File manager - Edit - /home/rangceb/diohome.com/wp-includes6790ed/fonts/core.tar
Back
functions.php 0000644 00000177746 15222641012 0007306 0 ustar 00 <?php if ( ! function_exists( 'et_allow_ampersand' ) ) : /** * Convert & into & * Escaped ampersand by wp_kses() which is used by et_get_safe_localization() * can be a troublesome in some cases, ie.: when string is sent in an email. * * @param string $string original string * * @return string modified string */ function et_allow_ampersand( $string ) { return str_replace('&', '&', $string); } endif; if ( ! function_exists( 'et_core_autoloader' ) ): /** * Callback for {@link spl_autoload_register()}. * * @param $class_name */ function et_core_autoloader( $class_name ) { if ( 0 !== strpos( $class_name, 'ET_Core' ) ) { return; } static $components = null; static $groups_loaded = array(); if ( null === $components ) { $components = et_core_get_components_metadata(); } if ( ! isset( $components[ $class_name ] ) ) { return; } $file = ET_CORE_PATH . $components[ $class_name ]['file']; $groups = $components[ $class_name ]['groups']; $slug = $components[ $class_name ]['slug']; if ( ! file_exists( $file ) ) { return; } // Load component class require_once $file; /** * Fires when a Core Component is loaded. * * The dynamic portion of the hook name, $slug, refers to the slug of the Core Component that was loaded. * * @since 1.0.0 */ do_action( "et_core_component_{$slug}_loaded" ); if ( empty( $groups ) ) { return; } foreach( $groups as $group_name ) { if ( in_array( $group_name, $groups_loaded ) ) { continue; } $groups_loaded[] = $group_name; $slug = $components['groups'][ $group_name ]['slug']; $init_file = $components['groups'][ $group_name ]['init']; $init_file = empty( $init_file ) ? null : ET_CORE_PATH . $init_file; et_core_initialize_component_group( $slug, $init_file ); } } endif; if ( ! function_exists( 'et_core_clear_transients' ) ): function et_core_clear_transients() { delete_transient( 'et_core_path' ); delete_transient( 'et_core_version' ); delete_transient( 'et_core_needs_old_theme_patch' ); } add_action( 'upgrader_process_complete', 'et_core_clear_transients', 10, 0 ); add_action( 'switch_theme', 'et_core_clear_transients' ); add_action( 'update_option_active_plugins', 'et_core_clear_transients', 10, 0 ); add_action( 'update_site_option_active_plugins', 'et_core_clear_transients', 10, 0 ); endif; if ( ! function_exists( 'et_core_cron_schedules_cb' ) ): function et_core_cron_schedules_cb( $schedules ) { if ( isset( $schedules['monthly'] ) ) { return $schedules; } $schedules['monthly'] = array( 'interval' => MONTH_IN_SECONDS, 'display' => __( 'Once Monthly' ) ); return $schedules; } add_action( 'cron_schedules', 'et_core_cron_schedules_cb' ); endif; if ( ! function_exists( 'et_core_die' ) ): function et_core_die( $message = '' ) { if ( wp_doing_ajax() ) { $message = '' !== $message ? $message : esc_html__( 'Configuration Error', 'et_core' ); wp_send_json_error( array( 'error' => $message ) ); } wp_die(); } endif; if ( ! function_exists( 'et_core_get_components_metadata' ) ): function et_core_get_components_metadata() { static $metadata = null; if ( null === $metadata ) { require_once '_metadata.php'; $metadata = json_decode( $metadata, true ); } return $metadata; } endif; if ( ! function_exists( 'et_core_get_component_names' ) ): /** * Returns the names of all available components, optionally filtered by type and/or group. * * @param string $include The type of components to include (official|third-party|all). Default is 'official'. * @param string $group Only include components in $group. Optional. * * @return array */ function et_core_get_component_names( $include = 'official', $group = '' ) { static $official_components = null; if ( null === $official_components ) { $official_components = et_core_get_components_metadata(); } if ( 'official' === $include ) { return empty( $group ) ? $official_components['names'] : $official_components['groups'][ $group ]['members']; } $third_party_components = et_core_get_third_party_components(); if ( 'third-party' === $include ) { return array_keys( $third_party_components ); } return array_merge( array_keys( $third_party_components ), empty( $group ) ? $official_components['names'] : $official_components['groups'][ $group ]['members'] ); } endif; if ( ! function_exists( 'et_core_get_ip_address' ) ): /** * Returns the IP address of the client that initiated the current HTTP request. * * @return string */ function et_core_get_ip_address() { static $ip; if ( null !== $ip ) { return $ip; } // Array of headers that could contain a valid IP address. $headers = array( 'HTTP_TRUE_CLIENT_IP', 'HTTP_CF_CONNECTING_IP', 'HTTP_X_SUCURI_CLIENTIP', 'HTTP_X_FORWARDED_FOR', 'HTTP_X_FORWARDED', 'HTTP_X_CLUSTER_CLIENT_IP', 'HTTP_FORWARDED_FOR', 'HTTP_FORWARDED', 'HTTP_CLIENT_IP', 'REMOTE_ADDR', ); $ip = ''; foreach ( $headers as $header ) { // Skip if the header is not set. if ( empty( $_SERVER[ $header ] ) ) { continue; } $header = $_SERVER[ $header ]; if ( et_()->includes( $header, ',' ) ) { $header = explode( ',', $header ); $header = $header[0]; } // Break if valid IP address is found. if ( filter_var( $header, FILTER_VALIDATE_IP, FILTER_FLAG_NO_RES_RANGE ) ) { $ip = sanitize_text_field( $header ); break; } } return $ip; } endif; if ( ! function_exists( 'et_core_use_google_fonts' ) ) : function et_core_use_google_fonts() { $utils = ET_Core_Data_Utils::instance(); $google_api_options = get_option( 'et_google_api_settings' ); return 'on' === $utils->array_get( $google_api_options, 'use_google_fonts', 'on' ); } endif; if ( ! function_exists( 'et_core_get_main_fonts' ) ) : function et_core_get_main_fonts() { global $wp_version; if ( version_compare( $wp_version, '4.6', '<' ) || ( ! is_admin() && ! et_core_use_google_fonts() ) ) { return ''; } $fonts_url = ''; /* Translators: If there are characters in your language that are not * supported by Open Sans, translate this to 'off'. Do not translate * into your own language. */ $open_sans = _x( 'on', 'Open Sans font: on or off', 'Divi' ); if ( 'off' !== $open_sans ) { $font_families = array(); if ( 'off' !== $open_sans ) $font_families[] = 'Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800'; $protocol = is_ssl() ? 'https' : 'http'; $query_args = array( 'family' => implode( '%7C', $font_families ), 'subset' => 'latin,latin-ext', ); $fonts_url = add_query_arg( $query_args, "$protocol://fonts.googleapis.com/css" ); } return $fonts_url; } endif; if ( ! function_exists( 'et_core_get_theme_info' ) ) : /** * Gets Theme Info. * * Gets Parent theme's info even when child theme is used. * * @param string $key One of WP_Theme class public properties. * * @returns string */ function et_core_get_theme_info( $key ) { static $theme_info = null; if ( ! $theme_info ) { $theme_info = wp_get_theme(); if ( defined( 'STYLESHEETPATH' ) && is_child_theme() ) { $theme_info = wp_get_theme( $theme_info->parent_theme ); } } return $theme_info->display( $key ); } endif; if ( ! function_exists( 'et_core_get_third_party_components' ) ): function et_core_get_third_party_components( $group = '' ) { static $third_party_components = null; if ( null !== $third_party_components ) { return $third_party_components; } /** * 3rd-party components can be registered by adding the class instance to this array using it's name as the key. * * @since 1.1.0 * * @param array $third_party { * An array mapping third party component names to a class instance reference. * * @type ET_Core_3rdPartyComponent $name The component class instance. * ... * } * @param string $group If not empty, only components classified under this group should be included. */ return $third_party_components = apply_filters( 'et_core_get_third_party_components', array(), $group ); } endif; if ( ! function_exists( 'et_core_get_memory_limit' ) ): /** * Returns the current php memory limit in megabytes as an int. * * @return int */ function et_core_get_memory_limit() { // Do NOT convert value to the integer, because wp_convert_hr_to_bytes() expects raw value from php_ini like 128M, 256M, 512M, etc $limit = @ini_get( 'memory_limit' ); $mb_in_bytes = 1024*1024; $bytes = max( wp_convert_hr_to_bytes( $limit ), $mb_in_bytes ); return ceil( $bytes / $mb_in_bytes ); } endif; if ( ! function_exists( 'et_core_initialize_component_group' ) ): function et_core_initialize_component_group( $slug, $init_file = null ) { $slug = strtolower( $slug ); if ( null !== $init_file && file_exists( $init_file ) ) { // Load and run component group's init function require_once $init_file; $init = "et_core_{$slug}_init"; $init(); } /** * Fires when a Core Component Group is loaded. * * The dynamic portion of the hook name, `$group`, refers to the name of the Core Component Group that was loaded. * * @since 1.0.0 */ do_action( "et_core_{$slug}_loaded" ); } endif; if ( ! function_exists( 'et_core_is_builder_used_on_current_request' ) ) : function et_core_is_builder_used_on_current_request() { static $builder_used = null; if ( null !== $builder_used ) { return $builder_used; } global $wp_query; if ( ! $wp_query ) { ET_Core_Logger::error( 'Called too early! $wp_query is not available.' ); return false; } $builder_used = false; if ( ! empty( $wp_query->posts ) ) { foreach ( $wp_query->posts as $post ) { if ( 'on' === get_post_meta( $post->ID, '_et_pb_use_builder', true ) ) { $builder_used = true; break; } } } else if ( ! empty( $wp_query->post ) ) { if ( 'on' === get_post_meta( $wp_query->post->ID, '_et_pb_use_builder', true ) ) { $builder_used = true; } } return $builder_used = apply_filters( 'et_core_is_builder_used_on_current_request', $builder_used ); } endif; if ( ! function_exists( 'et_core_is_fb_enabled' ) ): function et_core_is_fb_enabled() { if ( function_exists( 'et_fb_is_enabled' ) ) { return et_fb_is_enabled(); } return isset( $_GET['et_fb'] ) && current_user_can( 'edit-posts' ); } endif; if ( ! function_exists( 'et_core_is_saving_builder_modules_cache' ) ): function et_core_is_saving_builder_modules_cache() { // This filter is set when Modules Cache is being saved. return apply_filters( 'et_builder_modules_is_saving_cache', false ); } endif; /** * Is Gutenberg active? * * @since 3.19.2 Renamed from {@see et_is_gutenberg_active()} and moved to core. * @since 3.18 * * @return bool True - if the plugin is active */ if ( ! function_exists( 'et_core_is_gutenberg_active' ) ): function et_core_is_gutenberg_active() { global $wp_version; static $has_wp5_plus = null; if ( is_null( $has_wp5_plus ) ) { $has_wp5_plus = version_compare( $wp_version, '5.0-alpha1', '>=' ); } return $has_wp5_plus || function_exists( 'is_gutenberg_page' ); } endif; /** * Is Gutenberg active and enabled for the current post * WP 5.0 WARNING - don't use before global post has been set * * @since 3.19.2 Renamed from {@see et_is_gutenberg_enabled()} and moved to core. * @since 3.18 * * @return bool True - if the plugin is active and enabled. */ if ( ! function_exists( 'et_core_is_gutenberg_enabled' ) ): function et_core_is_gutenberg_enabled() { if ( function_exists( 'is_gutenberg_page' ) ) { return et_core_is_gutenberg_active() && is_gutenberg_page() && has_filter( 'replace_editor', 'gutenberg_init' ); } return et_core_is_gutenberg_active() && function_exists( 'use_block_editor_for_post' ) && use_block_editor_for_post( null ); } endif; if ( ! function_exists( 'et_core_load_main_fonts' ) ) : function et_core_load_main_fonts() { $fonts_url = et_core_get_main_fonts(); if ( empty( $fonts_url ) ) { return; } wp_enqueue_style( 'et-core-main-fonts', esc_url_raw( $fonts_url ), array(), null ); } endif; if ( ! function_exists( 'et_core_load_main_styles' ) ) : function et_core_load_main_styles( $hook ) { if ( ! in_array( $hook, array( 'post.php', 'post-new.php' ) ) ) { return; } wp_enqueue_style( 'et-core-admin' ); } endif; if ( ! function_exists( 'et_core_maybe_set_updated' ) ): function et_core_maybe_set_updated() { // TODO: Move et_{*}_option() functions to core. $last_core_version = get_option( 'et_core_version', '' ); if ( ET_CORE_VERSION === $last_core_version ) { return; } update_option( 'et_core_version', ET_CORE_VERSION ); define( 'ET_CORE_UPDATED', true ); } endif; if ( ! function_exists( 'et_core_maybe_patch_old_theme' ) ): function et_core_maybe_patch_old_theme() { if ( ! ET_Core_Logger::php_notices_enabled() ) { return; } if ( get_transient( 'et_core_needs_old_theme_patch' ) ) { add_action( 'after_setup_theme', 'ET_Core_Logger::disable_php_notices', 9 ); add_action( 'after_setup_theme', 'ET_Core_Logger::enable_php_notices', 11 ); return; } $themes = array( 'Divi' => '3.0.41', 'Extra' => '2.0.40' ); $current_theme = et_core_get_theme_info( 'Name' ); if ( ! in_array( $current_theme, array_keys( $themes ) ) ) { return; } $theme_version = et_core_get_theme_info( 'Version' ); if ( version_compare( $theme_version, $themes[ $current_theme ], '<' ) ) { add_action( 'after_setup_theme', 'ET_Core_Logger::disable_php_notices', 9 ); add_action( 'after_setup_theme', 'ET_Core_Logger::enable_php_notices', 11 ); set_transient( 'et_core_needs_old_theme_patch', true, DAY_IN_SECONDS ); } } endif; if ( ! function_exists( 'et_core_patch_core_3061' ) ): function et_core_patch_core_3061() { if ( '3.0.61' !== ET_CORE_VERSION ) { return; } if ( ! ET_Core_PageResource::can_write_to_filesystem() ) { return; // Should we display a notice in the dashboard? } $old_file = ET_CORE_PATH . 'init.php'; $new_file = dirname( __FILE__ ) . '/init.php'; ET_Core_PageResource::startup(); if ( ! ET_Core_PageResource::$wpfs ) { return; } ET_Core_PageResource::$wpfs->copy( $new_file, $old_file, true, 0644 ); et_core_clear_transients(); } endif; if ( ! function_exists( 'et_core_register_admin_assets' ) ) : /** * Register Core admin assets. * * @since ?.? Script 'et-core-admin' now loads in footer. * @since 1.0.0 * * @private */ function et_core_register_admin_assets() { wp_register_style( 'et-core-admin', ET_CORE_URL . 'admin/css/core.css', array(), ET_CORE_VERSION ); wp_register_script( 'et-core-admin', ET_CORE_URL . 'admin/js/core.js', array( 'jquery', 'jquery-ui-tabs', 'jquery-form', ), ET_CORE_VERSION, true ); wp_localize_script( 'et-core-admin', 'etCore', array( 'ajaxurl' => is_ssl() ? admin_url( 'admin-ajax.php' ) : admin_url( 'admin-ajax.php', 'http' ), 'wp_version' => get_bloginfo( 'version' ), 'text' => array( 'modalTempContentCheck' => esc_html__( 'Got it, thanks!', 'et_core' ), ), ) ); // enqueue common scripts as well. et_core_register_common_assets(); } endif; add_action( 'admin_enqueue_scripts', 'et_core_register_admin_assets' ); if ( ! function_exists( 'et_core_register_common_assets' ) ) : /** * Register and Enqueue Common Core assets. * * @since 1.0.0 * * @private */ function et_core_register_common_assets() { // common.js needs to be located at footer after waypoint, fitvid, & magnific js to avoid broken javascript on Facebook in-app browser wp_register_script( 'et-core-common', ET_CORE_URL . 'admin/js/common.js', array( 'jquery' ), ET_CORE_VERSION, true ); wp_enqueue_script( 'et-core-common' ); } endif; // common.js needs to be loaded after waypoint, fitvid, & magnific js to avoid broken javascript on Facebook in-app browser, hence the 15 priority add_action( 'wp_enqueue_scripts', 'et_core_register_common_assets', 15 ); if ( ! function_exists( 'et_core_noconflict_styles_gform' ) ) : /** * Register Core styles with Gravity Forms so that they're enqueued when running on no-conflict mode * * @since 3.21.2 * * @param $styles * * @return array */ function et_core_noconflict_styles_gform( $styles ) { $styles[] = 'et-core-admin'; return $styles; } endif; add_filter( 'gform_noconflict_styles', 'et_core_noconflict_scripts_gform' ); if ( ! function_exists( 'et_core_noconflict_scripts_gform' ) ) : /** * Register Core scripts with Gravity Forms so that they're enqueued when running on no-conflict mode * * @since 3.21.2 * * @param $scripts * * @return array */ function et_core_noconflict_scripts_gform( $scripts ) { $scripts[] = 'et-core-admin'; $scripts[] = 'et-core-common'; return $scripts; } endif; add_filter( 'gform_noconflict_scripts', 'et_core_noconflict_scripts_gform' ); if ( ! function_exists( 'et_core_security_check' ) ): /** * Check if current user can perform an action and/or verify a nonce value. die() if not authorized. * * @examples: * - Check if user can 'manage_options': `et_core_security_check();` * - Verify a nonce value: `et_core_security_check( '', 'nonce_name' );` * - Check if user can 'something' and verify a nonce value: `self::do_security_check( 'something', 'nonce_name' );` * * @param string $user_can The name of the capability to check with `current_user_can()`. * @param string $nonce_action The name of the nonce action to check (excluding '_nonce'). * @param string $nonce_key The key to use to lookup nonce value in `$nonce_location`. Default * is the value of `$nonce_action` with '_nonce' appended to it. * @param string $nonce_location Where the nonce is stored (_POST|_GET|_REQUEST). Default: _POST. * @param bool $die Whether or not to `die()` on failure. Default is `true`. * * @return bool|null Whether or not the checked passed if `$die` is `false`. */ function et_core_security_check( $user_can = 'manage_options', $nonce_action = '', $nonce_key = '', $nonce_location = '_POST', $die = true ) { $user_can = (string) $user_can; $nonce_action = (string) $nonce_action; $nonce_key = (string) $nonce_key; if ( empty( $nonce_key ) && false === strpos( $nonce_action, '_nonce' ) ) { $nonce_key = $nonce_action . '_nonce'; } else if ( empty( $nonce_key ) ) { $nonce_key = $nonce_action; } // phpcs:disable WordPress.Security.NonceVerification.NoNonceVerification switch( $nonce_location ) { case '_POST': $nonce_location = $_POST; break; case '_GET': $nonce_location = $_GET; break; case '_REQUEST': $nonce_location = $_REQUEST; break; default: return $die ? et_core_die() : false; } // phpcs:enable $passed = true; if ( is_numeric( $user_can ) ) { // Numeric values are deprecated in current_user_can(). We do not accept them here. $passed = false; } else if ( '' !== $nonce_action && empty( $nonce_location[ $nonce_key ] ) ) { // A nonce value is required when a nonce action is provided. $passed = false; } else if ( '' === $user_can && '' === $nonce_action ) { // At least one of a capability OR a nonce action is required. $passed = false; } else if ( '' !== $user_can && ! current_user_can( $user_can ) ) { // Capability check failed. $passed = false; } else if ( '' !== $nonce_action && ! wp_verify_nonce( $nonce_location[ $nonce_key ], $nonce_action ) ) { // Nonce verification failed. $passed = false; } if ( $die && ! $passed ) { et_core_die(); } return $passed; } endif; if ( ! function_exists( 'et_core_security_check_passed' ) ): /** * Wrapper for {@see et_core_security_check()} that disables `die()` on failure. * * @see et_core_security_check() for parameter documentation. * * @return bool Whether or not the security check passed. */ function et_core_security_check_passed( $user_can = 'manage_options', $nonce_action = '', $nonce_key = '', $nonce_location = '_POST' ) { return et_core_security_check( $user_can, $nonce_action, $nonce_key, $nonce_location, false ); } endif; if ( ! function_exists( 'et_core_setup' ) ) : /** * Setup Core. * * @since 1.0.0 * @since 3.0.60 The `$url` param is deprecated. * * @param string $deprecated Deprecated parameter. */ function et_core_setup( $deprecated = '' ) { if ( defined( 'ET_CORE_PATH' ) ) { return; } $core_path = _et_core_normalize_path( trailingslashit( dirname( __FILE__ ) ) ); $theme_dir = _et_core_normalize_path( trailingslashit( realpath( get_template_directory() ) ) ); if ( 0 === strpos( $core_path, $theme_dir ) ) { $url = get_template_directory_uri() . '/core/'; $type = 'theme'; } else { $url = plugin_dir_url( __FILE__ ); $type = 'plugin'; } define( 'ET_CORE_PATH', $core_path ); define( 'ET_CORE_URL', $url ); define( 'ET_CORE_TEXTDOMAIN', 'et-core' ); define( 'ET_CORE_TYPE', $type ); load_theme_textdomain( 'et-core', ET_CORE_PATH . 'languages/' ); et_core_maybe_set_updated(); et_new_core_setup(); register_shutdown_function( 'ET_Core_PageResource::shutdown' ); if ( is_admin() || ! empty( $_GET['et_fb'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.NoNonceVerification add_action( 'admin_enqueue_scripts', 'et_core_load_main_styles' ); } et_core_maybe_patch_old_theme(); } endif; if ( ! function_exists( 'et_force_edge_compatibility_mode' ) ) : function et_force_edge_compatibility_mode() { echo '<meta http-equiv="X-UA-Compatible" content="IE=edge">'; } endif; add_action( 'et_head_meta', 'et_force_edge_compatibility_mode' ); if ( ! function_exists( 'et_get_allowed_localization_html_elements' ) ) : function et_get_allowed_localization_html_elements() { $allowlisted_attributes = array( 'id' => array(), 'class' => array(), 'style' => array(), ); $allowlisted_attributes = apply_filters( 'et_allowed_localization_html_attributes', $allowlisted_attributes ); $elements = array( 'a' => array( 'href' => array(), 'title' => array(), 'target' => array(), 'rel' => array(), ), 'b' => array(), 'br' => array(), 'em' => array(), 'p' => array(), 'span' => array(), 'div' => array(), 'strong' => array(), 'code' => array(), ); $elements = apply_filters( 'et_allowed_localization_html_elements', $elements ); foreach ( $elements as $tag => $attributes ) { $elements[ $tag ] = array_merge( $attributes, $allowlisted_attributes ); } return $elements; } endif; if ( ! function_exists( 'et_get_safe_localization' ) ) : function et_get_safe_localization( $string ) { return apply_filters( 'et_get_safe_localization', wp_kses( $string, et_get_allowed_localization_html_elements() ) ); } endif; if ( ! function_exists( 'et_get_theme_version' ) ) : function et_get_theme_version() { $theme_info = wp_get_theme(); if ( is_child_theme() ) { $theme_info = wp_get_theme( $theme_info->parent_theme ); } $theme_version = $theme_info->display( 'Version' ); return $theme_version; } endif; if ( ! function_exists( 'et_get_child_theme_version' ) ) : /** * Get the current version of the active child theme. * * @since 4.10.0 */ function et_get_child_theme_version() { $theme_info = wp_get_theme(); $theme_info = wp_get_theme( $theme_info->child_theme ); $theme_version = $theme_info->display( 'Version' ); return $theme_version; } endif; if ( ! function_exists( 'et_requeue_child_theme_styles' ) ) : /** * Dequeue child theme css files and re-enqueue them below the theme stylesheet * and dynamic css files to preserve priority. * * @since 4.10.0 */ function et_requeue_child_theme_styles() { if ( is_child_theme() ) { global $shortname; $theme_version = et_get_child_theme_version(); $template_directory_uri = preg_quote( get_stylesheet_directory_uri(), '/' ); $styles = wp_styles(); $inline_style_suffix = et_core_is_inline_stylesheet_enabled() && et_use_dynamic_css() ? '-inline' : ''; $style_dep = array( $shortname . '-style-parent' . $inline_style_suffix ); if ( empty( $styles->registered ) ) { return; } foreach ( $styles->registered as $handle => $style ) { if ( preg_match( '/' . $template_directory_uri . '.*/', $style->src ) ) { $style_version = isset( $style->ver ) ? $style->ver : $theme_version; et_core_replace_enqueued_style( $style->src, '', $style_version, '', $style_dep, false ); } } } } endif; if ( ! function_exists( 'et_new_core_setup') ): function et_new_core_setup() { $has_php_52x = -1 === version_compare( PHP_VERSION, '5.3' ); require_once ET_CORE_PATH . 'components/Updates.php'; require_once ET_CORE_PATH . 'components/init.php'; require_once ET_CORE_PATH . 'php_functions.php'; require_once ET_CORE_PATH . 'wp_functions.php'; if ( $has_php_52x ) { spl_autoload_register( 'et_core_autoloader', true ); } else { spl_autoload_register( 'et_core_autoloader', true, true ); } // Initialize top-level components "group" $hook = did_action( 'plugins_loaded' ) ? 'after_setup_theme' : 'plugins_loaded'; add_action( $hook, 'et_core_init', 9999999 ); } endif; if ( ! function_exists( 'et_core_add_crossorigin_attribute' ) ): function et_core_add_crossorigin_attribute( $tag, $handle, $src ) { if ( ! $handle || ! in_array( $handle, array( 'react', 'react-dom' ) ) ) { return $tag; } return sprintf( '<script src="%1$s" crossorigin></script>', esc_attr( $src ) ); // phpcs:ignore WordPress.WP.EnqueuedResources.NonEnqueuedScript } endif; if ( ! function_exists( 'et_core_get_version_from_filesystem' ) ): /** * Get the core version from the filesystem. * This is necessary in cases such as Version Rollback where you cannot use * a constant from memory as it is outdated or you wish to get the version * not from the active (latest) core but from a different one. * * @param string $core_directory * * @return string */ function et_core_get_version_from_filesystem( $core_directory ) { $version_file = $core_directory . DIRECTORY_SEPARATOR . '_et_core_version.php'; if ( ! file_exists( $version_file ) ) { return ''; } include $version_file; return $ET_CORE_VERSION; } endif; if ( ! function_exists( 'et_core_replace_enqueued_style' ) ): /** * Replace a style's src if it is enqueued. * * @since 3.10 * * @param string $old_src Current src of css file. * @param string $new_src New css file src to replace old src. * @param string $new_ver New version for .css file. * @param string $new_handle New handle for .css file. * @param string $new_deps New deps for .css file. * @param boolean $regex Use regex to match and replace the style src. * * @return void */ function et_core_replace_enqueued_style( $old_src, $new_src, $new_ver, $new_handle, $new_deps, $regex = false ) { $styles = wp_styles(); if ( empty( $styles->registered ) ) { return; } foreach ( $styles->registered as $handle => $style ) { $match = $regex ? preg_match( $old_src, $style->src ) : $old_src === $style->src; if ( ! $match ) { continue; } $old_ver = isset( $style->ver ) ? $style->ver : false; $old_handle = $handle; $old_deps = isset( $style->deps ) ? $style->deps : array(); $style_handle = $new_handle ? $new_handle : $old_handle; $style_src = $regex ? preg_replace( $old_src, $new_src, $style->src ) : $new_src; $style_src = $new_src ? $style_src : $old_src; $style_deps = $new_deps ? $new_deps : $old_deps; $style_ver = $new_ver ? $new_ver : $old_ver; $style_media = isset( $style->args ) ? $style->args : 'all'; $inline_styles = $styles->get_data( $handle, 'after' ); $style_handle_filtered = apply_filters( 'et_core_enqueued_style_handle', $style_handle ); // Deregister first, so the handle can be re-enqueued. wp_dequeue_style( $old_handle ); wp_deregister_style( $old_handle ); // Enqueue the same handle with the new src. wp_enqueue_style( $style_handle_filtered, $style_src, $style_deps, $style_ver, $style_media ); if ( ! empty( $inline_styles ) ) { wp_add_inline_style( $style_handle_filtered, implode( "\n", $inline_styles ) ); } } } endif; if ( ! function_exists( 'et_core_is_inline_stylesheet_enabled' ) ) : /** * Check to see if Inline Stylesheet is enabled. * * @return bool * @since 4.10.2 */ function et_core_is_inline_stylesheet_enabled() { global $shortname; if ( defined( 'ET_BUILDER_PLUGIN_ACTIVE' ) ) { $options = get_option( 'et_pb_builder_options', array() ); $inline_stylesheet = isset( $options['performance_main_inline_stylesheet'] ) ? $options['performance_main_inline_stylesheet'] : 'on'; } else { // Get option value. If Extra, defaults to off. $inline_stylesheet = et_get_option( $shortname . '_inline_stylesheet', 'extra' === $shortname ? 'off' : 'on' ); } $enable_inline_stylesheet = 'on' === $inline_stylesheet ? true : false; return $enable_inline_stylesheet; } endif; if ( ! function_exists( 'et_core_is_safe_mode_active' ) ): /** * Check whether the Support Center's Safe Mode is active * * @param false|string $product The ET theme or plugin checking for Safe Mode status. * * @since ?.? * * @see ET_Core_SupportCenter::toggle_safe_mode * * @return bool */ function et_core_is_safe_mode_active($product=false) { // If we're checking against a particular product, return false if the product-specific usermeta doesn't match if ( $product ) { $product = esc_attr( $product ); if ( $product === get_user_meta( get_current_user_id(), '_et_support_center_safe_mode_product', true ) ) { return true; } return false; }; if ( 'on' === get_user_meta( get_current_user_id(), '_et_support_center_safe_mode', true ) ) { return true; }; return false; } endif; if ( ! function_exists( 'et_core_load_component' ) ) : /** * ============================= * ----->>> DEPRECATED! <<<----- * ============================= * Load Core components. * * This function loads Core components. Components are only loaded once, even if they are called many times. * Admin components/functions are automatically wrapped in an is_admin() check. * * @deprecated Component classes are now loaded automatically upon first use. Portability was the only component * ever loaded by this function, so it now only handles that single use-case (for backwards compatibility). * * @param string|array $components Name of the Core component(s) to include as and indexed array. * * @return bool Always return true. */ function et_core_load_component( $components ) { static $portability_loaded = false; if ( $portability_loaded || empty( $components ) ) { return true; } $is_jetpack = isset( $_SERVER['HTTP_USER_AGENT'] ) && false !== strpos( $_SERVER['HTTP_USER_AGENT'], 'Jetpack' ); if ( ! $is_jetpack && ! is_admin() && empty( $_GET['et_fb'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.NoNonceVerification return true; } if ( ! class_exists( 'ET_Core_Portability', false ) ) { include_once ET_CORE_PATH . 'components/Cache.php'; include_once ET_CORE_PATH . 'components/Portability.php'; } return $portability_loaded = true; } endif; /** * Is WooCommerce plugin active? * * @return bool True - if the plugin is active */ if ( ! function_exists( 'et_is_woocommerce_plugin_active' ) ): function et_is_woocommerce_plugin_active() { return class_exists( 'WooCommerce' ); } endif; /** * Check if WPML plugin is active. * * @since 4.2 * * @return bool */ function et_core_is_wpml_plugin_active() { return class_exists( 'SitePress' ); } if ( ! function_exists( 'et_is_product_taxonomy' ) ): /** * Wraps {@see is_product_taxonomy()} to check for its existence before calling. * * @since 4.0 * * @return bool */ function et_is_product_taxonomy() { return function_exists( 'is_product_taxonomy' ) && is_product_taxonomy(); } endif; if ( ! function_exists( 'et_core_add_allowed_protocols' ) ) : /** * Extend the allowlist of allowed URL protocols * * @param array $protocols List of URL protocols allowed by WordPress. * * @since 3.27.2 * * @return array Our extended list of URL protocols. */ function et_core_add_allowed_protocols( $protocols = array() ) { $additional = array( 'skype', // Add Skype messaging protocol 'sms', // Add SMS text messaging protocol ); $protocols = array_unique( array_merge( $protocols, $additional ) ); return $protocols; } add_filter( 'kses_allowed_protocols', 'et_core_add_allowed_protocols' ); endif; if ( ! function_exists( 'et_is_responsive_images_enabled' ) ): /** * Get the responsive images setting whether is enabled or not * * @since 3.27.1 * * @return bool */ function et_is_responsive_images_enabled() { global $shortname; static $enable_responsive_images; // Fetch the option once if ( null === $enable_responsive_images ) { $enable_responsive_images = et_get_option( "{$shortname}_enable_responsive_images", 'on' ); } return 'on' === $enable_responsive_images; } endif; if ( ! function_exists( 'et_screen_sizes' ) ) : /** * Get screen sizes list. * * @since 3.27.1 * * @return array */ function et_screen_sizes() { return array( 'desktop' => 1280, 'tablet' => 980, 'phone' => 480, ); } endif; if ( ! function_exists( 'et_image_get_responsive_size' ) ) : /** * Get images responsive sizes. * * @since 3.27.1 * * @param int $orig_width Original image's width. * @param int $orig_height Original image's height. * @param string $breakpoint Screen breakpont. See et_screen_sizes(). * * @return array|boolean Image responsive width & height. False on failure. */ function et_image_get_responsive_size( $orig_width, $orig_height, $breakpoint ) { $et_screen_sizes = et_screen_sizes(); if ( ! isset( $et_screen_sizes[ $breakpoint ] ) ) { return false; } $new_width = $et_screen_sizes[ $breakpoint ]; if ( $new_width >= $orig_width ) { return false; } $ratio = ( $orig_width * 1.0 ) / $orig_height; $new_height = round( ( $new_width / $ratio ) ); return array( 'width' => $new_width, 'height' => $new_height, ); } endif; if ( ! function_exists( 'et_image_add_srcset_and_sizes' ) ) : /** * Add ‘srcset’ and ‘sizes’ attributes to an existing ‘img’ element. * * @param string $image Image HTML markup. * @param boolean $echo Is print the output? * * @return string */ function et_image_add_srcset_and_sizes( $image, $echo = false ) { static $srcset_and_sizes_cached = array(); // Check if option is enabled. if ( ! et_is_responsive_images_enabled() ) { if ( $echo ) { echo et_core_intentionally_unescaped( $image, 'html' ); } return $image; } $src = et_get_src_from_img_tag( $image ); $cache_key = $src ? $src : 'empty-src'; if ( isset( $srcset_and_sizes_cached[ $cache_key ] ) ) { $image = $srcset_and_sizes_cached[ $cache_key ]; } else { // Only process if src attribute is not empty. if ( $src ) { $attachment_id = et_get_attachment_id_by_url( $src ); $image_meta = false; if ( $attachment_id ) { $image_meta = wp_get_attachment_metadata( $attachment_id ); } if ( $image_meta ) { $image = wp_image_add_srcset_and_sizes( $image, $image_meta, $attachment_id ); } } $srcset_and_sizes_cached[ $cache_key ] = $image; } if ( $echo ) { echo et_core_intentionally_unescaped( $image, 'html' ); } return $image; } endif; if ( ! function_exists( 'et_get_attachment_id_by_url_sql' ) ) : /** * Generate SQL query syntax to compute attachment ID by URL. * * @since 4.4.2 * * @param string $url The URL being looked up. * * @return string SQL query syntax. */ function et_get_attachment_id_by_url_sql( $normalized_url ) { global $wpdb; // Strip the HTTP/S protocol. $cleaned_url = preg_replace( '/^https?:/i', '', $normalized_url ); // Remove any thumbnail size suffix from the filename and use that as a fallback. $fallback_url = preg_replace( '/-(\d+)x(\d+)\.(jpg|jpeg|gif|png|svg|webp)$/', '.$3', $cleaned_url ); if ( $cleaned_url === $fallback_url ) { $attachments_query = $wpdb->prepare( "SELECT id FROM $wpdb->posts WHERE `post_type` = %s AND `guid` IN ( %s, %s )", 'attachment', esc_url_raw( "https:{$cleaned_url}" ), esc_url_raw( "http:{$cleaned_url}" ) ); } else { // Scenario: Trying to find the attachment for a file called x-150x150.jpg. // 1. Since WordPress adds the -150x150 suffix for thumbnail sizes we cannot be // sure if this is an attachment or an attachment's generated thumbnail. // 2. Since both x.jpg and x-150x150.jpg can be uploaded as separate attachments // we must decide which is a better match. // 3. The above is why we order by guid length and use the first result. $attachments_query = $wpdb->prepare( "SELECT id FROM $wpdb->posts WHERE `post_type` = %s AND `guid` IN ( %s, %s, %s, %s ) ORDER BY CHAR_LENGTH( `guid` ) DESC", 'attachment', esc_url_raw( "https:{$cleaned_url}" ), esc_url_raw( "https:{$fallback_url}" ), esc_url_raw( "http:{$cleaned_url}" ), esc_url_raw( "http:{$fallback_url}" ) ); } return $attachments_query; } endif; if ( ! function_exists( 'et_get_attachment_id_by_url' ) ) : /** * Tries to get attachment ID by URL. * * @since 3.27.1 * * @param string $url The URL being looked up. * * @return int The attachment ID found, or 0 on failure. */ function et_get_attachment_id_by_url( $url ) { global $wpdb; /** * Filters the attachment ID. * * @since 4.2.1 * * @param bool $attachment_id_pre Default value. Default is false. * @param string $url URL of the image need to query. * * @return bool|int */ $attachment_id_pre = apply_filters( 'et_get_attachment_id_by_url_pre', false, $url ); if ( false !== $attachment_id_pre ) { return $attachment_id_pre; } /** * Filters the attachment GUID. * * This filter intended to get the actual attachment guid URL in case the URL has been filtered before. * For example the URL has been modified to use CDN URL. * * @since 4.2.1 * * @param string $url URL of the image need to query. * * @return string */ $url = apply_filters( 'et_get_attachment_id_by_url_guid', $url ); // Normalize image URL. $normalized_url = et_attachment_normalize_url( $url ); // Bail early if the url is invalid. if ( ! $normalized_url ) { return 0; } // Load cached data for attachment_id_by_url. $cache = ET_Core_Cache_File::get( 'attachment_id_by_url' ); if ( isset( $cache[ $normalized_url ] ) ) { if ( et_core_is_uploads_dir_url( $normalized_url ) ) { return $cache[ $normalized_url ]; } unset( $cache[ $normalized_url ] ); ET_Core_Cache_File::set( 'attachment_id_by_url', $cache ); } $attachments_sql_query = et_get_attachment_id_by_url_sql( $normalized_url ); $attachment_id = (int) $wpdb->get_var( $attachments_sql_query ); // There is this new feature in WordPress 5.3 that allows users to upload big image file // (threshold being either width or height of 2560px) and the core will scale it down. // This causing the GUID URL info stored is no more relevant since the WordPress core system // will append "-scaled." string into the image URL when serving it in the frontend. // Hence we run another query as fallback in case the attachment ID is not found and // there is "-scaled." string appear in the image URL // @see https://make.wordpress.org/core/2019/10/09/introducing-handling-of-big-images-in-wordpress-5-3/ // @see https://wordpress.org/support/topic/media-images-renamed-to-xyz-scaled-jpg/ if ( ! $attachment_id && false !== strpos( $normalized_url, '-scaled.' ) ) { $normalized_url_not_scaled = str_replace( '-scaled.', '.', $normalized_url ); $attachments_sql_query = et_get_attachment_id_by_url_sql( $normalized_url_not_scaled ); $attachment_id = (int) $wpdb->get_var( $attachments_sql_query ); } // There is a case the GUID image URL stored differently with the URL // served in the frontend for a featured image, so the query will always fail. // Hence we add another fallback query to the _wp_attached_file value in // the postmeta table to match with the image relative path. if ( ! $attachment_id ) { $uploads = wp_get_upload_dir(); $uploads_baseurl = trailingslashit( $uploads['baseurl'] ); if ( 0 === strpos( $normalized_url, $uploads_baseurl ) ) { $file_path = str_replace( $uploads_baseurl, '', $normalized_url ); $file_path_no_resize = preg_replace( '/-(\d+)x(\d+)\.(jpg|jpeg|gif|png|svg|webp)$/', '.$3', $file_path ); if ( $file_path === $file_path_no_resize ) { $attachments_sql_query = $wpdb->prepare( "SELECT post_id FROM $wpdb->postmeta WHERE `meta_key` = %s AND `meta_value` = %s", '_wp_attached_file', $file_path ); } else { // Scenario: Trying to find the attachment for a file called x-150x150.jpg. // 1. Since WordPress adds the -150x150 suffix for thumbnail sizes we cannot be // sure if this is an attachment or an attachment's generated thumbnail. // 2. Since both x.jpg and x-150x150.jpg can be uploaded as separate attachments // we must decide which is a better match. // 3. The above is why we order by meta_value length and use the first result. $attachments_sql_query = $wpdb->prepare( "SELECT post_id FROM $wpdb->postmeta WHERE `meta_key` = %s AND `meta_value` IN ( %s, %s ) ORDER BY CHAR_LENGTH( `meta_value` ) DESC", '_wp_attached_file', $file_path, $file_path_no_resize ); } $attachment_id = (int) $wpdb->get_var( $attachments_sql_query ); } } // Cache data only if attachment ID is found. if ( $attachment_id && et_core_is_uploads_dir_url( $normalized_url ) ) { $cache[ $normalized_url ] = $attachment_id; ET_Core_Cache_File::set( 'attachment_id_by_url', $cache ); } return $attachment_id; } endif; if ( ! function_exists( 'et_get_attachment_size_by_url' ) ) : /** * Tries to get attachment size by URL. * * @since 3.27.1 * * @param string $url The URL being looked up. * @param string $default_size Default size name on failure. * * @return array|string Detected image size width and height or 'full' on failure. */ function et_get_attachment_size_by_url( $url, $default_size = 'full' ) { // Normalize image URL. $normalized_url = et_attachment_normalize_url( $url ); // Bail early if URL is invalid. if ( ! $normalized_url ) { return $default_size; } $cache = ET_Core_Cache_File::get( 'attachment_size_by_url' ); if ( isset( $cache[ $normalized_url ] ) ) { if ( et_core_is_uploads_dir_url( $normalized_url ) ) { return $cache[ $normalized_url ]; } unset( $cache[ $normalized_url ] ); ET_Core_Cache_File::set( 'attachment_size_by_url', $cache ); } $attachment_id = et_get_attachment_id_by_url( $url ); if ( ! $attachment_id ) { return $default_size; } $metadata = wp_get_attachment_metadata( $attachment_id ); if ( ! is_array( $metadata ) ) { return $default_size; } $size = $default_size; if ( isset( $metadata['file'] ) && strpos( $url, $metadata['file'] ) === ( strlen( $url ) - strlen( $metadata['file'] ) ) ) { $size = array( $metadata['width'], $metadata['height'] ); } elseif ( preg_match( '/-(\d+)x(\d+)\.(jpg|jpeg|gif|png|svg|webp)$/', $url, $match ) ) { // Get the image width and height. // Example: https://regex101.com/r/7JwGz7/1. $size = array( $match[1], $match[2] ); } // Cache data only if size is found. if ( $size !== $default_size && et_core_is_uploads_dir_url( $normalized_url ) ) { $cache[ $normalized_url ] = $size; ET_Core_Cache_File::set( 'attachment_size_by_url', $cache ); } return $size; } endif; if ( ! function_exists( 'et_get_image_srcset_sizes' ) ) : /** * Get image srcset & sizes attributes. * * @since 3.29.3 * * @param string $url Image source attribute value. * * @return (array|bool) Associative array of srcset & sizes attributes. False on failure. */ function et_get_image_srcset_sizes( $url ) { // Normalize image URL. $normalized_url = et_attachment_normalize_url( $url ); // Bail early if URL is invalid. if ( ! $normalized_url ) { return array(); } $cache = ET_Core_Cache_File::get( 'image_srcset_sizes' ); if ( isset( $cache[ $normalized_url ] ) ) { if ( et_core_is_uploads_dir_url( $normalized_url ) ) { return $cache[ $normalized_url ]; } unset( $cache[ $normalized_url ] ); ET_Core_Cache_File::set( 'image_srcset_sizes', $cache ); } $attachment_id = et_get_attachment_id_by_url( $url ); if ( ! $attachment_id ) { return array(); } $image_size = et_get_attachment_size_by_url( $url ); if ( ! $image_size ) { return array(); } $srcset = wp_get_attachment_image_srcset( $attachment_id, $image_size ); $sizes = wp_get_attachment_image_sizes( $attachment_id, $image_size ); if ( ! $srcset || ! $sizes ) { return array(); } $data = array( 'srcset' => $srcset, 'sizes' => $sizes, ); if ( et_core_is_uploads_dir_url( $normalized_url ) ) { $cache[ $normalized_url ] = $data; ET_Core_Cache_File::set( 'image_srcset_sizes', $cache ); } return $data; } endif; if ( ! function_exists( 'et_attachment_normalize_url' ) ) : /** * Tries to normalize attachment URL * * @since 3.27.1 * * @param string $url The URL being looked up. * * @return string|bool Normalized image URL or false on failure. */ function et_attachment_normalize_url( $url ) { // Remove URL query and string after list( $url ) = explode( '?', $url ); // Fixes the issue with x symbol between width and height values in the filename. $url = str_replace( '%26%23215%3B', 'x', rawurlencode( $url ) ); // Decode the URL. $url = rawurldecode( $url ); // Set as full path URL. if ( 0 !== strpos( $url, 'http' ) ) { $wp_upload_dir = wp_upload_dir( null, false ); $upload_dir = str_replace( site_url( '/' ), '', $wp_upload_dir['baseurl'] ); $url_trimmed = ltrim( $url, '/' ); if ( 0 === strpos( $url_trimmed, $upload_dir ) || 0 === strpos( $url_trimmed, 'wp-content' ) ) { $url = site_url( $url_trimmed ); } else { $url = $wp_upload_dir['baseurl'] . '/' . $url_trimmed; } } // Validate URL format and file extension. // Example: https://regex101.com/r/dXcpto/1. if ( ! filter_var( $url, FILTER_VALIDATE_URL ) || ! preg_match( '/^(.+)\.(jpg|jpeg|gif|png|svg|webp)$/', $url ) ) { return false; } return esc_url( $url ); } endif; if ( ! function_exists( 'et_core_is_uploads_dir_url' ) ) : /** * Check if a URL starts with the base upload directory URL. * * @since 4.2 * * @param string $url The URL being looked up. * * @return bool */ function et_core_is_uploads_dir_url( $url ) { $upload_dir = wp_upload_dir( null, false ); return et_()->starts_with( $url, $upload_dir['baseurl'] ); } endif; if ( ! function_exists( 'et_get_src_from_img_tag' ) ) : /** * Get src attribute value from image tag * * @since 3.27.1 * * @param string $image The HTML image tag to look up. * * @return string|bool Src attribute value. False on failure. */ function et_get_src_from_img_tag( $image ) { // Parse src attributes using regex. // Example: https://regex101.com/r/kY6Gdd/1. if ( preg_match( '/^<img.+src=[\'"](?P<src>.+?)[\'"].*>/', $image, $match ) ) { if ( isset( $match['src'] ) ) { return $match['src']; } } // Parse src attributes using DOMDocument when regex is failed. if ( class_exists( 'DOMDocument' ) && class_exists( 'DOMXPath' ) ) { $doc = new DOMDocument(); $doc->loadHTML( $image ); $xpath = new DOMXPath( $doc ); return $xpath->evaluate( 'string(//img/@src)' ); } return false; } endif; if ( ! function_exists( 'et_core_enqueue_js_admin' ) ) : function et_core_enqueue_js_admin() { global $themename; $epanel_jsfolder = ET_CORE_URL . 'admin/js'; et_core_load_main_fonts(); wp_register_script( 'epanel_colorpicker', $epanel_jsfolder . '/colorpicker.js', array(), et_get_theme_version() ); wp_register_script( 'epanel_eye', $epanel_jsfolder . '/eye.js', array(), et_get_theme_version() ); wp_register_script( 'epanel_checkbox', $epanel_jsfolder . '/checkbox.js', array(), et_get_theme_version() ); wp_enqueue_script( 'wp-color-picker' ); wp_enqueue_style( 'wp-color-picker' ); $wp_color_picker_alpha_uri = defined( 'ET_BUILDER_URI' ) ? ET_BUILDER_URI . '/scripts/ext/wp-color-picker-alpha.min.js' : $epanel_jsfolder . '/wp-color-picker-alpha.min.js'; wp_enqueue_script( 'wp-color-picker-alpha', $wp_color_picker_alpha_uri, array( 'jquery', 'wp-color-picker', ), et_get_theme_version(), true ); if ( ! wp_script_is( 'epanel_functions_init', 'enqueued' ) ) { wp_enqueue_script( 'epanel_functions_init', $epanel_jsfolder . '/functions-init.js', array( 'jquery', 'jquery-ui-tabs', 'jquery-form', 'epanel_colorpicker', 'epanel_eye', 'epanel_checkbox', 'wp-color-picker-alpha', ), et_get_theme_version() ); wp_localize_script( 'epanel_functions_init', 'ePanelishSettings', array( 'clearpath' => get_template_directory_uri() . '/epanel/images/empty.png', 'epanelish_nonce' => wp_create_nonce( 'epanelish_nonce' ), 'help_label' => esc_html__( 'Help', $themename ), 'et_core_nonces' => et_core_get_nonces(), ) ); } // Use WP 4.9 CodeMirror Editor for some fields if ( function_exists( 'wp_enqueue_code_editor' ) ) { wp_enqueue_code_editor( array( 'type' => 'text/css', ) ); // Required for Javascript mode wp_enqueue_script( 'jshint' ); wp_enqueue_script( 'htmlhint' ); } } endif; /** * Get ET account information. * * @since 4.0 * * @return array */ function et_core_get_et_account() { $utils = ET_Core_Data_Utils::instance(); $updates_options = get_site_option( 'et_automatic_updates_options', array() ); // Improve performance by NOT using $utils->array_get(). $username = isset( $updates_options['username'] ) ? $updates_options['username'] : ''; $api_key = isset( $updates_options['api_key'] ) ? $updates_options['api_key'] : ''; return array( 'et_username' => $username, 'et_api_key' => $api_key, 'status' => get_site_option( 'et_account_status', 'not_active' ), ); } /** * Get all meta saved by the builder for a given post. * * @since 4.0.10 * * @param integer $post_id * * @return array */ function et_core_get_post_builder_meta( $post_id ) { $raw_meta = get_post_meta( $post_id ); $meta = array(); foreach ( $raw_meta as $key => $values ) { if ( strpos( $key, '_et_pb_' ) !== 0 && strpos( $key, '_et_builder_' ) !== 0 ) { continue; } if ( strpos( $key, '_et_pb_ab_' ) === 0 ) { // Do not copy A/B meta as it is post-specific. continue; } foreach ( $values as $value ) { $meta[] = array( 'key' => $key, 'value' => $value, ); } } return $meta; } if ( ! function_exists( 'et_core_parse_google_fonts_json' ) ) : /** * Parse google fonts json to array. * * @since 4.0.10 * * @param string $json Google fonts json file content. * * @return array Associative array list of google fonts. */ function et_core_parse_google_fonts_json( $fonts_json ) { if ( ! $fonts_json || ! is_string( $fonts_json ) ) { return array(); } $fonts_json_decoded = json_decode( $fonts_json, true ); if ( ! $fonts_json_decoded || empty( $fonts_json_decoded['items'] ) ) { return array(); } $fonts = array(); foreach ( $fonts_json_decoded['items'] as $font_item ) { if ( ! isset( $font_item['family'], $font_item['variants'], $font_item['subsets'], $font_item['category'] ) ) { continue; } $fonts[ sanitize_text_field( $font_item['family'] ) ] = array( 'styles' => sanitize_text_field( implode( ',', $font_item['variants'] ) ), 'character_set' => sanitize_text_field( implode( ',', $font_item['subsets'] ) ), 'type' => sanitize_text_field( $font_item['category'] ), ); } ksort( $fonts ); return $fonts; } endif; if ( ! function_exists( 'et_core_get_saved_google_fonts' ) ) : /** * Get saved google fonts list. * * @since 4.0.10 * * @return array Associative array list of google fonts. */ function et_core_get_saved_google_fonts() { static $saved_google_fonts; if ( ! is_null( $saved_google_fonts ) ) { return $saved_google_fonts; } $json_file = ET_CORE_PATH . 'json-data/google-fonts.json'; if ( ! et_()->WPFS()->is_readable( $json_file ) ) { return array(); } $saved_google_fonts = et_core_parse_google_fonts_json( et_()->WPFS()->get_contents( $json_file ) ); return $saved_google_fonts; } endif; if ( ! function_exists( 'et_core_get_websafe_fonts' ) ) : /** * Get websafe fonts list. * * @since 4.0.10 * * @return array Associative array list of websafe fonts. */ function et_core_get_websafe_fonts() { $websafe_fonts = array( 'Georgia' => array( 'styles' => '300italic,400italic,600italic,700italic,800italic,400,300,600,700,800', 'character_set' => 'cyrillic,greek,latin', 'type' => 'serif', ), 'Times New Roman' => array( 'styles' => '300italic,400italic,600italic,700italic,800italic,400,300,600,700,800', 'character_set' => 'arabic,cyrillic,greek,hebrew,latin', 'type' => 'serif', ), 'Arial' => array( 'styles' => '300italic,400italic,600italic,700italic,800italic,400,300,600,700,800', 'character_set' => 'arabic,cyrillic,greek,hebrew,latin', 'type' => 'sans-serif', ), 'Trebuchet' => array( 'styles' => '300italic,400italic,600italic,700italic,800italic,400,300,600,700,800', 'character_set' => 'cyrillic,latin', 'type' => 'sans-serif', 'add_ms_version' => true, ), 'Verdana' => array( 'styles' => '300italic,400italic,600italic,700italic,800italic,400,300,600,700,800', 'character_set' => 'cyrillic,latin', 'type' => 'sans-serif', ), ); foreach ( array_keys( $websafe_fonts ) as $font_name ) { $websafe_fonts[ $font_name ]['standard'] = true; } ksort( $websafe_fonts ); return apply_filters( 'et_websafe_fonts', $websafe_fonts ); } endif; if ( ! function_exists( 'et_maybe_update_hosting_card_status' ) ) : /** * Divi Hosting Card :: Update dismiss status via ET API * * @since 4.4.7 */ function et_maybe_update_hosting_card_status() { $et_account = et_core_get_et_account(); $et_username = et_()->array_get( $et_account, 'et_username', '' ); $et_api_key = et_()->array_get( $et_account, 'et_api_key', '' ); // Exit if ET Username and/or ET API Key is not found if ( '' === $et_username || '' === $et_api_key ) { // Remove any WP Cron for Updating Hosting Card Status wp_unschedule_hook( 'et_maybe_update_hosting_card_status_cron' ); return; } global $wp_version; // Prepare settings for API request $options = array( 'timeout' => 10, 'body' => array( 'action' => 'disable_hosting_card', 'username' => $et_username, 'api_key' => $et_api_key, ), 'user-agent' => 'WordPress/' . $wp_version . '; Hosting Card/' . ET_CORE_VERSION . '; ' . home_url( '/' ), ); $request = wp_remote_post( 'https://www.elegantthemes.com/api/api.php', $options ); $request_response_code = wp_remote_retrieve_response_code( $request ); $response_body = wp_remote_retrieve_body( $request ); $response = (array) json_decode( $response_body ); // API request has been updated successfully and the User has already disabled the card, or, // when API request was successful and returns error message if ( 'disabled' === et_()->array_get( $response, 'status' ) || '' !== et_()->array_get( $response, 'error', '' ) ) { // Remove any WP Cron for Updating Hosting Card Status wp_unschedule_hook( 'et_maybe_update_hosting_card_status_cron' ); return; } // Fail-safe :: Schedule WP Cron to try again // Once something were wrong in API request, or, response has error code if ( is_wp_error( $request ) || 200 !== $request_response_code ) { // First API request has failed, which were done already in above, second request // (via cron) will be made in a minute, then third (via cron) and future (via cron) // call will be per hour. Once API request is successful, cron will be removed $timestamp = time() + 1 * MINUTE_IN_SECONDS; if ( ! wp_next_scheduled( 'et_maybe_update_hosting_card_status_cron' ) ) { wp_schedule_event( $timestamp, 'hourly', 'et_maybe_update_hosting_card_status_cron' ); } } } endif; // Action for WP Cron: Disable Hosting Card status via ET API add_action( 'et_maybe_update_hosting_card_status_cron', 'et_maybe_update_hosting_card_status' ); if ( ! function_exists( 'et_disable_emojis' ) ) : /** * Disable WordPress Emojis * Copyright Ryan Hellyer https://geek.hellyer.kiwi/ * License: GPL2 * * @since 4.10.0 * * Removes WordPress emoji scripts and styles. */ function et_disable_emojis() { global $shortname; if ( 'on' === et_get_option( $shortname . '_disable_emojis', 'on' ) ) { remove_action( 'wp_head', 'print_emoji_detection_script', 7 ); remove_action( 'admin_print_scripts', 'print_emoji_detection_script' ); remove_action( 'wp_print_styles', 'print_emoji_styles' ); remove_action( 'admin_print_styles', 'print_emoji_styles' ); remove_filter( 'the_content_feed', 'wp_staticize_emoji' ); remove_filter( 'comment_text_rss', 'wp_staticize_emoji' ); remove_filter( 'wp_mail', 'wp_staticize_emoji_for_email' ); add_filter( 'tiny_mce_plugins', 'et_disable_emojis_tinymce' ); add_filter( 'wp_resource_hints', 'et_disable_emojis_dns_prefetch', 10, 2 ); } } endif; if ( ! function_exists( 'et_disable_emojis_tinymce' ) ) : /** * Disables tinymce emojis. * Copyright Ryan Hellyer https://geek.hellyer.kiwi/ * License: GPL2 * * @since 4.10.0 * * @param array $plugins of plugins. * @return array plugins. */ function et_disable_emojis_tinymce( $plugins ) { if ( is_array( $plugins ) ) { return array_diff( $plugins, array( 'wpemoji' ) ); } return array(); } endif; if ( ! function_exists( 'et_disable_emojis_dns_prefetch' ) ) : /** * Disables dns prefech meta tags. * Copyright Ryan Hellyer https://geek.hellyer.kiwi/ * License: GPL2 * * @since 4.10.0 * * @param array $urls URLs to print for resource hints. * @param string $relation_type The relation type the URLs are printed for. * @return array plugins. */ function et_disable_emojis_dns_prefetch( $urls, $relation_type ) { if ( 'dns-prefetch' === $relation_type ) { $emoji_svg_url_bit = 'https://s.w.org/images/core/emoji/'; foreach ( $urls as $key => $url ) { if ( strpos( $url, $emoji_svg_url_bit ) !== false ) { unset( $urls[ $key ] ); } } } return $urls; } endif; if ( ! function_exists( 'et_dequeue_block_css' ) ) : /** * If the option is enabled and the page is built with the Divi Builder, * dequeue the gutenberg block css file from the head. * * @since 4.10.0 */ function et_dequeue_block_css() { global $shortname; $post_id = get_the_id(); $is_page_builder_used = function_exists( 'et_pb_is_pagebuilder_used' ) ? et_pb_is_pagebuilder_used( $post_id ) : false; $defer_block_css_enabled = ( 'on' === et_get_option( $shortname . '_defer_block_css', 'on' ) ); $is_wp_template_used = ! empty( et_builder_get_wp_editor_templates() ); if ( $is_page_builder_used && $defer_block_css_enabled && ! $is_wp_template_used ) { wp_dequeue_style( 'wp-block-library' ); } } endif; if ( ! function_exists( 'et_enqueue_block_css' ) ) : /** * If the option is enabled and the page is built with the Divi Builder, * enqueue the gutenberg block css file in the body. * * @since 4.10.0 */ function et_enqueue_block_css() { global $shortname; $post_id = get_the_id(); $is_page_builder_used = et_pb_is_pagebuilder_used( $post_id ); $defer_block_css_enabled = ( 'on' === et_get_option( $shortname . '_defer_block_css', 'on' ) ); if ( $is_page_builder_used && $defer_block_css_enabled ) { // Defer the stylesheet. add_filter( 'style_loader_tag', 'et_defer_gb_css', 10, 2 ); // Re-enqueue the deferred stylesheet. wp_enqueue_style( 'wp-block-library' ); } } endif; if ( ! function_exists( 'et_defer_gb_css' ) ) : /** * Load GB stylesheet asynchronously by swapping the media attribute on load. * * @since 4.10.0 * * @param string $html HTML to replace. * @param string $handle Stylesheet handle. * @return string $html replacement html. */ function et_defer_gb_css( $html, $handle ) { if ( 'wp-block-library' === $handle ) { return str_replace( "media='all'", "media='none' onload=\"media='all'\"", $html ); } return $html; } endif; /** * Enqueue Code snippets library scripts on theme options page. * * @since 4.19.0 * * @param string $hook_suffix Page hook suffix. * @return void */ function et_code_snippets_admin_enqueue_scripts( $hook_suffix ) { if ( ! function_exists( 'et_builder_bfb_enabled' ) ) { return; } global $shortname; // phpcs:disable WordPress.Security.NonceVerification -- This function does not change any state and is therefore not susceptible to CSRF. $is_templates_page = isset( $_GET['page'] ) && 'et_theme_builder' === $_GET['page']; $is_options_page = 'toplevel_page_et_' . $shortname . '_options' === $hook_suffix; $current_screen = get_current_screen(); $is_layouts_library_page = isset( $current_screen->id ) && 'edit-et_pb_layout' === $current_screen->id; if ( ! $is_templates_page && ! $is_options_page && ! $is_layouts_library_page && ! et_builder_bfb_enabled() ) { return; } if ( ! class_exists( 'ET_Code_Snippets_App' ) ) { require_once ET_CORE_PATH . 'code-snippets/code-snippets-app.php'; } if ( $is_layouts_library_page ) { // Avoids et_cloud_data not defined error. ET_Cloud_App::load_js(); } ET_Code_Snippets_App::load_js(); } add_action( 'admin_enqueue_scripts', 'et_code_snippets_admin_enqueue_scripts' ); /** * Enqueue Code snippets library scripts in VB. * * @since 4.19.0 * * @return void */ function et_code_snippets_vb_enqueue_scripts() { if ( ! et_core_is_fb_enabled() ) { return; } if ( ! class_exists( 'ET_Code_Snippets_App' ) ) { require_once ET_CORE_PATH . 'code-snippets/code-snippets-app.php'; } ET_Code_Snippets_App::load_js(); } add_action( 'wp_enqueue_scripts', 'et_code_snippets_vb_enqueue_scripts' ); /** * Enqueue AI scripts on BFB page. * * @since 4.22.0 * * @return void */ function et_ai_admin_enqueue_scripts() { if ( ! function_exists( 'et_builder_bfb_enabled' ) ) { return; } if ( ! et_builder_bfb_enabled() ) { return; } if ( ! class_exists( 'ET_AI_App' ) ) { $path = defined( 'ET_BUILDER_PLUGIN_ACTIVE' ) ? ET_BUILDER_PLUGIN_DIR : get_template_directory(); require_once $path . '/ai-app/ai-app.php'; } if ( et_pb_is_allowed( 'divi_ai' ) ) { ET_AI_App::load_js(); } } add_action( 'admin_enqueue_scripts', 'et_ai_admin_enqueue_scripts' ); /** * Load Cloud Snippets App on `Export To Divi Cloud` btn click. * * @since 4.21.1 * * @return void */ function et_save_to_cloud_modal() { $current_screen = get_current_screen(); $current_screen_id = $current_screen ? $current_screen->id : ''; if ( 'edit-et_pb_layout' !== $current_screen_id ) { return; } ?> <div id="et-cloud-app--layouts"></div> <?php } add_action( 'admin_footer', 'et_save_to_cloud_modal' ); /** * Get roles with specific capabilities. * * This function iterates through WordPress roles, identifying those with the specific * capabilities. The resulting array of applicable roles is then filtered using the * 'et_core_get_roles_by_capabilities' hook. * * Notes: The relation between the capabilities is "AND". So, all the capabilites should * be available and enabled to mark current role. * * @since 4.25.2 * * @param array $capabilities Specific capabilities that we want to check. * * @return array List of roles based on the specific capabilities. */ function et_core_get_roles_by_capabilities( $capabilities ) { global $wp_roles; $roles = []; foreach ( $wp_roles->roles as $role => $details ) { // By default, we assume that current role has all the capabilities. $has_capabilities = true; // Iterate through the capabilities to check the availability and activation. foreach ( $capabilities as $capability ) { // But once we find out one of the capabilities doesn't exist for current role, // break the loop and mark it as `false` to fasten the checking process. $has_capability = isset( $details['capabilities'][ $capability ] ) ? $details['capabilities'][ $capability ] : false; if ( ! $has_capability ) { $has_capabilities = false; break; } } // If capability check done and current role has all the capabilities, assign it. if ( $has_capabilities ) { $roles[] = $role; } } /** * Filters the list of roles based on the specific capabilities. * * @since 4.25.2 * * @param array $roles List of roles based on the specific capabilities. * @param string $capabilities Specific capabilities that we want to check. */ return apply_filters( 'et_core_get_roles_by_capabilities', $roles, $capabilities ); } php_functions.php 0000644 00000000734 15222641012 0010133 0 ustar 00 <?php if ( ! function_exists( 'array_replace' ) ) : function array_replace( array $array, array $array1 ) { $args = func_get_args(); $count = func_num_args(); for ( $i = 0; $i < $count; ++$i ) { if ( is_array( $args[ $i ] ) ) { foreach ( $args[ $i ] as $key => $val ) { $array[ $key ] = $val; } } else { trigger_error( __FUNCTION__ . '(): Argument #' . ( $i + 1 ) . ' is not an array', E_USER_WARNING ); return null; } } return $array; } endif; updates_init.php 0000644 00000000056 15222641012 0007741 0 ustar 00 <?php require_once 'components/Updates.php'; _et_core_version.php 0000644 00000000401 15222641012 0010567 0 ustar 00 <?php /** * Define the current ET Core version * * (Note: this value updates automatically as part of our Grunt release task) * * @package \ET\Core */ // Note, this will be updated automatically during grunt release task $ET_CORE_VERSION = '4.27.4'; i18n/library.php 0000644 00000003225 15222641012 0007475 0 ustar 00 <?php /** * I18n file. * * Translatable strings go here. * * @package Divi */ return [ 'Snippet' => esc_html__( 'Snippet', 'et_builder' ), 'Code Snippet' => esc_html__( 'Code Snippet', 'et_builder' ), 'Divi Code Snippets' => esc_html__( 'Divi Code Snippets', 'et_builder' ), 'Code Snippets Library' => esc_html__( 'Code Snippets Library', 'et_builder' ), 'Code Snippet Details' => esc_html__( 'Code Snippet Details', 'et_builder' ), 'CSS Snippet' => esc_html__( 'CSS Snippet', 'et_builder' ), 'Edit Snippet' => esc_html__( 'Edit Snippet', 'et_builder' ), 'HTML/JS Snippet' => esc_html__( 'HTML/JS Snippet', 'et_builder' ), 'Snippets' => esc_html__( 'Snippets', 'et_builder' ), 'importContextFail' => esc_html__( 'This file should not be imported in this context.', 'et_builder' ), 'Edit %s' => esc_html__( 'Edit %s', 'et_builder' ), 'Save' => esc_html__( 'Save', 'et_builder' ), 'Cancel' => esc_html__( 'Cancel', 'et_builder' ), 'Import & Export Snippets' => esc_html__( 'Import & Export Snippets', 'et_builder' ), 'Import & Export Snippet' => esc_html__( 'Import & Export Snippet', 'et_builder' ), 'Import Snippets' => esc_html__( 'Import Snippets', 'et_builder' ), 'Import Snippet' => esc_html__( 'Import Snippet', 'et_builder' ), 'Log In To Divi Cloud' => esc_html__( 'Log In To Divi Cloud', 'et_builder' ), 'Theme Options Library' => esc_html__( 'Theme Options Library', 'et_builder' ), 'Theme Options Details' => esc_html__( 'Theme Options Details', 'et_builder' ), ]; code-snippets/constants.php 0000644 00000000716 15222641012 0012045 0 ustar 00 <?php /** * "Code Snippets" quick feature constants file. * * Divi Cloud Code Snippet constants. * * @link https://github.com/elegantthemes/Divi/issues/26232 * * @package Divi * @subpackage Cloud * @since 4.19.0 */ if ( ! defined( 'ET_CODE_SNIPPET_POST_TYPE' ) ) { define( 'ET_CODE_SNIPPET_POST_TYPE', 'et_code_snippet' ); } if ( ! defined( 'ET_CODE_SNIPPET_TAXONOMY_TYPE' ) ) { define( 'ET_CODE_SNIPPET_TAXONOMY_TYPE', 'et_code_snippet_type' ); } code-snippets/CodeSnippetsLibrary.php 0000644 00000007265 15222641012 0013764 0 ustar 00 <?php /** * Code Snippets library. * * Registers post types to be used in the "Code Snippets" library. * * @link https://github.com/elegantthemes/Divi/issues/26232 * * @package Divi * @subpackage Builder * @since 4.19.0 */ /** * Core class used to implement "Code Snippets" library. * * Register post types & taxonomies to be used in "Code Snippets" library. */ class ET_Builder_Code_Snippets_Library { /** * Instance of `ET_Builder_Code_Snippets_Library`. * * @var ET_Builder_Code_Snippets_Library */ private static $_instance; /** * Instance of `ET_Core_Data_Utils`. * * @var ET_Core_Data_Utils */ protected static $_; /** * List of i18n strings. * * @var mixed[] */ protected static $_i18n; /** * ET_Builder_Post_Taxonomy_LayoutCategory instance. * * Shall be used for querying `et_code_snippet` taxonomy. * * @var ET_Builder_Post_Taxonomy_LayoutCategory */ public $code_snippet_categories; /** * ET_Builder_Post_Taxonomy_LayoutTag instance. * * Shall be used for querying `et_code_snippet` taxonomy . * * @var ET_Builder_Post_Taxonomy_LayoutTag */ public $code_snippet_tags; /** * ET_Builder_Post_Taxonomy_CodeSnippetType instance. * * Shall be used for querying `et_code_snippet` taxonomy . * * @var ET_Builder_Post_Taxonomy_CodeSnippetType */ public $code_snippet_types; /** * ET_Builder_Post_Type_TBItem instance. * * Shall be used for querying `et_tb_item` posts . * * @var ET_Builder_Post_Type_TBItem */ public $code_snippets; /** * ET_Builder_Post_Taxonomy_LayoutCategory instance. * * Shall be used for querying `et_tb_layout_category` taxonomy . * * @var ET_Builder_Post_Taxonomy_LayoutCategory */ public $code_snippets_categories; /** * ET_Builder_Post_Taxonomy_LayoutTag instance. * * Shall be used for querying `et_tb_layout_tag` taxonomy . * * @var ET_Builder_Post_Taxonomy_LayoutTag */ public $code_snippets_tags; /** * ET_Builder_Post_Taxonomy_CodeSnippetType instance. * * Shall be used for querying `et_tb_layout_type` taxonomy . * * @var ET_Builder_Post_Taxonomy_CodeSnippetType */ public $code_snippets_type; /** * Class constructor. */ public function __construct() { $this->_instance_check(); $this->_register_cpt_and_taxonomies(); } /** * Dies if an instance already exists. */ protected function _instance_check() { if ( self::$_instance ) { et_error( 'Multiple instances are not allowed!' ); wp_die(); } } /** * Registers the Theme Builder Library's custom post type and its taxonomies. */ protected function _register_cpt_and_taxonomies() { $files = [ ET_CODE_SNIPPETS_DIR . 'post/type/CodeSnippet.php', ET_CODE_SNIPPETS_DIR . 'post/taxonomy/CodeSnippetType.php', ]; if ( ! $files ) { return; } foreach ( $files as $file ) { require_once $file; } $this->code_snippets = ET_Builder_Post_Type_Code_Snippet::instance(); $this->code_snippets_categories = ET_Builder_Post_Taxonomy_LayoutCategory::instance(); $this->code_snippets_tags = ET_Builder_Post_Taxonomy_LayoutTag::instance(); $this->code_snippets_type = ET_Builder_Post_Taxonomy_CodeSnippetType::instance(); // We manually call register_all() now to ensure the CPT and taxonomies are registered // at exactly the same point during the request that they were in prior releases. ET_Builder_Post_Type_TBItem::register_all( 'builder' ); } /** * Returns the ET_Builder_TBItem_Library instance. * * @return ET_Builder_TBItem_Library */ public static function instance() { if ( ! self::$_instance ) { self::$_instance = new self(); } return self::$_instance; } } ET_Builder_Code_Snippets_Library::instance(); code-snippets/code-snippets.php 0000644 00000002400 15222641012 0012576 0 ustar 00 <?php /** * Code snippets quick feature entry file. * * Divi Cloud Code Snippets * * @link https://github.com/elegantthemes/Divi/issues/26232 * * @package Divi * @subpackage Core * @since 4.19.0 */ if ( ! defined( 'ET_CODE_SNIPPETS_DIR' ) ) { define( 'ET_CODE_SNIPPETS_DIR', ET_CORE_PATH . 'code-snippets/' ); } require_once trailingslashit( ET_CODE_SNIPPETS_DIR ) . 'constants.php'; require_once trailingslashit( ET_CODE_SNIPPETS_DIR ) . 'code-snippets-library.php'; require_once trailingslashit( ET_CODE_SNIPPETS_DIR ) . 'api.php'; if ( ! function_exists( 'et_init_code_snippets_library' ) ) : /** * Init Code Snippets Library. * * Class `ET_Builder_Post_Taxonomy_LayoutCategory` must be initalized * before `ET_Builder_Code_Snippets_Library` because of the internal dependency. * * Since `ET_Builder_Post_Taxonomy_LayoutCategory is initialized using * `add_action( 'init', 'et_setup_builder', 0 );`, * * We initialize `ET_Builder_Code_Snippets_Library` using * `add_action( 'init', 'et_init_code_snippets_library', 10 );` * * @return void */ function et_init_code_snippets_library() { require_once trailingslashit( ET_CODE_SNIPPETS_DIR ) . 'CodeSnippetsLibrary.php'; } endif; add_action( 'init', 'et_init_code_snippets_library' ); code-snippets/api.php 0000644 00000024164 15222641012 0010605 0 ustar 00 <?php /** * Code Snippets Library API. * * @package Divi */ // Exit if accessed directly. if ( ! defined( 'ABSPATH' ) ) { exit; } /** * Retrieves Code Snippets Library items. * * @return void */ function et_code_snippets_library_get_items() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_get_items', 'nonce' ); $code_snippet_type = ''; if ( isset( $_POST['et_code_snippet_type'] ) && is_string( $_POST['et_code_snippet_type'] ) ) { $code_snippet_type = sanitize_text_field( $_POST['et_code_snippet_type'] ); } $is_code_snippet_type_valid = in_array( $code_snippet_type, [ 'et_code_snippet_css', 'et_code_snippet_css_no_selector', 'et_code_snippet_html_js', ], true ); if ( ! $code_snippet_type || ! $is_code_snippet_type_valid ) { wp_send_json_error( 'Error: Wrong item type provided.' ); } $item_library_local = et_pb_code_snippets_library_local(); $data = $item_library_local->get_library_items( $code_snippet_type ); wp_send_json_success( $data ); } add_action( 'wp_ajax_et_code_snippets_library_get_items', 'et_code_snippets_library_get_items' ); /** * Retrieves Code Snippets Library item content. * * @return void */ function et_code_snippets_library_get_item_content() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_get_item_content', 'nonce' ); $post_id = isset( $_POST['et_code_snippet_id'] ) ? (int) sanitize_text_field( $_POST['et_code_snippet_id'] ) : 0; $return_format = isset( $_POST['et_code_snippet_format'] ) ? (string) sanitize_text_field( $_POST['et_code_snippet_format'] ) : 'raw'; $snippet_type = isset( $_POST['et_code_snippet_type'] ) ? (string) sanitize_text_field( $_POST['et_code_snippet_type'] ) : 'et_code_snippet_html_js'; $post_type = get_post_type( $post_id ); if ( ! current_user_can( 'edit_post', $post_id ) || ET_CODE_SNIPPET_POST_TYPE !== $post_type ) { wp_send_json_error( 'You do not have permission.' ); } $post = get_post( $post_id ); $post_content = $post->post_content; $exported = array(); if ( 'exported' === $return_format ) { $exported = array( 'context' => 'et_code_snippet', 'data' => $post_content, 'snippet_type' => $snippet_type, ); } wp_send_json_success( array( 'snippet' => $post_content, 'exported' => $exported, ) ); } add_action( 'wp_ajax_et_code_snippets_library_get_item_content', 'et_code_snippets_library_get_item_content' ); /** * Save Code Snippets Library item content. * * @return void */ function et_code_snippets_library_save_item_content() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_save_item_content', 'nonce' ); $post_id = isset( $_POST['et_code_snippet_id'] ) ? absint( $_POST['et_code_snippet_id'] ) : 0; $post_type = get_post_type( $post_id ); if ( ! current_user_can( 'edit_post', $post_id ) || ET_CODE_SNIPPET_POST_TYPE !== $post_type ) { wp_send_json_error( 'You do not have permission.' ); } // phpcs:disable ET.Sniffs.ValidatedSanitizedInput -- $_POST is an array, it's value sanitization is done at the time of saving by wp_update_post. $result = wp_update_post( [ 'ID' => $post_id, 'post_content' => $_POST['et_code_snippet_content'], ] ); // phpcs:enable wp_send_json_success( array( 'result' => $result, ) ); } add_action( 'wp_ajax_et_code_snippets_library_save_item_content', 'et_code_snippets_library_save_item_content' ); /** * Update Code Snippets Library item. * * @return void */ function et_code_snippets_library_update_item() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_update_item', 'nonce' ); $payload = isset( $_POST['payload'] ) ? $_POST['payload'] : array(); // phpcs:ignore ET.Sniffs.ValidatedSanitizedInput -- $_POST['payload'] is an array, it's value sanitization is done at the time of accessing value. $item_library_local = et_pb_code_snippets_library_local(); $response = $item_library_local->perform_item_update( $payload ); if ( ! $response ) { wp_send_json_error( 'Error: Wrong data provided.' ); } wp_send_json_success( $response ); } add_action( 'wp_ajax_et_code_snippets_library_update_item', 'et_code_snippets_library_update_item' ); /** * Prepare Library Categories or Tags List. * * @param string $taxonomy Name of the taxonomy. * * @return array Clean Categories/Tags array. **/ function et_get_clean_library_terms( $taxonomy = 'layout_category' ) { $raw_terms_array = apply_filters( 'et_pb_new_layout_cats_array', get_terms( $taxonomy, array( 'hide_empty' => false ) ) ); $clean_terms_array = array(); if ( is_array( $raw_terms_array ) && ! empty( $raw_terms_array ) ) { foreach ( $raw_terms_array as $term ) { $clean_terms_array[] = array( 'name' => et_core_intentionally_unescaped( html_entity_decode( $term->name ), 'react_jsx' ), 'id' => $term->term_id, 'slug' => $term->slug, 'count' => $term->count, ); } } return $clean_terms_array; } /** * AJAX Callback: Remove the Library layout after it was moved to the Cloud. * * @since 4.17.0 * * @global $_POST['payload'] Array with the layout data to remove. * * @return void|string JSON encoded in case of empty payload */ function et_code_snippets_toggle_cloud_status() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_toggle_item_location', 'nonce' ); $post_id = isset( $_POST['et_code_snippet_id'] ) ? (int) sanitize_text_field( $_POST['et_code_snippet_id'] ) : 0; if ( empty( $post_id ) ) { wp_send_json_error( 'No post ID' ); } $post_type = get_post_type( $post_id ); if ( ! current_user_can( 'edit_post', $post_id ) || ET_CODE_SNIPPET_POST_TYPE !== $post_type ) { wp_send_json_error( 'You do not have permission.' ); } wp_delete_post( $post_id, true ); wp_send_json_success( array( 'localLibraryTerms' => [ 'layout_category' => et_get_clean_library_terms(), 'layout_tag' => et_get_clean_library_terms( 'layout_tag' ), ], ) ); } add_action( 'wp_ajax_et_code_snippets_toggle_cloud_status', 'et_code_snippets_toggle_cloud_status' ); /** * Export Code Snippets Library item. * * @return void */ function et_code_snippets_library_export_item() { et_core_security_check( et_core_portability_cap( 'et_code_snippets' ), 'et_code_snippets_library_export_item', 'nonce' ); $post_id = isset( $_POST['id'] ) ? absint( $_POST['id'] ) : 0; $cloud_content = isset( $_POST['cloudContent'] ) ? $_POST['cloudContent'] : ''; // phpcs:ignore ET.Sniffs.ValidatedSanitizedInput -- $_POST['cloudContent'] is an array, it's value sanitization is done at the time of accessing value. $direct_export = isset( $_POST['directExport'] ) ? $_POST['directExport'] : ''; // phpcs:ignore ET.Sniffs.ValidatedSanitizedInput -- $_POST['directExport'] is an array, it's value sanitization is done at the time of accessing value. $response = et_code_snippets_library_export_item_data( $post_id, $cloud_content, $direct_export ); if ( ! $response ) { wp_send_json_error( 'Error: Wrong data provided.' ); } wp_send_json_success( $response ); } add_action( 'wp_ajax_et_code_snippets_library_export_item', 'et_code_snippets_library_export_item' ); /** * Download exported Code Snippets Library item. * * @return void */ function et_code_snippets_library_export_item_download() { et_core_security_check( et_core_portability_cap( 'et_code_snippets' ), 'et_code_snippets_library_export_item', 'nonce', '_GET' ); $id = ! empty( $_GET['id'] ) ? absint( $_GET['id'] ) : 0; $file_name = empty( $_GET['fileName'] ) ? 'code-snippet' : sanitize_file_name( $_GET['fileName'] ); header( 'Content-Description: File Transfer' ); header( 'Content-Disposition: attachment; filename="' . $file_name . '.json"' ); header( 'Content-Type: application/json' ); header( 'Pragma: no-cache' ); $transient = 'et_code_snippet_export_' . get_current_user_id() . '_' . $id; $export_content = get_transient( $transient ); delete_transient( $transient ); echo wp_json_encode( $export_content ); wp_die(); } add_action( 'wp_ajax_et_code_snippets_library_export_item_download', 'et_code_snippets_library_export_item_download' ); /** * Import Code Snippets Library item. * * @return void */ function et_code_snippets_library_import_item() { et_core_security_check( et_core_portability_cap( 'et_code_snippets' ), 'et_code_snippets_library_import_item', 'nonce' ); $response = et_code_snippets_library_import_item_data(); if ( ! $response ) { wp_send_json_error( 'Not a valid file.' ); } wp_send_json_success( $response ); } add_action( 'wp_ajax_et_code_snippets_library_import_item', 'et_code_snippets_library_import_item' ); /** * Update Local Library Tags and Categories. * * @return void */ function et_code_snippets_library_update_terms() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_update_terms', 'nonce' ); $payload = isset( $_POST['payload'] ) ? (array) $_POST['payload'] : array(); // phpcs:ignore ET.Sniffs.ValidatedSanitizedInput -- $_POST['payload'] is an array, it's value sanitization is done at the time of accessing value. if ( empty( $payload ) ) { wp_send_json_error( 'Payload is empty.' ); } $item_library_local = et_pb_code_snippets_library_local(); $response = $item_library_local->perform_terms_update( $payload ); wp_send_json_success( $response ); } add_action( 'wp_ajax_et_code_snippets_library_update_terms', 'et_code_snippets_library_update_terms' ); /** * Ajax :: Save code snippets to the local library. */ function et_code_snippets_library_save() { et_core_security_check( 'edit_posts', 'et_code_snippets_save_to_local_library' ); $post_id = et_save_item_to_local_library( $_POST ); if ( is_wp_error( $post_id ) ) { wp_send_json_error(); } wp_send_json_success(); } add_action( 'wp_ajax_et_code_snippets_library_save', 'et_code_snippets_library_save' ); /** * Ajax :: Get Cloud token. */ function et_code_snippets_library_get_token() { et_core_security_check( 'edit_posts', 'et_code_snippets_library_get_token', 'nonce' ); $access_token = get_transient( 'et_cloud_access_token' ); wp_send_json_success( array( 'accessToken' => $access_token, ) ); } add_action( 'wp_ajax_et_code_snippets_library_get_token', 'et_code_snippets_library_get_token' ); code-snippets/code-snippets-library.php 0000644 00000017732 15222641012 0014256 0 ustar 00 <?php /** * Code Snippets Library API. * * @package Divi */ // Exit if accessed directly. if ( ! defined( 'ABSPATH' ) ) { exit; } /** * Gets the terms list and processes it into desired format. * * @since 4.19.0 * * @param string $tax_name Term Name. * * @return array $terms_by_id */ function et_code_snippets_library_get_processed_terms( $tax_name ) { $terms = get_terms( $tax_name, [ 'hide_empty' => false ] ); $terms_by_id = []; if ( is_wp_error( $terms ) || empty( $terms ) ) { return []; } foreach ( $terms as $term ) { $term_id = $term->term_id; $terms_by_id[ $term_id ]['id'] = $term_id; $terms_by_id[ $term_id ]['name'] = $term->name; $terms_by_id[ $term_id ]['slug'] = $term->slug; $terms_by_id[ $term_id ]['count'] = $term->count; } return $terms_by_id; } /** * Processes item taxonomies for inclusion in the theme builder library UI items data. * * @since 4.19.0 * * @param WP_POST $post Unprocessed item. * @param object $item Currently processing item. * @param int $index The item's index position. * @param array[] $item_terms Processed items. * @param string $taxonomy_name Item name. * @param string $type Item type. * * @return void */ function et_code_snippets_library_process_item_taxonomy( $post, $item, $index, &$item_terms, $taxonomy_name, $type ) { $terms = wp_get_post_terms( $post->ID, $taxonomy_name ); if ( ! $terms ) { if ( 'category' === $type ) { $item->category_slug = 'uncategorized'; } return; } foreach ( $terms as $term ) { $term_name = et_core_intentionally_unescaped( $term->name, 'react_jsx' ); if ( ! isset( $item_terms[ $term->term_id ] ) ) { $item_terms[ $term->term_id ] = array( 'id' => $term->term_id, 'name' => $term_name, 'slug' => $term->slug, 'items' => array(), ); } $item_terms[ $term->term_id ]['items'][] = $index; if ( 'category' === $type ) { $item->categories[] = $term_name; } else { $item->tags[] = $term_name; } $item->{$type . '_ids'}[] = $term->term_id; if ( ! isset( $item->{$type . '_slug'} ) ) { $item->{$type . '_slug'} = $term->slug; } $id = get_post_meta( $post->ID, "_primary_{$taxonomy_name}", true ); if ( $id ) { // $id is a string, $term->term_id is an int. if ( $id === $term->term_id ) { // This is the primary term (used in the item URL). $item->{$type . '_slug'} = $term->slug; } } } } /** * Sanitize txonomies. * * @since 4.19.0 * * @param array $taxonomies Array of id for categories and tags. * * @return array Sanitized value. */ function et_code_snippets_library_sanitize_taxonomies( $taxonomies ) { if ( empty( $taxonomies ) ) { return array(); } return array_unique( array_map( 'intval', $taxonomies ) ); } /** * Get all terms of an item and merge any newly passed IDs with the list. * * @since 4.19.0 * * @param string $new_terms_list List of new terms. * @param array $taxonomies Taxonomies. * @param string $taxonomy_name Taxonomy name. * * @return array */ function et_code_snippets_library_create_and_get_all_item_terms( $new_terms_list, $taxonomies, $taxonomy_name ) { $new_names_array = explode( ',', $new_terms_list ); foreach ( $new_names_array as $new_name ) { if ( '' !== $new_name ) { $new_term = wp_insert_term( $new_name, $taxonomy_name ); if ( ! is_wp_error( $new_term ) ) { $taxonomies[] = $new_term['term_id']; } elseif ( ! empty( $new_term->error_data ) && ! empty( $new_term->error_data['term_exists'] ) ) { $taxonomies[] = $new_term->error_data['term_exists']; } } } return $taxonomies; } /** * Export the Code Snippets library item from cloud. * * @since 4.19.0 * * @param array $cloud_content Optional cloud content. * * @return array */ function et_code_snippets_library_export_cloud_item( $cloud_content ) { if ( ! current_user_can( 'edit_posts' ) ) { wp_die(); } $content = array( 'context' => 'et_code_snippet' ); $content['snippet_type'] = $cloud_content['snippet_type']; $content['data'] = $cloud_content['data']; return $content; } /** * Export the Code Snippets library item local item. * * @since 4.19.0 * * @param int $post_id Item ID. * * @return array */ function et_code_snippets_library_export_local_item( $post_id ) { if ( ! current_user_can( 'edit_post', $post_id ) ) { wp_die(); } $snippet = get_post( $post_id ); $snippet_type = current( wp_get_post_terms( $post_id, 'et_code_snippet_type' ) ); $content = array( 'context' => 'et_code_snippet' ); $content['snippet_type'] = $snippet_type->slug; $content['data'] = $snippet->post_content; return $content; } /** * Export the Code Snippets library item directly. * * @since 4.19.0 * @param array $direct_export Contain snippet-type and content. * * @return array */ function et_code_snippets_library_export_directly( $direct_export ) { if ( ! current_user_can( 'edit_posts' ) ) { wp_die(); } if ( ! trim( $direct_export['content'] ) ) { return false; } $content = array( 'context' => 'et_code_snippet' ); $content['snippet_type'] = $direct_export['snippet_type']; $content['data'] = stripslashes_deep( $direct_export['content'] ); return $content; } /** * Export the Code Snippets library item. * * @since 4.19.0 * * @param int $id Item ID. * @param array $cloud_content Optional cloud content. * @param array $direct_export Contain snippet-type and content. * * @return array */ function et_code_snippets_library_export_item_data( $id, $cloud_content, $direct_export ) { if ( ! current_user_can( 'edit_posts' ) ) { wp_die(); } if ( empty( $id ) ) { return false; } $id = absint( $id ); if ( empty( $direct_export ) ) { $export_content = empty( $cloud_content ) ? et_code_snippets_library_export_local_item( $id ) : et_code_snippets_library_export_cloud_item( $cloud_content ); } else { $export_content = et_code_snippets_library_export_directly( $direct_export ); } if ( empty( $export_content ) ) { return; } $transient = 'et_code_snippet_export_' . get_current_user_id() . '_' . $id; set_transient( $transient, $export_content, 60 * 60 * 24 ); return $export_content; } /** * Import the Code Snippets library item. * * @since 4.19.0 * * @return array */ function et_code_snippets_library_import_item_data() { if ( ! current_user_can( 'edit_posts' ) || ! isset( $_POST['fileData'] ) ) { // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Nonce verified in `et_builder_security_check` before calling this function. return false; } // phpcs:disable ET.Sniffs.ValidatedSanitizedInput.InputNotSanitized -- wp_insert_post function does sanitization. $file_data = $_POST['fileData']; // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Nonce verified in `et_builder_security_check` before calling this function. $file_name = sanitize_text_field( $file_data['title'] ); $file_content = isset( $_POST['fileContent'] ) ? json_decode( stripslashes( $_POST['fileContent'] ), true ) : ''; // phpcs:ignore WordPress.Security.NonceVerification.Missing -- Nonce verified in `et_builder_security_check` before calling this function. // phpcs:enable if ( ! isset( $file_data['type'] ) ) { return false; } $snippet = array( 'item_name' => $file_name, 'item_type' => $file_data['type'], 'content' => $file_content, ); return et_code_snippets_save_to_local_library( $snippet ); } /** * Save a code snippet to local library. * * @param array $item Item data. */ function et_code_snippets_save_to_local_library( $item ) { $_ = et_(); $item_name = sanitize_text_field( $_->array_get( $item, 'item_name', '' ) ); $content = $_->array_get( $item, 'content', '' ); $post_id = wp_insert_post( array( 'post_type' => ET_CODE_SNIPPET_POST_TYPE, 'post_status' => 'publish', 'post_title' => $item_name, 'post_content' => $content, ) ); et_local_library_set_item_taxonomy( $post_id, $item ); return $post_id; } code-snippets/code-snippets-app.php 0000644 00000011017 15222641012 0013360 0 ustar 00 <?php /** * Code Snippets App helpers. * * @since 4.19.0 * * @package Divi */ // Exit if accessed directly. if ( ! defined( 'ABSPATH' ) ) { exit; } /** * ET_Code_Snippets_App class. * * Nonces and i18n strings needed for Code Snippets Library Cloud app. * * @package Divi */ class ET_Code_Snippets_App { /** * Class instance. * * @var ET_Code_Snippets_App */ private static $_instance; /** * Get the class instance. * * @since 4.19.0 * * @return ET_Code_Snippets_App */ public static function instance() { if ( ! self::$_instance ) { self::$_instance = new self(); } return self::$_instance; } /** * Get Cloud Helpers. * * @return array Helpers. */ public static function get_cloud_helpers() { $role_capabilities = et_pb_get_role_settings(); $user_role = et_pb_get_current_user_role(); // phpcs:disable WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned, WordPress.Arrays.MultipleStatementAlignment.LongIndexSpaceBeforeDoubleArrow -- Aligned manually. return [ 'i18n' => [ 'library' => require ET_CORE_PATH . '/i18n/library.php' ], 'api' => admin_url( 'admin-ajax.php' ), 'capabilities' => isset( $role_capabilities[ $user_role ] ) ? $role_capabilities[ $user_role ] : array(), 'nonces' => [ 'et_code_snippets_library_get_items' => wp_create_nonce( 'et_code_snippets_library_get_items' ), 'et_code_snippets_library_get_item_content' => wp_create_nonce( 'et_code_snippets_library_get_item_content' ), 'et_code_snippets_library_update_item' => wp_create_nonce( 'et_code_snippets_library_update_item' ), 'et_code_snippets_library_toggle_item_location' => wp_create_nonce( 'et_code_snippets_library_toggle_item_location' ), 'et_code_snippets_library_export_item' => wp_create_nonce( 'et_code_snippets_library_export_item' ), 'et_code_snippets_library_import_item' => wp_create_nonce( 'et_code_snippets_library_import_item' ), 'et_code_snippets_library_save_item_content' => wp_create_nonce( 'et_code_snippets_library_save_item_content' ), 'et_code_snippets_library_update_terms' => wp_create_nonce( 'et_code_snippets_library_update_terms' ), 'et_code_snippets_library_get_token' => wp_create_nonce( 'et_code_snippets_library_get_token' ), 'et_code_snippets_save_to_local_library' => wp_create_nonce( 'et_code_snippets_save_to_local_library' ), ], ]; // phpcs:enable } /** * Load the Cloud App scripts. * * @param string $enqueue_prod_scripts Flag to force Production scripts. * @param bool $skip_react_loading Flag to skip react loading. * * @since 4.19.0 * * @return void */ public static function load_js( $enqueue_prod_scripts = true, $skip_react_loading = false ) { // phpcs:disable ET.Sniffs.ValidVariableName.VariableNotSnakeCase -- Following the pattern found in /cloud. $CORE_VERSION = defined( 'ET_CORE_VERSION' ) ? ET_CORE_VERSION : ''; $ET_DEBUG = defined( 'ET_DEBUG' ) && ET_DEBUG; $DEBUG = $ET_DEBUG; $home_url = wp_parse_url( get_site_url() ); $build_dir_uri = ET_CORE_URL . 'build'; $common_scripts = ET_COMMON_URL . '/scripts'; $cache_buster = $DEBUG ? mt_rand() / mt_getrandmax() : $CORE_VERSION; // phpcs:ignore WordPress.WP.AlternativeFunctions.rand_mt_rand -- mt_rand() should do for cache busting. $asset_path = ET_CORE_PATH . 'build/et-core-app.bundle.js'; if ( file_exists( $asset_path ) ) { wp_enqueue_style( 'et-code-snippets-styles', "{$build_dir_uri}/et-core-app.bundle.css", [], (string) $cache_buster ); } wp_enqueue_script( 'es6-promise', "{$common_scripts}/es6-promise.auto.min.js", [], '4.2.2', true ); $BUNDLE_DEPS = [ 'jquery', 'react', 'react-dom', 'es6-promise', ]; if ( $DEBUG || $enqueue_prod_scripts || file_exists( $asset_path ) ) { $BUNDLE_URI = ! file_exists( $asset_path ) ? "{$home_url['scheme']}://{$home_url['host']}:31499/et-core-app.bundle.js" : "{$build_dir_uri}/et-core-app.bundle.js"; // Skip the React loading if we already have React ( Gutenberg editor for example ) to avoid conflicts. if ( ! $skip_react_loading ) { if ( function_exists( 'et_fb_enqueue_react' ) ) { et_fb_enqueue_react(); } } wp_enqueue_script( 'et-code-snippets-app', $BUNDLE_URI, $BUNDLE_DEPS, (string) $cache_buster, true ); wp_localize_script( 'et-code-snippets-app', 'et_code_snippets_data', self::get_cloud_helpers() ); } } } ET_Code_Snippets_App::instance(); // phpcs:enable _metadata.php 0000644 00000037674 15222641012 0007210 0 ustar 00 <?php /* ==================================================================== * ----->>> This file is automatically generated. DO NOT EDIT! <<<----- * ==================================================================== */ $metadata = '{"groups":{"api":{"path":"components/api","slug":"API","init":"components/api/init.php","members":["ElegantThemes","OAuthHelper","Service"]},"api/email":{"path":"components/api/email","slug":"API_Email","init":"components/api/email/init.php","members":["ActiveCampaign","Aweber","CampaignMonitor","ConstantContact","ConvertKit","Emma","Feedblitz","Fields","FluentCRM","GetResponse","HubSpot","iContact","Infusionsoft","MadMimi","MailChimp","MailerLite","MailPoet","Mailster","Ontraport","Provider","Providers","SalesForce","SendinBlue"],"name_field_only":{"aweber":"Aweber","campaign_monitor":"CampaignMonitor","convertkit":"ConvertKit","getresponse":"GetResponse"}},"api/social":{"path":"components/api/social","slug":"API_Social","init":"","members":["Network"]},"api/spam":{"path":"components/api/spam","slug":"API_Spam","init":"components/api/spam/init.php","members":["SpamProvider","SpamProviders","ReCaptcha"]},"cache":{"path":"components/cache","slug":"Cache","init":"components/cache/init.php","members":["Directory","File"]},"data":{"path":"components/data","slug":"Data","init":"components/data/init.php","members":["ScriptReplacer","Utils"]},"lib":{"path":"components/lib","slug":"LIB","init":"","members":["BluehostCache","SilentThemeUpgraderSkin","WPHttp","OAuthBase","OAuthUtil","OAuthSignatureMethod","OAuthHMACSHA1","OAuthConsumer","OAuthToken","OAuthRequest"]},"mu-plugins":{"path":"components/mu-plugins","slug":"Mu-plugins","init":"","members":["SupportCenterSafeModeDisableChildThemes","SupportCenterSafeModeDisablePlugins"]},"post":{"path":"components/post","slug":"Post","init":"","members":["Object","Query","Taxonomy","Type"]}},"names":["ElegantThemes","ActiveCampaign","Aweber","CampaignMonitor","ConstantContact","ConvertKit","Emma","Feedblitz","Fields","FluentCRM","GetResponse","HubSpot","iContact","Infusionsoft","MadMimi","MailChimp","MailerLite","MailPoet","Mailster","Ontraport","SalesForce","SendinBlue","OAuthHelper","Service","Network","EmailProvider","SpamProvider","EmailProviders","SpamProviders","ReCaptcha","Cache","Directory","File","CompatibilityWarning","ScriptReplacer","Utils","HTTPInterface","BluehostCache","SilentThemeUpgraderSkin","WPHttp","Logger","SupportCenterSafeModeDisableChildThemes","SupportCenterSafeModeDisablePlugins","PageResource","Portability","Object","Query","Taxonomy","Type","SupportCenter","SupportCenterMUAutoloader","Updates","VersionRollback","OAuthBase","OAuthUtil","OAuthSignatureMethod","OAuthHMACSHA1","OAuthConsumer","OAuthToken","OAuthRequest"],"slugs":["elegantthemes","activecampaign","aweber","campaign_monitor","constant_contact","convertkit","emma","feedblitz","fields","fluentcrm","getresponse","hubspot","icontact","infusionsoft","madmimi","mailchimp","mailerlite","mailpoet","mailster","ontraport","salesforce","sendinblue","oauthhelper","service","network","email_provider","spam_provider","email_providers","spam_providers","recaptcha","cache","directory","file","compatibilitywarning","scriptreplacer","utils","httpinterface","bluehostcache","silentthemeupgraderskin","wphttp","logger","supportcentersafemodedisablechildthemes","supportcentersafemodedisableplugins","pageresource","portability","object","query","taxonomy","type","supportcenter","supportcentermuautoloader","updates","versionrollback","oauthbase","oauthutil","oauthsignaturemethod","oauthhmacsha1","oauthconsumer","oauthtoken","oauthrequest"],"ElegantThemes":"ET_Core_API_ElegantThemes","elegantthemes":"ET_Core_API_ElegantThemes","ET_Core_API_ElegantThemes":{"file":"components/api/ElegantThemes.php","groups":["api"],"name":"ElegantThemes","slug":"elegantthemes"},"ActiveCampaign":"ET_Core_API_Email_ActiveCampaign","activecampaign":"ET_Core_API_Email_ActiveCampaign","ET_Core_API_Email_ActiveCampaign":{"file":"components/api/email/ActiveCampaign.php","groups":["api","api/email"],"name":"ActiveCampaign","slug":"activecampaign"},"Aweber":"ET_Core_API_Email_Aweber","aweber":"ET_Core_API_Email_Aweber","ET_Core_API_Email_Aweber":{"file":"components/api/email/Aweber.php","groups":["api","api/email"],"name":"Aweber","slug":"aweber"},"CampaignMonitor":"ET_Core_API_Email_CampaignMonitor","campaign_monitor":"ET_Core_API_Email_CampaignMonitor","ET_Core_API_Email_CampaignMonitor":{"file":"components/api/email/CampaignMonitor.php","groups":["api","api/email"],"name":"CampaignMonitor","slug":"campaign_monitor"},"ConstantContact":"ET_Core_API_Email_ConstantContact","constant_contact":"ET_Core_API_Email_ConstantContact","ET_Core_API_Email_ConstantContact":{"file":"components/api/email/ConstantContact.php","groups":["api","api/email"],"name":"ConstantContact","slug":"constant_contact"},"ConvertKit":"ET_Core_API_Email_ConvertKit","convertkit":"ET_Core_API_Email_ConvertKit","ET_Core_API_Email_ConvertKit":{"file":"components/api/email/ConvertKit.php","groups":["api","api/email"],"name":"ConvertKit","slug":"convertkit"},"Emma":"ET_Core_API_Email_Emma","emma":"ET_Core_API_Email_Emma","ET_Core_API_Email_Emma":{"file":"components/api/email/Emma.php","groups":["api","api/email"],"name":"Emma","slug":"emma"},"Feedblitz":"ET_Core_API_Email_Feedblitz","feedblitz":"ET_Core_API_Email_Feedblitz","ET_Core_API_Email_Feedblitz":{"file":"components/api/email/Feedblitz.php","groups":["api","api/email"],"name":"Feedblitz","slug":"feedblitz"},"Fields":"ET_Core_API_Email_Fields","fields":"ET_Core_API_Email_Fields","ET_Core_API_Email_Fields":{"file":"components/api/email/Fields.php","groups":["api","api/email"],"name":"Fields","slug":"fields"},"FluentCRM":"ET_Core_API_Email_FluentCRM","fluentcrm":"ET_Core_API_Email_FluentCRM","ET_Core_API_Email_FluentCRM":{"file":"components/api/email/FluentCRM.php","groups":["api","api/email"],"name":"FluentCRM","slug":"fluentcrm"},"GetResponse":"ET_Core_API_Email_GetResponse","getresponse":"ET_Core_API_Email_GetResponse","ET_Core_API_Email_GetResponse":{"file":"components/api/email/GetResponse.php","groups":["api","api/email"],"name":"GetResponse","slug":"getresponse"},"HubSpot":"ET_Core_API_Email_HubSpot","hubspot":"ET_Core_API_Email_HubSpot","ET_Core_API_Email_HubSpot":{"file":"components/api/email/HubSpot.php","groups":["api","api/email"],"name":"HubSpot","slug":"hubspot"},"iContact":"ET_Core_API_Email_iContact","icontact":"ET_Core_API_Email_iContact","ET_Core_API_Email_iContact":{"file":"components/api/email/iContact.php","groups":["api","api/email"],"name":"iContact","slug":"icontact"},"Infusionsoft":"ET_Core_API_Email_Infusionsoft","infusionsoft":"ET_Core_API_Email_Infusionsoft","ET_Core_API_Email_Infusionsoft":{"file":"components/api/email/Infusionsoft.php","groups":["api","api/email"],"name":"Infusionsoft","slug":"infusionsoft"},"MadMimi":"ET_Core_API_Email_MadMimi","madmimi":"ET_Core_API_Email_MadMimi","ET_Core_API_Email_MadMimi":{"file":"components/api/email/MadMimi.php","groups":["api","api/email"],"name":"MadMimi","slug":"madmimi"},"MailChimp":"ET_Core_API_Email_MailChimp","mailchimp":"ET_Core_API_Email_MailChimp","ET_Core_API_Email_MailChimp":{"file":"components/api/email/MailChimp.php","groups":["api","api/email"],"name":"MailChimp","slug":"mailchimp"},"MailerLite":"ET_Core_API_Email_MailerLite","mailerlite":"ET_Core_API_Email_MailerLite","ET_Core_API_Email_MailerLite":{"file":"components/api/email/MailerLite.php","groups":["api","api/email"],"name":"MailerLite","slug":"mailerlite"},"MailPoet":"ET_Core_API_Email_MailPoet","mailpoet":"ET_Core_API_Email_MailPoet","ET_Core_API_Email_MailPoet":{"file":"components/api/email/MailPoet.php","groups":["api","api/email"],"name":"MailPoet","slug":"mailpoet"},"Mailster":"ET_Core_API_Email_Mailster","mailster":"ET_Core_API_Email_Mailster","ET_Core_API_Email_Mailster":{"file":"components/api/email/Mailster.php","groups":["api","api/email"],"name":"Mailster","slug":"mailster"},"Ontraport":"ET_Core_API_Email_Ontraport","ontraport":"ET_Core_API_Email_Ontraport","ET_Core_API_Email_Ontraport":{"file":"components/api/email/Ontraport.php","groups":["api","api/email"],"name":"Ontraport","slug":"ontraport"},"ET_Core_API_Email_Provider":{"file":"components/api/email/Provider.php","groups":["api","api/email"],"name":"Provider","slug":"provider"},"ET_Core_API_Email_Providers":{"file":"components/api/email/Providers.php","groups":["api","api/email"],"name":"Providers","slug":"providers"},"SalesForce":"ET_Core_API_Email_SalesForce","salesforce":"ET_Core_API_Email_SalesForce","ET_Core_API_Email_SalesForce":{"file":"components/api/email/SalesForce.php","groups":["api","api/email"],"name":"SalesForce","slug":"salesforce"},"SendinBlue":"ET_Core_API_Email_SendinBlue","sendinblue":"ET_Core_API_Email_SendinBlue","ET_Core_API_Email_SendinBlue":{"file":"components/api/email/SendinBlue.php","groups":["api","api/email"],"name":"SendinBlue","slug":"sendinblue"},"OAuthHelper":"ET_Core_API_OAuthHelper","oauthhelper":"ET_Core_API_OAuthHelper","ET_Core_API_OAuthHelper":{"file":"components/api/OAuthHelper.php","groups":["api"],"name":"OAuthHelper","slug":"oauthhelper"},"Service":"ET_Core_API_Service","service":"ET_Core_API_Service","ET_Core_API_Service":{"file":"components/api/Service.php","groups":["api"],"name":"Service","slug":"service"},"Network":"ET_Core_API_Social_Network","network":"ET_Core_API_Social_Network","ET_Core_API_Social_Network":{"file":"components/api/social/Network.php","groups":["api","api/social"],"name":"Network","slug":"network"},"EmailProvider":"ET_Core_API_Email_Provider","email_provider":"ET_Core_API_Email_Provider","SpamProvider":"ET_Core_API_Spam_Provider","spam_provider":"ET_Core_API_Spam_Provider","ET_Core_API_Spam_Provider":{"file":"components/api/spam/Provider.php","groups":["api","api/spam"],"name":"SpamProvider","slug":"spam_provider"},"EmailProviders":"ET_Core_API_Email_Providers","email_providers":"ET_Core_API_Email_Providers","SpamProviders":"ET_Core_API_Spam_Providers","spam_providers":"ET_Core_API_Spam_Providers","ET_Core_API_Spam_Providers":{"file":"components/api/spam/Providers.php","groups":["api","api/spam"],"name":"SpamProviders","slug":"spam_providers"},"ReCaptcha":"ET_Core_API_Spam_ReCaptcha","recaptcha":"ET_Core_API_Spam_ReCaptcha","ET_Core_API_Spam_ReCaptcha":{"file":"components/api/spam/ReCaptcha.php","groups":["api","api/spam"],"name":"ReCaptcha","slug":"recaptcha"},"Cache":"ET_Core_Cache","cache":"ET_Core_Cache","ET_Core_Cache":{"file":"components/Cache.php","groups":[],"name":"Cache","slug":"cache"},"Directory":"ET_Core_Cache_Directory","directory":"ET_Core_Cache_Directory","ET_Core_Cache_Directory":{"file":"components/cache/Directory.php","groups":["cache"],"name":"Directory","slug":"directory"},"File":"ET_Core_Cache_File","file":"ET_Core_Cache_File","ET_Core_Cache_File":{"file":"components/cache/File.php","groups":["cache"],"name":"File","slug":"file"},"CompatibilityWarning":"ET_Core_CompatibilityWarning","compatibilitywarning":"ET_Core_CompatibilityWarning","ET_Core_CompatibilityWarning":{"file":"components/CompatibilityWarning.php","groups":[],"name":"CompatibilityWarning","slug":"compatibilitywarning"},"ScriptReplacer":"ET_Core_Data_ScriptReplacer","scriptreplacer":"ET_Core_Data_ScriptReplacer","ET_Core_Data_ScriptReplacer":{"file":"components/data/ScriptReplacer.php","groups":["data"],"name":"ScriptReplacer","slug":"scriptreplacer"},"Utils":"ET_Core_Data_Utils","utils":"ET_Core_Data_Utils","ET_Core_Data_Utils":{"file":"components/data/Utils.php","groups":["data"],"name":"Utils","slug":"utils"},"HTTPInterface":"ET_Core_HTTPInterface","httpinterface":"ET_Core_HTTPInterface","ET_Core_HTTPInterface":{"file":"components/HTTPInterface.php","groups":[],"name":"HTTPInterface","slug":"httpinterface"},"BluehostCache":"ET_Core_LIB_BluehostCache","bluehostcache":"ET_Core_LIB_BluehostCache","ET_Core_LIB_BluehostCache":{"file":"components/lib/BluehostCache.php","groups":["lib"],"name":"BluehostCache","slug":"bluehostcache"},"OAuth":"ET_Core_LIB_OAuth","oauth":"ET_Core_LIB_OAuth","SilentThemeUpgraderSkin":"ET_Core_LIB_SilentThemeUpgraderSkin","silentthemeupgraderskin":"ET_Core_LIB_SilentThemeUpgraderSkin","ET_Core_LIB_SilentThemeUpgraderSkin":{"file":"components/lib/SilentThemeUpgraderSkin.php","groups":["lib"],"name":"SilentThemeUpgraderSkin","slug":"silentthemeupgraderskin"},"WPHttp":"ET_Core_LIB_WPHttp","wphttp":"ET_Core_LIB_WPHttp","ET_Core_LIB_WPHttp":{"file":"components/lib/WPHttp.php","groups":["lib"],"name":"WPHttp","slug":"wphttp"},"Logger":"ET_Core_Logger","logger":"ET_Core_Logger","ET_Core_Logger":{"file":"components/Logger.php","groups":[],"name":"Logger","slug":"logger"},"SupportCenterSafeModeDisableChildThemes":"ET_Core_Mu-plugins_SupportCenterSafeModeDisableChildThemes","supportcentersafemodedisablechildthemes":"ET_Core_Mu-plugins_SupportCenterSafeModeDisableChildThemes","ET_Core_Mu-plugins_SupportCenterSafeModeDisableChildThemes":{"file":"components/mu-plugins/SupportCenterSafeModeDisableChildThemes.php","groups":["mu-plugins"],"name":"SupportCenterSafeModeDisableChildThemes","slug":"supportcentersafemodedisablechildthemes"},"SupportCenterSafeModeDisablePlugins":"ET_Core_Mu-plugins_SupportCenterSafeModeDisablePlugins","supportcentersafemodedisableplugins":"ET_Core_Mu-plugins_SupportCenterSafeModeDisablePlugins","ET_Core_Mu-plugins_SupportCenterSafeModeDisablePlugins":{"file":"components/mu-plugins/SupportCenterSafeModeDisablePlugins.php","groups":["mu-plugins"],"name":"SupportCenterSafeModeDisablePlugins","slug":"supportcentersafemodedisableplugins"},"PageResource":"ET_Core_PageResource","pageresource":"ET_Core_PageResource","ET_Core_PageResource":{"file":"components/PageResource.php","groups":[],"name":"PageResource","slug":"pageresource"},"Portability":"ET_Core_Portability","portability":"ET_Core_Portability","ET_Core_Portability":{"file":"components/Portability.php","groups":[],"name":"Portability","slug":"portability"},"Object":"ET_Core_Post_Object","object":"ET_Core_Post_Object","ET_Core_Post_Object":{"file":"components/post/Object.php","groups":["post"],"name":"Object","slug":"object"},"Query":"ET_Core_Post_Query","query":"ET_Core_Post_Query","ET_Core_Post_Query":{"file":"components/post/Query.php","groups":["post"],"name":"Query","slug":"query"},"Taxonomy":"ET_Core_Post_Taxonomy","taxonomy":"ET_Core_Post_Taxonomy","ET_Core_Post_Taxonomy":{"file":"components/post/Taxonomy.php","groups":["post"],"name":"Taxonomy","slug":"taxonomy"},"Type":"ET_Core_Post_Type","type":"ET_Core_Post_Type","ET_Core_Post_Type":{"file":"components/post/Type.php","groups":["post"],"name":"Type","slug":"type"},"SupportCenter":"ET_Core_SupportCenter","supportcenter":"ET_Core_SupportCenter","ET_Core_SupportCenter":{"file":"components/SupportCenter.php","groups":[],"name":"SupportCenter","slug":"supportcenter"},"SupportCenterMUAutoloader":"ET_Core_SupportCenterMUAutoloader","supportcentermuautoloader":"ET_Core_SupportCenterMUAutoloader","ET_Core_SupportCenterMUAutoloader":{"file":"components/SupportCenterMUAutoloader.php","groups":[],"name":"SupportCenterMUAutoloader","slug":"supportcentermuautoloader"},"Updates":"ET_Core_Updates","updates":"ET_Core_Updates","ET_Core_Updates":{"file":"components/Updates.php","groups":[],"name":"Updates","slug":"updates"},"VersionRollback":"ET_Core_VersionRollback","versionrollback":"ET_Core_VersionRollback","ET_Core_VersionRollback":{"file":"components/VersionRollback.php","groups":[],"name":"VersionRollback","slug":"versionrollback"},"ET_Core_LIB_OAuthBase":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"},"ET_Core_LIB_OAuthUtil":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"},"ET_Core_LIB_OAuthSignatureMethod":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"},"ET_Core_LIB_OAuthHMACSHA1":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"},"ET_Core_LIB_OAuthConsumer":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"},"ET_Core_LIB_OAuthToken":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"},"ET_Core_LIB_OAuthRequest":{"file":"components/lib/OAuth.php","groups":["lib"],"name":"OAuth","slug":"oauth"}}'; wp_functions.php 0000644 00000021473 15222641012 0007775 0 ustar 00 <?php if ( ! function_exists( '_sanitize_text_fields' ) ): /** * Internal helper function to sanitize a string from user input or from the db * * @since 4.7.0 * @access private * * @param string $str String to sanitize. * @param bool $keep_newlines optional Whether to keep newlines. Default: false. * @return string Sanitized string. */ function _sanitize_text_fields( $str, $keep_newlines = false ) { $filtered = wp_check_invalid_utf8( $str ); if ( strpos( $filtered, '<' ) !== false ) { $filtered = wp_pre_kses_less_than( $filtered ); // This will strip extra whitespace for us. $filtered = wp_strip_all_tags( $filtered, false ); // Use html entities in a special case to make sure no later // newline stripping stage could lead to a functional tag $filtered = str_replace( "<\n", "<\n", $filtered ); } if ( ! $keep_newlines ) { $filtered = preg_replace( '/[\r\n\t ]+/', ' ', $filtered ); } $filtered = trim( $filtered ); $found = false; while ( preg_match( '/%[a-f0-9]{2}/i', $filtered, $match ) ) { $filtered = str_replace( $match[0], '', $filtered ); $found = true; } if ( $found ) { // Strip out the whitespace that may now exist after removing the octets. $filtered = trim( preg_replace( '/ +/', ' ', $filtered ) ); } return $filtered; } endif; if ( ! function_exists( 'get_site' ) ): /** * Retrieves site data given a site ID or site object. * * Site data will be cached and returned after being passed through a filter. * If the provided site is empty, the current site global will be used. * * @since 4.6.0 * * @param WP_Site|int|null $site Optional. Site to retrieve. Default is the current site. * @return WP_Site|null The site object or null if not found. */ function get_site( $site = null ) { if ( empty( $site ) ) { $site = get_current_blog_id(); } if ( $site instanceof WP_Site ) { $_site = $site; } elseif ( is_object( $site ) ) { $_site = new WP_Site( $site ); } else { $_site = WP_Site::get_instance( $site ); } if ( ! $_site ) { return null; } /** * Fires after a site is retrieved. * * @since 4.6.0 * * @param WP_Site $_site Site data. */ $_site = apply_filters( 'get_site', $_site ); return $_site; } endif; if ( ! function_exists( 'sanitize_textarea_field' ) ): /** * Sanitizes a multiline string from user input or from the database. * * The function is like sanitize_text_field(), but preserves * new lines (\n) and other whitespace, which are legitimate * input in textarea elements. * * @see sanitize_text_field() * * @since 4.7.0 * * @param string $str String to sanitize. * @return string Sanitized string. */ function sanitize_textarea_field( $str ) { $filtered = _sanitize_text_fields( $str, true ); /** * Filters a sanitized textarea field string. * * @since 4.7.0 * * @param string $filtered The sanitized string. * @param string $str The string prior to being sanitized. */ return apply_filters( 'sanitize_textarea_field', $filtered, $str ); } endif; if ( ! function_exists( 'wp_doing_ajax' ) ): function wp_doing_ajax() { /** * Filters whether the current request is an Ajax request. * * @since 4.7.0 * * @param bool $wp_doing_ajax Whether the current request is an Ajax request. */ return apply_filters( 'wp_doing_ajax', defined( 'DOING_AJAX' ) && DOING_AJAX ); } endif; if ( ! function_exists( 'wp_doing_cron' ) ): function wp_doing_cron() { /** * Filters whether the current request is a WordPress cron request. * * @since 4.8.0 * * @param bool $wp_doing_cron Whether the current request is a WordPress cron request. */ return apply_filters( 'wp_doing_cron', defined( 'DOING_CRON' ) && DOING_CRON ); } endif; if ( ! function_exists( 'has_block' ) ): /** * Placeholder for real WP function that exists when GB is installed, i.e. WP >= 5.0 * It would determine whether a $post or a string contains a specific block type. * * @see has_block() * * @since 4.2 * * @return bool forced false result. */ function has_block() { return false; } endif; if ( ! function_exists( 'wp_get_default_update_php_url' ) ) : /** * Gets the default URL to learn more about updating the PHP version the site is running on. * * Do not use this function to retrieve this URL. Instead, use {@see wp_get_update_php_url()} when relying on the URL. * This function does not allow modifying the returned URL, and is only used to compare the actually used URL with the * default one. * * @since 5.1.0 * @access private * * @return string Default URL to learn more about updating PHP. */ function wp_get_default_update_php_url() { return _x( 'https://wordpress.org/support/update-php/', 'localized PHP upgrade information page' ); } endif; if ( ! function_exists( 'wp_get_update_php_url' ) ) : /** * Gets the URL to learn more about updating the PHP version the site is running on. * * This URL can be overridden by specifying an environment variable `WP_UPDATE_PHP_URL` or by using the * {@see 'wp_update_php_url'} filter. Providing an empty string is not allowed and will result in the * default URL being used. Furthermore the page the URL links to should preferably be localized in the * site language. * * @since 5.1.0 * * @return string URL to learn more about updating PHP. */ function wp_get_update_php_url() { $default_url = wp_get_default_update_php_url(); $update_url = $default_url; if ( false !== getenv( 'WP_UPDATE_PHP_URL' ) ) { $update_url = getenv( 'WP_UPDATE_PHP_URL' ); } /** * Filters the URL to learn more about updating the PHP version the site is running on. * * Providing an empty string is not allowed and will result in the default URL being used. Furthermore * the page the URL links to should preferably be localized in the site language. * * @since 5.1.0 * * @param string $update_url URL to learn more about updating PHP. */ $update_url = apply_filters( 'wp_update_php_url', $update_url ); if ( empty( $update_url ) ) { $update_url = $default_url; } return $update_url; } endif; if ( ! function_exists( 'wp_get_update_php_annotation' ) ) : /** * Returns the default annotation for the web hosting altering the "Update PHP" page URL. * * This function is to be used after {@see wp_get_update_php_url()} to return a consistent * annotation if the web host has altered the default "Update PHP" page URL. * * @since 5.2.0 * * @return string Update PHP page annotation. An empty string if no custom URLs are provided. */ function wp_get_update_php_annotation() { $update_url = wp_get_update_php_url(); $default_url = wp_get_default_update_php_url(); if ( $update_url === $default_url ) { return ''; } $annotation = sprintf( /* translators: %s: Default Update PHP page URL. */ __( 'This resource is provided by your web host, and is specific to your site. For more information, <a href="%s" target="_blank">see the official WordPress documentation</a>.' ), esc_url( $default_url ) ); return $annotation; } endif; if ( ! function_exists( 'wp_update_php_annotation' ) ) : /** * Prints the default annotation for the web host altering the "Update PHP" page URL. * * This function is to be used after {@see wp_get_update_php_url()} to display a consistent * annotation if the web host has altered the default "Update PHP" page URL. * * @since 5.1.0 * @since 5.2.0 Added the `$before` and `$after` parameters. * * @param string $before Markup to output before the annotation. Default `<p class="description">`. * @param string $after Markup to output after the annotation. Default `</p>`. */ function wp_update_php_annotation( $before = '<p class="description">', $after = '</p>' ) { $annotation = wp_get_update_php_annotation(); if ( $annotation ) { echo et_core_intentionally_unescaped( $before . $annotation . $after, 'html' ); } } endif; if ( ! function_exists( 'is_wp_version_compatible' ) ) : /** * Checks compatibility with the current WordPress version. * * @since 5.2.0 * * @param string $required Minimum required WordPress version. * @return bool True if required version is compatible or empty, false if not. */ function is_wp_version_compatible( $required ) { return empty( $required ) || version_compare( get_bloginfo( 'version' ), $required, '>=' ); } endif; if ( ! function_exists( 'is_php_version_compatible' ) ) : /** * Checks compatibility with the current PHP version. * * @since 5.2.0 * * @param string $required Minimum required PHP version. * @return bool True if required version is compatible or empty, false if not. */ function is_php_version_compatible( $required ) { return empty( $required ) || version_compare( phpversion(), $required, '>=' ); } endif; if ( ! function_exists( 'wp_body_open' ) ) : /** * Fire the wp_body_open action. * * See {@see 'wp_body_open'}. * * @since 5.2.0 */ function wp_body_open() { /** * Triggered after the opening body tag. * * @since 5.2.0 */ do_action( 'wp_body_open' ); } endif; components/CompatibilityWarning.php 0000644 00000210763 15222641012 0013605 0 ustar 00 <?php /** * ET_Core_CompatibilityWarning class file. * * @class ET_Core_CompatibilityWarning * @package Core */ if ( ! defined( 'ABSPATH' ) ) { exit; // Exit if accessed directly. } if ( ! class_exists( 'ET_Core_CompatibilityWarning' ) ) : /** * Plugin & theme compatibility warning system backported from WP 5.5. * * This system is only intended for users who use Divi theme with WP 5.4.2 below and Divi * Builder plugin with WP 5.2 below. There are some areas where it overrides or modifies * the themes & plugins management template to show warnings when the current WP and/or * PHP versions doesn't work with the current and/or upcoming ET plugins/themes. * * A. Update Core * 1. Plugins list section. * 2. Themes list section. * * B. Manage Themes * On each of incompatible themes, shows warning and disables Activate & Live Preview * buttons when the theme is not activated yet. * 1. Themes List (tmpl-theme). * 2. Theme Details (tmpl-theme-single). * * C. Theme Customizer * On each of incompatible themes, shows warning and disables Live Preview button when * the theme is not activated yet. In addition, disable Publish button for the current * active theme. * 1. Themes List (tmpl-theme). * 2. Theme Details (tmpl-theme-single). * 3. Publish Button for current active theme. * * D. Plugins List * 1. Plugins List via `after_plugin_row_` action hook. * 2. Plugin activation warning. ET plugins that want to use this warning should * register `maybe_deactivate_incompatible_plugin()` on their activation hook. * * @since 4.7.0 */ class ET_Core_CompatibilityWarning { /** * Class instance. * * @var ET_Core_CompatibilityWarning */ public static $instance_class; /** * WP version where the official warning system is introduced. * * @var string */ public $supported_wp_version = array( 'plugin' => '5.3.0', 'theme' => '5.5.0', ); /** * Class constructor. */ public function __construct() { global $wp_version; // Ensure the system is loaded on lower version of supported version. if ( version_compare( $wp_version, $this->supported_wp_version[ ET_CORE_TYPE ], '>=' ) ) { return; } add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts' ) ); // A. Update Core - Overrides plugins and themes updates table body. add_action( 'admin_print_footer_scripts-update-core.php', array( $this, 'overrides_update_core_plugins_table_body' ) ); add_action( 'admin_print_footer_scripts-update-core.php', array( $this, 'overrides_update_core_themes_table_body' ) ); // B. Manage Themes - Overrides themes list & details templates. add_filter( 'wp_prepare_themes_for_js', array( $this, 'set_theme_additional_properties' ) ); add_action( 'admin_print_footer_scripts-themes.php', array( $this, 'overrides_tmpl_theme' ) ); // C. Theme Customizer - Overrides themes list & details templates. add_action( 'customize_controls_print_footer_scripts', array( $this, 'overrides_tmpl_customize_control_theme_content' ) ); // D. Plugins - Overrides current plugin list. Default priority is 20. add_action( 'load-plugins.php', array( $this, 'overrides_plugins_table_rows' ), 21 ); } /** * Returns instance of the class. * * @since 4.7.0 * * @return ET_Core_CompatibilityWarning */ public static function instance() { if ( ! isset( self::$instance_class ) ) { self::$instance_class = new self(); } return self::$instance_class; } /** * Set theme additional properties before it's rendered on Manage Themes page. * * @since 4.7.0 * * @param array $prepared_themes List of available themes. * * @return array */ public function set_theme_additional_properties( $prepared_themes ) { // Bail early if the $prepared_themes is empty. if ( empty( $prepared_themes ) ) { return $prepared_themes; } // 1. Get available themes update. $theme_updates = array(); if ( current_user_can( 'update_themes' ) ) { $updates_themes_transient = get_site_transient( 'update_themes' ); if ( isset( $updates_themes_transient->response ) ) { $theme_updates = $updates_themes_transient->response; } } // 2. Assign compatibility properties. $themes = $prepared_themes; foreach ( $themes as $theme_slug => $theme_info ) { // Ensure style.css file exist. $theme_root = get_theme_root( $theme_slug ); $theme_file = "{$theme_root}/{$theme_slug}/style.css"; if ( ! file_exists( $theme_file ) ) { continue; } // Get WP & PHP compatibility info. $theme_headers = get_file_data( $theme_file, array( 'RequiresWP' => 'Requires at least', 'RequiresPHP' => 'Requires PHP', ), 'theme' ); $require_wp = et_()->array_get( $theme_headers, 'RequiresWP', null ); $require_php = et_()->array_get( $theme_headers, 'RequiresPHP', null ); $update_requires_wp = et_()->array_get( $theme_updates, array( $theme_slug, 'requires' ), null ); $update_requires_php = et_()->array_get( $theme_updates, array( $theme_slug, 'requires_php' ), null ); $compatibility_properties = array( 'compatibleWP' => is_wp_version_compatible( $require_wp ), 'compatiblePHP' => is_php_version_compatible( $require_php ), 'updateResponse' => array( 'compatibleWP' => is_wp_version_compatible( $update_requires_wp ), 'compatiblePHP' => is_php_version_compatible( $update_requires_php ), ), ); $prepared_themes[ $theme_slug ] = array_merge( $prepared_themes[ $theme_slug ], $compatibility_properties ); } return $prepared_themes; } /** * Get plugins data for Update Core page. * * The data processing is backported from WP 5.5 with few modification. * * @see {list_plugin_updates()} of WP 5.5 * * @since 4.7.0 * * @return array */ public function get_update_core_plugins_data() { $plugin_updates = get_plugin_updates(); $plugin_processed = array(); // Bail early if there is no plugin updates. if ( empty( $plugin_updates ) ) { return array(); } foreach ( $plugin_updates as $plugin_file => $plugin_data ) { // reason: The properties come from WP plugin data. // phpcs:disable ET.Sniffs.ValidVariableName.UsedPropertyNotSnakeCase $plugin_name = $plugin_data->Name; $plugin_version = $plugin_data->Version; // phpcs:enable // a. Get current and update WP version. $wp_version = get_bloginfo( 'version' ); $cur_wp_version = preg_replace( '/-.*$/', '', $wp_version ); $core_updates = get_core_updates(); if ( ! isset( $core_updates[0]->response ) || 'latest' === $core_updates[0]->response || 'development' === $core_updates[0]->response || version_compare( $core_updates[0]->current, $cur_wp_version, '=' ) ) { $core_update_version = false; } else { $core_update_version = $core_updates[0]->current; } // b. Check PHP versions compatibility. WP doesn't check WP versions compatibility. $requires_php = isset( $plugin_data->update->requires_php ) ? $plugin_data->update->requires_php : null; $compatible_php = is_php_version_compatible( $requires_php ); // c. Icon. $icon = '<span class="dashicons dashicons-admin-plugins"></span>'; $preferred_icons = array( 'svg', '2x', '1x', 'default' ); foreach ( $preferred_icons as $preferred_icon ) { if ( ! empty( $plugin_data->update->icons[ $preferred_icon ] ) ) { $icon = '<img src="' . esc_url( $plugin_data->update->icons[ $preferred_icon ] ) . '" alt="" />'; break; } } // d. Process compatibility warning text. // Get plugin compat for running version of WordPress. if ( isset( $plugin_data->update->tested ) && version_compare( $plugin_data->update->tested, $cur_wp_version, '>=' ) ) { /* translators: %s: WordPress version. */ $compat = '<br />' . sprintf( __( 'Compatibility with WordPress %s: 100%% (according to its author)' ), $cur_wp_version ); } else { /* translators: %s: WordPress version. */ $compat = '<br />' . sprintf( __( 'Compatibility with WordPress %s: Unknown' ), $cur_wp_version ); } // Get plugin compat for updated version of WordPress. if ( $core_update_version ) { if ( isset( $plugin_data->update->tested ) && version_compare( $plugin_data->update->tested, $core_update_version, '>=' ) ) { /* translators: %s: WordPress version. */ $compat .= '<br />' . sprintf( __( 'Compatibility with WordPress %s: 100%% (according to its author)' ), $core_update_version ); } else { /* translators: %s: WordPress version. */ $compat .= '<br />' . sprintf( __( 'Compatibility with WordPress %s: Unknown' ), $core_update_version ); } } // Get plugin compat for updated version of PHP. if ( ! $compatible_php && current_user_can( 'update_php' ) ) { $compat .= '<br>' . __( 'This update doesn’t work with your version of PHP.' ) . ' '; $compat .= sprintf( /* translators: %s: URL to Update PHP page. */ __( '<a href="%s">Learn more about updating PHP</a>.' ), esc_url( wp_get_update_php_url() ) ); $annotation = wp_get_update_php_annotation(); if ( $annotation ) { $compat .= '</p><p><em>' . $annotation . '</em>'; } } // Get the upgrade notice for the new plugin version. if ( isset( $plugin_data->update->upgrade_notice ) ) { $upgrade_notice = '<br />' . wp_strip_all_tags( $plugin_data->update->upgrade_notice ); } else { $upgrade_notice = ''; } $details_url = self_admin_url( 'plugin-install.php?tab=plugin-information&plugin=' . $plugin_data->update->slug . '§ion=changelog&TB_iframe=true&width=640&height=662' ); $details = sprintf( '<a href="%1$s" class="thickbox open-plugin-details-modal" aria-label="%2$s">%3$s</a>', esc_url( $details_url ), /* translators: 1: Plugin name, 2: Version number. */ esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $plugin_name, $plugin_data->update->new_version ) ), /* translators: %s: Plugin version. */ sprintf( __( 'View version %s details.' ), $plugin_data->update->new_version ) ); $checkbox_id = 'checkbox_' . md5( $plugin_name ); // Plugin template properties. There is no compatible_wp property passed here. $plugin_processed[ $plugin_file ] = array( 'plugin_file' => esc_attr( $plugin_file ), 'name' => esc_attr( $plugin_name ), 'checkbox_id' => esc_attr( 'checkbox_' . md5( $plugin_name ) ), 'icon' => et_core_intentionally_unescaped( $icon, 'html' ), 'version' => esc_attr( $plugin_version ), 'new_version' => esc_attr( $plugin_data->update->new_version ), 'compatible_php' => $compatible_php, 'compat' => et_core_intentionally_unescaped( $compat, 'html' ), 'upgrade_notice' => et_core_intentionally_unescaped( $upgrade_notice, 'html' ), 'details' => et_core_intentionally_unescaped( $details, 'html' ), ); } return $plugin_processed; } /** * Get themes data for Update Core page. * * @since 4.7.0 * * @return array */ public function get_update_core_themes_data() { $theme_updates = get_theme_updates(); $theme_processed = array(); // Bail early if there is no theme updates. if ( empty( $theme_updates ) ) { return array(); } foreach ( $theme_updates as $stylesheet => $theme ) { // a. Check compatibility. $requires_wp = et_()->array_get( $theme->update, 'requires', null ); $requires_php = et_()->array_get( $theme->update, 'requires_php', null ); $compatible_wp = is_wp_version_compatible( $requires_wp ); $compatible_php = is_php_version_compatible( $requires_php ); // b. Process compatibility warning text. $compat = ''; if ( ! $compatible_wp && ! $compatible_php ) { $compat .= '<br>' . __( 'This update doesn’t work with your versions of WordPress and PHP.' ) . ' '; if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { $compat .= sprintf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); $annotation = wp_get_update_php_annotation(); if ( $annotation ) { $compat .= '</p><p><em>' . $annotation . '</em>'; } } elseif ( current_user_can( 'update_core' ) ) { $compat .= sprintf( /* translators: %s: URL to WordPress Updates screen. */ __( '<a href="%s">Please update WordPress</a>.' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { $compat .= sprintf( /* translators: %s: URL to Update PHP page. */ __( '<a href="%s">Learn more about updating PHP</a>.' ), esc_url( wp_get_update_php_url() ) ); $annotation = wp_get_update_php_annotation(); if ( $annotation ) { $compat .= '</p><p><em>' . $annotation . '</em>'; } } } elseif ( ! $compatible_wp ) { $compat .= '<br>' . __( 'This update doesn’t work with your version of WordPress.' ) . ' '; if ( current_user_can( 'update_core' ) ) { $compat .= sprintf( /* translators: %s: URL to WordPress Updates screen. */ __( '<a href="%s">Please update WordPress</a>.' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } } elseif ( ! $compatible_php ) { $compat .= '<br>' . __( 'This update doesn’t work with your version of PHP.' ) . ' '; if ( current_user_can( 'update_php' ) ) { $compat .= sprintf( /* translators: %s: URL to Update PHP page. */ __( '<a href="%s">Learn more about updating PHP</a>.' ), esc_url( wp_get_update_php_url() ) ); $annotation = wp_get_update_php_annotation(); if ( $annotation ) { $compat .= '</p><p><em>' . $annotation . '</em>'; } } } // Theme template properties. $theme_processed[ $stylesheet ] = array( 'stylesheet' => esc_attr( $stylesheet ), 'name' => esc_attr( $theme->display( 'Name' ) ), 'checkbox_id' => esc_attr( 'checkbox_' . md5( $theme->get( 'Name' ) ) ), 'screenshot' => esc_url( $theme->get_screenshot() ), 'version' => esc_attr( $theme->display( 'Version' ) ), 'new_version' => esc_attr( et_()->array_get( $theme->update, 'new_version', '' ) ), 'compatible_wp' => $compatible_wp, 'compatible_php' => $compatible_php, 'compat' => et_core_esc_previously( $compat ), ); } return $theme_processed; } /** * Enqueue compatibility warning scripts and its local data. * * @since 4.7.0 */ public function enqueue_scripts() { global $pagenow, $wp_customize; // Bail early if the current page is not one of the allowed pages. $allowed_pages = array( 'update-core.php', 'customize.php', 'themes.php', ); if ( ! in_array( $pagenow, $allowed_pages, true ) ) { return; } // Enqueue main scripts. wp_enqueue_script( 'et_compatibility_warning_script', ET_CORE_URL . 'admin/js/compatibility-warning.js', array( 'jquery' ), ET_CORE_VERSION, true ); $compatibility_warning = array(); if ( 'update-core.php' === $pagenow ) { $compatibility_warning['update_core_data'] = array( 'plugins' => self::get_update_core_plugins_data(), 'themes' => self::get_update_core_themes_data(), ); } elseif ( 'themes.php' === $pagenow ) { $compatibility_warning['manage_themes_data'] = true; } elseif ( 'customize.php' === $pagenow ) { // Ensure style.css file exist. $theme_root = $wp_customize->theme()->theme_root; $theme_slug = $wp_customize->theme()->stylesheet; $theme_file = "{$theme_root}/{$theme_slug}/style.css"; // Get WP & PHP compatibility info. $theme_headers = array(); if ( file_exists( $theme_file ) ) { $theme_headers = get_file_data( $theme_file, array( 'RequiresWP' => 'Requires at least', 'RequiresPHP' => 'Requires PHP', ), 'theme' ); } $requires_wp = et_()->array_get( $theme_headers, 'RequiresWP', false ); $requires_php = et_()->array_get( $theme_headers, 'RequiresPHP', false ); // Theme Customizer - Used for disable publish button. $compatibility_warning['customizer_data'] = array( 'compatible_wp' => is_wp_version_compatible( $requires_wp ), 'compatible_php' => is_php_version_compatible( $requires_php ), 'disabled_text' => esc_html_x( 'Cannot Activate', 'theme' ), ); } wp_localize_script( 'et_compatibility_warning_script', 'et_compatibility_warning', $compatibility_warning ); } /** * Overrides table body of plugin updates section. * * The structure is backported from WP 5.5 without any modification. * * @see {list_plugin_updates()} of WP 5.5 * * @since 4.7.0 */ public function overrides_update_core_plugins_table_body() { // Bail early if there is no plugin updates. if ( empty( get_plugin_updates() ) ) { return; } ?> <script type="text/html" id="tmpl-et-update-core-plugins-table-body"> <# if (data.plugins) { #> <# _.each(data.plugins, function(plugin, slug) { #> <tr> <td class="check-column"> <# if (plugin.compatible_php) { #> <input type="checkbox" name="checked[]" id="{{plugin.checkbox_id}}" value="{{plugin.plugin_file}}" /> <label for="{{plugin.checkbox_id}}" class="screen-reader-text"> <?php /* translators: %s: Plugin name. */ printf( esc_html__( 'Select %s' ), '{{plugin.name}}' ); ?> </label> <# } #> </td> <td class="plugin-title"><p> {{{plugin.icon}}} <strong>{{plugin.name}}</strong> <?php printf( /* translators: 1: Plugin version, 2: New version. */ esc_html__( 'You have version %1$s installed. Update to %2$s.' ), '{{plugin.version}}', '{{plugin.new_version}}' ); echo ' {{{plugin.details}}}{{{plugin.compat}}}{{{plugin.upgrade_notice}}}'; ?> </p></td> </tr> <# }); #> <# } #> </script> <?php } /** * Overrides table body of theme updates section. * * The structure is backported from WP 5.5 without any modification. * * @see {list_theme_updates()} of WP 5.5 * * @since 4.7.0 */ public function overrides_update_core_themes_table_body() { // Bail early if there is no theme updates. if ( empty( get_theme_updates() ) ) { return; } ?> <script type="text/html" id="tmpl-et-update-core-themes-table-body"> <# if (data.themes) { #> <# _.each(data.themes, function(theme, slug) { #> <tr> <td class="check-column"> <# if (theme.compatible_wp && theme.compatible_php) { #> <input type="checkbox" name="checked[]" id="{{theme.checkbox_id}}" value="{{theme.styelsheet}}" /> <label for="{{theme.checkbox_id}}" class="screen-reader-text"> <?php /* translators: %s: Theme name. */ printf( esc_html__( 'Select %s' ), '{{theme.name}}' ); ?> </label> <# } #> </td> <td class="plugin-title"><p> <img src="{{theme.screenshot}}" width="85" height="64" class="updates-table-screenshot" alt="" /> <strong>{{theme.name}}</strong> <?php printf( /* translators: 1: Theme version, 2: New version. */ esc_html__( 'You have version %1$s installed. Update to %2$s.' ), '{{theme.version}}', '{{theme.new_version}}' ); echo ' {{{theme.compat}}}'; ?> </p></td> </tr> <# }); #> <# } #> </script> <?php } /** * Overrides theme info & details display of Manage Themes. * * The structure is backported from WP 5.5 without any modification. * * @see {wp-admin/themes.php} of WP 5.5 * * @since 4.7.0 */ public function overrides_tmpl_theme() { ?> <script id="tmpl-theme" type="text/template"> <# if ( data.screenshot[0] ) { #> <div class="theme-screenshot"> <img src="{{ data.screenshot[0] }}" alt="" /> </div> <# } else { #> <div class="theme-screenshot blank"></div> <# } #> <# if ( data.hasUpdate ) { #> <# if ( data.updateResponse.compatibleWP && data.updateResponse.compatiblePHP ) { #> <div class="update-message notice inline notice-warning notice-alt"><p> <# if ( data.hasPackage ) { #> <?php echo et_core_intentionally_unescaped( __( 'New version available. <button class="button-link" type="button">Update now</button>' ), 'html' ); ?> <# } else { #> <?php esc_html_e( 'New version available.' ); ?> <# } #> </p></div> <# } else { #> <div class="update-message notice inline notice-error notice-alt"><p> <# if ( ! data.updateResponse.compatibleWP && ! data.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your versions of WordPress and PHP.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.updateResponse.compatibleWP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of WordPress.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of PHP.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p></div> <# } #> <# } #> <# if ( ! data.compatibleWP || ! data.compatiblePHP ) { #> <div class="notice notice-error notice-alt"><p> <# if ( ! data.compatibleWP && ! data.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your versions of WordPress and PHP.' ), 'html' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.compatibleWP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of WordPress.' ), 'html' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of PHP.' ), 'html' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p></div> <# } #> <span class="more-details" id="{{ data.id }}-action"><?php esc_html_e( 'Theme Details' ); ?></span> <div class="theme-author"> <?php /* translators: %s: Theme author name. */ printf( esc_html__( 'By %s' ), '{{{ data.author }}}' ); ?> </div> <div class="theme-id-container"> <# if ( data.active ) { #> <h2 class="theme-name" id="{{ data.id }}-name"> <span><?php echo esc_html_x( 'Active:', 'theme' ); ?></span> {{{ data.name }}} </h2> <# } else { #> <h2 class="theme-name" id="{{ data.id }}-name">{{{ data.name }}}</h2> <# } #> <div class="theme-actions"> <# if ( data.active ) { #> <# if ( data.actions.customize ) { #> <a class="button button-primary customize load-customize hide-if-no-customize" href="{{{ data.actions.customize }}}"><?php esc_html_e( 'Customize' ); ?></a> <# } #> <# } else { #> <# if ( data.compatibleWP && data.compatiblePHP ) { #> <?php /* translators: %s: Theme name. */ $aria_label = sprintf( esc_html_x( 'Activate %s', 'theme' ), '{{ data.name }}' ); ?> <a class="button activate" href="{{{ data.actions.activate }}}" aria-label="<?php echo esc_attr( $aria_label ); ?>"><?php esc_html_e( 'Activate' ); ?></a> <a class="button button-primary load-customize hide-if-no-customize" href="{{{ data.actions.customize }}}"><?php esc_html_e( 'Live Preview' ); ?></a> <# } else { #> <?php /* translators: %s: Theme name. */ $aria_label = sprintf( esc_html_x( 'Cannot Activate %s', 'theme' ), '{{ data.name }}' ); ?> <a class="button disabled" aria-label="<?php echo esc_attr( $aria_label ); ?>"><?php echo esc_html_x( 'Cannot Activate', 'theme' ); ?></a> <a class="button button-primary hide-if-no-customize disabled"><?php esc_html_e( 'Live Preview' ); ?></a> <# } #> <# } #> </div> </div> </script> <script id="tmpl-theme-single" type="text/template"> <div class="theme-backdrop"></div> <div class="theme-wrap wp-clearfix" role="document"> <div class="theme-header"> <button class="left dashicons dashicons-no"><span class="screen-reader-text"><?php esc_html_e( 'Show previous theme' ); ?></span></button> <button class="right dashicons dashicons-no"><span class="screen-reader-text"><?php esc_html_e( 'Show next theme' ); ?></span></button> <button class="close dashicons dashicons-no"><span class="screen-reader-text"><?php esc_html_e( 'Close details dialog' ); ?></span></button> </div> <div class="theme-about wp-clearfix"> <div class="theme-screenshots"> <# if ( data.screenshot[0] ) { #> <div class="screenshot"><img src="{{ data.screenshot[0] }}" alt="" /></div> <# } else { #> <div class="screenshot blank"></div> <# } #> </div> <div class="theme-info"> <# if ( data.active ) { #> <span class="current-label"><?php esc_html_e( 'Current Theme' ); ?></span> <# } #> <h2 class="theme-name">{{{ data.name }}}<span class="theme-version"> <?php /* translators: %s: Theme version. */ printf( esc_html__( 'Version: %s' ), '{{ data.version }}' ); ?> </span></h2> <p class="theme-author"> <?php /* translators: %s: Theme author link. */ printf( esc_html__( 'By %s' ), '{{{ data.authorAndUri }}}' ); ?> </p> <# if ( ! data.compatibleWP || ! data.compatiblePHP ) { #> <div class="notice notice-error notice-alt notice-large"><p> <# if ( ! data.compatibleWP && ! data.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your versions of WordPress and PHP.' ), 'html' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.compatibleWP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of WordPress.' ), 'html' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of PHP.' ), 'html' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p></div> <# } #> <# if ( data.hasUpdate ) { #> <# if ( data.updateResponse.compatibleWP && data.updateResponse.compatiblePHP ) { #> <div class="notice notice-warning notice-alt notice-large"> <h3 class="notice-title"><?php esc_html_e( 'Update Available' ); ?></h3> {{{ data.update }}} </div> <# } else { #> <div class="notice notice-error notice-alt notice-large"> <h3 class="notice-title"><?php esc_html_e( 'Update Incompatible' ); ?></h3> <p> <# if ( ! data.updateResponse.compatibleWP && ! data.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your versions of WordPress and PHP.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.updateResponse.compatibleWP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of WordPress.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of PHP.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p> </div> <# } #> <# } #> <p class="theme-description">{{{ data.description }}}</p> <# if ( data.parent ) { #> <p class="parent-theme"> <?php /* translators: %s: Theme name. */ printf( esc_html__( 'This is a child theme of %s.' ), '<strong>{{{ data.parent }}}</strong>' ); ?> </p> <# } #> <# if ( data.tags ) { #> <p class="theme-tags"><span><?php esc_html_e( 'Tags:' ); ?></span> {{{ data.tags }}}</p> <# } #> </div> </div> <div class="theme-actions"> <div class="active-theme"> <a href="{{{ data.actions.customize }}}" class="button button-primary customize load-customize hide-if-no-customize"><?php esc_html_e( 'Customize' ); ?></a> <?php echo et_core_intentionally_unescaped( implode( ' ', $GLOBALS['current_theme_actions'] ), 'html' ); ?> </div> <div class="inactive-theme"> <# if ( data.compatibleWP && data.compatiblePHP ) { #> <?php /* translators: %s: Theme name. */ $aria_label = sprintf( esc_html_x( 'Activate %s', 'theme' ), '{{ data.name }}' ); ?> <# if ( data.actions.activate ) { #> <a href="{{{ data.actions.activate }}}" class="button activate" aria-label="<?php echo esc_attr( $aria_label ); ?>"><?php esc_html_e( 'Activate' ); ?></a> <# } #> <a href="{{{ data.actions.customize }}}" class="button button-primary load-customize hide-if-no-customize"><?php esc_html_e( 'Live Preview' ); ?></a> <# } else { #> <?php /* translators: %s: Theme name. */ $aria_label = sprintf( esc_html_x( 'Cannot Activate %s', 'theme' ), '{{ data.name }}' ); ?> <# if ( data.actions.activate ) { #> <a class="button disabled" aria-label="<?php echo esc_attr( $aria_label ); ?>"><?php echo esc_html_x( 'Cannot Activate', 'theme' ); ?></a> <# } #> <a class="button button-primary hide-if-no-customize disabled"><?php esc_html_e( 'Live Preview' ); ?></a> <# } #> </div> <# if ( ! data.active && data.actions['delete'] ) { #> <a href="{{{ data.actions['delete'] }}}" class="button delete-theme"><?php esc_html_e( 'Delete' ); ?></a> <# } #> </div> </div> </script> <?php } /** * Overrides plugin warning display of Plugins list page. * * @see {wp_plugin_update_rows()} of WP 5.5 * * @since 4.7.0 */ public function overrides_plugins_table_rows() { if ( ! current_user_can( 'update_plugins' ) ) { return; } $update_plugins = get_site_transient( 'update_plugins' ); if ( isset( $update_plugins->response ) && is_array( $update_plugins->response ) ) { foreach ( $update_plugins->response as $plugin_file => $plugin ) { $requires_php = isset( $plugin->requires_php ) ? $plugin->requires_php : null; $compatible_php = is_php_version_compatible( $requires_php ); // Bail early if the package empty or already compatible with current PHP version. if ( empty( $plugin->package ) || $compatible_php ) { continue; } // Need to remove default action before we can replace it with the new one. remove_action( "after_plugin_row_$plugin_file", 'wp_plugin_update_row', 10, 2 ); add_action( "after_plugin_row_$plugin_file", array( $this, 'plugin_update_row_compatibility_error' ), 10, 2 ); } } } /** * Display plugin update row with error compatibility. * * @see {wp_plugin_update_row()} of WP 5.5 * * @since 4.7.0 * * @param string $file Plugin basename. * @param array $plugin_data Plugin information. */ public function plugin_update_row_compatibility_error( $file, $plugin_data ) { if ( ! is_network_admin() && is_multisite() ) { return; } $update_plugins = get_site_transient( 'update_plugins' ); if ( ! isset( $update_plugins->response[ $file ] ) ) { return; } // a. Plugin response. $response = $update_plugins->response[ $file ]; // b. Plugin name. $plugins_allowedtags = array( 'a' => array( 'href' => array(), 'title' => array(), ), 'abbr' => array( 'title' => array() ), 'acronym' => array( 'title' => array() ), 'code' => array(), 'em' => array(), 'strong' => array(), ); $plugin_name = wp_kses( $plugin_data['Name'], $plugins_allowedtags ); // c. Details URL. $details_url = self_admin_url( 'plugin-install.php?tab=plugin-information&plugin=' . $response->slug . '§ion=changelog&TB_iframe=true&width=600&height=800' ); // d. Active class. if ( is_network_admin() ) { $active_class = is_plugin_active_for_network( $file ) ? ' active' : ''; } else { $active_class = is_plugin_active( $file ) ? ' active' : ''; } /** * Column count. * * @var WP_Plugins_List_Table $wp_list_table */ $wp_list_table = _get_list_table( 'WP_Plugins_List_Table', array( 'screen' => get_current_screen(), ) ); // f. Error text. $update_php_notation = wp_get_update_php_annotation(); $error_text = sprintf( /* translators: 1: Plugin name, 2: Details URL, 3: Additional link attributes, 4: Version number 5: URL to Update PHP page. */ __( 'There is a new version of %1$s available, but it doesn’t work with your version of PHP. <a href="%2$s" %3$s>View version %4$s details</a> or <a href="%5$s">learn more about updating PHP</a>. %6$s' ), $plugin_name, esc_url( $details_url ), sprintf( 'class="thickbox open-plugin-details-modal" aria-label="%s"', /* translators: 1: Plugin name, 2: Version number. */ esc_attr( sprintf( __( 'View %1$s version %2$s details' ), $plugin_name, $response->new_version ) ) ), esc_attr( $response->new_version ), esc_url( wp_get_update_php_url() ), // #5 ! empty( $update_php_notation ) ? sprintf( __( '<br><em>%s</em>' ), $update_php_notation ) : '' ); printf( /* translators: 1: Active class, 2: Update slug, 3: Slug, 4: Plugin file, 5: Column count. */ '<tr class="plugin-update-tr%1$s" id="%2$s" data-slug="%3$s" data-plugin="%4$s"> <td colspan="%5$s" class="plugin-update colspanchange"> <div class="update-message notice inline notice-error notice-alt"> <p>%6$s</p> </div> </td> </tr>', esc_attr( $active_class ), esc_attr( $response->slug . '-update' ), esc_attr( $response->slug ), esc_attr( $file ), esc_attr( $wp_list_table->get_column_count() ), // #5 et_core_intentionally_unescaped( $error_text, 'html' ) ); } /** * Overrides theme info & details display of Theme Customizer. * * The structure is backported from WP 5.5 without any modification. * * @see {WP_Customize_Theme_Control::content_template()} of WP 5.5 * * @since 4.7.0 */ public function overrides_tmpl_customize_control_theme_content() { /* translators: %s: Theme name. */ $details_label = sprintf( esc_html__( 'Details for theme: %s' ), '{{ data.theme.name }}' ); /* translators: %s: Theme name. */ $customize_label = sprintf( esc_html__( 'Customize theme: %s' ), '{{ data.theme.name }}' ); /* translators: %s: Theme name. */ $preview_label = sprintf( esc_html__( 'Live preview theme: %s' ), '{{ data.theme.name }}' ); /* translators: %s: Theme name. */ $install_label = sprintf( esc_html__( 'Install and preview theme: %s' ), '{{ data.theme.name }}' ); ?> <script id="tmpl-customize-control-theme-content" type="text/html"> <# if ( data.theme.active ) { #> <div class="theme active" tabindex="0" aria-describedby="{{ data.section }}-{{ data.theme.id }}-action"> <# } else { #> <div class="theme" tabindex="0" aria-describedby="{{ data.section }}-{{ data.theme.id }}-action"> <# } #> <# if ( data.theme.screenshot && data.theme.screenshot[0] ) { #> <div class="theme-screenshot"> <img data-src="{{ data.theme.screenshot[0] }}" alt="" /> </div> <# } else { #> <div class="theme-screenshot blank"></div> <# } #> <span class="more-details theme-details" id="{{ data.section }}-{{ data.theme.id }}-action" aria-label="<?php echo esc_attr( $details_label ); ?>"><?php esc_html_e( 'Theme Details' ); ?></span> <div class="theme-author"> <?php /* translators: Theme author name. */ printf( esc_html_x( 'By %s', 'theme author' ), '{{ data.theme.author }}' ); ?> </div> <# if ( 'installed' === data.theme.type && data.theme.hasUpdate ) { #> <# if ( data.theme.updateResponse.compatibleWP && data.theme.updateResponse.compatiblePHP ) { #> <div class="update-message notice inline notice-warning notice-alt" data-slug="{{ data.theme.id }}"> <p> <?php if ( is_multisite() ) { esc_html_e( 'New version available.' ); } else { printf( /* translators: %s: "Update now" button. */ esc_html__( 'New version available. %s' ), '<button class="button-link update-theme" type="button">' . esc_html__( 'Update now' ) . '</button>' ); } ?> </p> </div> <# } else { #> <div class="update-message notice inline notice-error notice-alt" data-slug="{{ data.theme.id }}"> <p> <# if ( ! data.theme.updateResponse.compatibleWP && ! data.theme.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your versions of WordPress and PHP.' ), 'html' ), '{{{ data.theme.name }}}' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.theme.updateResponse.compatibleWP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of WordPress.' ), 'html' ), '{{{ data.theme.name }}}' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.theme.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of PHP.' ), 'html' ), '{{{ data.theme.name }}}' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p> </div> <# } #> <# } #> <# if ( ! data.theme.compatibleWP || ! data.theme.compatiblePHP ) { #> <div class="notice notice-error notice-alt"><p> <# if ( ! data.theme.compatibleWP && ! data.theme.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your versions of WordPress and PHP.' ), 'html' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.theme.compatibleWP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of WordPress.' ), 'html' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.theme.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of PHP.' ), 'html' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p></div> <# } #> <# if ( data.theme.active ) { #> <div class="theme-id-container"> <h3 class="theme-name" id="{{ data.section }}-{{ data.theme.id }}-name"> <span><?php echo esc_html_x( 'Previewing:', 'theme' ); ?></span> {{ data.theme.name }} </h3> <div class="theme-actions"> <button type="button" class="button button-primary customize-theme" aria-label="<?php echo esc_attr( $customize_label ); ?>"><?php esc_html_e( 'Customize' ); ?></button> </div> </div> <div class="notice notice-success notice-alt"><p><?php echo esc_html_x( 'Installed', 'theme' ); ?></p></div> <# } else if ( 'installed' === data.theme.type ) { #> <div class="theme-id-container"> <h3 class="theme-name" id="{{ data.section }}-{{ data.theme.id }}-name">{{ data.theme.name }}</h3> <div class="theme-actions"> <# if ( data.theme.compatibleWP && data.theme.compatiblePHP ) { #> <button type="button" class="button button-primary preview-theme" aria-label="<?php echo esc_attr( $preview_label ); ?>" data-slug="{{ data.theme.id }}"><?php esc_html_e( 'Live Preview' ); ?></button> <# } else { #> <button type="button" class="button button-primary disabled" aria-label="<?php echo esc_attr( $preview_label ); ?>"><?php esc_html_e( 'Live Preview' ); ?></button> <# } #> </div> </div> <div class="notice notice-success notice-alt"><p><?php echo esc_html_x( 'Installed', 'theme' ); ?></p></div> <# } else { #> <div class="theme-id-container"> <h3 class="theme-name" id="{{ data.section }}-{{ data.theme.id }}-name">{{ data.theme.name }}</h3> <div class="theme-actions"> <# if ( data.theme.compatibleWP && data.theme.compatiblePHP ) { #> <button type="button" class="button button-primary theme-install preview" aria-label="<?php echo esc_attr( $install_label ); ?>" data-slug="{{ data.theme.id }}" data-name="{{ data.theme.name }}"><?php esc_html_e( 'Install & Preview' ); ?></button> <# } else { #> <button type="button" class="button button-primary disabled" aria-label="<?php echo esc_attr( $install_label ); ?>" disabled><?php esc_html_e( 'Install & Preview' ); ?></button> <# } #> </div> </div> <# } #> </div> </script> <script type="text/html" id="tmpl-customize-themes-details-view"> <div class="theme-backdrop"></div> <div class="theme-wrap wp-clearfix" role="document"> <div class="theme-header"> <button type="button" class="left dashicons dashicons-no"><span class="screen-reader-text"><?php esc_html_e( 'Show previous theme' ); ?></span></button> <button type="button" class="right dashicons dashicons-no"><span class="screen-reader-text"><?php esc_html_e( 'Show next theme' ); ?></span></button> <button type="button" class="close dashicons dashicons-no"><span class="screen-reader-text"><?php esc_html_e( 'Close details dialog' ); ?></span></button> </div> <div class="theme-about wp-clearfix"> <div class="theme-screenshots"> <# if ( data.screenshot && data.screenshot[0] ) { #> <div class="screenshot"><img src="{{ data.screenshot[0] }}" alt="" /></div> <# } else { #> <div class="screenshot blank"></div> <# } #> </div> <div class="theme-info"> <# if ( data.active ) { #> <span class="current-label"><?php esc_html_e( 'Current Theme' ); ?></span> <# } #> <h2 class="theme-name">{{{ data.name }}}<span class="theme-version"> <?php /* translators: %s: Theme version. */ printf( esc_html__( 'Version: %s' ), '{{ data.version }}' ); ?> </span></h2> <h3 class="theme-author"> <?php /* translators: %s: Theme author link. */ printf( esc_html__( 'By %s' ), '{{{ data.authorAndUri }}}' ); ?> </h3> <# if ( data.stars && 0 != data.num_ratings ) { #> <div class="theme-rating"> {{{ data.stars }}} <a class="num-ratings" target="_blank" href="{{ data.reviews_url }}"> <?php printf( '%1$s <span class="screen-reader-text">%2$s</span>', /* translators: %s: Number of ratings. */ sprintf( esc_html__( '(%s ratings)' ), '{{ data.num_ratings }}' ), /* translators: Accessibility text. */ esc_html__( '(opens in a new tab)' ) ); ?> </a> </div> <# } #> <# if ( data.hasUpdate ) { #> <# if ( data.updateResponse.compatibleWP && data.updateResponse.compatiblePHP ) { #> <div class="notice notice-warning notice-alt notice-large" data-slug="{{ data.id }}"> <h3 class="notice-title"><?php esc_html_e( 'Update Available' ); ?></h3> {{{ data.update }}} </div> <# } else { #> <div class="notice notice-error notice-alt notice-large" data-slug="{{ data.id }}"> <h3 class="notice-title"><?php esc_html_e( 'Update Incompatible' ); ?></h3> <p> <# if ( ! data.updateResponse.compatibleWP && ! data.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your versions of WordPress and PHP.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.updateResponse.compatibleWP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of WordPress.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.updateResponse.compatiblePHP ) { #> <?php printf( /* translators: %s: Theme name. */ et_core_intentionally_unescaped( __( 'There is a new version of %s available, but it doesn’t work with your version of PHP.' ), 'html' ), '{{{ data.name }}}' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p> </div> <# } #> <# } #> <# if ( data.parent ) { #> <p class="parent-theme"> <?php printf( /* translators: %s: Theme name. */ esc_html__( 'This is a child theme of %s.' ), '<strong>{{{ data.parent }}}</strong>' ); ?> </p> <# } #> <# if ( ! data.compatibleWP || ! data.compatiblePHP ) { #> <div class="notice notice-error notice-alt notice-large"><p> <# if ( ! data.compatibleWP && ! data.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your versions of WordPress and PHP.' ), 'html' ); if ( current_user_can( 'update_core' ) && current_user_can( 'update_php' ) ) { printf( /* translators: 1: URL to WordPress Updates screen, 2: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%1$s">Please update WordPress</a>, and then <a href="%2$s">learn more about updating PHP</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } elseif ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } elseif ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } else if ( ! data.compatibleWP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of WordPress.' ), 'html' ); if ( current_user_can( 'update_core' ) ) { printf( /* translators: %s: URL to WordPress Updates screen. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Please update WordPress</a>.' ), 'html' ), esc_url( self_admin_url( 'update-core.php' ) ) ); } ?> <# } else if ( ! data.compatiblePHP ) { #> <?php echo et_core_intentionally_unescaped( __( 'This theme doesn’t work with your version of PHP.' ), 'html' ); if ( current_user_can( 'update_php' ) ) { printf( /* translators: %s: URL to Update PHP page. */ ' ' . et_core_intentionally_unescaped( __( '<a href="%s">Learn more about updating PHP</a>.' ), 'html' ), esc_url( wp_get_update_php_url() ) ); wp_update_php_annotation( '</p><p><em>', '</em>' ); } ?> <# } #> </p></div> <# } #> <p class="theme-description">{{{ data.description }}}</p> <# if ( data.tags ) { #> <p class="theme-tags"><span><?php esc_html_e( 'Tags:' ); ?></span> {{{ data.tags }}}</p> <# } #> </div> </div> <div class="theme-actions"> <# if ( data.active ) { #> <button type="button" class="button button-primary customize-theme"><?php esc_html_e( 'Customize' ); ?></button> <# } else if ( 'installed' === data.type ) { #> <?php if ( current_user_can( 'delete_themes' ) ) { ?> <# if ( data.actions && data.actions['delete'] ) { #> <a href="{{{ data.actions['delete'] }}}" data-slug="{{ data.id }}" class="button button-secondary delete-theme"><?php esc_html_e( 'Delete' ); ?></a> <# } #> <?php } ?> <# if ( data.compatibleWP && data.compatiblePHP ) { #> <button type="button" class="button button-primary preview-theme" data-slug="{{ data.id }}"><?php esc_html_e( 'Live Preview' ); ?></button> <# } else { #> <button class="button button-primary disabled"><?php esc_html_e( 'Live Preview' ); ?></button> <# } #> <# } else { #> <# if ( data.compatibleWP && data.compatiblePHP ) { #> <button type="button" class="button theme-install" data-slug="{{ data.id }}"><?php esc_html_e( 'Install' ); ?></button> <button type="button" class="button button-primary theme-install preview" data-slug="{{ data.id }}"><?php esc_html_e( 'Install & Preview' ); ?></button> <# } else { #> <button type="button" class="button disabled"><?php echo esc_html_x( 'Cannot Install', 'theme' ); ?></button> <button type="button" class="button button-primary disabled"><?php esc_html_e( 'Install & Preview' ); ?></button> <# } #> <# } #> </div> </div> </script> <?php } /** * Deactivate incompatible plugin once it's activated. * * The code is backported from WP 5.5 partially. However, not all the code is inlcuded * here because: * - We can't add `RequiresWP: Requires at least` & `RequiresPHP: Requires PHP` plugin * headers via `extra_plugin_headers` hook because the keys & values will be combined. * - On WP 5.3, it requires readme.txt instead of main plugin file. We can simplify it * by directly access main plugin file. * * @see {validate_plugin_requirements()} * * @since 4.7.0 * * @param string $plugin Main plugin file name. */ public static function maybe_deactivate_incompatible_plugin( $plugin ) { $plugin_file = WP_PLUGIN_DIR . '/' . $plugin; // Ensure the main plugin file exists. if ( ! file_exists( $plugin_file ) ) { return; } // Get WP & PHP compatibility info. $plugin_headers = get_file_data( $plugin_file, array( 'Name' => 'Plugin Name', 'RequiresWP' => 'Requires at least', 'RequiresPHP' => 'Requires PHP', ), 'plugin' ); $requirements = array( 'requires' => ! empty( $plugin_headers['RequiresWP'] ) ? $plugin_headers['RequiresWP'] : '', 'requires_php' => ! empty( $plugin_headers['RequiresPHP'] ) ? $plugin_headers['RequiresPHP'] : '', ); if ( ! function_exists( 'is_wp_version_compatible' ) || ! function_exists( 'is_php_version_compatible' ) ) { require_once plugin_dir_path( $plugin_file ) . 'core/wp_functions.php'; } // Check version compatibility. $compatible_wp = is_wp_version_compatible( $requirements['requires'] ); $compatible_php = is_php_version_compatible( $requirements['requires_php'] ); /* translators: %s: URL to Update PHP page. */ $php_update_message = '</p><p>' . sprintf( __( '<a href="%s">Learn more about updating PHP</a>.' ), esc_url( wp_get_update_php_url() ) ); $annotation = wp_get_update_php_annotation(); if ( $annotation ) { $php_update_message .= '</p><p><em>' . $annotation . '</em>'; } // Decide whether current plugin is compatible and should be activated or not. $result = true; if ( ! $compatible_wp && ! $compatible_php ) { $result = new WP_Error( 'plugin_wp_php_incompatible', '<p>' . sprintf( /* translators: 1: Current WordPress version, 2: Current PHP version, 3: Plugin name, 4: Required WordPress version, 5: Required PHP version. */ _x( '<strong>Error:</strong> Current versions of WordPress (%1$s) and PHP (%2$s) do not meet minimum requirements for %3$s. The plugin requires WordPress %4$s and PHP %5$s.', 'plugin' ), get_bloginfo( 'version' ), phpversion(), $plugin_headers['Name'], $requirements['requires'], $requirements['requires_php'] ) . $php_update_message . '</p>' ); } elseif ( ! $compatible_php ) { $result = new WP_Error( 'plugin_php_incompatible', '<p>' . sprintf( /* translators: 1: Current PHP version, 2: Plugin name, 3: Required PHP version. */ _x( '<strong>Error:</strong> Current PHP version (%1$s) does not meet minimum requirements for %2$s. The plugin requires PHP %3$s.', 'plugin' ), phpversion(), $plugin_headers['Name'], $requirements['requires_php'] ) . $php_update_message . '</p>' ); } elseif ( ! $compatible_wp ) { $result = new WP_Error( 'plugin_wp_incompatible', '<p>' . sprintf( /* translators: 1: Current WordPress version, 2: Plugin name, 3: Required WordPress version. */ _x( '<strong>Error:</strong> Current WordPress version (%1$s) does not meet minimum requirements for %2$s. The plugin requires WordPress %3$s.', 'plugin' ), get_bloginfo( 'version' ), $plugin_headers['Name'], $requirements['requires'] ) . '</p>' ); } if ( is_wp_error( $result ) ) { wp_die( $result ); // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped -- Can't call et_core_intentionally_unescaped function because it's fired during plugin activation hook. } } } endif; components/VersionRollback.php 0000644 00000044237 15222641012 0012546 0 ustar 00 <?php // phpcs:disable Generic.WhiteSpace.ScopeIndent -- our preference is to not indent the whole inner function in this scenario. if ( ! class_exists( 'ET_Core_VersionRollback' ) ) : /** * Handles version rollback. * * @since 3.10 * * @private * * @package ET\Core\VersionRollback */ class ET_Core_VersionRollback { /** * Product name. * * @var string */ protected $product_name = ''; /** * Product shortname. * * @var string */ protected $product_shortname = ''; /** * Current product version. * * @var string */ protected $product_version = ''; /** * Is rollback service enabled. * * @var bool */ protected $enabled = false; /** * API Username. * * @var string */ protected $api_username = ''; /** * API Key. * * @var string */ protected $api_key = ''; /** * ET_Core_VersionRollback constructor. * * @since 3.10 * * @param string $product_name Product name. * @param string $product_shortname Product shortname. * @param string $product_version Product version. */ public function __construct( $product_name, $product_shortname, $product_version ) { $this->product_name = sanitize_text_field( $product_name ); $this->product_shortname = sanitize_text_field( $product_shortname ); $this->product_version = sanitize_text_field( $product_version ); if ( ! $options = get_site_option( 'et_automatic_updates_options' ) ) { $options = get_option( 'et_automatic_updates_options' ); } $this->api_username = isset( $options['username'] ) ? sanitize_text_field( $options['username'] ) : ''; $this->api_key = isset( $options['api_key'] ) ? sanitize_text_field( $options['api_key'] ) : ''; } /** * Enqueue assets. * * @since ?.? Script `et-core-version-rollback` now loads in footer. * @since 3.10 */ public function assets() { wp_enqueue_style( 'et-core-version-rollback', ET_CORE_URL . 'admin/css/version-rollback.css', array( 'et-core-admin', ), ET_CORE_VERSION ); wp_enqueue_script( 'et-core-version-rollback', ET_CORE_URL . 'admin/js/version-rollback.js', array( 'jquery', 'jquery-ui-tabs', 'jquery-form', 'et-core-admin', ), ET_CORE_VERSION, true ); wp_localize_script( 'et-core-version-rollback', 'etCoreVersionRollbackI18n', array( 'unknownError' => esc_html__( 'An unknown error has occurred. Please try again later.', 'et-core' ), ) ); } /** * Get previous installed version, if any. * * @since 3.10 * * @return string */ protected function _get_previous_installed_version() { return et_get_option( "{$this->product_shortname}_previous_installed_version", '' ); } /** * Set previous installed version. * * @since 3.10 * * @param string $version * * @return void */ protected function _set_previous_installed_version( $version ) { et_update_option( "{$this->product_shortname}_previous_installed_version", sanitize_text_field( $version ) ); } /** * Get latest installed version, if any. * * @since 3.10 * * @return string */ protected function _get_latest_installed_version() { return et_get_option( "{$this->product_shortname}_latest_installed_version", '' ); } /** * Set latest installed version. * * @since 3.10 * * @param string $version * * @return void */ protected function _set_latest_installed_version( $version ) { et_update_option( "{$this->product_shortname}_latest_installed_version", sanitize_text_field( $version ) ); } /** * Check if the product has already been rolled back. * * @since 3.10 * * @return bool */ protected function _is_rolled_back() { return version_compare( $this->_get_latest_installed_version(), $this->_get_previous_installed_version(), '<=' ); } /** * Get unique ajax action. * * @since 3.10 * * @return string */ protected function _get_ajax_action() { return 'et_core_version_rollback'; } /** * Enable update rollback. * * @since 3.10 * * @return void */ public function enable() { if ( $this->enabled ) { return; } $this->enabled = true; add_action( 'admin_enqueue_scripts', array( $this, 'assets' ) ); add_action( 'wp_ajax_' . $this->_get_ajax_action(), array( $this, 'ajax_rollback' ) ); // Update version number when theme is manually replaced. add_action( 'admin_init', array( $this, 'store_previous_version_number' ) ); // Update version number when theme is activated. add_action( 'after_switch_theme', array( $this, 'store_previous_version_number' ) ); // Update version number when theme is updated. add_action( 'upgrader_process_complete', array( $this, 'store_previous_version_number' ), 10, 0 ); } /** * Handle REST API requests to rollback. * * @since 3.10 * * @return void */ public function ajax_rollback() { if ( ! isset( $_GET['nonce'] ) || ! wp_verify_nonce( $_GET['nonce'], $this->_get_ajax_action() ) ) { wp_send_json_error( array( 'errorCode' => 'et_unknown', 'error' => esc_html__( 'Security check failed. Please refresh and try again.', 'et-core' ), ), 400 ); } if ( ! current_user_can( 'install_themes' ) ) { wp_send_json_error( array( 'errorCode' => 'et_unknown', 'error' => esc_html__( 'You don\'t have sufficient permissions to access this page.', 'et-core' ), ), 400 ); } if ( $this->_is_rolled_back() ) { $error = ' <p> ' . et_get_safe_localization( sprintf( __( 'You\'re currently rolled back to <strong>Version %1$s</strong> from <strong>Version %2$s</strong>.', 'et-core' ), esc_html( $this->_get_latest_installed_version() ), esc_html( $this->_get_previous_installed_version() ) ) ) . ' </p> <p> ' . et_get_safe_localization( sprintf( __( 'Update to the latest version to unlock the full power of %1$s. <a href="%2$s" target="_blank">Learn more here</a>.', 'et-core' ), esc_html( $this->product_name ), esc_url( $this->_get_update_documentation_url() ) ) ) . ' </p> '; wp_send_json_error( array( 'errorCode' => 'et_unknown', 'error' => $error, ), 400 ); } $success = $this->rollback(); if ( is_wp_error( $success ) ) { $error = $success->get_error_message(); if ( $success->get_error_code() === 'et_version_rollback_blocklisted' ) { $error = ' <p> ' . et_get_safe_localization( sprintf( __( 'For privacy and security reasons, you cannot rollback to <strong>Version %1$s</strong>.', 'et-core' ), esc_html( $this->_get_previous_installed_version() ) ) ) . ' </p> <p> <a href="' . esc_url( $this->_get_update_documentation_url() ) . '" target="_blank"> ' . esc_html__( 'Learn more here.', 'et-core' ) . ' </a> </p> '; } wp_send_json_error( array( 'errorIsUnrecoverable' => in_array( $success->get_error_code(), array( 'et_version_rollback_not_available', 'et_version_rollback_blocklisted' ) ), 'errorCode' => $success->get_error_code(), 'error' => $error, ), 400 ); } wp_send_json_success(); } /** * Execute a version rollback. * * @since 3.10 * * @return bool|WP_Error */ public function rollback() { // Load versions before rollback so they are not affected. $previous_version = $this->_get_previous_installed_version(); $latest_version = $this->_get_latest_installed_version(); $api = new ET_Core_API_ElegantThemes( $this->api_username, $this->api_key ); $available = $api->is_product_available( $this->product_name, $previous_version ); if ( is_wp_error( $available ) ) { $major_minor = implode( '.', array_slice( explode( '.', $previous_version ), 0, 2 ) ); if ( $major_minor . '.0' === $previous_version ) { // Skip the trailing 0 in the version number and retry. $previous_version = $major_minor; $available = $api->is_product_available( $this->product_name, $previous_version ); } if ( is_wp_error( $available ) ) { return $available; } } $download_url = $api->get_download_url( $this->product_name, $previous_version ); // Buffer and discard output as upgrader classes still output content even if the upgrader skin is silent. $buffer_started = ob_start(); $result = $this->_install_theme( $download_url ); if ( $buffer_started ) { ob_end_clean(); } if ( is_wp_error( $result ) ) { return $result; } if ( true !== $result ) { return new WP_Error( 'et_unknown', esc_html__( 'An unknown error has occurred. Please try again later.', 'et-core' ) ); } /** * Fires after successful product version rollback. * * @since 3.26 * * @param string $product_short_name - The short name of the product rolling back. * @param string $rollback_from_version - The product version rolling back from. * @param string $rollback_to_version - The product version rolling back to. */ do_action( 'et_after_version_rollback', $this->product_shortname, $latest_version, $previous_version ); // Swap version numbers after a successful rollback. $this->_set_previous_installed_version( $latest_version ); $this->_set_latest_installed_version( $previous_version ); } /** * Install a theme overwriting it if it already exists. * Copied from Theme_Upgrader::install() due to lack of control over the clear_desination argument. * * @see Theme_Upgrader::install() @ WordPress 4.9.4 * * @since 3.10 * * @param string $package * * @return bool|WP_Error */ protected function _install_theme( $package ) { require_once( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); $upgrader = new Theme_Upgrader( new ET_Core_LIB_SilentThemeUpgraderSkin() ); $defaults = array( 'clear_update_cache' => true, ); $parsed_args = wp_parse_args( array(), $defaults ); $upgrader->init(); $upgrader->install_strings(); add_filter('upgrader_source_selection', array( $upgrader, 'check_package' ) ); add_filter('upgrader_post_install', array( $upgrader, 'check_parent_theme_filter' ), 10, 3 ); if ( $parsed_args['clear_update_cache'] ) { // Clear cache so wp_update_themes() knows about the new theme. add_action( 'upgrader_process_complete', 'wp_clean_themes_cache', 9, 0 ); } $upgrader->run( array( 'package' => $package, 'destination' => get_theme_root(), 'clear_destination' => true, // Overwrite theme. 'clear_working' => true, 'hook_extra' => array( 'type' => 'theme', 'action' => 'install', ), ) ); remove_action( 'upgrader_process_complete', 'wp_clean_themes_cache', 9 ); remove_filter( 'upgrader_source_selection', array( $upgrader, 'check_package' ) ); remove_filter( 'upgrader_post_install', array( $upgrader, 'check_parent_theme_filter' ) ); if ( ! $upgrader->result || is_wp_error( $upgrader->result ) ) { return $upgrader->result; } // Refresh the Theme Update information. wp_clean_themes_cache( $parsed_args['clear_update_cache'] ); return true; } /** * Get update documentation url for the product. * * @since 3.10 * * @return string */ protected function _get_update_documentation_url() { return "https://www.elegantthemes.com/documentation/{$this->product_shortname}/update-{$this->product_shortname}/"; } /** * Return ePanel option. * * @since 3.10 * * @return array */ public function get_epanel_option() { return array( 'name' => esc_html__( 'Version Rollback', 'et-core' ), 'id' => 'et_version_rollback', 'type' => 'callback_function', 'function_name' => array( $this, 'render_epanel_option' ), 'desc' => et_get_safe_localization( __( 'If you recently updated to a new version and are experiencing problems, you can easily roll back to the previously-installed version. We always recommend using the latest version and testing updates on a staging site. However, if you run into problems after updating you always have the option to roll back.', 'et-core' ) ), ); } /** * Render ePanel option. * * @since 3.10 * * @return void */ public function render_epanel_option() { $previous = $this->_get_previous_installed_version(); $modal_renderer = array( $this, 'render_epanel_no_previous_version_modal' ); if ( ! empty( $previous ) ) { $modal_renderer = array( $this, 'render_epanel_confirm_rollback_modal' ); if ( $this->_is_rolled_back() ) { $modal_renderer = array( $this, 'render_epanel_already_rolled_back_modal' ); } } add_action( 'admin_footer', $modal_renderer ); ?> <button type="button" class="et-button et-button--simple" data-et-core-modal=".et-core-version-rollback-modal"> <?php esc_html_e( 'Rollback to the previous version', 'et-core' ); ?> </button> <?php } /** * Render ePanel warning modal when no previous supported version has been used. * * @since 3.10 * * @return void */ public function render_epanel_no_previous_version_modal() { ?> <div class="et-core-modal-overlay et-core-form et-core-version-rollback-modal et-core-modal-actionless"> <div class="et-core-modal"> <div class="et-core-modal-header"> <h3 class="et-core-modal-title"> <?php esc_html_e( 'Version Rollback', 'et-core' ); ?> </h3> <a href="#" class="et-core-modal-close" data-et-core-modal="close"></a> </div> <div id="et-core-version-rollback-modal-content"> <div class="et-core-modal-content"> <p> <?php printf( esc_html__( 'The previously used version of %1$s does not support version rollback.', 'et-core' ), esc_html( $this->product_name ) ); ?> </p> </div> </div> </div> </div> <?php } /** * Render ePanel confirmation modal for rollback. * * @since 3.10 * * @return void */ public function render_epanel_confirm_rollback_modal() { $action = $this->_get_ajax_action(); $url = add_query_arg( array( 'action' => $action, 'nonce' => wp_create_nonce( $action ), ), admin_url( 'admin-ajax.php' ) ); ?> <div class="et-core-modal-overlay et-core-form et-core-version-rollback-modal"> <div class="et-core-modal"> <div class="et-core-modal-header"> <h3 class="et-core-modal-title"> <?php esc_html_e( 'Version Rollback', 'et-core' ); ?> </h3> <a href="#" class="et-core-modal-close" data-et-core-modal="close"></a> </div> <div id="et-core-version-rollback-modal-content"> <div class="et-core-modal-content"> <p> <?php echo et_get_safe_localization( sprintf( __( 'You\'ll be rolled back to <strong>Version %1$s</strong> from the current <strong>Version %2$s</strong>.', 'et-core' ), esc_html( $this->_get_previous_installed_version() ), esc_html( $this->_get_latest_installed_version() ) ) ); ?> </p> <p> <?php echo et_get_safe_localization( sprintf( __( 'Rolling back will reinstall the previous version of %1$s. You will be able to update to the latest version at any time. <a href="%2$s" target="_blank">Learn more here</a>.', 'et-core' ), esc_html( $this->product_name ), esc_url( $this->_get_update_documentation_url() ) ) ); ?> </p> <p> <strong> <?php esc_html_e( 'Make sure you have a full site backup before proceeding.', 'et-core' ); ?> </strong> </p> </div> <a class="et-core-modal-action et-core-version-rollback-confirm" href="<?php echo esc_url( $url ); ?>"> <?php esc_html_e( 'Rollback to the previous version', 'et-core' ); ?> </a> </div> </div> </div> <?php } /** * Render ePanel warning modal when a rollback has already been done. * * @since 3.10 * * @return void */ public function render_epanel_already_rolled_back_modal() { ?> <div class="et-core-modal-overlay et-core-form et-core-version-rollback-modal"> <div class="et-core-modal"> <div class="et-core-modal-header"> <h3 class="et-core-modal-title"> <?php esc_html_e( 'Version Rollback', 'et-core' ); ?> </h3> <a href="#" class="et-core-modal-close" data-et-core-modal="close"></a> </div> <div id="et-core-version-rollback-modal-content"> <div class="et-core-modal-content"> <p> <?php echo et_get_safe_localization( sprintf( __( 'You\'re currently rolled back to <strong>Version %1$s</strong> from <strong>Version %2$s</strong>.', 'et-core' ), esc_html( $this->_get_latest_installed_version() ), esc_html( $this->_get_previous_installed_version() ) ) ); ?> </p> <p> <?php echo et_get_safe_localization( sprintf( __( 'Update to the latest version to unlock the full power of %1$s. <a href="%2$s" target="_blank">Learn more here</a>.', 'et-core' ), esc_html( $this->product_name ), esc_url( $this->_get_update_documentation_url() ) ) ); ?> </p> </div> <a class="et-core-modal-action" href="<?php echo esc_url( admin_url( 'update-core.php' ) ); ?>"> <?php esc_html_e( 'Update to the Latest Version', 'et-core' ); ?> </a> </div> </div> </div> <?php } /** * Store latest and previous installed version. * * @since 3.10 * * @return void; */ public function store_previous_version_number() { $previous_installed_version = $this->_get_previous_installed_version(); $latest_installed_version = $this->_get_latest_installed_version(); // Get the theme version since the files may have changed but // we are still executing old code from memory. $theme_version = et_get_theme_version(); if ( $latest_installed_version === $theme_version ) { return; } if ( empty( $latest_installed_version ) ) { $latest_installed_version = $theme_version; } if ( version_compare( $theme_version, $latest_installed_version, '!=') ) { $previous_installed_version = $latest_installed_version; $latest_installed_version = $theme_version; } /** * Fires after new version number is updated. * * @since 4.10.0 */ do_action( 'et_store_before_new_version_update' ); $this->_set_previous_installed_version( $previous_installed_version ); $this->_set_latest_installed_version( $latest_installed_version ); /** * Fires after new version number is updated. * * @since 4.10.0 */ do_action( 'et_store_after_new_version_update' ); } } endif; components/Logger.php 0000644 00000007324 15222641012 0010662 0 ustar 00 <?php class ET_Core_Logger { /** * @var ET_Core_Data_Utils */ protected static $_; /** * Checksum for every log message output during the current request. * * @var string[] */ protected static $HISTORY = array(); /** * Writes a message to the debug log if it hasn't already been written once. * * @since 3.10 * * @param mixed $message * @param int $bt_index * @param boolean $log_ajax Whether or not to log on AJAX calls. */ protected static function _maybe_write_log( $message, $bt_index = 4, $log_ajax = true ) { global $ET_IS_TESTING_DEPRECATIONS; if ( ! is_scalar( $message ) ) { $message = print_r( $message, true ); } $message = (string) $message; $hash = md5( $message ); if ( ! $log_ajax && wp_doing_ajax() ) { return; } if ( $ET_IS_TESTING_DEPRECATIONS ) { trigger_error( $message ); } else if ( getenv( 'CI' ) || ! in_array( $hash, self::$HISTORY ) ) { self::$HISTORY[] = $hash; self::_write_log( $message, $bt_index ); } } /** * Writes a message to the WP Debug and PHP Error logs. * * @param string $message * @param int $bt_index */ private static function _write_log( $message, $bt_index = 4 ) { $message = trim( $message ); $backtrace = debug_backtrace( 1 ); $class = ''; $function = ''; if ( ! isset( $backtrace[ $bt_index ] ) ) { while ( $bt_index > 0 && ! isset( $backtrace[ $bt_index ] ) ) { $bt_index--; } // We need two stacks to get all the data we need so let's go down one more $bt_index--; } $stack = $backtrace[ $bt_index ]; $file = self::$_->array_get( $stack, 'file', '<unknown file>' ); $line = self::$_->array_get( $stack, 'line', '<unknown line>' ); // Name of the function and class (if applicable) are in the previous stack (stacks are in reverse order) $stack = $backtrace[ $bt_index + 1 ]; $class = self::$_->array_get( $stack, 'class', '' ); $function = self::$_->array_get( $stack, 'function', '<unknown function>' ); if ( $class ) { $class .= '::'; } if ( '<unknown file>' !== $file ) { $file = _et_core_normalize_path( $file ); $parts = explode( '/', $file ); $parts = array_slice( $parts, -2 ); $file = ".../{$parts[0]}/{$parts[1]}"; } $message = " {$file}:{$line} {$class}{$function}():\n{$message}\n"; error_log( $message ); } /** * Writes message to the logs if {@link WP_DEBUG} is `true`, otherwise does nothing. * * @since 1.1.0 * * @param mixed $message * @param int $bt_index * @param boolean $log_ajax Whether or not to log on AJAX calls. */ public static function debug( $message, $bt_index = 4, $log_ajax = true ) { if ( defined( 'WP_DEBUG' ) && WP_DEBUG ) { self::_maybe_write_log( $message, $bt_index, $log_ajax ); } } public static function disable_php_notices() { $error_reporting = error_reporting(); $notices_enabled = $error_reporting & E_NOTICE; if ( $notices_enabled ) { error_reporting( $error_reporting & ~E_NOTICE ); } } /** * Writes an error message to the logs regardless of whether or not debug mode is enabled. * * @since 1.1.0 * * @param mixed $message * @param int $bt_index */ public static function error( $message, $bt_index = 4 ) { self::_maybe_write_log( $message, $bt_index ); } public static function enable_php_notices() { $error_reporting = error_reporting(); $notices_enabled = $error_reporting & E_NOTICE; if ( ! $notices_enabled ) { error_reporting( $error_reporting | E_NOTICE ); } } public static function initialize() { self::$_ = ET_Core_Data_Utils::instance(); } public static function php_notices_enabled() { $error_reporting = error_reporting(); return $error_reporting & E_NOTICE; } } ET_Core_Logger::initialize(); components/Updates.php 0000644 00000105650 15222641012 0011051 0 ustar 00 <?php // phpcs:disable Generic.WhiteSpace.ScopeIndent.Incorrect, Generic.WhiteSpace.ScopeIndent.IncorrectExact -- Until we reformat this entire file, this rule makes reviewing PRs very difficult. if ( ! class_exists( 'ET_Core_Updates' ) ): /** * Handles the updates workflow. * * @private * * @package ET\Core\Updates */ final class ET_Core_Updates { protected $core_url; protected $options; protected $account_status; protected $product_version; protected $all_et_products_domains; protected $upgrading_et_product; protected $up_to_date_products_data; // class version protected $version; // Is a product being upgraded in the current API request. protected $upgraded_a_product = false; private static $_this; function __construct( $core_url, $product_version ) { global $wp_version; // Don't allow more than one instance of the class if ( isset( self::$_this ) ) { wp_die( sprintf( esc_html__( '%s: You cannot create a second instance of this class.', 'et-core' ), esc_html( get_class( $this ) ) ) ); } self::$_this = $this; $this->core_url = $core_url; $this->version = '1.2'; $this->up_to_date_products_data = array(); $this->product_version = $product_version; $this->get_options(); $this->upgrading_et_product = false; $this->update_product_domains(); $this->maybe_force_update_requests(); add_filter( 'wp_prepare_themes_for_js', array( $this, 'replace_theme_update_notification' ) ); add_filter( 'upgrader_package_options', array( $this, 'check_upgrading_product' ) ); // The 4th parameter, $hook_extra was added in WordPress 5.5.0. if ( version_compare( $wp_version, '5.5.0', '>=' ) ) { add_filter( 'upgrader_pre_download', array( $this, 'update_error_message' ), 20, 4 ); } else { add_filter( 'upgrader_pre_download', array( $this, 'update_error_message' ), 20, 3 ); } add_filter( 'pre_set_site_transient_update_plugins', array( $this, 'check_plugins_updates' ) ); add_filter( 'plugins_api', array( $this, 'maybe_modify_plugins_changelog' ), 20, 3 ); add_filter( 'pre_set_site_transient_update_themes', array( $this, 'check_themes_updates' ) ); add_filter( 'self_admin_url', array( $this, 'change_plugin_changelog_url' ), 10, 2 ); add_filter( 'admin_url', array( $this, 'change_plugin_changelog_url' ), 10, 2 ); add_filter( 'network_admin_url', array( $this, 'change_plugin_changelog_url' ), 10, 2 ); add_action( 'admin_notices', array( $this, 'maybe_show_account_notice' ) ); add_action( 'admin_enqueue_scripts', array( $this, 'load_scripts_styles' ) ); add_action( 'plugins_loaded', array( $this, 'remove_updater_plugin_actions' ), 30 ); add_action( 'after_setup_theme', array( $this, 'remove_theme_update_actions' ), 11 ); add_action( 'admin_init', array( $this, 'remove_plugin_update_actions' ) ); add_action( 'update_site_option_et_automatic_updates_options', array( $this, 'force_update_requests' ) ); add_action( 'update_option_et_automatic_updates_options', array( $this, 'force_update_requests' ) ); add_action( 'deleted_site_transient', array( $this, 'maybe_reset_et_products_update_transient' ) ); add_action( 'upgrader_process_complete', array( $this, 'upgraded_a_product' ), 9, 0 ); } function check_upgrading_product( $options ) { if ( ! isset( $options['hook_extra'] ) ) { return $options; } $hook_name = isset( $options['hook_extra']['plugin'] ) ? 'plugin' : 'theme'; // set the upgrading_et_product flag if one of ET plugins or themes is about to upgrade if ( isset( $options['hook_extra'][ $hook_name ] ) && in_array( $options['hook_extra'][ $hook_name ], $this->all_et_products_domains[ $hook_name ] ) ) { $this->upgrading_et_product = true; } return $options; } function maybe_append_custom_notification( $plugin_data, $response ) { if ( empty( $response ) ) { $package_available = false; } else { // for themes response is array for plugins - object, so check the format of data to get the correct results $package_available = is_array( $response ) ? ! empty( $response['package'] ) : ! empty( $response->package ); } if ( $package_available ) { return; } $message = empty( $custom_message = $this->get_custom_update_notification_message( $plugin_data['url'] ) ) ? et_get_safe_localization( __( 'For all Elegant Themes products, please <a href="https://www.elegantthemes.com/documentation/divi/update-divi/" target="_blank">authenticate your subscription</a> via the Updates tab in your theme & plugin settings to enable product updates. Make sure that your Username and API Key have been entered correctly.', 'et-core' ) ) : $custom_message; echo "</p><p>{$message}"; } /** * Check if we need to force update options removal in case a customer clicked on "Check Again" button * in the notification area. */ function maybe_force_update_requests() { if ( wp_doing_ajax() ) { return; } if ( empty( $_GET['et_action'] ) || 'update_account_details' !== $_GET['et_action'] ) { return; } if ( empty( $_GET['et_update_account_details_nonce'] ) || ! wp_verify_nonce( $_GET['et_update_account_details_nonce'], 'et_update_account_details' ) ) { return; } $this->force_update_requests(); } function get_custom_update_notification_message( $update_message ) { $is_valid_api_key_status = empty( $account_api_key_status = get_site_option( 'et_account_api_key_status' ) ) || 'invalid' !== $account_api_key_status; if ( $is_valid_api_key_status && false !== strpos( $update_message, '/wp-json/api/v1/changelog/product_id/' ) ) { return et_get_safe_localization( __( '<em>The license for this Divi Marketplace product has expired. Please <a target="_blank" href="https://www.elegantthemes.com/members-area/marketplace/">renew the license</a> to continue receiving product updates and support.</em>', 'et-core' ) ); } if ( false !== strpos( $update_message, 'Automatic update is unavailable for this theme' ) ) { return 'expired' === $this->account_status ? et_get_safe_localization( __( '<em>Your Elegant Themes subscription has expired. You must <a href="https://www.elegantthemes.com/members-area/renew/" target="_blank">renew your account</a> to regain access to product updates and support.</em>', 'et-core' ) ) : et_get_safe_localization( __( '<em>Before you can receive product updates, you must first authenticate your Elegant Themes subscription. To do this, you need to enter both your Elegant Themes Username and your Elegant Themes API Key into the Updates Tab in your theme and plugin settings. To locate your API Key, <a href="https://www.elegantthemes.com/members-area/api/" target="_blank">log in</a> to your Elegant Themes account and navigate to the <strong>Account > API Key</strong> page. <a href="https://www.elegantthemes.com/documentation/divi/update-divi/" target="_blank">Learn more here</a></em>. If you still get this message, please make sure that your Username and API Key have been entered correctly', 'et-core' ) ); } return ''; } function replace_theme_update_notification( $themes_array ) { if ( empty( $themes_array ) ) { return $themes_array; } if ( empty( $this->all_et_products_domains['theme'] ) ) { return $themes_array; } foreach ( $themes_array as $id => $theme_data ) { // replace default error message with custom message for ET themes. if ( ! in_array( $id, $this->all_et_products_domains['theme'] ) || false === strpos( $theme_data['update'], 'Automatic update is unavailable for this theme' ) ) { continue; } if ( ! empty( $custom_message = $this->get_custom_update_notification_message( $theme_data['update'] ) ) ) { $themes_array[ $id ]['update'] = sprintf( '<p>%1$s<br/> %2$s</p>', $theme_data['update'], $custom_message ); } } return $themes_array; } function update_error_message( $reply, $package, $upgrader, $hook_extra = array() ) { if ( ! $this->upgrading_et_product ) { return $reply; } // reset the upgrading_et_product flag $this->upgrading_et_product = false; if ( ! empty( $package ) ) { return $reply; } $hook_name = ! empty( $hook_extra['theme'] ) ? 'theme' : 'plugin'; $site_transient = 'theme' === $hook_name ? get_site_transient( 'et_update_themes' ) : get_site_transient( 'et_update_plugins' ); $changelog_url = ''; if ( isset( $site_transient->response ) && ! empty( $site_transient->response[ $hook_extra[ $hook_name ] ] ) ) { $changelog_url = 'theme' === $hook_name ? $site_transient->response[ $hook_extra[ $hook_name ] ]['url'] : $site_transient->response[ $hook_extra[ $hook_name ] ]->url; } if ( false !== strpos( $changelog_url, '/wp-json/api/v1/changelog/product_id/' ) ) { $error_message = $this->get_custom_update_notification_message( $changelog_url ); } else { $error_message = 'expired' === $this->account_status ? et_get_safe_localization( __( '<em>Your Elegant Themes subscription has expired. You must <a href="https://www.elegantthemes.com/members-area/renew/" target="_blank">renew your account</a> to regain access to product updates and support.</em>', 'et-core' ) ) : et_get_safe_localization( __( '<em>Before you can receive product updates, you must first authenticate your Elegant Themes subscription. To do this, you need to enter both your Elegant Themes Username and your Elegant Themes API Key into the Updates Tab in your theme and plugin settings. To locate your API Key, <a href="https://www.elegantthemes.com/members-area/api/" target="_blank">log in</a> to your Elegant Themes account and navigate to the <strong>Account > API Key</strong> page. <a href="https://www.elegantthemes.com/documentation/divi/update-divi/" target="_blank">Learn more here</a></em>. If you still get this message, please make sure that your Username and API Key have been entered correctly', 'et-core' ) ); } // output custom error message for ET Products if package is empty return new WP_Error( 'no_package', $error_message ); } /** * Get all Elegant Themes products, returned from the API request */ function get_et_api_products() { $products = array( 'theme' => array(), 'plugin' => array(), ); $update_transients = array( 'et_update_themes', 'et_update_plugins', ); foreach ( $update_transients as $update_transient_name ) { $type = 'et_update_themes' === $update_transient_name ? 'theme' : 'plugin'; if ( false !== ( $update_transient = get_site_transient( $update_transient_name ) ) && ! empty( $update_transient->response ) && is_array( $update_transient->response ) ) { $et_product_stylesheet_names = array_keys( $update_transient->response ); foreach ( $et_product_stylesheet_names as $et_product_stylesheet_name ) { $products[ $type ][] = $et_product_stylesheet_name; } } } return $products; } function get_all_et_products() { $checked_et_products = $this->get_et_api_products(); return $checked_et_products; } function remove_theme_update_actions() { remove_filter( 'pre_set_site_transient_update_themes', 'et_check_themes_updates' ); remove_filter( 'site_transient_update_themes', 'et_add_themes_to_update_notification' ); } function remove_plugin_update_actions() { remove_filter( 'pre_set_site_transient_update_plugins', 'et_shortcodes_plugin_check_updates' ); remove_filter( 'site_transient_update_plugins', 'et_shortcodes_plugin_add_to_update_notification' ); } /** * Removes Updater plugin actions and filters, * so it doesn't make additional requests to API * * @return void */ function remove_updater_plugin_actions() { if ( ! class_exists( 'ET_Automatic_Updates' ) ) { return; } $updates_class = ET_Automatic_Updates::get_this(); remove_filter( 'after_setup_theme', array( $updates_class, 'remove_default_updates' ), 11 ); remove_filter( 'init', array( $updates_class, 'remove_default_plugins_updates' ), 20 ); remove_action( 'admin_notices', array( $updates_class, 'maybe_display_expired_message' ) ); } /** * Returns an instance of the object * * @return object */ static function get_this() { return self::$_this; } /** * Adds automatic updates data only if Username and API key options are set * * @param array $send_to_api Data sent to server * @return array Modified data set if Username and API key are set, original data if not */ function maybe_add_automatic_updates_data( $send_to_api ) { if ( $this->options && isset( $this->options['username'] ) && isset( $this->options['api_key'] ) ) { $send_to_api['automatic_updates'] = 'on'; $send_to_api['username'] = urlencode( sanitize_text_field( $this->options['username'] ) ); $send_to_api['api_key'] = sanitize_text_field( $this->options['api_key'] ); $send_to_api = apply_filters( 'et_add_automatic_updates_data', $send_to_api ); } return $send_to_api; } /** * Gets plugin options * * @return void */ function get_options() { if ( ! $this->options = get_site_option( 'et_automatic_updates_options' ) ) { $this->options = get_option( 'et_automatic_updates_options' ); } if ( ! $this->account_status = get_site_option( 'et_account_status' ) ) { $this->account_status = get_option( 'et_account_status' ); } } function load_scripts_styles( $hook ) { if ( 'plugin-install.php' !== $hook ) { return; } wp_enqueue_style( 'et_core_updates', $this->core_url . 'admin/css/updates.css', array(), $this->product_version ); } function add_up_to_date_products_data( $update_data, $settings = array() ) { $settings = $this->process_request_settings( $settings ); $products_category = $settings['is_plugin_response'] ? 'plugins' : 'themes'; if ( ! empty( $this->up_to_date_products_data[ $products_category ] ) ) { $update_data->no_update = $this->up_to_date_products_data[ $products_category ]; } return $update_data; } /** * Merges product information from cached et updates transients * to the main WordPress updates transients. * * @param array $update_transient The main WordPress themes or plugins updates transient. * @param array $et_update_products_data The cached et themes or plugins updates transient. * @return array */ function merge_et_products_response( $update_transient, $et_update_products_data ) { // If $et_update_products_data is empty or both its response and no_update arrays are empty, there is no cached data to merge and we can return the main WordPress transient. if ( empty( $et_update_products_data ) || ( empty( $et_update_products_data->response ) && empty( $et_update_products_data->no_update ) ) ) { return $update_transient; // Return the original transient if true. } // Fields to merge. $merge_data_fields = array( 'response', 'no_update', ); // Merge the fields. foreach ( $merge_data_fields as $data_field_name ) { if ( empty( $et_update_products_data->$data_field_name ) ) { continue; // Skip if the field is empty. } // Get the default response data. $default_response_data = ! empty( $update_transient->$data_field_name ) ? $update_transient->$data_field_name : array(); // Merge the data. $update_transient->$data_field_name = array_merge( $default_response_data, (array) $et_update_products_data->$data_field_name ); } // Check if the response array is empty in the cached transient, which is where products that need to be updated are listed. Before merging, we need to make sure the latest version isn't already installed, in which case it needs to be moved to the no_update array. if ( ! empty( $et_update_products_data->response ) ) { foreach ( $et_update_products_data->response as $product => $data ) { // Get the currently installed product version from the primary WordPress update transient. $installed_version = isset( $update_transient->checked[ $product ] ) ? $update_transient->checked[ $product ] : null; // Get the latest product version from the cached transient, handling both array and object cases. if ( is_array( $data ) ) { $latest_version = isset( $data['new_version'] ) ? $data['new_version'] : null; } elseif ( is_object( $data ) ) { $latest_version = isset( $data->new_version ) ? $data->new_version : null; } // If the currently installed version is the latest version, we need to move the product to the no_update array and remove the product from the response array. if ( $installed_version && $latest_version && version_compare( $installed_version, $latest_version, '>=' ) ) { $update_transient->no_update[ $product ] = $data; unset( $update_transient->response[ $product ] ); } } } // Now we need to do the opposite. Check if the no_update array is empty in the cached transient, which is where products that don't need to be updated are listed. If an update is required, move the product to the response array. if ( ! empty( $et_update_products_data->no_update ) ) { foreach ( $et_update_products_data->no_update as $product => $data ) { // Get the currently installed product version from the primary WordPress update transient. $installed_version = isset( $update_transient->checked[ $product ] ) ? $update_transient->checked[ $product ] : null; // Get the latest product version from the cached transient, handling both array and object cases. if ( is_array( $data ) ) { $latest_version = isset( $data['new_version'] ) ? $data['new_version'] : null; } elseif ( is_object( $data ) ) { $latest_version = isset( $data->new_version ) ? $data->new_version : null; } // If the currently installed version is not the latest version, we need to move the product to the response array and remove the product from the no_update array. if ( $installed_version && $latest_version && version_compare( $installed_version, $latest_version, '<' ) ) { $update_transient->response[ $product ] = $data; unset( $update_transient->no_update[ $product ] ); } } } return $update_transient; // Return the merged transient updated with the most recently cached product info. } function check_plugins_updates( $update_transient ) { global $wp_version; if ( ! isset( $update_transient->response ) ) { return $update_transient; } $plugins = []; $et_update_plugins = get_site_transient( 'et_update_plugins' ); // update_plugins transient gets set two times, so we ensure we make a request once if ( ! $this->upgraded_a_product && isset( $et_update_plugins->last_checked ) && isset( $update_transient->last_checked ) && $et_update_plugins->last_checked > ( $update_transient->last_checked - 10 * MINUTE_IN_SECONDS ) ) { return $this->merge_et_products_response( $update_transient, $et_update_plugins ); } $_plugins = get_plugins(); if ( empty( $_plugins ) ) { return $update_transient; } foreach ( $_plugins as $file => $plugin ) { $update_uri = isset( $plugin['UpdateURI'] ) ? $plugin['UpdateURI'] : ''; $is_et_uri = false !== strpos( $update_uri, 'elegantthemes.com' ); // Continue to the next iteration if the Update URI // is not empty and not using Elegant Themes's domain. if ( ! empty( $update_uri ) && ! $is_et_uri ) { continue; } $plugins[ $file ] = $plugin['Version']; } do_action( 'et_core_updates_before_request' ); $send_to_api = array( 'action' => 'check_all_plugins_updates', 'installed_plugins' => $plugins, 'class_version' => $this->version, ); // Add automatic updates data if Username and API key are set correctly $send_to_api = $this->maybe_add_automatic_updates_data( $send_to_api ); // If we don't have update values cached in the transient, we need to bypass rate limiting. if ( $et_update_plugins ) { $rate_limit = 'true'; } else { $rate_limit = 'false'; } $options = array( 'timeout' => ( ( defined('DOING_CRON') && DOING_CRON ) ? 10 : 3), 'body' => $send_to_api, 'headers' => array( 'rate_limit' => $rate_limit, ), 'user-agent' => 'WordPress/' . $wp_version . '; Plugin Updates/' . ET_CORE_VERSION . '; ' . home_url( '/' ), ); $last_update = new stdClass(); $plugins_request = wp_remote_post( 'https://www.elegantthemes.com/api/api.php', $options ); $plugins_response = []; $et_update_plugins_updated = false; if ( ! is_wp_error( $plugins_request ) && wp_remote_retrieve_response_code( $plugins_request ) === 200 ){ $plugins_response = maybe_unserialize( wp_remote_retrieve_body( $plugins_request ) ); if ( ! empty( $plugins_response ) && is_array( $plugins_response ) ) { $et_update_plugins_updated = true; $request_settings = array( 'is_plugin_response' => true ); $plugins_response = $this->process_additional_response_settings( $plugins_response, $request_settings ); $last_update->checked = $plugins; $last_update->response = $plugins_response; $last_update = $this->add_up_to_date_products_data( $last_update, $request_settings ); $last_update->last_checked = time(); $update_transient = $this->merge_et_products_response( $update_transient, $plugins_response ); set_site_transient( 'et_update_plugins', $last_update ); $this->update_product_domains(); } } // if this is a rate limited or failed request, fallback to the last et_update_plugins value // rather than overwrite it with an empty response if ( ! $et_update_plugins_updated ) { $update_transient = $this->merge_et_products_response( $update_transient, $et_update_plugins ); } return $update_transient; } public function maybe_modify_plugins_changelog( $false, $action, $args ) { if ( 'plugin_information' !== $action ) { return $false; } if ( isset( $args->slug ) ) { $et_update_lb_plugin = get_site_transient( 'et_update_plugins' ); $plugin_basename = sprintf( '%1$s/%1$s.php', sanitize_text_field( $args->slug ) ); if ( isset( $et_update_lb_plugin->response[ $plugin_basename ] ) ) { $plugin_info = $et_update_lb_plugin->response[ $plugin_basename ]; if ( isset( $plugin_info->et_sections_used ) && 'on' === $plugin_info->et_sections_used ) { return $plugin_info; } } } return $false; } function process_account_settings( $response ) { if ( empty( $response['et_account_data'] ) ) { return $response; } $additional_settings_fields = array( 'et_username_status', 'et_api_key_status', 'et_expired_subscription', ); $et_account_data = $response['et_account_data']; $additional_settings = array(); $is_theme_response = is_array( $et_account_data ); foreach ( $additional_settings_fields as $additional_settings_field ) { $field = ''; $field_exists = $is_theme_response ? array_key_exists( $additional_settings_field, $et_account_data ) : ! empty( $et_account_data->$additional_settings_field ); if ( $field_exists ) { $field = $is_theme_response ? $et_account_data[ $additional_settings_field ] : $et_account_data->$additional_settings_field; } $additional_settings[ $additional_settings_field ] = $field; } if ( ! empty( $additional_settings[ 'et_username_status' ] ) && in_array( $additional_settings[ 'et_username_status' ], array( 'active', 'expired', 'not_found' ) ) ) { $this->account_status = sanitize_text_field( $additional_settings['et_username_status'] ); } else { // Set the account status to expired if the response array has 'et_expired_subscription' key $this->account_status = ! empty( $additional_settings[ 'et_expired_subscription' ] ) ? 'expired' : 'active'; } update_site_option( 'et_account_status', $this->account_status ); if ( ! empty( $additional_settings[ 'et_api_key_status' ] ) ) { update_site_option( 'et_account_api_key_status', sanitize_text_field( $additional_settings['et_api_key_status'] ) ); } else { delete_site_option( 'et_account_api_key_status' ); } unset( $response['et_account_data'] ); return $response; } function process_up_to_date_products_settings( $response, $settings ) { if ( empty( $response['et_up_to_date_products'] ) ) { return $response; } $products_category = $settings['is_plugin_response'] ? 'plugins' : 'themes'; $this->up_to_date_products_data[ $products_category ] = $response['et_up_to_date_products']; unset( $response['et_up_to_date_products'] ); return $response; } function process_request_settings( $settings = array() ) { $defaults = array( 'is_plugin_response' => false, ); return array_merge( $defaults, $settings ); } function process_additional_response_settings( $response, $settings = array() ) { if ( empty( $response ) ) { return $response; } $settings = $this->process_request_settings( $settings ); $response = $this->process_account_settings( $response ); $response = $this->process_up_to_date_products_settings( $response, $settings ); return $response; } /** * Sends a request to server, gets current themes versions * * @param object $update_transient Update transient option * @return object Update transient option */ function check_themes_updates( $update_transient ){ global $wp_version; $et_update_themes = get_site_transient( 'et_update_themes' ); // update_themes transient gets set two times, so we ensure we make a request once if ( ! $this->upgraded_a_product && isset( $et_update_themes->last_checked ) && isset( $update_transient->last_checked ) && $et_update_themes->last_checked > ( $update_transient->last_checked - 10 * MINUTE_IN_SECONDS ) ) { return $this->merge_et_products_response( $update_transient, $et_update_themes ); } if ( ! isset( $update_transient->checked ) ) { return $update_transient; } $themes = $update_transient->checked; do_action( 'et_core_updates_before_request' ); $send_to_api = array( 'action' => 'check_theme_updates', 'installed_themes' => $themes, 'class_version' => $this->version, ); // Add automatic updates data if Username and API key are set correctly $send_to_api = $this->maybe_add_automatic_updates_data( $send_to_api ); // If we don't have update values cached in the transient, we need to bypass rate limiting. if ( $et_update_themes ) { $rate_limit = 'true'; } else { $rate_limit = 'false'; } $options = array( 'timeout' => ( ( defined('DOING_CRON') && DOING_CRON ) ? 10 : 3 ), 'body' => $send_to_api, 'headers' => array( 'rate_limit' => $rate_limit, ), 'user-agent' => 'WordPress/' . $wp_version . '; Theme Updates/' . ET_CORE_VERSION . '; ' . home_url( '/' ), ); $last_update = new stdClass(); $theme_request = wp_remote_post( 'https://www.elegantthemes.com/api/api.php', $options ); $theme_response = []; $et_update_themes_updated = false; if ( ! is_wp_error( $theme_request ) && wp_remote_retrieve_response_code( $theme_request ) === 200 ){ $theme_response = maybe_unserialize( wp_remote_retrieve_body( $theme_request ) ); if ( ! empty( $theme_response ) && is_array( $theme_response ) ) { $et_update_themes_updated = true; $theme_response = $this->process_additional_response_settings( $theme_response ); $last_update->checked = $themes; $last_update->response = $theme_response; $last_update = $this->add_up_to_date_products_data( $last_update ); $last_update->last_checked = time(); $update_transient = $this->merge_et_products_response( $update_transient, $last_update ); set_site_transient( 'et_update_themes', $last_update ); $this->update_product_domains(); } } // if this is a rate limited or failed request, fallback to the last et_update_themes value // rather than overwrite it with an empty response if ( ! $et_update_themes_updated ) { $update_transient = $this->merge_et_products_response( $update_transient, $et_update_themes ); } return $update_transient; } function maybe_show_account_notice() { // Don't show notice on onboarding page. if ( isset( $_GET['page'] ) && 'et_onboarding' === $_GET['page'] ) { return; } if ( empty( $this->options['username'] ) || empty( $this->options['api_key'] ) ) { return; } $all_products = $this->get_et_api_products(); $total_products = count( $all_products['theme'] ) + count( $all_products['plugin'] ); if ( 1 === $total_products && et_()->includes( $all_products['plugin'], 'Divi Dash' ) ) { // Don't show the notice when Divi Dash is the only product return; } $output = ''; $messages = array(); $account_api_key_status = get_site_option( 'et_account_api_key_status' ); $is_expired_account = 'expired' === $this->account_status; $is_invalid_account = 'not_found' === $this->account_status; if ( ! $is_expired_account && ! $is_invalid_account && empty( $account_api_key_status ) ) { return; } if ( $is_expired_account ) { $messages[] = et_get_safe_localization( __( 'Your Elegant Themes subscription has expired. You must <a href="https://www.elegantthemes.com/members-area/" target="_blank">renew your account</a> to regain access to product updates and support. To ensure compatibility and security, it is important to always keep your themes and plugins updated.', 'et-core' ) ); } else if ( $is_invalid_account ) { $messages[] = et_get_safe_localization( __( 'The Elegant Themes username you entered is invalid. Please enter a valid username to receive product updates. If you forgot your username you can <a href="https://www.elegantthemes.com/members-area/retrieve-username/" target="_blank">request it here</a>.', 'et-core' ) ); } if ( ! empty( $account_api_key_status ) ) { switch ( $account_api_key_status ) { case 'deactivated': $status = 'not active'; break; default: $status = 'invalid'; break; } $messages[] = et_get_safe_localization( __( sprintf( 'The Elegant Themes API key you entered is %1$s. Please make sure that your API has been entered correctly and that it is <a href="https://www.elegantthemes.com/members-area/api/" target="_blank">enabled</a> in your account.', $status ), 'et-core' ) ); } foreach ( $messages as $message ) { $output .= sprintf( '<p>%1$s</p>', $message ); } if ( empty( $output ) ) { return; } $dashboard_url = add_query_arg( 'et_action', 'update_account_details', admin_url( 'update-core.php' ) ); printf( '<div class="notice notice-warning"> %1$s <p><a href="%2$s">%3$s</a></p> </div>', $output, esc_url( wp_nonce_url( $dashboard_url, 'et_update_account_details', 'et_update_account_details_nonce' ) ), esc_html__( 'Check Again', 'et-core' ) ); } function change_plugin_changelog_url( $url, $path ) { if ( 0 !== strpos( $path, 'plugin-install.php?tab=plugin-information&plugin=' ) ) { return $url; } $matches = array(); $update_transient = get_site_transient( 'et_update_plugins' ); $et_updated_plugins_data = get_transient( 'et_updated_plugins_data' ); $has_last_checked = ! empty( $update_transient->last_checked ) && ! empty( $et_updated_plugins_data->last_checked ); if ( ! is_object( $update_transient ) ) { return $url; } /* * Attempt to use a cached list of updated plugins. * Re-save the list, whenever the update transient last checked time changes. */ if ( false === $et_updated_plugins_data || ( $has_last_checked && $update_transient->last_checked !== $et_updated_plugins_data->last_checked ) ) { $et_updated_plugins_data = new stdClass(); if ( ! empty( $update_transient->last_checked ) ) { $et_updated_plugins_data->last_checked = $update_transient->last_checked; } foreach ( $update_transient->response as $response_plugin_settings ) { $slug = sanitize_text_field( $response_plugin_settings->slug ); $et_updated_plugins_data->changelogs[ $slug ] = esc_url_raw( $response_plugin_settings->url . '?TB_iframe=true&width=1024&height=800' ); } set_transient( 'et_updated_plugins_data', $et_updated_plugins_data ); } if ( ! empty( $update_transient->no_update ) ) { foreach ( $update_transient->no_update as $no_update_plugin_settings ) { $slug = sanitize_text_field( $no_update_plugin_settings->slug ); $et_updated_plugins_data->changelogs[ $slug ] = esc_url_raw( $no_update_plugin_settings->url . '?TB_iframe=true&width=1024&height=800' ); } } preg_match( '/plugin=([^&]*)/', $path, $matches ); $current_plugin_slug = $matches[1]; // Check if we're dealing with a product that has a custom changelog URL if ( ! empty( $et_updated_plugins_data->changelogs[ $current_plugin_slug ] ) ) { $url = esc_url_raw( $et_updated_plugins_data->changelogs[ $current_plugin_slug ] ); } return $url; } function force_update_requests() { $update_transients = array( 'update_themes', 'update_plugins', 'et_update_themes', 'et_update_plugins', ); foreach ( $update_transients as $update_transient ) { if ( get_site_transient( $update_transient ) ) { delete_site_transient( $update_transient ); } } } function update_product_domains() { $this->all_et_products_domains = $this->get_all_et_products(); $append_notification_action_name = 'maybe_append_custom_notification'; // update notifications for ET products if needed foreach ( array( 'theme', 'plugin' ) as $product_type ) { if ( empty( $this->all_et_products_domains[ $product_type] ) ) { continue; } foreach ( $this->all_et_products_domains[ $product_type ] as $product_key ) { $action_name = sanitize_text_field( sprintf( 'in_%1$s_update_message-%2$s', $product_type, $product_key ) ); if ( has_action( $action_name, array( $this, $append_notification_action_name ) ) ) { continue; } add_action( $action_name, array( $this, $append_notification_action_name ), 10, 2 ); } } } /** * Delete Elegant Themes update products transient, whenever default WordPress update transient gets removed */ function maybe_reset_et_products_update_transient( $transient_name ) { // Transient names for update transients we're interested in. $update_transients_names = array( 'update_themes' => 'et_update_themes', 'update_plugins' => 'et_update_plugins', ); // Check if the transient name is one of the update transients we're interested in. if ( empty( $update_transients_names[ $transient_name ] ) ) { return; } // Check the last_checked time in the transient, and only delete it if it's older than 24 hours. $et_update_transient = get_site_transient( $update_transients_names[ $transient_name ] ); if ( ! empty( $et_update_transient->last_checked ) && $et_update_transient->last_checked > ( time() - DAY_IN_SECONDS ) ) { return; } // Delete the ET update transient, because it's older than 24 hours. delete_site_transient( $update_transients_names[ $transient_name ] ); } /** * Detects if the current API request is related to a product update. * In this case, we need to allow the request to bypass rate limiting * since the update process requests two requests. */ function upgraded_a_product() { $this->upgraded_a_product = true; } } endif; if ( ! function_exists( 'et_core_enable_automatic_updates' ) ) : function et_core_enable_automatic_updates( $deprecated, $version ) { if ( ! is_admin() && ! wp_doing_cron() ) { return; } if ( isset( $GLOBALS['et_core_updates'] ) ) { return; } if ( defined( 'ET_CORE_URL' ) ) { $url = ET_CORE_URL; } else { $url = trailingslashit( $deprecated ) . 'core/'; } $GLOBALS['et_core_updates'] = new ET_Core_Updates( $url, $version ); } endif; components/Portability.php 0000644 00000316770 15222641012 0011755 0 ustar 00 <?php /** * Import and Export data. * * @package Core\Portability */ /** * Handles the portability workflow. * * @package ET\Core\Portability */ class ET_Core_Portability { /** * Current instance. * * @since 2.7.0 * * @type object */ public $instance; /** * @var ET_Core_Data_Utils */ protected static $_; /** * Whether or not an import is in progress. * * @since 3.0.99 * * @var bool */ protected static $_doing_import = false; /** * Constructor. * * @param string $context Portability context previously registered. */ public function __construct( $context ) { $this->instance = et_core_cache_get( $context, 'et_core_portability' ); self::$_ = ET_Core_Data_Utils::instance(); if ( $this->instance && $this->instance->view ) { if ( et_core_is_fb_enabled() ) { $this->assets(); } else { add_action( 'admin_footer', array( $this, 'modal' ) ); add_action( 'customize_controls_print_footer_scripts', array( $this, 'modal' ) ); add_action( 'admin_enqueue_scripts', array( $this, 'assets' ), 5 ); } } } public static function doing_import() { return self::$_doing_import; } /** * Import a previously exported layout. * * @since 3.10 Return the result of the import instead of dieing. * @since 2.7.0 * * @param string $file_context Accepts 'upload', 'sideload'. Default 'upload'. * * @return bool|array */ public function import( $file_context = 'upload' ) { global $shortname; $this->prevent_failure(); self::$_doing_import = true; $timestamp = $this->get_timestamp(); $filesystem = $this->set_filesystem(); $temp_file_id = sanitize_file_name( $timestamp ); $temp_file = $this->has_temp_file( $temp_file_id, 'et_core_import' ); // phpcs:disable WordPress.Security.NonceVerification.Missing -- Nonce verification is handled earlier. $include_global_presets = isset( $_POST['include_global_presets'] ) ? wp_validate_boolean( sanitize_text_field( $_POST['include_global_presets'] ) ) : false; $return_json = isset( $_POST['et_cloud_return_json'] ) ? wp_validate_boolean( sanitize_text_field( $_POST['et_cloud_return_json'] ) ) : false; $temp_presets = isset( $_POST['et_cloud_use_temp_presets'] ) ? wp_validate_boolean( sanitize_text_field( $_POST['et_cloud_use_temp_presets'] ) ) : false; $is_update_preset_id = isset( $_POST['onboarding'] ) ? wp_validate_boolean( sanitize_text_field( $_POST['onboarding'] ) ) : false; $preset_prefix = isset( $_POST['preset_prefix'] ) ? sanitize_text_field( $_POST['preset_prefix'] ) : ''; // phpcs:enable WordPress.Security.NonceVerification.Missing $global_presets = ''; if ( $temp_file ) { $import = json_decode( $filesystem->get_contents( $temp_file ), true ); } else { if ( ! isset( $_FILES['file']['name'] ) || ! et_()->ends_with( sanitize_file_name( $_FILES['file']['name'] ), '.json' ) ) { return array( 'message' => 'invalideFile' ); } if ( ! in_array( $file_context, array( 'upload', 'sideload' ) ) ) { $file_context = 'upload'; } $handle_file = "wp_handle_{$file_context}"; $upload = $handle_file( $_FILES['file'], array( 'test_size' => false, 'test_type' => false, 'test_form' => false, ) ); /** * Fires before an uploaded Portability JSON file is processed. * * @since 3.0.99 * * @param string $file The absolute path to the uploaded JSON file's temporary location. */ do_action( 'et_core_portability_import_file', $upload['file'] ); $temp_file = $this->temp_file( $temp_file_id, 'et_core_import', $upload['file'] ); $file_content = preg_replace( '/\x{FEFF}/u', '', $filesystem->get_contents( $temp_file ) ); // Replace BOM with empty string. $import = json_decode( $file_content, true ); $import = $this->validate( $import ); if ( $return_json ) { return array( 'jsonFromFile' => $import ); } // Check if Import contains Google Api Settings. if ( isset( $import['data']['et_google_api_settings'] ) && ( 'epanel' === $this->instance->context || 'epanel_temp' === $this->instance->context ) ) { $et_google_api_settings = $import['data']['et_google_api_settings']; } if ( ! isset( $import['context'] ) || ( isset( $import['context'] ) && $import['context'] !== $this->instance->context ) ) { $this->delete_temp_files( 'et_core_import', [ $temp_file_id => $temp_file ] ); return array( 'message' => 'importContextFail' ); } $import['data'] = $this->apply_query( $import['data'], 'set' ); $filesystem->put_contents( $upload['file'], wp_json_encode( (array) $import ) ); } // Upload images and replace current urls. if ( isset( $import['images'] ) ) { $images = $this->maybe_paginate_images( (array) $import['images'], 'upload_images', $timestamp ); $import['data'] = $this->replace_images_urls( $images, $import['data'] ); } if ( ! empty( $import['global_colors'] ) ) { $import['data'] = $this->_maybe_inject_gcid( $import['data'], $import['global_colors'] ); } $data = $import['data']; $success = array( 'timestamp' => $timestamp ); $this->delete_temp_files( 'et_core_import', [ $temp_file_id => $temp_file ] ); if ( 'options' === $this->instance->type ) { // Reset all data besides excluded data. $current_data = $this->apply_query( get_option( $this->instance->target, array() ), 'unset' ); if ( isset( $data['wp_custom_css'] ) && function_exists( 'wp_update_custom_css_post' ) ) { wp_update_custom_css_post( $data['wp_custom_css'] ); if ( 'yes' === get_theme_mod( 'et_pb_css_synced', 'no' ) ) { // If synced, clear the legacy custom css value to avoid unwanted merging of old and new css. $data[ "{$shortname}_custom_css" ] = ''; } } // Import Google API settings. if ( isset( $et_google_api_settings ) ) { // Get exising Google API key, sine it is not added to export. $et_previous_google_api_settings = get_option( 'et_google_api_settings' ); $et_previous_google_api_key = isset( $et_previous_google_api_settings['api_key'] ) ? $et_previous_google_api_settings['api_key'] : ''; $et_google_api_settings['api_key'] = $et_previous_google_api_key; update_option( 'et_google_api_settings', $et_google_api_settings ); } // Merge remaining current data with new data and update options. update_option( $this->instance->target, array_merge( $current_data, $data ) ); set_theme_mod( 'et_pb_css_synced', 'no' ); } // Pass the post content and let js save the post. if ( 'post' === $this->instance->type ) { $success['postContent'] = reset( $data ); // In some cases we receive the post array instaed of shortcode string. Handle this case. $shortcode_string = is_array( $success['postContent'] ) && ! empty( $success['postContent']['post_content'] ) ? $success['postContent']['post_content'] : $success['postContent']; if ( ! empty( $import['presets'] ) ) { $preset_rewrite_map = []; if ( $include_global_presets && ! $is_update_preset_id ) { $preset_rewrite_map = $this->prepare_to_import_layout_presets( $import['presets'] ); $global_presets = $import['presets']; } $shortcode_object = et_fb_process_shortcode( $shortcode_string ); if ( $is_update_preset_id ) { $global_presets = $import['presets']; $vb_presets_lookup = $this->_get_importing_presets_id_name_pairs( $global_presets ); $this->_update_shortcode_with_onboarding_preset( $shortcode_object, $vb_presets_lookup ); } else { $this->rewrite_module_preset_ids( $shortcode_object, $import['presets'], $preset_rewrite_map ); } $shortcode_string = et_fb_process_to_shortcode( $shortcode_object, array(), '', false ); } do_shortcode( $shortcode_string ); $success['postContent'] = $shortcode_string; $success['migrations'] = ET_Builder_Module_Settings_Migration::$migrated; $success['presets'] = isset( $import['presets'] ) && is_array( $import['presets'] ) ? $import['presets'] : (object) array(); } if ( 'post_type' === $this->instance->type ) { $preset_rewrite_map = array(); if ( ! empty( $import['presets'] ) && $include_global_presets ) { $preset_rewrite_map = $this->prepare_to_import_layout_presets( $import['presets'] ); $global_presets = $import['presets']; } foreach ( $data as &$post ) { $shortcode_object = et_fb_process_shortcode( $post['post_content'] ); if ( ! empty( $import['presets'] ) ) { if ( $include_global_presets ) { $this->rewrite_module_preset_ids( $shortcode_object, $import['presets'], $preset_rewrite_map ); } else { $this->_apply_global_presets( $shortcode_object, $import['presets'] ); } } $post_content = et_fb_process_to_shortcode( $shortcode_object, array(), '', false ); // Add slashes for post content to avoid unwanted unslashing (by wp_unslash) while post is inserting. $post['post_content'] = wp_slash( $post_content ); // Upload thumbnail image if exist. if ( ! empty( $post['post_meta'] ) && ! empty( $post['post_meta']['_thumbnail_id'] ) ) { $post_thumbnail_origin_id = (int) $post['post_meta']['_thumbnail_id'][0]; if ( ! empty( $import['thumbnails'] ) && ! empty( $import['thumbnails'][ $post_thumbnail_origin_id ] ) ) { $post_thumbnail_new = $this->upload_images( $import['thumbnails'][ $post_thumbnail_origin_id ] ); $new_thumbnail_data = reset( $post_thumbnail_new ); // New thumbnail image was uploaded and it should be updated. if ( isset( $new_thumbnail_data['replacement_id'] ) ) { $new_thumbnail_id = $new_thumbnail_data['replacement_id']; $post['thumbnail'] = $new_thumbnail_id; if ( ! function_exists( 'wp_crop_image' ) ) { include ABSPATH . 'wp-admin/includes/image.php'; } $thumbnail_path = get_attached_file( $new_thumbnail_id ); // Generate all the image sizes and update thumbnail metadata. $new_metadata = wp_generate_attachment_metadata( $new_thumbnail_id, $thumbnail_path ); wp_update_attachment_metadata( $new_thumbnail_id, $new_metadata ); } } } } $imported_posts = $this->import_posts( $data ); if ( false === $imported_posts ) { /** * Filters the error message when {@see ET_Core_Portability::import()} fails. * * @since 3.0.99 * * @param mixed $error_message Default is `null`. */ if ( $error_message = apply_filters( 'et_core_portability_import_error_message', false ) ) { $error_message = array( 'message' => $error_message ); } return $error_message; } else { $success['imported_posts'] = $imported_posts; } } if ( ! empty( $global_presets ) ) { if ( ! $this->import_global_presets( $global_presets, $temp_presets, true, $preset_prefix, true ) ) { if ( $error_message = apply_filters( 'et_core_portability_import_error_message', false ) ) { $error_message = array( 'message' => $error_message ); } return $error_message; } } if ( ! empty( $import['global_colors'] ) ) { $this->import_global_colors( $import['global_colors'] ); $success['globalColors'] = et_builder_get_all_global_colors( true ); } return $success; } /** * Initiate Export. * * @since 2.7.0 * * @param bool $return * * @return null|array */ public function export( $return = false, $include_used_presets = false ) { $this->prevent_failure(); et_core_nonce_verified_previously(); $timestamp = $this->get_timestamp(); $filesystem = $this->set_filesystem(); $temp_file_id = sanitize_file_name( $timestamp ); $temp_file = $this->has_temp_file( $temp_file_id, 'et_core_export' ); $apply_global_presets = isset( $_POST['apply_global_presets'] ) ? wp_validate_boolean( $_POST['apply_global_presets'] ) : false; $global_presets = ''; $global_colors = ''; $thumbnails = ''; if ( $temp_file ) { $file_data = json_decode( $filesystem->get_contents( $temp_file ) ); $data = (array) $file_data->data; $global_presets = $file_data->presets; $global_colors = $file_data->global_colors; } else { $temp_file = $this->temp_file( $temp_file_id, 'et_core_export' ); if ( 'options' === $this->instance->type ) { $data = get_option( $this->instance->target, array() ); // Export the Customizer "Additional CSS" value as well. if ( function_exists( 'wp_get_custom_css' ) ) { $data[ 'wp_custom_css' ] = wp_get_custom_css(); } } if ( 'post' === $this->instance->type ) { if ( ! ( isset( $_POST['post'] ) || isset( $_POST['content'] ) ) ) { wp_send_json_error(); } $fields_validatation = array( 'ID' => 'intval', // no post_content as the default case for no fields_validation will run it through perms based wp_kses_post, which is exactly what we want. ); $post_data = array( 'post_content' => stripcslashes( $_POST['content'] ), // need to run this through stripcslashes() as thats what wp_kses_post() expects. 'ID' => $_POST['post'], ); $post_data = $this->validate( $post_data, $fields_validatation ); $data = array( $post_data['ID'] => $post_data['post_content'] ); if ( isset( $_POST['global_presets'] ) ) { // phpcs:ignore ET.Sniffs.ValidatedSanitizedInput.InputNotSanitized -- filter_post_data() function does sanitation. $post_global_presets = $this->_filter_post_data( $_POST['global_presets'] ); $global_presets = json_decode( stripslashes( $post_global_presets ) ); } if ( isset( $_POST['global_colors'] ) ) { // phpcs:ignore ET.Sniffs.ValidatedSanitizedInput.InputNotSanitized -- filter_post_data() function does sanitation. $post_global_colors = $this->_filter_post_data( $_POST['global_colors'] ); $global_colors = json_decode( stripslashes( $post_global_colors ) ); } if ( $include_used_presets ) { $used_global_presets = array(); $used_global_colors = array(); $shortcode_object = et_fb_process_shortcode( $post_data['post_content'] ); $used_global_presets = array_merge( $this->get_used_global_presets( $shortcode_object, $used_global_presets ), $used_global_presets ); if ( ! empty( $used_global_presets ) ) { $global_presets = (object) $used_global_presets; } $used_global_colors = $this->_get_used_global_colors( $shortcode_object, $used_global_colors, $global_presets ); if ( ! empty( $used_global_colors ) ) { $global_colors = $this->_get_global_colors_data( $used_global_colors ); } } } if ( 'post_type' === $this->instance->type ) { $data = $this->export_posts_query(); } $data = $this->apply_query( $data, 'set' ); // Export Google API settings. if ( 'epanel' === $this->instance->context || 'epanel_temp' === $this->instance->context ) { $et_google_api_settings = get_option( 'et_google_api_settings', array() ); // Unset google api_key settings to prevent exporting it. if ( isset( $et_google_api_settings['api_key'] ) ) { unset( $et_google_api_settings['api_key'] ); } $data['et_google_api_settings'] = $et_google_api_settings; } if ( 'post_type' === $this->instance->type ) { $used_global_presets = array(); $used_global_colors = array(); $options = array( 'apply_global_presets' => true, ); foreach ( $data as $post ) { $shortcode_object = et_fb_process_shortcode( $post->post_content ); // We have to always process global presets to get the global colors correctly. $global_presets_from_post = $this->get_used_global_presets( $shortcode_object, $used_global_presets ); $used_global_presets = array_merge( $global_presets_from_post, $used_global_presets ); $used_global_colors = $this->_get_used_global_colors( $shortcode_object, $used_global_colors, $global_presets_from_post ); if ( $apply_global_presets ) { $shortcode_object = et_fb_process_to_shortcode( $shortcode_object, $options, '', false ); $post->post_content = $shortcode_object; } } if ( ! empty ( $used_global_presets ) ) { $global_presets = (object) $used_global_presets; } if ( ! empty( $used_global_colors ) ) { $global_colors = $this->_get_global_colors_data( $used_global_colors ); } } // put contents into file, this is temporary, // if images get paginated, this content will be brought back out // of a temp file in paginated request $file_data = array( 'data' => $data, 'presets' => $global_presets, 'global_colors' => $global_colors, ); $filesystem->put_contents( $temp_file, wp_json_encode( $file_data ) ); } $thumbnails = $this->_get_thumbnail_images( $data ); $images = $this->get_data_images( $data ); $data = array( 'context' => $this->instance->context, 'data' => $data, 'presets' => $global_presets, 'global_colors' => $global_colors, 'images' => $this->maybe_paginate_images( $images, 'encode_images', $timestamp ), 'thumbnails' => $thumbnails, ); // Return exported content instead of printing it if ( $return ) { return array_merge( $data, [ 'timestamp' => $timestamp ] ); } $filesystem->put_contents( $temp_file, wp_json_encode( (array) $data ) ); wp_send_json_success( array( 'timestamp' => $timestamp ) ); } /** * Serialize a single layout post in chunks. * * @since 4.0 * * @param integer $id Unique ID to represent this layout serialization. * @param integer $post_id * @param string $content * @param array $theme_builder_meta * @param integer $chunk * * @return array */ public function serialize_layout( $id, $post_id, $content, $theme_builder_meta = array(), $chunk = 0 ) { $this->prevent_failure(); $fields_validatation = array( // No post_content as the default case for no fields_validation will run it through perms based wp_kses_post, which is exactly what we want. 'ID' => 'intval', ); $post_data = array( // Need to run this through stripcslashes() as thats what wp_kses_post() expects. 'post_content' => stripcslashes( $content ), 'ID' => $post_id, ); $shortcode_object = et_fb_process_shortcode( $post_data['post_content'] ); $used_global_colors = $this->get_theme_builder_library_used_global_colors( $shortcode_object ); $post_data = $this->validate( $post_data, $fields_validatation ); $data = array( $post_data['ID'] => $post_data['post_content'] ); $data = $this->apply_query( $data, 'set' ); $images = $this->get_data_images( $data ); $images = $this->chunk_images( $images, 'encode_images', $id, $chunk ); // Generate list of used global colors. if ( ! empty( $used_global_colors ) ) { $global_colors = $this->_get_global_colors_data( $used_global_colors ); } $data = array( 'context' => 'et_builder', 'data' => $data, 'images' => $images['images'], 'post_title' => get_post_field( 'post_title', $post_id ), 'post_type' => get_post_type( $post_id ), 'theme_builder' => $theme_builder_meta, 'global_colors' => $global_colors, ); $chunks = $images['chunks']; $ready = $images['ready']; return array( 'ready' => $ready, 'chunks' => $chunks, 'data' => $data, ); } /** * Serialize Theme Builder templates in chunks. * * @since 4.0 * * @param integer $id Unique ID to represent this theme builder serialization process. * @param array $step * @param integer $steps * @param integer $step_index * @param integer $chunk * * @return array|false */ public function serialize_theme_builder( $id, $step, $steps, $step_index = 0, $chunk = 0 ) { if ( $step_index >= $steps ) { return false; } $this->prevent_failure(); $temp_file_id = sanitize_file_name( 'et_theme_builder_' . $id ); $temp_file = $this->has_temp_file( $temp_file_id, 'et_core_export' ); if ( $temp_file ) { $data = json_decode( $this->get_filesystem()->get_contents( $temp_file ), true ); } else { $temp_file = $this->temp_file( $temp_file_id, 'et_core_export' ); $data = array( 'context' => 'et_theme_builder', 'templates' => array(), 'layouts' => array(), 'presets' => array(), 'has_default_template' => false, 'has_global_layouts' => false, ); } $chunks = 1; switch ( $step['type'] ) { case 'template': $header_id = $step['data']['layouts']['header']['id']; $body_id = $step['data']['layouts']['body']['id']; $footer_id = $step['data']['layouts']['footer']['id']; $is_default = $step['data']['default']; if ( 0 !== $header_id && ! current_user_can( 'edit_post', $header_id ) ) { $step['data']['layouts']['header']['id'] = 0; } if ( 0 !== $body_id && ! current_user_can( 'edit_post', $body_id ) ) { $step['data']['layouts']['body']['id'] = 0; } if ( 0 !== $footer_id && ! current_user_can( 'edit_post', $footer_id ) ) { $step['data']['layouts']['footer']['id'] = 0; } if ( $is_default ) { $data['has_default_template'] = true; } $data['templates'][] = $step['data']; break; case 'layout': $post_id = $step['data']['post_id']; $is_global = $step['data']['is_global']; if ( ! current_user_can( 'edit_post', $post_id ) ) { break; } if ( 0 === $chunk && isset( $data['layouts'][ $post_id ] ) ) { // The layout is already exported. break; } if ( $is_global ) { $data['has_global_layouts'] = true; } $step_data = $this->serialize_layout( $id, $post_id, get_post_field( 'post_content', $post_id ), array( 'is_global' => $is_global, ), $chunk ); $step_data['data']['post_meta'] = array_merge( et_()->array_get( $step_data, 'data.post_meta', array() ), et_core_get_post_builder_meta( $post_id ) ); $data['layouts'][ $post_id ] = $step_data['data']; $chunks = $step_data['chunks']; break; case 'presets': $data['presets'] = $step['data']; break; } $ready = ( $step_index + 1 >= $steps ) && ( $chunk + 1 >= $chunks ); if ( ! $ready ) { $this->get_filesystem()->put_contents( $temp_file, wp_json_encode( $data ) ); } else { $this->delete_temp_files( 'et_core_export', array( $temp_file_id => $temp_file ) ); } return array( 'ready' => $ready, 'chunks' => $chunks, 'data' => $data, ); } /** * Export Theme Builder templates in chunks. * * @since 4.0 * * @param integer $id Unique ID to represent this theme builder export process. * @param array $step * @param integer $steps * @param integer $step_index * @param integer $chunk * * @return array|false */ public function export_theme_builder( $id, $step, $steps, $step_index = 0, $chunk = 0 ) { $result = $this->serialize_theme_builder( $id, $step, $steps, $step_index, $chunk ); if ( false === $result ) { return false; } $temp_file_id = sanitize_file_name( 'et_theme_builder_export_' . $id ); $temp_file = $this->temp_file( $temp_file_id, 'et_core_export' ); if ( $result['ready'] ) { $this->get_filesystem()->put_contents( $temp_file, wp_json_encode( $result[ 'data' ] ) ); } return array_merge( $result, array( 'temp_file' => $temp_file, 'temp_file_id' => $temp_file_id, ) ); } /** * Get whether an array represents a valid Theme Builder export. * * @since 4.0 * * @param array $export * * @return boolean */ public function is_valid_theme_builder_export( $export ) { $valid_context = isset( $export['context'] ) && $export['context'] === $this->instance->context; $has_templates = isset( $export['templates'] ) && is_array( $export['templates'] ); $has_layouts = isset( $export['layouts'] ) && is_array( $export['layouts'] ); return $valid_context && $has_templates && $has_layouts; } /** * Import a single layout in chunks. * * @since 4.0 * * @param string $id Unique ID to represent this layout serialization. * @param array $layout * @param integer $chunk * * @return array|false */ public function import_layout( $id, $layout, $chunk = 0 ) { $post_id = 0; $import = $this->validate( $layout ); if ( false === $import ) { return false; } $import['data'] = $this->apply_query( $import['data'], 'set' ); if ( ! isset( $import['context'] ) || ( isset( $import['context'] ) && 'et_builder' !== $import['context'] ) ) { return false; } $result = $this->chunk_images( self::$_->array_get( $import, 'images', array() ), 'upload_images', $id, $chunk ); if ( $result['ready'] ) { $import['data'] = $this->replace_images_urls( $result['images'], $import['data'] ); $post_type = self::$_->array_get( $import, 'post_type', 'post' ); $post_title = self::$_->array_get( $import, 'post_title', '' ); $post_status = self::$_->array_get( $import, 'post_status', 'publish' ); $post_meta = self::$_->array_get( $import, 'post_meta', array() ); $post_type_object = get_post_type_object( $post_type ); if ( ! $post_type_object || ! current_user_can( $post_type_object->cap->create_posts ) ) { return false; } $content = array_values( $import['data'] ); $content = $content[0]; $args = array( 'post_status' => $post_status, 'post_type' => $post_type, 'post_content' => current_user_can( 'unfiltered_html' ) ? $content : wp_kses_post( $content ), ); if ( ! empty( $post_title ) ) { $args['post_title'] = current_user_can( 'unfiltered_html' ) ? $post_title : wp_kses( $post_title, 'entities' ); } $post_id = et_theme_builder_insert_layout( $args ); if ( is_wp_error( $post_id ) ) { return false; } foreach ( $post_meta as $entry ) { update_post_meta( $post_id, $entry['key'], $entry['value'] ); } // Import Global Colors for each layout. if ( ! empty( $import['global_colors'] ) ) { $this->import_global_colors( $import['global_colors'] ); } } return array( 'ready' => $result['ready'], 'chunks' => $result['chunks'], 'id' => $post_id, ); } /** * Get importing presets ID and name pairs from presets data. * * @since 4.26.1 * * @param array $presets Presets data. */ protected function _get_importing_presets_id_name_pairs( $presets ) { $presets_lookup = []; foreach ( $presets as $module_type => $value ) { $presets_lookup[ $module_type ] = []; foreach ( $value['presets'] as $module_preset_id => $preset ) { $presets_lookup[ $module_type ][ $module_preset_id ] = $preset['name']; } } return $presets_lookup; } /** * Import Theme Builder templates in chunks. * * @since 4.0 * * @param integer $id Unique ID to represent this theme builder import process. * @param array $step * @param integer $steps * @param integer $step_index * @param integer $chunk * * @return array|false */ public function import_theme_builder( $id, $step, $steps, $step_index = 0, $chunk = 0 ) { if ( $step_index >= $steps ) { return false; } $layout_id_map = array(); $chunks = 1; if ( ! isset( $step['type'] ) ) { $step['type'] = ''; } switch ( $step['type'] ) { case 'layout': $presets = et_()->array_get( $step, 'presets', array() ); $presets_rewrite_map = et_()->array_get( $step, 'presets_rewrite_map', array() ); $is_update_preset_id = et_()->array_get( $step, 'is_update_preset_id', false ); $import_presets = et_()->array_get( $step, 'import_presets', false ); $layouts = et_()->array_get( $step['data'], 'data', array() ); if ( $is_update_preset_id ) { $tb_presets_lookup = $this->_get_importing_presets_id_name_pairs( $presets ); } // Apply any presets to the layouts' shortcodes prior to importing them. if ( ! empty( $presets ) && ! empty( $layouts ) ) { foreach ( $layouts as $key => $layout ) { $shortcode_object = et_fb_process_shortcode( $layout ); if ( $import_presets ) { if ( $is_update_preset_id ) { $this->_update_shortcode_with_onboarding_preset( $shortcode_object, $tb_presets_lookup ); } else { $this->rewrite_module_preset_ids( $shortcode_object, $presets, $presets_rewrite_map ); } } else { $this->_apply_global_presets( $shortcode_object, $presets ); } $layouts[ $key ] = et_fb_process_to_shortcode( $shortcode_object, array(), '', false ); } $step['data']['data'] = $layouts; } $result = $this->import_layout( $id, $step['data'], $chunk ); if ( false === $result ) { break; } if ( $result['ready'] ) { if ( ! isset( $layout_id_map[ $step['id'] ] ) ) { $layout_id_map[ $step['id'] ] = array(); } // Since a single layout can be duplicated multiple times if // it's global we have to keep an array of duplicated ids. $layout_id_map[ $step['id'] ][ $step['template_id'] ] = $result['id']; } $chunks = $result['chunks']; break; } $ready = ( $step_index + 1 >= $steps ) && ( $chunk + 1 >= $chunks ); return array( 'ready' => $ready, 'chunks' => $chunks, 'layout_id_map' => $layout_id_map, ); } /** * Download temporary file. * * @since 4.0 * * @param string $filename * @param string $temp_file_id * @param string $temp_file * @return void */ public function download_file( $filename, $temp_file_id, $temp_file ) { $this->prevent_failure(); $filename = sanitize_file_name( $filename ); header( 'Content-Description: File Transfer' ); header( "Content-Disposition: attachment; filename=\"{$filename}.json\"" ); header( 'Content-Type: application/json' ); header( 'Pragma: no-cache' ); if ( file_exists( $temp_file ) ) { echo et_core_esc_previously( $this->get_filesystem()->get_contents( $temp_file ) ); } $this->delete_temp_files( 'et_core_export', array( $temp_file_id => $temp_file ) ); wp_die(); } /** * Download Export Data. * * @since 2.7.0 */ public function download_export() { $this->prevent_failure(); et_core_nonce_verified_previously(); // Retrieve data. $timestamp = isset( $_GET['timestamp'] ) ? sanitize_text_field( $_GET['timestamp'] ) : null; $name = isset( $_GET['name'] ) ? sanitize_text_field( rawurldecode( $_GET['name'] ) ) : $this->instance->name; $filesystem = $this->set_filesystem(); $temp_file = $this->temp_file( sanitize_file_name( $timestamp ), 'et_core_export' ); header( 'Content-Description: File Transfer' ); header( "Content-Disposition: attachment; filename=\"{$name}.json\"" ); header( 'Content-Type: application/json' ); header( 'Pragma: no-cache' ); if ( file_exists( $temp_file ) ) { echo et_core_esc_previously( $filesystem->get_contents( $temp_file ) ); } $this->delete_temp_files( 'et_core_export' ); exit; } protected function to_megabytes( $value ) { $unit = strtoupper( substr( $value, -1 ) ); $amount = intval( substr( $value, 0, -1 ) ); // Known units switch ( $unit ) { case 'G': return $amount << 10; case 'M': return $amount; } if ( is_numeric( $unit ) ) { // Numeric unit is present, assume bytes return intval( $value ) >> 20; } // Unknown unit ... return intval( $value ); }// end to_megabytes() /** * Get selected posts data. * * @since 2.7.0 */ protected function export_posts_query() { et_core_nonce_verified_previously(); $args = array( 'post_type' => $this->instance->target, 'posts_per_page' => -1, 'no_found_rows' => true, ); // Only include selected posts if set and not empty. if ( isset( $_POST['selection'] ) ) { $include = json_decode( stripslashes( $_POST['selection'] ), true ); if ( ! empty( $include ) ) { $include = array_map( 'intval', array_values( $include ) ); $args['post__in'] = $include; } } $get_posts = get_posts( apply_filters( "et_core_portability_export_wp_query_{$this->instance->context}", $args ) ); $taxonomies = get_object_taxonomies( $this->instance->target ); $posts = array(); foreach ( $get_posts as $key => $post ) { unset( $post->post_author, $post->guid ); $posts[$post->ID] = $post; // Include post meta. $post_meta = (array) get_post_meta( $post->ID ); if ( isset( $post_meta['_edit_lock'] ) ) { unset( $post_meta['_edit_lock'], $post_meta['_edit_last'] ); } $posts[$post->ID]->post_meta = $post_meta; // Include terms. $get_terms = (array) wp_get_object_terms( $post->ID, $taxonomies ); $terms = array(); // Order terms to make sure children are after the parents. while ( $term = array_shift( $get_terms ) ) { if ( 0 === $term->parent || isset( $terms[$term->parent] ) ) { $terms[$term->term_id] = $term; } else { // if parent category is also exporting then add the term to the end of the list and process it later // otherwise add a term as usual if ( $this->is_parent_term_included( $get_terms, $term->parent ) ) { $get_terms[] = $term; } else { $terms[$term->term_id] = $term; } } } $posts[$post->ID]->terms = array(); foreach ( $terms as $term ) { $parents_data = array(); if ( $term->parent ) { $parent_slug = isset( $terms[$term->parent] ) ? $terms[$term->parent]->slug : $this->get_parent_slug( $term->parent, $term->taxonomy ); $parents_data = $this->get_all_parents( $term->parent, $term->taxonomy ); } else { $parent_slug = 0; } $posts[$post->ID]->terms[$term->term_id] = array( 'name' => $term->name, 'slug' => $term->slug, 'taxonomy' => $term->taxonomy, 'parent' => $parent_slug, 'all_parents' => $parents_data, 'description' => $term->description ); } } return $posts; } /** * Check whether the $parent_id included into the $terms_list. * * @since 2.7.0 * * @param array $terms_list Array of term objects. * @param int $parent_id . * * @return bool */ protected function is_parent_term_included( $terms_list, $parent_id ) { $is_parent_found = false; foreach ( $terms_list as $term => $term_details ) { if ( $parent_id === $term_details->term_id ) { $is_parent_found = true; } } return $is_parent_found; } /** * Retrieve the term slug. * * @since 2.7.0 * * @param int $parent_id . * @param string $taxonomy . * * @return int|string */ protected function get_parent_slug( $parent_id, $taxonomy ) { $term_data = get_term( $parent_id, $taxonomy ); $slug = '' === $term_data->slug ? 0 : $term_data->slug; return $slug; } /** * Prepare array of all parents so the correct hierarchy can be restored during the import. * * @since 2.7.0 * * @param int $parent_id . * @param string $taxonomy . * * @return array */ protected function get_all_parents( $parent_id, $taxonomy ) { $parents_data_array = array(); $parent = $parent_id; // retrieve data for all parent categories if ( 0 !== $parent ) { while( 0 !== $parent ) { $parent_term_data = get_term( $parent, $taxonomy ); $parents_data_array[$parent_term_data->slug] = array( 'name' => $parent_term_data->name, 'description' => $parent_term_data->description, 'parent' => 0 !== $parent_term_data->parent ? $this->get_parent_slug( $parent_term_data->parent, $taxonomy ) : 0, ); $parent = $parent_term_data->parent; } } //reverse order of items, to simplify the restoring process return array_reverse( $parents_data_array ); } /** * Check if a layout exists in the database already based on both its title and its slug. * * @param string $title * @param string $slug * * @return int $post_id The post id if it exists, zero otherwise. */ protected static function layout_exists( $title, $slug ) { global $wpdb; return (int) $wpdb->get_var( $wpdb->prepare( "SELECT ID FROM $wpdb->posts WHERE post_title = %s AND post_name = %s", array( wp_unslash( sanitize_post_field( 'post_title', $title, 0, 'db' ) ), wp_unslash( sanitize_post_field( 'post_name', $slug, 0, 'db' ) ), ) ) ); } /** * Update shortcode with onboarding preset. * * @since 4.26.1 * * @param array $shortcode_object - The shortcode object to be updated. * @param array $presets_lookup - The lookup table for presets. */ protected function _update_shortcode_with_onboarding_preset( &$shortcode_object, $presets_lookup ) { $global_presets_manager = ET_Builder_Global_Presets_Settings::instance(); $module_preset_attribute = ET_Builder_Global_Presets_Settings::MODULE_PRESET_ATTRIBUTE; $global_presets = $global_presets_manager->get_global_presets(); foreach ( $shortcode_object as &$module ) { $module_type = $global_presets_manager->maybe_convert_module_type( $module['type'], $module['attrs'] ); if ( isset( $presets_lookup[ $module_type ] ) ) { $module_preset_id = et_()->array_get( $module, "attrs.{$module_preset_attribute}", 'default' ); if ( 'default' === $module_preset_id ) { continue; } $module_preset_name = et_()->array_get( $presets_lookup, "{$module_type}.{$module_preset_id}", '' ); foreach ( $global_presets->$module_type->presets as $preset_id => $preset ) { if ( $preset->name === $module_preset_name ) { $module['attrs'][ $module_preset_attribute ] = $preset_id; break; } } } if ( isset( $module['content'] ) && is_array( $module['content'] ) ) { $this->_update_shortcode_with_onboarding_preset( $module['content'], $presets_lookup ); } } } /** * Imports Global Presets * * @since 4.0.10 Made public. * * @param array $presets - The Global Presets to be imported. * @param bool $is_temp_presets - Whether the presets are temporary or not. * @param bool $override_defaults - Whether the default presets should be overridden. * @param string $preset_prefix - A prefix to be prepended to preset name of the preset being imported, if override_defaults is true. * @param bool $skip_default - Whether updating the default preset key should be skipped. * * @return boolean */ public function import_global_presets( $presets, $is_temp_presets = false, $override_defaults = false, $preset_prefix = '', $skip_default = false ) { if ( ! is_array( $presets ) ) { return false; } $all_modules = ET_Builder_Element::get_modules(); $module_presets_manager = ET_Builder_Global_Presets_Settings::instance(); $global_presets = $module_presets_manager->get_global_presets(); $temp_presets = $module_presets_manager->get_temp_presets(); $presets_to_import = array(); foreach ( $presets as $module_type => $module_presets ) { $presets_to_import[ $module_type ] = array( 'presets' => array(), ); if ( ! isset( $global_presets->$module_type->presets ) ) { $initial_preset_structure = ET_Builder_Global_Presets_Settings::generate_module_initial_presets_structure( $module_type, $all_modules ); $global_presets->$module_type = $initial_preset_structure; } if ( $override_defaults && ! $skip_default ) { $global_presets->$module_type->default = $module_presets['default']; } $local_presets = $global_presets->$module_type->presets; $local_preset_names = array(); foreach ( $local_presets as $preset_id => $preset ) { // Skip temp presets. if ( ! isset( $temp_preset[ $module_type ]['presets'][ $preset_id ] ) ) { array_push( $local_preset_names, $preset->name ); } } foreach ( $module_presets['presets'] as $preset_id => $preset ) { $name = sanitize_text_field( $preset['name'] ); if ( $override_defaults && $preset_prefix ) { $name = $preset_prefix . ' ' . $name; // No duplicates allowed on override. if ( in_array( $name, $local_preset_names, true ) ) { continue; } } else { if ( in_array( $name, $local_preset_names, true ) ) { $name .= ' ' . esc_html__( 'imported', 'et-core' ); } } $presets_to_import[ $module_type ]['presets'][ $preset_id ] = array( 'name' => $name, 'created' => time() * 1000, 'updated' => time() * 1000, 'version' => $preset['version'], 'settings' => $preset['settings'], ); } } if ( $is_temp_presets ) { et_update_option( ET_Builder_Global_Presets_Settings::GLOBAL_PRESETS_OPTION_TEMP, $presets_to_import ); } // Merge existing Global Presets with imported ones foreach ( $presets_to_import as $module_type => $module_presets ) { foreach ( $module_presets['presets'] as $preset_id => $preset ) { $global_presets->$module_type->presets->$preset_id = (object) array(); $global_presets->$module_type->presets->$preset_id->name = sanitize_text_field( $preset['name'] ); $global_presets->$module_type->presets->$preset_id->created = $preset['created']; $global_presets->$module_type->presets->$preset_id->updated = $preset['updated']; $global_presets->$module_type->presets->$preset_id->version = $preset['version']; $global_presets->$module_type->presets->$preset_id->settings = (object) array(); foreach ( $preset['settings'] as $setting_name => $value ) { $setting_name_sanitized = sanitize_text_field( $setting_name ); $value_sanitized = sanitize_text_field( $value ); $global_presets->$module_type->presets->$preset_id->settings->$setting_name_sanitized = $value_sanitized; } // Inject Global colors into imported presets. $preset_settings = (array) $global_presets->$module_type->presets->$preset_id->settings; $global_presets->$module_type->presets->$preset_id->settings = ET_Builder_Global_Presets_Settings::maybe_set_global_colors( $preset_settings ); } } // Update option for product setting (last attr in args list). et_update_option( ET_Builder_Global_Presets_Settings::GLOBAL_PRESETS_OPTION, $global_presets, false, '', '', true ); if ( ! $is_temp_presets ) { $global_presets_history = ET_Builder_Global_Presets_History::instance(); $global_presets_history->add_global_history_record( $global_presets ); } return true; } /** * Prepare to import non-duplicate presets. * * @since 4.26.0 * * @param array $presets Presets to import. * * @return array */ public function prepare_to_import_non_duplicate_presets( $presets ) { $global_presets_manager = ET_Builder_Global_Presets_Settings::instance(); $existing_presets = $global_presets_manager->get_global_presets(); $existing_names = []; foreach ( $existing_presets as $module_slug => $data ) { foreach ( $data->presets as $preset ) { $existing_names[ $module_slug ][ trim( $preset->name ) ] = true; } } foreach ( $presets as $module_slug => $data ) { foreach ( $data['presets'] as $preset_id => $preset ) { if ( isset( $existing_names[ $module_slug ][ trim( $preset['name'] ) ] ) ) { unset( $presets[ $module_slug ]['presets'][ $preset_id ] ); } } } return $presets; } /** * Import global colors. * * @since 4.9.0 * * @param array $incoming_global_colors Global Colors Array. * * @return void */ public function import_global_colors( $incoming_global_colors ) { $excluded_colors = array( 'gcid-primary-color', 'gcid-secondary-color', 'gcid-heading-color', 'gcid-body-color' ); $global_colors = array(); foreach ( $incoming_global_colors as $incoming_gcolor ) { $key = et_()->sanitize_text_fields( $incoming_gcolor[0] ); // Skip excluded colors. if ( in_array( $key, $excluded_colors, true ) ) { continue; } $global_colors[ $key ] = et_()->sanitize_text_fields( $incoming_gcolor[1] ); } $stored_global_colors = et_builder_get_all_global_colors(); if ( ! empty( $stored_global_colors ) ) { $global_colors = array_merge( $global_colors, $stored_global_colors ); } et_update_option( 'et_global_colors', $global_colors ); } /** * Import post. * * @since 2.7.0 * * @param array $posts Array of data formatted by the portability exporter. * * @return bool */ protected function import_posts( $posts ) { /** * Filters the array of builder layouts to import. Returning an empty value will * short-circuit the import process. * * @since 3.0.99 * * @param array $posts */ $posts = apply_filters( 'et_core_portability_import_posts', $posts ); $imported_posts = array(); if ( empty( $posts ) ) { return false; } foreach ( $posts as $post ) { if ( isset( $post['post_status'] ) && 'auto-draft' === $post['post_status'] ) { continue; } $fields_validatation = array( 'ID' => 'intval', 'post_title' => 'sanitize_text_field', 'post_type' => 'sanitize_text_field', ); if ( ! $post = $this->validate( $post, $fields_validatation ) ) { continue; } $layout_exists = self::layout_exists( $post['post_title'], $post['post_name'] ); if ( $layout_exists && get_post_type( $layout_exists ) === $post['post_type'] ) { // Make sure the post is published. if ( 'publish' !== get_post_status( $layout_exists ) ) { wp_update_post( array( 'ID' => intval( $layout_exists ), 'post_status' => 'publish', ) ); } $imported_posts[] = intval( $layout_exists ); continue; } $post['import_id'] = $post['ID']; unset( $post['ID'] ); $post['post_author'] = (int) get_current_user_id(); // Insert or update post. $post_id = wp_insert_post( $post, true ); if ( ! $post_id || is_wp_error( $post_id ) ) { continue; } $imported_posts[] = $post_id; // Insert and set terms. if ( isset( $post['terms'] ) && is_array( $post['terms'] ) ) { $processed_terms = array(); foreach ( $post['terms'] as $term ) { $fields_validatation = array( 'name' => 'sanitize_text_field', 'slug' => 'sanitize_title', 'taxonomy' => 'sanitize_title', 'parent' => 'sanitize_title', 'description' => 'wp_kses_post', ); if ( ! $term = $this->validate( $term, $fields_validatation ) ) { continue; } if ( empty( $term['parent'] ) ) { $parent = 0; } else { if ( isset( $term['all_parents'] ) && ! empty( $term['all_parents'] ) ) { $this->restore_parent_categories( $term['all_parents'], $term['taxonomy'] ); } $parent = term_exists( $term['parent'], $term['taxonomy'] ); if ( is_array( $parent ) ){ $parent = $parent['term_id']; } } if ( ! $insert = term_exists( $term['slug'], $term['taxonomy'] ) ) { $insert = wp_insert_term( $term['name'], $term['taxonomy'], array( 'slug' => $term['slug'], 'description' => $term['description'], 'parent' => intval( $parent ), ) ); } if ( is_array( $insert ) && ! is_wp_error( $insert ) ) { $processed_terms[$term['taxonomy']][] = $term['slug']; } } // Set post terms. foreach ( $processed_terms as $taxonomy => $ids ) { wp_set_object_terms( $post_id, $ids, $taxonomy ); } } // Insert or update post meta. if ( isset( $post['post_meta'] ) && is_array( $post['post_meta'] ) ) { foreach ( $post['post_meta'] as $meta_key => $meta ) { $meta_key = sanitize_text_field( $meta_key ); if ( count( $meta ) < 2 ) { $meta = wp_kses_post( $meta[0] ); } else { $meta = array_map( 'wp_kses_post', $meta ); } update_post_meta( $post_id, $meta_key, $meta ); } } // Assign new thumbnail if provided. if ( isset( $post['thumbnail'] ) ) { set_post_thumbnail( $post_id, $post['thumbnail'] ); } } return $imported_posts; } /** * Restore the categories hierarchy in library. * * @since 2.7.0 * * @param array $parents_array Array of parent categories data. * @param string $taxonomy */ protected function restore_parent_categories( $parents_array, $taxonomy ) { foreach( $parents_array as $slug => $category_data ) { $current_category = term_exists( $slug, $taxonomy ); if ( ! is_array( $current_category ) ) { $parent_id = 0 !== $category_data['parent'] ? term_exists( $category_data['parent'], $taxonomy ) : 0; wp_insert_term( $category_data['name'], $taxonomy, array( 'slug' => $slug, 'description' => $category_data['description'], 'parent' => is_array( $parent_id ) ? $parent_id['term_id'] : $parent_id, ) ); } else if ( ( ! isset( $current_category['parent'] ) || 0 === $current_category['parent'] ) && 0 !== $category_data['parent'] ) { $parent_id = 0 !== $category_data['parent'] ? term_exists( $category_data['parent'], $taxonomy ) : 0; wp_update_term( $current_category['term_id'], $taxonomy, array( 'parent' => is_array( $parent_id ) ? $parent_id['term_id'] : $parent_id ) ); } } } /** * Generates UUIDs for the presets to avoid collisions. * * @since 4.5.0 * * @param array $global_presets - The Global Presets to be imported * * @return array - The list of module types for which preset ids have been changed */ public function prepare_to_import_layout_presets( &$global_presets ) { $preset_rewrite_map = array(); $initial_preset_id = ET_Builder_Global_Presets_Settings::MODULE_INITIAL_PRESET_ID; foreach ( $global_presets as $component_type => &$component_presets ) { $preset_rewrite_map[ $component_type ] = array(); foreach ( $component_presets['presets'] as $preset_id => $preset ) { $new_id = ET_Core_Data_Utils::uuid_v4(); $component_presets['presets'][ $new_id ] = $preset; $preset_rewrite_map[ $component_type ][ $preset_id ] = $new_id; unset( $component_presets['presets'][ $preset_id ] ); } if ( $component_presets['default'] === $initial_preset_id && ! isset( $preset_rewrite_map[ $component_type ][ $initial_preset_id ] ) ) { $new_id = ET_Core_Data_Utils::uuid_v4(); $component_presets['default'] = $new_id; if ( isset( $component_presets['presets'][ $initial_preset_id ] ) ) { $component_presets['presets'][ $new_id ] = $component_presets['presets'][ $initial_preset_id ]; unset( $component_presets['presets'][ $initial_preset_id ] ); } $preset_rewrite_map[ $component_type ][ $initial_preset_id ] = $new_id; } else { $component_presets['default'] = $preset_rewrite_map[ $component_type ][ $component_presets['default'] ]; } } return $preset_rewrite_map; } /** * Injects the given Global Presets settings into the imported layout * * @since 4.5.0 * * @param array $shortcode_object - The multidimensional array representing a page/module structure * @param array $global_presets - The Global Presets to be imported * @param array $preset_rewrite_map - The list of module types for which preset ids have been changed */ protected function rewrite_module_preset_ids( &$shortcode_object, $global_presets, $preset_rewrite_map ) { $global_presets_manager = ET_Builder_Global_Presets_Settings::instance(); $module_preset_attribute = ET_Builder_Global_Presets_Settings::MODULE_PRESET_ATTRIBUTE; foreach ( $shortcode_object as &$module ) { $module_type = $global_presets_manager->maybe_convert_module_type( $module['type'], $module['attrs'] ); $module_preset_id = et_()->array_get( $module, "attrs.{$module_preset_attribute}", 'default' ); if ( $module_preset_id === 'default' ) { $module['attrs'][ $module_preset_attribute ] = et_()->array_get( $global_presets, "{$module_type}.default", 'default' ); } else { if ( isset( $preset_rewrite_map[ $module_type ][ $module_preset_id ] ) ) { $module['attrs'][ $module_preset_attribute ] = $preset_rewrite_map[ $module_type ][ $module_preset_id ]; } else { $module['attrs'][ $module_preset_attribute ] = et_()->array_get( $global_presets, "{$module_type}.default", 'default' ); } } if ( isset( $module['content'] ) && is_array( $module['content'] ) ) { $this->rewrite_module_preset_ids( $module['content'], $global_presets, $preset_rewrite_map ); } } } /** * Injects global color ids into the imported layout * * @since 4.10.0 * * @param array $data - The multidimensional array representing a import object structure. */ protected function _maybe_inject_gcid( &$data, &$gcolors = null ) { foreach ( $data as $post_id => &$post_data ) { if ( is_array( $post_data ) ) { $shortcode_object = et_fb_process_shortcode( $post_data['post_content'] ); $this->_inject_gcid( $shortcode_object, $gcolors ); $data[ $post_id ]['post_content'] = et_fb_process_to_shortcode( $shortcode_object, array(), '', false ); } else { $shortcode_object = et_fb_process_shortcode( $post_data ); $this->_inject_gcid( $shortcode_object, $gcolors ); $data[ $post_id ] = et_fb_process_to_shortcode( $shortcode_object, array(), '', false ); } } unset( $post_data ); return $data; } /** * Process and inject global color ids into the shortcode * * @since 4.10.0 * * @param array $shortcode_object - The multidimensional array representing a page/module structure. */ protected function _inject_gcid( &$shortcode_object, &$global_colors ) { foreach ( $shortcode_object as &$module ) { // No global colors set for this module. if ( ! empty( $module['attrs']['global_colors_info'] ) && ! empty( $global_colors ) ) { $colors_array = json_decode( $module['attrs']['global_colors_info'], true ); if ( ! empty( $colors_array ) ) { foreach ( $colors_array as $color_id => $attrs_array ) { if ( ! empty( $attrs_array ) ) { // Get settings for this global color. $color = ''; foreach ( $global_colors as $gcid ) { if ( $color_id === $gcid[0] && 'yes' === $gcid[1]['active'] ) { $color = $gcid[1]['color']; } } foreach ( $attrs_array as $attr_name ) { if ( isset( $module['attrs'][ $attr_name ] ) && '' !== $module['attrs'][ $attr_name ] ) { // Match substring (needed for attrs like gradient stops). $module['attrs'][ $attr_name ] = str_replace( $color, $color_id, $module['attrs'][ $attr_name ] ); } } } } } } if ( isset( $module['content'] ) && is_array( $module['content'] ) ) { $this->_inject_gcid( $module['content'], $global_colors ); } } } /** * Injects the given Global Presets settings into the imported layout * * @since 3.26 * * @param array $shortcode_object - The multidimensional array representing a page/module structure * @param array $global_presets - The Global Presets to be applied */ protected function _apply_global_presets( &$shortcode_object, $global_presets ) { $global_presets_manager = ET_Builder_Global_Presets_Settings::instance(); $module_preset_attribute = ET_Builder_Global_Presets_Settings::MODULE_PRESET_ATTRIBUTE; foreach ( $shortcode_object as &$module ) { $module_type = $global_presets_manager->maybe_convert_module_type( $module['type'], $module['attrs'] ); if ( isset( $global_presets[ $module_type ] ) ) { $default_preset_id = et_()->array_get( $global_presets, "{$module_type}.default", null ); $module_preset_id = et_()->array_get( $module, "attrs.{$module_preset_attribute}", $default_preset_id ); if ( 'default' === $module_preset_id ) { $module_preset_id = $default_preset_id; } $preset_settings = array(); if ( isset( $global_presets[ $module_type ]['presets'][ $module_preset_id ] ) ) { $preset_settings = $global_presets[ $module_type ]['presets'][ $module_preset_id ]['settings']; } else { if ( isset( $global_presets[ $module_type ]['presets'][ $default_preset_id ]['settings'] ) ) { $preset_settings = $global_presets[ $module_type ]['presets'][ $default_preset_id ]['settings']; } } $merged_global_colors_info = array(); if ( isset( $module['attrs']['global_colors_info'] ) ) { // Retrive global_colors_info from post meta, which saved as string[][]. $gc_info_prepared = str_replace( array( '[', ']' ), array( '[', ']' ), $module['attrs']['global_colors_info'] ); $used_global_colors = json_decode( $gc_info_prepared, true ); $merged_global_colors_info = $used_global_colors; } // Merge Global Colors from preset. if ( isset( $preset_settings['global_colors_info'] ) ) { $preset_global_colors = json_decode( $preset_settings['global_colors_info'], true ); if ( ! empty( $preset_global_colors ) ) { foreach ( $preset_global_colors as $color_id => $settings_list ) { if ( ! empty( $settings_list ) ) { if ( isset( $used_global_colors[ $color_id ] ) ) { $merged_global_colors_info[ $color_id ] = array_merge( $used_global_colors[ $color_id ], $settings_list ); } else { $merged_global_colors_info[ $color_id ] = $settings_list; } foreach ( $settings_list as $setting_name ) { $preset_settings[ $setting_name ] = $color_id; } } } } } $module['attrs'] = array_merge( $preset_settings, $module['attrs'] ); $module['attrs']['global_colors_info'] = wp_json_encode( $merged_global_colors_info ); } if ( isset( $module['content'] ) && is_array( $module['content'] ) ) { $this->_apply_global_presets( $module['content'], $global_presets ); } } } /** * Restrict data according the argument registered. * * @since 2.7.0 * * @param array $data Array of data the query is applied on. * @param string $method Whether data should be set or reset. Accepts 'set' or 'unset' which is * should be used when treating existing data in the db. * * @return array */ protected function apply_query( $data, $method ) { $operator = ( $method === 'set' ) ? true : false; foreach ( $data as $id => $value ) { if ( ! empty( $this->instance->exclude ) && isset( $this->instance->exclude[$id] ) === $operator ) { unset( $data[$id] ); } if ( ! empty( $this->instance->include ) && isset( $this->instance->include[$id] ) === ! $operator ) { unset( $data[$id] ); } } return $data; } /** * Serialize images in chunks. * * @since 4.0 * * @param array $images * @param string $method Method applied on images. * @param string $id Unique ID to use for temporary files. * @param integer $chunk * * @return array */ protected function chunk_images( $images, $method, $id, $chunk = 0 ) { $images_per_chunk = 5; $chunks = 1; /** * Filters whether or not images in the file being imported should be paginated. * * @since 3.0.99 * * @param bool $paginate_images Default `true`. */ $paginate_images = apply_filters( 'et_core_portability_paginate_images', true ); if ( $paginate_images && count( $images ) > $images_per_chunk ) { $chunks = ceil( count( $images ) / $images_per_chunk ); $slice = $images_per_chunk * $chunk; $images = array_slice( $images, $slice, $images_per_chunk ); $images = $this->$method( $images ); $filesystem = $this->get_filesystem(); $temp_file_id = sanitize_file_name( "images_{$id}" ); $temp_file = $this->temp_file( $temp_file_id, 'et_core_export' ); $temp_images = json_decode( $filesystem->get_contents( $temp_file ), true ); if ( is_array( $temp_images ) ) { $images = array_merge( $temp_images, $images ); } if ( $chunk + 1 < $chunks ) { $filesystem->put_contents( $temp_file, wp_json_encode( (array) $images ) ); } else { $this->delete_temp_files( 'et_core_export', array( $temp_file_id => $temp_file ) ); } } else { $images = $this->$method( $images ); } return array( 'ready' => $chunk + 1 >= $chunks, 'chunks' => $chunks, 'images' => $images, ); } /** * Paginate images processing. * * @since 1.0.0 * * @param $images * @param string $method Method applied on images. * @param int $timestamp Timestamp used to store data upon pagination. * * @return array * @internal param array $data Array of images. */ protected function maybe_paginate_images( $images, $method, $timestamp ) { et_core_nonce_verified_previously(); $page = isset( $_POST['page'] ) ? (int) $_POST['page'] : 1; $result = $this->chunk_images( $images, $method, $timestamp, max( $page - 1, 0 ) ); if ( ! $result['ready'] ) { wp_send_json( array( 'page' => $page, 'total_pages' => $result['chunks'], 'timestamp' => $timestamp, ) ); } return $result['images']; } /** * Get all thumbnail images in the data given. * * @since 4.7.4 * * @param array $data Array of data. * * @return array */ protected function _get_thumbnail_images( $data ) { $thumbnails = array(); foreach ( $data as $post_data ) { // If post has thumbnail. if ( ! empty( $post_data->post_meta ) && ! empty( $post_data->post_meta->_thumbnail_id ) ) { $post_thumbnail = get_the_post_thumbnail_url( $post_data->ID ); // If thumbnail image found in the WP Media library. if ( $post_thumbnail ) { $thumbnail_id = (int) $post_data->post_meta->_thumbnail_id[0]; $thumbnail_image = $this->encode_images( array( $thumbnail_id ) ); $thumbnails[ $thumbnail_id ] = $thumbnail_image; } } } return $thumbnails; } /** * Get all images in the data given. * * @since 2.7.0 * * @param array $data Array of data. * @param bool $force Set whether the value should be added by force. Usually used for image ids. * * @return array */ protected function get_data_images( $data, $force = false ) { if ( empty( $data ) ) { return array(); } $images = array(); $images_src = array(); $basenames = array( 'src', 'image_url', 'background_image', 'image', 'url', 'bg_img_?\d?', ); $suffixes = array( '__hover', '_tablet', '_phone' ); foreach ( $basenames as $basename ) { $images_src[] = $basename; foreach ( $suffixes as $suffix ) { $images_src[] = $basename . $suffix; } } foreach ( $data as $value ) { // If the $value is an object and there is no post_content property, // it's unlikely to contain any image data so we can continue with the next iteration. if ( is_object( $value ) && ! property_exists( $value, 'post_content' ) ) { continue; } if ( is_array( $value ) || is_object( $value ) ) { // If the $value contains the post_content property, set $value to use // this object's property value instead of the entire object. if ( is_object( $value ) && property_exists( $value, 'post_content' ) ) { $value = $value->post_content; } $images = array_merge( $images, $this->get_data_images( (array) $value ) ); continue; } // Extract images from HTML or shortcodes. if ( preg_match_all( '/(' . implode( '|', $images_src ) . ')="(?P<src>\w+[^"]*)"/i', $value, $matches ) ) { foreach ( array_unique( $matches['src'] ) as $key => $src ) { $images = array_merge( $images, $this->get_data_images( array( $key => $src ) ) ); } } // Extract images from shortcodes gallery. if ( preg_match_all( '/gallery_ids="(?P<ids>\w+[^"]*)"/i', $value, $matches ) ) { foreach ( array_unique( $matches['ids'] ) as $galleries ) { $explode = explode( ',', str_replace( ' ', '', $galleries ) ); foreach ( $explode as $image_id ) { $images = array_merge( $images, $this->get_data_images( array( (int) $image_id ), true ) ); } } } if ( preg_match( '/^.+?\.(jpg|jpeg|jpe|png|gif|svg|webp)/', $value, $match ) || $force ) { $basename = basename( $value ); // Skip if the value is not a valid URL or an image ID (integer). if ( ! ( wp_http_validate_url( $value ) || is_int( $value ) ) ) { continue; } // Skip if the images array already contains the value to avoid duplicates. if ( isset( $images[$value] ) ) { continue; } $images[$value] = $value; } } return $images; } /** * Get the attachment post id for the given url. * * @since 3.22.3 * * @param string $url The url of an attachment file. * * @return int */ protected function _get_attachment_id_by_url( $url ) { global $wpdb; // Remove any thumbnail size suffix from the filename and use that as a fallback. $fallback_url = preg_replace( '/-\d+x\d+(\.[^.]+)$/i', '$1', $url ); // Scenario: Trying to find the attachment for a file called x-150x150.jpg. // 1. Since WordPress adds the -150x150 suffix for thumbnail sizes we cannot be // sure if this is an attachment or an attachment's generated thumbnail. // 2. Since both x.jpg and x-150x150.jpg can be uploaded as separate attachments // we must decide which is a better match. // 3. The above is why we order by guid length and use the first result. $attachments_query = $wpdb->prepare( " SELECT id FROM $wpdb->posts WHERE `post_type` = %s AND `guid` IN ( %s, %s ) ORDER BY CHAR_LENGTH( `guid` ) DESC ", 'attachment', esc_url_raw( $url ), esc_url_raw( $fallback_url ) ); $attachment_id = (int) $wpdb->get_var( $attachments_query ); return $attachment_id; } /** * Encode image in a base64 format. * * @since 2.7.0 * * @param array $images Array of data for which images need to be encoded if any. * * @return array */ protected function encode_images( $images ) { $encoded = array(); foreach ( $images as $url ) { $id = 0; $image = ''; if ( is_int( $url ) ) { $id = $url; $url = wp_get_attachment_url( $id ); } else { $id = $this->_get_attachment_id_by_url( $url ); } if ( $id > 0 ) { $image = $this->_encode_attachment_image( $id ); } if ( empty( $image ) ) { // Case 1: No attachment found. // Case 2: Attachment found, but file does not exist (may be stored on a CDN, for example). $image = $this->_encode_remote_image( $url ); } if ( empty( $image ) ) { // All fetching methods have failed - bail on encoding. continue; } $encoded[ $url ] = array( 'encoded' => $image, 'url' => $url, ); // Add image id for replacement purposes. if ( $id > 0 ) { $encoded[ $url ]['id'] = $id; } } return $encoded; } /** * Encode an image attachment. * * @since 3.22.3 * * @param int $id * * @return string */ protected function _encode_attachment_image( $id ) { /** * @var WP_Filesystem_Base $wp_filesystem */ global $wp_filesystem; if ( ! current_user_can( 'read_post', $id ) ) { return ''; } $file = get_attached_file( $id ); if ( ! $wp_filesystem->exists( $file ) ) { return ''; } $image = $wp_filesystem->get_contents( $file ); if ( empty( $image ) ) { return ''; } return base64_encode( $image ); } /** * Encode a remote image. * * @since 3.22.3 * * @param string $url * * @return string */ protected function _encode_remote_image( $url ) { $request = wp_remote_get( esc_url_raw( $url ), array( 'timeout' => 2, 'redirection' => 2, ) ); if ( ! is_array( $request ) || is_wp_error( $request ) ) { return ''; } if ( ! self::$_->includes( $request['headers']['content-type'], 'image' ) ) { return ''; } $image = wp_remote_retrieve_body( $request ); if ( ! $image ) { return ''; } return base64_encode( $image ); } /** * Decode base64 formatted image and upload it to WP media. * * @since 2.7.0 * * @param array $images Array of encoded images which needs to be uploaded. * * @return array */ protected function upload_images( $images ) { $filesystem = $this->set_filesystem(); /** * Filters whether or not to allow duplicate images to be uploaded * during Portability import. * * @since 4.14.8 * * @param bool $allow_duplicates Whether or not to allow duplicates. Default is `false`. */ $allow_duplicates = apply_filters( 'et_core_portability_import_attachment_allow_duplicates', false ); foreach ( $images as $key => $image ) { $basename = sanitize_file_name( wp_basename( $image['url'] ) ); $id = 0; $url = ''; if ( ! $allow_duplicates ) { $attachments = get_posts( array( 'posts_per_page' => -1, 'post_type' => 'attachment', 'meta_key' => '_wp_attached_file', 'meta_value' => pathinfo( $basename, PATHINFO_FILENAME ), 'meta_compare' => 'LIKE', ) ); // Avoid duplicates. if ( ! is_wp_error( $attachments ) && ! empty( $attachments ) ) { foreach ( $attachments as $attachment ) { $attachment_url = wp_get_attachment_url( $attachment->ID ); $file = get_attached_file( $attachment->ID ); $filename = sanitize_file_name( wp_basename( $file ) ); // Use existing image only if the content matches. if ( $filesystem->get_contents( $file ) === base64_decode( $image['encoded'] ) ) { $id = isset( $image['id'] ) ? $attachment->ID : 0; $url = $attachment_url; break; } } } } // Create new image. if ( empty( $url ) ) { $temp_file = wp_tempnam(); $filesystem->put_contents( $temp_file, base64_decode( $image['encoded'] ) ); $filetype = wp_check_filetype_and_ext( $temp_file, $basename ); if ( ! $allow_duplicates && ! empty( $attachments ) && ! is_wp_error( $attachments ) ) { // Avoid further duplicates if the proper_filename matches an existing image. if ( isset( $filetype['proper_filename'] ) && $filetype['proper_filename'] !== $basename ) { foreach ( $attachments as $attachment ) { $attachment_url = wp_get_attachment_url( $attachment->ID ); $file = get_attached_file( $attachment->ID ); $filename = sanitize_file_name( wp_basename( $file ) ); if ( isset( $filename ) && $filename === $filetype['proper_filename'] ) { // Use existing image only if the basenames and content match. if ( $filesystem->get_contents( $file ) === $filesystem->get_contents( $temp_file ) ) { $id = isset( $image['id'] ) ? $attachment->ID : 0; $url = $attachment_url; $filesystem->delete( $temp_file ); break; } } } } } $file = array( 'name' => $basename, 'tmp_name' => $temp_file, ); $upload = media_handle_sideload( $file ); $attachment_id = is_wp_error( $upload ) ? 0 : $upload; /** * Fires when image attachments are created during portability import. * * @since 4.14.6 * * @param int $attachment_id The attachment id or 0 if attachment upload failed. */ do_action( 'et_core_portability_import_attachment_created', $attachment_id ); if ( ! is_wp_error( $upload ) ) { // Set the replacement as an id if the original image was set as an id (for gallery). $id = isset( $image['id'] ) ? $upload : 0; $url = wp_get_attachment_url( $upload ); } else { // Make sure the temporary file is removed if media_handle_sideload didn't take care of it. $filesystem->delete( $temp_file ); } } // Only declare the replace if a url is set. if ( $id > 0 ) { $images[$key]['replacement_id'] = $id; } if ( ! empty( $url ) ) { $images[$key]['replacement_url'] = $url; } unset( $url ); } return $images; } /** * Replace encoded image url with a real url * * @param $subject - The string to perform replacing for * @param array $image - The image settings * * @return string|string[]|null */ protected function replace_image_url( $subject, $image ) { if ( isset( $image['replacement_id'] ) && isset( $image['id'] ) ) { $search = $image['id']; $replacement = $image['replacement_id']; $subject = preg_replace( "/(gallery_ids=.*?){$search}(.*?)/", "\${1}{$replacement}\${2}", $subject ); } if ( isset( $image['url'] ) && isset( $image['replacement_url'] ) && $image['url'] !== $image['replacement_url'] ) { $search = $image['url']; $replacement = $image['replacement_url']; $subject = str_replace( $search, $replacement, $subject ); } return $subject; } /** * Replace image urls with newly uploaded images. * * @since 2.7.0 * * @param array $images Array of new images uploaded. * @param array $data Array of for which images url needs to be replaced. * * @return array|mixed|object */ protected function replace_images_urls( $images, $data ) { foreach ( $data as $post_id => &$post_data ) { foreach ( $images as $image ) { if ( is_array( $post_data ) ) { foreach ( $post_data as $post_param => &$param_value ) { if ( ! is_array( $param_value ) ) { $data[ $post_id ][ $post_param ] = $this->replace_image_url( $param_value, $image ); } } unset($param_value); } else { $data[ $post_id ] = $this->replace_image_url( $post_data, $image ); } } } unset($post_data); return $data; } /** * Validate data and remove any malicious code. * * @since 2.7.0 * * @param array $data Array of data which needs to be validated. * @param array $fields_validation Array of field and validation callback. * * @return array|bool */ protected function validate( $data, $fields_validation = array() ) { if ( ! is_array( $data ) ) { return false; } foreach ( $data as $key => $value ) { if ( empty( $value ) ) { continue; } if ( is_array( $value ) ) { $data[$key] = $this->validate( $value, $fields_validation ); } else { if ( isset( $fields_validation[$key] ) ) { // @phpcs:ignore Generic.PHP.ForbiddenFunctions.Found $data[$key] = call_user_func( $fields_validation[$key], $value ); } else { if ( current_user_can( 'unfiltered_html' ) ) { $data[ $key ] = $value; } else { $data[ $key ] = wp_kses_post( $value ); } } } } return $data; } /** * Filters a variable with string filter * * @param mixed $data - Value to filter. * * @return mixed */ protected function _filter_post_data( $data ) { return filter_var( $data, FILTER_SANITIZE_STRING, FILTER_FLAG_NO_ENCODE_QUOTES ); } /** * Prevent import and export timeout or memory failure. * * @since 2.7.0 * * It doesn't need to be reset as in both case the request exit. */ protected function prevent_failure() { @set_time_limit( 0 ); // Increase memory which is safe at this stage of the request. if ( et_core_get_memory_limit() < 256 ) { @ini_set( 'memory_limit', '256M' ); } } /** * Set WP filesystem to direct. This should only be use to create a temporary file. * * @since 2.7.0 * * It is safe to do so since the created file is removed immediately after import. The method does'nt have * to be reset since the ajax query is exited. */ protected function set_filesystem() { global $wp_filesystem; add_filter( 'filesystem_method', array( $this, 'replace_filesystem_method' ) ); WP_Filesystem(); return $wp_filesystem; } /** * Proxy method for set_filesystem() to avoid calling it multiple times. * * @since 4.0 * * @return WP_Filesystem_Direct */ protected function get_filesystem() { static $filesystem = null; if ( null === $filesystem ) { $filesystem = $this->set_filesystem(); } return $filesystem; } /** * Check if a temporary file is register. Returns temporary file if it exists. * * @since 4.0 Made method public. * * @param string $id Unique id used when the temporary file was created. * @param string $group Group name in which files are grouped. * * @return bool|string */ public function has_temp_file( $id, $group ) { $temp_files = get_option( '_et_core_portability_temp_files', array() ); if ( isset( $temp_files[$group][$id] ) && file_exists( $temp_files[$group][$id] ) ) { return $temp_files[$group][$id]; } return false; } /** * Create a temp file and register it. * * @since 2.7.0 * @since 4.0 Made method public. Added $content parameter. * * @param string $id Unique id reference for the temporary file. * @param string $group Group name in which files are grouped. * @param string|bool $temp_file Path to the temporary file. False create a new temporary file. * * @return bool|string */ public function temp_file( $id, $group, $temp_file = false, $content = '' ) { $temp_files = get_option( '_et_core_portability_temp_files', array() ); if ( ! isset( $temp_files[$group] ) ) { $temp_files[$group] = array(); } if ( isset( $temp_files[$group][$id] ) && file_exists( $temp_files[$group][$id] ) ) { return $temp_files[$group][$id]; } $temp_file = $temp_file ? $temp_file : wp_tempnam(); $temp_files[$group][$id] = $temp_file; update_option( '_et_core_portability_temp_files', $temp_files, false ); if ( ! empty( $content ) ) { $this->get_filesystem()->put_contents( $temp_file, $content ); } return $temp_file; } /** * Get temp file contents or an empty string if it does not exist. * * @since 4.0 * * @param string $id Unique id used when the temporary file was created. * @param string $group Group name in which files are grouped. * * @return string */ public function get_temp_file_contents( $id, $group ) { $file = $this->has_temp_file( $id, $group ); if ( ! $file ) { return ''; } $content = $this->get_filesystem()->get_contents( $file ); return $content ? $content : ''; } /** * Delete all the temp files. * * @since 2.7.0 * * @param bool|string $group Group name in which files are grouped. Set to true to remove all groups and files. * @param array $defined_files Array or temoporary files to delete. No argument deletes all temp files. */ public function delete_temp_files( $group = false, $defined_files = false ) { $filesystem = $this->set_filesystem(); $temp_files = get_option( '_et_core_portability_temp_files', array() ); // Remove all temp files accross all groups if group is true. if ( $group === true ) { foreach( $temp_files as $group_id => $_group ) { $this->delete_temp_files( $group_id ); } } if ( ! isset( $temp_files[$group] ) ) { return; } $delete_files = ( is_array( $defined_files ) && ! empty( $defined_files ) ) ? $defined_files : $temp_files[$group]; foreach ( $delete_files as $id => $temp_file ) { if ( isset( $temp_files[$group][$id] ) && $filesystem->delete( $temp_files[$group][$id] ) ) { unset( $temp_files[$group][$id] ); } } if ( empty( $temp_files[$group] ) ) { unset( $temp_files[$group] ); } if ( empty( $temp_files ) ) { delete_option( '_et_core_portability_temp_files' ); } else { update_option( '_et_core_portability_temp_files', $temp_files, false ); } } /** * Set WP filesystem method to direct. * * @since 2.7.0 */ public function replace_filesystem_method() { return 'direct'; } /** * Get timestamp or create one if it isn't set. * * @since 2.7.0 */ public function get_timestamp() { et_core_nonce_verified_previously(); if ( isset( $_POST['timestamp'] ) && ! empty( $_POST['timestamp'] ) ) { return sanitize_text_field( $_POST['timestamp'] ); } return function_exists( 'hrtime' ) ? (string) hrtime( true ) : (string) microtime( true ); // phpcs:ignore PHPCompatibility.FunctionUse.NewFunctions.hrtimeFound -- Intentional use of new PHP function } /** * Get Global Colors array from provided global_colors_info. * * @since 4.10.8 * * @param array $global_colors_info Array of global colors to process. * * @return array The list of the Global Colors for export. */ protected function _get_global_colors_data( $global_colors_info = array() ) { $global_color_ids = array_unique( array_keys( $global_colors_info ) ); if ( empty( $global_color_ids ) ) { return array(); } $all_global_colors = et_builder_get_all_global_colors(); $used_colors = array(); foreach ( $global_color_ids as $color_id ) { if ( isset( $all_global_colors[ $color_id ] ) ) { $color_data = array( $color_id, $all_global_colors[ $color_id ], ); $used_colors[] = $color_data; } } return $used_colors; } /** * Get List of global colors used in shortcode. * * @since 4.10.8 * * @param array $shortcode_object The multidimensional array representing a page structure. * @param array $used_global_colors List of global colors to merge with. * @param array $presets Object of presets. * * @return array - The list of the Global Colors. */ protected function _get_used_global_colors( $shortcode_object, $used_global_colors = array(), $presets = array() ) { foreach ( $shortcode_object as $module ) { if ( isset( $module['attrs']['global_colors_info'] ) ) { // Retrive global_colors_info from post meta, which saved as string[][]. $gc_info_prepared = str_replace( array( '[', ']' ), array( '[', ']' ), $module['attrs']['global_colors_info'] ); // Make sure we pass array to array_merge to avoid Fatal Error. $gc_info_array = json_decode( $gc_info_prepared, true ); $gc_info_array = is_array( $gc_info_array ) ? $gc_info_array : []; $used_global_colors = array_merge( $used_global_colors, $gc_info_array ); } if ( isset( $module['content'] ) && is_array( $module['content'] ) ) { $used_global_colors = array_merge( $used_global_colors, $this->_get_used_global_colors( $module['content'], $used_global_colors, $presets ) ); } } if ( ! empty( $presets ) ) { foreach ( $presets as $module_type => $module_presets ) { foreach ( $module_presets->presets as $preset_id => $preset ) { if ( isset( $preset->settings->global_colors_info ) ) { $used_global_colors = array_merge( $used_global_colors, json_decode( $preset->settings->global_colors_info, true ) ); } } } } return $used_global_colors; } /** * Returns Global Presets used for a given shortcode only * * @since 3.26 * * @param array $shortcode_object - The multidimensional array representing a page structure * @param array $used_global_presets * * @return array - The list of the Global Presets * */ protected function get_used_global_presets( $shortcode_object, $used_global_presets = array() ) { $global_presets_manager = ET_Builder_Global_Presets_Settings::instance(); foreach ( $shortcode_object as $module ) { $module_type = $global_presets_manager->maybe_convert_module_type( $module['type'], $module['attrs'] ); $preset_id = $global_presets_manager->get_module_preset_id( $module_type, $module['attrs'] ); $preset = $global_presets_manager->get_module_preset( $module_type, $preset_id ); if ( $preset_id !== 'default' && count( (array) $preset ) !== 0 && count( (array) $preset->settings ) !== 0 ) { if ( ! isset( $used_global_presets[ $module_type ] ) ) { $used_global_presets[ $module_type ] = (object) array( 'presets' => (object) array(), ); } if ( ! isset( $used_global_presets[ $module_type ]->presets->$preset_id ) ) { $used_global_presets[ $module_type ]->presets->$preset_id = (object) array( 'name' => $preset->name, 'version' => $preset->version, 'settings' => $preset->settings, ); } if ( ! isset( $used_global_presets[ $module_type ]->default ) ) { $used_global_presets[ $module_type ]->default = $global_presets_manager->get_module_default_preset_id( $module_type ); } } if ( isset( $module['content'] ) && is_array( $module['content'] ) ) { $used_global_presets = array_merge( $used_global_presets, $this->get_used_global_presets( $module['content'], $used_global_presets ) ); } } return $used_global_presets; } /** * Returns Global Colors used for a given theme builder shortcode. * * @since 4.18.0 * * @param array $shortcode_object - The multidimensional array representing a page structure. * * @return array The list of the Global Colors */ public function get_theme_builder_library_used_global_colors( $shortcode_object ) { return $this->_get_used_global_colors( $shortcode_object ); } /** * Returns Global Presets used for a given theme builder shortcode. * * @since 4.18.0 * * @param array $shortcode_object - The multidimensional array representing a page structure. * * @return array The list of the Global Presets */ public function get_theme_builder_library_used_global_presets( $shortcode_object ) { return $this->get_used_global_presets( $shortcode_object ); } /** * Returns images used for a given theme builder shortcode. * * @since 4.18.0 * * @param array $data - ID and Post content. * * @return array The list of the encoded images */ public function get_theme_builder_library_images( $data ) { $timestamp = $this->get_timestamp(); $images = $this->get_data_images( $data ); return $this->maybe_paginate_images( $images, 'encode_images', $timestamp ); } /** * Returns thumbnails used for a given theme builder shortcode. * * @since 4.18.0 * * @param array $data - ID and Post content. * * @return array The list of the thumbnails */ public function get_theme_builder_library_thumbnail_images( $data ) { return $this->_get_thumbnail_images( $data ); } /** * Enqueue assets. * * @since ?.? Script `et-core-portability` now loads in footer along with `et-core-admin`. * @since 2.7.0 */ public function assets() { $time = '<span>1</span>'; wp_enqueue_style( 'et-core-portability', ET_CORE_URL . 'admin/css/portability.css', array( 'et-core-admin', ), ET_CORE_VERSION ); wp_enqueue_script( 'et-core-portability', ET_CORE_URL . 'admin/js/portability.js', array( 'jquery', 'jquery-ui-tabs', 'jquery-form', 'et-core-admin', ), ET_CORE_VERSION, true ); wp_localize_script( 'et-core-portability', 'etCorePortability', array( 'nonces' => array( 'import' => wp_create_nonce( 'et_core_portability_import' ), 'export' => wp_create_nonce( 'et_core_portability_export' ), 'cancel' => wp_create_nonce( 'et_core_portability_cancel' ), 'presets' => wp_create_nonce( 'et_core_portability_import_default_presets' ), ), 'postMaxSize' => $this->to_megabytes( @ini_get( 'post_max_size' ) ), 'uploadMaxSize' => $this->to_megabytes( @ini_get( 'upload_max_filesize' ) ), 'text' => array( // phpcs:disable WordPress.WP.I18n.NonSingularStringLiteralDomain -- Following the standard. 'browserSupport' => esc_html__( 'The browser version you are currently using is outdated. Please update to the newest version.', ET_CORE_TEXTDOMAIN ), 'memoryExhausted' => esc_html__( 'You reached your server memory limit. Please try increasing your PHP memory limit.', ET_CORE_TEXTDOMAIN ), 'maxSizeExceeded' => esc_html__( 'This file cannot be imported. It may be caused by file_uploads being disabled in your php.ini. It may also be caused by post_max_size or/and upload_max_filesize being smaller than file selected. Please increase it or transfer more substantial data at the time.', ET_CORE_TEXTDOMAIN ), 'invalideFile' => esc_html__( 'Invalid File format. You should be uploading a JSON file.', ET_CORE_TEXTDOMAIN ), 'importContextFail' => esc_html__( 'This file should not be imported in this context.', ET_CORE_TEXTDOMAIN ), 'noItemsSelected' => esc_html__( 'Please select at least one item to export or disable the "Only export selected items" option', ET_CORE_TEXTDOMAIN ), 'noItemsToExport' => esc_html__( 'There are no items to export.', ET_CORE_TEXTDOMAIN ), 'importing' => sprintf( esc_html__( 'Import estimated time remaining: %smin', ET_CORE_TEXTDOMAIN ), $time ), 'exporting' => sprintf( esc_html__( 'Export estimated time remaining: %smin', ET_CORE_TEXTDOMAIN ), $time ), 'backuping' => sprintf( esc_html__( 'Backup estimated time remaining: %smin', ET_CORE_TEXTDOMAIN ), $time ), // phpcs:enable ), ) ); } /** * Modal HTML. * * @since 2.7.0 */ public function modal() { $export_url = add_query_arg( array( 'et_core_portability' => true, 'context' => $this->instance->context, 'name' => $this->instance->name, 'nonce' => wp_create_nonce( 'et_core_portability_export' ), ), admin_url() ); $is_etdev_plugin_activated = is_plugin_active( 'etdev/etdev.php' ); // phpcs:disable WordPress.WP.I18n.NonSingularStringLiteralDomain -- Existing codebase. ?> <div class="et-core-modal-overlay et-core-form" data-et-core-portability="<?php echo esc_attr( $this->instance->context ); ?>"> <div class="et-core-modal"> <div class="et-core-modal-header"> <h3 class="et-core-modal-title"><?php echo esc_html( $this->instance->title ); ?></h3><a href="#" class="et-core-modal-close" data-et-core-modal="close"></a> </div> <div data-et-core-tabs class="et-core-modal-tabs-enabled"> <ul class="et-core-tabs"> <li><a href="#et-core-portability-export"><?php esc_html_e( 'Export', ET_CORE_TEXTDOMAIN ); ?></a></li> <li><a href="#et-core-portability-import"><?php esc_html_e( 'Import', ET_CORE_TEXTDOMAIN ); ?></a></li> </ul> <div id="et-core-portability-export"> <div class="et-core-modal-content"> <?php printf( esc_html__( 'Exporting your %s will create a JSON file that can be imported into a different website.', ET_CORE_TEXTDOMAIN ), esc_html( $this->instance->name ) ); ?> <h3><?php esc_html_e( 'Export File Name', ET_CORE_TEXTDOMAIN ); ?></h3> <form class="et-core-portability-export-form"> <input type="text" name="" value="<?php echo esc_attr( $this->instance->name ); ?>"> <?php if ( 'post_type' === $this->instance->type ) : ?> <div class="et-core-clearfix"></div> <label><input type="checkbox" name="et-core-portability-posts" <?php echo $is_etdev_plugin_activated ? 'checked' : ''; ?> /><?php esc_html_e( 'Only export selected items', ET_CORE_TEXTDOMAIN ); ?></label> <?php endif; ?> <?php if ( $is_etdev_plugin_activated ) : ?> <div class="et-core-clearfix"></div> <label><input type="checkbox" name="et-core-portability-apply-presets" checked /><?php esc_html_e( 'Export Presets As Static Styles', ET_CORE_TEXTDOMAIN ); ?></label> <?php endif; ?> </form> </div> <div class="et-core-action-buttons-container"> <a class="et-core-modal-action et-core-button-primary" href="#" data-et-core-portability-export="<?php echo esc_url( $export_url ); ?>"><?php esc_html_e( 'Download Export', ET_CORE_TEXTDOMAIN ); ?></a> <?php if ( 'et_builder_layouts' === $this->instance->context ) { ?> <a class="et-core-modal-action et-core-button-secondary" href="#" data-et-core-portability-export-to-cloud="1"><?php esc_html_e( 'Export To Divi Cloud', 'et-core' ); ?></a> <?php } ?> </div> <div class="et-core-action-buttons-container__during_action"> <a class="et-core-modal-action et-core-button-danger" href="#" data-et-core-portability-cancel><?php esc_html_e( 'Cancel Export', ET_CORE_TEXTDOMAIN ); ?></a> </div> </div> <div id="et-core-portability-import"> <div class="et-core-modal-content"> <?php if ( 'post' === $this->instance->type ) : ?> <?php printf( esc_html__( 'Importing a previously-exported %s file will overwrite all content currently on this page.', ET_CORE_TEXTDOMAIN ), esc_html( $this->instance->name ) ); ?> <?php elseif ( 'post_type' === $this->instance->type ) : ?> <?php printf( esc_html__( 'Select a previously-exported Divi Builder Layouts file to begin importing items. Large collections of image-heavy exports may take several minutes to upload.', ET_CORE_TEXTDOMAIN ), esc_html( $this->instance->name ) ); ?> <?php else : ?> <?php printf( esc_html__( 'Importing a previously-exported %s file will overwrite all current data. Please proceed with caution!', ET_CORE_TEXTDOMAIN ), esc_html( $this->instance->name ) ); ?> <?php endif; ?> <h3><?php esc_html_e( 'Select File To Import', ET_CORE_TEXTDOMAIN ); ?></h3> <form class="et-core-portability-import-form"> <span class="et-core-portability-import-placeholder"><?php esc_html_e( 'No File Selected', ET_CORE_TEXTDOMAIN ); ?></span> <button class="et-core-button"><?php esc_html_e( 'Choose File', ET_CORE_TEXTDOMAIN ); ?></button> <input type="file"> <div class="et-core-clearfix"></div> <?php if ( 'post_type' !== $this->instance->type ) : ?> <label><input type="checkbox" name="et-core-portability-import-backup" /><?php esc_html_e( 'Download Backup Before Importing', ET_CORE_TEXTDOMAIN ); // phpcs:ignore WordPress.WP.I18n.NonSingularStringLiteralDomain -- intentional use of ET_CORE_TEXTDOMAIN ?></label> <?php endif; ?> <?php if ( 'post_type' === $this->instance->type ) : ?> <label><input type="checkbox" name="et-core-portability-import-include-global-presets" /><?php esc_html_e( 'Import Presets', ET_CORE_TEXTDOMAIN ); ?></label> <?php endif; ?> </form> </div> <a class="et-core-modal-action et-core-portability-import" href="#"><?php printf( esc_html__( 'Import %s', ET_CORE_TEXTDOMAIN ), esc_html( $this->instance->name ) ); ?></a> <a class="et-core-modal-action et-core-button-danger" href="#" data-et-core-portability-cancel><?php esc_html_e( 'Cancel Import', ET_CORE_TEXTDOMAIN ); ?></a> </div> </div> </div> </div> <?php // phpcs:enable } } if ( ! function_exists( 'et_core_portability_register' ) ) : /** * Register portability. * * This function should be called in an 'admin_init' action callback. * * @since 2.7.0 * * @param string $context A unique ID used to register the portability arguments. * * @param array $args { * Array of arguments used to register the portability. * * @type string $name The name used in the various text string. * @type bool $view Whether the assets and content should load or not. * Example: `isset( $_GET['page'] ) && $_GET['page'] == 'example'`. * @type string $db The option_name from the wp_option table used to export and import data. * @type array $include Optional. Array of all the options scritcly included. Options ids must be set * as the array keys. * @type array $exclude Optional. Array of excluded options. Options ids must be set as the array keys. * } */ function et_core_portability_register( $context, $args ) { $defaults = array( 'context' => $context, 'title' => esc_html__( 'Portability', ET_CORE_TEXTDOMAIN ), // phpcs:ignore WordPress.WP.I18n.NonSingularStringLiteralDomain -- intentional use of ET_CORE_TEXTDOMAIN 'name' => false, 'view' => false, 'type' => false, 'target' => false, 'include' => array(), 'exclude' => array(), ); $data = apply_filters( "et_core_portability_args_{$context}", (object) array_merge( $defaults, (array) $args ) ); et_core_cache_set( $context, $data, 'et_core_portability' ); // Stop here if not allowed. if ( function_exists( 'et_pb_is_allowed' ) && ! et_pb_is_allowed( array( 'portability', "{$data->context}_portability" ) ) ) { // Set view to false if not allowed. $data->view = false; et_core_cache_set( $context, $data, 'et_core_portability' ); return; } if ( $data->view ) { et_core_portability_load( $context ); } } endif; if ( ! function_exists( 'et_core_portability_load' ) ) : /** * Load Portability class. * * @since 2.7.0 * * @param string $context A unique ID used to register the portability arguments. * @return ET_Core_Portability */ function et_core_portability_load( $context ) { return new ET_Core_Portability( $context ); } endif; if ( ! function_exists( 'et_core_portability_link' ) ) : /** * HTML link to trigger the portability modal. * * @since 2.7.0 * * @param string $context The context used to register the portability. * @param string|array $attributes Optional. Query string or array of attributes. Default empty. * * @return string */ function et_core_portability_link( $context, $attributes = array() ) { $instance = et_core_cache_get( $context, 'et_core_portability' ); if ( ! $capability = et_core_portability_cap( $context ) ) { return ''; } if ( ! current_user_can( $capability ) || ! ( isset( $instance->view ) && $instance->view ) ) { return ''; } $defaults = array( 'title' => esc_attr__( 'Import & Export', ET_CORE_TEXTDOMAIN ), ); $attributes = array_merge( $defaults, $attributes ); // Forced attributes. $attributes['href'] = '#'; $context = esc_attr( $context ); $attributes['data-et-core-modal'] = "[data-et-core-portability='{$context}']"; $string = ''; foreach ( $attributes as $attribute => $value ) { if ( null !== $value ){ $string .= esc_attr( $attribute ) . '="' . esc_attr( $value ) . '" '; } } return sprintf( '<a %1$s><span>%2$s</span></a>', trim( $string ), esc_html( $attributes['title'] ) ); } endif; if ( ! function_exists( 'et_core_portability_ajax_import' ) ) : /** * Ajax portability Import. * * @since 2.7.0 */ function et_core_portability_ajax_import() { if ( ! isset( $_POST['context'] ) ) { et_core_die(); } $context = sanitize_text_field( $_POST['context'] ); $post_id = isset( $_POST['post'] ) ? (int) $_POST['post'] : 0; $replace = isset( $_POST['replace'] ) ? '1' === $_POST['replace'] : false; if ( ! $capability = et_core_portability_cap( $context ) ) { et_core_die(); } if ( ! et_core_security_check_passed( $capability, 'et_core_portability_import', 'nonce' ) ) { et_core_die(); } $portability = et_core_portability_load( $context ); if ( ! $result = $portability->import() ) { wp_send_json_error(); } else if ( is_array( $result ) && isset( $result['message'] ) ) { wp_send_json_error( $result ); } else if ( $result ) { if ( $replace && $post_id > 0 && current_user_can( 'edit_post', $post_id ) ) { wp_update_post( array( 'ID' => $post_id, 'post_content' => $result['postContent'], ) ); } wp_send_json_success( $result ); } wp_send_json_error(); } add_action( 'wp_ajax_et_core_portability_import', 'et_core_portability_ajax_import' ); endif; if ( ! function_exists( 'et_core_portability_ajax_export' ) ) : /** * Ajax portability Export. * * @since 2.7.0 */ function et_core_portability_ajax_export() { if ( ! isset( $_POST['context'] ) ) { wp_send_json_error(); return; } $context = sanitize_text_field( $_POST['context'] ); // phpcs:ignore Squiz.PHP.DisallowMultipleAssignments.FoundInControlStructure, WordPress.CodeAnalysis.AssignmentInCondition.Found -- Existing codebase. if ( ! $capability = et_core_portability_cap( $context ) ) { wp_send_json_error(); return; } if ( ! et_core_security_check_passed( $capability, 'et_core_portability_export', 'nonce' ) ) { wp_send_json_error(); return; } $return = isset( $_POST['return'] ) && sanitize_text_field( $_POST['return'] ); if ( $return ) { $data = et_core_portability_load( $context )->export( $return ); wp_send_json_success( $data ); } else { et_core_portability_load( $context )->export(); } wp_send_json_error(); } add_action( 'wp_ajax_et_core_portability_export', 'et_core_portability_ajax_export' ); endif; if ( ! function_exists( 'et_core_portability_ajax_cancel' ) ) : /** * Cancel portability action. * * @since 2.7.0 */ function et_core_portability_ajax_cancel() { if ( ! isset( $_POST['context'] ) ) { et_core_die(); } $context = sanitize_text_field( $_POST['context'] ); if ( ! $capability = et_core_portability_cap( $context ) ) { et_core_die(); } if ( ! et_core_security_check_passed( $capability, 'et_core_portability_cancel' ) ) { et_core_die(); } et_core_portability_load( $context )->delete_temp_files( true ); wp_send_json_error(); } add_action( 'wp_ajax_et_core_portability_cancel', 'et_core_portability_ajax_cancel' ); endif; if ( ! function_exists( 'et_core_upload_and_get_urls_from_presets_images' ) ) : /** * Upload images and return the new URLs for presets. * * @since 4.26.1 * @param array $data Array of images to upload. * * @return array */ function et_core_upload_and_get_urls_from_presets_images( $data ) { if ( ! current_user_can( 'manage_options' ) ) { return; } // Require the file that includes wp_generate_attachment_metadata(). require_once( ABSPATH . 'wp-admin/includes/image.php' ); $mime_types = get_allowed_mime_types(); $wp_upload_dir = wp_upload_dir(); $uploaded_urls = []; foreach ( $data as $imageInfo ) { $image_data = base64_decode( $imageInfo['encoded'] ); $temp_file = tempnam( $wp_upload_dir['path'], 'preset_' ); $filetype = wp_check_filetype( basename( $temp_file ), null ); if ( ! in_array( $filetype['type'], $mime_types, true ) ) { continue; } file_put_contents( $temp_file, $image_data ); $attachment = [ 'guid' => $wp_upload_dir['url'] . '/' . basename( $temp_file ), 'post_mime_type' => $filetype['type'], 'post_title' => preg_replace( '/\.[^.]+$/', '', basename( $temp_file ) ), 'post_content' => '', 'post_status' => 'inherit' ]; $attach_id = wp_insert_attachment( $attachment, $temp_file ); $attach_data = wp_generate_attachment_metadata( $attach_id, $temp_file ); wp_update_attachment_metadata( $attach_id, $attach_data ); $uploaded_urls[] = [ 'old_url' => $imageInfo['url'], 'new_url' => wp_get_attachment_url( $attach_id ), ]; unlink( $temp_file ); } return $uploaded_urls; } endif; if ( ! function_exists( 'et_core_replace_image_urls_in_presets' ) ) : /** * Replace image URLs in presets JSON string. */ function et_core_replace_image_urls_in_presets( $presets, $uploaded_urls ) { foreach ( $uploaded_urls as $url ) { $presets = str_replace( $url['old_url'], $url['new_url'], $presets ); } return $presets; } endif; if ( ! function_exists( 'et_core_portability_import_default_presets' ) ) : /** * Set the default preset for a modules. * * @since 4.26.0 */ function et_core_portability_import_default_presets() { if ( ! et_core_security_check_passed( 'manage_options', 'et_core_portability_import_default_presets', 'nonce' ) ) { et_core_die(); } $presets = isset( $_POST['presets'] ) ? sanitize_text_field( $_POST['presets'] ) : ''; $preset_prefix = isset( $_POST['presetPrefix'] ) ? sanitize_text_field( $_POST['presetPrefix'] ) : ''; $global_colors = isset( $_POST['globalColors'] ) ? sanitize_text_field( $_POST['globalColors'] ) : ''; $images = isset( $_POST['images'] ) ? sanitize_text_field( $_POST['images'] ) : ''; $uploaded_urls = []; $portability = et_core_portability_load( 'et_builder' ); if ( $global_colors ) { $global_colors = json_decode( stripslashes( $global_colors ), true ); $portability->import_global_colors( $global_colors ); } if ( $images ) { $images = json_decode( stripslashes( $images ), true ); $uploaded_urls = et_core_upload_and_get_urls_from_presets_images( $images ); } if ( $presets ) { if ( ! empty( $uploaded_urls ) ) { $presets = et_core_replace_image_urls_in_presets( $presets, $uploaded_urls ); } $presets = json_decode( stripslashes( $presets ), true ); $portability->import_global_presets( $presets, false, true, $preset_prefix ); } ET_Core_PageResource::remove_static_resources( 'all', 'all' ); wp_send_json_success(); } add_action( 'wp_ajax_et_core_portability_import_default_presets', 'et_core_portability_import_default_presets' ); endif; if ( ! function_exists( 'et_core_portability_export' ) ) : /** * Portability export. * * @since 2.7.0 */ function et_core_portability_export() { if ( ! isset( $_GET['et_core_portability'], $_GET['timestamp'] ) ) { return; } if ( ! et_core_security_check_passed( 'edit_posts' ) ) { wp_die( esc_html__( 'The export process failed. Please refresh the page and try again.', ET_CORE_TEXTDOMAIN ) ); } et_core_portability_load( sanitize_text_field( $_GET['timestamp'] ) )->download_export(); } add_action( 'admin_init', 'et_core_portability_export', 20 ); endif; if ( ! function_exists( 'et_core_portability_cap' ) ): /** * Returns the required WordPress Capability for a Portability context. * * @since 3.0.91 * * @param string $context The Portability context * * @return string */ function et_core_portability_cap( $context ) { $capability = ''; $options_contexts = array( 'et_pb_roles', 'epanel', 'epanel_temp', 'et_divi_mods', 'et_extra_mods', ); $post_contexts = array( 'et_builder', 'et_theme_builder', 'et_code_snippets', 'et_builder_layouts', ); if ( in_array( $context, $options_contexts, true ) ) { $capability = 'edit_theme_options'; } else if ( in_array( $context, $post_contexts, true ) ) { $capability = 'edit_posts'; } return $capability; } endif; components/Cache.php 0000644 00000021343 15222641012 0010443 0 ustar 00 <?php /** * Core Cache implements an object cache. * * The Object Cache stores all of the cache data to memory only for the duration of the request. * * @package Core\Cache */ /** * Core class that implements an object cache. * * The Object Cache is used to save on trips to the database. The * Object Cache stores all of the cache data to memory and makes the cache * contents available by using a key, which is used to name and later retrieve * the cache contents. * * @private * * @package ET\Core\Cache */ final class ET_Core_Cache { /** * Cached data. * * @since 1.0.0 * * @type array */ private static $cache = array(); /** * Adds data to the cache if it doesn't already exist. * * @since 1.0.0 * * @param int|string $key What to call the contents in the cache. * @param mixed $data The contents to store in the cache. * @param string $group Optional. Where to group the cache contents. Default 'default'. * @return bool False if cache key and group already exist, true on success */ public static function add( $key, $data, $group = 'default' ) { if ( empty( $group ) ) { $group = 'default'; } if ( self::_exists( $key, $group ) ) { return false; } return self::set( $key, $data, $group ); } /** * Sets the data contents into the cache. * * The cache contents is grouped by the $group parameter followed by the * $key. This allows for duplicate ids in unique groups. * * @since 1.0.0 * * @param int|string $key What to call the contents in the cache. * @param mixed $data The contents to store in the cache. * @param string $group Optional. Where to group the cache contents. Default 'default'. * @param int $expire Not Used. * @return true Always returns true. */ public static function set( $key, $data, $group = 'default' ) { if ( empty( $group ) ) { $group = 'default'; } if ( is_object( $data ) ) { $data = clone $data; } self::$cache[ $group ][ $key ] = $data; return true; } /** * Retrieves the cache contents, if it exists. * * The contents will be first attempted to be retrieved by searching by the * key in the cache group. If the cache is hit (success) then the contents * are returned. * * @since 1.0.0 * * @param int|string $key What the contents in the cache are called. * @param string $group Optional. Where the cache contents are grouped. Default 'default'. * @return false|mixed False on failure to retrieve contents or the cache contents on success. */ public static function get( $key, $group = 'default' ) { if ( empty( $group ) ) { $group = 'default'; } if ( self::_exists( $key, $group ) ) { if ( is_object( self::$cache[ $group ][ $key ] ) ) { return clone self::$cache[ $group ][ $key ]; } else { return self::$cache[ $group ][ $key ]; } } return false; } /** * Retrieves the cache contents for entire group, if it exists. * * If the cache is hit (success) then the contents of the group * are returned. * * @since 1.0.0 * * @param string $group Where the cache contents are grouped. * @return false|mixed False on failure to retrieve contents or the cache contents on success. */ public static function get_group( $group ) { if ( isset( self::$cache[ $group ] ) ) { return self::$cache[ $group ]; } return false; } /** * Check the cache contents, if given key and (optional) group exists. * * @since 1.0.0 * * @param int|string $key What the contents in the cache are called. * @param string $group Optional. Where the cache contents are grouped. Default 'default'. * @return bool False on failure to retrieve contents or True on success. */ public static function has( $key, $group = 'default' ) { if ( empty( $group ) ) { $group = 'default'; } return self::_exists( $key, $group ); } /** * Removes the contents of the cache key in the group. * * If the cache key does not exist in the group, then nothing will happen. * * @since 1.0.0 * * @param int|string $key What the contents in the cache are called. * @param string $group Optional. Where the cache contents are grouped. Default 'default'. * @return bool False if the contents weren't deleted and true on success. */ public static function delete( $key, $group = 'default' ) { if ( empty( $group ) ) { $group = 'default'; } if ( ! self::_exists( $key, $group ) ) { return false; } unset( self::$cache[ $group ][ $key ] ); return true; } /** * Clears the object cache of all data. * * @since 1.0.0 * * @return true Always returns true. */ public static function flush() { self::$cache = array(); return true; } /** * Serves as a utility function to determine whether a key exists in the cache. * * @since 1.0.0 * @private * * @param int|string $key Cache key to check for existence. * @param string $group Cache group for the key existence check. * @return bool Whether the key exists in the cache for the given group. */ private static function _exists( $key, $group ) { return isset( self::$cache[ $group ] ) && isset( self::$cache[ $group ][ $key ] ); } } if ( ! function_exists( 'et_core_cache_add' ) ) : /** * Adds data to the cache if it doesn't already exist. * * @since 1.0.0 * * @param int|string $key What to call the contents in the cache. * @param mixed $data The contents to store in the cache. * @param string $group Optional. Where to group the cache contents. Default 'default'. * @return bool False if cache key and group already exist, true on success */ function et_core_cache_add( $key, $data, $group = '' ) { return ET_Core_Cache::add( $key, $data, $group ); } endif; if ( ! function_exists( 'et_core_cache_set' ) ) : /** * Sets the data contents into the cache. * * The cache contents is grouped by the $group parameter followed by the * $key. This allows for duplicate ids in unique groups. * * @since 1.0.0 * * @param int|string $key What to call the contents in the cache. * @param mixed $data The contents to store in the cache. * @param string $group Optional. Where to group the cache contents. Default 'default'. * @param int $expire Not Used. * @return true Always returns true. */ function et_core_cache_set( $key, $data, $group = '' ) { return ET_Core_Cache::set( $key, $data, $group ); } endif; if ( ! function_exists( 'et_core_cache_get' ) ) : /** * Retrieves the cache contents, if it exists. * * The contents will be first attempted to be retrieved by searching by the * key in the cache group. If the cache is hit (success) then the contents * are returned. * * @since 1.0.0 * * @param int|string $key What the contents in the cache are called. * @param string $group Optional. Where the cache contents are grouped. Default 'default'. * @return false|mixed False on failure to retrieve contents or the cache contents on success. */ function et_core_cache_get( $key, $group = '' ) { return ET_Core_Cache::get( $key, $group ); } endif; if ( ! function_exists( 'et_core_cache_get_group' ) ) : /** * Retrieves the cache contents for entire group, if it exists. * * If the cache is hit (success) then the contents of the group * are returned. * * @since 1.0.0 * * @param string $group Where the cache contents are grouped. * @return false|mixed False on failure to retrieve contents or the cache contents on success. */ function et_core_cache_get_group( $group ) { return ET_Core_Cache::get_group( $group ); } endif; if ( ! function_exists( 'et_core_cache_has' ) ) : /** * Check the cache contents, if given key and (optional) group exists. * * @since 1.0.0 * * @param int|string $key What the contents in the cache are called. * @param string $group Optional. Where the cache contents are grouped. Default 'default'. * @return bool False on failure to retrieve contents or True on success. */ function et_core_cache_has( $key, $group = '' ) { return ET_Core_Cache::has( $key, $group ); } endif; if ( ! function_exists( 'et_core_cache_delete' ) ) : /** * Removes the contents of the cache key in the group. * * If the cache key does not exist in the group, then nothing will happen. * * @since 1.0.0 * * @param int|string $key What the contents in the cache are called. * @param string $group Optional. Where the cache contents are grouped. Default 'default'. * @return bool False if the contents weren't deleted and true on success. */ function et_core_cache_delete( $key, $group = '' ) { return ET_Core_Cache::delete( $key, $group ); } endif; if ( ! function_exists( 'et_core_cache_flush' ) ) : /** * Clears the object cache of all data. * * @since 1.0.0 * @return true Always returns true. */ function et_core_cache_flush() { return ET_Core_Cache::flush(); } endif; components/init.php 0000644 00000030273 15222641012 0010405 0 ustar 00 <?php // phpcs:disable Generic.WhiteSpace.ScopeIndent -- our preference is to not indent the whole inner function in this scenario. if ( ! function_exists( 'et_core_init' ) ) : /** * {@see 'plugins_loaded' (9999999) Must run after cache plugins have been loaded.} */ function et_core_init() { ET_Core_API_Spam_Providers::instance(); ET_Core_Cache_Directory::instance(); ET_Core_PageResource::startup(); ET_Core_CompatibilityWarning::instance(); if ( defined( 'ET_CORE_UPDATED' ) ) { global $wp_rewrite; add_action( 'shutdown', array( $wp_rewrite, 'flush_rules' ) ); update_option( 'et_core_page_resource_remove_all', true ); } $cache_dir = ET_Core_PageResource::get_cache_directory(); if ( file_exists( $cache_dir . '/DONOTCACHEPAGE' ) ) { ! defined( 'DONOTCACHEPAGE' ) ? define( 'DONOTCACHEPAGE', true ) : ''; @unlink( $cache_dir . '/DONOTCACHEPAGE' ); } if ( get_option( 'et_core_page_resource_remove_all' ) ) { ET_Core_PageResource::remove_static_resources( 'all', 'all', true ); } } endif; if ( ! function_exists( 'et_core_site_has_builder' ) ) : /** * Check is `et_core_site_has_builder` allowed. * We can clear cache managed by 3rd party plugins only * if Divi, Extra, or the Divi Builder plugin * is active when the core was called. * * @return boolean */ function et_core_site_has_builder() { global $shortname; $core_path = get_transient( 'et_core_path' ); $is_divi_builder_plugin_active = false; if ( ! empty( $core_path ) && false !== strpos( $core_path, '/divi-builder/' ) && function_exists('is_plugin_active') ) { $is_divi_builder_plugin_active = is_plugin_active( 'divi-builder/divi-builder.php' ); } if( $is_divi_builder_plugin_active || in_array( $shortname, array( 'divi', 'extra' ) ) ) { return true; } return false; } endif; if ( ! function_exists( 'et_core_clear_wp_cache' ) ): function et_core_clear_wp_cache( $post_id = '' ) { if ( ( ! wp_doing_cron() && ! et_core_security_check_passed( 'edit_posts' ) ) || ! et_core_site_has_builder() ) { return; } try { // Cache Plugins // Comet Cache if ( is_callable( 'comet_cache::clear' ) ) { comet_cache::clear(); } // WP Rocket if ( function_exists( 'rocket_clean_post' ) ) { if ( '' !== $post_id ) { rocket_clean_post( $post_id ); } else if ( function_exists( 'rocket_clean_domain' ) ) { rocket_clean_domain(); } } // W3 Total Cache if ( has_action( 'w3tc_flush_post' ) ) { '' !== $post_id ? do_action( 'w3tc_flush_post', $post_id ) : do_action( 'w3tc_flush_posts' ); } // WP Super Cache if ( function_exists( 'wp_cache_debug' ) && defined( 'WPCACHEHOME' ) ) { include_once WPCACHEHOME . 'wp-cache-phase1.php'; include_once WPCACHEHOME . 'wp-cache-phase2.php'; if ( '' !== $post_id && function_exists( 'clear_post_supercache' ) ) { clear_post_supercache( $post_id ); } else if ( '' === $post_id && function_exists( 'wp_cache_clear_cache_on_menu' ) ) { wp_cache_clear_cache_on_menu(); } } // WP Fastest Cache if ( isset( $GLOBALS['wp_fastest_cache'] ) ) { if ( '' !== $post_id && method_exists( $GLOBALS['wp_fastest_cache'], 'singleDeleteCache' ) ) { $GLOBALS['wp_fastest_cache']->singleDeleteCache( $post_id ); } else if ( '' === $post_id && method_exists( $GLOBALS['wp_fastest_cache'], 'deleteCache' ) ) { $GLOBALS['wp_fastest_cache']->deleteCache(); } } // Hummingbird if ( has_action( 'wphb_clear_page_cache' ) ) { '' !== $post_id ? do_action( 'wphb_clear_page_cache', $post_id ) : do_action( 'wphb_clear_page_cache' ); } // WordPress Cache Enabler if ( has_action( 'ce_clear_cache' ) ) { '' !== $post_id ? do_action( 'ce_clear_post_cache', $post_id ) : do_action( 'ce_clear_cache' ); } // LiteSpeed Cache v3.0+. if ( '' !== $post_id && has_action( 'litespeed_purge_post' ) ) { do_action( 'litespeed_purge_post', $post_id ); } elseif ( '' === $post_id && has_action( 'litespeed_purge_all' ) ) { do_action( 'litespeed_purge_all' ); } // LiteSpeed Cache v1.1.3 until v3.0. if ( '' !== $post_id && function_exists( 'litespeed_purge_single_post' ) ) { litespeed_purge_single_post( $post_id ); } elseif ( '' === $post_id && is_callable( 'LiteSpeed_Cache_API::purge_all' ) ) { LiteSpeed_Cache_API::purge_all(); } elseif ( is_callable( 'LiteSpeed_Cache::get_instance' ) ) { // LiteSpeed Cache v1.1.3 below. LiteSpeed_Cache still exist on v2.9.9.2, but no // longer exist on v3.0. Keep it here as backward compatibility for lower version. $litespeed = LiteSpeed_Cache::get_instance(); if ( '' !== $post_id && method_exists( $litespeed, 'purge_post' ) ) { $litespeed->purge_post( $post_id ); } else if ( '' === $post_id && method_exists( $litespeed, 'purge_all' ) ) { $litespeed->purge_all(); } } // Hyper Cache if ( class_exists( 'HyperCache' ) && isset( HyperCache::$instance ) ) { if ( '' !== $post_id && method_exists( HyperCache::$instance, 'clean_post' ) ) { HyperCache::$instance->clean_post( $post_id ); } else if ( '' === $post_id && method_exists( HyperCache::$instance, 'clean' ) ) { HyperCache::$instance->clean_post( $post_id ); } } // Hosting Provider Caching // Pantheon Advanced Page Cache $pantheon_clear = 'pantheon_wp_clear_edge_keys'; $pantheon_clear_all = 'pantheon_wp_clear_edge_all'; if ( function_exists( $pantheon_clear ) || function_exists( $pantheon_clear_all ) ) { if ( '' !== $post_id && function_exists( $pantheon_clear ) ) { pantheon_wp_clear_edge_keys( array( "post-{$post_id}" ) ); } else if ( '' === $post_id && function_exists( $pantheon_clear_all ) ) { pantheon_wp_clear_edge_all(); } } // Siteground if ( isset( $GLOBALS['sg_cachepress_supercacher'] ) ) { global $sg_cachepress_supercacher; if ( is_object( $sg_cachepress_supercacher ) && method_exists( $sg_cachepress_supercacher, 'purge_cache' ) ) { $sg_cachepress_supercacher->purge_cache( true ); } } else if ( function_exists( 'sg_cachepress_purge_cache' ) ) { sg_cachepress_purge_cache(); } // WP Engine if ( class_exists( 'WpeCommon' ) ) { is_callable( 'WpeCommon::purge_memcached' ) ? WpeCommon::purge_memcached() : ''; is_callable( 'WpeCommon::clear_maxcdn_cache' ) ? WpeCommon::clear_maxcdn_cache() : ''; is_callable( 'WpeCommon::purge_varnish_cache' ) ? WpeCommon::purge_varnish_cache() : ''; if ( is_callable( 'WpeCommon::instance' ) && $instance = WpeCommon::instance() ) { method_exists( $instance, 'purge_object_cache' ) ? $instance->purge_object_cache() : ''; } } // Bluehost if ( class_exists( 'Endurance_Page_Cache' ) ) { wp_doing_ajax() ? ET_Core_LIB_BluehostCache::get_instance()->clear( $post_id ) : do_action( 'epc_purge' ); } // Pressable. if ( isset( $GLOBALS['batcache'] ) && is_object( $GLOBALS['batcache'] ) ) { wp_cache_flush(); } // Cloudways - Breeze. if ( class_exists( 'Breeze_Admin' ) ) { $breeze_admin = new Breeze_Admin(); $breeze_admin->breeze_clear_all_cache(); } // Kinsta. if ( class_exists( '\Kinsta\Cache' ) && isset( $GLOBALS['kinsta_cache'] ) && is_object( $GLOBALS['kinsta_cache'] ) ) { global $kinsta_cache; if ( isset( $kinsta_cache->kinsta_cache_purge ) && method_exists( $kinsta_cache->kinsta_cache_purge, 'purge_complete_caches' ) ) { $kinsta_cache->kinsta_cache_purge->purge_complete_caches(); } } // GoDaddy. if ( class_exists( '\WPaaS\Cache' ) ) { global $wpaas_cache_class; // Since GD System Plugin 4.51.1 the cache class instance can be accessed // with $wpaas_cache_class global. In addition to this, the 'has_ban' method // is no longer static. To cover both static and non-static versions we // can test if $wpaas_cache_class exists and use the correct type accordingly. $has_ban = $wpaas_cache_class ? $wpaas_cache_class->has_ban() : \WPaaS\Cache::has_ban(); if ( ! $has_ban ) { $gd_cache_class = $wpaas_cache_class ? $wpaas_cache_class : '\WPaaS\Cache'; remove_action( 'shutdown', array( $gd_cache_class, 'purge' ), PHP_INT_MAX ); add_action( 'shutdown', array( $gd_cache_class, 'ban' ), PHP_INT_MAX ); } } // Complimentary Performance Plugins. // Autoptimize. if ( is_callable( 'autoptimizeCache::clearall' ) ) { autoptimizeCache::clearall(); } // WP Optimize. if ( class_exists( 'WP_Optimize' ) && defined( 'WPO_PLUGIN_MAIN_PATH' ) ) { if ( '' !== $post_id && is_callable( 'WPO_Page_Cache::delete_single_post_cache' ) ) { WPO_Page_Cache::delete_single_post_cache( $post_id ); } elseif ( is_callable( array( 'WP_Optimize', 'get_page_cache' ) ) && is_callable( array( WP_Optimize()->get_page_cache(), 'purge' ) ) ) { WP_Optimize()->get_page_cache()->purge(); } } } catch( Exception $err ) { ET_Core_Logger::error( 'An exception occurred while attempting to clear site cache.' ); } } endif; if ( ! function_exists( 'et_core_get_nonces' ) ): /** * Returns the nonces for this component group. * * @return string[] */ function et_core_get_nonces() { static $nonces = null; return $nonces ? $nonces : $nonces = array( 'clear_page_resources_nonce' => wp_create_nonce( 'clear_page_resources' ), 'et_core_portability_export' => wp_create_nonce( 'et_core_portability_export' ), ); } endif; if ( ! function_exists( 'et_core_page_resource_auto_clear' ) ): function et_core_page_resource_auto_clear() { ET_Core_PageResource::remove_static_resources( 'all', 'all' ); } add_action( 'switch_theme', 'et_core_page_resource_auto_clear' ); add_action( 'activated_plugin', 'et_core_page_resource_auto_clear', 10, 0 ); add_action( 'deactivated_plugin', 'et_core_page_resource_auto_clear', 10, 0 ); endif; if ( ! function_exists( 'et_core_page_resource_clear' ) ): /** * Ajax handler for clearing cached page resources. */ function et_core_page_resource_clear() { et_core_security_check( 'manage_options', 'clear_page_resources' ); if ( empty( $_POST['et_post_id'] ) ) { et_core_die(); } $post_id = sanitize_key( $_POST['et_post_id'] ); $owner = sanitize_key( $_POST['et_owner'] ); ET_Core_PageResource::remove_static_resources( $post_id, $owner ); } add_action( 'wp_ajax_et_core_page_resource_clear', 'et_core_page_resource_clear' ); endif; if ( ! function_exists( 'et_core_page_resource_get' ) ): /** * Get a page resource instance. * * @param string $owner The owner of the instance (core|divi|builder|bloom|monarch|custom). * @param string $slug A string that uniquely identifies the resource. * @param string|int $post_id The post id that the resource is associated with or `global`. * If `null`, the return value of {@link get_the_ID()} will be used. * @param string $type The resource type (style|script). Default: `style`. * @param string $location Where the resource should be output (head|footer). Default: `head-late`. * * @return ET_Core_PageResource */ function et_core_page_resource_get( $owner, $slug, $post_id = null, $priority = 10, $location = 'head-late', $type = 'style' ) { $post_id = $post_id ? $post_id : et_core_page_resource_get_the_ID(); $_slug = "et-{$owner}-{$slug}-{$post_id}-cached-inline-{$type}s"; $all_resources = ET_Core_PageResource::get_resources(); return isset( $all_resources[ $_slug ] ) ? $all_resources[ $_slug ] : new ET_Core_PageResource( $owner, $slug, $post_id, $priority, $location, $type ); } endif; if ( ! function_exists( 'et_core_page_resource_get_the_ID' ) ): function et_core_page_resource_get_the_ID() { static $post_id = null; if ( is_int( $post_id ) ) { return $post_id; } return $post_id = apply_filters( 'et_core_page_resource_current_post_id', get_the_ID() ); } endif; if ( ! function_exists( 'et_core_page_resource_is_singular' ) ): function et_core_page_resource_is_singular() { return apply_filters( 'et_core_page_resource_is_singular', is_singular() ); } endif; if ( ! function_exists( 'et_debug' ) ): function et_debug( $msg, $bt_index = 4, $log_ajax = true ) { ET_Core_Logger::debug( $msg, $bt_index, $log_ajax ); } endif; if ( ! function_exists( 'et_wrong' ) ): function et_wrong( $msg, $error = false ) { $msg = "You're Doing It Wrong! {$msg}"; if ( $error ) { et_error( $msg ); } else { et_debug( $msg ); } } endif; if ( ! function_exists( 'et_error' ) ): function et_error( $msg, $bt_index = 4 ) { ET_Core_Logger::error( "[ERROR]: {$msg}", $bt_index ); } endif; components/HTTPInterface.php 0000644 00000026016 15222641012 0012042 0 ustar 00 <?php /** * Simple object to hold HTTP request details. * * @since 1.1.0 * * @package ET\Core\HTTP */ class ET_Core_HTTPRequest { /** * @var array */ public $ARGS; /** * @var bool */ public $BLOCKING = true; /** * @var null|array */ public $BODY = null; /** * @var bool */ public $COMPLETE = false; /** * @var array */ public $COOKIES = array(); /** * @var array */ public $HEADERS = array(); /** * @var bool */ public $IS_AUTH = false; /** * @var string */ public $METHOD = 'GET'; /** * @var string */ public $OWNER; /** * @var string */ public $URL; /** * @var string */ public $USER_AGENT; /** * ET_Core_HTTP_Request constructor. * * @param string $url The request URL. * @param string $method HTTP request method. Default is 'GET'. * @param string $owner The name of the owner of this request instance. Default is 'ET_Core'. * @param bool $is_auth Whether or not this request is auth-related. Cache disabled if `true`. Default is `false`. * @param array $body The request body. Default is `null`. * @param bool $is_json_body */ public function __construct( $url, $method = 'GET', $owner = 'ET_Core', $is_auth = false, $body = null, $is_json_body = false, $ssl_verify = true ) { $this->URL = esc_url_raw( $url ); $this->METHOD = $method; $this->BODY = $body; $this->IS_AUTH = $is_auth; $this->OWNER = $owner; $this->data_format = null; $this->JSON_BODY = $is_json_body; $this->SSL_VERIFY = $ssl_verify; $this->_set_user_agent(); $this->prepare_args(); } /** * Only include necessary properties when printing this object using {@link var_dump}. * * @return array */ public function __debugInfo() { return array( 'ARGS' => $this->ARGS, 'URL' => $this->URL, 'METHOD' => $this->METHOD, 'BODY' => $this->BODY, 'IS_AUTH' => $this->IS_AUTH, 'IS_JSON_BODY' => $this->JSON_BODY, 'OWNER' => $this->OWNER, ); } /** * Sets the user agent string. */ private function _set_user_agent() { global $wp_version; $owner = $this->OWNER; $version = 'bloom' === $owner ? $GLOBALS['et_bloom']->plugin_version : ET_CORE_VERSION; if ( 'builder' === $owner ) { $owner = 'Divi Builder'; } if ( '' === $owner ) { $this->OWNER = $owner = 'ET_Core'; } else { $owner = ucfirst( $owner ); } $this->USER_AGENT = "WordPress/{$wp_version}; {$owner}/{$version}; " . esc_url_raw( get_bloginfo( 'url' ) ); } /** * Prepares the request arguments (to be passed to wp_remote_*()) */ public function prepare_args() { $this->ARGS = array( 'blocking' => $this->BLOCKING, 'body' => $this->BODY, 'cookies' => $this->COOKIES, 'headers' => $this->HEADERS, 'method' => $this->METHOD, 'sslverify' => $this->SSL_VERIFY, 'user-agent' => $this->USER_AGENT, 'timeout' => 30, ); } } /** * Simple object to hold HTTP response details. * * @since 1.1.0 * * @package ET\Core\HTTP */ class ET_Core_HTTPResponse { /** * @var array */ public $COOKIES; /** * @var string|array */ public $DATA; /** * @var bool */ public $ERROR = false; /** * The error message if `self::$ERROR` is `true`. * * @var string */ public $ERROR_MESSAGE; /** * @var array */ public $HEADERS; /** * @var array|WP_Error */ public $RAW_RESPONSE; /** * @var ET_Core_HTTPRequest */ public $REQUEST; /** * The response's HTTP status code. * * @var int */ public $STATUS_CODE; /** * @var string */ public $STATUS_MESSAGE; /** * ET_Core_HTTP_Response constructor. * * @param ET_Core_HTTPRequest $request * @param array|WP_Error $response */ public function __construct( $request, $response ) { $this->REQUEST = $request; $this->RAW_RESPONSE = $response; $this->_parse_response(); } /** * Parse response and save relevant details. */ private function _parse_response() { if ( is_wp_error( $this->RAW_RESPONSE ) ) { $this->ERROR = true; $this->ERROR_MESSAGE = $this->RAW_RESPONSE->get_error_message(); $this->STATUS_CODE = $this->RAW_RESPONSE->get_error_code(); $this->STATUS_MESSAGE = $this->ERROR_MESSAGE; return; } $this->DATA = $this->RAW_RESPONSE['body']; $this->HEADERS = $this->RAW_RESPONSE['headers']; $this->COOKIES = $this->RAW_RESPONSE['cookies']; $this->STATUS_CODE = $this->RAW_RESPONSE['response']['code']; $this->STATUS_MESSAGE = $this->RAW_RESPONSE['response']['message']; if ( $this->STATUS_CODE >= 400 ) { $this->ERROR = true; $this->ERROR_MESSAGE = $this->STATUS_MESSAGE; } } /** * Only include necessary properties when printing this object using {@link var_dump}. * * @return array */ public function __debugInfo() { return array( 'STATUS_CODE' => $this->STATUS_CODE, 'STATUS_MESSAGE' => $this->STATUS_MESSAGE, 'ERROR' => $this->ERROR, 'ERROR_MESSAGE' => $this->ERROR_MESSAGE, 'DATA' => $this->DATA, ); } /** * Only include necessary properties when serializing this object for * storage in the WP Transient Cache. * * @return array */ public function __sleep() { return array( 'ERROR', 'ERROR_MESSAGE', 'STATUS_CODE', 'STATUS_MESSAGE', 'DATA' ); } } /** * High level, generic, wrapper for making HTTP requests. It uses WordPress HTTP API under-the-hood. * * @since 1.1.0 * * @package ET\Core\HTTP */ class ET_Core_HTTPInterface { /** * How much time responses are cached (in seconds). * * @since 1.1.0 * @var int */ protected $cache_timeout; /** * @var ET_Core_HTTPRequest */ public $request; /** * @var ET_Core_HTTPResponse */ public $response; /** * Whether or not json responses are expected to be received. Default is `true`. * * @var bool */ public $expects_json; /** * The name of the theme/plugin that created this class instance. Default: 'ET_Core'. * * @var string */ public $owner; /** * ET_Core_API_HTTP_Interface constructor. * * @since 1.1.0 * * @param string $owner The name of the theme/plugin that created this class instance. Default: 'ET_Core'. * @param array $request_details Array of config values for the request. Optional. * @param bool $json Whether or not json responses are expected to be received. Default is `true`. */ public function __construct( $owner = 'ET_Core', $request_details = array(), $json = true ) { $this->expects_json = $json; $this->cache_timeout = 15 * MINUTE_IN_SECONDS; $this->owner = $owner; if ( ! empty( $request_details ) ) { list( $url, $method, $is_auth, $body ) = $request_details; $this->prepare_request( $url, $method, $is_auth, $body ); } } /** * Only include necessary properties when printing this object using {@link var_dump}. * * @return array */ public function __debugInfo() { return array( 'REQUEST' => $this->request, 'RESPONSE' => $this->response, ); } /** * Only include necessary properties when serializing this object for * storage in the WP Transient Cache. * * @return array */ public function __sleep() { return array( 'request', 'response' ); } /** * Creates an identifier key for a request based on the URL and body content. * * @internal * @since 1.1.0 * * @param string $url The request URL. * @param string|string[] $body The request body. * * @return string */ protected static function _get_cache_key_for_request( $url, $body ) { if ( is_array( $body ) ) { $url .= json_encode( $body ); } else if ( ! empty( $body ) ) { $url .= $body; } return 'et-core-http-response-' . md5( $url ); } /** * Writes request/response info to the error log for failed requests. * * @internal * @since 1.1.0 */ protected function _log_failed_request() { $details = print_r( $this, true ); $class_name = get_class( $this ); $msg_part = "{$class_name} ERROR :: Remote request failed...\n\n"; $msg = "{$msg_part}Details: {$details}"; $max_len = @ini_get( 'log_errors_max_len' ); @ini_set( 'log_errors_max_len', 0 ); ET_Core_Logger::error( $msg ); if ( $max_len ) { @ini_set( 'log_errors_max_len', $max_len ); } } /** * Prepares request to send JSON data. */ protected function _setup_json_request() { $this->request->HEADERS['Accept'] = 'application/json'; if ( $this->request->JSON_BODY ) { $this->request->HEADERS['Content-Type'] = 'application/json'; $is_json = is_string( $this->request->BODY ) && in_array( $this->request->BODY[0], array( '[', '{' ) ); if ( $is_json || null === $this->request->BODY ) { return; } $this->request->BODY = json_encode( $this->request->BODY ); } } /** * Performs a remote HTTP request. Responses are cached for {@see self::$cache_timeout} seconds using * the {@link https://goo.gl/c0FSMH WP Transients API}. * * @since 1.1.0 */ public function make_remote_request() { $response = null; if ( $this->expects_json && ! isset( $this->request->HEADERS['Content-Type'] ) ) { $this->_setup_json_request(); } // Make sure we include any changes made after request object was instantiated. $this->request->prepare_args(); if ( 'POST' === $this->request->METHOD ) { $response = wp_remote_post( $this->request->URL, $this->request->ARGS ); } else if ( 'GET' === $this->request->METHOD && null === $this->request->data_format ) { $response = wp_remote_get( $this->request->URL, $this->request->ARGS ); } else if ( 'GET' === $this->request->METHOD && null !== $this->request->data_format ) { // WordPress sends data as query args for GET and HEAD requests and provides no way // to alter that behavior. Thus, we need to monkey patch it for now. See the mp'd class // for more details. require_once 'lib/WPHttp.php'; $wp_http = new ET_Core_LIB_WPHttp(); $this->request->ARGS['data_format'] = $this->request->data_format; $response = $wp_http->request( $this->request->URL, $this->request->ARGS ); } else if ( 'PUT' === $this->request->METHOD ) { $this->request->ARGS['method'] = 'PUT'; $response = wp_remote_request( $this->request->URL, $this->request->ARGS ); } $this->response = $response = new ET_Core_HTTPResponse( $this->request, $response ); if ( $response->ERROR || defined( 'ET_DEBUG' ) ) { $this->_log_failed_request(); } if ( $this->expects_json ) { $response->DATA = json_decode( $response->DATA, true ); } $this->request->COMPLETE = true; } /** * Replaces the current request object with a new instance. * * @param string $url * @param string $method * @param bool $is_auth * @param mixed? $body * @param bool $json_body * @param bool $ssl_verify */ public function prepare_request( $url, $method = 'GET', $is_auth = false, $body = null, $json_body = false, $ssl_verify = true ) { $this->request = new ET_Core_HTTPRequest( $url, $method, $this->owner, $is_auth, $body, $json_body, $ssl_verify ); } } components/SupportCenterMUAutoloader.php 0000644 00000003135 15222641012 0014536 0 ustar 00 <?php /** * Plugin Name: ET Support Center :: Must-Use Plugins Autoloader * Plugin URI: http://www.elegantthemes.com * Description: This plugin enables the Elegant Themes Support Center to provide more consistent functionality when Safe Mode is active. * Author: Elegant Themes * Author URI: http://www.elegantthemes.com * License: GPLv2 or later * * @package ET\Core\SupportCenter\SafeModeDisablePlugins * @author Elegant Themes <http://www.elegantthemes.com> * @license GNU General Public License v2 <http://www.gnu.org/licenses/gpl-2.0.html> */ // The general idea here is loosely based on <https://codex.wordpress.org/Must_Use_Plugins#Autoloader_Example>. // Quick exit if accessed directly if ( ! defined( 'ABSPATH' ) ) { exit; } // We only want to load these MU Plugins if Support Center is installed $support_center_installed = get_option( 'et_support_center_installed' ); if ( $support_center_installed ) { // Compile a list of plugins in the `mu-plugins/et-safe-mode` directory // (see `$pathname_to` in `ET_Core_SupportCenter::maybe_add_mu_autoloader()`) if ( $mu_plugins = glob( dirname( __FILE__ ) . '/et-safe-mode/*.php' ) ) { // Verbose logging: only log if `wp-config.php` has defined `ET_DEBUG='support_center'` $DEBUG_ET_SUPPORT_CENTER = defined( 'ET_DEBUG' ) && 'support_center' === ET_DEBUG; // Loop through the list of plugins and require each in turn foreach ( $mu_plugins as $plugin ) { if ( file_exists( $plugin ) ) { if ( $DEBUG_ET_SUPPORT_CENTER ) { error_log( 'ET Support Center: loading mu-plugin: ' . $plugin ); } require_once( $plugin ); } } } } components/README.md 0000644 00000001646 15222641012 0010212 0 ustar 00 ## Core Components This directory contains all of Core's PHP Components. Components are organized into groups using a nested directory structure. ### What's Inside |File|Name|Description| |:--------|:----------|:----------| |**api**|**ET_Core_API**|Communicate with 3rd-party APIs| |**data**|**ET_Core_Data**|Work with data (consume, format, etc)| |**lib**|**ET_Core_LIB**|3rd-Party Libraries| |**post**|**ET_Core_Post**|Work with WP Objects| |Cache.php|ET_Core_Cache|Simple object cache| |HTTPInterface.php|ET_Core_HTTPInterface|Wrapper for WP's HTTP API| |Logger.php|ET_Core_Logger|Write to the debug log. |PageResource.php|ET_Core_PageResource|Cache inline styles & scripts as static files.| |Portability.php|ET_Core_Portability|Portability import/export| |Rollback.php|ET_Core_VersionRollback|Theme & plugin version rollback| |Updates.php|ET_Core_Updates|Theme & plugin updates| > ***Note:*** Component groups are in **bold**. components/PageResource.php 0000644 00000103473 15222641012 0012031 0 ustar 00 <?php /** * Manages a frontend inline CSS or JavaScript resource. * * If possible, the resource will be served as a static file for better performance. It can be * tied to a specific post or it can be 'global'. The resource can be output, static or inline, * to one of four locations on the page: * * * `head-early`: right AFTER theme styles have been enqueued * * `head` : right BEFORE the theme and wp's inline custom css * * `head-late` : right AFTER the theme and wp's inline custom css * * `footer` : in the footer * * The first time the class is instantiated, a static callback method will be registered for each * output location. Inside each callback, we'll iterate over any/all instances that are assigned * to the current output location and perform the following steps: * * 1. If a static file exists for the resource, go to the next step. Otherwise, try to create * a static file for the resource if it has `data`. If it doesn't have `data`, assign it to * the next output location and then move on to the next resource (continue). * 2. If a static file exists for the resource, enqueue it (via WP or manually) and then move on * to the next resource (continue). If no static file exists, go to the next step. * 3. Output the resource inline. * * @since 2.0 * * @package ET\Core */ class ET_Core_PageResource { /** * Lock file. * * @var string[] */ protected static $_lock_file; /** * Onload attribute for stylesheet output. * * @var string[] */ private static $_onload = ''; /** * Output locations. * * @var string[] */ protected static $_output_locations = array( 'head-early', 'head', 'head-late', 'footer', ); /** * Resource owners. * * @var string[] */ protected static $_owners = array( 'divi', 'builder', 'epanel', 'epanel_temp', 'extra', 'core', 'bloom', 'monarch', 'custom', 'all', ); /** * Resource scopes. * * @var string[] */ protected static $_scopes = array( 'global', 'post', ); /** * Temp DIRS. * * @var array */ protected static $_temp_dirs = array(); /** * Resource types. * * @var string[] */ protected static $_types = array( 'style', 'script', ); /** * Whether or not we have write access to the filesystem. * * @var bool */ protected static $_can_write; /** * Request ID. * * @var int */ protected static $_request_id; /** * Request time. * * @var string */ protected static $_request_time; /** * All instances of this class. * * @var ET_Core_PageResource[] { * * @type ET_Core_PageResource $slug * } */ protected static $_resources; /** * All instances of this class organized by output location and sorted by priority. * * @var array[] { * * @type array[] $location {@see self::$_output_locations} { * * @type ET_Core_PageResource[] $priority { * * @type ET_Core_PageResource $slug * } * } * } */ protected static $_resources_by_location; /** * All instances of this class organized by scope. * * @var array[] { * * @type ET_Core_PageResource[] $post|$global { * * @type ET_Core_PageResource $slug * } * } */ protected static $_resources_by_scope; /** * @var string */ public static $WP_CONTENT_DIR; /** * @var string */ public static $current_output_location; /** * @var ET_Core_Data_Utils */ public static $data_utils; /** * @var \WP_Filesystem_Base|null */ public static $wpfs; /** * The absolute path to the directory where the static resource will be stored. * * @var string */ public $base_dir; /** * The absolute path to the static resource on the server. * * @var string */ public $path; /** * Temp DIR. * * @var array */ public $temp_dir; /** * The absolute URL through which the static resource can be downloaded. * * @var string */ public $url; /** * The data/contents for/of the static resource sorted by priority. * * @var array */ public $data; /** * Whether or not this resource has been disabled. * * @var bool */ public $disabled; /** * Whether or not the static resource file has been enqueued. * * @var bool */ public $enqueued; /** * Whether or not this resource is forced inline. * * @var bool */ public $forced_inline; /** * @var string */ public $filename; /** * Whether or not the resource has already been output to the page inline. * * @var bool */ public $inlined; /** * The owner of this instance. * * @var string */ public $owner; /** * The id of the post to which this resource belongs. * * @var string */ public $post_id; /** * The priority of this resource. * * @var int */ public $priority; /** * A unique identifier for this resource. * * @var string */ public $slug; /** * The resource type (style|script). * * @var string */ public $type; /** * The output location during which this resource's static file should be generated. * * @var string */ public $write_file_location; /** * The output location where this resource should be output. * * @var string */ public $location; /** * ET_Core_PageResource constructor * * @param string $owner The owner of the instance (core|divi|builder|bloom|monarch|custom). * @param string $slug A string that uniquely identifies the resource. * @param string|int $post_id The post id that the resource is associated with or `global`. * If `null`, {@link get_the_ID()} will be used. * @param string $type The resource type (style|script). Default: `style`. * @param string $location Where the resource should be output (head|footer). Default: `head`. */ public function __construct( $owner, $slug, $post_id = null, $priority = 10, $location = 'head-late', $type = 'style' ) { $this->owner = self::_validate_property( 'owner', $owner ); $this->post_id = self::_validate_property( 'post_id', $post_id ? $post_id : et_core_page_resource_get_the_ID() ); $this->type = self::_validate_property( 'type', $type ); $this->location = self::_validate_property( 'location', $location ); $this->write_file_location = $this->location; $this->filename = sanitize_file_name( "et-{$this->owner}-{$slug}-{$post_id}" ); $this->slug = "{$this->filename}-cached-inline-{$this->type}s"; $this->data = array(); $this->priority = $priority; self::startup(); $this->_initialize_resource(); } /** * Activates the class */ public static function startup() { if ( null !== self::$_resources ) { // Class has already been initialized return; } $time = (string) microtime( true ); $time = str_replace( '.', '', $time ); $rand = (string) mt_rand(); self::$_request_time = $time; self::$_request_id = "{$time}-{$rand}"; self::$_resources = array(); self::$data_utils = new ET_Core_Data_Utils(); foreach ( self::$_output_locations as $location ) { self::$_resources_by_location[ $location ] = array(); } foreach ( self::$_scopes as $scope ) { self::$_resources_by_scope[ $scope ] = array(); } // phpcs:enable self::$WP_CONTENT_DIR = self::$data_utils->normalize_path( WP_CONTENT_DIR ); self::$_lock_file = self::$_request_id . '~'; self::_register_callbacks(); self::_setup_wp_filesystem(); self::$_can_write = et_core_cache_dir()->can_write; } /** * Cleanup and save */ public static function shutdown() { if ( ! self::$_resources || ! self::$_can_write ) { return; } // Remove any leftover temporary directories that belong to this request foreach ( self::$_temp_dirs as $temp_directory ) { if ( file_exists( $temp_directory . '/' . self::$_lock_file ) ) { @self::$wpfs->delete( $temp_directory, true ); } } // Reset $_resources property; Mostly useful for unit test big request which needs to make // each test*() method act like it is different page request self::$_resources = null; if ( et_()->WPFS()->exists( self::$WP_CONTENT_DIR . '/cache/et' ) ) { // Remove old cache directory et_()->WPFS()->rmdir( self::$WP_CONTENT_DIR . '/cache/et', true ); } } protected static function _assign_output_location( $location, $resource ) { $priority_existed = isset( self::$_resources_by_location[ $location ][ $resource->priority ] ); self::$_resources_by_location[ $location ][ $resource->priority ][ $resource->slug ] = $resource; if ( ! $priority_existed ) { // We've added a new priority to the list, so put them back in sorted order. ksort( self::$_resources_by_location[ $location ], SORT_NUMERIC ); } } /** * Enqueues static file for provided script resource. * * @param ET_Core_PageResource $resource page resources. */ protected static function _enqueue_script( $resource ) { // Bust PHP's stats cache for the resource file to ensure we get the latest timestamp. clearstatcache( true, $resource->path ); $can_enqueue = 0 === did_action( 'wp_print_scripts' ); $timestamp = filemtime( $resource->path ); if ( $can_enqueue ) { wp_enqueue_script( $resource->slug, set_url_scheme( $resource->url ), array(), $timestamp, true ); } else { $timestamp = $timestamp ? $timestamp : ET_CORE_VERSION; printf( '<script id="%1$s" src="%2$s"></script>', // phpcs:ignore WordPress.WP.EnqueuedResources.NonEnqueuedScript esc_attr( $resource->slug ), esc_url( set_url_scheme( $resource->url . "?ver={$timestamp}" ) ) ); } $resource->enqueued = true; } /** * Enqueues static file for provided style resource. * * @param ET_Core_PageResource $resource */ protected static function _enqueue_style( $resource ) { if ( 'footer' === self::$current_output_location ) { return; } // Bust PHP's stats cache for the resource file to ensure we get the latest timestamp. clearstatcache( true, $resource->path ); $can_enqueue = 0 === did_action( 'wp_print_scripts' ); // reason: We do this on purpose when a style can't be enqueued. // phpcs:disable WordPress.WP.EnqueuedResources.NonEnqueuedStylesheet $template = '<link rel="stylesheet" id="%1$s" href="%2$s" />'; // phpcs:enable $timestamp = filemtime( $resource->path ); if ( $can_enqueue ) { wp_enqueue_style( $resource->slug, set_url_scheme( $resource->url ), array(), $timestamp ); } else { // reason: this whole file needs to be converted. // phpcs:disable ET.Sniffs.ValidVariableName.UsedPropertyNotSnakeCase $timestamp = $timestamp ?: ET_CORE_VERSION; $slug = esc_attr( $resource->slug ); $scheme = esc_url( set_url_scheme( $resource->url . "?ver={$timestamp}" ) ); $tag = sprintf( $template, $slug, $scheme ); $onload = et_core_esc_previously( self::$_onload ); // phpcs:enable $tag = apply_filters( 'et_core_page_resource_tag', $tag, $slug, $scheme, $onload ); print( et_core_esc_previously( $tag ) ); } $resource->enqueued = true; } /** * Returns the next output location. * * @see self::$_output_locations * * @return string */ protected static function _get_next_output_location() { $current_index = array_search( self::$current_output_location, self::$_output_locations, true ); if ( false === $current_index || ! is_int( $current_index ) ) { ET_Core_Logger::error( '$current_output_location is invalid!' ); } $current_index += 1; return self::$_output_locations[ $current_index ]; } /** * Creates static resource files for an output location if needed. * * @param string $location {@link self::$_output_locations}. */ protected static function _maybe_create_static_resources( $location ) { self::$current_output_location = $location; // Disable for footer inside builder if page uses Theme Builder Editor to avoid conflict with critical CSS. if ( 'footer' === $location && et_core_is_fb_enabled() && et_fb_is_theme_builder_used_on_page() ) { return false; } $sorted_resources = self::get_resources_by_output_location( $location ); foreach ( $sorted_resources as $priority => $resources ) { foreach ( $resources as $slug => $resource ) { if ( $resource->write_file_location !== $location ) { // This resource's static file needs to be generated later on. self::_assign_output_location( $resource->write_file_location, $resource ); continue; } if ( ! self::$_can_write ) { // The reason we don't simply check this before looping through resources and // bail if it fails is because we need to perform the output location assignment // in the previous conditional regardless (otherwise builder styles will break). continue; } if ( $resource->forced_inline || $resource->has_file() ) { continue; } $data = $resource->get_data( 'file' ); if ( empty( $data ) && 'footer' !== $location ) { // This resource doesn't have any data yet so we'll assign it to the next output location. $next_location = self::_get_next_output_location(); $resource->set_output_location( $next_location ); continue; } $force_write = apply_filters( 'et_core_page_resource_force_write', false, $resource ); if ( ! $force_write && empty( $data ) ) { continue; } // Make sure directory exists. if ( ! self::$data_utils->ensure_directory_exists( $resource->base_dir ) ) { self::$_can_write = false; return; } $can_continue = true; // Try to create a temporary directory which we'll use as a pseudo file lock if ( @mkdir( $resource->temp_dir, 0755 ) ) { //phpcs:ignore WordPress.PHP.NoSilencedErrors.Discouraged -- Just ignore this since it's an internal use. self::$_temp_dirs[] = $resource->temp_dir; // Make sure another request doesn't delete our temp directory. $lock_file = $resource->temp_dir . '/' . self::$_lock_file; self::$wpfs->put_contents( $lock_file, '' ); // Create the static resource file if ( ! self::$wpfs->put_contents( $resource->path, $data, 0644 ) ) { // There's no point in continuing self::$_can_write = $can_continue = false; } else { // Remove the temporary directory self::$wpfs->delete( $resource->temp_dir, true ); /** * Fires when the static resource file is created. * * @since 4.10.8 * * @param object $resource The resource object. */ do_action( 'et_core_static_file_created', $resource ); } } elseif ( file_exists( $resource->temp_dir ) ) { // The static resource file is currently being created by another request continue; } else { // Failed for some other reason. There's no point in continuing self::$_can_write = $can_continue = false; return; } if ( ! $can_continue ) { return; } if ( ! defined( 'DONOTCACHEPAGE' ) ) { define( 'DONOTCACHEPAGE', true ); } } } } /** * Enqueues static files for an output location if available. * * @param string $location {@link self::$_output_locations}. */ protected static function _maybe_enqueue_static_resources( $location ) { $sorted_resources = self::get_resources_by_output_location( $location ); foreach ( $sorted_resources as $priority => $resources ) { foreach ( $resources as $slug => $resource ) { if ( $resource->disabled ) { // Resource is disabled. Remove it from the queue. self::_unassign_output_location( $location, $resource ); continue; } if ( $resource->forced_inline || ! $resource->url || ! $resource->has_file() ) { continue; } if ( 'style' === $resource->type ) { self::_enqueue_style( $resource ); } elseif ( 'script' === $resource->type ) { self::_enqueue_script( $resource ); } if ( $resource->enqueued ) { self::_unassign_output_location( $location, $resource ); } } } } /** * Outputs all non-enqueued resources for an output location inline. * * @param string $location {@link self::$_output_locations}. */ protected static function _maybe_output_inline_resources( $location ) { $sorted_resources = self::get_resources_by_output_location( $location ); foreach ( $sorted_resources as $priority => $resources ) { foreach ( $resources as $slug => $resource ) { if ( $resource->disabled ) { // Resource is disabled. Remove it from the queue. self::_unassign_output_location( $location, $resource ); continue; } $data = $resource->get_data( 'inline' ); $same_write_file_location = $resource->write_file_location === $resource->location; if ( empty( $data ) && 'footer' !== $location && $same_write_file_location ) { // This resource doesn't have any data yet so we'll assign it to the next output location. $next_location = self::_get_next_output_location(); $resource->set_output_location( $next_location ); continue; } elseif ( empty( $data ) ) { continue; } printf( '<%1$s id="%2$s">%3$s</%1$s>', esc_html( $resource->type ), esc_attr( $resource->slug ), et_core_esc_previously( wp_strip_all_tags( $data ) ) ); if ( $same_write_file_location ) { // File wasn't created during this location's callback and it won't be created later $resource->inlined = true; } } } } /** * Registers necessary callbacks. */ protected static function _register_callbacks() { $class = 'ET_Core_PageResource'; // Output Location: head-early, right after theme styles have been enqueued. add_action( 'wp_enqueue_scripts', array( $class, 'head_early_output_cb' ), 11 ); // Output Location: head, right BEFORE the theme and wp's custom css. add_action( 'wp_head', array( $class, 'head_output_cb' ), 99 ); // Output Location: head-late, right AFTER the theme and wp's custom css. add_action( 'wp_head', array( $class, 'head_late_output_cb' ), 103 ); // Output Location: footer. add_action( 'wp_footer', array( $class, 'footer_output_cb' ), 20 ); // Always delete cached resources for a post upon saving. add_action( 'save_post', array( $class, 'save_post_cb' ), 10, 3 ); // Always delete cached resources for theme customizer upon saving. add_action( 'customize_save_after', array( $class, 'customize_save_after_cb' ) ); /* * Always delete dynamic css when saving widgets. * `widget_update_callback` fires on save for any of the present widgets, * `delete_widget` fires on save for any deleted widget. */ add_filter( 'widget_update_callback', array( $class, 'widget_update_callback_cb' ) ); add_filter( 'delete_widget', array( $class, 'widget_update_callback_cb' ) ); } /** * Initializes the WPFilesystem class. */ protected static function _setup_wp_filesystem() { // The wpfs instance will always exists at this point because the cache dir class initializes it beforehand self::$wpfs = $GLOBALS['wp_filesystem']; } /** * Unassign a resource from an output location. * * @param string $location {@link self::$_output_locations}. * @param ET_Core_PageResource $resource */ protected static function _unassign_output_location( $location, $resource ) { unset( self::$_resources_by_location[ $location ][ $resource->priority ][ $resource->slug ] ); } protected static function _validate_property( $property, $value ) { $valid_values = array( 'location' => self::$_output_locations, 'owner' => self::$_owners, 'type' => self::$_types, ); switch ( $property ) { case 'path': $value = et_()->normalize_path( realpath( $value ) ); $is_valid = et_()->starts_with( $value, et_core_cache_dir()->path ); break; case 'url': $base_url = et_core_cache_dir()->url; $is_valid = et_()->starts_with( $value, set_url_scheme( $base_url, 'http' ) ); $is_valid = $is_valid ? $is_valid : et_()->starts_with( $value, set_url_scheme( $base_url, 'https' ) ); break; case 'post_id': $is_valid = 'global' === $value || 'all' === $value || is_numeric( $value ); break; default: $is_valid = isset( $valid_values[ $property ] ) && in_array( $value, $valid_values[ $property ] ); break; } return $is_valid ? $value : ''; } /** * Whether or not we are able to write to the filesystem. * * @return bool */ public static function can_write_to_filesystem() { return ET_Core_Cache_Directory::instance()->can_write; } /** * Output Location: footer * {@see 'wp_footer' (20) Allow third-party extensions some room to do what they do} */ public static function footer_output_cb() { self::_maybe_create_static_resources( 'footer' ); self::_maybe_enqueue_static_resources( 'footer' ); self::_maybe_output_inline_resources( 'footer' ); } /** * Returns the absolute path to our cache directory. * * @since 4.0.8 Removed `$path_type` param b/c cache directory might not be located under wp-content. * @since 3.0.52 * * @return string */ public static function get_cache_directory() { return et_core_cache_dir()->path; } /** * Returns all current resources. * * @return array {@link self::$_resources} */ public static function get_resources() { return self::$_resources; } /** * Returns the current resources for the provided output location, sorted by priority. * * @param string $location The desired output location {@see self::$_output_locations}. * * @return array[] { * * @type ET_Core_PageResource[] $priority { * * @type ET_Core_PageResource $slug Resource. * ... * } * ... * } */ public static function get_resources_by_output_location( $location ) { return self::$_resources_by_location[ $location ]; } /** * Returns the current resources for the provided scope. * * @param string $scope The desired scope (post|global). * * @return ET_Core_PageResource[] */ public static function get_resources_by_scope( $scope ) { return self::$_resources_by_scope[ $scope ]; } /** * Output Location: head-early * {@see 'wp_enqueue_scripts' (11) Should run right after the theme enqueues its styles.} */ public static function head_early_output_cb() { self::_maybe_create_static_resources( 'head-early' ); self::_maybe_enqueue_static_resources( 'head-early' ); self::_maybe_output_inline_resources( 'head-early' ); } /** * Output Location: head * {@see 'wp_head' (99) Must run BEFORE the theme and WP's custom css callbacks.} */ public static function head_output_cb() { self::_maybe_create_static_resources( 'head' ); self::_maybe_enqueue_static_resources( 'head' ); self::_maybe_output_inline_resources( 'head' ); } /** * Output Location: head-late * {@see 'wp_head' (103) Must run AFTER the theme and WP's custom css callbacks.} */ public static function head_late_output_cb() { self::_maybe_create_static_resources( 'head-late' ); self::_maybe_enqueue_static_resources( 'head-late' ); self::_maybe_output_inline_resources( 'head-late' ); } /** * {@see 'widget_update_callback'} * * @param array $instance Widget settings being saved. */ public static function widget_update_callback_cb( $instance ) { self::remove_static_resources( 'all', 'all', false, 'dynamic' ); return $instance; } /** * {@see 'customize_save_after'} * * @param WP_Customize_Manager $manager */ public static function customize_save_after_cb( $manager ) { self::remove_static_resources( 'all', 'all' ); } /** * {@see 'save_post'} * * @param int $post_id * @param WP_Post $post * @param bool $update */ public static function save_post_cb( $post_id, $post, $update ) { // In Dynamic CSS, we parse the layout content for generating styles and store it under the `object_id`, so clearing // only the layout assets won't update the page style if we made any changes to the layout/global modules etc. // Hence, we need to clear all static resources when we update a layout. // Also, we should only clear the cache if the layout being saved is a global module/row/section. if ( 'et_pb_layout' === $post->post_type ) { $taxonomies = get_taxonomies( [ 'object_type' => [ 'et_pb_layout' ] ] ); $tax_to_clear = array( 'scope', 'layout_type' ); $types_to_clear = array( 'module', 'row', 'section' ); $scope_terms = get_the_terms( $post_id, 'scope' ); $layout_terms = get_the_terms( $post_id, 'layout_type' ); if ( ! empty( $scope_terms ) && ! empty( $layout_terms ) ) { $scope_terms = wp_list_pluck( $scope_terms, 'slug' ); $layout_terms = wp_list_pluck( $layout_terms, 'slug' ); $is_global = in_array( 'global', $scope_terms, true ); $clearable_modules = array_intersect( $types_to_clear, $layout_terms ); $remove_resource = $is_global && ! empty( $clearable_modules ); foreach ( $taxonomies as $taxonomy ) { if ( in_array( $taxonomy, $tax_to_clear, true ) && $remove_resource ) { $post_id = 'all'; break; } } } } self::remove_static_resources( $post_id, 'all' ); } /** * Remove static resources for a post, or optionally all resources, if any exist. * * @param string $post_id id of post. * @param string $owner owner of file. * @param bool $force remove all resources. * @param string $slug file slug. */ public static function remove_static_resources( $post_id, $owner = 'core', $force = false, $slug = 'all' ) { if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { return; } if ( ! wp_doing_cron() && ! et_core_security_check_passed( 'edit_posts' ) ) { return; } if ( ! self::can_write_to_filesystem() ) { return; } if ( ! self::$data_utils ) { self::startup(); } self::do_remove_static_resources( $post_id, $owner, $force, $slug ); } /** * Remove static resources action. * * @param string $post_id id of post. * @param string $owner owner of file. * @param bool $force remove all resources. * @param string $slug file slug. */ public static function do_remove_static_resources( $post_id, $owner = 'core', $force = false, $slug = 'all' ) { $post_id = self::_validate_property( 'post_id', $post_id ); $owner = self::_validate_property( 'owner', $owner ); $slug = sanitize_key( $slug ); if ( '' === $owner || '' === $post_id ) { return; } $_post_id = 'all' === $post_id ? '*' : $post_id; $_owner = 'all' === $owner ? '*' : $owner; $_slug = 'all' === $slug ? '*' : $slug; $cache_dir = self::get_cache_directory(); $files = array_merge( // Remove any CSS files missing a parent folder. (array) glob( "{$cache_dir}/et-{$_owner}-*" ), // Remove CSS files for individual posts or all posts if $post_id set to 'all'. (array) glob( "{$cache_dir}/{$_post_id}/et-{$_owner}-{$_slug}*" ), // Remove CSS files that contain theme builder template CSS. // Multiple directories need to be searched through since * doesn't match / in the glob pattern. (array) glob( "{$cache_dir}/*/et-{$_owner}-{$_slug}-*tb-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/*/et-{$_owner}-{$_slug}-*tb-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/*/*/et-{$_owner}-{$_slug}-*tb-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/et-{$_owner}-{$_slug}-*tb-for-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/*/et-{$_owner}-{$_slug}-*tb-for-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/*/*/et-{$_owner}-{$_slug}-*tb-for-{$_post_id}*" ), // Remove Dynamic CSS files for categories, tags, authors, archives, homepage post feed and search results. (array) glob( "{$cache_dir}/taxonomy/*/*/et-{$_owner}-dynamic*" ), (array) glob( "{$cache_dir}/author/*/et-{$_owner}-dynamic*" ), (array) glob( "{$cache_dir}/archive/et-{$_owner}-dynamic*" ), (array) glob( "{$cache_dir}/search/et-{$_owner}-dynamic*" ), (array) glob( "{$cache_dir}/notfound/et-{$_owner}-dynamic*" ), (array) glob( "{$cache_dir}/home/et-{$_owner}-dynamic*" ), // WP Templates and Template Parts. (array) glob( "{$cache_dir}/*/et-{$_owner}-{$_slug}-*wpe-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/*/et-{$_owner}-{$_slug}-*wpe-{$_post_id}*" ), (array) glob( "{$cache_dir}/*/*/*/et-{$_owner}-{$_slug}-*wpe-{$_post_id}*" ) ); self::_remove_files_in_directory( $files, $cache_dir ); // Remove empty directories. self::$data_utils->remove_empty_directories( $cache_dir ); // Clear cache managed by 3rd-party cache plugins. $post_id = ! empty( $post_id ) && absint( $post_id ) > 0 ? $post_id : ''; et_core_clear_wp_cache( $post_id ); // Purge the module features cache. if ( class_exists( 'ET_Builder_Module_Features' ) ) { if ( ! empty( $post_id ) ) { ET_Builder_Module_Features::purge_cache( $post_id ); } else { ET_Builder_Module_Features::purge_cache(); } } // Purge the google fonts cache. if ( empty( $post_id ) && class_exists( 'ET_Builder_Google_Fonts_Feature' ) ) { ET_Builder_Google_Fonts_Feature::purge_cache(); } // Purge the dynamic assets cache. if ( empty( $post_id ) && class_exists( 'ET_Builder_Dynamic_Assets_Feature' ) ) { ET_Builder_Dynamic_Assets_Feature::purge_cache(); } $post_meta_caches = array( 'et_enqueued_post_fonts', '_et_dynamic_cached_shortcodes', '_et_dynamic_cached_attributes', '_et_builder_module_features_cache', ); // Clear post meta caches. foreach ( $post_meta_caches as $post_meta_cache ) { if ( ! empty( $post_id ) ) { delete_post_meta( $post_id, $post_meta_cache ); } else { delete_post_meta_by_key( $post_meta_cache ); } } // Set our DONOTCACHEPAGE file for the next request. self::$data_utils->ensure_directory_exists( $cache_dir ); self::$wpfs->put_contents( $cache_dir . '/DONOTCACHEPAGE', '' ); if ( $force ) { delete_option( 'et_core_page_resource_remove_all' ); } /** * Fires when the static resources are removed. * * @since 4.21.1 * * @param mixed $post_id The post ID. */ do_action( 'et_core_static_resources_removed', $post_id ); } /** * Removes a list of files from the designated directory. * * @param array[] $files List of patterns to match. * @param string $cache_dir Cache directory. */ protected static function _remove_files_in_directory( $files, $cache_dir ) { foreach ( $files as $file ) { $file = self::$data_utils->normalize_path( $file ); if ( ! et_()->starts_with( $file, $cache_dir ) ) { // File is not located inside cache directory so skip it. continue; } if ( is_file( $file ) ) { self::$wpfs->delete( $file ); } } } public static function wpfs() { if ( null !== self::$wpfs ) { return self::$wpfs; } self::startup(); return self::$wpfs = et_core_cache_dir()->wpfs; } protected function _initialize_resource() { if ( ! self::can_write_to_filesystem() ) { $this->base_dir = $this->temp_dir = $this->path = $this->url = ''; //phpcs:ignore Squiz.PHP.DisallowMultipleAssignments.Found -- Just ignore this since it's an internal use. $this->_register_resource(); return; } $file_extension = 'style' === $this->type ? '.min.css' : '.min.js'; $path = self::get_cache_directory(); $url = et_core_cache_dir()->url; $file = et_()->path( $path, $this->post_id, $this->filename . $file_extension ); if ( file_exists( $file ) ) { // Static resource file exists $this->path = self::$data_utils->normalize_path( $file ); $this->base_dir = dirname( $this->path ); $this->url = et_()->path( $url, $this->post_id, basename( $this->path ) ); } else { // Static resource file doesn't exist $url .= "/{$this->post_id}/{$this->filename}{$file_extension}"; $path .= "/{$this->post_id}/{$this->filename}{$file_extension}"; $this->base_dir = self::$data_utils->normalize_path( dirname( $path ) ); $this->temp_dir = $this->base_dir . "/{$this->slug}~"; $this->path = $path; $this->url = $url; } $this->_register_resource(); } protected function _register_resource() { $this->enqueued = false; $this->inlined = false; $scope = 'global' === $this->post_id ? 'global' : 'post'; self::$_resources[ $this->slug ] = $this; self::$_resources_by_scope[ $scope ][ $this->slug ] = $this; self::_assign_output_location( $this->location, $this ); } public function get_data( $context ) { $result = ''; ksort( $this->data, SORT_NUMERIC ); /** * Filters the resource's data array. * * @since 3.0.52 * * @param array[] $data { * * @type string[] $priority Resource data. * ... * } * @param string $context Where the data will be used. Accepts 'inline', 'file'. * @param ET_Core_PageResource $resource The resource instance. */ $resource_data = apply_filters( 'et_core_page_resource_get_data', $this->data, $context, $this ); foreach ( $resource_data as $priority => $data_part ) { foreach ( $data_part as $data ) { $result .= $data; } } return $result; } /** * Whether or not a static resource exists on the filesystem for this instance. * * @return bool */ public function has_file() { if ( ! self::$wpfs || empty( $this->path ) || ! self::can_write_to_filesystem() ) { return false; } return self::$wpfs->exists( $this->path ); } /** * Set the resource's data. * * @param string $data * @param int $priority */ public function set_data( $data, $priority = 10 ) { if ( 'style' === $this->type ) { $data = et_core_data_utils_minify_css( $data ); // Remove empty media queries // @media only..and (feature:value) { } $pattern = '/@media\s+([\w\s]+)?\([\w-]+:[\w\d-]+\)\{\s*\}/'; $data = preg_replace( $pattern, '', $data ); } $this->data[ $priority ][] = trim( strip_tags( str_replace( '\n', '', $data ) ) ); } public function set_output_location( $location ) { if ( ! self::_validate_property( 'location', $location ) ) { return; } $current_location = $this->location; self::_unassign_output_location( $current_location, $this ); self::_assign_output_location( $location, $this ); $this->location = $location; } public function unregister_resource() { $scope = 'global' === $this->post_id ? 'global' : 'post'; unset( self::$_resources[ $this->slug ], self::$_resources_by_scope[ $scope ][ $this->slug ] ); self::_unassign_output_location( $this->location, $this ); } } components/SupportCenter.php 0000644 00000364371 15222641012 0012270 0 ustar 00 <?php // Quick exit if accessed directly if ( ! defined( 'ABSPATH' ) ) { exit; } /** * Elegant Themes Support Center adds a new page to the WP Admin menu. * * System Status * Here we note system settings that could potentially cause problems. An extended view (displaying all settings we * check, not just those with problematic results) can be toggled, with an option to copy this report to the * clipboard so it can be pasted in a support ticket. * * Elegant Themes Support * If Remote Access is enabled in this section, Elegant Themes Support will be granted limited access to the user's site * (@see ET_Core_SupportCenter::support_user_maybe_create_user()). When this is activated, a second toggle appears * for the user that will allow them to enable "Full Admin Privileges" which has no restrictions (only certain ET * Support staff will be able to request that the user enables this). Full Admin Privileges can be disabled at any * time, but are automatically disabled whenever the Remote Access is disabled (manually or by timeout). Time * remaining until Remote Access is automatically deactivated is indicated alongside the toggle. A link for * initiating a chat https://www.elegantthemes.com/members-area/help/ is also available in this section. * * Divi Documentation & Help * This section contains common help videos, articles, and a link to full documentation. This is not meant to be a * full service documentation center; it's mainly a launch off point. * * Divi Safe Mode * A quick and easy way for users and support to quickly disable plugins and scripts to see if Divi is the cause of * an issue. This call to action disables active plugins, custom css, child themes, scripts in the Integrations tab, * static css, and combination/minification of CSS and JS. When enabling this, the user will be presented with a * list of plugins that will be affected (disabled). Sitewide (not including the Visual Builder), there will be a * floating indicator in the upper right or left corner of the website that will indicate that Safe Mode is enabled * and will contain a link that takes you to the Support Page to disabled it. * * Logs * If WP_DEBUG_LOG is enabled, WordPress related errors will be archived in a log file. We load the most recent entries * of this log file for convienient viewing here, with a link to download the full log, as well as an option to copy * the log to the clipboard so it can be pasted in a support ticket. * * @package ET\Core\SupportCenter * @author Elegant Themes <http://www.elegantthemes.com> * @license GNU General Public License v2 <http://www.gnu.org/licenses/gpl-2.0.html> * * @since 3.24.1 Renamed from `ET_Support_Center` to `ET_Core_SupportCenter`. * @since 3.20 */ class ET_Core_SupportCenter { /** * Catch whether the ET_DEBUG flag is set. * * @since 3.20 * * @type string */ protected $DEBUG_ET_SUPPORT_CENTER = false; /** * Identifier for the parent theme or plugin activating the Support Center. * * @since 3.20 * * @type string */ protected $parent = ''; /** * "Nice name" for the parent theme or plugin activating the Support Center. * * @since 3.20 * * @type string */ protected $parent_nicename = ''; /** * Whether the Support Center was activated through a `plugin` or a `theme`. * * @since 3.20 * * @type string */ protected $child_of = ''; /** * Identifier for the parent theme or plugin activating the Support Center. * * @since 3.20 * * @type string */ protected $local_path; /** * Support User options * * @since 3.20 * * @type array */ protected $support_user_options; /** * Support User account name * * @since 3.20 * * @type string */ protected $support_user_account_name = 'elegant_themes_support'; /** * Support options name in the database * * @since 3.20 * * @type string */ protected $support_user_options_name = 'et_support_options'; /** * Name of the cron job we use to auto-delete the Support User account * * @since 3.20 * * @type string */ protected $support_user_cron_name = 'et_cron_delete_support_account'; /** * Expiration time to auto-delete the Support User account via cron * * @since 3.20 * * @type string */ protected $support_user_expiration_time = '+4 days'; /** * Provide nicename equivalents for boolean values * * @since 3.23 * * @type array */ protected $boolean_label = array( 'False', 'True' ); /** * Collection of plugins that we will NOT disable when Safe Mode is activated. * * @since 3.20 * * @type array */ protected $safe_mode_plugins_allowlist = array( 'etdev/etdev.php', // ET Development Workspace 'bloom/bloom.php', // ET Bloom Plugin 'monarch/monarch.php', // ET Monarch Plugin 'divi-builder/divi-builder.php', // ET Divi Builder Plugin 'divi-dash/divi-dash.php', // Divi Dash Plugin 'ari-adminer/ari-adminer.php', // ARI Adminer 'query-monitor/query-monitor.php', // Query Monitor 'woocommerce/woocommerce.php', // WooCommerce 'really-simple-ssl/rlrsssl-really-simple-ssl.php', // Really Simple SSL ); /** * Capabilities that should be granted to the Administrator role on activation. * * @since 3.28 * * @type array */ protected $support_center_administrator_caps = array( 'et_support_center', 'et_support_center_system', 'et_support_center_remote_access', 'et_support_center_documentation', 'et_support_center_safe_mode', 'et_support_center_logs', ); /** * Collection of Cards that has button to dismiss the Card. * * @since 4.4.7 * * @type array */ protected $card_with_dismiss_button = array( 'et_hosting_card', ); /** * Core functionality of the class * * @since 4.4.7 Added WP AJAX action for dismissible button for a card * @since 3.20 * * @param string $parent Identifier for the parent theme or plugin activating the Support Center. */ public function __construct( $parent = '' ) { // Verbose logging: only log if `wp-config.php` has defined `ET_DEBUG='support_center'` $this->DEBUG_ET_SUPPORT_CENTER = defined( 'ET_DEBUG' ) && 'support_center' === ET_DEBUG; // Set the identifier for the parent theme or plugin activating the Support Center. $this->parent = $parent; // Get `et_support_options` settings & set $this->support_user_options $this->support_user_get_options(); // Set the plugins allowlist for Safe Mode $this->set_safe_mode_plugins_allowlist(); } /** * WordPress action & filter setup * * @since 3.20 */ public function init() { update_option( 'et_support_center_installed', 'true' ); // Establish which theme or plugin has loaded the Support Center $this->set_parent_properties(); // When initialized, deactivate conflicting plugins $this->deactivate_conflicting_plugins(); add_action( 'admin_enqueue_scripts', array( $this, 'admin_enqueue_scripts_styles' ) ); add_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts_styles' ) ); // SC scripts are only used in FE for the "Turn Off Divi Safe Mode" floating button. if ( et_core_is_safe_mode_active() ) { add_action( 'wp_enqueue_scripts', array( $this, 'enqueue_scripts_styles' ) ); } // Get Site ID with Elegant Themes API & token (needed in advance for Remote Access). add_action( 'admin_init', array( $this, 'maybe_set_site_id' ) ); // Add extra User Role capabilities needed for Remote Access to work with 3rd party software add_filter( 'add_et_support_standard_capabilities', array( $this, 'support_user_extra_caps_standard' ), 10, 1 ); add_filter( 'add_et_support_elevated_capabilities', array( $this, 'support_user_extra_caps_elevated' ), 10, 1 ); // Make sure that our Support Account's roles are set up add_filter( 'add_et_builder_role_options', array( $this, 'support_user_add_role_options' ), 10, 1 ); // On Multisite installs, grant `unfiltered_html` capabilities to the Support User add_filter( 'map_meta_cap', array( $this, 'support_user_map_meta_cap' ), 1, 3 ); // Add CSS class name(s) to the Support Center page's body tag add_filter( 'admin_body_class', array( $this, 'add_admin_body_class_name' ) ); // Add a link to the Support Center in the admin menu add_filter( 'admin_menu', array( $this, 'add_admin_menu_item' ) ); // When Safe Mode is enabled, add floating frontend indicator add_action( 'admin_footer', array( $this, 'maybe_add_safe_mode_indicator' ) ); add_action( 'wp_footer', array( $this, 'maybe_add_safe_mode_indicator' ) ); // Add User capabilities to the Administrator Role add_action( 'admin_init', array( $this, 'support_center_capabilities_setup' ) ); if ( 'plugin' === $this->child_of ) { // Delete our Support User settings on deactivation register_deactivation_hook( __FILE__, array( $this, 'support_user_delete_account' ) ); register_deactivation_hook( __FILE__, array( $this, 'unlist_support_center' ) ); register_deactivation_hook( __FILE__, array( $this, 'support_center_capabilities_teardown' ) ); } if ( 'theme' === $this->child_of ) { // Delete our Support User settings on deactivation add_action( 'switch_theme', array( $this, 'maybe_deactivate_on_theme_switch' ) ); } // Automatically delete our Support User when the time runs out add_action( $this->support_user_cron_name, array( $this, 'support_user_cron_maybe_delete_account' ) ); add_action( 'init', array( $this, 'support_user_maybe_delete_expired_account' ) ); add_action( 'admin_init', array( $this, 'support_user_maybe_delete_expired_account' ) ); // Remove KSES filters for ET Support User add_action( 'admin_init', array( $this, 'support_user_kses_remove_filters' ) ); // Update Support User settings via AJAX add_action( 'wp_ajax_et_support_user_update', array( $this, 'support_user_update_via_ajax' ) ); // Toggle Safe Mode via AJAX add_action( 'wp_ajax_et_safe_mode_update', array( $this, 'safe_mode_update_via_ajax' ) ); // Safe Mode: Block restricted actions when Safe Mode active add_action( 'admin_footer', array( $this, 'render_safe_mode_block_restricted' ) ); // Safe Mode: Temporarily disable Custom CSS add_action( 'init', array( $this, 'maybe_disable_custom_css' ) ); // Safe Mode: Remove "Additional CSS" from WP Head action hook if ( et_core_is_safe_mode_active() ) { remove_action( 'wp_head', 'wp_custom_css_cb', 101 ); } // Support Center Card: Handle Dismiss Button add_action( 'wp_ajax_et_dismiss_support_center_card', array( $this, 'dismiss_support_center_card_via_ajax' ) ); } /** * Add User capabilities to the Administrator Role (if it exists) on first run * * @since 3.29.2 Added check to verify the Administrator Role exists before attempting to run `add_cap()`. * @since 3.28 */ public function support_center_capabilities_setup() { $support_capabilities = get_option( 'et_support_center_setup_done' ); $administrator_role = get_role( 'administrator' ); if ( $administrator_role && ! $support_capabilities ) { foreach ( $this->support_center_administrator_caps as $cap ) { $administrator_role->add_cap( $cap ); } update_option( 'et_support_center_setup_done', 'processed' ); } } /** * Remove User capabilities from the Administrator Role when product with Support Center is removed * * @since 3.29.2 Added check to verify the Administrator Role exists before attempting to run `remove_cap()`. * @since 3.28 */ public function support_center_capabilities_teardown() { $support_capabilities = get_option( 'et_support_center_setup_done' ); $administrator_role = get_role( 'administrator' ); if ( $administrator_role && $support_capabilities ) { foreach ( $this->support_center_administrator_caps as $cap ) { $administrator_role->remove_cap( $cap ); } delete_option( 'et_support_center_setup_done' ); } } /** * Set variables that change depending on whether a theme or a plugin activated the Support Center * * @since 3.20 */ public function set_parent_properties() { $core_path = _et_core_normalize_path( trailingslashit( dirname( __FILE__ ) ) ); $theme_dir = _et_core_normalize_path( trailingslashit( realpath( get_template_directory() ) ) ); if ( 0 === strpos( $core_path, $theme_dir ) ) { $this->child_of = 'theme'; $this->local_path = trailingslashit( get_template_directory_uri() . '/core/' ); } else { $this->child_of = 'plugin'; $this->local_path = plugins_url( '/', dirname( __FILE__ ) ); } $this->parent_nicename = $this->get_parent_nicename( $this->parent ); } /** * Get the "Nice Name" for the parent theme/plugin * * @param $parent * * @return bool|string */ public function get_parent_nicename( $parent ) { switch ( $parent ) { case 'bloom_plugin': return 'Bloom'; break; case 'monarch_plugin': return 'Monarch'; break; case 'extra_theme': return 'Extra'; break; case 'divi_theme': return 'Divi'; break; case 'divi_builder_plugin': return 'Divi Builder'; break; case 'divi_dash_plugin': return 'Divi Dash'; break; default: return false; } } /** * Prevent any possible conflicts with the Elegant Themes Support plugin * * @since 3.20 */ public function deactivate_conflicting_plugins() { require_once( ABSPATH . 'wp-admin/includes/plugin.php' ); // Load WP user management functions if ( is_multisite() ) { require_once( ABSPATH . 'wp-admin/includes/ms.php' ); } else { require_once( ABSPATH . 'wp-admin/includes/user.php' ); } // Verify that WP user management functions are available $can_delete_user = false; if ( is_multisite() && function_exists( 'wpmu_delete_user' ) ) { $can_delete_user = true; } if ( ! is_multisite() && function_exists( 'wp_delete_user' ) ) { $can_delete_user = true; } if ( $can_delete_user ) { deactivate_plugins( '/elegant-themes-support/elegant-themes-support.php' ); } else { et_error( 'Support Center: Unable to deactivate the ET Support Plugin.' ); } } /** * @param string $capability * * @return bool */ protected function current_user_can( $capability = '' ) { if ( function_exists( 'et_is_builder_plugin_active' ) ) { return et_pb_is_allowed( $capability ); } return current_user_can( $capability ); } /** * Add Safe Mode Autoloader Must-Use Plugin * * @since 3.20 */ public function maybe_add_mu_autoloader() { $file_name = '/SupportCenterMUAutoloader.php'; $file_path = dirname( __FILE__ ); // Exit if the `mu-plugins` directory doesn't exist & we're unable to create it if ( ! wp_mkdir_p( WPMU_PLUGIN_DIR ) ) { et_error( 'Support Center Safe Mode: mu-plugin folder not found.' ); return; } $pathname_to = WPMU_PLUGIN_DIR . $file_name; $pathname_from = $file_path . $file_name; // Exit if we can't find the mu-plugins autoloader if ( ! file_exists( $pathname_from ) ) { et_error( 'Support Center Safe Mode: mu-plugin autoloader not found.' ); return; } // Try to create a new subdirectory for our mu-plugins; if it fails, log an error message $pathname_plugins_from = dirname( __FILE__ ) . '/mu-plugins'; $pathname_plugins_to = WPMU_PLUGIN_DIR . '/et-safe-mode'; if ( ! wp_mkdir_p( $pathname_plugins_to ) ) { et_error( 'Support Center Safe Mode: mu-plugins subfolder not found.' ); return; } // Try to copy the mu-plugins; if any fail, log an error message if ( $mu_plugins = glob( dirname( __FILE__ ) . '/mu-plugins/*.php' ) ) { foreach ( $mu_plugins as $plugin ) { $new_file_path = str_replace( $pathname_plugins_from, $pathname_plugins_to, $plugin ); // Skip if this particular mu-plugin hasn't changed if ( file_exists( $new_file_path ) && md5_file( $new_file_path ) === md5_file( $plugin ) ) { continue; } $copy_file = @copy( $plugin, $new_file_path ); if ( ! $this->DEBUG_ET_SUPPORT_CENTER ) { continue; } if ( $copy_file ) { et_error( 'Support Center Safe Mode: mu-plugin [' . $plugin . '] installed.' ); } else { et_error( 'Support Center Safe Mode: mu-plugin [' . $plugin . '] failed installation. ' ); } } } // Finally, try to copy the autoloader file; if it fails, log an error message // Skip if the mu-plugins autoloader hasn't changed if ( file_exists( $pathname_to ) && md5_file( $pathname_to ) === md5_file( $pathname_from ) ) { return; } $copy_file = @copy( $pathname_from, $pathname_to ); if ( $this->DEBUG_ET_SUPPORT_CENTER ) { if ( $copy_file ) { et_error( 'Support Center Safe Mode: mu-plugin installed.' ); } else { et_error( 'Support Center Safe Mode: mu-plugin failed installation. ' ); } } } public function maybe_remove_mu_autoloader() { @unlink( WPMU_PLUGIN_DIR . '/SupportCenterMUAutoloader.php' ); @unlink( WPMU_PLUGIN_DIR . '/et-safe-mode/SupportCenterSafeModeDisablePlugins.php' ); et_()->remove_empty_directories( WPMU_PLUGIN_DIR . '/et-safe-mode' ); } /** * Update the Site ID data via Elegant Themes API * * @since ?.? Early exit if no Site ID, but also no API credentials to use for a request. * @since 3.20 * * @return void */ public function maybe_set_site_id() { // Early exit if the user doesn't have Support Center access. if ( ! $this->current_user_can( 'et_support_center' ) ) { return; } $site_id = get_option( 'et_support_site_id' ); // If we already have a saved Site ID for support, then we don't need to request a new ID. if ( ! empty( $site_id ) ) { return; } // If there are no saved API credentials, then we can't use the API to request a Site ID for support. if ( ! $this->get_et_license() ) { return; } $site_id = ''; $send_to_api = array( 'action' => 'get_site_id', ); $settings = array( 'timeout' => 30, 'body' => $send_to_api, ); $request = wp_remote_post( 'https://www.elegantthemes.com/api/token.php', $settings ); if ( ! is_wp_error( $request ) && 200 == wp_remote_retrieve_response_code( $request ) ) { $response = unserialize( wp_remote_retrieve_body( $request ) ); if ( ! empty( $response['site_id'] ) ) { $site_id = esc_attr( $response['site_id'] ); } } update_option( 'et_support_site_id', $site_id ); } /** * Safe Mode temporarily deactivates all plugins *except* those in the allowlist option set here * * @since 3.20 * * @return void */ public function set_safe_mode_plugins_allowlist() { update_option( 'et_safe_mode_plugins_allowlist', $this->safe_mode_plugins_allowlist ); } /** * Add Support Center menu item (but only if it's enabled for current user) * * When initialized we were given an identifier for the plugin or theme doing the initializing. We're going to use * that identifier here to insert the Support Center menu item in the correct location within the WP Admin Menu. * * @since 3.28 Expanded sub-menu links with support for additional ET products. * @since 3.20 */ public function add_admin_menu_item() { // Early exit if the user doesn't have Support Center access if ( ! $this->current_user_can( 'et_support_center' ) ) { return; } $menu_title = esc_html__( 'Support Center', 'et-core' ); $menu_slug = null; $parent_menu_slug = null; // By default, only user with `manage_options` capability which is "administrator" // can see Support Center menu and access the page. $capability = 'manage_options'; // Define parent and child menu slugs switch ( $this->parent ) { case 'bloom_plugin': $menu_slug = 'et_support_center_bloom'; $parent_menu_slug = 'et_bloom_options'; break; case 'monarch_plugin': $menu_title = esc_html__( 'Monarch Support Center', 'et-core' ); $menu_slug = 'et_support_center_monarch'; $parent_menu_slug = 'tools.php'; break; case 'extra_theme': $menu_slug = 'et_support_center_extra'; $parent_menu_slug = 'et_extra_options'; break; case 'divi_theme': case 'divi_builder_plugin': // In the Roles Editor, other user roles may have access to the Support Center. // But, most likely they don't have `manage_options` capability. So, if current // user can't `manage_options`, we will set the submenu capability into the // `edit_theme_options`, so other roles with `edit_theme_options` capability // can access the Support Center. if ( ! current_user_can( 'manage_options' ) ) { $capability = 'edit_theme_options'; } // However, that's not enough. We still need to check whether current user with // `manage_options` or `edit_theme_options` is allowed to access Support Center. if ( ! et_pb_is_allowed( 'support_center' ) ) { return; } $menu_slug = 'et_support_center_divi'; $parent_menu_slug = 'et_divi_options'; } // If there's no menu slug, then this product doesn't have Support Center enabled if ( ! $menu_slug ) { return; } // Build the link add_submenu_page( $parent_menu_slug, $menu_title, $menu_title, $capability, $menu_slug, array( $this, 'add_support_center' ) ); } /** * Add class name to Support Center page * * @since 3.20 * * @param string $admin_classes Current class names for the body tag. * * @return string */ public function add_admin_body_class_name( $admin_classes = '' ) { $classes = explode( ' ', $admin_classes ); $classes[] = 'et-admin-page'; if ( et_core_is_safe_mode_active() ) { $classes[] = 'et-safe-mode-active'; } return implode( ' ', $classes ); } /** * Support Center admin page JS * * @since 3.20 * * @param $hook string Unique identifier for WP admin page. * * @return void */ public function admin_enqueue_scripts_styles( $hook ) { et_core_register_admin_assets(); wp_enqueue_style( 'et-core-admin' ); wp_enqueue_script( 'et-core-admin' ); // Load only on `_et_support_center` pages. if ( strpos( $hook, '_et_support_center' ) ) { // Core Admin CSS wp_enqueue_style( 'et-core', $this->local_path . 'admin/css/core.css', array(), ET_CORE_VERSION ); // ePanel CSS wp_enqueue_style( 'et-wp-admin', $this->local_path . 'admin/css/wp-admin.css', array(), ET_CORE_VERSION ); // Support Center CSS wp_enqueue_style( 'et-support-center', $this->local_path . 'admin/css/support-center.css', array(), ET_CORE_VERSION ); // Support Center uses ePanel controls, so include the necessary scripts if ( function_exists( 'et_core_enqueue_js_admin' ) ) { et_core_enqueue_js_admin(); } } } /** * Support Center frontend CSS/JS * * @since 3.20 * * @param $hook string Unique identifier for WP admin page. * * @return void */ public function enqueue_scripts_styles( $hook ) { // We only need to add this for authenticated users on the frontend if ( ! is_user_logged_in() ) { return; } // Support Center JS wp_enqueue_script( 'et-support-center', $this->local_path . 'admin/js/support-center.js', array( 'jquery', 'underscore' ), ET_CORE_VERSION, true ); $support_center_nonce = wp_create_nonce( 'support_center' ); $etSupportCenterSettings = array( 'ajaxLoaderImg' => esc_url( $this->local_path . 'admin/images/ajax-loader.gif' ), 'ajaxURL' => admin_url( 'admin-ajax.php' ), 'siteURL' => get_site_url(), 'supportCenterURL' => get_admin_url( null, 'admin.php?page=et_support_center#et_card_safe_mode' ), 'nonce' => $support_center_nonce, ); wp_localize_script( 'et-support-center', 'etSupportCenter', $etSupportCenterSettings ); } /** * Divi Support Center :: Card * * Take an array of attributes and build a WP Card block for display on the Divi Support Center page. * * @since 4.4.7 Added optional dismissible button * @since 3.20 * * @param array $attrs * * @return string */ protected function add_support_center_card( $attrs = array( 'title' => '', 'content' => '' ) ) { $card_classes = array( 'card', ); if ( array_key_exists( 'additional_classes', $attrs ) ) { $card_classes = array_merge( $card_classes, $attrs['additional_classes'] ); } $dismiss_button = ''; if ( array_key_exists( 'dismiss_button', $attrs ) ) { // Update card class to indicate the presence of the dismiss button $card_classes = array_merge( $card_classes, array( 'has-dismiss-button' ) ); // Prepare Class for the Dismiss button $dismiss_button_classes = array( 'et-dismiss-button' ); if ( array_key_exists( 'additional_classes', $attrs['dismiss_button'] ) ) { $dismiss_button_classes = array_merge( $dismiss_button_classes, $attrs['dismiss_button']['additional_classes'] ); } // Whether to display tooltip for the dismiss button $dismiss_button_has_tooltip = array_key_exists( 'tooltip', $attrs['dismiss_button'] ); // HTML Template for the dismiss button $dismiss_button = PHP_EOL . "\t" . sprintf( '<button class="%2$s" data-key="%3$s" data-product="%4$s" %5$s type="button" ><span class="et-dismiss-button-label">%1$s</span></button>', esc_html__( 'Dismiss', 'et-core' ), esc_attr( implode( ' ', $dismiss_button_classes ) ), esc_attr( $attrs['dismiss_button']['card_key'] ), esc_attr( $this->parent ), $dismiss_button_has_tooltip ? 'data-tippy-content="' . esc_attr( $attrs['dismiss_button']['tooltip'] ) . '"' : '' ); } $card = PHP_EOL . '<div class="' . esc_attr( implode( ' ', $card_classes ) ) . '">' . PHP_EOL . "\t" . '<h2>' . esc_html( $attrs['title'] ) . '</h2>' . PHP_EOL . "\t" . '<div class="main">' . et_core_intentionally_unescaped( $attrs['content'], 'html' ) . '</div>' . et_core_esc_previously( $dismiss_button ) . PHP_EOL . '</div>'; return $card; } /** * Divi Support Center :: Dismiss a Card via Ajax * * @since 4.4.7 */ public function dismiss_support_center_card_via_ajax() { et_core_security_check( 'manage_options', 'support_center', 'nonce' ); $response = array(); // Check the ET product that dismissing the card $et_product = sanitize_key( $_POST['product'] ); // Confirm that this is a allowlisted product $allowlisted_product = $this->is_allowlisted_product( $et_product ); if ( ! $allowlisted_product ) { // Send a failure code and exit the function header( "HTTP/1.0 403 Forbidden" ); print 'Bad or malformed ET product name.'; wp_die(); } // Check the Card key against Cards that has a dismiss button $card_key = sanitize_key( $_POST['card_key'] ); if ( ! in_array( $card_key, $this->card_with_dismiss_button, true ) ) { // Send a failure code and exit the function header( "HTTP/1.0 403 Forbidden" ); print 'Card does not exists.'; wp_die(); } // Update option(s) update_option( "{$card_key}_dismissed", true ); // For Divi Hosting Card, update the status via ET API if ( $card_key === 'et_hosting_card' ) { $settings = $this->get_et_api_request_settings( 'disable_hosting_card' ); $et_username = et_()->array_get( $settings, 'body.username', '' ); $et_api_key = et_()->array_get( $settings, 'body.api_key', '' ); // Exit if ET Username and/or ET API Key is not found if ( $et_username === '' || $et_api_key === '' ) { return; } et_maybe_update_hosting_card_status(); } $response['message'] = sprintf( esc_html__( 'Card (%1$s) has been dismissed successfully.', 'et-core' ), $card_key ); // `echo` data to return if ( isset( $response ) ) { wp_send_json_success( $response ); } // `die` when we're done wp_die(); } /** * Prepare the "Divi Documentation & Help" video player block * * @since 3.28 Added support for Bloom, Monarch, and Divi Builer plugins. * @since 3.20 * * @param bool $formatted Return either a formatted HTML block (true) or an array (false) * * @return array|string */ protected function get_documentation_video_player( $formatted = true ) { /** * Define the videos list */ switch ( $this->parent ) { case 'extra_theme': $documentation_videos = array( array( 'name' => esc_attr__( 'A Basic Overview Of Extra', 'et-core' ), 'youtube_id' => 'JDSg9eq4LIc', ), array( 'name' => esc_attr__( 'Using Premade Layout Packs', 'et-core' ), 'youtube_id' => '9eqXcrLcnoc', ), array( 'name' => esc_attr__( 'Creating Category Layouts', 'et-core' ), 'youtube_id' => '30SVxnjdnxcE', ), ); break; case 'divi_theme': case 'divi_builder_plugin': $documentation_videos = array( array( 'name' => esc_attr__( 'Getting Started With The Divi Builder', 'et-core' ), 'youtube_id' => 'T-Oe01_J62c', ), array( 'name' => esc_attr__( 'Using Premade Layout Packs', 'et-core' ), 'youtube_id' => '9eqXcrLcnoc', ), array( 'name' => esc_attr__( 'The Divi Library', 'et-core' ), 'youtube_id' => 'boNZZ0MYU0E', ), ); break; case 'bloom_plugin': $documentation_videos = array( array( 'name' => esc_attr__( 'A Basic Overview Of The Bloom Plugin', 'et-core' ), 'youtube_id' => 'E4nfXFjuRRI', ), array( 'name' => esc_attr__( 'How To Update The Bloom Plugin', 'et-core' ), 'youtube_id' => '-IIdkRLskuA', ), array( 'name' => esc_attr__( 'How To Add Mailing List Accounts', 'et-core' ), 'youtube_id' => 'nEdWkHIgQwY', ), ); break; case 'monarch_plugin': $documentation_videos = array( array( 'name' => esc_attr__( 'A Complete Overviw Of Monarch', 'et-core' ), 'youtube_id' => 'RlMUEVkbMrs', ), array( 'name' => esc_attr__( 'Adding Social Networks', 'et-core' ), 'youtube_id' => 'ZabKCiKQJLM', ), array( 'name' => esc_attr__( 'Configuring Social Follower APIs', 'et-core' ), 'youtube_id' => 'vmE8uFhbzos', ), ); break; default: $documentation_videos = array(); } // If we just want the array (not a formatted HTML block), return that now if ( false === $formatted ) { return $documentation_videos; } $videos_list_html = ''; $playlist = array(); foreach ( $documentation_videos as $key => $video ) { $extra = ''; if ( 0 === $key ) { $extra = ' class="active"'; } $videos_list_html .= sprintf( '<li %1$s data-ytid="%2$s">%3$s%4$s</li>', $extra, esc_attr( $video['youtube_id'] ), '<span class="dashicons dashicons-arrow-right"></span>', et_core_intentionally_unescaped( $video['name'], 'fixed_string' ) ); $playlist[] = et_core_intentionally_unescaped( $video['youtube_id'], 'fixed_string' ); } $html = sprintf( '<div class="et_docs_videos">' . '<div class="wrapper"><div id="et_documentation_player" data-playlist="%1$s"></div></div>' . '<ul class="et_documentation_videos_list">%2$s</ul>' . '</div>', esc_attr( implode( ',', $playlist ) ), $videos_list_html ); return $html; } /** * Prepare the "Divi Documentation & Help" articles list * * @since 3.28 Added support for Bloom, Monarch, and Divi Builer plugins. * @since 3.20 * * @param bool $formatted Return either a formatted HTML block (true) or an array (false) * * @return array|string */ protected function get_documentation_articles_list( $formatted = true ) { $articles_list_html = ''; switch ( $this->parent ) { case 'extra_theme': $articles = array( array( 'title' => esc_attr__( 'Getting Started With Extra', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/extra/overview-extra/', ), array( 'title' => esc_attr__( 'Setting Up The Extra Theme Options', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/extra/theme-options-extra/', ), array( 'title' => esc_attr__( 'The Extra Category Builder', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/extra/category-builder/', ), array( 'title' => esc_attr__( 'Getting Started With The Divi Builder', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/visual-builder/', ), array( 'title' => esc_attr__( 'How To Update The Extra Theme', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/update-divi/', ), array( 'title' => esc_attr__( 'An Overview Of All Divi Modules', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/modules/', ), array( 'title' => esc_attr__( 'Getting Started With Layout Packs', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/premade-layouts/', ), array( 'title' => esc_attr__( 'Customizing Your Header And Navigation', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/extra/theme-customizer/', ), ); break; case 'divi_theme': $articles = array( array( 'title' => esc_attr__( 'Getting Started With The Divi Builder', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/visual-builder/', ), array( 'title' => esc_attr__( 'How To Update The Divi Theme', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/update-divi/', ), array( 'title' => esc_attr__( 'An Overview Of All Divi Modules', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/modules/', ), array( 'title' => esc_attr__( 'Using The Divi Library', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/divi-library/', ), array( 'title' => esc_attr__( 'Setting Up The Divi Theme Options', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/theme-options/', ), array( 'title' => esc_attr__( 'Getting Started With Layout Packs', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/premade-layouts/', ), array( 'title' => esc_attr__( 'Customizing Your Header And Navigation', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/customizer-header/', ), array( 'title' => esc_attr__( 'Divi For Developers', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/developers/', ), ); break; case 'divi_builder_plugin': $articles = array( array( 'title' => esc_attr__( 'Getting Started With The Divi Builder', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/visual-builder/', ), array( 'title' => esc_attr__( 'How To Update The Divi Builder', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi-builder/update-divi-builder/', ), array( 'title' => esc_attr__( 'An Overview Of All Divi Modules', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/modules/', ), array( 'title' => esc_attr__( 'Using The Divi Library', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/divi-library/', ), array( 'title' => esc_attr__( 'Selling Products With Divi And WooCommerce', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/ecommerce-divi/', ), array( 'title' => esc_attr__( 'Getting Started With Layout Packs', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/premade-layouts/', ), array( 'title' => esc_attr__( 'Importing And Exporting Divi Layouts', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/divi/library-import/', ), array( 'title' => esc_attr__( 'Divi For Developers', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/developers/', ), ); break; case 'bloom_plugin': $articles = array( array( 'title' => esc_attr__( 'A Basic Overview Of The Bloom Plugin', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/overview/', ), array( 'title' => esc_attr__( 'How To Update Your Bloom Plugin', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/update/', ), array( 'title' => esc_attr__( 'Adding Email Accounts In Bloom', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/accounts/', ), array( 'title' => esc_attr__( 'Customizing Your Opt-in Designs', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/design/', ), array( 'title' => esc_attr__( 'The Different Bloom Opt-in Types', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/optin-types/', ), array( 'title' => esc_attr__( 'Using The Bloom Display Settings', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/display/', ), array( 'title' => esc_attr__( 'How To Use Triggers In Bloom', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/triggers/', ), array( 'title' => esc_attr__( 'Adding Custom Fields To Bloom Opt-in Forms', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/bloom/optin/adding-custom-fields-to-bloom-optin-forms/', ), ); break; case 'monarch_plugin': $articles = array( array( 'title' => esc_attr__( 'A Complete Overview Of The Monarch Plugin', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/overview-monarch/', ), array( 'title' => esc_attr__( 'How To Update Your Monarch WordPress Plugin', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/update-monarch/', ), array( 'title' => esc_attr__( 'Adding and Managing Social Networks', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/networks/', ), array( 'title' => esc_attr__( 'Configuring Social Network APIs', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/api/', ), array( 'title' => esc_attr__( 'Customizing The Monarch Design', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/design-monarch/', ), array( 'title' => esc_attr__( 'Viewing Your Social Stats', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/stats/', ), array( 'title' => esc_attr__( 'Using The Floating Sidebar', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/sidebar/', ), array( 'title' => esc_attr__( 'Using Popup & Flyin Triggers', 'et-core' ), 'url' => 'https://www.elegantthemes.com/documentation/monarch/triggers-monarch/', ), ); break; default: $articles = array(); } // If we just want the array (not a formatted HTML block), return that now if ( false === $formatted ) { return $articles; } foreach ( $articles as $key => $article ) { $articles_list_html .= sprintf( '<li class="et-support-center-article"><a href="%1$s" target="_blank">%2$s</a></li>', esc_url( $article['url'] ), et_core_intentionally_unescaped( $article['title'], 'fixed_string' ) ); } $html = sprintf( '<div class="et_docs_articles"><ul class="et_documentation_articles_list">%1$s</ul></div>', $articles_list_html ); return $html; } /** * Look for Elegant Themes Support Account * * @since 3.20 * * @return WP_User|false WP_User object on success, false on failure. */ public function get_et_support_user() { return get_user_by( 'slug', $this->support_user_account_name ); } /** * Look for saved Elegant Themes Username & API Key * * @since 3.20 * * @return array|false license credentials on success, false on failure. */ public function get_et_license() { /** @var array License credentials [username|api_key] */ if ( ! $et_license = get_site_option( 'et_automatic_updates_options' ) ) { $et_license = get_option( 'et_automatic_updates_options', array() ); } if ( ! et_()->array_get( $et_license, 'username' ) ) { return false; } if ( ! et_()->array_get( $et_license, 'api_key' ) ) { return false; } return $et_license; } /** * Try to load the WP debug log. If found, return the last [$lines_to_return] lines of the file and the filesize. * * @since 3.20 * * @param int $lines_to_return Number of lines to read and return from the end of the wp_debug.log file. * * @return array */ protected function get_wp_debug_log( $lines_to_return = 10 ) { $log = array( 'entries' => '', 'size' => 0, ); // Early exit: internal PHP function `file_get_contents()` appears to be on lockdown if ( ! function_exists( 'file_get_contents' ) ) { $log['error'] = esc_attr__( 'Divi Support Center :: WordPress debug log cannot be read.', 'et-core' ); if ( defined( 'ET_DEBUG' ) ) { et_error( $log['error'] ); } return $log; } // Early exit: WP_DEBUG_LOG isn't defined in wp-config.php (or it's defined, but it's empty) if ( ! defined( 'WP_DEBUG_LOG' ) || ! WP_DEBUG_LOG ) { $log['error'] = esc_attr__( 'Divi Support Center :: WordPress debug.log is not configured.', 'et-core' ); if ( defined( 'ET_DEBUG' ) ) { et_error( $log['error'] ); } return $log; } /** * WordPress 5.1 introduces the option to define a custom path for the WP_DEBUG_LOG file. * * @see wp_debug_mode() * * @since 3.20 */ if ( in_array( strtolower( (string) WP_DEBUG_LOG ), array( 'true', '1' ), true ) ) { $wp_debug_log_path = realpath( WP_CONTENT_DIR . '/debug.log' ); } else if ( is_string( WP_DEBUG_LOG ) ) { $wp_debug_log_path = realpath( WP_DEBUG_LOG ); } // Early exit: `debug.log` doesn't exist or otherwise can't be read if ( ! isset( $wp_debug_log_path ) || ! file_exists( $wp_debug_log_path ) || ! is_readable( $wp_debug_log_path ) ) { $log['error'] = esc_attr__( 'Divi Support Center :: WordPress debug log cannot be found.', 'et-core' ); if ( defined( 'ET_DEBUG' ) ) { et_error( $log['error'] ); } return $log; } /** * At this point, we know: * (1) `$wp_debug_log_path` is set, * (2) it points to a valid location, and * (3) what it points to is readable. * * Before we continue, we'll ensure `$wp_debug_log_path` does not point to a directory. */ // Early exit: debug log definition points to a directory, not a file. if ( is_dir( $wp_debug_log_path ) ) { $log['error'] = esc_attr__( 'Divi Support Center :: WordPress debug log setting points to a directory, but should point to a file.', 'et-core' ); if ( defined( 'ET_DEBUG' ) ) { et_error( $log['error'] ); } return $log; } // Load the debug.log file $file = new SplFileObject( $wp_debug_log_path ); // Get the filesize of debug.log $log['size'] = $this->get_size_in_shorthand( 0 + $file->getSize() ); // If $lines_to_return is a positive integer, fetch the last [$lines_to_return] lines of the log file $lines_to_return = (int) $lines_to_return; if ( $lines_to_return > 0 ) { $file->seek( PHP_INT_MAX ); $total_lines = $file->key(); // If the file is smaller than the number of lines requested, return the entire file. $reader = new LimitIterator( $file, max( 0, $total_lines - $lines_to_return ) ); $log['entries'] = ''; foreach ( $reader as $line ) { $log['entries'] .= $line; } } // Unload the SplFileObject $file = null; return $log; } /** * When a predefined system setting is passed to this function, it will return the observed value. * * @since 3.20 * * @param bool $formatted Whether to return a formatted report or just the data array * @param string $format Return the report as either a `div` or `plain` text (if $formatted = true) * * @return array|string */ protected function system_diagnostics_generate_report( $formatted = true, $format = 'plain' ) { /** @var array Collection of system settings to run diagnostic checks on. */ global $wp_version; global $shortname; $divi_builder_plugin_active = et_is_builder_plugin_active(); if ( $divi_builder_plugin_active ) { $options = get_option( 'et_pb_builder_options', array() ); } if ( 'divi' === $shortname ) { $performance_options_url = get_admin_url() . 'admin.php?page=et_divi_options#general-2'; $builder_options_url = get_admin_url() . 'admin.php?page=et_divi_options#builder-2'; } elseif ( 'extra' === $shortname ) { $performance_options_url = get_admin_url() . 'admin.php?page=et_extra_options#general-2'; $builder_options_url = get_admin_url() . 'admin.php?page=et_extra_options#builder-2'; } else { $performance_options_url = get_admin_url() . 'admin.php?page=et_divi_options#tab_et_dashboard_tab_content_performance_main'; $builder_options_url = get_admin_url() . 'admin.php?page=et_divi_options#tab_et_dashboard_tab_content_advanced_main'; } $system_diagnostics_settings = array( array( 'name' => esc_attr__( 'Writable wp-content Directory', 'et-core' ), 'environment' => 'server', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'minimum' => null, 'recommended' => true, 'actual' => wp_is_writable( WP_CONTENT_DIR ), 'help_text' => et_core_intentionally_unescaped( __( 'We recommend that the wp-content directory on your server be writable by WordPress in order to ensure the full functionality of Divi Builder themes and plugins.', 'et-core' ), 'html' ), 'learn_more' => 'https://wordpress.org/support/article/changing-file-permissions/', ), array( 'name' => esc_attr__( 'Writable et-cache Directory', 'et-core' ), 'environment' => 'server', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'minimum' => null, 'recommended' => true, 'actual' => wp_is_writable( WP_CONTENT_DIR . '/et-cache' ), 'help_text' => et_core_intentionally_unescaped( __( 'We recommend that the et-cache directory on your server be writable by WordPress in order to ensure the full functionality of Divi Builder themes and plugins.', 'et-core' ), 'html' ), 'learn_more' => 'https://wordpress.org/support/article/changing-file-permissions/', ), array( 'name' => esc_attr__( 'PHP: Version', 'et-core' ), 'environment' => 'server', 'type' => 'version', 'pass_minus_one' => false, 'pass_zero' => false, 'minimum' => null, 'recommended' => '7.4 or higher', 'actual' => (float) phpversion(), 'help_text' => et_core_intentionally_unescaped( __( 'We recommend using the latest stable version of PHP. This will not only ensure compatibility with Divi, but it will also greatly speed up your website leading to less memory and CPU related issues.', 'et-core' ), 'html' ), 'learn_more' => 'http://php.net/releases/', ), array( 'name' => esc_attr__( 'WordPress Version', 'et-core' ), 'environment' => 'server', 'type' => 'version', 'pass_minus_one' => false, 'pass_zero' => false, 'minimum' => null, 'recommended' => '5.3 or higher', 'actual' => $wp_version, 'help_text' => et_core_intentionally_unescaped( __( 'We recommend using the latest stable version of WordPress. This will not only ensure compatibility with Divi, but it will also greatly speed up your website leading to less memory and CPU related issues.', 'et-core' ), 'html' ), 'learn_more' => 'https://wordpress.org/download/releases/', ), array( 'name' => esc_attr__( 'PHP: memory_limit', 'et-core' ), 'environment' => 'server', 'type' => 'size', 'pass_minus_one' => true, 'pass_zero' => false, 'minimum' => null, 'recommended' => '128M', 'actual' => ini_get( 'memory_limit' ), 'help_text' => et_get_safe_localization( sprintf( __( 'By default, memory limits set by your host or by WordPress may be too low. This will lead to applications crashing as PHP reaches the artificial limit. You can adjust your memory limit within your <a href="%1$s" target="_blank">php.ini file</a>, or by contacting your host for assistance. You may also need to define a memory limited in <a href="%2$s" target=_blank">wp-config.php</a>.', 'et-core' ), 'http://php.net/manual/en/ini.core.php#ini.memory-limit', 'https://codex.wordpress.org/Editing_wp-config.php' ) ), 'learn_more' => 'http://php.net/manual/en/ini.core.php#ini.memory-limit', ), array( 'name' => esc_attr__( 'PHP: post_max_size', 'et-core' ), 'environment' => 'server', 'type' => 'size', 'pass_minus_one' => false, 'pass_zero' => true, 'minimum' => null, 'recommended' => '64M', 'actual' => ini_get( 'post_max_size' ), 'help_text' => et_get_safe_localization( sprintf( __( 'Post Max Size limits how large a page or file can be on your website. If your page is larger than the limit set in PHP, it will fail to load. Post sizes can become quite large when using the Divi Builder, so it is important to increase this limit. It also affects file size upload/download, which can prevent large layouts from being imported into the builder. You can adjust your max post size within your <a href="%1$s" target="_blank">php.ini file</a>, or by contacting your host for assistance.', 'et_core' ), 'http://php.net/manual/en/ini.core.php#ini.post-max-size' ) ), 'learn_more' => 'http://php.net/manual/en/ini.core.php#ini.post-max-size', ), array( 'name' => esc_attr__( 'PHP: max_execution_time', 'et-core' ), 'environment' => 'server', 'type' => 'seconds', 'pass_minus_one' => false, 'pass_zero' => true, 'minimum' => null, 'recommended' => '120', 'actual' => ini_get( 'max_execution_time' ), 'help_text' => et_get_safe_localization( sprintf( __( 'Max Execution Time affects how long a page is allowed to load before it times out. If the limit is too low, you may not be able to import large layouts and files into the builder. You can adjust your max execution time within your <a href="%1$s">php.ini file</a>, or by contacting your host for assistance.', 'et-core' ), 'http://php.net/manual/en/info.configuration.php#ini.max-execution-time' ) ), 'learn_more' => 'http://php.net/manual/en/info.configuration.php#ini.max-execution-time', ), array( 'name' => esc_attr__( 'PHP: upload_max_filesize', 'et-core' ), 'environment' => 'server', 'type' => 'size', 'pass_minus_one' => false, 'pass_zero' => true, 'minimum' => null, 'recommended' => '64M', 'actual' => ini_get( 'upload_max_filesize' ), 'help_text' => et_get_safe_localization( sprintf( __( 'Upload Max File Size determines that maximum file size that you are allowed to upload to your server. If the limit is too low, you may not be able to import large collections of layouts into the Divi Library. You can adjust your max file size within your <a href="%1$s" target="_blank">php.ini file</a>, or by contacting your host for assistance.', 'et-core' ), 'http://php.net/manual/en/ini.core.php#ini.upload-max-filesize' ) ), 'learn_more' => 'http://php.net/manual/en/ini.core.php#ini.upload-max-filesize', ), array( 'name' => esc_attr__( 'PHP: max_input_time', 'et-core' ), 'environment' => 'server', 'type' => 'seconds', 'pass_minus_one' => true, 'pass_zero' => true, 'minimum' => null, 'recommended' => '60', 'actual' => ini_get( 'max_input_time' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This sets the maximum time in seconds a script is allowed to parse input data. If the limit is too low, the Divi Builder may time out before it is allowed to load. You can adjust your max input time within your <a href="%1$s" target="_blank">php.ini file</a>, or by contacting your host for assistance.', 'et-core' ), 'http://php.net/manual/en/info.configuration.php#ini.max-input-time' ) ), 'learn_more' => 'http://php.net/manual/en/info.configuration.php#ini.max-input-time', ), array( 'name' => esc_attr__( 'PHP: max_input_vars', 'et-core' ), 'environment' => 'server', 'type' => 'size', 'pass_minus_one' => false, 'pass_zero' => false, 'minimum' => null, 'recommended' => '1000', 'actual' => ini_get( 'max_input_vars' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This setting affects how many input variables may be accepted. If the limit is too low, it may prevent the Divi Builder from loading. You can adjust your max input variables within your <a href="%1$s" target="_blank">php.ini file</a>, or by contacting your host for assistance.', 'et-core' ), 'http://php.net/manual/en/info.configuration.php#ini.max-input-vars' ) ), 'learn_more' => 'http://php.net/manual/en/info.configuration.php#ini.max-input-vars', ), array( 'name' => esc_attr__( 'PHP: display_errors', 'et-core' ), 'environment' => 'server', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'pass_exact' => null, 'minimum' => null, 'recommended' => '0', 'actual' => ! ini_get( 'display_errors' ) ? '0' : ini_get( 'display_errors' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This setting determines whether or not errors should be printed as part of the page output. This is a feature to support your site\'s development and should never be used on production sites. You can edit this setting within your <a href="%1$s" target="_blank">php.ini file</a>, or by contacting your host for assistance.', 'et-core' ), 'http://php.net/manual/en/errorfunc.configuration.php#ini.display-errors' ) ), 'learn_more' => 'http://php.net/manual/en/errorfunc.configuration.php#ini.display-errors', ), array( 'name' => esc_attr__( 'Dynamic CSS', 'et-core' ), 'environment' => 'performance', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'pass_exact' => null, 'minimum' => null, 'recommended' => 'on', 'actual' => $divi_builder_plugin_active ? ( isset( $options['performance_main_dynamic_css'] ) ? $options['performance_main_dynamic_css'] : 'on' ) : et_get_option( $shortname . '_dynamic_css', 'on' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This is a very important performance setting that should be turned on. Dynamic CSS greatly reduces your website\'s CSS size, speeds up page load times and improves Google PageSpeed scores. You can turn this setting on in the <a href="%1$s" target="_blank">Theme Options</a>.', 'et-core' ), $performance_options_url ) ), 'learn_more' => $performance_options_url, ), array( 'name' => esc_attr__( 'Dynamic Framework', 'et-core' ), 'environment' => 'performance', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'pass_exact' => null, 'minimum' => null, 'recommended' => 'on', 'actual' => $divi_builder_plugin_active ? ( isset( $options['performance_main_dynamic_module_framework'] ) ? $options['performance_main_dynamic_module_framework'] : 'on' ) : et_get_option( $shortname . '_dynamic_module_framework', 'on' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This is a very important performance setting that should be turned on. The Dynamic Framework removes bloat from the back-end. This greatly reduces CPU and Memory usage and improves website speed. You can turn this setting on in the <a href="%1$s" target="_blank">Theme Options</a>.', 'et-core' ), $performance_options_url ) ), 'learn_more' => $performance_options_url, ), array( 'name' => esc_attr__( 'Dynamic JavaScript', 'et-core' ), 'environment' => 'performance', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'pass_exact' => null, 'minimum' => null, 'recommended' => 'on', 'actual' => $divi_builder_plugin_active ? ( isset( $options['performance_main_dynamic_css'] ) ? $options['performance_main_dynamic_css'] : 'on' ) : et_get_option( $shortname . '_dynamic_js_libraries', 'on' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This is a very important performance setting that should be turned on. Dynamic JavaScript removes unused scripts and improves website speed by loading JavaScript files only when they are needed. You can turn this setting on in the <a href="%1$s" target="_blank">Theme Options</a>.', 'et-core' ), $performance_options_url ) ), 'learn_more' => $performance_options_url, ), array( 'name' => esc_attr__( 'Critical CSS', 'et-core' ), 'environment' => 'performance', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'pass_exact' => null, 'minimum' => null, 'recommended' => 'on', 'actual' => $divi_builder_plugin_active ? ( isset( $options['performance_main_critical_css'] ) ? $options['performance_main_dynamic_css'] : 'on' ) : et_get_option( $shortname . '_critical_css', 'on' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This is a very important performance setting that should be turned on. Critical CSS greatly improves website loading speeds by deferring "below the fold" styles and removing render blocking requests for critical styles. You can turn this setting on in the <a href="%1$s" target="_blank">Theme Options</a>.', 'et-core' ), $performance_options_url ) ), 'learn_more' => $performance_options_url, ), array( 'name' => esc_attr__( 'Static CSS', 'et-core' ), 'environment' => 'performance', 'type' => 'truthy_falsy', 'pass_minus_one' => null, 'pass_zero' => null, 'pass_exact' => null, 'minimum' => null, 'recommended' => 'on', 'actual' => et_get_option( 'et_pb_static_css_file', 'on' ), 'help_text' => et_get_safe_localization( sprintf( __( 'This is a very important performance setting that should be turned on, even if you are using a caching plugin. Static CSS caches the builder CSS for each page so that it doesn\'t need to be processed on every page load. Even if you are using a caching plugin, this setting should still be turned on so that dynamic pages benefit. You can turn this setting on in the <a href="%1$s" target="_blank">Theme Options</a>.', 'et-core' ), $builder_options_url ) ), 'learn_more' => $builder_options_url, ), ); /** @var string Formatted report. */ $report = ''; // pass/fail Should be one of pass|minimal|fail|unknown. Defaults to 'unknown'. foreach ( $system_diagnostics_settings as $i => $scan ) { /** * 'pass_fail': four-step process to set its value: * - begin with `unknown` state; * - if recommended value exists, change to `fail`; * - if minimum value exists, compare against it & change to `minimal` if it passes; * - compare against recommended value & change to `pass` if it passes. */ $system_diagnostics_settings[ $i ]['pass_fail'] = 'unknown'; if ( ! is_null( $scan['recommended'] ) ) { $system_diagnostics_settings[ $i ]['pass_fail'] = 'fail'; } if ( ! is_null( $scan['minimum'] ) && $this->value_is_at_least( $scan['minimum'], $scan['actual'], $scan['type'] ) ) { $system_diagnostics_settings[ $i ]['pass_fail'] = 'minimal'; } if ( empty( $scan['pass_exact'] ) && ! is_null( $scan['recommended'] ) && $this->value_is_at_least( $scan['recommended'], $scan['actual'], $scan['type'] ) ) { $system_diagnostics_settings[ $i ]['pass_fail'] = 'pass'; } if ( $scan['pass_minus_one'] && -1 === (int) $scan['actual'] ) { $system_diagnostics_settings[ $i ]['pass_fail'] = 'pass'; } if ( $scan['pass_zero'] && 0 === (int) $scan['actual'] ) { $system_diagnostics_settings[ $i ]['pass_fail'] = 'pass'; } if ( ! empty( $scan['pass_exact'] ) && $scan['recommended'] === $scan['actual'] ) { $system_diagnostics_settings[ $i ]['pass_fail'] = 'pass'; } /** * Build messaging for minimum required values */ $message_minimum = ''; if ( ! is_null( $scan['minimum'] ) && 'fail' === $system_diagnostics_settings[ $i ]['pass_fail'] ) { $message_minimum = sprintf( esc_html__( 'This fails to meet our minimum required value of %1$s. ', 'et-core' ), esc_html( is_bool( $scan['minimum'] ) ? $this->boolean_label[ $scan['minimum'] ] : $scan['minimum'] ) ); } if ( ! is_null( $scan['minimum'] ) && 'minimal' === $system_diagnostics_settings[ $i ]['pass_fail'] ) { $message_minimum = sprintf( esc_html__( 'This meets our minimum required value of %1$s. ', 'et-core' ), esc_html( is_bool( $scan['minimum'] ) ? $this->boolean_label[ $scan['minimum'] ] : $scan['minimum'] ) ); } /** * Build description messaging for results & recommendation */ $learn_more_link = ''; if ( ! is_null( $scan['learn_more'] ) ) { $learn_more_link = sprintf( ' <a href="%1$s" target="_blank">%2$s</a>', esc_url( $scan['learn_more'] ), esc_html__( 'server' === $scan['environment'] ? 'Learn More.' : 'Enable Option.', 'et-core' ) ); } switch ( $system_diagnostics_settings[ $i ]['pass_fail'] ) { case 'pass': $system_diagnostics_settings[ $i ]['description'] = sprintf( '- %1$s %2$s', sprintf( esc_html__( 'performance' === $scan['environment'] ? 'Perfect! We recommend enabling this option.' : 'Congratulations! This meets or exceeds our recommendation of %1$s.', 'et-core' ), esc_html( is_bool( $scan['recommended'] ) ? $this->boolean_label[ $scan['recommended'] ] : $scan['recommended'] ) ), et_core_intentionally_unescaped( $learn_more_link, 'html' ) ); break; case 'minimal': case 'fail': $system_diagnostics_settings[ $i ]['description'] = sprintf( '- %1$s%2$s %3$s', esc_html( $message_minimum ), sprintf( esc_html__( 'performance' === $scan['environment'] ? 'Enable for optimal performance.' : 'We recommend %1$s for the best experience.', 'et-core' ), esc_html( is_bool( $scan['recommended'] ) ? $this->boolean_label[ $scan['recommended'] ] : $scan['recommended'] ) ), et_core_intentionally_unescaped( $learn_more_link, 'html' ) ); break; case 'unknown': default: $system_diagnostics_settings[ $i ]['description'] = sprintf( esc_html__( '- We are unable to determine your setting. %1$s', 'et-core' ), et_core_intentionally_unescaped( $learn_more_link, 'html' ) ); } } // If we just want the array (not a formatted HTML block), return that now if ( false === $formatted ) { return $system_diagnostics_settings; } foreach ( $system_diagnostics_settings as $item ) { // Add reported setting to plaintext report: if ( 'plain' === $format ) { switch ( $item['pass_fail'] ) { case 'pass': $status = ' '; break; case 'minimal': $status = '~ '; break; case 'fail': $status = "! "; break; case 'unknown': default: $status = '? '; } $report .= $status . $item['name'] . PHP_EOL . ' ' . $item['actual'] . PHP_EOL . PHP_EOL; } // Add reported setting to table: if ( 'div' === $format ) { $help_text = ''; if ( ! is_null( $item['help_text'] ) ) { $help_text = $item['help_text']; } $report .= sprintf( '<div class="et-epanel-box et_system_status_row et_system_status_%1$s"> <div class="et-box-title setting"> <h3>%2$s</h3> <div class="et-box-descr"><p>%3$s</p></div> </div> <div class="et-box-content results"> <span class="actual">%4$s</span> <span class="description">%5$s</span> </div> <span class="et-box-description"></span> </div>', esc_attr( $item['pass_fail'] ), esc_html( $item['name'] ), et_core_intentionally_unescaped( $help_text, 'html' ), esc_html( is_bool( $item['actual'] ) ? $this->boolean_label[ $item['actual'] ] : $item['actual'] ), et_core_intentionally_unescaped( $item['description'], 'html' ) ); } } // Prepend title and timestamp if ( 'plain' === $format ) { $report = '## ' . esc_html__( 'System Status', 'et-core' ) . ' ##' . PHP_EOL . ':: ' . date( 'Y-m-d @ H:i:s e' ) . PHP_EOL . PHP_EOL . $report; } if ( 'div' === $format ) { $report = sprintf( '<div class="%3$s-report">%1$s</div><p class="%3$s-congratulations">%2$s</p>', $report, esc_html__( 'Congratulations, all system checks have passed. Your hosting configuration is compatible with Divi.', 'et-core' ), 'et-system-status' ); } return $report; } /** * Convert size string with "shorthand byte" notation to raw byte value for comparisons. * * @since 3.20 * * @param string $size * * @return int size in bytes */ protected function get_size_in_bytes( $size = '' ) { // Capture the denomination and convert to uppercase, then do math to it switch ( strtoupper( substr( $size, -1 ) ) ) { // Terabytes case 'T': return (int) $size * 1099511627776; // Gigabytes case 'G': return (int) $size * 1073741824; // Megabytes case 'M': return (int) $size * 1048576; // Kilobytes case 'K': return (int) $size * 1024; default: return (int) $size; } } /** * Convert size string with "shorthand byte" notation to raw byte value for comparisons. * * @since 3.20 * * @param int $bytes * @param int $precision * * @return string size in "shorthand byte" notation */ protected function get_size_in_shorthand( $bytes = 0, $precision = 2 ) { $units = array( ' bytes', 'KB', 'MB', 'GB', 'TB' ); $i = 0; while ( $bytes > 1024 ) { $bytes /= 1024; $i++; } return round( $bytes, $precision ) . $units[ $i ]; } /** * Size comparisons between two values using a variety of calculation methods. * * @since 3.20.2 * * @param string|int|float $a Our value to compare against * @param string|int|float $b Server value being compared * @param string $type Comparison type * * @return bool Whether the second value is equal to or greater than the first */ protected function value_is_at_least( $a, $b, $type = 'size' ) { switch ( $type ) { case 'truthy_falsy': return $this->value_is_falsy( $a ) === $this->value_is_falsy( $b ); case 'version': return (float) $a <= (float) $b; case 'seconds': return (int) $a <= (int) $b; case 'size': default: return $this->get_size_in_bytes( $a ) <= $this->get_size_in_bytes( $b ); } } /** * Check value against a collection of "falsy" values * * @since 3.23 * * @param string|int|float $a Value to compare against * * @return bool Whether the second value is equal to or greater than the first */ protected function value_is_falsy( $a ) { // Accept falsy strings regardless of case (e.g. 'off', 'Off', 'OFF', 'oFf') if ( is_string( $a ) ) { $a = strtolower( $a ); } return in_array( $a, array( false, 'false', 0, '0', 'off' ), true ); } /** * SUPPORT CENTER :: REMOTE ACCESS */ /** * Add Support Center options to the Role Editor screen * * @see ET_Core_SupportCenter::current_user_can() * * @since 3.20 * * @param $all_role_options * * @return array */ public function support_user_add_role_options( $all_role_options ) { // get all the roles that can edit theme options. $applicability_roles = et_core_get_roles_by_capabilities( [ 'edit_theme_options' ] ); $all_role_options['support_center'] = array( 'section_title' => esc_attr__( 'Support Center', 'et-core' ), 'applicability' => $applicability_roles, 'options' => array( 'et_support_center' => array( 'name' => esc_attr__( 'Divi Support Center Page', 'et-core' ), ), 'et_support_center_system' => array( 'name' => esc_attr__( 'System Status', 'et-core' ), ), 'et_support_center_remote_access' => array( 'name' => esc_attr__( 'Remote Access', 'et-core' ), ), 'et_support_center_documentation' => array( 'name' => esc_attr__( 'Divi Documentation & Help', 'et-core' ), ), 'et_support_center_safe_mode' => array( 'name' => esc_attr__( 'Safe Mode', 'et-core' ), ), 'et_support_center_logs' => array( 'name' => esc_attr__( 'Logs', 'et-core' ), ), ), ); return $all_role_options; } /** * Add third party capabilities to Remote Access roles * * @return array Capabilities to add to the Remote Access user roles. */ public function support_user_extra_caps_standard( $extra_capabilities = array() ) { // The Events Calendar (if active on the site) if ( class_exists( 'Tribe__Events__Main' ) ) { $the_events_calendar = array( // Events 'edit_tribe_event' => 1, 'read_tribe_event' => 1, 'delete_tribe_event' => 1, 'delete_tribe_events' => 1, 'edit_tribe_events' => 1, 'edit_others_tribe_events' => 1, 'delete_others_tribe_events' => 1, 'publish_tribe_events' => 1, 'edit_published_tribe_events' => 1, 'delete_published_tribe_events' => 1, 'delete_private_tribe_events' => 1, 'edit_private_tribe_events' => 1, 'read_private_tribe_events' => 1, // Venues 'edit_tribe_venue' => 1, 'read_tribe_venue' => 1, 'delete_tribe_venue' => 1, 'delete_tribe_venues' => 1, 'edit_tribe_venues' => 1, 'edit_others_tribe_venues' => 1, 'delete_others_tribe_venues' => 1, 'publish_tribe_venues' => 1, 'edit_published_tribe_venues' => 1, 'delete_published_tribe_venues' => 1, 'delete_private_tribe_venues' => 1, 'edit_private_tribe_venues' => 1, 'read_private_tribe_venues' => 1, // Organizers 'edit_tribe_organizer' => 1, 'read_tribe_organizer' => 1, 'delete_tribe_organizer' => 1, 'delete_tribe_organizers' => 1, 'edit_tribe_organizers' => 1, 'edit_others_tribe_organizers' => 1, 'delete_others_tribe_organizers' => 1, 'publish_tribe_organizers' => 1, 'edit_published_tribe_organizers' => 1, 'delete_published_tribe_organizers' => 1, 'delete_private_tribe_organizers' => 1, 'edit_private_tribe_organizers' => 1, 'read_private_tribe_organizers' => 1, ); $extra_capabilities = array_merge( $extra_capabilities, $the_events_calendar ); } return $extra_capabilities; } /** * Add third party capabilities to the *Elevated* Remote Access role only * * @return array Capabilities to add to the Elevated Remote Access user role. */ public function support_user_extra_caps_elevated() { $extra_capabilities = array(); return $extra_capabilities; } /** * Create the Divi Support user (if it doesn't already exist) * * @since 3.20 * * @return void|WP_Error */ public function support_user_maybe_create_user() { if ( username_exists( $this->support_user_account_name ) ) { return; } // Define user roles that will be used to control ET Support User permissions $this->support_user_create_roles(); $token = $this->support_user_generate_token(); $password = $this->support_user_generate_password( $token ); if ( is_wp_error( $password ) ) { return $password; } $user_id = wp_insert_user( array( 'user_login' => $this->support_user_account_name, 'user_pass' => $password, 'first_name' => 'Elegant Themes', 'last_name' => 'Support', 'display_name' => 'Elegant Themes Support', 'role' => 'et_support', ) ); if ( is_wp_error( $user_id ) ) { return $user_id; } $account_settings = array( 'date_created' => time(), 'token' => $token, ); update_option( $this->support_user_options_name, $account_settings ); // update options variable $this->support_user_get_options(); $this->support_user_init_cron_delete_account(); } /** * Define both Standard and Elevated roles for the Divi Support user * * @since 3.22 Added filters to extend the list of capabilities for the ET Support User * @since 3.20 */ public function support_user_create_roles() { // Make sure old versions of these roles do not exist $this->support_user_remove_roles(); // Divi Support :: Standard $standard_capabilities = array( 'assign_product_terms' => true, 'delete_pages' => true, 'delete_posts' => true, 'delete_private_pages' => true, 'delete_private_posts' => true, 'delete_private_products' => true, 'delete_product' => true, 'delete_product_terms' => true, 'delete_products' => true, 'delete_published_pages' => true, 'delete_published_posts' => true, 'delete_published_products' => true, 'edit_dashboard' => true, 'edit_files' => true, 'edit_others_pages' => true, 'edit_others_posts' => true, 'edit_others_products' => true, 'edit_pages' => true, 'edit_posts' => true, 'edit_private_pages' => true, 'edit_private_posts' => true, 'edit_private_products' => true, 'edit_product' => true, 'edit_product_terms' => true, 'edit_products' => true, 'edit_published_pages' => true, 'edit_published_posts' => true, 'edit_published_products' => true, 'edit_theme_options' => true, 'list_users' => true, 'manage_categories' => true, 'manage_links' => true, 'manage_options' => true, 'manage_product_terms' => true, 'moderate_comments' => true, 'publish_pages' => true, 'publish_posts' => true, 'publish_products' => true, 'read' => true, 'read_private_pages' => true, 'read_private_posts' => true, 'read_private_products' => true, 'read_product' => true, 'unfiltered_html' => true, 'upload_files' => true, // Divi 'ab_testing' => true, 'add_library' => true, 'disable_module' => true, 'divi_builder_control' => true, 'divi_ai' => true, 'divi_library' => true, 'edit_borders' => true, 'edit_buttons' => true, 'edit_colors' => true, 'edit_configuration' => true, 'edit_content' => true, 'edit_global_library' => true, 'edit_layout' => true, 'export' => true, 'lock_module' => true, 'page_options' => true, 'portability' => true, 'read_dynamic_content_custom_fields' => true, 'save_library' => true, 'use_visual_builder' => true, 'theme_builder' => true, // WooCommerce Capabilities 'manage_woocommerce' => true, ); // Divi Support :: Elevated $elevated_capabilities = array_merge( $standard_capabilities, array( 'activate_plugins' => true, 'delete_plugins' => true, 'delete_themes' => true, 'edit_plugins' => true, 'edit_themes' => true, 'install_plugins' => true, 'install_themes' => true, 'switch_themes' => true, 'update_plugins' => true, 'update_themes' => true, ) ); // Filters to allow other code to extend the list of capabilities $additional_standard = apply_filters( 'add_et_support_standard_capabilities', array() ); $additional_elevated = apply_filters( 'add_et_support_elevated_capabilities', array() ); // Apply filter capabilities to our definitions $standard_capabilities = array_merge( $additional_standard, $standard_capabilities ); // Just like Elevated gets all of Standard's capabilities, it also inherits Standard's filter caps $elevated_capabilities = array_merge( $additional_standard, $additional_elevated, $elevated_capabilities ); // Create the standard ET Support role add_role( 'et_support', 'ET Support', $standard_capabilities ); $et_support_role = get_role( 'et_support' ); foreach ( $standard_capabilities as $cap ) { $et_support_role->add_cap( $cap ); } // Create the elevated ET Support role add_role( 'et_support_elevated', 'ET Support - Elevated', $elevated_capabilities ); $et_support_elevated_role = get_role( 'et_support_elevated' ); foreach ( $elevated_capabilities as $cap ) { $et_support_elevated_role->add_cap( $cap ); } } /** * Remove our Standard and Elevated Support roles * * @since 3.20 */ public function support_user_remove_roles() { // Divi Support :: Standard remove_role( 'et_support' ); // Divi Support :: Elevated remove_role( 'et_support_elevated' ); } /** * Set the ET Support User's role * * @since 3.20 * * @param string $role */ public function support_user_set_role( $role = '' ) { // Get the Divi Support User object $support_user = new WP_User( $this->support_user_account_name ); // Set the new Role switch ( $role ) { case 'et_support': $support_user->set_role( 'et_support' ); break; case 'et_support_elevated': $support_user->set_role( 'et_support_elevated' ); break; case '': default: $support_user->set_role( '' ); } } /** * Ensure the `unfiltered_html` capability is added to the ET Support roles in Multisite * * @since 3.22 * * @param array $caps An array of capabilities. * @param string $cap The capability being requested. * @param int $user_id The current user's ID. * * @return array Modified array of user capabilities. */ function support_user_map_meta_cap( $caps, $cap, $user_id ) { if ( ! $this->is_support_user( $user_id ) ) { return $caps; } // This user is in an ET Support user role, so add the capability if ( 'unfiltered_html' === $cap ) { $caps = array( 'unfiltered_html' ); } return $caps; } /** * Remove KSES filters on ET Support User's content * * @since 3.22 */ function support_user_kses_remove_filters() { if ( $this->is_support_user() ) { kses_remove_filters(); } } /** * Clear "Delete Account" cron hook * * @since 3.20 * * @return void */ public function support_user_clear_delete_cron() { wp_clear_scheduled_hook( $this->support_user_cron_name ); } /** * Delete the support account if it's expired or the expiration date is not set * * @since 3.20 * * @return void */ public function support_user_cron_maybe_delete_account() { if ( ! username_exists( $this->support_user_account_name ) ) { return; } if ( isset( $this->support_user_options['date_created'] ) ) { $this->support_user_maybe_delete_expired_account(); } else { // if the expiration date isn't set, delete the account anyway $this->support_user_delete_account(); } } /** * Schedule account removal check * * @since 3.20 * * @return void */ public function support_user_init_cron_delete_account() { $this->support_user_clear_delete_cron(); wp_schedule_event( time(), 'hourly', $this->support_user_cron_name ); } /** * Get plugin options * * @since 3.20 * * @return void */ public function support_user_get_options() { $this->support_user_options = get_option( $this->support_user_options_name ); } /** * Generate random token * * @since 3.20 * * @param integer $length Token Length * @param bool $include_symbols Whether to include special characters (or just stick to alphanumeric) * * @return string $token Generated token */ public function support_user_generate_token( $length = 17, $include_symbols = true ) { $alphanum = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'; $symbols = '!@$^*()-=+'; $token = substr( str_shuffle( $include_symbols ? $alphanum . $symbols : $alphanum ), 0, $length ); return $token; } /** * Generate password from token * * @since 3.20 * * @param string $token Token * * @return string|WP_Error Generated password if successful, WP Error object otherwise */ public function support_user_generate_password( $token ) { global $wp_version; $salt = ''; /** @see ET_Core_SupportCenter::maybe_set_site_id() */ $site_id = get_option( 'et_support_site_id' ); if ( empty( $site_id ) ) { return false; } // Site ID must be a string if ( ! is_string( $site_id ) ) { return false; } $et_license = $this->get_et_license(); if ( ! $et_license ) { return false; } $send_to_api = array( 'action' => 'get_salt', 'site_id' => esc_attr( $site_id ), 'username' => esc_attr( $et_license['username'] ), 'api_key' => esc_attr( $et_license['api_key'] ), 'site_url' => esc_url( home_url( '/' ) ), 'login_url' => 'https://www.elegantthemes.com/members-area/admin/token/' . '?url=' . urlencode( wp_login_url() ) . '&token=' . urlencode( $token . '|' . $site_id ), ); $support_user_options = array( 'timeout' => 30, 'body' => $send_to_api, 'user-agent' => 'WordPress/' . $wp_version . '; Support Center/' . ET_CORE_VERSION . '; ' . home_url( '/' ), ); $request = wp_remote_post( 'https://www.elegantthemes.com/api/token.php', $support_user_options ); // Early exit if we don't get a good HTTP response from the API server if ( 200 !== intval( wp_remote_retrieve_response_code( $request ) ) ) { return new WP_Error( 'et_remote_access', esc_html__( 'Elegant Themes API Error: HTTP error in API response', 'et-core' ) ); } // Early exit and pass along WP_Error report if the server response is an error if ( is_wp_error( $request ) ) { return new WP_Error( 'et_remote_access', esc_html__( 'Elegant Themes API Error: WordPress Error in API response', 'et-core' ) ); } // Otherwise the response is good - let's load it and continue $response = unserialize( wp_remote_retrieve_body( $request ) ); // If the API returns an error, we will return and log the accompanying message $response_is_error = array_key_exists( 'error', $response ); $response_has_error_message = array_key_exists( 'message', $response ); if ( $response_is_error && $response_has_error_message ) { return new WP_Error( 'et_remote_access', esc_html__( 'Elegant Themes API Error: ' . $response['message'], 'et-core' ) ); } // If we get an "Incorrect Token" response, delete the generated Site ID from database $response_is_token_error = array_key_exists( 'incorrect_token', $response ); if ( $response_is_token_error && ! empty( $response['incorrect_token'] ) ) { delete_option( 'et_support_site_id' ); return new WP_Error( 'et_remote_access', esc_html__( 'Elegant Themes API Error: Incorrect Token. Please, try again.', 'et-core' ) ); } // If we get a normal-looking response, but it doesn't contain the salt we need if ( empty( $response['salt'] ) ) { return new WP_Error( 'et_remote_access', esc_html__( 'Elegant Themes API Error: The API response was missing required data.', 'et-core' ) ); } // We have the salt; let's clean it and make sure we can use it $salt = sanitize_text_field( $response['salt'] ); if ( empty( $salt ) ) { return new WP_Error( 'et_remote_access', esc_html__( 'Elegant Themes API Error: The API responded, but the response was empty.', 'et-core' ) ); } // Generate the password using the token we were initially passed & the salt from the API $password = hash( 'sha256', $token . $salt ); return $password; } /** * Delete the account if it's expired * * @since 3.20 * * @return void */ public function support_user_maybe_delete_expired_account() { if ( empty( $this->support_user_options['date_created'] ) ) { return; } $expiration_date_unix = strtotime( $this->support_user_expiration_time, $this->support_user_options['date_created'] ); // Delete the user account if the expiration date is in the past if ( time() >= $expiration_date_unix ) { $this->support_user_delete_account(); } return; } /** * Delete support account and the plugin options ( token, expiration date ) * * @since 3.20 * * @return string | WP_Error Confirmation message on success, WP_Error on failure */ public function support_user_delete_account() { if ( defined( 'DOING_CRON' ) ) { require_once( ABSPATH . 'wp-admin/includes/user.php' ); } if ( ! username_exists( $this->support_user_account_name ) ) { return new WP_Error( 'get_user_data', esc_html__( 'Support account doesn\'t exist.', 'et-core' ) ); } $support_account_data = get_user_by( 'login', $this->support_user_account_name ); if ( $support_account_data ) { $support_account_id = $support_account_data->ID; if ( ( is_multisite() && ! wpmu_delete_user( $support_account_id ) ) || ( ! is_multisite() && ! wp_delete_user( $support_account_id ) ) ) { return new WP_Error( 'delete_user', esc_html__( 'Support account hasn\'t been removed. Try to regenerate token again.', 'et-core' ) ); } delete_option( $this->support_user_options_name ); } else { return new WP_Error( 'get_user_data', esc_html__( 'Cannot get the support account data. Try to regenerate token again.', 'et-core' ) ); } $this->support_user_remove_roles(); $this->support_user_remove_site_id(); $this->support_user_clear_delete_cron(); // update options variable $this->support_user_get_options(); new WP_Error( 'get_user_data', esc_html__( 'Token has been deleted successfully.', 'et-core' ) ); return esc_html__( 'Token has been deleted successfully. ', 'et-core' ); } /** * Maybe delete support account and the plugin options when switching themes * * If a theme change is one of: * - [Divi/Extra] > [Divi/Extra] child theme * - [Divi/Extra] child theme > [Divi/Extra] child theme * - [Divi/Extra] child theme > [Divi/Extra] * ...then we won't change the state of the Remote Access toggle. * * @since 3.23 * * @return string | WP_Error Confirmation message on success, WP_Error on failure */ public function maybe_deactivate_on_theme_switch() { // Don't do anything if the user isn't logged in if ( ! is_user_logged_in() ) { return; } // Don't do anything if the parent theme's name matches the parent of this Support Center instance if ( get_option( 'template' ) === $this->parent_nicename ) { return; } // Leaving Divi/Extra environment; deactivate Support Center $this->support_user_delete_account(); $this->unlist_support_center(); $this->support_center_capabilities_teardown(); } /** * Is this user the ET Support User? * * @since 3.22 * * @param int|null $user_id Pass a User ID to check. We'll get the current user's ID otherwise. * * @return bool Returns whether this user is the ET Support User. */ function is_support_user( $user_id = null ) { $user_id = $user_id ? (int) $user_id : get_current_user_id(); if ( ! $user_id ) { return false; } $user = get_userdata( $user_id ); if ( ! is_object( $user ) || ! property_exists( $user, 'roles' ) ) { return false; } // Gather this user's associated role(s). $user_roles = (array) $user->roles; $user_is_support = false; // First, check the username. if ( ! $this->support_user_account_name === $user->user_login ) { return $user_is_support; } // Determine whether this user has the ET Support User role. if ( in_array( 'et_support', $user_roles, true ) ) { $user_is_support = true; } if ( in_array( 'et_support_elevated', $user_roles, true ) ) { $user_is_support = true; } return $user_is_support; } /** * Delete support account and the plugin options ( token, expiration date ) * * @since 3.20 * * @return void */ public function unlist_support_center() { delete_option( 'et_support_center_installed' ); } /** * */ public function support_user_remove_site_id() { $site_id = get_option( 'et_support_site_id' ); if ( empty( $site_id ) ) { return; } // Site ID must be a string if ( ! is_string( $site_id ) ) { return; } $et_license = $this->get_et_license(); if ( ! $et_license ) { return; } $send_to_api = array( 'action' => 'remove_site_id', 'site_id' => esc_attr( $site_id ), 'username' => esc_attr( $et_license['username'] ), 'api_key' => esc_attr( $et_license['api_key'] ), 'site_url' => esc_url( home_url( '/' ) ), ); $settings = array( 'timeout' => 30, 'body' => $send_to_api, ); $request = wp_remote_post( 'https://www.elegantthemes.com/api/token.php', $settings ); } function support_user_update_via_ajax() { // Verify nonce et_core_security_check( 'manage_options', 'support_center', 'nonce' ); // Get POST data $support_update = sanitize_text_field( $_POST['support_update'] ); $response = array(); // Update option(s) if ( 'activate' === $support_update ) { $maybe_create_user = $this->support_user_maybe_create_user(); // Only activate if we have a User ID and Password if ( ! is_wp_error( $maybe_create_user ) ) { $this->support_user_set_role( 'et_support' ); $account_settings = get_option( $this->support_user_options_name ); $site_id = get_option( 'et_support_site_id' ); $response['expiry'] = strtotime( date( 'Y-m-d H:i:s ', $this->support_user_options['date_created'] ) . $this->support_user_expiration_time ); $response['token'] = ''; if ( ! empty( $site_id ) && is_string( $site_id ) ) { $account_setting_token = isset( $account_settings['token'] ) ? $account_settings['token'] : ''; $response['token'] = $account_setting_token . '|' . $site_id; } $response['message'] = esc_html__( 'ET Support User role has been activated.', 'et-core' ); } else { et_error( $maybe_create_user->get_error_message() ); $response['error'] = $maybe_create_user->get_error_message(); } } if ( 'elevate' === $support_update ) { $this->support_user_set_role( 'et_support_elevated' ); $response['message'] = esc_html__( 'ET Support User role has been elevated.', 'et-core' ); } if ( 'deactivate' === $support_update ) { $this->support_user_set_role( '' ); $this->support_user_delete_account(); $this->support_user_clear_delete_cron(); $response['message'] = esc_html__( 'ET Support User role has been deactivated.', 'et-core' ); } // `echo` data to return if ( isset( $response ) ) { echo json_encode( $response ); } // `die` when we're done wp_die(); } /** * SUPPORT CENTER :: SAFE MODE */ /** * ET Product Allowlist * * @since 3.28 * * @param string $product Potential ET product name that we want to confirm is on the list. * * @return string|false If the product is on our list, we return the "nice name" we have for it. Otherwise, we return FALSE. */ protected function is_allowlisted_product( $product = '' ) { switch ( $product ) { case 'divi_builder_plugin': case 'divi_theme': case 'extra_theme': case 'monarch_plugin': case 'bloom_plugin': case 'divi_dash_plugin': return $this->get_parent_nicename( $product ); break; default: return false; } } /** * Safe Mode: Set session cookie to temporarily disable Plugins * * @since 3.20 * * @return void */ function safe_mode_update_via_ajax() { et_core_security_check( 'manage_options', 'support_center', 'nonce' ); $response = array(); // Get POST data $support_update = sanitize_text_field( $_POST['support_update'] ); // Update option(s) if ( 'activate' === $support_update ) { // Check the ET product that is activating Safe Mode $safe_mode_activator = sanitize_key( $_POST['product'] ); // Confirm that this is a allowlisted product $allowlisted_product = $this->is_allowlisted_product( $safe_mode_activator ); if ( ! $allowlisted_product ) { // Send a failure code and exit the function header( "HTTP/1.0 403 Forbidden" ); print 'Bad or malformed ET product name.'; wp_die(); } $this->toggle_safe_mode( true, $safe_mode_activator ); $response['message'] = esc_html__( 'ET Safe Mode has been activated.', 'et-core' ); } if ( 'deactivate' === $support_update ) { $this->toggle_safe_mode( false ); $response['message'] = esc_html__( 'ET Safe Mode has been deactivated.', 'et-core' ); } $this->set_safe_mode_cookie(); // `echo` data to return if ( isset( $response ) ) { echo json_encode( $response ); } // `die` when we're done wp_die(); } /** * Toggle Safe Mode * * @since 3.20 * * @param bool $activate TRUE if enabling Safe Mode, FALSE if disabling Safe mode. * @param string $product Name of ET product that is activating Safe Mode (@see ET_Core_SupportCenter::get_parent_nicename()). */ public function toggle_safe_mode( $activate = true, $product = '' ) { $activate = (bool) $activate; $user_id = get_current_user_id(); $allowlisted_product = $this->is_allowlisted_product( $product ); // Only proceed with an activation request if it comes from a allowlisted product if ( $activate && ! $allowlisted_product ) { return; } update_user_meta( $user_id, '_et_support_center_safe_mode', $activate ? 'on' : 'off' ); update_user_meta( $user_id, '_et_support_center_safe_mode_product', $activate ? sanitize_text_field( $allowlisted_product ) : '' ); $activate ? $this->maybe_add_mu_autoloader() : $this->maybe_remove_mu_autoloader(); /** * Fires when safe mode is toggled on or off. * * @since 3.25.4 * * @param bool $state True if toggled on, false if toggled off. */ do_action( 'et_support_center_toggle_safe_mode', $activate ); } /** * Set Safe Mode Cookie * * @since 3.20 * * @return void */ function set_safe_mode_cookie() { if ( et_core_is_safe_mode_active() ) { // This random string ensures old cookies aren't used to view the site in Safe Mode $passport = md5( rand() ); update_option( 'et-support-center-safe-mode-verify', $passport ); setcookie( 'et-support-center-safe-mode', $passport, time() + DAY_IN_SECONDS, SITECOOKIEPATH, false, is_ssl() ); } else { // Force-expire the cookie setcookie( 'et-support-center-safe-mode', '', 1, SITECOOKIEPATH, false, is_ssl() ); } } /** * Render modal that intercepts plugin activation/deactivation * * @since 3.20 * * @return void */ public function render_safe_mode_block_restricted() { if ( ! et_core_is_safe_mode_active() ) { return; } // Get the name of the ET product that activated Safe Mode $safe_mode_activator = get_user_meta( get_current_user_id(), '_et_support_center_safe_mode_product', true ); $verified_activator = $this->is_allowlisted_product( $safe_mode_activator ); ?> <script type="text/template" id="et-ajax-safe-mode-template"> <div class="et-core-modal-overlay et-core-form et-core-safe-mode-block-modal"> <div class="et-core-modal"> <div class="et-core-modal-header"> <h3 class="et-core-modal-title"> <?php print esc_html__( 'Safe Mode', 'et-core' ); ?> </h3> <a href="#" class="et-core-modal-close" data-et-core-modal="close"></a> </div> <div id="et-core-safe-mode-block-modal-content"> <div class="et-core-modal-content"> <p><?php print esc_html__( 'Safe Mode is enabled and the current action cannot be performed.', 'et-core' ); ?></p> </div> <a class="et-core-modal-action" href="<?php echo admin_url( null, 'admin.php?page=et_support_center#et_card_safe_mode' ); ?>"> <?php print esc_html__( sprintf( 'Turn Off %1$s Safe Mode', $verified_activator ), 'et-core' ); ?> </a> </div> </div> </div> </script> <?php } /** * Disable Custom CSS (if Safe Mode is active) * * @since 3.20 */ function maybe_disable_custom_css() { // Don't do anything if the user isn't logged in if ( ! is_user_logged_in() ) { return; } if ( et_core_is_safe_mode_active() ) { // Remove "Additional CSS" from WP Head action hook remove_action( 'wp_head', 'wp_custom_css_cb', 101 ); } } /** * Add Safe Mode Indicator (if Safe Mode is active) * * @since 3.20 */ function maybe_add_safe_mode_indicator() { // Don't do anything if the user isn't logged in if ( ! is_user_logged_in() ) { return; } // Don't display when Visual Builder is active if ( et_core_is_fb_enabled() ) { return; } if ( et_core_is_safe_mode_active() ) { // Get the name of the ET product that activated Safe Mode $safe_mode_activator = get_user_meta( get_current_user_id(), '_et_support_center_safe_mode_product', true ); $verified_activator = $this->is_allowlisted_product( $safe_mode_activator ); print sprintf( '<a class="%1$s" href="%2$s">%3$s</a>', 'et-safe-mode-indicator', esc_url( get_admin_url( null, 'admin.php?page=et_support_center#et_card_safe_mode' ) ), esc_html__( sprintf( 'Turn Off %1$s Safe Mode', $verified_activator ), 'et-core' ) ); print sprintf( '<div id="%1$s"><img src="%2$s" alt="%3$s" id="%3$s"/></div>', 'et-ajax-saving', esc_url( $this->local_path . 'admin/images/ajax-loader.gif' ), 'loading' ); } } /** * Prints the admin page for Support Center * * @since 3.20 */ public function add_support_center() { $is_current_user_et_support = 0; if ( in_array( 'et_support', wp_get_current_user()->roles ) ) { $is_current_user_et_support = 1; } if ( in_array( 'et_support_elevated', wp_get_current_user()->roles ) ) { $is_current_user_et_support = 2; } // Conditionally Display Divi Hosting Card $this->maybe_display_divi_hosting_card(); ?> <div id="et_support_center" class="wrap et-divi-admin-page--wrapper" data-et-zone="wp-admin" data-et-page="wp-admin-support-center"> <h1><?php esc_html_e( sprintf( '%1$s Help & Support Center', $this->parent_nicename ), 'et-core' ); ?></h1> <div id="epanel"> <div id="epanel-content"> <?php /** * Run code before any of the Support Center cards have been output * * @since 3.20 */ do_action( 'et_support_center_above_cards' ); // Build Card :: System Status if ( $this->current_user_can( 'et_support_center_system' ) ) { $card_title = esc_html__( 'System Status', 'et-core' ); $card_content = sprintf( '<div class="et-system-status summary">%1$s</div>' . '<textarea id="et_system_status_plain">%2$s</textarea>' . '<div class="et_card_cta">%3$s %4$s %5$s</div>', et_core_intentionally_unescaped( $this->system_diagnostics_generate_report( true, 'div' ), 'html' ), et_core_intentionally_unescaped( $this->system_diagnostics_generate_report( true, 'plain' ), 'html' ), sprintf( '<a class="full_report_show">%1$s</a>', esc_html__( 'Show Full Report', 'et-core' ) ), sprintf( '<a class="full_report_hide">%1$s</a>', esc_html__( 'Hide Full Report', 'et-core' ) ), sprintf( '<a class="full_report_copy">%1$s</a>', esc_html__( 'Copy Full Report', 'et-core' ) ) ); print $this->add_support_center_card( array( 'title' => $card_title, 'content' => $card_content, 'additional_classes' => array( 'et_system_status', 'summary', ), ) ); } /** * Run code after the 1st Support Center card has been output * * @since 3.20 */ do_action( 'et_support_center_below_position_1' ); // Build Card :: Remote Access if ( $this->current_user_can( 'et_support_center_remote_access' ) && ( 0 === $is_current_user_et_support ) ) { $card_title = esc_html__( 'Elegant Themes Support', 'et-core' ); $card_content = __( '<p>Enabling <strong>Remote Access</strong> will give the Elegant Themes support team limited access to your WordPress Dashboard. If requested, you can also enable full admin privileges. Remote Access should only be turned on if requested by the Elegant Themes support team. Remote Access is automatically disabled after 4 days.</p>', 'et-core' ); $support_account = $this->get_et_support_user(); $is_et_support_user_active = 0; $has_et_license = $this->get_et_license(); if ( ! $has_et_license ) { $card_content .= sprintf( '<div class="et-support-user"><h4>%1$s</h4><p>%2$s</p></div>', esc_html__( 'Remote Access', 'et-core' ), __( 'Remote Access cannot be enabled because you do not have a valid API Key or your Elegant Themes subscription has expired. You can find your API Key by <a href="https://www.elegantthemes.com/members-area/api/" target="_blank">logging in</a> to your Elegant Themes account. It should then be added to your <a href="https://www.elegantthemes.com/documentation/divi/update-divi/" target=_blank">Options Panel</a>.', 'et-core' ) ); } else { if ( is_object( $support_account ) && property_exists( $support_account, 'roles' ) ) { if ( in_array( 'et_support', $support_account->roles ) ) { $is_et_support_user_active = 1; } if ( in_array( 'et_support_elevated', $support_account->roles ) ) { $is_et_support_user_active = 2; } } $support_user_active_state = ( intval( $is_et_support_user_active ) > 0 ) ? ' et_pb_on_state' : ' et_pb_off_state'; $expiry = ''; if ( ! empty( $this->support_user_options['date_created'] ) ) { // Calculate the 'Created Date' plus the 'Time To Expire' $date_created = date( 'Y-m-d H:i:s ', $this->support_user_options['date_created'] ); $expiry = strtotime( $date_created . $this->support_user_expiration_time ); } // Toggle Support User activation $card_content .= sprintf( '<div class="et-support-user"><h4>%1$s</h4>' . '<div class="et_support_user_toggle">' . '<div class="%7$s_wrapper"><div class="%7$s %2$s">' . '<span class="%8$s et_pb_on_value">%3$s</span>' . '<span class="et_pb_button_slider"></span>' . '<span class="%8$s et_pb_off_value">%4$s</span>' . '</div></div>' . '<span class="et-support-user-expiry" data-expiry="%5$s">%6$s' . '<span class="support-user-time-to-expiry"></span>' . '</span>' . '<span class="et-remote-access-error"></span>' . '</div>' . '</div>', esc_html__( 'Remote Access', 'et-core' ), esc_attr( $support_user_active_state ), esc_html__( 'Enabled', 'et-core' ), esc_html__( 'Disabled', 'et-core' ), esc_attr( $expiry ), esc_html__( 'Remote Access will be automatically disabled in: ', 'et-core' ), 'et_pb_yes_no_button', 'et_pb_value_text' ); // Toggle Support User role elevation (only visible if Support User is active) $extra_css = ( intval( $is_et_support_user_active ) > 0 ) ? 'style="display:block;"' : ''; $support_user_elevated_state = ( intval( $is_et_support_user_active ) > 1 ) ? ' et_pb_on_state' : ' et_pb_off_state'; $card_content .= sprintf( '<div class="et-support-user-elevated" %5$s><h4>%1$s</h4>' . '<div class="et_support_user_elevated_toggle">' . '<div class="%6$s_wrapper"><div class="%6$s %2$s">' . '<span class="%7$s et_pb_on_value">%3$s</span>' . '<span class="et_pb_button_slider"></span>' . '<span class="%7$s et_pb_off_value">%4$s</span>' . '</div></div>' . '</div>' . '</div>', esc_html__( 'Activate Full Admin Privileges', 'et-core' ), esc_attr( $support_user_elevated_state ), esc_html__( 'Enabled', 'et-core' ), esc_html__( 'Disabled', 'et-core' ), et_core_intentionally_unescaped( $extra_css, 'html' ), 'et_pb_yes_no_button', 'et_pb_value_text' ); } // Add a "Copy Support Token" CTA if Remote Access is active $site_id = get_option( 'et_support_site_id' ); $support_token_cta = ''; if ( intval( $is_et_support_user_active ) > 0 && ! empty( $site_id ) && is_string( $site_id ) ) { $account_settings = get_option( $this->support_user_options_name ); $account_setting_token = isset( $account_settings['token'] ) ? $account_settings['token'] : ''; $support_token_cta = '<a class="copy_support_token" data-token="' . esc_attr( $account_setting_token . '|' . $site_id ) . '">' . esc_html__( 'Copy Support Token', 'et-core' ) . '</a>'; } $vip_support_content = '<div class="et_vip_support">' . '<div class="et_vip_support__left">' . '<a target="_blank" href="https://www.elegantthemes.com/vip/?utm_source=Divi+VIP&utm_medium=Support+Center&utm_campaign=Native">' . '<img src="' . esc_url( ET_CORE_URL ) . 'admin/images/blurb-vip.jpg" alt="Divi VIP Support" />' . '</a>' . '</div>' . '<div class="et_vip_support__right">' . '<h2>' . esc_html__( 'Get More With Divi VIP', 'et-core' ) . '</h2>' . '<h2>' . esc_html__( 'The Best Support, Even Faster.', 'et-core' ) . '</h2>' . '<p>' . esc_html__( 'We want to provide exactly the level of support any of our customers need to be successful. With Divi VIP, you get faster support (Under 30 minutes response times around the clock). Keep your clients happy by letting us solve their problems faster.', 'et-core' ) . '</p>' . '<a target="_blank" href="https://www.elegantthemes.com/vip/?utm_source=Divi+VIP&utm_medium=Support+Center&utm_campaign=Native">' . esc_html__( 'Get Divi VIP Today!', 'et-core' ) . '</a>' . '</div>' . '</div>'; $card_content .= '<div class="et_card_cta">' . '<a target="_blank" href="https://www.elegantthemes.com/members-area/help/">' . esc_html__( 'Chat With Support', 'et-core' ) . '</a>' . $support_token_cta . $vip_support_content . '</div>'; print $this->add_support_center_card( array( 'title' => $card_title, 'content' => $card_content, 'additional_classes' => array( 'et_remote_access', 'et-epanel-box', ), ) ); } /** * Run code after the 2nd Support Center card has been output * * @since 3.20 */ do_action( 'et_support_center_below_position_2' ); // Build Card :: Divi Documentation & Help if ( $this->current_user_can( 'et_support_center_documentation' ) ) { switch ( $this->parent ) { case 'extra_theme': $documentation_url = 'https://www.elegantthemes.com/documentation/extra/'; break; case 'divi_theme': $documentation_url = 'https://www.elegantthemes.com/documentation/divi/'; break; case 'divi_builder_plugin': $documentation_url = 'https://www.elegantthemes.com/documentation/divi-builder/'; break; case 'monarch_plugin': $documentation_url = 'https://www.elegantthemes.com/documentation/monarch/'; break; case 'bloom_plugin': $documentation_url = 'https://www.elegantthemes.com/documentation/bloom/'; break; default: $documentation_url = 'https://www.elegantthemes.com/documentation/'; } $card_title = esc_html__( sprintf( '%1$s Documentation & Help', $this->parent_nicename ), 'et-core' ); $card_content = $this->get_documentation_video_player(); $card_content .= $this->get_documentation_articles_list(); $card_content .= '<div class="et_card_cta">' . '<a href="' . $documentation_url . '" class="launch_documentation" target="_blank">' . esc_html__( sprintf( 'View Full %1$s Documentation', $this->parent_nicename ), 'et-core' ) . '</a>' . '</div>'; print $this->add_support_center_card( array( 'title' => $card_title, 'content' => $card_content, 'additional_classes' => array( 'et_documentation_help', 'et-epanel-box', ), ) ); } /** * Run code after the 3rd Support Center card has been output * * @since 3.20 */ do_action( 'et_support_center_below_position_3' ); // Build Card :: Safe Mode if ( $this->current_user_can( 'et_support_center_safe_mode' ) ) { $card_title = esc_html__( 'Safe Mode', 'et-core' ); $card_content = __( '<p>Enabling <strong>Safe Mode</strong> will temporarily disable features and plugins that may be causing problems with your Elegant Themes product. This includes all Plugins, Child Themes, and Custom Code added to your integration areas. These items are only disabled for your current user session so your visitors will not be disrupted. Enabling Safe Mode makes it easy to figure out what is causing problems on your website by identifying or eliminating third party plugins and code as potential causes.</p>', 'et-core' ); $error_message = ''; $safe_mode_active = ( et_core_is_safe_mode_active() ) ? ' et_pb_on_state' : ' et_pb_off_state'; $plugins_list = array(); $plugins_output = ''; $has_mu_plugins_dir = wp_mkdir_p( WPMU_PLUGIN_DIR ) && wp_is_writable( WPMU_PLUGIN_DIR ); $can_create_mu_plugins_dir = wp_is_writable( WP_CONTENT_DIR ) && ! wp_mkdir_p( WPMU_PLUGIN_DIR ); if ( $has_mu_plugins_dir || $can_create_mu_plugins_dir ) { // Gather list of plugins that will be temporarily deactivated in Safe Mode $all_plugins = get_plugins(); $active_plugins = get_option( 'active_plugins' ); foreach ( $active_plugins as $plugin ) { // Verify this 'active' plugin actually exists in the plugins directory if ( ! in_array( $plugin, array_keys( $all_plugins ) ) ) { continue; } // If it's not in our allowlist, add it to the list of plugins we'll disable if ( ! in_array( $plugin, $this->safe_mode_plugins_allowlist ) ) { $plugins_list[] = '<li>' . esc_html( $all_plugins[ $plugin ]['Name'] ) . '</li>'; } } } else { $error_message = et_get_safe_localization( sprintf( __( '<p class="et-safe-mode-error">Plugins cannot be disabled because your <code>wp-content</code> directory has inconsistent file permissions. <a href="%1$s" target="_blank">Click here</a> for more information.</p>', 'et-core' ), 'https://wordpress.org/support/article/changing-file-permissions/' ) ); } if ( count( $plugins_list ) > 0 ) { $plugins_output = sprintf( '<p>%1$s</p><ul>%2$s</ul>', esc_html__( 'The following plugins will be temporarily disabled for you only:', 'et-core' ), et_core_intentionally_unescaped( implode( ' ', $plugins_list ), 'html' ) ); } // Toggle Safe Mode activation $card_content .= sprintf( '<div id="et_card_safe_mode" class="et-safe-mode" data-et-product="%8$s">' . '<div class="et_safe_mode_toggle">' . '<div class="%5$s_wrapper"><div class="%5$s %1$s">' . '<span class="%6$s et_pb_on_value">%2$s</span>' . '<span class="et_pb_button_slider"></span>' . '<span class="%6$s et_pb_off_value">%3$s</span>' . '</div></div>' . '%4$s' . '%7$s' . '</div>' . '</div>', esc_attr( $safe_mode_active ), esc_html__( 'Enabled', 'et-core' ), esc_html__( 'Disabled', 'et-core' ), $plugins_output, 'et_pb_yes_no_button', 'et_pb_value_text', $error_message, esc_attr( $this->parent ) ); print $this->add_support_center_card( array( 'title' => $card_title, 'content' => $card_content, 'additional_classes' => array( 'et_safe_mode', 'et-epanel-box', ), ) ); } /** * Run code after the 4th Support Center card has been output * * @since 3.20 */ do_action( 'et_support_center_below_position_4' ); // Build Card :: Logs if ( $this->current_user_can( 'et_support_center_logs' ) ) { $debug_log_lines = apply_filters( 'et_debug_log_lines', 200 ); $wp_debug_log = $this->get_wp_debug_log( $debug_log_lines ); $card_title = esc_html__( 'Logs', 'et-core' ); $card_content = '<p>If you have <a href="https://codex.wordpress.org/Debugging_in_WordPress" target=_blank" >WP_DEBUG_LOG</a> enabled, WordPress related errors will be archived in a log file. For your convenience, we have aggregated the contents of this log file so that you and the Elegant Themes support team can view it easily. The file cannot be edited here.</p>'; if ( isset( $wp_debug_log['error'] ) ) { $card_content .= '<div class="et_system_status_log_preview">' . '<textarea>' . $wp_debug_log['error'] . '</textarea>' . '</div>'; } else { $card_content .= '<div class="et_system_status_log_preview">' . '<textarea id="et_logs_display">' . $wp_debug_log['entries'] . '</textarea>' . '<textarea id="et_logs_recent">' . $wp_debug_log['entries'] . '</textarea>' . '</div>' . '<div class="et_card_cta">' . '<a href="' . content_url( 'debug.log' ) . '" class="download_debug_log" download>' . esc_html__( 'Download Full Debug Log', 'et-core' ) . ' (' . $wp_debug_log['size'] . ')' . '</a>' . '<a class="copy_debug_log">' . esc_html__( 'Copy Recent Log Entries', 'et-core' ) . '</a>' . '</div>'; } print $this->add_support_center_card( array( 'title' => $card_title, 'content' => $card_content, 'additional_classes' => array( 'et_system_logs', 'et-epanel-box', ), ) ); } /** * Run code after all of the Support Center cards have been output * * @since 3.20 */ do_action( 'et_support_center_below_cards' ); ?> </div> </div> </div> <div id="et-ajax-saving"> <img src="<?php echo esc_url( $this->local_path . 'admin/images/ajax-loader.gif' ); ?>" alt="loading" id="loading" /> </div> <?php } /** * SUPPORT CENTER :: DIVI HOSTING CARD */ /** * Conditionally display Divi Hosting Card in the Support Center * * @since 4.4.7 */ public function maybe_display_divi_hosting_card() { // Sanity Check: Exit early if the user does not have permission if ( ! $this->current_user_can( 'et_support_center_system' ) ) { return; } // Exit if Admin dismissed the Divi Hosting Card if ( get_option( 'et_hosting_card_dismissed', false ) ) { return; } // Show the Divi Hosting Card add_action( 'et_support_center_below_position_1', array( $this, 'print_divi_hosting_card' ) ); } /** * Prepare Settings for ET API request * Returns false when ET username/api_key is not found, and ET subscription is not active * * @since 4.4.7 * @param string $action * * @return bool|array */ protected function get_et_api_request_settings( $action ) { $et_account = et_core_get_et_account(); $et_username = et_()->array_get( $et_account, 'et_username', '' ); $et_api_key = et_()->array_get( $et_account, 'et_api_key', '' ); // Only when ET Username and ET API Key is found if ( '' !== $et_username && '' !== $et_api_key ) { global $wp_version; // Prepare settings for API request return array( 'timeout' => 30, 'body' => array( 'action' => $action, 'username' => $et_username, 'api_key' => $et_api_key, ), 'user-agent' => 'WordPress/' . $wp_version . '; Support Center/' . ET_CORE_VERSION . '; ' . home_url( '/' ), ); } return false; } /** * Check ET API whether ET User has disabled Divi Hosting Card * * @since 4.4.7 * * @return bool */ protected function maybe_api_has_hosting_card_disabled() { // Get API settings $api_settings = $this->get_et_api_request_settings( 'check_hosting_card_status' ); // Check API only when ET Username, ET API Key is found and Account is active if ( is_array( $api_settings ) ) { $request = wp_remote_post( 'https://www.elegantthemes.com/api/api.php', $api_settings ); $request_response_code = wp_remote_retrieve_response_code( $request ); // Do not show the Hosting Card when API Request, or, API Response has any error if ( is_wp_error( $request ) || 200 !== $request_response_code ) { return true; } $response_body = wp_remote_retrieve_body( $request ); $response = (array) json_decode( $response_body ); // Check whether the User has disabled the card if ( et_()->array_get( $response, 'success' ) && et_()->array_get( $response, 'status' ) === 'disabled' ) { // Mark it dismissed, so it won't be displayed anymore on this website update_option( 'et_hosting_card_dismissed', true ); // Do not show the Hosting Card return true; } } // Show the Hosting Card return false; } /** * Return Data for Divi Hosting Card * * @since 4.4.7 * * @return array */ protected function get_divi_hosting_features() { return array( 'title' => esc_html__( 'Get Recommended Divi Hosting', 'et-core' ), 'summary' => esc_html__( 'Upgrade your hosting to the most reliable, Divi-compatible hosting. Enjoy perfectly configured hosting environments pre-installed with the tools you need to be successful with Divi.', 'et-core' ), 'url' => 'https://www.elegantthemes.com/hosting/', 'learn_more' => esc_html__( 'Learn About Divi Hosting', 'et-core' ), 'dismiss_tooltip' => esc_html__( 'Remove This Recommendation On All Of Your Websites And Your Client\'s Websites Forever', 'et-core' ), 'features' => array( 'server' => array( 'title' => esc_html__( 'Divi-Optimized Servers', 'et-core' ), 'tooltip' => esc_html__( "We worked with our parters to make sure that their hosting solutions meet all of Divi's requirements out of the box. No hosting headaches on Divi Hosting.", 'et-core' ), ), 'speed' => array( 'title' => esc_html__( 'Blazing Fast Speed', 'et-core' ), 'tooltip' => esc_html__( 'Divi Hosting is powered by fast networks, modern hosting infrastructures and the latest server software. Plus you will enjoy automatic caching and a free CDN.', 'et-core' ), ), 'security' => array( 'title' => esc_html__( 'A Focus On Security', 'et-core' ), 'tooltip' => esc_html__( 'All of our hosting partners are dedicated to security. That means up-to-date server software and secure hosting practices.', 'et-core' ), ), 'backups' => array( 'title' => esc_html__( 'Automatic Backups', 'et-core' ), 'tooltip' => esc_html__( 'Every website needs backups! Each of our hosting partners provide automatic daily backups. If disaster strikes, these hosting companies have your back.', 'et-core' ), ), 'migrate' => array( 'title' => esc_html__( 'Easy Site Migration', 'et-core' ), 'tooltip' => esc_html__( "Already have a Divi website hosted somewhere else? All of our hosting partners provide migration tools or professional assisted migration. It's easy to switch to Divi Hosting!", 'et-core' ), ), 'staging' => array( 'title' => esc_html__( 'Easy Staging Sites', 'et-core' ), 'tooltip' => esc_html__( 'Automatic staging sites make it easy to develop new designs for your clients without disrupting visitors. Finish your work and push it live all at once.', 'et-core' ), ), ), ); } /** * Build and display Divi Hosting Card * * @since 4.4.7 */ public function print_divi_hosting_card() { // Gather System status data $report = $this->system_diagnostics_generate_report( false ); $result = array(); // Prepare the report data to check against when to show the Divi Hosting Card foreach ( $report as $status ) { $result[] = et_()->array_get( $status, 'pass_fail' ); } // Exit if any system status item is not in a warning state (red dot indicator) if ( ! in_array( 'fail', array_values( $result ), true ) ) { return; } // Exit if ET User has disabled the Divi Hosting card if ( $this->maybe_api_has_hosting_card_disabled() ) { return; } // JS dependency for Tooltips wp_enqueue_script( 'popper', $this->local_path . 'admin/js/popper.min.js', array( 'jquery' ), ET_CORE_VERSION ); wp_enqueue_script( 'tippy', $this->local_path . 'admin/js/tippy.min.js', array( 'jquery', 'popper' ), ET_CORE_VERSION ); $card = $this->get_divi_hosting_features(); $features = ''; // HTML Template for Features of the Divi Hosting Card foreach ( $card['features'] as $name => $feature ) { $features .= sprintf( '<div class="et_hosting_card--feature" data-tippy-content="%1$s">%2$s <h4>%3$s</h4></div>', esc_html( $feature['tooltip'] ), sprintf( '<object type="image/svg+xml" className="fitvidsignore" data="%1$s" width="32" height="32"></object>', esc_url( "{$this->local_path}admin/images/svg/{$name}.svg" ) ), esc_html( $feature['title'] ) ); } // HTML Template for the Divi Hosting Card $card_content = sprintf( '<p class="et_card_summary">%1$s</p> <div class="et_card_content et_hosting_card--features">%2$s</div> <div class="et_card_cta et_hosting_card--cta">%3$s</div>', esc_html( $card['summary'] ), et_core_esc_previously( $features ), sprintf( '<a class="et_hosting_card--link" target="_blank" href="%1$s" title="%2$s">%3$s</a>', esc_url( $card['url'] ), esc_attr( $card['learn_more'] ), esc_html( $card['learn_more'] ) ) ); // Display the Divi Hosting Card print $this->add_support_center_card( array( 'title' => $card['title'], 'content' => $card_content, 'additional_classes' => array( 'et_hosting_card', ), 'dismiss_button' => array( 'card_key' => 'et_hosting_card', 'tooltip' => $card['dismiss_tooltip'], 'additional_classes' => array( 'et_hosting_card--dismiss', ), ), ) ); } } json-data/google-fonts.json 0000644 00000555076 15222641012 0011737 0 ustar 00 {"items":[{"family":"ABeeZee","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Abel","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Abhaya Libre","variants":["regular","500","600","700","800"],"subsets":["latin","latin-ext","sinhala"],"category":"serif"},{"family":"Aboreto","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Abril Fatface","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Abyssinica SIL","variants":["regular"],"subsets":["ethiopic","latin","latin-ext"],"category":"serif"},{"family":"Aclonica","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Acme","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Actor","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Adamina","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Advent Pro","variants":["100","200","300","regular","500","600","700"],"subsets":["greek","latin","latin-ext"],"category":"sans-serif"},{"family":"Aguafina Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Akaya Kanadaka","variants":["regular"],"subsets":["kannada","latin","latin-ext"],"category":"display"},{"family":"Akaya Telivigala","variants":["regular"],"subsets":["latin","latin-ext","telugu"],"category":"display"},{"family":"Akronim","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Akshar","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Aladin","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Alata","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Alatsi","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Albert Sans","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Aldrich","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Alef","variants":["regular","700"],"subsets":["hebrew","latin"],"category":"sans-serif"},{"family":"Alegreya","variants":["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Alegreya SC","variants":["regular","italic","500","500italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Alegreya Sans","variants":["100","100italic","300","300italic","regular","italic","500","500italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Alegreya Sans SC","variants":["100","100italic","300","300italic","regular","italic","500","500italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Aleo","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Alex Brush","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Alfa Slab One","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Alice","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"serif"},{"family":"Alike","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Alike Angular","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Alkalami","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Allan","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Allerta","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Allerta Stencil","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Allison","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Allura","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Almarai","variants":["300","regular","700","800"],"subsets":["arabic"],"category":"sans-serif"},{"family":"Almendra","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Almendra Display","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Almendra SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Alumni Sans","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Alumni Sans Collegiate One","variants":["regular","italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Alumni Sans Inline One","variants":["regular","italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Alumni Sans Pinstripe","variants":["regular","italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Amarante","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Amaranth","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"Amatic SC","variants":["regular","700"],"subsets":["cyrillic","hebrew","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Amethysta","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Amiko","variants":["regular","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Amiri","variants":["regular","italic","700","700italic"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Amiri Quran","variants":["regular"],"subsets":["arabic","latin"],"category":"serif"},{"family":"Amita","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"handwriting"},{"family":"Anaheim","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Andada Pro","variants":["regular","500","600","700","800","italic","500italic","600italic","700italic","800italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Andika","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Anek Bangla","variants":["100","200","300","regular","500","600","700","800"],"subsets":["bengali","latin","latin-ext"],"category":"sans-serif"},{"family":"Anek Devanagari","variants":["100","200","300","regular","500","600","700","800"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Anek Gujarati","variants":["100","200","300","regular","500","600","700","800"],"subsets":["gujarati","latin","latin-ext"],"category":"sans-serif"},{"family":"Anek Gurmukhi","variants":["100","200","300","regular","500","600","700","800"],"subsets":["gurmukhi","latin","latin-ext"],"category":"sans-serif"},{"family":"Anek Kannada","variants":["100","200","300","regular","500","600","700","800"],"subsets":["kannada","latin","latin-ext"],"category":"sans-serif"},{"family":"Anek Latin","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Anek Malayalam","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","malayalam"],"category":"sans-serif"},{"family":"Anek Odia","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","oriya"],"category":"sans-serif"},{"family":"Anek Tamil","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","tamil"],"category":"sans-serif"},{"family":"Anek Telugu","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","telugu"],"category":"sans-serif"},{"family":"Angkor","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Annie Use Your Telescope","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Anonymous Pro","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","greek","latin","latin-ext"],"category":"monospace"},{"family":"Antic","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Antic Didone","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Antic Slab","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Anton","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Antonio","variants":["100","200","300","regular","500","600","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Anybody","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Arapey","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"Arbutus","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Arbutus Slab","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Architects Daughter","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Archivo","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Archivo Black","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Archivo Narrow","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Are You Serious","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Aref Ruqaa","variants":["regular","700"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Aref Ruqaa Ink","variants":["regular","700"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Arima","variants":["100","200","300","regular","500","600","700"],"subsets":["greek","greek-ext","latin","latin-ext","malayalam","tamil","vietnamese"],"category":"display"},{"family":"Arima Madurai","variants":["100","200","300","regular","500","700","800","900"],"subsets":["latin","latin-ext","tamil","vietnamese"],"category":"display"},{"family":"Arimo","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Arizonia","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Armata","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Arsenal","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Artifika","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Arvo","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"serif"},{"family":"Arya","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Asap","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Asap Condensed","variants":["regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Asar","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Asset","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Assistant","variants":["200","300","regular","500","600","700","800"],"subsets":["hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"Astloch","variants":["regular","700"],"subsets":["latin"],"category":"display"},{"family":"Asul","variants":["regular","700"],"subsets":["latin"],"category":"sans-serif"},{"family":"Athiti","variants":["200","300","regular","500","600","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Atkinson Hyperlegible","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Atma","variants":["300","regular","500","600","700"],"subsets":["bengali","latin","latin-ext"],"category":"display"},{"family":"Atomic Age","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Aubrey","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Audiowide","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Autour One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Average","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Average Sans","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Averia Gruesa Libre","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Averia Libre","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin"],"category":"display"},{"family":"Averia Sans Libre","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin"],"category":"display"},{"family":"Averia Serif Libre","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin"],"category":"display"},{"family":"Azeret Mono","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"B612","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"B612 Mono","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"monospace"},{"family":"BIZ UDGothic","variants":["regular","700"],"subsets":["cyrillic","greek-ext","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"BIZ UDMincho","variants":["regular"],"subsets":["cyrillic","greek-ext","japanese","latin","latin-ext"],"category":"serif"},{"family":"BIZ UDPGothic","variants":["regular","700"],"subsets":["cyrillic","greek-ext","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"BIZ UDPMincho","variants":["regular"],"subsets":["cyrillic","greek-ext","japanese","latin","latin-ext"],"category":"serif"},{"family":"Babylonica","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Bad Script","variants":["regular"],"subsets":["cyrillic","latin"],"category":"handwriting"},{"family":"Bahiana","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Bahianita","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bai Jamjuree","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Bakbak One","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"display"},{"family":"Ballet","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Baloo 2","variants":["regular","500","600","700","800"],"subsets":["devanagari","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Baloo Bhai 2","variants":["regular","500","600","700","800"],"subsets":["gujarati","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Baloo Bhaijaan 2","variants":["regular","500","600","700","800"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Baloo Bhaina 2","variants":["regular","500","600","700","800"],"subsets":["latin","latin-ext","oriya","vietnamese"],"category":"display"},{"family":"Baloo Chettan 2","variants":["regular","500","600","700","800"],"subsets":["latin","latin-ext","malayalam","vietnamese"],"category":"display"},{"family":"Baloo Da 2","variants":["regular","500","600","700","800"],"subsets":["bengali","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Baloo Paaji 2","variants":["regular","500","600","700","800"],"subsets":["gurmukhi","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Baloo Tamma 2","variants":["regular","500","600","700","800"],"subsets":["kannada","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Baloo Tammudu 2","variants":["regular","500","600","700","800"],"subsets":["latin","latin-ext","telugu","vietnamese"],"category":"display"},{"family":"Baloo Thambi 2","variants":["regular","500","600","700","800"],"subsets":["latin","latin-ext","tamil","vietnamese"],"category":"display"},{"family":"Balsamiq Sans","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"display"},{"family":"Balthazar","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Bangers","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Barlow","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Barlow Condensed","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Barlow Semi Condensed","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Barriecito","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Barrio","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Basic","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Baskervville","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Battambang","variants":["100","300","regular","700","900"],"subsets":["khmer","latin"],"category":"display"},{"family":"Baumans","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Bayon","variants":["regular"],"subsets":["khmer","latin"],"category":"sans-serif"},{"family":"Be Vietnam Pro","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Beau Rivage","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Bebas Neue","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Belgrano","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Bellefair","variants":["regular"],"subsets":["hebrew","latin","latin-ext"],"category":"serif"},{"family":"Belleza","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Bellota","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bellota Text","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"display"},{"family":"BenchNine","variants":["300","regular","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Benne","variants":["regular"],"subsets":["kannada","latin","latin-ext"],"category":"serif"},{"family":"Bentham","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Berkshire Swash","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Besley","variants":["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Beth Ellen","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Bevan","variants":["regular","italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"BhuTuka Expanded One","variants":["regular"],"subsets":["gurmukhi","latin","latin-ext"],"category":"display"},{"family":"Big Shoulders Display","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Big Shoulders Inline Display","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Big Shoulders Inline Text","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Big Shoulders Stencil Display","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Big Shoulders Stencil Text","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Big Shoulders Text","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bigelow Rules","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Bigshot One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Bilbo","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Bilbo Swash Caps","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"BioRhyme","variants":["200","300","regular","700","800"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"BioRhyme Expanded","variants":["200","300","regular","700","800"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Birthstone","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Birthstone Bounce","variants":["regular","500"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Biryani","variants":["200","300","regular","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Bitter","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Black And White Picture","variants":["regular"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Black Han Sans","variants":["regular"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Black Ops One","variants":["regular"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Blaka","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Blaka Hollow","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Blaka Ink","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Blinker","variants":["100","200","300","regular","600","700","800","900"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Bodoni Moda","variants":["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Bokor","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Bona Nova","variants":["regular","italic","700"],"subsets":["cyrillic","cyrillic-ext","greek","hebrew","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Bonbon","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Bonheur Royale","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Boogaloo","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Bowlby One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Bowlby One SC","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Brawler","variants":["regular","700"],"subsets":["latin"],"category":"serif"},{"family":"Bree Serif","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Brygada 1918","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Bubblegum Sans","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Bubbler One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Buda","variants":["300"],"subsets":["latin"],"category":"display"},{"family":"Buenard","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Bungee","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bungee Hairline","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bungee Inline","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bungee Outline","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bungee Shade","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Bungee Spice","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Butcherman","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Butterfly Kids","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Cabin","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Cabin Condensed","variants":["regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Cabin Sketch","variants":["regular","700"],"subsets":["latin"],"category":"display"},{"family":"Caesar Dressing","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Cagliostro","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Cairo","variants":["200","300","regular","500","600","700","800","900"],"subsets":["arabic","latin","latin-ext"],"category":"sans-serif"},{"family":"Cairo Play","variants":["200","300","regular","500","600","700","800","900"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Caladea","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Calistoga","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Calligraffitti","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Cambay","variants":["regular","italic","700","700italic"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Cambo","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Candal","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Cantarell","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"Cantata One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Cantora One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Capriola","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Caramel","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Carattere","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Cardo","variants":["regular","italic","700"],"subsets":["greek","greek-ext","latin","latin-ext"],"category":"serif"},{"family":"Carme","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Carrois Gothic","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Carrois Gothic SC","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Carter One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Castoro","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Catamaran","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","tamil"],"category":"sans-serif"},{"family":"Caudex","variants":["regular","italic","700","700italic"],"subsets":["greek","greek-ext","latin","latin-ext"],"category":"serif"},{"family":"Caveat","variants":["regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"handwriting"},{"family":"Caveat Brush","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Cedarville Cursive","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Ceviche One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Chakra Petch","variants":["300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Changa","variants":["200","300","regular","500","600","700","800"],"subsets":["arabic","latin","latin-ext"],"category":"sans-serif"},{"family":"Changa One","variants":["regular","italic"],"subsets":["latin"],"category":"display"},{"family":"Chango","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Charis SIL","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Charm","variants":["regular","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"handwriting"},{"family":"Charmonman","variants":["regular","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"handwriting"},{"family":"Chathura","variants":["100","300","regular","700","800"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Chau Philomene One","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Chela One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Chelsea Market","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Chenla","variants":["regular"],"subsets":["khmer"],"category":"display"},{"family":"Cherish","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Cherry Cream Soda","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Cherry Swash","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Chewy","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Chicle","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Chilanka","variants":["regular"],"subsets":["latin","malayalam"],"category":"handwriting"},{"family":"Chivo","variants":["300","300italic","regular","italic","700","700italic","900","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Chonburi","variants":["regular"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"display"},{"family":"Cinzel","variants":["regular","500","600","700","800","900"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Cinzel Decorative","variants":["regular","700","900"],"subsets":["latin"],"category":"display"},{"family":"Clicker Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Coda","variants":["regular","800"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Coda Caption","variants":["800"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Codystar","variants":["300","regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Coiny","variants":["regular"],"subsets":["latin","latin-ext","tamil","vietnamese"],"category":"display"},{"family":"Combo","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Comfortaa","variants":["300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Comforter","variants":["regular"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Comforter Brush","variants":["regular"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Comic Neue","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin"],"category":"handwriting"},{"family":"Coming Soon","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Commissioner","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Concert One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Condiment","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Content","variants":["regular","700"],"subsets":["khmer"],"category":"display"},{"family":"Contrail One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Convergence","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Cookie","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Copse","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Corben","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Corinthia","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Cormorant","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Cormorant Garamond","variants":["300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Cormorant Infant","variants":["300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Cormorant SC","variants":["300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Cormorant Unicase","variants":["300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Cormorant Upright","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Courgette","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Courier Prime","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"Cousine","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Coustard","variants":["regular","900"],"subsets":["latin"],"category":"serif"},{"family":"Covered By Your Grace","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Crafty Girls","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Creepster","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Crete Round","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Crimson Pro","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Crimson Text","variants":["regular","italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Croissant One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Crushed","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Cuprum","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Cute Font","variants":["regular"],"subsets":["korean","latin"],"category":"display"},{"family":"Cutive","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Cutive Mono","variants":["regular"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"DM Mono","variants":["300","300italic","regular","italic","500","500italic"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"DM Sans","variants":["regular","italic","500","500italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"DM Serif Display","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"DM Serif Text","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Damion","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Dancing Script","variants":["regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Dangrek","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Darker Grotesque","variants":["300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"David Libre","variants":["regular","500","700"],"subsets":["hebrew","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Dawning of a New Day","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Days One","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Dekko","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"handwriting"},{"family":"Dela Gothic One","variants":["regular"],"subsets":["cyrillic","greek","japanese","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Delius","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Delius Swash Caps","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Delius Unicase","variants":["regular","700"],"subsets":["latin"],"category":"handwriting"},{"family":"Della Respira","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Denk One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Devonshire","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Dhurjati","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Didact Gothic","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"Diplomata","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Diplomata SC","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Do Hyeon","variants":["regular"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Dokdo","variants":["regular"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Domine","variants":["regular","500","600","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Donegal One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Dongle","variants":["300","regular","700"],"subsets":["korean","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Doppio One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Dorsa","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Dosis","variants":["200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"DotGothic16","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Dr Sugiyama","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Duru Sans","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"DynaPuff","variants":["regular","500","600","700"],"subsets":["cyrillic-ext","latin","latin-ext"],"category":"display"},{"family":"Dynalight","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"EB Garamond","variants":["regular","500","600","700","800","italic","500italic","600italic","700italic","800italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Eagle Lake","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"East Sea Dokdo","variants":["regular"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Eater","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Economica","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Eczar","variants":["regular","500","600","700","800"],"subsets":["devanagari","greek","greek-ext","latin","latin-ext"],"category":"serif"},{"family":"Edu NSW ACT Foundation","variants":["regular","500","600","700"],"subsets":["latin"],"category":"handwriting"},{"family":"Edu QLD Beginner","variants":["regular","500","600","700"],"subsets":["latin"],"category":"handwriting"},{"family":"Edu SA Beginner","variants":["regular","500","600","700"],"subsets":["latin"],"category":"handwriting"},{"family":"Edu TAS Beginner","variants":["regular","500","600","700"],"subsets":["latin"],"category":"handwriting"},{"family":"Edu VIC WA NT Beginner","variants":["regular","500","600","700"],"subsets":["latin"],"category":"handwriting"},{"family":"El Messiri","variants":["regular","500","600","700"],"subsets":["arabic","cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Electrolize","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Elsie","variants":["regular","900"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Elsie Swash Caps","variants":["regular","900"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Emblema One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Emilys Candy","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Encode Sans","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Encode Sans Condensed","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Encode Sans Expanded","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Encode Sans SC","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Encode Sans Semi Condensed","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Encode Sans Semi Expanded","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Engagement","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Englebert","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Enriqueta","variants":["regular","500","600","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Ephesis","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Epilogue","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Erica One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Esteban","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Estonia","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Euphoria Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Ewert","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Exo","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Exo 2","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Expletus Sans","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Explora","variants":["regular"],"subsets":["cherokee","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Fahkwang","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Familjen Grotesk","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Fanwood Text","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"Farro","variants":["300","regular","500","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Farsan","variants":["regular"],"subsets":["gujarati","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Fascinate","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Fascinate Inline","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Faster One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Fasthand","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Fauna One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Faustina","variants":["300","regular","500","600","700","800","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Federant","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Federo","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Felipa","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Fenix","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Festive","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Figtree","variants":["300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Finger Paint","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Finlandica","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"Fira Code","variants":["300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],"category":"monospace"},{"family":"Fira Mono","variants":["regular","500","700"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],"category":"monospace"},{"family":"Fira Sans","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Fira Sans Condensed","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Fira Sans Extra Condensed","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Fjalla One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Fjord One","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Flamenco","variants":["300","regular"],"subsets":["latin"],"category":"display"},{"family":"Flavors","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Fleur De Leah","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Flow Block","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Flow Circular","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Flow Rounded","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Fondamento","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Fontdiner Swanky","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Forum","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"display"},{"family":"Francois One","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Frank Ruhl Libre","variants":["300","regular","500","700","900"],"subsets":["hebrew","latin","latin-ext"],"category":"serif"},{"family":"Fraunces","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Freckle Face","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Fredericka the Great","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Fredoka","variants":["300","regular","500","600","700"],"subsets":["hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"Fredoka One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Freehand","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Fresca","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Frijole","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Fruktur","variants":["regular","italic"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Fugaz One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Fuggles","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Fuzzy Bubbles","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"GFS Didot","variants":["regular"],"subsets":["greek"],"category":"serif"},{"family":"GFS Neohellenic","variants":["regular","italic","700","700italic"],"subsets":["greek"],"category":"sans-serif"},{"family":"Gabriela","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin"],"category":"serif"},{"family":"Gaegu","variants":["300","regular","700"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Gafata","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Galada","variants":["regular"],"subsets":["bengali","latin"],"category":"display"},{"family":"Galdeano","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Galindo","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Gamja Flower","variants":["regular"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Gantari","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Gayathri","variants":["100","regular","700"],"subsets":["latin","malayalam"],"category":"sans-serif"},{"family":"Gelasio","variants":["regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Gemunu Libre","variants":["200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","sinhala"],"category":"sans-serif"},{"family":"Genos","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cherokee","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Gentium Book Basic","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Gentium Book Plus","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Gentium Plus","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Geo","variants":["regular","italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"Georama","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Geostar","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Geostar Fill","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Germania One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Gideon Roman","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Gidugu","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Gilda Display","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Girassol","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Give You Glory","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Glass Antiqua","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Glegoo","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Gloria Hallelujah","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Glory","variants":["100","200","300","regular","500","600","700","800","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Gluten","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Goblin One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Gochi Hand","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Goldman","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Gorditas","variants":["regular","700"],"subsets":["latin"],"category":"display"},{"family":"Gothic A1","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Gotu","variants":["regular"],"subsets":["devanagari","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Goudy Bookletter 1911","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Gowun Batang","variants":["regular","700"],"subsets":["korean","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Gowun Dodum","variants":["regular"],"subsets":["korean","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Graduate","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Grand Hotel","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Grandstander","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Grape Nuts","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Gravitas One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Great Vibes","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Grechen Fuemen","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Grenze","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Grenze Gotisch","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Grey Qo","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Griffy","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Gruppo","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Gudea","variants":["regular","italic","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Gugi","variants":["regular"],"subsets":["korean","latin"],"category":"display"},{"family":"Gulzar","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Gupter","variants":["regular","500","700"],"subsets":["latin"],"category":"serif"},{"family":"Gurajada","variants":["regular"],"subsets":["latin","telugu"],"category":"serif"},{"family":"Gwendolyn","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Habibi","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Hachi Maru Pop","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"handwriting"},{"family":"Hahmlet","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["korean","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Halant","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Hammersmith One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Hanalei","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Hanalei Fill","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Handlee","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Hanuman","variants":["100","300","regular","700","900"],"subsets":["khmer","latin"],"category":"serif"},{"family":"Happy Monkey","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Harmattan","variants":["regular","700"],"subsets":["arabic","latin","latin-ext"],"category":"sans-serif"},{"family":"Headland One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Heebo","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["hebrew","latin"],"category":"sans-serif"},{"family":"Henny Penny","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Hepta Slab","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Herr Von Muellerhoff","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Hi Melody","variants":["regular"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Hina Mincho","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Hind","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Hind Guntur","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","telugu"],"category":"sans-serif"},{"family":"Hind Madurai","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","tamil"],"category":"sans-serif"},{"family":"Hind Siliguri","variants":["300","regular","500","600","700"],"subsets":["bengali","latin","latin-ext"],"category":"sans-serif"},{"family":"Hind Vadodara","variants":["300","regular","500","600","700"],"subsets":["gujarati","latin","latin-ext"],"category":"sans-serif"},{"family":"Holtwood One SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Homemade Apple","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Homenaje","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Hubballi","variants":["regular"],"subsets":["kannada","latin","latin-ext"],"category":"display"},{"family":"Hurricane","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"IBM Plex Mono","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"IBM Plex Sans","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"IBM Plex Sans Arabic","variants":["100","200","300","regular","500","600","700"],"subsets":["arabic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"IBM Plex Sans Condensed","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"IBM Plex Sans Devanagari","variants":["100","200","300","regular","500","600","700"],"subsets":["cyrillic-ext","devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"IBM Plex Sans Hebrew","variants":["100","200","300","regular","500","600","700"],"subsets":["cyrillic-ext","hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"IBM Plex Sans KR","variants":["100","200","300","regular","500","600","700"],"subsets":["korean","latin","latin-ext"],"category":"sans-serif"},{"family":"IBM Plex Sans Thai","variants":["100","200","300","regular","500","600","700"],"subsets":["cyrillic-ext","latin","latin-ext","thai"],"category":"sans-serif"},{"family":"IBM Plex Sans Thai Looped","variants":["100","200","300","regular","500","600","700"],"subsets":["cyrillic-ext","latin","latin-ext","thai"],"category":"sans-serif"},{"family":"IBM Plex Serif","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"IM Fell DW Pica","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell DW Pica SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell Double Pica","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell Double Pica SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell English","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell English SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell French Canon","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell French Canon SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell Great Primer","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"IM Fell Great Primer SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Ibarra Real Nova","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Iceberg","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Iceland","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Imbue","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Imperial Script","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Imprima","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Inconsolata","variants":["200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Inder","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Indie Flower","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Ingrid Darling","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Inika","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Inknut Antiqua","variants":["300","regular","500","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Inria Sans","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Inria Serif","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Inspiration","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Inter","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Inter Tight","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Irish Grover","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Island Moments","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Istok Web","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"Italiana","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Italianno","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Itim","variants":["regular"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"handwriting"},{"family":"Jacques Francois","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Jacques Francois Shadow","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Jaldi","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"JetBrains Mono","variants":["100","200","300","regular","500","600","700","800","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Jim Nightshade","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Joan","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Jockey One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Jolly Lodger","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Jomhuria","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Jomolhari","variants":["regular"],"subsets":["latin","tibetan"],"category":"serif"},{"family":"Josefin Sans","variants":["100","200","300","regular","500","600","700","100italic","200italic","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Josefin Slab","variants":["100","200","300","regular","500","600","700","100italic","200italic","300italic","italic","500italic","600italic","700italic"],"subsets":["latin"],"category":"serif"},{"family":"Jost","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Joti One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Jua","variants":["regular"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Judson","variants":["regular","italic","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Julee","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Julius Sans One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Junge","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Jura","variants":["300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","kayah-li","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Just Another Hand","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Just Me Again Down Here","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"K2D","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Kadwa","variants":["regular","700"],"subsets":["devanagari","latin"],"category":"serif"},{"family":"Kaisei Decol","variants":["regular","500","700"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Kaisei HarunoUmi","variants":["regular","500","700"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Kaisei Opti","variants":["regular","500","700"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Kaisei Tokumin","variants":["regular","500","700","800"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Kalam","variants":["300","regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"handwriting"},{"family":"Kameron","variants":["regular","700"],"subsets":["latin"],"category":"serif"},{"family":"Kanit","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Kantumruy","variants":["300","regular","700"],"subsets":["khmer"],"category":"sans-serif"},{"family":"Kantumruy Pro","variants":["100","200","300","regular","500","600","700","100italic","200italic","300italic","italic","500italic","600italic","700italic"],"subsets":["khmer","latin","latin-ext"],"category":"sans-serif"},{"family":"Karantina","variants":["300","regular","700"],"subsets":["hebrew","latin","latin-ext"],"category":"display"},{"family":"Karla","variants":["200","300","regular","500","600","700","800","200italic","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Karma","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Katibeh","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Kaushan Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Kavivanar","variants":["regular"],"subsets":["latin","latin-ext","tamil"],"category":"handwriting"},{"family":"Kavoon","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Kdam Thmor Pro","variants":["regular"],"subsets":["khmer","latin","latin-ext"],"category":"sans-serif"},{"family":"Keania One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Kelly Slab","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"display"},{"family":"Kenia","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Khand","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Khmer","variants":["regular"],"subsets":["khmer"],"category":"display"},{"family":"Khula","variants":["300","regular","600","700","800"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Kings","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Kirang Haerang","variants":["regular"],"subsets":["korean","latin"],"category":"display"},{"family":"Kite One","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Kiwi Maru","variants":["300","regular","500"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Klee One","variants":["regular","600"],"subsets":["cyrillic","greek-ext","japanese","latin","latin-ext"],"category":"handwriting"},{"family":"Knewave","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"KoHo","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Kodchasan","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Koh Santepheap","variants":["100","300","regular","700","900"],"subsets":["khmer","latin"],"category":"display"},{"family":"Kolker Brush","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Kosugi","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Kosugi Maru","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Kotta One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Koulen","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Kranky","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Kreon","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Kristi","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Krona One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Krub","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Kufam","variants":["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Kulim Park","variants":["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Kumar One","variants":["regular"],"subsets":["gujarati","latin","latin-ext"],"category":"display"},{"family":"Kumar One Outline","variants":["regular"],"subsets":["gujarati","latin","latin-ext"],"category":"display"},{"family":"Kumbh Sans","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Kurale","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","devanagari","latin","latin-ext"],"category":"serif"},{"family":"La Belle Aurore","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Lacquer","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Laila","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Lakki Reddy","variants":["regular"],"subsets":["latin","telugu"],"category":"handwriting"},{"family":"Lalezar","variants":["regular"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Lancelot","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Langar","variants":["regular"],"subsets":["gurmukhi","latin","latin-ext"],"category":"display"},{"family":"Lateef","variants":["200","300","regular","500","600","700","800"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Lato","variants":["100","100italic","300","300italic","regular","italic","700","700italic","900","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Lavishly Yours","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"League Gothic","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"League Script","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"League Spartan","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Leckerli One","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Ledger","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"serif"},{"family":"Lekton","variants":["regular","italic","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Lemon","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Lemonada","variants":["300","regular","500","600","700"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Lexend","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Deca","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Exa","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Giga","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Mega","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Peta","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Tera","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lexend Zetta","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Libre Barcode 128","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Barcode 128 Text","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Barcode 39","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Barcode 39 Extended","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Barcode 39 Extended Text","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Barcode 39 Text","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Barcode EAN13 Text","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Libre Baskerville","variants":["regular","italic","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Libre Bodoni","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Libre Caslon Display","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Libre Caslon Text","variants":["regular","italic","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Libre Franklin","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Licorice","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Life Savers","variants":["regular","700","800"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Lilita One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Lily Script One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Limelight","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Linden Hill","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"Literata","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Liu Jian Mao Cao","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"handwriting"},{"family":"Livvic","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","900","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Lobster","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Lobster Two","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"display"},{"family":"Londrina Outline","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Londrina Shadow","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Londrina Sketch","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Londrina Solid","variants":["100","300","regular","900"],"subsets":["latin"],"category":"display"},{"family":"Long Cang","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"handwriting"},{"family":"Lora","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Love Light","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Love Ya Like A Sister","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Loved by the King","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Lovers Quarrel","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Luckiest Guy","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Lusitana","variants":["regular","700"],"subsets":["latin"],"category":"serif"},{"family":"Lustria","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Luxurious Roman","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Luxurious Script","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"M PLUS 1","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["japanese","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"M PLUS 1 Code","variants":["100","200","300","regular","500","600","700"],"subsets":["japanese","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"M PLUS 1p","variants":["100","300","regular","500","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","japanese","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"M PLUS 2","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["japanese","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"M PLUS Code Latin","variants":["100","200","300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"M PLUS Rounded 1c","variants":["100","300","regular","500","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","japanese","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Ma Shan Zheng","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"handwriting"},{"family":"Macondo","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Macondo Swash Caps","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Mada","variants":["200","300","regular","500","600","700","900"],"subsets":["arabic","latin"],"category":"sans-serif"},{"family":"Magra","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Maiden Orange","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Maitree","variants":["200","300","regular","500","600","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"serif"},{"family":"Major Mono Display","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Mako","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Mali","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"handwriting"},{"family":"Mallanna","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Mandali","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Manjari","variants":["100","regular","700"],"subsets":["latin","latin-ext","malayalam"],"category":"sans-serif"},{"family":"Manrope","variants":["200","300","regular","500","600","700","800"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Mansalva","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Manuale","variants":["300","regular","500","600","700","800","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Marcellus","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Marcellus SC","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Marck Script","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"handwriting"},{"family":"Margarine","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Markazi Text","variants":["regular","500","600","700"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Marko One","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Marmelad","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Martel","variants":["200","300","regular","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Martel Sans","variants":["200","300","regular","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Marvel","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"Mate","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"Mate SC","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Maven Pro","variants":["regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"McLaren","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Mea Culpa","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Meddon","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"MedievalSharp","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Medula One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Meera Inimai","variants":["regular"],"subsets":["latin","tamil"],"category":"sans-serif"},{"family":"Megrim","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Meie Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Meow Script","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Merienda","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Merienda One","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Merriweather","variants":["300","300italic","regular","italic","700","700italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Merriweather Sans","variants":["300","regular","500","600","700","800","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Metal","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Metal Mania","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Metamorphous","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Metrophobic","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Michroma","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Milonga","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Miltonian","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Miltonian Tattoo","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Mina","variants":["regular","700"],"subsets":["bengali","latin","latin-ext"],"category":"sans-serif"},{"family":"Mingzat","variants":["regular"],"subsets":["latin","latin-ext","lepcha"],"category":"sans-serif"},{"family":"Miniver","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Miriam Libre","variants":["regular","700"],"subsets":["hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"Mirza","variants":["regular","500","600","700"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Miss Fajardose","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Mitr","variants":["200","300","regular","500","600","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Mochiy Pop One","variants":["regular"],"subsets":["japanese","latin"],"category":"sans-serif"},{"family":"Mochiy Pop P One","variants":["regular"],"subsets":["japanese","latin"],"category":"sans-serif"},{"family":"Modak","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"display"},{"family":"Modern Antiqua","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Mogra","variants":["regular"],"subsets":["gujarati","latin","latin-ext"],"category":"display"},{"family":"Mohave","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Molengo","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Molle","variants":["italic"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Monda","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Monofett","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Monoton","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Monsieur La Doulaise","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Montaga","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Montagu Slab","variants":["100","200","300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"MonteCarlo","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Montez","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Montserrat","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Montserrat Alternates","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Montserrat Subrayada","variants":["regular","700"],"subsets":["latin"],"category":"sans-serif"},{"family":"Moo Lah Lah","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Moon Dance","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Moul","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Moulpali","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Mountains of Christmas","variants":["regular","700"],"subsets":["latin"],"category":"display"},{"family":"Mouse Memoirs","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Mr Bedfort","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Mr Dafoe","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Mr De Haviland","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Mrs Saint Delafield","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Mrs Sheppards","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Ms Madi","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Mukta","variants":["200","300","regular","500","600","700","800"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Mukta Mahee","variants":["200","300","regular","500","600","700","800"],"subsets":["gurmukhi","latin","latin-ext"],"category":"sans-serif"},{"family":"Mukta Malar","variants":["200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","tamil"],"category":"sans-serif"},{"family":"Mukta Vaani","variants":["200","300","regular","500","600","700","800"],"subsets":["gujarati","latin","latin-ext"],"category":"sans-serif"},{"family":"Mulish","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Murecho","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"MuseoModerno","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"My Soul","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Mystery Quest","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"NTR","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Nabla","variants":["regular"],"subsets":["cyrillic-ext","latin","latin-ext","math","vietnamese"],"category":"display"},{"family":"Nanum Brush Script","variants":["regular"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Nanum Gothic","variants":["regular","700","800"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Nanum Gothic Coding","variants":["regular","700"],"subsets":["korean","latin"],"category":"monospace"},{"family":"Nanum Myeongjo","variants":["regular","700","800"],"subsets":["korean","latin"],"category":"serif"},{"family":"Nanum Pen Script","variants":["regular"],"subsets":["korean","latin"],"category":"handwriting"},{"family":"Neonderthaw","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Nerko One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Neucha","variants":["regular"],"subsets":["cyrillic","latin"],"category":"handwriting"},{"family":"Neuton","variants":["200","300","regular","italic","700","800"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"New Rocker","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"New Tegomin","variants":["regular"],"subsets":["japanese","latin","latin-ext"],"category":"serif"},{"family":"News Cycle","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Newsreader","variants":["200","300","regular","500","600","700","800","200italic","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Niconne","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Niramit","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Nixie One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nobile","variants":["regular","italic","500","500italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Nokora","variants":["100","300","regular","700","900"],"subsets":["khmer","latin"],"category":"sans-serif"},{"family":"Norican","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Nosifer","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Notable","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Nothing You Could Do","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Noticia Text","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Noto Color Emoji","variants":["regular"],"subsets":["emoji"],"category":"sans-serif"},{"family":"Noto Emoji","variants":["300","regular","500","600","700"],"subsets":["emoji"],"category":"sans-serif"},{"family":"Noto Kufi Arabic","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["arabic"],"category":"sans-serif"},{"family":"Noto Music","variants":["regular"],"subsets":["music"],"category":"sans-serif"},{"family":"Noto Naskh Arabic","variants":["regular","500","600","700"],"subsets":["arabic"],"category":"serif"},{"family":"Noto Nastaliq Urdu","variants":["regular","500","600","700"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Noto Rashi Hebrew","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["hebrew","latin","latin-ext"],"category":"serif"},{"family":"Noto Sans","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","devanagari","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Noto Sans Adlam","variants":["regular","500","600","700"],"subsets":["adlam","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Adlam Unjoined","variants":["regular","500","600","700"],"subsets":["adlam","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Anatolian Hieroglyphs","variants":["regular"],"subsets":["anatolian-hieroglyphs"],"category":"sans-serif"},{"family":"Noto Sans Arabic","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["arabic"],"category":"sans-serif"},{"family":"Noto Sans Armenian","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["armenian","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Avestan","variants":["regular"],"subsets":["avestan","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Balinese","variants":["regular","500","600","700"],"subsets":["balinese","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Bamum","variants":["regular","500","600","700"],"subsets":["bamum"],"category":"sans-serif"},{"family":"Noto Sans Bassa Vah","variants":["regular"],"subsets":["bassa-vah"],"category":"sans-serif"},{"family":"Noto Sans Batak","variants":["regular"],"subsets":["batak","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Bengali","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["bengali","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Bhaiksuki","variants":["regular"],"subsets":["bhaiksuki"],"category":"sans-serif"},{"family":"Noto Sans Brahmi","variants":["regular"],"subsets":["brahmi"],"category":"sans-serif"},{"family":"Noto Sans Buginese","variants":["regular"],"subsets":["buginese"],"category":"sans-serif"},{"family":"Noto Sans Buhid","variants":["regular"],"subsets":["buhid","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Canadian Aboriginal","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["canadian-aboriginal","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Carian","variants":["regular"],"subsets":["carian"],"category":"sans-serif"},{"family":"Noto Sans Caucasian Albanian","variants":["regular"],"subsets":["caucasian-albanian"],"category":"sans-serif"},{"family":"Noto Sans Chakma","variants":["regular"],"subsets":["chakma"],"category":"sans-serif"},{"family":"Noto Sans Cham","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cham","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Cherokee","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cherokee","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Coptic","variants":["regular"],"subsets":["coptic","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Cuneiform","variants":["regular"],"subsets":["cuneiform"],"category":"sans-serif"},{"family":"Noto Sans Cypriot","variants":["regular"],"subsets":["cypriot"],"category":"sans-serif"},{"family":"Noto Sans Deseret","variants":["regular"],"subsets":["deseret"],"category":"sans-serif"},{"family":"Noto Sans Devanagari","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Display","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Noto Sans Duployan","variants":["regular"],"subsets":["duployan"],"category":"sans-serif"},{"family":"Noto Sans Egyptian Hieroglyphs","variants":["regular"],"subsets":["egyptian-hieroglyphs"],"category":"sans-serif"},{"family":"Noto Sans Elbasan","variants":["regular"],"subsets":["elbasan"],"category":"sans-serif"},{"family":"Noto Sans Elymaic","variants":["regular"],"subsets":["elymaic"],"category":"sans-serif"},{"family":"Noto Sans Ethiopic","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["ethiopic","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Georgian","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["georgian","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Glagolitic","variants":["regular"],"subsets":["glagolitic"],"category":"sans-serif"},{"family":"Noto Sans Gothic","variants":["regular"],"subsets":["gothic"],"category":"sans-serif"},{"family":"Noto Sans Grantha","variants":["regular"],"subsets":["grantha","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Gujarati","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["gujarati","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Gunjala Gondi","variants":["regular"],"subsets":["gunjala-gondi"],"category":"sans-serif"},{"family":"Noto Sans Gurmukhi","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["gurmukhi","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans HK","variants":["100","300","regular","500","700","900"],"subsets":["chinese-hongkong","latin"],"category":"sans-serif"},{"family":"Noto Sans Hanifi Rohingya","variants":["regular","500","600","700"],"subsets":["hanifi-rohingya"],"category":"sans-serif"},{"family":"Noto Sans Hanunoo","variants":["regular"],"subsets":["hanunoo"],"category":"sans-serif"},{"family":"Noto Sans Hatran","variants":["regular"],"subsets":["hatran"],"category":"sans-serif"},{"family":"Noto Sans Hebrew","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Imperial Aramaic","variants":["regular"],"subsets":["imperial-aramaic"],"category":"sans-serif"},{"family":"Noto Sans Indic Siyaq Numbers","variants":["regular"],"subsets":["indic-siyaq-numbers"],"category":"sans-serif"},{"family":"Noto Sans Inscriptional Pahlavi","variants":["regular"],"subsets":["inscriptional-pahlavi"],"category":"sans-serif"},{"family":"Noto Sans Inscriptional Parthian","variants":["regular"],"subsets":["inscriptional-parthian"],"category":"sans-serif"},{"family":"Noto Sans JP","variants":["100","300","regular","500","700","900"],"subsets":["japanese","latin"],"category":"sans-serif"},{"family":"Noto Sans Javanese","variants":["regular","500","600","700"],"subsets":["javanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans KR","variants":["100","300","regular","500","700","900"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Noto Sans Kaithi","variants":["regular"],"subsets":["kaithi"],"category":"sans-serif"},{"family":"Noto Sans Kannada","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["kannada","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Kayah Li","variants":["regular","500","600","700"],"subsets":["kayah-li"],"category":"sans-serif"},{"family":"Noto Sans Kharoshthi","variants":["regular"],"subsets":["kharoshthi"],"category":"sans-serif"},{"family":"Noto Sans Khmer","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["khmer","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Khojki","variants":["regular"],"subsets":["khojki"],"category":"sans-serif"},{"family":"Noto Sans Khudawadi","variants":["regular"],"subsets":["khudawadi"],"category":"sans-serif"},{"family":"Noto Sans Lao","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["lao","latin","latin-ext"],"category":"sans-serif"},{"family":"Noto Sans Lepcha","variants":["regular"],"subsets":["lepcha"],"category":"sans-serif"},{"family":"Noto Sans Limbu","variants":["regular"],"subsets":["latin","latin-ext","limbu"],"category":"sans-serif"},{"family":"Noto Sans Linear A","variants":["regular"],"subsets":["linear-a"],"category":"sans-serif"},{"family":"Noto Sans Linear B","variants":["regular"],"subsets":["linear-b"],"category":"sans-serif"},{"family":"Noto Sans Lisu","variants":["regular","500","600","700"],"subsets":["latin","latin-ext","lisu"],"category":"sans-serif"},{"family":"Noto Sans Lycian","variants":["regular"],"subsets":["lycian"],"category":"sans-serif"},{"family":"Noto Sans Lydian","variants":["regular"],"subsets":["lydian"],"category":"sans-serif"},{"family":"Noto Sans Mahajani","variants":["regular"],"subsets":["mahajani"],"category":"sans-serif"},{"family":"Noto Sans Malayalam","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","malayalam"],"category":"sans-serif"},{"family":"Noto Sans Mandaic","variants":["regular"],"subsets":["mandaic"],"category":"sans-serif"},{"family":"Noto Sans Manichaean","variants":["regular"],"subsets":["manichaean"],"category":"sans-serif"},{"family":"Noto Sans Marchen","variants":["regular"],"subsets":["marchen"],"category":"sans-serif"},{"family":"Noto Sans Masaram Gondi","variants":["regular"],"subsets":["masaram-gondi"],"category":"sans-serif"},{"family":"Noto Sans Math","variants":["regular"],"subsets":["math"],"category":"sans-serif"},{"family":"Noto Sans Mayan Numerals","variants":["regular"],"subsets":["mayan-numerals"],"category":"sans-serif"},{"family":"Noto Sans Medefaidrin","variants":["regular","500","600","700"],"subsets":["medefaidrin"],"category":"sans-serif"},{"family":"Noto Sans Meetei Mayek","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","meetei-mayek"],"category":"sans-serif"},{"family":"Noto Sans Meroitic","variants":["regular"],"subsets":["meroitic"],"category":"sans-serif"},{"family":"Noto Sans Miao","variants":["regular"],"subsets":["latin","latin-ext","miao"],"category":"sans-serif"},{"family":"Noto Sans Modi","variants":["regular"],"subsets":["modi"],"category":"sans-serif"},{"family":"Noto Sans Mongolian","variants":["regular"],"subsets":["mongolian"],"category":"sans-serif"},{"family":"Noto Sans Mono","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Noto Sans Mro","variants":["regular"],"subsets":["mro"],"category":"sans-serif"},{"family":"Noto Sans Multani","variants":["regular"],"subsets":["multani"],"category":"sans-serif"},{"family":"Noto Sans Myanmar","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["myanmar"],"category":"sans-serif"},{"family":"Noto Sans N Ko","variants":["regular"],"subsets":["nko"],"category":"sans-serif"},{"family":"Noto Sans Nabataean","variants":["regular"],"subsets":["nabataean"],"category":"sans-serif"},{"family":"Noto Sans New Tai Lue","variants":["regular"],"subsets":["new-tai-lue"],"category":"sans-serif"},{"family":"Noto Sans Newa","variants":["regular"],"subsets":["newa"],"category":"sans-serif"},{"family":"Noto Sans Nushu","variants":["regular"],"subsets":["nushu"],"category":"sans-serif"},{"family":"Noto Sans Ogham","variants":["regular"],"subsets":["ogham"],"category":"sans-serif"},{"family":"Noto Sans Ol Chiki","variants":["regular","500","600","700"],"subsets":["ol-chiki"],"category":"sans-serif"},{"family":"Noto Sans Old Hungarian","variants":["regular"],"subsets":["old-hungarian"],"category":"sans-serif"},{"family":"Noto Sans Old Italic","variants":["regular"],"subsets":["old-italic"],"category":"sans-serif"},{"family":"Noto Sans Old North Arabian","variants":["regular"],"subsets":["old-north-arabian"],"category":"sans-serif"},{"family":"Noto Sans Old Permic","variants":["regular"],"subsets":["old-permic"],"category":"sans-serif"},{"family":"Noto Sans Old Persian","variants":["regular"],"subsets":["old-persian"],"category":"sans-serif"},{"family":"Noto Sans Old Sogdian","variants":["regular"],"subsets":["old-sogdian"],"category":"sans-serif"},{"family":"Noto Sans Old South Arabian","variants":["regular"],"subsets":["old-south-arabian"],"category":"sans-serif"},{"family":"Noto Sans Old Turkic","variants":["regular"],"subsets":["old-turkic"],"category":"sans-serif"},{"family":"Noto Sans Oriya","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","oriya"],"category":"sans-serif"},{"family":"Noto Sans Osage","variants":["regular"],"subsets":["osage"],"category":"sans-serif"},{"family":"Noto Sans Osmanya","variants":["regular"],"subsets":["osmanya"],"category":"sans-serif"},{"family":"Noto Sans Pahawh Hmong","variants":["regular"],"subsets":["pahawh-hmong"],"category":"sans-serif"},{"family":"Noto Sans Palmyrene","variants":["regular"],"subsets":["palmyrene"],"category":"sans-serif"},{"family":"Noto Sans Pau Cin Hau","variants":["regular"],"subsets":["pau-cin-hau"],"category":"sans-serif"},{"family":"Noto Sans Phags Pa","variants":["regular"],"subsets":["phags-pa"],"category":"sans-serif"},{"family":"Noto Sans Phoenician","variants":["regular"],"subsets":["phoenician"],"category":"sans-serif"},{"family":"Noto Sans Psalter Pahlavi","variants":["regular"],"subsets":["psalter-pahlavi"],"category":"sans-serif"},{"family":"Noto Sans Rejang","variants":["regular"],"subsets":["rejang"],"category":"sans-serif"},{"family":"Noto Sans Runic","variants":["regular"],"subsets":["runic"],"category":"sans-serif"},{"family":"Noto Sans SC","variants":["100","300","regular","500","700","900"],"subsets":["chinese-simplified","latin"],"category":"sans-serif"},{"family":"Noto Sans Samaritan","variants":["regular"],"subsets":["samaritan"],"category":"sans-serif"},{"family":"Noto Sans Saurashtra","variants":["regular"],"subsets":["saurashtra"],"category":"sans-serif"},{"family":"Noto Sans Sharada","variants":["regular"],"subsets":["sharada"],"category":"sans-serif"},{"family":"Noto Sans Shavian","variants":["regular"],"subsets":["shavian"],"category":"sans-serif"},{"family":"Noto Sans Siddham","variants":["regular"],"subsets":["siddham"],"category":"sans-serif"},{"family":"Noto Sans Sinhala","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","sinhala"],"category":"sans-serif"},{"family":"Noto Sans Sogdian","variants":["regular"],"subsets":["sogdian"],"category":"sans-serif"},{"family":"Noto Sans Sora Sompeng","variants":["regular","500","600","700"],"subsets":["sora-sompeng"],"category":"sans-serif"},{"family":"Noto Sans Soyombo","variants":["regular"],"subsets":["soyombo"],"category":"sans-serif"},{"family":"Noto Sans Sundanese","variants":["regular","500","600","700"],"subsets":["sundanese"],"category":"sans-serif"},{"family":"Noto Sans Syloti Nagri","variants":["regular"],"subsets":["syloti-nagri"],"category":"sans-serif"},{"family":"Noto Sans Symbols","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","symbols"],"category":"sans-serif"},{"family":"Noto Sans Symbols 2","variants":["regular"],"subsets":["symbols"],"category":"sans-serif"},{"family":"Noto Sans Syriac","variants":["100","regular","900"],"subsets":["syriac"],"category":"sans-serif"},{"family":"Noto Sans TC","variants":["100","300","regular","500","700","900"],"subsets":["chinese-traditional","latin"],"category":"sans-serif"},{"family":"Noto Sans Tagalog","variants":["regular"],"subsets":["tagalog"],"category":"sans-serif"},{"family":"Noto Sans Tagbanwa","variants":["regular"],"subsets":["tagbanwa"],"category":"sans-serif"},{"family":"Noto Sans Tai Le","variants":["regular"],"subsets":["tai-le"],"category":"sans-serif"},{"family":"Noto Sans Tai Tham","variants":["regular","500","600","700"],"subsets":["tai-tham"],"category":"sans-serif"},{"family":"Noto Sans Tai Viet","variants":["regular"],"subsets":["tai-viet"],"category":"sans-serif"},{"family":"Noto Sans Takri","variants":["regular"],"subsets":["takri"],"category":"sans-serif"},{"family":"Noto Sans Tamil","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","tamil"],"category":"sans-serif"},{"family":"Noto Sans Tamil Supplement","variants":["regular"],"subsets":["tamil-supplement"],"category":"sans-serif"},{"family":"Noto Sans Telugu","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","telugu"],"category":"sans-serif"},{"family":"Noto Sans Thaana","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["thaana"],"category":"sans-serif"},{"family":"Noto Sans Thai","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","thai"],"category":"sans-serif"},{"family":"Noto Sans Thai Looped","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["thai"],"category":"sans-serif"},{"family":"Noto Sans Tifinagh","variants":["regular"],"subsets":["tifinagh"],"category":"sans-serif"},{"family":"Noto Sans Tirhuta","variants":["regular"],"subsets":["tirhuta"],"category":"sans-serif"},{"family":"Noto Sans Ugaritic","variants":["regular"],"subsets":["ugaritic"],"category":"sans-serif"},{"family":"Noto Sans Vai","variants":["regular"],"subsets":["latin","latin-ext","vai"],"category":"sans-serif"},{"family":"Noto Sans Wancho","variants":["regular"],"subsets":["latin","latin-ext","wancho"],"category":"sans-serif"},{"family":"Noto Sans Warang Citi","variants":["regular"],"subsets":["latin","latin-ext","warang-citi"],"category":"sans-serif"},{"family":"Noto Sans Yi","variants":["regular"],"subsets":["yi"],"category":"sans-serif"},{"family":"Noto Sans Zanabazar Square","variants":["regular"],"subsets":["zanabazar-square"],"category":"sans-serif"},{"family":"Noto Serif","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Noto Serif Ahom","variants":["regular"],"subsets":["ahom","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Armenian","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["armenian","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Balinese","variants":["regular"],"subsets":["balinese","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Bengali","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["bengali","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Devanagari","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Display","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Noto Serif Dogra","variants":["regular"],"subsets":["dogra"],"category":"serif"},{"family":"Noto Serif Ethiopic","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["ethiopic","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Georgian","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["georgian","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Grantha","variants":["regular"],"subsets":["grantha","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Gujarati","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["gujarati","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Gurmukhi","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["gurmukhi","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif HK","variants":["200","300","regular","500","600","700","800","900"],"subsets":["chinese-hongkong","cyrillic","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Noto Serif Hebrew","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["hebrew","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif JP","variants":["200","300","regular","500","600","700","900"],"subsets":["japanese","latin"],"category":"serif"},{"family":"Noto Serif KR","variants":["200","300","regular","500","600","700","900"],"subsets":["korean","latin"],"category":"serif"},{"family":"Noto Serif Kannada","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["kannada","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Khmer","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["khmer","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Lao","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["lao","latin","latin-ext"],"category":"serif"},{"family":"Noto Serif Malayalam","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","malayalam"],"category":"serif"},{"family":"Noto Serif Myanmar","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["myanmar"],"category":"serif"},{"family":"Noto Serif Nyiakeng Puachue Hmong","variants":["regular","500","600","700"],"subsets":["nyiakeng-puachue-hmong"],"category":"serif"},{"family":"Noto Serif SC","variants":["200","300","regular","500","600","700","900"],"subsets":["chinese-simplified","latin"],"category":"serif"},{"family":"Noto Serif Sinhala","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","sinhala"],"category":"serif"},{"family":"Noto Serif TC","variants":["200","300","regular","500","600","700","900"],"subsets":["chinese-traditional","latin"],"category":"serif"},{"family":"Noto Serif Tamil","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","tamil"],"category":"serif"},{"family":"Noto Serif Tangut","variants":["regular"],"subsets":["tangut"],"category":"serif"},{"family":"Noto Serif Telugu","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","telugu"],"category":"serif"},{"family":"Noto Serif Thai","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","thai"],"category":"serif"},{"family":"Noto Serif Tibetan","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["tibetan"],"category":"serif"},{"family":"Noto Serif Yezidi","variants":["regular","500","600","700"],"subsets":["yezidi"],"category":"serif"},{"family":"Noto Traditional Nushu","variants":["regular"],"subsets":["nushu"],"category":"sans-serif"},{"family":"Nova Cut","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nova Flat","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nova Mono","variants":["regular"],"subsets":["greek","latin"],"category":"monospace"},{"family":"Nova Oval","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nova Round","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nova Script","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nova Slim","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Nova Square","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Numans","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Nunito","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Nunito Sans","variants":["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Nuosu SIL","variants":["regular"],"subsets":["latin","latin-ext","yi"],"category":"serif"},{"family":"Odibee Sans","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Odor Mean Chey","variants":["regular"],"subsets":["khmer","latin"],"category":"serif"},{"family":"Offside","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Oi","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","tamil","vietnamese"],"category":"display"},{"family":"Old Standard TT","variants":["regular","italic","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Oldenburg","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Ole","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Oleo Script","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Oleo Script Swash Caps","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Oooh Baby","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Open Sans","variants":["300","regular","500","600","700","800","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Oranienbaum","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"serif"},{"family":"Orbitron","variants":["regular","500","600","700","800","900"],"subsets":["latin"],"category":"sans-serif"},{"family":"Oregano","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Orelega One","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"display"},{"family":"Orienta","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Original Surfer","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Oswald","variants":["200","300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Outfit","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin"],"category":"sans-serif"},{"family":"Over the Rainbow","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Overlock","variants":["regular","italic","700","700italic","900","900italic"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Overlock SC","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Overpass","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Overpass Mono","variants":["300","regular","500","600","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Ovo","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Oxanium","variants":["200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Oxygen","variants":["300","regular","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Oxygen Mono","variants":["regular"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"PT Mono","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"monospace"},{"family":"PT Sans","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"PT Sans Caption","variants":["regular","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"PT Sans Narrow","variants":["regular","700"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"PT Serif","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"serif"},{"family":"PT Serif Caption","variants":["regular","italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"serif"},{"family":"Pacifico","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Padauk","variants":["regular","700"],"subsets":["latin","latin-ext","myanmar"],"category":"sans-serif"},{"family":"Palanquin","variants":["100","200","300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Palanquin Dark","variants":["regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Pangolin","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Paprika","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Parisienne","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Passero One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Passion One","variants":["regular","700","900"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Passions Conflict","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Pathway Gothic One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Patrick Hand","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Patrick Hand SC","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Pattaya","variants":["regular"],"subsets":["cyrillic","latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Patua One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Pavanam","variants":["regular"],"subsets":["latin","latin-ext","tamil"],"category":"sans-serif"},{"family":"Paytone One","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Peddana","variants":["regular"],"subsets":["latin","telugu"],"category":"serif"},{"family":"Peralta","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Permanent Marker","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Petemoss","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Petit Formal Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Petrona","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Philosopher","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","vietnamese"],"category":"sans-serif"},{"family":"Piazzolla","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Piedra","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Pinyon Script","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Pirata One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Plaster","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Play","variants":["regular","700"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Playball","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Playfair Display","variants":["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Playfair Display SC","variants":["regular","italic","700","700italic","900","900italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Plus Jakarta Sans","variants":["200","300","regular","500","600","700","800","200italic","300italic","italic","500italic","600italic","700italic","800italic"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Podkova","variants":["regular","500","600","700","800"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Poiret One","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"display"},{"family":"Poller One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Poly","variants":["regular","italic"],"subsets":["latin"],"category":"serif"},{"family":"Pompiere","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Pontano Sans","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Poor Story","variants":["regular"],"subsets":["korean","latin"],"category":"display"},{"family":"Poppins","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Port Lligat Sans","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Port Lligat Slab","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Potta One","variants":["regular"],"subsets":["japanese","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Pragati Narrow","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Praise","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Prata","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","vietnamese"],"category":"serif"},{"family":"Preahvihear","variants":["regular"],"subsets":["khmer","latin"],"category":"sans-serif"},{"family":"Press Start 2P","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext"],"category":"display"},{"family":"Pridi","variants":["200","300","regular","500","600","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"serif"},{"family":"Princess Sofia","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Prociono","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Prompt","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Prosto One","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"display"},{"family":"Proza Libre","variants":["regular","italic","500","500italic","600","600italic","700","700italic","800","800italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Public Sans","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Puppies Play","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Puritan","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"Purple Purse","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Qahiri","variants":["regular"],"subsets":["arabic","latin"],"category":"sans-serif"},{"family":"Quando","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Quantico","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"sans-serif"},{"family":"Quattrocento","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Quattrocento Sans","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Questrial","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Quicksand","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Quintessential","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Qwigley","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Qwitcher Grypen","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Racing Sans One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Radio Canada","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Radley","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Rajdhani","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Rakkas","variants":["regular"],"subsets":["arabic","latin","latin-ext"],"category":"display"},{"family":"Raleway","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Raleway Dots","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Ramabhadra","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Ramaraja","variants":["regular"],"subsets":["latin","telugu"],"category":"serif"},{"family":"Rambla","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Rammetto One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Rampart One","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"display"},{"family":"Ranchers","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Rancho","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Ranga","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"display"},{"family":"Rasa","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["gujarati","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Rationale","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Ravi Prakash","variants":["regular"],"subsets":["latin","telugu"],"category":"display"},{"family":"Readex Pro","variants":["200","300","regular","500","600","700"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Recursive","variants":["300","regular","500","600","700","800","900"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Red Hat Display","variants":["300","regular","500","600","700","800","900","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Red Hat Mono","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"Red Hat Text","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Red Rose","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Redacted","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Redacted Script","variants":["300","regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Redressed","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Reem Kufi","variants":["regular","500","600","700"],"subsets":["arabic","latin"],"category":"sans-serif"},{"family":"Reem Kufi Fun","variants":["regular","500","600","700"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Reem Kufi Ink","variants":["regular"],"subsets":["arabic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Reenie Beanie","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Reggae One","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"display"},{"family":"Revalia","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Rhodium Libre","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Ribeye","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Ribeye Marrow","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Righteous","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Risque","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Road Rage","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Roboto","variants":["100","100italic","300","300italic","regular","italic","500","500italic","700","700italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Roboto Condensed","variants":["300","300italic","regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Roboto Flex","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Roboto Mono","variants":["100","200","300","regular","500","600","700","100italic","200italic","300italic","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Roboto Serif","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Roboto Slab","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Rochester","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Rock Salt","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"RocknRoll One","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Rokkitt","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Romanesco","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Ropa Sans","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Rosario","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Rosarivo","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Rouge Script","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Rowdies","variants":["300","regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Rozha One","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Rubik","variants":["300","regular","500","600","700","800","900","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"Rubik Beastly","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Bubbles","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Burned","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Dirt","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Distressed","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Glitch","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Iso","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Marker Hatch","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Maze","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Microbe","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Mono One","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Rubik Moonrocks","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Puddles","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Rubik Wet Paint","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","hebrew","latin","latin-ext"],"category":"display"},{"family":"Ruda","variants":["regular","500","600","700","800","900"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Rufina","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Ruge Boogie","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Ruluko","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Rum Raisin","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Ruslan Display","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"display"},{"family":"Russo One","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Ruthie","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Rye","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"STIX Two Text","variants":["regular","500","600","700","italic","500italic","600italic","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Sacramento","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Sahitya","variants":["regular","700"],"subsets":["devanagari","latin"],"category":"serif"},{"family":"Sail","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Saira","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Saira Condensed","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Saira Extra Condensed","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Saira Semi Condensed","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Saira Stencil One","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Salsa","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Sanchez","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Sancreek","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Sansita","variants":["regular","italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Sansita Swashed","variants":["300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Sarabun","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"Sarala","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Sarina","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Sarpanch","variants":["regular","500","600","700","800","900"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Sassy Frass","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Satisfy","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Sawarabi Gothic","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Sawarabi Mincho","variants":["regular"],"subsets":["japanese","latin","latin-ext"],"category":"serif"},{"family":"Scada","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"Scheherazade New","variants":["regular","700"],"subsets":["arabic","latin","latin-ext"],"category":"serif"},{"family":"Schoolbell","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Scope One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Seaweed Script","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Secular One","variants":["regular"],"subsets":["hebrew","latin","latin-ext"],"category":"sans-serif"},{"family":"Sedgwick Ave","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Sedgwick Ave Display","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Sen","variants":["regular","700","800"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Send Flowers","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Sevillana","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Seymour One","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Shadows Into Light","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Shadows Into Light Two","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Shalimar","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Shanti","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Share","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Share Tech","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Share Tech Mono","variants":["regular"],"subsets":["latin"],"category":"monospace"},{"family":"Shippori Antique","variants":["regular"],"subsets":["japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Shippori Antique B1","variants":["regular"],"subsets":["japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Shippori Mincho","variants":["regular","500","600","700","800"],"subsets":["japanese","latin","latin-ext"],"category":"serif"},{"family":"Shippori Mincho B1","variants":["regular","500","600","700","800"],"subsets":["japanese","latin","latin-ext"],"category":"serif"},{"family":"Shojumaru","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Short Stack","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Shrikhand","variants":["regular"],"subsets":["gujarati","latin","latin-ext"],"category":"display"},{"family":"Siemreap","variants":["regular"],"subsets":["khmer"],"category":"display"},{"family":"Sigmar One","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Signika","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Signika Negative","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Silkscreen","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Simonetta","variants":["regular","italic","900","900italic"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Single Day","variants":["regular"],"subsets":["korean"],"category":"display"},{"family":"Sintony","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Sirin Stencil","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Six Caps","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Skranji","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Slabo 13px","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Slabo 27px","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Slackey","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Smokum","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Smooch","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Smooch Sans","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Smythe","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Sniglet","variants":["regular","800"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Snippet","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Snowburst One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Sofadi One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Sofia","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Solway","variants":["300","regular","500","700","800"],"subsets":["latin"],"category":"serif"},{"family":"Song Myung","variants":["regular"],"subsets":["korean","latin"],"category":"serif"},{"family":"Sonsie One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Sora","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Sorts Mill Goudy","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Source Code Pro","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Source Sans 3","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Source Sans Pro","variants":["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Source Serif 4","variants":["200","300","regular","500","600","700","800","900","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Source Serif Pro","variants":["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic","900","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Space Grotesk","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Space Mono","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Special Elite","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Spectral","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Spectral SC","variants":["200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Spicy Rice","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Spinnaker","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Spirax","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Splash","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Spline Sans","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Spline Sans Mono","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"Squada One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Square Peg","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Sree Krushnadevaraya","variants":["regular"],"subsets":["latin","telugu"],"category":"serif"},{"family":"Sriracha","variants":["regular"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"handwriting"},{"family":"Srisakdi","variants":["regular","700"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"display"},{"family":"Staatliches","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Stalemate","variants":["regular"],"subsets":["latin","latin-ext"],"category":"handwriting"},{"family":"Stalinist One","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"display"},{"family":"Stardos Stencil","variants":["regular","700"],"subsets":["latin"],"category":"display"},{"family":"Stick","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Stick No Bills","variants":["200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","sinhala"],"category":"sans-serif"},{"family":"Stint Ultra Condensed","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Stint Ultra Expanded","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Stoke","variants":["300","regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Strait","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Style Script","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Stylish","variants":["regular"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Sue Ellen Francisco","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Suez One","variants":["regular"],"subsets":["hebrew","latin","latin-ext"],"category":"serif"},{"family":"Sulphur Point","variants":["300","regular","700"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Sumana","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Sunflower","variants":["300","500","700"],"subsets":["korean","latin"],"category":"sans-serif"},{"family":"Sunshiney","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Supermercado One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Sura","variants":["regular","700"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Suranna","variants":["regular"],"subsets":["latin","telugu"],"category":"serif"},{"family":"Suravaram","variants":["regular"],"subsets":["latin","telugu"],"category":"serif"},{"family":"Suwannaphum","variants":["100","300","regular","700","900"],"subsets":["khmer","latin"],"category":"serif"},{"family":"Swanky and Moo Moo","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Syncopate","variants":["regular","700"],"subsets":["latin"],"category":"sans-serif"},{"family":"Syne","variants":["regular","500","600","700","800"],"subsets":["greek","latin","latin-ext"],"category":"sans-serif"},{"family":"Syne Mono","variants":["regular"],"subsets":["latin","latin-ext"],"category":"monospace"},{"family":"Syne Tactile","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Tai Heritage Pro","variants":["regular","700"],"subsets":["latin","latin-ext","tai-viet","vietnamese"],"category":"serif"},{"family":"Tajawal","variants":["200","300","regular","500","700","800","900"],"subsets":["arabic","latin"],"category":"sans-serif"},{"family":"Tangerine","variants":["regular","700"],"subsets":["latin"],"category":"handwriting"},{"family":"Tapestry","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Taprom","variants":["regular"],"subsets":["khmer","latin"],"category":"display"},{"family":"Tauri","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Taviraj","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"serif"},{"family":"Teko","variants":["300","regular","500","600","700"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Telex","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Tenali Ramakrishna","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Tenor Sans","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"sans-serif"},{"family":"Text Me One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Texturina","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Thasadith","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"sans-serif"},{"family":"The Girl Next Door","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"The Nautigal","variants":["regular","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Tienne","variants":["regular","700","900"],"subsets":["latin"],"category":"serif"},{"family":"Tillana","variants":["regular","500","600","700","800"],"subsets":["devanagari","latin","latin-ext"],"category":"handwriting"},{"family":"Timmana","variants":["regular"],"subsets":["latin","telugu"],"category":"sans-serif"},{"family":"Tinos","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","hebrew","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Tiro Bangla","variants":["regular","italic"],"subsets":["bengali","latin","latin-ext"],"category":"serif"},{"family":"Tiro Devanagari Hindi","variants":["regular","italic"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Tiro Devanagari Marathi","variants":["regular","italic"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Tiro Devanagari Sanskrit","variants":["regular","italic"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Tiro Gurmukhi","variants":["regular","italic"],"subsets":["gurmukhi","latin","latin-ext"],"category":"serif"},{"family":"Tiro Kannada","variants":["regular","italic"],"subsets":["kannada","latin","latin-ext"],"category":"serif"},{"family":"Tiro Tamil","variants":["regular","italic"],"subsets":["latin","latin-ext","tamil"],"category":"serif"},{"family":"Tiro Telugu","variants":["regular","italic"],"subsets":["latin","latin-ext","telugu"],"category":"serif"},{"family":"Titan One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Titillium Web","variants":["200","200italic","300","300italic","regular","italic","600","600italic","700","700italic","900"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Tomorrow","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Tourney","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"display"},{"family":"Trade Winds","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Train One","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"display"},{"family":"Trirong","variants":["100","100italic","200","200italic","300","300italic","regular","italic","500","500italic","600","600italic","700","700italic","800","800italic","900","900italic"],"subsets":["latin","latin-ext","thai","vietnamese"],"category":"serif"},{"family":"Trispace","variants":["100","200","300","regular","500","600","700","800"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Trocchi","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Trochut","variants":["regular","italic","700"],"subsets":["latin"],"category":"display"},{"family":"Truculenta","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Trykker","variants":["regular"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Tulpen One","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Turret Road","variants":["200","300","regular","500","700","800"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Twinkle Star","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Ubuntu","variants":["300","300italic","regular","italic","500","500italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"Ubuntu Condensed","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],"category":"sans-serif"},{"family":"Ubuntu Mono","variants":["regular","italic","700","700italic"],"subsets":["cyrillic","cyrillic-ext","greek","greek-ext","latin","latin-ext"],"category":"monospace"},{"family":"Uchen","variants":["regular"],"subsets":["latin","tibetan"],"category":"serif"},{"family":"Ultra","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Uncial Antiqua","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Underdog","variants":["regular"],"subsets":["cyrillic","latin","latin-ext"],"category":"display"},{"family":"Unica One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"UnifrakturCook","variants":["700"],"subsets":["latin"],"category":"display"},{"family":"UnifrakturMaguntia","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Unkempt","variants":["regular","700"],"subsets":["latin"],"category":"display"},{"family":"Unlock","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Unna","variants":["regular","italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Updock","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Urbanist","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"VT323","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Vampiro One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Varela","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Varela Round","variants":["regular"],"subsets":["hebrew","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Varta","variants":["300","regular","500","600","700"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Vast Shadow","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Vazirmatn","variants":["100","200","300","regular","500","600","700","800","900"],"subsets":["arabic","latin","latin-ext"],"category":"sans-serif"},{"family":"Vesper Libre","variants":["regular","500","700","900"],"subsets":["devanagari","latin","latin-ext"],"category":"serif"},{"family":"Viaoda Libre","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Vibes","variants":["regular"],"subsets":["arabic","latin"],"category":"display"},{"family":"Vibur","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Vidaloka","variants":["regular"],"subsets":["latin"],"category":"serif"},{"family":"Viga","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Voces","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Volkhov","variants":["regular","italic","700","700italic"],"subsets":["latin"],"category":"serif"},{"family":"Vollkorn","variants":["regular","500","600","700","800","900","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["cyrillic","cyrillic-ext","greek","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Vollkorn SC","variants":["regular","600","700","900"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Voltaire","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Vujahday Script","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Waiting for the Sunrise","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Wallpoet","variants":["regular"],"subsets":["latin"],"category":"display"},{"family":"Walter Turncoat","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Warnes","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Water Brush","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Waterfall","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Wellfleet","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Wendy One","variants":["regular"],"subsets":["latin","latin-ext"],"category":"sans-serif"},{"family":"Whisper","variants":["regular"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"WindSong","variants":["regular","500"],"subsets":["latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Wire One","variants":["regular"],"subsets":["latin"],"category":"sans-serif"},{"family":"Work Sans","variants":["100","200","300","regular","500","600","700","800","900","100italic","200italic","300italic","italic","500italic","600italic","700italic","800italic","900italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Xanh Mono","variants":["regular","italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"monospace"},{"family":"Yaldevi","variants":["200","300","regular","500","600","700"],"subsets":["latin","latin-ext","sinhala"],"category":"sans-serif"},{"family":"Yanone Kaffeesatz","variants":["200","300","regular","500","600","700"],"subsets":["cyrillic","latin","latin-ext","vietnamese"],"category":"sans-serif"},{"family":"Yantramanav","variants":["100","300","regular","500","700","900"],"subsets":["devanagari","latin","latin-ext"],"category":"sans-serif"},{"family":"Yatra One","variants":["regular"],"subsets":["devanagari","latin","latin-ext"],"category":"display"},{"family":"Yellowtail","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Yeon Sung","variants":["regular"],"subsets":["korean","latin"],"category":"display"},{"family":"Yeseva One","variants":["regular"],"subsets":["cyrillic","cyrillic-ext","latin","latin-ext","vietnamese"],"category":"display"},{"family":"Yesteryear","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Yomogi","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext","vietnamese"],"category":"handwriting"},{"family":"Yrsa","variants":["300","regular","500","600","700","300italic","italic","500italic","600italic","700italic"],"subsets":["latin","latin-ext","vietnamese"],"category":"serif"},{"family":"Yuji Boku","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Yuji Mai","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Yuji Syuku","variants":["regular"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"serif"},{"family":"Yusei Magic","variants":["regular"],"subsets":["japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"ZCOOL KuaiLe","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"display"},{"family":"ZCOOL QingKe HuangYou","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"display"},{"family":"ZCOOL XiaoWei","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"serif"},{"family":"Zen Antique","variants":["regular"],"subsets":["cyrillic","greek","japanese","latin","latin-ext"],"category":"serif"},{"family":"Zen Antique Soft","variants":["regular"],"subsets":["cyrillic","greek","japanese","latin","latin-ext"],"category":"serif"},{"family":"Zen Dots","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Zen Kaku Gothic Antique","variants":["300","regular","500","700","900"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Zen Kaku Gothic New","variants":["300","regular","500","700","900"],"subsets":["cyrillic","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Zen Kurenaido","variants":["regular"],"subsets":["cyrillic","greek","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Zen Loop","variants":["regular","italic"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Zen Maru Gothic","variants":["300","regular","500","700","900"],"subsets":["cyrillic","greek","japanese","latin","latin-ext"],"category":"sans-serif"},{"family":"Zen Old Mincho","variants":["regular","700","900"],"subsets":["cyrillic","greek","japanese","latin","latin-ext"],"category":"serif"},{"family":"Zen Tokyo Zoo","variants":["regular"],"subsets":["latin","latin-ext"],"category":"display"},{"family":"Zeyada","variants":["regular"],"subsets":["latin"],"category":"handwriting"},{"family":"Zhi Mang Xing","variants":["regular"],"subsets":["chinese-simplified","latin"],"category":"handwriting"},{"family":"Zilla Slab","variants":["300","300italic","regular","italic","500","500italic","600","600italic","700","700italic"],"subsets":["latin","latin-ext"],"category":"serif"},{"family":"Zilla Slab Highlight","variants":["regular","700"],"subsets":["latin","latin-ext"],"category":"display"}]} build/et-core-app.bundle.js 0000644 00004742262 15222641012 0011601 0 ustar 00 /*! This minified app bundle contains open source software from several third party developers. Please review CREDITS.md in the root directory or LICENSE.md in the current directory for complete licensing, copyright and patent information. This file and the included code may not be redistributed without the attributions listed in LICENSE.md, including associate copyright notices and licensing information. */!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="http://0.0.0.0:31499/",n(n.s=226)}([function(e,t){e.exports=React},function(e,t,n){e.exports=n(274)()},function(e,t,n){"use strict";n.r(t),n.d(t,"props",(function(){return Y})),n.d(t,"path",(function(){return G})),n.d(t,"state",(function(){return $})),n.d(t,"string",(function(){return K})),n.d(t,"sequences",(function(){return Z})),n.d(t,"computed",(function(){return X})),n.d(t,"moduleState",(function(){return Q})),n.d(t,"moduleSequences",(function(){return J})),n.d(t,"moduleComputed",(function(){return ee})),n.d(t,"ModuleClass",(function(){return h})),n.d(t,"ControllerClass",(function(){return j})),n.d(t,"ProviderClass",(function(){return g.a})),n.d(t,"BaseControllerClass",(function(){return k})),n.d(t,"ChainSequenceFactory",(function(){return z})),n.d(t,"ChainSequenceWithPropsFactory",(function(){return F})),n.d(t,"sequence",(function(){return s.j})),n.d(t,"parallel",(function(){return s.h})),n.d(t,"createTemplateTag",(function(){return s.e})),n.d(t,"extractValueWithPath",(function(){return s.g})),n.d(t,"resolveObject",(function(){return s.i})),n.d(t,"ResolveValue",(function(){return s.c})),n.d(t,"Tag",(function(){return s.d})),n.d(t,"Controller",(function(){return te})),n.d(t,"UniversalController",(function(){return ne})),n.d(t,"UniversalApp",(function(){return re})),n.d(t,"Module",(function(){return oe})),n.d(t,"CerebralError",(function(){return U})),n.d(t,"Provider",(function(){return g.a})),n.d(t,"Compute",(function(){return u.c})),n.d(t,"Reaction",(function(){return d})),n.d(t,"View",(function(){return V})),n.d(t,"createDummyController",(function(){return o.d})),n.d(t,"throwError",(function(){return o.y})),n.d(t,"default",(function(){return ae}));var r=n(43),o=n(5),i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var a=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.map={}}return i(e,[{key:"addEntity",value:function(e,t){var n=this,r=function(t){var r=t.split(".");r.reduce((function(t,n,o){return t[n]||(t[n]={}),o<r.length-1?(t[n].children=t[n].children||{},t[n].children):(t[n].entities=t[n].entities?t[n].entities.concat(e):[e],t)}),n.map)};for(var o in t)r(o)}},{key:"removeEntity",value:function(e,t){var n=this,r=function(t){var r=t.split(".");r.reduce((function(t,n,o){return o===r.length-1&&(t[n].entities.splice(t[n].entities.indexOf(e),1),t[n].entities.length||delete t[n].entities),t[n].children}),n.map)};for(var o in t)r(o)}},{key:"updateEntity",value:function(e,t,n){var r=t?Object.keys(t).reduce((function(e,t){return n[t]||(e[t]=!0),e}),{}):{},o=Object.keys(n).reduce((function(e,n){return t&&t[n]||(e[n]=!0),e}),{});this.removeEntity(e,r),this.addEntity(e,o)}},{key:"getAllUniqueEntities",value:function(){var e=[];return function t(n){for(var r in n){if(n[r].entities)for(var o=0;o<n[r].entities.length;o++)-1===e.indexOf(n[r].entities[o])&&e.push(n[r].entities[o]);n[r].children&&t(n[r].children)}}(this.map),e.sort((function(e,t){return e.rawId>t.rawId?1:-1}))}},{key:"getUniqueEntities",value:function(e){return Object(o.g)(e,this.map).reduce((function(e,t){return(t.entities||[]).reduce((function(e,t){return-1===e.indexOf(t)?e.concat(t):e}),e)}),[]).sort((function(e,t){return e.rawId>t.rawId?1:-1}))}}]),e}(),s=n(12),u=n(20),l=n(53),c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var f=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"Reaction"));return r.dependencies=e,r.cb=n,r.getter=null,r.context=null,r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),c(t,[{key:"initialize",value:function(){var e=this;return this.context=this.controller.createContext(),this.getter=function(t){return t.getValue(e.context)},this.controller.dependencyStore.updateEntity(this,null,this.createDependencyMap()),this}},{key:"createDependencyMap",value:function(){var e=this;return this.controller.createDependencyMap(Object.keys(this.dependencies).map((function(t){return e.dependencies[t]})),null,this.modulePath)}},{key:"onUpdate",value:function(){var e=this;this.executedCount++,this.controller.devtools&&this.controller.devtools.sendWatchMap([],[],0,0),this.cb(Object.keys(this.dependencies).reduce((function(t,n){return t[n]=e.dependencies[n].getValue(e.context),Object(o.t)(t[n])&&(t[n]=t[n].getValue()),t}),{get:this.getter}))}}]),t}(l.a),d=function(e,t){return t||(t=e,e={}),new f(e,t)},p=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var h=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.moduleDescription=t}return p(e,[{key:"create",value:function(t,n){var r=n.join("."),i={app:t,path:r,name:n.slice().pop()},a="function"==typeof this.moduleDescription?this.moduleDescription(i):Object.assign({},this.moduleDescription);!function e(r,i){Object.keys(r).forEach((function(a){"function"==typeof r[a]?r[a]=new u.a(r[a]).create(t,n,n.concat(i,a).join(".")):r[a]instanceof u.a?r[a].create(t,n,n.concat(i,a).join(".")):Object(o.v)(r[a])&&e(r[a],i.concat(a)),t.devtools&&r[a]instanceof u.a&&t.devtools.registerComputedState(r[a],n.concat(i,a))}))}(a.state||{},[]),a.signals&&Object(o.a)("module.signals",'use the property "sequences" when adding sequences to a module');var l=a.sequences||a.signals;return a.sequences=Object.keys(l||{}).reduce((function(e,r){var i=l[r];return i&&(Array.isArray(i)||"function"==typeof i||i instanceof s.a)||Object(o.y)('Sequence with name "'+r+'" is not correctly defined. Please check that the sequence is either a sequence, an array or a function.'),e[r]={sequence:i,run:function(e){return t.runSequence(n.concat(r).join("."),i,e)}},e}),{}),a.modules=Object.keys(a.modules||{}).reduce((function(r,o){var i=a.modules[o]instanceof e?a.modules[o]:new e(a.modules[o]);return r[o]=i.create(t,n.concat(o)),r}),{}),a.reactions=Object.keys(a.reactions||{}).reduce((function(e,r){if(!(a.reactions[r]instanceof f))throw new Error('You are not using a Reaction in module on key "'+r+'"');return e[r]=a.reactions[r].create(t,n,n.concat(r).join(".")),e}),{}),a}}]),e}();function v(e){return Object(g.a)({send:function(t){e.sendExecutionData(t,this.context.execution,this.context.functionDetails,this.context.props)},wrapProvider:function(e,t){var n=this;return Object.keys(t).reduce((function(r,o){var i=t[o];return r[o]=function(){for(var r=arguments.length,a=Array(r),s=0;s<r;s++)a[s]=arguments[s];return n.context.debugger.send({method:e+"."+o,args:a}),console.log(t.context),i.apply(t,a)},r}),{})}},{wrap:!1})}var g=n(29),m=Object(g.a)((function(e){return Object.assign((function(t,n){var r=e.resolve.value(t);return Object(o.t)(r)?r.getValue(n||e.props):r}),{path:function(t){return e.resolve.path(t)}})}),{wrap:!1}),y=n(62);function b(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function w(e){return Object(g.a)(y.b.reduce((function(e,t){return e[t]=function(){var e,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];n=Object(o.h)(n),Object(o.a)("module.*","use the new STORE provider, store.set(state.isAwesome, true)");for(var r=this.context.execution.name.split("."),i=r.splice(0,r.length-1),a=arguments.length,s=Array(a>1?a-1:0),u=1;u<a;u++)s[u-1]=arguments[u];return(e=this.context.state)[t].apply(e,[i.concat(n)].concat(s))},e}),{}),{wrap:!!e&&function(e,t){return y.b.reduce((function(n,r){if("get"===r||"compute"===r)n[r]=function(t){Object(o.a)("module.get","use the new GET provider, get(moduleState.foo)"),t=Object(o.h)(t);var n=e.execution.name.split(".");return t=n.splice(0,n.length-1).concat(t),e.state[r](t)};else{var i=e.state[r];n[r]=function(){for(var n=arguments.length,a=Array(n),s=0;s<n;s++)a[s]=arguments[s];Object(o.a)("module.*","use the new STORE provider, store.set(moduleState.isAwesome, true)");var u=a.slice(),l=Object(o.h)(u.shift()),c=e.execution.name.split("."),f=c.splice(0,c.length-1);l=f.concat(l),e.debugger.send({datetime:Date.now(),type:"mutation",color:"#333",method:"module."+r,args:[l].concat(b(u))});try{i.apply(e.state,[l].concat(b(u)))}catch(n){var d=e.execution.name;Object(o.y)('The sequence "'+d+'" with action "'+t.name+'" has an error: '+n.message)}}}return n}),{})}})}var _=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,o=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(e){o=!0,i=e}finally{try{!r&&s.return&&s.return()}finally{if(o)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},x=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var k=function(e){function t(e,n,r){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,{},r)),a=n.Model,s=n.devtools,u=void 0===s?null:s,l=n.stateChanges,c=void 0===l?"undefined"!=typeof window&&window.CEREBRAL_STATE:l,f=n.throwToConsole,d=void 0===f||f,p=n.preventInitialize,h=void 0!==p&&p,g=n.returnSequencePromise,y=void 0!==g&&g,b=n.noRethrow,_=void 0!==b&&b,x=i.getSequence,k=i.getSequences;return i.getSequence=function(){Object(o.y)('You are grabbing a sequence before controller has initialized, please wait for "initialized" event')},i.getSequences=function(){Object(o.y)('You are grabbing sequences before controller has initialized, please wait for "initialized" event')},i.throwToConsole=d,i.noRethrow=_,i.returnSequencePromise=y,i.devtools=u,i.Model=a,i.configure(e),h||i.emit("initialized:model"),i.contextProviders=Object.assign(i.contextProviders,Object(o.n)(i.module),{app:i,controller:i,get:m,state:i.model.StateProvider(i.devtools),store:i.model.StoreProvider&&i.model.StoreProvider(i.devtools),module:w(i.devtools)},i.devtools?{debugger:v(i.devtools)}:{}),c&&Object.keys(c).forEach((function(e){i.model.set(Object(o.h)(e),c[e])})),i.devtools&&i.devtools.init(i),!i.devtools&&Object(o.u)()&&"undefined"!=typeof navigator&&/Chrome/.test(navigator.userAgent)&&console.warn("You are not using the Cerebral devtools. It is highly recommended to use it in combination with the debugger: https://cerebraljs.com/docs/introduction/debugger.html"),Object(o.u)()&&(i.on("functionStart",(function(e,t,n){try{JSON.stringify(n)}catch(n){Object(o.y)("The function "+t.name+" in sequence "+e.name+" is not given a valid payload")}})),i.on("functionEnd",(function(e,t,n,r){u&&u.preventPropsReplacement&&Object.keys(r||{}).forEach((function(r){if(r in n)throw new Error('Cerebral Devtools - You have activated the "preventPropsReplacement" option and in sequence "'+e.name+'", before the action "'+t.name+'", the key "'+r+'" was replaced')}))}))),i.getSequence=x,i.getSequences=k,h||i.emit("initialized"),i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),x(t,[{key:"configure",value:function(e){this.module=e instanceof h?e.create(this,[]):new h(e).create(this,[]),this.model=new this.Model(this)}},{key:"reconfigure",value:function(e){var t=this;if(this.devtools){var n=this.model.get();this.configure(e),Object(o.p)(JSON.parse(this.devtools.initialModelString),n,this.model.get()).forEach((function(e){t.model.set(e.path,e.value)})),this.devtools.sendReInit(),this.flush()}}},{key:"getModel",value:function(){return this.model}},{key:"getState",value:function(e){var t=this.model.get(Object(o.h)(Object(o.c)(e)));return"string"==typeof e&&".*"===e.substr(e.length-2,2)?t?Object.keys(t):[]:t}},{key:"runSequence",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};!this.devtools||Object(o.v)(r)&&Object(o.w)(r)||(console.warn('You passed an invalid payload to sequence "'+e+'". Only serializable payloads can be passed to a sequence. The payload has been ignored. This is the object:',r),r={}),this.devtools&&(r=Object.keys(r).reduce((function(t,i){return Object(o.w)(r[i],n.devtools.allowedTypes)?(t[i]=Object(o.k)(r[i]),t):(console.warn('You passed an invalid payload to sequence "'+e+'", on key "'+i+'". Only serializable values like Object, Array, String, Number and Boolean can be passed in. Also these special value types:',n.devtools.allowedTypes),t)}),{}));var i=function(e){if(e){var t=Object(o.h)(e.execution.name).reduce((function(e,t,n){return e.currentModule.catch&&(e.catchingModule=e.currentModule),e.currentModule=e.currentModule.modules[t],e}),{currentModule:n.module,catchingModule:null});if(t.catchingModule){var r=!0,i=!1,a=void 0;try{for(var s,u=t.catchingModule.catch[Symbol.iterator]();!(r=(s=u.next()).done);r=!0){var l=_(s.value,2),c=l[0],f=l[1];if(e instanceof c)return n.runSequence("catch",f,e.payload),void(n.throwToConsole&&setTimeout((function(){console.log('Cerebral is handling error "'+e.name+": "+e.message+'" thrown by sequence "'+e.execution.name+'". Check debugger for more information.')})))}}catch(e){i=!0,a=e}finally{try{!r&&u.return&&u.return()}finally{if(i)throw a}}}if(!n.noRethrow){if(!e.execution.isAsync)throw e;setTimeout((function(){throw e}))}}};if(this.returnSequencePromise)return this.run(e,t,r).catch(i);this.run(e,t,r,i)}},{key:"getSequence",value:function(e){var t=Object(o.h)(e),n=t.pop(),r=t.reduce((function(e,t){return e?e.modules[t]:void 0}),this.module),i=r&&r.sequences[n];if(i)return i&&i.run}},{key:"getSequences",value:function(e){var t=Object(o.h)(e).reduce((function(e,t){return e?e.modules[t]:void 0}),this.module),n=t&&t.sequences;if(n){var r={};for(var i in n)r[i]=n[i].run;return r}}},{key:"addModule",value:function(e,t){var n=Object(o.h)(e),r=n.pop(),i=Object(o.m)(n,this.module),a=t instanceof h?t.create(this,Object(o.h)(e)):new h(t).create(this,Object(o.h)(e));i.modules[r]=a,a.providers&&Object.assign(this.contextProviders,a.providers),this.emit("moduleAdded",e.split("."),a),this.flush()}},{key:"removeModule",value:function(e){var t=this;if(!e)return console.warn("Controller.removeModule requires a Module Path"),null;var n=Object(o.h)(e),r=n.pop(),i=Object(o.m)(n,this.module),a=i.modules[r];a.providers&&Object.keys(a.providers).forEach((function(e){delete t.contextProviders[e]})),delete i.modules[r],this.emit("moduleRemoved",Object(o.h)(e),a),this.flush()}}]),t}(s.f),C=n(90),O="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=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var S=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.controller=e,n.devtools=e.devtools,n.state=n.devtools&&n.devtools.warnStateProps?Object(o.b)(n.initialState):n.initialState,e.on("initialized",(function(){n.flush()})),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),E(t,[{key:"updateIn",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];e.length?e.reduce((function(i,a,s){if(s===e.length-1){Array.isArray(i)||Object(o.v)(i)||Object(o.y)('The path "'+e.join(".")+'" is invalid. Path: "'+e.slice(0,e.length-1).join(".")+'" is type of "'+(null===i?"null":void 0===i?"undefined":O(i))+'"');var u=i[a];t(i[a],i,a),(i[a]!==u||Object(o.s)(i[a])&&Object(o.s)(u))&&n.changedPaths.push({path:e,forceChildPathUpdates:r})}else i[a]||(i[a]={});return i[a]}),this.state):t(this.state,this,"state")}},{key:"checkForComputed",value:function(e){var t=e.reduce((function(e,t){return e[t]}),this.state);if(t instanceof u.a&&Object(o.y)('You are trying to replace a computed value on path "'+e.join(".")+'", but that is not allowed'),Object(o.v)(t)){!function e(t,n){Object.keys(t).forEach((function(r){t[r]instanceof u.a?Object(o.y)('You are trying to replace a computed value on path "'+n.join(".")+'", but that is not allowed'):Object(o.v)(t[r])&&e(t[r],n.concat(r))}))}(t,e)}}},{key:"verifyValue",value:function(e,t){this.devtools&&(this.checkForComputed(t),Object(o.w)(e,this.devtools.allowedTypes)||Object(o.y)('You are passing a non serializable value into the state tree on path "'+t.join(".")+'"'),Object(o.k)(e),this.devtools.warnStateProps&&Object(o.b)(e))}},{key:"verifyValues",value:function(e,t){var n=this;this.devtools&&e.forEach((function(e){n.verifyValue(e,t)}))}},{key:"emitMutationEvent",value:function(e,t,n){for(var r=arguments.length,o=Array(r>3?r-3:0),i=3;i<r;i++)o[i-3]=arguments[i];this.controller.emit("mutation",{method:e,path:t,forceChildPathUpdates:n,args:o})}},{key:"get",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.reduce((function(t,n,r){return t instanceof u.b?t:t instanceof u.a?new u.b(t,e.slice(r)):t?t[n]:void 0}),this.state)}},{key:"set",value:function(e,t){this.verifyValue(t,e),this.updateIn(e,(function(e,n,r){n[r]=t}),!0),this.emitMutationEvent("set",e,!0,t)}},{key:"toggle",value:function(e){this.updateIn(e,(function(e,t,n){t[n]=!e})),this.emitMutationEvent("toggle",e,!1)}},{key:"push",value:function(e,t){this.verifyValue(t,e),this.updateIn(e,(function(e){e.push(t)})),this.emitMutationEvent("push",e,t,!1)}},{key:"merge",value:function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var o=Object.assign.apply(Object,n);if(this.get(e))for(var i in o)this.set(e.concat(i),o[i]);else this.set(e,o);this.emitMutationEvent.apply(this,["merge",e,!1].concat(n))}},{key:"pop",value:function(e){this.updateIn(e,(function(e){e.pop()})),this.emitMutationEvent("pop",e,!1)}},{key:"shift",value:function(e){this.updateIn(e,(function(e){e.shift()})),this.emitMutationEvent("shift",e,!1)}},{key:"unshift",value:function(e,t){this.verifyValue(t,e),this.updateIn(e,(function(e){e.unshift(t)})),this.emitMutationEvent("unshift",e,t,!1)}},{key:"splice",value:function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];this.verifyValues(n,e),this.updateIn(e,(function(e){e.splice.apply(e,n)})),this.emitMutationEvent.apply(this,["splice",e,!1].concat(n))}},{key:"unset",value:function(e){this.updateIn(e,(function(e,t,n){delete t[n]}),!0),this.emitMutationEvent("unset",e,!0)}},{key:"concat",value:function(e,t){this.verifyValue(t,e),this.updateIn(e,(function(e,n,r){n[r]=e.concat(t)})),this.emitMutationEvent("concat",e,!1,t)}},{key:"increment",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;if(!Number.isInteger(t))throw new Error("Cerebral state.increment: you must increment with integer values.");this.updateIn(e,(function(e,n,r){if(!Number.isInteger(e))throw new Error("Cerebral state.increment: you must increment integer values.");n[r]=e+t})),this.emitMutationEvent("increment",e,!1,t)}}]),t}(C.a),T=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var j=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,Object.assign({Model:S},n)));return r.dependencyStore=new a,r.flush=r.flush.bind(r),r.on("asyncFunction",(function(e,t){t.isParallel||r.flush()})),r.on("parallelStart",(function(){return r.flush()})),r.on("parallelProgress",(function(e,t,n){1===n&&r.flush()})),r.on("mutation",(function(e){return r.updateComputed(e)})),r.on("end",(function(){return r.flush()})),Object(o.j)(r.module,"reactions",(function(e,t){return e&&Object.keys(e).filter((function(t){return e[t]instanceof f})).forEach((function(t){return e[t].initialize()})),e})),r.getState=r.getState.bind(r),r.getSequence=r.getSequence.bind(r),r.getSequences=r.getSequences.bind(r),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),T(t,[{key:"flush",value:function(e){var t=this.model.flush();(e||t.length)&&(this.updateWatchers(t,e),this.emit("flush",t,Boolean(e)))}},{key:"updateComputed",value:function(e){this.dependencyStore.getUniqueEntities([e]).forEach((function(e){e instanceof u.a&&(e.isDirty=!0)}))}},{key:"updateWatchers",value:function(e,t){var n=[];n=t?this.dependencyStore.getAllUniqueEntities():this.dependencyStore.getUniqueEntities(e);var r=Date.now(),o="undefined"==typeof performance?Date.now():performance.now();n.forEach((function(n){n instanceof u.a||n.onUpdate(e,t)}));var i="undefined"==typeof performance?Date.now():performance.now();this.devtools&&n.length&&this.devtools.sendWatchMap(n,e,r,i-o)}},{key:"get",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.createContext(t),r=e.getValue(n);return Object(o.t)(r)?r.getValue(t):r}},{key:"createContext",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=t.length?t.join(".")+".":"";return{props:e,controller:this,execution:{name:n}}}},{key:"createDependencyMap",value:function(e,t,n){var r=this,i=this.createContext(t,n);return e.reduce((function(e,n){return n instanceof s.d?n.getTags(i).reduce((function(e,n){if("state"===n.type||"moduleState"===n.type){var a=n.getValue(i);if(Object(o.t)(a))return a.getValue(t),Object.assign(e,a.getDependencyMap());var s=n.getPath(i);e[Object(o.i)(s,r.getState(s))]=!0}return e}),e):e}),{})}}]),t}(k),M=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var L,A=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.changes=[],r.model.state=JSON.parse(JSON.stringify(r.model.state)),r.trackChanges=r.trackChanges.bind(r),r.on("flush",r.trackChanges),r.hasRun=!1,r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),M(t,[{key:"trackChanges",value:function(e){this.changes=this.changes.concat(e)}},{key:"getChanges",value:function(){var e=this;return this.changes.reduce((function(t,n){return t[n.path.join(".")]=e.getState(n.path),t}),{})}},{key:"getScript",value:function(){var e=JSON.stringify(this.getChanges());return this.hasRun=!0,"<script>window.CEREBRAL_STATE = "+e+"<\/script>"}},{key:"runSequence",value:function(e,t){var n=void 0;if(Array.isArray(e))n=this.run("UniversalController.run",e,t);else if("string"==typeof e){var r=Object(o.h)(e),i=r.pop(),a=Object(o.m)(r,this.module),s=a&&a.sequences[i];n=this.run(e,s.sequence,t)}else Object(o.y)("Sequence must be a sequence-path or an array of action.");return n}},{key:"setState",value:function(e,t){this.model.set(Object(o.h)(e),t),this.flush(!0)}}]),t}(j),P=n(46),R=(L=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}L(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),D=function(){function e(e){this.sequenceArray=e}return e.prototype.action=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r,o="string"==typeof t[0],i=o?t.splice(1):t;return i.forEach((function(e){o&&Object.defineProperty(e,"name",{value:t[0]})})),(r=this.sequenceArray).push.apply(r,i),new e(this.sequenceArray)},e.prototype.branch=function(t){var n=this;return this.sequenceArray.push(t),{paths:function(t){var r=function(e){var t={};for(var n in e){var r=new D([]);(0,e[n])(r),t[n]=r.sequenceArray}return t}(t);return n.sequenceArray.push(r),new e(n.sequenceArray)}}},e.prototype.parallel=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];var r="string"==typeof t[0]?t[1]:t[0],o="string"==typeof t[0]?t[0]:"";return this.sequenceArray.push(Object(s.h)(o,r)),new e(this.sequenceArray)},e.prototype.sequence=function(t){return(n=this.sequenceArray).push.apply(n,t),new e(this.sequenceArray);var n},e.prototype.when=function(e){return this.branch((function(t){return e(t)?t.path.true({}):t.path.false({})}))},e.prototype.debounce=function(e){return this.branch(Object(P.a)(e))},e.prototype.equals=function(e){return this.branch((function(t){var n=String(e(t));return t.path[n]?t.path[n]({}):t.path.othersise({})}))},e.prototype.wait=function(e){return this.sequenceArray.push(Object(P.b)(e)),new I(this.sequenceArray)},e}(),I=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return R(t,e),t.prototype.continue=function(e){var t=new D([]);return this.sequenceArray.push({continue:t.sequenceArray}),t},t}(D);function N(e){var t=new D([]);return e(t),t.sequenceArray}function z(){return function(e){return N(e)}}function F(){return function(e){return N(e)}}function B(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function H(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var U=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.name="CerebralError",r.details=n,r.toJSON=function(){var e=this;return Object.getOwnPropertyNames(this).reduce((function(t,n){return["toJSON","execution","functionDetails"].includes(n)||(t[n]=e[n]),t}),{})},r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";B(this,t);var n=H(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return Object.defineProperty(n,"message",{configurable:!0,enumerable:!1,value:e,writable:!0}),Object.defineProperty(n,"name",{configurable:!0,enumerable:!1,value:n.constructor.name,writable:!0}),Error.hasOwnProperty("captureStackTrace")?(Error.captureStackTrace(n,n.constructor),H(n)):(Object.defineProperty(n,"stack",{configurable:!0,enumerable:!1,value:new Error(e).stack,writable:!0}),n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(function(e){function t(){e.apply(this,arguments)}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}(Error))),W=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var V=function(e){function t(e){var n=e.dependencies,r=void 0===n?{}:n,i=e.mergeProps,a=e.props,u=e.controller,l=e.displayName,c=e.onUpdate;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var f=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"View"));return"function"==typeof r&&Object(o.y)("You can not use a function to define dependencies. Use tags or a function on the specific property you want to dynamically create"),Object.keys(r).forEach((function(e){r[e]instanceof s.d||Object(o.y)('The dependency "'+e+'" on component "'+l+'" is not a tag, it has to be a tag')})),f.dependencies=r,f.mergeProps=i,f.controller=u,f._displayName=l,f._hasWarnedBigComponent=!1,f.isUnmounted=!1,f.updateComponent=c||o.x,f.props=a,f.propKeys=Object.keys(a||{}),f._verifyPropsWarned=!1,f.dynamicDependencies=[],f.reactions=[],f.computedWithProps={},f.dynamicComputedWithProps={},f.createReaction=f.createReaction.bind(f),u.devtools&&u.devtools.warnStateProps&&f.verifyProps(a),f}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),W(t,[{key:"verifyProps",value:function(e){var t=Object(o.q)(e);t&&!this._verifyPropsWarned&&(console.warn("You are passing an "+(Array.isArray(e[t])?"array":"object")+' to the component "'+this._displayName+'" on prop "'+t+'" which is from the Cerebral state tree. You should not do this, but rather connect it directly to this component. This will optimize the component and avoid any rerender issues.'),this._verifyPropsWarned=!0)}},{key:"createDependencyMap",value:function(){var e=this,t=this.controller.createContext(this.props),n={},r=Object.keys(this.dependencies).map((function(r){var i=e.dependencies[r],a=i.getValue(t);return Object(o.t)(a)&&a.propsTags.length&&(n[i.getPath(t)]=a),i})).concat(this.dynamicDependencies);return Object.keys(this.computedWithProps).forEach((function(t){t in n||t in e.dynamicComputedWithProps||(e.computedWithProps[t].destroy(),delete e.computedWithProps[t])})),Object.keys(n).forEach((function(t){e.computedWithProps[t]||(e.computedWithProps[t]=n[t].clone())})),Object.keys(this.dynamicComputedWithProps).forEach((function(t){e.computedWithProps[t]||(e.computedWithProps[t]=e.dynamicComputedWithProps[t])})),this.controller.createDependencyMap(r,this.props)}},{key:"onUpdate",value:function(){this.isUnmounted||this.updateComponent.apply(this,arguments)}},{key:"mount",value:function(){this.create(this.controller,[],this._displayName),this.update(this.props)}},{key:"unMount",value:function(){var e=this;Object.keys(this.computedWithProps).forEach((function(t){e.computedWithProps[t].destroy()})),this.reactions.forEach((function(e){return e.destroy()})),this.isUnmounted=!0,this.destroy()}},{key:"onPropsUpdate",value:function(e,t){this.controller.devtools&&this.verifyProps(t);var n=Object(o.l)(e,t);return!!n.length&&(this.updateFromProps(n,t),!0)}},{key:"updateFromProps",value:function(e,t){this.update(t)}},{key:"updateFromState",value:function(e,t,n){this.update(t)}},{key:"update",value:function(e){var t=this.dependencyMap;this.props=e,this.dependencyMap=this.createDependencyMap();var n=Object.assign({},t),r=Object.assign({},this.dependencyMap);this.controller.dependencyStore.updateEntity(this,n,r),this.controller.devtools&&this.controller.devtools.updateWatchMap(this,r,n)}},{key:"createDynamicGetter",value:function(e,t){var n=this;return this.dynamicDependencies=[],this.dynamicComputedWithProps={},Object.assign((function(r){var i=r.getValue(t);if(n.dynamicDependencies.push(r),Object(o.t)(i)&&i.propsTags.length){var a=r.getPath(t);return n.computedWithProps[a]?(n.dynamicComputedWithProps[a]=n.computedWithProps[a],n.computedWithProps[a].getValue(e)):(n.dynamicComputedWithProps[a]=i.clone(),n.dynamicComputedWithProps[a].getValue(e))}return Object(o.t)(i)?i.getValue(e):i}),{path:function(e){return e.getPath(t)}})}},{key:"createReaction",value:function(e,t,n){var r=d(t,n).create(this.controller,this.modulePath,this.name+"."+e).initialize();return this.reactions.push(r),r}},{key:"getProps",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=Object.keys(this.dependencies).reduce((function(r,i){var a=t.dependencies[i],s=a.getValue(e);if(Object(o.t)(s)){var u=a.getPath(e);t.computedWithProps[u]?r[i]=t.computedWithProps[u].getValue(n):r[i]=s.getValue(n)}else r[i]=s;return r}),{});return this.controller.devtools&&this.controller.devtools.bigComponentsWarning&&!this._hasWarnedBigComponent&&Object.keys(this.dependencies).length>=this.controller.devtools.bigComponentsWarning&&(console.warn("Component named "+this._displayName+" has a lot of dependencies, consider refactoring or adjust this option in devtools"),this._hasWarnedBigComponent=!0),this.mergeProps?this.mergeProps(i,n,(function(t){t instanceof s.d||Object(o.y)("You are not passing a tag to the mergeProp get function");var r=t.getValue(e);return Object(o.t)(r)?r.getValue(n):r})):(i.get=this.createDynamicGetter(n,e),i.reaction=this.createReaction,Object.assign({},r?n:{},i))}},{key:"render",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){},n=arguments[2],r=this.controller.createContext(e),o=this.getProps(r,e,n);this.executedCount++,this.controller.devtools&&this.controller.devtools.sendWatchMap([],[],0,0);var i=t(o);return this.dynamicDependencies.length&&this.update(e),i}}]),t}(l.a),q=r;var Y=q.props,G=q.path,$=q.state,K=q.string,Z=q.sequences,X=q.computed,Q=q.moduleState,J=q.moduleSequences,ee=q.moduleComputed;function te(e,t){return Object(o.a)("Controller","Use App default import instead"),new j(e,t)}function ne(e,t){return Object(o.a)("UniversalController","Use UniversalApp import instead"),new A(e,t)}function re(e,t){return new A(e,t)}function oe(e){return Object(o.a)("Module","Use plain object/function. Type with ModuleDefinition export"),new h(e)}var ie=void 0;function ae(e,t){return t&&!0===t.hotReloading&&ie?(ie.reconfigure(e),ie):ie=new j(e,t)}},function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){(function(e,n){(function(){var r="Expected a function",o="__lodash_placeholder__",i=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],a="[object Arguments]",s="[object Array]",u="[object Boolean]",l="[object Date]",c="[object Error]",f="[object Function]",d="[object GeneratorFunction]",p="[object Map]",h="[object Number]",v="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",b="[object Symbol]",w="[object WeakMap]",_="[object ArrayBuffer]",x="[object DataView]",k="[object Float32Array]",C="[object Float64Array]",O="[object Int8Array]",E="[object Int16Array]",S="[object Int32Array]",T="[object Uint8Array]",j="[object Uint16Array]",M="[object Uint32Array]",L=/\b__p \+= '';/g,A=/\b(__p \+=) '' \+/g,P=/(__e\(.*?\)|\b__t\)) \+\n'';/g,R=/&(?:amp|lt|gt|quot|#39);/g,D=/[&<>"']/g,I=RegExp(R.source),N=RegExp(D.source),z=/<%-([\s\S]+?)%>/g,F=/<%([\s\S]+?)%>/g,B=/<%=([\s\S]+?)%>/g,H=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,U=/^\w*$/,W=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,V=/[\\^$.*+?()[\]{}|]/g,q=RegExp(V.source),Y=/^\s+/,G=/\s/,$=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,K=/\{\n\/\* \[wrapped with (.+)\] \*/,Z=/,? & /,X=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Q=/[()=,{}\[\]\/\s]/,J=/\\(\\)?/g,ee=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,te=/\w*$/,ne=/^[-+]0x[0-9a-f]+$/i,re=/^0b[01]+$/i,oe=/^\[object .+?Constructor\]$/,ie=/^0o[0-7]+$/i,ae=/^(?:0|[1-9]\d*)$/,se=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ue=/($^)/,le=/['\n\r\u2028\u2029\\]/g,ce="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",fe="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",de="[\\ud800-\\udfff]",pe="["+fe+"]",he="["+ce+"]",ve="\\d+",ge="[\\u2700-\\u27bf]",me="[a-z\\xdf-\\xf6\\xf8-\\xff]",ye="[^\\ud800-\\udfff"+fe+ve+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",be="\\ud83c[\\udffb-\\udfff]",we="[^\\ud800-\\udfff]",_e="(?:\\ud83c[\\udde6-\\uddff]){2}",xe="[\\ud800-\\udbff][\\udc00-\\udfff]",ke="[A-Z\\xc0-\\xd6\\xd8-\\xde]",Ce="(?:"+me+"|"+ye+")",Oe="(?:"+ke+"|"+ye+")",Ee="(?:"+he+"|"+be+")"+"?",Se="[\\ufe0e\\ufe0f]?"+Ee+("(?:\\u200d(?:"+[we,_e,xe].join("|")+")[\\ufe0e\\ufe0f]?"+Ee+")*"),Te="(?:"+[ge,_e,xe].join("|")+")"+Se,je="(?:"+[we+he+"?",he,_e,xe,de].join("|")+")",Me=RegExp("['\u2019]","g"),Le=RegExp(he,"g"),Ae=RegExp(be+"(?="+be+")|"+je+Se,"g"),Pe=RegExp([ke+"?"+me+"+(?:['\u2019](?:d|ll|m|re|s|t|ve))?(?="+[pe,ke,"$"].join("|")+")",Oe+"+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?(?="+[pe,ke+Ce,"$"].join("|")+")",ke+"?"+Ce+"+(?:['\u2019](?:d|ll|m|re|s|t|ve))?",ke+"+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ve,Te].join("|"),"g"),Re=RegExp("[\\u200d\\ud800-\\udfff"+ce+"\\ufe0e\\ufe0f]"),De=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ie=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Ne=-1,ze={};ze[k]=ze[C]=ze[O]=ze[E]=ze[S]=ze[T]=ze["[object Uint8ClampedArray]"]=ze[j]=ze[M]=!0,ze[a]=ze[s]=ze[_]=ze[u]=ze[x]=ze[l]=ze[c]=ze[f]=ze[p]=ze[h]=ze[v]=ze[g]=ze[m]=ze[y]=ze[w]=!1;var Fe={};Fe[a]=Fe[s]=Fe[_]=Fe[x]=Fe[u]=Fe[l]=Fe[k]=Fe[C]=Fe[O]=Fe[E]=Fe[S]=Fe[p]=Fe[h]=Fe[v]=Fe[g]=Fe[m]=Fe[y]=Fe[b]=Fe[T]=Fe["[object Uint8ClampedArray]"]=Fe[j]=Fe[M]=!0,Fe[c]=Fe[f]=Fe[w]=!1;var Be={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},He=parseFloat,Ue=parseInt,We="object"==typeof e&&e&&e.Object===Object&&e,Ve="object"==typeof self&&self&&self.Object===Object&&self,qe=We||Ve||Function("return this")(),Ye=t&&!t.nodeType&&t,Ge=Ye&&"object"==typeof n&&n&&!n.nodeType&&n,$e=Ge&&Ge.exports===Ye,Ke=$e&&We.process,Ze=function(){try{var e=Ge&&Ge.require&&Ge.require("util").types;return e||Ke&&Ke.binding&&Ke.binding("util")}catch(e){}}(),Xe=Ze&&Ze.isArrayBuffer,Qe=Ze&&Ze.isDate,Je=Ze&&Ze.isMap,et=Ze&&Ze.isRegExp,tt=Ze&&Ze.isSet,nt=Ze&&Ze.isTypedArray;function rt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function ot(e,t,n,r){for(var o=-1,i=null==e?0:e.length;++o<i;){var a=e[o];t(r,a,n(a),e)}return r}function it(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function at(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function st(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function ut(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}function lt(e,t){return!!(null==e?0:e.length)&&bt(e,t,0)>-1}function ct(e,t,n){for(var r=-1,o=null==e?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}function ft(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}function dt(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}function pt(e,t,n,r){var o=-1,i=null==e?0:e.length;for(r&&i&&(n=e[++o]);++o<i;)n=t(n,e[o],o,e);return n}function ht(e,t,n,r){var o=null==e?0:e.length;for(r&&o&&(n=e[--o]);o--;)n=t(n,e[o],o,e);return n}function vt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var gt=kt("length");function mt(e,t,n){var r;return n(e,(function(e,n,o){if(t(e,n,o))return r=n,!1})),r}function yt(e,t,n,r){for(var o=e.length,i=n+(r?1:-1);r?i--:++i<o;)if(t(e[i],i,e))return i;return-1}function bt(e,t,n){return t==t?function(e,t,n){var r=n-1,o=e.length;for(;++r<o;)if(e[r]===t)return r;return-1}(e,t,n):yt(e,_t,n)}function wt(e,t,n,r){for(var o=n-1,i=e.length;++o<i;)if(r(e[o],t))return o;return-1}function _t(e){return e!=e}function xt(e,t){var n=null==e?0:e.length;return n?Et(e,t)/n:NaN}function kt(e){return function(t){return null==t?void 0:t[e]}}function Ct(e){return function(t){return null==e?void 0:e[t]}}function Ot(e,t,n,r,o){return o(e,(function(e,o,i){n=r?(r=!1,e):t(n,e,o,i)})),n}function Et(e,t){for(var n,r=-1,o=e.length;++r<o;){var i=t(e[r]);void 0!==i&&(n=void 0===n?i:n+i)}return n}function St(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Tt(e){return e?e.slice(0,Yt(e)+1).replace(Y,""):e}function jt(e){return function(t){return e(t)}}function Mt(e,t){return ft(t,(function(t){return e[t]}))}function Lt(e,t){return e.has(t)}function At(e,t){for(var n=-1,r=e.length;++n<r&&bt(t,e[n],0)>-1;);return n}function Pt(e,t){for(var n=e.length;n--&&bt(t,e[n],0)>-1;);return n}function Rt(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}var Dt=Ct({"\xc0":"A","\xc1":"A","\xc2":"A","\xc3":"A","\xc4":"A","\xc5":"A","\xe0":"a","\xe1":"a","\xe2":"a","\xe3":"a","\xe4":"a","\xe5":"a","\xc7":"C","\xe7":"c","\xd0":"D","\xf0":"d","\xc8":"E","\xc9":"E","\xca":"E","\xcb":"E","\xe8":"e","\xe9":"e","\xea":"e","\xeb":"e","\xcc":"I","\xcd":"I","\xce":"I","\xcf":"I","\xec":"i","\xed":"i","\xee":"i","\xef":"i","\xd1":"N","\xf1":"n","\xd2":"O","\xd3":"O","\xd4":"O","\xd5":"O","\xd6":"O","\xd8":"O","\xf2":"o","\xf3":"o","\xf4":"o","\xf5":"o","\xf6":"o","\xf8":"o","\xd9":"U","\xda":"U","\xdb":"U","\xdc":"U","\xf9":"u","\xfa":"u","\xfb":"u","\xfc":"u","\xdd":"Y","\xfd":"y","\xff":"y","\xc6":"Ae","\xe6":"ae","\xde":"Th","\xfe":"th","\xdf":"ss","\u0100":"A","\u0102":"A","\u0104":"A","\u0101":"a","\u0103":"a","\u0105":"a","\u0106":"C","\u0108":"C","\u010a":"C","\u010c":"C","\u0107":"c","\u0109":"c","\u010b":"c","\u010d":"c","\u010e":"D","\u0110":"D","\u010f":"d","\u0111":"d","\u0112":"E","\u0114":"E","\u0116":"E","\u0118":"E","\u011a":"E","\u0113":"e","\u0115":"e","\u0117":"e","\u0119":"e","\u011b":"e","\u011c":"G","\u011e":"G","\u0120":"G","\u0122":"G","\u011d":"g","\u011f":"g","\u0121":"g","\u0123":"g","\u0124":"H","\u0126":"H","\u0125":"h","\u0127":"h","\u0128":"I","\u012a":"I","\u012c":"I","\u012e":"I","\u0130":"I","\u0129":"i","\u012b":"i","\u012d":"i","\u012f":"i","\u0131":"i","\u0134":"J","\u0135":"j","\u0136":"K","\u0137":"k","\u0138":"k","\u0139":"L","\u013b":"L","\u013d":"L","\u013f":"L","\u0141":"L","\u013a":"l","\u013c":"l","\u013e":"l","\u0140":"l","\u0142":"l","\u0143":"N","\u0145":"N","\u0147":"N","\u014a":"N","\u0144":"n","\u0146":"n","\u0148":"n","\u014b":"n","\u014c":"O","\u014e":"O","\u0150":"O","\u014d":"o","\u014f":"o","\u0151":"o","\u0154":"R","\u0156":"R","\u0158":"R","\u0155":"r","\u0157":"r","\u0159":"r","\u015a":"S","\u015c":"S","\u015e":"S","\u0160":"S","\u015b":"s","\u015d":"s","\u015f":"s","\u0161":"s","\u0162":"T","\u0164":"T","\u0166":"T","\u0163":"t","\u0165":"t","\u0167":"t","\u0168":"U","\u016a":"U","\u016c":"U","\u016e":"U","\u0170":"U","\u0172":"U","\u0169":"u","\u016b":"u","\u016d":"u","\u016f":"u","\u0171":"u","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017b":"Z","\u017d":"Z","\u017a":"z","\u017c":"z","\u017e":"z","\u0132":"IJ","\u0133":"ij","\u0152":"Oe","\u0153":"oe","\u0149":"'n","\u017f":"s"}),It=Ct({"&":"&","<":"<",">":">",'"':""","'":"'"});function Nt(e){return"\\"+Be[e]}function zt(e){return Re.test(e)}function Ft(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function Bt(e,t){return function(n){return e(t(n))}}function Ht(e,t){for(var n=-1,r=e.length,i=0,a=[];++n<r;){var s=e[n];s!==t&&s!==o||(e[n]=o,a[i++]=n)}return a}function Ut(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function Wt(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}function Vt(e){return zt(e)?function(e){var t=Ae.lastIndex=0;for(;Ae.test(e);)++t;return t}(e):gt(e)}function qt(e){return zt(e)?function(e){return e.match(Ae)||[]}(e):function(e){return e.split("")}(e)}function Yt(e){for(var t=e.length;t--&&G.test(e.charAt(t)););return t}var Gt=Ct({"&":"&","<":"<",">":">",""":'"',"'":"'"});var $t=function e(t){var n,G=(t=null==t?qe:$t.defaults(qe.Object(),t,$t.pick(qe,Ie))).Array,ce=t.Date,fe=t.Error,de=t.Function,pe=t.Math,he=t.Object,ve=t.RegExp,ge=t.String,me=t.TypeError,ye=G.prototype,be=de.prototype,we=he.prototype,_e=t["__core-js_shared__"],xe=be.toString,ke=we.hasOwnProperty,Ce=0,Oe=(n=/[^.]+$/.exec(_e&&_e.keys&&_e.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",Ee=we.toString,Se=xe.call(he),Te=qe._,je=ve("^"+xe.call(ke).replace(V,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ae=$e?t.Buffer:void 0,Re=t.Symbol,Be=t.Uint8Array,We=Ae?Ae.allocUnsafe:void 0,Ve=Bt(he.getPrototypeOf,he),Ye=he.create,Ge=we.propertyIsEnumerable,Ke=ye.splice,Ze=Re?Re.isConcatSpreadable:void 0,gt=Re?Re.iterator:void 0,Ct=Re?Re.toStringTag:void 0,Kt=function(){try{var e=ti(he,"defineProperty");return e({},"",{}),e}catch(e){}}(),Zt=t.clearTimeout!==qe.clearTimeout&&t.clearTimeout,Xt=ce&&ce.now!==qe.Date.now&&ce.now,Qt=t.setTimeout!==qe.setTimeout&&t.setTimeout,Jt=pe.ceil,en=pe.floor,tn=he.getOwnPropertySymbols,nn=Ae?Ae.isBuffer:void 0,rn=t.isFinite,on=ye.join,an=Bt(he.keys,he),sn=pe.max,un=pe.min,ln=ce.now,cn=t.parseInt,fn=pe.random,dn=ye.reverse,pn=ti(t,"DataView"),hn=ti(t,"Map"),vn=ti(t,"Promise"),gn=ti(t,"Set"),mn=ti(t,"WeakMap"),yn=ti(he,"create"),bn=mn&&new mn,wn={},_n=Ti(pn),xn=Ti(hn),kn=Ti(vn),Cn=Ti(gn),On=Ti(mn),En=Re?Re.prototype:void 0,Sn=En?En.valueOf:void 0,Tn=En?En.toString:void 0;function jn(e){if(qa(e)&&!Ra(e)&&!(e instanceof Pn)){if(e instanceof An)return e;if(ke.call(e,"__wrapped__"))return ji(e)}return new An(e)}var Mn=function(){function e(){}return function(t){if(!Va(t))return{};if(Ye)return Ye(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Ln(){}function An(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}function Pn(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function Rn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Dn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function In(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Nn(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new In;++t<n;)this.add(e[t])}function zn(e){var t=this.__data__=new Dn(e);this.size=t.size}function Fn(e,t){var n=Ra(e),r=!n&&Pa(e),o=!n&&!r&&za(e),i=!n&&!r&&!o&&Ja(e),a=n||r||o||i,s=a?St(e.length,ge):[],u=s.length;for(var l in e)!t&&!ke.call(e,l)||a&&("length"==l||o&&("offset"==l||"parent"==l)||i&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||ui(l,u))||s.push(l);return s}function Bn(e){var t=e.length;return t?e[Nr(0,t-1)]:void 0}function Hn(e,t){return Oi(bo(e),Zn(t,0,e.length))}function Un(e){return Oi(bo(e))}function Wn(e,t,n){(void 0!==n&&!Ma(e[t],n)||void 0===n&&!(t in e))&&$n(e,t,n)}function Vn(e,t,n){var r=e[t];ke.call(e,t)&&Ma(r,n)&&(void 0!==n||t in e)||$n(e,t,n)}function qn(e,t){for(var n=e.length;n--;)if(Ma(e[n][0],t))return n;return-1}function Yn(e,t,n,r){return tr(e,(function(e,o,i){t(r,e,n(e),i)})),r}function Gn(e,t){return e&&wo(t,_s(t),e)}function $n(e,t,n){"__proto__"==t&&Kt?Kt(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Kn(e,t){for(var n=-1,r=t.length,o=G(r),i=null==e;++n<r;)o[n]=i?void 0:gs(e,t[n]);return o}function Zn(e,t,n){return e==e&&(void 0!==n&&(e=e<=n?e:n),void 0!==t&&(e=e>=t?e:t)),e}function Xn(e,t,n,r,o,i){var s,c=1&t,w=2&t,L=4&t;if(n&&(s=o?n(e,r,o,i):n(e)),void 0!==s)return s;if(!Va(e))return e;var A=Ra(e);if(A){if(s=function(e){var t=e.length,n=new e.constructor(t);t&&"string"==typeof e[0]&&ke.call(e,"index")&&(n.index=e.index,n.input=e.input);return n}(e),!c)return bo(e,s)}else{var P=oi(e),R=P==f||P==d;if(za(e))return po(e,c);if(P==v||P==a||R&&!o){if(s=w||R?{}:ai(e),!c)return w?function(e,t){return wo(e,ri(e),t)}(e,function(e,t){return e&&wo(t,xs(t),e)}(s,e)):function(e,t){return wo(e,ni(e),t)}(e,Gn(s,e))}else{if(!Fe[P])return o?e:{};s=function(e,t,n){var r=e.constructor;switch(t){case _:return ho(e);case u:case l:return new r(+e);case x:return function(e,t){var n=t?ho(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case k:case C:case O:case E:case S:case T:case"[object Uint8ClampedArray]":case j:case M:return vo(e,n);case p:return new r;case h:case y:return new r(e);case g:return function(e){var t=new e.constructor(e.source,te.exec(e));return t.lastIndex=e.lastIndex,t}(e);case m:return new r;case b:return o=e,Sn?he(Sn.call(o)):{}}var o}(e,P,c)}}i||(i=new zn);var D=i.get(e);if(D)return D;i.set(e,s),Za(e)?e.forEach((function(r){s.add(Xn(r,t,n,r,e,i))})):Ya(e)&&e.forEach((function(r,o){s.set(o,Xn(r,t,n,o,e,i))}));var I=A?void 0:(L?w?$o:Go:w?xs:_s)(e);return it(I||e,(function(r,o){I&&(r=e[o=r]),Vn(s,o,Xn(r,t,n,o,e,i))})),s}function Qn(e,t,n){var r=n.length;if(null==e)return!r;for(e=he(e);r--;){var o=n[r],i=t[o],a=e[o];if(void 0===a&&!(o in e)||!i(a))return!1}return!0}function Jn(e,t,n){if("function"!=typeof e)throw new me(r);return _i((function(){e.apply(void 0,n)}),t)}function er(e,t,n,r){var o=-1,i=lt,a=!0,s=e.length,u=[],l=t.length;if(!s)return u;n&&(t=ft(t,jt(n))),r?(i=ct,a=!1):t.length>=200&&(i=Lt,a=!1,t=new Nn(t));e:for(;++o<s;){var c=e[o],f=null==n?c:n(c);if(c=r||0!==c?c:0,a&&f==f){for(var d=l;d--;)if(t[d]===f)continue e;u.push(c)}else i(t,f,r)||u.push(c)}return u}jn.templateSettings={escape:z,evaluate:F,interpolate:B,variable:"",imports:{_:jn}},jn.prototype=Ln.prototype,jn.prototype.constructor=jn,An.prototype=Mn(Ln.prototype),An.prototype.constructor=An,Pn.prototype=Mn(Ln.prototype),Pn.prototype.constructor=Pn,Rn.prototype.clear=function(){this.__data__=yn?yn(null):{},this.size=0},Rn.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Rn.prototype.get=function(e){var t=this.__data__;if(yn){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return ke.call(t,e)?t[e]:void 0},Rn.prototype.has=function(e){var t=this.__data__;return yn?void 0!==t[e]:ke.call(t,e)},Rn.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=yn&&void 0===t?"__lodash_hash_undefined__":t,this},Dn.prototype.clear=function(){this.__data__=[],this.size=0},Dn.prototype.delete=function(e){var t=this.__data__,n=qn(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ke.call(t,n,1),--this.size,!0)},Dn.prototype.get=function(e){var t=this.__data__,n=qn(t,e);return n<0?void 0:t[n][1]},Dn.prototype.has=function(e){return qn(this.__data__,e)>-1},Dn.prototype.set=function(e,t){var n=this.__data__,r=qn(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},In.prototype.clear=function(){this.size=0,this.__data__={hash:new Rn,map:new(hn||Dn),string:new Rn}},In.prototype.delete=function(e){var t=Jo(this,e).delete(e);return this.size-=t?1:0,t},In.prototype.get=function(e){return Jo(this,e).get(e)},In.prototype.has=function(e){return Jo(this,e).has(e)},In.prototype.set=function(e,t){var n=Jo(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Nn.prototype.add=Nn.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},Nn.prototype.has=function(e){return this.__data__.has(e)},zn.prototype.clear=function(){this.__data__=new Dn,this.size=0},zn.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},zn.prototype.get=function(e){return this.__data__.get(e)},zn.prototype.has=function(e){return this.__data__.has(e)},zn.prototype.set=function(e,t){var n=this.__data__;if(n instanceof Dn){var r=n.__data__;if(!hn||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new In(r)}return n.set(e,t),this.size=n.size,this};var tr=ko(lr),nr=ko(cr,!0);function rr(e,t){var n=!0;return tr(e,(function(e,r,o){return n=!!t(e,r,o)})),n}function or(e,t,n){for(var r=-1,o=e.length;++r<o;){var i=e[r],a=t(i);if(null!=a&&(void 0===s?a==a&&!Qa(a):n(a,s)))var s=a,u=i}return u}function ir(e,t){var n=[];return tr(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}function ar(e,t,n,r,o){var i=-1,a=e.length;for(n||(n=si),o||(o=[]);++i<a;){var s=e[i];t>0&&n(s)?t>1?ar(s,t-1,n,r,o):dt(o,s):r||(o[o.length]=s)}return o}var sr=Co(),ur=Co(!0);function lr(e,t){return e&&sr(e,t,_s)}function cr(e,t){return e&&ur(e,t,_s)}function fr(e,t){return ut(t,(function(t){return Ha(e[t])}))}function dr(e,t){for(var n=0,r=(t=uo(t,e)).length;null!=e&&n<r;)e=e[Si(t[n++])];return n&&n==r?e:void 0}function pr(e,t,n){var r=t(e);return Ra(e)?r:dt(r,n(e))}function hr(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Ct&&Ct in he(e)?function(e){var t=ke.call(e,Ct),n=e[Ct];try{e[Ct]=void 0;var r=!0}catch(e){}var o=Ee.call(e);r&&(t?e[Ct]=n:delete e[Ct]);return o}(e):function(e){return Ee.call(e)}(e)}function vr(e,t){return e>t}function gr(e,t){return null!=e&&ke.call(e,t)}function mr(e,t){return null!=e&&t in he(e)}function yr(e,t,n){for(var r=n?ct:lt,o=e[0].length,i=e.length,a=i,s=G(i),u=1/0,l=[];a--;){var c=e[a];a&&t&&(c=ft(c,jt(t))),u=un(c.length,u),s[a]=!n&&(t||o>=120&&c.length>=120)?new Nn(a&&c):void 0}c=e[0];var f=-1,d=s[0];e:for(;++f<o&&l.length<u;){var p=c[f],h=t?t(p):p;if(p=n||0!==p?p:0,!(d?Lt(d,h):r(l,h,n))){for(a=i;--a;){var v=s[a];if(!(v?Lt(v,h):r(e[a],h,n)))continue e}d&&d.push(h),l.push(p)}}return l}function br(e,t,n){var r=null==(e=mi(e,t=uo(t,e)))?e:e[Si(Bi(t))];return null==r?void 0:rt(r,e,n)}function wr(e){return qa(e)&&hr(e)==a}function _r(e,t,n,r,o){return e===t||(null==e||null==t||!qa(e)&&!qa(t)?e!=e&&t!=t:function(e,t,n,r,o,i){var f=Ra(e),d=Ra(t),w=f?s:oi(e),k=d?s:oi(t),C=(w=w==a?v:w)==v,O=(k=k==a?v:k)==v,E=w==k;if(E&&za(e)){if(!za(t))return!1;f=!0,C=!1}if(E&&!C)return i||(i=new zn),f||Ja(e)?qo(e,t,n,r,o,i):function(e,t,n,r,o,i,a){switch(n){case x:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _:return!(e.byteLength!=t.byteLength||!i(new Be(e),new Be(t)));case u:case l:case h:return Ma(+e,+t);case c:return e.name==t.name&&e.message==t.message;case g:case y:return e==t+"";case p:var s=Ft;case m:var f=1&r;if(s||(s=Ut),e.size!=t.size&&!f)return!1;var d=a.get(e);if(d)return d==t;r|=2,a.set(e,t);var v=qo(s(e),s(t),r,o,i,a);return a.delete(e),v;case b:if(Sn)return Sn.call(e)==Sn.call(t)}return!1}(e,t,w,n,r,o,i);if(!(1&n)){var S=C&&ke.call(e,"__wrapped__"),T=O&&ke.call(t,"__wrapped__");if(S||T){var j=S?e.value():e,M=T?t.value():t;return i||(i=new zn),o(j,M,n,r,i)}}if(!E)return!1;return i||(i=new zn),function(e,t,n,r,o,i){var a=1&n,s=Go(e),u=s.length,l=Go(t).length;if(u!=l&&!a)return!1;var c=u;for(;c--;){var f=s[c];if(!(a?f in t:ke.call(t,f)))return!1}var d=i.get(e),p=i.get(t);if(d&&p)return d==t&&p==e;var h=!0;i.set(e,t),i.set(t,e);var v=a;for(;++c<u;){f=s[c];var g=e[f],m=t[f];if(r)var y=a?r(m,g,f,t,e,i):r(g,m,f,e,t,i);if(!(void 0===y?g===m||o(g,m,n,r,i):y)){h=!1;break}v||(v="constructor"==f)}if(h&&!v){var b=e.constructor,w=t.constructor;b==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(h=!1)}return i.delete(e),i.delete(t),h}(e,t,n,r,o,i)}(e,t,n,r,_r,o))}function xr(e,t,n,r){var o=n.length,i=o,a=!r;if(null==e)return!i;for(e=he(e);o--;){var s=n[o];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<i;){var u=(s=n[o])[0],l=e[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in e))return!1}else{var f=new zn;if(r)var d=r(l,c,u,e,t,f);if(!(void 0===d?_r(c,l,3,r,f):d))return!1}}return!0}function kr(e){return!(!Va(e)||(t=e,Oe&&Oe in t))&&(Ha(e)?je:oe).test(Ti(e));var t}function Cr(e){return"function"==typeof e?e:null==e?Gs:"object"==typeof e?Ra(e)?Mr(e[0],e[1]):jr(e):nu(e)}function Or(e){if(!pi(e))return an(e);var t=[];for(var n in he(e))ke.call(e,n)&&"constructor"!=n&&t.push(n);return t}function Er(e){if(!Va(e))return function(e){var t=[];if(null!=e)for(var n in he(e))t.push(n);return t}(e);var t=pi(e),n=[];for(var r in e)("constructor"!=r||!t&&ke.call(e,r))&&n.push(r);return n}function Sr(e,t){return e<t}function Tr(e,t){var n=-1,r=Ia(e)?G(e.length):[];return tr(e,(function(e,o,i){r[++n]=t(e,o,i)})),r}function jr(e){var t=ei(e);return 1==t.length&&t[0][2]?vi(t[0][0],t[0][1]):function(n){return n===e||xr(n,e,t)}}function Mr(e,t){return ci(e)&&hi(t)?vi(Si(e),t):function(n){var r=gs(n,e);return void 0===r&&r===t?ms(n,e):_r(t,r,3)}}function Lr(e,t,n,r,o){e!==t&&sr(t,(function(i,a){if(o||(o=new zn),Va(i))!function(e,t,n,r,o,i,a){var s=bi(e,n),u=bi(t,n),l=a.get(u);if(l)return void Wn(e,n,l);var c=i?i(s,u,n+"",e,t,a):void 0,f=void 0===c;if(f){var d=Ra(u),p=!d&&za(u),h=!d&&!p&&Ja(u);c=u,d||p||h?Ra(s)?c=s:Na(s)?c=bo(s):p?(f=!1,c=po(u,!0)):h?(f=!1,c=vo(u,!0)):c=[]:$a(u)||Pa(u)?(c=s,Pa(s)?c=ss(s):Va(s)&&!Ha(s)||(c=ai(u))):f=!1}f&&(a.set(u,c),o(c,u,r,i,a),a.delete(u));Wn(e,n,c)}(e,t,a,n,Lr,r,o);else{var s=r?r(bi(e,a),i,a+"",e,t,o):void 0;void 0===s&&(s=i),Wn(e,a,s)}}),xs)}function Ar(e,t){var n=e.length;if(n)return ui(t+=t<0?n:0,n)?e[t]:void 0}function Pr(e,t,n){t=t.length?ft(t,(function(e){return Ra(e)?function(t){return dr(t,1===e.length?e[0]:e)}:e})):[Gs];var r=-1;return t=ft(t,jt(Qo())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(Tr(e,(function(e,n,o){return{criteria:ft(t,(function(t){return t(e)})),index:++r,value:e}})),(function(e,t){return function(e,t,n){var r=-1,o=e.criteria,i=t.criteria,a=o.length,s=n.length;for(;++r<a;){var u=go(o[r],i[r]);if(u){if(r>=s)return u;var l=n[r];return u*("desc"==l?-1:1)}}return e.index-t.index}(e,t,n)}))}function Rr(e,t,n){for(var r=-1,o=t.length,i={};++r<o;){var a=t[r],s=dr(e,a);n(s,a)&&Ur(i,uo(a,e),s)}return i}function Dr(e,t,n,r){var o=r?wt:bt,i=-1,a=t.length,s=e;for(e===t&&(t=bo(t)),n&&(s=ft(e,jt(n)));++i<a;)for(var u=0,l=t[i],c=n?n(l):l;(u=o(s,c,u,r))>-1;)s!==e&&Ke.call(s,u,1),Ke.call(e,u,1);return e}function Ir(e,t){for(var n=e?t.length:0,r=n-1;n--;){var o=t[n];if(n==r||o!==i){var i=o;ui(o)?Ke.call(e,o,1):eo(e,o)}}return e}function Nr(e,t){return e+en(fn()*(t-e+1))}function zr(e,t){var n="";if(!e||t<1||t>9007199254740991)return n;do{t%2&&(n+=e),(t=en(t/2))&&(e+=e)}while(t);return n}function Fr(e,t){return xi(gi(e,t,Gs),e+"")}function Br(e){return Bn(Ms(e))}function Hr(e,t){var n=Ms(e);return Oi(n,Zn(t,0,n.length))}function Ur(e,t,n,r){if(!Va(e))return e;for(var o=-1,i=(t=uo(t,e)).length,a=i-1,s=e;null!=s&&++o<i;){var u=Si(t[o]),l=n;if("__proto__"===u||"constructor"===u||"prototype"===u)return e;if(o!=a){var c=s[u];void 0===(l=r?r(c,u,s):void 0)&&(l=Va(c)?c:ui(t[o+1])?[]:{})}Vn(s,u,l),s=s[u]}return e}var Wr=bn?function(e,t){return bn.set(e,t),e}:Gs,Vr=Kt?function(e,t){return Kt(e,"toString",{configurable:!0,enumerable:!1,value:Vs(t),writable:!0})}:Gs;function qr(e){return Oi(Ms(e))}function Yr(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=G(o);++r<o;)i[r]=e[r+t];return i}function Gr(e,t){var n;return tr(e,(function(e,r,o){return!(n=t(e,r,o))})),!!n}function $r(e,t,n){var r=0,o=null==e?r:e.length;if("number"==typeof t&&t==t&&o<=2147483647){for(;r<o;){var i=r+o>>>1,a=e[i];null!==a&&!Qa(a)&&(n?a<=t:a<t)?r=i+1:o=i}return o}return Kr(e,t,Gs,n)}function Kr(e,t,n,r){var o=0,i=null==e?0:e.length;if(0===i)return 0;for(var a=(t=n(t))!=t,s=null===t,u=Qa(t),l=void 0===t;o<i;){var c=en((o+i)/2),f=n(e[c]),d=void 0!==f,p=null===f,h=f==f,v=Qa(f);if(a)var g=r||h;else g=l?h&&(r||d):s?h&&d&&(r||!p):u?h&&d&&!p&&(r||!v):!p&&!v&&(r?f<=t:f<t);g?o=c+1:i=c}return un(i,4294967294)}function Zr(e,t){for(var n=-1,r=e.length,o=0,i=[];++n<r;){var a=e[n],s=t?t(a):a;if(!n||!Ma(s,u)){var u=s;i[o++]=0===a?0:a}}return i}function Xr(e){return"number"==typeof e?e:Qa(e)?NaN:+e}function Qr(e){if("string"==typeof e)return e;if(Ra(e))return ft(e,Qr)+"";if(Qa(e))return Tn?Tn.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Jr(e,t,n){var r=-1,o=lt,i=e.length,a=!0,s=[],u=s;if(n)a=!1,o=ct;else if(i>=200){var l=t?null:Fo(e);if(l)return Ut(l);a=!1,o=Lt,u=new Nn}else u=t?[]:s;e:for(;++r<i;){var c=e[r],f=t?t(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var d=u.length;d--;)if(u[d]===f)continue e;t&&u.push(f),s.push(c)}else o(u,f,n)||(u!==s&&u.push(f),s.push(c))}return s}function eo(e,t){return null==(e=mi(e,t=uo(t,e)))||delete e[Si(Bi(t))]}function to(e,t,n,r){return Ur(e,t,n(dr(e,t)),r)}function no(e,t,n,r){for(var o=e.length,i=r?o:-1;(r?i--:++i<o)&&t(e[i],i,e););return n?Yr(e,r?0:i,r?i+1:o):Yr(e,r?i+1:0,r?o:i)}function ro(e,t){var n=e;return n instanceof Pn&&(n=n.value()),pt(t,(function(e,t){return t.func.apply(t.thisArg,dt([e],t.args))}),n)}function oo(e,t,n){var r=e.length;if(r<2)return r?Jr(e[0]):[];for(var o=-1,i=G(r);++o<r;)for(var a=e[o],s=-1;++s<r;)s!=o&&(i[o]=er(i[o]||a,e[s],t,n));return Jr(ar(i,1),t,n)}function io(e,t,n){for(var r=-1,o=e.length,i=t.length,a={};++r<o;){var s=r<i?t[r]:void 0;n(a,e[r],s)}return a}function ao(e){return Na(e)?e:[]}function so(e){return"function"==typeof e?e:Gs}function uo(e,t){return Ra(e)?e:ci(e,t)?[e]:Ei(us(e))}var lo=Fr;function co(e,t,n){var r=e.length;return n=void 0===n?r:n,!t&&n>=r?e:Yr(e,t,n)}var fo=Zt||function(e){return qe.clearTimeout(e)};function po(e,t){if(t)return e.slice();var n=e.length,r=We?We(n):new e.constructor(n);return e.copy(r),r}function ho(e){var t=new e.constructor(e.byteLength);return new Be(t).set(new Be(e)),t}function vo(e,t){var n=t?ho(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function go(e,t){if(e!==t){var n=void 0!==e,r=null===e,o=e==e,i=Qa(e),a=void 0!==t,s=null===t,u=t==t,l=Qa(t);if(!s&&!l&&!i&&e>t||i&&a&&u&&!s&&!l||r&&a&&u||!n&&u||!o)return 1;if(!r&&!i&&!l&&e<t||l&&n&&o&&!r&&!i||s&&n&&o||!a&&o||!u)return-1}return 0}function mo(e,t,n,r){for(var o=-1,i=e.length,a=n.length,s=-1,u=t.length,l=sn(i-a,0),c=G(u+l),f=!r;++s<u;)c[s]=t[s];for(;++o<a;)(f||o<i)&&(c[n[o]]=e[o]);for(;l--;)c[s++]=e[o++];return c}function yo(e,t,n,r){for(var o=-1,i=e.length,a=-1,s=n.length,u=-1,l=t.length,c=sn(i-s,0),f=G(c+l),d=!r;++o<c;)f[o]=e[o];for(var p=o;++u<l;)f[p+u]=t[u];for(;++a<s;)(d||o<i)&&(f[p+n[a]]=e[o++]);return f}function bo(e,t){var n=-1,r=e.length;for(t||(t=G(r));++n<r;)t[n]=e[n];return t}function wo(e,t,n,r){var o=!n;n||(n={});for(var i=-1,a=t.length;++i<a;){var s=t[i],u=r?r(n[s],e[s],s,n,e):void 0;void 0===u&&(u=e[s]),o?$n(n,s,u):Vn(n,s,u)}return n}function _o(e,t){return function(n,r){var o=Ra(n)?ot:Yn,i=t?t():{};return o(n,e,Qo(r,2),i)}}function xo(e){return Fr((function(t,n){var r=-1,o=n.length,i=o>1?n[o-1]:void 0,a=o>2?n[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,a&&li(n[0],n[1],a)&&(i=o<3?void 0:i,o=1),t=he(t);++r<o;){var s=n[r];s&&e(t,s,r,i)}return t}))}function ko(e,t){return function(n,r){if(null==n)return n;if(!Ia(n))return e(n,r);for(var o=n.length,i=t?o:-1,a=he(n);(t?i--:++i<o)&&!1!==r(a[i],i,a););return n}}function Co(e){return function(t,n,r){for(var o=-1,i=he(t),a=r(t),s=a.length;s--;){var u=a[e?s:++o];if(!1===n(i[u],u,i))break}return t}}function Oo(e){return function(t){var n=zt(t=us(t))?qt(t):void 0,r=n?n[0]:t.charAt(0),o=n?co(n,1).join(""):t.slice(1);return r[e]()+o}}function Eo(e){return function(t){return pt(Hs(Ps(t).replace(Me,"")),e,"")}}function So(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=Mn(e.prototype),r=e.apply(n,t);return Va(r)?r:n}}function To(e){return function(t,n,r){var o=he(t);if(!Ia(t)){var i=Qo(n,3);t=_s(t),n=function(e){return i(o[e],e,o)}}var a=e(t,n,r);return a>-1?o[i?t[a]:a]:void 0}}function jo(e){return Yo((function(t){var n=t.length,o=n,i=An.prototype.thru;for(e&&t.reverse();o--;){var a=t[o];if("function"!=typeof a)throw new me(r);if(i&&!s&&"wrapper"==Zo(a))var s=new An([],!0)}for(o=s?o:n;++o<n;){var u=Zo(a=t[o]),l="wrapper"==u?Ko(a):void 0;s=l&&fi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?s[Zo(l[0])].apply(s,l[3]):1==a.length&&fi(a)?s[u]():s.thru(a)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&Ra(r))return s.plant(r).value();for(var o=0,i=n?t[o].apply(this,e):r;++o<n;)i=t[o].call(this,i);return i}}))}function Mo(e,t,n,r,o,i,a,s,u,l){var c=128&t,f=1&t,d=2&t,p=24&t,h=512&t,v=d?void 0:So(e);return function g(){for(var m=arguments.length,y=G(m),b=m;b--;)y[b]=arguments[b];if(p)var w=Xo(g),_=Rt(y,w);if(r&&(y=mo(y,r,o,p)),i&&(y=yo(y,i,a,p)),m-=_,p&&m<l){var x=Ht(y,w);return No(e,t,Mo,g.placeholder,n,y,x,s,u,l-m)}var k=f?n:this,C=d?k[e]:e;return m=y.length,s?y=yi(y,s):h&&m>1&&y.reverse(),c&&u<m&&(y.length=u),this&&this!==qe&&this instanceof g&&(C=v||So(C)),C.apply(k,y)}}function Lo(e,t){return function(n,r){return function(e,t,n,r){return lr(e,(function(e,o,i){t(r,n(e),o,i)})),r}(n,e,t(r),{})}}function Ao(e,t){return function(n,r){var o;if(void 0===n&&void 0===r)return t;if(void 0!==n&&(o=n),void 0!==r){if(void 0===o)return r;"string"==typeof n||"string"==typeof r?(n=Qr(n),r=Qr(r)):(n=Xr(n),r=Xr(r)),o=e(n,r)}return o}}function Po(e){return Yo((function(t){return t=ft(t,jt(Qo())),Fr((function(n){var r=this;return e(t,(function(e){return rt(e,r,n)}))}))}))}function Ro(e,t){var n=(t=void 0===t?" ":Qr(t)).length;if(n<2)return n?zr(t,e):t;var r=zr(t,Jt(e/Vt(t)));return zt(t)?co(qt(r),0,e).join(""):r.slice(0,e)}function Do(e){return function(t,n,r){return r&&"number"!=typeof r&&li(t,n,r)&&(n=r=void 0),t=rs(t),void 0===n?(n=t,t=0):n=rs(n),function(e,t,n,r){for(var o=-1,i=sn(Jt((t-e)/(n||1)),0),a=G(i);i--;)a[r?i:++o]=e,e+=n;return a}(t,n,r=void 0===r?t<n?1:-1:rs(r),e)}}function Io(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=as(t),n=as(n)),e(t,n)}}function No(e,t,n,r,o,i,a,s,u,l){var c=8&t;t|=c?32:64,4&(t&=~(c?64:32))||(t&=-4);var f=[e,t,o,c?i:void 0,c?a:void 0,c?void 0:i,c?void 0:a,s,u,l],d=n.apply(void 0,f);return fi(e)&&wi(d,f),d.placeholder=r,ki(d,e,t)}function zo(e){var t=pe[e];return function(e,n){if(e=as(e),(n=null==n?0:un(os(n),292))&&rn(e)){var r=(us(e)+"e").split("e");return+((r=(us(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var Fo=gn&&1/Ut(new gn([,-0]))[1]==1/0?function(e){return new gn(e)}:Qs;function Bo(e){return function(t){var n=oi(t);return n==p?Ft(t):n==m?Wt(t):function(e,t){return ft(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function Ho(e,t,n,i,a,s,u,l){var c=2&t;if(!c&&"function"!=typeof e)throw new me(r);var f=i?i.length:0;if(f||(t&=-97,i=a=void 0),u=void 0===u?u:sn(os(u),0),l=void 0===l?l:os(l),f-=a?a.length:0,64&t){var d=i,p=a;i=a=void 0}var h=c?void 0:Ko(e),v=[e,t,n,i,a,d,p,s,u,l];if(h&&function(e,t){var n=e[1],r=t[1],i=n|r,a=i<131,s=128==r&&8==n||128==r&&256==n&&e[7].length<=t[8]||384==r&&t[7].length<=t[8]&&8==n;if(!a&&!s)return e;1&r&&(e[2]=t[2],i|=1&n?0:4);var u=t[3];if(u){var l=e[3];e[3]=l?mo(l,u,t[4]):u,e[4]=l?Ht(e[3],o):t[4]}(u=t[5])&&(l=e[5],e[5]=l?yo(l,u,t[6]):u,e[6]=l?Ht(e[5],o):t[6]);(u=t[7])&&(e[7]=u);128&r&&(e[8]=null==e[8]?t[8]:un(e[8],t[8]));null==e[9]&&(e[9]=t[9]);e[0]=t[0],e[1]=i}(v,h),e=v[0],t=v[1],n=v[2],i=v[3],a=v[4],!(l=v[9]=void 0===v[9]?c?0:e.length:sn(v[9]-f,0))&&24&t&&(t&=-25),t&&1!=t)g=8==t||16==t?function(e,t,n){var r=So(e);return function o(){for(var i=arguments.length,a=G(i),s=i,u=Xo(o);s--;)a[s]=arguments[s];var l=i<3&&a[0]!==u&&a[i-1]!==u?[]:Ht(a,u);if((i-=l.length)<n)return No(e,t,Mo,o.placeholder,void 0,a,l,void 0,void 0,n-i);var c=this&&this!==qe&&this instanceof o?r:e;return rt(c,this,a)}}(e,t,l):32!=t&&33!=t||a.length?Mo.apply(void 0,v):function(e,t,n,r){var o=1&t,i=So(e);return function t(){for(var a=-1,s=arguments.length,u=-1,l=r.length,c=G(l+s),f=this&&this!==qe&&this instanceof t?i:e;++u<l;)c[u]=r[u];for(;s--;)c[u++]=arguments[++a];return rt(f,o?n:this,c)}}(e,t,n,i);else var g=function(e,t,n){var r=1&t,o=So(e);return function t(){var i=this&&this!==qe&&this instanceof t?o:e;return i.apply(r?n:this,arguments)}}(e,t,n);return ki((h?Wr:wi)(g,v),e,t)}function Uo(e,t,n,r){return void 0===e||Ma(e,we[n])&&!ke.call(r,n)?t:e}function Wo(e,t,n,r,o,i){return Va(e)&&Va(t)&&(i.set(t,e),Lr(e,t,void 0,Wo,i),i.delete(t)),e}function Vo(e){return $a(e)?void 0:e}function qo(e,t,n,r,o,i){var a=1&n,s=e.length,u=t.length;if(s!=u&&!(a&&u>s))return!1;var l=i.get(e),c=i.get(t);if(l&&c)return l==t&&c==e;var f=-1,d=!0,p=2&n?new Nn:void 0;for(i.set(e,t),i.set(t,e);++f<s;){var h=e[f],v=t[f];if(r)var g=a?r(v,h,f,t,e,i):r(h,v,f,e,t,i);if(void 0!==g){if(g)continue;d=!1;break}if(p){if(!vt(t,(function(e,t){if(!Lt(p,t)&&(h===e||o(h,e,n,r,i)))return p.push(t)}))){d=!1;break}}else if(h!==v&&!o(h,v,n,r,i)){d=!1;break}}return i.delete(e),i.delete(t),d}function Yo(e){return xi(gi(e,void 0,Di),e+"")}function Go(e){return pr(e,_s,ni)}function $o(e){return pr(e,xs,ri)}var Ko=bn?function(e){return bn.get(e)}:Qs;function Zo(e){for(var t=e.name+"",n=wn[t],r=ke.call(wn,t)?n.length:0;r--;){var o=n[r],i=o.func;if(null==i||i==e)return o.name}return t}function Xo(e){return(ke.call(jn,"placeholder")?jn:e).placeholder}function Qo(){var e=jn.iteratee||$s;return e=e===$s?Cr:e,arguments.length?e(arguments[0],arguments[1]):e}function Jo(e,t){var n,r,o=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof t?"string":"hash"]:o.map}function ei(e){for(var t=_s(e),n=t.length;n--;){var r=t[n],o=e[r];t[n]=[r,o,hi(o)]}return t}function ti(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return kr(n)?n:void 0}var ni=tn?function(e){return null==e?[]:(e=he(e),ut(tn(e),(function(t){return Ge.call(e,t)})))}:iu,ri=tn?function(e){for(var t=[];e;)dt(t,ni(e)),e=Ve(e);return t}:iu,oi=hr;function ii(e,t,n){for(var r=-1,o=(t=uo(t,e)).length,i=!1;++r<o;){var a=Si(t[r]);if(!(i=null!=e&&n(e,a)))break;e=e[a]}return i||++r!=o?i:!!(o=null==e?0:e.length)&&Wa(o)&&ui(a,o)&&(Ra(e)||Pa(e))}function ai(e){return"function"!=typeof e.constructor||pi(e)?{}:Mn(Ve(e))}function si(e){return Ra(e)||Pa(e)||!!(Ze&&e&&e[Ze])}function ui(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&ae.test(e))&&e>-1&&e%1==0&&e<t}function li(e,t,n){if(!Va(n))return!1;var r=typeof t;return!!("number"==r?Ia(n)&&ui(t,n.length):"string"==r&&t in n)&&Ma(n[t],e)}function ci(e,t){if(Ra(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Qa(e))||(U.test(e)||!H.test(e)||null!=t&&e in he(t))}function fi(e){var t=Zo(e),n=jn[t];if("function"!=typeof n||!(t in Pn.prototype))return!1;if(e===n)return!0;var r=Ko(n);return!!r&&e===r[0]}(pn&&oi(new pn(new ArrayBuffer(1)))!=x||hn&&oi(new hn)!=p||vn&&"[object Promise]"!=oi(vn.resolve())||gn&&oi(new gn)!=m||mn&&oi(new mn)!=w)&&(oi=function(e){var t=hr(e),n=t==v?e.constructor:void 0,r=n?Ti(n):"";if(r)switch(r){case _n:return x;case xn:return p;case kn:return"[object Promise]";case Cn:return m;case On:return w}return t});var di=_e?Ha:au;function pi(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||we)}function hi(e){return e==e&&!Va(e)}function vi(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in he(n)))}}function gi(e,t,n){return t=sn(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=sn(r.length-t,0),a=G(i);++o<i;)a[o]=r[t+o];o=-1;for(var s=G(t+1);++o<t;)s[o]=r[o];return s[t]=n(a),rt(e,this,s)}}function mi(e,t){return t.length<2?e:dr(e,Yr(t,0,-1))}function yi(e,t){for(var n=e.length,r=un(t.length,n),o=bo(e);r--;){var i=t[r];e[r]=ui(i,n)?o[i]:void 0}return e}function bi(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var wi=Ci(Wr),_i=Qt||function(e,t){return qe.setTimeout(e,t)},xi=Ci(Vr);function ki(e,t,n){var r=t+"";return xi(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace($,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return it(i,(function(n){var r="_."+n[0];t&n[1]&&!lt(e,r)&&e.push(r)})),e.sort()}(function(e){var t=e.match(K);return t?t[1].split(Z):[]}(r),n)))}function Ci(e){var t=0,n=0;return function(){var r=ln(),o=16-(r-n);if(n=r,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Oi(e,t){var n=-1,r=e.length,o=r-1;for(t=void 0===t?r:t;++n<t;){var i=Nr(n,o),a=e[i];e[i]=e[n],e[n]=a}return e.length=t,e}var Ei=function(e){var t=Ca(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(W,(function(e,n,r,o){t.push(r?o.replace(J,"$1"):n||e)})),t}));function Si(e){if("string"==typeof e||Qa(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Ti(e){if(null!=e){try{return xe.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function ji(e){if(e instanceof Pn)return e.clone();var t=new An(e.__wrapped__,e.__chain__);return t.__actions__=bo(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var Mi=Fr((function(e,t){return Na(e)?er(e,ar(t,1,Na,!0)):[]})),Li=Fr((function(e,t){var n=Bi(t);return Na(n)&&(n=void 0),Na(e)?er(e,ar(t,1,Na,!0),Qo(n,2)):[]})),Ai=Fr((function(e,t){var n=Bi(t);return Na(n)&&(n=void 0),Na(e)?er(e,ar(t,1,Na,!0),void 0,n):[]}));function Pi(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:os(n);return o<0&&(o=sn(r+o,0)),yt(e,Qo(t,3),o)}function Ri(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r-1;return void 0!==n&&(o=os(n),o=n<0?sn(r+o,0):un(o,r-1)),yt(e,Qo(t,3),o,!0)}function Di(e){return(null==e?0:e.length)?ar(e,1):[]}function Ii(e){return e&&e.length?e[0]:void 0}var Ni=Fr((function(e){var t=ft(e,ao);return t.length&&t[0]===e[0]?yr(t):[]})),zi=Fr((function(e){var t=Bi(e),n=ft(e,ao);return t===Bi(n)?t=void 0:n.pop(),n.length&&n[0]===e[0]?yr(n,Qo(t,2)):[]})),Fi=Fr((function(e){var t=Bi(e),n=ft(e,ao);return(t="function"==typeof t?t:void 0)&&n.pop(),n.length&&n[0]===e[0]?yr(n,void 0,t):[]}));function Bi(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}var Hi=Fr(Ui);function Ui(e,t){return e&&e.length&&t&&t.length?Dr(e,t):e}var Wi=Yo((function(e,t){var n=null==e?0:e.length,r=Kn(e,t);return Ir(e,ft(t,(function(e){return ui(e,n)?+e:e})).sort(go)),r}));function Vi(e){return null==e?e:dn.call(e)}var qi=Fr((function(e){return Jr(ar(e,1,Na,!0))})),Yi=Fr((function(e){var t=Bi(e);return Na(t)&&(t=void 0),Jr(ar(e,1,Na,!0),Qo(t,2))})),Gi=Fr((function(e){var t=Bi(e);return t="function"==typeof t?t:void 0,Jr(ar(e,1,Na,!0),void 0,t)}));function $i(e){if(!e||!e.length)return[];var t=0;return e=ut(e,(function(e){if(Na(e))return t=sn(e.length,t),!0})),St(t,(function(t){return ft(e,kt(t))}))}function Ki(e,t){if(!e||!e.length)return[];var n=$i(e);return null==t?n:ft(n,(function(e){return rt(t,void 0,e)}))}var Zi=Fr((function(e,t){return Na(e)?er(e,t):[]})),Xi=Fr((function(e){return oo(ut(e,Na))})),Qi=Fr((function(e){var t=Bi(e);return Na(t)&&(t=void 0),oo(ut(e,Na),Qo(t,2))})),Ji=Fr((function(e){var t=Bi(e);return t="function"==typeof t?t:void 0,oo(ut(e,Na),void 0,t)})),ea=Fr($i);var ta=Fr((function(e){var t=e.length,n=t>1?e[t-1]:void 0;return n="function"==typeof n?(e.pop(),n):void 0,Ki(e,n)}));function na(e){var t=jn(e);return t.__chain__=!0,t}function ra(e,t){return t(e)}var oa=Yo((function(e){var t=e.length,n=t?e[0]:0,r=this.__wrapped__,o=function(t){return Kn(t,e)};return!(t>1||this.__actions__.length)&&r instanceof Pn&&ui(n)?((r=r.slice(n,+n+(t?1:0))).__actions__.push({func:ra,args:[o],thisArg:void 0}),new An(r,this.__chain__).thru((function(e){return t&&!e.length&&e.push(void 0),e}))):this.thru(o)}));var ia=_o((function(e,t,n){ke.call(e,n)?++e[n]:$n(e,n,1)}));var aa=To(Pi),sa=To(Ri);function ua(e,t){return(Ra(e)?it:tr)(e,Qo(t,3))}function la(e,t){return(Ra(e)?at:nr)(e,Qo(t,3))}var ca=_o((function(e,t,n){ke.call(e,n)?e[n].push(t):$n(e,n,[t])}));var fa=Fr((function(e,t,n){var r=-1,o="function"==typeof t,i=Ia(e)?G(e.length):[];return tr(e,(function(e){i[++r]=o?rt(t,e,n):br(e,t,n)})),i})),da=_o((function(e,t,n){$n(e,n,t)}));function pa(e,t){return(Ra(e)?ft:Tr)(e,Qo(t,3))}var ha=_o((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));var va=Fr((function(e,t){if(null==e)return[];var n=t.length;return n>1&&li(e,t[0],t[1])?t=[]:n>2&&li(t[0],t[1],t[2])&&(t=[t[0]]),Pr(e,ar(t,1),[])})),ga=Xt||function(){return qe.Date.now()};function ma(e,t,n){return t=n?void 0:t,Ho(e,128,void 0,void 0,void 0,void 0,t=e&&null==t?e.length:t)}function ya(e,t){var n;if("function"!=typeof t)throw new me(r);return e=os(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=void 0),n}}var ba=Fr((function(e,t,n){var r=1;if(n.length){var o=Ht(n,Xo(ba));r|=32}return Ho(e,r,t,n,o)})),wa=Fr((function(e,t,n){var r=3;if(n.length){var o=Ht(n,Xo(wa));r|=32}return Ho(t,r,e,n,o)}));function _a(e,t,n){var o,i,a,s,u,l,c=0,f=!1,d=!1,p=!0;if("function"!=typeof e)throw new me(r);function h(t){var n=o,r=i;return o=i=void 0,c=t,s=e.apply(r,n)}function v(e){return c=e,u=_i(m,t),f?h(e):s}function g(e){var n=e-l;return void 0===l||n>=t||n<0||d&&e-c>=a}function m(){var e=ga();if(g(e))return y(e);u=_i(m,function(e){var n=t-(e-l);return d?un(n,a-(e-c)):n}(e))}function y(e){return u=void 0,p&&o?h(e):(o=i=void 0,s)}function b(){var e=ga(),n=g(e);if(o=arguments,i=this,l=e,n){if(void 0===u)return v(l);if(d)return fo(u),u=_i(m,t),h(l)}return void 0===u&&(u=_i(m,t)),s}return t=as(t)||0,Va(n)&&(f=!!n.leading,a=(d="maxWait"in n)?sn(as(n.maxWait)||0,t):a,p="trailing"in n?!!n.trailing:p),b.cancel=function(){void 0!==u&&fo(u),c=0,o=l=i=u=void 0},b.flush=function(){return void 0===u?s:y(ga())},b}var xa=Fr((function(e,t){return Jn(e,1,t)})),ka=Fr((function(e,t,n){return Jn(e,as(t)||0,n)}));function Ca(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new me(r);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(Ca.Cache||In),n}function Oa(e){if("function"!=typeof e)throw new me(r);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}Ca.Cache=In;var Ea=lo((function(e,t){var n=(t=1==t.length&&Ra(t[0])?ft(t[0],jt(Qo())):ft(ar(t,1),jt(Qo()))).length;return Fr((function(r){for(var o=-1,i=un(r.length,n);++o<i;)r[o]=t[o].call(this,r[o]);return rt(e,this,r)}))})),Sa=Fr((function(e,t){return Ho(e,32,void 0,t,Ht(t,Xo(Sa)))})),Ta=Fr((function(e,t){return Ho(e,64,void 0,t,Ht(t,Xo(Ta)))})),ja=Yo((function(e,t){return Ho(e,256,void 0,void 0,void 0,t)}));function Ma(e,t){return e===t||e!=e&&t!=t}var La=Io(vr),Aa=Io((function(e,t){return e>=t})),Pa=wr(function(){return arguments}())?wr:function(e){return qa(e)&&ke.call(e,"callee")&&!Ge.call(e,"callee")},Ra=G.isArray,Da=Xe?jt(Xe):function(e){return qa(e)&&hr(e)==_};function Ia(e){return null!=e&&Wa(e.length)&&!Ha(e)}function Na(e){return qa(e)&&Ia(e)}var za=nn||au,Fa=Qe?jt(Qe):function(e){return qa(e)&&hr(e)==l};function Ba(e){if(!qa(e))return!1;var t=hr(e);return t==c||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!$a(e)}function Ha(e){if(!Va(e))return!1;var t=hr(e);return t==f||t==d||"[object AsyncFunction]"==t||"[object Proxy]"==t}function Ua(e){return"number"==typeof e&&e==os(e)}function Wa(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}function Va(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function qa(e){return null!=e&&"object"==typeof e}var Ya=Je?jt(Je):function(e){return qa(e)&&oi(e)==p};function Ga(e){return"number"==typeof e||qa(e)&&hr(e)==h}function $a(e){if(!qa(e)||hr(e)!=v)return!1;var t=Ve(e);if(null===t)return!0;var n=ke.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&xe.call(n)==Se}var Ka=et?jt(et):function(e){return qa(e)&&hr(e)==g};var Za=tt?jt(tt):function(e){return qa(e)&&oi(e)==m};function Xa(e){return"string"==typeof e||!Ra(e)&&qa(e)&&hr(e)==y}function Qa(e){return"symbol"==typeof e||qa(e)&&hr(e)==b}var Ja=nt?jt(nt):function(e){return qa(e)&&Wa(e.length)&&!!ze[hr(e)]};var es=Io(Sr),ts=Io((function(e,t){return e<=t}));function ns(e){if(!e)return[];if(Ia(e))return Xa(e)?qt(e):bo(e);if(gt&&e[gt])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[gt]());var t=oi(e);return(t==p?Ft:t==m?Ut:Ms)(e)}function rs(e){return e?(e=as(e))===1/0||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}function os(e){var t=rs(e),n=t%1;return t==t?n?t-n:t:0}function is(e){return e?Zn(os(e),0,4294967295):0}function as(e){if("number"==typeof e)return e;if(Qa(e))return NaN;if(Va(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=Va(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Tt(e);var n=re.test(e);return n||ie.test(e)?Ue(e.slice(2),n?2:8):ne.test(e)?NaN:+e}function ss(e){return wo(e,xs(e))}function us(e){return null==e?"":Qr(e)}var ls=xo((function(e,t){if(pi(t)||Ia(t))wo(t,_s(t),e);else for(var n in t)ke.call(t,n)&&Vn(e,n,t[n])})),cs=xo((function(e,t){wo(t,xs(t),e)})),fs=xo((function(e,t,n,r){wo(t,xs(t),e,r)})),ds=xo((function(e,t,n,r){wo(t,_s(t),e,r)})),ps=Yo(Kn);var hs=Fr((function(e,t){e=he(e);var n=-1,r=t.length,o=r>2?t[2]:void 0;for(o&&li(t[0],t[1],o)&&(r=1);++n<r;)for(var i=t[n],a=xs(i),s=-1,u=a.length;++s<u;){var l=a[s],c=e[l];(void 0===c||Ma(c,we[l])&&!ke.call(e,l))&&(e[l]=i[l])}return e})),vs=Fr((function(e){return e.push(void 0,Wo),rt(Cs,void 0,e)}));function gs(e,t,n){var r=null==e?void 0:dr(e,t);return void 0===r?n:r}function ms(e,t){return null!=e&&ii(e,t,mr)}var ys=Lo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Ee.call(t)),e[t]=n}),Vs(Gs)),bs=Lo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Ee.call(t)),ke.call(e,t)?e[t].push(n):e[t]=[n]}),Qo),ws=Fr(br);function _s(e){return Ia(e)?Fn(e):Or(e)}function xs(e){return Ia(e)?Fn(e,!0):Er(e)}var ks=xo((function(e,t,n){Lr(e,t,n)})),Cs=xo((function(e,t,n,r){Lr(e,t,n,r)})),Os=Yo((function(e,t){var n={};if(null==e)return n;var r=!1;t=ft(t,(function(t){return t=uo(t,e),r||(r=t.length>1),t})),wo(e,$o(e),n),r&&(n=Xn(n,7,Vo));for(var o=t.length;o--;)eo(n,t[o]);return n}));var Es=Yo((function(e,t){return null==e?{}:function(e,t){return Rr(e,t,(function(t,n){return ms(e,n)}))}(e,t)}));function Ss(e,t){if(null==e)return{};var n=ft($o(e),(function(e){return[e]}));return t=Qo(t),Rr(e,n,(function(e,n){return t(e,n[0])}))}var Ts=Bo(_s),js=Bo(xs);function Ms(e){return null==e?[]:Mt(e,_s(e))}var Ls=Eo((function(e,t,n){return t=t.toLowerCase(),e+(n?As(t):t)}));function As(e){return Bs(us(e).toLowerCase())}function Ps(e){return(e=us(e))&&e.replace(se,Dt).replace(Le,"")}var Rs=Eo((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),Ds=Eo((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),Is=Oo("toLowerCase");var Ns=Eo((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));var zs=Eo((function(e,t,n){return e+(n?" ":"")+Bs(t)}));var Fs=Eo((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),Bs=Oo("toUpperCase");function Hs(e,t,n){return e=us(e),void 0===(t=n?void 0:t)?function(e){return De.test(e)}(e)?function(e){return e.match(Pe)||[]}(e):function(e){return e.match(X)||[]}(e):e.match(t)||[]}var Us=Fr((function(e,t){try{return rt(e,void 0,t)}catch(e){return Ba(e)?e:new fe(e)}})),Ws=Yo((function(e,t){return it(t,(function(t){t=Si(t),$n(e,t,ba(e[t],e))})),e}));function Vs(e){return function(){return e}}var qs=jo(),Ys=jo(!0);function Gs(e){return e}function $s(e){return Cr("function"==typeof e?e:Xn(e,1))}var Ks=Fr((function(e,t){return function(n){return br(n,e,t)}})),Zs=Fr((function(e,t){return function(n){return br(e,n,t)}}));function Xs(e,t,n){var r=_s(t),o=fr(t,r);null!=n||Va(t)&&(o.length||!r.length)||(n=t,t=e,e=this,o=fr(t,_s(t)));var i=!(Va(n)&&"chain"in n&&!n.chain),a=Ha(e);return it(o,(function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(i||t){var n=e(this.__wrapped__),o=n.__actions__=bo(this.__actions__);return o.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,dt([this.value()],arguments))})})),e}function Qs(){}var Js=Po(ft),eu=Po(st),tu=Po(vt);function nu(e){return ci(e)?kt(Si(e)):function(e){return function(t){return dr(t,e)}}(e)}var ru=Do(),ou=Do(!0);function iu(){return[]}function au(){return!1}var su=Ao((function(e,t){return e+t}),0),uu=zo("ceil"),lu=Ao((function(e,t){return e/t}),1),cu=zo("floor");var fu,du=Ao((function(e,t){return e*t}),1),pu=zo("round"),hu=Ao((function(e,t){return e-t}),0);return jn.after=function(e,t){if("function"!=typeof t)throw new me(r);return e=os(e),function(){if(--e<1)return t.apply(this,arguments)}},jn.ary=ma,jn.assign=ls,jn.assignIn=cs,jn.assignInWith=fs,jn.assignWith=ds,jn.at=ps,jn.before=ya,jn.bind=ba,jn.bindAll=Ws,jn.bindKey=wa,jn.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Ra(e)?e:[e]},jn.chain=na,jn.chunk=function(e,t,n){t=(n?li(e,t,n):void 0===t)?1:sn(os(t),0);var r=null==e?0:e.length;if(!r||t<1)return[];for(var o=0,i=0,a=G(Jt(r/t));o<r;)a[i++]=Yr(e,o,o+=t);return a},jn.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,o=[];++t<n;){var i=e[t];i&&(o[r++]=i)}return o},jn.concat=function(){var e=arguments.length;if(!e)return[];for(var t=G(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return dt(Ra(n)?bo(n):[n],ar(t,1))},jn.cond=function(e){var t=null==e?0:e.length,n=Qo();return e=t?ft(e,(function(e){if("function"!=typeof e[1])throw new me(r);return[n(e[0]),e[1]]})):[],Fr((function(n){for(var r=-1;++r<t;){var o=e[r];if(rt(o[0],this,n))return rt(o[1],this,n)}}))},jn.conforms=function(e){return function(e){var t=_s(e);return function(n){return Qn(n,e,t)}}(Xn(e,1))},jn.constant=Vs,jn.countBy=ia,jn.create=function(e,t){var n=Mn(e);return null==t?n:Gn(n,t)},jn.curry=function e(t,n,r){var o=Ho(t,8,void 0,void 0,void 0,void 0,void 0,n=r?void 0:n);return o.placeholder=e.placeholder,o},jn.curryRight=function e(t,n,r){var o=Ho(t,16,void 0,void 0,void 0,void 0,void 0,n=r?void 0:n);return o.placeholder=e.placeholder,o},jn.debounce=_a,jn.defaults=hs,jn.defaultsDeep=vs,jn.defer=xa,jn.delay=ka,jn.difference=Mi,jn.differenceBy=Li,jn.differenceWith=Ai,jn.drop=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,(t=n||void 0===t?1:os(t))<0?0:t,r):[]},jn.dropRight=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,0,(t=r-(t=n||void 0===t?1:os(t)))<0?0:t):[]},jn.dropRightWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!0,!0):[]},jn.dropWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!0):[]},jn.fill=function(e,t,n,r){var o=null==e?0:e.length;return o?(n&&"number"!=typeof n&&li(e,t,n)&&(n=0,r=o),function(e,t,n,r){var o=e.length;for((n=os(n))<0&&(n=-n>o?0:o+n),(r=void 0===r||r>o?o:os(r))<0&&(r+=o),r=n>r?0:is(r);n<r;)e[n++]=t;return e}(e,t,n,r)):[]},jn.filter=function(e,t){return(Ra(e)?ut:ir)(e,Qo(t,3))},jn.flatMap=function(e,t){return ar(pa(e,t),1)},jn.flatMapDeep=function(e,t){return ar(pa(e,t),1/0)},jn.flatMapDepth=function(e,t,n){return n=void 0===n?1:os(n),ar(pa(e,t),n)},jn.flatten=Di,jn.flattenDeep=function(e){return(null==e?0:e.length)?ar(e,1/0):[]},jn.flattenDepth=function(e,t){return(null==e?0:e.length)?ar(e,t=void 0===t?1:os(t)):[]},jn.flip=function(e){return Ho(e,512)},jn.flow=qs,jn.flowRight=Ys,jn.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var o=e[t];r[o[0]]=o[1]}return r},jn.functions=function(e){return null==e?[]:fr(e,_s(e))},jn.functionsIn=function(e){return null==e?[]:fr(e,xs(e))},jn.groupBy=ca,jn.initial=function(e){return(null==e?0:e.length)?Yr(e,0,-1):[]},jn.intersection=Ni,jn.intersectionBy=zi,jn.intersectionWith=Fi,jn.invert=ys,jn.invertBy=bs,jn.invokeMap=fa,jn.iteratee=$s,jn.keyBy=da,jn.keys=_s,jn.keysIn=xs,jn.map=pa,jn.mapKeys=function(e,t){var n={};return t=Qo(t,3),lr(e,(function(e,r,o){$n(n,t(e,r,o),e)})),n},jn.mapValues=function(e,t){var n={};return t=Qo(t,3),lr(e,(function(e,r,o){$n(n,r,t(e,r,o))})),n},jn.matches=function(e){return jr(Xn(e,1))},jn.matchesProperty=function(e,t){return Mr(e,Xn(t,1))},jn.memoize=Ca,jn.merge=ks,jn.mergeWith=Cs,jn.method=Ks,jn.methodOf=Zs,jn.mixin=Xs,jn.negate=Oa,jn.nthArg=function(e){return e=os(e),Fr((function(t){return Ar(t,e)}))},jn.omit=Os,jn.omitBy=function(e,t){return Ss(e,Oa(Qo(t)))},jn.once=function(e){return ya(2,e)},jn.orderBy=function(e,t,n,r){return null==e?[]:(Ra(t)||(t=null==t?[]:[t]),Ra(n=r?void 0:n)||(n=null==n?[]:[n]),Pr(e,t,n))},jn.over=Js,jn.overArgs=Ea,jn.overEvery=eu,jn.overSome=tu,jn.partial=Sa,jn.partialRight=Ta,jn.partition=ha,jn.pick=Es,jn.pickBy=Ss,jn.property=nu,jn.propertyOf=function(e){return function(t){return null==e?void 0:dr(e,t)}},jn.pull=Hi,jn.pullAll=Ui,jn.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?Dr(e,t,Qo(n,2)):e},jn.pullAllWith=function(e,t,n){return e&&e.length&&t&&t.length?Dr(e,t,void 0,n):e},jn.pullAt=Wi,jn.range=ru,jn.rangeRight=ou,jn.rearg=ja,jn.reject=function(e,t){return(Ra(e)?ut:ir)(e,Oa(Qo(t,3)))},jn.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,o=[],i=e.length;for(t=Qo(t,3);++r<i;){var a=e[r];t(a,r,e)&&(n.push(a),o.push(r))}return Ir(e,o),n},jn.rest=function(e,t){if("function"!=typeof e)throw new me(r);return Fr(e,t=void 0===t?t:os(t))},jn.reverse=Vi,jn.sampleSize=function(e,t,n){return t=(n?li(e,t,n):void 0===t)?1:os(t),(Ra(e)?Hn:Hr)(e,t)},jn.set=function(e,t,n){return null==e?e:Ur(e,t,n)},jn.setWith=function(e,t,n,r){return r="function"==typeof r?r:void 0,null==e?e:Ur(e,t,n,r)},jn.shuffle=function(e){return(Ra(e)?Un:qr)(e)},jn.slice=function(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&li(e,t,n)?(t=0,n=r):(t=null==t?0:os(t),n=void 0===n?r:os(n)),Yr(e,t,n)):[]},jn.sortBy=va,jn.sortedUniq=function(e){return e&&e.length?Zr(e):[]},jn.sortedUniqBy=function(e,t){return e&&e.length?Zr(e,Qo(t,2)):[]},jn.split=function(e,t,n){return n&&"number"!=typeof n&&li(e,t,n)&&(t=n=void 0),(n=void 0===n?4294967295:n>>>0)?(e=us(e))&&("string"==typeof t||null!=t&&!Ka(t))&&!(t=Qr(t))&&zt(e)?co(qt(e),0,n):e.split(t,n):[]},jn.spread=function(e,t){if("function"!=typeof e)throw new me(r);return t=null==t?0:sn(os(t),0),Fr((function(n){var r=n[t],o=co(n,0,t);return r&&dt(o,r),rt(e,this,o)}))},jn.tail=function(e){var t=null==e?0:e.length;return t?Yr(e,1,t):[]},jn.take=function(e,t,n){return e&&e.length?Yr(e,0,(t=n||void 0===t?1:os(t))<0?0:t):[]},jn.takeRight=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,(t=r-(t=n||void 0===t?1:os(t)))<0?0:t,r):[]},jn.takeRightWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!1,!0):[]},jn.takeWhile=function(e,t){return e&&e.length?no(e,Qo(t,3)):[]},jn.tap=function(e,t){return t(e),e},jn.throttle=function(e,t,n){var o=!0,i=!0;if("function"!=typeof e)throw new me(r);return Va(n)&&(o="leading"in n?!!n.leading:o,i="trailing"in n?!!n.trailing:i),_a(e,t,{leading:o,maxWait:t,trailing:i})},jn.thru=ra,jn.toArray=ns,jn.toPairs=Ts,jn.toPairsIn=js,jn.toPath=function(e){return Ra(e)?ft(e,Si):Qa(e)?[e]:bo(Ei(us(e)))},jn.toPlainObject=ss,jn.transform=function(e,t,n){var r=Ra(e),o=r||za(e)||Ja(e);if(t=Qo(t,4),null==n){var i=e&&e.constructor;n=o?r?new i:[]:Va(e)&&Ha(i)?Mn(Ve(e)):{}}return(o?it:lr)(e,(function(e,r,o){return t(n,e,r,o)})),n},jn.unary=function(e){return ma(e,1)},jn.union=qi,jn.unionBy=Yi,jn.unionWith=Gi,jn.uniq=function(e){return e&&e.length?Jr(e):[]},jn.uniqBy=function(e,t){return e&&e.length?Jr(e,Qo(t,2)):[]},jn.uniqWith=function(e,t){return t="function"==typeof t?t:void 0,e&&e.length?Jr(e,void 0,t):[]},jn.unset=function(e,t){return null==e||eo(e,t)},jn.unzip=$i,jn.unzipWith=Ki,jn.update=function(e,t,n){return null==e?e:to(e,t,so(n))},jn.updateWith=function(e,t,n,r){return r="function"==typeof r?r:void 0,null==e?e:to(e,t,so(n),r)},jn.values=Ms,jn.valuesIn=function(e){return null==e?[]:Mt(e,xs(e))},jn.without=Zi,jn.words=Hs,jn.wrap=function(e,t){return Sa(so(t),e)},jn.xor=Xi,jn.xorBy=Qi,jn.xorWith=Ji,jn.zip=ea,jn.zipObject=function(e,t){return io(e||[],t||[],Vn)},jn.zipObjectDeep=function(e,t){return io(e||[],t||[],Ur)},jn.zipWith=ta,jn.entries=Ts,jn.entriesIn=js,jn.extend=cs,jn.extendWith=fs,Xs(jn,jn),jn.add=su,jn.attempt=Us,jn.camelCase=Ls,jn.capitalize=As,jn.ceil=uu,jn.clamp=function(e,t,n){return void 0===n&&(n=t,t=void 0),void 0!==n&&(n=(n=as(n))==n?n:0),void 0!==t&&(t=(t=as(t))==t?t:0),Zn(as(e),t,n)},jn.clone=function(e){return Xn(e,4)},jn.cloneDeep=function(e){return Xn(e,5)},jn.cloneDeepWith=function(e,t){return Xn(e,5,t="function"==typeof t?t:void 0)},jn.cloneWith=function(e,t){return Xn(e,4,t="function"==typeof t?t:void 0)},jn.conformsTo=function(e,t){return null==t||Qn(e,t,_s(t))},jn.deburr=Ps,jn.defaultTo=function(e,t){return null==e||e!=e?t:e},jn.divide=lu,jn.endsWith=function(e,t,n){e=us(e),t=Qr(t);var r=e.length,o=n=void 0===n?r:Zn(os(n),0,r);return(n-=t.length)>=0&&e.slice(n,o)==t},jn.eq=Ma,jn.escape=function(e){return(e=us(e))&&N.test(e)?e.replace(D,It):e},jn.escapeRegExp=function(e){return(e=us(e))&&q.test(e)?e.replace(V,"\\$&"):e},jn.every=function(e,t,n){var r=Ra(e)?st:rr;return n&&li(e,t,n)&&(t=void 0),r(e,Qo(t,3))},jn.find=aa,jn.findIndex=Pi,jn.findKey=function(e,t){return mt(e,Qo(t,3),lr)},jn.findLast=sa,jn.findLastIndex=Ri,jn.findLastKey=function(e,t){return mt(e,Qo(t,3),cr)},jn.floor=cu,jn.forEach=ua,jn.forEachRight=la,jn.forIn=function(e,t){return null==e?e:sr(e,Qo(t,3),xs)},jn.forInRight=function(e,t){return null==e?e:ur(e,Qo(t,3),xs)},jn.forOwn=function(e,t){return e&&lr(e,Qo(t,3))},jn.forOwnRight=function(e,t){return e&&cr(e,Qo(t,3))},jn.get=gs,jn.gt=La,jn.gte=Aa,jn.has=function(e,t){return null!=e&&ii(e,t,gr)},jn.hasIn=ms,jn.head=Ii,jn.identity=Gs,jn.includes=function(e,t,n,r){e=Ia(e)?e:Ms(e),n=n&&!r?os(n):0;var o=e.length;return n<0&&(n=sn(o+n,0)),Xa(e)?n<=o&&e.indexOf(t,n)>-1:!!o&&bt(e,t,n)>-1},jn.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:os(n);return o<0&&(o=sn(r+o,0)),bt(e,t,o)},jn.inRange=function(e,t,n){return t=rs(t),void 0===n?(n=t,t=0):n=rs(n),function(e,t,n){return e>=un(t,n)&&e<sn(t,n)}(e=as(e),t,n)},jn.invoke=ws,jn.isArguments=Pa,jn.isArray=Ra,jn.isArrayBuffer=Da,jn.isArrayLike=Ia,jn.isArrayLikeObject=Na,jn.isBoolean=function(e){return!0===e||!1===e||qa(e)&&hr(e)==u},jn.isBuffer=za,jn.isDate=Fa,jn.isElement=function(e){return qa(e)&&1===e.nodeType&&!$a(e)},jn.isEmpty=function(e){if(null==e)return!0;if(Ia(e)&&(Ra(e)||"string"==typeof e||"function"==typeof e.splice||za(e)||Ja(e)||Pa(e)))return!e.length;var t=oi(e);if(t==p||t==m)return!e.size;if(pi(e))return!Or(e).length;for(var n in e)if(ke.call(e,n))return!1;return!0},jn.isEqual=function(e,t){return _r(e,t)},jn.isEqualWith=function(e,t,n){var r=(n="function"==typeof n?n:void 0)?n(e,t):void 0;return void 0===r?_r(e,t,void 0,n):!!r},jn.isError=Ba,jn.isFinite=function(e){return"number"==typeof e&&rn(e)},jn.isFunction=Ha,jn.isInteger=Ua,jn.isLength=Wa,jn.isMap=Ya,jn.isMatch=function(e,t){return e===t||xr(e,t,ei(t))},jn.isMatchWith=function(e,t,n){return n="function"==typeof n?n:void 0,xr(e,t,ei(t),n)},jn.isNaN=function(e){return Ga(e)&&e!=+e},jn.isNative=function(e){if(di(e))throw new fe("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return kr(e)},jn.isNil=function(e){return null==e},jn.isNull=function(e){return null===e},jn.isNumber=Ga,jn.isObject=Va,jn.isObjectLike=qa,jn.isPlainObject=$a,jn.isRegExp=Ka,jn.isSafeInteger=function(e){return Ua(e)&&e>=-9007199254740991&&e<=9007199254740991},jn.isSet=Za,jn.isString=Xa,jn.isSymbol=Qa,jn.isTypedArray=Ja,jn.isUndefined=function(e){return void 0===e},jn.isWeakMap=function(e){return qa(e)&&oi(e)==w},jn.isWeakSet=function(e){return qa(e)&&"[object WeakSet]"==hr(e)},jn.join=function(e,t){return null==e?"":on.call(e,t)},jn.kebabCase=Rs,jn.last=Bi,jn.lastIndexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r;return void 0!==n&&(o=(o=os(n))<0?sn(r+o,0):un(o,r-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):yt(e,_t,o,!0)},jn.lowerCase=Ds,jn.lowerFirst=Is,jn.lt=es,jn.lte=ts,jn.max=function(e){return e&&e.length?or(e,Gs,vr):void 0},jn.maxBy=function(e,t){return e&&e.length?or(e,Qo(t,2),vr):void 0},jn.mean=function(e){return xt(e,Gs)},jn.meanBy=function(e,t){return xt(e,Qo(t,2))},jn.min=function(e){return e&&e.length?or(e,Gs,Sr):void 0},jn.minBy=function(e,t){return e&&e.length?or(e,Qo(t,2),Sr):void 0},jn.stubArray=iu,jn.stubFalse=au,jn.stubObject=function(){return{}},jn.stubString=function(){return""},jn.stubTrue=function(){return!0},jn.multiply=du,jn.nth=function(e,t){return e&&e.length?Ar(e,os(t)):void 0},jn.noConflict=function(){return qe._===this&&(qe._=Te),this},jn.noop=Qs,jn.now=ga,jn.pad=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;if(!t||r>=t)return e;var o=(t-r)/2;return Ro(en(o),n)+e+Ro(Jt(o),n)},jn.padEnd=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;return t&&r<t?e+Ro(t-r,n):e},jn.padStart=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;return t&&r<t?Ro(t-r,n)+e:e},jn.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),cn(us(e).replace(Y,""),t||0)},jn.random=function(e,t,n){if(n&&"boolean"!=typeof n&&li(e,t,n)&&(t=n=void 0),void 0===n&&("boolean"==typeof t?(n=t,t=void 0):"boolean"==typeof e&&(n=e,e=void 0)),void 0===e&&void 0===t?(e=0,t=1):(e=rs(e),void 0===t?(t=e,e=0):t=rs(t)),e>t){var r=e;e=t,t=r}if(n||e%1||t%1){var o=fn();return un(e+o*(t-e+He("1e-"+((o+"").length-1))),t)}return Nr(e,t)},jn.reduce=function(e,t,n){var r=Ra(e)?pt:Ot,o=arguments.length<3;return r(e,Qo(t,4),n,o,tr)},jn.reduceRight=function(e,t,n){var r=Ra(e)?ht:Ot,o=arguments.length<3;return r(e,Qo(t,4),n,o,nr)},jn.repeat=function(e,t,n){return t=(n?li(e,t,n):void 0===t)?1:os(t),zr(us(e),t)},jn.replace=function(){var e=arguments,t=us(e[0]);return e.length<3?t:t.replace(e[1],e[2])},jn.result=function(e,t,n){var r=-1,o=(t=uo(t,e)).length;for(o||(o=1,e=void 0);++r<o;){var i=null==e?void 0:e[Si(t[r])];void 0===i&&(r=o,i=n),e=Ha(i)?i.call(e):i}return e},jn.round=pu,jn.runInContext=e,jn.sample=function(e){return(Ra(e)?Bn:Br)(e)},jn.size=function(e){if(null==e)return 0;if(Ia(e))return Xa(e)?Vt(e):e.length;var t=oi(e);return t==p||t==m?e.size:Or(e).length},jn.snakeCase=Ns,jn.some=function(e,t,n){var r=Ra(e)?vt:Gr;return n&&li(e,t,n)&&(t=void 0),r(e,Qo(t,3))},jn.sortedIndex=function(e,t){return $r(e,t)},jn.sortedIndexBy=function(e,t,n){return Kr(e,t,Qo(n,2))},jn.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=$r(e,t);if(r<n&&Ma(e[r],t))return r}return-1},jn.sortedLastIndex=function(e,t){return $r(e,t,!0)},jn.sortedLastIndexBy=function(e,t,n){return Kr(e,t,Qo(n,2),!0)},jn.sortedLastIndexOf=function(e,t){if(null==e?0:e.length){var n=$r(e,t,!0)-1;if(Ma(e[n],t))return n}return-1},jn.startCase=zs,jn.startsWith=function(e,t,n){return e=us(e),n=null==n?0:Zn(os(n),0,e.length),t=Qr(t),e.slice(n,n+t.length)==t},jn.subtract=hu,jn.sum=function(e){return e&&e.length?Et(e,Gs):0},jn.sumBy=function(e,t){return e&&e.length?Et(e,Qo(t,2)):0},jn.template=function(e,t,n){var r=jn.templateSettings;n&&li(e,t,n)&&(t=void 0),e=us(e),t=fs({},t,r,Uo);var o,i,a=fs({},t.imports,r.imports,Uo),s=_s(a),u=Mt(a,s),l=0,c=t.interpolate||ue,f="__p += '",d=ve((t.escape||ue).source+"|"+c.source+"|"+(c===B?ee:ue).source+"|"+(t.evaluate||ue).source+"|$","g"),p="//# sourceURL="+(ke.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Ne+"]")+"\n";e.replace(d,(function(t,n,r,a,s,u){return r||(r=a),f+=e.slice(l,u).replace(le,Nt),n&&(o=!0,f+="' +\n__e("+n+") +\n'"),s&&(i=!0,f+="';\n"+s+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+t.length,t})),f+="';\n";var h=ke.call(t,"variable")&&t.variable;if(h){if(Q.test(h))throw new fe("Invalid `variable` option passed into `_.template`")}else f="with (obj) {\n"+f+"\n}\n";f=(i?f.replace(L,""):f).replace(A,"$1").replace(P,"$1;"),f="function("+(h||"obj")+") {\n"+(h?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(i?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=Us((function(){return de(s,p+"return "+f).apply(void 0,u)}));if(v.source=f,Ba(v))throw v;return v},jn.times=function(e,t){if((e=os(e))<1||e>9007199254740991)return[];var n=4294967295,r=un(e,4294967295);e-=4294967295;for(var o=St(r,t=Qo(t));++n<e;)t(n);return o},jn.toFinite=rs,jn.toInteger=os,jn.toLength=is,jn.toLower=function(e){return us(e).toLowerCase()},jn.toNumber=as,jn.toSafeInteger=function(e){return e?Zn(os(e),-9007199254740991,9007199254740991):0===e?e:0},jn.toString=us,jn.toUpper=function(e){return us(e).toUpperCase()},jn.trim=function(e,t,n){if((e=us(e))&&(n||void 0===t))return Tt(e);if(!e||!(t=Qr(t)))return e;var r=qt(e),o=qt(t);return co(r,At(r,o),Pt(r,o)+1).join("")},jn.trimEnd=function(e,t,n){if((e=us(e))&&(n||void 0===t))return e.slice(0,Yt(e)+1);if(!e||!(t=Qr(t)))return e;var r=qt(e);return co(r,0,Pt(r,qt(t))+1).join("")},jn.trimStart=function(e,t,n){if((e=us(e))&&(n||void 0===t))return e.replace(Y,"");if(!e||!(t=Qr(t)))return e;var r=qt(e);return co(r,At(r,qt(t))).join("")},jn.truncate=function(e,t){var n=30,r="...";if(Va(t)){var o="separator"in t?t.separator:o;n="length"in t?os(t.length):n,r="omission"in t?Qr(t.omission):r}var i=(e=us(e)).length;if(zt(e)){var a=qt(e);i=a.length}if(n>=i)return e;var s=n-Vt(r);if(s<1)return r;var u=a?co(a,0,s).join(""):e.slice(0,s);if(void 0===o)return u+r;if(a&&(s+=u.length-s),Ka(o)){if(e.slice(s).search(o)){var l,c=u;for(o.global||(o=ve(o.source,us(te.exec(o))+"g")),o.lastIndex=0;l=o.exec(c);)var f=l.index;u=u.slice(0,void 0===f?s:f)}}else if(e.indexOf(Qr(o),s)!=s){var d=u.lastIndexOf(o);d>-1&&(u=u.slice(0,d))}return u+r},jn.unescape=function(e){return(e=us(e))&&I.test(e)?e.replace(R,Gt):e},jn.uniqueId=function(e){var t=++Ce;return us(e)+t},jn.upperCase=Fs,jn.upperFirst=Bs,jn.each=ua,jn.eachRight=la,jn.first=Ii,Xs(jn,(fu={},lr(jn,(function(e,t){ke.call(jn.prototype,t)||(fu[t]=e)})),fu),{chain:!1}),jn.VERSION="4.17.21",it(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){jn[e].placeholder=jn})),it(["drop","take"],(function(e,t){Pn.prototype[e]=function(n){n=void 0===n?1:sn(os(n),0);var r=this.__filtered__&&!t?new Pn(this):this.clone();return r.__filtered__?r.__takeCount__=un(n,r.__takeCount__):r.__views__.push({size:un(n,4294967295),type:e+(r.__dir__<0?"Right":"")}),r},Pn.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),it(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=1==n||3==n;Pn.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:Qo(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),it(["head","last"],(function(e,t){var n="take"+(t?"Right":"");Pn.prototype[e]=function(){return this[n](1).value()[0]}})),it(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");Pn.prototype[e]=function(){return this.__filtered__?new Pn(this):this[n](1)}})),Pn.prototype.compact=function(){return this.filter(Gs)},Pn.prototype.find=function(e){return this.filter(e).head()},Pn.prototype.findLast=function(e){return this.reverse().find(e)},Pn.prototype.invokeMap=Fr((function(e,t){return"function"==typeof e?new Pn(this):this.map((function(n){return br(n,e,t)}))})),Pn.prototype.reject=function(e){return this.filter(Oa(Qo(e)))},Pn.prototype.slice=function(e,t){e=os(e);var n=this;return n.__filtered__&&(e>0||t<0)?new Pn(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),void 0!==t&&(n=(t=os(t))<0?n.dropRight(-t):n.take(t-e)),n)},Pn.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Pn.prototype.toArray=function(){return this.take(4294967295)},lr(Pn.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),r=/^(?:head|last)$/.test(t),o=jn[r?"take"+("last"==t?"Right":""):t],i=r||/^find/.test(t);o&&(jn.prototype[t]=function(){var t=this.__wrapped__,a=r?[1]:arguments,s=t instanceof Pn,u=a[0],l=s||Ra(t),c=function(e){var t=o.apply(jn,dt([e],a));return r&&f?t[0]:t};l&&n&&"function"==typeof u&&1!=u.length&&(s=l=!1);var f=this.__chain__,d=!!this.__actions__.length,p=i&&!f,h=s&&!d;if(!i&&l){t=h?t:new Pn(this);var v=e.apply(t,a);return v.__actions__.push({func:ra,args:[c],thisArg:void 0}),new An(v,f)}return p&&h?e.apply(this,a):(v=this.thru(c),p?r?v.value()[0]:v.value():v)})})),it(["pop","push","shift","sort","splice","unshift"],(function(e){var t=ye[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);jn.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var o=this.value();return t.apply(Ra(o)?o:[],e)}return this[n]((function(n){return t.apply(Ra(n)?n:[],e)}))}})),lr(Pn.prototype,(function(e,t){var n=jn[t];if(n){var r=n.name+"";ke.call(wn,r)||(wn[r]=[]),wn[r].push({name:t,func:n})}})),wn[Mo(void 0,2).name]=[{name:"wrapper",func:void 0}],Pn.prototype.clone=function(){var e=new Pn(this.__wrapped__);return e.__actions__=bo(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=bo(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=bo(this.__views__),e},Pn.prototype.reverse=function(){if(this.__filtered__){var e=new Pn(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},Pn.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=Ra(e),r=t<0,o=n?e.length:0,i=function(e,t,n){var r=-1,o=n.length;for(;++r<o;){var i=n[r],a=i.size;switch(i.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=un(t,e+a);break;case"takeRight":e=sn(e,t-a)}}return{start:e,end:t}}(0,o,this.__views__),a=i.start,s=i.end,u=s-a,l=r?s:a-1,c=this.__iteratees__,f=c.length,d=0,p=un(u,this.__takeCount__);if(!n||!r&&o==u&&p==u)return ro(e,this.__actions__);var h=[];e:for(;u--&&d<p;){for(var v=-1,g=e[l+=t];++v<f;){var m=c[v],y=m.iteratee,b=m.type,w=y(g);if(2==b)g=w;else if(!w){if(1==b)continue e;break e}}h[d++]=g}return h},jn.prototype.at=oa,jn.prototype.chain=function(){return na(this)},jn.prototype.commit=function(){return new An(this.value(),this.__chain__)},jn.prototype.next=function(){void 0===this.__values__&&(this.__values__=ns(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?void 0:this.__values__[this.__index__++]}},jn.prototype.plant=function(e){for(var t,n=this;n instanceof Ln;){var r=ji(n);r.__index__=0,r.__values__=void 0,t?o.__wrapped__=r:t=r;var o=r;n=n.__wrapped__}return o.__wrapped__=e,t},jn.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof Pn){var t=e;return this.__actions__.length&&(t=new Pn(this)),(t=t.reverse()).__actions__.push({func:ra,args:[Vi],thisArg:void 0}),new An(t,this.__chain__)}return this.thru(Vi)},jn.prototype.toJSON=jn.prototype.valueOf=jn.prototype.value=function(){return ro(this.__wrapped__,this.__actions__)},jn.prototype.first=jn.prototype.head,gt&&(jn.prototype[gt]=function(){return this}),jn}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(qe._=$t,define((function(){return $t}))):Ge?((Ge.exports=$t)._=$t,Ye._=$t):qe._=$t}).call(this)}).call(this,n(31),n(57)(e))},function(e,t,n){"use strict";n.d(t,"l",(function(){return s})),n.d(t,"c",(function(){return u})),n.d(t,"v",(function(){return l})),n.d(t,"s",(function(){return c})),n.d(t,"w",(function(){return f})),n.d(t,"h",(function(){return d})),n.d(t,"y",(function(){return p})),n.d(t,"u",(function(){return h})),n.d(t,"f",(function(){return v})),n.d(t,"k",(function(){return g})),n.d(t,"n",(function(){return m})),n.d(t,"g",(function(){return b})),n.d(t,"r",(function(){return w})),n.d(t,"i",(function(){return _})),n.d(t,"e",(function(){return x})),n.d(t,"x",(function(){return k})),n.d(t,"d",(function(){return C})),n.d(t,"b",(function(){return O})),n.d(t,"q",(function(){return E})),n.d(t,"m",(function(){return S})),n.d(t,"j",(function(){return T})),n.d(t,"a",(function(){return M})),n.d(t,"o",(function(){return L})),n.d(t,"t",(function(){return A})),n.d(t,"p",(function(){return P}));var r=n(43),o=n(20),i=n(12),a="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};function s(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=Object.keys(e),r=Object.keys(t),o=[],i=0;i<n.length;i++)e[n[i]]!==t[n[i]]&&o.push({path:[n[i]]});for(var a=0;a<r.length;a++)e[r[a]]!==t[r[a]]&&o.push({path:[r[a]]});return o}function u(e){return"string"==typeof e?e.replace(/\.\*\*|\.\*/,""):e}function l(e){return"object"===(void 0===e?"undefined":a(e))&&null!==e&&!Array.isArray(e)}function c(e){return"object"===(void 0===e?"undefined":a(e))&&null!==e}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=t.reduce((function(t,n){return!!(t||e instanceof n)||t}),!1);return!(void 0===e||!(n||l(e)&&"[object Object]"===Object.prototype.toString.call(e)&&(e.constructor===Object||null===Object.getPrototypeOf(e))||"number"==typeof e||"string"==typeof e||"boolean"==typeof e||null===e||Array.isArray(e)))}function d(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return Array.isArray(e)?e:"string"==typeof e?e.split("."):[]}function p(e){throw new Error("Cerebral - "+e)}function h(){return!1}function v(e,t,n){var r=void 0;return function(){var o=this,i=arguments,a=function(){r=null,n||e.apply(o,i)},s=n&&!r;clearTimeout(r),r=setTimeout(a,t),s&&e.apply(o,i)}}function g(e){if(e&&!f(e)){var t=e.constructor.name;try{Object.defineProperty(e,"toJSON",{value:function(){return"["+t+"]"}})}catch(e){}}return e}function m(e){return Object.assign(Object.keys(e.providers||{}).reduce((function(t,n){return t[n]=e.providers[n]instanceof i.b?e.providers[n]:new i.b(e.providers[n]),t}),{}),Object.keys(e.modules||{}).reduce((function(t,n){return Object.assign(t,m(e.modules[n]))}),{}))}function y(e){return Object.keys(e).reduce((function(t,n){return e[n].children?t.concat(e[n]).concat(y(e[n].children)):t.concat(e[n])}),[])}function b(e,t){for(var n=[],r=0;r<e.length;r++)for(var o=t,i=0;i<e[r].path.length&&o;i++){if(o["**"]&&n.push(o["**"]),i===e[r].path.length-1){var a=o[e[r].path[i]];a&&(n.push(a),a.children&&(e[r].forceChildPathUpdates?n=n.concat(y(a.children)):(a.children["**"]&&n.push(a.children["**"]),a.children["*"]&&n.push(a.children["*"])))),o["*"]&&n.push(o["*"])}if(!o[e[r].path[i]]){o=null;break}o=o[e[r].path[i]].children}return n}function w(e){return function(t){return t.split(".").reduce((function(e,n,r){return r>0&&void 0===e&&p('You are extracting with path "'+t+'", but it is not valid for this object'),e[n]}),e)}}function _(e,t){return c(t)&&-1===e.indexOf("*")?e+".**":e}function x(e){return{isTag:function(e){if(!(e instanceof r.Tag))return!1;for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return!n.length||n.reduce((function(t,n){return t||n===e.type}),!1)},isCompute:function(e){return A(e)},value:function(t,n){return t instanceof r.Tag||A(t)?t.getValue(n?Object.assign({},e,{props:n}):e):t},path:function(t){if(t instanceof r.Tag)return t.getPath(e);p("You are extracting a path from an argument that is not a Tag")}}}var k=function(){};function C(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=function(t){return d(t).reduce((function(e,t){return e?e[t]:void 0}),e)};return{options:{},on:function(){},getState:n,model:{get:n},getSequence:function(e){return t[e]||function(){}},dependencyStore:{addEntity:k,removeEntity:k}}}function O(e){if(c(e)&&!(e instanceof o.a)){for(var t in e)O(e[t]);!e.__CerebralState&&Object.defineProperty(e,"__CerebralState",{value:!0})}return e}function E(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce((function(t,n){return!t&&c(e[n])&&"__CerebralState"in e[n]?n:t}),null)}function S(e,t){var n=Array.isArray(e)?e:d(e);return n.reduce((function(t,r){return t.modules[r]||p('The path "'+n.join(".")+'" is invalid, can not find module. Does the path "'+n.splice(0,e.length-1).join(".")+'" exist?'),t.modules[r]}),t)}function T(e,t,n){var r=Object.keys(e.modules||{}).reduce((function(r,o){return r[o]=T(e.modules[o],t,n),r}),{});if(e[t]){var o=Object.keys(e[t]).reduce((function(n,r){var o=Object.getOwnPropertyDescriptor(e[t],r);return o&&"get"in o?Object.defineProperty(n,r,o):n[r]=e[t][r],n}),r);return n?n(o,e):o}return r}var j=[];function M(e,t){-1===j.indexOf(e)&&(j.push(e),console.warn(e+" is DEPRECATED - "+t))}function L(e,t){var n=t.execution.name.split(".");return n.splice(0,n.length-1).concat(e).join(".")}function A(e){return e instanceof o.a||e instanceof o.b}function P(e,t,n){var r=[];return function e(t,n,o){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[];if(A(n)||A(o))return o;if(l(n)&&l(o)){var a=Object.keys(n).concat(Object.keys(o)).reduce((function(e,t){return-1===e.indexOf(t)?e.concat(t):e}),[]),s=!0,u=!1,c=void 0;try{for(var f,d=a[Symbol.iterator]();!(s=(f=d.next()).done);s=!0){var p=f.value;e(t[p],n[p],o[p],i.concat(p))}}catch(e){u=!0,c=e}finally{try{!s&&d.return&&d.return()}finally{if(u)throw c}}}else"function"!=typeof o&&(Array.isArray(n)&&Array.isArray(o)||o===t&&n!==t?r.push({path:i.slice(),value:n}):o!==t&&r.push({path:i.slice(),value:o}))}(e,t,n),r}},function(e,t,n){(function(e,n){(function(){var r="Expected a function",o="__lodash_placeholder__",i=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],a="[object Arguments]",s="[object Array]",u="[object Boolean]",l="[object Date]",c="[object Error]",f="[object Function]",d="[object GeneratorFunction]",p="[object Map]",h="[object Number]",v="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",b="[object Symbol]",w="[object WeakMap]",_="[object ArrayBuffer]",x="[object DataView]",k="[object Float32Array]",C="[object Float64Array]",O="[object Int8Array]",E="[object Int16Array]",S="[object Int32Array]",T="[object Uint8Array]",j="[object Uint16Array]",M="[object Uint32Array]",L=/\b__p \+= '';/g,A=/\b(__p \+=) '' \+/g,P=/(__e\(.*?\)|\b__t\)) \+\n'';/g,R=/&(?:amp|lt|gt|quot|#39);/g,D=/[&<>"']/g,I=RegExp(R.source),N=RegExp(D.source),z=/<%-([\s\S]+?)%>/g,F=/<%([\s\S]+?)%>/g,B=/<%=([\s\S]+?)%>/g,H=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,U=/^\w*$/,W=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,V=/[\\^$.*+?()[\]{}|]/g,q=RegExp(V.source),Y=/^\s+/,G=/\s/,$=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,K=/\{\n\/\* \[wrapped with (.+)\] \*/,Z=/,? & /,X=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Q=/[()=,{}\[\]\/\s]/,J=/\\(\\)?/g,ee=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,te=/\w*$/,ne=/^[-+]0x[0-9a-f]+$/i,re=/^0b[01]+$/i,oe=/^\[object .+?Constructor\]$/,ie=/^0o[0-7]+$/i,ae=/^(?:0|[1-9]\d*)$/,se=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ue=/($^)/,le=/['\n\r\u2028\u2029\\]/g,ce="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",fe="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",de="[\\ud800-\\udfff]",pe="["+fe+"]",he="["+ce+"]",ve="\\d+",ge="[\\u2700-\\u27bf]",me="[a-z\\xdf-\\xf6\\xf8-\\xff]",ye="[^\\ud800-\\udfff"+fe+ve+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",be="\\ud83c[\\udffb-\\udfff]",we="[^\\ud800-\\udfff]",_e="(?:\\ud83c[\\udde6-\\uddff]){2}",xe="[\\ud800-\\udbff][\\udc00-\\udfff]",ke="[A-Z\\xc0-\\xd6\\xd8-\\xde]",Ce="(?:"+me+"|"+ye+")",Oe="(?:"+ke+"|"+ye+")",Ee="(?:"+he+"|"+be+")"+"?",Se="[\\ufe0e\\ufe0f]?"+Ee+("(?:\\u200d(?:"+[we,_e,xe].join("|")+")[\\ufe0e\\ufe0f]?"+Ee+")*"),Te="(?:"+[ge,_e,xe].join("|")+")"+Se,je="(?:"+[we+he+"?",he,_e,xe,de].join("|")+")",Me=RegExp("['\u2019]","g"),Le=RegExp(he,"g"),Ae=RegExp(be+"(?="+be+")|"+je+Se,"g"),Pe=RegExp([ke+"?"+me+"+(?:['\u2019](?:d|ll|m|re|s|t|ve))?(?="+[pe,ke,"$"].join("|")+")",Oe+"+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?(?="+[pe,ke+Ce,"$"].join("|")+")",ke+"?"+Ce+"+(?:['\u2019](?:d|ll|m|re|s|t|ve))?",ke+"+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ve,Te].join("|"),"g"),Re=RegExp("[\\u200d\\ud800-\\udfff"+ce+"\\ufe0e\\ufe0f]"),De=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ie=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Ne=-1,ze={};ze[k]=ze[C]=ze[O]=ze[E]=ze[S]=ze[T]=ze["[object Uint8ClampedArray]"]=ze[j]=ze[M]=!0,ze[a]=ze[s]=ze[_]=ze[u]=ze[x]=ze[l]=ze[c]=ze[f]=ze[p]=ze[h]=ze[v]=ze[g]=ze[m]=ze[y]=ze[w]=!1;var Fe={};Fe[a]=Fe[s]=Fe[_]=Fe[x]=Fe[u]=Fe[l]=Fe[k]=Fe[C]=Fe[O]=Fe[E]=Fe[S]=Fe[p]=Fe[h]=Fe[v]=Fe[g]=Fe[m]=Fe[y]=Fe[b]=Fe[T]=Fe["[object Uint8ClampedArray]"]=Fe[j]=Fe[M]=!0,Fe[c]=Fe[f]=Fe[w]=!1;var Be={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},He=parseFloat,Ue=parseInt,We="object"==typeof e&&e&&e.Object===Object&&e,Ve="object"==typeof self&&self&&self.Object===Object&&self,qe=We||Ve||Function("return this")(),Ye=t&&!t.nodeType&&t,Ge=Ye&&"object"==typeof n&&n&&!n.nodeType&&n,$e=Ge&&Ge.exports===Ye,Ke=$e&&We.process,Ze=function(){try{var e=Ge&&Ge.require&&Ge.require("util").types;return e||Ke&&Ke.binding&&Ke.binding("util")}catch(e){}}(),Xe=Ze&&Ze.isArrayBuffer,Qe=Ze&&Ze.isDate,Je=Ze&&Ze.isMap,et=Ze&&Ze.isRegExp,tt=Ze&&Ze.isSet,nt=Ze&&Ze.isTypedArray;function rt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function ot(e,t,n,r){for(var o=-1,i=null==e?0:e.length;++o<i;){var a=e[o];t(r,a,n(a),e)}return r}function it(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function at(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function st(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function ut(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}function lt(e,t){return!!(null==e?0:e.length)&&bt(e,t,0)>-1}function ct(e,t,n){for(var r=-1,o=null==e?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}function ft(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}function dt(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}function pt(e,t,n,r){var o=-1,i=null==e?0:e.length;for(r&&i&&(n=e[++o]);++o<i;)n=t(n,e[o],o,e);return n}function ht(e,t,n,r){var o=null==e?0:e.length;for(r&&o&&(n=e[--o]);o--;)n=t(n,e[o],o,e);return n}function vt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var gt=kt("length");function mt(e,t,n){var r;return n(e,(function(e,n,o){if(t(e,n,o))return r=n,!1})),r}function yt(e,t,n,r){for(var o=e.length,i=n+(r?1:-1);r?i--:++i<o;)if(t(e[i],i,e))return i;return-1}function bt(e,t,n){return t==t?function(e,t,n){var r=n-1,o=e.length;for(;++r<o;)if(e[r]===t)return r;return-1}(e,t,n):yt(e,_t,n)}function wt(e,t,n,r){for(var o=n-1,i=e.length;++o<i;)if(r(e[o],t))return o;return-1}function _t(e){return e!=e}function xt(e,t){var n=null==e?0:e.length;return n?Et(e,t)/n:NaN}function kt(e){return function(t){return null==t?void 0:t[e]}}function Ct(e){return function(t){return null==e?void 0:e[t]}}function Ot(e,t,n,r,o){return o(e,(function(e,o,i){n=r?(r=!1,e):t(n,e,o,i)})),n}function Et(e,t){for(var n,r=-1,o=e.length;++r<o;){var i=t(e[r]);void 0!==i&&(n=void 0===n?i:n+i)}return n}function St(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Tt(e){return e?e.slice(0,Yt(e)+1).replace(Y,""):e}function jt(e){return function(t){return e(t)}}function Mt(e,t){return ft(t,(function(t){return e[t]}))}function Lt(e,t){return e.has(t)}function At(e,t){for(var n=-1,r=e.length;++n<r&&bt(t,e[n],0)>-1;);return n}function Pt(e,t){for(var n=e.length;n--&&bt(t,e[n],0)>-1;);return n}function Rt(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}var Dt=Ct({"\xc0":"A","\xc1":"A","\xc2":"A","\xc3":"A","\xc4":"A","\xc5":"A","\xe0":"a","\xe1":"a","\xe2":"a","\xe3":"a","\xe4":"a","\xe5":"a","\xc7":"C","\xe7":"c","\xd0":"D","\xf0":"d","\xc8":"E","\xc9":"E","\xca":"E","\xcb":"E","\xe8":"e","\xe9":"e","\xea":"e","\xeb":"e","\xcc":"I","\xcd":"I","\xce":"I","\xcf":"I","\xec":"i","\xed":"i","\xee":"i","\xef":"i","\xd1":"N","\xf1":"n","\xd2":"O","\xd3":"O","\xd4":"O","\xd5":"O","\xd6":"O","\xd8":"O","\xf2":"o","\xf3":"o","\xf4":"o","\xf5":"o","\xf6":"o","\xf8":"o","\xd9":"U","\xda":"U","\xdb":"U","\xdc":"U","\xf9":"u","\xfa":"u","\xfb":"u","\xfc":"u","\xdd":"Y","\xfd":"y","\xff":"y","\xc6":"Ae","\xe6":"ae","\xde":"Th","\xfe":"th","\xdf":"ss","\u0100":"A","\u0102":"A","\u0104":"A","\u0101":"a","\u0103":"a","\u0105":"a","\u0106":"C","\u0108":"C","\u010a":"C","\u010c":"C","\u0107":"c","\u0109":"c","\u010b":"c","\u010d":"c","\u010e":"D","\u0110":"D","\u010f":"d","\u0111":"d","\u0112":"E","\u0114":"E","\u0116":"E","\u0118":"E","\u011a":"E","\u0113":"e","\u0115":"e","\u0117":"e","\u0119":"e","\u011b":"e","\u011c":"G","\u011e":"G","\u0120":"G","\u0122":"G","\u011d":"g","\u011f":"g","\u0121":"g","\u0123":"g","\u0124":"H","\u0126":"H","\u0125":"h","\u0127":"h","\u0128":"I","\u012a":"I","\u012c":"I","\u012e":"I","\u0130":"I","\u0129":"i","\u012b":"i","\u012d":"i","\u012f":"i","\u0131":"i","\u0134":"J","\u0135":"j","\u0136":"K","\u0137":"k","\u0138":"k","\u0139":"L","\u013b":"L","\u013d":"L","\u013f":"L","\u0141":"L","\u013a":"l","\u013c":"l","\u013e":"l","\u0140":"l","\u0142":"l","\u0143":"N","\u0145":"N","\u0147":"N","\u014a":"N","\u0144":"n","\u0146":"n","\u0148":"n","\u014b":"n","\u014c":"O","\u014e":"O","\u0150":"O","\u014d":"o","\u014f":"o","\u0151":"o","\u0154":"R","\u0156":"R","\u0158":"R","\u0155":"r","\u0157":"r","\u0159":"r","\u015a":"S","\u015c":"S","\u015e":"S","\u0160":"S","\u015b":"s","\u015d":"s","\u015f":"s","\u0161":"s","\u0162":"T","\u0164":"T","\u0166":"T","\u0163":"t","\u0165":"t","\u0167":"t","\u0168":"U","\u016a":"U","\u016c":"U","\u016e":"U","\u0170":"U","\u0172":"U","\u0169":"u","\u016b":"u","\u016d":"u","\u016f":"u","\u0171":"u","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017b":"Z","\u017d":"Z","\u017a":"z","\u017c":"z","\u017e":"z","\u0132":"IJ","\u0133":"ij","\u0152":"Oe","\u0153":"oe","\u0149":"'n","\u017f":"s"}),It=Ct({"&":"&","<":"<",">":">",'"':""","'":"'"});function Nt(e){return"\\"+Be[e]}function zt(e){return Re.test(e)}function Ft(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function Bt(e,t){return function(n){return e(t(n))}}function Ht(e,t){for(var n=-1,r=e.length,i=0,a=[];++n<r;){var s=e[n];s!==t&&s!==o||(e[n]=o,a[i++]=n)}return a}function Ut(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function Wt(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}function Vt(e){return zt(e)?function(e){var t=Ae.lastIndex=0;for(;Ae.test(e);)++t;return t}(e):gt(e)}function qt(e){return zt(e)?function(e){return e.match(Ae)||[]}(e):function(e){return e.split("")}(e)}function Yt(e){for(var t=e.length;t--&&G.test(e.charAt(t)););return t}var Gt=Ct({"&":"&","<":"<",">":">",""":'"',"'":"'"});var $t=function e(t){var n,G=(t=null==t?qe:$t.defaults(qe.Object(),t,$t.pick(qe,Ie))).Array,ce=t.Date,fe=t.Error,de=t.Function,pe=t.Math,he=t.Object,ve=t.RegExp,ge=t.String,me=t.TypeError,ye=G.prototype,be=de.prototype,we=he.prototype,_e=t["__core-js_shared__"],xe=be.toString,ke=we.hasOwnProperty,Ce=0,Oe=(n=/[^.]+$/.exec(_e&&_e.keys&&_e.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",Ee=we.toString,Se=xe.call(he),Te=qe._,je=ve("^"+xe.call(ke).replace(V,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ae=$e?t.Buffer:void 0,Re=t.Symbol,Be=t.Uint8Array,We=Ae?Ae.allocUnsafe:void 0,Ve=Bt(he.getPrototypeOf,he),Ye=he.create,Ge=we.propertyIsEnumerable,Ke=ye.splice,Ze=Re?Re.isConcatSpreadable:void 0,gt=Re?Re.iterator:void 0,Ct=Re?Re.toStringTag:void 0,Kt=function(){try{var e=ti(he,"defineProperty");return e({},"",{}),e}catch(e){}}(),Zt=t.clearTimeout!==qe.clearTimeout&&t.clearTimeout,Xt=ce&&ce.now!==qe.Date.now&&ce.now,Qt=t.setTimeout!==qe.setTimeout&&t.setTimeout,Jt=pe.ceil,en=pe.floor,tn=he.getOwnPropertySymbols,nn=Ae?Ae.isBuffer:void 0,rn=t.isFinite,on=ye.join,an=Bt(he.keys,he),sn=pe.max,un=pe.min,ln=ce.now,cn=t.parseInt,fn=pe.random,dn=ye.reverse,pn=ti(t,"DataView"),hn=ti(t,"Map"),vn=ti(t,"Promise"),gn=ti(t,"Set"),mn=ti(t,"WeakMap"),yn=ti(he,"create"),bn=mn&&new mn,wn={},_n=Ti(pn),xn=Ti(hn),kn=Ti(vn),Cn=Ti(gn),On=Ti(mn),En=Re?Re.prototype:void 0,Sn=En?En.valueOf:void 0,Tn=En?En.toString:void 0;function jn(e){if(qa(e)&&!Ra(e)&&!(e instanceof Pn)){if(e instanceof An)return e;if(ke.call(e,"__wrapped__"))return ji(e)}return new An(e)}var Mn=function(){function e(){}return function(t){if(!Va(t))return{};if(Ye)return Ye(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Ln(){}function An(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}function Pn(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function Rn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Dn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function In(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Nn(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new In;++t<n;)this.add(e[t])}function zn(e){var t=this.__data__=new Dn(e);this.size=t.size}function Fn(e,t){var n=Ra(e),r=!n&&Pa(e),o=!n&&!r&&za(e),i=!n&&!r&&!o&&Ja(e),a=n||r||o||i,s=a?St(e.length,ge):[],u=s.length;for(var l in e)!t&&!ke.call(e,l)||a&&("length"==l||o&&("offset"==l||"parent"==l)||i&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||ui(l,u))||s.push(l);return s}function Bn(e){var t=e.length;return t?e[Nr(0,t-1)]:void 0}function Hn(e,t){return Oi(bo(e),Zn(t,0,e.length))}function Un(e){return Oi(bo(e))}function Wn(e,t,n){(void 0!==n&&!Ma(e[t],n)||void 0===n&&!(t in e))&&$n(e,t,n)}function Vn(e,t,n){var r=e[t];ke.call(e,t)&&Ma(r,n)&&(void 0!==n||t in e)||$n(e,t,n)}function qn(e,t){for(var n=e.length;n--;)if(Ma(e[n][0],t))return n;return-1}function Yn(e,t,n,r){return tr(e,(function(e,o,i){t(r,e,n(e),i)})),r}function Gn(e,t){return e&&wo(t,_s(t),e)}function $n(e,t,n){"__proto__"==t&&Kt?Kt(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Kn(e,t){for(var n=-1,r=t.length,o=G(r),i=null==e;++n<r;)o[n]=i?void 0:gs(e,t[n]);return o}function Zn(e,t,n){return e==e&&(void 0!==n&&(e=e<=n?e:n),void 0!==t&&(e=e>=t?e:t)),e}function Xn(e,t,n,r,o,i){var s,c=1&t,w=2&t,L=4&t;if(n&&(s=o?n(e,r,o,i):n(e)),void 0!==s)return s;if(!Va(e))return e;var A=Ra(e);if(A){if(s=function(e){var t=e.length,n=new e.constructor(t);t&&"string"==typeof e[0]&&ke.call(e,"index")&&(n.index=e.index,n.input=e.input);return n}(e),!c)return bo(e,s)}else{var P=oi(e),R=P==f||P==d;if(za(e))return po(e,c);if(P==v||P==a||R&&!o){if(s=w||R?{}:ai(e),!c)return w?function(e,t){return wo(e,ri(e),t)}(e,function(e,t){return e&&wo(t,xs(t),e)}(s,e)):function(e,t){return wo(e,ni(e),t)}(e,Gn(s,e))}else{if(!Fe[P])return o?e:{};s=function(e,t,n){var r=e.constructor;switch(t){case _:return ho(e);case u:case l:return new r(+e);case x:return function(e,t){var n=t?ho(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case k:case C:case O:case E:case S:case T:case"[object Uint8ClampedArray]":case j:case M:return vo(e,n);case p:return new r;case h:case y:return new r(e);case g:return function(e){var t=new e.constructor(e.source,te.exec(e));return t.lastIndex=e.lastIndex,t}(e);case m:return new r;case b:return o=e,Sn?he(Sn.call(o)):{}}var o}(e,P,c)}}i||(i=new zn);var D=i.get(e);if(D)return D;i.set(e,s),Za(e)?e.forEach((function(r){s.add(Xn(r,t,n,r,e,i))})):Ya(e)&&e.forEach((function(r,o){s.set(o,Xn(r,t,n,o,e,i))}));var I=A?void 0:(L?w?$o:Go:w?xs:_s)(e);return it(I||e,(function(r,o){I&&(r=e[o=r]),Vn(s,o,Xn(r,t,n,o,e,i))})),s}function Qn(e,t,n){var r=n.length;if(null==e)return!r;for(e=he(e);r--;){var o=n[r],i=t[o],a=e[o];if(void 0===a&&!(o in e)||!i(a))return!1}return!0}function Jn(e,t,n){if("function"!=typeof e)throw new me(r);return _i((function(){e.apply(void 0,n)}),t)}function er(e,t,n,r){var o=-1,i=lt,a=!0,s=e.length,u=[],l=t.length;if(!s)return u;n&&(t=ft(t,jt(n))),r?(i=ct,a=!1):t.length>=200&&(i=Lt,a=!1,t=new Nn(t));e:for(;++o<s;){var c=e[o],f=null==n?c:n(c);if(c=r||0!==c?c:0,a&&f==f){for(var d=l;d--;)if(t[d]===f)continue e;u.push(c)}else i(t,f,r)||u.push(c)}return u}jn.templateSettings={escape:z,evaluate:F,interpolate:B,variable:"",imports:{_:jn}},jn.prototype=Ln.prototype,jn.prototype.constructor=jn,An.prototype=Mn(Ln.prototype),An.prototype.constructor=An,Pn.prototype=Mn(Ln.prototype),Pn.prototype.constructor=Pn,Rn.prototype.clear=function(){this.__data__=yn?yn(null):{},this.size=0},Rn.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Rn.prototype.get=function(e){var t=this.__data__;if(yn){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return ke.call(t,e)?t[e]:void 0},Rn.prototype.has=function(e){var t=this.__data__;return yn?void 0!==t[e]:ke.call(t,e)},Rn.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=yn&&void 0===t?"__lodash_hash_undefined__":t,this},Dn.prototype.clear=function(){this.__data__=[],this.size=0},Dn.prototype.delete=function(e){var t=this.__data__,n=qn(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ke.call(t,n,1),--this.size,!0)},Dn.prototype.get=function(e){var t=this.__data__,n=qn(t,e);return n<0?void 0:t[n][1]},Dn.prototype.has=function(e){return qn(this.__data__,e)>-1},Dn.prototype.set=function(e,t){var n=this.__data__,r=qn(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},In.prototype.clear=function(){this.size=0,this.__data__={hash:new Rn,map:new(hn||Dn),string:new Rn}},In.prototype.delete=function(e){var t=Jo(this,e).delete(e);return this.size-=t?1:0,t},In.prototype.get=function(e){return Jo(this,e).get(e)},In.prototype.has=function(e){return Jo(this,e).has(e)},In.prototype.set=function(e,t){var n=Jo(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Nn.prototype.add=Nn.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},Nn.prototype.has=function(e){return this.__data__.has(e)},zn.prototype.clear=function(){this.__data__=new Dn,this.size=0},zn.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},zn.prototype.get=function(e){return this.__data__.get(e)},zn.prototype.has=function(e){return this.__data__.has(e)},zn.prototype.set=function(e,t){var n=this.__data__;if(n instanceof Dn){var r=n.__data__;if(!hn||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new In(r)}return n.set(e,t),this.size=n.size,this};var tr=ko(lr),nr=ko(cr,!0);function rr(e,t){var n=!0;return tr(e,(function(e,r,o){return n=!!t(e,r,o)})),n}function or(e,t,n){for(var r=-1,o=e.length;++r<o;){var i=e[r],a=t(i);if(null!=a&&(void 0===s?a==a&&!Qa(a):n(a,s)))var s=a,u=i}return u}function ir(e,t){var n=[];return tr(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}function ar(e,t,n,r,o){var i=-1,a=e.length;for(n||(n=si),o||(o=[]);++i<a;){var s=e[i];t>0&&n(s)?t>1?ar(s,t-1,n,r,o):dt(o,s):r||(o[o.length]=s)}return o}var sr=Co(),ur=Co(!0);function lr(e,t){return e&&sr(e,t,_s)}function cr(e,t){return e&&ur(e,t,_s)}function fr(e,t){return ut(t,(function(t){return Ha(e[t])}))}function dr(e,t){for(var n=0,r=(t=uo(t,e)).length;null!=e&&n<r;)e=e[Si(t[n++])];return n&&n==r?e:void 0}function pr(e,t,n){var r=t(e);return Ra(e)?r:dt(r,n(e))}function hr(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Ct&&Ct in he(e)?function(e){var t=ke.call(e,Ct),n=e[Ct];try{e[Ct]=void 0;var r=!0}catch(e){}var o=Ee.call(e);r&&(t?e[Ct]=n:delete e[Ct]);return o}(e):function(e){return Ee.call(e)}(e)}function vr(e,t){return e>t}function gr(e,t){return null!=e&&ke.call(e,t)}function mr(e,t){return null!=e&&t in he(e)}function yr(e,t,n){for(var r=n?ct:lt,o=e[0].length,i=e.length,a=i,s=G(i),u=1/0,l=[];a--;){var c=e[a];a&&t&&(c=ft(c,jt(t))),u=un(c.length,u),s[a]=!n&&(t||o>=120&&c.length>=120)?new Nn(a&&c):void 0}c=e[0];var f=-1,d=s[0];e:for(;++f<o&&l.length<u;){var p=c[f],h=t?t(p):p;if(p=n||0!==p?p:0,!(d?Lt(d,h):r(l,h,n))){for(a=i;--a;){var v=s[a];if(!(v?Lt(v,h):r(e[a],h,n)))continue e}d&&d.push(h),l.push(p)}}return l}function br(e,t,n){var r=null==(e=mi(e,t=uo(t,e)))?e:e[Si(Bi(t))];return null==r?void 0:rt(r,e,n)}function wr(e){return qa(e)&&hr(e)==a}function _r(e,t,n,r,o){return e===t||(null==e||null==t||!qa(e)&&!qa(t)?e!=e&&t!=t:function(e,t,n,r,o,i){var f=Ra(e),d=Ra(t),w=f?s:oi(e),k=d?s:oi(t),C=(w=w==a?v:w)==v,O=(k=k==a?v:k)==v,E=w==k;if(E&&za(e)){if(!za(t))return!1;f=!0,C=!1}if(E&&!C)return i||(i=new zn),f||Ja(e)?qo(e,t,n,r,o,i):function(e,t,n,r,o,i,a){switch(n){case x:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _:return!(e.byteLength!=t.byteLength||!i(new Be(e),new Be(t)));case u:case l:case h:return Ma(+e,+t);case c:return e.name==t.name&&e.message==t.message;case g:case y:return e==t+"";case p:var s=Ft;case m:var f=1&r;if(s||(s=Ut),e.size!=t.size&&!f)return!1;var d=a.get(e);if(d)return d==t;r|=2,a.set(e,t);var v=qo(s(e),s(t),r,o,i,a);return a.delete(e),v;case b:if(Sn)return Sn.call(e)==Sn.call(t)}return!1}(e,t,w,n,r,o,i);if(!(1&n)){var S=C&&ke.call(e,"__wrapped__"),T=O&&ke.call(t,"__wrapped__");if(S||T){var j=S?e.value():e,M=T?t.value():t;return i||(i=new zn),o(j,M,n,r,i)}}if(!E)return!1;return i||(i=new zn),function(e,t,n,r,o,i){var a=1&n,s=Go(e),u=s.length,l=Go(t).length;if(u!=l&&!a)return!1;var c=u;for(;c--;){var f=s[c];if(!(a?f in t:ke.call(t,f)))return!1}var d=i.get(e),p=i.get(t);if(d&&p)return d==t&&p==e;var h=!0;i.set(e,t),i.set(t,e);var v=a;for(;++c<u;){f=s[c];var g=e[f],m=t[f];if(r)var y=a?r(m,g,f,t,e,i):r(g,m,f,e,t,i);if(!(void 0===y?g===m||o(g,m,n,r,i):y)){h=!1;break}v||(v="constructor"==f)}if(h&&!v){var b=e.constructor,w=t.constructor;b==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(h=!1)}return i.delete(e),i.delete(t),h}(e,t,n,r,o,i)}(e,t,n,r,_r,o))}function xr(e,t,n,r){var o=n.length,i=o,a=!r;if(null==e)return!i;for(e=he(e);o--;){var s=n[o];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<i;){var u=(s=n[o])[0],l=e[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in e))return!1}else{var f=new zn;if(r)var d=r(l,c,u,e,t,f);if(!(void 0===d?_r(c,l,3,r,f):d))return!1}}return!0}function kr(e){return!(!Va(e)||(t=e,Oe&&Oe in t))&&(Ha(e)?je:oe).test(Ti(e));var t}function Cr(e){return"function"==typeof e?e:null==e?Gs:"object"==typeof e?Ra(e)?Mr(e[0],e[1]):jr(e):nu(e)}function Or(e){if(!pi(e))return an(e);var t=[];for(var n in he(e))ke.call(e,n)&&"constructor"!=n&&t.push(n);return t}function Er(e){if(!Va(e))return function(e){var t=[];if(null!=e)for(var n in he(e))t.push(n);return t}(e);var t=pi(e),n=[];for(var r in e)("constructor"!=r||!t&&ke.call(e,r))&&n.push(r);return n}function Sr(e,t){return e<t}function Tr(e,t){var n=-1,r=Ia(e)?G(e.length):[];return tr(e,(function(e,o,i){r[++n]=t(e,o,i)})),r}function jr(e){var t=ei(e);return 1==t.length&&t[0][2]?vi(t[0][0],t[0][1]):function(n){return n===e||xr(n,e,t)}}function Mr(e,t){return ci(e)&&hi(t)?vi(Si(e),t):function(n){var r=gs(n,e);return void 0===r&&r===t?ms(n,e):_r(t,r,3)}}function Lr(e,t,n,r,o){e!==t&&sr(t,(function(i,a){if(o||(o=new zn),Va(i))!function(e,t,n,r,o,i,a){var s=bi(e,n),u=bi(t,n),l=a.get(u);if(l)return void Wn(e,n,l);var c=i?i(s,u,n+"",e,t,a):void 0,f=void 0===c;if(f){var d=Ra(u),p=!d&&za(u),h=!d&&!p&&Ja(u);c=u,d||p||h?Ra(s)?c=s:Na(s)?c=bo(s):p?(f=!1,c=po(u,!0)):h?(f=!1,c=vo(u,!0)):c=[]:$a(u)||Pa(u)?(c=s,Pa(s)?c=ss(s):Va(s)&&!Ha(s)||(c=ai(u))):f=!1}f&&(a.set(u,c),o(c,u,r,i,a),a.delete(u));Wn(e,n,c)}(e,t,a,n,Lr,r,o);else{var s=r?r(bi(e,a),i,a+"",e,t,o):void 0;void 0===s&&(s=i),Wn(e,a,s)}}),xs)}function Ar(e,t){var n=e.length;if(n)return ui(t+=t<0?n:0,n)?e[t]:void 0}function Pr(e,t,n){t=t.length?ft(t,(function(e){return Ra(e)?function(t){return dr(t,1===e.length?e[0]:e)}:e})):[Gs];var r=-1;return t=ft(t,jt(Qo())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(Tr(e,(function(e,n,o){return{criteria:ft(t,(function(t){return t(e)})),index:++r,value:e}})),(function(e,t){return function(e,t,n){var r=-1,o=e.criteria,i=t.criteria,a=o.length,s=n.length;for(;++r<a;){var u=go(o[r],i[r]);if(u){if(r>=s)return u;var l=n[r];return u*("desc"==l?-1:1)}}return e.index-t.index}(e,t,n)}))}function Rr(e,t,n){for(var r=-1,o=t.length,i={};++r<o;){var a=t[r],s=dr(e,a);n(s,a)&&Ur(i,uo(a,e),s)}return i}function Dr(e,t,n,r){var o=r?wt:bt,i=-1,a=t.length,s=e;for(e===t&&(t=bo(t)),n&&(s=ft(e,jt(n)));++i<a;)for(var u=0,l=t[i],c=n?n(l):l;(u=o(s,c,u,r))>-1;)s!==e&&Ke.call(s,u,1),Ke.call(e,u,1);return e}function Ir(e,t){for(var n=e?t.length:0,r=n-1;n--;){var o=t[n];if(n==r||o!==i){var i=o;ui(o)?Ke.call(e,o,1):eo(e,o)}}return e}function Nr(e,t){return e+en(fn()*(t-e+1))}function zr(e,t){var n="";if(!e||t<1||t>9007199254740991)return n;do{t%2&&(n+=e),(t=en(t/2))&&(e+=e)}while(t);return n}function Fr(e,t){return xi(gi(e,t,Gs),e+"")}function Br(e){return Bn(Ms(e))}function Hr(e,t){var n=Ms(e);return Oi(n,Zn(t,0,n.length))}function Ur(e,t,n,r){if(!Va(e))return e;for(var o=-1,i=(t=uo(t,e)).length,a=i-1,s=e;null!=s&&++o<i;){var u=Si(t[o]),l=n;if("__proto__"===u||"constructor"===u||"prototype"===u)return e;if(o!=a){var c=s[u];void 0===(l=r?r(c,u,s):void 0)&&(l=Va(c)?c:ui(t[o+1])?[]:{})}Vn(s,u,l),s=s[u]}return e}var Wr=bn?function(e,t){return bn.set(e,t),e}:Gs,Vr=Kt?function(e,t){return Kt(e,"toString",{configurable:!0,enumerable:!1,value:Vs(t),writable:!0})}:Gs;function qr(e){return Oi(Ms(e))}function Yr(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=G(o);++r<o;)i[r]=e[r+t];return i}function Gr(e,t){var n;return tr(e,(function(e,r,o){return!(n=t(e,r,o))})),!!n}function $r(e,t,n){var r=0,o=null==e?r:e.length;if("number"==typeof t&&t==t&&o<=2147483647){for(;r<o;){var i=r+o>>>1,a=e[i];null!==a&&!Qa(a)&&(n?a<=t:a<t)?r=i+1:o=i}return o}return Kr(e,t,Gs,n)}function Kr(e,t,n,r){var o=0,i=null==e?0:e.length;if(0===i)return 0;for(var a=(t=n(t))!=t,s=null===t,u=Qa(t),l=void 0===t;o<i;){var c=en((o+i)/2),f=n(e[c]),d=void 0!==f,p=null===f,h=f==f,v=Qa(f);if(a)var g=r||h;else g=l?h&&(r||d):s?h&&d&&(r||!p):u?h&&d&&!p&&(r||!v):!p&&!v&&(r?f<=t:f<t);g?o=c+1:i=c}return un(i,4294967294)}function Zr(e,t){for(var n=-1,r=e.length,o=0,i=[];++n<r;){var a=e[n],s=t?t(a):a;if(!n||!Ma(s,u)){var u=s;i[o++]=0===a?0:a}}return i}function Xr(e){return"number"==typeof e?e:Qa(e)?NaN:+e}function Qr(e){if("string"==typeof e)return e;if(Ra(e))return ft(e,Qr)+"";if(Qa(e))return Tn?Tn.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Jr(e,t,n){var r=-1,o=lt,i=e.length,a=!0,s=[],u=s;if(n)a=!1,o=ct;else if(i>=200){var l=t?null:Fo(e);if(l)return Ut(l);a=!1,o=Lt,u=new Nn}else u=t?[]:s;e:for(;++r<i;){var c=e[r],f=t?t(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var d=u.length;d--;)if(u[d]===f)continue e;t&&u.push(f),s.push(c)}else o(u,f,n)||(u!==s&&u.push(f),s.push(c))}return s}function eo(e,t){return null==(e=mi(e,t=uo(t,e)))||delete e[Si(Bi(t))]}function to(e,t,n,r){return Ur(e,t,n(dr(e,t)),r)}function no(e,t,n,r){for(var o=e.length,i=r?o:-1;(r?i--:++i<o)&&t(e[i],i,e););return n?Yr(e,r?0:i,r?i+1:o):Yr(e,r?i+1:0,r?o:i)}function ro(e,t){var n=e;return n instanceof Pn&&(n=n.value()),pt(t,(function(e,t){return t.func.apply(t.thisArg,dt([e],t.args))}),n)}function oo(e,t,n){var r=e.length;if(r<2)return r?Jr(e[0]):[];for(var o=-1,i=G(r);++o<r;)for(var a=e[o],s=-1;++s<r;)s!=o&&(i[o]=er(i[o]||a,e[s],t,n));return Jr(ar(i,1),t,n)}function io(e,t,n){for(var r=-1,o=e.length,i=t.length,a={};++r<o;){var s=r<i?t[r]:void 0;n(a,e[r],s)}return a}function ao(e){return Na(e)?e:[]}function so(e){return"function"==typeof e?e:Gs}function uo(e,t){return Ra(e)?e:ci(e,t)?[e]:Ei(us(e))}var lo=Fr;function co(e,t,n){var r=e.length;return n=void 0===n?r:n,!t&&n>=r?e:Yr(e,t,n)}var fo=Zt||function(e){return qe.clearTimeout(e)};function po(e,t){if(t)return e.slice();var n=e.length,r=We?We(n):new e.constructor(n);return e.copy(r),r}function ho(e){var t=new e.constructor(e.byteLength);return new Be(t).set(new Be(e)),t}function vo(e,t){var n=t?ho(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function go(e,t){if(e!==t){var n=void 0!==e,r=null===e,o=e==e,i=Qa(e),a=void 0!==t,s=null===t,u=t==t,l=Qa(t);if(!s&&!l&&!i&&e>t||i&&a&&u&&!s&&!l||r&&a&&u||!n&&u||!o)return 1;if(!r&&!i&&!l&&e<t||l&&n&&o&&!r&&!i||s&&n&&o||!a&&o||!u)return-1}return 0}function mo(e,t,n,r){for(var o=-1,i=e.length,a=n.length,s=-1,u=t.length,l=sn(i-a,0),c=G(u+l),f=!r;++s<u;)c[s]=t[s];for(;++o<a;)(f||o<i)&&(c[n[o]]=e[o]);for(;l--;)c[s++]=e[o++];return c}function yo(e,t,n,r){for(var o=-1,i=e.length,a=-1,s=n.length,u=-1,l=t.length,c=sn(i-s,0),f=G(c+l),d=!r;++o<c;)f[o]=e[o];for(var p=o;++u<l;)f[p+u]=t[u];for(;++a<s;)(d||o<i)&&(f[p+n[a]]=e[o++]);return f}function bo(e,t){var n=-1,r=e.length;for(t||(t=G(r));++n<r;)t[n]=e[n];return t}function wo(e,t,n,r){var o=!n;n||(n={});for(var i=-1,a=t.length;++i<a;){var s=t[i],u=r?r(n[s],e[s],s,n,e):void 0;void 0===u&&(u=e[s]),o?$n(n,s,u):Vn(n,s,u)}return n}function _o(e,t){return function(n,r){var o=Ra(n)?ot:Yn,i=t?t():{};return o(n,e,Qo(r,2),i)}}function xo(e){return Fr((function(t,n){var r=-1,o=n.length,i=o>1?n[o-1]:void 0,a=o>2?n[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,a&&li(n[0],n[1],a)&&(i=o<3?void 0:i,o=1),t=he(t);++r<o;){var s=n[r];s&&e(t,s,r,i)}return t}))}function ko(e,t){return function(n,r){if(null==n)return n;if(!Ia(n))return e(n,r);for(var o=n.length,i=t?o:-1,a=he(n);(t?i--:++i<o)&&!1!==r(a[i],i,a););return n}}function Co(e){return function(t,n,r){for(var o=-1,i=he(t),a=r(t),s=a.length;s--;){var u=a[e?s:++o];if(!1===n(i[u],u,i))break}return t}}function Oo(e){return function(t){var n=zt(t=us(t))?qt(t):void 0,r=n?n[0]:t.charAt(0),o=n?co(n,1).join(""):t.slice(1);return r[e]()+o}}function Eo(e){return function(t){return pt(Hs(Ps(t).replace(Me,"")),e,"")}}function So(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=Mn(e.prototype),r=e.apply(n,t);return Va(r)?r:n}}function To(e){return function(t,n,r){var o=he(t);if(!Ia(t)){var i=Qo(n,3);t=_s(t),n=function(e){return i(o[e],e,o)}}var a=e(t,n,r);return a>-1?o[i?t[a]:a]:void 0}}function jo(e){return Yo((function(t){var n=t.length,o=n,i=An.prototype.thru;for(e&&t.reverse();o--;){var a=t[o];if("function"!=typeof a)throw new me(r);if(i&&!s&&"wrapper"==Zo(a))var s=new An([],!0)}for(o=s?o:n;++o<n;){var u=Zo(a=t[o]),l="wrapper"==u?Ko(a):void 0;s=l&&fi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?s[Zo(l[0])].apply(s,l[3]):1==a.length&&fi(a)?s[u]():s.thru(a)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&Ra(r))return s.plant(r).value();for(var o=0,i=n?t[o].apply(this,e):r;++o<n;)i=t[o].call(this,i);return i}}))}function Mo(e,t,n,r,o,i,a,s,u,l){var c=128&t,f=1&t,d=2&t,p=24&t,h=512&t,v=d?void 0:So(e);return function g(){for(var m=arguments.length,y=G(m),b=m;b--;)y[b]=arguments[b];if(p)var w=Xo(g),_=Rt(y,w);if(r&&(y=mo(y,r,o,p)),i&&(y=yo(y,i,a,p)),m-=_,p&&m<l){var x=Ht(y,w);return No(e,t,Mo,g.placeholder,n,y,x,s,u,l-m)}var k=f?n:this,C=d?k[e]:e;return m=y.length,s?y=yi(y,s):h&&m>1&&y.reverse(),c&&u<m&&(y.length=u),this&&this!==qe&&this instanceof g&&(C=v||So(C)),C.apply(k,y)}}function Lo(e,t){return function(n,r){return function(e,t,n,r){return lr(e,(function(e,o,i){t(r,n(e),o,i)})),r}(n,e,t(r),{})}}function Ao(e,t){return function(n,r){var o;if(void 0===n&&void 0===r)return t;if(void 0!==n&&(o=n),void 0!==r){if(void 0===o)return r;"string"==typeof n||"string"==typeof r?(n=Qr(n),r=Qr(r)):(n=Xr(n),r=Xr(r)),o=e(n,r)}return o}}function Po(e){return Yo((function(t){return t=ft(t,jt(Qo())),Fr((function(n){var r=this;return e(t,(function(e){return rt(e,r,n)}))}))}))}function Ro(e,t){var n=(t=void 0===t?" ":Qr(t)).length;if(n<2)return n?zr(t,e):t;var r=zr(t,Jt(e/Vt(t)));return zt(t)?co(qt(r),0,e).join(""):r.slice(0,e)}function Do(e){return function(t,n,r){return r&&"number"!=typeof r&&li(t,n,r)&&(n=r=void 0),t=rs(t),void 0===n?(n=t,t=0):n=rs(n),function(e,t,n,r){for(var o=-1,i=sn(Jt((t-e)/(n||1)),0),a=G(i);i--;)a[r?i:++o]=e,e+=n;return a}(t,n,r=void 0===r?t<n?1:-1:rs(r),e)}}function Io(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=as(t),n=as(n)),e(t,n)}}function No(e,t,n,r,o,i,a,s,u,l){var c=8&t;t|=c?32:64,4&(t&=~(c?64:32))||(t&=-4);var f=[e,t,o,c?i:void 0,c?a:void 0,c?void 0:i,c?void 0:a,s,u,l],d=n.apply(void 0,f);return fi(e)&&wi(d,f),d.placeholder=r,ki(d,e,t)}function zo(e){var t=pe[e];return function(e,n){if(e=as(e),(n=null==n?0:un(os(n),292))&&rn(e)){var r=(us(e)+"e").split("e");return+((r=(us(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var Fo=gn&&1/Ut(new gn([,-0]))[1]==1/0?function(e){return new gn(e)}:Qs;function Bo(e){return function(t){var n=oi(t);return n==p?Ft(t):n==m?Wt(t):function(e,t){return ft(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function Ho(e,t,n,i,a,s,u,l){var c=2&t;if(!c&&"function"!=typeof e)throw new me(r);var f=i?i.length:0;if(f||(t&=-97,i=a=void 0),u=void 0===u?u:sn(os(u),0),l=void 0===l?l:os(l),f-=a?a.length:0,64&t){var d=i,p=a;i=a=void 0}var h=c?void 0:Ko(e),v=[e,t,n,i,a,d,p,s,u,l];if(h&&function(e,t){var n=e[1],r=t[1],i=n|r,a=i<131,s=128==r&&8==n||128==r&&256==n&&e[7].length<=t[8]||384==r&&t[7].length<=t[8]&&8==n;if(!a&&!s)return e;1&r&&(e[2]=t[2],i|=1&n?0:4);var u=t[3];if(u){var l=e[3];e[3]=l?mo(l,u,t[4]):u,e[4]=l?Ht(e[3],o):t[4]}(u=t[5])&&(l=e[5],e[5]=l?yo(l,u,t[6]):u,e[6]=l?Ht(e[5],o):t[6]);(u=t[7])&&(e[7]=u);128&r&&(e[8]=null==e[8]?t[8]:un(e[8],t[8]));null==e[9]&&(e[9]=t[9]);e[0]=t[0],e[1]=i}(v,h),e=v[0],t=v[1],n=v[2],i=v[3],a=v[4],!(l=v[9]=void 0===v[9]?c?0:e.length:sn(v[9]-f,0))&&24&t&&(t&=-25),t&&1!=t)g=8==t||16==t?function(e,t,n){var r=So(e);return function o(){for(var i=arguments.length,a=G(i),s=i,u=Xo(o);s--;)a[s]=arguments[s];var l=i<3&&a[0]!==u&&a[i-1]!==u?[]:Ht(a,u);if((i-=l.length)<n)return No(e,t,Mo,o.placeholder,void 0,a,l,void 0,void 0,n-i);var c=this&&this!==qe&&this instanceof o?r:e;return rt(c,this,a)}}(e,t,l):32!=t&&33!=t||a.length?Mo.apply(void 0,v):function(e,t,n,r){var o=1&t,i=So(e);return function t(){for(var a=-1,s=arguments.length,u=-1,l=r.length,c=G(l+s),f=this&&this!==qe&&this instanceof t?i:e;++u<l;)c[u]=r[u];for(;s--;)c[u++]=arguments[++a];return rt(f,o?n:this,c)}}(e,t,n,i);else var g=function(e,t,n){var r=1&t,o=So(e);return function t(){var i=this&&this!==qe&&this instanceof t?o:e;return i.apply(r?n:this,arguments)}}(e,t,n);return ki((h?Wr:wi)(g,v),e,t)}function Uo(e,t,n,r){return void 0===e||Ma(e,we[n])&&!ke.call(r,n)?t:e}function Wo(e,t,n,r,o,i){return Va(e)&&Va(t)&&(i.set(t,e),Lr(e,t,void 0,Wo,i),i.delete(t)),e}function Vo(e){return $a(e)?void 0:e}function qo(e,t,n,r,o,i){var a=1&n,s=e.length,u=t.length;if(s!=u&&!(a&&u>s))return!1;var l=i.get(e),c=i.get(t);if(l&&c)return l==t&&c==e;var f=-1,d=!0,p=2&n?new Nn:void 0;for(i.set(e,t),i.set(t,e);++f<s;){var h=e[f],v=t[f];if(r)var g=a?r(v,h,f,t,e,i):r(h,v,f,e,t,i);if(void 0!==g){if(g)continue;d=!1;break}if(p){if(!vt(t,(function(e,t){if(!Lt(p,t)&&(h===e||o(h,e,n,r,i)))return p.push(t)}))){d=!1;break}}else if(h!==v&&!o(h,v,n,r,i)){d=!1;break}}return i.delete(e),i.delete(t),d}function Yo(e){return xi(gi(e,void 0,Di),e+"")}function Go(e){return pr(e,_s,ni)}function $o(e){return pr(e,xs,ri)}var Ko=bn?function(e){return bn.get(e)}:Qs;function Zo(e){for(var t=e.name+"",n=wn[t],r=ke.call(wn,t)?n.length:0;r--;){var o=n[r],i=o.func;if(null==i||i==e)return o.name}return t}function Xo(e){return(ke.call(jn,"placeholder")?jn:e).placeholder}function Qo(){var e=jn.iteratee||$s;return e=e===$s?Cr:e,arguments.length?e(arguments[0],arguments[1]):e}function Jo(e,t){var n,r,o=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof t?"string":"hash"]:o.map}function ei(e){for(var t=_s(e),n=t.length;n--;){var r=t[n],o=e[r];t[n]=[r,o,hi(o)]}return t}function ti(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return kr(n)?n:void 0}var ni=tn?function(e){return null==e?[]:(e=he(e),ut(tn(e),(function(t){return Ge.call(e,t)})))}:iu,ri=tn?function(e){for(var t=[];e;)dt(t,ni(e)),e=Ve(e);return t}:iu,oi=hr;function ii(e,t,n){for(var r=-1,o=(t=uo(t,e)).length,i=!1;++r<o;){var a=Si(t[r]);if(!(i=null!=e&&n(e,a)))break;e=e[a]}return i||++r!=o?i:!!(o=null==e?0:e.length)&&Wa(o)&&ui(a,o)&&(Ra(e)||Pa(e))}function ai(e){return"function"!=typeof e.constructor||pi(e)?{}:Mn(Ve(e))}function si(e){return Ra(e)||Pa(e)||!!(Ze&&e&&e[Ze])}function ui(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&ae.test(e))&&e>-1&&e%1==0&&e<t}function li(e,t,n){if(!Va(n))return!1;var r=typeof t;return!!("number"==r?Ia(n)&&ui(t,n.length):"string"==r&&t in n)&&Ma(n[t],e)}function ci(e,t){if(Ra(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Qa(e))||(U.test(e)||!H.test(e)||null!=t&&e in he(t))}function fi(e){var t=Zo(e),n=jn[t];if("function"!=typeof n||!(t in Pn.prototype))return!1;if(e===n)return!0;var r=Ko(n);return!!r&&e===r[0]}(pn&&oi(new pn(new ArrayBuffer(1)))!=x||hn&&oi(new hn)!=p||vn&&"[object Promise]"!=oi(vn.resolve())||gn&&oi(new gn)!=m||mn&&oi(new mn)!=w)&&(oi=function(e){var t=hr(e),n=t==v?e.constructor:void 0,r=n?Ti(n):"";if(r)switch(r){case _n:return x;case xn:return p;case kn:return"[object Promise]";case Cn:return m;case On:return w}return t});var di=_e?Ha:au;function pi(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||we)}function hi(e){return e==e&&!Va(e)}function vi(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in he(n)))}}function gi(e,t,n){return t=sn(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=sn(r.length-t,0),a=G(i);++o<i;)a[o]=r[t+o];o=-1;for(var s=G(t+1);++o<t;)s[o]=r[o];return s[t]=n(a),rt(e,this,s)}}function mi(e,t){return t.length<2?e:dr(e,Yr(t,0,-1))}function yi(e,t){for(var n=e.length,r=un(t.length,n),o=bo(e);r--;){var i=t[r];e[r]=ui(i,n)?o[i]:void 0}return e}function bi(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var wi=Ci(Wr),_i=Qt||function(e,t){return qe.setTimeout(e,t)},xi=Ci(Vr);function ki(e,t,n){var r=t+"";return xi(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace($,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return it(i,(function(n){var r="_."+n[0];t&n[1]&&!lt(e,r)&&e.push(r)})),e.sort()}(function(e){var t=e.match(K);return t?t[1].split(Z):[]}(r),n)))}function Ci(e){var t=0,n=0;return function(){var r=ln(),o=16-(r-n);if(n=r,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Oi(e,t){var n=-1,r=e.length,o=r-1;for(t=void 0===t?r:t;++n<t;){var i=Nr(n,o),a=e[i];e[i]=e[n],e[n]=a}return e.length=t,e}var Ei=function(e){var t=Ca(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(W,(function(e,n,r,o){t.push(r?o.replace(J,"$1"):n||e)})),t}));function Si(e){if("string"==typeof e||Qa(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Ti(e){if(null!=e){try{return xe.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function ji(e){if(e instanceof Pn)return e.clone();var t=new An(e.__wrapped__,e.__chain__);return t.__actions__=bo(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var Mi=Fr((function(e,t){return Na(e)?er(e,ar(t,1,Na,!0)):[]})),Li=Fr((function(e,t){var n=Bi(t);return Na(n)&&(n=void 0),Na(e)?er(e,ar(t,1,Na,!0),Qo(n,2)):[]})),Ai=Fr((function(e,t){var n=Bi(t);return Na(n)&&(n=void 0),Na(e)?er(e,ar(t,1,Na,!0),void 0,n):[]}));function Pi(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:os(n);return o<0&&(o=sn(r+o,0)),yt(e,Qo(t,3),o)}function Ri(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r-1;return void 0!==n&&(o=os(n),o=n<0?sn(r+o,0):un(o,r-1)),yt(e,Qo(t,3),o,!0)}function Di(e){return(null==e?0:e.length)?ar(e,1):[]}function Ii(e){return e&&e.length?e[0]:void 0}var Ni=Fr((function(e){var t=ft(e,ao);return t.length&&t[0]===e[0]?yr(t):[]})),zi=Fr((function(e){var t=Bi(e),n=ft(e,ao);return t===Bi(n)?t=void 0:n.pop(),n.length&&n[0]===e[0]?yr(n,Qo(t,2)):[]})),Fi=Fr((function(e){var t=Bi(e),n=ft(e,ao);return(t="function"==typeof t?t:void 0)&&n.pop(),n.length&&n[0]===e[0]?yr(n,void 0,t):[]}));function Bi(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}var Hi=Fr(Ui);function Ui(e,t){return e&&e.length&&t&&t.length?Dr(e,t):e}var Wi=Yo((function(e,t){var n=null==e?0:e.length,r=Kn(e,t);return Ir(e,ft(t,(function(e){return ui(e,n)?+e:e})).sort(go)),r}));function Vi(e){return null==e?e:dn.call(e)}var qi=Fr((function(e){return Jr(ar(e,1,Na,!0))})),Yi=Fr((function(e){var t=Bi(e);return Na(t)&&(t=void 0),Jr(ar(e,1,Na,!0),Qo(t,2))})),Gi=Fr((function(e){var t=Bi(e);return t="function"==typeof t?t:void 0,Jr(ar(e,1,Na,!0),void 0,t)}));function $i(e){if(!e||!e.length)return[];var t=0;return e=ut(e,(function(e){if(Na(e))return t=sn(e.length,t),!0})),St(t,(function(t){return ft(e,kt(t))}))}function Ki(e,t){if(!e||!e.length)return[];var n=$i(e);return null==t?n:ft(n,(function(e){return rt(t,void 0,e)}))}var Zi=Fr((function(e,t){return Na(e)?er(e,t):[]})),Xi=Fr((function(e){return oo(ut(e,Na))})),Qi=Fr((function(e){var t=Bi(e);return Na(t)&&(t=void 0),oo(ut(e,Na),Qo(t,2))})),Ji=Fr((function(e){var t=Bi(e);return t="function"==typeof t?t:void 0,oo(ut(e,Na),void 0,t)})),ea=Fr($i);var ta=Fr((function(e){var t=e.length,n=t>1?e[t-1]:void 0;return n="function"==typeof n?(e.pop(),n):void 0,Ki(e,n)}));function na(e){var t=jn(e);return t.__chain__=!0,t}function ra(e,t){return t(e)}var oa=Yo((function(e){var t=e.length,n=t?e[0]:0,r=this.__wrapped__,o=function(t){return Kn(t,e)};return!(t>1||this.__actions__.length)&&r instanceof Pn&&ui(n)?((r=r.slice(n,+n+(t?1:0))).__actions__.push({func:ra,args:[o],thisArg:void 0}),new An(r,this.__chain__).thru((function(e){return t&&!e.length&&e.push(void 0),e}))):this.thru(o)}));var ia=_o((function(e,t,n){ke.call(e,n)?++e[n]:$n(e,n,1)}));var aa=To(Pi),sa=To(Ri);function ua(e,t){return(Ra(e)?it:tr)(e,Qo(t,3))}function la(e,t){return(Ra(e)?at:nr)(e,Qo(t,3))}var ca=_o((function(e,t,n){ke.call(e,n)?e[n].push(t):$n(e,n,[t])}));var fa=Fr((function(e,t,n){var r=-1,o="function"==typeof t,i=Ia(e)?G(e.length):[];return tr(e,(function(e){i[++r]=o?rt(t,e,n):br(e,t,n)})),i})),da=_o((function(e,t,n){$n(e,n,t)}));function pa(e,t){return(Ra(e)?ft:Tr)(e,Qo(t,3))}var ha=_o((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));var va=Fr((function(e,t){if(null==e)return[];var n=t.length;return n>1&&li(e,t[0],t[1])?t=[]:n>2&&li(t[0],t[1],t[2])&&(t=[t[0]]),Pr(e,ar(t,1),[])})),ga=Xt||function(){return qe.Date.now()};function ma(e,t,n){return t=n?void 0:t,Ho(e,128,void 0,void 0,void 0,void 0,t=e&&null==t?e.length:t)}function ya(e,t){var n;if("function"!=typeof t)throw new me(r);return e=os(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=void 0),n}}var ba=Fr((function(e,t,n){var r=1;if(n.length){var o=Ht(n,Xo(ba));r|=32}return Ho(e,r,t,n,o)})),wa=Fr((function(e,t,n){var r=3;if(n.length){var o=Ht(n,Xo(wa));r|=32}return Ho(t,r,e,n,o)}));function _a(e,t,n){var o,i,a,s,u,l,c=0,f=!1,d=!1,p=!0;if("function"!=typeof e)throw new me(r);function h(t){var n=o,r=i;return o=i=void 0,c=t,s=e.apply(r,n)}function v(e){return c=e,u=_i(m,t),f?h(e):s}function g(e){var n=e-l;return void 0===l||n>=t||n<0||d&&e-c>=a}function m(){var e=ga();if(g(e))return y(e);u=_i(m,function(e){var n=t-(e-l);return d?un(n,a-(e-c)):n}(e))}function y(e){return u=void 0,p&&o?h(e):(o=i=void 0,s)}function b(){var e=ga(),n=g(e);if(o=arguments,i=this,l=e,n){if(void 0===u)return v(l);if(d)return fo(u),u=_i(m,t),h(l)}return void 0===u&&(u=_i(m,t)),s}return t=as(t)||0,Va(n)&&(f=!!n.leading,a=(d="maxWait"in n)?sn(as(n.maxWait)||0,t):a,p="trailing"in n?!!n.trailing:p),b.cancel=function(){void 0!==u&&fo(u),c=0,o=l=i=u=void 0},b.flush=function(){return void 0===u?s:y(ga())},b}var xa=Fr((function(e,t){return Jn(e,1,t)})),ka=Fr((function(e,t,n){return Jn(e,as(t)||0,n)}));function Ca(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new me(r);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(Ca.Cache||In),n}function Oa(e){if("function"!=typeof e)throw new me(r);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}Ca.Cache=In;var Ea=lo((function(e,t){var n=(t=1==t.length&&Ra(t[0])?ft(t[0],jt(Qo())):ft(ar(t,1),jt(Qo()))).length;return Fr((function(r){for(var o=-1,i=un(r.length,n);++o<i;)r[o]=t[o].call(this,r[o]);return rt(e,this,r)}))})),Sa=Fr((function(e,t){return Ho(e,32,void 0,t,Ht(t,Xo(Sa)))})),Ta=Fr((function(e,t){return Ho(e,64,void 0,t,Ht(t,Xo(Ta)))})),ja=Yo((function(e,t){return Ho(e,256,void 0,void 0,void 0,t)}));function Ma(e,t){return e===t||e!=e&&t!=t}var La=Io(vr),Aa=Io((function(e,t){return e>=t})),Pa=wr(function(){return arguments}())?wr:function(e){return qa(e)&&ke.call(e,"callee")&&!Ge.call(e,"callee")},Ra=G.isArray,Da=Xe?jt(Xe):function(e){return qa(e)&&hr(e)==_};function Ia(e){return null!=e&&Wa(e.length)&&!Ha(e)}function Na(e){return qa(e)&&Ia(e)}var za=nn||au,Fa=Qe?jt(Qe):function(e){return qa(e)&&hr(e)==l};function Ba(e){if(!qa(e))return!1;var t=hr(e);return t==c||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!$a(e)}function Ha(e){if(!Va(e))return!1;var t=hr(e);return t==f||t==d||"[object AsyncFunction]"==t||"[object Proxy]"==t}function Ua(e){return"number"==typeof e&&e==os(e)}function Wa(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}function Va(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function qa(e){return null!=e&&"object"==typeof e}var Ya=Je?jt(Je):function(e){return qa(e)&&oi(e)==p};function Ga(e){return"number"==typeof e||qa(e)&&hr(e)==h}function $a(e){if(!qa(e)||hr(e)!=v)return!1;var t=Ve(e);if(null===t)return!0;var n=ke.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&xe.call(n)==Se}var Ka=et?jt(et):function(e){return qa(e)&&hr(e)==g};var Za=tt?jt(tt):function(e){return qa(e)&&oi(e)==m};function Xa(e){return"string"==typeof e||!Ra(e)&&qa(e)&&hr(e)==y}function Qa(e){return"symbol"==typeof e||qa(e)&&hr(e)==b}var Ja=nt?jt(nt):function(e){return qa(e)&&Wa(e.length)&&!!ze[hr(e)]};var es=Io(Sr),ts=Io((function(e,t){return e<=t}));function ns(e){if(!e)return[];if(Ia(e))return Xa(e)?qt(e):bo(e);if(gt&&e[gt])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[gt]());var t=oi(e);return(t==p?Ft:t==m?Ut:Ms)(e)}function rs(e){return e?(e=as(e))===1/0||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}function os(e){var t=rs(e),n=t%1;return t==t?n?t-n:t:0}function is(e){return e?Zn(os(e),0,4294967295):0}function as(e){if("number"==typeof e)return e;if(Qa(e))return NaN;if(Va(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=Va(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Tt(e);var n=re.test(e);return n||ie.test(e)?Ue(e.slice(2),n?2:8):ne.test(e)?NaN:+e}function ss(e){return wo(e,xs(e))}function us(e){return null==e?"":Qr(e)}var ls=xo((function(e,t){if(pi(t)||Ia(t))wo(t,_s(t),e);else for(var n in t)ke.call(t,n)&&Vn(e,n,t[n])})),cs=xo((function(e,t){wo(t,xs(t),e)})),fs=xo((function(e,t,n,r){wo(t,xs(t),e,r)})),ds=xo((function(e,t,n,r){wo(t,_s(t),e,r)})),ps=Yo(Kn);var hs=Fr((function(e,t){e=he(e);var n=-1,r=t.length,o=r>2?t[2]:void 0;for(o&&li(t[0],t[1],o)&&(r=1);++n<r;)for(var i=t[n],a=xs(i),s=-1,u=a.length;++s<u;){var l=a[s],c=e[l];(void 0===c||Ma(c,we[l])&&!ke.call(e,l))&&(e[l]=i[l])}return e})),vs=Fr((function(e){return e.push(void 0,Wo),rt(Cs,void 0,e)}));function gs(e,t,n){var r=null==e?void 0:dr(e,t);return void 0===r?n:r}function ms(e,t){return null!=e&&ii(e,t,mr)}var ys=Lo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Ee.call(t)),e[t]=n}),Vs(Gs)),bs=Lo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Ee.call(t)),ke.call(e,t)?e[t].push(n):e[t]=[n]}),Qo),ws=Fr(br);function _s(e){return Ia(e)?Fn(e):Or(e)}function xs(e){return Ia(e)?Fn(e,!0):Er(e)}var ks=xo((function(e,t,n){Lr(e,t,n)})),Cs=xo((function(e,t,n,r){Lr(e,t,n,r)})),Os=Yo((function(e,t){var n={};if(null==e)return n;var r=!1;t=ft(t,(function(t){return t=uo(t,e),r||(r=t.length>1),t})),wo(e,$o(e),n),r&&(n=Xn(n,7,Vo));for(var o=t.length;o--;)eo(n,t[o]);return n}));var Es=Yo((function(e,t){return null==e?{}:function(e,t){return Rr(e,t,(function(t,n){return ms(e,n)}))}(e,t)}));function Ss(e,t){if(null==e)return{};var n=ft($o(e),(function(e){return[e]}));return t=Qo(t),Rr(e,n,(function(e,n){return t(e,n[0])}))}var Ts=Bo(_s),js=Bo(xs);function Ms(e){return null==e?[]:Mt(e,_s(e))}var Ls=Eo((function(e,t,n){return t=t.toLowerCase(),e+(n?As(t):t)}));function As(e){return Bs(us(e).toLowerCase())}function Ps(e){return(e=us(e))&&e.replace(se,Dt).replace(Le,"")}var Rs=Eo((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),Ds=Eo((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),Is=Oo("toLowerCase");var Ns=Eo((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));var zs=Eo((function(e,t,n){return e+(n?" ":"")+Bs(t)}));var Fs=Eo((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),Bs=Oo("toUpperCase");function Hs(e,t,n){return e=us(e),void 0===(t=n?void 0:t)?function(e){return De.test(e)}(e)?function(e){return e.match(Pe)||[]}(e):function(e){return e.match(X)||[]}(e):e.match(t)||[]}var Us=Fr((function(e,t){try{return rt(e,void 0,t)}catch(e){return Ba(e)?e:new fe(e)}})),Ws=Yo((function(e,t){return it(t,(function(t){t=Si(t),$n(e,t,ba(e[t],e))})),e}));function Vs(e){return function(){return e}}var qs=jo(),Ys=jo(!0);function Gs(e){return e}function $s(e){return Cr("function"==typeof e?e:Xn(e,1))}var Ks=Fr((function(e,t){return function(n){return br(n,e,t)}})),Zs=Fr((function(e,t){return function(n){return br(e,n,t)}}));function Xs(e,t,n){var r=_s(t),o=fr(t,r);null!=n||Va(t)&&(o.length||!r.length)||(n=t,t=e,e=this,o=fr(t,_s(t)));var i=!(Va(n)&&"chain"in n&&!n.chain),a=Ha(e);return it(o,(function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(i||t){var n=e(this.__wrapped__),o=n.__actions__=bo(this.__actions__);return o.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,dt([this.value()],arguments))})})),e}function Qs(){}var Js=Po(ft),eu=Po(st),tu=Po(vt);function nu(e){return ci(e)?kt(Si(e)):function(e){return function(t){return dr(t,e)}}(e)}var ru=Do(),ou=Do(!0);function iu(){return[]}function au(){return!1}var su=Ao((function(e,t){return e+t}),0),uu=zo("ceil"),lu=Ao((function(e,t){return e/t}),1),cu=zo("floor");var fu,du=Ao((function(e,t){return e*t}),1),pu=zo("round"),hu=Ao((function(e,t){return e-t}),0);return jn.after=function(e,t){if("function"!=typeof t)throw new me(r);return e=os(e),function(){if(--e<1)return t.apply(this,arguments)}},jn.ary=ma,jn.assign=ls,jn.assignIn=cs,jn.assignInWith=fs,jn.assignWith=ds,jn.at=ps,jn.before=ya,jn.bind=ba,jn.bindAll=Ws,jn.bindKey=wa,jn.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Ra(e)?e:[e]},jn.chain=na,jn.chunk=function(e,t,n){t=(n?li(e,t,n):void 0===t)?1:sn(os(t),0);var r=null==e?0:e.length;if(!r||t<1)return[];for(var o=0,i=0,a=G(Jt(r/t));o<r;)a[i++]=Yr(e,o,o+=t);return a},jn.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,o=[];++t<n;){var i=e[t];i&&(o[r++]=i)}return o},jn.concat=function(){var e=arguments.length;if(!e)return[];for(var t=G(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return dt(Ra(n)?bo(n):[n],ar(t,1))},jn.cond=function(e){var t=null==e?0:e.length,n=Qo();return e=t?ft(e,(function(e){if("function"!=typeof e[1])throw new me(r);return[n(e[0]),e[1]]})):[],Fr((function(n){for(var r=-1;++r<t;){var o=e[r];if(rt(o[0],this,n))return rt(o[1],this,n)}}))},jn.conforms=function(e){return function(e){var t=_s(e);return function(n){return Qn(n,e,t)}}(Xn(e,1))},jn.constant=Vs,jn.countBy=ia,jn.create=function(e,t){var n=Mn(e);return null==t?n:Gn(n,t)},jn.curry=function e(t,n,r){var o=Ho(t,8,void 0,void 0,void 0,void 0,void 0,n=r?void 0:n);return o.placeholder=e.placeholder,o},jn.curryRight=function e(t,n,r){var o=Ho(t,16,void 0,void 0,void 0,void 0,void 0,n=r?void 0:n);return o.placeholder=e.placeholder,o},jn.debounce=_a,jn.defaults=hs,jn.defaultsDeep=vs,jn.defer=xa,jn.delay=ka,jn.difference=Mi,jn.differenceBy=Li,jn.differenceWith=Ai,jn.drop=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,(t=n||void 0===t?1:os(t))<0?0:t,r):[]},jn.dropRight=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,0,(t=r-(t=n||void 0===t?1:os(t)))<0?0:t):[]},jn.dropRightWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!0,!0):[]},jn.dropWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!0):[]},jn.fill=function(e,t,n,r){var o=null==e?0:e.length;return o?(n&&"number"!=typeof n&&li(e,t,n)&&(n=0,r=o),function(e,t,n,r){var o=e.length;for((n=os(n))<0&&(n=-n>o?0:o+n),(r=void 0===r||r>o?o:os(r))<0&&(r+=o),r=n>r?0:is(r);n<r;)e[n++]=t;return e}(e,t,n,r)):[]},jn.filter=function(e,t){return(Ra(e)?ut:ir)(e,Qo(t,3))},jn.flatMap=function(e,t){return ar(pa(e,t),1)},jn.flatMapDeep=function(e,t){return ar(pa(e,t),1/0)},jn.flatMapDepth=function(e,t,n){return n=void 0===n?1:os(n),ar(pa(e,t),n)},jn.flatten=Di,jn.flattenDeep=function(e){return(null==e?0:e.length)?ar(e,1/0):[]},jn.flattenDepth=function(e,t){return(null==e?0:e.length)?ar(e,t=void 0===t?1:os(t)):[]},jn.flip=function(e){return Ho(e,512)},jn.flow=qs,jn.flowRight=Ys,jn.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var o=e[t];r[o[0]]=o[1]}return r},jn.functions=function(e){return null==e?[]:fr(e,_s(e))},jn.functionsIn=function(e){return null==e?[]:fr(e,xs(e))},jn.groupBy=ca,jn.initial=function(e){return(null==e?0:e.length)?Yr(e,0,-1):[]},jn.intersection=Ni,jn.intersectionBy=zi,jn.intersectionWith=Fi,jn.invert=ys,jn.invertBy=bs,jn.invokeMap=fa,jn.iteratee=$s,jn.keyBy=da,jn.keys=_s,jn.keysIn=xs,jn.map=pa,jn.mapKeys=function(e,t){var n={};return t=Qo(t,3),lr(e,(function(e,r,o){$n(n,t(e,r,o),e)})),n},jn.mapValues=function(e,t){var n={};return t=Qo(t,3),lr(e,(function(e,r,o){$n(n,r,t(e,r,o))})),n},jn.matches=function(e){return jr(Xn(e,1))},jn.matchesProperty=function(e,t){return Mr(e,Xn(t,1))},jn.memoize=Ca,jn.merge=ks,jn.mergeWith=Cs,jn.method=Ks,jn.methodOf=Zs,jn.mixin=Xs,jn.negate=Oa,jn.nthArg=function(e){return e=os(e),Fr((function(t){return Ar(t,e)}))},jn.omit=Os,jn.omitBy=function(e,t){return Ss(e,Oa(Qo(t)))},jn.once=function(e){return ya(2,e)},jn.orderBy=function(e,t,n,r){return null==e?[]:(Ra(t)||(t=null==t?[]:[t]),Ra(n=r?void 0:n)||(n=null==n?[]:[n]),Pr(e,t,n))},jn.over=Js,jn.overArgs=Ea,jn.overEvery=eu,jn.overSome=tu,jn.partial=Sa,jn.partialRight=Ta,jn.partition=ha,jn.pick=Es,jn.pickBy=Ss,jn.property=nu,jn.propertyOf=function(e){return function(t){return null==e?void 0:dr(e,t)}},jn.pull=Hi,jn.pullAll=Ui,jn.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?Dr(e,t,Qo(n,2)):e},jn.pullAllWith=function(e,t,n){return e&&e.length&&t&&t.length?Dr(e,t,void 0,n):e},jn.pullAt=Wi,jn.range=ru,jn.rangeRight=ou,jn.rearg=ja,jn.reject=function(e,t){return(Ra(e)?ut:ir)(e,Oa(Qo(t,3)))},jn.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,o=[],i=e.length;for(t=Qo(t,3);++r<i;){var a=e[r];t(a,r,e)&&(n.push(a),o.push(r))}return Ir(e,o),n},jn.rest=function(e,t){if("function"!=typeof e)throw new me(r);return Fr(e,t=void 0===t?t:os(t))},jn.reverse=Vi,jn.sampleSize=function(e,t,n){return t=(n?li(e,t,n):void 0===t)?1:os(t),(Ra(e)?Hn:Hr)(e,t)},jn.set=function(e,t,n){return null==e?e:Ur(e,t,n)},jn.setWith=function(e,t,n,r){return r="function"==typeof r?r:void 0,null==e?e:Ur(e,t,n,r)},jn.shuffle=function(e){return(Ra(e)?Un:qr)(e)},jn.slice=function(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&li(e,t,n)?(t=0,n=r):(t=null==t?0:os(t),n=void 0===n?r:os(n)),Yr(e,t,n)):[]},jn.sortBy=va,jn.sortedUniq=function(e){return e&&e.length?Zr(e):[]},jn.sortedUniqBy=function(e,t){return e&&e.length?Zr(e,Qo(t,2)):[]},jn.split=function(e,t,n){return n&&"number"!=typeof n&&li(e,t,n)&&(t=n=void 0),(n=void 0===n?4294967295:n>>>0)?(e=us(e))&&("string"==typeof t||null!=t&&!Ka(t))&&!(t=Qr(t))&&zt(e)?co(qt(e),0,n):e.split(t,n):[]},jn.spread=function(e,t){if("function"!=typeof e)throw new me(r);return t=null==t?0:sn(os(t),0),Fr((function(n){var r=n[t],o=co(n,0,t);return r&&dt(o,r),rt(e,this,o)}))},jn.tail=function(e){var t=null==e?0:e.length;return t?Yr(e,1,t):[]},jn.take=function(e,t,n){return e&&e.length?Yr(e,0,(t=n||void 0===t?1:os(t))<0?0:t):[]},jn.takeRight=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,(t=r-(t=n||void 0===t?1:os(t)))<0?0:t,r):[]},jn.takeRightWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!1,!0):[]},jn.takeWhile=function(e,t){return e&&e.length?no(e,Qo(t,3)):[]},jn.tap=function(e,t){return t(e),e},jn.throttle=function(e,t,n){var o=!0,i=!0;if("function"!=typeof e)throw new me(r);return Va(n)&&(o="leading"in n?!!n.leading:o,i="trailing"in n?!!n.trailing:i),_a(e,t,{leading:o,maxWait:t,trailing:i})},jn.thru=ra,jn.toArray=ns,jn.toPairs=Ts,jn.toPairsIn=js,jn.toPath=function(e){return Ra(e)?ft(e,Si):Qa(e)?[e]:bo(Ei(us(e)))},jn.toPlainObject=ss,jn.transform=function(e,t,n){var r=Ra(e),o=r||za(e)||Ja(e);if(t=Qo(t,4),null==n){var i=e&&e.constructor;n=o?r?new i:[]:Va(e)&&Ha(i)?Mn(Ve(e)):{}}return(o?it:lr)(e,(function(e,r,o){return t(n,e,r,o)})),n},jn.unary=function(e){return ma(e,1)},jn.union=qi,jn.unionBy=Yi,jn.unionWith=Gi,jn.uniq=function(e){return e&&e.length?Jr(e):[]},jn.uniqBy=function(e,t){return e&&e.length?Jr(e,Qo(t,2)):[]},jn.uniqWith=function(e,t){return t="function"==typeof t?t:void 0,e&&e.length?Jr(e,void 0,t):[]},jn.unset=function(e,t){return null==e||eo(e,t)},jn.unzip=$i,jn.unzipWith=Ki,jn.update=function(e,t,n){return null==e?e:to(e,t,so(n))},jn.updateWith=function(e,t,n,r){return r="function"==typeof r?r:void 0,null==e?e:to(e,t,so(n),r)},jn.values=Ms,jn.valuesIn=function(e){return null==e?[]:Mt(e,xs(e))},jn.without=Zi,jn.words=Hs,jn.wrap=function(e,t){return Sa(so(t),e)},jn.xor=Xi,jn.xorBy=Qi,jn.xorWith=Ji,jn.zip=ea,jn.zipObject=function(e,t){return io(e||[],t||[],Vn)},jn.zipObjectDeep=function(e,t){return io(e||[],t||[],Ur)},jn.zipWith=ta,jn.entries=Ts,jn.entriesIn=js,jn.extend=cs,jn.extendWith=fs,Xs(jn,jn),jn.add=su,jn.attempt=Us,jn.camelCase=Ls,jn.capitalize=As,jn.ceil=uu,jn.clamp=function(e,t,n){return void 0===n&&(n=t,t=void 0),void 0!==n&&(n=(n=as(n))==n?n:0),void 0!==t&&(t=(t=as(t))==t?t:0),Zn(as(e),t,n)},jn.clone=function(e){return Xn(e,4)},jn.cloneDeep=function(e){return Xn(e,5)},jn.cloneDeepWith=function(e,t){return Xn(e,5,t="function"==typeof t?t:void 0)},jn.cloneWith=function(e,t){return Xn(e,4,t="function"==typeof t?t:void 0)},jn.conformsTo=function(e,t){return null==t||Qn(e,t,_s(t))},jn.deburr=Ps,jn.defaultTo=function(e,t){return null==e||e!=e?t:e},jn.divide=lu,jn.endsWith=function(e,t,n){e=us(e),t=Qr(t);var r=e.length,o=n=void 0===n?r:Zn(os(n),0,r);return(n-=t.length)>=0&&e.slice(n,o)==t},jn.eq=Ma,jn.escape=function(e){return(e=us(e))&&N.test(e)?e.replace(D,It):e},jn.escapeRegExp=function(e){return(e=us(e))&&q.test(e)?e.replace(V,"\\$&"):e},jn.every=function(e,t,n){var r=Ra(e)?st:rr;return n&&li(e,t,n)&&(t=void 0),r(e,Qo(t,3))},jn.find=aa,jn.findIndex=Pi,jn.findKey=function(e,t){return mt(e,Qo(t,3),lr)},jn.findLast=sa,jn.findLastIndex=Ri,jn.findLastKey=function(e,t){return mt(e,Qo(t,3),cr)},jn.floor=cu,jn.forEach=ua,jn.forEachRight=la,jn.forIn=function(e,t){return null==e?e:sr(e,Qo(t,3),xs)},jn.forInRight=function(e,t){return null==e?e:ur(e,Qo(t,3),xs)},jn.forOwn=function(e,t){return e&&lr(e,Qo(t,3))},jn.forOwnRight=function(e,t){return e&&cr(e,Qo(t,3))},jn.get=gs,jn.gt=La,jn.gte=Aa,jn.has=function(e,t){return null!=e&&ii(e,t,gr)},jn.hasIn=ms,jn.head=Ii,jn.identity=Gs,jn.includes=function(e,t,n,r){e=Ia(e)?e:Ms(e),n=n&&!r?os(n):0;var o=e.length;return n<0&&(n=sn(o+n,0)),Xa(e)?n<=o&&e.indexOf(t,n)>-1:!!o&&bt(e,t,n)>-1},jn.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:os(n);return o<0&&(o=sn(r+o,0)),bt(e,t,o)},jn.inRange=function(e,t,n){return t=rs(t),void 0===n?(n=t,t=0):n=rs(n),function(e,t,n){return e>=un(t,n)&&e<sn(t,n)}(e=as(e),t,n)},jn.invoke=ws,jn.isArguments=Pa,jn.isArray=Ra,jn.isArrayBuffer=Da,jn.isArrayLike=Ia,jn.isArrayLikeObject=Na,jn.isBoolean=function(e){return!0===e||!1===e||qa(e)&&hr(e)==u},jn.isBuffer=za,jn.isDate=Fa,jn.isElement=function(e){return qa(e)&&1===e.nodeType&&!$a(e)},jn.isEmpty=function(e){if(null==e)return!0;if(Ia(e)&&(Ra(e)||"string"==typeof e||"function"==typeof e.splice||za(e)||Ja(e)||Pa(e)))return!e.length;var t=oi(e);if(t==p||t==m)return!e.size;if(pi(e))return!Or(e).length;for(var n in e)if(ke.call(e,n))return!1;return!0},jn.isEqual=function(e,t){return _r(e,t)},jn.isEqualWith=function(e,t,n){var r=(n="function"==typeof n?n:void 0)?n(e,t):void 0;return void 0===r?_r(e,t,void 0,n):!!r},jn.isError=Ba,jn.isFinite=function(e){return"number"==typeof e&&rn(e)},jn.isFunction=Ha,jn.isInteger=Ua,jn.isLength=Wa,jn.isMap=Ya,jn.isMatch=function(e,t){return e===t||xr(e,t,ei(t))},jn.isMatchWith=function(e,t,n){return n="function"==typeof n?n:void 0,xr(e,t,ei(t),n)},jn.isNaN=function(e){return Ga(e)&&e!=+e},jn.isNative=function(e){if(di(e))throw new fe("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return kr(e)},jn.isNil=function(e){return null==e},jn.isNull=function(e){return null===e},jn.isNumber=Ga,jn.isObject=Va,jn.isObjectLike=qa,jn.isPlainObject=$a,jn.isRegExp=Ka,jn.isSafeInteger=function(e){return Ua(e)&&e>=-9007199254740991&&e<=9007199254740991},jn.isSet=Za,jn.isString=Xa,jn.isSymbol=Qa,jn.isTypedArray=Ja,jn.isUndefined=function(e){return void 0===e},jn.isWeakMap=function(e){return qa(e)&&oi(e)==w},jn.isWeakSet=function(e){return qa(e)&&"[object WeakSet]"==hr(e)},jn.join=function(e,t){return null==e?"":on.call(e,t)},jn.kebabCase=Rs,jn.last=Bi,jn.lastIndexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r;return void 0!==n&&(o=(o=os(n))<0?sn(r+o,0):un(o,r-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):yt(e,_t,o,!0)},jn.lowerCase=Ds,jn.lowerFirst=Is,jn.lt=es,jn.lte=ts,jn.max=function(e){return e&&e.length?or(e,Gs,vr):void 0},jn.maxBy=function(e,t){return e&&e.length?or(e,Qo(t,2),vr):void 0},jn.mean=function(e){return xt(e,Gs)},jn.meanBy=function(e,t){return xt(e,Qo(t,2))},jn.min=function(e){return e&&e.length?or(e,Gs,Sr):void 0},jn.minBy=function(e,t){return e&&e.length?or(e,Qo(t,2),Sr):void 0},jn.stubArray=iu,jn.stubFalse=au,jn.stubObject=function(){return{}},jn.stubString=function(){return""},jn.stubTrue=function(){return!0},jn.multiply=du,jn.nth=function(e,t){return e&&e.length?Ar(e,os(t)):void 0},jn.noConflict=function(){return qe._===this&&(qe._=Te),this},jn.noop=Qs,jn.now=ga,jn.pad=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;if(!t||r>=t)return e;var o=(t-r)/2;return Ro(en(o),n)+e+Ro(Jt(o),n)},jn.padEnd=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;return t&&r<t?e+Ro(t-r,n):e},jn.padStart=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;return t&&r<t?Ro(t-r,n)+e:e},jn.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),cn(us(e).replace(Y,""),t||0)},jn.random=function(e,t,n){if(n&&"boolean"!=typeof n&&li(e,t,n)&&(t=n=void 0),void 0===n&&("boolean"==typeof t?(n=t,t=void 0):"boolean"==typeof e&&(n=e,e=void 0)),void 0===e&&void 0===t?(e=0,t=1):(e=rs(e),void 0===t?(t=e,e=0):t=rs(t)),e>t){var r=e;e=t,t=r}if(n||e%1||t%1){var o=fn();return un(e+o*(t-e+He("1e-"+((o+"").length-1))),t)}return Nr(e,t)},jn.reduce=function(e,t,n){var r=Ra(e)?pt:Ot,o=arguments.length<3;return r(e,Qo(t,4),n,o,tr)},jn.reduceRight=function(e,t,n){var r=Ra(e)?ht:Ot,o=arguments.length<3;return r(e,Qo(t,4),n,o,nr)},jn.repeat=function(e,t,n){return t=(n?li(e,t,n):void 0===t)?1:os(t),zr(us(e),t)},jn.replace=function(){var e=arguments,t=us(e[0]);return e.length<3?t:t.replace(e[1],e[2])},jn.result=function(e,t,n){var r=-1,o=(t=uo(t,e)).length;for(o||(o=1,e=void 0);++r<o;){var i=null==e?void 0:e[Si(t[r])];void 0===i&&(r=o,i=n),e=Ha(i)?i.call(e):i}return e},jn.round=pu,jn.runInContext=e,jn.sample=function(e){return(Ra(e)?Bn:Br)(e)},jn.size=function(e){if(null==e)return 0;if(Ia(e))return Xa(e)?Vt(e):e.length;var t=oi(e);return t==p||t==m?e.size:Or(e).length},jn.snakeCase=Ns,jn.some=function(e,t,n){var r=Ra(e)?vt:Gr;return n&&li(e,t,n)&&(t=void 0),r(e,Qo(t,3))},jn.sortedIndex=function(e,t){return $r(e,t)},jn.sortedIndexBy=function(e,t,n){return Kr(e,t,Qo(n,2))},jn.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=$r(e,t);if(r<n&&Ma(e[r],t))return r}return-1},jn.sortedLastIndex=function(e,t){return $r(e,t,!0)},jn.sortedLastIndexBy=function(e,t,n){return Kr(e,t,Qo(n,2),!0)},jn.sortedLastIndexOf=function(e,t){if(null==e?0:e.length){var n=$r(e,t,!0)-1;if(Ma(e[n],t))return n}return-1},jn.startCase=zs,jn.startsWith=function(e,t,n){return e=us(e),n=null==n?0:Zn(os(n),0,e.length),t=Qr(t),e.slice(n,n+t.length)==t},jn.subtract=hu,jn.sum=function(e){return e&&e.length?Et(e,Gs):0},jn.sumBy=function(e,t){return e&&e.length?Et(e,Qo(t,2)):0},jn.template=function(e,t,n){var r=jn.templateSettings;n&&li(e,t,n)&&(t=void 0),e=us(e),t=fs({},t,r,Uo);var o,i,a=fs({},t.imports,r.imports,Uo),s=_s(a),u=Mt(a,s),l=0,c=t.interpolate||ue,f="__p += '",d=ve((t.escape||ue).source+"|"+c.source+"|"+(c===B?ee:ue).source+"|"+(t.evaluate||ue).source+"|$","g"),p="//# sourceURL="+(ke.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Ne+"]")+"\n";e.replace(d,(function(t,n,r,a,s,u){return r||(r=a),f+=e.slice(l,u).replace(le,Nt),n&&(o=!0,f+="' +\n__e("+n+") +\n'"),s&&(i=!0,f+="';\n"+s+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+t.length,t})),f+="';\n";var h=ke.call(t,"variable")&&t.variable;if(h){if(Q.test(h))throw new fe("Invalid `variable` option passed into `_.template`")}else f="with (obj) {\n"+f+"\n}\n";f=(i?f.replace(L,""):f).replace(A,"$1").replace(P,"$1;"),f="function("+(h||"obj")+") {\n"+(h?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(i?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=Us((function(){return de(s,p+"return "+f).apply(void 0,u)}));if(v.source=f,Ba(v))throw v;return v},jn.times=function(e,t){if((e=os(e))<1||e>9007199254740991)return[];var n=4294967295,r=un(e,4294967295);e-=4294967295;for(var o=St(r,t=Qo(t));++n<e;)t(n);return o},jn.toFinite=rs,jn.toInteger=os,jn.toLength=is,jn.toLower=function(e){return us(e).toLowerCase()},jn.toNumber=as,jn.toSafeInteger=function(e){return e?Zn(os(e),-9007199254740991,9007199254740991):0===e?e:0},jn.toString=us,jn.toUpper=function(e){return us(e).toUpperCase()},jn.trim=function(e,t,n){if((e=us(e))&&(n||void 0===t))return Tt(e);if(!e||!(t=Qr(t)))return e;var r=qt(e),o=qt(t);return co(r,At(r,o),Pt(r,o)+1).join("")},jn.trimEnd=function(e,t,n){if((e=us(e))&&(n||void 0===t))return e.slice(0,Yt(e)+1);if(!e||!(t=Qr(t)))return e;var r=qt(e);return co(r,0,Pt(r,qt(t))+1).join("")},jn.trimStart=function(e,t,n){if((e=us(e))&&(n||void 0===t))return e.replace(Y,"");if(!e||!(t=Qr(t)))return e;var r=qt(e);return co(r,At(r,qt(t))).join("")},jn.truncate=function(e,t){var n=30,r="...";if(Va(t)){var o="separator"in t?t.separator:o;n="length"in t?os(t.length):n,r="omission"in t?Qr(t.omission):r}var i=(e=us(e)).length;if(zt(e)){var a=qt(e);i=a.length}if(n>=i)return e;var s=n-Vt(r);if(s<1)return r;var u=a?co(a,0,s).join(""):e.slice(0,s);if(void 0===o)return u+r;if(a&&(s+=u.length-s),Ka(o)){if(e.slice(s).search(o)){var l,c=u;for(o.global||(o=ve(o.source,us(te.exec(o))+"g")),o.lastIndex=0;l=o.exec(c);)var f=l.index;u=u.slice(0,void 0===f?s:f)}}else if(e.indexOf(Qr(o),s)!=s){var d=u.lastIndexOf(o);d>-1&&(u=u.slice(0,d))}return u+r},jn.unescape=function(e){return(e=us(e))&&I.test(e)?e.replace(R,Gt):e},jn.uniqueId=function(e){var t=++Ce;return us(e)+t},jn.upperCase=Fs,jn.upperFirst=Bs,jn.each=ua,jn.eachRight=la,jn.first=Ii,Xs(jn,(fu={},lr(jn,(function(e,t){ke.call(jn.prototype,t)||(fu[t]=e)})),fu),{chain:!1}),jn.VERSION="4.17.21",it(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){jn[e].placeholder=jn})),it(["drop","take"],(function(e,t){Pn.prototype[e]=function(n){n=void 0===n?1:sn(os(n),0);var r=this.__filtered__&&!t?new Pn(this):this.clone();return r.__filtered__?r.__takeCount__=un(n,r.__takeCount__):r.__views__.push({size:un(n,4294967295),type:e+(r.__dir__<0?"Right":"")}),r},Pn.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),it(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=1==n||3==n;Pn.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:Qo(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),it(["head","last"],(function(e,t){var n="take"+(t?"Right":"");Pn.prototype[e]=function(){return this[n](1).value()[0]}})),it(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");Pn.prototype[e]=function(){return this.__filtered__?new Pn(this):this[n](1)}})),Pn.prototype.compact=function(){return this.filter(Gs)},Pn.prototype.find=function(e){return this.filter(e).head()},Pn.prototype.findLast=function(e){return this.reverse().find(e)},Pn.prototype.invokeMap=Fr((function(e,t){return"function"==typeof e?new Pn(this):this.map((function(n){return br(n,e,t)}))})),Pn.prototype.reject=function(e){return this.filter(Oa(Qo(e)))},Pn.prototype.slice=function(e,t){e=os(e);var n=this;return n.__filtered__&&(e>0||t<0)?new Pn(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),void 0!==t&&(n=(t=os(t))<0?n.dropRight(-t):n.take(t-e)),n)},Pn.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Pn.prototype.toArray=function(){return this.take(4294967295)},lr(Pn.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),r=/^(?:head|last)$/.test(t),o=jn[r?"take"+("last"==t?"Right":""):t],i=r||/^find/.test(t);o&&(jn.prototype[t]=function(){var t=this.__wrapped__,a=r?[1]:arguments,s=t instanceof Pn,u=a[0],l=s||Ra(t),c=function(e){var t=o.apply(jn,dt([e],a));return r&&f?t[0]:t};l&&n&&"function"==typeof u&&1!=u.length&&(s=l=!1);var f=this.__chain__,d=!!this.__actions__.length,p=i&&!f,h=s&&!d;if(!i&&l){t=h?t:new Pn(this);var v=e.apply(t,a);return v.__actions__.push({func:ra,args:[c],thisArg:void 0}),new An(v,f)}return p&&h?e.apply(this,a):(v=this.thru(c),p?r?v.value()[0]:v.value():v)})})),it(["pop","push","shift","sort","splice","unshift"],(function(e){var t=ye[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);jn.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var o=this.value();return t.apply(Ra(o)?o:[],e)}return this[n]((function(n){return t.apply(Ra(n)?n:[],e)}))}})),lr(Pn.prototype,(function(e,t){var n=jn[t];if(n){var r=n.name+"";ke.call(wn,r)||(wn[r]=[]),wn[r].push({name:t,func:n})}})),wn[Mo(void 0,2).name]=[{name:"wrapper",func:void 0}],Pn.prototype.clone=function(){var e=new Pn(this.__wrapped__);return e.__actions__=bo(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=bo(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=bo(this.__views__),e},Pn.prototype.reverse=function(){if(this.__filtered__){var e=new Pn(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},Pn.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=Ra(e),r=t<0,o=n?e.length:0,i=function(e,t,n){var r=-1,o=n.length;for(;++r<o;){var i=n[r],a=i.size;switch(i.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=un(t,e+a);break;case"takeRight":e=sn(e,t-a)}}return{start:e,end:t}}(0,o,this.__views__),a=i.start,s=i.end,u=s-a,l=r?s:a-1,c=this.__iteratees__,f=c.length,d=0,p=un(u,this.__takeCount__);if(!n||!r&&o==u&&p==u)return ro(e,this.__actions__);var h=[];e:for(;u--&&d<p;){for(var v=-1,g=e[l+=t];++v<f;){var m=c[v],y=m.iteratee,b=m.type,w=y(g);if(2==b)g=w;else if(!w){if(1==b)continue e;break e}}h[d++]=g}return h},jn.prototype.at=oa,jn.prototype.chain=function(){return na(this)},jn.prototype.commit=function(){return new An(this.value(),this.__chain__)},jn.prototype.next=function(){void 0===this.__values__&&(this.__values__=ns(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?void 0:this.__values__[this.__index__++]}},jn.prototype.plant=function(e){for(var t,n=this;n instanceof Ln;){var r=ji(n);r.__index__=0,r.__values__=void 0,t?o.__wrapped__=r:t=r;var o=r;n=n.__wrapped__}return o.__wrapped__=e,t},jn.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof Pn){var t=e;return this.__actions__.length&&(t=new Pn(this)),(t=t.reverse()).__actions__.push({func:ra,args:[Vi],thisArg:void 0}),new An(t,this.__chain__)}return this.thru(Vi)},jn.prototype.toJSON=jn.prototype.valueOf=jn.prototype.value=function(){return ro(this.__wrapped__,this.__actions__)},jn.prototype.first=jn.prototype.head,gt&&(jn.prototype[gt]=function(){return this}),jn}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(qe._=$t,define((function(){return $t}))):Ge?((Ge.exports=$t)._=$t,Ye._=$t):qe._=$t}).call(this)}).call(this,n(31),n(57)(e))},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){(function(e,n){(function(){var r="Expected a function",o="__lodash_placeholder__",i=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],a="[object Arguments]",s="[object Array]",u="[object Boolean]",l="[object Date]",c="[object Error]",f="[object Function]",d="[object GeneratorFunction]",p="[object Map]",h="[object Number]",v="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",b="[object Symbol]",w="[object WeakMap]",_="[object ArrayBuffer]",x="[object DataView]",k="[object Float32Array]",C="[object Float64Array]",O="[object Int8Array]",E="[object Int16Array]",S="[object Int32Array]",T="[object Uint8Array]",j="[object Uint16Array]",M="[object Uint32Array]",L=/\b__p \+= '';/g,A=/\b(__p \+=) '' \+/g,P=/(__e\(.*?\)|\b__t\)) \+\n'';/g,R=/&(?:amp|lt|gt|quot|#39);/g,D=/[&<>"']/g,I=RegExp(R.source),N=RegExp(D.source),z=/<%-([\s\S]+?)%>/g,F=/<%([\s\S]+?)%>/g,B=/<%=([\s\S]+?)%>/g,H=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,U=/^\w*$/,W=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,V=/[\\^$.*+?()[\]{}|]/g,q=RegExp(V.source),Y=/^\s+/,G=/\s/,$=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,K=/\{\n\/\* \[wrapped with (.+)\] \*/,Z=/,? & /,X=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,Q=/[()=,{}\[\]\/\s]/,J=/\\(\\)?/g,ee=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,te=/\w*$/,ne=/^[-+]0x[0-9a-f]+$/i,re=/^0b[01]+$/i,oe=/^\[object .+?Constructor\]$/,ie=/^0o[0-7]+$/i,ae=/^(?:0|[1-9]\d*)$/,se=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,ue=/($^)/,le=/['\n\r\u2028\u2029\\]/g,ce="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",fe="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\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",de="[\\ud800-\\udfff]",pe="["+fe+"]",he="["+ce+"]",ve="\\d+",ge="[\\u2700-\\u27bf]",me="[a-z\\xdf-\\xf6\\xf8-\\xff]",ye="[^\\ud800-\\udfff"+fe+ve+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",be="\\ud83c[\\udffb-\\udfff]",we="[^\\ud800-\\udfff]",_e="(?:\\ud83c[\\udde6-\\uddff]){2}",xe="[\\ud800-\\udbff][\\udc00-\\udfff]",ke="[A-Z\\xc0-\\xd6\\xd8-\\xde]",Ce="(?:"+me+"|"+ye+")",Oe="(?:"+ke+"|"+ye+")",Ee="(?:"+he+"|"+be+")"+"?",Se="[\\ufe0e\\ufe0f]?"+Ee+("(?:\\u200d(?:"+[we,_e,xe].join("|")+")[\\ufe0e\\ufe0f]?"+Ee+")*"),Te="(?:"+[ge,_e,xe].join("|")+")"+Se,je="(?:"+[we+he+"?",he,_e,xe,de].join("|")+")",Me=RegExp("['\u2019]","g"),Le=RegExp(he,"g"),Ae=RegExp(be+"(?="+be+")|"+je+Se,"g"),Pe=RegExp([ke+"?"+me+"+(?:['\u2019](?:d|ll|m|re|s|t|ve))?(?="+[pe,ke,"$"].join("|")+")",Oe+"+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?(?="+[pe,ke+Ce,"$"].join("|")+")",ke+"?"+Ce+"+(?:['\u2019](?:d|ll|m|re|s|t|ve))?",ke+"+(?:['\u2019](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",ve,Te].join("|"),"g"),Re=RegExp("[\\u200d\\ud800-\\udfff"+ce+"\\ufe0e\\ufe0f]"),De=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Ie=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Ne=-1,ze={};ze[k]=ze[C]=ze[O]=ze[E]=ze[S]=ze[T]=ze["[object Uint8ClampedArray]"]=ze[j]=ze[M]=!0,ze[a]=ze[s]=ze[_]=ze[u]=ze[x]=ze[l]=ze[c]=ze[f]=ze[p]=ze[h]=ze[v]=ze[g]=ze[m]=ze[y]=ze[w]=!1;var Fe={};Fe[a]=Fe[s]=Fe[_]=Fe[x]=Fe[u]=Fe[l]=Fe[k]=Fe[C]=Fe[O]=Fe[E]=Fe[S]=Fe[p]=Fe[h]=Fe[v]=Fe[g]=Fe[m]=Fe[y]=Fe[b]=Fe[T]=Fe["[object Uint8ClampedArray]"]=Fe[j]=Fe[M]=!0,Fe[c]=Fe[f]=Fe[w]=!1;var Be={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},He=parseFloat,Ue=parseInt,We="object"==typeof e&&e&&e.Object===Object&&e,Ve="object"==typeof self&&self&&self.Object===Object&&self,qe=We||Ve||Function("return this")(),Ye=t&&!t.nodeType&&t,Ge=Ye&&"object"==typeof n&&n&&!n.nodeType&&n,$e=Ge&&Ge.exports===Ye,Ke=$e&&We.process,Ze=function(){try{var e=Ge&&Ge.require&&Ge.require("util").types;return e||Ke&&Ke.binding&&Ke.binding("util")}catch(e){}}(),Xe=Ze&&Ze.isArrayBuffer,Qe=Ze&&Ze.isDate,Je=Ze&&Ze.isMap,et=Ze&&Ze.isRegExp,tt=Ze&&Ze.isSet,nt=Ze&&Ze.isTypedArray;function rt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function ot(e,t,n,r){for(var o=-1,i=null==e?0:e.length;++o<i;){var a=e[o];t(r,a,n(a),e)}return r}function it(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function at(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function st(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function ut(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}function lt(e,t){return!!(null==e?0:e.length)&&bt(e,t,0)>-1}function ct(e,t,n){for(var r=-1,o=null==e?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}function ft(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}function dt(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}function pt(e,t,n,r){var o=-1,i=null==e?0:e.length;for(r&&i&&(n=e[++o]);++o<i;)n=t(n,e[o],o,e);return n}function ht(e,t,n,r){var o=null==e?0:e.length;for(r&&o&&(n=e[--o]);o--;)n=t(n,e[o],o,e);return n}function vt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var gt=kt("length");function mt(e,t,n){var r;return n(e,(function(e,n,o){if(t(e,n,o))return r=n,!1})),r}function yt(e,t,n,r){for(var o=e.length,i=n+(r?1:-1);r?i--:++i<o;)if(t(e[i],i,e))return i;return-1}function bt(e,t,n){return t==t?function(e,t,n){var r=n-1,o=e.length;for(;++r<o;)if(e[r]===t)return r;return-1}(e,t,n):yt(e,_t,n)}function wt(e,t,n,r){for(var o=n-1,i=e.length;++o<i;)if(r(e[o],t))return o;return-1}function _t(e){return e!=e}function xt(e,t){var n=null==e?0:e.length;return n?Et(e,t)/n:NaN}function kt(e){return function(t){return null==t?void 0:t[e]}}function Ct(e){return function(t){return null==e?void 0:e[t]}}function Ot(e,t,n,r,o){return o(e,(function(e,o,i){n=r?(r=!1,e):t(n,e,o,i)})),n}function Et(e,t){for(var n,r=-1,o=e.length;++r<o;){var i=t(e[r]);void 0!==i&&(n=void 0===n?i:n+i)}return n}function St(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Tt(e){return e?e.slice(0,Yt(e)+1).replace(Y,""):e}function jt(e){return function(t){return e(t)}}function Mt(e,t){return ft(t,(function(t){return e[t]}))}function Lt(e,t){return e.has(t)}function At(e,t){for(var n=-1,r=e.length;++n<r&&bt(t,e[n],0)>-1;);return n}function Pt(e,t){for(var n=e.length;n--&&bt(t,e[n],0)>-1;);return n}function Rt(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}var Dt=Ct({"\xc0":"A","\xc1":"A","\xc2":"A","\xc3":"A","\xc4":"A","\xc5":"A","\xe0":"a","\xe1":"a","\xe2":"a","\xe3":"a","\xe4":"a","\xe5":"a","\xc7":"C","\xe7":"c","\xd0":"D","\xf0":"d","\xc8":"E","\xc9":"E","\xca":"E","\xcb":"E","\xe8":"e","\xe9":"e","\xea":"e","\xeb":"e","\xcc":"I","\xcd":"I","\xce":"I","\xcf":"I","\xec":"i","\xed":"i","\xee":"i","\xef":"i","\xd1":"N","\xf1":"n","\xd2":"O","\xd3":"O","\xd4":"O","\xd5":"O","\xd6":"O","\xd8":"O","\xf2":"o","\xf3":"o","\xf4":"o","\xf5":"o","\xf6":"o","\xf8":"o","\xd9":"U","\xda":"U","\xdb":"U","\xdc":"U","\xf9":"u","\xfa":"u","\xfb":"u","\xfc":"u","\xdd":"Y","\xfd":"y","\xff":"y","\xc6":"Ae","\xe6":"ae","\xde":"Th","\xfe":"th","\xdf":"ss","\u0100":"A","\u0102":"A","\u0104":"A","\u0101":"a","\u0103":"a","\u0105":"a","\u0106":"C","\u0108":"C","\u010a":"C","\u010c":"C","\u0107":"c","\u0109":"c","\u010b":"c","\u010d":"c","\u010e":"D","\u0110":"D","\u010f":"d","\u0111":"d","\u0112":"E","\u0114":"E","\u0116":"E","\u0118":"E","\u011a":"E","\u0113":"e","\u0115":"e","\u0117":"e","\u0119":"e","\u011b":"e","\u011c":"G","\u011e":"G","\u0120":"G","\u0122":"G","\u011d":"g","\u011f":"g","\u0121":"g","\u0123":"g","\u0124":"H","\u0126":"H","\u0125":"h","\u0127":"h","\u0128":"I","\u012a":"I","\u012c":"I","\u012e":"I","\u0130":"I","\u0129":"i","\u012b":"i","\u012d":"i","\u012f":"i","\u0131":"i","\u0134":"J","\u0135":"j","\u0136":"K","\u0137":"k","\u0138":"k","\u0139":"L","\u013b":"L","\u013d":"L","\u013f":"L","\u0141":"L","\u013a":"l","\u013c":"l","\u013e":"l","\u0140":"l","\u0142":"l","\u0143":"N","\u0145":"N","\u0147":"N","\u014a":"N","\u0144":"n","\u0146":"n","\u0148":"n","\u014b":"n","\u014c":"O","\u014e":"O","\u0150":"O","\u014d":"o","\u014f":"o","\u0151":"o","\u0154":"R","\u0156":"R","\u0158":"R","\u0155":"r","\u0157":"r","\u0159":"r","\u015a":"S","\u015c":"S","\u015e":"S","\u0160":"S","\u015b":"s","\u015d":"s","\u015f":"s","\u0161":"s","\u0162":"T","\u0164":"T","\u0166":"T","\u0163":"t","\u0165":"t","\u0167":"t","\u0168":"U","\u016a":"U","\u016c":"U","\u016e":"U","\u0170":"U","\u0172":"U","\u0169":"u","\u016b":"u","\u016d":"u","\u016f":"u","\u0171":"u","\u0173":"u","\u0174":"W","\u0175":"w","\u0176":"Y","\u0177":"y","\u0178":"Y","\u0179":"Z","\u017b":"Z","\u017d":"Z","\u017a":"z","\u017c":"z","\u017e":"z","\u0132":"IJ","\u0133":"ij","\u0152":"Oe","\u0153":"oe","\u0149":"'n","\u017f":"s"}),It=Ct({"&":"&","<":"<",">":">",'"':""","'":"'"});function Nt(e){return"\\"+Be[e]}function zt(e){return Re.test(e)}function Ft(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function Bt(e,t){return function(n){return e(t(n))}}function Ht(e,t){for(var n=-1,r=e.length,i=0,a=[];++n<r;){var s=e[n];s!==t&&s!==o||(e[n]=o,a[i++]=n)}return a}function Ut(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function Wt(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}function Vt(e){return zt(e)?function(e){var t=Ae.lastIndex=0;for(;Ae.test(e);)++t;return t}(e):gt(e)}function qt(e){return zt(e)?function(e){return e.match(Ae)||[]}(e):function(e){return e.split("")}(e)}function Yt(e){for(var t=e.length;t--&&G.test(e.charAt(t)););return t}var Gt=Ct({"&":"&","<":"<",">":">",""":'"',"'":"'"});var $t=function e(t){var n,G=(t=null==t?qe:$t.defaults(qe.Object(),t,$t.pick(qe,Ie))).Array,ce=t.Date,fe=t.Error,de=t.Function,pe=t.Math,he=t.Object,ve=t.RegExp,ge=t.String,me=t.TypeError,ye=G.prototype,be=de.prototype,we=he.prototype,_e=t["__core-js_shared__"],xe=be.toString,ke=we.hasOwnProperty,Ce=0,Oe=(n=/[^.]+$/.exec(_e&&_e.keys&&_e.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",Ee=we.toString,Se=xe.call(he),Te=qe._,je=ve("^"+xe.call(ke).replace(V,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ae=$e?t.Buffer:void 0,Re=t.Symbol,Be=t.Uint8Array,We=Ae?Ae.allocUnsafe:void 0,Ve=Bt(he.getPrototypeOf,he),Ye=he.create,Ge=we.propertyIsEnumerable,Ke=ye.splice,Ze=Re?Re.isConcatSpreadable:void 0,gt=Re?Re.iterator:void 0,Ct=Re?Re.toStringTag:void 0,Kt=function(){try{var e=ti(he,"defineProperty");return e({},"",{}),e}catch(e){}}(),Zt=t.clearTimeout!==qe.clearTimeout&&t.clearTimeout,Xt=ce&&ce.now!==qe.Date.now&&ce.now,Qt=t.setTimeout!==qe.setTimeout&&t.setTimeout,Jt=pe.ceil,en=pe.floor,tn=he.getOwnPropertySymbols,nn=Ae?Ae.isBuffer:void 0,rn=t.isFinite,on=ye.join,an=Bt(he.keys,he),sn=pe.max,un=pe.min,ln=ce.now,cn=t.parseInt,fn=pe.random,dn=ye.reverse,pn=ti(t,"DataView"),hn=ti(t,"Map"),vn=ti(t,"Promise"),gn=ti(t,"Set"),mn=ti(t,"WeakMap"),yn=ti(he,"create"),bn=mn&&new mn,wn={},_n=Ti(pn),xn=Ti(hn),kn=Ti(vn),Cn=Ti(gn),On=Ti(mn),En=Re?Re.prototype:void 0,Sn=En?En.valueOf:void 0,Tn=En?En.toString:void 0;function jn(e){if(qa(e)&&!Ra(e)&&!(e instanceof Pn)){if(e instanceof An)return e;if(ke.call(e,"__wrapped__"))return ji(e)}return new An(e)}var Mn=function(){function e(){}return function(t){if(!Va(t))return{};if(Ye)return Ye(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function Ln(){}function An(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}function Pn(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function Rn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Dn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function In(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Nn(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new In;++t<n;)this.add(e[t])}function zn(e){var t=this.__data__=new Dn(e);this.size=t.size}function Fn(e,t){var n=Ra(e),r=!n&&Pa(e),o=!n&&!r&&za(e),i=!n&&!r&&!o&&Ja(e),a=n||r||o||i,s=a?St(e.length,ge):[],u=s.length;for(var l in e)!t&&!ke.call(e,l)||a&&("length"==l||o&&("offset"==l||"parent"==l)||i&&("buffer"==l||"byteLength"==l||"byteOffset"==l)||ui(l,u))||s.push(l);return s}function Bn(e){var t=e.length;return t?e[Nr(0,t-1)]:void 0}function Hn(e,t){return Oi(bo(e),Zn(t,0,e.length))}function Un(e){return Oi(bo(e))}function Wn(e,t,n){(void 0!==n&&!Ma(e[t],n)||void 0===n&&!(t in e))&&$n(e,t,n)}function Vn(e,t,n){var r=e[t];ke.call(e,t)&&Ma(r,n)&&(void 0!==n||t in e)||$n(e,t,n)}function qn(e,t){for(var n=e.length;n--;)if(Ma(e[n][0],t))return n;return-1}function Yn(e,t,n,r){return tr(e,(function(e,o,i){t(r,e,n(e),i)})),r}function Gn(e,t){return e&&wo(t,_s(t),e)}function $n(e,t,n){"__proto__"==t&&Kt?Kt(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function Kn(e,t){for(var n=-1,r=t.length,o=G(r),i=null==e;++n<r;)o[n]=i?void 0:gs(e,t[n]);return o}function Zn(e,t,n){return e==e&&(void 0!==n&&(e=e<=n?e:n),void 0!==t&&(e=e>=t?e:t)),e}function Xn(e,t,n,r,o,i){var s,c=1&t,w=2&t,L=4&t;if(n&&(s=o?n(e,r,o,i):n(e)),void 0!==s)return s;if(!Va(e))return e;var A=Ra(e);if(A){if(s=function(e){var t=e.length,n=new e.constructor(t);t&&"string"==typeof e[0]&&ke.call(e,"index")&&(n.index=e.index,n.input=e.input);return n}(e),!c)return bo(e,s)}else{var P=oi(e),R=P==f||P==d;if(za(e))return po(e,c);if(P==v||P==a||R&&!o){if(s=w||R?{}:ai(e),!c)return w?function(e,t){return wo(e,ri(e),t)}(e,function(e,t){return e&&wo(t,xs(t),e)}(s,e)):function(e,t){return wo(e,ni(e),t)}(e,Gn(s,e))}else{if(!Fe[P])return o?e:{};s=function(e,t,n){var r=e.constructor;switch(t){case _:return ho(e);case u:case l:return new r(+e);case x:return function(e,t){var n=t?ho(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case k:case C:case O:case E:case S:case T:case"[object Uint8ClampedArray]":case j:case M:return vo(e,n);case p:return new r;case h:case y:return new r(e);case g:return function(e){var t=new e.constructor(e.source,te.exec(e));return t.lastIndex=e.lastIndex,t}(e);case m:return new r;case b:return o=e,Sn?he(Sn.call(o)):{}}var o}(e,P,c)}}i||(i=new zn);var D=i.get(e);if(D)return D;i.set(e,s),Za(e)?e.forEach((function(r){s.add(Xn(r,t,n,r,e,i))})):Ya(e)&&e.forEach((function(r,o){s.set(o,Xn(r,t,n,o,e,i))}));var I=A?void 0:(L?w?$o:Go:w?xs:_s)(e);return it(I||e,(function(r,o){I&&(r=e[o=r]),Vn(s,o,Xn(r,t,n,o,e,i))})),s}function Qn(e,t,n){var r=n.length;if(null==e)return!r;for(e=he(e);r--;){var o=n[r],i=t[o],a=e[o];if(void 0===a&&!(o in e)||!i(a))return!1}return!0}function Jn(e,t,n){if("function"!=typeof e)throw new me(r);return _i((function(){e.apply(void 0,n)}),t)}function er(e,t,n,r){var o=-1,i=lt,a=!0,s=e.length,u=[],l=t.length;if(!s)return u;n&&(t=ft(t,jt(n))),r?(i=ct,a=!1):t.length>=200&&(i=Lt,a=!1,t=new Nn(t));e:for(;++o<s;){var c=e[o],f=null==n?c:n(c);if(c=r||0!==c?c:0,a&&f==f){for(var d=l;d--;)if(t[d]===f)continue e;u.push(c)}else i(t,f,r)||u.push(c)}return u}jn.templateSettings={escape:z,evaluate:F,interpolate:B,variable:"",imports:{_:jn}},jn.prototype=Ln.prototype,jn.prototype.constructor=jn,An.prototype=Mn(Ln.prototype),An.prototype.constructor=An,Pn.prototype=Mn(Ln.prototype),Pn.prototype.constructor=Pn,Rn.prototype.clear=function(){this.__data__=yn?yn(null):{},this.size=0},Rn.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Rn.prototype.get=function(e){var t=this.__data__;if(yn){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return ke.call(t,e)?t[e]:void 0},Rn.prototype.has=function(e){var t=this.__data__;return yn?void 0!==t[e]:ke.call(t,e)},Rn.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=yn&&void 0===t?"__lodash_hash_undefined__":t,this},Dn.prototype.clear=function(){this.__data__=[],this.size=0},Dn.prototype.delete=function(e){var t=this.__data__,n=qn(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ke.call(t,n,1),--this.size,!0)},Dn.prototype.get=function(e){var t=this.__data__,n=qn(t,e);return n<0?void 0:t[n][1]},Dn.prototype.has=function(e){return qn(this.__data__,e)>-1},Dn.prototype.set=function(e,t){var n=this.__data__,r=qn(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},In.prototype.clear=function(){this.size=0,this.__data__={hash:new Rn,map:new(hn||Dn),string:new Rn}},In.prototype.delete=function(e){var t=Jo(this,e).delete(e);return this.size-=t?1:0,t},In.prototype.get=function(e){return Jo(this,e).get(e)},In.prototype.has=function(e){return Jo(this,e).has(e)},In.prototype.set=function(e,t){var n=Jo(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Nn.prototype.add=Nn.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},Nn.prototype.has=function(e){return this.__data__.has(e)},zn.prototype.clear=function(){this.__data__=new Dn,this.size=0},zn.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},zn.prototype.get=function(e){return this.__data__.get(e)},zn.prototype.has=function(e){return this.__data__.has(e)},zn.prototype.set=function(e,t){var n=this.__data__;if(n instanceof Dn){var r=n.__data__;if(!hn||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new In(r)}return n.set(e,t),this.size=n.size,this};var tr=ko(lr),nr=ko(cr,!0);function rr(e,t){var n=!0;return tr(e,(function(e,r,o){return n=!!t(e,r,o)})),n}function or(e,t,n){for(var r=-1,o=e.length;++r<o;){var i=e[r],a=t(i);if(null!=a&&(void 0===s?a==a&&!Qa(a):n(a,s)))var s=a,u=i}return u}function ir(e,t){var n=[];return tr(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}function ar(e,t,n,r,o){var i=-1,a=e.length;for(n||(n=si),o||(o=[]);++i<a;){var s=e[i];t>0&&n(s)?t>1?ar(s,t-1,n,r,o):dt(o,s):r||(o[o.length]=s)}return o}var sr=Co(),ur=Co(!0);function lr(e,t){return e&&sr(e,t,_s)}function cr(e,t){return e&&ur(e,t,_s)}function fr(e,t){return ut(t,(function(t){return Ha(e[t])}))}function dr(e,t){for(var n=0,r=(t=uo(t,e)).length;null!=e&&n<r;)e=e[Si(t[n++])];return n&&n==r?e:void 0}function pr(e,t,n){var r=t(e);return Ra(e)?r:dt(r,n(e))}function hr(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Ct&&Ct in he(e)?function(e){var t=ke.call(e,Ct),n=e[Ct];try{e[Ct]=void 0;var r=!0}catch(e){}var o=Ee.call(e);r&&(t?e[Ct]=n:delete e[Ct]);return o}(e):function(e){return Ee.call(e)}(e)}function vr(e,t){return e>t}function gr(e,t){return null!=e&&ke.call(e,t)}function mr(e,t){return null!=e&&t in he(e)}function yr(e,t,n){for(var r=n?ct:lt,o=e[0].length,i=e.length,a=i,s=G(i),u=1/0,l=[];a--;){var c=e[a];a&&t&&(c=ft(c,jt(t))),u=un(c.length,u),s[a]=!n&&(t||o>=120&&c.length>=120)?new Nn(a&&c):void 0}c=e[0];var f=-1,d=s[0];e:for(;++f<o&&l.length<u;){var p=c[f],h=t?t(p):p;if(p=n||0!==p?p:0,!(d?Lt(d,h):r(l,h,n))){for(a=i;--a;){var v=s[a];if(!(v?Lt(v,h):r(e[a],h,n)))continue e}d&&d.push(h),l.push(p)}}return l}function br(e,t,n){var r=null==(e=mi(e,t=uo(t,e)))?e:e[Si(Bi(t))];return null==r?void 0:rt(r,e,n)}function wr(e){return qa(e)&&hr(e)==a}function _r(e,t,n,r,o){return e===t||(null==e||null==t||!qa(e)&&!qa(t)?e!=e&&t!=t:function(e,t,n,r,o,i){var f=Ra(e),d=Ra(t),w=f?s:oi(e),k=d?s:oi(t),C=(w=w==a?v:w)==v,O=(k=k==a?v:k)==v,E=w==k;if(E&&za(e)){if(!za(t))return!1;f=!0,C=!1}if(E&&!C)return i||(i=new zn),f||Ja(e)?qo(e,t,n,r,o,i):function(e,t,n,r,o,i,a){switch(n){case x:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case _:return!(e.byteLength!=t.byteLength||!i(new Be(e),new Be(t)));case u:case l:case h:return Ma(+e,+t);case c:return e.name==t.name&&e.message==t.message;case g:case y:return e==t+"";case p:var s=Ft;case m:var f=1&r;if(s||(s=Ut),e.size!=t.size&&!f)return!1;var d=a.get(e);if(d)return d==t;r|=2,a.set(e,t);var v=qo(s(e),s(t),r,o,i,a);return a.delete(e),v;case b:if(Sn)return Sn.call(e)==Sn.call(t)}return!1}(e,t,w,n,r,o,i);if(!(1&n)){var S=C&&ke.call(e,"__wrapped__"),T=O&&ke.call(t,"__wrapped__");if(S||T){var j=S?e.value():e,M=T?t.value():t;return i||(i=new zn),o(j,M,n,r,i)}}if(!E)return!1;return i||(i=new zn),function(e,t,n,r,o,i){var a=1&n,s=Go(e),u=s.length,l=Go(t).length;if(u!=l&&!a)return!1;var c=u;for(;c--;){var f=s[c];if(!(a?f in t:ke.call(t,f)))return!1}var d=i.get(e),p=i.get(t);if(d&&p)return d==t&&p==e;var h=!0;i.set(e,t),i.set(t,e);var v=a;for(;++c<u;){f=s[c];var g=e[f],m=t[f];if(r)var y=a?r(m,g,f,t,e,i):r(g,m,f,e,t,i);if(!(void 0===y?g===m||o(g,m,n,r,i):y)){h=!1;break}v||(v="constructor"==f)}if(h&&!v){var b=e.constructor,w=t.constructor;b==w||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof w&&w instanceof w||(h=!1)}return i.delete(e),i.delete(t),h}(e,t,n,r,o,i)}(e,t,n,r,_r,o))}function xr(e,t,n,r){var o=n.length,i=o,a=!r;if(null==e)return!i;for(e=he(e);o--;){var s=n[o];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<i;){var u=(s=n[o])[0],l=e[u],c=s[1];if(a&&s[2]){if(void 0===l&&!(u in e))return!1}else{var f=new zn;if(r)var d=r(l,c,u,e,t,f);if(!(void 0===d?_r(c,l,3,r,f):d))return!1}}return!0}function kr(e){return!(!Va(e)||(t=e,Oe&&Oe in t))&&(Ha(e)?je:oe).test(Ti(e));var t}function Cr(e){return"function"==typeof e?e:null==e?Gs:"object"==typeof e?Ra(e)?Mr(e[0],e[1]):jr(e):nu(e)}function Or(e){if(!pi(e))return an(e);var t=[];for(var n in he(e))ke.call(e,n)&&"constructor"!=n&&t.push(n);return t}function Er(e){if(!Va(e))return function(e){var t=[];if(null!=e)for(var n in he(e))t.push(n);return t}(e);var t=pi(e),n=[];for(var r in e)("constructor"!=r||!t&&ke.call(e,r))&&n.push(r);return n}function Sr(e,t){return e<t}function Tr(e,t){var n=-1,r=Ia(e)?G(e.length):[];return tr(e,(function(e,o,i){r[++n]=t(e,o,i)})),r}function jr(e){var t=ei(e);return 1==t.length&&t[0][2]?vi(t[0][0],t[0][1]):function(n){return n===e||xr(n,e,t)}}function Mr(e,t){return ci(e)&&hi(t)?vi(Si(e),t):function(n){var r=gs(n,e);return void 0===r&&r===t?ms(n,e):_r(t,r,3)}}function Lr(e,t,n,r,o){e!==t&&sr(t,(function(i,a){if(o||(o=new zn),Va(i))!function(e,t,n,r,o,i,a){var s=bi(e,n),u=bi(t,n),l=a.get(u);if(l)return void Wn(e,n,l);var c=i?i(s,u,n+"",e,t,a):void 0,f=void 0===c;if(f){var d=Ra(u),p=!d&&za(u),h=!d&&!p&&Ja(u);c=u,d||p||h?Ra(s)?c=s:Na(s)?c=bo(s):p?(f=!1,c=po(u,!0)):h?(f=!1,c=vo(u,!0)):c=[]:$a(u)||Pa(u)?(c=s,Pa(s)?c=ss(s):Va(s)&&!Ha(s)||(c=ai(u))):f=!1}f&&(a.set(u,c),o(c,u,r,i,a),a.delete(u));Wn(e,n,c)}(e,t,a,n,Lr,r,o);else{var s=r?r(bi(e,a),i,a+"",e,t,o):void 0;void 0===s&&(s=i),Wn(e,a,s)}}),xs)}function Ar(e,t){var n=e.length;if(n)return ui(t+=t<0?n:0,n)?e[t]:void 0}function Pr(e,t,n){t=t.length?ft(t,(function(e){return Ra(e)?function(t){return dr(t,1===e.length?e[0]:e)}:e})):[Gs];var r=-1;return t=ft(t,jt(Qo())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(Tr(e,(function(e,n,o){return{criteria:ft(t,(function(t){return t(e)})),index:++r,value:e}})),(function(e,t){return function(e,t,n){var r=-1,o=e.criteria,i=t.criteria,a=o.length,s=n.length;for(;++r<a;){var u=go(o[r],i[r]);if(u){if(r>=s)return u;var l=n[r];return u*("desc"==l?-1:1)}}return e.index-t.index}(e,t,n)}))}function Rr(e,t,n){for(var r=-1,o=t.length,i={};++r<o;){var a=t[r],s=dr(e,a);n(s,a)&&Ur(i,uo(a,e),s)}return i}function Dr(e,t,n,r){var o=r?wt:bt,i=-1,a=t.length,s=e;for(e===t&&(t=bo(t)),n&&(s=ft(e,jt(n)));++i<a;)for(var u=0,l=t[i],c=n?n(l):l;(u=o(s,c,u,r))>-1;)s!==e&&Ke.call(s,u,1),Ke.call(e,u,1);return e}function Ir(e,t){for(var n=e?t.length:0,r=n-1;n--;){var o=t[n];if(n==r||o!==i){var i=o;ui(o)?Ke.call(e,o,1):eo(e,o)}}return e}function Nr(e,t){return e+en(fn()*(t-e+1))}function zr(e,t){var n="";if(!e||t<1||t>9007199254740991)return n;do{t%2&&(n+=e),(t=en(t/2))&&(e+=e)}while(t);return n}function Fr(e,t){return xi(gi(e,t,Gs),e+"")}function Br(e){return Bn(Ms(e))}function Hr(e,t){var n=Ms(e);return Oi(n,Zn(t,0,n.length))}function Ur(e,t,n,r){if(!Va(e))return e;for(var o=-1,i=(t=uo(t,e)).length,a=i-1,s=e;null!=s&&++o<i;){var u=Si(t[o]),l=n;if("__proto__"===u||"constructor"===u||"prototype"===u)return e;if(o!=a){var c=s[u];void 0===(l=r?r(c,u,s):void 0)&&(l=Va(c)?c:ui(t[o+1])?[]:{})}Vn(s,u,l),s=s[u]}return e}var Wr=bn?function(e,t){return bn.set(e,t),e}:Gs,Vr=Kt?function(e,t){return Kt(e,"toString",{configurable:!0,enumerable:!1,value:Vs(t),writable:!0})}:Gs;function qr(e){return Oi(Ms(e))}function Yr(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=G(o);++r<o;)i[r]=e[r+t];return i}function Gr(e,t){var n;return tr(e,(function(e,r,o){return!(n=t(e,r,o))})),!!n}function $r(e,t,n){var r=0,o=null==e?r:e.length;if("number"==typeof t&&t==t&&o<=2147483647){for(;r<o;){var i=r+o>>>1,a=e[i];null!==a&&!Qa(a)&&(n?a<=t:a<t)?r=i+1:o=i}return o}return Kr(e,t,Gs,n)}function Kr(e,t,n,r){var o=0,i=null==e?0:e.length;if(0===i)return 0;for(var a=(t=n(t))!=t,s=null===t,u=Qa(t),l=void 0===t;o<i;){var c=en((o+i)/2),f=n(e[c]),d=void 0!==f,p=null===f,h=f==f,v=Qa(f);if(a)var g=r||h;else g=l?h&&(r||d):s?h&&d&&(r||!p):u?h&&d&&!p&&(r||!v):!p&&!v&&(r?f<=t:f<t);g?o=c+1:i=c}return un(i,4294967294)}function Zr(e,t){for(var n=-1,r=e.length,o=0,i=[];++n<r;){var a=e[n],s=t?t(a):a;if(!n||!Ma(s,u)){var u=s;i[o++]=0===a?0:a}}return i}function Xr(e){return"number"==typeof e?e:Qa(e)?NaN:+e}function Qr(e){if("string"==typeof e)return e;if(Ra(e))return ft(e,Qr)+"";if(Qa(e))return Tn?Tn.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Jr(e,t,n){var r=-1,o=lt,i=e.length,a=!0,s=[],u=s;if(n)a=!1,o=ct;else if(i>=200){var l=t?null:Fo(e);if(l)return Ut(l);a=!1,o=Lt,u=new Nn}else u=t?[]:s;e:for(;++r<i;){var c=e[r],f=t?t(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var d=u.length;d--;)if(u[d]===f)continue e;t&&u.push(f),s.push(c)}else o(u,f,n)||(u!==s&&u.push(f),s.push(c))}return s}function eo(e,t){return null==(e=mi(e,t=uo(t,e)))||delete e[Si(Bi(t))]}function to(e,t,n,r){return Ur(e,t,n(dr(e,t)),r)}function no(e,t,n,r){for(var o=e.length,i=r?o:-1;(r?i--:++i<o)&&t(e[i],i,e););return n?Yr(e,r?0:i,r?i+1:o):Yr(e,r?i+1:0,r?o:i)}function ro(e,t){var n=e;return n instanceof Pn&&(n=n.value()),pt(t,(function(e,t){return t.func.apply(t.thisArg,dt([e],t.args))}),n)}function oo(e,t,n){var r=e.length;if(r<2)return r?Jr(e[0]):[];for(var o=-1,i=G(r);++o<r;)for(var a=e[o],s=-1;++s<r;)s!=o&&(i[o]=er(i[o]||a,e[s],t,n));return Jr(ar(i,1),t,n)}function io(e,t,n){for(var r=-1,o=e.length,i=t.length,a={};++r<o;){var s=r<i?t[r]:void 0;n(a,e[r],s)}return a}function ao(e){return Na(e)?e:[]}function so(e){return"function"==typeof e?e:Gs}function uo(e,t){return Ra(e)?e:ci(e,t)?[e]:Ei(us(e))}var lo=Fr;function co(e,t,n){var r=e.length;return n=void 0===n?r:n,!t&&n>=r?e:Yr(e,t,n)}var fo=Zt||function(e){return qe.clearTimeout(e)};function po(e,t){if(t)return e.slice();var n=e.length,r=We?We(n):new e.constructor(n);return e.copy(r),r}function ho(e){var t=new e.constructor(e.byteLength);return new Be(t).set(new Be(e)),t}function vo(e,t){var n=t?ho(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function go(e,t){if(e!==t){var n=void 0!==e,r=null===e,o=e==e,i=Qa(e),a=void 0!==t,s=null===t,u=t==t,l=Qa(t);if(!s&&!l&&!i&&e>t||i&&a&&u&&!s&&!l||r&&a&&u||!n&&u||!o)return 1;if(!r&&!i&&!l&&e<t||l&&n&&o&&!r&&!i||s&&n&&o||!a&&o||!u)return-1}return 0}function mo(e,t,n,r){for(var o=-1,i=e.length,a=n.length,s=-1,u=t.length,l=sn(i-a,0),c=G(u+l),f=!r;++s<u;)c[s]=t[s];for(;++o<a;)(f||o<i)&&(c[n[o]]=e[o]);for(;l--;)c[s++]=e[o++];return c}function yo(e,t,n,r){for(var o=-1,i=e.length,a=-1,s=n.length,u=-1,l=t.length,c=sn(i-s,0),f=G(c+l),d=!r;++o<c;)f[o]=e[o];for(var p=o;++u<l;)f[p+u]=t[u];for(;++a<s;)(d||o<i)&&(f[p+n[a]]=e[o++]);return f}function bo(e,t){var n=-1,r=e.length;for(t||(t=G(r));++n<r;)t[n]=e[n];return t}function wo(e,t,n,r){var o=!n;n||(n={});for(var i=-1,a=t.length;++i<a;){var s=t[i],u=r?r(n[s],e[s],s,n,e):void 0;void 0===u&&(u=e[s]),o?$n(n,s,u):Vn(n,s,u)}return n}function _o(e,t){return function(n,r){var o=Ra(n)?ot:Yn,i=t?t():{};return o(n,e,Qo(r,2),i)}}function xo(e){return Fr((function(t,n){var r=-1,o=n.length,i=o>1?n[o-1]:void 0,a=o>2?n[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,a&&li(n[0],n[1],a)&&(i=o<3?void 0:i,o=1),t=he(t);++r<o;){var s=n[r];s&&e(t,s,r,i)}return t}))}function ko(e,t){return function(n,r){if(null==n)return n;if(!Ia(n))return e(n,r);for(var o=n.length,i=t?o:-1,a=he(n);(t?i--:++i<o)&&!1!==r(a[i],i,a););return n}}function Co(e){return function(t,n,r){for(var o=-1,i=he(t),a=r(t),s=a.length;s--;){var u=a[e?s:++o];if(!1===n(i[u],u,i))break}return t}}function Oo(e){return function(t){var n=zt(t=us(t))?qt(t):void 0,r=n?n[0]:t.charAt(0),o=n?co(n,1).join(""):t.slice(1);return r[e]()+o}}function Eo(e){return function(t){return pt(Hs(Ps(t).replace(Me,"")),e,"")}}function So(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=Mn(e.prototype),r=e.apply(n,t);return Va(r)?r:n}}function To(e){return function(t,n,r){var o=he(t);if(!Ia(t)){var i=Qo(n,3);t=_s(t),n=function(e){return i(o[e],e,o)}}var a=e(t,n,r);return a>-1?o[i?t[a]:a]:void 0}}function jo(e){return Yo((function(t){var n=t.length,o=n,i=An.prototype.thru;for(e&&t.reverse();o--;){var a=t[o];if("function"!=typeof a)throw new me(r);if(i&&!s&&"wrapper"==Zo(a))var s=new An([],!0)}for(o=s?o:n;++o<n;){var u=Zo(a=t[o]),l="wrapper"==u?Ko(a):void 0;s=l&&fi(l[0])&&424==l[1]&&!l[4].length&&1==l[9]?s[Zo(l[0])].apply(s,l[3]):1==a.length&&fi(a)?s[u]():s.thru(a)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&Ra(r))return s.plant(r).value();for(var o=0,i=n?t[o].apply(this,e):r;++o<n;)i=t[o].call(this,i);return i}}))}function Mo(e,t,n,r,o,i,a,s,u,l){var c=128&t,f=1&t,d=2&t,p=24&t,h=512&t,v=d?void 0:So(e);return function g(){for(var m=arguments.length,y=G(m),b=m;b--;)y[b]=arguments[b];if(p)var w=Xo(g),_=Rt(y,w);if(r&&(y=mo(y,r,o,p)),i&&(y=yo(y,i,a,p)),m-=_,p&&m<l){var x=Ht(y,w);return No(e,t,Mo,g.placeholder,n,y,x,s,u,l-m)}var k=f?n:this,C=d?k[e]:e;return m=y.length,s?y=yi(y,s):h&&m>1&&y.reverse(),c&&u<m&&(y.length=u),this&&this!==qe&&this instanceof g&&(C=v||So(C)),C.apply(k,y)}}function Lo(e,t){return function(n,r){return function(e,t,n,r){return lr(e,(function(e,o,i){t(r,n(e),o,i)})),r}(n,e,t(r),{})}}function Ao(e,t){return function(n,r){var o;if(void 0===n&&void 0===r)return t;if(void 0!==n&&(o=n),void 0!==r){if(void 0===o)return r;"string"==typeof n||"string"==typeof r?(n=Qr(n),r=Qr(r)):(n=Xr(n),r=Xr(r)),o=e(n,r)}return o}}function Po(e){return Yo((function(t){return t=ft(t,jt(Qo())),Fr((function(n){var r=this;return e(t,(function(e){return rt(e,r,n)}))}))}))}function Ro(e,t){var n=(t=void 0===t?" ":Qr(t)).length;if(n<2)return n?zr(t,e):t;var r=zr(t,Jt(e/Vt(t)));return zt(t)?co(qt(r),0,e).join(""):r.slice(0,e)}function Do(e){return function(t,n,r){return r&&"number"!=typeof r&&li(t,n,r)&&(n=r=void 0),t=rs(t),void 0===n?(n=t,t=0):n=rs(n),function(e,t,n,r){for(var o=-1,i=sn(Jt((t-e)/(n||1)),0),a=G(i);i--;)a[r?i:++o]=e,e+=n;return a}(t,n,r=void 0===r?t<n?1:-1:rs(r),e)}}function Io(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=as(t),n=as(n)),e(t,n)}}function No(e,t,n,r,o,i,a,s,u,l){var c=8&t;t|=c?32:64,4&(t&=~(c?64:32))||(t&=-4);var f=[e,t,o,c?i:void 0,c?a:void 0,c?void 0:i,c?void 0:a,s,u,l],d=n.apply(void 0,f);return fi(e)&&wi(d,f),d.placeholder=r,ki(d,e,t)}function zo(e){var t=pe[e];return function(e,n){if(e=as(e),(n=null==n?0:un(os(n),292))&&rn(e)){var r=(us(e)+"e").split("e");return+((r=(us(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var Fo=gn&&1/Ut(new gn([,-0]))[1]==1/0?function(e){return new gn(e)}:Qs;function Bo(e){return function(t){var n=oi(t);return n==p?Ft(t):n==m?Wt(t):function(e,t){return ft(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function Ho(e,t,n,i,a,s,u,l){var c=2&t;if(!c&&"function"!=typeof e)throw new me(r);var f=i?i.length:0;if(f||(t&=-97,i=a=void 0),u=void 0===u?u:sn(os(u),0),l=void 0===l?l:os(l),f-=a?a.length:0,64&t){var d=i,p=a;i=a=void 0}var h=c?void 0:Ko(e),v=[e,t,n,i,a,d,p,s,u,l];if(h&&function(e,t){var n=e[1],r=t[1],i=n|r,a=i<131,s=128==r&&8==n||128==r&&256==n&&e[7].length<=t[8]||384==r&&t[7].length<=t[8]&&8==n;if(!a&&!s)return e;1&r&&(e[2]=t[2],i|=1&n?0:4);var u=t[3];if(u){var l=e[3];e[3]=l?mo(l,u,t[4]):u,e[4]=l?Ht(e[3],o):t[4]}(u=t[5])&&(l=e[5],e[5]=l?yo(l,u,t[6]):u,e[6]=l?Ht(e[5],o):t[6]);(u=t[7])&&(e[7]=u);128&r&&(e[8]=null==e[8]?t[8]:un(e[8],t[8]));null==e[9]&&(e[9]=t[9]);e[0]=t[0],e[1]=i}(v,h),e=v[0],t=v[1],n=v[2],i=v[3],a=v[4],!(l=v[9]=void 0===v[9]?c?0:e.length:sn(v[9]-f,0))&&24&t&&(t&=-25),t&&1!=t)g=8==t||16==t?function(e,t,n){var r=So(e);return function o(){for(var i=arguments.length,a=G(i),s=i,u=Xo(o);s--;)a[s]=arguments[s];var l=i<3&&a[0]!==u&&a[i-1]!==u?[]:Ht(a,u);if((i-=l.length)<n)return No(e,t,Mo,o.placeholder,void 0,a,l,void 0,void 0,n-i);var c=this&&this!==qe&&this instanceof o?r:e;return rt(c,this,a)}}(e,t,l):32!=t&&33!=t||a.length?Mo.apply(void 0,v):function(e,t,n,r){var o=1&t,i=So(e);return function t(){for(var a=-1,s=arguments.length,u=-1,l=r.length,c=G(l+s),f=this&&this!==qe&&this instanceof t?i:e;++u<l;)c[u]=r[u];for(;s--;)c[u++]=arguments[++a];return rt(f,o?n:this,c)}}(e,t,n,i);else var g=function(e,t,n){var r=1&t,o=So(e);return function t(){var i=this&&this!==qe&&this instanceof t?o:e;return i.apply(r?n:this,arguments)}}(e,t,n);return ki((h?Wr:wi)(g,v),e,t)}function Uo(e,t,n,r){return void 0===e||Ma(e,we[n])&&!ke.call(r,n)?t:e}function Wo(e,t,n,r,o,i){return Va(e)&&Va(t)&&(i.set(t,e),Lr(e,t,void 0,Wo,i),i.delete(t)),e}function Vo(e){return $a(e)?void 0:e}function qo(e,t,n,r,o,i){var a=1&n,s=e.length,u=t.length;if(s!=u&&!(a&&u>s))return!1;var l=i.get(e),c=i.get(t);if(l&&c)return l==t&&c==e;var f=-1,d=!0,p=2&n?new Nn:void 0;for(i.set(e,t),i.set(t,e);++f<s;){var h=e[f],v=t[f];if(r)var g=a?r(v,h,f,t,e,i):r(h,v,f,e,t,i);if(void 0!==g){if(g)continue;d=!1;break}if(p){if(!vt(t,(function(e,t){if(!Lt(p,t)&&(h===e||o(h,e,n,r,i)))return p.push(t)}))){d=!1;break}}else if(h!==v&&!o(h,v,n,r,i)){d=!1;break}}return i.delete(e),i.delete(t),d}function Yo(e){return xi(gi(e,void 0,Di),e+"")}function Go(e){return pr(e,_s,ni)}function $o(e){return pr(e,xs,ri)}var Ko=bn?function(e){return bn.get(e)}:Qs;function Zo(e){for(var t=e.name+"",n=wn[t],r=ke.call(wn,t)?n.length:0;r--;){var o=n[r],i=o.func;if(null==i||i==e)return o.name}return t}function Xo(e){return(ke.call(jn,"placeholder")?jn:e).placeholder}function Qo(){var e=jn.iteratee||$s;return e=e===$s?Cr:e,arguments.length?e(arguments[0],arguments[1]):e}function Jo(e,t){var n,r,o=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof t?"string":"hash"]:o.map}function ei(e){for(var t=_s(e),n=t.length;n--;){var r=t[n],o=e[r];t[n]=[r,o,hi(o)]}return t}function ti(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return kr(n)?n:void 0}var ni=tn?function(e){return null==e?[]:(e=he(e),ut(tn(e),(function(t){return Ge.call(e,t)})))}:iu,ri=tn?function(e){for(var t=[];e;)dt(t,ni(e)),e=Ve(e);return t}:iu,oi=hr;function ii(e,t,n){for(var r=-1,o=(t=uo(t,e)).length,i=!1;++r<o;){var a=Si(t[r]);if(!(i=null!=e&&n(e,a)))break;e=e[a]}return i||++r!=o?i:!!(o=null==e?0:e.length)&&Wa(o)&&ui(a,o)&&(Ra(e)||Pa(e))}function ai(e){return"function"!=typeof e.constructor||pi(e)?{}:Mn(Ve(e))}function si(e){return Ra(e)||Pa(e)||!!(Ze&&e&&e[Ze])}function ui(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&ae.test(e))&&e>-1&&e%1==0&&e<t}function li(e,t,n){if(!Va(n))return!1;var r=typeof t;return!!("number"==r?Ia(n)&&ui(t,n.length):"string"==r&&t in n)&&Ma(n[t],e)}function ci(e,t){if(Ra(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Qa(e))||(U.test(e)||!H.test(e)||null!=t&&e in he(t))}function fi(e){var t=Zo(e),n=jn[t];if("function"!=typeof n||!(t in Pn.prototype))return!1;if(e===n)return!0;var r=Ko(n);return!!r&&e===r[0]}(pn&&oi(new pn(new ArrayBuffer(1)))!=x||hn&&oi(new hn)!=p||vn&&"[object Promise]"!=oi(vn.resolve())||gn&&oi(new gn)!=m||mn&&oi(new mn)!=w)&&(oi=function(e){var t=hr(e),n=t==v?e.constructor:void 0,r=n?Ti(n):"";if(r)switch(r){case _n:return x;case xn:return p;case kn:return"[object Promise]";case Cn:return m;case On:return w}return t});var di=_e?Ha:au;function pi(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||we)}function hi(e){return e==e&&!Va(e)}function vi(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in he(n)))}}function gi(e,t,n){return t=sn(void 0===t?e.length-1:t,0),function(){for(var r=arguments,o=-1,i=sn(r.length-t,0),a=G(i);++o<i;)a[o]=r[t+o];o=-1;for(var s=G(t+1);++o<t;)s[o]=r[o];return s[t]=n(a),rt(e,this,s)}}function mi(e,t){return t.length<2?e:dr(e,Yr(t,0,-1))}function yi(e,t){for(var n=e.length,r=un(t.length,n),o=bo(e);r--;){var i=t[r];e[r]=ui(i,n)?o[i]:void 0}return e}function bi(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var wi=Ci(Wr),_i=Qt||function(e,t){return qe.setTimeout(e,t)},xi=Ci(Vr);function ki(e,t,n){var r=t+"";return xi(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace($,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return it(i,(function(n){var r="_."+n[0];t&n[1]&&!lt(e,r)&&e.push(r)})),e.sort()}(function(e){var t=e.match(K);return t?t[1].split(Z):[]}(r),n)))}function Ci(e){var t=0,n=0;return function(){var r=ln(),o=16-(r-n);if(n=r,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}function Oi(e,t){var n=-1,r=e.length,o=r-1;for(t=void 0===t?r:t;++n<t;){var i=Nr(n,o),a=e[i];e[i]=e[n],e[n]=a}return e.length=t,e}var Ei=function(e){var t=Ca(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(W,(function(e,n,r,o){t.push(r?o.replace(J,"$1"):n||e)})),t}));function Si(e){if("string"==typeof e||Qa(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Ti(e){if(null!=e){try{return xe.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function ji(e){if(e instanceof Pn)return e.clone();var t=new An(e.__wrapped__,e.__chain__);return t.__actions__=bo(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var Mi=Fr((function(e,t){return Na(e)?er(e,ar(t,1,Na,!0)):[]})),Li=Fr((function(e,t){var n=Bi(t);return Na(n)&&(n=void 0),Na(e)?er(e,ar(t,1,Na,!0),Qo(n,2)):[]})),Ai=Fr((function(e,t){var n=Bi(t);return Na(n)&&(n=void 0),Na(e)?er(e,ar(t,1,Na,!0),void 0,n):[]}));function Pi(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:os(n);return o<0&&(o=sn(r+o,0)),yt(e,Qo(t,3),o)}function Ri(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r-1;return void 0!==n&&(o=os(n),o=n<0?sn(r+o,0):un(o,r-1)),yt(e,Qo(t,3),o,!0)}function Di(e){return(null==e?0:e.length)?ar(e,1):[]}function Ii(e){return e&&e.length?e[0]:void 0}var Ni=Fr((function(e){var t=ft(e,ao);return t.length&&t[0]===e[0]?yr(t):[]})),zi=Fr((function(e){var t=Bi(e),n=ft(e,ao);return t===Bi(n)?t=void 0:n.pop(),n.length&&n[0]===e[0]?yr(n,Qo(t,2)):[]})),Fi=Fr((function(e){var t=Bi(e),n=ft(e,ao);return(t="function"==typeof t?t:void 0)&&n.pop(),n.length&&n[0]===e[0]?yr(n,void 0,t):[]}));function Bi(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}var Hi=Fr(Ui);function Ui(e,t){return e&&e.length&&t&&t.length?Dr(e,t):e}var Wi=Yo((function(e,t){var n=null==e?0:e.length,r=Kn(e,t);return Ir(e,ft(t,(function(e){return ui(e,n)?+e:e})).sort(go)),r}));function Vi(e){return null==e?e:dn.call(e)}var qi=Fr((function(e){return Jr(ar(e,1,Na,!0))})),Yi=Fr((function(e){var t=Bi(e);return Na(t)&&(t=void 0),Jr(ar(e,1,Na,!0),Qo(t,2))})),Gi=Fr((function(e){var t=Bi(e);return t="function"==typeof t?t:void 0,Jr(ar(e,1,Na,!0),void 0,t)}));function $i(e){if(!e||!e.length)return[];var t=0;return e=ut(e,(function(e){if(Na(e))return t=sn(e.length,t),!0})),St(t,(function(t){return ft(e,kt(t))}))}function Ki(e,t){if(!e||!e.length)return[];var n=$i(e);return null==t?n:ft(n,(function(e){return rt(t,void 0,e)}))}var Zi=Fr((function(e,t){return Na(e)?er(e,t):[]})),Xi=Fr((function(e){return oo(ut(e,Na))})),Qi=Fr((function(e){var t=Bi(e);return Na(t)&&(t=void 0),oo(ut(e,Na),Qo(t,2))})),Ji=Fr((function(e){var t=Bi(e);return t="function"==typeof t?t:void 0,oo(ut(e,Na),void 0,t)})),ea=Fr($i);var ta=Fr((function(e){var t=e.length,n=t>1?e[t-1]:void 0;return n="function"==typeof n?(e.pop(),n):void 0,Ki(e,n)}));function na(e){var t=jn(e);return t.__chain__=!0,t}function ra(e,t){return t(e)}var oa=Yo((function(e){var t=e.length,n=t?e[0]:0,r=this.__wrapped__,o=function(t){return Kn(t,e)};return!(t>1||this.__actions__.length)&&r instanceof Pn&&ui(n)?((r=r.slice(n,+n+(t?1:0))).__actions__.push({func:ra,args:[o],thisArg:void 0}),new An(r,this.__chain__).thru((function(e){return t&&!e.length&&e.push(void 0),e}))):this.thru(o)}));var ia=_o((function(e,t,n){ke.call(e,n)?++e[n]:$n(e,n,1)}));var aa=To(Pi),sa=To(Ri);function ua(e,t){return(Ra(e)?it:tr)(e,Qo(t,3))}function la(e,t){return(Ra(e)?at:nr)(e,Qo(t,3))}var ca=_o((function(e,t,n){ke.call(e,n)?e[n].push(t):$n(e,n,[t])}));var fa=Fr((function(e,t,n){var r=-1,o="function"==typeof t,i=Ia(e)?G(e.length):[];return tr(e,(function(e){i[++r]=o?rt(t,e,n):br(e,t,n)})),i})),da=_o((function(e,t,n){$n(e,n,t)}));function pa(e,t){return(Ra(e)?ft:Tr)(e,Qo(t,3))}var ha=_o((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));var va=Fr((function(e,t){if(null==e)return[];var n=t.length;return n>1&&li(e,t[0],t[1])?t=[]:n>2&&li(t[0],t[1],t[2])&&(t=[t[0]]),Pr(e,ar(t,1),[])})),ga=Xt||function(){return qe.Date.now()};function ma(e,t,n){return t=n?void 0:t,Ho(e,128,void 0,void 0,void 0,void 0,t=e&&null==t?e.length:t)}function ya(e,t){var n;if("function"!=typeof t)throw new me(r);return e=os(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=void 0),n}}var ba=Fr((function(e,t,n){var r=1;if(n.length){var o=Ht(n,Xo(ba));r|=32}return Ho(e,r,t,n,o)})),wa=Fr((function(e,t,n){var r=3;if(n.length){var o=Ht(n,Xo(wa));r|=32}return Ho(t,r,e,n,o)}));function _a(e,t,n){var o,i,a,s,u,l,c=0,f=!1,d=!1,p=!0;if("function"!=typeof e)throw new me(r);function h(t){var n=o,r=i;return o=i=void 0,c=t,s=e.apply(r,n)}function v(e){return c=e,u=_i(m,t),f?h(e):s}function g(e){var n=e-l;return void 0===l||n>=t||n<0||d&&e-c>=a}function m(){var e=ga();if(g(e))return y(e);u=_i(m,function(e){var n=t-(e-l);return d?un(n,a-(e-c)):n}(e))}function y(e){return u=void 0,p&&o?h(e):(o=i=void 0,s)}function b(){var e=ga(),n=g(e);if(o=arguments,i=this,l=e,n){if(void 0===u)return v(l);if(d)return fo(u),u=_i(m,t),h(l)}return void 0===u&&(u=_i(m,t)),s}return t=as(t)||0,Va(n)&&(f=!!n.leading,a=(d="maxWait"in n)?sn(as(n.maxWait)||0,t):a,p="trailing"in n?!!n.trailing:p),b.cancel=function(){void 0!==u&&fo(u),c=0,o=l=i=u=void 0},b.flush=function(){return void 0===u?s:y(ga())},b}var xa=Fr((function(e,t){return Jn(e,1,t)})),ka=Fr((function(e,t,n){return Jn(e,as(t)||0,n)}));function Ca(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new me(r);var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(Ca.Cache||In),n}function Oa(e){if("function"!=typeof e)throw new me(r);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}Ca.Cache=In;var Ea=lo((function(e,t){var n=(t=1==t.length&&Ra(t[0])?ft(t[0],jt(Qo())):ft(ar(t,1),jt(Qo()))).length;return Fr((function(r){for(var o=-1,i=un(r.length,n);++o<i;)r[o]=t[o].call(this,r[o]);return rt(e,this,r)}))})),Sa=Fr((function(e,t){return Ho(e,32,void 0,t,Ht(t,Xo(Sa)))})),Ta=Fr((function(e,t){return Ho(e,64,void 0,t,Ht(t,Xo(Ta)))})),ja=Yo((function(e,t){return Ho(e,256,void 0,void 0,void 0,t)}));function Ma(e,t){return e===t||e!=e&&t!=t}var La=Io(vr),Aa=Io((function(e,t){return e>=t})),Pa=wr(function(){return arguments}())?wr:function(e){return qa(e)&&ke.call(e,"callee")&&!Ge.call(e,"callee")},Ra=G.isArray,Da=Xe?jt(Xe):function(e){return qa(e)&&hr(e)==_};function Ia(e){return null!=e&&Wa(e.length)&&!Ha(e)}function Na(e){return qa(e)&&Ia(e)}var za=nn||au,Fa=Qe?jt(Qe):function(e){return qa(e)&&hr(e)==l};function Ba(e){if(!qa(e))return!1;var t=hr(e);return t==c||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!$a(e)}function Ha(e){if(!Va(e))return!1;var t=hr(e);return t==f||t==d||"[object AsyncFunction]"==t||"[object Proxy]"==t}function Ua(e){return"number"==typeof e&&e==os(e)}function Wa(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}function Va(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function qa(e){return null!=e&&"object"==typeof e}var Ya=Je?jt(Je):function(e){return qa(e)&&oi(e)==p};function Ga(e){return"number"==typeof e||qa(e)&&hr(e)==h}function $a(e){if(!qa(e)||hr(e)!=v)return!1;var t=Ve(e);if(null===t)return!0;var n=ke.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&xe.call(n)==Se}var Ka=et?jt(et):function(e){return qa(e)&&hr(e)==g};var Za=tt?jt(tt):function(e){return qa(e)&&oi(e)==m};function Xa(e){return"string"==typeof e||!Ra(e)&&qa(e)&&hr(e)==y}function Qa(e){return"symbol"==typeof e||qa(e)&&hr(e)==b}var Ja=nt?jt(nt):function(e){return qa(e)&&Wa(e.length)&&!!ze[hr(e)]};var es=Io(Sr),ts=Io((function(e,t){return e<=t}));function ns(e){if(!e)return[];if(Ia(e))return Xa(e)?qt(e):bo(e);if(gt&&e[gt])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[gt]());var t=oi(e);return(t==p?Ft:t==m?Ut:Ms)(e)}function rs(e){return e?(e=as(e))===1/0||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}function os(e){var t=rs(e),n=t%1;return t==t?n?t-n:t:0}function is(e){return e?Zn(os(e),0,4294967295):0}function as(e){if("number"==typeof e)return e;if(Qa(e))return NaN;if(Va(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=Va(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=Tt(e);var n=re.test(e);return n||ie.test(e)?Ue(e.slice(2),n?2:8):ne.test(e)?NaN:+e}function ss(e){return wo(e,xs(e))}function us(e){return null==e?"":Qr(e)}var ls=xo((function(e,t){if(pi(t)||Ia(t))wo(t,_s(t),e);else for(var n in t)ke.call(t,n)&&Vn(e,n,t[n])})),cs=xo((function(e,t){wo(t,xs(t),e)})),fs=xo((function(e,t,n,r){wo(t,xs(t),e,r)})),ds=xo((function(e,t,n,r){wo(t,_s(t),e,r)})),ps=Yo(Kn);var hs=Fr((function(e,t){e=he(e);var n=-1,r=t.length,o=r>2?t[2]:void 0;for(o&&li(t[0],t[1],o)&&(r=1);++n<r;)for(var i=t[n],a=xs(i),s=-1,u=a.length;++s<u;){var l=a[s],c=e[l];(void 0===c||Ma(c,we[l])&&!ke.call(e,l))&&(e[l]=i[l])}return e})),vs=Fr((function(e){return e.push(void 0,Wo),rt(Cs,void 0,e)}));function gs(e,t,n){var r=null==e?void 0:dr(e,t);return void 0===r?n:r}function ms(e,t){return null!=e&&ii(e,t,mr)}var ys=Lo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Ee.call(t)),e[t]=n}),Vs(Gs)),bs=Lo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Ee.call(t)),ke.call(e,t)?e[t].push(n):e[t]=[n]}),Qo),ws=Fr(br);function _s(e){return Ia(e)?Fn(e):Or(e)}function xs(e){return Ia(e)?Fn(e,!0):Er(e)}var ks=xo((function(e,t,n){Lr(e,t,n)})),Cs=xo((function(e,t,n,r){Lr(e,t,n,r)})),Os=Yo((function(e,t){var n={};if(null==e)return n;var r=!1;t=ft(t,(function(t){return t=uo(t,e),r||(r=t.length>1),t})),wo(e,$o(e),n),r&&(n=Xn(n,7,Vo));for(var o=t.length;o--;)eo(n,t[o]);return n}));var Es=Yo((function(e,t){return null==e?{}:function(e,t){return Rr(e,t,(function(t,n){return ms(e,n)}))}(e,t)}));function Ss(e,t){if(null==e)return{};var n=ft($o(e),(function(e){return[e]}));return t=Qo(t),Rr(e,n,(function(e,n){return t(e,n[0])}))}var Ts=Bo(_s),js=Bo(xs);function Ms(e){return null==e?[]:Mt(e,_s(e))}var Ls=Eo((function(e,t,n){return t=t.toLowerCase(),e+(n?As(t):t)}));function As(e){return Bs(us(e).toLowerCase())}function Ps(e){return(e=us(e))&&e.replace(se,Dt).replace(Le,"")}var Rs=Eo((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),Ds=Eo((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),Is=Oo("toLowerCase");var Ns=Eo((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));var zs=Eo((function(e,t,n){return e+(n?" ":"")+Bs(t)}));var Fs=Eo((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),Bs=Oo("toUpperCase");function Hs(e,t,n){return e=us(e),void 0===(t=n?void 0:t)?function(e){return De.test(e)}(e)?function(e){return e.match(Pe)||[]}(e):function(e){return e.match(X)||[]}(e):e.match(t)||[]}var Us=Fr((function(e,t){try{return rt(e,void 0,t)}catch(e){return Ba(e)?e:new fe(e)}})),Ws=Yo((function(e,t){return it(t,(function(t){t=Si(t),$n(e,t,ba(e[t],e))})),e}));function Vs(e){return function(){return e}}var qs=jo(),Ys=jo(!0);function Gs(e){return e}function $s(e){return Cr("function"==typeof e?e:Xn(e,1))}var Ks=Fr((function(e,t){return function(n){return br(n,e,t)}})),Zs=Fr((function(e,t){return function(n){return br(e,n,t)}}));function Xs(e,t,n){var r=_s(t),o=fr(t,r);null!=n||Va(t)&&(o.length||!r.length)||(n=t,t=e,e=this,o=fr(t,_s(t)));var i=!(Va(n)&&"chain"in n&&!n.chain),a=Ha(e);return it(o,(function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(i||t){var n=e(this.__wrapped__),o=n.__actions__=bo(this.__actions__);return o.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,dt([this.value()],arguments))})})),e}function Qs(){}var Js=Po(ft),eu=Po(st),tu=Po(vt);function nu(e){return ci(e)?kt(Si(e)):function(e){return function(t){return dr(t,e)}}(e)}var ru=Do(),ou=Do(!0);function iu(){return[]}function au(){return!1}var su=Ao((function(e,t){return e+t}),0),uu=zo("ceil"),lu=Ao((function(e,t){return e/t}),1),cu=zo("floor");var fu,du=Ao((function(e,t){return e*t}),1),pu=zo("round"),hu=Ao((function(e,t){return e-t}),0);return jn.after=function(e,t){if("function"!=typeof t)throw new me(r);return e=os(e),function(){if(--e<1)return t.apply(this,arguments)}},jn.ary=ma,jn.assign=ls,jn.assignIn=cs,jn.assignInWith=fs,jn.assignWith=ds,jn.at=ps,jn.before=ya,jn.bind=ba,jn.bindAll=Ws,jn.bindKey=wa,jn.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Ra(e)?e:[e]},jn.chain=na,jn.chunk=function(e,t,n){t=(n?li(e,t,n):void 0===t)?1:sn(os(t),0);var r=null==e?0:e.length;if(!r||t<1)return[];for(var o=0,i=0,a=G(Jt(r/t));o<r;)a[i++]=Yr(e,o,o+=t);return a},jn.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,o=[];++t<n;){var i=e[t];i&&(o[r++]=i)}return o},jn.concat=function(){var e=arguments.length;if(!e)return[];for(var t=G(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return dt(Ra(n)?bo(n):[n],ar(t,1))},jn.cond=function(e){var t=null==e?0:e.length,n=Qo();return e=t?ft(e,(function(e){if("function"!=typeof e[1])throw new me(r);return[n(e[0]),e[1]]})):[],Fr((function(n){for(var r=-1;++r<t;){var o=e[r];if(rt(o[0],this,n))return rt(o[1],this,n)}}))},jn.conforms=function(e){return function(e){var t=_s(e);return function(n){return Qn(n,e,t)}}(Xn(e,1))},jn.constant=Vs,jn.countBy=ia,jn.create=function(e,t){var n=Mn(e);return null==t?n:Gn(n,t)},jn.curry=function e(t,n,r){var o=Ho(t,8,void 0,void 0,void 0,void 0,void 0,n=r?void 0:n);return o.placeholder=e.placeholder,o},jn.curryRight=function e(t,n,r){var o=Ho(t,16,void 0,void 0,void 0,void 0,void 0,n=r?void 0:n);return o.placeholder=e.placeholder,o},jn.debounce=_a,jn.defaults=hs,jn.defaultsDeep=vs,jn.defer=xa,jn.delay=ka,jn.difference=Mi,jn.differenceBy=Li,jn.differenceWith=Ai,jn.drop=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,(t=n||void 0===t?1:os(t))<0?0:t,r):[]},jn.dropRight=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,0,(t=r-(t=n||void 0===t?1:os(t)))<0?0:t):[]},jn.dropRightWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!0,!0):[]},jn.dropWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!0):[]},jn.fill=function(e,t,n,r){var o=null==e?0:e.length;return o?(n&&"number"!=typeof n&&li(e,t,n)&&(n=0,r=o),function(e,t,n,r){var o=e.length;for((n=os(n))<0&&(n=-n>o?0:o+n),(r=void 0===r||r>o?o:os(r))<0&&(r+=o),r=n>r?0:is(r);n<r;)e[n++]=t;return e}(e,t,n,r)):[]},jn.filter=function(e,t){return(Ra(e)?ut:ir)(e,Qo(t,3))},jn.flatMap=function(e,t){return ar(pa(e,t),1)},jn.flatMapDeep=function(e,t){return ar(pa(e,t),1/0)},jn.flatMapDepth=function(e,t,n){return n=void 0===n?1:os(n),ar(pa(e,t),n)},jn.flatten=Di,jn.flattenDeep=function(e){return(null==e?0:e.length)?ar(e,1/0):[]},jn.flattenDepth=function(e,t){return(null==e?0:e.length)?ar(e,t=void 0===t?1:os(t)):[]},jn.flip=function(e){return Ho(e,512)},jn.flow=qs,jn.flowRight=Ys,jn.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var o=e[t];r[o[0]]=o[1]}return r},jn.functions=function(e){return null==e?[]:fr(e,_s(e))},jn.functionsIn=function(e){return null==e?[]:fr(e,xs(e))},jn.groupBy=ca,jn.initial=function(e){return(null==e?0:e.length)?Yr(e,0,-1):[]},jn.intersection=Ni,jn.intersectionBy=zi,jn.intersectionWith=Fi,jn.invert=ys,jn.invertBy=bs,jn.invokeMap=fa,jn.iteratee=$s,jn.keyBy=da,jn.keys=_s,jn.keysIn=xs,jn.map=pa,jn.mapKeys=function(e,t){var n={};return t=Qo(t,3),lr(e,(function(e,r,o){$n(n,t(e,r,o),e)})),n},jn.mapValues=function(e,t){var n={};return t=Qo(t,3),lr(e,(function(e,r,o){$n(n,r,t(e,r,o))})),n},jn.matches=function(e){return jr(Xn(e,1))},jn.matchesProperty=function(e,t){return Mr(e,Xn(t,1))},jn.memoize=Ca,jn.merge=ks,jn.mergeWith=Cs,jn.method=Ks,jn.methodOf=Zs,jn.mixin=Xs,jn.negate=Oa,jn.nthArg=function(e){return e=os(e),Fr((function(t){return Ar(t,e)}))},jn.omit=Os,jn.omitBy=function(e,t){return Ss(e,Oa(Qo(t)))},jn.once=function(e){return ya(2,e)},jn.orderBy=function(e,t,n,r){return null==e?[]:(Ra(t)||(t=null==t?[]:[t]),Ra(n=r?void 0:n)||(n=null==n?[]:[n]),Pr(e,t,n))},jn.over=Js,jn.overArgs=Ea,jn.overEvery=eu,jn.overSome=tu,jn.partial=Sa,jn.partialRight=Ta,jn.partition=ha,jn.pick=Es,jn.pickBy=Ss,jn.property=nu,jn.propertyOf=function(e){return function(t){return null==e?void 0:dr(e,t)}},jn.pull=Hi,jn.pullAll=Ui,jn.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?Dr(e,t,Qo(n,2)):e},jn.pullAllWith=function(e,t,n){return e&&e.length&&t&&t.length?Dr(e,t,void 0,n):e},jn.pullAt=Wi,jn.range=ru,jn.rangeRight=ou,jn.rearg=ja,jn.reject=function(e,t){return(Ra(e)?ut:ir)(e,Oa(Qo(t,3)))},jn.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,o=[],i=e.length;for(t=Qo(t,3);++r<i;){var a=e[r];t(a,r,e)&&(n.push(a),o.push(r))}return Ir(e,o),n},jn.rest=function(e,t){if("function"!=typeof e)throw new me(r);return Fr(e,t=void 0===t?t:os(t))},jn.reverse=Vi,jn.sampleSize=function(e,t,n){return t=(n?li(e,t,n):void 0===t)?1:os(t),(Ra(e)?Hn:Hr)(e,t)},jn.set=function(e,t,n){return null==e?e:Ur(e,t,n)},jn.setWith=function(e,t,n,r){return r="function"==typeof r?r:void 0,null==e?e:Ur(e,t,n,r)},jn.shuffle=function(e){return(Ra(e)?Un:qr)(e)},jn.slice=function(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&li(e,t,n)?(t=0,n=r):(t=null==t?0:os(t),n=void 0===n?r:os(n)),Yr(e,t,n)):[]},jn.sortBy=va,jn.sortedUniq=function(e){return e&&e.length?Zr(e):[]},jn.sortedUniqBy=function(e,t){return e&&e.length?Zr(e,Qo(t,2)):[]},jn.split=function(e,t,n){return n&&"number"!=typeof n&&li(e,t,n)&&(t=n=void 0),(n=void 0===n?4294967295:n>>>0)?(e=us(e))&&("string"==typeof t||null!=t&&!Ka(t))&&!(t=Qr(t))&&zt(e)?co(qt(e),0,n):e.split(t,n):[]},jn.spread=function(e,t){if("function"!=typeof e)throw new me(r);return t=null==t?0:sn(os(t),0),Fr((function(n){var r=n[t],o=co(n,0,t);return r&&dt(o,r),rt(e,this,o)}))},jn.tail=function(e){var t=null==e?0:e.length;return t?Yr(e,1,t):[]},jn.take=function(e,t,n){return e&&e.length?Yr(e,0,(t=n||void 0===t?1:os(t))<0?0:t):[]},jn.takeRight=function(e,t,n){var r=null==e?0:e.length;return r?Yr(e,(t=r-(t=n||void 0===t?1:os(t)))<0?0:t,r):[]},jn.takeRightWhile=function(e,t){return e&&e.length?no(e,Qo(t,3),!1,!0):[]},jn.takeWhile=function(e,t){return e&&e.length?no(e,Qo(t,3)):[]},jn.tap=function(e,t){return t(e),e},jn.throttle=function(e,t,n){var o=!0,i=!0;if("function"!=typeof e)throw new me(r);return Va(n)&&(o="leading"in n?!!n.leading:o,i="trailing"in n?!!n.trailing:i),_a(e,t,{leading:o,maxWait:t,trailing:i})},jn.thru=ra,jn.toArray=ns,jn.toPairs=Ts,jn.toPairsIn=js,jn.toPath=function(e){return Ra(e)?ft(e,Si):Qa(e)?[e]:bo(Ei(us(e)))},jn.toPlainObject=ss,jn.transform=function(e,t,n){var r=Ra(e),o=r||za(e)||Ja(e);if(t=Qo(t,4),null==n){var i=e&&e.constructor;n=o?r?new i:[]:Va(e)&&Ha(i)?Mn(Ve(e)):{}}return(o?it:lr)(e,(function(e,r,o){return t(n,e,r,o)})),n},jn.unary=function(e){return ma(e,1)},jn.union=qi,jn.unionBy=Yi,jn.unionWith=Gi,jn.uniq=function(e){return e&&e.length?Jr(e):[]},jn.uniqBy=function(e,t){return e&&e.length?Jr(e,Qo(t,2)):[]},jn.uniqWith=function(e,t){return t="function"==typeof t?t:void 0,e&&e.length?Jr(e,void 0,t):[]},jn.unset=function(e,t){return null==e||eo(e,t)},jn.unzip=$i,jn.unzipWith=Ki,jn.update=function(e,t,n){return null==e?e:to(e,t,so(n))},jn.updateWith=function(e,t,n,r){return r="function"==typeof r?r:void 0,null==e?e:to(e,t,so(n),r)},jn.values=Ms,jn.valuesIn=function(e){return null==e?[]:Mt(e,xs(e))},jn.without=Zi,jn.words=Hs,jn.wrap=function(e,t){return Sa(so(t),e)},jn.xor=Xi,jn.xorBy=Qi,jn.xorWith=Ji,jn.zip=ea,jn.zipObject=function(e,t){return io(e||[],t||[],Vn)},jn.zipObjectDeep=function(e,t){return io(e||[],t||[],Ur)},jn.zipWith=ta,jn.entries=Ts,jn.entriesIn=js,jn.extend=cs,jn.extendWith=fs,Xs(jn,jn),jn.add=su,jn.attempt=Us,jn.camelCase=Ls,jn.capitalize=As,jn.ceil=uu,jn.clamp=function(e,t,n){return void 0===n&&(n=t,t=void 0),void 0!==n&&(n=(n=as(n))==n?n:0),void 0!==t&&(t=(t=as(t))==t?t:0),Zn(as(e),t,n)},jn.clone=function(e){return Xn(e,4)},jn.cloneDeep=function(e){return Xn(e,5)},jn.cloneDeepWith=function(e,t){return Xn(e,5,t="function"==typeof t?t:void 0)},jn.cloneWith=function(e,t){return Xn(e,4,t="function"==typeof t?t:void 0)},jn.conformsTo=function(e,t){return null==t||Qn(e,t,_s(t))},jn.deburr=Ps,jn.defaultTo=function(e,t){return null==e||e!=e?t:e},jn.divide=lu,jn.endsWith=function(e,t,n){e=us(e),t=Qr(t);var r=e.length,o=n=void 0===n?r:Zn(os(n),0,r);return(n-=t.length)>=0&&e.slice(n,o)==t},jn.eq=Ma,jn.escape=function(e){return(e=us(e))&&N.test(e)?e.replace(D,It):e},jn.escapeRegExp=function(e){return(e=us(e))&&q.test(e)?e.replace(V,"\\$&"):e},jn.every=function(e,t,n){var r=Ra(e)?st:rr;return n&&li(e,t,n)&&(t=void 0),r(e,Qo(t,3))},jn.find=aa,jn.findIndex=Pi,jn.findKey=function(e,t){return mt(e,Qo(t,3),lr)},jn.findLast=sa,jn.findLastIndex=Ri,jn.findLastKey=function(e,t){return mt(e,Qo(t,3),cr)},jn.floor=cu,jn.forEach=ua,jn.forEachRight=la,jn.forIn=function(e,t){return null==e?e:sr(e,Qo(t,3),xs)},jn.forInRight=function(e,t){return null==e?e:ur(e,Qo(t,3),xs)},jn.forOwn=function(e,t){return e&&lr(e,Qo(t,3))},jn.forOwnRight=function(e,t){return e&&cr(e,Qo(t,3))},jn.get=gs,jn.gt=La,jn.gte=Aa,jn.has=function(e,t){return null!=e&&ii(e,t,gr)},jn.hasIn=ms,jn.head=Ii,jn.identity=Gs,jn.includes=function(e,t,n,r){e=Ia(e)?e:Ms(e),n=n&&!r?os(n):0;var o=e.length;return n<0&&(n=sn(o+n,0)),Xa(e)?n<=o&&e.indexOf(t,n)>-1:!!o&&bt(e,t,n)>-1},jn.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=null==n?0:os(n);return o<0&&(o=sn(r+o,0)),bt(e,t,o)},jn.inRange=function(e,t,n){return t=rs(t),void 0===n?(n=t,t=0):n=rs(n),function(e,t,n){return e>=un(t,n)&&e<sn(t,n)}(e=as(e),t,n)},jn.invoke=ws,jn.isArguments=Pa,jn.isArray=Ra,jn.isArrayBuffer=Da,jn.isArrayLike=Ia,jn.isArrayLikeObject=Na,jn.isBoolean=function(e){return!0===e||!1===e||qa(e)&&hr(e)==u},jn.isBuffer=za,jn.isDate=Fa,jn.isElement=function(e){return qa(e)&&1===e.nodeType&&!$a(e)},jn.isEmpty=function(e){if(null==e)return!0;if(Ia(e)&&(Ra(e)||"string"==typeof e||"function"==typeof e.splice||za(e)||Ja(e)||Pa(e)))return!e.length;var t=oi(e);if(t==p||t==m)return!e.size;if(pi(e))return!Or(e).length;for(var n in e)if(ke.call(e,n))return!1;return!0},jn.isEqual=function(e,t){return _r(e,t)},jn.isEqualWith=function(e,t,n){var r=(n="function"==typeof n?n:void 0)?n(e,t):void 0;return void 0===r?_r(e,t,void 0,n):!!r},jn.isError=Ba,jn.isFinite=function(e){return"number"==typeof e&&rn(e)},jn.isFunction=Ha,jn.isInteger=Ua,jn.isLength=Wa,jn.isMap=Ya,jn.isMatch=function(e,t){return e===t||xr(e,t,ei(t))},jn.isMatchWith=function(e,t,n){return n="function"==typeof n?n:void 0,xr(e,t,ei(t),n)},jn.isNaN=function(e){return Ga(e)&&e!=+e},jn.isNative=function(e){if(di(e))throw new fe("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return kr(e)},jn.isNil=function(e){return null==e},jn.isNull=function(e){return null===e},jn.isNumber=Ga,jn.isObject=Va,jn.isObjectLike=qa,jn.isPlainObject=$a,jn.isRegExp=Ka,jn.isSafeInteger=function(e){return Ua(e)&&e>=-9007199254740991&&e<=9007199254740991},jn.isSet=Za,jn.isString=Xa,jn.isSymbol=Qa,jn.isTypedArray=Ja,jn.isUndefined=function(e){return void 0===e},jn.isWeakMap=function(e){return qa(e)&&oi(e)==w},jn.isWeakSet=function(e){return qa(e)&&"[object WeakSet]"==hr(e)},jn.join=function(e,t){return null==e?"":on.call(e,t)},jn.kebabCase=Rs,jn.last=Bi,jn.lastIndexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var o=r;return void 0!==n&&(o=(o=os(n))<0?sn(r+o,0):un(o,r-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):yt(e,_t,o,!0)},jn.lowerCase=Ds,jn.lowerFirst=Is,jn.lt=es,jn.lte=ts,jn.max=function(e){return e&&e.length?or(e,Gs,vr):void 0},jn.maxBy=function(e,t){return e&&e.length?or(e,Qo(t,2),vr):void 0},jn.mean=function(e){return xt(e,Gs)},jn.meanBy=function(e,t){return xt(e,Qo(t,2))},jn.min=function(e){return e&&e.length?or(e,Gs,Sr):void 0},jn.minBy=function(e,t){return e&&e.length?or(e,Qo(t,2),Sr):void 0},jn.stubArray=iu,jn.stubFalse=au,jn.stubObject=function(){return{}},jn.stubString=function(){return""},jn.stubTrue=function(){return!0},jn.multiply=du,jn.nth=function(e,t){return e&&e.length?Ar(e,os(t)):void 0},jn.noConflict=function(){return qe._===this&&(qe._=Te),this},jn.noop=Qs,jn.now=ga,jn.pad=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;if(!t||r>=t)return e;var o=(t-r)/2;return Ro(en(o),n)+e+Ro(Jt(o),n)},jn.padEnd=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;return t&&r<t?e+Ro(t-r,n):e},jn.padStart=function(e,t,n){e=us(e);var r=(t=os(t))?Vt(e):0;return t&&r<t?Ro(t-r,n)+e:e},jn.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),cn(us(e).replace(Y,""),t||0)},jn.random=function(e,t,n){if(n&&"boolean"!=typeof n&&li(e,t,n)&&(t=n=void 0),void 0===n&&("boolean"==typeof t?(n=t,t=void 0):"boolean"==typeof e&&(n=e,e=void 0)),void 0===e&&void 0===t?(e=0,t=1):(e=rs(e),void 0===t?(t=e,e=0):t=rs(t)),e>t){var r=e;e=t,t=r}if(n||e%1||t%1){var o=fn();return un(e+o*(t-e+He("1e-"+((o+"").length-1))),t)}return Nr(e,t)},jn.reduce=function(e,t,n){var r=Ra(e)?pt:Ot,o=arguments.length<3;return r(e,Qo(t,4),n,o,tr)},jn.reduceRight=function(e,t,n){var r=Ra(e)?ht:Ot,o=arguments.length<3;return r(e,Qo(t,4),n,o,nr)},jn.repeat=function(e,t,n){return t=(n?li(e,t,n):void 0===t)?1:os(t),zr(us(e),t)},jn.replace=function(){var e=arguments,t=us(e[0]);return e.length<3?t:t.replace(e[1],e[2])},jn.result=function(e,t,n){var r=-1,o=(t=uo(t,e)).length;for(o||(o=1,e=void 0);++r<o;){var i=null==e?void 0:e[Si(t[r])];void 0===i&&(r=o,i=n),e=Ha(i)?i.call(e):i}return e},jn.round=pu,jn.runInContext=e,jn.sample=function(e){return(Ra(e)?Bn:Br)(e)},jn.size=function(e){if(null==e)return 0;if(Ia(e))return Xa(e)?Vt(e):e.length;var t=oi(e);return t==p||t==m?e.size:Or(e).length},jn.snakeCase=Ns,jn.some=function(e,t,n){var r=Ra(e)?vt:Gr;return n&&li(e,t,n)&&(t=void 0),r(e,Qo(t,3))},jn.sortedIndex=function(e,t){return $r(e,t)},jn.sortedIndexBy=function(e,t,n){return Kr(e,t,Qo(n,2))},jn.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=$r(e,t);if(r<n&&Ma(e[r],t))return r}return-1},jn.sortedLastIndex=function(e,t){return $r(e,t,!0)},jn.sortedLastIndexBy=function(e,t,n){return Kr(e,t,Qo(n,2),!0)},jn.sortedLastIndexOf=function(e,t){if(null==e?0:e.length){var n=$r(e,t,!0)-1;if(Ma(e[n],t))return n}return-1},jn.startCase=zs,jn.startsWith=function(e,t,n){return e=us(e),n=null==n?0:Zn(os(n),0,e.length),t=Qr(t),e.slice(n,n+t.length)==t},jn.subtract=hu,jn.sum=function(e){return e&&e.length?Et(e,Gs):0},jn.sumBy=function(e,t){return e&&e.length?Et(e,Qo(t,2)):0},jn.template=function(e,t,n){var r=jn.templateSettings;n&&li(e,t,n)&&(t=void 0),e=us(e),t=fs({},t,r,Uo);var o,i,a=fs({},t.imports,r.imports,Uo),s=_s(a),u=Mt(a,s),l=0,c=t.interpolate||ue,f="__p += '",d=ve((t.escape||ue).source+"|"+c.source+"|"+(c===B?ee:ue).source+"|"+(t.evaluate||ue).source+"|$","g"),p="//# sourceURL="+(ke.call(t,"sourceURL")?(t.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Ne+"]")+"\n";e.replace(d,(function(t,n,r,a,s,u){return r||(r=a),f+=e.slice(l,u).replace(le,Nt),n&&(o=!0,f+="' +\n__e("+n+") +\n'"),s&&(i=!0,f+="';\n"+s+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=u+t.length,t})),f+="';\n";var h=ke.call(t,"variable")&&t.variable;if(h){if(Q.test(h))throw new fe("Invalid `variable` option passed into `_.template`")}else f="with (obj) {\n"+f+"\n}\n";f=(i?f.replace(L,""):f).replace(A,"$1").replace(P,"$1;"),f="function("+(h||"obj")+") {\n"+(h?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(i?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var v=Us((function(){return de(s,p+"return "+f).apply(void 0,u)}));if(v.source=f,Ba(v))throw v;return v},jn.times=function(e,t){if((e=os(e))<1||e>9007199254740991)return[];var n=4294967295,r=un(e,4294967295);e-=4294967295;for(var o=St(r,t=Qo(t));++n<e;)t(n);return o},jn.toFinite=rs,jn.toInteger=os,jn.toLength=is,jn.toLower=function(e){return us(e).toLowerCase()},jn.toNumber=as,jn.toSafeInteger=function(e){return e?Zn(os(e),-9007199254740991,9007199254740991):0===e?e:0},jn.toString=us,jn.toUpper=function(e){return us(e).toUpperCase()},jn.trim=function(e,t,n){if((e=us(e))&&(n||void 0===t))return Tt(e);if(!e||!(t=Qr(t)))return e;var r=qt(e),o=qt(t);return co(r,At(r,o),Pt(r,o)+1).join("")},jn.trimEnd=function(e,t,n){if((e=us(e))&&(n||void 0===t))return e.slice(0,Yt(e)+1);if(!e||!(t=Qr(t)))return e;var r=qt(e);return co(r,0,Pt(r,qt(t))+1).join("")},jn.trimStart=function(e,t,n){if((e=us(e))&&(n||void 0===t))return e.replace(Y,"");if(!e||!(t=Qr(t)))return e;var r=qt(e);return co(r,At(r,qt(t))).join("")},jn.truncate=function(e,t){var n=30,r="...";if(Va(t)){var o="separator"in t?t.separator:o;n="length"in t?os(t.length):n,r="omission"in t?Qr(t.omission):r}var i=(e=us(e)).length;if(zt(e)){var a=qt(e);i=a.length}if(n>=i)return e;var s=n-Vt(r);if(s<1)return r;var u=a?co(a,0,s).join(""):e.slice(0,s);if(void 0===o)return u+r;if(a&&(s+=u.length-s),Ka(o)){if(e.slice(s).search(o)){var l,c=u;for(o.global||(o=ve(o.source,us(te.exec(o))+"g")),o.lastIndex=0;l=o.exec(c);)var f=l.index;u=u.slice(0,void 0===f?s:f)}}else if(e.indexOf(Qr(o),s)!=s){var d=u.lastIndexOf(o);d>-1&&(u=u.slice(0,d))}return u+r},jn.unescape=function(e){return(e=us(e))&&I.test(e)?e.replace(R,Gt):e},jn.uniqueId=function(e){var t=++Ce;return us(e)+t},jn.upperCase=Fs,jn.upperFirst=Bs,jn.each=ua,jn.eachRight=la,jn.first=Ii,Xs(jn,(fu={},lr(jn,(function(e,t){ke.call(jn.prototype,t)||(fu[t]=e)})),fu),{chain:!1}),jn.VERSION="4.17.21",it(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){jn[e].placeholder=jn})),it(["drop","take"],(function(e,t){Pn.prototype[e]=function(n){n=void 0===n?1:sn(os(n),0);var r=this.__filtered__&&!t?new Pn(this):this.clone();return r.__filtered__?r.__takeCount__=un(n,r.__takeCount__):r.__views__.push({size:un(n,4294967295),type:e+(r.__dir__<0?"Right":"")}),r},Pn.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),it(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=1==n||3==n;Pn.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:Qo(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),it(["head","last"],(function(e,t){var n="take"+(t?"Right":"");Pn.prototype[e]=function(){return this[n](1).value()[0]}})),it(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");Pn.prototype[e]=function(){return this.__filtered__?new Pn(this):this[n](1)}})),Pn.prototype.compact=function(){return this.filter(Gs)},Pn.prototype.find=function(e){return this.filter(e).head()},Pn.prototype.findLast=function(e){return this.reverse().find(e)},Pn.prototype.invokeMap=Fr((function(e,t){return"function"==typeof e?new Pn(this):this.map((function(n){return br(n,e,t)}))})),Pn.prototype.reject=function(e){return this.filter(Oa(Qo(e)))},Pn.prototype.slice=function(e,t){e=os(e);var n=this;return n.__filtered__&&(e>0||t<0)?new Pn(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),void 0!==t&&(n=(t=os(t))<0?n.dropRight(-t):n.take(t-e)),n)},Pn.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Pn.prototype.toArray=function(){return this.take(4294967295)},lr(Pn.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),r=/^(?:head|last)$/.test(t),o=jn[r?"take"+("last"==t?"Right":""):t],i=r||/^find/.test(t);o&&(jn.prototype[t]=function(){var t=this.__wrapped__,a=r?[1]:arguments,s=t instanceof Pn,u=a[0],l=s||Ra(t),c=function(e){var t=o.apply(jn,dt([e],a));return r&&f?t[0]:t};l&&n&&"function"==typeof u&&1!=u.length&&(s=l=!1);var f=this.__chain__,d=!!this.__actions__.length,p=i&&!f,h=s&&!d;if(!i&&l){t=h?t:new Pn(this);var v=e.apply(t,a);return v.__actions__.push({func:ra,args:[c],thisArg:void 0}),new An(v,f)}return p&&h?e.apply(this,a):(v=this.thru(c),p?r?v.value()[0]:v.value():v)})})),it(["pop","push","shift","sort","splice","unshift"],(function(e){var t=ye[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);jn.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var o=this.value();return t.apply(Ra(o)?o:[],e)}return this[n]((function(n){return t.apply(Ra(n)?n:[],e)}))}})),lr(Pn.prototype,(function(e,t){var n=jn[t];if(n){var r=n.name+"";ke.call(wn,r)||(wn[r]=[]),wn[r].push({name:t,func:n})}})),wn[Mo(void 0,2).name]=[{name:"wrapper",func:void 0}],Pn.prototype.clone=function(){var e=new Pn(this.__wrapped__);return e.__actions__=bo(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=bo(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=bo(this.__views__),e},Pn.prototype.reverse=function(){if(this.__filtered__){var e=new Pn(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},Pn.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=Ra(e),r=t<0,o=n?e.length:0,i=function(e,t,n){var r=-1,o=n.length;for(;++r<o;){var i=n[r],a=i.size;switch(i.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=un(t,e+a);break;case"takeRight":e=sn(e,t-a)}}return{start:e,end:t}}(0,o,this.__views__),a=i.start,s=i.end,u=s-a,l=r?s:a-1,c=this.__iteratees__,f=c.length,d=0,p=un(u,this.__takeCount__);if(!n||!r&&o==u&&p==u)return ro(e,this.__actions__);var h=[];e:for(;u--&&d<p;){for(var v=-1,g=e[l+=t];++v<f;){var m=c[v],y=m.iteratee,b=m.type,w=y(g);if(2==b)g=w;else if(!w){if(1==b)continue e;break e}}h[d++]=g}return h},jn.prototype.at=oa,jn.prototype.chain=function(){return na(this)},jn.prototype.commit=function(){return new An(this.value(),this.__chain__)},jn.prototype.next=function(){void 0===this.__values__&&(this.__values__=ns(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?void 0:this.__values__[this.__index__++]}},jn.prototype.plant=function(e){for(var t,n=this;n instanceof Ln;){var r=ji(n);r.__index__=0,r.__values__=void 0,t?o.__wrapped__=r:t=r;var o=r;n=n.__wrapped__}return o.__wrapped__=e,t},jn.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof Pn){var t=e;return this.__actions__.length&&(t=new Pn(this)),(t=t.reverse()).__actions__.push({func:ra,args:[Vi],thisArg:void 0}),new An(t,this.__chain__)}return this.thru(Vi)},jn.prototype.toJSON=jn.prototype.valueOf=jn.prototype.value=function(){return ro(this.__wrapped__,this.__actions__)},jn.prototype.first=jn.prototype.head,gt&&(jn.prototype[gt]=function(){return this}),jn}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(qe._=$t,define((function(){return $t}))):Ge?((Ge.exports=$t)._=$t,Ye._=$t):qe._=$t}).call(this)}).call(this,n(31),n(57)(e))},function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.__esModule=!0,e.exports.default=e.exports,n(t)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(73).default,o=n(7);e.exports=function(e,t){if(t&&("object"==r(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return o(e)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";n.d(t,"a",(function(){return s})),n.d(t,"j",(function(){return Q})),n.d(t,"h",(function(){return J})),n.d(t,"f",(function(){return X})),n.d(t,"b",(function(){return P})),n.d(t,"g",(function(){return N})),n.d(t,"i",(function(){return F})),n.d(t,"c",(function(){return I})),n.d(t,"e",(function(){return U})),n.d(t,"d",(function(){return H}));var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function o(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var s=function(){function e(t){a(this,e),this.type=t,"string"==typeof(arguments.length<=1?void 0:arguments[1])?(this.name=arguments.length<=1?void 0:arguments[1],this.items=arguments.length<=2?void 0:arguments[2]):(this.name=null,this.items=arguments.length<=1?void 0:arguments[1]),Array.isArray(this.items)||(this.items=[this.items])}return r(e,[{key:"toJSON",value:function(){return{name:this.name,_functionTreePrimitive:!0,type:this.type,items:this.items}}}]),e}(),u=function(e){function t(){var e;a(this,t);for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];return o(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this,"sequence"].concat(r)))}return i(t,e),t}(s),l=function(e){function t(){var e;a(this,t);for(var n=arguments.length,r=Array(n),i=0;i<n;i++)r[i]=arguments[i];return o(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this,"parallel"].concat(r)))}return i(t,e),t}(s),c=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function f(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function p(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var h=function(e){function t(e){f(this,t);var n=d(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e.message||e));return n.name="FunctionTreeError",n}return p(t,e),c(t,[{key:"toJSON",value:function(){return{name:this.name,message:this.message,stack:this.stack}}}]),t}(function(e){function t(){var t=Reflect.construct(e,Array.from(arguments));return Object.setPrototypeOf(t,Object.getPrototypeOf(this)),t}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}(Error)),v=function(e){function t(e,n,r,o){f(this,t);var i=d(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,o));return i.name="FunctionTreeExecutionError",i.execution=e,i.funcDetails=n,i.payload=r,i}return p(t,e),c(t,[{key:"toJSON",value:function(){return{name:this.name,message:this.message,execution:{name:this.execution.name},funcDetails:{name:this.funcDetails.name,functionIndex:this.funcDetails.functionIndex},payload:this.payload,stack:this.stack}}}]),t}(h),g="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};function m(e){if(e.displayName)return e.displayName;if(e.name)return e.name;var t=e.toString(),n=void 0;return 0===t.indexOf("async function")?n="async function ":0===t.indexOf("function")&&(n="function "),t=(t=t.substr(n?n.length:0)).substr(0,t.indexOf("("))}function y(e){return e&&!Array.isArray(e)&&"object"===(void 0===e?"undefined":g(e))&&!(e instanceof s)}function b(e,t,n,r){if(n instanceof s){var o=n.toJSON();return Object.assign(o,{items:b(e,t,o.items,n instanceof l).items})}if(Array.isArray(n))return new u(n.reduce((function(r,o,i){if(o instanceof s){var a=o.toJSON();return r.concat(Object.assign(a,{items:b(e,t,a.items,o instanceof l).items}))}if("function"==typeof o){var u={name:o.displayName||m(o),functionIndex:t.push(o)-1,function:o},c=n[i+1];return y(c)&&(u.outputs={},Object.keys(c).forEach((function(n){if(o.outputs&&!~o.outputs.indexOf(n))throw new h("Outputs object doesn't match list of possible outputs defined for function.");u.outputs[n]=b(e,t,"function"==typeof c[n]?[c[n]]:c[n])}))),r.concat(u)}if(y(o))return r;if(Array.isArray(o)){var f=b(e,t,o);return r.concat(f)}throw new h('Unexpected entry in "'+e+'". '+function(e,t){return"\n[\n"+e.map((function(e){return e===t?" "+(void 0===t?"undefined":g(t))+", <-- PROBLEM":"function"==typeof e?" "+m(e)+",":e instanceof s?" [ "+e.type.toUpperCase()+" ],":Array.isArray(e)?" [ SEQUENCE ],":" { PATHS },"})).join("\n")+"\n]\n "}(n,o))}),[])).toJSON();throw new h("Unexpected entry in tree")}var w=function(e,t){return b(e,[],"function"==typeof t?[t]:t)},_=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var x=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.path=t,this.payload=n}return _(e,[{key:"toJSON",value:function(){return{path:this.path,payload:this.payload,_functionTreePath:!0}}}]),e}(),k=n(207),C=n.n(k);function O(e,t){return e._functionTreePrimitive&&e.type===t}function E(e,t,n,r,o,i,a,s,u){!function t(u,l,c,f,d){n((function(){function n(e){t(u,l+1,e,c,d)}function p(n,o){return function(i){var a=Object.assign({},c,i?i.payload:{});if(i&&n.outputs){var s=Object.keys(n.outputs);if(!~s.indexOf(i.path))throw new v(e,n,c,"function "+n.name+" must use one of its possible outputs: "+s.join(", ")+".");r(n,i.path,a),t(n.outputs[i.path].items,0,a,c,o)}else o(a)}}var h=u[l];if(h)if(O(h,"sequence"))t(h.items,0,c,f,n);else if(O(h,"parallel")){var g=h.items.length,m=[];i(c,g),h.items.forEach((function(r,o){return r.function?e.runFunction(r,c,f,p(r,(function(e){m.push(e),m.length===g?(s(e,g),n(Object.assign.apply(Object,[{}].concat(m)))):a(e,g-m.length)}))):t(r.items,0,c,f,(function(e){m.push(e),m.length===g?(s(e,g),n(Object.assign.apply(Object,[{}].concat(m)))):a(e,g-m.length)})),m}))}else e.runFunction(h,c,f,p(h,n));else u!==e.staticTree&&o(c),d(c)}))}([e.staticTree],0,t,null,u)}var S="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};function T(e){return e&&(e instanceof Promise||"function"==typeof e.then&&"function"==typeof e.catch)}function j(e){return!(null!==e&&"object"===(void 0===e?"undefined":S(e))&&!Array.isArray(e)&&e.constructor!==Object)}var M="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},L=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function A(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var P=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.wrap,o=void 0===r||r,i=n.ignoreDefinition,a=void 0!==i&&i;A(this,e),this.definition=t,"function"!=typeof t&&(a||this.verifyDefinition(t),this.wrap=o,this.ProviderConstructor=function(e){this.context=e},this.ProviderConstructor.prototype=t,this.WrappedProviderConstructor=function(e,t){this.context=t,this.providerName=e},this.WrappedProviderConstructor.prototype=Object.keys(a?{}:t).reduce((function(e,n){var r=t[n];return e[n]=function(){for(var e=this,t=arguments.length,o=Array(t),i=0;i<t;i++)o[i]=arguments[i];var a=r.apply(this,o);return T(a)?a.then((function(t){return e.context.debugger.send({type:"provider",datetime:Date.now(),method:e.providerName+"."+n,args:o,isPromise:!0,isRejected:!1,returnValue:j(t)?t:"[CAN_NOT_SERIALIZE]"}),t})).catch((function(t){throw e.context.debugger.send({method:e.providerName+"."+n,args:o,isPromise:!0,isRejected:!0}),t})):(this.context.debugger.send({type:"provider",datetime:Date.now(),method:this.providerName+"."+n,args:o,returnValue:j(a)?a:"[CAN_NOT_SERIALIZE]"}),a)},e}),{}))}return L(e,[{key:"verifyDefinition",value:function(e){if(!this.ignoreDefinition){if("object"!==(void 0===e?"undefined":M(e))||null===e)throw new Error("The definition passed as Provider is not valid");Object.keys(e).forEach((function(t){if("function"!=typeof e[t])throw new Error("The property "+t+" passed to Provider is not a method")}))}}},{key:"get",value:function(e){return"function"==typeof this.definition?this.definition(e):new this.ProviderConstructor(e)}},{key:"getWrapped",value:function(e,t){return"function"==typeof this.definition?this.definition(t):new this.WrappedProviderConstructor(e,t)}}]),e}(),R=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function D(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var I=function(){function e(){D(this,e)}return R(e,[{key:"getValue",value:function(){throw new Error('Extending ResolveValue requires you to add a "getValue" method')}}]),e}();function N(e,t){return t.split(".").reduce((function(e,n,r){if(r>0&&void 0===e)throw new Error('Cannot extract value at path "'+t+'" ("'+n+'" is not defined).');return e[n]}),e)}var z=function(e){function t(e){D(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.cvalue=e,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),R(t,[{key:"getValue",value:function(e){var t=e.resolve,n=this.cvalue;return t.isResolveValue(n)?t.value(n):Object.keys(n).reduce((function(e,r){return e[r]=t.value(n[r]),e}),{})}}]),t}(I),F=function(e){return new z(e)},B=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var H=function(e){function t(e,n,r,o){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return i.type=e,i.getter=n,i.strings=r,i.values=o,i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),B(t,[{key:"getTags",value:function(){return[this].concat(this.getNestedTags())}},{key:"getPath",value:function(e){var t=this;return this.strings.reduce((function(n,r,o){var i=t.values[o];return i instanceof I?n+r+i.getValue(e):n+r+(void 0!==i?i:"")}),"")}},{key:"getValue",value:function(e){return this.getter(this.getPath(e),e)}},{key:"getNestedTags",value:function(){var e=this;return this.strings.reduce((function(n,r,o){var i=e.values[o];return i instanceof t?n.concat(i):n}),[])}},{key:"toString",value:function(){return this.type+"`"+this.pathToString()+"`"}},{key:"pathToString",value:function(){var e=this;return this.strings.reduce((function(n,r,o){var i=e.values[o];return i instanceof t?n+r+"${"+i.toString()+"}":n+r+(void 0!==i?i:"")}),"")}}]),t}(I);function U(e,t){return function(n){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];if(o.some((function(e){return void 0===e})))throw new Error("One of the values passed inside the tag interpolated to undefined. Please check.");return new H(e,t,n,o)}}var W=new P({isTag:function(e){if(!(e instanceof H))return!1;for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return!n.length||n.reduce((function(t,n){return t||n===e.type}),!1)},isResolveValue:function(e){return e instanceof I},value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e instanceof I?e.getValue(t?Object.assign({},this.context,t):this.context):e},path:function(e){if(e instanceof H)return e.getPath(this.context);throw new Error("You are extracting a path from an argument that is not a Tag.")}},{wrap:!1}),V=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),q="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};function Y(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function G(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $(e){return!e||"object"===(void 0===e?"undefined":q(e))&&!Array.isArray(e)}function K(e,t,n,r){var o=e;return o.execution=t,o.functionDetails=n,o.payload=Object.assign({},r,{_execution:{id:t.id,functionIndex:n.functionIndex},error:e.toJSON?e.toJSON():{name:e.name,message:e.message,stack:e.stack}}),o}var Z=function(){function e(t,n,r,o){G(this,e),this.id=Date.now()+"_"+Math.floor(1e4*Math.random()),this.name=t||n.name||this.id,this.staticTree=n,this.functionTree=r,this.datetime=Date.now(),this.errorCallback=o,this.hasThrown=!1,this.isAsync=!1,this.runFunction=this.runFunction.bind(this)}return V(e,[{key:"runFunction",value:function(e,t,n,r){if(!this.hasThrown){var o=this.createContext(e,t,n),i=this.functionTree,a=this.errorCallback,s=this,u=void 0;i.emit("functionStart",s,e,t);try{u=e.function(o)}catch(l){return this.hasThrown=!0,a(K(l,s,e,t),s,e,t)}if(T(u))i.emit("asyncFunction",s,e,t,u),this.isAsync=!0,u.then((function(n){if(n instanceof x)i.emit("functionEnd",s,e,t,n),r(n.toJSON());else{if(e.outputs)throw i.emit("functionEnd",s,e,t,n),new v(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" needs to be a path of either "+Object.keys(e.outputs)));if(!$(n))throw i.emit("functionEnd",s,e,t,n),new v(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" is not a valid result"));i.emit("functionEnd",s,e,t,n),r({payload:n})}})).catch((function(n){if(!s.hasThrown)if(n instanceof Error)s.hasThrown=!0,a(K(n,s,e,t),s,e,t);else if(n instanceof x)i.emit("functionEnd",s,e,t,n),r(n.toJSON());else if(e.outputs){var o=new v(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" needs to be a path of either "+Object.keys(e.outputs)));s.hasThrown=!0,a(K(o,s,e,t),s,e,t)}else if($(n))i.emit("functionEnd",s,e,t,n),r({payload:n});else{var u=new v(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" is not a valid result"));s.hasThrown=!0,a(K(u,s,e,t),s,e,t)}}));else if(u instanceof x)i.emit("functionEnd",s,e,t,u),r(u.toJSON());else if(e.outputs){var l=new v(s,e,t,new Error("The result "+JSON.stringify(u)+" from function "+e.name+" needs to be a path of either "+Object.keys(e.outputs)));this.hasThrown=!0,a(K(l,s,e,t),s,e,t)}else if($(u))i.emit("functionEnd",s,e,t,u),r({payload:u});else{var c=new v(s,e,t,new Error("The result "+JSON.stringify(u)+" from function "+e.name+" is not a valid result"));this.hasThrown=!0,a(K(c,s,e,t),s,e,t)}}}},{key:"createContext",value:function(e,t,n){var r=this.functionTree.contextProviders,o={execution:this,props:t||{},functionDetails:e,path:e.outputs?Object.keys(e.outputs).reduce((function(e,t){return e[t]=function(e){return new x(t,e)},e}),{}):null},i=r.debugger&&r.debugger.get(o,e,t,n),a=Object.keys(r).reduce((function(o,i){var a=r[i];return o[i]=a instanceof P?a.get(o,e,t,n):a,o}),o);return i?Object.keys(a).reduce((function(t,n){var o=r[n];return o&&o instanceof P&&o.wrap?t[n]="function"==typeof o.wrap?o.wrap(a,e):o.getWrapped(n,a):t[n]=a[n],t}),{}):a}}]),e}(),X=function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};G(this,t);var r=Y(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));if(r.cachedTrees=[],r.cachedStaticTrees=[],r.executeBranchWrapper=n.executeBranchWrapper||function(e){e()},"object"!==(void 0===e?"undefined":q(e))||null===e||Array.isArray(e))throw new Error("You have to pass an object of context providers to FunctionTree");var o=Object.keys(e);if(o.indexOf("props")>=0||o.indexOf("path")>=0||o.indexOf("resolve")>=0||o.indexOf("execution")>=0||o.indexOf("debugger")>=0)throw new Error('You are trying to add a provider with protected key. "props", "path", "resolve", "execution" and "debugger" are protected');return r.contextProviders=Object.assign({},e,{resolve:W}),r.run=r.run.bind(r),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),V(t,[{key:"run",value:function(){var e=this,t=void 0,n=void 0,r=void 0,o=void 0,i=void 0,a=[].slice.call(arguments);if(a.forEach((function(e){"string"==typeof e?t=e:Array.isArray(e)||e instanceof s?n=e:n||"function"!=typeof e?"function"==typeof e?o=e:r=e:n=e})),!n)throw new Error("function-tree - You did not pass in a function tree");var u=function(o,a){var s=e.cachedTrees.indexOf(n);-1===s?(i=w(t,n),e.cachedTrees.push(n),e.cachedStaticTrees.push(i)):i=e.cachedStaticTrees[s];var u=new Z(t,i,e,(function(t,n,r,o){e.emit("error",t,n,r,o),a(t)}));e.emit("start",u,r),E(u,r,e.executeBranchWrapper,(function(t,n,r){e.emit("pathStart",n,u,t,r)}),(function(t){e.emit("pathEnd",u,t)}),(function(t,n){e.emit("parallelStart",u,t,n)}),(function(t,n){e.emit("parallelProgress",u,t,n)}),(function(t,n){e.emit("parallelEnd",u,t,n)}),(function(t){e.emit("end",u,t),o===a?o(null,t):o(t)}))};if(!o)return new Promise(u);u(o,o)}}]),t}(C.a);function Q(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return new(Function.prototype.bind.apply(u,[null].concat(t)))}function J(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return new(Function.prototype.bind.apply(l,[null].concat(t)))}},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(273);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&r(e,t)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(150);function o(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,r(o.key),o)}}e.exports=function(e,t,n){return t&&o(e.prototype,t),n&&o(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){function n(){return e.exports=n=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},e.exports.__esModule=!0,e.exports.default=e.exports,n.apply(null,arguments)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){!function(){"use strict";var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var o=arguments[r];if(o){var i=typeof o;if("string"===i||"number"===i)e.push(o);else if(Array.isArray(o)){if(o.length){var a=n.apply(null,o);a&&e.push(a)}}else if("object"===i)if(o.toString===Object.prototype.toString)for(var s in o)t.call(o,s)&&o[s]&&e.push(s);else e.push(o.toString())}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"==typeof define.amd&&define.amd?define("classnames",[],(function(){return n})):window.classNames=n}()},function(e,t){e.exports=jQuery},function(e,t,n){var r=n(94);e.exports=function(e,t,n){var o=null==e?void 0:r(e,t);return void 0===o?n:o}},function(e,t,n){"use strict";n.d(t,"b",(function(){return u})),n.d(t,"a",(function(){return l}));var r=n(12),o=n(53),i=n(5),a=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var u=function(){function e(t,n){s(this,e),this.computed=t,this.propsTags=t.propsTags,this.nestedPath=n}return a(e,[{key:"getValue",value:function(e){return this.nestedPath.reduce((function(e,t){return e&&e[t]}),this.computed.getValue(e))}},{key:"getDependencyMap",value:function(){return this.computed.getDependencyMap()}},{key:"clone",value:function(){return this.computed.clone()}},{key:"destroy",value:function(){return this.computed.destroy()}}]),e}(),l=function(e){function t(e){s(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"Compute"));return n.computedCallback=e,n.isDirty=!0,n.value=null,n.props=null,n.getters=null,n.stateTags=[],n.propsTags=[],n.onUpdate=n.onUpdate.bind(n),n.dynamicGetter=n.dynamicGetter.bind(n),n.dynamicGetter.path=n.dynamicPathGetter.bind(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),a(t,[{key:"createDependencyMap",value:function(){return this.controller.createDependencyMap(this.stateTags,this.props,this.modulePath)}},{key:"getDependencyMap",value:function(){return this.dependencyMap}},{key:"onUpdate",value:function(){this.isDirty=!0}},{key:"clone",value:function(){return new t(this.computedCallback).create(this.controller,this.modulePath,this.name+" (clone)")}},{key:"compute",value:function(){return this.executedCount++,this.computedCallback(this.getDynamicGetter())}},{key:"getDynamicGetter",value:function(){return this.stateTags=[],this.propsTags=[],this.dynamicGetter}},{key:"parseDependencies",value:function(e){var t=this;if(!(e instanceof r.d))throw new Error('Cerebral - Only tags are allowed in the dynamic "get" of Compute');e.getTags().forEach((function(e){"props"===e.type?t.propsTags.push(e):t.stateTags.push(e)}))}},{key:"dynamicGetter",value:function(e){this.parseDependencies(e);var t=e.getValue(this.getters);return Object(i.t)(t)?t.getValue(this.props):t}},{key:"dynamicPathGetter",value:function(e){return e.getPath(this.getters)}},{key:"hasChangedProps",value:function(e){var t=this,n=this.controller.createContext(e);return this.propsTags.reduce((function(e,r){return!!e||r.getValue(t.getters)!==r.getValue(n)}),!1)}},{key:"getValue",value:function(e){if(!this.controller)throw new Error("This Cerebral Compute has not been added to a module");if(!this.isDirty&&this.propsTags.length&&this.hasChangedProps(e)&&(this.isDirty=!0),this.isDirty){this.getters=this.controller.createContext(e),this.props=e,this.value=this.compute();var t=this.dependencyMap;this.dependencyMap=this.createDependencyMap(),this.controller.dependencyStore.updateEntity(this,t,this.dependencyMap),this.controller.devtools&&(this.controller.devtools.updateWatchMap(this,this.dependencyMap,t),this.controller.devtools.updateComputedState(this.name,this.value)),this.isDirty=!1}return this.value}},{key:"toString",value:function(){return this.getValue(this.props)}}]),t}(o.a);t.c=function(e){return new l(e)}},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE e.exports=function(){"use strict";var e=navigator.userAgent,t=navigator.platform,n=/gecko\/\d/i.test(e),r=/MSIE \d/.test(e),o=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(e),i=/Edge\/(\d+)/.exec(e),a=r||o||i,s=a&&(r?document.documentMode||6:+(i||o)[1]),u=!i&&/WebKit\//.test(e),l=u&&/Qt\/\d+\.\d+/.test(e),c=!i&&/Chrome\/(\d+)/.exec(e),f=c&&+c[1],d=/Opera\//.test(e),p=/Apple Computer/.test(navigator.vendor),h=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(e),v=/PhantomJS/.test(e),g=p&&(/Mobile\/\w+/.test(e)||navigator.maxTouchPoints>2),m=/Android/.test(e),y=g||m||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(e),b=g||/Mac/.test(t),w=/\bCrOS\b/.test(e),_=/win/i.test(t),x=d&&e.match(/Version\/(\d*\.\d*)/);x&&(x=Number(x[1])),x&&x>=15&&(d=!1,u=!0);var k=b&&(l||d&&(null==x||x<12.11)),C=n||a&&s>=9;function O(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var E,S=function(e,t){var n=e.className,r=O(t).exec(n);if(r){var o=n.slice(r.index+r[0].length);e.className=n.slice(0,r.index)+(o?r[1]+o:"")}};function T(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function j(e,t){return T(e).appendChild(t)}function M(e,t,n,r){var o=document.createElement(e);if(n&&(o.className=n),r&&(o.style.cssText=r),"string"==typeof t)o.appendChild(document.createTextNode(t));else if(t)for(var i=0;i<t.length;++i)o.appendChild(t[i]);return o}function L(e,t,n,r){var o=M(e,t,n,r);return o.setAttribute("role","presentation"),o}function A(e,t){if(3==t.nodeType&&(t=t.parentNode),e.contains)return e.contains(t);do{if(11==t.nodeType&&(t=t.host),t==e)return!0}while(t=t.parentNode)}function P(){var e;try{e=document.activeElement}catch(t){e=document.body||null}for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function R(e,t){var n=e.className;O(t).test(n)||(e.className+=(n?" ":"")+t)}function D(e,t){for(var n=e.split(" "),r=0;r<n.length;r++)n[r]&&!O(n[r]).test(t)&&(t+=" "+n[r]);return t}E=document.createRange?function(e,t,n,r){var o=document.createRange();return o.setEnd(r||e,n),o.setStart(e,t),o}:function(e,t,n){var r=document.body.createTextRange();try{r.moveToElementText(e.parentNode)}catch(e){return r}return r.collapse(!0),r.moveEnd("character",n),r.moveStart("character",t),r};var I=function(e){e.select()};function N(e){var t=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,t)}}function z(e,t,n){for(var r in t||(t={}),e)!e.hasOwnProperty(r)||!1===n&&t.hasOwnProperty(r)||(t[r]=e[r]);return t}function F(e,t,n,r,o){null==t&&-1==(t=e.search(/[^\s\u00a0]/))&&(t=e.length);for(var i=r||0,a=o||0;;){var s=e.indexOf("\t",i);if(s<0||s>=t)return a+(t-i);a+=s-i,a+=n-a%n,i=s+1}}g?I=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:a&&(I=function(e){try{e.select()}catch(e){}});var B=function(){this.id=null,this.f=null,this.time=0,this.handler=N(this.onTimeout,this)};function H(e,t){for(var n=0;n<e.length;++n)if(e[n]==t)return n;return-1}B.prototype.onTimeout=function(e){e.id=0,e.time<=+new Date?e.f():setTimeout(e.handler,e.time-+new Date)},B.prototype.set=function(e,t){this.f=t;var n=+new Date+e;(!this.id||n<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,e),this.time=n)};var U={toString:function(){return"CodeMirror.Pass"}},W={scroll:!1},V={origin:"*mouse"},q={origin:"+move"};function Y(e,t,n){for(var r=0,o=0;;){var i=e.indexOf("\t",r);-1==i&&(i=e.length);var a=i-r;if(i==e.length||o+a>=t)return r+Math.min(a,t-o);if(o+=i-r,r=i+1,(o+=n-o%n)>=t)return r}}var G=[""];function $(e){for(;G.length<=e;)G.push(K(G)+" ");return G[e]}function K(e){return e[e.length-1]}function Z(e,t){for(var n=[],r=0;r<e.length;r++)n[r]=t(e[r],r);return n}function X(){}function Q(e,t){var n;return Object.create?n=Object.create(e):(X.prototype=e,n=new X),t&&z(t,n),n}var J=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function ee(e){return/\w/.test(e)||e>"\x80"&&(e.toUpperCase()!=e.toLowerCase()||J.test(e))}function te(e,t){return t?!!(t.source.indexOf("\\w")>-1&&ee(e))||t.test(e):ee(e)}function ne(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}var re=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function oe(e){return e.charCodeAt(0)>=768&&re.test(e)}function ie(e,t,n){for(;(n<0?t>0:t<e.length)&&oe(e.charAt(t));)t+=n;return t}function ae(e,t,n){for(var r=t>n?-1:1;;){if(t==n)return t;var o=(t+n)/2,i=r<0?Math.ceil(o):Math.floor(o);if(i==t)return e(i)?t:n;e(i)?n=i:t=i+r}}var se=null;function ue(e,t,n){var r;se=null;for(var o=0;o<e.length;++o){var i=e[o];if(i.from<t&&i.to>t)return o;i.to==t&&(i.from!=i.to&&"before"==n?r=o:se=o),i.from==t&&(i.from!=i.to&&"before"!=n?r=o:se=o)}return null!=r?r:se}var le=function(){var e=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,t=/[stwN]/,n=/[LRr]/,r=/[Lb1n]/,o=/[1n]/;function i(e,t,n){this.level=e,this.from=t,this.to=n}return function(a,s){var u="ltr"==s?"L":"R";if(0==a.length||"ltr"==s&&!e.test(a))return!1;for(var l,c=a.length,f=[],d=0;d<c;++d)f.push((l=a.charCodeAt(d))<=247?"bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN".charAt(l):1424<=l&&l<=1524?"R":1536<=l&&l<=1785?"nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111".charAt(l-1536):1774<=l&&l<=2220?"r":8192<=l&&l<=8203?"w":8204==l?"b":"L");for(var p=0,h=u;p<c;++p){var v=f[p];"m"==v?f[p]=h:h=v}for(var g=0,m=u;g<c;++g){var y=f[g];"1"==y&&"r"==m?f[g]="n":n.test(y)&&(m=y,"r"==y&&(f[g]="R"))}for(var b=1,w=f[0];b<c-1;++b){var _=f[b];"+"==_&&"1"==w&&"1"==f[b+1]?f[b]="1":","!=_||w!=f[b+1]||"1"!=w&&"n"!=w||(f[b]=w),w=_}for(var x=0;x<c;++x){var k=f[x];if(","==k)f[x]="N";else if("%"==k){var C=void 0;for(C=x+1;C<c&&"%"==f[C];++C);for(var O=x&&"!"==f[x-1]||C<c&&"1"==f[C]?"1":"N",E=x;E<C;++E)f[E]=O;x=C-1}}for(var S=0,T=u;S<c;++S){var j=f[S];"L"==T&&"1"==j?f[S]="L":n.test(j)&&(T=j)}for(var M=0;M<c;++M)if(t.test(f[M])){var L=void 0;for(L=M+1;L<c&&t.test(f[L]);++L);for(var A="L"==(M?f[M-1]:u),P=A==("L"==(L<c?f[L]:u))?A?"L":"R":u,R=M;R<L;++R)f[R]=P;M=L-1}for(var D,I=[],N=0;N<c;)if(r.test(f[N])){var z=N;for(++N;N<c&&r.test(f[N]);++N);I.push(new i(0,z,N))}else{var F=N,B=I.length,H="rtl"==s?1:0;for(++N;N<c&&"L"!=f[N];++N);for(var U=F;U<N;)if(o.test(f[U])){F<U&&(I.splice(B,0,new i(1,F,U)),B+=H);var W=U;for(++U;U<N&&o.test(f[U]);++U);I.splice(B,0,new i(2,W,U)),B+=H,F=U}else++U;F<N&&I.splice(B,0,new i(1,F,N))}return"ltr"==s&&(1==I[0].level&&(D=a.match(/^\s+/))&&(I[0].from=D[0].length,I.unshift(new i(0,0,D[0].length))),1==K(I).level&&(D=a.match(/\s+$/))&&(K(I).to-=D[0].length,I.push(new i(0,c-D[0].length,c)))),"rtl"==s?I.reverse():I}}();function ce(e,t){var n=e.order;return null==n&&(n=e.order=le(e.text,t)),n}var fe=[],de=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else if(e.attachEvent)e.attachEvent("on"+t,n);else{var r=e._handlers||(e._handlers={});r[t]=(r[t]||fe).concat(n)}};function pe(e,t){return e._handlers&&e._handlers[t]||fe}function he(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else if(e.detachEvent)e.detachEvent("on"+t,n);else{var r=e._handlers,o=r&&r[t];if(o){var i=H(o,n);i>-1&&(r[t]=o.slice(0,i).concat(o.slice(i+1)))}}}function ve(e,t){var n=pe(e,t);if(n.length)for(var r=Array.prototype.slice.call(arguments,2),o=0;o<n.length;++o)n[o].apply(null,r)}function ge(e,t,n){return"string"==typeof t&&(t={type:t,preventDefault:function(){this.defaultPrevented=!0}}),ve(e,n||t.type,e,t),xe(t)||t.codemirrorIgnore}function me(e){var t=e._handlers&&e._handlers.cursorActivity;if(t)for(var n=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),r=0;r<t.length;++r)-1==H(n,t[r])&&n.push(t[r])}function ye(e,t){return pe(e,t).length>0}function be(e){e.prototype.on=function(e,t){de(this,e,t)},e.prototype.off=function(e,t){he(this,e,t)}}function we(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function _e(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function xe(e){return null!=e.defaultPrevented?e.defaultPrevented:0==e.returnValue}function ke(e){we(e),_e(e)}function Ce(e){return e.target||e.srcElement}function Oe(e){var t=e.which;return null==t&&(1&e.button?t=1:2&e.button?t=3:4&e.button&&(t=2)),b&&e.ctrlKey&&1==t&&(t=3),t}var Ee,Se,Te=function(){if(a&&s<9)return!1;var e=M("div");return"draggable"in e||"dragDrop"in e}();function je(e){if(null==Ee){var t=M("span","\u200b");j(e,M("span",[t,document.createTextNode("x")])),0!=e.firstChild.offsetHeight&&(Ee=t.offsetWidth<=1&&t.offsetHeight>2&&!(a&&s<8))}var n=Ee?M("span","\u200b"):M("span","\xa0",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function Me(e){if(null!=Se)return Se;var t=j(e,document.createTextNode("A\u062eA")),n=E(t,0,1).getBoundingClientRect(),r=E(t,1,2).getBoundingClientRect();return T(e),!(!n||n.left==n.right)&&(Se=r.right-n.right<3)}var Le,Ae=3!="\n\nb".split(/\n/).length?function(e){for(var t=0,n=[],r=e.length;t<=r;){var o=e.indexOf("\n",t);-1==o&&(o=e.length);var i=e.slice(t,"\r"==e.charAt(o-1)?o-1:o),a=i.indexOf("\r");-1!=a?(n.push(i.slice(0,a)),t+=a+1):(n.push(i),t=o+1)}return n}:function(e){return e.split(/\r\n?|\n/)},Pe=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(e){return!1}}:function(e){var t;try{t=e.ownerDocument.selection.createRange()}catch(e){}return!(!t||t.parentElement()!=e)&&0!=t.compareEndPoints("StartToEnd",t)},Re="oncopy"in(Le=M("div"))||(Le.setAttribute("oncopy","return;"),"function"==typeof Le.oncopy),De=null,Ie={},Ne={};function ze(e,t){arguments.length>2&&(t.dependencies=Array.prototype.slice.call(arguments,2)),Ie[e]=t}function Fe(e){if("string"==typeof e&&Ne.hasOwnProperty(e))e=Ne[e];else if(e&&"string"==typeof e.name&&Ne.hasOwnProperty(e.name)){var t=Ne[e.name];"string"==typeof t&&(t={name:t}),(e=Q(t,e)).name=t.name}else{if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+xml$/.test(e))return Fe("application/xml");if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+json$/.test(e))return Fe("application/json")}return"string"==typeof e?{name:e}:e||{name:"null"}}function Be(e,t){t=Fe(t);var n=Ie[t.name];if(!n)return Be(e,"text/plain");var r=n(e,t);if(He.hasOwnProperty(t.name)){var o=He[t.name];for(var i in o)o.hasOwnProperty(i)&&(r.hasOwnProperty(i)&&(r["_"+i]=r[i]),r[i]=o[i])}if(r.name=t.name,t.helperType&&(r.helperType=t.helperType),t.modeProps)for(var a in t.modeProps)r[a]=t.modeProps[a];return r}var He={};function Ue(e,t){z(t,He.hasOwnProperty(e)?He[e]:He[e]={})}function We(e,t){if(!0===t)return t;if(e.copyState)return e.copyState(t);var n={};for(var r in t){var o=t[r];o instanceof Array&&(o=o.concat([])),n[r]=o}return n}function Ve(e,t){for(var n;e.innerMode&&(n=e.innerMode(t))&&n.mode!=e;)t=n.state,e=n.mode;return n||{mode:e,state:t}}function qe(e,t,n){return!e.startState||e.startState(t,n)}var Ye=function(e,t,n){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};function Ge(e,t){if((t-=e.first)<0||t>=e.size)throw new Error("There is no line "+(t+e.first)+" in the document.");for(var n=e;!n.lines;)for(var r=0;;++r){var o=n.children[r],i=o.chunkSize();if(t<i){n=o;break}t-=i}return n.lines[t]}function $e(e,t,n){var r=[],o=t.line;return e.iter(t.line,n.line+1,(function(e){var i=e.text;o==n.line&&(i=i.slice(0,n.ch)),o==t.line&&(i=i.slice(t.ch)),r.push(i),++o})),r}function Ke(e,t,n){var r=[];return e.iter(t,n,(function(e){r.push(e.text)})),r}function Ze(e,t){var n=t-e.height;if(n)for(var r=e;r;r=r.parent)r.height+=n}function Xe(e){if(null==e.parent)return null;for(var t=e.parent,n=H(t.lines,e),r=t.parent;r;t=r,r=r.parent)for(var o=0;r.children[o]!=t;++o)n+=r.children[o].chunkSize();return n+t.first}function Qe(e,t){var n=e.first;e:do{for(var r=0;r<e.children.length;++r){var o=e.children[r],i=o.height;if(t<i){e=o;continue e}t-=i,n+=o.chunkSize()}return n}while(!e.lines);for(var a=0;a<e.lines.length;++a){var s=e.lines[a].height;if(t<s)break;t-=s}return n+a}function Je(e,t){return t>=e.first&&t<e.first+e.size}function et(e,t){return String(e.lineNumberFormatter(t+e.firstLineNumber))}function tt(e,t,n){if(void 0===n&&(n=null),!(this instanceof tt))return new tt(e,t,n);this.line=e,this.ch=t,this.sticky=n}function nt(e,t){return e.line-t.line||e.ch-t.ch}function rt(e,t){return e.sticky==t.sticky&&0==nt(e,t)}function ot(e){return tt(e.line,e.ch)}function it(e,t){return nt(e,t)<0?t:e}function at(e,t){return nt(e,t)<0?e:t}function st(e,t){return Math.max(e.first,Math.min(t,e.first+e.size-1))}function ut(e,t){if(t.line<e.first)return tt(e.first,0);var n=e.first+e.size-1;return t.line>n?tt(n,Ge(e,n).text.length):function(e,t){var n=e.ch;return null==n||n>t?tt(e.line,t):n<0?tt(e.line,0):e}(t,Ge(e,t.line).text.length)}function lt(e,t){for(var n=[],r=0;r<t.length;r++)n[r]=ut(e,t[r]);return n}Ye.prototype.eol=function(){return this.pos>=this.string.length},Ye.prototype.sol=function(){return this.pos==this.lineStart},Ye.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Ye.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},Ye.prototype.eat=function(e){var t=this.string.charAt(this.pos);if("string"==typeof e?t==e:t&&(e.test?e.test(t):e(t)))return++this.pos,t},Ye.prototype.eatWhile=function(e){for(var t=this.pos;this.eat(e););return this.pos>t},Ye.prototype.eatSpace=function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},Ye.prototype.skipToEnd=function(){this.pos=this.string.length},Ye.prototype.skipTo=function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},Ye.prototype.backUp=function(e){this.pos-=e},Ye.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=F(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?F(this.string,this.lineStart,this.tabSize):0)},Ye.prototype.indentation=function(){return F(this.string,null,this.tabSize)-(this.lineStart?F(this.string,this.lineStart,this.tabSize):0)},Ye.prototype.match=function(e,t,n){if("string"!=typeof e){var r=this.string.slice(this.pos).match(e);return r&&r.index>0?null:(r&&!1!==t&&(this.pos+=r[0].length),r)}var o=function(e){return n?e.toLowerCase():e};if(o(this.string.substr(this.pos,e.length))==o(e))return!1!==t&&(this.pos+=e.length),!0},Ye.prototype.current=function(){return this.string.slice(this.start,this.pos)},Ye.prototype.hideFirstChars=function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}},Ye.prototype.lookAhead=function(e){var t=this.lineOracle;return t&&t.lookAhead(e)},Ye.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};var ct=function(e,t){this.state=e,this.lookAhead=t},ft=function(e,t,n,r){this.state=t,this.doc=e,this.line=n,this.maxLookAhead=r||0,this.baseTokens=null,this.baseTokenPos=1};function dt(e,t,n,r){var o=[e.state.modeGen],i={};_t(e,t.text,e.doc.mode,n,(function(e,t){return o.push(e,t)}),i,r);for(var a=n.state,s=function(r){n.baseTokens=o;var s=e.state.overlays[r],u=1,l=0;n.state=!0,_t(e,t.text,s.mode,n,(function(e,t){for(var n=u;l<e;){var r=o[u];r>e&&o.splice(u,1,e,o[u+1],r),u+=2,l=Math.min(e,r)}if(t)if(s.opaque)o.splice(n,u-n,e,"overlay "+t),u=n+2;else for(;n<u;n+=2){var i=o[n+1];o[n+1]=(i?i+" ":"")+"overlay "+t}}),i),n.state=a,n.baseTokens=null,n.baseTokenPos=1},u=0;u<e.state.overlays.length;++u)s(u);return{styles:o,classes:i.bgClass||i.textClass?i:null}}function pt(e,t,n){if(!t.styles||t.styles[0]!=e.state.modeGen){var r=ht(e,Xe(t)),o=t.text.length>e.options.maxHighlightLength&&We(e.doc.mode,r.state),i=dt(e,t,r);o&&(r.state=o),t.stateAfter=r.save(!o),t.styles=i.styles,i.classes?t.styleClasses=i.classes:t.styleClasses&&(t.styleClasses=null),n===e.doc.highlightFrontier&&(e.doc.modeFrontier=Math.max(e.doc.modeFrontier,++e.doc.highlightFrontier))}return t.styles}function ht(e,t,n){var r=e.doc,o=e.display;if(!r.mode.startState)return new ft(r,!0,t);var i=function(e,t,n){for(var r,o,i=e.doc,a=n?-1:t-(e.doc.mode.innerMode?1e3:100),s=t;s>a;--s){if(s<=i.first)return i.first;var u=Ge(i,s-1),l=u.stateAfter;if(l&&(!n||s+(l instanceof ct?l.lookAhead:0)<=i.modeFrontier))return s;var c=F(u.text,null,e.options.tabSize);(null==o||r>c)&&(o=s-1,r=c)}return o}(e,t,n),a=i>r.first&&Ge(r,i-1).stateAfter,s=a?ft.fromSaved(r,a,i):new ft(r,qe(r.mode),i);return r.iter(i,t,(function(n){vt(e,n.text,s);var r=s.line;n.stateAfter=r==t-1||r%5==0||r>=o.viewFrom&&r<o.viewTo?s.save():null,s.nextLine()})),n&&(r.modeFrontier=s.line),s}function vt(e,t,n,r){var o=e.doc.mode,i=new Ye(t,e.options.tabSize,n);for(i.start=i.pos=r||0,""==t&>(o,n.state);!i.eol();)mt(o,i,n.state),i.start=i.pos}function gt(e,t){if(e.blankLine)return e.blankLine(t);if(e.innerMode){var n=Ve(e,t);return n.mode.blankLine?n.mode.blankLine(n.state):void 0}}function mt(e,t,n,r){for(var o=0;o<10;o++){r&&(r[0]=Ve(e,n).mode);var i=e.token(t,n);if(t.pos>t.start)return i}throw new Error("Mode "+e.name+" failed to advance stream.")}ft.prototype.lookAhead=function(e){var t=this.doc.getLine(this.line+e);return null!=t&&e>this.maxLookAhead&&(this.maxLookAhead=e),t},ft.prototype.baseToken=function(e){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)this.baseTokenPos+=2;var t=this.baseTokens[this.baseTokenPos+1];return{type:t&&t.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},ft.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},ft.fromSaved=function(e,t,n){return t instanceof ct?new ft(e,We(e.mode,t.state),n,t.lookAhead):new ft(e,We(e.mode,t),n)},ft.prototype.save=function(e){var t=!1!==e?We(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new ct(t,this.maxLookAhead):t};var yt=function(e,t,n){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=t||null,this.state=n};function bt(e,t,n,r){var o,i,a=e.doc,s=a.mode,u=Ge(a,(t=ut(a,t)).line),l=ht(e,t.line,n),c=new Ye(u.text,e.options.tabSize,l);for(r&&(i=[]);(r||c.pos<t.ch)&&!c.eol();)c.start=c.pos,o=mt(s,c,l.state),r&&i.push(new yt(c,o,We(a.mode,l.state)));return r?i:new yt(c,o,l.state)}function wt(e,t){if(e)for(;;){var n=e.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!n)break;e=e.slice(0,n.index)+e.slice(n.index+n[0].length);var r=n[1]?"bgClass":"textClass";null==t[r]?t[r]=n[2]:new RegExp("(?:^|\\s)"+n[2]+"(?:$|\\s)").test(t[r])||(t[r]+=" "+n[2])}return e}function _t(e,t,n,r,o,i,a){var s=n.flattenSpans;null==s&&(s=e.options.flattenSpans);var u,l=0,c=null,f=new Ye(t,e.options.tabSize,r),d=e.options.addModeClass&&[null];for(""==t&&wt(gt(n,r.state),i);!f.eol();){if(f.pos>e.options.maxHighlightLength?(s=!1,a&&vt(e,t,r,f.pos),f.pos=t.length,u=null):u=wt(mt(n,f,r.state,d),i),d){var p=d[0].name;p&&(u="m-"+(u?p+" "+u:p))}if(!s||c!=u){for(;l<f.start;)o(l=Math.min(f.start,l+5e3),c);c=u}f.start=f.pos}for(;l<f.pos;){var h=Math.min(f.pos,l+5e3);o(h,c),l=h}}var xt=!1,kt=!1;function Ct(e,t,n){this.marker=e,this.from=t,this.to=n}function Ot(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];if(r.marker==t)return r}}function Et(e,t){for(var n,r=0;r<e.length;++r)e[r]!=t&&(n||(n=[])).push(e[r]);return n}function St(e,t){if(t.full)return null;var n=Je(e,t.from.line)&&Ge(e,t.from.line).markedSpans,r=Je(e,t.to.line)&&Ge(e,t.to.line).markedSpans;if(!n&&!r)return null;var o=t.from.ch,i=t.to.ch,a=0==nt(t.from,t.to),s=function(e,t,n){var r;if(e)for(var o=0;o<e.length;++o){var i=e[o],a=i.marker;if(null==i.from||(a.inclusiveLeft?i.from<=t:i.from<t)||i.from==t&&"bookmark"==a.type&&(!n||!i.marker.insertLeft)){var s=null==i.to||(a.inclusiveRight?i.to>=t:i.to>t);(r||(r=[])).push(new Ct(a,i.from,s?null:i.to))}}return r}(n,o,a),u=function(e,t,n){var r;if(e)for(var o=0;o<e.length;++o){var i=e[o],a=i.marker;if(null==i.to||(a.inclusiveRight?i.to>=t:i.to>t)||i.from==t&&"bookmark"==a.type&&(!n||i.marker.insertLeft)){var s=null==i.from||(a.inclusiveLeft?i.from<=t:i.from<t);(r||(r=[])).push(new Ct(a,s?null:i.from-t,null==i.to?null:i.to-t))}}return r}(r,i,a),l=1==t.text.length,c=K(t.text).length+(l?o:0);if(s)for(var f=0;f<s.length;++f){var d=s[f];if(null==d.to){var p=Ot(u,d.marker);p?l&&(d.to=null==p.to?null:p.to+c):d.to=o}}if(u)for(var h=0;h<u.length;++h){var v=u[h];null!=v.to&&(v.to+=c),null==v.from?Ot(s,v.marker)||(v.from=c,l&&(s||(s=[])).push(v)):(v.from+=c,l&&(s||(s=[])).push(v))}s&&(s=Tt(s)),u&&u!=s&&(u=Tt(u));var g=[s];if(!l){var m,y=t.text.length-2;if(y>0&&s)for(var b=0;b<s.length;++b)null==s[b].to&&(m||(m=[])).push(new Ct(s[b].marker,null,null));for(var w=0;w<y;++w)g.push(m);g.push(u)}return g}function Tt(e){for(var t=0;t<e.length;++t){var n=e[t];null!=n.from&&n.from==n.to&&!1!==n.marker.clearWhenEmpty&&e.splice(t--,1)}return e.length?e:null}function jt(e){var t=e.markedSpans;if(t){for(var n=0;n<t.length;++n)t[n].marker.detachLine(e);e.markedSpans=null}}function Mt(e,t){if(t){for(var n=0;n<t.length;++n)t[n].marker.attachLine(e);e.markedSpans=t}}function Lt(e){return e.inclusiveLeft?-1:0}function At(e){return e.inclusiveRight?1:0}function Pt(e,t){var n=e.lines.length-t.lines.length;if(0!=n)return n;var r=e.find(),o=t.find(),i=nt(r.from,o.from)||Lt(e)-Lt(t);if(i)return-i;var a=nt(r.to,o.to)||At(e)-At(t);return a||t.id-e.id}function Rt(e,t){var n,r=kt&&e.markedSpans;if(r)for(var o=void 0,i=0;i<r.length;++i)(o=r[i]).marker.collapsed&&null==(t?o.from:o.to)&&(!n||Pt(n,o.marker)<0)&&(n=o.marker);return n}function Dt(e){return Rt(e,!0)}function It(e){return Rt(e,!1)}function Nt(e,t){var n,r=kt&&e.markedSpans;if(r)for(var o=0;o<r.length;++o){var i=r[o];i.marker.collapsed&&(null==i.from||i.from<t)&&(null==i.to||i.to>t)&&(!n||Pt(n,i.marker)<0)&&(n=i.marker)}return n}function zt(e,t,n,r,o){var i=Ge(e,t),a=kt&&i.markedSpans;if(a)for(var s=0;s<a.length;++s){var u=a[s];if(u.marker.collapsed){var l=u.marker.find(0),c=nt(l.from,n)||Lt(u.marker)-Lt(o),f=nt(l.to,r)||At(u.marker)-At(o);if(!(c>=0&&f<=0||c<=0&&f>=0)&&(c<=0&&(u.marker.inclusiveRight&&o.inclusiveLeft?nt(l.to,n)>=0:nt(l.to,n)>0)||c>=0&&(u.marker.inclusiveRight&&o.inclusiveLeft?nt(l.from,r)<=0:nt(l.from,r)<0)))return!0}}}function Ft(e){for(var t;t=Dt(e);)e=t.find(-1,!0).line;return e}function Bt(e,t){var n=Ge(e,t),r=Ft(n);return n==r?t:Xe(r)}function Ht(e,t){if(t>e.lastLine())return t;var n,r=Ge(e,t);if(!Ut(e,r))return t;for(;n=It(r);)r=n.find(1,!0).line;return Xe(r)+1}function Ut(e,t){var n=kt&&t.markedSpans;if(n)for(var r=void 0,o=0;o<n.length;++o)if((r=n[o]).marker.collapsed){if(null==r.from)return!0;if(!r.marker.widgetNode&&0==r.from&&r.marker.inclusiveLeft&&Wt(e,t,r))return!0}}function Wt(e,t,n){if(null==n.to){var r=n.marker.find(1,!0);return Wt(e,r.line,Ot(r.line.markedSpans,n.marker))}if(n.marker.inclusiveRight&&n.to==t.text.length)return!0;for(var o=void 0,i=0;i<t.markedSpans.length;++i)if((o=t.markedSpans[i]).marker.collapsed&&!o.marker.widgetNode&&o.from==n.to&&(null==o.to||o.to!=n.from)&&(o.marker.inclusiveLeft||n.marker.inclusiveRight)&&Wt(e,t,o))return!0}function Vt(e){for(var t=0,n=(e=Ft(e)).parent,r=0;r<n.lines.length;++r){var o=n.lines[r];if(o==e)break;t+=o.height}for(var i=n.parent;i;i=(n=i).parent)for(var a=0;a<i.children.length;++a){var s=i.children[a];if(s==n)break;t+=s.height}return t}function qt(e){if(0==e.height)return 0;for(var t,n=e.text.length,r=e;t=Dt(r);){var o=t.find(0,!0);r=o.from.line,n+=o.from.ch-o.to.ch}for(r=e;t=It(r);){var i=t.find(0,!0);n-=r.text.length-i.from.ch,n+=(r=i.to.line).text.length-i.to.ch}return n}function Yt(e){var t=e.display,n=e.doc;t.maxLine=Ge(n,n.first),t.maxLineLength=qt(t.maxLine),t.maxLineChanged=!0,n.iter((function(e){var n=qt(e);n>t.maxLineLength&&(t.maxLineLength=n,t.maxLine=e)}))}var Gt=function(e,t,n){this.text=e,Mt(this,t),this.height=n?n(this):1};function $t(e){e.parent=null,jt(e)}Gt.prototype.lineNo=function(){return Xe(this)},be(Gt);var Kt={},Zt={};function Xt(e,t){if(!e||/^\s*$/.test(e))return null;var n=t.addModeClass?Zt:Kt;return n[e]||(n[e]=e.replace(/\S+/g,"cm-$&"))}function Qt(e,t){var n=L("span",null,null,u?"padding-right: .1px":null),r={pre:L("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:e,trailingSpace:!1,splitSpaces:e.getOption("lineWrapping")};t.measure={};for(var o=0;o<=(t.rest?t.rest.length:0);o++){var i=o?t.rest[o-1]:t.line,a=void 0;r.pos=0,r.addToken=en,Me(e.display.measure)&&(a=ce(i,e.doc.direction))&&(r.addToken=tn(r.addToken,a)),r.map=[],rn(i,r,pt(e,i,t!=e.display.externalMeasured&&Xe(i))),i.styleClasses&&(i.styleClasses.bgClass&&(r.bgClass=D(i.styleClasses.bgClass,r.bgClass||"")),i.styleClasses.textClass&&(r.textClass=D(i.styleClasses.textClass,r.textClass||""))),0==r.map.length&&r.map.push(0,0,r.content.appendChild(je(e.display.measure))),0==o?(t.measure.map=r.map,t.measure.cache={}):((t.measure.maps||(t.measure.maps=[])).push(r.map),(t.measure.caches||(t.measure.caches=[])).push({}))}if(u){var s=r.content.lastChild;(/\bcm-tab\b/.test(s.className)||s.querySelector&&s.querySelector(".cm-tab"))&&(r.content.className="cm-tab-wrap-hack")}return ve(e,"renderLine",e,t.line,r.pre),r.pre.className&&(r.textClass=D(r.pre.className,r.textClass||"")),r}function Jt(e){var t=M("span","\u2022","cm-invalidchar");return t.title="\\u"+e.charCodeAt(0).toString(16),t.setAttribute("aria-label",t.title),t}function en(e,t,n,r,o,i,u){if(t){var l,c=e.splitSpaces?function(e,t){if(e.length>1&&!/ /.test(e))return e;for(var n=t,r="",o=0;o<e.length;o++){var i=e.charAt(o);" "!=i||!n||o!=e.length-1&&32!=e.charCodeAt(o+1)||(i="\xa0"),r+=i,n=" "==i}return r}(t,e.trailingSpace):t,f=e.cm.state.specialChars,d=!1;if(f.test(t)){l=document.createDocumentFragment();for(var p=0;;){f.lastIndex=p;var h=f.exec(t),v=h?h.index-p:t.length-p;if(v){var g=document.createTextNode(c.slice(p,p+v));a&&s<9?l.appendChild(M("span",[g])):l.appendChild(g),e.map.push(e.pos,e.pos+v,g),e.col+=v,e.pos+=v}if(!h)break;p+=v+1;var m=void 0;if("\t"==h[0]){var y=e.cm.options.tabSize,b=y-e.col%y;(m=l.appendChild(M("span",$(b),"cm-tab"))).setAttribute("role","presentation"),m.setAttribute("cm-text","\t"),e.col+=b}else"\r"==h[0]||"\n"==h[0]?((m=l.appendChild(M("span","\r"==h[0]?"\u240d":"\u2424","cm-invalidchar"))).setAttribute("cm-text",h[0]),e.col+=1):((m=e.cm.options.specialCharPlaceholder(h[0])).setAttribute("cm-text",h[0]),a&&s<9?l.appendChild(M("span",[m])):l.appendChild(m),e.col+=1);e.map.push(e.pos,e.pos+1,m),e.pos++}}else e.col+=t.length,l=document.createTextNode(c),e.map.push(e.pos,e.pos+t.length,l),a&&s<9&&(d=!0),e.pos+=t.length;if(e.trailingSpace=32==c.charCodeAt(t.length-1),n||r||o||d||i||u){var w=n||"";r&&(w+=r),o&&(w+=o);var _=M("span",[l],w,i);if(u)for(var x in u)u.hasOwnProperty(x)&&"style"!=x&&"class"!=x&&_.setAttribute(x,u[x]);return e.content.appendChild(_)}e.content.appendChild(l)}}function tn(e,t){return function(n,r,o,i,a,s,u){o=o?o+" cm-force-border":"cm-force-border";for(var l=n.pos,c=l+r.length;;){for(var f=void 0,d=0;d<t.length&&!((f=t[d]).to>l&&f.from<=l);d++);if(f.to>=c)return e(n,r,o,i,a,s,u);e(n,r.slice(0,f.to-l),o,i,null,s,u),i=null,r=r.slice(f.to-l),l=f.to}}}function nn(e,t,n,r){var o=!r&&n.widgetNode;o&&e.map.push(e.pos,e.pos+t,o),!r&&e.cm.display.input.needsContentAttribute&&(o||(o=e.content.appendChild(document.createElement("span"))),o.setAttribute("cm-marker",n.id)),o&&(e.cm.display.input.setUneditable(o),e.content.appendChild(o)),e.pos+=t,e.trailingSpace=!1}function rn(e,t,n){var r=e.markedSpans,o=e.text,i=0;if(r)for(var a,s,u,l,c,f,d,p=o.length,h=0,v=1,g="",m=0;;){if(m==h){u=l=c=s="",d=null,f=null,m=1/0;for(var y=[],b=void 0,w=0;w<r.length;++w){var _=r[w],x=_.marker;if("bookmark"==x.type&&_.from==h&&x.widgetNode)y.push(x);else if(_.from<=h&&(null==_.to||_.to>h||x.collapsed&&_.to==h&&_.from==h)){if(null!=_.to&&_.to!=h&&m>_.to&&(m=_.to,l=""),x.className&&(u+=" "+x.className),x.css&&(s=(s?s+";":"")+x.css),x.startStyle&&_.from==h&&(c+=" "+x.startStyle),x.endStyle&&_.to==m&&(b||(b=[])).push(x.endStyle,_.to),x.title&&((d||(d={})).title=x.title),x.attributes)for(var k in x.attributes)(d||(d={}))[k]=x.attributes[k];x.collapsed&&(!f||Pt(f.marker,x)<0)&&(f=_)}else _.from>h&&m>_.from&&(m=_.from)}if(b)for(var C=0;C<b.length;C+=2)b[C+1]==m&&(l+=" "+b[C]);if(!f||f.from==h)for(var O=0;O<y.length;++O)nn(t,0,y[O]);if(f&&(f.from||0)==h){if(nn(t,(null==f.to?p+1:f.to)-h,f.marker,null==f.from),null==f.to)return;f.to==h&&(f=!1)}}if(h>=p)break;for(var E=Math.min(p,m);;){if(g){var S=h+g.length;if(!f){var T=S>E?g.slice(0,E-h):g;t.addToken(t,T,a?a+u:u,c,h+T.length==m?l:"",s,d)}if(S>=E){g=g.slice(E-h),h=E;break}h=S,c=""}g=o.slice(i,i=n[v++]),a=Xt(n[v++],t.cm.options)}}else for(var j=1;j<n.length;j+=2)t.addToken(t,o.slice(i,i=n[j]),Xt(n[j+1],t.cm.options))}function on(e,t,n){this.line=t,this.rest=function(e){for(var t,n;t=It(e);)e=t.find(1,!0).line,(n||(n=[])).push(e);return n}(t),this.size=this.rest?Xe(K(this.rest))-n+1:1,this.node=this.text=null,this.hidden=Ut(e,t)}function an(e,t,n){for(var r,o=[],i=t;i<n;i=r){var a=new on(e.doc,Ge(e.doc,i),i);r=i+a.size,o.push(a)}return o}var sn=null,un=null;function ln(e,t){var n=pe(e,t);if(n.length){var r,o=Array.prototype.slice.call(arguments,2);sn?r=sn.delayedCallbacks:un?r=un:(r=un=[],setTimeout(cn,0));for(var i=function(e){r.push((function(){return n[e].apply(null,o)}))},a=0;a<n.length;++a)i(a)}}function cn(){var e=un;un=null;for(var t=0;t<e.length;++t)e[t]()}function fn(e,t,n,r){for(var o=0;o<t.changes.length;o++){var i=t.changes[o];"text"==i?hn(e,t):"gutter"==i?gn(e,t,n,r):"class"==i?vn(e,t):"widget"==i&&mn(e,t,r)}t.changes=null}function dn(e){return e.node==e.text&&(e.node=M("div",null,null,"position: relative"),e.text.parentNode&&e.text.parentNode.replaceChild(e.node,e.text),e.node.appendChild(e.text),a&&s<8&&(e.node.style.zIndex=2)),e.node}function pn(e,t){var n=e.display.externalMeasured;return n&&n.line==t.line?(e.display.externalMeasured=null,t.measure=n.measure,n.built):Qt(e,t)}function hn(e,t){var n=t.text.className,r=pn(e,t);t.text==t.node&&(t.node=r.pre),t.text.parentNode.replaceChild(r.pre,t.text),t.text=r.pre,r.bgClass!=t.bgClass||r.textClass!=t.textClass?(t.bgClass=r.bgClass,t.textClass=r.textClass,vn(e,t)):n&&(t.text.className=n)}function vn(e,t){!function(e,t){var n=t.bgClass?t.bgClass+" "+(t.line.bgClass||""):t.line.bgClass;if(n&&(n+=" CodeMirror-linebackground"),t.background)n?t.background.className=n:(t.background.parentNode.removeChild(t.background),t.background=null);else if(n){var r=dn(t);t.background=r.insertBefore(M("div",null,n),r.firstChild),e.display.input.setUneditable(t.background)}}(e,t),t.line.wrapClass?dn(t).className=t.line.wrapClass:t.node!=t.text&&(t.node.className="");var n=t.textClass?t.textClass+" "+(t.line.textClass||""):t.line.textClass;t.text.className=n||""}function gn(e,t,n,r){if(t.gutter&&(t.node.removeChild(t.gutter),t.gutter=null),t.gutterBackground&&(t.node.removeChild(t.gutterBackground),t.gutterBackground=null),t.line.gutterClass){var o=dn(t);t.gutterBackground=M("div",null,"CodeMirror-gutter-background "+t.line.gutterClass,"left: "+(e.options.fixedGutter?r.fixedPos:-r.gutterTotalWidth)+"px; width: "+r.gutterTotalWidth+"px"),e.display.input.setUneditable(t.gutterBackground),o.insertBefore(t.gutterBackground,t.text)}var i=t.line.gutterMarkers;if(e.options.lineNumbers||i){var a=dn(t),s=t.gutter=M("div",null,"CodeMirror-gutter-wrapper","left: "+(e.options.fixedGutter?r.fixedPos:-r.gutterTotalWidth)+"px");if(s.setAttribute("aria-hidden","true"),e.display.input.setUneditable(s),a.insertBefore(s,t.text),t.line.gutterClass&&(s.className+=" "+t.line.gutterClass),!e.options.lineNumbers||i&&i["CodeMirror-linenumbers"]||(t.lineNumber=s.appendChild(M("div",et(e.options,n),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+r.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+e.display.lineNumInnerWidth+"px"))),i)for(var u=0;u<e.display.gutterSpecs.length;++u){var l=e.display.gutterSpecs[u].className,c=i.hasOwnProperty(l)&&i[l];c&&s.appendChild(M("div",[c],"CodeMirror-gutter-elt","left: "+r.gutterLeft[l]+"px; width: "+r.gutterWidth[l]+"px"))}}}function mn(e,t,n){t.alignable&&(t.alignable=null);for(var r=O("CodeMirror-linewidget"),o=t.node.firstChild,i=void 0;o;o=i)i=o.nextSibling,r.test(o.className)&&t.node.removeChild(o);bn(e,t,n)}function yn(e,t,n,r){var o=pn(e,t);return t.text=t.node=o.pre,o.bgClass&&(t.bgClass=o.bgClass),o.textClass&&(t.textClass=o.textClass),vn(e,t),gn(e,t,n,r),bn(e,t,r),t.node}function bn(e,t,n){if(wn(e,t.line,t,n,!0),t.rest)for(var r=0;r<t.rest.length;r++)wn(e,t.rest[r],t,n,!1)}function wn(e,t,n,r,o){if(t.widgets)for(var i=dn(n),a=0,s=t.widgets;a<s.length;++a){var u=s[a],l=M("div",[u.node],"CodeMirror-linewidget"+(u.className?" "+u.className:""));u.handleMouseEvents||l.setAttribute("cm-ignore-events","true"),_n(u,l,n,r),e.display.input.setUneditable(l),o&&u.above?i.insertBefore(l,n.gutter||n.text):i.appendChild(l),ln(u,"redraw")}}function _n(e,t,n,r){if(e.noHScroll){(n.alignable||(n.alignable=[])).push(t);var o=r.wrapperWidth;t.style.left=r.fixedPos+"px",e.coverGutter||(o-=r.gutterTotalWidth,t.style.paddingLeft=r.gutterTotalWidth+"px"),t.style.width=o+"px"}e.coverGutter&&(t.style.zIndex=5,t.style.position="relative",e.noHScroll||(t.style.marginLeft=-r.gutterTotalWidth+"px"))}function xn(e){if(null!=e.height)return e.height;var t=e.doc.cm;if(!t)return 0;if(!A(document.body,e.node)){var n="position: relative;";e.coverGutter&&(n+="margin-left: -"+t.display.gutters.offsetWidth+"px;"),e.noHScroll&&(n+="width: "+t.display.wrapper.clientWidth+"px;"),j(t.display.measure,M("div",[e.node],null,n))}return e.height=e.node.parentNode.offsetHeight}function kn(e,t){for(var n=Ce(t);n!=e.wrapper;n=n.parentNode)if(!n||1==n.nodeType&&"true"==n.getAttribute("cm-ignore-events")||n.parentNode==e.sizer&&n!=e.mover)return!0}function Cn(e){return e.lineSpace.offsetTop}function On(e){return e.mover.offsetHeight-e.lineSpace.offsetHeight}function En(e){if(e.cachedPaddingH)return e.cachedPaddingH;var t=j(e.measure,M("pre","x","CodeMirror-line-like")),n=window.getComputedStyle?window.getComputedStyle(t):t.currentStyle,r={left:parseInt(n.paddingLeft),right:parseInt(n.paddingRight)};return isNaN(r.left)||isNaN(r.right)||(e.cachedPaddingH=r),r}function Sn(e){return 50-e.display.nativeBarWidth}function Tn(e){return e.display.scroller.clientWidth-Sn(e)-e.display.barWidth}function jn(e){return e.display.scroller.clientHeight-Sn(e)-e.display.barHeight}function Mn(e,t,n){if(e.line==t)return{map:e.measure.map,cache:e.measure.cache};if(e.rest){for(var r=0;r<e.rest.length;r++)if(e.rest[r]==t)return{map:e.measure.maps[r],cache:e.measure.caches[r]};for(var o=0;o<e.rest.length;o++)if(Xe(e.rest[o])>n)return{map:e.measure.maps[o],cache:e.measure.caches[o],before:!0}}}function Ln(e,t,n,r){return Rn(e,Pn(e,t),n,r)}function An(e,t){if(t>=e.display.viewFrom&&t<e.display.viewTo)return e.display.view[fr(e,t)];var n=e.display.externalMeasured;return n&&t>=n.lineN&&t<n.lineN+n.size?n:void 0}function Pn(e,t){var n=Xe(t),r=An(e,n);r&&!r.text?r=null:r&&r.changes&&(fn(e,r,n,ar(e)),e.curOp.forceUpdate=!0),r||(r=function(e,t){var n=Xe(t=Ft(t)),r=e.display.externalMeasured=new on(e.doc,t,n);r.lineN=n;var o=r.built=Qt(e,r);return r.text=o.pre,j(e.display.lineMeasure,o.pre),r}(e,t));var o=Mn(r,t,n);return{line:t,view:r,rect:null,map:o.map,cache:o.cache,before:o.before,hasHeights:!1}}function Rn(e,t,n,r,o){t.before&&(n=-1);var i,u=n+(r||"");return t.cache.hasOwnProperty(u)?i=t.cache[u]:(t.rect||(t.rect=t.view.text.getBoundingClientRect()),t.hasHeights||(function(e,t,n){var r=e.options.lineWrapping,o=r&&Tn(e);if(!t.measure.heights||r&&t.measure.width!=o){var i=t.measure.heights=[];if(r){t.measure.width=o;for(var a=t.text.firstChild.getClientRects(),s=0;s<a.length-1;s++){var u=a[s],l=a[s+1];Math.abs(u.bottom-l.bottom)>2&&i.push((u.bottom+l.top)/2-n.top)}}i.push(n.bottom-n.top)}}(e,t.view,t.rect),t.hasHeights=!0),(i=function(e,t,n,r){var o,i=Nn(t.map,n,r),u=i.node,l=i.start,c=i.end,f=i.collapse;if(3==u.nodeType){for(var d=0;d<4;d++){for(;l&&oe(t.line.text.charAt(i.coverStart+l));)--l;for(;i.coverStart+c<i.coverEnd&&oe(t.line.text.charAt(i.coverStart+c));)++c;if((o=a&&s<9&&0==l&&c==i.coverEnd-i.coverStart?u.parentNode.getBoundingClientRect():zn(E(u,l,c).getClientRects(),r)).left||o.right||0==l)break;c=l,l-=1,f="right"}a&&s<11&&(o=function(e,t){if(!window.screen||null==screen.logicalXDPI||screen.logicalXDPI==screen.deviceXDPI||!function(e){if(null!=De)return De;var t=j(e,M("span","x")),n=t.getBoundingClientRect(),r=E(t,0,1).getBoundingClientRect();return De=Math.abs(n.left-r.left)>1}(e))return t;var n=screen.logicalXDPI/screen.deviceXDPI,r=screen.logicalYDPI/screen.deviceYDPI;return{left:t.left*n,right:t.right*n,top:t.top*r,bottom:t.bottom*r}}(e.display.measure,o))}else{var p;l>0&&(f=r="right"),o=e.options.lineWrapping&&(p=u.getClientRects()).length>1?p["right"==r?p.length-1:0]:u.getBoundingClientRect()}if(a&&s<9&&!l&&(!o||!o.left&&!o.right)){var h=u.parentNode.getClientRects()[0];o=h?{left:h.left,right:h.left+ir(e.display),top:h.top,bottom:h.bottom}:In}for(var v=o.top-t.rect.top,g=o.bottom-t.rect.top,m=(v+g)/2,y=t.view.measure.heights,b=0;b<y.length-1&&!(m<y[b]);b++);var w=b?y[b-1]:0,_=y[b],x={left:("right"==f?o.right:o.left)-t.rect.left,right:("left"==f?o.left:o.right)-t.rect.left,top:w,bottom:_};return o.left||o.right||(x.bogus=!0),e.options.singleCursorHeightPerLine||(x.rtop=v,x.rbottom=g),x}(e,t,n,r)).bogus||(t.cache[u]=i)),{left:i.left,right:i.right,top:o?i.rtop:i.top,bottom:o?i.rbottom:i.bottom}}var Dn,In={left:0,right:0,top:0,bottom:0};function Nn(e,t,n){for(var r,o,i,a,s,u,l=0;l<e.length;l+=3)if(s=e[l],u=e[l+1],t<s?(o=0,i=1,a="left"):t<u?i=1+(o=t-s):(l==e.length-3||t==u&&e[l+3]>t)&&(o=(i=u-s)-1,t>=u&&(a="right")),null!=o){if(r=e[l+2],s==u&&n==(r.insertLeft?"left":"right")&&(a=n),"left"==n&&0==o)for(;l&&e[l-2]==e[l-3]&&e[l-1].insertLeft;)r=e[2+(l-=3)],a="left";if("right"==n&&o==u-s)for(;l<e.length-3&&e[l+3]==e[l+4]&&!e[l+5].insertLeft;)r=e[(l+=3)+2],a="right";break}return{node:r,start:o,end:i,collapse:a,coverStart:s,coverEnd:u}}function zn(e,t){var n=In;if("left"==t)for(var r=0;r<e.length&&(n=e[r]).left==n.right;r++);else for(var o=e.length-1;o>=0&&(n=e[o]).left==n.right;o--);return n}function Fn(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var t=0;t<e.rest.length;t++)e.measure.caches[t]={}}function Bn(e){e.display.externalMeasure=null,T(e.display.lineMeasure);for(var t=0;t<e.display.view.length;t++)Fn(e.display.view[t])}function Hn(e){Bn(e),e.display.cachedCharWidth=e.display.cachedTextHeight=e.display.cachedPaddingH=null,e.options.lineWrapping||(e.display.maxLineChanged=!0),e.display.lineNumChars=null}function Un(){return c&&m?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function Wn(){return c&&m?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function Vn(e){var t=Ft(e).widgets,n=0;if(t)for(var r=0;r<t.length;++r)t[r].above&&(n+=xn(t[r]));return n}function qn(e,t,n,r,o){if(!o){var i=Vn(t);n.top+=i,n.bottom+=i}if("line"==r)return n;r||(r="local");var a=Vt(t);if("local"==r?a+=Cn(e.display):a-=e.display.viewOffset,"page"==r||"window"==r){var s=e.display.lineSpace.getBoundingClientRect();a+=s.top+("window"==r?0:Wn());var u=s.left+("window"==r?0:Un());n.left+=u,n.right+=u}return n.top+=a,n.bottom+=a,n}function Yn(e,t,n){if("div"==n)return t;var r=t.left,o=t.top;if("page"==n)r-=Un(),o-=Wn();else if("local"==n||!n){var i=e.display.sizer.getBoundingClientRect();r+=i.left,o+=i.top}var a=e.display.lineSpace.getBoundingClientRect();return{left:r-a.left,top:o-a.top}}function Gn(e,t,n,r,o){return r||(r=Ge(e.doc,t.line)),qn(e,r,Ln(e,r,t.ch,o),n)}function $n(e,t,n,r,o,i){function a(t,a){var s=Rn(e,o,t,a?"right":"left",i);return a?s.left=s.right:s.right=s.left,qn(e,r,s,n)}r=r||Ge(e.doc,t.line),o||(o=Pn(e,r));var s=ce(r,e.doc.direction),u=t.ch,l=t.sticky;if(u>=r.text.length?(u=r.text.length,l="before"):u<=0&&(u=0,l="after"),!s)return a("before"==l?u-1:u,"before"==l);function c(e,t,n){return a(n?e-1:e,1==s[t].level!=n)}var f=ue(s,u,l),d=se,p=c(u,f,"before"==l);return null!=d&&(p.other=c(u,d,"before"!=l)),p}function Kn(e,t){var n=0;t=ut(e.doc,t),e.options.lineWrapping||(n=ir(e.display)*t.ch);var r=Ge(e.doc,t.line),o=Vt(r)+Cn(e.display);return{left:n,right:n,top:o,bottom:o+r.height}}function Zn(e,t,n,r,o){var i=tt(e,t,n);return i.xRel=o,r&&(i.outside=r),i}function Xn(e,t,n){var r=e.doc;if((n+=e.display.viewOffset)<0)return Zn(r.first,0,null,-1,-1);var o=Qe(r,n),i=r.first+r.size-1;if(o>i)return Zn(r.first+r.size-1,Ge(r,i).text.length,null,1,1);t<0&&(t=0);for(var a=Ge(r,o);;){var s=tr(e,a,o,t,n),u=Nt(a,s.ch+(s.xRel>0||s.outside>0?1:0));if(!u)return s;var l=u.find(1);if(l.line==o)return l;a=Ge(r,o=l.line)}}function Qn(e,t,n,r){r-=Vn(t);var o=t.text.length,i=ae((function(t){return Rn(e,n,t-1).bottom<=r}),o,0);return{begin:i,end:o=ae((function(t){return Rn(e,n,t).top>r}),i,o)}}function Jn(e,t,n,r){return n||(n=Pn(e,t)),Qn(e,t,n,qn(e,t,Rn(e,n,r),"line").top)}function er(e,t,n,r){return!(e.bottom<=n)&&(e.top>n||(r?e.left:e.right)>t)}function tr(e,t,n,r,o){o-=Vt(t);var i=Pn(e,t),a=Vn(t),s=0,u=t.text.length,l=!0,c=ce(t,e.doc.direction);if(c){var f=(e.options.lineWrapping?rr:nr)(e,t,n,i,c,r,o);s=(l=1!=f.level)?f.from:f.to-1,u=l?f.to:f.from-1}var d,p,h=null,v=null,g=ae((function(t){var n=Rn(e,i,t);return n.top+=a,n.bottom+=a,!!er(n,r,o,!1)&&(n.top<=o&&n.left<=r&&(h=t,v=n),!0)}),s,u),m=!1;if(v){var y=r-v.left<v.right-r,b=y==l;g=h+(b?0:1),p=b?"after":"before",d=y?v.left:v.right}else{l||g!=u&&g!=s||g++,p=0==g?"after":g==t.text.length?"before":Rn(e,i,g-(l?1:0)).bottom+a<=o==l?"after":"before";var w=$n(e,tt(n,g,p),"line",t,i);d=w.left,m=o<w.top?-1:o>=w.bottom?1:0}return Zn(n,g=ie(t.text,g,1),p,m,r-d)}function nr(e,t,n,r,o,i,a){var s=ae((function(s){var u=o[s],l=1!=u.level;return er($n(e,tt(n,l?u.to:u.from,l?"before":"after"),"line",t,r),i,a,!0)}),0,o.length-1),u=o[s];if(s>0){var l=1!=u.level,c=$n(e,tt(n,l?u.from:u.to,l?"after":"before"),"line",t,r);er(c,i,a,!0)&&c.top>a&&(u=o[s-1])}return u}function rr(e,t,n,r,o,i,a){var s=Qn(e,t,r,a),u=s.begin,l=s.end;/\s/.test(t.text.charAt(l-1))&&l--;for(var c=null,f=null,d=0;d<o.length;d++){var p=o[d];if(!(p.from>=l||p.to<=u)){var h=Rn(e,r,1!=p.level?Math.min(l,p.to)-1:Math.max(u,p.from)).right,v=h<i?i-h+1e9:h-i;(!c||f>v)&&(c=p,f=v)}}return c||(c=o[o.length-1]),c.from<u&&(c={from:u,to:c.to,level:c.level}),c.to>l&&(c={from:c.from,to:l,level:c.level}),c}function or(e){if(null!=e.cachedTextHeight)return e.cachedTextHeight;if(null==Dn){Dn=M("pre",null,"CodeMirror-line-like");for(var t=0;t<49;++t)Dn.appendChild(document.createTextNode("x")),Dn.appendChild(M("br"));Dn.appendChild(document.createTextNode("x"))}j(e.measure,Dn);var n=Dn.offsetHeight/50;return n>3&&(e.cachedTextHeight=n),T(e.measure),n||1}function ir(e){if(null!=e.cachedCharWidth)return e.cachedCharWidth;var t=M("span","xxxxxxxxxx"),n=M("pre",[t],"CodeMirror-line-like");j(e.measure,n);var r=t.getBoundingClientRect(),o=(r.right-r.left)/10;return o>2&&(e.cachedCharWidth=o),o||10}function ar(e){for(var t=e.display,n={},r={},o=t.gutters.clientLeft,i=t.gutters.firstChild,a=0;i;i=i.nextSibling,++a){var s=e.display.gutterSpecs[a].className;n[s]=i.offsetLeft+i.clientLeft+o,r[s]=i.clientWidth}return{fixedPos:sr(t),gutterTotalWidth:t.gutters.offsetWidth,gutterLeft:n,gutterWidth:r,wrapperWidth:t.wrapper.clientWidth}}function sr(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function ur(e){var t=or(e.display),n=e.options.lineWrapping,r=n&&Math.max(5,e.display.scroller.clientWidth/ir(e.display)-3);return function(o){if(Ut(e.doc,o))return 0;var i=0;if(o.widgets)for(var a=0;a<o.widgets.length;a++)o.widgets[a].height&&(i+=o.widgets[a].height);return n?i+(Math.ceil(o.text.length/r)||1)*t:i+t}}function lr(e){var t=e.doc,n=ur(e);t.iter((function(e){var t=n(e);t!=e.height&&Ze(e,t)}))}function cr(e,t,n,r){var o=e.display;if(!n&&"true"==Ce(t).getAttribute("cm-not-content"))return null;var i,a,s=o.lineSpace.getBoundingClientRect();try{i=t.clientX-s.left,a=t.clientY-s.top}catch(e){return null}var u,l=Xn(e,i,a);if(r&&l.xRel>0&&(u=Ge(e.doc,l.line).text).length==l.ch){var c=F(u,u.length,e.options.tabSize)-u.length;l=tt(l.line,Math.max(0,Math.round((i-En(e.display).left)/ir(e.display))-c))}return l}function fr(e,t){if(t>=e.display.viewTo)return null;if((t-=e.display.viewFrom)<0)return null;for(var n=e.display.view,r=0;r<n.length;r++)if((t-=n[r].size)<0)return r}function dr(e,t,n,r){null==t&&(t=e.doc.first),null==n&&(n=e.doc.first+e.doc.size),r||(r=0);var o=e.display;if(r&&n<o.viewTo&&(null==o.updateLineNumbers||o.updateLineNumbers>t)&&(o.updateLineNumbers=t),e.curOp.viewChanged=!0,t>=o.viewTo)kt&&Bt(e.doc,t)<o.viewTo&&hr(e);else if(n<=o.viewFrom)kt&&Ht(e.doc,n+r)>o.viewFrom?hr(e):(o.viewFrom+=r,o.viewTo+=r);else if(t<=o.viewFrom&&n>=o.viewTo)hr(e);else if(t<=o.viewFrom){var i=vr(e,n,n+r,1);i?(o.view=o.view.slice(i.index),o.viewFrom=i.lineN,o.viewTo+=r):hr(e)}else if(n>=o.viewTo){var a=vr(e,t,t,-1);a?(o.view=o.view.slice(0,a.index),o.viewTo=a.lineN):hr(e)}else{var s=vr(e,t,t,-1),u=vr(e,n,n+r,1);s&&u?(o.view=o.view.slice(0,s.index).concat(an(e,s.lineN,u.lineN)).concat(o.view.slice(u.index)),o.viewTo+=r):hr(e)}var l=o.externalMeasured;l&&(n<l.lineN?l.lineN+=r:t<l.lineN+l.size&&(o.externalMeasured=null))}function pr(e,t,n){e.curOp.viewChanged=!0;var r=e.display,o=e.display.externalMeasured;if(o&&t>=o.lineN&&t<o.lineN+o.size&&(r.externalMeasured=null),!(t<r.viewFrom||t>=r.viewTo)){var i=r.view[fr(e,t)];if(null!=i.node){var a=i.changes||(i.changes=[]);-1==H(a,n)&&a.push(n)}}}function hr(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function vr(e,t,n,r){var o,i=fr(e,t),a=e.display.view;if(!kt||n==e.doc.first+e.doc.size)return{index:i,lineN:n};for(var s=e.display.viewFrom,u=0;u<i;u++)s+=a[u].size;if(s!=t){if(r>0){if(i==a.length-1)return null;o=s+a[i].size-t,i++}else o=s-t;t+=o,n+=o}for(;Bt(e.doc,n)!=n;){if(i==(r<0?0:a.length-1))return null;n+=r*a[i-(r<0?1:0)].size,i+=r}return{index:i,lineN:n}}function gr(e){for(var t=e.display.view,n=0,r=0;r<t.length;r++){var o=t[r];o.hidden||o.node&&!o.changes||++n}return n}function mr(e){e.display.input.showSelection(e.display.input.prepareSelection())}function yr(e,t){void 0===t&&(t=!0);var n=e.doc,r={},o=r.cursors=document.createDocumentFragment(),i=r.selection=document.createDocumentFragment(),a=e.options.$customCursor;a&&(t=!0);for(var s=0;s<n.sel.ranges.length;s++)if(t||s!=n.sel.primIndex){var u=n.sel.ranges[s];if(!(u.from().line>=e.display.viewTo||u.to().line<e.display.viewFrom)){var l=u.empty();if(a){var c=a(e,u);c&&br(e,c,o)}else(l||e.options.showCursorWhenSelecting)&&br(e,u.head,o);l||_r(e,u,i)}}return r}function br(e,t,n){var r=$n(e,t,"div",null,null,!e.options.singleCursorHeightPerLine),o=n.appendChild(M("div","\xa0","CodeMirror-cursor"));if(o.style.left=r.left+"px",o.style.top=r.top+"px",o.style.height=Math.max(0,r.bottom-r.top)*e.options.cursorHeight+"px",/\bcm-fat-cursor\b/.test(e.getWrapperElement().className)){var i=Gn(e,t,"div",null,null),a=i.right-i.left;o.style.width=(a>0?a:e.defaultCharWidth())+"px"}if(r.other){var s=n.appendChild(M("div","\xa0","CodeMirror-cursor CodeMirror-secondarycursor"));s.style.display="",s.style.left=r.other.left+"px",s.style.top=r.other.top+"px",s.style.height=.85*(r.other.bottom-r.other.top)+"px"}}function wr(e,t){return e.top-t.top||e.left-t.left}function _r(e,t,n){var r=e.display,o=e.doc,i=document.createDocumentFragment(),a=En(e.display),s=a.left,u=Math.max(r.sizerWidth,Tn(e)-r.sizer.offsetLeft)-a.right,l="ltr"==o.direction;function c(e,t,n,r){t<0&&(t=0),t=Math.round(t),r=Math.round(r),i.appendChild(M("div",null,"CodeMirror-selected","position: absolute; left: "+e+"px;\n top: "+t+"px; width: "+(null==n?u-e:n)+"px;\n height: "+(r-t)+"px"))}function f(t,n,r){var i,a,f=Ge(o,t),d=f.text.length;function p(n,r){return Gn(e,tt(t,n),"div",f,r)}function h(t,n,r){var o=Jn(e,f,null,t),i="ltr"==n==("after"==r)?"left":"right";return p("after"==r?o.begin:o.end-(/\s/.test(f.text.charAt(o.end-1))?2:1),i)[i]}var v=ce(f,o.direction);return function(e,t,n,r){if(!e)return r(t,n,"ltr",0);for(var o=!1,i=0;i<e.length;++i){var a=e[i];(a.from<n&&a.to>t||t==n&&a.to==t)&&(r(Math.max(a.from,t),Math.min(a.to,n),1==a.level?"rtl":"ltr",i),o=!0)}o||r(t,n,"ltr")}(v,n||0,null==r?d:r,(function(e,t,o,f){var g="ltr"==o,m=p(e,g?"left":"right"),y=p(t-1,g?"right":"left"),b=null==n&&0==e,w=null==r&&t==d,_=0==f,x=!v||f==v.length-1;if(y.top-m.top<=3){var k=(l?w:b)&&x,C=(l?b:w)&&_?s:(g?m:y).left,O=k?u:(g?y:m).right;c(C,m.top,O-C,m.bottom)}else{var E,S,T,j;g?(E=l&&b&&_?s:m.left,S=l?u:h(e,o,"before"),T=l?s:h(t,o,"after"),j=l&&w&&x?u:y.right):(E=l?h(e,o,"before"):s,S=!l&&b&&_?u:m.right,T=!l&&w&&x?s:y.left,j=l?h(t,o,"after"):u),c(E,m.top,S-E,m.bottom),m.bottom<y.top&&c(s,m.bottom,null,y.top),c(T,y.top,j-T,y.bottom)}(!i||wr(m,i)<0)&&(i=m),wr(y,i)<0&&(i=y),(!a||wr(m,a)<0)&&(a=m),wr(y,a)<0&&(a=y)})),{start:i,end:a}}var d=t.from(),p=t.to();if(d.line==p.line)f(d.line,d.ch,p.ch);else{var h=Ge(o,d.line),v=Ge(o,p.line),g=Ft(h)==Ft(v),m=f(d.line,d.ch,g?h.text.length+1:null).end,y=f(p.line,g?0:null,p.ch).start;g&&(m.top<y.top-2?(c(m.right,m.top,null,m.bottom),c(s,y.top,y.left,y.bottom)):c(m.right,m.top,y.left-m.right,m.bottom)),m.bottom<y.top&&c(s,m.bottom,null,y.top)}n.appendChild(i)}function xr(e){if(e.state.focused){var t=e.display;clearInterval(t.blinker);var n=!0;t.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?t.blinker=setInterval((function(){e.hasFocus()||Er(e),t.cursorDiv.style.visibility=(n=!n)?"":"hidden"}),e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function kr(e){e.hasFocus()||(e.display.input.focus(),e.state.focused||Or(e))}function Cr(e){e.state.delayingBlurEvent=!0,setTimeout((function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,e.state.focused&&Er(e))}),100)}function Or(e,t){e.state.delayingBlurEvent&&!e.state.draggingText&&(e.state.delayingBlurEvent=!1),"nocursor"!=e.options.readOnly&&(e.state.focused||(ve(e,"focus",e,t),e.state.focused=!0,R(e.display.wrapper,"CodeMirror-focused"),e.curOp||e.display.selForContextMenu==e.doc.sel||(e.display.input.reset(),u&&setTimeout((function(){return e.display.input.reset(!0)}),20)),e.display.input.receivedFocus()),xr(e))}function Er(e,t){e.state.delayingBlurEvent||(e.state.focused&&(ve(e,"blur",e,t),e.state.focused=!1,S(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout((function(){e.state.focused||(e.display.shift=!1)}),150))}function Sr(e){for(var t=e.display,n=t.lineDiv.offsetTop,r=Math.max(0,t.scroller.getBoundingClientRect().top),o=t.lineDiv.getBoundingClientRect().top,i=0,u=0;u<t.view.length;u++){var l=t.view[u],c=e.options.lineWrapping,f=void 0,d=0;if(!l.hidden){if(o+=l.line.height,a&&s<8){var p=l.node.offsetTop+l.node.offsetHeight;f=p-n,n=p}else{var h=l.node.getBoundingClientRect();f=h.bottom-h.top,!c&&l.text.firstChild&&(d=l.text.firstChild.getBoundingClientRect().right-h.left-1)}var v=l.line.height-f;if((v>.005||v<-.005)&&(o<r&&(i-=v),Ze(l.line,f),Tr(l.line),l.rest))for(var g=0;g<l.rest.length;g++)Tr(l.rest[g]);if(d>e.display.sizerWidth){var m=Math.ceil(d/ir(e.display));m>e.display.maxLineLength&&(e.display.maxLineLength=m,e.display.maxLine=l.line,e.display.maxLineChanged=!0)}}}Math.abs(i)>2&&(t.scroller.scrollTop+=i)}function Tr(e){if(e.widgets)for(var t=0;t<e.widgets.length;++t){var n=e.widgets[t],r=n.node.parentNode;r&&(n.height=r.offsetHeight)}}function jr(e,t,n){var r=n&&null!=n.top?Math.max(0,n.top):e.scroller.scrollTop;r=Math.floor(r-Cn(e));var o=n&&null!=n.bottom?n.bottom:r+e.wrapper.clientHeight,i=Qe(t,r),a=Qe(t,o);if(n&&n.ensure){var s=n.ensure.from.line,u=n.ensure.to.line;s<i?(i=s,a=Qe(t,Vt(Ge(t,s))+e.wrapper.clientHeight)):Math.min(u,t.lastLine())>=a&&(i=Qe(t,Vt(Ge(t,u))-e.wrapper.clientHeight),a=u)}return{from:i,to:Math.max(a,i+1)}}function Mr(e,t){var n=e.display,r=or(e.display);t.top<0&&(t.top=0);var o=e.curOp&&null!=e.curOp.scrollTop?e.curOp.scrollTop:n.scroller.scrollTop,i=jn(e),a={};t.bottom-t.top>i&&(t.bottom=t.top+i);var s=e.doc.height+On(n),u=t.top<r,l=t.bottom>s-r;if(t.top<o)a.scrollTop=u?0:t.top;else if(t.bottom>o+i){var c=Math.min(t.top,(l?s:t.bottom)-i);c!=o&&(a.scrollTop=c)}var f=e.options.fixedGutter?0:n.gutters.offsetWidth,d=e.curOp&&null!=e.curOp.scrollLeft?e.curOp.scrollLeft:n.scroller.scrollLeft-f,p=Tn(e)-n.gutters.offsetWidth,h=t.right-t.left>p;return h&&(t.right=t.left+p),t.left<10?a.scrollLeft=0:t.left<d?a.scrollLeft=Math.max(0,t.left+f-(h?0:10)):t.right>p+d-3&&(a.scrollLeft=t.right+(h?0:10)-p),a}function Lr(e,t){null!=t&&(Rr(e),e.curOp.scrollTop=(null==e.curOp.scrollTop?e.doc.scrollTop:e.curOp.scrollTop)+t)}function Ar(e){Rr(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function Pr(e,t,n){null==t&&null==n||Rr(e),null!=t&&(e.curOp.scrollLeft=t),null!=n&&(e.curOp.scrollTop=n)}function Rr(e){var t=e.curOp.scrollToPos;t&&(e.curOp.scrollToPos=null,Dr(e,Kn(e,t.from),Kn(e,t.to),t.margin))}function Dr(e,t,n,r){var o=Mr(e,{left:Math.min(t.left,n.left),top:Math.min(t.top,n.top)-r,right:Math.max(t.right,n.right),bottom:Math.max(t.bottom,n.bottom)+r});Pr(e,o.scrollLeft,o.scrollTop)}function Ir(e,t){Math.abs(e.doc.scrollTop-t)<2||(n||lo(e,{top:t}),Nr(e,t,!0),n&&lo(e),oo(e,100))}function Nr(e,t,n){t=Math.max(0,Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t)),(e.display.scroller.scrollTop!=t||n)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function zr(e,t,n,r){t=Math.max(0,Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth)),(n?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!r||(e.doc.scrollLeft=t,po(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function Fr(e){var t=e.display,n=t.gutters.offsetWidth,r=Math.round(e.doc.height+On(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?n:0,docHeight:r,scrollHeight:r+Sn(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:n}}var Br=function(e,t,n){this.cm=n;var r=this.vert=M("div",[M("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),o=this.horiz=M("div",[M("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");r.tabIndex=o.tabIndex=-1,e(r),e(o),de(r,"scroll",(function(){r.clientHeight&&t(r.scrollTop,"vertical")})),de(o,"scroll",(function(){o.clientWidth&&t(o.scrollLeft,"horizontal")})),this.checkedZeroWidth=!1,a&&s<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Br.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,n=e.scrollHeight>e.clientHeight+1,r=e.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=t?r+"px":"0";var o=e.viewHeight-(t?r:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+o)+"px"}else this.vert.scrollTop=0,this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=n?r+"px":"0",this.horiz.style.left=e.barLeft+"px";var i=e.viewWidth-e.barLeft-(n?r:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+i)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(0==r&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?r:0,bottom:t?r:0}},Br.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Br.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Br.prototype.zeroWidthHack=function(){var e=b&&!h?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new B,this.disableVert=new B},Br.prototype.enableZeroWidthBar=function(e,t,n){e.style.pointerEvents="auto",t.set(1e3,(function r(){var o=e.getBoundingClientRect();("vert"==n?document.elementFromPoint(o.right-1,(o.top+o.bottom)/2):document.elementFromPoint((o.right+o.left)/2,o.bottom-1))!=e?e.style.pointerEvents="none":t.set(1e3,r)}))},Br.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var Hr=function(){};function Ur(e,t){t||(t=Fr(e));var n=e.display.barWidth,r=e.display.barHeight;Wr(e,t);for(var o=0;o<4&&n!=e.display.barWidth||r!=e.display.barHeight;o++)n!=e.display.barWidth&&e.options.lineWrapping&&Sr(e),Wr(e,Fr(e)),n=e.display.barWidth,r=e.display.barHeight}function Wr(e,t){var n=e.display,r=n.scrollbars.update(t);n.sizer.style.paddingRight=(n.barWidth=r.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=r.bottom)+"px",n.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=r.bottom+"px",n.scrollbarFiller.style.width=r.right+"px"):n.scrollbarFiller.style.display="",r.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=r.bottom+"px",n.gutterFiller.style.width=t.gutterWidth+"px"):n.gutterFiller.style.display=""}Hr.prototype.update=function(){return{bottom:0,right:0}},Hr.prototype.setScrollLeft=function(){},Hr.prototype.setScrollTop=function(){},Hr.prototype.clear=function(){};var Vr={native:Br,null:Hr};function qr(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&S(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new Vr[e.options.scrollbarStyle]((function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),de(t,"mousedown",(function(){e.state.focused&&setTimeout((function(){return e.display.input.focus()}),0)})),t.setAttribute("cm-not-content","true")}),(function(t,n){"horizontal"==n?zr(e,t):Ir(e,t)}),e),e.display.scrollbars.addClass&&R(e.display.wrapper,e.display.scrollbars.addClass)}var Yr=0;function Gr(e){var t;e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Yr,markArrays:null},t=e.curOp,sn?sn.ops.push(t):t.ownsGroup=sn={ops:[t],delayedCallbacks:[]}}function $r(e){var t=e.curOp;t&&function(e,t){var n=e.ownsGroup;if(n)try{!function(e){var t=e.delayedCallbacks,n=0;do{for(;n<t.length;n++)t[n].call(null);for(var r=0;r<e.ops.length;r++){var o=e.ops[r];if(o.cursorActivityHandlers)for(;o.cursorActivityCalled<o.cursorActivityHandlers.length;)o.cursorActivityHandlers[o.cursorActivityCalled++].call(null,o.cm)}}while(n<t.length)}(n)}finally{sn=null,t(n)}}(t,(function(e){for(var t=0;t<e.ops.length;t++)e.ops[t].cm.curOp=null;!function(e){for(var t=e.ops,n=0;n<t.length;n++)Kr(t[n]);for(var r=0;r<t.length;r++)Zr(t[r]);for(var o=0;o<t.length;o++)Xr(t[o]);for(var i=0;i<t.length;i++)Qr(t[i]);for(var a=0;a<t.length;a++)Jr(t[a])}(e)}))}function Kr(e){var t=e.cm,n=t.display;!function(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=Sn(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=Sn(e)+"px",t.scrollbarsClipped=!0)}(t),e.updateMaxLine&&Yt(t),e.mustUpdate=e.viewChanged||e.forceUpdate||null!=e.scrollTop||e.scrollToPos&&(e.scrollToPos.from.line<n.viewFrom||e.scrollToPos.to.line>=n.viewTo)||n.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new ao(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function Zr(e){e.updatedDisplay=e.mustUpdate&&so(e.cm,e.update)}function Xr(e){var t=e.cm,n=t.display;e.updatedDisplay&&Sr(t),e.barMeasure=Fr(t),n.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=Ln(t,n.maxLine,n.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+e.adjustWidthTo+Sn(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+e.adjustWidthTo-Tn(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=n.input.prepareSelection())}function Qr(e){var t=e.cm;null!=e.adjustWidthTo&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&zr(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1);var n=e.focus&&e.focus==P();e.preparedSelection&&t.display.input.showSelection(e.preparedSelection,n),(e.updatedDisplay||e.startHeight!=t.doc.height)&&Ur(t,e.barMeasure),e.updatedDisplay&&fo(t,e.barMeasure),e.selectionChanged&&xr(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),n&&kr(e.cm)}function Jr(e){var t=e.cm,n=t.display,r=t.doc;e.updatedDisplay&&uo(t,e.update),null==n.wheelStartX||null==e.scrollTop&&null==e.scrollLeft&&!e.scrollToPos||(n.wheelStartX=n.wheelStartY=null),null!=e.scrollTop&&Nr(t,e.scrollTop,e.forceScroll),null!=e.scrollLeft&&zr(t,e.scrollLeft,!0,!0),e.scrollToPos&&function(e,t){if(!ge(e,"scrollCursorIntoView")){var n=e.display,r=n.sizer.getBoundingClientRect(),o=null;if(t.top+r.top<0?o=!0:t.bottom+r.top>(window.innerHeight||document.documentElement.clientHeight)&&(o=!1),null!=o&&!v){var i=M("div","\u200b",null,"position: absolute;\n top: "+(t.top-n.viewOffset-Cn(e.display))+"px;\n height: "+(t.bottom-t.top+Sn(e)+n.barHeight)+"px;\n left: "+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(i),i.scrollIntoView(o),e.display.lineSpace.removeChild(i)}}}(t,function(e,t,n,r){var o;null==r&&(r=0),e.options.lineWrapping||t!=n||(n="before"==t.sticky?tt(t.line,t.ch+1,"before"):t,t=t.ch?tt(t.line,"before"==t.sticky?t.ch-1:t.ch,"after"):t);for(var i=0;i<5;i++){var a=!1,s=$n(e,t),u=n&&n!=t?$n(e,n):s,l=Mr(e,o={left:Math.min(s.left,u.left),top:Math.min(s.top,u.top)-r,right:Math.max(s.left,u.left),bottom:Math.max(s.bottom,u.bottom)+r}),c=e.doc.scrollTop,f=e.doc.scrollLeft;if(null!=l.scrollTop&&(Ir(e,l.scrollTop),Math.abs(e.doc.scrollTop-c)>1&&(a=!0)),null!=l.scrollLeft&&(zr(e,l.scrollLeft),Math.abs(e.doc.scrollLeft-f)>1&&(a=!0)),!a)break}return o}(t,ut(r,e.scrollToPos.from),ut(r,e.scrollToPos.to),e.scrollToPos.margin));var o=e.maybeHiddenMarkers,i=e.maybeUnhiddenMarkers;if(o)for(var a=0;a<o.length;++a)o[a].lines.length||ve(o[a],"hide");if(i)for(var s=0;s<i.length;++s)i[s].lines.length&&ve(i[s],"unhide");n.wrapper.offsetHeight&&(r.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&ve(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function eo(e,t){if(e.curOp)return t();Gr(e);try{return t()}finally{$r(e)}}function to(e,t){return function(){if(e.curOp)return t.apply(e,arguments);Gr(e);try{return t.apply(e,arguments)}finally{$r(e)}}}function no(e){return function(){if(this.curOp)return e.apply(this,arguments);Gr(this);try{return e.apply(this,arguments)}finally{$r(this)}}}function ro(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);Gr(t);try{return e.apply(this,arguments)}finally{$r(t)}}}function oo(e,t){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(t,N(io,e))}function io(e){var t=e.doc;if(!(t.highlightFrontier>=e.display.viewTo)){var n=+new Date+e.options.workTime,r=ht(e,t.highlightFrontier),o=[];t.iter(r.line,Math.min(t.first+t.size,e.display.viewTo+500),(function(i){if(r.line>=e.display.viewFrom){var a=i.styles,s=i.text.length>e.options.maxHighlightLength?We(t.mode,r.state):null,u=dt(e,i,r,!0);s&&(r.state=s),i.styles=u.styles;var l=i.styleClasses,c=u.classes;c?i.styleClasses=c:l&&(i.styleClasses=null);for(var f=!a||a.length!=i.styles.length||l!=c&&(!l||!c||l.bgClass!=c.bgClass||l.textClass!=c.textClass),d=0;!f&&d<a.length;++d)f=a[d]!=i.styles[d];f&&o.push(r.line),i.stateAfter=r.save(),r.nextLine()}else i.text.length<=e.options.maxHighlightLength&&vt(e,i.text,r),i.stateAfter=r.line%5==0?r.save():null,r.nextLine();if(+new Date>n)return oo(e,e.options.workDelay),!0})),t.highlightFrontier=r.line,t.modeFrontier=Math.max(t.modeFrontier,r.line),o.length&&eo(e,(function(){for(var t=0;t<o.length;t++)pr(e,o[t],"text")}))}}var ao=function(e,t,n){var r=e.display;this.viewport=t,this.visible=jr(r,e.doc,t),this.editorIsHidden=!r.wrapper.offsetWidth,this.wrapperHeight=r.wrapper.clientHeight,this.wrapperWidth=r.wrapper.clientWidth,this.oldDisplayWidth=Tn(e),this.force=n,this.dims=ar(e),this.events=[]};function so(e,t){var n=e.display,r=e.doc;if(t.editorIsHidden)return hr(e),!1;if(!t.force&&t.visible.from>=n.viewFrom&&t.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==gr(e))return!1;ho(e)&&(hr(e),t.dims=ar(e));var o=r.first+r.size,i=Math.max(t.visible.from-e.options.viewportMargin,r.first),a=Math.min(o,t.visible.to+e.options.viewportMargin);n.viewFrom<i&&i-n.viewFrom<20&&(i=Math.max(r.first,n.viewFrom)),n.viewTo>a&&n.viewTo-a<20&&(a=Math.min(o,n.viewTo)),kt&&(i=Bt(e.doc,i),a=Ht(e.doc,a));var s=i!=n.viewFrom||a!=n.viewTo||n.lastWrapHeight!=t.wrapperHeight||n.lastWrapWidth!=t.wrapperWidth;!function(e,t,n){var r=e.display;0==r.view.length||t>=r.viewTo||n<=r.viewFrom?(r.view=an(e,t,n),r.viewFrom=t):(r.viewFrom>t?r.view=an(e,t,r.viewFrom).concat(r.view):r.viewFrom<t&&(r.view=r.view.slice(fr(e,t))),r.viewFrom=t,r.viewTo<n?r.view=r.view.concat(an(e,r.viewTo,n)):r.viewTo>n&&(r.view=r.view.slice(0,fr(e,n)))),r.viewTo=n}(e,i,a),n.viewOffset=Vt(Ge(e.doc,n.viewFrom)),e.display.mover.style.top=n.viewOffset+"px";var l=gr(e);if(!s&&0==l&&!t.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var c=function(e){if(e.hasFocus())return null;var t=P();if(!t||!A(e.display.lineDiv,t))return null;var n={activeElt:t};if(window.getSelection){var r=window.getSelection();r.anchorNode&&r.extend&&A(e.display.lineDiv,r.anchorNode)&&(n.anchorNode=r.anchorNode,n.anchorOffset=r.anchorOffset,n.focusNode=r.focusNode,n.focusOffset=r.focusOffset)}return n}(e);return l>4&&(n.lineDiv.style.display="none"),function(e,t,n){var r=e.display,o=e.options.lineNumbers,i=r.lineDiv,a=i.firstChild;function s(t){var n=t.nextSibling;return u&&b&&e.display.currentWheelTarget==t?t.style.display="none":t.parentNode.removeChild(t),n}for(var l=r.view,c=r.viewFrom,f=0;f<l.length;f++){var d=l[f];if(d.hidden);else if(d.node&&d.node.parentNode==i){for(;a!=d.node;)a=s(a);var p=o&&null!=t&&t<=c&&d.lineNumber;d.changes&&(H(d.changes,"gutter")>-1&&(p=!1),fn(e,d,c,n)),p&&(T(d.lineNumber),d.lineNumber.appendChild(document.createTextNode(et(e.options,c)))),a=d.node.nextSibling}else{var h=yn(e,d,c,n);i.insertBefore(h,a)}c+=d.size}for(;a;)a=s(a)}(e,n.updateLineNumbers,t.dims),l>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,function(e){if(e&&e.activeElt&&e.activeElt!=P()&&(e.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName)&&e.anchorNode&&A(document.body,e.anchorNode)&&A(document.body,e.focusNode))){var t=window.getSelection(),n=document.createRange();n.setEnd(e.anchorNode,e.anchorOffset),n.collapse(!1),t.removeAllRanges(),t.addRange(n),t.extend(e.focusNode,e.focusOffset)}}(c),T(n.cursorDiv),T(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,s&&(n.lastWrapHeight=t.wrapperHeight,n.lastWrapWidth=t.wrapperWidth,oo(e,400)),n.updateLineNumbers=null,!0}function uo(e,t){for(var n=t.viewport,r=!0;;r=!1){if(r&&e.options.lineWrapping&&t.oldDisplayWidth!=Tn(e))r&&(t.visible=jr(e.display,e.doc,n));else if(n&&null!=n.top&&(n={top:Math.min(e.doc.height+On(e.display)-jn(e),n.top)}),t.visible=jr(e.display,e.doc,n),t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)break;if(!so(e,t))break;Sr(e);var o=Fr(e);mr(e),Ur(e,o),fo(e,o),t.force=!1}t.signal(e,"update",e),e.display.viewFrom==e.display.reportedViewFrom&&e.display.viewTo==e.display.reportedViewTo||(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function lo(e,t){var n=new ao(e,t);if(so(e,n)){Sr(e),uo(e,n);var r=Fr(e);mr(e),Ur(e,r),fo(e,r),n.finish()}}function co(e){var t=e.gutters.offsetWidth;e.sizer.style.marginLeft=t+"px",ln(e,"gutterChanged",e)}function fo(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Sn(e)+"px"}function po(e){var t=e.display,n=t.view;if(t.alignWidgets||t.gutters.firstChild&&e.options.fixedGutter){for(var r=sr(t)-t.scroller.scrollLeft+e.doc.scrollLeft,o=t.gutters.offsetWidth,i=r+"px",a=0;a<n.length;a++)if(!n[a].hidden){e.options.fixedGutter&&(n[a].gutter&&(n[a].gutter.style.left=i),n[a].gutterBackground&&(n[a].gutterBackground.style.left=i));var s=n[a].alignable;if(s)for(var u=0;u<s.length;u++)s[u].style.left=i}e.options.fixedGutter&&(t.gutters.style.left=r+o+"px")}}function ho(e){if(!e.options.lineNumbers)return!1;var t=e.doc,n=et(e.options,t.first+t.size-1),r=e.display;if(n.length!=r.lineNumChars){var o=r.measure.appendChild(M("div",[M("div",n)],"CodeMirror-linenumber CodeMirror-gutter-elt")),i=o.firstChild.offsetWidth,a=o.offsetWidth-i;return r.lineGutter.style.width="",r.lineNumInnerWidth=Math.max(i,r.lineGutter.offsetWidth-a)+1,r.lineNumWidth=r.lineNumInnerWidth+a,r.lineNumChars=r.lineNumInnerWidth?n.length:-1,r.lineGutter.style.width=r.lineNumWidth+"px",co(e.display),!0}return!1}function vo(e,t){for(var n=[],r=!1,o=0;o<e.length;o++){var i=e[o],a=null;if("string"!=typeof i&&(a=i.style,i=i.className),"CodeMirror-linenumbers"==i){if(!t)continue;r=!0}n.push({className:i,style:a})}return t&&!r&&n.push({className:"CodeMirror-linenumbers",style:null}),n}function go(e){var t=e.gutters,n=e.gutterSpecs;T(t),e.lineGutter=null;for(var r=0;r<n.length;++r){var o=n[r],i=o.className,a=o.style,s=t.appendChild(M("div",null,"CodeMirror-gutter "+i));a&&(s.style.cssText=a),"CodeMirror-linenumbers"==i&&(e.lineGutter=s,s.style.width=(e.lineNumWidth||1)+"px")}t.style.display=n.length?"":"none",co(e)}function mo(e){go(e.display),dr(e),po(e)}function yo(e,t,r,o){var i=this;this.input=r,i.scrollbarFiller=M("div",null,"CodeMirror-scrollbar-filler"),i.scrollbarFiller.setAttribute("cm-not-content","true"),i.gutterFiller=M("div",null,"CodeMirror-gutter-filler"),i.gutterFiller.setAttribute("cm-not-content","true"),i.lineDiv=L("div",null,"CodeMirror-code"),i.selectionDiv=M("div",null,null,"position: relative; z-index: 1"),i.cursorDiv=M("div",null,"CodeMirror-cursors"),i.measure=M("div",null,"CodeMirror-measure"),i.lineMeasure=M("div",null,"CodeMirror-measure"),i.lineSpace=L("div",[i.measure,i.lineMeasure,i.selectionDiv,i.cursorDiv,i.lineDiv],null,"position: relative; outline: none");var l=L("div",[i.lineSpace],"CodeMirror-lines");i.mover=M("div",[l],null,"position: relative"),i.sizer=M("div",[i.mover],"CodeMirror-sizer"),i.sizerWidth=null,i.heightForcer=M("div",null,null,"position: absolute; height: 50px; width: 1px;"),i.gutters=M("div",null,"CodeMirror-gutters"),i.lineGutter=null,i.scroller=M("div",[i.sizer,i.heightForcer,i.gutters],"CodeMirror-scroll"),i.scroller.setAttribute("tabIndex","-1"),i.wrapper=M("div",[i.scrollbarFiller,i.gutterFiller,i.scroller],"CodeMirror"),i.wrapper.setAttribute("translate","no"),a&&s<8&&(i.gutters.style.zIndex=-1,i.scroller.style.paddingRight=0),u||n&&y||(i.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(i.wrapper):e(i.wrapper)),i.viewFrom=i.viewTo=t.first,i.reportedViewFrom=i.reportedViewTo=t.first,i.view=[],i.renderedView=null,i.externalMeasured=null,i.viewOffset=0,i.lastWrapHeight=i.lastWrapWidth=0,i.updateLineNumbers=null,i.nativeBarWidth=i.barHeight=i.barWidth=0,i.scrollbarsClipped=!1,i.lineNumWidth=i.lineNumInnerWidth=i.lineNumChars=null,i.alignWidgets=!1,i.cachedCharWidth=i.cachedTextHeight=i.cachedPaddingH=null,i.maxLine=null,i.maxLineLength=0,i.maxLineChanged=!1,i.wheelDX=i.wheelDY=i.wheelStartX=i.wheelStartY=null,i.shift=!1,i.selForContextMenu=null,i.activeTouch=null,i.gutterSpecs=vo(o.gutters,o.lineNumbers),go(i),r.init(i)}ao.prototype.signal=function(e,t){ye(e,t)&&this.events.push(arguments)},ao.prototype.finish=function(){for(var e=0;e<this.events.length;e++)ve.apply(null,this.events[e])};var bo=0,wo=null;function _o(e){var t=e.wheelDeltaX,n=e.wheelDeltaY;return null==t&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),null==n&&e.detail&&e.axis==e.VERTICAL_AXIS?n=e.detail:null==n&&(n=e.wheelDelta),{x:t,y:n}}function xo(e){var t=_o(e);return t.x*=wo,t.y*=wo,t}function ko(e,t){c&&f>=102&&(null==e.display.chromeScrollHack?e.display.sizer.style.pointerEvents="none":clearTimeout(e.display.chromeScrollHack),e.display.chromeScrollHack=setTimeout((function(){e.display.chromeScrollHack=null,e.display.sizer.style.pointerEvents=""}),100));var r=_o(t),o=r.x,i=r.y,a=wo;0===t.deltaMode&&(o=t.deltaX,i=t.deltaY,a=1);var s=e.display,l=s.scroller,p=l.scrollWidth>l.clientWidth,h=l.scrollHeight>l.clientHeight;if(o&&p||i&&h){if(i&&b&&u)e:for(var v=t.target,g=s.view;v!=l;v=v.parentNode)for(var m=0;m<g.length;m++)if(g[m].node==v){e.display.currentWheelTarget=v;break e}if(o&&!n&&!d&&null!=a)return i&&h&&Ir(e,Math.max(0,l.scrollTop+i*a)),zr(e,Math.max(0,l.scrollLeft+o*a)),(!i||i&&h)&&we(t),void(s.wheelStartX=null);if(i&&null!=a){var y=i*a,w=e.doc.scrollTop,_=w+s.wrapper.clientHeight;y<0?w=Math.max(0,w+y-50):_=Math.min(e.doc.height,_+y+50),lo(e,{top:w,bottom:_})}bo<20&&0!==t.deltaMode&&(null==s.wheelStartX?(s.wheelStartX=l.scrollLeft,s.wheelStartY=l.scrollTop,s.wheelDX=o,s.wheelDY=i,setTimeout((function(){if(null!=s.wheelStartX){var e=l.scrollLeft-s.wheelStartX,t=l.scrollTop-s.wheelStartY,n=t&&s.wheelDY&&t/s.wheelDY||e&&s.wheelDX&&e/s.wheelDX;s.wheelStartX=s.wheelStartY=null,n&&(wo=(wo*bo+n)/(bo+1),++bo)}}),200)):(s.wheelDX+=o,s.wheelDY+=i))}}a?wo=-.53:n?wo=15:c?wo=-.7:p&&(wo=-1/3);var Co=function(e,t){this.ranges=e,this.primIndex=t};Co.prototype.primary=function(){return this.ranges[this.primIndex]},Co.prototype.equals=function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var t=0;t<this.ranges.length;t++){var n=this.ranges[t],r=e.ranges[t];if(!rt(n.anchor,r.anchor)||!rt(n.head,r.head))return!1}return!0},Co.prototype.deepCopy=function(){for(var e=[],t=0;t<this.ranges.length;t++)e[t]=new Oo(ot(this.ranges[t].anchor),ot(this.ranges[t].head));return new Co(e,this.primIndex)},Co.prototype.somethingSelected=function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},Co.prototype.contains=function(e,t){t||(t=e);for(var n=0;n<this.ranges.length;n++){var r=this.ranges[n];if(nt(t,r.from())>=0&&nt(e,r.to())<=0)return n}return-1};var Oo=function(e,t){this.anchor=e,this.head=t};function Eo(e,t,n){var r=e&&e.options.selectionsMayTouch,o=t[n];t.sort((function(e,t){return nt(e.from(),t.from())})),n=H(t,o);for(var i=1;i<t.length;i++){var a=t[i],s=t[i-1],u=nt(s.to(),a.from());if(r&&!a.empty()?u>0:u>=0){var l=at(s.from(),a.from()),c=it(s.to(),a.to()),f=s.empty()?a.from()==a.head:s.from()==s.head;i<=n&&--n,t.splice(--i,2,new Oo(f?c:l,f?l:c))}}return new Co(t,n)}function So(e,t){return new Co([new Oo(e,t||e)],0)}function To(e){return e.text?tt(e.from.line+e.text.length-1,K(e.text).length+(1==e.text.length?e.from.ch:0)):e.to}function jo(e,t){if(nt(e,t.from)<0)return e;if(nt(e,t.to)<=0)return To(t);var n=e.line+t.text.length-(t.to.line-t.from.line)-1,r=e.ch;return e.line==t.to.line&&(r+=To(t).ch-t.to.ch),tt(n,r)}function Mo(e,t){for(var n=[],r=0;r<e.sel.ranges.length;r++){var o=e.sel.ranges[r];n.push(new Oo(jo(o.anchor,t),jo(o.head,t)))}return Eo(e.cm,n,e.sel.primIndex)}function Lo(e,t,n){return e.line==t.line?tt(n.line,e.ch-t.ch+n.ch):tt(n.line+(e.line-t.line),e.ch)}function Ao(e){e.doc.mode=Be(e.options,e.doc.modeOption),Po(e)}function Po(e){e.doc.iter((function(e){e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null)})),e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,oo(e,100),e.state.modeGen++,e.curOp&&dr(e)}function Ro(e,t){return 0==t.from.ch&&0==t.to.ch&&""==K(t.text)&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function Do(e,t,n,r){function o(e){return n?n[e]:null}function i(e,n,o){!function(e,t,n,r){e.text=t,e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null),null!=e.order&&(e.order=null),jt(e),Mt(e,n);var o=r?r(e):1;o!=e.height&&Ze(e,o)}(e,n,o,r),ln(e,"change",e,t)}function a(e,t){for(var n=[],i=e;i<t;++i)n.push(new Gt(l[i],o(i),r));return n}var s=t.from,u=t.to,l=t.text,c=Ge(e,s.line),f=Ge(e,u.line),d=K(l),p=o(l.length-1),h=u.line-s.line;if(t.full)e.insert(0,a(0,l.length)),e.remove(l.length,e.size-l.length);else if(Ro(e,t)){var v=a(0,l.length-1);i(f,f.text,p),h&&e.remove(s.line,h),v.length&&e.insert(s.line,v)}else if(c==f)if(1==l.length)i(c,c.text.slice(0,s.ch)+d+c.text.slice(u.ch),p);else{var g=a(1,l.length-1);g.push(new Gt(d+c.text.slice(u.ch),p,r)),i(c,c.text.slice(0,s.ch)+l[0],o(0)),e.insert(s.line+1,g)}else if(1==l.length)i(c,c.text.slice(0,s.ch)+l[0]+f.text.slice(u.ch),o(0)),e.remove(s.line+1,h);else{i(c,c.text.slice(0,s.ch)+l[0],o(0)),i(f,d+f.text.slice(u.ch),p);var m=a(1,l.length-1);h>1&&e.remove(s.line+1,h-1),e.insert(s.line+1,m)}ln(e,"change",e,t)}function Io(e,t,n){!function e(r,o,i){if(r.linked)for(var a=0;a<r.linked.length;++a){var s=r.linked[a];if(s.doc!=o){var u=i&&s.sharedHist;n&&!u||(t(s.doc,u),e(s.doc,r,u))}}}(e,null,!0)}function No(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,lr(e),Ao(e),zo(e),e.options.direction=t.direction,e.options.lineWrapping||Yt(e),e.options.mode=t.modeOption,dr(e)}function zo(e){("rtl"==e.doc.direction?R:S)(e.display.lineDiv,"CodeMirror-rtl")}function Fo(e){this.done=[],this.undone=[],this.undoDepth=e?e.undoDepth:1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e?e.maxGeneration:1}function Bo(e,t){var n={from:ot(t.from),to:To(t),text:$e(e,t.from,t.to)};return qo(e,n,t.from.line,t.to.line+1),Io(e,(function(e){return qo(e,n,t.from.line,t.to.line+1)}),!0),n}function Ho(e){for(;e.length&&K(e).ranges;)e.pop()}function Uo(e,t,n,r){var o=e.history;o.undone.length=0;var i,a,s=+new Date;if((o.lastOp==r||o.lastOrigin==t.origin&&t.origin&&("+"==t.origin.charAt(0)&&o.lastModTime>s-(e.cm?e.cm.options.historyEventDelay:500)||"*"==t.origin.charAt(0)))&&(i=function(e,t){return t?(Ho(e.done),K(e.done)):e.done.length&&!K(e.done).ranges?K(e.done):e.done.length>1&&!e.done[e.done.length-2].ranges?(e.done.pop(),K(e.done)):void 0}(o,o.lastOp==r)))a=K(i.changes),0==nt(t.from,t.to)&&0==nt(t.from,a.to)?a.to=To(t):i.changes.push(Bo(e,t));else{var u=K(o.done);for(u&&u.ranges||Vo(e.sel,o.done),i={changes:[Bo(e,t)],generation:o.generation},o.done.push(i);o.done.length>o.undoDepth;)o.done.shift(),o.done[0].ranges||o.done.shift()}o.done.push(n),o.generation=++o.maxGeneration,o.lastModTime=o.lastSelTime=s,o.lastOp=o.lastSelOp=r,o.lastOrigin=o.lastSelOrigin=t.origin,a||ve(e,"historyAdded")}function Wo(e,t,n,r){var o=e.history,i=r&&r.origin;n==o.lastSelOp||i&&o.lastSelOrigin==i&&(o.lastModTime==o.lastSelTime&&o.lastOrigin==i||function(e,t,n,r){var o=t.charAt(0);return"*"==o||"+"==o&&n.ranges.length==r.ranges.length&&n.somethingSelected()==r.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}(e,i,K(o.done),t))?o.done[o.done.length-1]=t:Vo(t,o.done),o.lastSelTime=+new Date,o.lastSelOrigin=i,o.lastSelOp=n,r&&!1!==r.clearRedo&&Ho(o.undone)}function Vo(e,t){var n=K(t);n&&n.ranges&&n.equals(e)||t.push(e)}function qo(e,t,n,r){var o=t["spans_"+e.id],i=0;e.iter(Math.max(e.first,n),Math.min(e.first+e.size,r),(function(n){n.markedSpans&&((o||(o=t["spans_"+e.id]={}))[i]=n.markedSpans),++i}))}function Yo(e){if(!e)return null;for(var t,n=0;n<e.length;++n)e[n].marker.explicitlyCleared?t||(t=e.slice(0,n)):t&&t.push(e[n]);return t?t.length?t:null:e}function Go(e,t){var n=function(e,t){var n=t["spans_"+e.id];if(!n)return null;for(var r=[],o=0;o<t.text.length;++o)r.push(Yo(n[o]));return r}(e,t),r=St(e,t);if(!n)return r;if(!r)return n;for(var o=0;o<n.length;++o){var i=n[o],a=r[o];if(i&&a)e:for(var s=0;s<a.length;++s){for(var u=a[s],l=0;l<i.length;++l)if(i[l].marker==u.marker)continue e;i.push(u)}else a&&(n[o]=a)}return n}function $o(e,t,n){for(var r=[],o=0;o<e.length;++o){var i=e[o];if(i.ranges)r.push(n?Co.prototype.deepCopy.call(i):i);else{var a=i.changes,s=[];r.push({changes:s});for(var u=0;u<a.length;++u){var l=a[u],c=void 0;if(s.push({from:l.from,to:l.to,text:l.text}),t)for(var f in l)(c=f.match(/^spans_(\d+)$/))&&H(t,Number(c[1]))>-1&&(K(s)[f]=l[f],delete l[f])}}}return r}function Ko(e,t,n,r){if(r){var o=e.anchor;if(n){var i=nt(t,o)<0;i!=nt(n,o)<0?(o=t,t=n):i!=nt(t,n)<0&&(t=n)}return new Oo(o,t)}return new Oo(n||t,t)}function Zo(e,t,n,r,o){null==o&&(o=e.cm&&(e.cm.display.shift||e.extend)),ti(e,new Co([Ko(e.sel.primary(),t,n,o)],0),r)}function Xo(e,t,n){for(var r=[],o=e.cm&&(e.cm.display.shift||e.extend),i=0;i<e.sel.ranges.length;i++)r[i]=Ko(e.sel.ranges[i],t[i],null,o);ti(e,Eo(e.cm,r,e.sel.primIndex),n)}function Qo(e,t,n,r){var o=e.sel.ranges.slice(0);o[t]=n,ti(e,Eo(e.cm,o,e.sel.primIndex),r)}function Jo(e,t,n,r){ti(e,So(t,n),r)}function ei(e,t,n){var r=e.history.done,o=K(r);o&&o.ranges?(r[r.length-1]=t,ni(e,t,n)):ti(e,t,n)}function ti(e,t,n){ni(e,t,n),Wo(e,e.sel,e.cm?e.cm.curOp.id:NaN,n)}function ni(e,t,n){(ye(e,"beforeSelectionChange")||e.cm&&ye(e.cm,"beforeSelectionChange"))&&(t=function(e,t,n){var r={ranges:t.ranges,update:function(t){this.ranges=[];for(var n=0;n<t.length;n++)this.ranges[n]=new Oo(ut(e,t[n].anchor),ut(e,t[n].head))},origin:n&&n.origin};return ve(e,"beforeSelectionChange",e,r),e.cm&&ve(e.cm,"beforeSelectionChange",e.cm,r),r.ranges!=t.ranges?Eo(e.cm,r.ranges,r.ranges.length-1):t}(e,t,n));var r=n&&n.bias||(nt(t.primary().head,e.sel.primary().head)<0?-1:1);ri(e,ii(e,t,r,!0)),n&&!1===n.scroll||!e.cm||"nocursor"==e.cm.getOption("readOnly")||Ar(e.cm)}function ri(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=1,e.cm.curOp.selectionChanged=!0,me(e.cm)),ln(e,"cursorActivity",e))}function oi(e){ri(e,ii(e,e.sel,null,!1))}function ii(e,t,n,r){for(var o,i=0;i<t.ranges.length;i++){var a=t.ranges[i],s=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[i],u=si(e,a.anchor,s&&s.anchor,n,r),l=si(e,a.head,s&&s.head,n,r);(o||u!=a.anchor||l!=a.head)&&(o||(o=t.ranges.slice(0,i)),o[i]=new Oo(u,l))}return o?Eo(e.cm,o,t.primIndex):t}function ai(e,t,n,r,o){var i=Ge(e,t.line);if(i.markedSpans)for(var a=0;a<i.markedSpans.length;++a){var s=i.markedSpans[a],u=s.marker,l="selectLeft"in u?!u.selectLeft:u.inclusiveLeft,c="selectRight"in u?!u.selectRight:u.inclusiveRight;if((null==s.from||(l?s.from<=t.ch:s.from<t.ch))&&(null==s.to||(c?s.to>=t.ch:s.to>t.ch))){if(o&&(ve(u,"beforeCursorEnter"),u.explicitlyCleared)){if(i.markedSpans){--a;continue}break}if(!u.atomic)continue;if(n){var f=u.find(r<0?1:-1),d=void 0;if((r<0?c:l)&&(f=ui(e,f,-r,f&&f.line==t.line?i:null)),f&&f.line==t.line&&(d=nt(f,n))&&(r<0?d<0:d>0))return ai(e,f,t,r,o)}var p=u.find(r<0?-1:1);return(r<0?l:c)&&(p=ui(e,p,r,p.line==t.line?i:null)),p?ai(e,p,t,r,o):null}}return t}function si(e,t,n,r,o){var i=r||1,a=ai(e,t,n,i,o)||!o&&ai(e,t,n,i,!0)||ai(e,t,n,-i,o)||!o&&ai(e,t,n,-i,!0);return a||(e.cantEdit=!0,tt(e.first,0))}function ui(e,t,n,r){return n<0&&0==t.ch?t.line>e.first?ut(e,tt(t.line-1)):null:n>0&&t.ch==(r||Ge(e,t.line)).text.length?t.line<e.first+e.size-1?tt(t.line+1,0):null:new tt(t.line,t.ch+n)}function li(e){e.setSelection(tt(e.firstLine(),0),tt(e.lastLine()),W)}function ci(e,t,n){var r={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){return r.canceled=!0}};return n&&(r.update=function(t,n,o,i){t&&(r.from=ut(e,t)),n&&(r.to=ut(e,n)),o&&(r.text=o),void 0!==i&&(r.origin=i)}),ve(e,"beforeChange",e,r),e.cm&&ve(e.cm,"beforeChange",e.cm,r),r.canceled?(e.cm&&(e.cm.curOp.updateInput=2),null):{from:r.from,to:r.to,text:r.text,origin:r.origin}}function fi(e,t,n){if(e.cm){if(!e.cm.curOp)return to(e.cm,fi)(e,t,n);if(e.cm.state.suppressEdits)return}if(!(ye(e,"beforeChange")||e.cm&&ye(e.cm,"beforeChange"))||(t=ci(e,t,!0))){var r=xt&&!n&&function(e,t,n){var r=null;if(e.iter(t.line,n.line+1,(function(e){if(e.markedSpans)for(var t=0;t<e.markedSpans.length;++t){var n=e.markedSpans[t].marker;!n.readOnly||r&&-1!=H(r,n)||(r||(r=[])).push(n)}})),!r)return null;for(var o=[{from:t,to:n}],i=0;i<r.length;++i)for(var a=r[i],s=a.find(0),u=0;u<o.length;++u){var l=o[u];if(!(nt(l.to,s.from)<0||nt(l.from,s.to)>0)){var c=[u,1],f=nt(l.from,s.from),d=nt(l.to,s.to);(f<0||!a.inclusiveLeft&&!f)&&c.push({from:l.from,to:s.from}),(d>0||!a.inclusiveRight&&!d)&&c.push({from:s.to,to:l.to}),o.splice.apply(o,c),u+=c.length-3}}return o}(e,t.from,t.to);if(r)for(var o=r.length-1;o>=0;--o)di(e,{from:r[o].from,to:r[o].to,text:o?[""]:t.text,origin:t.origin});else di(e,t)}}function di(e,t){if(1!=t.text.length||""!=t.text[0]||0!=nt(t.from,t.to)){var n=Mo(e,t);Uo(e,t,n,e.cm?e.cm.curOp.id:NaN),vi(e,t,n,St(e,t));var r=[];Io(e,(function(e,n){n||-1!=H(r,e.history)||(bi(e.history,t),r.push(e.history)),vi(e,t,null,St(e,t))}))}}function pi(e,t,n){var r=e.cm&&e.cm.state.suppressEdits;if(!r||n){for(var o,i=e.history,a=e.sel,s="undo"==t?i.done:i.undone,u="undo"==t?i.undone:i.done,l=0;l<s.length&&(o=s[l],n?!o.ranges||o.equals(e.sel):o.ranges);l++);if(l!=s.length){for(i.lastOrigin=i.lastSelOrigin=null;;){if(!(o=s.pop()).ranges){if(r)return void s.push(o);break}if(Vo(o,u),n&&!o.equals(e.sel))return void ti(e,o,{clearRedo:!1});a=o}var c=[];Vo(a,u),u.push({changes:c,generation:i.generation}),i.generation=o.generation||++i.maxGeneration;for(var f=ye(e,"beforeChange")||e.cm&&ye(e.cm,"beforeChange"),d=function(n){var r=o.changes[n];if(r.origin=t,f&&!ci(e,r,!1))return s.length=0,{};c.push(Bo(e,r));var i=n?Mo(e,r):K(s);vi(e,r,i,Go(e,r)),!n&&e.cm&&e.cm.scrollIntoView({from:r.from,to:To(r)});var a=[];Io(e,(function(e,t){t||-1!=H(a,e.history)||(bi(e.history,r),a.push(e.history)),vi(e,r,null,Go(e,r))}))},p=o.changes.length-1;p>=0;--p){var h=d(p);if(h)return h.v}}}}function hi(e,t){if(0!=t&&(e.first+=t,e.sel=new Co(Z(e.sel.ranges,(function(e){return new Oo(tt(e.anchor.line+t,e.anchor.ch),tt(e.head.line+t,e.head.ch))})),e.sel.primIndex),e.cm)){dr(e.cm,e.first,e.first-t,t);for(var n=e.cm.display,r=n.viewFrom;r<n.viewTo;r++)pr(e.cm,r,"gutter")}}function vi(e,t,n,r){if(e.cm&&!e.cm.curOp)return to(e.cm,vi)(e,t,n,r);if(t.to.line<e.first)hi(e,t.text.length-1-(t.to.line-t.from.line));else if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var o=t.text.length-1-(e.first-t.from.line);hi(e,o),t={from:tt(e.first,0),to:tt(t.to.line+o,t.to.ch),text:[K(t.text)],origin:t.origin}}var i=e.lastLine();t.to.line>i&&(t={from:t.from,to:tt(i,Ge(e,i).text.length),text:[t.text[0]],origin:t.origin}),t.removed=$e(e,t.from,t.to),n||(n=Mo(e,t)),e.cm?function(e,t,n){var r=e.doc,o=e.display,i=t.from,a=t.to,s=!1,u=i.line;e.options.lineWrapping||(u=Xe(Ft(Ge(r,i.line))),r.iter(u,a.line+1,(function(e){if(e==o.maxLine)return s=!0,!0}))),r.sel.contains(t.from,t.to)>-1&&me(e),Do(r,t,n,ur(e)),e.options.lineWrapping||(r.iter(u,i.line+t.text.length,(function(e){var t=qt(e);t>o.maxLineLength&&(o.maxLine=e,o.maxLineLength=t,o.maxLineChanged=!0,s=!1)})),s&&(e.curOp.updateMaxLine=!0)),function(e,t){if(e.modeFrontier=Math.min(e.modeFrontier,t),!(e.highlightFrontier<t-10)){for(var n=e.first,r=t-1;r>n;r--){var o=Ge(e,r).stateAfter;if(o&&(!(o instanceof ct)||r+o.lookAhead<t)){n=r+1;break}}e.highlightFrontier=Math.min(e.highlightFrontier,n)}}(r,i.line),oo(e,400);var l=t.text.length-(a.line-i.line)-1;t.full?dr(e):i.line!=a.line||1!=t.text.length||Ro(e.doc,t)?dr(e,i.line,a.line+1,l):pr(e,i.line,"text");var c=ye(e,"changes"),f=ye(e,"change");if(f||c){var d={from:i,to:a,text:t.text,removed:t.removed,origin:t.origin};f&&ln(e,"change",e,d),c&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(d)}e.display.selForContextMenu=null}(e.cm,t,r):Do(e,t,r),ni(e,n,W),e.cantEdit&&si(e,tt(e.firstLine(),0))&&(e.cantEdit=!1)}}function gi(e,t,n,r,o){var i;r||(r=n),nt(r,n)<0&&(n=(i=[r,n])[0],r=i[1]),"string"==typeof t&&(t=e.splitLines(t)),fi(e,{from:n,to:r,text:t,origin:o})}function mi(e,t,n,r){n<e.line?e.line+=r:t<e.line&&(e.line=t,e.ch=0)}function yi(e,t,n,r){for(var o=0;o<e.length;++o){var i=e[o],a=!0;if(i.ranges){i.copied||((i=e[o]=i.deepCopy()).copied=!0);for(var s=0;s<i.ranges.length;s++)mi(i.ranges[s].anchor,t,n,r),mi(i.ranges[s].head,t,n,r)}else{for(var u=0;u<i.changes.length;++u){var l=i.changes[u];if(n<l.from.line)l.from=tt(l.from.line+r,l.from.ch),l.to=tt(l.to.line+r,l.to.ch);else if(t<=l.to.line){a=!1;break}}a||(e.splice(0,o+1),o=0)}}}function bi(e,t){var n=t.from.line,r=t.to.line,o=t.text.length-(r-n)-1;yi(e.done,n,r,o),yi(e.undone,n,r,o)}function wi(e,t,n,r){var o=t,i=t;return"number"==typeof t?i=Ge(e,st(e,t)):o=Xe(t),null==o?null:(r(i,o)&&e.cm&&pr(e.cm,o,n),i)}function _i(e){this.lines=e,this.parent=null;for(var t=0,n=0;n<e.length;++n)e[n].parent=this,t+=e[n].height;this.height=t}function xi(e){this.children=e;for(var t=0,n=0,r=0;r<e.length;++r){var o=e[r];t+=o.chunkSize(),n+=o.height,o.parent=this}this.size=t,this.height=n,this.parent=null}Oo.prototype.from=function(){return at(this.anchor,this.head)},Oo.prototype.to=function(){return it(this.anchor,this.head)},Oo.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch},_i.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var n=e,r=e+t;n<r;++n){var o=this.lines[n];this.height-=o.height,$t(o),ln(o,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,n){this.height+=n,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var r=0;r<t.length;++r)t[r].parent=this},iterN:function(e,t,n){for(var r=e+t;e<r;++e)if(n(this.lines[e]))return!0}},xi.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){this.size-=t;for(var n=0;n<this.children.length;++n){var r=this.children[n],o=r.chunkSize();if(e<o){var i=Math.min(t,o-e),a=r.height;if(r.removeInner(e,i),this.height-=a-r.height,o==i&&(this.children.splice(n--,1),r.parent=null),0==(t-=i))break;e=0}else e-=o}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof _i))){var s=[];this.collapse(s),this.children=[new _i(s)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t<this.children.length;++t)this.children[t].collapse(e)},insertInner:function(e,t,n){this.size+=t.length,this.height+=n;for(var r=0;r<this.children.length;++r){var o=this.children[r],i=o.chunkSize();if(e<=i){if(o.insertInner(e,t,n),o.lines&&o.lines.length>50){for(var a=o.lines.length%25+25,s=a;s<o.lines.length;){var u=new _i(o.lines.slice(s,s+=25));o.height-=u.height,this.children.splice(++r,0,u),u.parent=this}o.lines=o.lines.slice(0,a),this.maybeSpill()}break}e-=i}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=new xi(e.children.splice(e.children.length-5,5));if(e.parent){e.size-=t.size,e.height-=t.height;var n=H(e.parent.children,e);e.parent.children.splice(n+1,0,t)}else{var r=new xi(e.children);r.parent=e,e.children=[r,t],e=r}t.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,n){for(var r=0;r<this.children.length;++r){var o=this.children[r],i=o.chunkSize();if(e<i){var a=Math.min(t,i-e);if(o.iterN(e,a,n))return!0;if(0==(t-=a))break;e=0}else e-=i}}};var ki=function(e,t,n){if(n)for(var r in n)n.hasOwnProperty(r)&&(this[r]=n[r]);this.doc=e,this.node=t};function Ci(e,t,n){Vt(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&Lr(e,n)}ki.prototype.clear=function(){var e=this.doc.cm,t=this.line.widgets,n=this.line,r=Xe(n);if(null!=r&&t){for(var o=0;o<t.length;++o)t[o]==this&&t.splice(o--,1);t.length||(n.widgets=null);var i=xn(this);Ze(n,Math.max(0,n.height-i)),e&&(eo(e,(function(){Ci(e,n,-i),pr(e,r,"widget")})),ln(e,"lineWidgetCleared",e,this,r))}},ki.prototype.changed=function(){var e=this,t=this.height,n=this.doc.cm,r=this.line;this.height=null;var o=xn(this)-t;o&&(Ut(this.doc,r)||Ze(r,r.height+o),n&&eo(n,(function(){n.curOp.forceUpdate=!0,Ci(n,r,o),ln(n,"lineWidgetChanged",n,e,Xe(r))})))},be(ki);var Oi=0,Ei=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++Oi};function Si(e,t,n,r,o){if(r&&r.shared)return function(e,t,n,r,o){(r=z(r)).shared=!1;var i=[Si(e,t,n,r,o)],a=i[0],s=r.widgetNode;return Io(e,(function(e){s&&(r.widgetNode=s.cloneNode(!0)),i.push(Si(e,ut(e,t),ut(e,n),r,o));for(var u=0;u<e.linked.length;++u)if(e.linked[u].isParent)return;a=K(i)})),new Ti(i,a)}(e,t,n,r,o);if(e.cm&&!e.cm.curOp)return to(e.cm,Si)(e,t,n,r,o);var i=new Ei(e,o),a=nt(t,n);if(r&&z(r,i,!1),a>0||0==a&&!1!==i.clearWhenEmpty)return i;if(i.replacedWith&&(i.collapsed=!0,i.widgetNode=L("span",[i.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||i.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(i.widgetNode.insertLeft=!0)),i.collapsed){if(zt(e,t.line,t,n,i)||t.line!=n.line&&zt(e,n.line,t,n,i))throw new Error("Inserting collapsed marker partially overlapping an existing one");kt=!0}i.addToHistory&&Uo(e,{from:t,to:n,origin:"markText"},e.sel,NaN);var s,u=t.line,l=e.cm;if(e.iter(u,n.line+1,(function(r){l&&i.collapsed&&!l.options.lineWrapping&&Ft(r)==l.display.maxLine&&(s=!0),i.collapsed&&u!=t.line&&Ze(r,0),function(e,t,n){var r=n&&window.WeakSet&&(n.markedSpans||(n.markedSpans=new WeakSet));r&&e.markedSpans&&r.has(e.markedSpans)?e.markedSpans.push(t):(e.markedSpans=e.markedSpans?e.markedSpans.concat([t]):[t],r&&r.add(e.markedSpans)),t.marker.attachLine(e)}(r,new Ct(i,u==t.line?t.ch:null,u==n.line?n.ch:null),e.cm&&e.cm.curOp),++u})),i.collapsed&&e.iter(t.line,n.line+1,(function(t){Ut(e,t)&&Ze(t,0)})),i.clearOnEnter&&de(i,"beforeCursorEnter",(function(){return i.clear()})),i.readOnly&&(xt=!0,(e.history.done.length||e.history.undone.length)&&e.clearHistory()),i.collapsed&&(i.id=++Oi,i.atomic=!0),l){if(s&&(l.curOp.updateMaxLine=!0),i.collapsed)dr(l,t.line,n.line+1);else if(i.className||i.startStyle||i.endStyle||i.css||i.attributes||i.title)for(var c=t.line;c<=n.line;c++)pr(l,c,"text");i.atomic&&oi(l.doc),ln(l,"markerAdded",l,i)}return i}Ei.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&Gr(e),ye(this,"clear")){var n=this.find();n&&ln(this,"clear",n.from,n.to)}for(var r=null,o=null,i=0;i<this.lines.length;++i){var a=this.lines[i],s=Ot(a.markedSpans,this);e&&!this.collapsed?pr(e,Xe(a),"text"):e&&(null!=s.to&&(o=Xe(a)),null!=s.from&&(r=Xe(a))),a.markedSpans=Et(a.markedSpans,s),null==s.from&&this.collapsed&&!Ut(this.doc,a)&&e&&Ze(a,or(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var u=0;u<this.lines.length;++u){var l=Ft(this.lines[u]),c=qt(l);c>e.display.maxLineLength&&(e.display.maxLine=l,e.display.maxLineLength=c,e.display.maxLineChanged=!0)}null!=r&&e&&this.collapsed&&dr(e,r,o+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&oi(e.doc)),e&&ln(e,"markerCleared",e,this,r,o),t&&$r(e),this.parent&&this.parent.clear()}},Ei.prototype.find=function(e,t){var n,r;null==e&&"bookmark"==this.type&&(e=1);for(var o=0;o<this.lines.length;++o){var i=this.lines[o],a=Ot(i.markedSpans,this);if(null!=a.from&&(n=tt(t?i:Xe(i),a.from),-1==e))return n;if(null!=a.to&&(r=tt(t?i:Xe(i),a.to),1==e))return r}return n&&{from:n,to:r}},Ei.prototype.changed=function(){var e=this,t=this.find(-1,!0),n=this,r=this.doc.cm;t&&r&&eo(r,(function(){var o=t.line,i=Xe(t.line),a=An(r,i);if(a&&(Fn(a),r.curOp.selectionChanged=r.curOp.forceUpdate=!0),r.curOp.updateMaxLine=!0,!Ut(n.doc,o)&&null!=n.height){var s=n.height;n.height=null;var u=xn(n)-s;u&&Ze(o,o.height+u)}ln(r,"markerChanged",r,e)}))},Ei.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;t.maybeHiddenMarkers&&-1!=H(t.maybeHiddenMarkers,this)||(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},Ei.prototype.detachLine=function(e){if(this.lines.splice(H(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}},be(Ei);var Ti=function(e,t){this.markers=e,this.primary=t;for(var n=0;n<e.length;++n)e[n].parent=this};function ji(e){return e.findMarks(tt(e.first,0),e.clipPos(tt(e.lastLine())),(function(e){return e.parent}))}function Mi(e){for(var t=function(t){var n=e[t],r=[n.primary.doc];Io(n.primary.doc,(function(e){return r.push(e)}));for(var o=0;o<n.markers.length;o++){var i=n.markers[o];-1==H(r,i.doc)&&(i.parent=null,n.markers.splice(o--,1))}},n=0;n<e.length;n++)t(n)}Ti.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();ln(this,"clear")}},Ti.prototype.find=function(e,t){return this.primary.find(e,t)},be(Ti);var Li=0,Ai=function(e,t,n,r,o){if(!(this instanceof Ai))return new Ai(e,t,n,r,o);null==n&&(n=0),xi.call(this,[new _i([new Gt("",null)])]),this.first=n,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=n;var i=tt(n,0);this.sel=So(i),this.history=new Fo(null),this.id=++Li,this.modeOption=t,this.lineSep=r,this.direction="rtl"==o?"rtl":"ltr",this.extend=!1,"string"==typeof e&&(e=this.splitLines(e)),Do(this,{from:i,to:i,text:e}),ti(this,So(i),W)};Ai.prototype=Q(xi.prototype,{constructor:Ai,iter:function(e,t,n){n?this.iterN(e-this.first,t-e,n):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var n=0,r=0;r<t.length;++r)n+=t[r].height;this.insertInner(e-this.first,t,n)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=Ke(this,this.first,this.first+this.size);return!1===e?t:t.join(e||this.lineSeparator())},setValue:ro((function(e){var t=tt(this.first,0),n=this.first+this.size-1;fi(this,{from:t,to:tt(n,Ge(this,n).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&Pr(this.cm,0,0),ti(this,So(t),W)})),replaceRange:function(e,t,n,r){gi(this,e,t=ut(this,t),n=n?ut(this,n):t,r)},getRange:function(e,t,n){var r=$e(this,ut(this,e),ut(this,t));return!1===n?r:""===n?r.join(""):r.join(n||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){if(Je(this,e))return Ge(this,e)},getLineNumber:function(e){return Xe(e)},getLineHandleVisualStart:function(e){return"number"==typeof e&&(e=Ge(this,e)),Ft(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return ut(this,e)},getCursor:function(e){var t=this.sel.primary();return null==e||"head"==e?t.head:"anchor"==e?t.anchor:"end"==e||"to"==e||!1===e?t.to():t.from()},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:ro((function(e,t,n){Jo(this,ut(this,"number"==typeof e?tt(e,t||0):e),null,n)})),setSelection:ro((function(e,t,n){Jo(this,ut(this,e),ut(this,t||e),n)})),extendSelection:ro((function(e,t,n){Zo(this,ut(this,e),t&&ut(this,t),n)})),extendSelections:ro((function(e,t){Xo(this,lt(this,e),t)})),extendSelectionsBy:ro((function(e,t){Xo(this,lt(this,Z(this.sel.ranges,e)),t)})),setSelections:ro((function(e,t,n){if(e.length){for(var r=[],o=0;o<e.length;o++)r[o]=new Oo(ut(this,e[o].anchor),ut(this,e[o].head||e[o].anchor));null==t&&(t=Math.min(e.length-1,this.sel.primIndex)),ti(this,Eo(this.cm,r,t),n)}})),addSelection:ro((function(e,t,n){var r=this.sel.ranges.slice(0);r.push(new Oo(ut(this,e),ut(this,t||e))),ti(this,Eo(this.cm,r,r.length-1),n)})),getSelection:function(e){for(var t,n=this.sel.ranges,r=0;r<n.length;r++){var o=$e(this,n[r].from(),n[r].to());t=t?t.concat(o):o}return!1===e?t:t.join(e||this.lineSeparator())},getSelections:function(e){for(var t=[],n=this.sel.ranges,r=0;r<n.length;r++){var o=$e(this,n[r].from(),n[r].to());!1!==e&&(o=o.join(e||this.lineSeparator())),t[r]=o}return t},replaceSelection:function(e,t,n){for(var r=[],o=0;o<this.sel.ranges.length;o++)r[o]=e;this.replaceSelections(r,t,n||"+input")},replaceSelections:ro((function(e,t,n){for(var r=[],o=this.sel,i=0;i<o.ranges.length;i++){var a=o.ranges[i];r[i]={from:a.from(),to:a.to(),text:this.splitLines(e[i]),origin:n}}for(var s=t&&"end"!=t&&function(e,t,n){for(var r=[],o=tt(e.first,0),i=o,a=0;a<t.length;a++){var s=t[a],u=Lo(s.from,o,i),l=Lo(To(s),o,i);if(o=s.to,i=l,"around"==n){var c=e.sel.ranges[a],f=nt(c.head,c.anchor)<0;r[a]=new Oo(f?l:u,f?u:l)}else r[a]=new Oo(u,u)}return new Co(r,e.sel.primIndex)}(this,r,t),u=r.length-1;u>=0;u--)fi(this,r[u]);s?ei(this,s):this.cm&&Ar(this.cm)})),undo:ro((function(){pi(this,"undo")})),redo:ro((function(){pi(this,"redo")})),undoSelection:ro((function(){pi(this,"undo",!0)})),redoSelection:ro((function(){pi(this,"redo",!0)})),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,n=0,r=0;r<e.done.length;r++)e.done[r].ranges||++t;for(var o=0;o<e.undone.length;o++)e.undone[o].ranges||++n;return{undo:t,redo:n}},clearHistory:function(){var e=this;this.history=new Fo(this.history),Io(this,(function(t){return t.history=e.history}),!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:$o(this.history.done),undone:$o(this.history.undone)}},setHistory:function(e){var t=this.history=new Fo(this.history);t.done=$o(e.done.slice(0),null,!0),t.undone=$o(e.undone.slice(0),null,!0)},setGutterMarker:ro((function(e,t,n){return wi(this,e,"gutter",(function(e){var r=e.gutterMarkers||(e.gutterMarkers={});return r[t]=n,!n&&ne(r)&&(e.gutterMarkers=null),!0}))})),clearGutter:ro((function(e){var t=this;this.iter((function(n){n.gutterMarkers&&n.gutterMarkers[e]&&wi(t,n,"gutter",(function(){return n.gutterMarkers[e]=null,ne(n.gutterMarkers)&&(n.gutterMarkers=null),!0}))}))})),lineInfo:function(e){var t;if("number"==typeof e){if(!Je(this,e))return null;if(t=e,!(e=Ge(this,e)))return null}else if(null==(t=Xe(e)))return null;return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:ro((function(e,t,n){return wi(this,e,"gutter"==t?"gutter":"class",(function(e){var r="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass";if(e[r]){if(O(n).test(e[r]))return!1;e[r]+=" "+n}else e[r]=n;return!0}))})),removeLineClass:ro((function(e,t,n){return wi(this,e,"gutter"==t?"gutter":"class",(function(e){var r="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass",o=e[r];if(!o)return!1;if(null==n)e[r]=null;else{var i=o.match(O(n));if(!i)return!1;var a=i.index+i[0].length;e[r]=o.slice(0,i.index)+(i.index&&a!=o.length?" ":"")+o.slice(a)||null}return!0}))})),addLineWidget:ro((function(e,t,n){return function(e,t,n,r){var o=new ki(e,n,r),i=e.cm;return i&&o.noHScroll&&(i.display.alignWidgets=!0),wi(e,t,"widget",(function(t){var n=t.widgets||(t.widgets=[]);if(null==o.insertAt?n.push(o):n.splice(Math.min(n.length,Math.max(0,o.insertAt)),0,o),o.line=t,i&&!Ut(e,t)){var r=Vt(t)<e.scrollTop;Ze(t,t.height+xn(o)),r&&Lr(i,o.height),i.curOp.forceUpdate=!0}return!0})),i&&ln(i,"lineWidgetAdded",i,o,"number"==typeof t?t:Xe(t)),o}(this,e,t,n)})),removeLineWidget:function(e){e.clear()},markText:function(e,t,n){return Si(this,ut(this,e),ut(this,t),n,n&&n.type||"range")},setBookmark:function(e,t){var n={replacedWith:t&&(null==t.nodeType?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return Si(this,e=ut(this,e),e,n,"bookmark")},findMarksAt:function(e){var t=[],n=Ge(this,(e=ut(this,e)).line).markedSpans;if(n)for(var r=0;r<n.length;++r){var o=n[r];(null==o.from||o.from<=e.ch)&&(null==o.to||o.to>=e.ch)&&t.push(o.marker.parent||o.marker)}return t},findMarks:function(e,t,n){e=ut(this,e),t=ut(this,t);var r=[],o=e.line;return this.iter(e.line,t.line+1,(function(i){var a=i.markedSpans;if(a)for(var s=0;s<a.length;s++){var u=a[s];null!=u.to&&o==e.line&&e.ch>=u.to||null==u.from&&o!=e.line||null!=u.from&&o==t.line&&u.from>=t.ch||n&&!n(u.marker)||r.push(u.marker.parent||u.marker)}++o})),r},getAllMarks:function(){var e=[];return this.iter((function(t){var n=t.markedSpans;if(n)for(var r=0;r<n.length;++r)null!=n[r].from&&e.push(n[r].marker)})),e},posFromIndex:function(e){var t,n=this.first,r=this.lineSeparator().length;return this.iter((function(o){var i=o.text.length+r;if(i>e)return t=e,!0;e-=i,++n})),ut(this,tt(n,t))},indexFromPos:function(e){var t=(e=ut(this,e)).ch;if(e.line<this.first||e.ch<0)return 0;var n=this.lineSeparator().length;return this.iter(this.first,e.line,(function(e){t+=e.text.length+n})),t},copy:function(e){var t=new Ai(Ke(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,n=this.first+this.size;null!=e.from&&e.from>t&&(t=e.from),null!=e.to&&e.to<n&&(n=e.to);var r=new Ai(Ke(this,t,n),e.mode||this.modeOption,t,this.lineSep,this.direction);return e.sharedHist&&(r.history=this.history),(this.linked||(this.linked=[])).push({doc:r,sharedHist:e.sharedHist}),r.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],function(e,t){for(var n=0;n<t.length;n++){var r=t[n],o=r.find(),i=e.clipPos(o.from),a=e.clipPos(o.to);if(nt(i,a)){var s=Si(e,i,a,r.primary,r.primary.type);r.markers.push(s),s.parent=r}}}(r,ji(this)),r},unlinkDoc:function(e){if(e instanceof Ta&&(e=e.doc),this.linked)for(var t=0;t<this.linked.length;++t)if(this.linked[t].doc==e){this.linked.splice(t,1),e.unlinkDoc(this),Mi(ji(this));break}if(e.history==this.history){var n=[e.id];Io(e,(function(e){return n.push(e.id)}),!0),e.history=new Fo(null),e.history.done=$o(this.history.done,n),e.history.undone=$o(this.history.undone,n)}},iterLinkedDocs:function(e){Io(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):Ae(e)},lineSeparator:function(){return this.lineSep||"\n"},setDirection:ro((function(e){var t;"rtl"!=e&&(e="ltr"),e!=this.direction&&(this.direction=e,this.iter((function(e){return e.order=null})),this.cm&&eo(t=this.cm,(function(){zo(t),dr(t)})))}))}),Ai.prototype.eachLine=Ai.prototype.iter;var Pi=0;function Ri(e){var t=this;if(Di(t),!ge(t,e)&&!kn(t.display,e)){we(e),a&&(Pi=+new Date);var n=cr(t,e,!0),r=e.dataTransfer.files;if(n&&!t.isReadOnly())if(r&&r.length&&window.FileReader&&window.File)for(var o=r.length,i=Array(o),s=0,u=function(){++s==o&&to(t,(function(){var e={from:n=ut(t.doc,n),to:n,text:t.doc.splitLines(i.filter((function(e){return null!=e})).join(t.doc.lineSeparator())),origin:"paste"};fi(t.doc,e),ei(t.doc,So(ut(t.doc,n),ut(t.doc,To(e))))}))()},l=function(e,n){if(t.options.allowDropFileTypes&&-1==H(t.options.allowDropFileTypes,e.type))u();else{var r=new FileReader;r.onerror=function(){return u()},r.onload=function(){var e=r.result;/[\x00-\x08\x0e-\x1f]{2}/.test(e)||(i[n]=e),u()},r.readAsText(e)}},c=0;c<r.length;c++)l(r[c],c);else{if(t.state.draggingText&&t.doc.sel.contains(n)>-1)return t.state.draggingText(e),void setTimeout((function(){return t.display.input.focus()}),20);try{var f=e.dataTransfer.getData("Text");if(f){var d;if(t.state.draggingText&&!t.state.draggingText.copy&&(d=t.listSelections()),ni(t.doc,So(n,n)),d)for(var p=0;p<d.length;++p)gi(t.doc,"",d[p].anchor,d[p].head,"drag");t.replaceSelection(f,"around","paste"),t.display.input.focus()}}catch(e){}}}}function Di(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function Ii(e){if(document.getElementsByClassName){for(var t=document.getElementsByClassName("CodeMirror"),n=[],r=0;r<t.length;r++){var o=t[r].CodeMirror;o&&n.push(o)}n.length&&n[0].operation((function(){for(var t=0;t<n.length;t++)e(n[t])}))}}var Ni=!1;function zi(){var e;Ni||(de(window,"resize",(function(){null==e&&(e=setTimeout((function(){e=null,Ii(Fi)}),100))})),de(window,"blur",(function(){return Ii(Er)})),Ni=!0)}function Fi(e){var t=e.display;t.cachedCharWidth=t.cachedTextHeight=t.cachedPaddingH=null,t.scrollbarsClipped=!1,e.setSize()}for(var Bi={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},Hi=0;Hi<10;Hi++)Bi[Hi+48]=Bi[Hi+96]=String(Hi);for(var Ui=65;Ui<=90;Ui++)Bi[Ui]=String.fromCharCode(Ui);for(var Wi=1;Wi<=12;Wi++)Bi[Wi+111]=Bi[Wi+63235]="F"+Wi;var Vi={};function qi(e){var t,n,r,o,i=e.split(/-(?!$)/);e=i[i.length-1];for(var a=0;a<i.length-1;a++){var s=i[a];if(/^(cmd|meta|m)$/i.test(s))o=!0;else if(/^a(lt)?$/i.test(s))t=!0;else if(/^(c|ctrl|control)$/i.test(s))n=!0;else{if(!/^s(hift)?$/i.test(s))throw new Error("Unrecognized modifier name: "+s);r=!0}}return t&&(e="Alt-"+e),n&&(e="Ctrl-"+e),o&&(e="Cmd-"+e),r&&(e="Shift-"+e),e}function Yi(e){var t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];if(/^(name|fallthrough|(de|at)tach)$/.test(n))continue;if("..."==r){delete e[n];continue}for(var o=Z(n.split(" "),qi),i=0;i<o.length;i++){var a=void 0,s=void 0;i==o.length-1?(s=o.join(" "),a=r):(s=o.slice(0,i+1).join(" "),a="...");var u=t[s];if(u){if(u!=a)throw new Error("Inconsistent bindings for "+s)}else t[s]=a}delete e[n]}for(var l in t)e[l]=t[l];return e}function Gi(e,t,n,r){var o=(t=Xi(t)).call?t.call(e,r):t[e];if(!1===o)return"nothing";if("..."===o)return"multi";if(null!=o&&n(o))return"handled";if(t.fallthrough){if("[object Array]"!=Object.prototype.toString.call(t.fallthrough))return Gi(e,t.fallthrough,n,r);for(var i=0;i<t.fallthrough.length;i++){var a=Gi(e,t.fallthrough[i],n,r);if(a)return a}}}function $i(e){var t="string"==typeof e?e:Bi[e.keyCode];return"Ctrl"==t||"Alt"==t||"Shift"==t||"Mod"==t}function Ki(e,t,n){var r=e;return t.altKey&&"Alt"!=r&&(e="Alt-"+e),(k?t.metaKey:t.ctrlKey)&&"Ctrl"!=r&&(e="Ctrl-"+e),(k?t.ctrlKey:t.metaKey)&&"Mod"!=r&&(e="Cmd-"+e),!n&&t.shiftKey&&"Shift"!=r&&(e="Shift-"+e),e}function Zi(e,t){if(d&&34==e.keyCode&&e.char)return!1;var n=Bi[e.keyCode];return null!=n&&!e.altGraphKey&&(3==e.keyCode&&e.code&&(n=e.code),Ki(n,e,t))}function Xi(e){return"string"==typeof e?Vi[e]:e}function Qi(e,t){for(var n=e.doc.sel.ranges,r=[],o=0;o<n.length;o++){for(var i=t(n[o]);r.length&&nt(i.from,K(r).to)<=0;){var a=r.pop();if(nt(a.from,i.from)<0){i.from=a.from;break}}r.push(i)}eo(e,(function(){for(var t=r.length-1;t>=0;t--)gi(e.doc,"",r[t].from,r[t].to,"+delete");Ar(e)}))}function Ji(e,t,n){var r=ie(e.text,t+n,n);return r<0||r>e.text.length?null:r}function ea(e,t,n){var r=Ji(e,t.ch,n);return null==r?null:new tt(t.line,r,n<0?"after":"before")}function ta(e,t,n,r,o){if(e){"rtl"==t.doc.direction&&(o=-o);var i=ce(n,t.doc.direction);if(i){var a,s=o<0?K(i):i[0],u=o<0==(1==s.level)?"after":"before";if(s.level>0||"rtl"==t.doc.direction){var l=Pn(t,n);a=o<0?n.text.length-1:0;var c=Rn(t,l,a).top;a=ae((function(e){return Rn(t,l,e).top==c}),o<0==(1==s.level)?s.from:s.to-1,a),"before"==u&&(a=Ji(n,a,1))}else a=o<0?s.to:s.from;return new tt(r,a,u)}}return new tt(r,o<0?n.text.length:0,o<0?"before":"after")}Vi.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Vi.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Vi.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Vi.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Vi.default=b?Vi.macDefault:Vi.pcDefault;var na={selectAll:li,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),W)},killLine:function(e){return Qi(e,(function(t){if(t.empty()){var n=Ge(e.doc,t.head.line).text.length;return t.head.ch==n&&t.head.line<e.lastLine()?{from:t.head,to:tt(t.head.line+1,0)}:{from:t.head,to:tt(t.head.line,n)}}return{from:t.from(),to:t.to()}}))},deleteLine:function(e){return Qi(e,(function(t){return{from:tt(t.from().line,0),to:ut(e.doc,tt(t.to().line+1,0))}}))},delLineLeft:function(e){return Qi(e,(function(e){return{from:tt(e.from().line,0),to:e.from()}}))},delWrappedLineLeft:function(e){return Qi(e,(function(t){var n=e.charCoords(t.head,"div").top+5;return{from:e.coordsChar({left:0,top:n},"div"),to:t.from()}}))},delWrappedLineRight:function(e){return Qi(e,(function(t){var n=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div");return{from:t.from(),to:r}}))},undo:function(e){return e.undo()},redo:function(e){return e.redo()},undoSelection:function(e){return e.undoSelection()},redoSelection:function(e){return e.redoSelection()},goDocStart:function(e){return e.extendSelection(tt(e.firstLine(),0))},goDocEnd:function(e){return e.extendSelection(tt(e.lastLine()))},goLineStart:function(e){return e.extendSelectionsBy((function(t){return ra(e,t.head.line)}),{origin:"+move",bias:1})},goLineStartSmart:function(e){return e.extendSelectionsBy((function(t){return oa(e,t.head)}),{origin:"+move",bias:1})},goLineEnd:function(e){return e.extendSelectionsBy((function(t){return function(e,t){var n=Ge(e.doc,t),r=function(e){for(var t;t=It(e);)e=t.find(1,!0).line;return e}(n);return r!=n&&(t=Xe(r)),ta(!0,e,n,t,-1)}(e,t.head.line)}),{origin:"+move",bias:-1})},goLineRight:function(e){return e.extendSelectionsBy((function(t){var n=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div")}),q)},goLineLeft:function(e){return e.extendSelectionsBy((function(t){var n=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:0,top:n},"div")}),q)},goLineLeftSmart:function(e){return e.extendSelectionsBy((function(t){var n=e.cursorCoords(t.head,"div").top+5,r=e.coordsChar({left:0,top:n},"div");return r.ch<e.getLine(r.line).search(/\S/)?oa(e,t.head):r}),q)},goLineUp:function(e){return e.moveV(-1,"line")},goLineDown:function(e){return e.moveV(1,"line")},goPageUp:function(e){return e.moveV(-1,"page")},goPageDown:function(e){return e.moveV(1,"page")},goCharLeft:function(e){return e.moveH(-1,"char")},goCharRight:function(e){return e.moveH(1,"char")},goColumnLeft:function(e){return e.moveH(-1,"column")},goColumnRight:function(e){return e.moveH(1,"column")},goWordLeft:function(e){return e.moveH(-1,"word")},goGroupRight:function(e){return e.moveH(1,"group")},goGroupLeft:function(e){return e.moveH(-1,"group")},goWordRight:function(e){return e.moveH(1,"word")},delCharBefore:function(e){return e.deleteH(-1,"codepoint")},delCharAfter:function(e){return e.deleteH(1,"char")},delWordBefore:function(e){return e.deleteH(-1,"word")},delWordAfter:function(e){return e.deleteH(1,"word")},delGroupBefore:function(e){return e.deleteH(-1,"group")},delGroupAfter:function(e){return e.deleteH(1,"group")},indentAuto:function(e){return e.indentSelection("smart")},indentMore:function(e){return e.indentSelection("add")},indentLess:function(e){return e.indentSelection("subtract")},insertTab:function(e){return e.replaceSelection("\t")},insertSoftTab:function(e){for(var t=[],n=e.listSelections(),r=e.options.tabSize,o=0;o<n.length;o++){var i=n[o].from(),a=F(e.getLine(i.line),i.ch,r);t.push($(r-a%r))}e.replaceSelections(t)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){return eo(e,(function(){for(var t=e.listSelections(),n=[],r=0;r<t.length;r++)if(t[r].empty()){var o=t[r].head,i=Ge(e.doc,o.line).text;if(i)if(o.ch==i.length&&(o=new tt(o.line,o.ch-1)),o.ch>0)o=new tt(o.line,o.ch+1),e.replaceRange(i.charAt(o.ch-1)+i.charAt(o.ch-2),tt(o.line,o.ch-2),o,"+transpose");else if(o.line>e.doc.first){var a=Ge(e.doc,o.line-1).text;a&&(o=new tt(o.line,1),e.replaceRange(i.charAt(0)+e.doc.lineSeparator()+a.charAt(a.length-1),tt(o.line-1,a.length-1),o,"+transpose"))}n.push(new Oo(o,o))}e.setSelections(n)}))},newlineAndIndent:function(e){return eo(e,(function(){for(var t=e.listSelections(),n=t.length-1;n>=0;n--)e.replaceRange(e.doc.lineSeparator(),t[n].anchor,t[n].head,"+input");t=e.listSelections();for(var r=0;r<t.length;r++)e.indentLine(t[r].from().line,null,!0);Ar(e)}))},openLine:function(e){return e.replaceSelection("\n","start")},toggleOverwrite:function(e){return e.toggleOverwrite()}};function ra(e,t){var n=Ge(e.doc,t),r=Ft(n);return r!=n&&(t=Xe(r)),ta(!0,e,r,t,1)}function oa(e,t){var n=ra(e,t.line),r=Ge(e.doc,n.line),o=ce(r,e.doc.direction);if(!o||0==o[0].level){var i=Math.max(n.ch,r.text.search(/\S/)),a=t.line==n.line&&t.ch<=i&&t.ch;return tt(n.line,a?0:i,n.sticky)}return n}function ia(e,t,n){if("string"==typeof t&&!(t=na[t]))return!1;e.display.input.ensurePolled();var r=e.display.shift,o=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),n&&(e.display.shift=!1),o=t(e)!=U}finally{e.display.shift=r,e.state.suppressEdits=!1}return o}var aa=new B;function sa(e,t,n,r){var o=e.state.keySeq;if(o){if($i(t))return"handled";if(/\'$/.test(t)?e.state.keySeq=null:aa.set(50,(function(){e.state.keySeq==o&&(e.state.keySeq=null,e.display.input.reset())})),ua(e,o+" "+t,n,r))return!0}return ua(e,t,n,r)}function ua(e,t,n,r){var o=function(e,t,n){for(var r=0;r<e.state.keyMaps.length;r++){var o=Gi(t,e.state.keyMaps[r],n,e);if(o)return o}return e.options.extraKeys&&Gi(t,e.options.extraKeys,n,e)||Gi(t,e.options.keyMap,n,e)}(e,t,r);return"multi"==o&&(e.state.keySeq=t),"handled"==o&&ln(e,"keyHandled",e,t,n),"handled"!=o&&"multi"!=o||(we(n),xr(e)),!!o}function la(e,t){var n=Zi(t,!0);return!!n&&(t.shiftKey&&!e.state.keySeq?sa(e,"Shift-"+n,t,(function(t){return ia(e,t,!0)}))||sa(e,n,t,(function(t){if("string"==typeof t?/^go[A-Z]/.test(t):t.motion)return ia(e,t)})):sa(e,n,t,(function(t){return ia(e,t)})))}var ca=null;function fa(e){var t=this;if(!(e.target&&e.target!=t.display.input.getField()||(t.curOp.focus=P(),ge(t,e)))){a&&s<11&&27==e.keyCode&&(e.returnValue=!1);var r=e.keyCode;t.display.shift=16==r||e.shiftKey;var o=la(t,e);d&&(ca=o?r:null,o||88!=r||Re||!(b?e.metaKey:e.ctrlKey)||t.replaceSelection("",null,"cut")),n&&!b&&!o&&46==r&&e.shiftKey&&!e.ctrlKey&&document.execCommand&&document.execCommand("cut"),18!=r||/\bCodeMirror-crosshair\b/.test(t.display.lineDiv.className)||function(e){var t=e.display.lineDiv;function n(e){18!=e.keyCode&&e.altKey||(S(t,"CodeMirror-crosshair"),he(document,"keyup",n),he(document,"mouseover",n))}R(t,"CodeMirror-crosshair"),de(document,"keyup",n),de(document,"mouseover",n)}(t)}}function da(e){16==e.keyCode&&(this.doc.sel.shift=!1),ge(this,e)}function pa(e){var t=this;if(!(e.target&&e.target!=t.display.input.getField()||kn(t.display,e)||ge(t,e)||e.ctrlKey&&!e.altKey||b&&e.metaKey)){var n=e.keyCode,r=e.charCode;if(d&&n==ca)return ca=null,void we(e);if(!d||e.which&&!(e.which<10)||!la(t,e)){var o=String.fromCharCode(null==r?n:r);"\b"!=o&&(function(e,t,n){return sa(e,"'"+n+"'",t,(function(t){return ia(e,t,!0)}))}(t,e,o)||t.display.input.onKeyPress(e))}}}var ha,va,ga=function(e,t,n){this.time=e,this.pos=t,this.button=n};function ma(e){var t=this,n=t.display;if(!(ge(t,e)||n.activeTouch&&n.input.supportsTouch()))if(n.input.ensurePolled(),n.shift=e.shiftKey,kn(n,e))u||(n.scroller.draggable=!1,setTimeout((function(){return n.scroller.draggable=!0}),100));else if(!wa(t,e)){var r=cr(t,e),o=Oe(e),i=r?function(e,t){var n=+new Date;return va&&va.compare(n,e,t)?(ha=va=null,"triple"):ha&&ha.compare(n,e,t)?(va=new ga(n,e,t),ha=null,"double"):(ha=new ga(n,e,t),va=null,"single")}(r,o):"single";window.focus(),1==o&&t.state.selectingText&&t.state.selectingText(e),r&&function(e,t,n,r,o){var i="Click";return"double"==r?i="Double"+i:"triple"==r&&(i="Triple"+i),sa(e,Ki(i=(1==t?"Left":2==t?"Middle":"Right")+i,o),o,(function(t){if("string"==typeof t&&(t=na[t]),!t)return!1;var r=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),r=t(e,n)!=U}finally{e.state.suppressEdits=!1}return r}))}(t,o,r,i,e)||(1==o?r?function(e,t,n,r){a?setTimeout(N(kr,e),0):e.curOp.focus=P();var o,i=function(e,t,n){var r=e.getOption("configureMouse"),o=r?r(e,t,n):{};if(null==o.unit){var i=w?n.shiftKey&&n.metaKey:n.altKey;o.unit=i?"rectangle":"single"==t?"char":"double"==t?"word":"line"}return(null==o.extend||e.doc.extend)&&(o.extend=e.doc.extend||n.shiftKey),null==o.addNew&&(o.addNew=b?n.metaKey:n.ctrlKey),null==o.moveOnDrag&&(o.moveOnDrag=!(b?n.altKey:n.ctrlKey)),o}(e,n,r),l=e.doc.sel;e.options.dragDrop&&Te&&!e.isReadOnly()&&"single"==n&&(o=l.contains(t))>-1&&(nt((o=l.ranges[o]).from(),t)<0||t.xRel>0)&&(nt(o.to(),t)>0||t.xRel<0)?function(e,t,n,r){var o=e.display,i=!1,l=to(e,(function(t){u&&(o.scroller.draggable=!1),e.state.draggingText=!1,e.state.delayingBlurEvent&&(e.hasFocus()?e.state.delayingBlurEvent=!1:Cr(e)),he(o.wrapper.ownerDocument,"mouseup",l),he(o.wrapper.ownerDocument,"mousemove",c),he(o.scroller,"dragstart",f),he(o.scroller,"drop",l),i||(we(t),r.addNew||Zo(e.doc,n,null,null,r.extend),u&&!p||a&&9==s?setTimeout((function(){o.wrapper.ownerDocument.body.focus({preventScroll:!0}),o.input.focus()}),20):o.input.focus())})),c=function(e){i=i||Math.abs(t.clientX-e.clientX)+Math.abs(t.clientY-e.clientY)>=10},f=function(){return i=!0};u&&(o.scroller.draggable=!0),e.state.draggingText=l,l.copy=!r.moveOnDrag,de(o.wrapper.ownerDocument,"mouseup",l),de(o.wrapper.ownerDocument,"mousemove",c),de(o.scroller,"dragstart",f),de(o.scroller,"drop",l),e.state.delayingBlurEvent=!0,setTimeout((function(){return o.input.focus()}),20),o.scroller.dragDrop&&o.scroller.dragDrop()}(e,r,t,i):function(e,t,n,r){a&&Cr(e);var o=e.display,i=e.doc;we(t);var s,u,l=i.sel,c=l.ranges;if(r.addNew&&!r.extend?(u=i.sel.contains(n),s=u>-1?c[u]:new Oo(n,n)):(s=i.sel.primary(),u=i.sel.primIndex),"rectangle"==r.unit)r.addNew||(s=new Oo(n,n)),n=cr(e,t,!0,!0),u=-1;else{var f=ya(e,n,r.unit);s=r.extend?Ko(s,f.anchor,f.head,r.extend):f}r.addNew?-1==u?(u=c.length,ti(i,Eo(e,c.concat([s]),u),{scroll:!1,origin:"*mouse"})):c.length>1&&c[u].empty()&&"char"==r.unit&&!r.extend?(ti(i,Eo(e,c.slice(0,u).concat(c.slice(u+1)),0),{scroll:!1,origin:"*mouse"}),l=i.sel):Qo(i,u,s,V):(u=0,ti(i,new Co([s],0),V),l=i.sel);var d=n;function p(t){if(0!=nt(d,t))if(d=t,"rectangle"==r.unit){for(var o=[],a=e.options.tabSize,c=F(Ge(i,n.line).text,n.ch,a),f=F(Ge(i,t.line).text,t.ch,a),p=Math.min(c,f),h=Math.max(c,f),v=Math.min(n.line,t.line),g=Math.min(e.lastLine(),Math.max(n.line,t.line));v<=g;v++){var m=Ge(i,v).text,y=Y(m,p,a);p==h?o.push(new Oo(tt(v,y),tt(v,y))):m.length>y&&o.push(new Oo(tt(v,y),tt(v,Y(m,h,a))))}o.length||o.push(new Oo(n,n)),ti(i,Eo(e,l.ranges.slice(0,u).concat(o),u),{origin:"*mouse",scroll:!1}),e.scrollIntoView(t)}else{var b,w=s,_=ya(e,t,r.unit),x=w.anchor;nt(_.anchor,x)>0?(b=_.head,x=at(w.from(),_.anchor)):(b=_.anchor,x=it(w.to(),_.head));var k=l.ranges.slice(0);k[u]=function(e,t){var n=t.anchor,r=t.head,o=Ge(e.doc,n.line);if(0==nt(n,r)&&n.sticky==r.sticky)return t;var i=ce(o);if(!i)return t;var a=ue(i,n.ch,n.sticky),s=i[a];if(s.from!=n.ch&&s.to!=n.ch)return t;var u,l=a+(s.from==n.ch==(1!=s.level)?0:1);if(0==l||l==i.length)return t;if(r.line!=n.line)u=(r.line-n.line)*("ltr"==e.doc.direction?1:-1)>0;else{var c=ue(i,r.ch,r.sticky),f=c-a||(r.ch-n.ch)*(1==s.level?-1:1);u=c==l-1||c==l?f<0:f>0}var d=i[l+(u?-1:0)],p=u==(1==d.level),h=p?d.from:d.to,v=p?"after":"before";return n.ch==h&&n.sticky==v?t:new Oo(new tt(n.line,h,v),r)}(e,new Oo(ut(i,x),b)),ti(i,Eo(e,k,u),V)}}var h=o.wrapper.getBoundingClientRect(),v=0;function g(t){e.state.selectingText=!1,v=1/0,t&&(we(t),o.input.focus()),he(o.wrapper.ownerDocument,"mousemove",m),he(o.wrapper.ownerDocument,"mouseup",y),i.history.lastSelOrigin=null}var m=to(e,(function(t){0!==t.buttons&&Oe(t)?function t(n){var a=++v,s=cr(e,n,!0,"rectangle"==r.unit);if(s)if(0!=nt(s,d)){e.curOp.focus=P(),p(s);var u=jr(o,i);(s.line>=u.to||s.line<u.from)&&setTimeout(to(e,(function(){v==a&&t(n)})),150)}else{var l=n.clientY<h.top?-20:n.clientY>h.bottom?20:0;l&&setTimeout(to(e,(function(){v==a&&(o.scroller.scrollTop+=l,t(n))})),50)}}(t):g(t)})),y=to(e,g);e.state.selectingText=y,de(o.wrapper.ownerDocument,"mousemove",m),de(o.wrapper.ownerDocument,"mouseup",y)}(e,r,t,i)}(t,r,i,e):Ce(e)==n.scroller&&we(e):2==o?(r&&Zo(t.doc,r),setTimeout((function(){return n.input.focus()}),20)):3==o&&(C?t.display.input.onContextMenu(e):Cr(t)))}}function ya(e,t,n){if("char"==n)return new Oo(t,t);if("word"==n)return e.findWordAt(t);if("line"==n)return new Oo(tt(t.line,0),ut(e.doc,tt(t.line+1,0)));var r=n(e,t);return new Oo(r.from,r.to)}function ba(e,t,n,r){var o,i;if(t.touches)o=t.touches[0].clientX,i=t.touches[0].clientY;else try{o=t.clientX,i=t.clientY}catch(e){return!1}if(o>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;r&&we(t);var a=e.display,s=a.lineDiv.getBoundingClientRect();if(i>s.bottom||!ye(e,n))return xe(t);i-=s.top-a.viewOffset;for(var u=0;u<e.display.gutterSpecs.length;++u){var l=a.gutters.childNodes[u];if(l&&l.getBoundingClientRect().right>=o)return ve(e,n,e,Qe(e.doc,i),e.display.gutterSpecs[u].className,t),xe(t)}}function wa(e,t){return ba(e,t,"gutterClick",!0)}function _a(e,t){kn(e.display,t)||function(e,t){return!!ye(e,"gutterContextMenu")&&ba(e,t,"gutterContextMenu",!1)}(e,t)||ge(e,t,"contextmenu")||C||e.display.input.onContextMenu(t)}function xa(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Hn(e)}ga.prototype.compare=function(e,t,n){return this.time+400>e&&0==nt(t,this.pos)&&n==this.button};var ka={toString:function(){return"CodeMirror.Init"}},Ca={},Oa={};function Ea(e,t,n){if(!t!=!(n&&n!=ka)){var r=e.display.dragFunctions,o=t?de:he;o(e.display.scroller,"dragstart",r.start),o(e.display.scroller,"dragenter",r.enter),o(e.display.scroller,"dragover",r.over),o(e.display.scroller,"dragleave",r.leave),o(e.display.scroller,"drop",r.drop)}}function Sa(e){e.options.lineWrapping?(R(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(S(e.display.wrapper,"CodeMirror-wrap"),Yt(e)),lr(e),dr(e),Hn(e),setTimeout((function(){return Ur(e)}),100)}function Ta(e,t){var n=this;if(!(this instanceof Ta))return new Ta(e,t);this.options=t=t?z(t):{},z(Ca,t,!1);var r=t.value;"string"==typeof r?r=new Ai(r,t.mode,null,t.lineSeparator,t.direction):t.mode&&(r.modeOption=t.mode),this.doc=r;var o=new Ta.inputStyles[t.inputStyle](this),i=this.display=new yo(e,r,o,t);for(var l in i.wrapper.CodeMirror=this,xa(this),t.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),qr(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new B,keySeq:null,specialChars:null},t.autofocus&&!y&&i.input.focus(),a&&s<11&&setTimeout((function(){return n.display.input.reset(!0)}),20),function(e){var t=e.display;de(t.scroller,"mousedown",to(e,ma)),de(t.scroller,"dblclick",a&&s<11?to(e,(function(t){if(!ge(e,t)){var n=cr(e,t);if(n&&!wa(e,t)&&!kn(e.display,t)){we(t);var r=e.findWordAt(n);Zo(e.doc,r.anchor,r.head)}}})):function(t){return ge(e,t)||we(t)}),de(t.scroller,"contextmenu",(function(t){return _a(e,t)})),de(t.input.getField(),"contextmenu",(function(n){t.scroller.contains(n.target)||_a(e,n)}));var n,r={end:0};function o(){t.activeTouch&&(n=setTimeout((function(){return t.activeTouch=null}),1e3),(r=t.activeTouch).end=+new Date)}function i(e,t){if(null==t.left)return!0;var n=t.left-e.left,r=t.top-e.top;return n*n+r*r>400}de(t.scroller,"touchstart",(function(o){if(!ge(e,o)&&!function(e){if(1!=e.touches.length)return!1;var t=e.touches[0];return t.radiusX<=1&&t.radiusY<=1}(o)&&!wa(e,o)){t.input.ensurePolled(),clearTimeout(n);var i=+new Date;t.activeTouch={start:i,moved:!1,prev:i-r.end<=300?r:null},1==o.touches.length&&(t.activeTouch.left=o.touches[0].pageX,t.activeTouch.top=o.touches[0].pageY)}})),de(t.scroller,"touchmove",(function(){t.activeTouch&&(t.activeTouch.moved=!0)})),de(t.scroller,"touchend",(function(n){var r=t.activeTouch;if(r&&!kn(t,n)&&null!=r.left&&!r.moved&&new Date-r.start<300){var a,s=e.coordsChar(t.activeTouch,"page");a=!r.prev||i(r,r.prev)?new Oo(s,s):!r.prev.prev||i(r,r.prev.prev)?e.findWordAt(s):new Oo(tt(s.line,0),ut(e.doc,tt(s.line+1,0))),e.setSelection(a.anchor,a.head),e.focus(),we(n)}o()})),de(t.scroller,"touchcancel",o),de(t.scroller,"scroll",(function(){t.scroller.clientHeight&&(Ir(e,t.scroller.scrollTop),zr(e,t.scroller.scrollLeft,!0),ve(e,"scroll",e))})),de(t.scroller,"mousewheel",(function(t){return ko(e,t)})),de(t.scroller,"DOMMouseScroll",(function(t){return ko(e,t)})),de(t.wrapper,"scroll",(function(){return t.wrapper.scrollTop=t.wrapper.scrollLeft=0})),t.dragFunctions={enter:function(t){ge(e,t)||ke(t)},over:function(t){ge(e,t)||(function(e,t){var n=cr(e,t);if(n){var r=document.createDocumentFragment();br(e,n,r),e.display.dragCursor||(e.display.dragCursor=M("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),j(e.display.dragCursor,r)}}(e,t),ke(t))},start:function(t){return function(e,t){if(a&&(!e.state.draggingText||+new Date-Pi<100))ke(t);else if(!ge(e,t)&&!kn(e.display,t)&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!p)){var n=M("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",d&&(n.width=n.height=1,e.display.wrapper.appendChild(n),n._top=n.offsetTop),t.dataTransfer.setDragImage(n,0,0),d&&n.parentNode.removeChild(n)}}(e,t)},drop:to(e,Ri),leave:function(t){ge(e,t)||Di(e)}};var u=t.input.getField();de(u,"keyup",(function(t){return da.call(e,t)})),de(u,"keydown",to(e,fa)),de(u,"keypress",to(e,pa)),de(u,"focus",(function(t){return Or(e,t)})),de(u,"blur",(function(t){return Er(e,t)}))}(this),zi(),Gr(this),this.curOp.forceUpdate=!0,No(this,r),t.autofocus&&!y||this.hasFocus()?setTimeout((function(){n.hasFocus()&&!n.state.focused&&Or(n)}),20):Er(this),Oa)Oa.hasOwnProperty(l)&&Oa[l](this,t[l],ka);ho(this),t.finishInit&&t.finishInit(this);for(var c=0;c<ja.length;++c)ja[c](this);$r(this),u&&t.lineWrapping&&"optimizelegibility"==getComputedStyle(i.lineDiv).textRendering&&(i.lineDiv.style.textRendering="auto")}Ta.defaults=Ca,Ta.optionHandlers=Oa;var ja=[];function Ma(e,t,n,r){var o,i=e.doc;null==n&&(n="add"),"smart"==n&&(i.mode.indent?o=ht(e,t).state:n="prev");var a=e.options.tabSize,s=Ge(i,t),u=F(s.text,null,a);s.stateAfter&&(s.stateAfter=null);var l,c=s.text.match(/^\s*/)[0];if(r||/\S/.test(s.text)){if("smart"==n&&((l=i.mode.indent(o,s.text.slice(c.length),s.text))==U||l>150)){if(!r)return;n="prev"}}else l=0,n="not";"prev"==n?l=t>i.first?F(Ge(i,t-1).text,null,a):0:"add"==n?l=u+e.options.indentUnit:"subtract"==n?l=u-e.options.indentUnit:"number"==typeof n&&(l=u+n),l=Math.max(0,l);var f="",d=0;if(e.options.indentWithTabs)for(var p=Math.floor(l/a);p;--p)d+=a,f+="\t";if(d<l&&(f+=$(l-d)),f!=c)return gi(i,f,tt(t,0),tt(t,c.length),"+input"),s.stateAfter=null,!0;for(var h=0;h<i.sel.ranges.length;h++){var v=i.sel.ranges[h];if(v.head.line==t&&v.head.ch<c.length){var g=tt(t,c.length);Qo(i,h,new Oo(g,g));break}}}Ta.defineInitHook=function(e){return ja.push(e)};var La=null;function Aa(e){La=e}function Pa(e,t,n,r,o){var i=e.doc;e.display.shift=!1,r||(r=i.sel);var a=+new Date-200,s="paste"==o||e.state.pasteIncoming>a,u=Ae(t),l=null;if(s&&r.ranges.length>1)if(La&&La.text.join("\n")==t){if(r.ranges.length%La.text.length==0){l=[];for(var c=0;c<La.text.length;c++)l.push(i.splitLines(La.text[c]))}}else u.length==r.ranges.length&&e.options.pasteLinesPerSelection&&(l=Z(u,(function(e){return[e]})));for(var f=e.curOp.updateInput,d=r.ranges.length-1;d>=0;d--){var p=r.ranges[d],h=p.from(),v=p.to();p.empty()&&(n&&n>0?h=tt(h.line,h.ch-n):e.state.overwrite&&!s?v=tt(v.line,Math.min(Ge(i,v.line).text.length,v.ch+K(u).length)):s&&La&&La.lineWise&&La.text.join("\n")==u.join("\n")&&(h=v=tt(h.line,0)));var g={from:h,to:v,text:l?l[d%l.length]:u,origin:o||(s?"paste":e.state.cutIncoming>a?"cut":"+input")};fi(e.doc,g),ln(e,"inputRead",e,g)}t&&!s&&Da(e,t),Ar(e),e.curOp.updateInput<2&&(e.curOp.updateInput=f),e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=-1}function Ra(e,t){var n=e.clipboardData&&e.clipboardData.getData("Text");if(n)return e.preventDefault(),t.isReadOnly()||t.options.disableInput||!t.hasFocus()||eo(t,(function(){return Pa(t,n,0,null,"paste")})),!0}function Da(e,t){if(e.options.electricChars&&e.options.smartIndent)for(var n=e.doc.sel,r=n.ranges.length-1;r>=0;r--){var o=n.ranges[r];if(!(o.head.ch>100||r&&n.ranges[r-1].head.line==o.head.line)){var i=e.getModeAt(o.head),a=!1;if(i.electricChars){for(var s=0;s<i.electricChars.length;s++)if(t.indexOf(i.electricChars.charAt(s))>-1){a=Ma(e,o.head.line,"smart");break}}else i.electricInput&&i.electricInput.test(Ge(e.doc,o.head.line).text.slice(0,o.head.ch))&&(a=Ma(e,o.head.line,"smart"));a&&ln(e,"electricInput",e,o.head.line)}}}function Ia(e){for(var t=[],n=[],r=0;r<e.doc.sel.ranges.length;r++){var o=e.doc.sel.ranges[r].head.line,i={anchor:tt(o,0),head:tt(o+1,0)};n.push(i),t.push(e.getRange(i.anchor,i.head))}return{text:t,ranges:n}}function Na(e,t,n,r){e.setAttribute("autocorrect",n?"":"off"),e.setAttribute("autocapitalize",r?"":"off"),e.setAttribute("spellcheck",!!t)}function za(){var e=M("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; min-height: 1em; outline: none"),t=M("div",[e],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return u?e.style.width="1000px":e.setAttribute("wrap","off"),g&&(e.style.border="1px solid black"),Na(e),t}function Fa(e,t,n,r,o){var i=t,a=n,s=Ge(e,t.line),u=o&&"rtl"==e.direction?-n:n;function l(i){var a,l;if("codepoint"==r){var c=s.text.charCodeAt(t.ch+(n>0?0:-1));if(isNaN(c))a=null;else{var f=n>0?c>=55296&&c<56320:c>=56320&&c<57343;a=new tt(t.line,Math.max(0,Math.min(s.text.length,t.ch+n*(f?2:1))),-n)}}else a=o?function(e,t,n,r){var o=ce(t,e.doc.direction);if(!o)return ea(t,n,r);n.ch>=t.text.length?(n.ch=t.text.length,n.sticky="before"):n.ch<=0&&(n.ch=0,n.sticky="after");var i=ue(o,n.ch,n.sticky),a=o[i];if("ltr"==e.doc.direction&&a.level%2==0&&(r>0?a.to>n.ch:a.from<n.ch))return ea(t,n,r);var s,u=function(e,n){return Ji(t,e instanceof tt?e.ch:e,n)},l=function(n){return e.options.lineWrapping?(s=s||Pn(e,t),Jn(e,t,s,n)):{begin:0,end:t.text.length}},c=l("before"==n.sticky?u(n,-1):n.ch);if("rtl"==e.doc.direction||1==a.level){var f=1==a.level==r<0,d=u(n,f?1:-1);if(null!=d&&(f?d<=a.to&&d<=c.end:d>=a.from&&d>=c.begin)){var p=f?"before":"after";return new tt(n.line,d,p)}}var h=function(e,t,r){for(var i=function(e,t){return t?new tt(n.line,u(e,1),"before"):new tt(n.line,e,"after")};e>=0&&e<o.length;e+=t){var a=o[e],s=t>0==(1!=a.level),l=s?r.begin:u(r.end,-1);if(a.from<=l&&l<a.to)return i(l,s);if(l=s?a.from:u(a.to,-1),r.begin<=l&&l<r.end)return i(l,s)}},v=h(i+r,r,c);if(v)return v;var g=r>0?c.end:u(c.begin,-1);return null==g||r>0&&g==t.text.length||!(v=h(r>0?0:o.length-1,r,l(g)))?null:v}(e.cm,s,t,n):ea(s,t,n);if(null==a){if(i||(l=t.line+u)<e.first||l>=e.first+e.size||(t=new tt(l,t.ch,t.sticky),!(s=Ge(e,l))))return!1;t=ta(o,e.cm,s,t.line,u)}else t=a;return!0}if("char"==r||"codepoint"==r)l();else if("column"==r)l(!0);else if("word"==r||"group"==r)for(var c=null,f="group"==r,d=e.cm&&e.cm.getHelper(t,"wordChars"),p=!0;!(n<0)||l(!p);p=!1){var h=s.text.charAt(t.ch)||"\n",v=te(h,d)?"w":f&&"\n"==h?"n":!f||/\s/.test(h)?null:"p";if(!f||p||v||(v="s"),c&&c!=v){n<0&&(n=1,l(),t.sticky="after");break}if(v&&(c=v),n>0&&!l(!p))break}var g=si(e,t,i,a,!0);return rt(i,g)&&(g.hitSide=!0),g}function Ba(e,t,n,r){var o,i,a=e.doc,s=t.left;if("page"==r){var u=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),l=Math.max(u-.5*or(e.display),3);o=(n>0?t.bottom:t.top)+n*l}else"line"==r&&(o=n>0?t.bottom+3:t.top-3);for(;(i=Xn(e,s,o)).outside;){if(n<0?o<=0:o>=a.height){i.hitSide=!0;break}o+=5*n}return i}var Ha=function(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new B,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function Ua(e,t){var n=An(e,t.line);if(!n||n.hidden)return null;var r=Ge(e.doc,t.line),o=Mn(n,r,t.line),i=ce(r,e.doc.direction),a="left";i&&(a=ue(i,t.ch)%2?"right":"left");var s=Nn(o.map,t.ch,a);return s.offset="right"==s.collapse?s.end:s.start,s}function Wa(e,t){return t&&(e.bad=!0),e}function Va(e,t,n){var r;if(t==e.display.lineDiv){if(!(r=e.display.lineDiv.childNodes[n]))return Wa(e.clipPos(tt(e.display.viewTo-1)),!0);t=null,n=0}else for(r=t;;r=r.parentNode){if(!r||r==e.display.lineDiv)return null;if(r.parentNode&&r.parentNode==e.display.lineDiv)break}for(var o=0;o<e.display.view.length;o++){var i=e.display.view[o];if(i.node==r)return qa(i,t,n)}}function qa(e,t,n){var r=e.text.firstChild,o=!1;if(!t||!A(r,t))return Wa(tt(Xe(e.line),0),!0);if(t==r&&(o=!0,t=r.childNodes[n],n=0,!t)){var i=e.rest?K(e.rest):e.line;return Wa(tt(Xe(i),i.text.length),o)}var a=3==t.nodeType?t:null,s=t;for(a||1!=t.childNodes.length||3!=t.firstChild.nodeType||(a=t.firstChild,n&&(n=a.nodeValue.length));s.parentNode!=r;)s=s.parentNode;var u=e.measure,l=u.maps;function c(t,n,r){for(var o=-1;o<(l?l.length:0);o++)for(var i=o<0?u.map:l[o],a=0;a<i.length;a+=3){var s=i[a+2];if(s==t||s==n){var c=Xe(o<0?e.line:e.rest[o]),f=i[a]+r;return(r<0||s!=t)&&(f=i[a+(r?1:0)]),tt(c,f)}}}var f=c(a,s,n);if(f)return Wa(f,o);for(var d=s.nextSibling,p=a?a.nodeValue.length-n:0;d;d=d.nextSibling){if(f=c(d,d.firstChild,0))return Wa(tt(f.line,f.ch-p),o);p+=d.textContent.length}for(var h=s.previousSibling,v=n;h;h=h.previousSibling){if(f=c(h,h.firstChild,-1))return Wa(tt(f.line,f.ch+v),o);v+=h.textContent.length}}Ha.prototype.init=function(e){var t=this,n=this,r=n.cm,o=n.div=e.lineDiv;function i(e){for(var t=e.target;t;t=t.parentNode){if(t==o)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(t.className))break}return!1}function a(e){if(i(e)&&!ge(r,e)){if(r.somethingSelected())Aa({lineWise:!1,text:r.getSelections()}),"cut"==e.type&&r.replaceSelection("",null,"cut");else{if(!r.options.lineWiseCopyCut)return;var t=Ia(r);Aa({lineWise:!0,text:t.text}),"cut"==e.type&&r.operation((function(){r.setSelections(t.ranges,0,W),r.replaceSelection("",null,"cut")}))}if(e.clipboardData){e.clipboardData.clearData();var a=La.text.join("\n");if(e.clipboardData.setData("Text",a),e.clipboardData.getData("Text")==a)return void e.preventDefault()}var s=za(),u=s.firstChild;r.display.lineSpace.insertBefore(s,r.display.lineSpace.firstChild),u.value=La.text.join("\n");var l=P();I(u),setTimeout((function(){r.display.lineSpace.removeChild(s),l.focus(),l==o&&n.showPrimarySelection()}),50)}}o.contentEditable=!0,Na(o,r.options.spellcheck,r.options.autocorrect,r.options.autocapitalize),de(o,"paste",(function(e){!i(e)||ge(r,e)||Ra(e,r)||s<=11&&setTimeout(to(r,(function(){return t.updateFromDOM()})),20)})),de(o,"compositionstart",(function(e){t.composing={data:e.data,done:!1}})),de(o,"compositionupdate",(function(e){t.composing||(t.composing={data:e.data,done:!1})})),de(o,"compositionend",(function(e){t.composing&&(e.data!=t.composing.data&&t.readFromDOMSoon(),t.composing.done=!0)})),de(o,"touchstart",(function(){return n.forceCompositionEnd()})),de(o,"input",(function(){t.composing||t.readFromDOMSoon()})),de(o,"copy",a),de(o,"cut",a)},Ha.prototype.screenReaderLabelChanged=function(e){e?this.div.setAttribute("aria-label",e):this.div.removeAttribute("aria-label")},Ha.prototype.prepareSelection=function(){var e=yr(this.cm,!1);return e.focus=P()==this.div,e},Ha.prototype.showSelection=function(e,t){e&&this.cm.display.view.length&&((e.focus||t)&&this.showPrimarySelection(),this.showMultipleSelections(e))},Ha.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Ha.prototype.showPrimarySelection=function(){var e=this.getSelection(),t=this.cm,r=t.doc.sel.primary(),o=r.from(),i=r.to();if(t.display.viewTo==t.display.viewFrom||o.line>=t.display.viewTo||i.line<t.display.viewFrom)e.removeAllRanges();else{var a=Va(t,e.anchorNode,e.anchorOffset),s=Va(t,e.focusNode,e.focusOffset);if(!a||a.bad||!s||s.bad||0!=nt(at(a,s),o)||0!=nt(it(a,s),i)){var u=t.display.view,l=o.line>=t.display.viewFrom&&Ua(t,o)||{node:u[0].measure.map[2],offset:0},c=i.line<t.display.viewTo&&Ua(t,i);if(!c){var f=u[u.length-1].measure,d=f.maps?f.maps[f.maps.length-1]:f.map;c={node:d[d.length-1],offset:d[d.length-2]-d[d.length-3]}}if(l&&c){var p,h=e.rangeCount&&e.getRangeAt(0);try{p=E(l.node,l.offset,c.offset,c.node)}catch(e){}p&&(!n&&t.state.focused?(e.collapse(l.node,l.offset),p.collapsed||(e.removeAllRanges(),e.addRange(p))):(e.removeAllRanges(),e.addRange(p)),h&&null==e.anchorNode?e.addRange(h):n&&this.startGracePeriod()),this.rememberSelection()}else e.removeAllRanges()}}},Ha.prototype.startGracePeriod=function(){var e=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout((function(){e.gracePeriod=!1,e.selectionChanged()&&e.cm.operation((function(){return e.cm.curOp.selectionChanged=!0}))}),20)},Ha.prototype.showMultipleSelections=function(e){j(this.cm.display.cursorDiv,e.cursors),j(this.cm.display.selectionDiv,e.selection)},Ha.prototype.rememberSelection=function(){var e=this.getSelection();this.lastAnchorNode=e.anchorNode,this.lastAnchorOffset=e.anchorOffset,this.lastFocusNode=e.focusNode,this.lastFocusOffset=e.focusOffset},Ha.prototype.selectionInEditor=function(){var e=this.getSelection();if(!e.rangeCount)return!1;var t=e.getRangeAt(0).commonAncestorContainer;return A(this.div,t)},Ha.prototype.focus=function(){"nocursor"!=this.cm.options.readOnly&&(this.selectionInEditor()&&P()==this.div||this.showSelection(this.prepareSelection(),!0),this.div.focus())},Ha.prototype.blur=function(){this.div.blur()},Ha.prototype.getField=function(){return this.div},Ha.prototype.supportsTouch=function(){return!0},Ha.prototype.receivedFocus=function(){var e=this,t=this;this.selectionInEditor()?setTimeout((function(){return e.pollSelection()}),20):eo(this.cm,(function(){return t.cm.curOp.selectionChanged=!0})),this.polling.set(this.cm.options.pollInterval,(function e(){t.cm.state.focused&&(t.pollSelection(),t.polling.set(t.cm.options.pollInterval,e))}))},Ha.prototype.selectionChanged=function(){var e=this.getSelection();return e.anchorNode!=this.lastAnchorNode||e.anchorOffset!=this.lastAnchorOffset||e.focusNode!=this.lastFocusNode||e.focusOffset!=this.lastFocusOffset},Ha.prototype.pollSelection=function(){if(null==this.readDOMTimeout&&!this.gracePeriod&&this.selectionChanged()){var e=this.getSelection(),t=this.cm;if(m&&c&&this.cm.display.gutterSpecs.length&&function(e){for(var t=e;t;t=t.parentNode)if(/CodeMirror-gutter-wrapper/.test(t.className))return!0;return!1}(e.anchorNode))return this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),void this.focus();if(!this.composing){this.rememberSelection();var n=Va(t,e.anchorNode,e.anchorOffset),r=Va(t,e.focusNode,e.focusOffset);n&&r&&eo(t,(function(){ti(t.doc,So(n,r),W),(n.bad||r.bad)&&(t.curOp.selectionChanged=!0)}))}}},Ha.prototype.pollContent=function(){null!=this.readDOMTimeout&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var e,t,n,r=this.cm,o=r.display,i=r.doc.sel.primary(),a=i.from(),s=i.to();if(0==a.ch&&a.line>r.firstLine()&&(a=tt(a.line-1,Ge(r.doc,a.line-1).length)),s.ch==Ge(r.doc,s.line).text.length&&s.line<r.lastLine()&&(s=tt(s.line+1,0)),a.line<o.viewFrom||s.line>o.viewTo-1)return!1;a.line==o.viewFrom||0==(e=fr(r,a.line))?(t=Xe(o.view[0].line),n=o.view[0].node):(t=Xe(o.view[e].line),n=o.view[e-1].node.nextSibling);var u,l,c=fr(r,s.line);if(c==o.view.length-1?(u=o.viewTo-1,l=o.lineDiv.lastChild):(u=Xe(o.view[c+1].line)-1,l=o.view[c+1].node.previousSibling),!n)return!1;for(var f=r.doc.splitLines(function(e,t,n,r,o){var i="",a=!1,s=e.doc.lineSeparator(),u=!1;function l(){a&&(i+=s,u&&(i+=s),a=u=!1)}function c(e){e&&(l(),i+=e)}function f(t){if(1==t.nodeType){var n=t.getAttribute("cm-text");if(n)return void c(n);var i,d=t.getAttribute("cm-marker");if(d){var p=e.findMarks(tt(r,0),tt(o+1,0),(g=+d,function(e){return e.id==g}));return void(p.length&&(i=p[0].find(0))&&c($e(e.doc,i.from,i.to).join(s)))}if("false"==t.getAttribute("contenteditable"))return;var h=/^(pre|div|p|li|table|br)$/i.test(t.nodeName);if(!/^br$/i.test(t.nodeName)&&0==t.textContent.length)return;h&&l();for(var v=0;v<t.childNodes.length;v++)f(t.childNodes[v]);/^(pre|p)$/i.test(t.nodeName)&&(u=!0),h&&(a=!0)}else 3==t.nodeType&&c(t.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "));var g}for(;f(t),t!=n;)t=t.nextSibling,u=!1;return i}(r,n,l,t,u)),d=$e(r.doc,tt(t,0),tt(u,Ge(r.doc,u).text.length));f.length>1&&d.length>1;)if(K(f)==K(d))f.pop(),d.pop(),u--;else{if(f[0]!=d[0])break;f.shift(),d.shift(),t++}for(var p=0,h=0,v=f[0],g=d[0],m=Math.min(v.length,g.length);p<m&&v.charCodeAt(p)==g.charCodeAt(p);)++p;for(var y=K(f),b=K(d),w=Math.min(y.length-(1==f.length?p:0),b.length-(1==d.length?p:0));h<w&&y.charCodeAt(y.length-h-1)==b.charCodeAt(b.length-h-1);)++h;if(1==f.length&&1==d.length&&t==a.line)for(;p&&p>a.ch&&y.charCodeAt(y.length-h-1)==b.charCodeAt(b.length-h-1);)p--,h++;f[f.length-1]=y.slice(0,y.length-h).replace(/^\u200b+/,""),f[0]=f[0].slice(p).replace(/\u200b+$/,"");var _=tt(t,p),x=tt(u,d.length?K(d).length-h:0);return f.length>1||f[0]||nt(_,x)?(gi(r.doc,f,_,x,"+input"),!0):void 0},Ha.prototype.ensurePolled=function(){this.forceCompositionEnd()},Ha.prototype.reset=function(){this.forceCompositionEnd()},Ha.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Ha.prototype.readFromDOMSoon=function(){var e=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout((function(){if(e.readDOMTimeout=null,e.composing){if(!e.composing.done)return;e.composing=null}e.updateFromDOM()}),80))},Ha.prototype.updateFromDOM=function(){var e=this;!this.cm.isReadOnly()&&this.pollContent()||eo(this.cm,(function(){return dr(e.cm)}))},Ha.prototype.setUneditable=function(e){e.contentEditable="false"},Ha.prototype.onKeyPress=function(e){0==e.charCode||this.composing||(e.preventDefault(),this.cm.isReadOnly()||to(this.cm,Pa)(this.cm,String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),0))},Ha.prototype.readOnlyChanged=function(e){this.div.contentEditable=String("nocursor"!=e)},Ha.prototype.onContextMenu=function(){},Ha.prototype.resetPosition=function(){},Ha.prototype.needsContentAttribute=!0;var Ya=function(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new B,this.hasSelection=!1,this.composing=null};Ya.prototype.init=function(e){var t=this,n=this,r=this.cm;this.createField(e);var o=this.textarea;function i(e){if(!ge(r,e)){if(r.somethingSelected())Aa({lineWise:!1,text:r.getSelections()});else{if(!r.options.lineWiseCopyCut)return;var t=Ia(r);Aa({lineWise:!0,text:t.text}),"cut"==e.type?r.setSelections(t.ranges,null,W):(n.prevInput="",o.value=t.text.join("\n"),I(o))}"cut"==e.type&&(r.state.cutIncoming=+new Date)}}e.wrapper.insertBefore(this.wrapper,e.wrapper.firstChild),g&&(o.style.width="0px"),de(o,"input",(function(){a&&s>=9&&t.hasSelection&&(t.hasSelection=null),n.poll()})),de(o,"paste",(function(e){ge(r,e)||Ra(e,r)||(r.state.pasteIncoming=+new Date,n.fastPoll())})),de(o,"cut",i),de(o,"copy",i),de(e.scroller,"paste",(function(t){if(!kn(e,t)&&!ge(r,t)){if(!o.dispatchEvent)return r.state.pasteIncoming=+new Date,void n.focus();var i=new Event("paste");i.clipboardData=t.clipboardData,o.dispatchEvent(i)}})),de(e.lineSpace,"selectstart",(function(t){kn(e,t)||we(t)})),de(o,"compositionstart",(function(){var e=r.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:e,range:r.markText(e,r.getCursor("to"),{className:"CodeMirror-composing"})}})),de(o,"compositionend",(function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)}))},Ya.prototype.createField=function(e){this.wrapper=za(),this.textarea=this.wrapper.firstChild},Ya.prototype.screenReaderLabelChanged=function(e){e?this.textarea.setAttribute("aria-label",e):this.textarea.removeAttribute("aria-label")},Ya.prototype.prepareSelection=function(){var e=this.cm,t=e.display,n=e.doc,r=yr(e);if(e.options.moveInputWithCursor){var o=$n(e,n.sel.primary().head,"div"),i=t.wrapper.getBoundingClientRect(),a=t.lineDiv.getBoundingClientRect();r.teTop=Math.max(0,Math.min(t.wrapper.clientHeight-10,o.top+a.top-i.top)),r.teLeft=Math.max(0,Math.min(t.wrapper.clientWidth-10,o.left+a.left-i.left))}return r},Ya.prototype.showSelection=function(e){var t=this.cm.display;j(t.cursorDiv,e.cursors),j(t.selectionDiv,e.selection),null!=e.teTop&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},Ya.prototype.reset=function(e){if(!this.contextMenuPending&&!this.composing){var t=this.cm;if(t.somethingSelected()){this.prevInput="";var n=t.getSelection();this.textarea.value=n,t.state.focused&&I(this.textarea),a&&s>=9&&(this.hasSelection=n)}else e||(this.prevInput=this.textarea.value="",a&&s>=9&&(this.hasSelection=null))}},Ya.prototype.getField=function(){return this.textarea},Ya.prototype.supportsTouch=function(){return!1},Ya.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!y||P()!=this.textarea))try{this.textarea.focus()}catch(e){}},Ya.prototype.blur=function(){this.textarea.blur()},Ya.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Ya.prototype.receivedFocus=function(){this.slowPoll()},Ya.prototype.slowPoll=function(){var e=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,(function(){e.poll(),e.cm.state.focused&&e.slowPoll()}))},Ya.prototype.fastPoll=function(){var e=!1,t=this;t.pollingFast=!0,t.polling.set(20,(function n(){t.poll()||e?(t.pollingFast=!1,t.slowPoll()):(e=!0,t.polling.set(60,n))}))},Ya.prototype.poll=function(){var e=this,t=this.cm,n=this.textarea,r=this.prevInput;if(this.contextMenuPending||!t.state.focused||Pe(n)&&!r&&!this.composing||t.isReadOnly()||t.options.disableInput||t.state.keySeq)return!1;var o=n.value;if(o==r&&!t.somethingSelected())return!1;if(a&&s>=9&&this.hasSelection===o||b&&/[\uf700-\uf7ff]/.test(o))return t.display.input.reset(),!1;if(t.doc.sel==t.display.selForContextMenu){var i=o.charCodeAt(0);if(8203!=i||r||(r="\u200b"),8666==i)return this.reset(),this.cm.execCommand("undo")}for(var u=0,l=Math.min(r.length,o.length);u<l&&r.charCodeAt(u)==o.charCodeAt(u);)++u;return eo(t,(function(){Pa(t,o.slice(u),r.length-u,null,e.composing?"*compose":null),o.length>1e3||o.indexOf("\n")>-1?n.value=e.prevInput="":e.prevInput=o,e.composing&&(e.composing.range.clear(),e.composing.range=t.markText(e.composing.start,t.getCursor("to"),{className:"CodeMirror-composing"}))})),!0},Ya.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Ya.prototype.onKeyPress=function(){a&&s>=9&&(this.hasSelection=null),this.fastPoll()},Ya.prototype.onContextMenu=function(e){var t=this,n=t.cm,r=n.display,o=t.textarea;t.contextMenuPending&&t.contextMenuPending();var i=cr(n,e),l=r.scroller.scrollTop;if(i&&!d){n.options.resetSelectionOnContextMenu&&-1==n.doc.sel.contains(i)&&to(n,ti)(n.doc,So(i),W);var c,f=o.style.cssText,p=t.wrapper.style.cssText,h=t.wrapper.offsetParent.getBoundingClientRect();if(t.wrapper.style.cssText="position: static",o.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(e.clientY-h.top-5)+"px; left: "+(e.clientX-h.left-5)+"px;\n z-index: 1000; background: "+(a?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",u&&(c=window.scrollY),r.input.focus(),u&&window.scrollTo(null,c),r.input.reset(),n.somethingSelected()||(o.value=t.prevInput=" "),t.contextMenuPending=m,r.selForContextMenu=n.doc.sel,clearTimeout(r.detectingSelectAll),a&&s>=9&&g(),C){ke(e);var v=function(){he(window,"mouseup",v),setTimeout(m,20)};de(window,"mouseup",v)}else setTimeout(m,50)}function g(){if(null!=o.selectionStart){var e=n.somethingSelected(),i="\u200b"+(e?o.value:"");o.value="\u21da",o.value=i,t.prevInput=e?"":"\u200b",o.selectionStart=1,o.selectionEnd=i.length,r.selForContextMenu=n.doc.sel}}function m(){if(t.contextMenuPending==m&&(t.contextMenuPending=!1,t.wrapper.style.cssText=p,o.style.cssText=f,a&&s<9&&r.scrollbars.setScrollTop(r.scroller.scrollTop=l),null!=o.selectionStart)){(!a||a&&s<9)&&g();var e=0,i=function(){r.selForContextMenu==n.doc.sel&&0==o.selectionStart&&o.selectionEnd>0&&"\u200b"==t.prevInput?to(n,li)(n):e++<10?r.detectingSelectAll=setTimeout(i,500):(r.selForContextMenu=null,r.input.reset())};r.detectingSelectAll=setTimeout(i,200)}}},Ya.prototype.readOnlyChanged=function(e){e||this.reset(),this.textarea.disabled="nocursor"==e,this.textarea.readOnly=!!e},Ya.prototype.setUneditable=function(){},Ya.prototype.needsContentAttribute=!1,function(e){var t=e.optionHandlers;function n(n,r,o,i){e.defaults[n]=r,o&&(t[n]=i?function(e,t,n){n!=ka&&o(e,t,n)}:o)}e.defineOption=n,e.Init=ka,n("value","",(function(e,t){return e.setValue(t)}),!0),n("mode",null,(function(e,t){e.doc.modeOption=t,Ao(e)}),!0),n("indentUnit",2,Ao,!0),n("indentWithTabs",!1),n("smartIndent",!0),n("tabSize",4,(function(e){Po(e),Hn(e),dr(e)}),!0),n("lineSeparator",null,(function(e,t){if(e.doc.lineSep=t,t){var n=[],r=e.doc.first;e.doc.iter((function(e){for(var o=0;;){var i=e.text.indexOf(t,o);if(-1==i)break;o=i+t.length,n.push(tt(r,i))}r++}));for(var o=n.length-1;o>=0;o--)gi(e.doc,t,n[o],tt(n[o].line,n[o].ch+t.length))}})),n("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,(function(e,t,n){e.state.specialChars=new RegExp(t.source+(t.test("\t")?"":"|\t"),"g"),n!=ka&&e.refresh()})),n("specialCharPlaceholder",Jt,(function(e){return e.refresh()}),!0),n("electricChars",!0),n("inputStyle",y?"contenteditable":"textarea",(function(){throw new Error("inputStyle can not (yet) be changed in a running editor")}),!0),n("spellcheck",!1,(function(e,t){return e.getInputField().spellcheck=t}),!0),n("autocorrect",!1,(function(e,t){return e.getInputField().autocorrect=t}),!0),n("autocapitalize",!1,(function(e,t){return e.getInputField().autocapitalize=t}),!0),n("rtlMoveVisually",!_),n("wholeLineUpdateBefore",!0),n("theme","default",(function(e){xa(e),mo(e)}),!0),n("keyMap","default",(function(e,t,n){var r=Xi(t),o=n!=ka&&Xi(n);o&&o.detach&&o.detach(e,r),r.attach&&r.attach(e,o||null)})),n("extraKeys",null),n("configureMouse",null),n("lineWrapping",!1,Sa,!0),n("gutters",[],(function(e,t){e.display.gutterSpecs=vo(t,e.options.lineNumbers),mo(e)}),!0),n("fixedGutter",!0,(function(e,t){e.display.gutters.style.left=t?sr(e.display)+"px":"0",e.refresh()}),!0),n("coverGutterNextToScrollbar",!1,(function(e){return Ur(e)}),!0),n("scrollbarStyle","native",(function(e){qr(e),Ur(e),e.display.scrollbars.setScrollTop(e.doc.scrollTop),e.display.scrollbars.setScrollLeft(e.doc.scrollLeft)}),!0),n("lineNumbers",!1,(function(e,t){e.display.gutterSpecs=vo(e.options.gutters,t),mo(e)}),!0),n("firstLineNumber",1,mo,!0),n("lineNumberFormatter",(function(e){return e}),mo,!0),n("showCursorWhenSelecting",!1,mr,!0),n("resetSelectionOnContextMenu",!0),n("lineWiseCopyCut",!0),n("pasteLinesPerSelection",!0),n("selectionsMayTouch",!1),n("readOnly",!1,(function(e,t){"nocursor"==t&&(Er(e),e.display.input.blur()),e.display.input.readOnlyChanged(t)})),n("screenReaderLabel",null,(function(e,t){t=""===t?null:t,e.display.input.screenReaderLabelChanged(t)})),n("disableInput",!1,(function(e,t){t||e.display.input.reset()}),!0),n("dragDrop",!0,Ea),n("allowDropFileTypes",null),n("cursorBlinkRate",530),n("cursorScrollMargin",0),n("cursorHeight",1,mr,!0),n("singleCursorHeightPerLine",!0,mr,!0),n("workTime",100),n("workDelay",100),n("flattenSpans",!0,Po,!0),n("addModeClass",!1,Po,!0),n("pollInterval",100),n("undoDepth",200,(function(e,t){return e.doc.history.undoDepth=t})),n("historyEventDelay",1250),n("viewportMargin",10,(function(e){return e.refresh()}),!0),n("maxHighlightLength",1e4,Po,!0),n("moveInputWithCursor",!0,(function(e,t){t||e.display.input.resetPosition()})),n("tabindex",null,(function(e,t){return e.display.input.getField().tabIndex=t||""})),n("autofocus",null),n("direction","ltr",(function(e,t){return e.doc.setDirection(t)}),!0),n("phrases",null)}(Ta),function(e){var t=e.optionHandlers,n=e.helpers={};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(e,n){var r=this.options,o=r[e];r[e]==n&&"mode"!=e||(r[e]=n,t.hasOwnProperty(e)&&to(this,t[e])(this,n,o),ve(this,"optionChange",this,e))},getOption:function(e){return this.options[e]},getDoc:function(){return this.doc},addKeyMap:function(e,t){this.state.keyMaps[t?"push":"unshift"](Xi(e))},removeKeyMap:function(e){for(var t=this.state.keyMaps,n=0;n<t.length;++n)if(t[n]==e||t[n].name==e)return t.splice(n,1),!0},addOverlay:no((function(t,n){var r=t.token?t:e.getMode(this.options,t);if(r.startState)throw new Error("Overlays may not be stateful.");!function(e,t,n){for(var r=0,o=n(t);r<e.length&&n(e[r])<=o;)r++;e.splice(r,0,t)}(this.state.overlays,{mode:r,modeSpec:t,opaque:n&&n.opaque,priority:n&&n.priority||0},(function(e){return e.priority})),this.state.modeGen++,dr(this)})),removeOverlay:no((function(e){for(var t=this.state.overlays,n=0;n<t.length;++n){var r=t[n].modeSpec;if(r==e||"string"==typeof e&&r.name==e)return t.splice(n,1),this.state.modeGen++,void dr(this)}})),indentLine:no((function(e,t,n){"string"!=typeof t&&"number"!=typeof t&&(t=null==t?this.options.smartIndent?"smart":"prev":t?"add":"subtract"),Je(this.doc,e)&&Ma(this,e,t,n)})),indentSelection:no((function(e){for(var t=this.doc.sel.ranges,n=-1,r=0;r<t.length;r++){var o=t[r];if(o.empty())o.head.line>n&&(Ma(this,o.head.line,e,!0),n=o.head.line,r==this.doc.sel.primIndex&&Ar(this));else{var i=o.from(),a=o.to(),s=Math.max(n,i.line);n=Math.min(this.lastLine(),a.line-(a.ch?0:1))+1;for(var u=s;u<n;++u)Ma(this,u,e);var l=this.doc.sel.ranges;0==i.ch&&t.length==l.length&&l[r].from().ch>0&&Qo(this.doc,r,new Oo(i,l[r].to()),W)}}})),getTokenAt:function(e,t){return bt(this,e,t)},getLineTokens:function(e,t){return bt(this,tt(e),t,!0)},getTokenTypeAt:function(e){e=ut(this.doc,e);var t,n=pt(this,Ge(this.doc,e.line)),r=0,o=(n.length-1)/2,i=e.ch;if(0==i)t=n[2];else for(;;){var a=r+o>>1;if((a?n[2*a-1]:0)>=i)o=a;else{if(!(n[2*a+1]<i)){t=n[2*a+2];break}r=a+1}}var s=t?t.indexOf("overlay "):-1;return s<0?t:0==s?null:t.slice(0,s-1)},getModeAt:function(t){var n=this.doc.mode;return n.innerMode?e.innerMode(n,this.getTokenAt(t).state).mode:n},getHelper:function(e,t){return this.getHelpers(e,t)[0]},getHelpers:function(e,t){var r=[];if(!n.hasOwnProperty(t))return r;var o=n[t],i=this.getModeAt(e);if("string"==typeof i[t])o[i[t]]&&r.push(o[i[t]]);else if(i[t])for(var a=0;a<i[t].length;a++){var s=o[i[t][a]];s&&r.push(s)}else i.helperType&&o[i.helperType]?r.push(o[i.helperType]):o[i.name]&&r.push(o[i.name]);for(var u=0;u<o._global.length;u++){var l=o._global[u];l.pred(i,this)&&-1==H(r,l.val)&&r.push(l.val)}return r},getStateAfter:function(e,t){var n=this.doc;return ht(this,(e=st(n,null==e?n.first+n.size-1:e))+1,t).state},cursorCoords:function(e,t){var n=this.doc.sel.primary();return $n(this,null==e?n.head:"object"==typeof e?ut(this.doc,e):e?n.from():n.to(),t||"page")},charCoords:function(e,t){return Gn(this,ut(this.doc,e),t||"page")},coordsChar:function(e,t){return Xn(this,(e=Yn(this,e,t||"page")).left,e.top)},lineAtHeight:function(e,t){return e=Yn(this,{top:e,left:0},t||"page").top,Qe(this.doc,e+this.display.viewOffset)},heightAtLine:function(e,t,n){var r,o=!1;if("number"==typeof e){var i=this.doc.first+this.doc.size-1;e<this.doc.first?e=this.doc.first:e>i&&(e=i,o=!0),r=Ge(this.doc,e)}else r=e;return qn(this,r,{top:0,left:0},t||"page",n||o).top+(o?this.doc.height-Vt(r):0)},defaultTextHeight:function(){return or(this.display)},defaultCharWidth:function(){return ir(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(e,t,n,r,o){var i,a,s,u=this.display,l=(e=$n(this,ut(this.doc,e))).bottom,c=e.left;if(t.style.position="absolute",t.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(t),u.sizer.appendChild(t),"over"==r)l=e.top;else if("above"==r||"near"==r){var f=Math.max(u.wrapper.clientHeight,this.doc.height),d=Math.max(u.sizer.clientWidth,u.lineSpace.clientWidth);("above"==r||e.bottom+t.offsetHeight>f)&&e.top>t.offsetHeight?l=e.top-t.offsetHeight:e.bottom+t.offsetHeight<=f&&(l=e.bottom),c+t.offsetWidth>d&&(c=d-t.offsetWidth)}t.style.top=l+"px",t.style.left=t.style.right="","right"==o?(c=u.sizer.clientWidth-t.offsetWidth,t.style.right="0px"):("left"==o?c=0:"middle"==o&&(c=(u.sizer.clientWidth-t.offsetWidth)/2),t.style.left=c+"px"),n&&(i=this,a={left:c,top:l,right:c+t.offsetWidth,bottom:l+t.offsetHeight},null!=(s=Mr(i,a)).scrollTop&&Ir(i,s.scrollTop),null!=s.scrollLeft&&zr(i,s.scrollLeft))},triggerOnKeyDown:no(fa),triggerOnKeyPress:no(pa),triggerOnKeyUp:da,triggerOnMouseDown:no(ma),execCommand:function(e){if(na.hasOwnProperty(e))return na[e].call(null,this)},triggerElectric:no((function(e){Da(this,e)})),findPosH:function(e,t,n,r){var o=1;t<0&&(o=-1,t=-t);for(var i=ut(this.doc,e),a=0;a<t&&!(i=Fa(this.doc,i,o,n,r)).hitSide;++a);return i},moveH:no((function(e,t){var n=this;this.extendSelectionsBy((function(r){return n.display.shift||n.doc.extend||r.empty()?Fa(n.doc,r.head,e,t,n.options.rtlMoveVisually):e<0?r.from():r.to()}),q)})),deleteH:no((function(e,t){var n=this.doc.sel,r=this.doc;n.somethingSelected()?r.replaceSelection("",null,"+delete"):Qi(this,(function(n){var o=Fa(r,n.head,e,t,!1);return e<0?{from:o,to:n.head}:{from:n.head,to:o}}))})),findPosV:function(e,t,n,r){var o=1,i=r;t<0&&(o=-1,t=-t);for(var a=ut(this.doc,e),s=0;s<t;++s){var u=$n(this,a,"div");if(null==i?i=u.left:u.left=i,(a=Ba(this,u,o,n)).hitSide)break}return a},moveV:no((function(e,t){var n=this,r=this.doc,o=[],i=!this.display.shift&&!r.extend&&r.sel.somethingSelected();if(r.extendSelectionsBy((function(a){if(i)return e<0?a.from():a.to();var s=$n(n,a.head,"div");null!=a.goalColumn&&(s.left=a.goalColumn),o.push(s.left);var u=Ba(n,s,e,t);return"page"==t&&a==r.sel.primary()&&Lr(n,Gn(n,u,"div").top-s.top),u}),q),o.length)for(var a=0;a<r.sel.ranges.length;a++)r.sel.ranges[a].goalColumn=o[a]})),findWordAt:function(e){var t=Ge(this.doc,e.line).text,n=e.ch,r=e.ch;if(t){var o=this.getHelper(e,"wordChars");"before"!=e.sticky&&r!=t.length||!n?++r:--n;for(var i=t.charAt(n),a=te(i,o)?function(e){return te(e,o)}:/\s/.test(i)?function(e){return/\s/.test(e)}:function(e){return!/\s/.test(e)&&!te(e)};n>0&&a(t.charAt(n-1));)--n;for(;r<t.length&&a(t.charAt(r));)++r}return new Oo(tt(e.line,n),tt(e.line,r))},toggleOverwrite:function(e){null!=e&&e==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?R(this.display.cursorDiv,"CodeMirror-overwrite"):S(this.display.cursorDiv,"CodeMirror-overwrite"),ve(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==P()},isReadOnly:function(){return!(!this.options.readOnly&&!this.doc.cantEdit)},scrollTo:no((function(e,t){Pr(this,e,t)})),getScrollInfo:function(){var e=this.display.scroller;return{left:e.scrollLeft,top:e.scrollTop,height:e.scrollHeight-Sn(this)-this.display.barHeight,width:e.scrollWidth-Sn(this)-this.display.barWidth,clientHeight:jn(this),clientWidth:Tn(this)}},scrollIntoView:no((function(e,t){null==e?(e={from:this.doc.sel.primary().head,to:null},null==t&&(t=this.options.cursorScrollMargin)):"number"==typeof e?e={from:tt(e,0),to:null}:null==e.from&&(e={from:e,to:null}),e.to||(e.to=e.from),e.margin=t||0,null!=e.from.line?function(e,t){Rr(e),e.curOp.scrollToPos=t}(this,e):Dr(this,e.from,e.to,e.margin)})),setSize:no((function(e,t){var n=this,r=function(e){return"number"==typeof e||/^\d+$/.test(String(e))?e+"px":e};null!=e&&(this.display.wrapper.style.width=r(e)),null!=t&&(this.display.wrapper.style.height=r(t)),this.options.lineWrapping&&Bn(this);var o=this.display.viewFrom;this.doc.iter(o,this.display.viewTo,(function(e){if(e.widgets)for(var t=0;t<e.widgets.length;t++)if(e.widgets[t].noHScroll){pr(n,o,"widget");break}++o})),this.curOp.forceUpdate=!0,ve(this,"refresh",this)})),operation:function(e){return eo(this,e)},startOperation:function(){return Gr(this)},endOperation:function(){return $r(this)},refresh:no((function(){var e=this.display.cachedTextHeight;dr(this),this.curOp.forceUpdate=!0,Hn(this),Pr(this,this.doc.scrollLeft,this.doc.scrollTop),co(this.display),(null==e||Math.abs(e-or(this.display))>.5||this.options.lineWrapping)&&lr(this),ve(this,"refresh",this)})),swapDoc:no((function(e){var t=this.doc;return t.cm=null,this.state.selectingText&&this.state.selectingText(),No(this,e),Hn(this),this.display.input.reset(),Pr(this,e.scrollLeft,e.scrollTop),this.curOp.forceScroll=!0,ln(this,"swapDoc",this,t),t})),phrase:function(e){var t=this.options.phrases;return t&&Object.prototype.hasOwnProperty.call(t,e)?t[e]:e},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},be(e),e.registerHelper=function(t,r,o){n.hasOwnProperty(t)||(n[t]=e[t]={_global:[]}),n[t][r]=o},e.registerGlobalHelper=function(t,r,o,i){e.registerHelper(t,r,i),n[t]._global.push({pred:o,val:i})}}(Ta);var Ga="iter insert remove copy getEditor constructor".split(" ");for(var $a in Ai.prototype)Ai.prototype.hasOwnProperty($a)&&H(Ga,$a)<0&&(Ta.prototype[$a]=function(e){return function(){return e.apply(this.doc,arguments)}}(Ai.prototype[$a]));return be(Ai),Ta.inputStyles={textarea:Ya,contenteditable:Ha},Ta.defineMode=function(e){Ta.defaults.mode||"null"==e||(Ta.defaults.mode=e),ze.apply(this,arguments)},Ta.defineMIME=function(e,t){Ne[e]=t},Ta.defineMode("null",(function(){return{token:function(e){return e.skipToEnd()}}})),Ta.defineMIME("text/plain","null"),Ta.defineExtension=function(e,t){Ta.prototype[e]=t},Ta.defineDocExtension=function(e,t){Ai.prototype[e]=t},Ta.fromTextArea=function(e,t){if((t=t?z(t):{}).value=e.value,!t.tabindex&&e.tabIndex&&(t.tabindex=e.tabIndex),!t.placeholder&&e.placeholder&&(t.placeholder=e.placeholder),null==t.autofocus){var n=P();t.autofocus=n==e||null!=e.getAttribute("autofocus")&&n==document.body}function r(){e.value=s.getValue()}var o;if(e.form&&(de(e.form,"submit",r),!t.leaveSubmitMethodAlone)){var i=e.form;o=i.submit;try{var a=i.submit=function(){r(),i.submit=o,i.submit(),i.submit=a}}catch(e){}}t.finishInit=function(n){n.save=r,n.getTextArea=function(){return e},n.toTextArea=function(){n.toTextArea=isNaN,r(),e.parentNode.removeChild(n.getWrapperElement()),e.style.display="",e.form&&(he(e.form,"submit",r),t.leaveSubmitMethodAlone||"function"!=typeof e.form.submit||(e.form.submit=o))}},e.style.display="none";var s=Ta((function(t){return e.parentNode.insertBefore(t,e.nextSibling)}),t);return s},function(e){e.off=he,e.on=de,e.wheelEventPixels=xo,e.Doc=Ai,e.splitLines=Ae,e.countColumn=F,e.findColumn=Y,e.isWordChar=ee,e.Pass=U,e.signal=ve,e.Line=Gt,e.changeEnd=To,e.scrollbarModel=Vr,e.Pos=tt,e.cmpPos=nt,e.modes=Ie,e.mimeModes=Ne,e.resolveMode=Fe,e.getMode=Be,e.modeExtensions=He,e.extendMode=Ue,e.copyState=We,e.startState=qe,e.innerMode=Ve,e.commands=na,e.keyMap=Vi,e.keyName=Zi,e.isModifierKey=$i,e.lookupKey=Gi,e.normalizeKeyMap=Yi,e.StringStream=Ye,e.SharedTextMarker=Ti,e.TextMarker=Ei,e.LineWidget=ki,e.e_preventDefault=we,e.e_stopPropagation=_e,e.e_stop=ke,e.addClass=R,e.contains=A,e.rmClass=S,e.keyNames=Bi}(Ta),Ta.version="5.65.5",Ta}()},function(e,t,n){var r=n(329),o=n(330),i=n(170),a=n(331);e.exports=function(e,t){return r(e)||o(e,t)||i(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){var n=Array.isArray;e.exports=n},function(e,t,n){var r=n(159),o=n(164),i=n(77),a=n(23),s=n(38),u=n(106),l=n(76),c=n(107),f=Object.prototype.hasOwnProperty;e.exports=function(e){if(null==e)return!0;if(s(e)&&(a(e)||"string"==typeof e||"function"==typeof e.splice||u(e)||c(e)||i(e)))return!e.length;var t=o(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(l(e))return!r(e).length;for(var n in e)if(f.call(e,n))return!1;return!0}},function(e,t,n){var r=n(266),o=n(267),i=n(147),a=n(268);e.exports=function(e,t){return r(e)||o(e,t)||i(e,t)||a()},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */e.exports=function(e,t,n,r,o,i,a,s){if(!e){var u;if(void 0===t)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[n,r,o,i,a,s],c=0;(u=new Error(t.replace(/%s/g,(function(){return l[c++]})))).name="Invariant Violation"}throw u.framesToPop=1,u}}},function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},e.exports.default=e.exports,e.exports.__esModule=!0,n.apply(this,arguments)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},function(e,t,n){"use strict";var r=n(12);t.a=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return new(Function.prototype.bind.apply(r.b,[null].concat(t)))}},function(e,t,n){"use strict";function r(e,t,n,r){this.col=n,this.line=t,this.text=e,this.type=r}e.exports=r,r.fromToken=function(e){return new r(e.value,e.startLine,e.startCol)},r.prototype={constructor:r,valueOf:function(){return this.toString()},toString:function(){return this.text}}},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t,n){var r=n(143),o="object"==typeof self&&self&&self.Object===Object&&self,i=r||o||Function("return this")();e.exports=i},function(e,t){e.exports=function(e){return null!=e&&"object"==typeof e}},function(e,t,n){"use strict";e.exports=y;var r=n(196),o=n(87),i=n(30),a=n(195),s=n(197),u=n(198),l=n(199),c=n(200),f=n(128),d=n(201),p=n(129),h=n(203),v=n(204),g=n(88),m=n(457);function y(e){r.call(this),this.options=e||{},this._tokenStream=null}y.DEFAULT_TYPE=0,y.COMBINATOR_TYPE=1,y.MEDIA_FEATURE_TYPE=2,y.MEDIA_QUERY_TYPE=3,y.PROPERTY_NAME_TYPE=4,y.PROPERTY_VALUE_TYPE=5,y.PROPERTY_VALUE_PART_TYPE=6,y.SELECTOR_TYPE=7,y.SELECTOR_PART_TYPE=8,y.SELECTOR_SUB_PART_TYPE=9,y.prototype=function(){var e,t=new r,n={__proto__:null,constructor:y,DEFAULT_TYPE:0,COMBINATOR_TYPE:1,MEDIA_FEATURE_TYPE:2,MEDIA_QUERY_TYPE:3,PROPERTY_NAME_TYPE:4,PROPERTY_VALUE_TYPE:5,PROPERTY_VALUE_PART_TYPE:6,SELECTOR_TYPE:7,SELECTOR_PART_TYPE:8,SELECTOR_SUB_PART_TYPE:9,_stylesheet:function(){var e,t,n,r=this._tokenStream;for(this.fire("startstylesheet"),this._charset(),this._skipCruft();r.peek()===g.IMPORT_SYM;)this._import(),this._skipCruft();for(;r.peek()===g.NAMESPACE_SYM;)this._namespace(),this._skipCruft();for(n=r.peek();n>g.EOF;){try{switch(n){case g.MEDIA_SYM:this._media(),this._skipCruft();break;case g.PAGE_SYM:this._page(),this._skipCruft();break;case g.FONT_FACE_SYM:this._font_face(),this._skipCruft();break;case g.KEYFRAMES_SYM:this._keyframes(),this._skipCruft();break;case g.VIEWPORT_SYM:this._viewport(),this._skipCruft();break;case g.DOCUMENT_SYM:this._document(),this._skipCruft();break;case g.SUPPORTS_SYM:this._supports(),this._skipCruft();break;case g.UNKNOWN_SYM:if(r.get(),this.options.strict)throw new o("Unknown @ rule.",r.LT(0).startLine,r.LT(0).startCol);for(this.fire({type:"error",error:null,message:"Unknown @ rule: "+r.LT(0).value+".",line:r.LT(0).startLine,col:r.LT(0).startCol}),e=0;r.advance([g.LBRACE,g.RBRACE])===g.LBRACE;)e++;for(;e;)r.advance([g.RBRACE]),e--;break;case g.S:this._readWhitespace();break;default:if(!this._ruleset())switch(n){case g.CHARSET_SYM:throw t=r.LT(1),this._charset(!1),new o("@charset not allowed here.",t.startLine,t.startCol);case g.IMPORT_SYM:throw t=r.LT(1),this._import(!1),new o("@import not allowed here.",t.startLine,t.startCol);case g.NAMESPACE_SYM:throw t=r.LT(1),this._namespace(!1),new o("@namespace not allowed here.",t.startLine,t.startCol);default:r.get(),this._unexpectedToken(r.token())}}}catch(e){if(!(e instanceof o)||this.options.strict)throw e;this.fire({type:"error",error:e,message:e.message,line:e.line,col:e.col})}n=r.peek()}n!==g.EOF&&this._unexpectedToken(r.token()),this.fire("endstylesheet")},_charset:function(e){var t,n,r,o=this._tokenStream;o.match(g.CHARSET_SYM)&&(n=o.token().startLine,r=o.token().startCol,this._readWhitespace(),o.mustMatch(g.STRING),t=o.token().value,this._readWhitespace(),o.mustMatch(g.SEMICOLON),!1!==e&&this.fire({type:"charset",charset:t,line:n,col:r}))},_import:function(e){var t,n,r,o=this._tokenStream;o.mustMatch(g.IMPORT_SYM),n=o.token(),this._readWhitespace(),o.mustMatch([g.STRING,g.URI]),t=o.token().value.replace(/^(?:url\()?["']?([^"']+?)["']?\)?$/,"$1"),this._readWhitespace(),r=this._media_query_list(),o.mustMatch(g.SEMICOLON),this._readWhitespace(),!1!==e&&this.fire({type:"import",uri:t,media:r,line:n.startLine,col:n.startCol})},_namespace:function(e){var t,n,r,o,i=this._tokenStream;i.mustMatch(g.NAMESPACE_SYM),t=i.token().startLine,n=i.token().startCol,this._readWhitespace(),i.match(g.IDENT)&&(r=i.token().value,this._readWhitespace()),i.mustMatch([g.STRING,g.URI]),o=i.token().value.replace(/(?:url\()?["']([^"']+)["']\)?/,"$1"),this._readWhitespace(),i.mustMatch(g.SEMICOLON),this._readWhitespace(),!1!==e&&this.fire({type:"namespace",prefix:r,uri:o,line:t,col:n})},_supports:function(e){var t,n,r=this._tokenStream;if(r.match(g.SUPPORTS_SYM)){for(t=r.token().startLine,n=r.token().startCol,this._readWhitespace(),this._supports_condition(),this._readWhitespace(),r.mustMatch(g.LBRACE),this._readWhitespace(),!1!==e&&this.fire({type:"startsupports",line:t,col:n});this._ruleset(););r.mustMatch(g.RBRACE),this._readWhitespace(),this.fire({type:"endsupports",line:t,col:n})}},_supports_condition:function(){var e,t=this._tokenStream;if(t.match(g.IDENT))"not"===(e=t.token().value.toLowerCase())?(t.mustMatch(g.S),this._supports_condition_in_parens()):t.unget();else for(this._supports_condition_in_parens(),this._readWhitespace();t.peek()===g.IDENT;)"and"!==(e=t.LT(1).value.toLowerCase())&&"or"!==e||(t.mustMatch(g.IDENT),this._readWhitespace(),this._supports_condition_in_parens(),this._readWhitespace())},_supports_condition_in_parens:function(){var e=this._tokenStream;e.match(g.LPAREN)?(this._readWhitespace(),e.match(g.IDENT)?"not"===e.token().value.toLowerCase()?(this._readWhitespace(),this._supports_condition(),this._readWhitespace(),e.mustMatch(g.RPAREN)):(e.unget(),this._supports_declaration_condition(!1)):(this._supports_condition(),this._readWhitespace(),e.mustMatch(g.RPAREN))):this._supports_declaration_condition()},_supports_declaration_condition:function(e){var t=this._tokenStream;!1!==e&&t.mustMatch(g.LPAREN),this._readWhitespace(),this._declaration(),t.mustMatch(g.RPAREN)},_media:function(){var e,t,n,r=this._tokenStream;for(r.mustMatch(g.MEDIA_SYM),e=r.token().startLine,t=r.token().startCol,this._readWhitespace(),n=this._media_query_list(),r.mustMatch(g.LBRACE),this._readWhitespace(),this.fire({type:"startmedia",media:n,line:e,col:t});;)if(r.peek()===g.PAGE_SYM)this._page();else if(r.peek()===g.FONT_FACE_SYM)this._font_face();else if(r.peek()===g.VIEWPORT_SYM)this._viewport();else if(r.peek()===g.DOCUMENT_SYM)this._document();else if(r.peek()===g.SUPPORTS_SYM)this._supports();else if(r.peek()===g.MEDIA_SYM)this._media();else if(!this._ruleset())break;r.mustMatch(g.RBRACE),this._readWhitespace(),this.fire({type:"endmedia",media:n,line:e,col:t})},_media_query_list:function(){var e=this._tokenStream,t=[];for(this._readWhitespace(),e.peek()!==g.IDENT&&e.peek()!==g.LPAREN||t.push(this._media_query());e.match(g.COMMA);)this._readWhitespace(),t.push(this._media_query());return t},_media_query:function(){var e=this._tokenStream,t=null,n=null,r=null,o=[];if(e.match(g.IDENT)&&("only"!==(n=e.token().value.toLowerCase())&&"not"!==n?(e.unget(),n=null):r=e.token()),this._readWhitespace(),e.peek()===g.IDENT?(t=this._media_type(),null===r&&(r=e.token())):e.peek()===g.LPAREN&&(null===r&&(r=e.LT(1)),o.push(this._media_expression())),null===t&&0===o.length)return null;for(this._readWhitespace();e.match(g.IDENT);)"and"!==e.token().value.toLowerCase()&&this._unexpectedToken(e.token()),this._readWhitespace(),o.push(this._media_expression());return new u(n,t,o,r.startLine,r.startCol)},_media_type:function(){return this._media_feature()},_media_expression:function(){var e,t,n=this._tokenStream,r=null;return n.mustMatch(g.LPAREN),e=this._media_feature(),this._readWhitespace(),n.match(g.COLON)&&(this._readWhitespace(),t=n.LT(1),r=this._expression()),n.mustMatch(g.RPAREN),this._readWhitespace(),new s(e,r?new i(r,t.startLine,t.startCol):null)},_media_feature:function(){var e=this._tokenStream;return this._readWhitespace(),e.mustMatch(g.IDENT),i.fromToken(e.token())},_page:function(){var e,t,n=this._tokenStream,r=null,o=null;n.mustMatch(g.PAGE_SYM),e=n.token().startLine,t=n.token().startCol,this._readWhitespace(),n.match(g.IDENT)&&"auto"===(r=n.token().value).toLowerCase()&&this._unexpectedToken(n.token()),n.peek()===g.COLON&&(o=this._pseudo_page()),this._readWhitespace(),this.fire({type:"startpage",id:r,pseudo:o,line:e,col:t}),this._readDeclarations(!0,!0),this.fire({type:"endpage",id:r,pseudo:o,line:e,col:t})},_margin:function(){var e,t,n=this._tokenStream,r=this._margin_sym();return!!r&&(e=n.token().startLine,t=n.token().startCol,this.fire({type:"startpagemargin",margin:r,line:e,col:t}),this._readDeclarations(!0),this.fire({type:"endpagemargin",margin:r,line:e,col:t}),!0)},_margin_sym:function(){var e=this._tokenStream;return e.match([g.TOPLEFTCORNER_SYM,g.TOPLEFT_SYM,g.TOPCENTER_SYM,g.TOPRIGHT_SYM,g.TOPRIGHTCORNER_SYM,g.BOTTOMLEFTCORNER_SYM,g.BOTTOMLEFT_SYM,g.BOTTOMCENTER_SYM,g.BOTTOMRIGHT_SYM,g.BOTTOMRIGHTCORNER_SYM,g.LEFTTOP_SYM,g.LEFTMIDDLE_SYM,g.LEFTBOTTOM_SYM,g.RIGHTTOP_SYM,g.RIGHTMIDDLE_SYM,g.RIGHTBOTTOM_SYM])?i.fromToken(e.token()):null},_pseudo_page:function(){var e=this._tokenStream;return e.mustMatch(g.COLON),e.mustMatch(g.IDENT),e.token().value},_font_face:function(){var e,t,n=this._tokenStream;n.mustMatch(g.FONT_FACE_SYM),e=n.token().startLine,t=n.token().startCol,this._readWhitespace(),this.fire({type:"startfontface",line:e,col:t}),this._readDeclarations(!0),this.fire({type:"endfontface",line:e,col:t})},_viewport:function(){var e,t,n=this._tokenStream;n.mustMatch(g.VIEWPORT_SYM),e=n.token().startLine,t=n.token().startCol,this._readWhitespace(),this.fire({type:"startviewport",line:e,col:t}),this._readDeclarations(!0),this.fire({type:"endviewport",line:e,col:t})},_document:function(){var e,t=this._tokenStream,n=[],r="";for(t.mustMatch(g.DOCUMENT_SYM),e=t.token(),/^@\-([^\-]+)\-/.test(e.value)&&(r=RegExp.$1),this._readWhitespace(),n.push(this._document_function());t.match(g.COMMA);)this._readWhitespace(),n.push(this._document_function());t.mustMatch(g.LBRACE),this._readWhitespace(),this.fire({type:"startdocument",functions:n,prefix:r,line:e.startLine,col:e.startCol});for(var o=!0;o;)switch(t.peek()){case g.PAGE_SYM:this._page();break;case g.FONT_FACE_SYM:this._font_face();break;case g.VIEWPORT_SYM:this._viewport();break;case g.MEDIA_SYM:this._media();break;case g.KEYFRAMES_SYM:this._keyframes();break;case g.DOCUMENT_SYM:this._document();break;default:o=Boolean(this._ruleset())}t.mustMatch(g.RBRACE),e=t.token(),this._readWhitespace(),this.fire({type:"enddocument",functions:n,prefix:r,line:e.startLine,col:e.startCol})},_document_function:function(){var e,t=this._tokenStream;return t.match(g.URI)?(e=t.token().value,this._readWhitespace()):e=this._function(),e},_operator:function(e){var t=this._tokenStream,n=null;return(t.match([g.SLASH,g.COMMA])||e&&t.match([g.PLUS,g.STAR,g.MINUS]))&&(n=t.token(),this._readWhitespace()),n?f.fromToken(n):null},_combinator:function(){var e,t=this._tokenStream,n=null;return t.match([g.PLUS,g.GREATER,g.TILDE])&&(e=t.token(),n=new a(e.value,e.startLine,e.startCol),this._readWhitespace()),n},_unary_operator:function(){var e=this._tokenStream;return e.match([g.MINUS,g.PLUS])?e.token().value:null},_property:function(){var e,t,n,r,o=this._tokenStream,i=null,a=null;return o.peek()===g.STAR&&this.options.starHack&&(o.get(),a=(t=o.token()).value,n=t.startLine,r=t.startCol),o.match(g.IDENT)&&("_"===(e=(t=o.token()).value).charAt(0)&&this.options.underscoreHack&&(a="_",e=e.substring(1)),i=new l(e,a,n||t.startLine,r||t.startCol),this._readWhitespace()),i},_ruleset:function(){var e,t=this._tokenStream;try{e=this._selectors_group()}catch(e){if(!(e instanceof o)||this.options.strict)throw e;if(this.fire({type:"error",error:e,message:e.message,line:e.line,col:e.col}),t.advance([g.RBRACE])!==g.RBRACE)throw e;return!0}return e&&(this.fire({type:"startrule",selectors:e,line:e[0].line,col:e[0].col}),this._readDeclarations(!0),this.fire({type:"endrule",selectors:e,line:e[0].line,col:e[0].col})),e},_selectors_group:function(){var e,t=this._tokenStream,n=[];if(null!==(e=this._selector()))for(n.push(e);t.match(g.COMMA);)this._readWhitespace(),null!==(e=this._selector())?n.push(e):this._unexpectedToken(t.LT(1));return n.length?n:null},_selector:function(){var e=this._tokenStream,t=[],n=null,r=null,o=null;if(null===(n=this._simple_selector_sequence()))return null;for(t.push(n);;)if(null!==(r=this._combinator()))t.push(r),null===(n=this._simple_selector_sequence())?this._unexpectedToken(e.LT(1)):t.push(n);else{if(!this._readWhitespace())break;o=new a(e.token().value,e.token().startLine,e.token().startCol),r=this._combinator(),null===(n=this._simple_selector_sequence())?null!==r&&this._unexpectedToken(e.LT(1)):(null!==r?t.push(r):t.push(o),t.push(n))}return new d(t,t[0].line,t[0].col)},_simple_selector_sequence:function(){var e,t,n=this._tokenStream,r=null,o=[],i="",a=[function(){return n.match(g.HASH)?new h(n.token().value,"id",n.token().startLine,n.token().startCol):null},this._class,this._attrib,this._pseudo,this._negation],s=0,u=a.length,l=null;for(e=n.LT(1).startLine,t=n.LT(1).startCol,(r=this._type_selector())||(r=this._universal()),null!==r&&(i+=r);n.peek()!==g.S;){for(;s<u&&null===l;)l=a[s++].call(this);if(null===l){if(""===i)return null;break}s=0,o.push(l),i+=l.toString(),l=null}return""!==i?new p(r,o,i,e,t):null},_type_selector:function(){var e=this._tokenStream,t=this._namespace_prefix(),n=this._element_name();return n?(t&&(n.text=t+n.text,n.col-=t.length),n):(t&&(e.unget(),t.length>1&&e.unget()),null)},_class:function(){var e,t=this._tokenStream;return t.match(g.DOT)?(t.mustMatch(g.IDENT),e=t.token(),new h("."+e.value,"class",e.startLine,e.startCol-1)):null},_element_name:function(){var e,t=this._tokenStream;return t.match(g.IDENT)?(e=t.token(),new h(e.value,"elementName",e.startLine,e.startCol)):null},_namespace_prefix:function(){var e=this._tokenStream,t="";return e.LA(1)!==g.PIPE&&e.LA(2)!==g.PIPE||(e.match([g.IDENT,g.STAR])&&(t+=e.token().value),e.mustMatch(g.PIPE),t+="|"),t.length?t:null},_universal:function(){var e,t=this._tokenStream,n="";return(e=this._namespace_prefix())&&(n+=e),t.match(g.STAR)&&(n+="*"),n.length?n:null},_attrib:function(){var e,t,n=this._tokenStream,r=null;return n.match(g.LBRACKET)?(r=(t=n.token()).value,r+=this._readWhitespace(),(e=this._namespace_prefix())&&(r+=e),n.mustMatch(g.IDENT),r+=n.token().value,r+=this._readWhitespace(),n.match([g.PREFIXMATCH,g.SUFFIXMATCH,g.SUBSTRINGMATCH,g.EQUALS,g.INCLUDES,g.DASHMATCH])&&(r+=n.token().value,r+=this._readWhitespace(),n.mustMatch([g.IDENT,g.STRING]),r+=n.token().value,r+=this._readWhitespace()),n.mustMatch(g.RBRACKET),new h(r+"]","attribute",t.startLine,t.startCol)):null},_pseudo:function(){var e,t,n=this._tokenStream,r=null,i=":";if(n.match(g.COLON)){if(n.match(g.COLON)&&(i+=":"),n.match(g.IDENT)?(r=n.token().value,e=n.token().startLine,t=n.token().startCol-i.length):n.peek()===g.FUNCTION&&(e=n.LT(1).startLine,t=n.LT(1).startCol-i.length,r=this._functional_pseudo()),!r){var a=n.LT(1).startLine,s=n.LT(0).startCol;throw new o("Expected a `FUNCTION` or `IDENT` after colon at line "+a+", col "+s+".",a,s)}r=new h(i+r,"pseudo",e,t)}return r},_functional_pseudo:function(){var e=this._tokenStream,t=null;return e.match(g.FUNCTION)&&(t=e.token().value,t+=this._readWhitespace(),t+=this._expression(),e.mustMatch(g.RPAREN),t+=")"),t},_expression:function(){for(var e=this._tokenStream,t="";e.match([g.PLUS,g.MINUS,g.DIMENSION,g.NUMBER,g.STRING,g.IDENT,g.LENGTH,g.FREQ,g.ANGLE,g.TIME,g.RESOLUTION,g.SLASH]);)t+=e.token().value,t+=this._readWhitespace();return t.length?t:null},_negation:function(){var e,t,n,r=this._tokenStream,o="",i=null;return r.match(g.NOT)&&(o=r.token().value,e=r.token().startLine,t=r.token().startCol,o+=this._readWhitespace(),o+=n=this._negation_arg(),o+=this._readWhitespace(),r.match(g.RPAREN),o+=r.token().value,(i=new h(o,"not",e,t)).args.push(n)),i},_negation_arg:function(){var e,t,n=this._tokenStream,r=[this._type_selector,this._universal,function(){return n.match(g.HASH)?new h(n.token().value,"id",n.token().startLine,n.token().startCol):null},this._class,this._attrib,this._pseudo],o=null,i=0,a=r.length;for(e=n.LT(1).startLine,t=n.LT(1).startCol;i<a&&null===o;)o=r[i].call(this),i++;return null===o&&this._unexpectedToken(n.LT(1)),"elementName"===o.type?new p(o,[],o.toString(),e,t):new p(null,[o],o.toString(),e,t)},_declaration:function(){var e=this._tokenStream,t=null,n=null,r=null,o=null,i="";if(null!==(t=this._property())){e.mustMatch(g.COLON),this._readWhitespace(),(n=this._expr())&&0!==n.length||this._unexpectedToken(e.LT(1)),r=this._prio(),i=t.toString(),(this.options.starHack&&"*"===t.hack||this.options.underscoreHack&&"_"===t.hack)&&(i=t.text);try{this._validateProperty(i,n)}catch(e){o=e}return this.fire({type:"property",property:t,value:n,important:r,line:t.line,col:t.col,invalid:o}),!0}return!1},_prio:function(){var e=this._tokenStream.match(g.IMPORTANT_SYM);return this._readWhitespace(),e},_expr:function(e){var t=[],n=null,r=null;if(null!==(n=this._term(e)))for(t.push(n);;){if((r=this._operator(e))&&t.push(r),null===(n=this._term(e)))break;t.push(n)}return t.length>0?new c(t,t[0].line,t[0].col):null},_term:function(e){var t,n,r,o,i=this._tokenStream,a=null,s=null,u=null;return null!==(t=this._unary_operator())&&(r=i.token().startLine,o=i.token().startCol),i.peek()===g.IE_FUNCTION&&this.options.ieFilters?(a=this._ie_function(),null===t&&(r=i.token().startLine,o=i.token().startCol)):e&&i.match([g.LPAREN,g.LBRACE,g.LBRACKET])?(s=(n=i.token()).endChar,a=n.value+this._expr(e).text,null===t&&(r=i.token().startLine,o=i.token().startCol),i.mustMatch(g.type(s)),a+=s,this._readWhitespace()):i.match([g.NUMBER,g.PERCENTAGE,g.LENGTH,g.ANGLE,g.TIME,g.FREQ,g.STRING,g.IDENT,g.URI,g.UNICODE_RANGE])?(a=i.token().value,null===t&&(r=i.token().startLine,o=i.token().startCol,u=f.fromToken(i.token())),this._readWhitespace()):null===(n=this._hexcolor())?(null===t&&(r=i.LT(1).startLine,o=i.LT(1).startCol),null===a&&(a=i.LA(3)===g.EQUALS&&this.options.ieFilters?this._ie_function():this._function())):(a=n.value,null===t&&(r=n.startLine,o=n.startCol)),null!==u?u:null!==a?new f(null!==t?t+a:a,r,o):null},_function:function(){var e,t=this._tokenStream,n=null;if(t.match(g.FUNCTION)){if(n=t.token().value,this._readWhitespace(),n+=this._expr(!0),this.options.ieFilters&&t.peek()===g.EQUALS)do{for(this._readWhitespace()&&(n+=t.token().value),t.LA(0)===g.COMMA&&(n+=t.token().value),t.match(g.IDENT),n+=t.token().value,t.match(g.EQUALS),n+=t.token().value,e=t.peek();e!==g.COMMA&&e!==g.S&&e!==g.RPAREN;)t.get(),n+=t.token().value,e=t.peek()}while(t.match([g.COMMA,g.S]));t.match(g.RPAREN),n+=")",this._readWhitespace()}return n},_ie_function:function(){var e,t=this._tokenStream,n=null;if(t.match([g.IE_FUNCTION,g.FUNCTION])){n=t.token().value;do{for(this._readWhitespace()&&(n+=t.token().value),t.LA(0)===g.COMMA&&(n+=t.token().value),t.match(g.IDENT),n+=t.token().value,t.match(g.EQUALS),n+=t.token().value,e=t.peek();e!==g.COMMA&&e!==g.S&&e!==g.RPAREN;)t.get(),n+=t.token().value,e=t.peek()}while(t.match([g.COMMA,g.S]));t.match(g.RPAREN),n+=")",this._readWhitespace()}return n},_hexcolor:function(){var e,t=this._tokenStream,n=null;if(t.match(g.HASH)){if(e=(n=t.token()).value,!/#[a-f0-9]{3,6}/i.test(e))throw new o("Expected a hex color but found '"+e+"' at line "+n.startLine+", col "+n.startCol+".",n.startLine,n.startCol);this._readWhitespace()}return n},_keyframes:function(){var e,t,n,r=this._tokenStream,o="";for(r.mustMatch(g.KEYFRAMES_SYM),e=r.token(),/^@\-([^\-]+)\-/.test(e.value)&&(o=RegExp.$1),this._readWhitespace(),n=this._keyframe_name(),this._readWhitespace(),r.mustMatch(g.LBRACE),this.fire({type:"startkeyframes",name:n,prefix:o,line:e.startLine,col:e.startCol}),this._readWhitespace(),t=r.peek();t===g.IDENT||t===g.PERCENTAGE;)this._keyframe_rule(),this._readWhitespace(),t=r.peek();this.fire({type:"endkeyframes",name:n,prefix:o,line:e.startLine,col:e.startCol}),this._readWhitespace(),r.mustMatch(g.RBRACE),this._readWhitespace()},_keyframe_name:function(){var e=this._tokenStream;return e.mustMatch([g.IDENT,g.STRING]),i.fromToken(e.token())},_keyframe_rule:function(){var e=this._key_list();this.fire({type:"startkeyframerule",keys:e,line:e[0].line,col:e[0].col}),this._readDeclarations(!0),this.fire({type:"endkeyframerule",keys:e,line:e[0].line,col:e[0].col})},_key_list:function(){var e=this._tokenStream,t=[];for(t.push(this._key()),this._readWhitespace();e.match(g.COMMA);)this._readWhitespace(),t.push(this._key()),this._readWhitespace();return t},_key:function(){var e,t=this._tokenStream;if(t.match(g.PERCENTAGE))return i.fromToken(t.token());if(t.match(g.IDENT)){if(e=t.token(),/from|to/i.test(e.value))return i.fromToken(e);t.unget()}this._unexpectedToken(t.LT(1))},_skipCruft:function(){for(;this._tokenStream.match([g.S,g.CDO,g.CDC]););},_readDeclarations:function(e,t){var n,r=this._tokenStream;this._readWhitespace(),e&&r.mustMatch(g.LBRACE),this._readWhitespace();try{for(;;){if(r.match(g.SEMICOLON)||t&&this._margin());else{if(!this._declaration())break;if(!r.match(g.SEMICOLON))break}this._readWhitespace()}r.mustMatch(g.RBRACE),this._readWhitespace()}catch(e){if(!(e instanceof o)||this.options.strict)throw e;if(this.fire({type:"error",error:e,message:e.message,line:e.line,col:e.col}),(n=r.advance([g.SEMICOLON,g.RBRACE]))===g.SEMICOLON)this._readDeclarations(!1,t);else if(n!==g.RBRACE)throw e}},_readWhitespace:function(){for(var e=this._tokenStream,t="";e.match(g.S);)t+=e.token().value;return t},_unexpectedToken:function(e){throw new o("Unexpected token '"+e.value+"' at line "+e.startLine+", col "+e.startCol+".",e.startLine,e.startCol)},_verifyEnd:function(){this._tokenStream.LA(1)!==g.EOF&&this._unexpectedToken(this._tokenStream.LT(1))},_validateProperty:function(e,t){m.validate(e,t)},parse:function(e){this._tokenStream=new v(e,g),this._stylesheet()},parseStyleSheet:function(e){return this.parse(e)},parseMediaQuery:function(e){this._tokenStream=new v(e,g);var t=this._media_query();return this._verifyEnd(),t},parsePropertyValue:function(e){this._tokenStream=new v(e,g),this._readWhitespace();var t=this._expr();return this._readWhitespace(),this._verifyEnd(),t},parseRule:function(e){this._tokenStream=new v(e,g),this._readWhitespace();var t=this._ruleset();return this._readWhitespace(),this._verifyEnd(),t},parseSelector:function(e){this._tokenStream=new v(e,g),this._readWhitespace();var t=this._selector();return this._readWhitespace(),this._verifyEnd(),t},parseStyleAttribute:function(e){e+="}",this._tokenStream=new v(e,g),this._readDeclarations()}};for(e in n)Object.prototype.hasOwnProperty.call(n,e)&&(t[e]=n[e]);return t}()},function(e,t,n){var r=n(283);e.exports=function(e,t){if(null==e)return{};var n,o,i=r(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)n=a[o],t.includes(n)||{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e){return void 0===e}},function(e,t,n){var r=n(104),o=n(284),i=n(285),a=n(38),s=n(76),u=n(41),l=Object.prototype.hasOwnProperty,c=i((function(e,t){if(s(t)||a(t))o(t,u(t),e);else for(var n in t)l.call(t,n)&&r(e,n,t[n])}));e.exports=c},function(e,t,n){var r=n(97),o=n(105);e.exports=function(e){return null!=e&&o(e.length)&&!r(e)}},function(e,t,n){var r=n(58),o=n(234),i=n(235),a=r?r.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":a&&a in Object(e)?o(e):i(e)}},function(e,t){e.exports=function(){}},function(e,t,n){var r=n(158),o=n(159),i=n(38);e.exports=function(e){return i(e)?r(e):o(e)}},function(e,t,n){e.exports=n(227)},function(e,t,n){"use strict";n.r(t),n.d(t,"string",(function(){return i})),n.d(t,"path",(function(){return a})),n.d(t,"signal",(function(){return s})),n.d(t,"signals",(function(){return u})),n.d(t,"sequences",(function(){return l})),n.d(t,"state",(function(){return c})),n.d(t,"module",(function(){return e})),n.d(t,"moduleState",(function(){return f})),n.d(t,"moduleSequences",(function(){return d})),n.d(t,"props",(function(){return p}));var r=n(12),o=n(5);n.d(t,"createTemplateTag",(function(){return r.e})),n.d(t,"extractValueWithPath",(function(){return r.g})),n.d(t,"resolveObject",(function(){return r.i})),n.d(t,"ResolveValue",(function(){return r.c})),n.d(t,"Tag",(function(){return r.d}));var i=Object(r.e)("string",(function(e){return e})),a=Object(r.e)("path",(function(e){return e})),s=Object(r.e)("signal",(function(e,t){return Object(o.a)("tags.signal",'use the "sequences" tag instead'),t.controller.getSequence(e)})),u=Object(r.e)("signals",(function(e,t){return Object(o.a)("tags.signals",'use the "sequences" tag instead'),t.controller.getSequences(e)})),l=Object(r.e)("sequences",(function(e,t){return t.controller.getSequence(e)||t.controller.getSequences(e)})),c=Object(r.e)("state",(function(e,t){return t.controller.getState(e)})),f=(e=Object(r.e)("module",(function(e,t){return Object(o.a)("tags.module",'use the "moduleState" tag instead'),t.controller.getState(Object(o.o)(e,t))})),Object(r.e)("moduleState",(function(e,t){return t.controller.getState(Object(o.o)(e,t))}))),d=Object(r.e)("moduleSequences",(function(e,t){return t.controller.getSequence(Object(o.o)(e,t))||t.controller.getSequences(Object(o.o)(e,t))})),p=Object(r.e)("props",(function(e,t){return Object(r.g)(t.props,e)}))},function(e,t,n){var r=n(260)();e.exports=r;try{regeneratorRuntime=r}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},function(e,t,n){var r=n(241),o=n(244);e.exports=function(e,t){var n=o(e,t);return r(n)?n:void 0}},function(e,t,n){"use strict";function r(e,t){function n(n){var r=n.path;return new Promise((function(n){t.timer&&(t.resolve(r.discard()),clearTimeout(t.timer)),t.timer=setTimeout((function(){t.resolve(r.continue()),t.timer=null,t.resolve=null}),e),t.resolve=n}))}return n.displayName="debounce - "+e+"ms",n}function o(e){return r(e,{timer:null,resolve:null})}n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a})),o.shared=function(){var e={timer:null,resolve:null};return function(t){return r(t,e)}};var i=o;var a=function(e){function t(t){var n=t.path;return new Promise((function(t){setTimeout((function(){return t(n?n.continue():null)}),e)}))}return t.displayName="wait - "+e+"ms",t}},function(e,t){e.exports=ReactDOM},function(e,t,n){var r=n(259);e.exports=function(e){return null==e?"":r(e)}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}},function(e,t,n){var r=n(68);e.exports=function(e){if("string"==typeof e||r(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}},function(e,t,n){var r=n(75),o=n(155),i=n(156);e.exports=function(e,t){return i(o(e,t,r),e+"")}},function(e,t,n){var r=n(39),o=n(367),i=n(33),a=Function.prototype,s=Object.prototype,u=a.toString,l=s.hasOwnProperty,c=u.call(Object);e.exports=function(e){if(!i(e)||"[object Object]"!=r(e))return!1;var t=o(e);if(null===t)return!0;var n=l.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&u.call(n)==c}},function(e,t,n){"use strict";var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var o=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n=e.nextWatchId++;this.id="Watch_"+n,this.rawId=n,this.name=null,this.type=t,this.executedCount=0,this.controller=null,this.modulePath="",this.dependencyMap=null}return r(e,[{key:"create",value:function(e,t,n){return this.name=n,this.controller=e,this.modulePath=t,this}},{key:"registerDependencies",value:function(){this.dependencyMap=this.createDependencyMap(),this.controller.dependencyStore.addEntity(this,this.dependencyMap),this.controller.devtools&&(this.controller.devtools.updateWatchMap(this,this.dependencyMap),this.controller.devtools.sendWatchMap([],[],0,0))}},{key:"destroy",value:function(){this.dependencyMap&&(this.controller.dependencyStore.removeEntity(this,this.dependencyMap),this.controller.devtools&&(this.controller.devtools.updateWatchMap(this,null,this.dependencyMap),this.controller.devtools.sendWatchMap([],[],0,0)))}},{key:"toJSON",value:function(){return{id:this.id,executedCount:this.executedCount,type:this.type,name:this.name}}}]),e}();o.nextWatchId=0,t.a=o},function(e,t,n){var r=n(39),o=n(23),i=n(33);e.exports=function(e){return"string"==typeof e||!o(e)&&i(e)&&"[object String]"==r(e)}},function(e,t,n){var r=n(49),o=n(109),i=n(324),a=n(23);e.exports=function(e,t){return(a(e)?r:i)(e,o(t,3))}},function(e,t,n){var r=n(174),o=n(38),i=n(54),a=n(418),s=n(422),u=Math.max;e.exports=function(e,t,n,l){e=o(e)?e:s(e),n=n&&!l?a(n):0;var c=e.length;return n<0&&(n=u(c+n,0)),i(e)?n<=c&&e.indexOf(t,n)>-1:!!c&&r(e,t,n)>-1}},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t,n){var r=n(32).Symbol;e.exports=r},function(e,t){e.exports=function(e,t){return e===t||e!=e&&t!=t}},function(e,t){var n=/^(?:0|[1-9]\d*)$/;e.exports=function(e,t){var r=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==r||"symbol"!=r&&n.test(e))&&e>-1&&e%1==0&&e<t}},function(e,t){e.exports=function(e,t,n,r){var o=n?n.call(r,e,t):void 0;if(void 0!==o)return!!o;if(e===t)return!0;if("object"!=typeof e||!e||"object"!=typeof t||!t)return!1;var i=Object.keys(e),a=Object.keys(t);if(i.length!==a.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),u=0;u<i.length;u++){var l=i[u];if(!s(l))return!1;var c=e[l],f=t[l];if(!1===(o=n?n.call(r,c,f,l):void 0)||void 0===o&&c!==f)return!1}return!0}},function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return s}));var r=n(5),o=n(29);function i(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var a=["concat","get","increment","merge","pop","push","set","shift","splice","toggle","unset","unshift"];function s(e){var t=null;return Object(o.a)(a.reduce((function(e,n){return e[n]=function(){for(var e=this,o=this.context.controller.model,i=arguments.length,a=Array(i),s=0;s<i;s++)a[s]=arguments[s];var u=Object(r.h)(Object(r.c)(a.shift()));return"get"===n?(Object(r.a)("state.get","use the new GET provider, get(state.foo)"),o.get(u)):(Object(r.a)("state.*","use the new STORE provider, store.set(state.isAwesome, true)"),this.context.controller.flush&&(clearTimeout(t),t=setTimeout((function(){return e.context.controller.flush()}))),o[n].apply(o,[u].concat(a)))},e}),{}),{wrap:!!e&&function(e,t){var n=null;return a.reduce((function(o,a){if("get"===a||"compute"===a)o[a]=function(t){return Object(r.a)("state.get","use the new GET provider, get(state.foo)"),e.controller.model[a](Object(r.h)(Object(r.c)(t)))};else{var s=e.controller.model[a];o[a]=function(){for(var o=arguments.length,u=Array(o),l=0;l<o;l++)u[l]=arguments[l];Object(r.a)("state.*","use the new STORE provider, store.set(state.isAwesome, true)");var c=u.slice(),f=Object(r.h)(c.shift());e.debugger.send({datetime:Date.now(),type:"mutation",color:"#333",method:a,args:[f].concat(i(c))}),e.controller.flush&&(clearTimeout(n),n=setTimeout((function(){return e.controller.flush()})));try{s.apply(e.controller.model,[f].concat(i(c)))}catch(n){var d=e.execution.name;Object(r.y)('The sequence "'+d+'" with action "'+t.name+'" has an error: '+n.message)}}}return o}),{})}})}},function(e,t){function n(e,t,n,r,o,i,a){try{var s=e[i](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,o)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise((function(o,i){var a=e.apply(t,r);function s(e){n(a,o,i,s,u,"next",e)}function u(e){n(a,o,i,s,u,"throw",e)}s(void 0)}))}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(417),o=n(169);e.exports=function(e,t){return null!=e&&o(e,t,r)}},function(e,t,n){var r=n(426),o=n(113),i=n(427),a=n(23);e.exports=function(e,t){return(a(e)?r:o)(e,i(t))}},function(e,t,n){var r=n(263),o=n(264),i=n(147),a=n(265);e.exports=function(e){return r(e)||o(e)||i(e)||a()},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(23),o=n(95),i=n(236),a=n(48);e.exports=function(e,t){return r(e)?e:o(e,t)?[e]:i(a(e))}},function(e,t,n){var r=n(39),o=n(33);e.exports=function(e){return"symbol"==typeof e||o(e)&&"[object Symbol]"==r(e)}},function(e,t,n){var r=n(45)(Object,"create");e.exports=r},function(e,t,n){var r=n(249),o=n(250),i=n(251),a=n(252),s=n(253);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(59);e.exports=function(e,t){for(var n=e.length;n--;)if(r(e[n][0],t))return n;return-1}},function(e,t,n){var r=n(255);e.exports=function(e,t){var n=e.__data__;return r(t)?n["string"==typeof t?"string":"hash"]:n.map}},function(e,t){function n(t){return e.exports=n="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.exports.__esModule=!0,e.exports.default=e.exports,n(t)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]="number"==typeof e[n]?e[n]:e[n].val);return t},e.exports=t.default},function(e,t){e.exports=function(e){return e}},function(e,t){var n=Object.prototype;e.exports=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||n)}},function(e,t,n){var r=n(291),o=n(33),i=Object.prototype,a=i.hasOwnProperty,s=i.propertyIsEnumerable,u=r(function(){return arguments}())?r:function(e){return o(e)&&a.call(e,"callee")&&!s.call(e,"callee")};e.exports=u},function(e,t,n){var r=n(96),o=n(304),i=n(305);function a(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new r;++t<n;)this.add(e[t])}a.prototype.add=a.prototype.push=o,a.prototype.has=i,e.exports=a},function(e,t){e.exports=function(e,t){return e.has(t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dontSetMe=function(e,t,n){if(e[t])return new Error("Invalid prop ".concat(t," passed to ").concat(n," - do not set this, set it on the child."))},t.findInArray=function(e,t){for(let n=0,r=e.length;n<r;n++)if(t.apply(t,[e[n],n,e]))return e[n]},t.int=function(e){return parseInt(e,10)},t.isFunction=function(e){return"function"==typeof e||"[object Function]"===Object.prototype.toString.call(e)},t.isNum=function(e){return"number"==typeof e&&!isNaN(e)}},function(e,t,n){var r=n(78),o=n(115),i=n(116),a=n(79),s=n(340),u=n(111);e.exports=function(e,t,n){var l=-1,c=o,f=e.length,d=!0,p=[],h=p;if(n)d=!1,c=i;else if(f>=200){var v=t?null:s(e);if(v)return u(v);d=!1,c=a,h=new r}else h=t?[]:p;e:for(;++l<f;){var g=e[l],m=t?t(g):g;if(g=n||0!==g?g:0,d&&m==m){for(var y=h.length;y--;)if(h[y]===m)continue e;t&&h.push(m),p.push(g)}else c(h,m,n)||(h!==p&&h.push(m),p.push(g))}return p}},function(e,t,n){"use strict";var r=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(177),i=n(26),a=n(28);t.BEGIN_DRAG="dnd-core/BEGIN_DRAG",t.PUBLISH_DRAG_SOURCE="dnd-core/PUBLISH_DRAG_SOURCE",t.HOVER="dnd-core/HOVER",t.DROP="dnd-core/DROP",t.END_DRAG="dnd-core/END_DRAG",t.default=function(e){return{beginDrag:function(n,r){void 0===n&&(n=[]);var o=void 0===r?{publishSource:!0}:r,s=o.publishSource,u=o.clientOffset,l=o.getSourceClientOffset,c=e.getMonitor(),f=e.getRegistry();i(!c.isDragging(),"Cannot call beginDrag while dragging.");for(var d=0,p=n;d<p.length;d++){var h=p[d];i(f.getSource(h),"Expected sourceIds to be registered.")}for(var v=null,g=n.length-1;g>=0;g--)if(c.canDragSource(n[g])){v=n[g];break}if(null!==v){var m=null;u&&(i("function"==typeof l,"When clientOffset is provided, getSourceClientOffset must be a function."),m=l(v));var y=f.getSource(v).beginDrag(c,v);i(a(y),"Item must be an object."),f.pinSource(v);var b=f.getSourceType(v);return{type:t.BEGIN_DRAG,payload:{itemType:b,item:y,sourceId:v,clientOffset:u||null,sourceClientOffset:m||null,isSourcePublic:!!s}}}},publishDragSource:function(){if(e.getMonitor().isDragging())return{type:t.PUBLISH_DRAG_SOURCE}},hover:function(n,r){var a=(void 0===r?{}:r).clientOffset;i(Array.isArray(n),"Expected targetIds to be an array.");var s=n.slice(0),u=e.getMonitor(),l=e.getRegistry();i(u.isDragging(),"Cannot call hover while not dragging."),i(!u.didDrop(),"Cannot call hover after drop.");for(var c=0;c<s.length;c++){var f=s[c];i(s.lastIndexOf(f)===c,"Expected targetIds to be unique in the passed array.");var d=l.getTarget(f);i(d,"Expected targetIds to be registered.")}var p=u.getItemType();for(c=s.length-1;c>=0;c--){f=s[c];var h=l.getTargetType(f);o.default(h,p)||s.splice(c,1)}for(var v=0,g=s;v<g.length;v++){f=g[v];(d=l.getTarget(f)).hover(u,f)}return{type:t.HOVER,payload:{targetIds:s,clientOffset:a||null}}},drop:function(n){void 0===n&&(n={});var o=e.getMonitor(),s=e.getRegistry();i(o.isDragging(),"Cannot call drop while not dragging."),i(!o.didDrop(),"Cannot call drop twice during one drag operation.");var u=o.getTargetIds().filter(o.canDropOnTarget,o);u.reverse(),u.forEach((function(u,l){var c=s.getTarget(u).drop(o,u);i(void 0===c||a(c),"Drop result must either be an object or undefined."),void 0===c&&(c=0===l?{}:o.getDropResult());var f={type:t.DROP,payload:{dropResult:r({},n,c)}};e.dispatch(f)}))},endDrag:function(){var n=e.getMonitor(),r=e.getRegistry();i(n.isDragging(),"Cannot call endDrag while not dragging.");var o=n.getSourceId();return r.getSource(o,!0).endDrag(n,o),r.unpinSource(),{type:t.END_DRAG}}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ADD_SOURCE="dnd-core/ADD_SOURCE",t.ADD_TARGET="dnd-core/ADD_TARGET",t.REMOVE_SOURCE="dnd-core/REMOVE_SOURCE",t.REMOVE_TARGET="dnd-core/REMOVE_TARGET",t.addSource=function(e){return{type:t.ADD_SOURCE,payload:{sourceId:e}}},t.addTarget=function(e){return{type:t.ADD_TARGET,payload:{targetId:e}}},t.removeSource=function(e){return{type:t.REMOVE_SOURCE,payload:{sourceId:e}}},t.removeTarget=function(e){return{type:t.REMOVE_TARGET,payload:{targetId:e}}}},function(e,t,n){var r=n(38),o=n(33);e.exports=function(e){return o(e)&&r(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r]}},function(e,t,n){e.exports=n(397)()},function(e,t,n){"use strict";function r(e,t,n){Error.call(this),this.name=this.constructor.name,this.col=n,this.line=t,this.message=e}e.exports=r,r.prototype=Object.create(Error.prototype),r.prototype.constructor=r},function(e,t,n){"use strict";var r=e.exports=[{name:"CDO"},{name:"CDC"},{name:"S",whitespace:!0},{name:"COMMENT",comment:!0,hide:!0,channel:"comment"},{name:"INCLUDES",text:"~="},{name:"DASHMATCH",text:"|="},{name:"PREFIXMATCH",text:"^="},{name:"SUFFIXMATCH",text:"$="},{name:"SUBSTRINGMATCH",text:"*="},{name:"STRING"},{name:"IDENT"},{name:"HASH"},{name:"IMPORT_SYM",text:"@import"},{name:"PAGE_SYM",text:"@page"},{name:"MEDIA_SYM",text:"@media"},{name:"FONT_FACE_SYM",text:"@font-face"},{name:"CHARSET_SYM",text:"@charset"},{name:"NAMESPACE_SYM",text:"@namespace"},{name:"SUPPORTS_SYM",text:"@supports"},{name:"VIEWPORT_SYM",text:["@viewport","@-ms-viewport","@-o-viewport"]},{name:"DOCUMENT_SYM",text:["@document","@-moz-document"]},{name:"UNKNOWN_SYM"},{name:"KEYFRAMES_SYM",text:["@keyframes","@-webkit-keyframes","@-moz-keyframes","@-o-keyframes"]},{name:"IMPORTANT_SYM"},{name:"LENGTH"},{name:"ANGLE"},{name:"TIME"},{name:"FREQ"},{name:"DIMENSION"},{name:"PERCENTAGE"},{name:"NUMBER"},{name:"URI"},{name:"FUNCTION"},{name:"UNICODE_RANGE"},{name:"INVALID"},{name:"PLUS",text:"+"},{name:"GREATER",text:">"},{name:"COMMA",text:","},{name:"TILDE",text:"~"},{name:"NOT"},{name:"TOPLEFTCORNER_SYM",text:"@top-left-corner"},{name:"TOPLEFT_SYM",text:"@top-left"},{name:"TOPCENTER_SYM",text:"@top-center"},{name:"TOPRIGHT_SYM",text:"@top-right"},{name:"TOPRIGHTCORNER_SYM",text:"@top-right-corner"},{name:"BOTTOMLEFTCORNER_SYM",text:"@bottom-left-corner"},{name:"BOTTOMLEFT_SYM",text:"@bottom-left"},{name:"BOTTOMCENTER_SYM",text:"@bottom-center"},{name:"BOTTOMRIGHT_SYM",text:"@bottom-right"},{name:"BOTTOMRIGHTCORNER_SYM",text:"@bottom-right-corner"},{name:"LEFTTOP_SYM",text:"@left-top"},{name:"LEFTMIDDLE_SYM",text:"@left-middle"},{name:"LEFTBOTTOM_SYM",text:"@left-bottom"},{name:"RIGHTTOP_SYM",text:"@right-top"},{name:"RIGHTMIDDLE_SYM",text:"@right-middle"},{name:"RIGHTBOTTOM_SYM",text:"@right-bottom"},{name:"RESOLUTION",state:"media"},{name:"IE_FUNCTION"},{name:"CHAR"},{name:"PIPE",text:"|"},{name:"SLASH",text:"/"},{name:"MINUS",text:"-"},{name:"STAR",text:"*"},{name:"LBRACE",endChar:"}",text:"{"},{name:"RBRACE",text:"}"},{name:"LBRACKET",endChar:"]",text:"["},{name:"RBRACKET",text:"]"},{name:"EQUALS",text:"="},{name:"COLON",text:":"},{name:"SEMICOLON",text:";"},{name:"LPAREN",endChar:")",text:"("},{name:"RPAREN",text:")"},{name:"DOT",text:"."}];!function(){var e=[],t=Object.create(null);r.UNKNOWN=-1,r.unshift({name:"EOF"});for(var n=0,o=r.length;n<o;n++)if(e.push(r[n].name),r[r[n].name]=n,r[n].text)if(r[n].text instanceof Array)for(var i=0;i<r[n].text.length;i++)t[r[n].text[i]]=n;else t[r[n].text]=n;r.name=function(t){return e[t]},r.type=function(e){return t[e]||-1}}()},function(e,t,n){var r=n(110);e.exports=function(e,t){return r(e,t)}},function(e,t,n){"use strict";var r=n(5),o=n(62),i=n(29);function a(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var s=["concat","increment","merge","pop","push","set","shift","splice","toggle","unset","unshift"];function u(e){var t=null;return Object(i.a)(s.reduce((function(e,n){return e[n]=function(){for(var e=this,o=arguments.length,i=Array(o),a=0;a<o;a++)i[a]=arguments[a];var s=this.context.controller.model,u=i.shift(),l=Object(r.h)(this.context.resolve.isTag(u)?this.context.resolve.path(u):u);if(i=i.map((function(t){return e.context.resolve.value(t)})),"moduleState"===u.type){var c=this.context.execution.name.split("."),f=c.splice(0,c.length-1);l=f.concat(l)}return this.context.controller.flush&&(clearTimeout(t),t=setTimeout((function(){return e.context.controller.flush()}))),"set"===n&&void 0===i[0]?s.unset.apply(s,[l].concat(i)):s[n].apply(s,[l].concat(i))},e}),{}),{wrap:!!e&&function(e,t){var n=null;return s.reduce((function(o,i){var s=e.controller.model[i];return o[i]=function(){for(var o=arguments.length,u=Array(o),l=0;l<o;l++)u[l]=arguments[l];var c=u.slice(),f=c.shift(),d=Object(r.h)(e.resolve.isTag(f)?e.resolve.path(f):f);if(c=c.map((function(t){return e.resolve.value(t)})),"moduleState"===f.type){var p=e.execution.name.split("."),h=p.splice(0,p.length-1);d=h.concat(d)}e.debugger.send({datetime:Date.now(),type:"mutation",color:"#333",method:i,args:[d].concat(a(c))}),e.controller.flush&&(clearTimeout(n),n=setTimeout((function(){return e.controller.flush()})));try{var v;if("set"===i&&void 0===c[0])(v=e.controller.model).unset.apply(v,[d].concat(a(c)));else s.apply(e.controller.model,[d].concat(a(c)))}catch(n){var g=e.execution.name;Object(r.y)('The sequence "'+g+'" with action "'+t.name+'" has an error: '+n.message)}},o}),{})}})}var l=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var c=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.initialState=Object(r.j)(t.module,"state"),this.StateProvider=o.a,this.StoreProvider=u,this.changedPaths=[],t.on("moduleAdded",this.onModuleAdded.bind(this)),t.on("moduleRemoved",this.onModuleRemoved.bind(this))}return l(e,[{key:"onModuleAdded",value:function(e,t){this.set(e,t.state)}},{key:"onModuleRemoved",value:function(e){this.unset(e)}},{key:"flush",value:function(){var e=this.changedPaths.slice();return this.changedPaths=[],e}}]),e}();t.a=c},function(e,t,n){(function(t){e.exports=function e(t,n,r){function o(a,s){if(!n[a]){if(!t[a]){if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var l=n[a]={exports:{}};t[a][0].call(l.exports,(function(e){var n=t[a][1][e];return o(n||e)}),l,l.exports,e,t,n,r)}return n[a].exports}for(var i=!1,a=0;a<r.length;a++)o(r[a]);return o}({1:[function(e,n,r){(function(e){"use strict";var t,r,o=e.MutationObserver||e.WebKitMutationObserver;if(o){var i=0,a=new o(c),s=e.document.createTextNode("");a.observe(s,{characterData:!0}),t=function(){s.data=i=++i%2}}else if(e.setImmediate||void 0===e.MessageChannel)t="document"in e&&"onreadystatechange"in e.document.createElement("script")?function(){var t=e.document.createElement("script");t.onreadystatechange=function(){c(),t.onreadystatechange=null,t.parentNode.removeChild(t),t=null},e.document.documentElement.appendChild(t)}:function(){setTimeout(c,0)};else{var u=new e.MessageChannel;u.port1.onmessage=c,t=function(){u.port2.postMessage(0)}}var l=[];function c(){var e,t;r=!0;for(var n=l.length;n;){for(t=l,l=[],e=-1;++e<n;)t[e]();n=l.length}r=!1}n.exports=function(e){1!==l.push(e)||r||t()}}).call(this,void 0!==t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],2:[function(e,t,n){"use strict";var r=e(1);function o(){}var i={},a=["REJECTED"],s=["FULFILLED"],u=["PENDING"];function l(e){if("function"!=typeof e)throw new TypeError("resolver must be a function");this.state=u,this.queue=[],this.outcome=void 0,e!==o&&p(this,e)}function c(e,t,n){this.promise=e,"function"==typeof t&&(this.onFulfilled=t,this.callFulfilled=this.otherCallFulfilled),"function"==typeof n&&(this.onRejected=n,this.callRejected=this.otherCallRejected)}function f(e,t,n){r((function(){var r;try{r=t(n)}catch(t){return i.reject(e,t)}r===e?i.reject(e,new TypeError("Cannot resolve promise with itself")):i.resolve(e,r)}))}function d(e){var t=e&&e.then;if(e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof t)return function(){t.apply(e,arguments)}}function p(e,t){var n=!1;function r(t){n||(n=!0,i.reject(e,t))}function o(t){n||(n=!0,i.resolve(e,t))}var a=h((function(){t(o,r)}));"error"===a.status&&r(a.value)}function h(e,t){var n={};try{n.value=e(t),n.status="success"}catch(e){n.status="error",n.value=e}return n}t.exports=l,l.prototype.catch=function(e){return this.then(null,e)},l.prototype.then=function(e,t){if("function"!=typeof e&&this.state===s||"function"!=typeof t&&this.state===a)return this;var n=new this.constructor(o);return this.state!==u?f(n,this.state===s?e:t,this.outcome):this.queue.push(new c(n,e,t)),n},c.prototype.callFulfilled=function(e){i.resolve(this.promise,e)},c.prototype.otherCallFulfilled=function(e){f(this.promise,this.onFulfilled,e)},c.prototype.callRejected=function(e){i.reject(this.promise,e)},c.prototype.otherCallRejected=function(e){f(this.promise,this.onRejected,e)},i.resolve=function(e,t){var n=h(d,t);if("error"===n.status)return i.reject(e,n.value);var r=n.value;if(r)p(e,r);else{e.state=s,e.outcome=t;for(var o=-1,a=e.queue.length;++o<a;)e.queue[o].callFulfilled(t)}return e},i.reject=function(e,t){e.state=a,e.outcome=t;for(var n=-1,r=e.queue.length;++n<r;)e.queue[n].callRejected(t);return e},l.resolve=function(e){return e instanceof this?e:i.resolve(new this(o),e)},l.reject=function(e){var t=new this(o);return i.reject(t,e)},l.all=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a=new Array(n),s=0,u=-1,l=new this(o);++u<n;)c(e[u],u);return l;function c(e,o){t.resolve(e).then((function(e){a[o]=e,++s!==n||r||(r=!0,i.resolve(l,a))}),(function(e){r||(r=!0,i.reject(l,e))}))}},l.race=function(e){var t=this;if("[object Array]"!==Object.prototype.toString.call(e))return this.reject(new TypeError("must be an array"));var n=e.length,r=!1;if(!n)return this.resolve([]);for(var a,s=-1,u=new this(o);++s<n;)a=e[s],t.resolve(a).then((function(e){r||(r=!0,i.resolve(u,e))}),(function(e){r||(r=!0,i.reject(u,e))}));return u}},{1:1}],3:[function(e,n,r){(function(t){"use strict";"function"!=typeof t.Promise&&(t.Promise=e(2))}).call(this,void 0!==t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{2:2}],4:[function(e,t,n){"use strict";var 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},o=function(){try{if("undefined"!=typeof indexedDB)return indexedDB;if("undefined"!=typeof webkitIndexedDB)return webkitIndexedDB;if("undefined"!=typeof mozIndexedDB)return mozIndexedDB;if("undefined"!=typeof OIndexedDB)return OIndexedDB;if("undefined"!=typeof msIndexedDB)return msIndexedDB}catch(e){return}}();function i(e,t){e=e||[],t=t||{};try{return new Blob(e,t)}catch(o){if("TypeError"!==o.name)throw o;for(var n=new("undefined"!=typeof BlobBuilder?BlobBuilder:"undefined"!=typeof MSBlobBuilder?MSBlobBuilder:"undefined"!=typeof MozBlobBuilder?MozBlobBuilder:WebKitBlobBuilder),r=0;r<e.length;r+=1)n.append(e[r]);return n.getBlob(t.type)}}"undefined"==typeof Promise&&e(3);var a=Promise;function s(e,t){t&&e.then((function(e){t(null,e)}),(function(e){t(e)}))}function u(e,t,n){"function"==typeof t&&e.then(t),"function"==typeof n&&e.catch(n)}function l(e){return"string"!=typeof e&&(console.warn(e+" used as a key, but it is not a string."),e=String(e)),e}function c(){if(arguments.length&&"function"==typeof arguments[arguments.length-1])return arguments[arguments.length-1]}var f=void 0,d={},p=Object.prototype.toString;function h(e){return"boolean"==typeof f?a.resolve(f):function(e){return new a((function(t){var n=e.transaction("local-forage-detect-blob-support","readwrite"),r=i([""]);n.objectStore("local-forage-detect-blob-support").put(r,"key"),n.onabort=function(e){e.preventDefault(),e.stopPropagation(),t(!1)},n.oncomplete=function(){var e=navigator.userAgent.match(/Chrome\/(\d+)/),n=navigator.userAgent.match(/Edge\//);t(n||!e||parseInt(e[1],10)>=43)}})).catch((function(){return!1}))}(e).then((function(e){return f=e}))}function v(e){var t=d[e.name],n={};n.promise=new a((function(e,t){n.resolve=e,n.reject=t})),t.deferredOperations.push(n),t.dbReady?t.dbReady=t.dbReady.then((function(){return n.promise})):t.dbReady=n.promise}function g(e){var t=d[e.name].deferredOperations.pop();if(t)return t.resolve(),t.promise}function m(e,t){var n=d[e.name].deferredOperations.pop();if(n)return n.reject(t),n.promise}function y(e,t){return new a((function(n,r){if(d[e.name]=d[e.name]||{forages:[],db:null,dbReady:null,deferredOperations:[]},e.db){if(!t)return n(e.db);v(e),e.db.close()}var i=[e.name];t&&i.push(e.version);var a=o.open.apply(o,i);t&&(a.onupgradeneeded=function(t){var n=a.result;try{n.createObjectStore(e.storeName),t.oldVersion<=1&&n.createObjectStore("local-forage-detect-blob-support")}catch(n){if("ConstraintError"!==n.name)throw n;console.warn('The database "'+e.name+'" has been upgraded from version '+t.oldVersion+" to version "+t.newVersion+', but the storage "'+e.storeName+'" already exists.')}}),a.onerror=function(e){e.preventDefault(),r(a.error)},a.onsuccess=function(){var t=a.result;t.onversionchange=function(e){e.target.close()},n(t),g(e)}}))}function b(e){return y(e,!1)}function w(e){return y(e,!0)}function _(e,t){if(!e.db)return!0;var n=!e.db.objectStoreNames.contains(e.storeName),r=e.version<e.db.version,o=e.version>e.db.version;if(r&&(e.version!==t&&console.warn('The database "'+e.name+"\" can't be downgraded from version "+e.db.version+" to version "+e.version+"."),e.version=e.db.version),o||n){if(n){var i=e.db.version+1;i>e.version&&(e.version=i)}return!0}return!1}function x(e){return i([function(e){for(var t=e.length,n=new ArrayBuffer(t),r=new Uint8Array(n),o=0;o<t;o++)r[o]=e.charCodeAt(o);return n}(atob(e.data))],{type:e.type})}function k(e){return e&&e.__local_forage_encoded_blob}function C(e){var t=this,n=t._initReady().then((function(){var e=d[t._dbInfo.name];if(e&&e.dbReady)return e.dbReady}));return u(n,e,e),n}function O(e,t,n,r){void 0===r&&(r=1);try{var o=e.db.transaction(e.storeName,t);n(null,o)}catch(o){if(r>0&&(!e.db||"InvalidStateError"===o.name||"NotFoundError"===o.name))return a.resolve().then((function(){if(!e.db||"NotFoundError"===o.name&&!e.db.objectStoreNames.contains(e.storeName)&&e.version<=e.db.version)return e.db&&(e.version=e.db.version+1),w(e)})).then((function(){return function(e){v(e);for(var t=d[e.name],n=t.forages,r=0;r<n.length;r++){var o=n[r];o._dbInfo.db&&(o._dbInfo.db.close(),o._dbInfo.db=null)}return e.db=null,b(e).then((function(t){return e.db=t,_(e)?w(e):t})).then((function(r){e.db=t.db=r;for(var o=0;o<n.length;o++)n[o]._dbInfo.db=r})).catch((function(t){throw m(e,t),t}))}(e).then((function(){O(e,t,n,r-1)}))})).catch(n);n(o)}}var E={_driver:"asyncStorage",_initStorage:function(e){var t=this,n={db:null};if(e)for(var r in e)n[r]=e[r];var o=d[n.name];o||(o={forages:[],db:null,dbReady:null,deferredOperations:[]},d[n.name]=o),o.forages.push(t),t._initReady||(t._initReady=t.ready,t.ready=C);var i=[];function s(){return a.resolve()}for(var u=0;u<o.forages.length;u++){var l=o.forages[u];l!==t&&i.push(l._initReady().catch(s))}var c=o.forages.slice(0);return a.all(i).then((function(){return n.db=o.db,b(n)})).then((function(e){return n.db=e,_(n,t._defaultConfig.version)?w(n):e})).then((function(e){n.db=o.db=e,t._dbInfo=n;for(var r=0;r<c.length;r++){var i=c[r];i!==t&&(i._dbInfo.db=n.db,i._dbInfo.version=n.version)}}))},_support:function(){try{if(!o||!o.open)return!1;var e="undefined"!=typeof openDatabase&&/(Safari|iPhone|iPad|iPod)/.test(navigator.userAgent)&&!/Chrome/.test(navigator.userAgent)&&!/BlackBerry/.test(navigator.platform),t="function"==typeof fetch&&-1!==fetch.toString().indexOf("[native code");return(!e||t)&&"undefined"!=typeof indexedDB&&"undefined"!=typeof IDBKeyRange}catch(e){return!1}}(),iterate:function(e,t){var n=this,r=new a((function(t,r){n.ready().then((function(){O(n._dbInfo,"readonly",(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName).openCursor(),s=1;a.onsuccess=function(){var n=a.result;if(n){var r=n.value;k(r)&&(r=x(r));var o=e(r,n.key,s++);void 0!==o?t(o):n.continue()}else t()},a.onerror=function(){r(a.error)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},getItem:function(e,t){var n=this;e=l(e);var r=new a((function(t,r){n.ready().then((function(){O(n._dbInfo,"readonly",(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName).get(e);a.onsuccess=function(){var e=a.result;void 0===e&&(e=null),k(e)&&(e=x(e)),t(e)},a.onerror=function(){r(a.error)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},setItem:function(e,t,n){var r=this;e=l(e);var o=new a((function(n,o){var i;r.ready().then((function(){return i=r._dbInfo,"[object Blob]"===p.call(t)?h(i.db).then((function(e){return e?t:(n=t,new a((function(e,t){var r=new FileReader;r.onerror=t,r.onloadend=function(t){var r=btoa(t.target.result||"");e({__local_forage_encoded_blob:!0,data:r,type:n.type})},r.readAsBinaryString(n)})));var n})):t})).then((function(t){O(r._dbInfo,"readwrite",(function(i,a){if(i)return o(i);try{var s=a.objectStore(r._dbInfo.storeName);null===t&&(t=void 0);var u=s.put(t,e);a.oncomplete=function(){void 0===t&&(t=null),n(t)},a.onabort=a.onerror=function(){var e=u.error?u.error:u.transaction.error;o(e)}}catch(e){o(e)}}))})).catch(o)}));return s(o,n),o},removeItem:function(e,t){var n=this;e=l(e);var r=new a((function(t,r){n.ready().then((function(){O(n._dbInfo,"readwrite",(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName).delete(e);i.oncomplete=function(){t()},i.onerror=function(){r(a.error)},i.onabort=function(){var e=a.error?a.error:a.transaction.error;r(e)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},clear:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){O(t._dbInfo,"readwrite",(function(r,o){if(r)return n(r);try{var i=o.objectStore(t._dbInfo.storeName).clear();o.oncomplete=function(){e()},o.onabort=o.onerror=function(){var e=i.error?i.error:i.transaction.error;n(e)}}catch(e){n(e)}}))})).catch(n)}));return s(n,e),n},length:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){O(t._dbInfo,"readonly",(function(r,o){if(r)return n(r);try{var i=o.objectStore(t._dbInfo.storeName).count();i.onsuccess=function(){e(i.result)},i.onerror=function(){n(i.error)}}catch(e){n(e)}}))})).catch(n)}));return s(n,e),n},key:function(e,t){var n=this,r=new a((function(t,r){e<0?t(null):n.ready().then((function(){O(n._dbInfo,"readonly",(function(o,i){if(o)return r(o);try{var a=i.objectStore(n._dbInfo.storeName),s=!1,u=a.openKeyCursor();u.onsuccess=function(){var n=u.result;n?0===e||s?t(n.key):(s=!0,n.advance(e)):t(null)},u.onerror=function(){r(u.error)}}catch(e){r(e)}}))})).catch(r)}));return s(r,t),r},keys:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){O(t._dbInfo,"readonly",(function(r,o){if(r)return n(r);try{var i=o.objectStore(t._dbInfo.storeName).openKeyCursor(),a=[];i.onsuccess=function(){var t=i.result;t?(a.push(t.key),t.continue()):e(a)},i.onerror=function(){n(i.error)}}catch(e){n(e)}}))})).catch(n)}));return s(n,e),n},dropInstance:function(e,t){t=c.apply(this,arguments);var n=this.config();(e="function"!=typeof e&&e||{}).name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var r,i=this;if(e.name){var u=e.name===n.name&&i._dbInfo.db,l=u?a.resolve(i._dbInfo.db):b(e).then((function(t){var n=d[e.name],r=n.forages;n.db=t;for(var o=0;o<r.length;o++)r[o]._dbInfo.db=t;return t}));r=e.storeName?l.then((function(t){if(t.objectStoreNames.contains(e.storeName)){var n=t.version+1;v(e);var r=d[e.name],i=r.forages;t.close();for(var s=0;s<i.length;s++){var u=i[s];u._dbInfo.db=null,u._dbInfo.version=n}return new a((function(t,r){var i=o.open(e.name,n);i.onerror=function(e){i.result.close(),r(e)},i.onupgradeneeded=function(){i.result.deleteObjectStore(e.storeName)},i.onsuccess=function(){var e=i.result;e.close(),t(e)}})).then((function(e){r.db=e;for(var t=0;t<i.length;t++){var n=i[t];n._dbInfo.db=e,g(n._dbInfo)}})).catch((function(t){throw(m(e,t)||a.resolve()).catch((function(){})),t}))}})):l.then((function(t){v(e);var n=d[e.name],r=n.forages;t.close();for(var i=0;i<r.length;i++)r[i]._dbInfo.db=null;return new a((function(t,n){var r=o.deleteDatabase(e.name);r.onerror=function(){var e=r.result;e&&e.close(),n(r.error)},r.onblocked=function(){console.warn('dropInstance blocked for database "'+e.name+'" until all open connections are closed')},r.onsuccess=function(){var e=r.result;e&&e.close(),t(e)}})).then((function(e){n.db=e;for(var t=0;t<r.length;t++)g(r[t]._dbInfo)})).catch((function(t){throw(m(e,t)||a.resolve()).catch((function(){})),t}))}))}else r=a.reject("Invalid arguments");return s(r,t),r}},S="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",T=/^~~local_forage_type~([^~]+)~/,j="__lfsc__:".length,M=j+"arbf".length,L=Object.prototype.toString;function A(e){var t,n,r,o,i,a=.75*e.length,s=e.length,u=0;"="===e[e.length-1]&&(a--,"="===e[e.length-2]&&a--);var l=new ArrayBuffer(a),c=new Uint8Array(l);for(t=0;t<s;t+=4)n=S.indexOf(e[t]),r=S.indexOf(e[t+1]),o=S.indexOf(e[t+2]),i=S.indexOf(e[t+3]),c[u++]=n<<2|r>>4,c[u++]=(15&r)<<4|o>>2,c[u++]=(3&o)<<6|63&i;return l}function P(e){var t,n=new Uint8Array(e),r="";for(t=0;t<n.length;t+=3)r+=S[n[t]>>2],r+=S[(3&n[t])<<4|n[t+1]>>4],r+=S[(15&n[t+1])<<2|n[t+2]>>6],r+=S[63&n[t+2]];return n.length%3==2?r=r.substring(0,r.length-1)+"=":n.length%3==1&&(r=r.substring(0,r.length-2)+"=="),r}var R={serialize:function(e,t){var n="";if(e&&(n=L.call(e)),e&&("[object ArrayBuffer]"===n||e.buffer&&"[object ArrayBuffer]"===L.call(e.buffer))){var r,o="__lfsc__:";e instanceof ArrayBuffer?(r=e,o+="arbf"):(r=e.buffer,"[object Int8Array]"===n?o+="si08":"[object Uint8Array]"===n?o+="ui08":"[object Uint8ClampedArray]"===n?o+="uic8":"[object Int16Array]"===n?o+="si16":"[object Uint16Array]"===n?o+="ur16":"[object Int32Array]"===n?o+="si32":"[object Uint32Array]"===n?o+="ui32":"[object Float32Array]"===n?o+="fl32":"[object Float64Array]"===n?o+="fl64":t(new Error("Failed to get type for BinaryArray"))),t(o+P(r))}else if("[object Blob]"===n){var i=new FileReader;i.onload=function(){var n="~~local_forage_type~"+e.type+"~"+P(this.result);t("__lfsc__:blob"+n)},i.readAsArrayBuffer(e)}else try{t(JSON.stringify(e))}catch(n){console.error("Couldn't convert value into a JSON string: ",e),t(null,n)}},deserialize:function(e){if("__lfsc__:"!==e.substring(0,j))return JSON.parse(e);var t,n=e.substring(M),r=e.substring(j,M);if("blob"===r&&T.test(n)){var o=n.match(T);t=o[1],n=n.substring(o[0].length)}var a=A(n);switch(r){case"arbf":return a;case"blob":return i([a],{type:t});case"si08":return new Int8Array(a);case"ui08":return new Uint8Array(a);case"uic8":return new Uint8ClampedArray(a);case"si16":return new Int16Array(a);case"ur16":return new Uint16Array(a);case"si32":return new Int32Array(a);case"ui32":return new Uint32Array(a);case"fl32":return new Float32Array(a);case"fl64":return new Float64Array(a);default:throw new Error("Unkown type: "+r)}},stringToBuffer:A,bufferToString:P}; /* * Includes code from: * * base64-arraybuffer * https://github.com/niklasvh/base64-arraybuffer * * Copyright (c) 2012 Niklas von Hertzen * Licensed under the MIT license. */function D(e,t,n,r){e.executeSql("CREATE TABLE IF NOT EXISTS "+t.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],n,r)}function I(e,t,n,r,o,i){e.executeSql(n,r,o,(function(e,a){a.code===a.SYNTAX_ERR?e.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[t.storeName],(function(e,s){s.rows.length?i(e,a):D(e,t,(function(){e.executeSql(n,r,o,i)}),i)}),i):i(e,a)}),i)}function N(e,t,n,r){var o=this;e=l(e);var i=new a((function(i,a){o.ready().then((function(){void 0===t&&(t=null);var s=t,u=o._dbInfo;u.serializer.serialize(t,(function(t,l){l?a(l):u.db.transaction((function(n){I(n,u,"INSERT OR REPLACE INTO "+u.storeName+" (key, value) VALUES (?, ?)",[e,t],(function(){i(s)}),(function(e,t){a(t)}))}),(function(t){if(t.code===t.QUOTA_ERR){if(r>0)return void i(N.apply(o,[e,s,n,r-1]));a(t)}}))}))})).catch(a)}));return s(i,n),i}function z(e){return new a((function(t,n){e.transaction((function(r){r.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name <> '__WebKitDatabaseInfoTable__'",[],(function(n,r){for(var o=[],i=0;i<r.rows.length;i++)o.push(r.rows.item(i).name);t({db:e,storeNames:o})}),(function(e,t){n(t)}))}),(function(e){n(e)}))}))}var F={_driver:"webSQLStorage",_initStorage:function(e){var t=this,n={db:null};if(e)for(var r in e)n[r]="string"!=typeof e[r]?e[r].toString():e[r];var o=new a((function(e,r){try{n.db=openDatabase(n.name,String(n.version),n.description,n.size)}catch(e){return r(e)}n.db.transaction((function(o){D(o,n,(function(){t._dbInfo=n,e()}),(function(e,t){r(t)}))}),r)}));return n.serializer=R,o},_support:"function"==typeof openDatabase,iterate:function(e,t){var n=this,r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){I(n,o,"SELECT * FROM "+o.storeName,[],(function(n,r){for(var i=r.rows,a=i.length,s=0;s<a;s++){var u=i.item(s),l=u.value;if(l&&(l=o.serializer.deserialize(l)),void 0!==(l=e(l,u.key,s+1)))return void t(l)}t()}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},getItem:function(e,t){var n=this;e=l(e);var r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){I(n,o,"SELECT * FROM "+o.storeName+" WHERE key = ? LIMIT 1",[e],(function(e,n){var r=n.rows.length?n.rows.item(0).value:null;r&&(r=o.serializer.deserialize(r)),t(r)}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},setItem:function(e,t,n){return N.apply(this,[e,t,n,1])},removeItem:function(e,t){var n=this;e=l(e);var r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){I(n,o,"DELETE FROM "+o.storeName+" WHERE key = ?",[e],(function(){t()}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},clear:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){I(t,r,"DELETE FROM "+r.storeName,[],(function(){e()}),(function(e,t){n(t)}))}))})).catch(n)}));return s(n,e),n},length:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){I(t,r,"SELECT COUNT(key) as c FROM "+r.storeName,[],(function(t,n){var r=n.rows.item(0).c;e(r)}),(function(e,t){n(t)}))}))})).catch(n)}));return s(n,e),n},key:function(e,t){var n=this,r=new a((function(t,r){n.ready().then((function(){var o=n._dbInfo;o.db.transaction((function(n){I(n,o,"SELECT key FROM "+o.storeName+" WHERE id = ? LIMIT 1",[e+1],(function(e,n){var r=n.rows.length?n.rows.item(0).key:null;t(r)}),(function(e,t){r(t)}))}))})).catch(r)}));return s(r,t),r},keys:function(e){var t=this,n=new a((function(e,n){t.ready().then((function(){var r=t._dbInfo;r.db.transaction((function(t){I(t,r,"SELECT key FROM "+r.storeName,[],(function(t,n){for(var r=[],o=0;o<n.rows.length;o++)r.push(n.rows.item(o).key);e(r)}),(function(e,t){n(t)}))}))})).catch(n)}));return s(n,e),n},dropInstance:function(e,t){t=c.apply(this,arguments);var n=this.config();(e="function"!=typeof e&&e||{}).name||(e.name=e.name||n.name,e.storeName=e.storeName||n.storeName);var r,o=this;return s(r=e.name?new a((function(t){var r;r=e.name===n.name?o._dbInfo.db:openDatabase(e.name,"","",0),e.storeName?t({db:r,storeNames:[e.storeName]}):t(z(r))})).then((function(e){return new a((function(t,n){e.db.transaction((function(r){function o(e){return new a((function(t,n){r.executeSql("DROP TABLE IF EXISTS "+e,[],(function(){t()}),(function(e,t){n(t)}))}))}for(var i=[],s=0,u=e.storeNames.length;s<u;s++)i.push(o(e.storeNames[s]));a.all(i).then((function(){t()})).catch((function(e){n(e)}))}),(function(e){n(e)}))}))})):a.reject("Invalid arguments"),t),r}};function B(e,t){var n=e.name+"/";return e.storeName!==t.storeName&&(n+=e.storeName+"/"),n}function H(){return!function(){try{return localStorage.setItem("_localforage_support_test",!0),localStorage.removeItem("_localforage_support_test"),!1}catch(e){return!0}}()||localStorage.length>0}var U={_driver:"localStorageWrapper",_initStorage:function(e){var t={};if(e)for(var n in e)t[n]=e[n];return t.keyPrefix=B(e,this._defaultConfig),H()?(this._dbInfo=t,t.serializer=R,a.resolve()):a.reject()},_support:function(){try{return"undefined"!=typeof localStorage&&"setItem"in localStorage&&!!localStorage.setItem}catch(e){return!1}}(),iterate:function(e,t){var n=this,r=n.ready().then((function(){for(var t=n._dbInfo,r=t.keyPrefix,o=r.length,i=localStorage.length,a=1,s=0;s<i;s++){var u=localStorage.key(s);if(0===u.indexOf(r)){var l=localStorage.getItem(u);if(l&&(l=t.serializer.deserialize(l)),void 0!==(l=e(l,u.substring(o),a++)))return l}}}));return s(r,t),r},getItem:function(e,t){var n=this;e=l(e);var r=n.ready().then((function(){var t=n._dbInfo,r=localStorage.getItem(t.keyPrefix+e);return r&&(r=t.serializer.deserialize(r)),r}));return s(r,t),r},setItem:function(e,t,n){var r=this;e=l(e);var o=r.ready().then((function(){void 0===t&&(t=null);var n=t;return new a((function(o,i){var a=r._dbInfo;a.serializer.serialize(t,(function(t,r){if(r)i(r);else try{localStorage.setItem(a.keyPrefix+e,t),o(n)}catch(e){"QuotaExceededError"!==e.name&&"NS_ERROR_DOM_QUOTA_REACHED"!==e.name||i(e),i(e)}}))}))}));return s(o,n),o},removeItem:function(e,t){var n=this;e=l(e);var r=n.ready().then((function(){var t=n._dbInfo;localStorage.removeItem(t.keyPrefix+e)}));return s(r,t),r},clear:function(e){var t=this,n=t.ready().then((function(){for(var e=t._dbInfo.keyPrefix,n=localStorage.length-1;n>=0;n--){var r=localStorage.key(n);0===r.indexOf(e)&&localStorage.removeItem(r)}}));return s(n,e),n},length:function(e){var t=this.keys().then((function(e){return e.length}));return s(t,e),t},key:function(e,t){var n=this,r=n.ready().then((function(){var t,r=n._dbInfo;try{t=localStorage.key(e)}catch(e){t=null}return t&&(t=t.substring(r.keyPrefix.length)),t}));return s(r,t),r},keys:function(e){var t=this,n=t.ready().then((function(){for(var e=t._dbInfo,n=localStorage.length,r=[],o=0;o<n;o++){var i=localStorage.key(o);0===i.indexOf(e.keyPrefix)&&r.push(i.substring(e.keyPrefix.length))}return r}));return s(n,e),n},dropInstance:function(e,t){if(t=c.apply(this,arguments),!(e="function"!=typeof e&&e||{}).name){var n=this.config();e.name=e.name||n.name,e.storeName=e.storeName||n.storeName}var r,o=this;return s(r=e.name?new a((function(t){e.storeName?t(B(e,o._defaultConfig)):t(e.name+"/")})).then((function(e){for(var t=localStorage.length-1;t>=0;t--){var n=localStorage.key(t);0===n.indexOf(e)&&localStorage.removeItem(n)}})):a.reject("Invalid arguments"),t),r}},W=function(e,t){for(var n,r,o=e.length,i=0;i<o;){if((n=e[i])===(r=t)||"number"==typeof n&&"number"==typeof r&&isNaN(n)&&isNaN(r))return!0;i++}return!1},V=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},q={},Y={},G={INDEXEDDB:E,WEBSQL:F,LOCALSTORAGE:U},$=[G.INDEXEDDB._driver,G.WEBSQL._driver,G.LOCALSTORAGE._driver],K=["dropInstance"],Z=["clear","getItem","iterate","key","keys","length","removeItem","setItem"].concat(K),X={description:"",driver:$.slice(),name:"localforage",size:4980736,storeName:"keyvaluepairs",version:1};function Q(e,t){e[t]=function(){var n=arguments;return e.ready().then((function(){return e[t].apply(e,n)}))}}function J(){for(var e=1;e<arguments.length;e++){var t=arguments[e];if(t)for(var n in t)t.hasOwnProperty(n)&&(V(t[n])?arguments[0][n]=t[n].slice():arguments[0][n]=t[n])}return arguments[0]}var ee=new(function(){function e(t){for(var n in function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),G)if(G.hasOwnProperty(n)){var r=G[n],o=r._driver;this[n]=o,q[o]||this.defineDriver(r)}this._defaultConfig=J({},X),this._config=J({},this._defaultConfig,t),this._driverSet=null,this._initDriver=null,this._ready=!1,this._dbInfo=null,this._wrapLibraryMethodsWithReady(),this.setDriver(this._config.driver).catch((function(){}))}return e.prototype.config=function(e){if("object"===(void 0===e?"undefined":r(e))){if(this._ready)return new Error("Can't call config() after localforage has been used.");for(var t in e){if("storeName"===t&&(e[t]=e[t].replace(/\W/g,"_")),"version"===t&&"number"!=typeof e[t])return new Error("Database version must be a number.");this._config[t]=e[t]}return!("driver"in e)||!e.driver||this.setDriver(this._config.driver)}return"string"==typeof e?this._config[e]:this._config},e.prototype.defineDriver=function(e,t,n){var r=new a((function(t,n){try{var r=e._driver,o=new Error("Custom driver not compliant; see https://mozilla.github.io/localForage/#definedriver");if(!e._driver)return void n(o);for(var i=Z.concat("_initStorage"),u=0,l=i.length;u<l;u++){var c=i[u];if((!W(K,c)||e[c])&&"function"!=typeof e[c])return void n(o)}!function(){for(var t=function(e){return function(){var t=new Error("Method "+e+" is not implemented by the current driver"),n=a.reject(t);return s(n,arguments[arguments.length-1]),n}},n=0,r=K.length;n<r;n++){var o=K[n];e[o]||(e[o]=t(o))}}();var f=function(n){q[r]&&console.info("Redefining LocalForage driver: "+r),q[r]=e,Y[r]=n,t()};"_support"in e?e._support&&"function"==typeof e._support?e._support().then(f,n):f(!!e._support):f(!0)}catch(e){n(e)}}));return u(r,t,n),r},e.prototype.driver=function(){return this._driver||null},e.prototype.getDriver=function(e,t,n){var r=q[e]?a.resolve(q[e]):a.reject(new Error("Driver not found."));return u(r,t,n),r},e.prototype.getSerializer=function(e){var t=a.resolve(R);return u(t,e),t},e.prototype.ready=function(e){var t=this,n=t._driverSet.then((function(){return null===t._ready&&(t._ready=t._initDriver()),t._ready}));return u(n,e,e),n},e.prototype.setDriver=function(e,t,n){var r=this;V(e)||(e=[e]);var o=this._getSupportedDrivers(e);function i(){r._config.driver=r.driver()}function s(e){return r._extend(e),i(),r._ready=r._initStorage(r._config),r._ready}var l=null!==this._driverSet?this._driverSet.catch((function(){return a.resolve()})):a.resolve();return this._driverSet=l.then((function(){var e=o[0];return r._dbInfo=null,r._ready=null,r.getDriver(e).then((function(e){r._driver=e._driver,i(),r._wrapLibraryMethodsWithReady(),r._initDriver=function(e){return function(){var t=0;return function n(){for(;t<e.length;){var o=e[t];return t++,r._dbInfo=null,r._ready=null,r.getDriver(o).then(s).catch(n)}i();var u=new Error("No available storage method found.");return r._driverSet=a.reject(u),r._driverSet}()}}(o)}))})).catch((function(){i();var e=new Error("No available storage method found.");return r._driverSet=a.reject(e),r._driverSet})),u(this._driverSet,t,n),this._driverSet},e.prototype.supports=function(e){return!!Y[e]},e.prototype._extend=function(e){J(this,e)},e.prototype._getSupportedDrivers=function(e){for(var t=[],n=0,r=e.length;n<r;n++){var o=e[n];this.supports(o)&&t.push(o)}return t},e.prototype._wrapLibraryMethodsWithReady=function(){for(var e=0,t=Z.length;e<t;e++)Q(this,Z[e])},e.prototype.createInstance=function(t){return new e(t)},e}());t.exports=ee},{3:3}]},{},[4])(4)}).call(this,n(31))},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e.default:e}t.__esModule=!0;var o=n(276);t.Motion=r(o);var i=n(278);t.StaggeredMotion=r(i);var a=n(279);t.TransitionMotion=r(a);var s=n(281);t.spring=r(s);var u=n(152);t.presets=r(u);var l=n(74);t.stripStyle=r(l);var c=n(282);t.reorderKeys=r(c)},function(e,t,n){var r=n(341),o=n(342),i=n(170),a=n(343);e.exports=function(e){return r(e)||o(e)||i(e)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(67),o=n(50);e.exports=function(e,t){for(var n=0,i=(t=r(t,e)).length;null!=e&&n<i;)e=e[o(t[n++])];return n&&n==i?e:void 0}},function(e,t,n){var r=n(23),o=n(68),i=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,a=/^\w*$/;e.exports=function(e,t){if(r(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!o(e))||(a.test(e)||!i.test(e)||null!=t&&e in Object(t))}},function(e,t,n){var r=n(238),o=n(254),i=n(256),a=n(257),s=n(258);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(39),o=n(28);e.exports=function(e){if(!o(e))return!1;var t=r(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},function(e,t,n){var r=n(45)(n(32),"Map");e.exports=r},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){var t={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=0);return t},e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t,n,o,i,a,s){var u=n+(-i*(t-o)+-a*n)*e,l=t+u*e;if(Math.abs(u)<s&&Math.abs(l-o)<s)return r[0]=o,r[1]=0,r;return r[0]=l,r[1]=u,r};var r=[0,0];e.exports=t.default},function(e,t,n){(function(t){(function(){var n,r,o;"undefined"!=typeof performance&&null!==performance&&performance.now?e.exports=function(){return performance.now()}:null!=t&&t.hrtime?(e.exports=function(){return(n()-o)/1e6},r=t.hrtime,o=(n=function(){var e;return 1e9*(e=r())[0]+e[1]})()):Date.now?(e.exports=function(){return Date.now()-o},o=Date.now()):(e.exports=function(){return(new Date).getTime()-o},o=(new Date).getTime())}).call(this)}).call(this,n(151))},function(e,t,n){(function(t){for(var r=n(277),o="undefined"==typeof window?t:window,i=["moz","webkit"],a="AnimationFrame",s=o["request"+a],u=o["cancel"+a]||o["cancelRequest"+a],l=0;!s&&l<i.length;l++)s=o[i[l]+"Request"+a],u=o[i[l]+"Cancel"+a]||o[i[l]+"CancelRequest"+a];if(!s||!u){var c=0,f=0,d=[];s=function(e){if(0===d.length){var t=r(),n=Math.max(0,1e3/60-(t-c));c=n+t,setTimeout((function(){var e=d.slice(0);d.length=0;for(var t=0;t<e.length;t++)if(!e[t].cancelled)try{e[t].callback(c)}catch(e){setTimeout((function(){throw e}),0)}}),Math.round(n))}return d.push({handle:++f,callback:e,cancelled:!1}),f},u=function(e){for(var t=0;t<d.length;t++)d[t].handle===e&&(d[t].cancelled=!0)}}e.exports=function(e){return s.call(o,e)},e.exports.cancel=function(){u.apply(o,arguments)},e.exports.polyfill=function(e){e||(e=o),e.requestAnimationFrame=s,e.cancelAnimationFrame=u}}).call(this,n(31))},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t,n){for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r)){if(0!==n[r])return!1;var o="number"==typeof t[r]?t[r]:t[r].val;if(e[r]!==o)return!1}return!0},e.exports=t.default},function(e,t,n){var r=n(153),o=n(59),i=Object.prototype.hasOwnProperty;e.exports=function(e,t,n){var a=e[t];i.call(e,t)&&o(a,n)&&(void 0!==n||t in e)||r(e,t,n)}},function(e,t){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}},function(e,t,n){(function(e){var r=n(32),o=n(292),i=t&&!t.nodeType&&t,a=i&&"object"==typeof e&&e&&!e.nodeType&&e,s=a&&a.exports===i?r.Buffer:void 0,u=(s?s.isBuffer:void 0)||o;e.exports=u}).call(this,n(57)(e))},function(e,t,n){var r=n(293),o=n(108),i=n(294),a=i&&i.isTypedArray,s=a?o(a):r;e.exports=s},function(e,t){e.exports=function(e){return function(t){return e(t)}}},function(e,t,n){var r=n(296),o=n(318),i=n(75),a=n(23),s=n(321);e.exports=function(e){return"function"==typeof e?e:null==e?i:"object"==typeof e?a(e)?o(e[0],e[1]):r(e):s(e)}},function(e,t,n){var r=n(303),o=n(33);e.exports=function e(t,n,i,a,s){return t===n||(null==t||null==n||!o(t)&&!o(n)?t!=t&&n!=n:r(t,n,i,a,e,s))}},function(e,t){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length,o=0,i=[];++n<r;){var a=e[n];t(a,n,e)&&(i[o++]=a)}return i}},function(e,t,n){var r=n(325),o=n(328)(r);e.exports=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addClassName=l,t.addEvent=function(e,t,n,r){if(!e)return;const o={capture:!0,...r};e.addEventListener?e.addEventListener(t,n,o):e.attachEvent?e.attachEvent("on"+t,n):e["on"+t]=n},t.addUserSelectStyles=function(e){if(!e)return;let t=e.getElementById("react-draggable-style-el");t||(t=e.createElement("style"),t.type="text/css",t.id="react-draggable-style-el",t.innerHTML=".react-draggable-transparent-selection *::-moz-selection {all: inherit;}\n",t.innerHTML+=".react-draggable-transparent-selection *::selection {all: inherit;}\n",e.getElementsByTagName("head")[0].appendChild(t));e.body&&l(e.body,"react-draggable-transparent-selection")},t.createCSSTransform=function(e,t){const n=u(e,t,"px");return{[(0,o.browserPrefixToKey)("transform",o.default)]:n}},t.createSVGTransform=function(e,t){return u(e,t,"")},t.getTouch=function(e,t){return e.targetTouches&&(0,r.findInArray)(e.targetTouches,e=>t===e.identifier)||e.changedTouches&&(0,r.findInArray)(e.changedTouches,e=>t===e.identifier)},t.getTouchIdentifier=function(e){if(e.targetTouches&&e.targetTouches[0])return e.targetTouches[0].identifier;if(e.changedTouches&&e.changedTouches[0])return e.changedTouches[0].identifier},t.getTranslation=u,t.innerHeight=function(e){let t=e.clientHeight;const n=e.ownerDocument.defaultView.getComputedStyle(e);return t-=(0,r.int)(n.paddingTop),t-=(0,r.int)(n.paddingBottom),t},t.innerWidth=function(e){let t=e.clientWidth;const n=e.ownerDocument.defaultView.getComputedStyle(e);return t-=(0,r.int)(n.paddingLeft),t-=(0,r.int)(n.paddingRight),t},t.matchesSelector=s,t.matchesSelectorAndParentsTo=function(e,t,n){let r=e;do{if(s(r,t))return!0;if(r===n)return!1;r=r.parentNode}while(r);return!1},t.offsetXYFromParent=function(e,t,n){const r=t===t.ownerDocument.body?{left:0,top:0}:t.getBoundingClientRect(),o=(e.clientX+t.scrollLeft-r.left)/n,i=(e.clientY+t.scrollTop-r.top)/n;return{x:o,y:i}},t.outerHeight=function(e){let t=e.clientHeight;const n=e.ownerDocument.defaultView.getComputedStyle(e);return t+=(0,r.int)(n.borderTopWidth),t+=(0,r.int)(n.borderBottomWidth),t},t.outerWidth=function(e){let t=e.clientWidth;const n=e.ownerDocument.defaultView.getComputedStyle(e);return t+=(0,r.int)(n.borderLeftWidth),t+=(0,r.int)(n.borderRightWidth),t},t.removeClassName=c,t.removeEvent=function(e,t,n,r){if(!e)return;const o={capture:!0,...r};e.removeEventListener?e.removeEventListener(t,n,o):e.detachEvent?e.detachEvent("on"+t,n):e["on"+t]=null},t.removeUserSelectStyles=function(e){if(!e)return;try{if(e.body&&c(e.body,"react-draggable-transparent-selection"),e.selection)e.selection.empty();else{const t=(e.defaultView||window).getSelection();t&&"Caret"!==t.type&&t.removeAllRanges()}}catch(e){}};var r=n(80),o=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=i(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=o?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(r,a,s):r[a]=e[a]}r.default=e,n&&n.set(e,r);return r}(n(334));function i(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(i=function(e){return e?n:t})(e)}let a="";function s(e,t){return a||(a=(0,r.findInArray)(["matches","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","oMatchesSelector"],(function(t){return(0,r.isFunction)(e[t])}))),!!(0,r.isFunction)(e[a])&&e[a](t)}function u(e,t,n){let{x:r,y:o}=e,i="translate(".concat(r).concat(n,",").concat(o).concat(n,")");if(t){const e="".concat("string"==typeof t.x?t.x:t.x+n),r="".concat("string"==typeof t.y?t.y:t.y+n);i="translate(".concat(e,", ").concat(r,")")+i}return i}function l(e,t){e.classList?e.classList.add(t):e.className.match(new RegExp("(?:^|\\s)".concat(t,"(?!\\S)")))||(e.className+=" ".concat(t))}function c(e,t){e.classList?e.classList.remove(t):e.className=e.className.replace(new RegExp("(?:^|\\s)".concat(t,"(?!\\S)"),"g"),"")}},function(e,t,n){var r=n(174);e.exports=function(e,t){return!!(null==e?0:e.length)&&r(e,t,0)>-1}},function(e,t){e.exports=function(e,t,n){for(var r=-1,o=null==e?0:e.length;++r<o;)if(n(t,e[r]))return!0;return!1}},function(e,t,n){"use strict";var r,o,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),a=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var s=n(0),u=n(344),l=n(85),c=n(26),f=n(119),d=n(120).default;function p(e,t){return{dragDropManager:u.createDragDropManager(e,t)}}t.Consumer=(o=s.createContext({dragDropManager:void 0})).Consumer,t.Provider=o.Provider,t.createChildContext=p,t.DragDropContextProvider=function(e){var n=e.backend,r=e.context,o=e.children,i=p(n,r);return s.createElement(t.Provider,{value:i},o)},t.DragDropContext=function(e,n){l.default("DragDropContext","backend",e);var r=p(e,n);return function(e){var n=e,o=n.displayName||n.name||"Component",u=function(u){function l(){var e=null!==u&&u.apply(this,arguments)||this;return e.ref=s.createRef(),e}return i(l,u),l.prototype.getDecoratedComponentInstance=function(){return c(this.ref.current,"In order to access an instance of the decorated component it can not be a stateless component."),this.ref.current},l.prototype.getManager=function(){return r.dragDropManager},l.prototype.render=function(){return s.createElement(t.Provider,{value:r},s.createElement(n,a({},this.props,{ref:d(n)?this.ref:void 0})))},l.DecoratedComponent=e,l.displayName="DragDropContext("+o+")",l}(s.Component);return f(u,e)}}},function(e,t,n){var r=n(163),o=n(357);e.exports=function e(t,n,i,a,s){var u=-1,l=t.length;for(i||(i=o),s||(s=[]);++u<l;){var c=t[u];n>0&&i(c)?n>1?e(c,n-1,i,a,s):r(s,c):a||(s[s.length]=c)}return s}},function(e,t,n){"use strict"; /** * Copyright 2015, Yahoo! Inc. * Copyrights licensed under the New BSD License. See the accompanying LICENSE file for terms. */var r={childContextTypes:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},i=Object.defineProperty,a=Object.getOwnPropertyNames,s=Object.getOwnPropertySymbols,u=Object.getOwnPropertyDescriptor,l=Object.getPrototypeOf,c=l&&l(Object);e.exports=function e(t,n,f){if("string"!=typeof n){if(c){var d=l(n);d&&d!==c&&e(t,d,f)}var p=a(n);s&&(p=p.concat(s(n)));for(var h=0;h<p.length;++h){var v=p[h];if(!(r[v]||o[v]||f&&f[v])){var g=u(n,v);try{i(t,v,g)}catch(e){}}}return t}return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.default=function(e){return Boolean(e&&e.prototype&&"function"==typeof e.prototype.render)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FILE="__NATIVE_FILE__",t.URL="__NATIVE_URL__",t.TEXT="__NATIVE_TEXT__"},function(e,t,n){var r=n(187),o=n(123);function i(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}i.prototype=r(o.prototype),i.prototype.constructor=i,e.exports=i},function(e,t){e.exports=function(){}},function(e,t,n){var r=n(187),o=n(123);function i(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}i.prototype=r(o.prototype),i.prototype.constructor=i,e.exports=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.buildRegExpFromDelimiters=function(e){var t=e.map((function(e){var t=e-48*Math.floor(e/48);return String.fromCharCode(96<=e?t:e)})).join(""),n=(0,i.default)(t);return new RegExp("["+n+"]+")},t.canDrag=function(e){var t=e.moveTag,n=e.readOnly,r=e.allowDragDrop;return void 0!==t&&!n&&r},t.canDrop=function(e){var t=e.readOnly,n=e.allowDragDrop;return!t&&n};var r,o=n(414),i=(r=o)&&r.__esModule?r:{default:r}},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t,n,r=e.Pos;function o(e,t){for(var n=function(e){var t=e.flags;return null!=t?t:(e.ignoreCase?"i":"")+(e.global?"g":"")+(e.multiline?"m":"")}(e),r=n,o=0;o<t.length;o++)-1==r.indexOf(t.charAt(o))&&(r+=t.charAt(o));return n==r?e:new RegExp(e.source,r)}function i(e){return/\\s|\\n|\n|\\W|\\D|\[\^/.test(e.source)}function a(e,t,n){t=o(t,"g");for(var i=n.line,a=n.ch,s=e.lastLine();i<=s;i++,a=0){t.lastIndex=a;var u=e.getLine(i),l=t.exec(u);if(l)return{from:r(i,l.index),to:r(i,l.index+l[0].length),match:l}}}function s(e,t,n){if(!i(t))return a(e,t,n);t=o(t,"gm");for(var s,u=1,l=n.line,c=e.lastLine();l<=c;){for(var f=0;f<u&&!(l>c);f++){var d=e.getLine(l++);s=null==s?d:s+"\n"+d}u*=2,t.lastIndex=n.ch;var p=t.exec(s);if(p){var h=s.slice(0,p.index).split("\n"),v=p[0].split("\n"),g=n.line+h.length-1,m=h[h.length-1].length;return{from:r(g,m),to:r(g+v.length-1,1==v.length?m+v[0].length:v[v.length-1].length),match:p}}}}function u(e,t,n){for(var r,o=0;o<=e.length;){t.lastIndex=o;var i=t.exec(e);if(!i)break;var a=i.index+i[0].length;if(a>e.length-n)break;(!r||a>r.index+r[0].length)&&(r=i),o=i.index+1}return r}function l(e,t,n){t=o(t,"g");for(var i=n.line,a=n.ch,s=e.firstLine();i>=s;i--,a=-1){var l=e.getLine(i),c=u(l,t,a<0?0:l.length-a);if(c)return{from:r(i,c.index),to:r(i,c.index+c[0].length),match:c}}}function c(e,t,n){if(!i(t))return l(e,t,n);t=o(t,"gm");for(var a,s=1,c=e.getLine(n.line).length-n.ch,f=n.line,d=e.firstLine();f>=d;){for(var p=0;p<s&&f>=d;p++){var h=e.getLine(f--);a=null==a?h:h+"\n"+a}s*=2;var v=u(a,t,c);if(v){var g=a.slice(0,v.index).split("\n"),m=v[0].split("\n"),y=f+g.length,b=g[g.length-1].length;return{from:r(y,b),to:r(y+m.length-1,1==m.length?b+m[0].length:m[m.length-1].length),match:v}}}}function f(e,t,n,r){if(e.length==t.length)return n;for(var o=0,i=n+Math.max(0,e.length-t.length);;){if(o==i)return o;var a=o+i>>1,s=r(e.slice(0,a)).length;if(s==n)return a;s>n?i=a:o=a+1}}function d(e,o,i,a){if(!o.length)return null;var s=a?t:n,u=s(o).split(/\r|\n\r?/);e:for(var l=i.line,c=i.ch,d=e.lastLine()+1-u.length;l<=d;l++,c=0){var p=e.getLine(l).slice(c),h=s(p);if(1==u.length){var v=h.indexOf(u[0]);if(-1==v)continue e;return i=f(p,h,v,s)+c,{from:r(l,f(p,h,v,s)+c),to:r(l,f(p,h,v+u[0].length,s)+c)}}var g=h.length-u[0].length;if(h.slice(g)==u[0]){for(var m=1;m<u.length-1;m++)if(s(e.getLine(l+m))!=u[m])continue e;var y=e.getLine(l+u.length-1),b=s(y),w=u[u.length-1];if(b.slice(0,w.length)==w)return{from:r(l,f(p,h,g,s)+c),to:r(l+u.length-1,f(y,b,w.length,s))}}}}function p(e,o,i,a){if(!o.length)return null;var s=a?t:n,u=s(o).split(/\r|\n\r?/);e:for(var l=i.line,c=i.ch,d=e.firstLine()-1+u.length;l>=d;l--,c=-1){var p=e.getLine(l);c>-1&&(p=p.slice(0,c));var h=s(p);if(1==u.length){var v=h.lastIndexOf(u[0]);if(-1==v)continue e;return{from:r(l,f(p,h,v,s)),to:r(l,f(p,h,v+u[0].length,s))}}var g=u[u.length-1];if(h.slice(0,g.length)==g){var m=1;for(i=l-u.length+1;m<u.length-1;m++)if(s(e.getLine(i+m))!=u[m])continue e;var y=e.getLine(l+1-u.length),b=s(y);if(b.slice(b.length-u[0].length)==u[0])return{from:r(l+1-u.length,f(y,b,y.length-u[0].length,s)),to:r(l,f(p,h,g.length,s))}}}}function h(e,t,n,i){var u;this.atOccurrence=!1,this.afterEmptyMatch=!1,this.doc=e,n=n?e.clipPos(n):r(0,0),this.pos={from:n,to:n},"object"==typeof i?u=i.caseFold:(u=i,i=null),"string"==typeof t?(null==u&&(u=!1),this.matches=function(n,r){return(n?p:d)(e,t,r,u)}):(t=o(t,"gm"),i&&!1===i.multiline?this.matches=function(n,r){return(n?l:a)(e,t,r)}:this.matches=function(n,r){return(n?c:s)(e,t,r)})}String.prototype.normalize?(t=function(e){return e.normalize("NFD").toLowerCase()},n=function(e){return e.normalize("NFD")}):(t=function(e){return e.toLowerCase()},n=function(e){return e}),h.prototype={findNext:function(){return this.find(!1)},findPrevious:function(){return this.find(!0)},find:function(t){var n=this.doc.clipPos(t?this.pos.from:this.pos.to);if(this.afterEmptyMatch&&this.atOccurrence&&(n=r(n.line,n.ch),t?(n.ch--,n.ch<0&&(n.line--,n.ch=(this.doc.getLine(n.line)||"").length)):(n.ch++,n.ch>(this.doc.getLine(n.line)||"").length&&(n.ch=0,n.line++)),0!=e.cmpPos(n,this.doc.clipPos(n))))return this.atOccurrence=!1;var o=this.matches(t,n);if(this.afterEmptyMatch=o&&0==e.cmpPos(o.from,o.to),o)return this.pos=o,this.atOccurrence=!0,this.pos.match||!0;var i=r(t?this.doc.firstLine():this.doc.lastLine()+1,0);return this.pos={from:i,to:i},this.atOccurrence=!1},from:function(){if(this.atOccurrence)return this.pos.from},to:function(){if(this.atOccurrence)return this.pos.to},replace:function(t,n){if(this.atOccurrence){var o=e.splitLines(t);this.doc.replaceRange(o,this.pos.from,this.pos.to,n),this.pos.to=r(this.pos.from.line+o.length-1,o[o.length-1].length+(1==o.length?this.pos.from.ch:0))}}},e.defineExtension("getSearchCursor",(function(e,t,n){return new h(this.doc,e,t,n)})),e.defineDocExtension("getSearchCursor",(function(e,t,n){return new h(this,e,t,n)})),e.defineExtension("selectMatches",(function(t,n){for(var r=[],o=this.getSearchCursor(t,this.getCursor("from"),n);o.findNext()&&!(e.cmpPos(o.to(),this.getCursor("to"))>0);)r.push({anchor:o.from(),head:o.to()});r.length&&this.setSelections(r,0)}))}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";function t(e){for(var t={},n=0;n<e.length;++n)t[e[n].toLowerCase()]=!0;return t}e.defineMode("css",(function(t,n){var r=n.inline;n.propertyKeywords||(n=e.resolveMode("text/css"));var o,i,a=t.indentUnit,s=n.tokenHooks,u=n.documentTypes||{},l=n.mediaTypes||{},c=n.mediaFeatures||{},f=n.mediaValueKeywords||{},d=n.propertyKeywords||{},p=n.nonStandardPropertyKeywords||{},h=n.fontProperties||{},v=n.counterDescriptors||{},g=n.colorKeywords||{},m=n.valueKeywords||{},y=n.allowNested,b=n.lineComment,w=!0===n.supportsAtComponent,_=!1!==t.highlightNonStandardPropertyKeywords;function x(e,t){return o=t,e}function k(e,t){var n=e.next();if(s[n]){var r=s[n](e,t);if(!1!==r)return r}return"@"==n?(e.eatWhile(/[\w\\\-]/),x("def",e.current())):"="==n||("~"==n||"|"==n)&&e.eat("=")?x(null,"compare"):'"'==n||"'"==n?(t.tokenize=C(n),t.tokenize(e,t)):"#"==n?(e.eatWhile(/[\w\\\-]/),x("atom","hash")):"!"==n?(e.match(/^\s*\w*/),x("keyword","important")):/\d/.test(n)||"."==n&&e.eat(/\d/)?(e.eatWhile(/[\w.%]/),x("number","unit")):"-"!==n?/[,+>*\/]/.test(n)?x(null,"select-op"):"."==n&&e.match(/^-?[_a-z][_a-z0-9-]*/i)?x("qualifier","qualifier"):/[:;{}\[\]\(\)]/.test(n)?x(null,n):e.match(/^[\w-.]+(?=\()/)?(/^(url(-prefix)?|domain|regexp)$/i.test(e.current())&&(t.tokenize=O),x("variable callee","variable")):/[\w\\\-]/.test(n)?(e.eatWhile(/[\w\\\-]/),x("property","word")):x(null,null):/[\d.]/.test(e.peek())?(e.eatWhile(/[\w.%]/),x("number","unit")):e.match(/^-[\w\\\-]*/)?(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?x("variable-2","variable-definition"):x("variable-2","variable")):e.match(/^\w+-/)?x("meta","meta"):void 0}function C(e){return function(t,n){for(var r,o=!1;null!=(r=t.next());){if(r==e&&!o){")"==e&&t.backUp(1);break}o=!o&&"\\"==r}return(r==e||!o&&")"!=e)&&(n.tokenize=null),x("string","string")}}function O(e,t){return e.next(),e.match(/^\s*[\"\')]/,!1)?t.tokenize=null:t.tokenize=C(")"),x(null,"(")}function E(e,t,n){this.type=e,this.indent=t,this.prev=n}function S(e,t,n,r){return e.context=new E(n,t.indentation()+(!1===r?0:a),e.context),n}function T(e){return e.context.prev&&(e.context=e.context.prev),e.context.type}function j(e,t,n){return A[n.context.type](e,t,n)}function M(e,t,n,r){for(var o=r||1;o>0;o--)n.context=n.context.prev;return j(e,t,n)}function L(e){var t=e.current().toLowerCase();i=m.hasOwnProperty(t)?"atom":g.hasOwnProperty(t)?"keyword":"variable"}var A={top:function(e,t,n){if("{"==e)return S(n,t,"block");if("}"==e&&n.context.prev)return T(n);if(w&&/@component/i.test(e))return S(n,t,"atComponentBlock");if(/^@(-moz-)?document$/i.test(e))return S(n,t,"documentTypes");if(/^@(media|supports|(-moz-)?document|import)$/i.test(e))return S(n,t,"atBlock");if(/^@(font-face|counter-style)/i.test(e))return n.stateArg=e,"restricted_atBlock_before";if(/^@(-(moz|ms|o|webkit)-)?keyframes$/i.test(e))return"keyframes";if(e&&"@"==e.charAt(0))return S(n,t,"at");if("hash"==e)i="builtin";else if("word"==e)i="tag";else{if("variable-definition"==e)return"maybeprop";if("interpolation"==e)return S(n,t,"interpolation");if(":"==e)return"pseudo";if(y&&"("==e)return S(n,t,"parens")}return n.context.type},block:function(e,t,n){if("word"==e){var r=t.current().toLowerCase();return d.hasOwnProperty(r)?(i="property","maybeprop"):p.hasOwnProperty(r)?(i=_?"string-2":"property","maybeprop"):y?(i=t.match(/^\s*:(?:\s|$)/,!1)?"property":"tag","block"):(i+=" error","maybeprop")}return"meta"==e?"block":y||"hash"!=e&&"qualifier"!=e?A.top(e,t,n):(i="error","block")},maybeprop:function(e,t,n){return":"==e?S(n,t,"prop"):j(e,t,n)},prop:function(e,t,n){if(";"==e)return T(n);if("{"==e&&y)return S(n,t,"propBlock");if("}"==e||"{"==e)return M(e,t,n);if("("==e)return S(n,t,"parens");if("hash"!=e||/^#([0-9a-fA-f]{3,4}|[0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/.test(t.current())){if("word"==e)L(t);else if("interpolation"==e)return S(n,t,"interpolation")}else i+=" error";return"prop"},propBlock:function(e,t,n){return"}"==e?T(n):"word"==e?(i="property","maybeprop"):n.context.type},parens:function(e,t,n){return"{"==e||"}"==e?M(e,t,n):")"==e?T(n):"("==e?S(n,t,"parens"):"interpolation"==e?S(n,t,"interpolation"):("word"==e&&L(t),"parens")},pseudo:function(e,t,n){return"meta"==e?"pseudo":"word"==e?(i="variable-3",n.context.type):j(e,t,n)},documentTypes:function(e,t,n){return"word"==e&&u.hasOwnProperty(t.current())?(i="tag",n.context.type):A.atBlock(e,t,n)},atBlock:function(e,t,n){if("("==e)return S(n,t,"atBlock_parens");if("}"==e||";"==e)return M(e,t,n);if("{"==e)return T(n)&&S(n,t,y?"block":"top");if("interpolation"==e)return S(n,t,"interpolation");if("word"==e){var r=t.current().toLowerCase();i="only"==r||"not"==r||"and"==r||"or"==r?"keyword":l.hasOwnProperty(r)?"attribute":c.hasOwnProperty(r)?"property":f.hasOwnProperty(r)?"keyword":d.hasOwnProperty(r)?"property":p.hasOwnProperty(r)?_?"string-2":"property":m.hasOwnProperty(r)?"atom":g.hasOwnProperty(r)?"keyword":"error"}return n.context.type},atComponentBlock:function(e,t,n){return"}"==e?M(e,t,n):"{"==e?T(n)&&S(n,t,y?"block":"top",!1):("word"==e&&(i="error"),n.context.type)},atBlock_parens:function(e,t,n){return")"==e?T(n):"{"==e||"}"==e?M(e,t,n,2):A.atBlock(e,t,n)},restricted_atBlock_before:function(e,t,n){return"{"==e?S(n,t,"restricted_atBlock"):"word"==e&&"@counter-style"==n.stateArg?(i="variable","restricted_atBlock_before"):j(e,t,n)},restricted_atBlock:function(e,t,n){return"}"==e?(n.stateArg=null,T(n)):"word"==e?(i="@font-face"==n.stateArg&&!h.hasOwnProperty(t.current().toLowerCase())||"@counter-style"==n.stateArg&&!v.hasOwnProperty(t.current().toLowerCase())?"error":"property","maybeprop"):"restricted_atBlock"},keyframes:function(e,t,n){return"word"==e?(i="variable","keyframes"):"{"==e?S(n,t,"top"):j(e,t,n)},at:function(e,t,n){return";"==e?T(n):"{"==e||"}"==e?M(e,t,n):("word"==e?i="tag":"hash"==e&&(i="builtin"),"at")},interpolation:function(e,t,n){return"}"==e?T(n):"{"==e||";"==e?M(e,t,n):("word"==e?i="variable":"variable"!=e&&"("!=e&&")"!=e&&(i="error"),"interpolation")}};return{startState:function(e){return{tokenize:null,state:r?"block":"top",stateArg:null,context:new E(r?"block":"top",e||0,null)}},token:function(e,t){if(!t.tokenize&&e.eatSpace())return null;var n=(t.tokenize||k)(e,t);return n&&"object"==typeof n&&(o=n[1],n=n[0]),i=n,"comment"!=o&&(t.state=A[t.state](o,e,t)),i},indent:function(e,t){var n=e.context,r=t&&t.charAt(0),o=n.indent;return"prop"!=n.type||"}"!=r&&")"!=r||(n=n.prev),n.prev&&("}"!=r||"block"!=n.type&&"top"!=n.type&&"interpolation"!=n.type&&"restricted_atBlock"!=n.type?(")"!=r||"parens"!=n.type&&"atBlock_parens"!=n.type)&&("{"!=r||"at"!=n.type&&"atBlock"!=n.type)||(o=Math.max(0,n.indent-a)):o=(n=n.prev).indent),o},electricChars:"}",blockCommentStart:"/*",blockCommentEnd:"*/",blockCommentContinue:" * ",lineComment:b,fold:"brace"}}));var n=["domain","regexp","url","url-prefix"],r=t(n),o=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],i=t(o),a=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover","prefers-color-scheme","dynamic-range","video-dynamic-range"],s=t(a),u=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive","dark","light","standard","high"],l=t(u),c=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","all","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backdrop-filter","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-position-x","background-position-y","background-repeat","background-size","baseline-shift","binding","bleed","block-size","bookmark-label","bookmark-level","bookmark-state","bookmark-target","border","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","counter-increment","counter-reset","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-content","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-family","font-feature-settings","font-kerning","font-language-override","font-optical-sizing","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","inset","inset-block","inset-block-end","inset-block-start","inset-inline","inset-inline-end","inset-inline-start","isolation","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-height-step","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","offset","offset-anchor","offset-distance","offset-path","offset-position","offset-rotate","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotate","rotation","rotation-point","row-gap","ruby-align","ruby-overhang","ruby-position","ruby-span","scale","scroll-behavior","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-type","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-skip-ink","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-orientation","text-outline","text-overflow","text-rendering","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","touch-action","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","translate","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","paint-order","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],f=t(c),d=["accent-color","aspect-ratio","border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","content-visibility","margin-block","margin-block-end","margin-block-start","margin-inline","margin-inline-end","margin-inline-start","overflow-anchor","overscroll-behavior","padding-block","padding-block-end","padding-block-start","padding-inline","padding-inline-end","padding-inline-start","scroll-snap-stop","scrollbar-3d-light-color","scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-track-color","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","shape-inside","zoom"],p=t(d),h=t(["font-display","font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"]),v=t(["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"]),g=["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkgrey","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkslategrey","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dimgrey","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightgrey","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightslategrey","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","slategrey","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],m=t(g),y=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","axis-pan","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","blur","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","brightness","bullets","button","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","conic-gradient","contain","content","contents","content-box","context-menu","continuous","contrast","copy","counter","counters","cover","crop","cross","crosshair","cubic-bezier","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","drop-shadow","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fill-box","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","grayscale","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","hue-rotate","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","manipulation","match","matrix","matrix3d","media-play-button","media-slider","media-sliderthumb","media-volume-slider","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiple_mask_images","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","pinch-zoom","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeating-conic-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturate","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","sepia","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","stroke-box","sub","subpixel-antialiased","svg_masks","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unidirectional-pan","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","view-box","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],b=t(y),w=n.concat(o).concat(a).concat(u).concat(c).concat(d).concat(g).concat(y);function _(e,t){for(var n,r=!1;null!=(n=e.next());){if(r&&"/"==n){t.tokenize=null;break}r="*"==n}return["comment","comment"]}e.registerHelper("hintWords","css",w),e.defineMIME("text/css",{documentTypes:r,mediaTypes:i,mediaFeatures:s,mediaValueKeywords:l,propertyKeywords:f,nonStandardPropertyKeywords:p,fontProperties:h,counterDescriptors:v,colorKeywords:m,valueKeywords:b,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=_,_(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:i,mediaFeatures:s,mediaValueKeywords:l,propertyKeywords:f,nonStandardPropertyKeywords:p,colorKeywords:m,valueKeywords:b,fontProperties:h,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=_,_(e,t)):["operator","operator"]},":":function(e){return!!e.match(/^\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:i,mediaFeatures:s,mediaValueKeywords:l,propertyKeywords:f,nonStandardPropertyKeywords:p,colorKeywords:m,valueKeywords:b,fontProperties:h,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=_,_(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:r,mediaTypes:i,mediaFeatures:s,propertyKeywords:f,nonStandardPropertyKeywords:p,fontProperties:h,counterDescriptors:v,colorKeywords:m,valueKeywords:b,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=_,_(e,t))}},name:"css",helperType:"gss"})}(n(21))},function(e,t,n){"use strict";e.exports=s;var r=n(30),o=n(194),i=n(34),a=n(88);function s(e,t,n,a){var u,l=a||{};if(r.call(this,e,t,n,i.PROPERTY_VALUE_PART_TYPE),this.type="unknown",/^([+\-]?[\d\.]+)([a-z]+)$/i.test(e))switch(this.type="dimension",this.value=+RegExp.$1,this.units=RegExp.$2,this.units.toLowerCase()){case"em":case"rem":case"ex":case"px":case"cm":case"mm":case"in":case"pt":case"pc":case"ch":case"vh":case"vw":case"vmax":case"vmin":this.type="length";break;case"fr":this.type="grid";break;case"deg":case"rad":case"grad":case"turn":this.type="angle";break;case"ms":case"s":this.type="time";break;case"hz":case"khz":this.type="frequency";break;case"dpi":case"dpcm":this.type="resolution"}else/^([+\-]?[\d\.]+)%$/i.test(e)?(this.type="percentage",this.value=+RegExp.$1):/^([+\-]?\d+)$/i.test(e)?(this.type="integer",this.value=+RegExp.$1):/^([+\-]?[\d\.]+)$/i.test(e)?(this.type="number",this.value=+RegExp.$1):/^#([a-f0-9]{3,6})/i.test(e)?(this.type="color",3===(u=RegExp.$1).length?(this.red=parseInt(u.charAt(0)+u.charAt(0),16),this.green=parseInt(u.charAt(1)+u.charAt(1),16),this.blue=parseInt(u.charAt(2)+u.charAt(2),16)):(this.red=parseInt(u.substring(0,2),16),this.green=parseInt(u.substring(2,4),16),this.blue=parseInt(u.substring(4,6),16))):/^rgb\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/i.test(e)?(this.type="color",this.red=+RegExp.$1,this.green=+RegExp.$2,this.blue=+RegExp.$3):/^rgb\(\s*(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*\)/i.test(e)?(this.type="color",this.red=255*+RegExp.$1/100,this.green=255*+RegExp.$2/100,this.blue=255*+RegExp.$3/100):/^rgba\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*([\d\.]+)\s*\)/i.test(e)?(this.type="color",this.red=+RegExp.$1,this.green=+RegExp.$2,this.blue=+RegExp.$3,this.alpha=+RegExp.$4):/^rgba\(\s*(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*,\s*([\d\.]+)\s*\)/i.test(e)?(this.type="color",this.red=255*+RegExp.$1/100,this.green=255*+RegExp.$2/100,this.blue=255*+RegExp.$3/100,this.alpha=+RegExp.$4):/^hsl\(\s*(\d+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*\)/i.test(e)?(this.type="color",this.hue=+RegExp.$1,this.saturation=+RegExp.$2/100,this.lightness=+RegExp.$3/100):/^hsla\(\s*(\d+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*,\s*([\d\.]+)\s*\)/i.test(e)?(this.type="color",this.hue=+RegExp.$1,this.saturation=+RegExp.$2/100,this.lightness=+RegExp.$3/100,this.alpha=+RegExp.$4):/^url\(("([^\\"]|\\.)*")\)/i.test(e)?(this.type="uri",this.uri=s.parseString(RegExp.$1)):/^([^\(]+)\(/i.test(e)?(this.type="function",this.name=RegExp.$1,this.value=e):/^"([^\n\r\f\\"]|\\\r\n|\\[^\r0-9a-f]|\\[0-9a-f]{1,6}(\r\n|[ \n\r\t\f])?)*"/i.test(e)||/^'([^\n\r\f\\']|\\\r\n|\\[^\r0-9a-f]|\\[0-9a-f]{1,6}(\r\n|[ \n\r\t\f])?)*'/i.test(e)?(this.type="string",this.value=s.parseString(e)):o[e.toLowerCase()]?(this.type="color",u=o[e.toLowerCase()].substring(1),this.red=parseInt(u.substring(0,2),16),this.green=parseInt(u.substring(2,4),16),this.blue=parseInt(u.substring(4,6),16)):/^[,\/]$/.test(e)?(this.type="operator",this.value=e):/^-?[a-z_\u00A0-\uFFFF][a-z0-9\-_\u00A0-\uFFFF]*$/i.test(e)&&(this.type="identifier",this.value=e);this.wasIdent=Boolean(l.ident)}s.prototype=new r,s.prototype.constructor=s,s.parseString=function(e){return(e=e.slice(1,-1)).replace(/\\(\r\n|[^\r0-9a-f]|[0-9a-f]{1,6}(\r\n|[ \n\r\t\f])?)/gi,(function(e,t){if(/^(\n|\r\n|\r|\f)$/.test(t))return"";var n=/^[0-9a-f]{1,6}/i.exec(t);if(n){var r=parseInt(n[0],16);return String.fromCodePoint?String.fromCodePoint(r):String.fromCharCode(r)}return t}))},s.serializeString=function(e){return'"'+e.replace(/["\r\n\f]/g,(function(e,t){return'"'===t?"\\"+t:"\\"+(String.codePointAt?String.codePointAt(0):String.charCodeAt(0)).toString(16)+" "}))+'"'},s.fromToken=function(e){return new s(e.value,e.startLine,e.startCol,{ident:e.type===a.IDENT})}},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t,n,i,a){r.call(this,n,i,a,o.SELECTOR_PART_TYPE),this.elementName=e,this.modifiers=t}i.prototype=new r,i.prototype.constructor=i},function(e,t,n){"use strict";function r(e){this._input=e.replace(/(\r\n?|\n)/g,"\n"),this._line=1,this._col=1,this._cursor=0}e.exports=r,r.prototype={constructor:r,getCol:function(){return this._col},getLine:function(){return this._line},eof:function(){return this._cursor===this._input.length},peek:function(e){var t=null;return e=void 0===e?1:e,this._cursor<this._input.length&&(t=this._input.charAt(this._cursor+e-1)),t},read:function(){var e=null;return this._cursor<this._input.length&&("\n"===this._input.charAt(this._cursor)?(this._line++,this._col=1):this._col++,e=this._input.charAt(this._cursor++)),e},mark:function(){this._bookmark={cursor:this._cursor,line:this._line,col:this._col}},reset:function(){this._bookmark&&(this._cursor=this._bookmark.cursor,this._line=this._bookmark.line,this._col=this._bookmark.col,delete this._bookmark)},readTo:function(e){for(var t,n="";n.length<e.length||n.lastIndexOf(e)!==n.length-e.length;){if(!(t=this.read()))throw new Error('Expected "'+e+'" at line '+this._line+", col "+this._col+".");n+=t}return n},readWhile:function(e){for(var t="",n=this.peek();null!==n&&e(n);)t+=this.read(),n=this.peek();return t},readMatch:function(e){var t=this._input.substring(this._cursor),n=null;return"string"==typeof e?t.slice(0,e.length)===e&&(n=this.readCount(e.length)):e instanceof RegExp&&e.test(t)&&(n=this.readCount(RegExp.lastMatch.length)),n},readCount:function(e){for(var t="";e--;)t+=this.read();return t}}},function(e,t,n){"use strict";e.exports=i;var r=n(130),o=n(87);function i(e,t){this.match=function(t){var n;return t.mark(),(n=e(t))?t.drop():t.restore(),n},this.toString="function"==typeof t?t:function(){return t}}i.prec={MOD:5,SEQ:4,ANDAND:3,OROR:2,ALT:1},i.parse=function(e){var t,n,a,s,u,l,c,f,d;if(t=new r(e),n=function(e){var n=t.readMatch(e);if(null===n)throw new o("Expected "+e,t.getLine(),t.getCol());return n},a=function(){for(var e=[s()];null!==t.readMatch(" | ");)e.push(s());return 1===e.length?e[0]:i.alt.apply(i,e)},s=function(){for(var e=[u()];null!==t.readMatch(" || ");)e.push(u());return 1===e.length?e[0]:i.oror.apply(i,e)},u=function(){for(var e=[l()];null!==t.readMatch(" && ");)e.push(l());return 1===e.length?e[0]:i.andand.apply(i,e)},l=function(){for(var e=[c()];null!==t.readMatch(/^ (?![&|\]])/);)e.push(c());return 1===e.length?e[0]:i.seq.apply(i,e)},c=function(){var e=f();if(null!==t.readMatch("?"))return e.question();if(null!==t.readMatch("*"))return e.star();if(null!==t.readMatch("+"))return e.plus();if(null!==t.readMatch("#"))return e.hash();if(null!==t.readMatch(/^\{\s*/)){var r=n(/^\d+/);n(/^\s*,\s*/);var o=n(/^\d+/);return n(/^\s*\}/),e.braces(+r,+o)}return e},f=function(){if(null!==t.readMatch("[ ")){var e=a();return n(" ]"),e}return i.fromType(n(/^[^ ?*+#{]+/))},d=a(),!t.eof())throw new o("Expected end of string",t.getLine(),t.getCol());return d},i.cast=function(e){return e instanceof i?e:i.parse(e)},i.fromType=function(e){var t=n(132);return new i((function(n){return n.hasNext()&&t.isType(n,e)}),e)},i.seq=function(){var e=Array.prototype.slice.call(arguments).map(i.cast);return 1===e.length?e[0]:new i((function(t){var n,r=!0;for(n=0;r&&n<e.length;n++)r=e[n].match(t);return r}),(function(t){var n=i.prec.SEQ,r=e.map((function(e){return e.toString(n)})).join(" ");return t>n&&(r="[ "+r+" ]"),r}))},i.alt=function(){var e=Array.prototype.slice.call(arguments).map(i.cast);return 1===e.length?e[0]:new i((function(t){var n,r=!1;for(n=0;!r&&n<e.length;n++)r=e[n].match(t);return r}),(function(t){var n=i.prec.ALT,r=e.map((function(e){return e.toString(n)})).join(" | ");return t>n&&(r="[ "+r+" ]"),r}))},i.many=function(e){var t=Array.prototype.slice.call(arguments,1).reduce((function(e,t){if(t.expand){var r=n(132);e.push.apply(e,r.complex[t.expand].options)}else e.push(i.cast(t));return e}),[]);!0===e&&(e=t.map((function(){return!0})));var r=new i((function(n){var r=[],o=0,i=0,a=function(s){for(var u=0;u<t.length;u++)if(!r[u])if(n.mark(),t[u].match(n)){if(r[u]=!0,a(s+(!1===e||e[u]?1:0)))return n.drop(),!0;n.restore(),r[u]=!1}else n.drop();return function(e){return 0===i?(o=Math.max(e,o),e===t.length):e===o}(s)};if(a(0)||(i++,a(0)),!1===e)return o>0;for(var s=0;s<t.length;s++)if(e[s]&&!r[s])return!1;return!0}),(function(n){var r=!1===e?i.prec.OROR:i.prec.ANDAND,o=t.map((function(t,n){return!1===e||e[n]?t.toString(r):t.toString(i.prec.MOD)+"?"})).join(!1===e?" || ":" && ");return n>r&&(o="[ "+o+" ]"),o}));return r.options=t,r},i.andand=function(){var e=Array.prototype.slice.call(arguments);return e.unshift(!0),i.many.apply(i,e)},i.oror=function(){var e=Array.prototype.slice.call(arguments);return e.unshift(!1),i.many.apply(i,e)},i.prototype={constructor:i,match:function(){throw new Error("unimplemented")},toString:function(){throw new Error("unimplemented")},func:function(){return this.match.bind(this)},then:function(e){return i.seq(this,e)},or:function(e){return i.alt(this,e)},andand:function(e){return i.many(!0,this,e)},oror:function(e){return i.many(!1,this,e)},star:function(){return this.braces(0,1/0,"*")},plus:function(){return this.braces(1,1/0,"+")},question:function(){return this.braces(0,1,"?")},hash:function(){return this.braces(1,1/0,"#",i.cast(","))},braces:function(e,t,n,r){var o=this,a=r?r.then(this):this;return n||(n="{"+e+","+t+"}"),new i((function(n){var i;for(i=0;i<t&&(i>0&&r?a.match(n):o.match(n));i++);return i>=e}),(function(){return o.toString(i.prec.MOD)+n}))}}},function(e,t,n){"use strict";var r,o,i=e.exports,a=n(131);r=i,o={isLiteral:function(e,t){var n,r,o=e.text.toString().toLowerCase(),i=t.split(" | "),a=!1;for(n=0,r=i.length;n<r&&!a;n++)"<"===i[n].charAt(0)?a=this.simple[i[n]](e):"()"===i[n].slice(-2)?a="function"===e.type&&e.name===i[n].slice(0,-2):o===i[n].toLowerCase()&&(a=!0);return a},isSimple:function(e){return Boolean(this.simple[e])},isComplex:function(e){return Boolean(this.complex[e])},describe:function(e){return this.complex[e]instanceof a?this.complex[e].toString(0):e},isAny:function(e,t){var n,r,o=t.split(" | "),i=!1;for(n=0,r=o.length;n<r&&!i&&e.hasNext();n++)i=this.isType(e,o[n]);return i},isAnyOfGroup:function(e,t){var n,r,o=t.split(" || "),i=!1;for(n=0,r=o.length;n<r&&!i;n++)i=this.isType(e,o[n]);return!!i&&o[n-1]},isType:function(e,t){var n=e.peek(),r=!1;return"<"!==t.charAt(0)?(r=this.isLiteral(n,t))&&e.next():this.simple[t]?(r=this.simple[t](n))&&e.next():r=this.complex[t]instanceof a?this.complex[t].match(e):this.complex[t](e),r},simple:{__proto__:null,"<absolute-size>":"xx-small | x-small | small | medium | large | x-large | xx-large","<animateable-feature>":"scroll-position | contents | <animateable-feature-name>","<animateable-feature-name>":function(e){return this["<ident>"](e)&&!/^(unset|initial|inherit|will-change|auto|scroll-position|contents)$/i.test(e)},"<angle>":function(e){return"angle"===e.type},"<attachment>":"scroll | fixed | local","<attr>":"attr()","<basic-shape>":"inset() | circle() | ellipse() | polygon()","<bg-image>":"<image> | <gradient> | none","<border-style>":"none | hidden | dotted | dashed | solid | double | groove | ridge | inset | outset","<border-width>":"<length> | thin | medium | thick","<box>":"padding-box | border-box | content-box","<clip-source>":"<uri>","<color>":function(e){return"color"===e.type||"transparent"===String(e)||"currentColor"===String(e)},"<color-svg>":function(e){return"color"===e.type},"<content>":"content()","<content-sizing>":"fill-available | -moz-available | -webkit-fill-available | max-content | -moz-max-content | -webkit-max-content | min-content | -moz-min-content | -webkit-min-content | fit-content | -moz-fit-content | -webkit-fit-content","<feature-tag-value>":function(e){return"function"===e.type&&/^[A-Z0-9]{4}$/i.test(e)},"<filter-function>":"blur() | brightness() | contrast() | custom() | drop-shadow() | grayscale() | hue-rotate() | invert() | opacity() | saturate() | sepia()","<flex-basis>":"<width>","<flex-direction>":"row | row-reverse | column | column-reverse","<flex-grow>":"<number>","<flex-shrink>":"<number>","<flex-wrap>":"nowrap | wrap | wrap-reverse","<font-size>":"<absolute-size> | <relative-size> | <length> | <percentage>","<font-stretch>":"normal | ultra-condensed | extra-condensed | condensed | semi-condensed | semi-expanded | expanded | extra-expanded | ultra-expanded","<font-style>":"normal | italic | oblique","<font-variant-caps>":"small-caps | all-small-caps | petite-caps | all-petite-caps | unicase | titling-caps","<font-variant-css21>":"normal | small-caps","<font-weight>":"normal | bold | bolder | lighter | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900","<generic-family>":"serif | sans-serif | cursive | fantasy | monospace","<geometry-box>":"<shape-box> | fill-box | stroke-box | view-box","<glyph-angle>":function(e){return"angle"===e.type&&"deg"===e.units},"<gradient>":function(e){return"function"===e.type&&/^(?:\-(?:ms|moz|o|webkit)\-)?(?:repeating\-)?(?:radial\-|linear\-)?gradient/i.test(e)},"<icccolor>":"cielab() | cielch() | cielchab() | icc-color() | icc-named-color()","<ident>":function(e){return"identifier"===e.type||e.wasIdent},"<ident-not-generic-family>":function(e){return this["<ident>"](e)&&!this["<generic-family>"](e)},"<image>":"<uri>","<integer>":function(e){return"integer"===e.type},"<length>":function(e){return!("function"!==e.type||!/^(?:\-(?:ms|moz|o|webkit)\-)?calc/i.test(e))||"length"===e.type||"number"===e.type||"integer"===e.type||"0"===String(e)},"<line>":function(e){return"integer"===e.type},"<line-height>":"<number> | <length> | <percentage> | normal","<margin-width>":"<length> | <percentage> | auto","<miterlimit>":function(e){return this["<number>"](e)&&e.value>=1},"<nonnegative-length-or-percentage>":function(e){return(this["<length>"](e)||this["<percentage>"](e))&&("0"===String(e)||"function"===e.type||e.value>=0)},"<nonnegative-number-or-percentage>":function(e){return(this["<number>"](e)||this["<percentage>"](e))&&("0"===String(e)||"function"===e.type||e.value>=0)},"<number>":function(e){return"number"===e.type||this["<integer>"](e)},"<opacity-value>":function(e){return this["<number>"](e)&&e.value>=0&&e.value<=1},"<padding-width>":"<nonnegative-length-or-percentage>","<percentage>":function(e){return"percentage"===e.type||"0"===String(e)},"<relative-size>":"smaller | larger","<shape>":"rect() | inset-rect()","<shape-box>":"<box> | margin-box","<single-animation-direction>":"normal | reverse | alternate | alternate-reverse","<single-animation-name>":function(e){return this["<ident>"](e)&&/^-?[a-z_][-a-z0-9_]+$/i.test(e)&&!/^(none|unset|initial|inherit)$/i.test(e)},"<string>":function(e){return"string"===e.type},"<time>":function(e){return"time"===e.type},"<uri>":function(e){return"uri"===e.type},"<width>":"<margin-width>"},complex:{__proto__:null,"<azimuth>":"<angle> | [ [ left-side | far-left | left | center-left | center | center-right | right | far-right | right-side ] || behind ] | leftwards | rightwards","<bg-position>":"<position>#","<bg-size>":"[ <length> | <percentage> | auto ]{1,2} | cover | contain","<border-image-slice>":a.many([!0],a.cast("<nonnegative-number-or-percentage>"),a.cast("<nonnegative-number-or-percentage>"),a.cast("<nonnegative-number-or-percentage>"),a.cast("<nonnegative-number-or-percentage>"),"fill"),"<border-radius>":"<nonnegative-length-or-percentage>{1,4} [ / <nonnegative-length-or-percentage>{1,4} ]?","<box-shadow>":"none | <shadow>#","<clip-path>":"<basic-shape> || <geometry-box>","<dasharray>":a.cast("<nonnegative-length-or-percentage>").braces(1,1/0,"#",a.cast(",").question()),"<family-name>":"<string> | <ident-not-generic-family> <ident>*","<filter-function-list>":"[ <filter-function> | <uri> ]+","<flex>":"none | [ <flex-grow> <flex-shrink>? || <flex-basis> ]","<font-family>":"[ <generic-family> | <family-name> ]#","<font-shorthand>":"[ <font-style> || <font-variant-css21> || <font-weight> || <font-stretch> ]? <font-size> [ / <line-height> ]? <font-family>","<font-variant-alternates>":"stylistic() || historical-forms || styleset() || character-variant() || swash() || ornaments() || annotation()","<font-variant-ligatures>":"[ common-ligatures | no-common-ligatures ] || [ discretionary-ligatures | no-discretionary-ligatures ] || [ historical-ligatures | no-historical-ligatures ] || [ contextual | no-contextual ]","<font-variant-numeric>":"[ lining-nums | oldstyle-nums ] || [ proportional-nums | tabular-nums ] || [ diagonal-fractions | stacked-fractions ] || ordinal || slashed-zero","<font-variant-east-asian>":"[ jis78 | jis83 | jis90 | jis04 | simplified | traditional ] || [ full-width | proportional-width ] || ruby","<paint>":"<paint-basic> | <uri> <paint-basic>?","<paint-basic>":"none | currentColor | <color-svg> <icccolor>?","<position>":"[ center | [ left | right ] [ <percentage> | <length> ]? ] && [ center | [ top | bottom ] [ <percentage> | <length> ]? ] | [ left | center | right | <percentage> | <length> ] [ top | center | bottom | <percentage> | <length> ] | [ left | center | right | top | bottom | <percentage> | <length> ]","<repeat-style>":"repeat-x | repeat-y | [ repeat | space | round | no-repeat ]{1,2}","<shadow>":a.many([!0],a.cast("<length>").braces(2,4),"inset","<color>"),"<text-decoration-color>":"<color>","<text-decoration-line>":"none | [ underline || overline || line-through || blink ]","<text-decoration-style>":"solid | double | dotted | dashed | wavy","<will-change>":"auto | <animateable-feature>#","<x-one-radius>":"[ <length> | <percentage> ]{1,2}"}},Object.keys(o).forEach((function(e){r[e]=o[e]})),Object.keys(i.simple).forEach((function(e){var t=i.simple[e];"string"==typeof t&&(i.simple[e]=function(e){return i.isLiteral(e,t)})})),Object.keys(i.complex).forEach((function(e){var t=i.complex[e];"string"==typeof t&&(i.complex[e]=a.parse(t))})),i.complex["<font-variant>"]=a.oror({expand:"<font-variant-ligatures>"},{expand:"<font-variant-alternates>"},"<font-variant-caps>",{expand:"<font-variant-numeric>"},{expand:"<font-variant-east-asian>"})},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(81);e.exports=function(e){return e&&e.length?r(e):[]}},function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},n.apply(this,arguments)}e.exports=n},function(e,t,n){var r=n(262).default,o=n(133);e.exports=function(e,t){if(t&&("object"===r(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return o(e)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},e.exports.default=e.exports,e.exports.__esModule=!0,n(t)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){e.exports=n(269)},function(e,t,n){var r=n(112),o=n(336),i=n(109),a=n(23);e.exports=function(e,t){return(a(e)?r:o)(e,i(t,3))}},function(e,t,n){var r=n(150);e.exports=function(e,t,n){return(t=r(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(28),o=n(424),i=n(190),a=Math.max,s=Math.min;e.exports=function(e,t,n){var u,l,c,f,d,p,h=0,v=!1,g=!1,m=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function y(t){var n=u,r=l;return u=l=void 0,h=t,f=e.apply(r,n)}function b(e){return h=e,d=setTimeout(_,t),v?y(e):f}function w(e){var n=e-p;return void 0===p||n>=t||n<0||g&&e-h>=c}function _(){var e=o();if(w(e))return x(e);d=setTimeout(_,function(e){var n=t-(e-p);return g?s(n,c-(e-h)):n}(e))}function x(e){return d=void 0,m&&u?y(e):(u=l=void 0,f)}function k(){var e=o(),n=w(e);if(u=arguments,l=this,p=e,n){if(void 0===d)return b(p);if(g)return clearTimeout(d),d=setTimeout(_,t),y(p)}return void 0===d&&(d=setTimeout(_,t)),f}return t=i(t)||0,r(n)&&(v=!!n.leading,c=(g="maxWait"in n)?a(i(n.maxWait)||0,t):c,m="trailing"in n?!!n.trailing:m),k.cancel=function(){void 0!==d&&clearTimeout(d),h=0,u=p=l=d=void 0},k.flush=function(){return void 0===d?f:x(o())},k}},function(e,t,n){e.exports=n(229)()},function(e,t,n){(function(t){var n="object"==typeof t&&t&&t.Object===Object&&t;e.exports=n}).call(this,n(31))},function(e,t,n){var r=n(96);function o(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,o=t?t.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=e.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(o.Cache||r),n}o.Cache=r,e.exports=o},function(e,t){var n=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return n.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(146);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){var n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(n){var r=new Uint8Array(16);e.exports=function(){return n(r),r}}else{var o=new Array(16);e.exports=function(){for(var e,t=0;t<16;t++)0==(3&t)&&(e=4294967296*Math.random()),o[t]=e>>>((3&t)<<3)&255;return o}}},function(e,t){for(var n=[],r=0;r<256;++r)n[r]=(r+256).toString(16).substr(1);e.exports=function(e,t){var r=t||0,o=n;return[o[e[r++]],o[e[r++]],o[e[r++]],o[e[r++]],"-",o[e[r++]],o[e[r++]],"-",o[e[r++]],o[e[r++]],"-",o[e[r++]],o[e[r++]],"-",o[e[r++]],o[e[r++]],o[e[r++]],o[e[r++]],o[e[r++]],o[e[r++]]].join("")}},function(e,t,n){var r=n(73).default,o=n(272);e.exports=function(e){var t=o(e,"string");return"symbol"==r(t)?t:t+""},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){var n,r,o=e.exports={};function i(){throw new Error("setTimeout has not been defined")}function a(){throw new Error("clearTimeout has not been defined")}function s(e){if(n===setTimeout)return setTimeout(e,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(e,0);try{return n(e,0)}catch(t){try{return n.call(null,e,0)}catch(t){return n.call(this,e,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(e){n=i}try{r="function"==typeof clearTimeout?clearTimeout:a}catch(e){r=a}}();var u,l=[],c=!1,f=-1;function d(){c&&u&&(c=!1,u.length?l=u.concat(l):f=-1,l.length&&p())}function p(){if(!c){var e=s(d);c=!0;for(var t=l.length;t;){for(u=l,l=[];++f<t;)u&&u[f].run();f=-1,t=l.length}u=null,c=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===a||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function v(){}o.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];l.push(new h(e,t)),1!==l.length||c||s(p)},h.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=v,o.addListener=v,o.once=v,o.off=v,o.removeListener=v,o.removeAllListeners=v,o.emit=v,o.prependListener=v,o.prependOnceListener=v,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},function(e,t,n){"use strict";t.__esModule=!0,t.default={noWobble:{stiffness:170,damping:26},gentle:{stiffness:120,damping:14},wobbly:{stiffness:180,damping:12},stiff:{stiffness:210,damping:20}},e.exports=t.default},function(e,t,n){var r=n(154);e.exports=function(e,t,n){"__proto__"==t&&r?r(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}},function(e,t,n){var r=n(45),o=function(){try{var e=r(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();e.exports=o},function(e,t,n){var r=n(286),o=Math.max;e.exports=function(e,t,n){return t=o(void 0===t?e.length-1:t,0),function(){for(var i=arguments,a=-1,s=o(i.length-t,0),u=Array(s);++a<s;)u[a]=i[t+a];a=-1;for(var l=Array(t+1);++a<t;)l[a]=i[a];return l[t]=n(u),r(e,this,l)}}},function(e,t,n){var r=n(287),o=n(289)(r);e.exports=o},function(e,t,n){var r=n(59),o=n(38),i=n(60),a=n(28);e.exports=function(e,t,n){if(!a(n))return!1;var s=typeof t;return!!("number"==s?o(n)&&i(t,n.length):"string"==s&&t in n)&&r(n[t],e)}},function(e,t,n){var r=n(290),o=n(77),i=n(23),a=n(106),s=n(60),u=n(107),l=Object.prototype.hasOwnProperty;e.exports=function(e,t){var n=i(e),c=!n&&o(e),f=!n&&!c&&a(e),d=!n&&!c&&!f&&u(e),p=n||c||f||d,h=p?r(e.length,String):[],v=h.length;for(var g in e)!t&&!l.call(e,g)||p&&("length"==g||f&&("offset"==g||"parent"==g)||d&&("buffer"==g||"byteLength"==g||"byteOffset"==g)||s(g,v))||h.push(g);return h}},function(e,t,n){var r=n(76),o=n(295),i=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return o(e);var t=[];for(var n in Object(e))i.call(e,n)&&"constructor"!=n&&t.push(n);return t}},function(e,t){e.exports=function(e,t){return function(n){return e(t(n))}}},function(e,t,n){var r=n(70),o=n(298),i=n(299),a=n(300),s=n(301),u=n(302);function l(e){var t=this.__data__=new r(e);this.size=t.size}l.prototype.clear=o,l.prototype.delete=i,l.prototype.get=a,l.prototype.has=s,l.prototype.set=u,e.exports=l},function(e,t,n){var r=n(78),o=n(306),i=n(79);e.exports=function(e,t,n,a,s,u){var l=1&n,c=e.length,f=t.length;if(c!=f&&!(l&&f>c))return!1;var d=u.get(e),p=u.get(t);if(d&&p)return d==t&&p==e;var h=-1,v=!0,g=2&n?new r:void 0;for(u.set(e,t),u.set(t,e);++h<c;){var m=e[h],y=t[h];if(a)var b=l?a(y,m,h,t,e,u):a(m,y,h,e,t,u);if(void 0!==b){if(b)continue;v=!1;break}if(g){if(!o(t,(function(e,t){if(!i(g,t)&&(m===e||s(m,e,n,a,u)))return g.push(t)}))){v=!1;break}}else if(m!==y&&!s(m,y,n,a,u)){v=!1;break}}return u.delete(e),u.delete(t),v}},function(e,t){e.exports=function(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}},function(e,t,n){var r=n(315),o=n(98),i=n(316),a=n(165),s=n(166),u=n(39),l=n(145),c=l(r),f=l(o),d=l(i),p=l(a),h=l(s),v=u;(r&&"[object DataView]"!=v(new r(new ArrayBuffer(1)))||o&&"[object Map]"!=v(new o)||i&&"[object Promise]"!=v(i.resolve())||a&&"[object Set]"!=v(new a)||s&&"[object WeakMap]"!=v(new s))&&(v=function(e){var t=u(e),n="[object Object]"==t?e.constructor:void 0,r=n?l(n):"";if(r)switch(r){case c:return"[object DataView]";case f:return"[object Map]";case d:return"[object Promise]";case p:return"[object Set]";case h:return"[object WeakMap]"}return t}),e.exports=v},function(e,t,n){var r=n(45)(n(32),"Set");e.exports=r},function(e,t,n){var r=n(45)(n(32),"WeakMap");e.exports=r},function(e,t,n){var r=n(28);e.exports=function(e){return e==e&&!r(e)}},function(e,t){e.exports=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}},function(e,t,n){var r=n(67),o=n(77),i=n(23),a=n(60),s=n(105),u=n(50);e.exports=function(e,t,n){for(var l=-1,c=(t=r(t,e)).length,f=!1;++l<c;){var d=u(t[l]);if(!(f=null!=e&&n(e,d)))break;e=e[d]}return f||++l!=c?f:!!(c=null==e?0:e.length)&&s(c)&&a(d,c)&&(i(e)||o(e))}},function(e,t,n){var r=n(171);e.exports=function(e,t){if(e){if("string"==typeof e)return r(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?r(e,t):void 0}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.canDragX=function(e){return"both"===e.props.axis||"x"===e.props.axis},t.canDragY=function(e){return"both"===e.props.axis||"y"===e.props.axis},t.createCoreData=function(e,t,n){const o=!(0,r.isNum)(e.lastX),a=i(e);return o?{node:a,deltaX:0,deltaY:0,lastX:t,lastY:n,x:t,y:n}:{node:a,deltaX:t-e.lastX,deltaY:n-e.lastY,lastX:e.lastX,lastY:e.lastY,x:t,y:n}},t.createDraggableData=function(e,t){const n=e.props.scale;return{node:t.node,x:e.state.x+t.deltaX/n,y:e.state.y+t.deltaY/n,deltaX:t.deltaX/n,deltaY:t.deltaY/n,lastX:e.state.x,lastY:e.state.y}},t.getBoundPosition=function(e,t,n){if(!e.props.bounds)return[t,n];let{bounds:a}=e.props;a="string"==typeof a?a:function(e){return{left:e.left,top:e.top,right:e.right,bottom:e.bottom}}(a);const s=i(e);if("string"==typeof a){const{ownerDocument:e}=s,t=e.defaultView;let n;if(n="parent"===a?s.parentNode:e.querySelector(a),!(n instanceof t.HTMLElement))throw new Error('Bounds selector "'+a+'" could not find an element.');const i=n,u=t.getComputedStyle(s),l=t.getComputedStyle(i);a={left:-s.offsetLeft+(0,r.int)(l.paddingLeft)+(0,r.int)(u.marginLeft),top:-s.offsetTop+(0,r.int)(l.paddingTop)+(0,r.int)(u.marginTop),right:(0,o.innerWidth)(i)-(0,o.outerWidth)(s)-s.offsetLeft+(0,r.int)(l.paddingRight)-(0,r.int)(u.marginRight),bottom:(0,o.innerHeight)(i)-(0,o.outerHeight)(s)-s.offsetTop+(0,r.int)(l.paddingBottom)-(0,r.int)(u.marginBottom)}}(0,r.isNum)(a.right)&&(t=Math.min(t,a.right));(0,r.isNum)(a.bottom)&&(n=Math.min(n,a.bottom));(0,r.isNum)(a.left)&&(t=Math.max(t,a.left));(0,r.isNum)(a.top)&&(n=Math.max(n,a.top));return[t,n]},t.getControlPosition=function(e,t,n){const r="number"==typeof t?(0,o.getTouch)(e,t):null;if("number"==typeof t&&!r)return null;const a=i(n),s=n.props.offsetParent||a.offsetParent||a.ownerDocument.body;return(0,o.offsetXYFromParent)(r||e,s,n.props.scale)},t.snapToGrid=function(e,t,n){const r=Math.round(t/e[0])*e[0],o=Math.round(n/e[1])*e[1];return[r,o]};var r=n(80),o=n(114);function i(e){const t=e.findDOMNode();if(!t)throw new Error("<DraggableCore>: Unmounted during event!");return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){void 0}},function(e,t,n){var r=n(337),o=n(338),i=n(339);e.exports=function(e,t,n){return t==t?i(e,t,n):r(e,o,n)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(117);t.DragDropContext=r.DragDropContext,t.DragDropContextProvider=r.DragDropContextProvider;var o=n(366);t.DragLayer=o.default;var i=n(368);t.DragSource=i.default;var a=n(378);t.DropTarget=a.default},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){e.SOURCE="SOURCE",e.TARGET="TARGET"}(t.HandlerRole||(t.HandlerRole={}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){return null===t?null===e:Array.isArray(e)?e.some((function(e){return e===t})):e===t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.strictEquality=function(e,t){return e===t},t.areCoordsEqual=function(e,t){return!e&&!t||!(!e||!t)&&(e.x===t.x&&e.y===t.y)},t.areArraysEqual=function(e,n,r){if(void 0===r&&(r=t.strictEquality),e.length!==n.length)return!1;for(var o=0;o<e.length;++o)if(!r(e[o],n[o]))return!1;return!0}},function(e,t,n){var r=n(180),o=n(51),i=n(84),a=o((function(e,t){return i(e)?r(e,t):[]}));e.exports=a},function(e,t,n){var r=n(78),o=n(115),i=n(116),a=n(49),s=n(108),u=n(79);e.exports=function(e,t,n,l){var c=-1,f=o,d=!0,p=e.length,h=[],v=t.length;if(!p)return h;n&&(t=a(t,s(n))),l?(f=i,d=!1):t.length>=200&&(f=u,d=!1,t=new r(t));e:for(;++c<p;){var g=e[c],m=null==n?g:n(g);if(g=l||0!==g?g:0,d&&m==m){for(var y=v;y--;)if(t[y]===m)continue e;h.push(g)}else f(t,m,l)||h.push(g)}return h}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(352);t.NONE=[],t.ALL=[],t.areDirty=function(e,n){return e!==t.NONE&&(e===t.ALL||void 0===n||r(n,e).length>0)}},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),s=n(117),u=n(369),l=n(120).default,c=(n(52),n(26)),f=n(119),d=n(61);t.default=function(e){var t=e.DecoratedComponent,n=e.createHandler,r=e.createMonitor,p=e.createConnector,h=e.registerHandler,v=e.containerDisplayName,g=e.getType,m=e.collect,y=e.options.arePropsEqual,b=void 0===y?d:y,w=t,_=t.displayName||t.name||"Component",x=function(e){function f(t){var n=e.call(this,t)||this;return n.isCurrentlyMounted=!1,n.handleChange=n.handleChange.bind(n),n.disposable=new u.SerialDisposable,n.receiveProps(t),n.dispose(),n}return o(f,e),f.prototype.getHandlerId=function(){return this.handlerId},f.prototype.getDecoratedComponentInstance=function(){return this.handler?this.handler.ref.current:null},f.prototype.shouldComponentUpdate=function(e,t){return!b(e,this.props)||!d(t,this.state)},f.prototype.componentDidMount=function(){this.isCurrentlyMounted=!0,this.disposable=new u.SerialDisposable,this.currentType=void 0,this.receiveProps(this.props),this.handleChange()},f.prototype.componentDidUpdate=function(e){b(this.props,e)||(this.receiveProps(this.props),this.handleChange())},f.prototype.componentWillUnmount=function(){this.dispose(),this.isCurrentlyMounted=!1},f.prototype.receiveProps=function(e){this.handler&&(this.handler.receiveProps(e),this.receiveType(g(e)))},f.prototype.receiveType=function(e){if(this.handlerMonitor&&this.manager&&this.handlerConnector&&e!==this.currentType){this.currentType=e;var t=h(e,this.handler,this.manager),n=t.handlerId,r=t.unregister;this.handlerId=n,this.handlerMonitor.receiveHandlerId(n),this.handlerConnector.receiveHandlerId(n);var o=this.manager.getMonitor().subscribeToStateChange(this.handleChange,{handlerIds:[n]});this.disposable.setDisposable(new u.CompositeDisposable(new u.Disposable(o),new u.Disposable(r)))}},f.prototype.handleChange=function(){if(this.isCurrentlyMounted){var e=this.getCurrentState();d(e,this.state)||this.setState(e)}},f.prototype.dispose=function(){this.disposable.dispose(),this.handlerConnector&&this.handlerConnector.receiveHandlerId(null)},f.prototype.getCurrentState=function(){return this.handlerConnector?m(this.handlerConnector.hooks,this.handlerMonitor):{}},f.prototype.render=function(){var e=this;return a.createElement(s.Consumer,null,(function(t){var n=t.dragDropManager;return void 0===n?null:(e.receiveDragDropManager(n),e.isCurrentlyMounted?a.createElement(w,i({},e.props,e.state,{ref:e.handler&&l(w)?e.handler.ref:void 0})):null)}))},f.prototype.receiveDragDropManager=function(e){void 0===this.manager&&(this.manager=e,c("object"==typeof e,"Could not find the drag and drop manager in the context of %s. Make sure to wrap the top-level component of your app with DragDropContext. Read more: http://react-dnd.github.io/react-dnd/docs-troubleshooting.html#could-not-find-the-drag-and-drop-manager-in-the-context",_,_),this.handlerMonitor=r(e),this.handlerConnector=p(e.getBackend()),this.handler=n(this.handlerMonitor))},f.DecoratedComponent=t,f.displayName=v+"("+_+")",f}(a.Component);return f(x,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),o=n(377);function i(e){return function(t,n){if(void 0===t&&(t=null),void 0===n&&(n=null),r.isValidElement(t)){var i=t;!function(e){if("string"!=typeof e.type){var t=e.type.displayName||e.type.name||"the component";throw new Error("Only native element nodes can now be passed to React DnD connectors.You can either wrap "+t+" into a <div>, or turn it into a drag source or a drop target itself.")}}(i);var a=n?function(t){return e(t,n)}:e;return o.default(i,a)}e(t,n)}}t.default=function(e){var t={};return Object.keys(e).forEach((function(n){var r=i(e[n]);t[n]=function(){return r}})),t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function e(t,n){return"string"==typeof t||"symbol"==typeof t||!!n&&Array.isArray(t)&&t.every((function(t){return e(t,!1)}))}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(144);t.isFirefox=r((function(){return/firefox/i.test(navigator.userAgent)})),t.isSafari=r((function(){return Boolean(window.safari)}))},function(e,t,n){!function(){"use strict";var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var o=arguments[r];if(o){var i=typeof o;if("string"===i||"number"===i)e.push(o);else if(Array.isArray(o)&&o.length){var a=n.apply(null,o);a&&e.push(a)}else if("object"===i)for(var s in o)t.call(o,s)&&o[s]&&e.push(s)}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"==typeof define.amd&&define.amd?define("classnames",[],(function(){return n})):window.classNames=n}()},function(e,t,n){var r=n(28),o=Object.create,i=function(){function e(){}return function(t){if(!r(t))return{};if(o)return o(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();e.exports=i},function(e,t,n){var r=n(407),o=n(40),i=r?function(e){return r.get(e)}:o;e.exports=i},function(e,t,n){var r=n(408),o=Object.prototype.hasOwnProperty;e.exports=function(e){for(var t=e.name+"",n=r[t],i=o.call(r,t)?n.length:0;i--;){var a=n[i],s=a.func;if(null==s||s==e)return a.name}return t}},function(e,t,n){var r=n(420),o=n(28),i=n(68),a=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,u=/^0o[0-7]+$/i,l=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(i(e))return NaN;if(o(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=o(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=r(e);var n=s.test(e);return n||u.test(e)?l(e.slice(2),n?2:8):a.test(e)?NaN:+e}},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){var t=/MSIE \d/.test(navigator.userAgent)&&(null==document.documentMode||document.documentMode<8),n=e.Pos,r={"(":")>",")":"(<","[":"]>","]":"[<","{":"}>","}":"{<","<":">>",">":"<<"};function o(e){return e&&e.bracketRegex||/[(){}[\]]/}function i(e,t,i){var s=e.getLineHandle(t.line),u=t.ch-1,l=i&&i.afterCursor;null==l&&(l=/(^| )cm-fat-cursor($| )/.test(e.getWrapperElement().className));var c=o(i),f=!l&&u>=0&&c.test(s.text.charAt(u))&&r[s.text.charAt(u)]||c.test(s.text.charAt(u+1))&&r[s.text.charAt(++u)];if(!f)return null;var d=">"==f.charAt(1)?1:-1;if(i&&i.strict&&d>0!=(u==t.ch))return null;var p=e.getTokenTypeAt(n(t.line,u+1)),h=a(e,n(t.line,u+(d>0?1:0)),d,p,i);return null==h?null:{from:n(t.line,u),to:h&&h.pos,match:h&&h.ch==f.charAt(0),forward:d>0}}function a(e,t,i,a,s){for(var u=s&&s.maxScanLineLength||1e4,l=s&&s.maxScanLines||1e3,c=[],f=o(s),d=i>0?Math.min(t.line+l,e.lastLine()+1):Math.max(e.firstLine()-1,t.line-l),p=t.line;p!=d;p+=i){var h=e.getLine(p);if(h){var v=i>0?0:h.length-1,g=i>0?h.length:-1;if(!(h.length>u))for(p==t.line&&(v=t.ch-(i<0?1:0));v!=g;v+=i){var m=h.charAt(v);if(f.test(m)&&(void 0===a||(e.getTokenTypeAt(n(p,v+1))||"")==(a||""))){var y=r[m];if(y&&">"==y.charAt(1)==i>0)c.push(m);else{if(!c.length)return{pos:n(p,v),ch:m};c.pop()}}}}}return p-i!=(i>0?e.lastLine():e.firstLine())&&null}function s(e,r,o){for(var a=e.state.matchBrackets.maxHighlightLineLength||1e3,s=o&&o.highlightNonMatching,u=[],l=e.listSelections(),c=0;c<l.length;c++){var f=l[c].empty()&&i(e,l[c].head,o);if(f&&(f.match||!1!==s)&&e.getLine(f.from.line).length<=a){var d=f.match?"CodeMirror-matchingbracket":"CodeMirror-nonmatchingbracket";u.push(e.markText(f.from,n(f.from.line,f.from.ch+1),{className:d})),f.to&&e.getLine(f.to.line).length<=a&&u.push(e.markText(f.to,n(f.to.line,f.to.ch+1),{className:d}))}}if(u.length){t&&e.state.focused&&e.focus();var p=function(){e.operation((function(){for(var e=0;e<u.length;e++)u[e].clear()}))};if(!r)return p;setTimeout(p,800)}}function u(e){e.operation((function(){e.state.matchBrackets.currentlyHighlighted&&(e.state.matchBrackets.currentlyHighlighted(),e.state.matchBrackets.currentlyHighlighted=null),e.state.matchBrackets.currentlyHighlighted=s(e,!1,e.state.matchBrackets)}))}function l(e){e.state.matchBrackets&&e.state.matchBrackets.currentlyHighlighted&&(e.state.matchBrackets.currentlyHighlighted(),e.state.matchBrackets.currentlyHighlighted=null)}e.defineOption("matchBrackets",!1,(function(t,n,r){r&&r!=e.Init&&(t.off("cursorActivity",u),t.off("focus",u),t.off("blur",l),l(t)),n&&(t.state.matchBrackets="object"==typeof n?n:{},t.on("cursorActivity",u),t.on("focus",u),t.on("blur",l))})),e.defineExtension("matchBrackets",(function(){s(this,!0)})),e.defineExtension("findMatchingBracket",(function(e,t,n){return(n||"boolean"==typeof t)&&(n?(n.strict=t,t=n):t=t?{strict:!0}:null),i(this,e,t)})),e.defineExtension("scanForBracket",(function(e,t,n,r){return a(this,e,t,n,r)}))}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t=e.Pos;function n(e,t){return e.line-t.line||e.ch-t.ch}var r="A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",o=new RegExp("<(/?)(["+r+"]["+r+"-:.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*)","g");function i(e,t,n,r){this.line=t,this.ch=n,this.cm=e,this.text=e.getLine(t),this.min=r?Math.max(r.from,e.firstLine()):e.firstLine(),this.max=r?Math.min(r.to-1,e.lastLine()):e.lastLine()}function a(e,n){var r=e.cm.getTokenTypeAt(t(e.line,n));return r&&/\btag\b/.test(r)}function s(e){if(!(e.line>=e.max))return e.ch=0,e.text=e.cm.getLine(++e.line),!0}function u(e){if(!(e.line<=e.min))return e.text=e.cm.getLine(--e.line),e.ch=e.text.length,!0}function l(e){for(;;){var t=e.text.indexOf(">",e.ch);if(-1==t){if(s(e))continue;return}if(a(e,t+1)){var n=e.text.lastIndexOf("/",t),r=n>-1&&!/\S/.test(e.text.slice(n+1,t));return e.ch=t+1,r?"selfClose":"regular"}e.ch=t+1}}function c(e){for(;;){var t=e.ch?e.text.lastIndexOf("<",e.ch-1):-1;if(-1==t){if(u(e))continue;return}if(a(e,t+1)){o.lastIndex=t,e.ch=t;var n=o.exec(e.text);if(n&&n.index==t)return n}else e.ch=t}}function f(e){for(;;){o.lastIndex=e.ch;var t=o.exec(e.text);if(!t){if(s(e))continue;return}if(a(e,t.index+1))return e.ch=t.index+t[0].length,t;e.ch=t.index+1}}function d(e){for(;;){var t=e.ch?e.text.lastIndexOf(">",e.ch-1):-1;if(-1==t){if(u(e))continue;return}if(a(e,t+1)){var n=e.text.lastIndexOf("/",t),r=n>-1&&!/\S/.test(e.text.slice(n+1,t));return e.ch=t+1,r?"selfClose":"regular"}e.ch=t}}function p(e,n){for(var r=[];;){var o,i=f(e),a=e.line,s=e.ch-(i?i[0].length:0);if(!i||!(o=l(e)))return;if("selfClose"!=o)if(i[1]){for(var u=r.length-1;u>=0;--u)if(r[u]==i[2]){r.length=u;break}if(u<0&&(!n||n==i[2]))return{tag:i[2],from:t(a,s),to:t(e.line,e.ch)}}else r.push(i[2])}}function h(e,n){for(var r=[];;){var o=d(e);if(!o)return;if("selfClose"!=o){var i=e.line,a=e.ch,s=c(e);if(!s)return;if(s[1])r.push(s[2]);else{for(var u=r.length-1;u>=0;--u)if(r[u]==s[2]){r.length=u;break}if(u<0&&(!n||n==s[2]))return{tag:s[2],from:t(e.line,e.ch),to:t(i,a)}}}else c(e)}}e.registerHelper("fold","xml",(function(e,r){for(var o=new i(e,r.line,0);;){var a=f(o);if(!a||o.line!=r.line)return;var s=l(o);if(!s)return;if(!a[1]&&"selfClose"!=s){var u=t(o.line,o.ch),c=p(o,a[2]);return c&&n(c.from,u)>0?{from:u,to:c.from}:null}}})),e.findMatchingTag=function(e,r,o){var a=new i(e,r.line,r.ch,o);if(-1!=a.text.indexOf(">")||-1!=a.text.indexOf("<")){var s=l(a),u=s&&t(a.line,a.ch),f=s&&c(a);if(s&&f&&!(n(a,r)>0)){var d={from:t(a.line,a.ch),to:u,tag:f[2]};return"selfClose"==s?{open:d,close:null,at:"open"}:f[1]?{open:h(a,f[2]),close:d,at:"close"}:{open:d,close:p(a=new i(e,u.line,u.ch,o),f[2]),at:"open"}}}},e.findEnclosingTag=function(e,t,n,r){for(var o=new i(e,t.line,t.ch,n);;){var a=h(o,r);if(!a)break;var s=p(new i(e,t.line,t.ch,n),a.tag);if(s)return{open:a,close:s}}},e.scanForClosingTag=function(e,t,n,r){return p(new i(e,t.line,t.ch,r?{from:0,to:r}:null),n)}}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){function t(t,n,r){var o,i=t.getWrapperElement();return(o=i.appendChild(document.createElement("div"))).className=r?"CodeMirror-dialog CodeMirror-dialog-bottom":"CodeMirror-dialog CodeMirror-dialog-top","string"==typeof n?o.innerHTML=n:o.appendChild(n),e.addClass(i,"dialog-opened"),o}function n(e,t){e.state.currentNotificationClose&&e.state.currentNotificationClose(),e.state.currentNotificationClose=t}e.defineExtension("openDialog",(function(r,o,i){i||(i={}),n(this,null);var a=t(this,r,i.bottom),s=!1,u=this;function l(t){if("string"==typeof t)f.value=t;else{if(s)return;s=!0,e.rmClass(a.parentNode,"dialog-opened"),a.parentNode.removeChild(a),u.focus(),i.onClose&&i.onClose(a)}}var c,f=a.getElementsByTagName("input")[0];return f?(f.focus(),i.value&&(f.value=i.value,!1!==i.selectValueOnOpen&&f.select()),i.onInput&&e.on(f,"input",(function(e){i.onInput(e,f.value,l)})),i.onKeyUp&&e.on(f,"keyup",(function(e){i.onKeyUp(e,f.value,l)})),e.on(f,"keydown",(function(t){i&&i.onKeyDown&&i.onKeyDown(t,f.value,l)||((27==t.keyCode||!1!==i.closeOnEnter&&13==t.keyCode)&&(f.blur(),e.e_stop(t),l()),13==t.keyCode&&o(f.value,t))})),!1!==i.closeOnBlur&&e.on(a,"focusout",(function(e){null!==e.relatedTarget&&l()}))):(c=a.getElementsByTagName("button")[0])&&(e.on(c,"click",(function(){l(),u.focus()})),!1!==i.closeOnBlur&&e.on(c,"blur",l),c.focus()),l})),e.defineExtension("openConfirm",(function(r,o,i){n(this,null);var a=t(this,r,i&&i.bottom),s=a.getElementsByTagName("button"),u=!1,l=this,c=1;function f(){u||(u=!0,e.rmClass(a.parentNode,"dialog-opened"),a.parentNode.removeChild(a),l.focus())}s[0].focus();for(var d=0;d<s.length;++d){var p=s[d];!function(t){e.on(p,"click",(function(n){e.e_preventDefault(n),f(),t&&t(l)}))}(o[d]),e.on(p,"blur",(function(){--c,setTimeout((function(){c<=0&&f()}),200)})),e.on(p,"focus",(function(){++c}))}})),e.defineExtension("openNotification",(function(r,o){n(this,l);var i,a=t(this,r,o&&o.bottom),s=!1,u=o&&void 0!==o.duration?o.duration:5e3;function l(){s||(s=!0,clearTimeout(i),e.rmClass(a.parentNode,"dialog-opened"),a.parentNode.removeChild(a))}return e.on(a,"click",(function(t){e.e_preventDefault(t),l()})),u&&(i=setTimeout(l,u)),l}))}(n(21))},function(e,t,n){"use strict";e.exports={__proto__:null,aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgrey:"#a9a9a9",darkgreen:"#006400",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",grey:"#808080",green:"#008000",greenyellow:"#adff2f",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgrey:"#d3d3d3",lightgreen:"#90ee90",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370d8",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#d87093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32",currentColor:"The value of the 'color' property.",activeBorder:"Active window border.",activecaption:"Active window caption.",appworkspace:"Background color of multiple document interface.",background:"Desktop background.",buttonface:"The face background color for 3-D elements that appear 3-D due to one layer of surrounding border.",buttonhighlight:"The color of the border facing the light source for 3-D elements that appear 3-D due to one layer of surrounding border.",buttonshadow:"The color of the border away from the light source for 3-D elements that appear 3-D due to one layer of surrounding border.",buttontext:"Text on push buttons.",captiontext:"Text in caption, size box, and scrollbar arrow box.",graytext:"Grayed (disabled) text. This color is set to #000 if the current display driver does not support a solid gray color.",greytext:"Greyed (disabled) text. This color is set to #000 if the current display driver does not support a solid grey color.",highlight:"Item(s) selected in a control.",highlighttext:"Text of item(s) selected in a control.",inactiveborder:"Inactive window border.",inactivecaption:"Inactive window caption.",inactivecaptiontext:"Color of text in an inactive caption.",infobackground:"Background color for tooltip controls.",infotext:"Text color for tooltip controls.",menu:"Menu background.",menutext:"Text in menus.",scrollbar:"Scroll bar gray area.",threeddarkshadow:"The color of the darker (generally outer) of the two borders away from the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",threedface:"The face background color for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",threedhighlight:"The color of the lighter (generally outer) of the two borders facing the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",threedlightshadow:"The color of the darker (generally inner) of the two borders facing the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",threedshadow:"The color of the lighter (generally inner) of the two borders away from the light source for 3-D elements that appear 3-D due to two concentric layers of surrounding border.",window:"Window background.",windowframe:"Window frame.",windowtext:"Text in windows."}},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t,n){r.call(this,e,t,n,o.COMBINATOR_TYPE),this.type="unknown",/^\s+$/.test(e)?this.type="descendant":">"===e?this.type="child":"+"===e?this.type="adjacent-sibling":"~"===e&&(this.type="sibling")}i.prototype=new r,i.prototype.constructor=i},function(e,t,n){"use strict";function r(){this._listeners=Object.create(null)}e.exports=r,r.prototype={constructor:r,addListener:function(e,t){this._listeners[e]||(this._listeners[e]=[]),this._listeners[e].push(t)},fire:function(e){if("string"==typeof e&&(e={type:e}),void 0!==e.target&&(e.target=this),void 0===e.type)throw new Error("Event object missing 'type' property.");if(this._listeners[e.type])for(var t=this._listeners[e.type].concat(),n=0,r=t.length;n<r;n++)t[n].call(this,e)},removeListener:function(e,t){if(this._listeners[e])for(var n=this._listeners[e],r=0,o=n.length;r<o;r++)if(n[r]===t){n.splice(r,1);break}}}},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t){r.call(this,"("+e+(null!==t?":"+t:"")+")",e.startLine,e.startCol,o.MEDIA_FEATURE_TYPE),this.name=e,this.value=t}i.prototype=new r,i.prototype.constructor=i},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t,n,i,a){r.call(this,(e?e+" ":"")+(t||"")+(t&&n.length>0?" and ":"")+n.join(" and "),i,a,o.MEDIA_QUERY_TYPE),this.modifier=e,this.mediaType=t,this.features=n}i.prototype=new r,i.prototype.constructor=i},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t,n,i){r.call(this,e,n,i,o.PROPERTY_NAME_TYPE),this.hack=t}i.prototype=new r,i.prototype.constructor=i,i.prototype.toString=function(){return(this.hack?this.hack:"")+this.text}},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t,n){r.call(this,e.join(" "),t,n,o.PROPERTY_VALUE_TYPE),this.parts=e}i.prototype=new r,i.prototype.constructor=i},function(e,t,n){"use strict";e.exports=a;var r=n(30),o=n(34),i=n(202);function a(e,t,n){r.call(this,e.join(" "),t,n,o.SELECTOR_TYPE),this.parts=e,this.specificity=i.calculate(this)}a.prototype=new r,a.prototype.constructor=a},function(e,t,n){"use strict";e.exports=i;var r=n(456),o=n(129);function i(e,t,n,r){this.a=e,this.b=t,this.c=n,this.d=r}i.prototype={constructor:i,compare:function(e){var t,n,r=["a","b","c","d"];for(t=0,n=r.length;t<n;t++){if(this[r[t]]<e[r[t]])return-1;if(this[r[t]]>e[r[t]])return 1}return 0},valueOf:function(){return 1e3*this.a+100*this.b+10*this.c+this.d},toString:function(){return this.a+","+this.b+","+this.c+","+this.d}},i.calculate=function(e){var t,n,a,s=0,u=0,l=0;function c(e){var t,n,o,i,a,f=e.elementName?e.elementName.text:"";for(f&&"*"!==f.charAt(f.length-1)&&l++,t=0,o=e.modifiers.length;t<o;t++)switch((a=e.modifiers[t]).type){case"class":case"attribute":u++;break;case"id":s++;break;case"pseudo":r.isElement(a.text)?l++:u++;break;case"not":for(n=0,i=a.args.length;n<i;n++)c(a.args[n])}}for(t=0,n=e.parts.length;t<n;t++)(a=e.parts[t])instanceof o&&c(a);return new i(0,s,u,l)}},function(e,t,n){"use strict";e.exports=i;var r=n(30),o=n(34);function i(e,t,n,i){r.call(this,e,n,i,o.SELECTOR_SUB_PART_TYPE),this.type=t,this.args=[]}i.prototype=new r,i.prototype.constructor=i},function(e,t,n){"use strict";e.exports=m;var r=n(205),o=n(128),i=n(88),a=/^[0-9a-fA-F]$/,s=/^[\u00A0-\uFFFF]$/,u=/\n|\r\n|\r|\f/,l=/\u0009|\u000a|\u000c|\u000d|\u0020/;function c(e){return null!==e&&a.test(e)}function f(e){return null!==e&&/\d/.test(e)}function d(e){return null!==e&&l.test(e)}function p(e){return null!==e&&u.test(e)}function h(e){return null!==e&&/[a-z_\u00A0-\uFFFF\\]/i.test(e)}function v(e){return null!==e&&(h(e)||/[0-9\-\\]/.test(e))}function g(e){return null!==e&&(h(e)||/\-\\/.test(e))}function m(e){r.call(this,e,i)}m.prototype=function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}(new r,{_getToken:function(){var e,t=this._reader,n=null,r=t.getLine(),o=t.getCol();for(e=t.read();e;){switch(e){case"/":n="*"===t.peek()?this.commentToken(e,r,o):this.charToken(e,r,o);break;case"|":case"~":case"^":case"$":case"*":n="="===t.peek()?this.comparisonToken(e,r,o):this.charToken(e,r,o);break;case'"':case"'":n=this.stringToken(e,r,o);break;case"#":n=v(t.peek())?this.hashToken(e,r,o):this.charToken(e,r,o);break;case".":n=f(t.peek())?this.numberToken(e,r,o):this.charToken(e,r,o);break;case"-":n="-"===t.peek()?this.htmlCommentEndToken(e,r,o):h(t.peek())?this.identOrFunctionToken(e,r,o):this.charToken(e,r,o);break;case"!":n=this.importantToken(e,r,o);break;case"@":n=this.atRuleToken(e,r,o);break;case":":n=this.notToken(e,r,o);break;case"<":n=this.htmlCommentStartToken(e,r,o);break;case"\\":n=/[^\r\n\f]/.test(t.peek())?this.identOrFunctionToken(this.readEscape(e,!0),r,o):this.charToken(e,r,o);break;case"U":case"u":if("+"===t.peek()){n=this.unicodeRangeToken(e,r,o);break}default:n=f(e)?this.numberToken(e,r,o):d(e)?this.whitespaceToken(e,r,o):g(e)?this.identOrFunctionToken(e,r,o):this.charToken(e,r,o)}break}return n||null!==e||(n=this.createToken(i.EOF,null,r,o)),n},createToken:function(e,t,n,r,o){var i=this._reader;return{value:t,type:e,channel:(o=o||{}).channel,endChar:o.endChar,hide:o.hide||!1,startLine:n,startCol:r,endLine:i.getLine(),endCol:i.getCol()}},atRuleToken:function(e,t,n){var r=e,o=this._reader,a=i.CHAR;return o.mark(),r=e+this.readName(),(a=i.type(r.toLowerCase()))!==i.CHAR&&a!==i.UNKNOWN||(r.length>1?a=i.UNKNOWN_SYM:(a=i.CHAR,r=e,o.reset())),this.createToken(a,r,t,n)},charToken:function(e,t,n){var r=i.type(e),o={};return-1===r?r=i.CHAR:o.endChar=i[r].endChar,this.createToken(r,e,t,n,o)},commentToken:function(e,t,n){var r=this.readComment(e);return this.createToken(i.COMMENT,r,t,n)},comparisonToken:function(e,t,n){var r=e+this._reader.read(),o=i.type(r)||i.CHAR;return this.createToken(o,r,t,n)},hashToken:function(e,t,n){var r=this.readName(e);return this.createToken(i.HASH,r,t,n)},htmlCommentStartToken:function(e,t,n){var r=this._reader,o=e;return r.mark(),"\x3c!--"===(o+=r.readCount(3))?this.createToken(i.CDO,o,t,n):(r.reset(),this.charToken(e,t,n))},htmlCommentEndToken:function(e,t,n){var r=this._reader,o=e;return r.mark(),"--\x3e"===(o+=r.readCount(2))?this.createToken(i.CDC,o,t,n):(r.reset(),this.charToken(e,t,n))},identOrFunctionToken:function(e,t,n){var r,o=this._reader,a=this.readName(e),s=i.IDENT;return"("===o.peek()?(a+=o.read(),["url(","url-prefix(","domain("].indexOf(a.toLowerCase())>-1?(o.mark(),null===(r=this.readURI(a))?(o.reset(),s=i.FUNCTION):(s=i.URI,a=r)):s=i.FUNCTION):":"===o.peek()&&"progid"===a.toLowerCase()&&(a+=o.readTo("("),s=i.IE_FUNCTION),this.createToken(s,a,t,n)},importantToken:function(e,t,n){var r,o,a=this._reader,s=e,u=i.CHAR;for(a.mark(),o=a.read();o;){if("/"===o){if("*"!==a.peek())break;if(""===(r=this.readComment(o)))break}else{if(!d(o)){if(/i/i.test(o)){r=a.readCount(8),/mportant/i.test(r)&&(s+=o+r,u=i.IMPORTANT_SYM);break}break}s+=o+this.readWhitespace()}o=a.read()}return u===i.CHAR?(a.reset(),this.charToken(e,t,n)):this.createToken(u,s,t,n)},notToken:function(e,t,n){var r=this._reader,o=e;return r.mark(),":not("===(o+=r.readCount(4)).toLowerCase()?this.createToken(i.NOT,o,t,n):(r.reset(),this.charToken(e,t,n))},numberToken:function(e,t,n){var r,o=this._reader,a=this.readNumber(e),s=i.NUMBER,u=o.peek();return g(u)?(a+=r=this.readName(o.read()),s=/^em$|^ex$|^px$|^gd$|^rem$|^vw$|^vh$|^vmax$|^vmin$|^ch$|^cm$|^mm$|^in$|^pt$|^pc$/i.test(r)?i.LENGTH:/^deg|^rad$|^grad$|^turn$/i.test(r)?i.ANGLE:/^ms$|^s$/i.test(r)?i.TIME:/^hz$|^khz$/i.test(r)?i.FREQ:/^dpi$|^dpcm$/i.test(r)?i.RESOLUTION:i.DIMENSION):"%"===u&&(a+=o.read(),s=i.PERCENTAGE),this.createToken(s,a,t,n)},stringToken:function(e,t,n){for(var r,o=e,a=e,s=this._reader,u=i.STRING,l=s.read();l;){if(a+=l,"\\"===l){if(null===(l=s.read()))break;if(/[^\r\n\f0-9a-f]/i.test(l))a+=l;else{for(r=0;c(l)&&r<6;r++)a+=l,l=s.read();if("\r"===l&&"\n"===s.peek()&&(a+=l,l=s.read()),!d(l))continue;a+=l}}else{if(l===o)break;if(p(s.peek())){u=i.INVALID;break}}l=s.read()}return null===l&&(u=i.INVALID),this.createToken(u,a,t,n)},unicodeRangeToken:function(e,t,n){var r,o=this._reader,a=e,s=i.CHAR;return"+"===o.peek()&&(o.mark(),a+=o.read(),2===(a+=this.readUnicodeRangePart(!0)).length?o.reset():(s=i.UNICODE_RANGE,-1===a.indexOf("?")&&"-"===o.peek()&&(o.mark(),r=o.read(),1===(r+=this.readUnicodeRangePart(!1)).length?o.reset():a+=r))),this.createToken(s,a,t,n)},whitespaceToken:function(e,t,n){var r=e+this.readWhitespace();return this.createToken(i.S,r,t,n)},readUnicodeRangePart:function(e){for(var t=this._reader,n="",r=t.peek();c(r)&&n.length<6;)t.read(),n+=r,r=t.peek();if(e)for(;"?"===r&&n.length<6;)t.read(),n+=r,r=t.peek();return n},readWhitespace:function(){for(var e=this._reader,t="",n=e.peek();d(n);)e.read(),t+=n,n=e.peek();return t},readNumber:function(e){for(var t=this._reader,n=e,r="."===e,o=t.peek();o;){if(f(o))n+=t.read();else{if("."!==o)break;if(r)break;r=!0,n+=t.read()}o=t.peek()}return n},readString:function(){var e=this.stringToken(this._reader.read(),0,0);return e.type===i.INVALID?null:e.value},readURI:function(e){for(var t=this._reader,n=e,r="",i=t.peek();i&&d(i);)t.read(),i=t.peek();for("'"===i||'"'===i?null!==(r=this.readString())&&(r=o.parseString(r)):r=this.readUnquotedURL(),i=t.peek();i&&d(i);)t.read(),i=t.peek();return null===r||")"!==i?n=null:n+=o.serializeString(r)+t.read(),n},readUnquotedURL:function(e){var t,n=this._reader,r=e||"";for(t=n.peek();t;t=n.peek())if(s.test(t)||/^[\-!#$%&*-\[\]-~]$/.test(t))r+=t,n.read();else{if("\\"!==t)break;if(!/^[^\r\n\f]$/.test(n.peek(2)))break;r+=this.readEscape(n.read(),!0)}return r},readName:function(e){var t,n=this._reader,r=e||"";for(t=n.peek();t;t=n.peek())if("\\"===t){if(!/^[^\r\n\f]$/.test(n.peek(2)))break;r+=this.readEscape(n.read(),!0)}else{if(!v(t))break;r+=n.read()}return r},readEscape:function(e,t){var n=this._reader,r=e||"",o=0,i=n.peek();if(c(i))do{r+=n.read(),i=n.peek()}while(i&&c(i)&&++o<6);if(1===r.length){if(!/^[^\r\n\f0-9a-f]$/.test(i))throw new Error("Bad escape sequence.");if(n.read(),t)return i}else"\r"===i?(n.read(),"\n"===n.peek()&&(i+=n.read())):/^[ \t\n\f]$/.test(i)?n.read():i="";if(t){var a=parseInt(r.slice(e.length),16);return String.fromCodePoint?String.fromCodePoint(a):String.fromCharCode(a)}return r+i},readComment:function(e){var t=this._reader,n=e||"",r=t.read();if("*"===r){for(;r;){if((n+=r).length>2&&"*"===r&&"/"===t.peek()){n+=t.read();break}r=t.read()}return n}return""}})},function(e,t,n){"use strict";e.exports=i;var r=n(130),o=n(87);function i(e,t){this._reader=new r(e?e.toString():""),this._token=null,this._tokenData=t,this._lt=[],this._ltIndex=0,this._ltIndexCache=[]}i.createTokenData=function(e){var t=[],n=Object.create(null),r=e.concat([]),o=0,i=r.length+1;for(r.UNKNOWN=-1,r.unshift({name:"EOF"});o<i;o++)t.push(r[o].name),r[r[o].name]=o,r[o].text&&(n[r[o].text]=o);return r.name=function(e){return t[e]},r.type=function(e){return n[e]},r},i.prototype={constructor:i,match:function(e,t){e instanceof Array||(e=[e]);for(var n=this.get(t),r=0,o=e.length;r<o;)if(n===e[r++])return!0;return this.unget(),!1},mustMatch:function(e){var t;if(e instanceof Array||(e=[e]),!this.match.apply(this,arguments))throw t=this.LT(1),new o("Expected "+this._tokenData[e[0]].name+" at line "+t.startLine+", col "+t.startCol+".",t.startLine,t.startCol)},advance:function(e,t){for(;0!==this.LA(0)&&!this.match(e,t);)this.get();return this.LA(0)},get:function(e){var t,n,r=this._tokenData,o=0;if(this._lt.length&&this._ltIndex>=0&&this._ltIndex<this._lt.length){for(o++,this._token=this._lt[this._ltIndex++],n=r[this._token.type];void 0!==n.channel&&e!==n.channel&&this._ltIndex<this._lt.length;)this._token=this._lt[this._ltIndex++],n=r[this._token.type],o++;if((void 0===n.channel||e===n.channel)&&this._ltIndex<=this._lt.length)return this._ltIndexCache.push(o),this._token.type}return(t=this._getToken()).type>-1&&!r[t.type].hide&&(t.channel=r[t.type].channel,this._token=t,this._lt.push(t),this._ltIndexCache.push(this._lt.length-this._ltIndex+o),this._lt.length>5&&this._lt.shift(),this._ltIndexCache.length>5&&this._ltIndexCache.shift(),this._ltIndex=this._lt.length),(n=r[t.type])&&(n.hide||void 0!==n.channel&&e!==n.channel)?this.get(e):t.type},LA:function(e){var t,n=e;if(e>0){if(e>5)throw new Error("Too much lookahead.");for(;n;)t=this.get(),n--;for(;n<e;)this.unget(),n++}else if(e<0){if(!this._lt[this._ltIndex+e])throw new Error("Too much lookbehind.");t=this._lt[this._ltIndex+e].type}else t=this._token.type;return t},LT:function(e){return this.LA(e),this._lt[this._ltIndex+e-1]},peek:function(){return this.LA(1)},token:function(){return this._token},tokenName:function(e){return e<0||e>this._tokenData.length?"UNKNOWN_TOKEN":this._tokenData[e].name},tokenType:function(e){return this._tokenData[e]||-1},unget:function(){if(!this._ltIndexCache.length)throw new Error("Too much lookahead.");this._ltIndex-=this._ltIndexCache.pop(),this._token=this._lt[this._ltIndex-1]}}},function(e,t,n){"use strict";function r(e,t,n){this.col=n,this.line=t,this.message=e}e.exports=r,r.prototype=new Error},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,o="~";function i(){}function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function s(){this._events=new i,this._eventsCount=0}Object.create&&(i.prototype=Object.create(null),(new i).__proto__||(o=!1)),s.prototype.eventNames=function(){var e,t,n=[];if(0===this._eventsCount)return n;for(t in e=this._events)r.call(e,t)&&n.push(o?t.slice(1):t);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(e)):n},s.prototype.listeners=function(e,t){var n=o?o+e:e,r=this._events[n];if(t)return!!r;if(!r)return[];if(r.fn)return[r.fn];for(var i=0,a=r.length,s=new Array(a);i<a;i++)s[i]=r[i].fn;return s},s.prototype.emit=function(e,t,n,r,i,a){var s=o?o+e:e;if(!this._events[s])return!1;var u,l,c=this._events[s],f=arguments.length;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),f){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,r),!0;case 5:return c.fn.call(c.context,t,n,r,i),!0;case 6:return c.fn.call(c.context,t,n,r,i,a),!0}for(l=1,u=new Array(f-1);l<f;l++)u[l-1]=arguments[l];c.fn.apply(c.context,u)}else{var d,p=c.length;for(l=0;l<p;l++)switch(c[l].once&&this.removeListener(e,c[l].fn,void 0,!0),f){case 1:c[l].fn.call(c[l].context);break;case 2:c[l].fn.call(c[l].context,t);break;case 3:c[l].fn.call(c[l].context,t,n);break;case 4:c[l].fn.call(c[l].context,t,n,r);break;default:if(!u)for(d=1,u=new Array(f-1);d<f;d++)u[d-1]=arguments[d];c[l].fn.apply(c[l].context,u)}}return!0},s.prototype.on=function(e,t,n){var r=new a(t,n||this),i=o?o+e:e;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],r]:this._events[i].push(r):(this._events[i]=r,this._eventsCount++),this},s.prototype.once=function(e,t,n){var r=new a(t,n||this,!0),i=o?o+e:e;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],r]:this._events[i].push(r):(this._events[i]=r,this._eventsCount++),this},s.prototype.removeListener=function(e,t,n,r){var a=o?o+e:e;if(!this._events[a])return this;if(!t)return 0==--this._eventsCount?this._events=new i:delete this._events[a],this;var s=this._events[a];if(s.fn)s.fn!==t||r&&!s.once||n&&s.context!==n||(0==--this._eventsCount?this._events=new i:delete this._events[a]);else{for(var u=0,l=[],c=s.length;u<c;u++)(s[u].fn!==t||r&&!s[u].once||n&&s[u].context!==n)&&l.push(s[u]);l.length?this._events[a]=1===l.length?l[0]:l:0==--this._eventsCount?this._events=new i:delete this._events[a]}return this},s.prototype.removeAllListeners=function(e){var t;return e?(t=o?o+e:e,this._events[t]&&(0==--this._eventsCount?this._events=new i:delete this._events[t])):(this._events=new i,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prototype.setMaxListeners=function(){return this},s.prefixed=o,s.EventEmitter=s,e.exports=s},function(e,t,n){"use strict";var r=Object.prototype.hasOwnProperty,o="~";function i(){}function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function s(){this._events=new i,this._eventsCount=0}Object.create&&(i.prototype=Object.create(null),(new i).__proto__||(o=!1)),s.prototype.eventNames=function(){var e,t,n=[];if(0===this._eventsCount)return n;for(t in e=this._events)r.call(e,t)&&n.push(o?t.slice(1):t);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(e)):n},s.prototype.listeners=function(e,t){var n=o?o+e:e,r=this._events[n];if(t)return!!r;if(!r)return[];if(r.fn)return[r.fn];for(var i=0,a=r.length,s=new Array(a);i<a;i++)s[i]=r[i].fn;return s},s.prototype.emit=function(e,t,n,r,i,a){var s=o?o+e:e;if(!this._events[s])return!1;var u,l,c=this._events[s],f=arguments.length;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),f){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,r),!0;case 5:return c.fn.call(c.context,t,n,r,i),!0;case 6:return c.fn.call(c.context,t,n,r,i,a),!0}for(l=1,u=new Array(f-1);l<f;l++)u[l-1]=arguments[l];c.fn.apply(c.context,u)}else{var d,p=c.length;for(l=0;l<p;l++)switch(c[l].once&&this.removeListener(e,c[l].fn,void 0,!0),f){case 1:c[l].fn.call(c[l].context);break;case 2:c[l].fn.call(c[l].context,t);break;case 3:c[l].fn.call(c[l].context,t,n);break;case 4:c[l].fn.call(c[l].context,t,n,r);break;default:if(!u)for(d=1,u=new Array(f-1);d<f;d++)u[d-1]=arguments[d];c[l].fn.apply(c[l].context,u)}}return!0},s.prototype.on=function(e,t,n){var r=new a(t,n||this),i=o?o+e:e;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],r]:this._events[i].push(r):(this._events[i]=r,this._eventsCount++),this},s.prototype.once=function(e,t,n){var r=new a(t,n||this,!0),i=o?o+e:e;return this._events[i]?this._events[i].fn?this._events[i]=[this._events[i],r]:this._events[i].push(r):(this._events[i]=r,this._eventsCount++),this},s.prototype.removeListener=function(e,t,n,r){var a=o?o+e:e;if(!this._events[a])return this;if(!t)return 0==--this._eventsCount?this._events=new i:delete this._events[a],this;var s=this._events[a];if(s.fn)s.fn!==t||r&&!s.once||n&&s.context!==n||(0==--this._eventsCount?this._events=new i:delete this._events[a]);else{for(var u=0,l=[],c=s.length;u<c;u++)(s[u].fn!==t||r&&!s[u].once||n&&s[u].context!==n)&&l.push(s[u]);l.length?this._events[a]=1===l.length?l[0]:l:0==--this._eventsCount?this._events=new i:delete this._events[a]}return this},s.prototype.removeAllListeners=function(e){var t;return e?(t=o?o+e:e,this._events[t]&&(0==--this._eventsCount?this._events=new i:delete this._events[t])):(this._events=new i,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prototype.setMaxListeners=function(){return this},s.prefixed=o,s.EventEmitter=s,e.exports=s},function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e.exports=function(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(261);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(e,t,n,r,o,i,a){try{var s=e[i](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,o)}e.exports=function(e){return function(){var t=this,r=arguments;return new Promise((function(o,i){var a=e.apply(t,r);function s(e){n(a,o,i,s,u,"next",e)}function u(e){n(a,o,i,s,u,"throw",e)}s(void 0)}))}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(270),o=n(271),i=o;i.v1=r,i.v4=o,e.exports=i},function(e,t,n){"use strict";(function(e){var r=n(0),o=n.n(r),i=n(1),a=n.n(i),s=n(463);function u(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function l(e,t,n){return t&&u(e.prototype,t),n&&u(e,n),e}function c(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function f(){return(f=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function d(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 p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach((function(t){c(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function h(e){return(h=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function v(e,t){return(v=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function g(e,t){return!t||"object"!=typeof t&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}var m={HIDE:"__react_tooltip_hide_event",REBUILD:"__react_tooltip_rebuild_event",SHOW:"__react_tooltip_show_event"},y=function(e,t){var n;"function"==typeof window.CustomEvent?n=new window.CustomEvent(e,{detail:t}):(n=document.createEvent("Event")).initEvent(e,!1,!0,t),window.dispatchEvent(n)};var b=function(e,t){var n=this.state.show,r=this.props.id,o=this.isCapture(t.currentTarget),i=t.currentTarget.getAttribute("currentItem");o||t.stopPropagation(),n&&"true"===i?e||this.hideTooltip(t):(t.currentTarget.setAttribute("currentItem","true"),w(t.currentTarget,this.getTargetArray(r)),this.showTooltip(t))},w=function(e,t){for(var n=0;n<t.length;n++)e!==t[n]?t[n].setAttribute("currentItem","false"):t[n].setAttribute("currentItem","true")},_={id:"9b69f92e-d3fe-498b-b1b4-c5e63a51b0cf",set:function(e,t,n){this.id in e?e[this.id][t]=n:Object.defineProperty(e,this.id,{configurable:!0,value:c({},t,n)})},get:function(e,t){var n=e[this.id];if(void 0!==n)return n[t]}};var x=function(e,t,n){var r=t.respectEffect,o=void 0!==r&&r,i=t.customEvent,a=void 0!==i&&i,s=this.props.id,u=n.target.getAttribute("data-tip")||null,l=n.target.getAttribute("data-for")||null,c=n.target;if(!this.isCustomEvent(c)||a){var f=null==s&&null==l||l===s;if(null!=u&&(!o||"float"===this.getEffect(c))&&f){var d=function(e){var t={};for(var n in e)"function"==typeof e[n]?t[n]=e[n].bind(e):t[n]=e[n];return t}(n);d.currentTarget=c,e(d)}}},k=function(e,t){var n={};return e.forEach((function(e){var r=e.getAttribute(t);r&&r.split(" ").forEach((function(e){return n[e]=!0}))})),n},C=function(){return document.getElementsByTagName("body")[0]};function O(e,t,n,r,o,i,a){for(var s=E(n),u=s.width,l=s.height,c=E(t),f=c.width,d=c.height,p=S(e,t,i),h=p.mouseX,v=p.mouseY,g=T(i,f,d,u,l),m=j(a),y=m.extraOffsetX,b=m.extraOffsetY,w=window.innerWidth,_=window.innerHeight,x=M(n),k=x.parentTop,C=x.parentLeft,O=function(e){var t=g[e].l;return h+t+y},L=function(e){var t=g[e].t;return v+t+b},A=function(e){return function(e){var t=g[e].r;return h+t+y}(e)>w},P=function(e){return function(e){var t=g[e].b;return v+t+b}(e)>_},R=function(e){return function(e){return O(e)<0}(e)||A(e)||function(e){return L(e)<0}(e)||P(e)},D=function(e){return!R(e)},I=["top","bottom","left","right"],N=[],z=0;z<4;z++){var F=I[z];D(F)&&N.push(F)}var B,H=!1,U=o!==r;return D(o)&&U?(H=!0,B=o):N.length>0&&R(o)&&R(r)&&(H=!0,B=N[0]),H?{isNewState:!0,newState:{place:B}}:{isNewState:!1,position:{left:parseInt(O(r)-C,10),top:parseInt(L(r)-k,10)}}}var E=function(e){var t=e.getBoundingClientRect(),n=t.height,r=t.width;return{height:parseInt(n,10),width:parseInt(r,10)}},S=function(e,t,n){var r=t.getBoundingClientRect(),o=r.top,i=r.left,a=E(t),s=a.width,u=a.height;return"float"===n?{mouseX:e.clientX,mouseY:e.clientY}:{mouseX:i+s/2,mouseY:o+u/2}},T=function(e,t,n,r,o){var i,a,s,u;return"float"===e?(i={l:-r/2,r:r/2,t:-(o+3+2),b:-3},s={l:-r/2,r:r/2,t:15,b:o+3+2+12},u={l:-(r+3+2),r:-3,t:-o/2,b:o/2},a={l:3,r:r+3+2,t:-o/2,b:o/2}):"solid"===e&&(i={l:-r/2,r:r/2,t:-(n/2+o+2),b:-n/2},s={l:-r/2,r:r/2,t:n/2,b:n/2+o+2},u={l:-(r+t/2+2),r:-t/2,t:-o/2,b:o/2},a={l:t/2,r:r+t/2+2,t:-o/2,b:o/2}),{top:i,bottom:s,left:u,right:a}},j=function(e){var t=0,n=0;for(var r in"[object String]"===Object.prototype.toString.apply(e)&&(e=JSON.parse(e.toString().replace(/'/g,'"'))),e)"top"===r?n-=parseInt(e[r],10):"bottom"===r?n+=parseInt(e[r],10):"left"===r?t-=parseInt(e[r],10):"right"===r&&(t+=parseInt(e[r],10));return{extraOffsetX:t,extraOffsetY:n}},M=function(e){for(var t=e;t;){var n=window.getComputedStyle(t);if("none"!==n.getPropertyValue("transform")||"transform"===n.getPropertyValue("will-change"))break;t=t.parentElement}return{parentTop:t&&t.getBoundingClientRect().top||0,parentLeft:t&&t.getBoundingClientRect().left||0}};function L(e,t,n,r){if(t)return t;if(null!=n)return n;if(null===n)return null;var i=/<br\s*\/?>/;return r&&"false"!==r&&i.test(e)?e.split(i).map((function(e,t){return o.a.createElement("span",{key:t,className:"multi-line"},e)})):e}function A(e){var t={};return Object.keys(e).filter((function(e){return/(^aria-\w+$|^role$)/.test(e)})).forEach((function(n){t[n]=e[n]})),t}function P(e){var t=e.length;return e.hasOwnProperty?Array.prototype.slice.call(e):new Array(t).fill().map((function(t){return e[t]}))}var R={dark:{text:"#fff",background:"#222",border:"transparent",arrow:"#222"},success:{text:"#fff",background:"#8DC572",border:"transparent",arrow:"#8DC572"},warning:{text:"#fff",background:"#F0AD4E",border:"transparent",arrow:"#F0AD4E"},error:{text:"#fff",background:"#BE6464",border:"transparent",arrow:"#BE6464"},info:{text:"#fff",background:"#337AB7",border:"transparent",arrow:"#337AB7"},light:{text:"#222",background:"#fff",border:"transparent",arrow:"#fff"}};function D(e,t,n,r){return function(e,t){var n=t.text,r=t.background,o=t.border,i=t.arrow;return"\n \t.".concat(e," {\n\t color: ").concat(n,";\n\t background: ").concat(r,";\n\t border: 1px solid ").concat(o,";\n \t}\n\n \t.").concat(e,".place-top {\n margin-top: -10px;\n }\n .").concat(e,".place-top::before {\n border-top: 8px solid ").concat(o,";\n }\n .").concat(e,".place-top::after {\n border-left: 8px solid transparent;\n border-right: 8px solid transparent;\n bottom: -6px;\n left: 50%;\n margin-left: -8px;\n border-top-color: ").concat(i,";\n border-top-style: solid;\n border-top-width: 6px;\n }\n\n .").concat(e,".place-bottom {\n margin-top: 10px;\n }\n .").concat(e,".place-bottom::before {\n border-bottom: 8px solid ").concat(o,";\n }\n .").concat(e,".place-bottom::after {\n border-left: 8px solid transparent;\n border-right: 8px solid transparent;\n top: -6px;\n left: 50%;\n margin-left: -8px;\n border-bottom-color: ").concat(i,";\n border-bottom-style: solid;\n border-bottom-width: 6px;\n }\n\n .").concat(e,".place-left {\n margin-left: -10px;\n }\n .").concat(e,".place-left::before {\n border-left: 8px solid ").concat(o,";\n }\n .").concat(e,".place-left::after {\n border-top: 5px solid transparent;\n border-bottom: 5px solid transparent;\n right: -6px;\n top: 50%;\n margin-top: -4px;\n border-left-color: ").concat(i,";\n border-left-style: solid;\n border-left-width: 6px;\n }\n\n .").concat(e,".place-right {\n margin-left: 10px;\n }\n .").concat(e,".place-right::before {\n border-right: 8px solid ").concat(o,";\n }\n .").concat(e,".place-right::after {\n border-top: 5px solid transparent;\n border-bottom: 5px solid transparent;\n left: -6px;\n top: 50%;\n margin-top: -4px;\n border-right-color: ").concat(i,";\n border-right-style: solid;\n border-right-width: 6px;\n }\n ")}(e,function(e,t,n){var r=e.text,o=e.background,i=e.border,a=e.arrow?e.arrow:e.background,s=function(e){return R[e]?p({},R[e]):void 0}(t);r&&(s.text=r);o&&(s.background=o);n&&(s.border=i||("light"===t?"black":"white"));a&&(s.arrow=a);return s}(t,n,r))}var I="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{};function N(e,t){return e(t={exports:{}},t.exports),t.exports}var z=function(e){return e&&e.Math==Math&&e},F=z("object"==typeof globalThis&&globalThis)||z("object"==typeof window&&window)||z("object"==typeof self&&self)||z("object"==typeof I&&I)||function(){return this}()||Function("return this")(),B=function(e){try{return!!e()}catch(e){return!0}},H=!B((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),U={}.propertyIsEnumerable,W=Object.getOwnPropertyDescriptor,V={f:W&&!U.call({1:2},1)?function(e){var t=W(this,e);return!!t&&t.enumerable}:U},q=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}},Y={}.toString,G=function(e){return Y.call(e).slice(8,-1)},$="".split,K=B((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==G(e)?$.call(e,""):Object(e)}:Object,Z=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e},X=function(e){return K(Z(e))},Q=function(e){return"object"==typeof e?null!==e:"function"==typeof e},J=function(e,t){if(!Q(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!Q(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!Q(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!Q(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")},ee=function(e){return Object(Z(e))},te={}.hasOwnProperty,ne=function(e,t){return te.call(ee(e),t)},re=F.document,oe=Q(re)&&Q(re.createElement),ie=function(e){return oe?re.createElement(e):{}},ae=!H&&!B((function(){return 7!=Object.defineProperty(ie("div"),"a",{get:function(){return 7}}).a})),se=Object.getOwnPropertyDescriptor,ue={f:H?se:function(e,t){if(e=X(e),t=J(t,!0),ae)try{return se(e,t)}catch(e){}if(ne(e,t))return q(!V.f.call(e,t),e[t])}},le=function(e){if(!Q(e))throw TypeError(String(e)+" is not an object");return e},ce=Object.defineProperty,fe={f:H?ce:function(e,t,n){if(le(e),t=J(t,!0),le(n),ae)try{return ce(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},de=H?function(e,t,n){return fe.f(e,t,q(1,n))}:function(e,t,n){return e[t]=n,e},pe=function(e,t){try{de(F,e,t)}catch(n){F[e]=t}return t},he=F["__core-js_shared__"]||pe("__core-js_shared__",{}),ve=Function.toString;"function"!=typeof he.inspectSource&&(he.inspectSource=function(e){return ve.call(e)});var ge,me,ye,be=he.inspectSource,we=F.WeakMap,_e="function"==typeof we&&/native code/.test(be(we)),xe=N((function(e){(e.exports=function(e,t){return he[e]||(he[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.12.1",mode:"global",copyright:"\xa9 2021 Denis Pushkarev (zloirock.ru)"})})),ke=0,Ce=Math.random(),Oe=function(e){return"Symbol("+String(void 0===e?"":e)+")_"+(++ke+Ce).toString(36)},Ee=xe("keys"),Se=function(e){return Ee[e]||(Ee[e]=Oe(e))},Te={},je=F.WeakMap;if(_e||he.state){var Me=he.state||(he.state=new je),Le=Me.get,Ae=Me.has,Pe=Me.set;ge=function(e,t){if(Ae.call(Me,e))throw new TypeError("Object already initialized");return t.facade=e,Pe.call(Me,e,t),t},me=function(e){return Le.call(Me,e)||{}},ye=function(e){return Ae.call(Me,e)}}else{var Re=Se("state");Te[Re]=!0,ge=function(e,t){if(ne(e,Re))throw new TypeError("Object already initialized");return t.facade=e,de(e,Re,t),t},me=function(e){return ne(e,Re)?e[Re]:{}},ye=function(e){return ne(e,Re)}}var De,Ie,Ne={set:ge,get:me,has:ye,enforce:function(e){return ye(e)?me(e):ge(e,{})},getterFor:function(e){return function(t){var n;if(!Q(t)||(n=me(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}}},ze=N((function(e){var t=Ne.get,n=Ne.enforce,r=String(String).split("String");(e.exports=function(e,t,o,i){var a,s=!!i&&!!i.unsafe,u=!!i&&!!i.enumerable,l=!!i&&!!i.noTargetGet;"function"==typeof o&&("string"!=typeof t||ne(o,"name")||de(o,"name",t),(a=n(o)).source||(a.source=r.join("string"==typeof t?t:""))),e!==F?(s?!l&&e[t]&&(u=!0):delete e[t],u?e[t]=o:de(e,t,o)):u?e[t]=o:pe(t,o)})(Function.prototype,"toString",(function(){return"function"==typeof this&&t(this).source||be(this)}))})),Fe=F,Be=function(e){return"function"==typeof e?e:void 0},He=function(e,t){return arguments.length<2?Be(Fe[e])||Be(F[e]):Fe[e]&&Fe[e][t]||F[e]&&F[e][t]},Ue=Math.ceil,We=Math.floor,Ve=function(e){return isNaN(e=+e)?0:(e>0?We:Ue)(e)},qe=Math.min,Ye=function(e){return e>0?qe(Ve(e),9007199254740991):0},Ge=Math.max,$e=Math.min,Ke=function(e){return function(t,n,r){var o,i=X(t),a=Ye(i.length),s=function(e,t){var n=Ve(e);return n<0?Ge(n+t,0):$e(n,t)}(r,a);if(e&&n!=n){for(;a>s;)if((o=i[s++])!=o)return!0}else for(;a>s;s++)if((e||s in i)&&i[s]===n)return e||s||0;return!e&&-1}},Ze={includes:Ke(!0),indexOf:Ke(!1)}.indexOf,Xe=function(e,t){var n,r=X(e),o=0,i=[];for(n in r)!ne(Te,n)&&ne(r,n)&&i.push(n);for(;t.length>o;)ne(r,n=t[o++])&&(~Ze(i,n)||i.push(n));return i},Qe=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Je=Qe.concat("length","prototype"),et={f:Object.getOwnPropertyNames||function(e){return Xe(e,Je)}},tt={f:Object.getOwnPropertySymbols},nt=He("Reflect","ownKeys")||function(e){var t=et.f(le(e)),n=tt.f;return n?t.concat(n(e)):t},rt=function(e,t){for(var n=nt(t),r=fe.f,o=ue.f,i=0;i<n.length;i++){var a=n[i];ne(e,a)||r(e,a,o(t,a))}},ot=/#|\.prototype\./,it=function(e,t){var n=st[at(e)];return n==lt||n!=ut&&("function"==typeof t?B(t):!!t)},at=it.normalize=function(e){return String(e).replace(ot,".").toLowerCase()},st=it.data={},ut=it.NATIVE="N",lt=it.POLYFILL="P",ct=it,ft=ue.f,dt=function(e,t,n){if(function(e){if("function"!=typeof e)throw TypeError(String(e)+" is not a function")}(e),void 0===t)return e;switch(n){case 0:return function(){return e.call(t)};case 1:return function(n){return e.call(t,n)};case 2:return function(n,r){return e.call(t,n,r)};case 3:return function(n,r,o){return e.call(t,n,r,o)}}return function(){return e.apply(t,arguments)}},pt=Array.isArray||function(e){return"Array"==G(e)},ht=He("navigator","userAgent")||"",vt=F.process,gt=vt&&vt.versions,mt=gt&>.v8;mt?Ie=(De=mt.split("."))[0]<4?1:De[0]+De[1]:ht&&(!(De=ht.match(/Edge\/(\d+)/))||De[1]>=74)&&(De=ht.match(/Chrome\/(\d+)/))&&(Ie=De[1]);var yt,bt=Ie&&+Ie,wt=!!Object.getOwnPropertySymbols&&!B((function(){return!String(Symbol())||!Symbol.sham&&bt&&bt<41})),_t=wt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,xt=xe("wks"),kt=F.Symbol,Ct=_t?kt:kt&&kt.withoutSetter||Oe,Ot=function(e){return ne(xt,e)&&(wt||"string"==typeof xt[e])||(wt&&ne(kt,e)?xt[e]=kt[e]:xt[e]=Ct("Symbol."+e)),xt[e]},Et=Ot("species"),St=function(e,t){var n;return pt(e)&&("function"!=typeof(n=e.constructor)||n!==Array&&!pt(n.prototype)?Q(n)&&null===(n=n[Et])&&(n=void 0):n=void 0),new(void 0===n?Array:n)(0===t?0:t)},Tt=[].push,jt=function(e){var t=1==e,n=2==e,r=3==e,o=4==e,i=6==e,a=7==e,s=5==e||i;return function(u,l,c,f){for(var d,p,h=ee(u),v=K(h),g=dt(l,c,3),m=Ye(v.length),y=0,b=f||St,w=t?b(u,m):n||a?b(u,0):void 0;m>y;y++)if((s||y in v)&&(p=g(d=v[y],y,h),e))if(t)w[y]=p;else if(p)switch(e){case 3:return!0;case 5:return d;case 6:return y;case 2:Tt.call(w,d)}else switch(e){case 4:return!1;case 7:Tt.call(w,d)}return i?-1:r||o?o:w}},Mt={forEach:jt(0),map:jt(1),filter:jt(2),some:jt(3),every:jt(4),find:jt(5),findIndex:jt(6),filterOut:jt(7)},Lt=Object.keys||function(e){return Xe(e,Qe)},At=H?Object.defineProperties:function(e,t){le(e);for(var n,r=Lt(t),o=r.length,i=0;o>i;)fe.f(e,n=r[i++],t[n]);return e},Pt=He("document","documentElement"),Rt=Se("IE_PROTO"),Dt=function(){},It=function(e){return"<script>"+e+"<\/script>"},Nt=function(){try{yt=document.domain&&new ActiveXObject("htmlfile")}catch(e){}var e,t;Nt=yt?function(e){e.write(It("")),e.close();var t=e.parentWindow.Object;return e=null,t}(yt):((t=ie("iframe")).style.display="none",Pt.appendChild(t),t.src=String("javascript:"),(e=t.contentWindow.document).open(),e.write(It("document.F=Object")),e.close(),e.F);for(var n=Qe.length;n--;)delete Nt.prototype[Qe[n]];return Nt()};Te[Rt]=!0;var zt=Object.create||function(e,t){var n;return null!==e?(Dt.prototype=le(e),n=new Dt,Dt.prototype=null,n[Rt]=e):n=Nt(),void 0===t?n:At(n,t)},Ft=Ot("unscopables"),Bt=Array.prototype;null==Bt[Ft]&&fe.f(Bt,Ft,{configurable:!0,value:zt(null)});var Ht,Ut,Wt,Vt,qt=Mt.find,Yt=!0;"find"in[]&&Array(1).find((function(){Yt=!1})),function(e,t){var n,r,o,i,a,s=e.target,u=e.global,l=e.stat;if(n=u?F:l?F[s]||pe(s,{}):(F[s]||{}).prototype)for(r in t){if(i=t[r],o=e.noTargetGet?(a=ft(n,r))&&a.value:n[r],!ct(u?r:s+(l?".":"#")+r,e.forced)&&void 0!==o){if(typeof i==typeof o)continue;rt(i,o)}(e.sham||o&&o.sham)&&de(i,"sham",!0),ze(n,r,i,e)}}({target:"Array",proto:!0,forced:Yt},{find:function(e){return qt(this,e,arguments.length>1?arguments[1]:void 0)}}),Ht="find",Bt[Ft][Ht]=!0;var Gt,$t=function(e){e.hide=function(e){y(m.HIDE,{target:e})},e.rebuild=function(){y(m.REBUILD)},e.show=function(e){y(m.SHOW,{target:e})},e.prototype.globalRebuild=function(){this.mount&&(this.unbindListener(),this.bindListener())},e.prototype.globalShow=function(e){if(this.mount){var t=!!(e&&e.detail&&e.detail.target);this.showTooltip({currentTarget:t&&e.detail.target},!0)}},e.prototype.globalHide=function(e){if(this.mount){var t=!!(e&&e.detail&&e.detail.target);this.hideTooltip({currentTarget:t&&e.detail.target},t)}}}(Ut=function(e){e.prototype.bindWindowEvents=function(e){window.removeEventListener(m.HIDE,this.globalHide),window.addEventListener(m.HIDE,this.globalHide,!1),window.removeEventListener(m.REBUILD,this.globalRebuild),window.addEventListener(m.REBUILD,this.globalRebuild,!1),window.removeEventListener(m.SHOW,this.globalShow),window.addEventListener(m.SHOW,this.globalShow,!1),e&&(window.removeEventListener("resize",this.onWindowResize),window.addEventListener("resize",this.onWindowResize,!1))},e.prototype.unbindWindowEvents=function(){window.removeEventListener(m.HIDE,this.globalHide),window.removeEventListener(m.REBUILD,this.globalRebuild),window.removeEventListener(m.SHOW,this.globalShow),window.removeEventListener("resize",this.onWindowResize)},e.prototype.onWindowResize=function(){this.mount&&this.hideTooltip()}}(Ut=function(e){e.prototype.isCustomEvent=function(e){return this.state.event||!!e.getAttribute("data-event")},e.prototype.customBindListener=function(e){var t=this,n=this.state,r=n.event,o=n.eventOff,i=e.getAttribute("data-event")||r,a=e.getAttribute("data-event-off")||o;i.split(" ").forEach((function(n){e.removeEventListener(n,_.get(e,n));var r=b.bind(t,a);_.set(e,n,r),e.addEventListener(n,r,!1)})),a&&a.split(" ").forEach((function(n){e.removeEventListener(n,t.hideTooltip),e.addEventListener(n,t.hideTooltip,!1)}))},e.prototype.customUnbindListener=function(e){var t=this.state,n=t.event,r=t.eventOff,o=n||e.getAttribute("data-event"),i=r||e.getAttribute("data-event-off");e.removeEventListener(o,_.get(e,n)),i&&e.removeEventListener(i,this.hideTooltip)}}(Ut=function(e){e.prototype.isCapture=function(e){return e&&"true"===e.getAttribute("data-iscapture")||this.props.isCapture||!1}}(Ut=function(e){e.prototype.getEffect=function(e){return e.getAttribute("data-effect")||this.props.effect||"float"}}(Ut=function(e){e.prototype.isBodyMode=function(){return!!this.props.bodyMode},e.prototype.bindBodyListener=function(e){var t=this,n=this.state,r=n.event,o=n.eventOff,i=n.possibleCustomEvents,a=n.possibleCustomEventsOff,s=C(),u=k(e,"data-event"),l=k(e,"data-event-off");null!=r&&(u[r]=!0),null!=o&&(l[o]=!0),i.split(" ").forEach((function(e){return u[e]=!0})),a.split(" ").forEach((function(e){return l[e]=!0})),this.unbindBodyListener(s);var c=this.bodyModeListeners={};for(var f in null==r&&(c.mouseover=x.bind(this,this.showTooltip,{}),c.mousemove=x.bind(this,this.updateTooltip,{respectEffect:!0}),c.mouseout=x.bind(this,this.hideTooltip,{})),u)c[f]=x.bind(this,(function(e){var n=e.currentTarget.getAttribute("data-event-off")||o;b.call(t,n,e)}),{customEvent:!0});for(var d in l)c[d]=x.bind(this,this.hideTooltip,{customEvent:!0});for(var p in c)s.addEventListener(p,c[p])},e.prototype.unbindBodyListener=function(e){e=e||C();var t=this.bodyModeListeners;for(var n in t)e.removeEventListener(n,t[n])}}((Vt=Wt=function(e){function t(e){var n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),(n=g(this,h(t).call(this,e))).state={uuid:e.uuid||"t"+Object(s.a)(),place:e.place||"top",desiredPlace:e.place||"top",type:"dark",effect:"float",show:!1,border:!1,customColors:{},offset:{},extraClass:"",html:!1,delayHide:0,delayShow:0,event:e.event||null,eventOff:e.eventOff||null,currentEvent:null,currentTarget:null,ariaProps:A(e),isEmptyTip:!1,disable:!1,possibleCustomEvents:e.possibleCustomEvents||"",possibleCustomEventsOff:e.possibleCustomEventsOff||"",originTooltip:null,isMultiline:!1},n.bind(["showTooltip","updateTooltip","hideTooltip","hideTooltipOnScroll","getTooltipContent","globalRebuild","globalShow","globalHide","onWindowResize","mouseOnToolTip"]),n.mount=!0,n.delayShowLoop=null,n.delayHideLoop=null,n.delayReshow=null,n.intervalUpdateContent=null,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&v(e,t)}(t,e),l(t,null,[{key:"propTypes",get:function(){return{uuid:a.a.string,children:a.a.any,place:a.a.string,type:a.a.string,effect:a.a.string,offset:a.a.object,multiline:a.a.bool,border:a.a.bool,textColor:a.a.string,backgroundColor:a.a.string,borderColor:a.a.string,arrowColor:a.a.string,insecure:a.a.bool,class:a.a.string,className:a.a.string,id:a.a.string,html:a.a.bool,delayHide:a.a.number,delayUpdate:a.a.number,delayShow:a.a.number,event:a.a.string,eventOff:a.a.string,isCapture:a.a.bool,globalEventOff:a.a.string,getContent:a.a.any,afterShow:a.a.func,afterHide:a.a.func,overridePosition:a.a.func,disable:a.a.bool,scrollHide:a.a.bool,resizeHide:a.a.bool,wrapper:a.a.string,bodyMode:a.a.bool,possibleCustomEvents:a.a.string,possibleCustomEventsOff:a.a.string,clickable:a.a.bool}}}]),l(t,[{key:"bind",value:function(e){var t=this;e.forEach((function(e){t[e]=t[e].bind(t)}))}},{key:"componentDidMount",value:function(){var e=this.props,t=(e.insecure,e.resizeHide);this.bindListener(),this.bindWindowEvents(t),this.injectStyles()}},{key:"componentWillUnmount",value:function(){this.mount=!1,this.clearTimer(),this.unbindListener(),this.removeScrollListener(this.state.currentTarget),this.unbindWindowEvents()}},{key:"injectStyles",value:function(){var e=this.tooltipRef;if(e){for(var t,n=e.parentNode;n.parentNode;)n=n.parentNode;switch(n.constructor.name){case"Document":case"HTMLDocument":case void 0:t=n.head;break;case"ShadowRoot":default:t=n}if(!t.querySelector("style[data-react-tooltip]")){var r=document.createElement("style");r.textContent='.__react_component_tooltip {\n border-radius: 3px;\n display: inline-block;\n font-size: 13px;\n left: -999em;\n opacity: 0;\n padding: 8px 21px;\n position: fixed;\n pointer-events: none;\n transition: opacity 0.3s ease-out;\n top: -999em;\n visibility: hidden;\n z-index: 999;\n}\n.__react_component_tooltip.allow_hover, .__react_component_tooltip.allow_click {\n pointer-events: auto;\n}\n.__react_component_tooltip::before, .__react_component_tooltip::after {\n content: "";\n width: 0;\n height: 0;\n position: absolute;\n}\n.__react_component_tooltip.show {\n opacity: 0.9;\n margin-top: 0;\n margin-left: 0;\n visibility: visible;\n}\n.__react_component_tooltip.place-top::before {\n border-left: 10px solid transparent;\n border-right: 10px solid transparent;\n bottom: -8px;\n left: 50%;\n margin-left: -10px;\n}\n.__react_component_tooltip.place-bottom::before {\n border-left: 10px solid transparent;\n border-right: 10px solid transparent;\n top: -8px;\n left: 50%;\n margin-left: -10px;\n}\n.__react_component_tooltip.place-left::before {\n border-top: 6px solid transparent;\n border-bottom: 6px solid transparent;\n right: -8px;\n top: 50%;\n margin-top: -5px;\n}\n.__react_component_tooltip.place-right::before {\n border-top: 6px solid transparent;\n border-bottom: 6px solid transparent;\n left: -8px;\n top: 50%;\n margin-top: -5px;\n}\n.__react_component_tooltip .multi-line {\n display: block;\n padding: 2px 0;\n text-align: center;\n}',r.setAttribute("data-react-tooltip","true"),t.appendChild(r)}}}},{key:"mouseOnToolTip",value:function(){return!(!this.state.show||!this.tooltipRef)&&(this.tooltipRef.matches||(this.tooltipRef.msMatchesSelector?this.tooltipRef.matches=this.tooltipRef.msMatchesSelector:this.tooltipRef.matches=this.tooltipRef.mozMatchesSelector),this.tooltipRef.matches(":hover"))}},{key:"getTargetArray",value:function(e){var t,n=[];if(e){var r=e.replace(/\\/g,"\\\\").replace(/"/g,'\\"');t='[data-tip][data-for="'.concat(r,'"]')}else t="[data-tip]:not([data-for])";return P(document.getElementsByTagName("*")).filter((function(e){return e.shadowRoot})).forEach((function(e){n=n.concat(P(e.shadowRoot.querySelectorAll(t)))})),n.concat(P(document.querySelectorAll(t)))}},{key:"bindListener",value:function(){var e=this,t=this.props,n=t.id,r=t.globalEventOff,o=t.isCapture,i=this.getTargetArray(n);i.forEach((function(t){null===t.getAttribute("currentItem")&&t.setAttribute("currentItem","false"),e.unbindBasicListener(t),e.isCustomEvent(t)&&e.customUnbindListener(t)})),this.isBodyMode()?this.bindBodyListener(i):i.forEach((function(t){var n=e.isCapture(t),r=e.getEffect(t);e.isCustomEvent(t)?e.customBindListener(t):(t.addEventListener("mouseenter",e.showTooltip,n),t.addEventListener("focus",e.showTooltip,n),"float"===r&&t.addEventListener("mousemove",e.updateTooltip,n),t.addEventListener("mouseleave",e.hideTooltip,n),t.addEventListener("blur",e.hideTooltip,n))})),r&&(window.removeEventListener(r,this.hideTooltip),window.addEventListener(r,this.hideTooltip,o)),this.bindRemovalTracker()}},{key:"unbindListener",value:function(){var e=this,t=this.props,n=t.id,r=t.globalEventOff;this.isBodyMode()?this.unbindBodyListener():this.getTargetArray(n).forEach((function(t){e.unbindBasicListener(t),e.isCustomEvent(t)&&e.customUnbindListener(t)})),r&&window.removeEventListener(r,this.hideTooltip),this.unbindRemovalTracker()}},{key:"unbindBasicListener",value:function(e){var t=this.isCapture(e);e.removeEventListener("mouseenter",this.showTooltip,t),e.removeEventListener("mousemove",this.updateTooltip,t),e.removeEventListener("mouseleave",this.hideTooltip,t)}},{key:"getTooltipContent",value:function(){var e,t=this.props,n=t.getContent,r=t.children;return n&&(e=Array.isArray(n)?n[0]&&n[0](this.state.originTooltip):n(this.state.originTooltip)),L(this.state.originTooltip,r,e,this.state.isMultiline)}},{key:"isEmptyTip",value:function(e){return"string"==typeof e&&""===e||null===e}},{key:"showTooltip",value:function(e,t){if(this.tooltipRef){if(t&&!this.getTargetArray(this.props.id).some((function(t){return t===e.currentTarget})))return;var n=this.props,r=n.multiline,o=n.getContent,i=e.currentTarget.getAttribute("data-tip"),a=e.currentTarget.getAttribute("data-multiline")||r||!1,s=e instanceof window.FocusEvent||t,u=!0;e.currentTarget.getAttribute("data-scroll-hide")?u="true"===e.currentTarget.getAttribute("data-scroll-hide"):null!=this.props.scrollHide&&(u=this.props.scrollHide),e&&e.currentTarget&&e.currentTarget.setAttribute&&e.currentTarget.setAttribute("aria-describedby",this.state.uuid);var l=e.currentTarget.getAttribute("data-place")||this.props.place||"top",c=s?"solid":this.getEffect(e.currentTarget),f=e.currentTarget.getAttribute("data-offset")||this.props.offset||{},d=O(e,e.currentTarget,this.tooltipRef,l,l,c,f);d.position&&this.props.overridePosition&&(d.position=this.props.overridePosition(d.position,e,e.currentTarget,this.tooltipRef,l,l,c,f));var p=d.isNewState?d.newState.place:l;this.clearTimer();var h=e.currentTarget,v=this.state.show?h.getAttribute("data-delay-update")||this.props.delayUpdate:0,g=this,m=function(){g.setState({originTooltip:i,isMultiline:a,desiredPlace:l,place:p,type:h.getAttribute("data-type")||g.props.type||"dark",customColors:{text:h.getAttribute("data-text-color")||g.props.textColor||null,background:h.getAttribute("data-background-color")||g.props.backgroundColor||null,border:h.getAttribute("data-border-color")||g.props.borderColor||null,arrow:h.getAttribute("data-arrow-color")||g.props.arrowColor||null},effect:c,offset:f,html:(h.getAttribute("data-html")?"true"===h.getAttribute("data-html"):g.props.html)||!1,delayShow:h.getAttribute("data-delay-show")||g.props.delayShow||0,delayHide:h.getAttribute("data-delay-hide")||g.props.delayHide||0,delayUpdate:h.getAttribute("data-delay-update")||g.props.delayUpdate||0,border:(h.getAttribute("data-border")?"true"===h.getAttribute("data-border"):g.props.border)||!1,extraClass:h.getAttribute("data-class")||g.props.class||g.props.className||"",disable:(h.getAttribute("data-tip-disable")?"true"===h.getAttribute("data-tip-disable"):g.props.disable)||!1,currentTarget:h},(function(){u&&g.addScrollListener(g.state.currentTarget),g.updateTooltip(e),o&&Array.isArray(o)&&(g.intervalUpdateContent=setInterval((function(){if(g.mount){var e=g.props.getContent,t=L(i,"",e[0](),a),n=g.isEmptyTip(t);g.setState({isEmptyTip:n}),g.updatePosition()}}),o[1]))}))};v?this.delayReshow=setTimeout(m,v):m()}}},{key:"updateTooltip",value:function(e){var t=this,n=this.state,r=n.delayShow,o=n.disable,i=this.props.afterShow,a=this.getTooltipContent(),s=e.currentTarget||e.target;if(!this.mouseOnToolTip()&&!this.isEmptyTip(a)&&!o){var u=this.state.show?0:parseInt(r,10),l=function(){if(Array.isArray(a)&&a.length>0||a){var n=!t.state.show;t.setState({currentEvent:e,currentTarget:s,show:!0},(function(){t.updatePosition(),n&&i&&i(e)}))}};clearTimeout(this.delayShowLoop),u?this.delayShowLoop=setTimeout(l,u):l()}}},{key:"listenForTooltipExit",value:function(){this.state.show&&this.tooltipRef&&this.tooltipRef.addEventListener("mouseleave",this.hideTooltip)}},{key:"removeListenerForTooltipExit",value:function(){this.state.show&&this.tooltipRef&&this.tooltipRef.removeEventListener("mouseleave",this.hideTooltip)}},{key:"hideTooltip",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{isScroll:!1},o=this.state.disable,i=r.isScroll,a=i?0:this.state.delayHide,s=this.props.afterHide,u=this.getTooltipContent();if(this.mount&&!this.isEmptyTip(u)&&!o){if(t){var l=this.getTargetArray(this.props.id),c=l.some((function(t){return t===e.currentTarget}));if(!c||!this.state.show)return}e&&e.currentTarget&&e.currentTarget.removeAttribute&&e.currentTarget.removeAttribute("aria-describedby");var f=function(){var t=n.state.show;n.mouseOnToolTip()?n.listenForTooltipExit():(n.removeListenerForTooltipExit(),n.setState({show:!1},(function(){n.removeScrollListener(n.state.currentTarget),t&&s&&s(e)})))};this.clearTimer(),a?this.delayHideLoop=setTimeout(f,parseInt(a,10)):f()}}},{key:"hideTooltipOnScroll",value:function(e,t){this.hideTooltip(e,t,{isScroll:!0})}},{key:"addScrollListener",value:function(e){var t=this.isCapture(e);window.addEventListener("scroll",this.hideTooltipOnScroll,t)}},{key:"removeScrollListener",value:function(e){var t=this.isCapture(e);window.removeEventListener("scroll",this.hideTooltipOnScroll,t)}},{key:"updatePosition",value:function(){var e=this,t=this.state,n=t.currentEvent,r=t.currentTarget,o=t.place,i=t.desiredPlace,a=t.effect,s=t.offset,u=this.tooltipRef,l=O(n,r,u,o,i,a,s);if(l.position&&this.props.overridePosition&&(l.position=this.props.overridePosition(l.position,n,r,u,o,i,a,s)),l.isNewState)return this.setState(l.newState,(function(){e.updatePosition()}));u.style.left=l.position.left+"px",u.style.top=l.position.top+"px"}},{key:"clearTimer",value:function(){clearTimeout(this.delayShowLoop),clearTimeout(this.delayHideLoop),clearTimeout(this.delayReshow),clearInterval(this.intervalUpdateContent)}},{key:"hasCustomColors",value:function(){var e=this;return Boolean(Object.keys(this.state.customColors).find((function(t){return"border"!==t&&e.state.customColors[t]}))||this.state.border&&this.state.customColors.border)}},{key:"render",value:function(){var e=this,n=this.state,r=n.extraClass,i=n.html,a=n.ariaProps,s=n.disable,u=n.uuid,l=this.getTooltipContent(),c=this.isEmptyTip(l),d=D(this.state.uuid,this.state.customColors,this.state.type,this.state.border),p="__react_component_tooltip"+" ".concat(this.state.uuid)+(!this.state.show||s||c?"":" show")+(this.state.border?" border":"")+" place-".concat(this.state.place)+" type-".concat(this.hasCustomColors()?"custom":this.state.type)+(this.props.delayUpdate?" allow_hover":"")+(this.props.clickable?" allow_click":""),h=this.props.wrapper;t.supportedWrappers.indexOf(h)<0&&(h=t.defaultProps.wrapper);var v=[p,r].filter(Boolean).join(" ");if(i){var g="".concat(l,'\n<style aria-hidden="true">').concat(d,"</style>");return o.a.createElement(h,f({className:"".concat(v),id:this.props.id||u,ref:function(t){return e.tooltipRef=t}},a,{"data-id":"tooltip",dangerouslySetInnerHTML:{__html:g}}))}return o.a.createElement(h,f({className:"".concat(v),id:this.props.id||u},a,{ref:function(t){return e.tooltipRef=t},"data-id":"tooltip"}),o.a.createElement("style",{dangerouslySetInnerHTML:{__html:d},"aria-hidden":"true"}),l)}}],[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.ariaProps,r=A(e);return Object.keys(r).some((function(e){return r[e]!==n[e]}))?p({},t,{ariaProps:r}):null}}]),t}(o.a.Component),c(Wt,"defaultProps",{insecure:!0,resizeHide:!0,wrapper:"div",clickable:!1}),c(Wt,"supportedWrappers",["div","span"]),c(Wt,"displayName","ReactTooltip"),(Gt=Ut=Vt).prototype.bindRemovalTracker=function(){var e=this,t=window.MutationObserver||window.WebKitMutationObserver||window.MozMutationObserver;if(null!=t){var n=new t((function(t){for(var n=0;n<t.length;n++)for(var r=t[n],o=0;o<r.removedNodes.length;o++)if(r.removedNodes[o]===e.state.currentTarget)return void e.hideTooltip()}));n.observe(window.document,{childList:!0,subtree:!0}),this.removalTracker=n}},Ut=void(Gt.prototype.unbindRemovalTracker=function(){this.removalTracker&&(this.removalTracker.disconnect(),this.removalTracker=null)})||Ut))||Ut)||Ut)||Ut)||Ut)||Ut)||Ut;t.a=$t}).call(this,n(31))},function(e,t,n){"use strict";var r=function(e){return e&&"object"==typeof e&&"default"in e?e.default:e}(n(0)),o=!1;"undefined"!=typeof window&&(o="ontouchstart"in window||window.DocumentTouch&&document instanceof window.DocumentTouch);var i=o,a={borderRadius:"inherit",height:"100%",left:0,position:"absolute",top:0,width:"100%"};function s(e,t,n,r){return n*((e=e/r-1)*e*e*e*e+1)+t}var u=Math.sqrt(2),l=Math.cos,c=Math.max,f=Math.min;function d(e){return f(e.duration,Date.now()-e.mouseDown)}function p(e){return 0<e.mouseUp?Date.now()-e.mouseUp:0}function h(e){var t=e.duration,n=e.radius,r=.85*s(d(e),0,n,t),o=.15*s(p(e),0,n,t),i=.02*n*l(Date.now()/t);return c(0,r+o+i)}function v(e,t,n){return n||f(.6*c(e,t))}function g(e,t){return s(p(e),t,-t,e.duration)}function m(e,t){return f(g(e,t),s(d(e),0,.3,3*e.duration))}function y(e,t,n){return f(1,h(e)/t*2/u)*(n/2-e.x)}function b(e,t,n){return f(1,h(e)/t*2/u)*(n/2-e.y)}function w(e){return h(e)/e.radius}var _=function(e){var t=e.mouseUp,n=e.duration;return!t||Date.now()-t<n};function x(e){var t,n=[],r=!1,o={each:function(e,t){for(var r=0,o=n.length;r<o;r++)e.call(t,n[r])},play:function(){r||(r=!0,o.update())},stop:function(){r=!1,cancelAnimationFrame(t)},getTotalOpacity:function(e){for(var t=0,r=0,o=n.length;r<o;r++)t+=m(n[r],e);return t},update:function(){(n=n.filter(_)).length?t=requestAnimationFrame(o.update):o.stop(),e()},add:function(e){n.push(e),o.play()},release:function(e){for(var t=n.length-1;0<=t;t--)if(!n[t].mouseUp)return n[t].mouseUp=e}};return o}function k(){for(var e=arguments,t={},n=0;n<arguments.length;n++){var r=e[n];if(r)for(var o in r)t[o]=r[o]}return t}var C=2*Math.PI,O={background:!0,className:"ink",duration:1e3,opacity:.25,recenter:!0,hasTouch:i},E=function(e){function t(t){e.apply(this,arguments),this.state={color:"transparent",density:1,height:0,store:x(this.tick.bind(this)),width:0},this.touchEvents=this.touchEvents()}return e&&(t.__proto__=e),((t.prototype=Object.create(e&&e.prototype)).constructor=t).prototype.touchEvents=function(){return this.props.hasTouch?{onTouchStart:this.t.bind(this),onTouchEnd:this.n.bind(this),onTouchCancel:this.n.bind(this)}:{onMouseDown:this.t.bind(this),onMouseUp:this.n.bind(this),onMouseLeave:this.n.bind(this)}},t.prototype.tick=function(){var e=this.state,t=e.ctx,n=e.color,r=e.density,o=e.height,i=e.width,a=e.store;t.save(),t.scale(r,r),t.clearRect(0,0,i,o),t.fillStyle=n,this.props.background&&(t.globalAlpha=a.getTotalOpacity(this.props.opacity),t.fillRect(0,0,i,o)),a.each(this.makeBlot,this),t.restore()},t.prototype.makeBlot=function(e){var t=this.state,n=t.ctx,r=t.height,o=t.width,i=e.x,a=e.y,s=e.radius;if(n.globalAlpha=g(e,this.props.opacity),n.beginPath(),this.props.recenter){var u=Math.max(r,o);i+=y(e,u,o),a+=b(e,u,r)}n.arc(i,a,s*w(e),0,C),n.closePath(),n.fill()},t.prototype.componentWillUnmount=function(){this.state.store.stop()},t.prototype.pushBlot=function(e,t,n){var r=this,o=this.canvas;o.getDOMNode&&"function"==typeof o.getDOMNode&&(o=o.getDOMNode());var i=o.getBoundingClientRect(),a=i.top,s=i.bottom,u=i.left,l=i.right,c=window.getComputedStyle(o).color,f=this.state.ctx||o.getContext("2d"),d=function(e){return(window.devicePixelRatio||1)/(e.webkitBackingStorePixelRatio||e.mozBackingStorePixelRatio||e.msBackingStorePixelRatio||e.oBackingStorePixelRatio||e.backingStorePixelRatio||1)}(f),p=s-a,h=l-u,g=v(p,h,this.props.radius);this.setState({color:c,ctx:f,density:d,height:p,width:h},(function(){r.state.store.add({duration:r.props.duration,mouseDown:e,mouseUp:0,radius:g,x:t-u,y:n-a})}))},t.prototype.setCanvas=function(e){this.canvas=e},t.prototype.render=function(){var e=this.state,t=e.density,n=e.height,o=e.width,i=this.props,s=i.className,u=i.style,l=k({className:s,ref:this.setCanvas.bind(this),height:n*t,width:o*t,onDragOver:this.n,style:k(a,u)},this.touchEvents);return r.createElement("canvas",l)},t.prototype.t=function(e){var t=e.button,n=e.ctrlKey,r=e.clientX,o=e.clientY,i=e.changedTouches,a=Date.now();if(i)for(var s=0;s<i.length;s++){var u=i[s],l=u.clientX,c=u.clientY;this.pushBlot(a,l,c)}else 0!==t||n||this.pushBlot(a,r,o)},t.prototype.n=function(){this.state.store.release(Date.now())},t}(r.PureComponent);E.defaultProps=O,e.exports=E},function(e,t,n){"use strict";const{default:r,DraggableCore:o}=n(332);e.exports=r,e.exports.default=r,e.exports.DraggableCore=o},function(e,t,n){"use strict";var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=n(0),a=y(i),s=n(175),u=y(n(383)),l=y(n(89)),c=y(n(40)),f=y(n(134)),d=y(n(396)),p=y(n(86)),h=y(n(186)),v=y(n(402)),g=n(125),m=n(416);function y(e){return e&&e.__esModule?e:{default:e}}function b(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var w=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));_.call(n),e.inline||console.warn("[Deprecation] The inline attribute is deprecated and will be removed in v7.x.x, please use inputFieldPosition instead.");var r=e.suggestions;return n.state={suggestions:r,query:"",isFocused:!1,selectedIndex:-1,selectionMode:!1},n.handleFocus=n.handleFocus.bind(n),n.handleBlur=n.handleBlur.bind(n),n.handleKeyDown=n.handleKeyDown.bind(n),n.handleChange=n.handleChange.bind(n),n.moveTag=n.moveTag.bind(n),n.handlePaste=n.handlePaste.bind(n),n.resetAndFocusInput=n.resetAndFocusInput.bind(n),n.handleSuggestionHover=n.handleSuggestionHover.bind(n),n.handleSuggestionClick=n.handleSuggestionClick.bind(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,[{key:"componentDidMount",value:function(){var e=this.props,t=e.autofocus,n=e.readOnly;t&&!n&&this.resetAndFocusInput()}},{key:"componentDidUpdate",value:function(e){(0,l.default)(e.suggestions,this.props.suggestions)||this.updateSuggestions()}},{key:"filteredSuggestions",value:function(e,t){var n=this;if(this.props.handleFilterSuggestions)return this.props.handleFilterSuggestions(e,t);var r=t.filter((function(t){return 0===n.getQueryIndex(e,t)})),o=t.filter((function(t){return n.getQueryIndex(e,t)>0}));return r.concat(o)}},{key:"resetAndFocusInput",value:function(){this.setState({query:""}),this.textInput&&(this.textInput.value="",this.textInput.focus())}},{key:"handleDelete",value:function(e,t){this.props.handleDelete(e,t),this.props.resetInputOnDelete?this.resetAndFocusInput():this.textInput&&this.textInput.focus(),t.stopPropagation()}},{key:"handleTagClick",value:function(e,t){this.props.handleTagClick&&this.props.handleTagClick(e,t),this.props.resetInputOnDelete?this.resetAndFocusInput():this.textInput&&this.textInput.focus()}},{key:"handleChange",value:function(e){this.props.handleInputChange&&this.props.handleInputChange(e.target.value);var t=e.target.value.trim();this.setState({query:t},this.updateSuggestions)}},{key:"handleFocus",value:function(e){var t=e.target.value;this.props.handleInputFocus&&this.props.handleInputFocus(t),this.setState({isFocused:!0})}},{key:"handleBlur",value:function(e){var t=e.target.value;this.props.handleInputBlur&&(this.props.handleInputBlur(t),this.textInput&&(this.textInput.value="")),this.setState({isFocused:!1})}},{key:"handleKeyDown",value:function(e){var t=this.state,n=t.query,r=t.selectedIndex,o=t.suggestions,i=t.selectionMode;if(e.keyCode===m.KEYS.ESCAPE&&(e.preventDefault(),e.stopPropagation(),this.setState({selectedIndex:-1,selectionMode:!1,suggestions:[]})),-1!==this.props.delimiters.indexOf(e.keyCode)&&!e.shiftKey){e.keyCode===m.KEYS.TAB&&""===n||e.preventDefault();var a=i&&-1!==r?o[r]:b({id:n},this.props.labelField,n);""!==a&&this.addTag(a)}e.keyCode===m.KEYS.BACKSPACE&&""===n&&this.props.allowDeleteFromEmptyInput&&this.handleDelete(this.props.tags.length-1,e),e.keyCode===m.KEYS.UP_ARROW&&(e.preventDefault(),this.setState({selectedIndex:r<=0?o.length-1:r-1,selectionMode:!0})),e.keyCode===m.KEYS.DOWN_ARROW&&(e.preventDefault(),this.setState({selectedIndex:0===o.length?-1:(r+1)%o.length,selectionMode:!0}))}},{key:"handlePaste",value:function(e){var t=this;if(this.props.allowAdditionFromPaste){e.preventDefault();var n=e.clipboardData||window.clipboardData,r=n.getData("text"),o=this.props.maxLength,i=void 0===o?r.length:o,a=Math.min(i,r.length),s=n.getData("text").substr(0,a),u=(0,g.buildRegExpFromDelimiters)(this.props.delimiters),l=s.split(u);(0,f.default)(l).forEach((function(e){return t.addTag(b({id:e},t.props.labelField,e))}))}}},{key:"handleSuggestionClick",value:function(e){this.addTag(this.state.suggestions[e])}},{key:"handleSuggestionHover",value:function(e){this.setState({selectedIndex:e,selectionMode:!0})}},{key:"moveTag",value:function(e,t){var n=this.props.tags[e];this.props.handleDrag(n,e,t)}},{key:"render",value:function(){var e=this,t=this.getTagItems(),n=r({},m.DEFAULT_CLASSNAMES,this.props.classNames),o=this.state.query.trim(),i=this.state.selectedIndex,s=this.state.suggestions,u=this.props,l=u.placeholder,c=u.name,f=u.id,p=u.maxLength,v=u.inline,g=u.inputFieldPosition,y=v?g:m.INPUT_FIELD_POSITIONS.BOTTOM,b=this.props.readOnly?null:a.default.createElement("div",{className:n.tagInput},a.default.createElement("input",{ref:function(t){e.textInput=t},className:n.tagInputField,type:"text",placeholder:l,"aria-label":l,onFocus:this.handleFocus,onBlur:this.handleBlur,onChange:this.handleChange,onKeyDown:this.handleKeyDown,onPaste:this.handlePaste,name:c,id:f,maxLength:p,value:this.props.inputValue}),a.default.createElement(d.default,{query:o,suggestions:s,labelField:this.props.labelField,selectedIndex:i,handleClick:this.handleSuggestionClick,handleHover:this.handleSuggestionHover,minQueryLength:this.props.minQueryLength,shouldRenderSuggestions:this.props.shouldRenderSuggestions,isFocused:this.state.isFocused,classNames:n,renderSuggestion:this.props.renderSuggestion}));return a.default.createElement("div",{className:(0,h.default)(n.tags,"react-tags-wrapper")},y===m.INPUT_FIELD_POSITIONS.TOP&&b,a.default.createElement("div",{className:n.selected},t,y===m.INPUT_FIELD_POSITIONS.INLINE&&b),y===m.INPUT_FIELD_POSITIONS.BOTTOM&&b)}}]),t}(i.Component);w.propTypes={placeholder:p.default.string,labelField:p.default.string,suggestions:p.default.arrayOf(p.default.shape({id:p.default.string.isRequired})),delimiters:p.default.arrayOf(p.default.number),autofocus:p.default.bool,inline:p.default.bool,inputFieldPosition:p.default.oneOf([m.INPUT_FIELD_POSITIONS.INLINE,m.INPUT_FIELD_POSITIONS.TOP,m.INPUT_FIELD_POSITIONS.BOTTOM]),handleDelete:p.default.func,handleAddition:p.default.func,handleDrag:p.default.func,handleFilterSuggestions:p.default.func,handleTagClick:p.default.func,allowDeleteFromEmptyInput:p.default.bool,allowAdditionFromPaste:p.default.bool,allowDragDrop:p.default.bool,resetInputOnDelete:p.default.bool,handleInputChange:p.default.func,handleInputFocus:p.default.func,handleInputBlur:p.default.func,minQueryLength:p.default.number,shouldRenderSuggestions:p.default.func,removeComponent:p.default.func,autocomplete:p.default.oneOfType([p.default.bool,p.default.number]),readOnly:p.default.bool,classNames:p.default.object,name:p.default.string,id:p.default.string,maxLength:p.default.number,inputValue:p.default.string,tags:p.default.arrayOf(p.default.shape({id:p.default.string.isRequired,className:p.default.string})),allowUnique:p.default.bool,renderSuggestion:p.default.func},w.defaultProps={placeholder:m.DEFAULT_PLACEHOLDER,labelField:m.DEFAULT_LABEL_FIELD,suggestions:[],delimiters:[m.KEYS.ENTER,m.KEYS.TAB],autofocus:!0,inline:!0,inputFieldPosition:m.INPUT_FIELD_POSITIONS.INLINE,handleDelete:c.default,handleAddition:c.default,allowDeleteFromEmptyInput:!0,allowAdditionFromPaste:!0,resetInputOnDelete:!0,autocomplete:!1,readOnly:!1,allowUnique:!0,allowDragDrop:!0,tags:[]};var _=function(){var e=this;this.getQueryIndex=function(t,n){return n[e.props.labelField].toLowerCase().indexOf(t.toLowerCase())},this.updateSuggestions=function(){var t=e.state,n=t.query,r=t.selectedIndex,o=e.filteredSuggestions(n,e.props.suggestions);e.setState({suggestions:o,selectedIndex:r>=o.length?o.length-1:r})},this.addTag=function(t){var n=e.props,r=n.tags,o=n.labelField,i=n.allowUnique;if(t.id&&t[o]){var a=r.map((function(e){return e.id.toLowerCase()}));if(!(i&&a.indexOf(t.id.toLowerCase())>=0)){if(e.props.autocomplete){var s=e.filteredSuggestions(t[o],e.props.suggestions);(1===e.props.autocomplete&&1===s.length||!0===e.props.autocomplete&&s.length)&&(t=s[0])}e.props.handleAddition(t),e.setState({query:"",selectionMode:!1,selectedIndex:-1}),e.resetAndFocusInput()}}},this.getTagItems=function(){var t=e.props,n=t.classNames,o=t.tags,i=t.labelField,s=t.removeComponent,u=t.readOnly,l=t.allowDragDrop,c=l?e.moveTag:null;return o.map((function(t,o){return a.default.createElement(v.default,{key:t.id+"-"+o,index:o,tag:t,labelField:i,onDelete:e.handleDelete.bind(e,o),moveTag:c,removeComponent:s,onTagClicked:e.handleTagClick.bind(e,o),readOnly:u,classNames:r({},m.DEFAULT_CLASSNAMES,n),allowDragDrop:l})}))}};e.exports={WithContext:(0,s.DragDropContext)(u.default)(w),WithOutContext:w,KEYS:m.KEYS}},function(e,t,n){"use strict";(function(e){function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function o(e){return(o="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)}var i,a=(i=function(e,t){return(i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0}),t.UnControlled=t.Controlled=void 0;var s,u=n(0),l="undefined"==typeof navigator||!0===e.PREVENT_CODEMIRROR_RENDER;l||(s=n(21));var c=function(){function e(){}return e.equals=function(e,t){var n=this,r=Object.keys,i=o(e),a=o(t);return e&&t&&"object"===i&&i===a?r(e).length===r(t).length&&r(e).every((function(r){return n.equals(e[r],t[r])})):e===t},e}(),f=function(){function e(e,t){this.editor=e,this.props=t}return e.prototype.delegateCursor=function(e,t,n){var r=this.editor.getDoc();n&&this.editor.focus(),t?r.setCursor(e):r.setCursor(e,null,{scroll:!1})},e.prototype.delegateScroll=function(e){this.editor.scrollTo(e.x,e.y)},e.prototype.delegateSelection=function(e,t){this.editor.getDoc().setSelections(e),t&&this.editor.focus()},e.prototype.apply=function(e){e&&e.selection&&e.selection.ranges&&this.delegateSelection(e.selection.ranges,e.selection.focus||!1),e&&e.cursor&&this.delegateCursor(e.cursor,e.autoScroll||!1,this.editor.getOption("autofocus")||!1),e&&e.scroll&&this.delegateScroll(e.scroll)},e.prototype.applyNext=function(e,t,n){e&&e.selection&&e.selection.ranges&&t&&t.selection&&t.selection.ranges&&!c.equals(e.selection.ranges,t.selection.ranges)&&this.delegateSelection(t.selection.ranges,t.selection.focus||!1),e&&e.cursor&&t&&t.cursor&&!c.equals(e.cursor,t.cursor)&&this.delegateCursor(n.cursor||t.cursor,t.autoScroll||!1,t.autoCursor||!1),e&&e.scroll&&t&&t.scroll&&!c.equals(e.scroll,t.scroll)&&this.delegateScroll(t.scroll)},e.prototype.applyUserDefined=function(e,t){t&&t.cursor&&this.delegateCursor(t.cursor,e.autoScroll||!1,this.editor.getOption("autofocus")||!1)},e.prototype.wire=function(e){var t=this;Object.keys(e||{}).filter((function(e){return/^on/.test(e)})).forEach((function(e){switch(e){case"onBlur":t.editor.on("blur",(function(e,n){t.props.onBlur(t.editor,n)}));break;case"onContextMenu":t.editor.on("contextmenu",(function(e,n){t.props.onContextMenu(t.editor,n)}));break;case"onCopy":t.editor.on("copy",(function(e,n){t.props.onCopy(t.editor,n)}));break;case"onCursor":t.editor.on("cursorActivity",(function(e){t.props.onCursor(t.editor,t.editor.getDoc().getCursor())}));break;case"onCursorActivity":t.editor.on("cursorActivity",(function(e){t.props.onCursorActivity(t.editor)}));break;case"onCut":t.editor.on("cut",(function(e,n){t.props.onCut(t.editor,n)}));break;case"onDblClick":t.editor.on("dblclick",(function(e,n){t.props.onDblClick(t.editor,n)}));break;case"onDragEnter":t.editor.on("dragenter",(function(e,n){t.props.onDragEnter(t.editor,n)}));break;case"onDragLeave":t.editor.on("dragleave",(function(e,n){t.props.onDragLeave(t.editor,n)}));break;case"onDragOver":t.editor.on("dragover",(function(e,n){t.props.onDragOver(t.editor,n)}));break;case"onDragStart":t.editor.on("dragstart",(function(e,n){t.props.onDragStart(t.editor,n)}));break;case"onDrop":t.editor.on("drop",(function(e,n){t.props.onDrop(t.editor,n)}));break;case"onFocus":t.editor.on("focus",(function(e,n){t.props.onFocus(t.editor,n)}));break;case"onGutterClick":t.editor.on("gutterClick",(function(e,n,r,o){t.props.onGutterClick(t.editor,n,r,o)}));break;case"onInputRead":t.editor.on("inputRead",(function(e,n){t.props.onInputRead(t.editor,n)}));break;case"onKeyDown":t.editor.on("keydown",(function(e,n){t.props.onKeyDown(t.editor,n)}));break;case"onKeyHandled":t.editor.on("keyHandled",(function(e,n,r){t.props.onKeyHandled(t.editor,n,r)}));break;case"onKeyPress":t.editor.on("keypress",(function(e,n){t.props.onKeyPress(t.editor,n)}));break;case"onKeyUp":t.editor.on("keyup",(function(e,n){t.props.onKeyUp(t.editor,n)}));break;case"onMouseDown":t.editor.on("mousedown",(function(e,n){t.props.onMouseDown(t.editor,n)}));break;case"onPaste":t.editor.on("paste",(function(e,n){t.props.onPaste(t.editor,n)}));break;case"onRenderLine":t.editor.on("renderLine",(function(e,n,r){t.props.onRenderLine(t.editor,n,r)}));break;case"onScroll":t.editor.on("scroll",(function(e){t.props.onScroll(t.editor,t.editor.getScrollInfo())}));break;case"onSelection":t.editor.on("beforeSelectionChange",(function(e,n){t.props.onSelection(t.editor,n)}));break;case"onTouchStart":t.editor.on("touchstart",(function(e,n){t.props.onTouchStart(t.editor,n)}));break;case"onUpdate":t.editor.on("update",(function(e){t.props.onUpdate(t.editor)}));break;case"onViewportChange":t.editor.on("viewportChange",(function(e,n,r){t.props.onViewportChange(t.editor,n,r)}))}}))},e}(),d=function(e){function t(t){var n=e.call(this,t)||this;return l||(n.applied=!1,n.appliedNext=!1,n.appliedUserDefined=!1,n.deferred=null,n.emulating=!1,n.hydrated=!1,n.initCb=function(){n.props.editorDidConfigure&&n.props.editorDidConfigure(n.editor)},n.mounted=!1),n}return a(t,e),t.prototype.hydrate=function(e){var t=this,n=e&&e.options?e.options:{},o=r({},s.defaults,this.editor.options,n);Object.keys(o).some((function(e){return t.editor.getOption(e)!==o[e]}))&&Object.keys(o).forEach((function(e){n.hasOwnProperty(e)&&t.editor.getOption(e)!==o[e]&&(t.editor.setOption(e,o[e]),t.mirror.setOption(e,o[e]))})),this.hydrated||(this.deferred?this.resolveChange(e.value):this.initChange(e.value||"")),this.hydrated=!0},t.prototype.initChange=function(e){this.emulating=!0;var t=this.editor.getDoc(),n=t.lastLine(),r=t.getLine(t.lastLine()).length;t.replaceRange(e||"",{line:0,ch:0},{line:n,ch:r}),this.mirror.setValue(e),t.clearHistory(),this.mirror.clearHistory(),this.emulating=!1},t.prototype.resolveChange=function(e){this.emulating=!0;var t=this.editor.getDoc();if("undo"===this.deferred.origin?t.undo():"redo"===this.deferred.origin?t.redo():t.replaceRange(this.deferred.text,this.deferred.from,this.deferred.to,this.deferred.origin),e&&e!==t.getValue()){var n=t.getCursor();t.setValue(e),t.setCursor(n)}this.emulating=!1,this.deferred=null},t.prototype.mirrorChange=function(e){var t=this.editor.getDoc();return"undo"===e.origin?(t.setHistory(this.mirror.getHistory()),this.mirror.undo()):"redo"===e.origin?(t.setHistory(this.mirror.getHistory()),this.mirror.redo()):this.mirror.replaceRange(e.text,e.from,e.to,e.origin),this.mirror.getValue()},t.prototype.componentDidMount=function(){var e=this;l||(this.props.defineMode&&this.props.defineMode.name&&this.props.defineMode.fn&&s.defineMode(this.props.defineMode.name,this.props.defineMode.fn),this.editor=s(this.ref,this.props.options),this.shared=new f(this.editor,this.props),this.mirror=s((function(){}),this.props.options),this.editor.on("electricInput",(function(){e.mirror.setHistory(e.editor.getDoc().getHistory())})),this.editor.on("cursorActivity",(function(){e.mirror.setCursor(e.editor.getDoc().getCursor())})),this.editor.on("beforeChange",(function(t,n){if(!e.emulating){n.cancel(),e.deferred=n;var r=e.mirrorChange(e.deferred);e.props.onBeforeChange&&e.props.onBeforeChange(e.editor,e.deferred,r)}})),this.editor.on("change",(function(t,n){e.mounted&&e.props.onChange&&e.props.onChange(e.editor,n,e.editor.getValue())})),this.hydrate(this.props),this.shared.apply(this.props),this.applied=!0,this.mounted=!0,this.shared.wire(this.props),this.editor.getOption("autofocus")&&this.editor.focus(),this.props.editorDidMount&&this.props.editorDidMount(this.editor,this.editor.getValue(),this.initCb))},t.prototype.componentDidUpdate=function(e){if(!l){var t={cursor:null};this.props.value!==e.value&&(this.hydrated=!1),this.props.autoCursor||void 0===this.props.autoCursor||(t.cursor=this.editor.getDoc().getCursor()),this.hydrate(this.props),this.appliedNext||(this.shared.applyNext(e,this.props,t),this.appliedNext=!0),this.shared.applyUserDefined(e,t),this.appliedUserDefined=!0}},t.prototype.componentWillUnmount=function(){l||this.props.editorWillUnmount&&this.props.editorWillUnmount(s)},t.prototype.shouldComponentUpdate=function(e,t){return!l},t.prototype.render=function(){var e=this;if(l)return null;var t=this.props.className?"react-codemirror2 "+this.props.className:"react-codemirror2";return u.createElement("div",{className:t,ref:function(t){return e.ref=t}})},t}(u.Component);t.Controlled=d;var p=function(e){function t(t){var n=e.call(this,t)||this;return l||(n.applied=!1,n.appliedUserDefined=!1,n.continueChange=!1,n.detached=!1,n.hydrated=!1,n.initCb=function(){n.props.editorDidConfigure&&n.props.editorDidConfigure(n.editor)},n.mounted=!1,n.onBeforeChangeCb=function(){n.continueChange=!0}),n}return a(t,e),t.prototype.hydrate=function(e){var t=this,n=e&&e.options?e.options:{},o=r({},s.defaults,this.editor.options,n);if(Object.keys(o).some((function(e){return t.editor.getOption(e)!==o[e]}))&&Object.keys(o).forEach((function(e){n.hasOwnProperty(e)&&t.editor.getOption(e)!==o[e]&&t.editor.setOption(e,o[e])})),!this.hydrated){var i=this.editor.getDoc(),a=i.lastLine(),u=i.getLine(i.lastLine()).length;i.replaceRange(e.value||"",{line:0,ch:0},{line:a,ch:u})}this.hydrated=!0},t.prototype.componentDidMount=function(){var e=this;l||(this.detached=!0===this.props.detach,this.props.defineMode&&this.props.defineMode.name&&this.props.defineMode.fn&&s.defineMode(this.props.defineMode.name,this.props.defineMode.fn),this.editor=s(this.ref,this.props.options),this.shared=new f(this.editor,this.props),this.editor.on("beforeChange",(function(t,n){e.props.onBeforeChange&&e.props.onBeforeChange(e.editor,n,e.editor.getValue(),e.onBeforeChangeCb)})),this.editor.on("change",(function(t,n){e.mounted&&e.props.onChange&&(e.props.onBeforeChange?e.continueChange&&e.props.onChange(e.editor,n,e.editor.getValue()):e.props.onChange(e.editor,n,e.editor.getValue()))})),this.hydrate(this.props),this.shared.apply(this.props),this.applied=!0,this.mounted=!0,this.shared.wire(this.props),this.editor.getDoc().clearHistory(),this.props.editorDidMount&&this.props.editorDidMount(this.editor,this.editor.getValue(),this.initCb))},t.prototype.componentDidUpdate=function(e){if(this.detached&&!1===this.props.detach&&(this.detached=!1,e.editorDidAttach&&e.editorDidAttach(this.editor)),this.detached||!0!==this.props.detach||(this.detached=!0,e.editorDidDetach&&e.editorDidDetach(this.editor)),!l&&!this.detached){var t={cursor:null};this.props.value!==e.value&&(this.hydrated=!1,this.applied=!1,this.appliedUserDefined=!1),e.autoCursor||void 0===e.autoCursor||(t.cursor=this.editor.getDoc().getCursor()),this.hydrate(this.props),this.applied||(this.shared.apply(e),this.applied=!0),this.appliedUserDefined||(this.shared.applyUserDefined(e,t),this.appliedUserDefined=!0)}},t.prototype.componentWillUnmount=function(){l||this.props.editorWillUnmount&&this.props.editorWillUnmount(s)},t.prototype.shouldComponentUpdate=function(e,t){var n=!0;return l&&(n=!1),this.detached&&e.detach&&(n=!1),n},t.prototype.render=function(){var e=this;if(l)return null;var t=this.props.className?"react-codemirror2 "+this.props.className:"react-codemirror2";return u.createElement("div",{className:t,ref:function(t){return e.ref=t}})},t}(u.Component);t.UnControlled=p}).call(this,n(31))},function(e,t,n){var r=n(39),o=n(33);e.exports=function(e){return"number"==typeof e||o(e)&&"[object Number]"==r(e)}},function(e,t,n){var r=n(425);e.exports=function(e,t,n){return null==e?e:r(e,t,n)}},function(e,t,n){var r=n(109),o=n(428);e.exports=function(e,t){var n=[];if(!e||!e.length)return n;var i=-1,a=[],s=e.length;for(t=r(t,3);++i<s;){var u=e[i];t(u,i,e)&&(n.push(u),a.push(i))}return o(e,a),n}},function(e,t,n){var r=n(81);e.exports=function(e,t){return t="function"==typeof t?t:void 0,e&&e.length?r(e,void 0,t):[]}},function(e,t,n){ /*! CSSLint v1.0.4 Copyright (c) 2016 Nicole Sullivan and Nicholas C. Zakas. All rights reserved. Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ var r=n(449),o=n(454),i=function(){"use strict";var e=[],t=[],n=/\/\*\s*csslint([^\*]*)\*\//,s=new o.util.EventTarget;return s.version="1.0.4",s.addRule=function(t){e.push(t),e[t.id]=t},s.clearRules=function(){e=[]},s.getRules=function(){return[].concat(e).sort((function(e,t){return e.id>t.id?1:0}))},s.getRuleset=function(){for(var t={},n=0,r=e.length;n<r;)t[e[n++].id]=1;return t},s.addFormatter=function(e){t[e.id]=e},s.getFormatter=function(e){return t[e]},s.format=function(e,t,n,r){var o=this.getFormatter(n),i=null;return o&&(i=o.startFormat(),i+=o.formatResults(e,t,r||{}),i+=o.endFormat()),i},s.hasFormat=function(e){return t.hasOwnProperty(e)},s.verify=function(t,s){var u,l,c,f=0,d={},p=[],h=new o.css.Parser({starHack:!0,ieFilters:!0,underscoreHack:!0,strict:!1});l=t.replace(/\n\r?/g,"$split$").split("$split$"),i.Util.forEach(l,(function(e,t){var n=e&&e.match(/\/\*[ \t]*csslint[ \t]+allow:[ \t]*([^\*]*)\*\//i),r=n&&n[1],o={};r&&(r.toLowerCase().split(",").forEach((function(e){o[e.trim()]=!0})),Object.keys(o).length>0&&(d[t+1]=o))}));var v=null,g=null;for(f in i.Util.forEach(l,(function(e,t){null===v&&e.match(/\/\*[ \t]*csslint[ \t]+ignore:start[ \t]*\*\//i)&&(v=t),e.match(/\/\*[ \t]*csslint[ \t]+ignore:end[ \t]*\*\//i)&&(g=t),null!==v&&null!==g&&(p.push([v,g]),v=g=null)})),null!==v&&p.push([v,l.length]),s||(s=this.getRuleset()),n.test(t)&&(s=function(e,t){var r,o=e&&e.match(n),i=o&&o[1];return i&&(r={true:2,"":1,false:0,2:2,1:1,0:0},i.toLowerCase().split(",").forEach((function(e){var n=e.split(":"),o=n[0]||"",i=n[1]||"";t[o.trim()]=r[i.trim()]}))),t}(t,s=r(s))),u=new a(l,s,d,p),s.errors=2,s)s.hasOwnProperty(f)&&s[f]&&e[f]&&e[f].init(h,u);try{h.parse(t)}catch(e){u.error("Fatal error, cannot continue: "+e.message,e.line,e.col,{})}return(c={messages:u.messages,stats:u.stats,ruleset:u.ruleset,allow:u.allow,ignore:u.ignore}).messages.sort((function(e,t){return e.rollup&&!t.rollup?1:!e.rollup&&t.rollup?-1:e.line-t.line})),c},s}();function a(e,t,n,r){"use strict";this.messages=[],this.stats=[],this.lines=e,this.ruleset=t,this.allow=n,this.allow||(this.allow={}),this.ignore=r,this.ignore||(this.ignore=[])}a.prototype={constructor:a,error:function(e,t,n,r){"use strict";this.messages.push({type:"error",line:t,col:n,message:e,evidence:this.lines[t-1],rule:r||{}})},warn:function(e,t,n,r){"use strict";this.report(e,t,n,r)},report:function(e,t,n,r){"use strict";if(!this.allow.hasOwnProperty(t)||!this.allow[t].hasOwnProperty(r.id)){var o=!1;i.Util.forEach(this.ignore,(function(e){e[0]<=t&&t<=e[1]&&(o=!0)})),o||this.messages.push({type:2===this.ruleset[r.id]?"error":"warning",line:t,col:n,message:e,evidence:this.lines[t-1],rule:r})}},info:function(e,t,n,r){"use strict";this.messages.push({type:"info",line:t,col:n,message:e,evidence:this.lines[t-1],rule:r})},rollupError:function(e,t){"use strict";this.messages.push({type:"error",rollup:!0,message:e,rule:t})},rollupWarn:function(e,t){"use strict";this.messages.push({type:"warning",rollup:!0,message:e,rule:t})},stat:function(e,t){"use strict";this.stats[e]=t}},i._Reporter=a,i.Util={mix:function(e,t){"use strict";var n;for(n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return n},indexOf:function(e,t){"use strict";if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},forEach:function(e,t){"use strict";if(e.forEach)return e.forEach(t);for(var n=0,r=e.length;n<r;n++)t(e[n],n,e)}},i.addRule({id:"adjoining-classes",name:"Disallow adjoining classes",desc:"Don't use adjoining classes.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-adjoining-classes",browsers:"IE6",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(r){var o,i,a,s,u,l,c=r.selectors;for(s=0;s<c.length;s++)for(o=c[s],u=0;u<o.parts.length;u++)if((i=o.parts[u]).type===e.SELECTOR_PART_TYPE)for(a=0,l=0;l<i.modifiers.length;l++)"class"===i.modifiers[l].type&&a++,a>1&&t.report("Adjoining classes: "+c[s].text,i.line,i.col,n)}))}}),i.addRule({id:"box-model",name:"Beware of broken box size",desc:"Don't use width or height when using padding or border.",url:"https://github.com/CSSLint/csslint/wiki/Beware-of-box-model-size",browsers:"All",init:function(e,t){"use strict";var n,r=this,o={border:1,"border-left":1,"border-right":1,padding:1,"padding-left":1,"padding-right":1},i={border:1,"border-bottom":1,"border-top":1,padding:1,"padding-bottom":1,"padding-top":1},a=!1;function s(){n={},a=!1}function u(){var e,s;if(!a){if(n.height)for(e in i)i.hasOwnProperty(e)&&n[e]&&(s=n[e].value,"padding"===e&&2===s.parts.length&&0===s.parts[0].value||t.report("Using height with "+e+" can sometimes make elements larger than you expect.",n[e].line,n[e].col,r));if(n.width)for(e in o)o.hasOwnProperty(e)&&n[e]&&(s=n[e].value,"padding"===e&&2===s.parts.length&&0===s.parts[1].value||t.report("Using width with "+e+" can sometimes make elements larger than you expect.",n[e].line,n[e].col,r))}}e.addListener("startrule",s),e.addListener("startfontface",s),e.addListener("startpage",s),e.addListener("startpagemargin",s),e.addListener("startkeyframerule",s),e.addListener("startviewport",s),e.addListener("property",(function(e){var t=e.property.text.toLowerCase();i[t]||o[t]?/^0\S*$/.test(e.value)||"border"===t&&"none"===e.value.toString()||(n[t]={line:e.property.line,col:e.property.col,value:e.value}):/^(width|height)/i.test(t)&&/^(length|percentage)/.test(e.value.parts[0].type)?n[t]=1:"box-sizing"===t&&(a=!0)})),e.addListener("endrule",u),e.addListener("endfontface",u),e.addListener("endpage",u),e.addListener("endpagemargin",u),e.addListener("endkeyframerule",u),e.addListener("endviewport",u)}}),i.addRule({id:"box-sizing",name:"Disallow use of box-sizing",desc:"The box-sizing properties isn't supported in IE6 and IE7.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-box-sizing",browsers:"IE6, IE7",tags:["Compatibility"],init:function(e,t){"use strict";var n=this;e.addListener("property",(function(e){"box-sizing"===e.property.text.toLowerCase()&&t.report("The box-sizing property isn't supported in IE6 and IE7.",e.line,e.col,n)}))}}),i.addRule({id:"bulletproof-font-face",name:"Use the bulletproof @font-face syntax",desc:"Use the bulletproof @font-face syntax to avoid 404's in old IE (http://www.fontspring.com/blog/the-new-bulletproof-font-face-syntax).",url:"https://github.com/CSSLint/csslint/wiki/Bulletproof-font-face",browsers:"All",init:function(e,t){"use strict";var n,r,o=this,i=!1,a=!0,s=!1;e.addListener("startfontface",(function(){i=!0})),e.addListener("property",(function(e){if(i){var t=e.property.toString().toLowerCase(),o=e.value.toString();if(n=e.line,r=e.col,"src"===t){var u=/^\s?url\(['"].+\.eot\?.*['"]\)\s*format\(['"]embedded-opentype['"]\).*$/i;!o.match(u)&&a?(s=!0,a=!1):o.match(u)&&!a&&(s=!1)}}})),e.addListener("endfontface",(function(){i=!1,s&&t.report("@font-face declaration doesn't follow the fontspring bulletproof syntax.",n,r,o)}))}}),i.addRule({id:"compatible-vendor-prefixes",name:"Require compatible vendor prefixes",desc:"Include all compatible vendor prefixes to reach a wider range of users.",url:"https://github.com/CSSLint/csslint/wiki/Require-compatible-vendor-prefixes",browsers:"All",init:function(e,t){"use strict";var n,r,o,a,s,u,l,c=this,f=!1,d=Array.prototype.push,p=[];for(o in n={animation:"webkit","animation-delay":"webkit","animation-direction":"webkit","animation-duration":"webkit","animation-fill-mode":"webkit","animation-iteration-count":"webkit","animation-name":"webkit","animation-play-state":"webkit","animation-timing-function":"webkit",appearance:"webkit moz","border-end":"webkit moz","border-end-color":"webkit moz","border-end-style":"webkit moz","border-end-width":"webkit moz","border-image":"webkit moz o","border-radius":"webkit","border-start":"webkit moz","border-start-color":"webkit moz","border-start-style":"webkit moz","border-start-width":"webkit moz","box-align":"webkit moz ms","box-direction":"webkit moz ms","box-flex":"webkit moz ms","box-lines":"webkit ms","box-ordinal-group":"webkit moz ms","box-orient":"webkit moz ms","box-pack":"webkit moz ms","box-sizing":"","box-shadow":"","column-count":"webkit moz ms","column-gap":"webkit moz ms","column-rule":"webkit moz ms","column-rule-color":"webkit moz ms","column-rule-style":"webkit moz ms","column-rule-width":"webkit moz ms","column-width":"webkit moz ms",hyphens:"epub moz","line-break":"webkit ms","margin-end":"webkit moz","margin-start":"webkit moz","marquee-speed":"webkit wap","marquee-style":"webkit wap","padding-end":"webkit moz","padding-start":"webkit moz","tab-size":"moz o","text-size-adjust":"webkit ms",transform:"webkit ms","transform-origin":"webkit ms",transition:"","transition-delay":"","transition-duration":"","transition-property":"","transition-timing-function":"","user-modify":"webkit moz","user-select":"webkit moz ms","word-break":"epub ms","writing-mode":"epub ms"})if(n.hasOwnProperty(o)){for(a=[],u=0,l=(s=n[o].split(" ")).length;u<l;u++)a.push("-"+s[u]+"-"+o);n[o]=a,d.apply(p,a)}e.addListener("startrule",(function(){r=[]})),e.addListener("startkeyframes",(function(e){f=e.prefix||!0})),e.addListener("endkeyframes",(function(){f=!1})),e.addListener("property",(function(e){var t=e.property;i.Util.indexOf(p,t.text)>-1&&(f&&"string"==typeof f&&0===t.text.indexOf("-"+f+"-")||r.push(t))})),e.addListener("endrule",(function(){if(r.length){var e,o,a,s,u,l,f,d,p,h,v={};for(e=0,o=r.length;e<o;e++)for(s in a=r[e],n)n.hasOwnProperty(s)&&(u=n[s],i.Util.indexOf(u,a.text)>-1&&(v[s]||(v[s]={full:u.slice(0),actual:[],actualNodes:[]}),-1===i.Util.indexOf(v[s].actual,a.text)&&(v[s].actual.push(a.text),v[s].actualNodes.push(a))));for(s in v)if(v.hasOwnProperty(s)&&(f=(l=v[s]).full,d=l.actual,f.length>d.length))for(e=0,o=f.length;e<o;e++)p=f[e],-1===i.Util.indexOf(d,p)&&(h=1===d.length?d[0]:2===d.length?d.join(" and "):d.join(", "),t.report("The property "+p+" is compatible with "+h+" and should be included as well.",l.actualNodes[0].line,l.actualNodes[0].col,c))}}))}}),i.addRule({id:"display-property-grouping",name:"Require properties appropriate for display",desc:"Certain properties shouldn't be used with certain display property values.",url:"https://github.com/CSSLint/csslint/wiki/Require-properties-appropriate-for-display",browsers:"All",init:function(e,t){"use strict";var n,r=this,o={display:1,float:"none",height:1,width:1,margin:1,"margin-left":1,"margin-right":1,"margin-bottom":1,"margin-top":1,padding:1,"padding-left":1,"padding-right":1,"padding-bottom":1,"padding-top":1,"vertical-align":1};function i(e,i,a){n[e]&&("string"==typeof o[e]&&n[e].value.toLowerCase()===o[e]||t.report(a||e+" can't be used with display: "+i+".",n[e].line,n[e].col,r))}function a(){n={}}function s(){var e=n.display?n.display.value:null;if(e)switch(e){case"inline":i("height",e),i("width",e),i("margin",e),i("margin-top",e),i("margin-bottom",e),i("float",e,"display:inline has no effect on floated elements (but may be used to fix the IE6 double-margin bug).");break;case"block":i("vertical-align",e);break;case"inline-block":i("float",e);break;default:0===e.indexOf("table-")&&(i("margin",e),i("margin-left",e),i("margin-right",e),i("margin-top",e),i("margin-bottom",e),i("float",e))}}e.addListener("startrule",a),e.addListener("startfontface",a),e.addListener("startkeyframerule",a),e.addListener("startpagemargin",a),e.addListener("startpage",a),e.addListener("startviewport",a),e.addListener("property",(function(e){var t=e.property.text.toLowerCase();o[t]&&(n[t]={value:e.value.text,line:e.property.line,col:e.property.col})})),e.addListener("endrule",s),e.addListener("endfontface",s),e.addListener("endkeyframerule",s),e.addListener("endpagemargin",s),e.addListener("endpage",s),e.addListener("endviewport",s)}}),i.addRule({id:"duplicate-background-images",name:"Disallow duplicate background images",desc:"Every background-image should be unique. Use a common class for e.g. sprites.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-duplicate-background-images",browsers:"All",init:function(e,t){"use strict";var n=this,r={};e.addListener("property",(function(e){var o,i,a=e.property.text,s=e.value;if(a.match(/background/i))for(o=0,i=s.parts.length;o<i;o++)"uri"===s.parts[o].type&&(void 0===r[s.parts[o].uri]?r[s.parts[o].uri]=e:t.report("Background image '"+s.parts[o].uri+"' was used multiple times, first declared at line "+r[s.parts[o].uri].line+", col "+r[s.parts[o].uri].col+".",e.line,e.col,n))}))}}),i.addRule({id:"duplicate-properties",name:"Disallow duplicate properties",desc:"Duplicate properties must appear one after the other.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-duplicate-properties",browsers:"All",init:function(e,t){"use strict";var n,r,o=this;function i(){n={}}e.addListener("startrule",i),e.addListener("startfontface",i),e.addListener("startpage",i),e.addListener("startpagemargin",i),e.addListener("startkeyframerule",i),e.addListener("startviewport",i),e.addListener("property",(function(e){var i=e.property.text.toLowerCase();!n[i]||r===i&&n[i]!==e.value.text||t.report("Duplicate property '"+e.property+"' found.",e.line,e.col,o),n[i]=e.value.text,r=i}))}}),i.addRule({id:"empty-rules",name:"Disallow empty rules",desc:"Rules without any properties specified should be removed.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-empty-rules",browsers:"All",init:function(e,t){"use strict";var n=this,r=0;e.addListener("startrule",(function(){r=0})),e.addListener("property",(function(){r++})),e.addListener("endrule",(function(e){var o=e.selectors;0===r&&t.report("Rule is empty.",o[0].line,o[0].col,n)}))}}),i.addRule({id:"errors",name:"Parsing Errors",desc:"This rule looks for recoverable syntax errors.",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("error",(function(e){t.error(e.message,e.line,e.col,n)}))}}),i.addRule({id:"fallback-colors",name:"Require fallback colors",desc:"For older browsers that don't support RGBA, HSL, or HSLA, provide a fallback color.",url:"https://github.com/CSSLint/csslint/wiki/Require-fallback-colors",browsers:"IE6,IE7,IE8",init:function(e,t){"use strict";var n,r=this,o={color:1,background:1,"border-color":1,"border-top-color":1,"border-right-color":1,"border-bottom-color":1,"border-left-color":1,border:1,"border-top":1,"border-right":1,"border-bottom":1,"border-left":1,"background-color":1};function i(){n=null}e.addListener("startrule",i),e.addListener("startfontface",i),e.addListener("startpage",i),e.addListener("startpagemargin",i),e.addListener("startkeyframerule",i),e.addListener("startviewport",i),e.addListener("property",(function(e){var i=e.property.text.toLowerCase(),a=e.value.parts,s=0,u="",l=a.length;if(o[i])for(;s<l;)"color"===a[s].type&&("alpha"in a[s]||"hue"in a[s]?(/([^\)]+)\(/.test(a[s])&&(u=RegExp.$1.toUpperCase()),n&&n.property.text.toLowerCase()===i&&"compat"===n.colorType||t.report("Fallback "+i+" (hex or RGB) should precede "+u+" "+i+".",e.line,e.col,r)):e.colorType="compat"),s++;n=e}))}}),i.addRule({id:"floats",name:"Disallow too many floats",desc:"This rule tests if the float property is used too many times",url:"https://github.com/CSSLint/csslint/wiki/Disallow-too-many-floats",browsers:"All",init:function(e,t){"use strict";var n=this,r=0;e.addListener("property",(function(e){"float"===e.property.text.toLowerCase()&&"none"!==e.value.text.toLowerCase()&&r++})),e.addListener("endstylesheet",(function(){t.stat("floats",r),r>=10&&t.rollupWarn("Too many floats ("+r+"), you're probably using them for layout. Consider using a grid system instead.",n)}))}}),i.addRule({id:"font-faces",name:"Don't use too many web fonts",desc:"Too many different web fonts in the same stylesheet.",url:"https://github.com/CSSLint/csslint/wiki/Don%27t-use-too-many-web-fonts",browsers:"All",init:function(e,t){"use strict";var n=this,r=0;e.addListener("startfontface",(function(){r++})),e.addListener("endstylesheet",(function(){r>5&&t.rollupWarn("Too many @font-face declarations ("+r+").",n)}))}}),i.addRule({id:"font-sizes",name:"Disallow too many font sizes",desc:"Checks the number of font-size declarations.",url:"https://github.com/CSSLint/csslint/wiki/Don%27t-use-too-many-font-size-declarations",browsers:"All",init:function(e,t){"use strict";var n=this,r=0;e.addListener("property",(function(e){"font-size"===e.property.toString()&&r++})),e.addListener("endstylesheet",(function(){t.stat("font-sizes",r),r>=10&&t.rollupWarn("Too many font-size declarations ("+r+"), abstraction needed.",n)}))}}),i.addRule({id:"gradients",name:"Require all gradient definitions",desc:"When using a vendor-prefixed gradient, make sure to use them all.",url:"https://github.com/CSSLint/csslint/wiki/Require-all-gradient-definitions",browsers:"All",init:function(e,t){"use strict";var n,r=this;e.addListener("startrule",(function(){n={moz:0,webkit:0,oldWebkit:0,o:0}})),e.addListener("property",(function(e){/\-(moz|o|webkit)(?:\-(?:linear|radial))\-gradient/i.test(e.value)?n[RegExp.$1]=1:/\-webkit\-gradient/i.test(e.value)&&(n.oldWebkit=1)})),e.addListener("endrule",(function(e){var o=[];n.moz||o.push("Firefox 3.6+"),n.webkit||o.push("Webkit (Safari 5+, Chrome)"),n.oldWebkit||o.push("Old Webkit (Safari 4+, Chrome)"),n.o||o.push("Opera 11.1+"),o.length&&o.length<4&&t.report("Missing vendor-prefixed CSS gradients for "+o.join(", ")+".",e.selectors[0].line,e.selectors[0].col,r)}))}}),i.addRule({id:"ids",name:"Disallow IDs in selectors",desc:"Selectors should not contain IDs.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-IDs-in-selectors",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(r){var o,i,a,s,u,l,c=r.selectors;for(s=0;s<c.length;s++){for(o=c[s],a=0,u=0;u<o.parts.length;u++)if((i=o.parts[u]).type===e.SELECTOR_PART_TYPE)for(l=0;l<i.modifiers.length;l++)"id"===i.modifiers[l].type&&a++;1===a?t.report("Don't use IDs in selectors.",o.line,o.col,n):a>1&&t.report(a+" IDs in the selector, really?",o.line,o.col,n)}}))}}),i.addRule({id:"import-ie-limit",name:"@import limit on IE6-IE9",desc:"IE6-9 supports up to 31 @import per stylesheet",browsers:"IE6, IE7, IE8, IE9",init:function(e,t){"use strict";var n=this,r=0;e.addListener("startpage",(function(){r=0})),e.addListener("import",(function(){r++})),e.addListener("endstylesheet",(function(){r>31&&t.rollupError("Too many @import rules ("+r+"). IE6-9 supports up to 31 import per stylesheet.",n)}))}}),i.addRule({id:"import",name:"Disallow @import",desc:"Don't use @import, use <link> instead.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-%40import",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("import",(function(e){t.report("@import prevents parallel downloads, use <link> instead.",e.line,e.col,n)}))}}),i.addRule({id:"important",name:"Disallow !important",desc:"Be careful when using !important declaration",url:"https://github.com/CSSLint/csslint/wiki/Disallow-%21important",browsers:"All",init:function(e,t){"use strict";var n=this,r=0;e.addListener("property",(function(e){!0===e.important&&(r++,t.report("Use of !important",e.line,e.col,n))})),e.addListener("endstylesheet",(function(){t.stat("important",r),r>=10&&t.rollupWarn("Too many !important declarations ("+r+"), try to use less than 10 to avoid specificity issues.",n)}))}}),i.addRule({id:"known-properties",name:"Require use of known properties",desc:"Properties should be known (listed in CSS3 specification) or be a vendor-prefixed property.",url:"https://github.com/CSSLint/csslint/wiki/Require-use-of-known-properties",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("property",(function(e){e.invalid&&t.report(e.invalid.message,e.line,e.col,n)}))}}),i.addRule({id:"order-alphabetical",name:"Alphabetical order",desc:"Assure properties are in alphabetical order",browsers:"All",init:function(e,t){"use strict";var n,r=this,o=function(){n=[]},i=function(e){n.join(",")!==n.sort().join(",")&&t.report("Rule doesn't have all its properties in alphabetical order.",e.line,e.col,r)};e.addListener("startrule",o),e.addListener("startfontface",o),e.addListener("startpage",o),e.addListener("startpagemargin",o),e.addListener("startkeyframerule",o),e.addListener("startviewport",o),e.addListener("property",(function(e){var t=e.property.text.toLowerCase().replace(/^-.*?-/,"");n.push(t)})),e.addListener("endrule",i),e.addListener("endfontface",i),e.addListener("endpage",i),e.addListener("endpagemargin",i),e.addListener("endkeyframerule",i),e.addListener("endviewport",i)}}),i.addRule({id:"outline-none",name:"Disallow outline: none",desc:"Use of outline: none or outline: 0 should be limited to :focus rules.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-outline%3Anone",browsers:"All",tags:["Accessibility"],init:function(e,t){"use strict";var n,r=this;function o(e){n=e.selectors?{line:e.line,col:e.col,selectors:e.selectors,propCount:0,outline:!1}:null}function i(){n&&n.outline&&(-1===n.selectors.toString().toLowerCase().indexOf(":focus")?t.report("Outlines should only be modified using :focus.",n.line,n.col,r):1===n.propCount&&t.report("Outlines shouldn't be hidden unless other visual changes are made.",n.line,n.col,r))}e.addListener("startrule",o),e.addListener("startfontface",o),e.addListener("startpage",o),e.addListener("startpagemargin",o),e.addListener("startkeyframerule",o),e.addListener("startviewport",o),e.addListener("property",(function(e){var t=e.property.text.toLowerCase(),r=e.value;n&&(n.propCount++,"outline"!==t||"none"!==r.toString()&&"0"!==r.toString()||(n.outline=!0))})),e.addListener("endrule",i),e.addListener("endfontface",i),e.addListener("endpage",i),e.addListener("endpagemargin",i),e.addListener("endkeyframerule",i),e.addListener("endviewport",i)}}),i.addRule({id:"overqualified-elements",name:"Disallow overqualified elements",desc:"Don't use classes or IDs with elements (a.foo or a#foo).",url:"https://github.com/CSSLint/csslint/wiki/Disallow-overqualified-elements",browsers:"All",init:function(e,t){"use strict";var n=this,r={};e.addListener("startrule",(function(o){var i,a,s,u,l,c,f=o.selectors;for(u=0;u<f.length;u++)for(i=f[u],l=0;l<i.parts.length;l++)if((a=i.parts[l]).type===e.SELECTOR_PART_TYPE)for(c=0;c<a.modifiers.length;c++)s=a.modifiers[c],a.elementName&&"id"===s.type?t.report("Element ("+a+") is overqualified, just use "+s+" without element name.",a.line,a.col,n):"class"===s.type&&(r[s]||(r[s]=[]),r[s].push({modifier:s,part:a}))})),e.addListener("endstylesheet",(function(){var e;for(e in r)r.hasOwnProperty(e)&&1===r[e].length&&r[e][0].part.elementName&&t.report("Element ("+r[e][0].part+") is overqualified, just use "+r[e][0].modifier+" without element name.",r[e][0].part.line,r[e][0].part.col,n)}))}}),i.addRule({id:"qualified-headings",name:"Disallow qualified headings",desc:"Headings should not be qualified (namespaced).",url:"https://github.com/CSSLint/csslint/wiki/Disallow-qualified-headings",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(r){var o,i,a,s,u=r.selectors;for(a=0;a<u.length;a++)for(o=u[a],s=0;s<o.parts.length;s++)(i=o.parts[s]).type===e.SELECTOR_PART_TYPE&&i.elementName&&/h[1-6]/.test(i.elementName.toString())&&s>0&&t.report("Heading ("+i.elementName+") should not be qualified.",i.line,i.col,n)}))}}),i.addRule({id:"regex-selectors",name:"Disallow selectors that look like regexs",desc:"Selectors that look like regular expressions are slow and should be avoided.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-selectors-that-look-like-regular-expressions",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(r){var o,i,a,s,u,l,c=r.selectors;for(s=0;s<c.length;s++)for(o=c[s],u=0;u<o.parts.length;u++)if((i=o.parts[u]).type===e.SELECTOR_PART_TYPE)for(l=0;l<i.modifiers.length;l++)"attribute"===(a=i.modifiers[l]).type&&/([~\|\^\$\*]=)/.test(a)&&t.report("Attribute selectors with "+RegExp.$1+" are slow!",a.line,a.col,n)}))}}),i.addRule({id:"rules-count",name:"Rules Count",desc:"Track how many rules there are.",browsers:"All",init:function(e,t){"use strict";var n=0;e.addListener("startrule",(function(){n++})),e.addListener("endstylesheet",(function(){t.stat("rule-count",n)}))}}),i.addRule({id:"selector-max-approaching",name:"Warn when approaching the 4095 selector limit for IE",desc:"Will warn when selector count is >= 3800 selectors.",browsers:"IE",init:function(e,t){"use strict";var n=this,r=0;e.addListener("startrule",(function(e){r+=e.selectors.length})),e.addListener("endstylesheet",(function(){r>=3800&&t.report("You have "+r+" selectors. Internet Explorer supports a maximum of 4095 selectors per stylesheet. Consider refactoring.",0,0,n)}))}}),i.addRule({id:"selector-max",name:"Error when past the 4095 selector limit for IE",desc:"Will error when selector count is > 4095.",browsers:"IE",init:function(e,t){"use strict";var n=this,r=0;e.addListener("startrule",(function(e){r+=e.selectors.length})),e.addListener("endstylesheet",(function(){r>4095&&t.report("You have "+r+" selectors. Internet Explorer supports a maximum of 4095 selectors per stylesheet. Consider refactoring.",0,0,n)}))}}),i.addRule({id:"selector-newline",name:"Disallow new-line characters in selectors",desc:"New-line characters in selectors are usually a forgotten comma and not a descendant combinator.",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(e){var r,o,i,a,s,u,l,c,f,d,p,h=e.selectors;for(r=0,o=h.length;r<o;r++)for(a=0,u=(i=h[r]).parts.length;a<u;a++)for(s=a+1;s<u;s++)l=i.parts[a],c=i.parts[s],f=l.type,d=l.line,p=c.line,"descendant"===f&&p>d&&t.report("newline character found in selector (forgot a comma?)",d,h[r].parts[0].col,n)}))}}),i.addRule({id:"shorthand",name:"Require shorthand properties",desc:"Use shorthand properties where possible.",url:"https://github.com/CSSLint/csslint/wiki/Require-shorthand-properties",browsers:"All",init:function(e,t){"use strict";var n,r,o,i,a=this,s={},u={margin:["margin-top","margin-bottom","margin-left","margin-right"],padding:["padding-top","padding-bottom","padding-left","padding-right"]};for(n in u)if(u.hasOwnProperty(n))for(r=0,o=u[n].length;r<o;r++)s[u[n][r]]=n;function l(){i={}}function c(e){var n,r,o,s;for(n in u)if(u.hasOwnProperty(n)){for(s=0,r=0,o=u[n].length;r<o;r++)s+=i[u[n][r]]?1:0;s===u[n].length&&t.report("The properties "+u[n].join(", ")+" can be replaced by "+n+".",e.line,e.col,a)}}e.addListener("startrule",l),e.addListener("startfontface",l),e.addListener("property",(function(e){var t=e.property.toString().toLowerCase();s[t]&&(i[t]=1)})),e.addListener("endrule",c),e.addListener("endfontface",c)}}),i.addRule({id:"star-property-hack",name:"Disallow properties with a star prefix",desc:"Checks for the star property hack (targets IE6/7)",url:"https://github.com/CSSLint/csslint/wiki/Disallow-star-hack",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("property",(function(e){"*"===e.property.hack&&t.report("Property with star prefix found.",e.property.line,e.property.col,n)}))}}),i.addRule({id:"text-indent",name:"Disallow negative text-indent",desc:"Checks for text indent less than -99px",url:"https://github.com/CSSLint/csslint/wiki/Disallow-negative-text-indent",browsers:"All",init:function(e,t){"use strict";var n,r,o=this;function i(){n=!1,r="inherit"}function a(){n&&"ltr"!==r&&t.report("Negative text-indent doesn't work well with RTL. If you use text-indent for image replacement explicitly set direction for that item to ltr.",n.line,n.col,o)}e.addListener("startrule",i),e.addListener("startfontface",i),e.addListener("property",(function(e){var t=e.property.toString().toLowerCase(),o=e.value;"text-indent"===t&&o.parts[0].value<-99?n=e.property:"direction"===t&&"ltr"===o.toString()&&(r="ltr")})),e.addListener("endrule",a),e.addListener("endfontface",a)}}),i.addRule({id:"underscore-property-hack",name:"Disallow properties with an underscore prefix",desc:"Checks for the underscore property hack (targets IE6)",url:"https://github.com/CSSLint/csslint/wiki/Disallow-underscore-hack",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("property",(function(e){"_"===e.property.hack&&t.report("Property with underscore prefix found.",e.property.line,e.property.col,n)}))}}),i.addRule({id:"unique-headings",name:"Headings should only be defined once",desc:"Headings should be defined only once.",url:"https://github.com/CSSLint/csslint/wiki/Headings-should-only-be-defined-once",browsers:"All",init:function(e,t){"use strict";var n=this,r={h1:0,h2:0,h3:0,h4:0,h5:0,h6:0};e.addListener("startrule",(function(e){var o,i,a,s,u,l=e.selectors;for(s=0;s<l.length;s++)if((i=(o=l[s]).parts[o.parts.length-1]).elementName&&/(h[1-6])/i.test(i.elementName.toString())){for(u=0;u<i.modifiers.length;u++)if("pseudo"===i.modifiers[u].type){a=!0;break}a||(r[RegExp.$1]++,r[RegExp.$1]>1&&t.report("Heading ("+i.elementName+") has already been defined.",i.line,i.col,n))}})),e.addListener("endstylesheet",(function(){var e,o=[];for(e in r)r.hasOwnProperty(e)&&r[e]>1&&o.push(r[e]+" "+e+"s");o.length&&t.rollupWarn("You have "+o.join(", ")+" defined in this stylesheet.",n)}))}}),i.addRule({id:"universal-selector",name:"Disallow universal selector",desc:"The universal selector (*) is known to be slow.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-universal-selector",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(e){var r,o,i,a=e.selectors;for(i=0;i<a.length;i++)"*"===(o=(r=a[i]).parts[r.parts.length-1]).elementName&&t.report(n.desc,o.line,o.col,n)}))}}),i.addRule({id:"unqualified-attributes",name:"Disallow unqualified attribute selectors",desc:"Unqualified attribute selectors are known to be slow.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-unqualified-attribute-selectors",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("startrule",(function(r){var o,i,a,s,u,l=r.selectors,c=!1;for(s=0;s<l.length;s++)if((i=(o=l[s]).parts[o.parts.length-1]).type===e.SELECTOR_PART_TYPE){for(u=0;u<i.modifiers.length;u++)if("class"===(a=i.modifiers[u]).type||"id"===a.type){c=!0;break}if(!c)for(u=0;u<i.modifiers.length;u++)"attribute"!==(a=i.modifiers[u]).type||i.elementName&&"*"!==i.elementName||t.report(n.desc,i.line,i.col,n)}}))}}),i.addRule({id:"vendor-prefix",name:"Require standard property with vendor prefix",desc:"When using a vendor-prefixed property, make sure to include the standard one.",url:"https://github.com/CSSLint/csslint/wiki/Require-standard-property-with-vendor-prefix",browsers:"All",init:function(e,t){"use strict";var n,r,o=this,i={"-webkit-border-radius":"border-radius","-webkit-border-top-left-radius":"border-top-left-radius","-webkit-border-top-right-radius":"border-top-right-radius","-webkit-border-bottom-left-radius":"border-bottom-left-radius","-webkit-border-bottom-right-radius":"border-bottom-right-radius","-o-border-radius":"border-radius","-o-border-top-left-radius":"border-top-left-radius","-o-border-top-right-radius":"border-top-right-radius","-o-border-bottom-left-radius":"border-bottom-left-radius","-o-border-bottom-right-radius":"border-bottom-right-radius","-moz-border-radius":"border-radius","-moz-border-radius-topleft":"border-top-left-radius","-moz-border-radius-topright":"border-top-right-radius","-moz-border-radius-bottomleft":"border-bottom-left-radius","-moz-border-radius-bottomright":"border-bottom-right-radius","-moz-column-count":"column-count","-webkit-column-count":"column-count","-moz-column-gap":"column-gap","-webkit-column-gap":"column-gap","-moz-column-rule":"column-rule","-webkit-column-rule":"column-rule","-moz-column-rule-style":"column-rule-style","-webkit-column-rule-style":"column-rule-style","-moz-column-rule-color":"column-rule-color","-webkit-column-rule-color":"column-rule-color","-moz-column-rule-width":"column-rule-width","-webkit-column-rule-width":"column-rule-width","-moz-column-width":"column-width","-webkit-column-width":"column-width","-webkit-column-span":"column-span","-webkit-columns":"columns","-moz-box-shadow":"box-shadow","-webkit-box-shadow":"box-shadow","-moz-transform":"transform","-webkit-transform":"transform","-o-transform":"transform","-ms-transform":"transform","-moz-transform-origin":"transform-origin","-webkit-transform-origin":"transform-origin","-o-transform-origin":"transform-origin","-ms-transform-origin":"transform-origin","-moz-box-sizing":"box-sizing","-webkit-box-sizing":"box-sizing"};function a(){n={},r=1}function s(){var e,r,a,s,u,l=[];for(e in n)i[e]&&l.push({actual:e,needed:i[e]});for(r=0,a=l.length;r<a;r++)s=l[r].needed,u=l[r].actual,n[s]?n[s][0].pos<n[u][0].pos&&t.report("Standard property '"+s+"' should come after vendor-prefixed property '"+u+"'.",n[u][0].name.line,n[u][0].name.col,o):t.report("Missing standard property '"+s+"' to go along with '"+u+"'.",n[u][0].name.line,n[u][0].name.col,o)}e.addListener("startrule",a),e.addListener("startfontface",a),e.addListener("startpage",a),e.addListener("startpagemargin",a),e.addListener("startkeyframerule",a),e.addListener("startviewport",a),e.addListener("property",(function(e){var t=e.property.text.toLowerCase();n[t]||(n[t]=[]),n[t].push({name:e.property,value:e.value,pos:r++})})),e.addListener("endrule",s),e.addListener("endfontface",s),e.addListener("endpage",s),e.addListener("endpagemargin",s),e.addListener("endkeyframerule",s),e.addListener("endviewport",s)}}),i.addRule({id:"zero-units",name:"Disallow units for 0 values",desc:"You don't need to specify units when a value is 0.",url:"https://github.com/CSSLint/csslint/wiki/Disallow-units-for-zero-values",browsers:"All",init:function(e,t){"use strict";var n=this;e.addListener("property",(function(e){for(var r=e.value.parts,o=0,i=r.length;o<i;)!r[o].units&&"percentage"!==r[o].type||0!==r[o].value||"time"===r[o].type||t.report("Values of 0 shouldn't have units specified.",r[o].line,r[o].col,n),o++}))}}),function(){"use strict";var e=function(e){return e&&e.constructor===String?e.replace(/["&><]/g,(function(e){switch(e){case'"':return""";case"&":return"&";case"<":return"<";case">":return">"}})):""};i.addFormatter({id:"checkstyle-xml",name:"Checkstyle XML format",startFormat:function(){return'<?xml version="1.0" encoding="utf-8"?><checkstyle>'},endFormat:function(){return"</checkstyle>"},readError:function(t,n){return'<file name="'+e(t)+'"><error line="0" column="0" severty="error" message="'+e(n)+'"></error></file>'},formatResults:function(t,n){var r=t.messages,o=[];return r.length>0&&(o.push('<file name="'+n+'">'),i.Util.forEach(r,(function(t){var n;t.rollup||o.push('<error line="'+t.line+'" column="'+t.col+'" severity="'+t.type+'" message="'+e(t.message)+'" source="'+(((n=t.rule)&&"name"in n?"net.csslint."+n.name.replace(/\s/g,""):"")+'"/>'))})),o.push("</file>")),o.join("")}})}(),i.addFormatter({id:"compact",name:"Compact, 'porcelain' format",startFormat:function(){"use strict";return""},endFormat:function(){"use strict";return""},formatResults:function(e,t,n){"use strict";var r=e.messages,o="";n=n||{};var a=function(e){return e.charAt(0).toUpperCase()+e.slice(1)};return 0===r.length?n.quiet?"":t+": Lint Free!":(i.Util.forEach(r,(function(e){e.rollup?o+=t+": "+a(e.type)+" - "+e.message+" ("+e.rule.id+")\n":o+=t+": line "+e.line+", col "+e.col+", "+a(e.type)+" - "+e.message+" ("+e.rule.id+")\n"})),o)}}),i.addFormatter({id:"csslint-xml",name:"CSSLint XML format",startFormat:function(){"use strict";return'<?xml version="1.0" encoding="utf-8"?><csslint>'},endFormat:function(){"use strict";return"</csslint>"},formatResults:function(e,t){"use strict";var n=e.messages,r=[],o=function(e){return e&&e.constructor===String?e.replace(/"/g,"'").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"):""};return n.length>0&&(r.push('<file name="'+t+'">'),i.Util.forEach(n,(function(e){e.rollup?r.push('<issue severity="'+e.type+'" reason="'+o(e.message)+'" evidence="'+o(e.evidence)+'"/>'):r.push('<issue line="'+e.line+'" char="'+e.col+'" severity="'+e.type+'" reason="'+o(e.message)+'" evidence="'+o(e.evidence)+'"/>')})),r.push("</file>")),r.join("")}}),i.addFormatter({id:"json",name:"JSON",startFormat:function(){"use strict";return this.json=[],""},endFormat:function(){"use strict";var e="";return this.json.length>0&&(e=1===this.json.length?JSON.stringify(this.json[0]):JSON.stringify(this.json)),e},formatResults:function(e,t,n){"use strict";return(e.messages.length>0||!n.quiet)&&this.json.push({filename:t,messages:e.messages,stats:e.stats}),""}}),i.addFormatter({id:"junit-xml",name:"JUNIT XML format",startFormat:function(){"use strict";return'<?xml version="1.0" encoding="utf-8"?><testsuites>'},endFormat:function(){"use strict";return"</testsuites>"},formatResults:function(e,t){"use strict";var n=e.messages,r=[],o={error:0,failure:0},i=function(e){return e&&e.constructor===String?e.replace(/"/g,"'").replace(/</g,"<").replace(/>/g,">"):""};return n.length>0&&(n.forEach((function(e){var t,n="warning"===e.type?"error":e.type;e.rollup||(r.push('<testcase time="0" name="'+(((t=e.rule)&&"name"in t?"net.csslint."+t.name.replace(/\s/g,""):"")+'">')),r.push("<"+n+' message="'+i(e.message)+'"><![CDATA['+e.line+":"+e.col+":"+i(e.evidence)+"]]></"+n+">"),r.push("</testcase>"),o[n]+=1)})),r.unshift('<testsuite time="0" tests="'+n.length+'" skipped="0" errors="'+o.error+'" failures="'+o.failure+'" package="net.csslint" name="'+t+'">'),r.push("</testsuite>")),r.join("")}}),i.addFormatter({id:"lint-xml",name:"Lint XML format",startFormat:function(){"use strict";return'<?xml version="1.0" encoding="utf-8"?><lint>'},endFormat:function(){"use strict";return"</lint>"},formatResults:function(e,t){"use strict";var n=e.messages,r=[],o=function(e){return e&&e.constructor===String?e.replace(/"/g,"'").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">"):""};return n.length>0&&(r.push('<file name="'+t+'">'),i.Util.forEach(n,(function(e){if(e.rollup)r.push('<issue severity="'+e.type+'" reason="'+o(e.message)+'" evidence="'+o(e.evidence)+'"/>');else{var t="";e.rule&&e.rule.id&&(t='rule="'+o(e.rule.id)+'" '),r.push("<issue "+t+'line="'+e.line+'" char="'+e.col+'" severity="'+e.type+'" reason="'+o(e.message)+'" evidence="'+o(e.evidence)+'"/>')}})),r.push("</file>")),r.join("")}}),i.addFormatter({id:"text",name:"Plain Text",startFormat:function(){"use strict";return""},endFormat:function(){"use strict";return""},formatResults:function(e,t,n){"use strict";var r=e.messages,o="";if(n=n||{},0===r.length)return n.quiet?"":"\n\ncsslint: No errors in "+t+".";o="\n\ncsslint: There ",1===r.length?o+="is 1 problem":o+="are "+r.length+" problems",o+=" in "+t+".";var a=t.lastIndexOf("/"),s=t;return-1===a&&(a=t.lastIndexOf("\\")),a>-1&&(s=t.substring(a+1)),i.Util.forEach(r,(function(e,t){o=o+"\n\n"+s,e.rollup?(o+="\n"+(t+1)+": "+e.type,o+="\n"+e.message):(o+="\n"+(t+1)+": "+e.type+" at line "+e.line+", col "+e.col,o+="\n"+e.message,o+="\n"+e.evidence)})),o}}),t.CSSLint=i},,function(e,t,n){e.exports=n(461)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decorator=t.connect=t.Container=void 0;var r=n(228);Object.defineProperty(t,"Container",{enumerable:!0,get:function(){return s(r).default}});var o=s(n(232)),i=n(233),a=s(i);function s(e){return e&&e.__esModule?e:{default:e}}t.connect=(0,a.default)(o.default),t.decorator=(0,i.decoratorFactory)(o.default)},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=u(n(0)),i=u(n(142)),a=n(2),s=n(231);function u(e){return e&&e.__esModule?e:{default:e}}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var f=function(e){function t(){return l(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"getChildContext",value:function(){var e=this.props,t=e.app,n=e.controller;return n&&(0,s.DEPRECATE)("Container",'please change from "controller" to "app" property'),t||n||(0,a.throwError)("You are not passing a Cerebral app to Container"),{controller:t||n}}},{key:"render",value:function(){return this.props.children}}]),t}(o.default.Component);f.propTypes={app:i.default.object.isRequired,children:i.default.node.isRequired},f.childContextTypes={controller:i.default.object.isRequired},t.default=f},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var r=n(230);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict";n.r(t);var r=n(5);n.d(t,"getChangedProps",(function(){return r.l})),n.d(t,"cleanPath",(function(){return r.c})),n.d(t,"isObject",(function(){return r.v})),n.d(t,"isComplexObject",(function(){return r.s})),n.d(t,"isSerializable",(function(){return r.w})),n.d(t,"ensurePath",(function(){return r.h})),n.d(t,"throwError",(function(){return r.y})),n.d(t,"isDeveloping",(function(){return r.u})),n.d(t,"debounce",(function(){return r.f})),n.d(t,"forceSerializable",(function(){return r.k})),n.d(t,"getProviders",(function(){return r.n})),n.d(t,"dependencyMatch",(function(){return r.g})),n.d(t,"getWithPath",(function(){return r.r})),n.d(t,"ensureStrictPath",(function(){return r.i})),n.d(t,"createResolver",(function(){return r.e})),n.d(t,"noop",(function(){return r.x})),n.d(t,"createDummyController",(function(){return r.d})),n.d(t,"addCerebralStateKey",(function(){return r.b})),n.d(t,"getStateTreeProp",(function(){return r.q})),n.d(t,"getModule",(function(){return r.m})),n.d(t,"extractModuleProp",(function(){return r.j})),n.d(t,"DEPRECATE",(function(){return r.a})),n.d(t,"getRootPath",(function(){return r.o})),n.d(t,"isComputedValue",(function(){return r.t})),n.d(t,"getStateChanges",(function(){return r.p}));var o=n(90);n.d(t,"BaseModel",(function(){return o.a}));var i=n(20);n.d(t,"ComputedClass",(function(){return i.a}))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();t.default=function(e,t,n){var i=function(i){function a(r,o){return u(this,a),l(this,(a.__proto__||Object.getPrototypeOf(a)).call(this,e,t,r,o.controller,n.displayName||n.name))}return c(a,i),r(a,[{key:"toJSON",value:function(){return this.view._displayName}},{key:"render",value:function(){return this.view.render(this.props,(function(e){return o.default.createElement(n,e)}))}}]),a}(f);return i.displayName="CerebralWrapping_"+(n.displayName||n.name),i.contextTypes={controller:a.default.object},i};var o=s(n(0)),i=n(2),a=s(n(142));function s(e){return e&&e.__esModule?e:{default:e}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function c(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var f=function(e){function t(e,n,r,o,a){u(this,t);var s=l(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,r));return o||(0,i.throwError)("Can not find controller, did you remember to use the Container component? Read more at: http://cerebraljs.com/docs/api/components.html#react"),s.onUpdate=s.onUpdate.bind(s),s.view=new i.View({dependencies:e,mergeProps:n,props:r,controller:o,displayName:a,onUpdate:s.onUpdate}),s.view.mount(),s}return c(t,e),r(t,[{key:"shouldComponentUpdate",value:function(e){return this.view.onPropsUpdate(this.props,e)}},{key:"componentDidMount",value:function(){this.view.dynamicDependencies.length&&this.view.update(this.props)}},{key:"componentDidUpdate",value:function(){this.view.dynamicDependencies.length&&this.view.update(this.props)}},{key:"componentWillUnmount",value:function(){this.view.unMount()}},{key:"onUpdate",value:function(e,t){this.view.updateFromState(e,this.props,t),this.forceUpdate()}}]),t}(o.default.Component)},function(e,t,n){"use strict";function r(e,t,n,r){return n&&!r?(r=n,n=null):n||r||(r=t,t={},n=null),e(t,n,r)}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return function(t,n,o){return r(e,t,n,o)}};t.decoratorFactory=function(e){return function(t){return function(n){return r(e,t)(n)}}}},function(e,t,n){var r=n(58),o=Object.prototype,i=o.hasOwnProperty,a=o.toString,s=r?r.toStringTag:void 0;e.exports=function(e){var t=i.call(e,s),n=e[s];try{e[s]=void 0;var r=!0}catch(e){}var o=a.call(e);return r&&(t?e[s]=n:delete e[s]),o}},function(e,t){var n=Object.prototype.toString;e.exports=function(e){return n.call(e)}},function(e,t,n){var r=n(237),o=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,i=/\\(\\)?/g,a=r((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(o,(function(e,n,r,o){t.push(r?o.replace(i,"$1"):n||e)})),t}));e.exports=a},function(e,t,n){var r=n(144);e.exports=function(e){var t=r(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}},function(e,t,n){var r=n(239),o=n(70),i=n(98);e.exports=function(){this.size=0,this.__data__={hash:new r,map:new(i||o),string:new r}}},function(e,t,n){var r=n(240),o=n(245),i=n(246),a=n(247),s=n(248);function u(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}u.prototype.clear=r,u.prototype.delete=o,u.prototype.get=i,u.prototype.has=a,u.prototype.set=s,e.exports=u},function(e,t,n){var r=n(69);e.exports=function(){this.__data__=r?r(null):{},this.size=0}},function(e,t,n){var r=n(97),o=n(242),i=n(28),a=n(145),s=/^\[object .+?Constructor\]$/,u=Function.prototype,l=Object.prototype,c=u.toString,f=l.hasOwnProperty,d=RegExp("^"+c.call(f).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!i(e)||o(e))&&(r(e)?d:s).test(a(e))}},function(e,t,n){var r,o=n(243),i=(r=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+r:"";e.exports=function(e){return!!i&&i in e}},function(e,t,n){var r=n(32)["__core-js_shared__"];e.exports=r},function(e,t){e.exports=function(e,t){return null==e?void 0:e[t]}},function(e,t){e.exports=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}},function(e,t,n){var r=n(69),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;if(r){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return o.call(t,e)?t[e]:void 0}},function(e,t,n){var r=n(69),o=Object.prototype.hasOwnProperty;e.exports=function(e){var t=this.__data__;return r?void 0!==t[e]:o.call(t,e)}},function(e,t,n){var r=n(69);e.exports=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=r&&void 0===t?"__lodash_hash_undefined__":t,this}},function(e,t){e.exports=function(){this.__data__=[],this.size=0}},function(e,t,n){var r=n(71),o=Array.prototype.splice;e.exports=function(e){var t=this.__data__,n=r(t,e);return!(n<0)&&(n==t.length-1?t.pop():o.call(t,n,1),--this.size,!0)}},function(e,t,n){var r=n(71);e.exports=function(e){var t=this.__data__,n=r(t,e);return n<0?void 0:t[n][1]}},function(e,t,n){var r=n(71);e.exports=function(e){return r(this.__data__,e)>-1}},function(e,t,n){var r=n(71);e.exports=function(e,t){var n=this.__data__,o=r(n,e);return o<0?(++this.size,n.push([e,t])):n[o][1]=t,this}},function(e,t,n){var r=n(72);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},function(e,t){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},function(e,t,n){var r=n(72);e.exports=function(e){return r(this,e).get(e)}},function(e,t,n){var r=n(72);e.exports=function(e){return r(this,e).has(e)}},function(e,t,n){var r=n(72);e.exports=function(e,t){var n=r(this,e),o=n.size;return n.set(e,t),this.size+=n.size==o?0:1,this}},function(e,t,n){var r=n(58),o=n(49),i=n(23),a=n(68),s=r?r.prototype:void 0,u=s?s.toString:void 0;e.exports=function e(t){if("string"==typeof t)return t;if(i(t))return o(t,e)+"";if(a(t))return u?u.call(t):"";var n=t+"";return"0"==n&&1/t==-1/0?"-0":n}},function(e,t,n){var r=n(73).default;function o(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */e.exports=o=function(){return n},e.exports.__esModule=!0,e.exports.default=e.exports;var t,n={},i=Object.prototype,a=i.hasOwnProperty,s=Object.defineProperty||function(e,t,n){e[t]=n.value},u="function"==typeof Symbol?Symbol:{},l=u.iterator||"@@iterator",c=u.asyncIterator||"@@asyncIterator",f=u.toStringTag||"@@toStringTag";function d(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{d({},"")}catch(t){d=function(e,t,n){return e[t]=n}}function p(e,t,n,r){var o=t&&t.prototype instanceof b?t:b,i=Object.create(o.prototype),a=new A(r||[]);return s(i,"_invoke",{value:T(e,n,a)}),i}function h(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}n.wrap=p;var v="suspendedStart",g="executing",m="completed",y={};function b(){}function w(){}function _(){}var x={};d(x,l,(function(){return this}));var k=Object.getPrototypeOf,C=k&&k(k(P([])));C&&C!==i&&a.call(C,l)&&(x=C);var O=_.prototype=b.prototype=Object.create(x);function E(e){["next","throw","return"].forEach((function(t){d(e,t,(function(e){return this._invoke(t,e)}))}))}function S(e,t){function n(o,i,s,u){var l=h(e[o],e,i);if("throw"!==l.type){var c=l.arg,f=c.value;return f&&"object"==r(f)&&a.call(f,"__await")?t.resolve(f.__await).then((function(e){n("next",e,s,u)}),(function(e){n("throw",e,s,u)})):t.resolve(f).then((function(e){c.value=e,s(c)}),(function(e){return n("throw",e,s,u)}))}u(l.arg)}var o;s(this,"_invoke",{value:function(e,r){function i(){return new t((function(t,o){n(e,r,t,o)}))}return o=o?o.then(i,i):i()}})}function T(e,n,r){var o=v;return function(i,a){if(o===g)throw Error("Generator is already running");if(o===m){if("throw"===i)throw a;return{value:t,done:!0}}for(r.method=i,r.arg=a;;){var s=r.delegate;if(s){var u=j(s,r);if(u){if(u===y)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(o===v)throw o=m,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);o=g;var l=h(e,n,r);if("normal"===l.type){if(o=r.done?m:"suspendedYield",l.arg===y)continue;return{value:l.arg,done:r.done}}"throw"===l.type&&(o=m,r.method="throw",r.arg=l.arg)}}}function j(e,n){var r=n.method,o=e.iterator[r];if(o===t)return n.delegate=null,"throw"===r&&e.iterator.return&&(n.method="return",n.arg=t,j(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),y;var i=h(o,e.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,y;var a=i.arg;return a?a.done?(n[e.resultName]=a.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,y):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,y)}function M(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(M,this),this.reset(!0)}function P(e){if(e||""===e){var n=e[l];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function n(){for(;++o<e.length;)if(a.call(e,o))return n.value=e[o],n.done=!1,n;return n.value=t,n.done=!0,n};return i.next=i}}throw new TypeError(r(e)+" is not iterable")}return w.prototype=_,s(O,"constructor",{value:_,configurable:!0}),s(_,"constructor",{value:w,configurable:!0}),w.displayName=d(_,f,"GeneratorFunction"),n.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===w||"GeneratorFunction"===(t.displayName||t.name))},n.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,_):(e.__proto__=_,d(e,f,"GeneratorFunction")),e.prototype=Object.create(O),e},n.awrap=function(e){return{__await:e}},E(S.prototype),d(S.prototype,c,(function(){return this})),n.AsyncIterator=S,n.async=function(e,t,r,o,i){void 0===i&&(i=Promise);var a=new S(p(e,t,r,o),i);return n.isGeneratorFunction(t)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},E(O),d(O,f,"Generator"),d(O,l,(function(){return this})),d(O,"toString",(function(){return"[object Generator]"})),n.keys=function(e){var t=Object(e),n=[];for(var r in t)n.push(r);return n.reverse(),function e(){for(;n.length;){var r=n.pop();if(r in t)return e.value=r,e.done=!1,e}return e.done=!0,e}},n.values=P,A.prototype={constructor:A,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(L),!e)for(var n in this)"t"===n.charAt(0)&&a.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function r(r,o){return s.type="throw",s.arg=e,n.next=r,o&&(n.method="next",n.arg=t),!!o}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],s=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var u=a.call(i,"catchLoc"),l=a.call(i,"finallyLoc");if(u&&l){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(u){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!l)throw Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(e,t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc<=this.prev&&a.call(r,"finallyLoc")&&this.prev<r.finallyLoc){var o=r;break}}o&&("break"===e||"continue"===e)&&o.tryLoc<=t&&t<=o.finallyLoc&&(o=null);var i=o?o.completion:{};return i.type=e,i.arg=t,o?(this.method="next",this.next=o.finallyLoc,y):this.complete(i)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),y},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),L(n),y}},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 o=r.arg;L(n)}return o}}throw Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:P(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),y}},n}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e},e.exports.default=e.exports,e.exports.__esModule=!0,n(t,r)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){function n(t){return"function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?(e.exports=n=function(e){return typeof e},e.exports.default=e.exports,e.exports.__esModule=!0):(e.exports=n=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.default=e.exports,e.exports.__esModule=!0),n(t)}e.exports=n,e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){var r=n(146);e.exports=function(e){if(Array.isArray(e))return r(e)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=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.")},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e){if(Array.isArray(e))return e},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i=[],a=!0,s=!1;try{for(n=n.call(e);!(a=(r=n.next()).done)&&(i.push(r.value),!t||i.length!==t);a=!0);}catch(e){s=!0,o=e}finally{try{a||null==n.return||n.return()}finally{if(s)throw o}}return i}},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.default=e.exports,e.exports.__esModule=!0},function(e,t,n){ /** * Copyright (c) 2014-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ var r=function(e){"use strict";var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},o=r.iterator||"@@iterator",i=r.asyncIterator||"@@asyncIterator",a=r.toStringTag||"@@toStringTag";function s(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{s({},"")}catch(e){s=function(e,t,n){return e[t]=n}}function u(e,t,n,r){var o=t&&t.prototype instanceof f?t:f,i=Object.create(o.prototype),a=new k(r||[]);return i._invoke=function(e,t,n){var r="suspendedStart";return function(o,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===o)throw i;return O()}for(n.method=o,n.arg=i;;){var a=n.delegate;if(a){var s=w(a,n);if(s){if(s===c)continue;return s}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var u=l(e,t,n);if("normal"===u.type){if(r=n.done?"completed":"suspendedYield",u.arg===c)continue;return{value:u.arg,done:n.done}}"throw"===u.type&&(r="completed",n.method="throw",n.arg=u.arg)}}}(e,n,a),i}function l(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=u;var c={};function f(){}function d(){}function p(){}var h={};s(h,o,(function(){return this}));var v=Object.getPrototypeOf,g=v&&v(v(C([])));g&&g!==t&&n.call(g,o)&&(h=g);var m=p.prototype=f.prototype=Object.create(h);function y(e){["next","throw","return"].forEach((function(t){s(e,t,(function(e){return this._invoke(t,e)}))}))}function b(e,t){var r;this._invoke=function(o,i){function a(){return new t((function(r,a){!function r(o,i,a,s){var u=l(e[o],e,i);if("throw"!==u.type){var c=u.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?t.resolve(f.__await).then((function(e){r("next",e,a,s)}),(function(e){r("throw",e,a,s)})):t.resolve(f).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,s)}))}s(u.arg)}(o,i,r,a)}))}return r=r?r.then(a,a):a()}}function w(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,w(e,t),"throw"===t.method))return c;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return c}var r=l(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,c;var o=r.arg;return o?o.done?(t[e.resultName]=o.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,c):o:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,c)}function _(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function x(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function k(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(_,this),this.reset(!0)}function C(e){if(e){var t=e[o];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r<e.length;)if(n.call(e,r))return t.value=e[r],t.done=!1,t;return t.value=void 0,t.done=!0,t};return i.next=i}}return{next:O}}function O(){return{value:void 0,done:!0}}return d.prototype=p,s(m,"constructor",p),s(p,"constructor",d),d.displayName=s(p,a,"GeneratorFunction"),e.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===d||"GeneratorFunction"===(t.displayName||t.name))},e.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,p):(e.__proto__=p,s(e,a,"GeneratorFunction")),e.prototype=Object.create(m),e},e.awrap=function(e){return{__await:e}},y(b.prototype),s(b.prototype,i,(function(){return this})),e.AsyncIterator=b,e.async=function(t,n,r,o,i){void 0===i&&(i=Promise);var a=new b(u(t,n,r,o),i);return e.isGeneratorFunction(n)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},y(m),s(m,a,"Generator"),s(m,o,(function(){return this})),s(m,"toString",(function(){return"[object Generator]"})),e.keys=function(e){var t=[];for(var n in e)t.push(n);return t.reverse(),function n(){for(;t.length;){var r=t.pop();if(r in e)return n.value=r,n.done=!1,n}return n.done=!0,n}},e.values=C,k.prototype={constructor:k,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(x),!e)for(var t in this)"t"===t.charAt(0)&&n.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void 0)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var t=this;function r(n,r){return a.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void 0),!!r}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var s=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(s&&u){if(this.prev<i.catchLoc)return r(i.catchLoc,!0);if(this.prev<i.finallyLoc)return r(i.finallyLoc)}else if(s){if(this.prev<i.catchLoc)return r(i.catchLoc,!0)}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return r(i.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,c):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),c},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),x(n),c}},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 o=r.arg;x(n)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:C(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),c}},e}(e.exports);try{regeneratorRuntime=r}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},function(e,t,n){var r,o,i=n(148),a=n(149),s=0,u=0;e.exports=function(e,t,n){var l=t&&n||0,c=t||[],f=(e=e||{}).node||r,d=void 0!==e.clockseq?e.clockseq:o;if(null==f||null==d){var p=i();null==f&&(f=r=[1|p[0],p[1],p[2],p[3],p[4],p[5]]),null==d&&(d=o=16383&(p[6]<<8|p[7]))}var h=void 0!==e.msecs?e.msecs:(new Date).getTime(),v=void 0!==e.nsecs?e.nsecs:u+1,g=h-s+(v-u)/1e4;if(g<0&&void 0===e.clockseq&&(d=d+1&16383),(g<0||h>s)&&void 0===e.nsecs&&(v=0),v>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");s=h,u=v,o=d;var m=(1e4*(268435455&(h+=122192928e5))+v)%4294967296;c[l++]=m>>>24&255,c[l++]=m>>>16&255,c[l++]=m>>>8&255,c[l++]=255&m;var y=h/4294967296*1e4&268435455;c[l++]=y>>>8&255,c[l++]=255&y,c[l++]=y>>>24&15|16,c[l++]=y>>>16&255,c[l++]=d>>>8|128,c[l++]=255&d;for(var b=0;b<6;++b)c[l+b]=f[b];return t||a(c)}},function(e,t,n){var r=n(148),o=n(149);e.exports=function(e,t,n){var i=t&&n||0;"string"==typeof e&&(t="binary"===e?new Array(16):null,e=null);var a=(e=e||{}).random||(e.rng||r)();if(a[6]=15&a[6]|64,a[8]=63&a[8]|128,t)for(var s=0;s<16;++s)t[i+s]=a[s];return t||o(a)}},function(e,t,n){var r=n(73).default;e.exports=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t||"default");if("object"!=r(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){function n(t,r){return e.exports=n=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},e.exports.__esModule=!0,e.exports.default=e.exports,n(t,r)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var r=n(275);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){"use strict";t.__esModule=!0;var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function i(e){return e&&e.__esModule?e:{default:e}}var a=i(n(99)),s=i(n(74)),u=i(n(100)),l=i(n(101)),c=i(n(102)),f=i(n(103)),d=i(n(0)),p=i(n(1)),h=function(e){function t(n){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),e.call(this,n),this.wasAnimating=!1,this.animationID=null,this.prevTime=0,this.accumulatedTime=0,this.unreadPropStyle=null,this.clearUnreadPropStyle=function(e){var t=!1,n=o.state,i=n.currentStyle,a=n.currentVelocity,s=n.lastIdealStyle,u=n.lastIdealVelocity;for(var l in e)if(Object.prototype.hasOwnProperty.call(e,l)){var c=e[l];"number"==typeof c&&(t||(t=!0,i=r({},i),a=r({},a),s=r({},s),u=r({},u)),i[l]=c,a[l]=0,s[l]=c,u[l]=0)}t&&o.setState({currentStyle:i,currentVelocity:a,lastIdealStyle:s,lastIdealVelocity:u})},this.startAnimationIfNecessary=function(){o.animationID=c.default((function(e){var t=o.props.style;if(f.default(o.state.currentStyle,t,o.state.currentVelocity))return o.wasAnimating&&o.props.onRest&&o.props.onRest(),o.animationID=null,o.wasAnimating=!1,void(o.accumulatedTime=0);o.wasAnimating=!0;var n=e||l.default(),r=n-o.prevTime;if(o.prevTime=n,o.accumulatedTime=o.accumulatedTime+r,o.accumulatedTime>1e3/60*10&&(o.accumulatedTime=0),0===o.accumulatedTime)return o.animationID=null,void o.startAnimationIfNecessary();var i=(o.accumulatedTime-Math.floor(o.accumulatedTime/(1e3/60))*(1e3/60))/(1e3/60),a=Math.floor(o.accumulatedTime/(1e3/60)),s={},c={},d={},p={};for(var h in t)if(Object.prototype.hasOwnProperty.call(t,h)){var v=t[h];if("number"==typeof v)d[h]=v,p[h]=0,s[h]=v,c[h]=0;else{for(var g=o.state.lastIdealStyle[h],m=o.state.lastIdealVelocity[h],y=0;y<a;y++){var b=u.default(1e3/60/1e3,g,m,v.val,v.stiffness,v.damping,v.precision);g=b[0],m=b[1]}var w=u.default(1e3/60/1e3,g,m,v.val,v.stiffness,v.damping,v.precision),_=w[0],x=w[1];d[h]=g+(_-g)*i,p[h]=m+(x-m)*i,s[h]=g,c[h]=m}}o.animationID=null,o.accumulatedTime-=a*(1e3/60),o.setState({currentStyle:d,currentVelocity:p,lastIdealStyle:s,lastIdealVelocity:c}),o.unreadPropStyle=null,o.startAnimationIfNecessary()}))},this.state=this.defaultState()}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,null,[{key:"propTypes",value:{defaultStyle:p.default.objectOf(p.default.number),style:p.default.objectOf(p.default.oneOfType([p.default.number,p.default.object])).isRequired,children:p.default.func.isRequired,onRest:p.default.func},enumerable:!0}]),t.prototype.defaultState=function(){var e=this.props,t=e.defaultStyle,n=e.style,r=t||s.default(n),o=a.default(r);return{currentStyle:r,currentVelocity:o,lastIdealStyle:r,lastIdealVelocity:o}},t.prototype.componentDidMount=function(){this.prevTime=l.default(),this.startAnimationIfNecessary()},t.prototype.componentWillReceiveProps=function(e){null!=this.unreadPropStyle&&this.clearUnreadPropStyle(this.unreadPropStyle),this.unreadPropStyle=e.style,null==this.animationID&&(this.prevTime=l.default(),this.startAnimationIfNecessary())},t.prototype.componentWillUnmount=function(){null!=this.animationID&&(c.default.cancel(this.animationID),this.animationID=null)},t.prototype.render=function(){var e=this.props.children(this.state.currentStyle);return e&&d.default.Children.only(e)},t}(d.default.Component);t.default=h,e.exports=t.default},function(e,t,n){(function(t){(function(){var n,r,o,i,a,s;"undefined"!=typeof performance&&null!==performance&&performance.now?e.exports=function(){return performance.now()}:null!=t&&t.hrtime?(e.exports=function(){return(n()-a)/1e6},r=t.hrtime,i=(n=function(){var e;return 1e9*(e=r())[0]+e[1]})(),s=1e9*t.uptime(),a=i-s):Date.now?(e.exports=function(){return Date.now()-o},o=Date.now()):(e.exports=function(){return(new Date).getTime()-o},o=(new Date).getTime())}).call(this)}).call(this,n(151))},function(e,t,n){"use strict";t.__esModule=!0;var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function i(e){return e&&e.__esModule?e:{default:e}}var a=i(n(99)),s=i(n(74)),u=i(n(100)),l=i(n(101)),c=i(n(102)),f=i(n(103)),d=i(n(0)),p=i(n(1));var h=function(e){function t(n){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),e.call(this,n),this.animationID=null,this.prevTime=0,this.accumulatedTime=0,this.unreadPropStyles=null,this.clearUnreadPropStyle=function(e){for(var t=o.state,n=t.currentStyles,i=t.currentVelocities,a=t.lastIdealStyles,s=t.lastIdealVelocities,u=!1,l=0;l<e.length;l++){var c=e[l],f=!1;for(var d in c)if(Object.prototype.hasOwnProperty.call(c,d)){var p=c[d];"number"==typeof p&&(f||(f=!0,u=!0,n[l]=r({},n[l]),i[l]=r({},i[l]),a[l]=r({},a[l]),s[l]=r({},s[l])),n[l][d]=p,i[l][d]=0,a[l][d]=p,s[l][d]=0)}}u&&o.setState({currentStyles:n,currentVelocities:i,lastIdealStyles:a,lastIdealVelocities:s})},this.startAnimationIfNecessary=function(){o.animationID=c.default((function(e){var t=o.props.styles(o.state.lastIdealStyles);if(function(e,t,n){for(var r=0;r<e.length;r++)if(!f.default(e[r],t[r],n[r]))return!1;return!0}(o.state.currentStyles,t,o.state.currentVelocities))return o.animationID=null,void(o.accumulatedTime=0);var n=e||l.default(),r=n-o.prevTime;if(o.prevTime=n,o.accumulatedTime=o.accumulatedTime+r,o.accumulatedTime>1e3/60*10&&(o.accumulatedTime=0),0===o.accumulatedTime)return o.animationID=null,void o.startAnimationIfNecessary();for(var i=(o.accumulatedTime-Math.floor(o.accumulatedTime/(1e3/60))*(1e3/60))/(1e3/60),a=Math.floor(o.accumulatedTime/(1e3/60)),s=[],c=[],d=[],p=[],h=0;h<t.length;h++){var v=t[h],g={},m={},y={},b={};for(var w in v)if(Object.prototype.hasOwnProperty.call(v,w)){var _=v[w];if("number"==typeof _)g[w]=_,m[w]=0,y[w]=_,b[w]=0;else{for(var x=o.state.lastIdealStyles[h][w],k=o.state.lastIdealVelocities[h][w],C=0;C<a;C++){var O=u.default(1e3/60/1e3,x,k,_.val,_.stiffness,_.damping,_.precision);x=O[0],k=O[1]}var E=u.default(1e3/60/1e3,x,k,_.val,_.stiffness,_.damping,_.precision),S=E[0],T=E[1];g[w]=x+(S-x)*i,m[w]=k+(T-k)*i,y[w]=x,b[w]=k}}d[h]=g,p[h]=m,s[h]=y,c[h]=b}o.animationID=null,o.accumulatedTime-=a*(1e3/60),o.setState({currentStyles:d,currentVelocities:p,lastIdealStyles:s,lastIdealVelocities:c}),o.unreadPropStyles=null,o.startAnimationIfNecessary()}))},this.state=this.defaultState()}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,null,[{key:"propTypes",value:{defaultStyles:p.default.arrayOf(p.default.objectOf(p.default.number)),styles:p.default.func.isRequired,children:p.default.func.isRequired},enumerable:!0}]),t.prototype.defaultState=function(){var e=this.props,t=e.defaultStyles,n=e.styles,r=t||n().map(s.default),o=r.map((function(e){return a.default(e)}));return{currentStyles:r,currentVelocities:o,lastIdealStyles:r,lastIdealVelocities:o}},t.prototype.componentDidMount=function(){this.prevTime=l.default(),this.startAnimationIfNecessary()},t.prototype.componentWillReceiveProps=function(e){null!=this.unreadPropStyles&&this.clearUnreadPropStyle(this.unreadPropStyles),this.unreadPropStyles=e.styles(this.state.lastIdealStyles),null==this.animationID&&(this.prevTime=l.default(),this.startAnimationIfNecessary())},t.prototype.componentWillUnmount=function(){null!=this.animationID&&(c.default.cancel(this.animationID),this.animationID=null)},t.prototype.render=function(){var e=this.props.children(this.state.currentStyles);return e&&d.default.Children.only(e)},t}(d.default.Component);t.default=h,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0;var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function i(e){return e&&e.__esModule?e:{default:e}}var a=i(n(99)),s=i(n(74)),u=i(n(100)),l=i(n(280)),c=i(n(101)),f=i(n(102)),d=i(n(103)),p=i(n(0)),h=i(n(1));function v(e,t,n){var r=t;return null==r?e.map((function(e,t){return{key:e.key,data:e.data,style:n[t]}})):e.map((function(e,t){for(var o=0;o<r.length;o++)if(r[o].key===e.key)return{key:r[o].key,data:r[o].data,style:n[t]};return{key:e.key,data:e.data,style:n[t]}}))}function g(e,t,n,r,o,i,s,u,c){for(var f=l.default(r,o,(function(e,r){var o=t(r);return null==o||d.default(i[e],o,s[e])?(n({key:r.key,data:r.data}),null):{key:r.key,data:r.data,style:o}})),p=[],h=[],v=[],g=[],m=0;m<f.length;m++){for(var y=f[m],b=null,w=0;w<r.length;w++)if(r[w].key===y.key){b=w;break}if(null==b){var _=e(y);p[m]=_,v[m]=_;var x=a.default(y.style);h[m]=x,g[m]=x}else p[m]=i[b],v[m]=u[b],h[m]=s[b],g[m]=c[b]}return[f,p,h,v,g]}var m=function(e){function t(n){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),e.call(this,n),this.unmounting=!1,this.animationID=null,this.prevTime=0,this.accumulatedTime=0,this.unreadPropStyles=null,this.clearUnreadPropStyle=function(e){for(var t=g(o.props.willEnter,o.props.willLeave,o.props.didLeave,o.state.mergedPropsStyles,e,o.state.currentStyles,o.state.currentVelocities,o.state.lastIdealStyles,o.state.lastIdealVelocities),n=t[0],i=t[1],a=t[2],s=t[3],u=t[4],l=0;l<e.length;l++){var c=e[l].style,f=!1;for(var d in c)if(Object.prototype.hasOwnProperty.call(c,d)){var p=c[d];"number"==typeof p&&(f||(f=!0,i[l]=r({},i[l]),a[l]=r({},a[l]),s[l]=r({},s[l]),u[l]=r({},u[l]),n[l]={key:n[l].key,data:n[l].data,style:r({},n[l].style)}),i[l][d]=p,a[l][d]=0,s[l][d]=p,u[l][d]=0,n[l].style[d]=p)}}o.setState({currentStyles:i,currentVelocities:a,mergedPropsStyles:n,lastIdealStyles:s,lastIdealVelocities:u})},this.startAnimationIfNecessary=function(){o.unmounting||(o.animationID=f.default((function(e){if(!o.unmounting){var t=o.props.styles,n="function"==typeof t?t(v(o.state.mergedPropsStyles,o.unreadPropStyles,o.state.lastIdealStyles)):t;if(function(e,t,n,r){if(r.length!==t.length)return!1;for(var o=0;o<r.length;o++)if(r[o].key!==t[o].key)return!1;for(o=0;o<r.length;o++)if(!d.default(e[o],t[o].style,n[o]))return!1;return!0}(o.state.currentStyles,n,o.state.currentVelocities,o.state.mergedPropsStyles))return o.animationID=null,void(o.accumulatedTime=0);var r=e||c.default(),i=r-o.prevTime;if(o.prevTime=r,o.accumulatedTime=o.accumulatedTime+i,o.accumulatedTime>1e3/60*10&&(o.accumulatedTime=0),0===o.accumulatedTime)return o.animationID=null,void o.startAnimationIfNecessary();for(var a=(o.accumulatedTime-Math.floor(o.accumulatedTime/(1e3/60))*(1e3/60))/(1e3/60),s=Math.floor(o.accumulatedTime/(1e3/60)),l=g(o.props.willEnter,o.props.willLeave,o.props.didLeave,o.state.mergedPropsStyles,n,o.state.currentStyles,o.state.currentVelocities,o.state.lastIdealStyles,o.state.lastIdealVelocities),f=l[0],p=l[1],h=l[2],m=l[3],y=l[4],b=0;b<f.length;b++){var w=f[b].style,_={},x={},k={},C={};for(var O in w)if(Object.prototype.hasOwnProperty.call(w,O)){var E=w[O];if("number"==typeof E)_[O]=E,x[O]=0,k[O]=E,C[O]=0;else{for(var S=m[b][O],T=y[b][O],j=0;j<s;j++){var M=u.default(1e3/60/1e3,S,T,E.val,E.stiffness,E.damping,E.precision);S=M[0],T=M[1]}var L=u.default(1e3/60/1e3,S,T,E.val,E.stiffness,E.damping,E.precision),A=L[0],P=L[1];_[O]=S+(A-S)*a,x[O]=T+(P-T)*a,k[O]=S,C[O]=T}}m[b]=k,y[b]=C,p[b]=_,h[b]=x}o.animationID=null,o.accumulatedTime-=s*(1e3/60),o.setState({currentStyles:p,currentVelocities:h,lastIdealStyles:m,lastIdealVelocities:y,mergedPropsStyles:f}),o.unreadPropStyles=null,o.startAnimationIfNecessary()}})))},this.state=this.defaultState()}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,null,[{key:"propTypes",value:{defaultStyles:h.default.arrayOf(h.default.shape({key:h.default.string.isRequired,data:h.default.any,style:h.default.objectOf(h.default.number).isRequired})),styles:h.default.oneOfType([h.default.func,h.default.arrayOf(h.default.shape({key:h.default.string.isRequired,data:h.default.any,style:h.default.objectOf(h.default.oneOfType([h.default.number,h.default.object])).isRequired}))]).isRequired,children:h.default.func.isRequired,willEnter:h.default.func,willLeave:h.default.func,didLeave:h.default.func},enumerable:!0},{key:"defaultProps",value:{willEnter:function(e){return s.default(e.style)},willLeave:function(){return null},didLeave:function(){}},enumerable:!0}]),t.prototype.defaultState=function(){var e=this.props,t=e.defaultStyles,n=e.styles,r=e.willEnter,o=e.willLeave,i=e.didLeave,u="function"==typeof n?n(t):n,l=void 0;l=null==t?u:t.map((function(e){for(var t=0;t<u.length;t++)if(u[t].key===e.key)return u[t];return e}));var c=null==t?u.map((function(e){return s.default(e.style)})):t.map((function(e){return s.default(e.style)})),f=null==t?u.map((function(e){return a.default(e.style)})):t.map((function(e){return a.default(e.style)})),d=g(r,o,i,l,u,c,f,c,f),p=d[0];return{currentStyles:d[1],currentVelocities:d[2],lastIdealStyles:d[3],lastIdealVelocities:d[4],mergedPropsStyles:p}},t.prototype.componentDidMount=function(){this.prevTime=c.default(),this.startAnimationIfNecessary()},t.prototype.componentWillReceiveProps=function(e){this.unreadPropStyles&&this.clearUnreadPropStyle(this.unreadPropStyles);var t=e.styles;this.unreadPropStyles="function"==typeof t?t(v(this.state.mergedPropsStyles,this.unreadPropStyles,this.state.lastIdealStyles)):t,null==this.animationID&&(this.prevTime=c.default(),this.startAnimationIfNecessary())},t.prototype.componentWillUnmount=function(){this.unmounting=!0,null!=this.animationID&&(f.default.cancel(this.animationID),this.animationID=null)},t.prototype.render=function(){var e=v(this.state.mergedPropsStyles,this.unreadPropStyles,this.state.currentStyles),t=this.props.children(e);return t&&p.default.Children.only(t)},t}(p.default.Component);t.default=m,e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t,n){for(var r={},o=0;o<e.length;o++)r[e[o].key]=o;var i={};for(o=0;o<t.length;o++)i[t[o].key]=o;var a=[];for(o=0;o<t.length;o++)a[o]=t[o];for(o=0;o<e.length;o++)if(!Object.prototype.hasOwnProperty.call(i,e[o].key)){var s=n(o,e[o]);null!=s&&a.push(s)}return a.sort((function(e,n){var o=i[e.key],a=i[n.key],s=r[e.key],u=r[n.key];if(null!=o&&null!=a)return i[e.key]-i[n.key];if(null!=s&&null!=u)return r[e.key]-r[n.key];if(null!=o){for(var l=0;l<t.length;l++){var c=t[l].key;if(Object.prototype.hasOwnProperty.call(r,c)){if(o<i[c]&&u>r[c])return-1;if(o>i[c]&&u<r[c])return 1}}return 1}for(l=0;l<t.length;l++){c=t[l].key;if(Object.prototype.hasOwnProperty.call(r,c)){if(a<i[c]&&s>r[c])return 1;if(a>i[c]&&s<r[c])return-1}}return-1}))},e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0;var r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e};t.default=function(e,t){return r({},s,t,{val:e})};var o,i=n(152),a=(o=i)&&o.__esModule?o:{default:o},s=r({},a.default.noWobble,{precision:.01});e.exports=t.default},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(){0};e.exports=t.default},function(e,t){e.exports=function(e,t){if(null==e)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.includes(r))continue;n[r]=e[r]}return n},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r=n(104),o=n(153);e.exports=function(e,t,n,i){var a=!n;n||(n={});for(var s=-1,u=t.length;++s<u;){var l=t[s],c=i?i(n[l],e[l],l,n,e):void 0;void 0===c&&(c=e[l]),a?o(n,l,c):r(n,l,c)}return n}},function(e,t,n){var r=n(51),o=n(157);e.exports=function(e){return r((function(t,n){var r=-1,i=n.length,a=i>1?n[i-1]:void 0,s=i>2?n[2]:void 0;for(a=e.length>3&&"function"==typeof a?(i--,a):void 0,s&&o(n[0],n[1],s)&&(a=i<3?void 0:a,i=1),t=Object(t);++r<i;){var u=n[r];u&&e(t,u,r,a)}return t}))}},function(e,t){e.exports=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}},function(e,t,n){var r=n(288),o=n(154),i=n(75),a=o?function(e,t){return o(e,"toString",{configurable:!0,enumerable:!1,value:r(t),writable:!0})}:i;e.exports=a},function(e,t){e.exports=function(e){return function(){return e}}},function(e,t){var n=Date.now;e.exports=function(e){var t=0,r=0;return function(){var o=n(),i=16-(o-r);if(r=o,i>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}},function(e,t){e.exports=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}},function(e,t,n){var r=n(39),o=n(33);e.exports=function(e){return o(e)&&"[object Arguments]"==r(e)}},function(e,t){e.exports=function(){return!1}},function(e,t,n){var r=n(39),o=n(105),i=n(33),a={};a["[object Float32Array]"]=a["[object Float64Array]"]=a["[object Int8Array]"]=a["[object Int16Array]"]=a["[object Int32Array]"]=a["[object Uint8Array]"]=a["[object Uint8ClampedArray]"]=a["[object Uint16Array]"]=a["[object Uint32Array]"]=!0,a["[object Arguments]"]=a["[object Array]"]=a["[object ArrayBuffer]"]=a["[object Boolean]"]=a["[object DataView]"]=a["[object Date]"]=a["[object Error]"]=a["[object Function]"]=a["[object Map]"]=a["[object Number]"]=a["[object Object]"]=a["[object RegExp]"]=a["[object Set]"]=a["[object String]"]=a["[object WeakMap]"]=!1,e.exports=function(e){return i(e)&&o(e.length)&&!!a[r(e)]}},function(e,t,n){(function(e){var r=n(143),o=t&&!t.nodeType&&t,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,a=i&&i.exports===o&&r.process,s=function(){try{var e=i&&i.require&&i.require("util").types;return e||a&&a.binding&&a.binding("util")}catch(e){}}();e.exports=s}).call(this,n(57)(e))},function(e,t,n){var r=n(160)(Object.keys,Object);e.exports=r},function(e,t,n){var r=n(297),o=n(317),i=n(168);e.exports=function(e){var t=o(e);return 1==t.length&&t[0][2]?i(t[0][0],t[0][1]):function(n){return n===e||r(n,e,t)}}},function(e,t,n){var r=n(161),o=n(110);e.exports=function(e,t,n,i){var a=n.length,s=a,u=!i;if(null==e)return!s;for(e=Object(e);a--;){var l=n[a];if(u&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++a<s;){var c=(l=n[a])[0],f=e[c],d=l[1];if(u&&l[2]){if(void 0===f&&!(c in e))return!1}else{var p=new r;if(i)var h=i(f,d,c,e,t,p);if(!(void 0===h?o(d,f,3,i,p):h))return!1}}return!0}},function(e,t,n){var r=n(70);e.exports=function(){this.__data__=new r,this.size=0}},function(e,t){e.exports=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}},function(e,t){e.exports=function(e){return this.__data__.get(e)}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t,n){var r=n(70),o=n(98),i=n(96);e.exports=function(e,t){var n=this.__data__;if(n instanceof r){var a=n.__data__;if(!o||a.length<199)return a.push([e,t]),this.size=++n.size,this;n=this.__data__=new i(a)}return n.set(e,t),this.size=n.size,this}},function(e,t,n){var r=n(161),o=n(162),i=n(307),a=n(310),s=n(164),u=n(23),l=n(106),c=n(107),f="[object Object]",d=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,p,h,v){var g=u(e),m=u(t),y=g?"[object Array]":s(e),b=m?"[object Array]":s(t),w=(y="[object Arguments]"==y?f:y)==f,_=(b="[object Arguments]"==b?f:b)==f,x=y==b;if(x&&l(e)){if(!l(t))return!1;g=!0,w=!1}if(x&&!w)return v||(v=new r),g||c(e)?o(e,t,n,p,h,v):i(e,t,y,n,p,h,v);if(!(1&n)){var k=w&&d.call(e,"__wrapped__"),C=_&&d.call(t,"__wrapped__");if(k||C){var O=k?e.value():e,E=C?t.value():t;return v||(v=new r),h(O,E,n,p,v)}}return!!x&&(v||(v=new r),a(e,t,n,p,h,v))}},function(e,t){e.exports=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this}},function(e,t){e.exports=function(e){return this.__data__.has(e)}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}},function(e,t,n){var r=n(58),o=n(308),i=n(59),a=n(162),s=n(309),u=n(111),l=r?r.prototype:void 0,c=l?l.valueOf:void 0;e.exports=function(e,t,n,r,l,f,d){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!f(new o(e),new o(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return i(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var p=s;case"[object Set]":var h=1&r;if(p||(p=u),e.size!=t.size&&!h)return!1;var v=d.get(e);if(v)return v==t;r|=2,d.set(e,t);var g=a(p(e),p(t),r,l,f,d);return d.delete(e),g;case"[object Symbol]":if(c)return c.call(e)==c.call(t)}return!1}},function(e,t,n){var r=n(32).Uint8Array;e.exports=r},function(e,t){e.exports=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}},function(e,t,n){var r=n(311),o=Object.prototype.hasOwnProperty;e.exports=function(e,t,n,i,a,s){var u=1&n,l=r(e),c=l.length;if(c!=r(t).length&&!u)return!1;for(var f=c;f--;){var d=l[f];if(!(u?d in t:o.call(t,d)))return!1}var p=s.get(e),h=s.get(t);if(p&&h)return p==t&&h==e;var v=!0;s.set(e,t),s.set(t,e);for(var g=u;++f<c;){var m=e[d=l[f]],y=t[d];if(i)var b=u?i(y,m,d,t,e,s):i(m,y,d,e,t,s);if(!(void 0===b?m===y||a(m,y,n,i,s):b)){v=!1;break}g||(g="constructor"==d)}if(v&&!g){var w=e.constructor,_=t.constructor;w==_||!("constructor"in e)||!("constructor"in t)||"function"==typeof w&&w instanceof w&&"function"==typeof _&&_ instanceof _||(v=!1)}return s.delete(e),s.delete(t),v}},function(e,t,n){var r=n(312),o=n(313),i=n(41);e.exports=function(e){return r(e,i,o)}},function(e,t,n){var r=n(163),o=n(23);e.exports=function(e,t,n){var i=t(e);return o(e)?i:r(i,n(e))}},function(e,t,n){var r=n(112),o=n(314),i=Object.prototype.propertyIsEnumerable,a=Object.getOwnPropertySymbols,s=a?function(e){return null==e?[]:(e=Object(e),r(a(e),(function(t){return i.call(e,t)})))}:o;e.exports=s},function(e,t){e.exports=function(){return[]}},function(e,t,n){var r=n(45)(n(32),"DataView");e.exports=r},function(e,t,n){var r=n(45)(n(32),"Promise");e.exports=r},function(e,t,n){var r=n(167),o=n(41);e.exports=function(e){for(var t=o(e),n=t.length;n--;){var i=t[n],a=e[i];t[n]=[i,a,r(a)]}return t}},function(e,t,n){var r=n(110),o=n(19),i=n(319),a=n(95),s=n(167),u=n(168),l=n(50);e.exports=function(e,t){return a(e)&&s(t)?u(l(e),t):function(n){var a=o(n,e);return void 0===a&&a===t?i(n,e):r(t,a,3)}}},function(e,t,n){var r=n(320),o=n(169);e.exports=function(e,t){return null!=e&&o(e,t,r)}},function(e,t){e.exports=function(e,t){return null!=e&&t in Object(e)}},function(e,t,n){var r=n(322),o=n(323),i=n(95),a=n(50);e.exports=function(e){return i(e)?r(a(e)):o(e)}},function(e,t){e.exports=function(e){return function(t){return null==t?void 0:t[e]}}},function(e,t,n){var r=n(94);e.exports=function(e){return function(t){return r(t,e)}}},function(e,t,n){var r=n(113),o=n(38);e.exports=function(e,t){var n=-1,i=o(e)?Array(e.length):[];return r(e,(function(e,r,o){i[++n]=t(e,r,o)})),i}},function(e,t,n){var r=n(326),o=n(41);e.exports=function(e,t){return e&&r(e,t,o)}},function(e,t,n){var r=n(327)();e.exports=r},function(e,t){e.exports=function(e){return function(t,n,r){for(var o=-1,i=Object(t),a=r(t),s=a.length;s--;){var u=a[e?s:++o];if(!1===n(i[u],u,i))break}return t}}},function(e,t,n){var r=n(38);e.exports=function(e,t){return function(n,o){if(null==n)return n;if(!r(n))return e(n,o);for(var i=n.length,a=t?i:-1,s=Object(n);(t?a--:++a<i)&&!1!==o(s[a],a,s););return n}}},function(e,t){e.exports=function(e){if(Array.isArray(e))return e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,s=[],u=!0,l=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=i.call(n)).done)&&(s.push(r.value),s.length!==t);u=!0);}catch(e){l=!0,o=e}finally{try{if(!u&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(l)throw o}}return s}},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"DraggableCore",{enumerable:!0,get:function(){return c.default}}),t.default=void 0;var r=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=p(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(r,i,a):r[i]=e[i]}r.default=e,n&&n.set(e,r);return r}(n(0)),o=d(n(1)),i=d(n(47)),a=d(n(333)),s=n(114),u=n(172),l=n(80),c=d(n(335)),f=d(n(173));function d(e){return e&&e.__esModule?e:{default:e}}function p(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(p=function(e){return e?n:t})(e)}function h(){return(h=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function v(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}class g extends r.Component{static getDerivedStateFromProps(e,t){let{position:n}=e,{prevPropsPosition:r}=t;return!n||r&&n.x===r.x&&n.y===r.y?null:((0,f.default)("Draggable: getDerivedStateFromProps %j",{position:n,prevPropsPosition:r}),{x:n.x,y:n.y,prevPropsPosition:{...n}})}constructor(e){super(e),v(this,"onDragStart",(e,t)=>{(0,f.default)("Draggable: onDragStart: %j",t);if(!1===this.props.onStart(e,(0,u.createDraggableData)(this,t)))return!1;this.setState({dragging:!0,dragged:!0})}),v(this,"onDrag",(e,t)=>{if(!this.state.dragging)return!1;(0,f.default)("Draggable: onDrag: %j",t);const n=(0,u.createDraggableData)(this,t),r={x:n.x,y:n.y,slackX:0,slackY:0};if(this.props.bounds){const{x:e,y:t}=r;r.x+=this.state.slackX,r.y+=this.state.slackY;const[o,i]=(0,u.getBoundPosition)(this,r.x,r.y);r.x=o,r.y=i,r.slackX=this.state.slackX+(e-r.x),r.slackY=this.state.slackY+(t-r.y),n.x=r.x,n.y=r.y,n.deltaX=r.x-this.state.x,n.deltaY=r.y-this.state.y}if(!1===this.props.onDrag(e,n))return!1;this.setState(r)}),v(this,"onDragStop",(e,t)=>{if(!this.state.dragging)return!1;if(!1===this.props.onStop(e,(0,u.createDraggableData)(this,t)))return!1;(0,f.default)("Draggable: onDragStop: %j",t);const n={dragging:!1,slackX:0,slackY:0};if(Boolean(this.props.position)){const{x:e,y:t}=this.props.position;n.x=e,n.y=t}this.setState(n)}),this.state={dragging:!1,dragged:!1,x:e.position?e.position.x:e.defaultPosition.x,y:e.position?e.position.y:e.defaultPosition.y,prevPropsPosition:{...e.position},slackX:0,slackY:0,isElementSVG:!1},!e.position||e.onDrag||e.onStop||console.warn("A `position` was applied to this <Draggable>, without drag handlers. This will make this component effectively undraggable. Please attach `onDrag` or `onStop` handlers so you can adjust the `position` of this element.")}componentDidMount(){void 0!==window.SVGElement&&this.findDOMNode()instanceof window.SVGElement&&this.setState({isElementSVG:!0})}componentWillUnmount(){this.setState({dragging:!1})}findDOMNode(){var e,t;return null!==(e=null===(t=this.props)||void 0===t||null===(t=t.nodeRef)||void 0===t?void 0:t.current)&&void 0!==e?e:i.default.findDOMNode(this)}render(){const{axis:e,bounds:t,children:n,defaultPosition:o,defaultClassName:i,defaultClassNameDragging:l,defaultClassNameDragged:f,position:d,positionOffset:p,scale:v,...g}=this.props;let m={},y=null;const b=!Boolean(d)||this.state.dragging,w=d||o,_={x:(0,u.canDragX)(this)&&b?this.state.x:w.x,y:(0,u.canDragY)(this)&&b?this.state.y:w.y};this.state.isElementSVG?y=(0,s.createSVGTransform)(_,p):m=(0,s.createCSSTransform)(_,p);const x=(0,a.default)(n.props.className||"",i,{[l]:this.state.dragging,[f]:this.state.dragged});return r.createElement(c.default,h({},g,{onStart:this.onDragStart,onDrag:this.onDrag,onStop:this.onDragStop}),r.cloneElement(r.Children.only(n),{className:x,style:{...n.props.style,...m},transform:y}))}}t.default=g,v(g,"displayName","Draggable"),v(g,"propTypes",{...c.default.propTypes,axis:o.default.oneOf(["both","x","y","none"]),bounds:o.default.oneOfType([o.default.shape({left:o.default.number,right:o.default.number,top:o.default.number,bottom:o.default.number}),o.default.string,o.default.oneOf([!1])]),defaultClassName:o.default.string,defaultClassNameDragging:o.default.string,defaultClassNameDragged:o.default.string,defaultPosition:o.default.shape({x:o.default.number,y:o.default.number}),positionOffset:o.default.shape({x:o.default.oneOfType([o.default.number,o.default.string]),y:o.default.oneOfType([o.default.number,o.default.string])}),position:o.default.shape({x:o.default.number,y:o.default.number}),className:l.dontSetMe,style:l.dontSetMe,transform:l.dontSetMe}),v(g,"defaultProps",{...c.default.defaultProps,axis:"both",bounds:!1,defaultClassName:"react-draggable",defaultClassNameDragging:"react-draggable-dragging",defaultClassNameDragged:"react-draggable-dragged",defaultPosition:{x:0,y:0},scale:1})},function(e,t,n){"use strict";function r(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=r(e[t]))&&(o&&(o+=" "),o+=n);else for(t in e)e[t]&&(o&&(o+=" "),o+=t);return o}function o(){for(var e,t,n=0,o="";n<arguments.length;)(e=arguments[n++])&&(t=r(e))&&(o&&(o+=" "),o+=t);return o}n.r(t),n.d(t,"clsx",(function(){return o})),t.default=o},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.browserPrefixToKey=i,t.browserPrefixToStyle=function(e,t){return t?"-".concat(t.toLowerCase(),"-").concat(e):e},t.default=void 0,t.getPrefix=o;const r=["Moz","Webkit","O","ms"];function o(){var e;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"transform";if("undefined"==typeof window)return"";const n=null===(e=window.document)||void 0===e||null===(e=e.documentElement)||void 0===e?void 0:e.style;if(!n)return"";if(t in n)return"";for(let e=0;e<r.length;e++)if(i(t,r[e])in n)return r[e];return""}function i(e,t){return t?"".concat(t).concat(function(e){let t="",n=!0;for(let r=0;r<e.length;r++)n?(t+=e[r].toUpperCase(),n=!1):"-"===e[r]?n=!0:t+=e[r];return t}(e)):e}t.default=o()},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=f(t);if(n&&n.has(e))return n.get(e);var r={},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(r,i,a):r[i]=e[i]}r.default=e,n&&n.set(e,r);return r}(n(0)),o=c(n(1)),i=c(n(47)),a=n(114),s=n(172),u=n(80),l=c(n(173));function c(e){return e&&e.__esModule?e:{default:e}}function f(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(f=function(e){return e?n:t})(e)}function d(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=typeof e||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==typeof t?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const p={start:"touchstart",move:"touchmove",stop:"touchend"},h={start:"mousedown",move:"mousemove",stop:"mouseup"};let v=h;class g extends r.Component{constructor(){super(...arguments),d(this,"dragging",!1),d(this,"lastX",NaN),d(this,"lastY",NaN),d(this,"touchIdentifier",null),d(this,"mounted",!1),d(this,"handleDragStart",e=>{if(this.props.onMouseDown(e),!this.props.allowAnyClick&&"number"==typeof e.button&&0!==e.button)return!1;const t=this.findDOMNode();if(!t||!t.ownerDocument||!t.ownerDocument.body)throw new Error("<DraggableCore> not mounted on DragStart!");const{ownerDocument:n}=t;if(this.props.disabled||!(e.target instanceof n.defaultView.Node)||this.props.handle&&!(0,a.matchesSelectorAndParentsTo)(e.target,this.props.handle,t)||this.props.cancel&&(0,a.matchesSelectorAndParentsTo)(e.target,this.props.cancel,t))return;"touchstart"===e.type&&e.preventDefault();const r=(0,a.getTouchIdentifier)(e);this.touchIdentifier=r;const o=(0,s.getControlPosition)(e,r,this);if(null==o)return;const{x:i,y:u}=o,c=(0,s.createCoreData)(this,i,u);(0,l.default)("DraggableCore: handleDragStart: %j",c),(0,l.default)("calling",this.props.onStart);!1!==this.props.onStart(e,c)&&!1!==this.mounted&&(this.props.enableUserSelectHack&&(0,a.addUserSelectStyles)(n),this.dragging=!0,this.lastX=i,this.lastY=u,(0,a.addEvent)(n,v.move,this.handleDrag),(0,a.addEvent)(n,v.stop,this.handleDragStop))}),d(this,"handleDrag",e=>{const t=(0,s.getControlPosition)(e,this.touchIdentifier,this);if(null==t)return;let{x:n,y:r}=t;if(Array.isArray(this.props.grid)){let e=n-this.lastX,t=r-this.lastY;if([e,t]=(0,s.snapToGrid)(this.props.grid,e,t),!e&&!t)return;n=this.lastX+e,r=this.lastY+t}const o=(0,s.createCoreData)(this,n,r);(0,l.default)("DraggableCore: handleDrag: %j",o);if(!1!==this.props.onDrag(e,o)&&!1!==this.mounted)this.lastX=n,this.lastY=r;else try{this.handleDragStop(new MouseEvent("mouseup"))}catch(e){const t=document.createEvent("MouseEvents");t.initMouseEvent("mouseup",!0,!0,window,0,0,0,0,0,!1,!1,!1,!1,0,null),this.handleDragStop(t)}}),d(this,"handleDragStop",e=>{if(!this.dragging)return;const t=(0,s.getControlPosition)(e,this.touchIdentifier,this);if(null==t)return;let{x:n,y:r}=t;if(Array.isArray(this.props.grid)){let e=n-this.lastX||0,t=r-this.lastY||0;[e,t]=(0,s.snapToGrid)(this.props.grid,e,t),n=this.lastX+e,r=this.lastY+t}const o=(0,s.createCoreData)(this,n,r);if(!1===this.props.onStop(e,o)||!1===this.mounted)return!1;const i=this.findDOMNode();i&&this.props.enableUserSelectHack&&(0,a.removeUserSelectStyles)(i.ownerDocument),(0,l.default)("DraggableCore: handleDragStop: %j",o),this.dragging=!1,this.lastX=NaN,this.lastY=NaN,i&&((0,l.default)("DraggableCore: Removing handlers"),(0,a.removeEvent)(i.ownerDocument,v.move,this.handleDrag),(0,a.removeEvent)(i.ownerDocument,v.stop,this.handleDragStop))}),d(this,"onMouseDown",e=>(v=h,this.handleDragStart(e))),d(this,"onMouseUp",e=>(v=h,this.handleDragStop(e))),d(this,"onTouchStart",e=>(v=p,this.handleDragStart(e))),d(this,"onTouchEnd",e=>(v=p,this.handleDragStop(e)))}componentDidMount(){this.mounted=!0;const e=this.findDOMNode();e&&(0,a.addEvent)(e,p.start,this.onTouchStart,{passive:!1})}componentWillUnmount(){this.mounted=!1;const e=this.findDOMNode();if(e){const{ownerDocument:t}=e;(0,a.removeEvent)(t,h.move,this.handleDrag),(0,a.removeEvent)(t,p.move,this.handleDrag),(0,a.removeEvent)(t,h.stop,this.handleDragStop),(0,a.removeEvent)(t,p.stop,this.handleDragStop),(0,a.removeEvent)(e,p.start,this.onTouchStart,{passive:!1}),this.props.enableUserSelectHack&&(0,a.removeUserSelectStyles)(t)}}findDOMNode(){var e,t;return null!==(e=this.props)&&void 0!==e&&e.nodeRef?null===(t=this.props)||void 0===t||null===(t=t.nodeRef)||void 0===t?void 0:t.current:i.default.findDOMNode(this)}render(){return r.cloneElement(r.Children.only(this.props.children),{onMouseDown:this.onMouseDown,onMouseUp:this.onMouseUp,onTouchEnd:this.onTouchEnd})}}t.default=g,d(g,"displayName","DraggableCore"),d(g,"propTypes",{allowAnyClick:o.default.bool,children:o.default.node.isRequired,disabled:o.default.bool,enableUserSelectHack:o.default.bool,offsetParent:function(e,t){if(e[t]&&1!==e[t].nodeType)throw new Error("Draggable's offsetParent must be a DOM Node.")},grid:o.default.arrayOf(o.default.number),handle:o.default.string,cancel:o.default.string,nodeRef:o.default.object,onStart:o.default.func,onDrag:o.default.func,onStop:o.default.func,onMouseDown:o.default.func,scale:o.default.number,className:u.dontSetMe,style:u.dontSetMe,transform:u.dontSetMe}),d(g,"defaultProps",{allowAnyClick:!1,disabled:!1,enableUserSelectHack:!0,onStart:function(){},onDrag:function(){},onStop:function(){},onMouseDown:function(){},scale:1})},function(e,t,n){var r=n(113);e.exports=function(e,t){var n=[];return r(e,(function(e,r,o){t(e,r,o)&&n.push(e)})),n}},function(e,t){e.exports=function(e,t,n,r){for(var o=e.length,i=n+(r?1:-1);r?i--:++i<o;)if(t(e[i],i,e))return i;return-1}},function(e,t){e.exports=function(e){return e!=e}},function(e,t){e.exports=function(e,t,n){for(var r=n-1,o=e.length;++r<o;)if(e[r]===t)return r;return-1}},function(e,t,n){var r=n(165),o=n(40),i=n(111),a=r&&1/i(new r([,-0]))[1]==1/0?function(e){return new r(e)}:o;e.exports=a},function(e,t,n){var r=n(171);e.exports=function(e){if(Array.isArray(e))return r(e)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=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.")},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";function r(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),r(n(176)),r(n(345))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(346);t.createDragDropManager=function(e,t){return new r.default(e,t)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(462),o=n(347),i=n(82),a=n(359),s=n(361),u=function(){function e(e,t){void 0===t&&(t={}),this.context=t,this.isSetUp=!1;var n=r.createStore(o.default);this.store=n,this.monitor=new a.default(n,new s.default(n)),this.backend=e(this),n.subscribe(this.handleRefCountChange.bind(this))}return e.prototype.getContext=function(){return this.context},e.prototype.getMonitor=function(){return this.monitor},e.prototype.getBackend=function(){return this.backend},e.prototype.getRegistry=function(){return this.monitor.registry},e.prototype.getActions=function(){var e=this,t=this.store.dispatch;var n=i.default(this);return Object.keys(n).reduce((function(r,o){var i,a=n[o];return r[o]=(i=a,function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var o=i.apply(e,n);void 0!==o&&t(o)}),r}),{})},e.prototype.dispatch=function(e){this.store.dispatch(e)},e.prototype.handleRefCountChange=function(){var e=this.store.getState().refCount>0;e&&!this.isSetUp?(this.backend.setup(),this.isSetUp=!0):!e&&this.isSetUp&&(this.backend.teardown(),this.isSetUp=!1)},e}();t.default=u},function(e,t,n){"use strict";var r=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(348),i=n(349),a=n(350),s=n(351),u=n(358),l=n(19);t.default=function(e,t){return void 0===e&&(e={}),{dirtyHandlerIds:s.default(e.dirtyHandlerIds,{type:t.type,payload:r({},t.payload,{prevTargetIds:l(e,"dragOperation.targetIds",[])})}),dragOffset:o.default(e.dragOffset,t),refCount:a.default(e.refCount,t),dragOperation:i.default(e.dragOperation,t),stateId:u.default(e.stateId)}}},function(e,t,n){"use strict";var r=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(82),i=n(178),a={initialSourceClientOffset:null,initialClientOffset:null,clientOffset:null};t.default=function(e,t){void 0===e&&(e=a);var n=t.payload;switch(t.type){case o.BEGIN_DRAG:return{initialSourceClientOffset:n.sourceClientOffset,initialClientOffset:n.clientOffset,clientOffset:n.clientOffset};case o.HOVER:return i.areCoordsEqual(e.clientOffset,n.clientOffset)?e:r({},e,{clientOffset:n.clientOffset});case o.END_DRAG:case o.DROP:return a;default:return e}}},function(e,t,n){"use strict";var r=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var o=n(82),i=n(83),a=n(179),s={itemType:null,item:null,sourceId:null,targetIds:[],dropResult:null,didDrop:!1,isSourcePublic:null};t.default=function(e,t){void 0===e&&(e=s);var n=t.payload;switch(t.type){case o.BEGIN_DRAG:return r({},e,{itemType:n.itemType,item:n.item,sourceId:n.sourceId,isSourcePublic:n.isSourcePublic,dropResult:null,didDrop:!1});case o.PUBLISH_DRAG_SOURCE:return r({},e,{isSourcePublic:!0});case o.HOVER:return r({},e,{targetIds:n.targetIds});case i.REMOVE_TARGET:return-1===e.targetIds.indexOf(n.targetId)?e:r({},e,{targetIds:a(e.targetIds,n.targetId)});case o.DROP:return r({},e,{dropResult:n.dropResult,didDrop:!0,targetIds:[]});case o.END_DRAG:return r({},e,{itemType:null,item:null,sourceId:null,dropResult:null,didDrop:!1,isSourcePublic:null,targetIds:[]});default:return e}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(83);t.default=function(e,t){switch(void 0===e&&(e=0),t.type){case r.ADD_SOURCE:case r.ADD_TARGET:return e+1;case r.REMOVE_SOURCE:case r.REMOVE_TARGET:return e-1;default:return e}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(82),o=n(83),i=n(178),a=n(181),s=n(355);t.default=function(e,t){switch(void 0===e&&(e=a.NONE),t.type){case r.HOVER:break;case o.ADD_SOURCE:case o.ADD_TARGET:case o.REMOVE_TARGET:case o.REMOVE_SOURCE:return a.NONE;case r.BEGIN_DRAG:case r.PUBLISH_DRAG_SOURCE:case r.END_DRAG:case r.DROP:default:return a.ALL}var n=t.payload,u=n.targetIds,l=void 0===u?[]:u,c=n.prevTargetIds,f=void 0===c?[]:c,d=s(l,f);if(!(d.length>0||!i.areArraysEqual(l,f)))return a.NONE;var p=f[f.length-1],h=l[l.length-1];return p!==h&&(p&&d.push(p),h&&d.push(h)),d}},function(e,t,n){var r=n(49),o=n(353),i=n(51),a=n(354),s=i((function(e){var t=r(e,a);return t.length&&t[0]===e[0]?o(t):[]}));e.exports=s},function(e,t,n){var r=n(78),o=n(115),i=n(116),a=n(49),s=n(108),u=n(79),l=Math.min;e.exports=function(e,t,n){for(var c=n?i:o,f=e[0].length,d=e.length,p=d,h=Array(d),v=1/0,g=[];p--;){var m=e[p];p&&t&&(m=a(m,s(t))),v=l(m.length,v),h[p]=!n&&(t||f>=120&&m.length>=120)?new r(p&&m):void 0}m=e[0];var y=-1,b=h[0];e:for(;++y<f&&g.length<v;){var w=m[y],_=t?t(w):w;if(w=n||0!==w?w:0,!(b?u(b,_):c(g,_,n))){for(p=d;--p;){var x=h[p];if(!(x?u(x,_):c(e[p],_,n)))continue e}b&&b.push(_),g.push(w)}}return g}},function(e,t,n){var r=n(84);e.exports=function(e){return r(e)?e:[]}},function(e,t,n){var r=n(112),o=n(51),i=n(356),a=n(84),s=o((function(e){return i(r(e,a))}));e.exports=s},function(e,t,n){var r=n(180),o=n(118),i=n(81);e.exports=function(e,t,n){var a=e.length;if(a<2)return a?i(e[0]):[];for(var s=-1,u=Array(a);++s<a;)for(var l=e[s],c=-1;++c<a;)c!=s&&(u[s]=r(u[s]||l,e[c],t,n));return i(o(u,1),t,n)}},function(e,t,n){var r=n(58),o=n(77),i=n(23),a=r?r.isConcatSpreadable:void 0;e.exports=function(e){return i(e)||o(e)||!!(a&&e&&e[a])}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){return void 0===e&&(e=0),e+1}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(177),o=n(360),i=n(181),a=n(26),s=function(){function e(e,t){this.store=e,this.registry=t}return e.prototype.subscribeToStateChange=function(e,t){var n=this;void 0===t&&(t={handlerIds:void 0});var r=t.handlerIds;a("function"==typeof e,"listener must be a function."),a(void 0===r||Array.isArray(r),"handlerIds, when specified, must be an array of strings.");var o=this.store.getState().stateId;return this.store.subscribe((function(){var t=n.store.getState(),a=t.stateId;try{a===o||a===o+1&&!i.areDirty(t.dirtyHandlerIds,r)||e()}finally{o=a}}))},e.prototype.subscribeToOffsetChange=function(e){var t=this;a("function"==typeof e,"listener must be a function.");var n=this.store.getState().dragOffset;return this.store.subscribe((function(){var r=t.store.getState().dragOffset;r!==n&&(n=r,e())}))},e.prototype.canDragSource=function(e){var t=this.registry.getSource(e);return a(t,"Expected to find a valid source."),!this.isDragging()&&t.canDrag(this,e)},e.prototype.canDropOnTarget=function(e){var t=this.registry.getTarget(e);if(a(t,"Expected to find a valid target."),!this.isDragging()||this.didDrop())return!1;var n=this.registry.getTargetType(e),o=this.getItemType();return r.default(n,o)&&t.canDrop(this,e)},e.prototype.isDragging=function(){return Boolean(this.getItemType())},e.prototype.isDraggingSource=function(e){var t=this.registry.getSource(e,!0);return a(t,"Expected to find a valid source."),!(!this.isDragging()||!this.isSourcePublic())&&(this.registry.getSourceType(e)===this.getItemType()&&t.isDragging(this,e))},e.prototype.isOverTarget=function(e,t){void 0===t&&(t={shallow:!1});var n=t.shallow;if(!this.isDragging())return!1;var o=this.registry.getTargetType(e),i=this.getItemType();if(i&&!r.default(o,i))return!1;var a=this.getTargetIds();if(!a.length)return!1;var s=a.indexOf(e);return n?s===a.length-1:s>-1},e.prototype.getItemType=function(){return this.store.getState().dragOperation.itemType},e.prototype.getItem=function(){return this.store.getState().dragOperation.item},e.prototype.getSourceId=function(){return this.store.getState().dragOperation.sourceId},e.prototype.getTargetIds=function(){return this.store.getState().dragOperation.targetIds},e.prototype.getDropResult=function(){return this.store.getState().dragOperation.dropResult},e.prototype.didDrop=function(){return this.store.getState().dragOperation.didDrop},e.prototype.isSourcePublic=function(){return this.store.getState().dragOperation.isSourcePublic},e.prototype.getInitialClientOffset=function(){return this.store.getState().dragOffset.initialClientOffset},e.prototype.getInitialSourceClientOffset=function(){return this.store.getState().dragOffset.initialSourceClientOffset},e.prototype.getClientOffset=function(){return this.store.getState().dragOffset.clientOffset},e.prototype.getSourceClientOffset=function(){return o.getSourceClientOffset(this.store.getState().dragOffset)},e.prototype.getDifferenceFromInitialOffset=function(){return o.getDifferenceFromInitialOffset(this.store.getState().dragOffset)},e}();t.default=s},function(e,t,n){"use strict";function r(e,t){return{x:e.x+t.x,y:e.y+t.y}}function o(e,t){return{x:e.x-t.x,y:e.y-t.y}}Object.defineProperty(t,"__esModule",{value:!0}),t.add=r,t.subtract=o,t.getSourceClientOffset=function(e){var t=e.clientOffset,n=e.initialClientOffset,i=e.initialSourceClientOffset;return t&&n&&i?o(r(t,i),n):null},t.getDifferenceFromInitialOffset=function(e){var t=e.clientOffset,n=e.initialClientOffset;return t&&n?o(t,n):null}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(83),o=n(362),i=n(176),a=n(363),s=n(26),u=n(364);function l(e){switch(e[0]){case"S":return i.HandlerRole.SOURCE;case"T":return i.HandlerRole.TARGET;default:s(!1,"Cannot parse handler ID: "+e)}}function c(e,t){var n=e.entries(),r=!1;do{var o=n.next(),i=o.done;if(o.value[1]===t)return!0;r=i}while(!r);return!1}var f=function(){function e(e){this.store=e,this.types=new Map,this.dragSources=new Map,this.dropTargets=new Map,this.pinnedSourceId=null,this.pinnedSource=null}return e.prototype.addSource=function(e,t){a.validateType(e),a.validateSourceContract(t);var n=this.addHandler(i.HandlerRole.SOURCE,e,t);return this.store.dispatch(r.addSource(n)),n},e.prototype.addTarget=function(e,t){a.validateType(e,!0),a.validateTargetContract(t);var n=this.addHandler(i.HandlerRole.TARGET,e,t);return this.store.dispatch(r.addTarget(n)),n},e.prototype.containsHandler=function(e){return c(this.dragSources,e)||c(this.dropTargets,e)},e.prototype.getSource=function(e,t){return void 0===t&&(t=!1),s(this.isSourceId(e),"Expected a valid source ID."),t&&e===this.pinnedSourceId?this.pinnedSource:this.dragSources.get(e)},e.prototype.getTarget=function(e){return s(this.isTargetId(e),"Expected a valid target ID."),this.dropTargets.get(e)},e.prototype.getSourceType=function(e){return s(this.isSourceId(e),"Expected a valid source ID."),this.types.get(e)},e.prototype.getTargetType=function(e){return s(this.isTargetId(e),"Expected a valid target ID."),this.types.get(e)},e.prototype.isSourceId=function(e){return l(e)===i.HandlerRole.SOURCE},e.prototype.isTargetId=function(e){return l(e)===i.HandlerRole.TARGET},e.prototype.removeSource=function(e){var t=this;s(this.getSource(e),"Expected an existing source."),this.store.dispatch(r.removeSource(e)),u((function(){t.dragSources.delete(e),t.types.delete(e)}))},e.prototype.removeTarget=function(e){s(this.getTarget(e),"Expected an existing target."),this.store.dispatch(r.removeTarget(e)),this.dropTargets.delete(e),this.types.delete(e)},e.prototype.pinSource=function(e){var t=this.getSource(e);s(t,"Expected an existing source."),this.pinnedSourceId=e,this.pinnedSource=t},e.prototype.unpinSource=function(){s(this.pinnedSource,"No source is pinned at the time."),this.pinnedSourceId=null,this.pinnedSource=null},e.prototype.addHandler=function(e,t,n){var r=function(e){var t=o.default().toString();switch(e){case i.HandlerRole.SOURCE:return"S"+t;case i.HandlerRole.TARGET:return"T"+t;default:throw new Error("Unknown Handler Role: "+e)}}(e);return this.types.set(r,t),e===i.HandlerRole.SOURCE?this.dragSources.set(r,n):e===i.HandlerRole.TARGET&&this.dropTargets.set(r,n),r},e}();t.default=f},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=0;t.default=function(){return r++}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(26);t.validateSourceContract=function(e){r("function"==typeof e.canDrag,"Expected canDrag to be a function."),r("function"==typeof e.beginDrag,"Expected beginDrag to be a function."),r("function"==typeof e.endDrag,"Expected endDrag to be a function.")},t.validateTargetContract=function(e){r("function"==typeof e.canDrop,"Expected canDrop to be a function."),r("function"==typeof e.hover,"Expected hover to be a function."),r("function"==typeof e.drop,"Expected beginDrag to be a function.")},t.validateType=function e(t,n){n&&Array.isArray(t)?t.forEach((function(t){return e(t,!1)})):r("string"==typeof t||"symbol"==typeof t,n?"Type can only be a string, a symbol, or an array of either.":"Type can only be a string or a symbol.")}},function(e,t,n){"use strict";var r=n(365),o=[],i=[],a=r.makeRequestCallFromTimer((function(){if(i.length)throw i.shift()}));function s(e){var t;(t=o.length?o.pop():new u).task=e,r(t)}function u(){this.task=null}e.exports=s,u.prototype.call=function(){try{this.task.call()}catch(e){s.onerror?s.onerror(e):(i.push(e),a())}finally{this.task=null,o[o.length]=this}}},function(e,t,n){"use strict";(function(t){function n(e){o.length||(r(),!0),o[o.length]=e}e.exports=n;var r,o=[],i=0;function a(){for(;i<o.length;){var e=i;if(i+=1,o[e].call(),i>1024){for(var t=0,n=o.length-i;t<n;t++)o[t]=o[t+i];o.length-=i,i=0}}o.length=0,i=0,!1}var s,u,l,c=void 0!==t?t:self,f=c.MutationObserver||c.WebKitMutationObserver;function d(e){return function(){var t=setTimeout(r,0),n=setInterval(r,50);function r(){clearTimeout(t),clearInterval(n),e()}}}"function"==typeof f?(s=1,u=new f(a),l=document.createTextNode(""),u.observe(l,{characterData:!0}),r=function(){s=-s,l.data=s}):r=d(a),n.requestFlush=r,n.makeRequestCallFromTimer=d}).call(this,n(31))},function(e,t,n){"use strict";var r,o=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),i=this&&this.__assign||Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e};Object.defineProperty(t,"__esModule",{value:!0});var a=n(0),s=n(85),u=n(117),l=n(119),c=n(52),f=n(26),d=n(61),p=n(120).default;t.default=function(e,t){return void 0===t&&(t={}),s.default("DragLayer","collect[, options]",e,t),f("function"==typeof e,'Expected "collect" provided as the first argument to DragLayer to be a function that collects props to inject into the component. ',"Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-layer.html",e),f(c(t),'Expected "options" provided as the second argument to DragLayer to be a plain object when specified. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-layer.html',t),function(n){var r=n,s=t.arePropsEqual,c=void 0===s?d:s,h=r.displayName||r.name||"Component",v=function(t){function s(e){var n=t.call(this,e)||this;return n.isCurrentlyMounted=!1,n.ref=a.createRef(),n.handleChange=n.handleChange.bind(n),n}return o(s,t),Object.defineProperty(s.prototype,"DecoratedComponent",{get:function(){return n},enumerable:!0,configurable:!0}),s.prototype.getDecoratedComponentInstance=function(){return f(this.ref.current,"In order to access an instance of the decorated component it can not be a stateless component."),this.ref.current},s.prototype.shouldComponentUpdate=function(e,t){return!c(e,this.props)||!d(t,this.state)},s.prototype.componentDidMount=function(){this.isCurrentlyMounted=!0,this.handleChange()},s.prototype.componentWillUnmount=function(){this.isCurrentlyMounted=!1,this.unsubscribeFromOffsetChange&&(this.unsubscribeFromOffsetChange(),this.unsubscribeFromOffsetChange=void 0),this.unsubscribeFromStateChange&&(this.unsubscribeFromStateChange(),this.unsubscribeFromStateChange=void 0)},s.prototype.render=function(){var e=this;return a.createElement(u.Consumer,null,(function(t){var n=t.dragDropManager;return void 0===n?null:(e.receiveDragDropManager(n),e.isCurrentlyMounted?a.createElement(r,i({},e.props,e.state,{ref:p(r)?e.ref:void 0})):null)}))},s.prototype.receiveDragDropManager=function(e){if(void 0===this.manager){this.manager=e,f("object"==typeof e,"Could not find the drag and drop manager in the context of %s. Make sure to wrap the top-level component of your app with DragDropContext. Read more: http://react-dnd.github.io/react-dnd/docs-troubleshooting.html#could-not-find-the-drag-and-drop-manager-in-the-context",h,h);var t=this.manager.getMonitor();this.unsubscribeFromOffsetChange=t.subscribeToOffsetChange(this.handleChange),this.unsubscribeFromStateChange=t.subscribeToStateChange(this.handleChange)}},s.prototype.handleChange=function(){if(this.isCurrentlyMounted){var e=this.getCurrentState();d(e,this.state)||this.setState(e)}},s.prototype.getCurrentState=function(){if(!this.manager)return{};var t=this.manager.getMonitor();return e(t,this.props)},s.displayName="DragLayer("+h+")",s}(a.Component);return l(v,n)}}},function(e,t,n){var r=n(160)(Object.getPrototypeOf,Object);e.exports=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(85),o=n(182),i=n(373),a=n(374),s=n(375),u=n(376),l=n(184),c=n(26),f=n(52);t.default=function(e,t,n,d){void 0===d&&(d={}),r.default("DragSource","type, spec, collect[, options]",e,t,n,d);var p=e;"function"!=typeof e&&(c(l.default(e),'Expected "type" provided as the first argument to DragSource to be a string, or a function that returns a string given the current props. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html',e),p=function(){return e}),c(f(t),'Expected "spec" provided as the second argument to DragSource to be a plain object. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html',t);var h=a.default(t);return c("function"==typeof n,'Expected "collect" provided as the third argument to DragSource to be a function that returns a plain object of props to inject. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html',n),c(f(d),'Expected "options" provided as the fourth argument to DragSource to be a plain object when specified. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html',n),function(e){return o.default({containerDisplayName:"DragSource",createHandler:h,registerHandler:i.default,createMonitor:s.default,createConnector:u.default,DecoratedComponent:e,getType:p,collect:n,options:d})}}},function(e,t,n){"use strict";function r(e){for(var n in e)t.hasOwnProperty(n)||(t[n]=e[n])}Object.defineProperty(t,"__esModule",{value:!0}),r(n(370)),r(n(371)),r(n(372))},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(97),o=n(40),i=function(){function e(e){this.isDisposed=!1,this.action=r(e)?e:o}return e.isDisposable=function(e){return e&&r(e.dispose)},e._fixup=function(t){return e.isDisposable(t)?t:e.empty},e.create=function(t){return new e(t)},e.prototype.dispose=function(){this.isDisposed||(this.action(),this.isDisposed=!0)},e.empty={dispose:o},e}();t.Disposable=i},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){this.isDisposed=!1}return e.prototype.getDisposable=function(){return this.current},e.prototype.setDisposable=function(e){var t=this.isDisposed;if(!t){var n=this.current;this.current=e,n&&n.dispose()}t&&e&&e.dispose()},e.prototype.dispose=function(){if(!this.isDisposed){this.isDisposed=!0;var e=this.current;this.current=void 0,e&&e.dispose()}},e}();t.SerialDisposable=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.isDisposed=!1,this.disposables=e}return e.prototype.add=function(e){this.isDisposed?e.dispose():this.disposables.push(e)},e.prototype.remove=function(e){var t=!1;if(!this.isDisposed){var n=this.disposables.indexOf(e);-1!==n&&(t=!0,this.disposables.splice(n,1),e.dispose())}return t},e.prototype.clear=function(){if(!this.isDisposed){for(var e=this.disposables.length,t=new Array(e),n=0;n<e;n++)t[n]=this.disposables[n];this.disposables=[];for(n=0;n<e;n++)t[n].dispose()}},e.prototype.dispose=function(){if(!this.isDisposed){this.isDisposed=!0;for(var e=this.disposables.length,t=new Array(e),n=0;n<e;n++)t[n]=this.disposables[n];this.disposables=[];for(n=0;n<e;n++)t[n].dispose()}},e}();t.CompositeDisposable=r},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){var r=n.getRegistry(),o=r.addSource(e,t);return{handlerId:o,unregister:function(){r.removeSource(o)}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),o=n(26),i=(n(52),["canDrag","beginDrag","isDragging","endDrag"]),a=["beginDrag"];t.default=function(e){Object.keys(e).forEach((function(t){o(i.indexOf(t)>-1,'Expected the drag source specification to only have some of the following keys: %s. Instead received a specification with an unexpected "%s" key. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html',i.join(", "),t),o("function"==typeof e[t],"Expected %s in the drag source specification to be a function. Instead received a specification with %s: %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html",t,t,e[t])})),a.forEach((function(t){o("function"==typeof e[t],"Expected %s in the drag source specification to be a function. Instead received a specification with %s: %s. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source.html",t,t,e[t])}));var t=function(){function t(e){this.monitor=e,this.props=null,this.ref=r.createRef(),this.beginDrag=this.beginDrag.bind(this)}return t.prototype.receiveProps=function(e){this.props=e},t.prototype.canDrag=function(){return!!this.props&&(!e.canDrag||e.canDrag(this.props,this.monitor))},t.prototype.isDragging=function(t,n){return!!this.props&&(e.isDragging?e.isDragging(this.props,this.monitor):n===t.getSourceId())},t.prototype.beginDrag=function(){if(this.props)return e.beginDrag(this.props,this.monitor,this.ref.current)},t.prototype.endDrag=function(){this.props&&e.endDrag&&e.endDrag(this.props,this.monitor,this.ref.current)},t}();return function(e){return new t(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(26),o=!1,i=!1,a=function(){function e(e){this.internalMonitor=e.getMonitor()}return e.prototype.receiveHandlerId=function(e){this.sourceId=e},e.prototype.canDrag=function(){r(!o,"You may not call monitor.canDrag() inside your canDrag() implementation. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source-monitor.html");try{return o=!0,this.internalMonitor.canDragSource(this.sourceId)}finally{o=!1}},e.prototype.isDragging=function(){r(!i,"You may not call monitor.isDragging() inside your isDragging() implementation. Read more: http://react-dnd.github.io/react-dnd/docs-drag-source-monitor.html");try{return i=!0,this.internalMonitor.isDraggingSource(this.sourceId)}finally{i=!1}},e.prototype.subscribeToStateChange=function(e,t){return this.internalMonitor.subscribeToStateChange(e,t)},e.prototype.isDraggingSource=function(e){return this.internalMonitor.isDraggingSource(e)},e.prototype.isOverTarget=function(e,t){return this.internalMonitor.isOverTarget(e,t)},e.prototype.getTargetIds=function(){return this.internalMonitor.getTargetIds()},e.prototype.isSourcePublic=function(){return this.internalMonitor.isSourcePublic()},e.prototype.getSourceId=function(){return this.internalMonitor.getSourceId()},e.prototype.subscribeToOffsetChange=function(e){return this.internalMonitor.subscribeToOffsetChange(e)},e.prototype.canDragSource=function(e){return this.internalMonitor.canDragSource(e)},e.prototype.canDropOnTarget=function(e){return this.internalMonitor.canDropOnTarget(e)},e.prototype.getItemType=function(){return this.internalMonitor.getItemType()},e.prototype.getItem=function(){return this.internalMonitor.getItem()},e.prototype.getDropResult=function(){return this.internalMonitor.getDropResult()},e.prototype.didDrop=function(){return this.internalMonitor.didDrop()},e.prototype.getInitialClientOffset=function(){return this.internalMonitor.getInitialClientOffset()},e.prototype.getInitialSourceClientOffset=function(){return this.internalMonitor.getInitialSourceClientOffset()},e.prototype.getSourceClientOffset=function(){return this.internalMonitor.getSourceClientOffset()},e.prototype.getClientOffset=function(){return this.internalMonitor.getClientOffset()},e.prototype.getDifferenceFromInitialOffset=function(){return this.internalMonitor.getDifferenceFromInitialOffset()},e}();t.default=function(e){return new a(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(183),o=n(61);t.default=function(e){var t,n,i,a,s,u,l;function c(){a&&(a(),a=void 0),t&&n&&(a=e.connectDragSource(t,n,i))}function f(){l&&(l(),l=void 0),t&&s&&(l=e.connectDragPreview(t,s,u))}return{receiveHandlerId:function(e){e!==t&&(t=e,c(),f())},hooks:r.default({dragSource:function(e,t){e===n&&o(t,i)||(n=e,i=t,c())},dragPreview:function(e,t){e===s&&o(t,u)||(s=e,u=t,f())}})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),o=n(26);t.default=function(e,t){var n=e.ref;return o("string"!=typeof n,"Cannot connect React DnD to an element with an existing string ref. Please convert it to use a callback ref instead, or wrap it into a <span> or <div>. Read more: https://facebook.github.io/react/docs/more-about-refs.html#the-ref-callback-attribute"),n?r.cloneElement(e,{ref:function(e){t(e),n&&n(e)}}):r.cloneElement(e,{ref:t})}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(85),o=n(182),i=n(379),a=n(380),s=n(381),u=n(382),l=n(184),c=n(26),f=n(52);t.default=function(e,t,n,d){void 0===d&&(d={}),r.default("DropTarget","type, spec, collect[, options]",e,t,n,d);var p=e;"function"!=typeof e&&(c(l.default(e,!0),'Expected "type" provided as the first argument to DropTarget to be a string, an array of strings, or a function that returns either given the current props. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target.html',e),p=function(){return e}),c(f(t),'Expected "spec" provided as the second argument to DropTarget to be a plain object. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target.html',t);var h=a.default(t);return c("function"==typeof n,'Expected "collect" provided as the third argument to DropTarget to be a function that returns a plain object of props to inject. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target.html',n),c(f(d),'Expected "options" provided as the fourth argument to DropTarget to be a plain object when specified. Instead, received %s. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target.html',n),function(e){return o.default({containerDisplayName:"DropTarget",createHandler:h,registerHandler:i.default,createMonitor:s.default,createConnector:u.default,DecoratedComponent:e,getType:p,collect:n,options:d})}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t,n){var r=n.getRegistry(),o=r.addTarget(e,t);return{handlerId:o,unregister:function(){r.removeTarget(o)}}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(0),o=n(26),i=(n(52),["canDrop","hover","drop"]);t.default=function(e){Object.keys(e).forEach((function(t){o(i.indexOf(t)>-1,'Expected the drop target specification to only have some of the following keys: %s. Instead received a specification with an unexpected "%s" key. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target.html',i.join(", "),t),o("function"==typeof e[t],"Expected %s in the drop target specification to be a function. Instead received a specification with %s: %s. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target.html",t,t,e[t])}));var t=function(){function t(e){this.monitor=e,this.props=null,this.ref=r.createRef()}return t.prototype.receiveProps=function(e){this.props=e},t.prototype.receiveMonitor=function(e){this.monitor=e},t.prototype.canDrop=function(){return!e.canDrop||e.canDrop(this.props,this.monitor)},t.prototype.hover=function(){e.hover&&e.hover(this.props,this.monitor,this.ref.current)},t.prototype.drop=function(){if(e.drop)return e.drop(this.props,this.monitor,this.ref.current)},t}();return function(e){return new t(e)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(26),o=!1,i=function(){function e(e){this.internalMonitor=e.getMonitor()}return e.prototype.receiveHandlerId=function(e){this.targetId=e},e.prototype.canDrop=function(){r(!o,"You may not call monitor.canDrop() inside your canDrop() implementation. Read more: http://react-dnd.github.io/react-dnd/docs-drop-target-monitor.html");try{return o=!0,this.internalMonitor.canDropOnTarget(this.targetId)}finally{o=!1}},e.prototype.isOver=function(e){return this.internalMonitor.isOverTarget(this.targetId,e)},e.prototype.getItemType=function(){return this.internalMonitor.getItemType()},e.prototype.getItem=function(){return this.internalMonitor.getItem()},e.prototype.getDropResult=function(){return this.internalMonitor.getDropResult()},e.prototype.didDrop=function(){return this.internalMonitor.didDrop()},e.prototype.getInitialClientOffset=function(){return this.internalMonitor.getInitialClientOffset()},e.prototype.getInitialSourceClientOffset=function(){return this.internalMonitor.getInitialSourceClientOffset()},e.prototype.getSourceClientOffset=function(){return this.internalMonitor.getSourceClientOffset()},e.prototype.getClientOffset=function(){return this.internalMonitor.getClientOffset()},e.prototype.getDifferenceFromInitialOffset=function(){return this.internalMonitor.getDifferenceFromInitialOffset()},e}();t.TargetMonitor=i,t.default=function(e){return new i(e)}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(183),o=n(61);t.default=function(e){var t,n,i,a;function s(){a&&(a(),a=void 0),t&&n&&(a=e.connectDropTarget(t,n,i))}return{receiveHandlerId:function(e){e!==t&&(t=e,s())},hooks:r.default({dropTarget:function(e,t){e===n&&o(t,i)||(n=e,i=t,s())}})}}},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},o=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var i=r(n(384)),a=r(n(395));t.getEmptyImage=a.default;var s=o(n(121));t.NativeTypes=s,t.default=function(e){return new i.default(e)}},function(e,t,n){"use strict";var r=this&&this.__decorate||function(e,t,n,r){var o,i=arguments.length,a=i<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(o=e[s])&&(a=(i<3?o(a):i>3?o(t,n,a):o(t,n))||a);return i>3&&a&&Object.defineProperty(t,n,a),a},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},i=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var a=o(n(385)),s=o(n(389)),u=n(185),l=n(391),c=n(393),f=i(n(121)),d=o(n(394)),p=n(61),h=function(){function e(e){this.sourcePreviewNodes={},this.sourcePreviewNodeOptions={},this.sourceNodes={},this.sourceNodeOptions={},this.enterLeaveCounter=new s.default,this.dragStartSourceIds=null,this.dropTargetIds=[],this.dragEnterTargetIds=[],this.currentNativeSource=null,this.currentNativeHandle=null,this.currentDragSourceNode=null,this.currentDragSourceNodeOffset=null,this.currentDragSourceNodeOffsetChanged=!1,this.altKeyPressed=!1,this.mouseMoveTimeoutTimer=null,this.asyncEndDragFrameId=null,this.dragOverTargetIds=null,this.actions=e.getActions(),this.monitor=e.getMonitor(),this.registry=e.getRegistry(),this.context=e.getContext()}return Object.defineProperty(e.prototype,"window",{get:function(){return this.context&&this.context.window?this.context.window:"undefined"!=typeof window?window:void 0},enumerable:!0,configurable:!0}),e.prototype.setup=function(){if(void 0!==this.window){if(this.window.__isReactDndBackendSetUp)throw new Error("Cannot have two HTML5 backends at the same time.");this.window.__isReactDndBackendSetUp=!0,this.addEventListeners(this.window)}},e.prototype.teardown=function(){void 0!==this.window&&(this.window.__isReactDndBackendSetUp=!1,this.removeEventListeners(this.window),this.clearCurrentDragSourceNode(),this.asyncEndDragFrameId&&this.window.cancelAnimationFrame(this.asyncEndDragFrameId))},e.prototype.connectDragPreview=function(e,t,n){var r=this;return this.sourcePreviewNodeOptions[e]=n,this.sourcePreviewNodes[e]=t,function(){delete r.sourcePreviewNodes[e],delete r.sourcePreviewNodeOptions[e]}},e.prototype.connectDragSource=function(e,t,n){var r=this;this.sourceNodes[e]=t,this.sourceNodeOptions[e]=n;var o=function(t){return r.handleDragStart(t,e)},i=function(e){return r.handleSelectStart(e)};return t.setAttribute("draggable",!0),t.addEventListener("dragstart",o),t.addEventListener("selectstart",i),function(){delete r.sourceNodes[e],delete r.sourceNodeOptions[e],t.removeEventListener("dragstart",o),t.removeEventListener("selectstart",i),t.setAttribute("draggable",!1)}},e.prototype.connectDropTarget=function(e,t){var n=this,r=function(t){return n.handleDragEnter(t,e)},o=function(t){return n.handleDragOver(t,e)},i=function(t){return n.handleDrop(t,e)};return t.addEventListener("dragenter",r),t.addEventListener("dragover",o),t.addEventListener("drop",i),function(){t.removeEventListener("dragenter",r),t.removeEventListener("dragover",o),t.removeEventListener("drop",i)}},e.prototype.addEventListeners=function(e){e.addEventListener&&(e.addEventListener("dragstart",this.handleTopDragStart),e.addEventListener("dragstart",this.handleTopDragStartCapture,!0),e.addEventListener("dragend",this.handleTopDragEndCapture,!0),e.addEventListener("dragenter",this.handleTopDragEnter),e.addEventListener("dragenter",this.handleTopDragEnterCapture,!0),e.addEventListener("dragleave",this.handleTopDragLeaveCapture,!0),e.addEventListener("dragover",this.handleTopDragOver),e.addEventListener("dragover",this.handleTopDragOverCapture,!0),e.addEventListener("drop",this.handleTopDrop),e.addEventListener("drop",this.handleTopDropCapture,!0))},e.prototype.removeEventListeners=function(e){e.removeEventListener&&(e.removeEventListener("dragstart",this.handleTopDragStart),e.removeEventListener("dragstart",this.handleTopDragStartCapture,!0),e.removeEventListener("dragend",this.handleTopDragEndCapture,!0),e.removeEventListener("dragenter",this.handleTopDragEnter),e.removeEventListener("dragenter",this.handleTopDragEnterCapture,!0),e.removeEventListener("dragleave",this.handleTopDragLeaveCapture,!0),e.removeEventListener("dragover",this.handleTopDragOver),e.removeEventListener("dragover",this.handleTopDragOverCapture,!0),e.removeEventListener("drop",this.handleTopDrop),e.removeEventListener("drop",this.handleTopDropCapture,!0))},e.prototype.getCurrentSourceNodeOptions=function(){var e=this.monitor.getSourceId(),t=this.sourceNodeOptions[e];return a.default(t||{},{dropEffect:this.altKeyPressed?"copy":"move"})},e.prototype.getCurrentDropEffect=function(){return this.isDraggingNativeItem()?"copy":this.getCurrentSourceNodeOptions().dropEffect},e.prototype.getCurrentSourcePreviewNodeOptions=function(){var e=this.monitor.getSourceId(),t=this.sourcePreviewNodeOptions[e];return a.default(t||{},{anchorX:.5,anchorY:.5,captureDraggingState:!1})},e.prototype.getSourceClientOffset=function(e){return l.getNodeClientOffset(this.sourceNodes[e])},e.prototype.isDraggingNativeItem=function(){var e=this.monitor.getItemType();return Object.keys(f).some((function(t){return f[t]===e}))},e.prototype.beginDragNativeItem=function(e){this.clearCurrentDragSourceNode();var t=c.createNativeDragSource(e);this.currentNativeSource=new t,this.currentNativeHandle=this.registry.addSource(e,this.currentNativeSource),this.actions.beginDrag([this.currentNativeHandle])},e.prototype.asyncEndDragNativeItem=function(){this.window&&(this.asyncEndDragFrameId=this.window.requestAnimationFrame(this.endDragNativeItem))},e.prototype.endDragNativeItem=function(){this.isDraggingNativeItem()&&(this.actions.endDrag(),this.registry.removeSource(this.currentNativeHandle),this.currentNativeHandle=null,this.currentNativeSource=null)},e.prototype.isNodeInDocument=function(e){return!!document&&document.body.contains(e)||!!this.window&&this.window.document.body.contains(e)},e.prototype.endDragIfSourceWasRemovedFromDOM=function(){var e=this.currentDragSourceNode;this.isNodeInDocument(e)||this.clearCurrentDragSourceNode()&&this.actions.endDrag()},e.prototype.setCurrentDragSourceNode=function(e){var t=this;this.clearCurrentDragSourceNode(),this.currentDragSourceNode=e,this.currentDragSourceNodeOffset=l.getNodeClientOffset(e),this.currentDragSourceNodeOffsetChanged=!1;this.mouseMoveTimeoutTimer=setTimeout((function(){return t.mouseMoveTimeoutId=null,t.window&&t.window.addEventListener("mousemove",t.endDragIfSourceWasRemovedFromDOM,!0)}),1e3)},e.prototype.clearCurrentDragSourceNode=function(){return!!this.currentDragSourceNode&&(this.currentDragSourceNode=null,this.currentDragSourceNodeOffset=null,this.currentDragSourceNodeOffsetChanged=!1,this.window&&(this.window.clearTimeout(this.mouseMoveTimeoutTimer),this.window.removeEventListener("mousemove",this.endDragIfSourceWasRemovedFromDOM,!0)),this.mouseMoveTimeoutTimer=null,!0)},e.prototype.checkIfCurrentDragSourceRectChanged=function(){var e=this.currentDragSourceNode;return!!e&&(!!this.currentDragSourceNodeOffsetChanged||(this.currentDragSourceNodeOffsetChanged=!p(l.getNodeClientOffset(e),this.currentDragSourceNodeOffset),this.currentDragSourceNodeOffsetChanged))},e.prototype.handleTopDragStartCapture=function(){this.clearCurrentDragSourceNode(),this.dragStartSourceIds=[]},e.prototype.handleDragStart=function(e,t){this.dragStartSourceIds||(this.dragStartSourceIds=[]),this.dragStartSourceIds.unshift(t)},e.prototype.handleTopDragStart=function(e){var t=this,n=this.dragStartSourceIds;this.dragStartSourceIds=null;var r=l.getEventClientOffset(e);this.monitor.isDragging()&&this.actions.endDrag(),this.actions.beginDrag(n||[],{publishSource:!1,getSourceClientOffset:this.getSourceClientOffset,clientOffset:r});var o=e.dataTransfer,i=c.matchNativeItemType(o);if(this.monitor.isDragging()){if("function"==typeof o.setDragImage){var a=this.monitor.getSourceId(),s=this.sourceNodes[a],u=this.sourcePreviewNodes[a]||s,f=this.getCurrentSourcePreviewNodeOptions(),d={anchorX:f.anchorX,anchorY:f.anchorY},p={offsetX:f.offsetX,offsetY:f.offsetY},h=l.getDragPreviewOffset(s,u,r,d,p);o.setDragImage(u,h.x,h.y)}try{o.setData("application/json",{})}catch(e){}this.setCurrentDragSourceNode(e.target),this.getCurrentSourcePreviewNodeOptions().captureDraggingState?this.actions.publishDragSource():setTimeout((function(){return t.actions.publishDragSource()}),0)}else if(i)this.beginDragNativeItem(i);else{if(!(o.types||e.target.hasAttribute&&e.target.hasAttribute("draggable")))return;e.preventDefault()}},e.prototype.handleTopDragEndCapture=function(){this.clearCurrentDragSourceNode()&&this.actions.endDrag()},e.prototype.handleTopDragEnterCapture=function(e){if(this.dragEnterTargetIds=[],this.enterLeaveCounter.enter(e.target)&&!this.monitor.isDragging()){var t=e.dataTransfer,n=c.matchNativeItemType(t);n&&this.beginDragNativeItem(n)}},e.prototype.handleDragEnter=function(e,t){this.dragEnterTargetIds.unshift(t)},e.prototype.handleTopDragEnter=function(e){var t=this,n=this.dragEnterTargetIds;(this.dragEnterTargetIds=[],this.monitor.isDragging())&&(this.altKeyPressed=e.altKey,u.isFirefox()||this.actions.hover(n,{clientOffset:l.getEventClientOffset(e)}),n.some((function(e){return t.monitor.canDropOnTarget(e)}))&&(e.preventDefault(),e.dataTransfer.dropEffect=this.getCurrentDropEffect()))},e.prototype.handleTopDragOverCapture=function(){this.dragOverTargetIds=[]},e.prototype.handleDragOver=function(e,t){null===this.dragOverTargetIds&&(this.dragOverTargetIds=[]),this.dragOverTargetIds.unshift(t)},e.prototype.handleTopDragOver=function(e){var t=this,n=this.dragOverTargetIds;if(this.dragOverTargetIds=[],!this.monitor.isDragging())return e.preventDefault(),void(e.dataTransfer.dropEffect="none");this.altKeyPressed=e.altKey,this.actions.hover(n||[],{clientOffset:l.getEventClientOffset(e)}),(n||[]).some((function(e){return t.monitor.canDropOnTarget(e)}))?(e.preventDefault(),e.dataTransfer.dropEffect=this.getCurrentDropEffect()):this.isDraggingNativeItem()?(e.preventDefault(),e.dataTransfer.dropEffect="none"):this.checkIfCurrentDragSourceRectChanged()&&(e.preventDefault(),e.dataTransfer.dropEffect="move")},e.prototype.handleTopDragLeaveCapture=function(e){this.isDraggingNativeItem()&&e.preventDefault(),this.enterLeaveCounter.leave(e.target)&&this.isDraggingNativeItem()&&this.endDragNativeItem()},e.prototype.handleTopDropCapture=function(e){this.dropTargetIds=[],e.preventDefault(),this.isDraggingNativeItem()&&this.currentNativeSource.mutateItemByReadingDataTransfer(e.dataTransfer),this.enterLeaveCounter.reset()},e.prototype.handleDrop=function(e,t){this.dropTargetIds.unshift(t)},e.prototype.handleTopDrop=function(e){var t=this.dropTargetIds;this.dropTargetIds=[],this.actions.hover(t,{clientOffset:l.getEventClientOffset(e)}),this.actions.drop({dropEffect:this.getCurrentDropEffect()}),this.isDraggingNativeItem()?this.endDragNativeItem():this.endDragIfSourceWasRemovedFromDOM()},e.prototype.handleSelectStart=function(e){var t=e.target;"function"==typeof t.dragDrop&&("INPUT"===t.tagName||"SELECT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable||(e.preventDefault(),t.dragDrop()))},r([d.default],e.prototype,"getSourceClientOffset",null),r([d.default],e.prototype,"asyncEndDragNativeItem",null),r([d.default],e.prototype,"endDragNativeItem",null),r([d.default],e.prototype,"isNodeInDocument",null),r([d.default],e.prototype,"endDragIfSourceWasRemovedFromDOM",null),r([d.default],e.prototype,"handleTopDragStartCapture",null),r([d.default],e.prototype,"handleTopDragStart",null),r([d.default],e.prototype,"handleTopDragEndCapture",null),r([d.default],e.prototype,"handleTopDragEnterCapture",null),r([d.default],e.prototype,"handleTopDragEnter",null),r([d.default],e.prototype,"handleTopDragOverCapture",null),r([d.default],e.prototype,"handleTopDragOver",null),r([d.default],e.prototype,"handleTopDragLeaveCapture",null),r([d.default],e.prototype,"handleTopDropCapture",null),r([d.default],e.prototype,"handleTopDrop",null),r([d.default],e.prototype,"handleSelectStart",null),e}();t.default=h},function(e,t,n){var r=n(51),o=n(59),i=n(157),a=n(386),s=Object.prototype,u=s.hasOwnProperty,l=r((function(e,t){e=Object(e);var n=-1,r=t.length,l=r>2?t[2]:void 0;for(l&&i(t[0],t[1],l)&&(r=1);++n<r;)for(var c=t[n],f=a(c),d=-1,p=f.length;++d<p;){var h=f[d],v=e[h];(void 0===v||o(v,s[h])&&!u.call(e,h))&&(e[h]=c[h])}return e}));e.exports=l},function(e,t,n){var r=n(158),o=n(387),i=n(38);e.exports=function(e){return i(e)?r(e,!0):o(e)}},function(e,t,n){var r=n(28),o=n(76),i=n(388),a=Object.prototype.hasOwnProperty;e.exports=function(e){if(!r(e))return i(e);var t=o(e),n=[];for(var s in e)("constructor"!=s||!t&&a.call(e,s))&&n.push(s);return n}},function(e,t){e.exports=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(390)),i=r(n(179)),a=function(){function e(){this.entered=[]}return e.prototype.enter=function(e){var t=this.entered.length;return this.entered=o.default(this.entered.filter((function(t){return document.documentElement.contains(t)&&(!t.contains||t.contains(e))})),[e]),0===t&&this.entered.length>0},e.prototype.leave=function(e){var t=this.entered.length;return this.entered=i.default(this.entered.filter((function(e){return document.documentElement.contains(e)})),e),t>0&&0===this.entered.length},e.prototype.reset=function(){this.entered=[]},e}();t.default=a},function(e,t,n){var r=n(118),o=n(51),i=n(81),a=n(84),s=o((function(e){return i(r(e,1,a,!0))}));e.exports=s},function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var o=n(185),i=r(n(392));function a(e){var t=1===e.nodeType?e:e.parentElement;if(!t)return null;var n=t.getBoundingClientRect(),r=n.top;return{x:n.left,y:r}}t.getNodeClientOffset=a,t.getEventClientOffset=function(e){return{x:e.clientX,y:e.clientY}},t.getDragPreviewOffset=function(e,t,n,r,s){var u,l,c="IMG"===(u=t).nodeName&&(o.isFirefox()||!document.documentElement.contains(u)),f=a(c?e:t),d={x:n.x-f.x,y:n.y-f.y},p=e.offsetWidth,h=e.offsetHeight,v=r.anchorX,g=r.anchorY,m=function(e,t,n,r){var i=e?t.width:n,a=e?t.height:r;return o.isSafari()&&e&&(a/=window.devicePixelRatio,i/=window.devicePixelRatio),{dragPreviewWidth:i,dragPreviewHeight:a}}(c,t,p,h),y=m.dragPreviewWidth,b=m.dragPreviewHeight,w=s.offsetX,_=s.offsetY,x=0===_||_;return{x:0===w||w?w:new i.default([0,.5,1],[d.x,d.x/p*y,d.x+y-p]).interpolate(v),y:x?_:(l=new i.default([0,.5,1],[d.y,d.y/h*b,d.y+b-h]).interpolate(g),o.isSafari()&&c&&(l+=(window.devicePixelRatio-1)*b),l)}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=e.length,r=[],o=0;o<n;o++)r.push(o);r.sort((function(t,n){return e[t]<e[n]?-1:1}));var i,a,s=[],u=[],l=[];for(o=0;o<n-1;o++)i=e[o+1]-e[o],a=t[o+1]-t[o],u.push(i),s.push(a),l.push(a/i);var c=[l[0]];for(o=0;o<u.length-1;o++){var f=l[o],d=l[o+1];if(f*d<=0)c.push(0);else{i=u[o];var p=u[o+1],h=i+p;c.push(3*h/((h+p)/f+(h+i)/d))}}c.push(l[l.length-1]);var v,g=[],m=[];for(o=0;o<c.length-1;o++){v=l[o];var y=c[o],b=1/u[o];h=y+c[o+1]-v-v;g.push((v-y-h)*b),m.push(h*b*b)}this.xs=e,this.ys=t,this.c1s=c,this.c2s=g,this.c3s=m}return e.prototype.interpolate=function(e){var t=this,n=t.xs,r=t.ys,o=t.c1s,i=t.c2s,a=t.c3s,s=n.length-1;if(e===n[s])return r[s];for(var u,l=0,c=a.length-1;l<=c;){var f=n[u=Math.floor(.5*(l+c))];if(f<e)l=u+1;else{if(!(f>e))return r[u];c=u-1}}var d=e-n[s=Math.max(0,c)],p=d*d;return r[s]+o[s]*d+i[s]*p+a[s]*d*p},e}();t.default=r},function(e,t,n){"use strict";var r=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var o=r(n(121));function i(e,t,n){var r=t.reduce((function(t,n){return t||e.getData(n)}),null);return null!=r?r:n}var a,s=((a={})[o.FILE]={exposeProperty:"files",matchesTypes:["Files"],getData:function(e){return Array.prototype.slice.call(e.files)}},a[o.URL]={exposeProperty:"urls",matchesTypes:["Url","text/uri-list"],getData:function(e,t){return i(e,t,"").split("\n")}},a[o.TEXT]={exposeProperty:"text",matchesTypes:["Text","text/plain"],getData:function(e,t){return i(e,t,"")}},a);t.createNativeDragSource=function(e){var t=s[e],n=t.exposeProperty,r=t.matchesTypes,o=t.getData;return function(){function e(){var e;this.item=(e={},Object.defineProperty(e,n,{get:function(){return console.warn("Browser doesn't allow reading \""+n+'" until the drop event.'),null},enumerable:!0,configurable:!0}),e)}return e.prototype.mutateItemByReadingDataTransfer=function(e){delete this.item[n],this.item[n]=o(e,r)},e.prototype.canDrag=function(){return!0},e.prototype.beginDrag=function(){return this.item},e.prototype.isDragging=function(e,t){return t===e.getSourceId()},e.prototype.endDrag=function(){},e}()},t.matchNativeItemType=function(e){var t=Array.prototype.slice.call(e.types||[]);return Object.keys(s).filter((function(e){return s[e].matchesTypes.some((function(e){return t.indexOf(e)>-1}))}))[0]||null}},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)}function o(e,t,n){var o=n.value;if("function"!=typeof o)throw new TypeError("@boundMethod decorator can only be applied to methods not: ".concat(r(o)));var i=!1;return{configurable:!0,get:function(){if(i||this===e.prototype||this.hasOwnProperty(t)||"function"!=typeof o)return o;var n=o.bind(this);return i=!0,Object.defineProperty(this,t,{configurable:!0,get:function(){return n},set:function(e){o=e,delete this[t]}}),i=!1,n},set:function(e){o=e}}}function i(e){var t;return"undefined"!=typeof Reflect&&"function"==typeof Reflect.ownKeys?t=Reflect.ownKeys(e.prototype):(t=Object.getOwnPropertyNames(e.prototype),"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(e.prototype)))),t.forEach((function(t){if("constructor"!==t){var n=Object.getOwnPropertyDescriptor(e.prototype,t);"function"==typeof n.value&&Object.defineProperty(e.prototype,t,o(e,t,n))}})),e}function a(){return 1===arguments.length?i.apply(void 0,arguments):o.apply(void 0,arguments)}n.r(t),n.d(t,"boundMethod",(function(){return o})),n.d(t,"boundClass",(function(){return i})),n.d(t,"default",(function(){return a}))},function(e,t,n){"use strict";var r;Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){return r||((r=new Image).src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw=="),r}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=n(0),i=l(o),a=l(n(86)),s=l(n(89)),u=l(n(399));function l(e){return e&&e.__esModule?e:{default:e}}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function f(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var d=function(e){function t(){var e,n,r;c(this,t);for(var o=arguments.length,a=Array(o),s=0;s<o;s++)a[s]=arguments[s];return n=r=f(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this].concat(a))),r.markIt=function(e,t){var n=t.trim().replace(/[-\\^$*+?.()|[\]{}]/g,"\\$&");return{__html:e[r.props.labelField].replace(RegExp(n,"gi"),(function(e){return"<mark>"+(0,u.default)(e)+"</mark>"}))}},r.shouldRenderSuggestions=function(e){var t=r.props,n=t.minQueryLength,o=t.isFocused;return e.length>=n&&o},r.renderSuggestion=function(e,t){var n=r.props.renderSuggestion;return"function"==typeof n?n(e,t):i.default.createElement("span",{dangerouslySetInnerHTML:r.markIt(e,t)})},f(r,n)}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"shouldComponentUpdate",value:function(e){var t=this.props,n=t.shouldRenderSuggestions||this.shouldRenderSuggestions;return t.isFocused!==e.isFocused||!(0,s.default)(t.suggestions,e.suggestions)||n(e.query)||n(e.query)!==n(t.query)}},{key:"componentDidUpdate",value:function(e){var t,n,r,o,i,a=this.props,s=a.selectedIndex,u=a.classNames;if(this.suggestionsContainer&&e.selectedIndex!==s){var l=this.suggestionsContainer.querySelector(u.activeSuggestion);l&&(t=l,n=this.suggestionsContainer,r=n.offsetHeight,o=t.offsetHeight,(i=t.offsetTop-n.scrollTop)+o>=r?n.scrollTop+=i-r+o:i<0&&(n.scrollTop+=i))}}},{key:"render",value:function(){var e=this,t=this.props,n=t.suggestions.map(function(e,n){return i.default.createElement("li",{key:n,onMouseDown:t.handleClick.bind(null,n),onTouchStart:t.handleClick.bind(null,n),onMouseOver:t.handleHover.bind(null,n),className:n===t.selectedIndex?t.classNames.activeSuggestion:""},this.renderSuggestion(e,t.query))}.bind(this)),r=t.shouldRenderSuggestions||this.shouldRenderSuggestions;return 0!==n.length&&r(t.query)?i.default.createElement("div",{ref:function(t){e.suggestionsContainer=t},className:this.props.classNames.suggestions},i.default.createElement("ul",null," ",n," ")):null}}]),t}(o.Component);d.propTypes={query:a.default.string.isRequired,selectedIndex:a.default.number.isRequired,suggestions:a.default.array.isRequired,handleClick:a.default.func.isRequired,handleHover:a.default.func.isRequired,minQueryLength:a.default.number,shouldRenderSuggestions:a.default.func,isFocused:a.default.bool.isRequired,classNames:a.default.object,labelField:a.default.string.isRequired,renderSuggestion:a.default.func},d.defaultProps={minQueryLength:2},t.default=d},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var r=n(398);function o(){}function i(){}i.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,i,a){if(a!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:i,resetWarningCache:o};return n.PropTypes=n,n}},function(e,t,n){"use strict"; /** * Copyright (c) 2013-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},function(e,t,n){var r=n(400),o=n(48),i=/[&<>"']/g,a=RegExp(i.source);e.exports=function(e){return(e=o(e))&&a.test(e)?e.replace(i,r):e}},function(e,t,n){var r=n(401)({"&":"&","<":"<",">":">",'"':""","'":"'"});e.exports=r},function(e,t){e.exports=function(e){return function(t){return null==e?void 0:e[t]}}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=n(0),i=p(o),a=n(175),s=p(n(86)),u=p(n(403)),l=p(n(186)),c=n(413),f=n(125),d=p(n(415));function p(e){return e&&e.__esModule?e:{default:e}}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function v(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var g="tag",m=function(e){function t(){return h(this,t),v(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"render",value:function(){var e=this.props,t=e.tag[e.labelField],n=e.connectDragSource,r=e.isDragging,o=e.connectDropTarget,a=e.readOnly,s=e.tag,u=e.classNames,c=s.className,p=void 0===c?"":c;return n(o(i.default.createElement("span",{className:(0,l.default)("tag-wrapper",u.tag,p),style:{opacity:r?0:1,cursor:(0,f.canDrag)(e)?"move":"auto"},onClick:e.onTagClicked,onKeyDown:e.onTagClicked,onTouchStart:e.onTagClicked},t,i.default.createElement(d.default,{tag:e.tag,className:u.remove,removeComponent:e.removeComponent,onClick:e.onDelete,readOnly:a}))))}}]),t}(o.Component);m.propTypes={labelField:s.default.string,onDelete:s.default.func.isRequired,tag:s.default.shape({id:s.default.string.isRequired,className:s.default.string}),moveTag:s.default.func,removeComponent:s.default.func,onTagClicked:s.default.func,classNames:s.default.object,readOnly:s.default.bool,connectDragSource:s.default.func.isRequired,isDragging:s.default.bool.isRequired,connectDropTarget:s.default.func.isRequired},m.defaultProps={labelField:"text",readOnly:!1},t.default=(0,u.default)((0,a.DragSource)(g,c.tagSource,c.dragSource),(0,a.DropTarget)(g,c.tagTarget,c.dropCollect))(m)},function(e,t,n){var r=n(404)();e.exports=r},function(e,t,n){var r=n(122),o=n(405),i=n(188),a=n(189),s=n(23),u=n(409);e.exports=function(e){return o((function(t){var n=t.length,o=n,l=r.prototype.thru;for(e&&t.reverse();o--;){var c=t[o];if("function"!=typeof c)throw new TypeError("Expected a function");if(l&&!f&&"wrapper"==a(c))var f=new r([],!0)}for(o=f?o:n;++o<n;){c=t[o];var d=a(c),p="wrapper"==d?i(c):void 0;f=p&&u(p[0])&&424==p[1]&&!p[4].length&&1==p[9]?f[a(p[0])].apply(f,p[3]):1==c.length&&u(c)?f[d]():f.thru(c)}return function(){var e=arguments,r=e[0];if(f&&1==e.length&&s(r))return f.plant(r).value();for(var o=0,i=n?t[o].apply(this,e):r;++o<n;)i=t[o].call(this,i);return i}}))}},function(e,t,n){var r=n(406),o=n(155),i=n(156);e.exports=function(e){return i(o(e,void 0,r),e+"")}},function(e,t,n){var r=n(118);e.exports=function(e){return(null==e?0:e.length)?r(e,1):[]}},function(e,t,n){var r=n(166),o=r&&new r;e.exports=o},function(e,t){e.exports={}},function(e,t,n){var r=n(124),o=n(188),i=n(189),a=n(410);e.exports=function(e){var t=i(e),n=a[t];if("function"!=typeof n||!(t in r.prototype))return!1;if(e===n)return!0;var s=o(n);return!!s&&e===s[0]}},function(e,t,n){var r=n(124),o=n(122),i=n(123),a=n(23),s=n(33),u=n(411),l=Object.prototype.hasOwnProperty;function c(e){if(s(e)&&!a(e)&&!(e instanceof r)){if(e instanceof o)return e;if(l.call(e,"__wrapped__"))return u(e)}return new o(e)}c.prototype=i.prototype,c.prototype.constructor=c,e.exports=c},function(e,t,n){var r=n(124),o=n(122),i=n(412);e.exports=function(e){if(e instanceof r)return e.clone();var t=new o(e.__wrapped__,e.__chain__);return t.__actions__=i(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}},function(e,t){e.exports=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dropCollect=t.dragSource=t.tagTarget=t.tagSource=void 0;var r=n(47),o=n(125),i={beginDrag:function(e){return{id:e.tag.index,index:e.index}},canDrag:function(e){return(0,o.canDrag)(e)}},a={hover:function(e,t,n){var o=t.getItem().index,i=e.index;if(o!==i){var a=(0,r.findDOMNode)(n).getBoundingClientRect(),s=(a.right-a.left)/2,u=t.getClientOffset().x-a.left;o<i&&u<s||o>i&&u>s||(e.moveTag(o,i),t.getItem().index=i)}},canDrop:function(e){return(0,o.canDrop)(e)}};t.tagSource=i,t.tagTarget=a,t.dragSource=function(e,t){return{connectDragSource:e.dragSource(),isDragging:t.isDragging()}},t.dropCollect=function(e){return{connectDropTarget:e.dropTarget()}}},function(e,t,n){var r=n(48),o=/[\\^$.*+?()[\]{}|]/g,i=RegExp(o.source);e.exports=function(e){return(e=r(e))&&i.test(e)?e.replace(o,"\\$&"):e}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(n(0)),o=i(n(86));function i(e){return e&&e.__esModule?e:{default:e}}var a=String.fromCharCode(215),s=function(e){var t=e.readOnly,n=e.removeComponent,o=e.onClick,i=e.className;if(t)return r.default.createElement("span",null);if(n){var s=n;return r.default.createElement(s,e)}return r.default.createElement("a",{onClick:o,className:i,onKeyDown:o},a)};s.propTypes={className:o.default.string,onClick:o.default.func.isRequired,readOnly:o.default.bool,removeComponent:o.default.func},t.default=s},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});t.KEYS={ENTER:13,TAB:9,BACKSPACE:8,UP_ARROW:38,DOWN_ARROW:40,ESCAPE:27},t.DEFAULT_PLACEHOLDER="Add new tag",t.DEFAULT_LABEL_FIELD="text",t.DEFAULT_CLASSNAMES={tags:"ReactTags__tags",tagInput:"ReactTags__tagInput",tagInputField:"ReactTags__tagInputField",selected:"ReactTags__selected",tag:"ReactTags__tag",remove:"ReactTags__remove",suggestions:"ReactTags__suggestions",activeSuggestion:"ReactTags__activeSuggestion"},t.INPUT_FIELD_POSITIONS={INLINE:"inline",TOP:"top",BOTTOM:"bottom"}},function(e,t){var n=Object.prototype.hasOwnProperty;e.exports=function(e,t){return null!=e&&n.call(e,t)}},function(e,t,n){var r=n(419);e.exports=function(e){var t=r(e),n=t%1;return t==t?n?t-n:t:0}},function(e,t,n){var r=n(190);e.exports=function(e){return e?(e=r(e))===1/0||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}},function(e,t,n){var r=n(421),o=/^\s+/;e.exports=function(e){return e?e.slice(0,r(e)+1).replace(o,""):e}},function(e,t){var n=/\s/;e.exports=function(e){for(var t=e.length;t--&&n.test(e.charAt(t)););return t}},function(e,t,n){var r=n(423),o=n(41);e.exports=function(e){return null==e?[]:r(e,o(e))}},function(e,t,n){var r=n(49);e.exports=function(e,t){return r(t,(function(t){return e[t]}))}},function(e,t,n){var r=n(32);e.exports=function(){return r.Date.now()}},function(e,t,n){var r=n(104),o=n(67),i=n(60),a=n(28),s=n(50);e.exports=function(e,t,n,u){if(!a(e))return e;for(var l=-1,c=(t=o(t,e)).length,f=c-1,d=e;null!=d&&++l<c;){var p=s(t[l]),h=n;if("__proto__"===p||"constructor"===p||"prototype"===p)return e;if(l!=f){var v=d[p];void 0===(h=u?u(v,p,d):void 0)&&(h=a(v)?v:i(t[l+1])?[]:{})}r(d,p,h),d=d[p]}return e}},function(e,t){e.exports=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}},function(e,t,n){var r=n(75);e.exports=function(e){return"function"==typeof e?e:r}},function(e,t,n){var r=n(429),o=n(60),i=Array.prototype.splice;e.exports=function(e,t){for(var n=e?t.length:0,a=n-1;n--;){var s=t[n];if(n==a||s!==u){var u=s;o(s)?i.call(e,s,1):r(e,s)}}return e}},function(e,t,n){var r=n(67),o=n(430),i=n(431),a=n(50);e.exports=function(e,t){return t=r(t,e),null==(e=i(e,t))||delete e[a(o(t))]}},function(e,t){e.exports=function(e){var t=null==e?0:e.length;return t?e[t-1]:void 0}},function(e,t,n){var r=n(94),o=n(432);e.exports=function(e,t){return t.length<2?e:r(e,o(t,0,-1))}},function(e,t){e.exports=function(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=Array(o);++r<o;)i[r]=e[r+t];return i}},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t=e.commands,n=e.Pos;function r(t,r){t.extendSelectionsBy((function(o){return t.display.shift||t.doc.extend||o.empty()?function(t,r,o){if(o<0&&0==r.ch)return t.clipPos(n(r.line-1));var i=t.getLine(r.line);if(o>0&&r.ch>=i.length)return t.clipPos(n(r.line+1,0));for(var a,s="start",u=r.ch,l=u,c=o<0?0:i.length,f=0;l!=c;l+=o,f++){var d=i.charAt(o<0?l-1:l),p="_"!=d&&e.isWordChar(d)?"w":"o";if("w"==p&&d.toUpperCase()==d&&(p="W"),"start"==s)"o"!=p?(s="in",a=p):u=l+o;else if("in"==s&&a!=p){if("w"==a&&"W"==p&&o<0&&l--,"W"==a&&"w"==p&&o>0){if(l==u+1){a="w";continue}l--}break}}return n(r.line,l)}(t.doc,o.head,r):r<0?o.from():o.to()}))}function o(t,r){if(t.isReadOnly())return e.Pass;t.operation((function(){for(var e=t.listSelections().length,o=[],i=-1,a=0;a<e;a++){var s=t.listSelections()[a].head;if(!(s.line<=i)){var u=n(s.line+(r?0:1),0);t.replaceRange("\n",u,null,"+insertLine"),t.indentLine(u.line,null,!0),o.push({head:u,anchor:u}),i=s.line+1}}t.setSelections(o)})),t.execCommand("indentAuto")}function i(t,r){for(var o=r.ch,i=o,a=t.getLine(r.line);o&&e.isWordChar(a.charAt(o-1));)--o;for(;i<a.length&&e.isWordChar(a.charAt(i));)++i;return{from:n(r.line,o),to:n(r.line,i),word:a.slice(o,i)}}function a(e,t){for(var n=e.listSelections(),r=[],o=0;o<n.length;o++){var i=n[o],a=e.findPosV(i.anchor,t,"line",i.anchor.goalColumn),s=e.findPosV(i.head,t,"line",i.head.goalColumn);a.goalColumn=null!=i.anchor.goalColumn?i.anchor.goalColumn:e.cursorCoords(i.anchor,"div").left,s.goalColumn=null!=i.head.goalColumn?i.head.goalColumn:e.cursorCoords(i.head,"div").left;var u={anchor:a,head:s};r.push(i),r.push(u)}e.setSelections(r)}function s(t){for(var r=t.listSelections(),o=[],i=0;i<r.length;i++){var a=r[i],s=a.head,u=t.scanForBracket(s,-1);if(!u)return!1;for(;;){var l=t.scanForBracket(s,1);if(!l)return!1;if(l.ch=="(){}[]".charAt("(){}[]".indexOf(u.ch)+1)){var c=n(u.pos.line,u.pos.ch+1);if(0!=e.cmpPos(c,a.from())||0!=e.cmpPos(l.pos,a.to())){o.push({anchor:c,head:l.pos});break}if(!(u=t.scanForBracket(u.pos,-1)))return!1}s=n(l.pos.line,l.pos.ch+1)}}return t.setSelections(o),!0}function u(e){return e?/\bpunctuation\b/.test(e)?e:void 0:null}function l(t,r,o){if(t.isReadOnly())return e.Pass;for(var i,a=t.listSelections(),s=[],u=0;u<a.length;u++){var l=a[u];if(!l.empty()){for(var c=l.from().line,f=l.to().line;u<a.length-1&&a[u+1].from().line==f;)f=a[++u].to().line;a[u].to().ch||f--,s.push(c,f)}}s.length?i=!0:s.push(t.firstLine(),t.lastLine()),t.operation((function(){for(var e=[],a=0;a<s.length;a+=2){var u=s[a],l=s[a+1],c=n(u,0),f=n(l),d=t.getRange(c,f,!1);r?d.sort((function(e,t){return e<t?-o:e==t?0:o})):d.sort((function(e,t){var n=e.toUpperCase(),r=t.toUpperCase();return n!=r&&(e=n,t=r),e<t?-o:e==t?0:o})),t.replaceRange(d,c,f),i&&e.push({anchor:c,head:n(l+1,0)})}i&&t.setSelections(e,0)}))}function c(t,n){t.operation((function(){for(var r=t.listSelections(),o=[],a=[],s=0;s<r.length;s++)(l=r[s]).empty()?(o.push(s),a.push("")):a.push(n(t.getRange(l.from(),l.to())));var u;for(t.replaceSelections(a,"around","case"),s=o.length-1;s>=0;s--){var l=r[o[s]];if(!(u&&e.cmpPos(l.head,u)>0)){var c=i(t,l.head);u=c.from,t.replaceRange(n(c.word),c.from,c.to)}}}))}function f(t){var n=t.getCursor("from"),r=t.getCursor("to");if(0==e.cmpPos(n,r)){var o=i(t,n);if(!o.word)return;n=o.from,r=o.to}return{from:n,to:r,query:t.getRange(n,r),word:o}}function d(e,t){var r=f(e);if(r){var o=r.query,i=e.getSearchCursor(o,t?r.to:r.from);(t?i.findNext():i.findPrevious())?e.setSelection(i.from(),i.to()):(i=e.getSearchCursor(o,t?n(e.firstLine(),0):e.clipPos(n(e.lastLine()))),(t?i.findNext():i.findPrevious())?e.setSelection(i.from(),i.to()):r.word&&e.setSelection(r.from,r.to))}}t.goSubwordLeft=function(e){r(e,-1)},t.goSubwordRight=function(e){r(e,1)},t.scrollLineUp=function(e){var t=e.getScrollInfo();if(!e.somethingSelected()){var n=e.lineAtHeight(t.top+t.clientHeight,"local");e.getCursor().line>=n&&e.execCommand("goLineUp")}e.scrollTo(null,t.top-e.defaultTextHeight())},t.scrollLineDown=function(e){var t=e.getScrollInfo();if(!e.somethingSelected()){var n=e.lineAtHeight(t.top,"local")+1;e.getCursor().line<=n&&e.execCommand("goLineDown")}e.scrollTo(null,t.top+e.defaultTextHeight())},t.splitSelectionByLine=function(e){for(var t=e.listSelections(),r=[],o=0;o<t.length;o++)for(var i=t[o].from(),a=t[o].to(),s=i.line;s<=a.line;++s)a.line>i.line&&s==a.line&&0==a.ch||r.push({anchor:s==i.line?i:n(s,0),head:s==a.line?a:n(s)});e.setSelections(r,0)},t.singleSelectionTop=function(e){var t=e.listSelections()[0];e.setSelection(t.anchor,t.head,{scroll:!1})},t.selectLine=function(e){for(var t=e.listSelections(),r=[],o=0;o<t.length;o++){var i=t[o];r.push({anchor:n(i.from().line,0),head:n(i.to().line+1,0)})}e.setSelections(r)},t.insertLineAfter=function(e){return o(e,!1)},t.insertLineBefore=function(e){return o(e,!0)},t.selectNextOccurrence=function(t){var r=t.getCursor("from"),o=t.getCursor("to"),a=t.state.sublimeFindFullWord==t.doc.sel;if(0==e.cmpPos(r,o)){var s=i(t,r);if(!s.word)return;t.setSelection(s.from,s.to),a=!0}else{var u=t.getRange(r,o),l=a?new RegExp("\\b"+u+"\\b"):u,c=t.getSearchCursor(l,o),f=c.findNext();if(f||(f=(c=t.getSearchCursor(l,n(t.firstLine(),0))).findNext()),!f||function(t,n,r){for(var o=0;o<t.length;o++)if(0==e.cmpPos(t[o].from(),n)&&0==e.cmpPos(t[o].to(),r))return!0;return!1}(t.listSelections(),c.from(),c.to()))return;t.addSelection(c.from(),c.to())}a&&(t.state.sublimeFindFullWord=t.doc.sel)},t.skipAndSelectNextOccurrence=function(n){var r=n.getCursor("anchor"),o=n.getCursor("head");t.selectNextOccurrence(n),0!=e.cmpPos(r,o)&&n.doc.setSelections(n.doc.listSelections().filter((function(e){return e.anchor!=r||e.head!=o})))},t.addCursorToPrevLine=function(e){a(e,-1)},t.addCursorToNextLine=function(e){a(e,1)},t.selectScope=function(e){s(e)||e.execCommand("selectAll")},t.selectBetweenBrackets=function(t){if(!s(t))return e.Pass},t.goToBracket=function(t){t.extendSelectionsBy((function(r){var o=t.scanForBracket(r.head,1,u(t.getTokenTypeAt(r.head)));if(o&&0!=e.cmpPos(o.pos,r.head))return o.pos;var i=t.scanForBracket(r.head,-1,u(t.getTokenTypeAt(n(r.head.line,r.head.ch+1))));return i&&n(i.pos.line,i.pos.ch+1)||r.head}))},t.swapLineUp=function(t){if(t.isReadOnly())return e.Pass;for(var r=t.listSelections(),o=[],i=t.firstLine()-1,a=[],s=0;s<r.length;s++){var u=r[s],l=u.from().line-1,c=u.to().line;a.push({anchor:n(u.anchor.line-1,u.anchor.ch),head:n(u.head.line-1,u.head.ch)}),0!=u.to().ch||u.empty()||--c,l>i?o.push(l,c):o.length&&(o[o.length-1]=c),i=c}t.operation((function(){for(var e=0;e<o.length;e+=2){var r=o[e],i=o[e+1],s=t.getLine(r);t.replaceRange("",n(r,0),n(r+1,0),"+swapLine"),i>t.lastLine()?t.replaceRange("\n"+s,n(t.lastLine()),null,"+swapLine"):t.replaceRange(s+"\n",n(i,0),null,"+swapLine")}t.setSelections(a),t.scrollIntoView()}))},t.swapLineDown=function(t){if(t.isReadOnly())return e.Pass;for(var r=t.listSelections(),o=[],i=t.lastLine()+1,a=r.length-1;a>=0;a--){var s=r[a],u=s.to().line+1,l=s.from().line;0!=s.to().ch||s.empty()||u--,u<i?o.push(u,l):o.length&&(o[o.length-1]=l),i=l}t.operation((function(){for(var e=o.length-2;e>=0;e-=2){var r=o[e],i=o[e+1],a=t.getLine(r);r==t.lastLine()?t.replaceRange("",n(r-1),n(r),"+swapLine"):t.replaceRange("",n(r,0),n(r+1,0),"+swapLine"),t.replaceRange(a+"\n",n(i,0),null,"+swapLine")}t.scrollIntoView()}))},t.toggleCommentIndented=function(e){e.toggleComment({indent:!0})},t.joinLines=function(e){for(var t=e.listSelections(),r=[],o=0;o<t.length;o++){for(var i=t[o],a=i.from(),s=a.line,u=i.to().line;o<t.length-1&&t[o+1].from().line==u;)u=t[++o].to().line;r.push({start:s,end:u,anchor:!i.empty()&&a})}e.operation((function(){for(var t=0,o=[],i=0;i<r.length;i++){for(var a,s=r[i],u=s.anchor&&n(s.anchor.line-t,s.anchor.ch),l=s.start;l<=s.end;l++){var c=l-t;l==s.end&&(a=n(c,e.getLine(c).length+1)),c<e.lastLine()&&(e.replaceRange(" ",n(c),n(c+1,/^\s*/.exec(e.getLine(c+1))[0].length)),++t)}o.push({anchor:u||a,head:a})}e.setSelections(o,0)}))},t.duplicateLine=function(e){e.operation((function(){for(var t=e.listSelections().length,r=0;r<t;r++){var o=e.listSelections()[r];o.empty()?e.replaceRange(e.getLine(o.head.line)+"\n",n(o.head.line,0)):e.replaceRange(e.getRange(o.from(),o.to()),o.from())}e.scrollIntoView()}))},t.sortLines=function(e){l(e,!0,1)},t.reverseSortLines=function(e){l(e,!0,-1)},t.sortLinesInsensitive=function(e){l(e,!1,1)},t.reverseSortLinesInsensitive=function(e){l(e,!1,-1)},t.nextBookmark=function(e){var t=e.state.sublimeBookmarks;if(t)for(;t.length;){var n=t.shift(),r=n.find();if(r)return t.push(n),e.setSelection(r.from,r.to)}},t.prevBookmark=function(e){var t=e.state.sublimeBookmarks;if(t)for(;t.length;){t.unshift(t.pop());var n=t[t.length-1].find();if(n)return e.setSelection(n.from,n.to);t.pop()}},t.toggleBookmark=function(e){for(var t=e.listSelections(),n=e.state.sublimeBookmarks||(e.state.sublimeBookmarks=[]),r=0;r<t.length;r++){for(var o=t[r].from(),i=t[r].to(),a=t[r].empty()?e.findMarksAt(o):e.findMarks(o,i),s=0;s<a.length;s++)if(a[s].sublimeBookmark){a[s].clear();for(var u=0;u<n.length;u++)n[u]==a[s]&&n.splice(u--,1);break}s==a.length&&n.push(e.markText(o,i,{sublimeBookmark:!0,clearWhenEmpty:!1}))}},t.clearBookmarks=function(e){var t=e.state.sublimeBookmarks;if(t)for(var n=0;n<t.length;n++)t[n].clear();t.length=0},t.selectBookmarks=function(e){var t=e.state.sublimeBookmarks,n=[];if(t)for(var r=0;r<t.length;r++){var o=t[r].find();o?n.push({anchor:o.from,head:o.to}):t.splice(r--,0)}n.length&&e.setSelections(n,0)},t.smartBackspace=function(t){if(t.somethingSelected())return e.Pass;t.operation((function(){for(var r=t.listSelections(),o=t.getOption("indentUnit"),i=r.length-1;i>=0;i--){var a=r[i].head,s=t.getRange({line:a.line,ch:0},a),u=e.countColumn(s,null,t.getOption("tabSize")),l=t.findPosH(a,-1,"char",!1);if(s&&!/\S/.test(s)&&u%o==0){var c=new n(a.line,e.findColumn(s,u-o,o));c.ch!=a.ch&&(l=c)}t.replaceRange("",l,a,"+delete")}}))},t.delLineRight=function(e){e.operation((function(){for(var t=e.listSelections(),r=t.length-1;r>=0;r--)e.replaceRange("",t[r].anchor,n(t[r].to().line),"+delete");e.scrollIntoView()}))},t.upcaseAtCursor=function(e){c(e,(function(e){return e.toUpperCase()}))},t.downcaseAtCursor=function(e){c(e,(function(e){return e.toLowerCase()}))},t.setSublimeMark=function(e){e.state.sublimeMark&&e.state.sublimeMark.clear(),e.state.sublimeMark=e.setBookmark(e.getCursor())},t.selectToSublimeMark=function(e){var t=e.state.sublimeMark&&e.state.sublimeMark.find();t&&e.setSelection(e.getCursor(),t)},t.deleteToSublimeMark=function(t){var n=t.state.sublimeMark&&t.state.sublimeMark.find();if(n){var r=t.getCursor(),o=n;if(e.cmpPos(r,o)>0){var i=o;o=r,r=i}t.state.sublimeKilled=t.getRange(r,o),t.replaceRange("",r,o)}},t.swapWithSublimeMark=function(e){var t=e.state.sublimeMark&&e.state.sublimeMark.find();t&&(e.state.sublimeMark.clear(),e.state.sublimeMark=e.setBookmark(e.getCursor()),e.setCursor(t))},t.sublimeYank=function(e){null!=e.state.sublimeKilled&&e.replaceSelection(e.state.sublimeKilled,null,"paste")},t.showInCenter=function(e){var t=e.cursorCoords(null,"local");e.scrollTo(null,(t.top+t.bottom)/2-e.getScrollInfo().clientHeight/2)},t.findUnder=function(e){d(e,!0)},t.findUnderPrevious=function(e){d(e,!1)},t.findAllUnder=function(e){var t=f(e);if(t){for(var n=e.getSearchCursor(t.query),r=[],o=-1;n.findNext();)r.push({anchor:n.from(),head:n.to()}),n.from().line<=t.from.line&&n.from().ch<=t.from.ch&&o++;e.setSelections(r,o)}};var p=e.keyMap;p.macSublime={"Cmd-Left":"goLineStartSmart","Shift-Tab":"indentLess","Shift-Ctrl-K":"deleteLine","Alt-Q":"wrapLines","Ctrl-Left":"goSubwordLeft","Ctrl-Right":"goSubwordRight","Ctrl-Alt-Up":"scrollLineUp","Ctrl-Alt-Down":"scrollLineDown","Cmd-L":"selectLine","Shift-Cmd-L":"splitSelectionByLine",Esc:"singleSelectionTop","Cmd-Enter":"insertLineAfter","Shift-Cmd-Enter":"insertLineBefore","Cmd-D":"selectNextOccurrence","Shift-Cmd-Space":"selectScope","Shift-Cmd-M":"selectBetweenBrackets","Cmd-M":"goToBracket","Cmd-Ctrl-Up":"swapLineUp","Cmd-Ctrl-Down":"swapLineDown","Cmd-/":"toggleCommentIndented","Cmd-J":"joinLines","Shift-Cmd-D":"duplicateLine",F5:"sortLines","Shift-F5":"reverseSortLines","Cmd-F5":"sortLinesInsensitive","Shift-Cmd-F5":"reverseSortLinesInsensitive",F2:"nextBookmark","Shift-F2":"prevBookmark","Cmd-F2":"toggleBookmark","Shift-Cmd-F2":"clearBookmarks","Alt-F2":"selectBookmarks",Backspace:"smartBackspace","Cmd-K Cmd-D":"skipAndSelectNextOccurrence","Cmd-K Cmd-K":"delLineRight","Cmd-K Cmd-U":"upcaseAtCursor","Cmd-K Cmd-L":"downcaseAtCursor","Cmd-K Cmd-Space":"setSublimeMark","Cmd-K Cmd-A":"selectToSublimeMark","Cmd-K Cmd-W":"deleteToSublimeMark","Cmd-K Cmd-X":"swapWithSublimeMark","Cmd-K Cmd-Y":"sublimeYank","Cmd-K Cmd-C":"showInCenter","Cmd-K Cmd-G":"clearBookmarks","Cmd-K Cmd-Backspace":"delLineLeft","Cmd-K Cmd-1":"foldAll","Cmd-K Cmd-0":"unfoldAll","Cmd-K Cmd-J":"unfoldAll","Ctrl-Shift-Up":"addCursorToPrevLine","Ctrl-Shift-Down":"addCursorToNextLine","Cmd-F3":"findUnder","Shift-Cmd-F3":"findUnderPrevious","Alt-F3":"findAllUnder","Shift-Cmd-[":"fold","Shift-Cmd-]":"unfold","Cmd-I":"findIncremental","Shift-Cmd-I":"findIncrementalReverse","Cmd-H":"replace",F3:"findNext","Shift-F3":"findPrev",fallthrough:"macDefault"},e.normalizeKeyMap(p.macSublime),p.pcSublime={"Shift-Tab":"indentLess","Shift-Ctrl-K":"deleteLine","Alt-Q":"wrapLines","Ctrl-T":"transposeChars","Alt-Left":"goSubwordLeft","Alt-Right":"goSubwordRight","Ctrl-Up":"scrollLineUp","Ctrl-Down":"scrollLineDown","Ctrl-L":"selectLine","Shift-Ctrl-L":"splitSelectionByLine",Esc:"singleSelectionTop","Ctrl-Enter":"insertLineAfter","Shift-Ctrl-Enter":"insertLineBefore","Ctrl-D":"selectNextOccurrence","Shift-Ctrl-Space":"selectScope","Shift-Ctrl-M":"selectBetweenBrackets","Ctrl-M":"goToBracket","Shift-Ctrl-Up":"swapLineUp","Shift-Ctrl-Down":"swapLineDown","Ctrl-/":"toggleCommentIndented","Ctrl-J":"joinLines","Shift-Ctrl-D":"duplicateLine",F9:"sortLines","Shift-F9":"reverseSortLines","Ctrl-F9":"sortLinesInsensitive","Shift-Ctrl-F9":"reverseSortLinesInsensitive",F2:"nextBookmark","Shift-F2":"prevBookmark","Ctrl-F2":"toggleBookmark","Shift-Ctrl-F2":"clearBookmarks","Alt-F2":"selectBookmarks",Backspace:"smartBackspace","Ctrl-K Ctrl-D":"skipAndSelectNextOccurrence","Ctrl-K Ctrl-K":"delLineRight","Ctrl-K Ctrl-U":"upcaseAtCursor","Ctrl-K Ctrl-L":"downcaseAtCursor","Ctrl-K Ctrl-Space":"setSublimeMark","Ctrl-K Ctrl-A":"selectToSublimeMark","Ctrl-K Ctrl-W":"deleteToSublimeMark","Ctrl-K Ctrl-X":"swapWithSublimeMark","Ctrl-K Ctrl-Y":"sublimeYank","Ctrl-K Ctrl-C":"showInCenter","Ctrl-K Ctrl-G":"clearBookmarks","Ctrl-K Ctrl-Backspace":"delLineLeft","Ctrl-K Ctrl-1":"foldAll","Ctrl-K Ctrl-0":"unfoldAll","Ctrl-K Ctrl-J":"unfoldAll","Ctrl-Alt-Up":"addCursorToPrevLine","Ctrl-Alt-Down":"addCursorToNextLine","Ctrl-F3":"findUnder","Shift-Ctrl-F3":"findUnderPrevious","Alt-F3":"findAllUnder","Shift-Ctrl-[":"fold","Shift-Ctrl-]":"unfold","Ctrl-I":"findIncremental","Shift-Ctrl-I":"findIncrementalReverse","Ctrl-H":"replace",F3:"findNext","Shift-F3":"findPrev",fallthrough:"pcDefault"},e.normalizeKeyMap(p.pcSublime);var h=p.default==p.macDefault;p.sublime=h?p.macSublime:p.pcSublime}(n(21),n(126),n(191))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t={script:[["lang",/(javascript|babel)/i,"javascript"],["type",/^(?:text|application)\/(?:x-)?(?:java|ecma)script$|^module$|^$/i,"javascript"],["type",/./,"text/plain"],[null,null,"javascript"]],style:[["lang",/^css$/i,"css"],["type",/^(text\/)?(x-)?(stylesheet|css)$/i,"css"],["type",/./,"text/plain"],[null,null,"css"]]},n={};function r(e,t){var r=e.match(function(e){var t=n[e];return t||(n[e]=new RegExp("\\s+"+e+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}(t));return r?/^\s*(.*?)\s*$/.exec(r[2])[1]:""}function o(e,t){return new RegExp((t?"^":"")+"</\\s*"+e+"\\s*>","i")}function i(e,t){for(var n in e)for(var r=t[n]||(t[n]=[]),o=e[n],i=o.length-1;i>=0;i--)r.unshift(o[i])}e.defineMode("htmlmixed",(function(n,a){var s=e.getMode(n,{name:"xml",htmlMode:!0,multilineTagIndentFactor:a.multilineTagIndentFactor,multilineTagIndentPastTag:a.multilineTagIndentPastTag,allowMissingTagName:a.allowMissingTagName}),u={},l=a&&a.tags,c=a&&a.scriptTypes;if(i(t,u),l&&i(l,u),c)for(var f=c.length-1;f>=0;f--)u.script.unshift(["type",c[f].matches,c[f].mode]);function d(t,i){var a,l=s.token(t,i.htmlState),c=/\btag\b/.test(l);if(c&&!/[<>\s\/]/.test(t.current())&&(a=i.htmlState.tagName&&i.htmlState.tagName.toLowerCase())&&u.hasOwnProperty(a))i.inTag=a+" ";else if(i.inTag&&c&&/>$/.test(t.current())){var f=/^([\S]+) (.*)/.exec(i.inTag);i.inTag=null;var p=">"==t.current()&&function(e,t){for(var n=0;n<e.length;n++){var o=e[n];if(!o[0]||o[1].test(r(t,o[0])))return o[2]}}(u[f[1]],f[2]),h=e.getMode(n,p),v=o(f[1],!0),g=o(f[1],!1);i.token=function(e,t){return e.match(v,!1)?(t.token=d,t.localState=t.localMode=null,null):function(e,t,n){var r=e.current(),o=r.search(t);return o>-1?e.backUp(r.length-o):r.match(/<\/?$/)&&(e.backUp(r.length),e.match(t,!1)||e.match(r)),n}(e,g,t.localMode.token(e,t.localState))},i.localMode=h,i.localState=e.startState(h,s.indent(i.htmlState,"",""))}else i.inTag&&(i.inTag+=t.current(),t.eol()&&(i.inTag+=" "));return l}return{startState:function(){return{token:d,inTag:null,localMode:null,localState:null,htmlState:e.startState(s)}},copyState:function(t){var n;return t.localState&&(n=e.copyState(t.localMode,t.localState)),{token:t.token,inTag:t.inTag,localMode:t.localMode,localState:n,htmlState:e.copyState(s,t.htmlState)}},token:function(e,t){return t.token(e,t)},indent:function(t,n,r){return!t.localMode||/^\s*<\//.test(n)?s.indent(t.htmlState,n,r):t.localMode.indent?t.localMode.indent(t.localState,n,r):e.Pass},innerMode:function(e){return{state:e.localState||e.htmlState,mode:e.localMode||s}}}}),"xml","javascript","css"),e.defineMIME("text/html","htmlmixed")}(n(21),n(435),n(436),n(127))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},n={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};e.defineMode("xml",(function(r,o){var i,a,s=r.indentUnit,u={},l=o.htmlMode?t:n;for(var c in l)u[c]=l[c];for(var c in o)u[c]=o[c];function f(e,t){function n(n){return t.tokenize=n,n(e,t)}var r=e.next();return"<"==r?e.eat("!")?e.eat("[")?e.match("CDATA[")?n(p("atom","]]>")):null:e.match("--")?n(p("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),n(function e(t){return function(n,r){for(var o;null!=(o=n.next());){if("<"==o)return r.tokenize=e(t+1),r.tokenize(n,r);if(">"==o){if(1==t){r.tokenize=f;break}return r.tokenize=e(t-1),r.tokenize(n,r)}}return"meta"}}(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=p("meta","?>"),"meta"):(i=e.eat("/")?"closeTag":"openTag",t.tokenize=d,"tag bracket"):"&"==r?(e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"))?"atom":"error":(e.eatWhile(/[^&<]/),null)}function d(e,t){var n,r,o=e.next();if(">"==o||"/"==o&&e.eat(">"))return t.tokenize=f,i=">"==o?"endTag":"selfcloseTag","tag bracket";if("="==o)return i="equals",null;if("<"==o){t.tokenize=f,t.state=y,t.tagName=t.tagStart=null;var a=t.tokenize(e,t);return a?a+" tag error":"tag error"}return/[\'\"]/.test(o)?(t.tokenize=(n=o,(r=function(e,t){for(;!e.eol();)if(e.next()==n){t.tokenize=d;break}return"string"}).isInAttribute=!0,r),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function p(e,t){return function(n,r){for(;!n.eol();){if(n.match(t)){r.tokenize=f;break}n.next()}return e}}function h(e){return e&&e.toLowerCase()}function v(e,t,n){this.prev=e.context,this.tagName=t||"",this.indent=e.indented,this.startOfLine=n,(u.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function g(e){e.context&&(e.context=e.context.prev)}function m(e,t){for(var n;;){if(!e.context)return;if(n=e.context.tagName,!u.contextGrabbers.hasOwnProperty(h(n))||!u.contextGrabbers[h(n)].hasOwnProperty(h(t)))return;g(e)}}function y(e,t,n){return"openTag"==e?(n.tagStart=t.column(),b):"closeTag"==e?w:y}function b(e,t,n){return"word"==e?(n.tagName=t.current(),a="tag",k):u.allowMissingTagName&&"endTag"==e?(a="tag bracket",k(e,0,n)):(a="error",b)}function w(e,t,n){if("word"==e){var r=t.current();return n.context&&n.context.tagName!=r&&u.implicitlyClosed.hasOwnProperty(h(n.context.tagName))&&g(n),n.context&&n.context.tagName==r||!1===u.matchClosing?(a="tag",_):(a="tag error",x)}return u.allowMissingTagName&&"endTag"==e?(a="tag bracket",_(e,0,n)):(a="error",x)}function _(e,t,n){return"endTag"!=e?(a="error",_):(g(n),y)}function x(e,t,n){return a="error",_(e,0,n)}function k(e,t,n){if("word"==e)return a="attribute",C;if("endTag"==e||"selfcloseTag"==e){var r=n.tagName,o=n.tagStart;return n.tagName=n.tagStart=null,"selfcloseTag"==e||u.autoSelfClosers.hasOwnProperty(h(r))?m(n,r):(m(n,r),n.context=new v(n,r,o==n.indented)),y}return a="error",k}function C(e,t,n){return"equals"==e?O:(u.allowMissing||(a="error"),k(e,0,n))}function O(e,t,n){return"string"==e?E:"word"==e&&u.allowUnquoted?(a="string",k):(a="error",k(e,0,n))}function E(e,t,n){return"string"==e?E:k(e,0,n)}return f.isInText=!0,{startState:function(e){var t={tokenize:f,state:y,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;i=null;var n=t.tokenize(e,t);return(n||i)&&"comment"!=n&&(a=null,t.state=t.state(i||n,e,t),a&&(n="error"==a?n+" error":a)),n},indent:function(t,n,r){var o=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+s;if(o&&o.noIndent)return e.Pass;if(t.tokenize!=d&&t.tokenize!=f)return r?r.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==u.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+s*(u.multilineTagIndentFactor||1);if(u.alignCDATA&&/<!\[CDATA\[/.test(n))return 0;var i=n&&/^<(\/)?([\w_:\.-]*)/.exec(n);if(i&&i[1])for(;o;){if(o.tagName==i[2]){o=o.prev;break}if(!u.implicitlyClosed.hasOwnProperty(h(o.tagName)))break;o=o.prev}else if(i)for(;o;){var a=u.contextGrabbers[h(o.tagName)];if(!a||!a.hasOwnProperty(h(i[2])))break;o=o.prev}for(;o&&o.prev&&!o.startOfLine;)o=o.prev;return o?o.indent+s:t.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:u.htmlMode?"html":"xml",helperType:u.htmlMode?"html":"xml",skipAttribute:function(e){e.state==O&&(e.state=k)},xmlCurrentTag:function(e){return e.tagName?{name:e.tagName,close:"closeTag"==e.type}:null},xmlCurrentContext:function(e){for(var t=[],n=e.context;n;n=n.prev)t.push(n.tagName);return t.reverse()}}})),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";e.defineMode("javascript",(function(t,n){var r,o,i=t.indentUnit,a=n.statementIndent,s=n.jsonld,u=n.json||s,l=!1!==n.trackScope,c=n.typescript,f=n.wordCharacters||/[\w$\xa1-\uffff]/,d=function(){function e(e){return{type:e,style:"keyword"}}var t=e("keyword a"),n=e("keyword b"),r=e("keyword c"),o=e("keyword d"),i=e("operator"),a={type:"atom",style:"atom"};return{if:e("if"),while:t,with:t,else:n,do:n,try:n,finally:n,return:o,break:o,continue:o,new:e("new"),delete:r,void:r,throw:r,debugger:e("debugger"),var:e("var"),const:e("var"),let:e("var"),function:e("function"),catch:e("catch"),for:e("for"),switch:e("switch"),case:e("case"),default:e("default"),in:i,typeof:i,instanceof:i,true:a,false:a,null:a,undefined:a,NaN:a,Infinity:a,this:e("this"),class:e("class"),super:e("atom"),yield:r,export:e("export"),import:e("import"),extends:r,await:r}}(),p=/[+\-*&%=<>!?|~^@]/,h=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function v(e,t,n){return r=e,o=n,t}function g(e,t){var n,r=e.next();if('"'==r||"'"==r)return t.tokenize=(n=r,function(e,t){var r,o=!1;if(s&&"@"==e.peek()&&e.match(h))return t.tokenize=g,v("jsonld-keyword","meta");for(;null!=(r=e.next())&&(r!=n||o);)o=!o&&"\\"==r;return o||(t.tokenize=g),v("string","string")}),t.tokenize(e,t);if("."==r&&e.match(/^\d[\d_]*(?:[eE][+\-]?[\d_]+)?/))return v("number","number");if("."==r&&e.match(".."))return v("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return v(r);if("="==r&&e.eat(">"))return v("=>","operator");if("0"==r&&e.match(/^(?:x[\dA-Fa-f_]+|o[0-7_]+|b[01_]+)n?/))return v("number","number");if(/\d/.test(r))return e.match(/^[\d_]*(?:n|(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)?/),v("number","number");if("/"==r)return e.eat("*")?(t.tokenize=m,m(e,t)):e.eat("/")?(e.skipToEnd(),v("comment","comment")):Qe(e,t,1)?(function(e){for(var t,n=!1,r=!1;null!=(t=e.next());){if(!n){if("/"==t&&!r)return;"["==t?r=!0:r&&"]"==t&&(r=!1)}n=!n&&"\\"==t}}(e),e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),v("regexp","string-2")):(e.eat("="),v("operator","operator",e.current()));if("`"==r)return t.tokenize=y,y(e,t);if("#"==r&&"!"==e.peek())return e.skipToEnd(),v("meta","meta");if("#"==r&&e.eatWhile(f))return v("variable","property");if("<"==r&&e.match("!--")||"-"==r&&e.match("->")&&!/\S/.test(e.string.slice(0,e.start)))return e.skipToEnd(),v("comment","comment");if(p.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-|&?]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),"?"==r&&e.eat(".")?v("."):v("operator","operator",e.current());if(f.test(r)){e.eatWhile(f);var o=e.current();if("."!=t.lastType){if(d.propertyIsEnumerable(o)){var i=d[o];return v(i.type,i.style,o)}if("async"==o&&e.match(/^(\s|\/\*([^*]|\*(?!\/))*?\*\/)*[\[\(\w]/,!1))return v("async","keyword",o)}return v("variable","variable",o)}}function m(e,t){for(var n,r=!1;n=e.next();){if("/"==n&&r){t.tokenize=g;break}r="*"==n}return v("comment","comment")}function y(e,t){for(var n,r=!1;null!=(n=e.next());){if(!r&&("`"==n||"$"==n&&e.eat("{"))){t.tokenize=g;break}r=!r&&"\\"==n}return v("quasi","string-2",e.current())}function b(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var n=e.string.indexOf("=>",e.start);if(!(n<0)){if(c){var r=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,n));r&&(n=r.index)}for(var o=0,i=!1,a=n-1;a>=0;--a){var s=e.string.charAt(a),u="([{}])".indexOf(s);if(u>=0&&u<3){if(!o){++a;break}if(0==--o){"("==s&&(i=!0);break}}else if(u>=3&&u<6)++o;else if(f.test(s))i=!0;else if(/["'\/`]/.test(s))for(;;--a){if(0==a)return;if(e.string.charAt(a-1)==s&&"\\"!=e.string.charAt(a-2)){a--;break}}else if(i&&!o){++a;break}}i&&!o&&(t.fatArrowAt=a)}}var w={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,import:!0,"jsonld-keyword":!0};function _(e,t,n,r,o,i){this.indented=e,this.column=t,this.type=n,this.prev=o,this.info=i,null!=r&&(this.align=r)}function x(e,t){if(!l)return!1;for(var n=e.localVars;n;n=n.next)if(n.name==t)return!0;for(var r=e.context;r;r=r.prev)for(n=r.vars;n;n=n.next)if(n.name==t)return!0}function k(e,t,n,r,o){var i=e.cc;for(C.state=e,C.stream=o,C.marked=null,C.cc=i,C.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;)if((i.length?i.pop():u?H:F)(n,r)){for(;i.length&&i[i.length-1].lex;)i.pop()();return C.marked?C.marked:"variable"==n&&x(e,r)?"variable-2":t}}var C={state:null,column:null,marked:null,cc:null};function O(){for(var e=arguments.length-1;e>=0;e--)C.cc.push(arguments[e])}function E(){return O.apply(null,arguments),!0}function S(e,t){for(var n=t;n;n=n.next)if(n.name==e)return!0;return!1}function T(e){var t=C.state;if(C.marked="def",l){if(t.context)if("var"==t.lexical.info&&t.context&&t.context.block){var r=function e(t,n){if(n){if(n.block){var r=e(t,n.prev);return r?r==n.prev?n:new M(r,n.vars,!0):null}return S(t,n.vars)?n:new M(n.prev,new L(t,n.vars),!1)}return null}(e,t.context);if(null!=r)return void(t.context=r)}else if(!S(e,t.localVars))return void(t.localVars=new L(e,t.localVars));n.globalVars&&!S(e,t.globalVars)&&(t.globalVars=new L(e,t.globalVars))}}function j(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}function M(e,t,n){this.prev=e,this.vars=t,this.block=n}function L(e,t){this.name=e,this.next=t}var A=new L("this",new L("arguments",null));function P(){C.state.context=new M(C.state.context,C.state.localVars,!1),C.state.localVars=A}function R(){C.state.context=new M(C.state.context,C.state.localVars,!0),C.state.localVars=null}function D(){C.state.localVars=C.state.context.vars,C.state.context=C.state.context.prev}function I(e,t){var n=function(){var n=C.state,r=n.indented;if("stat"==n.lexical.type)r=n.lexical.indented;else for(var o=n.lexical;o&&")"==o.type&&o.align;o=o.prev)r=o.indented;n.lexical=new _(r,C.stream.column(),e,null,n.lexical,t)};return n.lex=!0,n}function N(){var e=C.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function z(e){return function t(n){return n==e?E():";"==e||"}"==n||")"==n||"]"==n?O():E(t)}}function F(e,t){return"var"==e?E(I("vardef",t),ke,z(";"),N):"keyword a"==e?E(I("form"),W,F,N):"keyword b"==e?E(I("form"),F,N):"keyword d"==e?C.stream.match(/^\s*$/,!1)?E():E(I("stat"),q,z(";"),N):"debugger"==e?E(z(";")):"{"==e?E(I("}"),R,se,N,D):";"==e?E():"if"==e?("else"==C.state.lexical.info&&C.state.cc[C.state.cc.length-1]==N&&C.state.cc.pop()(),E(I("form"),W,F,N,je)):"function"==e?E(Pe):"for"==e?E(I("form"),R,Me,F,D,N):"class"==e||c&&"interface"==t?(C.marked="keyword",E(I("form","class"==e?e:t),ze,N)):"variable"==e?c&&"declare"==t?(C.marked="keyword",E(F)):c&&("module"==t||"enum"==t||"type"==t)&&C.stream.match(/^\s*\w/,!1)?(C.marked="keyword","enum"==t?E(Ze):"type"==t?E(De,z("operator"),de,z(";")):E(I("form"),Ce,z("{"),I("}"),se,N,N)):c&&"namespace"==t?(C.marked="keyword",E(I("form"),H,F,N)):c&&"abstract"==t?(C.marked="keyword",E(F)):E(I("stat"),ee):"switch"==e?E(I("form"),W,z("{"),I("}","switch"),R,se,N,N,D):"case"==e?E(H,z(":")):"default"==e?E(z(":")):"catch"==e?E(I("form"),P,B,F,N,D):"export"==e?E(I("stat"),Ue,N):"import"==e?E(I("stat"),Ve,N):"async"==e?E(F):"@"==t?E(H,F):O(I("stat"),H,z(";"),N)}function B(e){if("("==e)return E(Ie,z(")"))}function H(e,t){return V(e,t,!1)}function U(e,t){return V(e,t,!0)}function W(e){return"("!=e?O():E(I(")"),q,z(")"),N)}function V(e,t,n){if(C.state.fatArrowAt==C.stream.start){var r=n?X:Z;if("("==e)return E(P,I(")"),ie(Ie,")"),N,z("=>"),r,D);if("variable"==e)return O(P,Ce,z("=>"),r,D)}var o=n?G:Y;return w.hasOwnProperty(e)?E(o):"function"==e?E(Pe,o):"class"==e||c&&"interface"==t?(C.marked="keyword",E(I("form"),Ne,N)):"keyword c"==e||"async"==e?E(n?U:H):"("==e?E(I(")"),q,z(")"),N,o):"operator"==e||"spread"==e?E(n?U:H):"["==e?E(I("]"),Ke,N,o):"{"==e?ae(ne,"}",null,o):"quasi"==e?O($,o):"new"==e?E(function(e){return function(t){return"."==t?E(e?J:Q):"variable"==t&&c?E(we,e?G:Y):O(e?U:H)}}(n)):E()}function q(e){return e.match(/[;\}\)\],]/)?O():O(H)}function Y(e,t){return","==e?E(q):G(e,t,!1)}function G(e,t,n){var r=0==n?Y:G,o=0==n?H:U;return"=>"==e?E(P,n?X:Z,D):"operator"==e?/\+\+|--/.test(t)||c&&"!"==t?E(r):c&&"<"==t&&C.stream.match(/^([^<>]|<[^<>]*>)*>\s*\(/,!1)?E(I(">"),ie(de,">"),N,r):"?"==t?E(H,z(":"),o):E(o):"quasi"==e?O($,r):";"!=e?"("==e?ae(U,")","call",r):"."==e?E(te,r):"["==e?E(I("]"),q,z("]"),N,r):c&&"as"==t?(C.marked="keyword",E(de,r)):"regexp"==e?(C.state.lastType=C.marked="operator",C.stream.backUp(C.stream.pos-C.stream.start-1),E(o)):void 0:void 0}function $(e,t){return"quasi"!=e?O():"${"!=t.slice(t.length-2)?E($):E(q,K)}function K(e){if("}"==e)return C.marked="string-2",C.state.tokenize=y,E($)}function Z(e){return b(C.stream,C.state),O("{"==e?F:H)}function X(e){return b(C.stream,C.state),O("{"==e?F:U)}function Q(e,t){if("target"==t)return C.marked="keyword",E(Y)}function J(e,t){if("target"==t)return C.marked="keyword",E(G)}function ee(e){return":"==e?E(N,F):O(Y,z(";"),N)}function te(e){if("variable"==e)return C.marked="property",E()}function ne(e,t){return"async"==e?(C.marked="property",E(ne)):"variable"==e||"keyword"==C.style?(C.marked="property","get"==t||"set"==t?E(re):(c&&C.state.fatArrowAt==C.stream.start&&(n=C.stream.match(/^\s*:\s*/,!1))&&(C.state.fatArrowAt=C.stream.pos+n[0].length),E(oe))):"number"==e||"string"==e?(C.marked=s?"property":C.style+" property",E(oe)):"jsonld-keyword"==e?E(oe):c&&j(t)?(C.marked="keyword",E(ne)):"["==e?E(H,ue,z("]"),oe):"spread"==e?E(U,oe):"*"==t?(C.marked="keyword",E(ne)):":"==e?O(oe):void 0;var n}function re(e){return"variable"!=e?O(oe):(C.marked="property",E(Pe))}function oe(e){return":"==e?E(U):"("==e?O(Pe):void 0}function ie(e,t,n){function r(o,i){if(n?n.indexOf(o)>-1:","==o){var a=C.state.lexical;return"call"==a.info&&(a.pos=(a.pos||0)+1),E((function(n,r){return n==t||r==t?O():O(e)}),r)}return o==t||i==t?E():n&&n.indexOf(";")>-1?O(e):E(z(t))}return function(n,o){return n==t||o==t?E():O(e,r)}}function ae(e,t,n){for(var r=3;r<arguments.length;r++)C.cc.push(arguments[r]);return E(I(t,n),ie(e,t),N)}function se(e){return"}"==e?E():O(F,se)}function ue(e,t){if(c){if(":"==e)return E(de);if("?"==t)return E(ue)}}function le(e,t){if(c&&(":"==e||"in"==t))return E(de)}function ce(e){if(c&&":"==e)return C.stream.match(/^\s*\w+\s+is\b/,!1)?E(H,fe,de):E(de)}function fe(e,t){if("is"==t)return C.marked="keyword",E()}function de(e,t){return"keyof"==t||"typeof"==t||"infer"==t||"readonly"==t?(C.marked="keyword",E("typeof"==t?U:de)):"variable"==e||"void"==t?(C.marked="type",E(be)):"|"==t||"&"==t?E(de):"string"==e||"number"==e||"atom"==e?E(be):"["==e?E(I("]"),ie(de,"]",","),N,be):"{"==e?E(I("}"),he,N,be):"("==e?E(ie(ye,")"),pe,be):"<"==e?E(ie(de,">"),de):"quasi"==e?O(ge,be):void 0}function pe(e){if("=>"==e)return E(de)}function he(e){return e.match(/[\}\)\]]/)?E():","==e||";"==e?E(he):O(ve,he)}function ve(e,t){return"variable"==e||"keyword"==C.style?(C.marked="property",E(ve)):"?"==t||"number"==e||"string"==e?E(ve):":"==e?E(de):"["==e?E(z("variable"),le,z("]"),ve):"("==e?O(Re,ve):e.match(/[;\}\)\],]/)?void 0:E()}function ge(e,t){return"quasi"!=e?O():"${"!=t.slice(t.length-2)?E(ge):E(de,me)}function me(e){if("}"==e)return C.marked="string-2",C.state.tokenize=y,E(ge)}function ye(e,t){return"variable"==e&&C.stream.match(/^\s*[?:]/,!1)||"?"==t?E(ye):":"==e?E(de):"spread"==e?E(ye):O(de)}function be(e,t){return"<"==t?E(I(">"),ie(de,">"),N,be):"|"==t||"."==e||"&"==t?E(de):"["==e?E(de,z("]"),be):"extends"==t||"implements"==t?(C.marked="keyword",E(de)):"?"==t?E(de,z(":"),de):void 0}function we(e,t){if("<"==t)return E(I(">"),ie(de,">"),N,be)}function _e(){return O(de,xe)}function xe(e,t){if("="==t)return E(de)}function ke(e,t){return"enum"==t?(C.marked="keyword",E(Ze)):O(Ce,ue,Se,Te)}function Ce(e,t){return c&&j(t)?(C.marked="keyword",E(Ce)):"variable"==e?(T(t),E()):"spread"==e?E(Ce):"["==e?ae(Ee,"]"):"{"==e?ae(Oe,"}"):void 0}function Oe(e,t){return"variable"!=e||C.stream.match(/^\s*:/,!1)?("variable"==e&&(C.marked="property"),"spread"==e?E(Ce):"}"==e?O():"["==e?E(H,z("]"),z(":"),Oe):E(z(":"),Ce,Se)):(T(t),E(Se))}function Ee(){return O(Ce,Se)}function Se(e,t){if("="==t)return E(U)}function Te(e){if(","==e)return E(ke)}function je(e,t){if("keyword b"==e&&"else"==t)return E(I("form","else"),F,N)}function Me(e,t){return"await"==t?E(Me):"("==e?E(I(")"),Le,N):void 0}function Le(e){return"var"==e?E(ke,Ae):"variable"==e?E(Ae):O(Ae)}function Ae(e,t){return")"==e?E():";"==e?E(Ae):"in"==t||"of"==t?(C.marked="keyword",E(H,Ae)):O(H,Ae)}function Pe(e,t){return"*"==t?(C.marked="keyword",E(Pe)):"variable"==e?(T(t),E(Pe)):"("==e?E(P,I(")"),ie(Ie,")"),N,ce,F,D):c&&"<"==t?E(I(">"),ie(_e,">"),N,Pe):void 0}function Re(e,t){return"*"==t?(C.marked="keyword",E(Re)):"variable"==e?(T(t),E(Re)):"("==e?E(P,I(")"),ie(Ie,")"),N,ce,D):c&&"<"==t?E(I(">"),ie(_e,">"),N,Re):void 0}function De(e,t){return"keyword"==e||"variable"==e?(C.marked="type",E(De)):"<"==t?E(I(">"),ie(_e,">"),N):void 0}function Ie(e,t){return"@"==t&&E(H,Ie),"spread"==e?E(Ie):c&&j(t)?(C.marked="keyword",E(Ie)):c&&"this"==e?E(ue,Se):O(Ce,ue,Se)}function Ne(e,t){return"variable"==e?ze(e,t):Fe(e,t)}function ze(e,t){if("variable"==e)return T(t),E(Fe)}function Fe(e,t){return"<"==t?E(I(">"),ie(_e,">"),N,Fe):"extends"==t||"implements"==t||c&&","==e?("implements"==t&&(C.marked="keyword"),E(c?de:H,Fe)):"{"==e?E(I("}"),Be,N):void 0}function Be(e,t){return"async"==e||"variable"==e&&("static"==t||"get"==t||"set"==t||c&&j(t))&&C.stream.match(/^\s+[\w$\xa1-\uffff]/,!1)?(C.marked="keyword",E(Be)):"variable"==e||"keyword"==C.style?(C.marked="property",E(He,Be)):"number"==e||"string"==e?E(He,Be):"["==e?E(H,ue,z("]"),He,Be):"*"==t?(C.marked="keyword",E(Be)):c&&"("==e?O(Re,Be):";"==e||","==e?E(Be):"}"==e?E():"@"==t?E(H,Be):void 0}function He(e,t){if("!"==t)return E(He);if("?"==t)return E(He);if(":"==e)return E(de,Se);if("="==t)return E(U);var n=C.state.lexical.prev;return O(n&&"interface"==n.info?Re:Pe)}function Ue(e,t){return"*"==t?(C.marked="keyword",E($e,z(";"))):"default"==t?(C.marked="keyword",E(H,z(";"))):"{"==e?E(ie(We,"}"),$e,z(";")):O(F)}function We(e,t){return"as"==t?(C.marked="keyword",E(z("variable"))):"variable"==e?O(U,We):void 0}function Ve(e){return"string"==e?E():"("==e?O(H):"."==e?O(Y):O(qe,Ye,$e)}function qe(e,t){return"{"==e?ae(qe,"}"):("variable"==e&&T(t),"*"==t&&(C.marked="keyword"),E(Ge))}function Ye(e){if(","==e)return E(qe,Ye)}function Ge(e,t){if("as"==t)return C.marked="keyword",E(qe)}function $e(e,t){if("from"==t)return C.marked="keyword",E(H)}function Ke(e){return"]"==e?E():O(ie(U,"]"))}function Ze(){return O(I("form"),Ce,z("{"),I("}"),ie(Xe,"}"),N,N)}function Xe(){return O(Ce,Se)}function Qe(e,t,n){return t.tokenize==g&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(t.lastType)||"quasi"==t.lastType&&/\{\s*$/.test(e.string.slice(0,e.pos-(n||0)))}return P.lex=R.lex=!0,D.lex=!0,N.lex=!0,{startState:function(e){var t={tokenize:g,lastType:"sof",cc:[],lexical:new _((e||0)-i,0,"block",!1),localVars:n.localVars,context:n.localVars&&new M(null,null,!1),indented:e||0};return n.globalVars&&"object"==typeof n.globalVars&&(t.globalVars=n.globalVars),t},token:function(e,t){if(e.sol()&&(t.lexical.hasOwnProperty("align")||(t.lexical.align=!1),t.indented=e.indentation(),b(e,t)),t.tokenize!=m&&e.eatSpace())return null;var n=t.tokenize(e,t);return"comment"==r?n:(t.lastType="operator"!=r||"++"!=o&&"--"!=o?r:"incdec",k(t,n,r,o,e))},indent:function(t,r){if(t.tokenize==m||t.tokenize==y)return e.Pass;if(t.tokenize!=g)return 0;var o,s=r&&r.charAt(0),u=t.lexical;if(!/^\s*else\b/.test(r))for(var l=t.cc.length-1;l>=0;--l){var c=t.cc[l];if(c==N)u=u.prev;else if(c!=je&&c!=D)break}for(;("stat"==u.type||"form"==u.type)&&("}"==s||(o=t.cc[t.cc.length-1])&&(o==Y||o==G)&&!/^[,\.=+\-*:?[\(]/.test(r));)u=u.prev;a&&")"==u.type&&"stat"==u.prev.type&&(u=u.prev);var f=u.type,d=s==f;return"vardef"==f?u.indented+("operator"==t.lastType||","==t.lastType?u.info.length+1:0):"form"==f&&"{"==s?u.indented:"form"==f?u.indented+i:"stat"==f?u.indented+(function(e,t){return"operator"==e.lastType||","==e.lastType||p.test(t.charAt(0))||/[,.]/.test(t.charAt(0))}(t,r)?a||i:0):"switch"!=u.info||d||0==n.doubleIndentSwitch?u.align?u.column+(d?0:1):u.indented+(d?0:i):u.indented+(/^(?:case|default)\b/.test(r)?i:2*i)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:u?null:"/*",blockCommentEnd:u?null:"*/",blockCommentContinue:u?null:" * ",lineComment:u?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:u?"json":"javascript",jsonldMode:s,jsonMode:u,expressionAllowed:Qe,skipExpression:function(t){k(t,"atom","atom","true",new e.StringStream("",2,null))}}})),e.registerHelper("wordChars","javascript",/[\w$]/),e.defineMIME("text/javascript","javascript"),e.defineMIME("text/ecmascript","javascript"),e.defineMIME("application/javascript","javascript"),e.defineMIME("application/x-javascript","javascript"),e.defineMIME("application/ecmascript","javascript"),e.defineMIME("application/json",{name:"javascript",json:!0}),e.defineMIME("application/x-json",{name:"javascript",json:!0}),e.defineMIME("application/manifest+json",{name:"javascript",json:!0}),e.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),e.defineMIME("text/typescript",{name:"javascript",typescript:!0}),e.defineMIME("application/typescript",{name:"javascript",typescript:!0})}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";function t(e,t){if(this.cm=e,this.options=t,this.widget=null,this.debounce=0,this.tick=0,this.startPos=this.cm.getCursor("start"),this.startLen=this.cm.getLine(this.startPos.line).length-this.cm.getSelection().length,this.options.updateOnCursorActivity){var n=this;e.on("cursorActivity",this.activityFunc=function(){n.cursorActivity()})}}e.showHint=function(e,t,n){if(!t)return e.showHint(n);n&&n.async&&(t.async=!0);var r={hint:t};if(n)for(var o in n)r[o]=n[o];return e.showHint(r)},e.defineExtension("showHint",(function(n){n=function(e,t,n){var r=e.options.hintOptions,o={};for(var i in u)o[i]=u[i];if(r)for(var i in r)void 0!==r[i]&&(o[i]=r[i]);if(n)for(var i in n)void 0!==n[i]&&(o[i]=n[i]);return o.hint.resolve&&(o.hint=o.hint.resolve(e,t)),o}(this,this.getCursor("start"),n);var r=this.listSelections();if(!(r.length>1)){if(this.somethingSelected()){if(!n.hint.supportsSelection)return;for(var o=0;o<r.length;o++)if(r[o].head.line!=r[o].anchor.line)return}this.state.completionActive&&this.state.completionActive.close();var i=this.state.completionActive=new t(this,n);i.options.hint&&(e.signal(this,"startCompletion",this),i.update(!0))}})),e.defineExtension("closeHint",(function(){this.state.completionActive&&this.state.completionActive.close()}));var n=window.requestAnimationFrame||function(e){return setTimeout(e,1e3/60)},r=window.cancelAnimationFrame||clearTimeout;function o(e){return"string"==typeof e?e:e.text}function i(e,t){for(;t&&t!=e;){if("LI"===t.nodeName.toUpperCase()&&t.parentNode==e)return t;t=t.parentNode}}function a(t,n){this.id="cm-complete-"+Math.floor(Math.random(1e6)),this.completion=t,this.data=n,this.picked=!1;var r=this,a=t.cm,s=a.getInputField().ownerDocument,u=s.defaultView||s.parentWindow,l=this.hints=s.createElement("ul");l.setAttribute("role","listbox"),l.setAttribute("aria-expanded","true"),l.id=this.id;var c=t.cm.options.theme;l.className="CodeMirror-hints "+c,this.selectedHint=n.selectedHint||0;for(var f=n.list,d=0;d<f.length;++d){var p=l.appendChild(s.createElement("li")),h=f[d],v="CodeMirror-hint"+(d!=this.selectedHint?"":" CodeMirror-hint-active");null!=h.className&&(v=h.className+" "+v),p.className=v,d==this.selectedHint&&p.setAttribute("aria-selected","true"),p.id=this.id+"-"+d,p.setAttribute("role","option"),h.render?h.render(p,n,h):p.appendChild(s.createTextNode(h.displayText||o(h))),p.hintId=d}var g=t.options.container||s.body,m=a.cursorCoords(t.options.alignWithWord?n.from:null),y=m.left,b=m.bottom,w=!0,_=0,x=0;if(g!==s.body){var k=-1!==["absolute","relative","fixed"].indexOf(u.getComputedStyle(g).position)?g:g.offsetParent,C=k.getBoundingClientRect(),O=s.body.getBoundingClientRect();_=C.left-O.left-k.scrollLeft,x=C.top-O.top-k.scrollTop}l.style.left=y-_+"px",l.style.top=b-x+"px";var E=u.innerWidth||Math.max(s.body.offsetWidth,s.documentElement.offsetWidth),S=u.innerHeight||Math.max(s.body.offsetHeight,s.documentElement.offsetHeight);g.appendChild(l),a.getInputField().setAttribute("aria-autocomplete","list"),a.getInputField().setAttribute("aria-owns",this.id),a.getInputField().setAttribute("aria-activedescendant",this.id+"-"+this.selectedHint);var T,j=t.options.moveOnOverlap?l.getBoundingClientRect():new DOMRect,M=!!t.options.paddingForScrollbar&&l.scrollHeight>l.clientHeight+1;if(setTimeout((function(){T=a.getScrollInfo()})),j.bottom-S>0){var L=j.bottom-j.top;if(m.top-(m.bottom-j.top)-L>0)l.style.top=(b=m.top-L-x)+"px",w=!1;else if(L>S){l.style.height=S-5+"px",l.style.top=(b=m.bottom-j.top-x)+"px";var A=a.getCursor();n.from.ch!=A.ch&&(m=a.cursorCoords(A),l.style.left=(y=m.left-_)+"px",j=l.getBoundingClientRect())}}var P,R=j.right-E;if(M&&(R+=a.display.nativeBarWidth),R>0&&(j.right-j.left>E&&(l.style.width=E-5+"px",R-=j.right-j.left-E),l.style.left=(y=m.left-R-_)+"px"),M)for(var D=l.firstChild;D;D=D.nextSibling)D.style.paddingRight=a.display.nativeBarWidth+"px";a.addKeyMap(this.keyMap=function(e,t){var n={Up:function(){t.moveFocus(-1)},Down:function(){t.moveFocus(1)},PageUp:function(){t.moveFocus(1-t.menuSize(),!0)},PageDown:function(){t.moveFocus(t.menuSize()-1,!0)},Home:function(){t.setFocus(0)},End:function(){t.setFocus(t.length-1)},Enter:t.pick,Tab:t.pick,Esc:t.close};/Mac/.test(navigator.platform)&&(n["Ctrl-P"]=function(){t.moveFocus(-1)},n["Ctrl-N"]=function(){t.moveFocus(1)});var r=e.options.customKeys,o=r?{}:n;function i(e,r){var i;i="string"!=typeof r?function(e){return r(e,t)}:n.hasOwnProperty(r)?n[r]:r,o[e]=i}if(r)for(var a in r)r.hasOwnProperty(a)&&i(a,r[a]);var s=e.options.extraKeys;if(s)for(var a in s)s.hasOwnProperty(a)&&i(a,s[a]);return o}(t,{moveFocus:function(e,t){r.changeActive(r.selectedHint+e,t)},setFocus:function(e){r.changeActive(e)},menuSize:function(){return r.screenAmount()},length:f.length,close:function(){t.close()},pick:function(){r.pick()},data:n})),t.options.closeOnUnfocus&&(a.on("blur",this.onBlur=function(){P=setTimeout((function(){t.close()}),100)}),a.on("focus",this.onFocus=function(){clearTimeout(P)})),a.on("scroll",this.onScroll=function(){var e=a.getScrollInfo(),n=a.getWrapperElement().getBoundingClientRect();T||(T=a.getScrollInfo());var r=b+T.top-e.top,o=r-(u.pageYOffset||(s.documentElement||s.body).scrollTop);if(w||(o+=l.offsetHeight),o<=n.top||o>=n.bottom)return t.close();l.style.top=r+"px",l.style.left=y+T.left-e.left+"px"}),e.on(l,"dblclick",(function(e){var t=i(l,e.target||e.srcElement);t&&null!=t.hintId&&(r.changeActive(t.hintId),r.pick())})),e.on(l,"click",(function(e){var n=i(l,e.target||e.srcElement);n&&null!=n.hintId&&(r.changeActive(n.hintId),t.options.completeOnSingleClick&&r.pick())})),e.on(l,"mousedown",(function(){setTimeout((function(){a.focus()}),20)}));var I=this.getSelectedHintRange();return 0===I.from&&0===I.to||this.scrollToActive(),e.signal(n,"select",f[this.selectedHint],l.childNodes[this.selectedHint]),!0}function s(e,t,n,r){if(e.async)e(t,r,n);else{var o=e(t,n);o&&o.then?o.then(r):r(o)}}t.prototype={close:function(){this.active()&&(this.cm.state.completionActive=null,this.tick=null,this.options.updateOnCursorActivity&&this.cm.off("cursorActivity",this.activityFunc),this.widget&&this.data&&e.signal(this.data,"close"),this.widget&&this.widget.close(),e.signal(this.cm,"endCompletion",this.cm))},active:function(){return this.cm.state.completionActive==this},pick:function(t,n){var r=t.list[n],i=this;this.cm.operation((function(){r.hint?r.hint(i.cm,t,r):i.cm.replaceRange(o(r),r.from||t.from,r.to||t.to,"complete"),e.signal(t,"pick",r),i.cm.scrollIntoView()})),this.options.closeOnPick&&this.close()},cursorActivity:function(){this.debounce&&(r(this.debounce),this.debounce=0);var e=this.startPos;this.data&&(e=this.data.from);var t=this.cm.getCursor(),o=this.cm.getLine(t.line);if(t.line!=this.startPos.line||o.length-t.ch!=this.startLen-this.startPos.ch||t.ch<e.ch||this.cm.somethingSelected()||!t.ch||this.options.closeCharacters.test(o.charAt(t.ch-1)))this.close();else{var i=this;this.debounce=n((function(){i.update()})),this.widget&&this.widget.disable()}},update:function(e){if(null!=this.tick){var t=this,n=++this.tick;s(this.options.hint,this.cm,this.options,(function(r){t.tick==n&&t.finishUpdate(r,e)}))}},finishUpdate:function(t,n){this.data&&e.signal(this.data,"update");var r=this.widget&&this.widget.picked||n&&this.options.completeSingle;this.widget&&this.widget.close(),this.data=t,t&&t.list.length&&(r&&1==t.list.length?this.pick(t,0):(this.widget=new a(this,t),e.signal(t,"shown")))}},a.prototype={close:function(){if(this.completion.widget==this){this.completion.widget=null,this.hints.parentNode&&this.hints.parentNode.removeChild(this.hints),this.completion.cm.removeKeyMap(this.keyMap);var e=this.completion.cm.getInputField();e.removeAttribute("aria-activedescendant"),e.removeAttribute("aria-owns");var t=this.completion.cm;this.completion.options.closeOnUnfocus&&(t.off("blur",this.onBlur),t.off("focus",this.onFocus)),t.off("scroll",this.onScroll)}},disable:function(){this.completion.cm.removeKeyMap(this.keyMap);var e=this;this.keyMap={Enter:function(){e.picked=!0}},this.completion.cm.addKeyMap(this.keyMap)},pick:function(){this.completion.pick(this.data,this.selectedHint)},changeActive:function(t,n){if(t>=this.data.list.length?t=n?this.data.list.length-1:0:t<0&&(t=n?0:this.data.list.length-1),this.selectedHint!=t){var r=this.hints.childNodes[this.selectedHint];r&&(r.className=r.className.replace(" CodeMirror-hint-active",""),r.removeAttribute("aria-selected")),(r=this.hints.childNodes[this.selectedHint=t]).className+=" CodeMirror-hint-active",r.setAttribute("aria-selected","true"),this.completion.cm.getInputField().setAttribute("aria-activedescendant",r.id),this.scrollToActive(),e.signal(this.data,"select",this.data.list[this.selectedHint],r)}},scrollToActive:function(){var e=this.getSelectedHintRange(),t=this.hints.childNodes[e.from],n=this.hints.childNodes[e.to],r=this.hints.firstChild;t.offsetTop<this.hints.scrollTop?this.hints.scrollTop=t.offsetTop-r.offsetTop:n.offsetTop+n.offsetHeight>this.hints.scrollTop+this.hints.clientHeight&&(this.hints.scrollTop=n.offsetTop+n.offsetHeight-this.hints.clientHeight+r.offsetTop)},screenAmount:function(){return Math.floor(this.hints.clientHeight/this.hints.firstChild.offsetHeight)||1},getSelectedHintRange:function(){var e=this.completion.options.scrollMargin||0;return{from:Math.max(0,this.selectedHint-e),to:Math.min(this.data.list.length-1,this.selectedHint+e)}}},e.registerHelper("hint","auto",{resolve:function(t,n){var r,o=t.getHelpers(n,"hint");if(o.length){var i=function(e,t,n){var r=function(e,t){if(!e.somethingSelected())return t;for(var n=[],r=0;r<t.length;r++)t[r].supportsSelection&&n.push(t[r]);return n}(e,o);!function o(i){if(i==r.length)return t(null);s(r[i],e,n,(function(e){e&&e.list.length>0?t(e):o(i+1)}))}(0)};return i.async=!0,i.supportsSelection=!0,i}return(r=t.getHelper(t.getCursor(),"hintWords"))?function(t){return e.hint.fromList(t,{words:r})}:e.hint.anyword?function(t,n){return e.hint.anyword(t,n)}:function(){}}}),e.registerHelper("hint","fromList",(function(t,n){var r,o=t.getCursor(),i=t.getTokenAt(o),a=e.Pos(o.line,i.start),s=o;i.start<o.ch&&/\w/.test(i.string.charAt(o.ch-i.start-1))?r=i.string.substr(0,o.ch-i.start):(r="",a=o);for(var u=[],l=0;l<n.words.length;l++){var c=n.words[l];c.slice(0,r.length)==r&&u.push(c)}if(u.length)return{list:u,from:a,to:s}})),e.commands.autocomplete=e.showHint;var u={hint:e.hint.auto,completeSingle:!0,alignWithWord:!0,closeCharacters:/[\s()\[\]{};:>,]/,closeOnPick:!0,closeOnUnfocus:!0,updateOnCursorActivity:!0,completeOnSingleClick:!0,container:null,customKeys:null,extraKeys:null,paddingForScrollbar:!0,moveOnOverlap:!0};e.defineOption("hintOptions",null)}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t={active:1,after:1,before:1,checked:1,default:1,disabled:1,empty:1,enabled:1,"first-child":1,"first-letter":1,"first-line":1,"first-of-type":1,focus:1,hover:1,"in-range":1,indeterminate:1,invalid:1,lang:1,"last-child":1,"last-of-type":1,link:1,not:1,"nth-child":1,"nth-last-child":1,"nth-last-of-type":1,"nth-of-type":1,"only-of-type":1,"only-child":1,optional:1,"out-of-range":1,placeholder:1,"read-only":1,"read-write":1,required:1,root:1,selection:1,target:1,valid:1,visited:1};e.registerHelper("hint","css",(function(n){var r=n.getCursor(),o=n.getTokenAt(r),i=e.innerMode(n.getMode(),o.state);if("css"==i.mode.name){if("keyword"==o.type&&0=="!important".indexOf(o.string))return{list:["!important"],from:e.Pos(r.line,o.start),to:e.Pos(r.line,o.end)};var a=o.start,s=r.ch,u=o.string.slice(0,s-a);/[^\w$_-]/.test(u)&&(u="",a=s=r.ch);var l=e.resolveMode("text/css"),c=[],f=i.state.state;return"pseudo"==f||"variable-3"==o.type?d(t):"block"==f||"maybeprop"==f?d(l.propertyKeywords):"prop"==f||"parens"==f||"at"==f||"params"==f?(d(l.valueKeywords),d(l.colorKeywords)):"media"!=f&&"media_parens"!=f||(d(l.mediaTypes),d(l.mediaFeatures)),c.length?{list:c,from:e.Pos(r.line,a),to:e.Pos(r.line,s)}:void 0}function d(e){for(var t in e)u&&0!=t.lastIndexOf(u,0)||c.push(t)}}))}(n(21),n(127))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t="ab aa af ak sq am ar an hy as av ae ay az bm ba eu be bn bh bi bs br bg my ca ch ce ny zh cv kw co cr hr cs da dv nl dz en eo et ee fo fj fi fr ff gl ka de el gn gu ht ha he hz hi ho hu ia id ie ga ig ik io is it iu ja jv kl kn kr ks kk km ki rw ky kv kg ko ku kj la lb lg li ln lo lt lu lv gv mk mg ms ml mt mi mr mh mn na nv nb nd ne ng nn no ii nr oc oj cu om or os pa pi fa pl ps pt qu rm rn ro ru sa sc sd se sm sg sr gd sn si sk sl so st es su sw ss sv ta te tg th ti bo tk tl tn to tr ts tt tw ty ug uk ur uz ve vi vo wa cy wo fy xh yi yo za zu".split(" "),n=["_blank","_self","_top","_parent"],r=["ascii","utf-8","utf-16","latin1","latin1"],o=["get","post","put","delete"],i=["application/x-www-form-urlencoded","multipart/form-data","text/plain"],a=["all","screen","print","embossed","braille","handheld","print","projection","screen","tty","tv","speech","3d-glasses","resolution [>][<][=] [X]","device-aspect-ratio: X/Y","orientation:portrait","orientation:landscape","device-height: [X]","device-width: [X]"],s={attrs:{}},u={a:{attrs:{href:null,ping:null,type:null,media:a,target:n,hreflang:t}},abbr:s,acronym:s,address:s,applet:s,area:{attrs:{alt:null,coords:null,href:null,target:null,ping:null,media:a,hreflang:t,type:null,shape:["default","rect","circle","poly"]}},article:s,aside:s,audio:{attrs:{src:null,mediagroup:null,crossorigin:["anonymous","use-credentials"],preload:["none","metadata","auto"],autoplay:["","autoplay"],loop:["","loop"],controls:["","controls"]}},b:s,base:{attrs:{href:null,target:n}},basefont:s,bdi:s,bdo:s,big:s,blockquote:{attrs:{cite:null}},body:s,br:s,button:{attrs:{form:null,formaction:null,name:null,value:null,autofocus:["","autofocus"],disabled:["","autofocus"],formenctype:i,formmethod:o,formnovalidate:["","novalidate"],formtarget:n,type:["submit","reset","button"]}},canvas:{attrs:{width:null,height:null}},caption:s,center:s,cite:s,code:s,col:{attrs:{span:null}},colgroup:{attrs:{span:null}},command:{attrs:{type:["command","checkbox","radio"],label:null,icon:null,radiogroup:null,command:null,title:null,disabled:["","disabled"],checked:["","checked"]}},data:{attrs:{value:null}},datagrid:{attrs:{disabled:["","disabled"],multiple:["","multiple"]}},datalist:{attrs:{data:null}},dd:s,del:{attrs:{cite:null,datetime:null}},details:{attrs:{open:["","open"]}},dfn:s,dir:s,div:s,dialog:{attrs:{open:null}},dl:s,dt:s,em:s,embed:{attrs:{src:null,type:null,width:null,height:null}},eventsource:{attrs:{src:null}},fieldset:{attrs:{disabled:["","disabled"],form:null,name:null}},figcaption:s,figure:s,font:s,footer:s,form:{attrs:{action:null,name:null,"accept-charset":r,autocomplete:["on","off"],enctype:i,method:o,novalidate:["","novalidate"],target:n}},frame:s,frameset:s,h1:s,h2:s,h3:s,h4:s,h5:s,h6:s,head:{attrs:{},children:["title","base","link","style","meta","script","noscript","command"]},header:s,hgroup:s,hr:s,html:{attrs:{manifest:null},children:["head","body"]},i:s,iframe:{attrs:{src:null,srcdoc:null,name:null,width:null,height:null,sandbox:["allow-top-navigation","allow-same-origin","allow-forms","allow-scripts"],seamless:["","seamless"]}},img:{attrs:{alt:null,src:null,ismap:null,usemap:null,width:null,height:null,crossorigin:["anonymous","use-credentials"]}},input:{attrs:{alt:null,dirname:null,form:null,formaction:null,height:null,list:null,max:null,maxlength:null,min:null,name:null,pattern:null,placeholder:null,size:null,src:null,step:null,value:null,width:null,accept:["audio/*","video/*","image/*"],autocomplete:["on","off"],autofocus:["","autofocus"],checked:["","checked"],disabled:["","disabled"],formenctype:i,formmethod:o,formnovalidate:["","novalidate"],formtarget:n,multiple:["","multiple"],readonly:["","readonly"],required:["","required"],type:["hidden","text","search","tel","url","email","password","datetime","date","month","week","time","datetime-local","number","range","color","checkbox","radio","file","submit","image","reset","button"]}},ins:{attrs:{cite:null,datetime:null}},kbd:s,keygen:{attrs:{challenge:null,form:null,name:null,autofocus:["","autofocus"],disabled:["","disabled"],keytype:["RSA"]}},label:{attrs:{for:null,form:null}},legend:s,li:{attrs:{value:null}},link:{attrs:{href:null,type:null,hreflang:t,media:a,sizes:["all","16x16","16x16 32x32","16x16 32x32 64x64"]}},map:{attrs:{name:null}},mark:s,menu:{attrs:{label:null,type:["list","context","toolbar"]}},meta:{attrs:{content:null,charset:r,name:["viewport","application-name","author","description","generator","keywords"],"http-equiv":["content-language","content-type","default-style","refresh"]}},meter:{attrs:{value:null,min:null,low:null,high:null,max:null,optimum:null}},nav:s,noframes:s,noscript:s,object:{attrs:{data:null,type:null,name:null,usemap:null,form:null,width:null,height:null,typemustmatch:["","typemustmatch"]}},ol:{attrs:{reversed:["","reversed"],start:null,type:["1","a","A","i","I"]}},optgroup:{attrs:{disabled:["","disabled"],label:null}},option:{attrs:{disabled:["","disabled"],label:null,selected:["","selected"],value:null}},output:{attrs:{for:null,form:null,name:null}},p:s,param:{attrs:{name:null,value:null}},pre:s,progress:{attrs:{value:null,max:null}},q:{attrs:{cite:null}},rp:s,rt:s,ruby:s,s:s,samp:s,script:{attrs:{type:["text/javascript"],src:null,async:["","async"],defer:["","defer"],charset:r}},section:s,select:{attrs:{form:null,name:null,size:null,autofocus:["","autofocus"],disabled:["","disabled"],multiple:["","multiple"]}},small:s,source:{attrs:{src:null,type:null,media:null}},span:s,strike:s,strong:s,style:{attrs:{type:["text/css"],media:a,scoped:null}},sub:s,summary:s,sup:s,table:s,tbody:s,td:{attrs:{colspan:null,rowspan:null,headers:null}},textarea:{attrs:{dirname:null,form:null,maxlength:null,name:null,placeholder:null,rows:null,cols:null,autofocus:["","autofocus"],disabled:["","disabled"],readonly:["","readonly"],required:["","required"],wrap:["soft","hard"]}},tfoot:s,th:{attrs:{colspan:null,rowspan:null,headers:null,scope:["row","col","rowgroup","colgroup"]}},thead:s,time:{attrs:{datetime:null}},title:s,tr:s,track:{attrs:{src:null,label:null,default:null,kind:["subtitles","captions","descriptions","chapters","metadata"],srclang:t}},tt:s,u:s,ul:s,var:s,video:{attrs:{src:null,poster:null,width:null,height:null,crossorigin:["anonymous","use-credentials"],preload:["auto","metadata","none"],autoplay:["","autoplay"],mediagroup:["movie"],muted:["","muted"],controls:["","controls"]}},wbr:s},l={accesskey:["a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","0","1","2","3","4","5","6","7","8","9"],class:null,contenteditable:["true","false"],contextmenu:null,dir:["ltr","rtl","auto"],draggable:["true","false","auto"],dropzone:["copy","move","link","string:","file:"],hidden:["hidden"],id:null,inert:["inert"],itemid:null,itemprop:null,itemref:null,itemscope:["itemscope"],itemtype:null,lang:["en","es"],spellcheck:["true","false"],autocorrect:["true","false"],autocapitalize:["true","false"],style:null,tabindex:["1","2","3","4","5","6","7","8","9"],title:null,translate:["yes","no"],onclick:null,rel:["stylesheet","alternate","author","bookmark","help","license","next","nofollow","noreferrer","prefetch","prev","search","tag"]};function c(e){for(var t in l)l.hasOwnProperty(t)&&(e.attrs[t]=l[t])}for(var f in c(s),u)u.hasOwnProperty(f)&&u[f]!=s&&c(u[f]);e.htmlSchema=u,e.registerHelper("hint","html",(function(t,n){var r={schemaInfo:u};if(n)for(var o in n)r[o]=n[o];return e.hint.xml(t,r)}))}(n(21),n(440))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t=e.Pos;function n(e,t,n){return n?e.indexOf(t)>=0:0==e.lastIndexOf(t,0)}e.registerHelper("hint","xml",(function(r,o){var i=o&&o.schemaInfo,a=o&&o.quoteChar||'"',s=o&&o.matchInMiddle;if(i){var u=r.getCursor(),l=r.getTokenAt(u);if(l.end>u.ch&&(l.end=u.ch,l.string=l.string.slice(0,u.ch-l.start)),(b=e.innerMode(r.getMode(),l.state)).mode.xmlCurrentTag){var c,f,d=[],p=!1,h=/\btag\b/.test(l.type)&&!/>$/.test(l.string),v=h&&/^\w/.test(l.string);if(v){var g=r.getLine(u.line).slice(Math.max(0,l.start-2),l.start),m=/<\/$/.test(g)?"close":/<$/.test(g)?"open":null;m&&(f=l.start-("close"==m?2:1))}else h&&"<"==l.string?m="open":h&&"</"==l.string&&(m="close");var y=b.mode.xmlCurrentTag(b.state);if(!h&&!y||m){v&&(c=l.string),p=m;var b,w=b.mode.xmlCurrentContext?b.mode.xmlCurrentContext(b.state):[],_=(b=w.length&&w[w.length-1])&&i[b],x=b?_&&_.children:i["!top"];if(x&&"close"!=m)for(var k=0;k<x.length;++k)c&&!n(x[k],c,s)||d.push("<"+x[k]);else if("close"!=m)for(var C in i)!i.hasOwnProperty(C)||"!top"==C||"!attrs"==C||c&&!n(C,c,s)||d.push("<"+C);b&&(!c||"close"==m&&n(b,c,s))&&d.push("</"+b+">")}else{var O=(_=y&&i[y.name])&&_.attrs,E=i["!attrs"];if(!O&&!E)return;if(O){if(E){var S={};for(var T in E)E.hasOwnProperty(T)&&(S[T]=E[T]);for(var T in O)O.hasOwnProperty(T)&&(S[T]=O[T]);O=S}}else O=E;if("string"==l.type||"="==l.string){var j,M=(g=r.getRange(t(u.line,Math.max(0,u.ch-60)),t(u.line,"string"==l.type?l.start:l.end))).match(/([^\s\u00a0=<>\"\']+)=$/);if(!M||!O.hasOwnProperty(M[1])||!(j=O[M[1]]))return;if("function"==typeof j&&(j=j.call(this,r)),"string"==l.type){c=l.string;var L=0;/['"]/.test(l.string.charAt(0))&&(a=l.string.charAt(0),c=l.string.slice(1),L++);var A=l.string.length;if(/['"]/.test(l.string.charAt(A-1))&&(a=l.string.charAt(A-1),c=l.string.substr(L,A-2)),L){var P=r.getLine(u.line);P.length>l.end&&P.charAt(l.end)==a&&l.end++}p=!0}var R=function(e){if(e)for(var t=0;t<e.length;++t)c&&!n(e[t],c,s)||d.push(a+e[t]+a);return I()};return j&&j.then?j.then(R):R(j)}for(var D in"attribute"==l.type&&(c=l.string,p=!0),O)!O.hasOwnProperty(D)||c&&!n(D,c,s)||d.push(D)}return I()}}function I(){return{list:d,from:p?t(u.line,null==f?l.start:f):u,to:p?t(u.line,l.end):u}}}))}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){var t={pairs:"()[]{}''\"\"",closeBefore:")]}'\":;>",triples:"",explode:"[]{}"},n=e.Pos;function r(e,n){return"pairs"==n&&"string"==typeof e?e:"object"==typeof e&&null!=e[n]?e[n]:t[n]}e.defineOption("autoCloseBrackets",!1,(function(t,n,a){a&&a!=e.Init&&(t.removeKeyMap(o),t.state.closeBrackets=null),n&&(i(r(n,"pairs")),t.state.closeBrackets=n,t.addKeyMap(o))}));var o={Backspace:function(t){var o=s(t);if(!o||t.getOption("disableInput"))return e.Pass;for(var i=r(o,"pairs"),a=t.listSelections(),u=0;u<a.length;u++){if(!a[u].empty())return e.Pass;var c=l(t,a[u].head);if(!c||i.indexOf(c)%2!=0)return e.Pass}for(u=a.length-1;u>=0;u--){var f=a[u].head;t.replaceRange("",n(f.line,f.ch-1),n(f.line,f.ch+1),"+delete")}},Enter:function(t){var n=s(t),o=n&&r(n,"explode");if(!o||t.getOption("disableInput"))return e.Pass;for(var i=t.listSelections(),a=0;a<i.length;a++){if(!i[a].empty())return e.Pass;var c=l(t,i[a].head);if(!c||o.indexOf(c)%2!=0)return e.Pass}t.operation((function(){var e=t.lineSeparator()||"\n";t.replaceSelection(e+e,null),u(t,-1),i=t.listSelections();for(var n=0;n<i.length;n++){var r=i[n].head.line;t.indentLine(r,null,!0),t.indentLine(r+1,null,!0)}}))}};function i(e){for(var t=0;t<e.length;t++){var n=e.charAt(t),r="'"+n+"'";o[r]||(o[r]=a(n))}}function a(t){return function(o){return function(t,o){var i=s(t);if(!i||t.getOption("disableInput"))return e.Pass;var a=r(i,"pairs"),l=a.indexOf(o);if(-1==l)return e.Pass;for(var f,d=r(i,"closeBefore"),p=r(i,"triples"),h=a.charAt(l+1)==o,v=t.listSelections(),g=l%2==0,m=0;m<v.length;m++){var y,b=v[m],w=b.head,_=t.getRange(w,n(w.line,w.ch+1));if(g&&!b.empty())y="surround";else if(!h&&g||_!=o)if(h&&w.ch>1&&p.indexOf(o)>=0&&t.getRange(n(w.line,w.ch-2),w)==o+o){if(w.ch>2&&/\bstring/.test(t.getTokenTypeAt(n(w.line,w.ch-2))))return e.Pass;y="addFour"}else if(h){var x=0==w.ch?" ":t.getRange(n(w.line,w.ch-1),w);if(e.isWordChar(_)||x==o||e.isWordChar(x))return e.Pass;y="both"}else{if(!g||!(0===_.length||/\s/.test(_)||d.indexOf(_)>-1))return e.Pass;y="both"}else y=h&&c(t,w)?"both":p.indexOf(o)>=0&&t.getRange(w,n(w.line,w.ch+3))==o+o+o?"skipThree":"skip";if(f){if(f!=y)return e.Pass}else f=y}var k=l%2?a.charAt(l-1):o,C=l%2?o:a.charAt(l+1);t.operation((function(){if("skip"==f)u(t,1);else if("skipThree"==f)u(t,3);else if("surround"==f){for(var r=t.getSelections(),o=0;o<r.length;o++)r[o]=k+r[o]+C;for(t.replaceSelections(r,"around"),r=t.listSelections().slice(),o=0;o<r.length;o++)r[o]=(i=r[o],a=void 0,a=e.cmpPos(i.anchor,i.head)>0,{anchor:new n(i.anchor.line,i.anchor.ch+(a?-1:1)),head:new n(i.head.line,i.head.ch+(a?1:-1))});t.setSelections(r)}else"both"==f?(t.replaceSelection(k+C,null),t.triggerElectric(k+C),u(t,-1)):"addFour"==f&&(t.replaceSelection(k+k+k+k,"before"),u(t,1));var i,a}))}(o,t)}}function s(e){var t=e.state.closeBrackets;return!t||t.override?t:e.getModeAt(e.getCursor()).closeBrackets||t}function u(e,t){for(var n=[],r=e.listSelections(),o=0,i=0;i<r.length;i++){var a=r[i];a.head==e.getCursor()&&(o=i);var s=a.head.ch||t>0?{line:a.head.line,ch:a.head.ch+t}:{line:a.head.line-1};n.push({anchor:s,head:s})}e.setSelections(n,o)}function l(e,t){var r=e.getRange(n(t.line,t.ch-1),n(t.line,t.ch+1));return 2==r.length?r:null}function c(e,t){var r=e.getTokenAt(n(t.line,t.ch+1));return/\bstring/.test(r.type)&&r.start==t.ch&&(0==t.ch||!/\bstring/.test(e.getTokenTypeAt(t)))}i(t.pairs+"`")}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){e.defineOption("autoCloseTags",!1,(function(a,s,u){if(u!=e.Init&&u&&a.removeKeyMap("autoCloseTags"),s){var l={name:"autoCloseTags"};"object"==typeof s&&!1===s.whenClosing||(l["'/'"]=function(t){return function(t){return t.getOption("disableInput")?e.Pass:r(t,!0)}(t)}),"object"==typeof s&&!1===s.whenOpening||(l["'>'"]=function(r){return function(r){if(r.getOption("disableInput"))return e.Pass;for(var a=r.listSelections(),s=[],u=r.getOption("autoCloseTags"),l=0;l<a.length;l++){if(!a[l].empty())return e.Pass;var c=a[l].head,f=r.getTokenAt(c),d=e.innerMode(r.getMode(),f.state),p=d.state,h=d.mode.xmlCurrentTag&&d.mode.xmlCurrentTag(p),v=h&&h.name;if(!v)return e.Pass;var g="html"==d.mode.configuration,m="object"==typeof u&&u.dontCloseTags||g&&t,y="object"==typeof u&&u.indentTags||g&&n;f.end>c.ch&&(v=v.slice(0,v.length-f.end+c.ch));var b=v.toLowerCase();if(!v||"string"==f.type&&(f.end!=c.ch||!/[\"\']/.test(f.string.charAt(f.string.length-1))||1==f.string.length)||"tag"==f.type&&h.close||f.string.indexOf("/")==c.ch-f.start-1||m&&o(m,b)>-1||i(r,d.mode.xmlCurrentContext&&d.mode.xmlCurrentContext(p)||[],v,c,!0))return e.Pass;var w="object"==typeof u&&u.emptyTags;if(w&&o(w,v)>-1)s[l]={text:"/>",newPos:e.Pos(c.line,c.ch+2)};else{var _=y&&o(y,b)>-1;s[l]={indent:_,text:">"+(_?"\n\n":"")+"</"+v+">",newPos:_?e.Pos(c.line+1,0):e.Pos(c.line,c.ch+1)}}}var x="object"==typeof u&&u.dontIndentOnAutoClose;for(l=a.length-1;l>=0;l--){var k=s[l];r.replaceRange(k.text,a[l].head,a[l].anchor,"+insert");var C=r.listSelections().slice(0);C[l]={head:k.newPos,anchor:k.newPos},r.setSelections(C),!x&&k.indent&&(r.indentLine(k.newPos.line,null,!0),r.indentLine(k.newPos.line+1,null,!0))}}(r)}),a.addKeyMap(l)}}));var t=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"],n=["applet","blockquote","body","button","div","dl","fieldset","form","frameset","h1","h2","h3","h4","h5","h6","head","html","iframe","layer","legend","object","ol","p","select","table","ul"];function r(t,n){for(var r=t.listSelections(),o=[],a=n?"/":"</",s=t.getOption("autoCloseTags"),u="object"==typeof s&&s.dontIndentOnSlash,l=0;l<r.length;l++){if(!r[l].empty())return e.Pass;var c=r[l].head,f=t.getTokenAt(c),d=e.innerMode(t.getMode(),f.state),p=d.state;if(n&&("string"==f.type||"<"!=f.string.charAt(0)||f.start!=c.ch-1))return e.Pass;var h,v="xml"!=d.mode.name&&"htmlmixed"==t.getMode().name;if(v&&"javascript"==d.mode.name)h=a+"script";else if(v&&"css"==d.mode.name)h=a+"style";else{var g=d.mode.xmlCurrentContext&&d.mode.xmlCurrentContext(p),m=g.length?g[g.length-1]:"";if(!g||g.length&&i(t,g,m,c))return e.Pass;h=a+m}">"!=t.getLine(c.line).charAt(f.end)&&(h+=">"),o[l]=h}if(t.replaceSelections(o),r=t.listSelections(),!u)for(l=0;l<r.length;l++)(l==r.length-1||r[l].head.line<r[l+1].head.line)&&t.indentLine(r[l].head.line)}function o(e,t){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;++n)if(e[n]==t)return n;return-1}function i(t,n,r,o,i){if(!e.scanForClosingTag)return!1;var a=Math.min(t.lastLine()+1,o.line+500),s=e.scanForClosingTag(t,o,null,a);if(!s||s.tag!=r)return!1;for(var u=i?1:0,l=n.length-1;l>=0&&n[l]==r;l--)++u;for(o=s.to,l=1;l<u;l++){var c=e.scanForClosingTag(t,o,null,a);if(!c||c.tag!=r)return!1;o=c.to}return!0}e.commands.closeTag=function(e){return r(e)}}(n(21),n(192))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";function t(e){e.state.tagHit&&e.state.tagHit.clear(),e.state.tagOther&&e.state.tagOther.clear(),e.state.tagHit=e.state.tagOther=null}function n(n){n.state.failedTagMatch=!1,n.operation((function(){if(t(n),!n.somethingSelected()){var r=n.getCursor(),o=n.getViewport();o.from=Math.min(o.from,r.line),o.to=Math.max(r.line+1,o.to);var i=e.findMatchingTag(n,r,o);if(i){if(n.state.matchBothTags){var a="open"==i.at?i.open:i.close;a&&(n.state.tagHit=n.markText(a.from,a.to,{className:"CodeMirror-matchingtag"}))}var s="close"==i.at?i.open:i.close;s?n.state.tagOther=n.markText(s.from,s.to,{className:"CodeMirror-matchingtag"}):n.state.failedTagMatch=!0}}}))}function r(e){e.state.failedTagMatch&&n(e)}e.defineOption("matchTags",!1,(function(o,i,a){a&&a!=e.Init&&(o.off("cursorActivity",n),o.off("viewportChange",r),t(o)),i&&(o.state.matchBothTags="object"==typeof i&&i.bothTags,o.on("cursorActivity",n),o.on("viewportChange",r),n(o))})),e.commands.toMatchingTag=function(t){var n=e.findMatchingTag(t,t.getCursor());if(n){var r="close"==n.at?n.open:n.close;r&&t.extendSelection(r.to,r.from)}}}(n(21),n(192))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";var t="CodeMirror-activeline-background";function n(e){for(var n=0;n<e.state.activeLines.length;n++)e.removeLineClass(e.state.activeLines[n],"wrap","CodeMirror-activeline"),e.removeLineClass(e.state.activeLines[n],"background",t),e.removeLineClass(e.state.activeLines[n],"gutter","CodeMirror-activeline-gutter")}function r(e,r){for(var o=[],i=0;i<r.length;i++){var a=r[i],s=e.getOption("styleActiveLine");if("object"==typeof s&&s.nonEmpty?a.anchor.line==a.head.line:a.empty()){var u=e.getLineHandleVisualStart(a.head.line);o[o.length-1]!=u&&o.push(u)}}(function(e,t){if(e.length!=t.length)return!1;for(var n=0;n<e.length;n++)if(e[n]!=t[n])return!1;return!0})(e.state.activeLines,o)||e.operation((function(){n(e);for(var r=0;r<o.length;r++)e.addLineClass(o[r],"wrap","CodeMirror-activeline"),e.addLineClass(o[r],"background",t),e.addLineClass(o[r],"gutter","CodeMirror-activeline-gutter");e.state.activeLines=o}))}function o(e,t){r(e,t.ranges)}e.defineOption("styleActiveLine",!1,(function(t,i,a){var s=a!=e.Init&&a;i!=s&&(s&&(t.off("beforeSelectionChange",o),n(t),delete t.state.activeLines),i&&(t.state.activeLines=[],r(t,t.listSelections()),t.on("beforeSelectionChange",o)))}))}(n(21))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){"use strict";function t(){this.posFrom=this.posTo=this.lastQuery=this.query=null,this.overlay=null}function n(e){return e.state.search||(e.state.search=new t)}function r(e){return"string"==typeof e&&e==e.toLowerCase()}function o(e,t,n){return e.getSearchCursor(t,n,{caseFold:r(t),multiline:!0})}function i(e,t,n,r,o){e.openDialog?e.openDialog(t,o,{value:r,selectValueOnOpen:!0,bottom:e.options.search.bottom}):o(prompt(n,r))}function a(e){return e.replace(/\\([nrt\\])/g,(function(e,t){return"n"==t?"\n":"r"==t?"\r":"t"==t?"\t":"\\"==t?"\\":e}))}function s(e){var t=e.match(/^\/(.*)\/([a-z]*)$/);if(t)try{e=new RegExp(t[1],-1==t[2].indexOf("i")?"":"i")}catch(e){}else e=a(e);return("string"==typeof e?""==e:e.test(""))&&(e=/x^/),e}function u(e,t,n){t.queryText=n,t.query=s(n),e.removeOverlay(t.overlay,r(t.query)),t.overlay=function(e,t){return"string"==typeof e?e=new RegExp(e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&"),t?"gi":"g"):e.global||(e=new RegExp(e.source,e.ignoreCase?"gi":"g")),{token:function(t){e.lastIndex=t.pos;var n=e.exec(t.string);if(n&&n.index==t.pos)return t.pos+=n[0].length||1,"searching";n?t.pos=n.index:t.skipToEnd()}}}(t.query,r(t.query)),e.addOverlay(t.overlay),e.showMatchesOnScrollbar&&(t.annotate&&(t.annotate.clear(),t.annotate=null),t.annotate=e.showMatchesOnScrollbar(t.query,r(t.query)))}function l(t,r,o,a){var s=n(t);if(s.query)return c(t,r);var l=t.getSelection()||s.lastQuery;if(l instanceof RegExp&&"x^"==l.source&&(l=null),o&&t.openDialog){var d=null,h=function(n,r){e.e_stop(r),n&&(n!=s.queryText&&(u(t,s,n),s.posFrom=s.posTo=t.getCursor()),d&&(d.style.opacity=1),c(t,r.shiftKey,(function(e,n){var r;n.line<3&&document.querySelector&&(r=t.display.wrapper.querySelector(".CodeMirror-dialog"))&&r.getBoundingClientRect().bottom-4>t.cursorCoords(n,"window").top&&((d=r).style.opacity=.4)})))};!function(e,t,n,r,o){e.openDialog(t,r,{value:n,selectValueOnOpen:!0,closeOnEnter:!1,onClose:function(){f(e)},onKeyDown:o,bottom:e.options.search.bottom})}(t,p(t),l,h,(function(r,o){var i=e.keyName(r),a=t.getOption("extraKeys"),s=a&&a[i]||e.keyMap[t.getOption("keyMap")][i];"findNext"==s||"findPrev"==s||"findPersistentNext"==s||"findPersistentPrev"==s?(e.e_stop(r),u(t,n(t),o),t.execCommand(s)):"find"!=s&&"findPersistent"!=s||(e.e_stop(r),h(o,r))})),a&&l&&(u(t,s,l),c(t,r))}else i(t,p(t),"Search for:",l,(function(e){e&&!s.query&&t.operation((function(){u(t,s,e),s.posFrom=s.posTo=t.getCursor(),c(t,r)}))}))}function c(t,r,i){t.operation((function(){var a=n(t),s=o(t,a.query,r?a.posFrom:a.posTo);(s.find(r)||(s=o(t,a.query,r?e.Pos(t.lastLine()):e.Pos(t.firstLine(),0))).find(r))&&(t.setSelection(s.from(),s.to()),t.scrollIntoView({from:s.from(),to:s.to()},20),a.posFrom=s.from(),a.posTo=s.to(),i&&i(s.from(),s.to()))}))}function f(e){e.operation((function(){var t=n(e);t.lastQuery=t.query,t.query&&(t.query=t.queryText=null,e.removeOverlay(t.overlay),t.annotate&&(t.annotate.clear(),t.annotate=null))}))}function d(e,t){var n=e?document.createElement(e):document.createDocumentFragment();for(var r in t)n[r]=t[r];for(var o=2;o<arguments.length;o++){var i=arguments[o];n.appendChild("string"==typeof i?document.createTextNode(i):i)}return n}function p(e){var t=d("label",{className:"CodeMirror-search-label"},e.phrase("Search:"),d("input",{type:"text",style:"width: 10em",className:"CodeMirror-search-field",id:"CodeMirror-search-field"}));return t.setAttribute("for","CodeMirror-search-field"),d("",null,t," ",d("span",{style:"color: #666",className:"CodeMirror-search-hint"},e.phrase("(Use /re/ syntax for regexp search)")))}function h(e,t,n){e.operation((function(){for(var r=o(e,t);r.findNext();)if("string"!=typeof t){var i=e.getRange(r.from(),r.to()).match(t);r.replace(n.replace(/\$(\d)/g,(function(e,t){return i[t]})))}else r.replace(n)}))}function v(e,t){if(!e.getOption("readOnly")){var r=e.getSelection()||n(e).lastQuery,u=t?e.phrase("Replace all:"):e.phrase("Replace:"),l=d("",null,d("span",{className:"CodeMirror-search-label"},u),function(e){return d("",null," ",d("input",{type:"text",style:"width: 10em",className:"CodeMirror-search-field"})," ",d("span",{style:"color: #666",className:"CodeMirror-search-hint"},e.phrase("(Use /re/ syntax for regexp search)")))}(e));i(e,l,u,r,(function(n){n&&(n=s(n),i(e,function(e){return d("",null,d("span",{className:"CodeMirror-search-label"},e.phrase("With:"))," ",d("input",{type:"text",style:"width: 10em",className:"CodeMirror-search-field"}))}(e),e.phrase("Replace with:"),"",(function(r){if(r=a(r),t)h(e,n,r);else{f(e);var i=o(e,n,e.getCursor("from")),s=function(){var t,a=i.from();!(t=i.findNext())&&(i=o(e,n),!(t=i.findNext())||a&&i.from().line==a.line&&i.from().ch==a.ch)||(e.setSelection(i.from(),i.to()),e.scrollIntoView({from:i.from(),to:i.to()}),function(e,t,n,r){e.openConfirm?e.openConfirm(t,r):confirm(n)&&r[0]()}(e,function(e){return d("",null,d("span",{className:"CodeMirror-search-label"},e.phrase("Replace?"))," ",d("button",{},e.phrase("Yes"))," ",d("button",{},e.phrase("No"))," ",d("button",{},e.phrase("All"))," ",d("button",{},e.phrase("Stop")))}(e),e.phrase("Replace?"),[function(){u(t)},s,function(){h(e,n,r)}]))},u=function(e){i.replace("string"==typeof n?r:r.replace(/\$(\d)/g,(function(t,n){return e[n]}))),s()};s()}})))}))}}e.defineOption("search",{bottom:!1}),e.commands.find=function(e){f(e),l(e)},e.commands.findPersistent=function(e){f(e),l(e,!1,!0)},e.commands.findPersistentNext=function(e){l(e,!1,!0,!0)},e.commands.findPersistentPrev=function(e){l(e,!0,!0,!0)},e.commands.findNext=l,e.commands.findPrev=function(e){l(e,!0)},e.commands.clearSearch=f,e.commands.replace=v,e.commands.replaceAll=function(e){v(e,!0)}}(n(21),n(126),n(193))},function(e,t,n){ // CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: https://codemirror.net/LICENSE !function(e){function t(e){e.state.placeholder&&(e.state.placeholder.parentNode.removeChild(e.state.placeholder),e.state.placeholder=null)}function n(e){t(e);var n=e.state.placeholder=document.createElement("pre");n.style.cssText="height: 0; overflow: visible",n.style.direction=e.getOption("direction"),n.className="CodeMirror-placeholder CodeMirror-line-like";var r=e.getOption("placeholder");"string"==typeof r&&(r=document.createTextNode(r)),n.appendChild(r),e.display.lineSpace.insertBefore(n,e.display.lineSpace.firstChild)}function r(e){i(e)&&n(e)}function o(e){var r=e.getWrapperElement(),o=i(e);r.className=r.className.replace(" CodeMirror-empty","")+(o?" CodeMirror-empty":""),o?n(e):t(e)}function i(e){return 1===e.lineCount()&&""===e.getLine(0)}e.defineOption("placeholder","",(function(i,a,s){var u=s&&s!=e.Init;if(a&&!u)i.on("blur",r),i.on("change",o),i.on("swapDoc",o),e.on(i.getInputField(),"compositionupdate",i.state.placeholderCompose=function(){!function(e){setTimeout((function(){var r=!1;if(1==e.lineCount()){var o=e.getInputField();r="TEXTAREA"==o.nodeName?!e.getLine(0).length:!/[^\u200b]/.test(o.querySelector(".CodeMirror-line").textContent)}r?n(e):t(e)}),20)}(i)}),o(i);else if(!a&&u){i.off("blur",r),i.off("change",o),i.off("swapDoc",o),e.off(i.getInputField(),"compositionupdate",i.state.placeholderCompose),t(i);var l=i.getWrapperElement();l.className=l.className.replace(" CodeMirror-empty","")}a&&!i.hasFocus()&&r(i)}))}(n(21))},function(e,t,n){n(21).defineExtension("colorpicker",(function(){var e,t,n,r,o,i,a,s,u,l,c,f,d,p,h,v,g,m,y,b,w,_,x,k,C,O,E,S,T,j,M,L,A,P,R,D,I,N,z,F,B={trim:function(e){return e.replace(/^\s+|\s+$/g,"")},format:function(e,t){if("hex"==t){var n=e.r.toString(16);e.r<16&&(n="0"+n);var r=e.g.toString(16);e.g<16&&(r="0"+r);var o=e.b.toString(16);return e.b<16&&(o="0"+o),"#"+[n,r,o].join("")}return"rgb"==t?void 0===e.a?"rgb("+[e.r,e.g,e.b].join(",")+")":"rgba("+[e.r,e.g,e.b,e.a].join(",")+")":"hsl"==t?void 0===e.a?"hsl("+[e.h,e.s+"%",e.l+"%"].join(",")+")":"hsla("+[e.h,e.s+"%",e.l+"%",e.a].join(",")+")":e},parse:function(e){if("string"==typeof e){if(e.indexOf("rgb(")>-1){for(var t=0,n=(i=e.replace("rgb(","").replace(")","").split(",")).length;t<n;t++)i[t]=parseInt(B.trim(i[t]),10);return{type:"rgb",r:i[0],g:i[1],b:i[2],a:1}}if(e.indexOf("rgba(")>-1){for(t=0,n=(i=e.replace("rgba(","").replace(")","").split(",")).length;t<n;t++)i[t]=n-1==t?parseFloat(B.trim(i[t])):parseInt(B.trim(i[t]),10);return{type:"rgb",r:i[0],g:i[1],b:i[2],a:i[3]}}if(e.indexOf("hsl(")>-1){for(t=0,n=(i=e.replace("hsl(","").replace(")","").split(",")).length;t<n;t++)i[t]=parseInt(B.trim(i[t]),10);var r={type:"hsl",h:i[0],s:i[1],l:i[2],a:1},o=B.HSLtoRGB(r.h,r.s,r.l);return r.r=o.r,r.g=o.g,r.b=o.b,r}if(e.indexOf("hsla(")>-1){for(t=0,n=(i=e.replace("hsla(","").replace(")","").split(",")).length;t<n;t++)i[t]=n-1==t?parseFloat(B.trim(i[t])):parseInt(B.trim(i[t]),10);return r={type:"hsl",h:i[0],s:i[1],l:i[2],a:i[3]},o=B.HSLtoRGB(r.h,r.s,r.l),r.r=o.r,r.g=o.g,r.b=o.b,r}if(0==e.indexOf("#")){var i=[];if(3==(e=e.replace("#","")).length)for(t=0,n=e.length;t<n;t++){var a=e.substr(t,1);i.push(parseInt(a+a,16))}else for(t=0,n=e.length;t<n;t+=2)i.push(parseInt(e.substr(t,2),16));return{type:"hex",r:i[0],g:i[1],b:i[2],a:1}}}return e},HSVtoRGB:function(e,t,n){360==e&&(e=0);var r=t*n,o=r*(1-Math.abs(e/60%2-1)),i=n-r,a=[];return 0<=e&&e<60?a=[r,o,0]:60<=e&&e<120?a=[o,r,0]:120<=e&&e<180?a=[0,r,o]:180<=e&&e<240?a=[0,o,r]:240<=e&&e<300?a=[o,0,r]:300<=e&&e<360&&(a=[r,0,o]),{r:Math.ceil(255*(a[0]+i)),g:Math.ceil(255*(a[1]+i)),b:Math.ceil(255*(a[2]+i))}},RGBtoHSV:function(e,t,n){var r=e/255,o=t/255,i=n/255,a=Math.max(r,o,i),s=a-Math.min(r,o,i),u=0;return 0==s?u=0:a==r?u=(o-i)/s%6*60:a==o?u=60*((i-r)/s+2):a==i&&(u=60*((r-o)/s+4)),u<0&&(u=360+u),{h:u,s:0==a?0:s/a,v:a}},RGBtoHSL:function(e,t,n){e/=255,t/=255,n/=255;var r,o,i=Math.max(e,t,n),a=Math.min(e,t,n),s=(i+a)/2;if(i==a)r=o=0;else{var u=i-a;switch(o=s>.5?u/(2-i-a):u/(i+a),i){case e:r=(t-n)/u+(t<n?6:0);break;case t:r=(n-e)/u+2;break;case n:r=(e-t)/u+4}r/=6}return{h:Math.round(360*r),s:Math.round(100*o),l:Math.round(100*s)}},HUEtoRGB:function(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e},HSLtoRGB:function(e,t,n){var r,o,i;if(e/=360,n/=100,0==(t/=100))r=o=i=n;else{var a=n<.5?n*(1+t):n+t-n*t,s=2*n-a;r=this.HUEtoRGB(s,a,e+1/3),o=this.HUEtoRGB(s,a,e),i=this.HUEtoRGB(s,a,e-1/3)}return{r:255*r,g:255*o,b:255*i}}},H=[{rgb:"#ff0000",start:0},{rgb:"#ffff00",start:.17},{rgb:"#00ff00",start:.33},{rgb:"#00ffff",start:.5},{rgb:"#0000ff",start:.67},{rgb:"#ff00ff",start:.83},{rgb:"#ff0000",start:1}],U=(function(){for(var e=["","-o-","-ms-","-moz-","-webkit-"],t=document.createElement("div"),n=0;n<e.length;n++)t.style.background=e[n]+"linear-gradient(#000000, #ffffff)",t.style.background;t=null,delete t}(),function(){}),W=0,V={},q=!1,Y=2e3,G={},$=[{name:"Material",edit:!0,colors:["#fff","#f00","#0ff","#f0f","#fff","#f00","#0ff","#f0f","#fff","#f00","#0ff","#f0f"]},{name:"Custom",edit:!0,colors:[]},{name:"Pages",edit:!0,colors:["#fff","#f00","#0ff","#f0f"]}];function K(e,t,n){if("string"!=typeof e)this.el=e;else{var r=document.createElement(e);for(var o in this.uniqId=W++,r.className=t,n=n||{})r.setAttribute(o,n[o]);this.el=r}}function Z(){return B.HSVtoRGB(E,S,T)}function X(){var e=B.HSVtoRGB(E,S,T);return B.RGBtoHSL(e.r,e.g,e.b)}function Q(e){if("rgb"==(e=e||"hex"))return(n=Z()).a=1==O?void 0:O,B.format(n,"rgb");if("hsl"==e){var t=X();return t.a=1==O?void 0:O,B.format(t,"hsl")}var n=Z();return B.format(n,"hex")}function J(){var e,t,n,r,o,i,a=m.data("format")||"hex",s=null;if("hex"==a)j.val(B.format(Z(),"hex"));else if("rgb"==a)s=Z(),r=s.r,o=s.g,i=s.b,M.val(r),L.val(o),A.val(i),P.val(O);else if("hsl"==a){var u=X();e=u.h,t=u.s,n=u.l,R.val(e),D.val(t+"%"),I.val(n+"%"),N.val(O)}!function(e){c.css("background-color",e)}(Q("rgb")),s=Z(),function(e){var t=B.parse(e);t.a=0;var n=B.format(t,"rgb");t.a=1;var r=B.format(t,"rgb");h.css("background","linear-gradient(to right, "+n+", "+r+")")}(B.format(s,"rgb")),"function"==typeof U&&(isNaN(O)||U(Q(a)))}function ee(e){e.preventDefault();var n=t.position(),o=r.width(),i=r.height(),s=e.clientX-n.left,u=e.clientY-n.top;s<0?s=0:s>o&&(s=o),u<0?u=0:u>i&&(u=i),a.css({left:s-5+"px",top:u-5+"px"}),a.data("pos",{x:s,y:u}),ie(),J()}function te(e){for(var t,n,r=0;r<H.length;r++)if(H[r].start>=e){t=H[r-1],n=H[r];break}return t&&n?function(e,t,n){var r={r:parseInt(e.r+(t.r-e.r)*n,10),g:parseInt(e.g+(t.g-e.g)*n,10),b:parseInt(e.b+(t.b-e.b)*n,10)};return B.format(r,"hex")}(t,n,(e-t.start)/(n.start-t.start)):H[0].rgb}function ne(e){r.css("background-color",e)}function re(e){var t,n=f.offset().left,r=n+f.width(),o=e?ae(e).clientX:n+E/360*(r-n);t=o<n?0:o>r?100:(o-n)/(r-n)*100;var i=f.width()*(t/100);s.css({left:i-Math.ceil(s.width()/2)+"px"}),s.data("pos",{x:i}),ne(te(t/100)),E=t/100*360,J()}function oe(e){var t,n=p.offset().left,r=n+p.width(),o=ae(e).clientX;t=o<n?0:o>r?100:(o-n)/(r-n)*100;var i,a,s,u=p.width()*(t/100);g.css({left:u-Math.ceil(g.width()/2)+"px"}),g.data("pos",{x:u}),i=g.data("pos")||{x:0},a=Math.round(i.x/p.width()*100)/100,O=isNaN(a)?1:a,s=m.data("format")||"hex",O<1&&"hex"==s&&(m.removeClass(s),m.addClass("rgb"),m.data("format","rgb"),J()),J()}function ie(){var e=a.data("pos")||{x:0,y:0},t=s.data("pos")||{x:0},n=r.width(),o=r.height(),i=t.x/f.width()*360,u=e.x/n,l=(o-e.y)/o;0==n&&(i=0,u=0,l=0),E=i,S=u,T=l}function ae(e){return e.touches&&e.touches[0]?e.touches[0]:e}function se(e){var t=e.which,n=!1;return 37!=t&&39!=t&&8!=t&&46!=t&&9!=t||(n=!0),!(!n&&(t<48||t>57))}function ue(e){var t=M.val(),n=L.val(),r=A.val();""!=t&&""!=n&&""!=r&&(parseInt(t)>255?M.val(255):M.val(parseInt(t)),parseInt(n)>255?L.val(255):L.val(parseInt(n)),parseInt(r)>255?A.val(255):A.val(parseInt(r)),ce(B.format({r:M.int(),g:L.int(),b:A.int()},"hex")))}function le(e){var t;m.data("format",e),t=m.data("format")||"hex",m.removeClass("hex"),m.removeClass("rgb"),m.removeClass("hsl"),m.addClass(t)}function ce(e){var t=e||"#FF0000",n=B.parse(t);le(n.type),ne(t);var o,i,u,l,c=B.RGBtoHSV(n.r,n.g,n.b);o=c.h,i=c.s,u=c.v,l=n.a,O=l,E=o,S=i,T=u,function(){var e=r.width()*S,t=r.height()*(1-T);a.css({left:e-5+"px",top:t-5+"px"}),a.data("pos",{x:e,y:t});var n=f.width()*(E/360);s.css({left:n-7.5+"px"}),s.data("pos",{x:n});var o=p.width()*(O||0);g.css({left:o-7.5+"px"}),g.data("pos",{x:o})}(),re(),J()}function fe(e,t,n){e.addEventListener(t,n)}function de(e,t,n){e.removeEventListener(t,n)}function pe(e){r.data("isDown",!0),ee(e)}function he(e){r.data("isDown",!1)}function ve(e){e.preventDefault(),n.data("isDown",!0)}function ge(e){e.preventDefault(),d.data("isDown",!0)}function me(e){n.data("isDown",!0),re(e)}function ye(e){d.data("isDown",!0),oe(e)}function be(e){if(e.which<65||e.which>70)return se(e)}function we(e){var t=j.val();"#"==t.charAt(0)&&7==t.length&&ce(t)}function _e(e){var t,n;t=m.data("format")||"hex",n="hex","hex"==t?n="rgb":"rgb"==t?n="hsl":"hsl"==t&&(n=1==O?"hex":"rgb"),m.removeClass(t),m.addClass(n),m.data("format",n),J()}function xe(e){r.data("isDown",!1),n.data("isDown",!1),d.data("isDown",!1),"HTML"==e.target.nodeName||function(e){new K(e).closest("codemirror-colorview"),new K(e).closest("codemirror-colorpicker"),new K(e).closest("CodeMirror");e.nodeName}(e.target)}function ke(e){r.data("isDown")&&ee(e),n.data("isDown")&&re(e),d.data("isDown")&&oe(e)}function Ce(e){var t=new K("div","information-item "+e);if("hex"==e){var n=new K("div","input-field hex");j=new K("input","input",{type:"text"}),n.append(j),n.append(new K("div","title").html("HEX")),t.append(n)}else"rgb"==e?(n=new K("div","input-field rgb-r"),M=new K("input","input",{type:"text"}),n.append(M),n.append(new K("div","title").html("R")),t.append(n),n=new K("div","input-field rgb-g"),L=new K("input","input",{type:"text"}),n.append(L),n.append(new K("div","title").html("G")),t.append(n),n=new K("div","input-field rgb-b"),A=new K("input","input",{type:"text"}),n.append(A),n.append(new K("div","title").html("B")),t.append(n),n=new K("div","input-field rgb-a"),P=new K("input","input",{type:"text"}),n.append(P),n.append(new K("div","title").html("A")),t.append(n)):"hsl"==e&&(n=new K("div","input-field hsl-h"),R=new K("input","input",{type:"text"}),n.append(R),n.append(new K("div","title").html("H")),t.append(n),n=new K("div","input-field hsl-s"),D=new K("input","input",{type:"text"}),n.append(D),n.append(new K("div","title").html("S")),t.append(n),n=new K("div","input-field hsl-l"),I=new K("input","input",{type:"text"}),n.append(I),n.append(new K("div","title").html("L")),t.append(n),n=new K("div","input-field hsl-a"),N=new K("input","input",{type:"text"}),n.append(N),n.append(new K("div","title").html("A")),t.append(n));return t}function Oe(){}return K.prototype.closest=function(e){for(var t=this,n=!1;!(n=t.hasClass(e));){if(!t.el.parentNode)return null;t=new K(t.el.parentNode)}return n?t:null},K.prototype.removeClass=function(e){this.el.className=B.trim((" "+this.el.className+" ").replace(" "+e+" "," "))},K.prototype.hasClass=function(e){return!!this.el.className&&(" "+this.el.className+" ").indexOf(" "+e+" ")>-1},K.prototype.addClass=function(e){this.hasClass(e)||(this.el.className=this.el.className+" "+e)},K.prototype.html=function(e){return this.el.innerHTML=e,this},K.prototype.empty=function(){return this.html("")},K.prototype.append=function(e){return"string"==typeof e?this.el.appendChild(document.createTextNode(e)):this.el.appendChild(e.el||e),this},K.prototype.appendTo=function(e){return(e.el?e.el:e).appendChild(this.el),this},K.prototype.remove=function(){return this.el.parentNode&&this.el.parentNode.removeChild(this.el),this},K.prototype.text=function(){return this.el.textContent},K.prototype.css=function(e,t){if(2==arguments.length)this.el.style[e]=t;else if(1==arguments.length){if("string"==typeof e)return getComputedStyle(this.el)[e];var n=e||{};for(var r in n)this.el.style[r]=n[r]}return this},K.prototype.offset=function(){var e=this.el.getBoundingClientRect();return{top:e.top+document.body.scrollTop,left:e.left+document.body.scrollLeft}},K.prototype.position=function(){return{top:parseFloat(this.el.style.top),left:parseFloat(this.el.style.left)}},K.prototype.width=function(){return this.el.offsetWidth},K.prototype.height=function(){return this.el.offsetHeight},K.prototype.dataKey=function(e){return this.uniqId+"."+e},K.prototype.data=function(e,t){if(2!=arguments.length){if(1==arguments.length)return V[this.dataKey(e)];var n=Object.keys(V),r=this.uniqId+".";return n.filter((function(e){return 0==e.indexOf(r)})).map((function(e){return V[e]}))}return V[this.dataKey(e)]=t,this},K.prototype.val=function(e){return 0==arguments.length?this.el.value:(1==arguments.length&&(this.el.value=e),this)},K.prototype.int=function(){return parseInt(this.val(),10)},K.prototype.show=function(){return this.css("display","block")},K.prototype.hide=function(){return this.css("display","none")},G=F?$.filter((function(e){return e.name==F}))[0]:$[0],e=new K(document.body),t=new K("div","codemirror-colorpicker"),r=new K("div","color"),a=new K("div","drag-pointer"),o=new K("div","value"),i=new K("div","saturation"),u=new K("div","control"),l=new K("div","empty"),c=new K("div","color"),n=new K("div","hue"),f=new K("div","hue-container"),s=new K("div","drag-bar"),d=new K("div","opacity"),p=new K("div","opacity-container"),h=new K("div","color-bar"),g=new K("div","drag-bar2"),m=new K("div","information hex"),y=new K("div","information-change"),v=new K("button","format-change-button",{type:"button"}).html("\u2194"),y.append(v),m.append(Ce("hex")),m.append(Ce("rgb")),m.append(Ce("hsl")),m.append(y),o.append(a),i.append(o),r.append(i),f.append(s),n.append(f),p.append(h),p.append(g),d.append(p),u.append(n),u.append(d),u.append(l),u.append(c),b=new K("div","colorsets"),w=new K("div","menu"),_=new K("div","color-list"),b.append(w),b.append(_),C=new K("button","color-sets-choose-btn").html("+"),w.append(C),_.append(function(){for(var e=new K("div","current-color-sets"),t=0,n=G.colors.length;t<n;t++){var r=G.colors[t],o=new K("div","color-item",{"data-color":r}),i=new K("div","color-view");i.css({"background-color":r}),o.append(i),e.append(o)}return G.edit&&(o=new K("div","add-color-item").html("+"),e.append(o)),e}()),x=new K("div","color-chooser"),k=new K("div","colorsets-list"),x.append(k),t.append(r),t.append(u),t.append(m),t.append(b),t.append(x),function(){for(var e=0,t=H.length;e<t;e++){var n=H[e],r=B.parse(n.rgb);n.r=r.r,n.g=r.g,n.b=r.b}}(),ce(),{isShortCut:function(){return q},$root:t,show:function(n,o,i){var a;de(r.el,"mousedown",pe),de(r.el,"mouseup",he),de(s.el,"mousedown",ve),de(g.el,"mousedown",ge),de(f.el,"mousedown",me),de(p.el,"mousedown",ye),de(j.el,"keydown",be),de(j.el,"keyup",we),de(M.el,"keydown",se),de(M.el,"keyup",ue),de(L.el,"keydown",se),de(L.el,"keyup",ue),de(A.el,"keydown",se),de(A.el,"keyup",ue),de(document,"mouseup",xe),de(document,"mousemove",ke),de(v.el,"click",_e),U=void 0,fe(r.el,"mousedown",pe),fe(r.el,"mouseup",he),fe(s.el,"mousedown",ve),fe(g.el,"mousedown",ge),fe(f.el,"mousedown",me),fe(p.el,"mousedown",ye),fe(j.el,"keydown",be),fe(j.el,"keyup",we),fe(M.el,"keydown",se),fe(M.el,"keyup",ue),fe(L.el,"keydown",se),fe(L.el,"keyup",ue),fe(A.el,"keydown",se),fe(A.el,"keyup",ue),fe(document,"mouseup",xe),fe(document,"mousemove",ke),fe(v.el,"click",_e),t.appendTo(document.body),t.css({position:"fixed",left:"-10000px",top:"-10000px"}),t.show(),function(n){var r=t.width(),o=t.height(),i=n.left-e.el.scrollLeft;r+i>window.innerWidth&&(i-=r+i-window.innerWidth),i<0&&(i=0);var a=n.top-e.el.scrollTop;o+a>window.innerHeight&&(a-=o+a-window.innerHeight),a<0&&(a=0),t.css({left:i+"px",top:a+"px"})}(n),q=n.isShortCut||!1,ce(o),U=function(e){i(e)},(Y=n.hideDelay||2e3)>0&&(a=(a=Y)||0,de(t.el,"mouseenter"),de(t.el,"mouseleave"),fe(t.el,"mouseenter",(function(){clearTimeout(z)})),fe(t.el,"mouseleave",(function(){clearTimeout(z),z=setTimeout(Oe,a)})),clearTimeout(z),z=setTimeout(Oe,a))},hide:Oe,setColor:function(e){if("object"==typeof e){if(!e.r||!e.g||!e.b)return;ce(B.format(e,"hex"))}else if("string"==typeof e){if("#"!=e.charAt(0))return;ce(e)}},getColor:function(e){ie();var t=Z();return e?B.format(t,e):t}}}))},function(e,t,n){!function(e){"use strict";var t={aliceblue:"rgb(240, 248, 255)",antiquewhite:"rgb(250, 235, 215)",aqua:"rgb(0, 255, 255)",aquamarine:"rgb(127, 255, 212)",azure:"rgb(240, 255, 255)",beige:"rgb(245, 245, 220)",bisque:"rgb(255, 228, 196)",black:"rgb(0, 0, 0)",blanchedalmond:"rgb(255, 235, 205)",blue:"rgb(0, 0, 255)",blueviolet:"rgb(138, 43, 226)",brown:"rgb(165, 42, 42)",burlywood:"rgb(222, 184, 135)",cadetblue:"rgb(95, 158, 160)",chartreuse:"rgb(127, 255, 0)",chocolate:"rgb(210, 105, 30)",coral:"rgb(255, 127, 80)",cornflowerblue:"rgb(100, 149, 237)",cornsilk:"rgb(255, 248, 220)",crimson:"rgb(237, 20, 61)",cyan:"rgb(0, 255, 255)",darkblue:"rgb(0, 0, 139)",darkcyan:"rgb(0, 139, 139)",darkgoldenrod:"rgb(184, 134, 11)",darkgray:"rgb(169, 169, 169)",darkgrey:"rgb(169, 169, 169)",darkgreen:"rgb(0, 100, 0)",darkkhaki:"rgb(189, 183, 107)",darkmagenta:"rgb(139, 0, 139)",darkolivegreen:"rgb(85, 107, 47)",darkorange:"rgb(255, 140, 0)",darkorchid:"rgb(153, 50, 204)",darkred:"rgb(139, 0, 0)",darksalmon:"rgb(233, 150, 122)",darkseagreen:"rgb(143, 188, 143)",darkslateblue:"rgb(72, 61, 139)",darkslategray:"rgb(47, 79, 79)",darkslategrey:"rgb(47, 79, 79)",darkturquoise:"rgb(0, 206, 209)",darkviolet:"rgb(148, 0, 211)",deeppink:"rgb(255, 20, 147)",deepskyblue:"rgb(0, 191, 255)",dimgray:"rgb(105, 105, 105)",dimgrey:"rgb(105, 105, 105)",dodgerblue:"rgb(30, 144, 255)",firebrick:"rgb(178, 34, 34)",floralwhite:"rgb(255, 250, 240)",forestgreen:"rgb(34, 139, 34)",fuchsia:"rgb(255, 0, 255)",gainsboro:"rgb(220, 220, 220)",ghostwhite:"rgb(248, 248, 255)",gold:"rgb(255, 215, 0)",goldenrod:"rgb(218, 165, 32)",gray:"rgb(128, 128, 128)",grey:"rgb(128, 128, 128)",green:"rgb(0, 128, 0)",greenyellow:"rgb(173, 255, 47)",honeydew:"rgb(240, 255, 240)",hotpink:"rgb(255, 105, 180)",indianred:"rgb(205, 92, 92)",indigo:"rgb(75, 0, 130)",ivory:"rgb(255, 255, 240)",khaki:"rgb(240, 230, 140)",lavender:"rgb(230, 230, 250)",lavenderblush:"rgb(255, 240, 245)",lawngreen:"rgb(124, 252, 0)",lemonchiffon:"rgb(255, 250, 205)",lightblue:"rgb(173, 216, 230)",lightcoral:"rgb(240, 128, 128)",lightcyan:"rgb(224, 255, 255)",lightgoldenrodyellow:"rgb(250, 250, 210)",lightgreen:"rgb(144, 238, 144)",lightgray:"rgb(211, 211, 211)",lightgrey:"rgb(211, 211, 211)",lightpink:"rgb(255, 182, 193)",lightsalmon:"rgb(255, 160, 122)",lightseagreen:"rgb(32, 178, 170)",lightskyblue:"rgb(135, 206, 250)",lightslategray:"rgb(119, 136, 153)",lightslategrey:"rgb(119, 136, 153)",lightsteelblue:"rgb(176, 196, 222)",lightyellow:"rgb(255, 255, 224)",lime:"rgb(0, 255, 0)",limegreen:"rgb(50, 205, 50)",linen:"rgb(250, 240, 230)",magenta:"rgb(255, 0, 255)",maroon:"rgb(128, 0, 0)",mediumaquamarine:"rgb(102, 205, 170)",mediumblue:"rgb(0, 0, 205)",mediumorchid:"rgb(186, 85, 211)",mediumpurple:"rgb(147, 112, 219)",mediumseagreen:"rgb(60, 179, 113)",mediumslateblue:"rgb(123, 104, 238)",mediumspringgreen:"rgb(0, 250, 154)",mediumturquoise:"rgb(72, 209, 204)",mediumvioletred:"rgb(199, 21, 133)",midnightblue:"rgb(25, 25, 112)",mintcream:"rgb(245, 255, 250)",mistyrose:"rgb(255, 228, 225)",moccasin:"rgb(255, 228, 181)",navajowhite:"rgb(255, 222, 173)",navy:"rgb(0, 0, 128)",oldlace:"rgb(253, 245, 230)",olive:"rgb(128, 128, 0)",olivedrab:"rgb(107, 142, 35)",orange:"rgb(255, 165, 0)",orangered:"rgb(255, 69, 0)",orchid:"rgb(218, 112, 214)",palegoldenrod:"rgb(238, 232, 170)",palegreen:"rgb(152, 251, 152)",paleturquoise:"rgb(175, 238, 238)",palevioletred:"rgb(219, 112, 147)",papayawhip:"rgb(255, 239, 213)",peachpuff:"rgb(255, 218, 185)",peru:"rgb(205, 133, 63)",pink:"rgb(255, 192, 203)",plum:"rgb(221, 160, 221)",powderblue:"rgb(176, 224, 230)",purple:"rgb(128, 0, 128)",rebeccapurple:"rgb(102, 51, 153)",red:"rgb(255, 0, 0)",rosybrown:"rgb(188, 143, 143)",royalblue:"rgb(65, 105, 225)",saddlebrown:"rgb(139, 69, 19)",salmon:"rgb(250, 128, 114)",sandybrown:"rgb(244, 164, 96)",seagreen:"rgb(46, 139, 87)",seashell:"rgb(255, 245, 238)",sienna:"rgb(160, 82, 45)",silver:"rgb(192, 192, 192)",skyblue:"rgb(135, 206, 235)",slateblue:"rgb(106, 90, 205)",slategray:"rgb(112, 128, 144)",slategrey:"rgb(112, 128, 144)",snow:"rgb(255, 250, 250)",springgreen:"rgb(0, 255, 127)",steelblue:"rgb(70, 130, 180)",tan:"rgb(210, 180, 140)",teal:"rgb(0, 128, 128)",thistle:"rgb(216, 191, 216)",tomato:"rgb(255, 99, 71)",turquoise:"rgb(64, 224, 208)",violet:"rgb(238, 130, 238)",wheat:"rgb(245, 222, 179)",white:"rgb(255, 255, 255)",whitesmoke:"rgb(245, 245, 245)",yellow:"rgb(255, 255, 0)",yellowgreen:"rgb(154, 205, 50)",transparent:"rgba(0, 0, 0, 0)"},n=["comment","builtin"];function r(e,t){"setValue"==t.origin?(e.state.colorpicker.close_color_picker(),e.state.colorpicker.init_color_update(),e.state.colorpicker.style_color_update()):e.state.colorpicker.style_color_update(e.getCursor().line)}function o(e,t){e.state.colorpicker.isUpdate||(e.state.colorpicker.isUpdate=!0,e.state.colorpicker.close_color_picker(),e.state.colorpicker.init_color_update(),e.state.colorpicker.style_color_update())}function i(e,t){r(e,{origin:"setValue"})}function a(e,t){e.state.colorpicker.keyup(t)}function s(e,t){e.state.colorpicker.is_edit_mode()&&e.state.colorpicker.check_mousedown(t)}function u(e,t){r(e,{origin:"setValue"})}function l(e){e.state.colorpicker.close_color_picker()}function c(e,t){t="boolean"==typeof t?{mode:"view"}:Object.assign({mode:"view"},t||{}),this.opt=t,this.cm=e,this.markers={},n=this.opt.excluded_token||n,this.cm.colorpicker?this.colorpicker=this.cm.colorpicker():this.opt.colorpicker&&(this.colorpicker=this.opt.colorpicker),this.init_event()}e.defineOption("colorpicker",!1,(function(t,n,r){r&&r!=e.Init&&t.state.colorpicker&&(t.state.colorpicker.destroy(),t.state.colorpicker=null),n&&(t.state.colorpicker=new c(t,n))})),c.prototype.init_event=function(){var e,t;this.cm.on("mousedown",s),this.cm.on("keyup",a),this.cm.on("change",r),this.cm.on("update",o),this.cm.on("refresh",i),this.onPasteCallback=(e=this.cm,t=u,function(n){t.call(this,e,n)}),this.cm.getWrapperElement().addEventListener("paste",this.onPasteCallback),this.is_edit_mode()&&this.cm.on("scroll",function(e,t){var n=void 0;return function(r,o){n&&clearTimeout(n),n=setTimeout((function(){e(r,o)}),t||300)}}(l,50))},c.prototype.is_edit_mode=function(){return"edit"==this.opt.mode},c.prototype.is_view_mode=function(){return"view"==this.opt.mode},c.prototype.destroy=function(){this.cm.off("mousedown",s),this.cm.off("keyup",a),this.cm.off("change",r),this.cm.getWrapperElement().removeEventListener("paste",this.onPasteCallback),this.is_edit_mode()&&this.cm.off("scroll")},c.prototype.hasClass=function(e,t){return!!e.className&&(" "+e.className+" ").indexOf(" "+t+" ")>-1},c.prototype.check_mousedown=function(e){this.hasClass(e.target,"codemirror-colorview-background")?this.open_color_picker(e.target.parentNode):this.close_color_picker()},c.prototype.popup_color_picker=function(e){var t=this.cm.getCursor(),n=this,r={lineNo:t.line,ch:t.ch,color:e||"#FFFFFF",isShortCut:!0};Object.keys(this.markers).forEach((function(e){if(("#"+e).indexOf("#"+r.lineNo+":")>-1){var t=n.markers[e];t.ch<=r.ch&&r.ch<=t.ch+t.color.length&&(r.ch=t.ch,r.color=t.color,r.nameColor=t.nameColor)}})),this.open_color_picker(r)},c.prototype.open_color_picker=function(e){var t=e.lineNo,n=e.ch,r=e.nameColor,o=e.color;if(this.colorpicker){var i=this,a=o,s=this.cm.charCoords({line:t,ch:n});this.colorpicker.show({left:s.left,top:s.bottom,isShortCut:e.isShortCut||!1,hideDelay:i.opt.hideDelay||2e3},r||o,(function(e){i.cm.replaceRange(e,{line:t,ch:n},{line:t,ch:n+a.length},"*colorpicker"),a=e}))}},c.prototype.close_color_picker=function(e){this.colorpicker&&this.colorpicker.hide()},c.prototype.key=function(e,t){return[e,t].join(":")},c.prototype.keyup=function(e){this.colorpicker&&("Escape"==e.key||0==this.colorpicker.isShortCut())&&this.colorpicker.hide()},c.prototype.init_color_update=function(){this.markers={}},c.prototype.style_color_update=function(e){if(e)this.match(e);else for(var t=this.cm.lineCount(),n=0;n<t;n++)this.match(n)},c.prototype.empty_marker=function(e,t){for(var n,r,o=t.markedSpans||[],i=0,a=o.length;i<a;i++){var s=this.key(e,o[i].from);s&&(n=o[i].marker.replacedWith,r="codemirror-colorview",n&&n.className&&(" "+n.className+" ").indexOf(" "+r+" ")>-1)&&(delete this.markers[s],o[i].marker.clear())}},c.prototype.color_regexp=/(#(?:[\da-f]{3}){1,2}|rgb\((?:\s*\d{1,3},\s*){2}\d{1,3}\s*\)|rgba\((?:\s*\d{1,3},\s*){3}\d*\.?\d+\s*\)|hsl\(\s*\d{1,3}(?:,\s*\d{1,3}%){2}\s*\)|hsla\(\s*\d{1,3}(?:,\s*\d{1,3}%){2},\s*\d*\.?\d+\s*\)|([\w_\-]+))/gi,c.prototype.match_result=function(e){return e.text.match(this.color_regexp)},c.prototype.submatch=function(e,n){this.empty_marker(e,n);var r=this.match_result(n);if(r&&r.length)for(var o={next:0},i=0,a=r.length;i<a;i++)if(r[i].indexOf("#")>-1||r[i].indexOf("rgb")>-1||r[i].indexOf("hsl")>-1)this.render(o,e,n,r[i]);else{var s=t[r[i]];s&&this.render(o,e,n,r[i],s)}},c.prototype.match=function(e){var t=this.cm.getLineHandle(e),n=this;this.cm.operation((function(){n.submatch(e,t)}))},c.prototype.make_element=function(){var e=document.createElement("div");return e.className="codemirror-colorview",this.is_edit_mode()?e.title="open color picker":e.title="",e.back_element=this.make_background_element(),e.appendChild(e.back_element),e},c.prototype.make_background_element=function(){var e=document.createElement("div");return e.className="codemirror-colorview-background",e},c.prototype.set_state=function(e,t,n,r){var o=this.create_marker(e,t);return o.lineNo=e,o.ch=t,o.color=n,o.nameColor=r,o},c.prototype.create_marker=function(e,t){var n=this.key(e,t);return this.markers[n]||(this.markers[n]=this.make_element()),this.markers[n]},c.prototype.has_marker=function(e,t){var n=this.key(e,t);return!!this.markers[n]},c.prototype.update_element=function(e,t){e.back_element.style.backgroundColor=t},c.prototype.set_mark=function(e,t,n){this.cm.setBookmark({line:e,ch:t},{widget:n,handleMouseEvents:!0})},c.prototype.is_excluded_token=function(e,t){var r=this.cm.getTokenAt({line:e,ch:t},!0),o=r.type,i=r.state.state;if(null==o&&"block"==i)return!0;if(null==o&&"top"==i)return!0;for(var a=0,s=0,u=n.length;s<u;s++)if(o===n[s]){a++;break}return a>0},c.prototype.render=function(e,t,n,r,o){var i=n.text.indexOf(r,e.next);if(!0!==this.is_excluded_token(t,i)){if(e.next=i+r.length,this.has_marker(t,i))return this.update_element(this.create_marker(t,i),o||r),void this.set_state(t,i,r,o);var a=this.create_marker(t,i);this.update_element(a,o||r),this.set_state(t,i,r,o||r),this.set_mark(t,i,a)}}}(n(21))},function(e,t,n){(function(t){var n=function(){"use strict";function e(e,t){return null!=t&&e instanceof t}var n,r,o;try{n=Map}catch(e){n=function(){}}try{r=Set}catch(e){r=function(){}}try{o=Promise}catch(e){o=function(){}}function i(a,u,l,c,f){"object"==typeof u&&(l=u.depth,c=u.prototype,f=u.includeNonEnumerable,u=u.circular);var d=[],p=[],h=void 0!==t;return void 0===u&&(u=!0),void 0===l&&(l=1/0),function a(l,v){if(null===l)return null;if(0===v)return l;var g,m;if("object"!=typeof l)return l;if(e(l,n))g=new n;else if(e(l,r))g=new r;else if(e(l,o))g=new o((function(e,t){l.then((function(t){e(a(t,v-1))}),(function(e){t(a(e,v-1))}))}));else if(i.__isArray(l))g=[];else if(i.__isRegExp(l))g=new RegExp(l.source,s(l)),l.lastIndex&&(g.lastIndex=l.lastIndex);else if(i.__isDate(l))g=new Date(l.getTime());else{if(h&&t.isBuffer(l))return g=t.allocUnsafe?t.allocUnsafe(l.length):new t(l.length),l.copy(g),g;e(l,Error)?g=Object.create(l):void 0===c?(m=Object.getPrototypeOf(l),g=Object.create(m)):(g=Object.create(c),m=c)}if(u){var y=d.indexOf(l);if(-1!=y)return p[y];d.push(l),p.push(g)}for(var b in e(l,n)&&l.forEach((function(e,t){var n=a(t,v-1),r=a(e,v-1);g.set(n,r)})),e(l,r)&&l.forEach((function(e){var t=a(e,v-1);g.add(t)})),l){var w;m&&(w=Object.getOwnPropertyDescriptor(m,b)),w&&null==w.set||(g[b]=a(l[b],v-1))}if(Object.getOwnPropertySymbols){var _=Object.getOwnPropertySymbols(l);for(b=0;b<_.length;b++){var x=_[b];(!(C=Object.getOwnPropertyDescriptor(l,x))||C.enumerable||f)&&(g[x]=a(l[x],v-1),C.enumerable||Object.defineProperty(g,x,{enumerable:!1}))}}if(f){var k=Object.getOwnPropertyNames(l);for(b=0;b<k.length;b++){var C,O=k[b];(C=Object.getOwnPropertyDescriptor(l,O))&&C.enumerable||(g[O]=a(l[O],v-1),Object.defineProperty(g,O,{enumerable:!1}))}}return g}(a,l)}function a(e){return Object.prototype.toString.call(e)}function s(e){var t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),t}return i.clonePrototype=function(e){if(null===e)return null;var t=function(){};return t.prototype=e,new t},i.__objToStr=a,i.__isDate=function(e){return"object"==typeof e&&"[object Date]"===a(e)},i.__isArray=function(e){return"object"==typeof e&&"[object Array]"===a(e)},i.__isRegExp=function(e){return"object"==typeof e&&"[object RegExp]"===a(e)},i.__getRegExpFlags=s,i}();e.exports&&(e.exports=n)}).call(this,n(450).Buffer)},function(e,t,n){"use strict";(function(e){ /*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh <http://feross.org> * @license MIT */ var r=n(451),o=n(452),i=n(453);function a(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function s(e,t){if(a()<t)throw new RangeError("Invalid typed array length");return u.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=u.prototype:(null===e&&(e=new u(t)),e.length=t),e}function u(e,t,n){if(!(u.TYPED_ARRAY_SUPPORT||this instanceof u))return new u(e,t,n);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return f(this,e)}return l(this,e,t,n)}function l(e,t,n,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,n,r){if(t.byteLength,n<0||t.byteLength<n)throw new RangeError("'offset' is out of bounds");if(t.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");t=void 0===n&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,n):new Uint8Array(t,n,r);u.TYPED_ARRAY_SUPPORT?(e=t).__proto__=u.prototype:e=d(e,t);return e}(e,t,n,r):"string"==typeof t?function(e,t,n){"string"==typeof n&&""!==n||(n="utf8");if(!u.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|h(t,n),o=(e=s(e,r)).write(t,n);o!==r&&(e=e.slice(0,o));return e}(e,t,n):function(e,t){if(u.isBuffer(t)){var n=0|p(t.length);return 0===(e=s(e,n)).length||t.copy(e,0,0,n),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?s(e,0):d(e,t);if("Buffer"===t.type&&i(t.data))return d(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function c(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function f(e,t){if(c(t),e=s(e,t<0?0:0|p(t)),!u.TYPED_ARRAY_SUPPORT)for(var n=0;n<t;++n)e[n]=0;return e}function d(e,t){var n=t.length<0?0:0|p(t.length);e=s(e,n);for(var r=0;r<n;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=a())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+a().toString(16)+" bytes");return 0|e}function h(e,t){if(u.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var n=e.length;if(0===n)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return B(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return H(e).length;default:if(r)return B(e).length;t=(""+t).toLowerCase(),r=!0}}function v(e,t,n){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return j(this,t,n);case"utf8":case"utf-8":return E(this,t,n);case"ascii":return S(this,t,n);case"latin1":case"binary":return T(this,t,n);case"base64":return O(this,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return M(this,t,n);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function g(e,t,n){var r=e[t];e[t]=e[n],e[n]=r}function m(e,t,n,r,o){if(0===e.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=o?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(o)return-1;n=e.length-1}else if(n<0){if(!o)return-1;n=0}if("string"==typeof t&&(t=u.from(t,r)),u.isBuffer(t))return 0===t.length?-1:y(e,t,n,r,o);if("number"==typeof t)return t&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?o?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):y(e,[t],n,r,o);throw new TypeError("val must be string, number or Buffer")}function y(e,t,n,r,o){var i,a=1,s=e.length,u=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;a=2,s/=2,u/=2,n/=2}function l(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(o){var c=-1;for(i=n;i<s;i++)if(l(e,i)===l(t,-1===c?0:i-c)){if(-1===c&&(c=i),i-c+1===u)return c*a}else-1!==c&&(i-=i-c),c=-1}else for(n+u>s&&(n=s-u),i=n;i>=0;i--){for(var f=!0,d=0;d<u;d++)if(l(e,i+d)!==l(t,d)){f=!1;break}if(f)return i}return-1}function b(e,t,n,r){n=Number(n)||0;var o=e.length-n;r?(r=Number(r))>o&&(r=o):r=o;var i=t.length;if(i%2!=0)throw new TypeError("Invalid hex string");r>i/2&&(r=i/2);for(var a=0;a<r;++a){var s=parseInt(t.substr(2*a,2),16);if(isNaN(s))return a;e[n+a]=s}return a}function w(e,t,n,r){return U(B(t,e.length-n),e,n,r)}function _(e,t,n,r){return U(function(e){for(var t=[],n=0;n<e.length;++n)t.push(255&e.charCodeAt(n));return t}(t),e,n,r)}function x(e,t,n,r){return _(e,t,n,r)}function k(e,t,n,r){return U(H(t),e,n,r)}function C(e,t,n,r){return U(function(e,t){for(var n,r,o,i=[],a=0;a<e.length&&!((t-=2)<0);++a)n=e.charCodeAt(a),r=n>>8,o=n%256,i.push(o),i.push(r);return i}(t,e.length-n),e,n,r)}function O(e,t,n){return 0===t&&n===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,n))}function E(e,t,n){n=Math.min(e.length,n);for(var r=[],o=t;o<n;){var i,a,s,u,l=e[o],c=null,f=l>239?4:l>223?3:l>191?2:1;if(o+f<=n)switch(f){case 1:l<128&&(c=l);break;case 2:128==(192&(i=e[o+1]))&&(u=(31&l)<<6|63&i)>127&&(c=u);break;case 3:i=e[o+1],a=e[o+2],128==(192&i)&&128==(192&a)&&(u=(15&l)<<12|(63&i)<<6|63&a)>2047&&(u<55296||u>57343)&&(c=u);break;case 4:i=e[o+1],a=e[o+2],s=e[o+3],128==(192&i)&&128==(192&a)&&128==(192&s)&&(u=(15&l)<<18|(63&i)<<12|(63&a)<<6|63&s)>65535&&u<1114112&&(c=u)}null===c?(c=65533,f=1):c>65535&&(c-=65536,r.push(c>>>10&1023|55296),c=56320|1023&c),r.push(c),o+=f}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);var n="",r=0;for(;r<t;)n+=String.fromCharCode.apply(String,e.slice(r,r+=4096));return n}(r)}t.Buffer=u,t.SlowBuffer=function(e){+e!=e&&(e=0);return u.alloc(+e)},t.INSPECT_MAX_BYTES=50,u.TYPED_ARRAY_SUPPORT=void 0!==e.TYPED_ARRAY_SUPPORT?e.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),t.kMaxLength=a(),u.poolSize=8192,u._augment=function(e){return e.__proto__=u.prototype,e},u.from=function(e,t,n){return l(null,e,t,n)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(e,t,n){return function(e,t,n,r){return c(t),t<=0?s(e,t):void 0!==n?"string"==typeof r?s(e,t).fill(n,r):s(e,t).fill(n):s(e,t)}(null,e,t,n)},u.allocUnsafe=function(e){return f(null,e)},u.allocUnsafeSlow=function(e){return f(null,e)},u.isBuffer=function(e){return!(null==e||!e._isBuffer)},u.compare=function(e,t){if(!u.isBuffer(e)||!u.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var n=e.length,r=t.length,o=0,i=Math.min(n,r);o<i;++o)if(e[o]!==t[o]){n=e[o],r=t[o];break}return n<r?-1:r<n?1:0},u.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(e,t){if(!i(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return u.alloc(0);var n;if(void 0===t)for(t=0,n=0;n<e.length;++n)t+=e[n].length;var r=u.allocUnsafe(t),o=0;for(n=0;n<e.length;++n){var a=e[n];if(!u.isBuffer(a))throw new TypeError('"list" argument must be an Array of Buffers');a.copy(r,o),o+=a.length}return r},u.byteLength=h,u.prototype._isBuffer=!0,u.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)g(this,t,t+1);return this},u.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)g(this,t,t+3),g(this,t+1,t+2);return this},u.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)g(this,t,t+7),g(this,t+1,t+6),g(this,t+2,t+5),g(this,t+3,t+4);return this},u.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?E(this,0,e):v.apply(this,arguments)},u.prototype.equals=function(e){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===u.compare(this,e)},u.prototype.inspect=function(){var e="",n=t.INSPECT_MAX_BYTES;return this.length>0&&(e=this.toString("hex",0,n).match(/.{2}/g).join(" "),this.length>n&&(e+=" ... ")),"<Buffer "+e+">"},u.prototype.compare=function(e,t,n,r,o){if(!u.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===o&&(o=this.length),t<0||n>e.length||r<0||o>this.length)throw new RangeError("out of range index");if(r>=o&&t>=n)return 0;if(r>=o)return-1;if(t>=n)return 1;if(this===e)return 0;for(var i=(o>>>=0)-(r>>>=0),a=(n>>>=0)-(t>>>=0),s=Math.min(i,a),l=this.slice(r,o),c=e.slice(t,n),f=0;f<s;++f)if(l[f]!==c[f]){i=l[f],a=c[f];break}return i<a?-1:a<i?1:0},u.prototype.includes=function(e,t,n){return-1!==this.indexOf(e,t,n)},u.prototype.indexOf=function(e,t,n){return m(this,e,t,n,!0)},u.prototype.lastIndexOf=function(e,t,n){return m(this,e,t,n,!1)},u.prototype.write=function(e,t,n,r){if(void 0===t)r="utf8",n=this.length,t=0;else if(void 0===n&&"string"==typeof t)r=t,n=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var o=this.length-t;if((void 0===n||n>o)&&(n=o),e.length>0&&(n<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var i=!1;;)switch(r){case"hex":return b(this,e,t,n);case"utf8":case"utf-8":return w(this,e,t,n);case"ascii":return _(this,e,t,n);case"latin1":case"binary":return x(this,e,t,n);case"base64":return k(this,e,t,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return C(this,e,t,n);default:if(i)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),i=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function S(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(127&e[o]);return r}function T(e,t,n){var r="";n=Math.min(e.length,n);for(var o=t;o<n;++o)r+=String.fromCharCode(e[o]);return r}function j(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var o="",i=t;i<n;++i)o+=F(e[i]);return o}function M(e,t,n){for(var r=e.slice(t,n),o="",i=0;i<r.length;i+=2)o+=String.fromCharCode(r[i]+256*r[i+1]);return o}function L(e,t,n){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>n)throw new RangeError("Trying to access beyond buffer length")}function A(e,t,n,r,o,i){if(!u.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>o||t<i)throw new RangeError('"value" argument is out of bounds');if(n+r>e.length)throw new RangeError("Index out of range")}function P(e,t,n,r){t<0&&(t=65535+t+1);for(var o=0,i=Math.min(e.length-n,2);o<i;++o)e[n+o]=(t&255<<8*(r?o:1-o))>>>8*(r?o:1-o)}function R(e,t,n,r){t<0&&(t=4294967295+t+1);for(var o=0,i=Math.min(e.length-n,4);o<i;++o)e[n+o]=t>>>8*(r?o:3-o)&255}function D(e,t,n,r,o,i){if(n+r>e.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function I(e,t,n,r,i){return i||D(e,0,n,4),o.write(e,t,n,r,23,4),n+4}function N(e,t,n,r,i){return i||D(e,0,n,8),o.write(e,t,n,r,52,8),n+8}u.prototype.slice=function(e,t){var n,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),u.TYPED_ARRAY_SUPPORT)(n=this.subarray(e,t)).__proto__=u.prototype;else{var o=t-e;n=new u(o,void 0);for(var i=0;i<o;++i)n[i]=this[i+e]}return n},u.prototype.readUIntLE=function(e,t,n){e|=0,t|=0,n||L(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r},u.prototype.readUIntBE=function(e,t,n){e|=0,t|=0,n||L(e,t,this.length);for(var r=this[e+--t],o=1;t>0&&(o*=256);)r+=this[e+--t]*o;return r},u.prototype.readUInt8=function(e,t){return t||L(e,1,this.length),this[e]},u.prototype.readUInt16LE=function(e,t){return t||L(e,2,this.length),this[e]|this[e+1]<<8},u.prototype.readUInt16BE=function(e,t){return t||L(e,2,this.length),this[e]<<8|this[e+1]},u.prototype.readUInt32LE=function(e,t){return t||L(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},u.prototype.readUInt32BE=function(e,t){return t||L(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},u.prototype.readIntLE=function(e,t,n){e|=0,t|=0,n||L(e,t,this.length);for(var r=this[e],o=1,i=0;++i<t&&(o*=256);)r+=this[e+i]*o;return r>=(o*=128)&&(r-=Math.pow(2,8*t)),r},u.prototype.readIntBE=function(e,t,n){e|=0,t|=0,n||L(e,t,this.length);for(var r=t,o=1,i=this[e+--r];r>0&&(o*=256);)i+=this[e+--r]*o;return i>=(o*=128)&&(i-=Math.pow(2,8*t)),i},u.prototype.readInt8=function(e,t){return t||L(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},u.prototype.readInt16LE=function(e,t){t||L(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt16BE=function(e,t){t||L(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},u.prototype.readInt32LE=function(e,t){return t||L(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},u.prototype.readInt32BE=function(e,t){return t||L(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},u.prototype.readFloatLE=function(e,t){return t||L(e,4,this.length),o.read(this,e,!0,23,4)},u.prototype.readFloatBE=function(e,t){return t||L(e,4,this.length),o.read(this,e,!1,23,4)},u.prototype.readDoubleLE=function(e,t){return t||L(e,8,this.length),o.read(this,e,!0,52,8)},u.prototype.readDoubleBE=function(e,t){return t||L(e,8,this.length),o.read(this,e,!1,52,8)},u.prototype.writeUIntLE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||A(this,e,t,n,Math.pow(2,8*n)-1,0);var o=1,i=0;for(this[t]=255&e;++i<n&&(o*=256);)this[t+i]=e/o&255;return t+n},u.prototype.writeUIntBE=function(e,t,n,r){(e=+e,t|=0,n|=0,r)||A(this,e,t,n,Math.pow(2,8*n)-1,0);var o=n-1,i=1;for(this[t+o]=255&e;--o>=0&&(i*=256);)this[t+o]=e/i&255;return t+n},u.prototype.writeUInt8=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,1,255,0),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},u.prototype.writeUInt16LE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):P(this,e,t,!0),t+2},u.prototype.writeUInt16BE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):P(this,e,t,!1),t+2},u.prototype.writeUInt32LE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):R(this,e,t,!0),t+4},u.prototype.writeUInt32BE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):R(this,e,t,!1),t+4},u.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);A(this,e,t,n,o-1,-o)}var i=0,a=1,s=0;for(this[t]=255&e;++i<n&&(a*=256);)e<0&&0===s&&0!==this[t+i-1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+n},u.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t|=0,!r){var o=Math.pow(2,8*n-1);A(this,e,t,n,o-1,-o)}var i=n-1,a=1,s=0;for(this[t+i]=255&e;--i>=0&&(a*=256);)e<0&&0===s&&0!==this[t+i+1]&&(s=1),this[t+i]=(e/a>>0)-s&255;return t+n},u.prototype.writeInt8=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,1,127,-128),u.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},u.prototype.writeInt16LE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):P(this,e,t,!0),t+2},u.prototype.writeInt16BE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):P(this,e,t,!1),t+2},u.prototype.writeInt32LE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):R(this,e,t,!0),t+4},u.prototype.writeInt32BE=function(e,t,n){return e=+e,t|=0,n||A(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),u.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):R(this,e,t,!1),t+4},u.prototype.writeFloatLE=function(e,t,n){return I(this,e,t,!0,n)},u.prototype.writeFloatBE=function(e,t,n){return I(this,e,t,!1,n)},u.prototype.writeDoubleLE=function(e,t,n){return N(this,e,t,!0,n)},u.prototype.writeDoubleBE=function(e,t,n){return N(this,e,t,!1,n)},u.prototype.copy=function(e,t,n,r){if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-n&&(r=e.length-t+n);var o,i=r-n;if(this===e&&n<t&&t<r)for(o=i-1;o>=0;--o)e[o+t]=this[o+n];else if(i<1e3||!u.TYPED_ARRAY_SUPPORT)for(o=0;o<i;++o)e[o+t]=this[o+n];else Uint8Array.prototype.set.call(e,this.subarray(n,n+i),t);return i},u.prototype.fill=function(e,t,n,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===e.length){var o=e.charCodeAt(0);o<256&&(e=o)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!u.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<n)throw new RangeError("Out of range index");if(n<=t)return this;var i;if(t>>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i<n;++i)this[i]=e;else{var a=u.isBuffer(e)?e:B(new u(e,r).toString()),s=a.length;for(i=0;i<n-t;++i)this[i+t]=a[i%s]}return this};var z=/[^+\/0-9A-Za-z-_]/g;function F(e){return e<16?"0"+e.toString(16):e.toString(16)}function B(e,t){var n;t=t||1/0;for(var r=e.length,o=null,i=[],a=0;a<r;++a){if((n=e.charCodeAt(a))>55295&&n<57344){if(!o){if(n>56319){(t-=3)>-1&&i.push(239,191,189);continue}if(a+1===r){(t-=3)>-1&&i.push(239,191,189);continue}o=n;continue}if(n<56320){(t-=3)>-1&&i.push(239,191,189),o=n;continue}n=65536+(o-55296<<10|n-56320)}else o&&(t-=3)>-1&&i.push(239,191,189);if(o=null,n<128){if((t-=1)<0)break;i.push(n)}else if(n<2048){if((t-=2)<0)break;i.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;i.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;i.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return i}function H(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(z,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function U(e,t,n,r){for(var o=0;o<r&&!(o+n>=t.length||o>=e.length);++o)t[o+n]=e[o];return o}}).call(this,n(31))},function(e,t,n){"use strict";t.byteLength=function(e){var t=l(e),n=t[0],r=t[1];return 3*(n+r)/4-r},t.toByteArray=function(e){var t,n,r=l(e),a=r[0],s=r[1],u=new i(function(e,t,n){return 3*(t+n)/4-n}(0,a,s)),c=0,f=s>0?a-4:a;for(n=0;n<f;n+=4)t=o[e.charCodeAt(n)]<<18|o[e.charCodeAt(n+1)]<<12|o[e.charCodeAt(n+2)]<<6|o[e.charCodeAt(n+3)],u[c++]=t>>16&255,u[c++]=t>>8&255,u[c++]=255&t;2===s&&(t=o[e.charCodeAt(n)]<<2|o[e.charCodeAt(n+1)]>>4,u[c++]=255&t);1===s&&(t=o[e.charCodeAt(n)]<<10|o[e.charCodeAt(n+1)]<<4|o[e.charCodeAt(n+2)]>>2,u[c++]=t>>8&255,u[c++]=255&t);return u},t.fromByteArray=function(e){for(var t,n=e.length,o=n%3,i=[],a=0,s=n-o;a<s;a+=16383)i.push(c(e,a,a+16383>s?s:a+16383));1===o?(t=e[n-1],i.push(r[t>>2]+r[t<<4&63]+"==")):2===o&&(t=(e[n-2]<<8)+e[n-1],i.push(r[t>>10]+r[t>>4&63]+r[t<<2&63]+"="));return i.join("")};for(var r=[],o=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,u=a.length;s<u;++s)r[s]=a[s],o[a.charCodeAt(s)]=s;function l(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return-1===n&&(n=t),[n,n===t?0:4-n%4]}function c(e,t,n){for(var o,i,a=[],s=t;s<n;s+=3)o=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),a.push(r[(i=o)>>18&63]+r[i>>12&63]+r[i>>6&63]+r[63&i]);return a.join("")}o["-".charCodeAt(0)]=62,o["_".charCodeAt(0)]=63},function(e,t){t.read=function(e,t,n,r,o){var i,a,s=8*o-r-1,u=(1<<s)-1,l=u>>1,c=-7,f=n?o-1:0,d=n?-1:1,p=e[t+f];for(f+=d,i=p&(1<<-c)-1,p>>=-c,c+=s;c>0;i=256*i+e[t+f],f+=d,c-=8);for(a=i&(1<<-c)-1,i>>=-c,c+=r;c>0;a=256*a+e[t+f],f+=d,c-=8);if(0===i)i=1-l;else{if(i===u)return a?NaN:1/0*(p?-1:1);a+=Math.pow(2,r),i-=l}return(p?-1:1)*a*Math.pow(2,i-r)},t.write=function(e,t,n,r,o,i){var a,s,u,l=8*i-o-1,c=(1<<l)-1,f=c>>1,d=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:i-1,h=r?1:-1,v=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=c):(a=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-a))<1&&(a--,u*=2),(t+=a+f>=1?d/u:d*Math.pow(2,1-f))*u>=2&&(a++,u/=2),a+f>=c?(s=0,a=c):a+f>=1?(s=(t*u-1)*Math.pow(2,o),a+=f):(s=t*Math.pow(2,f-1)*Math.pow(2,o),a=0));o>=8;e[n+p]=255&s,p+=h,s/=256,o-=8);for(a=a<<o|s,l+=o;l>0;e[n+p]=255&a,p+=h,a/=256,l-=8);e[n+p-h]|=128*v}},function(e,t){var n={}.toString;e.exports=Array.isArray||function(e){return"[object Array]"==n.call(e)}},function(e,t,n){"use strict";e.exports={css:n(455),util:n(460)}},function(e,t,n){"use strict";e.exports={Colors:n(194),Combinator:n(195),Parser:n(34),PropertyName:n(199),PropertyValue:n(200),PropertyValuePart:n(128),Matcher:n(131),MediaFeature:n(197),MediaQuery:n(198),Selector:n(201),SelectorPart:n(129),SelectorSubPart:n(203),Specificity:n(202),TokenStream:n(204),Tokens:n(88),ValidationError:n(206)}},function(e,t,n){"use strict";var r=e.exports={__proto__:null,":first-letter":1,":first-line":1,":before":1,":after":1};r.ELEMENT=1,r.CLASS=2,r.isElement=function(e){return 0===e.indexOf("::")||r[e.toLowerCase()]===r.ELEMENT}},function(e,t,n){"use strict";var r=n(131),o=n(458),i=n(132),a=n(206),s=n(459);e.exports={validate:function(e,t){var n,r=e.toString().toLowerCase(),u=new s(t),l=o[r];if(l){if("number"!=typeof l){if(i.isAny(u,"inherit | initial | unset")){if(u.hasNext())throw n=u.next(),new a("Expected end of value but found '"+n+"'.",n.line,n.col);return}this.singleProperty(l,u)}}else if(0!==r.indexOf("-"))throw new a("Unknown property '"+e+"'.",e.line,e.col)},singleProperty:function(e,t){var n,o=t.value;if(!r.parse(e).match(t))throw t.hasNext()&&!t.isFirst()?(n=t.peek(),new a("Expected end of value but found '"+n+"'.",n.line,n.col)):new a("Expected ("+i.describe(e)+") but found '"+o+"'.",o.line,o.col);if(t.hasNext())throw n=t.next(),new a("Expected end of value but found '"+n+"'.",n.line,n.col)}}},function(e,t,n){"use strict";e.exports={__proto__:null,"align-items":"flex-start | flex-end | center | baseline | stretch","align-content":"flex-start | flex-end | center | space-between | space-around | stretch","align-self":"auto | flex-start | flex-end | center | baseline | stretch",all:"initial | inherit | unset","-webkit-align-items":"flex-start | flex-end | center | baseline | stretch","-webkit-align-content":"flex-start | flex-end | center | space-between | space-around | stretch","-webkit-align-self":"auto | flex-start | flex-end | center | baseline | stretch","alignment-adjust":"auto | baseline | before-edge | text-before-edge | middle | central | after-edge | text-after-edge | ideographic | alphabetic | hanging | mathematical | <percentage> | <length>","alignment-baseline":"auto | baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical",animation:1,"animation-delay":"<time>#","animation-direction":"<single-animation-direction>#","animation-duration":"<time>#","animation-fill-mode":"[ none | forwards | backwards | both ]#","animation-iteration-count":"[ <number> | infinite ]#","animation-name":"[ none | <single-animation-name> ]#","animation-play-state":"[ running | paused ]#","animation-timing-function":1,"-moz-animation-delay":"<time>#","-moz-animation-direction":"[ normal | alternate ]#","-moz-animation-duration":"<time>#","-moz-animation-iteration-count":"[ <number> | infinite ]#","-moz-animation-name":"[ none | <single-animation-name> ]#","-moz-animation-play-state":"[ running | paused ]#","-ms-animation-delay":"<time>#","-ms-animation-direction":"[ normal | alternate ]#","-ms-animation-duration":"<time>#","-ms-animation-iteration-count":"[ <number> | infinite ]#","-ms-animation-name":"[ none | <single-animation-name> ]#","-ms-animation-play-state":"[ running | paused ]#","-webkit-animation-delay":"<time>#","-webkit-animation-direction":"[ normal | alternate ]#","-webkit-animation-duration":"<time>#","-webkit-animation-fill-mode":"[ none | forwards | backwards | both ]#","-webkit-animation-iteration-count":"[ <number> | infinite ]#","-webkit-animation-name":"[ none | <single-animation-name> ]#","-webkit-animation-play-state":"[ running | paused ]#","-o-animation-delay":"<time>#","-o-animation-direction":"[ normal | alternate ]#","-o-animation-duration":"<time>#","-o-animation-iteration-count":"[ <number> | infinite ]#","-o-animation-name":"[ none | <single-animation-name> ]#","-o-animation-play-state":"[ running | paused ]#",appearance:"none | auto","-moz-appearance":"none | button | button-arrow-down | button-arrow-next | button-arrow-previous | button-arrow-up | button-bevel | button-focus | caret | checkbox | checkbox-container | checkbox-label | checkmenuitem | dualbutton | groupbox | listbox | listitem | menuarrow | menubar | menucheckbox | menuimage | menuitem | menuitemtext | menulist | menulist-button | menulist-text | menulist-textfield | menupopup | menuradio | menuseparator | meterbar | meterchunk | progressbar | progressbar-vertical | progresschunk | progresschunk-vertical | radio | radio-container | radio-label | radiomenuitem | range | range-thumb | resizer | resizerpanel | scale-horizontal | scalethumbend | scalethumb-horizontal | scalethumbstart | scalethumbtick | scalethumb-vertical | scale-vertical | scrollbarbutton-down | scrollbarbutton-left | scrollbarbutton-right | scrollbarbutton-up | scrollbarthumb-horizontal | scrollbarthumb-vertical | scrollbartrack-horizontal | scrollbartrack-vertical | searchfield | separator | sheet | spinner | spinner-downbutton | spinner-textfield | spinner-upbutton | splitter | statusbar | statusbarpanel | tab | tabpanel | tabpanels | tab-scroll-arrow-back | tab-scroll-arrow-forward | textfield | textfield-multiline | toolbar | toolbarbutton | toolbarbutton-dropdown | toolbargripper | toolbox | tooltip | treeheader | treeheadercell | treeheadersortarrow | treeitem | treeline | treetwisty | treetwistyopen | treeview | -moz-mac-unified-toolbar | -moz-win-borderless-glass | -moz-win-browsertabbar-toolbox | -moz-win-communicationstext | -moz-win-communications-toolbox | -moz-win-exclude-glass | -moz-win-glass | -moz-win-mediatext | -moz-win-media-toolbox | -moz-window-button-box | -moz-window-button-box-maximized | -moz-window-button-close | -moz-window-button-maximize | -moz-window-button-minimize | -moz-window-button-restore | -moz-window-frame-bottom | -moz-window-frame-left | -moz-window-frame-right | -moz-window-titlebar | -moz-window-titlebar-maximized","-ms-appearance":"none | icon | window | desktop | workspace | document | tooltip | dialog | button | push-button | hyperlink | radio | radio-button | checkbox | menu-item | tab | menu | menubar | pull-down-menu | pop-up-menu | list-menu | radio-group | checkbox-group | outline-tree | range | field | combo-box | signature | password | normal","-webkit-appearance":"none | button | button-bevel | caps-lock-indicator | caret | checkbox | default-button | listbox\t| listitem | media-fullscreen-button | media-mute-button | media-play-button | media-seek-back-button\t| media-seek-forward-button\t| media-slider | media-sliderthumb | menulist\t| menulist-button\t| menulist-text\t| menulist-textfield | push-button\t| radio\t| searchfield\t| searchfield-cancel-button\t| searchfield-decoration | searchfield-results-button | searchfield-results-decoration | slider-horizontal | slider-vertical | sliderthumb-horizontal | sliderthumb-vertical\t| square-button\t| textarea\t| textfield\t| scrollbarbutton-down | scrollbarbutton-left | scrollbarbutton-right | scrollbarbutton-up | scrollbargripper-horizontal | scrollbargripper-vertical | scrollbarthumb-horizontal | scrollbarthumb-vertical | scrollbartrack-horizontal | scrollbartrack-vertical","-o-appearance":"none | window | desktop | workspace | document | tooltip | dialog | button | push-button | hyperlink | radio | radio-button | checkbox | menu-item | tab | menu | menubar | pull-down-menu | pop-up-menu | list-menu | radio-group | checkbox-group | outline-tree | range | field | combo-box | signature | password | normal",azimuth:"<azimuth>","backface-visibility":"visible | hidden",background:1,"background-attachment":"<attachment>#","background-clip":"<box>#","background-color":"<color>","background-image":"<bg-image>#","background-origin":"<box>#","background-position":"<bg-position>","background-repeat":"<repeat-style>#","background-size":"<bg-size>#","baseline-shift":"baseline | sub | super | <percentage> | <length>",behavior:1,binding:1,bleed:"<length>","bookmark-label":"<content> | <attr> | <string>","bookmark-level":"none | <integer>","bookmark-state":"open | closed","bookmark-target":"none | <uri> | <attr>",border:"<border-width> || <border-style> || <color>","border-bottom":"<border-width> || <border-style> || <color>","border-bottom-color":"<color>","border-bottom-left-radius":"<x-one-radius>","border-bottom-right-radius":"<x-one-radius>","border-bottom-style":"<border-style>","border-bottom-width":"<border-width>","border-collapse":"collapse | separate","border-color":"<color>{1,4}","border-image":1,"border-image-outset":"[ <length> | <number> ]{1,4}","border-image-repeat":"[ stretch | repeat | round ]{1,2}","border-image-slice":"<border-image-slice>","border-image-source":"<image> | none","border-image-width":"[ <length> | <percentage> | <number> | auto ]{1,4}","border-left":"<border-width> || <border-style> || <color>","border-left-color":"<color>","border-left-style":"<border-style>","border-left-width":"<border-width>","border-radius":"<border-radius>","border-right":"<border-width> || <border-style> || <color>","border-right-color":"<color>","border-right-style":"<border-style>","border-right-width":"<border-width>","border-spacing":"<length>{1,2}","border-style":"<border-style>{1,4}","border-top":"<border-width> || <border-style> || <color>","border-top-color":"<color>","border-top-left-radius":"<x-one-radius>","border-top-right-radius":"<x-one-radius>","border-top-style":"<border-style>","border-top-width":"<border-width>","border-width":"<border-width>{1,4}",bottom:"<margin-width>","-moz-box-align":"start | end | center | baseline | stretch","-moz-box-decoration-break":"slice | clone","-moz-box-direction":"normal | reverse","-moz-box-flex":"<number>","-moz-box-flex-group":"<integer>","-moz-box-lines":"single | multiple","-moz-box-ordinal-group":"<integer>","-moz-box-orient":"horizontal | vertical | inline-axis | block-axis","-moz-box-pack":"start | end | center | justify","-o-box-decoration-break":"slice | clone","-webkit-box-align":"start | end | center | baseline | stretch","-webkit-box-decoration-break":"slice | clone","-webkit-box-direction":"normal | reverse","-webkit-box-flex":"<number>","-webkit-box-flex-group":"<integer>","-webkit-box-lines":"single | multiple","-webkit-box-ordinal-group":"<integer>","-webkit-box-orient":"horizontal | vertical | inline-axis | block-axis","-webkit-box-pack":"start | end | center | justify","box-decoration-break":"slice | clone","box-shadow":"<box-shadow>","box-sizing":"content-box | border-box","break-after":"auto | always | avoid | left | right | page | column | avoid-page | avoid-column","break-before":"auto | always | avoid | left | right | page | column | avoid-page | avoid-column","break-inside":"auto | avoid | avoid-page | avoid-column","caption-side":"top | bottom",clear:"none | right | left | both",clip:"<shape> | auto","-webkit-clip-path":"<clip-source> | <clip-path> | none","clip-path":"<clip-source> | <clip-path> | none","clip-rule":"nonzero | evenodd",color:"<color>","color-interpolation":"auto | sRGB | linearRGB","color-interpolation-filters":"auto | sRGB | linearRGB","color-profile":1,"color-rendering":"auto | optimizeSpeed | optimizeQuality","column-count":"<integer> | auto","column-fill":"auto | balance","column-gap":"<length> | normal","column-rule":"<border-width> || <border-style> || <color>","column-rule-color":"<color>","column-rule-style":"<border-style>","column-rule-width":"<border-width>","column-span":"none | all","column-width":"<length> | auto",columns:1,content:1,"counter-increment":1,"counter-reset":1,crop:"<shape> | auto",cue:"cue-after | cue-before","cue-after":1,"cue-before":1,cursor:1,direction:"ltr | rtl",display:"inline | block | list-item | inline-block | table | inline-table | table-row-group | table-header-group | table-footer-group | table-row | table-column-group | table-column | table-cell | table-caption | grid | inline-grid | run-in | ruby | ruby-base | ruby-text | ruby-base-container | ruby-text-container | contents | none | -moz-box | -moz-inline-block | -moz-inline-box | -moz-inline-grid | -moz-inline-stack | -moz-inline-table | -moz-grid | -moz-grid-group | -moz-grid-line | -moz-groupbox | -moz-deck | -moz-popup | -moz-stack | -moz-marker | -webkit-box | -webkit-inline-box | -ms-flexbox | -ms-inline-flexbox | flex | -webkit-flex | inline-flex | -webkit-inline-flex","dominant-baseline":"auto | use-script | no-change | reset-size | ideographic | alphabetic | hanging | mathematical | central | middle | text-after-edge | text-before-edge","drop-initial-after-adjust":"central | middle | after-edge | text-after-edge | ideographic | alphabetic | mathematical | <percentage> | <length>","drop-initial-after-align":"baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical","drop-initial-before-adjust":"before-edge | text-before-edge | central | middle | hanging | mathematical | <percentage> | <length>","drop-initial-before-align":"caps-height | baseline | use-script | before-edge | text-before-edge | after-edge | text-after-edge | central | middle | ideographic | alphabetic | hanging | mathematical","drop-initial-size":"auto | line | <length> | <percentage>","drop-initial-value":"<integer>",elevation:"<angle> | below | level | above | higher | lower","empty-cells":"show | hide","enable-background":1,fill:"<paint>","fill-opacity":"<opacity-value>","fill-rule":"nonzero | evenodd",filter:"<filter-function-list> | none",fit:"fill | hidden | meet | slice","fit-position":1,flex:"<flex>","flex-basis":"<width>","flex-direction":"row | row-reverse | column | column-reverse","flex-flow":"<flex-direction> || <flex-wrap>","flex-grow":"<number>","flex-shrink":"<number>","flex-wrap":"nowrap | wrap | wrap-reverse","-webkit-flex":"<flex>","-webkit-flex-basis":"<width>","-webkit-flex-direction":"row | row-reverse | column | column-reverse","-webkit-flex-flow":"<flex-direction> || <flex-wrap>","-webkit-flex-grow":"<number>","-webkit-flex-shrink":"<number>","-webkit-flex-wrap":"nowrap | wrap | wrap-reverse","-ms-flex":"<flex>","-ms-flex-align":"start | end | center | stretch | baseline","-ms-flex-direction":"row | row-reverse | column | column-reverse","-ms-flex-order":"<number>","-ms-flex-pack":"start | end | center | justify","-ms-flex-wrap":"nowrap | wrap | wrap-reverse",float:"left | right | none","float-offset":1,"flood-color":1,"flood-opacity":"<opacity-value>",font:"<font-shorthand> | caption | icon | menu | message-box | small-caption | status-bar","font-family":"<font-family>","font-feature-settings":"<feature-tag-value> | normal","font-kerning":"auto | normal | none","font-size":"<font-size>","font-size-adjust":"<number> | none","font-stretch":"<font-stretch>","font-style":"<font-style>","font-variant":"<font-variant> | normal | none","font-variant-alternates":"<font-variant-alternates> | normal","font-variant-caps":"<font-variant-caps> | normal","font-variant-east-asian":"<font-variant-east-asian> | normal","font-variant-ligatures":"<font-variant-ligatures> | normal | none","font-variant-numeric":"<font-variant-numeric> | normal","font-variant-position":"normal | sub | super","font-weight":"<font-weight>","glyph-orientation-horizontal":"<glyph-angle>","glyph-orientation-vertical":"auto | <glyph-angle>",grid:1,"grid-area":1,"grid-auto-columns":1,"grid-auto-flow":1,"grid-auto-position":1,"grid-auto-rows":1,"grid-cell-stacking":"columns | rows | layer","grid-column":1,"grid-columns":1,"grid-column-align":"start | end | center | stretch","grid-column-sizing":1,"grid-column-start":1,"grid-column-end":1,"grid-column-span":"<integer>","grid-flow":"none | rows | columns","grid-layer":"<integer>","grid-row":1,"grid-rows":1,"grid-row-align":"start | end | center | stretch","grid-row-start":1,"grid-row-end":1,"grid-row-span":"<integer>","grid-row-sizing":1,"grid-template":1,"grid-template-areas":1,"grid-template-columns":1,"grid-template-rows":1,"hanging-punctuation":1,height:"<margin-width> | <content-sizing>","hyphenate-after":"<integer> | auto","hyphenate-before":"<integer> | auto","hyphenate-character":"<string> | auto","hyphenate-lines":"no-limit | <integer>","hyphenate-resource":1,hyphens:"none | manual | auto",icon:1,"image-orientation":"angle | auto","image-rendering":"auto | optimizeSpeed | optimizeQuality","image-resolution":1,"ime-mode":"auto | normal | active | inactive | disabled","inline-box-align":"last | <integer>","justify-content":"flex-start | flex-end | center | space-between | space-around","-webkit-justify-content":"flex-start | flex-end | center | space-between | space-around",kerning:"auto | <length>",left:"<margin-width>","letter-spacing":"<length> | normal","line-height":"<line-height>","line-break":"auto | loose | normal | strict","line-stacking":1,"line-stacking-ruby":"exclude-ruby | include-ruby","line-stacking-shift":"consider-shifts | disregard-shifts","line-stacking-strategy":"inline-line-height | block-line-height | max-height | grid-height","list-style":1,"list-style-image":"<uri> | none","list-style-position":"inside | outside","list-style-type":"disc | circle | square | decimal | decimal-leading-zero | lower-roman | upper-roman | lower-greek | lower-latin | upper-latin | armenian | georgian | lower-alpha | upper-alpha | none",margin:"<margin-width>{1,4}","margin-bottom":"<margin-width>","margin-left":"<margin-width>","margin-right":"<margin-width>","margin-top":"<margin-width>",mark:1,"mark-after":1,"mark-before":1,marker:1,"marker-end":1,"marker-mid":1,"marker-start":1,marks:1,"marquee-direction":1,"marquee-play-count":1,"marquee-speed":1,"marquee-style":1,mask:1,"max-height":"<length> | <percentage> | <content-sizing> | none","max-width":"<length> | <percentage> | <content-sizing> | none","min-height":"<length> | <percentage> | <content-sizing> | contain-floats | -moz-contain-floats | -webkit-contain-floats","min-width":"<length> | <percentage> | <content-sizing> | contain-floats | -moz-contain-floats | -webkit-contain-floats","move-to":1,"nav-down":1,"nav-index":1,"nav-left":1,"nav-right":1,"nav-up":1,"object-fit":"fill | contain | cover | none | scale-down","object-position":"<position>",opacity:"<opacity-value>",order:"<integer>","-webkit-order":"<integer>",orphans:"<integer>",outline:1,"outline-color":"<color> | invert","outline-offset":1,"outline-style":"<border-style>","outline-width":"<border-width>",overflow:"visible | hidden | scroll | auto","overflow-style":1,"overflow-wrap":"normal | break-word","overflow-x":1,"overflow-y":1,padding:"<padding-width>{1,4}","padding-bottom":"<padding-width>","padding-left":"<padding-width>","padding-right":"<padding-width>","padding-top":"<padding-width>",page:1,"page-break-after":"auto | always | avoid | left | right","page-break-before":"auto | always | avoid | left | right","page-break-inside":"auto | avoid","page-policy":1,pause:1,"pause-after":1,"pause-before":1,perspective:1,"perspective-origin":1,phonemes:1,pitch:1,"pitch-range":1,"play-during":1,"pointer-events":"auto | none | visiblePainted | visibleFill | visibleStroke | visible | painted | fill | stroke | all",position:"static | relative | absolute | fixed","presentation-level":1,"punctuation-trim":1,quotes:1,"rendering-intent":1,resize:1,rest:1,"rest-after":1,"rest-before":1,richness:1,right:"<margin-width>",rotation:1,"rotation-point":1,"ruby-align":1,"ruby-overhang":1,"ruby-position":1,"ruby-span":1,"shape-rendering":"auto | optimizeSpeed | crispEdges | geometricPrecision",size:1,speak:"normal | none | spell-out","speak-header":"once | always","speak-numeral":"digits | continuous","speak-punctuation":"code | none","speech-rate":1,src:1,"stop-color":1,"stop-opacity":"<opacity-value>",stress:1,"string-set":1,stroke:"<paint>","stroke-dasharray":"none | <dasharray>","stroke-dashoffset":"<percentage> | <length>","stroke-linecap":"butt | round | square","stroke-linejoin":"miter | round | bevel","stroke-miterlimit":"<miterlimit>","stroke-opacity":"<opacity-value>","stroke-width":"<percentage> | <length>","table-layout":"auto | fixed","tab-size":"<integer> | <length>",target:1,"target-name":1,"target-new":1,"target-position":1,"text-align":"left | right | center | justify | match-parent | start | end","text-align-last":1,"text-anchor":"start | middle | end","text-decoration":"<text-decoration-line> || <text-decoration-style> || <text-decoration-color>","text-decoration-color":"<text-decoration-color>","text-decoration-line":"<text-decoration-line>","text-decoration-style":"<text-decoration-style>","text-emphasis":1,"text-height":1,"text-indent":"<length> | <percentage>","text-justify":"auto | none | inter-word | inter-ideograph | inter-cluster | distribute | kashida","text-outline":1,"text-overflow":1,"text-rendering":"auto | optimizeSpeed | optimizeLegibility | geometricPrecision","text-shadow":1,"text-transform":"capitalize | uppercase | lowercase | none","text-wrap":"normal | none | avoid",top:"<margin-width>","-ms-touch-action":"auto | none | pan-x | pan-y | pan-left | pan-right | pan-up | pan-down | manipulation","touch-action":"auto | none | pan-x | pan-y | pan-left | pan-right | pan-up | pan-down | manipulation",transform:1,"transform-origin":1,"transform-style":1,transition:1,"transition-delay":1,"transition-duration":1,"transition-property":1,"transition-timing-function":1,"unicode-bidi":"normal | embed | isolate | bidi-override | isolate-override | plaintext","user-modify":"read-only | read-write | write-only","user-select":"none | text | toggle | element | elements | all","vertical-align":"auto | use-script | baseline | sub | super | top | text-top | central | middle | bottom | text-bottom | <percentage> | <length>",visibility:"visible | hidden | collapse","voice-balance":1,"voice-duration":1,"voice-family":1,"voice-pitch":1,"voice-pitch-range":1,"voice-rate":1,"voice-stress":1,"voice-volume":1,volume:1,"white-space":"normal | pre | nowrap | pre-wrap | pre-line | -pre-wrap | -o-pre-wrap | -moz-pre-wrap | -hp-pre-wrap","white-space-collapse":1,widows:"<integer>",width:"<length> | <percentage> | <content-sizing> | auto","will-change":"<will-change>","word-break":"normal | keep-all | break-all","word-spacing":"<length> | normal","word-wrap":"normal | break-word","writing-mode":"horizontal-tb | vertical-rl | vertical-lr | lr-tb | rl-tb | tb-rl | bt-rl | tb-lr | bt-lr | lr-bt | rl-bt | lr | rl | tb","z-index":"<integer> | auto",zoom:"<number> | <percentage> | normal"}},function(e,t,n){"use strict";function r(e){this._i=0,this._parts=e.parts,this._marks=[],this.value=e}e.exports=r,r.prototype.count=function(){return this._parts.length},r.prototype.isFirst=function(){return 0===this._i},r.prototype.hasNext=function(){return this._i<this._parts.length},r.prototype.mark=function(){this._marks.push(this._i)},r.prototype.peek=function(e){return this.hasNext()?this._parts[this._i+(e||0)]:null},r.prototype.next=function(){return this.hasNext()?this._parts[this._i++]:null},r.prototype.previous=function(){return this._i>0?this._parts[--this._i]:null},r.prototype.restore=function(){this._marks.length&&(this._i=this._marks.pop())},r.prototype.drop=function(){this._marks.pop()}},function(e,t,n){"use strict";e.exports={StringReader:n(130),SyntaxError:n(87),SyntaxUnit:n(30),EventTarget:n(196),TokenStreamBase:n(205)}},function(e,t,n){"use strict";n.r(t);var r={};n.r(r),n.d(r,"closePortability",(function(){return Hr})),n.d(r,"downloadSnippetContent",(function(){return Gr})),n.d(r,"exportSnippet",(function(){return Ur})),n.d(r,"getExportedItem",(function(){return Pr})),n.d(r,"importSnippet",(function(){return Yr})),n.d(r,"insertSnippet",(function(){return Ar})),n.d(r,"loadItems",(function(){return Lr})),n.d(r,"openPortablity",(function(){return Br})),n.d(r,"resetSnippetCode",(function(){return zr})),n.d(r,"setLibraryContext",(function(){return Tr})),n.d(r,"setShowLibrary",(function(){return Nr})),n.d(r,"setShowSaveModal",(function(){return Fr})),n.d(r,"toggleLibraryItemLocation",(function(){return Rr})),n.d(r,"updateItem",(function(){return Ir})),n.d(r,"updateLocalFilters",(function(){return Dr})),n.d(r,"closeModal",(function(){return $r})),n.d(r,"setCloudToken",(function(){return jr})),n.d(r,"cacheCloudToken",(function(){return Mr}));var o={};n.r(o),n.d(o,"openEditModal",(function(){return Xr})),n.d(o,"closeEditModal",(function(){return Qr})),n.d(o,"saveEditedContent",(function(){return to}));var i={};n.r(i),n.d(i,"codeSnippetsLibApi",(function(){return ao}));var a={};n.r(a),n.d(a,"isEditItemModalOpen",(function(){return so}));var s=n(0),u=n.n(s),l=n(47),c=n(18),f=n.n(c),d=n(2),p=n(42),h=n(8),v=n(27),g=n.n(v),m=n(3),y=n.n(m),b=(n(12),n(46)),w=n(43),_=n(5);function x(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var k="http://cerebraljs.com/docs/api/factories.html#when";var C=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t.length>1?t[t.length-1]:null,o=t.length>1?t.slice(0,-1):t;function i(e){var t=e.path,n=e.props,i=e.resolve;if(o.length>0&&!(o[0]instanceof w.Tag))throw new Error("Cerebral factory.when: You have to use the STATE, MODULESTATE or PROPS tag as values, see: "+k);if(!t||!t.true||!t.false)throw new Error("Cerebral factory.when: true/false paths need to be provided, see: http://cerebraljs.com/docs/api/factories.html#when");var a=o.map((function(e){var t=i.value(e);return Object(_.t)(t)?t.getValue(n):t}));return Boolean(r?r.apply(void 0,x(a)):a[0])?t.true():t.false()}return i.displayName="factory.when("+t.filter((function(e){return"function"!=typeof e})).map((function(e){return String(e)})).join(",")+")",i};var O,E,S,T,j=n(20),M=function(e,t,n){function r(r){var o=r.store,i=r.props,a=r.resolve;if(!a.isTag(e,"state","props","moduleState"))throw new Error("Cerebral factory.set: You have to use the STATE, PROPS or MODULESTATE tag as first argument");var s=a.value(t);if(s&&s instanceof j.a&&(s=s.getValue(i)),!a.isResolveValue(t)&&Object(_.v)(t)?s=Object.assign({},s):!a.isResolveValue(t)&&Array.isArray(t)&&(s=s.slice()),n&&(s=n(s,r)),"state"!==e.type&&"moduleState"!==e.type){var u=Object.assign({},i),l=a.path(e).split("."),c=l.pop();return l.reduce((function(e,t){return e[t]=Object.assign({},e[t]||{})}),u)[c]=s,u}o.set(e,s)}return r.displayName="factory.set("+String(e)+", "+String(t)+")",r},L=n(6),A=null===(S=window)||void 0===S||null===(T=S.et_common_data)||void 0===T?void 0:T.config,P=n(19),R=n.n(P),D=function(e,t){for(var n=R()(e,t,""),r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];if(o.length>0){var a=R()(window,"wp.i18n.sprintf");return a?a.apply(void 0,[n].concat(o)):n.replace("%s",o[0])}return n},I=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return D.apply(void 0,[window.et_common_data.i18n,[e,t]].concat(r))},N=n(16),z=n.n(N),F=n(63),B=n.n(F),H=n(44),U=n.n(H),W=function(){var e=B()(U.a.mark((function e(t,n){var r,o,i=arguments;return U.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=i.length>2&&void 0!==i[2]?i[2]:{},e.prev=1,e.next=4,jQuery.ajax(z()({type:t,url:A.api,dataType:"json",data:n},r));case 4:if(!1!==(o=e.sent).success){e.next=7;break}return e.abrupt("return",Promise.reject(o.data||{}));case 7:if(!0!==o.success){e.next=9;break}return e.abrupt("return",Promise.resolve(o.data));case 9:e.next=14;break;case 11:return e.prev=11,e.t0=e.catch(1),e.abrupt("return",Promise.reject(e.t0));case 14:return e.abrupt("return",o);case 15:case"end":return e.stop()}}),e,null,[[1,11]])})));return function(t,n){return e.apply(this,arguments)}}(),V=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return W("POST",e,t)},q=function(e){var t;switch(e){case"code_html":t="et_code_snippet_html_js";break;case"code_css_no_selector":t="et_code_snippet_css_no_selector";break;default:t="et_code_snippet_css"}return t},Y=function(e,t,n){var r=[];return Object(L.forEach)(e,(function(e){n?r.push(t[e]):r.push(e)})),r},G=function(e){return V({action:"et_theme_builder_api_get_terms",nonce:A.nonces.et_theme_builder_api_get_terms,tax:e})},$=n(135),K=n.n($),Z=n(4),X=n(9),Q=n.n(X);function J(e){this.message=e}J.prototype=new Error,J.prototype.name="InvalidCharacterError";var ee="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new J("'atob' failed: The string to be decoded is not correctly encoded.");for(var n,r,o=0,i=0,a="";r=t.charAt(i++);~r&&(n=o%4?64*n+r:r,o++%4)?a+=String.fromCharCode(255&n>>(-2*o&6)):0)r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(r);return a};function te(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(e){return decodeURIComponent(ee(e).replace(/(.)/g,(function(e,t){var n=t.charCodeAt(0).toString(16).toUpperCase();return n.length<2&&(n="0"+n),"%"+n})))}(t)}catch(e){return ee(t)}}function ne(e){this.message=e}ne.prototype=new Error,ne.prototype.name="InvalidTokenError";var re=function(e,t){if("string"!=typeof e)throw new ne("Invalid token specified");var n=!0===(t=t||{}).header?0:1;try{return JSON.parse(te(e.split(".")[n]))}catch(e){throw new ne("Invalid token specified: "+e.message)}},oe=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function ie(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function ae(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}function se(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var ue=function(){function e(t){se(this,e),this.type=t,"string"==typeof(arguments.length<=1?void 0:arguments[1])?(this.name=arguments.length<=1?void 0:arguments[1],this.items=arguments.length<=2?void 0:arguments[2]):(this.name=null,this.items=arguments.length<=1?void 0:arguments[1]),Array.isArray(this.items)||(this.items=[this.items])}return oe(e,[{key:"toJSON",value:function(){return{name:this.name,_functionTreePrimitive:!0,type:this.type,items:this.items}}}]),e}(),le=function(e){function t(){var e;se(this,t);for(var n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];return ie(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this,"sequence"].concat(r)))}return ae(t,e),t}(ue),ce=function(e){function t(){var e;se(this,t);for(var n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];return ie(this,(e=t.__proto__||Object.getPrototypeOf(t)).call.apply(e,[this,"parallel"].concat(r)))}return ae(t,e),t}(ue),fe=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function de(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function pe(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function he(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var ve=function(e){function t(e){de(this,t);var n=pe(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e.message||e));return n.name="FunctionTreeError",n}return he(t,e),fe(t,[{key:"toJSON",value:function(){return{name:this.name,message:this.message,stack:this.stack}}}]),t}(function(e){function t(){var t=Reflect.construct(e,Array.from(arguments));return Object.setPrototypeOf(t,Object.getPrototypeOf(this)),t}return t.prototype=Object.create(e.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e,t}(Error)),ge=function(e){function t(e,n,r,o){de(this,t);var i=pe(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,o));return i.name="FunctionTreeExecutionError",i.execution=e,i.funcDetails=n,i.payload=r,i}return he(t,e),fe(t,[{key:"toJSON",value:function(){return{name:this.name,message:this.message,execution:{name:this.execution.name},funcDetails:{name:this.funcDetails.name,functionIndex:this.funcDetails.functionIndex},payload:this.payload,stack:this.stack}}}]),t}(ve),me="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};function ye(e){if(e.displayName)return e.displayName;if(e.name)return e.name;var t=e.toString(),n=void 0;return 0===t.indexOf("async function")?n="async function ":0===t.indexOf("function")&&(n="function "),t=(t=t.substr(n?n.length:0)).substr(0,t.indexOf("("))}function be(e){return e&&!Array.isArray(e)&&"object"===(void 0===e?"undefined":me(e))&&!(e instanceof ue)}function we(e,t,n,r){if(n instanceof ue){var o=n.toJSON();return Object.assign(o,{items:we(e,t,o.items,n instanceof ce).items})}if(Array.isArray(n))return new le(n.reduce((function(r,o,i){if(o instanceof ue){var a=o.toJSON();return r.concat(Object.assign(a,{items:we(e,t,a.items,o instanceof ce).items}))}if("function"==typeof o){var s={name:o.displayName||ye(o),functionIndex:t.push(o)-1,function:o},u=n[i+1];return be(u)&&(s.outputs={},Object.keys(u).forEach((function(n){if(o.outputs&&!~o.outputs.indexOf(n))throw new ve("Outputs object doesn't match list of possible outputs defined for function.");s.outputs[n]=we(e,t,"function"==typeof u[n]?[u[n]]:u[n])}))),r.concat(s)}if(be(o))return r;if(Array.isArray(o)){var l=we(e,t,o);return r.concat(l)}throw new ve('Unexpected entry in "'+e+'". '+function(e,t){return"\n[\n"+e.map((function(e){return e===t?" "+(void 0===t?"undefined":me(t))+", <-- PROBLEM":"function"==typeof e?" "+ye(e)+",":e instanceof ue?" [ "+e.type.toUpperCase()+" ],":Array.isArray(e)?" [ SEQUENCE ],":" { PATHS },"})).join("\n")+"\n]\n "}(n,o))}),[])).toJSON();throw new ve("Unexpected entry in tree")}var _e=function(e,t){return we(e,[],"function"==typeof t?[t]:t)},xe=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var ke=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.path=t,this.payload=n}return xe(e,[{key:"toJSON",value:function(){return{path:this.path,payload:this.payload,_functionTreePath:!0}}}]),e}(),Ce=n(208),Oe=n.n(Ce);function Ee(e,t){return e._functionTreePrimitive&&e.type===t}function Se(e,t,n,r,o,i,a,s,u){!function t(u,l,c,f,d){n((function(){function n(e){t(u,l+1,e,c,d)}function p(n,o){return function(i){var a=Object.assign({},c,i?i.payload:{});if(i&&n.outputs){var s=Object.keys(n.outputs);if(!~s.indexOf(i.path))throw new ge(e,n,c,"function "+n.name+" must use one of its possible outputs: "+s.join(", ")+".");r(n,i.path,a),t(n.outputs[i.path].items,0,a,c,o)}else o(a)}}var h=u[l];if(h)if(Ee(h,"sequence"))t(h.items,0,c,f,n);else if(Ee(h,"parallel")){var v=h.items.length,g=[];i(c,v),h.items.forEach((function(r,o){return r.function?e.runFunction(r,c,f,p(r,(function(e){g.push(e),g.length===v?(s(e,v),n(Object.assign.apply(Object,[{}].concat(g)))):a(e,v-g.length)}))):t(r.items,0,c,f,(function(e){g.push(e),g.length===v?(s(e,v),n(Object.assign.apply(Object,[{}].concat(g)))):a(e,v-g.length)})),g}))}else e.runFunction(h,c,f,p(h,n));else u!==e.staticTree&&o(c),d(c)}))}([e.staticTree],0,t,null,u)}var Te="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};function je(e){return e&&(e instanceof Promise||"function"==typeof e.then&&"function"==typeof e.catch)}function Me(e){return!(null!==e&&"object"===(void 0===e?"undefined":Te(e))&&!Array.isArray(e)&&e.constructor!==Object)}var Le="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},Ae=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function Pe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var Re=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.wrap,o=void 0===r||r,i=n.ignoreDefinition,a=void 0!==i&&i;Pe(this,e),this.definition=t,"function"!=typeof t&&(a||this.verifyDefinition(t),this.wrap=o,this.ProviderConstructor=function(e){this.context=e},this.ProviderConstructor.prototype=t,this.WrappedProviderConstructor=function(e,t){this.context=t,this.providerName=e},this.WrappedProviderConstructor.prototype=Object.keys(a?{}:t).reduce((function(e,n){var r=t[n];return e[n]=function(){for(var e=this,t=arguments.length,o=Array(t),i=0;i<t;i++)o[i]=arguments[i];var a=r.apply(this,o);return je(a)?a.then((function(t){return e.context.debugger.send({type:"provider",datetime:Date.now(),method:e.providerName+"."+n,args:o,isPromise:!0,isRejected:!1,returnValue:Me(t)?t:"[CAN_NOT_SERIALIZE]"}),t})).catch((function(t){throw e.context.debugger.send({method:e.providerName+"."+n,args:o,isPromise:!0,isRejected:!0}),t})):(this.context.debugger.send({type:"provider",datetime:Date.now(),method:this.providerName+"."+n,args:o,returnValue:Me(a)?a:"[CAN_NOT_SERIALIZE]"}),a)},e}),{}))}return Ae(e,[{key:"verifyDefinition",value:function(e){if(!this.ignoreDefinition){if("object"!==(void 0===e?"undefined":Le(e))||null===e)throw new Error("The definition passed as Provider is not valid");Object.keys(e).forEach((function(t){if("function"!=typeof e[t])throw new Error("The property "+t+" passed to Provider is not a method")}))}}},{key:"get",value:function(e){return"function"==typeof this.definition?this.definition(e):new this.ProviderConstructor(e)}},{key:"getWrapped",value:function(e,t){return"function"==typeof this.definition?this.definition(t):new this.WrappedProviderConstructor(e,t)}}]),e}(),De=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function Ie(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var Ne=function(){function e(){Ie(this,e)}return De(e,[{key:"getValue",value:function(){throw new Error('Extending ResolveValue requires you to add a "getValue" method')}}]),e}();!function(e){function t(e){Ie(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return n.cvalue=e,n}(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)})(t,e),De(t,[{key:"getValue",value:function(e){var t=e.resolve,n=this.cvalue;return t.isResolveValue(n)?t.value(n):Object.keys(n).reduce((function(e,r){return e[r]=t.value(n[r]),e}),{})}}])}(Ne);var ze=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var Fe=function(e){function t(e,n,r,o){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var i=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return i.type=e,i.getter=n,i.strings=r,i.values=o,i}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),ze(t,[{key:"getTags",value:function(){return[this].concat(this.getNestedTags())}},{key:"getPath",value:function(e){var t=this;return this.strings.reduce((function(n,r,o){var i=t.values[o];return i instanceof Ne?n+r+i.getValue(e):n+r+(void 0!==i?i:"")}),"")}},{key:"getValue",value:function(e){return this.getter(this.getPath(e),e)}},{key:"getNestedTags",value:function(){var e=this;return this.strings.reduce((function(n,r,o){var i=e.values[o];return i instanceof t?n.concat(i):n}),[])}},{key:"toString",value:function(){return this.type+"`"+this.pathToString()+"`"}},{key:"pathToString",value:function(){var e=this;return this.strings.reduce((function(n,r,o){var i=e.values[o];return i instanceof t?n+r+"${"+i.toString()+"}":n+r+(void 0!==i?i:"")}),"")}}]),t}(Ne);function Be(e,t){return function(n){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];if(o.some((function(e){return void 0===e})))throw new Error("One of the values passed inside the tag interpolated to undefined. Please check.");return new Fe(e,t,n,o)}}var He=new Re({isTag:function(e){if(!(e instanceof Fe))return!1;for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return!n.length||n.reduce((function(t,n){return t||n===e.type}),!1)},isResolveValue:function(e){return e instanceof Ne},value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e instanceof Ne?e.getValue(t?Object.assign({},this.context,t):this.context):e},path:function(e){if(e instanceof Fe)return e.getPath(this.context);throw new Error("You are extracting a path from an argument that is not a Tag.")}},{wrap:!1}),Ue=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),We="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};function Ve(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function qe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Ye(e){return!e||"object"===(void 0===e?"undefined":We(e))&&!Array.isArray(e)}function Ge(e,t,n,r){var o=e;return o.execution=t,o.functionDetails=n,o.payload=Object.assign({},r,{_execution:{id:t.id,functionIndex:n.functionIndex},error:e.toJSON?e.toJSON():{name:e.name,message:e.message,stack:e.stack}}),o}var $e=function(){function e(t,n,r,o){qe(this,e),this.id=Date.now()+"_"+Math.floor(1e4*Math.random()),this.name=t||n.name||this.id,this.staticTree=n,this.functionTree=r,this.datetime=Date.now(),this.errorCallback=o,this.hasThrown=!1,this.isAsync=!1,this.runFunction=this.runFunction.bind(this)}return Ue(e,[{key:"runFunction",value:function(e,t,n,r){if(!this.hasThrown){var o=this.createContext(e,t,n),i=this.functionTree,a=this.errorCallback,s=this,u=void 0;i.emit("functionStart",s,e,t);try{u=e.function(o)}catch(l){return this.hasThrown=!0,a(Ge(l,s,e,t),s,e,t)}if(je(u))i.emit("asyncFunction",s,e,t,u),this.isAsync=!0,u.then((function(n){if(n instanceof ke)i.emit("functionEnd",s,e,t,n),r(n.toJSON());else{if(e.outputs)throw i.emit("functionEnd",s,e,t,n),new ge(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" needs to be a path of either "+Object.keys(e.outputs)));if(!Ye(n))throw i.emit("functionEnd",s,e,t,n),new ge(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" is not a valid result"));i.emit("functionEnd",s,e,t,n),r({payload:n})}})).catch((function(n){if(!s.hasThrown)if(n instanceof Error)s.hasThrown=!0,a(Ge(n,s,e,t),s,e,t);else if(n instanceof ke)i.emit("functionEnd",s,e,t,n),r(n.toJSON());else if(e.outputs){var o=new ge(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" needs to be a path of either "+Object.keys(e.outputs)));s.hasThrown=!0,a(Ge(o,s,e,t),s,e,t)}else if(Ye(n))i.emit("functionEnd",s,e,t,n),r({payload:n});else{var u=new ge(s,e,t,new Error("The result "+JSON.stringify(n)+" from function "+e.name+" is not a valid result"));s.hasThrown=!0,a(Ge(u,s,e,t),s,e,t)}}));else if(u instanceof ke)i.emit("functionEnd",s,e,t,u),r(u.toJSON());else if(e.outputs){var l=new ge(s,e,t,new Error("The result "+JSON.stringify(u)+" from function "+e.name+" needs to be a path of either "+Object.keys(e.outputs)));this.hasThrown=!0,a(Ge(l,s,e,t),s,e,t)}else if(Ye(u))i.emit("functionEnd",s,e,t,u),r({payload:u});else{var c=new ge(s,e,t,new Error("The result "+JSON.stringify(u)+" from function "+e.name+" is not a valid result"));this.hasThrown=!0,a(Ge(c,s,e,t),s,e,t)}}}},{key:"createContext",value:function(e,t,n){var r=this.functionTree.contextProviders,o={execution:this,props:t||{},functionDetails:e,path:e.outputs?Object.keys(e.outputs).reduce((function(e,t){return e[t]=function(e){return new ke(t,e)},e}),{}):null},i=r.debugger&&r.debugger.get(o,e,t,n),a=Object.keys(r).reduce((function(o,i){var a=r[i];return o[i]=a instanceof Re?a.get(o,e,t,n):a,o}),o);return i?Object.keys(a).reduce((function(t,n){var o=r[n];return o&&o instanceof Re&&o.wrap?t[n]="function"==typeof o.wrap?o.wrap(a,e):o.getWrapped(n,a):t[n]=a[n],t}),{}):a}}]),e}();!function(e){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};qe(this,t);var r=Ve(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));if(r.cachedTrees=[],r.cachedStaticTrees=[],r.executeBranchWrapper=n.executeBranchWrapper||function(e){e()},"object"!==(void 0===e?"undefined":We(e))||null===e||Array.isArray(e))throw new Error("You have to pass an object of context providers to FunctionTree");var o=Object.keys(e);if(o.indexOf("props")>=0||o.indexOf("path")>=0||o.indexOf("resolve")>=0||o.indexOf("execution")>=0||o.indexOf("debugger")>=0)throw new Error('You are trying to add a provider with protected key. "props", "path", "resolve", "execution" and "debugger" are protected');return r.contextProviders=Object.assign({},e,{resolve:He}),r.run=r.run.bind(r),r}(function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)})(t,e),Ue(t,[{key:"run",value:function(){var e=this,t=void 0,n=void 0,r=void 0,o=void 0,i=void 0,a=[].slice.call(arguments);if(a.forEach((function(e){"string"==typeof e?t=e:Array.isArray(e)||e instanceof ue?n=e:n||"function"!=typeof e?"function"==typeof e?o=e:r=e:n=e})),!n)throw new Error("function-tree - You did not pass in a function tree");var s=function(o,a){var s=e.cachedTrees.indexOf(n);-1===s?(i=_e(t,n),e.cachedTrees.push(n),e.cachedStaticTrees.push(i)):i=e.cachedStaticTrees[s];var u=new $e(t,i,e,(function(t,n,r,o){e.emit("error",t,n,r,o),a(t)}));e.emit("start",u,r),Se(u,r,e.executeBranchWrapper,(function(t,n,r){e.emit("pathStart",n,u,t,r)}),(function(t){e.emit("pathEnd",u,t)}),(function(t,n){e.emit("parallelStart",u,t,n)}),(function(t,n){e.emit("parallelProgress",u,t,n)}),(function(t,n){e.emit("parallelEnd",u,t,n)}),(function(t){e.emit("end",u,t),o===a?o(null,t):o(t)}))};if(!o)return new Promise(s);s(o,o)}}])}(Oe.a);var Ke=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();var Ze=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n=e.nextWatchId++;this.id="Watch_"+n,this.rawId=n,this.name=null,this.type=t,this.executedCount=0,this.controller=null,this.modulePath="",this.dependencyMap=null}return Ke(e,[{key:"create",value:function(e,t,n){return this.name=n,this.controller=e,this.modulePath=t,this}},{key:"registerDependencies",value:function(){this.dependencyMap=this.createDependencyMap(),this.controller.dependencyStore.addEntity(this,this.dependencyMap),this.controller.devtools&&(this.controller.devtools.updateWatchMap(this,this.dependencyMap),this.controller.devtools.sendWatchMap([],[],0,0))}},{key:"destroy",value:function(){this.dependencyMap&&(this.controller.dependencyStore.removeEntity(this,this.dependencyMap),this.controller.devtools&&(this.controller.devtools.updateWatchMap(this,null,this.dependencyMap),this.controller.devtools.sendWatchMap([],[],0,0)))}},{key:"toJSON",value:function(){return{id:this.id,executedCount:this.executedCount,type:this.type,name:this.name}}}]),e}();Ze.nextWatchId=0;var Xe=Ze,Qe=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();function Je(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var et=function(){function e(t,n){Je(this,e),this.computed=t,this.propsTags=t.propsTags,this.nestedPath=n}return Qe(e,[{key:"getValue",value:function(e){return this.nestedPath.reduce((function(e,t){return e&&e[t]}),this.computed.getValue(e))}},{key:"getDependencyMap",value:function(){return this.computed.getDependencyMap()}},{key:"clone",value:function(){return this.computed.clone()}},{key:"destroy",value:function(){return this.computed.destroy()}}]),e}(),tt=function(e){function t(e){Je(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,"Compute"));return n.computedCallback=e,n.isDirty=!0,n.value=null,n.props=null,n.getters=null,n.stateTags=[],n.propsTags=[],n.onUpdate=n.onUpdate.bind(n),n.dynamicGetter=n.dynamicGetter.bind(n),n.dynamicGetter.path=n.dynamicPathGetter.bind(n),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),Qe(t,[{key:"createDependencyMap",value:function(){return this.controller.createDependencyMap(this.stateTags,this.props,this.modulePath)}},{key:"getDependencyMap",value:function(){return this.dependencyMap}},{key:"onUpdate",value:function(){this.isDirty=!0}},{key:"clone",value:function(){return new t(this.computedCallback).create(this.controller,this.modulePath,this.name+" (clone)")}},{key:"compute",value:function(){return this.executedCount++,this.computedCallback(this.getDynamicGetter())}},{key:"getDynamicGetter",value:function(){return this.stateTags=[],this.propsTags=[],this.dynamicGetter}},{key:"parseDependencies",value:function(e){var t=this;if(!(e instanceof Fe))throw new Error('Cerebral - Only tags are allowed in the dynamic "get" of Compute');e.getTags().forEach((function(e){"props"===e.type?t.propsTags.push(e):t.stateTags.push(e)}))}},{key:"dynamicGetter",value:function(e){this.parseDependencies(e);var t=e.getValue(this.getters);return it(t)?t.getValue(this.props):t}},{key:"dynamicPathGetter",value:function(e){return e.getPath(this.getters)}},{key:"hasChangedProps",value:function(e){var t=this,n=this.controller.createContext(e);return this.propsTags.reduce((function(e,r){return!!e||r.getValue(t.getters)!==r.getValue(n)}),!1)}},{key:"getValue",value:function(e){if(!this.controller)throw new Error("This Cerebral Compute has not been added to a module");if(!this.isDirty&&this.propsTags.length&&this.hasChangedProps(e)&&(this.isDirty=!0),this.isDirty){this.getters=this.controller.createContext(e),this.props=e,this.value=this.compute();var t=this.dependencyMap;this.dependencyMap=this.createDependencyMap(),this.controller.dependencyStore.updateEntity(this,t,this.dependencyMap),this.controller.devtools&&(this.controller.devtools.updateWatchMap(this,this.dependencyMap,t),this.controller.devtools.updateComputedState(this.name,this.value)),this.isDirty=!1}return this.value}},{key:"toString",value:function(){return this.getValue(this.props)}}]),t}(Xe);"function"==typeof Symbol&&Symbol.iterator;var nt=[];function rt(e,t){-1===nt.indexOf(e)&&(nt.push(e),console.warn(e+" is DEPRECATED - "+t))}function ot(e,t){var n=t.execution.name.split(".");return n.splice(0,n.length-1).concat(e).join(".")}function it(e){return e instanceof tt||e instanceof et}Be("string",(function(e){return e})),Be("path",(function(e){return e})),Be("signal",(function(e,t){return rt("tags.signal",'use the "sequences" tag instead'),t.controller.getSequence(e)})),Be("signals",(function(e,t){return rt("tags.signals",'use the "sequences" tag instead'),t.controller.getSequences(e)})),Be("sequences",(function(e,t){return t.controller.getSequence(e)||t.controller.getSequences(e)}));var at,st,ut,lt=Be("state",(function(e,t){return t.controller.getState(e)})),ct=(Be("module",(function(e,t){return rt("tags.module",'use the "moduleState" tag instead'),t.controller.getState(ot(e,t))})),Be("moduleState",(function(e,t){return t.controller.getState(ot(e,t))})),Be("moduleSequences",(function(e,t){return t.controller.getSequence(ot(e,t))||t.controller.getSequences(ot(e,t))})),Be("props",(function(e,t){return function(e,t){return t.split(".").reduce((function(e,n,r){if(r>0&&void 0===e)throw new Error('Cannot extract value at path "'+t+'" ("'+n+'" is not defined).');return e[n]}),e)}(t.props,e)})),{tags:"tags",categories:"categories",packs:"packs",favoritePacks:"favorites",cloudStatus:"activate",layout:"layouts",section:"sections",row:"rows",module:"modules",tb_template:"templates",tb_set:"template-sets",code_css:"snippets-css",code_css_no_selector:"snippets-css-ns",code_html:"snippets"});function ft(e){return e.filter((function(e,t){var n=e.id,r=e.item_location||"local";return!this.has(t=n+r)&&this.add(t)}),new Set)}function dt(e){try{return re(e)}catch(e){return"invalid-token"}}function pt(e,t){return e.match(/.{1,2}/g).map((function(e){return parseInt(e,16)})).map((function(e){return(n=t,n.split("").map((function(e){return e.charCodeAt(0)}))).reduce((function(e,t){return e^t}),e);var n})).map((function(e){return String.fromCharCode(e)})).join("")}function ht(e){var t=e(lt(at||(at=Q()(["teamSidebar.activeFolder.folder.endpoint"])))),n=e(lt(st||(st=Q()(["teamSidebar.activeFolder.folderType"])))),r="";return n&&"myFolders"!==n&&(r="".concat(t,"/cloud/v1")),r}var vt=n(91),gt=n.n(vt),mt={cache:{},offlineCacheTable:"DiviCloud",offlineCacheVersion:"1.4",cacheKey:"",init:function(e,t){var n=this;window.ETCloudCache=window.ETCloudCache||{},this.cacheKey=e,Object(Z.has)(window.ETCloudCache,e)||Object(Z.set)(window.ETCloudCache,e,{}),this.getOfflineCache("cloud-cache-version").then((function(e){n.offlineCacheVersion!==e&>.a.createInstance({name:n.offlineCacheTable}).clear().then((function(){n.setOfflineCache("cloud-cache-version",n.offlineCacheVersion)}))})),this.cache=window.ETCloudCache[e]},addData:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(n)Object(Z.set)(window.ETCloudCache,e,t);else{var o=r?window.ETCloudCache[r]:this.cache;Object(Z.set)(o,e,t)}},getData:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return n?Object(Z.get)(window.ETCloudCache[n],e,t):Object(Z.get)(this.cache,e,t)},clearData:function(){window.ETCloudCache={},Object(Z.set)(window.ETCloudCache,this.cacheKey,{}),this.cache=window.ETCloudCache[this.cacheKey]},setOfflineCache:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"items",o=gt.a.createInstance({name:this.offlineCacheTable});return n?o.getItem(e).then((function(n){var i=t;return i="array"===r?Object(Z.merge)(n,t):n?ft(Object(Z.concat)(n,t)):t,o.setItem(e,i)})):o.setItem(e,t)},getOfflineCache:function(e){return gt.a.createInstance({name:this.offlineCacheTable}).getItem(e).then((function(e){return e}))}};function yt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"user",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if("predefined"===e)return et_cloud_data.predefined_items_url;var n=dt(t),r="invalid-token"===n?"":Object(Z.get)(n,["aud",[1]],"");return"".concat(r,"/wp-json/cloud/v1")}function bt(e,t,n,r,o,i){var a={},s=Object(Z.get)(i,"providedUrl",null),u=Object(Z.get)(i,"providedBaseUrl","");return Tt({type:"get",resource:e,queryString:"per_page=".concat(r,"&page=").concat(n,"&orderby=id"),source:t,accessToken:o,providedUrl:s,providedBaseUrl:u}).then((function(e){var t=e.data,n=t;return Object(Z.isNil)(t)&&(n=e),Object(Z.isEmpty)(n)||n.error||Object(Z.forEach)(n,(function(e){var t=e.id;a[t]={},a[t].id=t,a[t].name=e.name,a[t].slug=e.slug,a[t].count=e.count,a[t].location="cloud"})),{data:a}}))}function wt(e,t,n,r,o,i){var a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:{},s=[],u=Object(Z.get)(a,"editPermission",!1),l="predefined"!==e&&u?"&status=publish,trash":"",c=Object(Z.get)(a,"providedUrl",null),d=Object(Z.get)(a,"providedBaseUrl",""),p="date",h="asc";switch(o){case"name":p="name";break;case"dateDesc":h="desc"}return Tt({type:"get",resource:t,queryString:"per_page=".concat(r,"&page=").concat(n).concat(l,"&orderBy=").concat(p,"&order=").concat(h),includeHeaders:!0,source:e,accessToken:i,providedUrl:c,providedBaseUrl:d}).then((function(t){return t.error?t:(Object(Z.forEach)(t.body,(function(t){if(t.id){var n={};if(n.id=t.id,n.date=t.date,n.name=f()("<textarea/>").html(Object(Z.get)(t,"title.rendered",t.name)).text(),n.slug=t.slug,n.category_ids=Object(Z.get)(t,"categories",[]),n.tag_ids=Object(Z.get)(t,"tags",[]),n.is_favorite=t.is_favorite||Object(Z.get)(t,"meta.et-api-cloud-favorite",!1),n.item_location="cloud",n.width=Object(Z.isEmpty)(Object(Z.get)(t,"module_width",[]))?"regular":"fullwidth",n.subtype=Object(Z.get)(t,"meta._et_pb_module_type",""),n.row_layout=Object(Z.get)(t,"meta._et_pb_row_layout",""),n.isTrash="trash"===t.status,n.modified=t.modified,t.meta){var r,o=Object(Z.get)(t,"meta.et-api-cloud-template-set-templates",[]);n.thumbnail=Object(Z.get)(t,"meta.et-api-cloud-thumbnails.large",""),n.thumbnail_medium=Object(Z.get)(t,"meta.et-api-cloud-thumbnails.medium",""),n.thumbnail_small=Object(Z.get)(t,"meta.et-api-cloud-thumbnails.small",""),n.item_items=o,n.allThumbnails=Object(Z.isEmpty)(o)?[]:Object(Z.get)(t,"meta.et-api-cloud-thumbnails",[]),n.builtFor=null!==(r=t.meta)&&void 0!==r&&r._built_for&&""!==t.meta._built_for?t.meta._built_for:"Divi"}else n.thumbnail=Object(Z.get)(t,"thumbnail","");"predefined"===e&&t.link&&(n.previewLink=t.link),t.packs&&(n.pack_id=t.packs[0],n.is_landing=Object(Z.endsWith)(t.slug,"-landing-page")||Object(Z.endsWith)(t.slug,"-landing"),n.description=Object(Z.isEmpty)(t.excerpt.rendered)?"":t.excerpt.rendered),s.push(n)}})),{data:{items:Object(Z.compact)(s)},pagesCount:t.totalPages,itemsCount:t.totalItems,cloudCount:t.totalCloudItems})}))}function _t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"layouts",n=e.isUserItems?"userItems":"predefined",r=e.pageNo,o=e.perPage,i=e.token,a=Object(Z.get)(e,"orderBy","date"),s=Object(Z.get)(e,"providedUrl",null),u=Object(Z.get)(e,"providedBaseUrl",""),l=Object(Z.get)(e,"editPermission",!1),c={providedUrl:s,providedBaseUrl:u,editPermission:l};switch(e.type){case"categoriesList":return bt("categories",n,r,o,i,c);case"tagsList":return bt("tags",n,r,o,i,c);case"packsList":return bt("packs",n,r,o,i);case"itemsList":var f="predefined"===n||"layout"===t?"layouts":t;return wt(n,f,r,o,a,i,c)}return new Promise((function(e){return e()}))}function xt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:"",a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:0;return Ot().then((function(s){var u=Object(Z.get)(s,"accessToken","");if(""===u)return r&&r({error:"auth_error"}),new Promise((function(e){return e({error:"auth_error"})}));var l=Object(Z.get)(s,"sharedFolders",[]),c=Object(Z.find)(l,["id",a]);return c&&!i&&(i="".concat(c.endpoint,"/cloud/v1")),kt(u,e,t,n,r,o,i)})).catch((function(e){return r&&r({error:e}),{error:e}}))}function kt(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=arguments.length>4&&void 0!==arguments[4]&&arguments[4],i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"";if(0!==i)return Tt({type:"post",resource:t,resourceId:i,accessToken:e,providedBaseUrl:a},n).then((function(e){return o&&o(e),e}));var s=[];return Object(Z.isEmpty)(r)||Object(Z.forEach)(r,(function(t,n){Object(Z.isEmpty)(t)||Object(Z.forEach)(t,(function(t){s.push(Et(t,n,e,a))}))})),"fullwidth"===n.width&&s.push(Et("fullwidth","module_width",e,a)),Object(Z.isEmpty)(s)?Tt({type:"post",resource:t,accessToken:e,providedBaseUrl:a},n).then((function(t){return o&&o(t,e),t})):Promise.all(s).then((function(r){var i=Object(Z.groupBy)(r,"taxonomy");return Object(Z.forEach)(["categories","tags","module_width"],(function(e){var t=Object(Z.get)(i,[e],[]),r=[];Object(Z.isEmpty)(t)||(r=Object(Z.map)(Object(Z.keys)(Object(Z.keyBy)(t,"id")),Z.toInteger)),n[e]=r})),Tt({type:"post",resource:t,accessToken:e,providedBaseUrl:a},n).then((function(t){return o&&o(t,e),t}))}))}function Ct(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return Ot(e,t)}function Ot(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return mt.getOfflineCache("refreshTokenPart").then((function(n){return new Promise((function(r){f.a.ajax({type:"POST",url:et_cloud_data.ajaxurl,dataType:"json",data:{action:"et_cloud_update_tokens",et_cloud_token_nonce:et_cloud_data.nonces.et_cloud_refresh_token,et_cloud_access_token:e,et_cloud_save_session:t,et_cloud_refresh_token_part:n},complete:function(e){var t=Object(Z.get)(e,"responseJSON.data",{});mt.setOfflineCache("refreshTokenPart",t.refreshTokenPart).then((function(){return r(t)}))}})}))}))}function Et(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"";return new Promise((function(o){return Object(Z.isUndefined)(e)||""===e?o({}):Tt({type:"post",resource:t,accessToken:n,providedBaseUrl:r},{name:e}).then((function(e){if(e.error&&"term_exists"!==e.error)return o({});var n="term_exists"===Object(Z.get)(e,"code","")?e.data.term_id:e.id;o({taxonomy:t,id:n})}))}))}function St(e){return Object(Z.get)(ct,e,e)}function Tt(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.type,r=e.resource,o=e.resourceId,i=e.source,a=e.queryString,s=e.providedUrl,u=e.providedBaseUrl,l=e.etAccount,c=e.accessToken,f=e.includeHeaders,d=s||"",p="predefined"===i&&"cloudStatus"!==r?"".concat(Object(Z.get)(l,"username",""),":").concat(Object(Z.get)(l,"apiKey","")):c,h=("predefined"!==i||"favoritePacks"===r||"layout"===r||"cloudStatus"===r)&&!s;if(!d){var v=u&&""!==u?u:yt(i,p),g=St(r);d="".concat(v,"/").concat(g),o&&(d="".concat(d,"/").concat(o)),a&&(d="".concat(d,"?").concat(a))}var m={method:n,mode:"cors"};Object(Z.isEmpty)(t)||(m.body=JSON.stringify(t));var y=s?{"Content-Type":"application/x-www-form-urlencoded"}:{"Content-Type":"application/json; charset=UTF-8",Accept:"application/json"};if(h){if(!p)return new Promise((function(e){return e({code:"missing_token",error:"Your Divi Cloud session has ended. Please try logging in again. If you continue to experience authorization failures, try closing Library modal and opening it again so that your authorization token can be regenerated."})}));y.Authorization="Bearer ".concat(p),m.credentials="same-origin"}return m.headers=y,tn(d,m,f)}var jt,Mt,Lt,At,Pt,Rt,Dt,It,Nt,zt,Ft,Bt,Ht,Ut,Wt,Vt,qt,Yt,Gt,$t,Kt,Zt,Xt,Qt,Jt,en=function(e){var t=new AbortController;return setTimeout((function(){return t.abort()}),1e3*e),t};function tn(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r="post"===t.method?300:15;return t.signal=en(r).signal,fetch(e,t).then((function(e){if(503===e.status)throw new Error("".concat(e.status," - ").concat(e.statusText));return e.json().then((function(t){return{totalPages:e.headers.get("x-wp-totalpages"),totalItems:e.headers.get("x-wp-total"),totalCloudItems:e.headers.get("X-ET-API-CLOUD-ITEM-COUNT"),body:t}}))})).then((function(e){return Object(Z.get)(e,"body.code")?K()({error:e.body.code},e.body):n?e:e.body})).catch((function(t){return console.log("CLOUD API REQUEST ERROR:",e,t),{error:t}}))}function nn(e,t,n,r){var o=arguments.length>4&&void 0!==arguments[4]&&arguments[4],i=Object(Z.get)(e,"error",""),a=t(lt(jt||(jt=Q()(["app.i18n"])))),s=["missing_token","rest_forbidden_context","401"],u=["rest_post_invalid_page_number"],l=Object(Z.get)(e,"code",i),c=Object(Z.toString)(Object(Z.get)(e,"message",i)),f="silent"===Object(Z.get)(e,"errorType","");if(!(Object(Z.includes)(u,l)||Object(Z.startsWith)("SyntaxError:",i)||Object(Z.includes)(c,"AbortError:")||f)){"wp_die"===l&&(l=Object(Z.toString)(Object(Z.get)(e,"data.status",l)));var d={message:c};if(Object(Z.includes)(s,l)&&""===ht(t)){var p=t(lt(Mt||(Mt=Q()(["lastAutoLogin"])))),h="inProgress"===t(lt(Lt||(Lt=Q()(["accessTokenUpdate"]))));if(h)return;return p?(n.set(lt(At||(At=Q()(["cloudStatus"]))),"off"),mt.setOfflineCache("refreshTokenPart",""),d={title:a["Your Divi Cloud Session Has Ended"],subtitle:a["Please Log In Again"],message:a.$cloudAuthError},void n.set(lt(Pt||(Pt=Q()(["errorMessage"]))),d)):(n.set(lt(Rt||(Rt=Q()(["lastAutoLogin"]))),!0),void rn({get:t,store:n,bridge:r,callback:o}))}if(""===ht(t)&&("max_free_items"===i||"max_paid_bytes"===i)){var v=Object(Z.get)(e,["data",i],50),g=function(){n.set(lt(Dt||(Dt=Q()(["errorMessage"]))),{}),n.set(lt(It||(It=Q()(["app.isCheckoutForm"]))),!0),r.emit("et_cloud_page_changed",[!1,a["Free Divi Cloud Limit Reached"]])},m="max_paid_bytes"===i?a.$cloudPaidLimitExceeded:a.$cloudFreeLimitExceeded,y="max_paid_bytes"===i?a.$cloudUpgradeMessage500:a.$cloudUpgradeMessage.replace("%s",v);d={title:a["Free Divi Cloud Limit Reached"],subtitle:m,message:y,button:{text:a["Get Unlimited Divi Cloud Storage"],action:g}}}n.set(lt(Nt||(Nt=Q()(["errorMessage"]))),d)}}function rn(e){var t=e.get,n=e.store,r=e.bridge,o=e.callback,i=void 0!==o&&o,a=t(lt(zt||(zt=Q()(["activationToken"])))),s=t(lt(Ft||(Ft=Q()(["saveSession"]))));return"inProgress"===t(lt(Bt||(Bt=Q()(["accessTokenUpdate"]))))?new Promise((function(e){return e({enablingStatus:"waiting"})})):(n.set(lt(Ht||(Ht=Q()(["activationToken"]))),""),n.set(lt(Ut||(Ut=Q()(["saveSession"]))),!1),n.set(lt(Wt||(Wt=Q()(["accessTokenUpdate"]))),"inProgress"),Ct(a,s).then((function(e){var o=Object(Z.get)(e,"accessToken",""),a=Object(Z.get)(e,"error"),s=Object(Z.get)(e,"sharedFolders",null);n.set(lt(Vt||(Vt=Q()(["teamSidebar.sharedFolders"]))),s),n.set(lt(qt||(qt=Q()(["accessTokenUpdate"]))),"");var u=function(e){var t=e(lt(ut||(ut=Q()(["teamSidebar.sharedFolders"]))));return Object(Z.some)(t,(function(e){return e.permissions.add}))}(t);return n.set(lt(Yt||(Yt=Q()(["teamSidebar.showPremadeLayoutsCopyModal"]))),u),mt.setOfflineCache("sharedFolders",s),""!==o&&Object(Z.isEmpty)(a)?(n.set(lt(Kt||(Kt=Q()(["cloudToken"]))),e.accessToken),n.set(lt(Zt||(Zt=Q()(["domainToken"]))),e.domainToken),n.set(lt(Xt||(Xt=Q()(["lastAutoLogin"]))),!1),r.emit("et_cloud_token_ready"),i&&i({get:t,store:n}),new Promise((function(e){return e({enablingStatus:"enabled"})}))):(n.set(lt(Gt||(Gt=Q()(["lastAutoLogin"]))),!0),nn(e,t,n,r),n.set(lt($t||($t=Q()(["cloudStatus"]))),"off"),mt.setOfflineCache("refreshTokenPart",""),new Promise((function(e){return e({enablingStatus:"failed"})})))})).catch((function(e){return n.set(lt(Qt||(Qt=Q()(["cloudStatus"]))),"off"),mt.setOfflineCache("refreshTokenPart",""),n.set(lt(Jt||(Jt=Q()(["accessTokenUpdate"]))),""),nn(e,t,n,r),new Promise((function(e){return e({enablingStatus:"failed"})}))})))}var on=n(209),an=n.n(on);window.CodeSnippetItemsLoaded={};var sn,un,ln,cn,fn,dn,pn,hn,vn,gn,mn,yn,bn,wn,_n,xn,kn,Cn,On,En,Sn,Tn,jn,Mn,Ln,An,Pn,Rn,Dn,In,Nn,zn,Fn,Bn,Hn,Un,Wn,Vn,qn,Yn,Gn,$n,Kn,Zn,Xn,Qn,Jn,er,tr,nr,rr,or,ir,ar,sr,ur,lr,cr,fr,dr,pr,hr,vr,gr,mr,yr,br,wr,_r,xr,kr,Cr,Or,Er,Sr=function(e,t){window.CodeSnippetItemsLoaded=g()({},CodeSnippetItemsLoaded,an()({},e,t))},Tr=Object(d.sequence)("Set Code Snippets library context",[M(Object(d.state)(sn||(sn=y()(["context"]))),Object(d.props)(un||(un=y()(["context"])))),M(Object(d.state)(ln||(ln=y()(["itemsLoadedAndCached"]))),!1)]),jr=Object(d.sequence)("Set cloudToken",[function(e){var t,n=e.get;t=n(Object(d.props)(cn||(cn=y()(["cloudToken"])))),window.globalCloudToken=t}]),Mr=Object(d.sequence)("Retrieve saved Cloud Access token and save to state",[function(e){var t=e.codeSnippetsLibApi,n=e.path;return t.getCloudToken().then((function(e){return n.success({cloudToken:e.accessToken})})).catch((function(){return n.error()}))},{success:[jr],error:[]}]),Lr=Object(d.sequence)("Load Code Snippets library items",[function(e){var t=e.codeSnippetsLibApi,n=e.get,r=e.path,o=n(Object(d.state)(fn||(fn=y()(["context"])))),i=q(o);return""===o?r.error():t.getItems(i).then((function(e){return r.success({items:e})})).catch((function(){return r.error()}))},{success:[M(Object(d.state)(dn||(dn=y()(["items"]))),Object(d.props)(pn||(pn=y()(["items"])))),M(Object(d.state)(hn||(hn=y()(["itemsLoadedAndCached"]))),!0),function(e){var t=e.get;Sr(t(Object(d.state)(vn||(vn=y()(["context"])))),!0)}],error:[]}]),Ar=Object(d.sequence)("Insert Code Snippet into a field",[function(e){var t=e.codeSnippetsLibApi,n=e.get,r=e.path,o=n(Object(d.props)(gn||(gn=y()(["snippetId"])))),i=n(Object(d.props)(mn||(mn=y()(["snippetContent"])))),a=n(Object(d.state)(yn||(yn=y()(["context"])))),s=q(a);return!1!==i?r.success({snippet:i}):t.getItemContent(o,s).then((function(e){return r.success({snippet:e.snippet})})).catch((function(){return r.error()}))},{success:[M(Object(d.state)(bn||(bn=y()(["snippetCode"]))),Object(d.props)(wn||(wn=y()(["snippet"])))),M(Object(d.state)(_n||(_n=y()(["snippetCodeAppend"]))),Object(d.props)(xn||(xn=y()(["isAppend"])))),function(e){e.get;var t=e.props,n=t.snippet,r=t.codeMirrorId,o=t.isAppend;if(t.skipInsert)return Promise.resolve();var i=jQuery("#".concat(r)).next(".CodeMirror")[0].CodeMirror;return o?(n=i.getValue()?"\n"+n:n,Promise.resolve(i.replaceRange(n,{line:i.lastLine()}))):Promise.resolve(i.setValue(n))},M(Object(d.state)(kn||(kn=y()(["showLibrary"]))),!1),M(Object(d.state)(Cn||(Cn=y()(["context"]))),""),function(){jQuery(window).trigger("et_code_snippets_library_close")}],error:[]}]),Pr=Object(d.sequence)("Get the exported Code Snippet content",[function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props,o=r.id,i=r.itemType;return t.getItemContent(o,i,"exported").then((function(e){return n.success(e)})).catch((function(){return n.error()}))},{success:[Promise.resolve(Object(d.props)(On||(On=y()(["response"]))))],error:[]}]),Rr=Object(d.sequence)("Remove local item from WPDB",[function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props.id;return t.removeLocalItem(r).then((function(e){return n.success(e)})).catch((function(){return n.error()}))},{success:[Promise.resolve(Object(d.props)(En||(En=y()(["response"]))))],error:[]}]),Dr=Object(d.sequence)("Update Local Filters",[function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props.payload;return t.updateFilters(r).then((function(e){return n.success(e)})).catch((function(){return n.error()}))},{success:[Promise.resolve(Object(d.props)(Sn||(Sn=y()(["response"]))))],error:[]}]),Ir=Object(d.sequence)("Update Code Snippets library item",[function(e){var t=e.codeSnippetsLibApi,n=e.get,r=e.path,o=n(Object(d.props)(Tn||(Tn=y()(["payload"]))));return t.updateItem(o).then((function(e){return r.success({updatedItem:{success:!0,data:e}})})).catch((function(){return r.error()}))},{success:[Promise.resolve(Object(d.props)(jn||(jn=y()(["updatedItem"]))))],error:[]}]),Nr=Object(d.sequence)("Set Code Snippets show library",[M(Object(d.state)(Mn||(Mn=y()(["showLibrary"]))),Object(d.props)(Ln||(Ln=y()(["toggle"]))))]),zr=Object(d.sequence)("Reset the saved code value",[M(Object(d.state)(An||(An=y()(["snippetCode"]))),"")]),Fr=Object(d.sequence)("Toggle Code Snippets save modal",[M(Object(d.state)(Pn||(Pn=y()(["showSave"]))),Object(d.props)(Rn||(Rn=y()(["toggle"]))))]),Br=Object(d.sequence)("Open Code Snippets portability modal",[M(Object(d.state)(Dn||(Dn=y()(["showPortability"]))),!0)]),Hr=Object(d.sequence)("Close Code Snippets portability modal",[M(Object(d.state)(In||(In=y()(["showPortability"]))),!1),M(Object(d.state)(Nn||(Nn=y()(["importError"]))),!1)]),Ur=Object(d.sequence)("Export code snippet",[function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props,o=r.id,i=r.cloudContent,a=r.directExport;return t.exportItem(o,i,a).then((function(){return n.success()})).catch((function(){return n.error()}))},{success:[function(e){var t=e.codeSnippetsLibApi,n=e.props,r=n.id,o=n.fileName,i=t.downloadExportFile(r,o);window.location.assign(i),window.ETCloudApp.emitSignal({signal:"finishDownload",data:{}})},function(e){var t=e.props.directExport;Object(h.isEmpty)(t)||jQuery(window).trigger("et_code_snippets_library_close")},Hr],error:[]}]),Wr=Object(d.sequence)("Import code snippet to cloud",[function(e){var t=e.get,n=e.store,r=e.props.importFile;return Ot().then((function(e){var o=e.accessToken;if(Object(h.isEmpty)(o))M(Object(d.state)(Un||(Un=y()(["importState"]))),"idle"),n.set(Object(d.state)(Wn||(Wn=y()(["cloudStatus"]))),{error:"auth_error"});else{n.set(Object(d.state)(Hn||(Hn=y()(["cloudToken"]))),o);var i={title:r.title,content:r.content,status:"publish",meta:{}};Tt({type:"post",resource:function(e){var t;switch(e){case"et_code_snippet_html_js":t="code_html";break;case"et_code_snippet_css":t="code_css";break;case"et_code_snippet_css_no_selector":t="code_css_no_selector"}return t}(r.type),accessToken:o,providedBaseUrl:window.ETCloudApp.getActiveFolderEndpoint()},i).then((function(e){e.error?nn(e,t,n,null):(n.set(Object(d.state)(zn||(zn=y()(["showPortability"]))),!1),n.set(Object(d.state)(Fn||(Fn=y()(["importError"]))),!1),n.set(Object(d.state)(Bn||(Bn=y()(["importState"]))),"success"),window.ETCloudApp.emitSignal({signal:"refreshCloudItems",data:{}}))}))}}))}]),Vr=Object(d.sequence)("Import code snippet to local",[function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props.importFile;return t.importItem(r).then((function(){return n.success()})).catch((function(){return n.error()}))},{success:[Hr,M(Object(d.state)(Vn||(Vn=y()(["importState"]))),"success"),function(){jQuery(window).trigger("et_cloud_refresh_local_items")}],error:[M(Object(d.state)(qn||(qn=y()(["importState"]))),"idle"),M(Object(d.state)(Yn||(Yn=y()(["importError"]))),!0)]}]),qr=Object(d.sequence)("Decide import code snippet",[M(Object(d.state)(Gn||(Gn=y()(["importState"]))),"loading"),function(e){var t=e.path;return e.props.importToCloud?t.cloud():t.local()},{cloud:[Wr],local:[Vr]}]),Yr=Object(d.sequence)("Import code snippet",[function(e){var t=e.path;if(e.props.importFile)return t.yes()},{yes:[qr]}]),Gr=Object(d.sequence)("Download Snippet Content",[function(){return window.ETCloudApp.setCodeSnippetPreviewState({codeSnippetPreviewState:"loading"})},function(e){var t=e.codeSnippetsLibApi,n=e.get,r=e.path,o=e.props,i=o.snippetId,a=o.snippetContent,s=o.needImageRefresh,u=o.item_location;if(!a&&"cloud"!==(void 0===u?"":u)){var l=n(Object(d.state)($n||($n=y()(["context"])))),c=q(l);return t.getItemContent(i,c).then((function(e){return r.success({snippet:e.snippet,itemId:i})})).catch((function(){return r.error()}))}var f=a;return r.success({snippet:f,itemId:i,needImageRefresh:s})},{success:[function(e){var t=e.props,n=t.snippet,r=t.itemId,o=t.needImageRefresh;window.ETCloudApp.emitSignal({signal:"renderCodeSnippetPreview",data:{snippet:n,itemId:r,needImageRefresh:o}})}],error:[]},function(){return window.ETCloudApp.setCodeSnippetPreviewState({codeSnippetPreviewState:""})}]),$r=Object(d.sequence)("Close open modal",[M(Object(d.state)(Kn||(Kn=y()(["openModal"]))),null)]),Kr=Object(d.sequence)("Open local item editor",[M(Object(d.state)(er||(er=y()(["edit.progress"]))),10),function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props.item;return t.getItemContent(r.id,r.type).then((function(e){return n.success({snippet:e.snippet})})).catch((function(){return n.error()}))},{success:[M(Object(d.state)(tr||(tr=y()(["edit.progress"]))),90),Object(b.b)(500),M(Object(d.state)(nr||(nr=y()(["edit.progress"]))),100),Object(b.b)(200),function(e){var t=e.store,n=e.props.snippet;t.set(Object(d.state)(rr||(rr=y()(["edit.snippet"]))),n)},M(Object(d.state)(or||(or=y()(["edit.progress"]))),0)],error:[M(Object(d.state)(ir||(ir=y()(["edit.progress"]))),0)]}]),Zr=Object(d.sequence)("Open cloud item editor",[M(Object(d.state)(ar||(ar=y()(["edit.snippet"]))),Object(d.props)(sr||(sr=y()(["content.data"])))),M(Object(d.state)(ur||(ur=y()(["edit.content"]))),Object(d.props)(lr||(lr=y()(["content"]))))]),Xr=Object(d.sequence)("Open modal to edit code snippet",[(Or="edit_item",function(e){return e.store.set(Object(d.state)(O||(O=y()(["openModal"]))),Or)}),M(Object(d.state)(cr||(cr=y()(["edit.item"]))),Object(d.props)(fr||(fr=y()(["item"])))),M(Object(d.state)(dr||(dr=y()(["edit.context"]))),Object(d.props)(pr||(pr=y()(["context"])))),C(Object(d.props)(hr||(hr=y()(["item.item_location"]))),(function(e){return"cloud"===e})),{true:[Zr],false:[Kr]}]),Qr=Object(d.sequence)("Close snippet editor modal",[function(e){return e.store.set(Object(d.state)(E||(E=y()(["openModal"]))),null)},M(Object(d.state)(vr||(vr=y()(["edit.saveState"]))),null),M(Object(d.state)(gr||(gr=y()(["edit.item"]))),null),M(Object(d.state)(mr||(mr=y()(["edit.snippet"]))),"")]),Jr=Object(d.sequence)("Edited item Saved",[function(){return{needImageRefresh:!0}},Gr,M(Object(d.state)(yr||(yr=y()(["edit.saveState"]))),"success"),Object(b.b)(500),Qr]),eo=Object(d.sequence)("Error while saving edited item",[M(Object(d.state)(br||(br=y()(["edit.saveState"]))),"error"),Object(b.b)(500),Qr]),to=Object(d.sequence)("Save editted content",[M(Object(d.state)(wr||(wr=y()(["edit.saveState"]))),"loading"),C(Object(d.state)(_r||(_r=y()(["edit.item.item_location"]))),(function(e){return"cloud"===e})),{true:[function(e){var t=e.get,n=e.props,r=e.path,o=t(Object(d.state)(Zn||(Zn=y()(["edit.item.id"])))),i=t(Object(d.state)(Xn||(Xn=y()(["context"])))),a=t(Object(d.state)(Qn||(Qn=y()(["edit.content"]))));return a=g()({},a,{data:n.content}),xt(i,{content:JSON.stringify(a)},[],h.noop,o).then((function(){return r.success()})).catch((function(){return r.error()}))},{success:[function(e){var t=e.get,n=e.props.content;return{snippetId:t(Object(d.state)(xr||(xr=y()(["edit.item.id"])))),snippetContent:n}},function(e){return{needImageRefresh:!0,item_location:(0,e.get)(Object(d.state)(kr||(kr=y()(["edit.item.item_location"]))))}},Jr],error:[eo]}],false:[function(e){var t=e.codeSnippetsLibApi,n=e.path,r=e.props.content,o=(0,e.get)(Object(d.state)(Jn||(Jn=y()(["edit.item.id"]))));return t.saveItemContent(o,r).then((function(e){return n.success({snippet:e.snippet})})).catch((function(){return n.error()}))},{success:[function(e){return{snippetId:(0,e.get)(Object(d.state)(Cr||(Cr=y()(["edit.item.id"]))))}},Jr],error:[eo]}]}]),no={state:{item:null,snippet:"",saveState:null,progress:0,content:{},context:""},sequences:o},ro=window.et_code_snippets_data,oo=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=f.a.ajax(g()({type:e,url:ro.api,dataType:"json",data:t},n));return Promise.resolve(r.promise()).then((function(e){return!1===e.success?Promise.reject(e.data||{}):Promise.resolve(e.data)}))},io=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return oo("POST",e,t)},ao={getItems:function(e){return io({action:"et_code_snippets_library_get_items",nonce:ro.nonces.et_code_snippets_library_get_items,et_code_snippet_type:e})},getItemContent:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"raw";return io({action:"et_code_snippets_library_get_item_content",nonce:ro.nonces.et_code_snippets_library_get_item_content,et_code_snippet_id:e,et_code_snippet_type:t,et_code_snippet_format:n})},saveItemContent:function(e,t){return io({action:"et_code_snippets_library_save_item_content",nonce:ro.nonces.et_code_snippets_library_save_item_content,et_code_snippet_id:e,et_code_snippet_content:t})},removeLocalItem:function(e){return io({action:"et_code_snippets_toggle_cloud_status",nonce:ro.nonces.et_code_snippets_library_toggle_item_location,et_code_snippet_id:e})},updateItem:function(e){return io({action:"et_code_snippets_library_update_item",nonce:ro.nonces.et_code_snippets_library_update_item,payload:e})},exportItem:function(e,t,n){return io({action:"et_code_snippets_library_export_item",nonce:ro.nonces.et_code_snippets_library_export_item,id:e,cloudContent:t,directExport:n})},downloadExportFile:function(e,t){var n={action:"et_code_snippets_library_export_item_download",nonce:ro.nonces.et_code_snippets_library_export_item,fileName:t,id:e};return"".concat(ro.api,"?").concat(jQuery.param(n))},importItem:function(e){var t=JSON.parse(e.content);return io({action:"et_code_snippets_library_import_item",nonce:ro.nonces.et_code_snippets_library_import_item,fileContent:JSON.stringify(t.data),fileData:e})},updateFilters:function(e){return io({action:"et_code_snippets_library_update_terms",nonce:ro.nonces.et_code_snippets_library_update_terms,payload:e})},getCloudToken:function(){return io({action:"et_code_snippets_library_get_token",nonce:ro.nonces.et_code_snippets_library_get_token})}},so=function(e){return"edit_item"===e(Object(d.state)(Er||(Er=y()(["openModal"]))))},uo=function(e){return{state:g()({},e,{openModal:null,itemsLoadedAndCached:!1,computed:g()({},a),cloudToken:null}),providers:i,sequences:r,modules:{edit:no}}},lo=n(210),co=n.n(lo),fo=n(211),po=n.n(fo),ho=n(133),vo=n.n(ho),go=n(212),mo=n.n(go),yo=n(136),bo=n.n(yo),wo=n(137),_o=n.n(wo),xo=n(213),ko=n.n(xo),Co=n(66),Oo=n.n(Co),Eo=n(25),So=n.n(Eo),To=n(138),jo=n.n(To),Mo=n(214),Lo=n(13),Ao=n.n(Lo),Po=n(15),Ro=n.n(Po),Do=n(7),Io=n.n(Do),No=n(14),zo=n.n(No),Fo=n(11),Bo=n.n(Fo),Ho=n(10),Uo=n.n(Ho),Wo=n(1),Vo=n.n(Wo),qo=n(17),Yo=n.n(qo),Go=n(215),$o=n(92);function Ko(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Zo=function(e){zo()(n,e);var t=Ko(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"getDefaultStyle",{configurable:!0,enumerable:!0,writable:!0,value:function(){return{size:r.props.scale,opacity:0}}}),Object.defineProperty(Io()(r),"getStyle",{configurable:!0,enumerable:!0,writable:!0,value:function(){return{size:r.props.enabled?Object($o.spring)(1,{stiffness:300,damping:20}):1,opacity:r.props.enabled?Object($o.spring)(1,{stiffness:300,damping:20}):1}}}),e))}return Ro()(n,[{key:"render",value:function(){var e=this;return u.a.createElement($o.Motion,{defaultStyle:this.getDefaultStyle(),style:this.getStyle(),onRest:this.props.onRest},(function(t){return e.props.children({opacity:t.opacity,transform:"scale(".concat(t.size,")")})}))}}]),n}(s.Component);Object.defineProperty(Zo,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{enabled:Vo.a.bool,scale:Vo.a.number,children:Vo.a.func.isRequired,onRest:Vo.a.func}}),Object.defineProperty(Zo,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{enabled:!0,scale:.5,onRest:L.noop}});var Xo=Zo;function Qo(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Jo=function(e){zo()(n,e);var t=Qo(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"componentDidMount",value:function(){Go.a.rebuild()}},{key:"render",value:function(){var e=this.props,t=e.animation,n=e.className,r=e.children;return u.a.createElement(Xo,{enabled:t},(function(e){return u.a.createElement("div",{className:"et-common-branded-modal et-common-branded-modal--fullheight ".concat(n),style:e},r)}))}}]),n}(s.PureComponent);Object.defineProperty(Jo,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{animation:Vo.a.bool,className:Vo.a.string}}),Object.defineProperty(Jo,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{animation:!0,className:""}});var ei=Jo,ti=n(35),ni=n.n(ti),ri=n(40),oi=n.n(ri),ii=n(216),ai=n.n(ii);function si(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var ui={width:"200%",height:"200%",top:"-50%",left:"-50%"},li=function(e){zo()(n,e);var t=si(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){return u.a.createElement(ai.a,{radius:150,duration:1200,background:!1,options:{background:!1},style:ui})}}]),n}(s.PureComponent),ci=["tip","ripple","className","children","forwardedRef"];function fi(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var di=function(e){zo()(n,e);var t=fi(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){var e=this.props,t=e.tip,n=e.ripple,r=e.className,o=e.children,i=e.forwardedRef,a=ni()(e,ci),s=z()({type:"button",className:"et-common-button ".concat(r)},a);return""!==t&&(s["data-tip"]=t),u.a.createElement("button",z()({ref:i},s),o,n&&u.a.createElement(li,null))}}]),n}(s.PureComponent);Object.defineProperty(di,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{tip:Vo.a.string,ripple:Vo.a.bool,className:Vo.a.string,forwardedRef:Vo.a.func}}),Object.defineProperty(di,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{tip:"",ripple:!0,className:"",forwardedRef:oi.a}});var pi=u.a.forwardRef((function(e,t){return u.a.createElement(di,z()({},e,{forwardedRef:t}))}));pi.displayName="Button";var hi=pi,vi=n(37),gi=n.n(vi),mi=n(36),yi=n.n(mi);function bi(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var wi=function(e){zo()(n,e);var t=bi(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"_renderGraphics",value:function(){var e,t=null!==(e=this.props.svgId)&&void 0!==e?e:"";switch(this.props.icon){case"delete":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 9h-3V8a1 1 0 0 0-1-1h-2a1 1 0 0 0-1 1v1H9a1 1 0 1 0 0 2h10a1 1 0 0 0 .004-2H19zM9 20c.021.543.457.979 1 1h8c.55-.004.996-.45 1-1v-7H9v7zm2.02-4.985h2v4h-2v-4zm4 0h2v4h-2v-4z",fillRule:"evenodd"}));case"close":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.59 14l4.08-4.082a1.124 1.124 0 0 0-1.587-1.588L14 12.411 9.918 8.329A1.124 1.124 0 0 0 8.33 9.92L12.411 14l-4.082 4.082a1.124 1.124 0 0 0 1.59 1.589L14 15.589l4.082 4.082a1.124 1.124 0 0 0 1.589-1.59L15.589 14h.001z",fillRule:"evenodd"}));case"exit":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.71 16.857l-2.85-2.854 2.85-2.854c.39-.395.39-1.03 0-1.426l-1.43-1.427a1 1 0 0 0-1.42 0L14 11.15l-2.85-2.854a1.013 1.013 0 0 0-1.43 0L8.3 9.723a1 1 0 0 0 0 1.426l2.85 2.854-2.85 2.853a1 1 0 0 0 0 1.427l1.42 1.427a1.011 1.011 0 0 0 1.43 0L14 16.856l2.86 2.854a1 1 0 0 0 1.42 0l1.43-1.427c.39-.395.39-1.03 0-1.426z",fillRule:"evenodd"}));case"check":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.203 9.21a.677.677 0 0 0-.98 0l-5.71 5.9-2.85-2.95a.675.675 0 0 0-.98 0l-1.48 1.523a.737.737 0 0 0 0 1.015l4.82 4.979a.677.677 0 0 0 .98 0l7.68-7.927a.737.737 0 0 0 0-1.015l-1.48-1.525z",fillRule:"evenodd"}));case"three-dots":return u.a.createElement("g",null,u.a.createElement("path",{d:"M2.001 4.5a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm0 6a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm0 6a2 2 0 1 1 0-4 2 2 0 0 1 0 4z",fillRule:"evenodd"}));case"tag":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.83,5h6.6A1.57,1.57,0,0,1,23,6.57v6.59a1.45,1.45,0,0,1-.35.66l-8.83,8.83a1.2,1.2,0,0,1-1.69,0L5.35,15.87a1.2,1.2,0,0,1,0-1.7l8.82-8.82A2,2,0,0,1,14.83,5Zm4.67,5A1.5,1.5,0,1,0,18,8.5,1.5,1.5,0,0,0,19.5,10Z"}));case"pack":return u.a.createElement("g",null,u.a.createElement("rect",{x:"6",y:"12",width:"16",height:"10",rx:"1",ry:"1"}),u.a.createElement("path",{d:"M21 6a1 1 0 0 1 1 1v3H6V9a1 1 0 0 1 1-1h5.66C13.31 7.13 14 6 15 6z"}));case"list":return u.a.createElement("g",null,u.a.createElement("rect",{x:"6",y:"6",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"6",y:"12",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"6",y:"18",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"12",y:"6",width:"10",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"12",y:"12",width:"10",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"12",y:"18",width:"10",height:"4",rx:"1",ry:"1"}));case"grid":return u.a.createElement("g",null,u.a.createElement("rect",{x:"6",y:"6",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"6",y:"12",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"6",y:"18",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"18",y:"6",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"18",y:"12",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"18",y:"18",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"12",y:"6",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"12",y:"12",width:"4",height:"4",rx:"1",ry:"1"}),u.a.createElement("rect",{x:"12",y:"18",width:"4",height:"4",rx:"1",ry:"1"}));case"back":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.988 10.963h-3v-2.52a.393.393 0 0 0-.63-.361l-5.2 4.5a.491.491 0 0 0 0 .72l5.2 4.5a.393.393 0 0 0 .63-.36v-2.52h2.99a2.992 2.992 0 0 1 2.99 2.972v1.287a.7.7 0 0 0 .7.694h2.59a.7.7 0 0 0 .7-.694v-1.3a6.948 6.948 0 0 0-6.97-6.918z",fillRule:"evenodd"}));case"placeholder":return u.a.createElement("g",null,u.a.createElement("path",{d:"M1 24h6a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H1a1 1 0 0 1-1-1v-6a1 1 0 0 1 1-1zM25 0h6a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1h-6a1 1 0 0 1-1-1V1a1 1 0 0 1 1-1zM1 12h30a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H1a1 1 0 0 1-1-1v-6a1 1 0 0 1 1-1zm12 12h18a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H13a1 1 0 0 1-1-1v-6a1 1 0 0 1 1-1zM1 0h18a1 1 0 0 1 1 1v6a1 1 0 0 1-1 1H1a1 1 0 0 1-1-1V1a1 1 0 0 1 1-1z",fill:"#e7eef5"}));case"cloud":return u.a.createElement("g",null,u.a.createElement("path",{d:"M5.48,23a5.5,5.5,0,0,1-.26-11A9,9,0,0,1,23,14h.5a4.5,4.5,0,0,1,0,9Z"}));case"menu-expand":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M14 20l-3-5h6zM14 8l3 5h-6z",fillRule:"evenodd"}));case"arrow-down-dense":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M3.44987 3.77347L5.90448 0.672666C6.00166 0.555503 6.0272 0.385363 5.96951 0.239402C5.91182 0.0934417 5.78188 -0.000569066 5.63861 2.59252e-06H0.359701C0.217594 0.000439083 0.0889622 0.0937073 0.0311752 0.238209C-0.0266118 0.382711 -0.00278329 0.551512 0.092034 0.669326L2.54904 3.77347C2.66298 3.91748 2.82706 4 2.99946 4C3.17186 4 3.33593 3.91748 3.44987 3.77347Z"}));case"caret-solid-right":return u.a.createElement("g",null,u.a.createElement("path",{d:"M6.65873 4.25043L2.00753 0.160427C1.83179 -0.00150394 1.57658 -0.0440559 1.35764 0.0520706C1.1387 0.148197 0.997682 0.364711 0.998539 0.603427L0.998539 9.39943C0.999194 9.63621 1.1391 9.85055 1.35585 9.94683C1.5726 10.0431 1.8258 10.0034 2.00252 9.84543L6.65873 5.75143C6.87475 5.56158 6.99854 5.28819 6.99854 5.00093C6.99854 4.71366 6.87475 4.44027 6.65873 4.25043Z"}));case"heart":return u.a.createElement("g",null,u.a.createElement("path",{d:"M4,10.66A5.67,5.67,0,0,1,9.51,5Q12.92,5,14,7.37C14.72,5.79,16.21,5,18.49,5A5.67,5.67,0,0,1,24,10.65C24,14,22.87,17.31,14,23,5.13,17.31,4,14,4,10.66Z"}));case"globe":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14 4C8.477 4 4 8.477 4 14s4.477 10 10 10 10-4.477 10-10S19.523 4 14 4zm.01 18c-4.411 0-8-3.589-8-8 0-.783.118-1.539.329-2.255.258.507.628.965.995 1.38.958 1.083.883 1.267.883 1.267.577 1.658 3.275.854 3.627 2.076s1.328.859.906 2.437c-.438 1.636.683 2.553 1.491 3.083-.077.003-.153.012-.231.012zm6.406-3.228c-.025-.011-.047-.027-.072-.037-1.754-.721-2.514-2.467-3.884-2.467s-2.113.532-2.882.436-.723-.917-1.276-1.373c-.553-.457-.457-.312-1.49-.697-1.033-.385-.24-2.307.481-1.971.721.336 1.304-.324 1.52.229.216.553.695 1.298.647.577-.048-.721.189-1.431.79-1.984s.096-.649.216-1.538 2.211.505 2.211-.312.361-.721.961-1.394c.528-.591.368-.882-.217-1.465a8.04 8.04 0 0 1 3.317 2.914c-1.041.174-1.418.809-1.953 1.92-.951 1.975 1.465 3.142 2.808 3.96.08.049.157.08.234.118a7.963 7.963 0 0 1-1.411 3.084z"}));case"help":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14 22a8 8 0 1 1 0-16 8 8 0 0 1 0 16zm0-3.6a.8.8 0 1 0 0-1.6.8.8 0 0 0 0 1.6zm-.8-3.2a.744.744 0 0 0 .8.8.744.744 0 0 0 .8-.8c.08-.343.305-.634.616-.8a2.976 2.976 0 0 0 1.784-2.8A2.944 2.944 0 0 0 14 8.8a3.112 3.112 0 0 0-3.2 2.4c-.096.48.264.8.8.8s.704-.32.8-.8c0-.04.216-.8 1.6-.8 1.24 0 1.6.8 1.6 1.2 0 .816-.536 1.088-1.128 1.456A2.536 2.536 0 0 0 13.2 15.2z"}));case"layout-placeholder":return u.a.createElement("g",{stroke:"none",strokeWidth:"1",fillRule:"evenodd"},u.a.createElement("path",{d:"M102,188 C107.522847,188 112,192.477153 112,198 L112,234 C112,239.522847 107.522847,244 102,244 L50,244 C44.4771525,244 40,239.522847 40,234 L40,198 C40,192.477153 44.4771525,188 50,188 L102,188 Z M350,188 C355.522847,188 360,192.477153 360,198 L360,234 C360,239.522847 355.522847,244 350,244 L140,244 C134.477153,244 130,239.522847 130,234 L130,198 C130,192.477153 134.477153,188 140,188 L350,188 Z M350,114 C355.522847,114 360,118.477153 360,124 L360,160 C360,165.522847 355.522847,170 350,170 L50,170 C44.4771525,170 40,165.522847 40,160 L40,124 C40,118.477153 44.4771525,114 50,114 L350,114 Z M211,40 C216.522847,40 221,44.4771525 221,50 L221,86 C221,91.5228475 216.522847,96 211,96 L50,96 C44.4771525,96 40,91.5228475 40,86 L40,50 C40,44.4771525 44.4771525,40 50,40 L211,40 Z M350,40 C355.522847,40 360,44.4771525 360,50 L360,86 C360,91.5228475 355.522847,96 350,96 L249,96 C243.477153,96 239,91.5228475 239,86 L239,50 C239,44.4771525 243.477153,40 249,40 L350,40 Z"}));case"background-image":return u.a.createElement("g",null,u.a.createElement("path",{d:"M309,78V206H91V78H309m8-16H83a8,8,0,0,0-8,8V214a8,8,0,0,0,8,8H317a8,8,0,0,0,8-8V70a8,8,0,0,0-8-8Z",fill:"#e7eef5"}),u.a.createElement("circle",{cx:"160",cy:"111",r:"12",fill:"#e7eef5"}),u.a.createElement("path",{d:"M105.37,190.83H295.63V151.08l-47.77-47.77a8,8,0,0,0-11.32,0l-65.2,65.2-15.75-15.74a8,8,0,0,0-11.24-.06Z",fill:"#e7eef5"}));case"folder-open":return u.a.createElement("g",null,u.a.createElement("path",{d:"M3.72076 6H17.6126L15.2792 13L1.38743 13L3.72076 6Z",fill:"#2B87DA",stroke:"#2B87DA",strokeWidth:"2"}),u.a.createElement("path",{d:"M7.00087 1.00001L7.00293 1C7.17604 0.999623 7.29258 1.04456 7.40366 1.12166C7.53485 1.21271 7.67711 1.36286 7.85596 1.60786L7.93916 1.72478L8.39713 2.40217L8.40492 2.4137L8.41303 2.425L8.52694 2.58378L8.82621 3.00095L9.33962 3.00087L15 3.00003V13H1V3.02273L1.00097 3.00138L1.0028 2.96112L1.00138 2.92084L1.00073 2.90238V1.02984L1.00233 1.0024L1.02999 1.00082L7.00087 1.00001Z",stroke:"#2B87DA",strokeWidth:"2"}));case"folder-close":return u.a.createElement("g",null,u.a.createElement("mask",{id:"path-1-inside-1_0_3891",fill:"white"},u.a.createElement("rect",{y:"2",width:"16",height:"12",rx:"1"})),u.a.createElement("rect",{y:"2",width:"16",height:"12",rx:"1",fill:"#737E89",stroke:"#737E89",strokeWidth:"4",mask:"url(#path-1-inside-1_0_3891)"}),u.a.createElement("path",{d:"M7.00184 0.500018C5.56659 0.503188 2.56668 0.501792 1.00092 0.500763C0.724748 0.500582 0.500739 0.724357 0.500739 1.0009V2.92021C0.500739 3.21507 0.746868 3.44071 1.03311 3.41833C2.56852 3.29832 5.46237 3.06926 7.76508 2.87025C8.32065 2.82224 8.84065 2.77608 9.29826 2.73369C9.0211 2.44434 8.80329 2.11638 8.61409 1.83149C8.60153 1.81259 8.58911 1.79387 8.5768 1.77537C8.04592 0.977625 7.68891 0.4985 7.00184 0.500018Z",fill:"#737E89",stroke:"#737E89"}));case"portability":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.6 20.8c0.2 0.3 0.7 0.3 0.9 0l2.1-3.5c0.2-0.3 0-0.8-0.4-0.8H11V8c0-0.6-0.4-1-1-1C9.4 7 9 7.4 9 8v8.5H7.9c-0.4 0-0.6 0.4-0.4 0.8L9.6 20.8z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M18.4 7.2c-0.2-0.3-0.7-0.3-0.9 0l-2.1 3.5c-0.2 0.3 0 0.8 0.4 0.8H17V20c0 0.6 0.4 1 1 1 0.6 0 1-0.4 1-1v-8.5h1.1c0.4 0 0.6-0.4 0.4-0.8L18.4 7.2z",fillRule:"evenodd"}));case"right-arrow":return u.a.createElement("g",null,u.a.createElement("rect",{width:"2.5",height:"9",rx:"1.25",transform:"matrix(-0.707107 0.707107 0.707107 0.707107 6.5 0.135986)",fill:"#737E89"}),u.a.createElement("rect",{width:"2.5",height:"9",rx:"1.25",transform:"matrix(0.707107 0.707107 0.707107 -0.707107 4.73218 11.0962)",fill:"#737E89"}));case"left-arrow":return u.a.createElement("g",null,u.a.createElement("rect",{x:"6.5",y:"0.135986",width:"2.5",height:"9",rx:"1.25",transform:"rotate(45 6.5 0.135986)",fill:"#737E89"}),u.a.createElement("rect",{x:"8.26782",y:"11.0962",width:"2.5",height:"9",rx:"1.25",transform:"rotate(135 8.26782 11.0962)",fill:"#737E89"}));case"magnifying-glass":return u.a.createElement("g",null,u.a.createElement("rect",{width:"28",height:"28",rx:"14",fill:"white"}),u.a.createElement("circle",{cx:"14",cy:"14",r:"5",stroke:"#32373C",strokeWidth:"2",fill:"white"}),u.a.createElement("rect",{x:"10.1992",y:"16.3867",width:"2",height:"3.66819",rx:"1",transform:"rotate(45 10.1992 16.3867)"}),u.a.createElement("rect",{x:"17",y:"13",width:"2",height:"6",rx:"1",transform:"rotate(90 17 13)"}),u.a.createElement("rect",{x:"15",y:"17",width:"2",height:"6",rx:"1",transform:"rotate(-180 15 17)"}));case"divi-ai-light":return u.a.createElement(u.a.Fragment,null,u.a.createElement("defs",null,u.a.createElement("linearGradient",{id:"divi-ai-light-linear-gradient",x1:"10.77",y1:"10.73",x2:"17.1",y2:"18.31",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{offset:"0",stopColor:"aqua"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200ff"}))),u.a.createElement("g",null,u.a.createElement("path",{className:"cls-2",d:"M5,11c0-2.83,0-4.24,.88-5.12,.88-.88,2.29-.88,5.12-.88h6c2.83,0,4.24,0,5.12,.88,.88,.88,.88,2.29,.88,5.12v6c0,2.83,0,4.24-.88,5.12s-2.29,.88-5.12,.88h-6c-2.83,0-4.24,0-5.12-.88-.88-.88-.88-2.29-.88-5.12v-6Z"})),u.a.createElement("g",null,u.a.createElement("path",{className:"cls-1",d:"M16,11c0-.55,.45-1,1-1s1,.45,1,1v6c0,.55-.45,1-1,1s-1-.45-1-1v-6Zm-1.05,5.68l-2-6c-.14-.41-.52-.68-.95-.68s-.81,.28-.95,.68l-2,6c-.17,.52,.11,1.09,.63,1.26,.52,.17,1.09-.11,1.26-.63l.44-1.32h1.23l.44,1.32c.17,.52,.74,.81,1.26,.63,.52-.17,.81-.74,.63-1.26Z"})));case"divi-ai":return u.a.createElement(u.a.Fragment,null,u.a.createElement("defs",null,u.a.createElement("linearGradient",{id:"divi-ai-linear-gradient",x1:"0%",y1:"0%",x2:"100%",y2:"100%"},u.a.createElement("stop",{offset:"0%",stopColor:"aqua"}),u.a.createElement("stop",{offset:"100%",stopColor:"#5200ff"}))),u.a.createElement("g",null,u.a.createElement("path",{d:"M22.12,5.88c-.88-.88-2.29-.88-5.12-.88h-6c-2.83,0-4.24,0-5.12,.88-.88,.88-.88,2.29-.88,5.12v6c0,2.83,0,4.24,.88,5.12s2.29,.88,5.12,.88h6c2.83,0,4.24,0,5.12-.88,.88-.88,.88-2.29,.88-5.12v-6c0-2.83,0-4.24-.88-5.12Zm-7.8,12.07c-.52,.17-1.09-.11-1.26-.63l-.44-1.32h-1.23l-.44,1.32c-.17,.52-.74,.81-1.26,.63-.52-.17-.81-.74-.63-1.26l2-6c.14-.41,.52-.68,.95-.68s.81,.28,.95,.68l2,6c.17,.52-.11,1.09-.63,1.26Zm3.68-.95c0,.55-.45,1-1,1s-1-.45-1-1v-6c0-.55,.45-1,1-1s1,.45,1,1v6Z"})));case"divi-ai-code":return u.a.createElement(u.a.Fragment,null,u.a.createElement("rect",{x:"5",y:"5",width:"18",height:"18",rx:"3",fill:"white"}),u.a.createElement("path",{d:"M16 11C16 10.4477 16.4477 10 17 10C17.5523 10 18 10.4477 18 11V17C18 17.5523 17.5523 18 17 18C16.4477 18 16 17.5523 16 17V11Z",fill:"url(#paint0_linear_654_6159_".concat(t,")")}),u.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 10C12.4305 10 12.8126 10.2754 12.9487 10.6838L14.9487 16.6838C15.1234 17.2077 14.8402 17.774 14.3163 17.9487C13.7923 18.1233 13.226 17.8402 13.0513 17.3162L12 14.1623L10.9487 17.3162C10.7741 17.8402 10.2077 18.1233 9.6838 17.9487C9.15986 17.774 8.8767 17.2077 9.05134 16.6838L11.0513 10.6838C11.1875 10.2754 11.5696 10 12 10Z",fill:"url(#paint1_linear_654_6159_".concat(t,")")}),u.a.createElement("path",{d:"M11 14H13V16H11V14Z",fill:"url(#paint2_linear_654_6159_".concat(t,")")}),u.a.createElement("defs",null,u.a.createElement("linearGradient",{id:"paint0_linear_654_6159_".concat(t),x1:"8.99976",y1:"10",x2:"16.9449",y2:"18.9382",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#4C5563"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"})),u.a.createElement("linearGradient",{id:"paint1_linear_654_6159_".concat(t),x1:"8.99976",y1:"10",x2:"16.9449",y2:"18.9382",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#4C5563"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"})),u.a.createElement("linearGradient",{id:"paint2_linear_654_6159_".concat(t),x1:"8.99976",y1:"10",x2:"16.9449",y2:"18.9382",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#4C5563"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"}))));case"divi-ai-code-hover":return u.a.createElement(u.a.Fragment,null,u.a.createElement("rect",{width:"28",height:"28",rx:"3",fill:"white",fillOpacity:"0.16"}),u.a.createElement("rect",{x:"5",y:"5",width:"18",height:"18",rx:"3",fill:"white"}),u.a.createElement("path",{d:"M16 11C16 10.4477 16.4477 10 17 10C17.5523 10 18 10.4477 18 11V17C18 17.5523 17.5523 18 17 18C16.4477 18 16 17.5523 16 17V11Z",fill:"url(#paint0_linear_655_5811_".concat(t,")")}),u.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12 10C12.4305 10 12.8126 10.2754 12.9487 10.6838L14.9487 16.6838C15.1234 17.2077 14.8402 17.774 14.3163 17.9487C13.7923 18.1233 13.226 17.8402 13.0513 17.3162L12 14.1623L10.9487 17.3162C10.7741 17.8402 10.2077 18.1233 9.6838 17.9487C9.15986 17.774 8.8767 17.2077 9.05134 16.6838L11.0513 10.6838C11.1875 10.2754 11.5696 10 12 10Z",fill:"url(#paint1_linear_655_5811_".concat(t,")")}),u.a.createElement("path",{d:"M11 14H13V16H11V14Z",fill:"url(#paint2_linear_655_5811_".concat(t,")")}),u.a.createElement("defs",null,u.a.createElement("linearGradient",{id:"paint0_linear_655_5811_".concat(t),x1:"8.99976",y1:"10",x2:"16.9449",y2:"18.9382",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#00FFFF"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"})),u.a.createElement("linearGradient",{id:"paint1_linear_655_5811_".concat(t),x1:"8.99976",y1:"10",x2:"16.9449",y2:"18.9382",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#00FFFF"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"})),u.a.createElement("linearGradient",{id:"paint2_linear_655_5811_".concat(t),x1:"8.99976",y1:"10",x2:"16.9449",y2:"18.9382",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#00FFFF"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"}))));case"divi-ai-filled":return u.a.createElement(u.a.Fragment,null,u.a.createElement("rect",{x:"5",y:"5",width:"18",height:"18",rx:"3",fill:"url(#paint0_linear_3093_65)"}),u.a.createElement("rect",{x:"16",y:"10",width:"2",height:"8",rx:"1",fill:"white"}),u.a.createElement("path",{d:"M10 17L12 11L14 17",stroke:"white",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),u.a.createElement("rect",{x:"11",y:"14",width:"2",height:"2",fill:"white"}),u.a.createElement("defs",null,u.a.createElement("linearGradient",{id:"paint0_linear_3093_65",x1:"5",y1:"5",x2:"23",y2:"23",gradientUnits:"userSpaceOnUse"},u.a.createElement("stop",{stopColor:"#00FFFF"}),u.a.createElement("stop",{offset:"1",stopColor:"#5200FF"}))));case"save":return u.a.createElement("g",null,u.a.createElement("path",{d:"M18.95 9.051a1 1 0 1 0-1.414 1.414 5 5 0 1 1-7.07 0A1 1 0 0 0 9.05 9.051a7 7 0 1 0 9.9.001v-.001zm-5.378 8.235a.5.5 0 0 0 .857 0l2.117-3.528a.5.5 0 0 0-.429-.758H15V8a1 1 0 0 0-2 0v5h-1.117a.5.5 0 0 0-.428.758l2.117 3.528z",fillRule:"evenodd"}));case"setting":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.426 13.088l-1.383-.362a.874.874 0 0 1-.589-.514l-.043-.107a.871.871 0 0 1 .053-.779l.721-1.234a.766.766 0 0 0-.116-.917 6.682 6.682 0 0 0-.252-.253.768.768 0 0 0-.917-.116l-1.234.722a.877.877 0 0 1-.779.053l-.107-.044a.87.87 0 0 1-.513-.587l-.362-1.383a.767.767 0 0 0-.73-.567h-.358a.768.768 0 0 0-.73.567l-.362 1.383a.878.878 0 0 1-.513.589l-.107.044a.875.875 0 0 1-.778-.054l-1.234-.722a.769.769 0 0 0-.918.117c-.086.082-.17.166-.253.253a.766.766 0 0 0-.115.916l.721 1.234a.87.87 0 0 1 .053.779l-.043.106a.874.874 0 0 1-.589.514l-1.382.362a.766.766 0 0 0-.567.731v.357a.766.766 0 0 0 .567.731l1.383.362c.266.07.483.26.588.513l.043.107a.87.87 0 0 1-.053.779l-.721 1.233a.767.767 0 0 0 .115.917c.083.087.167.171.253.253a.77.77 0 0 0 .918.116l1.234-.721a.87.87 0 0 1 .779-.054l.107.044a.878.878 0 0 1 .513.589l.362 1.383a.77.77 0 0 0 .731.567h.356a.766.766 0 0 0 .73-.567l.362-1.383a.878.878 0 0 1 .515-.589l.107-.044a.875.875 0 0 1 .778.054l1.234.721c.297.17.672.123.917-.117.087-.082.171-.166.253-.253a.766.766 0 0 0 .116-.917l-.721-1.234a.874.874 0 0 1-.054-.779l.044-.107a.88.88 0 0 1 .589-.513l1.383-.362a.77.77 0 0 0 .567-.731v-.357a.772.772 0 0 0-.569-.724v-.005zm-6.43 3.9a2.986 2.986 0 1 1 2.985-2.986 3 3 0 0 1-2.985 2.987v-.001z",fillRule:"evenodd"}));case"modify":return u.a.createElement(u.a.Fragment,null,u.a.createElement("path",{style:{opacity:.5},d:"M7,10c0-1.1,0.9-2,2-2c1.1,0,2,0.9,2,2c0,1.1-0.9,2-2,2C7.9,12,7,11.1,7,10z M16,12l-4.1,6.8L10,16l-4,6h16 L16,12z"}),u.a.createElement("path",{d:"M25,0.5c0.7-0.7,1.8-0.7,2.5,0c0.7,0.7,0.7,1.8,0,2.5l-1.2,1.3l-2.5-2.5L25,0.5z M21.9,3.6l2.4,2.4l-5.7,5.7 L16,12l0.2-2.6L21.9,3.6z M26,24V11.6c0-0.6-0.4-1-1-1s-1,0.4-1,1V24H4V4h12.4c0.6,0,1-0.4,1-1s-0.4-1-1-1H4C2.9,2,2,2.9,2,4v20 c0,1.1,0.9,2,2,2h20C25.1,26,26,25.1,26,24z"}));case"extend":return u.a.createElement(u.a.Fragment,null,u.a.createElement("path",{style:{opacity:.5},d:"M26,0H2C0.9,0,0,0.9,0,2v24c0,1.1,0.9,2,2,2h24c1.1,0,2-0.9,2-2V2C28,0.9,27.1,0,26,0z M2,2L2,2h3.3L2,5.3V2z M2,6.7L2,6.7L6.7,2h3.6L2,10.3V6.7z M26,26h-3.3l3.3-3.3V26z M26,21.3L21.3,26h-3.6l8.3-8.3V21.3z M26,6.3l-4,4v1.4l4-4v3.6l-4,4 v1.4l4-4v3.6l-4,4V21c0,0.6-0.4,1-1,1h-0.7l-4,4h-3.6l4-4h-1.4l-4,4H7.7l4-4h-1.4l-4,4H2.7l4-4c-0.4-0.1-0.6-0.4-0.7-0.7l-4,4v-3.6 l0,0l4-4v-1.4l-4,4v-3.6l0,0l4-4v-1.4l-4,4v-3.6l0,0l4-4V7c0-0.6,0.4-1,1-1h0.7l4-4h3.6l-4,4h1.4l4-4h3.6l-4,4h1.4l4-4h3.6l-4,4 c0.4,0.1,0.6,0.4,0.7,0.7l4-4V6.3z"}),u.a.createElement("path",{d:"M10.5,9c0.8,0,1.5,0.7,1.5,1.5S11.3,12,10.5,12S9,11.3,9,10.5S9.7,9,10.5,9z M20,19l-4.5-7l-3.1,4.8L11,15l-3,4 H20z M21,5H7C5.9,5,5,5.9,5,7v14c0,1.1,0.9,2,2,2h14c1.1,0,2-0.9,2-2V7C23,5.9,22.1,5,21,5z M21,21H7V7l0,0h14V21z"}));case"upscale":return u.a.createElement(u.a.Fragment,null,u.a.createElement("path",{style:{opacity:.5},d:"M24,26H4c-1.1,0-2-0.9-2-2V4c0-1.1,0.9-2,2-2h12.4c0.6,0,1,0.4,1,1s-0.4,1-1,1H4v20h20V11.6c0-0.6,0.4-1,1-1s1,0.4,1,1V24 C26,25.1,25.1,26,24,26z"}),u.a.createElement("path",{d:"M25.7,2.3C25.5,2.1,25.3,2,25,2h-4c-0.6,0-1,0.4-1,1s0.4,1,1,1h1.6l-4.1,4.1C18.3,8,18.2,8,18,8H4c-1.1,0-2,0.9-2,2v14 c0,1.1,0.9,2,2,2h14c1.1,0,2-0.9,2-2V10c0-0.2,0-0.3-0.1-0.5L24,5.4V7c0,0.6,0.4,1,1,1s1-0.4,1-1V3C26,2.7,25.9,2.5,25.7,2.3z M18,24H4V10l0,0h14V24z M7.5,12C8.3,12,9,12.7,9,13.5S8.3,15,7.5,15S6,14.3,6,13.5S6.7,12,7.5,12z M11,22h6l-4.5-7l-3.1,4.8L8,18 l-3,4h3H11z"}));case"enhance":return u.a.createElement(u.a.Fragment,null,u.a.createElement("path",{style:{opacity:.5},d:"M7,10c0-1.1,0.9-2,2-2c1.1,0,2,0.9,2,2c0,1.1-0.9,2-2,2C7.9,12,7,11.1,7,10z M16,12l-4.1,6.8L10,16l-4,6h16 L16,12z"}),u.a.createElement("path",{d:"M24,26H4c-1.1,0-2-0.9-2-2V4c0-1.1,0.9-2,2-2h8.3c0.6,0,1,0.4,1,1s-0.4,1-1,1H4v20h20v-8.1c0-0.6,0.4-1,1-1 s1,0.4,1,1V24C26,25.1,25.1,26,24,26z M15.6,5.6L13,6.5l2.6,0.9l0.9,2.6l0.9-2.6L20,6.5l-2.6-0.9L16.5,3L15.6,5.6z M22.6,3.6L20,4.5 l2.6,0.9L23.5,8l0.9-2.6L27,4.5l-2.6-0.9L23.5,1L22.6,3.6z M20.6,10.6L18,11.5l2.6,0.9l0.9,2.6l0.9-2.6l2.6-0.9l-2.6-0.9L21.5,8 L20.6,10.6z"}));case"undo":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.355 7.253c-1.74.026-3.321.559-4.576 1.528L7.999 7A1 1 0 0 0 7 8v4.998c0 .552.447.999.999.999h4.995a1 1 0 0 0 .999-.999l-2.014-2.016a4.51 4.51 0 0 1 2.44-.733c2.235-.032 4.261 1.58 4.534 3.799.338 2.751-1.789 5.009-4.46 5.009-1.149 0-2.186-.462-2.978-1.182a.654.654 0 0 0-.902.026l-1.184 1.175a.674.674 0 0 0 .032.979A7.443 7.443 0 0 0 14.493 22c4.401 0 7.915-3.8 7.452-8.297-.395-3.826-3.745-6.507-7.59-6.45z",fillRule:"evenodd"}));case"redo":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13.645 6.253C15.385 6.279 16.966 6.812 18.221 7.781L20.001 6C20.5529 6.00055 21 6.44811 21 7V11.998C21 12.55 20.553 12.997 20.001 12.997H15.006C14.4545 12.9964 14.0076 12.5495 14.007 11.998L16.021 9.982C15.295 9.50824 14.4479 9.25375 13.581 9.249C11.346 9.217 9.32 10.829 9.047 13.048C8.709 15.799 10.836 18.057 13.507 18.057C14.656 18.057 15.693 17.595 16.485 16.875C16.7445 16.6416 17.1414 16.6531 17.387 16.901L18.571 18.076C18.7014 18.2076 18.7719 18.3872 18.7658 18.5724C18.7598 18.7576 18.6777 18.9322 18.539 19.055C17.1639 20.3098 15.3685 21.0037 13.507 21C9.106 21 5.592 17.2 6.055 12.703C6.45 8.877 9.8 6.196 13.645 6.253Z",fillRule:"evenodd"}));case"image-edit":return u.a.createElement("g",null,u.a.createElement("rect",{width:"28",height:"28",rx:"14",fill:"white"}),u.a.createElement("path",{d:"M17.1348 9.45117C17.6018 8.9841 18.3591 8.9841 18.8262 9.45117C19.2932 9.91824 19.2932 10.6755 18.8262 11.1426L14.3692 15.5996C14.1739 15.7948 13.8573 15.7948 13.6621 15.5996L12.6778 14.6153C12.4825 14.42 12.4825 14.1034 12.6778 13.9082L17.1348 9.45117Z"}),u.a.createElement("path",{d:"M10.5408 17.5892C10.4987 17.7696 10.6606 17.9315 10.8411 17.8895L12.8749 17.4152C13.0659 17.3707 13.1336 17.1336 12.9949 16.9949L11.4353 15.4354C11.2967 15.2967 11.0596 15.3644 11.0151 15.5554L10.5408 17.5892Z"}),u.a.createElement("rect",{x:"19",y:"19",width:"2",height:"10",rx:"1",transform:"rotate(90 19 19)"}));case"checkmark-rounded":return u.a.createElement("g",null,u.a.createElement("rect",{width:"34",height:"34",rx:"17",fill:"#7E3BD0"}),u.a.createElement("path",{d:"M22.2026 12.2099C22.0748 12.0758 21.8977 12 21.7126 12C21.5274 12 21.3503 12.0758 21.2226 12.2099L15.5126 18.1099L12.6626 15.1599C12.5351 15.0253 12.3579 14.9491 12.1726 14.9491C11.9872 14.9491 11.81 15.0253 11.6826 15.1599L10.2026 16.6829C9.93248 16.9673 9.93248 17.4134 10.2026 17.6979L15.0226 22.6769C15.1503 22.8109 15.3274 22.8867 15.5126 22.8867C15.6977 22.8867 15.8748 22.8109 16.0026 22.6769L23.6826 14.7499C23.9527 14.4654 23.9527 14.0193 23.6826 13.7349L22.2026 12.2099Z",fill:"white"}));case"layers":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13.4335 16.6105C13.7747 16.8451 14.2253 16.8451 14.5665 16.6105L20.8014 12.324C21.3794 11.9267 21.3794 11.0733 20.8014 10.676L14.5665 6.38949C14.2253 6.15488 13.7747 6.15488 13.4335 6.38949L7.19861 10.676C6.62064 11.0733 6.62064 11.9267 7.19861 12.324L13.4335 16.6105Z",stroke:"#7E3BD0",strokeWidth:"2"}),u.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M17.7555 14.5763L19.9723 16.1598L20.5536 16.9735L19.9723 16.1598L14 20.4258L8.02766 16.1598L7.44642 15.3461L8.02766 16.1598L10.2445 14.5763L8.52408 13.3474L6.86518 14.5323C5.74849 15.33 5.74848 16.9896 6.86518 17.7873L12.8375 22.0532C13.5329 22.5499 14.4671 22.5499 15.1625 22.0532L21.1348 17.7873C22.2515 16.9896 22.2515 15.33 21.1348 14.5323L19.4759 13.3474L17.7555 14.5763Z",fill:"#7E3BD0"}));case"spinner":return u.a.createElement("g",null,u.a.createElement("circle",{className:"spinner-spin",cx:"12",cy:"12",r:"0"}),u.a.createElement("circle",{className:"spinner-spin spinner-spin-2",cx:"12",cy:"12",r:"0"}),u.a.createElement("circle",{className:"spinner-spin spinner-spin-3",cx:"12",cy:"12",r:"0"}));case"delete-light":return u.a.createElement("g",null,u.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 2L10.998 2H11.002C11.5543 2.0011 12.0011 2.44972 12 3.002C11.9989 3.55429 11.5503 4.0011 10.998 4L1 4C0.447715 4 0 3.55229 0 3C0 2.44772 0.447715 2 1 2H4V1C4 0.447715 4.44772 0 5 0H7C7.55229 0 8 0.447715 8 1V2ZM2 14C1.457 13.979 1.021 13.543 1 13V6H11V13C10.996 13.55 10.55 13.996 10 14H2ZM3 8H5V12H3V8ZM9 8H7V12H9V8Z",fill:"#2B87DA"}));case"pencil":return u.a.createElement("g",null,u.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M10.9721 0.519712C11.665 -0.173237 12.7874 -0.173237 13.4803 0.519712C14.1733 1.21266 14.1733 2.33505 13.4803 3.028L12.2708 4.29248L9.76253 1.7842L10.9721 0.519712ZM7.93037 3.6394L10.3607 6.06969L3.63395 12.7964L0 14.0001L1.20366 10.3661L7.93037 3.6394Z",fill:"#2B87DA"}));case"eye":return u.a.createElement("g",null,u.a.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M8 0.000102264C4.25771 -0.0182888 0.972543 2.44562 0 6.00019C0.98904 9.54379 4.26409 12 8 12C11.7359 12 15.011 9.54379 16 6.00019C15.0275 2.44562 11.7423 -0.0182888 8 0.000102264ZM8 10.033C5.36244 10.0501 2.99801 8.43638 2.091 6.00019C3.01229 3.57486 5.36779 1.96719 8 1.96719C10.6322 1.96719 12.9877 3.57486 13.909 6.00019C13.002 8.43638 10.6376 10.0501 8 10.033ZM10 6C10 7.10457 9.10457 8 8 8C6.89543 8 6 7.10457 6 6C6 4.89543 6.89543 4 8 4C9.10457 4 10 4.89543 10 6Z",fill:"#2B87DA"}));case"plus":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9 4H6V1C6 0.447715 5.55228 0 5 0C4.44772 0 4 0.447715 4 1V4H1C0.447715 4 0 4.44772 0 5C0 5.55228 0.447715 6 1 6H4V9C4 9.55229 4.44772 10 5 10C5.55228 10 6 9.55229 6 9V6H9C9.55229 6 10 5.55228 10 5C10 4.44772 9.55229 4 9 4Z",fill:"#32373C"}))}}},{key:"render",value:function(){var e=this.props,t=e.className,n=e.color,r=e.icon,o=e.size,i=e.viewBox,a=e.margin,s=e.onClick,l=e.elementType;if(!r)return!1;var c={fill:n,width:2*o,minWidth:2*o,height:2*o,margin:yi()(a)||!1===a?-(o-8):a},f="et-common-icon--".concat(r),d=Yo()({"et-common-icon":!0},f,t),p=this._renderGraphics();return p||(c={}),u.a.createElement(l,{className:d,style:gi()(c,this.props.style),onClick:s,"data-testid":this.props["data-for"]},u.a.createElement("svg",{viewBox:i,preserveAspectRatio:"xMidYMid meet",shapeRendering:"geometricPrecision"},p))}}]),n}(s.PureComponent);Object.defineProperty(wi,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{color:"#4c5866",size:14,viewBox:"0 0 28 28",elementType:"div"}});var _i=wi,xi=["title","additionalButton","onClose","className","showCloseButton"];function ki(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Ci=function(e){zo()(n,e);var t=ki(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){var e=this.props,t=e.title,n=e.additionalButton,r=e.onClose,o=e.className,i=e.showCloseButton,a=ni()(e,xi);return u.a.createElement("div",z()({className:"et-common-branded-modal__header ".concat(o)},a),u.a.createElement("span",{className:"et-common-branded-modal__title"},Object(L.isFunction)(t)?t():t),u.a.createElement("div",{className:"et-common-branded-modal__header-buttons"},Object(L.isFunction)(n)&&n(),i&&u.a.createElement(hi,{className:"et-common-button--round",onClick:r},u.a.createElement(_i,{icon:"close",color:"#ffffff"}))))}}]),n}(s.PureComponent);Object.defineProperty(Ci,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{title:Vo.a.oneOfType([Vo.a.string,Vo.a.func]).isRequired,className:Vo.a.string,onClose:Vo.a.func,additionalButton:Vo.a.func,showCloseButton:Vo.a.bool}}),Object.defineProperty(Ci,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{className:"",onClose:L.noop,additionalButton:L.noop,showCloseButton:!0}});var Oi=Ci,Ei=function(e){var t=e.progress,n=e.estimate,r=Math.ceil(Math.max(0,Math.min(100,t)));return 100==r?u.a.createElement("div",{className:"et-common-progress-bar"},u.a.createElement("span",{className:"et-common-loader et-common-loader-success"})):u.a.createElement("div",{className:"et-common-progress-bar"},u.a.createElement("div",{className:"et-common-progress-bar__background"},u.a.createElement("div",{className:"et-common-progress-bar__bar",style:{width:"".concat(r,"%")}},u.a.createElement("div",{className:"et-common-progress-bar__value"},"".concat(r,"%")))),n&&u.a.createElement("div",{className:"et-common-progress-bar__estimate"},n))};Ei.propTypes={progress:Vo.a.number.isRequired,estimate:Vo.a.string},Ei.defaultProps={estimate:""};var Si=u.a.memo(Ei);function Ti(e){var t=e.className,n=void 0===t?"":t;return u.a.createElement("div",{className:Yo()("et-common-app-spinner-block",n),"data-testid":"Spinner"},u.a.createElement("div",{className:"et-common-app-spinner-block__spinner"}))}var ji=u.a.memo(Ti);function Mi(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Li=function(e){zo()(n,e);var t=Mi(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"state",{configurable:!0,enumerable:!0,writable:!0,value:{importProgress:0,hideProgressBar:!1}}),Object.defineProperty(Io()(r),"onDownloadItem",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){r.props.onDownloadItem(t)}}),Object.defineProperty(Io()(r),"onUseItem",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){r.props.onUseItem(t)}}),Object.defineProperty(Io()(r),"onFilterUpdate",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){r.props.updateLocalFilters({payload:t}).then((function(e){window.ETCloudApp.emitSignal({signal:"receiveNewFilter",data:{data:e}})}))}}),Object.defineProperty(Io()(r),"toggleCloudStatus",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){var n=t.id;n&&r.props.toggleLibraryItemLocation({id:n}).then((function(e){var t=Object(L.get)(e,"localLibraryTerms",[]);if(!Object(L.isEmpty)(t)){var n={data:{filterType:"categories",localLibraryTerms:t,newFilters:t.layout_category}};window.ETCloudApp.emitSignal({signal:"receiveNewFilter",data:n});var r={data:{filterType:"tags",localLibraryTerms:t,newFilters:t.layout_tag}};window.ETCloudApp.emitSignal({signal:"receiveNewFilter",data:r})}}))}}),Object.defineProperty(Io()(r),"exportLocalItem",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t,n){r.props.getExportLocalItem({id:e,itemType:t}).then((function(t){(t=Object(L.get)(t,"exported","")).context="epanel";var r=Object(L.assign)(n,{content:t,updatedItem:e});window.ETCloudApp.emitSignal({signal:"receiveItemUpdate",data:{data:r}})}))}}),Object.defineProperty(Io()(r),"load",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.container,n=e.cloudPreferences,o=z()({context:"",itemsLabel:"",initialTab:"modules_library",editableTabs:["modules_library"],cloudTab:"modules_library",predefinedTab:"",animation:"on"},n);jQuery(window).trigger("et_cloud_container_ready",[o,t])}}),Object.defineProperty(Io()(r),"onItemUpdate",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){var n=r.props,o=n.onUpdateItem,i=n.cloudPreferences,a=Object(L.get)(t,"clickedItem.id",""),s={item_id:a,update_details:Object(L.get)(t,"itemPayload",[])},u=Object(L.get)(t,"clickedItem.type",i.context),l=Object(L.get)(t,"itemPayload.updateType",""),c="on"===Object(L.get)(t,"itemPayload.cloud"),f=Object(L.get)(s,"update_details",{});if("toggle_cloud"===l||"duplicate"===l&&c||Object(L.includes)(["move_to","copy_to"],l))r.exportLocalItem(a,u,f);else{if("toggle_fav"===l){var d=Object(L.get)(t,"clickedItem.is_favorite")?"off":"on";Object(L.set)(s,"update_details.favoriteStatus",d)}o({payload:s}).then((function(e){window.ETCloudApp.emitSignal({signal:"receiveItemUpdate",data:e.updatedItem})}))}}}),Object.defineProperty(Io()(r),"onDownloadProgress",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){r.setState({hideProgressBar:!1}),(t=Math.floor(t/2))<1&&(t=1),r.setState({importProgress:t})}}),Object.defineProperty(Io()(r),"renderProgressBar",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.state,t=e.importProgress,n=t>0;return!e.hideProgressBar&&(100===t&&setTimeout((function(){r.setState({hideProgressBar:!0})}),3e3),n&&u.a.createElement(Si,{progress:t}))}}),e))}return Ro()(n,[{key:"componentDidMount",value:function(){this.load(),jQuery(window).on("et_cloud_use_item",this.onUseItem),jQuery(window).on("et_cloud_update_item",this.onItemUpdate),jQuery(window).on("et_cloud_item_toggle_location",this.toggleCloudStatus),jQuery(window).on("et_cloud_download_progress",this.onDownloadProgress),jQuery(window).on("et_cloud_download_item",this.onDownloadItem),jQuery(window).on("et_cloud_filter_update",this.onFilterUpdate)}},{key:"componentWillUnmount",value:function(){jQuery(window).off("et_cloud_use_item",this.onUseItem),jQuery(window).off("et_cloud_update_item",this.onItemUpdate),jQuery(window).off("et_cloud_item_toggle_location",this.toggleCloudStatus),jQuery(window).off("et_cloud_download_progress",this.onDownloadProgress),jQuery(window).off("et_cloud_download_item",this.onDownloadItem),jQuery(window).off("et_cloud_filter_update",this.onFilterUpdate)}},{key:"render",value:function(){var e=!this.props.itemsLoaded;return u.a.createElement("div",{className:"et-common-library__container"},e&&u.a.createElement(ji,{className:"et-common-app-spinner-block et-common-app-spinner-block--overlay"}),u.a.createElement("div",{id:"et-cloud-app",className:"et-common-library-cloud"}),this.renderProgressBar())}}]),n}(s.PureComponent);Object.defineProperty(Li,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{cloudPreferences:Vo.a.object.isRequired,onUpdateItem:Vo.a.func.isRequired}}),Object.defineProperty(Li,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{container:document,itemsLoaded:!0}});var Ai=Li,Pi=n(55),Ri=n.n(Pi);function Di(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Ii=function(e){zo()(n,e);var t=Di(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"_onClickTab",{configurable:!0,enumerable:!0,writable:!0,value:function(e){e.preventDefault();var t=e.target.getAttribute("data-key");r.props.onChange(t)}}),e))}return Ro()(n,[{key:"render",value:function(){var e=this,t=this.props,n=t.currentTab,r=t.tabs,o=t.className,i=t.forwardedRef;return u.a.createElement("div",{ref:i,className:"et-common-tabs-navigation ".concat(o)},Ri()(r,(function(t){return u.a.createElement("button",{key:t.key,type:"button",className:Yo()({"et-common-tabs-navigation__button":!0,"et-common-tabs-navigation__button--active":t.key===n}),role:"tab","data-key":t.key,onClick:e._onClickTab},t.title)})))}}]),n}(s.PureComponent);Object.defineProperty(Ii,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{currentTab:Vo.a.string.isRequired,tabs:Vo.a.arrayOf(Vo.a.shape({key:Vo.a.string.isRequired,title:Vo.a.string.isRequired})).isRequired,className:Vo.a.string,onChange:Vo.a.func}}),Object.defineProperty(Ii,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{className:"",onChange:oi.a}});var Ni=u.a.forwardRef((function(e,t){return u.a.createElement(Ii,z()({},e,{forwardedRef:t}))})),zi=n(22),Fi=n.n(zi),Bi=n(24),Hi=n.n(Bi),Ui=n(217),Wi=n.n(Ui),Vi=n(139),qi=n.n(Vi),Yi=n(134),Gi=n.n(Yi),$i=-1,Ki=function(){if(0<$i)return $i;var e=document.createElement("div"),t=document.createElement("div");e.style.visibility="hidden",e.style.width="100px",t.style.width="100%",t.style.height="100%",e.appendChild(t),document.body.appendChild(e);var n=e.offsetWidth;e.style.overflow="scroll";var r=t.offsetWidth;return document.body.removeChild(e),$i=n-r},Zi=function(e){return e.document.body.scrollHeight>e.document.body.clientHeight};function Xi(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Qi=function(e){zo()(n,e);var t=Xi(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"toggleBodyClass",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=f()("body"),t=f()(window),n=e.hasClass("rtl"),o=r.getLocks().length>0,i="et-common-scroll-lock--added-margin",a=parseInt(e.attr("data-et-common-scroll-lock-offset"))||0,s=e.find("#wpadminbar");if(o&&Zi(window)){var u=Ki();e.addClass(i),e.css("margin".concat(n?"Left":"Right"),"".concat(u,"px")),s.length>0&&s.css("width","calc(100% - ".concat(u,"px)"))}!o&&e.hasClass(i)&&(e.removeClass(i),e.css("margin".concat(n?"Left":"Right"),""),s.length>0&&s.css("width","")),o&&0===a?e.attr("data-et-common-scroll-lock-offset",t.scrollTop()):o||0===a||(t.scrollTop(parseInt(e.attr("data-et-common-scroll-lock-offset"))||0),e.removeAttr("data-et-common-scroll-lock-offset")),e.toggleClass("et-common-scroll-lock",o)}}),Object.defineProperty(Io()(r),"getLocks",{configurable:!0,enumerable:!0,writable:!0,value:function(){return qi()((f()("body").attr("data-et-common-scroll-locks")||"").split(","),(function(e){return!!e}))}}),Object.defineProperty(Io()(r),"setLocks",{configurable:!0,enumerable:!0,writable:!0,value:function(e){f()("body").attr("data-et-common-scroll-locks",e.join(","))}}),Object.defineProperty(Io()(r),"addLock",{configurable:!0,enumerable:!0,writable:!0,value:function(e){var t=r.getLocks();t.push(e),r.setLocks(Gi()(t))}}),Object.defineProperty(Io()(r),"removeLock",{configurable:!0,enumerable:!0,writable:!0,value:function(e){var t=r.getLocks();r.setLocks(qi()(t,(function(t){return t!==e})))}}),e))}return Ro()(n,[{key:"componentDidMount",value:function(){this.addLock(this.props.lockId),this.toggleBodyClass()}},{key:"componentDidUpdate",value:function(e){this.removeLock(e.lockId),this.addLock(this.props.lockId),this.toggleBodyClass()}},{key:"componentWillUnmount",value:function(){this.removeLock(this.props.lockId),this.toggleBodyClass()}},{key:"render",value:function(){return null}}]),n}(s.PureComponent);Object.defineProperty(Qi,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{lockId:Vo.a.string.isRequired}});var Ji=Qi,ea=u.a.forwardRef((function(e,t){var n=e.animation,r=e.modalKey,o=e.children,i=e.draggable,a=Object(s.useState)({x:0,y:0}),l=Fi()(a,2),c=l[0],f=l[1],d=Object(s.useRef)(),p={enabled:n};Hi()(r)||(p.key=r);var h=function(){if(d.current){var e=window.top,t=d.current.getBoundingClientRect(),n=t.left,r=t.top;if(t.right>e.innerWidth&&(n=e.innerWidth-t.width),t.bottom>e.innerHeight&&(r=e.innerHeight-t.height),t.left<0&&(n=0),t.top<0&&(r=0),n!==t.left||r!==t.top){var o=n-t.left,i=r-t.top,a=d.current.style.transform.replace(/translate\((.*)px, (.*)px\)/,(function(e,t,n){var r=parseInt(t,10)+o,a=parseInt(n,10)+i;return f({x:r,y:a}),"translate(".concat(r,"px, ").concat(a,"px)")}));d.current.style.transform=a}}};Object(s.useEffect)((function(){if(i){var e=localStorage.getItem("".concat(r,"_position"));e&&f(JSON.parse(e));var t=d.current,n=new IntersectionObserver((function(e){e.forEach((function(e){e.isIntersecting||h()}))}),{root:null,rootMargin:"0px",threshold:0});t&&n.observe(t);var o=new ResizeObserver((function(){h()}));return t&&o.observe(t),function(){t&&(n.unobserve(t),o.unobserve(t))}}}),[]);var v=function(e,t){var n={x:t.lastX,y:t.lastY};localStorage.setItem("".concat(r,"_position"),JSON.stringify(n)),f(n)},g=function(){return u.a.createElement("div",{className:"et-common-prompt__container",ref:d},o)},m=Yo()({"et-common-prompt":!0,"et-common-prompt-draggable":i});return u.a.createElement("div",{className:m,ref:t},!i&&u.a.createElement("div",{className:"et-common-prompt__overlay"}),u.a.createElement(Xo,z()({},p,{onRest:h}),(function(e){return u.a.createElement("div",{className:"et-common-prompt__modal",style:e},i&&u.a.createElement(Wi.a,{handle:".react-draggable > .et-common-prompt__header",bounds:"parent",position:c,onStop:v},g()),!i&&g())})),u.a.createElement(Ji,{lockId:"common-prompt"}))}));ea.propTypes={animation:Vo.a.bool,modalKey:Vo.a.oneOfType([Vo.a.string,Vo.a.number]),draggable:Vo.a.bool},ea.defaultProps={animation:!0,modalKey:"",draggable:!1},ea.Header=u.a.memo((function(e){var t=e.children,n=e.render,r=e.onBack,o=e.onClose,i=e.className,a=void 0===i?"":i,s=e.additionalActions,l=void 0===s?null:s,c=Yo()({"et-common-prompt__header":!0,"et-common-prompt__header-back":r})+" ".concat(a);return u.a.createElement("div",{className:c},Object(L.isFunction)(r)&&u.a.createElement(hi,{className:"et-common-button--round",onClick:r},u.a.createElement(_i,{icon:"back",color:"#ffffff"})),u.a.createElement("span",null,t),Object(L.isFunction)(n)&&n(),u.a.createElement("div",{className:"et-common-prompt__header-actions"},u.a.createElement(u.a.Fragment,null,l||null,Object(L.isFunction)(o)&&u.a.createElement(hi,{className:"et-common-button--round",onClick:o,"data-testid":"ClosePrompt"},u.a.createElement(_i,{icon:"close",color:"#ffffff"})))))})),ea.Content=u.a.memo((function(e){var t=e.style,n=e.children;return u.a.createElement("div",{className:"et-common-prompt__body"},u.a.createElement("div",{className:"et-common-prompt__content",style:t},n))})),ea.Content.propTypes={style:Vo.a.object},ea.Content.defaultProps={style:{}},ea.Actions=u.a.memo((function(e){var t=e.children;return u.a.createElement("div",{className:"et-common-prompt__footer"},t)}));var ta=ea,na=["className","type"];function ra(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var oa=function(e){zo()(n,e);var t=ra(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){var e=this.props,t=e.className,n=e.type,r=ni()(e,na);return u.a.createElement("input",z()({type:n,className:"et-common-input-text ".concat(t)},r))}}]),n}(s.PureComponent);Object.defineProperty(oa,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{className:Vo.a.string,type:Vo.a.string}}),Object.defineProperty(oa,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{className:"",type:"text"}});var ia=oa,aa=["positive","value","checked","className","children"];function sa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var ua=function(e){zo()(n,e);var t=sa(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){var e=this.props,t=e.positive,n=e.value,r=e.checked,o=e.className,i=e.children,a=ni()(e,aa);return u.a.createElement("label",{className:"et-common-checkbox ".concat(o)},u.a.createElement("input",z()({type:"checkbox",value:n,checked:r,className:Yo()({"et-common-checkbox__input":!0,"et-common-checkbox__input--danger":!t})},a)),u.a.createElement("span",{className:"et-common-checkbox__label"},i))}}]),n}(s.PureComponent);Object.defineProperty(ua,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{positive:Vo.a.bool,value:Vo.a.oneOfType([Vo.a.string,Vo.a.number]).isRequired,checked:Vo.a.bool.isRequired,className:Vo.a.string}}),Object.defineProperty(ua,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{value:1,positive:!0,className:""}});var la=ua;function ca(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var fa=function(e){zo()(n,e);var t=ca(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"state",{configurable:!0,enumerable:!0,writable:!0,value:{disabled:!1,importFile:null,replaceContent:!1,downloadBackup:!1,importToCloud:!1}}),Object.defineProperty(Io()(r),"_setTab",{configurable:!0,enumerable:!0,writable:!0,value:function(e){r.props.setTab(e)}}),Object.defineProperty(Io()(r),"_onFileUpload",{configurable:!0,enumerable:!0,writable:!0,value:function(e){r.setState({importFile:Object(L.get)(e,"target.files[0]",""),disabled:!1})}}),Object.defineProperty(Io()(r),"_onReplaceContentChange",{configurable:!0,enumerable:!0,writable:!0,value:function(){r.setState({replaceContent:!r.state.replaceContent})}}),Object.defineProperty(Io()(r),"_onDownloadBackupChange",{configurable:!0,enumerable:!0,writable:!0,value:function(){r.setState({downloadBackup:!r.state.downloadBackup})}}),Object.defineProperty(Io()(r),"_onImportToCloudChange",{configurable:!0,enumerable:!0,writable:!0,value:function(){r.setState({importToCloud:!r.state.importToCloud})}}),Object.defineProperty(Io()(r),"_onFileNameChange",{configurable:!0,enumerable:!0,writable:!0,value:function(e){r.props.onFileNameChange(e.target.value)}}),Object.defineProperty(Io()(r),"_onPortabilityClick",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.state,n=e.tabMode,o=e.onPortabilityExport,i=e.onPortabilityImport,a=r.state,s=a.importFile,u=a.replaceContent,l=a.downloadBackup,c=a.importToCloud;r.setState({disabled:!0}),"export"!==t?s&&(n?i(s,u,l):i(s,c)):o()}}),e))}return Ro()(n,[{key:"renderExportArea",value:function(){var e=this.props,t=e.fileName,n=e.tabMode,r=e.subTitle,o=e.title;return u.a.createElement("div",{className:"et-common-export-file-container"},u.a.createElement("div",{className:"et-common-export-file-name-field"},n&&u.a.createElement("p",null,I("library","Exporting your %s will create a JSON file that can be imported into a different area.",r)),u.a.createElement("h3",null,I("library","Export %s Name",o)),u.a.createElement(ia,{value:t,name:"exportFileName",onChange:this._onFileNameChange})),u.a.createElement("div",{className:"et-common-export-error-container"}))}},{key:"renderImportArea",value:function(){var e=this.props,t=e.importError,n=e.tabMode,r=e.isCloudAvailable,o=e.cloudCheckboxLabel,i=this.state,a=i.importFile,l=i.replaceContent,c=i.downloadBackup,f=i.importToCloud,d=Object(L.get)(a,"name",I("library","No File Selected")),p=Yo()({"et-common-portability-import-placeholder":!0,"et-common-portability-import-placeholder--active":!Object(L.isEmpty)(Object(L.get)(a,"name",""))}),h=o||I("library","Import To Cloud"),v=r&&window.ETCloudApp.hasTeamPermissions("add"),g=v?u.a.createElement("p",null,u.a.createElement(la,{checked:f,onChange:this._onImportToCloudChange},h)):null;return u.a.createElement("div",{className:"et-common-import-file-container"},u.a.createElement("div",{className:"et-common-import-file-name-field"},u.a.createElement("h3",null,I("library","Choose File")),u.a.createElement("span",{className:p},d),u.a.createElement("input",{type:"file",className:"et-common-import-file",onChange:this._onFileUpload})),u.a.createElement("div",{className:"et-common-import-error-container"},t&&u.a.createElement("p",null,t)),u.a.createElement("div",{className:"et-common-portability-options-field"},!(!n&&!v)&&u.a.createElement("h3",null,I("library","Options")),n?u.a.createElement(s.Fragment,null,u.a.createElement("p",null,u.a.createElement(la,{checked:l,onChange:this._onReplaceContentChange},I("library","Replace Existing Content"))),u.a.createElement("p",null,u.a.createElement(la,{checked:c,onChange:this._onDownloadBackupChange},I("library","Download Backup Before Importing")))):u.a.createElement(s.Fragment,null,g)))}},{key:"render",value:function(){var e=this.props,t=e.title,n=e.state,r=e.loading,o=e.tabMode,i=e.heading,a=e.onClose,s=e.importState,l=this.state.disabled,c="export"===n,f="loading"===s,d=Yo()({"et-common-button--primary":!0,"et-common-button-disabled":l});return u.a.createElement("div",{className:"et-common-library-portability-modal"},u.a.createElement(ta,{modalKey:"et-common-portability-modal"},u.a.createElement(ta.Header,{onClose:a},i.replace(/&/,"&")),o&&u.a.createElement("div",{className:Yo()({"et-common-portability-modal__tab":!0,"et-common-portability-modal__tab--loading":r})},!r&&u.a.createElement(Ni,{className:"et-common-portability-modal__tabs-navigation",onChange:this._setTab,currentTab:n,tabs:[{key:"export",title:I("library","Export")},{key:"import",title:I("library","Import")}]})),f&&u.a.createElement("div",{className:"et-common-library-portability-modal__spinner-overlay"},u.a.createElement(ji,null)),u.a.createElement(ta.Content,null,c?this.renderExportArea():this.renderImportArea()),u.a.createElement(ta.Actions,null,u.a.createElement(hi,{className:d,onClick:this._onPortabilityClick},I("library",c?"Export %s":"Import %s",t)))))}}]),n}(s.PureComponent);Object.defineProperty(fa,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{title:Vo.a.string.isRequired,subTitle:Vo.a.string,state:Vo.a.string,fileName:Vo.a.string,setTab:Vo.a.func,onClose:Vo.a.func.isRequired,cloudCheckboxLabel:Vo.a.string}}),Object.defineProperty(fa,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{loading:!1,tabMode:!1,heading:I("library","Portability"),subTitle:""}});var da=fa;function pa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var ha=function(e){zo()(n,e);var t=pa(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"state",{configurable:!0,enumerable:!0,writable:!0,value:{portability:{id:0,state:null,title:"",content:"",fileName:""}}}),Object.defineProperty(Io()(r),"onCloudItemAction",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){var n=r.props,o=n.portabilityHeading,i=n.portabilityTitle,a=n.onOpenPortablity,s=Object(L.get)(t,"content","");if("export"===t.action){if(r.setState({portability:{id:Object(L.get)(t,"item.id",0),state:"export",heading:I("library","Export")+" "+o,title:i,cloudContent:s,fileName:Object(L.get)(t,"item.name","")}}),!s)return void a({data:t});var u=function(e){return new Promise((function(t){return setTimeout(t,e)}))};Promise.all([u(500).then((function(){return window.ETCloudApp.emitSignal({signal:"onDownloadProgress",data:{progress:150}})})),u(1e3).then((function(){return window.ETCloudApp.emitSignal({signal:"onDownloadProgress",data:{progress:200}})})),u(1200).then((function(){return window.ETCloudApp.emitSignal({signal:"finishDownload",data:{}})}))]).then((function(){a({data:t})}))}}}),Object.defineProperty(Io()(r),"openPortabilityImport",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.portabilityHeading,n=e.portabilityTitle,o=e.onOpenPortablity,i=window.ETCloudApp.getActiveFolderName();i="My Library"===i||""===i?"My":"".concat(i,"'s");var a="Import To ".concat(i," Cloud");r.setState({portability:{state:"import",heading:I("library","Import")+" "+t,title:n,cloudCheckboxLabel:a}}),o()}}),Object.defineProperty(Io()(r),"closePortability",{configurable:!0,enumerable:!0,writable:!0,value:function(){r.props.onClosePortability()}}),Object.defineProperty(Io()(r),"onExportFileNameChange",{configurable:!0,enumerable:!0,writable:!0,value:function(e){r.setState({portability:z()({},r.state.portability,{fileName:e})})}}),Object.defineProperty(Io()(r),"onPortabilityExport",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.state.portability,t=e.id,n=e.fileName,o=e.cloudContent;r.props.onPortabilityExport({id:t,fileName:n,cloudContent:o})}}),Object.defineProperty(Io()(r),"onPortabilityImport",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){var n=new FileReader;n.readAsText(e),n.onload=function(){var o=JSON.parse(n.result).snippet_type,i={title:e.name.replace(".json",""),content:n.result,type:o};r.props.onPortabilityImport({importFile:i,importToCloud:t})}}}),Object.defineProperty(Io()(r),"handleCloseBtnClick",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.onClose;e.showBackBtn?(window.ETCloudApp.goTo("back"),t()):t()}}),Object.defineProperty(Io()(r),"onShortcutKeydown",{configurable:!0,enumerable:!0,writable:!0,value:function(e){e.stopPropagation(),"Escape"!==e.key&&27!==e.keyCode||r.handleCloseBtnClick()}}),Object.defineProperty(Io()(r),"back",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props.onBackBtnClick;window.ETCloudApp.goTo("back"),e()}}),Object.defineProperty(Io()(r),"getTitle",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.detailsPageTitle,n=e.showBackBtn,o=e.title,i=n?t:o;return u.a.createElement(s.Fragment,null,u.a.createElement(hi,{className:Yo()({"et-code-snippets-library__back-button":!0,"et-code-snippets-library__back-button--visible":n}),onClick:r.back},u.a.createElement(_i,{size:"14",icon:"back",color:"#FFFFFF"})),u.a.createElement("span",{className:"et-et-code-snippets-library__title"},i))}}),e))}return Ro()(n,[{key:"componentDidMount",value:function(){f()(window).on("et_cloud_item_action",this.onCloudItemAction),window.top.document.addEventListener("keydown",this.onShortcutKeydown)}},{key:"componentWillUnmount",value:function(){f()(window).off("et_cloud_item_action",this.onCloudItemAction),window.top.document.removeEventListener("keydown",this.onShortcutKeydown)}},{key:"render",value:function(){var e=this,t=this.props,n=t.animation,r=t.showPortability,o=t.importError,i=t.importState,a=t.portabilityAllowed,s=t.isCloudActive,l=this.state.portability;return u.a.createElement("div",{className:"et-common-library-root"},u.a.createElement("div",{className:"et-common-library-overlay"}),u.a.createElement("div",{className:"et-common-library-modal-positioner"},u.a.createElement("div",{className:"et-common-library-modal"},u.a.createElement(ei,{animation:n,className:"et-common-library"},u.a.createElement(Oi,{title:this.getTitle,onClose:this.handleCloseBtnClick,additionalButton:function(){return a&&u.a.createElement(hi,{className:"et-common-library__portability-button",onClick:e.openPortabilityImport},u.a.createElement(_i,{size:"14",icon:"portability",color:"#fff"}))}}),u.a.createElement(Ai,this.props),r&&u.a.createElement(da,z()({},l,{onClose:this.closePortability,onFileNameChange:this.onExportFileNameChange,onPortabilityExport:this.onPortabilityExport,onPortabilityImport:this.onPortabilityImport,importError:o,importState:i,isCloudAvailable:s}))))))}}]),n}(s.PureComponent);Object.defineProperty(ha,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{title:Vo.a.string.isRequired,portabilityAllowed:Vo.a.bool.isRequired,animation:Vo.a.bool,importError:Vo.a.string,onClose:Vo.a.func,showPortability:Vo.a.bool,onOpenPortablity:Vo.a.func,onClosePortability:Vo.a.func}}),Object.defineProperty(ha,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{animation:!0,importError:"",onClose:L.noop}});var va=ha,ga=n(93),ma=n.n(ga),ya=n(463),ba=["className","value","options"];function wa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var _a=function(e){zo()(n,e);var t=wa(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"onClick",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.name,n=e.value;(0,e.onChange)(t,"on"===n?"off":"on")}}),e))}return Ro()(n,[{key:"render",value:function(){var e=this.props,t=e.className,n=e.value,r=e.options,o=ni()(e,ba),i="equal"===Object(L.get)(r,"type"),a=Yo()({"et-common-toggle":!0,"et-common-toggle--equal":i,"et-common-toggle--on":"on"===n,"et-common-toggle--off":"on"!==n},t),s=z()({className:a,onClick:this.onClick},o);return u.a.createElement("div",s,u.a.createElement("div",{className:"et-common-toggle__label et-common-toggle__label--on"},u.a.createElement("div",{className:"et-common-toggle__text"},r.on),u.a.createElement("div",{className:"et-common-toggle__handle"})),u.a.createElement("div",{className:"et-common-toggle__label et-common-toggle__label--off"},u.a.createElement("div",{className:"et-common-toggle__text"},r.off),u.a.createElement("div",{className:"et-common-toggle__handle"})))}}]),n}(s.PureComponent);Object.defineProperty(_a,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{name:Vo.a.string,value:Vo.a.string,onChange:Vo.a.func,options:Vo.a.object}}),Object.defineProperty(_a,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{value:"off",onChange:L.noop,options:{on:"on",off:"off",type:"default"}}});var xa=_a;function ka(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Ca=function(e){zo()(n,e);var t=ka(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"onChange",{configurable:!0,enumerable:!0,writable:!0,value:function(e){var t=r.props,n=t.selectedCategories,o=t.onCategoriesChange;if(o){var i=f()(e.target),a=parseInt(i.val()),s=i.is(":checked"),u=Object(L.includes)(n,a);o(a,s&&!u?"add":"remove")}}}),Object.defineProperty(Io()(r),"render",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.selectedCategories,n=e.allCategories,o=e.disabled,i=e.markedCategories,a=e.categoryMark,s=e.categoryClassNames;return Object(L.keys)(n).length>0?u.a.createElement("div",{className:"et-common-categories"},u.a.createElement("div",{className:"et-common-checkboxes-category-wrap"},Object(L.map)(n,(function(e,n){var l="";Object(L.isEmpty)(i)||(l=Object(L.includes)(i,e)?a:"");return u.a.createElement("p",{key:n,className:s},u.a.createElement("label",null,u.a.createElement("input",{type:"checkbox",value:n,onChange:r.onChange,checked:Object(L.includes)(t,Object(L.toInteger)(n)),disabled:o}),l,Object(L.unescape)(e)))})))):u.a.createElement("div",{className:"et-common-categories"})}}),e))}return n}(s.Component);Object.defineProperty(Ca,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{selectedCategories:Vo.a.array,allCategories:Vo.a.object,disabled:Vo.a.bool,onCategoriesChange:Vo.a.oneOfType([Vo.a.bool,Vo.a.func]),markedCategories:Vo.a.array,categoryMark:Vo.a.oneOfType([Vo.a.node,Vo.a.string])}}),Object.defineProperty(Ca,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{selectedCategories:[],allCategories:{},disabled:!1,onCategoriesChange:!1,markedCategories:[],categoryMark:""}});var Oa=Ca,Ea=n(218);function Sa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Ta=188,ja=13,Ma=function(e){zo()(n,e);var t=Sa(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"getSuggestions",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.selectedTags,n=e.allTags;if(Object(L.isEmpty)(n))return[];var o=Object(L.map)(n,(function(e,n){if(!Object(L.includes)(t,Object(L.toInteger)(n)))return{id:n,text:e}}));return Object(L.compact)(o)}}),Object.defineProperty(Io()(r),"getSelectedTags",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.selectedTags,n=e.allTags,o=e.markedTags;return Object(L.isEmpty)(t)?[]:Object(L.map)(t,(function(e){var t=""!==Object(L.get)(n,[e])?Object(L.get)(n,[e]):e,r=!1;Object(L.isEmpty)(o)||(r=Object(L.includes)(o,t));var i=r?"et-common-selected-tag-marked":"";return{id:Object(L.toString)(e),text:t,className:i}}))}}),Object.defineProperty(Io()(r),"suggestionsFilter",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){var n=Object(L.toLower)(e);return Object(L.filter)(t,(function(e){return Object(L.includes)(Object(L.toLower)(e.text),n)}))}}),Object.defineProperty(Io()(r),"onDeleteTag",{configurable:!0,enumerable:!0,writable:!0,value:function(e){r.props.onTagsChange(e,"remove",r.props.name)}}),Object.defineProperty(Io()(r),"onAddTag",{configurable:!0,enumerable:!0,writable:!0,value:function(e){r.props.onTagsChange(e,"add",r.props.name)}}),Object.defineProperty(Io()(r),"renderSuggestion",{configurable:!0,enumerable:!0,writable:!0,value:function(e,t){var n=r.props.markedTags,o=!1;Object(L.isEmpty)(n)||(o=Object(L.includes)(n,e.text));var i=o?"et-common-tag-suggestion et-common-tag-marked":"et-common-tag-suggestion";return u.a.createElement("span",{className:i},e.text)}}),Object.defineProperty(Io()(r),"render",{configurable:!0,enumerable:!0,writable:!0,value:function(){return u.a.createElement(Ea.WithContext,{tags:r.getSelectedTags(),suggestions:r.getSuggestions(),renderSuggestion:r.renderSuggestion,handleFilterSuggestions:r.suggestionsFilter,minQueryLength:0,handleDelete:r.onDeleteTag,handleAddition:r.onAddTag,autocomplete:!0,delimiters:r.props.delimiters,allowDragDrop:!1,autofocus:r.props.autofocus,placeholder:""})}}),e))}return n}(s.Component);Object.defineProperty(Ma,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{delimiters:Vo.a.array,name:Vo.a.string,allTags:Vo.a.oneOfType([Vo.a.object,Vo.a.array]),selectedTags:Vo.a.array,onTagsChange:Vo.a.oneOfType([Vo.a.bool,Vo.a.func]),autofocus:Vo.a.bool,markedTags:Vo.a.array}}),Object.defineProperty(Ma,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{delimiters:[Ta,ja],name:"TagsInput",allTags:{},selectedTags:[],onTagsChange:!1,autofocus:!1,markedTags:[],tagMark:""}});var La=Ma,Aa=n(54),Pa=n.n(Aa),Ra=n(64),Da=n.n(Ra);function Ia(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Na=null,za=function(e){zo()(n,e);var t=Ia(n);function n(e){var r;return Ao()(this,n),r=t.call(this,e),Object.defineProperty(Io()(r),"componentDidMount",{configurable:!0,enumerable:!0,writable:!0,value:function(){r.serverFramePopUp=r.loadServerFrame(),window.addEventListener("message",r.sendMessage),Na=setInterval((function(){R()(Io()(r),"serverFramePopUp.closed")&&(clearInterval(Na),r.props.onFrameClose&&r.props.onFrameClose())}),1e3)}}),Object.defineProperty(Io()(r),"componentWillUnmount",{configurable:!0,enumerable:!0,writable:!0,value:function(){window.removeEventListener("message",r.sendMessage),clearInterval(Na),Na=null,r.serverFramePopUp&&r.serverFramePopUp.close()}}),Object.defineProperty(Io()(r),"loadServerFrame",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.frameWidth,n=e.frameHeight,o=r.getFrameUrl(),i=window.top.outerWidth/2+window.top.screenX-t/2,a=window.top.outerHeight/2+window.top.screenY-n/2;return yi()(window.etServerFrameWindow)?window.open(o,"Elegantthemes","popup, width=".concat(t,", height=").concat(n,", left=").concat(i,", top=").concat(a,", toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, resizable=no, copyhistory=no")):(window.etServerFrameWindow.location.href=o,window.etServerFrameWindow)}}),Object.defineProperty(Io()(r),"getGenerateDomainTokenUrl",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.isCloud,n=e.domain,o=e.queryParams,i={domain:n,is_divi_cloud:t?1:0};return o&&(i=gi()(i,o)),i=f.a.param(i),"".concat("https://www.elegantthemes.com","/members-area/divi-cloud/token/?is_popup=1&").concat(i)}}),Object.defineProperty(Io()(r),"getFrameUrl",{configurable:!0,enumerable:!0,writable:!0,value:function(){var e=r.props,t=e.domainToken,n=e.frameUrl;return!Pa()(t)||Hi()(t)?r.getGenerateDomainTokenUrl():n}}),Object.defineProperty(Io()(r),"onDomainTokenReceived",{configurable:!0,enumerable:!0,writable:!0,value:function(e){if(Pa()(e)&&!Hi()(e)){var t=r.props,n=t.api,o=t.setDomainTokenNonce;f.a.ajax({type:"POST",url:n,data:{action:"et_builder_ajax_save_domain_token",domain_token:e,nonce:o}})}}}),Object.defineProperty(Io()(r),"sendMessage",{configurable:!0,enumerable:!0,writable:!0,value:function(e){if("https://www.elegantthemes.com"===R()(e,"origin","")){var t=R()(e,"data",{});if(Da()(t,"domain_token_generated")){var n=R()(t,"domain_token_generated");r.onDomainTokenReceived(n)}r.props.sendMessage(t)}}}),Object.defineProperty(Io()(r),"render",{configurable:!0,enumerable:!0,writable:!0,value:function(){return null}}),r}return n}(s.PureComponent);function Fa(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Ba=function(e){zo()(n,e);var t=Fa(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"_renderGraphics",value:function(){switch(this.props.icon){case"add":return u.a.createElement("g",null,u.a.createElement("path",{d:"M18 13h-3v-3a1 1 0 0 0-2 0v3h-3a1 1 0 0 0 0 2h3v3a1 1 0 0 0 2 0v-3h3a1 1 0 0 0 0-2z",fillRule:"evenodd"}));case"back":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.988 10.963h-3v-2.52a.393.393 0 0 0-.63-.361l-5.2 4.5a.491.491 0 0 0 0 .72l5.2 4.5a.393.393 0 0 0 .63-.36v-2.52h2.99a2.992 2.992 0 0 1 2.99 2.972v1.287a.7.7 0 0 0 .7.694h2.59a.7.7 0 0 0 .7-.694v-1.3a6.948 6.948 0 0 0-6.97-6.918z",fillRule:"evenodd"}));case"check":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.203 9.21a.677.677 0 0 0-.98 0l-5.71 5.9-2.85-2.95a.675.675 0 0 0-.98 0l-1.48 1.523a.737.737 0 0 0 0 1.015l4.82 4.979a.677.677 0 0 0 .98 0l7.68-7.927a.737.737 0 0 0 0-1.015l-1.48-1.525z",fillRule:"evenodd"}));case"close":case"close-small":case"multiply-by":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.59 14l4.08-4.082a1.124 1.124 0 0 0-1.587-1.588L14 12.411 9.918 8.329A1.124 1.124 0 0 0 8.33 9.92L12.411 14l-4.082 4.082a1.124 1.124 0 0 0 1.59 1.589L14 15.589l4.082 4.082a1.124 1.124 0 0 0 1.589-1.59L15.589 14h.001z",fillRule:"evenodd"}));case"column":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 8H8a1 1 0 0 0-1 1v10a1 1 0 0 0 1 1h12a1 1 0 0 0 1-1V9a1 1 0 0 0-1-.999V8zm-7 2h2v8h-2v-8zm-2 8H9v-8h2v8zm6-8h2v8h-2v-8z",fillRule:"evenodd"}));case"contract":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 19L20 9C20 8.5 19.5 8 19 8L9 8C8.5 8 8 8.5 8 9L8 19C8 19.5 8.5 20 9 20L19 20C19.5 20 20 19.5 20 19L20 19ZM18 18L10 18 10 10 18 10 18 18 18 18Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M11.5 13.5C11.8 13.5 12 13.3 12 13L12 12 13 12C13.3 12 13.5 11.8 13.5 11.5 13.5 11.2 13.3 11 13 11L11.5 11C11.2 11 11 11.2 11 11.5L11 13C11 13.3 11.2 13.5 11.5 13.5L11.5 13.5Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M16.5 11L15 11C14.7 11 14.5 11.2 14.5 11.5 14.5 11.8 14.7 12 15 12L16 12 16 13C16 13.3 16.2 13.5 16.5 13.5 16.8 13.5 17 13.3 17 13L17 11.5C17 11.2 16.8 11 16.5 11L16.5 11Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M13 16L12 16 12 15C12 14.7 11.8 14.5 11.5 14.5 11.2 14.5 11 14.7 11 15L11 16.5C11 16.8 11.2 17 11.5 17L13 17C13.3 17 13.5 16.8 13.5 16.5 13.5 16.2 13.3 16 13 16L13 16Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M16.5 14.5C16.2 14.5 16 14.7 16 15L16 16 15 16C14.7 16 14.5 16.2 14.5 16.5 14.5 16.8 14.7 17 15 17L16.5 17C16.8 17 17 16.8 17 16.5L17 15C17 14.7 16.8 14.5 16.5 14.5L16.5 14.5Z",fillRule:"evenodd"}));case"copy":return u.a.createElement("g",null,u.a.createElement("path",{d:"M16.919 15.391c.05-.124.074-.257.072-.39v-6a1.02 1.02 0 0 0-.072-.389.969.969 0 0 0-.893-.612H7.969a.97.97 0 0 0-.893.611c-.05.124-.076.256-.076.39v6c0 .134.026.266.076.39.146.365.5.604.893.605h8.057a.968.968 0 0 0 .893-.605zm3.074-3.413a1 1 0 0 0-1 1v5.011h-7.008a1 1 0 1 0 0 2h8a1 1 0 0 0 1-1v-6.013a1 1 0 0 0-.992-.998zm-5.016 2.013H8.991v-3.988h5.986v3.993-.005z",fillRule:"evenodd"}));case"delete":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 9h-3V8a1 1 0 0 0-1-1h-2a1 1 0 0 0-1 1v1H9a1 1 0 1 0 0 2h10a1 1 0 0 0 .004-2H19zM9 20c.021.543.457.979 1 1h8c.55-.004.996-.45 1-1v-7H9v7zm2.02-4.985h2v4h-2v-4zm4 0h2v4h-2v-4z",fillRule:"evenodd"}));case"desktop":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 7H8C7.5 7 7 7.5 7 8v10c0 0.5 0.5 1 1 1h5v1h-1c-0.5 0-1 0.5-1 1s0.5 1 1 1h4c0.5 0 1-0.5 1-1s-0.5-1-1-1h-1v-1h5c0.5 0 1-0.5 1-1V8C21 7.5 20.5 7 20 7zM15 18h-2v-1h2V18zM19 16H9V9h10V16z",fillRule:"evenodd"}));case"grid":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 7H8C7.5 7 7 7.5 7 8v12c0 0.5 0.5 1 1 1h12c0.5 0 1-0.5 1-1V8C21 7.5 20.5 7 20 7zM15 9v2h-2V9H15zM15 13v2h-2v-2H15zM9 9h2v2H9V9zM9 13h2v2H9V13zM9 19v-2h2v2H9zM13 19v-2h2v2H13zM19 19h-2v-2h2V19zM19 15h-2v-2h2V15zM19 11h-2V9h2V11z",fillRule:"evenodd"}));case"wireframe":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 7H8C7.5 7 7 7.5 7 8v4c0 0.5 0.5 1 1 1h12c0.5 0 1-0.5 1-1V8C21 7.5 20.5 7 20 7zM19 11H9V9h10V11z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M12 15H8c-0.5 0-1 0.5-1 1v4c0 0.5 0.5 1 1 1h4c0.5 0 1-0.5 1-1v-4C13 15.5 12.5 15 12 15zM11 19H9v-2h2V19z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M20 15h-4c-0.5 0-1 0.5-1 1v4c0 0.5 0.5 1 1 1h4c0.5 0 1-0.5 1-1v-4C21 15.5 20.5 15 20 15zM19 19h-2v-2h2V19z",fillRule:"evenodd"}));case"exit":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.71 16.857l-2.85-2.854 2.85-2.854c.39-.395.39-1.03 0-1.426l-1.43-1.427a1 1 0 0 0-1.42 0L14 11.15l-2.85-2.854a1.013 1.013 0 0 0-1.43 0L8.3 9.723a1 1 0 0 0 0 1.426l2.85 2.854-2.85 2.853a1 1 0 0 0 0 1.427l1.42 1.427a1.011 1.011 0 0 0 1.43 0L14 16.856l2.86 2.854a1 1 0 0 0 1.42 0l1.43-1.427c.39-.395.39-1.03 0-1.426z",fillRule:"evenodd"}));case"expand":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17 16L17 12C17 11.5 16.5 11 16 11L12 11C11.5 11 11 11.5 11 12L11 16C11 16.5 11.5 17 12 17L16 17C16.5 17 17 16.5 17 16L17 16ZM15 15L13 15 13 13 15 13 15 15 15 15Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M8.5 12C8.8 12 9 11.8 9 11.5L9 9 11.5 9C11.8 9 12 8.8 12 8.5 12 8.2 11.8 8 11.5 8L8.5 8C8.2 8 8 8.2 8 8.5L8 11.5C8 11.8 8.2 12 8.5 12L8.5 12Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M19.5 8L16.5 8C16.2 8 16 8.2 16 8.5 16 8.8 16.2 9 16.5 9L19 9 19 11.5C19 11.8 19.2 12 19.5 12 19.8 12 20 11.8 20 11.5L20 8.5C20 8.2 19.8 8 19.5 8L19.5 8Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M11.5 19L9 19 9 16.5C9 16.2 8.8 16 8.5 16 8.2 16 8 16.2 8 16.5L8 19.5C8 19.8 8.2 20 8.5 20L11.5 20C11.8 20 12 19.8 12 19.5 12 19.2 11.8 19 11.5 19L11.5 19Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M19.5 16C19.2 16 19 16.2 19 16.5L19 19 16.5 19C16.2 19 16 19.2 16 19.5 16 19.8 16.2 20 16.5 20L19.5 20C19.8 20 20 19.8 20 19.5L20 16.5C20 16.2 19.8 16 19.5 16L19.5 16Z",fillRule:"evenodd"}));case"heading-four":return u.a.createElement("g",null,u.a.createElement("path",{d:"M8 12.983h5V9a1 1 0 0 1 2 0v9.956a1 1 0 0 1-2 0v-3.973H8v3.973a1 1 0 0 1-2 0V9a1 1 0 1 1 2 0v3.983zm14 5.66h-.75v1.288h-1.29v-1.288h-2.67v-.914l2.74-4.013h1.22v3.907H22v1.02zm-2.04-1.02v-1.055c0-.175.01-.431.02-.764s.03-.529.03-.584h-.03a5.039 5.039 0 0 1-.38.681l-1.14 1.722h1.5z",fillRule:"evenodd"}));case"heading-one":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13 14.983H8v3.973a1 1 0 0 1-2 0V9a1 1 0 1 1 2 0v3.983h5V9a1 1 0 0 1 2 0v9.956a1 1 0 0 1-2 0v-3.973zm8.1 4.951h-1.32v-3.6l.01-.591.02-.645c-.146.15-.3.294-.46.428l-.71.574-.64-.79 2.01-1.594h1.09v6.218z",fillRule:"evenodd"}));case"heading-three":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13 14.983H8v3.973a1 1 0 0 1-2 0V9a1 1 0 1 1 2 0v3.983h5V9a1 1 0 0 1 2 0v9.956a1 1 0 0 1-2 0v-3.973zm8.65.125c.01.364-.12.718-.36.991-.26.29-.608.487-.99.561v.026a1.97 1.97 0 0 1 1.14.456c.265.256.407.613.39.981.03.546-.214 1.07-.65 1.4a3.04 3.04 0 0 1-1.87.5 4.6 4.6 0 0 1-1.8-.336v-1.118c.256.127.524.228.8.3.28.075.57.114.86.115a1.7 1.7 0 0 0 .97-.221.8.8 0 0 0 .31-.709.642.642 0 0 0-.36-.622 2.669 2.669 0 0 0-1.14-.183h-.48v-1.007h.49c.363.023.727-.042 1.06-.189a.687.687 0 0 0 .33-.648.714.714 0 0 0-.89-.706c-.21 0-.42.035-.62.1-.25.087-.49.206-.71.353l-.61-.906a3.419 3.419 0 0 1 2.04-.612 2.652 2.652 0 0 1 1.53.392c.36.24.572.649.56 1.082z",fillRule:"evenodd"}));case"heading-two":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13 14.983H8v3.973a1 1 0 0 1-2 0V9a1 1 0 1 1 2 0v3.983h5V9a1 1 0 0 1 2 0v9.956a1 1 0 0 1-2 0v-3.973zm8.99 4.951h-4.36v-.914l1.57-1.577c.46-.474.76-.8.91-.985a2.1 2.1 0 0 0 .3-.508c.063-.154.097-.318.1-.484a.7.7 0 0 0-.21-.557.8.8 0 0 0-.55-.183c-.246 0-.49.057-.71.166a3.6 3.6 0 0 0-.71.471l-.72-.845a4.47 4.47 0 0 1 .77-.553c.209-.11.43-.194.66-.249.262-.06.53-.09.8-.087.355-.008.707.065 1.03.213.285.13.527.339.7.6.165.262.252.566.25.876.002.275-.049.549-.15.805-.122.277-.28.536-.47.772-.35.398-.725.774-1.12 1.127l-.81.752v.059h2.72v1.106-.005z",fillRule:"evenodd"}));case"help":return u.a.createElement("g",null,u.a.createElement("circle",{cx:"14",cy:"19",r:"1"}),u.a.createElement("path",{d:"M13 16a3.17 3.17 0 0 1 1.59-2.68c.74-.46 1.41-.8 1.41-1.82 0-.5-.45-1.5-2-1.5-1.73 0-2 .95-2 1-.12.6-.33 1-1 1-.67 0-1.12-.4-1-1a3.89 3.89 0 0 1 4-3 3.68 3.68 0 0 1 4 3.5 3.72 3.72 0 0 1-2.23 3.5 1.53 1.53 0 0 0-.77 1 .93.93 0 0 1-1 1 .93.93 0 0 1-1-1z"}));case"help-circle":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14 22a8 8 0 1 1 0-16 8 8 0 0 1 0 16zm0-3.6a.8.8 0 1 0 0-1.6.8.8 0 0 0 0 1.6zm-.8-3.2a.744.744 0 0 0 .8.8.744.744 0 0 0 .8-.8c.08-.343.305-.634.616-.8a2.976 2.976 0 0 0 1.784-2.8A2.944 2.944 0 0 0 14 8.8a3.112 3.112 0 0 0-3.2 2.4c-.096.48.264.8.8.8s.704-.32.8-.8c0-.04.216-.8 1.6-.8 1.24 0 1.6.8 1.6 1.2 0 .816-.536 1.088-1.128 1.456A2.536 2.536 0 0 0 13.2 15.2z"}));case"history":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14 6.5C9.9 6.5 6.5 9.9 6.5 14 6.5 18.1 9.9 21.5 14 21.5 18.1 21.5 21.5 18.1 21.5 14 21.5 9.9 18.1 6.5 14 6.5L14 6.5ZM14 19.5C11 19.5 8.5 17 8.5 14 8.5 11 11 8.5 14 8.5 17 8.5 19.5 11 19.5 14 19.5 17 17 19.5 14 19.5L14 19.5Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M17 13L15 13 15 11C15 10.5 14.5 10 14 10 13.5 10 13 10.5 13 11L13 14C13 14.5 13.5 15 14 15L17 15C17.5 15 18 14.5 18 14 18 13.5 17.5 13 17 13L17 13Z",fillRule:"evenodd"}));case"indent":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 10H8a1 1 0 1 1 0-2h12a1 1 0 1 1 0 2zm0 10H8a1 1 0 0 1 0-2h12a1 1 0 1 1 0 2zm0-5h-7a1 1 0 0 1 0-2h7a1 1 0 1 1 0 2zM7.77 11.978l2.55 1.6a.5.5 0 0 1 0 .848l-2.55 1.6a.5.5 0 0 1-.77-.424v-3.2a.5.5 0 0 1 .77-.424z",fillRule:"evenodd"}));case"letter-spacing-small":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15 19V9a1 1 0 0 1 2 0v10a1 1 0 0 1-2 0zm-4 0V9a1 1 0 0 1 2 0v10a1 1 0 0 1-2 0z",fillRule:"evenodd"}));case"letter-spacing":return u.a.createElement("g",null,u.a.createElement("path",{d:"M18 19V9a1 1 0 0 1 2 0v10a1 1 0 0 1-2 0zM8 19V9a1 1 0 1 1 2 0v10a1 1 0 0 1-2 0z",fillRule:"evenodd"}));case"line-height-small":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 13H9a1 1 0 0 1 0-2h10a1 1 0 0 1 0 2zm0 4H9a1 1 0 0 1 0-2h10a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"line-height":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 10H9a1 1 0 1 1 0-2h10a1 1 0 0 1 0 2zm0 10H9a1 1 0 0 1 0-2h10a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"list":return u.a.createElement("g",null,u.a.createElement("path",{d:"M7 10a1 1 0 1 1 0-2 1 1 0 0 1 0 2zm0 5a1 1 0 1 1 0-2 1 1 0 0 1 0 2zm0 5a1 1 0 1 1 0-2 1 1 0 0 1 0 2zm11-10h-7a1 1 0 0 1 0-2h7a1 1 0 0 1 0 2zm2 5h-9a1 1 0 0 1 0-2h9a1 1 0 0 1 0 2zm-2 5h-7a1 1 0 0 1 0-2h7a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"loading":return u.a.createElement("g",null,u.a.createElement("circle",{className:"et-fb-icon__circle et-fb-icon__circle--1",cx:"2",cy:"2",r:"2",transform:"translate(4 12)"}),u.a.createElement("circle",{className:"et-fb-icon__circle et-fb-icon__circle--2",cx:"2.3",cy:"2.7",r:"2",transform:"rotate(72 4.397 10.865)"}),u.a.createElement("circle",{className:"et-fb-icon__circle et-fb-icon__circle--3",cx:"2.3",cy:"2.2",r:"2",transform:"rotate(144 10.216 8.724)"}),u.a.createElement("circle",{className:"et-fb-icon__circle et-fb-icon__circle--4",cx:"2.6",cy:"2",r:"2",transform:"rotate(-144 14.235 7.453)"}),u.a.createElement("circle",{className:"et-fb-icon__circle et-fb-icon__circle--5",cx:"2.8",cy:"2.1",r:"2",transform:"rotate(-72 20.635 5.838)"}));case"move":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.91,13.78l-1.85-1.85c-0.14-0.14-0.33-0.22-0.53-0.22c-0.2,0-0.39,0.08-0.53,0.22c-0.14,0.14-0.22,0.33-0.22,0.53S17.86,12.86,18,13v0h-2.94v-2.96c0.13,0.11,0.3,0.19,0.48,0.19c0.2,0,0.39-0.08,0.53-0.22c0.14-0.14,0.22-0.33,0.22-0.53s-0.08-0.39-0.22-0.53l-1.85-1.85C14.17,7.03,14.09,7,14,7s-0.16,0.03-0.22,0.09l-1.85,1.85c-0.14,0.14-0.22,0.33-0.22,0.53s0.08,0.39,0.22,0.53c0.14,0.14,0.33,0.22,0.53,0.22S12.86,10.14,13,10h0.06v3H10v0c0.14-0.14,0.22-0.33,0.22-0.53s-0.08-0.39-0.22-0.53c-0.14-0.14-0.33-0.22-0.53-0.22c-0.2,0-0.39,0.08-0.53,0.22L7.1,13.78C7.04,13.84,7,13.92,7,14c0,0.08,0.03,0.16,0.09,0.22l1.85,1.85c0.14,0.14,0.33,0.22,0.53,0.22c0.2,0,0.39-0.08,0.53-0.22c0.14-0.14,0.22-0.33,0.22-0.53c0-0.2-0.08-0.39-0.22-0.53v0h3.06v3H13c-0.14-0.14-0.33-0.22-0.53-0.22s-0.39,0.08-0.53,0.22c-0.14,0.14-0.22,0.33-0.22,0.53c0,0.2,0.08,0.39,0.22,0.53l1.85,1.85C13.84,20.97,13.92,21,14,21s0.16-0.03,0.22-0.09l1.85-1.85c0.14-0.14,0.22-0.33,0.22-0.53c0-0.2-0.08-0.39-0.22-0.53c-0.14-0.14-0.33-0.22-0.53-0.22c-0.18,0-0.34,0.07-0.48,0.19V15H18v0c-0.14,0.14-0.22,0.33-0.22,0.53c0,0.2,0.08,0.39,0.22,0.53c0.14,0.14,0.33,0.22,0.53,0.22c0.2,0,0.39-0.08,0.53-0.22l1.85-1.85C20.97,14.16,21,14.08,21,14C21,13.92,20.97,13.84,20.91,13.78z"}));case"position-move":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21,14a.31.31,0,0,1-.09.22l-1.85,1.85a.75.75,0,0,1-1.28-.53A.77.77,0,0,1,18,15h0a1.42,1.42,0,0,0,0-2h0a.77.77,0,0,1-.22-.54.75.75,0,0,1,1.28-.53l1.85,1.85A.31.31,0,0,1,21,14Zm-4.93,4a.75.75,0,0,0-.53-.22.77.77,0,0,0-.48.18L15,18a1.41,1.41,0,0,1-2,0l0,0a.75.75,0,0,0-1.06,0,.73.73,0,0,0,0,1.06l1.84,1.85A.31.31,0,0,0,14,21a.28.28,0,0,0,.22-.09l1.85-1.85a.75.75,0,0,0,0-1.06ZM10,15a1.42,1.42,0,0,1,0-2h0a.78.78,0,0,0,.23-.54.75.75,0,0,0-.22-.53.77.77,0,0,0-.54-.22.75.75,0,0,0-.53.22L7.1,13.78a.29.29,0,0,0,0,.44l1.84,1.85a.75.75,0,0,0,.53.22.77.77,0,0,0,.54-.22.75.75,0,0,0,.22-.53A.78.78,0,0,0,10,15Zm6.07-6.06L14.22,7.09A.28.28,0,0,0,14,7a.31.31,0,0,0-.22.09L11.94,8.94a.73.73,0,0,0,0,1.06A.75.75,0,0,0,13,10l0,0a1.41,1.41,0,0,1,2,0l.05.06a.77.77,0,0,0,.48.18.75.75,0,0,0,.53-1.28Zm0,5.06a2,2,0,1,0-2,2A2,2,0,0,0,16.06,14Z"}));case"position-horizontal":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21,14a.31.31,0,0,1-.09.22l-1.85,1.85a.75.75,0,0,1-1.28-.53A.77.77,0,0,1,18,15h0a1.42,1.42,0,0,0,0-2h0a.77.77,0,0,1-.22-.54.75.75,0,0,1,1.28-.53l1.85,1.85A.31.31,0,0,1,21,14ZM10,15a1.42,1.42,0,0,1,0-2h0a.78.78,0,0,0,.23-.54.75.75,0,0,0-.22-.53.77.77,0,0,0-.54-.22.75.75,0,0,0-.53.22L7.1,13.78a.29.29,0,0,0,0,.44l1.84,1.85a.75.75,0,0,0,.53.22.77.77,0,0,0,.54-.22.75.75,0,0,0,.22-.53A.78.78,0,0,0,10,15Zm6.06-1a2,2,0,1,0-2,2A2,2,0,0,0,16.06,14Z"}),u.a.createElement("path",{style:{opacity:.2},d:"M16.29,18.53a.75.75,0,0,1-.22.53l-1.85,1.85A.28.28,0,0,1,14,21a.31.31,0,0,1-.22-.09l-1.84-1.85a.73.73,0,0,1,0-1.06A.75.75,0,0,1,13,18l0,0a1.41,1.41,0,0,0,2,0l.05-.06a.77.77,0,0,1,.48-.18.75.75,0,0,1,.75.75Zm-.22-9.59L14.22,7.09A.28.28,0,0,0,14,7a.31.31,0,0,0-.22.09L11.94,8.94a.73.73,0,0,0,0,1.06A.75.75,0,0,0,13,10l0,0a1.41,1.41,0,0,1,2,0l.05.06a.77.77,0,0,0,.48.18.75.75,0,0,0,.53-1.28Z"}));case"position-vertical":return u.a.createElement("g",null,u.a.createElement("path",{style:{opacity:.2},d:"M21,14a.31.31,0,0,1-.09.22l-1.85,1.85a.75.75,0,0,1-1.28-.53A.77.77,0,0,1,18,15h0a1.42,1.42,0,0,0,0-2h0a.77.77,0,0,1-.22-.54.75.75,0,0,1,1.28-.53l1.85,1.85A.31.31,0,0,1,21,14ZM10,15a1.42,1.42,0,0,1,0-2h0a.78.78,0,0,0,.23-.54.75.75,0,0,0-.22-.53.77.77,0,0,0-.54-.22.75.75,0,0,0-.53.22L7.1,13.78a.29.29,0,0,0,0,.44l1.84,1.85a.75.75,0,0,0,.53.22.77.77,0,0,0,.54-.22.75.75,0,0,0,.22-.53A.78.78,0,0,0,10,15Z"}),u.a.createElement("path",{d:"M14.06,16a2,2,0,1,1,2-2A2,2,0,0,1,14.06,16Zm2,2a.75.75,0,0,0-.53-.22.77.77,0,0,0-.48.18L15,18a1.41,1.41,0,0,1-2,0l0,0a.75.75,0,0,0-1.06,0,.73.73,0,0,0,0,1.06l1.84,1.85A.31.31,0,0,0,14,21a.28.28,0,0,0,.22-.09l1.85-1.85a.75.75,0,0,0,0-1.06Zm0-9.06L14.22,7.09A.28.28,0,0,0,14,7a.31.31,0,0,0-.22.09L11.94,8.94a.73.73,0,0,0,0,1.06A.75.75,0,0,0,13,10l0,0a1.41,1.41,0,0,1,2,0l.05.06a.77.77,0,0,0,.48.18.75.75,0,0,0,.53-1.28Z"}));case"numbered-list":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.08 20H7.5a.5.5 0 1 1 0-1h.78l-.14-.146a.492.492 0 0 1 0-.707L8.28 18H7.5a.5.5 0 1 1 0-1h1.58a.653.653 0 0 1 .61.412.672.672 0 0 1-.14.726l-.36.362.36.362a.672.672 0 0 1 .14.726.653.653 0 0 1-.61.412zm8.91-10h-5a1 1 0 1 1 0-2h5a1 1 0 0 1 0 2zm3 5h-8a1 1 0 1 1 0-2h8a1 1 0 0 1 0 2zm-3 5h-5a1 1 0 1 1 0-2h5a1 1 0 0 1 0 2zm-8.51-5H7.5a.482.482 0 0 1-.46-.309.5.5 0 0 1 .1-.544L8.28 13H7.5a.5.5 0 1 1 0-1h1.59a.661.661 0 0 1 .47 1.126L8.69 14h.79a.5.5 0 0 1 0 1zm-.99-4a.5.5 0 0 1-.5-.5V9a.5.5 0 1 1 0-1h.5a.5.5 0 0 1 .49.5v2a.5.5 0 0 1-.49.5z",fillRule:"evenodd"}));case"paint":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.489 8.364a.9.9 0 0 0-.641-.26c-.281.003-.55.117-.746.318l-1.611 1.615-1.8-1.8a1 1 0 0 0-1.408 1.41l1.8 1.8-2.767 2.776a.988.988 0 0 0-.057 1.39l4.56 4.573a.9.9 0 0 0 .64.26 1.06 1.06 0 0 0 .747-.317l6.052-6.068a.624.624 0 0 0 .036-.875l-4.805-4.822zm1.07 6.583a4.34 4.34 0 0 1-6.15 0l2.082-2.087 1.017 1.019a1 1 0 1 0 1.408-1.411l-1.017-1.02.925-.928 3.075 3.084-1.34 1.343zm2.39 4.388a1.5 1.5 0 1 0 2.986 0c0-1.278-1.493-4.4-1.493-4.4s-1.493 3.067-1.493 4.4z",fillRule:"evenodd"}));case"phone":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17 7h-6c-0.5 0-1 0.5-1 1v12c0 0.5 0.5 1 1 1h6c0.5 0 1-0.5 1-1V8C18 7.5 17.5 7 17 7zM15 20h-2v-1h2V20zM16 18h-4V9h4V18z",fillRule:"evenodd"}));case"preview-link":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17.586 9l-4.536 4.535a1 1 0 1 0 1.414 1.415L19 10.415V12a1 1 0 0 0 2 0V8a.997.997 0 0 0-1-1h-4a1 1 0 0 0 0 2h1.586zm3.121 11.707A.997.997 0 0 1 20 21H8a.997.997 0 0 1-1-1V8a.997.997 0 0 1 1-1h4a1 1 0 0 1 0 2H9v10h10v-3a1 1 0 0 1 2 0v4a.997.997 0 0 1-.293.707z"}));case"redo":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.986 7l-1.78 1.78c-1.255-.967-2.835-1.501-4.575-1.527-3.845-.057-7.195 2.624-7.59 6.45C6.577 18.2 10.092 22 14.493 22c1.94 0 3.701-.736 5.031-1.945a.674.674 0 0 0 .032-.979l-1.184-1.175a.655.655 0 0 0-.901-.026c-.791.72-1.83 1.182-2.978 1.182-2.671 0-4.798-2.258-4.46-5.008.273-2.22 2.299-3.831 4.534-3.8a4.51 4.51 0 0 1 2.44.734l-2.014 2.014c0 .552.447.999.999.999h4.994a.998.998 0 0 0 1-1V8a1 1 0 0 0-1-1z",fillRule:"evenodd"}));case"reset":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.596 8.95a6.811 6.811 0 0 1 9.384-.15 6.661 6.661 0 0 1 .08 9.477 6.421 6.421 0 0 1-4.62 1.931c-.21 0-.42 0-.63-.017A6.084 6.084 0 0 1 9 17.151l5.45.005a3.274 3.274 0 0 0 3.26-3.3 3.418 3.418 0 0 0-3.41-3.314c-.83 0-1.626.321-2.224.89l1.764 1.755a.556.556 0 0 1-.4.948H7.56A.557.557 0 0 1 7 13.58V7.695a.557.557 0 0 1 .95-.393L9.596 8.95z",fillRule:"evenodd"}));case"resize":return u.a.createElement("g",null,u.a.createElement("path",{d:"M11.715 12.858l-2.292-2.291a1.885 1.885 0 0 1-1.381 1.524A1.041 1.041 0 0 1 7 11.049V7.431C7 7.193 7.193 7 7.431 7h3.618c.575 0 1.041.467 1.042 1.042a1.884 1.884 0 0 1-1.523 1.38l2.292 2.291 5.728 5.728a1.886 1.886 0 0 1 1.37-1.532c.575 0 1.041.467 1.042 1.042v3.618a.431.431 0 0 1-.431.431h-3.618a1.043 1.043 0 0 1-1.042-1.042 1.887 1.887 0 0 1 1.533-1.371l-5.728-5.728z",fillRule:"evenodd"}));case"save":return u.a.createElement("g",null,u.a.createElement("path",{d:"M18.95 9.051a1 1 0 1 0-1.414 1.414 5 5 0 1 1-7.07 0A1 1 0 0 0 9.05 9.051a7 7 0 1 0 9.9.001v-.001zm-5.378 8.235a.5.5 0 0 0 .857 0l2.117-3.528a.5.5 0 0 0-.429-.758H15V8a1 1 0 0 0-2 0v5h-1.117a.5.5 0 0 0-.428.758l2.117 3.528z",fillRule:"evenodd"}));case"setting":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.426 13.088l-1.383-.362a.874.874 0 0 1-.589-.514l-.043-.107a.871.871 0 0 1 .053-.779l.721-1.234a.766.766 0 0 0-.116-.917 6.682 6.682 0 0 0-.252-.253.768.768 0 0 0-.917-.116l-1.234.722a.877.877 0 0 1-.779.053l-.107-.044a.87.87 0 0 1-.513-.587l-.362-1.383a.767.767 0 0 0-.73-.567h-.358a.768.768 0 0 0-.73.567l-.362 1.383a.878.878 0 0 1-.513.589l-.107.044a.875.875 0 0 1-.778-.054l-1.234-.722a.769.769 0 0 0-.918.117c-.086.082-.17.166-.253.253a.766.766 0 0 0-.115.916l.721 1.234a.87.87 0 0 1 .053.779l-.043.106a.874.874 0 0 1-.589.514l-1.382.362a.766.766 0 0 0-.567.731v.357a.766.766 0 0 0 .567.731l1.383.362c.266.07.483.26.588.513l.043.107a.87.87 0 0 1-.053.779l-.721 1.233a.767.767 0 0 0 .115.917c.083.087.167.171.253.253a.77.77 0 0 0 .918.116l1.234-.721a.87.87 0 0 1 .779-.054l.107.044a.878.878 0 0 1 .513.589l.362 1.383a.77.77 0 0 0 .731.567h.356a.766.766 0 0 0 .73-.567l.362-1.383a.878.878 0 0 1 .515-.589l.107-.044a.875.875 0 0 1 .778.054l1.234.721c.297.17.672.123.917-.117.087-.082.171-.166.253-.253a.766.766 0 0 0 .116-.917l-.721-1.234a.874.874 0 0 1-.054-.779l.044-.107a.88.88 0 0 1 .589-.513l1.383-.362a.77.77 0 0 0 .567-.731v-.357a.772.772 0 0 0-.569-.724v-.005zm-6.43 3.9a2.986 2.986 0 1 1 2.985-2.986 3 3 0 0 1-2.985 2.987v-.001z",fillRule:"evenodd"}));case"sidebar":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 8L9 8C8.5 8 8 8.5 8 9L8 19C8 19.5 8.5 20 9 20L19 20C19.5 20 20 19.5 20 19L20 9C20 8.5 19.5 8 19 8L19 8ZM10 10L12 10 12 12 10 12 10 10 10 10ZM10 13L12 13 12 15 10 15 10 13 10 13ZM10 18L10 16 12 16 12 18 10 18 10 18ZM18 18L14 18 14 10 18 10 18 18 18 18Z",fillRule:"evenodd"}));case"tablet":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 7H9C8.5 7 8 7.5 8 8v12c0 0.5 0.5 1 1 1h10c0.5 0 1-0.5 1-1V8C20 7.5 19.5 7 19 7zM15 20h-2v-1h2V20zM18 18h-8V9h8V18z",fillRule:"evenodd"}));case"text-bold":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17.337 13.535c.43-.591.662-1.304.663-2.035A3.51 3.51 0 0 0 14.5 8h-3c-.114 0-.221.023-.333.034A.933.933 0 0 0 11 8a.969.969 0 0 0-.53.174A.982.982 0 0 0 10 9v10c.005.338.182.65.47.827.156.108.34.168.53.173a.933.933 0 0 0 .167-.034c.112.011.219.034.333.034h4a3.51 3.51 0 0 0 3.5-3.5 3.494 3.494 0 0 0-1.667-2.965h.004zM16 11.5a1.5 1.5 0 0 1-1.5 1.5H12v-3h2.5a1.5 1.5 0 0 1 1.5 1.5zm1 5a1.5 1.5 0 0 1-1.5 1.5H12v-3h3.5a1.5 1.5 0 0 1 1.5 1.5z",fillRule:"evenodd"}));case"text-center":return u.a.createElement("g",null,u.a.createElement("path",{d:"M18 10h-8a1 1 0 1 1 0-2h8a1 1 0 0 1 0 2zm2 5H8a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2zm-2 5h-8a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"text-italic":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17 8h-5c-.6 0-1 .4-1 1s.4 1 1 1h1.3l-2.1 8H10c-.6 0-1 .4-1 1s.4 1 1 1h5c.6 0 1-.4 1-1s-.4-1-1-1h-1.7l2.1-8H17c.6 0 1-.4 1-1s-.4-1-1-1z",fillRule:"evenodd"}));case"text-justify":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 20H8a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2zm0-10H8a1 1 0 1 1 0-2h12a1 1 0 0 1 0 2zM8 15a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2H8z",fillRule:"evenodd"}));case"text-large":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.38 8.96a1.006 1.006 0 0 0-.65-.9.942.942 0 0 0-.28-.046c-.03 0-.06-.013-.09-.014-.03 0-.06.011-.09.014a.942.942 0 0 0-.28.045.991.991 0 0 0-.65.9l-4.28 9.622c-.187.52.075 1.093.59 1.291a.992.992 0 0 0 1.28-.592l1.19-2.272h4.47l1.2 2.272a.994.994 0 1 0 1.86-.7l-4.27-9.62zm-2.52 6.042l1.5-3.039 1.5 3.04h-3z",fillRule:"evenodd"}));case"text-left":return u.a.createElement("g",null,u.a.createElement("path",{d:"M16 20H8a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2zm0-10H8a1 1 0 1 1 0-2h8a1 1 0 0 1 0 2zm4 5H8a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"text-link":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.726 7.274a.935.935 0 0 0-1.322 0l-1.849 1.85-.67-.67a3.06 3.06 0 0 0-4.226 0l-4.225 4.225a2.998 2.998 0 0 0 0 4.227l.669.67-1.85 1.85a.935.935 0 0 0 1.322 1.321l1.85-1.85.668.67a2.99 2.99 0 0 0 4.228 0l4.224-4.225a2.998 2.998 0 0 0 0-4.227l-.67-.67 1.85-1.85a.935.935 0 0 0 .001-1.321zm-2.498 5.162a1.123 1.123 0 0 1 0 1.584l-4.223 4.225a1.146 1.146 0 0 1-1.583 0l-.669-.67 1.581-1.582a.937.937 0 1 0-1.328-1.321l-1.582 1.581-.669-.669a1.122 1.122 0 0 1 0-1.584l4.225-4.224a1.12 1.12 0 0 1 1.583 0l.67.67-1.582 1.58a.935.935 0 0 0 1.322 1.322l1.581-1.582.674.67z",fillRule:"evenodd"}));case"text-quote":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.437 9.049a2 2 0 1 0 1.186 3.116c.264.574.394 1.2.381 1.833 0 2.116-1.118 3.998-1.999 3.998a1 1 0 1 0 0 2c2.392 0 3.999-3.1 3.999-5.998 0-2.709-1.48-4.698-3.567-4.949zm7.997 0a2 2 0 1 0 1.186 3.116c.263.574.393 1.2.38 1.833 0 2.116-1.117 3.998-1.998 3.998a1 1 0 1 0 0 2c2.392 0 3.998-3.1 3.998-5.998 0-2.709-1.48-4.698-3.566-4.949z",fillRule:"evenodd"}));case"text-right":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 15H8a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2zm0-5h-8a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2zm0 10h-8a1 1 0 0 1 0-2h8a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"text-small":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.168 10.639a.672.672 0 0 0-.424-.6.6.6 0 0 0-.186-.03c-.02 0-.038-.009-.057-.009a.521.521 0 0 0-.057.009.6.6 0 0 0-.186.03.672.672 0 0 0-.424.6l-2.792 6.448a.681.681 0 0 0 .384.865.645.645 0 0 0 .836-.4L12 15.997h3l.738 1.558a.646.646 0 0 0 .837.4.68.68 0 0 0 .383-.865l-2.791-6.451zm-1.645 4.315l.978-2.3.978 2.3h-1.956z",fillRule:"evenodd"}));case"text-underline":return u.a.createElement("g",null,u.a.createElement("path",{d:"M8 21h12c.6 0 1 .4 1 1s-.4 1-1 1H8c-.6 0-1-.4-1-1s.4-1 1-1zM10 8c.6 0 1 .4 1 1v6c0 1.7 1.3 3 3 3s3-1.3 3-3V9c0-.6.4-1 1-1s1 .4 1 1v6c0 2.8-2.2 5-5 5s-5-2.2-5-5V9c0-.6.4-1 1-1z",fillRule:"evenodd"}));case"text-underline-double":return u.a.createElement("g",null,u.a.createElement("path",{d:"M8.5 23h11a.5.5 0 0 1 0 1h-11a.5.5 0 0 1 0-1zM8.5 21h11a.5.5 0 0 1 0 1h-11a.5.5 0 0 1 0-1zM10 8a1 1 0 0 1 1 1v6a3 3 0 1 0 6 0V9a1 1 0 0 1 2 0v6a5 5 0 0 1-10 0V9a1 1 0 0 1 1-1z",fillRule:"evenodd"}));case"text-strikethrough":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.8 13c-.1 0-.2-.1-.3-.1C11.6 11.7 11 10 12.1 9c.9-.9 3.4-.4 3.7.5.2.5.7.8 1.3.6.5-.2.8-.7.6-1.3-.8-2.4-5.1-3.3-7-1.3-1.6 1.6-1.4 3.8.3 5.5H7c-.6 0-1 .4-1 1s.4 1 1 1h7.3c2.3 1.1 2.7 2.5 1.7 3.7-1.1 1.3-3.4 1.2-4.7-.8-.3-.5-.9-.6-1.4-.3-.5.3-.6.9-.3 1.4 2 3.2 5.9 3.3 7.9 1 1.3-1.5 1.3-3.4 0-5H21c.6 0 1-.4 1-1s-.4-1-1-1h-6.2z",fillRule:"evenodd"}));case"text-smallcaps":return u.a.createElement("g",null,u.a.createElement("path",{d:"M11 10h2c.6 0 1-.4 1-1s-.4-1-1-1H7c-.6 0-1 .4-1 1s.4 1 1 1h2v9c0 .6.4 1 1 1s1-.4 1-1v-9zm8 4v5c0 .6-.4 1-1 1s-1-.4-1-1v-5h-2c-.6 0-1-.4-1-1s.4-1 1-1h6c.6 0 1 .4 1 1s-.4 1-1 1h-2z",fillRule:"evenodd"}));case"text-uppercase":return u.a.createElement("g",null,u.a.createElement("path",{d:"M10 10h2c.6 0 1-.4 1-1s-.4-1-1-1H6c-.6 0-1 .4-1 1s.4 1 1 1h2v9c0 .6.4 1 1 1s1-.4 1-1v-9zm10 0v9c0 .6-.4 1-1 1s-1-.4-1-1v-9h-2c-.6 0-1-.4-1-1s.4-1 1-1h6c.6 0 1 .4 1 1s-.4 1-1 1h-2z",fillRule:"evenodd"}));case"text-h1":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21 19.934h-1.32v-3.6l.01-.591.02-.645c-.146.15-.3.294-.46.428l-.71.574-.64-.79 2.01-1.594H21v6.218zM13 9v4H8V9a1 1 0 0 0-2 0v10a1 1 0 0 0 2 0v-4h5v4a1 1 0 0 0 2 0V9a1 1 0 0 0-2 0z",fillRule:"evenodd"}));case"text-h2":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21.99 19.934h-4.36v-.914l1.57-1.577c.46-.474.76-.8.91-.985.123-.154.224-.325.3-.508.063-.154.097-.318.1-.484a.702.702 0 0 0-.21-.557.797.797 0 0 0-.55-.183c-.246 0-.49.057-.71.166a3.574 3.574 0 0 0-.71.471l-.72-.845a4.47 4.47 0 0 1 .77-.553c.209-.11.43-.194.66-.249.262-.06.53-.09.8-.087.355-.008.707.065 1.03.213.285.13.527.339.7.6.165.262.252.566.25.876.002.275-.049.549-.15.805-.122.277-.28.536-.47.772-.35.398-.725.774-1.12 1.127l-.81.752v.059h2.72v1.106-.005zM13 9v4H8V9a1 1 0 0 0-2 0v10a1 1 0 0 0 2 0v-4h5v4a1 1 0 0 0 2 0V9a1 1 0 0 0-2 0z",fillRule:"evenodd"}));case"text-h3":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21.65 15.108c.01.364-.12.718-.36.991-.26.29-.608.487-.99.561v.026a1.97 1.97 0 0 1 1.14.456c.265.256.407.613.39.981.03.546-.214 1.07-.65 1.4a3.037 3.037 0 0 1-1.87.5 4.587 4.587 0 0 1-1.8-.336v-1.118c.256.127.524.228.8.3.28.075.57.114.86.115.338.025.676-.052.97-.221a.802.802 0 0 0 .31-.709.642.642 0 0 0-.36-.622 2.674 2.674 0 0 0-1.14-.183h-.48v-1.007h.49c.363.023.727-.042 1.06-.189a.686.686 0 0 0 .33-.648.715.715 0 0 0-.89-.706c-.21 0-.42.035-.62.1-.25.087-.49.206-.71.353l-.61-.906a3.42 3.42 0 0 1 2.04-.612 2.65 2.65 0 0 1 1.53.392c.36.24.572.649.56 1.082zM13 9v4H8V9a1 1 0 0 0-2 0v10a1 1 0 0 0 2 0v-4h5v4a1 1 0 0 0 2 0V9a1 1 0 0 0-2 0z",fillRule:"evenodd"}));case"text-h4":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21.25 17.623v-3.907h-1.22l-2.74 4.013v.914h2.67v1.288h1.29v-1.288H22v-1.02h-.75zm-1.27-1.819c-.01.333-.02.589-.02.764v1.055h-1.5l1.14-1.722c.144-.217.271-.445.38-.681h.03c0 .055-.02.251-.03.584zM13 9v4H8V9a1 1 0 0 0-2 0v10a1 1 0 0 0 2 0v-4h5v4a1 1 0 0 0 2 0V9a1 1 0 0 0-2 0z",fillRule:"evenodd"}));case"text-h5":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.259 15.73c.621 0 1.115.174 1.483.523.368.349.552.826.552 1.433 0 .718-.221 1.27-.664 1.657-.442.387-1.075.58-1.898.58-.715 0-1.292-.116-1.731-.347v-1.173c.231.123.501.223.809.301.308.078.599.117.875.117.829 0 1.244-.34 1.244-1.02 0-.647-.429-.971-1.288-.971-.155 0-.327.015-.514.046-.188.031-.34.064-.457.099l-.541-.29.242-3.274h3.485v1.151H19.56l-.119 1.261.154-.031c.179-.041.4-.062.664-.062z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M13 9v4H8V9a1 1 0 0 0-2 0v10a1 1 0 0 0 2 0v-4h5v4a1 1 0 0 0 2 0V9a1 1 0 0 0-2 0z",fillRule:"evenodd"}));case"text-h6":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22.047 16.275c-.325-.36-.775-.541-1.349-.541-.639 0-1.103.249-1.393.747h-.057c.026-.507.113-.898.259-1.173s.367-.483.661-.624.675-.211 1.14-.211c.255 0 .513.029.773.088v-1.085a4.374 4.374 0 0 0-.861-.066c-1.072 0-1.877.311-2.415.932S18 15.909 18 17.18c0 .595.096 1.103.288 1.525s.464.743.817.962.767.33 1.241.33c.686 0 1.222-.2 1.608-.6s.58-.943.58-1.628c.001-.635-.161-1.133-.487-1.494zm-1.059 2.345c-.155.195-.378.292-.668.292-.281 0-.513-.12-.697-.36s-.275-.535-.275-.883c0-.237.097-.445.292-.624s.43-.268.705-.268c.293 0 .512.09.657.27s.218.427.218.74c.001.36-.076.638-.232.833z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M13 9v4H8V9a1 1 0 0 0-2 0v10a1 1 0 0 0 2 0v-4h5v4a1 1 0 0 0 2 0V9a1 1 0 0 0-2 0z",fillRule:"evenodd"}));case"text":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.4 8h-.3c-.4.2-.5.5-.6 1l-4.4 9.7c-.2.5.1 1.1.6 1.3.5.2 1.1-.1 1.3-.6L7 17h5l1 2.3c.2.5.8.8 1.3.6.5-.2.8-.8.6-1.3L10.5 9c-.1-.5-.2-.8-.6-.9-.1-.1-.2-.1-.3-.1h-.2zM8 15l1.5-3 1.5 3H8zm15.5 0v-1c0-1.7-1.3-3-3-3h-3c-.5 0-1.2.4-1.2 1s.6 1 1.2 1h3c.6 0 1 .4 1 1h-3c-1.6 0-3 1.3-3 3 0 1.6 1.3 3 3 3h2c.8 0 1.4-.3 2-.9.1.5.5.9 1 .9s1-.5 1-1-.4-1-1-1v-3zm-2 2c0 .6-.4 1-1 1h-2c-.6 0-1-.5-1-1s.5-1 1-1h3v1z",fillRule:"evenodd"}));case"undent":return u.a.createElement("g",null,u.a.createElement("path",{d:"M10.24 16.022l-2.56-1.6a.5.5 0 0 1 0-.848l2.56-1.6a.5.5 0 0 1 .76.424v3.2a.5.5 0 0 1-.76.424zM20 10H8a1 1 0 1 1 0-2h12a1 1 0 0 1 0 2zm0 5h-6a1 1 0 0 1 0-2h6a1 1 0 0 1 0 2zm0 5H8a1 1 0 0 1 0-2h12a1 1 0 0 1 0 2z",fillRule:"evenodd"}));case"undo":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.355 7.253c-1.74.026-3.321.559-4.576 1.528L7.999 7A1 1 0 0 0 7 8v4.998c0 .552.447.999.999.999h4.995a1 1 0 0 0 .999-.999l-2.014-2.016a4.51 4.51 0 0 1 2.44-.733c2.235-.032 4.261 1.58 4.534 3.799.338 2.751-1.789 5.009-4.46 5.009-1.149 0-2.186-.462-2.978-1.182a.654.654 0 0 0-.902.026l-1.184 1.175a.674.674 0 0 0 .032.979A7.443 7.443 0 0 0 14.493 22c4.401 0 7.915-3.8 7.452-8.297-.395-3.826-3.745-6.507-7.59-6.45z",fillRule:"evenodd"}));case"zoom-in":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.508 7a5.511 5.511 0 0 0-5.505 5.5 5.426 5.426 0 0 0 .847 2.92l-3.737 2.67c-.389.39.32 1.74.708 2.13.39.39 1.764 1.06 2.153.67l2.646-3.71A5.5 5.5 0 1 0 15.508 7zm0 9.01a3.505 3.505 0 1 1 3.5-3.51 3.514 3.514 0 0 1-3.5 3.51zm.5-5.01h-1v1h-1v1h1v1h1v-1h1v-1h-1v-1z",fillRule:"evenodd"}));case"zoom-out":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.508 7a5.5 5.5 0 0 0-4.658 8.43L7.113 18.1c-.389.39.32 1.73.708 2.12.39.39 1.764 1.07 2.153.68l2.646-3.71A5.5 5.5 0 1 0 15.508 7zm0 9.01a3.505 3.505 0 1 1-.01-7.01 3.505 3.505 0 0 1 .01 7.01zm-1.5-3h3v-1h-3v1z",fillRule:"evenodd"}));case"lock":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 12C19.9 11.7 19.3 11 19 11L18 11C18 8.1 16.2 6 14 6 11.8 6 10 8.1 10 11L9 11C8.6 11 8.1 11.6 8 12L8 13 8 19 8 20C8.1 20.3 8.7 20.9 9 21L19 21C19.4 21 19.9 20.4 20 20L20 19 20 14 20 12 20 12ZM14 8C15.1 8 16 9.4 16 11.1L12 11.1C12 9.4 12.9 8 14 8L14 8ZM18 19L10 19 10 13 18 13 18 19 18 19Z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M14 18C14.6 18 15 17.6 15 17L15 15C15 14.4 14.6 14 14 14 13.4 14 13 14.4 13 15L13 15 13 17C13 17.6 13.4 18 14 18L14 18Z",fillRule:"evenodd"}));case"previous":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.2 14L18.7 10C19.1 9.6 19.1 9 18.7 8.6 18.3 8.2 17.7 8.2 17.3 8.6L13.3 13.1C13.1 13.3 13 13.7 13 14 12.9 14.3 13 14.6 13.3 14.9L17.3 19.4C17.7 19.8 18.3 19.8 18.7 19.4 19.1 19 19.1 18.4 18.7 18L15.2 14 15.2 14Z",fillRule:"evenodd"}));case"next":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.8 14L12.3 18C11.9 18.4 11.9 19 12.3 19.4 12.7 19.8 13.3 19.8 13.7 19.4L17.7 14.9C17.9 14.7 18 14.3 18 14 18.1 13.7 18 13.4 17.7 13.1L13.7 8.6C13.3 8.2 12.7 8.2 12.3 8.6 11.9 9 11.9 9.6 12.3 10L15.8 14 15.8 14Z",fillRule:"evenodd"}));case"sync":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.1 11.7L19.1 11.7c-0.3 0.3-0.4 0.6-0.3 0.9 0.1 0.4 0.2 0.9 0.2 1.3 0 2.8-2.2 5-5 5v2c3.9 0 7-3.1 7-7 0-0.6-0.1-1.3-0.2-1.8C20.6 11.4 19.6 11.2 19.1 11.7z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M14 9V7c-3.9 0-7 3.1-7 7 0 0.6 0.1 1.2 0.2 1.8 0.2 0.7 1.1 1 1.7 0.4l0 0c0.2-0.2 0.4-0.6 0.3-0.9C9.1 14.9 9 14.5 9 14 9 11.2 11.2 9 14 9z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M18.2 8.6c0.4-0.3 0.4-0.9 0-1.2l-3.4-2.8C14.4 4.3 14 4.4 14 5v6c0 0.6 0.4 0.7 0.8 0.4L18.2 8.6z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M9.8 19.4c-0.4 0.3-0.4 0.9 0 1.2l3.4 2.8c0.4 0.3 0.8 0.2 0.8-0.4v-6c0-0.5-0.4-0.7-0.8-0.4L9.8 19.4z",fillRule:"evenodd"}));case"portability":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.6 20.8c0.2 0.3 0.7 0.3 0.9 0l2.1-3.5c0.2-0.3 0-0.8-0.4-0.8H11V8c0-0.6-0.4-1-1-1C9.4 7 9 7.4 9 8v8.5H7.9c-0.4 0-0.6 0.4-0.4 0.8L9.6 20.8z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M18.4 7.2c-0.2-0.3-0.7-0.3-0.9 0l-2.1 3.5c-0.2 0.3 0 0.8 0.4 0.8H17V20c0 0.6 0.4 1 1 1 0.6 0 1-0.4 1-1v-8.5h1.1c0.4 0 0.6-0.4 0.4-0.8L18.4 7.2z",fillRule:"evenodd"}));case"background-color":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.4 14.6c0 0-1.5 3.1-1.5 4.4 0 0.9 0.7 1.6 1.5 1.6 0.8 0 1.5-0.7 1.5-1.6C20.9 17.6 19.4 14.6 19.4 14.6zM19.3 12.8l-4.8-4.8c-0.2-0.2-0.4-0.3-0.6-0.3 -0.3 0-0.5 0.1-0.7 0.3l-1.6 1.6L9.8 7.8c-0.4-0.4-1-0.4-1.4 0C8 8.1 8 8.8 8.4 9.1l1.8 1.8 -2.8 2.8c-0.4 0.4-0.4 1-0.1 1.4l4.6 4.6c0.2 0.2 0.4 0.3 0.6 0.3 0.3 0 0.5-0.1 0.7-0.3l6.1-6.1C19.5 13.4 19.5 13.1 19.3 12.8zM15.6 14.6c-1.7 1.7-4.5 1.7-6.2 0l2.1-2.1 1 1c0.4 0.4 1 0.4 1.4 0 0.4-0.4 0.4-1 0-1.4l-1-1 0.9-0.9 3.1 3.1L15.6 14.6z",fillRule:"evenodd"}));case"background-image":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22.9 7.5c-0.1-0.3-0.5-0.6-0.8-0.6H5.9c-0.4 0-0.7 0.2-0.8 0.6C5.1 7.6 5 7.7 5 7.9v12.2c0 0.1 0 0.2 0.1 0.4 0.1 0.3 0.5 0.5 0.8 0.6h16.2c0.4 0 0.7-0.2 0.8-0.6 0-0.1 0.1-0.2 0.1-0.4V7.9C23 7.7 23 7.6 22.9 7.5zM21 18.9H7v-10h14V18.9z",fillRule:"evenodd"}),u.a.createElement("circle",{cx:"10.5",cy:"12.4",r:"1.5"}),u.a.createElement("polygon",{points:"15 16.9 13 13.9 11 16.9 "}),u.a.createElement("polygon",{points:"17 10.9 15 16.9 19 16.9 "}));case"background-video":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22.9 7.5c-0.1-0.3-0.5-0.6-0.8-0.6H5.9c-0.4 0-0.7 0.2-0.8 0.6C5.1 7.6 5 7.7 5 7.9v12.2c0 0.1 0 0.2 0.1 0.4 0.1 0.3 0.5 0.5 0.8 0.6h16.2c0.4 0 0.7-0.2 0.8-0.6 0-0.1 0.1-0.2 0.1-0.4V7.9C23 7.7 23 7.6 22.9 7.5zM21 18.9H7v-10h14V18.9z",fillRule:"evenodd"}),u.a.createElement("polygon",{points:"13 10.9 13 16.9 17 13.9 "}));case"background-gradient":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22.9 7.5c-0.1-0.3-0.5-0.6-0.8-0.6H5.9c-0.4 0-0.7 0.2-0.8 0.6C5.1 7.6 5 7.7 5 7.9v12.2c0 0.1 0 0.2 0.1 0.4 0.1 0.3 0.5 0.5 0.8 0.6h16.2c0.4 0 0.7-0.2 0.8-0.6 0-0.1 0.1-0.2 0.1-0.4V7.9C23 7.7 23 7.6 22.9 7.5zM21 18.9L7 8.9h14V18.9z",fillRule:"evenodd"}));case"background-pattern":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22,7H6A1,1,0,0,0,5,8V20a1,1,0,0,0,1,1H22a1,1,0,0,0,1-1V8A1,1,0,0,0,22,7ZM19.71,19l-2-2L20,14.71l1,1v2.58l-.71.71Zm-6,0-2-2L14,14.71,16.29,17l-2,2Zm-6,0L7,18.29V15.71l1-1L10.29,17l-2,2ZM7,9.71,7.71,9h.58l2,2L8,13.29l-1-1ZM8.71,14,11,11.71,13.29,14,11,16.29Zm5.58-5,2,2L14,13.29,11.71,11l2-2Zm.42,5L17,11.71,19.29,14,17,16.29Zm5.58-5,.71.71v2.58l-1,1L17.71,11l2-2ZM21,14.29,20.71,14l.29-.29ZM18.29,9,17,10.29,15.71,9Zm-6,0L11,10.29,9.71,9ZM7,13.71l.29.29L7,14.29ZM9.71,19,11,17.71,12.29,19Zm6,0L17,17.71,18.29,19Z"}));case"background-mask":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22,7H6A1,1,0,0,0,5,8V20a1,1,0,0,0,1,1H22a1,1,0,0,0,1-1V8A1,1,0,0,0,22,7ZM21,19H7V16.77A8.76,8.76,0,0,0,9,17a9,9,0,0,0,8.94-8H21Z"}));case"swap":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19 12h-3V9c0-0.5-0.5-1-1-1H8C7.5 8 7 8.5 7 9v7c0 0.5 0.5 1 1 1h3v3c0 0.5 0.5 1 1 1h7c0.5 0 1-0.5 1-1v-7C20 12.5 19.5 12 19 12zM18 19h-5v-2h2c0.5 0 1-0.5 1-1v-2h2V19z",fillRule:"evenodd"}));case"none":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14 24c5.5 0 10-4.5 10-10S19.5 4 14 4 4 8.5 4 14s4.5 10 10 10zm0-17.5c4.1 0 7.5 3.4 7.5 7.5 0 1.5-.5 2.9-1.2 4.1L9.9 7.7c1.2-.7 2.6-1.2 4.1-1.2zM7.7 9.9l10.4 10.4c-1.2.8-2.6 1.2-4.1 1.2-4.1 0-7.5-3.4-7.5-7.5 0-1.5.5-2.9 1.2-4.1z"}));case"animation-bounce":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("circle",{cx:"21.5",cy:"8.5",r:"3.5"}),u.a.createElement("circle",{cx:"16",cy:"12",r:"1.7"}),u.a.createElement("circle",{cx:"13",cy:"15",r:"1.2"}),u.a.createElement("circle",{cx:"11",cy:"18",r:"1"}),u.a.createElement("circle",{cx:"9",cy:"22",r:"1"}),u.a.createElement("circle",{cx:"7",cy:"19",r:"1"}),u.a.createElement("circle",{cx:"4",cy:"17",r:"1"}));case"animation-fade":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("circle",{cx:"8.5",cy:"19.5",r:"1.5"}),u.a.createElement("circle",{cx:"8.5",cy:"14.5",r:"1.5"}),u.a.createElement("circle",{cx:"5",cy:"12",r:"1"}),u.a.createElement("circle",{cx:"5",cy:"17",r:"1"}),u.a.createElement("circle",{cx:"8.5",cy:"9.5",r:"1.5"}),u.a.createElement("path",{d:"M15.7 4c-.4 0-.8.1-1.2.3-.6.3-.5.7-1.5.7-1.1 0-2 .9-2 2s.9 2 2 2c.3 0 .5.2.5.5s-.2.5-.5.5c-1.1 0-2 .9-2 2s.9 2 2 2c.3 0 .5.2.5.5s-.2.5-.5.5c-1.1 0-2 .9-2 2s.9 2 2 2c.3 0 .5.2.5.5s-.2.5-.5.5c-1.1 0-2 .9-2 2s.9 2 2 2c1 0 .9.4 1.4.7.4.2.8.3 1.2.3 4.3-.4 8.3-5.3 8.3-10.5s-4-10-8.2-10.5z"}));case"animation-flip":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M22 2.4l-7 2.9V7h-2v-.8L7.6 8.7c-.4.2-.6.5-.6.9v8.7c0 .4.2.7.6.9l5.4 2.5V21h2v1.7l7 2.9c.5.2 1-.2 1-.7V3.1c0-.5-.5-.9-1-.7zM15 19h-2v-2h2v2zm0-4h-2v-2h2v2zm0-4h-2V9h2v2zM13 2h2v2.5h-2zM13 23.5h2V26h-2z"}));case"animation-fold":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M24 7h-4V3.4c0-.8-.6-1.4-1.3-1.4-.2 0-.5.1-.7.2l-6.5 3.9c-.9.6-1.5 1.6-1.5 2.6V23c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2zm-6 10.5c0 .2-.1.4-.3.5L12 21.5V8.7c0-.4.2-.7.5-.9L18 4.5v13zM6 7h2v2H6zM6 23h2v2H6zM2.6 7.1c-.1 0-.1.1-.2.1v.1l-.1.1-.1.1c-.1.1-.2.3-.2.5v1h2V7H3c-.1 0-.2 0-.4.1zM2 23v1c0 .4.3.8.7.9.1.1.2.1.3.1h1v-2H2zM2 11h2v2H2zM2 19h2v2H2zM2 15h2v2H2z"}));case"animation-none":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M14 24c5.5 0 10-4.5 10-10S19.5 4 14 4 4 8.5 4 14s4.5 10 10 10zm0-17.5c4.1 0 7.5 3.4 7.5 7.5 0 1.5-.5 2.9-1.2 4.1L9.9 7.7c1.2-.7 2.6-1.2 4.1-1.2zM7.7 9.9l10.4 10.4c-1.2.8-2.6 1.2-4.1 1.2-4.1 0-7.5-3.4-7.5-7.5 0-1.5.5-2.9 1.2-4.1z"}));case"animation-roll":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M18.8 5c-5.3-2.7-11.8.2-14 5.6-1.1 2.8-1 6 .2 8.8.4 1 3.9 6.5 5 3.6.5-1.2-1.3-2.2-1.9-3-.8-1.2-1.4-2.5-1.6-3.9-.4-2.7.5-5.5 2.4-7.4 4-4 11.6-2.5 12.6 3.4.4 2.7-.9 5.5-3.4 6.6-2.6 1.1-6 0-6.8-2.8-.7-2.4 1.2-5.7 4-4.8 1.1.3 2 1.5 1.5 2.7-.3.7-1.7 1.2-1.6.1 0-.3.2-.4.2-.8-.1-.4-.5-.6-.9-.6-1.1.1-1.6 1.6-1.3 2.5.3 1.2 1.5 1.9 2.7 1.9 2.9 0 4.2-3.4 3.1-5.7-1.2-2.6-4.6-3.4-7-2.2-2.6 1.3-3.8 4.4-3.1 7.2 1.6 5.9 9.3 6.8 13.1 2.5 3.8-4.2 1.9-11.1-3.2-13.7z"}));case"animation-zoom":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M23.7 4.3c-.1-.1-.2-.2-.3-.2-.1-.1-.3-.1-.4-.1h-5c-.6 0-1 .4-1 1s.4 1 1 1h2.6l-3.1 3.1c-.2-.1-.3-.1-.5-.1h-6c-.2 0-.3 0-.5.1L7.4 6H10c.6 0 1-.4 1-1s-.4-1-1-1H5c-.1 0-.3 0-.4.1-.2.1-.4.3-.5.5-.1.1-.1.3-.1.4v5c0 .6.4 1 1 1s1-.4 1-1V7.4l3.1 3.1c-.1.2-.1.3-.1.5v6c0 .2 0 .3.1.5L6 20.6V18c0-.6-.4-1-1-1s-1 .4-1 1v5c0 .1 0 .3.1.4.1.2.3.4.5.5.1.1.3.1.4.1h5c.6 0 1-.4 1-1s-.4-1-1-1H7.4l3.1-3.1c.2 0 .3.1.5.1h6c.2 0 .3 0 .5-.1l3.1 3.1H18c-.6 0-1 .4-1 1s.4 1 1 1h5c.1 0 .3 0 .4-.1.2-.1.4-.3.5-.5.1-.1.1-.3.1-.4v-5c0-.6-.4-1-1-1s-1 .4-1 1v2.6l-3.1-3.1c0-.2.1-.3.1-.5v-6c0-.2 0-.3-.1-.5L22 7.4V10c0 .6.4 1 1 1s1-.4 1-1V5c0-.1 0-.3-.1-.4 0-.1-.1-.2-.2-.3z"}));case"animation-slide":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M22 4h-5c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h5c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zM10 14c0 .6.4 1 1 1h.6L10 16.6c-.4.4-.4 1 0 1.4.4.4 1 .4 1.4 0l3.3-3.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7L11.4 10c-.4-.4-1-.4-1.4 0-.4.4-.4 1 0 1.4l1.6 1.6H11c-.6 0-1 .4-1 1z"}),u.a.createElement("circle",{cx:"7",cy:"14",r:"1.5"}),u.a.createElement("circle",{cx:"3",cy:"14",r:"1"}));case"align-left":return u.a.createElement("g",null,u.a.createElement("path",{d:"M5 13h2v2H5zM5 21h2v2H5zM5 17h2v2H5zM5 9h2v2H5zM5 5h2v2H5z"}),u.a.createElement("path",{d:"M7.339 13.25a1 1 0 0 0 0 1.501l4.642 4.09a.6.6 0 0 0 1.007-.442V16h9a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1h-9V9.602a.601.601 0 0 0-1.002-.446L7.339 13.25z"}));case"align-center":return u.a.createElement("g",null,u.a.createElement("path",{d:"M5 13h2v2H5zM5 9h2v2H5zM5 17h2v2H5zM5 5h2v2H5zM5 21h2v2H5zM21 9h2v2h-2zM21 5h2v2h-2zM21 13h2v2h-2zM15 8h-2a1 1 0 0 0-1 1v10a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1V9a1 1 0 0 0-1-1zM21 17h2v2h-2zM21 21h2v2h-2z"}));case"align-right":return u.a.createElement("g",null,u.a.createElement("path",{d:"M21 21h2v2h-2zM21 17h2v2h-2zM21 9h2v2h-2zM21 5h2v2h-2zM21 13h2v2h-2z"}),u.a.createElement("path",{d:"M20.649 13.249l-4.642-4.09A.6.6 0 0 0 15 9.602V12H6a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h9v2.398a.601.601 0 0 0 1.002.446l4.647-4.094a1 1 0 0 0 0-1.501z"}));case"click":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M15 10V8c0-.6-.4-1-1-1s-1 .4-1 1v2c0 .3.2.6.4.8.2 0 .5.1.7.2.5-.1.9-.5.9-1zM20 15c.6 0 1-.4 1-1s-.4-1-1-1h-2c-.4 0-.7.2-.9.6l1.6 1.4H20zM10 13H8c-.6 0-1 .4-1 1s.4 1 1 1h2c.6 0 1-.4 1-1s-.4-1-1-1zM9.8 11.2c.2.2.5.3.7.3s.5-.1.7-.3c.4-.4.4-1 0-1.4l-1-1c-.4-.4-1-.4-1.4 0s-.4 1 0 1.4l1 1zM9.8 16.8l-1.1 1.1c-.4.4-.4 1 0 1.4.2.2.5.3.7.3s.5-.1.7-.3l.9-.9v-1.8c-.4-.2-.9-.1-1.2.2zM17.5 11.5c.3 0 .5-.1.7-.3l1-1c.4-.4.4-1 0-1.4s-1-.4-1.4 0l-1 1c-.4.4-.4 1 0 1.4.2.2.4.3.7.3zM13.4 12.9s-.1-.1-.2-.1-.3.1-.3.3v7.4c0 .3.3.6.6.6h.2l1.4-.6.8 2c.2.4.5.6.9.6.1 0 .3 0 .4-.1.5-.2.7-.8.5-1.3l-.8-2 1.9-.8c.3-.1.3-.5.1-.7l-5.5-5.3z",fillRule:"evenodd"}));case"hover":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M17.1 18.1l-5.7-5.2c-.2-.1-.4 0-.4.2v7.4c0 .4.4.7.8.6l1.4-.6.8 2c.2.5.8.7 1.3.5.5-.2.7-.8.5-1.3l-.8-2 1.9-.8c.3-.3.4-.6.2-.8zM20 10c-.6 0-1-.4-1-1-.6 0-1-.4-1-1s.4-1 1-1c1.1 0 2 .9 2 2 0 .6-.4 1-1 1zM8 10c-.6 0-1-.4-1-1 0-1.1.9-2 2-2 .6 0 1 .4 1 1s-.4 1-1 1c0 .6-.4 1-1 1zM9 20c-1.1 0-2-.9-2-2 0-.6.4-1 1-1s1 .4 1 1c.6 0 1 .4 1 1s-.4 1-1 1zM19 20c-.6 0-1-.4-1-1s.4-1 1-1c0-.6.4-1 1-1s1 .4 1 1c0 1.1-.9 2-2 2zM14.8 9h-1.5c-.6 0-1-.4-1-1s.4-1 1-1h1.5c.6 0 1 .4 1 1s-.5 1-1 1zM20 15c-.6 0-1-.4-1-1v-1c0-.6.4-1 1-1s1 .4 1 1v1c0 .6-.4 1-1 1zM8 15c-.6 0-1-.4-1-1v-1c0-.6.4-1 1-1s1 .4 1 1v1c0 .6-.4 1-1 1z",fillRule:"evenodd"}));case"menu-expand":return u.a.createElement("g",{fillRule:"evenodd"},u.a.createElement("path",{d:"M14 20l-3-5h6zM14 8l3 5h-6z",fillRule:"evenodd"}));case"border-all":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22 5H6a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h16a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1zm-2 15H8V8h12z"}));case"border-top":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17 21h2v2h-2zM5 9h2v2H5zM21 17h2v2h-2zM21 9h2v2h-2zM21 13h2v2h-2zM21 23h1a1 1 0 0 0 1-1v-1h-2zM5 17h2v2H5zM5 13h2v2H5zM13 21h2v2h-2zM9 21h2v2H9zM5 21v1a1 1 0 0 0 1 1h1v-2zM22 5H6a1 1 0 0 0-1 1v2h18V6a1 1 0 0 0-1-1z"}));case"border-right":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13 5h2v2h-2zM5 9h2v2H5zM9 5h2v2H9zM7 5H6a1 1 0 0 0-1 1v1h2zM5 13h2v2H5zM13 21h2v2h-2zM5 17h2v2H5zM9 21h2v2H9zM17 5h2v2h-2zM5 21v1a1 1 0 0 0 1 1h1v-2zM22 5h-2v18h2a1 1 0 0 0 1-1V6a1 1 0 0 0-1-1zM17 21h2v2h-2z"}));case"border-bottom":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9 5h2v2H9zM7 20H5v2a1 1 0 0 0 1 1h16a1 1 0 0 0 1-1v-2H7zM17 5h2v2h-2zM5 13h2v2H5zM5 9h2v2H5zM13 5h2v2h-2zM5 17h2v2H5zM21 9h2v2h-2zM21 17h2v2h-2zM22 5h-1v2h2V6a1 1 0 0 0-1-1zM21 13h2v2h-2zM7 5H6a1 1 0 0 0-1 1v1h2z"}));case"border-left":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22 5h-1v2h2V6a1 1 0 0 0-1-1zM9 21h2v2H9zM21 17h2v2h-2zM13 21h2v2h-2zM21 13h2v2h-2zM9 5h2v2H9zM17 21h2v2h-2zM17 5h2v2h-2zM21 9h2v2h-2zM8 7V5H6a1 1 0 0 0-1 1v16a1 1 0 0 0 1 1h2V7zM21 23h1a1 1 0 0 0 1-1v-1h-2zM13 5h2v2h-2z"}));case"border-link":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.71 17.71a3 3 0 0 1-2.12-.88l-.71-.71a1 1 0 0 1 1.41-1.41l.71.71a1 1 0 0 0 1.41 0l5-4.95a1 1 0 0 0 0-1.41l-1.46-1.42a1 1 0 0 0-1.41 0L16.1 9.07a1 1 0 0 1-1.41-1.41l1.43-1.43a3.07 3.07 0 0 1 4.24 0l1.41 1.41a3 3 0 0 1 0 4.24l-5 4.95a3 3 0 0 1-2.06.88z"}),u.a.createElement("path",{d:"M9.76 22.66a3 3 0 0 1-2.12-.88l-1.42-1.42a3 3 0 0 1 0-4.24l5-4.95a3.07 3.07 0 0 1 4.24 0l.71.71a1 1 0 0 1-1.41 1.41l-.76-.7a1 1 0 0 0-1.41 0l-5 4.95a1 1 0 0 0 0 1.41L9 20.36a1 1 0 0 0 1.41 0L11.82 19a1 1 0 0 1 1.41 1.41l-1.36 1.36a3 3 0 0 1-2.11.89z"}));case"window-undock":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9 10H8a1 1 0 0 0-1 1v1a1 1 0 0 0 2 0 1 1 0 0 0 0-2zM13 19h-1a1 1 0 0 0 0 2h1a1 1 0 0 0 0-2zM9 19a1 1 0 0 0-2 0v1a1 1 0 0 0 1 1h1a1 1 0 0 0 0-2zM20 7h-8a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V8a1 1 0 0 0-1-1zm-1 2v6h-6V9zM17 18a1 1 0 0 0-1 1 1 1 0 0 0 0 2h1a1 1 0 0 0 1-1v-1a1 1 0 0 0-1-1zM8 17a1 1 0 0 0 1-1v-1a1 1 0 0 0-2 0v1a1 1 0 0 0 1 1z"}));case"chevron-right":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13.38 19.48l4.6-4.6a1.25 1.25 0 0 0 0-1.77l-4.6-4.6a1.25 1.25 0 1 0-1.77 1.77L15.32 14l-3.71 3.71a1.25 1.25 0 1 0 1.77 1.77z",fillRule:"evenodd"}));case"chevron-left":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.62 8.52L10 13.12a1.25 1.25 0 0 0 0 1.77l4.6 4.6a1.25 1.25 0 0 0 1.77-1.77L12.68 14l3.71-3.71a1.25 1.25 0 1 0-1.77-1.77z",fillRule:"evenodd"}));case"chevron-up":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20 14.62L15.38 10a1.25 1.25 0 0 0-1.77 0L9 14.62a1.25 1.25 0 0 0 1.77 1.77l3.71-3.71 3.71 3.71A1.25 1.25 0 1 0 20 14.62z",fillRule:"evenodd"}));case"chevron-down":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.98 11.616a1.25 1.25 0 0 0-1.768 0L14.5 15.328l-3.712-3.712a1.25 1.25 0 0 0-1.768 1.768l4.596 4.596a1.25 1.25 0 0 0 1.768 0l4.596-4.596a1.25 1.25 0 0 0 0-1.768z",fillRule:"evenodd"}));case"flip-horizontally":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22 8.229a.995.995 0 0 0-.665.253L15 14.122l6.348 5.458A1 1 0 0 0 23 18.822V9.229a1 1 0 0 0-1-1zM7 11.458l2.963 2.638L7 16.643v-5.185M6 8.229a.996.996 0 0 0-1 1v9.592a1 1 0 0 0 1.652.758L13 14.122l-6.335-5.64A1 1 0 0 0 6 8.229zM13 5h2v2h-2zM13 9h2v2h-2zM13 13h2v2h-2zM13 17h2v2h-2zM13 21h2v2h-2z",fillRule:"evenodd"}));case"flip-vertically":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13.878 15L8.42 21.348A1 1 0 0 0 9.178 23h9.592a1 1 0 0 0 .747-1.665L13.878 15zM16.542 7l-2.638 2.963L11.357 7h5.185m2.229-2H9.178a1 1 0 0 0-.758 1.652L13.878 13l5.64-6.335A1 1 0 0 0 18.771 5zM5 13h2v2H5zM9 13h2v2H9zM13 13h2v2h-2zM17 13h2v2h-2zM21 13h2v2h-2z",fillRule:"evenodd"}));case"rotate-90-degree":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.355 7.253c-1.74.026-3.321.559-4.576 1.528L7.999 7A1 1 0 0 0 7 8v4.998c0 .552.447.999.999.999h4.995a1 1 0 0 0 .999-.999l-2.014-2.016a4.51 4.51 0 0 1 2.44-.733c2.235-.032 4.261 1.58 4.534 3.799.338 2.751-1.789 5.009-4.46 5.009-1.149 0-2.186-.462-2.978-1.182a.654.654 0 0 0-.902.026l-1.184 1.175a.674.674 0 0 0 .032.979A7.443 7.443 0 0 0 14.493 22c4.401 0 7.915-3.8 7.452-8.297-.395-3.826-3.745-6.507-7.59-6.45z",fillRule:"evenodd"}));case"invert":return u.a.createElement("g",null,u.a.createElement("path",{d:"m19.469855,14c0,-3.063118 -2.406736,-5.469854 -5.469854,-5.469854l0,10.939709c3.063118,0 5.469854,-2.406736 5.469854,-5.469854zm2.187942,-9.845738l-15.315592,0c-1.203368,0 -2.187942,0.984574 -2.187942,2.187942l0,15.315592c0,1.203368 0.984574,2.187942 2.187942,2.187942l15.315592,0c1.203368,0 2.187942,-0.984574 2.187942,-2.187942l0,-15.315592c0,-1.203368 -0.984574,-2.187942 -2.187942,-2.187942zm0,17.503534l-7.657796,0l0,-2.187942c-3.063118,0 -5.469854,-2.406736 -5.469854,-5.469854c0,-3.063118 2.406736,-5.469854 5.469854,-5.469854l0,-2.187942l7.657796,0l0,15.315592z"}));case"aspect-ratio-landscape":return u.a.createElement("g",null,u.a.createElement("rect",{x:"2",y:"6",width:"24",height:"16",rx:"2"}));case"aspect-ratio-square":return u.a.createElement("g",null,u.a.createElement("rect",{x:"6",y:"6",width:"16",height:"16",rx:"2"}));case"aspect-ratio-portrait":return u.a.createElement("g",null,u.a.createElement("rect",{x:"6",y:"2",width:"16",height:"24",rx:"2"}));case"eye":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14,16a2,2,0,1,1,2-2A2,2,0,0,1,14,16Zm0,2a6.24,6.24,0,0,0,5.91-4A6.35,6.35,0,0,0,8.09,14,6.24,6.24,0,0,0,14,18ZM14,8a8.22,8.22,0,0,1,8,6A8.33,8.33,0,0,1,6,14,8.22,8.22,0,0,1,14,8Z"}));case"closed-eye":return u.a.createElement("g",null,u.a.createElement("path",{d:"M9.89,16.69l2.18-2.17A1.81,1.81,0,0,1,12,14a2,2,0,0,1,2-2,1.81,1.81,0,0,1,.52.07l1.67-1.68A6.43,6.43,0,0,0,14,10a6.3,6.3,0,0,0-5.91,4.1A6.28,6.28,0,0,0,9.89,16.69ZM12.37,20l1.85-1.84a6.24,6.24,0,0,0,5.69-4.1A6.24,6.24,0,0,0,19.39,13l1.45-1.45A8.41,8.41,0,0,1,22,14.1a8.3,8.3,0,0,1-8,6.1A8.83,8.83,0,0,1,12.37,20Zm-2.1-.73-.11,0L8.34,21.07,6.93,19.66,8.48,18.1A8.36,8.36,0,0,1,6,14.1,8.24,8.24,0,0,1,14,8a8.11,8.11,0,0,1,3.72.87l1.94-1.94,1.41,1.41L19.42,10l.09.08L18.08,11.5,18,11.42l-2.06,2.06a.7.7,0,0,1,0,.14L13.62,16a.7.7,0,0,1-.14,0l-1.83,1.83.13,0Z"}));case"linked":return u.a.createElement("g",null,u.a.createElement("path",{d:"M8 14a1 1 0 0 1 0 2h-.5A2.5 2.5 0 0 1 5 13.5v-2A2.5 2.5 0 0 1 7.5 9h8a2.5 2.5 0 0 1 2.5 2.5v2a2.5 2.5 0 0 1-2.5 2.5H15a1 1 0 0 1 0-2h.5a.5.5 0 0 0 .5-.5v-2a.5.5 0 0 0-.5-.5h-8a.5.5 0 0 0-.5.5v2a.5.5 0 0 0 .5.5z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M20 14a1 1 0 0 1 0-2h.5a2.5 2.5 0 0 1 2.5 2.5v2a2.5 2.5 0 0 1-2.5 2.5h-8a2.5 2.5 0 0 1-2.5-2.5v-2a2.5 2.5 0 0 1 2.5-2.5h.5a1 1 0 0 1 0 2h-.5a.5.5 0 0 0-.5.5v2a.5.5 0 0 0 .5.5h8a.5.5 0 0 0 .5-.5v-2a.5.5 0 0 0-.5-.5z",fillRule:"evenodd"}));case"unlinked":return u.a.createElement("g",null,u.a.createElement("path",{d:"M16.75 9.14a1 1 0 0 1 .37 1.39l-4.5 8a1 1 0 0 1-1.37.37 1 1 0 0 1-.37-1.39l4.5-8a1 1 0 0 1 1.37-.37zM19.71 10H20a3 3 0 0 1 3 3v2a3 3 0 0 1-3 3h-4.81l1.13-2H20a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1h-1.42zM12.81 10l-1.13 2H8a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h1.42l-1.13 2H8a3 3 0 0 1-3-3v-2a3 3 0 0 1 3-3z",fillRule:"evenodd"}));case"app-setting":return u.a.createElement("g",null,u.a.createElement("path",{d:"M2.001 4.5a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm0 6a2 2 0 1 1 0-4 2 2 0 0 1 0 4zm0 6a2 2 0 1 1 0-4 2 2 0 0 1 0 4z",fillRule:"evenodd"}));case"expand-palette":return u.a.createElement("g",null,u.a.createElement("circle",{cx:"14",cy:"20",r:"2"}),u.a.createElement("circle",{cx:"14",cy:"13",r:"2"}),u.a.createElement("circle",{cx:"14",cy:"6",r:"2"}));case"paint-brush":return u.a.createElement("g",null,u.a.createElement("path",{d:"M12.635 16.21c-.907-.787.159-3.439 2.38-5.92 2.22-2.482 4.756-3.855 5.663-3.068s-.16 3.44-2.38 5.922c-2.223 2.482-4.757 3.854-5.663 3.066zm.254 2.022a2.133 2.133 0 0 1-.7 1.718c-1.458 1.446-3.712 1.274-4.9.242a.84.84 0 0 1-.287-.576.844.844 0 0 1 .796-.89h.01c.077.001.553-.008.716-.513.009-.123.026-.242.054-.36a2.182 2.182 0 0 1 1.988-1.639c1.208-.073 2.247.83 2.323 2.018z",fillRule:"evenodd"}));case"dynamic":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14 13c3.87 0 7-1.34 7-3s-3.13-3-7-3-7 1.34-7 3 3.13 3 7 3zM9.72 9.44A11.35 11.35 0 0 1 14 8.7a11.35 11.35 0 0 1 4.28.74 3.26 3.26 0 0 1 .93.56 3.26 3.26 0 0 1-.93.56 11.35 11.35 0 0 1-4.28.74 11.35 11.35 0 0 1-4.28-.74 3.26 3.26 0 0 1-.93-.56 3.26 3.26 0 0 1 .93-.56zM14 19a11.06 11.06 0 0 1-4.16-.72l-.16-.08a9.17 9.17 0 0 1-2.41-1A1.48 1.48 0 0 0 7 18c0 1.66 3.13 3 7 3a15.86 15.86 0 0 0 1.9-.11 5 5 0 0 1-.81-1.89H14zM9.84 14.28l-.16-.08a9.17 9.17 0 0 1-2.41-1A1.48 1.48 0 0 0 7 14c0 1.66 3.13 3 7 3h1.14a4.22 4.22 0 0 1 1-2 3.29 3.29 0 0 1 .26-.23A13.27 13.27 0 0 1 14 15a11.06 11.06 0 0 1-4.16-.72zM21 17v-2h-2v2h-2v2h2v2h2v-2h2v-2h-2z",fillRule:"evenodd"}));case"search":return u.a.createElement("g",null,u.a.createElement("path",{d:"M12.13,5a4.88,4.88,0,0,0-4.18,7.39L5.23,15.11a.78.78,0,0,0,0,1.11l.55.55a.78.78,0,0,0,1.11,0l2.72-2.72A4.88,4.88,0,1,0,12.13,5Zm0,7.75A2.88,2.88,0,1,1,15,9.88,2.87,2.87,0,0,1,12.13,12.75Z"}));case"skew":return u.a.createElement("g",null,u.a.createElement("path",{d:"M23.28 7H12.16a2 2 0 0 0-1.74 1L3.85 19.5a1 1 0 0 0 .87 1.5h11.12a2 2 0 0 0 1.74-1l6.57-11.5a1 1 0 0 0-.87-1.5zm-7.69 12H6.7l5.71-10h8.89z",fillRule:"evenodd"}));case"rotate":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.66 10.73a1.15 1.15 0 0 0-.48 1.55A5.85 5.85 0 1 1 14 9.15v2.54a.5.5 0 0 0 .85.35l3.36-3.37a1 1 0 0 0 0-1.41L14.85 3.9a.5.5 0 0 0-.85.35v2.6a8.15 8.15 0 1 0 7.22 4.36 1.15 1.15 0 0 0-1.56-.48z",fillRule:"evenodd"}));case"transform-origin":return u.a.createElement("g",null,u.a.createElement("path",{d:"M24 7V5a1 1 0 0 0-1-1h-2a1 1 0 0 0-1 1h-4a1 1 0 0 0-1-1h-2a1 1 0 0 0-1 1H8a1 1 0 0 0-1-1H5a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1v4a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1v4a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1h4a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1h4a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1v-4a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1V8a1 1 0 0 0 1-1zm-3 5a1 1 0 0 0-1 1v2a1 1 0 0 0 1 1v4a1 1 0 0 0-1 1h-4a1 1 0 0 0-1-1h-2a1 1 0 0 0-1 1H8a1 1 0 0 0-1-1v-4a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1V8a1 1 0 0 0 1-1h4a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1h4a1 1 0 0 0 1 1z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M16 13v2a1 1 0 0 1-1 1h-2a1 1 0 0 1-1-1v-2a1 1 0 0 1 1-1h2a1 1 0 0 1 1 1z",fillRule:"evenodd"}));case"divi-logo":return u.a.createElement("g",null,u.a.createElement("path",{d:"M15.764 10c0.864 0 1.624 0.142 2.258 0.42 0.626 0.276 1.156 0.664 1.578 1.152 0.444 0.514 0.788 1.14 1.024 1.86 0.25 0.758 0.376 1.614 0.376 2.542 0 0.916-0.124 1.766-0.366 2.528-0.232 0.724-0.57 1.354-1.006 1.874-0.418 0.498-0.952 0.896-1.584 1.186-0.638 0.29-1.404 0.438-2.28 0.438h-2.764v-12h2.764zM15.764 8h-3.764c-0.552 0-1 0.448-1 1v14c0 0.55 0.45 1 1 1h3.764c1.162 0 2.208-0.208 3.11-0.62 0.904-0.414 1.672-0.99 2.284-1.718 0.606-0.72 1.070-1.58 1.38-2.552 0.306-0.96 0.462-2.014 0.462-3.136 0-1.142-0.16-2.206-0.476-3.166-0.32-0.972-0.794-1.826-1.41-2.542-0.62-0.716-1.388-1.28-2.284-1.676-0.89-0.39-1.922-0.59-3.066-0.59v0z",fillRule:"evenodd"}),u.a.createElement("path",{d:"M16 2c7.72 0 14 6.28 14 14s-6.28 14-14 14-14-6.28-14-14 6.28-14 14-14zM16 0c-8.836 0-16 7.164-16 16s7.164 16 16 16 16-7.164 16-16-7.164-16-16-16v0z",fillRule:"evenodd"}));case"global-presets-open":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.42 18.77h-.08c-1.75-.73-2.51-2.47-3.88-2.47s-2.11.53-2.88.43-.73-.91-1.28-1.37-.46-.31-1.49-.7-.24-2.3.48-2 1.31-.32 1.52.23.7 1.3.65.58a2.4 2.4 0 0 1 .79-2c.6-.56.1-.65.22-1.54s2.21.5 2.21-.32.36-.72 1-1.39.37-.88-.22-1.46a8 8 0 0 1 3.32 2.91c-1 .17-1.42.81-2 1.92-1 2 1.47 3.14 2.81 4l.24.12a8.08 8.08 0 0 1-1.41 3.06zM14 22a8 8 0 0 1-7.66-10.26 6.92 6.92 0 0 0 1 1.38c1 1.09.89 1.27.89 1.27.57 1.66 3.27.86 3.62 2.08s1.33.86.91 2.43a2.72 2.72 0 0 0 1.48 3.1zm0-18a10 10 0 1 0 10 10A10 10 0 0 0 14 4z"}));case"global-presets-return":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17.69 16a7.15 7.15 0 0 0 .6-4.46l2.22-.77a.93.93 0 0 0-.43-1.24l-3.71-1.86a.93.93 0 0 0-1.25.42l-1.87 3.83a1 1 0 0 0 .43 1.25l1.86-.74a4.23 4.23 0 0 1-.38 2.35c-.89 1.89-3.16 3.16-5.05 2.22-1.23-.6-4.89 1.2-.93 2.65A6.85 6.85 0 0 0 17.69 16z"}));case"responsive-orientation-portrait":return u.a.createElement("g",null,u.a.createElement("path",{className:"opacity-half",d:"M21,14H7a2,2,0,0,0-2,2v5a2,2,0,0,0,2,2H21a2,2,0,0,0,2-2V16A2,2,0,0,0,21,14Zm0,7H7V16H21Z"}),u.a.createElement("path",{d:"M12,5H7A2,2,0,0,0,5,7V21a2,2,0,0,0,2,2h5a2,2,0,0,0,2-2V7A2,2,0,0,0,12,5Zm0,16H7V7h5ZM22.94,9.75a.75.75,0,0,1-.22.53l-2.19,2.19a.75.75,0,0,1-1.06,0l-2.19-2.19A.75.75,0,0,1,17.81,9H19a2,2,0,0,0-2-2,1,1,0,0,1,0-2,4,4,0,0,1,4,4h1.19A.76.76,0,0,1,22.94,9.75Z"}));case"responsive-orientation-landscape":return u.a.createElement("g",null,u.a.createElement("path",{className:"opacity-half",d:"M7,7V21h5V7ZM7,5h5a2,2,0,0,1,2,2V21a2,2,0,0,1-2,2H7a2,2,0,0,1-2-2V7A2,2,0,0,1,7,5Z"}),u.a.createElement("path",{d:"M7,16v5H21V16Zm0-2H21a2,2,0,0,1,2,2v5a2,2,0,0,1-2,2H7a2,2,0,0,1-2-2V16A2,2,0,0,1,7,14Zm16-3a1,1,0,0,1-2,0,2,2,0,0,0-2-2v1.19a.75.75,0,0,1-1.28.53L15.53,8.53a.75.75,0,0,1,0-1.06l2.19-2.19A.75.75,0,0,1,19,5.81V7A4,4,0,0,1,23,11Z"}));case"pencil":return u.a.createElement("g",null,u.a.createElement("path",{transform:"scale(-1, 1) translate(-28, 0)",d:"M10.64,13.07l2.43-2.43,6.73,6.73L21,21l-3.63-1.2ZM7.52,7.52a1.78,1.78,0,0,1,2.51,0l1.21,1.26L8.73,11.29,7.52,10A1.78,1.78,0,0,1,7.52,7.52Z"}));case"blur":return u.a.createElement("g",null,u.a.createElement("path",{d:"M14.37,6.4a.51.51,0,0,0-.74,0Q8,12.64,8,15.9c0,3.37,2,6.1,6,6.1s6-2.73,6-6.1Q20,12.65,14.37,6.4ZM14,20c-3.61,0-4-2.86-4-4.1,0-.69.42-2.66,4-6.88,3.58,4.22,4,6.19,4,6.88C18,17.14,17.61,20,14,20Z"}));case"horizontal-motion":return u.a.createElement("g",null,u.a.createElement("path",{d:"M22.8,17.5a.56.56,0,0,1,0,.9l-3.5,2.1c-.4.2-.8,0-.8-.4V19H10a1,1,0,0,1,0-2h8.5V15.8a.52.52,0,0,1,.8-.4ZM19,10a.94.94,0,0,1-1,1H9.5v1.2a.52.52,0,0,1-.8.4L5.2,10.5a.56.56,0,0,1,0-.9L8.7,7.5c.4-.2.8,0,.8.4V9H18A.94.94,0,0,1,19,10Z"}));case"vertical-motion":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17.5,5.2a.56.56,0,0,1,.9,0l2.1,3.5c.2.4,0,.8-.4.8H19V18a1,1,0,0,1-2,0V9.5H15.8a.52.52,0,0,1-.4-.8ZM10,9a.94.94,0,0,1,1,1v8.5h1.2a.52.52,0,0,1,.4.8l-2.1,3.5a.56.56,0,0,1-.9,0L7.5,19.3c-.2-.4,0-.8.4-.8H9V10A.94.94,0,0,1,10,9Z"}));case"cursor":return u.a.createElement("g",null,u.a.createElement("path",{d:"M11.8,7.1c0.2,0,0.5,0.1,0.6,0.3l6.4,7.8c0.2,0.2,0.2,0.6-0.1,0.8c0,0-0.1,0.1-0.1,0.1L16.4,17l1.5,3.6 c0.2,0.6,0,1.3-0.6,1.5c-0.5,0.2-1.2,0-1.5-0.5l-0.1-0.1l-1.5-3.6l-2.5,1c-0.3,0.1-0.6,0-0.8-0.3c0-0.1-0.1-0.2-0.1-0.2V7.9 C11,7.5,11.4,7.1,11.8,7.1z"}));case"pin":return u.a.createElement("g",null,u.a.createElement("path",{d:"M17,13.3c1.2,0.3,2,0.7,2,1.2c0,0.7-1.7,1.3-4,1.5v3l-1,2l-1-2v-3c-2.3-0.1-4-0.7-4-1.5c0-0.5,0.8-0.9,2-1.2V9.7 C9.8,9.4,9,9,9,8.5C9,7.7,11.2,7,14,7s5,0.7,5,1.5c0,0.5-0.8,0.9-2,1.2V13.3z"}));case"caret-down":case"caret-left":case"caret-right":case"caret-up":return u.a.createElement("g",null,u.a.createElement("path",{d:"M13.4,16.66,10.13,12a.71.71,0,0,1-.09-.65.49.49,0,0,1,.44-.36h7a.49.49,0,0,1,.44.36.72.72,0,0,1-.08.64L14.6,16.66a.7.7,0,0,1-1.2,0Z"}));case"overflow":return u.a.createElement("g",null,u.a.createElement("path",{d:"M6,9.5A1.5,1.5,0,1,1,7.5,11,1.5,1.5,0,0,1,6,9.5ZM7.5,16A1.5,1.5,0,1,0,6,14.5,1.5,1.5,0,0,0,7.5,16Zm0,5A1.5,1.5,0,1,0,6,19.5,1.5,1.5,0,0,0,7.5,21Z"}));case"layers-view":return u.a.createElement("g",null,u.a.createElement("path",{d:"M19.89,15.66,19,15.13l-4.48,2.69a1,1,0,0,1-1,0L9,15.13l-.88.53a.39.39,0,0,0,0,.68l5.37,3.23a1,1,0,0,0,1,0l5.37-3.23A.39.39,0,0,0,19.89,15.66Z"}),u.a.createElement("path",{d:"M13.49,15.57a1,1,0,0,0,1,0l5.37-3.23a.4.4,0,0,0,0-.68L14.51,8.43a1,1,0,0,0-1,0L8.11,11.66a.4.4,0,0,0,0,.68ZM14,9.87,17.54,12,14,14.13,10.46,12Z"}));case"update-with-current-styles":return u.a.createElement("g",null,u.a.createElement("path",{d:"M18.55,8a.93.93,0,0,1,.28.28L21,11.45a1,1,0,0,1-.27,1.38,1,1,0,0,1-.56.17H19v7a1,1,0,0,1-.88,1H10a1,1,0,0,1-1-.88V10a1,1,0,0,1,2-.12V19h6V13H15.87a1,1,0,0,1-1-1,1,1,0,0,1,.17-.55l2.13-3.2A1,1,0,0,1,18.55,8Z"}));case"star":return u.a.createElement("g",null,u.a.createElement("path",{d:"M20.46,12.07l-3.82-.56a.55.55,0,0,1-.42-.3l-1.71-3.4a.56.56,0,0,0-1,0l-1.74,3.4a.53.53,0,0,1-.42.3l-3.81.56a.56.56,0,0,0-.31,1L10,15.62a.56.56,0,0,1,.17.5L9.5,19.84a.56.56,0,0,0,.8.6L14,18.55h0l3.69,1.89a.55.55,0,0,0,.8-.59l-.63-3.73a.56.56,0,0,1,.17-.5L20.77,13A.56.56,0,0,0,20.46,12.07Z"}));default:return!1}}},{key:"render",value:function(){var e=this.props,t=e.block,n=e.children,r=e.className,o=e.color,i=e.icon,a=e.iconSvg,s=e.size,l=e.viewBox;if(!i&&!a)return!1;var c={fill:o,width:2*s,minWidth:2*s,height:2*s,margin:-(s-8)};switch(i){case"caret-left":c=gi()(c,{transform:"rotate(90deg)"});break;case"caret-right":c=gi()(c,{transform:"rotate(-90deg)"});break;case"caret-up":c=gi()(c,{transform:"rotate(180deg)"})}var f=i?"et-fb-icon--".concat(i):"et-fb-icon--svg",d=Yo()({"et-fb-icon":!0,"et-fb-icon--block":t},f,r);if(a)return u.a.createElement("div",{className:d,style:gi()(c,this.props.style),dangerouslySetInnerHTML:{__html:a}});var p=this._renderGraphics();return p||(c={}),u.a.createElement("div",{className:d,style:gi()(c,this.props.style)},p?u.a.createElement("svg",{viewBox:l,preserveAspectRatio:"xMidYMid meet",shapeRendering:"geometricPrecision"},p):n)}}]),n}(s.PureComponent);Object.defineProperty(Ba,"defaultProps",{configurable:!0,enumerable:!0,writable:!0,value:{color:"#4c5866",size:14,viewBox:"0 0 28 28"}}),Object.defineProperty(Ba,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{className:Vo.a.string,color:Vo.a.string,block:Vo.a.bool,icon:Vo.a.string,iconSvg:Vo.a.string,size:Vo.a.oneOfType([Vo.a.string,Vo.a.number]),style:Vo.a.object,viewBox:Vo.a.string}});var Ha=Ba,Ua=n(140),Wa=n.n(Ua);var Va=function(e){var t,n=e.link,r=e.title,o=e.context,i=e.colorScheme,a=e.description,s=e.buttonText;if("save-modal"===o&&"paid"===i)return null;n||s||a||(n="divi-cloud/?utm_source=Divi+Cloud&utm_medium=Divi+Library&utm_campaign=Native",s=I("library","nonLoggedIn$upsellCTAButtonText"),a=I("library","nonLoggedIn$upsellCTADescription"),"free"===i&&(n="members-area/checkout/?type=divi-cloud&utm_source=Divi+Cloud&utm_medium=Divi+Library&utm_campaign=Native",s=I("library","loggedIn$upsellCTAButtonText"),a=I("library","loggedIn$upsellCTADescription")));var l=Yo()((t={"et-cloud-app__upsell":!0},Wa()(t,"card-".concat(o),!0),Wa()(t,"card-".concat(null!=i?i:"default"),!0),t));return u.a.createElement("div",{className:l},r&&u.a.createElement("h2",{className:"et-cloud-app__upsell-title"},r),u.a.createElement("p",{className:"et-cloud-app__upsell-description"},a),u.a.createElement("a",{href:"https://www.elegantthemes.com/"+n,target:"_blank"},s))},qa=n(48),Ya=n.n(qa),Ga=n(23),$a=n.n(Ga),Ka=n(28),Za=n.n(Ka),Xa=n(56),Qa=n.n(Xa),Ja=n(41),es=n.n(Ja);function ts(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var ns=function(e){zo()(n,e);var t=ts(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){return u.a.createElement("option",{value:this.props.value},this.props.name)}}]),n}(s.PureComponent);function rs(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var os=function(e){zo()(n,e);var t=rs(n);function n(){return Ao()(this,n),t.apply(this,arguments)}return Ro()(n,[{key:"render",value:function(){return u.a.createElement("optgroup",{label:this.props.label},this.props.children)}}]),n}(s.PureComponent);function is(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var as=function(e){zo()(n,e);var t=is(n);function n(){var e,r;Ao()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return Bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(Io()(r),"getGroupForSelected",{configurable:!0,enumerable:!0,writable:!0,value:function(){return jQuery(r.node).find(":selected").parent().attr("label")}}),Object.defineProperty(Io()(r),"_onChange",{configurable:!0,enumerable:!0,writable:!0,value:function(e){var t=r.props.name,n=r.getGroupForSelected(),o=r.props.overwrite_onchange,i=r.props.value_overwrite,a=e.target.value;n&&(R()(Io()(r),"props.parseGroupValue",!0)&&(a="".concat(n,"|").concat(a)),r.props.group_prop&&r.props._onChange(r.props.group_prop,n)),r.props._onChange(t,a),o&&$a()(o)&&i&&Za()(i)&&Ri()(r.props.overwrite_onchange,(function(e){yi()(i[a])||r.props._onChange(e,i[a])}))}}),e))}return Ro()(n,[{key:"componentDidMount",value:function(){this.props.group_prop&&this.props._onChange(this.props.group_prop,this.getGroupForSelected())}},{key:"_render_options",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Ri()(e,(function(e,n){var r=R()(e,"name"),o=R()(e,"id"),i=n;return""!==t&&(i="".concat(t,"-").concat(n)),u.a.createElement(ns,{key:i,value:o,name:r})}))}},{key:"render",value:function(){var e,t=this,n=Ya()(this.props.value)?this.props.value:this.props.default;!Qa()(es()(this.props.options),n)&&Qa()(es()(this.props.options),Ya()(n))&&(n=Ya()(n));var r={"et-core-control-select":!0,"et-fb-settings-option-select":!0};this.props.className&&(r[this.props.className]=!0),e=this.props.groups?Ri()(this.props.options,(function(e,n){return"0"===n?t._render_options(e,n):u.a.createElement(os,{label:n,key:"option-group-".concat(n)},t._render_options(e,n))})):this._render_options(this.props.options);var o={};this.props.readonly&&(o.disabled=!0);var i=this.props.id;return i||(i="et-fb-".concat(this.props.name)),u.a.createElement("select",z()({ref:function(e){return t.node=e},className:Yo()(r),value:n,name:this.props.name,id:i,onChange:this._onChange},o),e)}}]),n}(s.PureComponent);Object.defineProperty(as,"propTypes",{configurable:!0,enumerable:!0,writable:!0,value:{name:Vo.a.string.isRequired}});var ss=as,us=A.layoutCategories,ls=A.layoutTags,cs=function(){var e=B()(U.a.mark((function e(){return U.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,G("layout_category");case 2:return us=e.sent,e.next=5,G("layout_tag");case 5:ls=e.sent;case 6:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();var fs=function(e){var t=e.onClose,n=e.context,r=e.content,o=e.selectedContent,i=e.setCloudToken,a=e.onSave,u=e.modalType,l=e.cloudToggle,c=void 0===l?"off":l,f=e.onSaveBtnClick,d=void 0===f?L.noop:f,p=e.closeSaveItemsModal,h=void 0===p?L.noop:p,v=Object(s.useState)(""),g=Fi()(v,2),m=g[0],y=g[1],b=Object(s.useState)(!1),w=Fi()(b,2),_=w[0],x=w[1],k=Object(s.useState)("off"),C=Fi()(k,2),O=C[0],E=C[1],S=Object(s.useState)([]),T=Fi()(S,2),j=T[0],M=T[1],P=Object(s.useState)([]),R=Fi()(P,2),D=R[0],N=R[1],F=Object(s.useState)(""),H=Fi()(F,2),W=H[0],V=H[1],G=Object(s.useState)(""),$=Fi()(G,2),K=$[0],Z=$[1],X=Object(s.useState)({}),Q=Fi()(X,2),J=Q[0],ee=Q[1],te=Object(s.useState)(!1),ne=Fi()(te,2),re=ne[0],oe=ne[1],ie=Object(s.useState)(!1),ae=Fi()(ie,2),se=ae[0],ue=ae[1],le=Object(s.useState)({error:""}),ce=Fi()(le,2),fe=ce[0],de=ce[1],pe=Object(s.useState)(500),he=Fi()(pe,2),ve=he[0],ge=he[1],me=Object(s.useState)(""),ye=Fi()(me,2),be=ye[0],we=ye[1],_e=Object(s.useRef)(null),xe=function(e){switch(e){case"code_css":case"code_css_no_selector":return I("library","CSS Snippet");case"code_html":return I("library","HTML/JS Snippet");case"theme-options":return I("library","Theme Options");default:return I("library","Code Snippet")}}(n),ke=Object(s.useState)(Object(ya.a)()),Ce=Fi()(ke,1)[0],Oe=Object(s.useRef)(!1),Ee=Object(s.useState)({"et-save-to-library-option--input":!0,"et-save-to-library-option--input-error":!1}),Se=Fi()(Ee,2),Te=Se[0],je=Se[1],Me=Object(s.useState)([]),Le=Fi()(Me,2),Ae=Le[0],Pe=Le[1],Re=Object(s.useState)(!1),De=Fi()(Re,2),Ie=De[0],Ne=De[1],ze=Object(s.useState)(0),Fe=Fi()(ze,2),Be=Fe[0],He=Fe[1],Ue=Object(s.useState)(null),We=Fi()(Ue,2),Ve=We[0],qe=We[1],Ye="headless"===u;Object(s.useEffect)((function(){Oe.current||(Oe.current=!0)}),[W,K]),Object(s.useEffect)((function(){return"on"===c&&tt("cloud","on"),jQuery(window).on("et_export_to_cloud_complete",(function(){we("check"),h()})),function(){jQuery(window).off("et_export_to_cloud_complete")}}),[]);var Ge=function(e,t){"add"===t?M([].concat(ma()(j),[e])):"remove"===t&&M(j.filter((function(t){return t!==e})))},$e=function(e,t,n){if("add"===t){var r=parseInt(e.id);r&&N([].concat(ma()(D),[r]))}else"remove"===t&&(D.splice(e,1),N(ma()(D)))},Ke=function(){je({"et-save-to-library-option--input":!0,"et-save-to-library-option--input-error":!1}),y(""),E("off"),M([]),N([]),V(""),Z("")},Ze=function(){var e=B()(U.a.mark((function e(i){var s;return U.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return we("loading"),e.prev=1,i=void 0,u=void 0,l=void 0,c=void 0,f=void 0,d=void 0,p=void 0,i=Je(us,"categories").allTerms,u=Je(ls,"tags").allTerms,c=Y(j,i,l="on"===O),f=Y(D,u,l),d=0===Be?{}:Object(L.find)(Ae,{id:Be}),p=Object(L.isEmpty)(d)?"":"".concat(d.endpoint,"/cloud/v1"),s={item_name:m,selected_cats:c,selected_tags:f,new_category_name:W,new_tag_name:K,item_type:q(n),content:_&&""!==o?o:r,cloud:O,context:n,providedBaseUrl:p},e.next=5,a(s);case 5:Oe.current&&cs(),we("check"),setTimeout((function(){Ke(),we(""),t(!0),jQuery(window).trigger("et_code_snippets_library_close")}),1e3),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(1),we("close");case 13:case"end":return e.stop()}var i,u,l,c,f,d,p}),e,null,[[1,10]])})));return function(t){return e.apply(this,arguments)}}(),Xe=function(){var e=window.parent.innerHeight;if("headless"===u)return ge("auto");if(e>900)return ge(600);var t=Object(L.get)(_e,"current.clientHeight",0)+300;t>e&&(t=e-300),300>e-t&&(t-=300),ge(t)},Qe=Object(L.debounce)(Xe,250),Je=function(e,t){var n=[],r=[],o={};if("on"===O&&!Object(L.isEmpty)(Object(L.get)(J,t,{}))){var i=Object(L.orderBy)(J[t],["name"]);Object(L.forEach)(i,(function(e,t){var i=Object(L.unescape)(e.name);-1===n.indexOf(i)&&(n.push(i),r.push(i),o[e.id]=i)}))}return Object(L.isEmpty)(e)||Object(L.forEach)(e,(function(e,t){var r=Object(L.unescape)(e.name);-1===n.indexOf(r)&&(n.push(r),o[e.id]=r)})),{termsList:n,cloudTermsNames:r,allTerms:o}},et=function(){Object(L.isEmpty)(J)&&(oe(!0),ue(!0),Ne(Object(L.isEmpty)(Ae))),Ot().then((function(e){var t=Object(L.get)(e,"accessToken",""),n=Object(L.get)(e,"sharedFolders",[]),r=0===Be?{}:Object(L.find)(n,{id:Be});if(""===t)de(z()({},fe,{error:"auth_error"})),oe(!1),ue(!1),Ne(!1);else{i(t),qe(t);var o=Object(L.isEmpty)(r)?"":"".concat(r.endpoint,"/cloud/v1");_t({type:"categoriesList",perPage:100,pageNo:1,isUserItems:!0,token:t,providedBaseUrl:o}).then((function(e){e.error?de(z()({},fe,{error:"auth_error"})):(oe(!1),ee((function(t){return{tags:z()({},t.tags),categories:e.data}})))})),_t({type:"tagsList",perPage:100,pageNo:1,isUserItems:!0,token:t,providedBaseUrl:o}).then((function(e){e.error?de(z()({},fe,{error:"auth_error"})):(ue(!1),ee((function(t){return{categories:z()({},t.categories),tags:e.data}})))})),Object(L.isEmpty)(Ae)&&Pe(n),Ne(!1)}}))},tt=function(e,t){"headless"===u&&"off"===t||(E(t),"on"===t?et():(oe(!1),ue(!1)))},nt=function(e){if(Object(L.has)(e,"divi_cloud_token")){var t=pt(Object(L.get)(e,"divi_cloud_token"),Ce),n=1===Object(L.get)(e,"save_session_on_this_website",0);qe(t),de({cloudStatus:{}}),oe(!0),ue(!0),Ct(t,n).then((function(e){e.error?de({cloudStatus:e}):et()}))}},rt=function(e){E("off"),de({error:""})},ot=function(e){var t=e.target.value;y(t),je(""===t?{"et-save-to-library-option--input":!0,"et-save-to-library-option--input-error":!0}:{"et-save-to-library-option--input":!0,"et-save-to-library-option--input-error":!1})},it=function(e,t){He(t),ee({})},at=function(){E("off"),de({error:""})};Object(s.useEffect)((function(){return""!==o&&x(!0),window.addEventListener("resize",Qe),function(){window.removeEventListener("resize",Qe)}}),[]),Object(s.useLayoutEffect)((function(){Xe()}),[]),Object(s.useEffect)((function(){Be&&et()}),[Be]);var st=Ye?I("library","Save Items To Divi Cloud"):I("library","Save %s",xe);return React.createElement("div",{className:"et-save-to-library-modal"},React.createElement(ta,{animation:!0,modalKey:"et-save-to-library-modal-key",ref:_e},React.createElement(ta.Header,{onClose:function(){Ke(),t(),jQuery(window).trigger("et_code_snippets_library_close")}},st),React.createElement(ta.Content,{style:{height:ve}},function(){if(""!==Object(L.get)(fe,"error",""))return React.createElement("div",null,React.createElement("div",{className:"et-cloud-login-notification"},React.createElement("h3",null,I("library","Log In To Divi Cloud"))),React.createElement(za,{api:A.api,setDomainTokenNonce:A.nonces.saveDomainToken,domain:A.site_domain,frameWidth:400,frameHeight:600,sendMessage:nt,queryParams:{cloud_id:Ce},onFrameClose:function(){return rt()},isCloud:!0}))}(),function(){var e=Object(L.get)(fe,"error",""),t="allowed"===A.localCategoriesEdit;if(""===e){var n=React.createElement("div",{className:"et-save-to-library-option"},React.createElement(la,{value:"save",checked:_,onChange:function(e){return x(e.target.checked)}},I("library","Save Selection Only")));""===o&&(n=null);var r,i="on"===O?function(){if(Ie)return React.createElement("div",{className:"et-save-to-library-option",style:{height:"60px"}},React.createElement(ji,null));var e=Object(L.filter)(Ae,(function(e){return!0===Object(L.get)(e,"permissions.add")})),t=Object(L.sortBy)(e,["name"]);if(Object(L.isEmpty)(t))return null;var n=Object(L.map)(t,(function(e){var t="".concat(Object(L.get)(e,"name",""),"'s Cloud");return z()({},e,{name:t})}));return n.unshift({id:0,name:I("library","My Cloud")}),React.createElement("div",{className:"et-save-to-library-option"},React.createElement("label",{className:"et-save-to-library-option--label"},I("library","Choose Library")),React.createElement("div",{className:"et-save-to-library-option-container"},React.createElement(ss,{id:"et-save-to-library-option--select-cloud-folders",className:"et-save-to-library-option--select-cloud-folders",name:I("library","Choose Library"),options:n,_onChange:it,value:Be,group_prop:!1})))}():null,a=Ye?React.createElement("p",{className:"et-save-to-library-description"},I("library","Save items to the Divi Cloud for later use")):React.createElement("p",{className:"et-save-to-library-description"},I("library","Save this %s to the Divi Library for later use.",xe)),l=Ye?null:React.createElement("div",{className:"et-save-to-library-option"},React.createElement("label",{className:"et-save-to-library-option--label"},I("library","%s Name",xe)),React.createElement("div",{className:"et-save-to-library-option-container"},React.createElement(ia,{value:m,onChange:ot,className:Yo()(Te),placeholder:I("library","Divi Library %s Name",xe)}))),c=Ye?null:React.createElement("div",{className:"et-save-to-library-option"},React.createElement("label",{className:"et-save-to-library-option--label"},"Add To Category"),React.createElement("div",{className:"et-save-to-library-option-container"},function(){if(re)return React.createElement(ji,null);var e=Je(us,"categories"),t=e.allTerms,n=e.cloudTermsNames;return React.createElement(Oa,{allCategories:t,onCategoriesChange:Ge,selectedCategories:j,markedCategories:n,categoryMark:"on"===O?React.createElement(_i,{icon:"cloud",color:"#0088E1",className:"et-cloud-category-mark",elementType:"span"}):""})}(),t&&React.createElement(ia,{value:W,onChange:function(e){return V(e.target.value)},className:"et-save-to-library-option--input",placeholder:I("library","Create New Category/Categories")}))),f=Ye?null:React.createElement("div",{className:"et-save-to-library-option"},React.createElement("label",{className:"et-save-to-library-option--label"},"Add To Tags"),React.createElement("div",{className:"et-save-to-library-option-container"},function(){if(se)return React.createElement(ji,null);var e=Je(ls,"tags"),t=e.allTerms,n=e.cloudTermsNames;return React.createElement(La,{allTags:t,selectedTags:D,onTagsChange:$e,markedTags:n})}(),t&&React.createElement(ia,{value:K,onChange:function(e){return Z(e.target.value)},className:"et-save-to-library-option--input",placeholder:I("library","Create New Tag(s)"),style:{marginTop:"10px"}})));return React.createElement(s.Fragment,null,a,l,n,React.createElement("div",{className:Yo()({"et-save-to-library-option":!0,"et-save-to-library-option--hidden":"headless"===u})},React.createElement("label",{className:"et-save-to-library-option--label"},"Save To Divi Cloud"),React.createElement("div",{className:"et-save-to-library-option-container"},React.createElement(xa,{name:"cloud",value:O,className:{"et-common-toggle__cursor_default":"headless"===u},onChange:tt}))),(r="on"===O?dt(Ve).dcst:"default",React.createElement(Va,{context:"save-modal",colorScheme:r})),i,c,f)}}()),React.createElement(ta.Actions,null,Object(L.get)(fe,"error","")?React.createElement(hi,{className:"et-common-button et-common-button--cancel",onClick:at},"Cancel"):React.createElement(hi,{className:"et-common-button--primary",onClick:function(e){return function(e){if("headless"!==u){var t=""!==m;je({"et-save-to-library-option--input":!0,"et-save-to-library-option--input-error":!t}),t&&Ze()}else{var n;we("loading");var r=Object(L.filter)(Ae,(function(e){return e.id===Be})),o=(null==r||null===(n=r[0])||void 0===n?void 0:n.endpoint)||"";d(e,o,J)}}(e)}},""!==be&&React.createElement(Ha,{size:"14",icon:be,color:"#FFFFFF"}),""===be&&"on"===O&&I("library","Save To Divi Cloud"),""===be&&"on"!==O&&I("library","Save To Library")))))},ds=n(219),ps=n(220),hs=n.n(ps),vs=n(141),gs=n.n(vs),ms=n(221),ys=n.n(ms),bs=n(65),ws=n.n(bs),_s=n(222),xs=n.n(_s),ks=(n(433),n(127),n(434),n(437),n(438),n(439),n(441),n(191),n(442),n(443),n(444),n(126),n(445),n(193),n(446),n(447),n(448),n(223)),Cs=n.n(ks),Os=n(89),Es=n.n(Os),Ss=n(224),Ts={"known-properties":1,"duplicate-properties":1},js={coverGutter:!1,noHScroll:!0},Ms=function(e){var t=e.message,n=e.line,r=e.type;return{description:t.replace(/ \w+ \w+ \d+, \w+ \d+\.$/,"."),line:n,type:r}},Ls=function(){function e(t,n,r){Ao()(this,e),this.mode=t,this.editor=n,this.delay=r,this.timer=0,this.lineWidgets=[],this.doLint=this.doLint.bind(this),this.removeLineWidget=this.removeLineWidget.bind(this),this.showErrors=this.showErrors.bind(this),this.showError=this.showError.bind(this)}return Ro()(e,[{key:"lint",value:function(e){clearTimeout(this.timer);var t=yi()(e)?this.delay:e;0===t?this.doLint():this.timer=setTimeout(this.doLint,t)}},{key:"doLint",value:function(){this.editor&&this.editor.operation(this.showErrors)}},{key:"getErrors",value:function(){var e,t=this.editor.getValue();switch(this.mode.name){case"css":var n=this.mode.inline?"p {".concat(t,"}"):t,r=Ss.CSSLint.verify(n,Ts).messages;e=Cs()(r,Es.a).map(Ms);break;default:e=[]}return e}},{key:"removeLineWidget",value:function(e){this.editor.removeLineWidget(e)}},{key:"showError",value:function(e){var t=this.editor,n=e.description,r=e.line,o=e.type,i=document.createElement("div");return i.appendChild(document.createTextNode("".concat(n))),i.className="codemirror-lint-".concat(o),t.addLineWidget(r-1,i,js)}},{key:"showErrors",value:function(){Hi()(this.lineWidgets)||ws()(this.lineWidgets,this.removeLineWidget);var e=this.getErrors();Hi()(e)?this.lineWidgets=[]:this.lineWidgets=e.map(this.showError)}},{key:"destroy",value:function(){clearTimeout(this.timer),this.editor=!1}}]),e}();function As(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=Uo()(e);if(t){var o=Uo()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return Bo()(this,n)}}var Ps=100,Rs=500,Ds=2e3,Is={common:{keyMap:"sublime",autofocus:!1,cursorBlinkRate:0,viewportMargin:1/0,theme:"et",styleActiveLine:!0,matchBrackets:!0,autoCloseBrackets:!0,autoCloseTags:!0,lineWrapping:!0,lineNumbers:!0,indentUnit:2,tabSize:2},modes:{css:{mode:{name:"css",inline:!0},colorpicker:{mode:"edit"},lineBreakPlaceholder:/\|\||<!-- \[et_pb_line_break_holder\] -->/},html:{mode:{name:"htmlmixed"},colorpicker:{mode:"edit"},matchTags:{bothTags:!0},lineBreakPlaceholder:/<!-- \[et_pb_line_break_holder\] -->/}}},Ns={line:0,ch:0},zs={ignoreKeys:[13,37,39],prefix:{css:/[A-z-]/,default:/[A-z]/},tokens:{xml:["attribute","tag"]}},Fs=function(e){var t=R()(e,e.is_fb_content?"content":"value");return t===e.default?"":t},Bs=function(e){e.hideCompletion(),e.hideColorPicker()},Hs=new(function(){function e(){Ao()(this,e),this.instances=[],this.listener=!1,this.$window=jQuery(window),this.onScroll=this.onScroll.bind(this)}return Ro()(e,[{key:"add",value:function(e){this.instances.push(e),this.check()}},{key:"remove",value:function(e){xs()(this.instances,e),this.check()}},{key:"onScroll",value:function(){ws()(this.instances,Bs)}},{key:"check",value:function(){this.instances.length>0?this.listener||(this.$window.on("wheel scroll",this.onScroll),this.listener=!0):this.listener&&(this.$window.off("wheel scroll",this.onScroll),this.listener=!1)}}]),e}()),Us=0;function Ws(e){var t=this,n=e.lineNo,r=e.ch,o=e.nameColor,i=e.color;if(this.colorpicker){var a=i,s=this.cm.charCoords({line:n,ch:r},"window");this.colorpicker.show({left:s.left,top:s.bottom+Us,isShortCut:e.isShortCut||!1,hideDelay:this.opt.hideDelay||2e3},o||i,(function(e){t.cm.replaceRange(e,{line:n,ch:r},{line:n,ch:r+a.length},"*colorpicker"),a=e})),jQuery(this.colorpicker.$root.el).css({top:"".concat(s.bottom+Us,"px"),left:hs()(s.left)?"".concat(s.left,"px"):s.left})}}var Vs=function(e){zo()(n,e);var t=As(n);function n(e){var r;Ao()(this,n),(r=t.call(this,e)).editor=!1,r.dirty=!1,r.markers=[],r.mode=R()(e,"mode","css"),r.options=z()({},Is.common,R()(Is.modes,r.mode,{}),{readOnly:R()(e,"readOnly",!1),cursorBlinkRate:R()(e,"cursorBlinkRate",Is.cursorBlinkRate),lint:R()(e,"lint",!0)}),Da()(r.options,"mode.inline")&&Da()(e,"inline")&&(r.options.mode.inline=e.inline),r.completion=R()(zs.prefix,r.mode,zs.prefix.default),r.onChange=r.onChange.bind(Io()(r)),r.onClick=r.onClick.bind(Io()(r)),r.onKeyUp=r.onKeyUp.bind(Io()(r)),r.onKeyDown=r.onKeyDown.bind(Io()(r)),r._onFocus=r._onFocus.bind(Io()(r)),r._onBlur=r._onBlur.bind(Io()(r)),r.onBeforeChange=r.onBeforeChange.bind(Io()(r)),r.editorDidMount=r.editorDidMount.bind(Io()(r)),r.activateEditor=r.activateEditor.bind(Io()(r)),r.getEditor=r.getEditor.bind(Io()(r)),r.debouncedShowCompletion=gs()(r.showCompletion,Rs),r.debouncedUpdateSettings=gs()(r.updateSettings,Ps),r.incrementalKey=0;var o=r.addLineBreaks(Fs(e)),i=r.addLineBreaks(r.props.default);return r.state={value:o,default:i,enabled:!Hi()(o)||!Hi()(i),focused:!1},r}return Ro()(n,[{key:"componentDidMount",value:function(){Hs.add(this)}},{key:"UNSAFE_componentWillReceiveProps",value:function(e){var t=this.addLineBreaks(Fs(e));if(this.state.enabled||Hi()(t)&&Hi()(this.state.default)||this.enableEditor(),this.state.value!==t||e.activeTabMode!==this.props.activeTabMode){var n=this.addLineBreaks(e.default);this.setState({default:n}),this.dirty||(this.incrementalKey++,this.setValue(t))}}},{key:"componentDidUpdate",value:function(){if(this.editor){var e=this.editor;if(ws()(this.markers,(function(e){e.clear()})),this.markers=[],Hi()(R()(this,"props.search")))return;for(var t=e.getSearchCursor(this.props.search);t.findNext();)this.markers.push(e.doc.markText(t.from(),t.to(),{className:"cm-searching",clearOnEnter:!0}))}}},{key:"componentWillUnmount",value:function(){this.hideCompletion(),this.hideColorPicker(),Hs.remove(this),this.debouncedShowCompletion.cancel(),this.debouncedUpdateSettings.flush(),this.editor=!1,this.linter&&this.linter.destroy()}},{key:"onBeforeChange",value:function(e,t,n){this.dirty=!0,this.setValue(n)}},{key:"onChange",value:function(){Ps>0?this.debouncedUpdateSettings():this.updateSettings(),this.lint()}},{key:"onKeyUp",value:function(e,t){this.checkCompletion(e,t)}},{key:"onKeyDown",value:function(e,t){"Enter"!==t.key&&13!==t.keyCode||t.stopPropagation()}},{key:"onClick",value:function(){this.options.autofocus=!0,this.enableEditor()}},{key:"setValue",value:function(e){this.setState({value:e})}},{key:"addLineBreaks",value:function(e){if(yi()(e)||!Pa()(e))return e;var t=this.options.lineBreakPlaceholder;return e.match(t)?e.split(t).join("\n"):e}},{key:"enableEditor",value:function(){this.setState({enabled:!0})}},{key:"lint",value:function(e){this.linter&&this.linter.lint(e)}},{key:"editorDidMount",value:function(e){this.editor=e;var t=e.state.colorpicker;t&&ys()(t,"open_color_picker",Ws.bind(t)),this.props.lint&&(this.linter=new Ls(this.options.mode,e,Ds),this.lint(0))}},{key:"updateSettings",value:function(){var e=this.props;e._onChange(e.name,this.state.value,e.type),this.dirty=!1}},{key:"hideCompletion",value:function(){this.debouncedShowCompletion.cancel(),this.editor&&this.editor.state.completionActive&&this.editor.state.completionActive.close()}},{key:"hideColorPicker",value:function(){this.editor&&this.editor.state.colorpicker&&this.editor.state.colorpicker.close_color_picker()}},{key:"checkCompletion",value:function(e,t){if(Qa()(zs.ignoreKeys,t.keyCode))this.hideCompletion();else{var n=e.doc,r=n.getCursor(),o=r.line,i=r.ch,a=R()(e.getModeAt(r),"name"),s=n.getLine(o),u=s.substr(Math.max(i-1,0),1),l=s.substr(i,1);if(this.completion.test(u)&&!this.completion.test(l)){var c=R()(zs,"tokens.".concat(a));if(c){var f=e.getTokenTypeAt(r);if(!Qa()(c,f))return void this.hideCompletion()}this.debouncedShowCompletion()}else this.hideCompletion()}}},{key:"showCompletion",value:function(){if(!this.editor.state.completionActive){var e=window.parent.body;this.editor.showHint({completeSingle:!1,container:e})}}},{key:"activateEditor",value:function(){this.enableEditor()}},{key:"getEditor",value:function(){return this.editor}},{key:"render",value:function(){var e,t=this.props,n=t.name,r=t.classList,o=z()({},this.options,{lineNumbers:this.state.focused||!Hi()(this.state.value)||Hi()(this.state.default),placeholder:this.state.default});e=u.a.createElement(ds.Controlled,{key:this.incrementalKey,value:this.state.value,options:o,cursor:this.options.autofocus?Ns:null,autoFocus:this.options.autofocus,name:n,id:"et-common-".concat(n),onChange:this.onChange,onBeforeChange:this.onBeforeChange,onKeyUp:this.onKeyUp,onKeyDown:this.onKeyDown,editorDidMount:this.editorDidMount,onFocus:this._onFocus,onBlur:this._onBlur});var i=z()({},r,{"et-common-codemirror":!0});return u.a.createElement("div",{className:Yo()(i)},e)}},{key:"_onFocus",value:function(){this.setState({focused:!0})}},{key:"_onBlur",value:function(){this.setState({focused:!1})}}]),n}(u.a.PureComponent);Vs.propTypes={className:Vo.a.string,inline:Vo.a.bool,lint:Vo.a.bool,name:Vo.a.string.isRequired,search:Vo.a.string,value:Vo.a.string},Vs.defaultProps={className:"",inline:!0,lint:!0,search:"",value:""};var qs,Ys,Gs,$s,Ks,Zs,Xs,Qs=Vs,Js=function(e,t){var n=Object(h.get)(e,t,"");for(var r=arguments.length,o=new Array(r>2?r-2:0),i=2;i<r;i++)o[i-2]=arguments[i];if(o.length>0){var a=Object(h.get)(window,"wp.i18n.sprintf");return a.apply(void 0,[n].concat(o))}return n},eu=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return Js.apply(void 0,[window.et_code_snippets_data.i18n,[e,t]].concat(r))};var tu,nu,ru,ou,iu,au={item:Object(d.state)(qs||(qs=y()(["edit.item"]))),snippet:Object(d.state)(Ys||(Ys=y()(["edit.snippet"]))),saveState:Object(d.state)(Gs||(Gs=y()(["edit.saveState"]))),progress:Object(d.state)($s||($s=y()(["edit.progress"]))),context:Object(d.state)(Ks||(Ks=y()(["edit.context"]))),onClose:Object(d.sequences)(Zs||(Zs=y()(["edit.closeEditModal"]))),onSave:Object(d.sequences)(Xs||(Xs=y()(["edit.saveEditedContent"])))},su=Object(p.connect)(au,(function(e){var t=e.saveState,n=e.item,r=e.snippet,o=e.progress,i=e.onClose,a=e.onSave,u=e.context,l=q(u),c="et_code_snippet_html_js"===l?"html":"css",f="et_code_snippet_css_no_selector"===l,d=Object(s.useState)(""),p=So()(d,2),h=p[0],v=p[1],g=function(){switch(t){case"error":return"cross";case"loading":return"loading";case"success":return"check";case"idle":default:return""}}(),m=function(){a({content:h})},y=function(e,t,n){"codeSnippetEditor"===e&&v(t)},b=function(){return React.createElement(ta.Header,{onClose:i},eu("library","Edit %s",n.name))},w=function(){return React.createElement(ta.Actions,null,React.createElement(hi,{className:"et-common-button--cancel",onClick:i},eu("library","Cancel")),0===o&&React.createElement(hi,{className:"et-common-button--secondary",onClick:m},""!==g&&React.createElement(Ha,{size:"14",icon:g,color:"#FFFFFF"}),""===g&&eu("library","Save")))};return Object(s.useEffect)((function(){v(r)}),[r]),React.createElement("div",{className:"divi-cloud-item-editor"},React.createElement("div",{className:"divi-cloud-item-editor-overlay"},React.createElement("div",{className:"divi-cloud-item-editor-modal-positioner"},React.createElement(ta,{animation:!0,modalKey:"divi-cloud-item-editor"},function(){if(0!==o)return React.createElement(s.Fragment,null,b(),React.createElement(ta.Content,null,React.createElement(Si,{progress:o})),w())}(),function(){if(0===o)return React.createElement(s.Fragment,null,b(),React.createElement(ta.Content,null,React.createElement(Qs,{value:h,name:"codeSnippetEditor",inline:f,mode:c,_onChange:y})),w())}()))))})),uu=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(Object(h.isEmpty)(t))return!0;var r=n?"off":"on";return Object(h.isArray)(t)?Object(h.every)(t,(function(t){return"on"===Object(h.get)(e,t,r)})):"on"===Object(h.get)(e,t,r)},lu=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return uu.apply(void 0,[ro.capabilities].concat(t))};var cu,fu,du,pu,hu,vu,gu,mu,yu,bu,wu,_u,xu,ku,Cu,Ou,Eu,Su,Tu,ju,Mu,Lu,Au,Pu,Ru,Du,Iu,Nu,zu,Fu,Bu,Hu,Uu={context:Object(d.state)(tu||(tu=y()(["context"]))),content:Object(d.state)(nu||(nu=y()(["content"]))),importState:Object(d.state)(ru||(ru=y()(["importState"]))),exportSnippet:Object(d.sequences)(ou||(ou=y()(["exportSnippet"]))),insertSnippet:Object(d.sequences)(iu||(iu=y()(["insertSnippet"])))},Wu=Object(p.connect)(Uu,(function(e){var t=Object(s.useState)("export"),n=So()(t,2),r=n[0],o=n[1],i=Object(s.useState)(eu("library","Code Snippet")),a=So()(i,2),l=a[0],c=a[1],f=Object(s.useState)(""),d=So()(f,2),p=d[0],v=d[1],g=e.context,m=e.content,y=e.onClose,b=e.codeMirrorId,w=e.exportSnippet,_=e.insertSnippet,x=e.insertCodeCallback,k=e.importState,C=e.isCloudAvailable,O=function(){w({id:1,fileName:l,directExport:{snippet_type:q(g),content:m}})},E=""!==m,S=E,T=eu("library",E?"Import & Export Snippet":"Import Snippet"),j=E?r:"import";return u.a.createElement("div",{className:"et-core-modal-overlay et-core-form et-core-active"},u.a.createElement(da,{heading:T,title:eu("library","Snippet"),subTitle:eu("library","Code Snippet"),fileName:l,state:j,tabMode:S,isCloudAvailable:C,setTab:o,importState:k,importError:p,onClose:y,onFileNameChange:c,onPortabilityExport:O,onPortabilityImport:function(e,t,n){var r=new FileReader;r.readAsText(e),r.onload=function(){var e=JSON.parse(r.result);e.snippet_type===q(g)?(n&&(c("code-snippet.json"),O()),_({codeMirrorId:b,snippetId:!1,snippetContent:e.data,isAppend:!t,skipInsert:!Object(h.isUndefined)(x)}).then(y)):v(eu("library","importContextFail"))}}}))}));var Vu={content:Object(d.state)(cu||(cu=y()(["content"]))),context:Object(d.state)(fu||(fu=y()(["context"]))),importError:Object(d.state)(du||(du=y()(["importError"]))),isEditItemModalOpen:Object(d.state)(pu||(pu=y()(["computed.isEditItemModalOpen"]))),items:Object(d.state)(hu||(hu=y()(["items"]))),itemsLoadedAndCached:Object(d.state)(vu||(vu=y()(["itemsLoadedAndCached"]))),selectedContent:Object(d.state)(gu||(gu=y()(["selectedContent"]))),showLibraryModal:Object(d.state)(mu||(mu=y()(["showLibrary"]))),showPortability:Object(d.state)(yu||(yu=y()(["showPortability"]))),showSaveModal:Object(d.state)(bu||(bu=y()(["showSave"]))),sidebarLabel:Object(d.state)(wu||(wu=y()(["sidebarLabel"]))),snippetCode:Object(d.state)(_u||(_u=y()(["snippetCode"]))),snippetCodeAppend:Object(d.state)(xu||(xu=y()(["snippetCodeAppend"]))),importState:Object(d.state)(ku||(ku=y()(["importState"]))),setContext:Object(d.sequences)(Cu||(Cu=y()(["setLibraryContext"]))),loadItems:Object(d.sequences)(Ou||(Ou=y()(["loadItems"]))),updateItem:Object(d.sequences)(Eu||(Eu=y()(["updateItem"]))),insertSnippet:Object(d.sequences)(Su||(Su=y()(["insertSnippet"]))),exportSnippet:Object(d.sequences)(Tu||(Tu=y()(["exportSnippet"]))),importSnippet:Object(d.sequences)(ju||(ju=y()(["importSnippet"]))),openPortablity:Object(d.sequences)(Mu||(Mu=y()(["openPortablity"]))),closePortability:Object(d.sequences)(Lu||(Lu=y()(["closePortability"]))),getExportedItem:Object(d.sequences)(Au||(Au=y()(["getExportedItem"]))),toggleLibraryItemLocation:Object(d.sequences)(Pu||(Pu=y()(["toggleLibraryItemLocation"]))),setShowLibraryModal:Object(d.sequences)(Ru||(Ru=y()(["setShowLibrary"]))),resetSnippetCode:Object(d.sequences)(Du||(Du=y()(["resetSnippetCode"]))),setShowSaveModal:Object(d.sequences)(Iu||(Iu=y()(["setShowSaveModal"]))),downloadSnippetContent:Object(d.sequences)(Nu||(Nu=y()(["downloadSnippetContent"]))),updateLocalFilters:Object(d.sequences)(zu||(zu=y()(["updateLocalFilters"]))),openEditModal:Object(d.sequences)(Fu||(Fu=y()(["edit.openEditModal"]))),setCloudToken:Object(d.sequences)(Bu||(Bu=y()(["setCloudToken"]))),cacheCloudToken:Object(d.sequences)(Hu||(Hu=y()(["cacheCloudToken"])))},qu=Object(p.connect)(Vu,(function(e){var t=Object(s.useState)({}),n=So()(t,2),r=n[0],o=n[1],i=Object(s.useState)(!1),a=So()(i,2),l=a[0],c=a[1],f=Object(s.useState)(""),d=So()(f,2),p=d[0],v=d[1],m=Object(s.useState)(!1),y=So()(m,2),b=(y[0],y[1],Object(s.useState)(1)),w=So()(b,2),_=(w[0],w[1],Object(s.useState)({error:""})),x=So()(_,2),k=x[0],C=x[1],O=Object(s.useState)(Object(Mo.v4)()),E=(So()(O,1)[0],Object(s.useState)(!1)),S=So()(E,2),T=(S[0],S[1],Object(h.get)(window,"globalCloudToken",null));function j(){var t=e.setContext,n=e.setShowLibraryModal;l?c(!1):(t({context:""}),n({toggle:!1}),jQuery(window).trigger("et_code_snippets_library_close"))}var M=function(){e.loadItems()},L=function(e,t,n){t?c(!1):(v(n||eu("library","Code Snippet Details")),c(!0))},P=function(t,n){var r=e.openEditModal,o=e.context,i=n.item;switch(window.ETCloudApp&&"cloud"===(null==i?void 0:i.item_location)&&setTimeout((function(){window.ETCloudApp.emitSignal({signal:"onDownloadProgress",data:{progress:200}}),window.ETCloudApp.emitSignal({signal:"finishDownload",data:{}})}),1e3),n.action){case"edit":r({item:i,content:Object(h.get)(n,"content",{}),context:o})}},R=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=t;H(r,n)},D=function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=e.context,r=e.setContext,o=e.setShowSaveModal,i="headless"===Q;t&&Sr(n,!1),r({context:""}),o({toggle:!1}),i&&jQuery('[data-et-core-portability="et_builder_layouts"]').addClass("et-core-active")},I=function(e){return"on"===e.cloud?function(e){var t=e.content,n=e.new_category_name,r=e.new_tag_name,o=e.selected_tags,i=e.selected_cats,a=e.item_type,s=e.context,u=e.item_name,l=e.providedBaseUrl,c=n.split(",").map((function(e){return Object(h.trim)(e)})),f=r.split(",").map((function(e){return Object(h.trim)(e)})),d={tags:[].concat(Oo()(o),Oo()(f)),categories:[].concat(Oo()(i),Oo()(c))},p={context:"et_code_snippet",data:t,snippet_type:a};return xt(s,{title:u,content:JSON.stringify(p),status:"publish"},d,h.noop,0,l)}(e):V(g()({action:"et_library_save_item",et_library_save_item_nonce:A.nonces.et_library_save_item,post_type:A.post_types.et_code_snippet},e))},N=function(){var t=e.setContext,n=e.closePortability;t({context:""}),n(),jQuery(window).trigger("et_code_snippets_library_close")},z=function(){T&&(window.ETCloudApp.setCloudToken(T),window.ETCloudApp.setSharedFolders())},F=function(){e.cacheCloudToken(),et_cloud_data.initialCloudStatus="on"},B=function(){e.setCloudToken({cloudToken:""}),et_cloud_data.initialCloudStatus="off"},H=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(e.setContext,e.setShowSaveModal,window.et_export_layout_response),o=(Object(h.size)(r.data),""),i=Object(h.get)(k,"error","");Ot().then(function(){var e=ko()(jo.a.mark((function e(a){var s,u,l,c,f;return jo.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:o=Object(h.get)(a,"accessToken",""),Object(h.get)(o,"dcst",""),""===o&&"auth_error"!==i?C(g()({},k,{error:"auth_error"})):""!==o&&(s=[],u=0,l=Object(h.get)(n,"tags",{}),c=Object(h.get)(n,"categories",{}),Object(h.forEach)(r.data,(function(e){var t="",n=!1,o=[],i=[],a={context:"et_builder",data:{1:e.post_content},presets:r.presets,global_colors:r.global_colors,images:r.images};if(Object(h.isEmpty)(e.terms)||Object(h.forEach)(e.terms,(function(e){switch(e.taxonomy){case"layout_type":t=e.name;break;case"layout_category":var r=Object(h.find)(c,["name",e.name]);Object(h.isUndefined)(r)||i.push(r.id);break;case"layout_tag":var a=Object(h.find)(l,["name",e.name]);Object(h.isUndefined)(a)||o.push(a.id);break;case"module_width":n="fullwidth"===e.name}})),Object(h.size)(r.data)>1){var f={};Object(h.isEmpty)(r.images)||Object(h.forEach)(r.images,(function(t,n){-1!==e.post_content.indexOf(n)&&(f[n]=t)})),a.images=f}var d={title:e.post_title,content:JSON.stringify(a),categories:i,tags:o,meta:{},status:"publish",width:n?"fullwidth":""};Object(h.has)(e,"post_meta._et_pb_module_type")&&(d.meta._et_pb_module_type=e.post_meta._et_pb_module_type[0]),Object(h.has)(e,"post_meta._et_pb_row_layout")&&(d.meta._et_pb_row_layout=e.post_meta._et_pb_row_layout[0]),Object(h.get)(s,u)?Object(h.size)(s[u])>5&&(u++,s[u]=[]):s[u]=[],s[u].push({itemType:t,newCloudItem:d})})),Object(h.isEmpty)(s)||(f=[],Object(h.forEach)(s,(function(e){Object(h.forEach)(e,(function(e){var n=e.itemType,r=e.newCloudItem;f.push(new Promise((function(e){kt(o,n,r,{},!1,0,t).then((function(t){t&&Object(h.get)(t,"code"),e(t)}))})))}))})),f.reduce((function(e,t){return e.then(t).catch((function(e){console.warn("err",e.message)}))}),Promise.resolve()).then((function(){jQuery(window).trigger("et_export_to_cloud_complete")}))));case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}())},U=function(){var t=e.setContext,n=e.setShowSaveModal;t({context:""}),n({toggle:!1}),jQuery(window).trigger("et_code_snippets_library_close")};Object(s.useEffect)((function(){var t,n;return function(){var t=e.setShowLibraryModal,n=e.loadItems,r=e.codeMirrorId,i=e.modalType,a=e.resetSnippetCode;e.context,"add"===i&&(a(),o(r),t({toggle:!0}),n())}(),t=e.setShowSaveModal,n=e.codeMirrorId,"save"===e.modalType&&(o(n),t({toggle:!0})),function(){var t=e.modalType,n=e.setShowSaveModal;"headless"===t&&window.etCore&&(window.etCore.modalClose(),setTimeout((function(){n({toggle:!0})}),300))}(),function(){var t=e.openPortablity,n=e.codeMirrorId;"portability"===e.modalType&&(o(n),t())}(),jQuery(window).on("et_cloud_refresh_local_items",M),jQuery(window).on("et_cloud_page_changed",L),jQuery(window).on("et_cloud_item_action",P),jQuery(window).on("et_cloud_token_ready",F),jQuery(window).on("et_cloud_token_removed",B),function(){jQuery(window).off("et_cloud_refresh_local_items",M),jQuery(window).off("et_cloud_page_changed",L),jQuery(window).off("et_cloud_item_action",P),jQuery(window).off("et_cloud_token_ready",F),jQuery(window).off("et_cloud_token_removed",B)}}),[]),Object(s.useEffect)((function(){return jQuery(window).on("et_cloud_app_ready",z),function(){jQuery(window).off("et_cloud_app_ready",z)}}),[T]),Object(s.useEffect)((function(){window.CodeSnippetItemsLoaded[e.context]&&window.ETCloudApp.toggleTab({items:e.items,tab:"modules_library",forceUpdateLocal:!0}),e.snippetCode&&""!==e.snippetCode&&e.insertCodeCallback&&(e.insertCodeCallback(e.snippetCode,e.snippetCodeAppend),e.resetSnippetCode())}),[e.items,e.context,e.snippetCode]);var W=e.closePortability,q=e.container,Y=e.context,G=e.exportSnippet,$=e.getExportedItem,K=e.importError,Z=e.importSnippet,X=e.importState,Q=e.modalType,J=e.openPortablity,ee=e.showLibraryModal,te=e.showPortability,ne=e.sidebarLabel,re=e.toggleLibraryItemLocation,oe=e.updateItem,ie=e.updateLocalFilters,ae=eu("library","code_html"===Y?"HTML/JS Snippet":"CSS Snippet"),se={cloudTab:"modules_library",context:Y,downloadItemInDetailsPage:!0,editorLabel:eu("library","Edit Snippet"),initialTab:"modules_library",showCodeSnippetPreview:!0,showHelpButton:!1,showLiveDemoBtn:!1,showLoadOptions:!0,shortLabel:eu("library","Code Snippet"),itemsLabel:ae,sidebarLabel:ne},ue="on"===et_cloud_data&&et_cloud_data.initialCloudStatus;return Object(h.get)(k,"error",""),u.a.createElement(s.Fragment,null,ee&&u.a.createElement("div",{className:"et-code-snippets-library__container"},u.a.createElement(va,{cloudPreferences:se,onClose:j,onUpdateItem:oe,onUseItem:function(t){var n=t.item,o=t.replace_content,i=!1,a=!1;if(Object(h.isString)(n)){var s=JSON.parse(n);i=Object(h.get)(s,"data","")}else a=n;e.insertSnippet({codeMirrorId:r,snippetId:a,snippetContent:i,isAppend:"off"===o,skipInsert:!Object(h.isUndefined)(e.insertCodeCallback)}).then(j)},onDownloadItem:function(t){var n=t.item,r=!1,o=!1;if(Object(h.isString)(n)){var i=JSON.parse(n);r=Object(h.get)(i,"data",""),e.downloadSnippetContent({snippetContent:r})}else o=n,e.downloadSnippetContent({snippetId:o})},getExportLocalItem:$,toggleLibraryItemLocation:re,updateLocalFilters:ie,title:eu("library","Code Snippets Library"),container:q,showBackBtn:l,detailsPageTitle:p,onBackBtnClick:function(){c(!1)},showPortability:te,portabilityHeading:eu("library","Snippet"),portabilityTitle:eu("library","Snippet"),importState:X,importError:K?eu("library","importContextFail"):"",onPortabilityExport:G,onPortabilityImport:Z,onOpenPortablity:J,onClosePortability:W,itemsLoaded:Object(h.get)(window.CodeSnippetItemsLoaded,Y,!1),portabilityAllowed:!!lu("portability")&&lu("et_code_snippets_portability"),isCloudActive:ue})),function(){var t=e.content,n=e.context,r=e.selectedContent,o=e.showSaveModal,i=e.setCloudToken;if(o)return"headless"===Q?u.a.createElement(fs,{onClose:D,context:n,content:t,selectedContent:r,setCloudToken:function(e){return i({cloudToken:e})},modalType:Q,cloudToggle:"on",onSaveBtnClick:R,closeSaveItemsModal:U}):u.a.createElement(fs,{onClose:D,context:n,content:t,selectedContent:r,setCloudToken:function(e){return i({cloudToken:e})},onSave:I})}(),!ee&&function(){var t=e.showPortability,n=e.codeMirrorId,r=e.insertCodeCallback;if(t)return u.a.createElement(Wu,{codeMirrorId:n,insertCodeCallback:r,isCloudAvailable:!1,onClose:N})}(),function(){if(e.isEditItemModalOpen)return u.a.createElement(su,null)}())}));function Yu(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_o()(e);if(t){var o=_o()(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return bo()(this,n)}}var Gu=function(e){mo()(n,e);var t=Yu(n);function n(){var e,r;co()(this,n);for(var o=arguments.length,i=new Array(o),a=0;a<o;a++)i[a]=arguments[a];return bo()(r,(e=r=t.call.apply(t,[this].concat(i)),Object.defineProperty(vo()(r),"state",{configurable:!0,enumerable:!0,writable:!0,value:{i18n:window.et_code_snippets_data.i18n}}),e))}return po()(n,[{key:"render",value:function(){var e=this.props,t=e.codeMirrorId,n=e.container,r=e.modalType,o=e.insertCodeCallback,i=this.state.i18n;return u.a.createElement(qu,{i18n:i,modalType:r,codeMirrorId:t,insertCodeCallback:o,container:n})}}]),n}(u.a.Component),$u={content:"",context:"code_css",importError:!1,items:[],showLibrary:!1,showPortability:!1,importState:"idle"};f()(window).on("et_code_snippets_container_ready",(function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:document,r=null,o=t.context,i=Object(h.assign)(Object(h.clone)($u),{}),a=t.modalType;""!==o&&Object(h.set)(i,"context",o);var s=Object(h.get)(t,"content","");""!==s&&Object(h.set)(i,"content",s);var c=Object(h.get)(t,"selectedContent","");Object(h.set)(i,"selectedContent",c);var v=Object(h.get)(t,"sidebarLabel","");Object(h.set)(i,"sidebarLabel",v);var g=Object(d.default)(uo(i),{devtools:r,returnSequencePromise:!0}),m=t.containerId,y=n.getElementById(m);""!==a?(Object(l.render)(u.a.createElement(p.Container,{app:g},u.a.createElement(Gu,{modalType:a,codeMirrorId:t.codeMirrorId,insertCodeCallback:t.insertCodeCallback,container:n})),y),f()(n).find("body.et-admin-page").addClass("et-code-snippets-open"),f()(window).on("et_code_snippets_library_close",(function(){var e=n.getElementById(m);setTimeout((function(){e&&(Object(l.unmountComponentAtNode)(e),e.remove()),f()("body.et-admin-page").removeClass("et-code-snippets-open")}))}))):Object(l.unmountComponentAtNode)(y)}))},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)}function o(e){var t=function(e,t){if("object"!=r(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var o=n.call(e,t||"default");if("object"!=r(o))return o;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==r(t)?t:t+""}function i(e,t,n){return(t=o(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(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 s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){i(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function u(e){return"Minified Redux error #"+e+"; visit https://redux.js.org/Errors?code="+e+" for the full message or use the non-minified dev environment for full errors. "}n.r(t),n.d(t,"__DO_NOT_USE__ActionTypes",(function(){return f})),n.d(t,"applyMiddleware",(function(){return b})),n.d(t,"bindActionCreators",(function(){return m})),n.d(t,"combineReducers",(function(){return v})),n.d(t,"compose",(function(){return y})),n.d(t,"createStore",(function(){return p})),n.d(t,"legacy_createStore",(function(){return h}));var l="function"==typeof Symbol&&Symbol.observable||"@@observable",c=function(){return Math.random().toString(36).substring(7).split("").join(".")},f={INIT:"@@redux/INIT"+c(),REPLACE:"@@redux/REPLACE"+c(),PROBE_UNKNOWN_ACTION:function(){return"@@redux/PROBE_UNKNOWN_ACTION"+c()}};function d(e){if("object"!=typeof e||null===e)return!1;for(var t=e;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t}function p(e,t,n){var r;if("function"==typeof t&&"function"==typeof n||"function"==typeof n&&"function"==typeof arguments[3])throw new Error(u(0));if("function"==typeof t&&void 0===n&&(n=t,t=void 0),void 0!==n){if("function"!=typeof n)throw new Error(u(1));return n(p)(e,t)}if("function"!=typeof e)throw new Error(u(2));var o=e,i=t,a=[],s=a,c=!1;function h(){s===a&&(s=a.slice())}function v(){if(c)throw new Error(u(3));return i}function g(e){if("function"!=typeof e)throw new Error(u(4));if(c)throw new Error(u(5));var t=!0;return h(),s.push(e),function(){if(t){if(c)throw new Error(u(6));t=!1,h();var n=s.indexOf(e);s.splice(n,1),a=null}}}function m(e){if(!d(e))throw new Error(u(7));if(void 0===e.type)throw new Error(u(8));if(c)throw new Error(u(9));try{c=!0,i=o(i,e)}finally{c=!1}for(var t=a=s,n=0;n<t.length;n++){(0,t[n])()}return e}function y(e){if("function"!=typeof e)throw new Error(u(10));o=e,m({type:f.REPLACE})}function b(){var e,t=g;return(e={subscribe:function(e){if("object"!=typeof e||null===e)throw new Error(u(11));function n(){e.next&&e.next(v())}return n(),{unsubscribe:t(n)}}})[l]=function(){return this},e}return m({type:f.INIT}),(r={dispatch:m,subscribe:g,getState:v,replaceReducer:y})[l]=b,r}var h=p;function v(e){for(var t=Object.keys(e),n={},r=0;r<t.length;r++){var o=t[r];0,"function"==typeof e[o]&&(n[o]=e[o])}var i,a=Object.keys(n);try{!function(e){Object.keys(e).forEach((function(t){var n=e[t];if(void 0===n(void 0,{type:f.INIT}))throw new Error(u(12));if(void 0===n(void 0,{type:f.PROBE_UNKNOWN_ACTION()}))throw new Error(u(13))}))}(n)}catch(e){i=e}return function(e,t){if(void 0===e&&(e={}),i)throw i;for(var r=!1,o={},s=0;s<a.length;s++){var l=a[s],c=n[l],f=e[l],d=c(f,t);if(void 0===d){t&&t.type;throw new Error(u(14))}o[l]=d,r=r||d!==f}return(r=r||a.length!==Object.keys(e).length)?o:e}}function g(e,t){return function(){return t(e.apply(this,arguments))}}function m(e,t){if("function"==typeof e)return g(e,t);if("object"!=typeof e||null===e)throw new Error(u(16));var n={};for(var r in e){var o=e[r];"function"==typeof o&&(n[r]=g(o,t))}return n}function y(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return 0===t.length?function(e){return e}:1===t.length?t[0]:t.reduce((function(e,t){return function(){return e(t.apply(void 0,arguments))}}))}function b(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return function(e){return function(){var n=e.apply(void 0,arguments),r=function(){throw new Error(u(15))},o={getState:n.getState,dispatch:function(){return r.apply(void 0,arguments)}},i=t.map((function(e){return e(o)}));return r=y.apply(void 0,i)(n.dispatch),s(s({},n),{},{dispatch:r})}}}},function(e,t,n){"use strict";var r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto),o=new Uint8Array(16);function i(){if(!r)throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return r(o)}for(var a=[],s=0;s<256;++s)a[s]=(s+256).toString(16).substr(1);var u=function(e,t){var n=t||0,r=a;return[r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]]].join("")};t.a=function(e,t,n){var r=t&&n||0;"string"==typeof e&&(t="binary"===e?new Array(16):null,e=null);var o=(e=e||{}).random||(e.rng||i)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,t)for(var a=0;a<16;++a)t[r+a]=o[a];return t||u(o)}}]); build/et-core-app.bundle.css 0000644 00000275041 15222641012 0011745 0 ustar 00 /*! This minified app bundle contains open source software from several third party developers. Please review CREDITS.md in the root directory or LICENSE.md in the current directory for complete licensing, copyright and patent information. This file and the included code may not be redistributed without the attributions listed in LICENSE.md, including associate copyright notices and licensing information. */ @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.et-common-branded-modal__header{z-index:1000}.et-common-branded-modal{font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;line-height:16px;border-radius:3px;-webkit-box-shadow:0 5px 30px rgba(43,135,218,0.2);box-shadow:0 5px 30px rgba(43,135,218,0.2);background:#fff;border-radius:3px;box-shadow:0 5px 30px rgba(43,135,218,0.2)}@media (max-width: 812px){.et-common-branded-modal{border-radius:0}}.et-common-branded-modal--fullheight{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;height:100%}.et-common-branded-modal__header{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;background:#6C2EB9;height:58px;border-radius:3px 3px 0 0;padding:0 14px 0 26px;color:#fff;font-size:18px;font-weight:600;line-height:24px;text-transform:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.et-tb-branded-modal--visual-builder .et-common-branded-modal__header{font-size:16px}.rtl .et-common-branded-modal__header{padding:0 18px 0 18px}@media (max-width: 812px){.et-common-branded-modal__header{border-radius:0}}.et-common-branded-modal--fullheight .et-common-branded-modal__header{-webkit-box-flex:0;-ms-flex:0 0 auto;flex:0 0 auto}.et-common-branded-modal--visual-builder .et-common-branded-modal__header{height:32px}.et-common-branded-modal__title{max-width:80%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block}.et-common-branded-modal__header-buttons{display:-webkit-box;display:-ms-flexbox;display:flex} .et-common-button{-webkit-box-sizing:border-box;box-sizing:border-box;position:relative;padding:12px;border:0;border-radius:3px;margin:0;line-height:16px;font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;font-size:14px;font-weight:600;background:transparent;color:#fff;outline:none;cursor:pointer;-webkit-transition:background 200ms ease;transition:background 200ms ease;overflow:hidden}a.et-common-button{text-align:center;text-decoration:none;display:inline-block}a.et-common-button:hover,a.et-common-button:focus{color:#fff;border:none;outline:none;-webkit-box-shadow:none;box-shadow:none}.et-common-button--round{border-radius:100px}.et-common-button--round .et-fb-icon{display:block}.et-common-button--compact{padding:8px}.et-common-button--rectangle{border-radius:3px;background:#f1f4f9;color:#5c6978}.et-common-button--primary{background:#2B87DA;color:#fff}.et-common-button--danger{background:#EF5555;color:#fff}.et-common-button--success{background:#29C4A9;color:#fff}.et-common-button--secondary{background:#29C4A9;color:#fff}.et-common-button--cancel{background:#ED5759;color:#fff}.et-common-button--tertiary{background:#7D3BCF;color:#fff}.et-common-button--meta{padding:6px;color:#fff;background:#a3b0c2;-webkit-box-shadow:5px 5px 15px rgba(43,135,218,0.15);box-shadow:5px 5px 15px rgba(43,135,218,0.15);-webkit-transition:padding 0.25s ease-in-out, margin 0.25s ease-in-out, bottom 0.25s ease-in-out;transition:padding 0.25s ease-in-out, margin 0.25s ease-in-out, bottom 0.25s ease-in-out}.et-common-button--meta:hover{padding:12px;margin:-6px} .et-common-icon{display:inline-block;vertical-align:middle}.et-common-icon svg{display:block;width:100%;fill:inherit}.et-common-icon.et-common-icon--divi-ai-light svg .cls-1{fill:url(#divi-ai-light-linear-gradient)}.et-common-icon.et-common-icon--divi-ai-light svg .cls-2{fill:#fff} @-webkit-keyframes et-common-fade-in{0%{opacity:0}100%{opacity:1}}@keyframes et-common-fade-in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes et-common-slide-fade-in{0%{-webkit-transform:translate(-30px, 0);transform:translate(-30px, 0);opacity:0}100%{-webkit-transform:translate(0, 0);transform:translate(0, 0);opacity:1}}@keyframes et-common-slide-fade-in{0%{-webkit-transform:translate(-30px, 0);transform:translate(-30px, 0);opacity:0}100%{-webkit-transform:translate(0, 0);transform:translate(0, 0);opacity:1}}@-webkit-keyframes et-common-zoom-in{0%{-webkit-transform:scale(0.5, 0.5);transform:scale(0.5, 0.5)}100%{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@keyframes et-common-zoom-in{0%{-webkit-transform:scale(0.5, 0.5);transform:scale(0.5, 0.5)}100%{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@-webkit-keyframes et-common-bounce-in{from,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1);animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1)}0%{opacity:0;-webkit-transform:scale3d(0.3, 0.3, 0.3);transform:scale3d(0.3, 0.3, 0.3)}20%{-webkit-transform:scale3d(1.1, 1.1, 1.1);transform:scale3d(1.1, 1.1, 1.1)}40%{-webkit-transform:scale3d(0.9, 0.9, 0.9);transform:scale3d(0.9, 0.9, 0.9)}60%{opacity:1;-webkit-transform:scale3d(1.03, 1.03, 1.03);transform:scale3d(1.03, 1.03, 1.03)}80%{-webkit-transform:scale3d(0.97, 0.97, 0.97);transform:scale3d(0.97, 0.97, 0.97)}to{opacity:1;-webkit-transform:scale3d(1, 1, 1);transform:scale3d(1, 1, 1)}}@keyframes et-common-bounce-in{from,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1);animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1)}0%{opacity:0;-webkit-transform:scale3d(0.3, 0.3, 0.3);transform:scale3d(0.3, 0.3, 0.3)}20%{-webkit-transform:scale3d(1.1, 1.1, 1.1);transform:scale3d(1.1, 1.1, 1.1)}40%{-webkit-transform:scale3d(0.9, 0.9, 0.9);transform:scale3d(0.9, 0.9, 0.9)}60%{opacity:1;-webkit-transform:scale3d(1.03, 1.03, 1.03);transform:scale3d(1.03, 1.03, 1.03)}80%{-webkit-transform:scale3d(0.97, 0.97, 0.97);transform:scale3d(0.97, 0.97, 0.97)}to{opacity:1;-webkit-transform:scale3d(1, 1, 1);transform:scale3d(1, 1, 1)}}.et-common-progress-bar{width:350px;left:50%;top:53%;position:absolute;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.et-common-progress-bar__background{background:#F1F5F9}.et-common-progress-bar__bar{border-radius:3px;background-color:#32C4AA;background-image:linear-gradient(-45deg, rgba(255,255,255,0.3) 25%, transparent 25%, transparent 50%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0.3) 75%, transparent 75%, transparent);background-size:30px 30px;-webkit-animation:et-core-progress-bar-stripes 2s linear infinite;animation:et-core-progress-bar-stripes 2s linear infinite;width:0%;-webkit-transition:width 0.4s ease;transition:width 0.4s ease}.et-common-progress-bar__value{min-width:30px;font-weight:700;line-height:22px;text-align:center;color:#fff}.et-common-progress-bar__estimate{padding:10px 0;text-align:center;font-weight:600;color:#A6A9B2}.et-common-loader{background:transparent;-webkit-transition:background, -webkit-box-shadow 0.3s;transition:background, -webkit-box-shadow 0.3s;transition:background, box-shadow 0.3s;transition:background, box-shadow 0.3s, -webkit-box-shadow 0.3s;height:50px;width:50px;color:#fff;border-radius:50px;text-align:center;-webkit-box-shadow:rgba(0,139,219,0.25) 0 0 60px;box-shadow:rgba(0,139,219,0.25) 0 0 60px;display:block;margin:auto}.et-common-loader-success{opacity:0;-webkit-animation:et-common-bounce-in 1s;animation:et-common-bounce-in 1s;-webkit-animation-delay:0.3s;animation-delay:0.3s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards;background:#a9e900;-webkit-box-shadow:rgba(169,233,0,0.25) 0 0 60px;box-shadow:rgba(169,233,0,0.25) 0 0 60px}.et-common-loader-success:before{font-family:'ETmodules';content:'\4e';font-weight:600;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:30px;line-height:53px} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.et-common-app-spinner-block{position:relative;height:80px}.et-common-app-spinner-block--overlay{position:absolute;z-index:100;left:0;top:0;width:100%;height:100%;background:#fff}.et-common-app-spinner-block__spinner{position:absolute;background:none;width:80px;height:80px;left:calc(50% - 40px);top:calc(50% - 40px);right:auto;bottom:auto}.et-common-app-spinner-block__spinner:before{content:'';position:absolute;top:50%;left:50%;width:12px;height:12px;border-radius:12px;-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #7E3BD0,0 17px #7E3BD0,-17px 0 #7E3BD0;box-shadow:0 -17px #7E3BD0,17px 0 #7E3BD0,0 17px #7E3BD0,-17px 0 #7E3BD0;margin:-6px auto auto -6px;-webkit-animation:et-spinner ease infinite 3s;animation:et-spinner ease infinite 3s} .et-common-tabs-navigation{display:-webkit-box;display:-ms-flexbox;display:flex;background:#7E3BD0}.et-common-tabs-navigation__button{display:block;padding:13px 26px;border:0;font-size:14px !important;font-weight:600 !important;line-height:1 !important;color:#fff !important;background:#7E3BD0;outline:none;-webkit-transition:background 200ms ease,opacity 150ms ease,-webkit-transform 200ms ease;transition:background 200ms ease,opacity 150ms ease,-webkit-transform 200ms ease;transition:background 200ms ease,transform 200ms ease,opacity 150ms ease;transition:background 200ms ease,transform 200ms ease,opacity 150ms ease,-webkit-transform 200ms ease;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.et-common-tabs-navigation__button:hover{background:#7435C1}.et-common-tabs-navigation__button--active,.et-common-tabs-navigation__button--active:hover{background:#8E42EB}.et-common-tabs-navigation__button svg{fill:#fff} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}body.et-common-prompt-open *{pointer-events:none}body.et-common-prompt-open .et-common-prompt,body.et-common-prompt-open .et-common-prompt *{pointer-events:auto}body.et-common-prompt-open{overflow:hidden}.et-common-prompt{position:fixed;left:0;top:0;width:100vw;height:100vh}.et-common-prompt-draggable{width:calc(100vw - 15px)}.et-common-prompt{z-index:2000000}.et-common-prompt__overlay{position:fixed;left:0;top:0;width:100vw;height:100vh;background:radial-gradient(ellipse at center, #fff 20%, rgba(255,255,255,0) 80%);-webkit-animation:et-common-fade-in 200ms ease;animation:et-common-fade-in 200ms ease}.et-common-prompt__modal{position:fixed;left:0;top:0;width:100vw;height:100vh}.et-common-prompt-draggable .et-common-prompt__modal{width:calc(100vw - 15px)}body.admin-bar .et-common-prompt-draggable .et-common-prompt__modal{top:32px;height:calc(100vh - 32px)}.et-common-prompt__modal{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.et-common-prompt__container{width:400px;max-width:100%;-webkit-box-shadow:0 5px 30px rgba(43,135,218,0.2);box-shadow:0 5px 30px rgba(43,135,218,0.2)}@media (max-width: 812px){.et-common-prompt__container{width:100%}}.et-common-prompt__header{display:-webkit-box;display:-ms-flexbox;display:flex;position:relative;padding:9px 26px;border-radius:3px 3px 0 0;font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;font-weight:600;font-size:18px;line-height:40px;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;color:#fff;background-color:#6C2EB9;-webkit-box-shadow:0 5px 30px rgba(0,0,0,0.1);box-shadow:0 5px 30px rgba(0,0,0,0.1);-webkit-box-shadow:none;box-shadow:none;padding-right:9px}.rtl .et-common-prompt__header{padding-right:18px !important;padding-left:9px !important}.et-common-prompt__header-back{padding-left:9px}@media (max-width: 812px){.et-common-prompt__header{margin-top:0;border-radius:0}}.react-draggable .et-common-prompt__header{cursor:move}.et-common-prompt__header-actions{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:end;-ms-flex-pack:end;justify-content:flex-end;-webkit-box-align:center;-ms-flex-align:center;align-items:center;margin-left:auto}.rtl .et-common-prompt__header-actions{margin-left:0 !important;margin-right:auto}.et-common-prompt__header-actions .et-fb-icon svg{fill:#fff}.et-common-prompt__body{background:#fff}@media (max-width: 812px){.et-common-prompt__body{height:calc(100vh - 58px - 42px)}}.et-common-prompt__content{color:#4C5866;padding:30px}.et-common-prompt__content p{margin:0 0 13px 0;font-weight:600}.et-common-prompt__content ul{padding:0 0 0 25px;list-style-type:disc}.et-common-prompt__content>*:last-child{margin-bottom:0}.et-common-prompt__footer{display:-webkit-box;display:-ms-flexbox;display:flex;border-radius:0 0 3px 3px}.et-common-prompt__footer .et-common-button{-webkit-box-flex:1;-ms-flex:1 0 0px;flex:1 0 0;padding:10px;font-weight:700;line-height:20px;border-radius:0}.et-common-prompt__footer .et-common-button:first-child{border-bottom-left-radius:3px}.et-common-prompt__footer .et-common-button:last-child{border-bottom-right-radius:3px}.rtl .et-common-prompt__footer .et-common-button:first-child{border-bottom-left-radius:0;border-bottom-right-radius:3px}.rtl .et-common-prompt__footer .et-common-button:last-child{border-bottom-right-radius:0;border-bottom-left-radius:3px}.rtl .et-common-prompt__footer .et-common-button:first-child:last-child{border-bottom-left-radius:3px;border-bottom-right-radius:3px}@media (max-width: 812px){.et-common-prompt__footer{border-radius:0}.et-common-prompt__footer .et-common-button{border-radius:0 !important}} body.et-common-scroll-lock{overflow:hidden} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}[type].et-common-input-text{display:inline-block;background:#F1F5F9;max-height:30px;border:0;border-radius:3px;padding:7px 10px;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-transition:background 200ms ease;transition:background 200ms ease;color:#4C5866;font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;font-size:13px;font-weight:600;text-transform:none;line-height:normal;-webkit-box-shadow:none;box-shadow:none;letter-spacing:normal}[type].et-common-input-text:focus{-webkit-box-shadow:none;box-shadow:none;background:#E6ECF2;text-transform:none;letter-spacing:normal}[type].et-common-input-text::-webkit-input-placeholder{color:#98a7b8;text-transform:none;letter-spacing:normal}[type].et-common-input-text:-moz-placeholder{color:#98a7b8;text-transform:none;letter-spacing:normal}[type].et-common-input-text::-moz-placeholder{color:#98a7b8;text-transform:none;letter-spacing:normal}[type].et-common-input-text:-ms-input-placeholder{color:#98a7b8;text-transform:none;letter-spacing:normal}[type].et-common-input-text--block{display:block;width:100%}[type].et-common-input-text[readonly]{background:#ffffff !important;border:1px solid #EAEDF0 !important;cursor:not-allowed} @-webkit-keyframes et-common-fade-in{0%{opacity:0}100%{opacity:1}}@keyframes et-common-fade-in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes et-common-slide-fade-in{0%{-webkit-transform:translate(-30px, 0);transform:translate(-30px, 0);opacity:0}100%{-webkit-transform:translate(0, 0);transform:translate(0, 0);opacity:1}}@keyframes et-common-slide-fade-in{0%{-webkit-transform:translate(-30px, 0);transform:translate(-30px, 0);opacity:0}100%{-webkit-transform:translate(0, 0);transform:translate(0, 0);opacity:1}}@-webkit-keyframes et-common-zoom-in{0%{-webkit-transform:scale(0.5, 0.5);transform:scale(0.5, 0.5)}100%{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@keyframes et-common-zoom-in{0%{-webkit-transform:scale(0.5, 0.5);transform:scale(0.5, 0.5)}100%{-webkit-transform:scale(1, 1);transform:scale(1, 1)}}@-webkit-keyframes et-common-bounce-in{from,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1);animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1)}0%{opacity:0;-webkit-transform:scale3d(0.3, 0.3, 0.3);transform:scale3d(0.3, 0.3, 0.3)}20%{-webkit-transform:scale3d(1.1, 1.1, 1.1);transform:scale3d(1.1, 1.1, 1.1)}40%{-webkit-transform:scale3d(0.9, 0.9, 0.9);transform:scale3d(0.9, 0.9, 0.9)}60%{opacity:1;-webkit-transform:scale3d(1.03, 1.03, 1.03);transform:scale3d(1.03, 1.03, 1.03)}80%{-webkit-transform:scale3d(0.97, 0.97, 0.97);transform:scale3d(0.97, 0.97, 0.97)}to{opacity:1;-webkit-transform:scale3d(1, 1, 1);transform:scale3d(1, 1, 1)}}@keyframes et-common-bounce-in{from,20%,40%,60%,80%,to{-webkit-animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1);animation-timing-function:cubic-bezier(0.215, 0.61, 0.355, 1)}0%{opacity:0;-webkit-transform:scale3d(0.3, 0.3, 0.3);transform:scale3d(0.3, 0.3, 0.3)}20%{-webkit-transform:scale3d(1.1, 1.1, 1.1);transform:scale3d(1.1, 1.1, 1.1)}40%{-webkit-transform:scale3d(0.9, 0.9, 0.9);transform:scale3d(0.9, 0.9, 0.9)}60%{opacity:1;-webkit-transform:scale3d(1.03, 1.03, 1.03);transform:scale3d(1.03, 1.03, 1.03)}80%{-webkit-transform:scale3d(0.97, 0.97, 0.97);transform:scale3d(0.97, 0.97, 0.97)}to{opacity:1;-webkit-transform:scale3d(1, 1, 1);transform:scale3d(1, 1, 1)}}.et-common-checkbox{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:start;-ms-flex-align:start;align-items:flex-start;padding:3px;font-size:13px;font-weight:600;color:#4C5866;line-height:normal}.et-common-checkbox__input[type="checkbox"]{-webkit-box-flex:0;-ms-flex:0 0 24px;flex:0 0 24px;width:24px;height:24px;padding:0;margin:0 8px 0 0;border:0;border-radius:3px;background:#f1f4f9;-webkit-box-shadow:none;box-shadow:none;-webkit-appearance:none}.rtl .et-common-checkbox__input[type="checkbox"]{margin:0 0 0 8px}.et-common-checkbox__input[type="checkbox"]:focus{outline:none;-webkit-box-shadow:none;box-shadow:none}.et-common-checkbox__input[type="checkbox"]:disabled,.et-common-checkbox__input[type="checkbox"]:disabled:checked:before{opacity:1}.et-common-checkbox__input[type="checkbox"]:checked{position:relative}.et-common-checkbox__input[type="checkbox"]:checked:before{content:"\f147";display:inline-block;position:absolute;margin:0 0 0 -1px;top:50%;left:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%);color:#00c3aa;font:400 24px/1 dashicons;height:auto;width:auto}.rtl .et-common-checkbox__input[type="checkbox"]:checked:before{margin:0 !important}.et-common-checkbox__input--danger[type="checkbox"]:checked:before{color:#EF5555}.et-common-checkbox__label{-webkit-box-flex:1;-ms-flex:1 1 0px;flex:1 1 0;line-height:24px;-webkit-transition:color 200ms ease;transition:color 200ms ease}.et-common-checkbox__label .et-fb-icon{-webkit-box-flex:0;-ms-flex:0 0 auto;flex:0 0 auto;position:relative;top:4px}.et-common-checkbox__label .et-fb-icon svg{fill:#a3b0c2;-webkit-transition:fill 200ms ease;transition:fill 200ms ease}.et-common-checkbox-group{padding-bottom:16px}.et-common-checkbox-group+.et-common-checkbox-group{padding-top:16px;border-top:2px solid #e7eef5}.et-common-checkbox-group:last-child{padding-bottom:0}.et-common-checkbox-group__label{display:block;margin-bottom:7px;font-size:13px;font-weight:600;color:#a3b0c2;cursor:auto}.et-common-checkbox-group__list{padding:0;margin:0;list-style-type:none}.et-common-checkbox-group__list li{padding:0;margin:0} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.et-common-library-portability-modal{-webkit-font-smoothing:antialiased}.et-common-library-portability-modal__spinner-overlay{-webkit-box-align:center;-ms-flex-align:center;align-items:center;background:#fff;display:-webkit-box;display:-ms-flexbox;display:flex;height:calc(100% - 60px);-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;position:absolute;top:60px;width:100%;z-index:99}.et-common-library-portability-modal .et-common-prompt__header .et-common-button{background:transparent !important}.et-common-library-portability-modal .et-common-button--primary{background:#2B87DA !important;color:#fff !important}.et-common-library-portability-modal .et-common-prompt__overlay,.et-common-library-portability-modal .et-common-prompt__modal{height:100%;width:100%}.et-common-library-portability-modal .et-common-prompt__container{position:relative}.et-common-library-portability-modal .et-common-prompt .et-common-export-file-container h3,.et-common-library-portability-modal .et-common-prompt .et-common-import-file-container h3{color:#32373c;font-size:14px;font-weight:600;font-family:inherit;margin:0;padding-bottom:10px}.et-common-library-portability-modal .et-common-prompt .et-common-export-file-container p,.et-common-library-portability-modal .et-common-prompt .et-common-import-file-container p{font-size:13px;padding:0}.et-common-library-portability-modal .et-common-prompt .et-common-export-file-container .et-common-input-text,.et-common-library-portability-modal .et-common-prompt .et-common-import-file-container .et-common-input-text{width:100%}.et-common-library-portability-modal .et-common-prompt button{font-weight:600}.et-common-library-portability-modal .et-common-import-file-container{position:relative}.et-common-library-portability-modal .et-common-import-file-container .et-common-import-file-name-field{height:54px;margin-bottom:20px}.et-common-library-portability-modal .et-common-import-file-container .et-common-import-file{cursor:pointer;height:30px;left:0;opacity:0;position:absolute;width:100%}.et-common-library-portability-modal .et-common-import-file-container .et-common-portability-import-placeholder{border:2px dashed #e6ecf2;border-radius:3px;color:#a3b0c2;float:left;font-size:12px;font-weight:700;height:16px;line-height:16px;overflow:hidden;padding:5px;text-align:center;text-overflow:ellipsis;text-transform:uppercase;white-space:nowrap;width:326px}.et-common-library-portability-modal .et-common-import-file-container .et-common-portability-import-placeholder--active{border-color:#2B87DA;border-style:solid;color:#2B87DA}.et-common-library-portability-modal .et-common-import-file-container .et-common-checkbox{padding:0}.et-common-library-portability-modal .et-common-import-file-container .et-common-checkbox__input::before{margin:0 !important}.toplevel_page_et_divi_options .et-common-library-portability-modal .et-common-import-file-container .et-common-checkbox__label{line-height:16px}.et-common-library-portability-modal .et-common-import-file-container .et-common-import-error-container p{margin:0 0 13px 0;color:red;font-weight:600}.et-common-library-portability-modal .et-common-button-disabled{pointer-events:none}body.et-fb .et-common-library-portability-modal .et-common-portability-import-placeholder{height:30px} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.et-common-library-overlay{position:fixed;left:0;top:0;width:100vw;height:100vh;background:radial-gradient(ellipse at center, #fff 20%, rgba(255,255,255,0.7) 100%);z-index:159900;-webkit-animation:et-core-fade-in 500ms linear;animation:et-core-fade-in 500ms linear}.et-common-library-modal-positioner{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;position:fixed;left:30px;top:32px;right:30px;bottom:30px;z-index:159900;-webkit-font-smoothing:antialiased}.et-common-library-modal{font-size:13px;-webkit-box-flex:1;-ms-flex:1 1 0px;flex:1 1 0}@media (min-width: 813px){.et-common-library-modal{position:relative;left:0 !important;right:0 !important;top:0 !important;bottom:0 !important}.et-common-library-modal #et-cloud-app .et-cloud-app-layout-screenshot{height:100%;max-height:100%}}.et-common-library-modal .et-common-branded-modal__header .et-common-button{background-color:transparent !important}.et-common-library-modal .et-common-branded-modal__header .et-common-button:focus{outline:none}.et-common-library-modal #et-cloud-app.et-common-library-cloud .et-cloud-app-content-wrapper{top:58px}.et-common-library-modal #et-cloud-app.et-common-library-cloud .et-cloud-app-content-wrapper .et-cloud-app-layout{height:calc(100% - 58px);overflow-y:auto}.et-common-library-modal #et-cloud-app.et-common-library-cloud .et-cloud-app-content-wrapper .et-cloud-app-view-header,.et-common-library-modal #et-cloud-app.et-common-library-cloud .et-cloud-app-content-wrapper .et-cloud-filter{font-weight:600}.et-common-library-modal #et-cloud-app.et-common-library-cloud .et-cloud-app-content-wrapper .et-cloud-filter-editor-add-new{line-height:1.7em}.et-common-library-modal #et-cloud-app.et-common-library-cloud .et-cloud-app-content-wrapper .et-cloud-editor-control h6{padding-bottom:10px}.et-common-button.et-code-snippets-library__back-button{margin-left:-40px;opacity:0;pointer-events:none;-webkit-transition:opacity 200ms ease,margin-left 500ms cubic-bezier(0.175, 0.885, 0.35, 1.42);transition:opacity 200ms ease,margin-left 500ms cubic-bezier(0.175, 0.885, 0.35, 1.42)}.et-common-button.et-code-snippets-library__back-button--visible{pointer-events:auto;margin-left:-12px;opacity:1}.et-common-button.et-code-snippets-library__back-button--visible .et-common-icon{margin-top:-11px !important}.rtl .et-common-button.et-code-snippets-library__back-button--visible{margin-left:0} .et-common-toggle{display:table;background:#f1f5f9;border-radius:3px;padding:5px;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-transition:background-color 200ms ease,color 200ms ease;transition:background-color 200ms ease,color 200ms ease;color:#A4AFC0;cursor:pointer}.et-common-toggle[disabled],.et-common-toggle[disabled] *{cursor:not-allowed}.et-common-toggle__label{color:inherit;font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;font-size:12px;font-weight:700;text-align:center;text-transform:uppercase;display:table-cell;vertical-align:middle;min-width:30px;height:20px;position:relative}.et-common-toggle__label--on{padding-right:2.5px}.et-common-toggle__label--off{padding-left:2.5px}.et-common-toggle__text{-webkit-transform:translateY(2px);transform:translateY(2px);margin-top:-3px;line-height:1.6em}.et-common-toggle__handle{position:relative;background:#fff;width:100%;height:20px;border-radius:3px;-webkit-box-shadow:0 1px 3px rgba(0,0,0,0.1);box-shadow:0 1px 3px rgba(0,0,0,0.1);-webkit-transition:all 200ms ease;transition:all 200ms ease;position:absolute;top:0;right:0}.et-common-toggle--on{background:#2B87DA;color:#fff}.et-common-toggle--on>.et-common-toggle__label--on>.et-common-toggle__handle{opacity:0;-webkit-transform:translateX(90%);transform:translateX(90%);-webkit-box-shadow:none;box-shadow:none}.et-common-toggle--on>.et-common-toggle__label--off{color:transparent}.et-common-toggle--off>.et-common-toggle__label--off>.et-common-toggle__handle{opacity:0;-webkit-transform:translateX(-90%);transform:translateX(-90%);-webkit-box-shadow:none;box-shadow:none}.et-common-toggle--off>.et-common-toggle__label--on{color:transparent}.et-common-toggle__cursor_default{cursor:default} .et-common-categories>label{font-size:14px;font-weight:600;line-height:20px;margin-bottom:10px;color:#32373C;display:block;max-width:100%}@media (max-width: 749px){.et-common-checkboxes-category-wrap{-webkit-columns:2;-moz-columns:2;columns:2}}.et-common-checkboxes-category-wrap p{padding-bottom:0;margin-top:0 !important;margin-bottom:6px !important;padding-left:34px}.et-common-checkboxes-category-wrap p label{font-size:13px;font-weight:600;position:relative;color:#4C5866;line-height:27.2px;cursor:pointer;text-transform:capitalize}.rtl .et-common-checkboxes-category-wrap p label{padding-right:40px}.et-common-checkboxes-category-wrap p.et-tb-prompt-input-error input[type="checkbox"],.et-common-checkboxes-category-wrap p.et-tb-prompt-input-error input[type="checkbox"]:focus{color:#FF9232;-webkit-box-shadow:inset 0px 0px 0px 2px #FF9232;box-shadow:inset 0px 0px 0px 2px #FF9232;background:rgba(255,146,50,0.1)}.et-common-checkboxes-category-wrap input{margin-bottom:10px;display:block;margin-bottom:10px;display:block;-webkit-appearance:none;-webkit-font-smoothing:subpixel-antialiased;-moz-osx-font-smoothing:grayscale;outline:0;position:absolute;top:-3px;left:-34px;display:inline-block;background:#f1f5f9;width:25px;min-width:16px;height:25px;border:0;border-radius:3px;-webkit-box-shadow:none;box-shadow:none;margin:0;padding:0 !important;float:none;clear:none;color:#4C5866;font-size:13px;font-weight:600;line-height:0;text-align:center;vertical-align:middle;cursor:pointer;margin-top:0 !important}.et-common-checkboxes-category-wrap input:checked:before{content:'\F147';display:inline-block;width:16px;margin:2px 0 0 -5px;float:none;color:#29C4A9;font:normal 21px/1 dashicons;vertical-align:middle;speak:none;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.et-common-checkboxes-category-wrap input:checked:after{display:none}.rtl .et-common-checkboxes-category-wrap input{right:0;position:absolute;left:auto}@media (max-width: 749px){.et-cloud-app-status-on .et-common-checkboxes-category-wrap{-webkit-columns:1;-moz-columns:1;columns:1}} .ReactTags__tags{position:relative;z-index:9}.ReactTags__tagInput{background:none;border:none;border-radius:3px;display:inline-block;max-width:100%;min-width:48px;width:1px;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;line-height:24px}.ReactTags__tagInput .ReactTags__tagInputField,.ReactTags__tagInput .ReactTags__tagInputField:focus{min-height:24px;height:24px;margin:0;font-size:13px;font-weight:600;color:#4C5866;width:100%;padding:3px;background:none;border:none}.ReactTags__selected{display:-webkit-box;display:-ms-flexbox;display:flex;border-radius:3px;background:#f1f5f9;-ms-flex-wrap:wrap;flex-wrap:wrap;padding:3px}.ReactTags__selected .ReactTags__tag{border-radius:3px;background:#e0e5ea;display:-webkit-box;display:-ms-flexbox;display:flex;padding:3px 6px 3px 8px;margin:0;color:#7b8490;line-height:18px;margin:2px 4px 2px 0;text-transform:capitalize;font-weight:600}.ReactTags__selected .ReactTags__remove{margin-left:6px !important;cursor:pointer;font-size:18px;color:#7b8490;border:none !important;height:18px !important;width:10px;line-height:19px;font-weight:900;display:inline-block;position:relative;background:none}.ReactTags__suggestions{position:absolute;left:0;width:100%}.ReactTags__suggestions ul{list-style-type:none;background:#fff;width:100%;position:relative;display:block;padding:3px !important;margin:0;margin-top:3px;-webkit-box-shadow:0 5px 30px rgba(43,135,218,0.2);box-shadow:0 5px 30px rgba(43,135,218,0.2);border-bottom-left-radius:3px;border-bottom-right-radius:3px}.ReactTags__suggestions ul li{display:inline-block;margin-bottom:0}.ReactTags__suggestions ul li.ReactTags__activeSuggestion{cursor:pointer}.ReactTags__suggestions ul li mark{background:none;font-weight:600}.ReactTags__suggestions ul li .et-common-tag-suggestion{display:inline-block;border-radius:3px;background:#e0e5ea;padding:3px 6px 3px 8px;margin:2px 4px 2px 0;color:#7b8490;line-height:18px;font-weight:600} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.et-fb-icon{display:inline-block;vertical-align:middle;-webkit-transition:fill 200ms ease;transition:fill 200ms ease}.et-fb-icon svg{display:block;width:100%;fill:inherit}.et-fb-icon svg path.opacity-half{opacity:0.5}.et-fb-icon--loading svg{-webkit-transform-origin:center;transform-origin:center;-webkit-animation:icon-loading-rotate 1s infinite linear;animation:icon-loading-rotate 1s infinite linear;fill:rgba(255,255,255,0.8)}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child{top:50%;left:50%;-webkit-transform:translate(-50%, -50%);transform:translate(-50%, -50%)}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child:before,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child:after{position:absolute;display:block;background:#fff;width:6px;height:6px;border-radius:10px}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child:before,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child:after{content:''}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child:before{left:-11px;-webkit-transform:translateX(-50%);transform:translateX(-50%)}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child:after{right:-11px;-webkit-transform:translateX(50%);transform:translateX(50%)}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--animate>.et-fb-icon__child{-webkit-transition:background 0.3s ease;transition:background 0.3s ease}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--animate:before,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--animate:after{-webkit-transition:right 100ms ease,left 100ms ease;transition:right 100ms ease,left 100ms ease}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--animate.et-fb-icon__child--active{-webkit-transition:background 200ms ease;transition:background 200ms ease}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--animate.et-fb-icon__child--active:before,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--animate.et-fb-icon__child--active:after{-webkit-transition:width 100ms 100ms ease,-webkit-transform 100ms 200ms cubic-bezier(0.28, 0.55, 0.385, 1.65);transition:width 100ms 100ms ease,-webkit-transform 100ms 200ms cubic-bezier(0.28, 0.55, 0.385, 1.65);transition:width 100ms 100ms ease,transform 100ms 200ms cubic-bezier(0.28, 0.55, 0.385, 1.65);transition:width 100ms 100ms ease,transform 100ms 200ms cubic-bezier(0.28, 0.55, 0.385, 1.65),-webkit-transform 100ms 200ms cubic-bezier(0.28, 0.55, 0.385, 1.65)}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active{background:transparent;-webkit-transition:background 200ms ease;transition:background 200ms ease}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active:before,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active:after{height:3px}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active:before,.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active:after{width:20px;-webkit-transform-origin:50% 50%;transform-origin:50% 50%}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active:before{left:50%;-webkit-transform:translateX(-50%) rotate(45deg);transform:translateX(-50%) rotate(45deg)}.et-fb-icon--page-settings-main-buttons>.et-fb-icon__child--active:after{right:50%;-webkit-transform:translateX(50%) rotate(-45deg);transform:translateX(50%) rotate(-45deg)}@-webkit-keyframes icon-loading-rotate{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes icon-loading-rotate{100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}} .et-common-library-cloud .et-cloud-app__upsell{margin-top:40px}.et-cloud-app__upsell{border-radius:7px;background-color:#f1f5f9;margin-top:20px;padding:20px;text-align:center;-webkit-animation:2s fadeIn;animation:2s fadeIn;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards;visibility:hidden}.et-cloud-app__upsell.card-default a{background-color:#2B87DA}.et-cloud-app__upsell.card-free a{background-color:#29C4A9}.et-cloud-app__upsell.card-paid a{background-color:#FF9232}.et-cloud-app__upsell.card-save-modal{border-radius:3px;padding:2px 12px 16px;text-align:left;margin:0 auto 10px;-webkit-animation-duration:5ms;animation-duration:5ms}.et-cloud-app__upsell.card-save-modal a{display:inline;font-weight:700}.et-cloud-app__upsell.card-default.card-save-modal{background-color:rgba(43,135,218,0.1)}.et-cloud-app__upsell.card-free.card-save-modal{background-color:rgba(43,196,169,0.1)}.et-cloud-app__upsell.card-save-modal .et-cloud-app__upsell-description{margin:0 !important;padding-bottom:15px !important}.et-cloud-app__upsell.card-default.card-save-modal .et-cloud-app__upsell-description{color:#2B87DA !important}.et-cloud-app__upsell.card-free.card-save-modal .et-cloud-app__upsell-description{color:#29C4A9 !important}.et-cloud-app__upsell-title{color:#4C5866;font-size:17px;font-weight:700;line-height:24px;margin:0;padding:0;text-transform:capitalize}.et-cloud-app__upsell-description{color:#4C5866 !important;font-size:13px;line-height:18px;margin:0;padding:10px 0 20px !important}.et-cloud-app__upsell a{color:#fff !important;border-radius:3px;display:block;padding:5px 12px;font-size:14px;font-weight:600;line-height:23px;margin:0 auto;text-decoration:none}.et-cloud-app__upsell a:hover{color:#fff}@-webkit-keyframes fadeIn{99%{visibility:hidden}100%{visibility:visible}}@keyframes fadeIn{99%{visibility:hidden}100%{visibility:visible}} .et-core-control-select{background:#f1f5f9;width:100%;border:0;border-radius:3px;-webkit-box-shadow:none;box-shadow:none;margin:0;padding:5px 10px;color:#4C5866;font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;font-size:13px;font-weight:600;height:30px;display:inline-block}body.gecko .et-core-control-select{-moz-appearance:none;z-index:10;background:#f1f5f9 !important;position:relative;border-radius:3px !important}body.gecko .et-core-control-select:after{font-family:'ETmodules' !important;speak:none;font-style:normal;font-weight:normal;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;content:'C';position:absolute;right:7px;top:8px;cursor:default;z-index:5}.et-core-control-select:-moz-focusring{text-shadow:0 0 0 #000;color:transparent}.et-core-control-select[disabled]{cursor:not-allowed} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.et-save-to-library-modal{font-family:"Open Sans",Helvetica,Roboto,Arial,sans-serif;font-weight:600;-webkit-font-smoothing:antialiased;font-size:13px}.et-save-to-library-modal .et-save-to-library-description{font-size:13px}.et-save-to-library-modal .et-common-prompt .et-common-prompt__modal .et-common-prompt__container .et-common-button{background:transparent}.et-save-to-library-modal .et-common-prompt .et-common-prompt__modal .et-common-prompt__container .et-common-button--primary{background:#2B87DA;color:#fff}.et-save-to-library-modal .et-common-prompt .et-common-prompt__modal .et-common-prompt__container .et-common-button--cancel{background:#ED5759;color:#fff}.et-save-to-library-modal .et-save-to-library-option input{color:#4C5866}.et-save-to-library-modal .et-save-to-library-option input:focus{outline:none;-webkit-box-shadow:none;box-shadow:none}.et-save-to-library-modal .et-save-to-library-option input[type=checkbox]:checked:after{display:none}.et-save-to-library-modal .et-save-to-library-option--select-cloud-folders{font-size:13px;background-color:#F1F5F9}.et-save-to-library-modal .et-save-to-library-option--select-cloud-folders,.et-save-to-library-modal .et-save-to-library-option--select-cloud-folders:focus,.et-save-to-library-modal .et-save-to-library-option--select-cloud-folders:hover{color:#4C5866}.et-save-to-library-modal .et-save-to-library-option--select-cloud-folders:focus{-webkit-box-shadow:none;box-shadow:none}.et-save-to-library-modal .et-save-to-library-option{padding:10px 0}.et-save-to-library-modal .et-save-to-library-option--hidden{display:none}.et-save-to-library-modal .et-save-to-library-option--label{color:#32373C;font-size:14px;font-weight:600;margin-bottom:5px;display:block}.et-save-to-library-modal .et-save-to-library-option--input{width:100%}.et-save-to-library-modal .et-common-input-text.et-save-to-library-option--input-error{-webkit-box-shadow:inset 0px 0px 0px 2px #FF9232;box-shadow:inset 0px 0px 0px 2px #FF9232;background:rgba(255,146,50,0.1)}.et-save-to-library-modal .et-common-prompt__content{overflow-x:hidden}.et-save-to-library-modal .et-common-prompt__content::-webkit-scrollbar{width:10px;cursor:initial}.et-save-to-library-modal .et-common-prompt__content::-webkit-scrollbar-thumb{background:#4C5866 !important;border-radius:3px;border-right:3px solid #fff;border-left:3px solid #fff}.et-save-to-library-modal .et-common-prompt__content::-webkit-scrollbar-thumb{border-right-width:0;border-radius:0}.rtl .et-save-to-library-modal .et-common-prompt__content::-webkit-scrollbar-thumb{border-left-width:0;border-right-width:3px}.et-save-to-library-modal .et-cloud-category-mark,.et-save-to-library-modal .et-cloud-tag-mark{margin-right:5px !important;margin-left:0px !important;width:14px !important;height:14px !important;min-width:12px !important}.rtl .et-save-to-library-modal .et-cloud-category-mark,.rtl .et-save-to-library-modal .et-cloud-tag-mark{margin-right:0 !important;margin-left:5px !important}.et-save-to-library-modal .et-common-tag-marked,.et-save-to-library-modal .et-common-selected-tag-marked{position:relative;background:#0088E1 !important;color:#fff !important}.et-save-to-library-modal .et-common-tag-marked .ReactTags__remove,.et-save-to-library-modal .et-common-selected-tag-marked .ReactTags__remove{background:#0088E1 !important;color:#fff !important}.et-save-to-library-modal .et-common-tag-marked:before,.et-save-to-library-modal .et-common-selected-tag-marked:before{font-family:'CloudApp';content:'\e900';color:#fff;margin-right:5px} .CodeMirror{font-family:monospace;height:300px;color:black;direction:ltr}.CodeMirror-lines{padding:4px 0}.CodeMirror pre.CodeMirror-line,.CodeMirror pre.CodeMirror-line-like{padding:0 4px}.CodeMirror-scrollbar-filler,.CodeMirror-gutter-filler{background-color:white}.CodeMirror-gutters{border-right:1px solid #ddd;background-color:#f7f7f7;white-space:nowrap}.CodeMirror-linenumber{padding:0 3px 0 5px;min-width:20px;text-align:right;color:#999;white-space:nowrap}.CodeMirror-guttermarker{color:black}.CodeMirror-guttermarker-subtle{color:#999}.CodeMirror-cursor{border-left:1px solid black;border-right:none;width:0}.CodeMirror div.CodeMirror-secondarycursor{border-left:1px solid silver}.cm-fat-cursor .CodeMirror-cursor{width:auto;border:0 !important;background:#7e7}.cm-fat-cursor div.CodeMirror-cursors{z-index:1}.cm-fat-cursor .CodeMirror-line::-moz-selection, .cm-fat-cursor .CodeMirror-line>span::-moz-selection, .cm-fat-cursor .CodeMirror-line>span>span::-moz-selection{background:transparent}.cm-fat-cursor .CodeMirror-line::selection,.cm-fat-cursor .CodeMirror-line>span::selection,.cm-fat-cursor .CodeMirror-line>span>span::selection{background:transparent}.cm-fat-cursor .CodeMirror-line::-moz-selection,.cm-fat-cursor .CodeMirror-line>span::-moz-selection,.cm-fat-cursor .CodeMirror-line>span>span::-moz-selection{background:transparent}.cm-fat-cursor{caret-color:transparent}@-webkit-keyframes blink{0%{}50%{background-color:transparent}100%{}}@keyframes blink{0%{}50%{background-color:transparent}100%{}}.cm-tab{display:inline-block;text-decoration:inherit}.CodeMirror-rulers{position:absolute;left:0;right:0;top:-50px;bottom:0;overflow:hidden}.CodeMirror-ruler{border-left:1px solid #ccc;top:0;bottom:0;position:absolute}.cm-s-default .cm-header{color:blue}.cm-s-default .cm-quote{color:#090}.cm-negative{color:#d44}.cm-positive{color:#292}.cm-header,.cm-strong{font-weight:bold}.cm-em{font-style:italic}.cm-link{text-decoration:underline}.cm-strikethrough{text-decoration:line-through}.cm-s-default .cm-keyword{color:#708}.cm-s-default .cm-atom{color:#219}.cm-s-default .cm-number{color:#164}.cm-s-default .cm-def{color:#00f}.cm-s-default .cm-variable-2{color:#05a}.cm-s-default .cm-variable-3,.cm-s-default .cm-type{color:#085}.cm-s-default .cm-comment{color:#a50}.cm-s-default .cm-string{color:#a11}.cm-s-default .cm-string-2{color:#f50}.cm-s-default .cm-meta{color:#555}.cm-s-default .cm-qualifier{color:#555}.cm-s-default .cm-builtin{color:#30a}.cm-s-default .cm-bracket{color:#997}.cm-s-default .cm-tag{color:#170}.cm-s-default .cm-attribute{color:#00c}.cm-s-default .cm-hr{color:#999}.cm-s-default .cm-link{color:#00c}.cm-s-default .cm-error{color:#f00}.cm-invalidchar{color:#f00}.CodeMirror-composing{border-bottom:2px solid}div.CodeMirror span.CodeMirror-matchingbracket{color:#0b0}div.CodeMirror span.CodeMirror-nonmatchingbracket{color:#a22}.CodeMirror-matchingtag{background:rgba(255,150,0,0.3)}.CodeMirror-activeline-background{background:#e8f2ff}.CodeMirror{position:relative;overflow:hidden;background:white}.CodeMirror-scroll{overflow:scroll !important;margin-bottom:-50px;margin-right:-50px;padding-bottom:50px;height:100%;outline:none;position:relative;z-index:0}.CodeMirror-sizer{position:relative;border-right:50px solid transparent}.CodeMirror-vscrollbar,.CodeMirror-hscrollbar,.CodeMirror-scrollbar-filler,.CodeMirror-gutter-filler{position:absolute;z-index:6;display:none;outline:none}.CodeMirror-vscrollbar{right:0;top:0;overflow-x:hidden;overflow-y:scroll}.CodeMirror-hscrollbar{bottom:0;left:0;overflow-y:hidden;overflow-x:scroll}.CodeMirror-scrollbar-filler{right:0;bottom:0}.CodeMirror-gutter-filler{left:0;bottom:0}.CodeMirror-gutters{position:absolute;left:0;top:0;min-height:100%;z-index:3}.CodeMirror-gutter{white-space:normal;height:100%;display:inline-block;vertical-align:top;margin-bottom:-50px}.CodeMirror-gutter-wrapper{position:absolute;z-index:4;background:none !important;border:none !important}.CodeMirror-gutter-background{position:absolute;top:0;bottom:0;z-index:4}.CodeMirror-gutter-elt{position:absolute;cursor:default;z-index:4}.CodeMirror-gutter-wrapper ::-moz-selection{background-color:transparent}.CodeMirror-gutter-wrapper ::selection{background-color:transparent}.CodeMirror-gutter-wrapper ::-moz-selection{background-color:transparent}.CodeMirror-lines{cursor:text;min-height:1px}.CodeMirror pre.CodeMirror-line,.CodeMirror pre.CodeMirror-line-like{border-radius:0;border-width:0;background:transparent;font-family:inherit;font-size:inherit;margin:0;white-space:pre;word-wrap:normal;line-height:inherit;color:inherit;z-index:2;position:relative;overflow:visible;-webkit-tap-highlight-color:transparent;-webkit-font-variant-ligatures:contextual;font-variant-ligatures:contextual}.CodeMirror-wrap pre.CodeMirror-line,.CodeMirror-wrap pre.CodeMirror-line-like{word-wrap:break-word;white-space:pre-wrap;word-break:normal}.CodeMirror-linebackground{position:absolute;left:0;right:0;top:0;bottom:0;z-index:0}.CodeMirror-linewidget{position:relative;z-index:2;padding:0.1px}.CodeMirror-rtl pre{direction:rtl}.CodeMirror-code{outline:none}.CodeMirror-scroll,.CodeMirror-sizer,.CodeMirror-gutter,.CodeMirror-gutters,.CodeMirror-linenumber{-webkit-box-sizing:content-box;box-sizing:content-box}.CodeMirror-measure{position:absolute;width:100%;height:0;overflow:hidden;visibility:hidden}.CodeMirror-cursor{position:absolute;pointer-events:none}.CodeMirror-measure pre{position:static}div.CodeMirror-cursors{visibility:hidden;position:relative;z-index:3}div.CodeMirror-dragcursors{visibility:visible}.CodeMirror-focused div.CodeMirror-cursors{visibility:visible}.CodeMirror-selected{background:#d9d9d9}.CodeMirror-focused .CodeMirror-selected{background:#d7d4f0}.CodeMirror-crosshair{cursor:crosshair}.CodeMirror-line::-moz-selection, .CodeMirror-line>span::-moz-selection, .CodeMirror-line>span>span::-moz-selection{background:#d7d4f0}.CodeMirror-line::selection,.CodeMirror-line>span::selection,.CodeMirror-line>span>span::selection{background:#d7d4f0}.CodeMirror-line::-moz-selection,.CodeMirror-line>span::-moz-selection,.CodeMirror-line>span>span::-moz-selection{background:#d7d4f0}.cm-searching{background-color:#ffa;background-color:rgba(255,255,0,0.4)}.cm-force-border{padding-right:.1px}@media print{.CodeMirror div.CodeMirror-cursors{visibility:hidden}}.cm-tab-wrap-hack:after{content:''}span.CodeMirror-selectedtext{background:none} .CodeMirror-hints{position:absolute;z-index:10;overflow:hidden;list-style:none;margin:0;padding:2px;-webkit-box-shadow:2px 3px 5px rgba(0,0,0,0.2);box-shadow:2px 3px 5px rgba(0,0,0,0.2);border-radius:3px;border:1px solid silver;background:white;font-size:90%;font-family:monospace;max-height:20em;overflow-y:auto}.CodeMirror-hint{margin:0;padding:0 4px;border-radius:2px;white-space:pre;color:black;cursor:pointer}li.CodeMirror-hint-active{background:#08f;color:white} .CodeMirror-dialog{position:absolute;left:0;right:0;background:inherit;z-index:15;padding:.1em .8em;overflow:hidden;color:inherit}.CodeMirror-dialog-top{border-bottom:1px solid #eee;top:0}.CodeMirror-dialog-bottom{border-top:1px solid #eee;bottom:0}.CodeMirror-dialog input{border:none;outline:none;background:transparent;width:20em;color:inherit;font-family:monospace}.CodeMirror-dialog button{font-size:70%} .codemirror-colorview{border:1px solid #8e8e8e;position:relative;display:inline-block;-webkit-box-sizing:border-box;box-sizing:border-box;margin:0px 2px;width:10px;height:10px;cursor:pointer;background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAJElEQVQYV2NctWrVfwYkEBYWxojMZ6SDAmT7QGx0K1EcRBsFAADeG/3M/HteAAAAAElFTkSuQmCC");background-repeat:repeat}.codemirror-colorview .codemirror-colorview-background{content:"";position:absolute;left:0px;right:0px;bottom:0px;top:0px}.codemirror-colorview:hover{border-color:#494949}.codemirror-colorpicker{position:relative;width:224px;z-index:1000;border:1px solid black}.codemirror-colorpicker>.color{position:relative;height:120px;overflow:hidden;cursor:pointer}.codemirror-colorpicker>.color>.saturation{position:relative;width:100%;height:100%}.codemirror-colorpicker>.color>.saturation>.value{position:relative;width:100%;height:100%}.codemirror-colorpicker>.color>.saturation>.value>.drag-pointer{position:absolute;width:10px;height:10px;border-radius:50%;left:-5px;top:-5px}.codemirror-colorpicker>.control{position:relative;padding:10px 0px 10px 0px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.codemirror-colorpicker>.control>.color,.codemirror-colorpicker>.control>.empty{position:absolute;left:11px;top:14px;width:30px;height:30px;border-radius:50%;-webkit-box-sizing:border-box;box-sizing:border-box}.codemirror-colorpicker>.control>.hue{position:relative;padding:6px 16px;margin:0px 0px 0px 45px;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer}.codemirror-colorpicker>.control>.hue>.hue-container{position:relative;width:100%;height:10px;border-radius:3px}.codemirror-colorpicker>.control>.opacity{position:relative;padding:3px 16px;margin:0px 0px 0px 45px;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer}.codemirror-colorpicker>.control>.opacity>.opacity-container{position:relative;width:100%;height:10px;border-radius:3px}.codemirror-colorpicker>.control .drag-bar,.codemirror-colorpicker>.control .drag-bar2{position:absolute;cursor:pointer;top:50% !important;margin-top:-7px !important;left:-3px;width:12px;height:12px;border-radius:50px}.codemirror-colorpicker>.information{position:relative;-webkit-box-sizing:padding-box;box-sizing:padding-box}.codemirror-colorpicker>.information.hex>.information-item.hex{display:-webkit-box;display:-ms-flexbox;display:flex}.codemirror-colorpicker>.information.rgb>.information-item.rgb{display:-webkit-box;display:-ms-flexbox;display:flex}.codemirror-colorpicker>.information.hsl>.information-item.hsl{display:-webkit-box;display:-ms-flexbox;display:flex}.codemirror-colorpicker>.information>.information-item{display:none;position:relative;padding:0px 5px;-webkit-box-sizing:border-box;box-sizing:border-box;margin-right:40px}.codemirror-colorpicker>.information>.information-change{position:absolute;display:block;width:40px;top:0px;right:0px;bottom:0px}.codemirror-colorpicker>.information>.information-change>.format-change-button{width:100%;height:100%;background:transparent;border:0px;cursor:pointer;outline:none}.codemirror-colorpicker>.information>.information-item>.input-field{display:block;-webkit-box-flex:1;-ms-flex:1;flex:1;padding:3px;-webkit-box-sizing:border-box;box-sizing:border-box}.codemirror-colorpicker>.information>.information-item>.input-field>input{text-align:center;width:100%;padding:3px;font-size:11px;color:#333;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;-o-user-select:text;user-select:text;border:1px solid #cbcbcb;border-radius:2px}.codemirror-colorpicker>.information>.information-item>.input-field>.title{text-align:center;font-size:12px;color:#a9a9a9;padding-top:2px}.codemirror-colorpicker>.information>input{position:absolute;font-size:10px;height:20px;bottom:20px;padding:0 0 0 2px;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;-o-user-select:text;user-select:text}.codemirror-colorpicker{border:1px solid rgba(0,0,0,0.2);background-color:#fff;border-radius:3px;-webkit-box-shadow:0 0px 10px 0px rgba(0,0,0,0.12);box-shadow:0 0px 10px 0px rgba(0,0,0,0.12)}.codemirror-colorpicker>.color>.saturation{background-color:rgba(204,154,129,0);background-image:-webkit-gradient(linear, left top, right top, from(#fff), to(rgba(204,154,129,0)));background-image:linear-gradient(to right, #fff, rgba(204,154,129,0));background-repeat:repeat-x;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#00cc9a81', GradientType=1)}.codemirror-colorpicker>.color>.saturation>.value{background-image:-webkit-gradient(linear, left bottom, left top, from(#000), to(rgba(204,154,129,0)));background-image:linear-gradient(to top, #000, rgba(204,154,129,0))}.codemirror-colorpicker>.color>.saturation>.value>.drag-pointer{border:1px solid #fff;-webkit-box-shadow:0 0 2px 0 rgba(0,0,0,0.05);box-shadow:0 0 2px 0 rgba(0,0,0,0.05)}.codemirror-colorpicker>.control>.hue>.hue-container{background:-webkit-gradient(linear, left top, right top, from(red), color-stop(17%, #ff0), color-stop(33%, lime), color-stop(50%, cyan), color-stop(67%, blue), color-stop(83%, #f0f), to(red));background:linear-gradient(to right, red 0%, #ff0 17%, lime 33%, cyan 50%, blue 67%, #f0f 83%, red 100%)}.codemirror-colorpicker>.control>.opacity>.opacity-container>.color-bar{position:absolute;display:block;content:"";left:0px;right:0px;bottom:0px;top:0px;background:-webkit-gradient(linear, left top, right top, from(rgba(232,232,232,0)), to(#e8e8e8));background:linear-gradient(to right, rgba(232,232,232,0), #e8e8e8)}.codemirror-colorpicker>.control>.opacity>.opacity-container{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAJElEQVQYV2NctWrVfwYkEBYWxojMZ6SDAmT7QGx0K1EcRBsFAADeG/3M/HteAAAAAElFTkSuQmCC");background-repeat:repeat}.codemirror-colorpicker>.control>.empty{background:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAJElEQVQYV2NctWrVfwYkEBYWxojMZ6SDAmT7QGx0K1EcRBsFAADeG/3M/HteAAAAAElFTkSuQmCC") repeat}.codemirror-colorpicker>.control .drag-bar,.codemirror-colorpicker>.control .drag-bar2{border:1px solid rgba(0,0,0,0.05);-webkit-box-shadow:0 0 2px 0 rgba(0,0,0,0.1);box-shadow:2px 2px 2px 0px rgba(0,0,0,0.2);background-color:#fefefe}.codemirror-colorpicker>.information>.title{color:#a3a3a3}.codemirror-colorpicker>.information>.input{color:#333}.codemirror-colorpicker>.colorsets{border-top:1px solid #e2e2e2}.codemirror-colorpicker>.colorsets>.menu{float:right;padding:4px 6px}.codemirror-colorpicker>.colorsets>.menu button{border:0px;font-size:14px;font-weight:300;font-family:serif, sans-serif;outline:none;cursor:pointer}.codemirror-colorpicker>.colorsets>.color-list{margin-right:20px;display:block;padding:12px;padding-bottom:0px;-webkit-box-sizing:border-box;box-sizing:border-box;line-height:0}.codemirror-colorpicker>.colorsets>.color-list .color-item{width:13px;height:13px;border-radius:3px;display:inline-block;margin-right:12px;margin-bottom:12px;background:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAJElEQVQYV2NctWrVfwYkEBYWxojMZ6SDAmT7QGx0K1EcRBsFAADeG/3M/HteAAAAAElFTkSuQmCC") no-repeat;background-size:contain;border:1px solid rgba(221,221,221,0.5);overflow:hidden;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer;vertical-align:middle}.codemirror-colorpicker>.colorsets>.color-list .color-item:hover{-webkit-transform:scale(1.2);transform:scale(1.2)}.codemirror-colorpicker>.colorsets>.color-list .color-item .color-view{width:100%;height:100%;padding:0px;margin:0px;pointer-events:none}.codemirror-colorpicker>.colorsets>.color-list .add-color-item{display:inline-block;margin-bottom:12px;-webkit-box-sizing:border-box;box-sizing:border-box;cursor:pointer;line-height:0;font-size:16px;font-weight:400;font-family:serif,sans-serif;color:#8e8e8e;vertical-align:middle}.codemirror-colorpicker>.color-chooser{position:absolute;top:0px;left:0px;right:0px;bottom:0px;background-color:rgba(0,0,0,0.3)}.codemirror-colorpicker>.color-chooser>.colorsets-list{position:absolute;top:120px;left:0px;right:0px;bottom:0px;background-color:white} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}html{}.et-common-codemirror{position:relative}.et-common-codemirror textarea.et-fb-settings-option-textarea,.et-common-codemirror textarea.et-fb-settings-option-textarea:focus{background-color:#4C5866 !important}.et-common-codemirror .react-codemirror2{border-radius:3px;background-color:#4C5866;min-height:120px;overflow:hidden}.et-common-codemirror .react-codemirror2 .CodeMirror-widget{line-height:8px}.et-common-codemirror .react-codemirror2 .CodeMirror-wrap{padding:4px 6px 4px 0}.et-common-codemirror .react-codemirror2 .CodeMirror-sizer{margin-left:29px !important}.et-common-codemirror .react-codemirror2 .CodeMirror-gutter-wrapper{left:-29px !important}.et-common-codemirror .react-codemirror2 .CodeMirror-gutters{left:-29px !important}.et-common-codemirror .react-codemirror2 .CodeMirror-gutters .CodeMirror-linenumbers{width:29px !important}.et-common-codemirror .react-codemirror2 .CodeMirror-linenumber.CodeMirror-gutter-elt{width:21px !important}.et-common-codemirror .react-codemirror2 .CodeMirror{font-size:13px;line-height:150%;height:auto}.et-common-codemirror .react-codemirror2 .CodeMirror .CodeMirror-scroll{min-height:110px;margin-bottom:-30px;margin-right:-30px;padding-bottom:30px;outline:none}.et-common-codemirror .react-codemirror2 .CodeMirror .CodeMirror-linenumber{text-align:right}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et{background-color:#4C5866;color:#fff}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-placeholder{color:#A2B0C1}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-gutters{background:#4C5866;color:#537f7e;border:none}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-guttermarker,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-guttermarker-subtle,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-linenumber{color:#8393a5}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-cursor{border-left:1px solid #fff}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et div.CodeMirror-selected{background:rgba(145,203,255,0.2)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-s-material.CodeMirror-focused div.CodeMirror-selected{background:rgba(0,0,0,0.1)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line::-moz-selection, .et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line>span::-moz-selection, .et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line>span>span::-moz-selection{background:rgba(0,0,0,0.1)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line::selection,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line>span::selection,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line>span>span::selection{background:rgba(0,0,0,0.1)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line::-moz-selection,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line>span::-moz-selection,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-line>span>span::-moz-selection{background:rgba(0,0,0,0.1)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-activeline-background{background:rgba(0,0,0,0.1)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et.CodeMirror-empty .CodeMirror-activeline-background{background:#4C5866}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et.CodeMirror-empty.CodeMirror-focused .CodeMirror-activeline-background{background:rgba(0,0,0,0.1)}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et.CodeMirror-empty .CodeMirror-scroll{min-height:120px;margin-bottom:-20px}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-keyword{color:#88c2f8}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-operator{color:#fff}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-variable-2,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-string-2,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-meta{color:#fff}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-variable-3,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-type{color:#88c2f8}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-builtin,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-qualifier,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-variable-3,.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-type{color:#fe9c47}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-atom{color:#88c2f8}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-number{color:#fe9c47}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-def{color:#fff}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-string{color:#fe9c47}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-comment{color:#8393a5}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-variable{color:#88c2f8}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-attribute{color:#88c2f8}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-property{color:#88dfbe}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-tag{color:#88dfbe}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .cm-searching{background:none;border-bottom:1px solid #fff;color:#fff}.et-common-codemirror .react-codemirror2 .CodeMirror.cm-s-et .CodeMirror-matchingbracket{text-decoration:underline;color:#fff !important}.et-common-codemirror .react-codemirror2 .CodeMirror .CodeMirror-matchingtag{background:rgba(255,255,255,0.15)}.et-common-codemirror .react-codemirror2 .CodeMirror .CodeMirror-linewidget{width:100% !important}.et-common-codemirror .react-codemirror2 .CodeMirror .codemirror-lint-warning,.et-common-codemirror .react-codemirror2 .CodeMirror .codemirror-lint-error{background-color:transparent;border-radius:3px;padding:5px 10px;margin:5px 0}.et-common-codemirror .react-codemirror2 .CodeMirror .codemirror-lint-error{color:#ff5758;border:2px solid #ff5758}.et-common-codemirror .react-codemirror2 .CodeMirror .codemirror-lint-warning{color:#fe9c47;border:2px solid #fe9c47}.et-common-codemirror .react-codemirror2 .CodeMirror .codemirror-colorview{border:1px solid #fff;border-radius:10px;margin:0 5px 0 0}.et-common-codemirror .react-codemirror2 .CodeMirror .codemirror-colorview .codemirror-colorview-background{border-radius:10px}.et-cloud-app-details-view-active .et-common-codemirror .react-codemirror2 .CodeMirror{font-weight:normal;height:100%}.et-common-codemirror textarea.et-fb-settings-option-textarea{display:block;resize:none}.et-cloud-app-codemirror .et-common-codemirror,.et-cloud-app-codemirror .et-common-codemirror .react-codemirror2,.et-common-codemirror .et-cloud-app-codemirror .CodeMirror{height:100%}.CodeMirror-vscrollbar::-webkit-scrollbar{width:10px;cursor:initial}.CodeMirror-vscrollbar::-webkit-scrollbar-thumb{background:#67737F !important;border-radius:3px;border-right:3px solid #4C5866;border-left:3px solid #4C5866}#et-cloud-app .et-cloud-app-layout-screenshot.et-cloud-app-codemirror .et-cloud-app-layout-cta-buttons{margin-top:-40px}#et-cloud-app .et-cloud-app-layout-screenshot.et-cloud-app-codemirror .et-cloud-app-layout-cta-buttons .et-common-button{z-index:9}html .CodeMirror-hints{z-index:1000000000}html .codemirror-colorpicker{z-index:1000000000}html .CodeMirror-dialog-top{background:#F1F5F9;border-bottom:none;-webkit-box-shadow:0 0 50px rgba(0,0,0,0.5);box-shadow:0 0 50px rgba(0,0,0,0.5);height:30px}html .CodeMirror-dialog-top .CodeMirror-search-label{color:#bec9d6;font-size:14px;font-weight:600;height:30px}html .CodeMirror-dialog-top .CodeMirror-search-field{font-weight:600 !important;color:#4C5866 !important;font-size:13px !important;height:30px}html .CodeMirror-dialog-top .CodeMirror-search-hint{display:none} @-webkit-keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@keyframes et-spinner{0%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}25%{-webkit-box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9;box-shadow:17px 0 #2B87DA,0 17px #29C4A9,-17px 0 #2B87DA,0 -17px #29C4A9}50%{-webkit-box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232;box-shadow:0 17px #2B87DA,-17px 0 #FF9232,0 -17px #2B87DA,17px 0 #FF9232}75%{-webkit-box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232;box-shadow:-17px 0 #7E3BD0,0 -17px #FF9232,17px 0 #7E3BD0,0 17px #FF9232}100%{-webkit-box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9;box-shadow:0 -17px #7E3BD0,17px 0 #29C4A9,0 17px #7E3BD0,-17px 0 #29C4A9}}@-webkit-keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}@keyframes et-pulse-animation{0%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}10%{-webkit-transform:scale(1);transform:scale(1)}20%{-webkit-transform:scale(1.02);transform:scale(1.02)}30%{-webkit-transform:scale(1.04);transform:scale(1.04)}40%{-webkit-transform:scale(1.06);transform:scale(1.06)}50%{-webkit-transform:scale(1.08);transform:scale(1.08)}60%{-webkit-transform:scale(1.06);transform:scale(1.06);border-color:#00c3aa}70%{-webkit-transform:scale(1.04);transform:scale(1.04)}80%{-webkit-transform:scale(1.02);transform:scale(1.02)}80%{-webkit-transform:scale(1);transform:scale(1)}100%{-webkit-transform:scale(0.95);transform:scale(0.95);border-color:#2b87da}}.divi-cloud-item-editor-overlay{position:fixed;left:0;top:0;width:100vw;height:100vh;background:radial-gradient(ellipse at center, #fff 20%, rgba(255,255,255,0.7) 100%);z-index:159900;-webkit-animation:et-core-fade-in 500ms linear;animation:et-core-fade-in 500ms linear}.divi-cloud-item-editor-modal-positioner{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;position:fixed;left:30px;top:32px;right:30px;bottom:30px;z-index:159900;-webkit-font-smoothing:antialiased}.divi-cloud-item-editor .et-common-prompt__container{width:calc(100% - 40px);height:calc(100% - 40px)}.divi-cloud-item-editor .et-common-prompt__body{height:calc(100vh - 140px)}.divi-cloud-item-editor .et-common-prompt .react-codemirror2 .CodeMirror{height:calc(100vh - 210px)}.et-fb .divi-cloud-item-editor .et-common-prompt .react-codemirror2 .CodeMirror{height:calc(100vh - 202px)} #et-code-snippets-container{position:relative;z-index:9999999}.et-code-snippets-library__container #et-cloud-app .et-cloud-app-layout .et-cloud-app-meta-icons{margin-top:15px}.et-code-snippets-library__container #et-cloud-app .et-cloud-app-layout-placeholder:before{font-family:'etbuilder';speak:none;font-weight:normal;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:80px;margin-bottom:5px;color:#e7eef5;content:'\0074';z-index:99;position:absolute;top:0;right:0;width:100%;height:100%;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.et-code-snippets-library__container #et-cloud-app .et-cloud-app-layout-screenshot::before{position:static !important}.et-code-snippets-library__container #et-cloud-app .et-cloud-app-layouts-grid-item-disabled .et-cloud-app-layout-placeholder:before{content:''} item-library-local/ItemLibraryLocal.php 0000644 00000026235 15222641012 0014146 0 ustar 00 <?php /** * Local Library API. * * @since 4.21.0 * * @package Divi */ if ( ! defined( 'ABSPATH' ) ) { exit; // Exit if accessed directly. } /** * ET_Item_Library_Local utility class. * * Item can be a layout, a template, a theme option, a code snippet, etc. * * @since 4.21.0 * * @return void */ abstract class ET_Item_Library_Local { /** * Instance. * * @var ET_Item_Library_Local Class instance. */ public static $_instance; /** * Post Type. * * @var string Post Type. */ public $post_type; /** * Ignore Process. * * @var array Ignore Process. */ public $exceptional_processes = array(); /** * Gets the library items. * * @param string $item_type Item Type. * * @return Array An array of items data. */ abstract public function get_library_items( $item_type ); /** * Remove, Rename or Add new Category/Tag into local library. * * @param array $payload Array with the update details. * * @return array */ public function perform_terms_update( $payload ) { if ( ! current_user_can( 'manage_categories' ) ) { wp_die(); } $new_terms = array(); foreach ( $payload as $single_item ) { $filter_type = $single_item['filterType']; $taxonomy = 'tags' === $single_item['filterType'] ? 'layout_tag' : 'layout_category'; switch ( $single_item['updateType'] ) { case 'remove': $term_id = (int) $single_item['id']; wp_delete_term( $term_id, $taxonomy ); break; case 'rename': $term_id = (int) $single_item['id']; $new_name = (string) $single_item['newName']; if ( '' !== $new_name ) { $updated_term_data = wp_update_term( $term_id, $taxonomy, array( 'name' => $new_name ) ); if ( ! is_wp_error( $updated_term_data ) ) { $new_terms[] = array( 'name' => $new_name, 'id' => $updated_term_data['term_id'], 'location' => 'local', ); } } break; case 'add': $term_name = (string) $single_item['id']; $new_term_data = wp_insert_term( $term_name, $taxonomy ); if ( ! is_wp_error( $new_term_data ) ) { $new_terms[] = array( 'name' => $term_name, 'id' => $new_term_data['term_id'], 'location' => 'local', ); } break; } } return array( 'newFilters' => $new_terms, 'filterType' => $filter_type, 'localLibraryTerms' => [ 'layout_category' => $this->get_processed_terms( 'layout_category' ), 'layout_tag' => $this->get_processed_terms( 'layout_tag' ), ], ); } /** * Gets the terms list and processes it into desired format. * * @since 4.18.0 * * @param string $term_name Term Name. * * @return array $terms_by_id */ public function get_processed_terms( $term_name ) { $terms = get_terms( $term_name, array( 'hide_empty' => false ) ); $terms_by_id = array(); if ( is_wp_error( $terms ) || empty( $terms ) ) { return array(); } foreach ( $terms as $term ) { $term_id = $term->term_id; $terms_by_id[ $term_id ]['id'] = $term_id; $terms_by_id[ $term_id ]['name'] = $term->name; $terms_by_id[ $term_id ]['slug'] = $term->slug; $terms_by_id[ $term_id ]['count'] = $term->count; } return $terms_by_id; } /** * Processes item taxonomies for inclusion in the library UI items data. * * @since 4.18.0 * * @param WP_POST $post Unprocessed item. * @param object $item Currently processing item. * @param int $index The item's index position. * @param array[] $item_terms Processed items. * @param string $taxonomy_name Item name. * @param string $type Item type. * * @return void */ public function process_item_taxonomy( $post, $item, $index, &$item_terms, $taxonomy_name, $type ) { $terms = wp_get_post_terms( $post->ID, $taxonomy_name ); if ( ! $terms ) { if ( 'category' === $type ) { $item->category_slug = 'uncategorized'; } return; } foreach ( $terms as $term ) { $term_name = et_core_intentionally_unescaped( $term->name, 'react_jsx' ); if ( ! isset( $item_terms[ $term->term_id ] ) ) { $item_terms[ $term->term_id ] = array( 'id' => $term->term_id, 'name' => $term_name, 'slug' => $term->slug, 'items' => array(), ); } $item_terms[ $term->term_id ]['items'][] = $index; if ( 'category' === $type ) { $item->categories[] = $term_name; } else { $item->tags[] = $term_name; } $item->{$type . '_ids'}[] = $term->term_id; if ( ! isset( $item->{$type . '_slug'} ) ) { $item->{$type . '_slug'} = $term->slug; } $id = get_post_meta( $post->ID, "_primary_{$taxonomy_name}", true ); if ( $id ) { // $id is a string, $term->term_id is an int. if ( $id === $term->term_id ) { // This is the primary term (used in the item URL). $item->{$type . '_slug'} = $term->slug; } } } } /** * Update library item. Support following updates: * - Duplicate * - Rename * - Toggle Favorite status * - Delete * - Delete Permanently * - Restore * * @since 4.21.0 * * @param array $payload Array with the id and update details. * * @return array Updated item details */ protected function _perform_item_common_updates( $payload ) { if ( empty( $payload['item_id'] ) || empty( $payload['update_details'] ) ) { return false; } $update_details = $payload['update_details']; if ( empty( $update_details['updateType'] ) ) { return false; } $et_builder_categories = ET_Builder_Post_Taxonomy_LayoutCategory::instance(); $et_builder_tags = ET_Builder_Post_Taxonomy_LayoutTag::instance(); $new_id = 0; $item_id = absint( $payload['item_id'] ); $item_update = array( 'ID' => $item_id ); $update_type = sanitize_text_field( $update_details['updateType'] ); $item_name = isset( $update_details['itemName'] ) ? sanitize_text_field( $update_details['itemName'] ) : ''; $favorite_status = isset( $update_details['favoriteStatus'] ) && ( 'on' === $update_details['favoriteStatus'] ) ? 'favorite' : ''; $categories = isset( $update_details['itemCategories'] ) ? array_unique( array_map( 'absint', $update_details['itemCategories'] ) ) : array(); $tags = isset( $update_details['itemTags'] ) ? array_unique( array_map( 'absint', $update_details['itemTags'] ) ) : array(); $post_type = get_post_type( $item_id ); if ( ! empty( $update_details['newCategoryName'] ) ) { $categories = $this->_create_and_get_all_item_terms( $update_details['newCategoryName'], $categories, $et_builder_categories->name ); } if ( ! empty( $update_details['newTagName'] ) ) { $tags = $this->_create_and_get_all_item_terms( $update_details['newTagName'], $tags, $et_builder_tags->name ); } if ( in_array( $update_type, $this->exceptional_processes, true ) ) { $update_type = 'default'; } switch ( $update_type ) { case 'duplicate': case 'duplicate_and_delete': break; case 'rename': if ( ! current_user_can( 'edit_post', $item_id ) || $this->post_type !== $post_type ) { return; } if ( $item_name ) { $item_update['post_title'] = $item_name; wp_update_post( $item_update ); } break; case 'toggle_fav': update_post_meta( $item_id, 'favorite_status', $favorite_status ); break; case 'delete': if ( ! current_user_can( 'edit_post', $item_id ) || $this->post_type !== $post_type ) { return; } wp_trash_post( $item_id ); break; case 'delete_permanently': if ( ! current_user_can( 'edit_post', $item_id ) || $this->post_type !== $post_type ) { return; } wp_delete_post( $item_id, true ); break; case 'restore': if ( ! current_user_can( 'edit_post', $item_id ) || $this->post_type !== $post_type ) { return; } $publish_fn = function() { return 'publish'; }; // wp_untrash_post() restores the post to `draft` by default, we have to set `publish` status via filter. add_filter( 'wp_untrash_post_status', $publish_fn ); wp_untrash_post( $item_id ); remove_filter( 'wp_untrash_post_status', $publish_fn ); break; case 'edit_cats': wp_set_object_terms( $item_id, $categories, $et_builder_categories->name ); wp_set_object_terms( $item_id, $tags, $et_builder_tags->name ); break; } // Continue with additional data. $processed_new_categories = array(); $processed_new_tags = array(); $updated_categories = get_terms( array( 'taxonomy' => $et_builder_categories->name, 'hide_empty' => false, ) ); $updated_tags = get_terms( array( 'taxonomy' => $et_builder_tags->name, 'hide_empty' => false, ) ); if ( ! empty( $updated_categories ) ) { foreach ( $updated_categories as $single_category ) { $processed_new_categories[] = array( 'id' => $single_category->term_id, 'name' => $single_category->name, 'count' => $single_category->count, 'location' => 'local', ); } } if ( ! empty( $updated_tags ) ) { foreach ( $updated_tags as $single_tag ) { $processed_new_tags[] = array( 'id' => $single_tag->term_id, 'name' => $single_tag->name, 'count' => $single_tag->count, 'location' => 'local', ); } } return array( 'updatedItem' => $item_id, 'newItem' => $new_id, 'updateType' => $update_type, 'categories' => $categories, 'tags' => $tags, 'updatedTerms' => array( 'categories' => $processed_new_categories, 'tags' => $processed_new_tags, ), ); } /** * Get all terms of an item and merge any newly passed IDs with the list. * * @since 4.19.0 * * @param string $new_terms_list List of new terms. * @param array $taxonomies Taxonomies. * @param string $taxonomy_name Taxonomy name. * * @return array */ private function _create_and_get_all_item_terms( $new_terms_list, $taxonomies, $taxonomy_name ) { $new_names_array = explode( ',', $new_terms_list ); foreach ( $new_names_array as $new_name ) { if ( '' !== $new_name ) { $new_term = wp_insert_term( $new_name, $taxonomy_name ); if ( ! is_wp_error( $new_term ) ) { $taxonomies[] = $new_term['term_id']; } elseif ( ! empty( $new_term->error_data ) && ! empty( $new_term->error_data['term_exists'] ) ) { $taxonomies[] = $new_term->error_data['term_exists']; } } } return $taxonomies; } /** * Prepare Library Categories or Tags List. * * @param string $taxonomy Name of the taxonomy. * * @return array Clean Categories/Tags array. **/ public function get_formatted_library_terms( $taxonomy = 'layout_category' ) { $raw_terms_array = apply_filters( 'et_pb_new_layout_cats_array', get_terms( $taxonomy, array( 'hide_empty' => false ) ) ); $formatted_terms_array = array(); if ( is_array( $raw_terms_array ) && ! empty( $raw_terms_array ) ) { foreach ( $raw_terms_array as $term ) { $formatted_terms_array[] = array( 'name' => et_core_intentionally_unescaped( html_entity_decode( $term->name ), 'react_jsx' ), 'id' => $term->term_id, 'slug' => $term->slug, 'count' => $term->count, ); } } return $formatted_terms_array; } } init.php 0000644 00000013360 15222641012 0006216 0 ustar 00 <?php /** * Load Elegant Themes Core. * * @package \ET\Core */ if ( defined( 'ET_CORE' ) ) { // Core has already been loaded. return; } define( 'ET_CORE', true ); if ( ! function_exists( '_et_core_find_latest' ) ) : /** * Find the latest version of Core currently available. * * @since 3.0.60 * * @return string $core_path Absolute path to the latest version of core. */ function _et_core_find_latest( $return = 'path' ) { static $latest_core_path = null; static $latest_core_version = null; if ( 'path' === $return && null !== $latest_core_path ) { return $latest_core_path; } if ( 'version' === $return && null !== $latest_core_version ) { return $latest_core_version; } $this_core_path = _et_core_normalize_path( dirname( __FILE__ ) ); $content_dir = _et_core_normalize_path( WP_CONTENT_DIR ); // If this constant is enabled, the core path from this product will be used instead of the latest core from all installed products. if ( defined( 'ET_USE_PRODUCT_CORE_PATHS' ) && ET_USE_PRODUCT_CORE_PATHS ) { return $this_core_path; } include $this_core_path . '/_et_core_version.php'; $latest_core_path = $this_core_path; $latest_core_version = $ET_CORE_VERSION; unset( $ET_CORE_VERSION ); $version_files = array_merge( (array) glob( "{$content_dir}/themes/*/core/_et_core_version.php" ), (array) glob( "{$content_dir}/plugins/*/core/_et_core_version.php" ) ); foreach ( $version_files as $version_file ) { $version_file = _et_core_normalize_path( $version_file ); if ( ! is_file( $version_file ) || 0 === strpos( $version_file, $this_core_path ) ) { continue; } include_once $version_file; if ( ! isset( $ET_CORE_VERSION ) ) { continue; } $is_greater_than = version_compare( $ET_CORE_VERSION, $latest_core_version, '>' ); if ( $is_greater_than && _et_core_path_belongs_to_active_product( $version_file ) ) { $latest_core_path = _et_core_normalize_path( dirname( $version_file ) ); $latest_core_version = $ET_CORE_VERSION; } unset( $ET_CORE_VERSION ); } if ( 'version' === $return ) { return $latest_core_version; } return $latest_core_path; } endif; if ( ! function_exists( '_et_core_path_belongs_to_active_product' ) ): /** * @private * @internal */ function _et_core_path_belongs_to_active_product( $path ) { global $wp_customize; include_once ABSPATH . 'wp-admin/includes/plugin.php'; $theme_dir = _et_core_normalize_path( get_template_directory() ); // When previewing a theme the `get_template_directory()` doesn't return the directory of the previewed theme // since this function will be called earlier (before `WP_Customize_Manager` manipulates the active theme) // when loaded from plugins (e.g bloom) if ( is_a( $wp_customize, 'WP_Customize_Manager' ) && ! $wp_customize->is_theme_active() ) { $template = $wp_customize->get_template(); $theme_root = get_theme_root( $template ); $preview_template_directory = apply_filters( 'template_directory', "$theme_root/$template", $template, $theme_root ); $theme_dir = _et_core_normalize_path( $preview_template_directory ); } if ( 0 === strpos( $path, $theme_dir ) ) { return true; } if ( false !== strpos( $path, '/divi-builder/' ) ) { return is_plugin_active( 'divi-builder/divi-builder.php' ); } if ( false !== strpos( $path, '/bloom/' ) ) { return is_plugin_active( 'bloom/bloom.php' ); } if ( false !== strpos( $path, '/monarch/' ) ) { return is_plugin_active( 'monarch/monarch.php' ); } if ( false !== strpos( $path, '/divi-dash/' ) ) { return is_plugin_active( 'divi-dash/divi-dash.php' ); } return false; } endif; if ( ! function_exists( '_et_core_load_latest' ) ): function _et_core_load_latest() { if ( defined( 'ET_CORE_VERSION' ) ) { return; } $core_path = get_transient( 'et_core_path' ); $version_file = $core_path ? file_exists( $core_path . '/_et_core_version.php' ) : false; $have_core_path = $core_path && $version_file && ! defined( 'ET_DEBUG' ); if ( $have_core_path && _et_core_path_belongs_to_active_product( $core_path ) ) { $core_version = get_transient( 'et_core_version' ); $core_path_changed = false; } else { $core_path = _et_core_find_latest(); $core_version = _et_core_find_latest( 'version' ); $core_path_changed = true; } /** * Overrides ET_CORE_PATH right before its loaded. * * @since 3.0.68 * * @param bool|string $core_path_override The absolute path to the core that should be loaded. */ $core_path_override = apply_filters( 'et_core_path_override', false ); if ( $core_path_override ) { $core_path = $core_path_override; } else if ( $core_path_changed ) { set_transient( 'et_core_path', $core_path, DAY_IN_SECONDS ); set_transient( 'et_core_version', $core_version, DAY_IN_SECONDS ); } define( 'ET_CORE_VERSION', $core_version ); require_once $core_path . '/functions.php'; } endif; if ( ! function_exists( '_et_core_normalize_path' ) ): /** * @private * @internal */ function _et_core_normalize_path( $path ) { return $path ? str_replace( '\\', '/', $path ) : ''; } endif; if ( ! function_exists( 'register_portability_for_code_snippets' ) ) : /** * Register portability which is needed to import/export saved Snippet via Divi Library. * * @since 4.19.0 */ function register_portability_for_code_snippets() { if ( ! function_exists( 'et_pb_is_allowed' ) ) { return; } // No permission, can't load library UI in the first place. if ( et_pb_is_allowed( 'divi_library' ) ) { // Register portability. et_core_portability_register( 'et_code_snippets', array( 'name' => esc_html__( 'Divi Code Snippets', 'et_builder' ), ) ); } } add_action( 'admin_init', 'register_portability_for_code_snippets' ); endif; _et_core_load_latest();
| ver. 1.4 |
Github
|
.
| PHP 8.4.10 | Generation time: 0.18 |
proxy
|
phpinfo
|
Settings