From e28172b0ba60768a5169534ab3f49c0d16876ede Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Zi=C3=B3=C5=82kowski?= Date: Wed, 26 Aug 2026 11:48:53 +0000 Subject: [PATCH 001/363] Connectors: Only validate submitted AI provider API keys `_wp_connectors_rest_settings_dispatch()` validated every stored AI provider API key on each `/wp/v2/settings` update, because the response always contains the full set of registered settings. Saving an unrelated setting therefore triggered a live validation request to each configured provider, and a key that failed validation at that moment was silently reset. Validate a key only when it is present in the current request, using `WP_REST_Request::has_param()`. Masking of stored keys in the response is unchanged. Add test coverage for omitted, submitted-invalid, and submitted-valid keys to the existing `Tests_Connectors_WpConnectorsRestSettingsDispatch` suite. Developed in: https://github.com/WordPress/wordpress-develop/pull/12350 Props khokansardar, hbhalodia, gziolo. Fixes #65554. See #65867. git-svn-id: https://develop.svn.wordpress.org/trunk@63348 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/connectors.php | 8 +- .../wpConnectorsRestSettingsDispatch.php | 120 ++++++++++++++++++ 2 files changed, 126 insertions(+), 2 deletions(-) diff --git a/src/wp-includes/connectors.php b/src/wp-includes/connectors.php index 7433203ab7fec..9aed5f1f4d7aa 100644 --- a/src/wp-includes/connectors.php +++ b/src/wp-includes/connectors.php @@ -731,9 +731,13 @@ function _wp_connectors_rest_settings_dispatch( WP_REST_Response $response, WP_R $value = $data[ $setting_name ]; - // On update, validate AI provider keys before masking. + // On update, validate AI provider keys submitted in the request before masking. // Non-AI connectors accept keys as-is; the service plugin handles its own validation. - if ( $is_update && is_string( $value ) && '' !== $value && 'ai_provider' === $connector_data['type'] ) { + if ( $is_update + && $request->has_param( $setting_name ) + && is_string( $value ) && '' !== $value + && 'ai_provider' === $connector_data['type'] + ) { if ( true !== _wp_connectors_is_ai_api_key_valid( $value, $connector_id ) ) { update_option( $setting_name, '' ); $data[ $setting_name ] = ''; diff --git a/tests/phpunit/tests/connectors/wpConnectorsRestSettingsDispatch.php b/tests/phpunit/tests/connectors/wpConnectorsRestSettingsDispatch.php index 7e0aa7ce6b2f1..eb723701731f1 100644 --- a/tests/phpunit/tests/connectors/wpConnectorsRestSettingsDispatch.php +++ b/tests/phpunit/tests/connectors/wpConnectorsRestSettingsDispatch.php @@ -1,4 +1,7 @@ register( self::CONNECTOR_ID, array( @@ -63,4 +87,100 @@ public function test_masks_application_password_but_not_username(): void { $this->assertSame( str_repeat( "\u{2022}", 16 ), $data[ self::CREDENTIALS_SETTING_NAME ]['password'] ); $this->assertNotSame( $application_password, $data[ self::CREDENTIALS_SETTING_NAME ]['password'] ); } + + /** + * Ensures a stored AI provider key is not re-validated, and therefore not reset, + * when it is not part of the current settings update. + * + * The /wp/v2/settings response always carries every registered setting, so the + * response data alone cannot tell which keys the request actually submitted. + * + * @ticket 65554 + */ + public function test_does_not_validate_or_reset_unsubmitted_ai_key(): void { + $stored_key = 'sk-stored-valid-key'; + update_option( self::AI_KEY_SETTING_NAME, $stored_key ); + + // A provider that would fail validation if it were consulted. + self::set_mock_provider_configured( false ); + + // An update that submits an unrelated setting. + $request = new WP_REST_Request( 'POST', '/wp/v2/settings' ); + $request->set_param( 'title', 'New Site Title' ); + $response = new WP_REST_Response( array( self::AI_KEY_SETTING_NAME => $stored_key ) ); + + $result = _wp_connectors_rest_settings_dispatch( $response, rest_get_server(), $request ); + $data = $result->get_data(); + + $this->assertSame( + $stored_key, + get_option( self::AI_KEY_SETTING_NAME ), + 'An AI provider key that was not submitted should not be reset.' + ); + $this->assertSame( + _wp_connectors_mask_api_key( $stored_key ), + $data[ self::AI_KEY_SETTING_NAME ], + 'The stored AI provider key should still be masked in the response.' + ); + } + + /** + * Ensures a submitted AI provider key that fails validation is still discarded. + * + * @ticket 65554 + */ + public function test_discards_submitted_invalid_ai_key(): void { + $submitted_key = 'sk-submitted-invalid-key'; + update_option( self::AI_KEY_SETTING_NAME, $submitted_key ); + + self::set_mock_provider_configured( false ); + + $request = new WP_REST_Request( 'POST', '/wp/v2/settings' ); + $request->set_param( self::AI_KEY_SETTING_NAME, $submitted_key ); + $response = new WP_REST_Response( array( self::AI_KEY_SETTING_NAME => $submitted_key ) ); + + $result = _wp_connectors_rest_settings_dispatch( $response, rest_get_server(), $request ); + $data = $result->get_data(); + + $this->assertSame( + '', + get_option( self::AI_KEY_SETTING_NAME ), + 'A submitted AI provider key that fails validation should be discarded.' + ); + $this->assertSame( + '', + $data[ self::AI_KEY_SETTING_NAME ], + 'The discarded key should be returned as an empty string.' + ); + } + + /** + * Ensures a submitted AI provider key that passes validation is kept and masked. + * + * @ticket 65554 + */ + public function test_keeps_and_masks_submitted_valid_ai_key(): void { + $submitted_key = 'sk-submitted-valid-key'; + update_option( self::AI_KEY_SETTING_NAME, $submitted_key ); + + self::set_mock_provider_configured( true ); + + $request = new WP_REST_Request( 'POST', '/wp/v2/settings' ); + $request->set_param( self::AI_KEY_SETTING_NAME, $submitted_key ); + $response = new WP_REST_Response( array( self::AI_KEY_SETTING_NAME => $submitted_key ) ); + + $result = _wp_connectors_rest_settings_dispatch( $response, rest_get_server(), $request ); + $data = $result->get_data(); + + $this->assertSame( + $submitted_key, + get_option( self::AI_KEY_SETTING_NAME ), + 'A submitted AI provider key that passes validation should be kept.' + ); + $this->assertSame( + _wp_connectors_mask_api_key( $submitted_key ), + $data[ self::AI_KEY_SETTING_NAME ], + 'The submitted AI provider key should be masked in the response.' + ); + } } From c86236167975d2857bc655eec46813b0a55cfa42 Mon Sep 17 00:00:00 2001 From: Nik Tsekouras Date: Wed, 26 Aug 2026 13:29:04 +0000 Subject: [PATCH 002/363] Editor: Append the post slug to single post template titles when posts share the same title. When a template is created for a specific post or page, `_wp_build_title_and_description_for_single_post_type_block_template()` is supposed to append the post slug to the computed template title when more posts share the same title, so the templates can be distinguished in the Site Editor. However, the query checking for posts with the same title inherited `posts_per_page => 1` from the default arguments, so it could never return more than one post and the check never matched. This has been the case since the function was introduced in WordPress 6.1. The query now fetches up to two posts, matching the `number => 2` argument already used by the taxonomy variant. Props ntsekouras, mamaduka, jameskoster. Fixes #65966. git-svn-id: https://develop.svn.wordpress.org/trunk@63349 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/block-template-utils.php | 3 +- .../buildBlockTemplateResultFromPost.php | 185 ++++++++++++++++++ 2 files changed, 187 insertions(+), 1 deletion(-) diff --git a/src/wp-includes/block-template-utils.php b/src/wp-includes/block-template-utils.php index 2d23f8545e87f..d17aa174398e3 100644 --- a/src/wp-includes/block-template-utils.php +++ b/src/wp-includes/block-template-utils.php @@ -729,7 +729,8 @@ function _wp_build_title_and_description_for_single_post_type_block_template( $p ); $args = array( - 'title' => $post_title, + 'title' => $post_title, + 'posts_per_page' => 2, ); $args = wp_parse_args( $args, $default_args ); diff --git a/tests/phpunit/tests/block-templates/buildBlockTemplateResultFromPost.php b/tests/phpunit/tests/block-templates/buildBlockTemplateResultFromPost.php index 5dbf91d911f07..05bd88bcd24dd 100644 --- a/tests/phpunit/tests/block-templates/buildBlockTemplateResultFromPost.php +++ b/tests/phpunit/tests/block-templates/buildBlockTemplateResultFromPost.php @@ -176,6 +176,191 @@ public function test_should_not_inject_ignored_hooked_block_into_template() { $this->assertStringNotContainsString( '', $template->content ); } + /** + * @ticket 65966 + */ + public function test_should_append_post_slug_to_title_when_posts_share_the_same_title() { + self::factory()->post->create( + array( + 'post_title' => 'Same Title', + 'post_name' => 'first-post', + ) + ); + self::factory()->post->create( + array( + 'post_title' => 'Same Title', + 'post_name' => 'second-post', + ) + ); + + $first_template_post = self::factory()->post->create_and_get( + array( + 'post_type' => 'wp_template', + 'post_name' => 'single-post-first-post', + 'post_title' => 'single-post-first-post', + 'post_content' => 'Content', + 'post_excerpt' => '', + 'tax_input' => array( + 'wp_theme' => array( + self::TEST_THEME, + ), + ), + ) + ); + wp_set_post_terms( $first_template_post->ID, self::TEST_THEME, 'wp_theme' ); + + $second_template_post = self::factory()->post->create_and_get( + array( + 'post_type' => 'wp_template', + 'post_name' => 'single-post-second-post', + 'post_title' => 'single-post-second-post', + 'post_content' => 'Content', + 'post_excerpt' => '', + 'tax_input' => array( + 'wp_theme' => array( + self::TEST_THEME, + ), + ), + ) + ); + wp_set_post_terms( $second_template_post->ID, self::TEST_THEME, 'wp_theme' ); + + $first_template = _build_block_template_result_from_post( $first_template_post ); + $second_template = _build_block_template_result_from_post( $second_template_post ); + + $this->assertNotWPError( $first_template, 'Building the template for the first post should not return an error.' ); + $this->assertSame( 'Post: Same Title (first-post)', $first_template->title, 'The title of the first post template should be suffixed with the post slug.' ); + $this->assertNotWPError( $second_template, 'Building the template for the second post should not return an error.' ); + $this->assertSame( 'Post: Same Title (second-post)', $second_template->title, 'The title of the second post template should be suffixed with the post slug.' ); + } + + /** + * @ticket 65966 + */ + public function test_should_not_append_post_slug_to_title_when_post_title_is_unique() { + self::factory()->post->create( + array( + 'post_title' => 'Unique Title', + 'post_name' => 'unique-post', + ) + ); + + $template_post = self::factory()->post->create_and_get( + array( + 'post_type' => 'wp_template', + 'post_name' => 'single-post-unique-post', + 'post_title' => 'single-post-unique-post', + 'post_content' => 'Content', + 'post_excerpt' => '', + 'tax_input' => array( + 'wp_theme' => array( + self::TEST_THEME, + ), + ), + ) + ); + wp_set_post_terms( $template_post->ID, self::TEST_THEME, 'wp_theme' ); + + $template = _build_block_template_result_from_post( $template_post ); + + $this->assertNotWPError( $template, 'Building the template should not return an error.' ); + $this->assertSame( 'Post: Unique Title', $template->title, 'The template title should not be suffixed with the post slug when the post title is unique.' ); + } + + /** + * @ticket 65966 + */ + public function test_should_append_term_slug_to_title_when_terms_share_the_same_name() { + self::factory()->term->create( + array( + 'taxonomy' => 'post_tag', + 'name' => 'Same Name', + 'slug' => 'first-tag', + ) + ); + self::factory()->term->create( + array( + 'taxonomy' => 'post_tag', + 'name' => 'Same Name', + 'slug' => 'second-tag', + ) + ); + + $first_template_post = self::factory()->post->create_and_get( + array( + 'post_type' => 'wp_template', + 'post_name' => 'tag-first-tag', + 'post_title' => 'tag-first-tag', + 'post_content' => 'Content', + 'post_excerpt' => '', + 'tax_input' => array( + 'wp_theme' => array( + self::TEST_THEME, + ), + ), + ) + ); + wp_set_post_terms( $first_template_post->ID, self::TEST_THEME, 'wp_theme' ); + + $second_template_post = self::factory()->post->create_and_get( + array( + 'post_type' => 'wp_template', + 'post_name' => 'tag-second-tag', + 'post_title' => 'tag-second-tag', + 'post_content' => 'Content', + 'post_excerpt' => '', + 'tax_input' => array( + 'wp_theme' => array( + self::TEST_THEME, + ), + ), + ) + ); + wp_set_post_terms( $second_template_post->ID, self::TEST_THEME, 'wp_theme' ); + + $first_template = _build_block_template_result_from_post( $first_template_post ); + $second_template = _build_block_template_result_from_post( $second_template_post ); + + $this->assertNotWPError( $first_template, 'Building the template for the first term should not return an error.' ); + $this->assertSame( 'Tag: Same Name (first-tag)', $first_template->title, 'The title of the first term template should be suffixed with the term slug.' ); + $this->assertNotWPError( $second_template, 'Building the template for the second term should not return an error.' ); + $this->assertSame( 'Tag: Same Name (second-tag)', $second_template->title, 'The title of the second term template should be suffixed with the term slug.' ); + } + + /** + * @ticket 65966 + */ + public function test_should_not_append_term_slug_to_title_when_term_name_is_unique() { + self::factory()->term->create( + array( + 'taxonomy' => 'category', + 'name' => 'Unique Category', + 'slug' => 'unique-category', + ) + ); + + $template_post = self::factory()->post->create_and_get( + array( + 'post_type' => 'wp_template', + 'post_name' => 'category-unique-category', + 'post_title' => 'category-unique-category', + 'post_content' => 'Content', + 'post_excerpt' => '', + 'tax_input' => array( + 'wp_theme' => array( + self::TEST_THEME, + ), + ), + ) + ); + wp_set_post_terms( $template_post->ID, self::TEST_THEME, 'wp_theme' ); + + $template = _build_block_template_result_from_post( $template_post ); + + $this->assertNotWPError( $template, 'Building the template should not return an error.' ); + $this->assertSame( 'Category: Unique Category', $template->title, 'The template title should not be suffixed with the term slug when the term name is unique.' ); + } + /** * @ticket 59646 * @ticket 60506 From 75683ef645d2216f5731b571fd153343833be5bb Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Wed, 26 Aug 2026 14:59:03 +0000 Subject: [PATCH 003/363] Code Modernization: Replace `socket_set_timeout()` usage in Snoopy library. `socket_set_timeout()` is an alias of `stream_set_timeout()`, and is deprecated in PHP 8.5. Includes removing unnecessary `unset( $postdata )` call before `$postdata` is assigned. Reference: [https://wiki.php.net/rfc/deprecations_php_8_5#formally_deprecate_socket_set_timeout PHP RFC: Deprecations for PHP 8.5: Formally deprecate socket_set_timeout]. Developed in https://github.com/WordPress/wordpress-develop/pull/13276. Props arshidkv12. Fixes #65965. git-svn-id: https://develop.svn.wordpress.org/trunk@63350 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-snoopy.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/wp-includes/class-snoopy.php b/src/wp-includes/class-snoopy.php index e82c673989463..73edcd822a5fa 100644 --- a/src/wp-includes/class-snoopy.php +++ b/src/wp-includes/class-snoopy.php @@ -278,8 +278,6 @@ function fetch($URI) function submit($URI, $formvars="", $formfiles="") { - unset($postdata); - $postdata = $this->_prepare_post_body($formvars, $formfiles); $URI_PARTS = parse_url($URI); @@ -844,7 +842,7 @@ function _httprequest($url,$fp,$URI,$http_method,$content_type="",$body="") // set the read timeout if needed if ($this->read_timeout > 0) - socket_set_timeout($fp, $this->read_timeout); + stream_set_timeout($fp, $this->read_timeout); $this->timed_out = false; fwrite($fp,$headers.$body,strlen($headers.$body)); From 558d0ff66d803d917f06ca49c68ad40432d56358 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Wed, 26 Aug 2026 21:44:34 +0000 Subject: [PATCH 004/363] Code Quality: Resolve the `isset.variable` PHPStan errors. Each of the six baselined errors was an `isset()` on a variable that is always defined and not nullable, or never defined at all. The `$_POST` superglobal is always set, so the checks on it in `Custom_Image_Header::step_2()` and `get_media_item()` were unconditional; the latter becomes `! empty( $_POST )`, which is what `isset()` plus `count()` already meant. `PHP_VERSION_ID` is constant within a request, so the guard above the `$loader` check in `WP_oEmbed::_parse_xml()` already decides it. The `namespace` group in `WP_Block_Parser::next_token()` is a non-trailing optional group under `PREG_OFFSET_CAPTURE`, which PHP always populates. In `wp_edit_theme_plugin_file()` the only assignment to `$stylesheet` is guarded by a `! empty()` on the argument it comes from, so a truthiness test cannot diverge from `isset()`. The remaining error is the reverse case: `$s` in `load_template()` is undefined to static analysis because it arrives through `extract()`. Assigning the query vars to a local first, and annotating that local as `array{ s?: scalar, ... }`, resolves both that report and the inline `@phpstan-ignore` above it. The annotation is deliberately local rather than on `WP_Query::$query_vars`, where an unsealed shape makes every unnamed key "might not exist" and reports more than it resolves. `scalar` rather than `string` is what `WP_Query::parse_query()` actually guarantees, since it gates the value only with `is_scalar()`. With the last entry fixed, the baseline file and its entry in the `includes` of `phpstan.neon.dist` are removed. Developed in https://github.com/WordPress/wordpress-develop/pull/13023. Follow-up to r28407, r32298, r41721, r48789, r60351, r61504, r61699, r63019. Props westonruter, apermo. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63351 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 1 - .../includes/class-custom-image-header.php | 2 +- src/wp-admin/includes/file.php | 9 ++-- src/wp-admin/includes/media.php | 2 +- src/wp-includes/class-wp-block-parser.php | 2 +- src/wp-includes/class-wp-oembed.php | 3 +- src/wp-includes/template.php | 8 +-- tests/phpstan/baselines/isset.variable.neon | 50 ------------------- 8 files changed, 15 insertions(+), 62 deletions(-) delete mode 100644 tests/phpstan/baselines/isset.variable.neon diff --git a/phpstan.neon.dist b/phpstan.neon.dist index bb806bc4a4b95..3e4b36f256d96 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -55,7 +55,6 @@ includes: - tests/phpstan/baselines/instanceof.alwaysTrue.neon - tests/phpstan/baselines/isset.offset.neon - tests/phpstan/baselines/isset.property.neon - - tests/phpstan/baselines/isset.variable.neon - tests/phpstan/baselines/method.childParameterType.neon - tests/phpstan/baselines/method.nonObject.neon - tests/phpstan/baselines/method.notFound.neon diff --git a/src/wp-admin/includes/class-custom-image-header.php b/src/wp-admin/includes/class-custom-image-header.php index 97a1a16052d12..c1816ffae2d9c 100644 --- a/src/wp-admin/includes/class-custom-image-header.php +++ b/src/wp-admin/includes/class-custom-image-header.php @@ -841,7 +841,7 @@ public function step_2() { $file = get_attached_file( $attachment_id, true ); $url = wp_get_attachment_image_src( $attachment_id, 'full' ); $url = $url[0]; - } elseif ( isset( $_POST ) ) { + } else { $data = $this->step_2_manage_upload(); $attachment_id = $data['attachment_id']; $file = $data['file']; diff --git a/src/wp-admin/includes/file.php b/src/wp-admin/includes/file.php index 8c0015020f35d..99b9735011bbc 100644 --- a/src/wp-admin/includes/file.php +++ b/src/wp-admin/includes/file.php @@ -397,9 +397,10 @@ function wp_edit_theme_plugin_file( $args ) { $file = $args['file']; $content = $args['newcontent']; - $plugin = null; - $theme = null; - $real_file = null; + $plugin = null; + $stylesheet = null; + $theme = null; + $real_file = null; if ( ! empty( $args['plugin'] ) ) { $plugin = $args['plugin']; @@ -560,7 +561,7 @@ function wp_edit_theme_plugin_file( $args ) { // Attempt loopback request to editor to see if user just whitescreened themselves. if ( $plugin ) { $url = add_query_arg( compact( 'plugin', 'file' ), admin_url( 'plugin-editor.php' ) ); - } elseif ( isset( $stylesheet ) ) { + } elseif ( $stylesheet ) { $url = add_query_arg( array( 'theme' => $stylesheet, diff --git a/src/wp-admin/includes/media.php b/src/wp-admin/includes/media.php index 35a34acb7e517..99281712f66cf 100644 --- a/src/wp-admin/includes/media.php +++ b/src/wp-admin/includes/media.php @@ -1773,7 +1773,7 @@ function get_media_item( $attachment_id, $args = null ) { if ( isset( $_GET['post_id'] ) ) { $calling_post_id = absint( $_GET['post_id'] ); - } elseif ( isset( $_POST ) && count( $_POST ) ) {// Like for async-upload where $_GET['post_id'] isn't set. + } elseif ( ! empty( $_POST ) ) { // Like for async-upload where $_GET['post_id'] isn't set. $calling_post_id = $post->post_parent; } diff --git a/src/wp-includes/class-wp-block-parser.php b/src/wp-includes/class-wp-block-parser.php index ea66e3b51d38d..81cb7a8fa21f7 100644 --- a/src/wp-includes/class-wp-block-parser.php +++ b/src/wp-includes/class-wp-block-parser.php @@ -268,7 +268,7 @@ public function next_token() { $is_closer = isset( $matches['closer'] ) && -1 !== $matches['closer'][1]; $is_void = isset( $matches['void'] ) && -1 !== $matches['void'][1]; $namespace = $matches['namespace']; - $namespace = ( isset( $namespace ) && -1 !== $namespace[1] ) ? $namespace[0] : 'core/'; + $namespace = ( -1 !== $namespace[1] ) ? $namespace[0] : 'core/'; $name = $namespace . $matches['name'][0]; $has_attrs = isset( $matches['attrs'] ) && -1 !== $matches['attrs'][1]; diff --git a/src/wp-includes/class-wp-oembed.php b/src/wp-includes/class-wp-oembed.php index 39029bd9a2b8d..b1a23ff66144d 100644 --- a/src/wp-includes/class-wp-oembed.php +++ b/src/wp-includes/class-wp-oembed.php @@ -674,6 +674,7 @@ private function _parse_xml( $response_body ) { return false; } + $loader = null; if ( PHP_VERSION_ID < 80000 ) { /* * This function has been deprecated in PHP 8.0 because in libxml 2.9.0, external entity loading @@ -688,7 +689,7 @@ private function _parse_xml( $response_body ) { libxml_use_internal_errors( $errors ); - if ( PHP_VERSION_ID < 80000 && isset( $loader ) ) { + if ( PHP_VERSION_ID < 80000 ) { // phpcs:ignore PHPCompatibility.FunctionUse.RemovedFunctions.libxml_disable_entity_loaderDeprecated libxml_disable_entity_loader( $loader ); } diff --git a/src/wp-includes/template.php b/src/wp-includes/template.php index 6ec1934f866ec..d2b74e188c095 100644 --- a/src/wp-includes/template.php +++ b/src/wp-includes/template.php @@ -782,7 +782,9 @@ function locate_template( $template_names, $load = false, $load_once = true, $ar function load_template( $_template_file, $load_once = true, $args = array() ) { global $posts, $post, $wp_did_header, $wp_query, $wp_rewrite, $wpdb, $wp_version, $wp, $id, $comment, $user_ID; - if ( is_array( $wp_query->query_vars ) ) { + /** @var array{ s?: scalar, ... } $query_vars */ + $query_vars = $wp_query->query_vars; + if ( is_array( $query_vars ) ) { /* * This use of extract() cannot be removed. There are many possible ways that * templates could depend on variables that it creates existing, and no way to @@ -792,11 +794,11 @@ function load_template( $_template_file, $load_once = true, $args = array() ) { * function variables cannot be overwritten. */ // phpcs:ignore WordPress.PHP.DontExtract.extract_extract - extract( $wp_query->query_vars, EXTR_SKIP ); + extract( $query_vars, EXTR_SKIP ); } if ( isset( $s ) ) { - $s = esc_attr( $s ); // @phpstan-ignore variable.undefined (It's extracted from query vars.) + $s = esc_attr( (string) $s ); } /** diff --git a/tests/phpstan/baselines/isset.variable.neon b/tests/phpstan/baselines/isset.variable.neon deleted file mode 100644 index f14ef0755fdb9..0000000000000 --- a/tests/phpstan/baselines/isset.variable.neon +++ /dev/null @@ -1,50 +0,0 @@ -# PHPStan baseline for the `isset.variable` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/isset.variable -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=isset.variable -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^Variable \$_POST in isset\(\) always exists and is not nullable\.$#' - identifier: isset.variable - count: 1 - path: ../../../src/wp-admin/includes/class-custom-image-header.php - - - message: '#^Variable \$stylesheet in isset\(\) always exists and is not nullable\.$#' - identifier: isset.variable - count: 1 - path: ../../../src/wp-admin/includes/file.php - - - message: '#^Variable \$_POST in isset\(\) always exists and is not nullable\.$#' - identifier: isset.variable - count: 1 - path: ../../../src/wp-admin/includes/media.php - - - message: '#^Variable \$namespace in isset\(\) always exists and is not nullable\.$#' - identifier: isset.variable - count: 1 - path: ../../../src/wp-includes/class-wp-block-parser.php - - - message: '#^Variable \$loader in isset\(\) always exists and is not nullable\.$#' - identifier: isset.variable - count: 1 - path: ../../../src/wp-includes/class-wp-oembed.php - - - message: '#^Variable \$s in isset\(\) is never defined\.$#' - identifier: isset.variable - count: 1 - path: ../../../src/wp-includes/template.php From f8d305313c90975c8eaa7ee06fb6a5a144ca9ca9 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Wed, 26 Aug 2026 21:51:59 +0000 Subject: [PATCH 005/363] Customize: Emit valid `aria-pressed` on device buttons. The responsive preview buttons in the Customizer rendered `aria-pressed` by passing a bool through `esc_attr()`, which PHP casts to `1` for the default device and to an empty string for the other two. Neither is valid for a tristate attribute whose only accepted values are `true`, `false`, `mixed`, and `undefined`, and an invalid value is treated as `undefined`, so on initial render none of the three buttons was exposed as a toggle button at all. Emitting the literals directly makes the server render agree with the `true`/`false` strings that `customize-controls.js` already writes on the first interaction, matching the existing pattern for `aria-expanded` in `wp-admin/includes/template.php`. The Site Icon button on the general settings screen relied on the same cast to produce the `1` and empty-string sentinels that `site-icon.js` compares against and writes back. That value was already correct; it is now written out explicitly so the contract is stated rather than resting on PHP's cast rules. With both call sites resolved, no `esc_*()` entries remain in the `argument.type` PHPStan baseline. Developed in https://github.com/WordPress/wordpress-develop/pull/13046. Follow-up to r36532, r57602, r63296. Props westonruter, afercia. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63352 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/customize.php | 2 +- src/wp-admin/options-general.php | 2 +- tests/phpstan/baselines/argument.type.neon | 10 ---------- 3 files changed, 2 insertions(+), 12 deletions(-) diff --git a/src/wp-admin/customize.php b/src/wp-admin/customize.php index 6496c824c9b10..75c0865b1f8eb 100644 --- a/src/wp-admin/customize.php +++ b/src/wp-admin/customize.php @@ -288,7 +288,7 @@ $class .= ' active'; } ?> - diff --git a/src/wp-admin/options-general.php b/src/wp-admin/options-general.php index 6a9a6d2f3812d..c1efa0c063c58 100644 --- a/src/wp-admin/options-general.php +++ b/src/wp-admin/options-general.php @@ -190,7 +190,7 @@ class="" data-choose-text="" data-update-text="" data-update="" - data-state="" + data-state="" > diff --git a/tests/phpstan/baselines/argument.type.neon b/tests/phpstan/baselines/argument.type.neon index da71134bcaf34..745a79986da89 100644 --- a/tests/phpstan/baselines/argument.type.neon +++ b/tests/phpstan/baselines/argument.type.neon @@ -43,11 +43,6 @@ parameters: identifier: argument.type count: 2 path: ../../../src/wp-admin/comment.php - - - message: '#^Parameter \#1 \$text of function esc_attr expects float\|int\|string, bool given\.$#' - identifier: argument.type - count: 1 - path: ../../../src/wp-admin/customize.php - message: '#^Parameter \#1 \$position of function wp_comment_reply expects int, string given\.$#' identifier: argument.type @@ -448,11 +443,6 @@ parameters: identifier: argument.type count: 1 path: ../../../src/wp-admin/network/site-users.php - - - message: '#^Parameter \#1 \$text of function esc_attr expects float\|int\|string, bool given\.$#' - identifier: argument.type - count: 1 - path: ../../../src/wp-admin/options-general.php - message: '#^Parameter \#2 \$callback of function array_filter expects \(callable\(mixed\)\: bool\)\|null, ''validate_file'' given\.$#' identifier: argument.type From 6655f47ee1ed6479050b23423a61430f28c5d22f Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Wed, 26 Aug 2026 22:02:22 +0000 Subject: [PATCH 006/363] Code Quality: Remove empty `greater.invalid` PHPStan baseline file. Follow-up to r63344. Props nathanrice. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63353 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpstan/baselines/greater.invalid.neon | 0 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 tests/phpstan/baselines/greater.invalid.neon diff --git a/tests/phpstan/baselines/greater.invalid.neon b/tests/phpstan/baselines/greater.invalid.neon deleted file mode 100644 index e69de29bb2d1d..0000000000000 From cc80c3a34d006422d5a0d182b8ac3d5396a23428 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Wed, 26 Aug 2026 22:20:49 +0000 Subject: [PATCH 007/363] Cache API: Treat an unusable cached value as a miss. `WP_Site::get_instance()` treated only `false` as a cache miss, but `wp_cache_get()` can return whatever a persistent object cache holds under that key. A cached string or array therefore skipped the refetch and reached the constructor, where `get_object_vars()` raised a `TypeError`. The same lookup is repeated in `WP_Network::get_instance()`, `WP_Post::get_instance()`, `WP_Comment::get_instance()` and `WP_Term::get_instance()`; networks and terms carried the identical fatal. All five now refetch unless the cached value is an object carrying the property that identifies it. That also closes a quieter bug in the same code: an object missing that property was accepted as a cache hit, so posts came back with an `ID` of `0`, comments with a null `comment_ID`, and terms as an entirely different term. Sites and networks keep their `-1` sentinel recording a lookup that previously found nothing. The refetched row is now stored with `wp_cache_set()` rather than `wp_cache_add()`. Widening the guard makes the branch reachable while an entry is still present, and `add()` does not overwrite, so the unusable value survived and every later lookup for that object queried the database again. Developed in https://github.com/WordPress/wordpress-develop/pull/13270. Follow-up to r33891, r35537, r45910, r62648. Props josephscott, westonruter. Fixes #65962. git-svn-id: https://develop.svn.wordpress.org/trunk@63354 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-comment.php | 7 +- src/wp-includes/class-wp-network.php | 11 +- src/wp-includes/class-wp-post.php | 8 +- src/wp-includes/class-wp-site.php | 11 +- src/wp-includes/class-wp-term.php | 15 +- tests/phpunit/tests/comment/wpComment.php | 74 +++++- tests/phpunit/tests/multisite/network.php | 69 ++++- tests/phpunit/tests/multisite/wpSite.php | 310 ++++++++++++++++++++++ tests/phpunit/tests/post/wpPost.php | 74 +++++- tests/phpunit/tests/term/wpTerm.php | 100 ++++++- 10 files changed, 664 insertions(+), 15 deletions(-) create mode 100644 tests/phpunit/tests/multisite/wpSite.php diff --git a/src/wp-includes/class-wp-comment.php b/src/wp-includes/class-wp-comment.php index f6b4d8d75f5e3..f14fac6614901 100644 --- a/src/wp-includes/class-wp-comment.php +++ b/src/wp-includes/class-wp-comment.php @@ -246,6 +246,7 @@ final class WP_Comment { * Retrieves a WP_Comment instance. * * @since 4.4.0 + * @since 7.2.0 Cache values that are not usable as a comment object are now treated as a cache miss and replaced. * * @global wpdb $wpdb WordPress database abstraction object. * @@ -263,7 +264,8 @@ public static function get_instance( $id ) { $_comment = wp_cache_get( $comment_id, 'comment' ); - if ( ! is_object( $_comment ) ) { + // A cached value that is not usable as a comment is treated as a cache miss. + if ( ! is_object( $_comment ) || ! isset( $_comment->comment_ID ) ) { /** @var object{ comment_ID: string, comment_post_ID: string, comment_author: string, comment_author_email: string, comment_author_url: string, comment_author_IP: string, comment_date: string, comment_date_gmt: string, comment_content: string, comment_karma: string, comment_approved: string, comment_agent: string, comment_type: string, comment_parent: string, user_id: string }|null $_comment */ $_comment = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $wpdb->comments WHERE comment_ID = %d LIMIT 1", $comment_id ) ); @@ -271,7 +273,8 @@ public static function get_instance( $id ) { return false; } - wp_cache_add( $_comment->comment_ID, $_comment, 'comment' ); + // Not wp_cache_add(), since an unusable cached value may still be present and must be replaced. + wp_cache_set( $_comment->comment_ID, $_comment, 'comment' ); } return new WP_Comment( $_comment ); diff --git a/src/wp-includes/class-wp-network.php b/src/wp-includes/class-wp-network.php index 23056cd5a80f5..b9f6b01f2938a 100644 --- a/src/wp-includes/class-wp-network.php +++ b/src/wp-includes/class-wp-network.php @@ -90,6 +90,7 @@ class WP_Network { * Retrieves a network from the database by its ID. * * @since 4.4.0 + * @since 7.2.0 Cache values that are neither a network object nor the -1 miss sentinel are now treated as a cache miss and replaced. * * @global wpdb $wpdb WordPress database abstraction object. * @@ -106,14 +107,20 @@ public static function get_instance( $network_id ) { $_network = wp_cache_get( $network_id, 'networks' ); - if ( false === $_network ) { + // A cached -1 records a previous lookup that found nothing. Any other non-numeric value that is not a network object is treated as a cache miss. + if ( + ( ! is_object( $_network ) || ! isset( $_network->id ) ) + && + ! is_numeric( $_network ) + ) { $_network = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM {$wpdb->site} WHERE id = %d LIMIT 1", $network_id ) ); if ( empty( $_network ) || is_wp_error( $_network ) ) { $_network = -1; } - wp_cache_add( $network_id, $_network, 'networks' ); + // Not wp_cache_add(), since an unusable cached value may still be present and must be replaced. + wp_cache_set( $network_id, $_network, 'networks' ); } if ( is_numeric( $_network ) ) { diff --git a/src/wp-includes/class-wp-post.php b/src/wp-includes/class-wp-post.php index 5531c1301ce3c..4008c6bc12880 100644 --- a/src/wp-includes/class-wp-post.php +++ b/src/wp-includes/class-wp-post.php @@ -267,6 +267,7 @@ final class WP_Post { * Retrieve WP_Post instance. * * @since 3.5.0 + * @since 7.2.0 Cache values that are not usable as a post object are now treated as a cache miss and replaced. * * @global wpdb $wpdb WordPress database abstraction object. * @@ -285,7 +286,8 @@ public static function get_instance( $post_id ) { $_post = wp_cache_get( $post_id, 'posts' ); - if ( ! ( $_post instanceof stdClass ) && ! ( $_post instanceof WP_Post ) ) { + // A cached value that is not usable as a post is treated as a cache miss. + if ( ! ( $_post instanceof stdClass || $_post instanceof WP_Post ) || ! isset( $_post->ID ) ) { $_post = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $wpdb->posts WHERE ID = %d LIMIT 1", $post_id ) ); if ( ! $_post ) { @@ -293,7 +295,9 @@ public static function get_instance( $post_id ) { } $_post = sanitize_post( $_post, 'raw' ); - wp_cache_add( (int) $_post->ID, $_post, 'posts' ); + + // Not wp_cache_add(), since an unusable cached value may still be present and must be replaced. + wp_cache_set( (int) $_post->ID, $_post, 'posts' ); } elseif ( empty( $_post->filter ) || 'raw' !== $_post->filter ) { $_post = sanitize_post( $_post, 'raw' ); } diff --git a/src/wp-includes/class-wp-site.php b/src/wp-includes/class-wp-site.php index ce7bc411518e1..bb6c2d50a3428 100644 --- a/src/wp-includes/class-wp-site.php +++ b/src/wp-includes/class-wp-site.php @@ -159,6 +159,7 @@ final class WP_Site { * Retrieves a site from the database by its ID. * * @since 4.5.0 + * @since 7.2.0 Cache values that are neither a site object nor the -1 miss sentinel are now treated as a cache miss and replaced. * * @global wpdb $wpdb WordPress database abstraction object. * @@ -175,14 +176,20 @@ public static function get_instance( $site_id ) { $_site = wp_cache_get( $site_id, 'sites' ); - if ( false === $_site ) { + // A cached -1 records a previous lookup that found nothing. Any other non-numeric value that is not a site object is treated as a cache miss. + if ( + ( ! is_object( $_site ) || ! isset( $_site->blog_id ) ) + && + ! is_numeric( $_site ) + ) { $_site = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM {$wpdb->blogs} WHERE blog_id = %d LIMIT 1", $site_id ) ); if ( empty( $_site ) || is_wp_error( $_site ) ) { $_site = -1; } - wp_cache_add( $site_id, $_site, 'sites' ); + // Not wp_cache_add(), since an unusable cached value may still be present and must be replaced. + wp_cache_set( $site_id, $_site, 'sites' ); } if ( is_numeric( $_site ) ) { diff --git a/src/wp-includes/class-wp-term.php b/src/wp-includes/class-wp-term.php index 0cefa3097b393..33547e4cbef98 100644 --- a/src/wp-includes/class-wp-term.php +++ b/src/wp-includes/class-wp-term.php @@ -103,6 +103,7 @@ final class WP_Term { * Retrieve WP_Term instance. * * @since 4.4.0 + * @since 7.2.0 Cache values that are not usable as a term object are now treated as a cache miss and replaced. * * @global wpdb $wpdb WordPress database abstraction object. * @@ -123,8 +124,15 @@ public static function get_instance( $term_id, $taxonomy = null ) { $_term = wp_cache_get( $term_id, 'terms' ); - // If there isn't a cached version, hit the database. - if ( ! $_term || ( $taxonomy && $taxonomy !== $_term->taxonomy ) ) { + /* + * If there isn't a usable cached version, hit the database. A cached value that is + * not a term object, or that belongs to another taxonomy, is treated as a cache miss. + */ + if ( + ! is_object( $_term ) + || ! isset( $_term->term_id, $_term->taxonomy ) + || ( $taxonomy && $taxonomy !== $_term->taxonomy ) + ) { // Any term found in the cache is not a match, so don't use it. $_term = false; @@ -177,7 +185,8 @@ public static function get_instance( $term_id, $taxonomy = null ) { // Don't cache terms that are shared between taxonomies. if ( 1 === count( $terms ) ) { - wp_cache_add( $term_id, $_term, 'terms' ); + // Not wp_cache_add(), since an unusable cached value may still be present and must be replaced. + wp_cache_set( $term_id, $_term, 'terms' ); } } diff --git a/tests/phpunit/tests/comment/wpComment.php b/tests/phpunit/tests/comment/wpComment.php index 1f8688d3aeaf9..7361b18346419 100644 --- a/tests/phpunit/tests/comment/wpComment.php +++ b/tests/phpunit/tests/comment/wpComment.php @@ -6,7 +6,7 @@ * @covers WP_Comment::get_instance */ class Tests_Comment_WpComment extends WP_UnitTestCase { - protected static $comment_id; + protected static int $comment_id; public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { global $wpdb; @@ -63,6 +63,78 @@ public function test_get_instance_should_succeed_for_float_that_is_equal_to_post $this->assertSame( '1', $found->comment_ID ); } + /** + * Tests that a cached value which cannot be used as a comment is treated as a cache miss. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss( $cache_value ): void { + wp_cache_set( self::$comment_id, $cache_value, 'comment' ); + + $num_queries = get_num_queries(); + + $comment = WP_Comment::get_instance( self::$comment_id ); + + $this->assertInstanceOf( WP_Comment::class, $comment, 'A comment object was not returned.' ); + $this->assertSame( (string) self::$comment_id, $comment->comment_ID, 'The wrong comment was returned.' ); + $this->assertSame( $num_queries + 1, get_num_queries(), 'The comment was not fetched from the database.' ); + } + + /** + * Tests that the refetched comment replaces the poisoned cache value. + * + * Otherwise the poisoned value survives and every subsequent lookup queries the database again. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_replaces_a_poisoned_cache_value( $cache_value ): void { + wp_cache_set( self::$comment_id, $cache_value, 'comment' ); + + // Prime the object cache, replacing the poisoned value. + WP_Comment::get_instance( self::$comment_id ); + + $num_queries = get_num_queries(); + + $comment = WP_Comment::get_instance( self::$comment_id ); + + $this->assertInstanceOf( WP_Comment::class, $comment, 'A comment object was not returned.' ); + $this->assertSame( (string) self::$comment_id, $comment->comment_ID, 'The wrong comment was returned.' ); + $this->assertSame( $num_queries, get_num_queries(), 'The database was queried again.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss(): array { + return array( + 'true' => array( true ), + 'a non-numeric string' => array( 'not-a-comment' ), + 'an empty array' => array( array() ), + 'an array of comment data' => array( + array( + 'comment_ID' => '1', + 'comment_content' => 'Hello world.', + ), + ), + 'an object without comment_ID' => array( + (object) array( + 'comment_content' => 'Hello world.', + ), + ), + 'a WP_Comment without comment_ID' => array( new WP_Comment( new stdClass() ) ), + ); + } + /** * @ticket 64898 * diff --git a/tests/phpunit/tests/multisite/network.php b/tests/phpunit/tests/multisite/network.php index a5741e91f93f7..17fcbfaa49fd3 100644 --- a/tests/phpunit/tests/multisite/network.php +++ b/tests/phpunit/tests/multisite/network.php @@ -11,7 +11,7 @@ class Tests_Multisite_Network extends WP_UnitTestCase { protected $plugin_hook_count = 0; - protected static $different_network_id; + protected static int $different_network_id; protected static $different_site_ids = array(); public function tear_down() { @@ -683,6 +683,73 @@ public function test_get_network_not_found_cache_clear() { $this->assertSame( $new_network_id, $fetched_network->id ); } + /** + * Tests that a cached value which is neither a network object nor the miss sentinel is treated as a cache miss. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss( $cache_value ): void { + wp_cache_set( self::$different_network_id, $cache_value, 'networks' ); + + $network = WP_Network::get_instance( self::$different_network_id ); + + $this->assertInstanceOf( WP_Network::class, $network, 'A network object was not returned.' ); + $this->assertSame( self::$different_network_id, $network->id, 'The wrong network was returned.' ); + } + + /** + * Tests that the refetched network replaces the poisoned cache value. + * + * Otherwise the poisoned value survives and every subsequent lookup queries the database again. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_replaces_a_poisoned_cache_value( $cache_value ): void { + wp_cache_set( self::$different_network_id, $cache_value, 'networks' ); + + // Prime the object cache, replacing the poisoned value. + WP_Network::get_instance( self::$different_network_id ); + + $cached = wp_cache_get( self::$different_network_id, 'networks' ); + + $this->assertInstanceOf( stdClass::class, $cached, 'The poisoned value was not replaced in the object cache.' ); + $this->assertSame( self::$different_network_id, (int) $cached->id, 'The wrong network was added to the object cache.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss(): array { + return array( + 'true' => array( true ), + 'a non-numeric string' => array( 'not-a-network' ), + 'an empty array' => array( array() ), + 'an array of network data' => array( + array( + 'id' => '1', + 'domain' => 'wordpress.org', + 'path' => '/', + ), + ), + 'an object without an id' => array( + (object) array( + 'domain' => 'wordpress.org', + 'path' => '/', + ), + ), + ); + } + /** * Gets the ID of the site with the highest ID. * @return int diff --git a/tests/phpunit/tests/multisite/wpSite.php b/tests/phpunit/tests/multisite/wpSite.php new file mode 100644 index 0000000000000..7c3439eae10ff --- /dev/null +++ b/tests/phpunit/tests/multisite/wpSite.php @@ -0,0 +1,310 @@ +blog->create( + array( + 'domain' => 'wordpress.org', + 'path' => '/', + ) + ); + + self::$nonexistent_site_id = self::$site_id + 1000; + } + + public static function wpTearDownAfterClass(): void { + /* + * The object cache is flushed before each test, but not between the last test + * and here. A poisoned value left in the 'sites' group would make the get_site() + * call inside wp_delete_site() consider the site to no longer exist. + */ + wp_cache_delete( self::$site_id, 'sites' ); + + wp_delete_site( self::$site_id ); + + wp_update_network_site_counts(); + } + + /** + * Tests that a site ID which cannot reference a site returns false without querying the database. + * + * @global wpdb $wpdb WordPress database abstraction object. + * + * @dataProvider data_get_instance_returns_false_for_an_empty_site_id + * + * @param mixed $site_id Site ID to look up. + */ + public function test_get_instance_returns_false_for_an_empty_site_id( $site_id ): void { + global $wpdb; + + $num_queries = $wpdb->num_queries; + + $this->assertFalse( WP_Site::get_instance( $site_id ), 'A site object was returned.' ); // @phpstan-ignore argument.type (Intentionally passing a value which is not an integer.) + $this->assertSame( $num_queries, $wpdb->num_queries, 'The database was queried.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_returns_false_for_an_empty_site_id(): array { + return array( + 'zero as an integer' => array( 0 ), + 'zero as a string' => array( '0' ), + 'a non-numeric string' => array( 'not-a-site-id' ), + 'false' => array( false ), + 'null' => array( null ), + ); + } + + /** + * Tests that an uncached site is fetched from the database and then added to the object cache. + * + * @global wpdb $wpdb WordPress database abstraction object. + */ + public function test_get_instance_queries_the_database_when_the_site_is_not_cached(): void { + global $wpdb; + + wp_cache_delete( self::$site_id, 'sites' ); + + $num_queries = $wpdb->num_queries; + + $site = WP_Site::get_instance( self::$site_id ); + + $this->assertInstanceOf( WP_Site::class, $site, 'A site object was not returned.' ); + $this->assertSame( (string) self::$site_id, $site->blog_id, 'The wrong site was returned.' ); + $this->assertSame( $num_queries + 1, $wpdb->num_queries, 'The site was not fetched from the database.' ); + + $cached = wp_cache_get( self::$site_id, 'sites' ); + + $this->assertInstanceOf( stdClass::class, $cached, 'The database row was not added to the object cache.' ); + $this->assertSame( (string) self::$site_id, $cached->blog_id, 'The wrong site was added to the object cache.' ); + } + + /** + * Tests that a cached site is returned without querying the database. + * + * @global wpdb $wpdb WordPress database abstraction object. + */ + public function test_get_instance_does_not_query_the_database_when_the_site_is_cached(): void { + global $wpdb; + + wp_cache_delete( self::$site_id, 'sites' ); + + // Prime the object cache. + WP_Site::get_instance( self::$site_id ); + + $num_queries = $wpdb->num_queries; + + $site = WP_Site::get_instance( self::$site_id ); + + $this->assertInstanceOf( WP_Site::class, $site, 'A site object was not returned.' ); + $this->assertSame( (string) self::$site_id, $site->blog_id, 'The wrong site was returned.' ); + $this->assertSame( $num_queries, $wpdb->num_queries, 'The database was queried.' ); + } + + /** + * Tests that a cached WP_Site object is treated as a cache hit. + * + * The object cache is normally primed with the raw database row, but a WP_Site + * instance may be cached by other means. + * + * @global wpdb $wpdb WordPress database abstraction object. + */ + public function test_get_instance_treats_a_cached_wp_site_object_as_a_cache_hit(): void { + global $wpdb; + + wp_cache_set( self::$site_id, WP_Site::get_instance( self::$site_id ), 'sites' ); + + $num_queries = $wpdb->num_queries; + + $site = WP_Site::get_instance( self::$site_id ); + + $this->assertInstanceOf( WP_Site::class, $site, 'A site object was not returned.' ); + $this->assertSame( (string) self::$site_id, $site->blog_id, 'The wrong site was returned.' ); + $this->assertSame( $num_queries, $wpdb->num_queries, 'The database was queried.' ); + } + + /** + * Tests that a site which is not in the database returns false and that the miss is cached. + * + * @global wpdb $wpdb WordPress database abstraction object. + */ + public function test_get_instance_returns_false_for_a_nonexistent_site_and_caches_the_miss(): void { + global $wpdb; + + wp_cache_delete( self::$nonexistent_site_id, 'sites' ); + + $num_queries = $wpdb->num_queries; + + $this->assertFalse( WP_Site::get_instance( self::$nonexistent_site_id ), 'A site object was returned.' ); + $this->assertSame( $num_queries + 1, $wpdb->num_queries, 'The database was not queried.' ); + $this->assertSame( -1, wp_cache_get( self::$nonexistent_site_id, 'sites' ), 'The miss was not cached as -1.' ); + } + + /** + * Tests that a cached miss is not looked up in the database again. + * + * @global wpdb $wpdb WordPress database abstraction object. + */ + public function test_get_instance_does_not_query_the_database_for_a_cached_miss(): void { + global $wpdb; + + wp_cache_delete( self::$nonexistent_site_id, 'sites' ); + + // Prime the object cache with the miss. + WP_Site::get_instance( self::$nonexistent_site_id ); + + $num_queries = $wpdb->num_queries; + + $this->assertFalse( WP_Site::get_instance( self::$nonexistent_site_id ), 'A site object was returned.' ); + $this->assertSame( $num_queries, $wpdb->num_queries, 'The database was queried.' ); + } + + /** + * Tests that a cached value which is neither a site object nor the miss sentinel is treated as a cache miss. + * + * @ticket 65962 + * + * @global wpdb $wpdb WordPress database abstraction object. + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss( $cache_value ): void { + global $wpdb; + + wp_cache_set( self::$site_id, $cache_value, 'sites' ); + + $num_queries = $wpdb->num_queries; + + $site = WP_Site::get_instance( self::$site_id ); + + $this->assertInstanceOf( WP_Site::class, $site, 'A site object was not returned.' ); + $this->assertSame( (string) self::$site_id, $site->blog_id, 'The wrong site was returned.' ); + $this->assertSame( $num_queries + 1, $wpdb->num_queries, 'The site was not fetched from the database.' ); + } + + /** + * Tests that the refetched site replaces the poisoned cache value. + * + * Otherwise the poisoned value survives and every subsequent lookup queries the database again. + * + * @ticket 65962 + * + * @global wpdb $wpdb WordPress database abstraction object. + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_replaces_a_poisoned_cache_value( $cache_value ): void { + global $wpdb; + + wp_cache_set( self::$site_id, $cache_value, 'sites' ); + + // Prime the object cache, replacing the poisoned value. + WP_Site::get_instance( self::$site_id ); + + $cached = wp_cache_get( self::$site_id, 'sites' ); + + $this->assertInstanceOf( stdClass::class, $cached, 'The poisoned value was not replaced in the object cache.' ); + $this->assertSame( (string) self::$site_id, $cached->blog_id, 'The wrong site was added to the object cache.' ); + + $num_queries = $wpdb->num_queries; + + $site = WP_Site::get_instance( self::$site_id ); + + $this->assertInstanceOf( WP_Site::class, $site, 'A site object was not returned.' ); + $this->assertSame( (string) self::$site_id, $site->blog_id, 'The wrong site was returned.' ); + $this->assertSame( $num_queries, $wpdb->num_queries, 'The database was queried again.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss(): array { + return array( + 'true' => array( true ), + 'a non-numeric string' => array( 'not-a-site' ), + 'an empty array' => array( array() ), + 'an array of site data' => array( + array( + 'blog_id' => '1', + 'domain' => 'wordpress.org', + 'path' => '/', + ), + ), + 'an object without blog_id' => array( + (object) array( + 'domain' => 'wordpress.org', + 'path' => '/', + ), + ), + ); + } + + /** + * Tests that any numeric cached value is treated as a cached miss. + * + * Only -1 is written to the cache to record a miss, but every numeric value is + * currently trusted as one, so an existing site is reported as not found. + * + * @ticket 65962 + * + * @global wpdb $wpdb WordPress database abstraction object. + * + * @dataProvider data_get_instance_treats_a_numeric_cache_value_as_a_cached_miss + * + * @param int|numeric-string $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_numeric_cache_value_as_a_cached_miss( $cache_value ): void { + global $wpdb; + + wp_cache_set( self::$site_id, $cache_value, 'sites' ); + + $num_queries = $wpdb->num_queries; + + $this->assertFalse( WP_Site::get_instance( self::$site_id ), 'A site object was returned.' ); + $this->assertSame( $num_queries, $wpdb->num_queries, 'The database was queried.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_treats_a_numeric_cache_value_as_a_cached_miss(): array { + return array( + 'the -1 miss sentinel' => array( -1 ), + '-1 as a string' => array( '-1' ), + 'zero' => array( 0 ), + 'a positive integer' => array( 42 ), + 'a float as a string' => array( '3.5' ), + ); + } +} diff --git a/tests/phpunit/tests/post/wpPost.php b/tests/phpunit/tests/post/wpPost.php index b35a9ba5c406a..e738ef25e7036 100644 --- a/tests/phpunit/tests/post/wpPost.php +++ b/tests/phpunit/tests/post/wpPost.php @@ -4,7 +4,7 @@ * @group post */ class Tests_Post_wpPost extends WP_UnitTestCase { - protected static $post_id; + protected static int $post_id; public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { global $wpdb; @@ -68,4 +68,76 @@ public function test_get_instance_should_succeed_for_float_that_is_equal_to_post $this->assertSame( 1, $found->ID ); } + + /** + * Tests that a cached value which cannot be used as a post is treated as a cache miss. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss( $cache_value ): void { + wp_cache_set( self::$post_id, $cache_value, 'posts' ); + + $num_queries = get_num_queries(); + + $post = WP_Post::get_instance( self::$post_id ); + + $this->assertInstanceOf( WP_Post::class, $post, 'A post object was not returned.' ); + $this->assertSame( self::$post_id, $post->ID, 'The wrong post was returned.' ); + $this->assertSame( $num_queries + 1, get_num_queries(), 'The post was not fetched from the database.' ); + } + + /** + * Tests that the refetched post replaces the poisoned cache value. + * + * Otherwise the poisoned value survives and every subsequent lookup queries the database again. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_replaces_a_poisoned_cache_value( $cache_value ): void { + wp_cache_set( self::$post_id, $cache_value, 'posts' ); + + // Prime the object cache, replacing the poisoned value. + WP_Post::get_instance( self::$post_id ); + + $num_queries = get_num_queries(); + + $post = WP_Post::get_instance( self::$post_id ); + + $this->assertInstanceOf( WP_Post::class, $post, 'A post object was not returned.' ); + $this->assertSame( self::$post_id, $post->ID, 'The wrong post was returned.' ); + $this->assertSame( $num_queries, get_num_queries(), 'The database was queried again.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss(): array { + return array( + 'true' => array( true ), + 'a non-numeric string' => array( 'not-a-post' ), + 'an empty array' => array( array() ), + 'an array of post data' => array( + array( + 'ID' => 1, + 'post_title' => 'Post 1', + ), + ), + 'an object without ID' => array( + (object) array( + 'post_title' => 'Post 1', + ), + ), + 'a WP_Post without ID' => array( new WP_Post( new stdClass() ) ), + ); + } } diff --git a/tests/phpunit/tests/term/wpTerm.php b/tests/phpunit/tests/term/wpTerm.php index e640cf8120732..f7a2934baa473 100644 --- a/tests/phpunit/tests/term/wpTerm.php +++ b/tests/phpunit/tests/term/wpTerm.php @@ -4,7 +4,7 @@ * @group taxonomy */ class Tests_Term_WpTerm extends WP_UnitTestCase { - protected static $term_id; + protected static int $term_id; public function set_up() { parent::set_up(); @@ -89,4 +89,102 @@ public function test_get_instance_should_respect_taxonomy_when_term_id_is_found_ $found = WP_Term::get_instance( self::$term_id, 'wptests_tax2' ); $this->assertFalse( $found ); } + + /** + * Tests that a cached value which cannot be used as a term is treated as a cache miss. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss( $cache_value ): void { + wp_cache_set( self::$term_id, $cache_value, 'terms' ); + + $num_queries = get_num_queries(); + + $term = WP_Term::get_instance( self::$term_id ); + + $this->assertInstanceOf( WP_Term::class, $term, 'A term object was not returned.' ); + $this->assertSame( self::$term_id, $term->term_id, 'The wrong term was returned.' ); + $this->assertSame( 'wptests_tax', $term->taxonomy, 'The term was returned without its taxonomy.' ); + $this->assertSame( $num_queries + 1, get_num_queries(), 'The term was not fetched from the database.' ); + } + + /** + * Tests that a poisoned cache value is treated as a miss when a taxonomy is given. + * + * The taxonomy comparison reads a property off whatever is cached, so the guard has to + * reject an unusable value before that point. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss_with_a_taxonomy( $cache_value ): void { + wp_cache_set( self::$term_id, $cache_value, 'terms' ); + + $term = WP_Term::get_instance( self::$term_id, 'wptests_tax' ); + + $this->assertInstanceOf( WP_Term::class, $term, 'A term object was not returned.' ); + $this->assertSame( self::$term_id, $term->term_id, 'The wrong term was returned.' ); + } + + /** + * Tests that the refetched term replaces the poisoned cache value. + * + * Otherwise the poisoned value survives and every subsequent lookup queries the database again. + * + * @ticket 65962 + * + * @dataProvider data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss + * + * @param mixed $cache_value Value to poison the object cache with. + */ + public function test_get_instance_replaces_a_poisoned_cache_value( $cache_value ): void { + wp_cache_set( self::$term_id, $cache_value, 'terms' ); + + // Prime the object cache, replacing the poisoned value. + WP_Term::get_instance( self::$term_id ); + + $num_queries = get_num_queries(); + + $term = WP_Term::get_instance( self::$term_id ); + + $this->assertInstanceOf( WP_Term::class, $term, 'A term object was not returned.' ); + $this->assertSame( self::$term_id, $term->term_id, 'The wrong term was returned.' ); + $this->assertSame( $num_queries, get_num_queries(), 'The database was queried again.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_instance_treats_a_poisoned_cache_value_as_a_cache_miss(): array { + return array( + 'true' => array( true ), + 'a non-numeric string' => array( 'not-a-term' ), + 'an array of term data' => array( + array( + 'term_id' => 1, + 'taxonomy' => 'wptests_tax', + ), + ), + 'an object without term_id' => array( + (object) array( + 'taxonomy' => 'wptests_tax', + ), + ), + 'an object without taxonomy' => array( + (object) array( + 'term_id' => 1, + ), + ), + 'a WP_Term without term_id' => array( new WP_Term( new stdClass() ) ), + ); + } } From fbd7acdef121b9c8fbee8d595a02b75c83d51b8e Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Thu, 27 Aug 2026 00:21:32 +0000 Subject: [PATCH 008/363] View configuration API: Add a Reading settings field. Adds a Reading settings entry to the form configuration returned for templates. The editor renders it as a link to the Reading settings screen in the front page template's summary panel. Developed in https://github.com/WordPress/wordpress-develop/pull/13266 Follow-up to [62547]. Props ntsekouras, wildworks. Fixes #65959. git-svn-id: https://develop.svn.wordpress.org/trunk@63355 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/view-config.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/wp-includes/view-config.php b/src/wp-includes/view-config.php index b97b221ec2a32..2b74a63608455 100644 --- a/src/wp-includes/view-config.php +++ b/src/wp-includes/view-config.php @@ -724,6 +724,13 @@ function _wp_get_entity_view_config_posttype_wp_template( $data ) { 'labelPosition' => 'none', ), ), + array( + 'id' => 'reading_settings', + 'layout' => array( + 'type' => 'regular', + 'labelPosition' => 'none', + ), + ), array( 'id' => 'last_edited_date', 'layout' => array( From 3342ad0cde42b78d3c5dba806301177c486c4402 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 27 Aug 2026 01:09:05 +0000 Subject: [PATCH 009/363] Build/Test Tools: Treat request-scoped constants as dynamic in PHPStan. The constants `DOING_AJAX`, `DOING_CRON`, `REST_REQUEST`, `WP_INSTALLING`, `WP_INSTALLING_NETWORK`, `WP_REPAIRING` and `XMLRPC_REQUEST` are each defined only as the literal `true` within the tree PHPStan analyzes, so it concluded that the right side of the `defined( 'X' ) && X` idiom can never be falsy. That is correct about the code PHPStan can see and wrong about reality: every one of these is request-scoped, absent on most requests, defined only by the front controller handling that particular kind of request, and definable by a plugin or by `wp-config.php` before load. The guard is doing real work, so the constants belong in `dynamicConstantNames` alongside those already listed there. This resolves 11 `booleanAnd.rightAlwaysTrue` occurrences, in `wp-admin/includes/schema.php`, `wp-includes/functions.php`, `wp-includes/l10n.php`, `wp-includes/load.php` and `wp-includes/user.php`, leaving 5 in the baseline, which was regenerated with `composer phpstan:baselines`. No source file is touched, so runtime behavior is unchanged. Developed in https://github.com/WordPress/wordpress-develop/pull/13071. Follow-up to r63023, r63191. Props tstokes8040. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63356 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpstan/base.neon | 7 ++++++ .../baselines/booleanAnd.rightAlwaysTrue.neon | 22 +------------------ 2 files changed, 8 insertions(+), 21 deletions(-) diff --git a/tests/phpstan/base.neon b/tests/phpstan/base.neon index ab07051c9ad7a..57cf0cf40da15 100644 --- a/tests/phpstan/base.neon +++ b/tests/phpstan/base.neon @@ -82,6 +82,8 @@ parameters: - DB_COLLATE - DISALLOW_FILE_EDIT - DISALLOW_UNFILTERED_HTML + - DOING_AJAX + - DOING_CRON - EMPTY_TRASH_DAYS - ENFORCE_GZIP - FORCE_SSL_LOGIN @@ -93,6 +95,7 @@ parameters: - MULTISITE - NO_HEADER_TEXT - NOBLOGREDIRECT + - REST_REQUEST - SAVEQUERIES - SCRIPT_DEBUG - SECRET_KEY @@ -106,9 +109,12 @@ parameters: - WP_DEBUG_DISPLAY - WP_DEBUG_LOG - WP_DEVELOPMENT_MODE + - WP_INSTALLING + - WP_INSTALLING_NETWORK - WP_LANG_DIR - WP_NETWORK_ADMIN - WP_POST_REVISIONS + - WP_REPAIRING - WP_SITEURL - WP_USE_THEMES - WP_USER_ADMIN @@ -116,6 +122,7 @@ parameters: - WPMU_ACCEL_REDIRECT - WPMU_PLUGIN_DIR - WPMU_SENDFILE + - XMLRPC_REQUEST # What directories and files should be scanned. paths: diff --git a/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon b/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon index 64071efcf3d23..6bd091f5adffc 100644 --- a/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon +++ b/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon @@ -23,11 +23,6 @@ parameters: identifier: booleanAnd.rightAlwaysTrue count: 1 path: ../../../src/wp-admin/includes/class-wp-site-health.php - - - message: '#^Right side of && is always true\.$#' - identifier: booleanAnd.rightAlwaysTrue - count: 1 - path: ../../../src/wp-admin/includes/schema.php - message: '#^Right side of && is always true\.$#' identifier: booleanAnd.rightAlwaysTrue @@ -46,20 +41,5 @@ parameters: - message: '#^Right side of && is always true\.$#' identifier: booleanAnd.rightAlwaysTrue - count: 2 + count: 1 path: ../../../src/wp-includes/functions.php - - - message: '#^Right side of && is always true\.$#' - identifier: booleanAnd.rightAlwaysTrue - count: 3 - path: ../../../src/wp-includes/l10n.php - - - message: '#^Right side of && is always true\.$#' - identifier: booleanAnd.rightAlwaysTrue - count: 4 - path: ../../../src/wp-includes/load.php - - - message: '#^Right side of && is always true\.$#' - identifier: booleanAnd.rightAlwaysTrue - count: 2 - path: ../../../src/wp-includes/user.php From 1806675d1004dc3d4dfe34df865a83eb7da90cb4 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 27 Aug 2026 03:45:40 +0000 Subject: [PATCH 010/363] Code Quality: Mark `have_posts()` and `have_comments()` as "impure" for PHPStan. Both `WP_Query::have_posts()` and `WP_Query::have_comments()` advance the loop as a side effect, so two identical calls do not return the same value. PHPStan treated them as pure, concluded that a `while ( have_posts() )` condition could never change, and reported the loops as always-true or always-false with the code past them unreachable. Marking those methods and their procedural wrappers in `wp-includes/query.php` as `@phpstan-impure` empties the `while.alwaysTrue` and `while.alwaysFalse` baselines, which are deleted along with their entries in `phpstan.neon.dist`, and trims `deadCode.unreachable` and `if.alwaysTrue`. Two of the removed `while.alwaysTrue` entries were in `Twenty_Fourteen_Ephemera_Widget::widget()`, whose loop carries a real bug: `$tmp_more` was assigned inside the loop whose effects it exists to undo, so on every iteration after the first it captured the value the widget itself had just written, and the restore afterwards put back the secondary query's `0` rather than the caller's value. The assignment moves above the loop, while also guarding against the variable possibly being undefined. Developed in https://github.com/WordPress/wordpress-develop/pull/13069. Follow-up to r27124, r30085, r63023. Props dpantazis, westonruter. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63357 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 2 - .../themes/twentyfourteen/inc/widgets.php | 3 +- src/wp-includes/class-wp-query.php | 4 + src/wp-includes/query.php | 4 + .../baselines/deadCode.unreachable.neon | 230 -------------- tests/phpstan/baselines/if.alwaysTrue.neon | 5 - .../phpstan/baselines/while.alwaysFalse.neon | 25 -- tests/phpstan/baselines/while.alwaysTrue.neon | 300 ------------------ .../theme/twentyFourteenEphemeraWidget.php | 134 ++++++++ 9 files changed, 144 insertions(+), 563 deletions(-) delete mode 100644 tests/phpstan/baselines/while.alwaysFalse.neon delete mode 100644 tests/phpstan/baselines/while.alwaysTrue.neon create mode 100644 tests/phpunit/tests/theme/twentyFourteenEphemeraWidget.php diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 3e4b36f256d96..1416704909f34 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -85,8 +85,6 @@ includes: - tests/phpstan/baselines/ternary.alwaysTrue.neon - tests/phpstan/baselines/varTag.noVariable.neon - tests/phpstan/baselines/variable.undefined.neon - - tests/phpstan/baselines/while.alwaysFalse.neon - - tests/phpstan/baselines/while.alwaysTrue.neon # phpstan:baselines end parameters: diff --git a/src/wp-content/themes/twentyfourteen/inc/widgets.php b/src/wp-content/themes/twentyfourteen/inc/widgets.php index 36846daa84860..b375113b308b5 100644 --- a/src/wp-content/themes/twentyfourteen/inc/widgets.php +++ b/src/wp-content/themes/twentyfourteen/inc/widgets.php @@ -137,6 +137,8 @@ public function widget( $args, $instance ) { if ( $ephemera->have_posts() ) : $tmp_content_width = $GLOBALS['content_width']; $GLOBALS['content_width'] = 306; + // The global is unset until a loop has run, so this may be reached before it exists. + $tmp_more = $GLOBALS['more'] ?? null; echo $args['before_widget']; ?> @@ -148,7 +150,6 @@ public function widget( $args, $instance ) { have_posts() ) : $ephemera->the_post(); - $tmp_more = $GLOBALS['more']; $GLOBALS['more'] = 0; ?>
  • diff --git a/src/wp-includes/class-wp-query.php b/src/wp-includes/class-wp-query.php index 228691d26d12b..906cca0905e1a 100644 --- a/src/wp-includes/class-wp-query.php +++ b/src/wp-includes/class-wp-query.php @@ -3839,6 +3839,8 @@ function ( $carry, $post ) { * * @since 1.5.0 * + * @phpstan-impure + * * @return bool True if posts are available, false if end of the loop. */ public function have_posts() { @@ -3929,6 +3931,8 @@ public function the_comment() { * * @since 2.2.0 * + * @phpstan-impure + * * @return bool True if comments are available, false if no more comments. */ public function have_comments() { diff --git a/src/wp-includes/query.php b/src/wp-includes/query.php index 60571c01cb880..42592002c1cab 100644 --- a/src/wp-includes/query.php +++ b/src/wp-includes/query.php @@ -956,6 +956,8 @@ function is_main_query() { * * @global WP_Query $wp_query WordPress Query object. * + * @phpstan-impure + * * @return bool True if posts are available, false if end of the loop. */ function have_posts() { @@ -1036,6 +1038,8 @@ function the_post() { * * @global WP_Query $wp_query WordPress Query object. * + * @phpstan-impure + * * @return bool True if comments are available, false if no more comments. */ function have_comments() { diff --git a/tests/phpstan/baselines/deadCode.unreachable.neon b/tests/phpstan/baselines/deadCode.unreachable.neon index 0bd31fe524a9a..8a4288bc40c43 100644 --- a/tests/phpstan/baselines/deadCode.unreachable.neon +++ b/tests/phpstan/baselines/deadCode.unreachable.neon @@ -38,241 +38,11 @@ parameters: identifier: deadCode.unreachable count: 1 path: ../../../src/wp-admin/includes/class-wp-internal-pointers.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 2 - path: ../../../src/wp-admin/includes/dashboard.php - message: '#^Unreachable statement \- code above always terminates\.$#' identifier: deadCode.unreachable count: 2 path: ../../../src/wp-admin/post.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/author.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/category.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/inc/widgets.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/showcase.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/tag.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfifteen/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfifteen/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfifteen/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/author.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/category.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/inc/widgets.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/tag.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/taxonomy-post_format.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/template-parts/page/content-front-page-panels.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentysixteen/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentysixteen/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentysixteen/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/author.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/category.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/tag.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/taxonomy-post_format.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/author.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/category.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/search.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/tag.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwentyone/archive.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwentyone/index.php - - - message: '#^Unreachable statement \- code above always terminates\.$#' - identifier: deadCode.unreachable - count: 1 - path: ../../../src/wp-content/themes/twentytwentyone/search.php - message: '#^Unreachable statement \- code above always terminates\.$#' identifier: deadCode.unreachable diff --git a/tests/phpstan/baselines/if.alwaysTrue.neon b/tests/phpstan/baselines/if.alwaysTrue.neon index f049efde2d19d..6888b9780b5f9 100644 --- a/tests/phpstan/baselines/if.alwaysTrue.neon +++ b/tests/phpstan/baselines/if.alwaysTrue.neon @@ -28,11 +28,6 @@ parameters: identifier: if.alwaysTrue count: 2 path: ../../../src/wp-admin/upload.php - - - message: '#^If condition is always true\.$#' - identifier: if.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/comments.php - message: '#^If condition is always true\.$#' identifier: if.alwaysTrue diff --git a/tests/phpstan/baselines/while.alwaysFalse.neon b/tests/phpstan/baselines/while.alwaysFalse.neon deleted file mode 100644 index 3c924003ea783..0000000000000 --- a/tests/phpstan/baselines/while.alwaysFalse.neon +++ /dev/null @@ -1,25 +0,0 @@ -# PHPStan baseline for the `while.alwaysFalse` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/while.alwaysFalse -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=while.alwaysFalse -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^While loop condition is always false\.$#' - identifier: while.alwaysFalse - count: 1 - path: ../../../src/wp-includes/feed-rdf.php diff --git a/tests/phpstan/baselines/while.alwaysTrue.neon b/tests/phpstan/baselines/while.alwaysTrue.neon deleted file mode 100644 index 5da6550e89cc0..0000000000000 --- a/tests/phpstan/baselines/while.alwaysTrue.neon +++ /dev/null @@ -1,300 +0,0 @@ -# PHPStan baseline for the `while.alwaysTrue` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/while.alwaysTrue -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=while.alwaysTrue -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-admin/includes/dashboard.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-admin/includes/nav-menu.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/author.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/category.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/inc/widgets.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/showcase.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/tag.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfifteen/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfifteen/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfifteen/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/author.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/category.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/inc/widgets.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/tag.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/taxonomy-post_format.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentynineteen/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/front-page.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyseventeen/template-parts/page/content-front-page-panels.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentysixteen/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentysixteen/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentysixteen/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyten/loop-attachment.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyten/loop-page.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentyten/loop-single.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/author.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/category.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/tag.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentythirteen/taxonomy-post_format.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/author.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/category.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwelve/tag.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwenty/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwenty/singular.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwenty/templates/template-cover.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwentyone/archive.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwentyone/index.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-content/themes/twentytwentyone/search.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-includes/block-template.php - - - message: '#^While loop condition is always true\.$#' - identifier: while.alwaysTrue - count: 1 - path: ../../../src/wp-includes/theme-compat/embed.php diff --git a/tests/phpunit/tests/theme/twentyFourteenEphemeraWidget.php b/tests/phpunit/tests/theme/twentyFourteenEphemeraWidget.php new file mode 100644 index 0000000000000..c2442ef18ec7e --- /dev/null +++ b/tests/phpunit/tests/theme/twentyFourteenEphemeraWidget.php @@ -0,0 +1,134 @@ + + */ + private array $original_globals = array(); + + public function set_up() { + parent::set_up(); + + /* + * `backupGlobals` is disabled for the suite, so these have to be restored by hand + * to keep later tests in the process from inheriting them. Capture them before the + * skip below, which still runs `tear_down()`. + */ + foreach ( $this->global_names as $global_name ) { + if ( array_key_exists( $global_name, $GLOBALS ) ) { + $this->original_globals[ $global_name ] = $GLOBALS[ $global_name ]; + } + } + + $widgets = WP_CONTENT_DIR . '/themes/twentyfourteen/inc/widgets.php'; + if ( ! file_exists( $widgets ) ) { + $this->markTestSkipped( 'The Twenty Fourteen theme is not installed.' ); + } + require_once $widgets; + } + + public function tear_down() { + foreach ( $this->global_names as $global_name ) { + if ( array_key_exists( $global_name, $this->original_globals ) ) { + $GLOBALS[ $global_name ] = $this->original_globals[ $global_name ]; + } else { + unset( $GLOBALS[ $global_name ] ); + } + } + + parent::tear_down(); + } + + /** + * The widget must restore the original `$more` global, which `WP_Query::setup_postdata()` + * zeroes out for each post the widget's secondary loop renders. + */ + public function test_widget_restores_more_global() { + $post_id = self::factory()->post->create( + array( + 'post_content' => 'I want ice cream!', + ) + ); + $this->assertIsInt( $post_id ); + set_post_format( $post_id, 'aside' ); + + // Sentinel value for the restore assertion below; it does not affect what the widget renders. + $GLOBALS['more'] = 1; + $GLOBALS['content_width'] = 474; + + $widget = new Twenty_Fourteen_Ephemera_Widget(); + + $output = get_echo( + array( $widget, 'widget' ), + array( + array( + 'before_widget' => '', + 'after_widget' => '', + ), + array( 'format' => 'aside' ), + ) + ); + + $this->assertNotEmpty( $output, 'The widget content.' ); + $processor = new WP_HTML_Tag_Processor( $output ); + $more_link_count = 0; + while ( $processor->next_tag( array( 'class_name' => 'more-link' ) ) ) { + ++$more_link_count; + } + $this->assertSame( 1, $more_link_count, 'Expected there to be one more link.' ); + $this->assertSame( 1, $GLOBALS['more'], 'The $more global was not restored to its original value.' ); // @phpstan-ignore method.alreadyNarrowedType (The global variable is modified by Twenty_Fourteen_Ephemera_Widget::widget().) + $this->assertSame( 474, $GLOBALS['content_width'], 'The $content_width global was not restored to its original value.' ); + } + + /** + * The `$more` global is only defined once a loop has run, so the widget must not + * assume it exists. It can render before any loop on a 404, an empty search, or an + * empty archive, as well as outside the template entirely. + */ + public function test_widget_when_more_global_is_undefined() { + $post_id = self::factory()->post->create( + array( + 'post_content' => 'I want ice cream!', + ) + ); + $this->assertIsInt( $post_id ); + set_post_format( $post_id, 'aside' ); + + unset( $GLOBALS['more'] ); + $GLOBALS['content_width'] = 474; + + $widget = new Twenty_Fourteen_Ephemera_Widget(); + + $output = get_echo( + array( $widget, 'widget' ), + array( + array( + 'before_widget' => '', + 'after_widget' => '', + ), + array( 'format' => 'aside' ), + ) + ); + + $this->assertNotEmpty( $output, 'The widget content.' ); + $this->assertNull( $GLOBALS['more'], 'The $more global was not restored to a falsey value.' ); // @phpstan-ignore offsetAccess.notFound (The global variable is set by Twenty_Fourteen_Ephemera_Widget::widget().) + } +} From a01819fddb4c6aeb4b51baa3c2f3e4bb4c7c567e Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Thu, 27 Aug 2026 09:28:56 +0000 Subject: [PATCH 011/363] Code Quality: Narrow post and term query return types by `fields`. `get_posts()`, `WP_Query::query()` and `WP_Term_Query::query()` take the query arguments directly, so static analysis can resolve their result from the `fields` value. Only `'ids'` was mapped; `'id=>parent'` and every `WP_Term_Query` field are now covered too. Two divergences in the cached `WP_Query` path had to be fixed for the `'id=>parent'` type to hold: a query served from the `post-queries` cache returned parent IDs keyed by their `post_parent:{$post_id}` cache keys rather than by post ID, and left `WP_Query::$posts` null when the cached query matched nothing. Developed in: https://github.com/WordPress/wordpress-develop/pull/13216 Props westonruter, swissspidy. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63358 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-query.php | 17 ++- src/wp-includes/class-wp-term-query.php | 38 +++++-- src/wp-includes/post.php | 6 +- tests/phpunit/tests/post/getPosts.php | 41 ++++++++ tests/phpunit/tests/query/fieldsClause.php | 116 +++++++++++++++++++++ tests/phpunit/tests/term/query.php | 47 +++++++++ 6 files changed, 251 insertions(+), 14 deletions(-) diff --git a/src/wp-includes/class-wp-query.php b/src/wp-includes/class-wp-query.php index 906cca0905e1a..9385ae832ff66 100644 --- a/src/wp-includes/class-wp-query.php +++ b/src/wp-includes/class-wp-query.php @@ -3295,15 +3295,20 @@ public function get_posts() { $post_parent_cache_keys[] = 'post_parent:' . (string) $post_id; } - /** @var int[] */ - $post_parents = wp_cache_get_multiple( $post_parent_cache_keys, 'posts' ); + /** @var array $cached_post_parents */ + $cached_post_parents = wp_cache_get_multiple( $post_parent_cache_keys, 'posts' ); - foreach ( $post_parents as $cache_key => $post_parent ) { + $post_parents = array(); + $this->posts = array(); + + foreach ( $cached_post_parents as $cache_key => $post_parent ) { $obj = new stdClass(); $obj->ID = (int) str_replace( 'post_parent:', '', $cache_key ); $obj->post_parent = (int) $post_parent; $this->posts[] = $obj; + + $post_parents[ $obj->ID ] = $obj->post_parent; } return $post_parents; @@ -3968,7 +3973,11 @@ public function rewind_comments() { * @return WP_Post[]|int[] Array of post objects or post IDs. * * @phpstan-return ( - * $query is array{ fields: 'ids', ... } ? int[] : WP_Post[] + * $query is array{ fields: 'ids', ... } + * ? int[] + * : ( $query is array{ fields: 'id=>parent', ... } + * ? array + * : WP_Post[] ) * ) */ public function query( $query ) { diff --git a/src/wp-includes/class-wp-term-query.php b/src/wp-includes/class-wp-term-query.php index 909da85433a51..56c8585d7224e 100644 --- a/src/wp-includes/class-wp-term-query.php +++ b/src/wp-includes/class-wp-term-query.php @@ -300,8 +300,24 @@ public function parse_query( $query = '' ) { * @since 4.6.0 * * @param string|array $query Array or URL query string of parameters. - * @return WP_Term[]|int[]|string[]|string Array of terms, or number of terms as numeric string - * when 'count' is passed to `$args['fields']`. + * @return WP_Term[]|int[]|string[]|int|string Array of terms, or number of terms as numeric string + * when 'count' is passed to `$args['fields']`, or the + * integer 0 when the queried parent term is not in the + * taxonomy hierarchy. + * + * @phpstan-return ( + * $query is array{ fields: 'count', ... } + * ? 0|numeric-string + * : ( $query is array{ fields: 'ids'|'tt_ids', ... } + * ? int[] + * : ( $query is array{ fields: 'id=>parent', ... } + * ? array + * : ( $query is array{ fields: 'names'|'slugs', ... } + * ? string[] + * : ( $query is array{ fields: 'id=>name'|'id=>slug', ... } + * ? array + * : WP_Term[] ) ) ) ) + * ) */ public function query( $query ) { $this->query_vars = wp_parse_args( $query ); @@ -318,7 +334,8 @@ public function query( $query ) { * - 'all' * - 'all_with_object_id' * - * The following will result in a numeric string being returned: + * The following will result in a numeric string being returned, or the integer 0 + * when the queried parent term is not in the taxonomy hierarchy: * * - 'count' * @@ -329,12 +346,9 @@ public function query( $query ) { * - 'names' * - 'slugs' * - * The following will result in an array of numeric strings being returned: - * - * - 'id=>parent' - * * The following will result in an array of integers being returned: * + * - 'id=>parent' * - 'ids' * - 'tt_ids' * @@ -342,8 +356,12 @@ public function query( $query ) { * * @global wpdb $wpdb WordPress database abstraction object. * - * @return WP_Term[]|int[]|string[]|string Array of terms, or number of terms as numeric string - * when 'count' is passed to `$args['fields']`. + * @return WP_Term[]|int[]|string[]|int|string Array of terms, or number of terms as numeric string + * when 'count' is passed to `$args['fields']`, or the + * integer 0 when the queried parent term is not in the + * taxonomy hierarchy. + * + * @phpstan-return 0|numeric-string|int[]|array|string[]|array|WP_Term[] */ public function get_terms() { global $wpdb; @@ -802,6 +820,8 @@ public function get_terms() { } if ( 'count' === $_fields ) { + // The request selects a single COUNT column, so it only returns null on a database error. + /** @var numeric-string $count */ $count = $wpdb->get_var( $this->request ); // phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared if ( $args['cache_results'] ) { wp_cache_set_salted( $cache_key, $count, 'term-queries', $last_changed ); diff --git a/src/wp-includes/post.php b/src/wp-includes/post.php index 2db73e9a20476..49ab472d37184 100644 --- a/src/wp-includes/post.php +++ b/src/wp-includes/post.php @@ -2619,7 +2619,11 @@ function is_post_embeddable( $post = null ) { * @return WP_Post[]|int[] Array of post objects or post IDs. * * @phpstan-return ( - * $args is array{ fields: 'ids', ... } ? int[] : WP_Post[] + * $args is array{ fields: 'ids', ... } + * ? int[] + * : ( $args is array{ fields: 'id=>parent', ... } + * ? array + * : WP_Post[] ) * ) */ function get_posts( $args = null ) { diff --git a/tests/phpunit/tests/post/getPosts.php b/tests/phpunit/tests/post/getPosts.php index 8d03b797df74c..723fd635bf1f3 100644 --- a/tests/phpunit/tests/post/getPosts.php +++ b/tests/phpunit/tests/post/getPosts.php @@ -176,4 +176,45 @@ public function test_should_accept_query_string_args(): void { $this->assertSame( array( $second_post_id ), $found_post_ids ); } + + /** + * Verifies what get_posts() returns for the `id=>parent` fields value. + * + * The second call is served from the `post-queries` cache, which previously returned + * the parent IDs keyed by the `post_parent:{$post_id}` cache keys they are stored + * under rather than by post ID. + * + * The cache hit is not specific to an external object cache being in use: the second + * call is served from the cache with the default in-memory implementation as well. + * + * @ticket 65817 + */ + public function test_should_return_parent_ids_keyed_by_post_id_when_cached(): void { + $parent_id = self::factory()->post->create( array( 'post_type' => 'page' ) ); + $this->assertIsInt( $parent_id, 'The parent page was not created.' ); + + $child_id = self::factory()->post->create( + array( + 'post_type' => 'page', + 'post_parent' => $parent_id, + ) + ); + $this->assertIsInt( $child_id, 'The child page was not created.' ); + + $args = array( + 'post_type' => 'page', + 'fields' => 'id=>parent', + 'numberposts' => -1, + 'orderby' => 'ID', + 'order' => 'ASC', + ); + + $expected = array( + $parent_id => 0, + $child_id => $parent_id, + ); + + $this->assertSame( $expected, get_posts( $args ), 'The uncached call is not of the expected form.' ); + $this->assertSame( $expected, get_posts( $args ), 'The cached call is not of the expected form.' ); + } } diff --git a/tests/phpunit/tests/query/fieldsClause.php b/tests/phpunit/tests/query/fieldsClause.php index c5febb973353b..e04e3fcd51c1b 100644 --- a/tests/phpunit/tests/query/fieldsClause.php +++ b/tests/phpunit/tests/query/fieldsClause.php @@ -211,6 +211,122 @@ public function test_should_include_filtered_values() { $this->assertEqualSets( $expected, $q2->posts, 'Posts property for second query is not in the expected form.' ); } + /** + * Tests the value returned when the fields are limited to the ID and parent sub-set. + * + * The second query is served from the `post-queries` cache, which previously returned + * the parent IDs keyed by the `post_parent:{$post_id}` cache keys they are stored + * under rather than by post ID. + * + * The cache hit is not specific to an external object cache being in use: the second + * query is served from the cache with the default in-memory implementation as well. + * + * @ticket 65817 + * + * @covers WP_Query::query + */ + public function test_id_and_parent_subset_should_return_parent_ids_keyed_by_post_id_when_cached() { + $parent_id = self::factory()->post->create( array( 'post_type' => 'page' ) ); + $this->assertIsInt( $parent_id, 'The parent page was not created.' ); + + $child_id = self::factory()->post->create( + array( + 'post_type' => 'page', + 'post_parent' => $parent_id, + ) + ); + $this->assertIsInt( $child_id, 'The child page was not created.' ); + + $query_args = array( + 'post_type' => 'page', + 'fields' => 'id=>parent', + 'posts_per_page' => -1, + 'orderby' => 'ID', + 'order' => 'ASC', + ); + + $expected = array( + $parent_id => 0, + $child_id => $parent_id, + ); + + $q1 = new WP_Query(); + $this->assertSame( $expected, $q1->query( $query_args ), 'The uncached query is not of the expected form.' ); + + $q2 = new WP_Query(); + $this->assertSame( $expected, $q2->query( $query_args ), 'The cached query is not of the expected form.' ); + } + + /** + * Tests the value returned when the fields are limited to the ID and parent sub-set + * and the query results are not cached. + * + * With caching disabled every query runs against the database, so the `post-queries` + * cache is never consulted. + * + * @ticket 65817 + * + * @covers WP_Query::query + */ + public function test_id_and_parent_subset_should_return_parent_ids_keyed_by_post_id_when_not_caching_results() { + $parent_id = self::factory()->post->create( array( 'post_type' => 'page' ) ); + $this->assertIsInt( $parent_id, 'The parent page was not created.' ); + + $child_id = self::factory()->post->create( + array( + 'post_type' => 'page', + 'post_parent' => $parent_id, + ) + ); + $this->assertIsInt( $child_id, 'The child page was not created.' ); + + $query_args = array( + 'post_type' => 'page', + 'fields' => 'id=>parent', + 'posts_per_page' => -1, + 'orderby' => 'ID', + 'order' => 'ASC', + 'cache_results' => false, + ); + + $expected = array( + $parent_id => 0, + $child_id => $parent_id, + ); + + $q1 = new WP_Query(); + $this->assertSame( $expected, $q1->query( $query_args ), 'First query is not of the expected form.' ); + + $q2 = new WP_Query(); + $this->assertSame( $expected, $q2->query( $query_args ), 'Second query is not of the expected form.' ); + } + + /** + * Tests the posts property when the fields are limited to the ID and parent sub-set + * and the query matches nothing. + * + * An empty result set is cached like any other, and the cached branch only ever + * appended to the posts property, so a second identical query left it as null where + * the first left it an empty array. + * + * @ticket 65817 + */ + public function test_id_and_parent_subset_should_populate_posts_property_when_cached_query_has_no_results() { + $query_args = array( + 'post_type' => 'wptests_pt', + 'fields' => 'id=>parent', + 'name' => 'this-slug-does-not-exist', + ); + + $q1 = new WP_Query(); + $this->assertSame( array(), $q1->query( $query_args ), 'The uncached query did not return an empty array.' ); + $this->assertSame( array(), $q1->posts, 'The posts property is not an empty array after the uncached query.' ); + + $q2 = new WP_Query(); + $this->assertSame( array(), $q2->query( $query_args ), 'The cached query did not return an empty array.' ); + $this->assertSame( array(), $q2->posts, 'The posts property is not an empty array after the cached query.' ); + } + /** * Filters the posts fields. * diff --git a/tests/phpunit/tests/term/query.php b/tests/phpunit/tests/term/query.php index f4a0a4cc5549f..a62072af65bf3 100644 --- a/tests/phpunit/tests/term/query.php +++ b/tests/phpunit/tests/term/query.php @@ -1207,4 +1207,51 @@ public function test_query_does_not_have_leading_whitespace() { $this->assertSame( ltrim( $q->request ), $q->request, 'The query has leading whitespace' ); } + + /** + * Verifies what WP_Term_Query::query() returns for the `id=>parent` fields value. + * + * Unlike WP_Query, both the uncached and the cached path run the results through + * WP_Term_Query::format_terms(), so the parent IDs are keyed by term ID either way. + * + * The assertion is repeated for a second query so that the cached path is covered + * both when an external object cache is in use and when it is not. + * + * @ticket 65817 + * + * @covers WP_Term_Query::query + */ + public function test_id_and_parent_fields_should_return_parent_ids_keyed_by_term_id() { + register_taxonomy( 'wptests_tax_hierarchical', 'post', array( 'hierarchical' => true ) ); + + $parent_id = self::factory()->term->create( array( 'taxonomy' => 'wptests_tax_hierarchical' ) ); + $this->assertIsInt( $parent_id, 'The parent term was not created.' ); + + $child_id = self::factory()->term->create( + array( + 'taxonomy' => 'wptests_tax_hierarchical', + 'parent' => $parent_id, + ) + ); + $this->assertIsInt( $child_id, 'The child term was not created.' ); + + $query_args = array( + 'taxonomy' => 'wptests_tax_hierarchical', + 'fields' => 'id=>parent', + 'hide_empty' => false, + 'orderby' => 'term_id', + 'order' => 'ASC', + ); + + $expected = array( + $parent_id => 0, + $child_id => $parent_id, + ); + + $q1 = new WP_Term_Query(); + $this->assertSame( $expected, $q1->query( $query_args ), 'First query is not of the expected form.' ); + + $q2 = new WP_Term_Query(); + $this->assertSame( $expected, $q2->query( $query_args ), 'Second query is not of the expected form.' ); + } } From ecc6a94f7aaa8cbed8a8e95b1a5aba199d8b6cad Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 10:19:31 +0000 Subject: [PATCH 012/363] Administration: Improve wp namespace in password-strength-meter.js Uses a consistent pattern for parameters and arguments in IIFEs. Props lemacarl, davidbaumwald, andg, hareesh-pillai, audrasjb, Boniu91, dkotter, hellofromTonya, vedantere, afercia. Fixes #38809. git-svn-id: https://develop.svn.wordpress.org/trunk@63359 602fd350-edb4-49c9-b593-d223f7449a82 --- src/js/_enqueues/wp/password-strength-meter.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/js/_enqueues/wp/password-strength-meter.js b/src/js/_enqueues/wp/password-strength-meter.js index 506088b038c8f..6aba8749adffa 100644 --- a/src/js/_enqueues/wp/password-strength-meter.js +++ b/src/js/_enqueues/wp/password-strength-meter.js @@ -3,9 +3,11 @@ */ /* global zxcvbn */ + +/** @namespace wp */ window.wp = window.wp || {}; -(function($){ +( function( $, wp ) { var __ = wp.i18n.__, sprintf = wp.i18n.sprintf; @@ -146,4 +148,4 @@ window.wp = window.wp || {}; * @type {wp.passwordStrength.meter} */ window.passwordStrength = wp.passwordStrength.meter; -})(jQuery); +} )( jQuery, window.wp ); From 00849cc49cddac2cadcf6b8fffe5e26b886501e9 Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Thu, 27 Aug 2026 12:03:16 +0000 Subject: [PATCH 013/363] Code Quality: Update PHPStan baseline files after r63358. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63360 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpstan/baselines/assign.propertyType.neon | 5 ----- tests/phpstan/baselines/return.type.neon | 5 ----- 2 files changed, 10 deletions(-) diff --git a/tests/phpstan/baselines/assign.propertyType.neon b/tests/phpstan/baselines/assign.propertyType.neon index f53f802b7d1da..82723fce7732a 100644 --- a/tests/phpstan/baselines/assign.propertyType.neon +++ b/tests/phpstan/baselines/assign.propertyType.neon @@ -48,11 +48,6 @@ parameters: identifier: assign.propertyType count: 1 path: ../../../src/wp-includes/class-wp-image-editor-imagick.php - - - message: '#^Property WP_Query\:\:\$posts \(array\\|null\) does not accept array\\.$#' - identifier: assign.propertyType - count: 1 - path: ../../../src/wp-includes/class-wp-query.php - message: '#^Property WP_Query\:\:\$posts \(array\\|null\) does not accept list\\|null\.$#' identifier: assign.propertyType diff --git a/tests/phpstan/baselines/return.type.neon b/tests/phpstan/baselines/return.type.neon index 9d99e94d0abd6..12bccecfa6be8 100644 --- a/tests/phpstan/baselines/return.type.neon +++ b/tests/phpstan/baselines/return.type.neon @@ -63,11 +63,6 @@ parameters: identifier: return.type count: 1 path: ../../../src/wp-includes/class-wp-image-editor-imagick.php - - - message: '#^Method WP_Term_Query\:\:get_terms\(\) should return array\\|string but returns int\.$#' - identifier: return.type - count: 1 - path: ../../../src/wp-includes/class-wp-term-query.php - message: '#^Method wp_xmlrpc_server\:\:mw_newPost\(\) should return int\|IXR_Error but returns string\.$#' identifier: return.type From 6e3ab806a2a13c843720908ad7e0174c5b6a822b Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Thu, 27 Aug 2026 12:05:58 +0000 Subject: [PATCH 014/363] I18N: Fix just-in-time translation loading for network-activated plugins. Just-in-time translation loading depends on text domain paths registered during bootstrap, but only site-level active plugins were registered. In multisite, PHP translation functions therefore returned untranslated strings for network-activated plugins even when the correct translation files were present. Developed in: https://github.com/WordPress/wordpress-develop/pull/11243 Follow-up to r59461. Props sanketparmar, okvee, pelentak. See #62244. Fixes #64249. git-svn-id: https://develop.svn.wordpress.org/trunk@63361 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-settings.php | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/src/wp-settings.php b/src/wp-settings.php index 29b7588b96b4f..1d55db83e2d85 100644 --- a/src/wp-settings.php +++ b/src/wp-settings.php @@ -502,6 +502,9 @@ */ $GLOBALS['wp_plugin_paths'] = array(); +// To make get_plugin_data() available for both network-activated and site-activated plugins, see #62244 and #64249. +require_once ABSPATH . 'wp-admin/includes/plugin.php'; + // Load must-use plugins. foreach ( wp_get_mu_plugins() as $mu_plugin ) { $_wp_plugin_file = $mu_plugin; @@ -524,6 +527,17 @@ foreach ( wp_get_active_network_plugins() as $network_plugin ) { wp_register_plugin_realpath( $network_plugin ); + $plugin_data = get_plugin_data( $network_plugin, false, false ); + + $textdomain = $plugin_data['TextDomain']; + if ( $textdomain ) { + if ( $plugin_data['DomainPath'] ) { + $GLOBALS['wp_textdomain_registry']->set_custom_path( $textdomain, dirname( $network_plugin ) . $plugin_data['DomainPath'] ); + } else { + $GLOBALS['wp_textdomain_registry']->set_custom_path( $textdomain, dirname( $network_plugin ) ); + } + } + $_wp_plugin_file = $network_plugin; include_once $network_plugin; $network_plugin = $_wp_plugin_file; // Avoid stomping of the $network_plugin variable in a plugin. @@ -537,7 +551,7 @@ */ do_action( 'network_plugin_loaded', $network_plugin ); } - unset( $network_plugin, $_wp_plugin_file ); + unset( $network_plugin, $_wp_plugin_file, $plugin_data, $textdomain ); } /** @@ -575,9 +589,6 @@ wp_recovery_mode()->initialize(); } -// To make get_plugin_data() available in a way that's compatible with plugins also loading this file, see #62244. -require_once ABSPATH . 'wp-admin/includes/plugin.php'; - // Load active plugins. foreach ( wp_get_active_and_valid_plugins() as $plugin ) { wp_register_plugin_realpath( $plugin ); From 99584cfd032f3aca1a0373cd6bba7d21e8a53086 Mon Sep 17 00:00:00 2001 From: Pascal Birchler Date: Thu, 27 Aug 2026 12:12:51 +0000 Subject: [PATCH 015/363] I18N: Simplify `WP_Textdomain_Registry::has()`. The `$domains_with_translations` cache was populated by scanning every translation file on each lookup, and matched text domains by prefix rather than in full. It was only ever read by `has()`, in a condition that can only be reached once a custom path has been registered, so checking for that path directly is equivalent, and takes the per-file work out of a loop that runs on every lookup. `WP_Textdomain_Registry::$domains_with_translations` is now deprecated. Developed in: https://github.com/WordPress/wordpress-develop/pull/7735 Props kkmuffme, swissspidy. Fixes #62348. git-svn-id: https://develop.svn.wordpress.org/trunk@63362 602fd350-edb4-49c9-b593-d223f7449a82 --- .../class-wp-textdomain-registry.php | 20 +-- .../tests/l10n/loadTextdomainJustInTime.php | 68 +++++++ .../tests/l10n/wpTextdomainRegistry.php | 167 ++++++++++++++++++ 3 files changed, 245 insertions(+), 10 deletions(-) diff --git a/src/wp-includes/class-wp-textdomain-registry.php b/src/wp-includes/class-wp-textdomain-registry.php index c62e751b6e47b..7d924d5abdf1d 100644 --- a/src/wp-includes/class-wp-textdomain-registry.php +++ b/src/wp-includes/class-wp-textdomain-registry.php @@ -63,8 +63,11 @@ class WP_Textdomain_Registry { * Holds a cached list of domains with translations to improve performance. * * @since 6.2.0 + * @since 7.2.0 This property is no longer used. * * @var string[] + * + * @deprecated */ protected $domains_with_translations = array(); @@ -108,10 +111,14 @@ public function get( $domain, $locale ) { * Determines whether any MO file paths are available for the domain. * * This is the case if a path has been set for the current locale, - * or if there is no information stored yet, in which case - * {@see _load_textdomain_just_in_time()} will fetch the information first. + * if there is no information stored yet, in which case + * {@see _load_textdomain_just_in_time()} will fetch the information first, + * or if a custom path has been registered via {@see load_plugin_textdomain()} + * or {@see load_theme_textdomain()}, which is always worth looking at. * * @since 6.1.0 + * @since 7.2.0 Checks for a registered custom path instead of the + * `$domains_with_translations` property. * * @param string $domain Text domain. * @return bool Whether any MO file paths are available for the domain. @@ -120,7 +127,7 @@ public function has( $domain ) { return ( isset( $this->current[ $domain ] ) || empty( $this->all[ $domain ] ) || - in_array( $domain, $this->domains_with_translations, true ) + isset( $this->custom_paths[ $domain ] ) ); } @@ -321,13 +328,6 @@ private function get_path_from_lang_dir( $domain, $locale ) { $php_path = "$location/$domain-$locale.l10n.php"; foreach ( $files as $file_path ) { - if ( - ! in_array( $domain, $this->domains_with_translations, true ) && - str_starts_with( str_replace( "$location/", '', $file_path ), "$domain-" ) - ) { - $this->domains_with_translations[] = $domain; - } - if ( $file_path === $mo_path || $file_path === $php_path ) { $found_location = rtrim( $location, '/' ) . '/'; break 2; diff --git a/tests/phpunit/tests/l10n/loadTextdomainJustInTime.php b/tests/phpunit/tests/l10n/loadTextdomainJustInTime.php index af8bb8825ac9e..ebf7dfc6da47d 100644 --- a/tests/phpunit/tests/l10n/loadTextdomainJustInTime.php +++ b/tests/phpunit/tests/l10n/loadTextdomainJustInTime.php @@ -372,4 +372,72 @@ public function test_plugin_translation_should_be_translated_when_calling_load_p $this->assertSame( 'Das ist ein Dummy Plugin', $output_after ); $this->assertTrue( $is_textdomain_loaded_after ); } + + /** + * Text domains that merely share a prefix with a translated one must not be + * treated as translated themselves. + * + * "internationalized-plugin-de_DE.mo" exists, but there is no + * "internationalized-de_DE.mo", so the "internationalized" text domain has no + * translations at all. + * + * @ticket 62348 + * + * @covers ::_load_textdomain_just_in_time + * @covers ::is_textdomain_loaded + */ + public function test_text_domain_sharing_a_prefix_with_a_translated_one_is_not_translated() { + add_filter( 'locale', array( $this, 'filter_set_locale_to_german' ) ); + + $actual = __( 'This is a dummy plugin', 'internationalized' ); + + remove_filter( 'locale', array( $this, 'filter_set_locale_to_german' ) ); + + $this->assertFalse( + is_textdomain_loaded( 'internationalized' ), + 'The "internationalized" text domain should not be considered loaded' + ); + $this->assertSame( + 'This is a dummy plugin', + $actual, + 'A text domain sharing a prefix with a translated one should not be translated' + ); + } + + /** + * Calling load_plugin_textdomain() after translations have already been loaded + * for one locale and missed for another must not stop just-in-time loading. + * + * Since 6.7.0 load_plugin_textdomain() only registers a custom path and leaves + * the loading to _load_textdomain_just_in_time(), which bails out early when + * WP_Textdomain_Registry::has() returns false. + * + * @ticket 62348 + * + * @covers ::_load_textdomain_just_in_time + * @covers ::load_plugin_textdomain + */ + public function test_plugin_translations_survive_a_late_load_plugin_textdomain_call() { + require_once DIR_TESTDATA . '/plugins/internationalized-plugin.php'; + + // de_DE translations are found in the WordPress languages directory. + switch_to_locale( 'de_DE' ); + $before = i18n_plugin_test(); + + // A locale without any translations for this plugin is used in between. + switch_to_locale( 'ja_JP' ); + $untranslated = i18n_plugin_test(); + + // Only now does the plugin register its own languages directory. + load_plugin_textdomain( 'internationalized-plugin', false, 'internationalized-plugin/languages' ); + + restore_previous_locale(); + $after = i18n_plugin_test(); + + restore_current_locale(); + + $this->assertSame( 'Das ist ein Dummy Plugin', $before, 'de_DE translations should be loaded up front' ); + $this->assertSame( 'This is a dummy plugin', $untranslated, 'There should be no ja_JP translations' ); + $this->assertSame( 'Das ist ein Dummy Plugin', $after, 'de_DE translations should survive load_plugin_textdomain()' ); + } } diff --git a/tests/phpunit/tests/l10n/wpTextdomainRegistry.php b/tests/phpunit/tests/l10n/wpTextdomainRegistry.php index f5a12ff779dde..1402a86ce0ad4 100644 --- a/tests/phpunit/tests/l10n/wpTextdomainRegistry.php +++ b/tests/phpunit/tests/l10n/wpTextdomainRegistry.php @@ -23,6 +23,7 @@ public function tear_down() { wp_cache_delete( md5( WP_LANG_DIR . '/plugins/' ), 'translation_files' ); wp_cache_delete( md5( WP_LANG_DIR . '/themes/' ), 'translation_files' ); wp_cache_delete( md5( WP_LANG_DIR . '/' ), 'translation_files' ); + wp_cache_delete( md5( WP_PLUGIN_DIR . '/custom-internationalized-plugin/languages/' ), 'translation_files' ); parent::tear_down(); } @@ -150,6 +151,172 @@ public function test_invalidate_mo_files_cache() { $this->assertFalse( wp_cache_get( md5( WP_LANG_DIR . '/' ), 'translation_files' ) ); } + /** + * The registry answers "yes" for a text domain it has never looked up, + * so that _load_textdomain_just_in_time() gets a chance to resolve it. + * + * @ticket 62348 + * + * @covers ::has + */ + public function test_has_returns_true_for_unknown_text_domain() { + $this->assertTrue( $this->instance->has( 'unknown-plugin' ) ); + } + + /** + * A lookup that found nothing still records the (negative) result for the + * current locale, which keeps has() truthy. + * + * @ticket 62348 + * + * @covers ::has + * @covers ::get + */ + public function test_has_returns_true_after_unsuccessful_lookup() { + $this->assertFalse( + $this->instance->get( 'unknown-plugin', 'de_DE' ), + 'A text domain without translations should not resolve to a path' + ); + $this->assertTrue( + $this->instance->has( 'unknown-plugin' ), + 'The negative result for the current locale should still be reported as available' + ); + } + + /** + * Registering a custom path late must not make previously found translations + * unreachable. + * + * load_plugin_textdomain() and load_theme_textdomain() only register a custom + * path and hand the actual loading off to _load_textdomain_just_in_time(), + * which bails early when has() returns false. + * + * @ticket 62348 + * + * @covers ::has + * @covers ::set_custom_path + */ + public function test_has_after_custom_path_is_registered_following_a_successful_lookup() { + // A first locale resolves to the WordPress languages directory. + $this->assertSame( + WP_LANG_DIR . '/plugins/', + $this->instance->get( 'internationalized-plugin', 'de_DE' ), + 'de_DE translations should be found in the WordPress languages directory' + ); + + // A second locale has no translations at all, so 'current' becomes false. + $this->assertFalse( + $this->instance->get( 'internationalized-plugin', 'fr_FR' ), + 'There should be no fr_FR translations' + ); + + // Only now does the plugin call load_plugin_textdomain(). + $this->instance->set_custom_path( + 'internationalized-plugin', + WP_PLUGIN_DIR . '/custom-internationalized-plugin/languages' + ); + + $this->assertTrue( + $this->instance->has( 'internationalized-plugin' ), + 'Registering a custom path should not hide the already known translations' + ); + $this->assertSame( + WP_LANG_DIR . '/plugins/', + $this->instance->get( 'internationalized-plugin', 'de_DE' ), + 'de_DE translations should still be found after registering a custom path' + ); + } + + /** + * Same as above, except that no locale ever resolved, so there is nothing + * left to remember once the negative results have been discarded. + * + * @ticket 62348 + * + * @covers ::has + * @covers ::set_custom_path + */ + public function test_has_after_custom_path_is_registered_following_an_unsuccessful_lookup() { + $this->assertFalse( + $this->instance->get( 'unknown-plugin', 'de_DE' ), + 'There should be no de_DE translations' + ); + + $this->instance->set_custom_path( + 'unknown-plugin', + WP_PLUGIN_DIR . '/custom-internationalized-plugin/languages' + ); + + $this->assertTrue( + $this->instance->has( 'unknown-plugin' ), + 'The newly registered custom path should be given a chance' + ); + } + + /** + * Text domains are matched in full, not by prefix. + * + * "internationalized-plugin-de_DE.mo" must not count as a translation for the + * "internationalized" text domain just because the file name starts with it. + * + * @ticket 62348 + * + * @covers ::get + * @covers ::has + * @dataProvider data_text_domains_sharing_a_prefix + * + * @param string $domain Text domain that has no translations of its own. + * @param string $locale Locale to look up. + */ + public function test_translations_are_not_shared_between_text_domains_with_a_common_prefix( $domain, $locale ) { + $this->assertFalse( + $this->instance->get( $domain, $locale ), + 'A text domain sharing a prefix with a translated one should not resolve to a path' + ); + } + + /** + * Data provider. + * + * @return array[] + */ + public function data_text_domains_sharing_a_prefix() { + return array( + // "internationalized-plugin-{de_DE,es_ES}.mo" exist, "internationalized-*" do not. + 'prefix of a domain with .mo files' => array( 'internationalized', 'de_DE' ), + 'prefix of a domain with .mo files, es' => array( 'internationalized', 'es_ES' ), + // "internationalized-plugin-2-de_DE.l10n.php" exists, but is not a + // translation of "internationalized-plugin". + 'domain whose sibling adds a suffix' => array( 'internationalized-plugin', 'fr_FR' ), + ); + } + + /** + * Once a custom path is registered, the domain must stay resolvable even when + * an unrelated text domain shares its prefix. + * + * @ticket 62348 + * + * @covers ::has + * @covers ::set_custom_path + */ + public function test_has_with_custom_path_is_unaffected_by_text_domains_sharing_a_prefix() { + $this->assertFalse( + $this->instance->get( 'internationalized', 'de_DE' ), + 'The "internationalized" text domain has no translations of its own' + ); + + $this->instance->set_custom_path( + 'internationalized', + WP_PLUGIN_DIR . '/custom-internationalized-plugin/languages' + ); + + $this->assertTrue( + $this->instance->has( 'internationalized' ), + 'The newly registered custom path should be given a chance' + ); + } + public function data_domains_locales() { return array( 'Non-existent plugin' => array( From f578e49092fa8516f158047257166ffc5e0c8eba Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 12:28:11 +0000 Subject: [PATCH 016/363] Administration: Improve consistency of the Dashboard widgets when JavaScript support is disabled. - Hides the Site Health Status widget when JS is off. - Your Recent Drafts: Always show a message when there are no recent drafts. Developed in https://github.com/WordPress/wordpress-develop/pull/12677 Props abcd95, hbhalodia, mukesh27, afercia. Fixes #65692. git-svn-id: https://develop.svn.wordpress.org/trunk@63363 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/dashboard.css | 9 ++++++--- src/wp-admin/css/site-health.css | 4 ++++ src/wp-admin/includes/dashboard.php | 7 +++++-- 3 files changed, 15 insertions(+), 5 deletions(-) diff --git a/src/wp-admin/css/dashboard.css b/src/wp-admin/css/dashboard.css index 17a9e312b85c6..7b0d0fe01c493 100644 --- a/src/wp-admin/css/dashboard.css +++ b/src/wp-admin/css/dashboard.css @@ -792,7 +792,8 @@ body #dashboard-widgets .postbox form .submit { margin: 12px; } -#dashboard_quick_press .drafts { +#dashboard_quick_press .drafts, +#dashboard_quick_press .no-drafts { padding: 10px 0 0; } @@ -827,7 +828,8 @@ body #dashboard-widgets .postbox form .submit { /* Dashboard Quick Draft - Drafts list */ -.js #dashboard_quick_press .drafts { +.js #dashboard_quick_press .drafts, +.js #dashboard_quick_press .no-drafts { border-top: 1px solid #f0f0f1; } @@ -874,7 +876,8 @@ body #dashboard-widgets .postbox form .submit { #dashboard-widgets h4, /* Back-compat for pre-4.4 */ #dashboard-widgets h3, -#dashboard_quick_press .drafts h2 { +#dashboard_quick_press .drafts h2, +#dashboard_quick_press .no-drafts p { margin: 0 12px 8px; padding: 0; font-size: 14px; diff --git a/src/wp-admin/css/site-health.css b/src/wp-admin/css/site-health.css index cf6c24e4a955c..f43db18a84efe 100644 --- a/src/wp-admin/css/site-health.css +++ b/src/wp-admin/css/site-health.css @@ -296,6 +296,10 @@ are styled in the Privacy section of edit.css */ } /* Styling unique to the dashboard widget. */ +.no-js #dashboard_site_health { + display: none; +} + #dashboard_site_health .site-health-details { padding-left: 16px; } diff --git a/src/wp-admin/includes/dashboard.php b/src/wp-admin/includes/dashboard.php index 7a78025214f10..488e01aa92481 100644 --- a/src/wp-admin/includes/dashboard.php +++ b/src/wp-admin/includes/dashboard.php @@ -656,6 +656,9 @@ function wp_dashboard_recent_drafts( $drafts = false ) { $drafts = get_posts( $query_args ); if ( ! $drafts ) { + echo '
    '; + echo '

    ' . __( 'There are no recent drafts.' ) . '

    '; + echo '
    '; return; } } @@ -1372,7 +1375,7 @@ function wp_dashboard_events_news() { * @since 4.8.0 */ function wp_print_community_events_markup() { - $community_events_notice = '

    ' . __( 'This widget requires JavaScript.' ) . '

    '; + $community_events_notice = '

    ' . __( 'The WordPress Events and News feeds require JavaScript.' ) . '

    '; $community_events_notice .= ''; $community_events_notice .= ''; @@ -1998,7 +2001,7 @@ function wp_dashboard_site_health() { $issues_total = $issue_counts['recommended'] + $issue_counts['critical']; ?>
    -
    +
    with

    HEADING

    ', 'expected' => array( 1, 2, 0 ), diff --git a/tests/phpunit/tests/functions/wpParseList.php b/tests/phpunit/tests/functions/wpParseList.php index e7bcce248ce85..42edfe3df45f2 100644 --- a/tests/phpunit/tests/functions/wpParseList.php +++ b/tests/phpunit/tests/functions/wpParseList.php @@ -14,7 +14,7 @@ class Tests_Functions_wpParseList extends WP_UnitTestCase { * * @dataProvider data_wp_parse_list * - * @param mixed[]|string $input_list + * @param mixed[]|string|int $input_list * @param array $expected */ public function test_wp_parse_list( $input_list, array $expected ): void { @@ -35,7 +35,7 @@ public function test_wp_parse_list( $input_list, array $expected ): void { /** * Data provider. * - * @return array }> + * @return array }> */ public function data_wp_parse_list(): array { return array( @@ -83,6 +83,22 @@ public function data_wp_parse_list(): array { 'input_list' => ',,', 'expected' => array(), ), + 'positive int' => array( + 'input_list' => 5, + 'expected' => array( '5' ), + ), + 'negative int' => array( + 'input_list' => -5, + 'expected' => array( '-5' ), + ), + 'zero' => array( + 'input_list' => 0, + 'expected' => array( '0' ), + ), + 'comma in array item' => array( + 'input_list' => array( '1,2' ), + 'expected' => array( '1,2' ), + ), 'passed scalar array' => array( 'input_list' => array( 'foo', true, false, 1, 3.14 ), 'expected' => array( 'foo', true, false, 1, 3.14 ), diff --git a/tests/phpunit/tests/functions/wpParseSlugList.php b/tests/phpunit/tests/functions/wpParseSlugList.php index d103bab4309b8..bdb6d2cdc7f49 100644 --- a/tests/phpunit/tests/functions/wpParseSlugList.php +++ b/tests/phpunit/tests/functions/wpParseSlugList.php @@ -16,7 +16,7 @@ class Tests_Functions_WpParseSlugList extends WP_UnitTestCase { * @dataProvider data_wp_parse_slug_list * @dataProvider data_unexpected_input * - * @param mixed[]|string $input_list + * @param mixed[]|string|int $input_list * @param array $expected */ public function test_wp_parse_slug_list( $input_list, array $expected ): void { @@ -37,7 +37,7 @@ public function test_wp_parse_slug_list( $input_list, array $expected ): void { /** * Data provider. * - * @return array }> + * @return array }> */ public function data_wp_parse_slug_list(): array { return array( @@ -75,6 +75,18 @@ public function data_wp_parse_slug_list(): array { 'input_list' => array( 'apple ', 'banana carrot', 'd o g' ), 'expected' => array( 'apple', 'banana-carrot', 'd-o-g' ), ), + 'positive int' => array( + 'input_list' => 5, + 'expected' => array( '5' ), + ), + 'negative int' => array( + 'input_list' => -5, + 'expected' => array( '5' ), + ), + 'zero' => array( + 'input_list' => 0, + 'expected' => array( '0' ), + ), 'passed assoc array' => array( 'input_list' => array( 'one' => 'foo', @@ -93,7 +105,7 @@ public function data_wp_parse_slug_list(): array { /** * Data provider. * - * @return array }> + * @return array }> */ public function data_unexpected_input(): array { return array( From c590bda3977b1f785b638c42ed0c504913e6ba01 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 27 Aug 2026 19:45:27 +0000 Subject: [PATCH 020/363] Code Quality: Narrow `$upgrader` type in upgrader skins. Each `WP_Upgrader_Skin` subclass is only ever constructed with one specific upgrader, but `$upgrader` was declared only on the parent as `WP_Upgrader`. Static analysis therefore flagged the subclass-specific calls to `Plugin_Upgrader::plugin_info()`, `Theme_Upgrader::theme_info()` and `Language_Pack_Upgrader::get_name_for_update()` as calls to undefined methods. Redeclaring the property in `Language_Pack_Upgrader_Skin`, `Plugin_Upgrader_Skin`, `Plugin_Installer_Skin`, `Theme_Upgrader_Skin` and `Theme_Installer_Skin` with its narrower type documents what was already true at runtime. The `@since` tag on each redeclaration is the version in which that skin class was introduced rather than the current release, since the property has always been available by inheritance and is not newly added here. With those five occurrences resolved, `tests/phpstan/baselines/method.notFound.neon` is empty and is removed along with its `includes` entry in `phpstan.neon.dist`, and two entries in `property.notFound.neon` that no longer match are dropped. Developed in https://github.com/WordPress/wordpress-develop/pull/13283. Follow-up to r63020. Props nathanrice, westonruter. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63367 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 1 - .../class-language-pack-upgrader-skin.php | 8 ++++ .../includes/class-plugin-installer-skin.php | 8 ++++ .../includes/class-plugin-upgrader-skin.php | 7 +++ .../includes/class-theme-installer-skin.php | 8 ++++ .../includes/class-theme-upgrader-skin.php | 8 ++++ tests/phpstan/baselines/method.notFound.neon | 45 ------------------- .../phpstan/baselines/property.notFound.neon | 10 ----- 8 files changed, 39 insertions(+), 56 deletions(-) delete mode 100644 tests/phpstan/baselines/method.notFound.neon diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 1416704909f34..5766f8a98a6b0 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -57,7 +57,6 @@ includes: - tests/phpstan/baselines/isset.property.neon - tests/phpstan/baselines/method.childParameterType.neon - tests/phpstan/baselines/method.nonObject.neon - - tests/phpstan/baselines/method.notFound.neon - tests/phpstan/baselines/method.unused.neon - tests/phpstan/baselines/notIdentical.alwaysTrue.neon - tests/phpstan/baselines/nullCoalesce.offset.neon diff --git a/src/wp-admin/includes/class-language-pack-upgrader-skin.php b/src/wp-admin/includes/class-language-pack-upgrader-skin.php index b93ed6c8bc32e..be2c7caabed3a 100644 --- a/src/wp-admin/includes/class-language-pack-upgrader-skin.php +++ b/src/wp-admin/includes/class-language-pack-upgrader-skin.php @@ -16,6 +16,14 @@ * @see WP_Upgrader_Skin */ class Language_Pack_Upgrader_Skin extends WP_Upgrader_Skin { + /** + * The upgrader instance. + * + * @since 3.7.0 + * @var Language_Pack_Upgrader + */ + public $upgrader; + public $language_update = null; public $done_header = false; public $done_footer = false; diff --git a/src/wp-admin/includes/class-plugin-installer-skin.php b/src/wp-admin/includes/class-plugin-installer-skin.php index 13b4dd7097cc9..ecfb1f7bd59b5 100644 --- a/src/wp-admin/includes/class-plugin-installer-skin.php +++ b/src/wp-admin/includes/class-plugin-installer-skin.php @@ -16,6 +16,14 @@ * @see WP_Upgrader_Skin */ class Plugin_Installer_Skin extends WP_Upgrader_Skin { + /** + * The upgrader instance. + * + * @since 2.8.0 + * @var Plugin_Upgrader + */ + public $upgrader; + public $api; public $type; public $url; diff --git a/src/wp-admin/includes/class-plugin-upgrader-skin.php b/src/wp-admin/includes/class-plugin-upgrader-skin.php index 0e3e778360061..1505e3d3a4977 100644 --- a/src/wp-admin/includes/class-plugin-upgrader-skin.php +++ b/src/wp-admin/includes/class-plugin-upgrader-skin.php @@ -16,6 +16,13 @@ * @see WP_Upgrader_Skin */ class Plugin_Upgrader_Skin extends WP_Upgrader_Skin { + /** + * The upgrader instance. + * + * @since 2.8.0 + * @var Plugin_Upgrader + */ + public $upgrader; /** * Holds the plugin slug in the Plugin Directory. diff --git a/src/wp-admin/includes/class-theme-installer-skin.php b/src/wp-admin/includes/class-theme-installer-skin.php index 70f3452606fdd..bd320ccb401c2 100644 --- a/src/wp-admin/includes/class-theme-installer-skin.php +++ b/src/wp-admin/includes/class-theme-installer-skin.php @@ -16,6 +16,14 @@ * @see WP_Upgrader_Skin */ class Theme_Installer_Skin extends WP_Upgrader_Skin { + /** + * The upgrader instance. + * + * @since 2.8.0 + * @var Theme_Upgrader + */ + public $upgrader; + public $api; public $type; public $url; diff --git a/src/wp-admin/includes/class-theme-upgrader-skin.php b/src/wp-admin/includes/class-theme-upgrader-skin.php index cd4c6c6db3b40..e8c60f5f57da7 100644 --- a/src/wp-admin/includes/class-theme-upgrader-skin.php +++ b/src/wp-admin/includes/class-theme-upgrader-skin.php @@ -17,6 +17,14 @@ */ class Theme_Upgrader_Skin extends WP_Upgrader_Skin { + /** + * The upgrader instance. + * + * @since 2.8.0 + * @var Theme_Upgrader + */ + public $upgrader; + /** * Holds the theme slug in the Theme Directory. * diff --git a/tests/phpstan/baselines/method.notFound.neon b/tests/phpstan/baselines/method.notFound.neon deleted file mode 100644 index 5d6bccb070ecb..0000000000000 --- a/tests/phpstan/baselines/method.notFound.neon +++ /dev/null @@ -1,45 +0,0 @@ -# PHPStan baseline for the `method.notFound` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/method.notFound -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=method.notFound -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^Call to an undefined method WP_Upgrader\:\:get_name_for_update\(\)\.$#' - identifier: method.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-language-pack-upgrader-skin.php - - - message: '#^Call to an undefined method WP_Upgrader\:\:plugin_info\(\)\.$#' - identifier: method.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-plugin-installer-skin.php - - - message: '#^Call to an undefined method WP_Upgrader\:\:plugin_info\(\)\.$#' - identifier: method.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-plugin-upgrader-skin.php - - - message: '#^Call to an undefined method WP_Upgrader\:\:theme_info\(\)\.$#' - identifier: method.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-theme-installer-skin.php - - - message: '#^Call to an undefined method WP_Upgrader\:\:theme_info\(\)\.$#' - identifier: method.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-theme-upgrader-skin.php diff --git a/tests/phpstan/baselines/property.notFound.neon b/tests/phpstan/baselines/property.notFound.neon index 7893a2dd24bb6..b8e86ff092bc7 100644 --- a/tests/phpstan/baselines/property.notFound.neon +++ b/tests/phpstan/baselines/property.notFound.neon @@ -23,11 +23,6 @@ parameters: identifier: property.notFound count: 2 path: ../../../src/wp-admin/includes/class-language-pack-upgrader.php - - - message: '#^Access to an undefined property WP_Upgrader\:\:\$new_plugin_data\.$#' - identifier: property.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-plugin-installer-skin.php - message: '#^Access to an undefined property WP_Upgrader_Skin\:\:\$plugin_active\.$#' identifier: property.notFound @@ -38,11 +33,6 @@ parameters: identifier: property.notFound count: 1 path: ../../../src/wp-admin/includes/class-plugin-upgrader.php - - - message: '#^Access to an undefined property WP_Upgrader\:\:\$new_theme_data\.$#' - identifier: property.notFound - count: 1 - path: ../../../src/wp-admin/includes/class-theme-installer-skin.php - message: '#^Access to an undefined property WP_Upgrader_Skin\:\:\$api\.$#' identifier: property.notFound From 759f0cb3cfc7ff240783330b7386a06172405d86 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 27 Aug 2026 20:02:54 +0000 Subject: [PATCH 021/363] Code Quality: Call private static methods via `self::`. The classes `WP_Classic_To_Block_Menu_Converter`, `WP_Navigation_Fallback`, `WP_Theme_JSON_Resolver`, and `WP_Font_Face_Resolver` reached their own private static helpers through `static::`. Late static binding is problematic here. Because the helpers are private they are not an extension point, yet `static::` still resolves against the called class, so a subclass that declares a method of the same name either hijacks the call when that method is protected or public, or triggers a fatal error when it is private. With `self::` the binding of the call goes to the declaring class, which is what the visibility already promises. In practice the resolution is unchanged, since core always invokes these classes by their own name and none of them is subclassed in core. Only calls to private methods are converted; `static::` is retained where it targets a protected or public member and late static binding is meaningful. This clears the 20 remaining `staticClassAccess.privateMethod` entries, covering 26 call sites, from the PHPStan baseline. Developed in https://github.com/WordPress/wordpress-develop/pull/13072. Follow-up to r63020. Props dpantazis, dhruvang21. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63368 602fd350-edb4-49c9-b593-d223f7449a82 --- ...ass-wp-classic-to-block-menu-converter.php | 6 +- .../class-wp-navigation-fallback.php | 20 ++-- .../class-wp-theme-json-resolver.php | 14 +-- .../fonts/class-wp-font-face-resolver.php | 12 +-- .../staticClassAccess.privateMethod.neon | 100 ------------------ 5 files changed, 26 insertions(+), 126 deletions(-) diff --git a/src/wp-includes/class-wp-classic-to-block-menu-converter.php b/src/wp-includes/class-wp-classic-to-block-menu-converter.php index a0b7d5075670a..ca46187991c7e 100644 --- a/src/wp-includes/class-wp-classic-to-block-menu-converter.php +++ b/src/wp-includes/class-wp-classic-to-block-menu-converter.php @@ -42,11 +42,11 @@ public static function convert( $menu ) { // Adds the class property classes for the current context, if applicable. _wp_menu_item_classes_by_context( $menu_items ); - $menu_items_by_parent_id = static::group_by_parent_id( $menu_items ); + $menu_items_by_parent_id = self::group_by_parent_id( $menu_items ); $first_menu_item = $menu_items_by_parent_id[0] ?? array(); - $inner_blocks = static::to_blocks( + $inner_blocks = self::to_blocks( $first_menu_item, $menu_items_by_parent_id ); @@ -117,7 +117,7 @@ private static function to_blocks( $menu_items, $menu_items_by_parent_id ) { ); $block['innerBlocks'] = isset( $menu_items_by_parent_id[ $menu_item->ID ] ) - ? static::to_blocks( $menu_items_by_parent_id[ $menu_item->ID ], $menu_items_by_parent_id ) + ? self::to_blocks( $menu_items_by_parent_id[ $menu_item->ID ], $menu_items_by_parent_id ) : array(); $block['innerContent'] = array_map( 'serialize_block', $block['innerBlocks'] ); diff --git a/src/wp-includes/class-wp-navigation-fallback.php b/src/wp-includes/class-wp-navigation-fallback.php index 573ab27f3489e..339fa58fc0ef8 100644 --- a/src/wp-includes/class-wp-navigation-fallback.php +++ b/src/wp-includes/class-wp-navigation-fallback.php @@ -77,24 +77,24 @@ public static function get_fallback() { */ $should_create_fallback = apply_filters( 'wp_navigation_should_create_fallback', true ); - $fallback = static::get_most_recently_published_navigation(); + $fallback = self::get_most_recently_published_navigation(); if ( $fallback || ! $should_create_fallback ) { return $fallback; } - $fallback = static::create_classic_menu_fallback(); + $fallback = self::create_classic_menu_fallback(); if ( $fallback && ! is_wp_error( $fallback ) ) { // Return the newly created fallback post object which will now be the most recently created navigation menu. - return $fallback instanceof WP_Post ? $fallback : static::get_most_recently_published_navigation(); + return $fallback instanceof WP_Post ? $fallback : self::get_most_recently_published_navigation(); } - $fallback = static::create_default_fallback(); + $fallback = self::create_default_fallback(); if ( $fallback && ! is_wp_error( $fallback ) ) { // Return the newly created fallback post object which will now be the most recently created navigation menu. - return $fallback instanceof WP_Post ? $fallback : static::get_most_recently_published_navigation(); + return $fallback instanceof WP_Post ? $fallback : self::get_most_recently_published_navigation(); } return null; @@ -138,7 +138,7 @@ private static function get_most_recently_published_navigation() { */ private static function create_classic_menu_fallback() { // See if we have a classic menu. - $classic_nav_menu = static::get_fallback_classic_menu(); + $classic_nav_menu = self::get_fallback_classic_menu(); if ( ! $classic_nav_menu ) { return new WP_Error( 'no_classic_menus', __( 'No Classic Menus found.' ) ); @@ -184,19 +184,19 @@ private static function get_fallback_classic_menu() { return null; } - $nav_menu = static::get_nav_menu_at_primary_location(); + $nav_menu = self::get_nav_menu_at_primary_location(); if ( $nav_menu ) { return $nav_menu; } - $nav_menu = static::get_nav_menu_with_primary_slug( $classic_nav_menus ); + $nav_menu = self::get_nav_menu_with_primary_slug( $classic_nav_menus ); if ( $nav_menu ) { return $nav_menu; } - return static::get_most_recently_created_nav_menu( $classic_nav_menus ); + return self::get_most_recently_created_nav_menu( $classic_nav_menus ); } @@ -269,7 +269,7 @@ private static function get_nav_menu_at_primary_location() { */ private static function create_default_fallback() { - $default_blocks = static::get_default_fallback_blocks(); + $default_blocks = self::get_default_fallback_blocks(); // Create a new navigation menu from the fallback blocks. $default_fallback = wp_insert_post( diff --git a/src/wp-includes/class-wp-theme-json-resolver.php b/src/wp-includes/class-wp-theme-json-resolver.php index 85124cf0e0cb6..b6c205bba03bd 100644 --- a/src/wp-includes/class-wp-theme-json-resolver.php +++ b/src/wp-includes/class-wp-theme-json-resolver.php @@ -279,8 +279,8 @@ public static function get_theme_data( $deprecated = array(), $options = array() * See test_add_registered_block_styles_to_theme_data and test_unwraps_block_style_variations. * */ - $theme_json_data = static::inject_variations_from_block_style_variation_files( $theme_json_data, $variations ); - $theme_json_data = static::inject_variations_from_block_styles_registry( $theme_json_data ); + $theme_json_data = self::inject_variations_from_block_style_variation_files( $theme_json_data, $variations ); + $theme_json_data = self::inject_variations_from_block_styles_registry( $theme_json_data ); /** * Filters the data provided by the theme for global styles and settings. @@ -400,7 +400,7 @@ public static function get_block_data() { $config = array( 'version' => WP_Theme_JSON::LATEST_SCHEMA ); foreach ( $blocks as $block_name => $block_type ) { if ( isset( $block_type->supports['__experimentalStyle'] ) ) { - $config['styles']['blocks'][ $block_name ] = static::remove_json_comments( $block_type->supports['__experimentalStyle'] ); + $config['styles']['blocks'][ $block_name ] = self::remove_json_comments( $block_type->supports['__experimentalStyle'] ); } if ( @@ -450,7 +450,7 @@ private static function remove_json_comments( $input_array ) { unset( $input_array['//'] ); foreach ( $input_array as $k => $v ) { if ( is_array( $v ) ) { - $input_array[ $k ] = static::remove_json_comments( $v ); + $input_array[ $k ] = self::remove_json_comments( $v ); } } @@ -805,10 +805,10 @@ public static function get_style_variations( $scope = 'theme' ) { $base_directory = get_stylesheet_directory() . '/styles'; $template_directory = get_template_directory() . '/styles'; if ( is_dir( $base_directory ) ) { - $variation_files = static::recursively_iterate_json( $base_directory ); + $variation_files = self::recursively_iterate_json( $base_directory ); } if ( is_dir( $template_directory ) && $template_directory !== $base_directory ) { - $variation_files_parent = static::recursively_iterate_json( $template_directory ); + $variation_files_parent = self::recursively_iterate_json( $template_directory ); // If the child and parent variation file basename are the same, only include the child theme's. foreach ( $variation_files_parent as $parent_path => $parent ) { foreach ( $variation_files as $child_path => $child ) { @@ -822,7 +822,7 @@ public static function get_style_variations( $scope = 'theme' ) { ksort( $variation_files ); foreach ( $variation_files as $path => $file ) { $decoded_file = self::read_json_file( $path ); - if ( is_array( $decoded_file ) && static::style_variation_has_scope( $decoded_file, $scope ) ) { + if ( is_array( $decoded_file ) && self::style_variation_has_scope( $decoded_file, $scope ) ) { $translated = static::translate( $decoded_file, wp_get_theme()->get( 'TextDomain' ) ); $variation = ( new WP_Theme_JSON( $translated ) )->get_raw_data(); if ( empty( $variation['title'] ) ) { diff --git a/src/wp-includes/fonts/class-wp-font-face-resolver.php b/src/wp-includes/fonts/class-wp-font-face-resolver.php index 153008b53aec0..f2da231ef058b 100644 --- a/src/wp-includes/fonts/class-wp-font-face-resolver.php +++ b/src/wp-includes/fonts/class-wp-font-face-resolver.php @@ -33,7 +33,7 @@ public static function get_fonts_from_theme_json() { return array(); } - return static::parse_settings( $settings ); + return self::parse_settings( $settings ); } /** @@ -65,7 +65,7 @@ public static function get_fonts_from_style_variations() { ), ); - return static::parse_settings( $settings ); + return self::parse_settings( $settings ); } /** @@ -92,14 +92,14 @@ private static function parse_settings( array $settings ) { continue; } - $font_family_name = static::maybe_parse_name_from_comma_separated_list( $definition['fontFamily'] ); + $font_family_name = self::maybe_parse_name_from_comma_separated_list( $definition['fontFamily'] ); // Skip if no font family is defined. if ( empty( $font_family_name ) ) { continue; } - $fonts[] = static::convert_font_face_properties( $definition['fontFace'], $font_family_name ); + $fonts[] = self::convert_font_face_properties( $definition['fontFace'], $font_family_name ); } } @@ -143,11 +143,11 @@ private static function convert_font_face_properties( array $font_face_definitio // Converts the "file:./" src placeholder into a theme font file URI. if ( ! empty( $font_face['src'] ) ) { - $font_face['src'] = static::to_theme_file_uri( (array) $font_face['src'] ); + $font_face['src'] = self::to_theme_file_uri( (array) $font_face['src'] ); } // Convert camelCase properties into kebab-case. - $font_face = static::to_kebab_case( $font_face ); + $font_face = self::to_kebab_case( $font_face ); $converted_font_faces[] = $font_face; } diff --git a/tests/phpstan/baselines/staticClassAccess.privateMethod.neon b/tests/phpstan/baselines/staticClassAccess.privateMethod.neon index c3a8969643a94..7e8a5c1cf59e1 100644 --- a/tests/phpstan/baselines/staticClassAccess.privateMethod.neon +++ b/tests/phpstan/baselines/staticClassAccess.privateMethod.neon @@ -18,81 +18,6 @@ parameters: ignoreErrors: - - - message: '#^Unsafe call to private method WP_Classic_To_Block_Menu_Converter\:\:group_by_parent_id\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-classic-to-block-menu-converter.php - - - message: '#^Unsafe call to private method WP_Classic_To_Block_Menu_Converter\:\:to_blocks\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/class-wp-classic-to-block-menu-converter.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:create_classic_menu_fallback\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:create_default_fallback\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:get_default_fallback_blocks\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:get_fallback_classic_menu\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:get_most_recently_created_nav_menu\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:get_most_recently_published_navigation\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 3 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:get_nav_menu_at_primary_location\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Navigation_Fallback\:\:get_nav_menu_with_primary_slug\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-navigation-fallback.php - - - message: '#^Unsafe call to private method WP_Theme_JSON_Resolver\:\:inject_variations_from_block_style_variation_files\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json-resolver.php - - - message: '#^Unsafe call to private method WP_Theme_JSON_Resolver\:\:inject_variations_from_block_styles_registry\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json-resolver.php - - - message: '#^Unsafe call to private method WP_Theme_JSON_Resolver\:\:recursively_iterate_json\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/class-wp-theme-json-resolver.php - - - message: '#^Unsafe call to private method WP_Theme_JSON_Resolver\:\:remove_json_comments\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/class-wp-theme-json-resolver.php - - - message: '#^Unsafe call to private method WP_Theme_JSON_Resolver\:\:style_variation_has_scope\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json-resolver.php - message: '#^Unsafe call to private method WP_Theme_JSON\:\:compute_spacing_sizes\(\) through static\:\:\.$#' identifier: staticClassAccess.privateMethod @@ -163,28 +88,3 @@ parameters: identifier: staticClassAccess.privateMethod count: 1 path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Font_Face_Resolver\:\:convert_font_face_properties\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/fonts/class-wp-font-face-resolver.php - - - message: '#^Unsafe call to private method WP_Font_Face_Resolver\:\:maybe_parse_name_from_comma_separated_list\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/fonts/class-wp-font-face-resolver.php - - - message: '#^Unsafe call to private method WP_Font_Face_Resolver\:\:parse_settings\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/fonts/class-wp-font-face-resolver.php - - - message: '#^Unsafe call to private method WP_Font_Face_Resolver\:\:to_kebab_case\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/fonts/class-wp-font-face-resolver.php - - - message: '#^Unsafe call to private method WP_Font_Face_Resolver\:\:to_theme_file_uri\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/fonts/class-wp-font-face-resolver.php From 2043dd639aacd4d21d19b17f20694d9a0f44f0e7 Mon Sep 17 00:00:00 2001 From: Aaron Jorbin Date: Thu, 27 Aug 2026 21:06:46 +0000 Subject: [PATCH 022/363] Media: Document PDF alpha channel return value. Document `WP_Image_Editor_Imagick::remove_pdf_alpha_channel()` as returning `null|WP_Error` and explicitly return null on success. Developed in: https://github.com/WordPress/wordpress-develop/pull/13200 Follow-up to r56271. Props mazharul78, westonruter. Fixes #65916. See #39216, #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63369 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-image-editor-imagick.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/wp-includes/class-wp-image-editor-imagick.php b/src/wp-includes/class-wp-image-editor-imagick.php index 57ed7c79e56ae..2ea329d2ce5a2 100644 --- a/src/wp-includes/class-wp-image-editor-imagick.php +++ b/src/wp-includes/class-wp-image-editor-imagick.php @@ -1085,6 +1085,8 @@ public function save( $destfilename = null, $mime_type = null ) { * Removes PDF alpha after it's been read. * * @since 6.4.0 + * + * @return null|WP_Error Null on success, WP_Error object if the alpha channel could not be removed. */ protected function remove_pdf_alpha_channel() { $version = Imagick::getVersion(); @@ -1097,6 +1099,8 @@ protected function remove_pdf_alpha_channel() { return new WP_Error( 'pdf_alpha_process_failed', $e->getMessage() ); } } + + return null; } /** From e85c9e4fbbcc21bfbb9ccfc57aa39e96c7d7acb8 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 21:44:20 +0000 Subject: [PATCH 023/363] Administration: Fix the CSS Coding Standards in color-picker.css. Lints the `src/wp-admin/css/color-picker.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13117 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63370 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/color-picker.css | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/css/color-picker.css b/src/wp-admin/css/color-picker.css index 8264432dd39cc..2c66a2cfcfac4 100644 --- a/src/wp-admin/css/color-picker.css +++ b/src/wp-admin/css/color-picker.css @@ -34,8 +34,8 @@ color: #1d2327; } -.wp-color-result:hover:after, -.wp-color-result:focus:after { +.wp-color-result:hover::after, +.wp-color-result:focus::after { color: #1d2327; border-color: #a7aaad; border-left: 1px solid #8c8f94; @@ -81,7 +81,7 @@ } .wp-picker-container .iris-square-slider .ui-slider-handle:focus { - background-color: #50575e + background-color: #50575e; } .wp-picker-container .iris-picker { From 758610d87cce372049a8a6a9685d993092373526 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 21:49:04 +0000 Subject: [PATCH 024/363] Administration: Fix the CSS Coding Standards in farbtastic.css. Lints the `src/wp-admin/css/farbtastic.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13138 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63371 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/farbtastic.css | 37 ++++++++++++++++----------------- 1 file changed, 18 insertions(+), 19 deletions(-) diff --git a/src/wp-admin/css/farbtastic.css b/src/wp-admin/css/farbtastic.css index 2bb73bfc7ce8b..bc3232c1a24dc 100644 --- a/src/wp-admin/css/farbtastic.css +++ b/src/wp-admin/css/farbtastic.css @@ -1,41 +1,40 @@ - .farbtastic { - position: relative; + position: relative; } .farbtastic * { - position: absolute; - cursor: crosshair; + position: absolute; + cursor: crosshair; } .farbtastic, .farbtastic .wheel { - width: 195px; - height: 195px; + width: 195px; + height: 195px; } .farbtastic .color, .farbtastic .overlay { - top: 47px; - left: 47px; - width: 101px; - height: 101px; + top: 47px; + left: 47px; + width: 101px; + height: 101px; } .farbtastic .wheel { - background: url(../images/wheel.png) no-repeat; - width: 195px; - height: 195px; + background: url(../images/wheel.png) no-repeat; + width: 195px; + height: 195px; } .farbtastic .overlay { - background: url(../images/mask.png) no-repeat; + background: url(../images/mask.png) no-repeat; } .farbtastic .marker { - width: 17px; - height: 17px; - margin: -8px 0 0 -8px; - overflow: hidden; - background: url(../images/marker.png) no-repeat; + width: 17px; + height: 17px; + margin: -8px 0 0 -8px; + overflow: hidden; + background: url(../images/marker.png) no-repeat; } From 061804d5656fd686d1214f7d890b8a9edbaa49dd Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 21:51:34 +0000 Subject: [PATCH 025/363] Administration: Fix the CSS Coding Standards in site-icon.css. Lints the `src/wp-admin/css/site-icon.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13148 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63372 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/site-icon.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-admin/css/site-icon.css b/src/wp-admin/css/site-icon.css index 93f36f093caf9..6783574249f5e 100644 --- a/src/wp-admin/css/site-icon.css +++ b/src/wp-admin/css/site-icon.css @@ -79,7 +79,7 @@ gap: 16px; } -.site-icon-preview:after { +.site-icon-preview::after { --after-size: 150%; aspect-ratio: 1/1; content: ""; @@ -87,7 +87,7 @@ position: absolute; top: 0; left: 0; - width: var(--after-size);; + width: var(--after-size); transform: translate(calc(var(--after-size) * -0.125), calc(var(--after-size) * -0.125)); filter: blur(5px); opacity: 0.5; From 14a99630395d5f23dc7519da47f1bff71c552bcc Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 21:54:20 +0000 Subject: [PATCH 026/363] Administration: Fix the CSS Coding Standards in classic-themes.css. Lints the `src/wp-includes/css/classic-themes.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13160 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63373 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/classic-themes.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-includes/css/classic-themes.css b/src/wp-includes/css/classic-themes.css index 4d54a1891ec52..c52bbc1e80cab 100644 --- a/src/wp-includes/css/classic-themes.css +++ b/src/wp-includes/css/classic-themes.css @@ -3,7 +3,7 @@ * They should match the button element rules in the base theme.json file. */ .wp-block-button__link { - color: #ffffff; + color: #fff; background-color: #32373c; border-radius: 9999px; /* 100% causes an oval, but any explicit but really high value retains the pill shape. */ @@ -19,6 +19,6 @@ .wp-block-file__button { background: #32373c; - color: #ffffff; + color: #fff; text-decoration: none; } From e18f2f71f0e3027fb6f8c2a8fd6b8c768f7279d5 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 21:57:42 +0000 Subject: [PATCH 027/363] Administration: Fix the CSS Coding Standards in wp-auth-check.css. Lints the `src/wp-includes/css/wp-auth-check.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13167 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63374 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/wp-auth-check.css | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/src/wp-includes/css/wp-auth-check.css b/src/wp-includes/css/wp-auth-check.css index 314ba615f1482..904dbab4fe9c5 100644 --- a/src/wp-includes/css/wp-auth-check.css +++ b/src/wp-includes/css/wp-auth-check.css @@ -53,7 +53,7 @@ -webkit-overflow-scrolling: touch; } -#wp-auth-check-form.loading:before { +#wp-auth-check-form.loading::before { content: ""; display: block; width: 20px; @@ -68,9 +68,8 @@ } @media print, - (min-resolution: 120dpi) { - - #wp-auth-check-form.loading:before { + (min-resolution: 120dpi) { + #wp-auth-check-form.loading::before { background-image: url(../images/spinner-2x.gif); } @@ -92,10 +91,10 @@ text-align: center; } -#wp-auth-check-wrap .wp-auth-check-close:before { +#wp-auth-check-wrap .wp-auth-check-close::before { content: "\f158"; - content: "\f158" / ''; - font: normal 20px/22px dashicons; + content: "\f158" / ""; + font: 400 20px/22px dashicons; -webkit-font-smoothing: antialiased !important; -moz-osx-font-smoothing: grayscale; } From a04367d6cb56d5d1bb0e66fbf4eae1d0639c0a0c Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 22:03:47 +0000 Subject: [PATCH 028/363] Administration: Fix the CSS Coding Standards in wp-embed-template.css. Lints the `src/wp-includes/css/wp-embed-template.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13169 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63375 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/wp-embed-template.css | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/src/wp-includes/css/wp-embed-template.css b/src/wp-includes/css/wp-embed-template.css index 9bf606589a773..6e2f8aac43a7b 100644 --- a/src/wp-includes/css/wp-embed-template.css +++ b/src/wp-includes/css/wp-embed-template.css @@ -1,4 +1,5 @@ -html, body { +html, +body { padding: 0; margin: 0; } @@ -31,25 +32,25 @@ body { background-repeat: no-repeat; background-size: 20px; background-position: center; - transition: background .1s ease-in; + transition: background 0.1s ease-in; position: relative; top: 5px; } .dashicons-no { - background-image: url("data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M15.55%2013.7l-2.19%202.06-3.42-3.65-3.64%203.43-2.06-2.18%203.64-3.43-3.42-3.64%202.18-2.06%203.43%203.64%203.64-3.42%202.05%202.18-3.64%203.43z%27%20fill%3D%27%23fff%27%2F%3E%3C%2Fsvg%3E"); + background-image: url(data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M15.55%2013.7l-2.19%202.06-3.42-3.65-3.64%203.43-2.06-2.18%203.64-3.43-3.42-3.64%202.18-2.06%203.43%203.64%203.64-3.42%202.05%202.18-3.64%203.43z%27%20fill%3D%27%23fff%27%2F%3E%3C%2Fsvg%3E); } .dashicons-admin-comments { - background-image: url("data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M5%202h9q.82%200%201.41.59T16%204v7q0%20.82-.59%201.41T14%2013h-2l-5%205v-5H5q-.82%200-1.41-.59T3%2011V4q0-.82.59-1.41T5%202z%27%20fill%3D%27%23646970%27%2F%3E%3C%2Fsvg%3E"); + background-image: url(data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M5%202h9q.82%200%201.41.59T16%204v7q0%20.82-.59%201.41T14%2013h-2l-5%205v-5H5q-.82%200-1.41-.59T3%2011V4q0-.82.59-1.41T5%202z%27%20fill%3D%27%23646970%27%2F%3E%3C%2Fsvg%3E); } .wp-embed-comments a:hover .dashicons-admin-comments { - background-image: url("data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M5%202h9q.82%200%201.41.59T16%204v7q0%20.82-.59%201.41T14%2013h-2l-5%205v-5H5q-.82%200-1.41-.59T3%2011V4q0-.82.59-1.41T5%202z%27%20fill%3D%27%23135e96%27%2F%3E%3C%2Fsvg%3E"); + background-image: url(data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M5%202h9q.82%200%201.41.59T16%204v7q0%20.82-.59%201.41T14%2013h-2l-5%205v-5H5q-.82%200-1.41-.59T3%2011V4q0-.82.59-1.41T5%202z%27%20fill%3D%27%23135e96%27%2F%3E%3C%2Fsvg%3E); } .dashicons-share { - background-image: url("data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.5%2012q1.24%200%202.12.88T17.5%2015t-.88%202.12-2.12.88-2.12-.88T11.5%2015q0-.34.09-.69l-4.38-2.3Q6.32%2013%205%2013q-1.24%200-2.12-.88T2%2010t.88-2.12T5%207q1.3%200%202.21.99l4.38-2.3q-.09-.35-.09-.69%200-1.24.88-2.12T14.5%202t2.12.88T17.5%205t-.88%202.12T14.5%208q-1.3%200-2.21-.99l-4.38%202.3Q8%209.66%208%2010t-.09.69l4.38%202.3q.89-.99%202.21-.99z%27%20fill%3D%27%23646970%27%2F%3E%3C%2Fsvg%3E"); + background-image: url(data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.5%2012q1.24%200%202.12.88T17.5%2015t-.88%202.12-2.12.88-2.12-.88T11.5%2015q0-.34.09-.69l-4.38-2.3Q6.32%2013%205%2013q-1.24%200-2.12-.88T2%2010t.88-2.12T5%207q1.3%200%202.21.99l4.38-2.3q-.09-.35-.09-.69%200-1.24.88-2.12T14.5%202t2.12.88T17.5%205t-.88%202.12T14.5%208q-1.3%200-2.21-.99l-4.38%202.3Q8%209.66%208%2010t-.09.69l4.38%202.3q.89-.99%202.21-.99z%27%20fill%3D%27%23646970%27%2F%3E%3C%2Fsvg%3E); display: none; } @@ -58,7 +59,7 @@ body { } .wp-embed-share-dialog-open:hover .dashicons-share { - background-image: url("data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.5%2012q1.24%200%202.12.88T17.5%2015t-.88%202.12-2.12.88-2.12-.88T11.5%2015q0-.34.09-.69l-4.38-2.3Q6.32%2013%205%2013q-1.24%200-2.12-.88T2%2010t.88-2.12T5%207q1.3%200%202.21.99l4.38-2.3q-.09-.35-.09-.69%200-1.24.88-2.12T14.5%202t2.12.88T17.5%205t-.88%202.12T14.5%208q-1.3%200-2.21-.99l-4.38%202.3Q8%209.66%208%2010t-.09.69l4.38%202.3q.89-.99%202.21-.99z%27%20fill%3D%27%23135e96%27%2F%3E%3C%2Fsvg%3E"); + background-image: url(data:image/svg+xml;charset=utf8,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2020%2020%27%3E%3Cpath%20d%3D%27M14.5%2012q1.24%200%202.12.88T17.5%2015t-.88%202.12-2.12.88-2.12-.88T11.5%2015q0-.34.09-.69l-4.38-2.3Q6.32%2013%205%2013q-1.24%200-2.12-.88T2%2010t.88-2.12T5%207q1.3%200%202.21.99l4.38-2.3q-.09-.35-.09-.69%200-1.24.88-2.12T14.5%202t2.12.88T17.5%205t-.88%202.12T14.5%208q-1.3%200-2.21-.99l-4.38%202.3Q8%209.66%208%2010t-.09.69l4.38%202.3q.89-.99%202.21-.99z%27%20fill%3D%27%23135e96%27%2F%3E%3C%2Fsvg%3E); } .wp-embed { @@ -188,7 +189,7 @@ p.wp-embed-heading { background-color: rgba(0, 0, 0, 0.9); color: #fff; opacity: 1; - transition: opacity .25s ease-in-out; + transition: opacity 0.25s ease-in-out; } .wp-embed-share-dialog.hidden { @@ -270,7 +271,7 @@ p.wp-embed-heading { line-height: 1.3; color: #a7aaad; cursor: pointer; - transition: color .1s ease-in; + transition: color 0.1s ease-in; } .wp-embed-share-tab-button [aria-selected="true"] { From 95373996e7a68b77d145ecdc7537e9448f3dddfc Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 22:07:25 +0000 Subject: [PATCH 029/363] Administration: Fix the CSS Coding Standards in wp-empty-template-alert.css. Lints the `src/wp-includes/css/wp-empty-template-alert.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13170 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63376 602fd350-edb4-49c9-b593-d223f7449a82 --- .../css/wp-empty-template-alert.css | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/wp-includes/css/wp-empty-template-alert.css b/src/wp-includes/css/wp-empty-template-alert.css index 53142ec84c7db..49af3be000947 100644 --- a/src/wp-includes/css/wp-empty-template-alert.css +++ b/src/wp-includes/css/wp-empty-template-alert.css @@ -1,23 +1,23 @@ #wp-empty-template-alert { - display: flex; - padding: var(--wp--style--root--padding-right, 2rem); - min-height: 60vh; - flex-direction: column; - align-items: center; - justify-content: center; - gap: var(--wp--style--block-gap, 2rem); + display: flex; + padding: var(--wp--style--root--padding-right, 2rem); + min-height: 60vh; + flex-direction: column; + align-items: center; + justify-content: center; + gap: var(--wp--style--block-gap, 2rem); } #wp-empty-template-alert > * { - max-width: 400px; + max-width: 400px; } #wp-empty-template-alert h2, #wp-empty-template-alert p { - margin: 0; - text-align: center; + margin: 0; + text-align: center; } #wp-empty-template-alert a { - margin-top: 1rem; + margin-top: 1rem; } From ed77ba9d4cc3c57dd16f2bead2ff3d2c30dcf76b Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 27 Aug 2026 22:10:19 +0000 Subject: [PATCH 030/363] Administration: Fix the CSS Coding Standards in wp-pointer.css. Lints the `src/wp-includes/css/wp-pointer.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13171 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63377 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/wp-pointer.css | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/wp-includes/css/wp-pointer.css b/src/wp-includes/css/wp-pointer.css index 4265f81fa6ed1..ccf7ddc560397 100644 --- a/src/wp-includes/css/wp-pointer.css +++ b/src/wp-includes/css/wp-pointer.css @@ -19,13 +19,13 @@ background: #2271b1; } -.wp-pointer-content h3:before { +.wp-pointer-content h3::before { background: #fff; border-radius: 50%; color: #2271b1; content: "\f227"; - content: "\f227" / ''; - font: normal 20px/1.6 dashicons; + content: "\f227" / ""; + font: 400 20px/1.6 dashicons; position: absolute; top: 8px; left: 15px; @@ -62,13 +62,13 @@ position: relative; } -.wp-pointer-buttons a.close:before { +.wp-pointer-buttons a.close::before { background: none; color: #787c82; content: "\f153"; - content: "\f153" / ''; + content: "\f153" / ""; display: block !important; - font: normal 16px/1 dashicons; + font: 400 16px/1 dashicons; margin: 1px 0; text-align: center; -webkit-font-smoothing: antialiased !important; @@ -79,7 +79,7 @@ top: 1px; } -.wp-pointer-buttons a.close:hover:before { +.wp-pointer-buttons a.close:hover::before { color: #d63638; } From 5bf63817467645ae67c83c692a1b99854e89d2b1 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 27 Aug 2026 22:33:18 +0000 Subject: [PATCH 031/363] Code Quality: Add the documented `return null;` to 14 functions. PHPStan reports `return.missing` where a documented return type obliges a function to return a value on every path, but one path falls off the end instead. Adding the `return null;` that the annotation already implies resolves the report without changing behavior, since PHP was returning null implicitly anyway. This is the shape r61716 used on `get_category_by_path()`, which replaced a bare `return;` in that same function; its remaining path is now handled too. Covered here are `get_category_by_path()`, `wp_list_users()`, `single_month_title()`, `WP_Customize_Manager::get_setting()`, `get_panel()`, `get_section()` and `get_control()`, `WP_Customize_Widgets::get_setting_type()`, `WP_Customize_Header_Image_Control::get_current_image_src()`, `WP_Image_Editor_Imagick::set_imagick_time_limit()`, and the four pagination helpers in `link-template.php`. Every change is a pure append, leaving the diff additive at 30 insertions and no deletions. Two further groups of `return.missing` fixes from the same pull request carry more risk and will follow separately. The baseline `tests/phpstan/baselines/return.missing.neon` drops from 41 entries covering 44 errors to 27 covering 29, so the file and its entry in `phpstan.neon.dist` both remain for now. Developed in https://github.com/WordPress/wordpress-develop/pull/13082. Follow-up to r61716, r63020. Props dpantazis, dmsnell. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63378 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/category.php | 2 + .../class-wp-customize-manager.php | 8 +++ .../class-wp-customize-widgets.php | 2 + .../class-wp-image-editor-imagick.php | 2 + ...lass-wp-customize-header-image-control.php | 2 + src/wp-includes/general-template.php | 3 + src/wp-includes/link-template.php | 8 +++ src/wp-includes/user.php | 3 + tests/phpstan/baselines/return.missing.neon | 70 ------------------- 9 files changed, 30 insertions(+), 70 deletions(-) diff --git a/src/wp-includes/category.php b/src/wp-includes/category.php index 8fb6b1c5479ba..dbb48d630b076 100644 --- a/src/wp-includes/category.php +++ b/src/wp-includes/category.php @@ -176,6 +176,8 @@ function get_category_by_path( $category_path, $full_match = true, $output = OBJ return $category; } + + return null; } /** diff --git a/src/wp-includes/class-wp-customize-manager.php b/src/wp-includes/class-wp-customize-manager.php index e298b04efcf90..6ee4292496aa6 100644 --- a/src/wp-includes/class-wp-customize-manager.php +++ b/src/wp-includes/class-wp-customize-manager.php @@ -3875,6 +3875,8 @@ public function get_setting( $id ) { if ( isset( $this->settings[ $id ] ) ) { return $this->settings[ $id ]; } + + return null; } /** @@ -3927,6 +3929,8 @@ public function get_panel( $id ) { if ( isset( $this->panels[ $id ] ) ) { return $this->panels[ $id ]; } + + return null; } /** @@ -4023,6 +4027,8 @@ public function get_section( $id ) { if ( isset( $this->sections[ $id ] ) ) { return $this->sections[ $id ]; } + + return null; } /** @@ -4102,6 +4108,8 @@ public function get_control( $id ) { if ( isset( $this->controls[ $id ] ) ) { return $this->controls[ $id ]; } + + return null; } /** diff --git a/src/wp-includes/class-wp-customize-widgets.php b/src/wp-includes/class-wp-customize-widgets.php index 7484d2deee7da..d7cd0d5de15dd 100644 --- a/src/wp-includes/class-wp-customize-widgets.php +++ b/src/wp-includes/class-wp-customize-widgets.php @@ -189,6 +189,8 @@ protected function get_setting_type( $setting_id ) { return $type; } } + + return null; } /** diff --git a/src/wp-includes/class-wp-image-editor-imagick.php b/src/wp-includes/class-wp-image-editor-imagick.php index 2ea329d2ce5a2..b2d6b374e33d9 100644 --- a/src/wp-includes/class-wp-image-editor-imagick.php +++ b/src/wp-includes/class-wp-image-editor-imagick.php @@ -531,6 +531,8 @@ public static function set_imagick_time_limit() { return $limit; } + + return null; } /** diff --git a/src/wp-includes/customize/class-wp-customize-header-image-control.php b/src/wp-includes/customize/class-wp-customize-header-image-control.php index f6da1275aec94..23018366425e9 100644 --- a/src/wp-includes/customize/class-wp-customize-header-image-control.php +++ b/src/wp-includes/customize/class-wp-customize-header-image-control.php @@ -201,6 +201,8 @@ public function get_current_image_src() { $src = call_user_func( $this->get_url, $src ); return $src; } + + return null; } /** diff --git a/src/wp-includes/general-template.php b/src/wp-includes/general-template.php index 22a1d3e307d3e..dae87c6aa8005 100644 --- a/src/wp-includes/general-template.php +++ b/src/wp-includes/general-template.php @@ -1896,7 +1896,10 @@ function single_month_title( $prefix = '', $display = true ) { if ( ! $display ) { return $result; } + echo $result; + + return null; } /** diff --git a/src/wp-includes/link-template.php b/src/wp-includes/link-template.php index 484a8c8f8591c..0f332b3101148 100644 --- a/src/wp-includes/link-template.php +++ b/src/wp-includes/link-template.php @@ -2530,6 +2530,8 @@ function get_next_posts_page_link( $max_page = 0 ) { return get_pagenum_link( $next_page ); } } + + return null; } /** @@ -2598,6 +2600,8 @@ function get_next_posts_link( $label = null, $max_page = 0 ) { preg_replace( '/&([^#])(?![a-z]{1,8};)/i', '&$1', $label ) ); } + + return null; } /** @@ -2637,6 +2641,8 @@ function get_previous_posts_page_link() { return get_pagenum_link( $previous_page ); } + + return null; } /** @@ -2692,6 +2698,8 @@ function get_previous_posts_link( $label = null ) { preg_replace( '/&([^#])(?![a-z]{1,8};)/i', '&$1', $label ) ); } + + return null; } /** diff --git a/src/wp-includes/user.php b/src/wp-includes/user.php index 1a1ce8359ccbe..01b567a74d86d 100644 --- a/src/wp-includes/user.php +++ b/src/wp-includes/user.php @@ -1013,7 +1013,10 @@ function wp_list_users( $args = array() ) { if ( ! $parsed_args['echo'] ) { return $return; } + echo $return; + + return null; } /** diff --git a/tests/phpstan/baselines/return.missing.neon b/tests/phpstan/baselines/return.missing.neon index 11bb654bafb2c..64fe066c133cb 100644 --- a/tests/phpstan/baselines/return.missing.neon +++ b/tests/phpstan/baselines/return.missing.neon @@ -28,56 +28,11 @@ parameters: identifier: return.missing count: 1 path: ../../../src/wp-content/themes/twentyfourteen/inc/widgets.php - - - message: '#^Function get_category_by_path\(\) should return array\|WP_Error\|WP_Term\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/category.php - - - message: '#^Method WP_Customize_Manager\:\:get_control\(\) should return WP_Customize_Control\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/class-wp-customize-manager.php - - - message: '#^Method WP_Customize_Manager\:\:get_panel\(\) should return WP_Customize_Panel\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/class-wp-customize-manager.php - - - message: '#^Method WP_Customize_Manager\:\:get_section\(\) should return WP_Customize_Section\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/class-wp-customize-manager.php - - - message: '#^Method WP_Customize_Manager\:\:get_setting\(\) should return WP_Customize_Setting\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/class-wp-customize-manager.php - - - message: '#^Method WP_Customize_Widgets\:\:get_setting_type\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/class-wp-customize-widgets.php - - - message: '#^Method WP_Image_Editor_Imagick\:\:set_imagick_time_limit\(\) should return int\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/class-wp-image-editor-imagick.php - - - message: '#^Method WP_Customize_Header_Image_Control\:\:get_current_image_src\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/customize/class-wp-customize-header-image-control.php - message: '#^Function post_type_archive_title\(\) should return string\|null but return statement is missing\.$#' identifier: return.missing count: 1 path: ../../../src/wp-includes/general-template.php - - - message: '#^Function single_month_title\(\) should return string\|false\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - message: '#^Function single_post_title\(\) should return string\|null but return statement is missing\.$#' identifier: return.missing @@ -108,26 +63,6 @@ parameters: identifier: return.missing count: 1 path: ../../../src/wp-includes/link-template.php - - - message: '#^Function get_next_posts_link\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/link-template.php - - - message: '#^Function get_next_posts_page_link\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 2 - path: ../../../src/wp-includes/link-template.php - - - message: '#^Function get_previous_posts_link\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/link-template.php - - - message: '#^Function get_previous_posts_page_link\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/link-template.php - message: '#^Function next_posts\(\) should return string\|null but return statement is missing\.$#' identifier: return.missing @@ -138,11 +73,6 @@ parameters: identifier: return.missing count: 1 path: ../../../src/wp-includes/link-template.php - - - message: '#^Function wp_list_users\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/user.php - message: '#^Method WP_Nav_Menu_Widget\:\:form\(\) should return string\|null but return statement is missing\.$#' identifier: return.missing From 1e097e34f478b1ce93888a87ac6042ea5aa43b00 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 27 Aug 2026 22:54:07 +0000 Subject: [PATCH 032/363] Code Quality: Resolve the remaining `return.missing` PHPStan errors. Nine template functions take a `$display` parameter and either echo their result or return it. Each is documented as returning `string|null`, but the echoing branch fell off the end without returning, which is what PHPStan reports as `return.missing`. Inverting the condition lets the value-returning path exit first and the echoing path fall through to an explicit `return null;`, the same shape `single_month_title()` received in r63378. Affected are `wp_title()`, `single_post_title()`, `post_type_archive_title()`, `single_term_title()`, `the_date()`, `the_modified_date()`, `edit_term_link()`, `next_posts()` and `previous_posts()`. No behavior changes. `WP_Widget::form()` is documented as `string|void` again. r59336 added the `void` deliberately, noting that unlike its siblings it is the child classes which return nothing when the method is correctly implemented. r62178 replaced it with `null` on the premise that `void` cannot belong to a union, which holds for PHP's native return types but not for PHPDoc, where PHPStan reads `void` in a union as "may not return at all". Under `string|null` the annotation instead obliged every override to return, putting all 18 of them in breach, two of which live in bundled themes that r62178 did not touch. With no occurrences left, `tests/phpstan/baselines/return.missing.neon` is deleted along with its entry in `phpstan.neon.dist`, completing the work begun in r63378. Developed in https://github.com/WordPress/wordpress-develop/pull/13082. Follow-up to r59336, r62178, r63020, r63378. Props dpantazis, dmsnell. See #65817, #64704. git-svn-id: https://develop.svn.wordpress.org/trunk@63379 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 1 - src/wp-includes/class-wp-widget.php | 3 +- src/wp-includes/general-template.php | 49 ++++--- src/wp-includes/link-template.php | 24 +-- tests/phpstan/baselines/return.missing.neon | 155 -------------------- 5 files changed, 48 insertions(+), 184 deletions(-) delete mode 100644 tests/phpstan/baselines/return.missing.neon diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 5766f8a98a6b0..4292aa4ddb408 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -76,7 +76,6 @@ includes: - tests/phpstan/baselines/property.phpDocType.neon - tests/phpstan/baselines/property.private.neon - tests/phpstan/baselines/property.protected.neon - - tests/phpstan/baselines/return.missing.neon - tests/phpstan/baselines/return.type.neon - tests/phpstan/baselines/return.unusedType.neon - tests/phpstan/baselines/smallerOrEqual.alwaysTrue.neon diff --git a/src/wp-includes/class-wp-widget.php b/src/wp-includes/class-wp-widget.php index dc84f54774162..b131c50db3226 100644 --- a/src/wp-includes/class-wp-widget.php +++ b/src/wp-includes/class-wp-widget.php @@ -138,7 +138,8 @@ public function update( $new_instance, $old_instance ) { * @since 2.8.0 * * @param array $instance The settings for the particular instance of the widget. - * @return string|null Default return is 'noform'. A subclass may opt to return null. + * @return string|void Default return is 'noform'. A subclass which echoes its own + * form returns nothing. */ public function form( $instance ) { echo '

    ' . __( 'There are no options for this widget.' ) . '

    '; diff --git a/src/wp-includes/general-template.php b/src/wp-includes/general-template.php index dae87c6aa8005..b626b5ca605ce 100644 --- a/src/wp-includes/general-template.php +++ b/src/wp-includes/general-template.php @@ -1673,11 +1673,13 @@ function wp_title( $sep = '»', $display = true, $seplocation = '' ) { $title = apply_filters( 'wp_title', $title, $sep, $seplocation ); // Send it out. - if ( $display ) { - echo $title; - } else { + if ( ! $display ) { return $title; } + + echo $title; + + return null; } /** @@ -1712,11 +1714,14 @@ function single_post_title( $prefix = '', $display = true ) { * @param WP_Post $_post The current post. */ $title = apply_filters( 'single_post_title', $_post->post_title, $_post ); - if ( $display ) { - echo $prefix . $title; - } else { + + if ( ! $display ) { return $prefix . $title; } + + echo $prefix . $title; + + return null; } /** @@ -1753,11 +1758,13 @@ function post_type_archive_title( $prefix = '', $display = true ) { */ $title = apply_filters( 'post_type_archive_title', $post_type_obj->labels->name, $post_type ); - if ( $display ) { - echo $prefix . $title; - } else { + if ( ! $display ) { return $prefix . $title; } + + echo $prefix . $title; + + return null; } /** @@ -1849,11 +1856,13 @@ function single_term_title( $prefix = '', $display = true ) { return null; } - if ( $display ) { - echo $prefix . $term_name; - } else { + if ( ! $display ) { return $prefix . $term_name; } + + echo $prefix . $term_name; + + return null; } /** @@ -2913,11 +2922,13 @@ function the_date( $format = '', $before = '', $after = '', $display = true ) { */ $the_date = apply_filters( 'the_date', $the_date, $format, $before, $after ); - if ( $display ) { - echo $the_date; - } else { + if ( ! $display ) { return $the_date; } + + echo $the_date; + + return null; } /** @@ -2981,11 +2992,13 @@ function the_modified_date( $format = '', $before = '', $after = '', $display = */ $the_modified_date = apply_filters( 'the_modified_date', $the_modified_date, $format, $before, $after ); - if ( $display ) { - echo $the_modified_date; - } else { + if ( ! $display ) { return $the_modified_date; } + + echo $the_modified_date; + + return null; } /** diff --git a/src/wp-includes/link-template.php b/src/wp-includes/link-template.php index 0f332b3101148..4c6b1fa929586 100644 --- a/src/wp-includes/link-template.php +++ b/src/wp-includes/link-template.php @@ -1164,11 +1164,13 @@ function edit_term_link( $link = '', $before = '', $after = '', $term = null, $d */ $link = $before . apply_filters( 'edit_term_link', $link, $term->term_id ) . $after; - if ( $display ) { - echo $link; - } else { + if ( ! $display ) { return $link; } + + echo $link; + + return null; } /** @@ -2547,11 +2549,13 @@ function next_posts( $max_page = 0, $display = true ) { $link = get_next_posts_page_link( $max_page ); $output = $link ? esc_url( $link ) : ''; - if ( $display ) { - echo $output; - } else { + if ( ! $display ) { return $output; } + + echo $output; + + return null; } /** @@ -2657,11 +2661,13 @@ function previous_posts( $display = true ) { $link = get_previous_posts_page_link(); $output = $link ? esc_url( $link ) : ''; - if ( $display ) { - echo $output; - } else { + if ( ! $display ) { return $output; } + + echo $output; + + return null; } /** diff --git a/tests/phpstan/baselines/return.missing.neon b/tests/phpstan/baselines/return.missing.neon deleted file mode 100644 index 64fe066c133cb..0000000000000 --- a/tests/phpstan/baselines/return.missing.neon +++ /dev/null @@ -1,155 +0,0 @@ -# PHPStan baseline for the `return.missing` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/return.missing -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=return.missing -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^Method Twenty_Eleven_Ephemera_Widget\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-content/themes/twentyeleven/inc/widgets.php - - - message: '#^Method Twenty_Fourteen_Ephemera_Widget\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-content/themes/twentyfourteen/inc/widgets.php - - - message: '#^Function post_type_archive_title\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - - - message: '#^Function single_post_title\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - - - message: '#^Function single_term_title\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - - - message: '#^Function the_date\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - - - message: '#^Function the_modified_date\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - - - message: '#^Function wp_title\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/general-template.php - - - message: '#^Function edit_term_link\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/link-template.php - - - message: '#^Function next_posts\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/link-template.php - - - message: '#^Function previous_posts\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/link-template.php - - - message: '#^Method WP_Nav_Menu_Widget\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-nav-menu-widget.php - - - message: '#^Method WP_Widget_Archives\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-archives.php - - - message: '#^Method WP_Widget_Block\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-block.php - - - message: '#^Method WP_Widget_Calendar\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-calendar.php - - - message: '#^Method WP_Widget_Categories\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-categories.php - - - message: '#^Method WP_Widget_Custom_HTML\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-custom-html.php - - - message: '#^Method WP_Widget_Links\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-links.php - - - message: '#^Method WP_Widget_Media\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-media.php - - - message: '#^Method WP_Widget_Meta\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-meta.php - - - message: '#^Method WP_Widget_Pages\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-pages.php - - - message: '#^Method WP_Widget_Recent_Comments\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-recent-comments.php - - - message: '#^Method WP_Widget_Recent_Posts\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-recent-posts.php - - - message: '#^Method WP_Widget_RSS\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-rss.php - - - message: '#^Method WP_Widget_Search\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 1 - path: ../../../src/wp-includes/widgets/class-wp-widget-search.php - - - message: '#^Method WP_Widget_Tag_Cloud\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 2 - path: ../../../src/wp-includes/widgets/class-wp-widget-tag-cloud.php - - - message: '#^Method WP_Widget_Text\:\:form\(\) should return string\|null but return statement is missing\.$#' - identifier: return.missing - count: 2 - path: ../../../src/wp-includes/widgets/class-wp-widget-text.php From 25a91cb9724e0fbda50a0d281c8f84e34aa738a8 Mon Sep 17 00:00:00 2001 From: Dennis Snell Date: Fri, 28 Aug 2026 00:04:49 +0000 Subject: [PATCH 033/363] HTML API: Refactor `wp_get_admin_notice()`. Refactors `wp_get_admin_notice()` to rely on the HTML API for HTML generation. This provides more reliable parsing and hardening for and against the provided arguments, but introduces behavioral changes that should only affect already-broken cases. Namely, the function previously generated its output and then mandated that calling code run it through `wp_kses()`. This meant that certain kinds of corruption were possible which would break boundaries within the generated HTML and result in mangled output through `wp_kses()`. Now, the function preserves all boundaries when generating the output, meaning that `wp_kses()` will receive already-normalized content. Developed in: https://github.com/WordPress/wordpress-develop/pull/13273 Discussed in: https://core.trac.wordpress.org/ticket/65984 Props dmsnell, joedolson, johnbillion, jorbin. See #65984. git-svn-id: https://develop.svn.wordpress.org/trunk@63380 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/functions.php | 51 +++++++++++-------- .../phpunit/tests/functions/wpAdminNotice.php | 8 +-- .../tests/functions/wpGetAdminNotice.php | 8 +-- 3 files changed, 37 insertions(+), 30 deletions(-) diff --git a/src/wp-includes/functions.php b/src/wp-includes/functions.php index e011ddf0c26a3..f6f902605a198 100644 --- a/src/wp-includes/functions.php +++ b/src/wp-includes/functions.php @@ -9237,23 +9237,26 @@ function wp_get_admin_notice( $message, $args = array() ) { * @param array $args The arguments for the admin notice. * @param string $message The message for the admin notice. */ - $args = apply_filters( 'wp_admin_notice_args', $args, $message ); - $id = ''; - $classes = 'notice'; - $attributes = ''; + $args = apply_filters( 'wp_admin_notice_args', $args, $message ); + + $wrap_with_p = false !== $args['paragraph_wrap']; + $wrap_opener = $wrap_with_p ? '

    ' : ''; + $wrap_closer = $wrap_with_p ? '

    ' : ''; + $html_builder = new WP_HTML_Tag_Processor( "
    {$wrap_opener}" ); + $html_builder->next_token(); if ( is_string( $args['id'] ) ) { $trimmed_id = trim( $args['id'] ); if ( '' !== $trimmed_id ) { - $id = 'id="' . $trimmed_id . '" '; + $html_builder->set_attribute( 'id', $trimmed_id ); } } if ( is_string( $args['type'] ) ) { $type = trim( $args['type'] ); - if ( str_contains( $type, ' ' ) ) { + if ( strlen( $type ) !== strcspn( $type, " \f\t\r\n" ) ) { _doing_it_wrong( __FUNCTION__, sprintf( @@ -9266,36 +9269,40 @@ function wp_get_admin_notice( $message, $args = array() ) { } if ( '' !== $type ) { - $classes .= ' notice-' . $type; + $html_builder->add_class( "notice-{$type}" ); } } if ( true === $args['dismissible'] ) { - $classes .= ' is-dismissible'; + $html_builder->add_class( 'is-dismissible' ); } if ( is_array( $args['additional_classes'] ) && ! empty( $args['additional_classes'] ) ) { - $classes .= ' ' . implode( ' ', $args['additional_classes'] ); + foreach ( $args['additional_classes'] as $class_name ) { + $html_builder->add_class( $class_name ); + } } if ( is_array( $args['attributes'] ) && ! empty( $args['attributes'] ) ) { - $attributes = ''; - foreach ( $args['attributes'] as $attr => $val ) { - if ( is_bool( $val ) ) { - $attributes .= $val ? ' ' . $attr : ''; - } elseif ( is_int( $attr ) ) { - $attributes .= ' ' . esc_attr( trim( $val ) ); - } elseif ( $val ) { - $attributes .= ' ' . $attr . '="' . esc_attr( trim( $val ) ) . '"'; + foreach ( $args['attributes'] as $name => $value ) { + if ( is_int( $name ) ) { + /* + * Boolean attributes may have been appended as numeric list items, + * for example, with `$args['attributes'][] = 'disabled'`. They should + * be recorded with the value serving as their name. + */ + $html_builder->set_attribute( $value, true ); + } elseif ( true === $value ) { + $html_builder->set_attribute( $name, true ); + } elseif ( false !== $value ) { + $html_builder->set_attribute( $name, trim( (string) $value ) ); } } } - if ( false !== $args['paragraph_wrap'] ) { - $message = "

    $message

    "; - } - - $markup = sprintf( '
    %4$s
    ', $id, $classes, $attributes, $message ); + $markup = $html_builder->get_updated_html(); + $markup .= $message; + $markup .= "{$wrap_closer}
    "; /** * Filters the markup for an admin notice. diff --git a/tests/phpunit/tests/functions/wpAdminNotice.php b/tests/phpunit/tests/functions/wpAdminNotice.php index e2b694d726cf1..3fb5391dead3e 100644 --- a/tests/phpunit/tests/functions/wpAdminNotice.php +++ b/tests/phpunit/tests/functions/wpAdminNotice.php @@ -25,7 +25,7 @@ public function test_should_output_admin_notice( $message, $args, $expected ) { wp_admin_notice( $message, $args ); $actual = ob_get_clean(); - $this->assertSame( $expected, $actual ); + $this->assertEqualHTML( $expected, $actual ); } /** @@ -154,21 +154,21 @@ public function data_should_output_admin_notice() { 'args' => array( 'type' => '">', ), - 'expected' => '
    alert("Howdy,admin!");">

    A notice with an unsafe type.

    ', + 'expected' => '

    A notice with an unsafe type.

    ', ), 'an unsafe ID' => array( 'message' => 'A notice with an unsafe ID.', 'args' => array( 'id' => '">
    alert( "Howdy, admin!" );

    A notice with an unsafe ID.

    ', + 'expected' => '

    A notice with an unsafe ID.

    ', ), 'unsafe additional classes' => array( 'message' => 'A notice with unsafe additional classes.', 'args' => array( 'additional_classes' => array( '">
    alert( "Howdy, admin!" );

    A notice with unsafe additional classes.

    ', + 'expected' => '

    A notice with unsafe additional classes.

    ', ), 'a type that is not a string' => array( 'message' => 'A notice with a type that is not a string.', diff --git a/tests/phpunit/tests/functions/wpGetAdminNotice.php b/tests/phpunit/tests/functions/wpGetAdminNotice.php index 41b24a122be88..87343479a2670 100644 --- a/tests/phpunit/tests/functions/wpGetAdminNotice.php +++ b/tests/phpunit/tests/functions/wpGetAdminNotice.php @@ -21,7 +21,7 @@ class Tests_Functions_WpGetAdminNotice extends WP_UnitTestCase { * @param string $expected The expected admin notice markup. */ public function test_should_return_admin_notice( $message, $args, $expected ) { - $this->assertSame( $expected, wp_get_admin_notice( $message, $args ) ); + $this->assertEqualHTML( $expected, wp_get_admin_notice( $message, $args ) ); } /** @@ -150,21 +150,21 @@ public function data_should_return_admin_notice() { 'args' => array( 'type' => '">', ), - 'expected' => '
    ">

    A notice with an unsafe type.

    ', + 'expected' => '

    A notice with an unsafe type.

    ', ), 'an unsafe ID' => array( 'message' => 'A notice with an unsafe ID.', 'args' => array( 'id' => '">

    A notice with an unsafe ID.

    ', + 'expected' => '

    A notice with an unsafe ID.

    ', ), 'unsafe additional classes' => array( 'message' => 'A notice with unsafe additional classes.', 'args' => array( 'additional_classes' => array( '">

    A notice with unsafe additional classes.

    ', + 'expected' => '

    A notice with unsafe additional classes.

    ', ), 'a type that is not a string' => array( 'message' => 'A notice with a type that is not a string.', From ddcfed2024b075b074694d6d3412a93a132fa70f Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 28 Aug 2026 00:45:55 +0000 Subject: [PATCH 034/363] Code Quality: Resolve the `encapsedStringPart.nonString` error. The `get_attachment_fields_to_edit()` function documented every value of its returned array as a field definition array, but the `attachment_fields_to_edit` filter may also add a `_final` entry holding raw HTML, which `get_media_item()` interpolates into a string. Declare that structure in a `@phpstan-return` tag so the `_final` entry is typed as a string while the remaining keys stay typed as field definition arrays, and widen the plain `@return` to a union so the array shape remains a proper subtype of it. The `menu_order` key is listed explicitly in the shape because `get_media_item()` unsets it. Unsetting a key that an unsealed array shape does not declare collapses the shape into a plain union of its value types, which would reintroduce the imprecision for every other field. Developed in https://github.com/WordPress/wordpress-develop/pull/13078. Follow-up to r61594, r63020. Props dpantazis. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63381 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 1 - src/wp-admin/includes/media.php | 11 +++++++- .../encapsedStringPart.nonString.neon | 25 ------------------- 3 files changed, 10 insertions(+), 27 deletions(-) delete mode 100644 tests/phpstan/baselines/encapsedStringPart.nonString.neon diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 4292aa4ddb408..3a4cce5b04ae3 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -42,7 +42,6 @@ includes: - tests/phpstan/baselines/empty.offset.neon - tests/phpstan/baselines/empty.property.neon - tests/phpstan/baselines/empty.variable.neon - - tests/phpstan/baselines/encapsedStringPart.nonString.neon - tests/phpstan/baselines/foreach.nonIterable.neon - tests/phpstan/baselines/function.alreadyNarrowedType.neon - tests/phpstan/baselines/function.impossibleType.neon diff --git a/src/wp-admin/includes/media.php b/src/wp-admin/includes/media.php index 99281712f66cf..babc0e85c33ac 100644 --- a/src/wp-admin/includes/media.php +++ b/src/wp-admin/includes/media.php @@ -1398,7 +1398,16 @@ function image_media_send_to_editor( $html, $attachment_id, $attachment ) { * * @param WP_Post $post * @param array $errors - * @return array> The attachment fields. + * @return array|string> The attachment fields, keyed by field name. Each value is a + * field definition array, except for the `_final` key, which the + * `attachment_fields_to_edit` filter may set to raw HTML that is + * rendered after all other fields. + * + * @phpstan-return array{ + * _final?: string, + * menu_order?: array, // Listed explicitly so that unsetting it in get_media_item() does not collapse this shape. + * ...> + * } */ function get_attachment_fields_to_edit( $post, $errors = null ) { if ( is_int( $post ) ) { diff --git a/tests/phpstan/baselines/encapsedStringPart.nonString.neon b/tests/phpstan/baselines/encapsedStringPart.nonString.neon deleted file mode 100644 index 707a2192a4c8a..0000000000000 --- a/tests/phpstan/baselines/encapsedStringPart.nonString.neon +++ /dev/null @@ -1,25 +0,0 @@ -# PHPStan baseline for the `encapsedStringPart.nonString` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/encapsedStringPart.nonString -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=encapsedStringPart.nonString -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^Part \$form_fields\[''_final''\] \(non\-empty\-array\\) of encapsed string cannot be cast to string\.$#' - identifier: encapsedStringPart.nonString - count: 1 - path: ../../../src/wp-admin/includes/media.php From 8c787059570b8ffae03e3d0c4d64ddde56096ce2 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Fri, 28 Aug 2026 01:49:20 +0000 Subject: [PATCH 035/363] Editor: Add the fit text CSS class to server-rendered blocks. Inject the `has-fit-text` class into the block wrapper during server-side rendering, so that fit text also takes effect on dynamically rendered blocks. Developed in: https://github.com/WordPress/wordpress-develop/pull/13287 Props westonruter, wildworks. Fixes #65973. git-svn-id: https://develop.svn.wordpress.org/trunk@63382 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/block-supports/typography.php | 1 + .../tests/block-supports/typography.php | 77 +++++++++++++++++++ 2 files changed, 78 insertions(+) diff --git a/src/wp-includes/block-supports/typography.php b/src/wp-includes/block-supports/typography.php index 6573119933721..e99d0254fb43d 100644 --- a/src/wp-includes/block-supports/typography.php +++ b/src/wp-includes/block-supports/typography.php @@ -311,6 +311,7 @@ function wp_render_typography_support( $block_content, $block ) { if ( ! empty( $block_content ) ) { $processor = new WP_HTML_Tag_Processor( $block_content ); if ( $processor->next_tag() ) { + $processor->add_class( 'has-fit-text' ); if ( ! $processor->get_attribute( 'data-wp-interactive' ) ) { $processor->set_attribute( 'data-wp-interactive', true ); } diff --git a/tests/phpunit/tests/block-supports/typography.php b/tests/phpunit/tests/block-supports/typography.php index 59c47516caa2d..2c39b9c51b82e 100644 --- a/tests/phpunit/tests/block-supports/typography.php +++ b/tests/phpunit/tests/block-supports/typography.php @@ -58,6 +58,9 @@ public function tear_down() { unregister_block_type( $this->test_block_name ); $this->test_block_name = null; + // Resets script modules enqueued while rendering fit text. + $GLOBALS['wp_script_modules'] = null; + parent::tear_down(); } @@ -1135,6 +1138,80 @@ public function data_generate_replace_inline_font_styles_with_fluid_values_fixtu ); } + /** + * Tests that the `has-fit-text` class name is added to the block wrapper when the + * `fitText` attribute is set. + * + * @ticket 65973 + * + * @covers ::wp_render_typography_support + * + * @dataProvider data_should_add_fit_text_class_name + * + * @param non-falsy-string $block_content HTML block content. + * @param non-falsy-string $expected_class Expected value of the class attribute on the block wrapper. + */ + public function test_should_add_fit_text_class_name( string $block_content, string $expected_class ) { + $block = array( + 'blockName' => 'core/site-title', + 'attrs' => array( + 'fitText' => true, + ), + ); + + $actual = wp_render_typography_support( $block_content, $block ); + + $processor = new WP_HTML_Tag_Processor( $actual ); + $processor->next_tag(); + + $this->assertSame( $expected_class, $processor->get_attribute( 'class' ), 'The block wrapper does not have the expected class names.' ); + $this->assertSame( 1, substr_count( $actual, 'has-fit-text' ), 'The class name should be added exactly once, to the outermost tag only.' ); + } + + /** + * Data provider for test_should_add_fit_text_class_name(). + * + * @return array + */ + public function data_should_add_fit_text_class_name(): array { + return array( + 'wrapper without a class attribute' => array( + 'block_content' => '

    Site Title

    ', + 'expected_class' => 'has-fit-text', + ), + 'wrapper with existing class names' => array( + 'block_content' => '

    Site Title

    ', + 'expected_class' => 'wp-block-site-title has-fit-text', + ), + 'wrapper with an already serialized class name' => array( + 'block_content' => '

    A paragraph

    ', + 'expected_class' => 'has-fit-text', + ), + 'wrapper with inner blocks' => array( + 'block_content' => '

    A paragraph inside a group

    ', + 'expected_class' => 'wp-block-group has-fit-text', + ), + ); + } + + /** + * Tests that the `has-fit-text` class name is not added when the block does not + * opt in to the fit text support. + * + * @ticket 65973 + * + * @covers ::wp_render_typography_support + */ + public function test_should_not_add_fit_text_class_name_without_fit_text_attribute() { + $block_content = '

    Site Title

    '; + $block = array( + 'blockName' => 'core/site-title', + 'attrs' => array(), + ); + + $this->assertSame( $block_content, wp_render_typography_support( $block_content, $block ) ); + } + /** * Tests that valid font size values are parsed. * From 6794f59d6b5ab75426647a5ae743e18654c99516 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 28 Aug 2026 02:50:34 +0000 Subject: [PATCH 036/363] Users: Document `comment_shortcuts` and `infinite_scrolling` properties on `WP_User`. Both are user preferences read straight off a `WP_User` through the magic `__get()`, exactly like `rich_editing` and `syntax_highlighting` beside them, but neither was listed among the class's `@property` tags, so nothing could resolve them. The `infinite_scrolling` property arrived in r62632 with the Media Library opt-out option; `comment_shortcuts` has gone undocumented since r9217 added the comment hotkeys opt-in, and was missing for the same reason. Regenerating the baselines drops both entries from `tests/phpstan/baselines/property.nonObject.neon`. Developed as subset of https://github.com/WordPress/wordpress-develop/pull/13064. Follow-up to r9217, r62632, r63020. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63383 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-user.php | 2 ++ tests/phpstan/baselines/property.nonObject.neon | 10 ---------- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/src/wp-includes/class-wp-user.php b/src/wp-includes/class-wp-user.php index d921a83de7f1f..d11d3b67af534 100644 --- a/src/wp-includes/class-wp-user.php +++ b/src/wp-includes/class-wp-user.php @@ -33,6 +33,8 @@ * @property string $display_name * @property string $spam * @property string $deleted + * @property string $comment_shortcuts + * @property string $infinite_scrolling * @property string $locale * @property string $rich_editing * @property string $syntax_highlighting diff --git a/tests/phpstan/baselines/property.nonObject.neon b/tests/phpstan/baselines/property.nonObject.neon index 81a4af3e09511..13fd1ccf89fc9 100644 --- a/tests/phpstan/baselines/property.nonObject.neon +++ b/tests/phpstan/baselines/property.nonObject.neon @@ -178,16 +178,6 @@ parameters: identifier: property.nonObject count: 2 path: ../../../src/wp-admin/update.php - - - message: '#^Cannot access property \$comment_shortcuts on WP_User\|false\.$#' - identifier: property.nonObject - count: 1 - path: ../../../src/wp-admin/user-edit.php - - - message: '#^Cannot access property \$infinite_scrolling on WP_User\|false\.$#' - identifier: property.nonObject - count: 1 - path: ../../../src/wp-admin/user-edit.php - message: '#^Cannot access property \$id on int\|string\|WP_Term\.$#' identifier: property.nonObject From 4a8a86b0fddb74aaeb68fb5cc143fb73557fdae9 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 28 Aug 2026 04:57:25 +0000 Subject: [PATCH 037/363] Code Quality: Call `WP_Theme_JSON`'s private statics via `self::`. In r52744 this class's internal calls were rewritten from `self::` to `static::` so that the subclasses it was opening the class up to could override them. For a private method that buys nothing, since a subclass cannot supply one, and PHPStan reports it as unsafe: late static binding resolves `static::` to the runtime class, where the private method is not visible. Thirty such call sites were left, reaching fourteen private statics. All fourteen are declared `private static` on `WP_Theme_JSON` itself, so `self::` is behavior-identical. A docblock example on `compute_spacing_sizes()` showed the same form and is updated along with the code it documents. This now eliminates the `tests/phpstan/baselines/staticClassAccess.privateMethod.neon` baseline. In r63368 the identifier was cleared from the four other classes reporting it, and `WP_Theme_JSON` was the last. Developed as subset of https://github.com/WordPress/wordpress-develop/pull/13064. Follow-up to r52744, r63020, r63368. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63384 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 1 - src/wp-includes/class-wp-theme-json.php | 60 ++++++------- .../staticClassAccess.privateMethod.neon | 90 ------------------- 3 files changed, 30 insertions(+), 121 deletions(-) delete mode 100644 tests/phpstan/baselines/staticClassAccess.privateMethod.neon diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 3a4cce5b04ae3..9f53887d400de 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -78,7 +78,6 @@ includes: - tests/phpstan/baselines/return.type.neon - tests/phpstan/baselines/return.unusedType.neon - tests/phpstan/baselines/smallerOrEqual.alwaysTrue.neon - - tests/phpstan/baselines/staticClassAccess.privateMethod.neon - tests/phpstan/baselines/ternary.alwaysTrue.neon - tests/phpstan/baselines/varTag.noVariable.neon - tests/phpstan/baselines/variable.undefined.neon diff --git a/src/wp-includes/class-wp-theme-json.php b/src/wp-includes/class-wp-theme-json.php index 7175d7a88747d..f9d07ccaa6c10 100644 --- a/src/wp-includes/class-wp-theme-json.php +++ b/src/wp-includes/class-wp-theme-json.php @@ -718,7 +718,7 @@ class WP_Theme_JSON { * @return array Responsive media queries. */ public static function get_viewport_media_queries( $viewport_settings = null, $options = array() ) { - $breakpoints = static::sanitize_viewport_settings( $viewport_settings ); + $breakpoints = self::sanitize_viewport_settings( $viewport_settings ); $responsive_media_queries = array(); @@ -788,7 +788,7 @@ private static function is_valid_viewport_breakpoint_size( $value ) { * @return float|null Viewport breakpoint size in pixels, or null when invalid. */ private static function get_viewport_breakpoint_value_in_pixels( $value ) { - if ( ! static::is_valid_viewport_breakpoint_size( $value ) ) { + if ( ! self::is_valid_viewport_breakpoint_size( $value ) ) { return null; } @@ -831,7 +831,7 @@ private static function sanitize_viewport_settings( $viewport_settings ) { $breakpoints = array(); foreach ( array_keys( static::DEFAULT_VIEWPORT_BREAKPOINTS ) as $breakpoint ) { $value = $viewport_settings[ $breakpoint ] ?? null; - $px = static::get_viewport_breakpoint_value_in_pixels( $value ); + $px = self::get_viewport_breakpoint_value_in_pixels( $value ); if ( null !== $px ) { $breakpoints[ $breakpoint ] = array( 'value' => trim( $value ), @@ -989,8 +989,8 @@ private function process_pseudo_selectors( $node, $base_selector, $settings, $bl if ( is_array( $block_metadata ) ) { $feature_declarations = $this->get_feature_declarations_for_node( $block_metadata, $pseudo_node ); - $feature_declarations = static::update_paragraph_text_indent_selector( $feature_declarations, $settings, $block_name ); - $feature_declarations = static::update_button_width_declarations( $feature_declarations, $settings ); + $feature_declarations = self::update_paragraph_text_indent_selector( $feature_declarations, $settings, $block_name ); + $feature_declarations = self::update_button_width_declarations( $feature_declarations, $settings ); foreach ( $feature_declarations as $feature_selector => $declarations ) { $target_selector = is_array( $style_variation ) @@ -1098,7 +1098,7 @@ public function __construct( $theme_json = array( 'version' => self::LATEST_SCHE $valid_block_names = array_keys( $blocks_metadata ); $valid_element_names = array_keys( static::ELEMENTS ); $valid_variations = static::get_valid_block_style_variations( $blocks_metadata ); - $this->theme_json = static::unwrap_shared_block_style_variations( $this->theme_json, $valid_variations ); + $this->theme_json = self::unwrap_shared_block_style_variations( $this->theme_json, $valid_variations ); $this->theme_json = static::sanitize( $this->theme_json, $valid_block_names, $valid_element_names, $valid_variations ); $this->theme_json = static::maybe_opt_in_into_settings( $this->theme_json ); @@ -1136,8 +1136,8 @@ public function __construct( $theme_json = array( 'version' => self::LATEST_SCHE if ( isset( $spacing_scale ) ) { $sizes_path = array( 'settings', 'spacing', 'spacingSizes', $origin ); $spacing_sizes = _wp_array_get( $this->theme_json, $sizes_path, array() ); - $spacing_scale_sizes = static::compute_spacing_sizes( $spacing_scale ); - $merged_spacing_sizes = static::merge_spacing_sizes( $spacing_scale_sizes, $spacing_sizes ); + $spacing_scale_sizes = self::compute_spacing_sizes( $spacing_scale ); + $merged_spacing_sizes = self::merge_spacing_sizes( $spacing_scale_sizes, $spacing_sizes ); _wp_array_set( $this->theme_json, $sizes_path, $merged_spacing_sizes ); } } @@ -1457,13 +1457,13 @@ protected static function sanitize( $input, $valid_block_names, $valid_element_n $result = static::remove_keys_not_in_schema( $input[ $subtree ], $schema[ $subtree ] ); if ( 'settings' === $subtree && array_key_exists( 'viewport', $input[ $subtree ] ) ) { - $result['viewport'] = static::sanitize_viewport_settings( $input[ $subtree ]['viewport'] ); + $result['viewport'] = self::sanitize_viewport_settings( $input[ $subtree ]['viewport'] ); } if ( empty( $result ) ) { unset( $output[ $subtree ] ); } else { - $output[ $subtree ] = static::resolve_custom_css_format( $result ); + $output[ $subtree ] = self::resolve_custom_css_format( $result ); } } @@ -2509,7 +2509,7 @@ protected function get_css_variables( $nodes, $origins ) { continue; } - $target = static::get_feature_selector( $feature_selectors, $preset_metadata['path'][0], $selector ); + $target = self::get_feature_selector( $feature_selectors, $preset_metadata['path'][0], $selector ); if ( ! isset( $vars_by_selector[ $target ] ) ) { $vars_by_selector[ $target ] = array(); @@ -3307,7 +3307,7 @@ protected static function get_style_nodes( $theme_json, $selectors = array(), $o return $nodes; } - $block_nodes = static::get_block_nodes( $theme_json, $selectors, $options ); + $block_nodes = self::get_block_nodes( $theme_json, $selectors, $options ); foreach ( $block_nodes as $block_node ) { $nodes[] = $block_node; } @@ -3332,7 +3332,7 @@ protected static function get_style_nodes( $theme_json, $selectors = array(), $o * @return array The block nodes in theme.json. */ public function get_styles_block_nodes() { - return static::get_block_nodes( $this->theme_json ); + return self::get_block_nodes( $this->theme_json ); } /** @@ -3824,11 +3824,11 @@ public function get_styles_for_block( $block_metadata ) { // Update text indent selector for paragraph blocks based on the textIndent setting. $block_name = $block_metadata['name'] ?? null; - $feature_declarations = static::update_paragraph_text_indent_selector( $feature_declarations, $settings, $block_name ); + $feature_declarations = self::update_paragraph_text_indent_selector( $feature_declarations, $settings, $block_name ); $block_elements = $block_metadata['elements'] ?? array(); // Update button width declarations for percentage values to use calc() with block gap. - $feature_declarations = static::update_button_width_declarations( $feature_declarations, $settings ); + $feature_declarations = self::update_button_width_declarations( $feature_declarations, $settings ); // If there are style variations, generate the declarations for them, including any feature selectors the block may have. $style_variation_declarations = array(); @@ -3844,10 +3844,10 @@ public function get_styles_for_block( $block_metadata ) { $variation_declarations = static::get_feature_declarations_for_node( $block_metadata, $style_variation_node ); // Update text indent selector for paragraph blocks based on the textIndent setting. - $variation_declarations = static::update_paragraph_text_indent_selector( $variation_declarations, $settings, $block_name ); + $variation_declarations = self::update_paragraph_text_indent_selector( $variation_declarations, $settings, $block_name ); // Update button width declarations for percentage values to use calc() with block gap. - $variation_declarations = static::update_button_width_declarations( $variation_declarations, $settings ); + $variation_declarations = self::update_button_width_declarations( $variation_declarations, $settings ); // Combine selectors with style variation's selector and add to overall style variation declarations. foreach ( $variation_declarations as $current_selector => $new_declarations ) { @@ -3864,7 +3864,7 @@ public function get_styles_for_block( $block_metadata ) { if ( isset( $block_metadata['name'] ) ) { $block_name = $block_metadata['name']; } elseif ( in_array( 'blocks', $block_metadata['path'], true ) && count( $block_metadata['path'] ) >= 3 ) { - $block_name = static::get_block_name_from_metadata_path( $block_metadata ); + $block_name = self::get_block_name_from_metadata_path( $block_metadata ); } else { $block_name = null; } @@ -3902,8 +3902,8 @@ public function get_styles_for_block( $block_metadata ) { $breakpoint_media = $responsive_media_queries[ $breakpoint ]; // Process feature-level declarations for this breakpoint. $breakpoint_feature_declarations = static::get_feature_declarations_for_node( $block_metadata, $breakpoint_node ); - $breakpoint_feature_declarations = static::update_paragraph_text_indent_selector( $breakpoint_feature_declarations, $settings, $block_name ); - $breakpoint_feature_declarations = static::update_button_width_declarations( $breakpoint_feature_declarations, $settings ); + $breakpoint_feature_declarations = self::update_paragraph_text_indent_selector( $breakpoint_feature_declarations, $settings, $block_name ); + $breakpoint_feature_declarations = self::update_button_width_declarations( $breakpoint_feature_declarations, $settings ); foreach ( $breakpoint_feature_declarations as $feature_selector => $feature_decl ) { $combined_selectors = static::get_block_style_variation_feature_selector( $style_variation, $feature_selector ); @@ -4101,7 +4101,7 @@ static function ( $pseudo_selector ) use ( $selector ) { // Update declarations if there are separators with only background color defined. if ( '.wp-block-separator' === $selector ) { - $declarations = static::update_separator_declarations( $declarations ); + $declarations = self::update_separator_declarations( $declarations ); } /* @@ -4343,8 +4343,8 @@ public function merge( $incoming ) { // Generate and merge the scales for this layer. $sizes_path = array( 'settings', 'spacing', 'spacingSizes', $origin ); $spacing_sizes = _wp_array_get( $incoming_data, $sizes_path, array() ); - $spacing_scale_sizes = static::compute_spacing_sizes( $flattened_spacing_scale ); - $merged_spacing_sizes = static::merge_spacing_sizes( $spacing_scale_sizes, $spacing_sizes ); + $spacing_scale_sizes = self::compute_spacing_sizes( $flattened_spacing_scale ); + $merged_spacing_sizes = self::merge_spacing_sizes( $spacing_scale_sizes, $spacing_sizes ); _wp_array_set( $incoming_data, $sizes_path, $merged_spacing_sizes ); } @@ -4441,7 +4441,7 @@ public function merge( $incoming ) { * some values provide exceptions, namely style values that are * objects and represent unique definitions for the style. */ - $style_nodes = static::get_block_nodes( + $style_nodes = self::get_block_nodes( $this->theme_json, array(), array( 'include_node_paths_only' => true ) @@ -4681,7 +4681,7 @@ public static function remove_insecure_properties( $theme_json, $origin = 'theme } $block_name = in_array( 'blocks', $metadata['path'], true ) - ? static::get_block_name_from_metadata_path( $metadata ) + ? self::get_block_name_from_metadata_path( $metadata ) : null; // The global styles custom CSS is not sanitized, but can only be edited by users with 'edit_css' capability. @@ -5008,13 +5008,13 @@ protected static function remove_insecure_settings( $input, $is_root = false ) { } // Ensure indirect properties not included in any `PRESETS_METADATA` value are allowed. - static::remove_indirect_properties( $input, $output ); + self::remove_indirect_properties( $input, $output ); // Preserve all valid settings that have type markers in VALID_SETTINGS. self::preserve_valid_typed_settings( $input, $output, static::VALID_SETTINGS ); if ( $is_root && array_key_exists( 'viewport', $input ) ) { - $output['viewport'] = static::sanitize_viewport_settings( $input['viewport'] ); + $output['viewport'] = self::sanitize_viewport_settings( $input['viewport'] ); } return $output; @@ -5049,7 +5049,7 @@ protected static function remove_insecure_styles( $input ) { } // Ensure indirect properties not handled by `compute_style_properties` are allowed. - static::remove_indirect_properties( $input, $output ); + self::remove_indirect_properties( $input, $output ); return $output; } @@ -5382,7 +5382,7 @@ public function set_spacing_sizes() { return; } - $spacing_sizes = static::compute_spacing_sizes( $spacing_scale ); + $spacing_sizes = self::compute_spacing_sizes( $spacing_scale ); // If there are 7 or fewer steps in the scale revert to numbers for labels instead of t-shirt sizes. if ( $spacing_scale['steps'] <= 7 ) { @@ -5434,7 +5434,7 @@ private static function merge_spacing_sizes( $base, $incoming ) { * 'operator' => '+', * 'increment' => 2, * ); - * $spacing_sizes = static::compute_spacing_sizes( $spacing_scale ); + * $spacing_sizes = self::compute_spacing_sizes( $spacing_scale ); * // -> array( * // array( 'name' => 'Small', 'slug' => '40', 'size' => '14px' ), * // array( 'name' => 'Medium', 'slug' => '50', 'size' => '16px' ), diff --git a/tests/phpstan/baselines/staticClassAccess.privateMethod.neon b/tests/phpstan/baselines/staticClassAccess.privateMethod.neon deleted file mode 100644 index 7e8a5c1cf59e1..0000000000000 --- a/tests/phpstan/baselines/staticClassAccess.privateMethod.neon +++ /dev/null @@ -1,90 +0,0 @@ -# PHPStan baseline for the `staticClassAccess.privateMethod` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/staticClassAccess.privateMethod -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=staticClassAccess.privateMethod -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:compute_spacing_sizes\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 3 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:get_block_name_from_metadata_path\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:get_block_nodes\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 3 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:get_feature_selector\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:get_viewport_breakpoint_value_in_pixels\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:is_valid_viewport_breakpoint_size\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:merge_spacing_sizes\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:remove_indirect_properties\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 2 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:resolve_custom_css_format\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:sanitize_viewport_settings\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 3 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:unwrap_shared_block_style_variations\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:update_button_width_declarations\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 4 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:update_paragraph_text_indent_selector\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 4 - path: ../../../src/wp-includes/class-wp-theme-json.php - - - message: '#^Unsafe call to private method WP_Theme_JSON\:\:update_separator_declarations\(\) through static\:\:\.$#' - identifier: staticClassAccess.privateMethod - count: 1 - path: ../../../src/wp-includes/class-wp-theme-json.php From 032e6b69edb01a98dfc7b70bae3dd7d560fe7e98 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Fri, 28 Aug 2026 08:36:10 +0000 Subject: [PATCH 038/363] Themes: Correct slug generation for block template files. Block template and template part slugs are now derived by stripping the theme directory and the template directory from the front of the file path. Slugs are correct regardless of where the theme is located or how its folder is named, and for templates in nested subdirectories. Developed in https://github.com/WordPress/wordpress-develop/pull/12399 Props mamaduka, wildworks, yashjawale. Fixes #65580. git-svn-id: https://develop.svn.wordpress.org/trunk@63385 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/block-template-utils.php | 4 +- tests/phpunit/tests/block-template.php | 121 ++++++++++++++++++++++- 2 files changed, 122 insertions(+), 3 deletions(-) diff --git a/src/wp-includes/block-template-utils.php b/src/wp-includes/block-template-utils.php index d17aa174398e3..b8ccd0f94a137 100644 --- a/src/wp-includes/block-template-utils.php +++ b/src/wp-includes/block-template-utils.php @@ -415,8 +415,8 @@ function _get_block_templates_files( $template_type, $query = array() ) { $template_base_path = $template_base_paths[ $template_type ]; $template_slug = substr( $template_file, - // Starting position of slug. - strpos( $template_file, $template_base_path . DIRECTORY_SEPARATOR ) + 1 + strlen( $template_base_path ), + // Starting position of the slug - the theme directory and the template base path. + strlen( $theme_dir . DIRECTORY_SEPARATOR . $template_base_path . DIRECTORY_SEPARATOR ), // Subtract ending '.html'. -5 ); diff --git a/tests/phpunit/tests/block-template.php b/tests/phpunit/tests/block-template.php index e0307b5782165..bfa60dadd65bb 100644 --- a/tests/phpunit/tests/block-template.php +++ b/tests/phpunit/tests/block-template.php @@ -21,7 +21,6 @@ public function set_up() { public function tear_down() { global $_wp_current_template_id, $_wp_current_template_content; unset( $_wp_current_template_id, $_wp_current_template_content ); - parent::tear_down(); } @@ -509,6 +508,126 @@ public function test_get_block_templates_paths_dir_doesnt_exists() { $this->assertSame( array(), $template_paths ); } + /** + * Tests that `_get_block_templates_files()` derives the correct template + * slugs from the theme's template files. + * + * The base path (e.g. `parts` or `templates`) must not end up in the slug, + * even when the theme folder name itself ends with the base path. + * + * @ticket 65580 + * + * @covers ::_get_block_templates_files + * + * @dataProvider data_get_block_templates_files_slugs + * + * @param string $theme_directory Directory name used as the theme directory. + * @param string $template_type Template type. Either 'wp_template' or 'wp_template_part'. + * @param array $expected_slugs Expected template slugs. + */ + public function test_get_block_templates_files_slugs( $theme_directory, $template_type, $expected_slugs ) { + $theme_root = sys_get_temp_dir() . '/wp-tests-block-template-slug-' . uniqid(); + $theme_dir = $theme_root . '/' . $theme_directory; + + $relative_paths = array( + 'parts/header.html', + 'parts/footer.html', + 'parts/footer-parts/header.html', + 'templates/index.html', + 'templates/footer.html', + ); + + $files = array(); + foreach ( $relative_paths as $relative_path ) { + $file_path = $theme_dir . '/' . $relative_path; + wp_mkdir_p( dirname( $file_path ) ); + touch( $file_path ); + $files[] = $file_path; + } + + add_filter( + 'stylesheet_directory', + static function () use ( $theme_dir ) { + return $theme_dir; + } + ); + + $slugs = wp_list_pluck( _get_block_templates_files( $template_type ), 'slug' ); + sort( $slugs ); + + // Collect every directory for cleanup. + $directories = array( $theme_root ); + foreach ( $files as $file_path ) { + $directory = dirname( $file_path ); + while ( strlen( $directory ) >= strlen( $theme_root ) ) { + $directories[] = $directory; + $directory = dirname( $directory ); + } + } + $directories = array_values( array_unique( $directories ) ); + + rsort( $directories ); + + foreach ( $files as $file_path ) { + unlink( $file_path ); + } + foreach ( $directories as $directory ) { + rmdir( $directory ); + } + + $this->assertSame( $expected_slugs, $slugs ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_get_block_templates_files_slugs() { + return array( + 'template parts in a theme whose directory name does not end with parts' => array( + 'theme_directory' => 'default', + 'template_type' => 'wp_template_part', + 'expected_slugs' => array( 'footer', 'footer-parts/header', 'header' ), + ), + 'templates in a theme whose directory name does not end with parts' => array( + 'theme_directory' => 'default', + 'template_type' => 'wp_template', + 'expected_slugs' => array( 'footer', 'index' ), + ), + 'template parts in a theme whose directory name ends with parts' => array( + 'theme_directory' => 'auto-parts', + 'template_type' => 'wp_template_part', + 'expected_slugs' => array( 'footer', 'footer-parts/header', 'header' ), + ), + 'templates in a theme whose directory name ends with parts' => array( + 'theme_directory' => 'auto-parts', + 'template_type' => 'wp_template', + 'expected_slugs' => array( 'footer', 'index' ), + ), + 'template parts in a theme whose directory name is exactly parts' => array( + 'theme_directory' => 'parts', + 'template_type' => 'wp_template_part', + 'expected_slugs' => array( 'footer', 'footer-parts/header', 'header' ), + ), + 'templates in a theme whose directory name ends with templates' => array( + 'theme_directory' => 'my-templates', + 'template_type' => 'wp_template', + 'expected_slugs' => array( 'footer', 'index' ), + ), + 'template parts in a theme placed inside a directory named parts' => array( + 'theme_directory' => 'parts/default', + 'template_type' => 'wp_template_part', + 'expected_slugs' => array( 'footer', 'footer-parts/header', 'header' ), + ), + 'templates in a theme placed inside a directory named templates' => array( + 'theme_directory' => 'templates/default', + 'template_type' => 'wp_template', + 'expected_slugs' => array( 'footer', 'index' ), + ), + ); + } + /** * Tests that get_block_templates() returns plugin-registered templates. * From 7b282cdfe900de724dca9236165bd12dba66ade7 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 28 Aug 2026 09:31:10 +0000 Subject: [PATCH 039/363] Administration: Fix the CSS Coding Standards in buttons.css. Lints the `src/wp-includes/css/buttons.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13159 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63386 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/buttons.css | 37 ++++++++++++++------------------- 1 file changed, 16 insertions(+), 21 deletions(-) diff --git a/src/wp-includes/css/buttons.css b/src/wp-includes/css/buttons.css index 57d5754483199..3d9650c98cc89 100644 --- a/src/wp-includes/css/buttons.css +++ b/src/wp-includes/css/buttons.css @@ -36,9 +36,9 @@ TABLE OF CONTENTS: ---------------------------------------------------------------------------- */ -/* ---------------------------------------------------------------------------- - 1.0 - Button Layouts ----------------------------------------------------------------------------- */ +/** + * 1.0 Button Layouts + */ .wp-core-ui .button, .wp-core-ui .button-primary, @@ -141,9 +141,9 @@ TABLE OF CONTENTS: width: auto; } -/* ---------------------------------------------------------------------------- - 2.0 - Default Button Style ----------------------------------------------------------------------------- */ +/** + * 2.0 Default Button Style + */ .wp-core-ui .button, .wp-core-ui .button-secondary { @@ -241,7 +241,7 @@ TABLE OF CONTENTS: color: var(--wp-admin-theme-color, #3858e9); text-decoration: underline; transition-property: border, background, color; - transition-duration: .05s; + transition-duration: 0.05s; transition-timing-function: ease-in-out; } @@ -273,10 +273,9 @@ TABLE OF CONTENTS: background: transparent !important; } - -/* ---------------------------------------------------------------------------- - 3.0 - Primary Button Style ----------------------------------------------------------------------------- */ +/** + * 3.0 Primary Button Style + */ .wp-core-ui .button-primary { background: var(--wp-admin-theme-color, #3858e9); @@ -330,9 +329,9 @@ TABLE OF CONTENTS: cursor: default; } -/* ---------------------------------------------------------------------------- - 4.0 - Button Groups ----------------------------------------------------------------------------- */ +/** + * 4.0 Button Groups + */ .wp-core-ui .button-group { position: relative; @@ -376,12 +375,11 @@ TABLE OF CONTENTS: box-shadow: inset 0 2px 6px -2px var(--wp-admin-theme-color-darker-20), 0 0 0 var(--wp-admin-border-width-focus, 1.5px) var(--wp-admin-theme-color); } -/* ---------------------------------------------------------------------------- - 5.0 - Responsive Button Styles ----------------------------------------------------------------------------- */ +/** + * 5.0 Responsive Button Styles + */ @media screen and (max-width: 782px) { - .wp-core-ui .button, .wp-core-ui .button.button-large, .wp-core-ui .button.button-compact, @@ -427,7 +425,6 @@ TABLE OF CONTENTS: } /* Reset responsive styles in Press This, Customizer */ - .wp-core-ui.wp-customizer .button { font-size: 13px; line-height: 2.30769231; /* 30px */ @@ -446,11 +443,9 @@ TABLE OF CONTENTS: } /* Reset responsive styles on Log in button on iframed login form */ - .interim-login .button.button-large { min-height: 32px; line-height: 2.30769231; /* 30px */ padding: 0 12px; } - } From 9748195729dc4266b2dd280e3a7dbbc29402472c Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 28 Aug 2026 09:37:05 +0000 Subject: [PATCH 040/363] Administration: Fix the CSS Coding Standards in l10n.css. Lints the `src/wp-admin/css/l10n.css` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13141 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63387 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/l10n.css | 25 ++++++++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/css/l10n.css b/src/wp-admin/css/l10n.css index 2d0b9b2145f69..18458c4872469 100644 --- a/src/wp-admin/css/l10n.css +++ b/src/wp-admin/css/l10n.css @@ -49,27 +49,37 @@ body.locale-he-il .press-this a.wp-switch-editor { } /* zh_CN: Enlarge dashboard widget 'Configure' link */ -.locale-zh-cn .hdnle a { font-size: 12px; } +.locale-zh-cn .hdnle a { + font-size: 12px; +} /* zn_CH: Enlarge font size, set font-size: normal */ -.locale-zh-cn form.upgrade .hint { font-style: normal; font-size: 100%; } +.locale-zh-cn form.upgrade .hint { + font-style: normal; + font-size: 100%; +} /* zh_CN: Enlarge font-size. */ -.locale-zh-cn #sort-buttons { font-size: 1em !important; } +.locale-zh-cn #sort-buttons { + font-size: 1em !important; +} /* de_DE: Text needs more space for translation */ .locale-de-de #customize-header-actions .button, .locale-de-de-formal #customize-header-actions .button { padding: 0 5px 1px; /* default 0 10px 1px */ } + .locale-de-de #customize-header-actions .spinner, .locale-de-de-formal #customize-header-actions .spinner { margin: 16px 3px 0; /* default 16px 4px 0 5px */ } + body[class*="locale-de-"] .inline-edit-row fieldset label span.title, body[class*="locale-de-"] .inline-edit-row fieldset.inline-edit-date legend { width: 7em; /* default 6em */ } + body[class*="locale-de-"] .inline-edit-row fieldset label span.input-text-wrap, body[class*="locale-de-"] .inline-edit-row fieldset .timestamp-wrap { margin-left: 7em; /* default 6em */ @@ -79,31 +89,39 @@ body[class*="locale-de-"] .inline-edit-row fieldset .timestamp-wrap { .locale-ru-ru #adminmenu { width: inherit; /* back-compat for pre-3.2 */ } + .locale-ru-ru #adminmenu, .locale-ru-ru #wpbody { margin-left: 0; /* back-compat for pre-3.2 */ } + .locale-ru-ru .inline-edit-row fieldset label span.title, .locale-ru-ru .inline-edit-row fieldset.inline-edit-date legend { width: 8em; /* default 6em */ } + .locale-ru-ru .inline-edit-row fieldset label span.input-text-wrap, .locale-ru-ru .inline-edit-row fieldset .timestamp-wrap { margin-left: 8em; /* default 6em */ } + .locale-ru-ru.post-php .tagsdiv .newtag, .locale-ru-ru.post-new-php .tagsdiv .newtag { width: 165px; /* default 180px - 15px */ } + .locale-ru-ru.press-this .posting { margin-right: 277px; /* default 252px + 25px */ } + .locale-ru-ru .press-this-sidebar { width: 265px; /* default 240px + 25px */ } + .locale-ru-ru #customize-header-actions .button { padding: 0 5px 1px; /* default 0 10px 1px */ } + .locale-ru-ru #customize-header-actions .spinner { margin: 16px 3px 0; /* default 16px 4px 0 5px */ } @@ -113,6 +131,7 @@ body[class*="locale-de-"] .inline-edit-row fieldset .timestamp-wrap { .locale-lt-lt .inline-edit-row fieldset.inline-edit-date legend { width: 8em; /* default 6em */ } + .locale-lt-lt .inline-edit-row fieldset label span.input-text-wrap, .locale-lt-lt .inline-edit-row fieldset .timestamp-wrap { margin-left: 8em; /* default 6em */ From d5f778399d4d34c6811e53ac23c552a943c109bb Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 28 Aug 2026 09:40:34 +0000 Subject: [PATCH 041/363] Administration: Fix the CSS Coding Standards in sunrise colors.scss. Lints the `src/wp-admin/css/colors/sunrise/colors.scss` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13176 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63388 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/colors/sunrise/colors.scss | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/wp-admin/css/colors/sunrise/colors.scss b/src/wp-admin/css/colors/sunrise/colors.scss index 3a00c91778d79..a1ef34054906e 100644 --- a/src/wp-admin/css/colors/sunrise/colors.scss +++ b/src/wp-admin/css/colors/sunrise/colors.scss @@ -1,10 +1,10 @@ @use "../_admin.scss" with ( - $scheme-name: "sunrise", - $base-color: #8a312d, - $highlight-color: #ad631e, - $notification-color: #ccaf0b, - $menu-highlight-text: #fff, - $menu-highlight-icon: #fff, - $menu-bubble-text: #1e1e1e, - $menu-submenu-focus-text: #fff + $scheme-name: "sunrise", + $base-color: #8a312d, + $highlight-color: #ad631e, + $notification-color: #ccaf0b, + $menu-highlight-text: #fff, + $menu-highlight-icon: #fff, + $menu-bubble-text: #1e1e1e, + $menu-submenu-focus-text: #fff ); From 0953851a48c728b608a437cd5e8380c044544805 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 28 Aug 2026 09:44:02 +0000 Subject: [PATCH 042/363] Administration: Fix the CSS Coding Standards in _variables.scss. Lints the `src/wp-admin/css/colors/_variables.scss` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13175 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63389 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/colors/_variables.scss | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/wp-admin/css/colors/_variables.scss b/src/wp-admin/css/colors/_variables.scss index d37c2b1392f00..6c0c15f4bb3ab 100644 --- a/src/wp-admin/css/colors/_variables.scss +++ b/src/wp-admin/css/colors/_variables.scss @@ -15,7 +15,6 @@ $icon-color: hsl(color.channel($base-color, "hue", $space: hsl), 7%, 95%) !defau $highlight-color: #0073aa !default; $notification-color: #d54e21 !default; - // global $body-background: $gray-100 !default; @@ -42,7 +41,7 @@ $menu-current-text: $menu-highlight-text !default; $menu-current-icon: $menu-highlight-icon !default; $menu-current-background: $menu-highlight-background !default; -$menu-submenu-text: color.mix( $base-color, $text-color, 30% ) !default; +$menu-submenu-text: color.mix($base-color, $text-color, 30%) !default; $menu-submenu-background: color.adjust($base-color, $lightness: -7%) !default; $menu-submenu-background-alt: color.adjust(color.adjust($menu-background, $lightness: 7%), $saturation: -7%) !default; @@ -64,9 +63,9 @@ $adminbar-input-background: color.adjust($menu-background, $lightness: 7%) !defa $adminbar-recovery-exit-text: $menu-bubble-text !default; $adminbar-recovery-exit-background: $menu-bubble-background !default; -$adminbar-recovery-exit-background-alt: color.mix(black, $adminbar-recovery-exit-background, 10%) !default; +$adminbar-recovery-exit-background-alt: color.mix(#000, $adminbar-recovery-exit-background, 10%) !default; -$menu-customizer-text: color.mix( $base-color, $text-color, 40% ) !default; +$menu-customizer-text: color.mix($base-color, $text-color, 40%) !default; // Dashboard Colors From 1bff82b2820bbcc98b2da751f8a8c1c07701e93e Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 28 Aug 2026 09:46:42 +0000 Subject: [PATCH 043/363] Administration: Fix the CSS Coding Standards in _mixins.scss. Lints the `src/wp-admin/css/colors/_mixins.scss` file. Part of the ongoing effort to lint all the admin CSS files. Developed in https://github.com/WordPress/wordpress-develop/pull/13173 See #65898. git-svn-id: https://develop.svn.wordpress.org/trunk@63390 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/colors/_mixins.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-admin/css/colors/_mixins.scss b/src/wp-admin/css/colors/_mixins.scss index 9575f1f2d623b..7b3802307a637 100644 --- a/src/wp-admin/css/colors/_mixins.scss +++ b/src/wp-admin/css/colors/_mixins.scss @@ -1,5 +1,5 @@ -@use 'sass:color'; -@use 'tokens'; +@use "sass:color"; +@use "tokens"; /* * Button mixin - creates a primary button effect. From f3c74e13a9afdb95ca7ad68a5fd69fe5aa1f61bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Greg=20Zi=C3=B3=C5=82kowski?= Date: Fri, 28 Aug 2026 11:09:30 +0000 Subject: [PATCH 044/363] Abilities API: Add missing `@since 7.1.0` changelog entries Document the 7.1 changes to existing docblocks that had no changelog line: the `public` meta argument, the `wp_ability_validate_input` and `wp_ability_validate_output` filters, exception handling in `invoke_callback()`, and the new schema property and collection parameters in the REST list controller. Follow-up to [62238], [62398], [62420], [62548], [62729], [62737]. Props khokansardar. See #65058, #64311, #64990, #65568. git-svn-id: https://develop.svn.wordpress.org/trunk@63391 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/abilities-api.php | 1 + .../abilities-api/class-wp-abilities-registry.php | 2 ++ src/wp-includes/abilities-api/class-wp-ability.php | 5 +++++ .../endpoints/class-wp-rest-abilities-v1-list-controller.php | 2 ++ 4 files changed, 10 insertions(+) diff --git a/src/wp-includes/abilities-api.php b/src/wp-includes/abilities-api.php index 92e13f1b489fc..393e40b56ed8c 100644 --- a/src/wp-includes/abilities-api.php +++ b/src/wp-includes/abilities-api.php @@ -232,6 +232,7 @@ * ), * * @since 6.9.0 + * @since 7.1.0 Added the `public` meta argument. * @since 7.2.0 The `category` argument is now optional and defaults to `uncategorized`. * * @see WP_Abilities_Registry::register() diff --git a/src/wp-includes/abilities-api/class-wp-abilities-registry.php b/src/wp-includes/abilities-api/class-wp-abilities-registry.php index cc795a1a8a430..813c3dd49f7be 100644 --- a/src/wp-includes/abilities-api/class-wp-abilities-registry.php +++ b/src/wp-includes/abilities-api/class-wp-abilities-registry.php @@ -40,6 +40,7 @@ final class WP_Abilities_Registry { * Do not use this method directly. Instead, use the `wp_register_ability()` function. * * @since 6.9.0 + * @since 7.1.0 Added the `public` meta argument. * @since 7.2.0 The `category` argument is now optional and defaults to `uncategorized`. * * @see wp_register_ability() @@ -110,6 +111,7 @@ public function register( string $name, array $args ): ?WP_Ability { * Filters the ability arguments before they are validated and used to instantiate the ability. * * @since 6.9.0 + * @since 7.1.0 Added the `public` meta argument. * @since 7.2.0 The `category` argument is now optional and defaults to `uncategorized`. * * @param array $args { diff --git a/src/wp-includes/abilities-api/class-wp-ability.php b/src/wp-includes/abilities-api/class-wp-ability.php index 9efefc6713f5a..8f2d431f05318 100644 --- a/src/wp-includes/abilities-api/class-wp-ability.php +++ b/src/wp-includes/abilities-api/class-wp-ability.php @@ -139,6 +139,7 @@ class WP_Ability { * @access private * * @since 6.9.0 + * @since 7.1.0 Added the `public` meta argument. * * @see wp_register_ability() * @@ -209,6 +210,7 @@ public function __construct( string $name, array $args ) { * caught and converted to a WP_Error by WP_Abilities_Registry::register(). * * @since 6.9.0 + * @since 7.1.0 Added the `public` meta argument. * * @see WP_Abilities_Registry::register() * @@ -512,6 +514,7 @@ public function normalize_input( $input = null ) { * Validates input data against the input schema. * * @since 6.9.0 + * @since 7.1.0 Added the `wp_ability_validate_input` filter. * * @param mixed $input Optional. The input data to validate. Default `null`. * @return true|WP_Error Returns true if valid or the WP_Error object if validation fails. @@ -577,6 +580,7 @@ public function validate_input( $input = null ) { * Invokes a callable, ensuring the input is passed through only if the input schema is defined. * * @since 6.9.0 + * @since 7.1.0 Exceptions thrown by the callback are now caught and returned as a `WP_Error`. * * @param callable $callback The callable to invoke. * @param mixed $input Optional. The input data for the ability. Default `null`. @@ -705,6 +709,7 @@ protected function do_execute( $input = null ) { * Validates output data against the output schema. * * @since 6.9.0 + * @since 7.1.0 Added the `wp_ability_validate_output` filter. * * @param mixed $output The output data to validate. * @return true|WP_Error Returns true if valid, or a WP_Error object if validation fails. diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-abilities-v1-list-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-abilities-v1-list-controller.php index 97d97ce379e8d..5547e7e002f02 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-abilities-v1-list-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-abilities-v1-list-controller.php @@ -244,6 +244,7 @@ public function prepare_item_for_response( $ability, $request ) { * Retrieves the ability's schema, conforming to JSON Schema. * * @since 6.9.0 + * @since 7.1.0 Added the `meta.public` property. * * @return array Item schema data. */ @@ -330,6 +331,7 @@ public function get_item_schema(): array { * Retrieves the query params for collections. * * @since 6.9.0 + * @since 7.1.0 Added the `namespace` and `meta` parameters and the `rest_abilities_collection_params` filter. * * @return array Collection parameters. */ From 06c6908f94a20f7b92cc7e905c5377f2431c1ed4 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 28 Aug 2026 13:23:59 +0000 Subject: [PATCH 045/363] Build/Test Tools: Update the `lint:jsdoc` configuration to be compatible with ESLint v10. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The JSDoc ESLint script is meant to check the JSDocs conformity with the ​WordPress JavaScript Docs Coding Standards. It was added in the context of ​the ​JavaScript Inline Docs Initiative, aimed to improve JavaScript documentation across the codebase. The new ESLint v10 provided by `@wordpress/scripts` requires a different configuration format. This change updates the configuration as needed, replicating as much as possible the previous configuration based on the `valid-jsdoc` rules. Developed in https://github.com/WordPress/wordpress-develop/pull/13237 Props afercia, mciampini. Fixes #65939. git-svn-id: https://develop.svn.wordpress.org/trunk@63392 602fd350-edb4-49c9-b593-d223f7449a82 --- .eslintignore | 26 -------------- .eslintrc-jsdoc.js | 85 +++++++++++++++++++++++++++++++--------------- eslint.config.js | 38 +++++++++++++++++++++ 3 files changed, 96 insertions(+), 53 deletions(-) delete mode 100644 .eslintignore create mode 100644 eslint.config.js diff --git a/.eslintignore b/.eslintignore deleted file mode 100644 index 9b3144df5c64d..0000000000000 --- a/.eslintignore +++ /dev/null @@ -1,26 +0,0 @@ -# Files and folders related to build/test tools including generated files -/build -/node_modules -/tests -/vendor -/tools -/jsdoc -/artifacts -/coverage -.cache/* -/src/wp-includes/blocks/**/*.js -/src/wp-includes/blocks/**/*.js.map -/src/wp-admin/js -/src/wp-includes/js - -# Excluded files and folders based on `jsdoc.conf.json` exclusions -/src/js/_enqueues/vendor - -# Themes -src/wp-content/themes - -# Files and folders that get created in wp-content -/src/wp-content/plugins -/src/wp-content/mu-plugins -/src/wp-content/upgrade -/src/wp-content/uploads diff --git a/.eslintrc-jsdoc.js b/.eslintrc-jsdoc.js index 6f7351ec08945..1e1059efeed2a 100644 --- a/.eslintrc-jsdoc.js +++ b/.eslintrc-jsdoc.js @@ -1,29 +1,60 @@ -module.exports = { - rules: { - 'require-jsdoc': 'off', - 'valid-jsdoc': [ 'error', { - prefer: { - arg: 'param', - argument: 'param', - extends: 'augments', - returns: 'return', +/** + * ESLint v10 flat config file for JSDoc linting. + * This config is based on the original valid-jsdoc rules. + */ + +const jsdocPlugin = require( 'eslint-plugin-jsdoc' ); + +module.exports = [ + { + plugins: { + jsdoc: jsdocPlugin, + }, + settings: { + jsdoc: { + tagNamePreference: { + 'arg': 'param', + 'argument': 'param', + 'extends': 'augments', + 'returns': 'return', + }, + preferredTypes: { + 'array': 'Array', + 'bool': 'boolean', + 'Boolean': 'boolean', + 'float': 'number', + 'Float': 'number', + 'function': 'Function', + 'int': 'number', + 'integer': 'number', + 'Integer': 'number', + 'Number': 'number', + 'object': 'Object', + 'String': 'string', + 'Void': 'void', + }, }, - preferType: { - array: 'Array', - bool: 'boolean', - Boolean: 'boolean', - float: 'number', - Float: 'number', - int: 'number', - integer: 'number', - Integer: 'number', - Number: 'number', - object: 'Object', - String: 'string', - Void: 'void', - }, - requireParamDescription: false, - requireReturn: false, - } ], + }, + rules: { + 'jsdoc/check-param-names': 'error', + 'jsdoc/check-types': 'error', + 'jsdoc/check-tag-names': [ 'error', { + definedTags: [ + 'memberOf', + 'output', + 'ticket', + 'link', + ], + } ], + 'jsdoc/require-param': [ 'error', { + enableFixer: false, + } ], + 'jsdoc/require-param-type': 'error', + 'jsdoc/require-returns-check': 'error', + 'jsdoc/require-returns-description': 'error', + 'jsdoc/require-returns': 'error', + 'jsdoc/require-returns-type': 'error', + 'jsdoc/check-syntax': 'error', + }, }, -}; +]; diff --git a/eslint.config.js b/eslint.config.js new file mode 100644 index 0000000000000..a3f2f384d7d7b --- /dev/null +++ b/eslint.config.js @@ -0,0 +1,38 @@ +/** + * ESLint v10 flat config entry point. + * + * This minimal config focuses only on JSDoc linting by importing + * the configuration from .eslintrc-jsdoc.js. + * + * General JavaScript linting is not performed here. + */ + +const jsdocConfig = require( './.eslintrc-jsdoc.js' ); + +module.exports = [ + ...jsdocConfig, + { + ignores: [ + 'build/**', + '**/build/**', + 'node_modules/**', + 'tests/**', + 'vendor/**', + 'tools/**', + 'jsdoc/**', + 'artifacts/**', + 'coverage/**', + '.cache/**', + 'src/wp-includes/blocks/**/*.js', + 'src/wp-includes/blocks/**/*.js.map', + 'src/wp-content/themes/**', + 'src/wp-content/plugins/**', + 'src/wp-content/mu-plugins/**', + 'src/wp-content/upgrade/**', + 'src/wp-content/uploads/**', + 'src/js/_enqueues/vendor/**', + 'src/wp-admin/js/**', + 'src/wp-includes/js/**', + ], + }, +]; From 67c01d5705e932507dd0f30d3b439ec7dafd0282 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 28 Aug 2026 21:09:19 +0000 Subject: [PATCH 046/363] XML-RPC: Require the `$fields` argument to be an array. Ten `wp.*` methods accept an optional `$fields` argument from the client and pass it straight through to the `_prepare_*()` helpers, where `in_array()` raises a fatal `TypeError` as soon as the value is not an array. A new `wp_xmlrpc_server::_is_fields_array()` helper now checks the argument up front, so a malformed request returns a 400 `IXR_Error` to the client instead of taking the request down with a fatal error. The affected methods are `wp.getPost`, `wp.getPosts`, `wp.getTaxonomy`, `wp.getTaxonomies`, `wp.getUser`, `wp.getUsers`, `wp.getProfile`, `wp.getPostType`, `wp.getPostTypes`, and `wp.getRevisions`. Unit tests covering each of them are included, along with the `@since` entries that were missing from `wp_getUser()`, `wp_getUsers()`, and `wp_getProfile()`. Developed in https://github.com/WordPress/wordpress-develop/pull/13299. Props josephscott, westonruter. Fixes #65983. git-svn-id: https://develop.svn.wordpress.org/trunk@63393 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-xmlrpc-server.php | 75 +++++++++++++++++++ tests/phpunit/tests/xmlrpc/wp/getPost.php | 12 +++ tests/phpunit/tests/xmlrpc/wp/getPostType.php | 14 ++++ .../phpunit/tests/xmlrpc/wp/getPostTypes.php | 14 ++++ tests/phpunit/tests/xmlrpc/wp/getPosts.php | 14 ++++ tests/phpunit/tests/xmlrpc/wp/getProfile.php | 14 ++++ .../phpunit/tests/xmlrpc/wp/getRevisions.php | 15 ++++ .../phpunit/tests/xmlrpc/wp/getTaxonomies.php | 14 ++++ tests/phpunit/tests/xmlrpc/wp/getTaxonomy.php | 14 ++++ tests/phpunit/tests/xmlrpc/wp/getUser.php | 12 +++ tests/phpunit/tests/xmlrpc/wp/getUsers.php | 14 ++++ 11 files changed, 212 insertions(+) diff --git a/src/wp-includes/class-wp-xmlrpc-server.php b/src/wp-includes/class-wp-xmlrpc-server.php index 1061dbd1831d2..506b3faebd1c8 100644 --- a/src/wp-includes/class-wp-xmlrpc-server.php +++ b/src/wp-includes/class-wp-xmlrpc-server.php @@ -808,6 +808,25 @@ protected function minimum_args( $args, $count ) { return true; } + /** + * Checks that the `$fields` argument received from a client is an array. + * + * @since 7.2.0 + * + * @param mixed $fields The `$fields` argument to check. + * @return bool True if `$fields` is an array, false otherwise. + * + * @phpstan-assert-if-true array $fields + */ + protected function _is_fields_array( $fields ): bool { + if ( ! is_array( $fields ) ) { + $this->error = new IXR_Error( 400, __( 'The fields argument must be an array.' ) ); + return false; + } + + return true; + } + /** * Prepares taxonomy data for return in an XML-RPC object. * @@ -1871,6 +1890,7 @@ public function wp_deletePost( $args ) { * Retrieves a post. * * @since 3.4.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * The optional $fields parameter specifies what fields will be included * in the response array. This should be a list of field names. 'post_id' will @@ -1928,6 +1948,10 @@ public function wp_getPost( $args ) { $post_id = (int) $args[3]; if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** @@ -1967,6 +1991,7 @@ public function wp_getPost( $args ) { * Retrieves posts. * * @since 3.4.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * @see wp_get_recent_posts() * @see wp_getPost() for more on `$fields` @@ -1997,6 +2022,10 @@ public function wp_getPosts( $args ) { $filter = $args[3] ?? array(); if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */ @@ -2534,6 +2563,7 @@ public function wp_getTerms( $args ) { * Retrieves a taxonomy. * * @since 3.4.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * @see get_taxonomy() * @@ -2562,6 +2592,10 @@ public function wp_getTaxonomy( $args ) { $taxonomy = $args[3]; if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** @@ -2601,6 +2635,7 @@ public function wp_getTaxonomy( $args ) { * Retrieves all taxonomies. * * @since 3.4.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * @see get_taxonomies() * @@ -2628,6 +2663,10 @@ public function wp_getTaxonomies( $args ) { $filter = $args[3] ?? array( 'public' => true ); if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */ @@ -2670,6 +2709,9 @@ public function wp_getTaxonomies( $args ) { * names can be used to specify multiple fields. The available conceptual * groups are 'basic' and 'all'. * + * @since 3.5.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. + * * @uses get_userdata() * * @param array $args { @@ -2707,6 +2749,10 @@ public function wp_getUser( $args ) { $user_id = (int) $args[3]; if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** @@ -2751,6 +2797,9 @@ public function wp_getUser( $args ) { * The optional $fields parameter specifies what fields will be included * in the response array. * + * @since 3.5.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. + * * @uses get_users() * @see wp_getUser() for more on $fields and return values * @@ -2777,6 +2826,10 @@ public function wp_getUsers( $args ) { $filter = $args[3] ?? array(); if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */ @@ -2834,6 +2887,9 @@ public function wp_getUsers( $args ) { /** * Retrieves information about the requesting user. * + * @since 3.5.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. + * * @uses get_userdata() * * @param array $args { @@ -2857,6 +2913,10 @@ public function wp_getProfile( $args ) { $password = $args[2]; if ( isset( $args[3] ) ) { + if ( ! $this->_is_fields_array( $args[3] ) ) { + return $this->error; + } + $fields = $args[3]; } else { /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */ @@ -4533,6 +4593,7 @@ public function wp_getPostFormats( $args ) { * Retrieves a post type. * * @since 3.4.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * @see get_post_type_object() * @@ -4568,6 +4629,10 @@ public function wp_getPostType( $args ) { $post_type_name = $args[3]; if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** @@ -4607,6 +4672,7 @@ public function wp_getPostType( $args ) { * Retrieves post types. * * @since 3.4.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * @see get_post_types() * @@ -4633,6 +4699,10 @@ public function wp_getPostTypes( $args ) { $filter = $args[3] ?? array( 'public' => true ); if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** This action is documented in wp-includes/class-wp-xmlrpc-server.php */ @@ -4666,6 +4736,7 @@ public function wp_getPostTypes( $args ) { * Retrieves revisions for a specific post. * * @since 3.5.0 + * @since 7.2.0 Returns an error if the `$fields` argument is not an array. * * The optional $fields parameter specifies what fields will be included * in the response array. @@ -4696,6 +4767,10 @@ public function wp_getRevisions( $args ) { $post_id = (int) $args[3]; if ( isset( $args[4] ) ) { + if ( ! $this->_is_fields_array( $args[4] ) ) { + return $this->error; + } + $fields = $args[4]; } else { /** diff --git a/tests/phpunit/tests/xmlrpc/wp/getPost.php b/tests/phpunit/tests/xmlrpc/wp/getPost.php index be25ca2770238..72a0685a8a11a 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getPost.php +++ b/tests/phpunit/tests/xmlrpc/wp/getPost.php @@ -147,4 +147,16 @@ public function test_valid_page() { $this->assertEquals( $parent_page_id, $result['post_parent'] ); $this->assertSame( 2, $result['menu_order'] ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $result = $this->myxmlrpcserver->wp_getPost( array( 1, 'author', 'author', $this->post_id, 'post' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getPostType.php b/tests/phpunit/tests/xmlrpc/wp/getPostType.php index 0a791d3517581..f3f34cc1bd9ab 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getPostType.php +++ b/tests/phpunit/tests/xmlrpc/wp/getPostType.php @@ -123,4 +123,18 @@ public function test_valid_type() { $this->assertSame( $value, $result[ $key ] ); } } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + + $result = $this->myxmlrpcserver->wp_getPostType( array( 1, 'editor', 'editor', 'post', 'labels' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getPostTypes.php b/tests/phpunit/tests/xmlrpc/wp/getPostTypes.php index cb12c6958e29f..dbd94ec33007f 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getPostTypes.php +++ b/tests/phpunit/tests/xmlrpc/wp/getPostTypes.php @@ -40,4 +40,18 @@ public function test_simple_filter() { $this->assertContains( 'page', $result_names ); $this->assertNotContains( 'post', $result_names ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + + $result = $this->myxmlrpcserver->wp_getPostTypes( array( 1, 'editor', 'editor', array(), 'labels' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getPosts.php b/tests/phpunit/tests/xmlrpc/wp/getPosts.php index 1369aaaae2844..b1ab560886eb9 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getPosts.php +++ b/tests/phpunit/tests/xmlrpc/wp/getPosts.php @@ -169,4 +169,18 @@ public function test_search() { $this->assertNotIXRError( $results ); $this->assertCount( 1, $results ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + + $result = $this->myxmlrpcserver->wp_getPosts( array( 1, 'editor', 'editor', array(), 'post' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getProfile.php b/tests/phpunit/tests/xmlrpc/wp/getProfile.php index 9893243cc6f26..c9325ade3d670 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getProfile.php +++ b/tests/phpunit/tests/xmlrpc/wp/getProfile.php @@ -45,4 +45,18 @@ public function test_arbitrary_fields() { sort( $keys ); $this->assertSameSets( $expected_fields, $keys ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + + $result = $this->myxmlrpcserver->wp_getProfile( array( 1, 'editor', 'editor', 'all' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getRevisions.php b/tests/phpunit/tests/xmlrpc/wp/getRevisions.php index 893a7a06dae93..01d8614460d8d 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getRevisions.php +++ b/tests/phpunit/tests/xmlrpc/wp/getRevisions.php @@ -77,4 +77,19 @@ public function test_revision_count_for_auto_draft_post_creation() { $result = $this->myxmlrpcserver->wp_getRevisions( array( 1, 'editor', 'editor', $post_id ) ); $this->assertCount( 1, $result ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + $post_id = self::factory()->post->create(); + + $result = $this->myxmlrpcserver->wp_getRevisions( array( 1, 'editor', 'editor', $post_id, 'post_date' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getTaxonomies.php b/tests/phpunit/tests/xmlrpc/wp/getTaxonomies.php index 13c78781813c0..ab5cadb19f8a6 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getTaxonomies.php +++ b/tests/phpunit/tests/xmlrpc/wp/getTaxonomies.php @@ -17,4 +17,18 @@ public function test_taxonomy_validated() { $result = $this->myxmlrpcserver->wp_getTaxonomies( array( 1, 'editor', 'editor' ) ); $this->assertNotIXRError( $result ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + + $result = $this->myxmlrpcserver->wp_getTaxonomies( array( 1, 'editor', 'editor', array(), 'labels' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getTaxonomy.php b/tests/phpunit/tests/xmlrpc/wp/getTaxonomy.php index be94db724d1ca..59e65b9e54c04 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getTaxonomy.php +++ b/tests/phpunit/tests/xmlrpc/wp/getTaxonomy.php @@ -75,4 +75,18 @@ public function test_taxonomy_with_menu_field_specified() { $this->assertNotIXRError( $result ); $this->assertTrue( $result['show_in_menu'] ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'editor' ); + + $result = $this->myxmlrpcserver->wp_getTaxonomy( array( 1, 'editor', 'editor', 'category', 'labels' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getUser.php b/tests/phpunit/tests/xmlrpc/wp/getUser.php index c9392bb1ce312..8cfb34ae3e7eb 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getUser.php +++ b/tests/phpunit/tests/xmlrpc/wp/getUser.php @@ -140,4 +140,16 @@ public function test_arbitrary_fields() { sort( $keys ); $this->assertSameSets( $expected_fields, $keys ); } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $result = $this->myxmlrpcserver->wp_getUser( array( 1, 'administrator', 'administrator', $this->administrator_id, 'all' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getUsers.php b/tests/phpunit/tests/xmlrpc/wp/getUsers.php index 2c8c4ec245cb3..a0eeee4026645 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getUsers.php +++ b/tests/phpunit/tests/xmlrpc/wp/getUsers.php @@ -125,4 +125,18 @@ public function test_order_filters() { $last_email = $user['email']; } } + + /** + * Ensure a non-array `$fields` argument is rejected instead of causing a fatal error. + * + * @ticket 65983 + */ + public function test_non_array_fields_returns_error(): void { + $this->make_user_by_role( 'administrator' ); + + $result = $this->myxmlrpcserver->wp_getUsers( array( 1, 'administrator', 'administrator', array(), 'all' ) ); + + $this->assertIXRError( $result ); + $this->assertSame( 400, $result->code ); + } } From 33a4f876c7c13ffe8e0b13ac06737e24c0bf4184 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 28 Aug 2026 21:27:00 +0000 Subject: [PATCH 047/363] Feeds: Add a filterable list of XML namespaces. The `rss2_ns`, `rss2_comments_ns`, `rdf_ns`, `atom_ns`, and `atom_comments_ns` actions are echo-only: a callback prints its `xmlns` attribute straight into the feed's root element with no way to know what another callback already printed. Two plugins declaring the same namespace therefore emit a duplicate attribute, which is a well-formedness error, so every strict consumer rejects the whole feed rather than just ignoring the repetition. The new `wp_get_feed_namespaces()` and `wp_feed_namespaces()` functions build and print that list from a `wp_feed_namespaces` filter, keyed by prefix so the same prefix cannot be declared twice. Prefixes are validated as XML names, with the reserved `xml` and `xmlns` rejected, and namespace URIs are escaped on output. The namespaces previously hard-coded in the bundled feed templates now come from this list and are merged back in after the filter runs, so a callback can neither remove them nor duplicate them. The `*_ns` actions are left in place and still fire, so a plugin echoing a namespace through one of them behaves exactly as before. Their documentation now points to the filter as the safer alternative. Developed in https://github.com/WordPress/wordpress-develop/pull/12812. Props pfefferle, westonruter, abcd95. Fixes #65785. git-svn-id: https://develop.svn.wordpress.org/trunk@63394 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/feed-atom-comments.php | 6 +- src/wp-includes/feed-atom.php | 6 +- src/wp-includes/feed-rdf.php | 10 +- src/wp-includes/feed-rss2-comments.php | 9 +- src/wp-includes/feed-rss2.php | 11 +- src/wp-includes/feed.php | 120 ++++++++++ tests/phpunit/tests/feed/feedNamespaces.php | 250 ++++++++++++++++++++ tests/phpunit/tests/feed/rss2.php | 37 +++ 8 files changed, 432 insertions(+), 17 deletions(-) create mode 100644 tests/phpunit/tests/feed/feedNamespaces.php diff --git a/src/wp-includes/feed-atom-comments.php b/src/wp-includes/feed-atom-comments.php index 1de77e391794d..2563e1f11e604 100644 --- a/src/wp-includes/feed-atom-comments.php +++ b/src/wp-includes/feed-atom-comments.php @@ -14,14 +14,18 @@ @@ -26,6 +24,9 @@ /** * Fires at the end of the RSS root to add namespaces. * + * Consider using the {@see 'wp_feed_namespaces'} filter instead, which + * prevents duplicate `xmlns` attributes. + * * @since 2.8.0 */ do_action( 'rss2_comments_ns' ); diff --git a/src/wp-includes/feed-rss2.php b/src/wp-includes/feed-rss2.php index 8b30313e6d606..0de3a3d9f4671 100644 --- a/src/wp-includes/feed-rss2.php +++ b/src/wp-includes/feed-rss2.php @@ -21,16 +21,15 @@ do_action( 'rss_tag_pre', 'rss2' ); ?> Array of namespace URIs, keyed by their prefix. + * @phpstan-param non-falsy-string $type + * @phpstan-return array + */ +function wp_get_feed_namespaces( string $type ): array { + $defaults = array(); + + switch ( $type ) { + case 'rss2': + $defaults = array( + 'content' => 'http://purl.org/rss/1.0/modules/content/', + 'wfw' => 'http://wellformedweb.org/CommentAPI/', + 'dc' => 'http://purl.org/dc/elements/1.1/', + 'atom' => 'http://www.w3.org/2005/Atom', + 'sy' => 'http://purl.org/rss/1.0/modules/syndication/', + 'slash' => 'http://purl.org/rss/1.0/modules/slash/', + ); + break; + + case 'rss2-comments': + $defaults = array( + 'content' => 'http://purl.org/rss/1.0/modules/content/', + 'dc' => 'http://purl.org/dc/elements/1.1/', + 'atom' => 'http://www.w3.org/2005/Atom', + 'sy' => 'http://purl.org/rss/1.0/modules/syndication/', + ); + break; + + case 'rdf': + $defaults = array( + 'rdf' => 'http://www.w3.org/1999/02/22-rdf-syntax-ns#', + 'dc' => 'http://purl.org/dc/elements/1.1/', + 'sy' => 'http://purl.org/rss/1.0/modules/syndication/', + 'admin' => 'http://webns.net/mvcb/', + 'content' => 'http://purl.org/rss/1.0/modules/content/', + ); + break; + + case 'atom': + case 'atom-comments': + $defaults = array( + 'thr' => 'http://purl.org/syndication/thread/1.0', + ); + break; + } + + /** + * Filters the XML namespaces of a feed's root element. + * + * Namespaces are keyed by their prefix, which makes duplicate `xmlns` + * attributes impossible. + * + * @since 7.2.0 + * + * @param array $namespaces Array of namespace URIs, keyed by their prefix. + * @param string $type Type of feed. Possible values include 'rss2', + * 'rss2-comments', 'rdf', 'atom', and 'atom-comments'. + */ + $namespaces = apply_filters( 'wp_feed_namespaces', $defaults, $type ); + + if ( ! is_array( $namespaces ) ) { + $namespaces = array(); + } + + // The bundled feed templates use the default namespaces, so they cannot be removed. + $namespaces = array_merge( $namespaces, $defaults ); + + $sanitized = array(); + + foreach ( $namespaces as $prefix => $uri ) { + $prefix = (string) $prefix; + + // Prefixes must be valid XML names, and the `xml` and `xmlns` prefixes are reserved. + if ( ! preg_match( '/^[\p{L}_][\p{L}\p{M}\p{N}._\-\x{B7}]*\z/u', $prefix ) + || in_array( strtolower( $prefix ), array( 'xml', 'xmlns' ), true ) + ) { + continue; + } + + if ( ! is_string( $uri ) || empty( $uri ) ) { + continue; + } + + $sanitized[ $prefix ] = $uri; + } + + return $sanitized; +} + +/** + * Displays the XML namespaces for the root element of a feed. + * + * Plugins should add namespaces via the {@see 'wp_feed_namespaces'} filter instead + * of the older {@see "{$type}_ns"} actions, as two action callbacks printing the + * same namespace produce a duplicate attribute, which is a well-formedness + * error in XML. + * + * @since 7.2.0 + * + * @param string $type Type of feed. Possible values include 'rss2', 'rss2-comments', + * 'rdf', 'atom', and 'atom-comments'. + * @phpstan-param non-falsy-string $type + */ +function wp_feed_namespaces( string $type ): void { + foreach ( wp_get_feed_namespaces( $type ) as $prefix => $uri ) { + printf( "xmlns:%s=\"%s\"\n\t", $prefix, esc_attr( $uri ) ); + } +} + /** * Gets the UTC time of the most recently modified post from WP_Query. * diff --git a/tests/phpunit/tests/feed/feedNamespaces.php b/tests/phpunit/tests/feed/feedNamespaces.php new file mode 100644 index 0000000000000..cc5b823f6c8a4 --- /dev/null +++ b/tests/phpunit/tests/feed/feedNamespaces.php @@ -0,0 +1,250 @@ +assertSameSetsWithIndex( + array( + 'content' => 'http://purl.org/rss/1.0/modules/content/', + 'wfw' => 'http://wellformedweb.org/CommentAPI/', + 'dc' => 'http://purl.org/dc/elements/1.1/', + 'atom' => 'http://www.w3.org/2005/Atom', + 'sy' => 'http://purl.org/rss/1.0/modules/syndication/', + 'slash' => 'http://purl.org/rss/1.0/modules/slash/', + ), + $namespaces + ); + } + + /** + * @ticket 65785 + */ + public function test_should_return_default_atom_namespaces() { + $namespaces = wp_get_feed_namespaces( 'atom' ); + + $this->assertSameSetsWithIndex( + array( + 'thr' => 'http://purl.org/syndication/thread/1.0', + ), + $namespaces + ); + } + + /** + * @ticket 65785 + */ + public function test_should_return_namespace_added_via_filter() { + add_filter( + 'wp_feed_namespaces', + static function ( array $namespaces ): array { + $namespaces['source'] = 'http://source.scripting.com/'; + return $namespaces; + } + ); + + $namespaces = wp_get_feed_namespaces( 'rss2' ); + + $this->assertArrayHasKey( 'source', $namespaces ); + $this->assertSame( 'http://source.scripting.com/', $namespaces['source'] ); + } + + /** + * The feed type is passed to the filter, so namespaces can be added to + * specific feeds only. + * + * @ticket 65785 + */ + public function test_filter_should_receive_the_feed_type() { + add_filter( + 'wp_feed_namespaces', + static function ( array $namespaces, string $type ): array { + if ( 'rss2' === $type ) { + $namespaces['source'] = 'http://source.scripting.com/'; + } + return $namespaces; + }, + 10, + 2 + ); + + $this->assertArrayHasKey( 'source', wp_get_feed_namespaces( 'rss2' ) ); + $this->assertArrayNotHasKey( 'source', wp_get_feed_namespaces( 'atom' ) ); + } + + /** + * The bundled feed templates use the default namespaces in their static + * markup, so a filter must not be able to remove them. + * + * @ticket 65785 + */ + public function test_should_not_allow_removing_default_namespaces() { + add_filter( + 'wp_feed_namespaces', + static function () { + return array( 'media' => 'http://search.yahoo.com/mrss/' ); + } + ); + + $namespaces = wp_get_feed_namespaces( 'rss2' ); + + $this->assertArrayHasKey( 'media', $namespaces ); + $this->assertArrayHasKey( 'content', $namespaces ); + $this->assertArrayHasKey( 'atom', $namespaces ); + } + + /** + * A filter callback without a return value must not break the feed. + * + * @ticket 65785 + */ + public function test_should_handle_a_non_array_filter_return() { + add_filter( 'wp_feed_namespaces', '__return_null' ); + + $namespaces = wp_get_feed_namespaces( 'rss2' ); + + $this->assertArrayHasKey( 'content', $namespaces ); + } + + /** + * @ticket 65785 + */ + public function test_should_skip_invalid_prefixes() { + add_filter( + 'wp_feed_namespaces', + static function ( array $namespaces ): array { + $namespaces[''] = 'http://example.org/empty'; + $namespaces['foo bar'] = 'http://example.org/space'; + $namespaces['"onload="x"'] = 'http://example.org/attack'; + $namespaces['0numeric'] = 'http://example.org/numeric'; + $namespaces['xmlns'] = 'http://example.org/reserved'; + $namespaces['XML'] = 'http://example.org/reserved-too'; + $namespaces['empty-uri'] = ''; + return $namespaces; + } + ); + + $namespaces = wp_get_feed_namespaces( 'rss2' ); + + $this->assertArrayNotHasKey( '', $namespaces ); + $this->assertArrayNotHasKey( 'foo bar', $namespaces ); + $this->assertArrayNotHasKey( '"onload="x"', $namespaces ); + $this->assertArrayNotHasKey( '0numeric', $namespaces ); + $this->assertArrayNotHasKey( 'xmlns', $namespaces ); + $this->assertArrayNotHasKey( 'XML', $namespaces ); + $this->assertArrayNotHasKey( 'empty-uri', $namespaces ); + } + + /** + * A prefix ending in a newline is a distinct array key from the same prefix + * without one, so allowing it through would print the same attribute name + * twice: XML permits whitespace between the name and the `=`. + * + * @ticket 65785 + */ + public function test_should_skip_a_prefix_with_a_trailing_newline() { + add_filter( + 'wp_feed_namespaces', + static function ( array $namespaces ): array { + $namespaces["content\n"] = 'http://example.org/duplicate'; + return $namespaces; + } + ); + + $namespaces = wp_get_feed_namespaces( 'rss2' ); + + $this->assertArrayNotHasKey( "content\n", $namespaces ); + $this->assertSame( 'http://purl.org/rss/1.0/modules/content/', $namespaces['content'] ); + } + + /** + * Prefixes are XML names: mixed case like `creativeCommons` and + * non-ASCII letters are valid and must be preserved. + * + * @ticket 65785 + */ + public function test_should_preserve_valid_prefixes() { + add_filter( + 'wp_feed_namespaces', + static function ( array $namespaces ): array { + $namespaces['creativeCommons'] = 'http://backend.userland.com/creativeCommonsRssModule'; + $namespaces['média'] = 'http://example.org/media'; + $namespaces['tag-uri'] = 'tag:example.org,2004:ns'; + return $namespaces; + } + ); + + $namespaces = wp_get_feed_namespaces( 'rss2' ); + + $this->assertArrayHasKey( 'creativeCommons', $namespaces ); + $this->assertArrayHasKey( 'média', $namespaces ); + // Namespace URIs are identifiers, not links, so non-http schemes must survive. + $this->assertSame( 'tag:example.org,2004:ns', $namespaces['tag-uri'] ); + } + + /** + * @ticket 65785 + */ + public function test_should_return_an_empty_array_for_an_unknown_type() { + $this->assertSame( array(), wp_get_feed_namespaces( 'unknown' ) ); + } + + /** + * @ticket 65785 + */ + public function test_feed_namespaces_should_print_default_namespaces() { + $output = get_echo( 'wp_feed_namespaces', array( 'rss2' ) ); + + $this->assertStringContainsString( 'xmlns:content="http://purl.org/rss/1.0/modules/content/"', $output ); + $this->assertStringContainsString( 'xmlns:slash="http://purl.org/rss/1.0/modules/slash/"', $output ); + } + + /** + * @ticket 65785 + */ + public function test_feed_namespaces_should_escape_the_namespace_uri() { + add_filter( + 'wp_feed_namespaces', + static function ( array $namespaces ): array { + $namespaces['evil'] = 'http://example.org/"> - admin_url( 'admin-ajax.php', 'relative' ), + 'pagenow' => $current_screen->id, + 'typenow' => $current_screen->post_type, + 'adminpage' => $admin_body_class, + 'thousandsSeparator' => $wp_locale->number_format['thousands_sep'], + 'decimalPoint' => $wp_locale->number_format['decimal_point'], + 'isRtl' => (int) is_rtl(), + ), + JSON_HEX_TAG | JSON_UNESCAPED_SLASHES + ) + ) +); /** * Fires when enqueuing scripts for all admin pages. @@ -253,11 +280,13 @@ $admin_body_classes = ltrim( $admin_body_classes . ' ' . $admin_body_class ); ?> - - - - - - admin_url( 'admin-ajax.php', 'relative' ), + 'pagenow' => 'media-upload-popup', + 'adminpage' => 'media-upload-popup', + 'isRtl' => (int) is_rtl(), + ), + JSON_HEX_TAG | JSON_UNESCAPED_SLASHES + ) + ) + ); /** This action is documented in wp-admin/admin-header.php */ do_action( 'admin_enqueue_scripts', 'media-upload-popup' ); @@ -630,18 +656,26 @@ function wp_iframe( $content_func, ...$args ) { ?> class="wp-core-ui no-js "> - - - - post_id = ' . $post_id . ';'; + wp_print_inline_script_tag( + sprintf( 'var post_id = %s;', wp_json_encode( $post_id, JSON_HEX_TAG | JSON_UNESCAPED_SLASHES ) ) + ); if ( empty( $_GET['chromeless'] ) ) { echo '
    '; @@ -2247,9 +2282,6 @@ function media_upload_form( $errors = null ) { */ $plupload_init = apply_filters( 'plupload_init', $plupload_init ); - ?> -
    - + 0 ) { + preloaded.each( function () { + prepareMediaItem( { id: this.id.replace( /[^0-9]/g, '' ) }, '' ); + } ); + } + updateMediaForm(); + } ); + JS + ); + ?>
    + +
    @@ -2596,16 +2646,20 @@ function media_upload_gallery_form( $errors ) { $form_class .= ' html-uploader'; } + wp_print_inline_script_tag( + <<<'JS' + jQuery( function ( $ ) { + var preloaded = $( '.media-item.preloaded' ); + if ( preloaded.length > 0 ) { + preloaded.each( function () { + prepareMediaItem( { id: this.id.replace( /[^0-9]/g, '' ) }, '' ); + } ); + updateMediaForm(); + } + } ); + JS + ); ?> -
    @@ -2925,15 +2979,21 @@ function media_upload_library_form( $errors ) {
    - + 0 ) { + preloaded.each( function () { + prepareMediaItem( { id: this.id.replace( /[^0-9]/g, '' ) }, '' ); + } ); + updateMediaForm(); + } + } ); + JS + ); + ?>
    diff --git a/src/wp-admin/includes/template.php b/src/wp-admin/includes/template.php index 418bfd7def697..e7034e1499ecd 100644 --- a/src/wp-admin/includes/template.php +++ b/src/wp-admin/includes/template.php @@ -2140,19 +2140,50 @@ function iframe_header( $title = '', $deprecated = false ) { <?php bloginfo( 'name' ); ?> › <?php echo $title; ?> — <?php _e( 'WordPress' ); ?> - - admin_url( 'admin-ajax.php', 'relative' ), + 'pagenow' => $current_screen->id ?? '', + 'typenow' => $current_screen->post_type ?? '', + 'adminpage' => $admin_body_class, + 'thousandsSeparator' => $wp_locale->number_format['thousands_sep'], + 'decimalPoint' => $wp_locale->number_format['decimal_point'], + 'isRtl' => (int) is_rtl(), + ), + JSON_HEX_TAG | JSON_UNESCAPED_SLASHES + ) + ) + ); + /** This action is documented in wp-admin/admin-header.php */ do_action( 'admin_enqueue_scripts', $hook_suffix ); @@ -2191,14 +2222,12 @@ function tb_close(){var win=window.dialogArguments||opener||parent||top;win.tb_r $admin_body_classes = ltrim( $admin_body_classes . ' ' . $admin_body_class ); ?> class="wp-admin wp-core-ui no-js iframe "> -
    - + Date: Fri, 4 Sep 2026 21:45:19 +0000 Subject: [PATCH 110/363] Administration: Fix doubled border on mobile for paused plugins. Update CSS for paused plugins in recovery mode to account for the changes in list table structure in r62958, which did not account for this case on small viewports. Props r1k0, joedolson. Fixes #65985. git-svn-id: https://develop.svn.wordpress.org/trunk@63482 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/list-tables.css | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/wp-admin/css/list-tables.css b/src/wp-admin/css/list-tables.css index 2b8103fe7a886..f6abda748bf1a 100644 --- a/src/wp-admin/css/list-tables.css +++ b/src/wp-admin/css/list-tables.css @@ -1980,7 +1980,8 @@ div.action-links, .plugins .active th.check-column, .plugins .active td.check-column, - .plugin-update-tr.active td { + .plugin-update-tr.active td, + .plugins tr.paused td.check-column { border-left: 4px solid transparent; } @@ -1994,6 +1995,10 @@ div.action-links, border-left: 4px solid var(--wp-admin-theme-color); } + .plugins tr.active.paused { + border-left: 4px solid #b32d2e; + } + .wp-list-table .column-primary .toggle-row { display: block; } From 2fbc03a4948160e319c0870a24b035a5996c957a Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Fri, 4 Sep 2026 23:35:50 +0000 Subject: [PATCH 111/363] Code Quality: Remove redundant `parent_post_type` property from template autosaves controller. The `WP_REST_Template_Autosaves_Controller` class redeclared a private `$parent_post_type` property and assigned it in its constructor. Both were dead code. The parent class `WP_REST_Autosaves_Controller` already declares and sets this property, and because it is declared `private`, the child class's copy could never be accessed by the parent's methods, nor was it ever read anywhere within the child class itself. The result was confusing property shadowing without any functional purpose. This change removes the duplicate property declaration and the corresponding assignment in the constructor. Since the property was never read in the child class and was effectively a separate, unused storage slot, there is no change in runtime behavior. Developed in https://github.com/WordPress/wordpress-develop/pull/12295. Follow-up to r56819. Props Soean. See #65818. git-svn-id: https://develop.svn.wordpress.org/trunk@63485 602fd350-edb4-49c9-b593-d223f7449a82 --- .../class-wp-rest-template-autosaves-controller.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php index dbdca575089fc..30e7dcdcd38c0 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php @@ -15,13 +15,6 @@ * @see WP_REST_Autosaves_Controller */ class WP_REST_Template_Autosaves_Controller extends WP_REST_Autosaves_Controller { - /** - * Parent post type. - * - * @since 6.4.0 - * @var string - */ - private $parent_post_type; /** * Parent post controller. @@ -56,7 +49,6 @@ class WP_REST_Template_Autosaves_Controller extends WP_REST_Autosaves_Controller */ public function __construct( $parent_post_type ) { parent::__construct( $parent_post_type ); - $this->parent_post_type = $parent_post_type; $post_type_object = get_post_type_object( $parent_post_type ); $parent_controller = $post_type_object->get_rest_controller(); From fc5042df91bbbc28b5b36ee9fa907f4c071e748e Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Fri, 4 Sep 2026 23:50:53 +0000 Subject: [PATCH 112/363] Build/Test Tools: Regenerate PHPStan baselines for `property.onlyWritten`. The sole `property.onlyWritten` error identified by PHPStan was [https://github.com/WordPress/wordpress-develop/pull/12295 fixed] without the baselines being regenerated. Follow-up to r63485. See #65817, #65818. git-svn-id: https://develop.svn.wordpress.org/trunk@63486 602fd350-edb4-49c9-b593-d223f7449a82 --- phpstan.neon.dist | 1 - .../baselines/property.onlyWritten.neon | 25 ------------------- 2 files changed, 26 deletions(-) delete mode 100644 tests/phpstan/baselines/property.onlyWritten.neon diff --git a/phpstan.neon.dist b/phpstan.neon.dist index 1ddfb275beeda..cc4579365122b 100644 --- a/phpstan.neon.dist +++ b/phpstan.neon.dist @@ -70,7 +70,6 @@ includes: - tests/phpstan/baselines/property.defaultValue.neon - tests/phpstan/baselines/property.nonObject.neon - tests/phpstan/baselines/property.notFound.neon - - tests/phpstan/baselines/property.onlyWritten.neon - tests/phpstan/baselines/property.phpDocType.neon - tests/phpstan/baselines/property.private.neon - tests/phpstan/baselines/property.protected.neon diff --git a/tests/phpstan/baselines/property.onlyWritten.neon b/tests/phpstan/baselines/property.onlyWritten.neon deleted file mode 100644 index f4b740e1bdf02..0000000000000 --- a/tests/phpstan/baselines/property.onlyWritten.neon +++ /dev/null @@ -1,25 +0,0 @@ -# PHPStan baseline for the `property.onlyWritten` errors in WordPress core. -# -# https://phpstan.org/error-identifiers/property.onlyWritten -# -# Each entry is scoped to a single file and carries an exact occurrence count, -# so that a new instance is reported as a new error rather than being absorbed -# silently. Fixing an occurrence therefore means decrementing or removing its -# entry here as part of the same change. -# -# The goal is to empty this file and delete it, along with the `includes` entry -# for it in phpstan.neon.dist. -# -# Generated by `composer phpstan:baselines`. Do not edit by hand; regenerate with -# -# composer phpstan:baselines -- --identifier=property.onlyWritten -# -# which reruns the analysis with this file suppressed so the errors surface again. - -parameters: - ignoreErrors: - - - message: '#^Property WP_REST_Template_Autosaves_Controller\:\:\$parent_post_type is never read, only written\.$#' - identifier: property.onlyWritten - count: 1 - path: ../../../src/wp-includes/rest-api/endpoints/class-wp-rest-template-autosaves-controller.php From 85be7fcba369ad6a2eb9441bc895aaad6de6de4a Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Sat, 5 Sep 2026 00:36:18 +0000 Subject: [PATCH 113/363] Code Quality: Refine the dual-mode template tag annotations. * Restore `void` to the `@return` unions of `wpdb::print_error()` and `wpdb::check_database_version()`, which r62177 replaced with `null`. * Add the `null` that fifteen tags describe in prose but omit from a `@return` listing only `string|void`. * Match every falsy spelling of a display flag, and every argument shape reaching a bail, so those calls resolve to `void`; a query string still cannot be read, tracked in #66049. * Narrow the deprecated param for `trackback_url()` so that static analysis catches the obsolete usage. Developed in https://github.com/WordPress/wordpress-develop/pull/13371. Follow-up to r32568, r61766, r61768, r62177, r62178, r63440, r63441. Props marian1, westonruter. See #64703, #64704, #65817, #66049. git-svn-id: https://develop.svn.wordpress.org/trunk@63487 602fd350-edb4-49c9-b593-d223f7449a82 --- .../themes/twentytwenty/inc/template-tags.php | 4 +-- src/wp-includes/author-template.php | 2 +- src/wp-includes/bookmark-template.php | 2 +- src/wp-includes/category-template.php | 8 ++--- src/wp-includes/class-wpdb.php | 8 ++--- src/wp-includes/comment-template.php | 10 +++--- src/wp-includes/functions.php | 4 +-- src/wp-includes/general-template.php | 35 ++++++++++--------- src/wp-includes/l10n.php | 11 ++++-- src/wp-includes/link-template.php | 14 ++++---- src/wp-includes/post-template.php | 14 ++++---- src/wp-includes/user.php | 2 +- 12 files changed, 60 insertions(+), 54 deletions(-) diff --git a/src/wp-content/themes/twentytwenty/inc/template-tags.php b/src/wp-content/themes/twentytwenty/inc/template-tags.php index 28eaad2b4e42d..7987e4c57af3f 100644 --- a/src/wp-content/themes/twentytwenty/inc/template-tags.php +++ b/src/wp-content/themes/twentytwenty/inc/template-tags.php @@ -107,8 +107,8 @@ function twentytwenty_site_logo( $args = array(), $display = true ) { * @since Twenty Twenty 1.0 * * @param bool $display Display or return the HTML. - * @return string|void The HTML when `$display` is false, null when the site has no - * description. Nothing otherwise. + * @return string|null|void The HTML when `$display` is false, null when the site has no + * description. Nothing otherwise. * @phpstan-return ( $display is true ? void : string|null ) */ function twentytwenty_site_description( $display = true ) { diff --git a/src/wp-includes/author-template.php b/src/wp-includes/author-template.php index 77b1adaf96ac0..b27bbf62379d4 100644 --- a/src/wp-includes/author-template.php +++ b/src/wp-includes/author-template.php @@ -453,7 +453,7 @@ function get_author_posts_url( $author_id, $author_nicename = '' ) { * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_list_authors( $args = '' ) { diff --git a/src/wp-includes/bookmark-template.php b/src/wp-includes/bookmark-template.php index b3f94decef2d2..37d55bf4561f6 100644 --- a/src/wp-includes/bookmark-template.php +++ b/src/wp-includes/bookmark-template.php @@ -210,7 +210,7 @@ function _walk_bookmarks( $bookmarks, $args = '' ) { * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_list_bookmarks( $args = '' ) { diff --git a/src/wp-includes/category-template.php b/src/wp-includes/category-template.php index 633c8faf81c51..f268f93cbc461 100644 --- a/src/wp-includes/category-template.php +++ b/src/wp-includes/category-template.php @@ -710,15 +710,15 @@ function wp_list_categories( $args = '' ) { * associated with the taxonomy. * @type bool $echo Whether or not to echo the return value. Default true. * } - * @return string|string[]|void Tag cloud as a string, or as an array when the 'format' argument - * is 'array'. Null on failure. Nothing when 'echo' is true and - * 'format' is not 'array'. + * @return string|string[]|null|void Tag cloud as a string, or as an array when the 'format' + * argument is 'array'. Null on failure. Nothing when 'echo' is + * true and 'format' is not 'array'. * @phpstan-return ( * $args is array{ format: 'array', ... } * ? string[]|null * : ( $args is array{ echo: false|0|''|'0', ... } * ? string|null - * : ( $args is ''|array ? void : string|string[]|null ) ) + * : ( $args is ''|'0'|array ? void : string|string[]|null ) ) * ) */ function wp_tag_cloud( $args = '' ) { diff --git a/src/wp-includes/class-wpdb.php b/src/wp-includes/class-wpdb.php index a676d395ee95c..5cf9508f8fbdf 100644 --- a/src/wp-includes/class-wpdb.php +++ b/src/wp-includes/class-wpdb.php @@ -1794,7 +1794,7 @@ public function esc_like( $text ) { * @global array $EZSQL_ERROR Stores error information of query and error string. * * @param string $str The error to display. - * @return null|false Null if the showing of errors is enabled, false if disabled. + * @return void|false Void if the showing of errors is enabled, false if disabled. */ public function print_error( $str = '' ) { global $EZSQL_ERROR; @@ -1855,8 +1855,6 @@ public function print_error( $str = '' ) { $query ); } - - return null; } /** @@ -4068,7 +4066,7 @@ public function close() { * @since 2.5.0 * * @global string $required_mysql_version The minimum required MySQL version string. - * @return WP_Error|null + * @return void|WP_Error Void if the server meets the minimum version, WP_Error if not. */ public function check_database_version() { global $required_mysql_version; @@ -4079,8 +4077,6 @@ public function check_database_version() { /* translators: 1: WordPress version number, 2: Minimum required MySQL version number. */ return new WP_Error( 'database_version', sprintf( __( 'Error: WordPress %1$s requires MySQL %2$s or higher' ), $wp_version, $required_mysql_version ) ); } - - return null; } /** diff --git a/src/wp-includes/comment-template.php b/src/wp-includes/comment-template.php index 68091c5f4c65e..f96cf18f78f13 100644 --- a/src/wp-includes/comment-template.php +++ b/src/wp-includes/comment-template.php @@ -1244,10 +1244,12 @@ function get_trackback_url() { * * @see get_trackback_url() * - * @param bool $deprecated_echo Deprecated. Use {@see get_trackback_url()}. Echo the URL or + * @param true $deprecated_echo Deprecated. Use {@see get_trackback_url()}. Echo the URL or * return it. Default true. * @return string|void The trackback URL when `$deprecated_echo` is false, nothing otherwise. * @phpstan-return ( $deprecated_echo is true ? void : string ) + * + * @phpstan-ignore conditionalType.alwaysTrue (Typed `true` to flag the deprecated argument.) */ function trackback_url( $deprecated_echo = true ) { if ( true !== $deprecated_echo ) { @@ -2233,12 +2235,12 @@ function _get_comment_reply_id( $post = null ) { * @type bool $echo Whether to echo the output or return it. Default true. * } * @param WP_Comment[] $comments Optional. Array of WP_Comment objects. Default null. - * @return string|void HTML list of comments when 'echo' is false, null when there are no - * comments to list. Nothing otherwise. + * @return string|null|void HTML list of comments when 'echo' is false, null when there are + * no comments to list. Nothing otherwise. * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string|null - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_list_comments( $args = array(), $comments = null ) { diff --git a/src/wp-includes/functions.php b/src/wp-includes/functions.php index dd42e3ad916f6..31de822d2aacd 100644 --- a/src/wp-includes/functions.php +++ b/src/wp-includes/functions.php @@ -8745,8 +8745,8 @@ function wp_get_default_update_php_url() { * @param string $before Markup to output before the annotation. Default `

    `. * @param string $after Markup to output after the annotation. Default `

    `. * @param bool $display Whether to echo or return the markup. Default `true` for echo. - * @return string|void Update PHP page annotation when `$display` is false, null when no - * annotation is available. Nothing otherwise. + * @return string|null|void Update PHP page annotation when `$display` is false, null when + * no annotation is available. Nothing otherwise. * @phpstan-return ( $display is true ? void : string|null ) */ function wp_update_php_annotation( $before = '

    ', $after = '

    ', $display = true ) { diff --git a/src/wp-includes/general-template.php b/src/wp-includes/general-template.php index e5c65279e52b5..7ba1d623f4631 100644 --- a/src/wp-includes/general-template.php +++ b/src/wp-includes/general-template.php @@ -1705,8 +1705,8 @@ function wp_title( $sep = '»', $display = true, $seplocation = '' ) { * * @param string $prefix Optional. What to display before the title. * @param bool $display Optional. Whether to display or retrieve title. Default true. - * @return string|void Title when retrieving, null on failure. - * Nothing when displaying. + * @return string|null|void Title when retrieving, null on failure. + * Nothing when displaying. * @phpstan-return ( $display is true ? void : string|null ) */ function single_post_title( $prefix = '', $display = true ) { @@ -1743,8 +1743,8 @@ function single_post_title( $prefix = '', $display = true ) { * * @param string $prefix Optional. What to display before the title. * @param bool $display Optional. Whether to display or retrieve title. Default true. - * @return string|void Title when retrieving, null on failure. - * Nothing when displaying. + * @return string|null|void Title when retrieving, null on failure. + * Nothing when displaying. * @phpstan-return ( $display is true ? void : string|null ) */ function post_type_archive_title( $prefix = '', $display = true ) { @@ -1787,8 +1787,8 @@ function post_type_archive_title( $prefix = '', $display = true ) { * * @param string $prefix Optional. What to display before the title. * @param bool $display Optional. Whether to display or retrieve title. Default true. - * @return string|void Title when retrieving, null on failure. - * Nothing when displaying. + * @return string|null|void Title when retrieving, null on failure. + * Nothing when displaying. * @phpstan-return ( $display is true ? void : string|null ) */ function single_cat_title( $prefix = '', $display = true ) { @@ -1810,8 +1810,8 @@ function single_cat_title( $prefix = '', $display = true ) { * * @param string $prefix Optional. What to display before the title. * @param bool $display Optional. Whether to display or retrieve title. Default true. - * @return string|void Title when retrieving, null on failure. - * Nothing when displaying. + * @return string|null|void Title when retrieving, null on failure. + * Nothing when displaying. * @phpstan-return ( $display is true ? void : string|null ) */ function single_tag_title( $prefix = '', $display = true ) { @@ -1833,8 +1833,8 @@ function single_tag_title( $prefix = '', $display = true ) { * * @param string $prefix Optional. What to display before the title. * @param bool $display Optional. Whether to display or retrieve title. Default true. - * @return string|void Title when retrieving, null on failure. - * Nothing when displaying. + * @return string|null|void Title when retrieving, null on failure. + * Nothing when displaying. * @phpstan-return ( $display is true ? void : string|null ) */ function single_term_title( $prefix = '', $display = true ) { @@ -2235,12 +2235,12 @@ function get_archives_link( $url, $text, $format = 'html', $before = '', $after * @type string $day Day. Default current day. * @type string $w Week. Default current week. * } - * @return string|void Archive links when 'echo' is false, null when the post type is - * not viewable. Nothing otherwise. + * @return string|null|void Archive links when 'echo' is false, null when the post type is + * not viewable. Nothing otherwise. * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string|null - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_get_archives( $args = '' ) { @@ -2511,8 +2511,8 @@ function calendar_week_mod( $num ) { * @type bool $display Whether to display the calendar output. Default true. * @type string $post_type Optional. Post type. Default 'post'. * } - * @return string|void Calendar HTML when `$display` is false, null when the site has - * no posts. Nothing otherwise. + * @return string|null|void Calendar HTML when `$display` is false, null when the site has + * no posts. Nothing otherwise. * @phpstan-return ( $args is array{ display: false|0|''|'0', ... } ? string|null : void ) */ function get_calendar( $args = array() ) { @@ -2927,7 +2927,8 @@ function the_date_xml() { * @param string $before Optional. Output before the date. Default empty. * @param string $after Optional. Output after the date. Default empty. * @param bool $display Optional. Whether to echo the date or return it. Default true. - * @return string|void String if retrieving. + * @return string|void The date when `$display` is false, or an empty string when the post's + * date matches the previously output one. Nothing otherwise. * @phpstan-return ( $display is true ? void : string ) */ function the_date( $format = '', $before = '', $after = '', $display = true ) { @@ -3003,7 +3004,7 @@ function get_the_date( $format = '', $post = null ) { * @param string $before Optional. Output before the date. Default empty. * @param string $after Optional. Output after the date. Default empty. * @param bool $display Optional. Whether to echo the date or return it. Default true. - * @return string|void String if retrieving. + * @return string|void The modified date when `$display` is false, nothing otherwise. * @phpstan-return ( $display is true ? void : string ) */ function the_modified_date( $format = '', $before = '', $after = '', $display = true ) { diff --git a/src/wp-includes/l10n.php b/src/wp-includes/l10n.php index a0be55146f7e6..7b9d2652d41dd 100644 --- a/src/wp-includes/l10n.php +++ b/src/wp-includes/l10n.php @@ -1736,8 +1736,15 @@ function wp_get_l10n_php_file_data( $php_file ) { * instead of an empty value. Default false. * } * @return string|void HTML dropdown list of languages. Always returned, whether or not - * 'echo' is true; nothing is returned when the required `id` or `name` - * argument is missing. + * 'echo' is true; nothing is returned when the 'id' or 'name' + * argument is empty. + * @phpstan-return ( + * $args is array{ id: ''|'0', ... } + * ? void + * : ( $args is array{ name: ''|'0', ... } + * ? void + * : ( $args is array ? string : string|void ) ) + * ) */ function wp_dropdown_languages( $args = array() ) { diff --git a/src/wp-includes/link-template.php b/src/wp-includes/link-template.php index cabb7cedfab21..f4accadb0bf3a 100644 --- a/src/wp-includes/link-template.php +++ b/src/wp-includes/link-template.php @@ -1131,8 +1131,8 @@ function get_edit_term_link( $term, $taxonomy = '', $object_type = '' ) { * @param string $after Optional. Display after edit link. Default empty. * @param int|WP_Term|null $term Optional. Term ID or object. If null, the queried object will be inspected. Default null. * @param bool $display Optional. Whether or not to echo the return. Default true. - * @return string|void HTML content when retrieving, null on failure or without the - * capability to edit the term. Nothing when displaying. + * @return string|null|void HTML content when retrieving, null on failure or without the + * capability to edit the term. Nothing when displaying. * @phpstan-return ( $display is true ? void : string|null ) */ function edit_term_link( $link = '', $before = '', $after = '', $term = null, $display = true ) { @@ -3268,16 +3268,16 @@ function previous_comments_link( $label = '' ) { * @global WP_Rewrite $wp_rewrite WordPress rewrite component. * * @param string|array $args Optional args. See paginate_links(). Default empty array. - * @return string|string[]|void Markup for comment page links, or an array of them when the 'type' - * argument is 'array'. Null if the query is not for an existing single - * post of any post type. Nothing when 'echo' is true and 'type' is not - * 'array'. + * @return string|string[]|null|void Markup for comment page links, or an array of them when + * the 'type' argument is 'array'. Null if the query is not for + * an existing single post of any post type. Nothing when 'echo' + * is true and 'type' is not 'array'. * @phpstan-return ( * $args is array{ type: 'array', ... } * ? string[]|null * : ( $args is array{ echo: false|0|''|'0', ... } * ? string|null - * : ( $args is ''|array ? void : string|string[]|null ) ) + * : ( $args is ''|'0'|array ? void : string|string[]|null ) ) * ) */ function paginate_comments_links( $args = array() ) { diff --git a/src/wp-includes/post-template.php b/src/wp-includes/post-template.php index 0c21f6815a28b..beb53c92b0c46 100644 --- a/src/wp-includes/post-template.php +++ b/src/wp-includes/post-template.php @@ -37,8 +37,8 @@ function get_the_ID() { // phpcs:ignore WordPress.NamingConventions.ValidFunctio * @param string $before Optional. Markup to prepend to the title. Default empty. * @param string $after Optional. Markup to append to the title. Default empty. * @param bool $display Optional. Whether to echo or return the title. Default true for echo. - * @return string|void Current post title when `$display` is false, null when the title - * is empty. Nothing otherwise. + * @return string|null|void Current post title when `$display` is false, null when the + * title is empty. Nothing otherwise. * @phpstan-return ( $display is true ? void : string|null ) */ function the_title( $before = '', $after = '', $display = true ) { @@ -77,12 +77,12 @@ function the_title( $before = '', $after = '', $display = true ) { * @type bool $echo Whether to echo or return the title. Default true for echo. * @type WP_Post $post Current post object to retrieve the title for. * } - * @return string|void The title attribute when 'echo' is false, null when the title is - * empty. Nothing otherwise. + * @return string|null|void The title attribute when 'echo' is false, null when the title + * is empty. Nothing otherwise. * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string|null - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function the_title_attribute( $args = '' ) { @@ -1309,7 +1309,7 @@ function wp_dropdown_pages( $args = '' ) { * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_list_pages( $args = '' ) { @@ -1437,7 +1437,7 @@ function wp_list_pages( $args = '' ) { * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_page_menu( $args = array() ) { diff --git a/src/wp-includes/user.php b/src/wp-includes/user.php index 0a0aed8348073..3e8d76b1e4a3b 100644 --- a/src/wp-includes/user.php +++ b/src/wp-includes/user.php @@ -911,7 +911,7 @@ function get_users( $args = array() ) { * @phpstan-return ( * $args is array{ echo: false|0|''|'0', ... } * ? string - * : ( $args is ''|array ? void : string|null ) + * : ( $args is ''|'0'|array ? void : string|null ) * ) */ function wp_list_users( $args = array() ) { From 823a803768217fe2ac382b5df80cf95c43177a23 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Sat, 5 Sep 2026 01:39:01 +0000 Subject: [PATCH 114/363] Taxonomy: Fix `wp_get_object_terms()` when requesting a count. Requesting a count passed the numeric string `get_terms()` returns straight to `array_merge()`, which warns and yields null on PHP 7.4 and throws a `TypeError` on PHP 8.0 and later. The count is now cast before it is merged, and summed once every taxonomy has been queried, so the function returns the numeric string its documentation has described since r49947. An empty object or taxonomy list returns `'0'` for the same reason, rather than the empty array that contradicted the documented type. A taxonomy registered with an `args` array is queried by a separate recursive call, and those results were merged with `array_merge()` unconditionally. For the `id=>` values of `fields` the term IDs are integer array keys, which `array_merge()` renumbers, so such a taxonomy came back keyed from zero. The recursive branch now uses the union operator for those, as the merge for the remaining taxonomies has done since r41809. The functions `get_terms()`, `wp_get_object_terms()`, `wp_count_terms()`, `wp_get_post_categories()`, `wp_get_post_tags()` and `wp_get_post_terms()` each gain a conditional return type that resolves the result from the `fields` value, falling back to what that function's own default answers with, as was done for `WP_Term_Query::query()` in r63358. Developed in https://github.com/WordPress/wordpress-develop/pull/7278. Follow-up to r38667, r40513, r41809, r49947, r63358. Props marian1, westonruter, swissspidy. See #65817, #66049. Fixes #61936. git-svn-id: https://develop.svn.wordpress.org/trunk@63488 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/post.php | 66 ++++- src/wp-includes/taxonomy.php | 98 ++++++-- .../phpstan/baselines/property.nonObject.neon | 10 - .../phpstan/baselines/property.notFound.neon | 10 + tests/phpunit/tests/term.php | 33 +++ tests/phpunit/tests/term/wpGetObjectTerms.php | 229 +++++++++++++++++- 6 files changed, 409 insertions(+), 37 deletions(-) diff --git a/src/wp-includes/post.php b/src/wp-includes/post.php index 26266c04140a2..dca47155a1227 100644 --- a/src/wp-includes/post.php +++ b/src/wp-includes/post.php @@ -4452,10 +4452,28 @@ function wp_untrash_post_comments( $post = null ) { * global $post. Default 0. * @param array $args Optional. Category query parameters. Default empty array. * See WP_Term_Query::__construct() for supported arguments. - * @return array|WP_Error List of categories. If the `$fields` argument passed via `$args` is 'all' or - * 'all_with_object_id', an array of WP_Term objects will be returned. If `$fields` - * is 'ids', an array of category IDs. If `$fields` is 'names', an array of category names. - * WP_Error object if 'category' taxonomy doesn't exist. + * @return int[]|WP_Term[]|string[]|string|WP_Error List of categories. An array of category IDs by + * default, and if the `$fields` argument passed via + * `$args` is 'ids'. If `$fields` is 'all' or + * 'all_with_object_id', an array of WP_Term objects. + * If `$fields` is 'names', an array of category names. + * If `$fields` is 'count', a count thereof as a numeric + * string. WP_Error object if 'category' taxonomy + * doesn't exist. + * + * @phpstan-return ( + * $args is array{ fields: 'count', ... } + * ? numeric-string|WP_Error + * : ( $args is array{ fields: 'id=>parent', ... } + * ? array|WP_Error + * : ( $args is array{ fields: 'names'|'slugs', ... } + * ? string[]|WP_Error + * : ( $args is array{ fields: 'id=>name'|'id=>slug', ... } + * ? array|WP_Error + * : ( $args is array{ fields: 'all'|'all_with_object_id', ... } + * ? WP_Term[]|WP_Error + * : int[]|WP_Error ) ) ) ) + * ) */ function wp_get_post_categories( $post_id = 0, $args = array() ) { $post_id = (int) $post_id; @@ -4480,8 +4498,24 @@ function wp_get_post_categories( $post_id = 0, $args = array() ) { * global $post. Default 0. * @param array $args Optional. Tag query parameters. Default empty array. * See WP_Term_Query::__construct() for supported arguments. - * @return array|WP_Error Array of WP_Term objects on success or empty array if no tags were found. - * WP_Error object if 'post_tag' taxonomy doesn't exist. + * @return WP_Term[]|int[]|string[]|string|WP_Error Array of WP_Term objects on success or empty array if no + * tags were found. A count thereof as a numeric string if + * the `$fields` argument passed via `$args` is 'count'. + * WP_Error object if 'post_tag' taxonomy doesn't exist. + * + * @phpstan-return ( + * $args is array{ fields: 'count', ... } + * ? numeric-string|WP_Error + * : ( $args is array{ fields: 'ids'|'tt_ids', ... } + * ? int[]|WP_Error + * : ( $args is array{ fields: 'id=>parent', ... } + * ? array|WP_Error + * : ( $args is array{ fields: 'names'|'slugs', ... } + * ? string[]|WP_Error + * : ( $args is array{ fields: 'id=>name'|'id=>slug', ... } + * ? array|WP_Error + * : WP_Term[]|WP_Error ) ) ) ) + * ) */ function wp_get_post_tags( $post_id = 0, $args = array() ) { return wp_get_post_terms( $post_id, 'post_tag', $args ); @@ -4501,8 +4535,24 @@ function wp_get_post_tags( $post_id = 0, $args = array() ) { * * @type string $fields Term fields to retrieve. Default 'all'. * } - * @return array|WP_Error Array of WP_Term objects on success or empty array if no terms were found. - * WP_Error object if `$taxonomy` doesn't exist. + * @return WP_Term[]|int[]|string[]|string|WP_Error Array of WP_Term objects on success or empty array if no + * terms were found. A count thereof as a numeric string if + * the `$fields` argument passed via `$args` is 'count'. + * WP_Error object if `$taxonomy` doesn't exist. + * + * @phpstan-return ( + * $args is array{ fields: 'count', ... } + * ? numeric-string|WP_Error + * : ( $args is array{ fields: 'ids'|'tt_ids', ... } + * ? int[]|WP_Error + * : ( $args is array{ fields: 'id=>parent', ... } + * ? array|WP_Error + * : ( $args is array{ fields: 'names'|'slugs', ... } + * ? string[]|WP_Error + * : ( $args is array{ fields: 'id=>name'|'id=>slug', ... } + * ? array|WP_Error + * : WP_Term[]|WP_Error ) ) ) ) + * ) */ function wp_get_post_terms( $post_id = 0, $taxonomy = 'post_tag', $args = array() ) { $post_id = (int) $post_id; diff --git a/src/wp-includes/taxonomy.php b/src/wp-includes/taxonomy.php index 597fdf4118d68..2e264ad4e433f 100644 --- a/src/wp-includes/taxonomy.php +++ b/src/wp-includes/taxonomy.php @@ -1309,15 +1309,35 @@ function get_term_to_edit( $id, $taxonomy ) { * Introduced 'meta_key' and 'meta_value' parameters. Introduced the ability to order results by metadata. * @since 4.8.0 Introduced 'suppress_filter' parameter. * - * @param array|string $args Optional. Array or string of arguments. See WP_Term_Query::__construct() + * @param array|string $args Optional. Array or string of arguments. See {@see WP_Term_Query::__construct()} * for information on accepted arguments. Default empty array. * @param array|string $deprecated Optional. Argument array, when using the legacy function parameter format. * If present, this parameter will be interpreted as `$args`, and the first * function parameter will be parsed as a taxonomy or array of taxonomies. * Default empty. - * @return WP_Term[]|int[]|string[]|string|WP_Error Array of terms, a count thereof as a numeric string, - * or WP_Error if any of the taxonomies do not exist. - * See the function description for more information. + * @return WP_Term[]|int[]|string[]|int|string|WP_Error Array of terms, a count thereof as a numeric string, + * the integer 0 when the queried parent term is not in + * the taxonomy hierarchy, or WP_Error if any of the + * taxonomies do not exist. See the function description + * for more information. + * + * @phpstan-return ( + * $args is array{ fields: 'count', ... } + * ? 0|numeric-string|WP_Error + * : ( $args is array{ fields: 'ids'|'tt_ids', ... } + * ? int[]|WP_Error + * : ( $args is array{ fields: 'id=>parent', ... } + * ? array|WP_Error + * : ( $args is array{ fields: 'names'|'slugs', ... } + * ? string[]|WP_Error + * : ( $args is array{ fields: 'id=>name'|'id=>slug', ... } + * ? array|WP_Error + * : ( $deprecated is '' + * ? ( $args is array + * ? WP_Term[]|WP_Error + * : WP_Term[]|int[]|string[]|int|string|WP_Error ) + * : WP_Term[]|int[]|string[]|int|string|WP_Error ) ) ) ) ) + * ) */ function get_terms( $args = array(), $deprecated = '' ) { $term_query = new WP_Term_Query(); @@ -1957,14 +1977,16 @@ function sanitize_term_field( $field, $value, $term_id, $taxonomy, $context ) { * @since 2.3.0 * @since 5.6.0 Changed the function signature so that the `$args` array can be provided as the first parameter. * - * @param array|string $args Optional. Array or string of arguments. See WP_Term_Query::__construct() + * @param array|string $args Optional. Array or string of arguments. See {@see WP_Term_Query::__construct()} * for information on accepted arguments. Default empty array. * @param array|string $deprecated Optional. Argument array, when using the legacy function parameter format. * If present, this parameter will be interpreted as `$args`, and the first * function parameter will be parsed as a taxonomy or array of taxonomies. * Default empty. - * @return string|WP_Error Numeric string containing the number of terms in that - * taxonomy or WP_Error if the taxonomy does not exist. + * @return string|int|WP_Error Numeric string containing the number of terms in that taxonomy, + * the integer 0 when the queried parent term is not in the taxonomy + * hierarchy, or WP_Error if the taxonomy does not exist. + * @phpstan-return numeric-string|0|WP_Error */ function wp_count_terms( $args = array(), $deprecated = '' ) { $use_legacy_args = false; @@ -1992,7 +2014,10 @@ function wp_count_terms( $args = array(), $deprecated = '' ) { unset( $args['ignore_empty'] ); } - $args['fields'] = 'count'; + $args = array_merge( + $args, + array( 'fields' => 'count' ) + ); return get_terms( $args ); } @@ -2289,16 +2314,40 @@ function wp_delete_category( $cat_id ) { * @since 4.7.0 Refactored to use WP_Term_Query, and to support any WP_Term_Query arguments. * @since 6.3.0 Passing `update_term_meta_cache` argument value false by default resulting in get_terms() to not * prime the term meta cache. + * @since 7.2.0 A count is returned as a numeric string when `$fields` is 'count'. Previously requesting + * a count resulted in an error. * * @param int|int[] $object_ids The ID(s) of the object(s) to retrieve. * @param string|string[] $taxonomies The taxonomy names to retrieve terms from. - * @param array|string $args See WP_Term_Query::__construct() for supported arguments. + * @param array|string $args See {@see WP_Term_Query::__construct()} for supported arguments. * @return WP_Term[]|int[]|string[]|string|WP_Error Array of terms, a count thereof as a numeric string, * or WP_Error if any of the taxonomies do not exist. - * See WP_Term_Query::get_terms() for more information. + * See {@see WP_Term_Query::get_terms()} for more information. + * + * @phpstan-return ( + * $args is array{ fields: 'count', ... } + * ? numeric-string|WP_Error + * : ( $args is array{ fields: 'ids'|'tt_ids', ... } + * ? int[]|WP_Error + * : ( $args is array{ fields: 'id=>parent', ... } + * ? array|WP_Error + * : ( $args is array{ fields: 'names'|'slugs', ... } + * ? string[]|WP_Error + * : ( $args is array{ fields: 'id=>name'|'id=>slug', ... } + * ? array|WP_Error + * : ( $args is array + * ? WP_Term[]|WP_Error + * : WP_Term[]|int[]|string[]|string|WP_Error ) ) ) ) ) + * ) */ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { + $args = wp_parse_args( $args ); + if ( empty( $object_ids ) || empty( $taxonomies ) ) { + if ( isset( $args['fields'] ) && 'count' === $args['fields'] ) { + return '0'; + } + return array(); } @@ -2338,6 +2387,13 @@ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { /* * When one or more queried taxonomies is registered with an 'args' array, * those params override the `$args` passed to this function. + * + * That array is for query modifiers such as 'orderby'. Overriding 'fields' + * there does not work, because callers depend on the shape they asked for: + * get_the_taxonomies() reads `$term->name` off the result, and + * wp_set_object_terms() needs the 'tt_ids' it requested. A taxonomy that + * overrides it also returns a different shape than the taxonomies queried + * below, leaving the two merged into one another here. */ $terms = array(); if ( count( $taxonomies ) > 1 ) { @@ -2345,7 +2401,16 @@ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { $t = get_taxonomy( $taxonomy ); if ( isset( $t->args ) && is_array( $t->args ) && array_merge( $args, $t->args ) != $args ) { unset( $taxonomies[ $index ] ); - $terms = array_merge( $terms, wp_get_object_terms( $object_ids, $taxonomy, array_merge( $args, $t->args ) ) ); + + // Cast because a count is returned as a numeric string. The counts are summed below. + $terms_from_taxonomy = (array) wp_get_object_terms( $object_ids, $taxonomy, array_merge( $args, $t->args ) ); + + // Array keys should be preserved for values of $fields that use term_id for keys. + if ( ! empty( $args['fields'] ) && str_starts_with( $args['fields'], 'id=>' ) ) { + $terms = $terms + $terms_from_taxonomy; + } else { + $terms = array_merge( $terms, $terms_from_taxonomy ); + } } } } else { @@ -2360,7 +2425,8 @@ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { // Taxonomies registered without an 'args' param are handled here. if ( ! empty( $taxonomies ) ) { - $terms_from_remaining_taxonomies = get_terms( $args ); + // Cast because a count is returned as a numeric string. The counts are summed below. + $terms_from_remaining_taxonomies = (array) get_terms( $args ); // Array keys should be preserved for values of $fields that use term_id for keys. if ( ! empty( $args['fields'] ) && str_starts_with( $args['fields'], 'id=>' ) ) { @@ -2370,6 +2436,10 @@ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { } } + if ( isset( $args['fields'] ) && 'count' === $args['fields'] ) { + $terms = (string) array_sum( $terms ); + } + /** * Filters the terms for a given object or objects. * @@ -2379,7 +2449,7 @@ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { * @param int[] $object_ids Array of object IDs for which terms were retrieved. * @param string[] $taxonomies Array of taxonomy names from which terms were retrieved. * @param array $args Array of arguments for retrieving terms for the given - * object(s). See wp_get_object_terms() for details. + * object(s). See {@see wp_get_object_terms()} for details. */ $terms = apply_filters( 'get_object_terms', $terms, $object_ids, $taxonomies, $args ); @@ -2398,7 +2468,7 @@ function wp_get_object_terms( $object_ids, $taxonomies, $args = array() ) { * @param string $object_ids Comma separated list of object IDs for which terms were retrieved. * @param string $taxonomies SQL fragment of taxonomy names from which terms were retrieved. * @param array $args Array of arguments for retrieving terms for the given - * object(s). See wp_get_object_terms() for details. + * object(s). See {@see wp_get_object_terms()} for details. */ return apply_filters( 'wp_get_object_terms', $terms, $object_ids, $taxonomies, $args ); } diff --git a/tests/phpstan/baselines/property.nonObject.neon b/tests/phpstan/baselines/property.nonObject.neon index 13fd1ccf89fc9..d242b9373685b 100644 --- a/tests/phpstan/baselines/property.nonObject.neon +++ b/tests/phpstan/baselines/property.nonObject.neon @@ -23,16 +23,6 @@ parameters: identifier: property.nonObject count: 2 path: ../../../src/wp-admin/includes/ajax-actions.php - - - message: '#^Cannot access property \$id on int\|string\|WP_Term\.$#' - identifier: property.nonObject - count: 1 - path: ../../../src/wp-admin/includes/ajax-actions.php - - - message: '#^Cannot access property \$link on int\|string\|WP_Term\.$#' - identifier: property.nonObject - count: 1 - path: ../../../src/wp-admin/includes/ajax-actions.php - message: '#^Cannot access property \$name on array\|object\.$#' identifier: property.nonObject diff --git a/tests/phpstan/baselines/property.notFound.neon b/tests/phpstan/baselines/property.notFound.neon index b8e86ff092bc7..f4288f6aa6aff 100644 --- a/tests/phpstan/baselines/property.notFound.neon +++ b/tests/phpstan/baselines/property.notFound.neon @@ -18,6 +18,16 @@ parameters: ignoreErrors: + - + message: '#^Access to an undefined property WP_Term\:\:\$id\.$#' + identifier: property.notFound + count: 1 + path: ../../../src/wp-admin/includes/ajax-actions.php + - + message: '#^Access to an undefined property WP_Term\:\:\$link\.$#' + identifier: property.notFound + count: 1 + path: ../../../src/wp-admin/includes/ajax-actions.php - message: '#^Access to an undefined property WP_Upgrader_Skin\:\:\$language_update\.$#' identifier: property.notFound diff --git a/tests/phpunit/tests/term.php b/tests/phpunit/tests/term.php index a9b97c1f36dee..2b236102b710e 100644 --- a/tests/phpunit/tests/term.php +++ b/tests/phpunit/tests/term.php @@ -79,6 +79,39 @@ public function test_wp_count_terms() { $this->assertSame( '1', $count ); } + /** + * Ensures a queried parent term outside the taxonomy hierarchy counts as the integer 0. + * + * Every other outcome is a numeric string, so this is the one case where the return + * type is not a string at all. + * + * @ticket 61936 + * + * @covers ::wp_count_terms + */ + public function test_wp_count_terms_should_return_integer_zero_for_a_parent_outside_the_hierarchy() { + register_taxonomy( 'wptests_tax_hierarchical', 'post', array( 'hierarchical' => true ) ); + + $term_id = self::factory()->term->create( array( 'taxonomy' => 'wptests_tax_hierarchical' ) ); + $this->assertIsInt( $term_id, 'The term was not created.' ); + + $count = wp_count_terms( + array( + 'taxonomy' => 'wptests_tax_hierarchical', + 'parent' => 99999, + ) + ); + $this->assertSame( 0, $count, 'Incorrect count for a parent outside the hierarchy.' ); + + $count = wp_count_terms( + array( + 'taxonomy' => 'wptests_tax_hierarchical', + 'child_of' => 99999, + ) + ); + $this->assertSame( 0, $count, 'Incorrect count for a child_of outside the hierarchy.' ); + } + /** * @ticket 36399 */ diff --git a/tests/phpunit/tests/term/wpGetObjectTerms.php b/tests/phpunit/tests/term/wpGetObjectTerms.php index a8483f8a770a2..c1eb27ea71295 100644 --- a/tests/phpunit/tests/term/wpGetObjectTerms.php +++ b/tests/phpunit/tests/term/wpGetObjectTerms.php @@ -5,16 +5,18 @@ * @covers ::wp_get_object_terms */ class Tests_Term_WpGetObjectTerms extends WP_UnitTestCase { - private $taxonomy = 'wptests_tax'; + /** + * Name of the taxonomy registered for each test. + */ + private string $taxonomy = 'wptests_tax'; /** * Temporary storage for taxonomies for tests using filter callbacks. * * Used in the `test_taxonomies_passed_to_wp_get_object_terms_filter_should_be_quoted()` method. - * - * @var array + * This is a SQL fragment of taxonomy names from which terms were retrieved. */ - private $taxonomies; + private ?string $taxonomies = null; public function set_up() { parent::set_up(); @@ -25,7 +27,7 @@ public function set_up() { * Clean up after each test. */ public function tear_down() { - unset( $this->taxonomies ); + $this->taxonomies = null; parent::tear_down(); } @@ -1012,4 +1014,221 @@ public function test_duplicate_terms_should_not_be_returned_when_passed_multiple $this->assertSameSets( $expected, $actual ); } + + /** + * @ticket 61936 + */ + public function test_should_return_numeric_string_for_fields_count() { + $fields = array( 'fields' => 'count' ); + + $taxonomies = array( 'wptests_tax', 'wptests_tax_2' ); + + register_taxonomy( $taxonomies[0], 'post' ); + register_taxonomy( $taxonomies[1], 'post' ); + + $term_1_id = self::factory()->term->create( array( 'taxonomy' => $taxonomies[0] ) ); + $term_2_id = self::factory()->term->create( array( 'taxonomy' => $taxonomies[1] ) ); + + $post_ids = self::factory()->post->create_many( 2 ); + wp_set_object_terms( $post_ids[0], $term_1_id, $taxonomies[0] ); + wp_set_object_terms( $post_ids[1], $term_1_id, $taxonomies[0] ); + wp_set_object_terms( $post_ids[1], $term_2_id, $taxonomies[1] ); + + $terms_count = wp_get_object_terms( 0, $taxonomies[0], $fields ); + $this->assertSame( '0', $terms_count, 'Incorrect term count with empty object_ids.' ); + + $terms_count = wp_get_object_terms( $post_ids[0], '', $fields ); + $this->assertSame( '0', $terms_count, 'Incorrect term count with empty taxonomies.' ); + + $terms_count = wp_get_object_terms( $post_ids[0], $taxonomies[0], $fields ); + $this->assertSame( '1', $terms_count, 'Incorrect term count with single object_id and single taxonomy.' ); + + $terms_count = wp_get_object_terms( $post_ids[0], $taxonomies, $fields ); + $this->assertSame( '1', $terms_count, 'Incorrect term count with single object_id and multiple taxonomies.' ); + + $terms_count = wp_get_object_terms( $post_ids[1], $taxonomies, $fields ); + $this->assertSame( '2', $terms_count, 'Incorrect term count with single object_id and multiple taxonomies.' ); + + $terms_count = wp_get_object_terms( $post_ids, $taxonomies, $fields ); + $this->assertSame( '3', $terms_count, 'Incorrect term count with multiple object_ids and multiple taxonomies.' ); + } + + /** + * Ensures that a count can be requested with the `$args` parameter in query string form. + * + * An empty object ID or taxonomy list short-circuits before `$args` would otherwise be + * parsed, so the query string has to be parsed up front for the `fields` value to be read. + * + * @ticket 61936 + */ + public function test_should_return_numeric_string_for_fields_count_passed_as_query_string() { + $post_id = self::factory()->post->create(); + $this->assertIsInt( $post_id, 'The post was not created.' ); + + $term_id = self::factory()->term->create( array( 'taxonomy' => $this->taxonomy ) ); + $this->assertIsInt( $term_id, 'The term was not created.' ); + + wp_set_object_terms( $post_id, $term_id, $this->taxonomy ); + + $terms_count = wp_get_object_terms( 0, $this->taxonomy, 'fields=count' ); + $this->assertSame( '0', $terms_count, 'Incorrect term count with empty object_ids.' ); + + $terms_count = wp_get_object_terms( $post_id, '', 'fields=count' ); + $this->assertSame( '0', $terms_count, 'Incorrect term count with empty taxonomies.' ); + + $terms_count = wp_get_object_terms( $post_id, $this->taxonomy, 'fields=count' ); + $this->assertSame( '1', $terms_count, 'Incorrect term count.' ); + } + + /** + * Ensures that a count is summed across a taxonomy registered with an 'args' array. + * + * Such a taxonomy is queried by a recursive call rather than alongside the others, + * and that call returns the count as a numeric string rather than as an array. + * + * @ticket 61936 + */ + public function test_should_return_numeric_string_for_fields_count_with_taxonomy_registered_with_args() { + $taxonomy1 = 'wptests_tax'; + $taxonomy2 = 'wptests_tax_2'; + + // Any non-empty 'args' array sends the taxonomy down the recursive path. + register_taxonomy( $taxonomy1, 'post', array( 'args' => array( 0 ) ) ); + register_taxonomy( $taxonomy2, 'post' ); + + $post_id = self::factory()->post->create(); + $this->assertIsInt( $post_id, 'The post was not created.' ); + + $term_1_id = self::factory()->term->create( array( 'taxonomy' => $taxonomy1 ) ); + $this->assertIsInt( $term_1_id, 'The term in the first taxonomy was not created.' ); + + $term_2_id = self::factory()->term->create( array( 'taxonomy' => $taxonomy2 ) ); + $this->assertIsInt( $term_2_id, 'The term in the second taxonomy was not created.' ); + + wp_set_object_terms( $post_id, $term_1_id, $taxonomy1 ); + wp_set_object_terms( $post_id, $term_2_id, $taxonomy2 ); + + $terms_count = wp_get_object_terms( $post_id, $taxonomy1, array( 'fields' => 'count' ) ); + $this->assertSame( '1', $terms_count, 'Incorrect term count with the single taxonomy registered with args.' ); + + $terms_count = wp_get_object_terms( $post_id, array( $taxonomy1, $taxonomy2 ), array( 'fields' => 'count' ) ); + $this->assertSame( '2', $terms_count, 'Incorrect term count across both taxonomies.' ); + } + + /** + * Verifies that the `id=>` values of the `fields` argument key the results by term ID. + * + * These are the values for which the results are merged with `+` rather than with + * array_merge(), so that the term ID keys survive. + * + * @ticket 61936 + */ + public function test_should_return_terms_keyed_by_term_id_for_id_fields() { + register_taxonomy( 'wptests_tax_hierarchical', 'post', array( 'hierarchical' => true ) ); + + $parent_id = self::factory()->term->create( + array( + 'taxonomy' => 'wptests_tax_hierarchical', + 'name' => 'Parent', + 'slug' => 'parent', + ) + ); + $this->assertIsInt( $parent_id, 'The parent term was not created.' ); + + $child_id = self::factory()->term->create( + array( + 'taxonomy' => 'wptests_tax_hierarchical', + 'name' => 'Child', + 'slug' => 'child', + 'parent' => $parent_id, + ) + ); + $this->assertIsInt( $child_id, 'The child term was not created.' ); + + $post_id = self::factory()->post->create(); + $this->assertIsInt( $post_id, 'The post was not created.' ); + + wp_set_object_terms( $post_id, array( $parent_id, $child_id ), 'wptests_tax_hierarchical' ); + + $expected = array( + 'id=>parent' => array( + $parent_id => 0, + $child_id => $parent_id, + ), + 'id=>name' => array( + $parent_id => 'Parent', + $child_id => 'Child', + ), + 'id=>slug' => array( + $parent_id => 'parent', + $child_id => 'child', + ), + ); + + foreach ( $expected as $fields => $expected_terms ) { + $actual = wp_get_object_terms( + $post_id, + 'wptests_tax_hierarchical', + array( + 'fields' => $fields, + 'orderby' => 'term_id', + 'order' => 'ASC', + ) + ); + + $this->assertSame( $expected_terms, $actual, "Incorrect terms for the '$fields' fields value." ); + } + } + + /** + * Ensures the term ID keys survive for a taxonomy registered with an 'args' array. + * + * Such a taxonomy is queried by a recursive call, and those results were merged with + * array_merge(), which renumbers the integer keys the `id=>` values rely on. + * + * @ticket 61936 + */ + public function test_should_return_terms_keyed_by_term_id_for_id_fields_with_taxonomy_registered_with_args() { + $taxonomy1 = 'wptests_tax'; + $taxonomy2 = 'wptests_tax_2'; + + // Any non-empty 'args' array sends the taxonomy down the recursive path. + register_taxonomy( $taxonomy1, 'post', array( 'args' => array( 0 ) ) ); + register_taxonomy( $taxonomy2, 'post' ); + + $post_id = self::factory()->post->create(); + $this->assertIsInt( $post_id, 'The post was not created.' ); + + $term_1_id = self::factory()->term->create( + array( + 'taxonomy' => $taxonomy1, + 'name' => 'Alpha', + ) + ); + $this->assertIsInt( $term_1_id, 'The term in the first taxonomy was not created.' ); + + $term_2_id = self::factory()->term->create( + array( + 'taxonomy' => $taxonomy2, + 'name' => 'Beta', + ) + ); + $this->assertIsInt( $term_2_id, 'The term in the second taxonomy was not created.' ); + + wp_set_object_terms( $post_id, $term_1_id, $taxonomy1 ); + wp_set_object_terms( $post_id, $term_2_id, $taxonomy2 ); + + $actual = wp_get_object_terms( + $post_id, + array( $taxonomy1, $taxonomy2 ), + array( 'fields' => 'id=>name' ) + ); + + $expected = array( + $term_1_id => 'Alpha', + $term_2_id => 'Beta', + ); + + $this->assertSame( $expected, $actual, 'Terms are not keyed by term ID.' ); + } } From d84095d77bba3dbc360f50b8d04558e759c22469 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Sat, 5 Sep 2026 05:56:32 +0000 Subject: [PATCH 115/363] Role/Capability: Ensure `wp_roles()` returns `WP_Roles`. Previously `wp_roles()` only checked whether the `$wp_roles` global was set before returning it, so any code that overwrote that global with another value caused the function to hand back something which is not a `WP_Roles` object. Checking `instanceof` instead guarantees the return type, matching the approach already used by `wp_scripts()` and `wp_styles()`. Developed in https://github.com/WordPress/wordpress-develop/pull/8315. Follow-up to r32541. Props marian1. See #62562. Fixes #62959. git-svn-id: https://develop.svn.wordpress.org/trunk@63490 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/capabilities.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-includes/capabilities.php b/src/wp-includes/capabilities.php index 645ab5588ee5e..6f8b57d50b348 100644 --- a/src/wp-includes/capabilities.php +++ b/src/wp-includes/capabilities.php @@ -1078,10 +1078,10 @@ function user_can_for_site( $user, $site_id, $capability, ...$args ) { * * @return WP_Roles WP_Roles global instance if not already instantiated. */ -function wp_roles() { +function wp_roles(): WP_Roles { global $wp_roles; - if ( ! isset( $wp_roles ) ) { + if ( ! ( $wp_roles instanceof WP_Roles ) ) { $wp_roles = new WP_Roles(); } return $wp_roles; From 235ab8443dc03027356ad91ce666d5dae4d8c093 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Sat, 5 Sep 2026 08:44:43 +0000 Subject: [PATCH 116/363] Docs: Align `@param` tag columns in general core API docblocks. Aligns `@param` tag columns in docblocks across the general core APIs per the PHP inline documentation standards. Developed in: https://github.com/WordPress/wordpress-develop/pull/13317 Props mukesh27, wildworks. See #65818. git-svn-id: https://develop.svn.wordpress.org/trunk@63491 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/file.php | 2 +- src/wp-includes/class-wp-fatal-error-handler.php | 4 ++-- src/wp-includes/class-wp-hook.php | 2 +- src/wp-includes/class-wp-http-requests-hooks.php | 6 +++--- src/wp-includes/class-wp-oembed.php | 2 +- src/wp-includes/cron.php | 16 ++++++++-------- src/wp-includes/embed.php | 6 +++--- src/wp-includes/formatting.php | 6 +++--- src/wp-includes/functions.php | 10 +++++----- src/wp-includes/functions.wp-scripts.php | 2 +- src/wp-includes/general-template.php | 2 +- src/wp-includes/link-template.php | 6 +++--- src/wp-includes/load.php | 4 ++-- src/wp-includes/option.php | 2 +- src/wp-includes/pomo/mo.php | 6 +++--- src/wp-includes/pomo/translations.php | 2 +- 16 files changed, 39 insertions(+), 39 deletions(-) diff --git a/src/wp-admin/includes/file.php b/src/wp-admin/includes/file.php index 99b9735011bbc..ef5a5025bef22 100644 --- a/src/wp-admin/includes/file.php +++ b/src/wp-admin/includes/file.php @@ -1312,7 +1312,7 @@ function download_url( $url, $timeout = 300, $signature_verification = false ) { * @since 5.2.0 * * @param false|string $signature_url The URL where signatures can be found for a file, or false if none are known. - * @param string $url The URL being verified. + * @param string $url The URL being verified. */ $signature_url = apply_filters( 'wp_signature_url', $signature_url, $url ); diff --git a/src/wp-includes/class-wp-fatal-error-handler.php b/src/wp-includes/class-wp-fatal-error-handler.php index cb09c6fed84c6..3632e372d4393 100644 --- a/src/wp-includes/class-wp-fatal-error-handler.php +++ b/src/wp-includes/class-wp-fatal-error-handler.php @@ -228,8 +228,8 @@ protected function display_default_error_template( $error, $handled ) { * * @since 5.2.0 * - * @param array $args Associative array of arguments passed to `wp_die()`. By default these contain a - * 'response' key, and optionally 'link_url' and 'link_text' keys. + * @param array $args Associative array of arguments passed to `wp_die()`. By default these contain a + * 'response' key, and optionally 'link_url' and 'link_text' keys. * @param array $error Error information retrieved from `error_get_last()`. */ $args = apply_filters( 'wp_php_error_args', $args, $error ); diff --git a/src/wp-includes/class-wp-hook.php b/src/wp-includes/class-wp-hook.php index 5a5874e39cabb..1718878308300 100644 --- a/src/wp-includes/class-wp-hook.php +++ b/src/wp-includes/class-wp-hook.php @@ -526,7 +526,7 @@ public function offsetGet( $offset ) { * @link https://www.php.net/manual/en/arrayaccess.offsetset.php * * @param int|null $offset The offset to assign the value to. - * @param array $value The value to set. + * @param array $value The value to set. * @phpstan-param array $value */ #[ReturnTypeWillChange] diff --git a/src/wp-includes/class-wp-http-requests-hooks.php b/src/wp-includes/class-wp-http-requests-hooks.php index 80e4eb7ef4b9f..f399acc860229 100644 --- a/src/wp-includes/class-wp-http-requests-hooks.php +++ b/src/wp-includes/class-wp-http-requests-hooks.php @@ -68,9 +68,9 @@ public function dispatch( $hook, $parameters = array() ) { * * @since 4.7.0 * - * @param array $parameters Parameters from Requests internal hook. - * @param array $request Request data in WP_Http format. - * @param string $url URL to request. + * @param array $parameters Parameters from Requests internal hook. + * @param array $request Request data in WP_Http format. + * @param string $url URL to request. */ do_action_ref_array( "requests-{$hook}", $parameters, $this->request, $this->url ); // phpcs:ignore WordPress.NamingConventions.ValidHookName.UseUnderscores diff --git a/src/wp-includes/class-wp-oembed.php b/src/wp-includes/class-wp-oembed.php index b1a23ff66144d..fa307092d409c 100644 --- a/src/wp-includes/class-wp-oembed.php +++ b/src/wp-includes/class-wp-oembed.php @@ -807,7 +807,7 @@ public function data2html( $data, $url ) { * * @param string|false $html Existing HTML. * @param object $data Data object from WP_oEmbed::data2html() - * @param string $url The original URL passed to oEmbed. + * @param string $url The original URL passed to oEmbed. * @return string|false Possibly modified $html. */ public function _strip_newlines( $html, $data, $url ) { diff --git a/src/wp-includes/cron.php b/src/wp-includes/cron.php index faa5b0fd6681e..82889d7cc7e2f 100644 --- a/src/wp-includes/cron.php +++ b/src/wp-includes/cron.php @@ -787,12 +787,12 @@ function wp_get_scheduled_event( $hook, $args = array(), $timestamp = null ) { * * @since 5.1.0 * - * @param null|false|object $pre Value to return instead. Default null to continue retrieving the event. - * @param string $hook Action hook of the event. - * @param array $args Array containing each separate argument to pass to the hook's callback function. - * Although not passed to a callback, these arguments are used to uniquely identify - * the event. - * @param int|null $timestamp Unix timestamp (UTC) of the event. Null to retrieve next scheduled event. + * @param null|false|object $pre Value to return instead. Default null to continue retrieving the event. + * @param string $hook Action hook of the event. + * @param array $args Array containing each separate argument to pass to the hook's callback function. + * Although not passed to a callback, these arguments are used to uniquely identify + * the event. + * @param int|null $timestamp Unix timestamp (UTC) of the event. Null to retrieve next scheduled event. */ $pre = apply_filters( 'pre_get_scheduled_event', null, $hook, $args, $timestamp ); @@ -966,7 +966,7 @@ function spawn_cron( $gmt_time = 0 ) { * @since 3.5.0 * @since 4.5.0 The `$doing_wp_cron` parameter was added. * - * @param array $cron_request_array { + * @param array $cron_request_array { * An array of cron request URL arguments. * * @type string $url The cron request URL. @@ -979,7 +979,7 @@ function spawn_cron( $gmt_time = 0 ) { * @type bool $sslverify Whether SSL should be verified for the request. Default false. * } * } - * @param string $doing_wp_cron The Unix timestamp (UTC) of the cron lock with microseconds. + * @param string $doing_wp_cron The Unix timestamp (UTC) of the cron lock with microseconds. */ $cron_request = apply_filters( 'cron_request', diff --git a/src/wp-includes/embed.php b/src/wp-includes/embed.php index 003c36cf9de58..e87cf4ec57989 100644 --- a/src/wp-includes/embed.php +++ b/src/wp-includes/embed.php @@ -98,7 +98,7 @@ function wp_embed_defaults( $url = '' ) { * * @see WP_oEmbed * - * @param string $url The URL that should be embedded. + * @param string $url The URL that should be embedded. * @param array|string $args { * Optional. Additional arguments for retrieving embed HTML. Default empty. * @@ -264,8 +264,8 @@ function wp_embed_handler_youtube( $matches, $attr, $url, $rawattr ) { * @since 3.6.0 * * @param array $matches The RegEx matches from the provided regex when calling wp_embed_register_handler(). - * @param array $attr Embed attributes. - * @param string $url The original URL that was matched by the regex. + * @param array $attr Embed attributes. + * @param string $url The original URL that was matched by the regex. * @param array $rawattr The original unmodified attributes. * @return string The embed HTML. */ diff --git a/src/wp-includes/formatting.php b/src/wp-includes/formatting.php index 94f8b3da849cb..1c0b62cf1e14f 100644 --- a/src/wp-includes/formatting.php +++ b/src/wp-includes/formatting.php @@ -3840,9 +3840,9 @@ function sanitize_email( $email ) { * * @since 2.8.0 * - * @param string $sanitized_email The sanitized email address. - * @param string $email The email address, as provided to sanitize_email(). - * @param string|null $message A message to pass to the user. null if email is sanitized. + * @param string $sanitized_email The sanitized email address. + * @param string $email The email address, as provided to sanitize_email(). + * @param string|null $message A message to pass to the user. null if email is sanitized. */ return apply_filters( 'sanitize_email', '', $email, 'email_too_short' ); } diff --git a/src/wp-includes/functions.php b/src/wp-includes/functions.php index 31de822d2aacd..1f29dfb5f29ab 100644 --- a/src/wp-includes/functions.php +++ b/src/wp-includes/functions.php @@ -3813,7 +3813,7 @@ function wp_nonce_ays( $action ) { * error data with the key 'title' may be used to specify the title. * If `$title` is an integer, then it is treated as the response code. * Default empty string. - * @param string|array|int $args { + * @param string|array|int $args { * Optional. Arguments to control behavior. If `$args` is an integer, then it is treated * as the response code. Default empty array. * @@ -8382,7 +8382,7 @@ function wp_site_admin_email_change_notification( $old_email, $new_email, $optio * * @since 4.9.0 * - * @param array $email_change_email { + * @param array $email_change_email { * Used to build wp_mail(). * * @type string $to The intended recipient. @@ -8395,8 +8395,8 @@ function wp_site_admin_email_change_notification( $old_email, $new_email, $optio * - `###SITEURL###` The URL to the site. * @type string $headers Headers. * } - * @param string $old_email The old site admin email address. - * @param string $new_email The new site admin email address. + * @param string $old_email The old site admin email address. + * @param string $new_email The new site admin email address. */ $email_change_email = apply_filters( 'site_admin_email_change_email', $email_change_email, $old_email, $new_email ); @@ -8941,7 +8941,7 @@ function wp_get_direct_update_https_url() { * @since MU (3.0.0) * @since 5.2.0 $max_execution_time parameter added. * - * @param string $directory Full path of a directory. + * @param string $directory Full path of a directory. * @param int $max_execution_time Maximum time to run before giving up. In seconds. * The timeout is global and is measured from the moment WordPress started to load. * @return int|false|null Size in bytes if a valid directory. False if not. Null if timeout. diff --git a/src/wp-includes/functions.wp-scripts.php b/src/wp-includes/functions.wp-scripts.php index 5e9589252124b..52504b890ad65 100644 --- a/src/wp-includes/functions.wp-scripts.php +++ b/src/wp-includes/functions.wp-scripts.php @@ -445,7 +445,7 @@ function wp_deregister_script( $handle ) { * as a query string for cache busting purposes. If version is set to false, a version * number is automatically added equal to current installed WordPress version. * If set to null, no version is added. - * @param array|bool $args { + * @param array|bool $args { * Optional. An array of extra args for the script. Default empty array. * Otherwise, it may be a boolean in which case it determines whether the script is printed in the footer. Default false. * diff --git a/src/wp-includes/general-template.php b/src/wp-includes/general-template.php index 7ba1d623f4631..63a3aa67123b2 100644 --- a/src/wp-includes/general-template.php +++ b/src/wp-includes/general-template.php @@ -4814,7 +4814,7 @@ function get_language_attributes( $doctype = 'html' ) { * @since 2.5.0 * @since 4.3.0 Added the `$doctype` parameter. * - * @param string $output A space-separated list of language attributes. + * @param string $output A space-separated list of language attributes. * @param string $doctype The type of HTML document (xhtml|html). */ return apply_filters( 'language_attributes', $output, $doctype ); diff --git a/src/wp-includes/link-template.php b/src/wp-includes/link-template.php index f4accadb0bf3a..ed37a83a87506 100644 --- a/src/wp-includes/link-template.php +++ b/src/wp-includes/link-template.php @@ -2007,9 +2007,9 @@ function get_adjacent_post( $in_same_term = false, $excluded_terms = '', $previo * @since 4.9.0 Added the `$order` parameter. * @since 6.9.0 Adds ID sort to ensure deterministic ordering for posts with identical dates. * - * @param string $order_by The `ORDER BY` clause in the SQL. - * @param WP_Post $post WP_Post object. - * @param string $order Sort order. 'DESC' for previous post, 'ASC' for next. + * @param string $order_by The `ORDER BY` clause in the SQL. + * @param WP_Post $post WP_Post object. + * @param string $order Sort order. 'DESC' for previous post, 'ASC' for next. */ $sort = apply_filters( "get_{$adjacent}_post_sort", "ORDER BY p.post_date $order, p.ID $order LIMIT 1", $post, $order ); diff --git a/src/wp-includes/load.php b/src/wp-includes/load.php index 27c58b57dd671..9d407453424c5 100644 --- a/src/wp-includes/load.php +++ b/src/wp-includes/load.php @@ -2042,8 +2042,8 @@ function wp_is_site_protected_by_basic_auth( $context = '' ) { * * @since 5.6.1 * - * @param bool $is_protected Whether the site is protected by Basic Auth. - * @param string $context The context to check for protection. One of 'login', 'admin', or 'front'. + * @param bool $is_protected Whether the site is protected by Basic Auth. + * @param string $context The context to check for protection. One of 'login', 'admin', or 'front'. */ return apply_filters( 'wp_is_site_protected_by_basic_auth', $is_protected, $context ); } diff --git a/src/wp-includes/option.php b/src/wp-includes/option.php index fb808b7ee4df1..5d877e7273f47 100644 --- a/src/wp-includes/option.php +++ b/src/wp-includes/option.php @@ -2978,7 +2978,7 @@ function register_initial_settings() { * @param string $option_group A settings group name. Should correspond to an allowed option key name. * Default allowed option key names include 'general', 'discussion', 'media', * 'reading', 'writing', and 'options'. - * @param string $option_name The name of an option to sanitize and save. + * @param string $option_name The name of an option to sanitize and save. * @param array $args { * Data used to describe the setting when registered. * diff --git a/src/wp-includes/pomo/mo.php b/src/wp-includes/pomo/mo.php index 1bbc40ab65aa2..c519633d8b968 100644 --- a/src/wp-includes/pomo/mo.php +++ b/src/wp-includes/pomo/mo.php @@ -310,10 +310,10 @@ public function import_from_reader( $reader ) { * found in a MO file * * @static - * @param string $original original string to translate from MO file. Might contain - * 0x04 as context separator or 0x00 as singular/plural separator + * @param string $original original string to translate from MO file. Might contain + * 0x04 as context separator or 0x00 as singular/plural separator * @param string $translation translation string from MO file. Might contain - * 0x00 as a plural translations separator + * 0x00 as a plural translations separator * @return Translation_Entry Entry instance. */ public function &make_entry( $original, $translation ) { diff --git a/src/wp-includes/pomo/translations.php b/src/wp-includes/pomo/translations.php index c4a9ba72d6755..64b9295ee6634 100644 --- a/src/wp-includes/pomo/translations.php +++ b/src/wp-includes/pomo/translations.php @@ -91,7 +91,7 @@ public function add_entry_or_merge( $entry ) { * @since 2.8.0 * * @param string $header header name, without trailing : - * @param string $value header value, without trailing \n + * @param string $value header value, without trailing \n */ public function set_header( $header, $value ) { $this->headers[ $header ] = $value; From c97b9967b3b947a84cb1230ebed3b8399f303264 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Sat, 5 Sep 2026 08:51:09 +0000 Subject: [PATCH 117/363] Docs: Align `@param` tag columns in administration docblocks. Aligns `@param` tag columns in docblocks across the administration screens per the PHP inline documentation standards. Developed in: https://github.com/WordPress/wordpress-develop/pull/13316 Props mukesh27, wildworks. See #65818. git-svn-id: https://develop.svn.wordpress.org/trunk@63492 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-community-events.php | 2 +- src/wp-admin/includes/class-wp-internal-pointers.php | 4 ++-- src/wp-admin/includes/class-wp-list-table.php | 2 +- src/wp-admin/includes/class-wp-posts-list-table.php | 2 +- src/wp-admin/includes/class-wp-terms-list-table.php | 4 ++-- src/wp-admin/includes/list-table.php | 2 +- src/wp-admin/includes/template.php | 2 +- src/wp-includes/class-walker-nav-menu.php | 10 +++++----- src/wp-includes/class-walker-page.php | 2 +- src/wp-includes/class-wp-admin-bar.php | 2 +- src/wp-includes/class-wp-customize-manager.php | 2 +- .../customize/class-wp-customize-selective-refresh.php | 2 +- src/wp-includes/widgets.php | 2 +- 13 files changed, 19 insertions(+), 19 deletions(-) diff --git a/src/wp-admin/includes/class-wp-community-events.php b/src/wp-admin/includes/class-wp-community-events.php index a31b3651b9a1c..d6a0c8161add9 100644 --- a/src/wp-admin/includes/class-wp-community-events.php +++ b/src/wp-admin/includes/class-wp-community-events.php @@ -39,7 +39,7 @@ class WP_Community_Events { * * @since 4.8.0 * - * @param int $user_id WP user ID. + * @param int $user_id WP user ID. * @param false|array $user_location { * Stored location data for the user. false to pass no location. * diff --git a/src/wp-admin/includes/class-wp-internal-pointers.php b/src/wp-admin/includes/class-wp-internal-pointers.php index 9a2135b5279fd..22233884b4beb 100644 --- a/src/wp-admin/includes/class-wp-internal-pointers.php +++ b/src/wp-admin/includes/class-wp-internal-pointers.php @@ -109,8 +109,8 @@ public static function enqueue_scripts( $hook_suffix ) { * @since 3.3.0 * * @param string $pointer_id The pointer ID. - * @param string $selector The HTML elements, on which the pointer should be attached. - * @param array $args Arguments to be passed to the pointer JS (see wp-pointer.js). + * @param string $selector The HTML elements, on which the pointer should be attached. + * @param array $args Arguments to be passed to the pointer JS (see wp-pointer.js). */ private static function print_js( $pointer_id, $selector, $args ) { if ( empty( $pointer_id ) || empty( $selector ) || empty( $args ) || empty( $args['content'] ) ) { diff --git a/src/wp-admin/includes/class-wp-list-table.php b/src/wp-admin/includes/class-wp-list-table.php index 17ec0c28f5c1f..df8e71834e0db 100644 --- a/src/wp-admin/includes/class-wp-list-table.php +++ b/src/wp-admin/includes/class-wp-list-table.php @@ -733,7 +733,7 @@ protected function months_dropdown( $post_type ) { * * @since 5.7.0 * - * @param object[]|false $months 'Months' drop-down results. Default false. + * @param object[]|false $months 'Months' drop-down results. Default false. * @param string $post_type The post type. */ $months = apply_filters( 'pre_months_dropdown_query', false, $post_type ); diff --git a/src/wp-admin/includes/class-wp-posts-list-table.php b/src/wp-admin/includes/class-wp-posts-list-table.php index bb8382569dbaa..d3d631b9b4467 100644 --- a/src/wp-admin/includes/class-wp-posts-list-table.php +++ b/src/wp-admin/includes/class-wp-posts-list-table.php @@ -1854,7 +1854,7 @@ public function inline_edit() { * @see wp_dropdown_users() * * @param array $users_opt An array of arguments passed to wp_dropdown_users(). - * @param bool $bulk A flag to denote if it's a bulk action. + * @param bool $bulk A flag to denote if it's a bulk action. */ $users_opt = apply_filters( 'quick_edit_dropdown_authors_args', $users_opt, $bulk ); diff --git a/src/wp-admin/includes/class-wp-terms-list-table.php b/src/wp-admin/includes/class-wp-terms-list-table.php index 561888fed8394..9481f0967a744 100644 --- a/src/wp-admin/includes/class-wp-terms-list-table.php +++ b/src/wp-admin/includes/class-wp-terms-list-table.php @@ -395,8 +395,8 @@ public function column_name( $tag ) { * * @see WP_Terms_List_Table::column_name() * - * @param string $pad_tag_name The term name, padded if not top-level. - * @param WP_Term $tag Term object. + * @param string $pad_tag_name The term name, padded if not top-level. + * @param WP_Term $tag Term object. */ $name = apply_filters( 'term_name', $pad . ' ' . $tag->name, $tag ); diff --git a/src/wp-admin/includes/list-table.php b/src/wp-admin/includes/list-table.php index 1e2c190c80fe9..97dfe4f858c7e 100644 --- a/src/wp-admin/includes/list-table.php +++ b/src/wp-admin/includes/list-table.php @@ -84,7 +84,7 @@ function _get_list_table( $class_name, $args = array() ) { * * @since 2.7.0 * - * @param string $screen The handle for the screen to register column headers for. This is + * @param string $screen The handle for the screen to register column headers for. This is * usually the hook name returned by the `add_*_page()` functions. * @param string[] $columns An array of columns with column IDs as the keys and translated * column names as the values. diff --git a/src/wp-admin/includes/template.php b/src/wp-admin/includes/template.php index e7034e1499ecd..a24aae32cc8dd 100644 --- a/src/wp-admin/includes/template.php +++ b/src/wp-admin/includes/template.php @@ -1808,7 +1808,7 @@ function do_settings_sections( $page ) { * * @global array $wp_settings_fields Storage array of settings fields and their pages/sections. * - * @param string $page Slug title of the admin page whose settings fields you want to show. + * @param string $page Slug title of the admin page whose settings fields you want to show. * @param string $section Slug title of the settings section whose fields you want to show. */ function do_settings_fields( $page, $section ) { diff --git a/src/wp-includes/class-walker-nav-menu.php b/src/wp-includes/class-walker-nav-menu.php index 3d9f442bb8e87..8047047757cea 100644 --- a/src/wp-includes/class-walker-nav-menu.php +++ b/src/wp-includes/class-walker-nav-menu.php @@ -99,13 +99,13 @@ public function start_lvl( &$output, $depth = 0, $args = null ) { * * @since 6.3.0 * - * @param array $atts { + * @param array $atts { * The HTML attributes applied to the `
    -
    +
    div:not(.boot-layout-container):not(#screen-meta) { + body.js #wpbody-content > div:not(#options-connectors-wp-admin-app):not(#screen-meta) { display: none; } body.js #wpfooter { @@ -324,7 +328,7 @@ function wp_options_connectors_wp_admin_render_page() { ); ?>
    -
    +
    { -}; -var useIsoLayoutEffect = typeof document !== "undefined" ? React4.useLayoutEffect : noop; - // node_modules/@base-ui/utils/warn.mjs var set2; if (true) { @@ -379,17 +373,14 @@ function warn(...messages) { } } -// node_modules/@base-ui/react/internals/direction-context/DirectionContext.mjs -var React5 = __toESM(require_react(), 1); -var DirectionContext = /* @__PURE__ */ React5.createContext(void 0); -if (true) DirectionContext.displayName = "DirectionContext"; -function useDirection() { - const context = React5.useContext(DirectionContext); - return context?.direction ?? "ltr"; -} +// node_modules/@base-ui/utils/useIsoLayoutEffect.mjs +var React3 = __toESM(require_react(), 1); +var noop = () => { +}; +var useIsoLayoutEffect = typeof document !== "undefined" ? React3.useLayoutEffect : noop; // node_modules/@base-ui/react/internals/useRenderElement.mjs -var React8 = __toESM(require_react(), 1); +var React6 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/useMergedRefs.mjs function useMergedRefs(a, b, c, d) { @@ -464,7 +455,7 @@ function update(forkRef, refs) { if (typeof cleanupCallback === "function") { cleanupCallback(); } else { - ref(null); + void ref(null); } break; } @@ -481,18 +472,18 @@ function update(forkRef, refs) { } // node_modules/@base-ui/utils/getReactElementRef.mjs -var React7 = __toESM(require_react(), 1); +var React5 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/reactVersion.mjs -var React6 = __toESM(require_react(), 1); -var majorVersion = parseInt(React6.version, 10); +var React4 = __toESM(require_react(), 1); +var majorVersion = parseInt(React4.version, 10); function isReactVersionAtLeast(reactVersionToCheck) { return majorVersion >= reactVersionToCheck; } // node_modules/@base-ui/utils/getReactElementRef.mjs function getReactElementRef(element) { - if (!/* @__PURE__ */ React7.isValidElement(element)) { + if (!/* @__PURE__ */ React5.isValidElement(element)) { return null; } const reactElement = element; @@ -730,17 +721,17 @@ function useRenderElementProps(componentProps, params = {}) { state = EMPTY_OBJECT, ref, props, - stateAttributesMapping: stateAttributesMapping3, + stateAttributesMapping, enabled = true } = params; const className = enabled ? resolveClassName(classNameProp, state) : void 0; const style = enabled ? resolveStyle(styleProp, state) : void 0; - const stateProps = enabled ? getStateAttributesProps(state, stateAttributesMapping3) : EMPTY_OBJECT; + const stateProps = enabled ? getStateAttributesProps(state, stateAttributesMapping) : EMPTY_OBJECT; const resolvedProps = enabled && props ? resolveRenderFunctionProps(props) : void 0; const outProps = enabled ? mergeObjects(stateProps, resolvedProps) ?? {} : EMPTY_OBJECT; if (typeof document !== "undefined") { if (!enabled) { - useMergedRefs(null, null); + void useMergedRefs(null, null); } else if (Array.isArray(ref)) { outProps.ref = useMergedRefsN([outProps.ref, getReactElementRef(renderProp), ...ref]); } else { @@ -779,15 +770,15 @@ function evaluateRenderProp(element, render, props, state) { mergedProps.ref = props.ref; let newElement = render; if (newElement?.$$typeof === REACT_LAZY_TYPE) { - const children = React8.Children.toArray(render); + const children = React6.Children.toArray(render); newElement = children[0]; } if (true) { - if (!/* @__PURE__ */ React8.isValidElement(newElement)) { + if (!/* @__PURE__ */ React6.isValidElement(newElement)) { throw new Error(["Base UI: The `render` prop was provided an invalid React element as `React.isValidElement(render)` is `false`.", "A valid React element must be provided to the `render` prop because it is cloned with props to replace the default element.", "https://base-ui.com/r/invalid-render-prop"].join("\n")); } } - return /* @__PURE__ */ React8.cloneElement(newElement, mergedProps); + return /* @__PURE__ */ React6.cloneElement(newElement, mergedProps); } if (element) { if (typeof element === "string") { @@ -824,16 +815,16 @@ function renderTag(Tag, props) { key: props.key }); } - return /* @__PURE__ */ React8.createElement(Tag, props); + return /* @__PURE__ */ React6.createElement(Tag, props); } // node_modules/@base-ui/utils/useId.mjs -var React9 = __toESM(require_react(), 1); +var React7 = __toESM(require_react(), 1); var globalId = 0; function useGlobalId(idOverride, prefix = "mui") { - const [defaultId, setDefaultId] = React9.useState(idOverride); + const [defaultId, setDefaultId] = React7.useState(idOverride); const id = idOverride || defaultId; - React9.useEffect(() => { + React7.useEffect(() => { if (defaultId == null) { globalId += 1; setDefaultId(`${prefix}-${globalId}`); @@ -957,17 +948,16 @@ function createChangeEventDetails(reason, event, trigger, customProperties) { } // node_modules/@base-ui/react/internals/useTransitionStatus.mjs -var React11 = __toESM(require_react(), 1); +var React9 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/useOnMount.mjs -var React10 = __toESM(require_react(), 1); -var EMPTY = []; +var React8 = __toESM(require_react(), 1); function useOnMount(fn) { - React10.useEffect(fn, EMPTY); + React8.useEffect(fn, EMPTY_ARRAY); } // node_modules/@base-ui/utils/useAnimationFrame.mjs -var EMPTY2 = null; +var EMPTY = null; var LAST_RAF = globalThis.requestAnimationFrame; var Scheduler = class { /* This implementation uses an array as a backing data-structure for frame callbacks. @@ -1027,21 +1017,21 @@ var AnimationFrame = class _AnimationFrame { static cancel(id) { return scheduler.cancel(id); } - currentId = EMPTY2; + currentId = EMPTY; /** * Executes `fn` after `delay`, clearing any previously scheduled call. */ request(fn) { this.cancel(); this.currentId = scheduler.request(() => { - this.currentId = EMPTY2; + this.currentId = EMPTY; fn(); }); } cancel = () => { - if (this.currentId !== EMPTY2) { + if (this.currentId !== EMPTY) { scheduler.cancel(this.currentId); - this.currentId = EMPTY2; + this.currentId = EMPTY; } }; disposeEffect = () => { @@ -1056,8 +1046,8 @@ function useAnimationFrame() { // node_modules/@base-ui/react/internals/useTransitionStatus.mjs function useTransitionStatus(open, enableIdleState = false, deferEndingState = false) { - const [transitionStatus, setTransitionStatus] = React11.useState(open && enableIdleState ? "idle" : void 0); - const [mounted, setMounted] = React11.useState(open); + const [transitionStatus, setTransitionStatus] = React9.useState(open && enableIdleState ? "idle" : void 0); + const [mounted, setMounted] = React9.useState(open); if (open && !mounted) { setMounted(true); setTransitionStatus("starting"); @@ -1118,10 +1108,10 @@ var TransitionStatusDataAttributes = /* @__PURE__ */ (function(TransitionStatusD return TransitionStatusDataAttributes2; })({}); var STARTING_HOOK = { - [TransitionStatusDataAttributes.startingStyle]: "" + "data-starting-style": "" }; var ENDING_HOOK = { - [TransitionStatusDataAttributes.endingStyle]: "" + "data-ending-style": "" }; var transitionStatusMapping = { transitionStatus(value) { @@ -1136,7 +1126,7 @@ var transitionStatusMapping = { }; // node_modules/@base-ui/react/internals/use-button/useButton.mjs -var React14 = __toESM(require_react(), 1); +var React12 = __toESM(require_react(), 1); // node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.mjs function hasWindow() { @@ -1295,11 +1285,11 @@ function getFrameElement(win) { } // node_modules/@base-ui/react/internals/composite/root/CompositeRootContext.mjs -var React12 = __toESM(require_react(), 1); -var CompositeRootContext = /* @__PURE__ */ React12.createContext(void 0); +var React10 = __toESM(require_react(), 1); +var CompositeRootContext = /* @__PURE__ */ React10.createContext(void 0); if (true) CompositeRootContext.displayName = "CompositeRootContext"; function useCompositeRootContext(optional = false) { - const context = React12.useContext(CompositeRootContext); + const context = React10.useContext(CompositeRootContext); if (context === void 0 && !optional) { throw new Error(true ? "Base UI: CompositeRootContext is missing. Composite parts must be placed within ." : formatErrorMessage_default(16)); } @@ -1307,7 +1297,7 @@ function useCompositeRootContext(optional = false) { } // node_modules/@base-ui/react/utils/useFocusableWhenDisabled.mjs -var React13 = __toESM(require_react(), 1); +var React11 = __toESM(require_react(), 1); function useFocusableWhenDisabled(parameters) { const { focusableWhenDisabled, @@ -1318,7 +1308,7 @@ function useFocusableWhenDisabled(parameters) { } = parameters; const isFocusableComposite = composite && focusableWhenDisabled !== false; const isNonFocusableComposite = composite && focusableWhenDisabled === false; - const props = React13.useMemo(() => { + const props = React11.useMemo(() => { const additionalProps = { // allow Tabbing away from focusableWhenDisabled elements onKeyDown(event) { @@ -1346,6 +1336,27 @@ function useFocusableWhenDisabled(parameters) { }; } +// node_modules/@base-ui/utils/owner.mjs +function ownerDocument(node) { + return node?.ownerDocument || document; +} + +// node_modules/@base-ui/react/utils/dispatchClickWithModifiers.mjs +function dispatchClickWithModifiers(target, sourceEvent, { + detail = 0 +} = {}) { + target.dispatchEvent(new (getWindow(target)).PointerEvent("click", { + bubbles: true, + cancelable: true, + composed: true, + detail, + shiftKey: sourceEvent.shiftKey, + ctrlKey: sourceEvent.ctrlKey, + altKey: sourceEvent.altKey, + metaKey: sourceEvent.metaKey + })); +} + // node_modules/@base-ui/react/internals/use-button/useButton.mjs function useButton(parameters = {}) { const { @@ -1355,7 +1366,7 @@ function useButton(parameters = {}) { native: isNativeButton = true, composite: compositeProp } = parameters; - const elementRef = React14.useRef(null); + const elementRef = React12.useRef(null); const compositeRootContext = useCompositeRootContext(true); const isCompositeItem = compositeProp ?? compositeRootContext !== void 0; const { @@ -1368,7 +1379,7 @@ function useButton(parameters = {}) { isNativeButton }); if (true) { - React14.useEffect(() => { + React12.useEffect(() => { if (!elementRef.current) { return; } @@ -1386,7 +1397,7 @@ function useButton(parameters = {}) { } }, [isNativeButton]); } - const updateDisabled = React14.useCallback(() => { + const updateDisabled = React12.useCallback(() => { const element = elementRef.current; if (!isButtonElement(element)) { return; @@ -1396,7 +1407,7 @@ function useButton(parameters = {}) { } }, [disabled2, focusableWhenDisabledProps.disabled, isCompositeItem]); useIsoLayoutEffect(updateDisabled, [updateDisabled]); - const getButtonProps = React14.useCallback((externalProps = {}) => { + const getButtonProps = React12.useCallback((externalProps = {}) => { const { onClick: externalOnClick, onMouseDown: externalOnMouseDown, @@ -1441,22 +1452,25 @@ function useButton(parameters = {}) { return; } event.preventDefault(); - if (isLink || isNativeButton && isButton) { - currentTarget.click(); - event.preventBaseUIHandler(); - } else if (shouldClick) { - externalOnClick?.(event); + if (!isNativeButton || isButton) { event.preventBaseUIHandler(); + dispatchClickWithModifiers(currentTarget, event); } return; } - if (shouldClick) { - if (!isNativeButton && (isSpaceKey || isEnterKey)) { + if (!shouldClick || isNativeButton || !isSpaceKey && !isEnterKey) { + if (isCurrentTarget && isLink && isSpaceKey) { event.preventDefault(); } - if (!isNativeButton && isEnterKey) { - externalOnClick?.(event); - } + return; + } + if (event.defaultPrevented) { + return; + } + event.preventDefault(); + if (isEnterKey) { + event.preventBaseUIHandler(); + dispatchClickWithModifiers(currentTarget, event); } }, onKeyUp(event) { @@ -1472,8 +1486,9 @@ function useButton(parameters = {}) { if (event.baseUIHandlerPrevented) { return; } - if (event.target === event.currentTarget && !isNativeButton && !isCompositeItem && event.key === " ") { - externalOnClick?.(event); + if (event.target === event.currentTarget && !isNativeButton && !isCompositeItem && !event.defaultPrevented && event.key === " ") { + event.preventBaseUIHandler(); + dispatchClickWithModifiers(event.currentTarget, event); } }, onPointerDown(event) { @@ -1502,7 +1517,7 @@ function isButtonElement(elem) { return isHTMLElement(elem) && elem.tagName === "BUTTON"; } function isValidLinkElement(elem) { - return Boolean(elem?.tagName === "A" && elem?.href); + return isHTMLElement(elem) && elem.tagName === "A" && Boolean(elem.href); } // node_modules/@base-ui/utils/addEventListener.mjs @@ -1531,13 +1546,8 @@ function createLatestRef(value) { return latest; } -// node_modules/@base-ui/utils/owner.mjs -function ownerDocument(node) { - return node?.ownerDocument || document; -} - // node_modules/@base-ui/react/internals/useOpenChangeComplete.mjs -var React15 = __toESM(require_react(), 1); +var React13 = __toESM(require_react(), 1); // node_modules/@base-ui/react/internals/useAnimationsFinished.mjs var ReactDOM = __toESM(require_react_dom(), 1); @@ -1551,7 +1561,7 @@ function resolveRef(maybeRef) { } // node_modules/@base-ui/react/internals/useAnimationsFinished.mjs -function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false, treatAbortedAsFinished = true) { +function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false) { const frame = useAnimationFrame(); return useStableCallback((fnToExecute, signal = null) => { frame.cancel(); @@ -1572,21 +1582,20 @@ function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false if (!signal?.aborted) { done(); } - }).catch(() => { - if (treatAbortedAsFinished) { - if (!signal?.aborted) { - done(); - } + }, () => { + if (signal?.aborted) { return; } const currentAnimations = resolvedElement.getAnimations(); - if (!signal?.aborted && currentAnimations.length > 0 && currentAnimations.some((animation) => animation.pending || animation.playState !== "finished")) { + if (currentAnimations.some((animation) => animation.pending || animation.playState !== "finished")) { exec(); + return; } + done(); }); } if (waitForStartingStyleRemoved) { - const startingStyleAttribute = TransitionStatusDataAttributes.startingStyle; + const startingStyleAttribute = "data-starting-style"; if (!resolvedElement.hasAttribute(startingStyleAttribute)) { frame.request(exec); return; @@ -1619,8 +1628,8 @@ function useOpenChangeComplete(parameters) { onComplete: onCompleteParam } = parameters; const onComplete = useStableCallback(onCompleteParam); - const runOnceAnimationsFinish = useAnimationsFinished(ref, open, false); - React15.useEffect(() => { + const runOnceAnimationsFinish = useAnimationsFinished(ref, open); + React13.useEffect(() => { if (!enabled) { return void 0; } @@ -1632,16 +1641,6 @@ function useOpenChangeComplete(parameters) { }, [enabled, open, onComplete, runOnceAnimationsFinish]); } -// node_modules/@base-ui/utils/useOnFirstRender.mjs -var React16 = __toESM(require_react(), 1); -function useOnFirstRender(fn) { - const ref = React16.useRef(true); - if (ref.current) { - ref.current = false; - fn(); - } -} - // node_modules/@base-ui/utils/platform/parts.mjs var parts_exports = {}; __export(parts_exports, { @@ -1733,29 +1732,29 @@ __export(env_exports, { var jsdom = /jsdom|happydom/.test(lowerUserAgent); // node_modules/@base-ui/utils/useTimeout.mjs -var EMPTY3 = 0; +var EMPTY2 = 0; var Timeout = class _Timeout { static create() { return new _Timeout(); } - currentId = EMPTY3; + currentId = EMPTY2; /** * Executes `fn` after `delay`, clearing any previously scheduled call. */ start(delay, fn) { this.clear(); this.currentId = setTimeout(() => { - this.currentId = EMPTY3; + this.currentId = EMPTY2; fn(); }, delay); } isStarted() { - return this.currentId !== EMPTY3; + return this.currentId !== EMPTY2; } clear = () => { - if (this.currentId !== EMPTY3) { + if (this.currentId !== EMPTY2) { clearTimeout(this.currentId); - this.currentId = EMPTY3; + this.currentId = EMPTY2; } }; disposeEffect = () => { @@ -1769,7 +1768,7 @@ function useTimeout() { } // node_modules/@base-ui/react/floating-ui-react/components/FloatingDelayGroup.mjs -var React17 = __toESM(require_react(), 1); +var React14 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/utils/event.mjs function isReactEvent(event) { @@ -1903,7 +1902,7 @@ function isHoverOpenEvent(openEventType) { // node_modules/@base-ui/react/floating-ui-react/components/FloatingDelayGroup.mjs var import_jsx_runtime = __toESM(require_jsx_runtime(), 1); -var FloatingDelayGroupContext = /* @__PURE__ */ React17.createContext({ +var FloatingDelayGroupContext = /* @__PURE__ */ React14.createContext({ hasProvider: false, timeoutMs: 0, delayRef: { @@ -1930,10 +1929,10 @@ function FloatingDelayGroup(props) { delay, timeoutMs = 0 } = props; - const delayRef = React17.useRef(delay); - const initialDelayRef = React17.useRef(delay); - const currentIdRef = React17.useRef(null); - const currentContextRef = React17.useRef(null); + const delayRef = React14.useRef(delay); + const initialDelayRef = React14.useRef(delay); + const currentIdRef = React14.useRef(null); + const currentContextRef = React14.useRef(null); const timeout = useTimeout(); useIsoLayoutEffect(() => { initialDelayRef.current = delay; @@ -1947,7 +1946,7 @@ function FloatingDelayGroup(props) { }; }, [delay, currentIdRef, delayRef, initialDelayRef]); return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FloatingDelayGroupContext.Provider, { - value: React17.useMemo(() => ({ + value: React14.useMemo(() => ({ hasProvider: true, delayRef, initialDelayRef, @@ -1967,7 +1966,7 @@ function useDelayGroup(context, options = { } = options; const store2 = "rootStore" in context ? context.rootStore : context; const floatingId = store2.useState("floatingId"); - const groupContext = React17.useContext(FloatingDelayGroupContext); + const groupContext = React14.useContext(FloatingDelayGroupContext); const { currentIdRef, delayRef, @@ -1977,22 +1976,13 @@ function useDelayGroup(context, options = { hasProvider, timeout } = groupContext; - const [isInstantPhase, setIsInstantPhase] = React17.useState(false); - const openRef = React17.useRef(open); - const isUnmountedRef = React17.useRef(false); + const [isInstantPhase, setIsInstantPhase] = React14.useState(false); + const openRef = React14.useRef(open); useIsoLayoutEffect(() => { openRef.current = open; }, [open]); - useIsoLayoutEffect(() => { - return () => { - isUnmountedRef.current = true; - }; - }, []); useIsoLayoutEffect(() => { function unset() { - if (!isUnmountedRef.current) { - setIsInstantPhase(false); - } currentContextRef.current?.setIsInstantPhase(false); currentIdRef.current = null; currentContextRef.current = null; @@ -2060,7 +2050,7 @@ function useDelayGroup(context, options = { } }; }, [currentContextRef, currentIdRef, delayRef, floatingId, initialDelayRef, timeout]); - return React17.useMemo(() => ({ + return React14.useMemo(() => ({ hasProvider, delayRef, isInstantPhase @@ -2080,7 +2070,7 @@ function mergeCleanups(...cleanups) { } // node_modules/@base-ui/react/utils/FocusGuard.mjs -var React18 = __toESM(require_react(), 1); +var React15 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/visuallyHidden.mjs var visuallyHiddenBase = { @@ -2106,8 +2096,8 @@ var visuallyHiddenInput = { // node_modules/@base-ui/react/utils/FocusGuard.mjs var import_jsx_runtime2 = __toESM(require_jsx_runtime(), 1); -var FocusGuard = /* @__PURE__ */ React18.forwardRef(function FocusGuard2(props, ref) { - const [role, setRole] = React18.useState(); +var FocusGuard = /* @__PURE__ */ React15.forwardRef(function FocusGuard2(props, ref) { + const [role, setRole] = React15.useState(); useIsoLayoutEffect(() => { if (parts_exports.screenReader.voiceOver && parts_exports.engine.webkit) { setRole("button"); @@ -2130,7 +2120,6 @@ var FocusGuard = /* @__PURE__ */ React18.forwardRef(function FocusGuard2(props, if (true) FocusGuard.displayName = "FocusGuard"; // node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs -var sides = ["top", "right", "bottom", "left"]; var min = Math.min; var max = Math.max; var round = Math.round; @@ -2452,7 +2441,7 @@ function createAttribute(name) { } // node_modules/@base-ui/react/floating-ui-react/components/FloatingPortal.mjs -var React19 = __toESM(require_react(), 1); +var React16 = __toESM(require_react(), 1); var ReactDOM2 = __toESM(require_react_dom(), 1); // node_modules/@base-ui/react/internals/constants.mjs @@ -2477,9 +2466,9 @@ var ownerVisuallyHidden = { // node_modules/@base-ui/react/floating-ui-react/components/FloatingPortal.mjs var import_jsx_runtime3 = __toESM(require_jsx_runtime(), 1); -var PortalContext = /* @__PURE__ */ React19.createContext(null); +var PortalContext = /* @__PURE__ */ React16.createContext(null); if (true) PortalContext.displayName = "PortalContext"; -var usePortalContext = () => React19.useContext(PortalContext); +var usePortalContext = () => React16.useContext(PortalContext); var attr = createAttribute("portal"); function useFloatingPortalNode(props = {}) { const { @@ -2491,14 +2480,14 @@ function useFloatingPortalNode(props = {}) { const uniqueId = useId(); const portalContext = usePortalContext(); const parentPortalNode = portalContext?.portalNode; - const [containerElement, setContainerElement] = React19.useState(null); - const [portalNode, setPortalNode] = React19.useState(null); + const [containerElement, setContainerElement] = React16.useState(null); + const [portalNode, setPortalNode] = React16.useState(null); const setPortalNodeRef = useStableCallback((node) => { if (node !== null) { setPortalNode(node); } }); - const containerRef = React19.useRef(null); + const containerRef = React16.useRef(null); useIsoLayoutEffect(() => { if (containerProp === null) { if (containerRef.current) { @@ -2508,9 +2497,6 @@ function useFloatingPortalNode(props = {}) { } return; } - if (uniqueId == null) { - return; - } const resolvedContainer = (containerProp && (isNode(containerProp) ? containerProp : containerProp.current)) ?? parentPortalNode ?? document.body; if (resolvedContainer == null) { if (containerRef.current) { @@ -2525,7 +2511,7 @@ function useFloatingPortalNode(props = {}) { setPortalNode(null); setContainerElement(resolvedContainer); } - }, [containerProp, parentPortalNode, uniqueId]); + }, [containerProp, parentPortalNode]); const portalElement = useRenderElement("div", componentProps, { ref: [ref, setPortalNodeRef], props: [{ @@ -2535,39 +2521,42 @@ function useFloatingPortalNode(props = {}) { }); const portalSubtree = containerElement && portalElement ? /* @__PURE__ */ ReactDOM2.createPortal(portalElement, containerElement) : null; return { - portalNode, - portalSubtree + node: portalNode, + // `id` and `render` props can override or remove the generated ID. Use the exact + // rendered value so `aria-owns` never points at an ID absent from the DOM. + nodeId: /* @__PURE__ */ React16.isValidElement(portalElement) ? portalElement.props.id : void 0, + subtree: portalSubtree }; } -var FloatingPortal = /* @__PURE__ */ React19.forwardRef(function FloatingPortal2(componentProps, forwardedRef) { +var FloatingPortal = /* @__PURE__ */ React16.forwardRef(function FloatingPortal2(componentProps, forwardedRef) { const { render, className, style, children, container, - renderGuards, ...elementProps } = componentProps; const { - portalNode, - portalSubtree + node: portalNode, + nodeId: portalNodeId, + subtree: portalSubtree } = useFloatingPortalNode({ container, ref: forwardedRef, componentProps, elementProps }); - const beforeOutsideRef = React19.useRef(null); - const afterOutsideRef = React19.useRef(null); - const beforeInsideRef = React19.useRef(null); - const afterInsideRef = React19.useRef(null); - const [focusManagerState, setFocusManagerState] = React19.useState(null); - const focusInsideDisabledRef = React19.useRef(false); + const beforeOutsideRef = React16.useRef(null); + const afterOutsideRef = React16.useRef(null); + const beforeInsideRef = React16.useRef(null); + const afterInsideRef = React16.useRef(null); + const [focusManagerState, setFocusManagerState] = React16.useState(null); + const focusInsideDisabledRef = React16.useRef(false); const modal = focusManagerState?.modal; const open = focusManagerState?.open; - const shouldRenderGuards = typeof renderGuards === "boolean" ? renderGuards : !!focusManagerState && !focusManagerState.modal && focusManagerState.open && !!portalNode; - React19.useEffect(() => { + const shouldRenderGuards = !!focusManagerState && !focusManagerState.modal && focusManagerState.open && !!portalNode; + React16.useEffect(() => { if (!portalNode || modal) { return void 0; } @@ -2593,7 +2582,7 @@ var FloatingPortal = /* @__PURE__ */ React19.forwardRef(function FloatingPortal2 enableFocusInside(portalNode); focusInsideDisabledRef.current = false; }, [open, portalNode]); - const portalContextValue = React19.useMemo(() => ({ + const portalContextValue = React16.useMemo(() => ({ beforeOutsideRef, afterOutsideRef, beforeInsideRef, @@ -2601,7 +2590,7 @@ var FloatingPortal = /* @__PURE__ */ React19.forwardRef(function FloatingPortal2 portalNode, setFocusManagerState }), [portalNode]); - return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(React19.Fragment, { + return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(React16.Fragment, { children: [portalSubtree, /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(PortalContext.Provider, { value: portalContextValue, children: [shouldRenderGuards && portalNode && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(FocusGuard, { @@ -2617,7 +2606,7 @@ var FloatingPortal = /* @__PURE__ */ React19.forwardRef(function FloatingPortal2 } } }), shouldRenderGuards && portalNode && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { - "aria-owns": portalNode.id, + "aria-owns": portalNodeId, style: ownerVisuallyHidden }), portalNode && /* @__PURE__ */ ReactDOM2.createPortal(children, portalNode), shouldRenderGuards && portalNode && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(FocusGuard, { "data-type": "outside", @@ -2641,7 +2630,7 @@ var FloatingPortal = /* @__PURE__ */ React19.forwardRef(function FloatingPortal2 if (true) FloatingPortal.displayName = "FloatingPortal"; // node_modules/@base-ui/react/floating-ui-react/components/FloatingTree.mjs -var React20 = __toESM(require_react(), 1); +var React17 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/utils/createEventEmitter.mjs function createEventEmitter() { @@ -2664,18 +2653,18 @@ function createEventEmitter() { // node_modules/@base-ui/react/floating-ui-react/components/FloatingTree.mjs var import_jsx_runtime4 = __toESM(require_jsx_runtime(), 1); -var FloatingNodeContext = /* @__PURE__ */ React20.createContext(null); +var FloatingNodeContext = /* @__PURE__ */ React17.createContext(null); if (true) FloatingNodeContext.displayName = "FloatingNodeContext"; -var FloatingTreeContext = /* @__PURE__ */ React20.createContext(null); +var FloatingTreeContext = /* @__PURE__ */ React17.createContext(null); if (true) FloatingTreeContext.displayName = "FloatingTreeContext"; -var useFloatingParentNodeId = () => React20.useContext(FloatingNodeContext)?.id || null; +var useFloatingParentNodeId = () => React17.useContext(FloatingNodeContext)?.id || null; var useFloatingTree = (externalTree) => { - const contextTree = React20.useContext(FloatingTreeContext); + const contextTree = React17.useContext(FloatingTreeContext); return externalTree ?? contextTree; }; // node_modules/@base-ui/react/floating-ui-react/hooks/useClientPoint.mjs -var React21 = __toESM(require_react(), 1); +var React18 = __toESM(require_react(), 1); function createVirtualElement(domElement, data) { let offsetX = null; let offsetY = null; @@ -2742,10 +2731,10 @@ function useClientPoint(context, props = {}) { const floating = store2.useState("floatingElement"); const domReference = store2.useState("domReferenceElement"); const dataRef = store2.context.dataRef; - const initialRef = React21.useRef(false); - const cleanupListenerRef = React21.useRef(null); - const [pointerType, setPointerType] = React21.useState(); - const [reactive, setReactive] = React21.useState([]); + const initialRef = React18.useRef(false); + const cleanupListenerRef = React18.useRef(null); + const [pointerType, setPointerType] = React18.useState(); + const [reactive, setReactive] = React18.useState([]); const resetReference = useStableCallback((reference2) => { store2.set("positionReference", reference2); }); @@ -2773,7 +2762,7 @@ function useClientPoint(context, props = {}) { } }); const openCheck = isMouseLikePointerType(pointerType) ? floating : open; - React21.useEffect(() => { + React18.useEffect(() => { if (!enabled) { resetReference(domReference); return void 0; @@ -2801,20 +2790,20 @@ function useClientPoint(context, props = {}) { } return cleanupListener; }, [openCheck, enabled, floating, dataRef, domReference, store2, setReference, resetReference, reactive]); - React21.useEffect(() => () => { + React18.useEffect(() => () => { store2.set("positionReference", null); }, [store2]); - React21.useEffect(() => { + React18.useEffect(() => { if (enabled && !floating) { initialRef.current = false; } }, [enabled, floating]); - React21.useEffect(() => { + React18.useEffect(() => { if (!enabled && open) { initialRef.current = true; } }, [enabled, open]); - const reference = React21.useMemo(() => { + const reference = React18.useMemo(() => { function setPointerTypeRef(event) { setPointerType(event.pointerType); } @@ -2825,14 +2814,14 @@ function useClientPoint(context, props = {}) { onMouseEnter: handleReferenceEnterOrMove }; }, [handleReferenceEnterOrMove]); - return React21.useMemo(() => enabled ? { + return React18.useMemo(() => enabled ? { reference, trigger: reference } : {}, [enabled, reference]); } // node_modules/@base-ui/react/floating-ui-react/hooks/useDismiss.mjs -var React22 = __toESM(require_react(), 1); +var React19 = __toESM(require_react(), 1); function alwaysFalse() { return false; } @@ -2867,12 +2856,12 @@ function useDismiss(context, props = {}) { escapeKey: escapeKeyBubbles, outsidePress: outsidePressBubbles } = normalizeProp(bubbles); - const pressStartedInsideRef = React22.useRef(false); - const pressStartPreventedRef = React22.useRef(false); - const suppressNextOutsideClickRef = React22.useRef(false); - const isComposingRef = React22.useRef(false); - const currentPointerTypeRef = React22.useRef(""); - const touchStateRef = React22.useRef(null); + const pressStartedInsideRef = React19.useRef(false); + const pressStartPreventedRef = React19.useRef(false); + const suppressNextOutsideClickRef = React19.useRef(false); + const isComposingRef = React19.useRef(false); + const currentPointerTypeRef = React19.useRef(""); + const touchStateRef = React19.useRef(null); const cancelDismissOnEndTimeout = useTimeout(); const clearInsideReactTreeTimeout = useTimeout(); const clearInsideReactTree = useStableCallback(() => { @@ -2941,9 +2930,9 @@ function useDismiss(context, props = {}) { pressStartPreventedRef.current = true; } }); - React22.useEffect(() => { + React19.useEffect(() => { if (!open || !enabled) { - return void 0; + return clearInsideReactTree; } dataRef.current.__escapeKeyBubbles = escapeKeyBubbles; dataRef.current.__outsidePressBubbles = outsidePressBubbles; @@ -3189,15 +3178,15 @@ function useDismiss(context, props = {}) { preventedPressSuppressionTimeout.clear(); resetPressStartState(); suppressNextOutsideClickRef.current = false; + clearInsideReactTree(); }; }, [dataRef, floatingElement, escapeKey2, outsidePressEnabled, outsidePress2, open, enabled, escapeKeyBubbles, outsidePressBubbles, closeOnEscapeKeyDown, clearInsideReactTree, getOutsidePressEventProp, hasBlockingChild, isEventWithinOwnElements, tree, store2, cancelDismissOnEndTimeout]); - React22.useEffect(clearInsideReactTree, [outsidePress2, clearInsideReactTree]); - const reference = React22.useMemo(() => ({ + const reference = React19.useMemo(() => ({ onKeyDown: closeOnEscapeKeyDown, onPointerDown: closeOnReferencePress, onClick: closeOnReferencePress }), [closeOnEscapeKeyDown, closeOnReferencePress]); - const floating = React22.useMemo(() => ({ + const floating = React19.useMemo(() => ({ onKeyDown: closeOnEscapeKeyDown, // `onMouseDown` may be blocked if `event.preventDefault()` is called in // `onPointerDown`, such as with . @@ -3217,7 +3206,7 @@ function useDismiss(context, props = {}) { onTouchEndCapture: markInsideReactTree, onTouchMoveCapture: markInsideReactTree }), [closeOnEscapeKeyDown, markInsideReactTree, markPressStartedInsideReactTree, markInsidePressStartPrevented]); - return React22.useMemo(() => enabled ? { + return React19.useMemo(() => enabled ? { reference, floating, trigger: reference @@ -3225,7 +3214,7 @@ function useDismiss(context, props = {}) { } // node_modules/@base-ui/react/floating-ui-react/hooks/useFloating.mjs -var React29 = __toESM(require_react(), 1); +var React27 = __toESM(require_react(), 1); // node_modules/@floating-ui/core/dist/floating-ui.core.mjs function computeCoordsFromPlacement(_ref, placement, rtl) { @@ -3529,67 +3518,6 @@ var flip = function(options) { } }; }; -function getSideOffsets(overflow, rect) { - return { - top: overflow.top - rect.height, - right: overflow.right - rect.width, - bottom: overflow.bottom - rect.height, - left: overflow.left - rect.width - }; -} -function isAnySideFullyClipped(overflow) { - return sides.some((side) => overflow[side] >= 0); -} -var hide = function(options) { - if (options === void 0) { - options = {}; - } - return { - name: "hide", - options, - async fn(state) { - const { - rects, - platform: platform3 - } = state; - const { - strategy = "referenceHidden", - ...detectOverflowOptions - } = evaluate(options, state); - switch (strategy) { - case "referenceHidden": { - const overflow = await platform3.detectOverflow(state, { - ...detectOverflowOptions, - elementContext: "reference" - }); - const offsets = getSideOffsets(overflow, rects.reference); - return { - data: { - referenceHiddenOffsets: offsets, - referenceHidden: isAnySideFullyClipped(offsets) - } - }; - } - case "escaped": { - const overflow = await platform3.detectOverflow(state, { - ...detectOverflowOptions, - altBoundary: true - }); - const offsets = getSideOffsets(overflow, rects.floating); - return { - data: { - escapedOffsets: offsets, - escaped: isAnySideFullyClipped(offsets) - } - }; - } - default: { - return {}; - } - } - } - }; -}; var originSides = /* @__PURE__ */ new Set(["left", "top"]); async function convertValueToCoords(state, options) { const { @@ -4456,7 +4384,6 @@ var offset2 = offset; var shift2 = shift; var flip2 = flip; var size2 = size; -var hide2 = hide; var limitShift2 = limitShift; var computePosition2 = (reference, floating, options) => { const cache = /* @__PURE__ */ new Map(); @@ -4473,7 +4400,7 @@ var computePosition2 = (reference, floating, options) => { }; // node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs -var React23 = __toESM(require_react(), 1); +var React20 = __toESM(require_react(), 1); var import_react2 = __toESM(require_react(), 1); var ReactDOM3 = __toESM(require_react_dom(), 1); var isClient = typeof document !== "undefined"; @@ -4539,7 +4466,7 @@ function roundByDPR(element, value) { return Math.round(value * dpr) / dpr; } function useLatestRef(value) { - const ref = React23.useRef(value); + const ref = React20.useRef(value); index(() => { ref.current = value; }); @@ -4562,7 +4489,7 @@ function useFloating(options) { whileElementsMounted, open } = options; - const [data, setData] = React23.useState({ + const [data, setData] = React20.useState({ x: 0, y: 0, strategy, @@ -4570,19 +4497,19 @@ function useFloating(options) { middlewareData: {}, isPositioned: false }); - const [latestMiddleware, setLatestMiddleware] = React23.useState(middleware); + const [latestMiddleware, setLatestMiddleware] = React20.useState(middleware); if (!deepEqual(latestMiddleware, middleware)) { setLatestMiddleware(middleware); } - const [_reference, _setReference] = React23.useState(null); - const [_floating, _setFloating] = React23.useState(null); - const setReference = React23.useCallback((node) => { + const [_reference, _setReference] = React20.useState(null); + const [_floating, _setFloating] = React20.useState(null); + const setReference = React20.useCallback((node) => { if (node !== referenceRef.current) { referenceRef.current = node; _setReference(node); } }, []); - const setFloating = React23.useCallback((node) => { + const setFloating = React20.useCallback((node) => { if (node !== floatingRef.current) { floatingRef.current = node; _setFloating(node); @@ -4590,14 +4517,14 @@ function useFloating(options) { }, []); const referenceEl = externalReference || _reference; const floatingEl = externalFloating || _floating; - const referenceRef = React23.useRef(null); - const floatingRef = React23.useRef(null); - const dataRef = React23.useRef(data); + const referenceRef = React20.useRef(null); + const floatingRef = React20.useRef(null); + const dataRef = React20.useRef(data); const hasWhileElementsMounted = whileElementsMounted != null; const whileElementsMountedRef = useLatestRef(whileElementsMounted); const platformRef = useLatestRef(platform3); const openRef = useLatestRef(open); - const update2 = React23.useCallback(() => { + const update2 = React20.useCallback(() => { if (!referenceRef.current || !floatingRef.current) { return; } @@ -4635,7 +4562,7 @@ function useFloating(options) { })); } }, [open]); - const isMountedRef = React23.useRef(false); + const isMountedRef = React20.useRef(false); index(() => { isMountedRef.current = true; return () => { @@ -4652,17 +4579,17 @@ function useFloating(options) { update2(); } }, [referenceEl, floatingEl, update2, whileElementsMountedRef, hasWhileElementsMounted]); - const refs = React23.useMemo(() => ({ + const refs = React20.useMemo(() => ({ reference: referenceRef, floating: floatingRef, setReference, setFloating }), [setReference, setFloating]); - const elements = React23.useMemo(() => ({ + const elements = React20.useMemo(() => ({ reference: referenceEl, floating: floatingEl }), [referenceEl, floatingEl]); - const floatingStyles = React23.useMemo(() => { + const floatingStyles = React20.useMemo(() => { const initialStyles = { position: strategy, left: 0, @@ -4688,7 +4615,7 @@ function useFloating(options) { top: y }; }, [strategy, transform, elements.floating, data.x, data.y]); - return React23.useMemo(() => ({ + return React20.useMemo(() => ({ ...data, update: update2, refs, @@ -4735,81 +4662,182 @@ var size3 = (options, deps) => { options: [options, deps] }; }; -var hide3 = (options, deps) => { - const result = hide2(options); - return { - name: result.name, - fn: result.fn, - options: [options, deps] - }; + +// node_modules/@base-ui/react/utils/popups/popupHandle.mjs +var BasePopupHandle = class { + /** + * Stores of every root currently using this handle, in attach order. A handle is meant to be used + * by a single mounted root, but roots can transiently overlap (e.g. during an animated route + * transition), so this stack lets `attachStore`'s cleanup restore the previous root instead of + * leaving a still-mounted root uncontrollable when a newer overlapping root detaches first. + */ + attachedStores = []; + /** + * Store of the root that currently controls the handle: the most recently attached one still + * mounted, or `null` when no root is attached. Imperative methods are no-ops while this is `null`. + */ + attachedStoreValue = null; + /** + * Listeners notified when `attachedStore` changes, so detached triggers can follow the store pointer. + */ + storeListeners = /* @__PURE__ */ new Set(); + /** + * Creates a handle backed by the store used while no root is attached. + * + * @param fallbackStore Inert, closed store handed to detached triggers while no root is attached, + * so they can render and register without a mounted root. Triggers register into whichever store + * `store` currently resolves to, so while detached they live in this store's trigger map and + * migrate themselves to the root's store (and back) as it attaches/detaches. + * @param componentName Component name used to prefix dev warnings, e.g. `'Menu'` produces + * `MenuHandle.open()` in warning text. + * @param throwOnMissingTrigger Whether `open(triggerId)` throws when no trigger with that id is + * registered. Anchored popups (Menu, Popover, Tooltip, PreviewCard) need a trigger to anchor to, + * so they throw; Dialog is not anchored and instead opens unassociated with a dev warning. + */ + constructor(fallbackStore, componentName, throwOnMissingTrigger = true) { + this.fallbackStore = fallbackStore; + this.componentName = componentName; + this.throwOnMissingTrigger = throwOnMissingTrigger; + } + get attachedStore() { + return this.attachedStoreValue; + } + /** + * Store that detached triggers read from: the attached root's store, or an inert fallback store + * used while no root is attached. + * @internal + */ + get store() { + return this.attachedStoreValue ?? this.fallbackStore; + } + /** + * Stable fallback store used for server rendering and hydration. Root stores cannot be recorded on + * the handle during render because a handle can be shared by concurrent server-rendered requests. + * @internal + */ + get serverStore() { + return this.fallbackStore; + } + /** + * Subscribes to changes of the attached store pointer so detached triggers re-render and re-bind + * when a root attaches or detaches. Returns a function that removes the listener. + * @internal + */ + subscribeStore(listener) { + this.storeListeners.add(listener); + return () => { + this.storeListeners.delete(listener); + }; + } + /** + * Points the handle at a root's store and notifies subscribers so detached triggers re-render and + * re-register into it (their registration ref re-fires on the store-pointer change). Returns a + * cleanup function that detaches the store again. + * @internal + */ + attachStore(newStore) { + this.attachedStores.push(newStore); + this.setActiveStore(newStore); + if (true) { + if (this.attachedStores.length > 1) { + const dev = this; + (dev.overlapWarningFrame ??= AnimationFrame.create()).request(() => { + if (this.attachedStores.length > 1) { + console.warn("Base UI: A handle is attached to more than one mounted root at the same time. The most recently mounted root takes over and the previous one stops being controlled by the handle. A handle should be used by a single root that stays mounted for the lifetime of the handle."); + } + }); + } + } + return () => { + const index2 = this.attachedStores.lastIndexOf(newStore); + if (index2 !== -1) { + this.attachedStores.splice(index2, 1); + } + this.setActiveStore(this.attachedStores[this.attachedStores.length - 1] ?? null); + }; + } + /** + * Sets the store that currently controls the handle and notifies subscribers when it changes, so + * detached triggers re-render and migrate their registration to the new store. + */ + setActiveStore(store2) { + if (this.attachedStoreValue !== store2) { + this.attachedStoreValue = store2; + this.storeListeners.forEach((listener) => { + listener(); + }); + } + } + /** + * Opens the attached root's store and associates it with the trigger with the given id, or a + * no-op (with a dev warning) while no root is attached. Shared by every concrete handle's public + * `open()` method, which only narrows the parameter type. + * + * When a trigger id is given but no matching trigger is registered, anchored popups throw (see + * `throwOnMissingTrigger`); Dialog opens unassociated with a dev warning instead. + * + * This method should only be called in an event handler or an effect (not during rendering). + * + * @param triggerId ID of the trigger to associate with the popup, or `null`/`undefined` to open + * without associating any trigger. + */ + openByTrigger(triggerId) { + const attachedStore = this.attachedStore; + if (attachedStore === null) { + if (true) { + console.warn(`Base UI: ${this.componentName}Handle.open() was called while no root using this handle is mounted. The call was ignored; mount a root with this handle before opening it imperatively.`); + } + return; + } + let triggerElement; + if (triggerId) { + for (let i = this.attachedStores.length - 1; i >= 0 && !triggerElement; i -= 1) { + triggerElement = this.attachedStores[i].context.triggerElements.getById(triggerId); + } + triggerElement ??= this.fallbackStore.context.triggerElements.getById(triggerId); + } + if (triggerId && !triggerElement) { + if (this.throwOnMissingTrigger) { + throw new Error(true ? `Base UI: ${this.componentName}Handle.open() was called with the trigger id "${triggerId}", but no matching trigger is registered with this handle. An anchored popup cannot open without a trigger to anchor to. Pass the id of a mounted ${this.componentName}.Trigger that has this handle set on its "handle" prop.` : formatErrorMessage_default(99, this.componentName, triggerId, this.componentName)); + } + if (true) { + console.warn(`Base UI: ${this.componentName}Handle.open: No trigger found with id "${triggerId}". The popup will open, but the trigger will not be associated with it.`); + } + } + attachedStore.setOpen(true, createChangeEventDetails(reason_parts_exports.imperativeAction, void 0, triggerElement)); + } + /** + * Closes the popup by setting the attached root's store to closed, or a no-op (with a dev warning) + * while no root is attached. Shared by every concrete handle's public `close()` method. + * + * This method should only be called in an event handler or an effect (not during rendering). + */ + closePopup() { + const attachedStore = this.attachedStore; + if (attachedStore === null) { + if (true) { + console.warn(`Base UI: ${this.componentName}Handle.close() was called while no root using this handle is mounted. The call was ignored.`); + } + return; + } + attachedStore.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction)); + } }; // node_modules/@base-ui/react/utils/popups/popupStoreUtils.mjs -var React28 = __toESM(require_react(), 1); +var React25 = __toESM(require_react(), 1); var ReactDOM4 = __toESM(require_react_dom(), 1); // node_modules/@base-ui/react/floating-ui-react/hooks/useSyncedFloatingRootContext.mjs -var React27 = __toESM(require_react(), 1); - -// node_modules/@base-ui/utils/store/createSelector.mjs -var createSelector = (a, b, c, d, e, f, ...other) => { - if (other.length > 0) { - throw new Error(true ? "Unsupported number of selectors" : formatErrorMessage_default(1)); - } - let selector; - if (a && b && c && d && e && f) { - selector = (state, a1, a2, a3) => { - const va = a(state, a1, a2, a3); - const vb = b(state, a1, a2, a3); - const vc = c(state, a1, a2, a3); - const vd = d(state, a1, a2, a3); - const ve = e(state, a1, a2, a3); - return f(va, vb, vc, vd, ve, a1, a2, a3); - }; - } else if (a && b && c && d && e) { - selector = (state, a1, a2, a3) => { - const va = a(state, a1, a2, a3); - const vb = b(state, a1, a2, a3); - const vc = c(state, a1, a2, a3); - const vd = d(state, a1, a2, a3); - return e(va, vb, vc, vd, a1, a2, a3); - }; - } else if (a && b && c && d) { - selector = (state, a1, a2, a3) => { - const va = a(state, a1, a2, a3); - const vb = b(state, a1, a2, a3); - const vc = c(state, a1, a2, a3); - return d(va, vb, vc, a1, a2, a3); - }; - } else if (a && b && c) { - selector = (state, a1, a2, a3) => { - const va = a(state, a1, a2, a3); - const vb = b(state, a1, a2, a3); - return c(va, vb, a1, a2, a3); - }; - } else if (a && b) { - selector = (state, a1, a2, a3) => { - const va = a(state, a1, a2, a3); - return b(va, a1, a2, a3); - }; - } else if (a) { - selector = a; - } else { - throw ( - /* minify-error-disabled */ - new Error("Missing arguments") - ); - } - return selector; -}; +var React24 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/store/useStore.mjs -var React25 = __toESM(require_react(), 1); +var React22 = __toESM(require_react(), 1); var import_shim = __toESM(require_shim(), 1); var import_with_selector = __toESM(require_with_selector(), 1); // node_modules/@base-ui/utils/fastHooks.mjs -var React24 = __toESM(require_react(), 1); +var React21 = __toESM(require_react(), 1); var hooks = []; var currentInstance = void 0; function getInstance() { @@ -4841,7 +4869,7 @@ function fastComponent(fn) { return FastComponent; } function fastComponentRef(fn) { - return /* @__PURE__ */ React24.forwardRef(fastComponent(fn)); + return /* @__PURE__ */ React21.forwardRef(fastComponent(fn)); } function createInstance() { return { @@ -4856,7 +4884,7 @@ function useStore(store2, selector, a1, a2, a3) { return useStoreImplementation(store2, selector, a1, a2, a3); } function useStoreR19(store2, selector, a1, a2, a3) { - const getSelection = React25.useCallback(() => selector(store2.getSnapshot(), a1, a2, a3), [store2, selector, a1, a2, a3]); + const getSelection = React22.useCallback(() => selector(store2.getSnapshot(), a1, a2, a3), [store2, selector, a1, a2, a3]); return (0, import_shim.useSyncExternalStore)(store2.subscribe, getSelection, getSelection); } register({ @@ -5043,7 +5071,7 @@ var Store = class { }; // node_modules/@base-ui/utils/store/ReactStore.mjs -var React26 = __toESM(require_react(), 1); +var React23 = __toESM(require_react(), 1); var ReactStore = class extends Store { /** * Creates a new ReactStore instance. @@ -5067,7 +5095,7 @@ var ReactStore = class extends Store { * by `useState` is updated before the next render (similarly to React's `useState`). */ useSyncedValue(key, value) { - React26.useDebugValue(key); + React23.useDebugValue(key); const store2 = this; useIsoLayoutEffect(() => { if (store2.state[key] !== value) { @@ -5102,8 +5130,8 @@ var ReactStore = class extends Store { useSyncedValues(statePart) { const store2 = this; if (true) { - React26.useDebugValue(statePart, (p) => Object.keys(p)); - const keys = React26.useRef(Object.keys(statePart)).current; + React23.useDebugValue(statePart, (p) => Object.keys(p)); + const keys = React23.useRef(Object.keys(statePart)).current; const nextKeys = Object.keys(statePart); if (keys.length !== nextKeys.length || keys.some((key, index2) => key !== nextKeys[index2])) { console.error("ReactStore.useSyncedValues expects the same prop keys on every render. Keys should be stable."); @@ -5119,7 +5147,7 @@ var ReactStore = class extends Store { * is non-undefined, the store's state at `key` is updated to match `controlled`. */ useControlledProp(key, controlled) { - React26.useDebugValue(key); + React23.useDebugValue(key); const store2 = this; const isControlled = controlled !== void 0; useIsoLayoutEffect(() => { @@ -5157,7 +5185,7 @@ var ReactStore = class extends Store { * @param key Key of the selector to use. */ useState(key, a1, a2, a3) { - React26.useDebugValue(key); + React23.useDebugValue(key); return useStore(this, this.selectors[key], a1, a2, a3); } /** @@ -5168,7 +5196,7 @@ var ReactStore = class extends Store { * @param fn Function to assign. */ useContextCallback(key, fn) { - React26.useDebugValue(key); + React23.useDebugValue(key); const stableFunction = useStableCallback(fn ?? NOOP); this.context[key] = stableFunction; } @@ -5179,7 +5207,7 @@ var ReactStore = class extends Store { * @param key Key of the state to set. */ useStateSetter(key) { - const ref = React26.useRef(void 0); + const ref = React23.useRef(void 0); if (ref.current === void 0) { ref.current = (value) => { this.set(key, value); @@ -5215,12 +5243,12 @@ var ReactStore = class extends Store { // node_modules/@base-ui/react/floating-ui-react/components/FloatingRootStore.mjs var selectors = { - open: createSelector((state) => state.open), - transitionStatus: createSelector((state) => state.transitionStatus), - domReferenceElement: createSelector((state) => state.domReferenceElement), - referenceElement: createSelector((state) => state.positionReference ?? state.referenceElement), - floatingElement: createSelector((state) => state.floatingElement), - floatingId: createSelector((state) => state.floatingId) + open: (state) => state.open, + transitionStatus: (state) => state.transitionStatus, + domReferenceElement: (state) => state.domReferenceElement, + referenceElement: (state) => state.positionReference ?? state.referenceElement, + floatingElement: (state) => state.floatingElement, + floatingId: (state) => state.floatingId }; var FloatingRootStore = class extends ReactStore { constructor(options) { @@ -5301,7 +5329,7 @@ function useSyncedFloatingRootContext(options) { const floatingElement = popupStore.useState(treatPopupAsFloatingElement ? "popupElement" : "positionerElement"); const triggerElements = popupStore.context.triggerElements; const handleOpenChange = onOpenChange; - const internalStoreRef = React27.useRef(null); + const internalStoreRef = React24.useRef(null); if (floatingRootContextProp === void 0 && internalStoreRef.current === null) { internalStoreRef.current = new FloatingRootStore({ open, @@ -5342,14 +5370,10 @@ var FOCUSABLE_POPUP_PROPS = { tabIndex: -1, [FOCUSABLE_ATTRIBUTE]: "" }; -function usePopupStore(externalStore, createStore, treatPopupAsFloatingElement = false) { +function usePopupRootStore(createStore, treatPopupAsFloatingElement = false) { const floatingId = useId(); const nested = useFloatingParentNodeId() != null; - const internalStoreRef = React28.useRef(null); - if (externalStore === void 0 && internalStoreRef.current === null) { - internalStoreRef.current = createStore(floatingId, nested); - } - const store2 = externalStore ?? internalStoreRef.current; + const store2 = useRefWithInit(() => createStore(floatingId, nested)).current; useSyncedFloatingRootContext({ popupStore: store2, treatPopupAsFloatingElement, @@ -5358,15 +5382,21 @@ function usePopupStore(externalStore, createStore, treatPopupAsFloatingElement = nested, onOpenChange: store2.setOpen }); - return { - store: store2, - internalStore: internalStoreRef.current - }; + return store2; +} +function PopupHandleAttachment({ + handle, + store: store2 +}) { + useIsoLayoutEffect(() => { + return handle.attachStore(store2); + }, [handle, store2]); + return null; } function useTriggerRegistration(id, store2) { - const registeredElementIdRef = React28.useRef(null); - const registeredElementRef = React28.useRef(null); - return React28.useCallback((element) => { + const registeredElementIdRef = React25.useRef(null); + const registeredElementRef = React25.useRef(null); + return React25.useCallback((element) => { if (id === void 0) { return; } @@ -5448,26 +5478,10 @@ function applyPopupOpenChange(store2, nextOpen, eventDetails, options = {}) { changeState(); } } -function useInitialOpenSync(store2, openProp, defaultOpen, defaultTriggerId) { - useOnFirstRender(() => { - if (openProp === void 0 && store2.state.open === false && defaultOpen) { - store2.state = { - ...store2.state, - open: true, - activeTriggerId: defaultTriggerId, - preventUnmountingOnClose: false - }; - } - }); -} function useTriggerDataForwarding(triggerId, triggerElementRef, store2, stateUpdates) { const isMountedByThisTrigger = store2.useState("isMountedByTrigger", triggerId); const baseRegisterTrigger = useTriggerRegistration(triggerId, store2); - const registerTrigger = useStableCallback((element) => { - baseRegisterTrigger(element); - if (!element) { - return; - } + const applyTriggerData = useStableCallback((element) => { const open = store2.select("open"); const activeTriggerId = store2.select("activeTriggerId"); if (activeTriggerId === triggerId) { @@ -5485,6 +5499,12 @@ function useTriggerDataForwarding(triggerId, triggerElementRef, store2, stateUpd }); } }); + const registerTrigger = React25.useCallback((element) => { + baseRegisterTrigger(element); + if (element) { + applyTriggerData(element); + } + }, [baseRegisterTrigger, applyTriggerData]); useIsoLayoutEffect(() => { if (isMountedByThisTrigger) { store2.update({ @@ -5502,10 +5522,14 @@ function useImplicitActiveTrigger(store2, options = {}) { const { closeOnActiveTriggerUnmount = false } = options; + const resolvedActiveTriggerIdRef = React25.useRef(null); const open = store2.useState("open"); const reactiveTriggerCount = store2.useState("triggerCount"); + const activeTriggerId = store2.useState("activeTriggerId"); + const reactiveActiveTriggerElement = store2.useState("activeTriggerElement"); useIsoLayoutEffect(() => { if (!open) { + resolvedActiveTriggerIdRef.current = null; if (store2.state.triggerCount !== 0) { store2.set("triggerCount", 0); } @@ -5516,22 +5540,42 @@ function useImplicitActiveTrigger(store2, options = {}) { if (store2.state.triggerCount !== triggerCount) { stateUpdates.triggerCount = triggerCount; } - const activeTriggerId = store2.select("activeTriggerId"); + const currentActiveTriggerId = store2.select("activeTriggerId"); let lostActiveTriggerId = null; - if (activeTriggerId) { - const activeTriggerElement = store2.context.triggerElements.getById(activeTriggerId); + if (currentActiveTriggerId) { + const activeTriggerElement = store2.context.triggerElements.getById(currentActiveTriggerId); if (!activeTriggerElement) { - lostActiveTriggerId = activeTriggerId; - } else if (activeTriggerElement !== store2.state.activeTriggerElement) { - stateUpdates.activeTriggerElement = activeTriggerElement; - } - } - if (!lostActiveTriggerId && !activeTriggerId && triggerCount === 1) { - const iteratorResult = store2.context.triggerElements.entries().next(); - if (!iteratorResult.done) { + for (const [triggerId, triggerElement] of store2.context.triggerElements.entries()) { + if (triggerElement === store2.state.activeTriggerElement) { + stateUpdates.activeTriggerId = triggerId; + stateUpdates.activeTriggerElement = triggerElement; + resolvedActiveTriggerIdRef.current = triggerId; + break; + } + } + if (stateUpdates.activeTriggerId === void 0) { + if (resolvedActiveTriggerIdRef.current === currentActiveTriggerId) { + lostActiveTriggerId = currentActiveTriggerId; + } else { + resolvedActiveTriggerIdRef.current = null; + } + } + } else { + resolvedActiveTriggerIdRef.current = currentActiveTriggerId; + if (activeTriggerElement !== store2.state.activeTriggerElement) { + stateUpdates.activeTriggerElement = activeTriggerElement; + } + } + } else { + resolvedActiveTriggerIdRef.current = null; + } + if (!lostActiveTriggerId && !currentActiveTriggerId && triggerCount === 1) { + const iteratorResult = store2.context.triggerElements.entries().next(); + if (!iteratorResult.done) { const [implicitTriggerId, implicitTriggerElement] = iteratorResult.value; stateUpdates.activeTriggerId = implicitTriggerId; stateUpdates.activeTriggerElement = implicitTriggerElement; + resolvedActiveTriggerIdRef.current = implicitTriggerId; } } if (stateUpdates.triggerCount !== void 0 || stateUpdates.activeTriggerId !== void 0 || stateUpdates.activeTriggerElement !== void 0) { @@ -5553,7 +5597,7 @@ function useImplicitActiveTrigger(store2, options = {}) { }); } } - }, [open, store2, reactiveTriggerCount, closeOnActiveTriggerUnmount]); + }, [open, store2, reactiveTriggerCount, activeTriggerId, reactiveActiveTriggerElement, closeOnActiveTriggerUnmount]); } function useOpenStateTransitions(open, store2, onUnmount) { const { @@ -5606,9 +5650,18 @@ function usePopupInteractionProps(store2, statePart) { } // node_modules/@base-ui/react/utils/popups/popupTriggerMap.mjs +var devElementIdsByMap; +function getDevElementIds(map) { + devElementIdsByMap ??= /* @__PURE__ */ new WeakMap(); + let elementIds = devElementIdsByMap.get(map); + if (!elementIds) { + elementIds = /* @__PURE__ */ new WeakMap(); + devElementIdsByMap.set(map, elementIds); + } + return elementIds; +} var PopupTriggerMap = class { constructor() { - this.elementsSet = /* @__PURE__ */ new Set(); this.idMap = /* @__PURE__ */ new Map(); } /** @@ -5617,42 +5670,48 @@ var PopupTriggerMap = class { * Note: The provided element is assumed to not be registered under multiple IDs. */ add(id, element) { - const existingElement = this.idMap.get(id); - if (existingElement === element) { - return; - } - if (existingElement !== void 0) { - this.elementsSet.delete(existingElement); - } - this.elementsSet.add(element); - this.idMap.set(id, element); if (true) { - if (this.elementsSet.size !== this.idMap.size) { + const elementIds = getDevElementIds(this); + const existingId = elementIds.get(element); + if (existingId !== void 0 && existingId !== id) { throw new Error("Base UI: A trigger element cannot be registered under multiple IDs in PopupTriggerMap."); } + const previousElement = this.idMap.get(id); + if (previousElement !== void 0 && previousElement !== element) { + elementIds.delete(previousElement); + } + elementIds.set(element, id); } + this.idMap.set(id, element); } /** * Removes the trigger element with the given ID. */ delete(id) { - const element = this.idMap.get(id); - if (element) { - this.elementsSet.delete(element); - this.idMap.delete(id); + if (true) { + const element = this.idMap.get(id); + if (element !== void 0) { + devElementIdsByMap?.get(this)?.delete(element); + } } + this.idMap.delete(id); } /** * Whether the given element is registered as a trigger. */ hasElement(element) { - return this.elementsSet.has(element); + for (const registered of this.idMap.values()) { + if (registered === element) { + return true; + } + } + return false; } /** * Whether there is a registered trigger element matching the given predicate. */ hasMatchingElement(predicate) { - for (const element of this.elementsSet) { + for (const element of this.idMap.values()) { if (predicate(element)) { return true; } @@ -5675,7 +5734,7 @@ var PopupTriggerMap = class { * Returns an iterable of all registered trigger elements. */ elements() { - return this.elementsSet.values(); + return this.idMap.values(); } /** * Returns the number of registered trigger elements. @@ -5735,12 +5794,12 @@ function createPopupFloatingRootContext(triggerElements, floatingId, nested = fa onOpenChange: void 0 }); } -var activeTriggerIdSelector = createSelector((state) => state.triggerIdProp ?? state.activeTriggerId); -var openSelector = createSelector((state) => state.openProp ?? state.open); -var popupIdSelector = createSelector((state) => { +var activeTriggerIdSelector = (state) => state.triggerIdProp ?? state.activeTriggerId; +var openSelector = (state) => state.openProp ?? state.open; +var popupIdSelector = (state) => { const popupId = state.popupElement?.id ?? state.floatingId; return popupId || void 0; -}); +}; function triggerOwnsOpenPopup(state, triggerId) { return triggerId !== void 0 && openSelector(state) && activeTriggerIdSelector(state) === triggerId; } @@ -5752,101 +5811,73 @@ function triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) { } var popupStoreSelectors = { open: openSelector, - mounted: createSelector((state) => state.mounted), - transitionStatus: createSelector((state) => state.transitionStatus), - floatingRootContext: createSelector((state) => state.floatingRootContext), - triggerCount: createSelector((state) => state.triggerCount), - preventUnmountingOnClose: createSelector((state) => state.preventUnmountingOnClose), - payload: createSelector((state) => state.payload), + mounted: (state) => state.mounted, + transitionStatus: (state) => state.transitionStatus, + floatingRootContext: (state) => state.floatingRootContext, + triggerCount: (state) => state.triggerCount, + preventUnmountingOnClose: (state) => state.preventUnmountingOnClose, + payload: (state) => state.payload, activeTriggerId: activeTriggerIdSelector, - activeTriggerElement: createSelector((state) => state.mounted ? state.activeTriggerElement : null), + activeTriggerElement: (state) => state.mounted ? state.activeTriggerElement : null, popupId: popupIdSelector, /** * Whether the trigger with the given ID was used to open the popup. */ - isTriggerActive: createSelector((state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId), + isTriggerActive: (state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId, /** * Whether the popup is open and was activated by a trigger with the given ID. */ - isOpenedByTrigger: createSelector((state, triggerId) => triggerOwnsOpenPopup(state, triggerId)), + isOpenedByTrigger: (state, triggerId) => triggerOwnsOpenPopup(state, triggerId), /** * Whether the popup is mounted and was activated by a trigger with the given ID. */ - isMountedByTrigger: createSelector((state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId && state.mounted), - triggerProps: createSelector((state, isActive) => isActive ? state.activeTriggerProps : state.inactiveTriggerProps), + isMountedByTrigger: (state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId && state.mounted, + triggerProps: (state, isActive) => isActive ? state.activeTriggerProps : state.inactiveTriggerProps, /** * Popup id for the trigger that currently owns the open popup. */ - triggerPopupId: createSelector((state, triggerId) => triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) ? popupIdSelector(state) : void 0), - popupProps: createSelector((state) => state.popupProps), - popupElement: createSelector((state) => state.popupElement), - positionerElement: createSelector((state) => state.positionerElement) + triggerPopupId: (state, triggerId) => triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) ? popupIdSelector(state) : void 0, + popupProps: (state) => state.popupProps, + popupElement: (state) => state.popupElement, + positionerElement: (state) => state.positionerElement }; -// node_modules/@base-ui/react/floating-ui-react/hooks/useFloatingRootContext.mjs -function useFloatingRootContext(options) { - const { - open = false, - onOpenChange, - elements = {} - } = options; - const floatingId = useId(); - const nested = useFloatingParentNodeId() != null; - if (true) { - const optionDomReference = elements.reference; - if (optionDomReference && !isElement(optionDomReference)) { - console.error("Cannot pass a virtual element to the `elements.reference` option,", "as it must be a real DOM element. Use `context.setPositionReference()`", "instead."); - } - } - const store2 = useRefWithInit(() => new FloatingRootStore({ - open, - transitionStatus: void 0, - onOpenChange, - referenceElement: elements.reference ?? null, - floatingElement: elements.floating ?? null, - triggerElements: new PopupTriggerMap(), - floatingId, - syncOnly: false, - nested - })).current; - useIsoLayoutEffect(() => { - const valuesToSync = { - open, - floatingId - }; - if (elements.reference !== void 0) { - valuesToSync.referenceElement = elements.reference; - valuesToSync.domReferenceElement = isElement(elements.reference) ? elements.reference : null; - } - if (elements.floating !== void 0) { - valuesToSync.floatingElement = elements.floating; +// node_modules/@base-ui/react/utils/popups/usePopupHandleStore.mjs +var React26 = __toESM(require_react(), 1); +var import_shim2 = __toESM(require_shim(), 1); +function usePopupHandleStore(handle) { + const subscribe = React26.useCallback((listener) => { + if (handle === void 0) { + return NOOP; } - store2.update(valuesToSync); - }, [open, floatingId, elements.reference, elements.floating, store2]); - store2.context.onOpenChange = onOpenChange; - store2.context.nested = nested; - return store2; + return handle.subscribeStore(listener); + }, [handle]); + const getSnapshot = React26.useCallback(() => { + return handle === void 0 ? void 0 : handle.store; + }, [handle]); + return (0, import_shim2.useSyncExternalStore)(subscribe, getSnapshot, () => handle?.serverStore); } // node_modules/@base-ui/react/floating-ui-react/hooks/useFloating.mjs -function useFloating2(options = {}) { +function useBaseUIFloating(options) { + return useFloatingWithStore(options, options.rootContext); +} +function useFloatingWithStore(options, store2) { const { nodeId, externalTree } = options; - const internalStore = useFloatingRootContext(options); - const store2 = options.rootContext || internalStore; const referenceElement = store2.useState("referenceElement"); const floatingElement = store2.useState("floatingElement"); const domReferenceElement = store2.useState("domReferenceElement"); const open = store2.useState("open"); const floatingId = store2.useState("floatingId"); - const [positionReference, setPositionReferenceRaw] = React29.useState(null); - const [localDomReference, setLocalDomReference] = React29.useState(void 0); - const [localFloatingElement, setLocalFloatingElement] = React29.useState(void 0); - const domReferenceRef = React29.useRef(null); + const [positionReference, setPositionReferenceRaw] = React27.useState(null); + const [localDomReference, setLocalDomReference] = React27.useState(void 0); + const [localFloatingElement, setLocalFloatingElement] = React27.useState(void 0); + const domReferenceRef = React27.useRef(null); const tree = useFloatingTree(externalTree); - const storeElements = React29.useMemo(() => ({ + const storeElements = React27.useMemo(() => ({ reference: referenceElement, floating: floatingElement, domReference: domReferenceElement @@ -5865,7 +5896,7 @@ function useFloating2(options = {}) { store2.useSyncedValue("referenceElement", localDomReference ?? null); store2.useSyncedValue("domReferenceElement", localDomReference === void 0 ? domReferenceElement : localDomReferenceElement); store2.useSyncedValue("floatingElement", syncedFloatingElement); - const setPositionReference = React29.useCallback((node) => { + const setPositionReference = React27.useCallback((node) => { const computedPositionReference = isElement(node) ? { getBoundingClientRect: () => node.getBoundingClientRect(), getClientRects: () => node.getClientRects(), @@ -5874,7 +5905,7 @@ function useFloating2(options = {}) { setPositionReferenceRaw(computedPositionReference); position.refs.setReference(computedPositionReference); }, [position.refs]); - const setReference = React29.useCallback((node) => { + const setReference = React27.useCallback((node) => { if (isElement(node) || node === null) { domReferenceRef.current = node; setLocalDomReference(node); @@ -5886,22 +5917,22 @@ function useFloating2(options = {}) { position.refs.setReference(node); } }, [position.refs, setLocalDomReference]); - const setFloating = React29.useCallback((node) => { + const setFloating = React27.useCallback((node) => { setLocalFloatingElement(node); position.refs.setFloating(node); }, [position.refs]); - const refs = React29.useMemo(() => ({ + const refs = React27.useMemo(() => ({ ...position.refs, setReference, setFloating, setPositionReference, domReference: domReferenceRef }), [position.refs, setReference, setFloating, setPositionReference]); - const elements = React29.useMemo(() => ({ + const elements = React27.useMemo(() => ({ ...position.elements, domReference: domReferenceElement }), [position.elements, domReferenceElement]); - const context = React29.useMemo(() => ({ + const context = React27.useMemo(() => ({ ...position, dataRef: store2.context.dataRef, open, @@ -5925,7 +5956,7 @@ function useFloating2(options = {}) { node.context = context; } }); - return React29.useMemo(() => ({ + return React27.useMemo(() => ({ ...position, context, refs, @@ -5935,7 +5966,7 @@ function useFloating2(options = {}) { } // node_modules/@base-ui/react/floating-ui-react/hooks/useFocus.mjs -var React30 = __toESM(require_react(), 1); +var React28 = __toESM(require_react(), 1); var isMacSafari = parts_exports.os.mac && parts_exports.engine.webkit; function useFocus(context, props = {}) { const { @@ -5947,11 +5978,11 @@ function useFocus(context, props = {}) { events, dataRef } = store2.context; - const blockFocusRef = React30.useRef(false); - const blockedReferenceRef = React30.useRef(null); - const keyboardModalityRef = React30.useRef(true); + const blockFocusRef = React28.useRef(false); + const blockedReferenceRef = React28.useRef(null); + const keyboardModalityRef = React28.useRef(true); const timeout = useTimeout(); - React30.useEffect(() => { + React28.useEffect(() => { const domReference = store2.select("domReferenceElement"); if (!enabled) { return void 0; @@ -5971,7 +6002,7 @@ function useFocus(context, props = {}) { } return mergeCleanups(addEventListener(win, "blur", onBlur), isMacSafari && addEventListener(win, "keydown", onKeyDown, true), isMacSafari && addEventListener(win, "pointerdown", onPointerDown, true)); }, [store2, enabled]); - React30.useEffect(() => { + React28.useEffect(() => { if (!enabled) { return void 0; } @@ -5989,7 +6020,7 @@ function useFocus(context, props = {}) { events.off("openchange", onOpenChangeLocal); }; }, [events, enabled, store2]); - const reference = React30.useMemo(() => { + const reference = React28.useMemo(() => { function resetBlockedFocus() { blockFocusRef.current = false; blockedReferenceRef.current = null; @@ -6056,14 +6087,14 @@ function useFocus(context, props = {}) { } }; }, [dataRef, delay, store2, timeout]); - return React30.useMemo(() => enabled ? { + return React28.useMemo(() => enabled ? { reference, trigger: reference } : {}, [enabled, reference]); } // node_modules/@base-ui/react/floating-ui-react/hooks/useHoverFloatingInteraction.mjs -var React31 = __toESM(require_react(), 1); +var React29 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/hooks/useHoverInteractionSharedState.mjs var HoverInteraction = class _HoverInteraction { @@ -6174,7 +6205,7 @@ function useHoverFloatingInteraction(context, parameters = {}) { clearPointerEvents(); } }, [open, instance, clearPointerEvents]); - React31.useEffect(() => { + React29.useEffect(() => { return clearPointerEvents; }, [clearPointerEvents]); useIsoLayoutEffect(() => { @@ -6203,7 +6234,7 @@ function useHoverFloatingInteraction(context, parameters = {}) { } return void 0; }, [enabled, open, domReferenceElement, floatingElement, instance, isHoverOpen, tree, parentId, clearPointerEvents]); - React31.useEffect(() => { + React29.useEffect(() => { if (!enabled) { return void 0; } @@ -6278,7 +6309,7 @@ function useHoverFloatingInteraction(context, parameters = {}) { } // node_modules/@base-ui/react/floating-ui-react/hooks/useHoverReferenceInteraction.mjs -var React32 = __toESM(require_react(), 1); +var React30 = __toESM(require_react(), 1); var ReactDOM5 = __toESM(require_react_dom(), 1); var EMPTY_REF = { current: null @@ -6296,7 +6327,8 @@ function useHoverReferenceInteraction(context, props = {}) { isActiveTrigger = true, getHandleCloseContext, isClosing, - shouldOpen: shouldOpenProp + shouldOpen: shouldOpenProp, + guardStaleOpen = false } = props; const store2 = "rootStore" in context ? context.rootStore : context; const { @@ -6305,7 +6337,7 @@ function useHoverReferenceInteraction(context, props = {}) { } = store2.context; const tree = useFloatingTree(externalTree); const instance = useHoverInteractionSharedState(store2); - const isHoverCloseActiveRef = React32.useRef(false); + const isHoverCloseActiveRef = React30.useRef(false); const handleCloseRef = useValueAsRef(handleClose); const delayRef = useValueAsRef(delay); const restMsRef = useValueAsRef(restMs); @@ -6343,8 +6375,8 @@ function useHoverReferenceInteraction(context, props = {}) { if (isActiveTrigger) { instance.handleCloseOptions = handleCloseRef.current?.__options; } - React32.useEffect(() => cleanupMouseMoveHandler, [cleanupMouseMoveHandler]); - React32.useEffect(() => { + React30.useEffect(() => cleanupMouseMoveHandler, [cleanupMouseMoveHandler]); + React30.useEffect(() => { if (!enabled) { return void 0; } @@ -6365,7 +6397,7 @@ function useHoverReferenceInteraction(context, props = {}) { events.off("openchange", onOpenChangeLocal); }; }, [enabled, events, instance, cleanupMouseMoveHandler]); - React32.useEffect(() => { + React30.useEffect(() => { if (!enabled) { return void 0; } @@ -6479,14 +6511,23 @@ function useHoverReferenceInteraction(context, props = {}) { closeWithDelay(event); } } + function onMouseOut(event) { + if (contains(trigger, event.relatedTarget)) { + return; + } + instance.openChangeTimeout.clear(); + instance.restTimeout.clear(); + instance.restTimeoutPending = false; + } + const staleOpenGuard = guardStaleOpen ? addEventListener(trigger, "mouseout", onMouseOut) : void 0; if (move) { return mergeCleanups(addEventListener(trigger, "mousemove", onMouseEnter, { once: true - }), addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave)); + }), addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave), staleOpenGuard); } - return mergeCleanups(addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave)); - }, [cleanupMouseMoveHandler, clearPointerEvents, dataRef, delayRef, store2, enabled, handleCloseRef, instance, isActiveTrigger, isOverInactiveTrigger, isClickLikeOpenEvent2, mouseOnly, move, restMsRef, triggerElementRef, tree, enabledRef, getHandleCloseContext, isClosingRef, checkShouldOpen]); - return React32.useMemo(() => { + return mergeCleanups(addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave), staleOpenGuard); + }, [cleanupMouseMoveHandler, clearPointerEvents, dataRef, delayRef, store2, enabled, handleCloseRef, instance, isActiveTrigger, isOverInactiveTrigger, isClickLikeOpenEvent2, mouseOnly, move, restMsRef, triggerElementRef, tree, enabledRef, getHandleCloseContext, isClosingRef, checkShouldOpen, guardStaleOpen]); + return React30.useMemo(() => { if (!enabled) { return void 0; } @@ -6767,6 +6808,21 @@ function safePolygon(options = {}) { return fn; } +// node_modules/@base-ui/react/utils/NullStore.mjs +var NullStore = class extends ReactStore { + // `update`/`set`/`notifyAll` funnel through `setState` in the base `Store`, so overriding + // `setState` alone would neutralize them today. They are overridden explicitly so the store stays + // inert even if a future base-class change stops routing a mutator through `setState`. + setState(_newState) { + } + update(_changes) { + } + set(_key, _value) { + } + notifyAll() { + } +}; + // node_modules/@base-ui/react/utils/popupStateMapping.mjs var CommonPopupDataAttributes = (function(CommonPopupDataAttributes2) { CommonPopupDataAttributes2["open"] = "data-open"; @@ -6778,26 +6834,17 @@ var CommonPopupDataAttributes = (function(CommonPopupDataAttributes2) { CommonPopupDataAttributes2["align"] = "data-align"; return CommonPopupDataAttributes2; })({}); -var CommonTriggerDataAttributes = /* @__PURE__ */ (function(CommonTriggerDataAttributes2) { - CommonTriggerDataAttributes2["popupOpen"] = "data-popup-open"; - CommonTriggerDataAttributes2["pressed"] = "data-pressed"; - return CommonTriggerDataAttributes2; -})({}); var TRIGGER_HOOK = { - [CommonTriggerDataAttributes.popupOpen]: "" -}; -var PRESSABLE_TRIGGER_HOOK = { - [CommonTriggerDataAttributes.popupOpen]: "", - [CommonTriggerDataAttributes.pressed]: "" + "data-popup-open": "" }; var POPUP_OPEN_HOOK = { - [CommonPopupDataAttributes.open]: "" + "data-open": "" }; var POPUP_CLOSED_HOOK = { - [CommonPopupDataAttributes.closed]: "" + "data-closed": "" }; var ANCHOR_HIDDEN_HOOK = { - [CommonPopupDataAttributes.anchorHidden]: "" + "data-anchor-hidden": "" }; var triggerOpenStateMapping = { open(value) { @@ -6821,6 +6868,10 @@ var popupStateMapping = { return null; } }; +var popupTransitionStateMapping = { + ...popupStateMapping, + ...transitionStatusMapping +}; // node_modules/@base-ui/utils/inertValue.mjs function inertValue(value) { @@ -6830,8 +6881,17 @@ function inertValue(value) { return value ? "true" : void 0; } -// node_modules/@base-ui/react/utils/useAnchorPositioning.mjs -var React33 = __toESM(require_react(), 1); +// node_modules/@base-ui/react/internals/direction-context/DirectionContext.mjs +var React31 = __toESM(require_react(), 1); +var DirectionContext = /* @__PURE__ */ React31.createContext(void 0); +if (true) DirectionContext.displayName = "DirectionContext"; +function useDirection() { + const context = React31.useContext(DirectionContext); + return context?.direction ?? "ltr"; +} + +// node_modules/@base-ui/react/internals/useAnchorPositioning.mjs +var React32 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/middleware/arrow.mjs var baseArrow = (options) => ({ @@ -6903,7 +6963,6 @@ var arrow4 = (options, deps) => ({ }); // node_modules/@base-ui/react/utils/hideMiddleware.mjs -var nativeHideFn = hide3().fn; var hide4 = { name: "hide", async fn(state) { @@ -6914,88 +6973,27 @@ var hide4 = { y } = state.rects.reference; const anchorHidden = width === 0 && height === 0 && x === 0 && y === 0; - const nativeHideResult = await nativeHideFn(state); + const overflow = await state.platform.detectOverflow(state, { + elementContext: "reference" + }); + const referenceHidden = overflow.top - height >= 0 || overflow.right - width >= 0 || overflow.bottom - height >= 0 || overflow.left - width >= 0; return { data: { - referenceHidden: nativeHideResult.data?.referenceHidden || anchorHidden + referenceHidden: referenceHidden || anchorHidden } }; } }; -// node_modules/@base-ui/react/utils/adaptiveOriginMiddleware.mjs +// node_modules/@base-ui/react/utils/adaptiveOriginConstants.mjs var DEFAULT_SIDES = { sideX: "left", sideY: "top" }; -var adaptiveOrigin = { - name: "adaptiveOrigin", - async fn(state) { - const { - x: rawX, - y: rawY, - rects: { - floating: floatRect - }, - elements: { - floating - }, - platform: platform3, - strategy, - placement - } = state; - const win = getWindow(floating); - const styles = win.getComputedStyle(floating); - const hasTransition = styles.transitionDuration !== "0s" && styles.transitionDuration !== ""; - if (!hasTransition) { - return { - x: rawX, - y: rawY, - data: DEFAULT_SIDES - }; - } - const offsetParent = await platform3.getOffsetParent?.(floating); - let offsetDimensions = { - width: 0, - height: 0 - }; - if (strategy === "fixed" && win?.visualViewport) { - offsetDimensions = { - width: win.visualViewport.width, - height: win.visualViewport.height - }; - } else if (offsetParent === win) { - const doc = ownerDocument(floating); - offsetDimensions = { - width: doc.documentElement.clientWidth, - height: doc.documentElement.clientHeight - }; - } else if (await platform3.isElement?.(offsetParent)) { - offsetDimensions = await platform3.getDimensions(offsetParent); - } - const currentSide = getSide(placement); - let x = rawX; - let y = rawY; - if (currentSide === "left") { - x = offsetDimensions.width - (rawX + floatRect.width); - } - if (currentSide === "top") { - y = offsetDimensions.height - (rawY + floatRect.height); - } - const sideX = currentSide === "left" ? "right" : DEFAULT_SIDES.sideX; - const sideY = currentSide === "top" ? "bottom" : DEFAULT_SIDES.sideY; - return { - x, - y, - data: { - sideX, - sideY - } - }; - } -}; -// node_modules/@base-ui/react/utils/useAnchorPositioning.mjs +// node_modules/@base-ui/react/internals/useAnchorPositioning.mjs +var AVAILABLE_WIDTH_VAR = "--available-width"; +var AVAILABLE_HEIGHT_VAR = "--available-height"; function getLogicalSide(sideParam, renderedSide, isRtl) { const isLogicalSideParam = sideParam === "inline-start" || sideParam === "inline-end"; const logicalRight = isRtl ? "inline-start" : "inline-end"; @@ -7027,6 +7025,9 @@ function getOffsetData(state, sideParam, isRtl) { return data; } function useAnchorPositioning(params) { + return useAnchorPositioningWithHook(params, useBaseUIFloating); +} +function useAnchorPositioningWithHook(params, useFloatingHook) { const { // Public parameters anchor, @@ -7046,19 +7047,21 @@ function useAnchorPositioning(params) { floatingRootContext, mounted, collisionAvoidance, - shiftCrossAxis = false, + shift: shift4, nodeId, adaptiveOrigin: adaptiveOrigin2, lazyFlip = false, externalTree } = params; - const [mountSide, setMountSide] = React33.useState(null); + const [mountSide, setMountSide] = React32.useState(null); if (!mounted && mountSide !== null) { setMountSide(null); } const collisionAvoidanceSide = collisionAvoidance.side || "flip"; const collisionAvoidanceAlign = collisionAvoidance.align || "flip"; const collisionAvoidanceFallbackAxisSide = collisionAvoidance.fallbackAxisSide || "end"; + const shiftCrossAxis = shift4?.crossAxis ?? false; + const shiftRootBoundary = shift4?.rootBoundary; const anchorFn = typeof anchor === "function" ? anchor : void 0; const anchorFnCallback = useStableCallback(anchorFn); const anchorDep = anchorFn ? anchorFnCallback : anchor; @@ -7076,31 +7079,31 @@ function useAnchorPositioning(params) { }[sideParam]; const placement = align === "center" ? side : `${side}-${align}`; let collisionPadding = collisionPaddingParam; - const bias = 1; - const biasTop = sideParam === "bottom" ? bias : 0; - const biasBottom = sideParam === "top" ? bias : 0; - const biasLeft = sideParam === "right" ? bias : 0; - const biasRight = sideParam === "left" ? bias : 0; if (typeof collisionPadding === "number") { collisionPadding = { - top: collisionPadding + biasTop, - right: collisionPadding + biasRight, - bottom: collisionPadding + biasBottom, - left: collisionPadding + biasLeft + top: collisionPadding, + right: collisionPadding, + bottom: collisionPadding, + left: collisionPadding }; } else if (collisionPadding) { collisionPadding = { - top: (collisionPadding.top || 0) + biasTop, - right: (collisionPadding.right || 0) + biasRight, - bottom: (collisionPadding.bottom || 0) + biasBottom, - left: (collisionPadding.left || 0) + biasLeft + top: collisionPadding.top || 0, + right: collisionPadding.right || 0, + bottom: collisionPadding.bottom || 0, + left: collisionPadding.left || 0 }; } + const bias = 1; + const biasTop = sideParam === "bottom" ? bias : 0; + const biasBottom = sideParam === "top" ? bias : 0; + const biasLeft = sideParam === "right" ? bias : 0; + const biasRight = sideParam === "left" ? bias : 0; const commonCollisionProps = { boundary: collisionBoundary === "clipping-ancestors" ? "clippingAncestors" : collisionBoundary, padding: collisionPadding }; - const arrowRef = React33.useRef(null); + const arrowRef = React32.useRef(null); const sideOffsetRef = useValueAsRef(sideOffset); const alignOffsetRef = useValueAsRef(alignOffset); const sideOffsetDep = typeof sideOffset !== "function" ? sideOffset : 0; @@ -7126,46 +7129,37 @@ function useAnchorPositioning(params) { // Ensure the popup flips if it's been limited by its --available-height and it resizes. // Since the size() padding is smaller than the flip() padding, flip() will take precedence. padding: { - top: collisionPadding.top + bias, - right: collisionPadding.right + bias, - bottom: collisionPadding.bottom + bias, - left: collisionPadding.left + bias + top: collisionPadding.top + bias + biasTop, + right: collisionPadding.right + bias + biasRight, + bottom: collisionPadding.bottom + bias + biasBottom, + left: collisionPadding.left + bias + biasLeft }, mainAxis: !shiftCrossAxis && collisionAvoidanceSide === "flip", crossAxis: collisionAvoidanceAlign === "flip" ? "alignment" : false, fallbackAxisSideDirection: collisionAvoidanceFallbackAxisSide }); - const shiftMiddleware = shiftDisabled ? null : shift3((data) => { - const html = ownerDocument(data.elements.floating).documentElement; - return { - ...commonCollisionProps, - // Use the Layout Viewport to avoid shifting around when pinch-zooming - // for context menus. - rootBoundary: shiftCrossAxis ? { - x: 0, - y: 0, - width: html.clientWidth, - height: html.clientHeight - } : void 0, - mainAxis: collisionAvoidanceAlign !== "none", - crossAxis: crossAxisShiftEnabled, - limiter: sticky || shiftCrossAxis ? void 0 : limitShift3((limitData) => { - if (!arrowRef.current) { - return {}; - } - const { - width, - height - } = arrowRef.current.getBoundingClientRect(); - const sideAxis = getSideAxis(getSide(limitData.placement)); - const arrowSize = sideAxis === "y" ? width : height; - const offsetAmount = sideAxis === "y" ? collisionPadding.left + collisionPadding.right : collisionPadding.top + collisionPadding.bottom; - return { - offset: arrowSize / 2 + offsetAmount / 2 - }; - }) - }; - }, [commonCollisionProps, sticky, shiftCrossAxis, collisionPadding, collisionAvoidanceAlign]); + const shiftMiddleware = shiftDisabled ? null : shift3({ + ...commonCollisionProps, + // Use the Layout Viewport to avoid shifting around when pinch-zooming. + rootBoundary: shiftRootBoundary, + mainAxis: collisionAvoidanceAlign !== "none", + crossAxis: crossAxisShiftEnabled, + limiter: sticky || shiftCrossAxis ? void 0 : limitShift3((limitData) => { + if (!arrowRef.current) { + return {}; + } + const { + width, + height + } = arrowRef.current.getBoundingClientRect(); + const sideAxis = getSideAxis(getSide(limitData.placement)); + const arrowSize = sideAxis === "y" ? width : height; + const offsetAmount = sideAxis === "y" ? collisionPadding.left + collisionPadding.right : collisionPadding.top + collisionPadding.bottom; + return { + offset: arrowSize / 2 + offsetAmount / 2 + }; + }) + }, [commonCollisionProps, sticky, shiftCrossAxis, shiftRootBoundary, collisionPadding, collisionAvoidanceAlign]); if (collisionAvoidanceSide === "shift" || collisionAvoidanceAlign === "shift" || align === "center") { middleware.push(shiftMiddleware, flipMiddleware); } else { @@ -7185,8 +7179,8 @@ function useAnchorPositioning(params) { return; } const floatingStyle = floating.style; - floatingStyle.setProperty("--available-width", `${availableWidth}px`); - floatingStyle.setProperty("--available-height", `${availableHeight}px`); + floatingStyle.setProperty(AVAILABLE_WIDTH_VAR, `${availableWidth}px`); + floatingStyle.setProperty(AVAILABLE_HEIGHT_VAR, `${availableHeight}px`); const dpr = getWindow(floating).devicePixelRatio || 1; const { x: x2, @@ -7249,7 +7243,7 @@ function useAnchorPositioning(params) { }); } }, [mounted, floatingRootContext]); - const autoUpdateOptions = React33.useMemo(() => ({ + const autoUpdateOptions = React32.useMemo(() => ({ elementResize: !disableAnchorTracking && typeof ResizeObserver !== "undefined", layoutShift: !disableAnchorTracking && typeof IntersectionObserver !== "undefined" }), [disableAnchorTracking]); @@ -7264,7 +7258,7 @@ function useAnchorPositioning(params) { context, isPositioned, floatingStyles: originalFloatingStyles - } = useFloating2({ + } = useFloatingHook({ rootContext: floatingRootContext, open: keepMounted ? mounted : void 0, placement, @@ -7279,21 +7273,34 @@ function useAnchorPositioning(params) { sideY } = middlewareData.adaptiveOrigin || DEFAULT_SIDES; const resolvedPosition = isPositioned ? positionMethod : "fixed"; - const floatingStyles = React33.useMemo(() => { - const base = adaptiveOrigin2 ? { - position: resolvedPosition, - [sideX]: x, - [sideY]: y - } : { - position: resolvedPosition, - ...originalFloatingStyles - }; + const floatingStyles = React32.useMemo(() => { + let base; + if (!isPositioned) { + base = { + position: resolvedPosition, + top: 0, + left: 0 + }; + } else if (adaptiveOrigin2) { + base = { + position: resolvedPosition, + [sideX]: x, + [sideY]: y + }; + } else { + base = { + ...originalFloatingStyles, + position: resolvedPosition + }; + } + base[AVAILABLE_WIDTH_VAR] = "100vw"; + base[AVAILABLE_HEIGHT_VAR] = "100vh"; if (!isPositioned) { base.opacity = 0; } return base; }, [adaptiveOrigin2, resolvedPosition, sideX, x, sideY, y, originalFloatingStyles, isPositioned]); - const registeredPositionReferenceRef = React33.useRef(null); + const registeredPositionReferenceRef = React32.useRef(null); useIsoLayoutEffect(() => { if (!mounted) { return; @@ -7307,7 +7314,7 @@ function useAnchorPositioning(params) { registeredPositionReferenceRef.current = finalAnchor; } }, [mounted, refs, anchorDep, anchorValueRef]); - React33.useEffect(() => { + React32.useEffect(() => { if (!mounted) { return; } @@ -7320,7 +7327,7 @@ function useAnchorPositioning(params) { registeredPositionReferenceRef.current = anchorValue.current; } }, [mounted, refs, anchorDep, anchorValueRef]); - React33.useEffect(() => { + React32.useEffect(() => { if (keepMounted && mounted && elements.reference && elements.floating) { return autoUpdate(elements.reference, elements.floating, update2, autoUpdateOptions); } @@ -7331,17 +7338,17 @@ function useAnchorPositioning(params) { const renderedAlign = getAlignment(renderedPlacement) || "center"; const anchorHidden = Boolean(middlewareData.hide?.referenceHidden); useIsoLayoutEffect(() => { - if (lazyFlip && mounted && isPositioned) { + if (lazyFlip && mounted && isPositioned && renderedSide !== side) { setMountSide(renderedSide); } - }, [lazyFlip, mounted, isPositioned, renderedSide]); - const arrowStyles = React33.useMemo(() => ({ + }, [lazyFlip, mounted, isPositioned, renderedSide, side]); + const arrowStyles = React32.useMemo(() => ({ position: "absolute", top: middlewareData.arrow?.y, left: middlewareData.arrow?.x }), [middlewareData.arrow]); const arrowUncentered = middlewareData.arrow?.centerOffset !== 0; - return React33.useMemo(() => ({ + return React32.useMemo(() => ({ positionerStyles: floatingStyles, arrowStyles, arrowRef, @@ -7360,7 +7367,7 @@ function isRef(param) { return param != null && "current" in param; } -// node_modules/@base-ui/react/utils/getDisabledMountTransitionStyles.mjs +// node_modules/@base-ui/react/internals/getDisabledMountTransitionStyles.mjs function getDisabledMountTransitionStyles(transitionStatus) { return transitionStatus === "starting" ? DISABLED_TRANSITIONS_STYLE : EMPTY_OBJECT; } @@ -7393,8 +7400,8 @@ function usePositioner(componentProps, state, { } // node_modules/@base-ui/react/button/Button.mjs -var React34 = __toESM(require_react(), 1); -var Button = /* @__PURE__ */ React34.forwardRef(function Button2(componentProps, forwardedRef) { +var React33 = __toESM(require_react(), 1); +var Button = /* @__PURE__ */ React33.forwardRef(function Button2(componentProps, forwardedRef) { const { render, className, @@ -7424,17 +7431,17 @@ var Button = /* @__PURE__ */ React34.forwardRef(function Button2(componentProps, if (true) Button.displayName = "Button"; // node_modules/@base-ui/react/utils/usePopupViewport.mjs -var React38 = __toESM(require_react(), 1); +var React37 = __toESM(require_react(), 1); var ReactDOM6 = __toESM(require_react_dom(), 1); // node_modules/@base-ui/utils/usePreviousValue.mjs -var React35 = __toESM(require_react(), 1); +var React34 = __toESM(require_react(), 1); function usePreviousValue(value) { - const [state, setState] = React35.useState({ + const [state, setState] = React34.useState({ current: value, previous: null }); - if (value !== state.current) { + if (!Object.is(value, state.current)) { setState({ current: value, previous: state.current @@ -7444,7 +7451,7 @@ function usePreviousValue(value) { } // node_modules/@base-ui/react/utils/usePopupAutoResize.mjs -var React36 = __toESM(require_react(), 1); +var React35 = __toESM(require_react(), 1); // node_modules/@base-ui/react/utils/getCssDimensions.mjs function getCssDimensions2(element) { @@ -7477,29 +7484,14 @@ function usePopupAutoResize(parameters) { side, direction } = parameters; - const runOnceAnimationsFinish = useAnimationsFinished(popupElement, true, false); + const runOnceAnimationsFinish = useAnimationsFinished(popupElement, true); const animationFrame = useAnimationFrame(); - const committedDimensionsRef = React36.useRef(null); - const isInitialRenderRef = React36.useRef(true); - const restoreAnchoringStylesRef = React36.useRef(NOOP); + const committedDimensionsRef = React35.useRef(null); + const isInitialRenderRef = React35.useRef(true); + const restoreAnchoringStylesRef = React35.useRef(NOOP); const onMeasureLayout = useStableCallback(onMeasureLayoutParam); const onMeasureLayoutComplete = useStableCallback(onMeasureLayoutCompleteParam); - const anchoringStyles = React36.useMemo(() => { - let isOriginSide = side === "top"; - let isPhysicalLeft = side === "left"; - if (direction === "rtl") { - isOriginSide = isOriginSide || side === "inline-end"; - isPhysicalLeft = isPhysicalLeft || side === "inline-end"; - } else { - isOriginSide = isOriginSide || side === "inline-start"; - isPhysicalLeft = isPhysicalLeft || side === "inline-start"; - } - return isOriginSide ? { - position: "absolute", - [side === "top" ? "bottom" : "top"]: "0", - [isPhysicalLeft ? "right" : "left"]: "0" - } : EMPTY_OBJECT; - }, [side, direction]); + const anchoringStyles = React35.useMemo(() => getPopupAnchoringStyles(side, direction), [side, direction]); useIsoLayoutEffect(() => { if (!mounted) { restoreAnchoringStylesRef.current = NOOP; @@ -7566,6 +7558,18 @@ function usePopupAutoResize(parameters) { }; }, [content, popupElement, positionerElement, runOnceAnimationsFinish, animationFrame, mounted, onMeasureLayout, onMeasureLayoutComplete, anchoringStyles]); } +function getPopupAnchoringStyles(side, direction) { + const isPhysicalTop = side === "top"; + const isPhysicalLeft = side === "left" || side === (direction === "rtl" ? "inline-end" : "inline-start"); + if (!isPhysicalTop && !isPhysicalLeft) { + return EMPTY_OBJECT; + } + return { + position: "absolute", + [isPhysicalTop ? "bottom" : "top"]: "0", + [isPhysicalLeft ? "right" : "left"]: "0" + }; +} function overrideElementStyle(element, property, value) { const originalValue = element.style.getPropertyValue(property); element.style.setProperty(property, value); @@ -7596,13 +7600,13 @@ function setPositionerCssSize(positionerElement, size4) { } // node_modules/@base-ui/react/direction-provider/DirectionProvider.mjs -var React37 = __toESM(require_react(), 1); +var React36 = __toESM(require_react(), 1); var import_jsx_runtime5 = __toESM(require_jsx_runtime(), 1); var DirectionProvider = function DirectionProvider2(props) { const { direction = "ltr" } = props; - const contextValue = React37.useMemo(() => ({ + const contextValue = React36.useMemo(() => ({ direction }), [direction]); return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(DirectionContext.Provider, { @@ -7612,78 +7616,164 @@ var DirectionProvider = function DirectionProvider2(props) { }; if (true) DirectionProvider.displayName = "DirectionProvider"; -// node_modules/@base-ui/react/utils/usePopupViewport.mjs -var import_jsx_runtime6 = __toESM(require_jsx_runtime(), 1); -function usePopupViewport(parameters) { - const { - store: store2, - side, - cssVars, - children - } = parameters; - const direction = useDirection(); - const activeTrigger = store2.useState("activeTriggerElement"); - const activeTriggerId = store2.useState("activeTriggerId"); - const open = store2.useState("open"); - const payload = store2.useState("payload"); - const mounted = store2.useState("mounted"); - const popupElement = store2.useState("popupElement"); - const positionerElement = store2.useState("positionerElement"); - const previousActiveTrigger = usePreviousValue(open ? activeTrigger : null); - const currentContentKey = usePopupContentKey(activeTriggerId, payload); - const capturedNodeRef = React38.useRef(null); - const [previousContentNode, setPreviousContentNode] = React38.useState(null); - const [newTriggerOffset, setNewTriggerOffset] = React38.useState(null); - const currentContainerRef = React38.useRef(null); - const previousContainerRef = React38.useRef(null); - const onAnimationsFinished = useAnimationsFinished(currentContainerRef, true, false); - const cleanupFrame = useAnimationFrame(); - const [previousContentDimensions, setPreviousContentDimensions] = React38.useState(null); - const [showStartingStyleAttribute, setShowStartingStyleAttribute] = React38.useState(false); - useIsoLayoutEffect(() => { - store2.set("hasViewport", true); - return () => { - store2.set("hasViewport", false); - }; - }, [store2]); - const handleMeasureLayout = useStableCallback(() => { - currentContainerRef.current?.style.setProperty("animation", "none"); - currentContainerRef.current?.style.setProperty("transition", "none"); - previousContainerRef.current?.style.setProperty("display", "none"); - }); - const handleMeasureLayoutComplete = useStableCallback((previousDimensions) => { - currentContainerRef.current?.style.removeProperty("animation"); - currentContainerRef.current?.style.removeProperty("transition"); - previousContainerRef.current?.style.removeProperty("display"); - if (previousDimensions) { - setPreviousContentDimensions(previousDimensions); - } - }); - const lastHandledTriggerRef = React38.useRef(null); - useIsoLayoutEffect(() => { - if (!open || !mounted) { - lastHandledTriggerRef.current = null; - } - }, [open, mounted]); +// node_modules/@base-ui/react/utils/adaptiveOriginMiddleware.mjs +var adaptiveOrigin = { + name: "adaptiveOrigin", + async fn(state) { + const { + x: rawX, + y: rawY, + rects: { + floating: floatRect + }, + elements: { + floating + }, + platform: platform3, + strategy, + placement + } = state; + const win = getWindow(floating); + const styles = win.getComputedStyle(floating); + const hasTransition = styles.transitionDuration !== "0s" && styles.transitionDuration !== ""; + if (!hasTransition) { + return { + x: rawX, + y: rawY, + data: DEFAULT_SIDES + }; + } + const offsetParent = await platform3.getOffsetParent?.(floating); + let offsetDimensions = { + width: 0, + height: 0 + }; + if (strategy === "fixed" && win?.visualViewport) { + offsetDimensions = { + width: win.visualViewport.width, + height: win.visualViewport.height + }; + } else if (offsetParent === win) { + const doc = ownerDocument(floating); + offsetDimensions = { + width: doc.documentElement.clientWidth, + height: doc.documentElement.clientHeight + }; + } else if (await platform3.isElement?.(offsetParent)) { + offsetDimensions = await platform3.getDimensions(offsetParent); + } + const currentSide = getSide(placement); + let x = rawX; + let y = rawY; + if (currentSide === "left") { + x = offsetDimensions.width - (rawX + floatRect.width); + } + if (currentSide === "top") { + y = offsetDimensions.height - (rawY + floatRect.height); + } + const sideX = currentSide === "left" ? "right" : DEFAULT_SIDES.sideX; + const sideY = currentSide === "top" ? "bottom" : DEFAULT_SIDES.sideY; + return { + x, + y, + data: { + sideX, + sideY + } + }; + } +}; + +// node_modules/@base-ui/react/utils/usePopupViewport.mjs +var import_jsx_runtime6 = __toESM(require_jsx_runtime(), 1); +var popupViewportStateMapping = { + activationDirection: (value) => value ? { + "data-activation-direction": value + } : null +}; +function usePopupViewport(parameters) { + const { + store: store2, + side, + children + } = parameters; + const direction = useDirection(); + const activeTrigger = store2.useState("activeTriggerElement"); + const activeTriggerId = store2.useState("activeTriggerId"); + const open = store2.useState("open"); + const payload = store2.useState("payload"); + const mounted = store2.useState("mounted"); + const popupElement = store2.useState("popupElement"); + const positionerElement = store2.useState("positionerElement"); + const previousActiveTrigger = usePreviousValue(open ? activeTrigger : null); + const currentContentKey = usePopupContentKey(activeTriggerId, payload); + const capturedNodeRef = React37.useRef(null); + const [previousContentNode, setPreviousContentNode] = React37.useState(null); + const [newTriggerOffset, setNewTriggerOffset] = React37.useState(null); + const currentContainerRef = React37.useRef(null); + const previousContainerRef = React37.useRef(null); + const onAnimationsFinished = useAnimationsFinished(currentContainerRef, true); + const cleanupFrame = useAnimationFrame(); + const cleanupControllerRef = React37.useRef(null); + const [previousContentDimensions, setPreviousContentDimensions] = React37.useState(null); + const [showStartingStyleAttribute, setShowStartingStyleAttribute] = React37.useState(false); + useIsoLayoutEffect(() => { + store2.set("adaptiveOrigin", adaptiveOrigin); + return () => { + store2.set("adaptiveOrigin", void 0); + }; + }, [store2]); + const handleMeasureLayout = useStableCallback(() => { + currentContainerRef.current?.style.setProperty("animation", "none"); + currentContainerRef.current?.style.setProperty("transition", "none"); + previousContainerRef.current?.style.setProperty("display", "none"); + }); + const handleMeasureLayoutComplete = useStableCallback((previousDimensions) => { + currentContainerRef.current?.style.removeProperty("animation"); + currentContainerRef.current?.style.removeProperty("transition"); + previousContainerRef.current?.style.removeProperty("display"); + if (previousDimensions) { + setPreviousContentDimensions(previousDimensions); + } + }); + const armViewportCleanup = useStableCallback(() => { + cleanupControllerRef.current?.abort(); + const controller = new AbortController(); + cleanupControllerRef.current = controller; + onAnimationsFinished(() => { + setPreviousContentNode(null); + setPreviousContentDimensions(null); + capturedNodeRef.current = null; + }, controller.signal); + }); + const lastHandledTriggerRef = React37.useRef(null); + useIsoLayoutEffect(() => { + if (!open || !mounted) { + lastHandledTriggerRef.current = null; + } + }, [open, mounted]); useIsoLayoutEffect(() => { if (activeTrigger && previousActiveTrigger && activeTrigger !== previousActiveTrigger && lastHandledTriggerRef.current !== activeTrigger && capturedNodeRef.current) { setPreviousContentNode(capturedNodeRef.current); setShowStartingStyleAttribute(true); const offset4 = calculateRelativePosition(previousActiveTrigger, activeTrigger); setNewTriggerOffset(offset4); - cleanupFrame.request(() => { - ReactDOM6.flushSync(() => { - setShowStartingStyleAttribute(false); - }); - onAnimationsFinished(() => { - setPreviousContentNode(null); - setPreviousContentDimensions(null); - capturedNodeRef.current = null; - }); - }); lastHandledTriggerRef.current = activeTrigger; } - }, [activeTrigger, previousActiveTrigger, previousContentNode, onAnimationsFinished, cleanupFrame]); + }, [activeTrigger, previousActiveTrigger]); + useIsoLayoutEffect(() => { + if (previousContentNode == null) { + return; + } + cleanupControllerRef.current?.abort(); + setShowStartingStyleAttribute(true); + cleanupFrame.request(() => { + ReactDOM6.flushSync(() => { + setShowStartingStyleAttribute(false); + }); + armViewportCleanup(); + }); + }, [currentContentKey, previousContentNode, armViewportCleanup, cleanupFrame]); useIsoLayoutEffect(() => { const source = currentContainerRef.current; if (!source) { @@ -7704,15 +7794,15 @@ function usePopupViewport(parameters) { children }, currentContentKey); } else { - childrenToRender = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(React38.Fragment, { + childrenToRender = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(React37.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { "data-previous": true, inert: inertValue(true), ref: previousContainerRef, style: { ...previousContentDimensions ? { - [cssVars.popupWidth]: `${previousContentDimensions.width}px`, - [cssVars.popupHeight]: `${previousContentDimensions.height}px` + "--popup-width": `${previousContentDimensions.width}px`, + "--popup-height": `${previousContentDimensions.height}px` } : null, position: "absolute" }, @@ -7783,10 +7873,10 @@ function calculateRelativePosition(from, to) { }; } function usePopupContentKey(activeTriggerId, payload) { - const [contentKey, setContentKey] = React38.useState(0); - const previousActiveTriggerIdRef = React38.useRef(activeTriggerId); - const previousPayloadRef = React38.useRef(payload); - const pendingPayloadUpdateRef = React38.useRef(false); + const [contentKey, setContentKey] = React37.useState(0); + const previousActiveTriggerIdRef = React37.useRef(activeTriggerId); + const previousPayloadRef = React37.useRef(payload); + const pendingPayloadUpdateRef = React37.useRef(false); useIsoLayoutEffect(() => { const previousActiveTriggerId = previousActiveTriggerIdRef.current; const previousPayload = previousPayloadRef.current; @@ -7806,10 +7896,10 @@ function usePopupContentKey(activeTriggerId, payload) { } // node_modules/@base-ui/react/utils/FloatingPortalLite.mjs -var React39 = __toESM(require_react(), 1); +var React38 = __toESM(require_react(), 1); var ReactDOM7 = __toESM(require_react_dom(), 1); var import_jsx_runtime7 = __toESM(require_jsx_runtime(), 1); -var FloatingPortalLite = /* @__PURE__ */ React39.forwardRef(function FloatingPortalLite2(componentProps, forwardedRef) { +var FloatingPortalLite = /* @__PURE__ */ React38.forwardRef(function FloatingPortalLite2(componentProps, forwardedRef) { const { children, container, @@ -7819,8 +7909,8 @@ var FloatingPortalLite = /* @__PURE__ */ React39.forwardRef(function FloatingPor ...elementProps } = componentProps; const { - portalNode, - portalSubtree + node: portalNode, + subtree: portalSubtree } = useFloatingPortalNode({ container, ref: forwardedRef, @@ -7830,7 +7920,7 @@ var FloatingPortalLite = /* @__PURE__ */ React39.forwardRef(function FloatingPor if (!portalSubtree && !portalNode) { return null; } - return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(React39.Fragment, { + return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(React38.Fragment, { children: [portalSubtree, portalNode && /* @__PURE__ */ ReactDOM7.createPortal(children, portalNode)] }); }); @@ -7852,14 +7942,14 @@ __export(index_parts_exports, { }); // node_modules/@base-ui/react/tooltip/root/TooltipRoot.mjs -var React42 = __toESM(require_react(), 1); +var React41 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/root/TooltipRootContext.mjs -var React40 = __toESM(require_react(), 1); -var TooltipRootContext = /* @__PURE__ */ React40.createContext(void 0); +var React39 = __toESM(require_react(), 1); +var TooltipRootContext = /* @__PURE__ */ React39.createContext(void 0); if (true) TooltipRootContext.displayName = "TooltipRootContext"; function useTooltipRootContext(optional) { - const context = React40.useContext(TooltipRootContext); + const context = React39.useContext(TooltipRootContext); if (context === void 0 && !optional) { throw new Error(true ? "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within ." : formatErrorMessage_default(72)); } @@ -7867,33 +7957,23 @@ function useTooltipRootContext(optional) { } // node_modules/@base-ui/react/tooltip/store/TooltipStore.mjs -var React41 = __toESM(require_react(), 1); +var React40 = __toESM(require_react(), 1); var selectors2 = { ...popupStoreSelectors, - disabled: createSelector((state) => state.disabled), - instantType: createSelector((state) => state.instantType), - isInstantPhase: createSelector((state) => state.isInstantPhase), - trackCursorAxis: createSelector((state) => state.trackCursorAxis), - disableHoverablePopup: createSelector((state) => state.disableHoverablePopup), - lastOpenChangeReason: createSelector((state) => state.openChangeReason), - closeOnClick: createSelector((state) => state.closeOnClick), - closeDelay: createSelector((state) => state.closeDelay), - hasViewport: createSelector((state) => state.hasViewport) + disabled: (state) => state.disabled, + instantType: (state) => state.instantType, + isInstantPhase: (state) => state.isInstantPhase, + trackCursorAxis: (state) => state.trackCursorAxis, + disableHoverablePopup: (state) => state.disableHoverablePopup, + lastOpenChangeReason: (state) => state.openChangeReason, + closeOnClick: (state) => state.closeOnClick, + closeDelay: (state) => state.closeDelay, + adaptiveOrigin: (state) => state.adaptiveOrigin }; -var TooltipStore = class _TooltipStore extends ReactStore { - constructor(initialState, floatingId, nested = false) { +var TooltipStore = class extends ReactStore { + constructor(initialState, floatingId, nested) { const triggerElements = new PopupTriggerMap(); - const state = { - ...createInitialState(), - ...initialState - }; - state.floatingRootContext = createPopupFloatingRootContext(triggerElements, floatingId, nested); - super(state, { - popupRef: /* @__PURE__ */ React41.createRef(), - onOpenChange: void 0, - onOpenChangeComplete: void 0, - triggerElements - }, selectors2); + super(createInitialState(initialState, triggerElements, floatingId, nested), createInitialContext(triggerElements), selectors2); } setOpen = (nextOpen, eventDetails) => { applyPopupOpenChange(this, nextOpen, eventDetails, { @@ -7906,13 +7986,17 @@ var TooltipStore = class _TooltipStore extends ReactStore { cancelPendingOpen(event) { this.state.floatingRootContext.dispatchOpenChange(false, createChangeEventDetails(reason_parts_exports.triggerPress, event)); } - static useStore(externalStore, initialState) { - const store2 = usePopupStore(externalStore, (floatingId, nested) => new _TooltipStore(initialState, floatingId, nested)).store; - return store2; - } }; -function createInitialState() { - return { +function createNullTooltipStore() { + const triggerElements = new PopupTriggerMap(); + const store2 = new NullStore(Object.freeze(createInitialState(void 0, triggerElements)), Object.freeze(createInitialContext(triggerElements)), selectors2); + return Object.assign(store2, { + setOpen: NOOP, + cancelPendingOpen: NOOP + }); +} +function createInitialState(initialState, triggerElements, floatingId, nested = false) { + const state = { ...createInitialPopupStoreState(), disabled: false, instantType: void 0, @@ -7922,7 +8006,18 @@ function createInitialState() { openChangeReason: null, closeOnClick: true, closeDelay: 0, - hasViewport: false + adaptiveOrigin: void 0, + ...initialState + }; + state.floatingRootContext = createPopupFloatingRootContext(triggerElements, floatingId, nested); + return state; +} +function createInitialContext(triggerElements) { + return { + popupRef: /* @__PURE__ */ React40.createRef(), + onOpenChange: void 0, + onOpenChangeComplete: void 0, + triggerElements }; } @@ -7943,13 +8038,12 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { defaultTriggerId: defaultTriggerIdProp = null, children } = props; - const store2 = TooltipStore.useStore(handle?.store, { + const store2 = usePopupRootStore((floatingId, nested) => new TooltipStore({ open: defaultOpen, openProp, activeTriggerId: defaultTriggerIdProp, triggerIdProp - }); - useInitialOpenSync(store2, openProp, defaultOpen, defaultTriggerIdProp); + }, floatingId, nested)); store2.useControlledProp("openProp", openProp); store2.useControlledProp("triggerIdProp", triggerIdProp); store2.useContextCallback("onOpenChange", onOpenChange); @@ -7961,9 +8055,9 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { const payload = store2.useState("payload"); store2.useSyncedValues({ trackCursorAxis, - disableHoverablePopup + disableHoverablePopup, + disabled: disabled2 }); - store2.useSyncedValue("disabled", disabled2); useImplicitActiveTrigger(store2, { closeOnActiveTriggerUnmount: true }); @@ -7974,7 +8068,7 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { const isInstantPhase = store2.useState("isInstantPhase"); const instantType = store2.useState("instantType"); const lastOpenChangeReason = store2.useState("lastOpenChangeReason"); - const previousInstantTypeRef = React42.useRef(null); + const previousInstantTypeRef = React41.useRef(null); useIsoLayoutEffect(() => { if (openState && disabled2) { store2.setOpen(false, createChangeEventDetails(reason_parts_exports.disabled)); @@ -7998,17 +8092,17 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { } } }, [store2, activeTriggerId, open]); - const handleImperativeClose = React42.useCallback(() => { - store2.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction)); - }, [store2]); - React42.useImperativeHandle(actionsRef, () => ({ + React41.useImperativeHandle(actionsRef, () => ({ unmount: forceUnmount, - close: handleImperativeClose - }), [forceUnmount, handleImperativeClose]); + close: () => store2.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction)) + }), [forceUnmount, store2]); const shouldRenderInteractions = open || mounted || !disabled2 && trackCursorAxis !== "none"; return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(TooltipRootContext.Provider, { value: store2, - children: [shouldRenderInteractions && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TooltipInteractions, { + children: [handle && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(PopupHandleAttachment, { + handle, + store: store2 + }), shouldRenderInteractions && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TooltipInteractions, { store: store2, disabled: disabled2, trackCursorAxis @@ -8032,35 +8126,26 @@ function TooltipInteractions({ enabled: !disabled2 && trackCursorAxis !== "none", axis: trackCursorAxis === "none" ? void 0 : trackCursorAxis }); - const activeTriggerProps = React42.useMemo(() => mergeProps(clientPoint.reference, dismiss.reference), [clientPoint.reference, dismiss.reference]); - const inactiveTriggerProps = React42.useMemo(() => mergeProps(clientPoint.trigger, dismiss.trigger), [clientPoint.trigger, dismiss.trigger]); - const popupProps = React42.useMemo(() => mergeProps(FOCUSABLE_POPUP_PROPS, clientPoint.floating, dismiss.floating), [clientPoint.floating, dismiss.floating]); + const triggerProps = React41.useMemo(() => mergeProps(clientPoint.reference, dismiss.reference), [clientPoint.reference, dismiss.reference]); usePopupInteractionProps(store2, { - activeTriggerProps, - inactiveTriggerProps, - popupProps + activeTriggerProps: triggerProps, + inactiveTriggerProps: triggerProps, + popupProps: dismiss.floating ?? EMPTY_OBJECT }); return null; } // node_modules/@base-ui/react/tooltip/trigger/TooltipTrigger.mjs -var React44 = __toESM(require_react(), 1); +var React43 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/provider/TooltipProviderContext.mjs -var React43 = __toESM(require_react(), 1); -var TooltipProviderContext = /* @__PURE__ */ React43.createContext(void 0); +var React42 = __toESM(require_react(), 1); +var TooltipProviderContext = /* @__PURE__ */ React42.createContext(void 0); if (true) TooltipProviderContext.displayName = "TooltipProviderContext"; function useTooltipProviderContext() { - return React43.useContext(TooltipProviderContext); + return React42.useContext(TooltipProviderContext); } -// node_modules/@base-ui/react/tooltip/trigger/TooltipTriggerDataAttributes.mjs -var TooltipTriggerDataAttributes = (function(TooltipTriggerDataAttributes2) { - TooltipTriggerDataAttributes2[TooltipTriggerDataAttributes2["popupOpen"] = CommonTriggerDataAttributes.popupOpen] = "popupOpen"; - TooltipTriggerDataAttributes2["triggerDisabled"] = "data-trigger-disabled"; - return TooltipTriggerDataAttributes2; -})({}); - // node_modules/@base-ui/react/tooltip/utils/constants.mjs var OPEN_DELAY = 600; @@ -8085,13 +8170,9 @@ function getTargetElement(event) { function closestEnabledTooltipTrigger(element) { let current = element; while (current) { - if (current.hasAttribute(TOOLTIP_TRIGGER_IDENTIFIER)) { - return current; - } - const parentElement = current.parentElement; - if (parentElement) { - current = parentElement; - continue; + const trigger = current.closest(`[${TOOLTIP_TRIGGER_IDENTIFIER}]`); + if (trigger) { + return trigger; } const root = current.getRootNode(); current = "host" in root && isElement(root.host) ? root.host : null; @@ -8113,7 +8194,8 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f ...elementProps } = componentProps; const rootContext = useTooltipRootContext(true); - const store2 = handle?.store ?? rootContext; + const handleStore = usePopupHandleStore(handle); + const store2 = handleStore ?? rootContext; if (!store2) { throw new Error(true ? "Base UI: must be either used within a component or provided with a handle." : formatErrorMessage_default(82)); } @@ -8121,7 +8203,7 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f const isTriggerActive = store2.useState("isTriggerActive", thisTriggerId); const isOpenedByThisTrigger = store2.useState("isOpenedByTrigger", thisTriggerId); const floatingRootContext = store2.useState("floatingRootContext"); - const triggerElementRef = React44.useRef(null); + const triggerElementRef = React43.useRef(null); const delayWithDefault = delay ?? OPEN_DELAY; const closeDelayWithDefault = closeDelay ?? 0; const { @@ -8132,7 +8214,7 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f closeOnClick, closeDelay: closeDelayWithDefault }); - const providerContext = useTooltipProviderContext(); + const providerDelay = useTooltipProviderContext(); const { delayRef, isInstantPhase, @@ -8147,21 +8229,14 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f const disabledRef = useValueAsRef(disabled2); const trackCursorAxis = store2.useState("trackCursorAxis"); const disableHoverablePopup = store2.useState("disableHoverablePopup"); - const isNestedTriggerHoveredRef = React44.useRef(false); + const isNestedTriggerHoveredRef = React43.useRef(false); const nestedTriggerOpenTimeout = useTimeout(); - const pointerTypeRef = React44.useRef(void 0); + const pointerTypeRef = React43.useRef(void 0); function getOpenDelay() { - const providerDelay = providerContext?.delay; - const groupOpenValue = typeof delayRef.current === "object" ? delayRef.current.open : void 0; - let computedOpenDelay = delayWithDefault; - if (hasProvider) { - if (groupOpenValue !== 0) { - computedOpenDelay = delay ?? providerDelay ?? delayWithDefault; - } else { - computedOpenDelay = 0; - } + if (!hasProvider) { + return delayWithDefault; } - return computedOpenDelay; + return getDelay(delayRef.current, "open") === 0 ? 0 : delay ?? providerDelay ?? OPEN_DELAY; } function isEnabledNestedTriggerTarget(target) { const triggerEl = triggerElementRef.current; @@ -8189,13 +8264,13 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f handleClose: !disableHoverablePopup && trackCursorAxis !== "both" ? safePolygon() : null, restMs: getOpenDelay, delay() { - const closeValue = typeof delayRef.current === "object" ? delayRef.current.close : void 0; - let computedCloseDelay = closeDelayWithDefault; if (closeDelay == null && hasProvider) { - computedCloseDelay = closeValue; + return { + close: getDelay(delayRef.current, "close") + }; } return { - close: computedCloseDelay + close: closeDelayWithDefault }; }, triggerElementRef, @@ -8272,7 +8347,7 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f } }, id: thisTriggerId, - [TooltipTriggerDataAttributes.triggerDisabled]: disabled2 ? "" : void 0, + "data-trigger-disabled": disabled2 ? "" : void 0, [TOOLTIP_TRIGGER_IDENTIFIER]: disabled2 ? void 0 : "" }, elementProps], stateAttributesMapping: triggerOpenStateMapping @@ -8282,14 +8357,14 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f if (true) TooltipTrigger.displayName = "TooltipTrigger"; // node_modules/@base-ui/react/tooltip/portal/TooltipPortal.mjs -var React46 = __toESM(require_react(), 1); +var React45 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/portal/TooltipPortalContext.mjs -var React45 = __toESM(require_react(), 1); -var TooltipPortalContext = /* @__PURE__ */ React45.createContext(void 0); +var React44 = __toESM(require_react(), 1); +var TooltipPortalContext = /* @__PURE__ */ React44.createContext(void 0); if (true) TooltipPortalContext.displayName = "TooltipPortalContext"; function useTooltipPortalContext() { - const value = React45.useContext(TooltipPortalContext); + const value = React44.useContext(TooltipPortalContext); if (value === void 0) { throw new Error(true ? "Base UI: is missing." : formatErrorMessage_default(70)); } @@ -8298,7 +8373,7 @@ function useTooltipPortalContext() { // node_modules/@base-ui/react/tooltip/portal/TooltipPortal.mjs var import_jsx_runtime9 = __toESM(require_jsx_runtime(), 1); -var TooltipPortal = /* @__PURE__ */ React46.forwardRef(function TooltipPortal2(props, forwardedRef) { +var TooltipPortal = /* @__PURE__ */ React45.forwardRef(function TooltipPortal2(props, forwardedRef) { const { keepMounted = false, ...portalProps @@ -8320,14 +8395,14 @@ var TooltipPortal = /* @__PURE__ */ React46.forwardRef(function TooltipPortal2(p if (true) TooltipPortal.displayName = "TooltipPortal"; // node_modules/@base-ui/react/tooltip/positioner/TooltipPositioner.mjs -var React48 = __toESM(require_react(), 1); +var React47 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/positioner/TooltipPositionerContext.mjs -var React47 = __toESM(require_react(), 1); -var TooltipPositionerContext = /* @__PURE__ */ React47.createContext(void 0); +var React46 = __toESM(require_react(), 1); +var TooltipPositionerContext = /* @__PURE__ */ React46.createContext(void 0); if (true) TooltipPositionerContext.displayName = "TooltipPositionerContext"; function useTooltipPositionerContext() { - const context = React47.useContext(TooltipPositionerContext); + const context = React46.useContext(TooltipPositionerContext); if (context === void 0) { throw new Error(true ? "Base UI: TooltipPositionerContext is missing. TooltipPositioner parts must be placed within ." : formatErrorMessage_default(71)); } @@ -8336,7 +8411,7 @@ function useTooltipPositionerContext() { // node_modules/@base-ui/react/tooltip/positioner/TooltipPositioner.mjs var import_jsx_runtime10 = __toESM(require_jsx_runtime(), 1); -var TooltipPositioner = /* @__PURE__ */ React48.forwardRef(function TooltipPositioner2(componentProps, forwardedRef) { +var TooltipPositioner = /* @__PURE__ */ React47.forwardRef(function TooltipPositioner2(componentProps, forwardedRef) { const { render, className, @@ -8364,7 +8439,7 @@ var TooltipPositioner = /* @__PURE__ */ React48.forwardRef(function TooltipPosit const floatingRootContext = store2.useState("floatingRootContext"); const instantType = store2.useState("instantType"); const transitionStatus = store2.useState("transitionStatus"); - const hasViewport = store2.useState("hasViewport"); + const adaptiveOrigin2 = store2.useState("adaptiveOrigin"); const positioning = useAnchorPositioning({ anchor, positionMethod, @@ -8381,9 +8456,9 @@ var TooltipPositioner = /* @__PURE__ */ React48.forwardRef(function TooltipPosit disableAnchorTracking, keepMounted, collisionAvoidance, - adaptiveOrigin: hasViewport ? adaptiveOrigin : void 0 + adaptiveOrigin: adaptiveOrigin2 }); - const state = React48.useMemo(() => ({ + const state = React47.useMemo(() => ({ open, side: positioning.side, align: positioning.align, @@ -8406,12 +8481,8 @@ var TooltipPositioner = /* @__PURE__ */ React48.forwardRef(function TooltipPosit if (true) TooltipPositioner.displayName = "TooltipPositioner"; // node_modules/@base-ui/react/tooltip/popup/TooltipPopup.mjs -var React49 = __toESM(require_react(), 1); -var stateAttributesMapping = { - ...popupStateMapping, - ...transitionStatusMapping -}; -var TooltipPopup = /* @__PURE__ */ React49.forwardRef(function TooltipPopup2(componentProps, forwardedRef) { +var React48 = __toESM(require_react(), 1); +var TooltipPopup = /* @__PURE__ */ React48.forwardRef(function TooltipPopup2(componentProps, forwardedRef) { const { render, className, @@ -8454,16 +8525,16 @@ var TooltipPopup = /* @__PURE__ */ React49.forwardRef(function TooltipPopup2(com const element = useRenderElement("div", componentProps, { state, ref: [forwardedRef, store2.context.popupRef, setPopupElement], - props: [popupProps, getDisabledMountTransitionStyles(transitionStatus), elementProps], - stateAttributesMapping + props: [FOCUSABLE_POPUP_PROPS, popupProps, getDisabledMountTransitionStyles(transitionStatus), elementProps], + stateAttributesMapping: popupTransitionStateMapping }); return element; }); if (true) TooltipPopup.displayName = "TooltipPopup"; // node_modules/@base-ui/react/tooltip/arrow/TooltipArrow.mjs -var React50 = __toESM(require_react(), 1); -var TooltipArrow = /* @__PURE__ */ React50.forwardRef(function TooltipArrow2(componentProps, forwardedRef) { +var React49 = __toESM(require_react(), 1); +var TooltipArrow = /* @__PURE__ */ React49.forwardRef(function TooltipArrow2(componentProps, forwardedRef) { const { render, className, @@ -8501,7 +8572,7 @@ var TooltipArrow = /* @__PURE__ */ React50.forwardRef(function TooltipArrow2(com if (true) TooltipArrow.displayName = "TooltipArrow"; // node_modules/@base-ui/react/tooltip/provider/TooltipProvider.mjs -var React51 = __toESM(require_react(), 1); +var React50 = __toESM(require_react(), 1); var import_jsx_runtime11 = __toESM(require_jsx_runtime(), 1); var TooltipProvider = function TooltipProvider2(props) { const { @@ -8509,16 +8580,12 @@ var TooltipProvider = function TooltipProvider2(props) { closeDelay, timeout = 400 } = props; - const contextValue = React51.useMemo(() => ({ - delay, - closeDelay - }), [delay, closeDelay]); - const delayValue = React51.useMemo(() => ({ + const delayValue = React50.useMemo(() => ({ open: delay, close: closeDelay }), [delay, closeDelay]); return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TooltipProviderContext.Provider, { - value: contextValue, + value: delay, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(FloatingDelayGroup, { delay: delayValue, timeoutMs: timeout, @@ -8529,22 +8596,8 @@ var TooltipProvider = function TooltipProvider2(props) { if (true) TooltipProvider.displayName = "TooltipProvider"; // node_modules/@base-ui/react/tooltip/viewport/TooltipViewport.mjs -var React52 = __toESM(require_react(), 1); - -// node_modules/@base-ui/react/tooltip/viewport/TooltipViewportCssVars.mjs -var TooltipViewportCssVars = /* @__PURE__ */ (function(TooltipViewportCssVars2) { - TooltipViewportCssVars2["popupWidth"] = "--popup-width"; - TooltipViewportCssVars2["popupHeight"] = "--popup-height"; - return TooltipViewportCssVars2; -})({}); - -// node_modules/@base-ui/react/tooltip/viewport/TooltipViewport.mjs -var stateAttributesMapping2 = { - activationDirection: (value) => value ? { - "data-activation-direction": value - } : null -}; -var TooltipViewport = /* @__PURE__ */ React52.forwardRef(function TooltipViewport2(componentProps, forwardedRef) { +var React51 = __toESM(require_react(), 1); +var TooltipViewport = /* @__PURE__ */ React51.forwardRef(function TooltipViewport2(componentProps, forwardedRef) { const { render, className, @@ -8561,7 +8614,6 @@ var TooltipViewport = /* @__PURE__ */ React52.forwardRef(function TooltipViewpor } = usePopupViewport({ store: store2, side: positioner.side, - cssVars: TooltipViewportCssVars, children }); const state = { @@ -8575,46 +8627,40 @@ var TooltipViewport = /* @__PURE__ */ React52.forwardRef(function TooltipViewpor props: [elementProps, { children: childrenToRender }], - stateAttributesMapping: stateAttributesMapping2 + stateAttributesMapping: popupViewportStateMapping }); }); if (true) TooltipViewport.displayName = "TooltipViewport"; // node_modules/@base-ui/react/tooltip/store/TooltipHandle.mjs -var TooltipHandle = class { - /** - * Internal store holding the tooltip state. - * @internal - */ +var TooltipHandle = class extends BasePopupHandle { constructor() { - this.store = new TooltipStore(); + super(createNullTooltipStore(), "Tooltip"); } /** - * Opens the tooltip and associates it with the trigger with the given ID. - * The trigger must be a Tooltip.Trigger component with this handle passed as a prop. + * Opens the tooltip and associates it with the trigger with the given id. * * This method should only be called in an event handler or an effect (not during rendering). * - * @param triggerId ID of the trigger to associate with the tooltip. + * @param triggerId ID of the trigger to associate with the tooltip. The trigger must be a matching + * `Tooltip.Trigger` with this handle passed as a prop. */ open(triggerId) { - const triggerElement = triggerId ? this.store.context.triggerElements.getById(triggerId) : void 0; - if (triggerId && !triggerElement) { - throw new Error(true ? `Base UI: TooltipHandle.open: No trigger found with id "${triggerId}".` : formatErrorMessage_default(81, triggerId)); - } - this.store.setOpen(true, createChangeEventDetails(reason_parts_exports.imperativeAction, void 0, triggerElement)); + this.openByTrigger(triggerId); } /** * Closes the tooltip. + * + * This method should only be called in an event handler or an effect (not during rendering). */ close() { - this.store.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction, void 0, void 0)); + this.closePopup(); } /** - * Indicates whether the tooltip is currently open. + * Whether the tooltip is currently open. Returns `false` while no root is attached to the handle. */ get isOpen() { - return this.store.select("open"); + return this.attachedStore?.select("open") ?? false; } }; function createTooltipHandle() { @@ -8922,7 +8968,7 @@ function registerStyle3(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle3("b74f1ac304", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);inset-inline-start:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); + registerStyle3("effc4e3032", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); } var style_default3 = { "button": "_97b0fc33c028be1a__button", "is-unstyled": "abbb272e2ce49bd6__is-unstyled", "is-loading": "_914b42f315c0e580__is-loading", "is-small": "_908205475f9f2a92__is-small", "icon": "_9f6fc6553aeb36fe__icon", "is-brand": "dd460c965226cc77__is-brand", "is-outline": "_62d5a778b7b258ee__is-outline", "is-minimal": "ad0619a3217c6a5b__is-minimal", "is-neutral": "e722a8f96726aa99__is-neutral", "is-solid": "b50b3358c5fb4d0b__is-solid", "is-compact": "cf59cf1b69629838__is-compact", "loading-animation": "_5a1d53da6f830c8d__loading-animation" }; if (typeof process === "undefined" || true) { @@ -8930,7 +8976,7 @@ if (typeof process === "undefined" || true) { } var resets_default = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; if (typeof process === "undefined" || true) { - registerStyle3("2ffedd8246", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); + registerStyle3("96553466c8", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); } var focus_module_default = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-within-visible": "_64de9947bf305b7a__outset-ring--focus-within-visible", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; if (typeof process === "undefined" || true) { @@ -9083,7 +9129,7 @@ function registerStyle4(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle4("b74f1ac304", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);inset-inline-start:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); + registerStyle4("effc4e3032", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); } var style_default4 = { "button": "_97b0fc33c028be1a__button", "is-unstyled": "abbb272e2ce49bd6__is-unstyled", "is-loading": "_914b42f315c0e580__is-loading", "is-small": "_908205475f9f2a92__is-small", "icon": "_9f6fc6553aeb36fe__icon", "is-brand": "dd460c965226cc77__is-brand", "is-outline": "_62d5a778b7b258ee__is-outline", "is-minimal": "ad0619a3217c6a5b__is-minimal", "is-neutral": "e722a8f96726aa99__is-neutral", "is-solid": "b50b3358c5fb4d0b__is-solid", "is-compact": "cf59cf1b69629838__is-compact", "loading-animation": "_5a1d53da6f830c8d__loading-animation" }; var ButtonIcon = (0, import_element14.forwardRef)( @@ -9136,41 +9182,16 @@ var import_primitives6 = __toESM(require_primitives(), 1); var import_jsx_runtime20 = __toESM(require_jsx_runtime(), 1); var published_default = /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives6.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives6.Path, { fillRule: "evenodd", clipRule: "evenodd", d: "M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm11.53-1.47-1.06-1.06L11 12.94l-1.47-1.47-1.06 1.06L11 15.06l4.53-4.53Z" }) }); -// packages/ui/build-module/utils/render-slot-with-children.mjs -var import_element15 = __toESM(require_element(), 1); -function renderSlotWithChildren(slot, defaultSlot, children) { - return (0, import_element15.cloneElement)(slot ?? defaultSlot, { children }); -} - -// packages/ui/build-module/utils/theme-provider.mjs -var theme = __toESM(require_theme(), 1); +// packages/ui/build-module/icon-button/icon-button.mjs +var import_element22 = __toESM(require_element(), 1); -// packages/ui/build-module/lock-unlock.mjs -var import_private_apis = __toESM(require_private_apis(), 1); -var { lock, unlock } = (0, import_private_apis.__dangerousOptInToUnstableAPIsOnlyForCoreModules)( - "I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.", - "@wordpress/ui" -); +// packages/ui/build-module/tooltip/popup.mjs +var import_element18 = __toESM(require_element(), 1); -// packages/ui/build-module/utils/theme-provider.mjs -function getThemeProvider() { - const themePackage = theme; - if (themePackage.ThemeProvider) { - return themePackage.ThemeProvider; - } - if (!themePackage.privateApis) { - throw new Error( - "@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`." - ); - } - return unlock( - themePackage.privateApis - ).ThemeProvider; -} -var ThemeProvider = getThemeProvider(); +// packages/ui/build-module/tooltip/portal.mjs +var import_element15 = __toESM(require_element(), 1); -// packages/ui/build-module/stack/stack.mjs -var import_element16 = __toESM(require_element(), 1); +// packages/ui/build-module/utils/wp-compat-overlay-slot.mjs var STYLE_HASH_ATTRIBUTE5 = "data-wp-hash"; function getRuntime5() { const globalScope = globalThis; @@ -9252,126 +9273,7 @@ function registerStyle5(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle5("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); -} -var style_default5 = { "stack": "_19ce0419607e1896__stack" }; -var gapTokens = { - xs: "var(--wpds-dimension-gap-xs, 4px)", - sm: "var(--wpds-dimension-gap-sm, 8px)", - md: "var(--wpds-dimension-gap-md, 12px)", - lg: "var(--wpds-dimension-gap-lg, 16px)", - xl: "var(--wpds-dimension-gap-xl, 24px)", - "2xl": "var(--wpds-dimension-gap-2xl, 32px)", - "3xl": "var(--wpds-dimension-gap-3xl, 40px)" -}; -var Stack = (0, import_element16.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { - const style = { - gap: gap && gapTokens[gap], - alignItems: align, - justifyContent: justify, - flexDirection: direction, - flexWrap: wrap - }; - const element = useRender({ - render, - ref, - props: mergeProps(props, { style, className: style_default5.stack }) - }); - return element; -}); - -// packages/ui/build-module/icon-button/icon-button.mjs -var import_element23 = __toESM(require_element(), 1); - -// packages/ui/build-module/tooltip/popup.mjs -var import_element19 = __toESM(require_element(), 1); - -// packages/ui/build-module/tooltip/portal.mjs -var import_element17 = __toESM(require_element(), 1); - -// packages/ui/build-module/utils/wp-compat-overlay-slot.mjs -var STYLE_HASH_ATTRIBUTE6 = "data-wp-hash"; -function getRuntime6() { - const globalScope = globalThis; - if (globalScope.__wpStyleRuntime) { - return globalScope.__wpStyleRuntime; - } - globalScope.__wpStyleRuntime = { - documents: /* @__PURE__ */ new Map(), - styles: /* @__PURE__ */ new Map(), - injectedStyles: /* @__PURE__ */ new WeakMap() - }; - if (typeof document !== "undefined") { - registerDocument6(document); - } - return globalScope.__wpStyleRuntime; -} -function documentContainsStyleHash6(targetDocument, hash) { - if (!targetDocument.head) { - return false; - } - for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE6}]` - )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE6) === hash) { - return true; - } - } - return false; -} -function injectStyle6(targetDocument, hash, css) { - if (!targetDocument.head) { - return; - } - const runtime = getRuntime6(); - let injectedStyles = runtime.injectedStyles.get(targetDocument); - if (!injectedStyles) { - injectedStyles = /* @__PURE__ */ new Set(); - runtime.injectedStyles.set(targetDocument, injectedStyles); - } - if (injectedStyles.has(hash)) { - return; - } - if (documentContainsStyleHash6(targetDocument, hash)) { - injectedStyles.add(hash); - return; - } - const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE6, hash); - style.appendChild(targetDocument.createTextNode(css)); - targetDocument.head.appendChild(style); - injectedStyles.add(hash); -} -function registerDocument6(targetDocument) { - const runtime = getRuntime6(); - runtime.documents.set( - targetDocument, - (runtime.documents.get(targetDocument) ?? 0) + 1 - ); - for (const [hash, css] of runtime.styles) { - injectStyle6(targetDocument, hash, css); - } - return () => { - const count = runtime.documents.get(targetDocument); - if (count === void 0) { - return; - } - if (count <= 1) { - runtime.documents.delete(targetDocument); - return; - } - runtime.documents.set(targetDocument, count - 1); - }; -} -function registerStyle6(hash, css) { - const runtime = getRuntime6(); - runtime.styles.set(hash, css); - for (const targetDocument of runtime.documents.keys()) { - injectStyle6(targetDocument, hash, css); - } -} -if (typeof process === "undefined" || true) { - registerStyle6("be37f31c1e", "._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}"); + registerStyle5("be37f31c1e", "._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}"); } var wp_compat_overlay_slot_default = { "slot": "_11fc52b637ff8a7e__slot" }; var WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE = "data-wp-compat-overlay-slot"; @@ -9431,7 +9333,7 @@ function getWpCompatOverlaySlot() { // packages/ui/build-module/tooltip/portal.mjs var import_jsx_runtime21 = __toESM(require_jsx_runtime(), 1); -var Portal = (0, import_element17.forwardRef)( +var Portal = (0, import_element15.forwardRef)( function TooltipPortal3({ container, ...restProps }, ref) { return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)( index_parts_exports.Portal, @@ -9445,10 +9347,10 @@ var Portal = (0, import_element17.forwardRef)( ); // packages/ui/build-module/tooltip/positioner.mjs -var import_element18 = __toESM(require_element(), 1); +var import_element16 = __toESM(require_element(), 1); var import_jsx_runtime22 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE7 = "data-wp-hash"; -function getRuntime7() { +var STYLE_HASH_ATTRIBUTE6 = "data-wp-hash"; +function getRuntime6() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9459,28 +9361,28 @@ function getRuntime7() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument7(document); + registerDocument6(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash7(targetDocument, hash) { +function documentContainsStyleHash6(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE7}]` + `style[${STYLE_HASH_ATTRIBUTE6}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE7) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE6) === hash) { return true; } } return false; } -function injectStyle7(targetDocument, hash, css) { +function injectStyle6(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime7(); + const runtime = getRuntime6(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9489,24 +9391,24 @@ function injectStyle7(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash7(targetDocument, hash)) { + if (documentContainsStyleHash6(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE7, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE6, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument7(targetDocument) { - const runtime = getRuntime7(); +function registerDocument6(targetDocument) { + const runtime = getRuntime6(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle7(targetDocument, hash, css); + injectStyle6(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9520,22 +9422,22 @@ function registerDocument7(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle7(hash, css) { - const runtime = getRuntime7(); +function registerStyle6(hash, css) { + const runtime = getRuntime6(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle7(targetDocument, hash, css); + injectStyle6(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle7("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); + registerStyle6("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); } var resets_default2 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; if (typeof process === "undefined" || true) { - registerStyle7("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); + registerStyle6("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); } -var style_default6 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; -var Positioner = (0, import_element18.forwardRef)( +var style_default5 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; +var Positioner = (0, import_element16.forwardRef)( function TooltipPositioner3({ align = "center", className, side = "top", sideOffset = 4, ...props }, ref) { return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)( index_parts_exports.Positioner, @@ -9547,7 +9449,7 @@ var Positioner = (0, import_element18.forwardRef)( ...props, className: clsx_default( resets_default2["box-sizing"], - style_default6.positioner, + style_default5.positioner, className ) } @@ -9555,10 +9457,43 @@ var Positioner = (0, import_element18.forwardRef)( } ); +// packages/ui/build-module/utils/render-slot-with-children.mjs +var import_element17 = __toESM(require_element(), 1); +function renderSlotWithChildren(slot, defaultSlot, children) { + return (0, import_element17.cloneElement)(slot ?? defaultSlot, { children }); +} + +// packages/ui/build-module/utils/theme-provider.mjs +var theme = __toESM(require_theme(), 1); + +// packages/ui/build-module/lock-unlock.mjs +var import_private_apis = __toESM(require_private_apis(), 1); +var { lock, unlock } = (0, import_private_apis.__dangerousOptInToUnstableAPIsOnlyForCoreModules)( + "I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.", + "@wordpress/ui" +); + +// packages/ui/build-module/utils/theme-provider.mjs +function getThemeProvider() { + const themePackage = theme; + if (themePackage.ThemeProvider) { + return themePackage.ThemeProvider; + } + if (!themePackage.privateApis) { + throw new Error( + "@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`." + ); + } + return unlock( + themePackage.privateApis + ).ThemeProvider; +} +var ThemeProvider = getThemeProvider(); + // packages/ui/build-module/tooltip/popup.mjs var import_jsx_runtime23 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE8 = "data-wp-hash"; -function getRuntime8() { +var STYLE_HASH_ATTRIBUTE7 = "data-wp-hash"; +function getRuntime7() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9569,28 +9504,28 @@ function getRuntime8() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument8(document); + registerDocument7(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash8(targetDocument, hash) { +function documentContainsStyleHash7(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE8}]` + `style[${STYLE_HASH_ATTRIBUTE7}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE8) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE7) === hash) { return true; } } return false; } -function injectStyle8(targetDocument, hash, css) { +function injectStyle7(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime8(); + const runtime = getRuntime7(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9599,24 +9534,24 @@ function injectStyle8(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash8(targetDocument, hash)) { + if (documentContainsStyleHash7(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE8, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE7, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument8(targetDocument) { - const runtime = getRuntime8(); +function registerDocument7(targetDocument) { + const runtime = getRuntime7(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle8(targetDocument, hash, css); + injectStyle7(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9630,24 +9565,24 @@ function registerDocument8(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle8(hash, css) { - const runtime = getRuntime8(); +function registerStyle7(hash, css) { + const runtime = getRuntime7(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle8(targetDocument, hash, css); + injectStyle7(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle8("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); + registerStyle7("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); } -var style_default7 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; +var style_default6 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; var POPUP_COLOR = { background: "#1e1e1e" }; -var Popup = (0, import_element19.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { +var Popup = (0, import_element18.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { const popupContent = /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(ThemeProvider, { color: POPUP_COLOR, children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)( index_parts_exports.Popup, { ref, - className: clsx_default(style_default7.popup, className), + className: clsx_default(style_default6.popup, className), ...props, children } @@ -9661,9 +9596,9 @@ var Popup = (0, import_element19.forwardRef)(function TooltipPopup3({ portal, po }); // packages/ui/build-module/tooltip/trigger.mjs -var import_element20 = __toESM(require_element(), 1); +var import_element19 = __toESM(require_element(), 1); var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); -var Trigger = (0, import_element20.forwardRef)( +var Trigger = (0, import_element19.forwardRef)( function TooltipTrigger3(props, ref) { return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(index_parts_exports.Trigger, { ref, ...props }); } @@ -9683,13 +9618,13 @@ function Root(props) { } // packages/ui/build-module/utils/keyboard-shortcut.mjs -var import_element22 = __toESM(require_element(), 1); +var import_element21 = __toESM(require_element(), 1); var import_i18n3 = __toESM(require_i18n(), 1); // packages/ui/build-module/visually-hidden/visually-hidden.mjs -var import_element21 = __toESM(require_element(), 1); -var STYLE_HASH_ATTRIBUTE9 = "data-wp-hash"; -function getRuntime9() { +var import_element20 = __toESM(require_element(), 1); +var STYLE_HASH_ATTRIBUTE8 = "data-wp-hash"; +function getRuntime8() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9700,28 +9635,28 @@ function getRuntime9() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument9(document); + registerDocument8(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash9(targetDocument, hash) { +function documentContainsStyleHash8(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE9}]` + `style[${STYLE_HASH_ATTRIBUTE8}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE9) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE8) === hash) { return true; } } return false; } -function injectStyle9(targetDocument, hash, css) { +function injectStyle8(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime9(); + const runtime = getRuntime8(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9730,24 +9665,24 @@ function injectStyle9(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash9(targetDocument, hash)) { + if (documentContainsStyleHash8(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE9, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE8, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument9(targetDocument) { - const runtime = getRuntime9(); +function registerDocument8(targetDocument) { + const runtime = getRuntime8(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle9(targetDocument, hash, css); + injectStyle8(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9761,24 +9696,24 @@ function registerDocument9(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle9(hash, css) { - const runtime = getRuntime9(); +function registerStyle8(hash, css) { + const runtime = getRuntime8(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle9(targetDocument, hash, css); + injectStyle8(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle9("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); + registerStyle8("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); } -var style_default8 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; -var VisuallyHidden = (0, import_element21.forwardRef)( +var style_default7 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; +var VisuallyHidden = (0, import_element20.forwardRef)( function VisuallyHidden2({ render, ...restProps }, ref) { const element = useRender({ render, ref, props: mergeProps( - { className: style_default8["visually-hidden"] }, + { className: style_default7["visually-hidden"] }, restProps, { // @ts-expect-error Arbitrary data-* attributes aren't indexable on the typed div props. Kept hardcoded so consumers can't change or remove it. @@ -9797,7 +9732,7 @@ function useKeyboardShortcutProps({ "aria-keyshortcuts": ariaKeyShortcuts, shortcut }) { - const generatedDescriptionId = (0, import_element22.useId)(); + const generatedDescriptionId = (0, import_element21.useId)(); const descriptionId = shortcut ? generatedDescriptionId : void 0; const describedBy = [ariaDescribedBy, descriptionId].filter(Boolean).join(" "); return { @@ -9808,16 +9743,13 @@ function useKeyboardShortcutProps({ } }; } -function KeyboardShortcutDescription({ - descriptionId, - shortcut -}) { +var KeyboardShortcutDescription = (0, import_element21.forwardRef)(function KeyboardShortcutDescription2({ descriptionId, shortcut }, ref) { return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( VisuallyHidden, { id: descriptionId, "aria-hidden": "true", - render: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", {}), + render: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { ref }), children: (0, import_i18n3.sprintf)( /* translators: %s: keyboard shortcut. */ (0, import_i18n3.__)("Keyboard shortcut: %s"), @@ -9825,18 +9757,15 @@ function KeyboardShortcutDescription({ ) } ); -} -function KeyboardShortcutDisplay({ - className, - shortcut -}) { - return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { "aria-hidden": "true", className, dir: "ltr", children: shortcut.displayShortcut }); -} +}); +var KeyboardShortcutDisplay = (0, import_element21.forwardRef)(function KeyboardShortcutDisplay2({ className, shortcut }, ref) { + return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { ref, "aria-hidden": "true", className, dir: "ltr", children: shortcut.displayShortcut }); +}); // packages/ui/build-module/icon-button/icon-button.mjs var import_jsx_runtime28 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE10 = "data-wp-hash"; -function getRuntime10() { +var STYLE_HASH_ATTRIBUTE9 = "data-wp-hash"; +function getRuntime9() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9847,28 +9776,28 @@ function getRuntime10() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument10(document); + registerDocument9(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash10(targetDocument, hash) { +function documentContainsStyleHash9(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE10}]` + `style[${STYLE_HASH_ATTRIBUTE9}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE10) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE9) === hash) { return true; } } return false; } -function injectStyle10(targetDocument, hash, css) { +function injectStyle9(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime10(); + const runtime = getRuntime9(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9877,24 +9806,24 @@ function injectStyle10(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash10(targetDocument, hash)) { + if (documentContainsStyleHash9(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE10, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE9, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument10(targetDocument) { - const runtime = getRuntime10(); +function registerDocument9(targetDocument) { + const runtime = getRuntime9(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle10(targetDocument, hash, css); + injectStyle9(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9908,18 +9837,18 @@ function registerDocument10(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle10(hash, css) { - const runtime = getRuntime10(); +function registerStyle9(hash, css) { + const runtime = getRuntime9(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle10(targetDocument, hash, css); + injectStyle9(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle10("c5cdafb1bc", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}"); + registerStyle9("c5cdafb1bc", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}"); } -var style_default9 = { "icon-button": "_28cfdc260e755391__icon-button", "icon": "f1c70d719989a85a__icon" }; -var IconButton = (0, import_element23.forwardRef)( +var style_default8 = { "icon-button": "_28cfdc260e755391__icon-button", "icon": "f1c70d719989a85a__icon" }; +var IconButton = (0, import_element22.forwardRef)( function IconButton2({ label, className, @@ -9935,7 +9864,7 @@ var IconButton = (0, import_element23.forwardRef)( "aria-keyshortcuts": ariaKeyShortcuts, ...restProps }, ref) { - const classes = clsx_default(style_default9["icon-button"], className); + const classes = clsx_default(style_default8["icon-button"], className); const { descriptionId, targetProps } = useKeyboardShortcutProps({ "aria-describedby": ariaDescribedBy, "aria-keyshortcuts": ariaKeyShortcuts, @@ -9960,7 +9889,7 @@ var IconButton = (0, import_element23.forwardRef)( ), className: classes, children: [ - /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { icon, size: 24, className: style_default9.icon }), + /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { icon, size: 24, className: style_default8.icon }), shortcut && descriptionId && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( KeyboardShortcutDescription, { @@ -9982,6 +9911,117 @@ var IconButton = (0, import_element23.forwardRef)( } ); +// packages/ui/build-module/stack/stack.mjs +var import_element23 = __toESM(require_element(), 1); +var STYLE_HASH_ATTRIBUTE10 = "data-wp-hash"; +function getRuntime10() { + const globalScope = globalThis; + if (globalScope.__wpStyleRuntime) { + return globalScope.__wpStyleRuntime; + } + globalScope.__wpStyleRuntime = { + documents: /* @__PURE__ */ new Map(), + styles: /* @__PURE__ */ new Map(), + injectedStyles: /* @__PURE__ */ new WeakMap() + }; + if (typeof document !== "undefined") { + registerDocument10(document); + } + return globalScope.__wpStyleRuntime; +} +function documentContainsStyleHash10(targetDocument, hash) { + if (!targetDocument.head) { + return false; + } + for (const style of targetDocument.head.querySelectorAll( + `style[${STYLE_HASH_ATTRIBUTE10}]` + )) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE10) === hash) { + return true; + } + } + return false; +} +function injectStyle10(targetDocument, hash, css) { + if (!targetDocument.head) { + return; + } + const runtime = getRuntime10(); + let injectedStyles = runtime.injectedStyles.get(targetDocument); + if (!injectedStyles) { + injectedStyles = /* @__PURE__ */ new Set(); + runtime.injectedStyles.set(targetDocument, injectedStyles); + } + if (injectedStyles.has(hash)) { + return; + } + if (documentContainsStyleHash10(targetDocument, hash)) { + injectedStyles.add(hash); + return; + } + const style = targetDocument.createElement("style"); + style.setAttribute(STYLE_HASH_ATTRIBUTE10, hash); + style.appendChild(targetDocument.createTextNode(css)); + targetDocument.head.appendChild(style); + injectedStyles.add(hash); +} +function registerDocument10(targetDocument) { + const runtime = getRuntime10(); + runtime.documents.set( + targetDocument, + (runtime.documents.get(targetDocument) ?? 0) + 1 + ); + for (const [hash, css] of runtime.styles) { + injectStyle10(targetDocument, hash, css); + } + return () => { + const count = runtime.documents.get(targetDocument); + if (count === void 0) { + return; + } + if (count <= 1) { + runtime.documents.delete(targetDocument); + return; + } + runtime.documents.set(targetDocument, count - 1); + }; +} +function registerStyle10(hash, css) { + const runtime = getRuntime10(); + runtime.styles.set(hash, css); + for (const targetDocument of runtime.documents.keys()) { + injectStyle10(targetDocument, hash, css); + } +} +if (typeof process === "undefined" || true) { + registerStyle10("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); +} +var style_default9 = { "stack": "_19ce0419607e1896__stack" }; +var gapTokens = { + xs: "var(--wpds-dimension-gap-xs, 4px)", + sm: "var(--wpds-dimension-gap-sm, 8px)", + md: "var(--wpds-dimension-gap-md, 12px)", + lg: "var(--wpds-dimension-gap-lg, 16px)", + xl: "var(--wpds-dimension-gap-xl, 24px)", + "2xl": "var(--wpds-dimension-gap-2xl, 32px)", + "3xl": "var(--wpds-dimension-gap-3xl, 40px)" +}; +var Stack = (0, import_element23.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { + const style = { + gap: gap && gapTokens[gap], + alignItems: align, + justifyContent: justify, + flexDirection: direction, + flexWrap: wrap + }; + const element = useRender({ + render, + ref, + props: mergeProps(props, { style, className: style_default9.stack }) + }); + return element; +}); + // packages/ui/build-module/link/link.mjs var import_element24 = __toESM(require_element(), 1); var import_i18n4 = __toESM(require_i18n(), 1); @@ -10071,7 +10111,7 @@ if (typeof process === "undefined" || true) { } var resets_default3 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; if (typeof process === "undefined" || true) { - registerStyle11("2ffedd8246", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); + registerStyle11("96553466c8", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); } var focus_module_default2 = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-within-visible": "_64de9947bf305b7a__outset-ring--focus-within-visible", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; if (typeof process === "undefined" || true) { @@ -10944,14 +10984,159 @@ var NavigableRegion = (0, import_element32.forwardRef)( NavigableRegion.displayName = "NavigableRegion"; var navigable_region_default = NavigableRegion; +// packages/admin-ui/build-module/navigation/index.mjs +var import_i18n6 = __toESM(require_i18n(), 1); +var import_jsx_runtime37 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE19 = "data-wp-hash"; +function getRuntime19() { + const globalScope = globalThis; + if (globalScope.__wpStyleRuntime) { + return globalScope.__wpStyleRuntime; + } + globalScope.__wpStyleRuntime = { + documents: /* @__PURE__ */ new Map(), + styles: /* @__PURE__ */ new Map(), + injectedStyles: /* @__PURE__ */ new WeakMap() + }; + if (typeof document !== "undefined") { + registerDocument19(document); + } + return globalScope.__wpStyleRuntime; +} +function documentContainsStyleHash19(targetDocument, hash) { + if (!targetDocument.head) { + return false; + } + for (const style of targetDocument.head.querySelectorAll( + `style[${STYLE_HASH_ATTRIBUTE19}]` + )) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE19) === hash) { + return true; + } + } + return false; +} +function injectStyle19(targetDocument, hash, css) { + if (!targetDocument.head) { + return; + } + const runtime = getRuntime19(); + let injectedStyles = runtime.injectedStyles.get(targetDocument); + if (!injectedStyles) { + injectedStyles = /* @__PURE__ */ new Set(); + runtime.injectedStyles.set(targetDocument, injectedStyles); + } + if (injectedStyles.has(hash)) { + return; + } + if (documentContainsStyleHash19(targetDocument, hash)) { + injectedStyles.add(hash); + return; + } + const style = targetDocument.createElement("style"); + style.setAttribute(STYLE_HASH_ATTRIBUTE19, hash); + style.appendChild(targetDocument.createTextNode(css)); + targetDocument.head.appendChild(style); + injectedStyles.add(hash); +} +function registerDocument19(targetDocument) { + const runtime = getRuntime19(); + runtime.documents.set( + targetDocument, + (runtime.documents.get(targetDocument) ?? 0) + 1 + ); + for (const [hash, css] of runtime.styles) { + injectStyle19(targetDocument, hash, css); + } + return () => { + const count = runtime.documents.get(targetDocument); + if (count === void 0) { + return; + } + if (count <= 1) { + runtime.documents.delete(targetDocument); + return; + } + runtime.documents.set(targetDocument, count - 1); + }; +} +function registerStyle19(hash, css) { + const runtime = getRuntime19(); + runtime.styles.set(hash, css); + for (const targetDocument of runtime.documents.keys()) { + injectStyle19(targetDocument, hash, css); + } +} +if (typeof process === "undefined" || true) { + registerStyle19("72ef022400", ".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}"); +} +var style_default18 = { "list": "bfb5a2dd8cceebd3__list", "li": "a4759b4cb2c8bd92__li", "item": "_07da506d3f2d9afe__item" }; +var Navigation = ({ + items, + currentHref, + ariaLabel = (0, import_i18n6.__)("Sections"), + linkComponent, + className +}) => { + if (!items.length) { + return null; + } + const LinkComponent = linkComponent ?? "a"; + if (true) { + const invalidItem = items.find( + (item) => typeof item.href !== "string" + ); + if (invalidItem) { + throw new Error( + `Navigation: item "${invalidItem.label}" is missing an \`href\` prop.` + ); + } + const duplicate = items.find( + (item, index2) => items.findIndex((other) => other.href === item.href) !== index2 + ); + if (duplicate) { + throw new Error( + `Navigation: duplicate \`href\` "${duplicate.href}". Each item must have a unique \`href\` so a single item receives \`aria-current="page"\`.` + ); + } + } + return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("nav", { "aria-label": ariaLabel, className, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( + Stack, + { + render: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("ul", { role: "list" }), + direction: "row", + align: "center", + gap: "md", + className: style_default18.list, + children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("li", { className: style_default18.li, children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( + Text, + { + variant: "body-md", + className: style_default18.item, + render: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( + Link, + { + variant: "unstyled", + "aria-current": item.href === currentHref ? "page" : void 0, + render: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(LinkComponent, { href: item.href }) + } + ), + children: item.label + } + ) }, item.href)) + } + ) }); +}; +var navigation_default = Navigation; + // packages/admin-ui/build-module/page/sidebar-toggle-slot.mjs var import_components = __toESM(require_components(), 1); var { Fill: SidebarToggleFill, Slot: SidebarToggleSlot } = (0, import_components.createSlotFill)("SidebarToggle"); // packages/admin-ui/build-module/page/header.mjs -var import_jsx_runtime37 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE19 = "data-wp-hash"; -function getRuntime19() { +var import_jsx_runtime38 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE20 = "data-wp-hash"; +function getRuntime20() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -10962,28 +11147,28 @@ function getRuntime19() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument19(document); + registerDocument20(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash19(targetDocument, hash) { +function documentContainsStyleHash20(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE19}]` + `style[${STYLE_HASH_ATTRIBUTE20}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE19) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE20) === hash) { return true; } } return false; } -function injectStyle19(targetDocument, hash, css) { +function injectStyle20(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime19(); + const runtime = getRuntime20(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -10992,24 +11177,24 @@ function injectStyle19(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash19(targetDocument, hash)) { + if (documentContainsStyleHash20(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE19, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE20, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument19(targetDocument) { - const runtime = getRuntime19(); +function registerDocument20(targetDocument) { + const runtime = getRuntime20(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle19(targetDocument, hash, css); + injectStyle20(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -11023,17 +11208,17 @@ function registerDocument19(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle19(hash, css) { - const runtime = getRuntime19(); +function registerStyle20(hash, css) { + const runtime = getRuntime20(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle19(targetDocument, hash, css); + injectStyle20(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle19("ddd9aab364", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); + registerStyle20("1f3750277d", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); } -var style_default18 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; +var style_default19 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-lockup": "_8bcd33103b451f30__header-lockup", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "has-navigation": "_4b0f17e503d11619__has-navigation", "header-navigation": "_673c99dcbfb58211__header-navigation", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; function Header({ headingLevel = 1, breadcrumbs, @@ -11042,75 +11227,106 @@ function Header({ title, subTitle, actions, + navigation, + components, showSidebarToggle = true }) { const HeadingTag = `h${headingLevel}`; - return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(Stack, { direction: "column", className: style_default18.header, children: [ - /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)( - Stack, - { - className: style_default18["header-content"], - direction: "row", - gap: "sm", - justify: "space-between", - children: [ - /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(Stack, { direction: "row", gap: "sm", align: "center", justify: "start", children: [ - showSidebarToggle && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( - SidebarToggleSlot, - { - bubblesVirtually: true, - className: style_default18["sidebar-toggle-slot"] - } - ), - visual && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( - "div", - { - className: style_default18["header-visual"], - "aria-hidden": "true", - children: visual - } - ), - title && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( - Text, - { - className: style_default18["header-title"], - render: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(HeadingTag, {}), - variant: "heading-lg", - children: title - } - ), - breadcrumbs, - badges - ] }), - actions && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( - Stack, - { - align: "center", - className: style_default18["header-actions"], - direction: "row", - gap: "sm", - children: actions - } - ) - ] - } - ), - subTitle && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)( - Text, - { - render: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("p", {}), - variant: "body-md", - className: style_default18["header-subtitle"], - children: subTitle - } - ) - ] }); + const hasNavigation = !!navigation?.items?.length; + return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)( + Stack, + { + direction: "column", + className: clsx_default( + style_default19.header, + hasNavigation && style_default19["has-navigation"] + ), + children: [ + /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)( + Stack, + { + className: style_default19["header-content"], + direction: "row", + gap: "sm", + justify: "space-between", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)( + Stack, + { + direction: "row", + gap: "sm", + align: "center", + justify: "start", + className: style_default19["header-lockup"], + children: [ + showSidebarToggle && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + SidebarToggleSlot, + { + bubblesVirtually: true, + className: style_default19["sidebar-toggle-slot"] + } + ), + visual && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + "div", + { + className: style_default19["header-visual"], + "aria-hidden": "true", + children: visual + } + ), + title && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + Text, + { + className: style_default19["header-title"], + render: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(HeadingTag, {}), + variant: "heading-lg", + children: title + } + ), + breadcrumbs, + badges + ] + } + ), + actions && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + Stack, + { + align: "center", + className: style_default19["header-actions"], + direction: "row", + gap: "sm", + children: actions + } + ) + ] + } + ), + subTitle && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + Text, + { + render: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("p", {}), + variant: "body-md", + className: style_default19["header-subtitle"], + children: subTitle + } + ), + hasNavigation && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + navigation_default, + { + ...navigation, + linkComponent: components?.link, + className: style_default19["header-navigation"] + } + ) + ] + } + ); } // packages/admin-ui/build-module/page/index.mjs -var import_jsx_runtime38 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE20 = "data-wp-hash"; -function getRuntime20() { +var import_jsx_runtime39 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE21 = "data-wp-hash"; +function getRuntime21() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -11121,28 +11337,28 @@ function getRuntime20() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument20(document); + registerDocument21(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash20(targetDocument, hash) { +function documentContainsStyleHash21(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE20}]` + `style[${STYLE_HASH_ATTRIBUTE21}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE20) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE21) === hash) { return true; } } return false; } -function injectStyle20(targetDocument, hash, css) { +function injectStyle21(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime20(); + const runtime = getRuntime21(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -11151,24 +11367,24 @@ function injectStyle20(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash20(targetDocument, hash)) { + if (documentContainsStyleHash21(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE20, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE21, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument20(targetDocument) { - const runtime = getRuntime20(); +function registerDocument21(targetDocument) { + const runtime = getRuntime21(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle20(targetDocument, hash, css); + injectStyle21(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -11182,17 +11398,17 @@ function registerDocument20(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle20(hash, css) { - const runtime = getRuntime20(); +function registerStyle21(hash, css) { + const runtime = getRuntime21(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle20(targetDocument, hash, css); + injectStyle21(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle20("ddd9aab364", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); + registerStyle21("1f3750277d", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); } -var style_default19 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; +var style_default20 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-lockup": "_8bcd33103b451f30__header-lockup", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "has-navigation": "_4b0f17e503d11619__has-navigation", "header-navigation": "_673c99dcbfb58211__header-navigation", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; function Page({ headingLevel, breadcrumbs, @@ -11203,14 +11419,16 @@ function Page({ children, className, actions, + navigation, + components, ariaLabel, hasPadding = false, showSidebarToggle = true }) { - const classes = clsx_default(style_default19.page, className); + const classes = clsx_default(style_default20.page, className); const effectiveAriaLabel = ariaLabel ?? (typeof title === "string" ? title : ""); - return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(navigable_region_default, { className: classes, ariaLabel: effectiveAriaLabel, children: [ - (title || breadcrumbs || badges || actions || visual) && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(navigable_region_default, { className: classes, ariaLabel: effectiveAriaLabel, children: [ + (title || breadcrumbs || badges || actions || visual || !!navigation?.items?.length) && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)( Header, { headingLevel, @@ -11220,15 +11438,17 @@ function Page({ title, subTitle, actions, + navigation, + components, showSidebarToggle } ), - hasPadding ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + hasPadding ? /* @__PURE__ */ (0, import_jsx_runtime39.jsx)( "div", { className: clsx_default( - style_default19.content, - style_default19["has-padding"] + style_default20.content, + style_default20["has-padding"] ), children } @@ -11242,7 +11462,7 @@ var page_default = Page; var import_components4 = __toESM(require_components()); var import_data4 = __toESM(require_data()); var import_element36 = __toESM(require_element()); -var import_i18n9 = __toESM(require_i18n()); +var import_i18n10 = __toESM(require_i18n()); var import_core_data3 = __toESM(require_core_data()); import { privateApis as connectorsPrivateApis2 @@ -11268,7 +11488,7 @@ var import_components3 = __toESM(require_components()); var import_core_data2 = __toESM(require_core_data()); var import_data3 = __toESM(require_data()); var import_element35 = __toESM(require_element()); -var import_i18n8 = __toESM(require_i18n()); +var import_i18n9 = __toESM(require_i18n()); var import_notices2 = __toESM(require_notices()); var import_url = __toESM(require_url()); @@ -11276,7 +11496,7 @@ var import_url = __toESM(require_url()); var import_components2 = __toESM(require_components()); var import_element34 = __toESM(require_element()); var import_data2 = __toESM(require_data()); -var import_i18n7 = __toESM(require_i18n()); +var import_i18n8 = __toESM(require_i18n()); import { __experimentalRegisterConnector as registerConnector, __experimentalConnectorItem as ConnectorItem, @@ -11289,7 +11509,7 @@ import { var import_core_data = __toESM(require_core_data()); var import_data = __toESM(require_data()); var import_element33 = __toESM(require_element()); -var import_i18n6 = __toESM(require_i18n()); +var import_i18n7 = __toESM(require_i18n()); var import_notices = __toESM(require_notices()); function useConnectorPlugin({ file: pluginFileFromServer, @@ -11403,9 +11623,9 @@ function useConnectorPlugin({ ); const createConnectedNotice = () => { createSuccessNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("%s connected successfully."), + (0, import_i18n7.__)("%s connected successfully."), connectorName ), { @@ -11416,9 +11636,9 @@ function useConnectorPlugin({ }; const createDisconnectedNotice = () => { createSuccessNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("%s disconnected."), + (0, import_i18n7.__)("%s disconnected."), connectorName ), { @@ -11429,9 +11649,9 @@ function useConnectorPlugin({ }; const createDisconnectErrorNotice = () => { createErrorNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("Failed to disconnect %s."), + (0, import_i18n7.__)("Failed to disconnect %s."), connectorName ), { @@ -11456,9 +11676,9 @@ function useConnectorPlugin({ invalidateResolution("getEntityRecord", ["root", "site"]); setIsExpanded(true); createSuccessNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("Plugin for %s installed and activated successfully."), + (0, import_i18n7.__)("Plugin for %s installed and activated successfully."), connectorName ), { @@ -11468,9 +11688,9 @@ function useConnectorPlugin({ ); } catch { createErrorNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("Failed to install plugin for %s."), + (0, import_i18n7.__)("Failed to install plugin for %s."), connectorName ), { @@ -11501,9 +11721,9 @@ function useConnectorPlugin({ invalidateResolution("getEntityRecord", ["root", "site"]); setIsExpanded(true); createSuccessNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("Plugin for %s activated successfully."), + (0, import_i18n7.__)("Plugin for %s activated successfully."), connectorName ), { @@ -11513,9 +11733,9 @@ function useConnectorPlugin({ ); } catch { createErrorNotice( - (0, import_i18n6.sprintf)( + (0, import_i18n7.sprintf)( /* translators: %s: Name of the connector (e.g. "OpenAI"). */ - (0, import_i18n6.__)("Failed to activate plugin for %s."), + (0, import_i18n7.__)("Failed to activate plugin for %s."), connectorName ), { @@ -11544,23 +11764,23 @@ function useConnectorPlugin({ }; const getButtonLabel = () => { if (isBusy) { - return pluginStatus === "not-installed" ? (0, import_i18n6.__)("Installing\u2026") : (0, import_i18n6.__)("Activating\u2026"); + return pluginStatus === "not-installed" ? (0, import_i18n7.__)("Installing\u2026") : (0, import_i18n7.__)("Activating\u2026"); } if (isExpanded) { - return (0, import_i18n6.__)("Cancel"); + return (0, import_i18n7.__)("Cancel"); } if (isConnected) { - return (0, import_i18n6.__)("Edit"); + return (0, import_i18n7.__)("Edit"); } switch (pluginStatus) { case "checking": - return (0, import_i18n6.__)("Checking\u2026"); + return (0, import_i18n7.__)("Checking\u2026"); case "not-installed": - return (0, import_i18n6.__)("Install"); + return (0, import_i18n7.__)("Install"); case "inactive": - return (0, import_i18n6.__)("Activate"); + return (0, import_i18n7.__)("Activate"); case "active": - return (0, import_i18n6.__)("Set up"); + return (0, import_i18n7.__)("Set up"); } }; const saveApiKey = async (apiKey) => { @@ -11594,7 +11814,7 @@ function useConnectorPlugin({ const credentials = record?.[settingName]; if (!credentials?.username || !credentials?.password) { throw new Error( - (0, import_i18n6.__)("It was not possible to save these credentials.") + (0, import_i18n7.__)("It was not possible to save these credentials.") ); } setConnectedState(true); @@ -11649,7 +11869,8 @@ function useConnectorPlugin({ } // routes/connectors-home/logos.tsx -var OpenAILogo = () => /* @__PURE__ */ React.createElement( +var import_jsx_runtime40 = __toESM(require_jsx_runtime()); +var OpenAILogo = () => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( "svg", { width: "40", @@ -11657,17 +11878,17 @@ var OpenAILogo = () => /* @__PURE__ */ React.createElement( viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg", - "aria-hidden": "true" - }, - /* @__PURE__ */ React.createElement( - "path", - { - d: "M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364l2.0201-1.1685a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.4043-.6813zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z", - fill: "currentColor" - } - ) + "aria-hidden": "true", + children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364l2.0201-1.1685a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.4043-.6813zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z", + fill: "currentColor" + } + ) + } ); -var ClaudeLogo = () => /* @__PURE__ */ React.createElement( +var ClaudeLogo = () => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( "svg", { width: "40", @@ -11675,17 +11896,17 @@ var ClaudeLogo = () => /* @__PURE__ */ React.createElement( viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", - "aria-hidden": "true" - }, - /* @__PURE__ */ React.createElement( - "path", - { - d: "M6.2 21.024L12.416 17.536L12.52 17.232L12.416 17.064H12.112L11.072 17L7.52 16.904L4.44 16.776L1.456 16.616L0.704 16.456L0 15.528L0.072 15.064L0.704 14.64L1.608 14.72L3.608 14.856L6.608 15.064L8.784 15.192L12.008 15.528H12.52L12.592 15.32L12.416 15.192L12.28 15.064L9.176 12.96L5.816 10.736L4.056 9.456L3.104 8.808L2.624 8.2L2.416 6.872L3.28 5.92L4.44 6L4.736 6.08L5.912 6.984L8.424 8.928L11.704 11.344L12.184 11.744L12.376 11.608L12.4 11.512L12.184 11.152L10.4 7.928L8.496 4.648L7.648 3.288L7.424 2.472C7.344 2.136 7.288 1.856 7.288 1.512L8.272 0.176L8.816 0L10.128 0.176L10.68 0.656L11.496 2.52L12.816 5.456L14.864 9.448L15.464 10.632L15.784 11.728L15.904 12.064H16.112V11.872L16.28 9.624L16.592 6.864L16.896 3.312L17 2.312L17.496 1.112L18.48 0.464L19.248 0.832L19.88 1.736L19.792 2.32L19.416 4.76L18.68 8.584L18.2 11.144H18.48L18.8 10.824L20.096 9.104L22.272 6.384L23.232 5.304L24.352 4.112L25.072 3.544H26.432L27.432 5.032L26.984 6.568L25.584 8.344L24.424 9.848L22.76 12.088L21.72 13.88L21.816 14.024L22.064 14L25.824 13.2L27.856 12.832L30.28 12.416L31.376 12.928L31.496 13.448L31.064 14.512L28.472 15.152L25.432 15.76L20.904 16.832L20.848 16.872L20.912 16.952L22.952 17.144L23.824 17.192H25.96L29.936 17.488L30.976 18.176L31.6 19.016L31.496 19.656L29.896 20.472L27.736 19.96L22.696 18.76L20.968 18.328H20.728V18.472L22.168 19.88L24.808 22.264L28.112 25.336L28.28 26.096L27.856 26.696L27.408 26.632L24.504 24.448L23.384 23.464L20.848 21.328H20.68V21.552L21.264 22.408L24.352 27.048L24.512 28.472L24.288 28.936L23.488 29.216L22.608 29.056L20.8 26.52L18.936 23.664L17.432 21.104L17.248 21.208L16.36 30.768L15.944 31.256L14.984 31.624L14.184 31.016L13.76 30.032L14.184 28.088L14.696 25.552L15.112 23.536L15.488 21.032L15.712 20.2L15.696 20.144L15.512 20.168L13.624 22.76L10.752 26.64L8.48 29.072L7.936 29.288L6.992 28.8L7.08 27.928L7.608 27.152L10.752 23.152L12.648 20.672L13.872 19.24L13.864 19.032H13.792L5.44 24.456L3.952 24.648L3.312 24.048L3.392 23.064L3.696 22.744L6.208 21.016L6.2 21.024Z", - fill: "#D97757" - } - ) + "aria-hidden": "true", + children: /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M6.2 21.024L12.416 17.536L12.52 17.232L12.416 17.064H12.112L11.072 17L7.52 16.904L4.44 16.776L1.456 16.616L0.704 16.456L0 15.528L0.072 15.064L0.704 14.64L1.608 14.72L3.608 14.856L6.608 15.064L8.784 15.192L12.008 15.528H12.52L12.592 15.32L12.416 15.192L12.28 15.064L9.176 12.96L5.816 10.736L4.056 9.456L3.104 8.808L2.624 8.2L2.416 6.872L3.28 5.92L4.44 6L4.736 6.08L5.912 6.984L8.424 8.928L11.704 11.344L12.184 11.744L12.376 11.608L12.4 11.512L12.184 11.152L10.4 7.928L8.496 4.648L7.648 3.288L7.424 2.472C7.344 2.136 7.288 1.856 7.288 1.512L8.272 0.176L8.816 0L10.128 0.176L10.68 0.656L11.496 2.52L12.816 5.456L14.864 9.448L15.464 10.632L15.784 11.728L15.904 12.064H16.112V11.872L16.28 9.624L16.592 6.864L16.896 3.312L17 2.312L17.496 1.112L18.48 0.464L19.248 0.832L19.88 1.736L19.792 2.32L19.416 4.76L18.68 8.584L18.2 11.144H18.48L18.8 10.824L20.096 9.104L22.272 6.384L23.232 5.304L24.352 4.112L25.072 3.544H26.432L27.432 5.032L26.984 6.568L25.584 8.344L24.424 9.848L22.76 12.088L21.72 13.88L21.816 14.024L22.064 14L25.824 13.2L27.856 12.832L30.28 12.416L31.376 12.928L31.496 13.448L31.064 14.512L28.472 15.152L25.432 15.76L20.904 16.832L20.848 16.872L20.912 16.952L22.952 17.144L23.824 17.192H25.96L29.936 17.488L30.976 18.176L31.6 19.016L31.496 19.656L29.896 20.472L27.736 19.96L22.696 18.76L20.968 18.328H20.728V18.472L22.168 19.88L24.808 22.264L28.112 25.336L28.28 26.096L27.856 26.696L27.408 26.632L24.504 24.448L23.384 23.464L20.848 21.328H20.68V21.552L21.264 22.408L24.352 27.048L24.512 28.472L24.288 28.936L23.488 29.216L22.608 29.056L20.8 26.52L18.936 23.664L17.432 21.104L17.248 21.208L16.36 30.768L15.944 31.256L14.984 31.624L14.184 31.016L13.76 30.032L14.184 28.088L14.696 25.552L15.112 23.536L15.488 21.032L15.712 20.2L15.696 20.144L15.512 20.168L13.624 22.76L10.752 26.64L8.48 29.072L7.936 29.288L6.992 28.8L7.08 27.928L7.608 27.152L10.752 23.152L12.648 20.672L13.872 19.24L13.864 19.032H13.792L5.44 24.456L3.952 24.648L3.312 24.048L3.392 23.064L3.696 22.744L6.208 21.016L6.2 21.024Z", + fill: "#D97757" + } + ) + } ); -var DefaultConnectorLogo = () => /* @__PURE__ */ React.createElement( +var DefaultConnectorLogo = () => /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)( "svg", { width: "40", @@ -11693,24 +11914,26 @@ var DefaultConnectorLogo = () => /* @__PURE__ */ React.createElement( viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", - "aria-hidden": "true" - }, - /* @__PURE__ */ React.createElement( - "path", - { - d: "M0 4C0 1.79086 1.79086 0 4 0H28C30.2091 0 32 1.79086 32 4V28C32 30.2091 30.2091 32 28 32H4C1.79086 32 0 30.2091 0 28V4Z", - fill: "#F0F0F0" - } - ), - /* @__PURE__ */ React.createElement( - "path", - { - d: "M14.5 8V12H17.5V8H19V12H20.5C20.7652 12 21.0196 12.1054 21.2071 12.2929C21.3946 12.4804 21.5 12.7348 21.5 13V17L18.5 21V23C18.5 23.2652 18.3946 23.5196 18.2071 23.7071C18.0196 23.8946 17.7652 24 17.5 24H14.5C14.2348 24 13.9804 23.8946 13.7929 23.7071C13.6054 23.5196 13.5 23.2652 13.5 23V21L10.5 17V13C10.5 12.7348 10.6054 12.4804 10.7929 12.2929C10.9804 12.1054 11.2348 12 11.5 12H13V8H14.5ZM15 20.5V22.5H17V20.5L20 16.5V13.5H12V16.5L15 20.5Z", - fill: "#949494" - } - ) + "aria-hidden": "true", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M0 4C0 1.79086 1.79086 0 4 0H28C30.2091 0 32 1.79086 32 4V28C32 30.2091 30.2091 32 28 32H4C1.79086 32 0 30.2091 0 28V4Z", + fill: "#F0F0F0" + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M14.5 8V12H17.5V8H19V12H20.5C20.7652 12 21.0196 12.1054 21.2071 12.2929C21.3946 12.4804 21.5 12.7348 21.5 13V17L18.5 21V23C18.5 23.2652 18.3946 23.5196 18.2071 23.7071C18.0196 23.8946 17.7652 24 17.5 24H14.5C14.2348 24 13.9804 23.8946 13.7929 23.7071C13.6054 23.5196 13.5 23.2652 13.5 23V21L10.5 17V13C10.5 12.7348 10.6054 12.4804 10.7929 12.2929C10.9804 12.1054 11.2348 12 11.5 12H13V8H14.5ZM15 20.5V22.5H17V20.5L20 16.5V13.5H12V16.5L15 20.5Z", + fill: "#949494" + } + ) + ] + } ); -var AkismetLogo = () => /* @__PURE__ */ React.createElement( +var AkismetLogo = () => /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)( "svg", { width: "40", @@ -11718,20 +11941,22 @@ var AkismetLogo = () => /* @__PURE__ */ React.createElement( viewBox: "0 0 44 44", fill: "none", xmlns: "http://www.w3.org/2000/svg", - "aria-hidden": "true" - }, - /* @__PURE__ */ React.createElement("rect", { width: "44", height: "44", fill: "#357B49", rx: "6" }), - /* @__PURE__ */ React.createElement( - "path", - { - fill: "#fff", - fillRule: "evenodd", - d: "m29.746 28.31-6.392-16.797c-.152-.397-.305-.672-.789-.675-.673 0-1.408.611-1.746 1.316l-7.378 16.154c-.072.16-.143.311-.214.454-.5.995-1.045 1.546-2.357 1.626a.399.399 0 0 0-.16.033l-.01.004a.399.399 0 0 0-.23.392v.01c0 .054.01.106.03.155l.004.01a.416.416 0 0 0 .394.252h6.212a.417.417 0 0 0 .307-.12.416.416 0 0 0 .124-.305.398.398 0 0 0-.105-.302.399.399 0 0 0-.294-.127c-.757 0-2.197-.062-2.197-1.164.02-.318.103-.63.245-.916l1.399-3.152c.52-1.163 1.654-1.163 2.572-1.163h5.843c.023 0 .044 0 .062.003.13.014.16.081.214.242l1.534 4.07a2.857 2.857 0 0 1 .216 1.04c0 .054-.003.104-.01.153-.09.726-.831.887-1.49.887a.4.4 0 0 0-.294.127l-.007.008-.007.008a.401.401 0 0 0-.092.286v.01c0 .054.01.106.03.155l.005.01a.42.42 0 0 0 .395.252h7.011a.413.413 0 0 0 .279-.13.412.412 0 0 0 .11-.297.387.387 0 0 0-.09-.294.388.388 0 0 0-.277-.135c-1.448-.122-2.295-.643-2.847-2.08Zm-11.985-5.844 2.847-6.304c.361-.728.659-1.486.889-2.265 0-.06.03-.092.06-.092s.061.032.061.091c.02.122.045.247.073.374.197.888.584 1.878.914 2.723l.176.453 1.684 4.529a.927.927 0 0 1 .092.4.473.473 0 0 1-.009.094c-.041.202-.228.272-.602.272h-6.063c-.122 0-.184-.03-.184-.092a.36.36 0 0 1 .062-.183Zm17.107-.721c0 .786-.446 1.231-1.25 1.231-.806 0-1.125-.409-1.125-1.034 0-.786.465-1.231 1.25-1.231.785 0 1.125.427 1.125 1.034ZM9.629 23.002c.803 0 1.25-.447 1.25-1.231 0-.607-.343-1.036-1.128-1.036-.785 0-1.25.447-1.25 1.231 0 .625.325 1.036 1.128 1.036Z", - clipRule: "evenodd" - } - ) + "aria-hidden": "true", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("rect", { width: "44", height: "44", fill: "#357B49", rx: "6" }), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + fill: "#fff", + fillRule: "evenodd", + d: "m29.746 28.31-6.392-16.797c-.152-.397-.305-.672-.789-.675-.673 0-1.408.611-1.746 1.316l-7.378 16.154c-.072.16-.143.311-.214.454-.5.995-1.045 1.546-2.357 1.626a.399.399 0 0 0-.16.033l-.01.004a.399.399 0 0 0-.23.392v.01c0 .054.01.106.03.155l.004.01a.416.416 0 0 0 .394.252h6.212a.417.417 0 0 0 .307-.12.416.416 0 0 0 .124-.305.398.398 0 0 0-.105-.302.399.399 0 0 0-.294-.127c-.757 0-2.197-.062-2.197-1.164.02-.318.103-.63.245-.916l1.399-3.152c.52-1.163 1.654-1.163 2.572-1.163h5.843c.023 0 .044 0 .062.003.13.014.16.081.214.242l1.534 4.07a2.857 2.857 0 0 1 .216 1.04c0 .054-.003.104-.01.153-.09.726-.831.887-1.49.887a.4.4 0 0 0-.294.127l-.007.008-.007.008a.401.401 0 0 0-.092.286v.01c0 .054.01.106.03.155l.005.01a.42.42 0 0 0 .395.252h7.011a.413.413 0 0 0 .279-.13.412.412 0 0 0 .11-.297.387.387 0 0 0-.09-.294.388.388 0 0 0-.277-.135c-1.448-.122-2.295-.643-2.847-2.08Zm-11.985-5.844 2.847-6.304c.361-.728.659-1.486.889-2.265 0-.06.03-.092.06-.092s.061.032.061.091c.02.122.045.247.073.374.197.888.584 1.878.914 2.723l.176.453 1.684 4.529a.927.927 0 0 1 .092.4.473.473 0 0 1-.009.094c-.041.202-.228.272-.602.272h-6.063c-.122 0-.184-.03-.184-.092a.36.36 0 0 1 .062-.183Zm17.107-.721c0 .786-.446 1.231-1.25 1.231-.806 0-1.125-.409-1.125-1.034 0-.786.465-1.231 1.25-1.231.785 0 1.125.427 1.125 1.034ZM9.629 23.002c.803 0 1.25-.447 1.25-1.231 0-.607-.343-1.036-1.128-1.036-.785 0-1.25.447-1.25 1.231 0 .625.325 1.036 1.128 1.036Z", + clipRule: "evenodd" + } + ) + ] + } ); -var GeminiLogo = () => /* @__PURE__ */ React.createElement( +var GeminiLogo = () => /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)( "svg", { width: "40", @@ -11739,76 +11964,89 @@ var GeminiLogo = () => /* @__PURE__ */ React.createElement( style: { flex: "none", lineHeight: 1 }, viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg", - "aria-hidden": "true" - }, - /* @__PURE__ */ React.createElement( - "path", - { - d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", - fill: "#3186FF" - } - ), - /* @__PURE__ */ React.createElement( - "path", - { - d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", - fill: "url(#lobe-icons-gemini-fill-0)" - } - ), - /* @__PURE__ */ React.createElement( - "path", - { - d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", - fill: "url(#lobe-icons-gemini-fill-1)" - } - ), - /* @__PURE__ */ React.createElement( - "path", - { - d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", - fill: "url(#lobe-icons-gemini-fill-2)" - } - ), - /* @__PURE__ */ React.createElement("defs", null, /* @__PURE__ */ React.createElement( - "linearGradient", - { - gradientUnits: "userSpaceOnUse", - id: "lobe-icons-gemini-fill-0", - x1: "7", - x2: "11", - y1: "15.5", - y2: "12" - }, - /* @__PURE__ */ React.createElement("stop", { stopColor: "#08B962" }), - /* @__PURE__ */ React.createElement("stop", { offset: "1", stopColor: "#08B962", stopOpacity: "0" }) - ), /* @__PURE__ */ React.createElement( - "linearGradient", - { - gradientUnits: "userSpaceOnUse", - id: "lobe-icons-gemini-fill-1", - x1: "8", - x2: "11.5", - y1: "5.5", - y2: "11" - }, - /* @__PURE__ */ React.createElement("stop", { stopColor: "#F94543" }), - /* @__PURE__ */ React.createElement("stop", { offset: "1", stopColor: "#F94543", stopOpacity: "0" }) - ), /* @__PURE__ */ React.createElement( - "linearGradient", - { - gradientUnits: "userSpaceOnUse", - id: "lobe-icons-gemini-fill-2", - x1: "3.5", - x2: "17.5", - y1: "13.5", - y2: "12" - }, - /* @__PURE__ */ React.createElement("stop", { stopColor: "#FABC12" }), - /* @__PURE__ */ React.createElement("stop", { offset: ".46", stopColor: "#FABC12", stopOpacity: "0" }) - )) + "aria-hidden": "true", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", + fill: "#3186FF" + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", + fill: "url(#lobe-icons-gemini-fill-0)" + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", + fill: "url(#lobe-icons-gemini-fill-1)" + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "path", + { + d: "M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z", + fill: "url(#lobe-icons-gemini-fill-2)" + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)("defs", { children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)( + "linearGradient", + { + gradientUnits: "userSpaceOnUse", + id: "lobe-icons-gemini-fill-0", + x1: "7", + x2: "11", + y1: "15.5", + y2: "12", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("stop", { stopColor: "#08B962" }), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("stop", { offset: "1", stopColor: "#08B962", stopOpacity: "0" }) + ] + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)( + "linearGradient", + { + gradientUnits: "userSpaceOnUse", + id: "lobe-icons-gemini-fill-1", + x1: "8", + x2: "11.5", + y1: "5.5", + y2: "11", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("stop", { stopColor: "#F94543" }), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("stop", { offset: "1", stopColor: "#F94543", stopOpacity: "0" }) + ] + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)( + "linearGradient", + { + gradientUnits: "userSpaceOnUse", + id: "lobe-icons-gemini-fill-2", + x1: "3.5", + x2: "17.5", + y1: "13.5", + y2: "12", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("stop", { stopColor: "#FABC12" }), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)("stop", { offset: ".46", stopColor: "#FABC12", stopOpacity: "0" }) + ] + } + ) + ] }) + ] + } ); // routes/connectors-home/default-connectors.tsx +var import_jsx_runtime41 = __toESM(require_jsx_runtime()); var { store: connectorsStore } = unlock2(connectorsPrivateApis); function getConnectorScriptModuleData() { try { @@ -11835,15 +12073,15 @@ var CONNECTOR_LOGOS = { }; function getConnectorLogo(connectorId, logoUrl) { if (logoUrl) { - return /* @__PURE__ */ React.createElement("img", { src: logoUrl, alt: "", width: 40, height: 40 }); + return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("img", { src: logoUrl, alt: "", width: 40, height: 40 }); } const Logo = CONNECTOR_LOGOS[connectorId]; if (Logo) { - return /* @__PURE__ */ React.createElement(Logo, null); + return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Logo, {}); } - return /* @__PURE__ */ React.createElement(DefaultConnectorLogo, null); + return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(DefaultConnectorLogo, {}); } -var ConnectedBadge = () => /* @__PURE__ */ React.createElement( +var ConnectedBadge = () => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( "span", { style: { @@ -11854,23 +12092,23 @@ var ConnectedBadge = () => /* @__PURE__ */ React.createElement( fontSize: "13px", fontWeight: "var(--wpds-typography-font-weight-emphasis)", whiteSpace: "nowrap" - } - }, - (0, import_i18n7.__)("Connected") + }, + children: (0, import_i18n8.__)("Connected") + } ); -var PluginDirectoryLink = ({ slug }) => /* @__PURE__ */ React.createElement( +var PluginDirectoryLink = ({ slug }) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( Link, { - href: (0, import_i18n7.sprintf)( + href: (0, import_i18n8.sprintf)( /* translators: %s: plugin slug. */ - (0, import_i18n7.__)("https://wordpress.org/plugins/%s/"), + (0, import_i18n8.__)("https://wordpress.org/plugins/%s/"), slug ), - openInNewTab: true - }, - (0, import_i18n7.__)("Learn more") + openInNewTab: true, + children: (0, import_i18n8.__)("Learn more") + } ); -var UnavailableActionBadge = () => /* @__PURE__ */ React.createElement(Badge, null, (0, import_i18n7.__)("Not available")); +var UnavailableActionBadge = () => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(Badge, { children: (0, import_i18n8.__)("Not available") }); function ConnectorActionArea({ isConnected, showUnavailableBadge, @@ -11882,19 +12120,23 @@ function ConnectorActionArea({ handleButtonClick, getButtonLabel }) { - return /* @__PURE__ */ React.createElement(import_components2.__experimentalHStack, { spacing: 3, expanded: false }, isConnected && /* @__PURE__ */ React.createElement(ConnectedBadge, null), showUnavailableBadge && (pluginSlug ? /* @__PURE__ */ React.createElement(PluginDirectoryLink, { slug: pluginSlug }) : /* @__PURE__ */ React.createElement(UnavailableActionBadge, null)), !showUnavailableBadge && /* @__PURE__ */ React.createElement( - import_components2.Button, - { - ref: actionButtonRef, - variant: isExpanded || isConnected ? "tertiary" : "secondary", - size: "compact", - onClick: handleButtonClick, - disabled: pluginStatus === "checking" || isBusy, - isBusy, - accessibleWhenDisabled: true - }, - getButtonLabel() - )); + return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(import_components2.__experimentalHStack, { spacing: 3, expanded: false, children: [ + isConnected && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(ConnectedBadge, {}), + showUnavailableBadge && (pluginSlug ? /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(PluginDirectoryLink, { slug: pluginSlug }) : /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(UnavailableActionBadge, {})), + !showUnavailableBadge && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( + import_components2.Button, + { + ref: actionButtonRef, + variant: isExpanded || isConnected ? "tertiary" : "secondary", + size: "compact", + onClick: handleButtonClick, + disabled: pluginStatus === "checking" || isBusy, + isBusy, + accessibleWhenDisabled: true, + children: getButtonLabel() + } + ) + ] }); } function getPluginSlug(pluginFile) { const pluginBasename = pluginFile?.replace(/\.php$/, ""); @@ -11938,14 +12180,14 @@ function ApiKeyConnector({ const isExternallyConfigured = keySource === "env" || keySource === "constant"; const showUnavailableBadge = pluginStatus === "not-installed" && canInstallPlugins === false || pluginStatus === "inactive" && canActivatePlugins === false; const actionButtonRef = (0, import_element34.useRef)(null); - return /* @__PURE__ */ React.createElement( + return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( ConnectorItem, { className: pluginSlug ? `connector-item--${pluginSlug}` : void 0, logo, name, description, - actionArea: /* @__PURE__ */ React.createElement( + actionArea: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( ConnectorActionArea, { isConnected, @@ -11958,27 +12200,27 @@ function ApiKeyConnector({ handleButtonClick, getButtonLabel } - ) - }, - isExpanded && pluginStatus === "active" && hasResolvedSettings && /* @__PURE__ */ React.createElement( - DefaultConnectorSettings, - { - key: isConnected ? "connected" : "setup", - initialValue: isExternallyConfigured ? "\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022" : currentApiKey, - helpUrl, - readOnly: isConnected || isExternallyConfigured, - keySource, - onRemove: isExternallyConfigured ? void 0 : async () => { - await removeApiKey(); - actionButtonRef.current?.focus(); + ), + children: isExpanded && pluginStatus === "active" && hasResolvedSettings && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( + DefaultConnectorSettings, + { + initialValue: isExternallyConfigured ? "\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022" : currentApiKey, + helpUrl, + readOnly: isConnected || isExternallyConfigured, + keySource, + onRemove: isExternallyConfigured ? void 0 : async () => { + await removeApiKey(); + actionButtonRef.current?.focus(); + }, + onSave: async (apiKey) => { + await saveApiKey(apiKey); + setIsExpanded(false); + actionButtonRef.current?.focus(); + } }, - onSave: async (apiKey) => { - await saveApiKey(apiKey); - setIsExpanded(false); - actionButtonRef.current?.focus(); - } - } - ) + isConnected ? "connected" : "setup" + ) + } ); } function ApplicationPasswordConnector({ @@ -12019,14 +12261,14 @@ function ApplicationPasswordConnector({ const isExternallyConfigured = keySource === "env" || keySource === "constant"; const actionButtonRef = (0, import_element34.useRef)(null); const showUnavailableBadge = pluginStatus === "not-installed" && canInstallPlugins === false || pluginStatus === "inactive" && canActivatePlugins === false; - return /* @__PURE__ */ React.createElement( + return /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( ConnectorItem, { className: pluginSlug ? `connector-item--${pluginSlug}` : void 0, logo, name, description, - actionArea: /* @__PURE__ */ React.createElement( + actionArea: /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( ConnectorActionArea, { isConnected, @@ -12039,27 +12281,27 @@ function ApplicationPasswordConnector({ handleButtonClick, getButtonLabel } - ) - }, - isExpanded && pluginStatus === "active" && hasResolvedSettings && /* @__PURE__ */ React.createElement( - ApplicationPasswordConnectorSettings, - { - key: isConnected ? "connected" : "setup", - initialUsername: isExternallyConfigured ? "\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022" : currentUsername, - helpUrl, - readOnly: isConnected || isExternallyConfigured, - keySource, - onRemove: isExternallyConfigured ? void 0 : async () => { - await removeCredentials(); - actionButtonRef.current?.focus(); + ), + children: isExpanded && pluginStatus === "active" && hasResolvedSettings && /* @__PURE__ */ (0, import_jsx_runtime41.jsx)( + ApplicationPasswordConnectorSettings, + { + initialUsername: isExternallyConfigured ? "\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022" : currentUsername, + helpUrl, + readOnly: isConnected || isExternallyConfigured, + keySource, + onRemove: isExternallyConfigured ? void 0 : async () => { + await removeCredentials(); + actionButtonRef.current?.focus(); + }, + onSave: async (credentials) => { + await saveCredentials(credentials); + setIsExpanded(false); + actionButtonRef.current?.focus(); + } }, - onSave: async (credentials) => { - await saveCredentials(credentials); - setIsExpanded(false); - actionButtonRef.current?.focus(); - } - } - ) + isConnected ? "connected" : "setup" + ) + } ); } function registerDefaultConnectors() { @@ -12092,29 +12334,31 @@ function registerDefaultConnectors() { } // routes/connectors-home/wp-logo-decoration.tsx +var import_jsx_runtime42 = __toESM(require_jsx_runtime()); function WpLogoDecoration() { - return /* @__PURE__ */ React.createElement("div", { className: "ai-plugin-callout__decoration", "aria-hidden": "true" }, /* @__PURE__ */ React.createElement( + return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "ai-plugin-callout__decoration", "aria-hidden": "true", children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)( "svg", { viewBox: "0 0 248 248", xmlns: "http://www.w3.org/2000/svg", xmlnsXlink: "http://www.w3.org/1999/xlink", focusable: "false", - style: { width: "100%", height: "100%" } - }, - /* @__PURE__ */ React.createElement( - "image", - { - href: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAQAElEQVR4AezdC3ojWW5tYflOzPbIbI/M9sh8+WdrdZ+KpiiKL5FB5KedwN7AeSFIpHRYmfX/PubXVGAqMBV4kQpMw3qRBzXbnApMBT4+pmHNq2AqMBV4mQpMw3qZR3X9RmeGqcCrV2Aa1qs/wdn/VOCNKjAN640e9hx1KvDqFZiG9epPcPY/FThWgZ1q07B2+mDnWFOBPVZgGtYen+qcaSqw0wpMw9rpg51jTQX2WIFpWMee6mhTganAU1ZgGtZTPpbZ1FRgKnCsAtOwjlVltKnAVOApKzAN6ykfy2zqcRWYlV6pAtOwXulpzV6nAm9egWlYb/4CmONPBV6pAtOwXulpve9e//Nw9P/7xL8d7Hy9aQWubFhvWrU59qMr8D+HBcPBna93rcA0rHd98q91bs3q3w9bBv7Bna93rMA0rHd86nPmqcCLVmAa1os+uF/Y9m8u6Q7rvw8bgLnDOhTiXb+mYb3rk3+tc//rYbsaVTjQP18amct4+h9hftt3BaZh7fv57v107rNg7+ec831WYBrWZyHGPHUF/vewu//6xNqg+HMRfyjMrb+edb5pWM/6ZGZfawX86Bc0qTU2/htVYBrWGz3sOepU4NUrMA3r1Z/g7H8q8EYVmIZ1h4c9U04FpgL3qcA0rPvUdWadCkwF7lCBaVh3KOpMORWYCtynAtOw7lPXmfVdKjDnfGgFpmE9tNyz2FRgKnBNBaZhXVO9GTsVmAo8tALTsB5a7llsKjAVuKYCv9uwrtn5jJ0KTAXergLTsN7ukc+BpwKvW4FpWK/77GbnU4G3q8A0rLd75L914Fl3KnB9BaZhXV/DmWEqMBV4UAWmYT2o0LPMVGAqcH0FpmFdX8OZYSowFfhrBe7GpmHdrbQz8VRgKnDrCkzDunVFZ76pwFTgbhWYhnW30s7EU4GpwK0rMA3r1hW9fr6ZYSowFfiiAtOwvijMyFOBqcDzVWAa1vM9k9nRVGAq8EUFpmF9UZiRpwKPqMCs8bMKTMP6Wb0meyowFfjFCkzD+sXiz9JTganAzyowDetn9ZrsqcBU4Bcr8NIN6xfrNktPBaYCv1CBaVi/UPRZciowFbisAtOwLqvbjJoKTAV+oQLTsH6h6LPkBRWYIVOBQwWmYR2KMF9TganAa1RgGtZrPKfZ5VRgKnCowDSsQxHmayowFXimCny9l2lYX9dmIlOBqcCTVWAa1pM9kNnOVGAq8HUFpmF9XZuJTAWmAk9WgWlYT/ZArt/OzDAV2G8FpmHt99nOyaYCu6vANKzdPdK7HOjfDrP+9yf4B/fP138efoeDma+pwP0rMA3r/jXewwqaVFjP8x8HAmIHd74eXIG3W24a1ts98pse+H8Os8HBzNdU4P4VmIZ1/xrvYQU/9v3L4SCwNqh/P2iwagdpvqYC96nANKz71HVmnQpMBe5QgXduWHco526n9B3W9tJ91fi7Pfwc7HkqMA3reZ7FM+/kXw+bc7EeDvTPV1z8jzC/TQXuWYFpWPes7sw9FZgK3LQC07BuWs7dTva/h5P91ye6YGfT2EP4eb9mZ/uowDSsfTzHe5/CHVXQqKzHbjX6YCpwtwpMw7pbaX808f8dsoN7oQOdr6nAVGBbgWlY24o8hvvEzXcnp1YTl3cq51ExTdRe7GldE6ev2vhTgbtV4KyGdbfV33diDeC7T9bE5T1LlezFntb94PRVG38qcLcKTMO6W2lPTuy/GPdfiJfED+6G6Lg8/m/Dnuxne7lOe5Y9/naNZv0HVGAa1gOKfMYSGkI4I/1XUp59f79SlFn0sRWYhvXYereaex/3PyunQT9iiePlPMbOKlOBJ67ANKzfeTiakvufVsdDmjgtPnYq8PYVmIb1Oy8B9z7uf06tLi7vVM7EpgJvVYFpWM/xuF1mB3dFz7Gr2cXOK/B6x5uG9RzPzH1VeI4dzS6mAk9YgWlYT/hQZktTganA8QpMwzpel1GnAlOBJ6zANKyLH8oMnApMBR5dgWlYj674rDcVmApcXIFpWBeXbgZOBaYCj67ANKxHV3zWe8UKzJ6fpALTsJ7kQcw2pgJTge8rMA3r+xpNxlRgKvAkFZiG9SQPYrYxFZgKfF+BRzSs73cxGVOBqcBU4IwKTMM6o0iTMhWYCjxHBaZhPcdzmF1MBaYCZ1RgGtYZRXrSFP9Wln/gD/htEwd/mTqNT4Nyj2ny+7/3sDgYh4NxNBYHcdrH4Tc8HOifL/E044hsmjgN0tj2Ko6DcfLE8EADcfmAg1w64IMXrcA0rNd5cN6Y3njrjnE4pvkHANP58iCNxQO+B3x11v84HA6c9+DO1ytWYBrW6zw1/6Df/FtZlz8vtYPLZ5iRv16BaVi//gjO3sD2zYb7F0mB30Q4aHBpfBqU68cjHPjl4iHNPy5oDljH4yBeLh7SxNN+Mr7cY+PFmpNtLf52/2suv9yx11TgF8ZOw/qFor/gkt7kKzrCJZox9xzf3GN3WIFpWK/xUN27hHbsuyIXyyBGZ/FAgzgrh7aO59PE5AQaiKfJ2WriNCiPPZabxsqBa8ebw9rAD9agmX+r0QcvVoFpWK/xwLzxvOFcGq87pof0OHtKE5MDLqpxwAMO4mksDfggjgMecBBPY2lsEKdBGouDOB5oEGdx4Ac8pLFpY1+sAtOwfuuBXb+uN/H1s9x2hm0zWH/8u+1KM9tbVmAa1ms8dj/SuEh2odyOXUSHtTGksadyjZETjuWm/e/BKc+4A/1g09iPw69j2kH+OHe8XHMF89GOjaeXx+LAD41nt5rcwYtVYBrWiz2wZbvehBoZ8IVYPNAgzuKw5vK32prLD8dy08xRHosDP5TLbrVtLg7lscbRWDzQIM7isObyaYMXrMA0rBd8aN9s2Y9lodQ4m/ZK1r7Duu80Np0f0n7ZzvK3qsA0rFtV8vHzeFP6r9+Bbwesy/lAgzgrh8YaC+t3I3SclRdoEGflbDU6TYwfaBBn5Ww1fN2nPB820ECcZiweaLDmyqGBcSunDV6sAtOwXuyBPWC73tTe9NulaNuLfhqsuY1nV13eOeONMRb4t4Q93HK+mevBFZiG9eCC33i5ay+S3efAui3fibjc3+o06625OH3VjKOZZ9V9aCB/1XC5q2YczTyrfq7vgt5YWMc076qN/2IVeIGG9WIVfdx2vSG9CaFVaRpDSI+zcuisxgDrHMXYFfLhO018m0eDrY6D2AoapNmjvUN7FcdDueLyQU762B1UYBrWDh7iHGEq8C4VmIa1vyfdJbTvNDqdi/Ww3g3JgfKe1TpT+2+/zpHGtne6HEgbu5MKTMPayYNcjuENC9sL7iXl765LaPi78MvOLZZ3dmc65/y3WG/meGAFpmE9sNhPuJQ7HhffT7i1i7fkTODy/eJJZuBzVmAa1nM+l2t21SW0S+fm4Qdv5lV/hR+dNNXt/p0jje1M6a9wrvY89swKTMM6s1AvnuZNHF7xKO092xnibNrYF6nAJduchnVJ1Z57jO8sQjt1aR3c8aS/inWe7f6dI43tLPSQNnYnFZiGtZMHuRzDhTOsl869gdkl9cOna7Bqz+g7i72H9hhnV00DU4O0sTupwDSsnTzIOcZU4B0qMA3rRZ/yiW27gAYX1aXxw3rf0wV9ec9qfeJ3bP9pbHv346NzqUHa2J1UYBrWTh7kcgwNKSR7E4e0V7LtnXU2e2fxQBvsvALTsHb+gD+P544nfEovZdo7u24cD6s+/k4rMA1rfw/WJTq4eO50/OANvtXjz2pdoLd/31HZp3OksTQQx1n89TEn+HsFpmH9vRRv6XjTw94O70w+Wdzbud7+PNOw9vcScLcDLqq/O52Lafgu75Xizu5M60X8K+1/9nqiAtOwThTnRUPerLD+SORTs+AN3dH4EH9W6zztv3PZdxrb3ukhbexOKrD/hrWTBzXHmApMBT4+pmHt71Xgwhn6TsQJXcIH9zs04AP/meE87b9z2Xca2/7pciBt7E4qMA1rJw9yOYY3LJxz6awRwDL85V1n96niOed/+cO+2wGmYb3bE//reXd21/PncJ3pnA8d/gyY316nAtOwXudZnbvTfzkkgovqg/vnix+8of+Ih9/SDu5Tf/nEr722fzaN7QDp8yNhFdmRnYa1o4d54ijexOFE2tOG2nu2jcbZtLE7rsA0rP09XN9ZhE7nniq440l/Fes82/07Rxr7KmeZfV5RgaVhXTHLDH2mCrhwhvXS2Zs7rHutEazaM/rO0v7Z9sgPac7kU8NpYlVkR3Ya1o4e5hzlLxWYS/e/lGMfZBrWPp7jeoouqNl0fljve3w3sl5Yl/9sVvM5tv80tj07kw8d2LSxO6nANKydPMjlGN6omhIk0wLt1dDe2c7F4uHVzjT7vaAC07AuKNoLDumeh33B7X/Yd/hYfqWxizzuXiswDWt/T9aFM6yXzvywvrnTnr0KPkRor76jsl/nSGNpII6z+GBHFZiGtaOHecFRvOnhgqFPPcSZfLL41Jt81Ob2tM40rD09zb+dxd0OuKj+m/L17y7c4euM14v4zsqZ1ov41zvF7PhoBaZhHS3LS4verOCN20F8ahY0s3Q+xJ/VOk/771z2ncauexeDVRt/BxWYhrWDhzhHmAq8SwWmYX3zpF8w7MIZ+k7EEVzCB/c7NOAD/5nhPO2/c9l3Gtv+6XIgbexOKjANaycPcjmGNyycc+msEcAy/OVdZ/ep4jnnf/nDvtsBpmG92xP/63nd88Bf1ddmzgPnfOjw2id9w91Pw9rfQ3cBDS6qOx0/eDNv9fizWp/4bffvHGlse0//+Y+EzTD2aSswDetpH81NN+ZNHG468YMma+/Zlo2zaWN3XIFpWPt7uL6zCJ0uzrrjSX+Utaa1gW9dFg+0r7Dm8strLJs2dscVmIa1v4frwhnWS2c8rCf26Rqs2j381mZrOCwO617pPghg24uckM6mseVqXs5kjrSxO6nA7RrWTgoyx3iaCmhIT7OZ2chzVGAa1nM8h1vuwgV1aN44u973uJyH8u5lfWJnbWh9Fg+tTXeJ7jultGPjxRrL4mCcM5kDH+yoAtOwdvQwP4/iDQve+J/SBx4+fuFXa7Pti8WBf2pbckK5bBp7avzEdlKBaVg7eZDfHMOPV+Gb1HPCP85pbbbB/BXpx+xXeV/px+YYbQcVmIa1g4e4OYILZ1gvnfnBm7wh8mDVil1jfcezzulSvPXFzC2eJk4DcTqLgzgN0tfxdHkgjrP4YEcVmIa1o4f5w6N4w/9wyFnp5tVgzkr+Iskc6yeHX6R9KV87/suJJ/C7FZiG9bv1v8fq7nbARfWp+eW4rIZTeT+NmdeFN/vTsfKNsyfAf4prx/90vb3nP9X5pmE91eO4yWY0C1h/JPKpWfCGbiE5sGrFrrHb+eyn9a1nbjZNnAbGirE4iJcrRhNPY2lAl8Pigx1VYBrWjh7mHGUqsPcKTMPa3xN24Qy+y+h0LtaD+x06Kwfwe8Ia9gTWtRaLgzjtK8hpoPtu7gAAEABJREFU/+Uan8Y2li4H0sbupALTsO77IH9jdm9YOOfS2uU4yL/3Xq0B6zo4nLPXddwp33zOdMs5T603sQdWYBrWA4s9Sz2kAu6u4LsPHR6ymVnkthWYhnXbej7DbC6gwUV1++EHb2Y6Kw/4tHvBj2fWgdZi29N3nwiKl2ucfbJpLA3SrYkPdlSBaVg7epgnjuJNHE6kPTzUnthTi4uvKPeYVuzhdha8fwWmYd2/xo9ewR0OrN9h8INYe+JD/FmtPR7bfxr7rHuffd2wAtOwbljMJ5nKJ2qwXjq7hA5tUxOQB/z0Z7TtnW2vLB7at+blU0PnShu7kwpMw9rJg5xjTAXeoQJP07DeodgPOqML6tCSx+56aC6rgV/uM1qf+NkjrPvDQ7rvsJxJDdLG7qQC07B28iCXY3jDgjdysjdwWHU+lPes1nnaP98+7TuNpQUxiI/dSQWmYe3kQX5zDPc94ZvUpwy3d3bdIB5WffydVmAa1v4erAtnWC+d+cEb3KlZecCnPQY/X8XFevvvOyx7TmObVRxn08bupALTsHbyIOcYf6mAZrZ+SvqX4JDXrcA0rNd9dl/t3N0NuKj+Kocux8U04HvBXs+1l+dz1TmmYV1Vvqcc7AIa1h+J/JWY4A3dxuXAqhV7Jus87d9+7c2e01ga0OWw+OBXK3Dbxadh3baeM9tUYCpwxwpMw7pjcR8wtbsaaCm+S/SQHmflpL+K9R2Ti3Ro/6zzhM4iJ8hJH7uDCkzDeu2H2Bvz0lNoBHDp+EeO03zCqXXLYU/lTewFKzAN66kf2rebc08D3yZ+kaBZXTP+i2lHngrcpwLTsO5T10fN6jIaWk/zwUN6nJWTzm457dmgsdo7tF8WD+05zspJH7uDCkzD2sFD3BzBmzQUirNpr2btPbT3OHtKKzb2xSswDet1H6A7Gt95AL+T4CFNPKTtwXZOtvPwgzNv9VUr9gx29nBGBaZhnVGkJ03xxvNXVoBvmyweaEC/9oLePM8EZ+qc63/Vnsa2Xw0MB+PSx75YBaZhvdgDm+1OBd65AtOwXvfpu7cJ6ynS2HTfYbiEhrQ9WH+tKHQe515Bx8vj0wYvWIG9NKwXLP3VW/bG04BAQzLhqtFpQQzir26dxbmB33mcO6SJywN++tgXq8A0rBd7YMt23cWERf5IYz/u+Mv8K1rqmFbsEfbY+se0R+xl1rhxBaZh3bigd5rOhfn2r6B4E9LBdw6WXjU67RZo3tYxZ5p1XGbTAA84GNf+jaMBH/iXwFhzs41vbTadxUF+uXScTRv7xBWYhvXED+fJtuZNvX4ad4vtmVMT+dFcS7Lxa7NcQme5144/a5FJul0FpmHdrpb3nMm/beXuBe65zqm5u7Q+lXMqZu+w5vjuZv2nYdbYOb753Fex5+Rvc6x/zfjtfMPvXIFpWHcu8I2m743lzdWUNG924NO9cfFAuwXMaw22+fDWWfeVxq65cmCdo/il1lywjrduKLbulb/ml7Nq4z9pBaZhPemDmW1NBaYCHx8fmyJMw9oU5AmoexXfBbBtpwtrNl2O+x9IK/8aay5Y57CGtcG6YiwO4jTAAw7iacbRrEGHNPq1MJc5oblop9Zfcxsz9gkrMA3r+R6KS2Twhv5ud3JCubg3aPyn1nhvYPanY3+abw245WW+ucwJ3+1HTvgud+JPUIFpWE/wEDZb6IJ9I59N3cnA2QM2ica6YGc3oaFTgd+twDSs363/sdV9d+Rymi2OhxqJ+FYr/285sZ9ZY829jtLAtmvJSRMvP41NE8fB/HQWB3HaLWAuc0LzrXu1Lp2VE2iDJ6/ANKwnf0Cf2/PmCp/SH5PG/hHu9Jv5V7TMJZoxp8YXu9SaP6xzpLHp/JA29okrMA3r+R6O7wZCu4uz7lzS+RC/hbVGaD5rpPHpbBpLA37AYc3lbzX5tHvBmtYAfuvgIU08jZ8+9gkqMA3rdx+CNwS0C74L95AeZ9PkuhwHfvq11hqhueJsa7E4uOg+lntMM47OGgvrePqtz2RO6wB/uz6dBvyAvwjeY5vTsH73OXvzwLFd+FHlmH5P7au93HPNY3PbBxyLjfbGFZiG9bsPvx891l1oVODTwnQ8rFoXxmLp11qX1qG57MUakMYP4sf0NPFy0+Ks+Kr7L9XVJu1aa43OxG8+fkizl2O5xcf+YgWmYf1i8Y8s7c1TE1rfsGmsnIbyIX6tNZd1Q/Ph1gY+XS4OaXQ84CCexqd9NV7s1rCWdYFvfrY9sTSQE/DBE1VgGtafh/FUv/lRKLSxOJt2L2uN0Bpx9pj2lX4q15gV5T7SHlv/mPbIPc1aJyowDetEce4c8qf4uX9dxCV08IZqa3yIX2vN1Tps87mExsG+6WuuOA3kBBzE04yjsWniNDA/ncVvAWtVa745WesEGsRZOTTg33JP5hz8sALTsH5YsCdL9yaCJ9vWVdvxiaEzsVdNdOPBmirceNqZ7icVmIb1k2rdNtcdSrh0Zn/iw6Xjn3GcS291YW+5P3PCpXO6iF/vui6dZ8ZdUYFpWFcU78qh3jzeAFDTofmELLREnJWTfmtrbmuE5rfHtPbKpomXm8amieNgHJ3FQZwGdJzFbwHnMifwzclaO9AgzsqhAR/4g1+qwDSsXyr8LDsVmAr8vALTsH5es0tGuJPxHQM0nu9iF8TpLB5oEGfl0G453lzmNLc1Ag3E0+RsNXEalMfiII7DT8Yfy01jzResA3FWDu3Y+mJygjyIs3Jo63g+bfALFfhpw/qFLe5iSZe1sF4k870hQgeNs6c0MTkBhziLAz/gIc1etppYmjge0uPiW00sTRwP6XHxrSaWJo6H9Dh7ShOTE3CIszjwAx7S7CVt7IMrMA3rwQWf5aYCU4HLKzAN6/La/WSky16XuGzj+tSJ1mUui4dy46wcuh9NcEhj8SAP4qwc2jreXmhicgINxNPk0I6Np5fH4nDp+NY6Nl7MGsE6EGfl0Na9prFygjyIs3Jo63h7oQ1+oQLTsH6h6J9LejOs+JQ/ztU+Dr/OzT2Wdxj+cUz/u/bxj1+rxi/CD+dq8s/NPZZ3yXjzGBdwiLM48AMe0ti0sQ+uwDSsxxTcn9DBXYhV2a1GT2Nx4AfjaOxWo6exOPCDcTQ2jaUBP+Cw5vK3mnwa8AMOxqTxaZDG4sAP5bJbbZuLQ3mscTQWBz4N8IBDnC2XxYM8iLP44M4VmIZ15wJ/Tu/CPXxKH3HWG4LO4oEGcRaHNZe/1dZcfpAHxqR1kbxqYvKAH+TQ2LTG09NYOV9p3uRy4KvxxoKc0JxsGisP+AGHNZe/1eTTgB9wMCbtu73KH9ypAtOw7lTYN53WG/tNj/7ix36R7U/DesyDcu+xwqr+6kkaHtLYn2ryjQs4xFkc+MFeaJDG4iCOAw78IL7VitHFV06Ls+I0wAMO4luNnsbiwA84xFk84OFczV7KdQEf0sbesQLTsO5Y3GVqnziFZD8SpfHp3jxpLA34QQ6NTbv3ePOfWkvcnqA8FgdxHPi0Y/unywlyaMak8WliaSwN+EEOjU271XjzmivggztXYBrWnQv8Ob0flcKn9BHPfnz+irOf0gc/fCy/0thkfjiliZXH4sAPOMSzNIizOPADDvEsDeIsDvyAQzxLgziLAz/gIY39qSbfuIBDnMUHd67ANKxbFPgfc3jh9u8u+ZO3iL/mEeTQXeJuNbE0Vh7wgxya+beaWBorD/hBDm0dby80sfJYGojjIId2bDxdTsDh0vGtdWy8WOuw1gF+kENb95rGlsfKA36QQ1vH2wtNrDyWFsTyx96wAtOwbljMmWoq8FkBDUyT+6RjblWBaVi3quQ/5nFfEv6hjvdOFfC3GrwG3unMDznrNKzbltmLtMtdfrN7AYd0eWn9aSyWxp4ab4wc4Mu9dLy9nBovbh1oLRYHceMBDziIpxlHY9PEaZDGOg9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4P/y8fFhLzSxNJa2Qnzl49+gAtOwblDEmWIqMBV4TAWmYV1XZ5er0Cz+JHZ/Afx0PJQvvtXE0thHjbcXa321vrj9gBy5q8angZyAg3jaT8Yfy01jm5O1DvCDHNqx9cXKY+UBP8ihreP5NLHyWBqI4yCHNrhRBaZhXV5IL0Yvyj41aiY6rH+FAw/liaex6fxwShMrj8WBH3CIs3jAwV62Gj1NHA/pcfGtJpYmjof0uPhWE0sTx0N6nD2lickJOMRZHPgBD2n2stXE0sRxSBt7owo8uGHdaNfPM417ivW/fH6enc1OpgI7rMA0rMsfqmblAtaPAM1C669qsOn8IIeu0W01epq5cUhjG8/iwJcHOPxkvHxjgR9wOLZXa5bHygN+wOHS8db4ajy9dVgc+KHx7Fbb5uJQHmscjcUDDeIsDny1B+NogxtVYBrWjQr5OY0XqAYG/E/5Aw8fn7/ibLksDvzP1A88fHz+Ek/jk9mtRk9jcTiWu2prLj/I+Wo8vTwWB364x3hzWwf4AQdrpvG3mhgN+AEHY9L4W02MBuIBH9ywAtOwLi+mOwovVOCbicUDDeKsHBqLA58GeMAhzpbL4sCXB3jAIc6Wy+JBHsRZHNZc/lZbc/kA8sAYHPhbjU4DfjiWm7bNxaGxbLksDnx5gAcc4my5LB7kQZzFYc3lb7U1V2zwgwpMw/pBsTapLtvD+sJMc/nakDT2mHZs/Fe5jTdGDvDpLB5oEGdxWHPb66qtufwg56vx9PJYHPjhHuPNbR3gBxysmcbfamI04AccjEm7Za3MPfhBBaZh/aBYkzoVmAr8bgWmYV1efxfJ27uKOCve7HhIE99qYmksDvyAQ5zFAx7O1ezlVK74qTnFHz3eeu2JxYEfcIizeMDDudotz9qaL28fdYBpWJdX2l2ET4KAbyYvfhzS6HiQQxNP49PE0lga8IMcGpt27/HmP7WWuD1BeSwO4jjwacf2T5cT5NCMSePTxNJYGvCDHBqbdu/x5j+1lrg9DS6owDSsC4r2OcS9xopP+eMSzZiPz1/88Cl9xNmP5RcekuPsKU1MTsAhzuLAX0GDSzRjjAV+wCHO4sBfQYNztZ/kHpvz0vHmMhb4AR9cUIFpWOcVzZ+K/qt2thEuYWnghUgXx0GcBngoV3yriaWxxgI/yKGta6Wx5bHygB/k0Nbx9kITK4+lgTgOcmjHxtPlBBwuHd9ax8aLtQ5rHeAHObR1r2lseaw84Ac5tHW8vdDEymNpII6DHNqx8fTBDyswDeu8gvlkyIuPPW/ED7Im9a0r4B98fOsC/OTw07DOq5aLVvcg7HkjJmsqcF4Fjv3TNOeNfMOsaVjnPXTf0rtIZRuBe7FBOouDeLl40Pjo4mnG0cTSWBrwgxyaMWl8mlgaSwN+kEMzJs1eaGJpLA3EcTCOxuIgTgM84CCeZhyNTROnQRprPzRxHIyjieGBBnFWDs0YHPg0MTzQIM7KoRmDg73QxPBAA/E042hsmjhtcEEFpmFdUFjYef8AAA5ZSURBVLQZMhW4uAIz8KoKTMP65/K5q4I14gI1FPOn5ilNvDnKY0+NF5MTHjW+vX61vnh7kmNfq8anQXksDuI4/GT8sdw01nzBOhBn5dCOrS8mJ8iDOCuHto7n08TkBBqIp8nZauI0KI/FB99UYBrWPxfIiwd6scngBxxcwKexNOCDOA54wEE8jaUBP+AQZ/GAh59q8htrLziksTiI44EGcXEc0lgcxPFAg7g4DmksDuJ4oEGcxYEf8JDG/lSTbxzYCw54wEE8jaUBH8RxwAM++KYC07C+KdCEpwJTgeepwGs1rMfUrctRl6qt6N84Cuk+MdxqYmnsT8fLNw7Wy1k8WEMeu9XoaSwO/GAcjU1jacAPOFx6VmPh0vH2+NV4evtkceCD+jWepQFfHuABhzhbLosHeRBncfjJWe0xGDv4pgLTsL4p0GfYvUP4lD7irBf0x+EXiwP/IP35wsMf4fBbnC2XxYF/SPvzhYc/wuE38TT+Qfpg09iPz1/88Cl9rLn8j8Mvtjz2IP354gc5RHar0dNYHPjBOBq71ehpLA78YByNTWNpwAdxHPg04G81Og34AQdj0vhbTYwG/HAsN00uP+CDbyowDeuvBXKf0IuNLcoPcujsVqOnsTjwg3E0dqvR01gc+ME4GrvV6GksDvxgHI1NY2nADzisufytJp8G/ICDMWl8GqSxOPBDuexW2+biUB5rHI3FgU8DPOAgnsbfamI04AccjEnjbzUxGvADDsYEfLBUYBrWUoyD64Xir1bAejmKh0Pan684axzRiw+HS8abx9hgToizOKy5/K225vKDPDAmrb2umpg84Ac5NDat8fQ0Fgd+MI72Ta0+5MsDfmg8m8bKA37AYc3lbzX5NOAHHIxJ66yrJiYP+EEOjU1rPD2NxUGuD30AHywVmIa1FONM17fwZ6ZO2gtWQMN4wW2/x5anYf31OWtGweVp0TQ2TRyHNH4QP6aniZebxqaxOPADDnEWD3g4V7OXU7nip+YUf/R467UnFgd+wCHO4gEP52r3Pqv9uMSH9jT2swLTsD4L8Wm8WPrUxo8sn/Kf/z15epp4Gp9+zng5co05NV5MHvBD49k0c8lbNTEa8IMcGpv23XjxU7ni5oTyWBzEceDTjq1PlxPk0IxJ49PE0lga8IMcGpt27/HmP7WWuD1BeSwO9ioH8HfA2WechvXPpfIjQSgaZ49pX+nHco9pl4w3j3EBhziLAz/gIY09V/tJ7rE5f2O8fVg34BBnceAHPKSx52o/yT025zq++Fvbd29Y/hSDXgR8l52wXoTioVzxtF5Y54wv99h4seZkW4sf5NDXtdLY8lh5wA9yaOt4e6GJlcfSQBwHObRj4+lyAg6Xjm+tY+PFWoe1DvCDHNq61zS2PFYeHFtrHS8u79rx5rBuwMH8adagDT4r8M4Ny4vBi2P91OazLGOmAlOBZ6zAOzcsz8PFJvBfFbPv21bAH2S3nXFmu1kF3rlhdbnJVlDf+vdXc9aL0DS2XHEcjKOzOIjTAA+tJ55mnDyxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaZDG2g9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4GAvNDE80EA8zTgamyZOgzQWB3EcjKMNPivwzg3rswRjpgJTgVepwDs3LH96bS83V43fcyyPTRPHoR8jVo1frpxwLDeNLY991Pj2+tX64vYDcuxr1fg0kBNwEE/7yfhjuWlsc7LWAX6QQzu2vlh5rDw4lrtqfHnXjjeHdQMO5k+zBg3o/3lwVu1A3+vrnRuWy3YPP/Tk4+JbTSxNHA/pcfGtJpYmjof0OHtKE5MTcIizOPADHtLsZauJpYnjIT0uvtXE0sTxkB4X32piaeJ4SI+zpzQxOQGHOIvDuhYe5ID4VqOnieMhPS6+1cTSxPGQ7gMioKe9nX3nhvV2D3sOfFYF3rohnFWhX0x654blr1j4hBBcoHoMLB5oEGdxuHS8Nb4aT7dGwCHONp7FgS8P8IBDnC2XxYM8iLM4XHpWY+HS8fb41Xi6PQYc4i6vG8+m8+VBGosDP5TLprHygB9wuPSsxsKx8XSX8OBHQ/wt8VYNa/OEPfjgBSnMbjV6GosDPxhHY7caPY3FgR+Mo7FpLA34AYc1l7/V5NOAH3AwJo2/1cRowA/HctO2uTg0li2XxYEvD/CAQ5wtl8WDPIiL48Df6qsmJg/4AYc1l7/V5NOAH47lpm1zcWgsu+aKvT3epWH5Nj/00HEvCuDTWTzQIM7KobE48LcanQb8cCw3bZuLQ2PZclkc+PIADzjE2XJZPMiDOIvDmsvfamsuP8gDY9L4W02MBvxwLDdtm4tDY9lyWRz48gAPOIin8beaGA34AQdj0vhbTYwG/ICDMWn8rSZGe0u8S8PqUxe2B+0CM6wvjDSXn8dyj2n3GG8fx9ZKs6Yc4NNZPNAgzuKw5nbWVVtz+UHOV+Pp5bE48MM9xpvbOsAPOFgzjb/VxGjgNYIDDsbg8Ey1sre3wrs0rLd6qHPYj4+PKcIuK/AuDauLUbYH6XLTHQGk8YP4MT1NvNy0OCt+TE8TlwdpLB5wiLM48AMe0thzNXs5lStuPjiWJ35MTxM3FtL4QfyYniZebhqbxuLADzjEWTzg4VzNXk7lip+aU/xW45vnbey7NCw/94ceLu6TJODTvdBwSKPjQQ5NPI1PE9tq9DRWDs0YHPg0MTzQIM7KobE43Hu8+a0D/K/Wp8sJOBiTxqcd2z+9PFYOzRgc+DQxPNAgzsqhsTjce7z5rQP8r9anywk4GJPGpx3bP/3t8C4N6+0e7Bx4KrDHChxvWPs7qYtU6E8sJ8T/7+BAOouD+CH85wsPLmCJ4mnG0dg0cRqksafGi8kJxkKclUNb1+LTxOQEGsRZOTRjcGivYniQB+JpxtHYNHEapLE4iONgHI3FQZwGeLAfmniacTSxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaW+Jd2lYXlzQJzxv+bDn0FOBV6/AuzQsdwCwXni++rOb/U8F3q4C79KwtpeYHjTNX3UA33LTWBzEaYAHjY8mnmYcjU0Tp0Eae2q8mJxgLMRZObR1LT5NTE6gQZyVQzPmXz4+PmjtVQwP8kA8zTgamyZOgzQWB3EcjKOxOIjTAA/2QxNPM44mlsbSgB/k0IxJ49PE0lga8IMcmjFp9kITS2NpII6DcTQWB3Ea4AEH8TTjaGyaOO0t8S4N6y0f7hx6KrC3Crxzw/KnlgtMcL/l2a4anwZywrHcNLa8a8ebx9rAD9agmX+riaWx8oAf5NDW8XyaWHksDcRxkLPVxGkgJ+AgnvaT8cdy09jmZK0D/CCHdmx9sfJYecAPcmjreD5NrDyWBuI4yNlq4jSQE3AQT2s8nQ/8t8U7NywX8F4AsL4AcBBPx0OaeBpLZ4M4DdJYHMTxQIM4iwM/4CGN/akm3ziwFxzwgIN4GksDPojjgAccxNNYGvBBHAc84CCextKAH3CIs3jAw081+Y21FxzSWBzE8UCDuDgOaSwO4niggb8WpJHR8Uvw8mPeuWG9/MObA7xVBXxg5N7srQ69Pew7Nyx/TccFJvRCYOmhesVZOXQvIBzSWDzIgzgrh3ZsPF1OwCHONp7FgS8PcHAuHPBQLpvGygN+wOHYXh8x3hpfrU9vnywO/NB4dqttc3EojzWOxuKBBnEWh3vUyrx+VPRM7QV/S7xzw/LgQw8f98IAfjoejmnlsuXxj+Ue08plG88ey01bc/l01jjg0wAPOIin8beaGA344Vhu2jYXh8ay5bI48OUBHnCIs+WyeJAHcRaHNZe/1dZcfpAHxqTxt5oYDfjhWG7aNheHxrJrrtjb450b1rGH735gRTlePEGczp7SxOQBPxhHY7caPY3FgR+Mo7FbjZ7G4sAPxtHYNJYG/IDDmsvfavJpwA84GJPG32piNOCHY7lp21wcGsuWy+LAlwd4wCHOlsviQR7EWRzWXP5WW3P5QR4YE/DBUoFpWEsxDq4XiotNcMl5kP588cMf4fBbnDXuIH2wOLg8/fj8hYdP6SPOGkdn8UCDOIvDmsvfamsuP8gDY9La66qJyQN+kENj0xpPT2Nx4AfjaGzatePNY07gBxzWtfhbTT4N+AEHY9La66qJyQN+kENj0xpPT2NxkOv1B3za4LMC07A+CzFmKjAVeP4KTMP66zNyZxBcnhZNY9PEcUjjB/Fjepp4uWlsGosDP+AQZ/GAh3M1ezmVK35qTvFHj7dee2Jx4Acc4iwe8PAX7UDoB/Pnix/ufVbruMQH/p8NzG9/q8A0rL/Vod+9QHwSA+4W0vEghy6exqeJbTV6GiuHZgwOfJoYHmgQZ+XQWBzuPd781gH+V+vT5QQcjEnj047tn14eK4dmDA58mhgeaBBn5dBYHO493vzWAf5X69PlBBzs1TjAB0sFpmEtxRh3KjAVeO4KTMN67ufzTLv7yQXwT3Kf6YyzlyevwF0a1pOfebZ3ugKajX8sbpvlkyyxVceP/ejiE641b/ypwE0qMA3rJmXc1STuUPxTJttDuWsRW3X8WMM6Nn4dN/5U4KIKTMO6qGwzaCowFfiNCkzD+o2q72nNOctU4IEVmIb1wGLPUlOBqcB1FZiGdV39ZvRUYCrwwApMw3pgsWepqcBrV+D3dz8N6/efwexgKjAVOLMC07DOLNSkTQWmAr9fgWlYv/8MZgdTganAmRWYhnVmoa5PmxmmAlOBayswDevaCs74qcBU4GEVmIb1sFLPQlOBqcC1FZiGdW0FZ/xU4J8rMMqdKjAN606FnWmnAlOB21dgGtbtazozTgWmAneqwDSsOxV2pp0KTAVuX4H/DwAA//9sB2hHAAAABklEQVQDAB9QlitZA9bLAAAAAElFTkSuQmCC", - width: "248", - height: "248", - style: { mixBlendMode: "multiply" } - } - ) - )); + style: { width: "100%", height: "100%" }, + children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)( + "image", + { + href: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAQAElEQVR4AezdC3ojWW5tYflOzPbIbI/M9sh8+WdrdZ+KpiiKL5FB5KedwN7AeSFIpHRYmfX/PubXVGAqMBV4kQpMw3qRBzXbnApMBT4+pmHNq2AqMBV4mQpMw3qZR3X9RmeGqcCrV2Aa1qs/wdn/VOCNKjAN640e9hx1KvDqFZiG9epPcPY/FThWgZ1q07B2+mDnWFOBPVZgGtYen+qcaSqw0wpMw9rpg51jTQX2WIFpWMee6mhTganAU1ZgGtZTPpbZ1FRgKnCsAtOwjlVltKnAVOApKzAN6ykfy2zqcRWYlV6pAtOwXulpzV6nAm9egWlYb/4CmONPBV6pAtOwXulpve9e//Nw9P/7xL8d7Hy9aQWubFhvWrU59qMr8D+HBcPBna93rcA0rHd98q91bs3q3w9bBv7Bna93rMA0rHd86nPmqcCLVmAa1os+uF/Y9m8u6Q7rvw8bgLnDOhTiXb+mYb3rk3+tc//rYbsaVTjQP18amct4+h9hftt3BaZh7fv57v107rNg7+ec831WYBrWZyHGPHUF/vewu//6xNqg+HMRfyjMrb+edb5pWM/6ZGZfawX86Bc0qTU2/htVYBrWGz3sOepU4NUrMA3r1Z/g7H8q8EYVmIZ1h4c9U04FpgL3qcA0rPvUdWadCkwF7lCBaVh3KOpMORWYCtynAtOw7lPXmfVdKjDnfGgFpmE9tNyz2FRgKnBNBaZhXVO9GTsVmAo8tALTsB5a7llsKjAVuKYCv9uwrtn5jJ0KTAXergLTsN7ukc+BpwKvW4FpWK/77GbnU4G3q8A0rLd75L914Fl3KnB9BaZhXV/DmWEqMBV4UAWmYT2o0LPMVGAqcH0FpmFdX8OZYSowFfhrBe7GpmHdrbQz8VRgKnDrCkzDunVFZ76pwFTgbhWYhnW30s7EU4GpwK0rMA3r1hW9fr6ZYSowFfiiAtOwvijMyFOBqcDzVWAa1vM9k9nRVGAq8EUFpmF9UZiRpwKPqMCs8bMKTMP6Wb0meyowFfjFCkzD+sXiz9JTganAzyowDetn9ZrsqcBU4Bcr8NIN6xfrNktPBaYCv1CBaVi/UPRZciowFbisAtOwLqvbjJoKTAV+oQLTsH6h6LPkBRWYIVOBQwWmYR2KMF9TganAa1RgGtZrPKfZ5VRgKnCowDSsQxHmayowFXimCny9l2lYX9dmIlOBqcCTVWAa1pM9kNnOVGAq8HUFpmF9XZuJTAWmAk9WgWlYT/ZArt/OzDAV2G8FpmHt99nOyaYCu6vANKzdPdK7HOjfDrP+9yf4B/fP138efoeDma+pwP0rMA3r/jXewwqaVFjP8x8HAmIHd74eXIG3W24a1ts98pse+H8Os8HBzNdU4P4VmIZ1/xrvYQU/9v3L4SCwNqh/P2iwagdpvqYC96nANKz71HVmnQpMBe5QgXduWHco526n9B3W9tJ91fi7Pfwc7HkqMA3reZ7FM+/kXw+bc7EeDvTPV1z8jzC/TQXuWYFpWPes7sw9FZgK3LQC07BuWs7dTva/h5P91ye6YGfT2EP4eb9mZ/uowDSsfTzHe5/CHVXQqKzHbjX6YCpwtwpMw7pbaX808f8dsoN7oQOdr6nAVGBbgWlY24o8hvvEzXcnp1YTl3cq51ExTdRe7GldE6ev2vhTgbtV4KyGdbfV33diDeC7T9bE5T1LlezFntb94PRVG38qcLcKTMO6W2lPTuy/GPdfiJfED+6G6Lg8/m/Dnuxne7lOe5Y9/naNZv0HVGAa1gOKfMYSGkI4I/1XUp59f79SlFn0sRWYhvXYereaex/3PyunQT9iiePlPMbOKlOBJ67ANKzfeTiakvufVsdDmjgtPnYq8PYVmIb1Oy8B9z7uf06tLi7vVM7EpgJvVYFpWM/xuF1mB3dFz7Gr2cXOK/B6x5uG9RzPzH1VeI4dzS6mAk9YgWlYT/hQZktTganA8QpMwzpel1GnAlOBJ6zANKyLH8oMnApMBR5dgWlYj674rDcVmApcXIFpWBeXbgZOBaYCj67ANKxHV3zWe8UKzJ6fpALTsJ7kQcw2pgJTge8rMA3r+xpNxlRgKvAkFZiG9SQPYrYxFZgKfF+BRzSs73cxGVOBqcBU4IwKTMM6o0iTMhWYCjxHBaZhPcdzmF1MBaYCZ1RgGtYZRXrSFP9Wln/gD/htEwd/mTqNT4Nyj2ny+7/3sDgYh4NxNBYHcdrH4Tc8HOifL/E044hsmjgN0tj2Ko6DcfLE8EADcfmAg1w64IMXrcA0rNd5cN6Y3njrjnE4pvkHANP58iCNxQO+B3x11v84HA6c9+DO1ytWYBrW6zw1/6Df/FtZlz8vtYPLZ5iRv16BaVi//gjO3sD2zYb7F0mB30Q4aHBpfBqU68cjHPjl4iHNPy5oDljH4yBeLh7SxNN+Mr7cY+PFmpNtLf52/2suv9yx11TgF8ZOw/qFor/gkt7kKzrCJZox9xzf3GN3WIFpWK/xUN27hHbsuyIXyyBGZ/FAgzgrh7aO59PE5AQaiKfJ2WriNCiPPZabxsqBa8ebw9rAD9agmX+r0QcvVoFpWK/xwLzxvOFcGq87pof0OHtKE5MDLqpxwAMO4mksDfggjgMecBBPY2lsEKdBGouDOB5oEGdx4Ac8pLFpY1+sAtOwfuuBXb+uN/H1s9x2hm0zWH/8u+1KM9tbVmAa1ms8dj/SuEh2odyOXUSHtTGksadyjZETjuWm/e/BKc+4A/1g09iPw69j2kH+OHe8XHMF89GOjaeXx+LAD41nt5rcwYtVYBrWiz2wZbvehBoZ8IVYPNAgzuKw5vK32prLD8dy08xRHosDP5TLbrVtLg7lscbRWDzQIM7isObyaYMXrMA0rBd8aN9s2Y9lodQ4m/ZK1r7Duu80Np0f0n7ZzvK3qsA0rFtV8vHzeFP6r9+Bbwesy/lAgzgrh8YaC+t3I3SclRdoEGflbDU6TYwfaBBn5Ww1fN2nPB820ECcZiweaLDmyqGBcSunDV6sAtOwXuyBPWC73tTe9NulaNuLfhqsuY1nV13eOeONMRb4t4Q93HK+mevBFZiG9eCC33i5ay+S3efAui3fibjc3+o06625OH3VjKOZZ9V9aCB/1XC5q2YczTyrfq7vgt5YWMc076qN/2IVeIGG9WIVfdx2vSG9CaFVaRpDSI+zcuisxgDrHMXYFfLhO018m0eDrY6D2AoapNmjvUN7FcdDueLyQU762B1UYBrWDh7iHGEq8C4VmIa1vyfdJbTvNDqdi/Ww3g3JgfKe1TpT+2+/zpHGtne6HEgbu5MKTMPayYNcjuENC9sL7iXl765LaPi78MvOLZZ3dmc65/y3WG/meGAFpmE9sNhPuJQ7HhffT7i1i7fkTODy/eJJZuBzVmAa1nM+l2t21SW0S+fm4Qdv5lV/hR+dNNXt/p0jje1M6a9wrvY89swKTMM6s1AvnuZNHF7xKO092xnibNrYF6nAJduchnVJ1Z57jO8sQjt1aR3c8aS/inWe7f6dI43tLPSQNnYnFZiGtZMHuRzDhTOsl869gdkl9cOna7Bqz+g7i72H9hhnV00DU4O0sTupwDSsnTzIOcZU4B0qMA3rRZ/yiW27gAYX1aXxw3rf0wV9ec9qfeJ3bP9pbHv346NzqUHa2J1UYBrWTh7kcgwNKSR7E4e0V7LtnXU2e2fxQBvsvALTsHb+gD+P544nfEovZdo7u24cD6s+/k4rMA1rfw/WJTq4eO50/OANvtXjz2pdoLd/31HZp3OksTQQx1n89TEn+HsFpmH9vRRv6XjTw94O70w+Wdzbud7+PNOw9vcScLcDLqq/O52Lafgu75Xizu5M60X8K+1/9nqiAtOwThTnRUPerLD+SORTs+AN3dH4EH9W6zztv3PZdxrb3ukhbexOKrD/hrWTBzXHmApMBT4+pmHt71Xgwhn6TsQJXcIH9zs04AP/meE87b9z2Xca2/7pciBt7E4qMA1rJw9yOYY3LJxz6awRwDL85V1n96niOed/+cO+2wGmYb3bE//reXd21/PncJ3pnA8d/gyY316nAtOwXudZnbvTfzkkgovqg/vnix+8of+Ih9/SDu5Tf/nEr722fzaN7QDp8yNhFdmRnYa1o4d54ijexOFE2tOG2nu2jcbZtLE7rsA0rP09XN9ZhE7nniq440l/Fes82/07Rxr7KmeZfV5RgaVhXTHLDH2mCrhwhvXS2Zs7rHutEazaM/rO0v7Z9sgPac7kU8NpYlVkR3Ya1o4e5hzlLxWYS/e/lGMfZBrWPp7jeoouqNl0fljve3w3sl5Yl/9sVvM5tv80tj07kw8d2LSxO6nANKydPMjlGN6omhIk0wLt1dDe2c7F4uHVzjT7vaAC07AuKNoLDumeh33B7X/Yd/hYfqWxizzuXiswDWt/T9aFM6yXzvywvrnTnr0KPkRor76jsl/nSGNpII6z+GBHFZiGtaOHecFRvOnhgqFPPcSZfLL41Jt81Ob2tM40rD09zb+dxd0OuKj+m/L17y7c4euM14v4zsqZ1ov41zvF7PhoBaZhHS3LS4verOCN20F8ahY0s3Q+xJ/VOk/771z2ncauexeDVRt/BxWYhrWDhzhHmAq8SwWmYX3zpF8w7MIZ+k7EEVzCB/c7NOAD/5nhPO2/c9l3Gtv+6XIgbexOKjANaycPcjmGNyycc+msEcAy/OVdZ/ep4jnnf/nDvtsBpmG92xP/63nd88Bf1ddmzgPnfOjw2id9w91Pw9rfQ3cBDS6qOx0/eDNv9fizWp/4bffvHGlse0//+Y+EzTD2aSswDetpH81NN+ZNHG468YMma+/Zlo2zaWN3XIFpWPt7uL6zCJ0uzrrjSX+Utaa1gW9dFg+0r7Dm8strLJs2dscVmIa1v4frwhnWS2c8rCf26Rqs2j381mZrOCwO617pPghg24uckM6mseVqXs5kjrSxO6nA7RrWTgoyx3iaCmhIT7OZ2chzVGAa1nM8h1vuwgV1aN44u973uJyH8u5lfWJnbWh9Fg+tTXeJ7jultGPjxRrL4mCcM5kDH+yoAtOwdvQwP4/iDQve+J/SBx4+fuFXa7Pti8WBf2pbckK5bBp7avzEdlKBaVg7eZDfHMOPV+Gb1HPCP85pbbbB/BXpx+xXeV/px+YYbQcVmIa1g4e4OYILZ1gvnfnBm7wh8mDVil1jfcezzulSvPXFzC2eJk4DcTqLgzgN0tfxdHkgjrP4YEcVmIa1o4f5w6N4w/9wyFnp5tVgzkr+Iskc6yeHX6R9KV87/suJJ/C7FZiG9bv1v8fq7nbARfWp+eW4rIZTeT+NmdeFN/vTsfKNsyfAf4prx/90vb3nP9X5pmE91eO4yWY0C1h/JPKpWfCGbiE5sGrFrrHb+eyn9a1nbjZNnAbGirE4iJcrRhNPY2lAl8Pigx1VYBrWjh7mHGUqsPcKTMPa3xN24Qy+y+h0LtaD+x06Kwfwe8Ia9gTWtRaLgzjtK8hpoPtu7gAAEABJREFU/+Uan8Y2li4H0sbupALTsO77IH9jdm9YOOfS2uU4yL/3Xq0B6zo4nLPXddwp33zOdMs5T603sQdWYBrWA4s9Sz2kAu6u4LsPHR6ymVnkthWYhnXbej7DbC6gwUV1++EHb2Y6Kw/4tHvBj2fWgdZi29N3nwiKl2ucfbJpLA3SrYkPdlSBaVg7epgnjuJNHE6kPTzUnthTi4uvKPeYVuzhdha8fwWmYd2/xo9ewR0OrN9h8INYe+JD/FmtPR7bfxr7rHuffd2wAtOwbljMJ5nKJ2qwXjq7hA5tUxOQB/z0Z7TtnW2vLB7at+blU0PnShu7kwpMw9rJg5xjTAXeoQJP07DeodgPOqML6tCSx+56aC6rgV/uM1qf+NkjrPvDQ7rvsJxJDdLG7qQC07B28iCXY3jDgjdysjdwWHU+lPes1nnaP98+7TuNpQUxiI/dSQWmYe3kQX5zDPc94ZvUpwy3d3bdIB5WffydVmAa1v4erAtnWC+d+cEb3KlZecCnPQY/X8XFevvvOyx7TmObVRxn08bupALTsHbyIOcYf6mAZrZ+SvqX4JDXrcA0rNd9dl/t3N0NuKj+Kocux8U04HvBXs+1l+dz1TmmYV1Vvqcc7AIa1h+J/JWY4A3dxuXAqhV7Jus87d9+7c2e01ga0OWw+OBXK3Dbxadh3baeM9tUYCpwxwpMw7pjcR8wtbsaaCm+S/SQHmflpL+K9R2Ti3Ro/6zzhM4iJ8hJH7uDCkzDeu2H2Bvz0lNoBHDp+EeO03zCqXXLYU/lTewFKzAN66kf2rebc08D3yZ+kaBZXTP+i2lHngrcpwLTsO5T10fN6jIaWk/zwUN6nJWTzm457dmgsdo7tF8WD+05zspJH7uDCkzD2sFD3BzBmzQUirNpr2btPbT3OHtKKzb2xSswDet1H6A7Gt95AL+T4CFNPKTtwXZOtvPwgzNv9VUr9gx29nBGBaZhnVGkJ03xxvNXVoBvmyweaEC/9oLePM8EZ+qc63/Vnsa2Xw0MB+PSx75YBaZhvdgDm+1OBd65AtOwXvfpu7cJ6ynS2HTfYbiEhrQ9WH+tKHQe515Bx8vj0wYvWIG9NKwXLP3VW/bG04BAQzLhqtFpQQzir26dxbmB33mcO6SJywN++tgXq8A0rBd7YMt23cWERf5IYz/u+Mv8K1rqmFbsEfbY+se0R+xl1rhxBaZh3bigd5rOhfn2r6B4E9LBdw6WXjU67RZo3tYxZ5p1XGbTAA84GNf+jaMBH/iXwFhzs41vbTadxUF+uXScTRv7xBWYhvXED+fJtuZNvX4ad4vtmVMT+dFcS7Lxa7NcQme5144/a5FJul0FpmHdrpb3nMm/beXuBe65zqm5u7Q+lXMqZu+w5vjuZv2nYdbYOb753Fex5+Rvc6x/zfjtfMPvXIFpWHcu8I2m743lzdWUNG924NO9cfFAuwXMaw22+fDWWfeVxq65cmCdo/il1lywjrduKLbulb/ml7Nq4z9pBaZhPemDmW1NBaYCHx8fmyJMw9oU5AmoexXfBbBtpwtrNl2O+x9IK/8aay5Y57CGtcG6YiwO4jTAAw7iacbRrEGHNPq1MJc5oblop9Zfcxsz9gkrMA3r+R6KS2Twhv5ud3JCubg3aPyn1nhvYPanY3+abw245WW+ucwJ3+1HTvgud+JPUIFpWE/wEDZb6IJ9I59N3cnA2QM2ica6YGc3oaFTgd+twDSs363/sdV9d+Rymi2OhxqJ+FYr/285sZ9ZY829jtLAtmvJSRMvP41NE8fB/HQWB3HaLWAuc0LzrXu1Lp2VE2iDJ6/ANKwnf0Cf2/PmCp/SH5PG/hHu9Jv5V7TMJZoxp8YXu9SaP6xzpLHp/JA29okrMA3r+R6O7wZCu4uz7lzS+RC/hbVGaD5rpPHpbBpLA37AYc3lbzX5tHvBmtYAfuvgIU08jZ8+9gkqMA3rdx+CNwS0C74L95AeZ9PkuhwHfvq11hqhueJsa7E4uOg+lntMM47OGgvrePqtz2RO6wB/uz6dBvyAvwjeY5vTsH73OXvzwLFd+FHlmH5P7au93HPNY3PbBxyLjfbGFZiG9bsPvx891l1oVODTwnQ8rFoXxmLp11qX1qG57MUakMYP4sf0NPFy0+Ks+Kr7L9XVJu1aa43OxG8+fkizl2O5xcf+YgWmYf1i8Y8s7c1TE1rfsGmsnIbyIX6tNZd1Q/Ph1gY+XS4OaXQ84CCexqd9NV7s1rCWdYFvfrY9sTSQE/DBE1VgGtafh/FUv/lRKLSxOJt2L2uN0Bpx9pj2lX4q15gV5T7SHlv/mPbIPc1aJyowDetEce4c8qf4uX9dxCV08IZqa3yIX2vN1Tps87mExsG+6WuuOA3kBBzE04yjsWniNDA/ncVvAWtVa745WesEGsRZOTTg33JP5hz8sALTsH5YsCdL9yaCJ9vWVdvxiaEzsVdNdOPBmirceNqZ7icVmIb1k2rdNtcdSrh0Zn/iw6Xjn3GcS291YW+5P3PCpXO6iF/vui6dZ8ZdUYFpWFcU78qh3jzeAFDTofmELLREnJWTfmtrbmuE5rfHtPbKpomXm8amieNgHJ3FQZwGdJzFbwHnMifwzclaO9AgzsqhAR/4g1+qwDSsXyr8LDsVmAr8vALTsH5es0tGuJPxHQM0nu9iF8TpLB5oEGfl0G453lzmNLc1Ag3E0+RsNXEalMfiII7DT8Yfy01jzResA3FWDu3Y+mJygjyIs3Jo63g+bfALFfhpw/qFLe5iSZe1sF4k870hQgeNs6c0MTkBhziLAz/gIc1etppYmjge0uPiW00sTRwP6XHxrSaWJo6H9Dh7ShOTE3CIszjwAx7S7CVt7IMrMA3rwQWf5aYCU4HLKzAN6/La/WSky16XuGzj+tSJ1mUui4dy46wcuh9NcEhj8SAP4qwc2jreXmhicgINxNPk0I6Np5fH4nDp+NY6Nl7MGsE6EGfl0Na9prFygjyIs3Jo63h7oQ1+oQLTsH6h6J9LejOs+JQ/ztU+Dr/OzT2Wdxj+cUz/u/bxj1+rxi/CD+dq8s/NPZZ3yXjzGBdwiLM48AMe0ti0sQ+uwDSsxxTcn9DBXYhV2a1GT2Nx4AfjaOxWo6exOPCDcTQ2jaUBP+Cw5vK3mnwa8AMOxqTxaZDG4sAP5bJbbZuLQ3mscTQWBz4N8IBDnC2XxYM8iLP44M4VmIZ15wJ/Tu/CPXxKH3HWG4LO4oEGcRaHNZe/1dZcfpAHxqR1kbxqYvKAH+TQ2LTG09NYOV9p3uRy4KvxxoKc0JxsGisP+AGHNZe/1eTTgB9wMCbtu73KH9ypAtOw7lTYN53WG/tNj/7ix36R7U/DesyDcu+xwqr+6kkaHtLYn2ryjQs4xFkc+MFeaJDG4iCOAw78IL7VitHFV06Ls+I0wAMO4luNnsbiwA84xFk84OFczV7KdQEf0sbesQLTsO5Y3GVqnziFZD8SpfHp3jxpLA34QQ6NTbv3ePOfWkvcnqA8FgdxHPi0Y/unywlyaMak8WliaSwN+EEOjU271XjzmivggztXYBrWnQv8Ob0flcKn9BHPfnz+irOf0gc/fCy/0thkfjiliZXH4sAPOMSzNIizOPADDvEsDeIsDvyAQzxLgziLAz/gIY39qSbfuIBDnMUHd67ANKxbFPgfc3jh9u8u+ZO3iL/mEeTQXeJuNbE0Vh7wgxya+beaWBorD/hBDm0dby80sfJYGojjIId2bDxdTsDh0vGtdWy8WOuw1gF+kENb95rGlsfKA36QQ1vH2wtNrDyWFsTyx96wAtOwbljMmWoq8FkBDUyT+6RjblWBaVi3quQ/5nFfEv6hjvdOFfC3GrwG3unMDznrNKzbltmLtMtdfrN7AYd0eWn9aSyWxp4ab4wc4Mu9dLy9nBovbh1oLRYHceMBDziIpxlHY9PEaZDGOg9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4P/y8fFhLzSxNJa2Qnzl49+gAtOwblDEmWIqMBV4TAWmYV1XZ5er0Cz+JHZ/Afx0PJQvvtXE0thHjbcXa321vrj9gBy5q8angZyAg3jaT8Yfy01jm5O1DvCDHNqx9cXKY+UBP8ihreP5NLHyWBqI4yCHNrhRBaZhXV5IL0Yvyj41aiY6rH+FAw/liaex6fxwShMrj8WBH3CIs3jAwV62Gj1NHA/pcfGtJpYmjof0uPhWE0sTx0N6nD2lickJOMRZHPgBD2n2stXE0sRxSBt7owo8uGHdaNfPM417ivW/fH6enc1OpgI7rMA0rMsfqmblAtaPAM1C669qsOn8IIeu0W01epq5cUhjG8/iwJcHOPxkvHxjgR9wOLZXa5bHygN+wOHS8db4ajy9dVgc+KHx7Fbb5uJQHmscjcUDDeIsDny1B+NogxtVYBrWjQr5OY0XqAYG/E/5Aw8fn7/ibLksDvzP1A88fHz+Ek/jk9mtRk9jcTiWu2prLj/I+Wo8vTwWB364x3hzWwf4AQdrpvG3mhgN+AEHY9L4W02MBuIBH9ywAtOwLi+mOwovVOCbicUDDeKsHBqLA58GeMAhzpbL4sCXB3jAIc6Wy+JBHsRZHNZc/lZbc/kA8sAYHPhbjU4DfjiWm7bNxaGxbLksDnx5gAcc4my5LB7kQZzFYc3lb7U1V2zwgwpMw/pBsTapLtvD+sJMc/nakDT2mHZs/Fe5jTdGDvDpLB5oEGdxWHPb66qtufwg56vx9PJYHPjhHuPNbR3gBxysmcbfamI04AccjEm7Za3MPfhBBaZh/aBYkzoVmAr8bgWmYV1efxfJ27uKOCve7HhIE99qYmksDvyAQ5zFAx7O1ezlVK74qTnFHz3eeu2JxYEfcIizeMDDudotz9qaL28fdYBpWJdX2l2ET4KAbyYvfhzS6HiQQxNP49PE0lga8IMcGpt27/HmP7WWuD1BeSwO4jjwacf2T5cT5NCMSePTxNJYGvCDHBqbdu/x5j+1lrg9DS6owDSsC4r2OcS9xopP+eMSzZiPz1/88Cl9xNmP5RcekuPsKU1MTsAhzuLAX0GDSzRjjAV+wCHO4sBfQYNztZ/kHpvz0vHmMhb4AR9cUIFpWOcVzZ+K/qt2thEuYWnghUgXx0GcBngoV3yriaWxxgI/yKGta6Wx5bHygB/k0Nbx9kITK4+lgTgOcmjHxtPlBBwuHd9ax8aLtQ5rHeAHObR1r2lseaw84Ac5tHW8vdDEymNpII6DHNqx8fTBDyswDeu8gvlkyIuPPW/ED7Im9a0r4B98fOsC/OTw07DOq5aLVvcg7HkjJmsqcF4Fjv3TNOeNfMOsaVjnPXTf0rtIZRuBe7FBOouDeLl40Pjo4mnG0cTSWBrwgxyaMWl8mlgaSwN+kEMzJs1eaGJpLA3EcTCOxuIgTgM84CCeZhyNTROnQRprPzRxHIyjieGBBnFWDs0YHPg0MTzQIM7KoRmDg73QxPBAA/E042hsmjhtcEEFpmFdUFjYef8AAA5ZSURBVLQZMhW4uAIz8KoKTMP65/K5q4I14gI1FPOn5ilNvDnKY0+NF5MTHjW+vX61vnh7kmNfq8anQXksDuI4/GT8sdw01nzBOhBn5dCOrS8mJ8iDOCuHto7n08TkBBqIp8nZauI0KI/FB99UYBrWPxfIiwd6scngBxxcwKexNOCDOA54wEE8jaUBP+AQZ/GAh59q8htrLziksTiI44EGcXEc0lgcxPFAg7g4DmksDuJ4oEGcxYEf8JDG/lSTbxzYCw54wEE8jaUBH8RxwAM++KYC07C+KdCEpwJTgeepwGs1rMfUrctRl6qt6N84Cuk+MdxqYmnsT8fLNw7Wy1k8WEMeu9XoaSwO/GAcjU1jacAPOFx6VmPh0vH2+NV4evtkceCD+jWepQFfHuABhzhbLosHeRBncfjJWe0xGDv4pgLTsL4p0GfYvUP4lD7irBf0x+EXiwP/IP35wsMf4fBbnC2XxYF/SPvzhYc/wuE38TT+Qfpg09iPz1/88Cl9rLn8j8Mvtjz2IP354gc5RHar0dNYHPjBOBq71ehpLA78YByNTWNpwAdxHPg04G81Og34AQdj0vhbTYwG/HAsN00uP+CDbyowDeuvBXKf0IuNLcoPcujsVqOnsTjwg3E0dqvR01gc+ME4GrvV6GksDvxgHI1NY2nADzisufytJp8G/ICDMWl8GqSxOPBDuexW2+biUB5rHI3FgU8DPOAgnsbfamI04AccjEnjbzUxGvADDsYEfLBUYBrWUoyD64Xir1bAejmKh0Pan684axzRiw+HS8abx9hgToizOKy5/K225vKDPDAmrb2umpg84Ac5NDat8fQ0Fgd+MI72Ta0+5MsDfmg8m8bKA37AYc3lbzX5NOAHHIxJ66yrJiYP+EEOjU1rPD2NxUGuD30AHywVmIa1FONM17fwZ6ZO2gtWQMN4wW2/x5anYf31OWtGweVp0TQ2TRyHNH4QP6aniZebxqaxOPADDnEWD3g4V7OXU7nip+YUf/R467UnFgd+wCHO4gEP52r3Pqv9uMSH9jT2swLTsD4L8Wm8WPrUxo8sn/Kf/z15epp4Gp9+zng5co05NV5MHvBD49k0c8lbNTEa8IMcGpv23XjxU7ni5oTyWBzEceDTjq1PlxPk0IxJ49PE0lga8IMcGpt27/HmP7WWuD1BeSwO9ioH8HfA2WechvXPpfIjQSgaZ49pX+nHco9pl4w3j3EBhziLAz/gIY09V/tJ7rE5f2O8fVg34BBnceAHPKSx52o/yT025zq++Fvbd29Y/hSDXgR8l52wXoTioVzxtF5Y54wv99h4seZkW4sf5NDXtdLY8lh5wA9yaOt4e6GJlcfSQBwHObRj4+lyAg6Xjm+tY+PFWoe1DvCDHNq61zS2PFYeHFtrHS8u79rx5rBuwMH8adagDT4r8M4Ny4vBi2P91OazLGOmAlOBZ6zAOzcsz8PFJvBfFbPv21bAH2S3nXFmu1kF3rlhdbnJVlDf+vdXc9aL0DS2XHEcjKOzOIjTAA+tJ55mnDyxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaZDG2g9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4GAvNDE80EA8zTgamyZOgzQWB3EcjKMNPivwzg3rswRjpgJTgVepwDs3LH96bS83V43fcyyPTRPHoR8jVo1frpxwLDeNLY991Pj2+tX64vYDcuxr1fg0kBNwEE/7yfhjuWlsc7LWAX6QQzu2vlh5rDw4lrtqfHnXjjeHdQMO5k+zBg3o/3lwVu1A3+vrnRuWy3YPP/Tk4+JbTSxNHA/pcfGtJpYmjof0OHtKE5MTcIizOPADHtLsZauJpYnjIT0uvtXE0sTxkB4X32piaeJ4SI+zpzQxOQGHOIvDuhYe5ID4VqOnieMhPS6+1cTSxPGQ7gMioKe9nX3nhvV2D3sOfFYF3rohnFWhX0x654blr1j4hBBcoHoMLB5oEGdxuHS8Nb4aT7dGwCHONp7FgS8P8IBDnC2XxYM8iLM4XHpWY+HS8fb41Xi6PQYc4i6vG8+m8+VBGosDP5TLprHygB9wuPSsxsKx8XSX8OBHQ/wt8VYNa/OEPfjgBSnMbjV6GosDPxhHY7caPY3FgR+Mo7FpLA34AYc1l7/V5NOAH3AwJo2/1cRowA/HctO2uTg0li2XxYEvD/CAQ5wtl8WDPIiL48Df6qsmJg/4AYc1l7/V5NOAH47lpm1zcWgsu+aKvT3epWH5Nj/00HEvCuDTWTzQIM7KobE48LcanQb8cCw3bZuLQ2PZclkc+PIADzjE2XJZPMiDOIvDmsvfamsuP8gDY9L4W02MBvxwLDdtm4tDY9lyWRz48gAPOIin8beaGA34AQdj0vhbTYwG/ICDMWn8rSZGe0u8S8PqUxe2B+0CM6wvjDSXn8dyj2n3GG8fx9ZKs6Yc4NNZPNAgzuKw5nbWVVtz+UHOV+Pp5bE48MM9xpvbOsAPOFgzjb/VxGjgNYIDDsbg8Ey1sre3wrs0rLd6qHPYj4+PKcIuK/AuDauLUbYH6XLTHQGk8YP4MT1NvNy0OCt+TE8TlwdpLB5wiLM48AMe0thzNXs5lStuPjiWJ35MTxM3FtL4QfyYniZebhqbxuLADzjEWTzg4VzNXk7lip+aU/xW45vnbey7NCw/94ceLu6TJODTvdBwSKPjQQ5NPI1PE9tq9DRWDs0YHPg0MTzQIM7KobE43Hu8+a0D/K/Wp8sJOBiTxqcd2z+9PFYOzRgc+DQxPNAgzsqhsTjce7z5rQP8r9anywk4GJPGpx3bP/3t8C4N6+0e7Bx4KrDHChxvWPs7qYtU6E8sJ8T/7+BAOouD+CH85wsPLmCJ4mnG0dg0cRqksafGi8kJxkKclUNb1+LTxOQEGsRZOTRjcGivYniQB+JpxtHYNHEapLE4iONgHI3FQZwGeLAfmniacTSxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaW+Jd2lYXlzQJzxv+bDn0FOBV6/AuzQsdwCwXni++rOb/U8F3q4C79KwtpeYHjTNX3UA33LTWBzEaYAHjY8mnmYcjU0Tp0Eae2q8mJxgLMRZObR1LT5NTE6gQZyVQzPmXz4+PmjtVQwP8kA8zTgamyZOgzQWB3EcjKOxOIjTAA/2QxNPM44mlsbSgB/k0IxJ49PE0lga8IMcmjFp9kITS2NpII6DcTQWB3Ea4AEH8TTjaGyaOO0t8S4N6y0f7hx6KrC3Crxzw/KnlgtMcL/l2a4anwZywrHcNLa8a8ebx9rAD9agmX+riaWx8oAf5NDW8XyaWHksDcRxkLPVxGkgJ+AgnvaT8cdy09jmZK0D/CCHdmx9sfJYecAPcmjreD5NrDyWBuI4yNlq4jSQE3AQT2s8nQ/8t8U7NywX8F4AsL4AcBBPx0OaeBpLZ4M4DdJYHMTxQIM4iwM/4CGN/akm3ziwFxzwgIN4GksDPojjgAccxNNYGvBBHAc84CCextKAH3CIs3jAw081+Y21FxzSWBzE8UCDuDgOaSwO4niggb8WpJHR8Uvw8mPeuWG9/MObA7xVBXxg5N7srQ69Pew7Nyx/TccFJvRCYOmhesVZOXQvIBzSWDzIgzgrh3ZsPF1OwCHONp7FgS8PcHAuHPBQLpvGygN+wOHYXh8x3hpfrU9vnywO/NB4dqttc3EojzWOxuKBBnEWh3vUyrx+VPRM7QV/S7xzw/LgQw8f98IAfjoejmnlsuXxj+Ue08plG88ey01bc/l01jjg0wAPOIin8beaGA344Vhu2jYXh8ay5bI48OUBHnCIs+WyeJAHcRaHNZe/1dZcfpAHxqTxt5oYDfjhWG7aNheHxrJrrtjb450b1rGH735gRTlePEGczp7SxOQBPxhHY7caPY3FgR+Mo7FbjZ7G4sAPxtHYNJYG/IDDmsvfavJpwA84GJPG32piNOCHY7lp21wcGsuWy+LAlwd4wCHOlsviQR7EWRzWXP5WW3P5QR4YE/DBUoFpWEsxDq4XiotNcMl5kP588cMf4fBbnDXuIH2wOLg8/fj8hYdP6SPOGkdn8UCDOIvDmsvfamsuP8gDY9La66qJyQN+kENj0xpPT2Nx4AfjaGzatePNY07gBxzWtfhbTT4N+AEHY9La66qJyQN+kENj0xpPT2NxkOv1B3za4LMC07A+CzFmKjAVeP4KTMP66zNyZxBcnhZNY9PEcUjjB/Fjepp4uWlsGosDP+AQZ/GAh3M1ezmVK35qTvFHj7dee2Jx4Acc4iwe8PAX7UDoB/Pnix/ufVbruMQH/p8NzG9/q8A0rL/Vod+9QHwSA+4W0vEghy6exqeJbTV6GiuHZgwOfJoYHmgQZ+XQWBzuPd781gH+V+vT5QQcjEnj047tn14eK4dmDA58mhgeaBBn5dBYHO493vzWAf5X69PlBBzs1TjAB0sFpmEtxRh3KjAVeO4KTMN67ufzTLv7yQXwT3Kf6YyzlyevwF0a1pOfebZ3ugKajX8sbpvlkyyxVceP/ejiE641b/ypwE0qMA3rJmXc1STuUPxTJttDuWsRW3X8WMM6Nn4dN/5U4KIKTMO6qGwzaCowFfiNCkzD+o2q72nNOctU4IEVmIb1wGLPUlOBqcB1FZiGdV39ZvRUYCrwwApMw3pgsWepqcBrV+D3dz8N6/efwexgKjAVOLMC07DOLNSkTQWmAr9fgWlYv/8MZgdTganAmRWYhnVmoa5PmxmmAlOBayswDevaCs74qcBU4GEVmIb1sFLPQlOBqcC1FZiGdW0FZ/xU4J8rMMqdKjAN606FnWmnAlOB21dgGtbtazozTgWmAneqwDSsOxV2pp0KTAVuX4H/DwAA//9sB2hHAAAABklEQVQDAB9QlitZA9bLAAAAAElFTkSuQmCC", + width: "248", + height: "248", + style: { mixBlendMode: "multiply" } + } + ) + } + ) }); } // routes/connectors-home/ai-plugin-callout.tsx +var import_jsx_runtime43 = __toESM(require_jsx_runtime()); var AI_PLUGIN_SLUG = "ai"; var AI_PLUGIN_PAGE_SLUG = "ai-wp-admin"; var AI_PLUGIN_ID = "ai/ai"; @@ -12204,14 +12448,14 @@ function AiPluginCallout() { ); setJustActivated(true); createSuccessNotice( - (0, import_i18n8.__)("AI plugin installed and activated successfully."), + (0, import_i18n9.__)("AI plugin installed and activated successfully."), { id: "ai-plugin-install-success", type: "snackbar" } ); } catch { - createErrorNotice((0, import_i18n8.__)("Failed to install the AI plugin."), { + createErrorNotice((0, import_i18n9.__)("Failed to install the AI plugin."), { id: "ai-plugin-install-error", type: "snackbar" }); @@ -12229,12 +12473,12 @@ function AiPluginCallout() { { throwOnError: true } ); setJustActivated(true); - createSuccessNotice((0, import_i18n8.__)("AI plugin activated successfully."), { + createSuccessNotice((0, import_i18n9.__)("AI plugin activated successfully."), { id: "ai-plugin-activate-success", type: "snackbar" }); } catch { - createErrorNotice((0, import_i18n8.__)("Failed to activate the AI plugin."), { + createErrorNotice((0, import_i18n9.__)("Failed to activate the AI plugin."), { id: "ai-plugin-activate-error", type: "snackbar" }); @@ -12260,63 +12504,70 @@ function AiPluginCallout() { const hideButtons = pluginStatus === "not-installed" && canInstallPlugins === false; const getMessage = () => { if (isJustConnected) { - return (0, import_i18n8.__)( + return (0, import_i18n9.__)( "The AI plugin is ready to use. You can use it to generate featured images, alt text, titles, excerpts and more. Learn more" ); } if (isActiveNoProvider) { - return (0, import_i18n8.__)( + return (0, import_i18n9.__)( "The AI plugin is installed. Connect an AI provider below to generate featured images, alt text, titles, excerpts, and more. Learn more" ); } - return (0, import_i18n8.__)( + return (0, import_i18n9.__)( "The AI plugin can use your AI connectors to generate featured images, alt text, titles, excerpts and more. Learn more" ); }; const getPrimaryButtonProps = () => { if (pluginStatus === "not-installed") { return { - label: isBusy ? (0, import_i18n8.__)("Installing\u2026") : (0, import_i18n8.__)("Install the AI plugin"), + label: isBusy ? (0, import_i18n9.__)("Installing\u2026") : (0, import_i18n9.__)("Install the AI plugin"), disabled: isBusy, onClick: isBusy ? void 0 : installPlugin }; } return { - label: isBusy ? (0, import_i18n8.__)("Activating\u2026") : (0, import_i18n8.__)("Activate the AI plugin"), + label: isBusy ? (0, import_i18n9.__)("Activating\u2026") : (0, import_i18n9.__)("Activate the AI plugin"), disabled: isBusy, onClick: isBusy ? void 0 : activatePlugin }; }; - return /* @__PURE__ */ React.createElement("div", { className: "ai-plugin-callout" }, /* @__PURE__ */ React.createElement("div", { className: "ai-plugin-callout__content" }, /* @__PURE__ */ React.createElement("p", null, (0, import_element35.createInterpolateElement)(getMessage(), { - strong: /* @__PURE__ */ React.createElement("strong", null), - // @ts-expect-error `children` is injected by `createInterpolateElement` at runtime. - a: /* @__PURE__ */ React.createElement(import_components3.ExternalLink, { href: AI_PLUGIN_URL }) - })), !hideButtons && (showInstallActivate ? /* @__PURE__ */ React.createElement( - import_components3.Button, - { - variant: "primary", - size: "compact", - isBusy, - disabled: getPrimaryButtonProps().disabled, - accessibleWhenDisabled: true, - onClick: getPrimaryButtonProps().onClick - }, - getPrimaryButtonProps().label - ) : /* @__PURE__ */ React.createElement( - import_components3.Button, - { - ref: actionButtonRef, - variant: "secondary", - size: "compact", - href: (0, import_url.addQueryArgs)("options-general.php", { - page: AI_PLUGIN_PAGE_SLUG - }) - }, - (0, import_i18n8.__)("Control features in the AI plugin") - ))), /* @__PURE__ */ React.createElement(WpLogoDecoration, null)); + return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "ai-plugin-callout", children: [ + /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)("div", { className: "ai-plugin-callout__content", children: [ + /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("p", { children: (0, import_element35.createInterpolateElement)(getMessage(), { + strong: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("strong", {}), + // @ts-expect-error `children` is injected by `createInterpolateElement` at runtime. + a: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(import_components3.ExternalLink, { href: AI_PLUGIN_URL }) + }) }), + !hideButtons && (showInstallActivate ? /* @__PURE__ */ (0, import_jsx_runtime43.jsx)( + import_components3.Button, + { + variant: "primary", + size: "compact", + isBusy, + disabled: getPrimaryButtonProps().disabled, + accessibleWhenDisabled: true, + onClick: getPrimaryButtonProps().onClick, + children: getPrimaryButtonProps().label + } + ) : /* @__PURE__ */ (0, import_jsx_runtime43.jsx)( + import_components3.Button, + { + ref: actionButtonRef, + variant: "secondary", + size: "compact", + href: (0, import_url.addQueryArgs)("options-general.php", { + page: AI_PLUGIN_PAGE_SLUG + }), + children: (0, import_i18n9.__)("Control features in the AI plugin") + } + )) + ] }), + /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(WpLogoDecoration, {}) + ] }); } // routes/connectors-home/stage.tsx +var import_jsx_runtime44 = __toESM(require_jsx_runtime()); var { store } = unlock2(connectorsPrivateApis2); registerDefaultConnectors(); function ConnectorsPage() { @@ -12349,7 +12600,9 @@ function ConnectorsPage() { (connector) => connector.type === "ai_provider" ).map( (connector) => connector.plugin?.file?.split("/")[0] - ).filter((slug) => !!slug) + ).filter( + (slug) => !!slug + ) ) ).sort(); const installedPluginSlugs = new Set( @@ -12366,86 +12619,96 @@ function ConnectorsPage() { (slug) => !installedPluginSlugs.has(slug) ); const isEmpty = renderableConnectors.length === 0; - return /* @__PURE__ */ React.createElement( + return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( page_default, { - title: (0, import_i18n9.__)("Connectors"), - subTitle: (0, import_i18n9.__)( + title: (0, import_i18n10.__)("Connectors"), + subTitle: (0, import_i18n10.__)( "All of your API keys and credentials are stored here and shared across plugins. Configure once and use everywhere." - ) - }, - /* @__PURE__ */ React.createElement( - "div", - { - className: `connectors-page${isEmpty ? " connectors-page--empty" : ""}` - }, - manualInstallPluginSlugs.length > 0 && (isFileModDisabled || !canInstallPlugins) && /* @__PURE__ */ React.createElement( - notice_exports.Root, - { - intent: "info", - className: "connectors-page__file-mods-notice" - }, - /* @__PURE__ */ React.createElement(notice_exports.Description, null, isFileModDisabled ? (0, import_i18n9.__)( - "Plugins cannot be installed here due to your site configuration. Install them manually using your normal deployment workflow." - ) : (0, import_i18n9.__)( - "You do not have permission to install plugins. Please ask a site administrator to install them for you." - )) ), - isEmpty ? /* @__PURE__ */ React.createElement( - import_components4.__experimentalVStack, + children: /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)( + "div", { - alignment: "center", - spacing: 3, - style: { maxWidth: 480 } - }, - /* @__PURE__ */ React.createElement(import_components4.__experimentalVStack, { alignment: "center", spacing: 2 }, /* @__PURE__ */ React.createElement(import_components4.__experimentalHeading, { level: 2, size: 15 }, (0, import_i18n9.__)("No connectors yet")), /* @__PURE__ */ React.createElement(import_components4.__experimentalText, { size: 12 }, (0, import_i18n9.__)( - "Connectors appear here when you install plugins that use external services. Each plugin registers the API keys it needs, and you manage them all in one place." - ))), - /* @__PURE__ */ React.createElement( - import_components4.Button, - { - variant: "secondary", - href: "plugin-install.php", - __next40pxDefaultSize: true - }, - (0, import_i18n9.__)("Learn more") - ) - ) : /* @__PURE__ */ React.createElement(import_components4.__experimentalVStack, { spacing: 3 }, /* @__PURE__ */ React.createElement(AiPluginCallout, null), /* @__PURE__ */ React.createElement(import_components4.__experimentalVStack, { spacing: 3, role: "list" }, connectors.map( - (connector) => { - if (connector.render) { - return /* @__PURE__ */ React.createElement( - connector.render, + className: `connectors-page${isEmpty ? " connectors-page--empty" : ""}`, + children: [ + manualInstallPluginSlugs.length > 0 && (isFileModDisabled || !canInstallPlugins) && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( + notice_exports.Root, { - key: connector.slug, - slug: connector.slug, - name: connector.name, - description: connector.description, - type: connector.type, - logo: connector.logo, - authentication: connector.authentication, - plugin: connector.plugin + intent: "info", + className: "connectors-page__file-mods-notice", + children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(notice_exports.Description, { children: isFileModDisabled ? (0, import_i18n10.__)( + "Plugins cannot be installed here due to your site configuration. Install them manually using your normal deployment workflow." + ) : (0, import_i18n10.__)( + "You do not have permission to install plugins. Please ask a site administrator to install them for you." + ) }) } - ); - } - return null; - } - ))), - canInstallPlugins && !isFileModDisabled && /* @__PURE__ */ React.createElement("p", null, (0, import_element36.createInterpolateElement)( - (0, import_i18n9.__)( - "If the connector you need is not listed, search the plugin directory to see if a connector is available." - ), - { - a: ( - // eslint-disable-next-line jsx-a11y/anchor-has-content - /* @__PURE__ */ React.createElement("a", { href: "plugin-install.php?s=connector&tab=search&type=tag" }) - ) + ), + isEmpty ? /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)( + import_components4.__experimentalVStack, + { + alignment: "center", + spacing: 3, + style: { maxWidth: 480 }, + children: [ + /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_components4.__experimentalVStack, { alignment: "center", spacing: 2, children: [ + /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_components4.__experimentalHeading, { level: 2, size: 15, children: (0, import_i18n10.__)("No connectors yet") }), + /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_components4.__experimentalText, { size: 12, children: (0, import_i18n10.__)( + "Connectors appear here when you install plugins that use external services. Each plugin registers the API keys it needs, and you manage them all in one place." + ) }) + ] }), + /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( + import_components4.Button, + { + variant: "secondary", + href: "plugin-install.php", + __next40pxDefaultSize: true, + children: (0, import_i18n10.__)("Learn more") + } + ) + ] + } + ) : /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(import_components4.__experimentalVStack, { spacing: 3, children: [ + /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(AiPluginCallout, {}), + /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(import_components4.__experimentalVStack, { spacing: 3, role: "list", children: connectors.map( + (connector) => { + if (connector.render) { + return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( + connector.render, + { + slug: connector.slug, + name: connector.name, + description: connector.description, + type: connector.type, + logo: connector.logo, + authentication: connector.authentication, + plugin: connector.plugin + }, + connector.slug + ); + } + return null; + } + ) }) + ] }), + canInstallPlugins && !isFileModDisabled && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("p", { children: (0, import_element36.createInterpolateElement)( + (0, import_i18n10.__)( + "If the connector you need is not listed, search the plugin directory to see if a connector is available." + ), + { + a: ( + // eslint-disable-next-line jsx-a11y/anchor-has-content + /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("a", { href: "plugin-install.php?s=connector&tab=search&type=tag" }) + ) + } + ) }) + ] } - )) - ) + ) + } ); } function Stage() { - return /* @__PURE__ */ React.createElement(ConnectorsPage, null); + return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(ConnectorsPage, {}); } var stage = Stage; export { diff --git a/src/wp-includes/build/routes/connectors-home/content.min.asset.php b/src/wp-includes/build/routes/connectors-home/content.min.asset.php index ebf36d49cadba..1dda70de8f9a3 100644 --- a/src/wp-includes/build/routes/connectors-home/content.min.asset.php +++ b/src/wp-includes/build/routes/connectors-home/content.min.asset.php @@ -1 +1 @@ - array('react', 'react-dom', 'react-jsx-runtime', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-private-apis', 'wp-theme', 'wp-url'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/connectors', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '5dd79b91fcc9e57d6786'); \ No newline at end of file + array('react', 'react-dom', 'react-jsx-runtime', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-private-apis', 'wp-theme', 'wp-url', 'wp-warning'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/connectors', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '9c97839e08e086000847'); \ No newline at end of file diff --git a/src/wp-includes/build/routes/connectors-home/content.min.js b/src/wp-includes/build/routes/connectors-home/content.min.js index a126dc05f98d2..2296c11a9ccd8 100644 --- a/src/wp-includes/build/routes/connectors-home/content.min.js +++ b/src/wp-includes/build/routes/connectors-home/content.min.js @@ -1,4 +1,4 @@ -var If=Object.create;var Rr=Object.defineProperty;var Mf=Object.getOwnPropertyDescriptor;var Bf=Object.getOwnPropertyNames;var Hf=Object.getPrototypeOf,zf=Object.prototype.hasOwnProperty;var Re=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Ot=(e,t)=>{for(var o in t)Rr(e,o,{get:t[o],enumerable:!0})},Df=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Bf(t))!zf.call(e,r)&&r!==o&&Rr(e,r,{get:()=>t[r],enumerable:!(n=Mf(t,r))||n.enumerable});return e};var b=(e,t,o)=>(o=e!=null?If(Hf(e)):{},Df(t||!e||!e.__esModule?Rr(o,"default",{value:e,enumerable:!0}):o,e));var lt=Re((M0,ea)=>{ea.exports=window.wp.i18n});var ce=Re((H0,oa)=>{oa.exports=window.wp.element});var z=Re((z0,na)=>{na.exports=window.React});var K=Re((U0,aa)=>{aa.exports=window.ReactJSXRuntime});var Mt=Re((Zh,Ia)=>{Ia.exports=window.ReactDOM});var Fc=Re(jc=>{"use strict";var ho=z();function Vm(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Wm=typeof Object.is=="function"?Object.is:Vm,Ym=ho.useState,Um=ho.useEffect,Gm=ho.useLayoutEffect,Xm=ho.useDebugValue;function Km(e,t){var o=t(),n=Ym({inst:{value:o,getSnapshot:t}}),r=n[0].inst,i=n[1];return Gm(function(){r.value=o,r.getSnapshot=t,ci(r)&&i({inst:r})},[e,o,t]),Um(function(){return ci(r)&&i({inst:r}),e(function(){ci(r)&&i({inst:r})})},[e]),Xm(o),o}function ci(e){var t=e.getSnapshot;e=e.value;try{var o=t();return!Wm(e,o)}catch{return!0}}function qm(e,t){return t()}var Zm=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?qm:Km;jc.useSyncExternalStore=ho.useSyncExternalStore!==void 0?ho.useSyncExternalStore:Zm});var li=Re((z1,Vc)=>{"use strict";Vc.exports=Fc()});var Yc=Re(Wc=>{"use strict";var Dn=z(),Qm=li();function Jm(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var $m=typeof Object.is=="function"?Object.is:Jm,eg=Qm.useSyncExternalStore,tg=Dn.useRef,og=Dn.useEffect,ng=Dn.useMemo,rg=Dn.useDebugValue;Wc.useSyncExternalStoreWithSelector=function(e,t,o,n,r){var i=tg(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=ng(function(){function l(m){if(!c){if(c=!0,d=m,m=n(m),r!==void 0&&s.hasValue){var u=s.value;if(r(u,m))return f=u}return f=m}if(u=f,$m(d,m))return u;var g=n(m);return r!==void 0&&r(u,g)?(d=m,u):(d=m,f=g)}var c=!1,d,f,p=o===void 0?null:o;return[function(){return l(t())},p===null?void 0:function(){return l(p())}]},[t,o,n,r]);var a=eg(e,i[0],i[1]);return og(function(){s.hasValue=!0,s.value=a},[a]),rg(a),a}});var Gc=Re((j1,Uc)=>{"use strict";Uc.exports=Yc()});var $t=Re((g4,xd)=>{xd.exports=window.wp.primitives});var Od=Re((H4,Ad)=>{Ad.exports=window.wp.theme});var ts=Re((z4,Nd)=>{Nd.exports=window.wp.privateApis});var tn=Re((P3,Gu)=>{Gu.exports=window.wp.components});var nn=Re((j3,ef)=>{ef.exports=window.wp.data});var hr=Re((F3,tf)=>{tf.exports=window.wp.coreData});var Us=Re((Y3,nf)=>{nf.exports=window.wp.notices});var sf=Re((U3,rf)=>{rf.exports=window.wp.url});function ta(e){var t,o,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;te();function Y(e){let t=Se(Wf).current;return t.next=e,Vf(t.effect),t.trampoline}function Wf(){let e={next:void 0,callback:Yf,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function Yf(){}var sa=b(z(),1),Uf=()=>{},D=typeof document<"u"?sa.useLayoutEffect:Uf;var bn=b(z(),1),Er=bn.createContext(void 0);function so(){return bn.useContext(Er)?.direction??"ltr"}function Gf(e,t){return function(n,...r){let i=new URL(e);return i.searchParams.set("code",n.toString()),r.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${n}; visit ${i} for the full message.`}}var Xf=Gf("https://base-ui.com/production-error","Base UI"),ke=Xf;var Wt=b(z(),1);function Tr(e,t,o,n){let r=Se(la).current;return Kf(r,e,t,o,n)&&da(r,[e,t,o,n]),r.callback}function ca(e){let t=Se(la).current;return qf(t,e)&&da(t,e),t.callback}function la(){return{callback:null,cleanup:null,refs:[]}}function Kf(e,t,o,n,r){return e.refs[0]!==t||e.refs[1]!==o||e.refs[2]!==n||e.refs[3]!==r}function qf(e,t){return e.refs.length!==t.length||e.refs.some((o,n)=>o!==t[n])}function da(e,t){if(e.refs=t,t.every(o=>o==null)){e.callback=null;return}e.callback=o=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),o!=null){let n=Array(t.length).fill(null);for(let r=0;r{for(let r=0;r=e}function kr(e){if(!fa.isValidElement(e))return null;let t=e,o=t.props;return(ao(19)?o?.ref:t.ref)??null}function Mo(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function Nt(){}var eh=Object.freeze([]),be=Object.freeze({});function pa(e,t){let o={};for(let n in e){let r=e[n];if(t?.hasOwnProperty(n)){let i=t[n](r);i!=null&&Object.assign(o,i);continue}r===!0?o[`data-${n.toLowerCase()}`]="":r&&(o[`data-${n.toLowerCase()}`]=r.toString())}return o}function ma(e,t){return typeof e=="function"?e(t):e}function ga(e,t){return typeof e=="function"?e(t):e}var Pr={};function we(e,t,o,n,r){if(!o&&!n&&!r&&!e)return hn(t);let i=hn(e);return t&&(i=Bo(i,t)),o&&(i=Bo(i,o)),n&&(i=Bo(i,n)),r&&(i=Bo(i,r)),i}function ba(e){if(e.length===0)return Pr;if(e.length===1)return hn(e[0]);let t=hn(e[0]);for(let o=1;o=65&&r<=90&&(typeof t=="function"||typeof t>"u")}function Cr(e){return typeof e=="function"}function wa(e,t){return Cr(e)?e(t):e??Pr}function $f(e,t){return t?e?(...o)=>{let n=o[0];if(_a(n)){let i=n;Ho(i);let s=t(...o);return i.baseUIHandlerPrevented||e?.(...o),s}let r=t(...o);return e?.(...o),r}:va(t):e}function va(e){return e&&((...t)=>{let o=t[0];return _a(o)&&Ho(o),e(...t)})}function Ho(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Ar(e,t){return t?e?t+" "+e:t:e}function _a(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var Or=b(z(),1);function Pe(e,t,o={}){let n=t.render,r=ep(t,o);if(o.enabled===!1)return null;let i=o.state??be;return np(e,n,r,i)}function ep(e,t={}){let{className:o,style:n,render:r}=e,{state:i=be,ref:s,props:a,stateAttributesMapping:l,enabled:c=!0}=t,d=c?ma(o,i):void 0,f=c?ga(n,i):void 0,p=c?pa(i,l):be,m=c&&a?tp(a):void 0,u=c?Mo(p,m)??{}:be;return typeof document<"u"&&(c?Array.isArray(s)?u.ref=ca([u.ref,kr(r),...s]):u.ref=Tr(u.ref,kr(r),s):Tr(null,null)),c?(d!==void 0&&(u.className=Ar(u.className,d)),f!==void 0&&(u.style=Mo(u.style,f)),u):be}function tp(e){return Array.isArray(e)?ba(e):we(void 0,e)}var op=Symbol.for("react.lazy");function np(e,t,o,n){if(t){if(typeof t=="function")return t(o,n);let r=we(o,t.props);r.ref=o.ref;let i=t;return i?.$$typeof===op&&(i=Wt.Children.toArray(t)[0]),Wt.cloneElement(i,r)}if(e&&typeof e=="string")return rp(e,o);throw new Error(ke(8))}function rp(e,t){return e==="button"?(0,Or.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,Or.createElement)("img",{alt:"",...t,key:t.key}):Wt.createElement(e,t)}var wn=b(z(),1);var ya=0;function ip(e,t="mui"){let[o,n]=wn.useState(e),r=e||o;return wn.useEffect(()=>{o==null&&(ya+=1,n(`${t}-${ya}`))},[o,t]),r}var xa=Io.useId;function Lt(e,t){if(xa!==void 0){let o=xa();return e??(t?`${t}-${o}`:o)}return ip(e,t)}function Ra(e){return Lt(e,"base-ui")}var U={};Ot(U,{cancelOpen:()=>Lp,chipRemovePress:()=>gp,clearPress:()=>mp,closePress:()=>fp,closeWatcher:()=>Tp,decrementPress:()=>wp,disabled:()=>Mp,drag:()=>Ap,escapeKey:()=>Ep,focusOut:()=>Sp,imperativeAction:()=>zp,incrementPress:()=>hp,initial:()=>Hp,inputBlur:()=>yp,inputChange:()=>vp,inputClear:()=>_p,inputPaste:()=>xp,inputPress:()=>Rp,itemPress:()=>up,keyboard:()=>Pp,linkPress:()=>pp,listNavigation:()=>kp,missing:()=>Bp,none:()=>sp,outsidePress:()=>dp,pointer:()=>Cp,scrub:()=>Np,siblingOpen:()=>Ip,swipe:()=>Dp,trackPress:()=>bp,triggerFocus:()=>lp,triggerHover:()=>cp,triggerPress:()=>ap,wheel:()=>Op,windowResize:()=>jp});var sp="none",ap="trigger-press",cp="trigger-hover",lp="trigger-focus",dp="outside-press",up="item-press",fp="close-press",pp="link-press",mp="clear-press",gp="chip-remove-press",bp="track-press",hp="increment-press",wp="decrement-press",vp="input-change",_p="input-clear",yp="input-blur",xp="input-paste",Rp="input-press",Sp="focus-out",Ep="escape-key",Tp="close-watcher",kp="list-navigation",Pp="keyboard",Cp="pointer",Ap="drag",Op="wheel",Np="scrub",Lp="cancel-open",Ip="sibling-open",Mp="disabled",Bp="missing",Hp="initial",zp="imperative-action",Dp="swipe",jp="window-resize";function ee(e,t,o,n){let r=!1,i=!1,s=n??be;return{reason:e,event:t??new Event("base-ui"),cancel(){r=!0},allowPropagation(){i=!0},get isCanceled(){return r},get isPropagationAllowed(){return i},trigger:o,...s}}var Lr=b(z(),1);var Sa=b(z(),1),Fp=[];function co(e){Sa.useEffect(e,Fp)}var vn=null,kh=globalThis.requestAnimationFrame,Nr=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let o=this.callbacks,n=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,n>0)for(let r=0;r=this.callbacks.length||(this.callbacks[o]=null,this.callbacksCount-=1)}},_n=new Nr,dt=class e{static create(){return new e}static request(t){return _n.request(t)}static cancel(t){return _n.cancel(t)}currentId=vn;request(t){this.cancel(),this.currentId=_n.request(()=>{this.currentId=vn,t()})}cancel=()=>{this.currentId!==vn&&(_n.cancel(this.currentId),this.currentId=vn)};disposeEffect=()=>this.cancel};function lo(){let e=Se(dt.create).current;return co(e.disposeEffect),e}function Ea(e,t=!1,o=!1){let[n,r]=Lr.useState(e&&t?"idle":void 0),[i,s]=Lr.useState(e);return e&&!i&&(s(!0),r("starting")),!e&&i&&n!=="ending"&&!o&&r("ending"),!e&&!i&&n==="ending"&&r(void 0),D(()=>{if(!e&&i&&n!=="ending"&&o){let a=dt.request(()=>{r("ending")});return()=>{dt.cancel(a)}}},[e,i,n,o]),D(()=>{if(!e||t)return;let a=dt.request(()=>{r(void 0)});return()=>{dt.cancel(a)}},[t,e]),D(()=>{if(!e||!t)return;e&&i&&n!=="idle"&&r("starting");let a=dt.request(()=>{r("idle")});return()=>{dt.cancel(a)}},[t,e,i,n]),{mounted:i,setMounted:s,transitionStatus:n}}var Yt=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),Vp={[Yt.startingStyle]:""},Wp={[Yt.endingStyle]:""},Ta={transitionStatus(e){return e==="starting"?Vp:e==="ending"?Wp:null}};var fo=b(z(),1);function yn(){return typeof window<"u"}function Gt(e){return xn(e)?(e.nodeName||"").toLowerCase():"#document"}function me(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function ft(e){var t;return(t=(xn(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function xn(e){return yn()?e instanceof Node||e instanceof me(e).Node:!1}function F(e){return yn()?e instanceof Element||e instanceof me(e).Element:!1}function ye(e){return yn()?e instanceof HTMLElement||e instanceof me(e).HTMLElement:!1}function uo(e){return!yn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof me(e).ShadowRoot}function zo(e){let{overflow:t,overflowX:o,overflowY:n,display:r}=Ie(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+o)&&r!=="inline"&&r!=="contents"}function ka(e){return/^(table|td|th)$/.test(Gt(e))}function Do(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var Yp=/transform|translate|scale|rotate|perspective|filter/,Up=/paint|layout|strict|content/,Ut=e=>!!e&&e!=="none",Ir;function Rn(e){let t=F(e)?Ie(e):e;return Ut(t.transform)||Ut(t.translate)||Ut(t.scale)||Ut(t.rotate)||Ut(t.perspective)||!Sn()&&(Ut(t.backdropFilter)||Ut(t.filter))||Yp.test(t.willChange||"")||Up.test(t.contain||"")}function Pa(e){let t=ut(e);for(;ye(t)&&!pt(t);){if(Rn(t))return t;if(Do(t))return null;t=ut(t)}return null}function Sn(){return Ir==null&&(Ir=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Ir}function pt(e){return/^(html|body|#document)$/.test(Gt(e))}function Ie(e){return me(e).getComputedStyle(e)}function jo(e){return F(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ut(e){if(Gt(e)==="html")return e;let t=e.assignedSlot||e.parentNode||uo(e)&&e.host||ft(e);return uo(t)?t.host:t}function Ca(e){let t=ut(e);return pt(t)?(e.ownerDocument||e).body:ye(t)&&zo(t)?t:Ca(t)}function It(e,t,o){var n;t===void 0&&(t=[]),o===void 0&&(o=!0);let r=Ca(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),s=me(r);if(i){let a=En(s);return t.concat(s,s.visualViewport||[],zo(r)?r:[],a&&o?It(a):[])}else return t.concat(r,It(r,[],o))}function En(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}var Tn=b(z(),1),Gp=Tn.createContext(void 0);function Aa(e=!1){let t=Tn.useContext(Gp);if(t===void 0&&!e)throw new Error(ke(16));return t}var Oa=b(z(),1);function Na(e){let{focusableWhenDisabled:t,disabled:o,composite:n=!1,tabIndex:r=0,isNativeButton:i}=e,s=n&&t!==!1,a=n&&t===!1;return{props:Oa.useMemo(()=>{let c={onKeyDown(d){o&&t&&d.key!=="Tab"&&d.preventDefault()}};return n||(c.tabIndex=r,!i&&o&&(c.tabIndex=t?r:-1)),(i&&(t||s)||!i&&o)&&(c["aria-disabled"]=o),i&&(!t||a)&&(c.disabled=o),c},[n,o,t,s,a,i,r])}}function La(e={}){let{disabled:t=!1,focusableWhenDisabled:o,tabIndex:n=0,native:r=!0,composite:i}=e,s=fo.useRef(null),a=Aa(!0),l=i??a!==void 0,{props:c}=Na({focusableWhenDisabled:o,disabled:t,composite:l,tabIndex:n,isNativeButton:r}),d=fo.useCallback(()=>{let m=s.current;Mr(m)&&l&&t&&c.disabled===void 0&&m.disabled&&(m.disabled=!1)},[t,c.disabled,l]);D(d,[d]);let f=fo.useCallback((m={})=>{let{onClick:u,onMouseDown:g,onKeyUp:v,onKeyDown:_,onPointerDown:w,...y}=m;return we({onClick(h){if(t){h.preventDefault();return}u?.(h)},onMouseDown(h){t||g?.(h)},onKeyDown(h){if(t||(Ho(h),_?.(h),h.baseUIHandlerPrevented))return;let T=h.target===h.currentTarget,x=h.currentTarget,R=Mr(x),E=!r&&Xp(x),k=T&&(r?R:!E),C=h.key==="Enter",W=h.key===" ",O=x.getAttribute("role"),L=O?.startsWith("menuitem")||O==="option"||O==="gridcell";if(T&&l&&W){if(h.defaultPrevented&&L)return;h.preventDefault(),E||r&&R?(x.click(),h.preventBaseUIHandler()):k&&(u?.(h),h.preventBaseUIHandler());return}k&&(!r&&(W||C)&&h.preventDefault(),!r&&C&&u?.(h))},onKeyUp(h){if(!t){if(Ho(h),v?.(h),h.target===h.currentTarget&&r&&l&&Mr(h.currentTarget)&&h.key===" "){h.preventDefault();return}h.baseUIHandlerPrevented||h.target===h.currentTarget&&!r&&!l&&h.key===" "&&u?.(h)}},onPointerDown(h){if(t){h.preventDefault();return}w?.(h)}},r?{type:"button"}:{role:"button"},c,y)},[t,c,l,r]),p=Y(m=>{s.current=m,d()});return{getButtonProps:f,buttonRef:p}}function Mr(e){return ye(e)&&e.tagName==="BUTTON"}function Xp(e){return!!(e?.tagName==="A"&&e?.href)}function re(e,t,o,n){return e.addEventListener(t,o,n),()=>{e.removeEventListener(t,o,n)}}function He(e){let t=Se(Kp,e).current;return t.next=e,D(t.effect),t}function Kp(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}function xe(e){return e?.ownerDocument||document}var Ha=b(z(),1);var Ba=b(Mt(),1);function Ma(e){return e==null?e:"current"in e?e.current:e}function po(e,t=!1,o=!0){let n=lo();return Y((r,i=null)=>{n.cancel();let s=Ma(e);if(s==null)return;let a=s,l=()=>{Ba.flushSync(r)};if(typeof a.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){r();return}function c(){Promise.all(a.getAnimations().map(d=>d.finished)).then(()=>{i?.aborted||l()}).catch(()=>{if(o){i?.aborted||l();return}let d=a.getAnimations();!i?.aborted&&d.length>0&&d.some(f=>f.pending||f.playState!=="finished")&&c()})}if(t){let d=Yt.startingStyle;if(!a.hasAttribute(d)){n.request(c);return}let f=new MutationObserver(()=>{a.hasAttribute(d)||(f.disconnect(),c())});f.observe(a,{attributes:!0,attributeFilter:[d]}),i?.addEventListener("abort",()=>f.disconnect(),{once:!0});return}n.request(c)})}function kn(e){let{enabled:t=!0,open:o,ref:n,onComplete:r}=e,i=Y(r),s=po(n,o,!1);Ha.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,o,i,s])}var za=b(z(),1);function Da(e){let t=za.useRef(!0);t.current&&(t.current=!1,e())}var Rt={};Ot(Rt,{engine:()=>jr,env:()=>Vr,os:()=>zr,screenReader:()=>Fr});var zr={};Ot(zr,{android:()=>Va,apple:()=>Hr,ios:()=>Br,linux:()=>$p,mac:()=>Wa,windows:()=>Jp});function qp(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:Zp,platform:Qp,maxTouchPoints:ja}=qp(),Xt=Zp.toLowerCase(),Kt=Qp.toLowerCase();var Br=/^i(os$|p)/.test(Kt)||Kt==="macintel"&&ja>1,Fa="android",Va=Kt===Fa||Xt.includes(Fa),Wa=!Br&&Kt.startsWith("mac"),Jp=Kt.startsWith("win"),$p=!Va&&/^(linux|chrome os)/.test(Kt),Hr=Wa||Br;var jr={};Ot(jr,{blink:()=>tm,gecko:()=>em,webkit:()=>Dr});var Dr=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),em=!Dr&&Xt.includes("firefox"),tm=!Dr&&Xt.includes("chrom");var Fr={};Ot(Fr,{voiceOver:()=>om});var om=Hr;var Vr={};Ot(Vr,{jsdom:()=>nm});var nm=/jsdom|happydom/.test(Xt);var Fo=0,We=class e{static create(){return new e}currentId=Fo;start(t,o){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Fo,o()},t)}isStarted(){return this.currentId!==Fo}clear=()=>{this.currentId!==Fo&&(clearTimeout(this.currentId),this.currentId=Fo)};disposeEffect=()=>this.clear};function ot(){let e=Se(We.create).current;return co(e.disposeEffect),e}var Ce=b(z(),1);function Ya(e){return"nativeEvent"in e}function St(e,t){let o=["mouse","pen"];return t||o.push("",void 0),o.includes(e)}function Ua(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var Wr="data-base-ui-focusable";var Yr="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Pn(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function ie(e,t){if(!e||!t)return!1;let o=t.getRootNode?.();if(e.contains(t))return!0;if(o&&uo(o)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function Me(e){return"composedPath"in e?e.composedPath()[0]:e.target}function Bt(e,t){if(!F(e))return!1;let o=e;if(t.hasElement(o))return!o.hasAttribute("data-trigger-disabled");for(let[,n]of t.entries())if(ie(n,o))return!n.hasAttribute("data-trigger-disabled");return!1}function Cn(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let o=e;return o.target!=null&&t.contains(o.target)}function Ga(e){return e.matches("html,body")}function Xa(e){return ye(e)&&e.matches(Yr)}function Ur(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${Yr}`)!=null}function Ka(e){if(!e||Rt.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function rm(e,t){return t!=null&&!St(t)?0:typeof e=="function"?e():e}function Et(e,t,o){let n=rm(e,o);return typeof n=="number"?n:n?.[t]}function Gr(e){return typeof e=="function"?e():e}function An(e,t){return t||e==="click"||e==="mousedown"}function qa(e){return e?.includes("mouse")&&e!=="mousedown"}var Za=b(K(),1),Qa=Ce.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new We,currentIdRef:{current:null},currentContextRef:{current:null}});function im(e,t){e.current=t.current}function Xr(e){let{children:t,delay:o,timeoutMs:n=0}=e,r=Ce.useRef(o),i=Ce.useRef(o),s=Ce.useRef(null),a=Ce.useRef(null),l=ot();return D(()=>{if(i.current=o,!s.current){r.current=o;return}r.current={open:Et(r.current,"open"),close:Et(o,"close")}},[o,s,r,i]),(0,Za.jsx)(Qa.Provider,{value:Ce.useMemo(()=>({hasProvider:!0,delayRef:r,initialDelayRef:i,currentIdRef:s,timeoutMs:n,currentContextRef:a,timeout:l}),[n,l]),children:t})}function Kr(e,t={open:!1}){let{open:o}=t,n="rootStore"in e?e.rootStore:e,r=n.useState("floatingId"),i=Ce.useContext(Qa),{currentIdRef:s,delayRef:a,timeoutMs:l,initialDelayRef:c,currentContextRef:d,hasProvider:f,timeout:p}=i,[m,u]=Ce.useState(!1),g=Ce.useRef(o),v=Ce.useRef(!1);return D(()=>{g.current=o},[o]),D(()=>()=>{v.current=!0},[]),D(()=>{function _(){v.current||u(!1),d.current?.setIsInstantPhase(!1),s.current=null,d.current=null,a.current=c.current,p.clear()}if(s.current&&!o&&s.current===r){if(u(!1),l){let w=r;return p.start(l,()=>{n.select("open")||s.current&&s.current!==w||_()}),()=>{(g.current||s.current!==w)&&p.clear()}}_()}},[o,r,s,a,l,c,d,p,n]),D(()=>{if(!o)return;let _=d.current,w=s.current;p.clear(),d.current={onOpenChange:n.setOpen,setIsInstantPhase:u},s.current=r,a.current={open:0,close:Et(c.current,"close")},w!==null&&w!==r?(u(!0),_?.setIsInstantPhase(!0),_?.onOpenChange(!1,ee(U.none))):(u(!1),_?.setIsInstantPhase(!1))},[o,r,n,s,a,c,d,p]),D(()=>()=>{if(s.current===r){if(d.current=null,!g.current)return;s.current=null,im(a,c),p.clear()}},[d,s,a,r,c,p]),Ce.useMemo(()=>({hasProvider:f,delayRef:a,isInstantPhase:m}),[f,a,m])}function nt(...e){return()=>{for(let t=0;t({x:e,y:e}),sm={left:"right",right:"left",bottom:"top",top:"bottom"};function Nn(e,t,o){return rt(e,Ht(t,o))}function it(e,t){return typeof e=="function"?e(t):e}function Ae(e){return e.split("-")[0]}function st(e){return e.split("-")[1]}function Ln(e){return e==="x"?"y":"x"}function Yo(e){return e==="y"?"height":"width"}function ze(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function Uo(e){return Ln(ze(e))}function tc(e,t,o){o===void 0&&(o=!1);let n=st(e),r=Uo(e),i=Yo(r),s=r==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Vo(s)),[s,Vo(s)]}function oc(e){let t=Vo(e);return[On(e),t,On(t)]}function On(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var Ja=["left","right"],$a=["right","left"],am=["top","bottom"],cm=["bottom","top"];function lm(e,t,o){switch(e){case"top":case"bottom":return o?t?$a:Ja:t?Ja:$a;case"left":case"right":return t?am:cm;default:return[]}}function nc(e,t,o,n){let r=st(e),i=lm(Ae(e),o==="start",n);return r&&(i=i.map(s=>s+"-"+r),t&&(i=i.concat(i.map(On)))),i}function Vo(e){let t=Ae(e);return sm[t]+e.slice(t.length)}function dm(e){var t,o,n,r;return{top:(t=e.top)!=null?t:0,right:(o=e.right)!=null?o:0,bottom:(n=e.bottom)!=null?n:0,left:(r=e.left)!=null?r:0}}function In(e){return typeof e!="number"?dm(e):{top:e,right:e,bottom:e,left:e}}function qt(e){let{x:t,y:o,width:n,height:r}=e;return{width:n,height:r,top:o,left:t,right:t+n,bottom:o+r,x:t,y:o}}function Tt(e,t,o=!0){return e.filter(r=>r.parentId===t).flatMap(r=>[...!o||r.context?.open?[r]:[],...Tt(e,r.id,o)])}function mo(e){return`data-base-ui-${e}`}var Ye=b(z(),1),sc=b(Mt(),1);var rc={style:{transition:"none"}};var um="data-base-ui-swipe-ignore",fm="data-swipe-ignore",zw=`[${um}]`,Dw=`[${fm}]`;var ic={fallbackAxisSide:"end"};var ac=b(K(),1),pm=Ye.createContext(null),mm=()=>Ye.useContext(pm),gm=mo("portal");function qr(e={}){let{ref:t,container:o,componentProps:n=be,elementProps:r}=e,i=Lt(),a=mm()?.portalNode,[l,c]=Ye.useState(null),[d,f]=Ye.useState(null),p=Y(v=>{v!==null&&f(v)}),m=Ye.useRef(null);D(()=>{if(o===null){m.current&&(m.current=null,f(null),c(null));return}if(i==null)return;let v=(o&&(xn(o)?o:o.current))??a??document.body;if(v==null){m.current&&(m.current=null,f(null),c(null));return}m.current!==v&&(m.current=v,f(null),c(v))},[o,a,i]);let u=Pe("div",n,{ref:[t,p],props:[{id:i,[gm]:""},r]});return{portalNode:d,portalSubtree:l&&u?sc.createPortal(u,l):null}}var Zt=b(z(),1);function cc(){let e=new Map;return{emit(t,o){e.get(t)?.forEach(n=>n(o))},on(t,o){e.has(t)||e.set(t,new Set),e.get(t).add(o)},off(t,o){e.get(t)?.delete(o)}}}var bm=b(K(),1),hm=Zt.createContext(null),wm=Zt.createContext(null),go=()=>Zt.useContext(hm)?.id||null,Dt=e=>{let t=Zt.useContext(wm);return e??t};var De=b(z(),1);function vm(e,t){let o=null,n=null,r=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",l=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",c=i.width,d=i.height,f=i.x,p=i.y;return o==null&&t.x&&s&&(o=i.x-t.x),n==null&&t.y&&a&&(n=i.y-t.y),f-=o||0,p-=n||0,c=0,d=0,!r||l?(c=t.axis==="y"?i.width:0,d=t.axis==="x"?i.height:0,f=s&&t.x!=null?t.x:f,p=a&&t.y!=null?t.y:p):r&&!l&&(d=t.axis==="x"?i.height:d,c=t.axis==="y"?i.width:c),r=!0,{width:c,height:d,x:f,y:p,top:p,right:f+c,bottom:p+d,left:f}}}}function lc(e){return e!=null&&e.clientX!=null}function Zr(e,t={}){let{enabled:o=!0,axis:n="both"}=t,r="rootStore"in e?e.rootStore:e,i=r.useState("open"),s=r.useState("floatingElement"),a=r.useState("domReferenceElement"),l=r.context.dataRef,c=De.useRef(!1),d=De.useRef(null),[f,p]=De.useState(),[m,u]=De.useState([]),g=Y(h=>{r.set("positionReference",h)}),v=Y((h,T,x)=>{c.current||l.current.openEvent&&!lc(l.current.openEvent)||r.set("positionReference",vm(x??a,{x:h,y:T,axis:n,dataRef:l,pointerType:f}))}),_=Y(h=>{i?d.current||(v(h.clientX,h.clientY,h.currentTarget),u([])):v(h.clientX,h.clientY,h.currentTarget)}),w=St(f)?s:i;De.useEffect(()=>{if(!o){g(a);return}if(!w)return;function h(){d.current?.(),d.current=null}let T=me(s);function x(R){let E=Me(R);ie(s,E)?h():v(R.clientX,R.clientY)}return!l.current.openEvent||lc(l.current.openEvent)?d.current=re(T,"mousemove",x):g(a),h},[w,o,s,l,a,r,v,g,m]),De.useEffect(()=>()=>{r.set("positionReference",null)},[r]),De.useEffect(()=>{o&&!s&&(c.current=!1)},[o,s]),De.useEffect(()=>{!o&&i&&(c.current=!0)},[o,i]);let y=De.useMemo(()=>{function h(T){p(T.pointerType)}return{onPointerDown:h,onPointerEnter:h,onMouseMove:_,onMouseEnter:_}},[_]);return De.useMemo(()=>o?{reference:y,trigger:y}:{},[o,y])}var je=b(z(),1);function _m(){return!1}function ym(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function Qr(e,t={}){let{enabled:o=!0,escapeKey:n=!0,outsidePress:r=!0,outsidePressEvent:i="sloppy",referencePress:s=_m,bubbles:a,externalTree:l}=t,c="rootStore"in e?e.rootStore:e,d=c.useState("open"),f=c.useState("floatingElement"),{dataRef:p}=c.context,m=Dt(l),u=Y(typeof r=="function"?r:()=>!1),g=typeof r=="function"?u:r,v=g!==!1,_=Y(()=>i),{escapeKey:w,outsidePress:y}=ym(a),h=je.useRef(!1),T=je.useRef(!1),x=je.useRef(!1),R=je.useRef(!1),E=je.useRef(""),k=je.useRef(null),C=ot(),W=ot(),O=Y(()=>{W.clear(),p.current.insideReactTree=!1}),L=Y(V=>{let oe=p.current.floatingContext?.nodeId;return(m?Tt(m.nodesRef.current,oe):[]).some(se=>se.context?.open&&!se.context.dataRef.current[V])}),I=Y(V=>Cn(V,c.select("floatingElement"))||Cn(V,c.select("domReferenceElement"))),S=Y(V=>{s()&&c.setOpen(!1,ee(U.triggerPress,V.nativeEvent))}),N=Y(V=>{if(!d||!o||!n||V.key!=="Escape"||R.current||!w&&L("__escapeKeyBubbles"))return;let oe=Ya(V)?V.nativeEvent:V,te=ee(U.escapeKey,oe);c.setOpen(!1,te),te.isCanceled||V.preventDefault(),!w&&!te.isPropagationAllowed&&V.stopPropagation()}),H=Y(()=>{p.current.insideReactTree=!0,W.start(0,O)}),P=Y(V=>{if(!d||!o||V.button!==0)return;let oe=Me(V.nativeEvent);ie(c.select("floatingElement"),oe)&&(h.current||(h.current=!0,T.current=!1))}),A=Y(V=>{!d||!o||(V.defaultPrevented||V.nativeEvent.defaultPrevented)&&h.current&&(T.current=!0)});je.useEffect(()=>{if(!d||!o)return;p.current.__escapeKeyBubbles=w,p.current.__outsidePressBubbles=y;let V=new We,oe=new We;function te(){V.clear(),R.current=!0}function se(){V.start(Rt.engine.webkit?5:0,()=>{R.current=!1})}function G(){x.current=!0,oe.start(0,()=>{x.current=!1})}function q(){h.current=!1,T.current=!1}function J(){let B=E.current,j=B==="pen"||!B?"mouse":B,he=_(),Te=typeof he=="function"?he():he;return typeof Te=="string"?Te:Te[j]}function ne(B){let j=J();return j==="intentional"&&B.type!=="click"||j==="sloppy"&&B.type==="click"}function ge(B){let j=p.current.floatingContext?.nodeId,he=m&&Tt(m.nodesRef.current,j).some(Te=>Cn(B,Te.context?.elements.floating));return I(B)||he}function de(B){if(ne(B)){B.type!=="click"&&!I(B)&&(oe.clear(),x.current=!1),O();return}if(p.current.insideReactTree){O();return}let j=Me(B),he=`[${mo("inert")}]`,Te=F(j)?j.getRootNode():null,Pt=Array.from((uo(Te)?Te:xe(c.select("floatingElement"))).querySelectorAll(he)),No=c.context.triggerElements;if(j&&(No.hasElement(j)||No.hasMatchingElement(Ve=>ie(Ve,j))))return;let yt=F(j)?j:null;for(;yt&&!pt(yt);){let Ve=ut(yt);if(pt(Ve)||!F(Ve))break;yt=Ve}if(!(Pt.length&&F(j)&&!Ga(j)&&!ie(j,c.select("floatingElement"))&&Pt.every(Ve=>!ie(yt,Ve)))){if(ye(j)&&!("touches"in B)){let Ve=pt(j),Ct=Ie(j),At=/auto|scroll/,dn=Ve||At.test(Ct.overflowX),un=Ve||At.test(Ct.overflowY),fn=dn&&j.clientWidth>0&&j.scrollWidth>j.clientWidth,pn=un&&j.clientHeight>0&&j.scrollHeight>j.clientHeight,mn=Ct.direction==="rtl",ae=pn&&(mn?B.offsetX<=j.offsetWidth-j.clientWidth:B.offsetX>j.clientWidth),Le=fn&&B.offsetY>j.clientHeight;if(ae||Le)return}if(!ge(B)){if(J()==="intentional"&&x.current){oe.clear(),x.current=!1;return}typeof g=="function"&&!g(B)||L("__outsidePressBubbles")||(c.setOpen(!1,ee(U.outsidePress,B)),O())}}}function X(B){J()!=="sloppy"||B.pointerType==="touch"||!c.select("open")||!o||I(B)||de(B)}function pe(B){if(J()!=="sloppy"||!c.select("open")||!o||I(B))return;let j=B.touches[0];j&&(k.current={startTime:Date.now(),startX:j.clientX,startY:j.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},C.start(1e3,()=>{k.current&&(k.current.dismissOnTouchEnd=!1,k.current.dismissOnMouseDown=!1)}))}function ue(B,j){let he=Me(B);if(!he)return;let Te=re(he,B.type,()=>{j(B),Te()})}function _t(B){E.current="touch",ue(B,pe)}function Ee(B){C.clear(),B.type==="pointerdown"&&(E.current=B.pointerType),!(B.type==="mousedown"&&k.current&&!k.current.dismissOnMouseDown)&&ue(B,j=>{j.type==="pointerdown"?X(j):de(j)})}function Fe(B){if(!h.current)return;let j=T.current;if(q(),J()==="intentional"){if(B.type==="pointercancel"){j&&G();return}if(!ge(B)){if(j){G();return}typeof g=="function"&&!g(B)||(oe.clear(),x.current=!0,O())}}}function Xe(B){if(J()!=="sloppy"||!k.current||I(B))return;let j=B.touches[0];if(!j)return;let he=Math.abs(j.clientX-k.current.startX),Te=Math.abs(j.clientY-k.current.startY),Pt=Math.sqrt(he*he+Te*Te);Pt>5&&(k.current.dismissOnTouchEnd=!0),Pt>10&&(de(B),C.clear(),k.current=null)}function Be(B){ue(B,Xe)}function no(B){J()!=="sloppy"||!k.current||I(B)||(k.current.dismissOnTouchEnd&&de(B),C.clear(),k.current=null)}function ln(B){ue(B,no)}let _e=xe(f),ro=nt(n&&nt(re(_e,"keydown",N),re(_e,"compositionstart",te),re(_e,"compositionend",se)),v&&nt(re(_e,"click",Ee,!0),re(_e,"pointerdown",Ee,!0),re(_e,"pointerup",Fe,!0),re(_e,"pointercancel",Fe,!0),re(_e,"mousedown",Ee,!0),re(_e,"mouseup",Fe,!0),re(_e,"touchstart",_t,!0),re(_e,"touchmove",Be,!0),re(_e,"touchend",ln,!0)));return()=>{ro(),V.clear(),oe.clear(),q(),x.current=!1}},[p,f,n,v,g,d,o,w,y,N,O,_,L,I,m,c,C]),je.useEffect(O,[g,O]);let M=je.useMemo(()=>({onKeyDown:N,onPointerDown:S,onClick:S}),[N,S]),Q=je.useMemo(()=>({onKeyDown:N,onPointerDown:A,onMouseDown:A,onClickCapture:H,onMouseDownCapture(V){H(),P(V)},onPointerDownCapture(V){H(),P(V)},onMouseUpCapture:H,onTouchEndCapture:H,onTouchMoveCapture:H}),[N,H,P,A]);return je.useMemo(()=>o?{reference:M,floating:Q,trigger:M}:{},[o,M,Q])}var Oe=b(z(),1);function dc(e,t,o){let{reference:n,floating:r}=e,i=ze(t),s=Uo(t),a=Yo(s),l=Ae(t),c=i==="y",d=n.x+n.width/2-r.width/2,f=n.y+n.height/2-r.height/2,p=n[a]/2-r[a]/2,m;switch(l){case"top":m={x:d,y:n.y-r.height};break;case"bottom":m={x:d,y:n.y+n.height};break;case"right":m={x:n.x+n.width,y:f};break;case"left":m={x:n.x-r.width,y:f};break;default:m={x:n.x,y:n.y}}let u=st(t);return u&&(m[s]+=p*(u==="end"?1:-1)*(o&&c?-1:1)),m}async function pc(e,t){var o;t===void 0&&(t={});let{x:n,y:r,platform:i,rects:s,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:p=!1,padding:m=0}=it(t,e),u=In(m),v=a[p?f==="floating"?"reference":"floating":f],_=qt(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(v)))==null||o?v:v.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:d,strategy:l})),w=f==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,y=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),h=await(i.isElement==null?void 0:i.isElement(y))&&await(i.getScale==null?void 0:i.getScale(y))||{x:1,y:1},T=qt(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:w,offsetParent:y,strategy:l}):w);return{top:(_.top-T.top+u.top)/h.y,bottom:(T.bottom-_.bottom+u.bottom)/h.y,left:(_.left-T.left+u.left)/h.x,right:(T.right-_.right+u.right)/h.x}}var xm=50,mc=async(e,t,o)=>{let{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:s}=o,a=s.detectOverflow?s:{...s,detectOverflow:pc},l=await(s.isRTL==null?void 0:s.isRTL(t)),c=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:d,y:f}=dc(c,n,l),p=n,m=0,u={};for(let g=0;gI<=0)){var W,O;let I=(((W=i.flip)==null?void 0:W.index)||0)+1,S=R[I];if(S&&(!(f==="alignment"?w!==ze(S):!1)||C.every(P=>ze(P.placement)===w?P.overflows[0]>0:!0)))return{data:{index:I,overflows:C},reset:{placement:S}};let N=(O=C.filter(H=>H.overflows[0]<=0).sort((H,P)=>H.overflows[1]-P.overflows[1])[0])==null?void 0:O.placement;if(!N)switch(m){case"bestFit":{var L;let H=(L=C.filter(P=>{if(x){let A=ze(P.placement);return A===w||A==="y"}return!0}).map(P=>[P.placement,P.overflows.filter(A=>A>0).reduce((A,M)=>A+M,0)]).sort((P,A)=>P[1]-A[1])[0])==null?void 0:L[0];H&&(N=H);break}case"initialPlacement":N=a;break}if(r!==N)return{reset:{placement:N}}}return{}}}};function uc(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function fc(e){return ec.some(t=>e[t]>=0)}var bc=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){let{rects:o,platform:n}=t,{strategy:r="referenceHidden",...i}=it(e,t);switch(r){case"referenceHidden":{let s=await n.detectOverflow(t,{...i,elementContext:"reference"}),a=uc(s,o.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:fc(a)}}}case"escaped":{let s=await n.detectOverflow(t,{...i,altBoundary:!0}),a=uc(s,o.floating);return{data:{escapedOffsets:a,escaped:fc(a)}}}default:return{}}}}};var hc=new Set(["left","top"]);async function Rm(e,t){let{placement:o,platform:n,elements:r}=e,i=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=Ae(o),a=st(o),l=ze(o)==="y",c=hc.has(s)?-1:1,d=i&&l?-1:1,f=it(t,e),{mainAxis:p,crossAxis:m,alignmentAxis:u}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&typeof u=="number"&&(m=a==="end"?u*-1:u),l?{x:m*d,y:p*c}:{x:p*c,y:m*d}}var wc=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var o,n;let{x:r,y:i,placement:s,middlewareData:a}=t,l=await Rm(t,e);return s===((o=a.offset)==null?void 0:o.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:i+l.y,data:{...l,placement:s}}}}},vc=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:o,y:n,placement:r,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:l={fn:w=>{let{x:y,y:h}=w;return{x:y,y:h}}},...c}=it(e,t),d={x:o,y:n},f=await i.detectOverflow(t,c),p=ze(r),m=Ln(p),u=d[m],g=d[p],v=(w,y)=>Nn(y+f[w==="y"?"top":"left"],y,y-f[w==="y"?"bottom":"right"]);s&&(u=v(m,u)),a&&(g=v(p,g));let _=l.fn({...t,[m]:u,[p]:g});return{..._,data:{x:_.x-o,y:_.y-n,enabled:{[m]:s,[p]:a}}}}}},_c=function(e){return e===void 0&&(e={}),{options:e,fn(t){var o,n;let{x:r,y:i,placement:s,rects:a,middlewareData:l}=t,{offset:c=0,mainAxis:d=!0,crossAxis:f=!0}=it(e,t),p={x:r,y:i},m=ze(s),u=Ln(m),g=p[u],v=p[m],_=it(c,t),w=typeof _=="number"?{mainAxis:_,crossAxis:0}:{mainAxis:(o=_.mainAxis)!=null?o:0,crossAxis:(n=_.crossAxis)!=null?n:0};if(d){let T=u==="y"?"height":"width",x=a.reference[u]-a.floating[T]+w.mainAxis,R=a.reference[u]+a.reference[T]-w.mainAxis;gR&&(g=R)}if(f){var y,h;let T=u==="y"?"width":"height",x=hc.has(Ae(s)),R=a.reference[m]-a.floating[T]+(x&&((y=l.offset)==null?void 0:y[m])||0)+(x?0:w.crossAxis),E=a.reference[m]+a.reference[T]+(x?0:((h=l.offset)==null?void 0:h[m])||0)-(x?w.crossAxis:0);vE&&(v=E)}return{[u]:g,[m]:v}}}},yc=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:o,rects:n,platform:r,elements:i}=t,{apply:s=()=>{},...a}=it(e,t),l=await r.detectOverflow(t,a),c=Ae(o),d=st(o),f=ze(o)==="y",{width:p,height:m}=n.floating,u,g;c==="top"||c==="bottom"?(u=c,g=d===(await(r.isRTL==null?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(g=c,u=d==="end"?"top":"bottom");let v=m-l.top-l.bottom,_=p-l.left-l.right,w=Ht(m-l[u],v),y=Ht(p-l[g],_),h=t.middlewareData.shift,T=!h,x=w,R=y;h!=null&&h.enabled.x&&(R=_),h!=null&&h.enabled.y&&(x=v),T&&!d&&(f?R=p-2*rt(l.left,l.right):x=m-2*rt(l.top,l.bottom)),await s({...t,availableWidth:R,availableHeight:x});let E=await r.getDimensions(i.floating);return p!==E.width||m!==E.height?{reset:{rects:!0}}:{}}}};function Sc(e){let t=Ie(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=ye(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n,a=zt(o)!==i||zt(n)!==s;return a&&(o=i,n=s),{width:o,height:n,$:a}}function $r(e){return F(e)?e:e.contextElement}function bo(e){let t=$r(e);if(!ye(t))return mt(1);let o=t.getBoundingClientRect(),{width:n,height:r,$:i}=Sc(t),s=(i?zt(o.width):o.width)/n,a=(i?zt(o.height):o.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Sm=mt(0);function Ec(e){let t=me(e);return!Sn()||!t.visualViewport?Sm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function Em(e,t,o){return t===void 0&&(t=!1),!!o&&t&&o===me(e)}function Qt(e,t,o,n){t===void 0&&(t=!1),o===void 0&&(o=!1);let r=e.getBoundingClientRect(),i=$r(e),s=mt(1);t&&(n?F(n)&&(s=bo(n)):s=bo(e));let a=Em(i,o,n)?Ec(i):mt(0),l=(r.left+a.x)/s.x,c=(r.top+a.y)/s.y,d=r.width/s.x,f=r.height/s.y;if(i&&n){let p=me(i),m=F(n)?me(n):n,u=p,g=En(u);for(;g&&m!==u;){let v=bo(g),_=g.getBoundingClientRect(),w=Ie(g),y=_.left+(g.clientLeft+parseFloat(w.paddingLeft))*v.x,h=_.top+(g.clientTop+parseFloat(w.paddingTop))*v.y;l*=v.x,c*=v.y,d*=v.x,f*=v.y,l+=y,c+=h,u=me(g),g=En(u)}}return qt({width:d,height:f,x:l,y:c})}function Mn(e,t){let o=jo(e).scrollLeft;return t?t.left+o:Qt(ft(e)).left+o}function Tc(e,t){let o=e.getBoundingClientRect(),n=o.left+t.scrollLeft-Mn(e,o),r=o.top+t.scrollTop;return{x:n,y:r}}function Tm(e){let{elements:t,rect:o,offsetParent:n,strategy:r}=e,i=r==="fixed",s=ft(n),a=t?Do(t.floating):!1;if(n===s||a&&i)return o;let l={scrollLeft:0,scrollTop:0},c=mt(1),d=mt(0),f=ye(n);if((f||!i)&&((Gt(n)!=="body"||zo(s))&&(l=jo(n)),f)){let m=Qt(n);c=bo(n),d.x=m.x+n.clientLeft,d.y=m.y+n.clientTop}let p=s&&!f&&!i?Tc(s,l):mt(0);return{width:o.width*c.x,height:o.height*c.y,x:o.x*c.x-l.scrollLeft*c.x+d.x+p.x,y:o.y*c.y-l.scrollTop*c.y+d.y+p.y}}function km(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function Pm(e){let t=jo(e),o=e.ownerDocument.body,n=rt(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),r=rt(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight),i=-t.scrollLeft+Mn(e),s=-t.scrollTop;return Ie(o).direction==="rtl"&&(i+=rt(e.clientWidth,o.clientWidth)-n),{width:n,height:r,x:i,y:s}}var Cm=25;function Am(e,t,o){o===void 0&&(o="viewport");let n=o==="layoutViewport",r=me(e),i=ft(e),s=r.visualViewport,a=i.clientWidth,l=i.clientHeight,c=0,d=0;if(s){let p=!Sn()||t==="fixed";n?p||(c=-s.offsetLeft,d=-s.offsetTop):(a=s.width,l=s.height,p&&(c=s.offsetLeft,d=s.offsetTop))}if(Mn(i)<=0){let p=i.ownerDocument,m=p.body,u=getComputedStyle(m),g=p.compatMode==="CSS1Compat"&&parseFloat(u.marginLeft)+parseFloat(u.marginRight)||0,v=Math.abs(i.clientWidth-m.clientWidth-g),_=getComputedStyle(i).scrollbarGutter==="stable both-edges"?v/2:v;_<=Cm&&(a-=_)}return{width:a,height:l,x:c,y:d}}function Om(e,t){let o=Qt(e,!0,t==="fixed"),n=o.top+e.clientTop,r=o.left+e.clientLeft,i=bo(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,l=r*i.x,c=n*i.y;return{width:s,height:a,x:l,y:c}}function xc(e,t,o){let n;if(t==="viewport"||t==="layoutViewport")n=Am(e,o,t);else if(t==="document")n=Pm(ft(e));else if(F(t))n=Om(t,o);else{let r=Ec(e);n={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return qt(n)}function Nm(e,t){let o=t.get(e);if(o)return o;let n=It(e,[],!1).filter(a=>F(a)&&Gt(a)!=="body"),r=null,i=Ie(e).position==="fixed",s=i?ut(e):e;for(;F(s)&&!pt(s);){let a=Ie(s),l=Rn(s),c=r?r.position:i?"fixed":"";!l&&(c==="fixed"||c==="absolute"&&a.position==="static")?n=n.filter(f=>f!==s):r=a,s=ut(s)}return t.set(e,n),n}function Lm(e){let{element:t,boundary:o,rootBoundary:n,strategy:r}=e,s=[...o==="clippingAncestors"?Do(t)?[]:Nm(t,this._c):[].concat(o),n],a=xc(t,s[0],r),l=a.top,c=a.right,d=a.bottom,f=a.left;for(let p=1;p{a(!1,1e-7)},1e3)}R=!1}try{n=new IntersectionObserver(E,{...x,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,x)}n.observe(e)}let l=me(e),c=()=>a(o);return l.addEventListener("resize",c),a(!0),()=>{l.removeEventListener("resize",c),s()}}function Go(e,t,o,n){n===void 0&&(n={});let{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=$r(e),d=r||i?[...c?It(c):[],...t?It(t):[]]:[];d.forEach(_=>{r&&_.addEventListener("scroll",o),i&&_.addEventListener("resize",o)});let f=c&&a?zm(c,o,i):null,p=-1,m=null;s&&(m=new ResizeObserver(_=>{let[w]=_;w&&w.target===c&&m&&t&&(m.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var y;(y=m)==null||y.observe(t)})),o()}),c&&!l&&m.observe(c),t&&m.observe(t));let u,g=l?Qt(e):null;l&&v();function v(){let _=Qt(e);g&&!Pc(g,_)&&o(),g=_,u=requestAnimationFrame(v)}return o(),()=>{var _;d.forEach(w=>{r&&w.removeEventListener("scroll",o),i&&w.removeEventListener("resize",o)}),f?.(),(_=m)==null||_.disconnect(),m=null,l&&cancelAnimationFrame(u)}}var Cc=wc;var Ac=vc,Oc=gc,Nc=yc,Lc=bc;var Ic=_c,Bn=(e,t,o)=>{let n=new Map,r=o??{},i={...ei,...r.platform,_c:n};return mc(e,t,{...r,platform:i})};var ve=b(z(),1),Bc=b(z(),1),Hc=b(Mt(),1),jm=typeof document<"u",Fm=function(){},Hn=jm?Bc.useLayoutEffect:Fm;function zn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let o,n,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(o=e.length,o!==t.length)return!1;for(n=o;n--!==0;)if(!zn(e[n],t[n]))return!1;return!0}if(r=Object.keys(e),o=r.length,o!==Object.keys(t).length)return!1;for(n=o;n--!==0;)if(!{}.hasOwnProperty.call(t,r[n]))return!1;for(n=o;n--!==0;){let i=r[n];if(!(i==="_owner"&&e.$$typeof)&&!zn(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function zc(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Mc(e,t){let o=zc(e);return Math.round(t*o)/o}function ti(e){let t=ve.useRef(e);return Hn(()=>{t.current=e}),t}function Dc(e){e===void 0&&(e={});let{placement:t="bottom",strategy:o="absolute",middleware:n=[],platform:r,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:l,open:c}=e,[d,f]=ve.useState({x:0,y:0,strategy:o,placement:t,middlewareData:{},isPositioned:!1}),[p,m]=ve.useState(n);zn(p,n)||m(n);let[u,g]=ve.useState(null),[v,_]=ve.useState(null),w=ve.useCallback(P=>{P!==x.current&&(x.current=P,g(P))},[]),y=ve.useCallback(P=>{P!==R.current&&(R.current=P,_(P))},[]),h=i||u,T=s||v,x=ve.useRef(null),R=ve.useRef(null),E=ve.useRef(d),k=l!=null,C=ti(l),W=ti(r),O=ti(c),L=ve.useCallback(()=>{if(!x.current||!R.current)return;let P={placement:t,strategy:o,middleware:p};W.current&&(P.platform=W.current),Bn(x.current,R.current,P).then(A=>{let M={...A,isPositioned:O.current!==!1};I.current&&!zn(E.current,M)&&(E.current=M,Hc.flushSync(()=>{f(M)}))})},[p,t,o,W,O]);Hn(()=>{c===!1&&E.current.isPositioned&&(E.current.isPositioned=!1,f(P=>({...P,isPositioned:!1})))},[c]);let I=ve.useRef(!1);Hn(()=>(I.current=!0,()=>{I.current=!1}),[]),Hn(()=>{if(h&&(x.current=h),T&&(R.current=T),h&&T){if(C.current)return C.current(h,T,L);L()}},[h,T,L,C,k]);let S=ve.useMemo(()=>({reference:x,floating:R,setReference:w,setFloating:y}),[w,y]),N=ve.useMemo(()=>({reference:h,floating:T}),[h,T]),H=ve.useMemo(()=>{let P={position:o,left:0,top:0};if(!N.floating)return P;let A=Mc(N.floating,d.x),M=Mc(N.floating,d.y);return a?{...P,transform:"translate("+A+"px, "+M+"px)",...zc(N.floating)>=1.5&&{willChange:"transform"}}:{position:o,left:A,top:M}},[o,a,N.floating,d.x,d.y]);return ve.useMemo(()=>({...d,update:L,refs:S,elements:N,floatingStyles:H}),[d,L,S,N,H])}var oi=(e,t)=>{let o=Cc(e);return{name:o.name,fn:o.fn,options:[e,t]}},ni=(e,t)=>{let o=Ac(e);return{name:o.name,fn:o.fn,options:[e,t]}},ri=(e,t)=>({fn:Ic(e).fn,options:[e,t]}),ii=(e,t)=>{let o=Oc(e);return{name:o.name,fn:o.fn,options:[e,t]}},si=(e,t)=>{let o=Nc(e);return{name:o.name,fn:o.fn,options:[e,t]}};var ai=(e,t)=>{let o=Lc(e);return{name:o.name,fn:o.fn,options:[e,t]}};var vo=b(z(),1),tl=b(Mt(),1);var $c=b(z(),1);var Z=(e,t,o,n,r,i,...s)=>{if(s.length>0)throw new Error(ke(1));let a;if(e&&t&&o&&n&&r&&i)a=(l,c,d,f)=>{let p=e(l,c,d,f),m=t(l,c,d,f),u=o(l,c,d,f),g=n(l,c,d,f),v=r(l,c,d,f);return i(p,m,u,g,v,c,d,f)};else if(e&&t&&o&&n&&r)a=(l,c,d,f)=>{let p=e(l,c,d,f),m=t(l,c,d,f),u=o(l,c,d,f),g=n(l,c,d,f);return r(p,m,u,g,c,d,f)};else if(e&&t&&o&&n)a=(l,c,d,f)=>{let p=e(l,c,d,f),m=t(l,c,d,f),u=o(l,c,d,f);return n(p,m,u,c,d,f)};else if(e&&t&&o)a=(l,c,d,f)=>{let p=e(l,c,d,f),m=t(l,c,d,f);return o(p,m,c,d,f)};else if(e&&t)a=(l,c,d,f)=>{let p=e(l,c,d,f);return t(p,c,d,f)};else if(e)a=e;else throw new Error("Missing arguments");return a};var Qc=b(z(),1),pi=b(li(),1),Jc=b(Gc(),1);var Xc=b(z(),1);var di=[],ui;function Kc(){return ui}function qc(e){di.push(e)}function fi(e){let t=(o,n)=>{let r=Se(ig).current,i;try{ui=r;for(let s of di)s.before(r);i=e(o,n);for(let s of di)s.after(r);r.didInitialize=!0}finally{ui=void 0}return i};return t.displayName=e.displayName||e.name,t}function Zc(e){return Xc.forwardRef(fi(e))}function ig(){return{didInitialize:!1}}var sg=ao(19),ag=sg?lg:dg;function jn(e,t,o,n,r){return ag(e,t,o,n,r)}function cg(e,t,o,n,r){let i=Qc.useCallback(()=>t(e.getSnapshot(),o,n,r),[e,t,o,n,r]);return(0,pi.useSyncExternalStore)(e.subscribe,i,i)}qc({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let o=0;o0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let o=new Set;for(let r of e.syncHooks)o.add(r.store);let n=[];for(let r of o)n.push(r.subscribe(t));return()=>{for(let r of n)r()}}),(0,pi.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function lg(e,t,o,n,r){let i=Kc();if(!i)return cg(e,t,o,n,r);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,o)||!Object.is(a.a2,n)||!Object.is(a.a3,r))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=o,a.a2=n,a.a3=r,a.value=t(e.getSnapshot(),o,n,r))):(a={store:e,selector:t,a1:o,a2:n,a3:r,value:t(e.getSnapshot(),o,n,r)},i.syncHooks.push(a)),a.value}function dg(e,t,o,n,r){return(0,Jc.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,o,n,r))}var Fn=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let o=this.updateTick;for(let n of this.listeners){if(o!==this.updateTick)return;n(t)}}update(t){for(let o in t)if(!Object.is(this.state[o],t[o])){this.setState({...this.state,...t});return}}set(t,o){Object.is(this.state[t],o)||this.setState({...this.state,[t]:o})}notifyAll(){let t={...this.state};this.setState(t)}use(t,o,n,r){return jn(this,t,o,n,r)}};var Jt=b(z(),1);var wo=class extends Fn{constructor(t,o={},n){super(t),this.context=o,this.selectors=n}useSyncedValue(t,o){Jt.useDebugValue(t);let n=this;D(()=>{n.state[t]!==o&&n.set(t,o)},[n,t,o])}useSyncedValueWithCleanup(t,o){let n=this;D(()=>(n.state[t]!==o&&n.set(t,o),()=>{n.set(t,void 0)}),[n,t,o])}useSyncedValues(t){let o=this,n=Object.values(t);D(()=>{o.update(t)},[o,...n])}useControlledProp(t,o){Jt.useDebugValue(t);let n=this,r=o!==void 0;D(()=>{r&&!Object.is(n.state[t],o)&&n.setState({...n.state,[t]:o})},[n,t,o,r])}select(t,o,n,r){let i=this.selectors[t];return i(this.state,o,n,r)}useState(t,o,n,r){return Jt.useDebugValue(t),jn(this,this.selectors[t],o,n,r)}useContextCallback(t,o){Jt.useDebugValue(t);let n=Y(o??Nt);this.context[t]=n}useStateSetter(t){let o=Jt.useRef(void 0);return o.current===void 0&&(o.current=n=>{this.set(t,n)}),o.current}observe(t,o){let n;typeof t=="function"?n=t:n=this.selectors[t];let r=n(this.state);return o(r,r,this),this.subscribe(i=>{let s=n(i);if(!Object.is(r,s)){let a=r;r=s,o(s,a,this)}})}};var ug={open:Z(e=>e.open),transitionStatus:Z(e=>e.transitionStatus),domReferenceElement:Z(e=>e.domReferenceElement),referenceElement:Z(e=>e.positionReference??e.referenceElement),floatingElement:Z(e=>e.floatingElement),floatingId:Z(e=>e.floatingId)},gt=class extends wo{constructor(t){let{syncOnly:o,nested:n,onOpenChange:r,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:r,dataRef:{current:{}},events:cc(),nested:n,triggerElements:i},ug),this.syncOnly=o}syncOpenEvent=(t,o)=>{(!t||!this.state.open||o!=null&&Ua(o))&&(this.context.dataRef.current.openEvent=t?o:void 0)};dispatchOpenChange=(t,o)=>{this.syncOpenEvent(t,o.event);let n={open:t,reason:o.reason,nativeEvent:o.event,nested:this.context.nested,triggerElement:o.trigger};this.context.events.emit("openchange",n)};setOpen=(t,o)=>{if(this.syncOnly){this.context.onOpenChange?.(t,o);return}this.dispatchOpenChange(t,o),this.context.onOpenChange?.(t,o)}};function el(e){let{popupStore:t,treatPopupAsFloatingElement:o=!1,floatingRootContext:n,floatingId:r,nested:i,onOpenChange:s}=e,a=t.useState("open"),l=t.useState("activeTriggerElement"),c=t.useState(o?"popupElement":"positionerElement"),d=t.context.triggerElements,f=s,p=$c.useRef(null);n===void 0&&p.current===null&&(p.current=new gt({open:a,transitionStatus:void 0,referenceElement:l,floatingElement:c,triggerElements:d,onOpenChange:f,floatingId:r,syncOnly:!0,nested:i}));let m=n??p.current;return t.useSyncedValue("floatingId",r),D(()=>{let u={open:a,floatingId:r,referenceElement:l,floatingElement:c};F(l)&&(u.domReferenceElement=l),m.state.positionReference===m.state.referenceElement&&(u.positionReference=l),m.update(u)},[a,r,l,c,m]),m.context.onOpenChange=f,m.context.nested=i,m}var ol={tabIndex:-1,[Wr]:""};function nl(e,t,o=!1){let n=Lt(),r=go()!=null,i=vo.useRef(null);e===void 0&&i.current===null&&(i.current=t(n,r));let s=e??i.current;return el({popupStore:s,treatPopupAsFloatingElement:o,floatingRootContext:s.state.floatingRootContext,floatingId:n,nested:r,onOpenChange:s.setOpen}),{store:s,internalStore:i.current}}function fg(e,t){let o=vo.useRef(null),n=vo.useRef(null);return vo.useCallback(r=>{if(e===void 0)return;let i=!1;if(o.current!==null){let s=o.current,a=n.current,l=t.context.triggerElements.getById(s);a&&l===a&&(t.context.triggerElements.delete(s),i=!0),o.current=null,n.current=null}if(r!==null&&(o.current=e,n.current=r,t.context.triggerElements.add(e,r),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function pg(e,t,o,n=!1){t?e.preventUnmountingOnClose=!1:n&&(e.preventUnmountingOnClose=!0);let r=o?.id??null;(r||t)&&(e.activeTriggerId=r,e.activeTriggerElement=o??null)}function mg(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function rl(e,t,o,n={}){let r=o.reason,i=r===U.triggerHover,s=t&&r===U.triggerFocus,a=!t&&(r===U.triggerPress||r===U.escapeKey),l=mg(o);if(e.context.onOpenChange?.(t,o),o.isCanceled)return;n.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,o);let c=()=>{let d={...n.extraState,open:t};s?d.instantType="focus":a?d.instantType="dismiss":i&&(d.instantType=void 0),pg(d,t,o.trigger,l()),e.update(d)};i?tl.flushSync(c):c()}function il(e,t,o,n){Da(()=>{t===void 0&&e.state.open===!1&&o&&(e.state={...e.state,open:!0,activeTriggerId:n,preventUnmountingOnClose:!1})})}function sl(e,t,o,n){let r=o.useState("isMountedByTrigger",e),i=fg(e,o),s=Y(a=>{if(i(a),!a)return;let l=o.select("open"),c=o.select("activeTriggerId");if(c===e){o.update({activeTriggerElement:a,...l?n:null});return}c==null&&l&&o.update({activeTriggerId:e,activeTriggerElement:a,...n})});return D(()=>{r&&o.update({activeTriggerElement:t.current,...n})},[r,o,t,...Object.values(n)]),{registerTrigger:s,isMountedByThisTrigger:r}}function al(e,t={}){let{closeOnActiveTriggerUnmount:o=!1}=t,n=e.useState("open"),r=e.useState("triggerCount");D(()=>{if(!n){e.state.triggerCount!==0&&e.set("triggerCount",0);return}let i=e.context.triggerElements.size,s={};e.state.triggerCount!==i&&(s.triggerCount=i);let a=e.select("activeTriggerId"),l=null;if(a){let c=e.context.triggerElements.getById(a);c?c!==e.state.activeTriggerElement&&(s.activeTriggerElement=c):l=a}if(!l&&!a&&i===1){let c=e.context.triggerElements.entries().next();if(!c.done){let[d,f]=c.value;s.activeTriggerId=d,s.activeTriggerElement=f}}(s.triggerCount!==void 0||s.activeTriggerId!==void 0||s.activeTriggerElement!==void 0)&&e.update(s),l&&o&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===l&&!e.context.triggerElements.getById(l)){let c=ee(U.none);e.setOpen(!1,c),c.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[n,e,r,o])}function cl(e,t,o){let{mounted:n,setMounted:r,transitionStatus:i}=Ea(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:n,transitionStatus:i,preventUnmountingOnClose:a});let l=Y(()=>{r(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),o?.(),t.context.onOpenChangeComplete?.(!1)});return kn({enabled:n&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||l()}}),{forceUnmount:l,transitionStatus:i}}function ll(e,t){e.useSyncedValues(t),D(()=>()=>{e.update({activeTriggerProps:be,inactiveTriggerProps:be,popupProps:be})},[e])}var jt=class{constructor(){this.elementsSet=new Set,this.idMap=new Map}add(t,o){let n=this.idMap.get(t);n!==o&&(n!==void 0&&this.elementsSet.delete(n),this.elementsSet.add(o),this.idMap.set(t,o))}delete(t){let o=this.idMap.get(t);o&&(this.elementsSet.delete(o),this.idMap.delete(t))}hasElement(t){return this.elementsSet.has(t)}hasMatchingElement(t){for(let o of this.elementsSet)if(t(o))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.elementsSet.values()}get size(){return this.idMap.size}};function dl(){return new gt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new jt,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function fl(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:dl(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:be,inactiveTriggerProps:be,popupProps:be}}function pl(e,t,o=!1){return new gt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:o,onOpenChange:void 0})}var Xo=Z(e=>e.triggerIdProp??e.activeTriggerId),mi=Z(e=>e.openProp??e.open),ul=Z(e=>(e.popupElement?.id??e.floatingId)||void 0);function ml(e,t){return t!==void 0&&mi(e)&&Xo(e)===t}function gg(e,t){return ml(e,t)?!0:t!==void 0&&mi(e)&&Xo(e)==null&&e.triggerCount===1}var gl={open:mi,mounted:Z(e=>e.mounted),transitionStatus:Z(e=>e.transitionStatus),floatingRootContext:Z(e=>e.floatingRootContext),triggerCount:Z(e=>e.triggerCount),preventUnmountingOnClose:Z(e=>e.preventUnmountingOnClose),payload:Z(e=>e.payload),activeTriggerId:Xo,activeTriggerElement:Z(e=>e.mounted?e.activeTriggerElement:null),popupId:ul,isTriggerActive:Z((e,t)=>t!==void 0&&Xo(e)===t),isOpenedByTrigger:Z((e,t)=>ml(e,t)),isMountedByTrigger:Z((e,t)=>t!==void 0&&Xo(e)===t&&e.mounted),triggerProps:Z((e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps),triggerPopupId:Z((e,t)=>gg(e,t)?ul(e):void 0),popupProps:Z(e=>e.popupProps),popupElement:Z(e=>e.popupElement),positionerElement:Z(e=>e.positionerElement)};function bl(e){let{open:t=!1,onOpenChange:o,elements:n={}}=e,r=Lt(),i=go()!=null,s=Se(()=>new gt({open:t,transitionStatus:void 0,onOpenChange:o,referenceElement:n.reference??null,floatingElement:n.floating??null,triggerElements:new jt,floatingId:r,syncOnly:!1,nested:i})).current;return D(()=>{let a={open:t,floatingId:r};n.reference!==void 0&&(a.referenceElement=n.reference,a.domReferenceElement=F(n.reference)?n.reference:null),n.floating!==void 0&&(a.floatingElement=n.floating),s.update(a)},[t,r,n.reference,n.floating,s]),s.context.onOpenChange=o,s.context.nested=i,s}function gi(e={}){let{nodeId:t,externalTree:o}=e,n=bl(e),r=e.rootContext||n,i=r.useState("referenceElement"),s=r.useState("floatingElement"),a=r.useState("domReferenceElement"),l=r.useState("open"),c=r.useState("floatingId"),[d,f]=Oe.useState(null),[p,m]=Oe.useState(void 0),[u,g]=Oe.useState(void 0),v=Oe.useRef(null),_=Dt(o),w=Oe.useMemo(()=>({reference:i,floating:s,domReference:a}),[i,s,a]),y=Dc({...e,elements:{...w,...d&&{reference:d}}}),h=F(p)?p:null,T=u===void 0?r.state.floatingElement:u;r.useSyncedValue("referenceElement",p??null),r.useSyncedValue("domReferenceElement",p===void 0?a:h),r.useSyncedValue("floatingElement",T);let x=Oe.useCallback(O=>{let L=F(O)?{getBoundingClientRect:()=>O.getBoundingClientRect(),getClientRects:()=>O.getClientRects(),contextElement:O}:O;f(L),y.refs.setReference(L)},[y.refs]),R=Oe.useCallback(O=>{(F(O)||O===null)&&(v.current=O,m(O)),(F(y.refs.reference.current)||y.refs.reference.current===null||O!==null&&!F(O))&&y.refs.setReference(O)},[y.refs,m]),E=Oe.useCallback(O=>{g(O),y.refs.setFloating(O)},[y.refs]),k=Oe.useMemo(()=>({...y.refs,setReference:R,setFloating:E,setPositionReference:x,domReference:v}),[y.refs,R,E,x]),C=Oe.useMemo(()=>({...y.elements,domReference:a}),[y.elements,a]),W=Oe.useMemo(()=>({...y,dataRef:r.context.dataRef,open:l,onOpenChange:r.setOpen,events:r.context.events,floatingId:c,refs:k,elements:C,nodeId:t,rootStore:r}),[y,k,C,t,r,l,c]);return D(()=>{a&&(v.current=a)},[a]),D(()=>{r.context.dataRef.current.floatingContext=W;let O=_?.nodesRef.current.find(L=>L.id===t);O&&(O.context=W)}),Oe.useMemo(()=>({...y,context:W,refs:k,elements:C,rootStore:r}),[y,k,C,W,r])}var bt=b(z(),1);var bi=Rt.os.mac&&Rt.engine.webkit;function hi(e,t={}){let{enabled:o=!0,delay:n}=t,r="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=r.context,a=bt.useRef(!1),l=bt.useRef(null),c=bt.useRef(!0),d=ot();bt.useEffect(()=>{let p=r.select("domReferenceElement");if(!o)return;let m=me(p);function u(){let _=r.select("domReferenceElement");!r.select("open")&&ye(_)&&_===Pn(xe(_))&&(a.current=!0)}function g(){c.current=!0}function v(){c.current=!1}return nt(re(m,"blur",u),bi&&re(m,"keydown",g,!0),bi&&re(m,"pointerdown",v,!0))},[r,o]),bt.useEffect(()=>{if(!o)return;function p(m){if(m.reason===U.triggerPress||m.reason===U.escapeKey){let u=r.select("domReferenceElement");F(u)&&(l.current=u,a.current=!0)}}return i.on("openchange",p),()=>{i.off("openchange",p)}},[i,o,r]);let f=bt.useMemo(()=>{function p(){a.current=!1,l.current=null}return{onMouseLeave(){p()},onFocus(m){let u=m.currentTarget;if(a.current){if(l.current===u)return;p()}let g=Me(m.nativeEvent);if(F(g)){if(bi&&!m.relatedTarget){if(!c.current&&!Xa(g))return}else if(!Ka(g))return}let v=Bt(m.relatedTarget,r.context.triggerElements),{nativeEvent:_,currentTarget:w}=m,y=typeof n=="function"?n():n;if(r.select("open")&&v||y===0||y===void 0){r.setOpen(!0,ee(U.triggerFocus,_,w));return}d.start(y,()=>{a.current||r.setOpen(!0,ee(U.triggerFocus,_,w))})},onBlur(m){p();let u=m.relatedTarget,g=m.nativeEvent,v=F(u)&&u.hasAttribute(mo("focus-guard"))&&u.getAttribute("data-type")==="outside";d.start(0,()=>{let _=r.select("domReferenceElement"),w=Pn(xe(_));!u&&w===_||ie(s.current.floatingContext?.refs.floating.current,w)||ie(_,w)||v||Bt(u??w,r.context.triggerElements)||r.setOpen(!1,ee(U.triggerFocus,g))})}}},[s,n,r,d]);return bt.useMemo(()=>o?{reference:f,trigger:f}:{},[o,f])}var vi=b(z(),1);var wi=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new We,this.restTimeout=new We,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},Vn=new WeakMap;function _o(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&Vn.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),Vn.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function Wn(e,t){let{scopeElement:o,referenceElement:n,floatingElement:r}=t,i=Vn.get(o);i&&i!==e&&_o(i),_o(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=o,e.pointerEventsReferenceElement=n,e.pointerEventsFloatingElement=r,Vn.set(o,e),o.style.pointerEvents="none",n.style.pointerEvents="auto",r.style.pointerEvents="auto"}function yo(e){let t=e.context.dataRef.current,o=Se(()=>t.hoverInteractionState??wi.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=o),co(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function _i(e,t={}){let{enabled:o=!0,closeDelay:n=0,nodeId:r}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),l=i.useState("domReferenceElement"),{dataRef:c}=i.context,d=Dt(),f=go(),p=yo(i),m=ot(),u=Y(()=>An(c.current.openEvent?.type,p.interactedInside)),g=Y(()=>qa(c.current.openEvent?.type)),v=Y(()=>{_o(p)});D(()=>{s||(p.pointerType=void 0,p.restTimeoutPending=!1,p.interactedInside=!1,v())},[s,p,v]),vi.useEffect(()=>v,[v]),D(()=>{if(o&&s&&p.handleCloseOptions?.blockPointerEvents&&g()&&F(l)&&a){let _=l,w=a,y=xe(a),h=d?.nodesRef.current.find(E=>E.id===f)?.context?.elements.floating;h&&(h.style.pointerEvents="");let T=p.pointerEventsScopeElement!==w?p.pointerEventsScopeElement:null,x=h!==w?h:null,R=p.handleCloseOptions?.getScope?.()??T??x??_.closest("[data-rootownerid]")??y.body;return Wn(p,{scopeElement:R,referenceElement:_,floatingElement:w}),()=>{v()}}},[o,s,l,a,p,g,d,f,v]),vi.useEffect(()=>{if(!o)return;function _(){return!!(d&&f&&Tt(d.nodesRef.current,f).length>0)}function w(E){let k=Et(n,"close",p.pointerType),C=()=>{i.setOpen(!1,ee(U.triggerHover,E)),d?.events.emit("floating.closed",E)};k?p.openChangeTimeout.start(k,C):(p.openChangeTimeout.clear(),C())}function y(E){let k=Me(E);if(!Ur(k)){p.interactedInside=!1;return}p.interactedInside=k?.closest("[aria-haspopup]")!=null}function h(){p.openChangeTimeout.clear(),m.clear(),d?.events.off("floating.closed",x),v()}function T(E){if(_()&&d){d.events.on("floating.closed",x);return}if(Bt(E.relatedTarget,i.context.triggerElements))return;let k=c.current.floatingContext?.nodeId??r,C=E.relatedTarget;if(!(d&&k&&F(C)&&Tt(d.nodesRef.current,k,!1).some(O=>ie(O.context?.elements.floating,C)))){if(p.handler){p.handler(E);return}v(),g()&&!u()&&w(E)}}function x(E){!d||!f||_()||m.start(0,()=>{d.events.off("floating.closed",x),i.setOpen(!1,ee(U.triggerHover,E)),d.events.emit("floating.closed",E)})}let R=a;return nt(R&&re(R,"mouseenter",h),R&&re(R,"mouseleave",T),R&&re(R,"pointerdown",y,!0),()=>{d?.events.off("floating.closed",x)})},[o,a,i,c,n,r,g,u,v,p,d,f,m])}var Ft=b(z(),1),hl=b(Mt(),1);var bg={current:null};function yi(e,t={}){let{enabled:o=!0,delay:n=0,handleClose:r=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:l=bg,externalTree:c,isActiveTrigger:d=!0,getHandleCloseContext:f,isClosing:p,shouldOpen:m}=t,u="rootStore"in e?e.rootStore:e,{dataRef:g,events:v}=u.context,_=Dt(c),w=yo(u),y=Ft.useRef(!1),h=He(r),T=He(n),x=He(s),R=He(o),E=He(m),k=He(p),C=Y(()=>An(g.current.openEvent?.type,w.interactedInside)),W=Y(()=>E.current?.()!==!1),O=Y((S,N,H)=>{let P=u.context.triggerElements;if(P.hasElement(N))return!S||!ie(S,N);if(!F(H))return!1;let A=H;return P.hasMatchingElement(M=>ie(M,A))&&(!S||!ie(S,A))}),L=Y(()=>{if(!w.handler)return;xe(u.select("domReferenceElement")).removeEventListener("mousemove",w.handler),w.handler=void 0}),I=Y(()=>{_o(w)});return d&&(w.handleCloseOptions=h.current?.__options),Ft.useEffect(()=>L,[L]),Ft.useEffect(()=>{if(!o)return;function S(N){N.open?y.current=!1:(y.current=N.reason===U.triggerHover,L(),w.openChangeTimeout.clear(),w.restTimeout.clear(),w.blockMouseMove=!0,w.restTimeoutPending=!1)}return v.on("openchange",S),()=>{v.off("openchange",S)}},[o,v,w,L]),Ft.useEffect(()=>{if(!o)return;function S(A,M=!0){let Q=Et(T.current,"close",w.pointerType);Q?w.openChangeTimeout.start(Q,()=>{u.setOpen(!1,ee(U.triggerHover,A)),_?.events.emit("floating.closed",A)}):M&&(w.openChangeTimeout.clear(),u.setOpen(!1,ee(U.triggerHover,A)),_?.events.emit("floating.closed",A))}let N=l.current??(d?u.select("domReferenceElement"):null);if(!F(N))return;function H(A){if(w.openChangeTimeout.clear(),w.blockMouseMove=!1,i&&!St(w.pointerType))return;let M=Gr(x.current),Q=Et(T.current,"open",w.pointerType),V=Me(A),oe=A.currentTarget??null,te=u.select("domReferenceElement"),se=oe;if(F(V)&&!u.context.triggerElements.hasElement(V)){for(let ue of u.context.triggerElements.elements())if(ie(ue,V)){se=ue;break}}F(oe)&&F(te)&&!u.context.triggerElements.hasElement(oe)&&ie(oe,te)&&(se=te);let G=se==null?!1:O(te,se,V),q=u.select("open"),J=k.current?.()??u.select("transitionStatus")==="ending",ne=!q&&J&&y.current,ge=!G&&F(se)&&F(te)&&ie(te,se)&&ne,de=M>0&&!Q,X=G&&(q||ne)||ge,pe=!q||G;if(X){W()&&u.setOpen(!0,ee(U.triggerHover,A,se));return}de||(Q?w.openChangeTimeout.start(Q,()=>{pe&&W()&&u.setOpen(!0,ee(U.triggerHover,A,se))}):pe&&W()&&u.setOpen(!0,ee(U.triggerHover,A,se)))}function P(A){if(C()){I();return}L();let M=u.select("domReferenceElement"),Q=xe(M);w.restTimeout.clear(),w.restTimeoutPending=!1;let V=g.current.floatingContext??f?.();if(Bt(A.relatedTarget,u.context.triggerElements))return;if(h.current&&V){u.select("open")||w.openChangeTimeout.clear();let te=l.current;w.handler=h.current({...V,tree:_,x:A.clientX,y:A.clientY,onClose(){I(),L(),R.current&&!C()&&te===u.select("domReferenceElement")&&S(A,!0)}}),Q.addEventListener("mousemove",w.handler),w.handler(A);return}(w.pointerType!=="touch"||!ie(u.select("floatingElement"),A.relatedTarget))&&S(A)}return a?nt(re(N,"mousemove",H,{once:!0}),re(N,"mouseenter",H),re(N,"mouseleave",P)):nt(re(N,"mouseenter",H),re(N,"mouseleave",P))},[L,I,g,T,u,o,h,w,d,O,C,i,a,x,l,_,R,f,k,W]),Ft.useMemo(()=>{if(!o)return;function S(N){w.pointerType=N.pointerType}return{onPointerDown:S,onPointerEnter:S,onMouseMove(N){let{nativeEvent:H}=N,P=N.currentTarget,A=u.select("domReferenceElement"),M=u.select("open"),Q=O(A,P,N.target);if(i&&!St(w.pointerType))return;if(M&&Q&&w.handleCloseOptions?.blockPointerEvents){let te=u.select("floatingElement");if(te){let se=w.handleCloseOptions?.getScope?.()??P.ownerDocument.body;Wn(w,{scopeElement:se,referenceElement:P,floatingElement:te})}}let V=Gr(x.current);if(M&&!Q||V===0||!Q&&w.restTimeoutPending&&N.movementX**2+N.movementY**2<2)return;w.restTimeout.clear();function oe(){if(w.restTimeoutPending=!1,C())return;let te=u.select("open");!w.blockMouseMove&&(!te||Q)&&W()&&u.setOpen(!0,ee(U.triggerHover,H,P))}w.pointerType==="touch"?hl.flushSync(()=>{oe()}):Q&&M?oe():(w.restTimeoutPending=!0,w.restTimeout.start(V,oe))}}},[o,w,C,O,i,u,x,W])}var wl=.1,hg=wl*wl,le=.5;function Yn(e,t,o,n,r,i){return n>=t!=i>=t&&e<=(r-o)*(t-n)/(i-n)+o}function Un(e,t,o,n,r,i,s,a,l,c){let d=!1;return Yn(e,t,o,n,r,i)&&(d=!d),Yn(e,t,r,i,s,a)&&(d=!d),Yn(e,t,s,a,l,c)&&(d=!d),Yn(e,t,l,c,o,n)&&(d=!d),d}function wg(e,t,o){return e>=o.x&&e<=o.x+o.width&&t>=o.y&&t<=o.y+o.height}function Gn(e,t,o,n,r,i){let s=Math.min(o,r),a=Math.max(o,r),l=Math.min(n,i),c=Math.max(n,i);return e>=s&&e<=a&&t>=l&&t<=c}function xi(e={}){let{blockPointerEvents:t=!1}=e,o=new We,n=({x:r,y:i,placement:s,elements:a,onClose:l,nodeId:c,tree:d})=>{let f=s?.split("-")[0],p=!1,m=null,u=null,g=typeof performance<"u"?performance.now():0;function v(w,y){let h=performance.now(),T=h-g;if(m===null||u===null||T===0)return m=w,u=y,g=h,!1;let x=w-m,R=y-u,E=x*x+R*R,k=T*T*hg;return m=w,u=y,g=h,E0)}function L(){O()||_()}if(O())return;let I=h.getBoundingClientRect(),S=T.getBoundingClientRect(),N=r>S.right-S.width/2,H=i>S.bottom-S.height/2,P=S.width>I.width,A=S.height>I.height,M=(P?I:S).left,Q=(P?I:S).right,V=(A?I:S).top,oe=(A?I:S).bottom;if(f==="top"&&i>=I.bottom-1||f==="bottom"&&i<=I.top+1||f==="left"&&r>=I.right-1||f==="right"&&r<=I.left+1){L();return}let te=!1;switch(f){case"top":te=Gn(x,R,M,I.top+1,Q,S.bottom-1);break;case"bottom":te=Gn(x,R,M,S.top+1,Q,I.bottom-1);break;case"left":te=Gn(x,R,S.right-1,oe,I.left+1,V);break;case"right":te=Gn(x,R,I.right-1,oe,S.left+1,V);break;default:}if(te)return;if(p&&!wg(x,R,I)){L();return}if(!k&&v(x,R)){L();return}let se=!1;switch(f){case"top":{let G=P?le/2:le*4,q=P||N?r+G:r-G,J=P?r-G:N?r+G:r-G,ne=i+le+1,ge=N||P?S.bottom-le:S.top,de=N?P?S.bottom-le:S.top:S.bottom-le;se=Un(x,R,q,ne,J,ne,S.left,ge,S.right,de);break}case"bottom":{let G=P?le/2:le*4,q=P||N?r+G:r-G,J=P?r-G:N?r+G:r-G,ne=i-le,ge=N||P?S.top+le:S.bottom,de=N?P?S.top+le:S.bottom:S.top+le;se=Un(x,R,q,ne,J,ne,S.left,ge,S.right,de);break}case"left":{let G=A?le/2:le*4,q=A||H?i+G:i-G,J=A?i-G:H?i+G:i-G,ne=r+le+1,ge=H||A?S.right-le:S.left,de=H?A?S.right-le:S.left:S.right-le;se=Un(x,R,ge,S.top,de,S.bottom,ne,q,ne,J);break}case"right":{let G=A?le/2:le*4,q=A||H?i+G:i-G,J=A?i-G:H?i+G:i-G,ne=r-le,ge=H||A?S.left+le:S.right,de=H?A?S.left+le:S.right:S.left+le;se=Un(x,R,ne,q,ne,J,ge,S.top,de,S.bottom);break}default:}se?p||o.start(40,L):L()}};return n.__options={...e,blockPointerEvents:t},n}var Ri=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=Yt.startingStyle]="startingStyle",e[e.endingStyle=Yt.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({}),Ko=(function(e){return e.popupOpen="data-popup-open",e.pressed="data-pressed",e})({}),vg={[Ko.popupOpen]:""},oy={[Ko.popupOpen]:"",[Ko.pressed]:""},_g={[Ri.open]:""},yg={[Ri.closed]:""},xg={[Ri.anchorHidden]:""},vl={open(e){return e?vg:null}};var xo={open(e){return e?_g:yg},anchorHidden(e){return e?xg:null}};function _l(e){return ao(19)?e:e?"true":void 0}var Ue=b(z(),1);var Rg=e=>({name:"arrow",options:e,async fn(t){let{x:o,y:n,placement:r,rects:i,platform:s,elements:a,middlewareData:l}=t,{element:c,padding:d=0,offsetParent:f="real"}=it(e,t)||{};if(c==null)return{};let p=In(d),m={x:o,y:n},u=Uo(r),g=Yo(u),v=await s.getDimensions(c),_=u==="y",w=_?"top":"left",y=_?"bottom":"right",h=_?"clientHeight":"clientWidth",T=i.reference[g]+i.reference[u]-m[u]-i.floating[g],x=m[u]-i.reference[u],R=f==="real"?await s.getOffsetParent?.(c):a.floating,E=a.floating[h]||i.floating[g];(!E||!await s.isElement?.(R))&&(E=a.floating[h]||i.floating[g]);let k=T/2-x/2,C=E/2-v[g]/2-1,W=Math.min(p[w],C),O=Math.min(p[y],C),L=W,I=E-v[g]-O,S=E/2-v[g]/2+k,N=Nn(L,S,I),H=!l.arrow&&st(r)!=null&&S!==N&&i.reference[g]/2-(S({...Rg(e),options:[e,t]});var Sg=ai().fn,xl={name:"hide",async fn(e){let{width:t,height:o,x:n,y:r}=e.rects.reference,i=t===0&&o===0&&n===0&&r===0;return{data:{referenceHidden:(await Sg(e)).data?.referenceHidden||i}}}};var qo={sideX:"left",sideY:"top"},Rl={name:"adaptiveOrigin",async fn(e){let{x:t,y:o,rects:{floating:n},elements:{floating:r},platform:i,strategy:s,placement:a}=e,l=me(r),c=l.getComputedStyle(r);if(!(c.transitionDuration!=="0s"&&c.transitionDuration!==""))return{x:t,y:o,data:qo};let f=await i.getOffsetParent?.(r),p={width:0,height:0};if(s==="fixed"&&l?.visualViewport)p={width:l.visualViewport.width,height:l.visualViewport.height};else if(f===l){let w=xe(r);p={width:w.documentElement.clientWidth,height:w.documentElement.clientHeight}}else await i.isElement?.(f)&&(p=await i.getDimensions(f));let m=Ae(a),u=t,g=o;m==="left"&&(u=p.width-(t+n.width)),m==="top"&&(g=p.height-(o+n.height));let v=m==="left"?"right":qo.sideX,_=m==="top"?"bottom":qo.sideY;return{x:u,y:g,data:{sideX:v,sideY:_}}}};function Tl(e,t,o){let n=e==="inline-start"||e==="inline-end";return{top:"top",right:n?o?"inline-start":"inline-end":"right",bottom:"bottom",left:n?o?"inline-end":"inline-start":"left"}[t]}function Sl(e,t,o){let{rects:n,placement:r}=e;return{side:Tl(t,Ae(r),o),align:st(r)||"center",anchor:{width:n.reference.width,height:n.reference.height},positioner:{width:n.floating.width,height:n.floating.height}}}function kl(e){let{anchor:t,positionMethod:o="absolute",side:n="bottom",sideOffset:r=0,align:i="center",alignOffset:s=0,collisionBoundary:a,collisionPadding:l=5,sticky:c=!1,arrowPadding:d=5,disableAnchorTracking:f=!1,inline:p,keepMounted:m=!1,floatingRootContext:u,mounted:g,collisionAvoidance:v,shiftCrossAxis:_=!1,nodeId:w,adaptiveOrigin:y,lazyFlip:h=!1,externalTree:T}=e,[x,R]=Ue.useState(null);!g&&x!==null&&R(null);let E=v.side||"flip",k=v.align||"flip",C=v.fallbackAxisSide||"end",W=typeof t=="function"?t:void 0,O=Y(W),L=W?O:t,I=He(t),S=He(g),H=so()==="rtl",P=x||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":H?"left":"right","inline-start":H?"right":"left"}[n],A=i==="center"?P:`${P}-${i}`,M=l,Q=1,V=n==="bottom"?Q:0,oe=n==="top"?Q:0,te=n==="right"?Q:0,se=n==="left"?Q:0;typeof M=="number"?M={top:M+V,right:M+se,bottom:M+oe,left:M+te}:M&&(M={top:(M.top||0)+V,right:(M.right||0)+se,bottom:(M.bottom||0)+oe,left:(M.left||0)+te});let G={boundary:a==="clipping-ancestors"?"clippingAncestors":a,padding:M},q=Ue.useRef(null),J=He(r),ne=He(s),ge=typeof r!="function"?r:0,de=typeof s!="function"?s:0,X=[];p&&X.push(p),X.push(oi(ae=>{let Le=Sl(ae,n,H),ct=typeof J.current=="function"?J.current(Le):J.current,Ke=typeof ne.current=="function"?ne.current(Le):ne.current;return{mainAxis:ct,crossAxis:Ke,alignmentAxis:Ke}},[ge,de,H,n]));let pe=k==="none"&&E!=="shift",ue=!pe&&(c||_||E==="shift"),_t=E==="none"?null:ii({...G,padding:{top:M.top+Q,right:M.right+Q,bottom:M.bottom+Q,left:M.left+Q},mainAxis:!_&&E==="flip",crossAxis:k==="flip"?"alignment":!1,fallbackAxisSideDirection:C}),Ee=pe?null:ni(ae=>{let Le=xe(ae.elements.floating).documentElement;return{...G,rootBoundary:_?{x:0,y:0,width:Le.clientWidth,height:Le.clientHeight}:void 0,mainAxis:k!=="none",crossAxis:ue,limiter:c||_?void 0:ri(ct=>{if(!q.current)return{};let{width:Ke,height:xt}=q.current.getBoundingClientRect(),tt=ze(Ae(ct.placement)),Vt=tt==="y"?Ke:xt,io=tt==="y"?M.left+M.right:M.top+M.bottom;return{offset:Vt/2+io/2}})}},[G,c,_,M,k]);E==="shift"||k==="shift"||i==="center"?X.push(Ee,_t):X.push(_t,Ee),X.push(si({...G,apply({elements:{floating:ae},availableWidth:Le,availableHeight:ct,rects:Ke}){if(!S.current)return;let xt=ae.style;xt.setProperty("--available-width",`${Le}px`),xt.setProperty("--available-height",`${ct}px`);let tt=me(ae).devicePixelRatio||1,{x:Vt,y:io,width:gn,height:vr}=Ke.reference,_r=(Math.round((Vt+gn)*tt)-Math.round(Vt*tt))/tt,yr=(Math.round((io+vr)*tt)-Math.round(io*tt))/tt;xt.setProperty("--anchor-width",`${_r}px`),xt.setProperty("--anchor-height",`${yr}px`)}}),yl(ae=>({element:q.current||xe(ae.elements.floating).createElement("div"),padding:d,offsetParent:"floating"}),[d]),{name:"transformOrigin",fn(ae){let{elements:Le,middlewareData:ct,placement:Ke,rects:xt,y:tt}=ae,Vt=Ae(Ke),io=ze(Vt),gn=q.current,vr=ct.arrow?.x||0,_r=ct.arrow?.y||0,yr=gn?.clientWidth||0,Pf=gn?.clientHeight||0,xr=vr+yr/2,$s=_r+Pf/2,Cf=Math.abs(ct.shift?.y||0),Af=xt.reference.height/2,Lo=typeof r=="function"?r(Sl(ae,n,H)):r,Of=Cf>Lo,Nf={top:`${xr}px calc(100% + ${Lo}px)`,bottom:`${xr}px ${-Lo}px`,left:`calc(100% + ${Lo}px) ${$s}px`,right:`${-Lo}px ${$s}px`}[Vt],Lf=`${xr}px ${xt.reference.y+Af-tt}px`;return Le.floating.style.setProperty("--transform-origin",ue&&io==="y"&&Of?Lf:Nf),{}}},xl,y),D(()=>{!g&&u&&u.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[g,u]);let Fe=Ue.useMemo(()=>({elementResize:!f&&typeof ResizeObserver<"u",layoutShift:!f&&typeof IntersectionObserver<"u"}),[f]),{refs:Xe,elements:Be,x:no,y:ln,middlewareData:_e,update:ro,placement:B,context:j,isPositioned:he,floatingStyles:Te}=gi({rootContext:u,open:m?g:void 0,placement:A,middleware:X,strategy:o,whileElementsMounted:m?void 0:(...ae)=>Go(...ae,Fe),nodeId:w,externalTree:T}),{sideX:Pt,sideY:No}=_e.adaptiveOrigin||qo,yt=he?o:"fixed",Ve=Ue.useMemo(()=>{let ae=y?{position:yt,[Pt]:no,[No]:ln}:{position:yt,...Te};return he||(ae.opacity=0),ae},[y,yt,Pt,no,No,ln,Te,he]),Ct=Ue.useRef(null);D(()=>{if(!g)return;let ae=I.current,Le=typeof ae=="function"?ae():ae,Ke=(El(Le)?Le.current:Le)||null||null;Ke!==Ct.current&&(Xe.setPositionReference(Ke),Ct.current=Ke)},[g,Xe,L,I]),Ue.useEffect(()=>{if(!g)return;let ae=I.current;typeof ae!="function"&&El(ae)&&ae.current!==Ct.current&&(Xe.setPositionReference(ae.current),Ct.current=ae.current)},[g,Xe,L,I]),Ue.useEffect(()=>{if(m&&g&&Be.reference&&Be.floating)return Go(Be.reference,Be.floating,ro,Fe)},[m,g,Be,ro,Fe]);let At=Ae(B),dn=Tl(n,At,H),un=st(B)||"center",fn=!!_e.hide?.referenceHidden;D(()=>{h&&g&&he&&R(At)},[h,g,he,At]);let pn=Ue.useMemo(()=>({position:"absolute",top:_e.arrow?.y,left:_e.arrow?.x}),[_e.arrow]),mn=_e.arrow?.centerOffset!==0;return Ue.useMemo(()=>({positionerStyles:Ve,arrowStyles:pn,arrowRef:q,arrowUncentered:mn,side:dn,align:un,physicalSide:At,anchorHidden:fn,refs:Xe,context:j,isPositioned:he,update:ro}),[Ve,pn,q,mn,dn,un,At,fn,Xe,j,he,ro])}function El(e){return e!=null&&"current"in e}function Xn(e){return e==="starting"?rc:be}function Pl(e,t,{styles:o,transitionStatus:n,props:r,refs:i,hidden:s,inert:a=!1}){let l={...o};return a&&(l.pointerEvents="none"),Pe("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:l},Xn(n),r],stateAttributesMapping:xo})}var Cl=b(z(),1);var Si=Cl.forwardRef(function(t,o){let{render:n,className:r,disabled:i=!1,focusableWhenDisabled:s=!1,nativeButton:a=!0,style:l,...c}=t,{getButtonProps:d,buttonRef:f}=La({disabled:i,focusableWhenDisabled:s,native:a});return Pe("button",t,{state:{disabled:i},ref:[o,f],props:[c,d]})});var Ne=b(z(),1),Hl=b(Mt(),1);var Al=b(z(),1);function Ol(e){let[t,o]=Al.useState({current:e,previous:null});return e!==t.current&&o({current:e,previous:t.current}),t.previous}var Ro=b(z(),1);function Ei(e){let t=Ie(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=ye(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n;return(zt(o)!==i||zt(n)!==s)&&(o=i,n=s),{width:o,height:n}}function Ll(e){let{popupElement:t,positionerElement:o,content:n,mounted:r,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:l}=e,c=po(t,!0,!1),d=lo(),f=Ro.useRef(null),p=Ro.useRef(!0),m=Ro.useRef(Nt),u=Y(i),g=Y(s),v=Ro.useMemo(()=>{let _=a==="top",w=a==="left";return l==="rtl"?(_=_||a==="inline-end",w=w||a==="inline-end"):(_=_||a==="inline-start",w=w||a==="inline-start"),_?{position:"absolute",[a==="top"?"bottom":"top"]:"0",[w?"right":"left"]:"0"}:be},[a,l]);D(()=>{if(!r){m.current=Nt,p.current=!0,f.current=null;return}if(!t||!o)return;m.current=Nl(t,v),Ti(t,"auto");let _=qn(t,"position","static"),w=qn(t,"transform","none"),y=qn(t,"scale","1"),h=Nl(o,{"--available-width":"max-content","--available-height":"max-content"});function T(){_(),w(),h()}function x(){T(),y()}if(u?.(),p.current||f.current===null){Kn(o,"max-content");let C=Ei(t);return f.current=C,Kn(o,C),x(),g?.(null,C),p.current=!1,()=>{m.current(),m.current=Nt}}Kn(o,"max-content");let R=f.current,E=Ei(t);f.current=E,Ti(t,R),x(),g?.(R,E),Kn(o,E);let k=new AbortController;return d.request(()=>{Ti(t,E),c(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},k.signal)}),()=>{k.abort(),d.cancel(),m.current(),m.current=Nt}},[n,t,o,c,d,r,u,g,v])}function qn(e,t,o){let n=e.style.getPropertyValue(t);return e.style.setProperty(t,o),()=>{e.style.setProperty(t,n)}}function Nl(e,t){let o=[];for(let[n,r]of Object.entries(t))o.push(qn(e,n,r));return o.length?()=>{o.forEach(n=>n())}:Nt}function Ti(e,t){let o=t==="auto"?"auto":`${t.width}px`,n=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",o),e.style.setProperty("--popup-height",n)}function Kn(e,t){let o=t==="max-content"?"max-content":`${t.width}px`,n=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",o),e.style.setProperty("--positioner-height",n)}var Il=b(z(),1);var Ml=b(K(),1),Zn=function(t){let{direction:o="ltr"}=t,n=Il.useMemo(()=>({direction:o}),[o]);return(0,Ml.jsx)(Er.Provider,{value:n,children:t.children})};var So=b(K(),1);function zl(e){let{store:t,side:o,cssVars:n,children:r}=e,i=so(),s=t.useState("activeTriggerElement"),a=t.useState("activeTriggerId"),l=t.useState("open"),c=t.useState("payload"),d=t.useState("mounted"),f=t.useState("popupElement"),p=t.useState("positionerElement"),m=Ol(l?s:null),u=kg(a,c),g=Ne.useRef(null),[v,_]=Ne.useState(null),[w,y]=Ne.useState(null),h=Ne.useRef(null),T=Ne.useRef(null),x=po(h,!0,!1),R=lo(),[E,k]=Ne.useState(null),[C,W]=Ne.useState(!1);D(()=>(t.set("hasViewport",!0),()=>{t.set("hasViewport",!1)}),[t]);let O=Y(()=>{h.current?.style.setProperty("animation","none"),h.current?.style.setProperty("transition","none"),T.current?.style.setProperty("display","none")}),L=Y(P=>{h.current?.style.removeProperty("animation"),h.current?.style.removeProperty("transition"),T.current?.style.removeProperty("display"),P&&k(P)}),I=Ne.useRef(null);D(()=>{(!l||!d)&&(I.current=null)},[l,d]),D(()=>{if(s&&m&&s!==m&&I.current!==s&&g.current){_(g.current),W(!0);let P=Tg(m,s);y(P),R.request(()=>{Hl.flushSync(()=>{W(!1)}),x(()=>{_(null),k(null),g.current=null})}),I.current=s}},[s,m,v,x,R]),D(()=>{let P=h.current;if(!P)return;let A=xe(P).createElement("div");for(let M of Array.from(P.childNodes))A.appendChild(M.cloneNode(!0));g.current=A});let S=v!=null,N;S?N=(0,So.jsxs)(Ne.Fragment,{children:[(0,So.jsx)("div",{"data-previous":!0,inert:_l(!0),ref:T,style:{...E?{[n.popupWidth]:`${E.width}px`,[n.popupHeight]:`${E.height}px`}:null,position:"absolute"},"data-ending-style":C?void 0:""},"previous"),(0,So.jsx)("div",{"data-current":!0,ref:h,"data-starting-style":C?"":void 0,children:r},u)]}):N=(0,So.jsx)("div",{"data-current":!0,ref:h,children:r},u),D(()=>{let P=T.current;!P||!v||P.replaceChildren(...Array.from(v.childNodes))},[v]),Ll({popupElement:f,positionerElement:p,mounted:d,content:c,onMeasureLayout:O,onMeasureLayoutComplete:L,side:o,direction:i});let H={activationDirection:Eg(w),transitioning:S};return{children:N,state:H}}function Eg(e){if(e)return`${Bl(e.horizontal,5,"right","left")} ${Bl(e.vertical,5,"down","up")}`}function Bl(e,t,o,n){return e>t?o:e<-t?n:""}function Tg(e,t){let o=e.getBoundingClientRect(),n=t.getBoundingClientRect(),r={x:o.left+o.width/2,y:o.top+o.height/2},i={x:n.left+n.width/2,y:n.top+n.height/2};return{horizontal:i.x-r.x,vertical:i.y-r.y}}function kg(e,t){let[o,n]=Ne.useState(0),r=Ne.useRef(e),i=Ne.useRef(t),s=Ne.useRef(!1);return D(()=>{let a=r.current,l=i.current,c=e!==a,d=t!==l;c?(n(f=>f+1),s.current=!d):s.current&&d&&(n(f=>f+1),s.current=!1),r.current=e,i.current=t},[e,t]),`${e??"current"}-${o}`}var Qn=b(z(),1),Dl=b(Mt(),1);var jl=b(K(),1),Fl=Qn.forwardRef(function(t,o){let{children:n,container:r,className:i,render:s,style:a,...l}=t,{portalNode:c,portalSubtree:d}=qr({container:r,ref:o,componentProps:t,elementProps:l});return!d&&!c?null:(0,jl.jsxs)(Qn.Fragment,{children:[d,c&&Dl.createPortal(n,c)]})});var Ze={};Ot(Ze,{Arrow:()=>nd,Handle:()=>Zo,Popup:()=>td,Portal:()=>Ql,Positioner:()=>$l,Provider:()=>rd,Root:()=>Wl,Trigger:()=>Kl,Viewport:()=>ad,createHandle:()=>cd});var ht=b(z(),1);var Jn=b(z(),1),ki=Jn.createContext(void 0);function qe(e){let t=Jn.useContext(ki);if(t===void 0&&!e)throw new Error(ke(72));return t}var Vl=b(z(),1);var Pg={...gl,disabled:Z(e=>e.disabled),instantType:Z(e=>e.instantType),isInstantPhase:Z(e=>e.isInstantPhase),trackCursorAxis:Z(e=>e.trackCursorAxis),disableHoverablePopup:Z(e=>e.disableHoverablePopup),lastOpenChangeReason:Z(e=>e.openChangeReason),closeOnClick:Z(e=>e.closeOnClick),closeDelay:Z(e=>e.closeDelay),hasViewport:Z(e=>e.hasViewport)},Eo=class e extends wo{constructor(t,o,n=!1){let r=new jt,i={...Cg(),...t};i.floatingRootContext=pl(r,o,n),super(i,{popupRef:Vl.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:r},Pg)}setOpen=(t,o)=>{rl(this,t,o,{extraState:{openChangeReason:o.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,ee(U.triggerPress,t))}static useStore(t,o){return nl(t,(r,i)=>new e(o,r,i)).store}};function Cg(){return{...fl(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,hasViewport:!1}}var $n=b(K(),1),Wl=fi(function(t){let{disabled:o=!1,defaultOpen:n=!1,open:r,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:l,onOpenChangeComplete:c,handle:d,triggerId:f,defaultTriggerId:p=null,children:m}=t,u=Eo.useStore(d?.store,{open:n,openProp:r,activeTriggerId:p,triggerIdProp:f});il(u,r,n,p),u.useControlledProp("openProp",r),u.useControlledProp("triggerIdProp",f),u.useContextCallback("onOpenChange",l),u.useContextCallback("onOpenChangeComplete",c);let g=u.useState("open"),v=!o&&g,_=u.useState("activeTriggerId"),w=u.useState("mounted"),y=u.useState("payload");u.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i}),u.useSyncedValue("disabled",o),al(u,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:h,transitionStatus:T}=cl(v,u),x=u.useState("isInstantPhase"),R=u.useState("instantType"),E=u.useState("lastOpenChangeReason"),k=ht.useRef(null);D(()=>{g&&o&&u.setOpen(!1,ee(U.disabled))},[g,o,u]),D(()=>{T==="ending"&&E===U.none||T!=="ending"&&x?(R!=="delay"&&(k.current=R),u.set("instantType","delay")):k.current!==null&&(u.set("instantType",k.current),k.current=null)},[T,x,E,R,u]),D(()=>{v&&_==null&&u.set("payload",void 0)},[u,_,v]);let C=ht.useCallback(()=>{u.setOpen(!1,ee(U.imperativeAction))},[u]);ht.useImperativeHandle(a,()=>({unmount:h,close:C}),[h,C]);let W=v||w||!o&&s!=="none";return(0,$n.jsxs)(ki.Provider,{value:u,children:[W&&(0,$n.jsx)(Ag,{store:u,disabled:o,trackCursorAxis:s}),typeof m=="function"?m({payload:y}):m]})});function Ag({store:e,disabled:t,trackCursorAxis:o}){let n=e.useState("floatingRootContext"),r=Qr(n,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=Zr(n,{enabled:!t&&o!=="none",axis:o==="none"?void 0:o}),s=ht.useMemo(()=>we(i.reference,r.reference),[i.reference,r.reference]),a=ht.useMemo(()=>we(i.trigger,r.trigger),[i.trigger,r.trigger]),l=ht.useMemo(()=>we(ol,i.floating,r.floating),[i.floating,r.floating]);return ll(e,{activeTriggerProps:s,inactiveTriggerProps:a,popupProps:l}),null}var tr=b(z(),1);var er=b(z(),1),Pi=er.createContext(void 0);function Yl(){return er.useContext(Pi)}var Ul=(function(e){return e[e.popupOpen=Ko.popupOpen]="popupOpen",e.triggerDisabled="data-trigger-disabled",e})({});var Xl="data-base-ui-tooltip-trigger";function Gl(e){if("composedPath"in e){let o=e.composedPath();for(let n=0;ng.select("transitionStatus")==="ending",shouldOpen(){return!A.current}}),G=hi(y,{enabled:!S}).reference,q=X=>{let pe=A.current,ue=Gl(X),_t=te(ue),Ee=h.current,Fe=Ee&&ue&&ie(Ee,ue);if(_t&&g.select("open")&&g.select("lastOpenChangeReason")===U.triggerHover){g.setOpen(!1,ee(U.triggerHover,X));return}if(pe&&!_t&&Fe&&!N.current&&!g.select("open")&&Ee&&St(Q.current)){let Xe=()=>{!A.current&&!N.current&&!g.select("open")&&g.setOpen(!0,ee(U.triggerHover,X,Ee))},Be=V();Be===0?(M.clear(),Xe()):M.start(Be,Xe)}},J=g.useState("triggerProps",E);return Pe("button",t,{state:{open:w},ref:[o,R,h],props:[se,G,E||H!=="none"?J:void 0,{onMouseOver(X){q(X.nativeEvent)},onFocus(X){oe(Gl(X.nativeEvent))&&X.preventBaseUIHandler()},onMouseLeave(){A.current=!1,M.clear(),Q.current=void 0},onPointerEnter(X){Q.current=X.pointerType},onPointerDown(X){Q.current=X.pointerType,g.set("closeOnClick",d),d&&!g.select("open")&&g.cancelPendingOpen(X.nativeEvent)},onClick(X){d&&!g.select("open")&&g.cancelPendingOpen(X.nativeEvent)},id:v,[Ul.triggerDisabled]:S?"":void 0,[Xl]:S?void 0:""},m],stateAttributesMapping:vl})});var Zl=b(z(),1);var or=b(z(),1),Ci=or.createContext(void 0);function ql(){let e=or.useContext(Ci);if(e===void 0)throw new Error(ke(70));return e}var Ai=b(K(),1),Ql=Zl.forwardRef(function(t,o){let{keepMounted:n=!1,...r}=t;return qe().useState("mounted")||n?(0,Ai.jsx)(Ci.Provider,{value:n,children:(0,Ai.jsx)(Fl,{ref:o,...r})}):null});var rr=b(z(),1);var nr=b(z(),1),Oi=nr.createContext(void 0);function To(){let e=nr.useContext(Oi);if(e===void 0)throw new Error(ke(71));return e}var Jl=b(K(),1),$l=rr.forwardRef(function(t,o){let{render:n,className:r,anchor:i,positionMethod:s="absolute",side:a="top",align:l="center",sideOffset:c=0,alignOffset:d=0,collisionBoundary:f="clipping-ancestors",collisionPadding:p=5,arrowPadding:m=5,sticky:u=!1,disableAnchorTracking:g=!1,collisionAvoidance:v=ic,style:_,...w}=t,y=qe(),h=ql(),T=y.useState("open"),x=y.useState("mounted"),R=y.useState("trackCursorAxis"),E=y.useState("disableHoverablePopup"),k=y.useState("floatingRootContext"),C=y.useState("instantType"),W=y.useState("transitionStatus"),O=y.useState("hasViewport"),L=kl({anchor:i,positionMethod:s,floatingRootContext:k,mounted:x,side:a,sideOffset:c,align:l,alignOffset:d,collisionBoundary:f,collisionPadding:p,sticky:u,arrowPadding:m,disableAnchorTracking:g,keepMounted:h,collisionAvoidance:v,adaptiveOrigin:O?Rl:void 0}),I=rr.useMemo(()=>({open:T,side:L.side,align:L.align,anchorHidden:L.anchorHidden,instant:R!=="none"?"tracking-cursor":C}),[T,L.side,L.align,L.anchorHidden,R,C]),S=Pl(t,I,{styles:L.positionerStyles,transitionStatus:W,props:w,refs:[o,y.useStateSetter("positionerElement")],hidden:!x,inert:!T||R==="both"||E});return(0,Jl.jsx)(Oi.Provider,{value:L,children:S})});var ed=b(z(),1);var Ng={...xo,...Ta},td=ed.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=qe(),{side:l,align:c}=To(),d=a.useState("open"),f=a.useState("instantType"),p=a.useState("transitionStatus"),m=a.useState("popupProps"),u=a.useState("floatingRootContext"),g=a.useState("disabled"),v=a.useState("closeDelay");kn({open:d,ref:a.context.popupRef,onComplete(){d&&a.context.onOpenChangeComplete?.(!0)}}),_i(u,{enabled:!g,closeDelay:v});let _=a.useStateSetter("popupElement");return Pe("div",t,{state:{open:d,side:l,align:c,instant:f,transitionStatus:p},ref:[o,a.context.popupRef,_],props:[m,Xn(p),s],stateAttributesMapping:Ng})});var od=b(z(),1);var nd=od.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=qe(),{arrowRef:l,side:c,align:d,arrowUncentered:f,arrowStyles:p}=To(),m=a.useState("open"),u=a.useState("instantType");return Pe("div",t,{state:{open:m,side:c,align:d,uncentered:f,instant:u},ref:[o,l],props:[{style:p,"aria-hidden":!0},s],stateAttributesMapping:xo})});var Ni=b(z(),1);var Li=b(K(),1),rd=function(t){let{delay:o,closeDelay:n,timeout:r=400}=t,i=Ni.useMemo(()=>({delay:o,closeDelay:n}),[o,n]),s=Ni.useMemo(()=>({open:o,close:n}),[o,n]);return(0,Li.jsx)(Pi.Provider,{value:i,children:(0,Li.jsx)(Xr,{delay:s,timeoutMs:r,children:t.children})})};var sd=b(z(),1);var id=(function(e){return e.popupWidth="--popup-width",e.popupHeight="--popup-height",e})({});var Lg={activationDirection:e=>e?{"data-activation-direction":e}:null},ad=sd.forwardRef(function(t,o){let{render:n,className:r,style:i,children:s,...a}=t,l=qe(),c=To(),d=l.useState("instantType"),{children:f,state:p}=zl({store:l,side:c.side,cssVars:id,children:s}),m={activationDirection:p.activationDirection,transitioning:p.transitioning,instant:d};return Pe("div",t,{state:m,ref:o,props:[a,{children:f}],stateAttributesMapping:Lg})});var Zo=class{constructor(){this.store=new Eo}open(t){let o=t?this.store.context.triggerElements.getById(t):void 0;if(t&&!o)throw new Error(ke(81,t));this.store.setOpen(!0,ee(U.imperativeAction,void 0,o))}close(){this.store.setOpen(!1,ee(U.imperativeAction,void 0,void 0))}get isOpen(){return this.store.select("open")}};function cd(){return new Zo}function Qe(e){return Pe(e.defaultTagName??"div",e,e)}var ud=b(ce(),1),Ii="data-wp-hash";function Mi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Mg(document)),e.__wpStyleRuntime}function Ig(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ii}]`))if(o.getAttribute(Ii)===t)return!0;return!1}function fd(e,t,o){if(!e.head)return;let n=Mi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ig(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ii,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Mg(e){let t=Mi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)fd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function pd(e,t){let o=Mi();o.styles.set(e,t);for(let n of o.documents.keys())fd(n,e,t)}typeof process>"u",pd("a495f9d138",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var ld={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",pd("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var dd={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},Je=(0,ud.forwardRef)(function({variant:t="body-md",render:o,className:n,...r},i){return Qe({render:o,defaultTagName:"span",ref:i,props:we(r,{className:$(ld.text,dd.heading,dd.p,ld[t],n)})})});var hd=b(K(),1),Bi="data-wp-hash";function Hi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Hg(document)),e.__wpStyleRuntime}function Bg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Bi}]`))if(o.getAttribute(Bi)===t)return!0;return!1}function bd(e,t,o){if(!e.head)return;let n=Hi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Bg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Bi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Hg(e){let t=Hi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)bd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function zg(e,t){let o=Hi();o.styles.set(e,t);for(let n of o.documents.keys())bd(n,e,t)}typeof process>"u",zg("9db2873e7f","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._96e6251aad1a6136__badge{border-radius:var(--wpds-border-radius-lg,8px);padding-block:var(--wpds-dimension-padding-xs,4px);padding-inline:var(--wpds-dimension-padding-sm,8px)}._99f7158cb520f750__is-high-intent{background-color:var(--wpds-color-background-surface-error,#f6e6e3);color:var(--wpds-color-foreground-content-error,#470000)}.c20ebef2365bc8b7__is-medium-intent{background-color:var(--wpds-color-background-surface-warning,#fde6be);color:var(--wpds-color-foreground-content-warning,#2e1900)}._365e1626c6202e52__is-low-intent{background-color:var(--wpds-color-background-surface-caution,#fee995);color:var(--wpds-color-foreground-content-caution,#281d00)}._33f8198127ddf4ef__is-stable-intent{background-color:var(--wpds-color-background-surface-success,#c6f7cd);color:var(--wpds-color-foreground-content-success,#002900)}._04c1aca8fc449412__is-informational-intent{background-color:var(--wpds-color-background-surface-info,#deebfa);color:var(--wpds-color-foreground-content-info,#001b4f)}._90726e69d495ec19__is-draft-intent{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);color:var(--wpds-color-foreground-content-neutral,#1e1e1e)}._898f4a544993bd39__is-none-intent{background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);padding-block:calc(var(--wpds-dimension-padding-xs, 4px) - var(--wpds-border-width-xs, 1px));padding-inline:calc(var(--wpds-dimension-padding-sm, 8px) - var(--wpds-border-width-xs, 1px))}}}");var md={badge:"_96e6251aad1a6136__badge","is-high-intent":"_99f7158cb520f750__is-high-intent","is-medium-intent":"c20ebef2365bc8b7__is-medium-intent","is-low-intent":"_365e1626c6202e52__is-low-intent","is-stable-intent":"_33f8198127ddf4ef__is-stable-intent","is-informational-intent":"_04c1aca8fc449412__is-informational-intent","is-draft-intent":"_90726e69d495ec19__is-draft-intent","is-none-intent":"_898f4a544993bd39__is-none-intent"},zi=(0,gd.forwardRef)(function({intent:t="none",className:o,...n},r){return(0,hd.jsx)(Je,{ref:r,className:$(md.badge,md[`is-${t}-intent`],o),...n,variant:"body-sm"})});var ir=b(ce(),1),wd=b(lt(),1),_d=b(K(),1);import{speak as Dg}from"@wordpress/a11y";var Di="data-wp-hash";function ji(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Fg(document)),e.__wpStyleRuntime}function jg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Di}]`))if(o.getAttribute(Di)===t)return!0;return!1}function vd(e,t,o){if(!e.head)return;let n=ji(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(jg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Di,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Fg(e){let t=ji();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)vd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function sr(e,t){let o=ji();o.styles.set(e,t);for(let n of o.documents.keys())vd(n,e,t)}typeof process>"u",sr("b74f1ac304",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);inset-inline-start:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var Qo={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"};typeof process>"u",sr("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Vg={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",sr("2ffedd8246","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var Wg={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",sr("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Yg={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},yd=(0,ir.forwardRef)(function({tone:t="brand",variant:o="solid",size:n="default",className:r,focusableWhenDisabled:i=!0,disabled:s,loading:a,loadingAnnouncement:l=(0,wd.__)("Loading"),children:c,...d},f){let p=$(Yg.button,Vg["box-sizing"],Wg["outset-ring--focus-except-active"],o!=="unstyled"&&Qo.button,Qo[`is-${t}`],Qo[`is-${o}`],Qo[`is-${n}`],a&&Qo["is-loading"],r);return(0,ir.useEffect)(()=>{a&&l&&Dg(l)},[a,l]),(0,_d.jsx)(Si,{ref:f,className:p,focusableWhenDisabled:i,disabled:s??a,...d,children:c})});var Td=b(ce(),1);var Rd=b(ce(),1),Sd=b($t(),1),Ed=b(K(),1),eo=(0,Rd.forwardRef)(function({icon:t,size:o=24,...n},r){return(0,Ed.jsx)(Sd.SVG,{ref:r,...t.props,...n,width:o,height:o})});var Pd=b(K(),1),Fi="data-wp-hash";function Vi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Gg(document)),e.__wpStyleRuntime}function Ug(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Fi}]`))if(o.getAttribute(Fi)===t)return!0;return!1}function kd(e,t,o){if(!e.head)return;let n=Vi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ug(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Fi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Gg(e){let t=Vi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)kd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Xg(e,t){let o=Vi();o.styles.set(e,t);for(let n of o.documents.keys())kd(n,e,t)}typeof process>"u",Xg("b74f1ac304",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);inset-inline-start:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var Kg={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"},Wi=(0,Td.forwardRef)(function({className:t,icon:o,...n},r){return(0,Pd.jsx)(eo,{ref:r,icon:o,className:$(Kg.icon,t),size:24,...n})});Wi.displayName="Button.Icon";var ar=Object.assign(yd,{Icon:Wi});var cr=b($t(),1),Yi=b(K(),1),Ui=(0,Yi.jsx)(cr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Yi.jsx)(cr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-.75 12v-1.5h1.5V16h-1.5Zm0-8v5h1.5V8h-1.5Z"})});var lr=b($t(),1),Gi=b(K(),1),Xi=(0,Gi.jsx)(lr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Gi.jsx)(lr.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})});var dr=b($t(),1),Ki=b(K(),1),qi=(0,Ki.jsx)(dr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Ki.jsx)(dr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z"})});var ur=b($t(),1),Zi=b(K(),1),Qi=(0,Zi.jsx)(ur.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Zi.jsx)(ur.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm.75 4v1.5h-1.5V8h1.5Zm0 8v-5h-1.5v5h1.5Z"})});var fr=b($t(),1),Ji=b(K(),1),$i=(0,Ji.jsx)(fr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Ji.jsx)(fr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm11.53-1.47-1.06-1.06L11 12.94l-1.47-1.47-1.06 1.06L11 15.06l4.53-4.53Z"})});var Cd=b(ce(),1);function es(e,t,o){return(0,Cd.cloneElement)(e??t,{children:o})}var qg=b(Od(),1);var Ld=b(ts(),1),{lock:D4,unlock:Id}=(0,Ld.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function Zg(){let e=qg;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return Id(e.privateApis).ThemeProvider}var Md=Zg();var Bd=b(ce(),1),os="data-wp-hash";function ns(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Jg(document)),e.__wpStyleRuntime}function Qg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${os}]`))if(o.getAttribute(os)===t)return!0;return!1}function Hd(e,t,o){if(!e.head)return;let n=ns(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Qg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(os,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Jg(e){let t=ns();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Hd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function $g(e,t){let o=ns();o.styles.set(e,t);for(let n of o.documents.keys())Hd(n,e,t)}typeof process>"u",$g("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var eb={stack:"_19ce0419607e1896__stack"},tb={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},ko=(0,Bd.forwardRef)(function({direction:t,gap:o,align:n,justify:r,wrap:i,render:s,...a},l){let c={gap:o&&tb[o],alignItems:n,justifyContent:r,flexDirection:t,flexWrap:i};return Qe({render:s,ref:l,props:we(a,{style:c,className:eb.stack})})});var du=b(ce(),1);var Zd=b(ce(),1);var Vd=b(ce(),1);var is="data-wp-hash";function ss(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&nb(document)),e.__wpStyleRuntime}function ob(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${is}]`))if(o.getAttribute(is)===t)return!0;return!1}function Dd(e,t,o){if(!e.head)return;let n=ss(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(ob(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(is,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function nb(e){let t=ss();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Dd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function rb(e,t){let o=ss();o.styles.set(e,t);for(let n of o.documents.keys())Dd(n,e,t)}typeof process>"u",rb("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var zd={slot:"_11fc52b637ff8a7e__slot"},jd="data-wp-compat-overlay-slot";function ib(){return typeof document>"u"?null:document}function sb(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var wt=null;function rs(e){return e.setAttribute("aria-hidden","false"),e}function ab(e){let t=e.createElement("div");return t.setAttribute(jd,""),zd.slot&&t.classList.add(zd.slot),e.body.appendChild(t),t}function Fd(){if(typeof window>"u"||!sb()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=ib();if(!e||!e.body)return;if(wt&&wt.ownerDocument===e&&wt.isConnected)return rs(wt);let t=e.querySelector(`[${jd}]`);return t instanceof HTMLDivElement?(wt=rs(t),wt):(wt?.isConnected&&wt.remove(),wt=rs(ab(e)),wt)}var Wd=b(K(),1),Yd=(0,Vd.forwardRef)(function({container:t,...o},n){return(0,Wd.jsx)(Ze.Portal,{container:t??Fd(),...o,ref:n})});var Ud=b(ce(),1),Kd=b(K(),1),as="data-wp-hash";function cs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&lb(document)),e.__wpStyleRuntime}function cb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${as}]`))if(o.getAttribute(as)===t)return!0;return!1}function Gd(e,t,o){if(!e.head)return;let n=cs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(cb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(as,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function lb(e){let t=cs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Gd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Xd(e,t){let o=cs();o.styles.set(e,t);for(let n of o.documents.keys())Gd(n,e,t)}typeof process>"u",Xd("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var db={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Xd("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var ub={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},qd=(0,Ud.forwardRef)(function({align:t="center",className:o,side:n="top",sideOffset:r=4,...i},s){return(0,Kd.jsx)(Ze.Positioner,{ref:s,align:t,side:n,sideOffset:r,...i,className:$(db["box-sizing"],ub.positioner,o)})});var Jo=b(K(),1),ls="data-wp-hash";function ds(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&pb(document)),e.__wpStyleRuntime}function fb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ls}]`))if(o.getAttribute(ls)===t)return!0;return!1}function Qd(e,t,o){if(!e.head)return;let n=ds(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(fb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ls,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function pb(e){let t=ds();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Qd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function mb(e,t){let o=ds();o.styles.set(e,t);for(let n of o.documents.keys())Qd(n,e,t)}typeof process>"u",mb("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var gb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},bb={background:"#1e1e1e"},us=(0,Zd.forwardRef)(function({portal:t,positioner:o,children:n,className:r,...i},s){let a=(0,Jo.jsx)(Md,{color:bb,children:(0,Jo.jsx)(Ze.Popup,{ref:s,className:$(gb.popup,r),...i,children:n})}),l=es(o,(0,Jo.jsx)(qd,{}),a);return es(t,(0,Jo.jsx)(Yd,{}),l)});var Jd=b(ce(),1),$d=b(K(),1),fs=(0,Jd.forwardRef)(function(t,o){return(0,$d.jsx)(Ze.Trigger,{ref:o,...t})});var eu=b(lt(),1),tu=b(K(),1);function ou({children:e}){return(0,tu.jsx)(Zn,{direction:(0,eu.isRTL)()?"rtl":"ltr",children:e})}var ps=b(K(),1);function ms(e){return(0,ps.jsx)(ou,{children:(0,ps.jsx)(Ze.Root,{...e})})}var iu=b(ce(),1),mr=b(lt(),1);var nu=b(ce(),1),gs="data-wp-hash";function bs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&vb(document)),e.__wpStyleRuntime}function wb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${gs}]`))if(o.getAttribute(gs)===t)return!0;return!1}function ru(e,t,o){if(!e.head)return;let n=bs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(wb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(gs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function vb(e){let t=bs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ru(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function _b(e,t){let o=bs();o.styles.set(e,t);for(let n of o.documents.keys())ru(n,e,t)}typeof process>"u",_b("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var yb={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},hs=(0,nu.forwardRef)(function({render:t,...o},n){return Qe({render:t,ref:n,props:we({className:yb["visually-hidden"]},o,{"data-visually-hidden":""})})});var pr=b(K(),1);function su({"aria-describedby":e,"aria-keyshortcuts":t,shortcut:o}){let n=(0,iu.useId)(),r=o?n:void 0,i=[e,r].filter(Boolean).join(" ");return{descriptionId:r,targetProps:{"aria-describedby":i||void 0,"aria-keyshortcuts":o?.ariaKeyShortcut??t}}}function au({descriptionId:e,shortcut:t}){return(0,pr.jsx)(hs,{id:e,"aria-hidden":"true",render:(0,pr.jsx)("span",{}),children:(0,mr.sprintf)((0,mr.__)("Keyboard shortcut: %s"),t.label??t.ariaKeyShortcut)})}function cu({className:e,shortcut:t}){return(0,pr.jsx)("span",{"aria-hidden":"true",className:e,dir:"ltr",children:t.displayShortcut})}var $e=b(K(),1),ws="data-wp-hash";function vs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Rb(document)),e.__wpStyleRuntime}function xb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ws}]`))if(o.getAttribute(ws)===t)return!0;return!1}function uu(e,t,o){if(!e.head)return;let n=vs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(xb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ws,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Rb(e){let t=vs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)uu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Sb(e,t){let o=vs();o.styles.set(e,t);for(let n of o.documents.keys())uu(n,e,t)}typeof process>"u",Sb("c5cdafb1bc","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}");var lu={"icon-button":"_28cfdc260e755391__icon-button",icon:"f1c70d719989a85a__icon"},_s=(0,du.forwardRef)(function({label:t,className:o,children:n,disabled:r,focusableWhenDisabled:i=!0,icon:s,size:a,shortcut:l,positioner:c,"aria-describedby":d,"aria-keyshortcuts":f,...p},m){let u=$(lu["icon-button"],o),{descriptionId:g,targetProps:v}=su({"aria-describedby":d,"aria-keyshortcuts":f,shortcut:l});return(0,$e.jsxs)(ms,{children:[(0,$e.jsxs)(fs,{ref:m,...v,disabled:r&&!i,render:(0,$e.jsx)(ar,{...p,size:a,"aria-label":t,disabled:r,focusableWhenDisabled:i}),className:u,children:[(0,$e.jsx)(eo,{icon:s,size:24,className:lu.icon}),l&&g&&(0,$e.jsx)(au,{descriptionId:g,shortcut:l})]}),(0,$e.jsxs)(us,{positioner:c,children:[t,l&&(0,$e.jsxs)($e.Fragment,{children:[" ",(0,$e.jsx)(cu,{shortcut:l})]})]})]})});var fu=b(ce(),1),pu=b(lt(),1),Po=b(K(),1),ys="data-wp-hash";function xs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Tb(document)),e.__wpStyleRuntime}function Eb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ys}]`))if(o.getAttribute(ys)===t)return!0;return!1}function mu(e,t,o){if(!e.head)return;let n=xs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Eb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ys,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Tb(e){let t=xs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)mu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function br(e,t){let o=xs();o.styles.set(e,t);for(let n of o.documents.keys())mu(n,e,t)}typeof process>"u",br("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var kb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",br("2ffedd8246","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--focus-color:var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color);outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var Pb={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",br("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var gr={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",br("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Cb={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},$o=(0,fu.forwardRef)(function({children:t,variant:o="default",tone:n="brand",openInNewTab:r=!1,render:i,className:s,...a},l){return Qe({render:i,defaultTagName:"a",ref:l,props:we(a,{className:$(Cb.a,kb["box-sizing"],Pb["outset-ring--focus-except-active"],o!=="unstyled"&&gr.link,o!=="unstyled"&&gr[`is-${n}`],o==="unstyled"&&gr["is-unstyled"],s),target:r?"_blank":void 0,children:(0,Po.jsxs)(Po.Fragment,{children:[t,r&&(0,Po.jsx)("span",{className:gr["link-icon"],role:"img","aria-label":(0,pu.__)("(opens in a new tab)")})]})})})});var en={};Ot(en,{ActionButton:()=>zu,ActionLink:()=>Fu,Actions:()=>Pu,CloseIcon:()=>Lu,Description:()=>Eu,Root:()=>hu,Title:()=>yu});var Co=b(ce(),1);import{speak as Ab}from"@wordpress/a11y";var Ao=b(K(),1),Ss="data-wp-hash";function Es(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Nb(document)),e.__wpStyleRuntime}function Ob(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ss}]`))if(o.getAttribute(Ss)===t)return!0;return!1}function gu(e,t,o){if(!e.head)return;let n=Es(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ob(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ss,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Nb(e){let t=Es();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)gu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function bu(e,t){let o=Es();o.styles.set(e,t);for(let n of o.documents.keys())gu(n,e,t)}typeof process>"u",bu("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Lb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",bu("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Rs={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Ib={neutral:null,info:Qi,warning:Ui,success:$i,error:qi};function Mb(e){return e==="error"?"assertive":"polite"}function Bb(e){if(e){if(typeof e=="string")return e;try{return(0,Co.renderToString)(e)}catch{return}}}function Hb(e,t){let o=Bb(e);(0,Co.useEffect)(()=>{o&&Ab(o,t)},[o,t])}var hu=(0,Co.forwardRef)(function({intent:t="neutral",children:o,icon:n,spokenMessage:r=o,politeness:i=Mb(t),render:s,...a},l){Hb(r,i);let c=n===null?null:n??Ib[t],d=$(Rs.notice,Rs[`is-${t}`],Lb["box-sizing"]);return Qe({defaultTagName:"div",render:s,ref:l,props:we({className:d,children:(0,Ao.jsxs)(Ao.Fragment,{children:[o,c&&(0,Ao.jsx)(eo,{className:Rs.icon,icon:c})]})},a)})});var wu=b(ce(),1);var _u=b(K(),1),Ts="data-wp-hash";function ks(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Db(document)),e.__wpStyleRuntime}function zb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ts}]`))if(o.getAttribute(Ts)===t)return!0;return!1}function vu(e,t,o){if(!e.head)return;let n=ks(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(zb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ts,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Db(e){let t=ks();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)vu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function jb(e,t){let o=ks();o.styles.set(e,t);for(let n of o.documents.keys())vu(n,e,t)}typeof process>"u",jb("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Fb={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},yu=(0,wu.forwardRef)(function({className:t,...o},n){return(0,_u.jsx)(Je,{ref:n,variant:"heading-md",className:$(Fb.title,t),...o})});var xu=b(ce(),1);var Su=b(K(),1),Ps="data-wp-hash";function Cs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Wb(document)),e.__wpStyleRuntime}function Vb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ps}]`))if(o.getAttribute(Ps)===t)return!0;return!1}function Ru(e,t,o){if(!e.head)return;let n=Cs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Vb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ps,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Wb(e){let t=Cs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ru(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Yb(e,t){let o=Cs();o.styles.set(e,t);for(let n of o.documents.keys())Ru(n,e,t)}typeof process>"u",Yb("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Ub={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Eu=(0,xu.forwardRef)(function({className:t,...o},n){return(0,Su.jsx)(Je,{ref:n,variant:"body-md",className:$(Ub.description,t),...o})});var Tu=b(ce(),1);var As="data-wp-hash";function Os(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Xb(document)),e.__wpStyleRuntime}function Gb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${As}]`))if(o.getAttribute(As)===t)return!0;return!1}function ku(e,t,o){if(!e.head)return;let n=Os(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Gb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(As,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Xb(e){let t=Os();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ku(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Kb(e,t){let o=Os();o.styles.set(e,t);for(let n of o.documents.keys())ku(n,e,t)}typeof process>"u",Kb("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var qb={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Pu=(0,Tu.forwardRef)(function({render:t,...o},n){return Qe({defaultTagName:"div",render:t,ref:n,props:we({className:qb.actions},o)})});var Cu=b(ce(),1),Au=b(lt(),1);var Nu=b(K(),1),Ns="data-wp-hash";function Ls(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Qb(document)),e.__wpStyleRuntime}function Zb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ns}]`))if(o.getAttribute(Ns)===t)return!0;return!1}function Ou(e,t,o){if(!e.head)return;let n=Ls(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Zb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ns,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Qb(e){let t=Ls();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ou(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Jb(e,t){let o=Ls();o.styles.set(e,t);for(let n of o.documents.keys())Ou(n,e,t)}typeof process>"u",Jb("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var $b={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Lu=(0,Cu.forwardRef)(function({className:t,icon:o=Xi,label:n=(0,Au.__)("Dismiss"),...r},i){return(0,Nu.jsx)(_s,{...r,ref:i,className:$($b["close-icon"],t),variant:"minimal",size:"small",tone:"neutral",icon:o,label:n})});var Mu=b(ce(),1);var Hu=b(K(),1),Is="data-wp-hash";function Ms(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&t0(document)),e.__wpStyleRuntime}function e0(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Is}]`))if(o.getAttribute(Is)===t)return!0;return!1}function Bu(e,t,o){if(!e.head)return;let n=Ms(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(e0(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Is,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function t0(e){let t=Ms();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Bu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function o0(e,t){let o=Ms();o.styles.set(e,t);for(let n of o.documents.keys())Bu(n,e,t)}typeof process>"u",o0("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Iu={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},zu=(0,Mu.forwardRef)(function({className:t,loading:o,loadingAnnouncement:n,variant:r,...i},s){return(0,Hu.jsx)(ar,{...i,...o!==void 0?{loading:o,loadingAnnouncement:n??""}:{},ref:s,size:"compact",tone:"neutral",variant:r,className:$(Iu["action-button"],Iu[`is-action-button-${r}`],t)})});var Du=b(ce(),1);var Hs=b(K(),1),Bs="data-wp-hash";function zs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&r0(document)),e.__wpStyleRuntime}function n0(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Bs}]`))if(o.getAttribute(Bs)===t)return!0;return!1}function ju(e,t,o){if(!e.head)return;let n=zs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(n0(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Bs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function r0(e){let t=zs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ju(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function i0(e,t){let o=zs();o.styles.set(e,t);for(let n of o.documents.keys())ju(n,e,t)}typeof process>"u",i0("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var s0={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Fu=(0,Du.forwardRef)(function({className:t,render:o,...n},r){return(0,Hs.jsx)(Je,{ref:r,className:$(s0["action-link"],t),...n,variant:"body-md",render:(0,Hs.jsx)($o,{tone:"neutral",variant:"default",render:o})})});var Vu=b(ce(),1),Wu=b(K(),1),Yu=(0,Vu.forwardRef)(({children:e,className:t,ariaLabel:o,as:n="div",...r},i)=>(0,Wu.jsx)(n,{ref:i,className:$("admin-ui-navigable-region",t),"aria-label":o,role:"region",tabIndex:"-1",...r,children:e}));Yu.displayName="NavigableRegion";var Uu=Yu;var Xu=b(tn(),1),{Fill:Ku,Slot:qu}=(0,Xu.createSlotFill)("SidebarToggle");var et=b(K(),1),Ds="data-wp-hash";function js(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&c0(document)),e.__wpStyleRuntime}function a0(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ds}]`))if(o.getAttribute(Ds)===t)return!0;return!1}function Zu(e,t,o){if(!e.head)return;let n=js(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(a0(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ds,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function c0(e){let t=js();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Zu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function l0(e,t){let o=js();o.styles.set(e,t);for(let n of o.documents.keys())Zu(n,e,t)}typeof process>"u",l0("ddd9aab364","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var to={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function Qu({headingLevel:e=1,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:s,showSidebarToggle:a=!0}){let l=`h${e}`;return(0,et.jsxs)(ko,{direction:"column",className:to.header,children:[(0,et.jsxs)(ko,{className:to["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,et.jsxs)(ko,{direction:"row",gap:"sm",align:"center",justify:"start",children:[a&&(0,et.jsx)(qu,{bubblesVirtually:!0,className:to["sidebar-toggle-slot"]}),n&&(0,et.jsx)("div",{className:to["header-visual"],"aria-hidden":"true",children:n}),r&&(0,et.jsx)(Je,{className:to["header-title"],render:(0,et.jsx)(l,{}),variant:"heading-lg",children:r}),t,o]}),s&&(0,et.jsx)(ko,{align:"center",className:to["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,et.jsx)(Je,{render:(0,et.jsx)("p",{}),variant:"body-md",className:to["header-subtitle"],children:i})]})}var on=b(K(),1),Vs="data-wp-hash";function Ws(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&u0(document)),e.__wpStyleRuntime}function d0(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Vs}]`))if(o.getAttribute(Vs)===t)return!0;return!1}function Ju(e,t,o){if(!e.head)return;let n=Ws(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(d0(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function u0(e){let t=Ws();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ju(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function f0(e,t){let o=Ws();o.styles.set(e,t);for(let n of o.documents.keys())Ju(n,e,t)}typeof process>"u",f0("ddd9aab364","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Fs={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function $u({headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,children:s,className:a,actions:l,ariaLabel:c,hasPadding:d=!1,showSidebarToggle:f=!0}){let p=$(Fs.page,a);return(0,on.jsxs)(Uu,{className:p,ariaLabel:c??(typeof r=="string"?r:""),children:[(r||t||o||l||n)&&(0,on.jsx)(Qu,{headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:l,showSidebarToggle:f}),d?(0,on.jsx)("div",{className:$(Fs.content,Fs["has-padding"]),children:s}):s]})}$u.SidebarToggleFill=Ku;var Ys=$u;var at=b(tn()),Ef=b(nn()),Tf=b(ce()),kt=b(lt()),kf=b(hr());import{privateApis as C0}from"@wordpress/connectors";var of=b(ts()),{lock:V3,unlock:Oo}=(0,of.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/routes");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='09e9b056ea']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","09e9b056ea"),e.appendChild(document.createTextNode(".connectors-page{box-sizing:border-box;margin:0 auto;max-width:680px;padding:24px;width:100%}.connectors-page .components-item{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;padding:20px;scroll-margin-top:120px}.connectors-page .connector-settings__error{color:#cc1818}.connectors-page .connector-settings .components-text-control__input{font-family:monospace;scroll-margin-top:120px}.connectors-page__file-mods-notice{margin-bottom:16px}.connectors-page--empty{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:32px;justify-content:center;text-align:center}.connectors-page .ai-plugin-callout{background-color:#e7d4e4;background-image:radial-gradient(ellipse 70% 120% at 18% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 92% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 58% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%);border-radius:8px;overflow:hidden;padding:24px;padding-inline-end:150px;position:relative}[dir=rtl] .connectors-page .ai-plugin-callout{background-image:radial-gradient(ellipse 70% 120% at 82% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 8% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 42% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%)}.connectors-page .ai-plugin-callout__content{align-items:flex-start;display:flex;flex-direction:column;gap:12px;padding-top:2px}.connectors-page .ai-plugin-callout__content p{font-size:13px;line-height:20px;margin:0}.connectors-page .ai-plugin-callout__decoration{height:110px;inset-inline-end:16px;position:absolute;top:12px;width:110px}.connectors-page>p{color:#949494}@media (max-width:680px){.connectors-page .ai-plugin-callout{padding:12px;padding-inline-end:100px}.connectors-page .ai-plugin-callout__decoration{height:75px;inset-inline-end:8px;top:8px;width:75px}}@media (max-width:480px){.connectors-page{padding:8px}.connectors-page .ai-plugin-callout{padding-inline-end:130px}.connectors-page .components-item{padding:12px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child svg{height:32px;width:32px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child>.components-h-stack:last-child{align-items:flex-end;flex-direction:column}}")),document.head.appendChild(e)}var an=b(tn()),Qs=b(hr()),cn=b(nn()),vt=b(ce()),Ge=b(lt()),yf=b(Us()),xf=b(sf());var wr=b(tn()),Ks=b(ce()),mf=b(nn()),oo=b(lt());import{__experimentalRegisterConnector as p0,__experimentalConnectorItem as pf,__experimentalDefaultConnectorSettings as m0,__experimentalApplicationPasswordConnectorSettings as g0,privateApis as b0}from"@wordpress/connectors";var Gs=b(hr()),sn=b(nn()),rn=b(ce()),fe=b(lt()),af=b(Us());function Xs({file:e,settingName:t,connectorName:o,isInstalled:n,isActivated:r,keySource:i="none",initialIsConnected:s=!1}){let[a,l]=(0,rn.useState)(!1),[c,d]=(0,rn.useState)(!1),[f,p]=(0,rn.useState)(s),[m,u]=(0,rn.useState)(null),g=e?.replace(/\.php$/,""),v=g?.includes("/")?g.split("/")[0]:g,{derivedPluginStatus:_,canManagePlugins:w,currentApiKey:y,currentUsername:h,hasStoredCredentials:T,hasResolvedSettings:x,canInstallPlugins:R}=(0,sn.useSelect)(q=>{let J=q(Gs.store),ge=J.getEntityRecord("root","site")?.[t],de=typeof ge=="string"?ge:"",X=typeof ge=="object"&&ge!==null?ge:void 0,pe=X!==void 0?!!X.username&&!!X.password:!!de,ue=J.hasFinishedResolution("getEntityRecord",["root","site"]),_t=!!J.canUser("create",{kind:"root",name:"plugin"}),Ee={currentApiKey:de,currentUsername:X?.username??"",hasStoredCredentials:pe,hasResolvedSettings:ue,canInstallPlugins:_t};if(!e)return{...Ee,derivedPluginStatus:ue?"active":"checking",canManagePlugins:void 0};let Fe=J.getEntityRecord("root","plugin",g);if(!J.hasFinishedResolution("getEntityRecord",["root","plugin",g]))return{...Ee,derivedPluginStatus:"checking",canManagePlugins:void 0};if(Fe){let no=Fe.status==="active"||Fe.status==="network-active";return{...Ee,derivedPluginStatus:no?"active":"inactive",canManagePlugins:!0}}let Be="not-installed";return r?Be="active":n&&(Be="inactive"),{...Ee,derivedPluginStatus:Be,canManagePlugins:!1}},[e,g,t,n,r]),E=m??_,k=w,C=E==="active"&&f||m==="active"&&T,{saveEntityRecord:W,invalidateResolution:O}=(0,sn.useDispatch)(Gs.store),{createSuccessNotice:L,createErrorNotice:I}=(0,sn.useDispatch)(af.store),S=q=>W("root","site",{[t]:q},{throwOnError:!0}),N=()=>{L((0,fe.sprintf)((0,fe.__)("%s connected successfully."),o),{id:"connector-connect-success",type:"snackbar"})},H=()=>{L((0,fe.sprintf)((0,fe.__)("%s disconnected."),o),{id:"connector-disconnect-success",type:"snackbar"})},P=()=>{I((0,fe.sprintf)((0,fe.__)("Failed to disconnect %s."),o),{id:"connector-disconnect-error",type:"snackbar"})},A=async()=>{if(v){d(!0);try{await W("root","plugin",{slug:v,status:"active"},{throwOnError:!0}),u("active"),O("getEntityRecord",["root","site"]),l(!0),L((0,fe.sprintf)((0,fe.__)("Plugin for %s installed and activated successfully."),o),{id:"connector-plugin-install-success",type:"snackbar"})}catch{I((0,fe.sprintf)((0,fe.__)("Failed to install plugin for %s."),o),{id:"connector-plugin-install-error",type:"snackbar"})}finally{d(!1)}}},M=async()=>{if(e){d(!0);try{await W("root","plugin",{plugin:g,status:"active"},{throwOnError:!0}),u("active"),O("getEntityRecord",["root","site"]),l(!0),L((0,fe.sprintf)((0,fe.__)("Plugin for %s activated successfully."),o),{id:"connector-plugin-activate-success",type:"snackbar"})}catch{I((0,fe.sprintf)((0,fe.__)("Failed to activate plugin for %s."),o),{id:"connector-plugin-activate-error",type:"snackbar"})}finally{d(!1)}}};return{pluginStatus:E,canInstallPlugins:R,canActivatePlugins:k,isExpanded:a,setIsExpanded:l,isBusy:c,isConnected:C,currentApiKey:y,currentUsername:h,hasResolvedSettings:x,keySource:i,handleButtonClick:()=>{if(E==="not-installed"){if(R===!1)return;A()}else if(E==="inactive"){if(k===!1)return;M()}else l(!a)},getButtonLabel:()=>{if(c)return E==="not-installed"?(0,fe.__)("Installing\u2026"):(0,fe.__)("Activating\u2026");if(a)return(0,fe.__)("Cancel");if(C)return(0,fe.__)("Edit");switch(E){case"checking":return(0,fe.__)("Checking\u2026");case"not-installed":return(0,fe.__)("Install");case"inactive":return(0,fe.__)("Activate");case"active":return(0,fe.__)("Set up")}},saveApiKey:async q=>{let J=y;try{let de=(await S(q))?.[t];if(q&&(de===J||!de))throw new Error("It was not possible to connect to the provider using this key.");p(!0),N()}catch(ne){throw console.error("Failed to save API key:",ne),ne}},removeApiKey:async()=>{try{await S(""),p(!1),H()}catch(q){console.error("Failed to remove API key:",q),P()}},saveCredentials:async({username:q,applicationPassword:J})=>{try{let de=(await S({username:q,password:J}))?.[t];if(!de?.username||!de?.password)throw new Error((0,fe.__)("It was not possible to save these credentials."));p(!0),N()}catch(ne){throw console.error("Failed to save credentials:",ne),ne}},removeCredentials:async()=>{try{await S({username:"",password:""}),p(!1),H()}catch(q){console.error("Failed to remove credentials:",q),P()}}}}var cf=()=>React.createElement("svg",{width:"40",height:"40",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},React.createElement("path",{d:"M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364l2.0201-1.1685a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.4043-.6813zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z",fill:"currentColor"})),lf=()=>React.createElement("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},React.createElement("path",{d:"M6.2 21.024L12.416 17.536L12.52 17.232L12.416 17.064H12.112L11.072 17L7.52 16.904L4.44 16.776L1.456 16.616L0.704 16.456L0 15.528L0.072 15.064L0.704 14.64L1.608 14.72L3.608 14.856L6.608 15.064L8.784 15.192L12.008 15.528H12.52L12.592 15.32L12.416 15.192L12.28 15.064L9.176 12.96L5.816 10.736L4.056 9.456L3.104 8.808L2.624 8.2L2.416 6.872L3.28 5.92L4.44 6L4.736 6.08L5.912 6.984L8.424 8.928L11.704 11.344L12.184 11.744L12.376 11.608L12.4 11.512L12.184 11.152L10.4 7.928L8.496 4.648L7.648 3.288L7.424 2.472C7.344 2.136 7.288 1.856 7.288 1.512L8.272 0.176L8.816 0L10.128 0.176L10.68 0.656L11.496 2.52L12.816 5.456L14.864 9.448L15.464 10.632L15.784 11.728L15.904 12.064H16.112V11.872L16.28 9.624L16.592 6.864L16.896 3.312L17 2.312L17.496 1.112L18.48 0.464L19.248 0.832L19.88 1.736L19.792 2.32L19.416 4.76L18.68 8.584L18.2 11.144H18.48L18.8 10.824L20.096 9.104L22.272 6.384L23.232 5.304L24.352 4.112L25.072 3.544H26.432L27.432 5.032L26.984 6.568L25.584 8.344L24.424 9.848L22.76 12.088L21.72 13.88L21.816 14.024L22.064 14L25.824 13.2L27.856 12.832L30.28 12.416L31.376 12.928L31.496 13.448L31.064 14.512L28.472 15.152L25.432 15.76L20.904 16.832L20.848 16.872L20.912 16.952L22.952 17.144L23.824 17.192H25.96L29.936 17.488L30.976 18.176L31.6 19.016L31.496 19.656L29.896 20.472L27.736 19.96L22.696 18.76L20.968 18.328H20.728V18.472L22.168 19.88L24.808 22.264L28.112 25.336L28.28 26.096L27.856 26.696L27.408 26.632L24.504 24.448L23.384 23.464L20.848 21.328H20.68V21.552L21.264 22.408L24.352 27.048L24.512 28.472L24.288 28.936L23.488 29.216L22.608 29.056L20.8 26.52L18.936 23.664L17.432 21.104L17.248 21.208L16.36 30.768L15.944 31.256L14.984 31.624L14.184 31.016L13.76 30.032L14.184 28.088L14.696 25.552L15.112 23.536L15.488 21.032L15.712 20.2L15.696 20.144L15.512 20.168L13.624 22.76L10.752 26.64L8.48 29.072L7.936 29.288L6.992 28.8L7.08 27.928L7.608 27.152L10.752 23.152L12.648 20.672L13.872 19.24L13.864 19.032H13.792L5.44 24.456L3.952 24.648L3.312 24.048L3.392 23.064L3.696 22.744L6.208 21.016L6.2 21.024Z",fill:"#D97757"})),df=()=>React.createElement("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},React.createElement("path",{d:"M0 4C0 1.79086 1.79086 0 4 0H28C30.2091 0 32 1.79086 32 4V28C32 30.2091 30.2091 32 28 32H4C1.79086 32 0 30.2091 0 28V4Z",fill:"#F0F0F0"}),React.createElement("path",{d:"M14.5 8V12H17.5V8H19V12H20.5C20.7652 12 21.0196 12.1054 21.2071 12.2929C21.3946 12.4804 21.5 12.7348 21.5 13V17L18.5 21V23C18.5 23.2652 18.3946 23.5196 18.2071 23.7071C18.0196 23.8946 17.7652 24 17.5 24H14.5C14.2348 24 13.9804 23.8946 13.7929 23.7071C13.6054 23.5196 13.5 23.2652 13.5 23V21L10.5 17V13C10.5 12.7348 10.6054 12.4804 10.7929 12.2929C10.9804 12.1054 11.2348 12 11.5 12H13V8H14.5ZM15 20.5V22.5H17V20.5L20 16.5V13.5H12V16.5L15 20.5Z",fill:"#949494"})),uf=()=>React.createElement("svg",{width:"40",height:"40",viewBox:"0 0 44 44",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},React.createElement("rect",{width:"44",height:"44",fill:"#357B49",rx:"6"}),React.createElement("path",{fill:"#fff",fillRule:"evenodd",d:"m29.746 28.31-6.392-16.797c-.152-.397-.305-.672-.789-.675-.673 0-1.408.611-1.746 1.316l-7.378 16.154c-.072.16-.143.311-.214.454-.5.995-1.045 1.546-2.357 1.626a.399.399 0 0 0-.16.033l-.01.004a.399.399 0 0 0-.23.392v.01c0 .054.01.106.03.155l.004.01a.416.416 0 0 0 .394.252h6.212a.417.417 0 0 0 .307-.12.416.416 0 0 0 .124-.305.398.398 0 0 0-.105-.302.399.399 0 0 0-.294-.127c-.757 0-2.197-.062-2.197-1.164.02-.318.103-.63.245-.916l1.399-3.152c.52-1.163 1.654-1.163 2.572-1.163h5.843c.023 0 .044 0 .062.003.13.014.16.081.214.242l1.534 4.07a2.857 2.857 0 0 1 .216 1.04c0 .054-.003.104-.01.153-.09.726-.831.887-1.49.887a.4.4 0 0 0-.294.127l-.007.008-.007.008a.401.401 0 0 0-.092.286v.01c0 .054.01.106.03.155l.005.01a.42.42 0 0 0 .395.252h7.011a.413.413 0 0 0 .279-.13.412.412 0 0 0 .11-.297.387.387 0 0 0-.09-.294.388.388 0 0 0-.277-.135c-1.448-.122-2.295-.643-2.847-2.08Zm-11.985-5.844 2.847-6.304c.361-.728.659-1.486.889-2.265 0-.06.03-.092.06-.092s.061.032.061.091c.02.122.045.247.073.374.197.888.584 1.878.914 2.723l.176.453 1.684 4.529a.927.927 0 0 1 .092.4.473.473 0 0 1-.009.094c-.041.202-.228.272-.602.272h-6.063c-.122 0-.184-.03-.184-.092a.36.36 0 0 1 .062-.183Zm17.107-.721c0 .786-.446 1.231-1.25 1.231-.806 0-1.125-.409-1.125-1.034 0-.786.465-1.231 1.25-1.231.785 0 1.125.427 1.125 1.034ZM9.629 23.002c.803 0 1.25-.447 1.25-1.231 0-.607-.343-1.036-1.128-1.036-.785 0-1.25.447-1.25 1.231 0 .625.325 1.036 1.128 1.036Z",clipRule:"evenodd"})),ff=()=>React.createElement("svg",{width:"40",height:"40",style:{flex:"none",lineHeight:1},viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true"},React.createElement("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"#3186FF"}),React.createElement("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-0)"}),React.createElement("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-1)"}),React.createElement("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-2)"}),React.createElement("defs",null,React.createElement("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-0",x1:"7",x2:"11",y1:"15.5",y2:"12"},React.createElement("stop",{stopColor:"#08B962"}),React.createElement("stop",{offset:"1",stopColor:"#08B962",stopOpacity:"0"})),React.createElement("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-1",x1:"8",x2:"11.5",y1:"5.5",y2:"11"},React.createElement("stop",{stopColor:"#F94543"}),React.createElement("stop",{offset:"1",stopColor:"#F94543",stopOpacity:"0"})),React.createElement("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-2",x1:"3.5",x2:"17.5",y1:"13.5",y2:"12"},React.createElement("stop",{stopColor:"#FABC12"}),React.createElement("stop",{offset:".46",stopColor:"#FABC12",stopOpacity:"0"}))));var{store:h0}=Oo(b0);function gf(){try{return JSON.parse(document.getElementById("wp-script-module-data-options-connectors-wp-admin")?.textContent??"{}")}catch{return{}}}function qs(){return gf().connectors??{}}function bf(){return!!gf().isFileModDisabled}var w0={google:ff,openai:cf,anthropic:lf,akismet:uf};function v0(e,t){if(t)return React.createElement("img",{src:t,alt:"",width:40,height:40});let o=w0[e];return React.createElement(o||df,null)}var _0=()=>React.createElement("span",{style:{color:"#345b37",backgroundColor:"#eff8f0",padding:"4px 12px",borderRadius:"2px",fontSize:"13px",fontWeight:"var(--wpds-typography-font-weight-emphasis)",whiteSpace:"nowrap"}},(0,oo.__)("Connected")),y0=({slug:e})=>React.createElement($o,{href:(0,oo.sprintf)((0,oo.__)("https://wordpress.org/plugins/%s/"),e),openInNewTab:!0},(0,oo.__)("Learn more")),x0=()=>React.createElement(zi,null,(0,oo.__)("Not available"));function hf({isConnected:e,showUnavailableBadge:t,pluginSlug:o,isExpanded:n,isBusy:r,pluginStatus:i,actionButtonRef:s,handleButtonClick:a,getButtonLabel:l}){return React.createElement(wr.__experimentalHStack,{spacing:3,expanded:!1},e&&React.createElement(_0,null),t&&(o?React.createElement(y0,{slug:o}):React.createElement(x0,null)),!t&&React.createElement(wr.Button,{ref:s,variant:n||e?"tertiary":"secondary",size:"compact",onClick:a,disabled:i==="checking"||r,isBusy:r,accessibleWhenDisabled:!0},l()))}function wf(e){let t=e?.replace(/\.php$/,"");return t?.includes("/")?t.split("/")[0]:t}function R0({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="api_key"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=wf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:f,isExpanded:p,setIsExpanded:m,isBusy:u,isConnected:g,currentApiKey:v,hasResolvedSettings:_,keySource:w,handleButtonClick:y,getButtonLabel:h,saveApiKey:T,removeApiKey:x}=Xs({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),R=w==="env"||w==="constant",E=c==="not-installed"&&d===!1||c==="inactive"&&f===!1,k=(0,Ks.useRef)(null);return React.createElement(pf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:React.createElement(hf,{isConnected:g,showUnavailableBadge:E,pluginSlug:l,isExpanded:p,isBusy:u,pluginStatus:c,actionButtonRef:k,handleButtonClick:y,getButtonLabel:h})},p&&c==="active"&&_&&React.createElement(m0,{key:g?"connected":"setup",initialValue:R?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":v,helpUrl:a,readOnly:g||R,keySource:w,onRemove:R?void 0:async()=>{await x(),k.current?.focus()},onSave:async C=>{await T(C),m(!1),k.current?.focus()}}))}function S0({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="application_password"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=wf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:f,isExpanded:p,setIsExpanded:m,isBusy:u,isConnected:g,currentUsername:v,hasResolvedSettings:_,keySource:w,handleButtonClick:y,getButtonLabel:h,saveCredentials:T,removeCredentials:x}=Xs({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),R=w==="env"||w==="constant",E=(0,Ks.useRef)(null),k=c==="not-installed"&&d===!1||c==="inactive"&&f===!1;return React.createElement(pf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:React.createElement(hf,{isConnected:g,showUnavailableBadge:k,pluginSlug:l,isExpanded:p,isBusy:u,pluginStatus:c,actionButtonRef:E,handleButtonClick:y,getButtonLabel:h})},p&&c==="active"&&_&&React.createElement(g0,{key:g?"connected":"setup",initialUsername:R?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":v,helpUrl:a,readOnly:g||R,keySource:w,onRemove:R?void 0:async()=>{await x(),E.current?.focus()},onSave:async C=>{await T(C),m(!1),E.current?.focus()}}))}function vf(){let e=qs(),t=o=>o.replace(/[^a-z0-9-_]/gi,"-");for(let[o,n]of Object.entries(e)){if(o==="akismet"&&!n.plugin?.isInstalled)continue;let{authentication:r}=n,i=t(o),s={name:n.name,description:n.description,type:n.type,logo:v0(o,n.logoUrl),authentication:r,plugin:n.plugin},a=Oo((0,mf.select)(h0)).getConnector(i);r.method==="api_key"&&!a?.render?s.render=R0:r.method==="application_password"&&!a?.render&&(s.render=S0),p0(i,s)}}function _f(){return React.createElement("div",{className:"ai-plugin-callout__decoration","aria-hidden":"true"},React.createElement("svg",{viewBox:"0 0 248 248",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",focusable:"false",style:{width:"100%",height:"100%"}},React.createElement("image",{href:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAQAElEQVR4AezdC3ojWW5tYflOzPbIbI/M9sh8+WdrdZ+KpiiKL5FB5KedwN7AeSFIpHRYmfX/PubXVGAqMBV4kQpMw3qRBzXbnApMBT4+pmHNq2AqMBV4mQpMw3qZR3X9RmeGqcCrV2Aa1qs/wdn/VOCNKjAN640e9hx1KvDqFZiG9epPcPY/FThWgZ1q07B2+mDnWFOBPVZgGtYen+qcaSqw0wpMw9rpg51jTQX2WIFpWMee6mhTganAU1ZgGtZTPpbZ1FRgKnCsAtOwjlVltKnAVOApKzAN6ykfy2zqcRWYlV6pAtOwXulpzV6nAm9egWlYb/4CmONPBV6pAtOwXulpve9e//Nw9P/7xL8d7Hy9aQWubFhvWrU59qMr8D+HBcPBna93rcA0rHd98q91bs3q3w9bBv7Bna93rMA0rHd86nPmqcCLVmAa1os+uF/Y9m8u6Q7rvw8bgLnDOhTiXb+mYb3rk3+tc//rYbsaVTjQP18amct4+h9hftt3BaZh7fv57v107rNg7+ec831WYBrWZyHGPHUF/vewu//6xNqg+HMRfyjMrb+edb5pWM/6ZGZfawX86Bc0qTU2/htVYBrWGz3sOepU4NUrMA3r1Z/g7H8q8EYVmIZ1h4c9U04FpgL3qcA0rPvUdWadCkwF7lCBaVh3KOpMORWYCtynAtOw7lPXmfVdKjDnfGgFpmE9tNyz2FRgKnBNBaZhXVO9GTsVmAo8tALTsB5a7llsKjAVuKYCv9uwrtn5jJ0KTAXergLTsN7ukc+BpwKvW4FpWK/77GbnU4G3q8A0rLd75L914Fl3KnB9BaZhXV/DmWEqMBV4UAWmYT2o0LPMVGAqcH0FpmFdX8OZYSowFfhrBe7GpmHdrbQz8VRgKnDrCkzDunVFZ76pwFTgbhWYhnW30s7EU4GpwK0rMA3r1hW9fr6ZYSowFfiiAtOwvijMyFOBqcDzVWAa1vM9k9nRVGAq8EUFpmF9UZiRpwKPqMCs8bMKTMP6Wb0meyowFfjFCkzD+sXiz9JTganAzyowDetn9ZrsqcBU4Bcr8NIN6xfrNktPBaYCv1CBaVi/UPRZciowFbisAtOwLqvbjJoKTAV+oQLTsH6h6LPkBRWYIVOBQwWmYR2KMF9TganAa1RgGtZrPKfZ5VRgKnCowDSsQxHmayowFXimCny9l2lYX9dmIlOBqcCTVWAa1pM9kNnOVGAq8HUFpmF9XZuJTAWmAk9WgWlYT/ZArt/OzDAV2G8FpmHt99nOyaYCu6vANKzdPdK7HOjfDrP+9yf4B/fP138efoeDma+pwP0rMA3r/jXewwqaVFjP8x8HAmIHd74eXIG3W24a1ts98pse+H8Os8HBzNdU4P4VmIZ1/xrvYQU/9v3L4SCwNqh/P2iwagdpvqYC96nANKz71HVmnQpMBe5QgXduWHco526n9B3W9tJ91fi7Pfwc7HkqMA3reZ7FM+/kXw+bc7EeDvTPV1z8jzC/TQXuWYFpWPes7sw9FZgK3LQC07BuWs7dTva/h5P91ye6YGfT2EP4eb9mZ/uowDSsfTzHe5/CHVXQqKzHbjX6YCpwtwpMw7pbaX808f8dsoN7oQOdr6nAVGBbgWlY24o8hvvEzXcnp1YTl3cq51ExTdRe7GldE6ev2vhTgbtV4KyGdbfV33diDeC7T9bE5T1LlezFntb94PRVG38qcLcKTMO6W2lPTuy/GPdfiJfED+6G6Lg8/m/Dnuxne7lOe5Y9/naNZv0HVGAa1gOKfMYSGkI4I/1XUp59f79SlFn0sRWYhvXYereaex/3PyunQT9iiePlPMbOKlOBJ67ANKzfeTiakvufVsdDmjgtPnYq8PYVmIb1Oy8B9z7uf06tLi7vVM7EpgJvVYFpWM/xuF1mB3dFz7Gr2cXOK/B6x5uG9RzPzH1VeI4dzS6mAk9YgWlYT/hQZktTganA8QpMwzpel1GnAlOBJ6zANKyLH8oMnApMBR5dgWlYj674rDcVmApcXIFpWBeXbgZOBaYCj67ANKxHV3zWe8UKzJ6fpALTsJ7kQcw2pgJTge8rMA3r+xpNxlRgKvAkFZiG9SQPYrYxFZgKfF+BRzSs73cxGVOBqcBU4IwKTMM6o0iTMhWYCjxHBaZhPcdzmF1MBaYCZ1RgGtYZRXrSFP9Wln/gD/htEwd/mTqNT4Nyj2ny+7/3sDgYh4NxNBYHcdrH4Tc8HOifL/E044hsmjgN0tj2Ko6DcfLE8EADcfmAg1w64IMXrcA0rNd5cN6Y3njrjnE4pvkHANP58iCNxQO+B3x11v84HA6c9+DO1ytWYBrW6zw1/6Df/FtZlz8vtYPLZ5iRv16BaVi//gjO3sD2zYb7F0mB30Q4aHBpfBqU68cjHPjl4iHNPy5oDljH4yBeLh7SxNN+Mr7cY+PFmpNtLf52/2suv9yx11TgF8ZOw/qFor/gkt7kKzrCJZox9xzf3GN3WIFpWK/xUN27hHbsuyIXyyBGZ/FAgzgrh7aO59PE5AQaiKfJ2WriNCiPPZabxsqBa8ebw9rAD9agmX+r0QcvVoFpWK/xwLzxvOFcGq87pof0OHtKE5MDLqpxwAMO4mksDfggjgMecBBPY2lsEKdBGouDOB5oEGdx4Ac8pLFpY1+sAtOwfuuBXb+uN/H1s9x2hm0zWH/8u+1KM9tbVmAa1ms8dj/SuEh2odyOXUSHtTGksadyjZETjuWm/e/BKc+4A/1g09iPw69j2kH+OHe8XHMF89GOjaeXx+LAD41nt5rcwYtVYBrWiz2wZbvehBoZ8IVYPNAgzuKw5vK32prLD8dy08xRHosDP5TLbrVtLg7lscbRWDzQIM7isObyaYMXrMA0rBd8aN9s2Y9lodQ4m/ZK1r7Duu80Np0f0n7ZzvK3qsA0rFtV8vHzeFP6r9+Bbwesy/lAgzgrh8YaC+t3I3SclRdoEGflbDU6TYwfaBBn5Ww1fN2nPB820ECcZiweaLDmyqGBcSunDV6sAtOwXuyBPWC73tTe9NulaNuLfhqsuY1nV13eOeONMRb4t4Q93HK+mevBFZiG9eCC33i5ay+S3efAui3fibjc3+o06625OH3VjKOZZ9V9aCB/1XC5q2YczTyrfq7vgt5YWMc076qN/2IVeIGG9WIVfdx2vSG9CaFVaRpDSI+zcuisxgDrHMXYFfLhO018m0eDrY6D2AoapNmjvUN7FcdDueLyQU762B1UYBrWDh7iHGEq8C4VmIa1vyfdJbTvNDqdi/Ww3g3JgfKe1TpT+2+/zpHGtne6HEgbu5MKTMPayYNcjuENC9sL7iXl765LaPi78MvOLZZ3dmc65/y3WG/meGAFpmE9sNhPuJQ7HhffT7i1i7fkTODy/eJJZuBzVmAa1nM+l2t21SW0S+fm4Qdv5lV/hR+dNNXt/p0jje1M6a9wrvY89swKTMM6s1AvnuZNHF7xKO092xnibNrYF6nAJduchnVJ1Z57jO8sQjt1aR3c8aS/inWe7f6dI43tLPSQNnYnFZiGtZMHuRzDhTOsl869gdkl9cOna7Bqz+g7i72H9hhnV00DU4O0sTupwDSsnTzIOcZU4B0qMA3rRZ/yiW27gAYX1aXxw3rf0wV9ec9qfeJ3bP9pbHv346NzqUHa2J1UYBrWTh7kcgwNKSR7E4e0V7LtnXU2e2fxQBvsvALTsHb+gD+P544nfEovZdo7u24cD6s+/k4rMA1rfw/WJTq4eO50/OANvtXjz2pdoLd/31HZp3OksTQQx1n89TEn+HsFpmH9vRRv6XjTw94O70w+Wdzbud7+PNOw9vcScLcDLqq/O52Lafgu75Xizu5M60X8K+1/9nqiAtOwThTnRUPerLD+SORTs+AN3dH4EH9W6zztv3PZdxrb3ukhbexOKrD/hrWTBzXHmApMBT4+pmHt71Xgwhn6TsQJXcIH9zs04AP/meE87b9z2Xca2/7pciBt7E4qMA1rJw9yOYY3LJxz6awRwDL85V1n96niOed/+cO+2wGmYb3bE//reXd21/PncJ3pnA8d/gyY316nAtOwXudZnbvTfzkkgovqg/vnix+8of+Ih9/SDu5Tf/nEr722fzaN7QDp8yNhFdmRnYa1o4d54ijexOFE2tOG2nu2jcbZtLE7rsA0rP09XN9ZhE7nniq440l/Fes82/07Rxr7KmeZfV5RgaVhXTHLDH2mCrhwhvXS2Zs7rHutEazaM/rO0v7Z9sgPac7kU8NpYlVkR3Ya1o4e5hzlLxWYS/e/lGMfZBrWPp7jeoouqNl0fljve3w3sl5Yl/9sVvM5tv80tj07kw8d2LSxO6nANKydPMjlGN6omhIk0wLt1dDe2c7F4uHVzjT7vaAC07AuKNoLDumeh33B7X/Yd/hYfqWxizzuXiswDWt/T9aFM6yXzvywvrnTnr0KPkRor76jsl/nSGNpII6z+GBHFZiGtaOHecFRvOnhgqFPPcSZfLL41Jt81Ob2tM40rD09zb+dxd0OuKj+m/L17y7c4euM14v4zsqZ1ov41zvF7PhoBaZhHS3LS4verOCN20F8ahY0s3Q+xJ/VOk/771z2ncauexeDVRt/BxWYhrWDhzhHmAq8SwWmYX3zpF8w7MIZ+k7EEVzCB/c7NOAD/5nhPO2/c9l3Gtv+6XIgbexOKjANaycPcjmGNyycc+msEcAy/OVdZ/ep4jnnf/nDvtsBpmG92xP/63nd88Bf1ddmzgPnfOjw2id9w91Pw9rfQ3cBDS6qOx0/eDNv9fizWp/4bffvHGlse0//+Y+EzTD2aSswDetpH81NN+ZNHG468YMma+/Zlo2zaWN3XIFpWPt7uL6zCJ0uzrrjSX+Utaa1gW9dFg+0r7Dm8strLJs2dscVmIa1v4frwhnWS2c8rCf26Rqs2j381mZrOCwO617pPghg24uckM6mseVqXs5kjrSxO6nA7RrWTgoyx3iaCmhIT7OZ2chzVGAa1nM8h1vuwgV1aN44u973uJyH8u5lfWJnbWh9Fg+tTXeJ7jultGPjxRrL4mCcM5kDH+yoAtOwdvQwP4/iDQve+J/SBx4+fuFXa7Pti8WBf2pbckK5bBp7avzEdlKBaVg7eZDfHMOPV+Gb1HPCP85pbbbB/BXpx+xXeV/px+YYbQcVmIa1g4e4OYILZ1gvnfnBm7wh8mDVil1jfcezzulSvPXFzC2eJk4DcTqLgzgN0tfxdHkgjrP4YEcVmIa1o4f5w6N4w/9wyFnp5tVgzkr+Iskc6yeHX6R9KV87/suJJ/C7FZiG9bv1v8fq7nbARfWp+eW4rIZTeT+NmdeFN/vTsfKNsyfAf4prx/90vb3nP9X5pmE91eO4yWY0C1h/JPKpWfCGbiE5sGrFrrHb+eyn9a1nbjZNnAbGirE4iJcrRhNPY2lAl8Pigx1VYBrWjh7mHGUqsPcKTMPa3xN24Qy+y+h0LtaD+x06Kwfwe8Ia9gTWtRaLgzjtK8hpoPtu7gAAEABJREFU/+Uan8Y2li4H0sbupALTsO77IH9jdm9YOOfS2uU4yL/3Xq0B6zo4nLPXddwp33zOdMs5T603sQdWYBrWA4s9Sz2kAu6u4LsPHR6ymVnkthWYhnXbej7DbC6gwUV1++EHb2Y6Kw/4tHvBj2fWgdZi29N3nwiKl2ucfbJpLA3SrYkPdlSBaVg7epgnjuJNHE6kPTzUnthTi4uvKPeYVuzhdha8fwWmYd2/xo9ewR0OrN9h8INYe+JD/FmtPR7bfxr7rHuffd2wAtOwbljMJ5nKJ2qwXjq7hA5tUxOQB/z0Z7TtnW2vLB7at+blU0PnShu7kwpMw9rJg5xjTAXeoQJP07DeodgPOqML6tCSx+56aC6rgV/uM1qf+NkjrPvDQ7rvsJxJDdLG7qQC07B28iCXY3jDgjdysjdwWHU+lPes1nnaP98+7TuNpQUxiI/dSQWmYe3kQX5zDPc94ZvUpwy3d3bdIB5WffydVmAa1v4erAtnWC+d+cEb3KlZecCnPQY/X8XFevvvOyx7TmObVRxn08bupALTsHbyIOcYf6mAZrZ+SvqX4JDXrcA0rNd9dl/t3N0NuKj+Kocux8U04HvBXs+1l+dz1TmmYV1Vvqcc7AIa1h+J/JWY4A3dxuXAqhV7Jus87d9+7c2e01ga0OWw+OBXK3Dbxadh3baeM9tUYCpwxwpMw7pjcR8wtbsaaCm+S/SQHmflpL+K9R2Ti3Ro/6zzhM4iJ8hJH7uDCkzDeu2H2Bvz0lNoBHDp+EeO03zCqXXLYU/lTewFKzAN66kf2rebc08D3yZ+kaBZXTP+i2lHngrcpwLTsO5T10fN6jIaWk/zwUN6nJWTzm457dmgsdo7tF8WD+05zspJH7uDCkzD2sFD3BzBmzQUirNpr2btPbT3OHtKKzb2xSswDet1H6A7Gt95AL+T4CFNPKTtwXZOtvPwgzNv9VUr9gx29nBGBaZhnVGkJ03xxvNXVoBvmyweaEC/9oLePM8EZ+qc63/Vnsa2Xw0MB+PSx75YBaZhvdgDm+1OBd65AtOwXvfpu7cJ6ynS2HTfYbiEhrQ9WH+tKHQe515Bx8vj0wYvWIG9NKwXLP3VW/bG04BAQzLhqtFpQQzir26dxbmB33mcO6SJywN++tgXq8A0rBd7YMt23cWERf5IYz/u+Mv8K1rqmFbsEfbY+se0R+xl1rhxBaZh3bigd5rOhfn2r6B4E9LBdw6WXjU67RZo3tYxZ5p1XGbTAA84GNf+jaMBH/iXwFhzs41vbTadxUF+uXScTRv7xBWYhvXED+fJtuZNvX4ad4vtmVMT+dFcS7Lxa7NcQme5144/a5FJul0FpmHdrpb3nMm/beXuBe65zqm5u7Q+lXMqZu+w5vjuZv2nYdbYOb753Fex5+Rvc6x/zfjtfMPvXIFpWHcu8I2m743lzdWUNG924NO9cfFAuwXMaw22+fDWWfeVxq65cmCdo/il1lywjrduKLbulb/ml7Nq4z9pBaZhPemDmW1NBaYCHx8fmyJMw9oU5AmoexXfBbBtpwtrNl2O+x9IK/8aay5Y57CGtcG6YiwO4jTAAw7iacbRrEGHNPq1MJc5oblop9Zfcxsz9gkrMA3r+R6KS2Twhv5ud3JCubg3aPyn1nhvYPanY3+abw245WW+ucwJ3+1HTvgud+JPUIFpWE/wEDZb6IJ9I59N3cnA2QM2ica6YGc3oaFTgd+twDSs363/sdV9d+Rymi2OhxqJ+FYr/285sZ9ZY829jtLAtmvJSRMvP41NE8fB/HQWB3HaLWAuc0LzrXu1Lp2VE2iDJ6/ANKwnf0Cf2/PmCp/SH5PG/hHu9Jv5V7TMJZoxp8YXu9SaP6xzpLHp/JA29okrMA3r+R6O7wZCu4uz7lzS+RC/hbVGaD5rpPHpbBpLA37AYc3lbzX5tHvBmtYAfuvgIU08jZ8+9gkqMA3rdx+CNwS0C74L95AeZ9PkuhwHfvq11hqhueJsa7E4uOg+lntMM47OGgvrePqtz2RO6wB/uz6dBvyAvwjeY5vTsH73OXvzwLFd+FHlmH5P7au93HPNY3PbBxyLjfbGFZiG9bsPvx891l1oVODTwnQ8rFoXxmLp11qX1qG57MUakMYP4sf0NPFy0+Ks+Kr7L9XVJu1aa43OxG8+fkizl2O5xcf+YgWmYf1i8Y8s7c1TE1rfsGmsnIbyIX6tNZd1Q/Ph1gY+XS4OaXQ84CCexqd9NV7s1rCWdYFvfrY9sTSQE/DBE1VgGtafh/FUv/lRKLSxOJt2L2uN0Bpx9pj2lX4q15gV5T7SHlv/mPbIPc1aJyowDetEce4c8qf4uX9dxCV08IZqa3yIX2vN1Tps87mExsG+6WuuOA3kBBzE04yjsWniNDA/ncVvAWtVa745WesEGsRZOTTg33JP5hz8sALTsH5YsCdL9yaCJ9vWVdvxiaEzsVdNdOPBmirceNqZ7icVmIb1k2rdNtcdSrh0Zn/iw6Xjn3GcS291YW+5P3PCpXO6iF/vui6dZ8ZdUYFpWFcU78qh3jzeAFDTofmELLREnJWTfmtrbmuE5rfHtPbKpomXm8amieNgHJ3FQZwGdJzFbwHnMifwzclaO9AgzsqhAR/4g1+qwDSsXyr8LDsVmAr8vALTsH5es0tGuJPxHQM0nu9iF8TpLB5oEGfl0G453lzmNLc1Ag3E0+RsNXEalMfiII7DT8Yfy01jzResA3FWDu3Y+mJygjyIs3Jo63g+bfALFfhpw/qFLe5iSZe1sF4k870hQgeNs6c0MTkBhziLAz/gIc1etppYmjge0uPiW00sTRwP6XHxrSaWJo6H9Dh7ShOTE3CIszjwAx7S7CVt7IMrMA3rwQWf5aYCU4HLKzAN6/La/WSky16XuGzj+tSJ1mUui4dy46wcuh9NcEhj8SAP4qwc2jreXmhicgINxNPk0I6Np5fH4nDp+NY6Nl7MGsE6EGfl0Na9prFygjyIs3Jo63h7oQ1+oQLTsH6h6J9LejOs+JQ/ztU+Dr/OzT2Wdxj+cUz/u/bxj1+rxi/CD+dq8s/NPZZ3yXjzGBdwiLM48AMe0ti0sQ+uwDSsxxTcn9DBXYhV2a1GT2Nx4AfjaOxWo6exOPCDcTQ2jaUBP+Cw5vK3mnwa8AMOxqTxaZDG4sAP5bJbbZuLQ3mscTQWBz4N8IBDnC2XxYM8iLP44M4VmIZ15wJ/Tu/CPXxKH3HWG4LO4oEGcRaHNZe/1dZcfpAHxqR1kbxqYvKAH+TQ2LTG09NYOV9p3uRy4KvxxoKc0JxsGisP+AGHNZe/1eTTgB9wMCbtu73KH9ypAtOw7lTYN53WG/tNj/7ix36R7U/DesyDcu+xwqr+6kkaHtLYn2ryjQs4xFkc+MFeaJDG4iCOAw78IL7VitHFV06Ls+I0wAMO4luNnsbiwA84xFk84OFczV7KdQEf0sbesQLTsO5Y3GVqnziFZD8SpfHp3jxpLA34QQ6NTbv3ePOfWkvcnqA8FgdxHPi0Y/unywlyaMak8WliaSwN+EEOjU271XjzmivggztXYBrWnQv8Ob0flcKn9BHPfnz+irOf0gc/fCy/0thkfjiliZXH4sAPOMSzNIizOPADDvEsDeIsDvyAQzxLgziLAz/gIY39qSbfuIBDnMUHd67ANKxbFPgfc3jh9u8u+ZO3iL/mEeTQXeJuNbE0Vh7wgxya+beaWBorD/hBDm0dby80sfJYGojjIId2bDxdTsDh0vGtdWy8WOuw1gF+kENb95rGlsfKA36QQ1vH2wtNrDyWFsTyx96wAtOwbljMmWoq8FkBDUyT+6RjblWBaVi3quQ/5nFfEv6hjvdOFfC3GrwG3unMDznrNKzbltmLtMtdfrN7AYd0eWn9aSyWxp4ab4wc4Mu9dLy9nBovbh1oLRYHceMBDziIpxlHY9PEaZDGOg9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4P/y8fFhLzSxNJa2Qnzl49+gAtOwblDEmWIqMBV4TAWmYV1XZ5er0Cz+JHZ/Afx0PJQvvtXE0thHjbcXa321vrj9gBy5q8angZyAg3jaT8Yfy01jm5O1DvCDHNqx9cXKY+UBP8ihreP5NLHyWBqI4yCHNrhRBaZhXV5IL0Yvyj41aiY6rH+FAw/liaex6fxwShMrj8WBH3CIs3jAwV62Gj1NHA/pcfGtJpYmjof0uPhWE0sTx0N6nD2lickJOMRZHPgBD2n2stXE0sRxSBt7owo8uGHdaNfPM417ivW/fH6enc1OpgI7rMA0rMsfqmblAtaPAM1C669qsOn8IIeu0W01epq5cUhjG8/iwJcHOPxkvHxjgR9wOLZXa5bHygN+wOHS8db4ajy9dVgc+KHx7Fbb5uJQHmscjcUDDeIsDny1B+NogxtVYBrWjQr5OY0XqAYG/E/5Aw8fn7/ibLksDvzP1A88fHz+Ek/jk9mtRk9jcTiWu2prLj/I+Wo8vTwWB364x3hzWwf4AQdrpvG3mhgN+AEHY9L4W02MBuIBH9ywAtOwLi+mOwovVOCbicUDDeKsHBqLA58GeMAhzpbL4sCXB3jAIc6Wy+JBHsRZHNZc/lZbc/kA8sAYHPhbjU4DfjiWm7bNxaGxbLksDnx5gAcc4my5LB7kQZzFYc3lb7U1V2zwgwpMw/pBsTapLtvD+sJMc/nakDT2mHZs/Fe5jTdGDvDpLB5oEGdxWHPb66qtufwg56vx9PJYHPjhHuPNbR3gBxysmcbfamI04AccjEm7Za3MPfhBBaZh/aBYkzoVmAr8bgWmYV1efxfJ27uKOCve7HhIE99qYmksDvyAQ5zFAx7O1ezlVK74qTnFHz3eeu2JxYEfcIizeMDDudotz9qaL28fdYBpWJdX2l2ET4KAbyYvfhzS6HiQQxNP49PE0lga8IMcGpt27/HmP7WWuD1BeSwO4jjwacf2T5cT5NCMSePTxNJYGvCDHBqbdu/x5j+1lrg9DS6owDSsC4r2OcS9xopP+eMSzZiPz1/88Cl9xNmP5RcekuPsKU1MTsAhzuLAX0GDSzRjjAV+wCHO4sBfQYNztZ/kHpvz0vHmMhb4AR9cUIFpWOcVzZ+K/qt2thEuYWnghUgXx0GcBngoV3yriaWxxgI/yKGta6Wx5bHygB/k0Nbx9kITK4+lgTgOcmjHxtPlBBwuHd9ax8aLtQ5rHeAHObR1r2lseaw84Ac5tHW8vdDEymNpII6DHNqx8fTBDyswDeu8gvlkyIuPPW/ED7Im9a0r4B98fOsC/OTw07DOq5aLVvcg7HkjJmsqcF4Fjv3TNOeNfMOsaVjnPXTf0rtIZRuBe7FBOouDeLl40Pjo4mnG0cTSWBrwgxyaMWl8mlgaSwN+kEMzJs1eaGJpLA3EcTCOxuIgTgM84CCeZhyNTROnQRprPzRxHIyjieGBBnFWDs0YHPg0MTzQIM7KoRmDg73QxPBAA/E042hsmjhtcEEFpmFdUFjYef8AAA5ZSURBVLQZMhW4uAIz8KoKTMP65/K5q4I14gI1FPOn5ilNvDnKY0+NF5MTHjW+vX61vnh7kmNfq8anQXksDuI4/GT8sdw01nzBOhBn5dCOrS8mJ8iDOCuHto7n08TkBBqIp8nZauI0KI/FB99UYBrWPxfIiwd6scngBxxcwKexNOCDOA54wEE8jaUBP+AQZ/GAh59q8htrLziksTiI44EGcXEc0lgcxPFAg7g4DmksDuJ4oEGcxYEf8JDG/lSTbxzYCw54wEE8jaUBH8RxwAM++KYC07C+KdCEpwJTgeepwGs1rMfUrctRl6qt6N84Cuk+MdxqYmnsT8fLNw7Wy1k8WEMeu9XoaSwO/GAcjU1jacAPOFx6VmPh0vH2+NV4evtkceCD+jWepQFfHuABhzhbLosHeRBncfjJWe0xGDv4pgLTsL4p0GfYvUP4lD7irBf0x+EXiwP/IP35wsMf4fBbnC2XxYF/SPvzhYc/wuE38TT+Qfpg09iPz1/88Cl9rLn8j8Mvtjz2IP354gc5RHar0dNYHPjBOBq71ehpLA78YByNTWNpwAdxHPg04G81Og34AQdj0vhbTYwG/HAsN00uP+CDbyowDeuvBXKf0IuNLcoPcujsVqOnsTjwg3E0dqvR01gc+ME4GrvV6GksDvxgHI1NY2nADzisufytJp8G/ICDMWl8GqSxOPBDuexW2+biUB5rHI3FgU8DPOAgnsbfamI04AccjEnjbzUxGvADDsYEfLBUYBrWUoyD64Xir1bAejmKh0Pan684axzRiw+HS8abx9hgToizOKy5/K225vKDPDAmrb2umpg84Ac5NDat8fQ0Fgd+MI72Ta0+5MsDfmg8m8bKA37AYc3lbzX5NOAHHIxJ66yrJiYP+EEOjU1rPD2NxUGuD30AHywVmIa1FONM17fwZ6ZO2gtWQMN4wW2/x5anYf31OWtGweVp0TQ2TRyHNH4QP6aniZebxqaxOPADDnEWD3g4V7OXU7nip+YUf/R467UnFgd+wCHO4gEP52r3Pqv9uMSH9jT2swLTsD4L8Wm8WPrUxo8sn/Kf/z15epp4Gp9+zng5co05NV5MHvBD49k0c8lbNTEa8IMcGpv23XjxU7ni5oTyWBzEceDTjq1PlxPk0IxJ49PE0lga8IMcGpt27/HmP7WWuD1BeSwO9ioH8HfA2WechvXPpfIjQSgaZ49pX+nHco9pl4w3j3EBhziLAz/gIY09V/tJ7rE5f2O8fVg34BBnceAHPKSx52o/yT025zq++Fvbd29Y/hSDXgR8l52wXoTioVzxtF5Y54wv99h4seZkW4sf5NDXtdLY8lh5wA9yaOt4e6GJlcfSQBwHObRj4+lyAg6Xjm+tY+PFWoe1DvCDHNq61zS2PFYeHFtrHS8u79rx5rBuwMH8adagDT4r8M4Ny4vBi2P91OazLGOmAlOBZ6zAOzcsz8PFJvBfFbPv21bAH2S3nXFmu1kF3rlhdbnJVlDf+vdXc9aL0DS2XHEcjKOzOIjTAA+tJ55mnDyxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaZDG2g9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4GAvNDE80EA8zTgamyZOgzQWB3EcjKMNPivwzg3rswRjpgJTgVepwDs3LH96bS83V43fcyyPTRPHoR8jVo1frpxwLDeNLY991Pj2+tX64vYDcuxr1fg0kBNwEE/7yfhjuWlsc7LWAX6QQzu2vlh5rDw4lrtqfHnXjjeHdQMO5k+zBg3o/3lwVu1A3+vrnRuWy3YPP/Tk4+JbTSxNHA/pcfGtJpYmjof0OHtKE5MTcIizOPADHtLsZauJpYnjIT0uvtXE0sTxkB4X32piaeJ4SI+zpzQxOQGHOIvDuhYe5ID4VqOnieMhPS6+1cTSxPGQ7gMioKe9nX3nhvV2D3sOfFYF3rohnFWhX0x654blr1j4hBBcoHoMLB5oEGdxuHS8Nb4aT7dGwCHONp7FgS8P8IBDnC2XxYM8iLM4XHpWY+HS8fb41Xi6PQYc4i6vG8+m8+VBGosDP5TLprHygB9wuPSsxsKx8XSX8OBHQ/wt8VYNa/OEPfjgBSnMbjV6GosDPxhHY7caPY3FgR+Mo7FpLA34AYc1l7/V5NOAH3AwJo2/1cRowA/HctO2uTg0li2XxYEvD/CAQ5wtl8WDPIiL48Df6qsmJg/4AYc1l7/V5NOAH47lpm1zcWgsu+aKvT3epWH5Nj/00HEvCuDTWTzQIM7KobE48LcanQb8cCw3bZuLQ2PZclkc+PIADzjE2XJZPMiDOIvDmsvfamsuP8gDY9L4W02MBvxwLDdtm4tDY9lyWRz48gAPOIin8beaGA34AQdj0vhbTYwG/ICDMWn8rSZGe0u8S8PqUxe2B+0CM6wvjDSXn8dyj2n3GG8fx9ZKs6Yc4NNZPNAgzuKw5nbWVVtz+UHOV+Pp5bE48MM9xpvbOsAPOFgzjb/VxGjgNYIDDsbg8Ey1sre3wrs0rLd6qHPYj4+PKcIuK/AuDauLUbYH6XLTHQGk8YP4MT1NvNy0OCt+TE8TlwdpLB5wiLM48AMe0thzNXs5lStuPjiWJ35MTxM3FtL4QfyYniZebhqbxuLADzjEWTzg4VzNXk7lip+aU/xW45vnbey7NCw/94ceLu6TJODTvdBwSKPjQQ5NPI1PE9tq9DRWDs0YHPg0MTzQIM7KobE43Hu8+a0D/K/Wp8sJOBiTxqcd2z+9PFYOzRgc+DQxPNAgzsqhsTjce7z5rQP8r9anywk4GJPGpx3bP/3t8C4N6+0e7Bx4KrDHChxvWPs7qYtU6E8sJ8T/7+BAOouD+CH85wsPLmCJ4mnG0dg0cRqksafGi8kJxkKclUNb1+LTxOQEGsRZOTRjcGivYniQB+JpxtHYNHEapLE4iONgHI3FQZwGeLAfmniacTSxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaW+Jd2lYXlzQJzxv+bDn0FOBV6/AuzQsdwCwXni++rOb/U8F3q4C79KwtpeYHjTNX3UA33LTWBzEaYAHjY8mnmYcjU0Tp0Eae2q8mJxgLMRZObR1LT5NTE6gQZyVQzPmXz4+PmjtVQwP8kA8zTgamyZOgzQWB3EcjKOxOIjTAA/2QxNPM44mlsbSgB/k0IxJ49PE0lga8IMcmjFp9kITS2NpII6DcTQWB3Ea4AEH8TTjaGyaOO0t8S4N6y0f7hx6KrC3Crxzw/KnlgtMcL/l2a4anwZywrHcNLa8a8ebx9rAD9agmX+riaWx8oAf5NDW8XyaWHksDcRxkLPVxGkgJ+AgnvaT8cdy09jmZK0D/CCHdmx9sfJYecAPcmjreD5NrDyWBuI4yNlq4jSQE3AQT2s8nQ/8t8U7NywX8F4AsL4AcBBPx0OaeBpLZ4M4DdJYHMTxQIM4iwM/4CGN/akm3ziwFxzwgIN4GksDPojjgAccxNNYGvBBHAc84CCextKAH3CIs3jAw081+Y21FxzSWBzE8UCDuDgOaSwO4niggb8WpJHR8Uvw8mPeuWG9/MObA7xVBXxg5N7srQ69Pew7Nyx/TccFJvRCYOmhesVZOXQvIBzSWDzIgzgrh3ZsPF1OwCHONp7FgS8PcHAuHPBQLpvGygN+wOHYXh8x3hpfrU9vnywO/NB4dqttc3EojzWOxuKBBnEWh3vUyrx+VPRM7QV/S7xzw/LgQw8f98IAfjoejmnlsuXxj+Ue08plG88ey01bc/l01jjg0wAPOIin8beaGA344Vhu2jYXh8ay5bI48OUBHnCIs+WyeJAHcRaHNZe/1dZcfpAHxqTxt5oYDfjhWG7aNheHxrJrrtjb450b1rGH735gRTlePEGczp7SxOQBPxhHY7caPY3FgR+Mo7FbjZ7G4sAPxtHYNJYG/IDDmsvfavJpwA84GJPG32piNOCHY7lp21wcGsuWy+LAlwd4wCHOlsviQR7EWRzWXP5WW3P5QR4YE/DBUoFpWEsxDq4XiotNcMl5kP588cMf4fBbnDXuIH2wOLg8/fj8hYdP6SPOGkdn8UCDOIvDmsvfamsuP8gDY9La66qJyQN+kENj0xpPT2Nx4AfjaGzatePNY07gBxzWtfhbTT4N+AEHY9La66qJyQN+kENj0xpPT2NxkOv1B3za4LMC07A+CzFmKjAVeP4KTMP66zNyZxBcnhZNY9PEcUjjB/Fjepp4uWlsGosDP+AQZ/GAh3M1ezmVK35qTvFHj7dee2Jx4Acc4iwe8PAX7UDoB/Pnix/ufVbruMQH/p8NzG9/q8A0rL/Vod+9QHwSA+4W0vEghy6exqeJbTV6GiuHZgwOfJoYHmgQZ+XQWBzuPd781gH+V+vT5QQcjEnj047tn14eK4dmDA58mhgeaBBn5dBYHO493vzWAf5X69PlBBzs1TjAB0sFpmEtxRh3KjAVeO4KTMN67ufzTLv7yQXwT3Kf6YyzlyevwF0a1pOfebZ3ugKajX8sbpvlkyyxVceP/ejiE641b/ypwE0qMA3rJmXc1STuUPxTJttDuWsRW3X8WMM6Nn4dN/5U4KIKTMO6qGwzaCowFfiNCkzD+o2q72nNOctU4IEVmIb1wGLPUlOBqcB1FZiGdV39ZvRUYCrwwApMw3pgsWepqcBrV+D3dz8N6/efwexgKjAVOLMC07DOLNSkTQWmAr9fgWlYv/8MZgdTganAmRWYhnVmoa5PmxmmAlOBayswDevaCs74qcBU4GEVmIb1sFLPQlOBqcC1FZiGdW0FZ/xU4J8rMMqdKjAN606FnWmnAlOB21dgGtbtazozTgWmAneqwDSsOxV2pp0KTAVuX4H/DwAA//9sB2hHAAAABklEQVQDAB9QlitZA9bLAAAAAElFTkSuQmCC",width:"248",height:"248",style:{mixBlendMode:"multiply"}})))}var E0="ai",T0="ai-wp-admin",Zs="ai/ai",k0="https://wordpress.org/plugins/ai/",Js=Object.values(qs()),P0=Js.some(e=>e.type==="ai_provider"),Rf=[];for(let e of Js)e.type==="ai_provider"&&e.authentication.method==="api_key"&&Rf.push(e.authentication.settingName);function Sf(){let[e,t]=(0,vt.useState)(!1),[o,n]=(0,vt.useState)(!1),r=(0,vt.useRef)(null);(0,vt.useEffect)(()=>{o&&r.current?.focus()},[o]);let i=(0,vt.useRef)(Js.some(T=>T.type==="ai_provider"&&T.authentication.method==="api_key"&&T.authentication.isConnected)).current,{pluginStatus:s,canInstallPlugins:a,canManagePlugins:l,hasConnectedProvider:c}=(0,cn.useSelect)(T=>{let x=T(Qs.store),R=!!x.canUser("create",{kind:"root",name:"plugin"}),E=x.getEntityRecord("root","site"),k=i||Rf.some(O=>!!E?.[O]),C=x.getEntityRecord("root","plugin",Zs);return x.hasFinishedResolution("getEntityRecord",["root","plugin",Zs])?C?{pluginStatus:C.status==="active"?"active":"inactive",canInstallPlugins:R,canManagePlugins:!0,hasConnectedProvider:k}:{pluginStatus:"not-installed",canInstallPlugins:R,canManagePlugins:R,hasConnectedProvider:k}:{pluginStatus:"checking",canInstallPlugins:R,canManagePlugins:void 0,hasConnectedProvider:k}},[]),{saveEntityRecord:d}=(0,cn.useDispatch)(Qs.store),{createSuccessNotice:f,createErrorNotice:p}=(0,cn.useDispatch)(yf.store),m=async()=>{t(!0);try{await d("root","plugin",{slug:E0,status:"active"},{throwOnError:!0}),n(!0),f((0,Ge.__)("AI plugin installed and activated successfully."),{id:"ai-plugin-install-success",type:"snackbar"})}catch{p((0,Ge.__)("Failed to install the AI plugin."),{id:"ai-plugin-install-error",type:"snackbar"})}finally{t(!1)}},u=async()=>{t(!0);try{await d("root","plugin",{plugin:Zs,status:"active"},{throwOnError:!0}),n(!0),f((0,Ge.__)("AI plugin activated successfully."),{id:"ai-plugin-activate-success",type:"snackbar"})}catch{p((0,Ge.__)("Failed to activate the AI plugin."),{id:"ai-plugin-activate-error",type:"snackbar"})}finally{t(!1)}};if(!P0||s==="checking"||s==="active"&&i&&!o||s==="inactive"&&l===!1)return null;let g=s==="active"&&!c,v=s==="active"&&c&&(!i||o),_=s==="not-installed"||s==="inactive",w=s==="not-installed"&&a===!1,y=()=>v?(0,Ge.__)("The AI plugin is ready to use. You can use it to generate featured images, alt text, titles, excerpts and more. Learn more"):g?(0,Ge.__)("The AI plugin is installed. Connect an AI provider below to generate featured images, alt text, titles, excerpts, and more. Learn more"):(0,Ge.__)("The AI plugin can use your AI connectors to generate featured images, alt text, titles, excerpts and more. Learn more"),h=()=>s==="not-installed"?{label:e?(0,Ge.__)("Installing\u2026"):(0,Ge.__)("Install the AI plugin"),disabled:e,onClick:e?void 0:m}:{label:e?(0,Ge.__)("Activating\u2026"):(0,Ge.__)("Activate the AI plugin"),disabled:e,onClick:e?void 0:u};return React.createElement("div",{className:"ai-plugin-callout"},React.createElement("div",{className:"ai-plugin-callout__content"},React.createElement("p",null,(0,vt.createInterpolateElement)(y(),{strong:React.createElement("strong",null),a:React.createElement(an.ExternalLink,{href:k0})})),!w&&(_?React.createElement(an.Button,{variant:"primary",size:"compact",isBusy:e,disabled:h().disabled,accessibleWhenDisabled:!0,onClick:h().onClick},h().label):React.createElement(an.Button,{ref:r,variant:"secondary",size:"compact",href:(0,xf.addQueryArgs)("options-general.php",{page:T0})},(0,Ge.__)("Control features in the AI plugin")))),React.createElement(_f,null))}var{store:A0}=Oo(C0);vf();function O0(){let e=bf(),{connectors:t,canInstallPlugins:o,isAiPluginInstalled:n}=(0,Ef.useSelect)(c=>{let d=c(kf.store),f=d.getEntityRecord("root","plugin","ai/ai");return{connectors:Oo(c(A0)).getConnectors(),canInstallPlugins:d.canUser("create",{kind:"root",name:"plugin"}),isAiPluginInstalled:!!f}},[]),r=t.filter(c=>c.render),i=Array.from(new Set(t.filter(c=>c.type==="ai_provider").map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c))).sort(),s=new Set(t.filter(c=>c.plugin?.isInstalled).map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c));n&&s.add("ai");let a=["ai",...i].filter(c=>!s.has(c)),l=r.length===0;return React.createElement(Ys,{title:(0,kt.__)("Connectors"),subTitle:(0,kt.__)("All of your API keys and credentials are stored here and shared across plugins. Configure once and use everywhere.")},React.createElement("div",{className:`connectors-page${l?" connectors-page--empty":""}`},a.length>0&&(e||!o)&&React.createElement(en.Root,{intent:"info",className:"connectors-page__file-mods-notice"},React.createElement(en.Description,null,e?(0,kt.__)("Plugins cannot be installed here due to your site configuration. Install them manually using your normal deployment workflow."):(0,kt.__)("You do not have permission to install plugins. Please ask a site administrator to install them for you."))),l?React.createElement(at.__experimentalVStack,{alignment:"center",spacing:3,style:{maxWidth:480}},React.createElement(at.__experimentalVStack,{alignment:"center",spacing:2},React.createElement(at.__experimentalHeading,{level:2,size:15},(0,kt.__)("No connectors yet")),React.createElement(at.__experimentalText,{size:12},(0,kt.__)("Connectors appear here when you install plugins that use external services. Each plugin registers the API keys it needs, and you manage them all in one place."))),React.createElement(at.Button,{variant:"secondary",href:"plugin-install.php",__next40pxDefaultSize:!0},(0,kt.__)("Learn more"))):React.createElement(at.__experimentalVStack,{spacing:3},React.createElement(Sf,null),React.createElement(at.__experimentalVStack,{spacing:3,role:"list"},t.map(c=>c.render?React.createElement(c.render,{key:c.slug,slug:c.slug,name:c.name,description:c.description,type:c.type,logo:c.logo,authentication:c.authentication,plugin:c.plugin}):null))),o&&!e&&React.createElement("p",null,(0,Tf.createInterpolateElement)((0,kt.__)("If the connector you need is not listed, search the plugin directory to see if a connector is available."),{a:React.createElement("a",{href:"plugin-install.php?s=connector&tab=search&type=tag"})}))))}function N0(){return React.createElement(O0,null)}var L0=N0;export{L0 as stage}; +var Zf=Object.create;var Ir=Object.defineProperty;var Qf=Object.getOwnPropertyDescriptor;var Jf=Object.getOwnPropertyNames;var $f=Object.getPrototypeOf,ep=Object.prototype.hasOwnProperty;var Te=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Mt=(e,t)=>{for(var o in t)Ir(e,o,{get:t[o],enumerable:!0})},tp=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Jf(t))!ep.call(e,r)&&r!==o&&Ir(e,r,{get:()=>t[r],enumerable:!(n=Qf(t,r))||n.enumerable});return e};var b=(e,t,o)=>(o=e!=null?Zf($f(e)):{},tp(t||!e||!e.__esModule?Ir(o,"default",{value:e,enumerable:!0}):o,e));var st=Te(($h,da)=>{da.exports=window.wp.i18n});var ce=Te((t0,fa)=>{fa.exports=window.wp.element});var z=Te((o0,pa)=>{pa.exports=window.React});var W=Te((l0,ha)=>{ha.exports=window.ReactJSXRuntime});var Ht=Te((bw,Ua)=>{Ua.exports=window.ReactDOM});var Gc=Te(Uc=>{"use strict";var xo=z();function ng(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var rg=typeof Object.is=="function"?Object.is:ng,ig=xo.useState,sg=xo.useEffect,ag=xo.useLayoutEffect,cg=xo.useDebugValue;function lg(e,t){var o=t(),n=ig({inst:{value:o,getSnapshot:t}}),r=n[0].inst,i=n[1];return ag(function(){r.value=o,r.getSnapshot=t,bi(r)&&i({inst:r})},[e,o,t]),sg(function(){return bi(r)&&i({inst:r}),e(function(){bi(r)&&i({inst:r})})},[e]),cg(o),o}function bi(e){var t=e.getSnapshot;e=e.value;try{var o=t();return!rg(e,o)}catch{return!0}}function dg(e,t){return t()}var ug=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?dg:lg;Uc.useSyncExternalStore=xo.useSyncExternalStore!==void 0?xo.useSyncExternalStore:ug});var Un=Te((av,Kc)=>{"use strict";Kc.exports=Gc()});var qc=Te(Xc=>{"use strict";var Gn=z(),fg=Un();function pg(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var mg=typeof Object.is=="function"?Object.is:pg,gg=fg.useSyncExternalStore,bg=Gn.useRef,hg=Gn.useEffect,wg=Gn.useMemo,vg=Gn.useDebugValue;Xc.useSyncExternalStoreWithSelector=function(e,t,o,n,r){var i=bg(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=wg(function(){function l(f){if(!c){if(c=!0,d=f,f=n(f),r!==void 0&&s.hasValue){var p=s.value;if(r(p,f))return m=p}return m=f}if(p=m,mg(d,f))return p;var g=n(f);return r!==void 0&&r(p,g)?(d=f,p):(d=f,m=g)}var c=!1,d,m,u=o===void 0?null:o;return[function(){return l(t())},u===null?void 0:function(){return l(u())}]},[t,o,n,r]);var a=gg(e,i[0],i[1]);return hg(function(){s.hasValue=!0,s.value=a},[a]),vg(a),a}});var Qc=Te((lv,Zc)=>{"use strict";Zc.exports=qc()});var so=Te((C4,Bd)=>{Bd.exports=window.wp.primitives});var nu=Te((r3,ou)=>{ou.exports=window.wp.theme});var fs=Te((i3,ru)=>{ru.exports=window.wp.privateApis});var rn=Te((U5,lf)=>{lf.exports=window.wp.components});var an=Te((i8,hf)=>{hf.exports=window.wp.data});var Tr=Te((s8,wf)=>{wf.exports=window.wp.coreData});var ea=Te((l8,_f)=>{_f.exports=window.wp.notices});var xf=Te((d8,yf)=>{yf.exports=window.wp.url});function ua(e){var t,o,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;te();function Y(e){let t=ke(ip).current;return t.next=e,rp(t.effect),t.trampoline}function ip(){let e={next:void 0,callback:sp,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function sp(){}var ba=b(z(),1),ap=()=>{},F=typeof document<"u"?ba.useLayoutEffect:ap;function cp(e,t){return function(n,...r){let i=new URL(e);return i.searchParams.set("code",n.toString()),r.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${n}; visit ${i} for the full message.`}}var lp=cp("https://base-ui.com/production-error","Base UI"),De=lp;var qt=b(z(),1);function Mr(e,t,o,n){let r=ke(va).current;return dp(r,e,t,o,n)&&_a(r,[e,t,o,n]),r.callback}function wa(e){let t=ke(va).current;return up(t,e)&&_a(t,e),t.callback}function va(){return{callback:null,cleanup:null,refs:[]}}function dp(e,t,o,n,r){return e.refs[0]!==t||e.refs[1]!==o||e.refs[2]!==n||e.refs[3]!==r}function up(e,t){return e.refs.length!==t.length||e.refs.some((o,n)=>o!==t[n])}function _a(e,t){if(e.refs=t,t.every(o=>o==null)){e.callback=null;return}e.callback=o=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),o!=null){let n=Array(t.length).fill(null);for(let r=0;r{for(let r=0;r=e}function Br(e){if(!xa.isValidElement(e))return null;let t=e,o=t.props;return(po(19)?o?.ref:t.ref)??null}function zo(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function Ge(){}var Sa=Object.freeze([]),me=Object.freeze({});function Ra(e,t){let o={};for(let n in e){let r=e[n];if(t?.hasOwnProperty(n)){let i=t[n](r);i!=null&&Object.assign(o,i);continue}r===!0?o[`data-${n.toLowerCase()}`]="":r&&(o[`data-${n.toLowerCase()}`]=r.toString())}return o}function Ea(e,t){return typeof e=="function"?e(t):e}function Ta(e,t){return typeof e=="function"?e(t):e}var Hr={};function ve(e,t,o,n,r){if(!o&&!n&&!r&&!e)return _n(t);let i=_n(e);return t&&(i=Do(i,t)),o&&(i=Do(i,o)),n&&(i=Do(i,n)),r&&(i=Do(i,r)),i}function ka(e){if(e.length===0)return Hr;if(e.length===1)return _n(e[0]);let t=_n(e[0]);for(let o=1;o=65&&r<=90&&(typeof t=="function"||typeof t>"u")}function zr(e){return typeof e=="function"}function Ca(e,t){return zr(e)?e(t):e??Hr}function gp(e,t){return t?e?(...o)=>{let n=o[0];if(Oa(n)){let i=n;jo(i);let s=t(...o);return i.baseUIHandlerPrevented||e?.(...o),s}let r=t(...o);return e?.(...o),r}:Aa(t):e}function Aa(e){return e&&((...t)=>{let o=t[0];return Oa(o)&&jo(o),e(...t)})}function jo(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Dr(e,t){return t?e?t+" "+e:t:e}function Oa(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var jr=b(z(),1);function Oe(e,t,o={}){let n=t.render,r=bp(t,o);if(o.enabled===!1)return null;let i=o.state??me;return vp(e,n,r,i)}function bp(e,t={}){let{className:o,style:n,render:r}=e,{state:i=me,ref:s,props:a,stateAttributesMapping:l,enabled:c=!0}=t,d=c?Ea(o,i):void 0,m=c?Ta(n,i):void 0,u=c?Ra(i,l):me,f=c&&a?hp(a):void 0,p=c?zo(u,f)??{}:me;return typeof document<"u"&&(c?Array.isArray(s)?p.ref=wa([p.ref,Br(r),...s]):p.ref=Mr(p.ref,Br(r),s):Mr(null,null)),c?(d!==void 0&&(p.className=Dr(p.className,d)),m!==void 0&&(p.style=zo(p.style,m)),p):me}function hp(e){return Array.isArray(e)?ka(e):ve(void 0,e)}var wp=Symbol.for("react.lazy");function vp(e,t,o,n){if(t){if(typeof t=="function")return t(o,n);let r=ve(o,t.props);r.ref=o.ref;let i=t;return i?.$$typeof===wp&&(i=qt.Children.toArray(t)[0]),qt.cloneElement(i,r)}if(e&&typeof e=="string")return _p(e,o);throw new Error(De(8))}function _p(e,t){return e==="button"?(0,jr.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,jr.createElement)("img",{alt:"",...t,key:t.key}):qt.createElement(e,t)}var yn=b(z(),1);var Na=0;function yp(e,t="mui"){let[o,n]=yn.useState(e),r=e||o;return yn.useEffect(()=>{o==null&&(Na+=1,n(`${t}-${Na}`))},[o,t]),r}var Ia=Ho.useId;function mo(e,t){if(Ia!==void 0){let o=Ia();return e??(t?`${t}-${o}`:o)}return yp(e,t)}function La(e){return mo(e,"base-ui")}var G={};Mt(G,{cancelOpen:()=>qp,chipRemovePress:()=>Op,clearPress:()=>Ap,closePress:()=>Pp,closeWatcher:()=>Vp,decrementPress:()=>Lp,disabled:()=>Qp,drag:()=>Gp,escapeKey:()=>Fp,focusOut:()=>jp,imperativeAction:()=>em,incrementPress:()=>Ip,initial:()=>$p,inputBlur:()=>Hp,inputChange:()=>Mp,inputClear:()=>Bp,inputPaste:()=>zp,inputPress:()=>Dp,itemPress:()=>kp,keyboard:()=>Yp,linkPress:()=>Cp,listNavigation:()=>Wp,missing:()=>Jp,none:()=>xp,outsidePress:()=>Tp,pointer:()=>Up,scrub:()=>Xp,siblingOpen:()=>Zp,swipe:()=>tm,trackPress:()=>Np,triggerFocus:()=>Ep,triggerHover:()=>Rp,triggerPress:()=>Sp,wheel:()=>Kp,windowResize:()=>om});var xp="none",Sp="trigger-press",Rp="trigger-hover",Ep="trigger-focus",Tp="outside-press",kp="item-press",Pp="close-press",Cp="link-press",Ap="clear-press",Op="chip-remove-press",Np="track-press",Ip="increment-press",Lp="decrement-press",Mp="input-change",Bp="input-clear",Hp="input-blur",zp="input-paste",Dp="input-press",jp="focus-out",Fp="escape-key",Vp="close-watcher",Wp="list-navigation",Yp="keyboard",Up="pointer",Gp="drag",Kp="wheel",Xp="scrub",qp="cancel-open",Zp="sibling-open",Qp="disabled",Jp="missing",$p="initial",em="imperative-action",tm="swipe",om="window-resize";function ee(e,t,o,n){let r=!1,i=!1,s=n??me;return{reason:e,event:t??new Event("base-ui"),cancel(){r=!0},allowPropagation(){i=!0},get isCanceled(){return r},get isPropagationAllowed(){return i},trigger:o,...s}}var Vr=b(z(),1);var Ma=b(z(),1);function go(e){Ma.useEffect(e,Sa)}var xn=null,Y0=globalThis.requestAnimationFrame,Fr=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let o=this.callbacks,n=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,n>0)for(let r=0;r=this.callbacks.length||(this.callbacks[o]=null,this.callbacksCount-=1)}},Sn=new Fr;var gt=class e{static create(){return new e}static request(t){return Sn.request(t)}static cancel(t){return Sn.cancel(t)}currentId=xn;request(t){this.cancel(),this.currentId=Sn.request(()=>{this.currentId=xn,t()})}cancel=()=>{this.currentId!==xn&&(Sn.cancel(this.currentId),this.currentId=xn)};disposeEffect=()=>this.cancel};function bo(){let e=ke(gt.create).current;return go(e.disposeEffect),e}function Ba(e,t=!1,o=!1){let[n,r]=Vr.useState(e&&t?"idle":void 0),[i,s]=Vr.useState(e);return e&&!i&&(s(!0),r("starting")),!e&&i&&n!=="ending"&&!o&&r("ending"),!e&&!i&&n==="ending"&&r(void 0),F(()=>{if(!e&&i&&n!=="ending"&&o){let a=gt.request(()=>{r("ending")});return()=>{gt.cancel(a)}}},[e,i,n,o]),F(()=>{if(!e||t)return;let a=gt.request(()=>{r(void 0)});return()=>{gt.cancel(a)}},[t,e]),F(()=>{if(!e||!t)return;e&&i&&n!=="idle"&&r("starting");let a=gt.request(()=>{r("idle")});return()=>{gt.cancel(a)}},[t,e,i,n]),{mounted:i,setMounted:s,transitionStatus:n}}var Wr=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),nm={"data-starting-style":""},rm={"data-ending-style":""},Ha={transitionStatus(e){return e==="starting"?nm:e==="ending"?rm:null}};var wo=b(z(),1);function Rn(){return typeof window<"u"}function Qt(e){return En(e)?(e.nodeName||"").toLowerCase():"#document"}function fe(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function ht(e){var t;return(t=(En(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function En(e){return Rn()?e instanceof Node||e instanceof fe(e).Node:!1}function U(e){return Rn()?e instanceof Element||e instanceof fe(e).Element:!1}function he(e){return Rn()?e instanceof HTMLElement||e instanceof fe(e).HTMLElement:!1}function ho(e){return!Rn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof fe(e).ShadowRoot}function Fo(e){let{overflow:t,overflowX:o,overflowY:n,display:r}=Le(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+o)&&r!=="inline"&&r!=="contents"}function za(e){return/^(table|td|th)$/.test(Qt(e))}function Vo(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var im=/transform|translate|scale|rotate|perspective|filter/,sm=/paint|layout|strict|content/,Zt=e=>!!e&&e!=="none",Yr;function Tn(e){let t=U(e)?Le(e):e;return Zt(t.transform)||Zt(t.translate)||Zt(t.scale)||Zt(t.rotate)||Zt(t.perspective)||!kn()&&(Zt(t.backdropFilter)||Zt(t.filter))||im.test(t.willChange||"")||sm.test(t.contain||"")}function Da(e){let t=bt(e);for(;he(t)&&!wt(t);){if(Tn(t))return t;if(Vo(t))return null;t=bt(t)}return null}function kn(){return Yr==null&&(Yr=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Yr}function wt(e){return/^(html|body|#document)$/.test(Qt(e))}function Le(e){return fe(e).getComputedStyle(e)}function Wo(e){return U(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function bt(e){if(Qt(e)==="html")return e;let t=e.assignedSlot||e.parentNode||ho(e)&&e.host||ht(e);return ho(t)?t.host:t}function ja(e){let t=bt(e);return wt(t)?(e.ownerDocument||e).body:he(t)&&Fo(t)?t:ja(t)}function Bt(e,t,o){var n;t===void 0&&(t=[]),o===void 0&&(o=!0);let r=ja(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),s=fe(r);if(i){let a=Pn(s);return t.concat(s,s.visualViewport||[],Fo(r)?r:[],a&&o?Bt(a):[])}else return t.concat(r,Bt(r,[],o))}function Pn(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}var Cn=b(z(),1),am=Cn.createContext(void 0);function Fa(e=!1){let t=Cn.useContext(am);if(t===void 0&&!e)throw new Error(De(16));return t}var Va=b(z(),1);function Wa(e){let{focusableWhenDisabled:t,disabled:o,composite:n=!1,tabIndex:r=0,isNativeButton:i}=e,s=n&&t!==!1,a=n&&t===!1;return{props:Va.useMemo(()=>{let c={onKeyDown(d){o&&t&&d.key!=="Tab"&&d.preventDefault()}};return n||(c.tabIndex=r,!i&&o&&(c.tabIndex=t?r:-1)),(i&&(t||s)||!i&&o)&&(c["aria-disabled"]=o),i&&(!t||a)&&(c.disabled=o),c},[n,o,t,s,a,i,r])}}function Pe(e){return e?.ownerDocument||document}function An(e,t,{detail:o=0}={}){e.dispatchEvent(new(fe(e)).PointerEvent("click",{bubbles:!0,cancelable:!0,composed:!0,detail:o,shiftKey:t.shiftKey,ctrlKey:t.ctrlKey,altKey:t.altKey,metaKey:t.metaKey}))}function Ya(e={}){let{disabled:t=!1,focusableWhenDisabled:o,tabIndex:n=0,native:r=!0,composite:i}=e,s=wo.useRef(null),a=Fa(!0),l=i??a!==void 0,{props:c}=Wa({focusableWhenDisabled:o,disabled:t,composite:l,tabIndex:n,isNativeButton:r}),d=wo.useCallback(()=>{let f=s.current;Ur(f)&&l&&t&&c.disabled===void 0&&f.disabled&&(f.disabled=!1)},[t,c.disabled,l]);F(d,[d]);let m=wo.useCallback((f={})=>{let{onClick:p,onMouseDown:g,onKeyUp:h,onKeyDown:y,onPointerDown:_,...v}=f;return ve({onClick(w){if(t){w.preventDefault();return}p?.(w)},onMouseDown(w){t||g?.(w)},onKeyDown(w){if(t||(jo(w),y?.(w),w.baseUIHandlerPrevented))return;let R=w.target===w.currentTarget,x=w.currentTarget,S=Ur(x),E=!r&&cm(x),T=R&&(r?S:!E),P=w.key==="Enter",N=w.key===" ",H=x.getAttribute("role"),j=H?.startsWith("menuitem")||H==="option"||H==="gridcell";if(R&&l&&N){if(w.defaultPrevented&&j)return;w.preventDefault(),(!r||S)&&(w.preventBaseUIHandler(),An(x,w));return}if(!T||r||!N&&!P){R&&E&&N&&w.preventDefault();return}w.defaultPrevented||(w.preventDefault(),P&&(w.preventBaseUIHandler(),An(x,w)))},onKeyUp(w){if(!t){if(jo(w),h?.(w),w.target===w.currentTarget&&r&&l&&Ur(w.currentTarget)&&w.key===" "){w.preventDefault();return}w.baseUIHandlerPrevented||w.target===w.currentTarget&&!r&&!l&&!w.defaultPrevented&&w.key===" "&&(w.preventBaseUIHandler(),An(w.currentTarget,w))}},onPointerDown(w){if(t){w.preventDefault();return}_?.(w)}},r?{type:"button"}:{role:"button"},c,v)},[t,c,l,r]),u=Y(f=>{s.current=f,d()});return{getButtonProps:m,buttonRef:u}}function Ur(e){return he(e)&&e.tagName==="BUTTON"}function cm(e){return he(e)&&e.tagName==="A"&&!!e.href}function oe(e,t,o,n){return e.addEventListener(t,o,n),()=>{e.removeEventListener(t,o,n)}}function je(e){let t=ke(lm,e).current;return t.next=e,F(t.effect),t}function lm(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var Xa=b(z(),1);var Ka=b(Ht(),1);function Ga(e){return e==null?e:"current"in e?e.current:e}function vo(e,t=!1){let o=bo();return Y((n,r=null)=>{o.cancel();let i=Ga(e);if(i==null)return;let s=i,a=()=>{Ka.flushSync(n)};if(typeof s.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){n();return}function l(){Promise.all(s.getAnimations().map(c=>c.finished)).then(()=>{r?.aborted||a()},()=>{if(r?.aborted)return;if(s.getAnimations().some(d=>d.pending||d.playState!=="finished")){l();return}a()})}if(t){let c="data-starting-style";if(!s.hasAttribute(c)){o.request(l);return}let d=new MutationObserver(()=>{s.hasAttribute(c)||(d.disconnect(),l())});d.observe(s,{attributes:!0,attributeFilter:[c]}),r?.addEventListener("abort",()=>d.disconnect(),{once:!0});return}o.request(l)})}function On(e){let{enabled:t=!0,open:o,ref:n,onComplete:r}=e,i=Y(r),s=vo(n,o);Xa.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,o,i,s])}var kt={};Mt(kt,{engine:()=>Zr,env:()=>Jr,os:()=>Xr,screenReader:()=>Qr});var Xr={};Mt(Xr,{android:()=>Qa,apple:()=>Kr,ios:()=>Gr,linux:()=>mm,mac:()=>Ja,windows:()=>pm});function dm(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:um,platform:fm,maxTouchPoints:qa}=dm(),Jt=um.toLowerCase(),$t=fm.toLowerCase();var Gr=/^i(os$|p)/.test($t)||$t==="macintel"&&qa>1,Za="android",Qa=$t===Za||Jt.includes(Za),Ja=!Gr&&$t.startsWith("mac"),pm=$t.startsWith("win"),mm=!Qa&&/^(linux|chrome os)/.test($t),Kr=Ja||Gr;var Zr={};Mt(Zr,{blink:()=>bm,gecko:()=>gm,webkit:()=>qr});var qr=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),gm=!qr&&Jt.includes("firefox"),bm=!qr&&Jt.includes("chrom");var Qr={};Mt(Qr,{voiceOver:()=>hm});var hm=Kr;var Jr={};Mt(Jr,{jsdom:()=>wm});var wm=/jsdom|happydom/.test(Jt);var Yo=0,Ke=class e{static create(){return new e}currentId=Yo;start(t,o){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Yo,o()},t)}isStarted(){return this.currentId!==Yo}clear=()=>{this.currentId!==Yo&&(clearTimeout(this.currentId),this.currentId=Yo)};disposeEffect=()=>this.clear};function at(){let e=ke(Ke.create).current;return go(e.disposeEffect),e}var Be=b(z(),1);function $a(e){return"nativeEvent"in e}function Pt(e,t){let o=["mouse","pen"];return t||o.push("",void 0),o.includes(e)}function ec(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var $r="data-base-ui-focusable";var ei="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Nn(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function re(e,t){if(!e||!t)return!1;let o=t.getRootNode?.();if(e.contains(t))return!0;if(o&&ho(o)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function Me(e){return"composedPath"in e?e.composedPath()[0]:e.target}function zt(e,t){if(!U(e))return!1;let o=e;if(t.hasElement(o))return!o.hasAttribute("data-trigger-disabled");for(let[,n]of t.entries())if(re(n,o))return!n.hasAttribute("data-trigger-disabled");return!1}function In(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let o=e;return o.target!=null&&t.contains(o.target)}function tc(e){return e.matches("html,body")}function oc(e){return he(e)&&e.matches(ei)}function ti(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${ei}`)!=null}function nc(e){if(!e||kt.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function vm(e,t){return t!=null&&!Pt(t)?0:typeof e=="function"?e():e}function $e(e,t,o){let n=vm(e,o);return typeof n=="number"?n:n?.[t]}function oi(e){return typeof e=="function"?e():e}function Ln(e,t){return t||e==="click"||e==="mousedown"}function rc(e){return e?.includes("mouse")&&e!=="mousedown"}var ic=b(W(),1),sc=Be.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new Ke,currentIdRef:{current:null},currentContextRef:{current:null}});function _m(e,t){e.current=t.current}function ni(e){let{children:t,delay:o,timeoutMs:n=0}=e,r=Be.useRef(o),i=Be.useRef(o),s=Be.useRef(null),a=Be.useRef(null),l=at();return F(()=>{if(i.current=o,!s.current){r.current=o;return}r.current={open:$e(r.current,"open"),close:$e(o,"close")}},[o,s,r,i]),(0,ic.jsx)(sc.Provider,{value:Be.useMemo(()=>({hasProvider:!0,delayRef:r,initialDelayRef:i,currentIdRef:s,timeoutMs:n,currentContextRef:a,timeout:l}),[n,l]),children:t})}function ri(e,t={open:!1}){let{open:o}=t,n="rootStore"in e?e.rootStore:e,r=n.useState("floatingId"),i=Be.useContext(sc),{currentIdRef:s,delayRef:a,timeoutMs:l,initialDelayRef:c,currentContextRef:d,hasProvider:m,timeout:u}=i,[f,p]=Be.useState(!1),g=Be.useRef(o);return F(()=>{g.current=o},[o]),F(()=>{function h(){d.current?.setIsInstantPhase(!1),s.current=null,d.current=null,a.current=c.current,u.clear()}if(s.current&&!o&&s.current===r){if(p(!1),l){let y=r;return u.start(l,()=>{n.select("open")||s.current&&s.current!==y||h()}),()=>{(g.current||s.current!==y)&&u.clear()}}h()}},[o,r,s,a,l,c,d,u,n]),F(()=>{if(!o)return;let h=d.current,y=s.current;u.clear(),d.current={onOpenChange:n.setOpen,setIsInstantPhase:p},s.current=r,a.current={open:0,close:$e(c.current,"close")},y!==null&&y!==r?(p(!0),h?.setIsInstantPhase(!0),h?.onOpenChange(!1,ee(G.none))):(p(!1),h?.setIsInstantPhase(!1))},[o,r,n,s,a,c,d,u]),F(()=>()=>{if(s.current===r){if(d.current=null,!g.current)return;s.current=null,_m(a,c),u.clear()}},[d,s,a,r,c,u]),Be.useMemo(()=>({hasProvider:m,delayRef:a,isInstantPhase:f}),[m,a,f])}function ct(...e){return()=>{for(let t=0;t({x:e,y:e}),ym={left:"right",right:"left",bottom:"top",top:"bottom"};function Bn(e,t,o){return lt(e,Dt(t,o))}function _t(e,t){return typeof e=="function"?e(t):e}function Ne(e){return e.split("-")[0]}function dt(e){return e.split("-")[1]}function Hn(e){return e==="x"?"y":"x"}function Ko(e){return e==="y"?"height":"width"}function Fe(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function Xo(e){return Hn(Fe(e))}function lc(e,t,o){o===void 0&&(o=!1);let n=dt(e),r=Xo(e),i=Ko(r),s=r==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Uo(s)),[s,Uo(s)]}function dc(e){let t=Uo(e);return[Mn(e),t,Mn(t)]}function Mn(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var ac=["left","right"],cc=["right","left"],xm=["top","bottom"],Sm=["bottom","top"];function Rm(e,t,o){switch(e){case"top":case"bottom":return o?t?cc:ac:t?ac:cc;case"left":case"right":return t?xm:Sm;default:return[]}}function uc(e,t,o,n){let r=dt(e),i=Rm(Ne(e),o==="start",n);return r&&(i=i.map(s=>s+"-"+r),t&&(i=i.concat(i.map(Mn)))),i}function Uo(e){let t=Ne(e);return ym[t]+e.slice(t.length)}function Em(e){var t,o,n,r;return{top:(t=e.top)!=null?t:0,right:(o=e.right)!=null?o:0,bottom:(n=e.bottom)!=null?n:0,left:(r=e.left)!=null?r:0}}function zn(e){return typeof e!="number"?Em(e):{top:e,right:e,bottom:e,left:e}}function eo(e){let{x:t,y:o,width:n,height:r}=e;return{width:n,height:r,top:o,left:t,right:t+n,bottom:o+r,x:t,y:o}}function Ct(e,t,o=!0){return e.filter(r=>r.parentId===t).flatMap(r=>[...!o||r.context?.open?[r]:[],...Ct(e,r.id,o)])}function _o(e){return`data-base-ui-${e}`}var He=b(z(),1),mc=b(Ht(),1);var fc={style:{transition:"none"}};var Tm="data-base-ui-swipe-ignore",km="data-swipe-ignore",o1=`[${Tm}]`,n1=`[${km}]`;var pc={fallbackAxisSide:"end"};var gc=b(W(),1),Pm=He.createContext(null),Cm=()=>He.useContext(Pm),Am=_o("portal");function bc(e={}){let{ref:t,container:o,componentProps:n=me,elementProps:r}=e,i=mo(),a=Cm()?.portalNode,[l,c]=He.useState(null),[d,m]=He.useState(null),u=Y(h=>{h!==null&&m(h)}),f=He.useRef(null);F(()=>{if(o===null){f.current&&(f.current=null,m(null),c(null));return}let h=(o&&(En(o)?o:o.current))??a??document.body;if(h==null){f.current&&(f.current=null,m(null),c(null));return}f.current!==h&&(f.current=h,m(null),c(h))},[o,a]);let p=Oe("div",n,{ref:[t,u],props:[{id:i,[Am]:""},r]}),g=l&&p?mc.createPortal(p,l):null;return{node:d,nodeId:He.isValidElement(p)?p.props.id:void 0,subtree:g}}var to=b(z(),1);function hc(){let e=new Map;return{emit(t,o){e.get(t)?.forEach(n=>n(o))},on(t,o){e.has(t)||e.set(t,new Set),e.get(t).add(o)},off(t,o){e.get(t)?.delete(o)}}}var Om=b(W(),1),Nm=to.createContext(null),Im=to.createContext(null),Dn=()=>to.useContext(Nm)?.id||null,Ft=e=>{let t=to.useContext(Im);return e??t};var Ve=b(z(),1);function Lm(e,t){let o=null,n=null,r=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",l=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",c=i.width,d=i.height,m=i.x,u=i.y;return o==null&&t.x&&s&&(o=i.x-t.x),n==null&&t.y&&a&&(n=i.y-t.y),m-=o||0,u-=n||0,c=0,d=0,!r||l?(c=t.axis==="y"?i.width:0,d=t.axis==="x"?i.height:0,m=s&&t.x!=null?t.x:m,u=a&&t.y!=null?t.y:u):r&&!l&&(d=t.axis==="x"?i.height:d,c=t.axis==="y"?i.width:c),r=!0,{width:c,height:d,x:m,y:u,top:u,right:m+c,bottom:u+d,left:m}}}}function wc(e){return e!=null&&e.clientX!=null}function ii(e,t={}){let{enabled:o=!0,axis:n="both"}=t,r="rootStore"in e?e.rootStore:e,i=r.useState("open"),s=r.useState("floatingElement"),a=r.useState("domReferenceElement"),l=r.context.dataRef,c=Ve.useRef(!1),d=Ve.useRef(null),[m,u]=Ve.useState(),[f,p]=Ve.useState([]),g=Y(w=>{r.set("positionReference",w)}),h=Y((w,R,x)=>{c.current||l.current.openEvent&&!wc(l.current.openEvent)||r.set("positionReference",Lm(x??a,{x:w,y:R,axis:n,dataRef:l,pointerType:m}))}),y=Y(w=>{i?d.current||(h(w.clientX,w.clientY,w.currentTarget),p([])):h(w.clientX,w.clientY,w.currentTarget)}),_=Pt(m)?s:i;Ve.useEffect(()=>{if(!o){g(a);return}if(!_)return;function w(){d.current?.(),d.current=null}let R=fe(s);function x(S){let E=Me(S);re(s,E)?w():h(S.clientX,S.clientY)}return!l.current.openEvent||wc(l.current.openEvent)?d.current=oe(R,"mousemove",x):g(a),w},[_,o,s,l,a,r,h,g,f]),Ve.useEffect(()=>()=>{r.set("positionReference",null)},[r]),Ve.useEffect(()=>{o&&!s&&(c.current=!1)},[o,s]),Ve.useEffect(()=>{!o&&i&&(c.current=!0)},[o,i]);let v=Ve.useMemo(()=>{function w(R){u(R.pointerType)}return{onPointerDown:w,onPointerEnter:w,onMouseMove:y,onMouseEnter:y}},[y]);return Ve.useMemo(()=>o?{reference:v,trigger:v}:{},[o,v])}var Xe=b(z(),1);function Mm(){return!1}function Bm(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function si(e,t={}){let{enabled:o=!0,escapeKey:n=!0,outsidePress:r=!0,outsidePressEvent:i="sloppy",referencePress:s=Mm,bubbles:a,externalTree:l}=t,c="rootStore"in e?e.rootStore:e,d=c.useState("open"),m=c.useState("floatingElement"),{dataRef:u}=c.context,f=Ft(l),p=Y(typeof r=="function"?r:()=>!1),g=typeof r=="function"?p:r,h=g!==!1,y=Y(()=>i),{escapeKey:_,outsidePress:v}=Bm(a),w=Xe.useRef(!1),R=Xe.useRef(!1),x=Xe.useRef(!1),S=Xe.useRef(!1),E=Xe.useRef(""),T=Xe.useRef(null),P=at(),N=at(),H=Y(()=>{N.clear(),u.current.insideReactTree=!1}),j=Y(O=>{let V=u.current.floatingContext?.nodeId;return(f?Ct(f.nodesRef.current,V):[]).some(ie=>ie.context?.open&&!ie.context.dataRef.current[O])}),L=Y(O=>In(O,c.select("floatingElement"))||In(O,c.select("domReferenceElement"))),k=Y(O=>{s()&&c.setOpen(!1,ee(G.triggerPress,O.nativeEvent))}),I=Y(O=>{if(!d||!o||!n||O.key!=="Escape"||S.current||!_&&j("__escapeKeyBubbles"))return;let V=$a(O)?O.nativeEvent:O,Z=ee(G.escapeKey,V);c.setOpen(!1,Z),Z.isCanceled||O.preventDefault(),!_&&!Z.isPropagationAllowed&&O.stopPropagation()}),C=Y(()=>{u.current.insideReactTree=!0,N.start(0,H)}),A=Y(O=>{if(!d||!o||O.button!==0)return;let V=Me(O.nativeEvent);re(c.select("floatingElement"),V)&&(w.current||(w.current=!0,R.current=!1))}),M=Y(O=>{!d||!o||(O.defaultPrevented||O.nativeEvent.defaultPrevented)&&w.current&&(R.current=!0)});Xe.useEffect(()=>{if(!d||!o)return H;u.current.__escapeKeyBubbles=_,u.current.__outsidePressBubbles=v;let O=new Ke,V=new Ke;function Z(){O.clear(),S.current=!0}function ie(){O.start(kt.engine.webkit?5:0,()=>{S.current=!1})}function K(){x.current=!0,V.start(0,()=>{x.current=!1})}function Q(){w.current=!1,R.current=!1}function q(){let B=E.current,D=B==="pen"||!B?"mouse":B,Se=y(),Ae=typeof Se=="function"?Se():Se;return typeof Ae=="string"?Ae:Ae[D]}function $(B){let D=q();return D==="intentional"&&B.type!=="click"||D==="sloppy"&&B.type==="click"}function ne(B){let D=u.current.floatingContext?.nodeId,Se=f&&Ct(f.nodesRef.current,D).some(Ae=>In(B,Ae.context?.elements.floating));return L(B)||Se}function se(B){if($(B)){B.type!=="click"&&!L(B)&&(V.clear(),x.current=!1),H();return}if(u.current.insideReactTree){H();return}let D=Me(B),Se=`[${_o("inert")}]`,Ae=U(D)?D.getRootNode():null,Nt=Array.from((ho(Ae)?Ae:Pe(c.select("floatingElement"))).querySelectorAll(Se)),it=c.context.triggerElements;if(D&&(it.hasElement(D)||it.hasMatchingElement(Ye=>re(Ye,D))))return;let It=U(D)?D:null;for(;It&&!wt(It);){let Ye=bt(It);if(wt(Ye)||!U(Ye))break;It=Ye}if(!(Nt.length&&U(D)&&!tc(D)&&!re(D,c.select("floatingElement"))&&Nt.every(Ye=>!re(It,Ye)))){if(he(D)&&!("touches"in B)){let Ye=wt(D),uo=Le(D),Xt=/auto|scroll/,pn=Ye||Xt.test(uo.overflowX),fo=Ye||Xt.test(uo.overflowY),Lt=pn&&D.clientWidth>0&&D.scrollWidth>D.clientWidth,mn=fo&&D.clientHeight>0&&D.scrollHeight>D.clientHeight,gn=uo.direction==="rtl",bn=mn&&(gn?B.offsetX<=D.offsetWidth-D.clientWidth:B.offsetX>D.clientWidth),hn=Lt&&B.offsetY>D.clientHeight;if(bn||hn)return}if(!ne(B)){if(q()==="intentional"&&x.current){V.clear(),x.current=!1;return}typeof g=="function"&&!g(B)||j("__outsidePressBubbles")||(c.setOpen(!1,ee(G.outsidePress,B)),H())}}}function ze(B){q()!=="sloppy"||B.pointerType==="touch"||!c.select("open")||!o||L(B)||se(B)}function ae(B){if(q()!=="sloppy"||!c.select("open")||!o||L(B))return;let D=B.touches[0];D&&(T.current={startTime:Date.now(),startX:D.clientX,startY:D.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},P.start(1e3,()=>{T.current&&(T.current.dismissOnTouchEnd=!1,T.current.dismissOnMouseDown=!1)}))}function ge(B,D){let Se=Me(B);if(!Se)return;let Ae=oe(Se,B.type,()=>{D(B),Ae()})}function be(B){E.current="touch",ge(B,ae)}function Ee(B){P.clear(),B.type==="pointerdown"&&(E.current=B.pointerType),!(B.type==="mousedown"&&T.current&&!T.current.dismissOnMouseDown)&&ge(B,D=>{D.type==="pointerdown"?ze(D):se(D)})}function ye(B){if(!w.current)return;let D=R.current;if(Q(),q()==="intentional"){if(B.type==="pointercancel"){D&&K();return}if(!ne(B)){if(D){K();return}typeof g=="function"&&!g(B)||(V.clear(),x.current=!0,H())}}}function Kt(B){if(q()!=="sloppy"||!T.current||L(B))return;let D=B.touches[0];if(!D)return;let Se=Math.abs(D.clientX-T.current.startX),Ae=Math.abs(D.clientY-T.current.startY),Nt=Math.sqrt(Se*Se+Ae*Ae);Nt>5&&(T.current.dismissOnTouchEnd=!0),Nt>10&&(se(B),P.clear(),T.current=null)}function rt(B){ge(B,Kt)}function ft(B){q()!=="sloppy"||!T.current||L(B)||(T.current.dismissOnTouchEnd&&se(B),P.clear(),T.current=null)}function Ot(B){ge(B,ft)}let xe=Pe(m),fn=ct(n&&ct(oe(xe,"keydown",I),oe(xe,"compositionstart",Z),oe(xe,"compositionend",ie)),h&&ct(oe(xe,"click",Ee,!0),oe(xe,"pointerdown",Ee,!0),oe(xe,"pointerup",ye,!0),oe(xe,"pointercancel",ye,!0),oe(xe,"mousedown",Ee,!0),oe(xe,"mouseup",ye,!0),oe(xe,"touchstart",be,!0),oe(xe,"touchmove",rt,!0),oe(xe,"touchend",Ot,!0)));return()=>{fn(),O.clear(),V.clear(),Q(),x.current=!1,H()}},[u,m,n,h,g,d,o,_,v,I,H,y,j,L,f,c,P]);let X=Xe.useMemo(()=>({onKeyDown:I,onPointerDown:k,onClick:k}),[I,k]),de=Xe.useMemo(()=>({onKeyDown:I,onPointerDown:M,onMouseDown:M,onClickCapture:C,onMouseDownCapture(O){C(),A(O)},onPointerDownCapture(O){C(),A(O)},onMouseUpCapture:C,onTouchEndCapture:C,onTouchMoveCapture:C}),[I,C,A,M]);return Xe.useMemo(()=>o?{reference:X,floating:de,trigger:X}:{},[o,X,de])}var Ie=b(z(),1);function vc(e,t,o){let{reference:n,floating:r}=e,i=Fe(t),s=Xo(t),a=Ko(s),l=Ne(t),c=i==="y",d=n.x+n.width/2-r.width/2,m=n.y+n.height/2-r.height/2,u=n[a]/2-r[a]/2,f;switch(l){case"top":f={x:d,y:n.y-r.height};break;case"bottom":f={x:d,y:n.y+n.height};break;case"right":f={x:n.x+n.width,y:m};break;case"left":f={x:n.x-r.width,y:m};break;default:f={x:n.x,y:n.y}}let p=dt(t);return p&&(f[s]+=u*(p==="end"?1:-1)*(o&&c?-1:1)),f}async function _c(e,t){var o;t===void 0&&(t={});let{x:n,y:r,platform:i,rects:s,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:m="floating",altBoundary:u=!1,padding:f=0}=_t(t,e),p=zn(f),h=a[u?m==="floating"?"reference":"floating":m],y=eo(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(h)))==null||o?h:h.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:d,strategy:l})),_=m==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),w=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},R=eo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:v,strategy:l}):_);return{top:(y.top-R.top+p.top)/w.y,bottom:(R.bottom-y.bottom+p.bottom)/w.y,left:(y.left-R.left+p.left)/w.x,right:(R.right-y.right+p.right)/w.x}}var Hm=50,yc=async(e,t,o)=>{let{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:s}=o,a=s.detectOverflow?s:{...s,detectOverflow:_c},l=await(s.isRTL==null?void 0:s.isRTL(t)),c=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:d,y:m}=vc(c,n,l),u=n,f=0,p={};for(let g=0;gL<=0)){var N,H;let L=(((N=i.flip)==null?void 0:N.index)||0)+1,k=S[L];if(k&&(!(m==="alignment"?_!==Fe(k):!1)||P.every(A=>Fe(A.placement)===_?A.overflows[0]>0:!0)))return{data:{index:L,overflows:P},reset:{placement:k}};let I=(H=P.filter(C=>C.overflows[0]<=0).sort((C,A)=>C.overflows[1]-A.overflows[1])[0])==null?void 0:H.placement;if(!I)switch(f){case"bestFit":{var j;let C=(j=P.filter(A=>{if(x){let M=Fe(A.placement);return M===_||M==="y"}return!0}).map(A=>[A.placement,A.overflows.filter(M=>M>0).reduce((M,X)=>M+X,0)]).sort((A,M)=>A[1]-M[1])[0])==null?void 0:j[0];C&&(I=C);break}case"initialPlacement":I=a;break}if(r!==I)return{reset:{placement:I}}}return{}}}};var Sc=new Set(["left","top"]);async function zm(e,t){let{placement:o,platform:n,elements:r}=e,i=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=Ne(o),a=dt(o),l=Fe(o)==="y",c=Sc.has(s)?-1:1,d=i&&l?-1:1,m=_t(t,e),{mainAxis:u,crossAxis:f,alignmentAxis:p}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return a&&typeof p=="number"&&(f=a==="end"?p*-1:p),l?{x:f*d,y:u*c}:{x:u*c,y:f*d}}var Rc=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var o,n;let{x:r,y:i,placement:s,middlewareData:a}=t,l=await zm(t,e);return s===((o=a.offset)==null?void 0:o.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:i+l.y,data:{...l,placement:s}}}}},Ec=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:o,y:n,placement:r,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:l={fn:_=>{let{x:v,y:w}=_;return{x:v,y:w}}},...c}=_t(e,t),d={x:o,y:n},m=await i.detectOverflow(t,c),u=Fe(r),f=Hn(u),p=d[f],g=d[u],h=(_,v)=>Bn(v+m[_==="y"?"top":"left"],v,v-m[_==="y"?"bottom":"right"]);s&&(p=h(f,p)),a&&(g=h(u,g));let y=l.fn({...t,[f]:p,[u]:g});return{...y,data:{x:y.x-o,y:y.y-n,enabled:{[f]:s,[u]:a}}}}}},Tc=function(e){return e===void 0&&(e={}),{options:e,fn(t){var o,n;let{x:r,y:i,placement:s,rects:a,middlewareData:l}=t,{offset:c=0,mainAxis:d=!0,crossAxis:m=!0}=_t(e,t),u={x:r,y:i},f=Fe(s),p=Hn(f),g=u[p],h=u[f],y=_t(c,t),_=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:(o=y.mainAxis)!=null?o:0,crossAxis:(n=y.crossAxis)!=null?n:0};if(d){let R=p==="y"?"height":"width",x=a.reference[p]-a.floating[R]+_.mainAxis,S=a.reference[p]+a.reference[R]-_.mainAxis;gS&&(g=S)}if(m){var v,w;let R=p==="y"?"width":"height",x=Sc.has(Ne(s)),S=a.reference[f]-a.floating[R]+(x&&((v=l.offset)==null?void 0:v[f])||0)+(x?0:_.crossAxis),E=a.reference[f]+a.reference[R]+(x?0:((w=l.offset)==null?void 0:w[f])||0)-(x?_.crossAxis:0);hE&&(h=E)}return{[p]:g,[f]:h}}}},kc=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:o,rects:n,platform:r,elements:i}=t,{apply:s=()=>{},...a}=_t(e,t),l=await r.detectOverflow(t,a),c=Ne(o),d=dt(o),m=Fe(o)==="y",{width:u,height:f}=n.floating,p,g;c==="top"||c==="bottom"?(p=c,g=d===(await(r.isRTL==null?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(g=c,p=d==="end"?"top":"bottom");let h=f-l.top-l.bottom,y=u-l.left-l.right,_=Dt(f-l[p],h),v=Dt(u-l[g],y),w=t.middlewareData.shift,R=!w,x=_,S=v;w!=null&&w.enabled.x&&(S=y),w!=null&&w.enabled.y&&(x=h),R&&!d&&(m?S=u-2*lt(l.left,l.right):x=f-2*lt(l.top,l.bottom)),await s({...t,availableWidth:S,availableHeight:x});let E=await r.getDimensions(i.floating);return u!==E.width||f!==E.height?{reset:{rects:!0}}:{}}}};function Ac(e){let t=Le(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=he(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n,a=jt(o)!==i||jt(n)!==s;return a&&(o=i,n=s),{width:o,height:n,$:a}}function ci(e){return U(e)?e:e.contextElement}function yo(e){let t=ci(e);if(!he(t))return vt(1);let o=t.getBoundingClientRect(),{width:n,height:r,$:i}=Ac(t),s=(i?jt(o.width):o.width)/n,a=(i?jt(o.height):o.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Dm=vt(0);function Oc(e){let t=fe(e);return!kn()||!t.visualViewport?Dm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function jm(e,t,o){return t===void 0&&(t=!1),!!o&&t&&o===fe(e)}function oo(e,t,o,n){t===void 0&&(t=!1),o===void 0&&(o=!1);let r=e.getBoundingClientRect(),i=ci(e),s=vt(1);t&&(n?U(n)&&(s=yo(n)):s=yo(e));let a=jm(i,o,n)?Oc(i):vt(0),l=(r.left+a.x)/s.x,c=(r.top+a.y)/s.y,d=r.width/s.x,m=r.height/s.y;if(i&&n){let u=fe(i),f=U(n)?fe(n):n,p=u,g=Pn(p);for(;g&&f!==p;){let h=yo(g),y=g.getBoundingClientRect(),_=Le(g),v=y.left+(g.clientLeft+parseFloat(_.paddingLeft))*h.x,w=y.top+(g.clientTop+parseFloat(_.paddingTop))*h.y;l*=h.x,c*=h.y,d*=h.x,m*=h.y,l+=v,c+=w,p=fe(g),g=Pn(p)}}return eo({width:d,height:m,x:l,y:c})}function jn(e,t){let o=Wo(e).scrollLeft;return t?t.left+o:oo(ht(e)).left+o}function Nc(e,t){let o=e.getBoundingClientRect(),n=o.left+t.scrollLeft-jn(e,o),r=o.top+t.scrollTop;return{x:n,y:r}}function Fm(e){let{elements:t,rect:o,offsetParent:n,strategy:r}=e,i=r==="fixed",s=ht(n),a=t?Vo(t.floating):!1;if(n===s||a&&i)return o;let l={scrollLeft:0,scrollTop:0},c=vt(1),d=vt(0),m=he(n);if((m||!i)&&((Qt(n)!=="body"||Fo(s))&&(l=Wo(n)),m)){let f=oo(n);c=yo(n),d.x=f.x+n.clientLeft,d.y=f.y+n.clientTop}let u=s&&!m&&!i?Nc(s,l):vt(0);return{width:o.width*c.x,height:o.height*c.y,x:o.x*c.x-l.scrollLeft*c.x+d.x+u.x,y:o.y*c.y-l.scrollTop*c.y+d.y+u.y}}function Vm(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function Wm(e){let t=Wo(e),o=e.ownerDocument.body,n=lt(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),r=lt(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight),i=-t.scrollLeft+jn(e),s=-t.scrollTop;return Le(o).direction==="rtl"&&(i+=lt(e.clientWidth,o.clientWidth)-n),{width:n,height:r,x:i,y:s}}var Ym=25;function Um(e,t,o){o===void 0&&(o="viewport");let n=o==="layoutViewport",r=fe(e),i=ht(e),s=r.visualViewport,a=i.clientWidth,l=i.clientHeight,c=0,d=0;if(s){let u=!kn()||t==="fixed";n?u||(c=-s.offsetLeft,d=-s.offsetTop):(a=s.width,l=s.height,u&&(c=s.offsetLeft,d=s.offsetTop))}if(jn(i)<=0){let u=i.ownerDocument,f=u.body,p=getComputedStyle(f),g=u.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,h=Math.abs(i.clientWidth-f.clientWidth-g),y=getComputedStyle(i).scrollbarGutter==="stable both-edges"?h/2:h;y<=Ym&&(a-=y)}return{width:a,height:l,x:c,y:d}}function Gm(e,t){let o=oo(e,!0,t==="fixed"),n=o.top+e.clientTop,r=o.left+e.clientLeft,i=yo(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,l=r*i.x,c=n*i.y;return{width:s,height:a,x:l,y:c}}function Pc(e,t,o){let n;if(t==="viewport"||t==="layoutViewport")n=Um(e,o,t);else if(t==="document")n=Wm(ht(e));else if(U(t))n=Gm(t,o);else{let r=Oc(e);n={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return eo(n)}function Km(e,t){let o=t.get(e);if(o)return o;let n=Bt(e,[],!1).filter(a=>U(a)&&Qt(a)!=="body"),r=null,i=Le(e).position==="fixed",s=i?bt(e):e;for(;U(s)&&!wt(s);){let a=Le(s),l=Tn(s),c=r?r.position:i?"fixed":"";!l&&(c==="fixed"||c==="absolute"&&a.position==="static")?n=n.filter(m=>m!==s):r=a,s=bt(s)}return t.set(e,n),n}function Xm(e){let{element:t,boundary:o,rootBoundary:n,strategy:r}=e,s=[...o==="clippingAncestors"?Vo(t)?[]:Km(t,this._c):[].concat(o),n],a=Pc(t,s[0],r),l=a.top,c=a.right,d=a.bottom,m=a.left;for(let u=1;u{a(!1,1e-7)},1e3)}S=!1}try{n=new IntersectionObserver(E,{...x,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,x)}n.observe(e)}let l=fe(e),c=()=>a(o);return l.addEventListener("resize",c),a(!0),()=>{l.removeEventListener("resize",c),s()}}function qo(e,t,o,n){n===void 0&&(n={});let{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=ci(e),d=r||i?[...c?Bt(c):[],...t?Bt(t):[]]:[];d.forEach(y=>{r&&y.addEventListener("scroll",o),i&&y.addEventListener("resize",o)});let m=c&&a?$m(c,o,i):null,u=-1,f=null;s&&(f=new ResizeObserver(y=>{let[_]=y;_&&_.target===c&&f&&t&&(f.unobserve(t),cancelAnimationFrame(u),u=requestAnimationFrame(()=>{var v;(v=f)==null||v.observe(t)})),o()}),c&&!l&&f.observe(c),t&&f.observe(t));let p,g=l?oo(e):null;l&&h();function h(){let y=oo(e);g&&!Lc(g,y)&&o(),g=y,p=requestAnimationFrame(h)}return o(),()=>{var y;d.forEach(_=>{r&&_.removeEventListener("scroll",o),i&&_.removeEventListener("resize",o)}),m?.(),(y=f)==null||y.disconnect(),f=null,l&&cancelAnimationFrame(p)}}var Mc=Rc;var Bc=Ec,Hc=xc,zc=kc;var Dc=Tc,Fn=(e,t,o)=>{let n=new Map,r=o??{},i={...li,...r.platform,_c:n};return yc(e,t,{...r,platform:i})};var we=b(z(),1),Fc=b(z(),1),Vc=b(Ht(),1),tg=typeof document<"u",og=function(){},Vn=tg?Fc.useLayoutEffect:og;function Wn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let o,n,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(o=e.length,o!==t.length)return!1;for(n=o;n--!==0;)if(!Wn(e[n],t[n]))return!1;return!0}if(r=Object.keys(e),o=r.length,o!==Object.keys(t).length)return!1;for(n=o;n--!==0;)if(!{}.hasOwnProperty.call(t,r[n]))return!1;for(n=o;n--!==0;){let i=r[n];if(!(i==="_owner"&&e.$$typeof)&&!Wn(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Wc(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function jc(e,t){let o=Wc(e);return Math.round(t*o)/o}function di(e){let t=we.useRef(e);return Vn(()=>{t.current=e}),t}function Yc(e){e===void 0&&(e={});let{placement:t="bottom",strategy:o="absolute",middleware:n=[],platform:r,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:l,open:c}=e,[d,m]=we.useState({x:0,y:0,strategy:o,placement:t,middlewareData:{},isPositioned:!1}),[u,f]=we.useState(n);Wn(u,n)||f(n);let[p,g]=we.useState(null),[h,y]=we.useState(null),_=we.useCallback(A=>{A!==x.current&&(x.current=A,g(A))},[]),v=we.useCallback(A=>{A!==S.current&&(S.current=A,y(A))},[]),w=i||p,R=s||h,x=we.useRef(null),S=we.useRef(null),E=we.useRef(d),T=l!=null,P=di(l),N=di(r),H=di(c),j=we.useCallback(()=>{if(!x.current||!S.current)return;let A={placement:t,strategy:o,middleware:u};N.current&&(A.platform=N.current),Fn(x.current,S.current,A).then(M=>{let X={...M,isPositioned:H.current!==!1};L.current&&!Wn(E.current,X)&&(E.current=X,Vc.flushSync(()=>{m(X)}))})},[u,t,o,N,H]);Vn(()=>{c===!1&&E.current.isPositioned&&(E.current.isPositioned=!1,m(A=>({...A,isPositioned:!1})))},[c]);let L=we.useRef(!1);Vn(()=>(L.current=!0,()=>{L.current=!1}),[]),Vn(()=>{if(w&&(x.current=w),R&&(S.current=R),w&&R){if(P.current)return P.current(w,R,j);j()}},[w,R,j,P,T]);let k=we.useMemo(()=>({reference:x,floating:S,setReference:_,setFloating:v}),[_,v]),I=we.useMemo(()=>({reference:w,floating:R}),[w,R]),C=we.useMemo(()=>{let A={position:o,left:0,top:0};if(!I.floating)return A;let M=jc(I.floating,d.x),X=jc(I.floating,d.y);return a?{...A,transform:"translate("+M+"px, "+X+"px)",...Wc(I.floating)>=1.5&&{willChange:"transform"}}:{position:o,left:M,top:X}},[o,a,I.floating,d.x,d.y]);return we.useMemo(()=>({...d,update:j,refs:k,elements:I,floatingStyles:C}),[d,j,k,I,C])}var ui=(e,t)=>{let o=Mc(e);return{name:o.name,fn:o.fn,options:[e,t]}},fi=(e,t)=>{let o=Bc(e);return{name:o.name,fn:o.fn,options:[e,t]}},pi=(e,t)=>({fn:Dc(e).fn,options:[e,t]}),mi=(e,t)=>{let o=Hc(e);return{name:o.name,fn:o.fn,options:[e,t]}},gi=(e,t)=>{let o=zc(e);return{name:o.name,fn:o.fn,options:[e,t]}};var Yn=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,o,n=!0){this.fallbackStore=t,this.componentName=o,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let o=this.attachedStores.lastIndexOf(t);o!==-1&&this.attachedStores.splice(o,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(o=>{o()}))}openByTrigger(t){let o=this.attachedStore;if(o===null)return;let n;if(t){for(let r=this.attachedStores.length-1;r>=0&&!n;r-=1)n=this.attachedStores[r].context.triggerElements.getById(t);n??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!n&&this.throwOnMissingTrigger)throw new Error(De(99,this.componentName,t,this.componentName));o.setOpen(!0,ee(G.imperativeAction,void 0,n))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,ee(G.imperativeAction))}};var ro=b(z(),1),sl=b(Ht(),1);var rl=b(z(),1);var ol=b(z(),1),_i=b(Un(),1),nl=b(Qc(),1);var Jc=b(z(),1);var hi=[],wi;function $c(){return wi}function el(e){hi.push(e)}function vi(e){let t=(o,n)=>{let r=ke(_g).current,i;try{wi=r;for(let s of hi)s.before(r);i=e(o,n);for(let s of hi)s.after(r);r.didInitialize=!0}finally{wi=void 0}return i};return t.displayName=e.displayName||e.name,t}function tl(e){return Jc.forwardRef(vi(e))}function _g(){return{didInitialize:!1}}var yg=po(19),xg=yg?Rg:Eg;function Kn(e,t,o,n,r){return xg(e,t,o,n,r)}function Sg(e,t,o,n,r){let i=ol.useCallback(()=>t(e.getSnapshot(),o,n,r),[e,t,o,n,r]);return(0,_i.useSyncExternalStore)(e.subscribe,i,i)}el({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let o=0;o0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let o=new Set;for(let r of e.syncHooks)o.add(r.store);let n=[];for(let r of o)n.push(r.subscribe(t));return()=>{for(let r of n)r()}}),(0,_i.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function Rg(e,t,o,n,r){let i=$c();if(!i)return Sg(e,t,o,n,r);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,o)||!Object.is(a.a2,n)||!Object.is(a.a3,r))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=o,a.a2=n,a.a3=r,a.value=t(e.getSnapshot(),o,n,r))):(a={store:e,selector:t,a1:o,a2:n,a3:r,value:t(e.getSnapshot(),o,n,r)},i.syncHooks.push(a)),a.value}function Eg(e,t,o,n,r){return(0,nl.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,o,n,r))}var Xn=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let o=this.updateTick;for(let n of this.listeners){if(o!==this.updateTick)return;n(t)}}update(t){for(let o in t)if(!Object.is(this.state[o],t[o])){this.setState({...this.state,...t});return}}set(t,o){Object.is(this.state[t],o)||this.setState({...this.state,[t]:o})}notifyAll(){let t={...this.state};this.setState(t)}use(t,o,n,r){return Kn(this,t,o,n,r)}};var no=b(z(),1);var Vt=class extends Xn{constructor(t,o={},n){super(t),this.context=o,this.selectors=n}useSyncedValue(t,o){no.useDebugValue(t);let n=this;F(()=>{n.state[t]!==o&&n.set(t,o)},[n,t,o])}useSyncedValueWithCleanup(t,o){let n=this;F(()=>(n.state[t]!==o&&n.set(t,o),()=>{n.set(t,void 0)}),[n,t,o])}useSyncedValues(t){let o=this,n=Object.values(t);F(()=>{o.update(t)},[o,...n])}useControlledProp(t,o){no.useDebugValue(t);let n=this,r=o!==void 0;F(()=>{r&&!Object.is(n.state[t],o)&&n.setState({...n.state,[t]:o})},[n,t,o,r])}select(t,o,n,r){let i=this.selectors[t];return i(this.state,o,n,r)}useState(t,o,n,r){return no.useDebugValue(t),Kn(this,this.selectors[t],o,n,r)}useContextCallback(t,o){no.useDebugValue(t);let n=Y(o??Ge);this.context[t]=n}useStateSetter(t){let o=no.useRef(void 0);return o.current===void 0&&(o.current=n=>{this.set(t,n)}),o.current}observe(t,o){let n;typeof t=="function"?n=t:n=this.selectors[t];let r=n(this.state);return o(r,r,this),this.subscribe(i=>{let s=n(i);if(!Object.is(r,s)){let a=r;r=s,o(s,a,this)}})}};var Tg={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},Wt=class extends Vt{constructor(t){let{syncOnly:o,nested:n,onOpenChange:r,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:r,dataRef:{current:{}},events:hc(),nested:n,triggerElements:i},Tg),this.syncOnly=o}syncOpenEvent=(t,o)=>{(!t||!this.state.open||o!=null&&ec(o))&&(this.context.dataRef.current.openEvent=t?o:void 0)};dispatchOpenChange=(t,o)=>{this.syncOpenEvent(t,o.event);let n={open:t,reason:o.reason,nativeEvent:o.event,nested:this.context.nested,triggerElement:o.trigger};this.context.events.emit("openchange",n)};setOpen=(t,o)=>{if(this.syncOnly){this.context.onOpenChange?.(t,o);return}this.dispatchOpenChange(t,o),this.context.onOpenChange?.(t,o)}};function il(e){let{popupStore:t,treatPopupAsFloatingElement:o=!1,floatingRootContext:n,floatingId:r,nested:i,onOpenChange:s}=e,a=t.useState("open"),l=t.useState("activeTriggerElement"),c=t.useState(o?"popupElement":"positionerElement"),d=t.context.triggerElements,m=s,u=rl.useRef(null);n===void 0&&u.current===null&&(u.current=new Wt({open:a,transitionStatus:void 0,referenceElement:l,floatingElement:c,triggerElements:d,onOpenChange:m,floatingId:r,syncOnly:!0,nested:i}));let f=n??u.current;return t.useSyncedValue("floatingId",r),F(()=>{let p={open:a,floatingId:r,referenceElement:l,floatingElement:c};U(l)&&(p.domReferenceElement=l),f.state.positionReference===f.state.referenceElement&&(p.positionReference=l),f.update(p)},[a,r,l,c,f]),f.context.onOpenChange=m,f.context.nested=i,f}var al={tabIndex:-1,[$r]:""};function cl(e,t=!1){let o=mo(),n=Dn()!=null,r=ke(()=>e(o,n)).current;return il({popupStore:r,treatPopupAsFloatingElement:t,floatingRootContext:r.state.floatingRootContext,floatingId:o,nested:n,onOpenChange:r.setOpen}),r}function ll({handle:e,store:t}){return F(()=>e.attachStore(t),[e,t]),null}function kg(e,t){let o=ro.useRef(null),n=ro.useRef(null);return ro.useCallback(r=>{if(e===void 0)return;let i=!1;if(o.current!==null){let s=o.current,a=n.current,l=t.context.triggerElements.getById(s);a&&l===a&&(t.context.triggerElements.delete(s),i=!0),o.current=null,n.current=null}if(r!==null&&(o.current=e,n.current=r,t.context.triggerElements.add(e,r),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function Pg(e,t,o,n=!1){t?e.preventUnmountingOnClose=!1:n&&(e.preventUnmountingOnClose=!0);let r=o?.id??null;(r||t)&&(e.activeTriggerId=r,e.activeTriggerElement=o??null)}function Cg(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function dl(e,t,o,n={}){let r=o.reason,i=r===G.triggerHover,s=t&&r===G.triggerFocus,a=!t&&(r===G.triggerPress||r===G.escapeKey),l=Cg(o);if(e.context.onOpenChange?.(t,o),o.isCanceled)return;n.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,o);let c=()=>{let d={...n.extraState,open:t};s?d.instantType="focus":a?d.instantType="dismiss":i&&(d.instantType=void 0),Pg(d,t,o.trigger,l()),e.update(d)};i?sl.flushSync(c):c()}function ul(e,t,o,n){let r=o.useState("isMountedByTrigger",e),i=kg(e,o),s=Y(l=>{let c=o.select("open"),d=o.select("activeTriggerId");if(d===e){o.update({activeTriggerElement:l,...c?n:null});return}d==null&&c&&o.update({activeTriggerId:e,activeTriggerElement:l,...n})}),a=ro.useCallback(l=>{i(l),l&&s(l)},[i,s]);return F(()=>{r&&o.update({activeTriggerElement:t.current,...n})},[r,o,t,...Object.values(n)]),{registerTrigger:a,isMountedByThisTrigger:r}}function fl(e,t={}){let{closeOnActiveTriggerUnmount:o=!1}=t,n=ro.useRef(null),r=e.useState("open"),i=e.useState("triggerCount"),s=e.useState("activeTriggerId"),a=e.useState("activeTriggerElement");F(()=>{if(!r){n.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let l=e.context.triggerElements.size,c={};e.state.triggerCount!==l&&(c.triggerCount=l);let d=e.select("activeTriggerId"),m=null;if(d){let u=e.context.triggerElements.getById(d);if(u)n.current=d,u!==e.state.activeTriggerElement&&(c.activeTriggerElement=u);else{for(let[f,p]of e.context.triggerElements.entries())if(p===e.state.activeTriggerElement){c.activeTriggerId=f,c.activeTriggerElement=p,n.current=f;break}c.activeTriggerId===void 0&&(n.current===d?m=d:n.current=null)}}else n.current=null;if(!m&&!d&&l===1){let u=e.context.triggerElements.entries().next();if(!u.done){let[f,p]=u.value;c.activeTriggerId=f,c.activeTriggerElement=p,n.current=f}}(c.triggerCount!==void 0||c.activeTriggerId!==void 0||c.activeTriggerElement!==void 0)&&e.update(c),m&&o&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===m&&!e.context.triggerElements.getById(m)){let u=ee(G.none);e.setOpen(!1,u),u.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[r,e,i,s,a,o])}function pl(e,t,o){let{mounted:n,setMounted:r,transitionStatus:i}=Ba(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:n,transitionStatus:i,preventUnmountingOnClose:a});let l=Y(()=>{r(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),o?.(),t.context.onOpenChangeComplete?.(!1)});return On({enabled:n&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||l()}}),{forceUnmount:l,transitionStatus:i}}function ml(e,t){e.useSyncedValues(t),F(()=>()=>{e.update({activeTriggerProps:me,inactiveTriggerProps:me,popupProps:me})},[e])}var io=class{constructor(){this.idMap=new Map}add(t,o){this.idMap.set(t,o)}delete(t){this.idMap.delete(t)}hasElement(t){for(let o of this.idMap.values())if(o===t)return!0;return!1}hasMatchingElement(t){for(let o of this.idMap.values())if(t(o))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function gl(){return new Wt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new io,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function hl(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:gl(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:me,inactiveTriggerProps:me,popupProps:me}}function wl(e,t,o=!1){return new Wt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:o,onOpenChange:void 0})}var Zo=e=>e.triggerIdProp??e.activeTriggerId,yi=e=>e.openProp??e.open,bl=e=>(e.popupElement?.id??e.floatingId)||void 0;function vl(e,t){return t!==void 0&&yi(e)&&Zo(e)===t}function Ag(e,t){return vl(e,t)?!0:t!==void 0&&yi(e)&&Zo(e)==null&&e.triggerCount===1}var _l={open:yi,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:Zo,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:bl,isTriggerActive:(e,t)=>t!==void 0&&Zo(e)===t,isOpenedByTrigger:(e,t)=>vl(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&Zo(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>Ag(e,t)?bl(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var xi=b(z(),1),yl=b(Un(),1);function xl(e){let t=xi.useCallback(n=>e===void 0?Ge:e.subscribeStore(n),[e]),o=xi.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,yl.useSyncExternalStore)(t,o,()=>e?.serverStore)}function Sl(e){return Og(e,e.rootContext)}function Og(e,t){let{nodeId:o,externalTree:n}=e,r=t.useState("referenceElement"),i=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),l=t.useState("floatingId"),[c,d]=Ie.useState(null),[m,u]=Ie.useState(void 0),[f,p]=Ie.useState(void 0),g=Ie.useRef(null),h=Ft(n),y=Ie.useMemo(()=>({reference:r,floating:i,domReference:s}),[r,i,s]),_=Yc({...e,elements:{...y,...c&&{reference:c}}}),v=U(m)?m:null,w=f===void 0?t.state.floatingElement:f;t.useSyncedValue("referenceElement",m??null),t.useSyncedValue("domReferenceElement",m===void 0?s:v),t.useSyncedValue("floatingElement",w);let R=Ie.useCallback(N=>{let H=U(N)?{getBoundingClientRect:()=>N.getBoundingClientRect(),getClientRects:()=>N.getClientRects(),contextElement:N}:N;d(H),_.refs.setReference(H)},[_.refs]),x=Ie.useCallback(N=>{(U(N)||N===null)&&(g.current=N,u(N)),(U(_.refs.reference.current)||_.refs.reference.current===null||N!==null&&!U(N))&&_.refs.setReference(N)},[_.refs,u]),S=Ie.useCallback(N=>{p(N),_.refs.setFloating(N)},[_.refs]),E=Ie.useMemo(()=>({..._.refs,setReference:x,setFloating:S,setPositionReference:R,domReference:g}),[_.refs,x,S,R]),T=Ie.useMemo(()=>({..._.elements,domReference:s}),[_.elements,s]),P=Ie.useMemo(()=>({..._,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:l,refs:E,elements:T,nodeId:o,rootStore:t}),[_,E,T,o,t,a,l]);return F(()=>{s&&(g.current=s)},[s]),F(()=>{t.context.dataRef.current.floatingContext=P;let N=h?.nodesRef.current.find(H=>H.id===o);N&&(N.context=P)}),Ie.useMemo(()=>({..._,context:P,refs:E,elements:T,rootStore:t}),[_,E,T,P,t])}var yt=b(z(),1);var Si=kt.os.mac&&kt.engine.webkit;function Ri(e,t={}){let{enabled:o=!0,delay:n}=t,r="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=r.context,a=yt.useRef(!1),l=yt.useRef(null),c=yt.useRef(!0),d=at();yt.useEffect(()=>{let u=r.select("domReferenceElement");if(!o)return;let f=fe(u);function p(){let y=r.select("domReferenceElement");!r.select("open")&&he(y)&&y===Nn(Pe(y))&&(a.current=!0)}function g(){c.current=!0}function h(){c.current=!1}return ct(oe(f,"blur",p),Si&&oe(f,"keydown",g,!0),Si&&oe(f,"pointerdown",h,!0))},[r,o]),yt.useEffect(()=>{if(!o)return;function u(f){if(f.reason===G.triggerPress||f.reason===G.escapeKey){let p=r.select("domReferenceElement");U(p)&&(l.current=p,a.current=!0)}}return i.on("openchange",u),()=>{i.off("openchange",u)}},[i,o,r]);let m=yt.useMemo(()=>{function u(){a.current=!1,l.current=null}return{onMouseLeave(){u()},onFocus(f){let p=f.currentTarget;if(a.current){if(l.current===p)return;u()}let g=Me(f.nativeEvent);if(U(g)){if(Si&&!f.relatedTarget){if(!c.current&&!oc(g))return}else if(!nc(g))return}let h=zt(f.relatedTarget,r.context.triggerElements),{nativeEvent:y,currentTarget:_}=f,v=typeof n=="function"?n():n;if(r.select("open")&&h||v===0||v===void 0){r.setOpen(!0,ee(G.triggerFocus,y,_));return}d.start(v,()=>{a.current||r.setOpen(!0,ee(G.triggerFocus,y,_))})},onBlur(f){u();let p=f.relatedTarget,g=f.nativeEvent,h=U(p)&&p.hasAttribute(_o("focus-guard"))&&p.getAttribute("data-type")==="outside";d.start(0,()=>{let y=r.select("domReferenceElement"),_=Nn(Pe(y));!p&&_===y||re(s.current.floatingContext?.refs.floating.current,_)||re(y,_)||h||zt(p??_,r.context.triggerElements)||r.setOpen(!1,ee(G.triggerFocus,g))})}}},[s,n,r,d]);return yt.useMemo(()=>o?{reference:m,trigger:m}:{},[o,m])}var Ti=b(z(),1);var Ei=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new Ke,this.restTimeout=new Ke,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},qn=new WeakMap;function So(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&qn.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),qn.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function Zn(e,t){let{scopeElement:o,referenceElement:n,floatingElement:r}=t,i=qn.get(o);i&&i!==e&&So(i),So(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=o,e.pointerEventsReferenceElement=n,e.pointerEventsFloatingElement=r,qn.set(o,e),o.style.pointerEvents="none",n.style.pointerEvents="auto",r.style.pointerEvents="auto"}function Ro(e){let t=e.context.dataRef.current,o=ke(()=>t.hoverInteractionState??Ei.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=o),go(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function ki(e,t={}){let{enabled:o=!0,closeDelay:n=0,nodeId:r}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),l=i.useState("domReferenceElement"),{dataRef:c}=i.context,d=Ft(),m=Dn(),u=Ro(i),f=at(),p=Y(()=>Ln(c.current.openEvent?.type,u.interactedInside)),g=Y(()=>rc(c.current.openEvent?.type)),h=Y(()=>{So(u)});F(()=>{s||(u.pointerType=void 0,u.restTimeoutPending=!1,u.interactedInside=!1,h())},[s,u,h]),Ti.useEffect(()=>h,[h]),F(()=>{if(o&&s&&u.handleCloseOptions?.blockPointerEvents&&g()&&U(l)&&a){let y=l,_=a,v=Pe(a),w=d?.nodesRef.current.find(E=>E.id===m)?.context?.elements.floating;w&&(w.style.pointerEvents="");let R=u.pointerEventsScopeElement!==_?u.pointerEventsScopeElement:null,x=w!==_?w:null,S=u.handleCloseOptions?.getScope?.()??R??x??y.closest("[data-rootownerid]")??v.body;return Zn(u,{scopeElement:S,referenceElement:y,floatingElement:_}),()=>{h()}}},[o,s,l,a,u,g,d,m,h]),Ti.useEffect(()=>{if(!o)return;function y(){return!!(d&&m&&Ct(d.nodesRef.current,m).length>0)}function _(E){let T=$e(n,"close",u.pointerType),P=()=>{i.setOpen(!1,ee(G.triggerHover,E)),d?.events.emit("floating.closed",E)};T?u.openChangeTimeout.start(T,P):(u.openChangeTimeout.clear(),P())}function v(E){let T=Me(E);if(!ti(T)){u.interactedInside=!1;return}u.interactedInside=T?.closest("[aria-haspopup]")!=null}function w(){u.openChangeTimeout.clear(),f.clear(),d?.events.off("floating.closed",x),h()}function R(E){if(y()&&d){d.events.on("floating.closed",x);return}if(zt(E.relatedTarget,i.context.triggerElements))return;let T=c.current.floatingContext?.nodeId??r,P=E.relatedTarget;if(!(d&&T&&U(P)&&Ct(d.nodesRef.current,T,!1).some(H=>re(H.context?.elements.floating,P)))){if(u.handler){u.handler(E);return}h(),g()&&!p()&&_(E)}}function x(E){!d||!m||y()||f.start(0,()=>{d.events.off("floating.closed",x),i.setOpen(!1,ee(G.triggerHover,E)),d.events.emit("floating.closed",E)})}let S=a;return ct(S&&oe(S,"mouseenter",w),S&&oe(S,"mouseleave",R),S&&oe(S,"pointerdown",v,!0),()=>{d?.events.off("floating.closed",x)})},[o,a,i,c,n,r,g,p,h,u,d,m,f])}var Yt=b(z(),1),Rl=b(Ht(),1);var Ng={current:null};function Pi(e,t={}){let{enabled:o=!0,delay:n=0,handleClose:r=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:l=Ng,externalTree:c,isActiveTrigger:d=!0,getHandleCloseContext:m,isClosing:u,shouldOpen:f,guardStaleOpen:p=!1}=t,g="rootStore"in e?e.rootStore:e,{dataRef:h,events:y}=g.context,_=Ft(c),v=Ro(g),w=Yt.useRef(!1),R=je(r),x=je(n),S=je(s),E=je(o),T=je(f),P=je(u),N=Y(()=>Ln(h.current.openEvent?.type,v.interactedInside)),H=Y(()=>T.current?.()!==!1),j=Y((I,C,A)=>{let M=g.context.triggerElements;if(M.hasElement(C))return!I||!re(I,C);if(!U(A))return!1;let X=A;return M.hasMatchingElement(de=>re(de,X))&&(!I||!re(I,X))}),L=Y(()=>{if(!v.handler)return;Pe(g.select("domReferenceElement")).removeEventListener("mousemove",v.handler),v.handler=void 0}),k=Y(()=>{So(v)});return d&&(v.handleCloseOptions=R.current?.__options),Yt.useEffect(()=>L,[L]),Yt.useEffect(()=>{if(!o)return;function I(C){C.open?w.current=!1:(w.current=C.reason===G.triggerHover,L(),v.openChangeTimeout.clear(),v.restTimeout.clear(),v.blockMouseMove=!0,v.restTimeoutPending=!1)}return y.on("openchange",I),()=>{y.off("openchange",I)}},[o,y,v,L]),Yt.useEffect(()=>{if(!o)return;function I(O,V=!0){let Z=$e(x.current,"close",v.pointerType);Z?v.openChangeTimeout.start(Z,()=>{g.setOpen(!1,ee(G.triggerHover,O)),_?.events.emit("floating.closed",O)}):V&&(v.openChangeTimeout.clear(),g.setOpen(!1,ee(G.triggerHover,O)),_?.events.emit("floating.closed",O))}let C=l.current??(d?g.select("domReferenceElement"):null);if(!U(C))return;function A(O){if(v.openChangeTimeout.clear(),v.blockMouseMove=!1,i&&!Pt(v.pointerType))return;let V=oi(S.current),Z=$e(x.current,"open",v.pointerType),ie=Me(O),K=O.currentTarget??null,Q=g.select("domReferenceElement"),q=K;if(U(ie)&&!g.context.triggerElements.hasElement(ie)){for(let ye of g.context.triggerElements.elements())if(re(ye,ie)){q=ye;break}}U(K)&&U(Q)&&!g.context.triggerElements.hasElement(K)&&re(K,Q)&&(q=Q);let $=q==null?!1:j(Q,q,ie),ne=g.select("open"),se=P.current?.()??g.select("transitionStatus")==="ending",ze=!ne&&se&&w.current,ae=!$&&U(q)&&U(Q)&&re(Q,q)&&ze,ge=V>0&&!Z,be=$&&(ne||ze)||ae,Ee=!ne||$;if(be){H()&&g.setOpen(!0,ee(G.triggerHover,O,q));return}ge||(Z?v.openChangeTimeout.start(Z,()=>{Ee&&H()&&g.setOpen(!0,ee(G.triggerHover,O,q))}):Ee&&H()&&g.setOpen(!0,ee(G.triggerHover,O,q)))}function M(O){if(N()){k();return}L();let V=g.select("domReferenceElement"),Z=Pe(V);v.restTimeout.clear(),v.restTimeoutPending=!1;let ie=h.current.floatingContext??m?.();if(zt(O.relatedTarget,g.context.triggerElements))return;if(R.current&&ie){g.select("open")||v.openChangeTimeout.clear();let Q=l.current;v.handler=R.current({...ie,tree:_,x:O.clientX,y:O.clientY,onClose(){k(),L(),E.current&&!N()&&Q===g.select("domReferenceElement")&&I(O,!0)}}),Z.addEventListener("mousemove",v.handler),v.handler(O);return}(v.pointerType!=="touch"||!re(g.select("floatingElement"),O.relatedTarget))&&I(O)}function X(O){re(C,O.relatedTarget)||(v.openChangeTimeout.clear(),v.restTimeout.clear(),v.restTimeoutPending=!1)}let de=p?oe(C,"mouseout",X):void 0;return a?ct(oe(C,"mousemove",A,{once:!0}),oe(C,"mouseenter",A),oe(C,"mouseleave",M),de):ct(oe(C,"mouseenter",A),oe(C,"mouseleave",M),de)},[L,k,h,x,g,o,R,v,d,j,N,i,a,S,l,_,E,m,P,H,p]),Yt.useMemo(()=>{if(!o)return;function I(C){v.pointerType=C.pointerType}return{onPointerDown:I,onPointerEnter:I,onMouseMove(C){let{nativeEvent:A}=C,M=C.currentTarget,X=g.select("domReferenceElement"),de=g.select("open"),O=j(X,M,C.target);if(i&&!Pt(v.pointerType))return;if(de&&O&&v.handleCloseOptions?.blockPointerEvents){let ie=g.select("floatingElement");if(ie){let K=v.handleCloseOptions?.getScope?.()??M.ownerDocument.body;Zn(v,{scopeElement:K,referenceElement:M,floatingElement:ie})}}let V=oi(S.current);if(de&&!O||V===0||!O&&v.restTimeoutPending&&C.movementX**2+C.movementY**2<2)return;v.restTimeout.clear();function Z(){if(v.restTimeoutPending=!1,N())return;let ie=g.select("open");!v.blockMouseMove&&(!ie||O)&&H()&&g.setOpen(!0,ee(G.triggerHover,A,M))}v.pointerType==="touch"?Rl.flushSync(()=>{Z()}):O&&de?Z():(v.restTimeoutPending=!0,v.restTimeout.start(V,Z))}}},[o,v,N,j,i,g,S,H])}var El=.1,Ig=El*El,le=.5;function Qn(e,t,o,n,r,i){return n>=t!=i>=t&&e<=(r-o)*(t-n)/(i-n)+o}function Jn(e,t,o,n,r,i,s,a,l,c){let d=!1;return Qn(e,t,o,n,r,i)&&(d=!d),Qn(e,t,r,i,s,a)&&(d=!d),Qn(e,t,s,a,l,c)&&(d=!d),Qn(e,t,l,c,o,n)&&(d=!d),d}function Lg(e,t,o){return e>=o.x&&e<=o.x+o.width&&t>=o.y&&t<=o.y+o.height}function $n(e,t,o,n,r,i){let s=Math.min(o,r),a=Math.max(o,r),l=Math.min(n,i),c=Math.max(n,i);return e>=s&&e<=a&&t>=l&&t<=c}function Ci(e={}){let{blockPointerEvents:t=!1}=e,o=new Ke,n=({x:r,y:i,placement:s,elements:a,onClose:l,nodeId:c,tree:d})=>{let m=s?.split("-")[0],u=!1,f=null,p=null,g=typeof performance<"u"?performance.now():0;function h(_,v){let w=performance.now(),R=w-g;if(f===null||p===null||R===0)return f=_,p=v,g=w,!1;let x=_-f,S=v-p,E=x*x+S*S,T=R*R*Ig;return f=_,p=v,g=w,E0)}function j(){H()||y()}if(H())return;let L=w.getBoundingClientRect(),k=R.getBoundingClientRect(),I=r>k.right-k.width/2,C=i>k.bottom-k.height/2,A=k.width>L.width,M=k.height>L.height,X=(A?L:k).left,de=(A?L:k).right,O=(M?L:k).top,V=(M?L:k).bottom;if(m==="top"&&i>=L.bottom-1||m==="bottom"&&i<=L.top+1||m==="left"&&r>=L.right-1||m==="right"&&r<=L.left+1){j();return}let Z=!1;switch(m){case"top":Z=$n(x,S,X,L.top+1,de,k.bottom-1);break;case"bottom":Z=$n(x,S,X,k.top+1,de,L.bottom-1);break;case"left":Z=$n(x,S,k.right-1,V,L.left+1,O);break;case"right":Z=$n(x,S,L.right-1,V,k.left+1,O);break;default:}if(Z)return;if(u&&!Lg(x,S,L)){j();return}if(!T&&h(x,S)){j();return}let ie=!1;switch(m){case"top":{let K=A?le/2:le*4,Q=A||I?r+K:r-K,q=A?r-K:I?r+K:r-K,$=i+le+1,ne=I||A?k.bottom-le:k.top,se=I?A?k.bottom-le:k.top:k.bottom-le;ie=Jn(x,S,Q,$,q,$,k.left,ne,k.right,se);break}case"bottom":{let K=A?le/2:le*4,Q=A||I?r+K:r-K,q=A?r-K:I?r+K:r-K,$=i-le,ne=I||A?k.top+le:k.bottom,se=I?A?k.top+le:k.bottom:k.top+le;ie=Jn(x,S,Q,$,q,$,k.left,ne,k.right,se);break}case"left":{let K=M?le/2:le*4,Q=M||C?i+K:i-K,q=M?i-K:C?i+K:i-K,$=r+le+1,ne=C||M?k.right-le:k.left,se=C?M?k.right-le:k.left:k.right-le;ie=Jn(x,S,ne,k.top,se,k.bottom,$,Q,$,q);break}case"right":{let K=M?le/2:le*4,Q=M||C?i+K:i-K,q=M?i-K:C?i+K:i-K,$=r-le,ne=C||M?k.left+le:k.right,se=C?M?k.left+le:k.right:k.left+le;ie=Jn(x,S,$,Q,$,q,ne,k.top,se,k.bottom);break}default:}ie?u||o.start(40,j):j()}};return n.__options={...e,blockPointerEvents:t},n}var er=class extends Vt{setState(t){}update(t){}set(t,o){}notifyAll(){}};var hy=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=Wr.startingStyle]="startingStyle",e[e.endingStyle=Wr.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({});var Mg={"data-popup-open":""};var Bg={"data-open":""},Hg={"data-closed":""},zg={"data-anchor-hidden":""},Tl={open(e){return e?Mg:null}};var Qo={open(e){return e?Bg:Hg},anchorHidden(e){return e?zg:null}},kl={...Qo,...Ha};function Pl(e){return po(19)?e:e?"true":void 0}var tr=b(z(),1),Ai=tr.createContext(void 0);function Eo(){return tr.useContext(Ai)?.direction??"ltr"}var qe=b(z(),1);var Dg=e=>({name:"arrow",options:e,async fn(t){let{x:o,y:n,placement:r,rects:i,platform:s,elements:a,middlewareData:l}=t,{element:c,padding:d=0,offsetParent:m="real"}=_t(e,t)||{};if(c==null)return{};let u=zn(d),f={x:o,y:n},p=Xo(r),g=Ko(p),h=await s.getDimensions(c),y=p==="y",_=y?"top":"left",v=y?"bottom":"right",w=y?"clientHeight":"clientWidth",R=i.reference[g]+i.reference[p]-f[p]-i.floating[g],x=f[p]-i.reference[p],S=m==="real"?await s.getOffsetParent?.(c):a.floating,E=a.floating[w]||i.floating[g];(!E||!await s.isElement?.(S))&&(E=a.floating[w]||i.floating[g]);let T=R/2-x/2,P=E/2-h[g]/2-1,N=Math.min(u[_],P),H=Math.min(u[v],P),j=N,L=E-h[g]-H,k=E/2-h[g]/2+T,I=Bn(j,k,L),C=!l.arrow&&dt(r)!=null&&k!==I&&i.reference[g]/2-(k({...Dg(e),options:[e,t]});var Al={name:"hide",async fn(e){let{width:t,height:o,x:n,y:r}=e.rects.reference,i=t===0&&o===0&&n===0&&r===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-o>=0||s.right-t>=0||s.bottom-o>=0||s.left-t>=0||i}}}};var To={sideX:"left",sideY:"top"};var Ol="--available-width",Nl="--available-height";function Ml(e,t,o){let n=e==="inline-start"||e==="inline-end";return{top:"top",right:n?o?"inline-start":"inline-end":"right",bottom:"bottom",left:n?o?"inline-end":"inline-start":"left"}[t]}function Il(e,t,o){let{rects:n,placement:r}=e;return{side:Ml(t,Ne(r),o),align:dt(r)||"center",anchor:{width:n.reference.width,height:n.reference.height},positioner:{width:n.floating.width,height:n.floating.height}}}function Bl(e){return jg(e,Sl)}function jg(e,t){let{anchor:o,positionMethod:n="absolute",side:r="bottom",sideOffset:i=0,align:s="center",alignOffset:a=0,collisionBoundary:l,collisionPadding:c=5,sticky:d=!1,arrowPadding:m=5,disableAnchorTracking:u=!1,inline:f,keepMounted:p=!1,floatingRootContext:g,mounted:h,collisionAvoidance:y,shift:_,nodeId:v,adaptiveOrigin:w,lazyFlip:R=!1,externalTree:x}=e,[S,E]=qe.useState(null);!h&&S!==null&&E(null);let T=y.side||"flip",P=y.align||"flip",N=y.fallbackAxisSide||"end",H=_?.crossAxis??!1,j=_?.rootBoundary,L=typeof o=="function"?o:void 0,k=Y(L),I=L?k:o,C=je(o),A=je(h),X=Eo()==="rtl",de=S||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":X?"left":"right","inline-start":X?"right":"left"}[r],O=s==="center"?de:`${de}-${s}`,V=c;typeof V=="number"?V={top:V,right:V,bottom:V,left:V}:V&&(V={top:V.top||0,right:V.right||0,bottom:V.bottom||0,left:V.left||0});let Z=1,ie=r==="bottom"?Z:0,K=r==="top"?Z:0,Q=r==="right"?Z:0,q=r==="left"?Z:0,$={boundary:l==="clipping-ancestors"?"clippingAncestors":l,padding:V},ne=qe.useRef(null),se=je(i),ze=je(a),ae=typeof i!="function"?i:0,ge=typeof a!="function"?a:0,be=[];f&&be.push(f),be.push(ui(te=>{let Je=Il(te,r,X),pt=typeof se.current=="function"?se.current(Je):se.current,Ue=typeof ze.current=="function"?ze.current(Je):ze.current;return{mainAxis:pt,crossAxis:Ue,alignmentAxis:Ue}},[ae,ge,X,r]));let Ee=P==="none"&&T!=="shift",ye=!Ee&&(d||H||T==="shift"),Kt=T==="none"?null:mi({...$,padding:{top:V.top+Z+ie,right:V.right+Z+q,bottom:V.bottom+Z+K,left:V.left+Z+Q},mainAxis:!H&&T==="flip",crossAxis:P==="flip"?"alignment":!1,fallbackAxisSideDirection:N}),rt=Ee?null:fi({...$,rootBoundary:j,mainAxis:P!=="none",crossAxis:ye,limiter:d||H?void 0:pi(te=>{if(!ne.current)return{};let{width:Je,height:pt}=ne.current.getBoundingClientRect(),Ue=Fe(Ne(te.placement)),Tt=Ue==="y"?Je:pt,mt=Ue==="y"?V.left+V.right:V.top+V.bottom;return{offset:Tt/2+mt/2}})},[$,d,H,j,V,P]);T==="shift"||P==="shift"||s==="center"?be.push(rt,Kt):be.push(Kt,rt),be.push(gi({...$,apply({elements:{floating:te},availableWidth:Je,availableHeight:pt,rects:Ue}){if(!A.current)return;let Tt=te.style;Tt.setProperty(Ol,`${Je}px`),Tt.setProperty(Nl,`${pt}px`);let mt=fe(te).devicePixelRatio||1,{x:Mo,y:wn,width:vn,height:Cr}=Ue.reference,Ar=(Math.round((Mo+vn)*mt)-Math.round(Mo*mt))/mt,Or=(Math.round((wn+Cr)*mt)-Math.round(wn*mt))/mt;Tt.setProperty("--anchor-width",`${Ar}px`),Tt.setProperty("--anchor-height",`${Or}px`)}}),Cl(te=>({element:ne.current||Pe(te.elements.floating).createElement("div"),padding:m,offsetParent:"floating"}),[m]),{name:"transformOrigin",fn(te){let{elements:Je,middlewareData:pt,placement:Ue,rects:Tt,y:mt}=te,Mo=Ne(Ue),wn=Fe(Mo),vn=ne.current,Cr=pt.arrow?.x||0,Ar=pt.arrow?.y||0,Or=vn?.clientWidth||0,Yf=vn?.clientHeight||0,Nr=Cr+Or/2,la=Ar+Yf/2,Uf=Math.abs(pt.shift?.y||0),Gf=Tt.reference.height/2,Bo=typeof i=="function"?i(Il(te,r,X)):i,Kf=Uf>Bo,Xf={top:`${Nr}px calc(100% + ${Bo}px)`,bottom:`${Nr}px ${-Bo}px`,left:`calc(100% + ${Bo}px) ${la}px`,right:`${-Bo}px ${la}px`}[Mo],qf=`${Nr}px ${Tt.reference.y+Gf-mt}px`;return Je.floating.style.setProperty("--transform-origin",ye&&wn==="y"&&Kf?qf:Xf),{}}},Al,w),F(()=>{!h&&g&&g.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[h,g]);let ft=qe.useMemo(()=>({elementResize:!u&&typeof ResizeObserver<"u",layoutShift:!u&&typeof IntersectionObserver<"u"}),[u]),{refs:Ot,elements:xe,x:fn,y:B,middlewareData:D,update:Se,placement:Ae,context:Nt,isPositioned:it,floatingStyles:It}=t({rootContext:g,open:p?h:void 0,placement:O,middleware:be,strategy:n,whileElementsMounted:p?void 0:(...te)=>qo(...te,ft),nodeId:v,externalTree:x}),{sideX:Ye,sideY:uo}=D.adaptiveOrigin||To,Xt=it?n:"fixed",pn=qe.useMemo(()=>{let te;return it?w?te={position:Xt,[Ye]:fn,[uo]:B}:te={...It,position:Xt}:te={position:Xt,top:0,left:0},te[Ol]="100vw",te[Nl]="100vh",it||(te.opacity=0),te},[w,Xt,Ye,fn,uo,B,It,it]),fo=qe.useRef(null);F(()=>{if(!h)return;let te=C.current,Je=typeof te=="function"?te():te,Ue=(Ll(Je)?Je.current:Je)||null||null;Ue!==fo.current&&(Ot.setPositionReference(Ue),fo.current=Ue)},[h,Ot,I,C]),qe.useEffect(()=>{if(!h)return;let te=C.current;typeof te!="function"&&Ll(te)&&te.current!==fo.current&&(Ot.setPositionReference(te.current),fo.current=te.current)},[h,Ot,I,C]),qe.useEffect(()=>{if(p&&h&&xe.reference&&xe.floating)return qo(xe.reference,xe.floating,Se,ft)},[p,h,xe,Se,ft]);let Lt=Ne(Ae),mn=Ml(r,Lt,X),gn=dt(Ae)||"center",bn=!!D.hide?.referenceHidden;F(()=>{R&&h&&it&&Lt!==de&&E(Lt)},[R,h,it,Lt,de]);let hn=qe.useMemo(()=>({position:"absolute",top:D.arrow?.y,left:D.arrow?.x}),[D.arrow]),ca=D.arrow?.centerOffset!==0;return qe.useMemo(()=>({positionerStyles:pn,arrowStyles:hn,arrowRef:ne,arrowUncentered:ca,side:mn,align:gn,physicalSide:Lt,anchorHidden:bn,refs:Ot,context:Nt,isPositioned:it,update:Se}),[pn,hn,ne,ca,mn,gn,Lt,bn,Ot,Nt,it,Se])}function Ll(e){return e!=null&&"current"in e}function or(e){return e==="starting"?fc:me}function Hl(e,t,{styles:o,transitionStatus:n,props:r,refs:i,hidden:s,inert:a=!1}){let l={...o};return a&&(l.pointerEvents="none"),Oe("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:l},or(n),r],stateAttributesMapping:Qo})}var zl=b(z(),1);var Oi=zl.forwardRef(function(t,o){let{render:n,className:r,disabled:i=!1,focusableWhenDisabled:s=!1,nativeButton:a=!0,style:l,...c}=t,{getButtonProps:d,buttonRef:m}=Ya({disabled:i,focusableWhenDisabled:s,native:a});return Oe("button",t,{state:{disabled:i},ref:[o,m],props:[c,d]})});var Ce=b(z(),1),Kl=b(Ht(),1);var Dl=b(z(),1);function jl(e){let[t,o]=Dl.useState({current:e,previous:null});return Object.is(e,t.current)||o({current:e,previous:t.current}),t.previous}var ko=b(z(),1);function Ni(e){let t=Le(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=he(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n;return(jt(o)!==i||jt(n)!==s)&&(o=i,n=s),{width:o,height:n}}function Vl(e){let{popupElement:t,positionerElement:o,content:n,mounted:r,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:l}=e,c=vo(t,!0),d=bo(),m=ko.useRef(null),u=ko.useRef(!0),f=ko.useRef(Ge),p=Y(i),g=Y(s),h=ko.useMemo(()=>Fg(a,l),[a,l]);F(()=>{if(!r){f.current=Ge,u.current=!0,m.current=null;return}if(!t||!o)return;f.current=Fl(t,h),Ii(t,"auto");let y=rr(t,"position","static"),_=rr(t,"transform","none"),v=rr(t,"scale","1"),w=Fl(o,{"--available-width":"max-content","--available-height":"max-content"});function R(){y(),_(),w()}function x(){R(),v()}if(p?.(),u.current||m.current===null){nr(o,"max-content");let P=Ni(t);return m.current=P,nr(o,P),x(),g?.(null,P),u.current=!1,()=>{f.current(),f.current=Ge}}nr(o,"max-content");let S=m.current,E=Ni(t);m.current=E,Ii(t,S),x(),g?.(S,E),nr(o,E);let T=new AbortController;return d.request(()=>{Ii(t,E),c(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},T.signal)}),()=>{T.abort(),d.cancel(),f.current(),f.current=Ge}},[n,t,o,c,d,r,p,g,h])}function Fg(e,t){let o=e==="top",n=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!o&&!n?me:{position:"absolute",[o?"bottom":"top"]:"0",[n?"right":"left"]:"0"}}function rr(e,t,o){let n=e.style.getPropertyValue(t);return e.style.setProperty(t,o),()=>{e.style.setProperty(t,n)}}function Fl(e,t){let o=[];for(let[n,r]of Object.entries(t))o.push(rr(e,n,r));return o.length?()=>{o.forEach(n=>n())}:Ge}function Ii(e,t){let o=t==="auto"?"auto":`${t.width}px`,n=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",o),e.style.setProperty("--popup-height",n)}function nr(e,t){let o=t==="max-content"?"max-content":`${t.width}px`,n=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",o),e.style.setProperty("--positioner-height",n)}var Wl=b(z(),1);var Yl=b(W(),1),ir=function(t){let{direction:o="ltr"}=t,n=Wl.useMemo(()=>({direction:o}),[o]);return(0,Yl.jsx)(Ai.Provider,{value:n,children:t.children})};var Ul={name:"adaptiveOrigin",async fn(e){let{x:t,y:o,rects:{floating:n},elements:{floating:r},platform:i,strategy:s,placement:a}=e,l=fe(r),c=l.getComputedStyle(r);if(!(c.transitionDuration!=="0s"&&c.transitionDuration!==""))return{x:t,y:o,data:To};let m=await i.getOffsetParent?.(r),u={width:0,height:0};if(s==="fixed"&&l?.visualViewport)u={width:l.visualViewport.width,height:l.visualViewport.height};else if(m===l){let _=Pe(r);u={width:_.documentElement.clientWidth,height:_.documentElement.clientHeight}}else await i.isElement?.(m)&&(u=await i.getDimensions(m));let f=Ne(a),p=t,g=o;f==="left"&&(p=u.width-(t+n.width)),f==="top"&&(g=u.height-(o+n.height));let h=f==="left"?"right":To.sideX,y=f==="top"?"bottom":To.sideY;return{x:p,y:g,data:{sideX:h,sideY:y}}}};var Po=b(W(),1),Xl={activationDirection:e=>e?{"data-activation-direction":e}:null};function ql(e){let{store:t,side:o,children:n}=e,r=Eo(),i=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),a=t.useState("open"),l=t.useState("payload"),c=t.useState("mounted"),d=t.useState("popupElement"),m=t.useState("positionerElement"),u=jl(a?i:null),f=Yg(s,l),p=Ce.useRef(null),[g,h]=Ce.useState(null),[y,_]=Ce.useState(null),v=Ce.useRef(null),w=Ce.useRef(null),R=vo(v,!0),x=bo(),S=Ce.useRef(null),[E,T]=Ce.useState(null),[P,N]=Ce.useState(!1);F(()=>(t.set("adaptiveOrigin",Ul),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let H=Y(()=>{v.current?.style.setProperty("animation","none"),v.current?.style.setProperty("transition","none"),w.current?.style.setProperty("display","none")}),j=Y(M=>{v.current?.style.removeProperty("animation"),v.current?.style.removeProperty("transition"),w.current?.style.removeProperty("display"),M&&T(M)}),L=Y(()=>{S.current?.abort();let M=new AbortController;S.current=M,R(()=>{h(null),T(null),p.current=null},M.signal)}),k=Ce.useRef(null);F(()=>{(!a||!c)&&(k.current=null)},[a,c]),F(()=>{if(i&&u&&i!==u&&k.current!==i&&p.current){h(p.current),N(!0);let M=Wg(u,i);_(M),k.current=i}},[i,u]),F(()=>{g!=null&&(S.current?.abort(),N(!0),x.request(()=>{Kl.flushSync(()=>{N(!1)}),L()}))},[f,g,L,x]),F(()=>{let M=v.current;if(!M)return;let X=Pe(M).createElement("div");for(let de of Array.from(M.childNodes))X.appendChild(de.cloneNode(!0));p.current=X});let I=g!=null,C;I?C=(0,Po.jsxs)(Ce.Fragment,{children:[(0,Po.jsx)("div",{"data-previous":!0,inert:Pl(!0),ref:w,style:{...E?{"--popup-width":`${E.width}px`,"--popup-height":`${E.height}px`}:null,position:"absolute"},"data-ending-style":P?void 0:""},"previous"),(0,Po.jsx)("div",{"data-current":!0,ref:v,"data-starting-style":P?"":void 0,children:n},f)]}):C=(0,Po.jsx)("div",{"data-current":!0,ref:v,children:n},f),F(()=>{let M=w.current;!M||!g||M.replaceChildren(...Array.from(g.childNodes))},[g]),Vl({popupElement:d,positionerElement:m,mounted:c,content:l,onMeasureLayout:H,onMeasureLayoutComplete:j,side:o,direction:r});let A={activationDirection:Vg(y),transitioning:I};return{children:C,state:A}}function Vg(e){if(e)return`${Gl(e.horizontal,5,"right","left")} ${Gl(e.vertical,5,"down","up")}`}function Gl(e,t,o,n){return e>t?o:e<-t?n:""}function Wg(e,t){let o=e.getBoundingClientRect(),n=t.getBoundingClientRect(),r={x:o.left+o.width/2,y:o.top+o.height/2},i={x:n.left+n.width/2,y:n.top+n.height/2};return{horizontal:i.x-r.x,vertical:i.y-r.y}}function Yg(e,t){let[o,n]=Ce.useState(0),r=Ce.useRef(e),i=Ce.useRef(t),s=Ce.useRef(!1);return F(()=>{let a=r.current,l=i.current,c=e!==a,d=t!==l;c?(n(m=>m+1),s.current=!d):s.current&&d&&(n(m=>m+1),s.current=!1),r.current=e,i.current=t},[e,t]),`${e??"current"}-${o}`}var sr=b(z(),1),Zl=b(Ht(),1);var Ql=b(W(),1),Jl=sr.forwardRef(function(t,o){let{children:n,container:r,className:i,render:s,style:a,...l}=t,{node:c,subtree:d}=bc({container:r,ref:o,componentProps:t,elementProps:l});return!d&&!c?null:(0,Ql.jsxs)(sr.Fragment,{children:[d,c&&Zl.createPortal(n,c)]})});var tt={};Mt(tt,{Arrow:()=>hd,Handle:()=>$o,Popup:()=>gd,Portal:()=>ud,Positioner:()=>pd,Provider:()=>vd,Root:()=>rd,Trigger:()=>cd,Viewport:()=>yd,createHandle:()=>xd});var Co=b(z(),1);var ar=b(z(),1),Li=ar.createContext(void 0);function et(e){let t=ar.useContext(Li);if(t===void 0&&!e)throw new Error(De(72));return t}var $l=b(z(),1);var ed={..._l,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},cr=class extends Vt{constructor(t,o,n){let r=new io;super(od(t,r,o,n),nd(r),ed)}setOpen=(t,o)=>{dl(this,t,o,{extraState:{openChangeReason:o.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,ee(G.triggerPress,t))}};function td(){let e=new io,t=new er(Object.freeze(od(void 0,e)),Object.freeze(nd(e)),ed);return Object.assign(t,{setOpen:Ge,cancelPendingOpen:Ge})}function od(e,t,o,n=!1){let r={...hl(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e};return r.floatingRootContext=wl(t,o,n),r}function nd(e){return{popupRef:$l.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var Jo=b(W(),1),rd=vi(function(t){let{disabled:o=!1,defaultOpen:n=!1,open:r,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:l,onOpenChangeComplete:c,handle:d,triggerId:m,defaultTriggerId:u=null,children:f}=t,p=cl((N,H)=>new cr({open:n,openProp:r,activeTriggerId:u,triggerIdProp:m},N,H));p.useControlledProp("openProp",r),p.useControlledProp("triggerIdProp",m),p.useContextCallback("onOpenChange",l),p.useContextCallback("onOpenChangeComplete",c);let g=p.useState("open"),h=!o&&g,y=p.useState("activeTriggerId"),_=p.useState("mounted"),v=p.useState("payload");p.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i,disabled:o}),fl(p,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:w,transitionStatus:R}=pl(h,p),x=p.useState("isInstantPhase"),S=p.useState("instantType"),E=p.useState("lastOpenChangeReason"),T=Co.useRef(null);F(()=>{g&&o&&p.setOpen(!1,ee(G.disabled))},[g,o,p]),F(()=>{R==="ending"&&E===G.none||R!=="ending"&&x?(S!=="delay"&&(T.current=S),p.set("instantType","delay")):T.current!==null&&(p.set("instantType",T.current),T.current=null)},[R,x,E,S,p]),F(()=>{h&&y==null&&p.set("payload",void 0)},[p,y,h]),Co.useImperativeHandle(a,()=>({unmount:w,close:()=>p.setOpen(!1,ee(G.imperativeAction))}),[w,p]);let P=h||_||!o&&s!=="none";return(0,Jo.jsxs)(Li.Provider,{value:p,children:[d&&(0,Jo.jsx)(ll,{handle:d,store:p}),P&&(0,Jo.jsx)(Ug,{store:p,disabled:o,trackCursorAxis:s}),typeof f=="function"?f({payload:v}):f]})});function Ug({store:e,disabled:t,trackCursorAxis:o}){let n=e.useState("floatingRootContext"),r=si(n,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=ii(n,{enabled:!t&&o!=="none",axis:o==="none"?void 0:o}),s=Co.useMemo(()=>ve(i.reference,r.reference),[i.reference,r.reference]);return ml(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:r.floating??me}),null}var dr=b(z(),1);var lr=b(z(),1),Mi=lr.createContext(void 0);function id(){return lr.useContext(Mi)}var ad="data-base-ui-tooltip-trigger";function sd(e){if("composedPath"in e){let o=e.composedPath();for(let n=0;nh.select("transitionStatus")==="ending",shouldOpen(){return!X.current}}),Q=Ri(w,{enabled:!I}).reference,q=ae=>{let ge=X.current,be=sd(ae),Ee=ie(be),ye=R.current,Kt=ye&&be&&re(ye,be);if(Ee&&h.select("open")&&h.select("lastOpenChangeReason")===G.triggerHover){h.setOpen(!1,ee(G.triggerHover,ae));return}if(ge&&!Ee&&Kt&&!C.current&&!h.select("open")&&ye&&Pt(O.current)){let rt=()=>{!X.current&&!C.current&&!h.select("open")&&h.setOpen(!0,ee(G.triggerHover,ae,ye))},ft=V();ft===0?(de.clear(),rt()):de.start(ft,rt)}},$=h.useState("triggerProps",T);return Oe("button",t,{state:{open:v},ref:[o,E,R],props:[K,Q,T||A!=="none"?$:void 0,{onMouseOver(ae){q(ae.nativeEvent)},onFocus(ae){Z(sd(ae.nativeEvent))&&ae.preventBaseUIHandler()},onMouseLeave(){X.current=!1,de.clear(),O.current=void 0},onPointerEnter(ae){O.current=ae.pointerType},onPointerDown(ae){O.current=ae.pointerType,h.set("closeOnClick",d),d&&!h.select("open")&&h.cancelPendingOpen(ae.nativeEvent)},onClick(ae){d&&!h.select("open")&&h.cancelPendingOpen(ae.nativeEvent)},id:y,"data-trigger-disabled":I?"":void 0,[ad]:I?void 0:""},f],stateAttributesMapping:Tl})});var dd=b(z(),1);var ur=b(z(),1),Bi=ur.createContext(void 0);function ld(){let e=ur.useContext(Bi);if(e===void 0)throw new Error(De(70));return e}var Hi=b(W(),1),ud=dd.forwardRef(function(t,o){let{keepMounted:n=!1,...r}=t;return et().useState("mounted")||n?(0,Hi.jsx)(Bi.Provider,{value:n,children:(0,Hi.jsx)(Jl,{ref:o,...r})}):null});var pr=b(z(),1);var fr=b(z(),1),zi=fr.createContext(void 0);function Ao(){let e=fr.useContext(zi);if(e===void 0)throw new Error(De(71));return e}var fd=b(W(),1),pd=pr.forwardRef(function(t,o){let{render:n,className:r,anchor:i,positionMethod:s="absolute",side:a="top",align:l="center",sideOffset:c=0,alignOffset:d=0,collisionBoundary:m="clipping-ancestors",collisionPadding:u=5,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:g=!1,collisionAvoidance:h=pc,style:y,..._}=t,v=et(),w=ld(),R=v.useState("open"),x=v.useState("mounted"),S=v.useState("trackCursorAxis"),E=v.useState("disableHoverablePopup"),T=v.useState("floatingRootContext"),P=v.useState("instantType"),N=v.useState("transitionStatus"),H=v.useState("adaptiveOrigin"),j=Bl({anchor:i,positionMethod:s,floatingRootContext:T,mounted:x,side:a,sideOffset:c,align:l,alignOffset:d,collisionBoundary:m,collisionPadding:u,sticky:p,arrowPadding:f,disableAnchorTracking:g,keepMounted:w,collisionAvoidance:h,adaptiveOrigin:H}),L=pr.useMemo(()=>({open:R,side:j.side,align:j.align,anchorHidden:j.anchorHidden,instant:S!=="none"?"tracking-cursor":P}),[R,j.side,j.align,j.anchorHidden,S,P]),k=Hl(t,L,{styles:j.positionerStyles,transitionStatus:N,props:_,refs:[o,v.useStateSetter("positionerElement")],hidden:!x,inert:!R||S==="both"||E});return(0,fd.jsx)(zi.Provider,{value:j,children:k})});var md=b(z(),1);var gd=md.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=et(),{side:l,align:c}=Ao(),d=a.useState("open"),m=a.useState("instantType"),u=a.useState("transitionStatus"),f=a.useState("popupProps"),p=a.useState("floatingRootContext"),g=a.useState("disabled"),h=a.useState("closeDelay");On({open:d,ref:a.context.popupRef,onComplete(){d&&a.context.onOpenChangeComplete?.(!0)}}),ki(p,{enabled:!g,closeDelay:h});let y=a.useStateSetter("popupElement");return Oe("div",t,{state:{open:d,side:l,align:c,instant:m,transitionStatus:u},ref:[o,a.context.popupRef,y],props:[al,f,or(u),s],stateAttributesMapping:kl})});var bd=b(z(),1);var hd=bd.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=et(),{arrowRef:l,side:c,align:d,arrowUncentered:m,arrowStyles:u}=Ao(),f=a.useState("open"),p=a.useState("instantType");return Oe("div",t,{state:{open:f,side:c,align:d,uncentered:m,instant:p},ref:[o,l],props:[{style:u,"aria-hidden":!0},s],stateAttributesMapping:Qo})});var wd=b(z(),1);var Di=b(W(),1),vd=function(t){let{delay:o,closeDelay:n,timeout:r=400}=t,i=wd.useMemo(()=>({open:o,close:n}),[o,n]);return(0,Di.jsx)(Mi.Provider,{value:o,children:(0,Di.jsx)(ni,{delay:i,timeoutMs:r,children:t.children})})};var _d=b(z(),1);var yd=_d.forwardRef(function(t,o){let{render:n,className:r,style:i,children:s,...a}=t,l=et(),c=Ao(),d=l.useState("instantType"),{children:m,state:u}=ql({store:l,side:c.side,children:s}),f={activationDirection:u.activationDirection,transitioning:u.transitioning,instant:d};return Oe("div",t,{state:f,ref:o,props:[a,{children:m}],stateAttributesMapping:Xl})});var $o=class extends Yn{constructor(){super(td(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function xd(){return new $o}function ot(e){return Oe(e.defaultTagName??"div",e,e)}var Ed=b(ce(),1),ji="data-wp-hash";function Fi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&qg(document)),e.__wpStyleRuntime}function Xg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ji}]`))if(o.getAttribute(ji)===t)return!0;return!1}function Td(e,t,o){if(!e.head)return;let n=Fi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Xg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ji,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function qg(e){let t=Fi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Td(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function kd(e,t){let o=Fi();o.styles.set(e,t);for(let n of o.documents.keys())Td(n,e,t)}typeof process>"u",kd("a495f9d138",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Sd={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",kd("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Rd={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},We=(0,Ed.forwardRef)(function({variant:t="body-md",render:o,className:n,...r},i){return ot({render:o,defaultTagName:"span",ref:i,props:ve(r,{className:J(Sd.text,Rd.heading,Rd.p,Sd[t],n)})})});var Od=b(W(),1),Vi="data-wp-hash";function Wi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Qg(document)),e.__wpStyleRuntime}function Zg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Vi}]`))if(o.getAttribute(Vi)===t)return!0;return!1}function Ad(e,t,o){if(!e.head)return;let n=Wi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Zg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Vi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Qg(e){let t=Wi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ad(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Jg(e,t){let o=Wi();o.styles.set(e,t);for(let n of o.documents.keys())Ad(n,e,t)}typeof process>"u",Jg("9db2873e7f","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._96e6251aad1a6136__badge{border-radius:var(--wpds-border-radius-lg,8px);padding-block:var(--wpds-dimension-padding-xs,4px);padding-inline:var(--wpds-dimension-padding-sm,8px)}._99f7158cb520f750__is-high-intent{background-color:var(--wpds-color-background-surface-error,#f6e6e3);color:var(--wpds-color-foreground-content-error,#470000)}.c20ebef2365bc8b7__is-medium-intent{background-color:var(--wpds-color-background-surface-warning,#fde6be);color:var(--wpds-color-foreground-content-warning,#2e1900)}._365e1626c6202e52__is-low-intent{background-color:var(--wpds-color-background-surface-caution,#fee995);color:var(--wpds-color-foreground-content-caution,#281d00)}._33f8198127ddf4ef__is-stable-intent{background-color:var(--wpds-color-background-surface-success,#c6f7cd);color:var(--wpds-color-foreground-content-success,#002900)}._04c1aca8fc449412__is-informational-intent{background-color:var(--wpds-color-background-surface-info,#deebfa);color:var(--wpds-color-foreground-content-info,#001b4f)}._90726e69d495ec19__is-draft-intent{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);color:var(--wpds-color-foreground-content-neutral,#1e1e1e)}._898f4a544993bd39__is-none-intent{background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);padding-block:calc(var(--wpds-dimension-padding-xs, 4px) - var(--wpds-border-width-xs, 1px));padding-inline:calc(var(--wpds-dimension-padding-sm, 8px) - var(--wpds-border-width-xs, 1px))}}}");var Pd={badge:"_96e6251aad1a6136__badge","is-high-intent":"_99f7158cb520f750__is-high-intent","is-medium-intent":"c20ebef2365bc8b7__is-medium-intent","is-low-intent":"_365e1626c6202e52__is-low-intent","is-stable-intent":"_33f8198127ddf4ef__is-stable-intent","is-informational-intent":"_04c1aca8fc449412__is-informational-intent","is-draft-intent":"_90726e69d495ec19__is-draft-intent","is-none-intent":"_898f4a544993bd39__is-none-intent"},Yi=(0,Cd.forwardRef)(function({intent:t="none",className:o,...n},r){return(0,Od.jsx)(We,{ref:r,className:J(Pd.badge,Pd[`is-${t}-intent`],o),...n,variant:"body-sm"})});var mr=b(ce(),1),Nd=b(st(),1),Ld=b(W(),1);import{speak as $g}from"@wordpress/a11y";var Ui="data-wp-hash";function Gi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&tb(document)),e.__wpStyleRuntime}function eb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ui}]`))if(o.getAttribute(Ui)===t)return!0;return!1}function Id(e,t,o){if(!e.head)return;let n=Gi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(eb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ui,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function tb(e){let t=Gi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Id(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function gr(e,t){let o=Gi();o.styles.set(e,t);for(let n of o.documents.keys())Id(n,e,t)}typeof process>"u",gr("effc4e3032",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var en={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"};typeof process>"u",gr("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var ob={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",gr("96553466c8","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var nb={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",gr("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var rb={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},Md=(0,mr.forwardRef)(function({tone:t="brand",variant:o="solid",size:n="default",className:r,focusableWhenDisabled:i=!0,disabled:s,loading:a,loadingAnnouncement:l=(0,Nd.__)("Loading"),children:c,...d},m){let u=J(rb.button,ob["box-sizing"],nb["outset-ring--focus-except-active"],o!=="unstyled"&&en.button,en[`is-${t}`],en[`is-${o}`],en[`is-${n}`],a&&en["is-loading"],r);return(0,mr.useEffect)(()=>{a&&l&&$g(l)},[a,l]),(0,Ld.jsx)(Oi,{ref:m,className:u,focusableWhenDisabled:i,disabled:s??a,...d,children:c})});var jd=b(ce(),1);var Hd=b(ce(),1),zd=b(so(),1),Dd=b(W(),1),ao=(0,Hd.forwardRef)(function({icon:t,size:o=24,...n},r){return(0,Dd.jsx)(zd.SVG,{ref:r,...t.props,...n,width:o,height:o})});var Vd=b(W(),1),Ki="data-wp-hash";function Xi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&sb(document)),e.__wpStyleRuntime}function ib(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ki}]`))if(o.getAttribute(Ki)===t)return!0;return!1}function Fd(e,t,o){if(!e.head)return;let n=Xi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(ib(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ki,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function sb(e){let t=Xi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Fd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ab(e,t){let o=Xi();o.styles.set(e,t);for(let n of o.documents.keys())Fd(n,e,t)}typeof process>"u",ab("effc4e3032",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var cb={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"},qi=(0,jd.forwardRef)(function({className:t,icon:o,...n},r){return(0,Vd.jsx)(ao,{ref:r,icon:o,className:J(cb.icon,t),size:24,...n})});qi.displayName="Button.Icon";var br=Object.assign(Md,{Icon:qi});var hr=b(so(),1),Zi=b(W(),1),Qi=(0,Zi.jsx)(hr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Zi.jsx)(hr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-.75 12v-1.5h1.5V16h-1.5Zm0-8v5h1.5V8h-1.5Z"})});var wr=b(so(),1),Ji=b(W(),1),$i=(0,Ji.jsx)(wr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Ji.jsx)(wr.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})});var vr=b(so(),1),es=b(W(),1),ts=(0,es.jsx)(vr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,es.jsx)(vr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z"})});var _r=b(so(),1),os=b(W(),1),ns=(0,os.jsx)(_r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,os.jsx)(_r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm.75 4v1.5h-1.5V8h1.5Zm0 8v-5h-1.5v5h1.5Z"})});var yr=b(so(),1),rs=b(W(),1),is=(0,rs.jsx)(yr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,rs.jsx)(yr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm11.53-1.47-1.06-1.06L11 12.94l-1.47-1.47-1.06 1.06L11 15.06l4.53-4.53Z"})});var yu=b(ce(),1);var cu=b(ce(),1);var Kd=b(ce(),1);var as="data-wp-hash";function cs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&db(document)),e.__wpStyleRuntime}function lb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${as}]`))if(o.getAttribute(as)===t)return!0;return!1}function Yd(e,t,o){if(!e.head)return;let n=cs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(lb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(as,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function db(e){let t=cs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Yd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ub(e,t){let o=cs();o.styles.set(e,t);for(let n of o.documents.keys())Yd(n,e,t)}typeof process>"u",ub("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var Wd={slot:"_11fc52b637ff8a7e__slot"},Ud="data-wp-compat-overlay-slot";function fb(){return typeof document>"u"?null:document}function pb(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var xt=null;function ss(e){return e.setAttribute("aria-hidden","false"),e}function mb(e){let t=e.createElement("div");return t.setAttribute(Ud,""),Wd.slot&&t.classList.add(Wd.slot),e.body.appendChild(t),t}function Gd(){if(typeof window>"u"||!pb()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=fb();if(!e||!e.body)return;if(xt&&xt.ownerDocument===e&&xt.isConnected)return ss(xt);let t=e.querySelector(`[${Ud}]`);return t instanceof HTMLDivElement?(xt=ss(t),xt):(xt?.isConnected&&xt.remove(),xt=ss(mb(e)),xt)}var Xd=b(W(),1),qd=(0,Kd.forwardRef)(function({container:t,...o},n){return(0,Xd.jsx)(tt.Portal,{container:t??Gd(),...o,ref:n})});var Zd=b(ce(),1),$d=b(W(),1),ls="data-wp-hash";function ds(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&bb(document)),e.__wpStyleRuntime}function gb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ls}]`))if(o.getAttribute(ls)===t)return!0;return!1}function Qd(e,t,o){if(!e.head)return;let n=ds(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(gb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ls,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function bb(e){let t=ds();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Qd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Jd(e,t){let o=ds();o.styles.set(e,t);for(let n of o.documents.keys())Qd(n,e,t)}typeof process>"u",Jd("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var hb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Jd("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var wb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},eu=(0,Zd.forwardRef)(function({align:t="center",className:o,side:n="top",sideOffset:r=4,...i},s){return(0,$d.jsx)(tt.Positioner,{ref:s,align:t,side:n,sideOffset:r,...i,className:J(hb["box-sizing"],wb.positioner,o)})});var tu=b(ce(),1);function us(e,t,o){return(0,tu.cloneElement)(e??t,{children:o})}var vb=b(nu(),1);var iu=b(fs(),1),{lock:s3,unlock:su}=(0,iu.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function _b(){let e=vb;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return su(e.privateApis).ThemeProvider}var au=_b();var tn=b(W(),1),ps="data-wp-hash";function ms(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&xb(document)),e.__wpStyleRuntime}function yb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ps}]`))if(o.getAttribute(ps)===t)return!0;return!1}function lu(e,t,o){if(!e.head)return;let n=ms(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(yb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ps,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function xb(e){let t=ms();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)lu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Sb(e,t){let o=ms();o.styles.set(e,t);for(let n of o.documents.keys())lu(n,e,t)}typeof process>"u",Sb("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Rb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Eb={background:"#1e1e1e"},gs=(0,cu.forwardRef)(function({portal:t,positioner:o,children:n,className:r,...i},s){let a=(0,tn.jsx)(au,{color:Eb,children:(0,tn.jsx)(tt.Popup,{ref:s,className:J(Rb.popup,r),...i,children:n})}),l=us(o,(0,tn.jsx)(eu,{}),a);return us(t,(0,tn.jsx)(qd,{}),l)});var du=b(ce(),1),uu=b(W(),1),bs=(0,du.forwardRef)(function(t,o){return(0,uu.jsx)(tt.Trigger,{ref:o,...t})});var fu=b(st(),1),pu=b(W(),1);function mu({children:e}){return(0,pu.jsx)(ir,{direction:(0,fu.isRTL)()?"rtl":"ltr",children:e})}var hs=b(W(),1);function ws(e){return(0,hs.jsx)(mu,{children:(0,hs.jsx)(tt.Root,{...e})})}var on=b(ce(),1),Sr=b(st(),1);var gu=b(ce(),1),vs="data-wp-hash";function _s(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Pb(document)),e.__wpStyleRuntime}function kb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${vs}]`))if(o.getAttribute(vs)===t)return!0;return!1}function bu(e,t,o){if(!e.head)return;let n=_s(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(kb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Pb(e){let t=_s();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)bu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Cb(e,t){let o=_s();o.styles.set(e,t);for(let n of o.documents.keys())bu(n,e,t)}typeof process>"u",Cb("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var Ab={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},ys=(0,gu.forwardRef)(function({render:t,...o},n){return ot({render:t,ref:n,props:ve({className:Ab["visually-hidden"]},o,{"data-visually-hidden":""})})});var xr=b(W(),1);function hu({"aria-describedby":e,"aria-keyshortcuts":t,shortcut:o}){let n=(0,on.useId)(),r=o?n:void 0,i=[e,r].filter(Boolean).join(" ");return{descriptionId:r,targetProps:{"aria-describedby":i||void 0,"aria-keyshortcuts":o?.ariaKeyShortcut??t}}}var wu=(0,on.forwardRef)(function({descriptionId:t,shortcut:o},n){return(0,xr.jsx)(ys,{id:t,"aria-hidden":"true",render:(0,xr.jsx)("span",{ref:n}),children:(0,Sr.sprintf)((0,Sr.__)("Keyboard shortcut: %s"),o.label??o.ariaKeyShortcut)})}),vu=(0,on.forwardRef)(function({className:t,shortcut:o},n){return(0,xr.jsx)("span",{ref:n,"aria-hidden":"true",className:t,dir:"ltr",children:o.displayShortcut})});var nt=b(W(),1),xs="data-wp-hash";function Ss(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Nb(document)),e.__wpStyleRuntime}function Ob(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${xs}]`))if(o.getAttribute(xs)===t)return!0;return!1}function xu(e,t,o){if(!e.head)return;let n=Ss(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ob(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(xs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Nb(e){let t=Ss();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)xu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Ib(e,t){let o=Ss();o.styles.set(e,t);for(let n of o.documents.keys())xu(n,e,t)}typeof process>"u",Ib("c5cdafb1bc","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}");var _u={"icon-button":"_28cfdc260e755391__icon-button",icon:"f1c70d719989a85a__icon"},Rs=(0,yu.forwardRef)(function({label:t,className:o,children:n,disabled:r,focusableWhenDisabled:i=!0,icon:s,size:a,shortcut:l,positioner:c,"aria-describedby":d,"aria-keyshortcuts":m,...u},f){let p=J(_u["icon-button"],o),{descriptionId:g,targetProps:h}=hu({"aria-describedby":d,"aria-keyshortcuts":m,shortcut:l});return(0,nt.jsxs)(ws,{children:[(0,nt.jsxs)(bs,{ref:f,...h,disabled:r&&!i,render:(0,nt.jsx)(br,{...u,size:a,"aria-label":t,disabled:r,focusableWhenDisabled:i}),className:p,children:[(0,nt.jsx)(ao,{icon:s,size:24,className:_u.icon}),l&&g&&(0,nt.jsx)(wu,{descriptionId:g,shortcut:l})]}),(0,nt.jsxs)(gs,{positioner:c,children:[t,l&&(0,nt.jsxs)(nt.Fragment,{children:[" ",(0,nt.jsx)(vu,{shortcut:l})]})]})]})});var Su=b(ce(),1),Es="data-wp-hash";function Ts(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Mb(document)),e.__wpStyleRuntime}function Lb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Es}]`))if(o.getAttribute(Es)===t)return!0;return!1}function Ru(e,t,o){if(!e.head)return;let n=Ts(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Lb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Es,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Mb(e){let t=Ts();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ru(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Bb(e,t){let o=Ts();o.styles.set(e,t);for(let n of o.documents.keys())Ru(n,e,t)}typeof process>"u",Bb("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var Hb={stack:"_19ce0419607e1896__stack"},zb={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},Ut=(0,Su.forwardRef)(function({direction:t,gap:o,align:n,justify:r,wrap:i,render:s,...a},l){let c={gap:o&&zb[o],alignItems:n,justifyContent:r,flexDirection:t,flexWrap:i};return ot({render:s,ref:l,props:ve(a,{style:c,className:Hb.stack})})});var Eu=b(ce(),1),Tu=b(st(),1),Oo=b(W(),1),ks="data-wp-hash";function Ps(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&jb(document)),e.__wpStyleRuntime}function Db(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ks}]`))if(o.getAttribute(ks)===t)return!0;return!1}function ku(e,t,o){if(!e.head)return;let n=Ps(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Db(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ks,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function jb(e){let t=Ps();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ku(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Er(e,t){let o=Ps();o.styles.set(e,t);for(let n of o.documents.keys())ku(n,e,t)}typeof process>"u",Er("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Fb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Er("96553466c8","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var Vb={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",Er("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var Rr={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",Er("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Wb={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},co=(0,Eu.forwardRef)(function({children:t,variant:o="default",tone:n="brand",openInNewTab:r=!1,render:i,className:s,...a},l){return ot({render:i,defaultTagName:"a",ref:l,props:ve(a,{className:J(Wb.a,Fb["box-sizing"],Vb["outset-ring--focus-except-active"],o!=="unstyled"&&Rr.link,o!=="unstyled"&&Rr[`is-${n}`],o==="unstyled"&&Rr["is-unstyled"],s),target:r?"_blank":void 0,children:(0,Oo.jsxs)(Oo.Fragment,{children:[t,r&&(0,Oo.jsx)("span",{className:Rr["link-icon"],role:"img","aria-label":(0,Tu.__)("(opens in a new tab)")})]})})})});var nn={};Mt(nn,{ActionButton:()=>Qu,ActionLink:()=>ef,Actions:()=>Fu,CloseIcon:()=>Gu,Description:()=>zu,Root:()=>Au,Title:()=>Lu});var No=b(ce(),1);import{speak as Yb}from"@wordpress/a11y";var Io=b(W(),1),As="data-wp-hash";function Os(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Gb(document)),e.__wpStyleRuntime}function Ub(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${As}]`))if(o.getAttribute(As)===t)return!0;return!1}function Pu(e,t,o){if(!e.head)return;let n=Os(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ub(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(As,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Gb(e){let t=Os();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Pu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Cu(e,t){let o=Os();o.styles.set(e,t);for(let n of o.documents.keys())Pu(n,e,t)}typeof process>"u",Cu("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Kb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Cu("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Cs={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Xb={neutral:null,info:ns,warning:Qi,success:is,error:ts};function qb(e){return e==="error"?"assertive":"polite"}function Zb(e){if(e){if(typeof e=="string")return e;try{return(0,No.renderToString)(e)}catch{return}}}function Qb(e,t){let o=Zb(e);(0,No.useEffect)(()=>{o&&Yb(o,t)},[o,t])}var Au=(0,No.forwardRef)(function({intent:t="neutral",children:o,icon:n,spokenMessage:r=o,politeness:i=qb(t),render:s,...a},l){Qb(r,i);let c=n===null?null:n??Xb[t],d=J(Cs.notice,Cs[`is-${t}`],Kb["box-sizing"]);return ot({defaultTagName:"div",render:s,ref:l,props:ve({className:d,children:(0,Io.jsxs)(Io.Fragment,{children:[o,c&&(0,Io.jsx)(ao,{className:Cs.icon,icon:c})]})},a)})});var Ou=b(ce(),1);var Iu=b(W(),1),Ns="data-wp-hash";function Is(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&$b(document)),e.__wpStyleRuntime}function Jb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ns}]`))if(o.getAttribute(Ns)===t)return!0;return!1}function Nu(e,t,o){if(!e.head)return;let n=Is(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Jb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ns,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function $b(e){let t=Is();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Nu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function eh(e,t){let o=Is();o.styles.set(e,t);for(let n of o.documents.keys())Nu(n,e,t)}typeof process>"u",eh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var th={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Lu=(0,Ou.forwardRef)(function({className:t,...o},n){return(0,Iu.jsx)(We,{ref:n,variant:"heading-md",className:J(th.title,t),...o})});var Mu=b(ce(),1);var Hu=b(W(),1),Ls="data-wp-hash";function Ms(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&nh(document)),e.__wpStyleRuntime}function oh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ls}]`))if(o.getAttribute(Ls)===t)return!0;return!1}function Bu(e,t,o){if(!e.head)return;let n=Ms(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(oh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ls,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function nh(e){let t=Ms();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Bu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function rh(e,t){let o=Ms();o.styles.set(e,t);for(let n of o.documents.keys())Bu(n,e,t)}typeof process>"u",rh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var ih={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},zu=(0,Mu.forwardRef)(function({className:t,...o},n){return(0,Hu.jsx)(We,{ref:n,variant:"body-md",className:J(ih.description,t),...o})});var Du=b(ce(),1);var Bs="data-wp-hash";function Hs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&ah(document)),e.__wpStyleRuntime}function sh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Bs}]`))if(o.getAttribute(Bs)===t)return!0;return!1}function ju(e,t,o){if(!e.head)return;let n=Hs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(sh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Bs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function ah(e){let t=Hs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ju(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ch(e,t){let o=Hs();o.styles.set(e,t);for(let n of o.documents.keys())ju(n,e,t)}typeof process>"u",ch("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var lh={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Fu=(0,Du.forwardRef)(function({render:t,...o},n){return ot({defaultTagName:"div",render:t,ref:n,props:ve({className:lh.actions},o)})});var Vu=b(ce(),1),Wu=b(st(),1);var Uu=b(W(),1),zs="data-wp-hash";function Ds(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&uh(document)),e.__wpStyleRuntime}function dh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${zs}]`))if(o.getAttribute(zs)===t)return!0;return!1}function Yu(e,t,o){if(!e.head)return;let n=Ds(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(dh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(zs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function uh(e){let t=Ds();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Yu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function fh(e,t){let o=Ds();o.styles.set(e,t);for(let n of o.documents.keys())Yu(n,e,t)}typeof process>"u",fh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var ph={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Gu=(0,Vu.forwardRef)(function({className:t,icon:o=$i,label:n=(0,Wu.__)("Dismiss"),...r},i){return(0,Uu.jsx)(Rs,{...r,ref:i,className:J(ph["close-icon"],t),variant:"minimal",size:"small",tone:"neutral",icon:o,label:n})});var Xu=b(ce(),1);var Zu=b(W(),1),js="data-wp-hash";function Fs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&gh(document)),e.__wpStyleRuntime}function mh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${js}]`))if(o.getAttribute(js)===t)return!0;return!1}function qu(e,t,o){if(!e.head)return;let n=Fs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(mh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(js,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function gh(e){let t=Fs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)qu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function bh(e,t){let o=Fs();o.styles.set(e,t);for(let n of o.documents.keys())qu(n,e,t)}typeof process>"u",bh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Ku={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Qu=(0,Xu.forwardRef)(function({className:t,loading:o,loadingAnnouncement:n,variant:r,...i},s){return(0,Zu.jsx)(br,{...i,...o!==void 0?{loading:o,loadingAnnouncement:n??""}:{},ref:s,size:"compact",tone:"neutral",variant:r,className:J(Ku["action-button"],Ku[`is-action-button-${r}`],t)})});var Ju=b(ce(),1);var Ws=b(W(),1),Vs="data-wp-hash";function Ys(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&wh(document)),e.__wpStyleRuntime}function hh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Vs}]`))if(o.getAttribute(Vs)===t)return!0;return!1}function $u(e,t,o){if(!e.head)return;let n=Ys(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(hh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function wh(e){let t=Ys();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)$u(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function vh(e,t){let o=Ys();o.styles.set(e,t);for(let n of o.documents.keys())$u(n,e,t)}typeof process>"u",vh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var _h={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},ef=(0,Ju.forwardRef)(function({className:t,render:o,...n},r){return(0,Ws.jsx)(We,{ref:r,className:J(_h["action-link"],t),...n,variant:"body-md",render:(0,Ws.jsx)(co,{tone:"neutral",variant:"default",render:o})})});var tf=b(ce(),1),of=b(W(),1),nf=(0,tf.forwardRef)(({children:e,className:t,ariaLabel:o,as:n="div",...r},i)=>(0,of.jsx)(n,{ref:i,className:J("admin-ui-navigable-region",t),"aria-label":o,role:"region",tabIndex:"-1",...r,children:e}));nf.displayName="NavigableRegion";var rf=nf;var sf=b(st(),1);var Gt=b(W(),1),Gs="data-wp-hash";function Ks(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&xh(document)),e.__wpStyleRuntime}function yh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Gs}]`))if(o.getAttribute(Gs)===t)return!0;return!1}function af(e,t,o){if(!e.head)return;let n=Ks(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(yh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Gs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function xh(e){let t=Ks();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)af(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Sh(e,t){let o=Ks();o.styles.set(e,t);for(let n of o.documents.keys())af(n,e,t)}typeof process>"u",Sh("72ef022400",".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}");var Us={list:"bfb5a2dd8cceebd3__list",li:"a4759b4cb2c8bd92__li",item:"_07da506d3f2d9afe__item"},Rh=({items:e,currentHref:t,ariaLabel:o=(0,sf.__)("Sections"),linkComponent:n,className:r})=>{if(!e.length)return null;let i=n??"a";return(0,Gt.jsx)("nav",{"aria-label":o,className:r,children:(0,Gt.jsx)(Ut,{render:(0,Gt.jsx)("ul",{role:"list"}),direction:"row",align:"center",gap:"md",className:Us.list,children:e.map(s=>(0,Gt.jsx)("li",{className:Us.li,children:(0,Gt.jsx)(We,{variant:"body-md",className:Us.item,render:(0,Gt.jsx)(co,{variant:"unstyled","aria-current":s.href===t?"page":void 0,render:(0,Gt.jsx)(i,{href:s.href})}),children:s.label})},s.href))})})},cf=Rh;var df=b(rn(),1),{Fill:uf,Slot:ff}=(0,df.createSlotFill)("SidebarToggle");var Ze=b(W(),1),Xs="data-wp-hash";function qs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Th(document)),e.__wpStyleRuntime}function Eh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Xs}]`))if(o.getAttribute(Xs)===t)return!0;return!1}function pf(e,t,o){if(!e.head)return;let n=qs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Eh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Xs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Th(e){let t=qs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)pf(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function kh(e,t){let o=qs();o.styles.set(e,t);for(let n of o.documents.keys())pf(n,e,t)}typeof process>"u",kh("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var St={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function mf({headingLevel:e=1,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:s,navigation:a,components:l,showSidebarToggle:c=!0}){let d=`h${e}`,m=!!a?.items?.length;return(0,Ze.jsxs)(Ut,{direction:"column",className:J(St.header,m&&St["has-navigation"]),children:[(0,Ze.jsxs)(Ut,{className:St["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,Ze.jsxs)(Ut,{direction:"row",gap:"sm",align:"center",justify:"start",className:St["header-lockup"],children:[c&&(0,Ze.jsx)(ff,{bubblesVirtually:!0,className:St["sidebar-toggle-slot"]}),n&&(0,Ze.jsx)("div",{className:St["header-visual"],"aria-hidden":"true",children:n}),r&&(0,Ze.jsx)(We,{className:St["header-title"],render:(0,Ze.jsx)(d,{}),variant:"heading-lg",children:r}),t,o]}),s&&(0,Ze.jsx)(Ut,{align:"center",className:St["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,Ze.jsx)(We,{render:(0,Ze.jsx)("p",{}),variant:"body-md",className:St["header-subtitle"],children:i}),m&&(0,Ze.jsx)(cf,{...a,linkComponent:l?.link,className:St["header-navigation"]})]})}var sn=b(W(),1),Qs="data-wp-hash";function Js(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Ch(document)),e.__wpStyleRuntime}function Ph(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Qs}]`))if(o.getAttribute(Qs)===t)return!0;return!1}function gf(e,t,o){if(!e.head)return;let n=Js(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ph(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Qs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Ch(e){let t=Js();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)gf(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Ah(e,t){let o=Js();o.styles.set(e,t);for(let n of o.documents.keys())gf(n,e,t)}typeof process>"u",Ah("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Zs={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function bf({headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,children:s,className:a,actions:l,navigation:c,components:d,ariaLabel:m,hasPadding:u=!1,showSidebarToggle:f=!0}){let p=J(Zs.page,a);return(0,sn.jsxs)(rf,{className:p,ariaLabel:m??(typeof r=="string"?r:""),children:[(r||t||o||l||n||!!c?.items?.length)&&(0,sn.jsx)(mf,{headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:l,navigation:c,components:d,showSidebarToggle:f}),u?(0,sn.jsx)("div",{className:J(Zs.content,Zs["has-padding"]),children:s}):s]})}bf.SidebarToggleFill=uf;var $s=bf;var ut=b(rn()),Ff=b(an()),Vf=b(ce()),At=b(st()),Wf=b(Tr());import{privateApis as Kh}from"@wordpress/connectors";var vf=b(fs()),{lock:a8,unlock:Lo}=(0,vf.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/routes");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='09e9b056ea']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","09e9b056ea"),e.appendChild(document.createTextNode(".connectors-page{box-sizing:border-box;margin:0 auto;max-width:680px;padding:24px;width:100%}.connectors-page .components-item{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;padding:20px;scroll-margin-top:120px}.connectors-page .connector-settings__error{color:#cc1818}.connectors-page .connector-settings .components-text-control__input{font-family:monospace;scroll-margin-top:120px}.connectors-page__file-mods-notice{margin-bottom:16px}.connectors-page--empty{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:32px;justify-content:center;text-align:center}.connectors-page .ai-plugin-callout{background-color:#e7d4e4;background-image:radial-gradient(ellipse 70% 120% at 18% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 92% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 58% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%);border-radius:8px;overflow:hidden;padding:24px;padding-inline-end:150px;position:relative}[dir=rtl] .connectors-page .ai-plugin-callout{background-image:radial-gradient(ellipse 70% 120% at 82% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 8% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 42% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%)}.connectors-page .ai-plugin-callout__content{align-items:flex-start;display:flex;flex-direction:column;gap:12px;padding-top:2px}.connectors-page .ai-plugin-callout__content p{font-size:13px;line-height:20px;margin:0}.connectors-page .ai-plugin-callout__decoration{height:110px;inset-inline-end:16px;position:absolute;top:12px;width:110px}.connectors-page>p{color:#949494}@media (max-width:680px){.connectors-page .ai-plugin-callout{padding:12px;padding-inline-end:100px}.connectors-page .ai-plugin-callout__decoration{height:75px;inset-inline-end:8px;top:8px;width:75px}}@media (max-width:480px){.connectors-page{padding:8px}.connectors-page .ai-plugin-callout{padding-inline-end:130px}.connectors-page .components-item{padding:12px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child svg{height:32px;width:32px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child>.components-h-stack:last-child{align-items:flex-end;flex-direction:column}}")),document.head.appendChild(e)}var dn=b(rn()),sa=b(Tr()),un=b(an()),Et=b(ce()),Qe=b(st()),Hf=b(ea()),zf=b(xf());var kr=b(rn()),na=b(ce()),Af=b(an()),lo=b(st());import{__experimentalRegisterConnector as Oh,__experimentalConnectorItem as Cf,__experimentalDefaultConnectorSettings as Nh,__experimentalApplicationPasswordConnectorSettings as Ih,privateApis as Lh}from"@wordpress/connectors";var ta=b(Tr()),ln=b(an()),cn=b(ce()),pe=b(st()),Sf=b(ea());function oa({file:e,settingName:t,connectorName:o,isInstalled:n,isActivated:r,keySource:i="none",initialIsConnected:s=!1}){let[a,l]=(0,cn.useState)(!1),[c,d]=(0,cn.useState)(!1),[m,u]=(0,cn.useState)(s),[f,p]=(0,cn.useState)(null),g=e?.replace(/\.php$/,""),h=g?.includes("/")?g.split("/")[0]:g,{derivedPluginStatus:y,canManagePlugins:_,currentApiKey:v,currentUsername:w,hasStoredCredentials:R,hasResolvedSettings:x,canInstallPlugins:S}=(0,ln.useSelect)(Q=>{let q=Q(ta.store),ne=q.getEntityRecord("root","site")?.[t],se=typeof ne=="string"?ne:"",ze=typeof ne=="object"&&ne!==null?ne:void 0,ae=ze!==void 0?!!ze.username&&!!ze.password:!!se,ge=q.hasFinishedResolution("getEntityRecord",["root","site"]),be=!!q.canUser("create",{kind:"root",name:"plugin"}),Ee={currentApiKey:se,currentUsername:ze?.username??"",hasStoredCredentials:ae,hasResolvedSettings:ge,canInstallPlugins:be};if(!e)return{...Ee,derivedPluginStatus:ge?"active":"checking",canManagePlugins:void 0};let ye=q.getEntityRecord("root","plugin",g);if(!q.hasFinishedResolution("getEntityRecord",["root","plugin",g]))return{...Ee,derivedPluginStatus:"checking",canManagePlugins:void 0};if(ye){let ft=ye.status==="active"||ye.status==="network-active";return{...Ee,derivedPluginStatus:ft?"active":"inactive",canManagePlugins:!0}}let rt="not-installed";return r?rt="active":n&&(rt="inactive"),{...Ee,derivedPluginStatus:rt,canManagePlugins:!1}},[e,g,t,n,r]),E=f??y,T=_,P=E==="active"&&m||f==="active"&&R,{saveEntityRecord:N,invalidateResolution:H}=(0,ln.useDispatch)(ta.store),{createSuccessNotice:j,createErrorNotice:L}=(0,ln.useDispatch)(Sf.store),k=Q=>N("root","site",{[t]:Q},{throwOnError:!0}),I=()=>{j((0,pe.sprintf)((0,pe.__)("%s connected successfully."),o),{id:"connector-connect-success",type:"snackbar"})},C=()=>{j((0,pe.sprintf)((0,pe.__)("%s disconnected."),o),{id:"connector-disconnect-success",type:"snackbar"})},A=()=>{L((0,pe.sprintf)((0,pe.__)("Failed to disconnect %s."),o),{id:"connector-disconnect-error",type:"snackbar"})},M=async()=>{if(h){d(!0);try{await N("root","plugin",{slug:h,status:"active"},{throwOnError:!0}),p("active"),H("getEntityRecord",["root","site"]),l(!0),j((0,pe.sprintf)((0,pe.__)("Plugin for %s installed and activated successfully."),o),{id:"connector-plugin-install-success",type:"snackbar"})}catch{L((0,pe.sprintf)((0,pe.__)("Failed to install plugin for %s."),o),{id:"connector-plugin-install-error",type:"snackbar"})}finally{d(!1)}}},X=async()=>{if(e){d(!0);try{await N("root","plugin",{plugin:g,status:"active"},{throwOnError:!0}),p("active"),H("getEntityRecord",["root","site"]),l(!0),j((0,pe.sprintf)((0,pe.__)("Plugin for %s activated successfully."),o),{id:"connector-plugin-activate-success",type:"snackbar"})}catch{L((0,pe.sprintf)((0,pe.__)("Failed to activate plugin for %s."),o),{id:"connector-plugin-activate-error",type:"snackbar"})}finally{d(!1)}}};return{pluginStatus:E,canInstallPlugins:S,canActivatePlugins:T,isExpanded:a,setIsExpanded:l,isBusy:c,isConnected:P,currentApiKey:v,currentUsername:w,hasResolvedSettings:x,keySource:i,handleButtonClick:()=>{if(E==="not-installed"){if(S===!1)return;M()}else if(E==="inactive"){if(T===!1)return;X()}else l(!a)},getButtonLabel:()=>{if(c)return E==="not-installed"?(0,pe.__)("Installing\u2026"):(0,pe.__)("Activating\u2026");if(a)return(0,pe.__)("Cancel");if(P)return(0,pe.__)("Edit");switch(E){case"checking":return(0,pe.__)("Checking\u2026");case"not-installed":return(0,pe.__)("Install");case"inactive":return(0,pe.__)("Activate");case"active":return(0,pe.__)("Set up")}},saveApiKey:async Q=>{let q=v;try{let se=(await k(Q))?.[t];if(Q&&(se===q||!se))throw new Error("It was not possible to connect to the provider using this key.");u(!0),I()}catch($){throw console.error("Failed to save API key:",$),$}},removeApiKey:async()=>{try{await k(""),u(!1),C()}catch(Q){console.error("Failed to remove API key:",Q),A()}},saveCredentials:async({username:Q,applicationPassword:q})=>{try{let se=(await k({username:Q,password:q}))?.[t];if(!se?.username||!se?.password)throw new Error((0,pe.__)("It was not possible to save these credentials."));u(!0),I()}catch($){throw console.error("Failed to save credentials:",$),$}},removeCredentials:async()=>{try{await k({username:"",password:""}),u(!1),C()}catch(Q){console.error("Failed to remove credentials:",Q),A()}}}}var ue=b(W()),Rf=()=>(0,ue.jsx)("svg",{width:"40",height:"40",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:(0,ue.jsx)("path",{d:"M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364l2.0201-1.1685a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.4043-.6813zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z",fill:"currentColor"})}),Ef=()=>(0,ue.jsx)("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:(0,ue.jsx)("path",{d:"M6.2 21.024L12.416 17.536L12.52 17.232L12.416 17.064H12.112L11.072 17L7.52 16.904L4.44 16.776L1.456 16.616L0.704 16.456L0 15.528L0.072 15.064L0.704 14.64L1.608 14.72L3.608 14.856L6.608 15.064L8.784 15.192L12.008 15.528H12.52L12.592 15.32L12.416 15.192L12.28 15.064L9.176 12.96L5.816 10.736L4.056 9.456L3.104 8.808L2.624 8.2L2.416 6.872L3.28 5.92L4.44 6L4.736 6.08L5.912 6.984L8.424 8.928L11.704 11.344L12.184 11.744L12.376 11.608L12.4 11.512L12.184 11.152L10.4 7.928L8.496 4.648L7.648 3.288L7.424 2.472C7.344 2.136 7.288 1.856 7.288 1.512L8.272 0.176L8.816 0L10.128 0.176L10.68 0.656L11.496 2.52L12.816 5.456L14.864 9.448L15.464 10.632L15.784 11.728L15.904 12.064H16.112V11.872L16.28 9.624L16.592 6.864L16.896 3.312L17 2.312L17.496 1.112L18.48 0.464L19.248 0.832L19.88 1.736L19.792 2.32L19.416 4.76L18.68 8.584L18.2 11.144H18.48L18.8 10.824L20.096 9.104L22.272 6.384L23.232 5.304L24.352 4.112L25.072 3.544H26.432L27.432 5.032L26.984 6.568L25.584 8.344L24.424 9.848L22.76 12.088L21.72 13.88L21.816 14.024L22.064 14L25.824 13.2L27.856 12.832L30.28 12.416L31.376 12.928L31.496 13.448L31.064 14.512L28.472 15.152L25.432 15.76L20.904 16.832L20.848 16.872L20.912 16.952L22.952 17.144L23.824 17.192H25.96L29.936 17.488L30.976 18.176L31.6 19.016L31.496 19.656L29.896 20.472L27.736 19.96L22.696 18.76L20.968 18.328H20.728V18.472L22.168 19.88L24.808 22.264L28.112 25.336L28.28 26.096L27.856 26.696L27.408 26.632L24.504 24.448L23.384 23.464L20.848 21.328H20.68V21.552L21.264 22.408L24.352 27.048L24.512 28.472L24.288 28.936L23.488 29.216L22.608 29.056L20.8 26.52L18.936 23.664L17.432 21.104L17.248 21.208L16.36 30.768L15.944 31.256L14.984 31.624L14.184 31.016L13.76 30.032L14.184 28.088L14.696 25.552L15.112 23.536L15.488 21.032L15.712 20.2L15.696 20.144L15.512 20.168L13.624 22.76L10.752 26.64L8.48 29.072L7.936 29.288L6.992 28.8L7.08 27.928L7.608 27.152L10.752 23.152L12.648 20.672L13.872 19.24L13.864 19.032H13.792L5.44 24.456L3.952 24.648L3.312 24.048L3.392 23.064L3.696 22.744L6.208 21.016L6.2 21.024Z",fill:"#D97757"})}),Tf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("path",{d:"M0 4C0 1.79086 1.79086 0 4 0H28C30.2091 0 32 1.79086 32 4V28C32 30.2091 30.2091 32 28 32H4C1.79086 32 0 30.2091 0 28V4Z",fill:"#F0F0F0"}),(0,ue.jsx)("path",{d:"M14.5 8V12H17.5V8H19V12H20.5C20.7652 12 21.0196 12.1054 21.2071 12.2929C21.3946 12.4804 21.5 12.7348 21.5 13V17L18.5 21V23C18.5 23.2652 18.3946 23.5196 18.2071 23.7071C18.0196 23.8946 17.7652 24 17.5 24H14.5C14.2348 24 13.9804 23.8946 13.7929 23.7071C13.6054 23.5196 13.5 23.2652 13.5 23V21L10.5 17V13C10.5 12.7348 10.6054 12.4804 10.7929 12.2929C10.9804 12.1054 11.2348 12 11.5 12H13V8H14.5ZM15 20.5V22.5H17V20.5L20 16.5V13.5H12V16.5L15 20.5Z",fill:"#949494"})]}),kf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 44 44",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("rect",{width:"44",height:"44",fill:"#357B49",rx:"6"}),(0,ue.jsx)("path",{fill:"#fff",fillRule:"evenodd",d:"m29.746 28.31-6.392-16.797c-.152-.397-.305-.672-.789-.675-.673 0-1.408.611-1.746 1.316l-7.378 16.154c-.072.16-.143.311-.214.454-.5.995-1.045 1.546-2.357 1.626a.399.399 0 0 0-.16.033l-.01.004a.399.399 0 0 0-.23.392v.01c0 .054.01.106.03.155l.004.01a.416.416 0 0 0 .394.252h6.212a.417.417 0 0 0 .307-.12.416.416 0 0 0 .124-.305.398.398 0 0 0-.105-.302.399.399 0 0 0-.294-.127c-.757 0-2.197-.062-2.197-1.164.02-.318.103-.63.245-.916l1.399-3.152c.52-1.163 1.654-1.163 2.572-1.163h5.843c.023 0 .044 0 .062.003.13.014.16.081.214.242l1.534 4.07a2.857 2.857 0 0 1 .216 1.04c0 .054-.003.104-.01.153-.09.726-.831.887-1.49.887a.4.4 0 0 0-.294.127l-.007.008-.007.008a.401.401 0 0 0-.092.286v.01c0 .054.01.106.03.155l.005.01a.42.42 0 0 0 .395.252h7.011a.413.413 0 0 0 .279-.13.412.412 0 0 0 .11-.297.387.387 0 0 0-.09-.294.388.388 0 0 0-.277-.135c-1.448-.122-2.295-.643-2.847-2.08Zm-11.985-5.844 2.847-6.304c.361-.728.659-1.486.889-2.265 0-.06.03-.092.06-.092s.061.032.061.091c.02.122.045.247.073.374.197.888.584 1.878.914 2.723l.176.453 1.684 4.529a.927.927 0 0 1 .092.4.473.473 0 0 1-.009.094c-.041.202-.228.272-.602.272h-6.063c-.122 0-.184-.03-.184-.092a.36.36 0 0 1 .062-.183Zm17.107-.721c0 .786-.446 1.231-1.25 1.231-.806 0-1.125-.409-1.125-1.034 0-.786.465-1.231 1.25-1.231.785 0 1.125.427 1.125 1.034ZM9.629 23.002c.803 0 1.25-.447 1.25-1.231 0-.607-.343-1.036-1.128-1.036-.785 0-1.25.447-1.25 1.231 0 .625.325 1.036 1.128 1.036Z",clipRule:"evenodd"})]}),Pf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",style:{flex:"none",lineHeight:1},viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"#3186FF"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-0)"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-1)"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-2)"}),(0,ue.jsxs)("defs",{children:[(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-0",x1:"7",x2:"11",y1:"15.5",y2:"12",children:[(0,ue.jsx)("stop",{stopColor:"#08B962"}),(0,ue.jsx)("stop",{offset:"1",stopColor:"#08B962",stopOpacity:"0"})]}),(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-1",x1:"8",x2:"11.5",y1:"5.5",y2:"11",children:[(0,ue.jsx)("stop",{stopColor:"#F94543"}),(0,ue.jsx)("stop",{offset:"1",stopColor:"#F94543",stopOpacity:"0"})]}),(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-2",x1:"3.5",x2:"17.5",y1:"13.5",y2:"12",children:[(0,ue.jsx)("stop",{stopColor:"#FABC12"}),(0,ue.jsx)("stop",{offset:".46",stopColor:"#FABC12",stopOpacity:"0"})]})]})]});var _e=b(W()),{store:Mh}=Lo(Lh);function Of(){try{return JSON.parse(document.getElementById("wp-script-module-data-options-connectors-wp-admin")?.textContent??"{}")}catch{return{}}}function ra(){return Of().connectors??{}}function Nf(){return!!Of().isFileModDisabled}var Bh={google:Pf,openai:Rf,anthropic:Ef,akismet:kf};function Hh(e,t){if(t)return(0,_e.jsx)("img",{src:t,alt:"",width:40,height:40});let o=Bh[e];return o?(0,_e.jsx)(o,{}):(0,_e.jsx)(Tf,{})}var zh=()=>(0,_e.jsx)("span",{style:{color:"#345b37",backgroundColor:"#eff8f0",padding:"4px 12px",borderRadius:"2px",fontSize:"13px",fontWeight:"var(--wpds-typography-font-weight-emphasis)",whiteSpace:"nowrap"},children:(0,lo.__)("Connected")}),Dh=({slug:e})=>(0,_e.jsx)(co,{href:(0,lo.sprintf)((0,lo.__)("https://wordpress.org/plugins/%s/"),e),openInNewTab:!0,children:(0,lo.__)("Learn more")}),jh=()=>(0,_e.jsx)(Yi,{children:(0,lo.__)("Not available")});function If({isConnected:e,showUnavailableBadge:t,pluginSlug:o,isExpanded:n,isBusy:r,pluginStatus:i,actionButtonRef:s,handleButtonClick:a,getButtonLabel:l}){return(0,_e.jsxs)(kr.__experimentalHStack,{spacing:3,expanded:!1,children:[e&&(0,_e.jsx)(zh,{}),t&&(o?(0,_e.jsx)(Dh,{slug:o}):(0,_e.jsx)(jh,{})),!t&&(0,_e.jsx)(kr.Button,{ref:s,variant:n||e?"tertiary":"secondary",size:"compact",onClick:a,disabled:i==="checking"||r,isBusy:r,accessibleWhenDisabled:!0,children:l()})]})}function Lf(e){let t=e?.replace(/\.php$/,"");return t?.includes("/")?t.split("/")[0]:t}function Fh({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="api_key"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=Lf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:m,isExpanded:u,setIsExpanded:f,isBusy:p,isConnected:g,currentApiKey:h,hasResolvedSettings:y,keySource:_,handleButtonClick:v,getButtonLabel:w,saveApiKey:R,removeApiKey:x}=oa({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),S=_==="env"||_==="constant",E=c==="not-installed"&&d===!1||c==="inactive"&&m===!1,T=(0,na.useRef)(null);return(0,_e.jsx)(Cf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:(0,_e.jsx)(If,{isConnected:g,showUnavailableBadge:E,pluginSlug:l,isExpanded:u,isBusy:p,pluginStatus:c,actionButtonRef:T,handleButtonClick:v,getButtonLabel:w}),children:u&&c==="active"&&y&&(0,_e.jsx)(Nh,{initialValue:S?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":h,helpUrl:a,readOnly:g||S,keySource:_,onRemove:S?void 0:async()=>{await x(),T.current?.focus()},onSave:async P=>{await R(P),f(!1),T.current?.focus()}},g?"connected":"setup")})}function Vh({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="application_password"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=Lf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:m,isExpanded:u,setIsExpanded:f,isBusy:p,isConnected:g,currentUsername:h,hasResolvedSettings:y,keySource:_,handleButtonClick:v,getButtonLabel:w,saveCredentials:R,removeCredentials:x}=oa({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),S=_==="env"||_==="constant",E=(0,na.useRef)(null),T=c==="not-installed"&&d===!1||c==="inactive"&&m===!1;return(0,_e.jsx)(Cf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:(0,_e.jsx)(If,{isConnected:g,showUnavailableBadge:T,pluginSlug:l,isExpanded:u,isBusy:p,pluginStatus:c,actionButtonRef:E,handleButtonClick:v,getButtonLabel:w}),children:u&&c==="active"&&y&&(0,_e.jsx)(Ih,{initialUsername:S?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":h,helpUrl:a,readOnly:g||S,keySource:_,onRemove:S?void 0:async()=>{await x(),E.current?.focus()},onSave:async P=>{await R(P),f(!1),E.current?.focus()}},g?"connected":"setup")})}function Mf(){let e=ra(),t=o=>o.replace(/[^a-z0-9-_]/gi,"-");for(let[o,n]of Object.entries(e)){if(o==="akismet"&&!n.plugin?.isInstalled)continue;let{authentication:r}=n,i=t(o),s={name:n.name,description:n.description,type:n.type,logo:Hh(o,n.logoUrl),authentication:r,plugin:n.plugin},a=Lo((0,Af.select)(Mh)).getConnector(i);r.method==="api_key"&&!a?.render?s.render=Fh:r.method==="application_password"&&!a?.render&&(s.render=Vh),Oh(i,s)}}var Pr=b(W());function Bf(){return(0,Pr.jsx)("div",{className:"ai-plugin-callout__decoration","aria-hidden":"true",children:(0,Pr.jsx)("svg",{viewBox:"0 0 248 248",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",focusable:"false",style:{width:"100%",height:"100%"},children:(0,Pr.jsx)("image",{href:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAQAElEQVR4AezdC3ojWW5tYflOzPbIbI/M9sh8+WdrdZ+KpiiKL5FB5KedwN7AeSFIpHRYmfX/PubXVGAqMBV4kQpMw3qRBzXbnApMBT4+pmHNq2AqMBV4mQpMw3qZR3X9RmeGqcCrV2Aa1qs/wdn/VOCNKjAN640e9hx1KvDqFZiG9epPcPY/FThWgZ1q07B2+mDnWFOBPVZgGtYen+qcaSqw0wpMw9rpg51jTQX2WIFpWMee6mhTganAU1ZgGtZTPpbZ1FRgKnCsAtOwjlVltKnAVOApKzAN6ykfy2zqcRWYlV6pAtOwXulpzV6nAm9egWlYb/4CmONPBV6pAtOwXulpve9e//Nw9P/7xL8d7Hy9aQWubFhvWrU59qMr8D+HBcPBna93rcA0rHd98q91bs3q3w9bBv7Bna93rMA0rHd86nPmqcCLVmAa1os+uF/Y9m8u6Q7rvw8bgLnDOhTiXb+mYb3rk3+tc//rYbsaVTjQP18amct4+h9hftt3BaZh7fv57v107rNg7+ec831WYBrWZyHGPHUF/vewu//6xNqg+HMRfyjMrb+edb5pWM/6ZGZfawX86Bc0qTU2/htVYBrWGz3sOepU4NUrMA3r1Z/g7H8q8EYVmIZ1h4c9U04FpgL3qcA0rPvUdWadCkwF7lCBaVh3KOpMORWYCtynAtOw7lPXmfVdKjDnfGgFpmE9tNyz2FRgKnBNBaZhXVO9GTsVmAo8tALTsB5a7llsKjAVuKYCv9uwrtn5jJ0KTAXergLTsN7ukc+BpwKvW4FpWK/77GbnU4G3q8A0rLd75L914Fl3KnB9BaZhXV/DmWEqMBV4UAWmYT2o0LPMVGAqcH0FpmFdX8OZYSowFfhrBe7GpmHdrbQz8VRgKnDrCkzDunVFZ76pwFTgbhWYhnW30s7EU4GpwK0rMA3r1hW9fr6ZYSowFfiiAtOwvijMyFOBqcDzVWAa1vM9k9nRVGAq8EUFpmF9UZiRpwKPqMCs8bMKTMP6Wb0meyowFfjFCkzD+sXiz9JTganAzyowDetn9ZrsqcBU4Bcr8NIN6xfrNktPBaYCv1CBaVi/UPRZciowFbisAtOwLqvbjJoKTAV+oQLTsH6h6LPkBRWYIVOBQwWmYR2KMF9TganAa1RgGtZrPKfZ5VRgKnCowDSsQxHmayowFXimCny9l2lYX9dmIlOBqcCTVWAa1pM9kNnOVGAq8HUFpmF9XZuJTAWmAk9WgWlYT/ZArt/OzDAV2G8FpmHt99nOyaYCu6vANKzdPdK7HOjfDrP+9yf4B/fP138efoeDma+pwP0rMA3r/jXewwqaVFjP8x8HAmIHd74eXIG3W24a1ts98pse+H8Os8HBzNdU4P4VmIZ1/xrvYQU/9v3L4SCwNqh/P2iwagdpvqYC96nANKz71HVmnQpMBe5QgXduWHco526n9B3W9tJ91fi7Pfwc7HkqMA3reZ7FM+/kXw+bc7EeDvTPV1z8jzC/TQXuWYFpWPes7sw9FZgK3LQC07BuWs7dTva/h5P91ye6YGfT2EP4eb9mZ/uowDSsfTzHe5/CHVXQqKzHbjX6YCpwtwpMw7pbaX808f8dsoN7oQOdr6nAVGBbgWlY24o8hvvEzXcnp1YTl3cq51ExTdRe7GldE6ev2vhTgbtV4KyGdbfV33diDeC7T9bE5T1LlezFntb94PRVG38qcLcKTMO6W2lPTuy/GPdfiJfED+6G6Lg8/m/Dnuxne7lOe5Y9/naNZv0HVGAa1gOKfMYSGkI4I/1XUp59f79SlFn0sRWYhvXYereaex/3PyunQT9iiePlPMbOKlOBJ67ANKzfeTiakvufVsdDmjgtPnYq8PYVmIb1Oy8B9z7uf06tLi7vVM7EpgJvVYFpWM/xuF1mB3dFz7Gr2cXOK/B6x5uG9RzPzH1VeI4dzS6mAk9YgWlYT/hQZktTganA8QpMwzpel1GnAlOBJ6zANKyLH8oMnApMBR5dgWlYj674rDcVmApcXIFpWBeXbgZOBaYCj67ANKxHV3zWe8UKzJ6fpALTsJ7kQcw2pgJTge8rMA3r+xpNxlRgKvAkFZiG9SQPYrYxFZgKfF+BRzSs73cxGVOBqcBU4IwKTMM6o0iTMhWYCjxHBaZhPcdzmF1MBaYCZ1RgGtYZRXrSFP9Wln/gD/htEwd/mTqNT4Nyj2ny+7/3sDgYh4NxNBYHcdrH4Tc8HOifL/E044hsmjgN0tj2Ko6DcfLE8EADcfmAg1w64IMXrcA0rNd5cN6Y3njrjnE4pvkHANP58iCNxQO+B3x11v84HA6c9+DO1ytWYBrW6zw1/6Df/FtZlz8vtYPLZ5iRv16BaVi//gjO3sD2zYb7F0mB30Q4aHBpfBqU68cjHPjl4iHNPy5oDljH4yBeLh7SxNN+Mr7cY+PFmpNtLf52/2suv9yx11TgF8ZOw/qFor/gkt7kKzrCJZox9xzf3GN3WIFpWK/xUN27hHbsuyIXyyBGZ/FAgzgrh7aO59PE5AQaiKfJ2WriNCiPPZabxsqBa8ebw9rAD9agmX+r0QcvVoFpWK/xwLzxvOFcGq87pof0OHtKE5MDLqpxwAMO4mksDfggjgMecBBPY2lsEKdBGouDOB5oEGdx4Ac8pLFpY1+sAtOwfuuBXb+uN/H1s9x2hm0zWH/8u+1KM9tbVmAa1ms8dj/SuEh2odyOXUSHtTGksadyjZETjuWm/e/BKc+4A/1g09iPw69j2kH+OHe8XHMF89GOjaeXx+LAD41nt5rcwYtVYBrWiz2wZbvehBoZ8IVYPNAgzuKw5vK32prLD8dy08xRHosDP5TLbrVtLg7lscbRWDzQIM7isObyaYMXrMA0rBd8aN9s2Y9lodQ4m/ZK1r7Duu80Np0f0n7ZzvK3qsA0rFtV8vHzeFP6r9+Bbwesy/lAgzgrh8YaC+t3I3SclRdoEGflbDU6TYwfaBBn5Ww1fN2nPB820ECcZiweaLDmyqGBcSunDV6sAtOwXuyBPWC73tTe9NulaNuLfhqsuY1nV13eOeONMRb4t4Q93HK+mevBFZiG9eCC33i5ay+S3efAui3fibjc3+o06625OH3VjKOZZ9V9aCB/1XC5q2YczTyrfq7vgt5YWMc076qN/2IVeIGG9WIVfdx2vSG9CaFVaRpDSI+zcuisxgDrHMXYFfLhO018m0eDrY6D2AoapNmjvUN7FcdDueLyQU762B1UYBrWDh7iHGEq8C4VmIa1vyfdJbTvNDqdi/Ww3g3JgfKe1TpT+2+/zpHGtne6HEgbu5MKTMPayYNcjuENC9sL7iXl765LaPi78MvOLZZ3dmc65/y3WG/meGAFpmE9sNhPuJQ7HhffT7i1i7fkTODy/eJJZuBzVmAa1nM+l2t21SW0S+fm4Qdv5lV/hR+dNNXt/p0jje1M6a9wrvY89swKTMM6s1AvnuZNHF7xKO092xnibNrYF6nAJduchnVJ1Z57jO8sQjt1aR3c8aS/inWe7f6dI43tLPSQNnYnFZiGtZMHuRzDhTOsl869gdkl9cOna7Bqz+g7i72H9hhnV00DU4O0sTupwDSsnTzIOcZU4B0qMA3rRZ/yiW27gAYX1aXxw3rf0wV9ec9qfeJ3bP9pbHv346NzqUHa2J1UYBrWTh7kcgwNKSR7E4e0V7LtnXU2e2fxQBvsvALTsHb+gD+P544nfEovZdo7u24cD6s+/k4rMA1rfw/WJTq4eO50/OANvtXjz2pdoLd/31HZp3OksTQQx1n89TEn+HsFpmH9vRRv6XjTw94O70w+Wdzbud7+PNOw9vcScLcDLqq/O52Lafgu75Xizu5M60X8K+1/9nqiAtOwThTnRUPerLD+SORTs+AN3dH4EH9W6zztv3PZdxrb3ukhbexOKrD/hrWTBzXHmApMBT4+pmHt71Xgwhn6TsQJXcIH9zs04AP/meE87b9z2Xca2/7pciBt7E4qMA1rJw9yOYY3LJxz6awRwDL85V1n96niOed/+cO+2wGmYb3bE//reXd21/PncJ3pnA8d/gyY316nAtOwXudZnbvTfzkkgovqg/vnix+8of+Ih9/SDu5Tf/nEr722fzaN7QDp8yNhFdmRnYa1o4d54ijexOFE2tOG2nu2jcbZtLE7rsA0rP09XN9ZhE7nniq440l/Fes82/07Rxr7KmeZfV5RgaVhXTHLDH2mCrhwhvXS2Zs7rHutEazaM/rO0v7Z9sgPac7kU8NpYlVkR3Ya1o4e5hzlLxWYS/e/lGMfZBrWPp7jeoouqNl0fljve3w3sl5Yl/9sVvM5tv80tj07kw8d2LSxO6nANKydPMjlGN6omhIk0wLt1dDe2c7F4uHVzjT7vaAC07AuKNoLDumeh33B7X/Yd/hYfqWxizzuXiswDWt/T9aFM6yXzvywvrnTnr0KPkRor76jsl/nSGNpII6z+GBHFZiGtaOHecFRvOnhgqFPPcSZfLL41Jt81Ob2tM40rD09zb+dxd0OuKj+m/L17y7c4euM14v4zsqZ1ov41zvF7PhoBaZhHS3LS4verOCN20F8ahY0s3Q+xJ/VOk/771z2ncauexeDVRt/BxWYhrWDhzhHmAq8SwWmYX3zpF8w7MIZ+k7EEVzCB/c7NOAD/5nhPO2/c9l3Gtv+6XIgbexOKjANaycPcjmGNyycc+msEcAy/OVdZ/ep4jnnf/nDvtsBpmG92xP/63nd88Bf1ddmzgPnfOjw2id9w91Pw9rfQ3cBDS6qOx0/eDNv9fizWp/4bffvHGlse0//+Y+EzTD2aSswDetpH81NN+ZNHG468YMma+/Zlo2zaWN3XIFpWPt7uL6zCJ0uzrrjSX+Utaa1gW9dFg+0r7Dm8strLJs2dscVmIa1v4frwhnWS2c8rCf26Rqs2j381mZrOCwO617pPghg24uckM6mseVqXs5kjrSxO6nA7RrWTgoyx3iaCmhIT7OZ2chzVGAa1nM8h1vuwgV1aN44u973uJyH8u5lfWJnbWh9Fg+tTXeJ7jultGPjxRrL4mCcM5kDH+yoAtOwdvQwP4/iDQve+J/SBx4+fuFXa7Pti8WBf2pbckK5bBp7avzEdlKBaVg7eZDfHMOPV+Gb1HPCP85pbbbB/BXpx+xXeV/px+YYbQcVmIa1g4e4OYILZ1gvnfnBm7wh8mDVil1jfcezzulSvPXFzC2eJk4DcTqLgzgN0tfxdHkgjrP4YEcVmIa1o4f5w6N4w/9wyFnp5tVgzkr+Iskc6yeHX6R9KV87/suJJ/C7FZiG9bv1v8fq7nbARfWp+eW4rIZTeT+NmdeFN/vTsfKNsyfAf4prx/90vb3nP9X5pmE91eO4yWY0C1h/JPKpWfCGbiE5sGrFrrHb+eyn9a1nbjZNnAbGirE4iJcrRhNPY2lAl8Pigx1VYBrWjh7mHGUqsPcKTMPa3xN24Qy+y+h0LtaD+x06Kwfwe8Ia9gTWtRaLgzjtK8hpoPtu7gAAEABJREFU/+Uan8Y2li4H0sbupALTsO77IH9jdm9YOOfS2uU4yL/3Xq0B6zo4nLPXddwp33zOdMs5T603sQdWYBrWA4s9Sz2kAu6u4LsPHR6ymVnkthWYhnXbej7DbC6gwUV1++EHb2Y6Kw/4tHvBj2fWgdZi29N3nwiKl2ucfbJpLA3SrYkPdlSBaVg7epgnjuJNHE6kPTzUnthTi4uvKPeYVuzhdha8fwWmYd2/xo9ewR0OrN9h8INYe+JD/FmtPR7bfxr7rHuffd2wAtOwbljMJ5nKJ2qwXjq7hA5tUxOQB/z0Z7TtnW2vLB7at+blU0PnShu7kwpMw9rJg5xjTAXeoQJP07DeodgPOqML6tCSx+56aC6rgV/uM1qf+NkjrPvDQ7rvsJxJDdLG7qQC07B28iCXY3jDgjdysjdwWHU+lPes1nnaP98+7TuNpQUxiI/dSQWmYe3kQX5zDPc94ZvUpwy3d3bdIB5WffydVmAa1v4erAtnWC+d+cEb3KlZecCnPQY/X8XFevvvOyx7TmObVRxn08bupALTsHbyIOcYf6mAZrZ+SvqX4JDXrcA0rNd9dl/t3N0NuKj+Kocux8U04HvBXs+1l+dz1TmmYV1Vvqcc7AIa1h+J/JWY4A3dxuXAqhV7Jus87d9+7c2e01ga0OWw+OBXK3Dbxadh3baeM9tUYCpwxwpMw7pjcR8wtbsaaCm+S/SQHmflpL+K9R2Ti3Ro/6zzhM4iJ8hJH7uDCkzDeu2H2Bvz0lNoBHDp+EeO03zCqXXLYU/lTewFKzAN66kf2rebc08D3yZ+kaBZXTP+i2lHngrcpwLTsO5T10fN6jIaWk/zwUN6nJWTzm457dmgsdo7tF8WD+05zspJH7uDCkzD2sFD3BzBmzQUirNpr2btPbT3OHtKKzb2xSswDet1H6A7Gt95AL+T4CFNPKTtwXZOtvPwgzNv9VUr9gx29nBGBaZhnVGkJ03xxvNXVoBvmyweaEC/9oLePM8EZ+qc63/Vnsa2Xw0MB+PSx75YBaZhvdgDm+1OBd65AtOwXvfpu7cJ6ynS2HTfYbiEhrQ9WH+tKHQe515Bx8vj0wYvWIG9NKwXLP3VW/bG04BAQzLhqtFpQQzir26dxbmB33mcO6SJywN++tgXq8A0rBd7YMt23cWERf5IYz/u+Mv8K1rqmFbsEfbY+se0R+xl1rhxBaZh3bigd5rOhfn2r6B4E9LBdw6WXjU67RZo3tYxZ5p1XGbTAA84GNf+jaMBH/iXwFhzs41vbTadxUF+uXScTRv7xBWYhvXED+fJtuZNvX4ad4vtmVMT+dFcS7Lxa7NcQme5144/a5FJul0FpmHdrpb3nMm/beXuBe65zqm5u7Q+lXMqZu+w5vjuZv2nYdbYOb753Fex5+Rvc6x/zfjtfMPvXIFpWHcu8I2m743lzdWUNG924NO9cfFAuwXMaw22+fDWWfeVxq65cmCdo/il1lywjrduKLbulb/ml7Nq4z9pBaZhPemDmW1NBaYCHx8fmyJMw9oU5AmoexXfBbBtpwtrNl2O+x9IK/8aay5Y57CGtcG6YiwO4jTAAw7iacbRrEGHNPq1MJc5oblop9Zfcxsz9gkrMA3r+R6KS2Twhv5ud3JCubg3aPyn1nhvYPanY3+abw245WW+ucwJ3+1HTvgud+JPUIFpWE/wEDZb6IJ9I59N3cnA2QM2ica6YGc3oaFTgd+twDSs363/sdV9d+Rymi2OhxqJ+FYr/285sZ9ZY829jtLAtmvJSRMvP41NE8fB/HQWB3HaLWAuc0LzrXu1Lp2VE2iDJ6/ANKwnf0Cf2/PmCp/SH5PG/hHu9Jv5V7TMJZoxp8YXu9SaP6xzpLHp/JA29okrMA3r+R6O7wZCu4uz7lzS+RC/hbVGaD5rpPHpbBpLA37AYc3lbzX5tHvBmtYAfuvgIU08jZ8+9gkqMA3rdx+CNwS0C74L95AeZ9PkuhwHfvq11hqhueJsa7E4uOg+lntMM47OGgvrePqtz2RO6wB/uz6dBvyAvwjeY5vTsH73OXvzwLFd+FHlmH5P7au93HPNY3PbBxyLjfbGFZiG9bsPvx891l1oVODTwnQ8rFoXxmLp11qX1qG57MUakMYP4sf0NPFy0+Ks+Kr7L9XVJu1aa43OxG8+fkizl2O5xcf+YgWmYf1i8Y8s7c1TE1rfsGmsnIbyIX6tNZd1Q/Ph1gY+XS4OaXQ84CCexqd9NV7s1rCWdYFvfrY9sTSQE/DBE1VgGtafh/FUv/lRKLSxOJt2L2uN0Bpx9pj2lX4q15gV5T7SHlv/mPbIPc1aJyowDetEce4c8qf4uX9dxCV08IZqa3yIX2vN1Tps87mExsG+6WuuOA3kBBzE04yjsWniNDA/ncVvAWtVa745WesEGsRZOTTg33JP5hz8sALTsH5YsCdL9yaCJ9vWVdvxiaEzsVdNdOPBmirceNqZ7icVmIb1k2rdNtcdSrh0Zn/iw6Xjn3GcS291YW+5P3PCpXO6iF/vui6dZ8ZdUYFpWFcU78qh3jzeAFDTofmELLREnJWTfmtrbmuE5rfHtPbKpomXm8amieNgHJ3FQZwGdJzFbwHnMifwzclaO9AgzsqhAR/4g1+qwDSsXyr8LDsVmAr8vALTsH5es0tGuJPxHQM0nu9iF8TpLB5oEGfl0G453lzmNLc1Ag3E0+RsNXEalMfiII7DT8Yfy01jzResA3FWDu3Y+mJygjyIs3Jo63g+bfALFfhpw/qFLe5iSZe1sF4k870hQgeNs6c0MTkBhziLAz/gIc1etppYmjge0uPiW00sTRwP6XHxrSaWJo6H9Dh7ShOTE3CIszjwAx7S7CVt7IMrMA3rwQWf5aYCU4HLKzAN6/La/WSky16XuGzj+tSJ1mUui4dy46wcuh9NcEhj8SAP4qwc2jreXmhicgINxNPk0I6Np5fH4nDp+NY6Nl7MGsE6EGfl0Na9prFygjyIs3Jo63h7oQ1+oQLTsH6h6J9LejOs+JQ/ztU+Dr/OzT2Wdxj+cUz/u/bxj1+rxi/CD+dq8s/NPZZ3yXjzGBdwiLM48AMe0ti0sQ+uwDSsxxTcn9DBXYhV2a1GT2Nx4AfjaOxWo6exOPCDcTQ2jaUBP+Cw5vK3mnwa8AMOxqTxaZDG4sAP5bJbbZuLQ3mscTQWBz4N8IBDnC2XxYM8iLP44M4VmIZ15wJ/Tu/CPXxKH3HWG4LO4oEGcRaHNZe/1dZcfpAHxqR1kbxqYvKAH+TQ2LTG09NYOV9p3uRy4KvxxoKc0JxsGisP+AGHNZe/1eTTgB9wMCbtu73KH9ypAtOw7lTYN53WG/tNj/7ix36R7U/DesyDcu+xwqr+6kkaHtLYn2ryjQs4xFkc+MFeaJDG4iCOAw78IL7VitHFV06Ls+I0wAMO4luNnsbiwA84xFk84OFczV7KdQEf0sbesQLTsO5Y3GVqnziFZD8SpfHp3jxpLA34QQ6NTbv3ePOfWkvcnqA8FgdxHPi0Y/unywlyaMak8WliaSwN+EEOjU271XjzmivggztXYBrWnQv8Ob0flcKn9BHPfnz+irOf0gc/fCy/0thkfjiliZXH4sAPOMSzNIizOPADDvEsDeIsDvyAQzxLgziLAz/gIY39qSbfuIBDnMUHd67ANKxbFPgfc3jh9u8u+ZO3iL/mEeTQXeJuNbE0Vh7wgxya+beaWBorD/hBDm0dby80sfJYGojjIId2bDxdTsDh0vGtdWy8WOuw1gF+kENb95rGlsfKA36QQ1vH2wtNrDyWFsTyx96wAtOwbljMmWoq8FkBDUyT+6RjblWBaVi3quQ/5nFfEv6hjvdOFfC3GrwG3unMDznrNKzbltmLtMtdfrN7AYd0eWn9aSyWxp4ab4wc4Mu9dLy9nBovbh1oLRYHceMBDziIpxlHY9PEaZDGOg9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4P/y8fFhLzSxNJa2Qnzl49+gAtOwblDEmWIqMBV4TAWmYV1XZ5er0Cz+JHZ/Afx0PJQvvtXE0thHjbcXa321vrj9gBy5q8angZyAg3jaT8Yfy01jm5O1DvCDHNqx9cXKY+UBP8ihreP5NLHyWBqI4yCHNrhRBaZhXV5IL0Yvyj41aiY6rH+FAw/liaex6fxwShMrj8WBH3CIs3jAwV62Gj1NHA/pcfGtJpYmjof0uPhWE0sTx0N6nD2lickJOMRZHPgBD2n2stXE0sRxSBt7owo8uGHdaNfPM417ivW/fH6enc1OpgI7rMA0rMsfqmblAtaPAM1C669qsOn8IIeu0W01epq5cUhjG8/iwJcHOPxkvHxjgR9wOLZXa5bHygN+wOHS8db4ajy9dVgc+KHx7Fbb5uJQHmscjcUDDeIsDny1B+NogxtVYBrWjQr5OY0XqAYG/E/5Aw8fn7/ibLksDvzP1A88fHz+Ek/jk9mtRk9jcTiWu2prLj/I+Wo8vTwWB364x3hzWwf4AQdrpvG3mhgN+AEHY9L4W02MBuIBH9ywAtOwLi+mOwovVOCbicUDDeKsHBqLA58GeMAhzpbL4sCXB3jAIc6Wy+JBHsRZHNZc/lZbc/kA8sAYHPhbjU4DfjiWm7bNxaGxbLksDnx5gAcc4my5LB7kQZzFYc3lb7U1V2zwgwpMw/pBsTapLtvD+sJMc/nakDT2mHZs/Fe5jTdGDvDpLB5oEGdxWHPb66qtufwg56vx9PJYHPjhHuPNbR3gBxysmcbfamI04AccjEm7Za3MPfhBBaZh/aBYkzoVmAr8bgWmYV1efxfJ27uKOCve7HhIE99qYmksDvyAQ5zFAx7O1ezlVK74qTnFHz3eeu2JxYEfcIizeMDDudotz9qaL28fdYBpWJdX2l2ET4KAbyYvfhzS6HiQQxNP49PE0lga8IMcGpt27/HmP7WWuD1BeSwO4jjwacf2T5cT5NCMSePTxNJYGvCDHBqbdu/x5j+1lrg9DS6owDSsC4r2OcS9xopP+eMSzZiPz1/88Cl9xNmP5RcekuPsKU1MTsAhzuLAX0GDSzRjjAV+wCHO4sBfQYNztZ/kHpvz0vHmMhb4AR9cUIFpWOcVzZ+K/qt2thEuYWnghUgXx0GcBngoV3yriaWxxgI/yKGta6Wx5bHygB/k0Nbx9kITK4+lgTgOcmjHxtPlBBwuHd9ax8aLtQ5rHeAHObR1r2lseaw84Ac5tHW8vdDEymNpII6DHNqx8fTBDyswDeu8gvlkyIuPPW/ED7Im9a0r4B98fOsC/OTw07DOq5aLVvcg7HkjJmsqcF4Fjv3TNOeNfMOsaVjnPXTf0rtIZRuBe7FBOouDeLl40Pjo4mnG0cTSWBrwgxyaMWl8mlgaSwN+kEMzJs1eaGJpLA3EcTCOxuIgTgM84CCeZhyNTROnQRprPzRxHIyjieGBBnFWDs0YHPg0MTzQIM7KoRmDg73QxPBAA/E042hsmjhtcEEFpmFdUFjYef8AAA5ZSURBVLQZMhW4uAIz8KoKTMP65/K5q4I14gI1FPOn5ilNvDnKY0+NF5MTHjW+vX61vnh7kmNfq8anQXksDuI4/GT8sdw01nzBOhBn5dCOrS8mJ8iDOCuHto7n08TkBBqIp8nZauI0KI/FB99UYBrWPxfIiwd6scngBxxcwKexNOCDOA54wEE8jaUBP+AQZ/GAh59q8htrLziksTiI44EGcXEc0lgcxPFAg7g4DmksDuJ4oEGcxYEf8JDG/lSTbxzYCw54wEE8jaUBH8RxwAM++KYC07C+KdCEpwJTgeepwGs1rMfUrctRl6qt6N84Cuk+MdxqYmnsT8fLNw7Wy1k8WEMeu9XoaSwO/GAcjU1jacAPOFx6VmPh0vH2+NV4evtkceCD+jWepQFfHuABhzhbLosHeRBncfjJWe0xGDv4pgLTsL4p0GfYvUP4lD7irBf0x+EXiwP/IP35wsMf4fBbnC2XxYF/SPvzhYc/wuE38TT+Qfpg09iPz1/88Cl9rLn8j8Mvtjz2IP354gc5RHar0dNYHPjBOBq71ehpLA78YByNTWNpwAdxHPg04G81Og34AQdj0vhbTYwG/HAsN00uP+CDbyowDeuvBXKf0IuNLcoPcujsVqOnsTjwg3E0dqvR01gc+ME4GrvV6GksDvxgHI1NY2nADzisufytJp8G/ICDMWl8GqSxOPBDuexW2+biUB5rHI3FgU8DPOAgnsbfamI04AccjEnjbzUxGvADDsYEfLBUYBrWUoyD64Xir1bAejmKh0Pan684axzRiw+HS8abx9hgToizOKy5/K225vKDPDAmrb2umpg84Ac5NDat8fQ0Fgd+MI72Ta0+5MsDfmg8m8bKA37AYc3lbzX5NOAHHIxJ66yrJiYP+EEOjU1rPD2NxUGuD30AHywVmIa1FONM17fwZ6ZO2gtWQMN4wW2/x5anYf31OWtGweVp0TQ2TRyHNH4QP6aniZebxqaxOPADDnEWD3g4V7OXU7nip+YUf/R467UnFgd+wCHO4gEP52r3Pqv9uMSH9jT2swLTsD4L8Wm8WPrUxo8sn/Kf/z15epp4Gp9+zng5co05NV5MHvBD49k0c8lbNTEa8IMcGpv23XjxU7ni5oTyWBzEceDTjq1PlxPk0IxJ49PE0lga8IMcGpt27/HmP7WWuD1BeSwO9ioH8HfA2WechvXPpfIjQSgaZ49pX+nHco9pl4w3j3EBhziLAz/gIY09V/tJ7rE5f2O8fVg34BBnceAHPKSx52o/yT025zq++Fvbd29Y/hSDXgR8l52wXoTioVzxtF5Y54wv99h4seZkW4sf5NDXtdLY8lh5wA9yaOt4e6GJlcfSQBwHObRj4+lyAg6Xjm+tY+PFWoe1DvCDHNq61zS2PFYeHFtrHS8u79rx5rBuwMH8adagDT4r8M4Ny4vBi2P91OazLGOmAlOBZ6zAOzcsz8PFJvBfFbPv21bAH2S3nXFmu1kF3rlhdbnJVlDf+vdXc9aL0DS2XHEcjKOzOIjTAA+tJ55mnDyxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaZDG2g9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4GAvNDE80EA8zTgamyZOgzQWB3EcjKMNPivwzg3rswRjpgJTgVepwDs3LH96bS83V43fcyyPTRPHoR8jVo1frpxwLDeNLY991Pj2+tX64vYDcuxr1fg0kBNwEE/7yfhjuWlsc7LWAX6QQzu2vlh5rDw4lrtqfHnXjjeHdQMO5k+zBg3o/3lwVu1A3+vrnRuWy3YPP/Tk4+JbTSxNHA/pcfGtJpYmjof0OHtKE5MTcIizOPADHtLsZauJpYnjIT0uvtXE0sTxkB4X32piaeJ4SI+zpzQxOQGHOIvDuhYe5ID4VqOnieMhPS6+1cTSxPGQ7gMioKe9nX3nhvV2D3sOfFYF3rohnFWhX0x654blr1j4hBBcoHoMLB5oEGdxuHS8Nb4aT7dGwCHONp7FgS8P8IBDnC2XxYM8iLM4XHpWY+HS8fb41Xi6PQYc4i6vG8+m8+VBGosDP5TLprHygB9wuPSsxsKx8XSX8OBHQ/wt8VYNa/OEPfjgBSnMbjV6GosDPxhHY7caPY3FgR+Mo7FpLA34AYc1l7/V5NOAH3AwJo2/1cRowA/HctO2uTg0li2XxYEvD/CAQ5wtl8WDPIiL48Df6qsmJg/4AYc1l7/V5NOAH47lpm1zcWgsu+aKvT3epWH5Nj/00HEvCuDTWTzQIM7KobE48LcanQb8cCw3bZuLQ2PZclkc+PIADzjE2XJZPMiDOIvDmsvfamsuP8gDY9L4W02MBvxwLDdtm4tDY9lyWRz48gAPOIin8beaGA34AQdj0vhbTYwG/ICDMWn8rSZGe0u8S8PqUxe2B+0CM6wvjDSXn8dyj2n3GG8fx9ZKs6Yc4NNZPNAgzuKw5nbWVVtz+UHOV+Pp5bE48MM9xpvbOsAPOFgzjb/VxGjgNYIDDsbg8Ey1sre3wrs0rLd6qHPYj4+PKcIuK/AuDauLUbYH6XLTHQGk8YP4MT1NvNy0OCt+TE8TlwdpLB5wiLM48AMe0thzNXs5lStuPjiWJ35MTxM3FtL4QfyYniZebhqbxuLADzjEWTzg4VzNXk7lip+aU/xW45vnbey7NCw/94ceLu6TJODTvdBwSKPjQQ5NPI1PE9tq9DRWDs0YHPg0MTzQIM7KobE43Hu8+a0D/K/Wp8sJOBiTxqcd2z+9PFYOzRgc+DQxPNAgzsqhsTjce7z5rQP8r9anywk4GJPGpx3bP/3t8C4N6+0e7Bx4KrDHChxvWPs7qYtU6E8sJ8T/7+BAOouD+CH85wsPLmCJ4mnG0dg0cRqksafGi8kJxkKclUNb1+LTxOQEGsRZOTRjcGivYniQB+JpxtHYNHEapLE4iONgHI3FQZwGeLAfmniacTSxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaW+Jd2lYXlzQJzxv+bDn0FOBV6/AuzQsdwCwXni++rOb/U8F3q4C79KwtpeYHjTNX3UA33LTWBzEaYAHjY8mnmYcjU0Tp0Eae2q8mJxgLMRZObR1LT5NTE6gQZyVQzPmXz4+PmjtVQwP8kA8zTgamyZOgzQWB3EcjKOxOIjTAA/2QxNPM44mlsbSgB/k0IxJ49PE0lga8IMcmjFp9kITS2NpII6DcTQWB3Ea4AEH8TTjaGyaOO0t8S4N6y0f7hx6KrC3Crxzw/KnlgtMcL/l2a4anwZywrHcNLa8a8ebx9rAD9agmX+riaWx8oAf5NDW8XyaWHksDcRxkLPVxGkgJ+AgnvaT8cdy09jmZK0D/CCHdmx9sfJYecAPcmjreD5NrDyWBuI4yNlq4jSQE3AQT2s8nQ/8t8U7NywX8F4AsL4AcBBPx0OaeBpLZ4M4DdJYHMTxQIM4iwM/4CGN/akm3ziwFxzwgIN4GksDPojjgAccxNNYGvBBHAc84CCextKAH3CIs3jAw081+Y21FxzSWBzE8UCDuDgOaSwO4niggb8WpJHR8Uvw8mPeuWG9/MObA7xVBXxg5N7srQ69Pew7Nyx/TccFJvRCYOmhesVZOXQvIBzSWDzIgzgrh3ZsPF1OwCHONp7FgS8PcHAuHPBQLpvGygN+wOHYXh8x3hpfrU9vnywO/NB4dqttc3EojzWOxuKBBnEWh3vUyrx+VPRM7QV/S7xzw/LgQw8f98IAfjoejmnlsuXxj+Ue08plG88ey01bc/l01jjg0wAPOIin8beaGA344Vhu2jYXh8ay5bI48OUBHnCIs+WyeJAHcRaHNZe/1dZcfpAHxqTxt5oYDfjhWG7aNheHxrJrrtjb450b1rGH735gRTlePEGczp7SxOQBPxhHY7caPY3FgR+Mo7FbjZ7G4sAPxtHYNJYG/IDDmsvfavJpwA84GJPG32piNOCHY7lp21wcGsuWy+LAlwd4wCHOlsviQR7EWRzWXP5WW3P5QR4YE/DBUoFpWEsxDq4XiotNcMl5kP588cMf4fBbnDXuIH2wOLg8/fj8hYdP6SPOGkdn8UCDOIvDmsvfamsuP8gDY9La66qJyQN+kENj0xpPT2Nx4AfjaGzatePNY07gBxzWtfhbTT4N+AEHY9La66qJyQN+kENj0xpPT2NxkOv1B3za4LMC07A+CzFmKjAVeP4KTMP66zNyZxBcnhZNY9PEcUjjB/Fjepp4uWlsGosDP+AQZ/GAh3M1ezmVK35qTvFHj7dee2Jx4Acc4iwe8PAX7UDoB/Pnix/ufVbruMQH/p8NzG9/q8A0rL/Vod+9QHwSA+4W0vEghy6exqeJbTV6GiuHZgwOfJoYHmgQZ+XQWBzuPd781gH+V+vT5QQcjEnj047tn14eK4dmDA58mhgeaBBn5dBYHO493vzWAf5X69PlBBzs1TjAB0sFpmEtxRh3KjAVeO4KTMN67ufzTLv7yQXwT3Kf6YyzlyevwF0a1pOfebZ3ugKajX8sbpvlkyyxVceP/ejiE641b/ypwE0qMA3rJmXc1STuUPxTJttDuWsRW3X8WMM6Nn4dN/5U4KIKTMO6qGwzaCowFfiNCkzD+o2q72nNOctU4IEVmIb1wGLPUlOBqcB1FZiGdV39ZvRUYCrwwApMw3pgsWepqcBrV+D3dz8N6/efwexgKjAVOLMC07DOLNSkTQWmAr9fgWlYv/8MZgdTganAmRWYhnVmoa5PmxmmAlOBayswDevaCs74qcBU4GEVmIb1sFLPQlOBqcC1FZiGdW0FZ/xU4J8rMMqdKjAN606FnWmnAlOB21dgGtbtazozTgWmAneqwDSsOxV2pp0KTAVuX4H/DwAA//9sB2hHAAAABklEQVQDAB9QlitZA9bLAAAAAElFTkSuQmCC",width:"248",height:"248",style:{mixBlendMode:"multiply"}})})})}var Rt=b(W()),Wh="ai",Yh="ai-wp-admin",ia="ai/ai",Uh="https://wordpress.org/plugins/ai/",aa=Object.values(ra()),Gh=aa.some(e=>e.type==="ai_provider"),Df=[];for(let e of aa)e.type==="ai_provider"&&e.authentication.method==="api_key"&&Df.push(e.authentication.settingName);function jf(){let[e,t]=(0,Et.useState)(!1),[o,n]=(0,Et.useState)(!1),r=(0,Et.useRef)(null);(0,Et.useEffect)(()=>{o&&r.current?.focus()},[o]);let i=(0,Et.useRef)(aa.some(R=>R.type==="ai_provider"&&R.authentication.method==="api_key"&&R.authentication.isConnected)).current,{pluginStatus:s,canInstallPlugins:a,canManagePlugins:l,hasConnectedProvider:c}=(0,un.useSelect)(R=>{let x=R(sa.store),S=!!x.canUser("create",{kind:"root",name:"plugin"}),E=x.getEntityRecord("root","site"),T=i||Df.some(H=>!!E?.[H]),P=x.getEntityRecord("root","plugin",ia);return x.hasFinishedResolution("getEntityRecord",["root","plugin",ia])?P?{pluginStatus:P.status==="active"?"active":"inactive",canInstallPlugins:S,canManagePlugins:!0,hasConnectedProvider:T}:{pluginStatus:"not-installed",canInstallPlugins:S,canManagePlugins:S,hasConnectedProvider:T}:{pluginStatus:"checking",canInstallPlugins:S,canManagePlugins:void 0,hasConnectedProvider:T}},[]),{saveEntityRecord:d}=(0,un.useDispatch)(sa.store),{createSuccessNotice:m,createErrorNotice:u}=(0,un.useDispatch)(Hf.store),f=async()=>{t(!0);try{await d("root","plugin",{slug:Wh,status:"active"},{throwOnError:!0}),n(!0),m((0,Qe.__)("AI plugin installed and activated successfully."),{id:"ai-plugin-install-success",type:"snackbar"})}catch{u((0,Qe.__)("Failed to install the AI plugin."),{id:"ai-plugin-install-error",type:"snackbar"})}finally{t(!1)}},p=async()=>{t(!0);try{await d("root","plugin",{plugin:ia,status:"active"},{throwOnError:!0}),n(!0),m((0,Qe.__)("AI plugin activated successfully."),{id:"ai-plugin-activate-success",type:"snackbar"})}catch{u((0,Qe.__)("Failed to activate the AI plugin."),{id:"ai-plugin-activate-error",type:"snackbar"})}finally{t(!1)}};if(!Gh||s==="checking"||s==="active"&&i&&!o||s==="inactive"&&l===!1)return null;let g=s==="active"&&!c,h=s==="active"&&c&&(!i||o),y=s==="not-installed"||s==="inactive",_=s==="not-installed"&&a===!1,v=()=>h?(0,Qe.__)("The AI plugin is ready to use. You can use it to generate featured images, alt text, titles, excerpts and more. Learn more"):g?(0,Qe.__)("The AI plugin is installed. Connect an AI provider below to generate featured images, alt text, titles, excerpts, and more. Learn more"):(0,Qe.__)("The AI plugin can use your AI connectors to generate featured images, alt text, titles, excerpts and more. Learn more"),w=()=>s==="not-installed"?{label:e?(0,Qe.__)("Installing\u2026"):(0,Qe.__)("Install the AI plugin"),disabled:e,onClick:e?void 0:f}:{label:e?(0,Qe.__)("Activating\u2026"):(0,Qe.__)("Activate the AI plugin"),disabled:e,onClick:e?void 0:p};return(0,Rt.jsxs)("div",{className:"ai-plugin-callout",children:[(0,Rt.jsxs)("div",{className:"ai-plugin-callout__content",children:[(0,Rt.jsx)("p",{children:(0,Et.createInterpolateElement)(v(),{strong:(0,Rt.jsx)("strong",{}),a:(0,Rt.jsx)(dn.ExternalLink,{href:Uh})})}),!_&&(y?(0,Rt.jsx)(dn.Button,{variant:"primary",size:"compact",isBusy:e,disabled:w().disabled,accessibleWhenDisabled:!0,onClick:w().onClick,children:w().label}):(0,Rt.jsx)(dn.Button,{ref:r,variant:"secondary",size:"compact",href:(0,zf.addQueryArgs)("options-general.php",{page:Yh}),children:(0,Qe.__)("Control features in the AI plugin")}))]}),(0,Rt.jsx)(Bf,{})]})}var Re=b(W()),{store:Xh}=Lo(Kh);Mf();function qh(){let e=Nf(),{connectors:t,canInstallPlugins:o,isAiPluginInstalled:n}=(0,Ff.useSelect)(c=>{let d=c(Wf.store),m=d.getEntityRecord("root","plugin","ai/ai");return{connectors:Lo(c(Xh)).getConnectors(),canInstallPlugins:d.canUser("create",{kind:"root",name:"plugin"}),isAiPluginInstalled:!!m}},[]),r=t.filter(c=>c.render),i=Array.from(new Set(t.filter(c=>c.type==="ai_provider").map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c))).sort(),s=new Set(t.filter(c=>c.plugin?.isInstalled).map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c));n&&s.add("ai");let a=["ai",...i].filter(c=>!s.has(c)),l=r.length===0;return(0,Re.jsx)($s,{title:(0,At.__)("Connectors"),subTitle:(0,At.__)("All of your API keys and credentials are stored here and shared across plugins. Configure once and use everywhere."),children:(0,Re.jsxs)("div",{className:`connectors-page${l?" connectors-page--empty":""}`,children:[a.length>0&&(e||!o)&&(0,Re.jsx)(nn.Root,{intent:"info",className:"connectors-page__file-mods-notice",children:(0,Re.jsx)(nn.Description,{children:e?(0,At.__)("Plugins cannot be installed here due to your site configuration. Install them manually using your normal deployment workflow."):(0,At.__)("You do not have permission to install plugins. Please ask a site administrator to install them for you.")})}),l?(0,Re.jsxs)(ut.__experimentalVStack,{alignment:"center",spacing:3,style:{maxWidth:480},children:[(0,Re.jsxs)(ut.__experimentalVStack,{alignment:"center",spacing:2,children:[(0,Re.jsx)(ut.__experimentalHeading,{level:2,size:15,children:(0,At.__)("No connectors yet")}),(0,Re.jsx)(ut.__experimentalText,{size:12,children:(0,At.__)("Connectors appear here when you install plugins that use external services. Each plugin registers the API keys it needs, and you manage them all in one place.")})]}),(0,Re.jsx)(ut.Button,{variant:"secondary",href:"plugin-install.php",__next40pxDefaultSize:!0,children:(0,At.__)("Learn more")})]}):(0,Re.jsxs)(ut.__experimentalVStack,{spacing:3,children:[(0,Re.jsx)(jf,{}),(0,Re.jsx)(ut.__experimentalVStack,{spacing:3,role:"list",children:t.map(c=>c.render?(0,Re.jsx)(c.render,{slug:c.slug,name:c.name,description:c.description,type:c.type,logo:c.logo,authentication:c.authentication,plugin:c.plugin},c.slug):null)})]}),o&&!e&&(0,Re.jsx)("p",{children:(0,Vf.createInterpolateElement)((0,At.__)("If the connector you need is not listed, search the plugin directory to see if a connector is available."),{a:(0,Re.jsx)("a",{href:"plugin-install.php?s=connector&tab=search&type=tag"})})})]})})}function Zh(){return(0,Re.jsx)(qh,{})}var Qh=Zh;export{Qh as stage}; /*! Bundled license information: use-sync-external-store/cjs/use-sync-external-store-shim.production.js: diff --git a/src/wp-includes/build/routes/font-list/content.js b/src/wp-includes/build/routes/font-list/content.js index 9683f74f08a9b..6f0404e093d80 100644 --- a/src/wp-includes/build/routes/font-list/content.js +++ b/src/wp-includes/build/routes/font-list/content.js @@ -78,7 +78,7 @@ var require_use_sync_external_store_shim_development = __commonJS({ return x2 === y2 && (0 !== x2 || 1 / x2 === 1 / y2) || x2 !== x2 && y2 !== y2; } function useSyncExternalStore$2(subscribe, getSnapshot) { - didWarnOld18Alpha || void 0 === React49.startTransition || (didWarnOld18Alpha = true, console.error( + didWarnOld18Alpha || void 0 === React48.startTransition || (didWarnOld18Alpha = true, console.error( "You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release." )); var value = getSnapshot(); @@ -126,8 +126,8 @@ var require_use_sync_external_store_shim_development = __commonJS({ return getSnapshot(); } "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error()); - var React49 = require_react(), objectIs = "function" === typeof Object.is ? Object.is : is, useState28 = React49.useState, useEffect20 = React49.useEffect, useLayoutEffect4 = React49.useLayoutEffect, useDebugValue2 = React49.useDebugValue, didWarnOld18Alpha = false, didWarnUncachedGetSnapshot = false, shim = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2; - exports.useSyncExternalStore = void 0 !== React49.useSyncExternalStore ? React49.useSyncExternalStore : shim; + var React48 = require_react(), objectIs = "function" === typeof Object.is ? Object.is : is, useState28 = React48.useState, useEffect20 = React48.useEffect, useLayoutEffect4 = React48.useLayoutEffect, useDebugValue2 = React48.useDebugValue, didWarnOld18Alpha = false, didWarnUncachedGetSnapshot = false, shim = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2; + exports.useSyncExternalStore = void 0 !== React48.useSyncExternalStore ? React48.useSyncExternalStore : shim; "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error()); })(); } @@ -154,14 +154,14 @@ var require_with_selector_development = __commonJS({ return x2 === y2 && (0 !== x2 || 1 / x2 === 1 / y2) || x2 !== x2 && y2 !== y2; } "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error()); - var React49 = require_react(), shim = require_shim(), objectIs = "function" === typeof Object.is ? Object.is : is, useSyncExternalStore2 = shim.useSyncExternalStore, useRef23 = React49.useRef, useEffect20 = React49.useEffect, useMemo30 = React49.useMemo, useDebugValue2 = React49.useDebugValue; + var React48 = require_react(), shim = require_shim(), objectIs = "function" === typeof Object.is ? Object.is : is, useSyncExternalStore3 = shim.useSyncExternalStore, useRef22 = React48.useRef, useEffect20 = React48.useEffect, useMemo32 = React48.useMemo, useDebugValue2 = React48.useDebugValue; exports.useSyncExternalStoreWithSelector = function(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) { - var instRef = useRef23(null); + var instRef = useRef22(null); if (null === instRef.current) { var inst = { hasValue: false, value: null }; instRef.current = inst; } else inst = instRef.current; - instRef = useMemo30( + instRef = useMemo32( function() { function memoizedSelector(nextSnapshot) { if (!hasMemo) { @@ -196,7 +196,7 @@ var require_with_selector_development = __commonJS({ }, [getSnapshot, getServerSnapshot, selector, isEqual] ); - var value = useSyncExternalStore2(subscribe, instRef[0], instRef[1]); + var value = useSyncExternalStore3(subscribe, instRef[0], instRef[1]); useEffect20( function() { inst.hasValue = true; @@ -498,16 +498,16 @@ function clsx() { var clsx_default = clsx; // node_modules/@base-ui/utils/safeReact.mjs -var React2 = __toESM(require_react(), 1); +var React = __toESM(require_react(), 1); var SafeReact = { - ...React2 + ...React }; // node_modules/@base-ui/utils/useRefWithInit.mjs -var React3 = __toESM(require_react(), 1); +var React2 = __toESM(require_react(), 1); var UNINITIALIZED = {}; function useRefWithInit(init, initArg) { - const ref = React3.useRef(UNINITIALIZED); + const ref = React2.useRef(UNINITIALIZED); if (ref.current === UNINITIALIZED) { ref.current = init(initArg); } @@ -547,12 +547,6 @@ function assertNotCalled() { } } -// node_modules/@base-ui/utils/useIsoLayoutEffect.mjs -var React4 = __toESM(require_react(), 1); -var noop = () => { -}; -var useIsoLayoutEffect = typeof document !== "undefined" ? React4.useLayoutEffect : noop; - // node_modules/@base-ui/utils/warn.mjs var set; if (true) { @@ -568,17 +562,14 @@ function warn(...messages) { } } -// node_modules/@base-ui/react/internals/direction-context/DirectionContext.mjs -var React5 = __toESM(require_react(), 1); -var DirectionContext = /* @__PURE__ */ React5.createContext(void 0); -if (true) DirectionContext.displayName = "DirectionContext"; -function useDirection() { - const context = React5.useContext(DirectionContext); - return context?.direction ?? "ltr"; -} +// node_modules/@base-ui/utils/useIsoLayoutEffect.mjs +var React3 = __toESM(require_react(), 1); +var noop = () => { +}; +var useIsoLayoutEffect = typeof document !== "undefined" ? React3.useLayoutEffect : noop; // node_modules/@base-ui/react/internals/useRenderElement.mjs -var React8 = __toESM(require_react(), 1); +var React6 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/useMergedRefs.mjs function useMergedRefs(a2, b2, c2, d2) { @@ -653,7 +644,7 @@ function update(forkRef, refs) { if (typeof cleanupCallback === "function") { cleanupCallback(); } else { - ref(null); + void ref(null); } break; } @@ -670,18 +661,18 @@ function update(forkRef, refs) { } // node_modules/@base-ui/utils/getReactElementRef.mjs -var React7 = __toESM(require_react(), 1); +var React5 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/reactVersion.mjs -var React6 = __toESM(require_react(), 1); -var majorVersion = parseInt(React6.version, 10); +var React4 = __toESM(require_react(), 1); +var majorVersion = parseInt(React4.version, 10); function isReactVersionAtLeast(reactVersionToCheck) { return majorVersion >= reactVersionToCheck; } // node_modules/@base-ui/utils/getReactElementRef.mjs function getReactElementRef(element) { - if (!/* @__PURE__ */ React7.isValidElement(element)) { + if (!/* @__PURE__ */ React5.isValidElement(element)) { return null; } const reactElement = element; @@ -919,17 +910,17 @@ function useRenderElementProps(componentProps, params = {}) { state = EMPTY_OBJECT, ref, props, - stateAttributesMapping: stateAttributesMapping3, + stateAttributesMapping, enabled = true } = params; const className = enabled ? resolveClassName(classNameProp, state) : void 0; const style = enabled ? resolveStyle(styleProp, state) : void 0; - const stateProps = enabled ? getStateAttributesProps(state, stateAttributesMapping3) : EMPTY_OBJECT; + const stateProps = enabled ? getStateAttributesProps(state, stateAttributesMapping) : EMPTY_OBJECT; const resolvedProps = enabled && props ? resolveRenderFunctionProps(props) : void 0; const outProps = enabled ? mergeObjects(stateProps, resolvedProps) ?? {} : EMPTY_OBJECT; if (typeof document !== "undefined") { if (!enabled) { - useMergedRefs(null, null); + void useMergedRefs(null, null); } else if (Array.isArray(ref)) { outProps.ref = useMergedRefsN([outProps.ref, getReactElementRef(renderProp), ...ref]); } else { @@ -968,15 +959,15 @@ function evaluateRenderProp(element, render, props, state) { mergedProps.ref = props.ref; let newElement = render; if (newElement?.$$typeof === REACT_LAZY_TYPE) { - const children = React8.Children.toArray(render); + const children = React6.Children.toArray(render); newElement = children[0]; } if (true) { - if (!/* @__PURE__ */ React8.isValidElement(newElement)) { + if (!/* @__PURE__ */ React6.isValidElement(newElement)) { throw new Error(["Base UI: The `render` prop was provided an invalid React element as `React.isValidElement(render)` is `false`.", "A valid React element must be provided to the `render` prop because it is cloned with props to replace the default element.", "https://base-ui.com/r/invalid-render-prop"].join("\n")); } } - return /* @__PURE__ */ React8.cloneElement(newElement, mergedProps); + return /* @__PURE__ */ React6.cloneElement(newElement, mergedProps); } if (element) { if (typeof element === "string") { @@ -1013,16 +1004,16 @@ function renderTag(Tag, props) { key: props.key }); } - return /* @__PURE__ */ React8.createElement(Tag, props); + return /* @__PURE__ */ React6.createElement(Tag, props); } // node_modules/@base-ui/utils/useId.mjs -var React9 = __toESM(require_react(), 1); +var React7 = __toESM(require_react(), 1); var globalId = 0; function useGlobalId(idOverride, prefix = "mui") { - const [defaultId, setDefaultId] = React9.useState(idOverride); + const [defaultId, setDefaultId] = React7.useState(idOverride); const id = idOverride || defaultId; - React9.useEffect(() => { + React7.useEffect(() => { if (defaultId == null) { globalId += 1; setDefaultId(`${prefix}-${globalId}`); @@ -1146,17 +1137,16 @@ function createChangeEventDetails(reason, event, trigger, customProperties) { } // node_modules/@base-ui/react/internals/useTransitionStatus.mjs -var React11 = __toESM(require_react(), 1); +var React9 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/useOnMount.mjs -var React10 = __toESM(require_react(), 1); -var EMPTY = []; +var React8 = __toESM(require_react(), 1); function useOnMount(fn) { - React10.useEffect(fn, EMPTY); + React8.useEffect(fn, EMPTY_ARRAY); } // node_modules/@base-ui/utils/useAnimationFrame.mjs -var EMPTY2 = null; +var EMPTY = null; var LAST_RAF = globalThis.requestAnimationFrame; var Scheduler = class { /* This implementation uses an array as a backing data-structure for frame callbacks. @@ -1216,21 +1206,21 @@ var AnimationFrame = class _AnimationFrame { static cancel(id) { return scheduler.cancel(id); } - currentId = EMPTY2; + currentId = EMPTY; /** * Executes `fn` after `delay`, clearing any previously scheduled call. */ request(fn) { this.cancel(); this.currentId = scheduler.request(() => { - this.currentId = EMPTY2; + this.currentId = EMPTY; fn(); }); } cancel = () => { - if (this.currentId !== EMPTY2) { + if (this.currentId !== EMPTY) { scheduler.cancel(this.currentId); - this.currentId = EMPTY2; + this.currentId = EMPTY; } }; disposeEffect = () => { @@ -1245,8 +1235,8 @@ function useAnimationFrame() { // node_modules/@base-ui/react/internals/useTransitionStatus.mjs function useTransitionStatus(open, enableIdleState = false, deferEndingState = false) { - const [transitionStatus, setTransitionStatus] = React11.useState(open && enableIdleState ? "idle" : void 0); - const [mounted, setMounted] = React11.useState(open); + const [transitionStatus, setTransitionStatus] = React9.useState(open && enableIdleState ? "idle" : void 0); + const [mounted, setMounted] = React9.useState(open); if (open && !mounted) { setMounted(true); setTransitionStatus("starting"); @@ -1307,10 +1297,10 @@ var TransitionStatusDataAttributes = /* @__PURE__ */ (function(TransitionStatusD return TransitionStatusDataAttributes2; })({}); var STARTING_HOOK = { - [TransitionStatusDataAttributes.startingStyle]: "" + "data-starting-style": "" }; var ENDING_HOOK = { - [TransitionStatusDataAttributes.endingStyle]: "" + "data-ending-style": "" }; var transitionStatusMapping = { transitionStatus(value) { @@ -1480,6 +1470,11 @@ function getFrameElement(win) { return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null; } +// node_modules/@base-ui/utils/owner.mjs +function ownerDocument(node) { + return node?.ownerDocument || document; +} + // node_modules/@base-ui/utils/addEventListener.mjs function addEventListener(target, type, listener, options) { target.addEventListener(type, listener, options); @@ -1506,13 +1501,8 @@ function createLatestRef(value) { return latest; } -// node_modules/@base-ui/utils/owner.mjs -function ownerDocument(node) { - return node?.ownerDocument || document; -} - // node_modules/@base-ui/react/internals/useOpenChangeComplete.mjs -var React12 = __toESM(require_react(), 1); +var React10 = __toESM(require_react(), 1); // node_modules/@base-ui/react/internals/useAnimationsFinished.mjs var ReactDOM = __toESM(require_react_dom(), 1); @@ -1526,7 +1516,7 @@ function resolveRef(maybeRef) { } // node_modules/@base-ui/react/internals/useAnimationsFinished.mjs -function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false, treatAbortedAsFinished = true) { +function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false) { const frame = useAnimationFrame(); return useStableCallback((fnToExecute, signal = null) => { frame.cancel(); @@ -1547,21 +1537,20 @@ function useAnimationsFinished(elementOrRef, waitForStartingStyleRemoved = false if (!signal?.aborted) { done(); } - }).catch(() => { - if (treatAbortedAsFinished) { - if (!signal?.aborted) { - done(); - } + }, () => { + if (signal?.aborted) { return; } const currentAnimations = resolvedElement.getAnimations(); - if (!signal?.aborted && currentAnimations.length > 0 && currentAnimations.some((animation) => animation.pending || animation.playState !== "finished")) { + if (currentAnimations.some((animation) => animation.pending || animation.playState !== "finished")) { exec(); + return; } + done(); }); } if (waitForStartingStyleRemoved) { - const startingStyleAttribute = TransitionStatusDataAttributes.startingStyle; + const startingStyleAttribute = "data-starting-style"; if (!resolvedElement.hasAttribute(startingStyleAttribute)) { frame.request(exec); return; @@ -1594,8 +1583,8 @@ function useOpenChangeComplete(parameters) { onComplete: onCompleteParam } = parameters; const onComplete = useStableCallback(onCompleteParam); - const runOnceAnimationsFinish = useAnimationsFinished(ref, open, false); - React12.useEffect(() => { + const runOnceAnimationsFinish = useAnimationsFinished(ref, open); + React10.useEffect(() => { if (!enabled) { return void 0; } @@ -1607,16 +1596,6 @@ function useOpenChangeComplete(parameters) { }, [enabled, open, onComplete, runOnceAnimationsFinish]); } -// node_modules/@base-ui/utils/useOnFirstRender.mjs -var React13 = __toESM(require_react(), 1); -function useOnFirstRender(fn) { - const ref = React13.useRef(true); - if (ref.current) { - ref.current = false; - fn(); - } -} - // node_modules/@base-ui/utils/platform/parts.mjs var parts_exports = {}; __export(parts_exports, { @@ -1708,29 +1687,29 @@ __export(env_exports, { var jsdom = /jsdom|happydom/.test(lowerUserAgent); // node_modules/@base-ui/utils/useTimeout.mjs -var EMPTY3 = 0; +var EMPTY2 = 0; var Timeout = class _Timeout { static create() { return new _Timeout(); } - currentId = EMPTY3; + currentId = EMPTY2; /** * Executes `fn` after `delay`, clearing any previously scheduled call. */ start(delay, fn) { this.clear(); this.currentId = setTimeout(() => { - this.currentId = EMPTY3; + this.currentId = EMPTY2; fn(); }, delay); } isStarted() { - return this.currentId !== EMPTY3; + return this.currentId !== EMPTY2; } clear = () => { - if (this.currentId !== EMPTY3) { + if (this.currentId !== EMPTY2) { clearTimeout(this.currentId); - this.currentId = EMPTY3; + this.currentId = EMPTY2; } }; disposeEffect = () => { @@ -1744,7 +1723,7 @@ function useTimeout() { } // node_modules/@base-ui/react/floating-ui-react/components/FloatingDelayGroup.mjs -var React14 = __toESM(require_react(), 1); +var React11 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/utils/event.mjs function isReactEvent(event) { @@ -1878,7 +1857,7 @@ function isHoverOpenEvent(openEventType) { // node_modules/@base-ui/react/floating-ui-react/components/FloatingDelayGroup.mjs var import_jsx_runtime = __toESM(require_jsx_runtime(), 1); -var FloatingDelayGroupContext = /* @__PURE__ */ React14.createContext({ +var FloatingDelayGroupContext = /* @__PURE__ */ React11.createContext({ hasProvider: false, timeoutMs: 0, delayRef: { @@ -1905,10 +1884,10 @@ function FloatingDelayGroup(props) { delay, timeoutMs = 0 } = props; - const delayRef = React14.useRef(delay); - const initialDelayRef = React14.useRef(delay); - const currentIdRef = React14.useRef(null); - const currentContextRef = React14.useRef(null); + const delayRef = React11.useRef(delay); + const initialDelayRef = React11.useRef(delay); + const currentIdRef = React11.useRef(null); + const currentContextRef = React11.useRef(null); const timeout = useTimeout(); useIsoLayoutEffect(() => { initialDelayRef.current = delay; @@ -1922,7 +1901,7 @@ function FloatingDelayGroup(props) { }; }, [delay, currentIdRef, delayRef, initialDelayRef]); return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(FloatingDelayGroupContext.Provider, { - value: React14.useMemo(() => ({ + value: React11.useMemo(() => ({ hasProvider: true, delayRef, initialDelayRef, @@ -1942,7 +1921,7 @@ function useDelayGroup(context, options = { } = options; const store = "rootStore" in context ? context.rootStore : context; const floatingId = store.useState("floatingId"); - const groupContext = React14.useContext(FloatingDelayGroupContext); + const groupContext = React11.useContext(FloatingDelayGroupContext); const { currentIdRef, delayRef, @@ -1952,22 +1931,13 @@ function useDelayGroup(context, options = { hasProvider, timeout } = groupContext; - const [isInstantPhase, setIsInstantPhase] = React14.useState(false); - const openRef = React14.useRef(open); - const isUnmountedRef = React14.useRef(false); + const [isInstantPhase, setIsInstantPhase] = React11.useState(false); + const openRef = React11.useRef(open); useIsoLayoutEffect(() => { openRef.current = open; }, [open]); - useIsoLayoutEffect(() => { - return () => { - isUnmountedRef.current = true; - }; - }, []); useIsoLayoutEffect(() => { function unset() { - if (!isUnmountedRef.current) { - setIsInstantPhase(false); - } currentContextRef.current?.setIsInstantPhase(false); currentIdRef.current = null; currentContextRef.current = null; @@ -2035,7 +2005,7 @@ function useDelayGroup(context, options = { } }; }, [currentContextRef, currentIdRef, delayRef, floatingId, initialDelayRef, timeout]); - return React14.useMemo(() => ({ + return React11.useMemo(() => ({ hasProvider, delayRef, isInstantPhase @@ -2055,7 +2025,7 @@ function mergeCleanups(...cleanups) { } // node_modules/@base-ui/react/utils/FocusGuard.mjs -var React15 = __toESM(require_react(), 1); +var React12 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/visuallyHidden.mjs var visuallyHiddenBase = { @@ -2081,8 +2051,8 @@ var visuallyHiddenInput = { // node_modules/@base-ui/react/utils/FocusGuard.mjs var import_jsx_runtime2 = __toESM(require_jsx_runtime(), 1); -var FocusGuard = /* @__PURE__ */ React15.forwardRef(function FocusGuard2(props, ref) { - const [role, setRole] = React15.useState(); +var FocusGuard = /* @__PURE__ */ React12.forwardRef(function FocusGuard2(props, ref) { + const [role, setRole] = React12.useState(); useIsoLayoutEffect(() => { if (parts_exports.screenReader.voiceOver && parts_exports.engine.webkit) { setRole("button"); @@ -2105,7 +2075,6 @@ var FocusGuard = /* @__PURE__ */ React15.forwardRef(function FocusGuard2(props, if (true) FocusGuard.displayName = "FocusGuard"; // node_modules/@floating-ui/utils/dist/floating-ui.utils.mjs -var sides = ["top", "right", "bottom", "left"]; var min = Math.min; var max = Math.max; var round = Math.round; @@ -2427,7 +2396,7 @@ function createAttribute(name2) { } // node_modules/@base-ui/react/floating-ui-react/components/FloatingPortal.mjs -var React16 = __toESM(require_react(), 1); +var React13 = __toESM(require_react(), 1); var ReactDOM2 = __toESM(require_react_dom(), 1); // node_modules/@base-ui/react/internals/constants.mjs @@ -2452,9 +2421,9 @@ var ownerVisuallyHidden = { // node_modules/@base-ui/react/floating-ui-react/components/FloatingPortal.mjs var import_jsx_runtime3 = __toESM(require_jsx_runtime(), 1); -var PortalContext = /* @__PURE__ */ React16.createContext(null); +var PortalContext = /* @__PURE__ */ React13.createContext(null); if (true) PortalContext.displayName = "PortalContext"; -var usePortalContext = () => React16.useContext(PortalContext); +var usePortalContext = () => React13.useContext(PortalContext); var attr = createAttribute("portal"); function useFloatingPortalNode(props = {}) { const { @@ -2466,14 +2435,14 @@ function useFloatingPortalNode(props = {}) { const uniqueId = useId(); const portalContext = usePortalContext(); const parentPortalNode = portalContext?.portalNode; - const [containerElement, setContainerElement] = React16.useState(null); - const [portalNode, setPortalNode] = React16.useState(null); + const [containerElement, setContainerElement] = React13.useState(null); + const [portalNode, setPortalNode] = React13.useState(null); const setPortalNodeRef = useStableCallback((node) => { if (node !== null) { setPortalNode(node); } }); - const containerRef = React16.useRef(null); + const containerRef = React13.useRef(null); useIsoLayoutEffect(() => { if (containerProp === null) { if (containerRef.current) { @@ -2483,9 +2452,6 @@ function useFloatingPortalNode(props = {}) { } return; } - if (uniqueId == null) { - return; - } const resolvedContainer = (containerProp && (isNode(containerProp) ? containerProp : containerProp.current)) ?? parentPortalNode ?? document.body; if (resolvedContainer == null) { if (containerRef.current) { @@ -2500,7 +2466,7 @@ function useFloatingPortalNode(props = {}) { setPortalNode(null); setContainerElement(resolvedContainer); } - }, [containerProp, parentPortalNode, uniqueId]); + }, [containerProp, parentPortalNode]); const portalElement = useRenderElement("div", componentProps, { ref: [ref, setPortalNodeRef], props: [{ @@ -2510,39 +2476,42 @@ function useFloatingPortalNode(props = {}) { }); const portalSubtree = containerElement && portalElement ? /* @__PURE__ */ ReactDOM2.createPortal(portalElement, containerElement) : null; return { - portalNode, - portalSubtree + node: portalNode, + // `id` and `render` props can override or remove the generated ID. Use the exact + // rendered value so `aria-owns` never points at an ID absent from the DOM. + nodeId: /* @__PURE__ */ React13.isValidElement(portalElement) ? portalElement.props.id : void 0, + subtree: portalSubtree }; } -var FloatingPortal = /* @__PURE__ */ React16.forwardRef(function FloatingPortal2(componentProps, forwardedRef) { +var FloatingPortal = /* @__PURE__ */ React13.forwardRef(function FloatingPortal2(componentProps, forwardedRef) { const { render, className, style, children, container, - renderGuards, ...elementProps } = componentProps; const { - portalNode, - portalSubtree + node: portalNode, + nodeId: portalNodeId, + subtree: portalSubtree } = useFloatingPortalNode({ container, ref: forwardedRef, componentProps, elementProps }); - const beforeOutsideRef = React16.useRef(null); - const afterOutsideRef = React16.useRef(null); - const beforeInsideRef = React16.useRef(null); - const afterInsideRef = React16.useRef(null); - const [focusManagerState, setFocusManagerState] = React16.useState(null); - const focusInsideDisabledRef = React16.useRef(false); + const beforeOutsideRef = React13.useRef(null); + const afterOutsideRef = React13.useRef(null); + const beforeInsideRef = React13.useRef(null); + const afterInsideRef = React13.useRef(null); + const [focusManagerState, setFocusManagerState] = React13.useState(null); + const focusInsideDisabledRef = React13.useRef(false); const modal = focusManagerState?.modal; const open = focusManagerState?.open; - const shouldRenderGuards = typeof renderGuards === "boolean" ? renderGuards : !!focusManagerState && !focusManagerState.modal && focusManagerState.open && !!portalNode; - React16.useEffect(() => { + const shouldRenderGuards = !!focusManagerState && !focusManagerState.modal && focusManagerState.open && !!portalNode; + React13.useEffect(() => { if (!portalNode || modal) { return void 0; } @@ -2568,7 +2537,7 @@ var FloatingPortal = /* @__PURE__ */ React16.forwardRef(function FloatingPortal2 enableFocusInside(portalNode); focusInsideDisabledRef.current = false; }, [open, portalNode]); - const portalContextValue = React16.useMemo(() => ({ + const portalContextValue = React13.useMemo(() => ({ beforeOutsideRef, afterOutsideRef, beforeInsideRef, @@ -2576,7 +2545,7 @@ var FloatingPortal = /* @__PURE__ */ React16.forwardRef(function FloatingPortal2 portalNode, setFocusManagerState }), [portalNode]); - return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(React16.Fragment, { + return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(React13.Fragment, { children: [portalSubtree, /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)(PortalContext.Provider, { value: portalContextValue, children: [shouldRenderGuards && portalNode && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(FocusGuard, { @@ -2592,7 +2561,7 @@ var FloatingPortal = /* @__PURE__ */ React16.forwardRef(function FloatingPortal2 } } }), shouldRenderGuards && portalNode && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("span", { - "aria-owns": portalNode.id, + "aria-owns": portalNodeId, style: ownerVisuallyHidden }), portalNode && /* @__PURE__ */ ReactDOM2.createPortal(children, portalNode), shouldRenderGuards && portalNode && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(FocusGuard, { "data-type": "outside", @@ -2616,7 +2585,7 @@ var FloatingPortal = /* @__PURE__ */ React16.forwardRef(function FloatingPortal2 if (true) FloatingPortal.displayName = "FloatingPortal"; // node_modules/@base-ui/react/floating-ui-react/components/FloatingTree.mjs -var React17 = __toESM(require_react(), 1); +var React14 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/utils/createEventEmitter.mjs function createEventEmitter() { @@ -2639,18 +2608,18 @@ function createEventEmitter() { // node_modules/@base-ui/react/floating-ui-react/components/FloatingTree.mjs var import_jsx_runtime4 = __toESM(require_jsx_runtime(), 1); -var FloatingNodeContext = /* @__PURE__ */ React17.createContext(null); +var FloatingNodeContext = /* @__PURE__ */ React14.createContext(null); if (true) FloatingNodeContext.displayName = "FloatingNodeContext"; -var FloatingTreeContext = /* @__PURE__ */ React17.createContext(null); +var FloatingTreeContext = /* @__PURE__ */ React14.createContext(null); if (true) FloatingTreeContext.displayName = "FloatingTreeContext"; -var useFloatingParentNodeId = () => React17.useContext(FloatingNodeContext)?.id || null; +var useFloatingParentNodeId = () => React14.useContext(FloatingNodeContext)?.id || null; var useFloatingTree = (externalTree) => { - const contextTree = React17.useContext(FloatingTreeContext); + const contextTree = React14.useContext(FloatingTreeContext); return externalTree ?? contextTree; }; // node_modules/@base-ui/react/floating-ui-react/hooks/useClientPoint.mjs -var React18 = __toESM(require_react(), 1); +var React15 = __toESM(require_react(), 1); function createVirtualElement(domElement, data) { let offsetX = null; let offsetY = null; @@ -2717,10 +2686,10 @@ function useClientPoint(context, props = {}) { const floating = store.useState("floatingElement"); const domReference = store.useState("domReferenceElement"); const dataRef = store.context.dataRef; - const initialRef = React18.useRef(false); - const cleanupListenerRef = React18.useRef(null); - const [pointerType, setPointerType] = React18.useState(); - const [reactive, setReactive] = React18.useState([]); + const initialRef = React15.useRef(false); + const cleanupListenerRef = React15.useRef(null); + const [pointerType, setPointerType] = React15.useState(); + const [reactive, setReactive] = React15.useState([]); const resetReference = useStableCallback((reference2) => { store.set("positionReference", reference2); }); @@ -2748,7 +2717,7 @@ function useClientPoint(context, props = {}) { } }); const openCheck = isMouseLikePointerType(pointerType) ? floating : open; - React18.useEffect(() => { + React15.useEffect(() => { if (!enabled) { resetReference(domReference); return void 0; @@ -2776,20 +2745,20 @@ function useClientPoint(context, props = {}) { } return cleanupListener; }, [openCheck, enabled, floating, dataRef, domReference, store, setReference, resetReference, reactive]); - React18.useEffect(() => () => { + React15.useEffect(() => () => { store.set("positionReference", null); }, [store]); - React18.useEffect(() => { + React15.useEffect(() => { if (enabled && !floating) { initialRef.current = false; } }, [enabled, floating]); - React18.useEffect(() => { + React15.useEffect(() => { if (!enabled && open) { initialRef.current = true; } }, [enabled, open]); - const reference = React18.useMemo(() => { + const reference = React15.useMemo(() => { function setPointerTypeRef(event) { setPointerType(event.pointerType); } @@ -2800,14 +2769,14 @@ function useClientPoint(context, props = {}) { onMouseEnter: handleReferenceEnterOrMove }; }, [handleReferenceEnterOrMove]); - return React18.useMemo(() => enabled ? { + return React15.useMemo(() => enabled ? { reference, trigger: reference } : {}, [enabled, reference]); } // node_modules/@base-ui/react/floating-ui-react/hooks/useDismiss.mjs -var React19 = __toESM(require_react(), 1); +var React16 = __toESM(require_react(), 1); function alwaysFalse() { return false; } @@ -2842,12 +2811,12 @@ function useDismiss(context, props = {}) { escapeKey: escapeKeyBubbles, outsidePress: outsidePressBubbles } = normalizeProp(bubbles); - const pressStartedInsideRef = React19.useRef(false); - const pressStartPreventedRef = React19.useRef(false); - const suppressNextOutsideClickRef = React19.useRef(false); - const isComposingRef = React19.useRef(false); - const currentPointerTypeRef = React19.useRef(""); - const touchStateRef = React19.useRef(null); + const pressStartedInsideRef = React16.useRef(false); + const pressStartPreventedRef = React16.useRef(false); + const suppressNextOutsideClickRef = React16.useRef(false); + const isComposingRef = React16.useRef(false); + const currentPointerTypeRef = React16.useRef(""); + const touchStateRef = React16.useRef(null); const cancelDismissOnEndTimeout = useTimeout(); const clearInsideReactTreeTimeout = useTimeout(); const clearInsideReactTree = useStableCallback(() => { @@ -2916,9 +2885,9 @@ function useDismiss(context, props = {}) { pressStartPreventedRef.current = true; } }); - React19.useEffect(() => { + React16.useEffect(() => { if (!open || !enabled) { - return void 0; + return clearInsideReactTree; } dataRef.current.__escapeKeyBubbles = escapeKeyBubbles; dataRef.current.__outsidePressBubbles = outsidePressBubbles; @@ -3164,15 +3133,15 @@ function useDismiss(context, props = {}) { preventedPressSuppressionTimeout.clear(); resetPressStartState(); suppressNextOutsideClickRef.current = false; + clearInsideReactTree(); }; }, [dataRef, floatingElement, escapeKey2, outsidePressEnabled, outsidePress2, open, enabled, escapeKeyBubbles, outsidePressBubbles, closeOnEscapeKeyDown, clearInsideReactTree, getOutsidePressEventProp, hasBlockingChild, isEventWithinOwnElements, tree, store, cancelDismissOnEndTimeout]); - React19.useEffect(clearInsideReactTree, [outsidePress2, clearInsideReactTree]); - const reference = React19.useMemo(() => ({ + const reference = React16.useMemo(() => ({ onKeyDown: closeOnEscapeKeyDown, onPointerDown: closeOnReferencePress, onClick: closeOnReferencePress }), [closeOnEscapeKeyDown, closeOnReferencePress]); - const floating = React19.useMemo(() => ({ + const floating = React16.useMemo(() => ({ onKeyDown: closeOnEscapeKeyDown, // `onMouseDown` may be blocked if `event.preventDefault()` is called in // `onPointerDown`, such as with . @@ -3192,7 +3161,7 @@ function useDismiss(context, props = {}) { onTouchEndCapture: markInsideReactTree, onTouchMoveCapture: markInsideReactTree }), [closeOnEscapeKeyDown, markInsideReactTree, markPressStartedInsideReactTree, markInsidePressStartPrevented]); - return React19.useMemo(() => enabled ? { + return React16.useMemo(() => enabled ? { reference, floating, trigger: reference @@ -3200,7 +3169,7 @@ function useDismiss(context, props = {}) { } // node_modules/@base-ui/react/floating-ui-react/hooks/useFloating.mjs -var React26 = __toESM(require_react(), 1); +var React24 = __toESM(require_react(), 1); // node_modules/@floating-ui/core/dist/floating-ui.core.mjs function computeCoordsFromPlacement(_ref, placement, rtl) { @@ -3504,67 +3473,6 @@ var flip = function(options) { } }; }; -function getSideOffsets(overflow, rect) { - return { - top: overflow.top - rect.height, - right: overflow.right - rect.width, - bottom: overflow.bottom - rect.height, - left: overflow.left - rect.width - }; -} -function isAnySideFullyClipped(overflow) { - return sides.some((side) => overflow[side] >= 0); -} -var hide = function(options) { - if (options === void 0) { - options = {}; - } - return { - name: "hide", - options, - async fn(state) { - const { - rects, - platform: platform3 - } = state; - const { - strategy = "referenceHidden", - ...detectOverflowOptions - } = evaluate(options, state); - switch (strategy) { - case "referenceHidden": { - const overflow = await platform3.detectOverflow(state, { - ...detectOverflowOptions, - elementContext: "reference" - }); - const offsets = getSideOffsets(overflow, rects.reference); - return { - data: { - referenceHiddenOffsets: offsets, - referenceHidden: isAnySideFullyClipped(offsets) - } - }; - } - case "escaped": { - const overflow = await platform3.detectOverflow(state, { - ...detectOverflowOptions, - altBoundary: true - }); - const offsets = getSideOffsets(overflow, rects.floating); - return { - data: { - escapedOffsets: offsets, - escaped: isAnySideFullyClipped(offsets) - } - }; - } - default: { - return {}; - } - } - } - }; -}; var originSides = /* @__PURE__ */ new Set(["left", "top"]); async function convertValueToCoords(state, options) { const { @@ -4431,7 +4339,6 @@ var offset2 = offset; var shift2 = shift; var flip2 = flip; var size2 = size; -var hide2 = hide; var limitShift2 = limitShift; var computePosition2 = (reference, floating, options) => { const cache = /* @__PURE__ */ new Map(); @@ -4448,7 +4355,7 @@ var computePosition2 = (reference, floating, options) => { }; // node_modules/@floating-ui/react-dom/dist/floating-ui.react-dom.mjs -var React20 = __toESM(require_react(), 1); +var React17 = __toESM(require_react(), 1); var import_react2 = __toESM(require_react(), 1); var ReactDOM3 = __toESM(require_react_dom(), 1); var isClient = typeof document !== "undefined"; @@ -4514,7 +4421,7 @@ function roundByDPR(element, value) { return Math.round(value * dpr) / dpr; } function useLatestRef(value) { - const ref = React20.useRef(value); + const ref = React17.useRef(value); index(() => { ref.current = value; }); @@ -4537,7 +4444,7 @@ function useFloating(options) { whileElementsMounted, open } = options; - const [data, setData] = React20.useState({ + const [data, setData] = React17.useState({ x: 0, y: 0, strategy, @@ -4545,19 +4452,19 @@ function useFloating(options) { middlewareData: {}, isPositioned: false }); - const [latestMiddleware, setLatestMiddleware] = React20.useState(middleware); + const [latestMiddleware, setLatestMiddleware] = React17.useState(middleware); if (!deepEqual(latestMiddleware, middleware)) { setLatestMiddleware(middleware); } - const [_reference, _setReference] = React20.useState(null); - const [_floating, _setFloating] = React20.useState(null); - const setReference = React20.useCallback((node) => { + const [_reference, _setReference] = React17.useState(null); + const [_floating, _setFloating] = React17.useState(null); + const setReference = React17.useCallback((node) => { if (node !== referenceRef.current) { referenceRef.current = node; _setReference(node); } }, []); - const setFloating = React20.useCallback((node) => { + const setFloating = React17.useCallback((node) => { if (node !== floatingRef.current) { floatingRef.current = node; _setFloating(node); @@ -4565,14 +4472,14 @@ function useFloating(options) { }, []); const referenceEl = externalReference || _reference; const floatingEl = externalFloating || _floating; - const referenceRef = React20.useRef(null); - const floatingRef = React20.useRef(null); - const dataRef = React20.useRef(data); + const referenceRef = React17.useRef(null); + const floatingRef = React17.useRef(null); + const dataRef = React17.useRef(data); const hasWhileElementsMounted = whileElementsMounted != null; const whileElementsMountedRef = useLatestRef(whileElementsMounted); const platformRef = useLatestRef(platform3); const openRef = useLatestRef(open); - const update2 = React20.useCallback(() => { + const update2 = React17.useCallback(() => { if (!referenceRef.current || !floatingRef.current) { return; } @@ -4610,7 +4517,7 @@ function useFloating(options) { })); } }, [open]); - const isMountedRef = React20.useRef(false); + const isMountedRef = React17.useRef(false); index(() => { isMountedRef.current = true; return () => { @@ -4627,17 +4534,17 @@ function useFloating(options) { update2(); } }, [referenceEl, floatingEl, update2, whileElementsMountedRef, hasWhileElementsMounted]); - const refs = React20.useMemo(() => ({ + const refs = React17.useMemo(() => ({ reference: referenceRef, floating: floatingRef, setReference, setFloating }), [setReference, setFloating]); - const elements2 = React20.useMemo(() => ({ + const elements2 = React17.useMemo(() => ({ reference: referenceEl, floating: floatingEl }), [referenceEl, floatingEl]); - const floatingStyles = React20.useMemo(() => { + const floatingStyles = React17.useMemo(() => { const initialStyles = { position: strategy, left: 0, @@ -4663,7 +4570,7 @@ function useFloating(options) { top: y2 }; }, [strategy, transform, elements2.floating, data.x, data.y]); - return React20.useMemo(() => ({ + return React17.useMemo(() => ({ ...data, update: update2, refs, @@ -4710,81 +4617,182 @@ var size3 = (options, deps) => { options: [options, deps] }; }; -var hide3 = (options, deps) => { - const result = hide2(options); - return { - name: result.name, - fn: result.fn, - options: [options, deps] - }; + +// node_modules/@base-ui/react/utils/popups/popupHandle.mjs +var BasePopupHandle = class { + /** + * Stores of every root currently using this handle, in attach order. A handle is meant to be used + * by a single mounted root, but roots can transiently overlap (e.g. during an animated route + * transition), so this stack lets `attachStore`'s cleanup restore the previous root instead of + * leaving a still-mounted root uncontrollable when a newer overlapping root detaches first. + */ + attachedStores = []; + /** + * Store of the root that currently controls the handle: the most recently attached one still + * mounted, or `null` when no root is attached. Imperative methods are no-ops while this is `null`. + */ + attachedStoreValue = null; + /** + * Listeners notified when `attachedStore` changes, so detached triggers can follow the store pointer. + */ + storeListeners = /* @__PURE__ */ new Set(); + /** + * Creates a handle backed by the store used while no root is attached. + * + * @param fallbackStore Inert, closed store handed to detached triggers while no root is attached, + * so they can render and register without a mounted root. Triggers register into whichever store + * `store` currently resolves to, so while detached they live in this store's trigger map and + * migrate themselves to the root's store (and back) as it attaches/detaches. + * @param componentName Component name used to prefix dev warnings, e.g. `'Menu'` produces + * `MenuHandle.open()` in warning text. + * @param throwOnMissingTrigger Whether `open(triggerId)` throws when no trigger with that id is + * registered. Anchored popups (Menu, Popover, Tooltip, PreviewCard) need a trigger to anchor to, + * so they throw; Dialog is not anchored and instead opens unassociated with a dev warning. + */ + constructor(fallbackStore, componentName, throwOnMissingTrigger = true) { + this.fallbackStore = fallbackStore; + this.componentName = componentName; + this.throwOnMissingTrigger = throwOnMissingTrigger; + } + get attachedStore() { + return this.attachedStoreValue; + } + /** + * Store that detached triggers read from: the attached root's store, or an inert fallback store + * used while no root is attached. + * @internal + */ + get store() { + return this.attachedStoreValue ?? this.fallbackStore; + } + /** + * Stable fallback store used for server rendering and hydration. Root stores cannot be recorded on + * the handle during render because a handle can be shared by concurrent server-rendered requests. + * @internal + */ + get serverStore() { + return this.fallbackStore; + } + /** + * Subscribes to changes of the attached store pointer so detached triggers re-render and re-bind + * when a root attaches or detaches. Returns a function that removes the listener. + * @internal + */ + subscribeStore(listener) { + this.storeListeners.add(listener); + return () => { + this.storeListeners.delete(listener); + }; + } + /** + * Points the handle at a root's store and notifies subscribers so detached triggers re-render and + * re-register into it (their registration ref re-fires on the store-pointer change). Returns a + * cleanup function that detaches the store again. + * @internal + */ + attachStore(newStore) { + this.attachedStores.push(newStore); + this.setActiveStore(newStore); + if (true) { + if (this.attachedStores.length > 1) { + const dev = this; + (dev.overlapWarningFrame ??= AnimationFrame.create()).request(() => { + if (this.attachedStores.length > 1) { + console.warn("Base UI: A handle is attached to more than one mounted root at the same time. The most recently mounted root takes over and the previous one stops being controlled by the handle. A handle should be used by a single root that stays mounted for the lifetime of the handle."); + } + }); + } + } + return () => { + const index2 = this.attachedStores.lastIndexOf(newStore); + if (index2 !== -1) { + this.attachedStores.splice(index2, 1); + } + this.setActiveStore(this.attachedStores[this.attachedStores.length - 1] ?? null); + }; + } + /** + * Sets the store that currently controls the handle and notifies subscribers when it changes, so + * detached triggers re-render and migrate their registration to the new store. + */ + setActiveStore(store) { + if (this.attachedStoreValue !== store) { + this.attachedStoreValue = store; + this.storeListeners.forEach((listener) => { + listener(); + }); + } + } + /** + * Opens the attached root's store and associates it with the trigger with the given id, or a + * no-op (with a dev warning) while no root is attached. Shared by every concrete handle's public + * `open()` method, which only narrows the parameter type. + * + * When a trigger id is given but no matching trigger is registered, anchored popups throw (see + * `throwOnMissingTrigger`); Dialog opens unassociated with a dev warning instead. + * + * This method should only be called in an event handler or an effect (not during rendering). + * + * @param triggerId ID of the trigger to associate with the popup, or `null`/`undefined` to open + * without associating any trigger. + */ + openByTrigger(triggerId) { + const attachedStore = this.attachedStore; + if (attachedStore === null) { + if (true) { + console.warn(`Base UI: ${this.componentName}Handle.open() was called while no root using this handle is mounted. The call was ignored; mount a root with this handle before opening it imperatively.`); + } + return; + } + let triggerElement; + if (triggerId) { + for (let i2 = this.attachedStores.length - 1; i2 >= 0 && !triggerElement; i2 -= 1) { + triggerElement = this.attachedStores[i2].context.triggerElements.getById(triggerId); + } + triggerElement ??= this.fallbackStore.context.triggerElements.getById(triggerId); + } + if (triggerId && !triggerElement) { + if (this.throwOnMissingTrigger) { + throw new Error(true ? `Base UI: ${this.componentName}Handle.open() was called with the trigger id "${triggerId}", but no matching trigger is registered with this handle. An anchored popup cannot open without a trigger to anchor to. Pass the id of a mounted ${this.componentName}.Trigger that has this handle set on its "handle" prop.` : formatErrorMessage_default(99, this.componentName, triggerId, this.componentName)); + } + if (true) { + console.warn(`Base UI: ${this.componentName}Handle.open: No trigger found with id "${triggerId}". The popup will open, but the trigger will not be associated with it.`); + } + } + attachedStore.setOpen(true, createChangeEventDetails(reason_parts_exports.imperativeAction, void 0, triggerElement)); + } + /** + * Closes the popup by setting the attached root's store to closed, or a no-op (with a dev warning) + * while no root is attached. Shared by every concrete handle's public `close()` method. + * + * This method should only be called in an event handler or an effect (not during rendering). + */ + closePopup() { + const attachedStore = this.attachedStore; + if (attachedStore === null) { + if (true) { + console.warn(`Base UI: ${this.componentName}Handle.close() was called while no root using this handle is mounted. The call was ignored.`); + } + return; + } + attachedStore.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction)); + } }; // node_modules/@base-ui/react/utils/popups/popupStoreUtils.mjs -var React25 = __toESM(require_react(), 1); +var React22 = __toESM(require_react(), 1); var ReactDOM4 = __toESM(require_react_dom(), 1); // node_modules/@base-ui/react/floating-ui-react/hooks/useSyncedFloatingRootContext.mjs -var React24 = __toESM(require_react(), 1); - -// node_modules/@base-ui/utils/store/createSelector.mjs -var createSelector = (a2, b2, c2, d2, e2, f2, ...other) => { - if (other.length > 0) { - throw new Error(true ? "Unsupported number of selectors" : formatErrorMessage_default(1)); - } - let selector; - if (a2 && b2 && c2 && d2 && e2 && f2) { - selector = (state, a1, a22, a3) => { - const va = a2(state, a1, a22, a3); - const vb = b2(state, a1, a22, a3); - const vc = c2(state, a1, a22, a3); - const vd = d2(state, a1, a22, a3); - const ve = e2(state, a1, a22, a3); - return f2(va, vb, vc, vd, ve, a1, a22, a3); - }; - } else if (a2 && b2 && c2 && d2 && e2) { - selector = (state, a1, a22, a3) => { - const va = a2(state, a1, a22, a3); - const vb = b2(state, a1, a22, a3); - const vc = c2(state, a1, a22, a3); - const vd = d2(state, a1, a22, a3); - return e2(va, vb, vc, vd, a1, a22, a3); - }; - } else if (a2 && b2 && c2 && d2) { - selector = (state, a1, a22, a3) => { - const va = a2(state, a1, a22, a3); - const vb = b2(state, a1, a22, a3); - const vc = c2(state, a1, a22, a3); - return d2(va, vb, vc, a1, a22, a3); - }; - } else if (a2 && b2 && c2) { - selector = (state, a1, a22, a3) => { - const va = a2(state, a1, a22, a3); - const vb = b2(state, a1, a22, a3); - return c2(va, vb, a1, a22, a3); - }; - } else if (a2 && b2) { - selector = (state, a1, a22, a3) => { - const va = a2(state, a1, a22, a3); - return b2(va, a1, a22, a3); - }; - } else if (a2) { - selector = a2; - } else { - throw ( - /* minify-error-disabled */ - new Error("Missing arguments") - ); - } - return selector; -}; +var React21 = __toESM(require_react(), 1); // node_modules/@base-ui/utils/store/useStore.mjs -var React22 = __toESM(require_react(), 1); +var React19 = __toESM(require_react(), 1); var import_shim = __toESM(require_shim(), 1); var import_with_selector = __toESM(require_with_selector(), 1); // node_modules/@base-ui/utils/fastHooks.mjs -var React21 = __toESM(require_react(), 1); +var React18 = __toESM(require_react(), 1); var hooks = []; var currentInstance = void 0; function getInstance() { @@ -4816,7 +4824,7 @@ function fastComponent(fn) { return FastComponent; } function fastComponentRef(fn) { - return /* @__PURE__ */ React21.forwardRef(fastComponent(fn)); + return /* @__PURE__ */ React18.forwardRef(fastComponent(fn)); } function createInstance() { return { @@ -4831,7 +4839,7 @@ function useStore(store, selector, a1, a2, a3) { return useStoreImplementation(store, selector, a1, a2, a3); } function useStoreR19(store, selector, a1, a2, a3) { - const getSelection = React22.useCallback(() => selector(store.getSnapshot(), a1, a2, a3), [store, selector, a1, a2, a3]); + const getSelection = React19.useCallback(() => selector(store.getSnapshot(), a1, a2, a3), [store, selector, a1, a2, a3]); return (0, import_shim.useSyncExternalStore)(store.subscribe, getSelection, getSelection); } register({ @@ -5018,7 +5026,7 @@ var Store = class { }; // node_modules/@base-ui/utils/store/ReactStore.mjs -var React23 = __toESM(require_react(), 1); +var React20 = __toESM(require_react(), 1); var ReactStore = class extends Store { /** * Creates a new ReactStore instance. @@ -5042,7 +5050,7 @@ var ReactStore = class extends Store { * by `useState` is updated before the next render (similarly to React's `useState`). */ useSyncedValue(key, value) { - React23.useDebugValue(key); + React20.useDebugValue(key); const store = this; useIsoLayoutEffect(() => { if (store.state[key] !== value) { @@ -5077,8 +5085,8 @@ var ReactStore = class extends Store { useSyncedValues(statePart) { const store = this; if (true) { - React23.useDebugValue(statePart, (p3) => Object.keys(p3)); - const keys = React23.useRef(Object.keys(statePart)).current; + React20.useDebugValue(statePart, (p3) => Object.keys(p3)); + const keys = React20.useRef(Object.keys(statePart)).current; const nextKeys = Object.keys(statePart); if (keys.length !== nextKeys.length || keys.some((key, index2) => key !== nextKeys[index2])) { console.error("ReactStore.useSyncedValues expects the same prop keys on every render. Keys should be stable."); @@ -5094,7 +5102,7 @@ var ReactStore = class extends Store { * is non-undefined, the store's state at `key` is updated to match `controlled`. */ useControlledProp(key, controlled) { - React23.useDebugValue(key); + React20.useDebugValue(key); const store = this; const isControlled = controlled !== void 0; useIsoLayoutEffect(() => { @@ -5132,7 +5140,7 @@ var ReactStore = class extends Store { * @param key Key of the selector to use. */ useState(key, a1, a2, a3) { - React23.useDebugValue(key); + React20.useDebugValue(key); return useStore(this, this.selectors[key], a1, a2, a3); } /** @@ -5143,7 +5151,7 @@ var ReactStore = class extends Store { * @param fn Function to assign. */ useContextCallback(key, fn) { - React23.useDebugValue(key); + React20.useDebugValue(key); const stableFunction = useStableCallback(fn ?? NOOP); this.context[key] = stableFunction; } @@ -5154,7 +5162,7 @@ var ReactStore = class extends Store { * @param key Key of the state to set. */ useStateSetter(key) { - const ref = React23.useRef(void 0); + const ref = React20.useRef(void 0); if (ref.current === void 0) { ref.current = (value) => { this.set(key, value); @@ -5190,12 +5198,12 @@ var ReactStore = class extends Store { // node_modules/@base-ui/react/floating-ui-react/components/FloatingRootStore.mjs var selectors = { - open: createSelector((state) => state.open), - transitionStatus: createSelector((state) => state.transitionStatus), - domReferenceElement: createSelector((state) => state.domReferenceElement), - referenceElement: createSelector((state) => state.positionReference ?? state.referenceElement), - floatingElement: createSelector((state) => state.floatingElement), - floatingId: createSelector((state) => state.floatingId) + open: (state) => state.open, + transitionStatus: (state) => state.transitionStatus, + domReferenceElement: (state) => state.domReferenceElement, + referenceElement: (state) => state.positionReference ?? state.referenceElement, + floatingElement: (state) => state.floatingElement, + floatingId: (state) => state.floatingId }; var FloatingRootStore = class extends ReactStore { constructor(options) { @@ -5276,7 +5284,7 @@ function useSyncedFloatingRootContext(options) { const floatingElement = popupStore.useState(treatPopupAsFloatingElement ? "popupElement" : "positionerElement"); const triggerElements = popupStore.context.triggerElements; const handleOpenChange = onOpenChange; - const internalStoreRef = React24.useRef(null); + const internalStoreRef = React21.useRef(null); if (floatingRootContextProp === void 0 && internalStoreRef.current === null) { internalStoreRef.current = new FloatingRootStore({ open, @@ -5317,14 +5325,10 @@ var FOCUSABLE_POPUP_PROPS = { tabIndex: -1, [FOCUSABLE_ATTRIBUTE]: "" }; -function usePopupStore(externalStore, createStore, treatPopupAsFloatingElement = false) { +function usePopupRootStore(createStore, treatPopupAsFloatingElement = false) { const floatingId = useId(); const nested = useFloatingParentNodeId() != null; - const internalStoreRef = React25.useRef(null); - if (externalStore === void 0 && internalStoreRef.current === null) { - internalStoreRef.current = createStore(floatingId, nested); - } - const store = externalStore ?? internalStoreRef.current; + const store = useRefWithInit(() => createStore(floatingId, nested)).current; useSyncedFloatingRootContext({ popupStore: store, treatPopupAsFloatingElement, @@ -5333,15 +5337,21 @@ function usePopupStore(externalStore, createStore, treatPopupAsFloatingElement = nested, onOpenChange: store.setOpen }); - return { - store, - internalStore: internalStoreRef.current - }; + return store; +} +function PopupHandleAttachment({ + handle, + store +}) { + useIsoLayoutEffect(() => { + return handle.attachStore(store); + }, [handle, store]); + return null; } function useTriggerRegistration(id, store) { - const registeredElementIdRef = React25.useRef(null); - const registeredElementRef = React25.useRef(null); - return React25.useCallback((element) => { + const registeredElementIdRef = React22.useRef(null); + const registeredElementRef = React22.useRef(null); + return React22.useCallback((element) => { if (id === void 0) { return; } @@ -5423,26 +5433,10 @@ function applyPopupOpenChange(store, nextOpen, eventDetails, options = {}) { changeState(); } } -function useInitialOpenSync(store, openProp, defaultOpen, defaultTriggerId) { - useOnFirstRender(() => { - if (openProp === void 0 && store.state.open === false && defaultOpen) { - store.state = { - ...store.state, - open: true, - activeTriggerId: defaultTriggerId, - preventUnmountingOnClose: false - }; - } - }); -} function useTriggerDataForwarding(triggerId, triggerElementRef, store, stateUpdates) { const isMountedByThisTrigger = store.useState("isMountedByTrigger", triggerId); const baseRegisterTrigger = useTriggerRegistration(triggerId, store); - const registerTrigger = useStableCallback((element) => { - baseRegisterTrigger(element); - if (!element) { - return; - } + const applyTriggerData = useStableCallback((element) => { const open = store.select("open"); const activeTriggerId = store.select("activeTriggerId"); if (activeTriggerId === triggerId) { @@ -5460,6 +5454,12 @@ function useTriggerDataForwarding(triggerId, triggerElementRef, store, stateUpda }); } }); + const registerTrigger = React22.useCallback((element) => { + baseRegisterTrigger(element); + if (element) { + applyTriggerData(element); + } + }, [baseRegisterTrigger, applyTriggerData]); useIsoLayoutEffect(() => { if (isMountedByThisTrigger) { store.update({ @@ -5477,10 +5477,14 @@ function useImplicitActiveTrigger(store, options = {}) { const { closeOnActiveTriggerUnmount = false } = options; + const resolvedActiveTriggerIdRef = React22.useRef(null); const open = store.useState("open"); const reactiveTriggerCount = store.useState("triggerCount"); + const activeTriggerId = store.useState("activeTriggerId"); + const reactiveActiveTriggerElement = store.useState("activeTriggerElement"); useIsoLayoutEffect(() => { if (!open) { + resolvedActiveTriggerIdRef.current = null; if (store.state.triggerCount !== 0) { store.set("triggerCount", 0); } @@ -5491,22 +5495,42 @@ function useImplicitActiveTrigger(store, options = {}) { if (store.state.triggerCount !== triggerCount) { stateUpdates.triggerCount = triggerCount; } - const activeTriggerId = store.select("activeTriggerId"); + const currentActiveTriggerId = store.select("activeTriggerId"); let lostActiveTriggerId = null; - if (activeTriggerId) { - const activeTriggerElement = store.context.triggerElements.getById(activeTriggerId); + if (currentActiveTriggerId) { + const activeTriggerElement = store.context.triggerElements.getById(currentActiveTriggerId); if (!activeTriggerElement) { - lostActiveTriggerId = activeTriggerId; - } else if (activeTriggerElement !== store.state.activeTriggerElement) { - stateUpdates.activeTriggerElement = activeTriggerElement; + for (const [triggerId, triggerElement] of store.context.triggerElements.entries()) { + if (triggerElement === store.state.activeTriggerElement) { + stateUpdates.activeTriggerId = triggerId; + stateUpdates.activeTriggerElement = triggerElement; + resolvedActiveTriggerIdRef.current = triggerId; + break; + } + } + if (stateUpdates.activeTriggerId === void 0) { + if (resolvedActiveTriggerIdRef.current === currentActiveTriggerId) { + lostActiveTriggerId = currentActiveTriggerId; + } else { + resolvedActiveTriggerIdRef.current = null; + } + } + } else { + resolvedActiveTriggerIdRef.current = currentActiveTriggerId; + if (activeTriggerElement !== store.state.activeTriggerElement) { + stateUpdates.activeTriggerElement = activeTriggerElement; + } } + } else { + resolvedActiveTriggerIdRef.current = null; } - if (!lostActiveTriggerId && !activeTriggerId && triggerCount === 1) { + if (!lostActiveTriggerId && !currentActiveTriggerId && triggerCount === 1) { const iteratorResult = store.context.triggerElements.entries().next(); if (!iteratorResult.done) { const [implicitTriggerId, implicitTriggerElement] = iteratorResult.value; stateUpdates.activeTriggerId = implicitTriggerId; stateUpdates.activeTriggerElement = implicitTriggerElement; + resolvedActiveTriggerIdRef.current = implicitTriggerId; } } if (stateUpdates.triggerCount !== void 0 || stateUpdates.activeTriggerId !== void 0 || stateUpdates.activeTriggerElement !== void 0) { @@ -5528,7 +5552,7 @@ function useImplicitActiveTrigger(store, options = {}) { }); } } - }, [open, store, reactiveTriggerCount, closeOnActiveTriggerUnmount]); + }, [open, store, reactiveTriggerCount, activeTriggerId, reactiveActiveTriggerElement, closeOnActiveTriggerUnmount]); } function useOpenStateTransitions(open, store, onUnmount) { const { @@ -5581,9 +5605,18 @@ function usePopupInteractionProps(store, statePart) { } // node_modules/@base-ui/react/utils/popups/popupTriggerMap.mjs +var devElementIdsByMap; +function getDevElementIds(map) { + devElementIdsByMap ??= /* @__PURE__ */ new WeakMap(); + let elementIds = devElementIdsByMap.get(map); + if (!elementIds) { + elementIds = /* @__PURE__ */ new WeakMap(); + devElementIdsByMap.set(map, elementIds); + } + return elementIds; +} var PopupTriggerMap = class { constructor() { - this.elementsSet = /* @__PURE__ */ new Set(); this.idMap = /* @__PURE__ */ new Map(); } /** @@ -5592,42 +5625,48 @@ var PopupTriggerMap = class { * Note: The provided element is assumed to not be registered under multiple IDs. */ add(id, element) { - const existingElement = this.idMap.get(id); - if (existingElement === element) { - return; - } - if (existingElement !== void 0) { - this.elementsSet.delete(existingElement); - } - this.elementsSet.add(element); - this.idMap.set(id, element); if (true) { - if (this.elementsSet.size !== this.idMap.size) { + const elementIds = getDevElementIds(this); + const existingId = elementIds.get(element); + if (existingId !== void 0 && existingId !== id) { throw new Error("Base UI: A trigger element cannot be registered under multiple IDs in PopupTriggerMap."); } + const previousElement = this.idMap.get(id); + if (previousElement !== void 0 && previousElement !== element) { + elementIds.delete(previousElement); + } + elementIds.set(element, id); } + this.idMap.set(id, element); } /** * Removes the trigger element with the given ID. */ delete(id) { - const element = this.idMap.get(id); - if (element) { - this.elementsSet.delete(element); - this.idMap.delete(id); + if (true) { + const element = this.idMap.get(id); + if (element !== void 0) { + devElementIdsByMap?.get(this)?.delete(element); + } } + this.idMap.delete(id); } /** * Whether the given element is registered as a trigger. */ hasElement(element) { - return this.elementsSet.has(element); - } + for (const registered of this.idMap.values()) { + if (registered === element) { + return true; + } + } + return false; + } /** * Whether there is a registered trigger element matching the given predicate. */ hasMatchingElement(predicate) { - for (const element of this.elementsSet) { + for (const element of this.idMap.values()) { if (predicate(element)) { return true; } @@ -5650,7 +5689,7 @@ var PopupTriggerMap = class { * Returns an iterable of all registered trigger elements. */ elements() { - return this.elementsSet.values(); + return this.idMap.values(); } /** * Returns the number of registered trigger elements. @@ -5710,12 +5749,12 @@ function createPopupFloatingRootContext(triggerElements, floatingId, nested = fa onOpenChange: void 0 }); } -var activeTriggerIdSelector = createSelector((state) => state.triggerIdProp ?? state.activeTriggerId); -var openSelector = createSelector((state) => state.openProp ?? state.open); -var popupIdSelector = createSelector((state) => { +var activeTriggerIdSelector = (state) => state.triggerIdProp ?? state.activeTriggerId; +var openSelector = (state) => state.openProp ?? state.open; +var popupIdSelector = (state) => { const popupId = state.popupElement?.id ?? state.floatingId; return popupId || void 0; -}); +}; function triggerOwnsOpenPopup(state, triggerId) { return triggerId !== void 0 && openSelector(state) && activeTriggerIdSelector(state) === triggerId; } @@ -5727,101 +5766,73 @@ function triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) { } var popupStoreSelectors = { open: openSelector, - mounted: createSelector((state) => state.mounted), - transitionStatus: createSelector((state) => state.transitionStatus), - floatingRootContext: createSelector((state) => state.floatingRootContext), - triggerCount: createSelector((state) => state.triggerCount), - preventUnmountingOnClose: createSelector((state) => state.preventUnmountingOnClose), - payload: createSelector((state) => state.payload), + mounted: (state) => state.mounted, + transitionStatus: (state) => state.transitionStatus, + floatingRootContext: (state) => state.floatingRootContext, + triggerCount: (state) => state.triggerCount, + preventUnmountingOnClose: (state) => state.preventUnmountingOnClose, + payload: (state) => state.payload, activeTriggerId: activeTriggerIdSelector, - activeTriggerElement: createSelector((state) => state.mounted ? state.activeTriggerElement : null), + activeTriggerElement: (state) => state.mounted ? state.activeTriggerElement : null, popupId: popupIdSelector, /** * Whether the trigger with the given ID was used to open the popup. */ - isTriggerActive: createSelector((state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId), + isTriggerActive: (state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId, /** * Whether the popup is open and was activated by a trigger with the given ID. */ - isOpenedByTrigger: createSelector((state, triggerId) => triggerOwnsOpenPopup(state, triggerId)), + isOpenedByTrigger: (state, triggerId) => triggerOwnsOpenPopup(state, triggerId), /** * Whether the popup is mounted and was activated by a trigger with the given ID. */ - isMountedByTrigger: createSelector((state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId && state.mounted), - triggerProps: createSelector((state, isActive) => isActive ? state.activeTriggerProps : state.inactiveTriggerProps), + isMountedByTrigger: (state, triggerId) => triggerId !== void 0 && activeTriggerIdSelector(state) === triggerId && state.mounted, + triggerProps: (state, isActive) => isActive ? state.activeTriggerProps : state.inactiveTriggerProps, /** * Popup id for the trigger that currently owns the open popup. */ - triggerPopupId: createSelector((state, triggerId) => triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) ? popupIdSelector(state) : void 0), - popupProps: createSelector((state) => state.popupProps), - popupElement: createSelector((state) => state.popupElement), - positionerElement: createSelector((state) => state.positionerElement) + triggerPopupId: (state, triggerId) => triggerOwnsOpenPopupOrIsOnlyTrigger(state, triggerId) ? popupIdSelector(state) : void 0, + popupProps: (state) => state.popupProps, + popupElement: (state) => state.popupElement, + positionerElement: (state) => state.positionerElement }; -// node_modules/@base-ui/react/floating-ui-react/hooks/useFloatingRootContext.mjs -function useFloatingRootContext(options) { - const { - open = false, - onOpenChange, - elements: elements2 = {} - } = options; - const floatingId = useId(); - const nested = useFloatingParentNodeId() != null; - if (true) { - const optionDomReference = elements2.reference; - if (optionDomReference && !isElement(optionDomReference)) { - console.error("Cannot pass a virtual element to the `elements.reference` option,", "as it must be a real DOM element. Use `context.setPositionReference()`", "instead."); - } - } - const store = useRefWithInit(() => new FloatingRootStore({ - open, - transitionStatus: void 0, - onOpenChange, - referenceElement: elements2.reference ?? null, - floatingElement: elements2.floating ?? null, - triggerElements: new PopupTriggerMap(), - floatingId, - syncOnly: false, - nested - })).current; - useIsoLayoutEffect(() => { - const valuesToSync = { - open, - floatingId - }; - if (elements2.reference !== void 0) { - valuesToSync.referenceElement = elements2.reference; - valuesToSync.domReferenceElement = isElement(elements2.reference) ? elements2.reference : null; - } - if (elements2.floating !== void 0) { - valuesToSync.floatingElement = elements2.floating; +// node_modules/@base-ui/react/utils/popups/usePopupHandleStore.mjs +var React23 = __toESM(require_react(), 1); +var import_shim2 = __toESM(require_shim(), 1); +function usePopupHandleStore(handle) { + const subscribe = React23.useCallback((listener) => { + if (handle === void 0) { + return NOOP; } - store.update(valuesToSync); - }, [open, floatingId, elements2.reference, elements2.floating, store]); - store.context.onOpenChange = onOpenChange; - store.context.nested = nested; - return store; + return handle.subscribeStore(listener); + }, [handle]); + const getSnapshot = React23.useCallback(() => { + return handle === void 0 ? void 0 : handle.store; + }, [handle]); + return (0, import_shim2.useSyncExternalStore)(subscribe, getSnapshot, () => handle?.serverStore); } // node_modules/@base-ui/react/floating-ui-react/hooks/useFloating.mjs -function useFloating2(options = {}) { +function useBaseUIFloating(options) { + return useFloatingWithStore(options, options.rootContext); +} +function useFloatingWithStore(options, store) { const { nodeId, externalTree } = options; - const internalStore = useFloatingRootContext(options); - const store = options.rootContext || internalStore; const referenceElement = store.useState("referenceElement"); const floatingElement = store.useState("floatingElement"); const domReferenceElement = store.useState("domReferenceElement"); const open = store.useState("open"); const floatingId = store.useState("floatingId"); - const [positionReference, setPositionReferenceRaw] = React26.useState(null); - const [localDomReference, setLocalDomReference] = React26.useState(void 0); - const [localFloatingElement, setLocalFloatingElement] = React26.useState(void 0); - const domReferenceRef = React26.useRef(null); + const [positionReference, setPositionReferenceRaw] = React24.useState(null); + const [localDomReference, setLocalDomReference] = React24.useState(void 0); + const [localFloatingElement, setLocalFloatingElement] = React24.useState(void 0); + const domReferenceRef = React24.useRef(null); const tree = useFloatingTree(externalTree); - const storeElements = React26.useMemo(() => ({ + const storeElements = React24.useMemo(() => ({ reference: referenceElement, floating: floatingElement, domReference: domReferenceElement @@ -5840,7 +5851,7 @@ function useFloating2(options = {}) { store.useSyncedValue("referenceElement", localDomReference ?? null); store.useSyncedValue("domReferenceElement", localDomReference === void 0 ? domReferenceElement : localDomReferenceElement); store.useSyncedValue("floatingElement", syncedFloatingElement); - const setPositionReference = React26.useCallback((node) => { + const setPositionReference = React24.useCallback((node) => { const computedPositionReference = isElement(node) ? { getBoundingClientRect: () => node.getBoundingClientRect(), getClientRects: () => node.getClientRects(), @@ -5849,7 +5860,7 @@ function useFloating2(options = {}) { setPositionReferenceRaw(computedPositionReference); position.refs.setReference(computedPositionReference); }, [position.refs]); - const setReference = React26.useCallback((node) => { + const setReference = React24.useCallback((node) => { if (isElement(node) || node === null) { domReferenceRef.current = node; setLocalDomReference(node); @@ -5861,22 +5872,22 @@ function useFloating2(options = {}) { position.refs.setReference(node); } }, [position.refs, setLocalDomReference]); - const setFloating = React26.useCallback((node) => { + const setFloating = React24.useCallback((node) => { setLocalFloatingElement(node); position.refs.setFloating(node); }, [position.refs]); - const refs = React26.useMemo(() => ({ + const refs = React24.useMemo(() => ({ ...position.refs, setReference, setFloating, setPositionReference, domReference: domReferenceRef }), [position.refs, setReference, setFloating, setPositionReference]); - const elements2 = React26.useMemo(() => ({ + const elements2 = React24.useMemo(() => ({ ...position.elements, domReference: domReferenceElement }), [position.elements, domReferenceElement]); - const context = React26.useMemo(() => ({ + const context = React24.useMemo(() => ({ ...position, dataRef: store.context.dataRef, open, @@ -5900,7 +5911,7 @@ function useFloating2(options = {}) { node.context = context; } }); - return React26.useMemo(() => ({ + return React24.useMemo(() => ({ ...position, context, refs, @@ -5910,7 +5921,7 @@ function useFloating2(options = {}) { } // node_modules/@base-ui/react/floating-ui-react/hooks/useFocus.mjs -var React27 = __toESM(require_react(), 1); +var React25 = __toESM(require_react(), 1); var isMacSafari = parts_exports.os.mac && parts_exports.engine.webkit; function useFocus(context, props = {}) { const { @@ -5922,11 +5933,11 @@ function useFocus(context, props = {}) { events, dataRef } = store.context; - const blockFocusRef = React27.useRef(false); - const blockedReferenceRef = React27.useRef(null); - const keyboardModalityRef = React27.useRef(true); + const blockFocusRef = React25.useRef(false); + const blockedReferenceRef = React25.useRef(null); + const keyboardModalityRef = React25.useRef(true); const timeout = useTimeout(); - React27.useEffect(() => { + React25.useEffect(() => { const domReference = store.select("domReferenceElement"); if (!enabled) { return void 0; @@ -5946,7 +5957,7 @@ function useFocus(context, props = {}) { } return mergeCleanups(addEventListener(win, "blur", onBlur), isMacSafari && addEventListener(win, "keydown", onKeyDown, true), isMacSafari && addEventListener(win, "pointerdown", onPointerDown, true)); }, [store, enabled]); - React27.useEffect(() => { + React25.useEffect(() => { if (!enabled) { return void 0; } @@ -5964,7 +5975,7 @@ function useFocus(context, props = {}) { events.off("openchange", onOpenChangeLocal); }; }, [events, enabled, store]); - const reference = React27.useMemo(() => { + const reference = React25.useMemo(() => { function resetBlockedFocus() { blockFocusRef.current = false; blockedReferenceRef.current = null; @@ -6031,14 +6042,14 @@ function useFocus(context, props = {}) { } }; }, [dataRef, delay, store, timeout]); - return React27.useMemo(() => enabled ? { + return React25.useMemo(() => enabled ? { reference, trigger: reference } : {}, [enabled, reference]); } // node_modules/@base-ui/react/floating-ui-react/hooks/useHoverFloatingInteraction.mjs -var React28 = __toESM(require_react(), 1); +var React26 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/hooks/useHoverInteractionSharedState.mjs var HoverInteraction = class _HoverInteraction { @@ -6149,7 +6160,7 @@ function useHoverFloatingInteraction(context, parameters = {}) { clearPointerEvents(); } }, [open, instance, clearPointerEvents]); - React28.useEffect(() => { + React26.useEffect(() => { return clearPointerEvents; }, [clearPointerEvents]); useIsoLayoutEffect(() => { @@ -6178,7 +6189,7 @@ function useHoverFloatingInteraction(context, parameters = {}) { } return void 0; }, [enabled, open, domReferenceElement, floatingElement, instance, isHoverOpen, tree, parentId, clearPointerEvents]); - React28.useEffect(() => { + React26.useEffect(() => { if (!enabled) { return void 0; } @@ -6253,7 +6264,7 @@ function useHoverFloatingInteraction(context, parameters = {}) { } // node_modules/@base-ui/react/floating-ui-react/hooks/useHoverReferenceInteraction.mjs -var React29 = __toESM(require_react(), 1); +var React27 = __toESM(require_react(), 1); var ReactDOM5 = __toESM(require_react_dom(), 1); var EMPTY_REF = { current: null @@ -6271,7 +6282,8 @@ function useHoverReferenceInteraction(context, props = {}) { isActiveTrigger = true, getHandleCloseContext, isClosing, - shouldOpen: shouldOpenProp + shouldOpen: shouldOpenProp, + guardStaleOpen = false } = props; const store = "rootStore" in context ? context.rootStore : context; const { @@ -6280,7 +6292,7 @@ function useHoverReferenceInteraction(context, props = {}) { } = store.context; const tree = useFloatingTree(externalTree); const instance = useHoverInteractionSharedState(store); - const isHoverCloseActiveRef = React29.useRef(false); + const isHoverCloseActiveRef = React27.useRef(false); const handleCloseRef = useValueAsRef(handleClose); const delayRef = useValueAsRef(delay); const restMsRef = useValueAsRef(restMs); @@ -6318,8 +6330,8 @@ function useHoverReferenceInteraction(context, props = {}) { if (isActiveTrigger) { instance.handleCloseOptions = handleCloseRef.current?.__options; } - React29.useEffect(() => cleanupMouseMoveHandler, [cleanupMouseMoveHandler]); - React29.useEffect(() => { + React27.useEffect(() => cleanupMouseMoveHandler, [cleanupMouseMoveHandler]); + React27.useEffect(() => { if (!enabled) { return void 0; } @@ -6340,7 +6352,7 @@ function useHoverReferenceInteraction(context, props = {}) { events.off("openchange", onOpenChangeLocal); }; }, [enabled, events, instance, cleanupMouseMoveHandler]); - React29.useEffect(() => { + React27.useEffect(() => { if (!enabled) { return void 0; } @@ -6454,14 +6466,23 @@ function useHoverReferenceInteraction(context, props = {}) { closeWithDelay(event); } } + function onMouseOut(event) { + if (contains(trigger, event.relatedTarget)) { + return; + } + instance.openChangeTimeout.clear(); + instance.restTimeout.clear(); + instance.restTimeoutPending = false; + } + const staleOpenGuard = guardStaleOpen ? addEventListener(trigger, "mouseout", onMouseOut) : void 0; if (move) { return mergeCleanups(addEventListener(trigger, "mousemove", onMouseEnter, { once: true - }), addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave)); + }), addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave), staleOpenGuard); } - return mergeCleanups(addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave)); - }, [cleanupMouseMoveHandler, clearPointerEvents, dataRef, delayRef, store, enabled, handleCloseRef, instance, isActiveTrigger, isOverInactiveTrigger, isClickLikeOpenEvent2, mouseOnly, move, restMsRef, triggerElementRef, tree, enabledRef, getHandleCloseContext, isClosingRef, checkShouldOpen]); - return React29.useMemo(() => { + return mergeCleanups(addEventListener(trigger, "mouseenter", onMouseEnter), addEventListener(trigger, "mouseleave", onMouseLeave), staleOpenGuard); + }, [cleanupMouseMoveHandler, clearPointerEvents, dataRef, delayRef, store, enabled, handleCloseRef, instance, isActiveTrigger, isOverInactiveTrigger, isClickLikeOpenEvent2, mouseOnly, move, restMsRef, triggerElementRef, tree, enabledRef, getHandleCloseContext, isClosingRef, checkShouldOpen, guardStaleOpen]); + return React27.useMemo(() => { if (!enabled) { return void 0; } @@ -6742,6 +6763,21 @@ function safePolygon(options = {}) { return fn; } +// node_modules/@base-ui/react/utils/NullStore.mjs +var NullStore = class extends ReactStore { + // `update`/`set`/`notifyAll` funnel through `setState` in the base `Store`, so overriding + // `setState` alone would neutralize them today. They are overridden explicitly so the store stays + // inert even if a future base-class change stops routing a mutator through `setState`. + setState(_newState) { + } + update(_changes) { + } + set(_key, _value) { + } + notifyAll() { + } +}; + // node_modules/@base-ui/react/utils/popupStateMapping.mjs var CommonPopupDataAttributes = (function(CommonPopupDataAttributes2) { CommonPopupDataAttributes2["open"] = "data-open"; @@ -6753,26 +6789,17 @@ var CommonPopupDataAttributes = (function(CommonPopupDataAttributes2) { CommonPopupDataAttributes2["align"] = "data-align"; return CommonPopupDataAttributes2; })({}); -var CommonTriggerDataAttributes = /* @__PURE__ */ (function(CommonTriggerDataAttributes2) { - CommonTriggerDataAttributes2["popupOpen"] = "data-popup-open"; - CommonTriggerDataAttributes2["pressed"] = "data-pressed"; - return CommonTriggerDataAttributes2; -})({}); var TRIGGER_HOOK = { - [CommonTriggerDataAttributes.popupOpen]: "" -}; -var PRESSABLE_TRIGGER_HOOK = { - [CommonTriggerDataAttributes.popupOpen]: "", - [CommonTriggerDataAttributes.pressed]: "" + "data-popup-open": "" }; var POPUP_OPEN_HOOK = { - [CommonPopupDataAttributes.open]: "" + "data-open": "" }; var POPUP_CLOSED_HOOK = { - [CommonPopupDataAttributes.closed]: "" + "data-closed": "" }; var ANCHOR_HIDDEN_HOOK = { - [CommonPopupDataAttributes.anchorHidden]: "" + "data-anchor-hidden": "" }; var triggerOpenStateMapping = { open(value) { @@ -6796,6 +6823,10 @@ var popupStateMapping = { return null; } }; +var popupTransitionStateMapping = { + ...popupStateMapping, + ...transitionStatusMapping +}; // node_modules/@base-ui/utils/inertValue.mjs function inertValue(value) { @@ -6805,8 +6836,17 @@ function inertValue(value) { return value ? "true" : void 0; } -// node_modules/@base-ui/react/utils/useAnchorPositioning.mjs -var React30 = __toESM(require_react(), 1); +// node_modules/@base-ui/react/internals/direction-context/DirectionContext.mjs +var React28 = __toESM(require_react(), 1); +var DirectionContext = /* @__PURE__ */ React28.createContext(void 0); +if (true) DirectionContext.displayName = "DirectionContext"; +function useDirection() { + const context = React28.useContext(DirectionContext); + return context?.direction ?? "ltr"; +} + +// node_modules/@base-ui/react/internals/useAnchorPositioning.mjs +var React29 = __toESM(require_react(), 1); // node_modules/@base-ui/react/floating-ui-react/middleware/arrow.mjs var baseArrow = (options) => ({ @@ -6878,7 +6918,6 @@ var arrow4 = (options, deps) => ({ }); // node_modules/@base-ui/react/utils/hideMiddleware.mjs -var nativeHideFn = hide3().fn; var hide4 = { name: "hide", async fn(state) { @@ -6889,88 +6928,27 @@ var hide4 = { y: y2 } = state.rects.reference; const anchorHidden = width === 0 && height === 0 && x2 === 0 && y2 === 0; - const nativeHideResult = await nativeHideFn(state); + const overflow = await state.platform.detectOverflow(state, { + elementContext: "reference" + }); + const referenceHidden = overflow.top - height >= 0 || overflow.right - width >= 0 || overflow.bottom - height >= 0 || overflow.left - width >= 0; return { data: { - referenceHidden: nativeHideResult.data?.referenceHidden || anchorHidden + referenceHidden: referenceHidden || anchorHidden } }; } }; -// node_modules/@base-ui/react/utils/adaptiveOriginMiddleware.mjs +// node_modules/@base-ui/react/utils/adaptiveOriginConstants.mjs var DEFAULT_SIDES = { sideX: "left", sideY: "top" }; -var adaptiveOrigin = { - name: "adaptiveOrigin", - async fn(state) { - const { - x: rawX, - y: rawY, - rects: { - floating: floatRect - }, - elements: { - floating - }, - platform: platform3, - strategy, - placement - } = state; - const win = getWindow(floating); - const styles = win.getComputedStyle(floating); - const hasTransition = styles.transitionDuration !== "0s" && styles.transitionDuration !== ""; - if (!hasTransition) { - return { - x: rawX, - y: rawY, - data: DEFAULT_SIDES - }; - } - const offsetParent = await platform3.getOffsetParent?.(floating); - let offsetDimensions = { - width: 0, - height: 0 - }; - if (strategy === "fixed" && win?.visualViewport) { - offsetDimensions = { - width: win.visualViewport.width, - height: win.visualViewport.height - }; - } else if (offsetParent === win) { - const doc = ownerDocument(floating); - offsetDimensions = { - width: doc.documentElement.clientWidth, - height: doc.documentElement.clientHeight - }; - } else if (await platform3.isElement?.(offsetParent)) { - offsetDimensions = await platform3.getDimensions(offsetParent); - } - const currentSide = getSide(placement); - let x2 = rawX; - let y2 = rawY; - if (currentSide === "left") { - x2 = offsetDimensions.width - (rawX + floatRect.width); - } - if (currentSide === "top") { - y2 = offsetDimensions.height - (rawY + floatRect.height); - } - const sideX = currentSide === "left" ? "right" : DEFAULT_SIDES.sideX; - const sideY = currentSide === "top" ? "bottom" : DEFAULT_SIDES.sideY; - return { - x: x2, - y: y2, - data: { - sideX, - sideY - } - }; - } -}; -// node_modules/@base-ui/react/utils/useAnchorPositioning.mjs +// node_modules/@base-ui/react/internals/useAnchorPositioning.mjs +var AVAILABLE_WIDTH_VAR = "--available-width"; +var AVAILABLE_HEIGHT_VAR = "--available-height"; function getLogicalSide(sideParam, renderedSide, isRtl) { const isLogicalSideParam = sideParam === "inline-start" || sideParam === "inline-end"; const logicalRight = isRtl ? "inline-start" : "inline-end"; @@ -7002,6 +6980,9 @@ function getOffsetData(state, sideParam, isRtl) { return data; } function useAnchorPositioning(params) { + return useAnchorPositioningWithHook(params, useBaseUIFloating); +} +function useAnchorPositioningWithHook(params, useFloatingHook) { const { // Public parameters anchor, @@ -7021,19 +7002,21 @@ function useAnchorPositioning(params) { floatingRootContext, mounted, collisionAvoidance, - shiftCrossAxis = false, + shift: shift4, nodeId, adaptiveOrigin: adaptiveOrigin2, lazyFlip = false, externalTree } = params; - const [mountSide, setMountSide] = React30.useState(null); + const [mountSide, setMountSide] = React29.useState(null); if (!mounted && mountSide !== null) { setMountSide(null); } const collisionAvoidanceSide = collisionAvoidance.side || "flip"; const collisionAvoidanceAlign = collisionAvoidance.align || "flip"; const collisionAvoidanceFallbackAxisSide = collisionAvoidance.fallbackAxisSide || "end"; + const shiftCrossAxis = shift4?.crossAxis ?? false; + const shiftRootBoundary = shift4?.rootBoundary; const anchorFn = typeof anchor === "function" ? anchor : void 0; const anchorFnCallback = useStableCallback(anchorFn); const anchorDep = anchorFn ? anchorFnCallback : anchor; @@ -7051,31 +7034,31 @@ function useAnchorPositioning(params) { }[sideParam]; const placement = align === "center" ? side : `${side}-${align}`; let collisionPadding = collisionPaddingParam; - const bias = 1; - const biasTop = sideParam === "bottom" ? bias : 0; - const biasBottom = sideParam === "top" ? bias : 0; - const biasLeft = sideParam === "right" ? bias : 0; - const biasRight = sideParam === "left" ? bias : 0; if (typeof collisionPadding === "number") { collisionPadding = { - top: collisionPadding + biasTop, - right: collisionPadding + biasRight, - bottom: collisionPadding + biasBottom, - left: collisionPadding + biasLeft + top: collisionPadding, + right: collisionPadding, + bottom: collisionPadding, + left: collisionPadding }; } else if (collisionPadding) { collisionPadding = { - top: (collisionPadding.top || 0) + biasTop, - right: (collisionPadding.right || 0) + biasRight, - bottom: (collisionPadding.bottom || 0) + biasBottom, - left: (collisionPadding.left || 0) + biasLeft + top: collisionPadding.top || 0, + right: collisionPadding.right || 0, + bottom: collisionPadding.bottom || 0, + left: collisionPadding.left || 0 }; } + const bias = 1; + const biasTop = sideParam === "bottom" ? bias : 0; + const biasBottom = sideParam === "top" ? bias : 0; + const biasLeft = sideParam === "right" ? bias : 0; + const biasRight = sideParam === "left" ? bias : 0; const commonCollisionProps = { boundary: collisionBoundary === "clipping-ancestors" ? "clippingAncestors" : collisionBoundary, padding: collisionPadding }; - const arrowRef = React30.useRef(null); + const arrowRef = React29.useRef(null); const sideOffsetRef = useValueAsRef(sideOffset); const alignOffsetRef = useValueAsRef(alignOffset); const sideOffsetDep = typeof sideOffset !== "function" ? sideOffset : 0; @@ -7101,46 +7084,37 @@ function useAnchorPositioning(params) { // Ensure the popup flips if it's been limited by its --available-height and it resizes. // Since the size() padding is smaller than the flip() padding, flip() will take precedence. padding: { - top: collisionPadding.top + bias, - right: collisionPadding.right + bias, - bottom: collisionPadding.bottom + bias, - left: collisionPadding.left + bias + top: collisionPadding.top + bias + biasTop, + right: collisionPadding.right + bias + biasRight, + bottom: collisionPadding.bottom + bias + biasBottom, + left: collisionPadding.left + bias + biasLeft }, mainAxis: !shiftCrossAxis && collisionAvoidanceSide === "flip", crossAxis: collisionAvoidanceAlign === "flip" ? "alignment" : false, fallbackAxisSideDirection: collisionAvoidanceFallbackAxisSide }); - const shiftMiddleware = shiftDisabled ? null : shift3((data) => { - const html = ownerDocument(data.elements.floating).documentElement; - return { - ...commonCollisionProps, - // Use the Layout Viewport to avoid shifting around when pinch-zooming - // for context menus. - rootBoundary: shiftCrossAxis ? { - x: 0, - y: 0, - width: html.clientWidth, - height: html.clientHeight - } : void 0, - mainAxis: collisionAvoidanceAlign !== "none", - crossAxis: crossAxisShiftEnabled, - limiter: sticky || shiftCrossAxis ? void 0 : limitShift3((limitData) => { - if (!arrowRef.current) { - return {}; - } - const { - width, - height - } = arrowRef.current.getBoundingClientRect(); - const sideAxis = getSideAxis(getSide(limitData.placement)); - const arrowSize = sideAxis === "y" ? width : height; - const offsetAmount = sideAxis === "y" ? collisionPadding.left + collisionPadding.right : collisionPadding.top + collisionPadding.bottom; - return { - offset: arrowSize / 2 + offsetAmount / 2 - }; - }) - }; - }, [commonCollisionProps, sticky, shiftCrossAxis, collisionPadding, collisionAvoidanceAlign]); + const shiftMiddleware = shiftDisabled ? null : shift3({ + ...commonCollisionProps, + // Use the Layout Viewport to avoid shifting around when pinch-zooming. + rootBoundary: shiftRootBoundary, + mainAxis: collisionAvoidanceAlign !== "none", + crossAxis: crossAxisShiftEnabled, + limiter: sticky || shiftCrossAxis ? void 0 : limitShift3((limitData) => { + if (!arrowRef.current) { + return {}; + } + const { + width, + height + } = arrowRef.current.getBoundingClientRect(); + const sideAxis = getSideAxis(getSide(limitData.placement)); + const arrowSize = sideAxis === "y" ? width : height; + const offsetAmount = sideAxis === "y" ? collisionPadding.left + collisionPadding.right : collisionPadding.top + collisionPadding.bottom; + return { + offset: arrowSize / 2 + offsetAmount / 2 + }; + }) + }, [commonCollisionProps, sticky, shiftCrossAxis, shiftRootBoundary, collisionPadding, collisionAvoidanceAlign]); if (collisionAvoidanceSide === "shift" || collisionAvoidanceAlign === "shift" || align === "center") { middleware.push(shiftMiddleware, flipMiddleware); } else { @@ -7160,8 +7134,8 @@ function useAnchorPositioning(params) { return; } const floatingStyle = floating.style; - floatingStyle.setProperty("--available-width", `${availableWidth}px`); - floatingStyle.setProperty("--available-height", `${availableHeight}px`); + floatingStyle.setProperty(AVAILABLE_WIDTH_VAR, `${availableWidth}px`); + floatingStyle.setProperty(AVAILABLE_HEIGHT_VAR, `${availableHeight}px`); const dpr = getWindow(floating).devicePixelRatio || 1; const { x: x3, @@ -7224,7 +7198,7 @@ function useAnchorPositioning(params) { }); } }, [mounted, floatingRootContext]); - const autoUpdateOptions = React30.useMemo(() => ({ + const autoUpdateOptions = React29.useMemo(() => ({ elementResize: !disableAnchorTracking && typeof ResizeObserver !== "undefined", layoutShift: !disableAnchorTracking && typeof IntersectionObserver !== "undefined" }), [disableAnchorTracking]); @@ -7239,7 +7213,7 @@ function useAnchorPositioning(params) { context, isPositioned, floatingStyles: originalFloatingStyles - } = useFloating2({ + } = useFloatingHook({ rootContext: floatingRootContext, open: keepMounted ? mounted : void 0, placement, @@ -7254,21 +7228,34 @@ function useAnchorPositioning(params) { sideY } = middlewareData.adaptiveOrigin || DEFAULT_SIDES; const resolvedPosition = isPositioned ? positionMethod : "fixed"; - const floatingStyles = React30.useMemo(() => { - const base = adaptiveOrigin2 ? { - position: resolvedPosition, - [sideX]: x2, - [sideY]: y2 - } : { - position: resolvedPosition, - ...originalFloatingStyles - }; + const floatingStyles = React29.useMemo(() => { + let base; + if (!isPositioned) { + base = { + position: resolvedPosition, + top: 0, + left: 0 + }; + } else if (adaptiveOrigin2) { + base = { + position: resolvedPosition, + [sideX]: x2, + [sideY]: y2 + }; + } else { + base = { + ...originalFloatingStyles, + position: resolvedPosition + }; + } + base[AVAILABLE_WIDTH_VAR] = "100vw"; + base[AVAILABLE_HEIGHT_VAR] = "100vh"; if (!isPositioned) { base.opacity = 0; } return base; }, [adaptiveOrigin2, resolvedPosition, sideX, x2, sideY, y2, originalFloatingStyles, isPositioned]); - const registeredPositionReferenceRef = React30.useRef(null); + const registeredPositionReferenceRef = React29.useRef(null); useIsoLayoutEffect(() => { if (!mounted) { return; @@ -7282,7 +7269,7 @@ function useAnchorPositioning(params) { registeredPositionReferenceRef.current = finalAnchor; } }, [mounted, refs, anchorDep, anchorValueRef]); - React30.useEffect(() => { + React29.useEffect(() => { if (!mounted) { return; } @@ -7295,7 +7282,7 @@ function useAnchorPositioning(params) { registeredPositionReferenceRef.current = anchorValue.current; } }, [mounted, refs, anchorDep, anchorValueRef]); - React30.useEffect(() => { + React29.useEffect(() => { if (keepMounted && mounted && elements2.reference && elements2.floating) { return autoUpdate(elements2.reference, elements2.floating, update2, autoUpdateOptions); } @@ -7306,17 +7293,17 @@ function useAnchorPositioning(params) { const renderedAlign = getAlignment(renderedPlacement) || "center"; const anchorHidden = Boolean(middlewareData.hide?.referenceHidden); useIsoLayoutEffect(() => { - if (lazyFlip && mounted && isPositioned) { + if (lazyFlip && mounted && isPositioned && renderedSide !== side) { setMountSide(renderedSide); } - }, [lazyFlip, mounted, isPositioned, renderedSide]); - const arrowStyles = React30.useMemo(() => ({ + }, [lazyFlip, mounted, isPositioned, renderedSide, side]); + const arrowStyles = React29.useMemo(() => ({ position: "absolute", top: middlewareData.arrow?.y, left: middlewareData.arrow?.x }), [middlewareData.arrow]); const arrowUncentered = middlewareData.arrow?.centerOffset !== 0; - return React30.useMemo(() => ({ + return React29.useMemo(() => ({ positionerStyles: floatingStyles, arrowStyles, arrowRef, @@ -7335,7 +7322,7 @@ function isRef(param) { return param != null && "current" in param; } -// node_modules/@base-ui/react/utils/getDisabledMountTransitionStyles.mjs +// node_modules/@base-ui/react/internals/getDisabledMountTransitionStyles.mjs function getDisabledMountTransitionStyles(transitionStatus) { return transitionStatus === "starting" ? DISABLED_TRANSITIONS_STYLE : EMPTY_OBJECT; } @@ -7368,17 +7355,17 @@ function usePositioner(componentProps, state, { } // node_modules/@base-ui/react/utils/usePopupViewport.mjs -var React34 = __toESM(require_react(), 1); +var React33 = __toESM(require_react(), 1); var ReactDOM6 = __toESM(require_react_dom(), 1); // node_modules/@base-ui/utils/usePreviousValue.mjs -var React31 = __toESM(require_react(), 1); +var React30 = __toESM(require_react(), 1); function usePreviousValue(value) { - const [state, setState] = React31.useState({ + const [state, setState] = React30.useState({ current: value, previous: null }); - if (value !== state.current) { + if (!Object.is(value, state.current)) { setState({ current: value, previous: state.current @@ -7388,7 +7375,7 @@ function usePreviousValue(value) { } // node_modules/@base-ui/react/utils/usePopupAutoResize.mjs -var React32 = __toESM(require_react(), 1); +var React31 = __toESM(require_react(), 1); // node_modules/@base-ui/react/utils/getCssDimensions.mjs function getCssDimensions2(element) { @@ -7421,29 +7408,14 @@ function usePopupAutoResize(parameters) { side, direction } = parameters; - const runOnceAnimationsFinish = useAnimationsFinished(popupElement, true, false); + const runOnceAnimationsFinish = useAnimationsFinished(popupElement, true); const animationFrame = useAnimationFrame(); - const committedDimensionsRef = React32.useRef(null); - const isInitialRenderRef = React32.useRef(true); - const restoreAnchoringStylesRef = React32.useRef(NOOP); + const committedDimensionsRef = React31.useRef(null); + const isInitialRenderRef = React31.useRef(true); + const restoreAnchoringStylesRef = React31.useRef(NOOP); const onMeasureLayout = useStableCallback(onMeasureLayoutParam); const onMeasureLayoutComplete = useStableCallback(onMeasureLayoutCompleteParam); - const anchoringStyles = React32.useMemo(() => { - let isOriginSide = side === "top"; - let isPhysicalLeft = side === "left"; - if (direction === "rtl") { - isOriginSide = isOriginSide || side === "inline-end"; - isPhysicalLeft = isPhysicalLeft || side === "inline-end"; - } else { - isOriginSide = isOriginSide || side === "inline-start"; - isPhysicalLeft = isPhysicalLeft || side === "inline-start"; - } - return isOriginSide ? { - position: "absolute", - [side === "top" ? "bottom" : "top"]: "0", - [isPhysicalLeft ? "right" : "left"]: "0" - } : EMPTY_OBJECT; - }, [side, direction]); + const anchoringStyles = React31.useMemo(() => getPopupAnchoringStyles(side, direction), [side, direction]); useIsoLayoutEffect(() => { if (!mounted) { restoreAnchoringStylesRef.current = NOOP; @@ -7510,6 +7482,18 @@ function usePopupAutoResize(parameters) { }; }, [content, popupElement, positionerElement, runOnceAnimationsFinish, animationFrame, mounted, onMeasureLayout, onMeasureLayoutComplete, anchoringStyles]); } +function getPopupAnchoringStyles(side, direction) { + const isPhysicalTop = side === "top"; + const isPhysicalLeft = side === "left" || side === (direction === "rtl" ? "inline-end" : "inline-start"); + if (!isPhysicalTop && !isPhysicalLeft) { + return EMPTY_OBJECT; + } + return { + position: "absolute", + [isPhysicalTop ? "bottom" : "top"]: "0", + [isPhysicalLeft ? "right" : "left"]: "0" + }; +} function overrideElementStyle(element, property, value) { const originalValue = element.style.getPropertyValue(property); element.style.setProperty(property, value); @@ -7540,13 +7524,13 @@ function setPositionerCssSize(positionerElement, size4) { } // node_modules/@base-ui/react/direction-provider/DirectionProvider.mjs -var React33 = __toESM(require_react(), 1); +var React32 = __toESM(require_react(), 1); var import_jsx_runtime5 = __toESM(require_jsx_runtime(), 1); var DirectionProvider = function DirectionProvider2(props) { const { direction = "ltr" } = props; - const contextValue = React33.useMemo(() => ({ + const contextValue = React32.useMemo(() => ({ direction }), [direction]); return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(DirectionContext.Provider, { @@ -7556,78 +7540,164 @@ var DirectionProvider = function DirectionProvider2(props) { }; if (true) DirectionProvider.displayName = "DirectionProvider"; -// node_modules/@base-ui/react/utils/usePopupViewport.mjs -var import_jsx_runtime6 = __toESM(require_jsx_runtime(), 1); -function usePopupViewport(parameters) { - const { - store, - side, - cssVars, - children - } = parameters; - const direction = useDirection(); - const activeTrigger = store.useState("activeTriggerElement"); - const activeTriggerId = store.useState("activeTriggerId"); - const open = store.useState("open"); - const payload = store.useState("payload"); - const mounted = store.useState("mounted"); - const popupElement = store.useState("popupElement"); - const positionerElement = store.useState("positionerElement"); - const previousActiveTrigger = usePreviousValue(open ? activeTrigger : null); - const currentContentKey = usePopupContentKey(activeTriggerId, payload); - const capturedNodeRef = React34.useRef(null); - const [previousContentNode, setPreviousContentNode] = React34.useState(null); - const [newTriggerOffset, setNewTriggerOffset] = React34.useState(null); - const currentContainerRef = React34.useRef(null); - const previousContainerRef = React34.useRef(null); - const onAnimationsFinished = useAnimationsFinished(currentContainerRef, true, false); - const cleanupFrame = useAnimationFrame(); - const [previousContentDimensions, setPreviousContentDimensions] = React34.useState(null); - const [showStartingStyleAttribute, setShowStartingStyleAttribute] = React34.useState(false); - useIsoLayoutEffect(() => { - store.set("hasViewport", true); - return () => { - store.set("hasViewport", false); - }; - }, [store]); - const handleMeasureLayout = useStableCallback(() => { - currentContainerRef.current?.style.setProperty("animation", "none"); - currentContainerRef.current?.style.setProperty("transition", "none"); - previousContainerRef.current?.style.setProperty("display", "none"); - }); - const handleMeasureLayoutComplete = useStableCallback((previousDimensions) => { - currentContainerRef.current?.style.removeProperty("animation"); - currentContainerRef.current?.style.removeProperty("transition"); - previousContainerRef.current?.style.removeProperty("display"); - if (previousDimensions) { - setPreviousContentDimensions(previousDimensions); - } - }); - const lastHandledTriggerRef = React34.useRef(null); - useIsoLayoutEffect(() => { - if (!open || !mounted) { - lastHandledTriggerRef.current = null; +// node_modules/@base-ui/react/utils/adaptiveOriginMiddleware.mjs +var adaptiveOrigin = { + name: "adaptiveOrigin", + async fn(state) { + const { + x: rawX, + y: rawY, + rects: { + floating: floatRect + }, + elements: { + floating + }, + platform: platform3, + strategy, + placement + } = state; + const win = getWindow(floating); + const styles = win.getComputedStyle(floating); + const hasTransition = styles.transitionDuration !== "0s" && styles.transitionDuration !== ""; + if (!hasTransition) { + return { + x: rawX, + y: rawY, + data: DEFAULT_SIDES + }; } - }, [open, mounted]); + const offsetParent = await platform3.getOffsetParent?.(floating); + let offsetDimensions = { + width: 0, + height: 0 + }; + if (strategy === "fixed" && win?.visualViewport) { + offsetDimensions = { + width: win.visualViewport.width, + height: win.visualViewport.height + }; + } else if (offsetParent === win) { + const doc = ownerDocument(floating); + offsetDimensions = { + width: doc.documentElement.clientWidth, + height: doc.documentElement.clientHeight + }; + } else if (await platform3.isElement?.(offsetParent)) { + offsetDimensions = await platform3.getDimensions(offsetParent); + } + const currentSide = getSide(placement); + let x2 = rawX; + let y2 = rawY; + if (currentSide === "left") { + x2 = offsetDimensions.width - (rawX + floatRect.width); + } + if (currentSide === "top") { + y2 = offsetDimensions.height - (rawY + floatRect.height); + } + const sideX = currentSide === "left" ? "right" : DEFAULT_SIDES.sideX; + const sideY = currentSide === "top" ? "bottom" : DEFAULT_SIDES.sideY; + return { + x: x2, + y: y2, + data: { + sideX, + sideY + } + }; + } +}; + +// node_modules/@base-ui/react/utils/usePopupViewport.mjs +var import_jsx_runtime6 = __toESM(require_jsx_runtime(), 1); +var popupViewportStateMapping = { + activationDirection: (value) => value ? { + "data-activation-direction": value + } : null +}; +function usePopupViewport(parameters) { + const { + store, + side, + children + } = parameters; + const direction = useDirection(); + const activeTrigger = store.useState("activeTriggerElement"); + const activeTriggerId = store.useState("activeTriggerId"); + const open = store.useState("open"); + const payload = store.useState("payload"); + const mounted = store.useState("mounted"); + const popupElement = store.useState("popupElement"); + const positionerElement = store.useState("positionerElement"); + const previousActiveTrigger = usePreviousValue(open ? activeTrigger : null); + const currentContentKey = usePopupContentKey(activeTriggerId, payload); + const capturedNodeRef = React33.useRef(null); + const [previousContentNode, setPreviousContentNode] = React33.useState(null); + const [newTriggerOffset, setNewTriggerOffset] = React33.useState(null); + const currentContainerRef = React33.useRef(null); + const previousContainerRef = React33.useRef(null); + const onAnimationsFinished = useAnimationsFinished(currentContainerRef, true); + const cleanupFrame = useAnimationFrame(); + const cleanupControllerRef = React33.useRef(null); + const [previousContentDimensions, setPreviousContentDimensions] = React33.useState(null); + const [showStartingStyleAttribute, setShowStartingStyleAttribute] = React33.useState(false); + useIsoLayoutEffect(() => { + store.set("adaptiveOrigin", adaptiveOrigin); + return () => { + store.set("adaptiveOrigin", void 0); + }; + }, [store]); + const handleMeasureLayout = useStableCallback(() => { + currentContainerRef.current?.style.setProperty("animation", "none"); + currentContainerRef.current?.style.setProperty("transition", "none"); + previousContainerRef.current?.style.setProperty("display", "none"); + }); + const handleMeasureLayoutComplete = useStableCallback((previousDimensions) => { + currentContainerRef.current?.style.removeProperty("animation"); + currentContainerRef.current?.style.removeProperty("transition"); + previousContainerRef.current?.style.removeProperty("display"); + if (previousDimensions) { + setPreviousContentDimensions(previousDimensions); + } + }); + const armViewportCleanup = useStableCallback(() => { + cleanupControllerRef.current?.abort(); + const controller = new AbortController(); + cleanupControllerRef.current = controller; + onAnimationsFinished(() => { + setPreviousContentNode(null); + setPreviousContentDimensions(null); + capturedNodeRef.current = null; + }, controller.signal); + }); + const lastHandledTriggerRef = React33.useRef(null); + useIsoLayoutEffect(() => { + if (!open || !mounted) { + lastHandledTriggerRef.current = null; + } + }, [open, mounted]); useIsoLayoutEffect(() => { if (activeTrigger && previousActiveTrigger && activeTrigger !== previousActiveTrigger && lastHandledTriggerRef.current !== activeTrigger && capturedNodeRef.current) { setPreviousContentNode(capturedNodeRef.current); setShowStartingStyleAttribute(true); const offset4 = calculateRelativePosition(previousActiveTrigger, activeTrigger); setNewTriggerOffset(offset4); - cleanupFrame.request(() => { - ReactDOM6.flushSync(() => { - setShowStartingStyleAttribute(false); - }); - onAnimationsFinished(() => { - setPreviousContentNode(null); - setPreviousContentDimensions(null); - capturedNodeRef.current = null; - }); - }); lastHandledTriggerRef.current = activeTrigger; } - }, [activeTrigger, previousActiveTrigger, previousContentNode, onAnimationsFinished, cleanupFrame]); + }, [activeTrigger, previousActiveTrigger]); + useIsoLayoutEffect(() => { + if (previousContentNode == null) { + return; + } + cleanupControllerRef.current?.abort(); + setShowStartingStyleAttribute(true); + cleanupFrame.request(() => { + ReactDOM6.flushSync(() => { + setShowStartingStyleAttribute(false); + }); + armViewportCleanup(); + }); + }, [currentContentKey, previousContentNode, armViewportCleanup, cleanupFrame]); useIsoLayoutEffect(() => { const source = currentContainerRef.current; if (!source) { @@ -7648,15 +7718,15 @@ function usePopupViewport(parameters) { children }, currentContentKey); } else { - childrenToRender = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(React34.Fragment, { + childrenToRender = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(React33.Fragment, { children: [/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { "data-previous": true, inert: inertValue(true), ref: previousContainerRef, style: { ...previousContentDimensions ? { - [cssVars.popupWidth]: `${previousContentDimensions.width}px`, - [cssVars.popupHeight]: `${previousContentDimensions.height}px` + "--popup-width": `${previousContentDimensions.width}px`, + "--popup-height": `${previousContentDimensions.height}px` } : null, position: "absolute" }, @@ -7727,10 +7797,10 @@ function calculateRelativePosition(from, to) { }; } function usePopupContentKey(activeTriggerId, payload) { - const [contentKey, setContentKey] = React34.useState(0); - const previousActiveTriggerIdRef = React34.useRef(activeTriggerId); - const previousPayloadRef = React34.useRef(payload); - const pendingPayloadUpdateRef = React34.useRef(false); + const [contentKey, setContentKey] = React33.useState(0); + const previousActiveTriggerIdRef = React33.useRef(activeTriggerId); + const previousPayloadRef = React33.useRef(payload); + const pendingPayloadUpdateRef = React33.useRef(false); useIsoLayoutEffect(() => { const previousActiveTriggerId = previousActiveTriggerIdRef.current; const previousPayload = previousPayloadRef.current; @@ -7750,10 +7820,10 @@ function usePopupContentKey(activeTriggerId, payload) { } // node_modules/@base-ui/react/utils/FloatingPortalLite.mjs -var React35 = __toESM(require_react(), 1); +var React34 = __toESM(require_react(), 1); var ReactDOM7 = __toESM(require_react_dom(), 1); var import_jsx_runtime7 = __toESM(require_jsx_runtime(), 1); -var FloatingPortalLite = /* @__PURE__ */ React35.forwardRef(function FloatingPortalLite2(componentProps, forwardedRef) { +var FloatingPortalLite = /* @__PURE__ */ React34.forwardRef(function FloatingPortalLite2(componentProps, forwardedRef) { const { children, container, @@ -7763,8 +7833,8 @@ var FloatingPortalLite = /* @__PURE__ */ React35.forwardRef(function FloatingPor ...elementProps } = componentProps; const { - portalNode, - portalSubtree + node: portalNode, + subtree: portalSubtree } = useFloatingPortalNode({ container, ref: forwardedRef, @@ -7774,7 +7844,7 @@ var FloatingPortalLite = /* @__PURE__ */ React35.forwardRef(function FloatingPor if (!portalSubtree && !portalNode) { return null; } - return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(React35.Fragment, { + return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(React34.Fragment, { children: [portalSubtree, portalNode && /* @__PURE__ */ ReactDOM7.createPortal(children, portalNode)] }); }); @@ -7796,14 +7866,14 @@ __export(index_parts_exports, { }); // node_modules/@base-ui/react/tooltip/root/TooltipRoot.mjs -var React38 = __toESM(require_react(), 1); +var React37 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/root/TooltipRootContext.mjs -var React36 = __toESM(require_react(), 1); -var TooltipRootContext = /* @__PURE__ */ React36.createContext(void 0); +var React35 = __toESM(require_react(), 1); +var TooltipRootContext = /* @__PURE__ */ React35.createContext(void 0); if (true) TooltipRootContext.displayName = "TooltipRootContext"; function useTooltipRootContext(optional) { - const context = React36.useContext(TooltipRootContext); + const context = React35.useContext(TooltipRootContext); if (context === void 0 && !optional) { throw new Error(true ? "Base UI: TooltipRootContext is missing. Tooltip parts must be placed within ." : formatErrorMessage_default(72)); } @@ -7811,33 +7881,23 @@ function useTooltipRootContext(optional) { } // node_modules/@base-ui/react/tooltip/store/TooltipStore.mjs -var React37 = __toESM(require_react(), 1); +var React36 = __toESM(require_react(), 1); var selectors2 = { ...popupStoreSelectors, - disabled: createSelector((state) => state.disabled), - instantType: createSelector((state) => state.instantType), - isInstantPhase: createSelector((state) => state.isInstantPhase), - trackCursorAxis: createSelector((state) => state.trackCursorAxis), - disableHoverablePopup: createSelector((state) => state.disableHoverablePopup), - lastOpenChangeReason: createSelector((state) => state.openChangeReason), - closeOnClick: createSelector((state) => state.closeOnClick), - closeDelay: createSelector((state) => state.closeDelay), - hasViewport: createSelector((state) => state.hasViewport) -}; -var TooltipStore = class _TooltipStore extends ReactStore { - constructor(initialState, floatingId, nested = false) { + disabled: (state) => state.disabled, + instantType: (state) => state.instantType, + isInstantPhase: (state) => state.isInstantPhase, + trackCursorAxis: (state) => state.trackCursorAxis, + disableHoverablePopup: (state) => state.disableHoverablePopup, + lastOpenChangeReason: (state) => state.openChangeReason, + closeOnClick: (state) => state.closeOnClick, + closeDelay: (state) => state.closeDelay, + adaptiveOrigin: (state) => state.adaptiveOrigin +}; +var TooltipStore = class extends ReactStore { + constructor(initialState, floatingId, nested) { const triggerElements = new PopupTriggerMap(); - const state = { - ...createInitialState(), - ...initialState - }; - state.floatingRootContext = createPopupFloatingRootContext(triggerElements, floatingId, nested); - super(state, { - popupRef: /* @__PURE__ */ React37.createRef(), - onOpenChange: void 0, - onOpenChangeComplete: void 0, - triggerElements - }, selectors2); + super(createInitialState(initialState, triggerElements, floatingId, nested), createInitialContext(triggerElements), selectors2); } setOpen = (nextOpen, eventDetails) => { applyPopupOpenChange(this, nextOpen, eventDetails, { @@ -7850,13 +7910,17 @@ var TooltipStore = class _TooltipStore extends ReactStore { cancelPendingOpen(event) { this.state.floatingRootContext.dispatchOpenChange(false, createChangeEventDetails(reason_parts_exports.triggerPress, event)); } - static useStore(externalStore, initialState) { - const store = usePopupStore(externalStore, (floatingId, nested) => new _TooltipStore(initialState, floatingId, nested)).store; - return store; - } }; -function createInitialState() { - return { +function createNullTooltipStore() { + const triggerElements = new PopupTriggerMap(); + const store = new NullStore(Object.freeze(createInitialState(void 0, triggerElements)), Object.freeze(createInitialContext(triggerElements)), selectors2); + return Object.assign(store, { + setOpen: NOOP, + cancelPendingOpen: NOOP + }); +} +function createInitialState(initialState, triggerElements, floatingId, nested = false) { + const state = { ...createInitialPopupStoreState(), disabled: false, instantType: void 0, @@ -7866,7 +7930,18 @@ function createInitialState() { openChangeReason: null, closeOnClick: true, closeDelay: 0, - hasViewport: false + adaptiveOrigin: void 0, + ...initialState + }; + state.floatingRootContext = createPopupFloatingRootContext(triggerElements, floatingId, nested); + return state; +} +function createInitialContext(triggerElements) { + return { + popupRef: /* @__PURE__ */ React36.createRef(), + onOpenChange: void 0, + onOpenChangeComplete: void 0, + triggerElements }; } @@ -7887,13 +7962,12 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { defaultTriggerId: defaultTriggerIdProp = null, children } = props; - const store = TooltipStore.useStore(handle?.store, { + const store = usePopupRootStore((floatingId, nested) => new TooltipStore({ open: defaultOpen, openProp, activeTriggerId: defaultTriggerIdProp, triggerIdProp - }); - useInitialOpenSync(store, openProp, defaultOpen, defaultTriggerIdProp); + }, floatingId, nested)); store.useControlledProp("openProp", openProp); store.useControlledProp("triggerIdProp", triggerIdProp); store.useContextCallback("onOpenChange", onOpenChange); @@ -7905,9 +7979,9 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { const payload = store.useState("payload"); store.useSyncedValues({ trackCursorAxis, - disableHoverablePopup + disableHoverablePopup, + disabled: disabled2 }); - store.useSyncedValue("disabled", disabled2); useImplicitActiveTrigger(store, { closeOnActiveTriggerUnmount: true }); @@ -7918,7 +7992,7 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { const isInstantPhase = store.useState("isInstantPhase"); const instantType = store.useState("instantType"); const lastOpenChangeReason = store.useState("lastOpenChangeReason"); - const previousInstantTypeRef = React38.useRef(null); + const previousInstantTypeRef = React37.useRef(null); useIsoLayoutEffect(() => { if (openState && disabled2) { store.setOpen(false, createChangeEventDetails(reason_parts_exports.disabled)); @@ -7942,17 +8016,17 @@ var TooltipRoot = fastComponent(function TooltipRoot2(props) { } } }, [store, activeTriggerId, open]); - const handleImperativeClose = React38.useCallback(() => { - store.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction)); - }, [store]); - React38.useImperativeHandle(actionsRef, () => ({ + React37.useImperativeHandle(actionsRef, () => ({ unmount: forceUnmount, - close: handleImperativeClose - }), [forceUnmount, handleImperativeClose]); + close: () => store.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction)) + }), [forceUnmount, store]); const shouldRenderInteractions = open || mounted || !disabled2 && trackCursorAxis !== "none"; return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(TooltipRootContext.Provider, { value: store, - children: [shouldRenderInteractions && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TooltipInteractions, { + children: [handle && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(PopupHandleAttachment, { + handle, + store + }), shouldRenderInteractions && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TooltipInteractions, { store, disabled: disabled2, trackCursorAxis @@ -7976,35 +8050,26 @@ function TooltipInteractions({ enabled: !disabled2 && trackCursorAxis !== "none", axis: trackCursorAxis === "none" ? void 0 : trackCursorAxis }); - const activeTriggerProps = React38.useMemo(() => mergeProps(clientPoint.reference, dismiss.reference), [clientPoint.reference, dismiss.reference]); - const inactiveTriggerProps = React38.useMemo(() => mergeProps(clientPoint.trigger, dismiss.trigger), [clientPoint.trigger, dismiss.trigger]); - const popupProps = React38.useMemo(() => mergeProps(FOCUSABLE_POPUP_PROPS, clientPoint.floating, dismiss.floating), [clientPoint.floating, dismiss.floating]); + const triggerProps = React37.useMemo(() => mergeProps(clientPoint.reference, dismiss.reference), [clientPoint.reference, dismiss.reference]); usePopupInteractionProps(store, { - activeTriggerProps, - inactiveTriggerProps, - popupProps + activeTriggerProps: triggerProps, + inactiveTriggerProps: triggerProps, + popupProps: dismiss.floating ?? EMPTY_OBJECT }); return null; } // node_modules/@base-ui/react/tooltip/trigger/TooltipTrigger.mjs -var React40 = __toESM(require_react(), 1); +var React39 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/provider/TooltipProviderContext.mjs -var React39 = __toESM(require_react(), 1); -var TooltipProviderContext = /* @__PURE__ */ React39.createContext(void 0); +var React38 = __toESM(require_react(), 1); +var TooltipProviderContext = /* @__PURE__ */ React38.createContext(void 0); if (true) TooltipProviderContext.displayName = "TooltipProviderContext"; function useTooltipProviderContext() { - return React39.useContext(TooltipProviderContext); + return React38.useContext(TooltipProviderContext); } -// node_modules/@base-ui/react/tooltip/trigger/TooltipTriggerDataAttributes.mjs -var TooltipTriggerDataAttributes = (function(TooltipTriggerDataAttributes2) { - TooltipTriggerDataAttributes2[TooltipTriggerDataAttributes2["popupOpen"] = CommonTriggerDataAttributes.popupOpen] = "popupOpen"; - TooltipTriggerDataAttributes2["triggerDisabled"] = "data-trigger-disabled"; - return TooltipTriggerDataAttributes2; -})({}); - // node_modules/@base-ui/react/tooltip/utils/constants.mjs var OPEN_DELAY = 600; @@ -8029,13 +8094,9 @@ function getTargetElement(event) { function closestEnabledTooltipTrigger(element) { let current = element; while (current) { - if (current.hasAttribute(TOOLTIP_TRIGGER_IDENTIFIER)) { - return current; - } - const parentElement = current.parentElement; - if (parentElement) { - current = parentElement; - continue; + const trigger = current.closest(`[${TOOLTIP_TRIGGER_IDENTIFIER}]`); + if (trigger) { + return trigger; } const root = current.getRootNode(); current = "host" in root && isElement(root.host) ? root.host : null; @@ -8057,7 +8118,8 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f ...elementProps } = componentProps; const rootContext = useTooltipRootContext(true); - const store = handle?.store ?? rootContext; + const handleStore = usePopupHandleStore(handle); + const store = handleStore ?? rootContext; if (!store) { throw new Error(true ? "Base UI: must be either used within a component or provided with a handle." : formatErrorMessage_default(82)); } @@ -8065,7 +8127,7 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f const isTriggerActive = store.useState("isTriggerActive", thisTriggerId); const isOpenedByThisTrigger = store.useState("isOpenedByTrigger", thisTriggerId); const floatingRootContext = store.useState("floatingRootContext"); - const triggerElementRef = React40.useRef(null); + const triggerElementRef = React39.useRef(null); const delayWithDefault = delay ?? OPEN_DELAY; const closeDelayWithDefault = closeDelay ?? 0; const { @@ -8076,7 +8138,7 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f closeOnClick, closeDelay: closeDelayWithDefault }); - const providerContext = useTooltipProviderContext(); + const providerDelay = useTooltipProviderContext(); const { delayRef, isInstantPhase, @@ -8091,21 +8153,14 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f const disabledRef = useValueAsRef(disabled2); const trackCursorAxis = store.useState("trackCursorAxis"); const disableHoverablePopup = store.useState("disableHoverablePopup"); - const isNestedTriggerHoveredRef = React40.useRef(false); + const isNestedTriggerHoveredRef = React39.useRef(false); const nestedTriggerOpenTimeout = useTimeout(); - const pointerTypeRef = React40.useRef(void 0); + const pointerTypeRef = React39.useRef(void 0); function getOpenDelay() { - const providerDelay = providerContext?.delay; - const groupOpenValue = typeof delayRef.current === "object" ? delayRef.current.open : void 0; - let computedOpenDelay = delayWithDefault; - if (hasProvider) { - if (groupOpenValue !== 0) { - computedOpenDelay = delay ?? providerDelay ?? delayWithDefault; - } else { - computedOpenDelay = 0; - } + if (!hasProvider) { + return delayWithDefault; } - return computedOpenDelay; + return getDelay(delayRef.current, "open") === 0 ? 0 : delay ?? providerDelay ?? OPEN_DELAY; } function isEnabledNestedTriggerTarget(target) { const triggerEl = triggerElementRef.current; @@ -8133,13 +8188,13 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f handleClose: !disableHoverablePopup && trackCursorAxis !== "both" ? safePolygon() : null, restMs: getOpenDelay, delay() { - const closeValue = typeof delayRef.current === "object" ? delayRef.current.close : void 0; - let computedCloseDelay = closeDelayWithDefault; if (closeDelay == null && hasProvider) { - computedCloseDelay = closeValue; + return { + close: getDelay(delayRef.current, "close") + }; } return { - close: computedCloseDelay + close: closeDelayWithDefault }; }, triggerElementRef, @@ -8216,7 +8271,7 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f } }, id: thisTriggerId, - [TooltipTriggerDataAttributes.triggerDisabled]: disabled2 ? "" : void 0, + "data-trigger-disabled": disabled2 ? "" : void 0, [TOOLTIP_TRIGGER_IDENTIFIER]: disabled2 ? void 0 : "" }, elementProps], stateAttributesMapping: triggerOpenStateMapping @@ -8226,14 +8281,14 @@ var TooltipTrigger = fastComponentRef(function TooltipTrigger2(componentProps, f if (true) TooltipTrigger.displayName = "TooltipTrigger"; // node_modules/@base-ui/react/tooltip/portal/TooltipPortal.mjs -var React42 = __toESM(require_react(), 1); +var React41 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/portal/TooltipPortalContext.mjs -var React41 = __toESM(require_react(), 1); -var TooltipPortalContext = /* @__PURE__ */ React41.createContext(void 0); +var React40 = __toESM(require_react(), 1); +var TooltipPortalContext = /* @__PURE__ */ React40.createContext(void 0); if (true) TooltipPortalContext.displayName = "TooltipPortalContext"; function useTooltipPortalContext() { - const value = React41.useContext(TooltipPortalContext); + const value = React40.useContext(TooltipPortalContext); if (value === void 0) { throw new Error(true ? "Base UI: is missing." : formatErrorMessage_default(70)); } @@ -8242,7 +8297,7 @@ function useTooltipPortalContext() { // node_modules/@base-ui/react/tooltip/portal/TooltipPortal.mjs var import_jsx_runtime9 = __toESM(require_jsx_runtime(), 1); -var TooltipPortal = /* @__PURE__ */ React42.forwardRef(function TooltipPortal2(props, forwardedRef) { +var TooltipPortal = /* @__PURE__ */ React41.forwardRef(function TooltipPortal2(props, forwardedRef) { const { keepMounted = false, ...portalProps @@ -8264,14 +8319,14 @@ var TooltipPortal = /* @__PURE__ */ React42.forwardRef(function TooltipPortal2(p if (true) TooltipPortal.displayName = "TooltipPortal"; // node_modules/@base-ui/react/tooltip/positioner/TooltipPositioner.mjs -var React44 = __toESM(require_react(), 1); +var React43 = __toESM(require_react(), 1); // node_modules/@base-ui/react/tooltip/positioner/TooltipPositionerContext.mjs -var React43 = __toESM(require_react(), 1); -var TooltipPositionerContext = /* @__PURE__ */ React43.createContext(void 0); +var React42 = __toESM(require_react(), 1); +var TooltipPositionerContext = /* @__PURE__ */ React42.createContext(void 0); if (true) TooltipPositionerContext.displayName = "TooltipPositionerContext"; function useTooltipPositionerContext() { - const context = React43.useContext(TooltipPositionerContext); + const context = React42.useContext(TooltipPositionerContext); if (context === void 0) { throw new Error(true ? "Base UI: TooltipPositionerContext is missing. TooltipPositioner parts must be placed within ." : formatErrorMessage_default(71)); } @@ -8280,7 +8335,7 @@ function useTooltipPositionerContext() { // node_modules/@base-ui/react/tooltip/positioner/TooltipPositioner.mjs var import_jsx_runtime10 = __toESM(require_jsx_runtime(), 1); -var TooltipPositioner = /* @__PURE__ */ React44.forwardRef(function TooltipPositioner2(componentProps, forwardedRef) { +var TooltipPositioner = /* @__PURE__ */ React43.forwardRef(function TooltipPositioner2(componentProps, forwardedRef) { const { render, className, @@ -8308,7 +8363,7 @@ var TooltipPositioner = /* @__PURE__ */ React44.forwardRef(function TooltipPosit const floatingRootContext = store.useState("floatingRootContext"); const instantType = store.useState("instantType"); const transitionStatus = store.useState("transitionStatus"); - const hasViewport = store.useState("hasViewport"); + const adaptiveOrigin2 = store.useState("adaptiveOrigin"); const positioning = useAnchorPositioning({ anchor, positionMethod, @@ -8325,9 +8380,9 @@ var TooltipPositioner = /* @__PURE__ */ React44.forwardRef(function TooltipPosit disableAnchorTracking, keepMounted, collisionAvoidance, - adaptiveOrigin: hasViewport ? adaptiveOrigin : void 0 + adaptiveOrigin: adaptiveOrigin2 }); - const state = React44.useMemo(() => ({ + const state = React43.useMemo(() => ({ open, side: positioning.side, align: positioning.align, @@ -8350,12 +8405,8 @@ var TooltipPositioner = /* @__PURE__ */ React44.forwardRef(function TooltipPosit if (true) TooltipPositioner.displayName = "TooltipPositioner"; // node_modules/@base-ui/react/tooltip/popup/TooltipPopup.mjs -var React45 = __toESM(require_react(), 1); -var stateAttributesMapping = { - ...popupStateMapping, - ...transitionStatusMapping -}; -var TooltipPopup = /* @__PURE__ */ React45.forwardRef(function TooltipPopup2(componentProps, forwardedRef) { +var React44 = __toESM(require_react(), 1); +var TooltipPopup = /* @__PURE__ */ React44.forwardRef(function TooltipPopup2(componentProps, forwardedRef) { const { render, className, @@ -8398,16 +8449,16 @@ var TooltipPopup = /* @__PURE__ */ React45.forwardRef(function TooltipPopup2(com const element = useRenderElement("div", componentProps, { state, ref: [forwardedRef, store.context.popupRef, setPopupElement], - props: [popupProps, getDisabledMountTransitionStyles(transitionStatus), elementProps], - stateAttributesMapping + props: [FOCUSABLE_POPUP_PROPS, popupProps, getDisabledMountTransitionStyles(transitionStatus), elementProps], + stateAttributesMapping: popupTransitionStateMapping }); return element; }); if (true) TooltipPopup.displayName = "TooltipPopup"; // node_modules/@base-ui/react/tooltip/arrow/TooltipArrow.mjs -var React46 = __toESM(require_react(), 1); -var TooltipArrow = /* @__PURE__ */ React46.forwardRef(function TooltipArrow2(componentProps, forwardedRef) { +var React45 = __toESM(require_react(), 1); +var TooltipArrow = /* @__PURE__ */ React45.forwardRef(function TooltipArrow2(componentProps, forwardedRef) { const { render, className, @@ -8445,7 +8496,7 @@ var TooltipArrow = /* @__PURE__ */ React46.forwardRef(function TooltipArrow2(com if (true) TooltipArrow.displayName = "TooltipArrow"; // node_modules/@base-ui/react/tooltip/provider/TooltipProvider.mjs -var React47 = __toESM(require_react(), 1); +var React46 = __toESM(require_react(), 1); var import_jsx_runtime11 = __toESM(require_jsx_runtime(), 1); var TooltipProvider = function TooltipProvider2(props) { const { @@ -8453,16 +8504,12 @@ var TooltipProvider = function TooltipProvider2(props) { closeDelay, timeout = 400 } = props; - const contextValue = React47.useMemo(() => ({ - delay, - closeDelay - }), [delay, closeDelay]); - const delayValue = React47.useMemo(() => ({ + const delayValue = React46.useMemo(() => ({ open: delay, close: closeDelay }), [delay, closeDelay]); return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TooltipProviderContext.Provider, { - value: contextValue, + value: delay, children: /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(FloatingDelayGroup, { delay: delayValue, timeoutMs: timeout, @@ -8473,22 +8520,8 @@ var TooltipProvider = function TooltipProvider2(props) { if (true) TooltipProvider.displayName = "TooltipProvider"; // node_modules/@base-ui/react/tooltip/viewport/TooltipViewport.mjs -var React48 = __toESM(require_react(), 1); - -// node_modules/@base-ui/react/tooltip/viewport/TooltipViewportCssVars.mjs -var TooltipViewportCssVars = /* @__PURE__ */ (function(TooltipViewportCssVars2) { - TooltipViewportCssVars2["popupWidth"] = "--popup-width"; - TooltipViewportCssVars2["popupHeight"] = "--popup-height"; - return TooltipViewportCssVars2; -})({}); - -// node_modules/@base-ui/react/tooltip/viewport/TooltipViewport.mjs -var stateAttributesMapping2 = { - activationDirection: (value) => value ? { - "data-activation-direction": value - } : null -}; -var TooltipViewport = /* @__PURE__ */ React48.forwardRef(function TooltipViewport2(componentProps, forwardedRef) { +var React47 = __toESM(require_react(), 1); +var TooltipViewport = /* @__PURE__ */ React47.forwardRef(function TooltipViewport2(componentProps, forwardedRef) { const { render, className, @@ -8505,7 +8538,6 @@ var TooltipViewport = /* @__PURE__ */ React48.forwardRef(function TooltipViewpor } = usePopupViewport({ store, side: positioner.side, - cssVars: TooltipViewportCssVars, children }); const state = { @@ -8519,46 +8551,40 @@ var TooltipViewport = /* @__PURE__ */ React48.forwardRef(function TooltipViewpor props: [elementProps, { children: childrenToRender }], - stateAttributesMapping: stateAttributesMapping2 + stateAttributesMapping: popupViewportStateMapping }); }); if (true) TooltipViewport.displayName = "TooltipViewport"; // node_modules/@base-ui/react/tooltip/store/TooltipHandle.mjs -var TooltipHandle = class { - /** - * Internal store holding the tooltip state. - * @internal - */ +var TooltipHandle = class extends BasePopupHandle { constructor() { - this.store = new TooltipStore(); + super(createNullTooltipStore(), "Tooltip"); } /** - * Opens the tooltip and associates it with the trigger with the given ID. - * The trigger must be a Tooltip.Trigger component with this handle passed as a prop. + * Opens the tooltip and associates it with the trigger with the given id. * * This method should only be called in an event handler or an effect (not during rendering). * - * @param triggerId ID of the trigger to associate with the tooltip. + * @param triggerId ID of the trigger to associate with the tooltip. The trigger must be a matching + * `Tooltip.Trigger` with this handle passed as a prop. */ open(triggerId) { - const triggerElement = triggerId ? this.store.context.triggerElements.getById(triggerId) : void 0; - if (triggerId && !triggerElement) { - throw new Error(true ? `Base UI: TooltipHandle.open: No trigger found with id "${triggerId}".` : formatErrorMessage_default(81, triggerId)); - } - this.store.setOpen(true, createChangeEventDetails(reason_parts_exports.imperativeAction, void 0, triggerElement)); + this.openByTrigger(triggerId); } /** * Closes the tooltip. + * + * This method should only be called in an event handler or an effect (not during rendering). */ close() { - this.store.setOpen(false, createChangeEventDetails(reason_parts_exports.imperativeAction, void 0, void 0)); + this.closePopup(); } /** - * Indicates whether the tooltip is currently open. + * Whether the tooltip is currently open. Returns `false` while no root is attached to the handle. */ get isOpen() { - return this.store.select("open"); + return this.attachedStore?.select("open") ?? false; } }; function createTooltipHandle() { @@ -8716,41 +8742,24 @@ var import_primitives5 = __toESM(require_primitives(), 1); var import_jsx_runtime16 = __toESM(require_jsx_runtime(), 1); var previous_default = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_primitives5.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_primitives5.Path, { d: "M11.6 7l-1.1-1L5 12l5.5 6 1.1-1L7 12l4.6-5zm6 0l-1.1-1-5.5 6 5.5 6 1.1-1-4.6-5 4.6-5z" }) }); -// packages/ui/build-module/utils/render-slot-with-children.mjs -var import_element12 = __toESM(require_element(), 1); -function renderSlotWithChildren(slot, defaultSlot, children) { - return (0, import_element12.cloneElement)(slot ?? defaultSlot, { children }); -} - -// packages/ui/build-module/utils/theme-provider.mjs -var theme = __toESM(require_theme(), 1); +// packages/ui/build-module/tooltip/index.mjs +var tooltip_exports = {}; +__export(tooltip_exports, { + Popup: () => Popup, + Portal: () => Portal, + Positioner: () => Positioner, + Provider: () => Provider, + Root: () => Root, + Trigger: () => Trigger +}); -// packages/ui/build-module/lock-unlock.mjs -var import_private_apis = __toESM(require_private_apis(), 1); -var { lock, unlock } = (0, import_private_apis.__dangerousOptInToUnstableAPIsOnlyForCoreModules)( - "I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.", - "@wordpress/ui" -); +// packages/ui/build-module/tooltip/popup.mjs +var import_element15 = __toESM(require_element(), 1); -// packages/ui/build-module/utils/theme-provider.mjs -function getThemeProvider() { - const themePackage = theme; - if (themePackage.ThemeProvider) { - return themePackage.ThemeProvider; - } - if (!themePackage.privateApis) { - throw new Error( - "@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`." - ); - } - return unlock( - themePackage.privateApis - ).ThemeProvider; -} -var ThemeProvider = getThemeProvider(); +// packages/ui/build-module/tooltip/portal.mjs +var import_element12 = __toESM(require_element(), 1); -// packages/ui/build-module/stack/stack.mjs -var import_element13 = __toESM(require_element(), 1); +// packages/ui/build-module/utils/wp-compat-overlay-slot.mjs var STYLE_HASH_ATTRIBUTE2 = "data-wp-hash"; function getRuntime2() { const globalScope = globalThis; @@ -8832,152 +8841,25 @@ function registerStyle2(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle2("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); + registerStyle2("be37f31c1e", "._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}"); } -var style_default2 = { "stack": "_19ce0419607e1896__stack" }; -var gapTokens = { - xs: "var(--wpds-dimension-gap-xs, 4px)", - sm: "var(--wpds-dimension-gap-sm, 8px)", - md: "var(--wpds-dimension-gap-md, 12px)", - lg: "var(--wpds-dimension-gap-lg, 16px)", - xl: "var(--wpds-dimension-gap-xl, 24px)", - "2xl": "var(--wpds-dimension-gap-2xl, 32px)", - "3xl": "var(--wpds-dimension-gap-3xl, 40px)" -}; -var Stack = (0, import_element13.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { - const style = { - gap: gap && gapTokens[gap], - alignItems: align, - justifyContent: justify, - flexDirection: direction, - flexWrap: wrap - }; - const element = useRender({ - render, - ref, - props: mergeProps(props, { style, className: style_default2.stack }) - }); - return element; -}); - -// packages/ui/build-module/tooltip/index.mjs -var tooltip_exports = {}; -__export(tooltip_exports, { - Popup: () => Popup, - Portal: () => Portal, - Positioner: () => Positioner, - Provider: () => Provider, - Root: () => Root, - Trigger: () => Trigger -}); - -// packages/ui/build-module/tooltip/popup.mjs -var import_element16 = __toESM(require_element(), 1); - -// packages/ui/build-module/tooltip/portal.mjs -var import_element14 = __toESM(require_element(), 1); - -// packages/ui/build-module/utils/wp-compat-overlay-slot.mjs -var STYLE_HASH_ATTRIBUTE3 = "data-wp-hash"; -function getRuntime3() { - const globalScope = globalThis; - if (globalScope.__wpStyleRuntime) { - return globalScope.__wpStyleRuntime; - } - globalScope.__wpStyleRuntime = { - documents: /* @__PURE__ */ new Map(), - styles: /* @__PURE__ */ new Map(), - injectedStyles: /* @__PURE__ */ new WeakMap() - }; - if (typeof document !== "undefined") { - registerDocument3(document); - } - return globalScope.__wpStyleRuntime; -} -function documentContainsStyleHash3(targetDocument, hash) { - if (!targetDocument.head) { - return false; - } - for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE3}]` - )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE3) === hash) { - return true; - } - } - return false; -} -function injectStyle3(targetDocument, hash, css) { - if (!targetDocument.head) { - return; - } - const runtime = getRuntime3(); - let injectedStyles = runtime.injectedStyles.get(targetDocument); - if (!injectedStyles) { - injectedStyles = /* @__PURE__ */ new Set(); - runtime.injectedStyles.set(targetDocument, injectedStyles); - } - if (injectedStyles.has(hash)) { - return; - } - if (documentContainsStyleHash3(targetDocument, hash)) { - injectedStyles.add(hash); - return; - } - const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE3, hash); - style.appendChild(targetDocument.createTextNode(css)); - targetDocument.head.appendChild(style); - injectedStyles.add(hash); -} -function registerDocument3(targetDocument) { - const runtime = getRuntime3(); - runtime.documents.set( - targetDocument, - (runtime.documents.get(targetDocument) ?? 0) + 1 - ); - for (const [hash, css] of runtime.styles) { - injectStyle3(targetDocument, hash, css); - } - return () => { - const count = runtime.documents.get(targetDocument); - if (count === void 0) { - return; - } - if (count <= 1) { - runtime.documents.delete(targetDocument); - return; - } - runtime.documents.set(targetDocument, count - 1); - }; -} -function registerStyle3(hash, css) { - const runtime = getRuntime3(); - runtime.styles.set(hash, css); - for (const targetDocument of runtime.documents.keys()) { - injectStyle3(targetDocument, hash, css); - } -} -if (typeof process === "undefined" || true) { - registerStyle3("be37f31c1e", "._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}"); -} -var wp_compat_overlay_slot_default = { "slot": "_11fc52b637ff8a7e__slot" }; -var WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE = "data-wp-compat-overlay-slot"; -function resolveOwnerDocument() { - return typeof document === "undefined" ? null : document; -} -function isInWordPressEnvironment() { - let topWp; - try { - topWp = window.top?.wp; - } catch { - } - const wp = topWp ?? window.wp; - return typeof wp?.components === "object" && wp.components !== null; -} -var cachedSlot = null; -function ensureSlotIsAccessible(element) { - element.setAttribute("aria-hidden", "false"); +var wp_compat_overlay_slot_default = { "slot": "_11fc52b637ff8a7e__slot" }; +var WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE = "data-wp-compat-overlay-slot"; +function resolveOwnerDocument() { + return typeof document === "undefined" ? null : document; +} +function isInWordPressEnvironment() { + let topWp; + try { + topWp = window.top?.wp; + } catch { + } + const wp = topWp ?? window.wp; + return typeof wp?.components === "object" && wp.components !== null; +} +var cachedSlot = null; +function ensureSlotIsAccessible(element) { + element.setAttribute("aria-hidden", "false"); return element; } function createSlot(ownerDocument2) { @@ -9019,7 +8901,7 @@ function getWpCompatOverlaySlot() { // packages/ui/build-module/tooltip/portal.mjs var import_jsx_runtime17 = __toESM(require_jsx_runtime(), 1); -var Portal = (0, import_element14.forwardRef)( +var Portal = (0, import_element12.forwardRef)( function TooltipPortal3({ container, ...restProps }, ref) { return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)( index_parts_exports.Portal, @@ -9033,10 +8915,10 @@ var Portal = (0, import_element14.forwardRef)( ); // packages/ui/build-module/tooltip/positioner.mjs -var import_element15 = __toESM(require_element(), 1); +var import_element13 = __toESM(require_element(), 1); var import_jsx_runtime18 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE4 = "data-wp-hash"; -function getRuntime4() { +var STYLE_HASH_ATTRIBUTE3 = "data-wp-hash"; +function getRuntime3() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9047,28 +8929,28 @@ function getRuntime4() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument4(document); + registerDocument3(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash4(targetDocument, hash) { +function documentContainsStyleHash3(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE4}]` + `style[${STYLE_HASH_ATTRIBUTE3}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE4) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE3) === hash) { return true; } } return false; } -function injectStyle4(targetDocument, hash, css) { +function injectStyle3(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime4(); + const runtime = getRuntime3(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9077,24 +8959,24 @@ function injectStyle4(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash4(targetDocument, hash)) { + if (documentContainsStyleHash3(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE4, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE3, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument4(targetDocument) { - const runtime = getRuntime4(); +function registerDocument3(targetDocument) { + const runtime = getRuntime3(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle4(targetDocument, hash, css); + injectStyle3(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9108,22 +8990,22 @@ function registerDocument4(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle4(hash, css) { - const runtime = getRuntime4(); +function registerStyle3(hash, css) { + const runtime = getRuntime3(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle4(targetDocument, hash, css); + injectStyle3(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle4("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); + registerStyle3("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); } var resets_default = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; if (typeof process === "undefined" || true) { - registerStyle4("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); + registerStyle3("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); } -var style_default3 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; -var Positioner = (0, import_element15.forwardRef)( +var style_default2 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; +var Positioner = (0, import_element13.forwardRef)( function TooltipPositioner3({ align = "center", className, side = "top", sideOffset = 4, ...props }, ref) { return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)( index_parts_exports.Positioner, @@ -9135,7 +9017,7 @@ var Positioner = (0, import_element15.forwardRef)( ...props, className: clsx_default( resets_default["box-sizing"], - style_default3.positioner, + style_default2.positioner, className ) } @@ -9143,10 +9025,43 @@ var Positioner = (0, import_element15.forwardRef)( } ); +// packages/ui/build-module/utils/render-slot-with-children.mjs +var import_element14 = __toESM(require_element(), 1); +function renderSlotWithChildren(slot, defaultSlot, children) { + return (0, import_element14.cloneElement)(slot ?? defaultSlot, { children }); +} + +// packages/ui/build-module/utils/theme-provider.mjs +var theme = __toESM(require_theme(), 1); + +// packages/ui/build-module/lock-unlock.mjs +var import_private_apis = __toESM(require_private_apis(), 1); +var { lock, unlock } = (0, import_private_apis.__dangerousOptInToUnstableAPIsOnlyForCoreModules)( + "I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.", + "@wordpress/ui" +); + +// packages/ui/build-module/utils/theme-provider.mjs +function getThemeProvider() { + const themePackage = theme; + if (themePackage.ThemeProvider) { + return themePackage.ThemeProvider; + } + if (!themePackage.privateApis) { + throw new Error( + "@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`." + ); + } + return unlock( + themePackage.privateApis + ).ThemeProvider; +} +var ThemeProvider = getThemeProvider(); + // packages/ui/build-module/tooltip/popup.mjs var import_jsx_runtime19 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE5 = "data-wp-hash"; -function getRuntime5() { +var STYLE_HASH_ATTRIBUTE4 = "data-wp-hash"; +function getRuntime4() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9157,28 +9072,28 @@ function getRuntime5() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument5(document); + registerDocument4(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash5(targetDocument, hash) { +function documentContainsStyleHash4(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE5}]` + `style[${STYLE_HASH_ATTRIBUTE4}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE5) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE4) === hash) { return true; } } return false; } -function injectStyle5(targetDocument, hash, css) { +function injectStyle4(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime5(); + const runtime = getRuntime4(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9187,24 +9102,24 @@ function injectStyle5(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash5(targetDocument, hash)) { + if (documentContainsStyleHash4(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE5, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE4, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument5(targetDocument) { - const runtime = getRuntime5(); +function registerDocument4(targetDocument) { + const runtime = getRuntime4(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle5(targetDocument, hash, css); + injectStyle4(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9218,24 +9133,24 @@ function registerDocument5(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle5(hash, css) { - const runtime = getRuntime5(); +function registerStyle4(hash, css) { + const runtime = getRuntime4(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle5(targetDocument, hash, css); + injectStyle4(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle5("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); + registerStyle4("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); } -var style_default4 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; +var style_default3 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; var POPUP_COLOR = { background: "#1e1e1e" }; -var Popup = (0, import_element16.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { +var Popup = (0, import_element15.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { const popupContent = /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(ThemeProvider, { color: POPUP_COLOR, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)( index_parts_exports.Popup, { ref, - className: clsx_default(style_default4.popup, className), + className: clsx_default(style_default3.popup, className), ...props, children } @@ -9249,9 +9164,9 @@ var Popup = (0, import_element16.forwardRef)(function TooltipPopup3({ portal, po }); // packages/ui/build-module/tooltip/trigger.mjs -var import_element17 = __toESM(require_element(), 1); +var import_element16 = __toESM(require_element(), 1); var import_jsx_runtime20 = __toESM(require_jsx_runtime(), 1); -var Trigger = (0, import_element17.forwardRef)( +var Trigger = (0, import_element16.forwardRef)( function TooltipTrigger3(props, ref) { return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(index_parts_exports.Trigger, { ref, ...props }); } @@ -9276,10 +9191,10 @@ function Provider({ ...props }) { return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(index_parts_exports.Provider, { ...props }); } -// packages/ui/build-module/skeleton/skeleton.mjs -var import_element18 = __toESM(require_element(), 1); -var STYLE_HASH_ATTRIBUTE6 = "data-wp-hash"; -function getRuntime6() { +// packages/ui/build-module/visually-hidden/visually-hidden.mjs +var import_element17 = __toESM(require_element(), 1); +var STYLE_HASH_ATTRIBUTE5 = "data-wp-hash"; +function getRuntime5() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9290,28 +9205,28 @@ function getRuntime6() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument6(document); + registerDocument5(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash6(targetDocument, hash) { +function documentContainsStyleHash5(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE6}]` + `style[${STYLE_HASH_ATTRIBUTE5}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE6) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE5) === hash) { return true; } } return false; } -function injectStyle6(targetDocument, hash, css) { +function injectStyle5(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime6(); + const runtime = getRuntime5(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9320,24 +9235,24 @@ function injectStyle6(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash6(targetDocument, hash)) { + if (documentContainsStyleHash5(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE6, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE5, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument6(targetDocument) { - const runtime = getRuntime6(); +function registerDocument5(targetDocument) { + const runtime = getRuntime5(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle6(targetDocument, hash, css); + injectStyle5(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9351,32 +9266,390 @@ function registerDocument6(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle6(hash, css) { - const runtime = getRuntime6(); +function registerStyle5(hash, css) { + const runtime = getRuntime5(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle6(targetDocument, hash, css); + injectStyle5(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle6("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); + registerStyle5("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); } -var resets_default2 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; -if (typeof process === "undefined" || true) { - registerStyle6("ed2c39ec90", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.b20cc1690085c2f0__skeleton{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);display:block;@media (forced-colors:active){border:var(--wpds-border-width-xs,1px) solid CanvasText}}._9b143194fdb45f93__pulse{@media not (prefers-reduced-motion){animation:e2b9fe0690281bc8__skeleton-pulse 1.5s ease-in-out infinite}}@keyframes e2b9fe0690281bc8__skeleton-pulse{0%,to{opacity:1}50%{opacity:.4}}}}"); -} -var style_default5 = { "skeleton": "b20cc1690085c2f0__skeleton", "pulse": "_9b143194fdb45f93__pulse", "skeleton-pulse": "e2b9fe0690281bc8__skeleton-pulse" }; -var Skeleton = (0, import_element18.forwardRef)( - function Skeleton2({ render, ...props }, ref) { +var style_default4 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; +var VisuallyHidden = (0, import_element17.forwardRef)( + function VisuallyHidden2({ render, ...restProps }, ref) { + const element = useRender({ + render, + ref, + props: mergeProps( + { className: style_default4["visually-hidden"] }, + restProps, + { + // @ts-expect-error Arbitrary data-* attributes aren't indexable on the typed div props. Kept hardcoded so consumers can't change or remove it. + "data-visually-hidden": "" + } + ) + }); + return element; + } +); + +// packages/ui/build-module/stack/stack.mjs +var import_element18 = __toESM(require_element(), 1); +var STYLE_HASH_ATTRIBUTE6 = "data-wp-hash"; +function getRuntime6() { + const globalScope = globalThis; + if (globalScope.__wpStyleRuntime) { + return globalScope.__wpStyleRuntime; + } + globalScope.__wpStyleRuntime = { + documents: /* @__PURE__ */ new Map(), + styles: /* @__PURE__ */ new Map(), + injectedStyles: /* @__PURE__ */ new WeakMap() + }; + if (typeof document !== "undefined") { + registerDocument6(document); + } + return globalScope.__wpStyleRuntime; +} +function documentContainsStyleHash6(targetDocument, hash) { + if (!targetDocument.head) { + return false; + } + for (const style of targetDocument.head.querySelectorAll( + `style[${STYLE_HASH_ATTRIBUTE6}]` + )) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE6) === hash) { + return true; + } + } + return false; +} +function injectStyle6(targetDocument, hash, css) { + if (!targetDocument.head) { + return; + } + const runtime = getRuntime6(); + let injectedStyles = runtime.injectedStyles.get(targetDocument); + if (!injectedStyles) { + injectedStyles = /* @__PURE__ */ new Set(); + runtime.injectedStyles.set(targetDocument, injectedStyles); + } + if (injectedStyles.has(hash)) { + return; + } + if (documentContainsStyleHash6(targetDocument, hash)) { + injectedStyles.add(hash); + return; + } + const style = targetDocument.createElement("style"); + style.setAttribute(STYLE_HASH_ATTRIBUTE6, hash); + style.appendChild(targetDocument.createTextNode(css)); + targetDocument.head.appendChild(style); + injectedStyles.add(hash); +} +function registerDocument6(targetDocument) { + const runtime = getRuntime6(); + runtime.documents.set( + targetDocument, + (runtime.documents.get(targetDocument) ?? 0) + 1 + ); + for (const [hash, css] of runtime.styles) { + injectStyle6(targetDocument, hash, css); + } + return () => { + const count = runtime.documents.get(targetDocument); + if (count === void 0) { + return; + } + if (count <= 1) { + runtime.documents.delete(targetDocument); + return; + } + runtime.documents.set(targetDocument, count - 1); + }; +} +function registerStyle6(hash, css) { + const runtime = getRuntime6(); + runtime.styles.set(hash, css); + for (const targetDocument of runtime.documents.keys()) { + injectStyle6(targetDocument, hash, css); + } +} +if (typeof process === "undefined" || true) { + registerStyle6("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); +} +var style_default5 = { "stack": "_19ce0419607e1896__stack" }; +var gapTokens = { + xs: "var(--wpds-dimension-gap-xs, 4px)", + sm: "var(--wpds-dimension-gap-sm, 8px)", + md: "var(--wpds-dimension-gap-md, 12px)", + lg: "var(--wpds-dimension-gap-lg, 16px)", + xl: "var(--wpds-dimension-gap-xl, 24px)", + "2xl": "var(--wpds-dimension-gap-2xl, 32px)", + "3xl": "var(--wpds-dimension-gap-3xl, 40px)" +}; +var Stack = (0, import_element18.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { + const style = { + gap: gap && gapTokens[gap], + alignItems: align, + justifyContent: justify, + flexDirection: direction, + flexWrap: wrap + }; + const element = useRender({ + render, + ref, + props: mergeProps(props, { style, className: style_default5.stack }) + }); + return element; +}); + +// packages/ui/build-module/link/link.mjs +var import_element19 = __toESM(require_element(), 1); +var import_i18n2 = __toESM(require_i18n(), 1); +var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE7 = "data-wp-hash"; +function getRuntime7() { + const globalScope = globalThis; + if (globalScope.__wpStyleRuntime) { + return globalScope.__wpStyleRuntime; + } + globalScope.__wpStyleRuntime = { + documents: /* @__PURE__ */ new Map(), + styles: /* @__PURE__ */ new Map(), + injectedStyles: /* @__PURE__ */ new WeakMap() + }; + if (typeof document !== "undefined") { + registerDocument7(document); + } + return globalScope.__wpStyleRuntime; +} +function documentContainsStyleHash7(targetDocument, hash) { + if (!targetDocument.head) { + return false; + } + for (const style of targetDocument.head.querySelectorAll( + `style[${STYLE_HASH_ATTRIBUTE7}]` + )) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE7) === hash) { + return true; + } + } + return false; +} +function injectStyle7(targetDocument, hash, css) { + if (!targetDocument.head) { + return; + } + const runtime = getRuntime7(); + let injectedStyles = runtime.injectedStyles.get(targetDocument); + if (!injectedStyles) { + injectedStyles = /* @__PURE__ */ new Set(); + runtime.injectedStyles.set(targetDocument, injectedStyles); + } + if (injectedStyles.has(hash)) { + return; + } + if (documentContainsStyleHash7(targetDocument, hash)) { + injectedStyles.add(hash); + return; + } + const style = targetDocument.createElement("style"); + style.setAttribute(STYLE_HASH_ATTRIBUTE7, hash); + style.appendChild(targetDocument.createTextNode(css)); + targetDocument.head.appendChild(style); + injectedStyles.add(hash); +} +function registerDocument7(targetDocument) { + const runtime = getRuntime7(); + runtime.documents.set( + targetDocument, + (runtime.documents.get(targetDocument) ?? 0) + 1 + ); + for (const [hash, css] of runtime.styles) { + injectStyle7(targetDocument, hash, css); + } + return () => { + const count = runtime.documents.get(targetDocument); + if (count === void 0) { + return; + } + if (count <= 1) { + runtime.documents.delete(targetDocument); + return; + } + runtime.documents.set(targetDocument, count - 1); + }; +} +function registerStyle7(hash, css) { + const runtime = getRuntime7(); + runtime.styles.set(hash, css); + for (const targetDocument of runtime.documents.keys()) { + injectStyle7(targetDocument, hash, css); + } +} +if (typeof process === "undefined" || true) { + registerStyle7("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); +} +var resets_default2 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; +if (typeof process === "undefined" || true) { + registerStyle7("96553466c8", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); +} +var focus_module_default = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-within-visible": "_64de9947bf305b7a__outset-ring--focus-within-visible", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; +if (typeof process === "undefined" || true) { + registerStyle7("e8e6a9be37", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}'); +} +var style_default6 = { "link": "d4250949359b05ce__link", "is-brand": "c6055659b8e2cd2c__is-brand", "is-neutral": "_92e0dfcaeee15b88__is-neutral", "is-unstyled": "cf122a9bf1035d42__is-unstyled", "link-icon": "_0cb411afac4c86c7__link-icon" }; +if (typeof process === "undefined" || true) { + registerStyle7("af6d9984a6", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}"); +} +var global_css_defense_default2 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a" }; +var Link = (0, import_element19.forwardRef)(function Link2({ + children, + variant = "default", + tone = "brand", + openInNewTab = false, + render, + className, + ...props +}, ref) { + const element = useRender({ + render, + defaultTagName: "a", + ref, + props: mergeProps(props, { + className: clsx_default( + global_css_defense_default2.a, + resets_default2["box-sizing"], + focus_module_default["outset-ring--focus-except-active"], + variant !== "unstyled" && style_default6.link, + variant !== "unstyled" && style_default6[`is-${tone}`], + variant === "unstyled" && style_default6["is-unstyled"], + className + ), + target: openInNewTab ? "_blank" : void 0, + children: /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [ + children, + openInNewTab && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)( + "span", + { + className: style_default6["link-icon"], + role: "img", + "aria-label": ( + /* translators: accessibility text appended to link text */ + (0, import_i18n2.__)("(opens in a new tab)") + ) + } + ) + ] }) + }) + }); + return element; +}); + +// packages/ui/build-module/skeleton/skeleton.mjs +var import_element20 = __toESM(require_element(), 1); +var STYLE_HASH_ATTRIBUTE8 = "data-wp-hash"; +function getRuntime8() { + const globalScope = globalThis; + if (globalScope.__wpStyleRuntime) { + return globalScope.__wpStyleRuntime; + } + globalScope.__wpStyleRuntime = { + documents: /* @__PURE__ */ new Map(), + styles: /* @__PURE__ */ new Map(), + injectedStyles: /* @__PURE__ */ new WeakMap() + }; + if (typeof document !== "undefined") { + registerDocument8(document); + } + return globalScope.__wpStyleRuntime; +} +function documentContainsStyleHash8(targetDocument, hash) { + if (!targetDocument.head) { + return false; + } + for (const style of targetDocument.head.querySelectorAll( + `style[${STYLE_HASH_ATTRIBUTE8}]` + )) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE8) === hash) { + return true; + } + } + return false; +} +function injectStyle8(targetDocument, hash, css) { + if (!targetDocument.head) { + return; + } + const runtime = getRuntime8(); + let injectedStyles = runtime.injectedStyles.get(targetDocument); + if (!injectedStyles) { + injectedStyles = /* @__PURE__ */ new Set(); + runtime.injectedStyles.set(targetDocument, injectedStyles); + } + if (injectedStyles.has(hash)) { + return; + } + if (documentContainsStyleHash8(targetDocument, hash)) { + injectedStyles.add(hash); + return; + } + const style = targetDocument.createElement("style"); + style.setAttribute(STYLE_HASH_ATTRIBUTE8, hash); + style.appendChild(targetDocument.createTextNode(css)); + targetDocument.head.appendChild(style); + injectedStyles.add(hash); +} +function registerDocument8(targetDocument) { + const runtime = getRuntime8(); + runtime.documents.set( + targetDocument, + (runtime.documents.get(targetDocument) ?? 0) + 1 + ); + for (const [hash, css] of runtime.styles) { + injectStyle8(targetDocument, hash, css); + } + return () => { + const count = runtime.documents.get(targetDocument); + if (count === void 0) { + return; + } + if (count <= 1) { + runtime.documents.delete(targetDocument); + return; + } + runtime.documents.set(targetDocument, count - 1); + }; +} +function registerStyle8(hash, css) { + const runtime = getRuntime8(); + runtime.styles.set(hash, css); + for (const targetDocument of runtime.documents.keys()) { + injectStyle8(targetDocument, hash, css); + } +} +if (typeof process === "undefined" || true) { + registerStyle8("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); +} +var resets_default3 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; +if (typeof process === "undefined" || true) { + registerStyle8("ed2c39ec90", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.b20cc1690085c2f0__skeleton{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);display:block;@media (forced-colors:active){border:var(--wpds-border-width-xs,1px) solid CanvasText}}._9b143194fdb45f93__pulse{@media not (prefers-reduced-motion){animation:e2b9fe0690281bc8__skeleton-pulse 1.5s ease-in-out infinite}}@keyframes e2b9fe0690281bc8__skeleton-pulse{0%,to{opacity:1}50%{opacity:.4}}}}"); +} +var style_default7 = { "skeleton": "b20cc1690085c2f0__skeleton", "pulse": "_9b143194fdb45f93__pulse", "skeleton-pulse": "e2b9fe0690281bc8__skeleton-pulse" }; +var Skeleton = (0, import_element20.forwardRef)( + function Skeleton2({ render, ...props }, ref) { return useRender({ render, ref, props: mergeProps( { className: clsx_default( - style_default5.skeleton, - style_default5.pulse, - resets_default2["box-sizing"] + style_default7.skeleton, + style_default7.pulse, + resets_default3["box-sizing"] ), // Decorative by default; consumers mark the loading // region with aria-busy / role="status". @@ -9389,11 +9662,11 @@ var Skeleton = (0, import_element18.forwardRef)( ); // packages/admin-ui/build-module/navigable-region/index.mjs -var import_element19 = __toESM(require_element(), 1); -var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); -var NavigableRegion = (0, import_element19.forwardRef)( +var import_element21 = __toESM(require_element(), 1); +var import_jsx_runtime25 = __toESM(require_jsx_runtime(), 1); +var NavigableRegion = (0, import_element21.forwardRef)( ({ children, className, ariaLabel, as: Tag = "div", ...props }, ref) => { - return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( Tag, { ref, @@ -9410,14 +9683,159 @@ var NavigableRegion = (0, import_element19.forwardRef)( NavigableRegion.displayName = "NavigableRegion"; var navigable_region_default = NavigableRegion; +// packages/admin-ui/build-module/navigation/index.mjs +var import_i18n3 = __toESM(require_i18n(), 1); +var import_jsx_runtime26 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE9 = "data-wp-hash"; +function getRuntime9() { + const globalScope = globalThis; + if (globalScope.__wpStyleRuntime) { + return globalScope.__wpStyleRuntime; + } + globalScope.__wpStyleRuntime = { + documents: /* @__PURE__ */ new Map(), + styles: /* @__PURE__ */ new Map(), + injectedStyles: /* @__PURE__ */ new WeakMap() + }; + if (typeof document !== "undefined") { + registerDocument9(document); + } + return globalScope.__wpStyleRuntime; +} +function documentContainsStyleHash9(targetDocument, hash) { + if (!targetDocument.head) { + return false; + } + for (const style of targetDocument.head.querySelectorAll( + `style[${STYLE_HASH_ATTRIBUTE9}]` + )) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE9) === hash) { + return true; + } + } + return false; +} +function injectStyle9(targetDocument, hash, css) { + if (!targetDocument.head) { + return; + } + const runtime = getRuntime9(); + let injectedStyles = runtime.injectedStyles.get(targetDocument); + if (!injectedStyles) { + injectedStyles = /* @__PURE__ */ new Set(); + runtime.injectedStyles.set(targetDocument, injectedStyles); + } + if (injectedStyles.has(hash)) { + return; + } + if (documentContainsStyleHash9(targetDocument, hash)) { + injectedStyles.add(hash); + return; + } + const style = targetDocument.createElement("style"); + style.setAttribute(STYLE_HASH_ATTRIBUTE9, hash); + style.appendChild(targetDocument.createTextNode(css)); + targetDocument.head.appendChild(style); + injectedStyles.add(hash); +} +function registerDocument9(targetDocument) { + const runtime = getRuntime9(); + runtime.documents.set( + targetDocument, + (runtime.documents.get(targetDocument) ?? 0) + 1 + ); + for (const [hash, css] of runtime.styles) { + injectStyle9(targetDocument, hash, css); + } + return () => { + const count = runtime.documents.get(targetDocument); + if (count === void 0) { + return; + } + if (count <= 1) { + runtime.documents.delete(targetDocument); + return; + } + runtime.documents.set(targetDocument, count - 1); + }; +} +function registerStyle9(hash, css) { + const runtime = getRuntime9(); + runtime.styles.set(hash, css); + for (const targetDocument of runtime.documents.keys()) { + injectStyle9(targetDocument, hash, css); + } +} +if (typeof process === "undefined" || true) { + registerStyle9("72ef022400", ".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}"); +} +var style_default8 = { "list": "bfb5a2dd8cceebd3__list", "li": "a4759b4cb2c8bd92__li", "item": "_07da506d3f2d9afe__item" }; +var Navigation = ({ + items, + currentHref, + ariaLabel = (0, import_i18n3.__)("Sections"), + linkComponent, + className +}) => { + if (!items.length) { + return null; + } + const LinkComponent = linkComponent ?? "a"; + if (true) { + const invalidItem = items.find( + (item) => typeof item.href !== "string" + ); + if (invalidItem) { + throw new Error( + `Navigation: item "${invalidItem.label}" is missing an \`href\` prop.` + ); + } + const duplicate = items.find( + (item, index2) => items.findIndex((other) => other.href === item.href) !== index2 + ); + if (duplicate) { + throw new Error( + `Navigation: duplicate \`href\` "${duplicate.href}". Each item must have a unique \`href\` so a single item receives \`aria-current="page"\`.` + ); + } + } + return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("nav", { "aria-label": ariaLabel, className, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)( + Stack, + { + render: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("ul", { role: "list" }), + direction: "row", + align: "center", + gap: "md", + className: style_default8.list, + children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("li", { className: style_default8.li, children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)( + Text, + { + variant: "body-md", + className: style_default8.item, + render: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)( + Link, + { + variant: "unstyled", + "aria-current": item.href === currentHref ? "page" : void 0, + render: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(LinkComponent, { href: item.href }) + } + ), + children: item.label + } + ) }, item.href)) + } + ) }); +}; +var navigation_default = Navigation; + // packages/admin-ui/build-module/page/sidebar-toggle-slot.mjs var import_components = __toESM(require_components(), 1); var { Fill: SidebarToggleFill, Slot: SidebarToggleSlot } = (0, import_components.createSlotFill)("SidebarToggle"); // packages/admin-ui/build-module/page/header.mjs -var import_jsx_runtime25 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE7 = "data-wp-hash"; -function getRuntime7() { +var import_jsx_runtime27 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE10 = "data-wp-hash"; +function getRuntime10() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9428,28 +9846,28 @@ function getRuntime7() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument7(document); + registerDocument10(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash7(targetDocument, hash) { +function documentContainsStyleHash10(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE7}]` + `style[${STYLE_HASH_ATTRIBUTE10}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE7) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE10) === hash) { return true; } } return false; } -function injectStyle7(targetDocument, hash, css) { +function injectStyle10(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime7(); + const runtime = getRuntime10(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9458,24 +9876,24 @@ function injectStyle7(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash7(targetDocument, hash)) { + if (documentContainsStyleHash10(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE7, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE10, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument7(targetDocument) { - const runtime = getRuntime7(); +function registerDocument10(targetDocument) { + const runtime = getRuntime10(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle7(targetDocument, hash, css); + injectStyle10(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9489,17 +9907,17 @@ function registerDocument7(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle7(hash, css) { - const runtime = getRuntime7(); +function registerStyle10(hash, css) { + const runtime = getRuntime10(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle7(targetDocument, hash, css); + injectStyle10(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle7("ddd9aab364", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); + registerStyle10("1f3750277d", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); } -var style_default6 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; +var style_default9 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-lockup": "_8bcd33103b451f30__header-lockup", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "has-navigation": "_4b0f17e503d11619__has-navigation", "header-navigation": "_673c99dcbfb58211__header-navigation", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; function Header({ headingLevel = 1, breadcrumbs, @@ -9508,75 +9926,106 @@ function Header({ title, subTitle, actions, + navigation, + components, showSidebarToggle = true }) { const HeadingTag = `h${headingLevel}`; - return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(Stack, { direction: "column", className: style_default6.header, children: [ - /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)( - Stack, - { - className: style_default6["header-content"], - direction: "row", - gap: "sm", - justify: "space-between", - children: [ - /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(Stack, { direction: "row", gap: "sm", align: "center", justify: "start", children: [ - showSidebarToggle && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( - SidebarToggleSlot, - { - bubblesVirtually: true, - className: style_default6["sidebar-toggle-slot"] - } - ), - visual && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( - "div", - { - className: style_default6["header-visual"], - "aria-hidden": "true", - children: visual - } - ), - title && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( - Text, - { - className: style_default6["header-title"], - render: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(HeadingTag, {}), - variant: "heading-lg", - children: title - } - ), - breadcrumbs, - badges - ] }), - actions && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( - Stack, - { - align: "center", - className: style_default6["header-actions"], - direction: "row", - gap: "sm", - children: actions - } - ) - ] - } - ), - subTitle && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( - Text, - { - render: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", {}), - variant: "body-md", - className: style_default6["header-subtitle"], - children: subTitle - } - ) - ] }); + const hasNavigation = !!navigation?.items?.length; + return /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)( + Stack, + { + direction: "column", + className: clsx_default( + style_default9.header, + hasNavigation && style_default9["has-navigation"] + ), + children: [ + /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)( + Stack, + { + className: style_default9["header-content"], + direction: "row", + gap: "sm", + justify: "space-between", + children: [ + /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)( + Stack, + { + direction: "row", + gap: "sm", + align: "center", + justify: "start", + className: style_default9["header-lockup"], + children: [ + showSidebarToggle && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + SidebarToggleSlot, + { + bubblesVirtually: true, + className: style_default9["sidebar-toggle-slot"] + } + ), + visual && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + "div", + { + className: style_default9["header-visual"], + "aria-hidden": "true", + children: visual + } + ), + title && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + Text, + { + className: style_default9["header-title"], + render: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(HeadingTag, {}), + variant: "heading-lg", + children: title + } + ), + breadcrumbs, + badges + ] + } + ), + actions && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + Stack, + { + align: "center", + className: style_default9["header-actions"], + direction: "row", + gap: "sm", + children: actions + } + ) + ] + } + ), + subTitle && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + Text, + { + render: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("p", {}), + variant: "body-md", + className: style_default9["header-subtitle"], + children: subTitle + } + ), + hasNavigation && /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + navigation_default, + { + ...navigation, + linkComponent: components?.link, + className: style_default9["header-navigation"] + } + ) + ] + } + ); } // packages/admin-ui/build-module/page/index.mjs -var import_jsx_runtime26 = __toESM(require_jsx_runtime(), 1); -var STYLE_HASH_ATTRIBUTE8 = "data-wp-hash"; -function getRuntime8() { +var import_jsx_runtime28 = __toESM(require_jsx_runtime(), 1); +var STYLE_HASH_ATTRIBUTE11 = "data-wp-hash"; +function getRuntime11() { const globalScope = globalThis; if (globalScope.__wpStyleRuntime) { return globalScope.__wpStyleRuntime; @@ -9587,28 +10036,28 @@ function getRuntime8() { injectedStyles: /* @__PURE__ */ new WeakMap() }; if (typeof document !== "undefined") { - registerDocument8(document); + registerDocument11(document); } return globalScope.__wpStyleRuntime; } -function documentContainsStyleHash8(targetDocument, hash) { +function documentContainsStyleHash11(targetDocument, hash) { if (!targetDocument.head) { return false; } for (const style of targetDocument.head.querySelectorAll( - `style[${STYLE_HASH_ATTRIBUTE8}]` + `style[${STYLE_HASH_ATTRIBUTE11}]` )) { - if (style.getAttribute(STYLE_HASH_ATTRIBUTE8) === hash) { + if (style.getAttribute(STYLE_HASH_ATTRIBUTE11) === hash) { return true; } } return false; } -function injectStyle8(targetDocument, hash, css) { +function injectStyle11(targetDocument, hash, css) { if (!targetDocument.head) { return; } - const runtime = getRuntime8(); + const runtime = getRuntime11(); let injectedStyles = runtime.injectedStyles.get(targetDocument); if (!injectedStyles) { injectedStyles = /* @__PURE__ */ new Set(); @@ -9617,24 +10066,24 @@ function injectStyle8(targetDocument, hash, css) { if (injectedStyles.has(hash)) { return; } - if (documentContainsStyleHash8(targetDocument, hash)) { + if (documentContainsStyleHash11(targetDocument, hash)) { injectedStyles.add(hash); return; } const style = targetDocument.createElement("style"); - style.setAttribute(STYLE_HASH_ATTRIBUTE8, hash); + style.setAttribute(STYLE_HASH_ATTRIBUTE11, hash); style.appendChild(targetDocument.createTextNode(css)); targetDocument.head.appendChild(style); injectedStyles.add(hash); } -function registerDocument8(targetDocument) { - const runtime = getRuntime8(); +function registerDocument11(targetDocument) { + const runtime = getRuntime11(); runtime.documents.set( targetDocument, (runtime.documents.get(targetDocument) ?? 0) + 1 ); for (const [hash, css] of runtime.styles) { - injectStyle8(targetDocument, hash, css); + injectStyle11(targetDocument, hash, css); } return () => { const count = runtime.documents.get(targetDocument); @@ -9648,17 +10097,17 @@ function registerDocument8(targetDocument) { runtime.documents.set(targetDocument, count - 1); }; } -function registerStyle8(hash, css) { - const runtime = getRuntime8(); +function registerStyle11(hash, css) { + const runtime = getRuntime11(); runtime.styles.set(hash, css); for (const targetDocument of runtime.documents.keys()) { - injectStyle8(targetDocument, hash, css); + injectStyle11(targetDocument, hash, css); } } if (typeof process === "undefined" || true) { - registerStyle8("ddd9aab364", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); + registerStyle11("1f3750277d", "._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}"); } -var style_default7 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; +var style_default10 = { "page": "_956b6df0898efed0__page", "header": "_0625b55e82a0d93d__header", "header-content": "a43c44d5ae28b2e8__header-content", "header-actions": "b7cb5b9daf3a3b25__header-actions", "header-lockup": "_8bcd33103b451f30__header-lockup", "header-title": "_8113be94e7caf73c__header-title", "header-visual": "_9a776c7f70996f61__header-visual", "sidebar-toggle-slot": "d5e0920cd15d35bc__sidebar-toggle-slot", "header-subtitle": "_60fea2f6bf5319cd__header-subtitle", "has-navigation": "_4b0f17e503d11619__has-navigation", "header-navigation": "_673c99dcbfb58211__header-navigation", "content": "be5e57d029ec4036__content", "has-padding": "_128806d0b26e3a50__has-padding" }; function Page({ headingLevel, breadcrumbs, @@ -9669,14 +10118,16 @@ function Page({ children, className, actions, + navigation, + components, ariaLabel, hasPadding = false, showSidebarToggle = true }) { - const classes = clsx_default(style_default7.page, className); + const classes = clsx_default(style_default10.page, className); const effectiveAriaLabel = ariaLabel ?? (typeof title === "string" ? title : ""); - return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(navigable_region_default, { className: classes, ariaLabel: effectiveAriaLabel, children: [ - (title || breadcrumbs || badges || actions || visual) && /* @__PURE__ */ (0, import_jsx_runtime26.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(navigable_region_default, { className: classes, ariaLabel: effectiveAriaLabel, children: [ + (title || breadcrumbs || badges || actions || visual || !!navigation?.items?.length) && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( Header, { headingLevel, @@ -9686,15 +10137,17 @@ function Page({ title, subTitle, actions, + navigation, + components, showSidebarToggle } ), - hasPadding ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)( + hasPadding ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( "div", { className: clsx_default( - style_default7.content, - style_default7["has-padding"] + style_default10.content, + style_default10["has-padding"] ), children } @@ -9705,20 +10158,20 @@ Page.SidebarToggleFill = SidebarToggleFill; var page_default = Page; // routes/font-list/stage.tsx -var import_i18n48 = __toESM(require_i18n()); +var import_i18n51 = __toESM(require_i18n()); var import_components58 = __toESM(require_components()); var import_editor = __toESM(require_editor()); var import_core_data12 = __toESM(require_core_data()); var import_data13 = __toESM(require_data()); -var import_element51 = __toESM(require_element()); +var import_element54 = __toESM(require_element()); // packages/global-styles-ui/build-module/global-styles-ui.mjs var import_components57 = __toESM(require_components(), 1); var import_blocks5 = __toESM(require_blocks(), 1); var import_data12 = __toESM(require_data(), 1); var import_block_editor14 = __toESM(require_block_editor(), 1); -var import_element50 = __toESM(require_element(), 1); -var import_compose6 = __toESM(require_compose(), 1); +var import_element53 = __toESM(require_element(), 1); +var import_compose7 = __toESM(require_compose(), 1); // packages/global-styles-engine/build-module/utils/object.mjs function setImmutably(object, path, value) { @@ -11110,11 +11563,11 @@ lock2(privateApis, { }); // packages/global-styles-ui/build-module/provider.mjs -var import_element21 = __toESM(require_element(), 1); +var import_element23 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/context.mjs -var import_element20 = __toESM(require_element(), 1); -var GlobalStylesContext = (0, import_element20.createContext)({ +var import_element22 = __toESM(require_element(), 1); +var GlobalStylesContext = (0, import_element22.createContext)({ user: { styles: {}, settings: {} }, base: { styles: {}, settings: {} }, merged: { styles: {}, settings: {} }, @@ -11124,7 +11577,7 @@ var GlobalStylesContext = (0, import_element20.createContext)({ }); // packages/global-styles-ui/build-module/provider.mjs -var import_jsx_runtime27 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime29 = __toESM(require_jsx_runtime(), 1); function GlobalStylesProvider({ children, value, @@ -11132,10 +11585,10 @@ function GlobalStylesProvider({ onChange, fontLibraryEnabled }) { - const merged = (0, import_element21.useMemo)(() => { + const merged = (0, import_element23.useMemo)(() => { return mergeGlobalStyles(baseValue, value); }, [baseValue, value]); - const contextValue = (0, import_element21.useMemo)( + const contextValue = (0, import_element23.useMemo)( () => ({ user: value, base: baseValue, @@ -11145,22 +11598,22 @@ function GlobalStylesProvider({ }), [value, baseValue, merged, onChange, fontLibraryEnabled] ); - return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(GlobalStylesContext.Provider, { value: contextValue, children }); + return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(GlobalStylesContext.Provider, { value: contextValue, children }); } // packages/global-styles-ui/build-module/screen-root.mjs var import_components8 = __toESM(require_components(), 1); -var import_i18n6 = __toESM(require_i18n(), 1); +var import_i18n8 = __toESM(require_i18n(), 1); var import_data2 = __toESM(require_data(), 1); var import_core_data2 = __toESM(require_core_data(), 1); // packages/global-styles-ui/build-module/icon-with-current-color.mjs -var import_jsx_runtime28 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime30 = __toESM(require_jsx_runtime(), 1); function IconWithCurrentColor({ className, ...props }) { - return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime30.jsx)( icon_default, { className: clsx_default( @@ -11174,27 +11627,27 @@ function IconWithCurrentColor({ // packages/global-styles-ui/build-module/navigation-button.mjs var import_components2 = __toESM(require_components(), 1); -var import_jsx_runtime29 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime31 = __toESM(require_jsx_runtime(), 1); function GenericNavigationButton({ icon, children, ...props }) { - return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_components2.__experimentalItem, { ...props, children: [ - icon && /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_components2.__experimentalHStack, { justify: "flex-start", children: [ - /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(IconWithCurrentColor, { icon, size: 24 }), - /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_components2.FlexItem, { children }) + return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(import_components2.__experimentalItem, { ...props, children: [ + icon && /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)(import_components2.__experimentalHStack, { justify: "flex-start", children: [ + /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(IconWithCurrentColor, { icon, size: 24 }), + /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_components2.FlexItem, { children }) ] }), !icon && children ] }); } function NavigationButtonAsItem(props) { - return /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(import_components2.Navigator.Button, { as: GenericNavigationButton, ...props }); + return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(import_components2.Navigator.Button, { as: GenericNavigationButton, ...props }); } // packages/global-styles-ui/build-module/root-menu.mjs var import_components3 = __toESM(require_components(), 1); -var import_i18n4 = __toESM(require_i18n(), 1); +var import_i18n6 = __toESM(require_i18n(), 1); var import_block_editor = __toESM(require_block_editor(), 1); // node_modules/colord/plugins/a11y.mjs @@ -11220,13 +11673,13 @@ function a11y_default(o3) { } // packages/global-styles-ui/build-module/hooks.mjs -var import_element22 = __toESM(require_element(), 1); +var import_element24 = __toESM(require_element(), 1); var import_data = __toESM(require_data(), 1); var import_core_data = __toESM(require_core_data(), 1); -var import_i18n3 = __toESM(require_i18n(), 1); +var import_i18n5 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/utils.mjs -var import_i18n2 = __toESM(require_i18n(), 1); +var import_i18n4 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/lock-unlock.mjs var import_private_apis4 = __toESM(require_private_apis(), 1); @@ -11239,35 +11692,35 @@ var { lock: lock3, unlock: unlock3 } = (0, import_private_apis4.__dangerousOptIn var { getViewportBreakpoints: getViewportBreakpoints2 } = unlock3(privateApis); var VALID_ELEMENT_STATES = { link: [ - { value: ":link", label: (0, import_i18n2.__)("Link") }, - { value: ":any-link", label: (0, import_i18n2.__)("Any Link") }, - { value: ":visited", label: (0, import_i18n2.__)("Visited") }, - { value: ":hover", label: (0, import_i18n2.__)("Hover") }, - { value: ":focus", label: (0, import_i18n2.__)("Focus") }, - { value: ":focus-visible", label: (0, import_i18n2.__)("Focus-visible") }, - { value: ":active", label: (0, import_i18n2.__)("Active") } + { value: ":link", label: (0, import_i18n4.__)("Link") }, + { value: ":any-link", label: (0, import_i18n4.__)("Any Link") }, + { value: ":visited", label: (0, import_i18n4.__)("Visited") }, + { value: ":hover", label: (0, import_i18n4.__)("Hover") }, + { value: ":focus", label: (0, import_i18n4.__)("Focus") }, + { value: ":focus-visible", label: (0, import_i18n4.__)("Focus-visible") }, + { value: ":active", label: (0, import_i18n4.__)("Active") } ], button: [ - { value: ":link", label: (0, import_i18n2.__)("Link") }, - { value: ":any-link", label: (0, import_i18n2.__)("Any Link") }, - { value: ":visited", label: (0, import_i18n2.__)("Visited") }, - { value: ":hover", label: (0, import_i18n2.__)("Hover") }, - { value: ":focus", label: (0, import_i18n2.__)("Focus") }, - { value: ":focus-visible", label: (0, import_i18n2.__)("Focus-visible") }, - { value: ":active", label: (0, import_i18n2.__)("Active") } + { value: ":link", label: (0, import_i18n4.__)("Link") }, + { value: ":any-link", label: (0, import_i18n4.__)("Any Link") }, + { value: ":visited", label: (0, import_i18n4.__)("Visited") }, + { value: ":hover", label: (0, import_i18n4.__)("Hover") }, + { value: ":focus", label: (0, import_i18n4.__)("Focus") }, + { value: ":focus-visible", label: (0, import_i18n4.__)("Focus-visible") }, + { value: ":active", label: (0, import_i18n4.__)("Active") } ] }; var VALID_BLOCK_STATES = { "core/button": [ - { value: ":hover", label: (0, import_i18n2.__)("Hover") }, - { value: ":focus", label: (0, import_i18n2.__)("Focus") }, - { value: ":focus-visible", label: (0, import_i18n2.__)("Focus-visible") }, - { value: ":active", label: (0, import_i18n2.__)("Active") } + { value: ":hover", label: (0, import_i18n4.__)("Hover") }, + { value: ":focus", label: (0, import_i18n4.__)("Focus") }, + { value: ":focus-visible", label: (0, import_i18n4.__)("Focus-visible") }, + { value: ":active", label: (0, import_i18n4.__)("Active") } ] }; var RESPONSIVE_STATES = [ - { value: "@tablet", label: (0, import_i18n2.__)("Tablet") }, - { value: "@mobile", label: (0, import_i18n2.__)("Mobile") } + { value: "@tablet", label: (0, import_i18n4.__)("Tablet") }, + { value: "@mobile", label: (0, import_i18n4.__)("Mobile") } ]; function removePropertiesFromObject(object, properties) { if (!properties?.length) { @@ -11354,7 +11807,7 @@ function getFontFamilies(themeJson) { // packages/global-styles-ui/build-module/hooks.mjs k([a11y_default]); function useStyle(path, blockName, readFrom = "merged", shouldDecodeEncode = true, state) { - const { user, base, merged, onChange } = (0, import_element22.useContext)(GlobalStylesContext); + const { user, base, merged, onChange } = (0, import_element24.useContext)(GlobalStylesContext); const statePathParts = state?.split(".").filter(Boolean) ?? []; const pseudoSelectorState = statePathParts.find( (value) => value.startsWith(":") @@ -11367,7 +11820,7 @@ function useStyle(path, blockName, readFrom = "merged", shouldDecodeEncode = tru } else if (readFrom === "user") { sourceValue = user; } - const styleValue = (0, import_element22.useMemo)(() => { + const styleValue = (0, import_element24.useMemo)(() => { const rawValue = getStyle( sourceValue, stylePath, @@ -11385,7 +11838,7 @@ function useStyle(path, blockName, readFrom = "merged", shouldDecodeEncode = tru shouldDecodeEncode, pseudoSelectorState ]); - const setStyleValue = (0, import_element22.useCallback)( + const setStyleValue = (0, import_element24.useCallback)( (newValue) => { let valueToSet = newValue; if (pseudoSelectorState) { @@ -11413,18 +11866,18 @@ function useStyle(path, blockName, readFrom = "merged", shouldDecodeEncode = tru return [styleValue, setStyleValue]; } function useSetting(path, blockName, readFrom = "merged") { - const { user, base, merged, onChange } = (0, import_element22.useContext)(GlobalStylesContext); + const { user, base, merged, onChange } = (0, import_element24.useContext)(GlobalStylesContext); let sourceValue = merged; if (readFrom === "base") { sourceValue = base; } else if (readFrom === "user") { sourceValue = user; } - const settingValue = (0, import_element22.useMemo)( + const settingValue = (0, import_element24.useMemo)( () => getSetting(sourceValue, path, blockName), [sourceValue, path, blockName] ); - const setSettingValue = (0, import_element22.useCallback)( + const setSettingValue = (0, import_element24.useCallback)( (newValue) => { const newGlobalStyles = setSetting( user, @@ -11444,7 +11897,7 @@ function hasThemeVariation({ settings, styles }) { - return title === (0, import_i18n3.__)("Default") || Object.keys(settings || {}).length > 0 || Object.keys(styles || {}).length > 0; + return title === (0, import_i18n5.__)("Default") || Object.keys(settings || {}).length > 0 || Object.keys(styles || {}).length > 0; } function useCurrentMergeThemeStyleVariationsWithUserConfig(properties = []) { const { variationsFromTheme } = (0, import_data.useSelect)((select) => { @@ -11455,14 +11908,14 @@ function useCurrentMergeThemeStyleVariationsWithUserConfig(properties = []) { variationsFromTheme: _variationsFromTheme || EMPTY_ARRAY2 }; }, []); - const { user: userVariation } = (0, import_element22.useContext)(GlobalStylesContext); - return (0, import_element22.useMemo)(() => { + const { user: userVariation } = (0, import_element24.useContext)(GlobalStylesContext); + return (0, import_element24.useMemo)(() => { const clonedUserVariation = structuredClone(userVariation); const userVariationWithoutProperties = removePropertiesFromObject( clonedUserVariation, properties ); - userVariationWithoutProperties.title = (0, import_i18n3.__)("Default"); + userVariationWithoutProperties.title = (0, import_i18n5.__)("Default"); const variationsWithPropertiesAndBase = variationsFromTheme.filter((variation) => { return isVariationWithProperties(variation, properties); }).map((variation) => { @@ -11480,7 +11933,7 @@ function useCurrentMergeThemeStyleVariationsWithUserConfig(properties = []) { } // packages/global-styles-ui/build-module/root-menu.mjs -var import_jsx_runtime30 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime32 = __toESM(require_jsx_runtime(), 1); var { useHasDimensionsPanel, useHasTypographyPanel, @@ -11526,9 +11979,9 @@ function useStylesPreviewColors() { } // packages/global-styles-ui/build-module/typography-example.mjs -var import_element23 = __toESM(require_element(), 1); +var import_element25 = __toESM(require_element(), 1); var import_components4 = __toESM(require_components(), 1); -var import_i18n5 = __toESM(require_i18n(), 1); +var import_i18n7 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/font-library/utils/preview-styles.mjs function findNearest(input, numbers) { @@ -11538,21 +11991,23 @@ function findNearest(input, numbers) { numbers.sort((a2, b2) => Math.abs(input - a2) - Math.abs(input - b2)); return numbers[0]; } -function extractFontWeights(fontFaces) { - const result = []; - fontFaces.forEach((face) => { - const weights = String(face.fontWeight).split(" "); - if (weights.length === 2) { - const start = parseInt(weights[0]); - const end = parseInt(weights[1]); - for (let i2 = start; i2 <= end; i2 += 100) { - result.push(i2); - } - } else if (weights.length === 1) { - result.push(parseInt(weights[0])); - } - }); - return result; +var FONT_WEIGHT_KEYWORDS = { + normal: 400, + bold: 700 +}; +function isValidWeight(weight) { + return weight !== void 0 && Number.isFinite(weight) && weight >= 1 && weight <= 1e3; +} +function resolveFontWeight(fontWeight) { + const weights = String(fontWeight ?? "").trim().toLowerCase().split(/\s+/).filter(Boolean).map((value) => FONT_WEIGHT_KEYWORDS[value] ?? Number(value)); + const [start, end] = weights; + if (!isValidWeight(start)) { + return "400"; + } + if (weights.length !== 2 || !isValidWeight(end)) { + return String(start); + } + return String(Math.min(Math.max(400, start), end)); } function formatFontFamily(input) { const regex = /^(?!generic\([ a-zA-Z\-]+\)$)(?!^[a-zA-Z\-]+$).+/; @@ -11599,12 +12054,15 @@ function getFamilyPreviewStyle(family) { ); if (normalFaces.length > 0) { style.fontStyle = "normal"; - const normalWeights = extractFontWeights(normalFaces); - const nearestWeight = findNearest(400, normalWeights); - style.fontWeight = String(nearestWeight) || "400"; + const normalWeights = normalFaces.map( + (face) => Number(resolveFontWeight(face.fontWeight)) + ); + style.fontWeight = String( + findNearest(400, normalWeights) ?? 400 + ); } else { style.fontStyle = family.fontFace.length && family.fontFace[0].fontStyle || "normal"; - style.fontWeight = family.fontFace.length && String(family.fontFace[0].fontWeight) || "400"; + style.fontWeight = family.fontFace.length && resolveFontWeight(family.fontFace[0].fontWeight) || "400"; } } return style; @@ -11613,17 +12071,17 @@ function getFacePreviewStyle(face) { return { fontFamily: formatFontFamily(face.fontFamily), fontStyle: face.fontStyle || "normal", - fontWeight: face.fontWeight || "400" + fontWeight: resolveFontWeight(face.fontWeight) }; } // packages/global-styles-ui/build-module/typography-example.mjs -var import_jsx_runtime31 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime33 = __toESM(require_jsx_runtime(), 1); function PreviewTypography({ fontSize, variation }) { - const { base } = (0, import_element23.useContext)(GlobalStylesContext); + const { base } = (0, import_element25.useContext)(GlobalStylesContext); let config = base; if (variation) { config = { ...base, ...variation }; @@ -11640,7 +12098,7 @@ function PreviewTypography({ bodyPreviewStyle.fontSize = fontSize; headingPreviewStyle.fontSize = fontSize; } - return /* @__PURE__ */ (0, import_jsx_runtime31.jsxs)( + return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)( import_components4.__unstableMotion.div, { animate: { @@ -11660,8 +12118,8 @@ function PreviewTypography({ lineHeight: 1 }, children: [ - /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { style: headingPreviewStyle, children: (0, import_i18n5._x)("A", "Uppercase letter A") }), - /* @__PURE__ */ (0, import_jsx_runtime31.jsx)("span", { style: bodyPreviewStyle, children: (0, import_i18n5._x)("a", "Lowercase letter A") }) + /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { style: headingPreviewStyle, children: (0, import_i18n7._x)("A", "Uppercase letter A") }), + /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("span", { style: bodyPreviewStyle, children: (0, import_i18n7._x)("a", "Lowercase letter A") }) ] } ); @@ -11669,14 +12127,14 @@ function PreviewTypography({ // packages/global-styles-ui/build-module/highlighted-colors.mjs var import_components5 = __toESM(require_components(), 1); -var import_jsx_runtime32 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime34 = __toESM(require_jsx_runtime(), 1); function HighlightedColors({ normalizedColorSwatchSize, ratio }) { const { highlightedColors } = useStylesPreviewColors(); const scaledSwatchSize = normalizedColorSwatchSize * ratio; - return highlightedColors.map(({ slug, color }, index2) => /* @__PURE__ */ (0, import_jsx_runtime32.jsx)( + return highlightedColors.map(({ slug, color }, index2) => /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( import_components5.__unstableMotion.div, { style: { @@ -11704,8 +12162,8 @@ function HighlightedColors({ // packages/global-styles-ui/build-module/preview-wrapper.mjs var import_components6 = __toESM(require_components(), 1); var import_compose = __toESM(require_compose(), 1); -var import_element24 = __toESM(require_element(), 1); -var import_jsx_runtime33 = __toESM(require_jsx_runtime(), 1); +var import_element26 = __toESM(require_element(), 1); +var import_jsx_runtime35 = __toESM(require_jsx_runtime(), 1); var normalizedWidth = 248; var normalizedHeight = 152; var THROTTLE_OPTIONS = { @@ -11721,21 +12179,21 @@ function PreviewWrapper({ const [backgroundColor = "white"] = useStyle("color.background"); const [gradientValue] = useStyle("color.gradient"); const disableMotion = (0, import_compose.useReducedMotion)(); - const [isHovered, setIsHovered] = (0, import_element24.useState)(false); + const [isHovered, setIsHovered] = (0, import_element26.useState)(false); const [containerResizeListener, { width }] = (0, import_compose.useResizeObserver)(); - const [throttledWidth, setThrottledWidthState] = (0, import_element24.useState)(width); - const [ratioState, setRatioState] = (0, import_element24.useState)(); + const [throttledWidth, setThrottledWidthState] = (0, import_element26.useState)(width); + const [ratioState, setRatioState] = (0, import_element26.useState)(); const setThrottledWidth = (0, import_compose.useThrottle)( setThrottledWidthState, 250, THROTTLE_OPTIONS ); - (0, import_element24.useLayoutEffect)(() => { + (0, import_element26.useLayoutEffect)(() => { if (width) { setThrottledWidth(width); } }, [width, setThrottledWidth]); - (0, import_element24.useLayoutEffect)(() => { + (0, import_element26.useLayoutEffect)(() => { const newRatio = throttledWidth ? throttledWidth / normalizedWidth : 1; const ratioDiff = newRatio - (ratioState || 0); const isRatioDiffBigEnough = Math.abs(ratioDiff) > 0.1; @@ -11746,10 +12204,10 @@ function PreviewWrapper({ const fallbackRatio = width ? width / normalizedWidth : 1; const ratio = ratioState ? ratioState : fallbackRatio; const isReady = !!width; - return /* @__PURE__ */ (0, import_jsx_runtime33.jsxs)(import_jsx_runtime33.Fragment, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime33.jsx)("div", { style: { position: "relative" }, children: containerResizeListener }), + return /* @__PURE__ */ (0, import_jsx_runtime35.jsxs)(import_jsx_runtime35.Fragment, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime35.jsx)("div", { style: { position: "relative" }, children: containerResizeListener }), !isReady && // Match the preview aspect ratio so layout doesn't jump once width is measured. - /* @__PURE__ */ (0, import_jsx_runtime33.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime35.jsx)( Skeleton, { className: "global-styles-ui-preview__wrapper", @@ -11758,7 +12216,7 @@ function PreviewWrapper({ } } ), - isReady && /* @__PURE__ */ (0, import_jsx_runtime33.jsx)( + isReady && /* @__PURE__ */ (0, import_jsx_runtime35.jsx)( "div", { className: clsx_default("global-styles-ui-preview__wrapper", { @@ -11770,7 +12228,7 @@ function PreviewWrapper({ onMouseEnter: () => setIsHovered(true), onMouseLeave: () => setIsHovered(false), tabIndex: -1, - children: /* @__PURE__ */ (0, import_jsx_runtime33.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime35.jsx)( import_components6.__unstableMotion.div, { style: { @@ -11792,7 +12250,7 @@ function PreviewWrapper({ var preview_wrapper_default = PreviewWrapper; // packages/global-styles-ui/build-module/preview-styles.mjs -var import_jsx_runtime34 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime36 = __toESM(require_jsx_runtime(), 1); var firstFrameVariants = { start: { scale: 1, @@ -11842,14 +12300,14 @@ function PreviewStyles({ "elements.h1.color.text" ); const { paletteColors } = useStylesPreviewColors(); - return /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)( + return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)( preview_wrapper_default, { label, isFocused, withHoverView, children: [ - ({ ratio, key }) => /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + ({ ratio, key }) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( import_components7.__unstableMotion.div, { variants: firstFrameVariants, @@ -11857,7 +12315,7 @@ function PreviewStyles({ height: "100%", overflow: "hidden" }, - children: /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)( + children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)( import_components7.__experimentalHStack, { spacing: 10 * ratio, @@ -11867,14 +12325,14 @@ function PreviewStyles({ overflow: "hidden" }, children: [ - /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( PreviewTypography, { fontSize: 65 * ratio, variation } ), - /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(import_components7.__experimentalVStack, { spacing: 4 * ratio, children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(import_components7.__experimentalVStack, { spacing: 4 * ratio, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( HighlightedColors, { normalizedColorSwatchSize: 32, @@ -11887,7 +12345,7 @@ function PreviewStyles({ }, key ), - ({ key }) => /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + ({ key }) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( import_components7.__unstableMotion.div, { variants: withHoverView ? midFrameVariants : void 0, @@ -11900,7 +12358,7 @@ function PreviewStyles({ filter: "blur(60px)", opacity: 0.1 }, - children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( import_components7.__experimentalHStack, { spacing: 0, @@ -11909,7 +12367,7 @@ function PreviewStyles({ height: "100%", overflow: "hidden" }, - children: paletteColors.slice(0, 4).map(({ color }, index2) => /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + children: paletteColors.slice(0, 4).map(({ color }, index2) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( "div", { style: { @@ -11925,7 +12383,7 @@ function PreviewStyles({ }, key ), - ({ ratio, key }) => /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + ({ ratio, key }) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( import_components7.__unstableMotion.div, { variants: secondFrameVariants, @@ -11936,7 +12394,7 @@ function PreviewStyles({ position: "absolute", top: 0 }, - children: /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( import_components7.__experimentalVStack, { spacing: 3 * ratio, @@ -11947,7 +12405,7 @@ function PreviewStyles({ padding: 10 * ratio, boxSizing: "border-box" }, - children: label && /* @__PURE__ */ (0, import_jsx_runtime34.jsx)( + children: label && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)( "div", { style: { @@ -11973,14 +12431,14 @@ function PreviewStyles({ var preview_styles_default = PreviewStyles; // packages/global-styles-ui/build-module/screen-root.mjs -var import_jsx_runtime35 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime37 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-block-list.mjs var import_blocks2 = __toESM(require_blocks(), 1); -var import_i18n8 = __toESM(require_i18n(), 1); +var import_i18n10 = __toESM(require_i18n(), 1); var import_components11 = __toESM(require_components(), 1); var import_data4 = __toESM(require_data(), 1); -var import_element25 = __toESM(require_element(), 1); +var import_element27 = __toESM(require_element(), 1); var import_block_editor3 = __toESM(require_block_editor(), 1); var import_compose2 = __toESM(require_compose(), 1); import { speak } from "@wordpress/a11y"; @@ -11989,7 +12447,7 @@ import { speak } from "@wordpress/a11y"; var import_blocks = __toESM(require_blocks(), 1); var import_data3 = __toESM(require_data(), 1); var import_components9 = __toESM(require_components(), 1); -var import_jsx_runtime36 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime38 = __toESM(require_jsx_runtime(), 1); function getFilteredBlockStyles(blockStyles, variations) { return blockStyles?.filter( (style) => style.source === "block" || variations.includes(style.name) @@ -12010,13 +12468,13 @@ function useBlockVariations(name2) { // packages/global-styles-ui/build-module/screen-header.mjs var import_components10 = __toESM(require_components(), 1); -var import_i18n7 = __toESM(require_i18n(), 1); +var import_i18n9 = __toESM(require_i18n(), 1); var import_block_editor2 = __toESM(require_block_editor(), 1); -var import_jsx_runtime37 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime39 = __toESM(require_jsx_runtime(), 1); var { StateControl, StateControlBadges } = unlock3(import_block_editor2.privateApis); // packages/global-styles-ui/build-module/screen-block-list.mjs -var import_jsx_runtime38 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime40 = __toESM(require_jsx_runtime(), 1); var { useHasDimensionsPanel: useHasDimensionsPanel2, useHasTypographyPanel: useHasTypographyPanel2, @@ -12025,6 +12483,22 @@ var { useHasColorPanel: useHasColorPanel2, useHasBackgroundPanel: useHasBackgroundPanel2 } = unlock3(import_block_editor3.privateApis); +var { Menu } = unlock3(import_components11.privateApis); +function hasAnyValue(value) { + if (value === void 0 || value === null) { + return false; + } + if (Array.isArray(value)) { + return value.length > 0; + } + if (typeof value === "object") { + return Object.values(value).some(hasAnyValue); + } + return true; +} +function hasUserStylesForBlock(user, blockName) { + return hasAnyValue(user?.styles?.blocks?.[blockName]) || hasAnyValue(user?.settings?.blocks?.[blockName]); +} function useSortedBlockTypes() { const blockItems = (0, import_data4.useSelect)( (select) => select(import_blocks2.store).getBlockTypes(), @@ -12055,88 +12529,144 @@ function useBlockHasGlobalStyles(blockName) { const hasGlobalStyles = hasTypographyPanel || hasColorPanel || hasBackgroundPanel || hasLayoutPanel || hasVariationsPanel; return hasGlobalStyles; } -function BlockMenuItem({ block }) { +function BlockMenuItem({ block, isCustomized }) { const hasBlockMenuItem = useBlockHasGlobalStyles(block.name); if (!hasBlockMenuItem) { return null; } - return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( NavigationButtonAsItem, { path: "/blocks/" + encodeURIComponent(block.name), - children: /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(import_components11.__experimentalHStack, { justify: "flex-start", children: [ - /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_block_editor3.BlockIcon, { icon: block.icon }), - /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_components11.FlexItem, { children: block.title }) + children: /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_components11.__experimentalHStack, { justify: "flex-start", spacing: 2, children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + import_block_editor3.BlockIcon, + { + className: "global-styles-ui-block-types-item__icon", + icon: block.icon + } + ), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_components11.FlexItem, { children: block.title }), + isCustomized && /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(import_jsx_runtime40.Fragment, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(VisuallyHidden, { children: (0, import_i18n10.__)("Has custom styles") }), + /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + "span", + { + "aria-hidden": "true", + className: "global-styles-ui-block-types-item__indicator" + } + ) + ] }) ] }) } ); } -function BlockList({ filterValue }) { +function EmptyBlockList({ + filterValue, + styleFilter +}) { + const label = "customized" === styleFilter && !filterValue ? (0, import_i18n10.__)("You haven't customized any blocks yet.") : (0, import_i18n10.__)("No blocks found."); + return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + import_components11.__experimentalText, + { + align: "center", + as: "p", + className: "global-styles-ui-block-types-item-list__no-results", + children: label + } + ); +} +function BlockList({ filterValue, styleFilter }) { const sortedBlockTypes = useSortedBlockTypes(); const debouncedSpeak = (0, import_compose2.useDebounce)(speak, 500); const { isMatchingSearchTerm } = (0, import_data4.useSelect)(import_blocks2.store); - const filteredBlockTypes = !filterValue ? sortedBlockTypes : sortedBlockTypes.filter( + const { user } = (0, import_element27.useContext)(GlobalStylesContext); + const customizedBlockNames = (0, import_element27.useMemo)(() => { + const names = /* @__PURE__ */ new Set(); + const blockNames = [ + ...Object.keys(user?.styles?.blocks ?? {}), + ...Object.keys(user?.settings?.blocks ?? {}) + ]; + blockNames.forEach((blockName) => { + if (hasUserStylesForBlock(user, blockName)) { + names.add(blockName); + } + }); + return names; + }, [user]); + const searchedBlockTypes = !filterValue ? sortedBlockTypes : sortedBlockTypes.filter( (blockType) => isMatchingSearchTerm(blockType, filterValue) ); - const blockTypesListRef = (0, import_element25.useRef)(null); - (0, import_element25.useEffect)(() => { - if (!filterValue) { + const filteredBlockTypes = styleFilter === "customized" ? searchedBlockTypes.filter( + (blockType) => customizedBlockNames.has(blockType.name) + ) : searchedBlockTypes; + const blockTypesListRef = (0, import_element27.useRef)(null); + const hasResults = filteredBlockTypes.length > 0; + (0, import_element27.useEffect)(() => { + if (!filterValue && styleFilter === "all") { return; } - const count = blockTypesListRef.current?.childElementCount || 0; - const resultsFoundMessage = (0, import_i18n8.sprintf)( + const count = hasResults ? blockTypesListRef.current?.childElementCount || 0 : 0; + const resultsFoundMessage = (0, import_i18n10.sprintf)( /* translators: %d: number of results. */ - (0, import_i18n8._n)("%d result found.", "%d results found.", count), + (0, import_i18n10._n)("%d result found.", "%d results found.", count), count ); debouncedSpeak(resultsFoundMessage, "polite"); - }, [filterValue, debouncedSpeak]); - return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + }, [filterValue, styleFilter, hasResults, debouncedSpeak]); + return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( "div", { ref: blockTypesListRef, className: "global-styles-ui-block-types-item-list", role: "list", - children: filteredBlockTypes.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(import_components11.__experimentalText, { align: "center", as: "p", children: (0, import_i18n8.__)("No blocks found.") }) : filteredBlockTypes.map((block) => /* @__PURE__ */ (0, import_jsx_runtime38.jsx)( + children: filteredBlockTypes.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( + EmptyBlockList, + { + filterValue, + styleFilter + } + ) : filteredBlockTypes.map((block) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)( BlockMenuItem, { - block + block, + isCustomized: customizedBlockNames.has(block.name) }, "menu-itemblock-" + block.name )) } ); } -var MemoizedBlockList = (0, import_element25.memo)(BlockList); +var MemoizedBlockList = (0, import_element27.memo)(BlockList); // packages/global-styles-ui/build-module/screen-block.mjs var import_blocks4 = __toESM(require_blocks(), 1); var import_block_editor5 = __toESM(require_block_editor(), 1); -var import_element27 = __toESM(require_element(), 1); +var import_element29 = __toESM(require_element(), 1); var import_data5 = __toESM(require_data(), 1); var import_core_data3 = __toESM(require_core_data(), 1); var import_components14 = __toESM(require_components(), 1); -var import_i18n9 = __toESM(require_i18n(), 1); +var import_i18n11 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/block-preview-panel.mjs var import_block_editor4 = __toESM(require_block_editor(), 1); var import_blocks3 = __toESM(require_blocks(), 1); var import_components12 = __toESM(require_components(), 1); -var import_element26 = __toESM(require_element(), 1); -var import_jsx_runtime39 = __toESM(require_jsx_runtime(), 1); +var import_element28 = __toESM(require_element(), 1); +var import_jsx_runtime41 = __toESM(require_jsx_runtime(), 1); var { getViewportBreakpoints: getViewportBreakpoints3, getViewportBreakpointValueInPixels: getViewportBreakpointValueInPixels2 } = unlock3( privateApis ); // packages/global-styles-ui/build-module/subtitle.mjs var import_components13 = __toESM(require_components(), 1); -var import_jsx_runtime40 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime42 = __toESM(require_jsx_runtime(), 1); function Subtitle({ children, level = 2 }) { - return /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(import_components13.__experimentalHeading, { className: "global-styles-ui-subtitle", level, children }); + return /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(import_components13.__experimentalHeading, { className: "global-styles-ui-subtitle", level, children }); } // packages/global-styles-ui/build-module/screen-block.mjs -var import_jsx_runtime41 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime43 = __toESM(require_jsx_runtime(), 1); var { useHasDimensionsPanel: useHasDimensionsPanel3, useHasTypographyPanel: useHasTypographyPanel3, @@ -12157,37 +12687,37 @@ var { } = unlock3(import_block_editor5.privateApis); // packages/global-styles-ui/build-module/screen-typography.mjs -var import_i18n23 = __toESM(require_i18n(), 1); -var import_components31 = __toESM(require_components(), 1); -var import_element39 = __toESM(require_element(), 1); +var import_i18n25 = __toESM(require_i18n(), 1); +var import_components30 = __toESM(require_components(), 1); +var import_element41 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/screen-body.mjs var import_components15 = __toESM(require_components(), 1); -var import_jsx_runtime42 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime44 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/typography-elements.mjs -var import_i18n10 = __toESM(require_i18n(), 1); +var import_i18n12 = __toESM(require_i18n(), 1); var import_components16 = __toESM(require_components(), 1); -var import_jsx_runtime43 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime45 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/variations/variations-typography.mjs var import_components18 = __toESM(require_components(), 1); // packages/global-styles-ui/build-module/preview-typography.mjs var import_components17 = __toESM(require_components(), 1); -var import_jsx_runtime44 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime46 = __toESM(require_jsx_runtime(), 1); var StylesPreviewTypography = ({ variation, isFocused, withHoverView }) => { - return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)( preview_wrapper_default, { label: variation.title, isFocused, withHoverView, - children: ({ ratio, key }) => /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( + children: ({ ratio, key }) => /* @__PURE__ */ (0, import_jsx_runtime46.jsx)( import_components17.__experimentalHStack, { spacing: 10 * ratio, @@ -12196,7 +12726,7 @@ var StylesPreviewTypography = ({ height: "100%", overflow: "hidden" }, - children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime46.jsx)( PreviewTypography, { variation, @@ -12212,10 +12742,10 @@ var StylesPreviewTypography = ({ var preview_typography_default = StylesPreviewTypography; // packages/global-styles-ui/build-module/variations/variation.mjs -var import_element28 = __toESM(require_element(), 1); +var import_element30 = __toESM(require_element(), 1); var import_keycodes = __toESM(require_keycodes(), 1); -var import_i18n11 = __toESM(require_i18n(), 1); -var import_jsx_runtime45 = __toESM(require_jsx_runtime(), 1); +var import_i18n13 = __toESM(require_i18n(), 1); +var import_jsx_runtime47 = __toESM(require_jsx_runtime(), 1); function Variation({ variation, children, @@ -12223,13 +12753,13 @@ function Variation({ properties, showTooltip = false }) { - const [isFocused, setIsFocused] = (0, import_element28.useState)(false); + const [isFocused, setIsFocused] = (0, import_element30.useState)(false); const { base, user, onChange: setUserConfig - } = (0, import_element28.useContext)(GlobalStylesContext); - const context = (0, import_element28.useMemo)(() => { + } = (0, import_element30.useContext)(GlobalStylesContext); + const context = (0, import_element30.useMemo)(() => { let merged = mergeGlobalStyles(base, variation); if (properties) { merged = filterObjectByProperties(merged, properties); @@ -12249,20 +12779,20 @@ function Variation({ selectVariation(); } }; - const isActive = (0, import_element28.useMemo)( + const isActive = (0, import_element30.useMemo)( () => areGlobalStylesEqual(user, variation), [user, variation] ); let label = variation?.title; if (variation?.description) { - label = (0, import_i18n11.sprintf)( + label = (0, import_i18n13.sprintf)( /* translators: 1: variation title. 2: variation description. */ - (0, import_i18n11._x)("%1$s (%2$s)", "variation label"), + (0, import_i18n13._x)("%1$s (%2$s)", "variation label"), variation?.title, variation?.description ); } - const content = /* @__PURE__ */ (0, import_jsx_runtime45.jsx)( + const content = /* @__PURE__ */ (0, import_jsx_runtime47.jsx)( "div", { className: clsx_default("global-styles-ui-variations_item", { @@ -12276,7 +12806,7 @@ function Variation({ "aria-current": isActive, onFocus: () => setIsFocused(true), onBlur: () => setIsFocused(false), - children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)( "div", { className: clsx_default("global-styles-ui-variations_item-preview", { @@ -12287,14 +12817,14 @@ function Variation({ ) } ); - return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(GlobalStylesContext.Provider, { value: context, children: showTooltip ? /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(tooltip_exports.Root, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(tooltip_exports.Trigger, { render: content }), - /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(tooltip_exports.Popup, { children: variation?.title }) + return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(GlobalStylesContext.Provider, { value: context, children: showTooltip ? /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(tooltip_exports.Root, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(tooltip_exports.Trigger, { render: content }), + /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(tooltip_exports.Popup, { children: variation?.title }) ] }) : content }); } // packages/global-styles-ui/build-module/variations/variations-typography.mjs -var import_jsx_runtime46 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime48 = __toESM(require_jsx_runtime(), 1); var propertiesToFilter = ["typography"]; function TypographyVariations({ title, @@ -12304,9 +12834,9 @@ function TypographyVariations({ if (typographyVariations?.length <= 1) { return null; } - return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)(import_components18.__experimentalVStack, { spacing: 3, children: [ - title && /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Subtitle, { level: 3, children: title }), - /* @__PURE__ */ (0, import_jsx_runtime46.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(import_components18.__experimentalVStack, { spacing: 3, children: [ + title && /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(Subtitle, { level: 3, children: title }), + /* @__PURE__ */ (0, import_jsx_runtime48.jsx)( import_components18.__experimentalGrid, { columns: 3, @@ -12314,13 +12844,13 @@ function TypographyVariations({ className: "global-styles-ui-style-variations-container", children: typographyVariations.map( (variation, index2) => { - return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)( Variation, { variation, properties: propertiesToFilter, showTooltip: true, - children: () => /* @__PURE__ */ (0, import_jsx_runtime46.jsx)( + children: () => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)( preview_typography_default, { variation @@ -12337,15 +12867,15 @@ function TypographyVariations({ } // packages/global-styles-ui/build-module/font-families.mjs -var import_i18n21 = __toESM(require_i18n(), 1); -var import_components29 = __toESM(require_components(), 1); -var import_element38 = __toESM(require_element(), 1); +var import_i18n23 = __toESM(require_i18n(), 1); +var import_components28 = __toESM(require_components(), 1); +var import_element40 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/font-library/context.mjs -var import_element29 = __toESM(require_element(), 1); +var import_element31 = __toESM(require_element(), 1); var import_data6 = __toESM(require_data(), 1); var import_core_data5 = __toESM(require_core_data(), 1); -var import_i18n13 = __toESM(require_i18n(), 1); +var import_i18n15 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/font-library/api.mjs var import_api_fetch = __toESM(require_api_fetch(), 1); @@ -12467,22 +12997,22 @@ function kebabCase(str) { } // packages/global-styles-ui/build-module/font-library/utils/constants.mjs -var import_i18n12 = __toESM(require_i18n(), 1); +var import_i18n14 = __toESM(require_i18n(), 1); var ALLOWED_FILE_EXTENSIONS = ["otf", "ttf", "woff", "woff2"]; var FONT_WEIGHTS = { - 100: (0, import_i18n12._x)("Thin", "font weight"), - 200: (0, import_i18n12._x)("Extra-light", "font weight"), - 300: (0, import_i18n12._x)("Light", "font weight"), - 400: (0, import_i18n12._x)("Normal", "font weight"), - 500: (0, import_i18n12._x)("Medium", "font weight"), - 600: (0, import_i18n12._x)("Semi-bold", "font weight"), - 700: (0, import_i18n12._x)("Bold", "font weight"), - 800: (0, import_i18n12._x)("Extra-bold", "font weight"), - 900: (0, import_i18n12._x)("Black", "font weight") + 100: (0, import_i18n14._x)("Thin", "font weight"), + 200: (0, import_i18n14._x)("Extra-light", "font weight"), + 300: (0, import_i18n14._x)("Light", "font weight"), + 400: (0, import_i18n14._x)("Normal", "font weight"), + 500: (0, import_i18n14._x)("Medium", "font weight"), + 600: (0, import_i18n14._x)("Semi-bold", "font weight"), + 700: (0, import_i18n14._x)("Bold", "font weight"), + 800: (0, import_i18n14._x)("Extra-bold", "font weight"), + 900: (0, import_i18n14._x)("Black", "font weight") }; var FONT_STYLES = { - normal: (0, import_i18n12._x)("Normal", "font style"), - italic: (0, import_i18n12._x)("Italic", "font style") + normal: (0, import_i18n14._x)("Normal", "font style"), + italic: (0, import_i18n14._x)("Italic", "font style") }; // packages/global-styles-ui/build-module/font-library/utils/index.mjs @@ -12760,8 +13290,8 @@ function toggleFont(font2, face, initialfonts = []) { } // packages/global-styles-ui/build-module/font-library/context.mjs -var import_jsx_runtime47 = __toESM(require_jsx_runtime(), 1); -var FontLibraryContext = (0, import_element29.createContext)( +var import_jsx_runtime49 = __toESM(require_jsx_runtime(), 1); +var FontLibraryContext = (0, import_element31.createContext)( {} ); FontLibraryContext.displayName = "FontLibraryContext"; @@ -12777,7 +13307,7 @@ function FontLibraryProvider({ children }) { "globalStyles", globalStylesId ); - const [isInstalling, setIsInstalling] = (0, import_element29.useState)(false); + const [isInstalling, setIsInstalling] = (0, import_element31.useState)(false); const { records: libraryPosts = [], isResolving: isResolvingLibrary } = (0, import_core_data5.useEntityRecords)( "postType", "wp_font_family", @@ -12807,12 +13337,12 @@ function FontLibraryProvider({ children }) { ); await saveEntityRecord("root", "globalStyles", finalGlobalStyles); }; - const [modalTabOpen, setModalTabOpen] = (0, import_element29.useState)(""); - const [libraryFontSelected, setLibraryFontSelected] = (0, import_element29.useState)(void 0); + const [modalTabOpen, setModalTabOpen] = (0, import_element31.useState)(""); + const [libraryFontSelected, setLibraryFontSelected] = (0, import_element31.useState)(void 0); const themeFonts = fontFamilies?.theme ? fontFamilies.theme.map((f2) => setUIValuesNeeded(f2, { source: "theme" })).sort((a2, b2) => a2.name.localeCompare(b2.name)) : []; const customFonts = fontFamilies?.custom ? fontFamilies.custom.map((f2) => setUIValuesNeeded(f2, { source: "custom" })).sort((a2, b2) => a2.name.localeCompare(b2.name)) : []; const baseCustomFonts = libraryFonts ? libraryFonts.map((f2) => setUIValuesNeeded(f2, { source: "custom" })).sort((a2, b2) => a2.name.localeCompare(b2.name)) : []; - (0, import_element29.useEffect)(() => { + (0, import_element31.useEffect)(() => { if (!modalTabOpen) { setLibraryFontSelected(void 0); } @@ -12829,7 +13359,7 @@ function FontLibraryProvider({ children }) { source: font2.source }); }; - const [loadedFontUrls] = (0, import_element29.useState)(/* @__PURE__ */ new Set()); + const [loadedFontUrls] = (0, import_element31.useState)(/* @__PURE__ */ new Set()); const getAvailableFontsOutline = (availableFontFamilies) => { const outline = availableFontFamilies.reduce( (acc, font2) => { @@ -12957,7 +13487,7 @@ function FontLibraryProvider({ children }) { await saveFontFamilies(activeFonts); } if (installationErrorMessages.length > 0) { - const installError = new Error((0, import_i18n13.__)("There was an error installing fonts.")); + const installError = new Error((0, import_i18n15.__)("There was an error installing fonts.")); installError.installationErrors = installationErrorMessages; throw installError; } @@ -12967,7 +13497,7 @@ function FontLibraryProvider({ children }) { } async function uninstallFontFamily(fontFamilyToUninstall) { if (!fontFamilyToUninstall?.id) { - throw new Error((0, import_i18n13.__)("Font family to uninstall is not defined.")); + throw new Error((0, import_i18n15.__)("Font family to uninstall is not defined.")); } try { await deleteEntityRecord( @@ -13072,7 +13602,7 @@ function FontLibraryProvider({ children }) { loadFontFaceInBrowser(fontFace, src, "document"); loadedFontUrls.add(src); }; - return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)( FontLibraryContext.Provider, { value: { @@ -13100,27 +13630,27 @@ function FontLibraryProvider({ children }) { var context_default = FontLibraryProvider; // packages/global-styles-ui/build-module/font-library/modal.mjs -var import_i18n19 = __toESM(require_i18n(), 1); -var import_components27 = __toESM(require_components(), 1); +var import_i18n21 = __toESM(require_i18n(), 1); +var import_components26 = __toESM(require_components(), 1); var import_core_data8 = __toESM(require_core_data(), 1); var import_data8 = __toESM(require_data(), 1); // packages/global-styles-ui/build-module/font-library/installed-fonts.mjs -var import_components22 = __toESM(require_components(), 1); +var import_components21 = __toESM(require_components(), 1); var import_core_data6 = __toESM(require_core_data(), 1); var import_data7 = __toESM(require_data(), 1); -var import_element33 = __toESM(require_element(), 1); -var import_i18n15 = __toESM(require_i18n(), 1); +var import_element35 = __toESM(require_element(), 1); +var import_i18n17 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/font-library/font-card.mjs -var import_i18n14 = __toESM(require_i18n(), 1); -var import_element31 = __toESM(require_element(), 1); -var import_components20 = __toESM(require_components(), 1); +var import_i18n16 = __toESM(require_i18n(), 1); +var import_element33 = __toESM(require_element(), 1); +var import_components19 = __toESM(require_components(), 1); // packages/global-styles-ui/build-module/font-library/font-demo.mjs -var import_components19 = __toESM(require_components(), 1); -var import_element30 = __toESM(require_element(), 1); -var import_jsx_runtime48 = __toESM(require_jsx_runtime(), 1); +var import_element32 = __toESM(require_element(), 1); +var import_jsx_runtime50 = __toESM(require_jsx_runtime(), 1); +var loadedPreviews = /* @__PURE__ */ new Set(); function getPreviewUrl(fontFace) { if (fontFace.preview) { return fontFace.preview; @@ -13146,16 +13676,24 @@ function getDisplayFontFace(font2) { }; } function FontDemo({ font: font2, text }) { - const ref = (0, import_element30.useRef)(null); + const ref = (0, import_element32.useRef)(null); const fontFace = getDisplayFontFace(font2); const style = getFamilyPreviewStyle(font2); text = text || ("name" in font2 ? font2.name : ""); const customPreviewUrl = font2.preview; - const [isIntersecting, setIsIntersecting] = (0, import_element30.useState)(false); - const [isAssetLoaded, setIsAssetLoaded] = (0, import_element30.useState)(false); - const { loadFontFaceAsset } = (0, import_element30.useContext)(FontLibraryContext); const previewUrl = customPreviewUrl ?? getPreviewUrl(fontFace); - const isPreviewImage = previewUrl && previewUrl.match(/\.(png|jpg|jpeg|gif|svg)$/i); + const isPreviewImage = Boolean( + previewUrl && /\.(png|jpg|jpeg|gif|svg)$/i.test(previewUrl) + ); + const [isIntersecting, setIsIntersecting] = (0, import_element32.useState)(false); + const [isFontLoaded, setIsFontLoaded] = (0, import_element32.useState)(false); + const [resolvedUrl, setResolvedUrl] = (0, import_element32.useState)(); + const { loadFontFaceAsset } = (0, import_element32.useContext)(FontLibraryContext); + const isAssetLoaded = isPreviewImage ? !!previewUrl && (loadedPreviews.has(previewUrl) || resolvedUrl === previewUrl) : isFontLoaded; + const estimatedImageWidth = Math.min( + Math.max(text.length * 12, 48), + 300 + ); const faceStyles = getFacePreviewStyle(fontFace); const textDemoStyle = { fontSize: "18px", @@ -13164,7 +13702,10 @@ function FontDemo({ font: font2, text }) { ...style, ...faceStyles }; - (0, import_element30.useEffect)(() => { + (0, import_element32.useEffect)(() => { + if (isPreviewImage) { + return; + } const observer = new window.IntersectionObserver(([entry]) => { setIsIntersecting(entry.isIntersecting); }, {}); @@ -13172,28 +13713,47 @@ function FontDemo({ font: font2, text }) { observer.observe(ref.current); } return () => observer.disconnect(); - }, [ref]); - (0, import_element30.useEffect)(() => { + }, [isPreviewImage]); + (0, import_element32.useEffect)(() => { const loadAsset = async () => { - if (isIntersecting) { - if (!isPreviewImage && fontFace.src) { + if (isIntersecting && !isPreviewImage) { + if (fontFace.src) { await loadFontFaceAsset(fontFace); } - setIsAssetLoaded(true); + setIsFontLoaded(true); } }; loadAsset(); }, [fontFace, isIntersecting, loadFontFaceAsset, isPreviewImage]); - return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { ref, children: isPreviewImage ? /* @__PURE__ */ (0, import_jsx_runtime48.jsx)( - "img", - { - src: previewUrl, - loading: "lazy", - alt: text, - className: "font-library__font-variant_demo-image" - } - ) : /* @__PURE__ */ (0, import_jsx_runtime48.jsx)( - import_components19.__experimentalText, + return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { ref, className: "font-library__font-demo", children: isPreviewImage ? /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_jsx_runtime50.Fragment, { children: [ + !isAssetLoaded && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)( + Skeleton, + { + className: "font-library__font-variant-demo-skeleton", + style: { width: estimatedImageWidth } + } + ), + /* @__PURE__ */ (0, import_jsx_runtime50.jsx)( + "img", + { + src: previewUrl, + loading: "lazy", + alt: text, + onLoad: () => { + if (previewUrl) { + loadedPreviews.add(previewUrl); + } + setResolvedUrl(previewUrl); + }, + onError: () => setResolvedUrl(previewUrl), + className: clsx_default( + "font-library__font-variant_demo-image", + { "is-loading": !isAssetLoaded } + ) + } + ) + ] }) : /* @__PURE__ */ (0, import_jsx_runtime50.jsx)( + "span", { style: textDemoStyle, className: "font-library__font-variant_demo-text", @@ -13204,7 +13764,7 @@ function FontDemo({ font: font2, text }) { var font_demo_default = FontDemo; // packages/global-styles-ui/build-module/font-library/font-card.mjs -var import_jsx_runtime49 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime51 = __toESM(require_jsx_runtime(), 1); function FontCard({ font: font2, onClick, @@ -13216,15 +13776,15 @@ function FontCard({ const style = { cursor: !!onClick ? "pointer" : "default" }; - const navigator2 = (0, import_components20.useNavigator)(); - const ref = (0, import_element31.useRef)(null); - (0, import_element31.useEffect)(() => { + const navigator2 = (0, import_components19.useNavigator)(); + const ref = (0, import_element33.useRef)(null); + (0, import_element33.useEffect)(() => { if (shouldFocus) { ref.current?.focus(); } }, [shouldFocus]); - return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)( - import_components20.Button, + return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + import_components19.Button, { ref, __next40pxDefaultSize: true, @@ -13236,19 +13796,19 @@ function FontCard({ }, style, className: "font-library__font-card", - children: /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(import_components20.Flex, { justify: "space-between", wrap: false, children: [ - /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(font_demo_default, { font: font2 }), - /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(import_components20.Flex, { justify: "flex-end", children: [ - /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(import_components20.FlexItem, { children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(import_components20.__experimentalText, { className: "font-library__font-card__count", children: variantsText || (0, import_i18n14.sprintf)( + children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components19.Flex, { justify: "space-between", wrap: false, children: [ + /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(font_demo_default, { font: font2 }), + /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components19.Flex, { justify: "flex-end", children: [ + /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components19.FlexItem, { children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components19.__experimentalText, { className: "font-library__font-card__count", children: variantsText || (0, import_i18n16.sprintf)( /* translators: %d: Number of font variants. */ - (0, import_i18n14._n)( + (0, import_i18n16._n)( "%d variant", "%d variants", variantsCount ), variantsCount ) }) }), - /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(import_components20.FlexItem, { children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(icon_default, { icon: (0, import_i18n14.isRTL)() ? chevron_left_default : chevron_right_default }) }) + /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components19.FlexItem, { children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(icon_default, { icon: (0, import_i18n16.isRTL)() ? chevron_left_default : chevron_right_default }) }) ] }) ] }) } @@ -13257,14 +13817,14 @@ function FontCard({ var font_card_default = FontCard; // packages/global-styles-ui/build-module/font-library/library-font-variant.mjs -var import_element32 = __toESM(require_element(), 1); -var import_components21 = __toESM(require_components(), 1); -var import_jsx_runtime50 = __toESM(require_jsx_runtime(), 1); +var import_element34 = __toESM(require_element(), 1); +var import_components20 = __toESM(require_components(), 1); +var import_jsx_runtime52 = __toESM(require_jsx_runtime(), 1); function LibraryFontVariant({ face, font: font2 }) { - const { isFontActivated, toggleActivateFont } = (0, import_element32.useContext)(FontLibraryContext); + const { isFontActivated, toggleActivateFont } = (0, import_element34.useContext)(FontLibraryContext); const isInstalled = (font2?.fontFace?.length ?? 0) > 0 ? isFontActivated( font2.slug, face.fontStyle, @@ -13279,17 +13839,17 @@ function LibraryFontVariant({ toggleActivateFont(font2); }; const displayName = font2.name + " " + getFontFaceVariantName(face); - const checkboxId = (0, import_element32.useId)(); - return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "font-library__font-card", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(import_components21.Flex, { justify: "flex-start", align: "center", gap: "1rem", children: [ - /* @__PURE__ */ (0, import_jsx_runtime50.jsx)( - import_components21.CheckboxControl, + const checkboxId = (0, import_element34.useId)(); + return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "font-library__font-card", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(import_components20.Flex, { justify: "flex-start", align: "center", gap: "1rem", children: [ + /* @__PURE__ */ (0, import_jsx_runtime52.jsx)( + import_components20.CheckboxControl, { checked: isInstalled, onChange: handleToggleActivation, id: checkboxId } ), - /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("label", { htmlFor: checkboxId, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("label", { htmlFor: checkboxId, children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)( font_demo_default, { font: face, @@ -13335,7 +13895,7 @@ function sortFontFaces(faces) { } // packages/global-styles-ui/build-module/font-library/installed-fonts.mjs -var import_jsx_runtime51 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime53 = __toESM(require_jsx_runtime(), 1); function getFontFamiliesKey(fontFamilies) { if (!fontFamilies) { return ""; @@ -13361,11 +13921,11 @@ function InstalledFonts() { isInstalling, saveFontFamilies, getFontFacesActivated - } = (0, import_element33.useContext)(FontLibraryContext); + } = (0, import_element35.useContext)(FontLibraryContext); const [fontFamilies, setFontFamilies] = useSetting("typography.fontFamilies"); - const [lastSelectedFontSlug, setLastSelectedFontSlug] = (0, import_element33.useState)(void 0); - const [isConfirmDeleteOpen, setIsConfirmDeleteOpen] = (0, import_element33.useState)(false); - const [notice, setNotice] = (0, import_element33.useState)(null); + const [lastSelectedFontSlug, setLastSelectedFontSlug] = (0, import_element35.useState)(void 0); + const [isConfirmDeleteOpen, setIsConfirmDeleteOpen] = (0, import_element35.useState)(false); + const [notice, setNotice] = (0, import_element35.useState)(null); const [baseFontFamilies] = useSetting("typography.fontFamilies", void 0, "base"); const globalStylesId = (0, import_data7.useSelect)((select) => { const { __experimentalGetCurrentGlobalStylesId } = select(import_core_data6.store); @@ -13378,7 +13938,7 @@ function InstalledFonts() { ); const editedFontFamilies = globalStyles?.edits?.settings?.typography?.fontFamilies; const savedFontFamilies = globalStyles?.record?.settings?.typography?.fontFamilies; - const fontFamiliesHasChanges = (0, import_element33.useMemo)(() => { + const fontFamiliesHasChanges = (0, import_element35.useMemo)(() => { if (editedFontFamilies === void 0) { return false; } @@ -13411,14 +13971,14 @@ function InstalledFonts() { await saveFontFamilies(fontFamilies); setNotice({ type: "success", - message: (0, import_i18n15.__)("Font family updated successfully.") + message: (0, import_i18n17.__)("Font family updated successfully.") }); } catch (error) { setNotice({ type: "error", - message: (0, import_i18n15.sprintf)( + message: (0, import_i18n17.sprintf)( /* translators: %s: error message */ - (0, import_i18n15.__)("There was an error updating the font family. %s"), + (0, import_i18n17.__)("There was an error updating the font family. %s"), error.message ) }); @@ -13445,14 +14005,14 @@ function InstalledFonts() { font2.slug, font2.source ).length; - return (0, import_i18n15.sprintf)( + return (0, import_i18n17.sprintf)( /* translators: 1: Active font variants, 2: Total font variants. */ - (0, import_i18n15.__)("%1$d of %2$d active"), + (0, import_i18n17.__)("%1$d of %2$d active"), variantsActive, variantsInstalled ); }; - (0, import_element33.useEffect)(() => { + (0, import_element35.useEffect)(() => { handleSetLibraryFontSelected(libraryFontSelected); }, []); const activeFontsCount = libraryFontSelected ? getFontFacesActivated( @@ -13490,40 +14050,40 @@ function InstalledFonts() { } }; const hasFonts = baseThemeFonts.length > 0 || baseCustomFonts.length > 0; - return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: "font-library__tabpanel-layout", children: [ - isResolvingLibrary && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "font-library__loading", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.ProgressBar, {}) }), - !isResolvingLibrary && /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_jsx_runtime51.Fragment, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)( - import_components22.Navigator, + return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "font-library__tabpanel-layout", children: [ + isResolvingLibrary && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "font-library__loading", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.ProgressBar, {}) }), + !isResolvingLibrary && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_jsx_runtime53.Fragment, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)( + import_components21.Navigator, { initialPath: libraryFontSelected ? "/fontFamily" : "/", children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.Navigator.Screen, { path: "/", children: /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.__experimentalVStack, { spacing: "8", children: [ - notice && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.Notice, + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.Navigator.Screen, { path: "/", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.__experimentalVStack, { spacing: "8", children: [ + notice && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.Notice, { status: notice.type, onRemove: () => setNotice(null), children: notice.message } ), - !hasFonts && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalText, { as: "p", children: (0, import_i18n15.__)("No fonts installed.") }), - baseThemeFonts.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.__experimentalVStack, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("h2", { + !hasFonts && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalText, { as: "p", children: (0, import_i18n17.__)("No fonts installed.") }), + baseThemeFonts.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.__experimentalVStack, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("h2", { className: "font-library__fonts-title", /* translators: Heading for a list of fonts provided by the theme. */ - children: (0, import_i18n15._x)("Theme", "font source") + children: (0, import_i18n17._x)("Theme", "font source") }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( "ul", { role: "list", className: "font-library__fonts-list", - children: baseThemeFonts.map((font2) => /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + children: baseThemeFonts.map((font2) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( "li", { className: "font-library__fonts-list-item", - children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( font_card_default, { font: font2, @@ -13546,22 +14106,22 @@ function InstalledFonts() { } ) ] }), - baseCustomFonts.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.__experimentalVStack, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("h2", { + baseCustomFonts.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.__experimentalVStack, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("h2", { className: "font-library__fonts-title", /* translators: Heading for a list of fonts installed by the user. */ - children: (0, import_i18n15._x)("Custom", "font source") + children: (0, import_i18n17._x)("Custom", "font source") }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( "ul", { role: "list", className: "font-library__fonts-list", - children: baseCustomFonts.map((font2) => /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + children: baseCustomFonts.map((font2) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( "li", { className: "font-library__fonts-list-item", - children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( font_card_default, { font: font2, @@ -13585,8 +14145,8 @@ function InstalledFonts() { ) ] }) ] }) }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.Navigator.Screen, { path: "/fontFamily", children: [ - libraryFontSelected && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.Navigator.Screen, { path: "/fontFamily", children: [ + libraryFontSelected && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( ConfirmDeleteDialog, { font: libraryFontSelected, @@ -13597,11 +14157,11 @@ function InstalledFonts() { handleSetLibraryFontSelected } ), - /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.Flex, { justify: "flex-start", children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.Navigator.BackButton, + /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.Flex, { justify: "flex-start", children: [ + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.Navigator.BackButton, { - icon: (0, import_i18n15.isRTL)() ? chevron_right_default : chevron_left_default, + icon: (0, import_i18n17.isRTL)() ? chevron_right_default : chevron_left_default, size: "small", onClick: () => { setLastSelectedFontSlug( @@ -13612,11 +14172,11 @@ function InstalledFonts() { ); setNotice(null); }, - label: (0, import_i18n15.__)("Back") + label: (0, import_i18n17.__)("Back") } ), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.__experimentalHeading, + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.__experimentalHeading, { level: 2, size: 13, @@ -13625,47 +14185,47 @@ function InstalledFonts() { } ) ] }), - notice && /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_jsx_runtime51.Fragment, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalSpacer, { margin: 1 }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.Notice, + notice && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_jsx_runtime53.Fragment, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalSpacer, { margin: 1 }), + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.Notice, { status: notice.type, onRemove: () => setNotice(null), children: notice.message } ), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalSpacer, { margin: 1 }) + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalSpacer, { margin: 1 }) ] }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalSpacer, { margin: 4 }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalText, { children: (0, import_i18n15.__)( + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalSpacer, { margin: 4 }), + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalText, { children: (0, import_i18n17.__)( "Choose font variants. Keep in mind that too many variants could make your site slower." ) }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalSpacer, { margin: 4 }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.__experimentalVStack, { spacing: 0, children: [ - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.CheckboxControl, + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalSpacer, { margin: 4 }), + /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.__experimentalVStack, { spacing: 0, children: [ + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.CheckboxControl, { className: "font-library__select-all", - label: (0, import_i18n15.__)("Select all"), + label: (0, import_i18n17.__)("Select all"), checked: isSelectAllChecked, onChange: toggleSelectAll, indeterminate: isIndeterminate } ), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.__experimentalSpacer, { margin: 8 }), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.__experimentalSpacer, { margin: 8 }), + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( "ul", { role: "list", className: "font-library__fonts-list", children: libraryFontSelected && getFontFacesToDisplay( libraryFontSelected - ).map((face, i2) => /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + ).map((face, i2) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( "li", { className: "font-library__fonts-list-item", - children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( library_font_variant_default, { font: libraryFontSelected, @@ -13683,27 +14243,27 @@ function InstalledFonts() { ] } ), - /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(import_components22.__experimentalHStack, { justify: "flex-end", className: "font-library__footer", children: [ - isInstalling && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_components22.ProgressBar, {}), - shouldDisplayDeleteButton && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.Button, + /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components21.__experimentalHStack, { justify: "flex-end", className: "font-library__footer", children: [ + isInstalling && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(import_components21.ProgressBar, {}), + shouldDisplayDeleteButton && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.Button, { __next40pxDefaultSize: true, isDestructive: true, variant: "tertiary", onClick: handleUninstallClick, - children: (0, import_i18n15.__)("Delete") + children: (0, import_i18n17.__)("Delete") } ), - /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.Button, + /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.Button, { __next40pxDefaultSize: true, variant: "primary", onClick: handleUpdate, disabled: !fontFamiliesHasChanges, accessibleWhenDisabled: true, - children: (0, import_i18n15.__)("Update") + children: (0, import_i18n17.__)("Update") } ) ] }) @@ -13718,7 +14278,7 @@ function ConfirmDeleteDialog({ uninstallFontFamily, handleSetLibraryFontSelected }) { - const navigator2 = (0, import_components22.useNavigator)(); + const navigator2 = (0, import_components21.useNavigator)(); const handleConfirmUninstall = async () => { setNotice(null); setIsOpen(false); @@ -13728,30 +14288,30 @@ function ConfirmDeleteDialog({ handleSetLibraryFontSelected(void 0); setNotice({ type: "success", - message: (0, import_i18n15.__)("Font family uninstalled successfully.") + message: (0, import_i18n17.__)("Font family uninstalled successfully.") }); } catch (error) { setNotice({ type: "error", - message: (0, import_i18n15.__)("There was an error uninstalling the font family.") + error.message + message: (0, import_i18n17.__)("There was an error uninstalling the font family.") + error.message }); } }; const handleCancelUninstall = () => { setIsOpen(false); }; - return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)( - import_components22.__experimentalConfirmDialog, + return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + import_components21.__experimentalConfirmDialog, { isOpen, - cancelButtonText: (0, import_i18n15.__)("Cancel"), - confirmButtonText: (0, import_i18n15.__)("Delete"), + cancelButtonText: (0, import_i18n17.__)("Cancel"), + confirmButtonText: (0, import_i18n17.__)("Delete"), onCancel: handleCancelUninstall, onConfirm: handleConfirmUninstall, size: "medium", - children: font2 && (0, import_i18n15.sprintf)( + children: font2 && (0, import_i18n17.sprintf)( /* translators: %s: Name of the font. */ - (0, import_i18n15.__)( + (0, import_i18n17.__)( 'Are you sure you want to delete "%s" font and all its variants and assets?' ), font2.name @@ -13762,10 +14322,10 @@ function ConfirmDeleteDialog({ var installed_fonts_default = InstalledFonts; // packages/global-styles-ui/build-module/font-library/font-collection.mjs -var import_element35 = __toESM(require_element(), 1); -var import_components25 = __toESM(require_components(), 1); +var import_element37 = __toESM(require_element(), 1); +var import_components24 = __toESM(require_components(), 1); var import_compose3 = __toESM(require_compose(), 1); -var import_i18n17 = __toESM(require_i18n(), 1); +var import_i18n19 = __toESM(require_i18n(), 1); var import_core_data7 = __toESM(require_core_data(), 1); // packages/global-styles-ui/build-module/font-library/utils/filter-fonts.mjs @@ -13809,9 +14369,9 @@ function isFontFontFaceInOutline(slug, face, outline) { } // packages/global-styles-ui/build-module/font-library/google-fonts-confirm-dialog.mjs -var import_i18n16 = __toESM(require_i18n(), 1); -var import_components23 = __toESM(require_components(), 1); -var import_jsx_runtime52 = __toESM(require_jsx_runtime(), 1); +var import_i18n18 = __toESM(require_i18n(), 1); +var import_components22 = __toESM(require_components(), 1); +var import_jsx_runtime54 = __toESM(require_jsx_runtime(), 1); function GoogleFontsConfirmDialog() { const handleConfirm = () => { window.localStorage.setItem( @@ -13820,24 +14380,24 @@ function GoogleFontsConfirmDialog() { ); window.dispatchEvent(new Event("storage")); }; - return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "font-library__google-fonts-confirm", children: /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.Card, { children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(import_components23.CardBody, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.__experimentalHeading, { level: 2, children: (0, import_i18n16.__)("Connect to Google Fonts") }), - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.__experimentalSpacer, { margin: 6 }), - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.__experimentalText, { as: "p", children: (0, import_i18n16.__)( + return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "font-library__google-fonts-confirm", children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.Card, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components22.CardBody, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.__experimentalHeading, { level: 2, children: (0, import_i18n18.__)("Connect to Google Fonts") }), + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.__experimentalSpacer, { margin: 6 }), + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.__experimentalText, { as: "p", children: (0, import_i18n18.__)( "To install fonts from Google you must give permission to connect directly to Google servers. The fonts you install will be downloaded from Google and stored on your site. Your site will then use these locally-hosted fonts." ) }), - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.__experimentalSpacer, { margin: 3 }), - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.__experimentalText, { as: "p", children: (0, import_i18n16.__)( + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.__experimentalSpacer, { margin: 3 }), + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.__experimentalText, { as: "p", children: (0, import_i18n18.__)( "You can alternatively upload files directly on the Upload tab." ) }), - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(import_components23.__experimentalSpacer, { margin: 6 }), - /* @__PURE__ */ (0, import_jsx_runtime52.jsx)( - import_components23.Button, + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components22.__experimentalSpacer, { margin: 6 }), + /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + import_components22.Button, { __next40pxDefaultSize: true, variant: "primary", onClick: handleConfirm, - children: (0, import_i18n16.__)("Allow access to Google Fonts") + children: (0, import_i18n18.__)("Allow access to Google Fonts") } ) ] }) }) }); @@ -13845,9 +14405,9 @@ function GoogleFontsConfirmDialog() { var google_fonts_confirm_dialog_default = GoogleFontsConfirmDialog; // packages/global-styles-ui/build-module/font-library/collection-font-variant.mjs -var import_element34 = __toESM(require_element(), 1); -var import_components24 = __toESM(require_components(), 1); -var import_jsx_runtime53 = __toESM(require_jsx_runtime(), 1); +var import_element36 = __toESM(require_element(), 1); +var import_components23 = __toESM(require_components(), 1); +var import_jsx_runtime55 = __toESM(require_jsx_runtime(), 1); function CollectionFontVariant({ face, font: font2, @@ -13862,17 +14422,17 @@ function CollectionFontVariant({ handleToggleVariant(font2); }; const displayName = font2.name + " " + getFontFaceVariantName(face); - const checkboxId = (0, import_element34.useId)(); - return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "font-library__font-card", children: /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_components24.Flex, { justify: "flex-start", align: "center", gap: "1rem", children: [ - /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( - import_components24.CheckboxControl, + const checkboxId = (0, import_element36.useId)(); + return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "font-library__font-card", children: /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_components23.Flex, { justify: "flex-start", align: "center", gap: "1rem", children: [ + /* @__PURE__ */ (0, import_jsx_runtime55.jsx)( + import_components23.CheckboxControl, { checked: selected, onChange: handleToggleActivation, id: checkboxId } ), - /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("label", { htmlFor: checkboxId, children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("label", { htmlFor: checkboxId, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)( font_demo_default, { font: face, @@ -13885,10 +14445,10 @@ function CollectionFontVariant({ var collection_font_variant_default = CollectionFontVariant; // packages/global-styles-ui/build-module/font-library/font-collection.mjs -var import_jsx_runtime54 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime56 = __toESM(require_jsx_runtime(), 1); var DEFAULT_CATEGORY = { slug: "all", - name: (0, import_i18n17._x)("All", "font categories") + name: (0, import_i18n19._x)("All", "font categories") }; var LOCAL_STORAGE_ITEM = "wp-font-library-google-fonts-permission"; var MIN_WINDOW_HEIGHT = 500; @@ -13897,22 +14457,22 @@ function FontCollection({ slug }) { const getGoogleFontsPermissionFromStorage = () => { return window.localStorage.getItem(LOCAL_STORAGE_ITEM) === "true"; }; - const [selectedFont, setSelectedFont] = (0, import_element35.useState)( + const [selectedFont, setSelectedFont] = (0, import_element37.useState)( null ); - const [lastSelectedFontSlug, setLastSelectedFontSlug] = (0, import_element35.useState)(void 0); - const [notice, setNotice] = (0, import_element35.useState)(null); - const [fontsToInstall, setFontsToInstall] = (0, import_element35.useState)( + const [lastSelectedFontSlug, setLastSelectedFontSlug] = (0, import_element37.useState)(void 0); + const [notice, setNotice] = (0, import_element37.useState)(null); + const [fontsToInstall, setFontsToInstall] = (0, import_element37.useState)( [] ); - const [page, setPage] = (0, import_element35.useState)(1); - const [filters, setFilters] = (0, import_element35.useState)({}); - const [renderConfirmDialog, setRenderConfirmDialog] = (0, import_element35.useState)( + const [page, setPage] = (0, import_element37.useState)(1); + const [filters, setFilters] = (0, import_element37.useState)({}); + const [renderConfirmDialog, setRenderConfirmDialog] = (0, import_element37.useState)( requiresPermission && !getGoogleFontsPermissionFromStorage() ); - const { installFonts, isInstalling } = (0, import_element35.useContext)(FontLibraryContext); + const { installFonts, isInstalling } = (0, import_element37.useContext)(FontLibraryContext); const { record: selectedCollection, isResolving: isLoading } = (0, import_core_data7.useEntityRecord)("root", "fontCollection", slug); - (0, import_element35.useEffect)(() => { + (0, import_element37.useEffect)(() => { const handleStorage = () => { setRenderConfirmDialog( requiresPermission && !getGoogleFontsPermissionFromStorage() @@ -13926,19 +14486,19 @@ function FontCollection({ slug }) { window.localStorage.setItem(LOCAL_STORAGE_ITEM, "false"); window.dispatchEvent(new Event("storage")); }; - (0, import_element35.useEffect)(() => { + (0, import_element37.useEffect)(() => { setSelectedFont(null); }, [slug]); - (0, import_element35.useEffect)(() => { + (0, import_element37.useEffect)(() => { setFontsToInstall([]); }, [selectedFont]); - const collectionFonts = (0, import_element35.useMemo)( + const collectionFonts = (0, import_element37.useMemo)( () => selectedCollection?.font_families ?? [], [selectedCollection] ); const collectionCategories = selectedCollection?.categories ?? []; const categories = [DEFAULT_CATEGORY, ...collectionCategories]; - const fonts = (0, import_element35.useMemo)( + const fonts = (0, import_element37.useMemo)( () => filterFonts(collectionFonts, filters), [collectionFonts, filters] ); @@ -13997,7 +14557,7 @@ function FontCollection({ slug }) { } catch { setNotice({ type: "error", - message: (0, import_i18n17.__)( + message: (0, import_i18n19.__)( "Error installing the fonts, could not be downloaded." ) }); @@ -14007,7 +14567,7 @@ function FontCollection({ slug }) { await installFonts([fontFamily]); setNotice({ type: "success", - message: (0, import_i18n17.__)("Fonts were installed successfully.") + message: (0, import_i18n19.__)("Fonts were installed successfully.") }); } catch (error) { setNotice({ @@ -14033,35 +14593,35 @@ function FontCollection({ slug }) { return sortFontFaces(fontFamily.fontFace); }; if (renderConfirmDialog) { - return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(google_fonts_confirm_dialog_default, {}); + return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(google_fonts_confirm_dialog_default, {}); } const showActions = slug === "google-fonts" && !renderConfirmDialog && !selectedFont; - return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "font-library__tabpanel-layout", children: [ - isLoading && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "font-library__loading", children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.ProgressBar, {}) }), - !isLoading && selectedCollection && /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)( - import_components25.Navigator, + return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { className: "font-library__tabpanel-layout", children: [ + isLoading && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "font-library__loading", children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.ProgressBar, {}) }), + !isLoading && selectedCollection && /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_jsx_runtime56.Fragment, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)( + import_components24.Navigator, { initialPath: "/", className: "font-library__tabpanel-layout", children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.Navigator.Screen, { path: "/", children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.__experimentalHStack, { justify: "space-between", children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.__experimentalVStack, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalHeading, { level: 2, size: 13, children: selectedCollection.name }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalText, { children: selectedCollection.description }) + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.Navigator.Screen, { path: "/", children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.__experimentalHStack, { justify: "space-between", children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.__experimentalVStack, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalHeading, { level: 2, size: 13, children: selectedCollection.name }), + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalText, { children: selectedCollection.description }) ] }), - showActions && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.DropdownMenu, + showActions && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.DropdownMenu, { icon: more_vertical_default, - label: (0, import_i18n17.__)("Actions"), + label: (0, import_i18n19.__)("Actions"), popoverProps: { position: "bottom left" }, controls: [ { - title: (0, import_i18n17.__)( + title: (0, import_i18n19.__)( "Revoke access to Google Fonts" ), onClick: revokeAccess @@ -14070,26 +14630,26 @@ function FontCollection({ slug }) { } ) ] }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 4 }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.__experimentalHStack, { spacing: 4, justify: "space-between", children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.SearchControl, + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 4 }), + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.__experimentalHStack, { spacing: 4, justify: "space-between", children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.SearchControl, { className: "font-library__search", value: filters.search, - placeholder: (0, import_i18n17.__)("Font name\u2026"), - label: (0, import_i18n17.__)("Search"), + placeholder: (0, import_i18n19.__)("Font name\u2026"), + label: (0, import_i18n19.__)("Search"), onChange: debouncedUpdateSearchInput, hideLabelFromVision: false } ), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.SelectControl, + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.SelectControl, { - label: (0, import_i18n17.__)("Category"), + label: (0, import_i18n19.__)("Category"), value: filters.category, onChange: handleCategoryFilter, - children: categories && categories.map((category) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + children: categories && categories.map((category) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( "option", { value: category.slug, @@ -14100,20 +14660,20 @@ function FontCollection({ slug }) { } ) ] }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 4 }), - !!selectedCollection?.font_families?.length && !fonts.length && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalText, { children: (0, import_i18n17.__)( + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 4 }), + !!selectedCollection?.font_families?.length && !fonts.length && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalText, { children: (0, import_i18n19.__)( "No fonts found. Try with a different search term." ) }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "font-library__fonts-grid__main", children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "font-library__fonts-grid__main", children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( "ul", { role: "list", className: "font-library__fonts-list", - children: items.map((font2) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + children: items.map((font2) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( "li", { className: "font-library__fonts-list-item", - children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( font_card_default, { font: font2.font_family_settings, @@ -14132,12 +14692,12 @@ function FontCollection({ slug }) { } ) }) ] }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.Navigator.Screen, { path: "/fontFamily", children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.Flex, { justify: "flex-start", children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.Navigator.BackButton, + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.Navigator.Screen, { path: "/fontFamily", children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.Flex, { justify: "flex-start", children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.Navigator.BackButton, { - icon: (0, import_i18n17.isRTL)() ? chevron_right_default : chevron_left_default, + icon: (0, import_i18n19.isRTL)() ? chevron_right_default : chevron_left_default, size: "small", onClick: () => { setLastSelectedFontSlug( @@ -14146,11 +14706,11 @@ function FontCollection({ slug }) { setSelectedFont(null); setNotice(null); }, - label: (0, import_i18n17.__)("Back") + label: (0, import_i18n19.__)("Back") } ), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.__experimentalHeading, + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.__experimentalHeading, { level: 2, size: 13, @@ -14159,42 +14719,42 @@ function FontCollection({ slug }) { } ) ] }), - notice && /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 1 }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.Notice, + notice && /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_jsx_runtime56.Fragment, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 1 }), + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.Notice, { status: notice.type, onRemove: () => setNotice(null), children: notice.message } ), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 1 }) + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 1 }) ] }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 4 }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalText, { children: (0, import_i18n17.__)("Select font variants to install.") }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 4 }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.CheckboxControl, + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 4 }), + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalText, { children: (0, import_i18n19.__)("Select font variants to install.") }), + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 4 }), + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.CheckboxControl, { className: "font-library__select-all", - label: (0, import_i18n17.__)("Select all"), + label: (0, import_i18n19.__)("Select all"), checked: isSelectAllChecked, onChange: toggleSelectAll, indeterminate: isIndeterminate } ), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalVStack, { spacing: 0, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalVStack, { spacing: 0, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( "ul", { role: "list", className: "font-library__fonts-list", children: selectedFont && getSortedFontFaces(selectedFont).map( - (face, i2) => /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + (face, i2) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( "li", { className: "font-library__fonts-list-item", - children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( + children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( collection_font_variant_default, { font: selectedFont, @@ -14214,18 +14774,18 @@ function FontCollection({ slug }) { ) } ) }), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_components25.__experimentalSpacer, { margin: 16 }) + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_components24.__experimentalSpacer, { margin: 16 }) ] }) ] } ), - selectedFont && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.Flex, + selectedFont && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.Flex, { justify: "flex-end", className: "font-library__footer", - children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.Button, + children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.Button, { __next40pxDefaultSize: true, variant: "primary", @@ -14233,30 +14793,30 @@ function FontCollection({ slug }) { isBusy: isInstalling, disabled: fontsToInstall.length === 0 || isInstalling, accessibleWhenDisabled: true, - children: (0, import_i18n17.__)("Install") + children: (0, import_i18n19.__)("Install") } ) } ), - !selectedFont && /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)( - import_components25.__experimentalHStack, + !selectedFont && /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)( + import_components24.__experimentalHStack, { expanded: false, className: "font-library__footer", justify: "end", spacing: 6, children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.__experimentalHStack, + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.__experimentalHStack, { justify: "flex-start", expanded: false, spacing: 1, className: "font-library__page-selection", - children: (0, import_element35.createInterpolateElement)( - (0, import_i18n17.sprintf)( + children: (0, import_element37.createInterpolateElement)( + (0, import_i18n19.sprintf)( // translators: 1: Current page number, 2: Total number of pages. - (0, import_i18n17._x)( + (0, import_i18n19._x)( "
    Page
    %1$s
    of %2$d
    ", "paging" ), @@ -14264,12 +14824,12 @@ function FontCollection({ slug }) { totalPages ), { - div: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { "aria-hidden": true }), + div: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { "aria-hidden": true }), // @ts-expect-error — Tag injected via sprintf argument, not visible in format string. - CurrentPage: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.SelectControl, + CurrentPage: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.SelectControl, { - "aria-label": (0, import_i18n17.__)( + "aria-label": (0, import_i18n19.__)( "Current page" ), value: page.toString(), @@ -14292,28 +14852,28 @@ function FontCollection({ slug }) { ) } ), - /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_components25.__experimentalHStack, { expanded: false, spacing: 1, children: [ - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.Button, + /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(import_components24.__experimentalHStack, { expanded: false, spacing: 1, children: [ + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.Button, { onClick: () => setPage(page - 1), disabled: page === 1, accessibleWhenDisabled: true, - label: (0, import_i18n17.__)("Previous page"), - icon: (0, import_i18n17.isRTL)() ? next_default : previous_default, + label: (0, import_i18n19.__)("Previous page"), + icon: (0, import_i18n19.isRTL)() ? next_default : previous_default, showTooltip: true, size: "compact", tooltipPosition: "top" } ), - /* @__PURE__ */ (0, import_jsx_runtime54.jsx)( - import_components25.Button, + /* @__PURE__ */ (0, import_jsx_runtime56.jsx)( + import_components24.Button, { onClick: () => setPage(page + 1), disabled: page === totalPages, accessibleWhenDisabled: true, - label: (0, import_i18n17.__)("Next page"), - icon: (0, import_i18n17.isRTL)() ? previous_default : next_default, + label: (0, import_i18n19.__)("Next page"), + icon: (0, import_i18n19.isRTL)() ? previous_default : next_default, showTooltip: true, size: "compact", tooltipPosition: "top" @@ -14329,9 +14889,9 @@ function FontCollection({ slug }) { var font_collection_default = FontCollection; // packages/global-styles-ui/build-module/font-library/upload-fonts.mjs -var import_i18n18 = __toESM(require_i18n(), 1); -var import_components26 = __toESM(require_components(), 1); -var import_element36 = __toESM(require_element(), 1); +var import_i18n20 = __toESM(require_i18n(), 1); +var import_components25 = __toESM(require_components(), 1); +var import_element38 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/font-library/lib/unbrotli.mjs var __require2 = /* @__PURE__ */ ((x2) => typeof __require !== "undefined" ? __require : typeof Proxy !== "undefined" ? new Proxy(x2, { @@ -18149,12 +18709,12 @@ var inflate_default = (function() { var STR_APPLY_UIA_OK = true; try { String.fromCharCode.apply(null, [0]); - } catch (__42) { + } catch (__45) { STR_APPLY_OK = false; } try { String.fromCharCode.apply(null, new Uint8Array(1)); - } catch (__42) { + } catch (__45) { STR_APPLY_UIA_OK = false; } var _utf8len = new utils.Buf8(256); @@ -24386,11 +24946,11 @@ function makeFamiliesFromFaces(fontFaces) { } // packages/global-styles-ui/build-module/font-library/upload-fonts.mjs -var import_jsx_runtime55 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime57 = __toESM(require_jsx_runtime(), 1); function UploadFonts() { - const { installFonts } = (0, import_element36.useContext)(FontLibraryContext); - const [isUploading, setIsUploading] = (0, import_element36.useState)(false); - const [notice, setNotice] = (0, import_element36.useState)(null); + const { installFonts } = (0, import_element38.useContext)(FontLibraryContext); + const [isUploading, setIsUploading] = (0, import_element38.useState)(false); + const [notice, setNotice] = (0, import_element38.useState)(null); const handleDropZone = (files) => { handleFilesUpload(files); }; @@ -24426,7 +24986,7 @@ function UploadFonts() { if (allowedFiles.length > 0) { loadFiles(allowedFiles); } else { - const message = hasInvalidFiles ? (0, import_i18n18.__)("Sorry, you are not allowed to upload this file type.") : (0, import_i18n18.__)("No fonts found to install."); + const message = hasInvalidFiles ? (0, import_i18n20.__)("Sorry, you are not allowed to upload this file type.") : (0, import_i18n20.__)("No fonts found to install."); setNotice({ type: "error", message @@ -24496,7 +25056,7 @@ function UploadFonts() { await installFonts(fontFamilies); setNotice({ type: "success", - message: (0, import_i18n18.__)("Fonts were installed successfully.") + message: (0, import_i18n20.__)("Fonts were installed successfully.") }); } catch (error) { const typedError = error; @@ -24508,42 +25068,42 @@ function UploadFonts() { } setIsUploading(false); }; - return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("div", { className: "font-library__tabpanel-layout", children: [ - /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components26.DropZone, { onFilesDrop: handleDropZone }), - /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(import_components26.__experimentalVStack, { className: "font-library__local-fonts", justify: "start", children: [ - notice && /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)( - import_components26.Notice, + return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "font-library__tabpanel-layout", children: [ + /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_components25.DropZone, { onFilesDrop: handleDropZone }), + /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(import_components25.__experimentalVStack, { className: "font-library__local-fonts", justify: "start", children: [ + notice && /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)( + import_components25.Notice, { status: notice.type, __unstableHTML: true, onRemove: () => setNotice(null), children: [ notice.message, - notice.errors && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("ul", { children: notice.errors.map((error, index2) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("li", { children: error }, index2)) }) + notice.errors && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("ul", { children: notice.errors.map((error, index2) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("li", { children: error }, index2)) }) ] } ), - isUploading && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components26.FlexItem, { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "font-library__upload-area", children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components26.ProgressBar, {}) }) }), - !isUploading && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)( - import_components26.FormFileUpload, + isUploading && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_components25.FlexItem, { children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: "font-library__upload-area", children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_components25.ProgressBar, {}) }) }), + !isUploading && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)( + import_components25.FormFileUpload, { accept: ALLOWED_FILE_EXTENSIONS.map( (ext) => `.${ext}` ).join(","), multiple: true, onChange: onFilesUpload, - render: ({ openFileDialog }) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)( - import_components26.Button, + render: ({ openFileDialog }) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)( + import_components25.Button, { __next40pxDefaultSize: true, className: "font-library__upload-area", onClick: openFileDialog, - children: (0, import_i18n18.__)("Upload font") + children: (0, import_i18n20.__)("Upload font") } ) } ), - /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(import_components26.__experimentalText, { className: "font-library__upload-area__text", children: (0, import_i18n18.__)( + /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_components25.__experimentalText, { className: "font-library__upload-area__text", children: (0, import_i18n20.__)( "Uploaded fonts appear in your library and can be used in your theme. Supported formats: .ttf, .otf, .woff, and .woff2." ) }) ] }) @@ -24552,114 +25112,131 @@ function UploadFonts() { var upload_fonts_default = UploadFonts; // packages/global-styles-ui/build-module/font-library/modal.mjs -var import_jsx_runtime56 = __toESM(require_jsx_runtime(), 1); -var { Tabs } = unlock3(import_components27.privateApis); +var import_jsx_runtime58 = __toESM(require_jsx_runtime(), 1); +var { Tabs } = unlock3(import_components26.privateApis); var DEFAULT_TAB = { id: "installed-fonts", - title: (0, import_i18n19._x)("Library", "Font library") + title: (0, import_i18n21._x)("Library", "Font library") }; var UPLOAD_TAB = { id: "upload-fonts", - title: (0, import_i18n19._x)("Upload", "noun") + title: (0, import_i18n21._x)("Upload", "noun") }; // packages/global-styles-ui/build-module/font-family-item.mjs -var import_i18n20 = __toESM(require_i18n(), 1); -var import_components28 = __toESM(require_components(), 1); -var import_element37 = __toESM(require_element(), 1); -var import_jsx_runtime57 = __toESM(require_jsx_runtime(), 1); +var import_i18n22 = __toESM(require_i18n(), 1); +var import_components27 = __toESM(require_components(), 1); +var import_element39 = __toESM(require_element(), 1); +var import_jsx_runtime59 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/font-families.mjs -var import_jsx_runtime58 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime60 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/font-sizes/font-sizes-count.mjs -var import_i18n22 = __toESM(require_i18n(), 1); -var import_components30 = __toESM(require_components(), 1); -var import_jsx_runtime59 = __toESM(require_jsx_runtime(), 1); +var import_i18n24 = __toESM(require_i18n(), 1); +var import_components29 = __toESM(require_components(), 1); +var import_jsx_runtime61 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-typography.mjs -var import_jsx_runtime60 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime62 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-typography-element.mjs -var import_i18n24 = __toESM(require_i18n(), 1); -var import_components32 = __toESM(require_components(), 1); -var import_element40 = __toESM(require_element(), 1); +var import_i18n26 = __toESM(require_i18n(), 1); +var import_components31 = __toESM(require_components(), 1); +var import_element42 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/typography-panel.mjs var import_block_editor6 = __toESM(require_block_editor(), 1); -var import_jsx_runtime61 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime63 = __toESM(require_jsx_runtime(), 1); var { useSettingsForBlockElement: useSettingsForBlockElement4, TypographyPanel: StylesTypographyPanel2 } = unlock3(import_block_editor6.privateApis); // packages/global-styles-ui/build-module/typography-preview.mjs -var import_jsx_runtime62 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime64 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-typography-element.mjs -var import_jsx_runtime63 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime65 = __toESM(require_jsx_runtime(), 1); var elements = { text: { - description: (0, import_i18n24.__)("Manage the fonts used on the site."), - title: (0, import_i18n24.__)("Text") + description: (0, import_i18n26.__)("Manage the fonts used on the site."), + title: (0, import_i18n26.__)("Text") }, link: { - description: (0, import_i18n24.__)("Manage the fonts and typography used on the links."), - title: (0, import_i18n24.__)("Links") + description: (0, import_i18n26.__)("Manage the fonts and typography used on the links."), + title: (0, import_i18n26.__)("Links") }, heading: { - description: (0, import_i18n24.__)("Manage the fonts and typography used on headings."), - title: (0, import_i18n24.__)("Headings") + description: (0, import_i18n26.__)("Manage the fonts and typography used on headings."), + title: (0, import_i18n26.__)("Headings") }, caption: { - description: (0, import_i18n24.__)("Manage the fonts and typography used on captions."), - title: (0, import_i18n24.__)("Captions") + description: (0, import_i18n26.__)("Manage the fonts and typography used on captions."), + title: (0, import_i18n26.__)("Captions") + }, + cite: { + description: (0, import_i18n26.__)("Manage the fonts and typography used on citations."), + title: (0, import_i18n26.__)("Citations") }, button: { - description: (0, import_i18n24.__)("Manage the fonts and typography used on buttons."), - title: (0, import_i18n24.__)("Buttons") + description: (0, import_i18n26.__)("Manage the fonts and typography used on buttons."), + title: (0, import_i18n26.__)("Buttons") + }, + textInput: { + description: (0, import_i18n26.__)("Manage the fonts and typography used on inputs."), + title: (0, import_i18n26.__)("Inputs") + }, + select: { + description: (0, import_i18n26.__)("Manage the fonts and typography used on selects."), + title: (0, import_i18n26.__)("Selects") } }; // packages/global-styles-ui/build-module/screen-colors.mjs -var import_i18n26 = __toESM(require_i18n(), 1); -var import_components35 = __toESM(require_components(), 1); +var import_i18n28 = __toESM(require_i18n(), 1); +var import_components34 = __toESM(require_components(), 1); var import_block_editor7 = __toESM(require_block_editor(), 1); // packages/global-styles-ui/build-module/palette.mjs -var import_components34 = __toESM(require_components(), 1); -var import_i18n25 = __toESM(require_i18n(), 1); -var import_element41 = __toESM(require_element(), 1); +var import_components33 = __toESM(require_components(), 1); +var import_i18n27 = __toESM(require_i18n(), 1); +var import_element43 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/color-indicator-wrapper.mjs -var import_components33 = __toESM(require_components(), 1); -var import_jsx_runtime64 = __toESM(require_jsx_runtime(), 1); +var import_components32 = __toESM(require_components(), 1); +var import_jsx_runtime66 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/palette.mjs -var import_jsx_runtime65 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime67 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-colors.mjs -var import_jsx_runtime66 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime68 = __toESM(require_jsx_runtime(), 1); var { useSettingsForBlockElement: useSettingsForBlockElement5, ColorPanel: StylesColorPanel2 } = unlock3( import_block_editor7.privateApis ); +var ADDITIONAL_ELEMENTS = [ + { name: "cite", label: (0, import_i18n28.__)("Citations") }, + { name: "textInput", label: (0, import_i18n28.__)("Inputs") }, + { name: "select", label: (0, import_i18n28.__)("Selects") } +]; // packages/global-styles-ui/build-module/screen-color-palette.mjs -var import_i18n29 = __toESM(require_i18n(), 1); +var import_i18n32 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/color-palette-panel.mjs var import_compose4 = __toESM(require_compose(), 1); -var import_components38 = __toESM(require_components(), 1); -var import_i18n27 = __toESM(require_i18n(), 1); +var import_components37 = __toESM(require_components(), 1); +var import_i18n29 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/variations/variations-color.mjs -var import_components37 = __toESM(require_components(), 1); +var import_components36 = __toESM(require_components(), 1); // packages/global-styles-ui/build-module/preview-colors.mjs -var import_components36 = __toESM(require_components(), 1); +var import_components35 = __toESM(require_components(), 1); // packages/global-styles-ui/build-module/preset-colors.mjs -var import_jsx_runtime67 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime69 = __toESM(require_jsx_runtime(), 1); function PresetColors() { const { paletteColors } = useStylesPreviewColors(); - return paletteColors.slice(0, 4).map(({ slug, color }, index2) => /* @__PURE__ */ (0, import_jsx_runtime67.jsx)( + return paletteColors.slice(0, 4).map(({ slug, color }, index2) => /* @__PURE__ */ (0, import_jsx_runtime69.jsx)( "div", { style: { @@ -24673,7 +25250,7 @@ function PresetColors() { } // packages/global-styles-ui/build-module/preview-colors.mjs -var import_jsx_runtime68 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime70 = __toESM(require_jsx_runtime(), 1); var firstFrameVariants2 = { start: { scale: 1, @@ -24689,22 +25266,22 @@ var StylesPreviewColors = ({ isFocused, withHoverView }) => { - return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime70.jsx)( preview_wrapper_default, { label, isFocused, withHoverView, - children: ({ key }) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)( - import_components36.__unstableMotion.div, + children: ({ key }) => /* @__PURE__ */ (0, import_jsx_runtime70.jsx)( + import_components35.__unstableMotion.div, { variants: firstFrameVariants2, style: { height: "100%", overflow: "hidden" }, - children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)( - import_components36.__experimentalHStack, + children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)( + import_components35.__experimentalHStack, { spacing: 0, justify: "center", @@ -24712,7 +25289,7 @@ var StylesPreviewColors = ({ height: "100%", overflow: "hidden" }, - children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(PresetColors, {}) + children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(PresetColors, {}) } ) }, @@ -24724,7 +25301,7 @@ var StylesPreviewColors = ({ var preview_colors_default = StylesPreviewColors; // packages/global-styles-ui/build-module/variations/variations-color.mjs -var import_jsx_runtime69 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime71 = __toESM(require_jsx_runtime(), 1); var propertiesToFilter2 = ["color"]; function ColorVariations({ title, @@ -24734,16 +25311,16 @@ function ColorVariations({ if (colorVariations?.length <= 1) { return null; } - return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_components37.__experimentalVStack, { spacing: 3, children: [ - title && /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Subtitle, { level: 3, children: title }), - /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_components37.__experimentalGrid, { gap, children: colorVariations.map((variation, index2) => /* @__PURE__ */ (0, import_jsx_runtime69.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime71.jsxs)(import_components36.__experimentalVStack, { spacing: 3, children: [ + title && /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(Subtitle, { level: 3, children: title }), + /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(import_components36.__experimentalGrid, { gap, children: colorVariations.map((variation, index2) => /* @__PURE__ */ (0, import_jsx_runtime71.jsx)( Variation, { variation, isPill: true, properties: propertiesToFilter2, showTooltip: true, - children: () => /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(preview_colors_default, {}) + children: () => /* @__PURE__ */ (0, import_jsx_runtime71.jsx)(preview_colors_default, {}) }, index2 )) }) @@ -24751,115 +25328,122 @@ function ColorVariations({ } // packages/global-styles-ui/build-module/color-palette-panel.mjs -var import_jsx_runtime70 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime72 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/gradients-palette-panel.mjs var import_compose5 = __toESM(require_compose(), 1); +var import_components38 = __toESM(require_components(), 1); +var import_i18n30 = __toESM(require_i18n(), 1); +var import_jsx_runtime73 = __toESM(require_jsx_runtime(), 1); + +// packages/global-styles-ui/build-module/duotone-palette-panel.mjs +var import_compose6 = __toESM(require_compose(), 1); +var import_element44 = __toESM(require_element(), 1); var import_components39 = __toESM(require_components(), 1); -var import_i18n28 = __toESM(require_i18n(), 1); -var import_jsx_runtime71 = __toESM(require_jsx_runtime(), 1); +var import_i18n31 = __toESM(require_i18n(), 1); +var import_jsx_runtime74 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-color-palette.mjs -var import_jsx_runtime72 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime75 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-background.mjs -var import_i18n30 = __toESM(require_i18n(), 1); +var import_i18n33 = __toESM(require_i18n(), 1); var import_block_editor9 = __toESM(require_block_editor(), 1); var import_components40 = __toESM(require_components(), 1); // packages/global-styles-ui/build-module/background-panel.mjs var import_block_editor8 = __toESM(require_block_editor(), 1); -var import_jsx_runtime73 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime76 = __toESM(require_jsx_runtime(), 1); var { BackgroundPanel: StylesBackgroundPanel2 } = unlock3( import_block_editor8.privateApis ); // packages/global-styles-ui/build-module/screen-background.mjs -var import_jsx_runtime74 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime77 = __toESM(require_jsx_runtime(), 1); var { useHasBackgroundPanel: useHasBackgroundPanel4 } = unlock3(import_block_editor9.privateApis); // packages/global-styles-ui/build-module/shadows-panel.mjs -var import_i18n33 = __toESM(require_i18n(), 1); +var import_i18n36 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/presets/preset-group.mjs var import_components42 = __toESM(require_components(), 1); -var import_i18n32 = __toESM(require_i18n(), 1); -var import_element42 = __toESM(require_element(), 1); +var import_i18n35 = __toESM(require_i18n(), 1); +var import_element45 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/presets/dialogs/confirm-reset-dialog.mjs var import_components41 = __toESM(require_components(), 1); -var import_i18n31 = __toESM(require_i18n(), 1); -var import_jsx_runtime75 = __toESM(require_jsx_runtime(), 1); +var import_i18n34 = __toESM(require_i18n(), 1); +var import_jsx_runtime78 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/presets/preset-group.mjs -var import_jsx_runtime76 = __toESM(require_jsx_runtime(), 1); -var { Menu } = unlock3(import_components42.privateApis); +var import_jsx_runtime79 = __toESM(require_jsx_runtime(), 1); +var { Menu: Menu2 } = unlock3(import_components42.privateApis); // packages/global-styles-ui/build-module/shadows-panel.mjs -var import_jsx_runtime77 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime80 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/shadows-edit-panel.mjs var import_components46 = __toESM(require_components(), 1); -var import_i18n36 = __toESM(require_i18n(), 1); -var import_element44 = __toESM(require_element(), 1); +var import_i18n39 = __toESM(require_i18n(), 1); +var import_element47 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/presets/preset-edit-header.mjs var import_components43 = __toESM(require_components(), 1); -var import_jsx_runtime78 = __toESM(require_jsx_runtime(), 1); -var { Menu: Menu2 } = unlock3(import_components43.privateApis); +var import_jsx_runtime81 = __toESM(require_jsx_runtime(), 1); +var { Menu: Menu3 } = unlock3(import_components43.privateApis); // packages/global-styles-ui/build-module/presets/dialogs/confirm-delete-dialog.mjs var import_components44 = __toESM(require_components(), 1); -var import_i18n34 = __toESM(require_i18n(), 1); -var import_jsx_runtime79 = __toESM(require_jsx_runtime(), 1); +var import_i18n37 = __toESM(require_i18n(), 1); +var import_jsx_runtime82 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/presets/dialogs/rename-dialog.mjs var import_components45 = __toESM(require_components(), 1); -var import_i18n35 = __toESM(require_i18n(), 1); -var import_element43 = __toESM(require_element(), 1); -var import_jsx_runtime80 = __toESM(require_jsx_runtime(), 1); +var import_i18n38 = __toESM(require_i18n(), 1); +var import_element46 = __toESM(require_element(), 1); +var import_jsx_runtime83 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/shadows-edit-panel.mjs -var import_jsx_runtime81 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime84 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-shadows.mjs -var import_jsx_runtime82 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime85 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-layout.mjs -var import_i18n37 = __toESM(require_i18n(), 1); +var import_i18n40 = __toESM(require_i18n(), 1); var import_block_editor11 = __toESM(require_block_editor(), 1); // packages/global-styles-ui/build-module/dimensions-panel.mjs var import_block_editor10 = __toESM(require_block_editor(), 1); -var import_element45 = __toESM(require_element(), 1); -var import_jsx_runtime83 = __toESM(require_jsx_runtime(), 1); +var import_element48 = __toESM(require_element(), 1); +var import_jsx_runtime86 = __toESM(require_jsx_runtime(), 1); var { useSettingsForBlockElement: useSettingsForBlockElement6, DimensionsPanel: StylesDimensionsPanel2 } = unlock3(import_block_editor10.privateApis); // packages/global-styles-ui/build-module/screen-layout.mjs -var import_jsx_runtime84 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime87 = __toESM(require_jsx_runtime(), 1); var { useHasDimensionsPanel: useHasDimensionsPanel4, useSettingsForBlockElement: useSettingsForBlockElement7 } = unlock3( import_block_editor11.privateApis ); // packages/global-styles-ui/build-module/screen-style-variations.mjs var import_components49 = __toESM(require_components(), 1); -var import_i18n40 = __toESM(require_i18n(), 1); +var import_i18n43 = __toESM(require_i18n(), 1); // packages/global-styles-ui/build-module/style-variations-content.mjs -var import_i18n39 = __toESM(require_i18n(), 1); +var import_i18n42 = __toESM(require_i18n(), 1); var import_components48 = __toESM(require_components(), 1); // packages/global-styles-ui/build-module/style-variations-container.mjs var import_core_data9 = __toESM(require_core_data(), 1); var import_data9 = __toESM(require_data(), 1); -var import_element46 = __toESM(require_element(), 1); +var import_element49 = __toESM(require_element(), 1); var import_components47 = __toESM(require_components(), 1); -var import_i18n38 = __toESM(require_i18n(), 1); -var import_jsx_runtime85 = __toESM(require_jsx_runtime(), 1); +var import_i18n41 = __toESM(require_i18n(), 1); +var import_jsx_runtime88 = __toESM(require_jsx_runtime(), 1); function StyleVariationsContainer({ gap = 2 }) { - const { user } = (0, import_element46.useContext)(GlobalStylesContext); + const { user } = (0, import_element49.useContext)(GlobalStylesContext); const userStyles = user?.styles; const variations = (0, import_data9.useSelect)((select) => { const result = select( @@ -24875,10 +25459,10 @@ function StyleVariationsContainer({ ]); } ); - const themeVariations = (0, import_element46.useMemo)(() => { + const themeVariations = (0, import_element49.useMemo)(() => { const withEmptyVariation = [ { - title: (0, import_i18n38.__)("Default"), + title: (0, import_i18n41.__)("Default"), settings: {}, styles: {} }, @@ -24921,14 +25505,14 @@ function StyleVariationsContainer({ if (!fullStyleVariations || fullStyleVariations.length < 1) { return null; } - return /* @__PURE__ */ (0, import_jsx_runtime85.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime88.jsx)( import_components47.__experimentalGrid, { columns: 2, className: "global-styles-ui-style-variations-container", gap, children: themeVariations.map( - (variation, index2) => /* @__PURE__ */ (0, import_jsx_runtime85.jsx)(Variation, { variation, children: (isFocused) => /* @__PURE__ */ (0, import_jsx_runtime85.jsx)( + (variation, index2) => /* @__PURE__ */ (0, import_jsx_runtime88.jsx)(Variation, { variation, children: (isFocused) => /* @__PURE__ */ (0, import_jsx_runtime88.jsx)( preview_styles_default, { label: variation?.title, @@ -24944,74 +25528,74 @@ function StyleVariationsContainer({ var style_variations_container_default = StyleVariationsContainer; // packages/global-styles-ui/build-module/style-variations-content.mjs -var import_jsx_runtime86 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime89 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-style-variations.mjs -var import_jsx_runtime87 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime90 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-css.mjs -var import_i18n41 = __toESM(require_i18n(), 1); +var import_i18n44 = __toESM(require_i18n(), 1); var import_components50 = __toESM(require_components(), 1); var import_block_editor12 = __toESM(require_block_editor(), 1); -var import_jsx_runtime88 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime91 = __toESM(require_jsx_runtime(), 1); var { AdvancedPanel: StylesAdvancedPanel2 } = unlock3(import_block_editor12.privateApis); // packages/global-styles-ui/build-module/screen-revisions/index.mjs -var import_i18n44 = __toESM(require_i18n(), 1); +var import_i18n47 = __toESM(require_i18n(), 1); var import_components53 = __toESM(require_components(), 1); -var import_element48 = __toESM(require_element(), 1); +var import_element51 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/screen-revisions/use-global-styles-revisions.mjs var import_data10 = __toESM(require_data(), 1); var import_core_data10 = __toESM(require_core_data(), 1); -var import_element47 = __toESM(require_element(), 1); +var import_element50 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/screen-revisions/revisions-buttons.mjs -var import_i18n42 = __toESM(require_i18n(), 1); +var import_i18n45 = __toESM(require_i18n(), 1); var import_components51 = __toESM(require_components(), 1); var import_date = __toESM(require_date(), 1); var import_core_data11 = __toESM(require_core_data(), 1); var import_data11 = __toESM(require_data(), 1); var import_keycodes2 = __toESM(require_keycodes(), 1); -var import_jsx_runtime89 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime92 = __toESM(require_jsx_runtime(), 1); var { Badge: WCBadge } = unlock3(import_components51.privateApis); var DAY_IN_MILLISECONDS = 60 * 60 * 1e3 * 24; // packages/global-styles-ui/build-module/pagination/index.mjs var import_components52 = __toESM(require_components(), 1); -var import_i18n43 = __toESM(require_i18n(), 1); -var import_jsx_runtime90 = __toESM(require_jsx_runtime(), 1); +var import_i18n46 = __toESM(require_i18n(), 1); +var import_jsx_runtime93 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/screen-revisions/index.mjs -var import_jsx_runtime91 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime94 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/font-sizes/font-sizes.mjs -var import_i18n45 = __toESM(require_i18n(), 1); +var import_i18n48 = __toESM(require_i18n(), 1); var import_components54 = __toESM(require_components(), 1); -var import_jsx_runtime92 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime95 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/font-sizes/font-size.mjs -var import_i18n47 = __toESM(require_i18n(), 1); +var import_i18n50 = __toESM(require_i18n(), 1); var import_components56 = __toESM(require_components(), 1); -var import_element49 = __toESM(require_element(), 1); +var import_element52 = __toESM(require_element(), 1); // packages/global-styles-ui/build-module/font-sizes/font-size-preview.mjs var import_block_editor13 = __toESM(require_block_editor(), 1); -var import_i18n46 = __toESM(require_i18n(), 1); -var import_jsx_runtime93 = __toESM(require_jsx_runtime(), 1); +var import_i18n49 = __toESM(require_i18n(), 1); +var import_jsx_runtime96 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/size-control/index.mjs var import_components55 = __toESM(require_components(), 1); -var import_jsx_runtime94 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime97 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/font-sizes/font-size.mjs -var import_jsx_runtime95 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime98 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/global-styles-ui.mjs -var import_jsx_runtime96 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime99 = __toESM(require_jsx_runtime(), 1); // packages/global-styles-ui/build-module/with-global-styles-provider.mjs -var import_jsx_runtime97 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime100 = __toESM(require_jsx_runtime(), 1); function withGlobalStylesProvider(Component) { return function WrappedComponent({ value, @@ -25019,13 +25603,13 @@ function withGlobalStylesProvider(Component) { onChange, ...props }) { - return /* @__PURE__ */ (0, import_jsx_runtime97.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime100.jsx)( GlobalStylesProvider, { value, baseValue, onChange, - children: /* @__PURE__ */ (0, import_jsx_runtime97.jsx)(Component, { ...props }) + children: /* @__PURE__ */ (0, import_jsx_runtime100.jsx)(Component, { ...props }) } ); }; @@ -25041,7 +25625,7 @@ var ColorVariations2 = withGlobalStylesProvider(ColorVariations); var TypographyVariations2 = withGlobalStylesProvider(TypographyVariations); // packages/global-styles-ui/build-module/font-library/font-library.mjs -var import_jsx_runtime98 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime101 = __toESM(require_jsx_runtime(), 1); function FontLibrary({ value, baseValue, @@ -25051,21 +25635,21 @@ function FontLibrary({ let content; switch (activeTab) { case "upload-fonts": - content = /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(upload_fonts_default, {}); + content = /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(upload_fonts_default, {}); break; case "installed-fonts": - content = /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(installed_fonts_default, {}); + content = /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(installed_fonts_default, {}); break; default: - content = /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(font_collection_default, { slug: activeTab }); + content = /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(font_collection_default, { slug: activeTab }); } - return /* @__PURE__ */ (0, import_jsx_runtime98.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime101.jsx)( GlobalStylesProvider, { value, baseValue, onChange, - children: /* @__PURE__ */ (0, import_jsx_runtime98.jsx)(context_default, { children: content }) + children: /* @__PURE__ */ (0, import_jsx_runtime101.jsx)(context_default, { children: content }) } ); } @@ -25078,21 +25662,22 @@ var { unlock: unlock4 } = (0, import_private_apis5.__dangerousOptInToUnstableAPI ); // routes/font-list/style.scss -if (typeof document !== "undefined" && true && !document.head.querySelector("style[data-wp-hash='9553e553cd']")) { +if (typeof document !== "undefined" && true && !document.head.querySelector("style[data-wp-hash='8316bac515']")) { const style = document.createElement("style"); - style.setAttribute("data-wp-hash", "9553e553cd"); - style.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid #ddd;bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-card{border:1px solid #ddd;box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid #ddd;position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid #ddd;height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid #ddd;bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-search{margin-bottom:10px;padding:0 16px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__remove-button.global-styles-ui__shadow-editor__remove-button{border:none}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;max-height:calc(100% - 110px);overflow:auto}.font-library-page:has(.font-library__footer) .font-library-page__tab-panel{max-height:calc(100% - 198px)}')); + style.setAttribute("data-wp-hash", "8316bac515"); + style.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-demo{position:relative}.font-library__font-card{border:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-image{transition:opacity var(--wpds-motion-duration-lg,.3s) var(--wpds-motion-easing-subtle,cubic-bezier(.15,0,.15,1))}}.font-library__font-card .font-library__font-variant_demo-image.is-loading{left:0;opacity:0;position:absolute;top:0}.font-library__font-card .font-library__font-variant-demo-skeleton{border-radius:var(--wpds-border-radius-sm,2px);height:24px}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-filter{margin-bottom:12px;padding:0 16px}.global-styles-ui-block-types-search{flex-grow:1}.global-styles-ui-block-types-item-list .global-styles-ui-block-types-item__icon{min-width:24px}.global-styles-ui-block-types-item-list__no-results{padding-top:16px}.global-styles-ui-block-types-item__indicator{background:var(--wp-admin-theme-color);border-radius:50%;flex:none;height:6px;margin-left:auto;width:6px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-duotone-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;max-height:calc(100% - 110px);overflow:auto}.font-library-page:has(.font-library__footer) .font-library-page__tab-panel{max-height:calc(100% - 198px)}')); document.head.appendChild(style); } // routes/font-list/stage.tsx +var import_jsx_runtime102 = __toESM(require_jsx_runtime()); var { Tabs: Tabs2 } = unlock4(import_components58.privateApis); var { useGlobalStyles } = unlock4(import_editor.privateApis); function FontLibraryPage() { const { records: collections = [] } = (0, import_core_data12.useEntityRecords)("root", "fontCollection", { _fields: "slug,name,description" }); - const [activeTab, setActiveTab] = (0, import_element51.useState)("installed-fonts"); + const [activeTab, setActiveTab] = (0, import_element54.useState)("installed-fonts"); const { base, user, setUser, isReady } = useGlobalStyles(); const canUserCreate = (0, import_data13.useSelect)((select) => { return select(import_core_data12.store).canUser("create", { @@ -25106,50 +25691,52 @@ function FontLibraryPage() { const tabs = [ { id: "installed-fonts", - title: (0, import_i18n48._x)("Library", "Font library") + title: (0, import_i18n51._x)("Library", "Font library") } ]; if (canUserCreate) { tabs.push({ id: "upload-fonts", - title: (0, import_i18n48._x)("Upload", "noun") + title: (0, import_i18n51._x)("Upload", "noun") }); tabs.push( ...(collections || []).map(({ slug, name: name2 }) => ({ id: slug, - title: collections && collections.length === 1 && slug === "google-fonts" ? (0, import_i18n48.__)("Install Fonts") : name2 + title: collections && collections.length === 1 && slug === "google-fonts" ? (0, import_i18n51.__)("Install Fonts") : name2 })) ); } - return /* @__PURE__ */ React.createElement(page_default, { title: (0, import_i18n48.__)("Fonts"), className: "font-library-page" }, /* @__PURE__ */ React.createElement( + return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(page_default, { title: (0, import_i18n51.__)("Fonts"), className: "font-library-page", children: /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)( Tabs2, { selectedTabId: activeTab, - onSelect: (tabId) => setActiveTab(tabId) - }, - /* @__PURE__ */ React.createElement("div", { className: "font-library-page__tablist" }, /* @__PURE__ */ React.createElement(Tabs2.TabList, null, tabs.map(({ id, title }) => /* @__PURE__ */ React.createElement(Tabs2.Tab, { key: id, tabId: id }, title)))), - tabs.map(({ id }) => /* @__PURE__ */ React.createElement( - Tabs2.TabPanel, - { - key: id, - tabId: id, - focusable: false, - className: "font-library-page__tab-panel" - }, - /* @__PURE__ */ React.createElement( - FontLibrary, - { - value: user, - baseValue: base, - onChange: setUser, - activeTab: id - } - ) - )) - )); + onSelect: (tabId) => setActiveTab(tabId), + children: [ + /* @__PURE__ */ (0, import_jsx_runtime102.jsx)("div", { className: "font-library-page__tablist", children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(Tabs2.TabList, { children: tabs.map(({ id, title }) => /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(Tabs2.Tab, { tabId: id, children: title }, id)) }) }), + tabs.map(({ id }) => /* @__PURE__ */ (0, import_jsx_runtime102.jsx)( + Tabs2.TabPanel, + { + tabId: id, + focusable: false, + className: "font-library-page__tab-panel", + children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)( + FontLibrary, + { + value: user, + baseValue: base, + onChange: setUser, + activeTab: id + } + ) + }, + id + )) + ] + } + ) }); } function Stage() { - return /* @__PURE__ */ React.createElement(FontLibraryPage, null); + return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(FontLibraryPage, {}); } var stage = Stage; export { diff --git a/src/wp-includes/build/routes/font-list/content.min.asset.php b/src/wp-includes/build/routes/font-list/content.min.asset.php index 93a78c7d9e473..a14c8d81d4ff1 100644 --- a/src/wp-includes/build/routes/font-list/content.min.asset.php +++ b/src/wp-includes/build/routes/font-list/content.min.asset.php @@ -1 +1 @@ - array('react', 'react-dom', 'react-jsx-runtime', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-date', 'wp-editor', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-private-apis', 'wp-style-engine', 'wp-theme'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '43d7c20a365e66da5be0'); \ No newline at end of file + array('react', 'react-dom', 'react-jsx-runtime', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-date', 'wp-editor', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-private-apis', 'wp-style-engine', 'wp-theme', 'wp-warning'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '104b97a0cdd454e16bdd'); \ No newline at end of file diff --git a/src/wp-includes/build/routes/font-list/content.min.js b/src/wp-includes/build/routes/font-list/content.min.js index 4b9b08be15c2d..9b907e95bf431 100644 --- a/src/wp-includes/build/routes/font-list/content.min.js +++ b/src/wp-includes/build/routes/font-list/content.min.js @@ -1,4 +1,4 @@ -var gv=Object.create;var Ra=Object.defineProperty;var yv=Object.getOwnPropertyDescriptor;var vv=Object.getOwnPropertyNames;var bv=Object.getPrototypeOf,wv=Object.prototype.hasOwnProperty;var zt=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var tt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),ro=(e,t)=>{for(var r in t)Ra(e,r,{get:t[r],enumerable:!0})},xv=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of vv(t))!wv.call(e,n)&&n!==r&&Ra(e,n,{get:()=>t[n],enumerable:!(o=yv(t,n))||o.enumerable});return e};var h=(e,t,r)=>(r=e!=null?gv(bv(e)):{},xv(t||!e||!e.__esModule?Ra(r,"default",{value:e,enumerable:!0}):r,e));var xe=tt((q2,Ou)=>{Ou.exports=window.wp.i18n});var ke=tt((X2,Fu)=>{Fu.exports=window.wp.element});var ge=tt((K2,Au)=>{Au.exports=window.React});var Y=tt((oT,Du)=>{Du.exports=window.ReactJSXRuntime});var io=tt((QT,af)=>{af.exports=window.ReactDOM});var md=tt(pd=>{"use strict";var ln=ge();function S0(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var C0=typeof Object.is=="function"?Object.is:S0,R0=ln.useState,E0=ln.useEffect,T0=ln.useLayoutEffect,_0=ln.useDebugValue;function P0(e,t){var r=t(),o=R0({inst:{value:r,getSnapshot:t}}),n=o[0].inst,s=o[1];return T0(function(){n.value=r,n.getSnapshot=t,ll(n)&&s({inst:n})},[e,r,t]),E0(function(){return ll(n)&&s({inst:n}),e(function(){ll(n)&&s({inst:n})})},[e]),_0(r),r}function ll(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!C0(e,r)}catch{return!0}}function O0(e,t){return t()}var k0=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?O0:P0;pd.useSyncExternalStore=ln.useSyncExternalStore!==void 0?ln.useSyncExternalStore:k0});var cl=tt((jP,hd)=>{"use strict";hd.exports=md()});var yd=tt(gd=>{"use strict";var Qs=ge(),F0=cl();function A0(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var I0=typeof Object.is=="function"?Object.is:A0,L0=F0.useSyncExternalStore,N0=Qs.useRef,D0=Qs.useEffect,M0=Qs.useMemo,V0=Qs.useDebugValue;gd.useSyncExternalStoreWithSelector=function(e,t,r,o,n){var s=N0(null);if(s.current===null){var i={hasValue:!1,value:null};s.current=i}else i=s.current;s=M0(function(){function u(g){if(!l){if(l=!0,c=g,g=o(g),n!==void 0&&i.hasValue){var d=i.value;if(n(d,g))return f=d}return f=g}if(d=f,I0(c,g))return d;var v=o(g);return n!==void 0&&n(d,v)?(c=g,d):(c=g,f=v)}var l=!1,c,f,m=r===void 0?null:r;return[function(){return u(t())},m===null?void 0:function(){return u(m())}]},[t,r,o,n]);var a=L0(e,s[0],s[1]);return D0(function(){i.hasValue=!0,i.value=a},[a]),V0(a),a}});var bd=tt((UP,vd)=>{"use strict";vd.exports=yd()});var bn=tt((oA,jp)=>{jp.exports=window.wp.primitives});var No=tt((nA,zp)=>{zp.exports=window.wp.compose});var Wp=tt((xA,Hp)=>{Hp.exports=window.wp.theme});var as=tt((SA,Gp)=>{Gp.exports=window.wp.privateApis});var ce=tt((T4,_m)=>{_m.exports=window.wp.components});var Dm=tt((V4,Nm)=>{Nm.exports=window.wp.editor});var nr=tt((B4,Mm)=>{Mm.exports=window.wp.coreData});var Xt=tt((j4,Vm)=>{Vm.exports=window.wp.data});var Sn=tt((z4,Bm)=>{Bm.exports=window.wp.blocks});var Dt=tt((U4,jm)=>{jm.exports=window.wp.blockEditor});var Um=tt((Z4,zm)=>{zm.exports=window.wp.styleEngine});var Xm=tt((i5,Zm)=>{"use strict";Zm.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var o,n,s;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;for(n of t.entries())if(!e(n[1],r.get(n[0])))return!1;return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(t[n]!==r[n])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(s=Object.keys(t),o=s.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,s[n]))return!1;for(n=o;n--!==0;){var i=s[n];if(!e(t[i],r[i]))return!1}return!0}return t!==t&&r!==r}});var $m=tt((l5,Qm)=>{"use strict";var i1=function(t){return a1(t)&&!l1(t)};function a1(e){return!!e&&typeof e=="object"}function l1(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||f1(e)}var c1=typeof Symbol=="function"&&Symbol.for,u1=c1?Symbol.for("react.element"):60103;function f1(e){return e.$$typeof===u1}function d1(e){return Array.isArray(e)?[]:{}}function ds(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Rn(d1(e),e,t):e}function p1(e,t,r){return e.concat(t).map(function(o){return ds(o,r)})}function m1(e,t){if(!t.customMerge)return Rn;var r=t.customMerge(e);return typeof r=="function"?r:Rn}function h1(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function Km(e){return Object.keys(e).concat(h1(e))}function Jm(e,t){try{return t in e}catch{return!1}}function g1(e,t){return Jm(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function y1(e,t,r){var o={};return r.isMergeableObject(e)&&Km(e).forEach(function(n){o[n]=ds(e[n],r)}),Km(t).forEach(function(n){g1(e,n)||(Jm(e,n)&&r.isMergeableObject(t[n])?o[n]=m1(n,r)(e[n],t[n],r):o[n]=ds(t[n],r))}),o}function Rn(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||p1,r.isMergeableObject=r.isMergeableObject||i1,r.cloneUnlessOtherwiseSpecified=ds;var o=Array.isArray(t),n=Array.isArray(e),s=o===n;return s?o?r.arrayMerge(e,t,r):y1(e,t,r):ds(t,r)}Rn.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(o,n){return Rn(o,n,r)},{})};var v1=Rn;Qm.exports=v1});var jc=tt((QL,ug)=>{ug.exports=window.wp.keycodes});var mg=tt((uN,pg)=>{pg.exports=window.wp.apiFetch});var Xy=tt((Qz,Zy)=>{Zy.exports=window.wp.date});function ku(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;te();function Te(e){let t=Rt(Ev).current;return t.next=e,Rv(t.effect),t.trampoline}function Ev(){let e={next:void 0,callback:Tv,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function Tv(){}var Nu=h(ge(),1),_v=()=>{},ye=typeof document<"u"?Nu.useLayoutEffect:_v;var ks=h(ge(),1),Ta=ks.createContext(void 0);function Qo(){return ks.useContext(Ta)?.direction??"ltr"}function Pv(e,t){return function(o,...n){let s=new URL(e);return s.searchParams.set("code",o.toString()),n.forEach(i=>s.searchParams.append("args[]",i)),`${t} error #${o}; visit ${s} for the full message.`}}var Ov=Pv("https://base-ui.com/production-error","Base UI"),Ut=Ov;var Eo=h(ge(),1);function _a(e,t,r,o){let n=Rt(Vu).current;return kv(n,e,t,r,o)&&Bu(n,[e,t,r,o]),n.callback}function Mu(e){let t=Rt(Vu).current;return Fv(t,e)&&Bu(t,e),t.callback}function Vu(){return{callback:null,cleanup:null,refs:[]}}function kv(e,t,r,o,n){return e.refs[0]!==t||e.refs[1]!==r||e.refs[2]!==o||e.refs[3]!==n}function Fv(e,t){return e.refs.length!==t.length||e.refs.some((r,o)=>r!==t[o])}function Bu(e,t){if(e.refs=t,t.every(r=>r==null)){e.callback=null;return}e.callback=r=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),r!=null){let o=Array(t.length).fill(null);for(let n=0;n{for(let n=0;n=e}function Pa(e){if(!zu.isValidElement(e))return null;let t=e,r=t.props;return($o(19)?r?.ref:t.ref)??null}function Gn(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function oo(){}var dT=Object.freeze([]),pt=Object.freeze({});function Uu(e,t){let r={};for(let o in e){let n=e[o];if(t?.hasOwnProperty(o)){let s=t[o](n);s!=null&&Object.assign(r,s);continue}n===!0?r[`data-${o.toLowerCase()}`]="":n&&(r[`data-${o.toLowerCase()}`]=n.toString())}return r}function Hu(e,t){return typeof e=="function"?e(t):e}function Wu(e,t){return typeof e=="function"?e(t):e}var Oa={};function er(e,t,r,o,n){if(!r&&!o&&!n&&!e)return Fs(t);let s=Fs(e);return t&&(s=Yn(s,t)),r&&(s=Yn(s,r)),o&&(s=Yn(s,o)),n&&(s=Yn(s,n)),s}function Gu(e){if(e.length===0)return Oa;if(e.length===1)return Fs(e[0]);let t=Fs(e[0]);for(let r=1;r=65&&n<=90&&(typeof t=="function"||typeof t>"u")}function ka(e){return typeof e=="function"}function qu(e,t){return ka(e)?e(t):e??Oa}function Nv(e,t){return t?e?(...r)=>{let o=r[0];if(Ku(o)){let s=o;Xu(s);let i=t(...r);return s.baseUIHandlerPrevented||e?.(...r),i}let n=t(...r);return e?.(...r),n}:Zu(t):e}function Zu(e){return e&&((...t)=>{let r=t[0];return Ku(r)&&Xu(r),e(...t)})}function Xu(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Fa(e,t){return t?e?t+" "+e:t:e}function Ku(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var Aa=h(ge(),1);function Ht(e,t,r={}){let o=t.render,n=Dv(t,r);if(r.enabled===!1)return null;let s=r.state??pt;return Bv(e,o,n,s)}function Dv(e,t={}){let{className:r,style:o,render:n}=e,{state:s=pt,ref:i,props:a,stateAttributesMapping:u,enabled:l=!0}=t,c=l?Hu(r,s):void 0,f=l?Wu(o,s):void 0,m=l?Uu(s,u):pt,g=l&&a?Mv(a):void 0,d=l?Gn(m,g)??{}:pt;return typeof document<"u"&&(l?Array.isArray(i)?d.ref=Mu([d.ref,Pa(n),...i]):d.ref=_a(d.ref,Pa(n),i):_a(null,null)),l?(c!==void 0&&(d.className=Fa(d.className,c)),f!==void 0&&(d.style=Gn(d.style,f)),d):pt}function Mv(e){return Array.isArray(e)?Gu(e):er(void 0,e)}var Vv=Symbol.for("react.lazy");function Bv(e,t,r,o){if(t){if(typeof t=="function")return t(r,o);let n=er(r,t.props);n.ref=r.ref;let s=t;return s?.$$typeof===Vv&&(s=Eo.Children.toArray(t)[0]),Eo.cloneElement(s,n)}if(e&&typeof e=="string")return jv(e,r);throw new Error(Ut(8))}function jv(e,t){return e==="button"?(0,Aa.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,Aa.createElement)("img",{alt:"",...t,key:t.key}):Eo.createElement(e,t)}var As=h(ge(),1);var Ju=0;function zv(e,t="mui"){let[r,o]=As.useState(e),n=e||r;return As.useEffect(()=>{r==null&&(Ju+=1,o(`${t}-${Ju}`))},[r,t]),n}var Qu=Wn.useId;function no(e,t){if(Qu!==void 0){let r=Qu();return e??(t?`${t}-${r}`:r)}return zv(e,t)}function $u(e){return no(e,"base-ui")}var _e={};ro(_e,{cancelOpen:()=>hb,chipRemovePress:()=>Jv,clearPress:()=>Kv,closePress:()=>Zv,closeWatcher:()=>lb,decrementPress:()=>eb,disabled:()=>yb,drag:()=>db,escapeKey:()=>ab,focusOut:()=>ib,imperativeAction:()=>wb,incrementPress:()=>$v,initial:()=>bb,inputBlur:()=>ob,inputChange:()=>tb,inputClear:()=>rb,inputPaste:()=>nb,inputPress:()=>sb,itemPress:()=>qv,keyboard:()=>ub,linkPress:()=>Xv,listNavigation:()=>cb,missing:()=>vb,none:()=>Uv,outsidePress:()=>Yv,pointer:()=>fb,scrub:()=>mb,siblingOpen:()=>gb,swipe:()=>xb,trackPress:()=>Qv,triggerFocus:()=>Gv,triggerHover:()=>Wv,triggerPress:()=>Hv,wheel:()=>pb,windowResize:()=>Sb});var Uv="none",Hv="trigger-press",Wv="trigger-hover",Gv="trigger-focus",Yv="outside-press",qv="item-press",Zv="close-press",Xv="link-press",Kv="clear-press",Jv="chip-remove-press",Qv="track-press",$v="increment-press",eb="decrement-press",tb="input-change",rb="input-clear",ob="input-blur",nb="input-paste",sb="input-press",ib="focus-out",ab="escape-key",lb="close-watcher",cb="list-navigation",ub="keyboard",fb="pointer",db="drag",pb="wheel",mb="scrub",hb="cancel-open",gb="sibling-open",yb="disabled",vb="missing",bb="initial",wb="imperative-action",xb="swipe",Sb="window-resize";function je(e,t,r,o){let n=!1,s=!1,i=o??pt;return{reason:e,event:t??new Event("base-ui"),cancel(){n=!0},allowPropagation(){s=!0},get isCanceled(){return n},get isPropagationAllowed(){return s},trigger:r,...i}}var La=h(ge(),1);var ef=h(ge(),1),Cb=[];function en(e){ef.useEffect(e,Cb)}var Is=null,BT=globalThis.requestAnimationFrame,Ia=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let r=this.callbacks,o=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,o>0)for(let n=0;n=this.callbacks.length||(this.callbacks[r]=null,this.callbacksCount-=1)}},Ls=new Ia,Er=class e{static create(){return new e}static request(t){return Ls.request(t)}static cancel(t){return Ls.cancel(t)}currentId=Is;request(t){this.cancel(),this.currentId=Ls.request(()=>{this.currentId=Is,t()})}cancel=()=>{this.currentId!==Is&&(Ls.cancel(this.currentId),this.currentId=Is)};disposeEffect=()=>this.cancel};function tn(){let e=Rt(Er.create).current;return en(e.disposeEffect),e}function tf(e,t=!1,r=!1){let[o,n]=La.useState(e&&t?"idle":void 0),[s,i]=La.useState(e);return e&&!s&&(i(!0),n("starting")),!e&&s&&o!=="ending"&&!r&&n("ending"),!e&&!s&&o==="ending"&&n(void 0),ye(()=>{if(!e&&s&&o!=="ending"&&r){let a=Er.request(()=>{n("ending")});return()=>{Er.cancel(a)}}},[e,s,o,r]),ye(()=>{if(!e||t)return;let a=Er.request(()=>{n(void 0)});return()=>{Er.cancel(a)}},[t,e]),ye(()=>{if(!e||!t)return;e&&s&&o!=="idle"&&n("starting");let a=Er.request(()=>{n("idle")});return()=>{Er.cancel(a)}},[t,e,s,o]),{mounted:s,setMounted:i,transitionStatus:o}}var To=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),Rb={[To.startingStyle]:""},Eb={[To.endingStyle]:""},rf={transitionStatus(e){return e==="starting"?Rb:e==="ending"?Eb:null}};function Ns(){return typeof window<"u"}function Po(e){return Ds(e)?(e.nodeName||"").toLowerCase():"#document"}function it(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function _r(e){var t;return(t=(Ds(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ds(e){return Ns()?e instanceof Node||e instanceof it(e).Node:!1}function Se(e){return Ns()?e instanceof Element||e instanceof it(e).Element:!1}function Et(e){return Ns()?e instanceof HTMLElement||e instanceof it(e).HTMLElement:!1}function rn(e){return!Ns()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof it(e).ShadowRoot}function qn(e){let{overflow:t,overflowX:r,overflowY:o,display:n}=Lt(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+r)&&n!=="inline"&&n!=="contents"}function of(e){return/^(table|td|th)$/.test(Po(e))}function Zn(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var Tb=/transform|translate|scale|rotate|perspective|filter/,_b=/paint|layout|strict|content/,_o=e=>!!e&&e!=="none",Na;function Ms(e){let t=Se(e)?Lt(e):e;return _o(t.transform)||_o(t.translate)||_o(t.scale)||_o(t.rotate)||_o(t.perspective)||!Vs()&&(_o(t.backdropFilter)||_o(t.filter))||Tb.test(t.willChange||"")||_b.test(t.contain||"")}function nf(e){let t=Tr(e);for(;Et(t)&&!Pr(t);){if(Ms(t))return t;if(Zn(t))return null;t=Tr(t)}return null}function Vs(){return Na==null&&(Na=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Na}function Pr(e){return/^(html|body|#document)$/.test(Po(e))}function Lt(e){return it(e).getComputedStyle(e)}function Xn(e){return Se(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Tr(e){if(Po(e)==="html")return e;let t=e.assignedSlot||e.parentNode||rn(e)&&e.host||_r(e);return rn(t)?t.host:t}function sf(e){let t=Tr(e);return Pr(t)?(e.ownerDocument||e).body:Et(t)&&qn(t)?t:sf(t)}function so(e,t,r){var o;t===void 0&&(t=[]),r===void 0&&(r=!0);let n=sf(e),s=n===((o=e.ownerDocument)==null?void 0:o.body),i=it(n);if(s){let a=Bs(i);return t.concat(i,i.visualViewport||[],qn(n)?n:[],a&&r?so(a):[])}else return t.concat(n,so(n,[],r))}function Bs(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ye(e,t,r,o){return e.addEventListener(t,r,o),()=>{e.removeEventListener(t,r,o)}}function Wt(e){let t=Rt(Pb,e).current;return t.next=e,ye(t.effect),t}function Pb(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}function xt(e){return e?.ownerDocument||document}var uf=h(ge(),1);var cf=h(io(),1);function lf(e){return e==null?e:"current"in e?e.current:e}function on(e,t=!1,r=!0){let o=tn();return Te((n,s=null)=>{o.cancel();let i=lf(e);if(i==null)return;let a=i,u=()=>{cf.flushSync(n)};if(typeof a.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){n();return}function l(){Promise.all(a.getAnimations().map(c=>c.finished)).then(()=>{s?.aborted||u()}).catch(()=>{if(r){s?.aborted||u();return}let c=a.getAnimations();!s?.aborted&&c.length>0&&c.some(f=>f.pending||f.playState!=="finished")&&l()})}if(t){let c=To.startingStyle;if(!a.hasAttribute(c)){o.request(l);return}let f=new MutationObserver(()=>{a.hasAttribute(c)||(f.disconnect(),l())});f.observe(a,{attributes:!0,attributeFilter:[c]}),s?.addEventListener("abort",()=>f.disconnect(),{once:!0});return}o.request(l)})}function js(e){let{enabled:t=!0,open:r,ref:o,onComplete:n}=e,s=Te(n),i=on(o,r,!1);uf.useEffect(()=>{if(!t)return;let a=new AbortController;return i(s,a.signal),()=>{a.abort()}},[t,r,s,i])}var ff=h(ge(),1);function df(e){let t=ff.useRef(!0);t.current&&(t.current=!1,e())}var Wr={};ro(Wr,{engine:()=>ja,env:()=>Ua,os:()=>Va,screenReader:()=>za});var Va={};ro(Va,{android:()=>hf,apple:()=>Ma,ios:()=>Da,linux:()=>Ib,mac:()=>gf,windows:()=>Ab});function Ob(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:kb,platform:Fb,maxTouchPoints:pf}=Ob(),Oo=kb.toLowerCase(),ko=Fb.toLowerCase();var Da=/^i(os$|p)/.test(ko)||ko==="macintel"&&pf>1,mf="android",hf=ko===mf||Oo.includes(mf),gf=!Da&&ko.startsWith("mac"),Ab=ko.startsWith("win"),Ib=!hf&&/^(linux|chrome os)/.test(ko),Ma=gf||Da;var ja={};ro(ja,{blink:()=>Nb,gecko:()=>Lb,webkit:()=>Ba});var Ba=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),Lb=!Ba&&Oo.includes("firefox"),Nb=!Ba&&Oo.includes("chrom");var za={};ro(za,{voiceOver:()=>Db});var Db=Ma;var Ua={};ro(Ua,{jsdom:()=>Mb});var Mb=/jsdom|happydom/.test(Oo);var Kn=0,tr=class e{static create(){return new e}currentId=Kn;start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Kn,r()},t)}isStarted(){return this.currentId!==Kn}clear=()=>{this.currentId!==Kn&&(clearTimeout(this.currentId),this.currentId=Kn)};disposeEffect=()=>this.clear};function vr(){let e=Rt(tr.create).current;return en(e.disposeEffect),e}var _t=h(ge(),1);function yf(e){return"nativeEvent"in e}function Gr(e,t){let r=["mouse","pen"];return t||r.push("",void 0),r.includes(e)}function vf(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var Ha="data-base-ui-focusable";var Wa="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function zs(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function Ze(e,t){if(!e||!t)return!1;let r=t.getRootNode?.();if(e.contains(t))return!0;if(r&&rn(r)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Nt(e){return"composedPath"in e?e.composedPath()[0]:e.target}function ao(e,t){if(!Se(e))return!1;let r=e;if(t.hasElement(r))return!r.hasAttribute("data-trigger-disabled");for(let[,o]of t.entries())if(Ze(o,r))return!o.hasAttribute("data-trigger-disabled");return!1}function Us(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let r=e;return r.target!=null&&t.contains(r.target)}function bf(e){return e.matches("html,body")}function wf(e){return Et(e)&&e.matches(Wa)}function Ga(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${Wa}`)!=null}function xf(e){if(!e||Wr.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function Vb(e,t){return t!=null&&!Gr(t)?0:typeof e=="function"?e():e}function Yr(e,t,r){let o=Vb(e,r);return typeof o=="number"?o:o?.[t]}function Ya(e){return typeof e=="function"?e():e}function Hs(e,t){return t||e==="click"||e==="mousedown"}function Sf(e){return e?.includes("mouse")&&e!=="mousedown"}var Cf=h(Y(),1),Rf=_t.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new tr,currentIdRef:{current:null},currentContextRef:{current:null}});function Bb(e,t){e.current=t.current}function qa(e){let{children:t,delay:r,timeoutMs:o=0}=e,n=_t.useRef(r),s=_t.useRef(r),i=_t.useRef(null),a=_t.useRef(null),u=vr();return ye(()=>{if(s.current=r,!i.current){n.current=r;return}n.current={open:Yr(n.current,"open"),close:Yr(r,"close")}},[r,i,n,s]),(0,Cf.jsx)(Rf.Provider,{value:_t.useMemo(()=>({hasProvider:!0,delayRef:n,initialDelayRef:s,currentIdRef:i,timeoutMs:o,currentContextRef:a,timeout:u}),[o,u]),children:t})}function Za(e,t={open:!1}){let{open:r}=t,o="rootStore"in e?e.rootStore:e,n=o.useState("floatingId"),s=_t.useContext(Rf),{currentIdRef:i,delayRef:a,timeoutMs:u,initialDelayRef:l,currentContextRef:c,hasProvider:f,timeout:m}=s,[g,d]=_t.useState(!1),v=_t.useRef(r),x=_t.useRef(!1);return ye(()=>{v.current=r},[r]),ye(()=>()=>{x.current=!0},[]),ye(()=>{function C(){x.current||d(!1),c.current?.setIsInstantPhase(!1),i.current=null,c.current=null,a.current=l.current,m.clear()}if(i.current&&!r&&i.current===n){if(d(!1),u){let w=n;return m.start(u,()=>{o.select("open")||i.current&&i.current!==w||C()}),()=>{(v.current||i.current!==w)&&m.clear()}}C()}},[r,n,i,a,u,l,c,m,o]),ye(()=>{if(!r)return;let C=c.current,w=i.current;m.clear(),c.current={onOpenChange:o.setOpen,setIsInstantPhase:d},i.current=n,a.current={open:0,close:Yr(l.current,"close")},w!==null&&w!==n?(d(!0),C?.setIsInstantPhase(!0),C?.onOpenChange(!1,je(_e.none))):(d(!1),C?.setIsInstantPhase(!1))},[r,n,o,i,a,l,c,m]),ye(()=>()=>{if(i.current===n){if(c.current=null,!v.current)return;i.current=null,Bb(a,l),m.clear()}},[c,i,a,n,l,m]),_t.useMemo(()=>({hasProvider:f,delayRef:a,isInstantPhase:g}),[f,a,g])}function br(...e){return()=>{for(let t=0;t({x:e,y:e}),jb={left:"right",right:"left",bottom:"top",top:"bottom"};function Gs(e,t,r){return wr(e,lo(t,r))}function xr(e,t){return typeof e=="function"?e(t):e}function Pt(e){return e.split("-")[0]}function Sr(e){return e.split("-")[1]}function Ys(e){return e==="x"?"y":"x"}function $n(e){return e==="y"?"height":"width"}function Gt(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function es(e){return Ys(Gt(e))}function Pf(e,t,r){r===void 0&&(r=!1);let o=Sr(e),n=es(e),s=$n(n),i=n==="x"?o===(r?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=Jn(i)),[i,Jn(i)]}function Of(e){let t=Jn(e);return[Ws(e),t,Ws(t)]}function Ws(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var Ef=["left","right"],Tf=["right","left"],zb=["top","bottom"],Ub=["bottom","top"];function Hb(e,t,r){switch(e){case"top":case"bottom":return r?t?Tf:Ef:t?Ef:Tf;case"left":case"right":return t?zb:Ub;default:return[]}}function kf(e,t,r,o){let n=Sr(e),s=Hb(Pt(e),r==="start",o);return n&&(s=s.map(i=>i+"-"+n),t&&(s=s.concat(s.map(Ws)))),s}function Jn(e){let t=Pt(e);return jb[t]+e.slice(t.length)}function Wb(e){var t,r,o,n;return{top:(t=e.top)!=null?t:0,right:(r=e.right)!=null?r:0,bottom:(o=e.bottom)!=null?o:0,left:(n=e.left)!=null?n:0}}function qs(e){return typeof e!="number"?Wb(e):{top:e,right:e,bottom:e,left:e}}function Fo(e){let{x:t,y:r,width:o,height:n}=e;return{width:o,height:n,top:r,left:t,right:t+o,bottom:r+n,x:t,y:r}}function qr(e,t,r=!0){return e.filter(n=>n.parentId===t).flatMap(n=>[...!r||n.context?.open?[n]:[],...qr(e,n.id,r)])}function nn(e){return`data-base-ui-${e}`}var rr=h(ge(),1),If=h(io(),1);var Ff={style:{transition:"none"}};var Gb="data-base-ui-swipe-ignore",Yb="data-swipe-ignore",j_=`[${Gb}]`,z_=`[${Yb}]`;var Af={fallbackAxisSide:"end"};var Lf=h(Y(),1),qb=rr.createContext(null),Zb=()=>rr.useContext(qb),Xb=nn("portal");function Xa(e={}){let{ref:t,container:r,componentProps:o=pt,elementProps:n}=e,s=no(),a=Zb()?.portalNode,[u,l]=rr.useState(null),[c,f]=rr.useState(null),m=Te(x=>{x!==null&&f(x)}),g=rr.useRef(null);ye(()=>{if(r===null){g.current&&(g.current=null,f(null),l(null));return}if(s==null)return;let x=(r&&(Ds(r)?r:r.current))??a??document.body;if(x==null){g.current&&(g.current=null,f(null),l(null));return}g.current!==x&&(g.current=x,f(null),l(x))},[r,a,s]);let d=Ht("div",o,{ref:[t,m],props:[{id:s,[Xb]:""},n]});return{portalNode:c,portalSubtree:u&&d?If.createPortal(d,u):null}}var Ao=h(ge(),1);function Nf(){let e=new Map;return{emit(t,r){e.get(t)?.forEach(o=>o(r))},on(t,r){e.has(t)||e.set(t,new Set),e.get(t).add(r)},off(t,r){e.get(t)?.delete(r)}}}var Kb=h(Y(),1),Jb=Ao.createContext(null),Qb=Ao.createContext(null),sn=()=>Ao.useContext(Jb)?.id||null,uo=e=>{let t=Ao.useContext(Qb);return e??t};var Yt=h(ge(),1);function $b(e,t){let r=null,o=null,n=!1;return{contextElement:e||void 0,getBoundingClientRect(){let s=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},i=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",u=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",l=s.width,c=s.height,f=s.x,m=s.y;return r==null&&t.x&&i&&(r=s.x-t.x),o==null&&t.y&&a&&(o=s.y-t.y),f-=r||0,m-=o||0,l=0,c=0,!n||u?(l=t.axis==="y"?s.width:0,c=t.axis==="x"?s.height:0,f=i&&t.x!=null?t.x:f,m=a&&t.y!=null?t.y:m):n&&!u&&(c=t.axis==="x"?s.height:c,l=t.axis==="y"?s.width:l),n=!0,{width:l,height:c,x:f,y:m,top:m,right:f+l,bottom:m+c,left:f}}}}function Df(e){return e!=null&&e.clientX!=null}function Ka(e,t={}){let{enabled:r=!0,axis:o="both"}=t,n="rootStore"in e?e.rootStore:e,s=n.useState("open"),i=n.useState("floatingElement"),a=n.useState("domReferenceElement"),u=n.context.dataRef,l=Yt.useRef(!1),c=Yt.useRef(null),[f,m]=Yt.useState(),[g,d]=Yt.useState([]),v=Te(R=>{n.set("positionReference",R)}),x=Te((R,A,T)=>{l.current||u.current.openEvent&&!Df(u.current.openEvent)||n.set("positionReference",$b(T??a,{x:R,y:A,axis:o,dataRef:u,pointerType:f}))}),C=Te(R=>{s?c.current||(x(R.clientX,R.clientY,R.currentTarget),d([])):x(R.clientX,R.clientY,R.currentTarget)}),w=Gr(f)?i:s;Yt.useEffect(()=>{if(!r){v(a);return}if(!w)return;function R(){c.current?.(),c.current=null}let A=it(i);function T(_){let P=Nt(_);Ze(i,P)?R():x(_.clientX,_.clientY)}return!u.current.openEvent||Df(u.current.openEvent)?c.current=Ye(A,"mousemove",T):v(a),R},[w,r,i,u,a,n,x,v,g]),Yt.useEffect(()=>()=>{n.set("positionReference",null)},[n]),Yt.useEffect(()=>{r&&!i&&(l.current=!1)},[r,i]),Yt.useEffect(()=>{!r&&s&&(l.current=!0)},[r,s]);let b=Yt.useMemo(()=>{function R(A){m(A.pointerType)}return{onPointerDown:R,onPointerEnter:R,onMouseMove:C,onMouseEnter:C}},[C]);return Yt.useMemo(()=>r?{reference:b,trigger:b}:{},[r,b])}var qt=h(ge(),1);function e0(){return!1}function t0(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function Ja(e,t={}){let{enabled:r=!0,escapeKey:o=!0,outsidePress:n=!0,outsidePressEvent:s="sloppy",referencePress:i=e0,bubbles:a,externalTree:u}=t,l="rootStore"in e?e.rootStore:e,c=l.useState("open"),f=l.useState("floatingElement"),{dataRef:m}=l.context,g=uo(u),d=Te(typeof n=="function"?n:()=>!1),v=typeof n=="function"?d:n,x=v!==!1,C=Te(()=>s),{escapeKey:w,outsidePress:b}=t0(a),R=qt.useRef(!1),A=qt.useRef(!1),T=qt.useRef(!1),_=qt.useRef(!1),P=qt.useRef(""),N=qt.useRef(null),q=vr(),H=vr(),S=Te(()=>{H.clear(),m.current.insideReactTree=!1}),I=Te(F=>{let Z=m.current.floatingContext?.nodeId;return(g?qr(g.nodesRef.current,Z):[]).some(we=>we.context?.open&&!we.context.dataRef.current[F])}),W=Te(F=>Us(F,l.select("floatingElement"))||Us(F,l.select("domReferenceElement"))),O=Te(F=>{i()&&l.setOpen(!1,je(_e.triggerPress,F.nativeEvent))}),D=Te(F=>{if(!c||!r||!o||F.key!=="Escape"||_.current||!w&&I("__escapeKeyBubbles"))return;let Z=yf(F)?F.nativeEvent:F,se=je(_e.escapeKey,Z);l.setOpen(!1,se),se.isCanceled||F.preventDefault(),!w&&!se.isPropagationAllowed&&F.stopPropagation()}),J=Te(()=>{m.current.insideReactTree=!0,H.start(0,S)}),M=Te(F=>{if(!c||!r||F.button!==0)return;let Z=Nt(F.nativeEvent);Ze(l.select("floatingElement"),Z)&&(R.current||(R.current=!0,A.current=!1))}),E=Te(F=>{!c||!r||(F.defaultPrevented||F.nativeEvent.defaultPrevented)&&R.current&&(A.current=!0)});qt.useEffect(()=>{if(!c||!r)return;m.current.__escapeKeyBubbles=w,m.current.__outsidePressBubbles=b;let F=new tr,Z=new tr;function se(){F.clear(),_.current=!0}function we(){F.start(Wr.engine.webkit?5:0,()=>{_.current=!1})}function ie(){T.current=!0,Z.start(0,()=>{T.current=!1})}function ve(){R.current=!1,A.current=!1}function Ee(){let V=P.current,re=V==="pen"||!V?"mouse":V,Ne=C(),He=typeof Ne=="function"?Ne():Ne;return typeof He=="string"?He:He[re]}function ee(V){let re=Ee();return re==="intentional"&&V.type!=="click"||re==="sloppy"&&V.type==="click"}function Fe(V){let re=m.current.floatingContext?.nodeId,Ne=g&&qr(g.nodesRef.current,re).some(He=>Us(V,He.context?.elements.floating));return W(V)||Ne}function Ae(V){if(ee(V)){V.type!=="click"&&!W(V)&&(Z.clear(),T.current=!1),S();return}if(m.current.insideReactTree){S();return}let re=Nt(V),Ne=`[${nn("inert")}]`,He=Se(re)?re.getRootNode():null,ot=Array.from((rn(He)?He:xt(l.select("floatingElement"))).querySelectorAll(Ne)),ut=l.context.triggerElements;if(re&&(ut.hasElement(re)||ut.hasMatchingElement(We=>Ze(We,re))))return;let ze=Se(re)?re:null;for(;ze&&!Pr(ze);){let We=Tr(ze);if(Pr(We)||!Se(We))break;ze=We}if(!(ot.length&&Se(re)&&!bf(re)&&!Ze(re,l.select("floatingElement"))&&ot.every(We=>!Ze(ze,We)))){if(Et(re)&&!("touches"in V)){let We=Pr(re),nt=Lt(re),be=/auto|scroll/,Rr=We||be.test(nt.overflowX),gr=We||be.test(nt.overflowY),$e=Rr&&re.clientWidth>0&&re.scrollWidth>re.clientWidth,jr=gr&&re.clientHeight>0&&re.scrollHeight>re.clientHeight,Ct=nt.direction==="rtl",Le=jr&&(Ct?V.offsetX<=re.offsetWidth-re.clientWidth:V.offsetX>re.clientWidth),qe=$e&&V.offsetY>re.clientHeight;if(Le||qe)return}if(!Fe(V)){if(Ee()==="intentional"&&T.current){Z.clear(),T.current=!1;return}typeof v=="function"&&!v(V)||I("__outsidePressBubbles")||(l.setOpen(!1,je(_e.outsidePress,V)),S())}}}function Oe(V){Ee()!=="sloppy"||V.pointerType==="touch"||!l.select("open")||!r||W(V)||Ae(V)}function Ue(V){if(Ee()!=="sloppy"||!l.select("open")||!r||W(V))return;let re=V.touches[0];re&&(N.current={startTime:Date.now(),startX:re.clientX,startY:re.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},q.start(1e3,()=>{N.current&&(N.current.dismissOnTouchEnd=!1,N.current.dismissOnMouseDown=!1)}))}function G(V,re){let Ne=Nt(V);if(!Ne)return;let He=Ye(Ne,V.type,()=>{re(V),He()})}function z(V){P.current="touch",G(V,Ue)}function X(V){q.clear(),V.type==="pointerdown"&&(P.current=V.pointerType),!(V.type==="mousedown"&&N.current&&!N.current.dismissOnMouseDown)&&G(V,re=>{re.type==="pointerdown"?Oe(re):Ae(re)})}function U(V){if(!R.current)return;let re=A.current;if(ve(),Ee()==="intentional"){if(V.type==="pointercancel"){re&&ie();return}if(!Fe(V)){if(re){ie();return}typeof v=="function"&&!v(V)||(Z.clear(),T.current=!0,S())}}}function K(V){if(Ee()!=="sloppy"||!N.current||W(V))return;let re=V.touches[0];if(!re)return;let Ne=Math.abs(re.clientX-N.current.startX),He=Math.abs(re.clientY-N.current.startY),ot=Math.sqrt(Ne*Ne+He*He);ot>5&&(N.current.dismissOnTouchEnd=!0),ot>10&&(Ae(V),q.clear(),N.current=null)}function fe(V){G(V,K)}function ue(V){Ee()!=="sloppy"||!N.current||W(V)||(N.current.dismissOnTouchEnd&&Ae(V),q.clear(),N.current=null)}function de(V){G(V,ue)}let pe=xt(f),me=br(o&&br(Ye(pe,"keydown",D),Ye(pe,"compositionstart",se),Ye(pe,"compositionend",we)),x&&br(Ye(pe,"click",X,!0),Ye(pe,"pointerdown",X,!0),Ye(pe,"pointerup",U,!0),Ye(pe,"pointercancel",U,!0),Ye(pe,"mousedown",X,!0),Ye(pe,"mouseup",U,!0),Ye(pe,"touchstart",z,!0),Ye(pe,"touchmove",fe,!0),Ye(pe,"touchend",de,!0)));return()=>{me(),F.clear(),Z.clear(),ve(),T.current=!1}},[m,f,o,x,v,c,r,w,b,D,S,C,I,W,g,l,q]),qt.useEffect(S,[v,S]);let L=qt.useMemo(()=>({onKeyDown:D,onPointerDown:O,onClick:O}),[D,O]),$=qt.useMemo(()=>({onKeyDown:D,onPointerDown:E,onMouseDown:E,onClickCapture:J,onMouseDownCapture(F){J(),M(F)},onPointerDownCapture(F){J(),M(F)},onMouseUpCapture:J,onTouchEndCapture:J,onTouchMoveCapture:J}),[D,J,M,E]);return qt.useMemo(()=>r?{reference:L,floating:$,trigger:L}:{},[r,L,$])}var Ot=h(ge(),1);function Mf(e,t,r){let{reference:o,floating:n}=e,s=Gt(t),i=es(t),a=$n(i),u=Pt(t),l=s==="y",c=o.x+o.width/2-n.width/2,f=o.y+o.height/2-n.height/2,m=o[a]/2-n[a]/2,g;switch(u){case"top":g={x:c,y:o.y-n.height};break;case"bottom":g={x:c,y:o.y+o.height};break;case"right":g={x:o.x+o.width,y:f};break;case"left":g={x:o.x-n.width,y:f};break;default:g={x:o.x,y:o.y}}let d=Sr(t);return d&&(g[i]+=m*(d==="end"?1:-1)*(r&&l?-1:1)),g}async function jf(e,t){var r;t===void 0&&(t={});let{x:o,y:n,platform:s,rects:i,elements:a,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:f="floating",altBoundary:m=!1,padding:g=0}=xr(t,e),d=qs(g),x=a[m?f==="floating"?"reference":"floating":f],C=Fo(await s.getClippingRect({element:(r=await(s.isElement==null?void 0:s.isElement(x)))==null||r?x:x.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:l,rootBoundary:c,strategy:u})),w=f==="floating"?{x:o,y:n,width:i.floating.width,height:i.floating.height}:i.reference,b=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),R=await(s.isElement==null?void 0:s.isElement(b))&&await(s.getScale==null?void 0:s.getScale(b))||{x:1,y:1},A=Fo(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:w,offsetParent:b,strategy:u}):w);return{top:(C.top-A.top+d.top)/R.y,bottom:(A.bottom-C.bottom+d.bottom)/R.y,left:(C.left-A.left+d.left)/R.x,right:(A.right-C.right+d.right)/R.x}}var r0=50,zf=async(e,t,r)=>{let{placement:o="bottom",strategy:n="absolute",middleware:s=[],platform:i}=r,a=i.detectOverflow?i:{...i,detectOverflow:jf},u=await(i.isRTL==null?void 0:i.isRTL(t)),l=await i.getElementRects({reference:e,floating:t,strategy:n}),{x:c,y:f}=Mf(l,o,u),m=o,g=0,d={};for(let v=0;vW<=0)){var H,S;let W=(((H=s.flip)==null?void 0:H.index)||0)+1,O=_[W];if(O&&(!(f==="alignment"?w!==Gt(O):!1)||q.every(M=>Gt(M.placement)===w?M.overflows[0]>0:!0)))return{data:{index:W,overflows:q},reset:{placement:O}};let D=(S=q.filter(J=>J.overflows[0]<=0).sort((J,M)=>J.overflows[1]-M.overflows[1])[0])==null?void 0:S.placement;if(!D)switch(g){case"bestFit":{var I;let J=(I=q.filter(M=>{if(T){let E=Gt(M.placement);return E===w||E==="y"}return!0}).map(M=>[M.placement,M.overflows.filter(E=>E>0).reduce((E,L)=>E+L,0)]).sort((M,E)=>M[1]-E[1])[0])==null?void 0:I[0];J&&(D=J);break}case"initialPlacement":D=a;break}if(n!==D)return{reset:{placement:D}}}return{}}}};function Vf(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Bf(e){return _f.some(t=>e[t]>=0)}var Hf=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){let{rects:r,platform:o}=t,{strategy:n="referenceHidden",...s}=xr(e,t);switch(n){case"referenceHidden":{let i=await o.detectOverflow(t,{...s,elementContext:"reference"}),a=Vf(i,r.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:Bf(a)}}}case"escaped":{let i=await o.detectOverflow(t,{...s,altBoundary:!0}),a=Vf(i,r.floating);return{data:{escapedOffsets:a,escaped:Bf(a)}}}default:return{}}}}};var Wf=new Set(["left","top"]);async function o0(e,t){let{placement:r,platform:o,elements:n}=e,s=await(o.isRTL==null?void 0:o.isRTL(n.floating)),i=Pt(r),a=Sr(r),u=Gt(r)==="y",l=Wf.has(i)?-1:1,c=s&&u?-1:1,f=xr(t,e),{mainAxis:m,crossAxis:g,alignmentAxis:d}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return a&&typeof d=="number"&&(g=a==="end"?d*-1:d),u?{x:g*c,y:m*l}:{x:m*l,y:g*c}}var Gf=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,o;let{x:n,y:s,placement:i,middlewareData:a}=t,u=await o0(t,e);return i===((r=a.offset)==null?void 0:r.placement)&&(o=a.arrow)!=null&&o.alignmentOffset?{}:{x:n+u.x,y:s+u.y,data:{...u,placement:i}}}}},Yf=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:r,y:o,placement:n,platform:s}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:u={fn:w=>{let{x:b,y:R}=w;return{x:b,y:R}}},...l}=xr(e,t),c={x:r,y:o},f=await s.detectOverflow(t,l),m=Gt(n),g=Ys(m),d=c[g],v=c[m],x=(w,b)=>Gs(b+f[w==="y"?"top":"left"],b,b-f[w==="y"?"bottom":"right"]);i&&(d=x(g,d)),a&&(v=x(m,v));let C=u.fn({...t,[g]:d,[m]:v});return{...C,data:{x:C.x-r,y:C.y-o,enabled:{[g]:i,[m]:a}}}}}},qf=function(e){return e===void 0&&(e={}),{options:e,fn(t){var r,o;let{x:n,y:s,placement:i,rects:a,middlewareData:u}=t,{offset:l=0,mainAxis:c=!0,crossAxis:f=!0}=xr(e,t),m={x:n,y:s},g=Gt(i),d=Ys(g),v=m[d],x=m[g],C=xr(l,t),w=typeof C=="number"?{mainAxis:C,crossAxis:0}:{mainAxis:(r=C.mainAxis)!=null?r:0,crossAxis:(o=C.crossAxis)!=null?o:0};if(c){let A=d==="y"?"height":"width",T=a.reference[d]-a.floating[A]+w.mainAxis,_=a.reference[d]+a.reference[A]-w.mainAxis;v_&&(v=_)}if(f){var b,R;let A=d==="y"?"width":"height",T=Wf.has(Pt(i)),_=a.reference[g]-a.floating[A]+(T&&((b=u.offset)==null?void 0:b[g])||0)+(T?0:w.crossAxis),P=a.reference[g]+a.reference[A]+(T?0:((R=u.offset)==null?void 0:R[g])||0)-(T?w.crossAxis:0);x<_?x=_:x>P&&(x=P)}return{[d]:v,[g]:x}}}},Zf=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:r,rects:o,platform:n,elements:s}=t,{apply:i=()=>{},...a}=xr(e,t),u=await n.detectOverflow(t,a),l=Pt(r),c=Sr(r),f=Gt(r)==="y",{width:m,height:g}=o.floating,d,v;l==="top"||l==="bottom"?(d=l,v=c===(await(n.isRTL==null?void 0:n.isRTL(s.floating))?"start":"end")?"left":"right"):(v=l,d=c==="end"?"top":"bottom");let x=g-u.top-u.bottom,C=m-u.left-u.right,w=lo(g-u[d],x),b=lo(m-u[v],C),R=t.middlewareData.shift,A=!R,T=w,_=b;R!=null&&R.enabled.x&&(_=C),R!=null&&R.enabled.y&&(T=x),A&&!c&&(f?_=m-2*wr(u.left,u.right):T=g-2*wr(u.top,u.bottom)),await i({...t,availableWidth:_,availableHeight:T});let P=await n.getDimensions(s.floating);return m!==P.width||g!==P.height?{reset:{rects:!0}}:{}}}};function Jf(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=Et(e),s=n?e.offsetWidth:r,i=n?e.offsetHeight:o,a=co(r)!==s||co(o)!==i;return a&&(r=s,o=i),{width:r,height:o,$:a}}function $a(e){return Se(e)?e:e.contextElement}function an(e){let t=$a(e);if(!Et(t))return Or(1);let r=t.getBoundingClientRect(),{width:o,height:n,$:s}=Jf(t),i=(s?co(r.width):r.width)/o,a=(s?co(r.height):r.height)/n;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}var n0=Or(0);function Qf(e){let t=it(e);return!Vs()||!t.visualViewport?n0:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function s0(e,t,r){return t===void 0&&(t=!1),!!r&&t&&r===it(e)}function Io(e,t,r,o){t===void 0&&(t=!1),r===void 0&&(r=!1);let n=e.getBoundingClientRect(),s=$a(e),i=Or(1);t&&(o?Se(o)&&(i=an(o)):i=an(e));let a=s0(s,r,o)?Qf(s):Or(0),u=(n.left+a.x)/i.x,l=(n.top+a.y)/i.y,c=n.width/i.x,f=n.height/i.y;if(s&&o){let m=it(s),g=Se(o)?it(o):o,d=m,v=Bs(d);for(;v&&g!==d;){let x=an(v),C=v.getBoundingClientRect(),w=Lt(v),b=C.left+(v.clientLeft+parseFloat(w.paddingLeft))*x.x,R=C.top+(v.clientTop+parseFloat(w.paddingTop))*x.y;u*=x.x,l*=x.y,c*=x.x,f*=x.y,u+=b,l+=R,d=it(v),v=Bs(d)}}return Fo({width:c,height:f,x:u,y:l})}function Zs(e,t){let r=Xn(e).scrollLeft;return t?t.left+r:Io(_r(e)).left+r}function $f(e,t){let r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-Zs(e,r),n=r.top+t.scrollTop;return{x:o,y:n}}function i0(e){let{elements:t,rect:r,offsetParent:o,strategy:n}=e,s=n==="fixed",i=_r(o),a=t?Zn(t.floating):!1;if(o===i||a&&s)return r;let u={scrollLeft:0,scrollTop:0},l=Or(1),c=Or(0),f=Et(o);if((f||!s)&&((Po(o)!=="body"||qn(i))&&(u=Xn(o)),f)){let g=Io(o);l=an(o),c.x=g.x+o.clientLeft,c.y=g.y+o.clientTop}let m=i&&!f&&!s?$f(i,u):Or(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-u.scrollLeft*l.x+c.x+m.x,y:r.y*l.y-u.scrollTop*l.y+c.y+m.y}}function a0(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function l0(e){let t=Xn(e),r=e.ownerDocument.body,o=wr(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),n=wr(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight),s=-t.scrollLeft+Zs(e),i=-t.scrollTop;return Lt(r).direction==="rtl"&&(s+=wr(e.clientWidth,r.clientWidth)-o),{width:o,height:n,x:s,y:i}}var c0=25;function u0(e,t,r){r===void 0&&(r="viewport");let o=r==="layoutViewport",n=it(e),s=_r(e),i=n.visualViewport,a=s.clientWidth,u=s.clientHeight,l=0,c=0;if(i){let m=!Vs()||t==="fixed";o?m||(l=-i.offsetLeft,c=-i.offsetTop):(a=i.width,u=i.height,m&&(l=i.offsetLeft,c=i.offsetTop))}if(Zs(s)<=0){let m=s.ownerDocument,g=m.body,d=getComputedStyle(g),v=m.compatMode==="CSS1Compat"&&parseFloat(d.marginLeft)+parseFloat(d.marginRight)||0,x=Math.abs(s.clientWidth-g.clientWidth-v),C=getComputedStyle(s).scrollbarGutter==="stable both-edges"?x/2:x;C<=c0&&(a-=C)}return{width:a,height:u,x:l,y:c}}function f0(e,t){let r=Io(e,!0,t==="fixed"),o=r.top+e.clientTop,n=r.left+e.clientLeft,s=an(e),i=e.clientWidth*s.x,a=e.clientHeight*s.y,u=n*s.x,l=o*s.y;return{width:i,height:a,x:u,y:l}}function Xf(e,t,r){let o;if(t==="viewport"||t==="layoutViewport")o=u0(e,r,t);else if(t==="document")o=l0(_r(e));else if(Se(t))o=f0(t,r);else{let n=Qf(e);o={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Fo(o)}function d0(e,t){let r=t.get(e);if(r)return r;let o=so(e,[],!1).filter(a=>Se(a)&&Po(a)!=="body"),n=null,s=Lt(e).position==="fixed",i=s?Tr(e):e;for(;Se(i)&&!Pr(i);){let a=Lt(i),u=Ms(i),l=n?n.position:s?"fixed":"";!u&&(l==="fixed"||l==="absolute"&&a.position==="static")?o=o.filter(f=>f!==i):n=a,i=Tr(i)}return t.set(e,o),o}function p0(e){let{element:t,boundary:r,rootBoundary:o,strategy:n}=e,i=[...r==="clippingAncestors"?Zn(t)?[]:d0(t,this._c):[].concat(r),o],a=Xf(t,i[0],n),u=a.top,l=a.right,c=a.bottom,f=a.left;for(let m=1;m{a(!1,1e-7)},1e3)}_=!1}try{o=new IntersectionObserver(P,{...T,root:s.ownerDocument})}catch{o=new IntersectionObserver(P,T)}o.observe(e)}let u=it(e),l=()=>a(r);return u.addEventListener("resize",l),a(!0),()=>{u.removeEventListener("resize",l),i()}}function ts(e,t,r,o){o===void 0&&(o={});let{ancestorScroll:n=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:u=!1}=o,l=$a(e),c=n||s?[...l?so(l):[],...t?so(t):[]]:[];c.forEach(C=>{n&&C.addEventListener("scroll",r),s&&C.addEventListener("resize",r)});let f=l&&a?v0(l,r,s):null,m=-1,g=null;i&&(g=new ResizeObserver(C=>{let[w]=C;w&&w.target===l&&g&&t&&(g.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var b;(b=g)==null||b.observe(t)})),r()}),l&&!u&&g.observe(l),t&&g.observe(t));let d,v=u?Io(e):null;u&&x();function x(){let C=Io(e);v&&!td(v,C)&&r(),v=C,d=requestAnimationFrame(x)}return r(),()=>{var C;c.forEach(w=>{n&&w.removeEventListener("scroll",r),s&&w.removeEventListener("resize",r)}),f?.(),(C=g)==null||C.disconnect(),g=null,u&&cancelAnimationFrame(d)}}var rd=Gf;var od=Yf,nd=Uf,sd=Zf,id=Hf;var ad=qf,Xs=(e,t,r)=>{let o=new Map,n=r??{},s={...el,...n.platform,_c:o};return zf(e,t,{...n,platform:s})};var yt=h(ge(),1),cd=h(ge(),1),ud=h(io(),1),w0=typeof document<"u",x0=function(){},Ks=w0?cd.useLayoutEffect:x0;function Js(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,o,n;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(o=r;o--!==0;)if(!Js(e[o],t[o]))return!1;return!0}if(n=Object.keys(e),r=n.length,r!==Object.keys(t).length)return!1;for(o=r;o--!==0;)if(!{}.hasOwnProperty.call(t,n[o]))return!1;for(o=r;o--!==0;){let s=n[o];if(!(s==="_owner"&&e.$$typeof)&&!Js(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function fd(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ld(e,t){let r=fd(e);return Math.round(t*r)/r}function tl(e){let t=yt.useRef(e);return Ks(()=>{t.current=e}),t}function dd(e){e===void 0&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:o=[],platform:n,elements:{reference:s,floating:i}={},transform:a=!0,whileElementsMounted:u,open:l}=e,[c,f]=yt.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[m,g]=yt.useState(o);Js(m,o)||g(o);let[d,v]=yt.useState(null),[x,C]=yt.useState(null),w=yt.useCallback(M=>{M!==T.current&&(T.current=M,v(M))},[]),b=yt.useCallback(M=>{M!==_.current&&(_.current=M,C(M))},[]),R=s||d,A=i||x,T=yt.useRef(null),_=yt.useRef(null),P=yt.useRef(c),N=u!=null,q=tl(u),H=tl(n),S=tl(l),I=yt.useCallback(()=>{if(!T.current||!_.current)return;let M={placement:t,strategy:r,middleware:m};H.current&&(M.platform=H.current),Xs(T.current,_.current,M).then(E=>{let L={...E,isPositioned:S.current!==!1};W.current&&!Js(P.current,L)&&(P.current=L,ud.flushSync(()=>{f(L)}))})},[m,t,r,H,S]);Ks(()=>{l===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,f(M=>({...M,isPositioned:!1})))},[l]);let W=yt.useRef(!1);Ks(()=>(W.current=!0,()=>{W.current=!1}),[]),Ks(()=>{if(R&&(T.current=R),A&&(_.current=A),R&&A){if(q.current)return q.current(R,A,I);I()}},[R,A,I,q,N]);let O=yt.useMemo(()=>({reference:T,floating:_,setReference:w,setFloating:b}),[w,b]),D=yt.useMemo(()=>({reference:R,floating:A}),[R,A]),J=yt.useMemo(()=>{let M={position:r,left:0,top:0};if(!D.floating)return M;let E=ld(D.floating,c.x),L=ld(D.floating,c.y);return a?{...M,transform:"translate("+E+"px, "+L+"px)",...fd(D.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:E,top:L}},[r,a,D.floating,c.x,c.y]);return yt.useMemo(()=>({...c,update:I,refs:O,elements:D,floatingStyles:J}),[c,I,O,D,J])}var rl=(e,t)=>{let r=rd(e);return{name:r.name,fn:r.fn,options:[e,t]}},ol=(e,t)=>{let r=od(e);return{name:r.name,fn:r.fn,options:[e,t]}},nl=(e,t)=>({fn:ad(e).fn,options:[e,t]}),sl=(e,t)=>{let r=nd(e);return{name:r.name,fn:r.fn,options:[e,t]}},il=(e,t)=>{let r=sd(e);return{name:r.name,fn:r.fn,options:[e,t]}};var al=(e,t)=>{let r=id(e);return{name:r.name,fn:r.fn,options:[e,t]}};var un=h(ge(),1),Pd=h(io(),1);var Td=h(ge(),1);var De=(e,t,r,o,n,s,...i)=>{if(i.length>0)throw new Error(Ut(1));let a;if(e&&t&&r&&o&&n&&s)a=(u,l,c,f)=>{let m=e(u,l,c,f),g=t(u,l,c,f),d=r(u,l,c,f),v=o(u,l,c,f),x=n(u,l,c,f);return s(m,g,d,v,x,l,c,f)};else if(e&&t&&r&&o&&n)a=(u,l,c,f)=>{let m=e(u,l,c,f),g=t(u,l,c,f),d=r(u,l,c,f),v=o(u,l,c,f);return n(m,g,d,v,l,c,f)};else if(e&&t&&r&&o)a=(u,l,c,f)=>{let m=e(u,l,c,f),g=t(u,l,c,f),d=r(u,l,c,f);return o(m,g,d,l,c,f)};else if(e&&t&&r)a=(u,l,c,f)=>{let m=e(u,l,c,f),g=t(u,l,c,f);return r(m,g,l,c,f)};else if(e&&t)a=(u,l,c,f)=>{let m=e(u,l,c,f);return t(m,l,c,f)};else if(e)a=e;else throw new Error("Missing arguments");return a};var Rd=h(ge(),1),pl=h(cl(),1),Ed=h(bd(),1);var wd=h(ge(),1);var ul=[],fl;function xd(){return fl}function Sd(e){ul.push(e)}function dl(e){let t=(r,o)=>{let n=Rt(B0).current,s;try{fl=n;for(let i of ul)i.before(n);s=e(r,o);for(let i of ul)i.after(n);n.didInitialize=!0}finally{fl=void 0}return s};return t.displayName=e.displayName||e.name,t}function Cd(e){return wd.forwardRef(dl(e))}function B0(){return{didInitialize:!1}}var j0=$o(19),z0=j0?H0:W0;function $s(e,t,r,o,n){return z0(e,t,r,o,n)}function U0(e,t,r,o,n){let s=Rd.useCallback(()=>t(e.getSnapshot(),r,o,n),[e,t,r,o,n]);return(0,pl.useSyncExternalStore)(e.subscribe,s,s)}Sd({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let r=0;r0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let r=new Set;for(let n of e.syncHooks)r.add(n.store);let o=[];for(let n of r)o.push(n.subscribe(t));return()=>{for(let n of o)n()}}),(0,pl.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function H0(e,t,r,o,n){let s=xd();if(!s)return U0(e,t,r,o,n);let i=s.syncIndex;s.syncIndex+=1;let a;return s.didInitialize?(a=s.syncHooks[i],(a.store!==e||a.selector!==t||!Object.is(a.a1,r)||!Object.is(a.a2,o)||!Object.is(a.a3,n))&&(a.store!==e&&(s.didChangeStore=!0),a.store=e,a.selector=t,a.a1=r,a.a2=o,a.a3=n,a.value=t(e.getSnapshot(),r,o,n))):(a={store:e,selector:t,a1:r,a2:o,a3:n,value:t(e.getSnapshot(),r,o,n)},s.syncHooks.push(a)),a.value}function W0(e,t,r,o,n){return(0,Ed.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,s=>t(s,r,o,n))}var ei=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let r=this.updateTick;for(let o of this.listeners){if(r!==this.updateTick)return;o(t)}}update(t){for(let r in t)if(!Object.is(this.state[r],t[r])){this.setState({...this.state,...t});return}}set(t,r){Object.is(this.state[t],r)||this.setState({...this.state,[t]:r})}notifyAll(){let t={...this.state};this.setState(t)}use(t,r,o,n){return $s(this,t,r,o,n)}};var Lo=h(ge(),1);var cn=class extends ei{constructor(t,r={},o){super(t),this.context=r,this.selectors=o}useSyncedValue(t,r){Lo.useDebugValue(t);let o=this;ye(()=>{o.state[t]!==r&&o.set(t,r)},[o,t,r])}useSyncedValueWithCleanup(t,r){let o=this;ye(()=>(o.state[t]!==r&&o.set(t,r),()=>{o.set(t,void 0)}),[o,t,r])}useSyncedValues(t){let r=this,o=Object.values(t);ye(()=>{r.update(t)},[r,...o])}useControlledProp(t,r){Lo.useDebugValue(t);let o=this,n=r!==void 0;ye(()=>{n&&!Object.is(o.state[t],r)&&o.setState({...o.state,[t]:r})},[o,t,r,n])}select(t,r,o,n){let s=this.selectors[t];return s(this.state,r,o,n)}useState(t,r,o,n){return Lo.useDebugValue(t),$s(this,this.selectors[t],r,o,n)}useContextCallback(t,r){Lo.useDebugValue(t);let o=Te(r??oo);this.context[t]=o}useStateSetter(t){let r=Lo.useRef(void 0);return r.current===void 0&&(r.current=o=>{this.set(t,o)}),r.current}observe(t,r){let o;typeof t=="function"?o=t:o=this.selectors[t];let n=o(this.state);return r(n,n,this),this.subscribe(s=>{let i=o(s);if(!Object.is(n,i)){let a=n;n=i,r(i,a,this)}})}};var G0={open:De(e=>e.open),transitionStatus:De(e=>e.transitionStatus),domReferenceElement:De(e=>e.domReferenceElement),referenceElement:De(e=>e.positionReference??e.referenceElement),floatingElement:De(e=>e.floatingElement),floatingId:De(e=>e.floatingId)},kr=class extends cn{constructor(t){let{syncOnly:r,nested:o,onOpenChange:n,triggerElements:s,...i}=t;super({...i,positionReference:i.referenceElement,domReferenceElement:i.referenceElement},{onOpenChange:n,dataRef:{current:{}},events:Nf(),nested:o,triggerElements:s},G0),this.syncOnly=r}syncOpenEvent=(t,r)=>{(!t||!this.state.open||r!=null&&vf(r))&&(this.context.dataRef.current.openEvent=t?r:void 0)};dispatchOpenChange=(t,r)=>{this.syncOpenEvent(t,r.event);let o={open:t,reason:r.reason,nativeEvent:r.event,nested:this.context.nested,triggerElement:r.trigger};this.context.events.emit("openchange",o)};setOpen=(t,r)=>{if(this.syncOnly){this.context.onOpenChange?.(t,r);return}this.dispatchOpenChange(t,r),this.context.onOpenChange?.(t,r)}};function _d(e){let{popupStore:t,treatPopupAsFloatingElement:r=!1,floatingRootContext:o,floatingId:n,nested:s,onOpenChange:i}=e,a=t.useState("open"),u=t.useState("activeTriggerElement"),l=t.useState(r?"popupElement":"positionerElement"),c=t.context.triggerElements,f=i,m=Td.useRef(null);o===void 0&&m.current===null&&(m.current=new kr({open:a,transitionStatus:void 0,referenceElement:u,floatingElement:l,triggerElements:c,onOpenChange:f,floatingId:n,syncOnly:!0,nested:s}));let g=o??m.current;return t.useSyncedValue("floatingId",n),ye(()=>{let d={open:a,floatingId:n,referenceElement:u,floatingElement:l};Se(u)&&(d.domReferenceElement=u),g.state.positionReference===g.state.referenceElement&&(d.positionReference=u),g.update(d)},[a,n,u,l,g]),g.context.onOpenChange=f,g.context.nested=s,g}var Od={tabIndex:-1,[Ha]:""};function kd(e,t,r=!1){let o=no(),n=sn()!=null,s=un.useRef(null);e===void 0&&s.current===null&&(s.current=t(o,n));let i=e??s.current;return _d({popupStore:i,treatPopupAsFloatingElement:r,floatingRootContext:i.state.floatingRootContext,floatingId:o,nested:n,onOpenChange:i.setOpen}),{store:i,internalStore:s.current}}function Y0(e,t){let r=un.useRef(null),o=un.useRef(null);return un.useCallback(n=>{if(e===void 0)return;let s=!1;if(r.current!==null){let i=r.current,a=o.current,u=t.context.triggerElements.getById(i);a&&u===a&&(t.context.triggerElements.delete(i),s=!0),r.current=null,o.current=null}if(n!==null&&(r.current=e,o.current=n,t.context.triggerElements.add(e,n),s=!0),s){let i=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==i&&t.set("triggerCount",i)}},[t,e])}function q0(e,t,r,o=!1){t?e.preventUnmountingOnClose=!1:o&&(e.preventUnmountingOnClose=!0);let n=r?.id??null;(n||t)&&(e.activeTriggerId=n,e.activeTriggerElement=r??null)}function Z0(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function Fd(e,t,r,o={}){let n=r.reason,s=n===_e.triggerHover,i=t&&n===_e.triggerFocus,a=!t&&(n===_e.triggerPress||n===_e.escapeKey),u=Z0(r);if(e.context.onOpenChange?.(t,r),r.isCanceled)return;o.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,r);let l=()=>{let c={...o.extraState,open:t};i?c.instantType="focus":a?c.instantType="dismiss":s&&(c.instantType=void 0),q0(c,t,r.trigger,u()),e.update(c)};s?Pd.flushSync(l):l()}function Ad(e,t,r,o){df(()=>{t===void 0&&e.state.open===!1&&r&&(e.state={...e.state,open:!0,activeTriggerId:o,preventUnmountingOnClose:!1})})}function Id(e,t,r,o){let n=r.useState("isMountedByTrigger",e),s=Y0(e,r),i=Te(a=>{if(s(a),!a)return;let u=r.select("open"),l=r.select("activeTriggerId");if(l===e){r.update({activeTriggerElement:a,...u?o:null});return}l==null&&u&&r.update({activeTriggerId:e,activeTriggerElement:a,...o})});return ye(()=>{n&&r.update({activeTriggerElement:t.current,...o})},[n,r,t,...Object.values(o)]),{registerTrigger:i,isMountedByThisTrigger:n}}function Ld(e,t={}){let{closeOnActiveTriggerUnmount:r=!1}=t,o=e.useState("open"),n=e.useState("triggerCount");ye(()=>{if(!o){e.state.triggerCount!==0&&e.set("triggerCount",0);return}let s=e.context.triggerElements.size,i={};e.state.triggerCount!==s&&(i.triggerCount=s);let a=e.select("activeTriggerId"),u=null;if(a){let l=e.context.triggerElements.getById(a);l?l!==e.state.activeTriggerElement&&(i.activeTriggerElement=l):u=a}if(!u&&!a&&s===1){let l=e.context.triggerElements.entries().next();if(!l.done){let[c,f]=l.value;i.activeTriggerId=c,i.activeTriggerElement=f}}(i.triggerCount!==void 0||i.activeTriggerId!==void 0||i.activeTriggerElement!==void 0)&&e.update(i),u&&r&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===u&&!e.context.triggerElements.getById(u)){let l=je(_e.none);e.setOpen(!1,l),l.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[o,e,n,r])}function Nd(e,t,r){let{mounted:o,setMounted:n,transitionStatus:s}=tf(e),i=t.useState("preventUnmountingOnClose"),a=e?!1:i;t.useSyncedValues({mounted:o,transitionStatus:s,preventUnmountingOnClose:a});let u=Te(()=>{n(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),r?.(),t.context.onOpenChangeComplete?.(!1)});return js({enabled:o&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||u()}}),{forceUnmount:u,transitionStatus:s}}function Dd(e,t){e.useSyncedValues(t),ye(()=>()=>{e.update({activeTriggerProps:pt,inactiveTriggerProps:pt,popupProps:pt})},[e])}var fo=class{constructor(){this.elementsSet=new Set,this.idMap=new Map}add(t,r){let o=this.idMap.get(t);o!==r&&(o!==void 0&&this.elementsSet.delete(o),this.elementsSet.add(r),this.idMap.set(t,r))}delete(t){let r=this.idMap.get(t);r&&(this.elementsSet.delete(r),this.idMap.delete(t))}hasElement(t){return this.elementsSet.has(t)}hasMatchingElement(t){for(let r of this.elementsSet)if(t(r))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.elementsSet.values()}get size(){return this.idMap.size}};function Md(){return new kr({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new fo,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function Bd(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:Md(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:pt,inactiveTriggerProps:pt,popupProps:pt}}function jd(e,t,r=!1){return new kr({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:r,onOpenChange:void 0})}var rs=De(e=>e.triggerIdProp??e.activeTriggerId),ml=De(e=>e.openProp??e.open),Vd=De(e=>(e.popupElement?.id??e.floatingId)||void 0);function zd(e,t){return t!==void 0&&ml(e)&&rs(e)===t}function X0(e,t){return zd(e,t)?!0:t!==void 0&&ml(e)&&rs(e)==null&&e.triggerCount===1}var Ud={open:ml,mounted:De(e=>e.mounted),transitionStatus:De(e=>e.transitionStatus),floatingRootContext:De(e=>e.floatingRootContext),triggerCount:De(e=>e.triggerCount),preventUnmountingOnClose:De(e=>e.preventUnmountingOnClose),payload:De(e=>e.payload),activeTriggerId:rs,activeTriggerElement:De(e=>e.mounted?e.activeTriggerElement:null),popupId:Vd,isTriggerActive:De((e,t)=>t!==void 0&&rs(e)===t),isOpenedByTrigger:De((e,t)=>zd(e,t)),isMountedByTrigger:De((e,t)=>t!==void 0&&rs(e)===t&&e.mounted),triggerProps:De((e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps),triggerPopupId:De((e,t)=>X0(e,t)?Vd(e):void 0),popupProps:De(e=>e.popupProps),popupElement:De(e=>e.popupElement),positionerElement:De(e=>e.positionerElement)};function Hd(e){let{open:t=!1,onOpenChange:r,elements:o={}}=e,n=no(),s=sn()!=null,i=Rt(()=>new kr({open:t,transitionStatus:void 0,onOpenChange:r,referenceElement:o.reference??null,floatingElement:o.floating??null,triggerElements:new fo,floatingId:n,syncOnly:!1,nested:s})).current;return ye(()=>{let a={open:t,floatingId:n};o.reference!==void 0&&(a.referenceElement=o.reference,a.domReferenceElement=Se(o.reference)?o.reference:null),o.floating!==void 0&&(a.floatingElement=o.floating),i.update(a)},[t,n,o.reference,o.floating,i]),i.context.onOpenChange=r,i.context.nested=s,i}function hl(e={}){let{nodeId:t,externalTree:r}=e,o=Hd(e),n=e.rootContext||o,s=n.useState("referenceElement"),i=n.useState("floatingElement"),a=n.useState("domReferenceElement"),u=n.useState("open"),l=n.useState("floatingId"),[c,f]=Ot.useState(null),[m,g]=Ot.useState(void 0),[d,v]=Ot.useState(void 0),x=Ot.useRef(null),C=uo(r),w=Ot.useMemo(()=>({reference:s,floating:i,domReference:a}),[s,i,a]),b=dd({...e,elements:{...w,...c&&{reference:c}}}),R=Se(m)?m:null,A=d===void 0?n.state.floatingElement:d;n.useSyncedValue("referenceElement",m??null),n.useSyncedValue("domReferenceElement",m===void 0?a:R),n.useSyncedValue("floatingElement",A);let T=Ot.useCallback(S=>{let I=Se(S)?{getBoundingClientRect:()=>S.getBoundingClientRect(),getClientRects:()=>S.getClientRects(),contextElement:S}:S;f(I),b.refs.setReference(I)},[b.refs]),_=Ot.useCallback(S=>{(Se(S)||S===null)&&(x.current=S,g(S)),(Se(b.refs.reference.current)||b.refs.reference.current===null||S!==null&&!Se(S))&&b.refs.setReference(S)},[b.refs,g]),P=Ot.useCallback(S=>{v(S),b.refs.setFloating(S)},[b.refs]),N=Ot.useMemo(()=>({...b.refs,setReference:_,setFloating:P,setPositionReference:T,domReference:x}),[b.refs,_,P,T]),q=Ot.useMemo(()=>({...b.elements,domReference:a}),[b.elements,a]),H=Ot.useMemo(()=>({...b,dataRef:n.context.dataRef,open:u,onOpenChange:n.setOpen,events:n.context.events,floatingId:l,refs:N,elements:q,nodeId:t,rootStore:n}),[b,N,q,t,n,u,l]);return ye(()=>{a&&(x.current=a)},[a]),ye(()=>{n.context.dataRef.current.floatingContext=H;let S=C?.nodesRef.current.find(I=>I.id===t);S&&(S.context=H)}),Ot.useMemo(()=>({...b,context:H,refs:N,elements:q,rootStore:n}),[b,N,q,H,n])}var Fr=h(ge(),1);var gl=Wr.os.mac&&Wr.engine.webkit;function yl(e,t={}){let{enabled:r=!0,delay:o}=t,n="rootStore"in e?e.rootStore:e,{events:s,dataRef:i}=n.context,a=Fr.useRef(!1),u=Fr.useRef(null),l=Fr.useRef(!0),c=vr();Fr.useEffect(()=>{let m=n.select("domReferenceElement");if(!r)return;let g=it(m);function d(){let C=n.select("domReferenceElement");!n.select("open")&&Et(C)&&C===zs(xt(C))&&(a.current=!0)}function v(){l.current=!0}function x(){l.current=!1}return br(Ye(g,"blur",d),gl&&Ye(g,"keydown",v,!0),gl&&Ye(g,"pointerdown",x,!0))},[n,r]),Fr.useEffect(()=>{if(!r)return;function m(g){if(g.reason===_e.triggerPress||g.reason===_e.escapeKey){let d=n.select("domReferenceElement");Se(d)&&(u.current=d,a.current=!0)}}return s.on("openchange",m),()=>{s.off("openchange",m)}},[s,r,n]);let f=Fr.useMemo(()=>{function m(){a.current=!1,u.current=null}return{onMouseLeave(){m()},onFocus(g){let d=g.currentTarget;if(a.current){if(u.current===d)return;m()}let v=Nt(g.nativeEvent);if(Se(v)){if(gl&&!g.relatedTarget){if(!l.current&&!wf(v))return}else if(!xf(v))return}let x=ao(g.relatedTarget,n.context.triggerElements),{nativeEvent:C,currentTarget:w}=g,b=typeof o=="function"?o():o;if(n.select("open")&&x||b===0||b===void 0){n.setOpen(!0,je(_e.triggerFocus,C,w));return}c.start(b,()=>{a.current||n.setOpen(!0,je(_e.triggerFocus,C,w))})},onBlur(g){m();let d=g.relatedTarget,v=g.nativeEvent,x=Se(d)&&d.hasAttribute(nn("focus-guard"))&&d.getAttribute("data-type")==="outside";c.start(0,()=>{let C=n.select("domReferenceElement"),w=zs(xt(C));!d&&w===C||Ze(i.current.floatingContext?.refs.floating.current,w)||Ze(C,w)||x||ao(d??w,n.context.triggerElements)||n.setOpen(!1,je(_e.triggerFocus,v))})}}},[i,o,n,c]);return Fr.useMemo(()=>r?{reference:f,trigger:f}:{},[r,f])}var bl=h(ge(),1);var vl=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new tr,this.restTimeout=new tr,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},ti=new WeakMap;function fn(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&ti.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),ti.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ri(e,t){let{scopeElement:r,referenceElement:o,floatingElement:n}=t,s=ti.get(r);s&&s!==e&&fn(s),fn(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=r,e.pointerEventsReferenceElement=o,e.pointerEventsFloatingElement=n,ti.set(r,e),r.style.pointerEvents="none",o.style.pointerEvents="auto",n.style.pointerEvents="auto"}function dn(e){let t=e.context.dataRef.current,r=Rt(()=>t.hoverInteractionState??vl.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=r),en(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function wl(e,t={}){let{enabled:r=!0,closeDelay:o=0,nodeId:n}=t,s="rootStore"in e?e.rootStore:e,i=s.useState("open"),a=s.useState("floatingElement"),u=s.useState("domReferenceElement"),{dataRef:l}=s.context,c=uo(),f=sn(),m=dn(s),g=vr(),d=Te(()=>Hs(l.current.openEvent?.type,m.interactedInside)),v=Te(()=>Sf(l.current.openEvent?.type)),x=Te(()=>{fn(m)});ye(()=>{i||(m.pointerType=void 0,m.restTimeoutPending=!1,m.interactedInside=!1,x())},[i,m,x]),bl.useEffect(()=>x,[x]),ye(()=>{if(r&&i&&m.handleCloseOptions?.blockPointerEvents&&v()&&Se(u)&&a){let C=u,w=a,b=xt(a),R=c?.nodesRef.current.find(P=>P.id===f)?.context?.elements.floating;R&&(R.style.pointerEvents="");let A=m.pointerEventsScopeElement!==w?m.pointerEventsScopeElement:null,T=R!==w?R:null,_=m.handleCloseOptions?.getScope?.()??A??T??C.closest("[data-rootownerid]")??b.body;return ri(m,{scopeElement:_,referenceElement:C,floatingElement:w}),()=>{x()}}},[r,i,u,a,m,v,c,f,x]),bl.useEffect(()=>{if(!r)return;function C(){return!!(c&&f&&qr(c.nodesRef.current,f).length>0)}function w(P){let N=Yr(o,"close",m.pointerType),q=()=>{s.setOpen(!1,je(_e.triggerHover,P)),c?.events.emit("floating.closed",P)};N?m.openChangeTimeout.start(N,q):(m.openChangeTimeout.clear(),q())}function b(P){let N=Nt(P);if(!Ga(N)){m.interactedInside=!1;return}m.interactedInside=N?.closest("[aria-haspopup]")!=null}function R(){m.openChangeTimeout.clear(),g.clear(),c?.events.off("floating.closed",T),x()}function A(P){if(C()&&c){c.events.on("floating.closed",T);return}if(ao(P.relatedTarget,s.context.triggerElements))return;let N=l.current.floatingContext?.nodeId??n,q=P.relatedTarget;if(!(c&&N&&Se(q)&&qr(c.nodesRef.current,N,!1).some(S=>Ze(S.context?.elements.floating,q)))){if(m.handler){m.handler(P);return}x(),v()&&!d()&&w(P)}}function T(P){!c||!f||C()||g.start(0,()=>{c.events.off("floating.closed",T),s.setOpen(!1,je(_e.triggerHover,P)),c.events.emit("floating.closed",P)})}let _=a;return br(_&&Ye(_,"mouseenter",R),_&&Ye(_,"mouseleave",A),_&&Ye(_,"pointerdown",b,!0),()=>{c?.events.off("floating.closed",T)})},[r,a,s,l,o,n,v,d,x,m,c,f,g])}var po=h(ge(),1),Wd=h(io(),1);var K0={current:null};function xl(e,t={}){let{enabled:r=!0,delay:o=0,handleClose:n=null,mouseOnly:s=!1,restMs:i=0,move:a=!0,triggerElementRef:u=K0,externalTree:l,isActiveTrigger:c=!0,getHandleCloseContext:f,isClosing:m,shouldOpen:g}=t,d="rootStore"in e?e.rootStore:e,{dataRef:v,events:x}=d.context,C=uo(l),w=dn(d),b=po.useRef(!1),R=Wt(n),A=Wt(o),T=Wt(i),_=Wt(r),P=Wt(g),N=Wt(m),q=Te(()=>Hs(v.current.openEvent?.type,w.interactedInside)),H=Te(()=>P.current?.()!==!1),S=Te((O,D,J)=>{let M=d.context.triggerElements;if(M.hasElement(D))return!O||!Ze(O,D);if(!Se(J))return!1;let E=J;return M.hasMatchingElement(L=>Ze(L,E))&&(!O||!Ze(O,E))}),I=Te(()=>{if(!w.handler)return;xt(d.select("domReferenceElement")).removeEventListener("mousemove",w.handler),w.handler=void 0}),W=Te(()=>{fn(w)});return c&&(w.handleCloseOptions=R.current?.__options),po.useEffect(()=>I,[I]),po.useEffect(()=>{if(!r)return;function O(D){D.open?b.current=!1:(b.current=D.reason===_e.triggerHover,I(),w.openChangeTimeout.clear(),w.restTimeout.clear(),w.blockMouseMove=!0,w.restTimeoutPending=!1)}return x.on("openchange",O),()=>{x.off("openchange",O)}},[r,x,w,I]),po.useEffect(()=>{if(!r)return;function O(E,L=!0){let $=Yr(A.current,"close",w.pointerType);$?w.openChangeTimeout.start($,()=>{d.setOpen(!1,je(_e.triggerHover,E)),C?.events.emit("floating.closed",E)}):L&&(w.openChangeTimeout.clear(),d.setOpen(!1,je(_e.triggerHover,E)),C?.events.emit("floating.closed",E))}let D=u.current??(c?d.select("domReferenceElement"):null);if(!Se(D))return;function J(E){if(w.openChangeTimeout.clear(),w.blockMouseMove=!1,s&&!Gr(w.pointerType))return;let L=Ya(T.current),$=Yr(A.current,"open",w.pointerType),F=Nt(E),Z=E.currentTarget??null,se=d.select("domReferenceElement"),we=Z;if(Se(F)&&!d.context.triggerElements.hasElement(F)){for(let G of d.context.triggerElements.elements())if(Ze(G,F)){we=G;break}}Se(Z)&&Se(se)&&!d.context.triggerElements.hasElement(Z)&&Ze(Z,se)&&(we=se);let ie=we==null?!1:S(se,we,F),ve=d.select("open"),Ee=N.current?.()??d.select("transitionStatus")==="ending",ee=!ve&&Ee&&b.current,Fe=!ie&&Se(we)&&Se(se)&&Ze(se,we)&&ee,Ae=L>0&&!$,Oe=ie&&(ve||ee)||Fe,Ue=!ve||ie;if(Oe){H()&&d.setOpen(!0,je(_e.triggerHover,E,we));return}Ae||($?w.openChangeTimeout.start($,()=>{Ue&&H()&&d.setOpen(!0,je(_e.triggerHover,E,we))}):Ue&&H()&&d.setOpen(!0,je(_e.triggerHover,E,we)))}function M(E){if(q()){W();return}I();let L=d.select("domReferenceElement"),$=xt(L);w.restTimeout.clear(),w.restTimeoutPending=!1;let F=v.current.floatingContext??f?.();if(ao(E.relatedTarget,d.context.triggerElements))return;if(R.current&&F){d.select("open")||w.openChangeTimeout.clear();let se=u.current;w.handler=R.current({...F,tree:C,x:E.clientX,y:E.clientY,onClose(){W(),I(),_.current&&!q()&&se===d.select("domReferenceElement")&&O(E,!0)}}),$.addEventListener("mousemove",w.handler),w.handler(E);return}(w.pointerType!=="touch"||!Ze(d.select("floatingElement"),E.relatedTarget))&&O(E)}return a?br(Ye(D,"mousemove",J,{once:!0}),Ye(D,"mouseenter",J),Ye(D,"mouseleave",M)):br(Ye(D,"mouseenter",J),Ye(D,"mouseleave",M))},[I,W,v,A,d,r,R,w,c,S,q,s,a,T,u,C,_,f,N,H]),po.useMemo(()=>{if(!r)return;function O(D){w.pointerType=D.pointerType}return{onPointerDown:O,onPointerEnter:O,onMouseMove(D){let{nativeEvent:J}=D,M=D.currentTarget,E=d.select("domReferenceElement"),L=d.select("open"),$=S(E,M,D.target);if(s&&!Gr(w.pointerType))return;if(L&&$&&w.handleCloseOptions?.blockPointerEvents){let se=d.select("floatingElement");if(se){let we=w.handleCloseOptions?.getScope?.()??M.ownerDocument.body;ri(w,{scopeElement:we,referenceElement:M,floatingElement:se})}}let F=Ya(T.current);if(L&&!$||F===0||!$&&w.restTimeoutPending&&D.movementX**2+D.movementY**2<2)return;w.restTimeout.clear();function Z(){if(w.restTimeoutPending=!1,q())return;let se=d.select("open");!w.blockMouseMove&&(!se||$)&&H()&&d.setOpen(!0,je(_e.triggerHover,J,M))}w.pointerType==="touch"?Wd.flushSync(()=>{Z()}):$&&L?Z():(w.restTimeoutPending=!0,w.restTimeout.start(F,Z))}}},[r,w,q,S,s,d,T,H])}var Gd=.1,J0=Gd*Gd,Ke=.5;function oi(e,t,r,o,n,s){return o>=t!=s>=t&&e<=(n-r)*(t-o)/(s-o)+r}function ni(e,t,r,o,n,s,i,a,u,l){let c=!1;return oi(e,t,r,o,n,s)&&(c=!c),oi(e,t,n,s,i,a)&&(c=!c),oi(e,t,i,a,u,l)&&(c=!c),oi(e,t,u,l,r,o)&&(c=!c),c}function Q0(e,t,r){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height}function si(e,t,r,o,n,s){let i=Math.min(r,n),a=Math.max(r,n),u=Math.min(o,s),l=Math.max(o,s);return e>=i&&e<=a&&t>=u&&t<=l}function Sl(e={}){let{blockPointerEvents:t=!1}=e,r=new tr,o=({x:n,y:s,placement:i,elements:a,onClose:u,nodeId:l,tree:c})=>{let f=i?.split("-")[0],m=!1,g=null,d=null,v=typeof performance<"u"?performance.now():0;function x(w,b){let R=performance.now(),A=R-v;if(g===null||d===null||A===0)return g=w,d=b,v=R,!1;let T=w-g,_=b-d,P=T*T+_*_,N=A*A*J0;return g=w,d=b,v=R,P0)}function I(){S()||C()}if(S())return;let W=R.getBoundingClientRect(),O=A.getBoundingClientRect(),D=n>O.right-O.width/2,J=s>O.bottom-O.height/2,M=O.width>W.width,E=O.height>W.height,L=(M?W:O).left,$=(M?W:O).right,F=(E?W:O).top,Z=(E?W:O).bottom;if(f==="top"&&s>=W.bottom-1||f==="bottom"&&s<=W.top+1||f==="left"&&n>=W.right-1||f==="right"&&n<=W.left+1){I();return}let se=!1;switch(f){case"top":se=si(T,_,L,W.top+1,$,O.bottom-1);break;case"bottom":se=si(T,_,L,O.top+1,$,W.bottom-1);break;case"left":se=si(T,_,O.right-1,Z,W.left+1,F);break;case"right":se=si(T,_,W.right-1,Z,O.left+1,F);break;default:}if(se)return;if(m&&!Q0(T,_,W)){I();return}if(!N&&x(T,_)){I();return}let we=!1;switch(f){case"top":{let ie=M?Ke/2:Ke*4,ve=M||D?n+ie:n-ie,Ee=M?n-ie:D?n+ie:n-ie,ee=s+Ke+1,Fe=D||M?O.bottom-Ke:O.top,Ae=D?M?O.bottom-Ke:O.top:O.bottom-Ke;we=ni(T,_,ve,ee,Ee,ee,O.left,Fe,O.right,Ae);break}case"bottom":{let ie=M?Ke/2:Ke*4,ve=M||D?n+ie:n-ie,Ee=M?n-ie:D?n+ie:n-ie,ee=s-Ke,Fe=D||M?O.top+Ke:O.bottom,Ae=D?M?O.top+Ke:O.bottom:O.top+Ke;we=ni(T,_,ve,ee,Ee,ee,O.left,Fe,O.right,Ae);break}case"left":{let ie=E?Ke/2:Ke*4,ve=E||J?s+ie:s-ie,Ee=E?s-ie:J?s+ie:s-ie,ee=n+Ke+1,Fe=J||E?O.right-Ke:O.left,Ae=J?E?O.right-Ke:O.left:O.right-Ke;we=ni(T,_,Fe,O.top,Ae,O.bottom,ee,ve,ee,Ee);break}case"right":{let ie=E?Ke/2:Ke*4,ve=E||J?s+ie:s-ie,Ee=E?s-ie:J?s+ie:s-ie,ee=n-Ke,Fe=J||E?O.left+Ke:O.right,Ae=J?E?O.left+Ke:O.right:O.left+Ke;we=ni(T,_,ee,ve,ee,Ee,Fe,O.top,Ae,O.bottom);break}default:}we?m||r.start(40,I):I()}};return o.__options={...e,blockPointerEvents:t},o}var Cl=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=To.startingStyle]="startingStyle",e[e.endingStyle=To.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({}),os=(function(e){return e.popupOpen="data-popup-open",e.pressed="data-pressed",e})({}),$0={[os.popupOpen]:""},nk={[os.popupOpen]:"",[os.pressed]:""},ew={[Cl.open]:""},tw={[Cl.closed]:""},rw={[Cl.anchorHidden]:""},Yd={open(e){return e?$0:null}};var pn={open(e){return e?ew:tw},anchorHidden(e){return e?rw:null}};function qd(e){return $o(19)?e:e?"true":void 0}var or=h(ge(),1);var ow=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:o,placement:n,rects:s,platform:i,elements:a,middlewareData:u}=t,{element:l,padding:c=0,offsetParent:f="real"}=xr(e,t)||{};if(l==null)return{};let m=qs(c),g={x:r,y:o},d=es(n),v=$n(d),x=await i.getDimensions(l),C=d==="y",w=C?"top":"left",b=C?"bottom":"right",R=C?"clientHeight":"clientWidth",A=s.reference[v]+s.reference[d]-g[d]-s.floating[v],T=g[d]-s.reference[d],_=f==="real"?await i.getOffsetParent?.(l):a.floating,P=a.floating[R]||s.floating[v];(!P||!await i.isElement?.(_))&&(P=a.floating[R]||s.floating[v]);let N=A/2-T/2,q=P/2-x[v]/2-1,H=Math.min(m[w],q),S=Math.min(m[b],q),I=H,W=P-x[v]-S,O=P/2-x[v]/2+N,D=Gs(I,O,W),J=!u.arrow&&Sr(n)!=null&&O!==D&&s.reference[v]/2-(O({...ow(e),options:[e,t]});var nw=al().fn,Xd={name:"hide",async fn(e){let{width:t,height:r,x:o,y:n}=e.rects.reference,s=t===0&&r===0&&o===0&&n===0;return{data:{referenceHidden:(await nw(e)).data?.referenceHidden||s}}}};var ns={sideX:"left",sideY:"top"},Kd={name:"adaptiveOrigin",async fn(e){let{x:t,y:r,rects:{floating:o},elements:{floating:n},platform:s,strategy:i,placement:a}=e,u=it(n),l=u.getComputedStyle(n);if(!(l.transitionDuration!=="0s"&&l.transitionDuration!==""))return{x:t,y:r,data:ns};let f=await s.getOffsetParent?.(n),m={width:0,height:0};if(i==="fixed"&&u?.visualViewport)m={width:u.visualViewport.width,height:u.visualViewport.height};else if(f===u){let w=xt(n);m={width:w.documentElement.clientWidth,height:w.documentElement.clientHeight}}else await s.isElement?.(f)&&(m=await s.getDimensions(f));let g=Pt(a),d=t,v=r;g==="left"&&(d=m.width-(t+o.width)),g==="top"&&(v=m.height-(r+o.height));let x=g==="left"?"right":ns.sideX,C=g==="top"?"bottom":ns.sideY;return{x:d,y:v,data:{sideX:x,sideY:C}}}};function $d(e,t,r){let o=e==="inline-start"||e==="inline-end";return{top:"top",right:o?r?"inline-start":"inline-end":"right",bottom:"bottom",left:o?r?"inline-end":"inline-start":"left"}[t]}function Jd(e,t,r){let{rects:o,placement:n}=e;return{side:$d(t,Pt(n),r),align:Sr(n)||"center",anchor:{width:o.reference.width,height:o.reference.height},positioner:{width:o.floating.width,height:o.floating.height}}}function ep(e){let{anchor:t,positionMethod:r="absolute",side:o="bottom",sideOffset:n=0,align:s="center",alignOffset:i=0,collisionBoundary:a,collisionPadding:u=5,sticky:l=!1,arrowPadding:c=5,disableAnchorTracking:f=!1,inline:m,keepMounted:g=!1,floatingRootContext:d,mounted:v,collisionAvoidance:x,shiftCrossAxis:C=!1,nodeId:w,adaptiveOrigin:b,lazyFlip:R=!1,externalTree:A}=e,[T,_]=or.useState(null);!v&&T!==null&&_(null);let P=x.side||"flip",N=x.align||"flip",q=x.fallbackAxisSide||"end",H=typeof t=="function"?t:void 0,S=Te(H),I=H?S:t,W=Wt(t),O=Wt(v),J=Qo()==="rtl",M=T||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":J?"left":"right","inline-start":J?"right":"left"}[o],E=s==="center"?M:`${M}-${s}`,L=u,$=1,F=o==="bottom"?$:0,Z=o==="top"?$:0,se=o==="right"?$:0,we=o==="left"?$:0;typeof L=="number"?L={top:L+F,right:L+we,bottom:L+Z,left:L+se}:L&&(L={top:(L.top||0)+F,right:(L.right||0)+we,bottom:(L.bottom||0)+Z,left:(L.left||0)+se});let ie={boundary:a==="clipping-ancestors"?"clippingAncestors":a,padding:L},ve=or.useRef(null),Ee=Wt(n),ee=Wt(i),Fe=typeof n!="function"?n:0,Ae=typeof i!="function"?i:0,Oe=[];m&&Oe.push(m),Oe.push(rl(Le=>{let qe=Jd(Le,o,J),k=typeof Ee.current=="function"?Ee.current(qe):Ee.current,Q=typeof ee.current=="function"?ee.current(qe):ee.current;return{mainAxis:k,crossAxis:Q,alignmentAxis:Q}},[Fe,Ae,J,o]));let Ue=N==="none"&&P!=="shift",G=!Ue&&(l||C||P==="shift"),z=P==="none"?null:sl({...ie,padding:{top:L.top+$,right:L.right+$,bottom:L.bottom+$,left:L.left+$},mainAxis:!C&&P==="flip",crossAxis:N==="flip"?"alignment":!1,fallbackAxisSideDirection:q}),X=Ue?null:ol(Le=>{let qe=xt(Le.elements.floating).documentElement;return{...ie,rootBoundary:C?{x:0,y:0,width:qe.clientWidth,height:qe.clientHeight}:void 0,mainAxis:N!=="none",crossAxis:G,limiter:l||C?void 0:nl(k=>{if(!ve.current)return{};let{width:Q,height:y}=ve.current.getBoundingClientRect(),oe=Gt(Pt(k.placement)),Ve=oe==="y"?Q:y,te=oe==="y"?L.left+L.right:L.top+L.bottom;return{offset:Ve/2+te/2}})}},[ie,l,C,L,N]);P==="shift"||N==="shift"||s==="center"?Oe.push(X,z):Oe.push(z,X),Oe.push(il({...ie,apply({elements:{floating:Le},availableWidth:qe,availableHeight:k,rects:Q}){if(!O.current)return;let y=Le.style;y.setProperty("--available-width",`${qe}px`),y.setProperty("--available-height",`${k}px`);let oe=it(Le).devicePixelRatio||1,{x:Ve,y:te,width:ht,height:ne}=Q.reference,Qe=(Math.round((Ve+ht)*oe)-Math.round(Ve*oe))/oe,B=(Math.round((te+ne)*oe)-Math.round(te*oe))/oe;y.setProperty("--anchor-width",`${Qe}px`),y.setProperty("--anchor-height",`${B}px`)}}),Zd(Le=>({element:ve.current||xt(Le.elements.floating).createElement("div"),padding:c,offsetParent:"floating"}),[c]),{name:"transformOrigin",fn(Le){let{elements:qe,middlewareData:k,placement:Q,rects:y,y:oe}=Le,Ve=Pt(Q),te=Gt(Ve),ht=ve.current,ne=k.arrow?.x||0,Qe=k.arrow?.y||0,B=ht?.clientWidth||0,j=ht?.clientHeight||0,yr=ne+B/2,Ge=Qe+j/2,le=Math.abs(k.shift?.y||0),zr=y.reference.height/2,Qt=typeof n=="function"?n(Jd(Le,o,J)):n,et=le>Qt,Me={top:`${yr}px calc(100% + ${Qt}px)`,bottom:`${yr}px ${-Qt}px`,left:`calc(100% + ${Qt}px) ${Ge}px`,right:`${-Qt}px ${Ge}px`}[Ve],ft=`${yr}px ${y.reference.y+zr-oe}px`;return qe.floating.style.setProperty("--transform-origin",G&&te==="y"&&et?ft:Me),{}}},Xd,b),ye(()=>{!v&&d&&d.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[v,d]);let U=or.useMemo(()=>({elementResize:!f&&typeof ResizeObserver<"u",layoutShift:!f&&typeof IntersectionObserver<"u"}),[f]),{refs:K,elements:fe,x:ue,y:de,middlewareData:pe,update:me,placement:V,context:re,isPositioned:Ne,floatingStyles:He}=hl({rootContext:d,open:g?v:void 0,placement:E,middleware:Oe,strategy:r,whileElementsMounted:g?void 0:(...Le)=>ts(...Le,U),nodeId:w,externalTree:A}),{sideX:ot,sideY:ut}=pe.adaptiveOrigin||ns,ze=Ne?r:"fixed",We=or.useMemo(()=>{let Le=b?{position:ze,[ot]:ue,[ut]:de}:{position:ze,...He};return Ne||(Le.opacity=0),Le},[b,ze,ot,ue,ut,de,He,Ne]),nt=or.useRef(null);ye(()=>{if(!v)return;let Le=W.current,qe=typeof Le=="function"?Le():Le,Q=(Qd(qe)?qe.current:qe)||null||null;Q!==nt.current&&(K.setPositionReference(Q),nt.current=Q)},[v,K,I,W]),or.useEffect(()=>{if(!v)return;let Le=W.current;typeof Le!="function"&&Qd(Le)&&Le.current!==nt.current&&(K.setPositionReference(Le.current),nt.current=Le.current)},[v,K,I,W]),or.useEffect(()=>{if(g&&v&&fe.reference&&fe.floating)return ts(fe.reference,fe.floating,me,U)},[g,v,fe,me,U]);let be=Pt(V),Rr=$d(o,be,J),gr=Sr(V)||"center",$e=!!pe.hide?.referenceHidden;ye(()=>{R&&v&&Ne&&_(be)},[R,v,Ne,be]);let jr=or.useMemo(()=>({position:"absolute",top:pe.arrow?.y,left:pe.arrow?.x}),[pe.arrow]),Ct=pe.arrow?.centerOffset!==0;return or.useMemo(()=>({positionerStyles:We,arrowStyles:jr,arrowRef:ve,arrowUncentered:Ct,side:Rr,align:gr,physicalSide:be,anchorHidden:$e,refs:K,context:re,isPositioned:Ne,update:me}),[We,jr,ve,Ct,Rr,gr,be,$e,K,re,Ne,me])}function Qd(e){return e!=null&&"current"in e}function ii(e){return e==="starting"?Ff:pt}function tp(e,t,{styles:r,transitionStatus:o,props:n,refs:s,hidden:i,inert:a=!1}){let u={...r};return a&&(u.pointerEvents="none"),Ht("div",e,{state:t,ref:s,props:[{role:"presentation",hidden:i,style:u},ii(o),n],stateAttributesMapping:pn})}var kt=h(ge(),1),cp=h(io(),1);var rp=h(ge(),1);function op(e){let[t,r]=rp.useState({current:e,previous:null});return e!==t.current&&r({current:e,previous:t.current}),t.previous}var mn=h(ge(),1);function Rl(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=Et(e),s=n?e.offsetWidth:r,i=n?e.offsetHeight:o;return(co(r)!==s||co(o)!==i)&&(r=s,o=i),{width:r,height:o}}function sp(e){let{popupElement:t,positionerElement:r,content:o,mounted:n,onMeasureLayout:s,onMeasureLayoutComplete:i,side:a,direction:u}=e,l=on(t,!0,!1),c=tn(),f=mn.useRef(null),m=mn.useRef(!0),g=mn.useRef(oo),d=Te(s),v=Te(i),x=mn.useMemo(()=>{let C=a==="top",w=a==="left";return u==="rtl"?(C=C||a==="inline-end",w=w||a==="inline-end"):(C=C||a==="inline-start",w=w||a==="inline-start"),C?{position:"absolute",[a==="top"?"bottom":"top"]:"0",[w?"right":"left"]:"0"}:pt},[a,u]);ye(()=>{if(!n){g.current=oo,m.current=!0,f.current=null;return}if(!t||!r)return;g.current=np(t,x),El(t,"auto");let C=li(t,"position","static"),w=li(t,"transform","none"),b=li(t,"scale","1"),R=np(r,{"--available-width":"max-content","--available-height":"max-content"});function A(){C(),w(),R()}function T(){A(),b()}if(d?.(),m.current||f.current===null){ai(r,"max-content");let q=Rl(t);return f.current=q,ai(r,q),T(),v?.(null,q),m.current=!1,()=>{g.current(),g.current=oo}}ai(r,"max-content");let _=f.current,P=Rl(t);f.current=P,El(t,_),T(),v?.(_,P),ai(r,P);let N=new AbortController;return c.request(()=>{El(t,P),l(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},N.signal)}),()=>{N.abort(),c.cancel(),g.current(),g.current=oo}},[o,t,r,l,c,n,d,v,x])}function li(e,t,r){let o=e.style.getPropertyValue(t);return e.style.setProperty(t,r),()=>{e.style.setProperty(t,o)}}function np(e,t){let r=[];for(let[o,n]of Object.entries(t))r.push(li(e,o,n));return r.length?()=>{r.forEach(o=>o())}:oo}function El(e,t){let r=t==="auto"?"auto":`${t.width}px`,o=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",r),e.style.setProperty("--popup-height",o)}function ai(e,t){let r=t==="max-content"?"max-content":`${t.width}px`,o=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",r),e.style.setProperty("--positioner-height",o)}var ip=h(ge(),1);var ap=h(Y(),1),ci=function(t){let{direction:r="ltr"}=t,o=ip.useMemo(()=>({direction:r}),[r]);return(0,ap.jsx)(Ta.Provider,{value:o,children:t.children})};var hn=h(Y(),1);function up(e){let{store:t,side:r,cssVars:o,children:n}=e,s=Qo(),i=t.useState("activeTriggerElement"),a=t.useState("activeTriggerId"),u=t.useState("open"),l=t.useState("payload"),c=t.useState("mounted"),f=t.useState("popupElement"),m=t.useState("positionerElement"),g=op(u?i:null),d=aw(a,l),v=kt.useRef(null),[x,C]=kt.useState(null),[w,b]=kt.useState(null),R=kt.useRef(null),A=kt.useRef(null),T=on(R,!0,!1),_=tn(),[P,N]=kt.useState(null),[q,H]=kt.useState(!1);ye(()=>(t.set("hasViewport",!0),()=>{t.set("hasViewport",!1)}),[t]);let S=Te(()=>{R.current?.style.setProperty("animation","none"),R.current?.style.setProperty("transition","none"),A.current?.style.setProperty("display","none")}),I=Te(M=>{R.current?.style.removeProperty("animation"),R.current?.style.removeProperty("transition"),A.current?.style.removeProperty("display"),M&&N(M)}),W=kt.useRef(null);ye(()=>{(!u||!c)&&(W.current=null)},[u,c]),ye(()=>{if(i&&g&&i!==g&&W.current!==i&&v.current){C(v.current),H(!0);let M=iw(g,i);b(M),_.request(()=>{cp.flushSync(()=>{H(!1)}),T(()=>{C(null),N(null),v.current=null})}),W.current=i}},[i,g,x,T,_]),ye(()=>{let M=R.current;if(!M)return;let E=xt(M).createElement("div");for(let L of Array.from(M.childNodes))E.appendChild(L.cloneNode(!0));v.current=E});let O=x!=null,D;O?D=(0,hn.jsxs)(kt.Fragment,{children:[(0,hn.jsx)("div",{"data-previous":!0,inert:qd(!0),ref:A,style:{...P?{[o.popupWidth]:`${P.width}px`,[o.popupHeight]:`${P.height}px`}:null,position:"absolute"},"data-ending-style":q?void 0:""},"previous"),(0,hn.jsx)("div",{"data-current":!0,ref:R,"data-starting-style":q?"":void 0,children:n},d)]}):D=(0,hn.jsx)("div",{"data-current":!0,ref:R,children:n},d),ye(()=>{let M=A.current;!M||!x||M.replaceChildren(...Array.from(x.childNodes))},[x]),sp({popupElement:f,positionerElement:m,mounted:c,content:l,onMeasureLayout:S,onMeasureLayoutComplete:I,side:r,direction:s});let J={activationDirection:sw(w),transitioning:O};return{children:D,state:J}}function sw(e){if(e)return`${lp(e.horizontal,5,"right","left")} ${lp(e.vertical,5,"down","up")}`}function lp(e,t,r,o){return e>t?r:e<-t?o:""}function iw(e,t){let r=e.getBoundingClientRect(),o=t.getBoundingClientRect(),n={x:r.left+r.width/2,y:r.top+r.height/2},s={x:o.left+o.width/2,y:o.top+o.height/2};return{horizontal:s.x-n.x,vertical:s.y-n.y}}function aw(e,t){let[r,o]=kt.useState(0),n=kt.useRef(e),s=kt.useRef(t),i=kt.useRef(!1);return ye(()=>{let a=n.current,u=s.current,l=e!==a,c=t!==u;l?(o(f=>f+1),i.current=!c):i.current&&c&&(o(f=>f+1),i.current=!1),n.current=e,s.current=t},[e,t]),`${e??"current"}-${r}`}var ui=h(ge(),1),fp=h(io(),1);var dp=h(Y(),1),pp=ui.forwardRef(function(t,r){let{children:o,container:n,className:s,render:i,style:a,...u}=t,{portalNode:l,portalSubtree:c}=Xa({container:n,ref:r,componentProps:t,elementProps:u});return!c&&!l?null:(0,dp.jsxs)(ui.Fragment,{children:[c,l&&fp.createPortal(o,l)]})});var Zt={};ro(Zt,{Arrow:()=>Op,Handle:()=>ss,Popup:()=>_p,Portal:()=>Cp,Positioner:()=>Ep,Provider:()=>kp,Root:()=>hp,Trigger:()=>wp,Viewport:()=>Ip,createHandle:()=>Lp});var Ar=h(ge(),1);var fi=h(ge(),1),Tl=fi.createContext(void 0);function ir(e){let t=fi.useContext(Tl);if(t===void 0&&!e)throw new Error(Ut(72));return t}var mp=h(ge(),1);var lw={...Ud,disabled:De(e=>e.disabled),instantType:De(e=>e.instantType),isInstantPhase:De(e=>e.isInstantPhase),trackCursorAxis:De(e=>e.trackCursorAxis),disableHoverablePopup:De(e=>e.disableHoverablePopup),lastOpenChangeReason:De(e=>e.openChangeReason),closeOnClick:De(e=>e.closeOnClick),closeDelay:De(e=>e.closeDelay),hasViewport:De(e=>e.hasViewport)},gn=class e extends cn{constructor(t,r,o=!1){let n=new fo,s={...cw(),...t};s.floatingRootContext=jd(n,r,o),super(s,{popupRef:mp.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:n},lw)}setOpen=(t,r)=>{Fd(this,t,r,{extraState:{openChangeReason:r.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,je(_e.triggerPress,t))}static useStore(t,r){return kd(t,(n,s)=>new e(r,n,s)).store}};function cw(){return{...Bd(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,hasViewport:!1}}var di=h(Y(),1),hp=dl(function(t){let{disabled:r=!1,defaultOpen:o=!1,open:n,disableHoverablePopup:s=!1,trackCursorAxis:i="none",actionsRef:a,onOpenChange:u,onOpenChangeComplete:l,handle:c,triggerId:f,defaultTriggerId:m=null,children:g}=t,d=gn.useStore(c?.store,{open:o,openProp:n,activeTriggerId:m,triggerIdProp:f});Ad(d,n,o,m),d.useControlledProp("openProp",n),d.useControlledProp("triggerIdProp",f),d.useContextCallback("onOpenChange",u),d.useContextCallback("onOpenChangeComplete",l);let v=d.useState("open"),x=!r&&v,C=d.useState("activeTriggerId"),w=d.useState("mounted"),b=d.useState("payload");d.useSyncedValues({trackCursorAxis:i,disableHoverablePopup:s}),d.useSyncedValue("disabled",r),Ld(d,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:R,transitionStatus:A}=Nd(x,d),T=d.useState("isInstantPhase"),_=d.useState("instantType"),P=d.useState("lastOpenChangeReason"),N=Ar.useRef(null);ye(()=>{v&&r&&d.setOpen(!1,je(_e.disabled))},[v,r,d]),ye(()=>{A==="ending"&&P===_e.none||A!=="ending"&&T?(_!=="delay"&&(N.current=_),d.set("instantType","delay")):N.current!==null&&(d.set("instantType",N.current),N.current=null)},[A,T,P,_,d]),ye(()=>{x&&C==null&&d.set("payload",void 0)},[d,C,x]);let q=Ar.useCallback(()=>{d.setOpen(!1,je(_e.imperativeAction))},[d]);Ar.useImperativeHandle(a,()=>({unmount:R,close:q}),[R,q]);let H=x||w||!r&&i!=="none";return(0,di.jsxs)(Tl.Provider,{value:d,children:[H&&(0,di.jsx)(uw,{store:d,disabled:r,trackCursorAxis:i}),typeof g=="function"?g({payload:b}):g]})});function uw({store:e,disabled:t,trackCursorAxis:r}){let o=e.useState("floatingRootContext"),n=Ja(o,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),s=Ka(o,{enabled:!t&&r!=="none",axis:r==="none"?void 0:r}),i=Ar.useMemo(()=>er(s.reference,n.reference),[s.reference,n.reference]),a=Ar.useMemo(()=>er(s.trigger,n.trigger),[s.trigger,n.trigger]),u=Ar.useMemo(()=>er(Od,s.floating,n.floating),[s.floating,n.floating]);return Dd(e,{activeTriggerProps:i,inactiveTriggerProps:a,popupProps:u}),null}var mi=h(ge(),1);var pi=h(ge(),1),_l=pi.createContext(void 0);function gp(){return pi.useContext(_l)}var yp=(function(e){return e[e.popupOpen=os.popupOpen]="popupOpen",e.triggerDisabled="data-trigger-disabled",e})({});var bp="data-base-ui-tooltip-trigger";function vp(e){if("composedPath"in e){let r=e.composedPath();for(let o=0;ov.select("transitionStatus")==="ending",shouldOpen(){return!E.current}}),ie=yl(b,{enabled:!O}).reference,ve=Oe=>{let Ue=E.current,G=vp(Oe),z=se(G),X=R.current,U=X&&G&&Ze(X,G);if(z&&v.select("open")&&v.select("lastOpenChangeReason")===_e.triggerHover){v.setOpen(!1,je(_e.triggerHover,Oe));return}if(Ue&&!z&&U&&!D.current&&!v.select("open")&&X&&Gr($.current)){let K=()=>{!E.current&&!D.current&&!v.select("open")&&v.setOpen(!0,je(_e.triggerHover,Oe,X))},fe=F();fe===0?(L.clear(),K()):L.start(fe,K)}},Ee=v.useState("triggerProps",P);return Ht("button",t,{state:{open:w},ref:[r,_,R],props:[we,ie,P||J!=="none"?Ee:void 0,{onMouseOver(Oe){ve(Oe.nativeEvent)},onFocus(Oe){Z(vp(Oe.nativeEvent))&&Oe.preventBaseUIHandler()},onMouseLeave(){E.current=!1,L.clear(),$.current=void 0},onPointerEnter(Oe){$.current=Oe.pointerType},onPointerDown(Oe){$.current=Oe.pointerType,v.set("closeOnClick",c),c&&!v.select("open")&&v.cancelPendingOpen(Oe.nativeEvent)},onClick(Oe){c&&!v.select("open")&&v.cancelPendingOpen(Oe.nativeEvent)},id:x,[yp.triggerDisabled]:O?"":void 0,[bp]:O?void 0:""},g],stateAttributesMapping:Yd})});var Sp=h(ge(),1);var hi=h(ge(),1),Pl=hi.createContext(void 0);function xp(){let e=hi.useContext(Pl);if(e===void 0)throw new Error(Ut(70));return e}var Ol=h(Y(),1),Cp=Sp.forwardRef(function(t,r){let{keepMounted:o=!1,...n}=t;return ir().useState("mounted")||o?(0,Ol.jsx)(Pl.Provider,{value:o,children:(0,Ol.jsx)(pp,{ref:r,...n})}):null});var yi=h(ge(),1);var gi=h(ge(),1),kl=gi.createContext(void 0);function yn(){let e=gi.useContext(kl);if(e===void 0)throw new Error(Ut(71));return e}var Rp=h(Y(),1),Ep=yi.forwardRef(function(t,r){let{render:o,className:n,anchor:s,positionMethod:i="absolute",side:a="top",align:u="center",sideOffset:l=0,alignOffset:c=0,collisionBoundary:f="clipping-ancestors",collisionPadding:m=5,arrowPadding:g=5,sticky:d=!1,disableAnchorTracking:v=!1,collisionAvoidance:x=Af,style:C,...w}=t,b=ir(),R=xp(),A=b.useState("open"),T=b.useState("mounted"),_=b.useState("trackCursorAxis"),P=b.useState("disableHoverablePopup"),N=b.useState("floatingRootContext"),q=b.useState("instantType"),H=b.useState("transitionStatus"),S=b.useState("hasViewport"),I=ep({anchor:s,positionMethod:i,floatingRootContext:N,mounted:T,side:a,sideOffset:l,align:u,alignOffset:c,collisionBoundary:f,collisionPadding:m,sticky:d,arrowPadding:g,disableAnchorTracking:v,keepMounted:R,collisionAvoidance:x,adaptiveOrigin:S?Kd:void 0}),W=yi.useMemo(()=>({open:A,side:I.side,align:I.align,anchorHidden:I.anchorHidden,instant:_!=="none"?"tracking-cursor":q}),[A,I.side,I.align,I.anchorHidden,_,q]),O=tp(t,W,{styles:I.positionerStyles,transitionStatus:H,props:w,refs:[r,b.useStateSetter("positionerElement")],hidden:!T,inert:!A||_==="both"||P});return(0,Rp.jsx)(kl.Provider,{value:I,children:O})});var Tp=h(ge(),1);var dw={...pn,...rf},_p=Tp.forwardRef(function(t,r){let{render:o,className:n,style:s,...i}=t,a=ir(),{side:u,align:l}=yn(),c=a.useState("open"),f=a.useState("instantType"),m=a.useState("transitionStatus"),g=a.useState("popupProps"),d=a.useState("floatingRootContext"),v=a.useState("disabled"),x=a.useState("closeDelay");js({open:c,ref:a.context.popupRef,onComplete(){c&&a.context.onOpenChangeComplete?.(!0)}}),wl(d,{enabled:!v,closeDelay:x});let C=a.useStateSetter("popupElement");return Ht("div",t,{state:{open:c,side:u,align:l,instant:f,transitionStatus:m},ref:[r,a.context.popupRef,C],props:[g,ii(m),i],stateAttributesMapping:dw})});var Pp=h(ge(),1);var Op=Pp.forwardRef(function(t,r){let{render:o,className:n,style:s,...i}=t,a=ir(),{arrowRef:u,side:l,align:c,arrowUncentered:f,arrowStyles:m}=yn(),g=a.useState("open"),d=a.useState("instantType");return Ht("div",t,{state:{open:g,side:l,align:c,uncentered:f,instant:d},ref:[r,u],props:[{style:m,"aria-hidden":!0},i],stateAttributesMapping:pn})});var Fl=h(ge(),1);var Al=h(Y(),1),kp=function(t){let{delay:r,closeDelay:o,timeout:n=400}=t,s=Fl.useMemo(()=>({delay:r,closeDelay:o}),[r,o]),i=Fl.useMemo(()=>({open:r,close:o}),[r,o]);return(0,Al.jsx)(_l.Provider,{value:s,children:(0,Al.jsx)(qa,{delay:i,timeoutMs:n,children:t.children})})};var Ap=h(ge(),1);var Fp=(function(e){return e.popupWidth="--popup-width",e.popupHeight="--popup-height",e})({});var pw={activationDirection:e=>e?{"data-activation-direction":e}:null},Ip=Ap.forwardRef(function(t,r){let{render:o,className:n,style:s,children:i,...a}=t,u=ir(),l=yn(),c=u.useState("instantType"),{children:f,state:m}=up({store:u,side:l.side,cssVars:Fp,children:i}),g={activationDirection:m.activationDirection,transitioning:m.transitioning,instant:c};return Ht("div",t,{state:g,ref:r,props:[a,{children:f}],stateAttributesMapping:pw})});var ss=class{constructor(){this.store=new gn}open(t){let r=t?this.store.context.triggerElements.getById(t):void 0;if(t&&!r)throw new Error(Ut(81,t));this.store.setOpen(!0,je(_e.imperativeAction,void 0,r))}close(){this.store.setOpen(!1,je(_e.imperativeAction,void 0,void 0))}get isOpen(){return this.store.select("open")}};function Lp(){return new ss}function vn(e){return Ht(e.defaultTagName??"div",e,e)}var Mp=h(ke(),1),Il="data-wp-hash";function Ll(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&hw(document)),e.__wpStyleRuntime}function mw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Il}]`))if(r.getAttribute(Il)===t)return!0;return!1}function Vp(e,t,r){if(!e.head)return;let o=Ll(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(mw(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(Il,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function hw(e){let t=Ll();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Vp(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Bp(e,t){let r=Ll();r.styles.set(e,t);for(let o of r.documents.keys())Vp(o,e,t)}typeof process>"u",Bp("a495f9d138",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Np={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",Bp("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Dp={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},vi=(0,Mp.forwardRef)(function({variant:t="body-md",render:r,className:o,...n},s){return vn({render:r,defaultTagName:"span",ref:s,props:er(n,{className:st(Np.text,Dp.heading,Dp.p,Np[t],o)})})});var bi=h(ke(),1),is=(0,bi.forwardRef)(({icon:e,size:t=24,...r},o)=>(0,bi.cloneElement)(e,{width:t,height:t,...r,ref:o}));var wi=h(bn(),1),Nl=h(Y(),1),Do=(0,Nl.jsx)(wi.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Nl.jsx)(wi.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"})});var xi=h(bn(),1),Dl=h(Y(),1),Mo=(0,Dl.jsx)(xi.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Dl.jsx)(xi.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"})});var Si=h(bn(),1),Ml=h(Y(),1),Vl=(0,Ml.jsx)(Si.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Ml.jsx)(Si.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"})});var Ci=h(bn(),1),Bl=h(Y(),1),Ri=(0,Bl.jsx)(Ci.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Bl.jsx)(Ci.Path,{d:"M6.6 6L5.4 7l4.5 5-4.5 5 1.1 1 5.5-6-5.4-6zm6 0l-1.1 1 4.5 5-4.5 5 1.1 1 5.5-6-5.5-6z"})});var Ei=h(bn(),1),jl=h(Y(),1),Ti=(0,jl.jsx)(Ei.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,jl.jsx)(Ei.Path,{d:"M11.6 7l-1.1-1L5 12l5.5 6 1.1-1L7 12l4.6-5zm6 0l-1.1-1-5.5 6 5.5 6 1.1-1-4.6-5 4.6-5z"})});var Up=h(ke(),1);function zl(e,t,r){return(0,Up.cloneElement)(e??t,{children:r})}var gw=h(Wp(),1);var Yp=h(as(),1),{lock:CA,unlock:qp}=(0,Yp.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function yw(){let e=gw;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return qp(e.privateApis).ThemeProvider}var Zp=yw();var Xp=h(ke(),1),Ul="data-wp-hash";function Hl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&bw(document)),e.__wpStyleRuntime}function vw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Ul}]`))if(r.getAttribute(Ul)===t)return!0;return!1}function Kp(e,t,r){if(!e.head)return;let o=Hl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(vw(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(Ul,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function bw(e){let t=Hl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Kp(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function ww(e,t){let r=Hl();r.styles.set(e,t);for(let o of r.documents.keys())Kp(o,e,t)}typeof process>"u",ww("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var xw={stack:"_19ce0419607e1896__stack"},Sw={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},wn=(0,Xp.forwardRef)(function({direction:t,gap:r,align:o,justify:n,wrap:s,render:i,...a},u){let l={gap:r&&Sw[r],alignItems:o,justifyContent:n,flexDirection:t,flexWrap:s};return vn({render:i,ref:u,props:er(a,{style:l,className:xw.stack})})});var xn={};ro(xn,{Popup:()=>cm,Portal:()=>_i,Positioner:()=>Pi,Provider:()=>vm,Root:()=>gm,Trigger:()=>dm});var am=h(ke(),1);var tm=h(ke(),1);var Gl="data-wp-hash";function Yl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Rw(document)),e.__wpStyleRuntime}function Cw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Gl}]`))if(r.getAttribute(Gl)===t)return!0;return!1}function Qp(e,t,r){if(!e.head)return;let o=Yl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Cw(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(Gl,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function Rw(e){let t=Yl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Qp(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Ew(e,t){let r=Yl();r.styles.set(e,t);for(let o of r.documents.keys())Qp(o,e,t)}typeof process>"u",Ew("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var Jp={slot:"_11fc52b637ff8a7e__slot"},$p="data-wp-compat-overlay-slot";function Tw(){return typeof document>"u"?null:document}function _w(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var Ir=null;function Wl(e){return e.setAttribute("aria-hidden","false"),e}function Pw(e){let t=e.createElement("div");return t.setAttribute($p,""),Jp.slot&&t.classList.add(Jp.slot),e.body.appendChild(t),t}function em(){if(typeof window>"u"||!_w()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=Tw();if(!e||!e.body)return;if(Ir&&Ir.ownerDocument===e&&Ir.isConnected)return Wl(Ir);let t=e.querySelector(`[${$p}]`);return t instanceof HTMLDivElement?(Ir=Wl(t),Ir):(Ir?.isConnected&&Ir.remove(),Ir=Wl(Pw(e)),Ir)}var rm=h(Y(),1),_i=(0,tm.forwardRef)(function({container:t,...r},o){return(0,rm.jsx)(Zt.Portal,{container:t??em(),...r,ref:o})});var om=h(ke(),1),im=h(Y(),1),ql="data-wp-hash";function Zl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&kw(document)),e.__wpStyleRuntime}function Ow(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${ql}]`))if(r.getAttribute(ql)===t)return!0;return!1}function nm(e,t,r){if(!e.head)return;let o=Zl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Ow(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(ql,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function kw(e){let t=Zl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)nm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function sm(e,t){let r=Zl();r.styles.set(e,t);for(let o of r.documents.keys())nm(o,e,t)}typeof process>"u",sm("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Fw={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",sm("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Aw={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Pi=(0,om.forwardRef)(function({align:t="center",className:r,side:o="top",sideOffset:n=4,...s},i){return(0,im.jsx)(Zt.Positioner,{ref:i,align:t,side:o,sideOffset:n,...s,className:st(Fw["box-sizing"],Aw.positioner,r)})});var ls=h(Y(),1),Xl="data-wp-hash";function Kl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Lw(document)),e.__wpStyleRuntime}function Iw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Xl}]`))if(r.getAttribute(Xl)===t)return!0;return!1}function lm(e,t,r){if(!e.head)return;let o=Kl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Iw(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(Xl,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function Lw(e){let t=Kl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)lm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Nw(e,t){let r=Kl();r.styles.set(e,t);for(let o of r.documents.keys())lm(o,e,t)}typeof process>"u",Nw("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Dw={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Mw={background:"#1e1e1e"},cm=(0,am.forwardRef)(function({portal:t,positioner:r,children:o,className:n,...s},i){let a=(0,ls.jsx)(Zp,{color:Mw,children:(0,ls.jsx)(Zt.Popup,{ref:i,className:st(Dw.popup,n),...s,children:o})}),u=zl(r,(0,ls.jsx)(Pi,{}),a);return zl(t,(0,ls.jsx)(_i,{}),u)});var um=h(ke(),1),fm=h(Y(),1),dm=(0,um.forwardRef)(function(t,r){return(0,fm.jsx)(Zt.Trigger,{ref:r,...t})});var pm=h(xe(),1),mm=h(Y(),1);function hm({children:e}){return(0,mm.jsx)(ci,{direction:(0,pm.isRTL)()?"rtl":"ltr",children:e})}var Jl=h(Y(),1);function gm(e){return(0,Jl.jsx)(hm,{children:(0,Jl.jsx)(Zt.Root,{...e})})}var ym=h(Y(),1);function vm({...e}){return(0,ym.jsx)(Zt.Provider,{...e})}var wm=h(ke(),1),Ql="data-wp-hash";function $l(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Bw(document)),e.__wpStyleRuntime}function Vw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Ql}]`))if(r.getAttribute(Ql)===t)return!0;return!1}function xm(e,t,r){if(!e.head)return;let o=$l(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Vw(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(Ql,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function Bw(e){let t=$l();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)xm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Sm(e,t){let r=$l();r.styles.set(e,t);for(let o of r.documents.keys())xm(o,e,t)}typeof process>"u",Sm("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var jw={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Sm("ed2c39ec90","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.b20cc1690085c2f0__skeleton{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);display:block;@media (forced-colors:active){border:var(--wpds-border-width-xs,1px) solid CanvasText}}._9b143194fdb45f93__pulse{@media not (prefers-reduced-motion){animation:e2b9fe0690281bc8__skeleton-pulse 1.5s ease-in-out infinite}}@keyframes e2b9fe0690281bc8__skeleton-pulse{0%,to{opacity:1}50%{opacity:.4}}}}");var bm={skeleton:"b20cc1690085c2f0__skeleton",pulse:"_9b143194fdb45f93__pulse","skeleton-pulse":"e2b9fe0690281bc8__skeleton-pulse"},ec=(0,wm.forwardRef)(function({render:t,...r},o){return vn({render:t,ref:o,props:er({className:st(bm.skeleton,bm.pulse,jw["box-sizing"]),"aria-hidden":!0},r)})});var Cm=h(ke(),1),Rm=h(Y(),1),Em=(0,Cm.forwardRef)(({children:e,className:t,ariaLabel:r,as:o="div",...n},s)=>(0,Rm.jsx)(o,{ref:s,className:st("admin-ui-navigable-region",t),"aria-label":r,role:"region",tabIndex:"-1",...n,children:e}));Em.displayName="NavigableRegion";var Tm=Em;var Pm=h(ce(),1),{Fill:Om,Slot:km}=(0,Pm.createSlotFill)("SidebarToggle");var ar=h(Y(),1),tc="data-wp-hash";function rc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Uw(document)),e.__wpStyleRuntime}function zw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${tc}]`))if(r.getAttribute(tc)===t)return!0;return!1}function Fm(e,t,r){if(!e.head)return;let o=rc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(zw(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(tc,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function Uw(e){let t=rc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Fm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Hw(e,t){let r=rc();r.styles.set(e,t);for(let o of r.documents.keys())Fm(o,e,t)}typeof process>"u",Hw("ddd9aab364","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Vo={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function Am({headingLevel:e=1,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:s,actions:i,showSidebarToggle:a=!0}){let u=`h${e}`;return(0,ar.jsxs)(wn,{direction:"column",className:Vo.header,children:[(0,ar.jsxs)(wn,{className:Vo["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,ar.jsxs)(wn,{direction:"row",gap:"sm",align:"center",justify:"start",children:[a&&(0,ar.jsx)(km,{bubblesVirtually:!0,className:Vo["sidebar-toggle-slot"]}),o&&(0,ar.jsx)("div",{className:Vo["header-visual"],"aria-hidden":"true",children:o}),n&&(0,ar.jsx)(vi,{className:Vo["header-title"],render:(0,ar.jsx)(u,{}),variant:"heading-lg",children:n}),t,r]}),i&&(0,ar.jsx)(wn,{align:"center",className:Vo["header-actions"],direction:"row",gap:"sm",children:i})]}),s&&(0,ar.jsx)(vi,{render:(0,ar.jsx)("p",{}),variant:"body-md",className:Vo["header-subtitle"],children:s})]})}var cs=h(Y(),1),nc="data-wp-hash";function sc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Gw(document)),e.__wpStyleRuntime}function Ww(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${nc}]`))if(r.getAttribute(nc)===t)return!0;return!1}function Im(e,t,r){if(!e.head)return;let o=sc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Ww(e,t)){n.add(t);return}let s=e.createElement("style");s.setAttribute(nc,t),s.appendChild(e.createTextNode(r)),e.head.appendChild(s),n.add(t)}function Gw(e){let t=sc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Im(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Yw(e,t){let r=sc();r.styles.set(e,t);for(let o of r.documents.keys())Im(o,e,t)}typeof process>"u",Yw("ddd9aab364","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8113be94e7caf73c__header-title{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var oc={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function Lm({headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:s,children:i,className:a,actions:u,ariaLabel:l,hasPadding:c=!1,showSidebarToggle:f=!0}){let m=st(oc.page,a);return(0,cs.jsxs)(Tm,{className:m,ariaLabel:l??(typeof n=="string"?n:""),children:[(n||t||r||u||o)&&(0,cs.jsx)(Am,{headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:s,actions:u,showSidebarToggle:f}),c?(0,cs.jsx)("div",{className:st(oc.content,oc["has-padding"]),children:i}):i]})}Lm.SidebarToggleFill=Om;var ic=Lm;var jn=h(xe()),uv=h(ce()),fv=h(Dm()),wa=h(nr()),dv=h(Xt()),pv=h(ke());var av=h(ce(),1),lv=h(Sn(),1),D2=h(Xt(),1),M2=h(Dt(),1),wu=h(ke(),1),V2=h(No(),1);function Cn(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let s of t){let i=n[s];n=n[s]=Array.isArray(i)?[...i]:{...i}}return n[o]=r,e}var vt=(e,t,r)=>{let o=Array.isArray(t)?t:t.split("."),n=e;return o.forEach(s=>{n=n?.[s]}),n??r};var qw=["appearanceTools","useRootPaddingAwareAlignments","background.backgroundImage","background.backgroundRepeat","background.backgroundSize","background.backgroundPosition","background.gradient","border.color","border.radius","border.radiusSizes","border.style","border.width","shadow.presets","shadow.defaultPresets","color.background","color.button","color.caption","color.custom","color.customDuotone","color.customGradient","color.defaultDuotone","color.defaultGradients","color.defaultPalette","color.duotone","color.gradients","color.heading","color.link","color.palette","color.text","custom","dimensions.aspectRatio","dimensions.height","dimensions.minHeight","dimensions.minWidth","dimensions.width","dimensions.dimensionSizes","layout.contentSize","layout.definitions","layout.wideSize","lightbox.enabled","lightbox.allowEditing","position.fixed","position.sticky","spacing.customSpacingSize","spacing.defaultSpacingSizes","spacing.spacingSizes","spacing.spacingScale","spacing.blockGap","spacing.margin","spacing.padding","spacing.units","typography.fluid","typography.customFontSize","typography.defaultFontSizes","typography.dropCap","typography.fontFamilies","typography.fontSizes","typography.fontStyle","typography.fontWeight","typography.letterSpacing","typography.lineHeight","typography.textAlign","typography.textColumns","typography.textDecoration","typography.textIndent","typography.textTransform","typography.writingMode","viewport.mobile","viewport.tablet"];function ac(e,t,r){let o=r?".blocks."+r:"",n=t?"."+t:"",s=`settings${o}${n}`,i=`settings${n}`;if(t)return vt(e,s)??vt(e,i);let a={};return qw.forEach(u=>{let l=vt(e,`settings${o}.${u}`)??vt(e,`settings.${u}`);l!==void 0&&(a=Cn(a,u.split("."),l))}),a}function lc(e,t,r,o){let n=o?".blocks."+o:"",s=t?"."+t:"",i=`settings${n}${s}`;return Cn(e,i.split("."),r)}var Gm=h(Um(),1);var Zw="1600px",Xw="320px",Kw=1,Jw=.25,Qw=.75,$w="14px";function Hm({minimumFontSize:e,maximumFontSize:t,fontSize:r,minimumViewportWidth:o=Xw,maximumViewportWidth:n=Zw,scaleFactor:s=Kw,minimumFontSizeLimit:i}){if(i=Lr(i)?i:$w,r){let b=Lr(r);if(!b?.unit||!b?.value)return null;let R=Lr(i,{coerceTo:b.unit});if(R?.value&&!e&&!t&&b?.value<=R?.value)return null;if(t||(t=`${b.value}${b.unit}`),!e){let A=b.unit==="px"?b.value:b.value*16,T=Math.min(Math.max(1-.075*Math.log2(A),Jw),Qw),_=us(b.value*T,3);R?.value&&_0}function e1(e){let t=e?.typography??{},r=e?.layout,o=Lr(r?.wideSize)?r?.wideSize:null;return cc(t)&&o?{fluid:{maxViewportWidth:o,...typeof t.fluid=="object"?t.fluid:{}}}:{fluid:t?.fluid}}function Wm(e,t){let{size:r}=e;if(!r||r==="0"||e?.fluid===!1||!cc(t?.typography)&&!cc(e))return r;let o=e1(t)?.fluid??{},n=Hm({minimumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.min,maximumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.max,fontSize:r,minimumFontSizeLimit:typeof o=="object"?o?.minFontSize:void 0,maximumViewportWidth:typeof o=="object"?o?.maxViewportWidth:void 0,minimumViewportWidth:typeof o=="object"?o?.minViewportWidth:void 0});return n||r}var t1=[{path:["color","palette"],valueKey:"color",cssVarInfix:"color",classes:[{classSuffix:"color",propertyName:"color"},{classSuffix:"background-color",propertyName:"background-color"},{classSuffix:"border-color",propertyName:"border-color"}]},{path:["color","gradients"],valueKey:"gradient",cssVarInfix:"gradient",classes:[{classSuffix:"gradient-background",propertyName:"background"}]},{path:["color","duotone"],valueKey:"colors",cssVarInfix:"duotone",valueFunc:({slug:e})=>`url( '#wp-duotone-${e}' )`,classes:[]},{path:["shadow","presets"],valueKey:"shadow",cssVarInfix:"shadow",classes:[]},{path:["typography","fontSizes"],valueFunc:(e,t)=>Wm(e,t),valueKey:"size",cssVarInfix:"font-size",classes:[{classSuffix:"font-size",propertyName:"font-size"}]},{path:["typography","fontFamilies"],valueKey:"fontFamily",cssVarInfix:"font-family",classes:[{classSuffix:"font-family",propertyName:"font-family"}]},{path:["spacing","spacingSizes"],valueKey:"size",cssVarInfix:"spacing",valueFunc:({size:e})=>e,classes:[]},{path:["border","radiusSizes"],valueKey:"size",cssVarInfix:"border-radius",classes:[]},{path:["dimensions","dimensionSizes"],valueKey:"size",cssVarInfix:"dimension",classes:[]}];function r1(e,t){if(!e||!t)return e;if(typeof e=="object"&&"ref"in e&&e?.ref){let r=(0,Gm.getCSSValueFromRawStyle)(vt(t,e.ref));return typeof r=="object"&&r!==null&&"ref"in r&&r?.ref?void 0:r===void 0?e:r}return e}function o1(e,t){if(!e||!t||!Array.isArray(t))return e;let r=t.find(o=>o?.name===e);return r?.href?r?.href:e}function Ym(e,t){if(!e||!t)return e;let r=r1(e,t);return typeof r=="object"&&r!==null&&"url"in r&&r?.url&&(r.url=o1(r.url,t?._links?.["wp:theme-file"])),r}function qm(e,t,r=[],o="slug",n){let s=[t?vt(e,["blocks",t,...r]):void 0,vt(e,r)].filter(Boolean);for(let i of s)if(i){let a=["custom","theme","default"];for(let u of a){let l=i[u];if(l){let c=l.find(f=>f[o]===n);if(c)return o==="slug"||qm(e,t,r,"slug",c.slug)[o]===c[o]?c:void 0}}}}function n1(e,t,r,[o,n]=[]){let s=t1.find(a=>a.cssVarInfix===o);if(!s||!e.settings)return r;let i=qm(e.settings,t,s.path,"slug",n);if(i){let{valueKey:a}=s,u=i[a];return Oi(e,t,u)}return r}function s1(e,t,r,o=[]){let n=(t?vt(e?.settings??{},["blocks",t,"custom",...o]):void 0)??vt(e?.settings??{},["custom",...o]);return n?Oi(e,t,n):r}function Oi(e,t,r){if(!r||typeof r!="string")if(typeof r=="object"&&r!==null&&"ref"in r&&typeof r.ref=="string"){let l=vt(e,r.ref);if(!l||typeof l=="object"&&"ref"in l)return l;r=l}else return r;let o="var:",n="var(--wp--",s=")",i;if(r.startsWith(o))i=r.slice(o.length).split("|");else if(r.startsWith(n)&&r.endsWith(s))i=r.slice(n.length,-s.length).split("--");else return r;let[a,...u]=i;return a==="preset"?n1(e,t,r,u):a==="custom"?s1(e,t,r,u):r}function ki(e,t,r,o=!0){let n=t?"."+t:"",s=r?`styles.blocks.${r}${n}`:`styles${n}`;if(!e)return;let i=vt(e,s),a=void 0;if(i===void 0&&a){let l=!0,c=e;for(let f of s.split(".")){if(!c||typeof c!="object"||!Object.hasOwn(c,f)){l=!1;break}c=c[f]}l||(i=vt(e,a))}return o?Oi(e,r,i):i}function uc(e,t,r,o){let n=t?"."+t:"",s=o?`styles.blocks.${o}${n}`:`styles${n}`;return Cn(e,s.split("."),r)}var fc=h(Xm(),1);function fs(e,t){return typeof e!="object"||typeof t!="object"?e===t:(0,fc.default)(e?.styles,t?.styles)&&(0,fc.default)(e?.settings,t?.settings)}var rh=h($m(),1);function eh(e){return Object.prototype.toString.call(e)==="[object Object]"}function th(e){var t,r;return eh(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(eh(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}function Bo(e,t){return(0,rh.default)(e,t,{isMergeableObject:th,customMerge:r=>{if(r==="backgroundImage")return(o,n)=>n??o}})}var b1={grad:.9,turn:360,rad:360/(2*Math.PI)},Zr=function(e){return typeof e=="string"?e.length>0:typeof e=="number"},St=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=Math.pow(10,t)),Math.round(r*e)/r+0},cr=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=1),e>r?r:e>t?e:t},uh=function(e){return(e=isFinite(e)?e%360:0)>0?e:e+360},oh=function(e){return{r:cr(e.r,0,255),g:cr(e.g,0,255),b:cr(e.b,0,255),a:cr(e.a)}},dc=function(e){return{r:St(e.r),g:St(e.g),b:St(e.b),a:St(e.a,3)}},w1=/^#([0-9a-f]{3,8})$/i,Fi=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},fh=function(e){var t=e.r,r=e.g,o=e.b,n=e.a,s=Math.max(t,r,o),i=s-Math.min(t,r,o),a=i?s===t?(r-o)/i:s===r?2+(o-t)/i:4+(t-r)/i:0;return{h:60*(a<0?a+6:a),s:s?i/s*100:0,v:s/255*100,a:n}},dh=function(e){var t=e.h,r=e.s,o=e.v,n=e.a;t=t/360*6,r/=100,o/=100;var s=Math.floor(t),i=o*(1-r),a=o*(1-(t-s)*r),u=o*(1-(1-t+s)*r),l=s%6;return{r:255*[o,a,i,i,u,o][l],g:255*[u,o,o,a,i,i][l],b:255*[i,i,u,o,o,a][l],a:n}},nh=function(e){return{h:uh(e.h),s:cr(e.s,0,100),l:cr(e.l,0,100),a:cr(e.a)}},sh=function(e){return{h:St(e.h),s:St(e.s),l:St(e.l),a:St(e.a,3)}},ih=function(e){return dh((r=(t=e).s,{h:t.h,s:(r*=((o=t.l)<50?o:100-o)/100)>0?2*r/(o+r)*100:0,v:o+r,a:t.a}));var t,r,o},ps=function(e){return{h:(t=fh(e)).h,s:(n=(200-(r=t.s))*(o=t.v)/100)>0&&n<200?r*o/100/(n<=100?n:200-n)*100:0,l:n/2,a:t.a};var t,r,o,n},x1=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,S1=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,C1=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,R1=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,hc={string:[[function(e){var t=w1.exec(e);return t?(e=t[1]).length<=4?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:e.length===4?St(parseInt(e[3]+e[3],16)/255,2):1}:e.length===6||e.length===8?{r:parseInt(e.substr(0,2),16),g:parseInt(e.substr(2,2),16),b:parseInt(e.substr(4,2),16),a:e.length===8?St(parseInt(e.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(e){var t=C1.exec(e)||R1.exec(e);return t?t[2]!==t[4]||t[4]!==t[6]?null:oh({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:t[7]===void 0?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(e){var t=x1.exec(e)||S1.exec(e);if(!t)return null;var r,o,n=nh({h:(r=t[1],o=t[2],o===void 0&&(o="deg"),Number(r)*(b1[o]||1)),s:Number(t[3]),l:Number(t[4]),a:t[5]===void 0?1:Number(t[5])/(t[6]?100:1)});return ih(n)},"hsl"]],object:[[function(e){var t=e.r,r=e.g,o=e.b,n=e.a,s=n===void 0?1:n;return Zr(t)&&Zr(r)&&Zr(o)?oh({r:Number(t),g:Number(r),b:Number(o),a:Number(s)}):null},"rgb"],[function(e){var t=e.h,r=e.s,o=e.l,n=e.a,s=n===void 0?1:n;if(!Zr(t)||!Zr(r)||!Zr(o))return null;var i=nh({h:Number(t),s:Number(r),l:Number(o),a:Number(s)});return ih(i)},"hsl"],[function(e){var t=e.h,r=e.s,o=e.v,n=e.a,s=n===void 0?1:n;if(!Zr(t)||!Zr(r)||!Zr(o))return null;var i=(function(a){return{h:uh(a.h),s:cr(a.s,0,100),v:cr(a.v,0,100),a:cr(a.a)}})({h:Number(t),s:Number(r),v:Number(o),a:Number(s)});return dh(i)},"hsv"]]},ah=function(e,t){for(var r=0;r=.5},e.prototype.toHex=function(){return t=dc(this.rgba),r=t.r,o=t.g,n=t.b,i=(s=t.a)<1?Fi(St(255*s)):"","#"+Fi(r)+Fi(o)+Fi(n)+i;var t,r,o,n,s,i},e.prototype.toRgb=function(){return dc(this.rgba)},e.prototype.toRgbString=function(){return t=dc(this.rgba),r=t.r,o=t.g,n=t.b,(s=t.a)<1?"rgba("+r+", "+o+", "+n+", "+s+")":"rgb("+r+", "+o+", "+n+")";var t,r,o,n,s},e.prototype.toHsl=function(){return sh(ps(this.rgba))},e.prototype.toHslString=function(){return t=sh(ps(this.rgba)),r=t.h,o=t.s,n=t.l,(s=t.a)<1?"hsla("+r+", "+o+"%, "+n+"%, "+s+")":"hsl("+r+", "+o+"%, "+n+"%)";var t,r,o,n,s},e.prototype.toHsv=function(){return t=fh(this.rgba),{h:St(t.h),s:St(t.s),v:St(t.v),a:St(t.a,3)};var t},e.prototype.invert=function(){return lr({r:255-(t=this.rgba).r,g:255-t.g,b:255-t.b,a:t.a});var t},e.prototype.saturate=function(t){return t===void 0&&(t=.1),lr(pc(this.rgba,t))},e.prototype.desaturate=function(t){return t===void 0&&(t=.1),lr(pc(this.rgba,-t))},e.prototype.grayscale=function(){return lr(pc(this.rgba,-1))},e.prototype.lighten=function(t){return t===void 0&&(t=.1),lr(lh(this.rgba,t))},e.prototype.darken=function(t){return t===void 0&&(t=.1),lr(lh(this.rgba,-t))},e.prototype.rotate=function(t){return t===void 0&&(t=15),this.hue(this.hue()+t)},e.prototype.alpha=function(t){return typeof t=="number"?lr({r:(r=this.rgba).r,g:r.g,b:r.b,a:t}):St(this.rgba.a,3);var r},e.prototype.hue=function(t){var r=ps(this.rgba);return typeof t=="number"?lr({h:t,s:r.s,l:r.l,a:r.a}):St(r.h)},e.prototype.isEqual=function(t){return this.toHex()===lr(t).toHex()},e})(),lr=function(e){return e instanceof gc?e:new gc(e)},ch=[],ph=function(e){e.forEach(function(t){ch.indexOf(t)<0&&(t(gc,hc),ch.push(t))})};function T1(e=[]){let t={r:[],g:[],b:[],a:[]};return e.forEach(r=>{let o=lr(r).toRgb();t.r.push(o.r/255),t.g.push(o.g/255),t.b.push(o.b/255),t.a.push(o.a)}),t}function mh(e){return`${e}{filter:none}`}function hh(e,t){return`${e}{filter:url(#${t})}`}function gh(e,t){let r=T1(t);return` +var Uv=Object.create;var ka=Object.defineProperty;var Wv=Object.getOwnPropertyDescriptor;var Gv=Object.getOwnPropertyNames;var Yv=Object.getPrototypeOf,qv=Object.prototype.hasOwnProperty;var Wt=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var tt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),so=(e,t)=>{for(var r in t)ka(e,r,{get:t[r],enumerable:!0})},Zv=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Gv(t))!qv.call(e,n)&&n!==r&&ka(e,n,{get:()=>t[n],enumerable:!(o=Wv(t,n))||o.enumerable});return e};var f=(e,t,r)=>(r=e!=null?Uv(Yv(e)):{},Zv(t||!e||!e.__esModule?ka(r,"default",{value:e,enumerable:!0}):r,e));var ge=tt((ME,zu)=>{zu.exports=window.wp.i18n});var Te=tt((DE,Uu)=>{Uu.exports=window.wp.element});var ve=tt((BE,Wu)=>{Wu.exports=window.React});var Z=tt((YE,Zu)=>{Zu.exports=window.ReactJSXRuntime});var lo=tt((jT,wf)=>{wf.exports=window.ReactDOM});var xd=tt(wd=>{"use strict";var fn=ve();function Z0(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var X0=typeof Object.is=="function"?Object.is:Z0,K0=fn.useState,J0=fn.useEffect,Q0=fn.useLayoutEffect,$0=fn.useDebugValue;function ew(e,t){var r=t(),o=K0({inst:{value:r,getSnapshot:t}}),n=o[0].inst,i=o[1];return Q0(function(){n.value=r,n.getSnapshot=t,dl(n)&&i({inst:n})},[e,r,t]),J0(function(){return dl(n)&&i({inst:n}),e(function(){dl(n)&&i({inst:n})})},[e]),$0(r),r}function dl(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!X0(e,r)}catch{return!0}}function tw(e,t){return t()}var rw=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?tw:ew;wd.useSyncExternalStore=fn.useSyncExternalStore!==void 0?fn.useSyncExternalStore:rw});var ts=tt((FO,Sd)=>{"use strict";Sd.exports=xd()});var _d=tt(Cd=>{"use strict";var rs=ve(),ow=ts();function nw(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var iw=typeof Object.is=="function"?Object.is:nw,sw=ow.useSyncExternalStore,aw=rs.useRef,lw=rs.useEffect,cw=rs.useMemo,uw=rs.useDebugValue;Cd.useSyncExternalStoreWithSelector=function(e,t,r,o,n){var i=aw(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=cw(function(){function u(h){if(!l){if(l=!0,c=h,h=o(h),n!==void 0&&s.hasValue){var g=s.value;if(n(g,h))return m=g}return m=h}if(g=m,iw(c,h))return g;var b=o(h);return n!==void 0&&n(g,b)?(c=h,g):(c=h,m=b)}var l=!1,c,m,d=r===void 0?null:r;return[function(){return u(t())},d===null?void 0:function(){return u(d())}]},[t,r,o,n]);var a=sw(e,i[0],i[1]);return lw(function(){s.hasValue=!0,s.value=a},[a]),uw(a),a}});var Ed=tt((IO,Rd)=>{"use strict";Rd.exports=_d()});var xn=tt((B5,rm)=>{rm.exports=window.wp.primitives});var yo=tt((j5,om)=>{om.exports=window.wp.compose});var gm=tt((uA,hm)=>{hm.exports=window.wp.theme});var li=tt((fA,ym)=>{ym.exports=window.wp.privateApis});var ue=tt((w4,Jm)=>{Jm.exports=window.wp.components});var sh=tt((L4,ih)=>{ih.exports=window.wp.editor});var sr=tt((N4,ah)=>{ah.exports=window.wp.coreData});var Kt=tt((M4,lh)=>{lh.exports=window.wp.data});var _n=tt((V4,ch)=>{ch.exports=window.wp.blocks});var Dt=tt((D4,uh)=>{uh.exports=window.wp.blockEditor});var dh=tt((W4,fh)=>{fh.exports=window.wp.styleEngine});var bh=tt((rI,vh)=>{"use strict";vh.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var o,n,i;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;for(n of t.entries())if(!e(n[1],r.get(n[0])))return!1;return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(t[n]!==r[n])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),o=i.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[n]))return!1;for(n=o;n--!==0;){var s=i[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var Ch=tt((nI,Sh)=>{"use strict";var W1=function(t){return G1(t)&&!Y1(t)};function G1(e){return!!e&&typeof e=="object"}function Y1(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||X1(e)}var q1=typeof Symbol=="function"&&Symbol.for,Z1=q1?Symbol.for("react.element"):60103;function X1(e){return e.$$typeof===Z1}function K1(e){return Array.isArray(e)?[]:{}}function mi(e,t){return t.clone!==!1&&t.isMergeableObject(e)?En(K1(e),e,t):e}function J1(e,t,r){return e.concat(t).map(function(o){return mi(o,r)})}function Q1(e,t){if(!t.customMerge)return En;var r=t.customMerge(e);return typeof r=="function"?r:En}function $1(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function wh(e){return Object.keys(e).concat($1(e))}function xh(e,t){try{return t in e}catch{return!1}}function ex(e,t){return xh(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function tx(e,t,r){var o={};return r.isMergeableObject(e)&&wh(e).forEach(function(n){o[n]=mi(e[n],r)}),wh(t).forEach(function(n){ex(e,n)||(xh(e,n)&&r.isMergeableObject(t[n])?o[n]=Q1(n,r)(e[n],t[n],r):o[n]=mi(t[n],r))}),o}function En(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||J1,r.isMergeableObject=r.isMergeableObject||W1,r.cloneUnlessOtherwiseSpecified=mi;var o=Array.isArray(t),n=Array.isArray(e),i=o===n;return i?o?r.arrayMerge(e,t,r):tx(e,t,r):mi(t,r)}En.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(o,n){return En(o,n,r)},{})};var rx=En;Sh.exports=rx});var Qc=tt((JN,Ng)=>{Ng.exports=window.wp.keycodes});var Bg=tt((c8,Dg)=>{Dg.exports=window.wp.apiFetch});var Sv=tt((o7,xv)=>{xv.exports=window.wp.date});function Hu(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;te();function Pe(e){let t=Ct(Qv).current;return t.next=e,Jv(t.effect),t.trampoline}function Qv(){let e={next:void 0,callback:$v,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function $v(){}var qu=f(ve(),1),eb=()=>{},we=typeof document<"u"?qu.useLayoutEffect:eb;function tb(e,t){return function(o,...n){let i=new URL(e);return i.searchParams.set("code",o.toString()),n.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${o}; visit ${i} for the full message.`}}var rb=tb("https://base-ui.com/production-error","Base UI"),lr=rb;var Ao=f(ve(),1);function Aa(e,t,r,o){let n=Ct(Ku).current;return ob(n,e,t,r,o)&&Ju(n,[e,t,r,o]),n.callback}function Xu(e){let t=Ct(Ku).current;return nb(t,e)&&Ju(t,e),t.callback}function Ku(){return{callback:null,cleanup:null,refs:[]}}function ob(e,t,r,o,n){return e.refs[0]!==t||e.refs[1]!==r||e.refs[2]!==o||e.refs[3]!==n}function nb(e,t){return e.refs.length!==t.length||e.refs.some((r,o)=>r!==t[o])}function Ju(e,t){if(e.refs=t,t.every(r=>r==null)){e.callback=null;return}e.callback=r=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),r!=null){let o=Array(t.length).fill(null);for(let n=0;n{for(let n=0;n=e}function Ia(e){if(!$u.isValidElement(e))return null;let t=e,r=t.props;return(rn(19)?r?.ref:t.ref)??null}function Yn(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function tr(){}var ef=Object.freeze([]),nt=Object.freeze({});function tf(e,t){let r={};for(let o in e){let n=e[o];if(t?.hasOwnProperty(o)){let i=t[o](n);i!=null&&Object.assign(r,i);continue}n===!0?r[`data-${o.toLowerCase()}`]="":n&&(r[`data-${o.toLowerCase()}`]=n.toString())}return r}function rf(e,t){return typeof e=="function"?e(t):e}function of(e,t){return typeof e=="function"?e(t):e}var La={};function It(e,t,r,o,n){if(!r&&!o&&!n&&!e)return Ai(t);let i=Ai(e);return t&&(i=qn(i,t)),r&&(i=qn(i,r)),o&&(i=qn(i,o)),n&&(i=qn(i,n)),i}function nf(e){if(e.length===0)return La;if(e.length===1)return Ai(e[0]);let t=Ai(e[0]);for(let r=1;r=65&&n<=90&&(typeof t=="function"||typeof t>"u")}function Na(e){return typeof e=="function"}function af(e,t){return Na(e)?e(t):e??La}function lb(e,t){return t?e?(...r)=>{let o=r[0];if(uf(o)){let i=o;cf(i);let s=t(...r);return i.baseUIHandlerPrevented||e?.(...r),s}let n=t(...r);return e?.(...r),n}:lf(t):e}function lf(e){return e&&((...t)=>{let r=t[0];return uf(r)&&cf(r),e(...t)})}function cf(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Ma(e,t){return t?e?t+" "+e:t:e}function uf(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var Va=f(ve(),1);function Gt(e,t,r={}){let o=t.render,n=cb(t,r);if(r.enabled===!1)return null;let i=r.state??nt;return db(e,o,n,i)}function cb(e,t={}){let{className:r,style:o,render:n}=e,{state:i=nt,ref:s,props:a,stateAttributesMapping:u,enabled:l=!0}=t,c=l?rf(r,i):void 0,m=l?of(o,i):void 0,d=l?tf(i,u):nt,h=l&&a?ub(a):void 0,g=l?Yn(d,h)??{}:nt;return typeof document<"u"&&(l?Array.isArray(s)?g.ref=Xu([g.ref,Ia(n),...s]):g.ref=Aa(g.ref,Ia(n),s):Aa(null,null)),l?(c!==void 0&&(g.className=Ma(g.className,c)),m!==void 0&&(g.style=Yn(g.style,m)),g):nt}function ub(e){return Array.isArray(e)?nf(e):It(void 0,e)}var fb=Symbol.for("react.lazy");function db(e,t,r,o){if(t){if(typeof t=="function")return t(r,o);let n=It(r,t.props);n.ref=r.ref;let i=t;return i?.$$typeof===fb&&(i=Ao.Children.toArray(t)[0]),Ao.cloneElement(i,n)}if(e&&typeof e=="string")return pb(e,r);throw new Error(lr(8))}function pb(e,t){return e==="button"?(0,Va.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,Va.createElement)("img",{alt:"",...t,key:t.key}):Ao.createElement(e,t)}var Ii=f(ve(),1);var ff=0;function mb(e,t="mui"){let[r,o]=Ii.useState(e),n=e||r;return Ii.useEffect(()=>{r==null&&(ff+=1,o(`${t}-${ff}`))},[r,t]),n}var df=Gn.useId;function on(e,t){if(df!==void 0){let r=df();return e??(t?`${t}-${r}`:r)}return mb(e,t)}function pf(e){return on(e,"base-ui")}var Oe={};so(Oe,{cancelOpen:()=>Hb,chipRemovePress:()=>_b,clearPress:()=>Cb,closePress:()=>xb,closeWatcher:()=>Nb,decrementPress:()=>Tb,disabled:()=>Wb,drag:()=>Bb,escapeKey:()=>Lb,focusOut:()=>Ib,imperativeAction:()=>qb,incrementPress:()=>Eb,initial:()=>Yb,inputBlur:()=>kb,inputChange:()=>Pb,inputClear:()=>Ob,inputPaste:()=>Fb,inputPress:()=>Ab,itemPress:()=>wb,keyboard:()=>Vb,linkPress:()=>Sb,listNavigation:()=>Mb,missing:()=>Gb,none:()=>hb,outsidePress:()=>bb,pointer:()=>Db,scrub:()=>zb,siblingOpen:()=>Ub,swipe:()=>Zb,trackPress:()=>Rb,triggerFocus:()=>vb,triggerHover:()=>yb,triggerPress:()=>gb,wheel:()=>jb,windowResize:()=>Xb});var hb="none",gb="trigger-press",yb="trigger-hover",vb="trigger-focus",bb="outside-press",wb="item-press",xb="close-press",Sb="link-press",Cb="clear-press",_b="chip-remove-press",Rb="track-press",Eb="increment-press",Tb="decrement-press",Pb="input-change",Ob="input-clear",kb="input-blur",Fb="input-paste",Ab="input-press",Ib="focus-out",Lb="escape-key",Nb="close-watcher",Mb="list-navigation",Vb="keyboard",Db="pointer",Bb="drag",jb="wheel",zb="scrub",Hb="cancel-open",Ub="sibling-open",Wb="disabled",Gb="missing",Yb="initial",qb="imperative-action",Zb="swipe",Xb="window-resize";function De(e,t,r,o){let n=!1,i=!1,s=o??nt;return{reason:e,event:t??new Event("base-ui"),cancel(){n=!0},allowPropagation(){i=!0},get isCanceled(){return n},get isPropagationAllowed(){return i},trigger:r,...s}}var Ba=f(ve(),1);var mf=f(ve(),1);function nn(e){mf.useEffect(e,ef)}var Li=null,TT=globalThis.requestAnimationFrame,Da=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let r=this.callbacks,o=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,o>0)for(let n=0;n=this.callbacks.length||(this.callbacks[r]=null,this.callbacksCount-=1)}},Ni=new Da;var kr=class e{static create(){return new e}static request(t){return Ni.request(t)}static cancel(t){return Ni.cancel(t)}currentId=Li;request(t){this.cancel(),this.currentId=Ni.request(()=>{this.currentId=Li,t()})}cancel=()=>{this.currentId!==Li&&(Ni.cancel(this.currentId),this.currentId=Li)};disposeEffect=()=>this.cancel};function sn(){let e=Ct(kr.create).current;return nn(e.disposeEffect),e}function hf(e,t=!1,r=!1){let[o,n]=Ba.useState(e&&t?"idle":void 0),[i,s]=Ba.useState(e);return e&&!i&&(s(!0),n("starting")),!e&&i&&o!=="ending"&&!r&&n("ending"),!e&&!i&&o==="ending"&&n(void 0),we(()=>{if(!e&&i&&o!=="ending"&&r){let a=kr.request(()=>{n("ending")});return()=>{kr.cancel(a)}}},[e,i,o,r]),we(()=>{if(!e||t)return;let a=kr.request(()=>{n(void 0)});return()=>{kr.cancel(a)}},[t,e]),we(()=>{if(!e||!t)return;e&&i&&o!=="idle"&&n("starting");let a=kr.request(()=>{n("idle")});return()=>{kr.cancel(a)}},[t,e,i,o]),{mounted:i,setMounted:s,transitionStatus:o}}var ja=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),Kb={"data-starting-style":""},Jb={"data-ending-style":""},gf={transitionStatus(e){return e==="starting"?Kb:e==="ending"?Jb:null}};function Mi(){return typeof window<"u"}function Lo(e){return Vi(e)?(e.nodeName||"").toLowerCase():"#document"}function it(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ar(e){var t;return(t=(Vi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Vi(e){return Mi()?e instanceof Node||e instanceof it(e).Node:!1}function Re(e){return Mi()?e instanceof Element||e instanceof it(e).Element:!1}function _t(e){return Mi()?e instanceof HTMLElement||e instanceof it(e).HTMLElement:!1}function an(e){return!Mi()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof it(e).ShadowRoot}function Zn(e){let{overflow:t,overflowX:r,overflowY:o,display:n}=Lt(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+r)&&n!=="inline"&&n!=="contents"}function yf(e){return/^(table|td|th)$/.test(Lo(e))}function Xn(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var Qb=/transform|translate|scale|rotate|perspective|filter/,$b=/paint|layout|strict|content/,Io=e=>!!e&&e!=="none",za;function Di(e){let t=Re(e)?Lt(e):e;return Io(t.transform)||Io(t.translate)||Io(t.scale)||Io(t.rotate)||Io(t.perspective)||!Bi()&&(Io(t.backdropFilter)||Io(t.filter))||Qb.test(t.willChange||"")||$b.test(t.contain||"")}function vf(e){let t=Fr(e);for(;_t(t)&&!Ir(t);){if(Di(t))return t;if(Xn(t))return null;t=Fr(t)}return null}function Bi(){return za==null&&(za=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),za}function Ir(e){return/^(html|body|#document)$/.test(Lo(e))}function Lt(e){return it(e).getComputedStyle(e)}function Kn(e){return Re(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Fr(e){if(Lo(e)==="html")return e;let t=e.assignedSlot||e.parentNode||an(e)&&e.host||Ar(e);return an(t)?t.host:t}function bf(e){let t=Fr(e);return Ir(t)?(e.ownerDocument||e).body:_t(t)&&Zn(t)?t:bf(t)}function ao(e,t,r){var o;t===void 0&&(t=[]),r===void 0&&(r=!0);let n=bf(e),i=n===((o=e.ownerDocument)==null?void 0:o.body),s=it(n);if(i){let a=ji(s);return t.concat(s,s.visualViewport||[],Zn(n)?n:[],a&&r?ao(a):[])}else return t.concat(n,ao(n,[],r))}function ji(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Rt(e){return e?.ownerDocument||document}function ze(e,t,r,o){return e.addEventListener(t,r,o),()=>{e.removeEventListener(t,r,o)}}function Yt(e){let t=Ct(e0,e).current;return t.next=e,we(t.effect),t}function e0(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var Cf=f(ve(),1);var Sf=f(lo(),1);function xf(e){return e==null?e:"current"in e?e.current:e}function ln(e,t=!1){let r=sn();return Pe((o,n=null)=>{r.cancel();let i=xf(e);if(i==null)return;let s=i,a=()=>{Sf.flushSync(o)};if(typeof s.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){o();return}function u(){Promise.all(s.getAnimations().map(l=>l.finished)).then(()=>{n?.aborted||a()},()=>{if(n?.aborted)return;if(s.getAnimations().some(c=>c.pending||c.playState!=="finished")){u();return}a()})}if(t){let l="data-starting-style";if(!s.hasAttribute(l)){r.request(u);return}let c=new MutationObserver(()=>{s.hasAttribute(l)||(c.disconnect(),u())});c.observe(s,{attributes:!0,attributeFilter:[l]}),n?.addEventListener("abort",()=>c.disconnect(),{once:!0});return}r.request(u)})}function zi(e){let{enabled:t=!0,open:r,ref:o,onComplete:n}=e,i=Pe(n),s=ln(o,r);Cf.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,r,i,s])}var Zr={};so(Zr,{engine:()=>Ya,env:()=>Za,os:()=>Wa,screenReader:()=>qa});var Wa={};so(Wa,{android:()=>Ef,apple:()=>Ua,ios:()=>Ha,linux:()=>i0,mac:()=>Tf,windows:()=>n0});function t0(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:r0,platform:o0,maxTouchPoints:_f}=t0(),No=r0.toLowerCase(),Mo=o0.toLowerCase();var Ha=/^i(os$|p)/.test(Mo)||Mo==="macintel"&&_f>1,Rf="android",Ef=Mo===Rf||No.includes(Rf),Tf=!Ha&&Mo.startsWith("mac"),n0=Mo.startsWith("win"),i0=!Ef&&/^(linux|chrome os)/.test(Mo),Ua=Tf||Ha;var Ya={};so(Ya,{blink:()=>a0,gecko:()=>s0,webkit:()=>Ga});var Ga=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),s0=!Ga&&No.includes("firefox"),a0=!Ga&&No.includes("chrom");var qa={};so(qa,{voiceOver:()=>l0});var l0=Ua;var Za={};so(Za,{jsdom:()=>c0});var c0=/jsdom|happydom/.test(No);var Jn=0,rr=class e{static create(){return new e}currentId=Jn;start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Jn,r()},t)}isStarted(){return this.currentId!==Jn}clear=()=>{this.currentId!==Jn&&(clearTimeout(this.currentId),this.currentId=Jn)};disposeEffect=()=>this.clear};function xr(){let e=Ct(rr.create).current;return nn(e.disposeEffect),e}var Mt=f(ve(),1);function Pf(e){return"nativeEvent"in e}function Xr(e,t){let r=["mouse","pen"];return t||r.push("",void 0),r.includes(e)}function Of(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var Xa="data-base-ui-focusable";var Ka="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Hi(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function Ge(e,t){if(!e||!t)return!1;let r=t.getRootNode?.();if(e.contains(t))return!0;if(r&&an(r)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Nt(e){return"composedPath"in e?e.composedPath()[0]:e.target}function co(e,t){if(!Re(e))return!1;let r=e;if(t.hasElement(r))return!r.hasAttribute("data-trigger-disabled");for(let[,o]of t.entries())if(Ge(o,r))return!o.hasAttribute("data-trigger-disabled");return!1}function Ui(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let r=e;return r.target!=null&&t.contains(r.target)}function kf(e){return e.matches("html,body")}function Ff(e){return _t(e)&&e.matches(Ka)}function Ja(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${Ka}`)!=null}function Af(e){if(!e||Zr.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function u0(e,t){return t!=null&&!Xr(t)?0:typeof e=="function"?e():e}function cr(e,t,r){let o=u0(e,r);return typeof o=="number"?o:o?.[t]}function Qa(e){return typeof e=="function"?e():e}function Wi(e,t){return t||e==="click"||e==="mousedown"}function If(e){return e?.includes("mouse")&&e!=="mousedown"}var Lf=f(Z(),1),Nf=Mt.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new rr,currentIdRef:{current:null},currentContextRef:{current:null}});function f0(e,t){e.current=t.current}function $a(e){let{children:t,delay:r,timeoutMs:o=0}=e,n=Mt.useRef(r),i=Mt.useRef(r),s=Mt.useRef(null),a=Mt.useRef(null),u=xr();return we(()=>{if(i.current=r,!s.current){n.current=r;return}n.current={open:cr(n.current,"open"),close:cr(r,"close")}},[r,s,n,i]),(0,Lf.jsx)(Nf.Provider,{value:Mt.useMemo(()=>({hasProvider:!0,delayRef:n,initialDelayRef:i,currentIdRef:s,timeoutMs:o,currentContextRef:a,timeout:u}),[o,u]),children:t})}function el(e,t={open:!1}){let{open:r}=t,o="rootStore"in e?e.rootStore:e,n=o.useState("floatingId"),i=Mt.useContext(Nf),{currentIdRef:s,delayRef:a,timeoutMs:u,initialDelayRef:l,currentContextRef:c,hasProvider:m,timeout:d}=i,[h,g]=Mt.useState(!1),b=Mt.useRef(r);return we(()=>{b.current=r},[r]),we(()=>{function w(){c.current?.setIsInstantPhase(!1),s.current=null,c.current=null,a.current=l.current,d.clear()}if(s.current&&!r&&s.current===n){if(g(!1),u){let C=n;return d.start(u,()=>{o.select("open")||s.current&&s.current!==C||w()}),()=>{(b.current||s.current!==C)&&d.clear()}}w()}},[r,n,s,a,u,l,c,d,o]),we(()=>{if(!r)return;let w=c.current,C=s.current;d.clear(),c.current={onOpenChange:o.setOpen,setIsInstantPhase:g},s.current=n,a.current={open:0,close:cr(l.current,"close")},C!==null&&C!==n?(g(!0),w?.setIsInstantPhase(!0),w?.onOpenChange(!1,De(Oe.none))):(g(!1),w?.setIsInstantPhase(!1))},[r,n,o,s,a,l,c,d]),we(()=>()=>{if(s.current===n){if(c.current=null,!b.current)return;s.current=null,f0(a,l),d.clear()}},[c,s,a,n,l,d]),Mt.useMemo(()=>({hasProvider:m,delayRef:a,isInstantPhase:h}),[m,a,h])}function Sr(...e){return()=>{for(let t=0;t({x:e,y:e}),d0={left:"right",right:"left",bottom:"top",top:"bottom"};function Yi(e,t,r){return Cr(e,uo(t,r))}function Nr(e,t){return typeof e=="function"?e(t):e}function Tt(e){return e.split("-")[0]}function _r(e){return e.split("-")[1]}function qi(e){return e==="x"?"y":"x"}function ei(e){return e==="y"?"height":"width"}function qt(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function ti(e){return qi(qt(e))}function Df(e,t,r){r===void 0&&(r=!1);let o=_r(e),n=ti(e),i=ei(n),s=n==="x"?o===(r?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Qn(s)),[s,Qn(s)]}function Bf(e){let t=Qn(e);return[Gi(e),t,Gi(t)]}function Gi(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var Mf=["left","right"],Vf=["right","left"],p0=["top","bottom"],m0=["bottom","top"];function h0(e,t,r){switch(e){case"top":case"bottom":return r?t?Vf:Mf:t?Mf:Vf;case"left":case"right":return t?p0:m0;default:return[]}}function jf(e,t,r,o){let n=_r(e),i=h0(Tt(e),r==="start",o);return n&&(i=i.map(s=>s+"-"+n),t&&(i=i.concat(i.map(Gi)))),i}function Qn(e){let t=Tt(e);return d0[t]+e.slice(t.length)}function g0(e){var t,r,o,n;return{top:(t=e.top)!=null?t:0,right:(r=e.right)!=null?r:0,bottom:(o=e.bottom)!=null?o:0,left:(n=e.left)!=null?n:0}}function Zi(e){return typeof e!="number"?g0(e):{top:e,right:e,bottom:e,left:e}}function Vo(e){let{x:t,y:r,width:o,height:n}=e;return{width:o,height:n,top:r,left:t,right:t+o,bottom:r+n,x:t,y:r}}function Kr(e,t,r=!0){return e.filter(n=>n.parentId===t).flatMap(n=>[...!r||n.context?.open?[n]:[],...Kr(e,n.id,r)])}function cn(e){return`data-base-ui-${e}`}var Vt=f(ve(),1),Uf=f(lo(),1);var zf={style:{transition:"none"}};var y0="data-base-ui-swipe-ignore",v0="data-swipe-ignore",EP=`[${y0}]`,TP=`[${v0}]`;var Hf={fallbackAxisSide:"end"};var Wf=f(Z(),1),b0=Vt.createContext(null),w0=()=>Vt.useContext(b0),x0=cn("portal");function Gf(e={}){let{ref:t,container:r,componentProps:o=nt,elementProps:n}=e,i=on(),a=w0()?.portalNode,[u,l]=Vt.useState(null),[c,m]=Vt.useState(null),d=Pe(w=>{w!==null&&m(w)}),h=Vt.useRef(null);we(()=>{if(r===null){h.current&&(h.current=null,m(null),l(null));return}let w=(r&&(Vi(r)?r:r.current))??a??document.body;if(w==null){h.current&&(h.current=null,m(null),l(null));return}h.current!==w&&(h.current=w,m(null),l(w))},[r,a]);let g=Gt("div",o,{ref:[t,d],props:[{id:i,[x0]:""},n]}),b=u&&g?Uf.createPortal(g,u):null;return{node:c,nodeId:Vt.isValidElement(g)?g.props.id:void 0,subtree:b}}var Do=f(ve(),1);function Yf(){let e=new Map;return{emit(t,r){e.get(t)?.forEach(o=>o(r))},on(t,r){e.has(t)||e.set(t,new Set),e.get(t).add(r)},off(t,r){e.get(t)?.delete(r)}}}var S0=f(Z(),1),C0=Do.createContext(null),_0=Do.createContext(null),Xi=()=>Do.useContext(C0)?.id||null,po=e=>{let t=Do.useContext(_0);return e??t};var Zt=f(ve(),1);function R0(e,t){let r=null,o=null,n=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",u=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",l=i.width,c=i.height,m=i.x,d=i.y;return r==null&&t.x&&s&&(r=i.x-t.x),o==null&&t.y&&a&&(o=i.y-t.y),m-=r||0,d-=o||0,l=0,c=0,!n||u?(l=t.axis==="y"?i.width:0,c=t.axis==="x"?i.height:0,m=s&&t.x!=null?t.x:m,d=a&&t.y!=null?t.y:d):n&&!u&&(c=t.axis==="x"?i.height:c,l=t.axis==="y"?i.width:l),n=!0,{width:l,height:c,x:m,y:d,top:d,right:m+l,bottom:d+c,left:m}}}}function qf(e){return e!=null&&e.clientX!=null}function tl(e,t={}){let{enabled:r=!0,axis:o="both"}=t,n="rootStore"in e?e.rootStore:e,i=n.useState("open"),s=n.useState("floatingElement"),a=n.useState("domReferenceElement"),u=n.context.dataRef,l=Zt.useRef(!1),c=Zt.useRef(null),[m,d]=Zt.useState(),[h,g]=Zt.useState([]),b=Pe(_=>{n.set("positionReference",_)}),w=Pe((_,k,E)=>{l.current||u.current.openEvent&&!qf(u.current.openEvent)||n.set("positionReference",R0(E??a,{x:_,y:k,axis:o,dataRef:u,pointerType:m}))}),C=Pe(_=>{i?c.current||(w(_.clientX,_.clientY,_.currentTarget),g([])):w(_.clientX,_.clientY,_.currentTarget)}),x=Xr(m)?s:i;Zt.useEffect(()=>{if(!r){b(a);return}if(!x)return;function _(){c.current?.(),c.current=null}let k=it(s);function E(T){let O=Nt(T);Ge(s,O)?_():w(T.clientX,T.clientY)}return!u.current.openEvent||qf(u.current.openEvent)?c.current=ze(k,"mousemove",E):b(a),_},[x,r,s,u,a,n,w,b,h]),Zt.useEffect(()=>()=>{n.set("positionReference",null)},[n]),Zt.useEffect(()=>{r&&!s&&(l.current=!1)},[r,s]),Zt.useEffect(()=>{!r&&i&&(l.current=!0)},[r,i]);let v=Zt.useMemo(()=>{function _(k){d(k.pointerType)}return{onPointerDown:_,onPointerEnter:_,onMouseMove:C,onMouseEnter:C}},[C]);return Zt.useMemo(()=>r?{reference:v,trigger:v}:{},[r,v])}var or=f(ve(),1);function E0(){return!1}function T0(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function rl(e,t={}){let{enabled:r=!0,escapeKey:o=!0,outsidePress:n=!0,outsidePressEvent:i="sloppy",referencePress:s=E0,bubbles:a,externalTree:u}=t,l="rootStore"in e?e.rootStore:e,c=l.useState("open"),m=l.useState("floatingElement"),{dataRef:d}=l.context,h=po(u),g=Pe(typeof n=="function"?n:()=>!1),b=typeof n=="function"?g:n,w=b!==!1,C=Pe(()=>i),{escapeKey:x,outsidePress:v}=T0(a),_=or.useRef(!1),k=or.useRef(!1),E=or.useRef(!1),T=or.useRef(!1),O=or.useRef(""),I=or.useRef(null),J=xr(),D=xr(),S=Pe(()=>{D.clear(),d.current.insideReactTree=!1}),L=Pe(P=>{let W=d.current.floatingContext?.nodeId;return(h?Kr(h.nodesRef.current,W):[]).some(xe=>xe.context?.open&&!xe.context.dataRef.current[P])}),Y=Pe(P=>Ui(P,l.select("floatingElement"))||Ui(P,l.select("domReferenceElement"))),A=Pe(P=>{s()&&l.setOpen(!1,De(Oe.triggerPress,P.nativeEvent))}),N=Pe(P=>{if(!c||!r||!o||P.key!=="Escape"||T.current||!x&&L("__escapeKeyBubbles"))return;let W=Pf(P)?P.nativeEvent:P,ne=De(Oe.escapeKey,W);l.setOpen(!1,ne),ne.isCanceled||P.preventDefault(),!x&&!ne.isPropagationAllowed&&P.stopPropagation()}),q=Pe(()=>{d.current.insideReactTree=!0,D.start(0,S)}),U=Pe(P=>{if(!c||!r||P.button!==0)return;let W=Nt(P.nativeEvent);Ge(l.select("floatingElement"),W)&&(_.current||(_.current=!0,k.current=!1))}),R=Pe(P=>{!c||!r||(P.defaultPrevented||P.nativeEvent.defaultPrevented)&&_.current&&(k.current=!0)});or.useEffect(()=>{if(!c||!r)return S;d.current.__escapeKeyBubbles=x,d.current.__outsidePressBubbles=v;let P=new rr,W=new rr;function ne(){P.clear(),T.current=!0}function xe(){P.start(Zr.engine.webkit?5:0,()=>{T.current=!1})}function se(){E.current=!0,W.start(0,()=>{E.current=!1})}function be(){_.current=!1,k.current=!1}function ye(){let V=O.current,te=V==="pen"||!V?"mouse":V,Ne=C(),He=typeof Ne=="function"?Ne():Ne;return typeof He=="string"?He:He[te]}function $(V){let te=ye();return te==="intentional"&&V.type!=="click"||te==="sloppy"&&V.type==="click"}function _e(V){let te=d.current.floatingContext?.nodeId,Ne=h&&Kr(h.nodesRef.current,te).some(He=>Ui(V,He.context?.elements.floating));return Y(V)||Ne}function Fe(V){if($(V)){V.type!=="click"&&!Y(V)&&(W.clear(),E.current=!1),S();return}if(d.current.insideReactTree){S();return}let te=Nt(V),Ne=`[${cn("inert")}]`,He=Re(te)?te.getRootNode():null,ot=Array.from((an(He)?He:Rt(l.select("floatingElement"))).querySelectorAll(Ne)),Ze=l.context.triggerElements;if(te&&(Ze.hasElement(te)||Ze.hasMatchingElement(Ue=>Ge(Ue,te))))return;let Be=Re(te)?te:null;for(;Be&&!Ir(Be);){let Ue=Fr(Be);if(Ir(Ue)||!Re(Ue))break;Be=Ue}if(!(ot.length&&Re(te)&&!kf(te)&&!Ge(te,l.select("floatingElement"))&&ot.every(Ue=>!Ge(Be,Ue)))){if(_t(te)&&!("touches"in V)){let Ue=Ir(te),ct=Lt(te),Se=/auto|scroll/,Pr=Ue||Se.test(ct.overflowX),$t=Ue||Se.test(ct.overflowY),Ye=Pr&&te.clientWidth>0&&te.scrollWidth>te.clientWidth,Yr=$t&&te.clientHeight>0&&te.scrollHeight>te.clientHeight,St=ct.direction==="rtl",kt=Yr&&(St?V.offsetX<=te.offsetWidth-te.clientWidth:V.offsetX>te.clientWidth),vt=Ye&&V.offsetY>te.clientHeight;if(kt||vt)return}if(!_e(V)){if(ye()==="intentional"&&E.current){W.clear(),E.current=!1;return}typeof b=="function"&&!b(V)||L("__outsidePressBubbles")||(l.setOpen(!1,De(Oe.outsidePress,V)),S())}}}function xt(V){ye()!=="sloppy"||V.pointerType==="touch"||!l.select("open")||!r||Y(V)||Fe(V)}function Le(V){if(ye()!=="sloppy"||!l.select("open")||!r||Y(V))return;let te=V.touches[0];te&&(I.current={startTime:Date.now(),startX:te.clientX,startY:te.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},J.start(1e3,()=>{I.current&&(I.current.dismissOnTouchEnd=!1,I.current.dismissOnMouseDown=!1)}))}function X(V,te){let Ne=Nt(V);if(!Ne)return;let He=ze(Ne,V.type,()=>{te(V),He()})}function M(V){O.current="touch",X(V,Le)}function K(V){J.clear(),V.type==="pointerdown"&&(O.current=V.pointerType),!(V.type==="mousedown"&&I.current&&!I.current.dismissOnMouseDown)&&X(V,te=>{te.type==="pointerdown"?xt(te):Fe(te)})}function H(V){if(!_.current)return;let te=k.current;if(be(),ye()==="intentional"){if(V.type==="pointercancel"){te&&se();return}if(!_e(V)){if(te){se();return}typeof b=="function"&&!b(V)||(W.clear(),E.current=!0,S())}}}function Q(V){if(ye()!=="sloppy"||!I.current||Y(V))return;let te=V.touches[0];if(!te)return;let Ne=Math.abs(te.clientX-I.current.startX),He=Math.abs(te.clientY-I.current.startY),ot=Math.sqrt(Ne*Ne+He*He);ot>5&&(I.current.dismissOnTouchEnd=!0),ot>10&&(Fe(V),J.clear(),I.current=null)}function pe(V){X(V,Q)}function le(V){ye()!=="sloppy"||!I.current||Y(V)||(I.current.dismissOnTouchEnd&&Fe(V),J.clear(),I.current=null)}function fe(V){X(V,le)}let me=Rt(m),he=Sr(o&&Sr(ze(me,"keydown",N),ze(me,"compositionstart",ne),ze(me,"compositionend",xe)),w&&Sr(ze(me,"click",K,!0),ze(me,"pointerdown",K,!0),ze(me,"pointerup",H,!0),ze(me,"pointercancel",H,!0),ze(me,"mousedown",K,!0),ze(me,"mouseup",H,!0),ze(me,"touchstart",M,!0),ze(me,"touchmove",pe,!0),ze(me,"touchend",fe,!0)));return()=>{he(),P.clear(),W.clear(),be(),E.current=!1,S()}},[d,m,o,w,b,c,r,x,v,N,S,C,L,Y,h,l,J]);let B=or.useMemo(()=>({onKeyDown:N,onPointerDown:A,onClick:A}),[N,A]),re=or.useMemo(()=>({onKeyDown:N,onPointerDown:R,onMouseDown:R,onClickCapture:q,onMouseDownCapture(P){q(),U(P)},onPointerDownCapture(P){q(),U(P)},onMouseUpCapture:q,onTouchEndCapture:q,onTouchMoveCapture:q}),[N,q,U,R]);return or.useMemo(()=>r?{reference:B,floating:re,trigger:B}:{},[r,B,re])}var Pt=f(ve(),1);function Zf(e,t,r){let{reference:o,floating:n}=e,i=qt(t),s=ti(t),a=ei(s),u=Tt(t),l=i==="y",c=o.x+o.width/2-n.width/2,m=o.y+o.height/2-n.height/2,d=o[a]/2-n[a]/2,h;switch(u){case"top":h={x:c,y:o.y-n.height};break;case"bottom":h={x:c,y:o.y+o.height};break;case"right":h={x:o.x+o.width,y:m};break;case"left":h={x:o.x-n.width,y:m};break;default:h={x:o.x,y:o.y}}let g=_r(t);return g&&(h[s]+=d*(g==="end"?1:-1)*(r&&l?-1:1)),h}async function Xf(e,t){var r;t===void 0&&(t={});let{x:o,y:n,platform:i,rects:s,elements:a,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:m="floating",altBoundary:d=!1,padding:h=0}=Nr(t,e),g=Zi(h),w=a[d?m==="floating"?"reference":"floating":m],C=Vo(await i.getClippingRect({element:(r=await(i.isElement==null?void 0:i.isElement(w)))==null||r?w:w.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:l,rootBoundary:c,strategy:u})),x=m==="floating"?{x:o,y:n,width:s.floating.width,height:s.floating.height}:s.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),_=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},k=Vo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:x,offsetParent:v,strategy:u}):x);return{top:(C.top-k.top+g.top)/_.y,bottom:(k.bottom-C.bottom+g.bottom)/_.y,left:(C.left-k.left+g.left)/_.x,right:(k.right-C.right+g.right)/_.x}}var P0=50,Kf=async(e,t,r)=>{let{placement:o="bottom",strategy:n="absolute",middleware:i=[],platform:s}=r,a=s.detectOverflow?s:{...s,detectOverflow:Xf},u=await(s.isRTL==null?void 0:s.isRTL(t)),l=await s.getElementRects({reference:e,floating:t,strategy:n}),{x:c,y:m}=Zf(l,o,u),d=o,h=0,g={};for(let b=0;bY<=0)){var D,S;let Y=(((D=i.flip)==null?void 0:D.index)||0)+1,A=T[Y];if(A&&(!(m==="alignment"?x!==qt(A):!1)||J.every(U=>qt(U.placement)===x?U.overflows[0]>0:!0)))return{data:{index:Y,overflows:J},reset:{placement:A}};let N=(S=J.filter(q=>q.overflows[0]<=0).sort((q,U)=>q.overflows[1]-U.overflows[1])[0])==null?void 0:S.placement;if(!N)switch(h){case"bestFit":{var L;let q=(L=J.filter(U=>{if(E){let R=qt(U.placement);return R===x||R==="y"}return!0}).map(U=>[U.placement,U.overflows.filter(R=>R>0).reduce((R,B)=>R+B,0)]).sort((U,R)=>U[1]-R[1])[0])==null?void 0:L[0];q&&(N=q);break}case"initialPlacement":N=a;break}if(n!==N)return{reset:{placement:N}}}return{}}}};var Qf=new Set(["left","top"]);async function O0(e,t){let{placement:r,platform:o,elements:n}=e,i=await(o.isRTL==null?void 0:o.isRTL(n.floating)),s=Tt(r),a=_r(r),u=qt(r)==="y",l=Qf.has(s)?-1:1,c=i&&u?-1:1,m=Nr(t,e),{mainAxis:d,crossAxis:h,alignmentAxis:g}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return a&&typeof g=="number"&&(h=a==="end"?g*-1:g),u?{x:h*c,y:d*l}:{x:d*l,y:h*c}}var $f=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,o;let{x:n,y:i,placement:s,middlewareData:a}=t,u=await O0(t,e);return s===((r=a.offset)==null?void 0:r.placement)&&(o=a.arrow)!=null&&o.alignmentOffset?{}:{x:n+u.x,y:i+u.y,data:{...u,placement:s}}}}},ed=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:r,y:o,placement:n,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:u={fn:x=>{let{x:v,y:_}=x;return{x:v,y:_}}},...l}=Nr(e,t),c={x:r,y:o},m=await i.detectOverflow(t,l),d=qt(n),h=qi(d),g=c[h],b=c[d],w=(x,v)=>Yi(v+m[x==="y"?"top":"left"],v,v-m[x==="y"?"bottom":"right"]);s&&(g=w(h,g)),a&&(b=w(d,b));let C=u.fn({...t,[h]:g,[d]:b});return{...C,data:{x:C.x-r,y:C.y-o,enabled:{[h]:s,[d]:a}}}}}},td=function(e){return e===void 0&&(e={}),{options:e,fn(t){var r,o;let{x:n,y:i,placement:s,rects:a,middlewareData:u}=t,{offset:l=0,mainAxis:c=!0,crossAxis:m=!0}=Nr(e,t),d={x:n,y:i},h=qt(s),g=qi(h),b=d[g],w=d[h],C=Nr(l,t),x=typeof C=="number"?{mainAxis:C,crossAxis:0}:{mainAxis:(r=C.mainAxis)!=null?r:0,crossAxis:(o=C.crossAxis)!=null?o:0};if(c){let k=g==="y"?"height":"width",E=a.reference[g]-a.floating[k]+x.mainAxis,T=a.reference[g]+a.reference[k]-x.mainAxis;bT&&(b=T)}if(m){var v,_;let k=g==="y"?"width":"height",E=Qf.has(Tt(s)),T=a.reference[h]-a.floating[k]+(E&&((v=u.offset)==null?void 0:v[h])||0)+(E?0:x.crossAxis),O=a.reference[h]+a.reference[k]+(E?0:((_=u.offset)==null?void 0:_[h])||0)-(E?x.crossAxis:0);wO&&(w=O)}return{[g]:b,[h]:w}}}},rd=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:r,rects:o,platform:n,elements:i}=t,{apply:s=()=>{},...a}=Nr(e,t),u=await n.detectOverflow(t,a),l=Tt(r),c=_r(r),m=qt(r)==="y",{width:d,height:h}=o.floating,g,b;l==="top"||l==="bottom"?(g=l,b=c===(await(n.isRTL==null?void 0:n.isRTL(i.floating))?"start":"end")?"left":"right"):(b=l,g=c==="end"?"top":"bottom");let w=h-u.top-u.bottom,C=d-u.left-u.right,x=uo(h-u[g],w),v=uo(d-u[b],C),_=t.middlewareData.shift,k=!_,E=x,T=v;_!=null&&_.enabled.x&&(T=C),_!=null&&_.enabled.y&&(E=w),k&&!c&&(m?T=d-2*Cr(u.left,u.right):E=h-2*Cr(u.top,u.bottom)),await s({...t,availableWidth:T,availableHeight:E});let O=await n.getDimensions(i.floating);return d!==O.width||h!==O.height?{reset:{rects:!0}}:{}}}};function id(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=_t(e),i=n?e.offsetWidth:r,s=n?e.offsetHeight:o,a=fo(r)!==i||fo(o)!==s;return a&&(r=i,o=s),{width:r,height:o,$:a}}function nl(e){return Re(e)?e:e.contextElement}function un(e){let t=nl(e);if(!_t(t))return Lr(1);let r=t.getBoundingClientRect(),{width:o,height:n,$:i}=id(t),s=(i?fo(r.width):r.width)/o,a=(i?fo(r.height):r.height)/n;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var k0=Lr(0);function sd(e){let t=it(e);return!Bi()||!t.visualViewport?k0:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function F0(e,t,r){return t===void 0&&(t=!1),!!r&&t&&r===it(e)}function Bo(e,t,r,o){t===void 0&&(t=!1),r===void 0&&(r=!1);let n=e.getBoundingClientRect(),i=nl(e),s=Lr(1);t&&(o?Re(o)&&(s=un(o)):s=un(e));let a=F0(i,r,o)?sd(i):Lr(0),u=(n.left+a.x)/s.x,l=(n.top+a.y)/s.y,c=n.width/s.x,m=n.height/s.y;if(i&&o){let d=it(i),h=Re(o)?it(o):o,g=d,b=ji(g);for(;b&&h!==g;){let w=un(b),C=b.getBoundingClientRect(),x=Lt(b),v=C.left+(b.clientLeft+parseFloat(x.paddingLeft))*w.x,_=C.top+(b.clientTop+parseFloat(x.paddingTop))*w.y;u*=w.x,l*=w.y,c*=w.x,m*=w.y,u+=v,l+=_,g=it(b),b=ji(g)}}return Vo({width:c,height:m,x:u,y:l})}function Ki(e,t){let r=Kn(e).scrollLeft;return t?t.left+r:Bo(Ar(e)).left+r}function ad(e,t){let r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-Ki(e,r),n=r.top+t.scrollTop;return{x:o,y:n}}function A0(e){let{elements:t,rect:r,offsetParent:o,strategy:n}=e,i=n==="fixed",s=Ar(o),a=t?Xn(t.floating):!1;if(o===s||a&&i)return r;let u={scrollLeft:0,scrollTop:0},l=Lr(1),c=Lr(0),m=_t(o);if((m||!i)&&((Lo(o)!=="body"||Zn(s))&&(u=Kn(o)),m)){let h=Bo(o);l=un(o),c.x=h.x+o.clientLeft,c.y=h.y+o.clientTop}let d=s&&!m&&!i?ad(s,u):Lr(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-u.scrollLeft*l.x+c.x+d.x,y:r.y*l.y-u.scrollTop*l.y+c.y+d.y}}function I0(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function L0(e){let t=Kn(e),r=e.ownerDocument.body,o=Cr(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),n=Cr(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight),i=-t.scrollLeft+Ki(e),s=-t.scrollTop;return Lt(r).direction==="rtl"&&(i+=Cr(e.clientWidth,r.clientWidth)-o),{width:o,height:n,x:i,y:s}}var N0=25;function M0(e,t,r){r===void 0&&(r="viewport");let o=r==="layoutViewport",n=it(e),i=Ar(e),s=n.visualViewport,a=i.clientWidth,u=i.clientHeight,l=0,c=0;if(s){let d=!Bi()||t==="fixed";o?d||(l=-s.offsetLeft,c=-s.offsetTop):(a=s.width,u=s.height,d&&(l=s.offsetLeft,c=s.offsetTop))}if(Ki(i)<=0){let d=i.ownerDocument,h=d.body,g=getComputedStyle(h),b=d.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,w=Math.abs(i.clientWidth-h.clientWidth-b),C=getComputedStyle(i).scrollbarGutter==="stable both-edges"?w/2:w;C<=N0&&(a-=C)}return{width:a,height:u,x:l,y:c}}function V0(e,t){let r=Bo(e,!0,t==="fixed"),o=r.top+e.clientTop,n=r.left+e.clientLeft,i=un(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,u=n*i.x,l=o*i.y;return{width:s,height:a,x:u,y:l}}function od(e,t,r){let o;if(t==="viewport"||t==="layoutViewport")o=M0(e,r,t);else if(t==="document")o=L0(Ar(e));else if(Re(t))o=V0(t,r);else{let n=sd(e);o={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Vo(o)}function D0(e,t){let r=t.get(e);if(r)return r;let o=ao(e,[],!1).filter(a=>Re(a)&&Lo(a)!=="body"),n=null,i=Lt(e).position==="fixed",s=i?Fr(e):e;for(;Re(s)&&!Ir(s);){let a=Lt(s),u=Di(s),l=n?n.position:i?"fixed":"";!u&&(l==="fixed"||l==="absolute"&&a.position==="static")?o=o.filter(m=>m!==s):n=a,s=Fr(s)}return t.set(e,o),o}function B0(e){let{element:t,boundary:r,rootBoundary:o,strategy:n}=e,s=[...r==="clippingAncestors"?Xn(t)?[]:D0(t,this._c):[].concat(r),o],a=od(t,s[0],n),u=a.top,l=a.right,c=a.bottom,m=a.left;for(let d=1;d{a(!1,1e-7)},1e3)}T=!1}try{o=new IntersectionObserver(O,{...E,root:i.ownerDocument})}catch{o=new IntersectionObserver(O,E)}o.observe(e)}let u=it(e),l=()=>a(r);return u.addEventListener("resize",l),a(!0),()=>{u.removeEventListener("resize",l),s()}}function ri(e,t,r,o){o===void 0&&(o={});let{ancestorScroll:n=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:u=!1}=o,l=nl(e),c=n||i?[...l?ao(l):[],...t?ao(t):[]]:[];c.forEach(C=>{n&&C.addEventListener("scroll",r),i&&C.addEventListener("resize",r)});let m=l&&a?W0(l,r,i):null,d=-1,h=null;s&&(h=new ResizeObserver(C=>{let[x]=C;x&&x.target===l&&h&&t&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var v;(v=h)==null||v.observe(t)})),r()}),l&&!u&&h.observe(l),t&&h.observe(t));let g,b=u?Bo(e):null;u&&w();function w(){let C=Bo(e);b&&!cd(b,C)&&r(),b=C,g=requestAnimationFrame(w)}return r(),()=>{var C;c.forEach(x=>{n&&x.removeEventListener("scroll",r),i&&x.removeEventListener("resize",r)}),m?.(),(C=h)==null||C.disconnect(),h=null,u&&cancelAnimationFrame(g)}}var ud=$f;var fd=ed,dd=Jf,pd=rd;var md=td,Ji=(e,t,r)=>{let o=new Map,n=r??{},i={...il,...n.platform,_c:o};return Kf(e,t,{...n,platform:i})};var mt=f(ve(),1),gd=f(ve(),1),yd=f(lo(),1),Y0=typeof document<"u",q0=function(){},Qi=Y0?gd.useLayoutEffect:q0;function $i(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,o,n;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(o=r;o--!==0;)if(!$i(e[o],t[o]))return!1;return!0}if(n=Object.keys(e),r=n.length,r!==Object.keys(t).length)return!1;for(o=r;o--!==0;)if(!{}.hasOwnProperty.call(t,n[o]))return!1;for(o=r;o--!==0;){let i=n[o];if(!(i==="_owner"&&e.$$typeof)&&!$i(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function vd(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function hd(e,t){let r=vd(e);return Math.round(t*r)/r}function sl(e){let t=mt.useRef(e);return Qi(()=>{t.current=e}),t}function bd(e){e===void 0&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:o=[],platform:n,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:u,open:l}=e,[c,m]=mt.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[d,h]=mt.useState(o);$i(d,o)||h(o);let[g,b]=mt.useState(null),[w,C]=mt.useState(null),x=mt.useCallback(U=>{U!==E.current&&(E.current=U,b(U))},[]),v=mt.useCallback(U=>{U!==T.current&&(T.current=U,C(U))},[]),_=i||g,k=s||w,E=mt.useRef(null),T=mt.useRef(null),O=mt.useRef(c),I=u!=null,J=sl(u),D=sl(n),S=sl(l),L=mt.useCallback(()=>{if(!E.current||!T.current)return;let U={placement:t,strategy:r,middleware:d};D.current&&(U.platform=D.current),Ji(E.current,T.current,U).then(R=>{let B={...R,isPositioned:S.current!==!1};Y.current&&!$i(O.current,B)&&(O.current=B,yd.flushSync(()=>{m(B)}))})},[d,t,r,D,S]);Qi(()=>{l===!1&&O.current.isPositioned&&(O.current.isPositioned=!1,m(U=>({...U,isPositioned:!1})))},[l]);let Y=mt.useRef(!1);Qi(()=>(Y.current=!0,()=>{Y.current=!1}),[]),Qi(()=>{if(_&&(E.current=_),k&&(T.current=k),_&&k){if(J.current)return J.current(_,k,L);L()}},[_,k,L,J,I]);let A=mt.useMemo(()=>({reference:E,floating:T,setReference:x,setFloating:v}),[x,v]),N=mt.useMemo(()=>({reference:_,floating:k}),[_,k]),q=mt.useMemo(()=>{let U={position:r,left:0,top:0};if(!N.floating)return U;let R=hd(N.floating,c.x),B=hd(N.floating,c.y);return a?{...U,transform:"translate("+R+"px, "+B+"px)",...vd(N.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:R,top:B}},[r,a,N.floating,c.x,c.y]);return mt.useMemo(()=>({...c,update:L,refs:A,elements:N,floatingStyles:q}),[c,L,A,N,q])}var al=(e,t)=>{let r=ud(e);return{name:r.name,fn:r.fn,options:[e,t]}},ll=(e,t)=>{let r=fd(e);return{name:r.name,fn:r.fn,options:[e,t]}},cl=(e,t)=>({fn:md(e).fn,options:[e,t]}),ul=(e,t)=>{let r=dd(e);return{name:r.name,fn:r.fn,options:[e,t]}},fl=(e,t)=>{let r=pd(e);return{name:r.name,fn:r.fn,options:[e,t]}};var es=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,r,o=!0){this.fallbackStore=t,this.componentName=r,this.throwOnMissingTrigger=o}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let r=this.attachedStores.lastIndexOf(t);r!==-1&&this.attachedStores.splice(r,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(r=>{r()}))}openByTrigger(t){let r=this.attachedStore;if(r===null)return;let o;if(t){for(let n=this.attachedStores.length-1;n>=0&&!o;n-=1)o=this.attachedStores[n].context.triggerElements.getById(t);o??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!o&&this.throwOnMissingTrigger)throw new Error(lr(99,this.componentName,t,this.componentName));r.setOpen(!0,De(Oe.imperativeAction,void 0,o))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,De(Oe.imperativeAction))}};var zo=f(ve(),1),Nd=f(lo(),1);var Id=f(ve(),1);var Fd=f(ve(),1),gl=f(ts(),1),Ad=f(Ed(),1);var Td=f(ve(),1);var pl=[],ml;function Pd(){return ml}function Od(e){pl.push(e)}function hl(e){let t=(r,o)=>{let n=Ct(fw).current,i;try{ml=n;for(let s of pl)s.before(n);i=e(r,o);for(let s of pl)s.after(n);n.didInitialize=!0}finally{ml=void 0}return i};return t.displayName=e.displayName||e.name,t}function kd(e){return Td.forwardRef(hl(e))}function fw(){return{didInitialize:!1}}var dw=rn(19),pw=dw?hw:gw;function os(e,t,r,o,n){return pw(e,t,r,o,n)}function mw(e,t,r,o,n){let i=Fd.useCallback(()=>t(e.getSnapshot(),r,o,n),[e,t,r,o,n]);return(0,gl.useSyncExternalStore)(e.subscribe,i,i)}Od({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let r=0;r0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let r=new Set;for(let n of e.syncHooks)r.add(n.store);let o=[];for(let n of r)o.push(n.subscribe(t));return()=>{for(let n of o)n()}}),(0,gl.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function hw(e,t,r,o,n){let i=Pd();if(!i)return mw(e,t,r,o,n);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,r)||!Object.is(a.a2,o)||!Object.is(a.a3,n))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=r,a.a2=o,a.a3=n,a.value=t(e.getSnapshot(),r,o,n))):(a={store:e,selector:t,a1:r,a2:o,a3:n,value:t(e.getSnapshot(),r,o,n)},i.syncHooks.push(a)),a.value}function gw(e,t,r,o,n){return(0,Ad.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,r,o,n))}var ns=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let r=this.updateTick;for(let o of this.listeners){if(r!==this.updateTick)return;o(t)}}update(t){for(let r in t)if(!Object.is(this.state[r],t[r])){this.setState({...this.state,...t});return}}set(t,r){Object.is(this.state[t],r)||this.setState({...this.state,[t]:r})}notifyAll(){let t={...this.state};this.setState(t)}use(t,r,o,n){return os(this,t,r,o,n)}};var jo=f(ve(),1);var mo=class extends ns{constructor(t,r={},o){super(t),this.context=r,this.selectors=o}useSyncedValue(t,r){jo.useDebugValue(t);let o=this;we(()=>{o.state[t]!==r&&o.set(t,r)},[o,t,r])}useSyncedValueWithCleanup(t,r){let o=this;we(()=>(o.state[t]!==r&&o.set(t,r),()=>{o.set(t,void 0)}),[o,t,r])}useSyncedValues(t){let r=this,o=Object.values(t);we(()=>{r.update(t)},[r,...o])}useControlledProp(t,r){jo.useDebugValue(t);let o=this,n=r!==void 0;we(()=>{n&&!Object.is(o.state[t],r)&&o.setState({...o.state,[t]:r})},[o,t,r,n])}select(t,r,o,n){let i=this.selectors[t];return i(this.state,r,o,n)}useState(t,r,o,n){return jo.useDebugValue(t),os(this,this.selectors[t],r,o,n)}useContextCallback(t,r){jo.useDebugValue(t);let o=Pe(r??tr);this.context[t]=o}useStateSetter(t){let r=jo.useRef(void 0);return r.current===void 0&&(r.current=o=>{this.set(t,o)}),r.current}observe(t,r){let o;typeof t=="function"?o=t:o=this.selectors[t];let n=o(this.state);return r(n,n,this),this.subscribe(i=>{let s=o(i);if(!Object.is(n,s)){let a=n;n=s,r(s,a,this)}})}};var yw={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},ho=class extends mo{constructor(t){let{syncOnly:r,nested:o,onOpenChange:n,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:n,dataRef:{current:{}},events:Yf(),nested:o,triggerElements:i},yw),this.syncOnly=r}syncOpenEvent=(t,r)=>{(!t||!this.state.open||r!=null&&Of(r))&&(this.context.dataRef.current.openEvent=t?r:void 0)};dispatchOpenChange=(t,r)=>{this.syncOpenEvent(t,r.event);let o={open:t,reason:r.reason,nativeEvent:r.event,nested:this.context.nested,triggerElement:r.trigger};this.context.events.emit("openchange",o)};setOpen=(t,r)=>{if(this.syncOnly){this.context.onOpenChange?.(t,r);return}this.dispatchOpenChange(t,r),this.context.onOpenChange?.(t,r)}};function Ld(e){let{popupStore:t,treatPopupAsFloatingElement:r=!1,floatingRootContext:o,floatingId:n,nested:i,onOpenChange:s}=e,a=t.useState("open"),u=t.useState("activeTriggerElement"),l=t.useState(r?"popupElement":"positionerElement"),c=t.context.triggerElements,m=s,d=Id.useRef(null);o===void 0&&d.current===null&&(d.current=new ho({open:a,transitionStatus:void 0,referenceElement:u,floatingElement:l,triggerElements:c,onOpenChange:m,floatingId:n,syncOnly:!0,nested:i}));let h=o??d.current;return t.useSyncedValue("floatingId",n),we(()=>{let g={open:a,floatingId:n,referenceElement:u,floatingElement:l};Re(u)&&(g.domReferenceElement=u),h.state.positionReference===h.state.referenceElement&&(g.positionReference=u),h.update(g)},[a,n,u,l,h]),h.context.onOpenChange=m,h.context.nested=i,h}var Md={tabIndex:-1,[Xa]:""};function Vd(e,t=!1){let r=on(),o=Xi()!=null,n=Ct(()=>e(r,o)).current;return Ld({popupStore:n,treatPopupAsFloatingElement:t,floatingRootContext:n.state.floatingRootContext,floatingId:r,nested:o,onOpenChange:n.setOpen}),n}function Dd({handle:e,store:t}){return we(()=>e.attachStore(t),[e,t]),null}function vw(e,t){let r=zo.useRef(null),o=zo.useRef(null);return zo.useCallback(n=>{if(e===void 0)return;let i=!1;if(r.current!==null){let s=r.current,a=o.current,u=t.context.triggerElements.getById(s);a&&u===a&&(t.context.triggerElements.delete(s),i=!0),r.current=null,o.current=null}if(n!==null&&(r.current=e,o.current=n,t.context.triggerElements.add(e,n),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function bw(e,t,r,o=!1){t?e.preventUnmountingOnClose=!1:o&&(e.preventUnmountingOnClose=!0);let n=r?.id??null;(n||t)&&(e.activeTriggerId=n,e.activeTriggerElement=r??null)}function ww(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function Bd(e,t,r,o={}){let n=r.reason,i=n===Oe.triggerHover,s=t&&n===Oe.triggerFocus,a=!t&&(n===Oe.triggerPress||n===Oe.escapeKey),u=ww(r);if(e.context.onOpenChange?.(t,r),r.isCanceled)return;o.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,r);let l=()=>{let c={...o.extraState,open:t};s?c.instantType="focus":a?c.instantType="dismiss":i&&(c.instantType=void 0),bw(c,t,r.trigger,u()),e.update(c)};i?Nd.flushSync(l):l()}function jd(e,t,r,o){let n=r.useState("isMountedByTrigger",e),i=vw(e,r),s=Pe(u=>{let l=r.select("open"),c=r.select("activeTriggerId");if(c===e){r.update({activeTriggerElement:u,...l?o:null});return}c==null&&l&&r.update({activeTriggerId:e,activeTriggerElement:u,...o})}),a=zo.useCallback(u=>{i(u),u&&s(u)},[i,s]);return we(()=>{n&&r.update({activeTriggerElement:t.current,...o})},[n,r,t,...Object.values(o)]),{registerTrigger:a,isMountedByThisTrigger:n}}function zd(e,t={}){let{closeOnActiveTriggerUnmount:r=!1}=t,o=zo.useRef(null),n=e.useState("open"),i=e.useState("triggerCount"),s=e.useState("activeTriggerId"),a=e.useState("activeTriggerElement");we(()=>{if(!n){o.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let u=e.context.triggerElements.size,l={};e.state.triggerCount!==u&&(l.triggerCount=u);let c=e.select("activeTriggerId"),m=null;if(c){let d=e.context.triggerElements.getById(c);if(d)o.current=c,d!==e.state.activeTriggerElement&&(l.activeTriggerElement=d);else{for(let[h,g]of e.context.triggerElements.entries())if(g===e.state.activeTriggerElement){l.activeTriggerId=h,l.activeTriggerElement=g,o.current=h;break}l.activeTriggerId===void 0&&(o.current===c?m=c:o.current=null)}}else o.current=null;if(!m&&!c&&u===1){let d=e.context.triggerElements.entries().next();if(!d.done){let[h,g]=d.value;l.activeTriggerId=h,l.activeTriggerElement=g,o.current=h}}(l.triggerCount!==void 0||l.activeTriggerId!==void 0||l.activeTriggerElement!==void 0)&&e.update(l),m&&r&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===m&&!e.context.triggerElements.getById(m)){let d=De(Oe.none);e.setOpen(!1,d),d.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[n,e,i,s,a,r])}function Hd(e,t,r){let{mounted:o,setMounted:n,transitionStatus:i}=hf(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:o,transitionStatus:i,preventUnmountingOnClose:a});let u=Pe(()=>{n(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),r?.(),t.context.onOpenChangeComplete?.(!1)});return zi({enabled:o&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||u()}}),{forceUnmount:u,transitionStatus:i}}function Ud(e,t){e.useSyncedValues(t),we(()=>()=>{e.update({activeTriggerProps:nt,inactiveTriggerProps:nt,popupProps:nt})},[e])}var Ho=class{constructor(){this.idMap=new Map}add(t,r){this.idMap.set(t,r)}delete(t){this.idMap.delete(t)}hasElement(t){for(let r of this.idMap.values())if(r===t)return!0;return!1}hasMatchingElement(t){for(let r of this.idMap.values())if(t(r))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function Wd(){return new ho({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new Ho,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function Yd(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:Wd(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:nt,inactiveTriggerProps:nt,popupProps:nt}}function qd(e,t,r=!1){return new ho({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:r,onOpenChange:void 0})}var oi=e=>e.triggerIdProp??e.activeTriggerId,yl=e=>e.openProp??e.open,Gd=e=>(e.popupElement?.id??e.floatingId)||void 0;function Zd(e,t){return t!==void 0&&yl(e)&&oi(e)===t}function xw(e,t){return Zd(e,t)?!0:t!==void 0&&yl(e)&&oi(e)==null&&e.triggerCount===1}var Xd={open:yl,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:oi,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:Gd,isTriggerActive:(e,t)=>t!==void 0&&oi(e)===t,isOpenedByTrigger:(e,t)=>Zd(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&oi(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>xw(e,t)?Gd(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var vl=f(ve(),1),Kd=f(ts(),1);function Jd(e){let t=vl.useCallback(o=>e===void 0?tr:e.subscribeStore(o),[e]),r=vl.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,Kd.useSyncExternalStore)(t,r,()=>e?.serverStore)}function Qd(e){return Sw(e,e.rootContext)}function Sw(e,t){let{nodeId:r,externalTree:o}=e,n=t.useState("referenceElement"),i=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),u=t.useState("floatingId"),[l,c]=Pt.useState(null),[m,d]=Pt.useState(void 0),[h,g]=Pt.useState(void 0),b=Pt.useRef(null),w=po(o),C=Pt.useMemo(()=>({reference:n,floating:i,domReference:s}),[n,i,s]),x=bd({...e,elements:{...C,...l&&{reference:l}}}),v=Re(m)?m:null,_=h===void 0?t.state.floatingElement:h;t.useSyncedValue("referenceElement",m??null),t.useSyncedValue("domReferenceElement",m===void 0?s:v),t.useSyncedValue("floatingElement",_);let k=Pt.useCallback(D=>{let S=Re(D)?{getBoundingClientRect:()=>D.getBoundingClientRect(),getClientRects:()=>D.getClientRects(),contextElement:D}:D;c(S),x.refs.setReference(S)},[x.refs]),E=Pt.useCallback(D=>{(Re(D)||D===null)&&(b.current=D,d(D)),(Re(x.refs.reference.current)||x.refs.reference.current===null||D!==null&&!Re(D))&&x.refs.setReference(D)},[x.refs,d]),T=Pt.useCallback(D=>{g(D),x.refs.setFloating(D)},[x.refs]),O=Pt.useMemo(()=>({...x.refs,setReference:E,setFloating:T,setPositionReference:k,domReference:b}),[x.refs,E,T,k]),I=Pt.useMemo(()=>({...x.elements,domReference:s}),[x.elements,s]),J=Pt.useMemo(()=>({...x,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:u,refs:O,elements:I,nodeId:r,rootStore:t}),[x,O,I,r,t,a,u]);return we(()=>{s&&(b.current=s)},[s]),we(()=>{t.context.dataRef.current.floatingContext=J;let D=w?.nodesRef.current.find(S=>S.id===r);D&&(D.context=J)}),Pt.useMemo(()=>({...x,context:J,refs:O,elements:I,rootStore:t}),[x,O,I,J,t])}var Mr=f(ve(),1);var bl=Zr.os.mac&&Zr.engine.webkit;function wl(e,t={}){let{enabled:r=!0,delay:o}=t,n="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=n.context,a=Mr.useRef(!1),u=Mr.useRef(null),l=Mr.useRef(!0),c=xr();Mr.useEffect(()=>{let d=n.select("domReferenceElement");if(!r)return;let h=it(d);function g(){let C=n.select("domReferenceElement");!n.select("open")&&_t(C)&&C===Hi(Rt(C))&&(a.current=!0)}function b(){l.current=!0}function w(){l.current=!1}return Sr(ze(h,"blur",g),bl&&ze(h,"keydown",b,!0),bl&&ze(h,"pointerdown",w,!0))},[n,r]),Mr.useEffect(()=>{if(!r)return;function d(h){if(h.reason===Oe.triggerPress||h.reason===Oe.escapeKey){let g=n.select("domReferenceElement");Re(g)&&(u.current=g,a.current=!0)}}return i.on("openchange",d),()=>{i.off("openchange",d)}},[i,r,n]);let m=Mr.useMemo(()=>{function d(){a.current=!1,u.current=null}return{onMouseLeave(){d()},onFocus(h){let g=h.currentTarget;if(a.current){if(u.current===g)return;d()}let b=Nt(h.nativeEvent);if(Re(b)){if(bl&&!h.relatedTarget){if(!l.current&&!Ff(b))return}else if(!Af(b))return}let w=co(h.relatedTarget,n.context.triggerElements),{nativeEvent:C,currentTarget:x}=h,v=typeof o=="function"?o():o;if(n.select("open")&&w||v===0||v===void 0){n.setOpen(!0,De(Oe.triggerFocus,C,x));return}c.start(v,()=>{a.current||n.setOpen(!0,De(Oe.triggerFocus,C,x))})},onBlur(h){d();let g=h.relatedTarget,b=h.nativeEvent,w=Re(g)&&g.hasAttribute(cn("focus-guard"))&&g.getAttribute("data-type")==="outside";c.start(0,()=>{let C=n.select("domReferenceElement"),x=Hi(Rt(C));!g&&x===C||Ge(s.current.floatingContext?.refs.floating.current,x)||Ge(C,x)||w||co(g??x,n.context.triggerElements)||n.setOpen(!1,De(Oe.triggerFocus,b))})}}},[s,o,n,c]);return Mr.useMemo(()=>r?{reference:m,trigger:m}:{},[r,m])}var Sl=f(ve(),1);var xl=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new rr,this.restTimeout=new rr,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},is=new WeakMap;function dn(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&is.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),is.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ss(e,t){let{scopeElement:r,referenceElement:o,floatingElement:n}=t,i=is.get(r);i&&i!==e&&dn(i),dn(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=r,e.pointerEventsReferenceElement=o,e.pointerEventsFloatingElement=n,is.set(r,e),r.style.pointerEvents="none",o.style.pointerEvents="auto",n.style.pointerEvents="auto"}function pn(e){let t=e.context.dataRef.current,r=Ct(()=>t.hoverInteractionState??xl.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=r),nn(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function Cl(e,t={}){let{enabled:r=!0,closeDelay:o=0,nodeId:n}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),u=i.useState("domReferenceElement"),{dataRef:l}=i.context,c=po(),m=Xi(),d=pn(i),h=xr(),g=Pe(()=>Wi(l.current.openEvent?.type,d.interactedInside)),b=Pe(()=>If(l.current.openEvent?.type)),w=Pe(()=>{dn(d)});we(()=>{s||(d.pointerType=void 0,d.restTimeoutPending=!1,d.interactedInside=!1,w())},[s,d,w]),Sl.useEffect(()=>w,[w]),we(()=>{if(r&&s&&d.handleCloseOptions?.blockPointerEvents&&b()&&Re(u)&&a){let C=u,x=a,v=Rt(a),_=c?.nodesRef.current.find(O=>O.id===m)?.context?.elements.floating;_&&(_.style.pointerEvents="");let k=d.pointerEventsScopeElement!==x?d.pointerEventsScopeElement:null,E=_!==x?_:null,T=d.handleCloseOptions?.getScope?.()??k??E??C.closest("[data-rootownerid]")??v.body;return ss(d,{scopeElement:T,referenceElement:C,floatingElement:x}),()=>{w()}}},[r,s,u,a,d,b,c,m,w]),Sl.useEffect(()=>{if(!r)return;function C(){return!!(c&&m&&Kr(c.nodesRef.current,m).length>0)}function x(O){let I=cr(o,"close",d.pointerType),J=()=>{i.setOpen(!1,De(Oe.triggerHover,O)),c?.events.emit("floating.closed",O)};I?d.openChangeTimeout.start(I,J):(d.openChangeTimeout.clear(),J())}function v(O){let I=Nt(O);if(!Ja(I)){d.interactedInside=!1;return}d.interactedInside=I?.closest("[aria-haspopup]")!=null}function _(){d.openChangeTimeout.clear(),h.clear(),c?.events.off("floating.closed",E),w()}function k(O){if(C()&&c){c.events.on("floating.closed",E);return}if(co(O.relatedTarget,i.context.triggerElements))return;let I=l.current.floatingContext?.nodeId??n,J=O.relatedTarget;if(!(c&&I&&Re(J)&&Kr(c.nodesRef.current,I,!1).some(S=>Ge(S.context?.elements.floating,J)))){if(d.handler){d.handler(O);return}w(),b()&&!g()&&x(O)}}function E(O){!c||!m||C()||h.start(0,()=>{c.events.off("floating.closed",E),i.setOpen(!1,De(Oe.triggerHover,O)),c.events.emit("floating.closed",O)})}let T=a;return Sr(T&&ze(T,"mouseenter",_),T&&ze(T,"mouseleave",k),T&&ze(T,"pointerdown",v,!0),()=>{c?.events.off("floating.closed",E)})},[r,a,i,l,o,n,b,g,w,d,c,m,h])}var go=f(ve(),1),$d=f(lo(),1);var Cw={current:null};function _l(e,t={}){let{enabled:r=!0,delay:o=0,handleClose:n=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:u=Cw,externalTree:l,isActiveTrigger:c=!0,getHandleCloseContext:m,isClosing:d,shouldOpen:h,guardStaleOpen:g=!1}=t,b="rootStore"in e?e.rootStore:e,{dataRef:w,events:C}=b.context,x=po(l),v=pn(b),_=go.useRef(!1),k=Yt(n),E=Yt(o),T=Yt(s),O=Yt(r),I=Yt(h),J=Yt(d),D=Pe(()=>Wi(w.current.openEvent?.type,v.interactedInside)),S=Pe(()=>I.current?.()!==!1),L=Pe((N,q,U)=>{let R=b.context.triggerElements;if(R.hasElement(q))return!N||!Ge(N,q);if(!Re(U))return!1;let B=U;return R.hasMatchingElement(re=>Ge(re,B))&&(!N||!Ge(N,B))}),Y=Pe(()=>{if(!v.handler)return;Rt(b.select("domReferenceElement")).removeEventListener("mousemove",v.handler),v.handler=void 0}),A=Pe(()=>{dn(v)});return c&&(v.handleCloseOptions=k.current?.__options),go.useEffect(()=>Y,[Y]),go.useEffect(()=>{if(!r)return;function N(q){q.open?_.current=!1:(_.current=q.reason===Oe.triggerHover,Y(),v.openChangeTimeout.clear(),v.restTimeout.clear(),v.blockMouseMove=!0,v.restTimeoutPending=!1)}return C.on("openchange",N),()=>{C.off("openchange",N)}},[r,C,v,Y]),go.useEffect(()=>{if(!r)return;function N(P,W=!0){let ne=cr(E.current,"close",v.pointerType);ne?v.openChangeTimeout.start(ne,()=>{b.setOpen(!1,De(Oe.triggerHover,P)),x?.events.emit("floating.closed",P)}):W&&(v.openChangeTimeout.clear(),b.setOpen(!1,De(Oe.triggerHover,P)),x?.events.emit("floating.closed",P))}let q=u.current??(c?b.select("domReferenceElement"):null);if(!Re(q))return;function U(P){if(v.openChangeTimeout.clear(),v.blockMouseMove=!1,i&&!Xr(v.pointerType))return;let W=Qa(T.current),ne=cr(E.current,"open",v.pointerType),xe=Nt(P),se=P.currentTarget??null,be=b.select("domReferenceElement"),ye=se;if(Re(xe)&&!b.context.triggerElements.hasElement(xe)){for(let H of b.context.triggerElements.elements())if(Ge(H,xe)){ye=H;break}}Re(se)&&Re(be)&&!b.context.triggerElements.hasElement(se)&&Ge(se,be)&&(ye=be);let $=ye==null?!1:L(be,ye,xe),_e=b.select("open"),Fe=J.current?.()??b.select("transitionStatus")==="ending",xt=!_e&&Fe&&_.current,Le=!$&&Re(ye)&&Re(be)&&Ge(be,ye)&&xt,X=W>0&&!ne,M=$&&(_e||xt)||Le,K=!_e||$;if(M){S()&&b.setOpen(!0,De(Oe.triggerHover,P,ye));return}X||(ne?v.openChangeTimeout.start(ne,()=>{K&&S()&&b.setOpen(!0,De(Oe.triggerHover,P,ye))}):K&&S()&&b.setOpen(!0,De(Oe.triggerHover,P,ye)))}function R(P){if(D()){A();return}Y();let W=b.select("domReferenceElement"),ne=Rt(W);v.restTimeout.clear(),v.restTimeoutPending=!1;let xe=w.current.floatingContext??m?.();if(co(P.relatedTarget,b.context.triggerElements))return;if(k.current&&xe){b.select("open")||v.openChangeTimeout.clear();let be=u.current;v.handler=k.current({...xe,tree:x,x:P.clientX,y:P.clientY,onClose(){A(),Y(),O.current&&!D()&&be===b.select("domReferenceElement")&&N(P,!0)}}),ne.addEventListener("mousemove",v.handler),v.handler(P);return}(v.pointerType!=="touch"||!Ge(b.select("floatingElement"),P.relatedTarget))&&N(P)}function B(P){Ge(q,P.relatedTarget)||(v.openChangeTimeout.clear(),v.restTimeout.clear(),v.restTimeoutPending=!1)}let re=g?ze(q,"mouseout",B):void 0;return a?Sr(ze(q,"mousemove",U,{once:!0}),ze(q,"mouseenter",U),ze(q,"mouseleave",R),re):Sr(ze(q,"mouseenter",U),ze(q,"mouseleave",R),re)},[Y,A,w,E,b,r,k,v,c,L,D,i,a,T,u,x,O,m,J,S,g]),go.useMemo(()=>{if(!r)return;function N(q){v.pointerType=q.pointerType}return{onPointerDown:N,onPointerEnter:N,onMouseMove(q){let{nativeEvent:U}=q,R=q.currentTarget,B=b.select("domReferenceElement"),re=b.select("open"),P=L(B,R,q.target);if(i&&!Xr(v.pointerType))return;if(re&&P&&v.handleCloseOptions?.blockPointerEvents){let xe=b.select("floatingElement");if(xe){let se=v.handleCloseOptions?.getScope?.()??R.ownerDocument.body;ss(v,{scopeElement:se,referenceElement:R,floatingElement:xe})}}let W=Qa(T.current);if(re&&!P||W===0||!P&&v.restTimeoutPending&&q.movementX**2+q.movementY**2<2)return;v.restTimeout.clear();function ne(){if(v.restTimeoutPending=!1,D())return;let xe=b.select("open");!v.blockMouseMove&&(!xe||P)&&S()&&b.setOpen(!0,De(Oe.triggerHover,U,R))}v.pointerType==="touch"?$d.flushSync(()=>{ne()}):P&&re?ne():(v.restTimeoutPending=!0,v.restTimeout.start(W,ne))}}},[r,v,D,L,i,b,T,S])}var ep=.1,_w=ep*ep,Xe=.5;function as(e,t,r,o,n,i){return o>=t!=i>=t&&e<=(n-r)*(t-o)/(i-o)+r}function ls(e,t,r,o,n,i,s,a,u,l){let c=!1;return as(e,t,r,o,n,i)&&(c=!c),as(e,t,n,i,s,a)&&(c=!c),as(e,t,s,a,u,l)&&(c=!c),as(e,t,u,l,r,o)&&(c=!c),c}function Rw(e,t,r){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height}function cs(e,t,r,o,n,i){let s=Math.min(r,n),a=Math.max(r,n),u=Math.min(o,i),l=Math.max(o,i);return e>=s&&e<=a&&t>=u&&t<=l}function Rl(e={}){let{blockPointerEvents:t=!1}=e,r=new rr,o=({x:n,y:i,placement:s,elements:a,onClose:u,nodeId:l,tree:c})=>{let m=s?.split("-")[0],d=!1,h=null,g=null,b=typeof performance<"u"?performance.now():0;function w(x,v){let _=performance.now(),k=_-b;if(h===null||g===null||k===0)return h=x,g=v,b=_,!1;let E=x-h,T=v-g,O=E*E+T*T,I=k*k*_w;return h=x,g=v,b=_,O0)}function L(){S()||C()}if(S())return;let Y=_.getBoundingClientRect(),A=k.getBoundingClientRect(),N=n>A.right-A.width/2,q=i>A.bottom-A.height/2,U=A.width>Y.width,R=A.height>Y.height,B=(U?Y:A).left,re=(U?Y:A).right,P=(R?Y:A).top,W=(R?Y:A).bottom;if(m==="top"&&i>=Y.bottom-1||m==="bottom"&&i<=Y.top+1||m==="left"&&n>=Y.right-1||m==="right"&&n<=Y.left+1){L();return}let ne=!1;switch(m){case"top":ne=cs(E,T,B,Y.top+1,re,A.bottom-1);break;case"bottom":ne=cs(E,T,B,A.top+1,re,Y.bottom-1);break;case"left":ne=cs(E,T,A.right-1,W,Y.left+1,P);break;case"right":ne=cs(E,T,Y.right-1,W,A.left+1,P);break;default:}if(ne)return;if(d&&!Rw(E,T,Y)){L();return}if(!I&&w(E,T)){L();return}let xe=!1;switch(m){case"top":{let se=U?Xe/2:Xe*4,be=U||N?n+se:n-se,ye=U?n-se:N?n+se:n-se,$=i+Xe+1,_e=N||U?A.bottom-Xe:A.top,Fe=N?U?A.bottom-Xe:A.top:A.bottom-Xe;xe=ls(E,T,be,$,ye,$,A.left,_e,A.right,Fe);break}case"bottom":{let se=U?Xe/2:Xe*4,be=U||N?n+se:n-se,ye=U?n-se:N?n+se:n-se,$=i-Xe,_e=N||U?A.top+Xe:A.bottom,Fe=N?U?A.top+Xe:A.bottom:A.top+Xe;xe=ls(E,T,be,$,ye,$,A.left,_e,A.right,Fe);break}case"left":{let se=R?Xe/2:Xe*4,be=R||q?i+se:i-se,ye=R?i-se:q?i+se:i-se,$=n+Xe+1,_e=q||R?A.right-Xe:A.left,Fe=q?R?A.right-Xe:A.left:A.right-Xe;xe=ls(E,T,_e,A.top,Fe,A.bottom,$,be,$,ye);break}case"right":{let se=R?Xe/2:Xe*4,be=R||q?i+se:i-se,ye=R?i-se:q?i+se:i-se,$=n-Xe,_e=q||R?A.left+Xe:A.right,Fe=q?R?A.left+Xe:A.right:A.left+Xe;xe=ls(E,T,$,be,$,ye,_e,A.top,Fe,A.bottom);break}default:}xe?d||r.start(40,L):L()}};return o.__options={...e,blockPointerEvents:t},o}var us=class extends mo{setState(t){}update(t){}set(t,r){}notifyAll(){}};var zk=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=ja.startingStyle]="startingStyle",e[e.endingStyle=ja.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({});var Ew={"data-popup-open":""};var Tw={"data-open":""},Pw={"data-closed":""},Ow={"data-anchor-hidden":""},tp={open(e){return e?Ew:null}};var ni={open(e){return e?Tw:Pw},anchorHidden(e){return e?Ow:null}},rp={...ni,...gf};function op(e){return rn(19)?e:e?"true":void 0}var fs=f(ve(),1),El=fs.createContext(void 0);function mn(){return fs.useContext(El)?.direction??"ltr"}var nr=f(ve(),1);var kw=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:o,placement:n,rects:i,platform:s,elements:a,middlewareData:u}=t,{element:l,padding:c=0,offsetParent:m="real"}=Nr(e,t)||{};if(l==null)return{};let d=Zi(c),h={x:r,y:o},g=ti(n),b=ei(g),w=await s.getDimensions(l),C=g==="y",x=C?"top":"left",v=C?"bottom":"right",_=C?"clientHeight":"clientWidth",k=i.reference[b]+i.reference[g]-h[g]-i.floating[b],E=h[g]-i.reference[g],T=m==="real"?await s.getOffsetParent?.(l):a.floating,O=a.floating[_]||i.floating[b];(!O||!await s.isElement?.(T))&&(O=a.floating[_]||i.floating[b]);let I=k/2-E/2,J=O/2-w[b]/2-1,D=Math.min(d[x],J),S=Math.min(d[v],J),L=D,Y=O-w[b]-S,A=O/2-w[b]/2+I,N=Yi(L,A,Y),q=!u.arrow&&_r(n)!=null&&A!==N&&i.reference[b]/2-(A({...kw(e),options:[e,t]});var ip={name:"hide",async fn(e){let{width:t,height:r,x:o,y:n}=e.rects.reference,i=t===0&&r===0&&o===0&&n===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-r>=0||s.right-t>=0||s.bottom-r>=0||s.left-t>=0||i}}}};var hn={sideX:"left",sideY:"top"};var sp="--available-width",ap="--available-height";function up(e,t,r){let o=e==="inline-start"||e==="inline-end";return{top:"top",right:o?r?"inline-start":"inline-end":"right",bottom:"bottom",left:o?r?"inline-end":"inline-start":"left"}[t]}function lp(e,t,r){let{rects:o,placement:n}=e;return{side:up(t,Tt(n),r),align:_r(n)||"center",anchor:{width:o.reference.width,height:o.reference.height},positioner:{width:o.floating.width,height:o.floating.height}}}function fp(e){return Fw(e,Qd)}function Fw(e,t){let{anchor:r,positionMethod:o="absolute",side:n="bottom",sideOffset:i=0,align:s="center",alignOffset:a=0,collisionBoundary:u,collisionPadding:l=5,sticky:c=!1,arrowPadding:m=5,disableAnchorTracking:d=!1,inline:h,keepMounted:g=!1,floatingRootContext:b,mounted:w,collisionAvoidance:C,shift:x,nodeId:v,adaptiveOrigin:_,lazyFlip:k=!1,externalTree:E}=e,[T,O]=nr.useState(null);!w&&T!==null&&O(null);let I=C.side||"flip",J=C.align||"flip",D=C.fallbackAxisSide||"end",S=x?.crossAxis??!1,L=x?.rootBoundary,Y=typeof r=="function"?r:void 0,A=Pe(Y),N=Y?A:r,q=Yt(r),U=Yt(w),B=mn()==="rtl",re=T||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":B?"left":"right","inline-start":B?"right":"left"}[n],P=s==="center"?re:`${re}-${s}`,W=l;typeof W=="number"?W={top:W,right:W,bottom:W,left:W}:W&&(W={top:W.top||0,right:W.right||0,bottom:W.bottom||0,left:W.left||0});let ne=1,xe=n==="bottom"?ne:0,se=n==="top"?ne:0,be=n==="right"?ne:0,ye=n==="left"?ne:0,$={boundary:u==="clipping-ancestors"?"clippingAncestors":u,padding:W},_e=nr.useRef(null),Fe=Yt(i),xt=Yt(a),Le=typeof i!="function"?i:0,X=typeof a!="function"?a:0,M=[];h&&M.push(h),M.push(al(G=>{let y=lp(G,n,B),oe=typeof Fe.current=="function"?Fe.current(y):Fe.current,Ae=typeof xt.current=="function"?xt.current(y):xt.current;return{mainAxis:oe,crossAxis:Ae,alignmentAxis:Ae}},[Le,X,B,n]));let K=J==="none"&&I!=="shift",H=!K&&(c||S||I==="shift"),Q=I==="none"?null:ul({...$,padding:{top:W.top+ne+xe,right:W.right+ne+ye,bottom:W.bottom+ne+se,left:W.left+ne+be},mainAxis:!S&&I==="flip",crossAxis:J==="flip"?"alignment":!1,fallbackAxisSideDirection:D}),pe=K?null:ll({...$,rootBoundary:L,mainAxis:J!=="none",crossAxis:H,limiter:c||S?void 0:cl(G=>{if(!_e.current)return{};let{width:y,height:oe}=_e.current.getBoundingClientRect(),Ae=qt(Tt(G.placement)),ee=Ae==="y"?y:oe,Qe=Ae==="y"?W.left+W.right:W.top+W.bottom;return{offset:ee/2+Qe/2}})},[$,c,S,L,W,J]);I==="shift"||J==="shift"||s==="center"?M.push(pe,Q):M.push(Q,pe),M.push(fl({...$,apply({elements:{floating:G},availableWidth:y,availableHeight:oe,rects:Ae}){if(!U.current)return;let ee=G.style;ee.setProperty(sp,`${y}px`),ee.setProperty(ap,`${oe}px`);let Qe=it(G).devicePixelRatio||1,{x:ie,y:Je,width:j,height:z}=Ae.reference,vr=(Math.round((ie+j)*Qe)-Math.round(ie*Qe))/Qe,je=(Math.round((Je+z)*Qe)-Math.round(Je*Qe))/Qe;ee.setProperty("--anchor-width",`${vr}px`),ee.setProperty("--anchor-height",`${je}px`)}}),np(G=>({element:_e.current||Rt(G.elements.floating).createElement("div"),padding:m,offsetParent:"floating"}),[m]),{name:"transformOrigin",fn(G){let{elements:y,middlewareData:oe,placement:Ae,rects:ee,y:Qe}=G,ie=Tt(Ae),Je=qt(ie),j=_e.current,z=oe.arrow?.x||0,vr=oe.arrow?.y||0,je=j?.clientWidth||0,ce=j?.clientHeight||0,br=z+je/2,Or=vr+ce/2,et=Math.abs(oe.shift?.y||0),Me=ee.reference.height/2,$e=typeof i=="function"?i(lp(G,n,B)):i,ut=et>$e,pt={top:`${br}px calc(100% + ${$e}px)`,bottom:`${br}px ${-$e}px`,left:`calc(100% + ${$e}px) ${Or}px`,right:`${-$e}px ${Or}px`}[ie],wr=`${br}px ${ee.reference.y+Me-Qe}px`;return y.floating.style.setProperty("--transform-origin",H&&Je==="y"&&ut?wr:pt),{}}},ip,_),we(()=>{!w&&b&&b.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[w,b]);let le=nr.useMemo(()=>({elementResize:!d&&typeof ResizeObserver<"u",layoutShift:!d&&typeof IntersectionObserver<"u"}),[d]),{refs:fe,elements:me,x:he,y:V,middlewareData:te,update:Ne,placement:He,context:ot,isPositioned:Ze,floatingStyles:Be}=t({rootContext:b,open:g?w:void 0,placement:P,middleware:M,strategy:o,whileElementsMounted:g?void 0:(...G)=>ri(...G,le),nodeId:v,externalTree:E}),{sideX:Ue,sideY:ct}=te.adaptiveOrigin||hn,Se=Ze?o:"fixed",Pr=nr.useMemo(()=>{let G;return Ze?_?G={position:Se,[Ue]:he,[ct]:V}:G={...Be,position:Se}:G={position:Se,top:0,left:0},G[sp]="100vw",G[ap]="100vh",Ze||(G.opacity=0),G},[_,Se,Ue,he,ct,V,Be,Ze]),$t=nr.useRef(null);we(()=>{if(!w)return;let G=q.current,y=typeof G=="function"?G():G,Ae=(cp(y)?y.current:y)||null||null;Ae!==$t.current&&(fe.setPositionReference(Ae),$t.current=Ae)},[w,fe,N,q]),nr.useEffect(()=>{if(!w)return;let G=q.current;typeof G!="function"&&cp(G)&&G.current!==$t.current&&(fe.setPositionReference(G.current),$t.current=G.current)},[w,fe,N,q]),nr.useEffect(()=>{if(g&&w&&me.reference&&me.floating)return ri(me.reference,me.floating,Ne,le)},[g,w,me,Ne,le]);let Ye=Tt(He),Yr=up(n,Ye,B),St=_r(He)||"center",kt=!!te.hide?.referenceHidden;we(()=>{k&&w&&Ze&&Ye!==re&&O(Ye)},[k,w,Ze,Ye,re]);let vt=nr.useMemo(()=>({position:"absolute",top:te.arrow?.y,left:te.arrow?.x}),[te.arrow]),F=te.arrow?.centerOffset!==0;return nr.useMemo(()=>({positionerStyles:Pr,arrowStyles:vt,arrowRef:_e,arrowUncentered:F,side:Yr,align:St,physicalSide:Ye,anchorHidden:kt,refs:fe,context:ot,isPositioned:Ze,update:Ne}),[Pr,vt,_e,F,Yr,St,Ye,kt,fe,ot,Ze,Ne])}function cp(e){return e!=null&&"current"in e}function ds(e){return e==="starting"?zf:nt}function dp(e,t,{styles:r,transitionStatus:o,props:n,refs:i,hidden:s,inert:a=!1}){let u={...r};return a&&(u.pointerEvents="none"),Gt("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:u},ds(o),n],stateAttributesMapping:ni})}var Et=f(ve(),1),xp=f(lo(),1);var pp=f(ve(),1);function mp(e){let[t,r]=pp.useState({current:e,previous:null});return Object.is(e,t.current)||r({current:e,previous:t.current}),t.previous}var gn=f(ve(),1);function Tl(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=_t(e),i=n?e.offsetWidth:r,s=n?e.offsetHeight:o;return(fo(r)!==i||fo(o)!==s)&&(r=i,o=s),{width:r,height:o}}function gp(e){let{popupElement:t,positionerElement:r,content:o,mounted:n,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:u}=e,l=ln(t,!0),c=sn(),m=gn.useRef(null),d=gn.useRef(!0),h=gn.useRef(tr),g=Pe(i),b=Pe(s),w=gn.useMemo(()=>Aw(a,u),[a,u]);we(()=>{if(!n){h.current=tr,d.current=!0,m.current=null;return}if(!t||!r)return;h.current=hp(t,w),Pl(t,"auto");let C=ms(t,"position","static"),x=ms(t,"transform","none"),v=ms(t,"scale","1"),_=hp(r,{"--available-width":"max-content","--available-height":"max-content"});function k(){C(),x(),_()}function E(){k(),v()}if(g?.(),d.current||m.current===null){ps(r,"max-content");let J=Tl(t);return m.current=J,ps(r,J),E(),b?.(null,J),d.current=!1,()=>{h.current(),h.current=tr}}ps(r,"max-content");let T=m.current,O=Tl(t);m.current=O,Pl(t,T),E(),b?.(T,O),ps(r,O);let I=new AbortController;return c.request(()=>{Pl(t,O),l(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},I.signal)}),()=>{I.abort(),c.cancel(),h.current(),h.current=tr}},[o,t,r,l,c,n,g,b,w])}function Aw(e,t){let r=e==="top",o=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!r&&!o?nt:{position:"absolute",[r?"bottom":"top"]:"0",[o?"right":"left"]:"0"}}function ms(e,t,r){let o=e.style.getPropertyValue(t);return e.style.setProperty(t,r),()=>{e.style.setProperty(t,o)}}function hp(e,t){let r=[];for(let[o,n]of Object.entries(t))r.push(ms(e,o,n));return r.length?()=>{r.forEach(o=>o())}:tr}function Pl(e,t){let r=t==="auto"?"auto":`${t.width}px`,o=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",r),e.style.setProperty("--popup-height",o)}function ps(e,t){let r=t==="max-content"?"max-content":`${t.width}px`,o=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",r),e.style.setProperty("--positioner-height",o)}var yp=f(ve(),1);var vp=f(Z(),1),hs=function(t){let{direction:r="ltr"}=t,o=yp.useMemo(()=>({direction:r}),[r]);return(0,vp.jsx)(El.Provider,{value:o,children:t.children})};var bp={name:"adaptiveOrigin",async fn(e){let{x:t,y:r,rects:{floating:o},elements:{floating:n},platform:i,strategy:s,placement:a}=e,u=it(n),l=u.getComputedStyle(n);if(!(l.transitionDuration!=="0s"&&l.transitionDuration!==""))return{x:t,y:r,data:hn};let m=await i.getOffsetParent?.(n),d={width:0,height:0};if(s==="fixed"&&u?.visualViewport)d={width:u.visualViewport.width,height:u.visualViewport.height};else if(m===u){let x=Rt(n);d={width:x.documentElement.clientWidth,height:x.documentElement.clientHeight}}else await i.isElement?.(m)&&(d=await i.getDimensions(m));let h=Tt(a),g=t,b=r;h==="left"&&(g=d.width-(t+o.width)),h==="top"&&(b=d.height-(r+o.height));let w=h==="left"?"right":hn.sideX,C=h==="top"?"bottom":hn.sideY;return{x:g,y:b,data:{sideX:w,sideY:C}}}};var yn=f(Z(),1),Sp={activationDirection:e=>e?{"data-activation-direction":e}:null};function Cp(e){let{store:t,side:r,children:o}=e,n=mn(),i=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),a=t.useState("open"),u=t.useState("payload"),l=t.useState("mounted"),c=t.useState("popupElement"),m=t.useState("positionerElement"),d=mp(a?i:null),h=Nw(s,u),g=Et.useRef(null),[b,w]=Et.useState(null),[C,x]=Et.useState(null),v=Et.useRef(null),_=Et.useRef(null),k=ln(v,!0),E=sn(),T=Et.useRef(null),[O,I]=Et.useState(null),[J,D]=Et.useState(!1);we(()=>(t.set("adaptiveOrigin",bp),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let S=Pe(()=>{v.current?.style.setProperty("animation","none"),v.current?.style.setProperty("transition","none"),_.current?.style.setProperty("display","none")}),L=Pe(R=>{v.current?.style.removeProperty("animation"),v.current?.style.removeProperty("transition"),_.current?.style.removeProperty("display"),R&&I(R)}),Y=Pe(()=>{T.current?.abort();let R=new AbortController;T.current=R,k(()=>{w(null),I(null),g.current=null},R.signal)}),A=Et.useRef(null);we(()=>{(!a||!l)&&(A.current=null)},[a,l]),we(()=>{if(i&&d&&i!==d&&A.current!==i&&g.current){w(g.current),D(!0);let R=Lw(d,i);x(R),A.current=i}},[i,d]),we(()=>{b!=null&&(T.current?.abort(),D(!0),E.request(()=>{xp.flushSync(()=>{D(!1)}),Y()}))},[h,b,Y,E]),we(()=>{let R=v.current;if(!R)return;let B=Rt(R).createElement("div");for(let re of Array.from(R.childNodes))B.appendChild(re.cloneNode(!0));g.current=B});let N=b!=null,q;N?q=(0,yn.jsxs)(Et.Fragment,{children:[(0,yn.jsx)("div",{"data-previous":!0,inert:op(!0),ref:_,style:{...O?{"--popup-width":`${O.width}px`,"--popup-height":`${O.height}px`}:null,position:"absolute"},"data-ending-style":J?void 0:""},"previous"),(0,yn.jsx)("div",{"data-current":!0,ref:v,"data-starting-style":J?"":void 0,children:o},h)]}):q=(0,yn.jsx)("div",{"data-current":!0,ref:v,children:o},h),we(()=>{let R=_.current;!R||!b||R.replaceChildren(...Array.from(b.childNodes))},[b]),gp({popupElement:c,positionerElement:m,mounted:l,content:u,onMeasureLayout:S,onMeasureLayoutComplete:L,side:r,direction:n});let U={activationDirection:Iw(C),transitioning:N};return{children:q,state:U}}function Iw(e){if(e)return`${wp(e.horizontal,5,"right","left")} ${wp(e.vertical,5,"down","up")}`}function wp(e,t,r,o){return e>t?r:e<-t?o:""}function Lw(e,t){let r=e.getBoundingClientRect(),o=t.getBoundingClientRect(),n={x:r.left+r.width/2,y:r.top+r.height/2},i={x:o.left+o.width/2,y:o.top+o.height/2};return{horizontal:i.x-n.x,vertical:i.y-n.y}}function Nw(e,t){let[r,o]=Et.useState(0),n=Et.useRef(e),i=Et.useRef(t),s=Et.useRef(!1);return we(()=>{let a=n.current,u=i.current,l=e!==a,c=t!==u;l?(o(m=>m+1),s.current=!c):s.current&&c&&(o(m=>m+1),s.current=!1),n.current=e,i.current=t},[e,t]),`${e??"current"}-${r}`}var gs=f(ve(),1),_p=f(lo(),1);var Rp=f(Z(),1),Ep=gs.forwardRef(function(t,r){let{children:o,container:n,className:i,render:s,style:a,...u}=t,{node:l,subtree:c}=Gf({container:n,ref:r,componentProps:t,elementProps:u});return!c&&!l?null:(0,Rp.jsxs)(gs.Fragment,{children:[c,l&&_p.createPortal(o,l)]})});var Xt={};so(Xt,{Arrow:()=>Gp,Handle:()=>si,Popup:()=>Up,Portal:()=>Bp,Positioner:()=>zp,Provider:()=>qp,Root:()=>Ap,Trigger:()=>Mp,Viewport:()=>Xp,createHandle:()=>Kp});var vn=f(ve(),1);var ys=f(ve(),1),Ol=ys.createContext(void 0);function ur(e){let t=ys.useContext(Ol);if(t===void 0&&!e)throw new Error(lr(72));return t}var Tp=f(ve(),1);var Pp={...Xd,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},vs=class extends mo{constructor(t,r,o){let n=new Ho;super(kp(t,n,r,o),Fp(n),Pp)}setOpen=(t,r)=>{Bd(this,t,r,{extraState:{openChangeReason:r.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,De(Oe.triggerPress,t))}};function Op(){let e=new Ho,t=new us(Object.freeze(kp(void 0,e)),Object.freeze(Fp(e)),Pp);return Object.assign(t,{setOpen:tr,cancelPendingOpen:tr})}function kp(e,t,r,o=!1){let n={...Yd(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e};return n.floatingRootContext=qd(t,r,o),n}function Fp(e){return{popupRef:Tp.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var ii=f(Z(),1),Ap=hl(function(t){let{disabled:r=!1,defaultOpen:o=!1,open:n,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:u,onOpenChangeComplete:l,handle:c,triggerId:m,defaultTriggerId:d=null,children:h}=t,g=Vd((D,S)=>new vs({open:o,openProp:n,activeTriggerId:d,triggerIdProp:m},D,S));g.useControlledProp("openProp",n),g.useControlledProp("triggerIdProp",m),g.useContextCallback("onOpenChange",u),g.useContextCallback("onOpenChangeComplete",l);let b=g.useState("open"),w=!r&&b,C=g.useState("activeTriggerId"),x=g.useState("mounted"),v=g.useState("payload");g.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i,disabled:r}),zd(g,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:_,transitionStatus:k}=Hd(w,g),E=g.useState("isInstantPhase"),T=g.useState("instantType"),O=g.useState("lastOpenChangeReason"),I=vn.useRef(null);we(()=>{b&&r&&g.setOpen(!1,De(Oe.disabled))},[b,r,g]),we(()=>{k==="ending"&&O===Oe.none||k!=="ending"&&E?(T!=="delay"&&(I.current=T),g.set("instantType","delay")):I.current!==null&&(g.set("instantType",I.current),I.current=null)},[k,E,O,T,g]),we(()=>{w&&C==null&&g.set("payload",void 0)},[g,C,w]),vn.useImperativeHandle(a,()=>({unmount:_,close:()=>g.setOpen(!1,De(Oe.imperativeAction))}),[_,g]);let J=w||x||!r&&s!=="none";return(0,ii.jsxs)(Ol.Provider,{value:g,children:[c&&(0,ii.jsx)(Dd,{handle:c,store:g}),J&&(0,ii.jsx)(Mw,{store:g,disabled:r,trackCursorAxis:s}),typeof h=="function"?h({payload:v}):h]})});function Mw({store:e,disabled:t,trackCursorAxis:r}){let o=e.useState("floatingRootContext"),n=rl(o,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=tl(o,{enabled:!t&&r!=="none",axis:r==="none"?void 0:r}),s=vn.useMemo(()=>It(i.reference,n.reference),[i.reference,n.reference]);return Ud(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:n.floating??nt}),null}var ws=f(ve(),1);var bs=f(ve(),1),kl=bs.createContext(void 0);function Ip(){return bs.useContext(kl)}var Np="data-base-ui-tooltip-trigger";function Lp(e){if("composedPath"in e){let r=e.composedPath();for(let o=0;ow.select("transitionStatus")==="ending",shouldOpen(){return!B.current}}),be=wl(_,{enabled:!N}).reference,ye=Le=>{let X=B.current,M=Lp(Le),K=xe(M),H=k.current,Q=H&&M&&Ge(H,M);if(K&&w.select("open")&&w.select("lastOpenChangeReason")===Oe.triggerHover){w.setOpen(!1,De(Oe.triggerHover,Le));return}if(X&&!K&&Q&&!q.current&&!w.select("open")&&H&&Xr(P.current)){let pe=()=>{!B.current&&!q.current&&!w.select("open")&&w.setOpen(!0,De(Oe.triggerHover,Le,H))},le=W();le===0?(re.clear(),pe()):re.start(le,pe)}},$=w.useState("triggerProps",I);return Gt("button",t,{state:{open:v},ref:[r,O,k],props:[se,be,I||U!=="none"?$:void 0,{onMouseOver(Le){ye(Le.nativeEvent)},onFocus(Le){ne(Lp(Le.nativeEvent))&&Le.preventBaseUIHandler()},onMouseLeave(){B.current=!1,re.clear(),P.current=void 0},onPointerEnter(Le){P.current=Le.pointerType},onPointerDown(Le){P.current=Le.pointerType,w.set("closeOnClick",c),c&&!w.select("open")&&w.cancelPendingOpen(Le.nativeEvent)},onClick(Le){c&&!w.select("open")&&w.cancelPendingOpen(Le.nativeEvent)},id:C,"data-trigger-disabled":N?"":void 0,[Np]:N?void 0:""},h],stateAttributesMapping:tp})});var Dp=f(ve(),1);var xs=f(ve(),1),Fl=xs.createContext(void 0);function Vp(){let e=xs.useContext(Fl);if(e===void 0)throw new Error(lr(70));return e}var Al=f(Z(),1),Bp=Dp.forwardRef(function(t,r){let{keepMounted:o=!1,...n}=t;return ur().useState("mounted")||o?(0,Al.jsx)(Fl.Provider,{value:o,children:(0,Al.jsx)(Ep,{ref:r,...n})}):null});var Cs=f(ve(),1);var Ss=f(ve(),1),Il=Ss.createContext(void 0);function bn(){let e=Ss.useContext(Il);if(e===void 0)throw new Error(lr(71));return e}var jp=f(Z(),1),zp=Cs.forwardRef(function(t,r){let{render:o,className:n,anchor:i,positionMethod:s="absolute",side:a="top",align:u="center",sideOffset:l=0,alignOffset:c=0,collisionBoundary:m="clipping-ancestors",collisionPadding:d=5,arrowPadding:h=5,sticky:g=!1,disableAnchorTracking:b=!1,collisionAvoidance:w=Hf,style:C,...x}=t,v=ur(),_=Vp(),k=v.useState("open"),E=v.useState("mounted"),T=v.useState("trackCursorAxis"),O=v.useState("disableHoverablePopup"),I=v.useState("floatingRootContext"),J=v.useState("instantType"),D=v.useState("transitionStatus"),S=v.useState("adaptiveOrigin"),L=fp({anchor:i,positionMethod:s,floatingRootContext:I,mounted:E,side:a,sideOffset:l,align:u,alignOffset:c,collisionBoundary:m,collisionPadding:d,sticky:g,arrowPadding:h,disableAnchorTracking:b,keepMounted:_,collisionAvoidance:w,adaptiveOrigin:S}),Y=Cs.useMemo(()=>({open:k,side:L.side,align:L.align,anchorHidden:L.anchorHidden,instant:T!=="none"?"tracking-cursor":J}),[k,L.side,L.align,L.anchorHidden,T,J]),A=dp(t,Y,{styles:L.positionerStyles,transitionStatus:D,props:x,refs:[r,v.useStateSetter("positionerElement")],hidden:!E,inert:!k||T==="both"||O});return(0,jp.jsx)(Il.Provider,{value:L,children:A})});var Hp=f(ve(),1);var Up=Hp.forwardRef(function(t,r){let{render:o,className:n,style:i,...s}=t,a=ur(),{side:u,align:l}=bn(),c=a.useState("open"),m=a.useState("instantType"),d=a.useState("transitionStatus"),h=a.useState("popupProps"),g=a.useState("floatingRootContext"),b=a.useState("disabled"),w=a.useState("closeDelay");zi({open:c,ref:a.context.popupRef,onComplete(){c&&a.context.onOpenChangeComplete?.(!0)}}),Cl(g,{enabled:!b,closeDelay:w});let C=a.useStateSetter("popupElement");return Gt("div",t,{state:{open:c,side:u,align:l,instant:m,transitionStatus:d},ref:[r,a.context.popupRef,C],props:[Md,h,ds(d),s],stateAttributesMapping:rp})});var Wp=f(ve(),1);var Gp=Wp.forwardRef(function(t,r){let{render:o,className:n,style:i,...s}=t,a=ur(),{arrowRef:u,side:l,align:c,arrowUncentered:m,arrowStyles:d}=bn(),h=a.useState("open"),g=a.useState("instantType");return Gt("div",t,{state:{open:h,side:l,align:c,uncentered:m,instant:g},ref:[r,u],props:[{style:d,"aria-hidden":!0},s],stateAttributesMapping:ni})});var Yp=f(ve(),1);var Ll=f(Z(),1),qp=function(t){let{delay:r,closeDelay:o,timeout:n=400}=t,i=Yp.useMemo(()=>({open:r,close:o}),[r,o]);return(0,Ll.jsx)(kl.Provider,{value:r,children:(0,Ll.jsx)($a,{delay:i,timeoutMs:n,children:t.children})})};var Zp=f(ve(),1);var Xp=Zp.forwardRef(function(t,r){let{render:o,className:n,style:i,children:s,...a}=t,u=ur(),l=bn(),c=u.useState("instantType"),{children:m,state:d}=Cp({store:u,side:l.side,children:s}),h={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:c};return Gt("div",t,{state:h,ref:r,props:[a,{children:m}],stateAttributesMapping:Sp})});var si=class extends es{constructor(){super(Op(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function Kp(){return new si}function Vr(e){return Gt(e.defaultTagName??"div",e,e)}var $p=f(Te(),1),Nl="data-wp-hash";function Ml(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&jw(document)),e.__wpStyleRuntime}function Bw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Nl}]`))if(r.getAttribute(Nl)===t)return!0;return!1}function em(e,t,r){if(!e.head)return;let o=Ml(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Bw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Nl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function jw(e){let t=Ml();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)em(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function tm(e,t){let r=Ml();r.styles.set(e,t);for(let o of r.documents.keys())em(o,e,t)}typeof process>"u",tm("a495f9d138",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Jp={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",tm("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Qp={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},wn=(0,$p.forwardRef)(function({variant:t="body-md",render:r,className:o,...n},i){return Vr({render:r,defaultTagName:"span",ref:i,props:It(n,{className:We(Jp.text,Qp.heading,Qp.p,Jp[t],o)})})});var _s=f(Te(),1),ai=(0,_s.forwardRef)(({icon:e,size:t=24,...r},o)=>(0,_s.cloneElement)(e,{width:t,height:t,...r,ref:o}));var Rs=f(xn(),1),Vl=f(Z(),1),Uo=(0,Vl.jsx)(Rs.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Vl.jsx)(Rs.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"})});var Es=f(xn(),1),Dl=f(Z(),1),Wo=(0,Dl.jsx)(Es.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Dl.jsx)(Es.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"})});var Ts=f(xn(),1),Bl=f(Z(),1),jl=(0,Bl.jsx)(Ts.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Bl.jsx)(Ts.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"})});var Ps=f(xn(),1),zl=f(Z(),1),Os=(0,zl.jsx)(Ps.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,zl.jsx)(Ps.Path,{d:"M6.6 6L5.4 7l4.5 5-4.5 5 1.1 1 5.5-6-5.4-6zm6 0l-1.1 1 4.5 5-4.5 5 1.1 1 5.5-6-5.5-6z"})});var ks=f(xn(),1),Hl=f(Z(),1),Fs=(0,Hl.jsx)(ks.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Hl.jsx)(ks.Path,{d:"M11.6 7l-1.1-1L5 12l5.5 6 1.1-1L7 12l4.6-5zm6 0l-1.1-1-5.5 6 5.5 6 1.1-1-4.6-5 4.6-5z"})});var Sn={};so(Sn,{Popup:()=>Cm,Portal:()=>As,Positioner:()=>Is,Provider:()=>Am,Root:()=>km,Trigger:()=>Em});var xm=f(Te(),1);var lm=f(Te(),1);var Wl="data-wp-hash";function Gl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Hw(document)),e.__wpStyleRuntime}function zw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Wl}]`))if(r.getAttribute(Wl)===t)return!0;return!1}function im(e,t,r){if(!e.head)return;let o=Gl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(zw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Wl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Hw(e){let t=Gl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)im(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Uw(e,t){let r=Gl();r.styles.set(e,t);for(let o of r.documents.keys())im(o,e,t)}typeof process>"u",Uw("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var nm={slot:"_11fc52b637ff8a7e__slot"},sm="data-wp-compat-overlay-slot";function Ww(){return typeof document>"u"?null:document}function Gw(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var Dr=null;function Ul(e){return e.setAttribute("aria-hidden","false"),e}function Yw(e){let t=e.createElement("div");return t.setAttribute(sm,""),nm.slot&&t.classList.add(nm.slot),e.body.appendChild(t),t}function am(){if(typeof window>"u"||!Gw()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=Ww();if(!e||!e.body)return;if(Dr&&Dr.ownerDocument===e&&Dr.isConnected)return Ul(Dr);let t=e.querySelector(`[${sm}]`);return t instanceof HTMLDivElement?(Dr=Ul(t),Dr):(Dr?.isConnected&&Dr.remove(),Dr=Ul(Yw(e)),Dr)}var cm=f(Z(),1),As=(0,lm.forwardRef)(function({container:t,...r},o){return(0,cm.jsx)(Xt.Portal,{container:t??am(),...r,ref:o})});var um=f(Te(),1),pm=f(Z(),1),Yl="data-wp-hash";function ql(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Zw(document)),e.__wpStyleRuntime}function qw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Yl}]`))if(r.getAttribute(Yl)===t)return!0;return!1}function fm(e,t,r){if(!e.head)return;let o=ql(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(qw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Yl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Zw(e){let t=ql();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)fm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function dm(e,t){let r=ql();r.styles.set(e,t);for(let o of r.documents.keys())fm(o,e,t)}typeof process>"u",dm("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Xw={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",dm("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Kw={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Is=(0,um.forwardRef)(function({align:t="center",className:r,side:o="top",sideOffset:n=4,...i},s){return(0,pm.jsx)(Xt.Positioner,{ref:s,align:t,side:o,sideOffset:n,...i,className:We(Xw["box-sizing"],Kw.positioner,r)})});var mm=f(Te(),1);function Zl(e,t,r){return(0,mm.cloneElement)(e??t,{children:r})}var Jw=f(gm(),1);var vm=f(li(),1),{lock:dA,unlock:bm}=(0,vm.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function Qw(){let e=Jw;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return bm(e.privateApis).ThemeProvider}var wm=Qw();var ci=f(Z(),1),Xl="data-wp-hash";function Kl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&e1(document)),e.__wpStyleRuntime}function $w(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Xl}]`))if(r.getAttribute(Xl)===t)return!0;return!1}function Sm(e,t,r){if(!e.head)return;let o=Kl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if($w(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Xl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function e1(e){let t=Kl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Sm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function t1(e,t){let r=Kl();r.styles.set(e,t);for(let o of r.documents.keys())Sm(o,e,t)}typeof process>"u",t1("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var r1={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},o1={background:"#1e1e1e"},Cm=(0,xm.forwardRef)(function({portal:t,positioner:r,children:o,className:n,...i},s){let a=(0,ci.jsx)(wm,{color:o1,children:(0,ci.jsx)(Xt.Popup,{ref:s,className:We(r1.popup,n),...i,children:o})}),u=Zl(r,(0,ci.jsx)(Is,{}),a);return Zl(t,(0,ci.jsx)(As,{}),u)});var _m=f(Te(),1),Rm=f(Z(),1),Em=(0,_m.forwardRef)(function(t,r){return(0,Rm.jsx)(Xt.Trigger,{ref:r,...t})});var Tm=f(ge(),1),Pm=f(Z(),1);function Om({children:e}){return(0,Pm.jsx)(hs,{direction:(0,Tm.isRTL)()?"rtl":"ltr",children:e})}var Jl=f(Z(),1);function km(e){return(0,Jl.jsx)(Om,{children:(0,Jl.jsx)(Xt.Root,{...e})})}var Fm=f(Z(),1);function Am({...e}){return(0,Fm.jsx)(Xt.Provider,{...e})}var Im=f(Te(),1),Ql="data-wp-hash";function $l(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&i1(document)),e.__wpStyleRuntime}function n1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Ql}]`))if(r.getAttribute(Ql)===t)return!0;return!1}function Lm(e,t,r){if(!e.head)return;let o=$l(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(n1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Ql,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function i1(e){let t=$l();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Lm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function s1(e,t){let r=$l();r.styles.set(e,t);for(let o of r.documents.keys())Lm(o,e,t)}typeof process>"u",s1("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var a1={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},ec=(0,Im.forwardRef)(function({render:t,...r},o){return Vr({render:t,ref:o,props:It({className:a1["visually-hidden"]},r,{"data-visually-hidden":""})})});var Nm=f(Te(),1),tc="data-wp-hash";function rc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&c1(document)),e.__wpStyleRuntime}function l1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${tc}]`))if(r.getAttribute(tc)===t)return!0;return!1}function Mm(e,t,r){if(!e.head)return;let o=rc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(l1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(tc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function c1(e){let t=rc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Mm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function u1(e,t){let r=rc();r.styles.set(e,t);for(let o of r.documents.keys())Mm(o,e,t)}typeof process>"u",u1("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var f1={stack:"_19ce0419607e1896__stack"},d1={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},vo=(0,Nm.forwardRef)(function({direction:t,gap:r,align:o,justify:n,wrap:i,render:s,...a},u){let l={gap:r&&d1[r],alignItems:o,justifyContent:n,flexDirection:t,flexWrap:i};return Vr({render:s,ref:u,props:It(a,{style:l,className:f1.stack})})});var Vm=f(Te(),1),Dm=f(ge(),1),Cn=f(Z(),1),oc="data-wp-hash";function nc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&m1(document)),e.__wpStyleRuntime}function p1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${oc}]`))if(r.getAttribute(oc)===t)return!0;return!1}function Bm(e,t,r){if(!e.head)return;let o=nc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(p1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(oc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function m1(e){let t=nc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Bm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Ns(e,t){let r=nc();r.styles.set(e,t);for(let o of r.documents.keys())Bm(o,e,t)}typeof process>"u",Ns("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var h1={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Ns("96553466c8","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var g1={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",Ns("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var Ls={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",Ns("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var y1={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},ic=(0,Vm.forwardRef)(function({children:t,variant:r="default",tone:o="brand",openInNewTab:n=!1,render:i,className:s,...a},u){return Vr({render:i,defaultTagName:"a",ref:u,props:It(a,{className:We(y1.a,h1["box-sizing"],g1["outset-ring--focus-except-active"],r!=="unstyled"&&Ls.link,r!=="unstyled"&&Ls[`is-${o}`],r==="unstyled"&&Ls["is-unstyled"],s),target:n?"_blank":void 0,children:(0,Cn.jsxs)(Cn.Fragment,{children:[t,n&&(0,Cn.jsx)("span",{className:Ls["link-icon"],role:"img","aria-label":(0,Dm.__)("(opens in a new tab)")})]})})})});var zm=f(Te(),1),sc="data-wp-hash";function ac(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&b1(document)),e.__wpStyleRuntime}function v1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${sc}]`))if(r.getAttribute(sc)===t)return!0;return!1}function Hm(e,t,r){if(!e.head)return;let o=ac(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(v1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(sc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function b1(e){let t=ac();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Hm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Um(e,t){let r=ac();r.styles.set(e,t);for(let o of r.documents.keys())Hm(o,e,t)}typeof process>"u",Um("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var w1={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Um("ed2c39ec90","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.b20cc1690085c2f0__skeleton{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);display:block;@media (forced-colors:active){border:var(--wpds-border-width-xs,1px) solid CanvasText}}._9b143194fdb45f93__pulse{@media not (prefers-reduced-motion){animation:e2b9fe0690281bc8__skeleton-pulse 1.5s ease-in-out infinite}}@keyframes e2b9fe0690281bc8__skeleton-pulse{0%,to{opacity:1}50%{opacity:.4}}}}");var jm={skeleton:"b20cc1690085c2f0__skeleton",pulse:"_9b143194fdb45f93__pulse","skeleton-pulse":"e2b9fe0690281bc8__skeleton-pulse"},ui=(0,zm.forwardRef)(function({render:t,...r},o){return Vr({render:t,ref:o,props:It({className:We(jm.skeleton,jm.pulse,w1["box-sizing"]),"aria-hidden":!0},r)})});var Wm=f(Te(),1),Gm=f(Z(),1),Ym=(0,Wm.forwardRef)(({children:e,className:t,ariaLabel:r,as:o="div",...n},i)=>(0,Gm.jsx)(o,{ref:i,className:We("admin-ui-navigable-region",t),"aria-label":r,role:"region",tabIndex:"-1",...n,children:e}));Ym.displayName="NavigableRegion";var qm=Ym;var Zm=f(ge(),1);var bo=f(Z(),1),cc="data-wp-hash";function uc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&S1(document)),e.__wpStyleRuntime}function x1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${cc}]`))if(r.getAttribute(cc)===t)return!0;return!1}function Xm(e,t,r){if(!e.head)return;let o=uc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(x1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(cc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function S1(e){let t=uc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Xm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function C1(e,t){let r=uc();r.styles.set(e,t);for(let o of r.documents.keys())Xm(o,e,t)}typeof process>"u",C1("72ef022400",".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}");var lc={list:"bfb5a2dd8cceebd3__list",li:"a4759b4cb2c8bd92__li",item:"_07da506d3f2d9afe__item"},_1=({items:e,currentHref:t,ariaLabel:r=(0,Zm.__)("Sections"),linkComponent:o,className:n})=>{if(!e.length)return null;let i=o??"a";return(0,bo.jsx)("nav",{"aria-label":r,className:n,children:(0,bo.jsx)(vo,{render:(0,bo.jsx)("ul",{role:"list"}),direction:"row",align:"center",gap:"md",className:lc.list,children:e.map(s=>(0,bo.jsx)("li",{className:lc.li,children:(0,bo.jsx)(wn,{variant:"body-md",className:lc.item,render:(0,bo.jsx)(ic,{variant:"unstyled","aria-current":s.href===t?"page":void 0,render:(0,bo.jsx)(i,{href:s.href})}),children:s.label})},s.href))})})},Km=_1;var Qm=f(ue(),1),{Fill:$m,Slot:eh}=(0,Qm.createSlotFill)("SidebarToggle");var ir=f(Z(),1),fc="data-wp-hash";function dc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&E1(document)),e.__wpStyleRuntime}function R1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${fc}]`))if(r.getAttribute(fc)===t)return!0;return!1}function th(e,t,r){if(!e.head)return;let o=dc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(R1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(fc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function E1(e){let t=dc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)th(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function T1(e,t){let r=dc();r.styles.set(e,t);for(let o of r.documents.keys())th(o,e,t)}typeof process>"u",T1("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Br={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function rh({headingLevel:e=1,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,actions:s,navigation:a,components:u,showSidebarToggle:l=!0}){let c=`h${e}`,m=!!a?.items?.length;return(0,ir.jsxs)(vo,{direction:"column",className:We(Br.header,m&&Br["has-navigation"]),children:[(0,ir.jsxs)(vo,{className:Br["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,ir.jsxs)(vo,{direction:"row",gap:"sm",align:"center",justify:"start",className:Br["header-lockup"],children:[l&&(0,ir.jsx)(eh,{bubblesVirtually:!0,className:Br["sidebar-toggle-slot"]}),o&&(0,ir.jsx)("div",{className:Br["header-visual"],"aria-hidden":"true",children:o}),n&&(0,ir.jsx)(wn,{className:Br["header-title"],render:(0,ir.jsx)(c,{}),variant:"heading-lg",children:n}),t,r]}),s&&(0,ir.jsx)(vo,{align:"center",className:Br["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,ir.jsx)(wn,{render:(0,ir.jsx)("p",{}),variant:"body-md",className:Br["header-subtitle"],children:i}),m&&(0,ir.jsx)(Km,{...a,linkComponent:u?.link,className:Br["header-navigation"]})]})}var fi=f(Z(),1),mc="data-wp-hash";function hc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&O1(document)),e.__wpStyleRuntime}function P1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${mc}]`))if(r.getAttribute(mc)===t)return!0;return!1}function oh(e,t,r){if(!e.head)return;let o=hc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(P1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(mc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function O1(e){let t=hc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)oh(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function k1(e,t){let r=hc();r.styles.set(e,t);for(let o of r.documents.keys())oh(o,e,t)}typeof process>"u",k1("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var pc={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function nh({headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,children:s,className:a,actions:u,navigation:l,components:c,ariaLabel:m,hasPadding:d=!1,showSidebarToggle:h=!0}){let g=We(pc.page,a);return(0,fi.jsxs)(qm,{className:g,ariaLabel:m??(typeof n=="string"?n:""),children:[(n||t||r||u||o||!!l?.items?.length)&&(0,fi.jsx)(rh,{headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,actions:u,navigation:l,components:c,showSidebarToggle:h}),d?(0,fi.jsx)("div",{className:We(pc.content,pc["has-padding"]),children:s}):s]})}nh.SidebarToggleFill=$m;var gc=nh;var zn=f(ge()),Vv=f(ue()),Dv=f(sh()),Ea=f(sr()),Bv=f(Kt()),jv=f(Te());var Lv=f(ue(),1),Nv=f(_n(),1),RE=f(Kt(),1),EE=f(Dt(),1),Au=f(Te(),1),TE=f(yo(),1);function Rn(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let i of t){let s=n[i];n=n[i]=Array.isArray(s)?[...s]:{...s}}return n[o]=r,e}var ht=(e,t,r)=>{let o=Array.isArray(t)?t:t.split("."),n=e;return o.forEach(i=>{n=n?.[i]}),n??r};var F1=["appearanceTools","useRootPaddingAwareAlignments","background.backgroundImage","background.backgroundRepeat","background.backgroundSize","background.backgroundPosition","background.gradient","border.color","border.radius","border.radiusSizes","border.style","border.width","shadow.presets","shadow.defaultPresets","color.background","color.button","color.caption","color.custom","color.customDuotone","color.customGradient","color.defaultDuotone","color.defaultGradients","color.defaultPalette","color.duotone","color.gradients","color.heading","color.link","color.palette","color.text","custom","dimensions.aspectRatio","dimensions.height","dimensions.minHeight","dimensions.minWidth","dimensions.width","dimensions.dimensionSizes","layout.contentSize","layout.definitions","layout.wideSize","lightbox.enabled","lightbox.allowEditing","position.fixed","position.sticky","spacing.customSpacingSize","spacing.defaultSpacingSizes","spacing.spacingSizes","spacing.spacingScale","spacing.blockGap","spacing.margin","spacing.padding","spacing.units","typography.fluid","typography.customFontSize","typography.defaultFontSizes","typography.dropCap","typography.fontFamilies","typography.fontSizes","typography.fontStyle","typography.fontWeight","typography.letterSpacing","typography.lineHeight","typography.textAlign","typography.textColumns","typography.textDecoration","typography.textIndent","typography.textTransform","typography.writingMode","viewport.mobile","viewport.tablet"];function yc(e,t,r){let o=r?".blocks."+r:"",n=t?"."+t:"",i=`settings${o}${n}`,s=`settings${n}`;if(t)return ht(e,i)??ht(e,s);let a={};return F1.forEach(u=>{let l=ht(e,`settings${o}.${u}`)??ht(e,`settings.${u}`);l!==void 0&&(a=Rn(a,u.split("."),l))}),a}function vc(e,t,r,o){let n=o?".blocks."+o:"",i=t?"."+t:"",s=`settings${n}${i}`;return Rn(e,s.split("."),r)}var hh=f(dh(),1);var A1="1600px",I1="320px",L1=1,N1=.25,M1=.75,V1="14px";function ph({minimumFontSize:e,maximumFontSize:t,fontSize:r,minimumViewportWidth:o=I1,maximumViewportWidth:n=A1,scaleFactor:i=L1,minimumFontSizeLimit:s}){if(s=jr(s)?s:V1,r){let v=jr(r);if(!v?.unit||!v?.value)return null;let _=jr(s,{coerceTo:v.unit});if(_?.value&&!e&&!t&&v?.value<=_?.value)return null;if(t||(t=`${v.value}${v.unit}`),!e){let k=v.unit==="px"?v.value:v.value*16,E=Math.min(Math.max(1-.075*Math.log2(k),N1),M1),T=di(v.value*E,3);_?.value&&T<_?.value?e=`${_.value}${_.unit}`:e=`${T}${v.unit}`}}let a=jr(e),u=a?.unit||"rem",l=jr(t,{coerceTo:u});if(!a||!l)return null;let c=jr(e,{coerceTo:"rem"}),m=jr(n,{coerceTo:u}),d=jr(o,{coerceTo:u});if(!m||!d||!c)return null;let h=m.value-d.value;if(!h)return null;let g=di(d.value/100,3),b=di(g,3)+u,w=100*((l.value-a.value)/h),C=di((w||1)*i,3),x=`${c.value}${c.unit} + ((1vw - ${b}) * ${C})`;return`clamp(${e}, ${x}, ${t})`}function jr(e,t={}){if(typeof e!="string"&&typeof e!="number")return null;isFinite(e)&&(e=`${e}px`);let{coerceTo:r,rootSizeValue:o,acceptableUnits:n}={coerceTo:"",rootSizeValue:16,acceptableUnits:["rem","px","em"],...t},i=n?.join("|"),s=new RegExp(`^(\\d*\\.?\\d+)(${i}){1,1}$`),a=e.toString().match(s);if(!a||a.length<3)return null;let[,u,l]=a,c=parseFloat(u);return r==="px"&&(l==="em"||l==="rem")&&(c=c*o,l=r),l==="px"&&(r==="em"||r==="rem")&&(c=c/o,l=r),(r==="em"||r==="rem")&&(l==="em"||l==="rem")&&(l=r),l?{value:di(c,3),unit:l}:null}function di(e,t=3){let r=Math.pow(10,t);return Math.round(e*r)/r}function bc(e){let t=e?.fluid;return t===!0||t&&typeof t=="object"&&Object.keys(t).length>0}function D1(e){let t=e?.typography??{},r=e?.layout,o=jr(r?.wideSize)?r?.wideSize:null;return bc(t)&&o?{fluid:{maxViewportWidth:o,...typeof t.fluid=="object"?t.fluid:{}}}:{fluid:t?.fluid}}function mh(e,t){let{size:r}=e;if(!r||r==="0"||e?.fluid===!1||!bc(t?.typography)&&!bc(e))return r;let o=D1(t)?.fluid??{},n=ph({minimumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.min,maximumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.max,fontSize:r,minimumFontSizeLimit:typeof o=="object"?o?.minFontSize:void 0,maximumViewportWidth:typeof o=="object"?o?.maxViewportWidth:void 0,minimumViewportWidth:typeof o=="object"?o?.minViewportWidth:void 0});return n||r}var B1=[{path:["color","palette"],valueKey:"color",cssVarInfix:"color",classes:[{classSuffix:"color",propertyName:"color"},{classSuffix:"background-color",propertyName:"background-color"},{classSuffix:"border-color",propertyName:"border-color"}]},{path:["color","gradients"],valueKey:"gradient",cssVarInfix:"gradient",classes:[{classSuffix:"gradient-background",propertyName:"background"}]},{path:["color","duotone"],valueKey:"colors",cssVarInfix:"duotone",valueFunc:({slug:e})=>`url( '#wp-duotone-${e}' )`,classes:[]},{path:["shadow","presets"],valueKey:"shadow",cssVarInfix:"shadow",classes:[]},{path:["typography","fontSizes"],valueFunc:(e,t)=>mh(e,t),valueKey:"size",cssVarInfix:"font-size",classes:[{classSuffix:"font-size",propertyName:"font-size"}]},{path:["typography","fontFamilies"],valueKey:"fontFamily",cssVarInfix:"font-family",classes:[{classSuffix:"font-family",propertyName:"font-family"}]},{path:["spacing","spacingSizes"],valueKey:"size",cssVarInfix:"spacing",valueFunc:({size:e})=>e,classes:[]},{path:["border","radiusSizes"],valueKey:"size",cssVarInfix:"border-radius",classes:[]},{path:["dimensions","dimensionSizes"],valueKey:"size",cssVarInfix:"dimension",classes:[]}];function j1(e,t){if(!e||!t)return e;if(typeof e=="object"&&"ref"in e&&e?.ref){let r=(0,hh.getCSSValueFromRawStyle)(ht(t,e.ref));return typeof r=="object"&&r!==null&&"ref"in r&&r?.ref?void 0:r===void 0?e:r}return e}function z1(e,t){if(!e||!t||!Array.isArray(t))return e;let r=t.find(o=>o?.name===e);return r?.href?r?.href:e}function gh(e,t){if(!e||!t)return e;let r=j1(e,t);return typeof r=="object"&&r!==null&&"url"in r&&r?.url&&(r.url=z1(r.url,t?._links?.["wp:theme-file"])),r}function yh(e,t,r=[],o="slug",n){let i=[t?ht(e,["blocks",t,...r]):void 0,ht(e,r)].filter(Boolean);for(let s of i)if(s){let a=["custom","theme","default"];for(let u of a){let l=s[u];if(l){let c=l.find(m=>m[o]===n);if(c)return o==="slug"||yh(e,t,r,"slug",c.slug)[o]===c[o]?c:void 0}}}}function H1(e,t,r,[o,n]=[]){let i=B1.find(a=>a.cssVarInfix===o);if(!i||!e.settings)return r;let s=yh(e.settings,t,i.path,"slug",n);if(s){let{valueKey:a}=i,u=s[a];return Ms(e,t,u)}return r}function U1(e,t,r,o=[]){let n=(t?ht(e?.settings??{},["blocks",t,"custom",...o]):void 0)??ht(e?.settings??{},["custom",...o]);return n?Ms(e,t,n):r}function Ms(e,t,r){if(!r||typeof r!="string")if(typeof r=="object"&&r!==null&&"ref"in r&&typeof r.ref=="string"){let l=ht(e,r.ref);if(!l||typeof l=="object"&&"ref"in l)return l;r=l}else return r;let o="var:",n="var(--wp--",i=")",s;if(r.startsWith(o))s=r.slice(o.length).split("|");else if(r.startsWith(n)&&r.endsWith(i))s=r.slice(n.length,-i.length).split("--");else return r;let[a,...u]=s;return a==="preset"?H1(e,t,r,u):a==="custom"?U1(e,t,r,u):r}function Vs(e,t,r,o=!0){let n=t?"."+t:"",i=r?`styles.blocks.${r}${n}`:`styles${n}`;if(!e)return;let s=ht(e,i),a=void 0;if(s===void 0&&a){let l=!0,c=e;for(let m of i.split(".")){if(!c||typeof c!="object"||!Object.hasOwn(c,m)){l=!1;break}c=c[m]}l||(s=ht(e,a))}return o?Ms(e,r,s):s}function wc(e,t,r,o){let n=t?"."+t:"",i=o?`styles.blocks.${o}${n}`:`styles${n}`;return Rn(e,i.split("."),r)}var xc=f(bh(),1);function pi(e,t){return typeof e!="object"||typeof t!="object"?e===t:(0,xc.default)(e?.styles,t?.styles)&&(0,xc.default)(e?.settings,t?.settings)}var Eh=f(Ch(),1);function _h(e){return Object.prototype.toString.call(e)==="[object Object]"}function Rh(e){var t,r;return _h(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(_h(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}function Go(e,t){return(0,Eh.default)(e,t,{isMergeableObject:Rh,customMerge:r=>{if(r==="backgroundImage")return(o,n)=>n??o}})}var ox={grad:.9,turn:360,rad:360/(2*Math.PI)},Jr=function(e){return typeof e=="string"?e.length>0:typeof e=="number"},bt=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=Math.pow(10,t)),Math.round(r*e)/r+0},dr=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=1),e>r?r:e>t?e:t},Lh=function(e){return(e=isFinite(e)?e%360:0)>0?e:e+360},Th=function(e){return{r:dr(e.r,0,255),g:dr(e.g,0,255),b:dr(e.b,0,255),a:dr(e.a)}},Sc=function(e){return{r:bt(e.r),g:bt(e.g),b:bt(e.b),a:bt(e.a,3)}},nx=/^#([0-9a-f]{3,8})$/i,Ds=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},Nh=function(e){var t=e.r,r=e.g,o=e.b,n=e.a,i=Math.max(t,r,o),s=i-Math.min(t,r,o),a=s?i===t?(r-o)/s:i===r?2+(o-t)/s:4+(t-r)/s:0;return{h:60*(a<0?a+6:a),s:i?s/i*100:0,v:i/255*100,a:n}},Mh=function(e){var t=e.h,r=e.s,o=e.v,n=e.a;t=t/360*6,r/=100,o/=100;var i=Math.floor(t),s=o*(1-r),a=o*(1-(t-i)*r),u=o*(1-(1-t+i)*r),l=i%6;return{r:255*[o,a,s,s,u,o][l],g:255*[u,o,o,a,s,s][l],b:255*[s,s,u,o,o,a][l],a:n}},Ph=function(e){return{h:Lh(e.h),s:dr(e.s,0,100),l:dr(e.l,0,100),a:dr(e.a)}},Oh=function(e){return{h:bt(e.h),s:bt(e.s),l:bt(e.l),a:bt(e.a,3)}},kh=function(e){return Mh((r=(t=e).s,{h:t.h,s:(r*=((o=t.l)<50?o:100-o)/100)>0?2*r/(o+r)*100:0,v:o+r,a:t.a}));var t,r,o},hi=function(e){return{h:(t=Nh(e)).h,s:(n=(200-(r=t.s))*(o=t.v)/100)>0&&n<200?r*o/100/(n<=100?n:200-n)*100:0,l:n/2,a:t.a};var t,r,o,n},ix=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,sx=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ax=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,lx=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Rc={string:[[function(e){var t=nx.exec(e);return t?(e=t[1]).length<=4?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:e.length===4?bt(parseInt(e[3]+e[3],16)/255,2):1}:e.length===6||e.length===8?{r:parseInt(e.substr(0,2),16),g:parseInt(e.substr(2,2),16),b:parseInt(e.substr(4,2),16),a:e.length===8?bt(parseInt(e.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(e){var t=ax.exec(e)||lx.exec(e);return t?t[2]!==t[4]||t[4]!==t[6]?null:Th({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:t[7]===void 0?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(e){var t=ix.exec(e)||sx.exec(e);if(!t)return null;var r,o,n=Ph({h:(r=t[1],o=t[2],o===void 0&&(o="deg"),Number(r)*(ox[o]||1)),s:Number(t[3]),l:Number(t[4]),a:t[5]===void 0?1:Number(t[5])/(t[6]?100:1)});return kh(n)},"hsl"]],object:[[function(e){var t=e.r,r=e.g,o=e.b,n=e.a,i=n===void 0?1:n;return Jr(t)&&Jr(r)&&Jr(o)?Th({r:Number(t),g:Number(r),b:Number(o),a:Number(i)}):null},"rgb"],[function(e){var t=e.h,r=e.s,o=e.l,n=e.a,i=n===void 0?1:n;if(!Jr(t)||!Jr(r)||!Jr(o))return null;var s=Ph({h:Number(t),s:Number(r),l:Number(o),a:Number(i)});return kh(s)},"hsl"],[function(e){var t=e.h,r=e.s,o=e.v,n=e.a,i=n===void 0?1:n;if(!Jr(t)||!Jr(r)||!Jr(o))return null;var s=(function(a){return{h:Lh(a.h),s:dr(a.s,0,100),v:dr(a.v,0,100),a:dr(a.a)}})({h:Number(t),s:Number(r),v:Number(o),a:Number(i)});return Mh(s)},"hsv"]]},Fh=function(e,t){for(var r=0;r=.5},e.prototype.toHex=function(){return t=Sc(this.rgba),r=t.r,o=t.g,n=t.b,s=(i=t.a)<1?Ds(bt(255*i)):"","#"+Ds(r)+Ds(o)+Ds(n)+s;var t,r,o,n,i,s},e.prototype.toRgb=function(){return Sc(this.rgba)},e.prototype.toRgbString=function(){return t=Sc(this.rgba),r=t.r,o=t.g,n=t.b,(i=t.a)<1?"rgba("+r+", "+o+", "+n+", "+i+")":"rgb("+r+", "+o+", "+n+")";var t,r,o,n,i},e.prototype.toHsl=function(){return Oh(hi(this.rgba))},e.prototype.toHslString=function(){return t=Oh(hi(this.rgba)),r=t.h,o=t.s,n=t.l,(i=t.a)<1?"hsla("+r+", "+o+"%, "+n+"%, "+i+")":"hsl("+r+", "+o+"%, "+n+"%)";var t,r,o,n,i},e.prototype.toHsv=function(){return t=Nh(this.rgba),{h:bt(t.h),s:bt(t.s),v:bt(t.v),a:bt(t.a,3)};var t},e.prototype.invert=function(){return fr({r:255-(t=this.rgba).r,g:255-t.g,b:255-t.b,a:t.a});var t},e.prototype.saturate=function(t){return t===void 0&&(t=.1),fr(Cc(this.rgba,t))},e.prototype.desaturate=function(t){return t===void 0&&(t=.1),fr(Cc(this.rgba,-t))},e.prototype.grayscale=function(){return fr(Cc(this.rgba,-1))},e.prototype.lighten=function(t){return t===void 0&&(t=.1),fr(Ah(this.rgba,t))},e.prototype.darken=function(t){return t===void 0&&(t=.1),fr(Ah(this.rgba,-t))},e.prototype.rotate=function(t){return t===void 0&&(t=15),this.hue(this.hue()+t)},e.prototype.alpha=function(t){return typeof t=="number"?fr({r:(r=this.rgba).r,g:r.g,b:r.b,a:t}):bt(this.rgba.a,3);var r},e.prototype.hue=function(t){var r=hi(this.rgba);return typeof t=="number"?fr({h:t,s:r.s,l:r.l,a:r.a}):bt(r.h)},e.prototype.isEqual=function(t){return this.toHex()===fr(t).toHex()},e})(),fr=function(e){return e instanceof Ec?e:new Ec(e)},Ih=[],Vh=function(e){e.forEach(function(t){Ih.indexOf(t)<0&&(t(Ec,Rc),Ih.push(t))})};function ux(e=[]){let t={r:[],g:[],b:[],a:[]};return e.forEach(r=>{let o=fr(r).toRgb();t.r.push(o.r/255),t.g.push(o.g/255),t.b.push(o.b/255),t.a.push(o.a)}),t}function Dh(e){return`${e}{filter:none}`}function Bh(e,t){return`${e}{filter:url(#${t})}`}function jh(e,t){let r=ux(t);return` -`}var yh={mobile:"480px",tablet:"782px"},vh=/^(\d+|\d*\.\d+)(px|em|rem)$/,_1=16;function P1(e){return"mobile"in e||"tablet"in e}function O1(e){return!e||typeof e!="object"?{}:P1(e)?e:e.settings?.viewport??{}}function k1(e){return typeof e=="string"&&vh.test(e.trim())}function yc(e){if(typeof e=="number")return e;if(typeof e!="string")return;let t=e.trim().match(vh);if(!t)return;let r=Number.parseFloat(t[1]);return t[2]==="px"?r:r*_1}function vc(e){let t=O1(e),r={},o={};Object.keys(yh).forEach(a=>{let u=a,l=t[u],c=yc(l);c!==void 0&&k1(l)&&(r[u]=l.trim(),o[u]=c)});let n=Object.keys(r);if(!n.length)return{...yh};if(n.length===1)return r;let s=r.mobile,i=r.tablet;return o.mobile>=o.tablet?{mobile:s}:{mobile:s,tablet:i}}function bh(e){let t=vc(e),r={};return t.mobile&&(r["@mobile"]=`@media (width <= ${t.mobile})`),t.tablet&&(r["@tablet"]=t.mobile?`@media (${t.mobile} < width <= ${t.tablet})`:`@media (width <= ${t.tablet})`),r}function Ai(e,t,r,{resolveRefs:o=!0}={}){if(!e?.styles?.blocks?.[t]?.variations?.[r])return;let n=i=>{Object.keys(i).forEach(a=>{let u=i[a];if(typeof u=="object"&&u!==null)if(u.ref!==void 0)if(typeof u.ref!="string"||u.ref.trim()==="")delete i[a];else{let l=vt(e,u.ref);l!=null?i[a]=l:delete i[a]}else n(u),Object.keys(u).length===0&&delete i[a]})},s=JSON.parse(JSON.stringify(e.styles.blocks[t].variations[r]));return o&&n(s),s}var xc="default";function Ch(e){let t=e?.viewport,r=e?.pseudoState;return(!t||t===xc)&&(!r||r===xc)}function F1(e){return Ch(e)?[]:[e.viewport,e.pseudoState].filter(t=>!!t&&t!==xc)}function A1(e,t){let r=F1(t);return r.length?vt(e,r):e}var I1=new Set(["blocks","variations","css"]),bc=Object.freeze({value:{},sources:{}}),L1={root:{layer:"root"},element:{layer:"element"},block:{layer:"block"},blockVariation:{layer:"blockVariation"}};function mo(e){let t=L1[e];return t?{...t}:null}function ho(e,t){return!e||!t?null:{styles:e,source:t}}function N1(e){return e.join(".")}function D1(e){return{...e}}function Rh(e){return e===""||e===null||typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0}function wc(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&typeof e.ref=="string"}function go(e){if(!e||typeof e!="object"||Array.isArray(e))return null;let t={};for(let r of Object.keys(e))if(!I1.has(r)){if(r==="elements"){e.elements&&typeof e.elements=="object"&&(t.elements=e.elements);continue}Rh(e[r])||(t[r]=e[r])}return Object.keys(t).length===0?null:t}var wh=new Set(["backgroundImage"]);function Eh(e,t,r,o,n,s=[]){if(!t||typeof t!="object"||Array.isArray(t))return e;for(let i of Object.keys(t)){let a=t[i];if(Rh(a))continue;if(wc(a)){if(a.ref.trim()==="")continue;let l=vt(r,a.ref);if(l==null||wc(l))continue;a=l}let u=[...s,i];if(!wh.has(i)&&a!==null&&typeof a=="object"&&!Array.isArray(a)&&!wc(a)){let l=e[i]&&typeof e[i]=="object"&&!Array.isArray(e[i])?e[i]:{};e[i]=Eh({...l},a,r,o,n,u)}else e[i]=wh.has(i)&&a!==null&&typeof a=="object"&&!Array.isArray(a)?{...a}:a,o&&n&&(n[N1(u)]=D1(o))}return e}function Ii(e,t){if(!e)return null;let r=A1(e,t);return r&&typeof r=="object"&&!Array.isArray(r)?r:null}var M1=["color.background","color.gradient","background","spacing","dimensions","border","shadow","filter"];function V1(e){return e.startsWith("elements.")?!1:M1.some(t=>e===t||e.startsWith(`${t}.`))}function Th(e,t){if(!e||typeof e!="object")return;let[r,...o]=t;if(o.length===0){delete e[r];return}let n=e[r];n&&typeof n=="object"&&(Th(n,o),Object.keys(n).length===0&&delete e[r])}function B1(e,t){for(let r of Object.keys(t))t[r].layer==="root"&&V1(r)&&(Th(e,r.split(".")),delete t[r])}function j1(e,t,r){let o=e?.background?.backgroundImage;if(!o)return;let n=Ym(o,{...t,_links:r??void 0});n!==void 0&&(e.background.backgroundImage=n)}function xh(e,{blockName:t,variationName:r=null,elements:o=null,viewport:n=null,pseudoState:s=null}={}){if(!e||!e.styles||!t)return bc;let i=e.styles,a={viewport:n,pseudoState:s},u=i,l=i.blocks?.[t]??null,c=(o??[]).map(x=>i.elements?.[x]??null).filter(x=>!!x),f=r?Ai(e,t,r)??null:null,m=[ho(go(u),mo("root")),...c.map(x=>ho(go(x),mo("element"))),l?ho(go(l),mo("block")):null,f?ho(go(f),mo("blockVariation")):null];Ch(a)||m.push(ho(go(Ii(u,a)),mo("root")),...c.map(x=>ho(go(Ii(x,a)),mo("element"))),l?ho(go(Ii(l,a)),mo("block")):null,f?ho(go(Ii(f,a)),mo("blockVariation")):null);let g=m.filter(Boolean);if(g.length===0)return bc;let d={},v=g.reduce((x,C)=>Eh(x,C.styles,e,C.source,d),{});return B1(v,d),j1(v,e,e._links??null),{value:v,sources:d}}var z1={},Sh=new WeakMap;function _h(e,t={}){let r=e?.styles;if(!r||typeof r!="object")return xh(e,t);let o=Sh.get(r);o||(o=new WeakMap,Sh.set(r,o));let n=e?._links??z1,s=o.get(n);s||(s=new Map,o.set(n,s));let i=`${t.elements?.join(",")??""}:${t.viewport??""}:${t.pseudoState??""}`,a=(t.blockName||"")+""+(t.variationName||"")+""+i;if(s.has(a))return s.get(a);let u=xh(e,t);return s.set(a,u),u}var Ph=h(as(),1),{lock:Oh,unlock:S5}=(0,Ph.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-engine");var En={};Oh(En,{getResponsiveMediaQueries:bh,getViewportBreakpoints:vc,getViewportBreakpointValueInPixels:yc,getDuotoneFilter:gh,getDuotoneStylesheet:hh,getDuotoneUnsetStylesheet:mh,resolveStyle:_h,getVariationStyle:Ai});var Sc=h(ke(),1);var kh=h(ke(),1),Tt=(0,kh.createContext)({user:{styles:{},settings:{}},base:{styles:{},settings:{}},merged:{styles:{},settings:{}},onChange:()=>{},fontLibraryEnabled:!1});var Fh=h(Y(),1);function ms({children:e,value:t,baseValue:r,onChange:o,fontLibraryEnabled:n}){let s=(0,Sc.useMemo)(()=>Bo(r,t),[r,t]),i=(0,Sc.useMemo)(()=>({user:t,base:r,merged:s,onChange:o,fontLibraryEnabled:n}),[t,r,s,o,n]);return(0,Fh.jsx)(Tt.Provider,{value:i,children:e})}var Jr=h(ce(),1),Zh=h(xe(),1);var tx=h(Xt(),1),rx=h(nr(),1);var Ah=h(Y(),1);function Cc({className:e,...t}){return(0,Ah.jsx)(is,{className:st(e,"global-styles-ui-icon-with-current-color"),...t})}var yo=h(ce(),1);var jo=h(Y(),1);function U1({icon:e,children:t,...r}){return(0,jo.jsxs)(yo.__experimentalItem,{...r,children:[e&&(0,jo.jsxs)(yo.__experimentalHStack,{justify:"flex-start",children:[(0,jo.jsx)(Cc,{icon:e,size:24}),(0,jo.jsx)(yo.FlexItem,{children:t})]}),!e&&t]})}function Xr(e){return(0,jo.jsx)(yo.Navigator.Button,{as:U1,...e})}var G1=h(ce(),1);var Y1=h(xe(),1),Bh=h(Dt(),1);var Rc=function(e){var t=e/255;return t<.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},Ec=function(e){return .2126*Rc(e.r)+.7152*Rc(e.g)+.0722*Rc(e.b)};function Ih(e){e.prototype.luminance=function(){return t=Ec(this.rgba),(r=2)===void 0&&(r=0),o===void 0&&(o=Math.pow(10,r)),Math.round(o*t)/o+0;var t,r,o},e.prototype.contrast=function(t){t===void 0&&(t="#FFF");var r,o,n,s,i,a,u,l=t instanceof e?t:new e(t);return s=this.rgba,i=l.toRgb(),a=Ec(s),u=Ec(i),r=a>u?(a+.05)/(u+.05):(u+.05)/(a+.05),(o=2)===void 0&&(o=0),n===void 0&&(n=Math.pow(10,o)),Math.floor(n*r)/n+0},e.prototype.isReadable=function(t,r){return t===void 0&&(t="#FFF"),r===void 0&&(r={}),this.contrast(t)>=(a=(i=(o=r).size)===void 0?"normal":i,(s=(n=o.level)===void 0?"AA":n)==="AAA"&&a==="normal"?7:s==="AA"&&a==="large"?3:4.5);var o,n,s,i,a}}var Cr=h(ke(),1),Mh=h(Xt(),1),Vh=h(nr(),1),_c=h(xe(),1);var mt=h(xe(),1);var Lh=h(as(),1),{lock:Z5,unlock:Be}=(0,Lh.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-ui");var{getViewportBreakpoints:Q5}=Be(En),$5={link:[{value:":link",label:(0,mt.__)("Link")},{value:":any-link",label:(0,mt.__)("Any Link")},{value:":visited",label:(0,mt.__)("Visited")},{value:":hover",label:(0,mt.__)("Hover")},{value:":focus",label:(0,mt.__)("Focus")},{value:":focus-visible",label:(0,mt.__)("Focus-visible")},{value:":active",label:(0,mt.__)("Active")}],button:[{value:":link",label:(0,mt.__)("Link")},{value:":any-link",label:(0,mt.__)("Any Link")},{value:":visited",label:(0,mt.__)("Visited")},{value:":hover",label:(0,mt.__)("Hover")},{value:":focus",label:(0,mt.__)("Focus")},{value:":focus-visible",label:(0,mt.__)("Focus-visible")},{value:":active",label:(0,mt.__)("Active")}]},eI={"core/button":[{value:":hover",label:(0,mt.__)("Hover")},{value:":focus",label:(0,mt.__)("Focus")},{value:":focus-visible",label:(0,mt.__)("Focus-visible")},{value:":active",label:(0,mt.__)("Active")}]},tI=[{value:"@tablet",label:(0,mt.__)("Tablet")},{value:"@mobile",label:(0,mt.__)("Mobile")}];function Tc(e,t){if(!t?.length||typeof e!="object"||!e||!Object.keys(e).length)return e;for(let r in e)t.includes(r)?delete e[r]:typeof e[r]=="object"&&Tc(e[r],t);return e}var Li=(e,t)=>{if(!e||!t?.length)return{};let r={};return Object.keys(e).forEach(o=>{if(t.includes(o))r[o]=e[o];else if(typeof e[o]=="object"){let n=Li(e[o],t);Object.keys(n).length&&(r[o]=n)}}),r};function hs(e,t){let r=Li(structuredClone(e),t);return fs(r,e)}function Nh(e,t){if(!Array.isArray(e)||!t)return null;let o=t.replace("var(","").replace(")","")?.split("--").slice(-1)[0];return e.find(n=>n.slug===o)}function Dh(e){let t=e?.settings?.typography?.fontFamilies?.theme,r=e?.settings?.typography?.fontFamilies?.custom,o=[];t&&r?o=[...t,...r]:t?o=t:r&&(o=r);let n=e?.styles?.typography?.fontFamily,s=Nh(o,n),i=e?.styles?.elements?.heading?.typography?.fontFamily,a;return i?a=Nh(o,e?.styles?.elements?.heading?.typography?.fontFamily):a=s,[s,a]}ph([Ih]);function Xe(e,t,r="merged",o=!0,n){let{user:s,base:i,merged:a,onChange:u}=(0,Cr.useContext)(Tt),l=n?.split(".").filter(Boolean)??[],c=l.find(x=>x.startsWith(":")),f=l.filter(x=>!x.startsWith(":")).join("."),m=[e,f].filter(Boolean).join("."),g=a;r==="base"?g=i:r==="user"&&(g=s);let d=(0,Cr.useMemo)(()=>{let x=ki(g,m,t,o);return c?x?.[c]??{}:x},[g,m,t,o,c]),v=(0,Cr.useCallback)(x=>{let C=x;c&&(C={...ki(s,m,t,!1),[c]:x});let w=uc(s,m,C,t);u(w)},[s,u,m,t,c]);return[d,v]}function Je(e,t,r="merged"){let{user:o,base:n,merged:s,onChange:i}=(0,Cr.useContext)(Tt),a=s;r==="base"?a=n:r==="user"&&(a=o);let u=(0,Cr.useMemo)(()=>ac(a,e,t),[a,e,t]),l=(0,Cr.useCallback)(c=>{let f=lc(o,e,c,t);i(f)},[o,i,e,t]);return[u,l]}var H1=[];function W1({title:e,settings:t,styles:r}){return e===(0,_c.__)("Default")||Object.keys(t||{}).length>0||Object.keys(r||{}).length>0}function Ni(e=[]){let{variationsFromTheme:t}=(0,Mh.useSelect)(o=>({variationsFromTheme:o(Vh.store).__experimentalGetCurrentThemeGlobalStylesVariations?.()||H1}),[]),{user:r}=(0,Cr.useContext)(Tt);return(0,Cr.useMemo)(()=>{let o=structuredClone(r),n=Tc(o,e);n.title=(0,_c.__)("Default");let s=t.filter(a=>hs(a,e)).map(a=>Bo(n,a)),i=[n,...s];return i?.length?i.filter(W1):[]},[e,r,t])}var Pc=h(Y(),1),{useHasDimensionsPanel:dI,useHasTypographyPanel:pI,useHasColorPanel:mI,useSettingsForBlockElement:hI,useHasBackgroundPanel:gI}=Be(Bh.privateApis);var Nr=h(ce(),1);function Tn(){let[e="black"]=Xe("color.text"),[t="white"]=Xe("color.background"),[r=e]=Xe("elements.h1.color.text"),[o=r]=Xe("elements.link.color.text"),[n=o]=Xe("elements.button.color.background"),[s]=Je("color.palette.core")||[],[i]=Je("color.palette.theme")||[],[a]=Je("color.palette.custom")||[],u=(i??[]).concat(a??[]).concat(s??[]),l=u.filter(({color:m})=>m===e),c=u.filter(({color:m})=>m===n),f=l.concat(c).concat(u).filter(({color:m})=>m!==t).slice(0,2);return{paletteColors:u,highlightedColors:f}}var Uh=h(ke(),1),Hh=h(ce(),1),kc=h(xe(),1);function q1(e,t){return t.length===0?null:(t.sort((r,o)=>Math.abs(e-r)-Math.abs(e-o)),t[0])}function Z1(e){let t=[];return e.forEach(r=>{let o=String(r.fontWeight).split(" ");if(o.length===2){let n=parseInt(o[0]),s=parseInt(o[1]);for(let i=n;i<=s;i+=100)t.push(i)}else o.length===1&&t.push(parseInt(o[0]))}),t}function jh(e){let t=/^(?!generic\([ a-zA-Z\-]+\)$)(?!^[a-zA-Z\-]+$).+/,r=e.trim(),o=n=>(n=n.trim(),n.match(t)?(n=n.replace(/^["']|["']$/g,""),`"${n}"`):n);return r.includes(",")?r.split(",").map(o).filter(n=>n!=="").join(", "):o(r)}function Oc(e){if(!e)return"";let t=e.trim();return t.includes(",")&&(t=(t.split(",").find(r=>r.trim()!=="")??"").trim()),t=t.replace(/^["']|["']$/g,""),window.navigator.userAgent.toLowerCase().includes("firefox")&&(t=`"${t}"`),t}function _n(e){let t={fontFamily:jh(e.fontFamily)};if(!("fontFace"in e)||!Array.isArray(e.fontFace))return t.fontWeight="400",t.fontStyle="normal",t;if(e.fontFace){let r=e.fontFace.filter(o=>o?.fontStyle&&o.fontStyle.toLowerCase()==="normal");if(r.length>0){t.fontStyle="normal";let o=Z1(r),n=q1(400,o);t.fontWeight=String(n)||"400"}else t.fontStyle=e.fontFace.length&&e.fontFace[0].fontStyle||"normal",t.fontWeight=e.fontFace.length&&String(e.fontFace[0].fontWeight)||"400"}return t}function zh(e){return{fontFamily:jh(e.fontFamily),fontStyle:e.fontStyle||"normal",fontWeight:e.fontWeight||"400"}}var gs=h(Y(),1);function Di({fontSize:e,variation:t}){let{base:r}=(0,Uh.useContext)(Tt),o=r;t&&(o={...r,...t});let[n]=Xe("color.text"),[s,i]=Dh(o),a=s?_n(s):{},u=i?_n(i):{};return n&&(a.color=n,u.color=n),e&&(a.fontSize=e,u.fontSize=e),(0,gs.jsxs)(Hh.__unstableMotion.div,{animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:.3,type:"tween"},style:{textAlign:"center",lineHeight:1},children:[(0,gs.jsx)("span",{style:u,children:(0,kc._x)("A","Uppercase letter A")}),(0,gs.jsx)("span",{style:a,children:(0,kc._x)("a","Lowercase letter A")})]})}var Wh=h(ce(),1);var Gh=h(Y(),1);function Yh({normalizedColorSwatchSize:e,ratio:t}){let{highlightedColors:r}=Tn(),o=e*t;return r.map(({slug:n,color:s},i)=>(0,Gh.jsx)(Wh.__unstableMotion.div,{style:{height:o,width:o,background:s,borderRadius:o/2},animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:i===1?.2:.1}},`${n}-${i}`))}var qh=h(ce(),1),Pn=h(No(),1),zo=h(ke(),1);var Kr=h(Y(),1),Fc=248,Ac=152,X1={leading:!0,trailing:!0};function K1({children:e,label:t,isFocused:r,withHoverView:o}){let[n="white"]=Xe("color.background"),[s]=Xe("color.gradient"),i=(0,Pn.useReducedMotion)(),[a,u]=(0,zo.useState)(!1),[l,{width:c}]=(0,Pn.useResizeObserver)(),[f,m]=(0,zo.useState)(c),[g,d]=(0,zo.useState)(),v=(0,Pn.useThrottle)(m,250,X1);(0,zo.useLayoutEffect)(()=>{c&&v(c)},[c,v]),(0,zo.useLayoutEffect)(()=>{let b=f?f/Fc:1,R=b-(g||0);(Math.abs(R)>.1||!g)&&d(b)},[f,g]);let x=c?c/Fc:1,C=g||x,w=!!c;return(0,Kr.jsxs)(Kr.Fragment,{children:[(0,Kr.jsx)("div",{style:{position:"relative"},children:l}),!w&&(0,Kr.jsx)(ec,{className:"global-styles-ui-preview__wrapper",style:{aspectRatio:Fc/Ac}}),w&&(0,Kr.jsx)("div",{className:st("global-styles-ui-preview__wrapper",{"is-hoverable":o}),style:{height:Ac*C},onMouseEnter:()=>u(!0),onMouseLeave:()=>u(!1),tabIndex:-1,children:(0,Kr.jsx)(qh.__unstableMotion.div,{style:{height:Ac*C,width:"100%",background:s??n},initial:"start",animate:(a||r)&&!i&&t?"hover":"start",children:[].concat(e).map((b,R)=>b({ratio:C,key:R}))})})]})}var On=K1;var Kt=h(Y(),1),J1={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},Q1={hover:{opacity:1},start:{opacity:.5}},$1={hover:{scale:1,opacity:1},start:{scale:0,opacity:0}};function ex({label:e,isFocused:t,withHoverView:r,variation:o}){let[n]=Xe("typography.fontWeight"),[s="serif"]=Xe("typography.fontFamily"),[i=s]=Xe("elements.h1.typography.fontFamily"),[a=n]=Xe("elements.h1.typography.fontWeight"),[u="black"]=Xe("color.text"),[l=u]=Xe("elements.h1.color.text"),{paletteColors:c}=Tn();return(0,Kt.jsxs)(On,{label:e,isFocused:t,withHoverView:r,children:[({ratio:f,key:m})=>(0,Kt.jsx)(Nr.__unstableMotion.div,{variants:J1,style:{height:"100%",overflow:"hidden"},children:(0,Kt.jsxs)(Nr.__experimentalHStack,{spacing:10*f,justify:"center",style:{height:"100%",overflow:"hidden"},children:[(0,Kt.jsx)(Di,{fontSize:65*f,variation:o}),(0,Kt.jsx)(Nr.__experimentalVStack,{spacing:4*f,children:(0,Kt.jsx)(Yh,{normalizedColorSwatchSize:32,ratio:f})})]})},m),({key:f})=>(0,Kt.jsx)(Nr.__unstableMotion.div,{variants:r?Q1:void 0,style:{height:"100%",width:"100%",position:"absolute",top:0,overflow:"hidden",filter:"blur(60px)",opacity:.1},children:(0,Kt.jsx)(Nr.__experimentalHStack,{spacing:0,justify:"flex-start",style:{height:"100%",overflow:"hidden"},children:c.slice(0,4).map(({color:m},g)=>(0,Kt.jsx)("div",{style:{height:"100%",background:m,flexGrow:1}},g))})},f),({ratio:f,key:m})=>(0,Kt.jsx)(Nr.__unstableMotion.div,{variants:$1,style:{height:"100%",width:"100%",overflow:"hidden",position:"absolute",top:0},children:(0,Kt.jsx)(Nr.__experimentalVStack,{spacing:3*f,justify:"center",style:{height:"100%",overflow:"hidden",padding:10*f,boxSizing:"border-box"},children:e&&(0,Kt.jsx)("div",{style:{fontSize:40*f,fontFamily:i,color:l,fontWeight:a,lineHeight:"1em",textAlign:"center"},children:e})})},m)]})}var Ic=ex;var Xh=h(Y(),1);var Nc=h(Sn(),1),kn=h(xe(),1),Ho=h(ce(),1),Dc=h(Xt(),1),vo=h(ke(),1),Mi=h(Dt(),1),tg=h(No(),1);import{speak as ix}from"@wordpress/a11y";var Kh=h(Sn(),1),Jh=h(Xt(),1),ox=h(ce(),1);var nx=h(Y(),1);function sx(e,t){return e?.filter(r=>r.source==="block"||t.includes(r.name))||[]}function Lc(e){let t=(0,Jh.useSelect)(n=>{let{getBlockStyles:s}=n(Kh.store);return s(e)},[e]),[r]=Xe("variations",e),o=Object.keys(r??{});return sx(t,o)}var Uo=h(ce(),1),Qh=h(xe(),1);var $h=h(Dt(),1);var eg=h(Y(),1),{StateControl:ZI,StateControlBadges:XI}=Be($h.privateApis);var Dr=h(Y(),1),{useHasDimensionsPanel:ax,useHasTypographyPanel:lx,useHasBorderPanel:cx,useSettingsForBlockElement:ux,useHasColorPanel:fx,useHasBackgroundPanel:dx}=Be(Mi.privateApis);function px(){let e=(0,Dc.useSelect)(n=>n(Nc.store).getBlockTypes(),[]),t=(n,s)=>{let{core:i,noncore:a}=n;return(s.name.startsWith("core/")?i:a).push(s),n},{core:r,noncore:o}=e.reduce(t,{core:[],noncore:[]});return[...r,...o]}function mx(e){let[t]=Je("",e),r=ux(t,e),o=lx(r),n=fx(r),s=dx(r),i=cx(r),a=ax(r),u=i||a,l=!!Lc(e)?.length;return o||n||s||u||l}function hx({block:e}){return mx(e.name)?(0,Dr.jsx)(Xr,{path:"/blocks/"+encodeURIComponent(e.name),children:(0,Dr.jsxs)(Ho.__experimentalHStack,{justify:"flex-start",children:[(0,Dr.jsx)(Mi.BlockIcon,{icon:e.icon}),(0,Dr.jsx)(Ho.FlexItem,{children:e.title})]})}):null}function gx({filterValue:e}){let t=px(),r=(0,tg.useDebounce)(ix,500),{isMatchingSearchTerm:o}=(0,Dc.useSelect)(Nc.store),n=e?t.filter(i=>o(i,e)):t,s=(0,vo.useRef)(null);return(0,vo.useEffect)(()=>{if(!e)return;let i=s.current?.childElementCount||0,a=(0,kn.sprintf)((0,kn._n)("%d result found.","%d results found.",i),i);r(a,"polite")},[e,r]),(0,Dr.jsx)("div",{ref:s,className:"global-styles-ui-block-types-item-list",role:"list",children:n.length===0?(0,Dr.jsx)(Ho.__experimentalText,{align:"center",as:"p",children:(0,kn.__)("No blocks found.")}):n.map(i=>(0,Dr.jsx)(hx,{block:i},"menu-itemblock-"+i.name))})}var oL=(0,vo.memo)(gx);var xx=h(Sn(),1),sg=h(Dt(),1),Mc=h(ke(),1),Sx=h(Xt(),1),Cx=h(nr(),1),Vc=h(ce(),1),ig=h(xe(),1);var yx=h(Dt(),1),rg=h(Sn(),1),vx=h(ce(),1),bx=h(ke(),1);var wx=h(Y(),1),{getViewportBreakpoints:uL,getViewportBreakpointValueInPixels:fL}=Be(En);var og=h(ce(),1),ng=h(Y(),1);function ur({children:e,level:t=2}){return(0,ng.jsx)(og.__experimentalHeading,{className:"global-styles-ui-subtitle",level:t,children:e})}var Bc=h(Y(),1);var{useHasDimensionsPanel:TL,useHasTypographyPanel:_L,useHasBorderPanel:PL,useSettingsForBlockElement:OL,useHasColorPanel:kL,useHasFiltersPanel:FL,useHasImageSettingsPanel:AL,useHasBackgroundPanel:IL,BackgroundPanel:LL,BorderPanel:NL,ColorPanel:DL,TypographyPanel:ML,DimensionsPanel:VL,FiltersPanel:BL,ImageSettingsPanel:jL,AdvancedPanel:zL}=Be(sg.privateApis);var DE=h(xe(),1),ME=h(ce(),1),VE=h(ke(),1);var Rx=h(ce(),1);var Ex=h(Y(),1);var Tx=h(xe(),1),Vi=h(ce(),1);var ag=h(Y(),1);var zi=h(ce(),1);var lg=h(ce(),1);var Bi=h(Y(),1),_x=({variation:e,isFocused:t,withHoverView:r})=>(0,Bi.jsx)(On,{label:e.title,isFocused:t,withHoverView:r,children:({ratio:o,key:n})=>(0,Bi.jsx)(lg.__experimentalHStack,{spacing:10*o,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Bi.jsx)(Di,{variation:e,fontSize:85*o})},n)}),cg=_x;var Wo=h(ke(),1),fg=h(jc(),1),ji=h(xe(),1);var bo=h(Y(),1);function Fn({variation:e,children:t,isPill:r=!1,properties:o,showTooltip:n=!1}){let[s,i]=(0,Wo.useState)(!1),{base:a,user:u,onChange:l}=(0,Wo.useContext)(Tt),c=(0,Wo.useMemo)(()=>{let x=Bo(a,e);return o&&(x=Li(x,o)),{user:e,base:a,merged:x,onChange:()=>{}}},[e,a,o]),f=()=>l(e),m=x=>{x.keyCode===fg.ENTER&&(x.preventDefault(),f())},g=(0,Wo.useMemo)(()=>fs(u,e),[u,e]),d=e?.title;e?.description&&(d=(0,ji.sprintf)((0,ji._x)("%1$s (%2$s)","variation label"),e?.title,e?.description));let v=(0,bo.jsx)("div",{className:st("global-styles-ui-variations_item",{"is-active":g}),role:"button",onClick:f,onKeyDown:m,tabIndex:0,"aria-label":d,"aria-current":g,onFocus:()=>i(!0),onBlur:()=>i(!1),children:(0,bo.jsx)("div",{className:st("global-styles-ui-variations_item-preview",{"is-pill":r}),children:t(s)})});return(0,bo.jsx)(Tt.Provider,{value:c,children:n?(0,bo.jsxs)(xn.Root,{children:[(0,bo.jsx)(xn.Trigger,{render:v}),(0,bo.jsx)(xn.Popup,{children:e?.title})]}):v})}var Go=h(Y(),1),dg=["typography"];function Ui({title:e,gap:t=2}){let r=Ni(dg);return r?.length<=1?null:(0,Go.jsxs)(zi.__experimentalVStack,{spacing:3,children:[e&&(0,Go.jsx)(ur,{level:3,children:e}),(0,Go.jsx)(zi.__experimentalGrid,{columns:3,gap:t,className:"global-styles-ui-style-variations-container",children:r.map((o,n)=>(0,Go.jsx)(Fn,{variation:o,properties:dg,showTooltip:!0,children:()=>(0,Go.jsx)(cg,{variation:o})},n))})]})}var LE=h(xe(),1),Cs=h(ce(),1);var NE=h(ke(),1);var Qr=h(ke(),1),Co=h(Xt(),1),So=h(nr(),1),Wc=h(xe(),1);var zc=h(mg(),1),hg=h(nr(),1),gg="/wp/v2/font-families";function yg(e){let{receiveEntityRecords:t}=e.dispatch(hg.store);t("postType","wp_font_family",[],void 0,!0)}async function vg(e,t){let o=await(0,zc.default)({path:gg,method:"POST",body:e});return yg(t),{id:o.id,...o.font_family_settings,fontFace:[]}}async function bg(e,t,r){let o={path:`${gg}/${e}/font-faces`,method:"POST",body:t},n=await(0,zc.default)(o);return yg(r),{id:n.id,...n.font_face_settings}}var An=function(){return An=Object.assign||function(t){for(var r,o=1,n=arguments.length;o{o.forEach(n=>{n.family===Oc(e?.fontFamily)&&n.weight===e?.fontWeight&&n.style===e?.fontStyle&&o.delete(n)})};if((t==="document"||t==="all")&&r(document.fonts),t==="iframe"||t==="all"){let o=document.querySelector('iframe[name="editor-canvas"]');o?.contentDocument&&r(o.contentDocument.fonts)}}function In(e){if(!e)return;let t;if(Array.isArray(e)?t=e[0]:t=e,!t.startsWith("file:."))return kx(t)||(t=encodeURI(t)),t}function Og(e){let t=new FormData,{fontFace:r,category:o,...n}=e,s={...n,slug:Hi(e.slug)};return t.append("font_family_settings",JSON.stringify(s)),t}function kg(e){return(e?.fontFace??[]).map((r,o)=>{let n={...r},s=new FormData;if(n.file){let i=Array.isArray(n.file)?n.file:[n.file],a=[];i.forEach((u,l)=>{let c=`file-${o}-${l}`;s.append(c,u,u.name),a.push(c)}),n.src=a.length===1?a[0]:a,delete n.file,s.append("font_face_settings",JSON.stringify(n))}else s.append("font_face_settings",JSON.stringify(n));return s})}async function Fg(e,t,r){let o=[];for(let s of t)try{let i=await bg(e,s,r);o.push({status:"fulfilled",value:i})}catch(i){o.push({status:"rejected",reason:i})}let n={errors:[],successes:[]};return o.forEach((s,i)=>{if(s.status==="fulfilled"&&s.value){let a=s.value;n.successes.push(a)}else s.reason&&n.errors.push({data:t[i],message:s.reason.message})}),n}async function Ag(e){e=Array.isArray(e)?e:[e];let t=await Promise.all(e.map(async r=>fetch(new Request(r)).then(o=>{if(!o.ok)throw new Error(`Error downloading font face asset from ${r}. Server responded with status: ${o.status}`);return o.blob()}).then(o=>{let n=r.split("/").pop();return new _g([o],n,{type:o.type})})));return t.length===1?t[0]:t}function Hc(e,t){return t.findIndex(r=>r.fontWeight===e.fontWeight&&r.fontStyle===e.fontStyle)!==-1}function Ig(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let s of t){let i=n[s];n=n[s]=Array.isArray(i)?[...i]:{...i}}return n[o]=r,e}function Gi(e,t,r=[]){let o=u=>u.slug===e.slug,n=u=>u.find(o),s=u=>u?r.filter(l=>!o(l)):[...r,e],i=u=>{let l=f=>f.fontWeight===t.fontWeight&&f.fontStyle===t.fontStyle;if(!u)return[...r,{...e,fontFace:[t]}];let c=u.fontFace||[];return c.find(l)?c=c.filter(f=>!l(f)):c=[...c,t],c.length===0?r.filter(f=>!o(f)):r.map(f=>o(f)?{...f,fontFace:c}:f)},a=n(r);return t?i(a):s(a)}var Lg=h(Y(),1),Mt=(0,Qr.createContext)({});Mt.displayName="FontLibraryContext";function Ax({children:e}){let t=(0,Co.useRegistry)(),{saveEntityRecord:r,deleteEntityRecord:o}=(0,Co.useDispatch)(So.store),{globalStylesId:n}=(0,Co.useSelect)(E=>{let{__experimentalGetCurrentGlobalStylesId:L}=E(So.store);return{globalStylesId:L()}},[]),s=(0,So.useEntityRecord)("root","globalStyles",n),[i,a]=(0,Qr.useState)(!1),{records:u=[],isResolving:l}=(0,So.useEntityRecords)("postType","wp_font_family",{_embed:!0}),c=(u||[]).map(E=>({id:E.id,...E.font_family_settings||{},fontFace:E?._embedded?.font_faces?.map(L=>L.font_face_settings)||[]}))||[],[f,m]=Je("typography.fontFamilies"),g=async E=>{if(!s.record)return;let L=s.record,$=Ig(L??{},["settings","typography","fontFamilies"],E);await r("root","globalStyles",$)},[d,v]=(0,Qr.useState)(""),[x,C]=(0,Qr.useState)(void 0),w=f?.theme?f.theme.map(E=>wo(E,{source:"theme"})).sort((E,L)=>E.name.localeCompare(L.name)):[],b=f?.custom?f.custom.map(E=>wo(E,{source:"custom"})).sort((E,L)=>E.name.localeCompare(L.name)):[],R=c?c.map(E=>wo(E,{source:"custom"})).sort((E,L)=>E.name.localeCompare(L.name)):[];(0,Qr.useEffect)(()=>{d||C(void 0)},[d]);let A=E=>{if(!E){C(void 0);return}let $=(E.source==="theme"?w:R).find(F=>F.slug===E.slug);C({...$||E,source:E.source})},[T]=(0,Qr.useState)(new Set),_=E=>E.reduce(($,F)=>{let Z=F?.fontFace&&F.fontFace?.length>0?F?.fontFace.map(se=>`${se.fontStyle??""}${se.fontWeight??""}`):["normal400"];return $[F.slug]=Z,$},{}),P=E=>_(E==="theme"?w:b),N=(E,L,$,F)=>!L&&!$?!!P(F)[E]:!!P(F)[E]?.includes((L??"")+($??"")),q=(E,L)=>P(L)[E]||[];async function H(E){a(!0);try{let L=[],$=[];for(let Z of E){let se=!1,we=await(0,Co.resolveSelect)(So.store).getEntityRecords("postType","wp_font_family",{slug:Z.slug,per_page:1,_embed:!0}),ie=we&&we.length>0?we[0]:null,ve=ie?{id:ie.id,...ie.font_family_settings,fontFace:(ie?._embedded?.font_faces??[]).map(Ae=>Ae.font_face_settings)||[]}:null;ve||(se=!0,ve=await vg(Og(Z),t));let Ee=ve.fontFace&&Z.fontFace?ve.fontFace.filter(Ae=>Ae&&Z.fontFace&&Hc(Ae,Z.fontFace)):[];ve.fontFace&&Z.fontFace&&(Z.fontFace=Z.fontFace.filter(Ae=>!Hc(Ae,ve.fontFace)));let ee=[],Fe=[];if(Z?.fontFace?.length??!1){let Ae=await Fg(ve.id,kg(Z),t);ee=Ae?.successes,Fe=Ae?.errors}(ee?.length>0||Ee?.length>0)&&(ve.fontFace=[...ee],L.push(ve)),ve&&!Z?.fontFace?.length&&L.push(ve),se&&(Z?.fontFace?.length??0)>0&&ee?.length===0&&await o("postType","wp_font_family",ve.id,{force:!0}),$=$.concat(Fe)}let F=$.reduce((Z,se)=>Z.includes(se.message)?Z:[...Z,se.message],[]);if(L.length>0){let Z=W(L);await g(Z)}if(F.length>0){let Z=new Error((0,Wc.__)("There was an error installing fonts."));throw Z.installationErrors=F,Z}}finally{a(!1)}}async function S(E){if(!E?.id)throw new Error((0,Wc.__)("Font family to uninstall is not defined."));try{await o("postType","wp_font_family",E.id,{force:!0});let L=I(E);return await g(L),{deleted:!0}}catch(L){throw console.error("There was an error uninstalling the font family:",L),L}}let I=E=>{let $=(f?.[E.source??""]??[]).filter(Z=>Z.slug!==E.slug),F={...f,[E.source??""]:$};return m(F),E.fontFace&&E.fontFace.forEach(Z=>{ys(Z,"all")}),F},W=E=>{let L=O(E),$={...f,custom:Pg(f?.custom,L)};return m($),D(L),$},O=E=>E.map(({id:L,fontFace:$,...F})=>({...F,...$&&$.length>0?{fontFace:$.map(({id:Z,...se})=>se)}:{}})),D=E=>{E.forEach(L=>{L.fontFace&&L.fontFace.forEach($=>{let F=In($?.src??"");F&&xo($,F,"all")})})},J=(E,L)=>{let $=f?.[E.source??""]??[],F=Gi(E,L,$);m({...f,[E.source??""]:F});let Z=N(E.slug,L?.fontStyle??"",L?.fontWeight??"",E.source??"custom");if(L&&Z)ys(L,"all");else{let se=In(L?.src??"");L&&se&&xo(L,se,"all")}},M=async E=>{if(!E.src)return;let L=In(E.src);!L||T.has(L)||(xo(E,L,"document"),T.add(L))};return(0,Lg.jsx)(Mt.Provider,{value:{libraryFontSelected:x,handleSetLibraryFontSelected:A,fontFamilies:f??{},baseCustomFonts:R,isFontActivated:N,getFontFacesActivated:q,loadFontFaceAsset:M,installFonts:H,uninstallFontFamily:S,toggleActivateFont:J,getAvailableFontsOutline:_,modalTabOpen:d,setModalTabOpen:v,saveFontFamilies:g,isResolvingLibrary:l,isInstalling:i},children:e})}var Yi=Ax;var la=h(xe(),1),Xc=h(ce(),1),gy=h(nr(),1),AE=h(Xt(),1);var Ie=h(ce(),1),bs=h(nr(),1),Gc=h(Xt(),1),Br=h(ke(),1),at=h(xe(),1);var Nn=h(xe(),1),Zi=h(ke(),1),dr=h(ce(),1);var Ng=h(ce(),1),Mr=h(ke(),1);var qi=h(Y(),1);function Ix(e){if(e.preview)return e.preview;if(e.src)return Array.isArray(e.src)?e.src[0]:e.src}function Lx(e){return"fontStyle"in e&&e.fontStyle||"fontWeight"in e&&e.fontWeight?e:"fontFace"in e&&e.fontFace&&e.fontFace.length?e.fontFace.find(t=>t.fontStyle==="normal"&&t.fontWeight==="400")||e.fontFace[0]:{fontStyle:"normal",fontWeight:"400",fontFamily:e.fontFamily}}function Nx({font:e,text:t}){let r=(0,Mr.useRef)(null),o=Lx(e),n=_n(e);t=t||("name"in e?e.name:"");let s=e.preview,[i,a]=(0,Mr.useState)(!1),[u,l]=(0,Mr.useState)(!1),{loadFontFaceAsset:c}=(0,Mr.useContext)(Mt),f=s??Ix(o),m=f&&f.match(/\.(png|jpg|jpeg|gif|svg)$/i),g=zh(o),d={fontSize:"18px",lineHeight:1,opacity:u?"1":"0",...n,...g};return(0,Mr.useEffect)(()=>{let v=new window.IntersectionObserver(([x])=>{a(x.isIntersecting)},{});return r.current&&v.observe(r.current),()=>v.disconnect()},[r]),(0,Mr.useEffect)(()=>{(async()=>i&&(!m&&o.src&&await c(o),l(!0)))()},[o,i,c,m]),(0,qi.jsx)("div",{ref:r,children:m?(0,qi.jsx)("img",{src:f,loading:"lazy",alt:t,className:"font-library__font-variant_demo-image"}):(0,qi.jsx)(Ng.__experimentalText,{style:d,className:"font-library__font-variant_demo-text",children:t})})}var Ln=Nx;var Vr=h(Y(),1);function Dx({font:e,onClick:t,variantsText:r,navigatorPath:o,shouldFocus:n}){let s=e.fontFace?.length||1,i={cursor:t?"pointer":"default"},a=(0,dr.useNavigator)(),u=(0,Zi.useRef)(null);return(0,Zi.useEffect)(()=>{n&&u.current?.focus()},[n]),(0,Vr.jsx)(dr.Button,{ref:u,__next40pxDefaultSize:!0,onClick:()=>{t(),o&&a.goTo(o)},style:i,className:"font-library__font-card",children:(0,Vr.jsxs)(dr.Flex,{justify:"space-between",wrap:!1,children:[(0,Vr.jsx)(Ln,{font:e}),(0,Vr.jsxs)(dr.Flex,{justify:"flex-end",children:[(0,Vr.jsx)(dr.FlexItem,{children:(0,Vr.jsx)(dr.__experimentalText,{className:"font-library__font-card__count",children:r||(0,Nn.sprintf)((0,Nn._n)("%d variant","%d variants",s),s)})}),(0,Vr.jsx)(dr.FlexItem,{children:(0,Vr.jsx)(is,{icon:(0,Nn.isRTL)()?Do:Mo})})]})]})})}var vs=Dx;var Xi=h(ke(),1),Ki=h(ce(),1);var Yo=h(Y(),1);function Mx({face:e,font:t}){let{isFontActivated:r,toggleActivateFont:o}=(0,Xi.useContext)(Mt),n=(t?.fontFace?.length??0)>0?r(t.slug,e.fontStyle,e.fontWeight,t.source):r(t.slug,void 0,void 0,t.source),s=()=>{if((t?.fontFace?.length??0)>0){o(t,e);return}o(t)},i=t.name+" "+Wi(e),a=(0,Xi.useId)();return(0,Yo.jsx)("div",{className:"font-library__font-card",children:(0,Yo.jsxs)(Ki.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Yo.jsx)(Ki.CheckboxControl,{checked:n,onChange:s,id:a}),(0,Yo.jsx)("label",{htmlFor:a,children:(0,Yo.jsx)(Ln,{font:e,text:i,onClick:s})})]})})}var Dg=Mx;function Mg(e){switch(e){case"normal":return 400;case"bold":return 700;case"bolder":return 500;case"lighter":return 300;default:return parseInt(e,10)}}function Ji(e){return e.sort((t,r)=>t.fontStyle==="normal"&&r.fontStyle!=="normal"?-1:r.fontStyle==="normal"&&t.fontStyle!=="normal"?1:t.fontStyle===r.fontStyle?Mg(t.fontWeight?.toString()??"normal")-Mg(r.fontWeight?.toString()??"normal"):!t.fontStyle||!r.fontStyle?t.fontStyle?-1:1:t.fontStyle.localeCompare(r.fontStyle))}var Re=h(Y(),1);function Vg(e){if(!e)return"";let t={};for(let r of Object.keys(e).sort())t[r]=(e[r]??[]).map(o=>({slug:o.slug,fontFace:(o.fontFace??[]).map(n=>`${n.fontStyle}-${n.fontWeight}`).sort()})).sort((o,n)=>o.slug.localeCompare(n.slug));return JSON.stringify(t)}function Vx(){let{baseCustomFonts:e,libraryFontSelected:t,handleSetLibraryFontSelected:r,uninstallFontFamily:o,isResolvingLibrary:n,isInstalling:s,saveFontFamilies:i,getFontFacesActivated:a}=(0,Br.useContext)(Mt),[u,l]=Je("typography.fontFamilies"),[c,f]=(0,Br.useState)(void 0),[m,g]=(0,Br.useState)(!1),[d,v]=(0,Br.useState)(null),[x]=Je("typography.fontFamilies",void 0,"base"),C=(0,Gc.useSelect)(F=>{let{__experimentalGetCurrentGlobalStylesId:Z}=F(bs.store);return Z()},[]),w=(0,bs.useEntityRecord)("root","globalStyles",C),b=w?.edits?.settings?.typography?.fontFamilies,R=w?.record?.settings?.typography?.fontFamilies,A=(0,Br.useMemo)(()=>b===void 0?!1:Vg(b)!==Vg(R),[b,R]),T=u?.theme?u.theme.map(F=>wo(F,{source:"theme"})).sort((F,Z)=>F.name.localeCompare(Z.name)):[],_=new Set(T.map(F=>F.slug)),P=x?.theme?T.concat(x.theme.filter(F=>!_.has(F.slug)).map(F=>wo(F,{source:"theme"})).sort((F,Z)=>F.name.localeCompare(Z.name))):[],N=t?.source==="custom"&&t?.id,q=(0,Gc.useSelect)(F=>{let{canUser:Z}=F(bs.store);return N&&Z("delete",{kind:"postType",name:"wp_font_family",id:N})},[N]),H=!!t&&t?.source!=="theme"&&q,S=()=>{g(!0)},I=async()=>{v(null);try{await i(u),v({type:"success",message:(0,at.__)("Font family updated successfully.")})}catch(F){v({type:"error",message:(0,at.sprintf)((0,at.__)("There was an error updating the font family. %s"),F.message)})}},W=F=>F?!F.fontFace||!F.fontFace.length?[{fontFamily:F.fontFamily,fontStyle:"normal",fontWeight:"400"}]:Ji(F.fontFace):[],O=F=>{let Z=F?.fontFace&&(F?.fontFace?.length??0)>0?F.fontFace.length:1,se=a(F.slug,F.source).length;return(0,at.sprintf)((0,at.__)("%1$d of %2$d active"),se,Z)};(0,Br.useEffect)(()=>{r(t)},[]);let D=t?a(t.slug,t.source).length:0,J=t?.fontFace?.length??(t?.fontFamily?1:0),M=D>0&&D!==J,E=D===J,L=()=>{if(!t||!t?.source)return;let F=u?.[t.source]?.filter(se=>se.slug!==t.slug)??[],Z=E?F:[...F,t];l({...u,[t.source]:Z}),t.fontFace&&t.fontFace.forEach(se=>{if(E)ys(se,"all");else{let we=In(se?.src??"");we&&xo(se,we,"all")}})},$=P.length>0||e.length>0;return(0,Re.jsxs)("div",{className:"font-library__tabpanel-layout",children:[n&&(0,Re.jsx)("div",{className:"font-library__loading",children:(0,Re.jsx)(Ie.ProgressBar,{})}),!n&&(0,Re.jsxs)(Re.Fragment,{children:[(0,Re.jsxs)(Ie.Navigator,{initialPath:t?"/fontFamily":"/",children:[(0,Re.jsx)(Ie.Navigator.Screen,{path:"/",children:(0,Re.jsxs)(Ie.__experimentalVStack,{spacing:"8",children:[d&&(0,Re.jsx)(Ie.Notice,{status:d.type,onRemove:()=>v(null),children:d.message}),!$&&(0,Re.jsx)(Ie.__experimentalText,{as:"p",children:(0,at.__)("No fonts installed.")}),P.length>0&&(0,Re.jsxs)(Ie.__experimentalVStack,{children:[(0,Re.jsx)("h2",{className:"font-library__fonts-title",children:(0,at._x)("Theme","font source")}),(0,Re.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:P.map(F=>(0,Re.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Re.jsx)(vs,{font:F,navigatorPath:"/fontFamily",variantsText:O(F),shouldFocus:F.slug===c,onClick:()=>{v(null),r(F)}})},F.slug))})]}),e.length>0&&(0,Re.jsxs)(Ie.__experimentalVStack,{children:[(0,Re.jsx)("h2",{className:"font-library__fonts-title",children:(0,at._x)("Custom","font source")}),(0,Re.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:e.map(F=>(0,Re.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Re.jsx)(vs,{font:F,navigatorPath:"/fontFamily",variantsText:O(F),shouldFocus:F.slug===c,onClick:()=>{v(null),r(F)}})},F.slug))})]})]})}),(0,Re.jsxs)(Ie.Navigator.Screen,{path:"/fontFamily",children:[t&&(0,Re.jsx)(Bx,{font:t,isOpen:m,setIsOpen:g,setNotice:v,uninstallFontFamily:o,handleSetLibraryFontSelected:r}),(0,Re.jsxs)(Ie.Flex,{justify:"flex-start",children:[(0,Re.jsx)(Ie.Navigator.BackButton,{icon:(0,at.isRTL)()?Mo:Do,size:"small",onClick:()=>{f(t?.slug),r(void 0),v(null)},label:(0,at.__)("Back")}),(0,Re.jsx)(Ie.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:t?.name})]}),d&&(0,Re.jsxs)(Re.Fragment,{children:[(0,Re.jsx)(Ie.__experimentalSpacer,{margin:1}),(0,Re.jsx)(Ie.Notice,{status:d.type,onRemove:()=>v(null),children:d.message}),(0,Re.jsx)(Ie.__experimentalSpacer,{margin:1})]}),(0,Re.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Re.jsx)(Ie.__experimentalText,{children:(0,at.__)("Choose font variants. Keep in mind that too many variants could make your site slower.")}),(0,Re.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Re.jsxs)(Ie.__experimentalVStack,{spacing:0,children:[(0,Re.jsx)(Ie.CheckboxControl,{className:"font-library__select-all",label:(0,at.__)("Select all"),checked:E,onChange:L,indeterminate:M}),(0,Re.jsx)(Ie.__experimentalSpacer,{margin:8}),(0,Re.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:t&&W(t).map((F,Z)=>(0,Re.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Re.jsx)(Dg,{font:t,face:F},`face${Z}`)},`face${Z}`))})]})]})]}),(0,Re.jsxs)(Ie.__experimentalHStack,{justify:"flex-end",className:"font-library__footer",children:[s&&(0,Re.jsx)(Ie.ProgressBar,{}),H&&(0,Re.jsx)(Ie.Button,{__next40pxDefaultSize:!0,isDestructive:!0,variant:"tertiary",onClick:S,children:(0,at.__)("Delete")}),(0,Re.jsx)(Ie.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:I,disabled:!A,accessibleWhenDisabled:!0,children:(0,at.__)("Update")})]})]})]})}function Bx({font:e,isOpen:t,setIsOpen:r,setNotice:o,uninstallFontFamily:n,handleSetLibraryFontSelected:s}){let i=(0,Ie.useNavigator)(),a=async()=>{o(null),r(!1);try{await n(e),i.goBack(),s(void 0),o({type:"success",message:(0,at.__)("Font family uninstalled successfully.")})}catch(l){o({type:"error",message:(0,at.__)("There was an error uninstalling the font family.")+l.message})}},u=()=>{r(!1)};return(0,Re.jsx)(Ie.__experimentalConfirmDialog,{isOpen:t,cancelButtonText:(0,at.__)("Cancel"),confirmButtonText:(0,at.__)("Delete"),onCancel:u,onConfirm:a,size:"medium",children:e&&(0,at.sprintf)((0,at.__)('Are you sure you want to delete "%s" font and all its variants and assets?'),e.name)})}var Qi=Vx;var bt=h(ke(),1),Ce=h(ce(),1),Yg=h(No(),1),rt=h(xe(),1);var qg=h(nr(),1);function Bg(e,t){let{category:r,search:o}=t,n=e||[];return r&&r!=="all"&&(n=n.filter(s=>s.categories&&s.categories.indexOf(r)!==-1)),o&&(n=n.filter(s=>s.font_family_settings&&s.font_family_settings.name.toLowerCase().includes(o.toLowerCase()))),n}function jg(e){return e.reduce((t,r)=>({...t,[r.slug]:(r?.fontFace||[]).reduce((o,n)=>({...o,[`${n.fontStyle}-${n.fontWeight}`]:!0}),{})}),{})}function zg(e,t,r){return t?!!r[e]?.[`${t.fontStyle}-${t.fontWeight}`]:!!r[e]}var ws=h(xe(),1),Vt=h(ce(),1),pr=h(Y(),1);function jx(){let e=()=>{window.localStorage.setItem("wp-font-library-google-fonts-permission","true"),window.dispatchEvent(new Event("storage"))};return(0,pr.jsx)("div",{className:"font-library__google-fonts-confirm",children:(0,pr.jsx)(Vt.Card,{children:(0,pr.jsxs)(Vt.CardBody,{children:[(0,pr.jsx)(Vt.__experimentalHeading,{level:2,children:(0,ws.__)("Connect to Google Fonts")}),(0,pr.jsx)(Vt.__experimentalSpacer,{margin:6}),(0,pr.jsx)(Vt.__experimentalText,{as:"p",children:(0,ws.__)("To install fonts from Google you must give permission to connect directly to Google servers. The fonts you install will be downloaded from Google and stored on your site. Your site will then use these locally-hosted fonts.")}),(0,pr.jsx)(Vt.__experimentalSpacer,{margin:3}),(0,pr.jsx)(Vt.__experimentalText,{as:"p",children:(0,ws.__)("You can alternatively upload files directly on the Upload tab.")}),(0,pr.jsx)(Vt.__experimentalSpacer,{margin:6}),(0,pr.jsx)(Vt.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:e,children:(0,ws.__)("Allow access to Google Fonts")})]})})})}var Ug=jx;var Hg=h(ke(),1),$i=h(ce(),1);var qo=h(Y(),1);function zx({face:e,font:t,handleToggleVariant:r,selected:o}){let n=()=>{if(t?.fontFace){r(t,e);return}r(t)},s=t.name+" "+Wi(e),i=(0,Hg.useId)();return(0,qo.jsx)("div",{className:"font-library__font-card",children:(0,qo.jsxs)($i.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,qo.jsx)($i.CheckboxControl,{checked:o,onChange:n,id:i}),(0,qo.jsx)("label",{htmlFor:i,children:(0,qo.jsx)(Ln,{font:e,text:s,onClick:n})})]})})}var Wg=zx;var he=h(Y(),1),Ux={slug:"all",name:(0,rt._x)("All","font categories")},Gg="wp-font-library-google-fonts-permission",Hx=500;function Wx({slug:e}){let t=e==="google-fonts",r=()=>window.localStorage.getItem(Gg)==="true",[o,n]=(0,bt.useState)(null),[s,i]=(0,bt.useState)(void 0),[a,u]=(0,bt.useState)(null),[l,c]=(0,bt.useState)([]),[f,m]=(0,bt.useState)(1),[g,d]=(0,bt.useState)({}),[v,x]=(0,bt.useState)(t&&!r()),{installFonts:C,isInstalling:w}=(0,bt.useContext)(Mt),{record:b,isResolving:R}=(0,qg.useEntityRecord)("root","fontCollection",e);(0,bt.useEffect)(()=>{let ee=()=>{x(t&&!r())};return ee(),window.addEventListener("storage",ee),()=>window.removeEventListener("storage",ee)},[e,t]);let A=()=>{window.localStorage.setItem(Gg,"false"),window.dispatchEvent(new Event("storage"))};(0,bt.useEffect)(()=>{n(null)},[e]),(0,bt.useEffect)(()=>{c([])},[o]);let T=(0,bt.useMemo)(()=>b?.font_families??[],[b]),_=b?.categories??[],P=[Ux,..._],N=(0,bt.useMemo)(()=>Bg(T,g),[T,g]),q=Math.max(window.innerHeight,Hx),H=Math.floor((q-417)/61),S=Math.ceil(N.length/H),I=(f-1)*H,W=f*H,O=N.slice(I,W),D=ee=>{d({...g,category:ee}),m(1)},M=(0,Yg.debounce)(ee=>{d({...g,search:ee}),m(1)},300),E=(ee,Fe)=>{let Ae=Gi(ee,Fe,l);c(Ae)},L=jg(l),$=()=>{c([])},F=l.length>0?l[0]?.fontFace?.length??0:0,Z=F>0&&F!==o?.fontFace?.length,se=F===o?.fontFace?.length,we=()=>{let ee=[];!se&&o&&ee.push(o),c(ee)},ie=async()=>{u(null);let ee=l[0];try{ee?.fontFace&&await Promise.all(ee.fontFace.map(async Fe=>{Fe.src&&(Fe.file=await Ag(Fe.src))}))}catch{u({type:"error",message:(0,rt.__)("Error installing the fonts, could not be downloaded.")});return}try{await C([ee]),u({type:"success",message:(0,rt.__)("Fonts were installed successfully.")})}catch(Fe){u({type:"error",message:Fe.message})}$()},ve=ee=>ee?!ee.fontFace||!ee.fontFace.length?[{fontFamily:ee.fontFamily,fontStyle:"normal",fontWeight:"400"}]:Ji(ee.fontFace):[];if(v)return(0,he.jsx)(Ug,{});let Ee=e==="google-fonts"&&!v&&!o;return(0,he.jsxs)("div",{className:"font-library__tabpanel-layout",children:[R&&(0,he.jsx)("div",{className:"font-library__loading",children:(0,he.jsx)(Ce.ProgressBar,{})}),!R&&b&&(0,he.jsxs)(he.Fragment,{children:[(0,he.jsxs)(Ce.Navigator,{initialPath:"/",className:"font-library__tabpanel-layout",children:[(0,he.jsxs)(Ce.Navigator.Screen,{path:"/",children:[(0,he.jsxs)(Ce.__experimentalHStack,{justify:"space-between",children:[(0,he.jsxs)(Ce.__experimentalVStack,{children:[(0,he.jsx)(Ce.__experimentalHeading,{level:2,size:13,children:b.name}),(0,he.jsx)(Ce.__experimentalText,{children:b.description})]}),Ee&&(0,he.jsx)(Ce.DropdownMenu,{icon:Vl,label:(0,rt.__)("Actions"),popoverProps:{position:"bottom left"},controls:[{title:(0,rt.__)("Revoke access to Google Fonts"),onClick:A}]})]}),(0,he.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,he.jsxs)(Ce.__experimentalHStack,{spacing:4,justify:"space-between",children:[(0,he.jsx)(Ce.SearchControl,{className:"font-library__search",value:g.search,placeholder:(0,rt.__)("Font name\u2026"),label:(0,rt.__)("Search"),onChange:M,hideLabelFromVision:!1}),(0,he.jsx)(Ce.SelectControl,{label:(0,rt.__)("Category"),value:g.category,onChange:D,children:P&&P.map(ee=>(0,he.jsx)("option",{value:ee.slug,children:ee.name},ee.slug))})]}),(0,he.jsx)(Ce.__experimentalSpacer,{margin:4}),!!b?.font_families?.length&&!N.length&&(0,he.jsx)(Ce.__experimentalText,{children:(0,rt.__)("No fonts found. Try with a different search term.")}),(0,he.jsx)("div",{className:"font-library__fonts-grid__main",children:(0,he.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:O.map(ee=>(0,he.jsx)("li",{className:"font-library__fonts-list-item",children:(0,he.jsx)(vs,{font:ee.font_family_settings,navigatorPath:"/fontFamily",shouldFocus:ee.font_family_settings.slug===s,onClick:()=>{n(ee.font_family_settings)}})},ee.font_family_settings.slug))})})]}),(0,he.jsxs)(Ce.Navigator.Screen,{path:"/fontFamily",children:[(0,he.jsxs)(Ce.Flex,{justify:"flex-start",children:[(0,he.jsx)(Ce.Navigator.BackButton,{icon:(0,rt.isRTL)()?Mo:Do,size:"small",onClick:()=>{i(o?.slug),n(null),u(null)},label:(0,rt.__)("Back")}),(0,he.jsx)(Ce.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:o?.name})]}),a&&(0,he.jsxs)(he.Fragment,{children:[(0,he.jsx)(Ce.__experimentalSpacer,{margin:1}),(0,he.jsx)(Ce.Notice,{status:a.type,onRemove:()=>u(null),children:a.message}),(0,he.jsx)(Ce.__experimentalSpacer,{margin:1})]}),(0,he.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,he.jsx)(Ce.__experimentalText,{children:(0,rt.__)("Select font variants to install.")}),(0,he.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,he.jsx)(Ce.CheckboxControl,{className:"font-library__select-all",label:(0,rt.__)("Select all"),checked:se,onChange:we,indeterminate:Z}),(0,he.jsx)(Ce.__experimentalVStack,{spacing:0,children:(0,he.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:o&&ve(o).map((ee,Fe)=>(0,he.jsx)("li",{className:"font-library__fonts-list-item",children:(0,he.jsx)(Wg,{font:o,face:ee,handleToggleVariant:E,selected:zg(o.slug,o.fontFace?ee:null,L)})},`face${Fe}`))})}),(0,he.jsx)(Ce.__experimentalSpacer,{margin:16})]})]}),o&&(0,he.jsx)(Ce.Flex,{justify:"flex-end",className:"font-library__footer",children:(0,he.jsx)(Ce.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:ie,isBusy:w,disabled:l.length===0||w,accessibleWhenDisabled:!0,children:(0,rt.__)("Install")})}),!o&&(0,he.jsxs)(Ce.__experimentalHStack,{expanded:!1,className:"font-library__footer",justify:"end",spacing:6,children:[(0,he.jsx)(Ce.__experimentalHStack,{justify:"flex-start",expanded:!1,spacing:1,className:"font-library__page-selection",children:(0,bt.createInterpolateElement)((0,rt.sprintf)((0,rt._x)("
    Page
    %1$s
    of %2$d
    ","paging"),"",S),{div:(0,he.jsx)("div",{"aria-hidden":!0}),CurrentPage:(0,he.jsx)(Ce.SelectControl,{"aria-label":(0,rt.__)("Current page"),value:f.toString(),options:[...Array(S)].map((ee,Fe)=>({label:(Fe+1).toString(),value:(Fe+1).toString()})),onChange:ee=>m(parseInt(ee)),size:"small",variant:"minimal"})})}),(0,he.jsxs)(Ce.__experimentalHStack,{expanded:!1,spacing:1,children:[(0,he.jsx)(Ce.Button,{onClick:()=>m(f-1),disabled:f===1,accessibleWhenDisabled:!0,label:(0,rt.__)("Previous page"),icon:(0,rt.isRTL)()?Ri:Ti,showTooltip:!0,size:"compact",tooltipPosition:"top"}),(0,he.jsx)(Ce.Button,{onClick:()=>m(f+1),disabled:f===S,accessibleWhenDisabled:!0,label:(0,rt.__)("Next page"),icon:(0,rt.isRTL)()?Ti:Ri,showTooltip:!0,size:"compact",tooltipPosition:"top"})]})]})]})]})}var ea=Wx;var Dn=h(xe(),1),Ft=h(ce(),1),Ss=h(ke(),1);var ta=(e=>typeof zt<"u"?zt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof zt<"u"?zt:t)[r]}):e)(function(e){if(typeof zt<"u")return zt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),Zg=(function(){var e,t,r;return(function(){function o(n,s,i){function a(c,f){if(!s[c]){if(!n[c]){var m=typeof ta=="function"&&ta;if(!f&&m)return m(c,!0);if(u)return u(c,!0);var g=new Error("Cannot find module '"+c+"'");throw g.code="MODULE_NOT_FOUND",g}var d=s[c]={exports:{}};n[c][0].call(d.exports,function(v){var x=n[c][1][v];return a(x||v)},d,d.exports,o,n,s,i)}return s[c].exports}for(var u=typeof ta=="function"&&ta,l=0;l0},c.prototype.readMoreInput=function(){if(!(this.bit_end_pos_>256))if(this.eos_){if(this.bit_pos_>this.bit_end_pos_)throw new Error("Unexpected end of input "+this.bit_pos_+" "+this.bit_end_pos_)}else{var f=this.buf_ptr_,m=this.input_.read(this.buf_,f,i);if(m<0)throw new Error("Unexpected end of input");if(m=8;)this.val_>>>=8,this.val_|=this.buf_[this.pos_&u]<<24,++this.pos_,this.bit_pos_=this.bit_pos_-8>>>0,this.bit_end_pos_=this.bit_end_pos_-8>>>0},c.prototype.readBits=function(f){32-this.bit_pos_>>this.bit_pos_&l[f];return this.bit_pos_+=f,m},n.exports=c},{}],2:[function(o,n,s){var i=0,a=1,u=2,l=3;s.lookup=new Uint8Array([0,0,0,0,0,0,0,0,0,4,4,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,12,16,12,12,20,12,16,24,28,12,12,32,12,36,12,44,44,44,44,44,44,44,44,44,44,32,32,24,40,28,12,12,48,52,52,52,48,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,24,12,28,12,12,12,56,60,60,60,56,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,24,12,28,12,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,56,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,10,10,10,10,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,22,22,22,22,23,23,23,23,24,24,24,24,25,25,25,25,26,26,26,26,27,27,27,27,28,28,28,28,29,29,29,29,30,30,30,30,31,31,31,31,32,32,32,32,33,33,33,33,34,34,34,34,35,35,35,35,36,36,36,36,37,37,37,37,38,38,38,38,39,39,39,39,40,40,40,40,41,41,41,41,42,42,42,42,43,43,43,43,44,44,44,44,45,45,45,45,46,46,46,46,47,47,47,47,48,48,48,48,49,49,49,49,50,50,50,50,51,51,51,51,52,52,52,52,53,53,53,53,54,54,54,54,55,55,55,55,56,56,56,56,57,57,57,57,58,58,58,58,59,59,59,59,60,60,60,60,61,61,61,61,62,62,62,62,63,63,63,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),s.lookupOffsets=new Uint16Array([1024,1536,1280,1536,0,256,768,512])},{}],3:[function(o,n,s){var i=o("./streams").BrotliInput,a=o("./streams").BrotliOutput,u=o("./bit_reader"),l=o("./dictionary"),c=o("./huffman").HuffmanCode,f=o("./huffman").BrotliBuildHuffmanTable,m=o("./context"),g=o("./prefix"),d=o("./transform"),v=8,x=16,C=256,w=704,b=26,R=6,A=2,T=8,_=255,P=1080,N=18,q=new Uint8Array([1,2,3,4,0,5,17,6,16,7,8,9,10,11,12,13,14,15]),H=16,S=new Uint8Array([3,2,1,0,3,3,3,3,3,3,2,2,2,2,2,2]),I=new Int8Array([0,0,0,0,-1,1,-2,2,-3,3,-1,1,-2,2,-3,3]),W=new Uint16Array([256,402,436,468,500,534,566,598,630,662,694,726,758,790,822,854,886,920,952,984,1016,1048,1080]);function O(G){var z;return G.readBits(1)===0?16:(z=G.readBits(3),z>0?17+z:(z=G.readBits(3),z>0?8+z:17))}function D(G){if(G.readBits(1)){var z=G.readBits(3);return z===0?1:G.readBits(z)+(1<1&&fe===0)throw new Error("Invalid size byte");z.meta_block_length|=fe<4&&ue===0)throw new Error("Invalid size nibble");z.meta_block_length|=ue<>>X.bit_pos_&_,K=G[z].bits-T,K>0&&(X.bit_pos_+=T,z+=G[z].value,z+=X.val_>>>X.bit_pos_&(1<0;){var re=0,Ne;if(U.readMoreInput(),U.fillBitWindow(),re+=U.val_>>>U.bit_pos_&31,U.bit_pos_+=me[re].bits,Ne=me[re].value&255,Ne>Ne);else{var He=Ne-14,ot,ut,ze=0;if(Ne===x&&(ze=fe),de!==ze&&(ue=0,de=ze),ot=ue,ue>0&&(ue-=2,ue<<=He),ue+=U.readBits(He)+3,ut=ue-ot,K+ut>z)throw new Error("[ReadHuffmanCodeLengths] symbol + repeat_delta > num_symbols");for(var We=0;We0;++de){var ze=q[de],We=0,nt;U.fillBitWindow(),We+=U.val_>>>U.bit_pos_&15,U.bit_pos_+=ut[We].bits,nt=ut[We].value,Ne[ze]=nt,nt!==0&&(He-=32>>nt,++ot)}if(!(ot===1||He===0))throw new Error("[ReadHuffmanCode] invalid num_codes or space");L(Ne,G,ue,U)}if(K=f(z,X,T,ue,G),K===0)throw new Error("[ReadHuffmanCode] BuildHuffmanTable failed: ");return K}function F(G,z,X){var U,K;return U=E(G,z,X),K=g.kBlockLengthPrefixCode[U].nbits,g.kBlockLengthPrefixCode[U].offset+X.readBits(K)}function Z(G,z,X){var U;return G>>5]),this.htrees=new Uint32Array(z)}ie.prototype.decode=function(G){var z,X,U=0;for(z=0;z=G)throw new Error("[DecodeContextMap] i >= context_map_size");pe[ue]=0,++ue}else pe[ue]=me-K,++ue}return z.readBits(1)&&we(pe,G),X}function Ee(G,z,X,U,K,fe,ue){var de=X*2,pe=X,me=E(z,X*P,ue),V;me===0?V=K[de+(fe[pe]&1)]:me===1?V=K[de+(fe[pe]-1&1)]+1:V=me-2,V>=G&&(V-=G),U[X]=V,K[de+(fe[pe]&1)]=V,++fe[pe]}function ee(G,z,X,U,K,fe){var ue=K+1,de=X&K,pe=fe.pos_&u.IBUF_MASK,me;if(z<8||fe.bit_pos_+(z<<3)0;)fe.readMoreInput(),U[de++]=fe.readBits(8),de===ue&&(G.write(U,ue),de=0);return}if(fe.bit_end_pos_<32)throw new Error("[CopyUncompressedBlockToOutput] br.bit_end_pos_ < 32");for(;fe.bit_pos_<32;)U[de]=fe.val_>>>fe.bit_pos_,fe.bit_pos_+=8,++de,--z;if(me=fe.bit_end_pos_-fe.bit_pos_>>3,pe+me>u.IBUF_MASK){for(var V=u.IBUF_MASK+1-pe,re=0;re=ue){G.write(U,ue),de-=ue;for(var re=0;re=ue;){if(me=ue-de,fe.input_.read(U,de,me)z.buffer.length){var Ro=new Uint8Array(U+$e);Ro.set(z.buffer),z.buffer=Ro}if(K=Ur.input_end,jr=Ur.is_uncompressed,Ur.is_metadata){for(Fe(be);$e>0;--$e)be.readMoreInput(),be.readBits(8);continue}if($e!==0){if(jr){be.bit_pos_=be.bit_pos_+7&-8,ee(z,$e,U,V,me,be),U+=$e;continue}for(X=0;X<3;++X)qe[X]=D(be)+1,qe[X]>=2&&($(qe[X]+2,We,X*P,be),$(b,nt,X*P,be),Ct[X]=F(nt,X*P,be),Q[X]=1);for(be.readMoreInput(),y=be.readBits(2),oe=H+(be.readBits(4)<0;){var dt,It,Bt,Ko,xa,jt,$t,Hr,zn,Jo,Un;for(be.readMoreInput(),Ct[1]===0&&(Ee(qe[1],We,1,Le,k,Q,be),Ct[1]=F(nt,P,be),wt=ze[1].htrees[Le[1]]),--Ct[1],dt=E(ze[1].codes,wt,be),It=dt>>6,It>=2?(It-=2,$t=-1):$t=0,Bt=g.kInsertRangeLut[It]+(dt>>3&7),Ko=g.kCopyRangeLut[It]+(dt&7),xa=g.kInsertLengthPrefixCode[Bt].offset+be.readBits(g.kInsertLengthPrefixCode[Bt].nbits),jt=g.kCopyLengthPrefixCode[Ko].offset+be.readBits(g.kCopyLengthPrefixCode[Ko].nbits),ot=V[U-1&me],ut=V[U-2&me],Jo=0;Jo4?3:jt-2)&255,et=B[Qt+zn],$t=E(ze[2].codes,ze[2].htrees[et],be),$t>=oe){var Sa,Eu,Hn;$t-=oe,Eu=$t&Ve,$t>>=y,Sa=($t>>1)+1,Hn=(2+($t&1)<de)if(jt>=l.minDictionaryWordLength&&jt<=l.maxDictionaryWordLength){var Hn=l.offsetsByLength[jt],Tu=Hr-de-1,_u=l.sizeBitsByLength[jt],mv=(1<<_u)-1,hv=Tu&mv,Pu=Tu>>_u;if(Hn+=hv*jt,Pu=re){z.write(V,pe);for(var Os=0;Os0&&(Ne[He&3]=Hr,++He),jt>$e)throw new Error("Invalid backward reference. pos: "+U+" distance: "+Hr+" len: "+jt+" bytes left: "+$e);for(Jo=0;Jo>=1;return(f&g-1)+g}function l(f,m,g,d,v){do d-=g,f[m+d]=new i(v.bits,v.value);while(d>0)}function c(f,m,g){for(var d=1<0;--S[w])C=new i(w&255,H[b++]&65535),l(f,m+R,A,N,C),R=u(R,w);for(_=q-1,T=-1,w=g+1,A=2;w<=a;++w,A<<=1)for(;S[w]>0;--S[w])(R&_)!==T&&(m+=N,P=c(S,w,g),N=1<>g),A,N,C),R=u(R,w);return q}},{}],8:[function(o,n,s){"use strict";s.byteLength=g,s.toByteArray=v,s.fromByteArray=w;for(var i=[],a=[],u=typeof Uint8Array<"u"?Uint8Array:Array,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=0,f=l.length;c0)throw new Error("Invalid string. Length must be a multiple of 4");var A=b.indexOf("=");A===-1&&(A=R);var T=A===R?0:4-A%4;return[A,T]}function g(b){var R=m(b),A=R[0],T=R[1];return(A+T)*3/4-T}function d(b,R,A){return(R+A)*3/4-A}function v(b){for(var R,A=m(b),T=A[0],_=A[1],P=new u(d(b,T,_)),N=0,q=_>0?T-4:T,H=0;H>16&255,P[N++]=R>>8&255,P[N++]=R&255;return _===2&&(R=a[b.charCodeAt(H)]<<2|a[b.charCodeAt(H+1)]>>4,P[N++]=R&255),_===1&&(R=a[b.charCodeAt(H)]<<10|a[b.charCodeAt(H+1)]<<4|a[b.charCodeAt(H+2)]>>2,P[N++]=R>>8&255,P[N++]=R&255),P}function x(b){return i[b>>18&63]+i[b>>12&63]+i[b>>6&63]+i[b&63]}function C(b,R,A){for(var T,_=[],P=R;Pq?q:N+P));return T===1?(R=b[A-1],_.push(i[R>>2]+i[R<<4&63]+"==")):T===2&&(R=(b[A-2]<<8)+b[A-1],_.push(i[R>>10]+i[R>>4&63]+i[R<<2&63]+"=")),_.join("")}},{}],9:[function(o,n,s){function i(a,u){this.offset=a,this.nbits=u}s.kBlockLengthPrefixCode=[new i(1,2),new i(5,2),new i(9,2),new i(13,2),new i(17,3),new i(25,3),new i(33,3),new i(41,3),new i(49,4),new i(65,4),new i(81,4),new i(97,4),new i(113,5),new i(145,5),new i(177,5),new i(209,5),new i(241,6),new i(305,6),new i(369,7),new i(497,8),new i(753,9),new i(1265,10),new i(2289,11),new i(4337,12),new i(8433,13),new i(16625,24)],s.kInsertLengthPrefixCode=[new i(0,0),new i(1,0),new i(2,0),new i(3,0),new i(4,0),new i(5,0),new i(6,1),new i(8,1),new i(10,2),new i(14,2),new i(18,3),new i(26,3),new i(34,4),new i(50,4),new i(66,5),new i(98,5),new i(130,6),new i(194,7),new i(322,8),new i(578,9),new i(1090,10),new i(2114,12),new i(6210,14),new i(22594,24)],s.kCopyLengthPrefixCode=[new i(2,0),new i(3,0),new i(4,0),new i(5,0),new i(6,0),new i(7,0),new i(8,0),new i(9,0),new i(10,1),new i(12,1),new i(14,2),new i(18,2),new i(22,3),new i(30,3),new i(38,4),new i(54,4),new i(70,5),new i(102,5),new i(134,6),new i(198,7),new i(326,8),new i(582,9),new i(1094,10),new i(2118,24)],s.kInsertRangeLut=[0,0,8,8,0,16,8,16,16],s.kCopyRangeLut=[0,8,0,8,16,0,16,8,16]},{}],10:[function(o,n,s){function i(u){this.buffer=u,this.pos=0}i.prototype.read=function(u,l,c){this.pos+c>this.buffer.length&&(c=this.buffer.length-this.pos);for(var f=0;fthis.buffer.length)throw new Error("Output buffer is not large enough");return this.buffer.set(u.subarray(0,l),this.pos),this.pos+=l,l},s.BrotliOutput=a},{}],11:[function(o,n,s){var i=o("./dictionary"),a=0,u=1,l=2,c=3,f=4,m=5,g=6,d=7,v=8,x=9,C=10,w=11,b=12,R=13,A=14,T=15,_=16,P=17,N=18,q=19,H=20;function S(O,D,J){this.prefix=new Uint8Array(O.length),this.transform=D,this.suffix=new Uint8Array(J.length);for(var M=0;M'),new S("",a,` -`),new S("",c,""),new S("",a,"]"),new S("",a," for "),new S("",A,""),new S("",l,""),new S("",a," a "),new S("",a," that "),new S(" ",C,""),new S("",a,". "),new S(".",a,""),new S(" ",a,", "),new S("",T,""),new S("",a," with "),new S("",a,"'"),new S("",a," from "),new S("",a," by "),new S("",_,""),new S("",P,""),new S(" the ",a,""),new S("",f,""),new S("",a,". The "),new S("",w,""),new S("",a," on "),new S("",a," as "),new S("",a," is "),new S("",d,""),new S("",u,"ing "),new S("",a,` - `),new S("",a,":"),new S(" ",a,". "),new S("",a,"ed "),new S("",H,""),new S("",N,""),new S("",g,""),new S("",a,"("),new S("",C,", "),new S("",v,""),new S("",a," at "),new S("",a,"ly "),new S(" the ",a," of "),new S("",m,""),new S("",x,""),new S(" ",C,", "),new S("",C,'"'),new S(".",a,"("),new S("",w," "),new S("",C,'">'),new S("",a,'="'),new S(" ",a,"."),new S(".com/",a,""),new S(" the ",a," of the "),new S("",C,"'"),new S("",a,". This "),new S("",a,","),new S(".",a," "),new S("",C,"("),new S("",C,"."),new S("",a," not "),new S(" ",a,'="'),new S("",a,"er "),new S(" ",w," "),new S("",a,"al "),new S(" ",w,""),new S("",a,"='"),new S("",w,'"'),new S("",C,". "),new S(" ",a,"("),new S("",a,"ful "),new S(" ",C,". "),new S("",a,"ive "),new S("",a,"less "),new S("",w,"'"),new S("",a,"est "),new S(" ",C,"."),new S("",w,'">'),new S(" ",a,"='"),new S("",C,","),new S("",a,"ize "),new S("",w,"."),new S("\xC2\xA0",a,""),new S(" ",a,","),new S("",C,'="'),new S("",w,'="'),new S("",a,"ous "),new S("",w,", "),new S("",C,"='"),new S(" ",C,","),new S(" ",w,'="'),new S(" ",w,", "),new S("",w,","),new S("",w,"("),new S("",w,". "),new S(" ",w,"."),new S("",w,"='"),new S(" ",w,". "),new S(" ",C,'="'),new S(" ",w,"='"),new S(" ",C,"='")];s.kTransforms=I,s.kNumTransforms=I.length;function W(O,D){return O[D]<192?(O[D]>=97&&O[D]<=122&&(O[D]^=32),1):O[D]<224?(O[D+1]^=32,2):(O[D+2]^=5,3)}s.transformDictionaryWord=function(O,D,J,M,E){var L=I[E].prefix,$=I[E].suffix,F=I[E].transform,Z=FM&&(Z=M);for(var ve=0;ve0;){var Ee=W(O,ie);ie+=Ee,M-=Ee}for(var ee=0;ee<$.length;)O[D++]=$[ee++];return D-we}},{"./dictionary":6}],12:[function(o,n,s){n.exports=o("./dec/decode").BrotliDecompressBuffer},{"./dec/decode":3}]},{},[12])(12)})();var ra=(e=>typeof zt<"u"?zt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof zt<"u"?zt:t)[r]}):e)(function(e){if(typeof zt<"u")return zt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),Xg=(function(){var e,t,r;return(function(){function o(n,s,i){function a(c,f){if(!s[c]){if(!n[c]){var m=typeof ra=="function"&&ra;if(!f&&m)return m(c,!0);if(u)return u(c,!0);var g=new Error("Cannot find module '"+c+"'");throw g.code="MODULE_NOT_FOUND",g}var d=s[c]={exports:{}};n[c][0].call(d.exports,function(v){var x=n[c][1][v];return a(x||v)},d,d.exports,o,n,s,i)}return s[c].exports}for(var u=typeof ra=="function"&&ra,l=0;l=252?6:c>=248?5:c>=240?4:c>=224?3:c>=192?2:1;l[254]=l[254]=1,s.string2buf=function(m){var g,d,v,x,C,w=m.length,b=0;for(x=0;x>>6,g[C++]=128|d&63):d<65536?(g[C++]=224|d>>>12,g[C++]=128|d>>>6&63,g[C++]=128|d&63):(g[C++]=240|d>>>18,g[C++]=128|d>>>12&63,g[C++]=128|d>>>6&63,g[C++]=128|d&63);return g};function f(m,g){if(g<65534&&(m.subarray&&u||!m.subarray&&a))return String.fromCharCode.apply(null,i.shrinkBuf(m,g));for(var d="",v=0;v4){b[v++]=65533,d+=C-1;continue}for(x&=C===2?31:C===3?15:7;C>1&&d1){b[v++]=65533;continue}x<65536?b[v++]=x:(x-=65536,b[v++]=55296|x>>10&1023,b[v++]=56320|x&1023)}return f(b,v)},s.utf8border=function(m,g){var d;for(g=g||m.length,g>m.length&&(g=m.length),d=g-1;d>=0&&(m[d]&192)===128;)d--;return d<0||d===0?g:d+l[m[d]]>g?d:g}},{"./common":1}],3:[function(o,n,s){"use strict";function i(a,u,l,c){for(var f=a&65535|0,m=a>>>16&65535|0,g=0;l!==0;){g=l>2e3?2e3:l,l-=g;do f=f+u[c++]|0,m=m+f|0;while(--g);f%=65521,m%=65521}return f|m<<16|0}n.exports=i},{}],4:[function(o,n,s){"use strict";n.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],5:[function(o,n,s){"use strict";function i(){for(var l,c=[],f=0;f<256;f++){l=f;for(var m=0;m<8;m++)l=l&1?3988292384^l>>>1:l>>>1;c[f]=l}return c}var a=i();function u(l,c,f,m){var g=a,d=m+f;l^=-1;for(var v=m;v>>8^g[(l^c[v])&255];return l^-1}n.exports=u},{}],6:[function(o,n,s){"use strict";function i(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}n.exports=i},{}],7:[function(o,n,s){"use strict";var i=30,a=12;n.exports=function(l,c){var f,m,g,d,v,x,C,w,b,R,A,T,_,P,N,q,H,S,I,W,O,D,J,M,E;f=l.state,m=l.next_in,M=l.input,g=m+(l.avail_in-5),d=l.next_out,E=l.output,v=d-(c-l.avail_out),x=d+(l.avail_out-257),C=f.dmax,w=f.wsize,b=f.whave,R=f.wnext,A=f.window,T=f.hold,_=f.bits,P=f.lencode,N=f.distcode,q=(1<>>24,T>>>=I,_-=I,I=S>>>16&255,I===0)E[d++]=S&65535;else if(I&16){W=S&65535,I&=15,I&&(_>>=I,_-=I),_<15&&(T+=M[m++]<<_,_+=8,T+=M[m++]<<_,_+=8),S=N[T&H];r:for(;;){if(I=S>>>24,T>>>=I,_-=I,I=S>>>16&255,I&16){if(O=S&65535,I&=15,_C){l.msg="invalid distance too far back",f.mode=i;break e}if(T>>>=I,_-=I,I=d-v,O>I){if(I=O-I,I>b&&f.sane){l.msg="invalid distance too far back",f.mode=i;break e}if(D=0,J=A,R===0){if(D+=w-I,I2;)E[d++]=J[D++],E[d++]=J[D++],E[d++]=J[D++],W-=3;W&&(E[d++]=J[D++],W>1&&(E[d++]=J[D++]))}else{D=d-O;do E[d++]=E[D++],E[d++]=E[D++],E[d++]=E[D++],W-=3;while(W>2);W&&(E[d++]=E[D++],W>1&&(E[d++]=E[D++]))}}else if((I&64)===0){S=N[(S&65535)+(T&(1<>3,m-=W,_-=W<<3,T&=(1<<_)-1,l.next_in=m,l.next_out=d,l.avail_in=m>>24&255)+(k>>>8&65280)+((k&65280)<<8)+((k&255)<<24)}function Ne(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new i.Buf16(320),this.work=new i.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function He(k){var Q;return!k||!k.state?R:(Q=k.state,k.total_in=k.total_out=Q.total=0,k.msg="",Q.wrap&&(k.adler=Q.wrap&1),Q.mode=N,Q.last=0,Q.havedict=0,Q.dmax=32768,Q.head=null,Q.hold=0,Q.bits=0,Q.lencode=Q.lendyn=new i.Buf32(de),Q.distcode=Q.distdyn=new i.Buf32(pe),Q.sane=1,Q.back=-1,C)}function ot(k){var Q;return!k||!k.state?R:(Q=k.state,Q.wsize=0,Q.whave=0,Q.wnext=0,He(k))}function ut(k,Q){var y,oe;return!k||!k.state||(oe=k.state,Q<0?(y=0,Q=-Q):(y=(Q>>4)+1,Q<48&&(Q&=15)),Q&&(Q<8||Q>15))?R:(oe.window!==null&&oe.wbits!==Q&&(oe.window=null),oe.wrap=y,oe.wbits=Q,ot(k))}function ze(k,Q){var y,oe;return k?(oe=new Ne,k.state=oe,oe.window=null,y=ut(k,Q),y!==C&&(k.state=null),y):R}function We(k){return ze(k,V)}var nt=!0,be,Rr;function gr(k){if(nt){var Q;for(be=new i.Buf32(512),Rr=new i.Buf32(32),Q=0;Q<144;)k.lens[Q++]=8;for(;Q<256;)k.lens[Q++]=9;for(;Q<280;)k.lens[Q++]=7;for(;Q<288;)k.lens[Q++]=8;for(c(m,k.lens,0,288,be,0,k.work,{bits:9}),Q=0;Q<32;)k.lens[Q++]=5;c(g,k.lens,0,32,Rr,0,k.work,{bits:5}),nt=!1}k.lencode=be,k.lenbits=9,k.distcode=Rr,k.distbits=5}function $e(k,Q,y,oe){var Ve,te=k.state;return te.window===null&&(te.wsize=1<=te.wsize?(i.arraySet(te.window,Q,y-te.wsize,te.wsize,0),te.wnext=0,te.whave=te.wsize):(Ve=te.wsize-te.wnext,Ve>oe&&(Ve=oe),i.arraySet(te.window,Q,y-oe,Ve,te.wnext),oe-=Ve,oe?(i.arraySet(te.window,Q,y-oe,oe,0),te.wnext=oe,te.whave=te.wsize):(te.wnext+=Ve,te.wnext===te.wsize&&(te.wnext=0),te.whave>>8&255,y.check=u(y.check,dt,2,0),B=0,j=0,y.mode=q;break}if(y.flags=0,y.head&&(y.head.done=!1),!(y.wrap&1)||(((B&255)<<8)+(B>>8))%31){k.msg="incorrect header check",y.mode=K;break}if((B&15)!==P){k.msg="unknown compression method",y.mode=K;break}if(B>>>=4,j-=4,lt=(B&15)+8,y.wbits===0)y.wbits=lt;else if(lt>y.wbits){k.msg="invalid window size",y.mode=K;break}y.dmax=1<>8&1),y.flags&512&&(dt[0]=B&255,dt[1]=B>>>8&255,y.check=u(y.check,dt,2,0)),B=0,j=0,y.mode=H;case H:for(;j<32;){if(ne===0)break e;ne--,B+=oe[te++]<>>8&255,dt[2]=B>>>16&255,dt[3]=B>>>24&255,y.check=u(y.check,dt,4,0)),B=0,j=0,y.mode=S;case S:for(;j<16;){if(ne===0)break e;ne--,B+=oe[te++]<>8),y.flags&512&&(dt[0]=B&255,dt[1]=B>>>8&255,y.check=u(y.check,dt,2,0)),B=0,j=0,y.mode=I;case I:if(y.flags&1024){for(;j<16;){if(ne===0)break e;ne--,B+=oe[te++]<>>8&255,y.check=u(y.check,dt,2,0)),B=0,j=0}else y.head&&(y.head.extra=null);y.mode=W;case W:if(y.flags&1024&&(le=y.length,le>ne&&(le=ne),le&&(y.head&&(lt=y.head.extra_len-y.length,y.head.extra||(y.head.extra=new Array(y.head.extra_len)),i.arraySet(y.head.extra,oe,te,le,lt)),y.flags&512&&(y.check=u(y.check,oe,le,te)),ne-=le,te+=le,y.length-=le),y.length))break e;y.length=0,y.mode=O;case O:if(y.flags&2048){if(ne===0)break e;le=0;do lt=oe[te+le++],y.head&<&&y.length<65536&&(y.head.name+=String.fromCharCode(lt));while(lt&&le>9&1,y.head.done=!0),k.adler=y.check=0,y.mode=L;break;case M:for(;j<32;){if(ne===0)break e;ne--,B+=oe[te++]<>>=j&7,j-=j&7,y.mode=z;break}for(;j<3;){if(ne===0)break e;ne--,B+=oe[te++]<>>=1,j-=1,B&3){case 0:y.mode=F;break;case 1:if(gr(y),y.mode=Ee,Q===x){B>>>=2,j-=2;break e}break;case 2:y.mode=we;break;case 3:k.msg="invalid block type",y.mode=K}B>>>=2,j-=2;break;case F:for(B>>>=j&7,j-=j&7;j<32;){if(ne===0)break e;ne--,B+=oe[te++]<>>16^65535)){k.msg="invalid stored block lengths",y.mode=K;break}if(y.length=B&65535,B=0,j=0,y.mode=Z,Q===x)break e;case Z:y.mode=se;case se:if(le=y.length,le){if(le>ne&&(le=ne),le>Qe&&(le=Qe),le===0)break e;i.arraySet(Ve,oe,te,le,ht),ne-=le,te+=le,Qe-=le,ht+=le,y.length-=le;break}y.mode=L;break;case we:for(;j<14;){if(ne===0)break e;ne--,B+=oe[te++]<>>=5,j-=5,y.ndist=(B&31)+1,B>>>=5,j-=5,y.ncode=(B&15)+4,B>>>=4,j-=4,y.nlen>286||y.ndist>30){k.msg="too many length or distance symbols",y.mode=K;break}y.have=0,y.mode=ie;case ie:for(;y.have>>=3,j-=3}for(;y.have<19;)y.lens[Ko[y.have++]]=0;if(y.lencode=y.lendyn,y.lenbits=7,It={bits:y.lenbits},At=c(f,y.lens,0,19,y.lencode,0,y.work,It),y.lenbits=It.bits,At){k.msg="invalid code lengths set",y.mode=K;break}y.have=0,y.mode=ve;case ve:for(;y.have>>24,ft=et>>>16&255,gt=et&65535,!(Me<=j);){if(ne===0)break e;ne--,B+=oe[te++]<>>=Me,j-=Me,y.lens[y.have++]=gt;else{if(gt===16){for(Bt=Me+2;j>>=Me,j-=Me,y.have===0){k.msg="invalid bit length repeat",y.mode=K;break}lt=y.lens[y.have-1],le=3+(B&3),B>>>=2,j-=2}else if(gt===17){for(Bt=Me+3;j>>=Me,j-=Me,lt=0,le=3+(B&7),B>>>=3,j-=3}else{for(Bt=Me+7;j>>=Me,j-=Me,lt=0,le=11+(B&127),B>>>=7,j-=7}if(y.have+le>y.nlen+y.ndist){k.msg="invalid bit length repeat",y.mode=K;break}for(;le--;)y.lens[y.have++]=lt}}if(y.mode===K)break;if(y.lens[256]===0){k.msg="invalid code -- missing end-of-block",y.mode=K;break}if(y.lenbits=9,It={bits:y.lenbits},At=c(m,y.lens,0,y.nlen,y.lencode,0,y.work,It),y.lenbits=It.bits,At){k.msg="invalid literal/lengths set",y.mode=K;break}if(y.distbits=6,y.distcode=y.distdyn,It={bits:y.distbits},At=c(g,y.lens,y.nlen,y.ndist,y.distcode,0,y.work,It),y.distbits=It.bits,At){k.msg="invalid distances set",y.mode=K;break}if(y.mode=Ee,Q===x)break e;case Ee:y.mode=ee;case ee:if(ne>=6&&Qe>=258){k.next_out=ht,k.avail_out=Qe,k.next_in=te,k.avail_in=ne,y.hold=B,y.bits=j,l(k,Ge),ht=k.next_out,Ve=k.output,Qe=k.avail_out,te=k.next_in,oe=k.input,ne=k.avail_in,B=y.hold,j=y.bits,y.mode===L&&(y.back=-1);break}for(y.back=0;et=y.lencode[B&(1<>>24,ft=et>>>16&255,gt=et&65535,!(Me<=j);){if(ne===0)break e;ne--,B+=oe[te++]<>wt)],Me=et>>>24,ft=et>>>16&255,gt=et&65535,!(wt+Me<=j);){if(ne===0)break e;ne--,B+=oe[te++]<>>=wt,j-=wt,y.back+=wt}if(B>>>=Me,j-=Me,y.back+=Me,y.length=gt,ft===0){y.mode=G;break}if(ft&32){y.back=-1,y.mode=L;break}if(ft&64){k.msg="invalid literal/length code",y.mode=K;break}y.extra=ft&15,y.mode=Fe;case Fe:if(y.extra){for(Bt=y.extra;j>>=y.extra,j-=y.extra,y.back+=y.extra}y.was=y.length,y.mode=Ae;case Ae:for(;et=y.distcode[B&(1<>>24,ft=et>>>16&255,gt=et&65535,!(Me<=j);){if(ne===0)break e;ne--,B+=oe[te++]<>wt)],Me=et>>>24,ft=et>>>16&255,gt=et&65535,!(wt+Me<=j);){if(ne===0)break e;ne--,B+=oe[te++]<>>=wt,j-=wt,y.back+=wt}if(B>>>=Me,j-=Me,y.back+=Me,ft&64){k.msg="invalid distance code",y.mode=K;break}y.offset=gt,y.extra=ft&15,y.mode=Oe;case Oe:if(y.extra){for(Bt=y.extra;j>>=y.extra,j-=y.extra,y.back+=y.extra}if(y.offset>y.dmax){k.msg="invalid distance too far back",y.mode=K;break}y.mode=Ue;case Ue:if(Qe===0)break e;if(le=Ge-Qe,y.offset>le){if(le=y.offset-le,le>y.whave&&y.sane){k.msg="invalid distance too far back",y.mode=K;break}le>y.wnext?(le-=y.wnext,zr=y.wsize-le):zr=y.wnext-le,le>y.length&&(le=y.length),Qt=y.window}else Qt=Ve,zr=ht-y.offset,le=y.length;le>Qe&&(le=Qe),Qe-=le,y.length-=le;do Ve[ht++]=Qt[zr++];while(--le);y.length===0&&(y.mode=ee);break;case G:if(Qe===0)break e;Ve[ht++]=y.length,Qe--,y.mode=ee;break;case z:if(y.wrap){for(;j<32;){if(ne===0)break e;ne--,B|=oe[te++]<=1&&ee[W]===0;W--);if(O>W&&(O=W),W===0)return T[_++]=1<<24|64<<16|0,T[_++]=1<<24|64<<16|0,N.bits=1,0;for(I=1;I0&&(w===c||W!==1))return-1;for(Fe[1]=0,H=1;Hu||w===m&&E>l)return 1;for(;;){Ue=H-J,P[S]Ee?(G=Ae[Oe+P[S]],z=ie[ve+P[S]]):(G=96,z=0),$=1<>J)+F]=Ue<<24|G<<16|z|0;while(F!==0);for($=1<>=1;if($!==0?(L&=$-1,L+=$):L=0,S++,--ee[H]===0){if(H===W)break;H=b[R+P[S]]}if(H>O&&(L&se)!==Z){for(J===0&&(J=O),we+=I,D=H-J,M=1<u||w===m&&E>l)return 1;Z=L&se,T[Z]=O<<24|D<<16|we-_|0}}return L!==0&&(T[we+L]=H-J<<24|64<<16|0),N.bits=O,0}},{"../utils/common":1}],10:[function(o,n,s){"use strict";n.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],11:[function(o,n,s){"use strict";function i(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}n.exports=i},{}],"/lib/inflate.js":[function(o,n,s){"use strict";var i=o("./zlib/inflate"),a=o("./utils/common"),u=o("./utils/strings"),l=o("./zlib/constants"),c=o("./zlib/messages"),f=o("./zlib/zstream"),m=o("./zlib/gzheader"),g=Object.prototype.toString;function d(C){if(!(this instanceof d))return new d(C);this.options=a.assign({chunkSize:16384,windowBits:0,to:""},C||{});var w=this.options;w.raw&&w.windowBits>=0&&w.windowBits<16&&(w.windowBits=-w.windowBits,w.windowBits===0&&(w.windowBits=-15)),w.windowBits>=0&&w.windowBits<16&&!(C&&C.windowBits)&&(w.windowBits+=32),w.windowBits>15&&w.windowBits<48&&(w.windowBits&15)===0&&(w.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new f,this.strm.avail_out=0;var b=i.inflateInit2(this.strm,w.windowBits);if(b!==l.Z_OK)throw new Error(c[b]);if(this.header=new m,i.inflateGetHeader(this.strm,this.header),w.dictionary&&(typeof w.dictionary=="string"?w.dictionary=u.string2buf(w.dictionary):g.call(w.dictionary)==="[object ArrayBuffer]"&&(w.dictionary=new Uint8Array(w.dictionary)),w.raw&&(b=i.inflateSetDictionary(this.strm,w.dictionary),b!==l.Z_OK)))throw new Error(c[b])}d.prototype.push=function(C,w){var b=this.strm,R=this.options.chunkSize,A=this.options.dictionary,T,_,P,N,q,H=!1;if(this.ended)return!1;_=w===~~w?w:w===!0?l.Z_FINISH:l.Z_NO_FLUSH,typeof C=="string"?b.input=u.binstring2buf(C):g.call(C)==="[object ArrayBuffer]"?b.input=new Uint8Array(C):b.input=C,b.next_in=0,b.avail_in=b.input.length;do{if(b.avail_out===0&&(b.output=new a.Buf8(R),b.next_out=0,b.avail_out=R),T=i.inflate(b,l.Z_NO_FLUSH),T===l.Z_NEED_DICT&&A&&(T=i.inflateSetDictionary(this.strm,A)),T===l.Z_BUF_ERROR&&H===!0&&(T=l.Z_OK,H=!1),T!==l.Z_STREAM_END&&T!==l.Z_OK)return this.onEnd(T),this.ended=!0,!1;b.next_out&&(b.avail_out===0||T===l.Z_STREAM_END||b.avail_in===0&&(_===l.Z_FINISH||_===l.Z_SYNC_FLUSH))&&(this.options.to==="string"?(P=u.utf8border(b.output,b.next_out),N=b.next_out-P,q=u.buf2string(b.output,P),b.next_out=N,b.avail_out=R-N,N&&a.arraySet(b.output,b.output,P,N,0),this.onData(q)):this.onData(a.shrinkBuf(b.output,b.next_out))),b.avail_in===0&&b.avail_out===0&&(H=!0)}while((b.avail_in>0||b.avail_out===0)&&T!==l.Z_STREAM_END);return T===l.Z_STREAM_END&&(_=l.Z_FINISH),_===l.Z_FINISH?(T=i.inflateEnd(this.strm),this.onEnd(T),this.ended=!0,T===l.Z_OK):(_===l.Z_SYNC_FLUSH&&(this.onEnd(l.Z_OK),b.avail_out=0),!0)},d.prototype.onData=function(C){this.chunks.push(C)},d.prototype.onEnd=function(C){C===l.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=C,this.msg=this.strm.msg};function v(C,w){var b=new d(w);if(b.push(C,!0),b.err)throw b.msg||c[b.err];return b.result}function x(C,w){return w=w||{},w.raw=!0,v(C,w)}s.Inflate=d,s.inflate=v,s.inflateRaw=x,s.ungzip=v},{"./utils/common":1,"./utils/strings":2,"./zlib/constants":4,"./zlib/gzheader":6,"./zlib/inflate":8,"./zlib/messages":10,"./zlib/zstream":11}]},{},[])("/lib/inflate.js")})();var TD=globalThis.fetch,oa=class{constructor(e,t={},r){this.type=e,this.detail=t,this.msg=r,Object.defineProperty(this,"__mayPropagate",{enumerable:!1,writable:!0}),this.__mayPropagate=!0}preventDefault(){}stopPropagation(){this.__mayPropagate=!1}valueOf(){return this}toString(){return this.msg?`[${this.type} event]: ${this.msg}`:`[${this.type} event]`}},Gx=class{constructor(){this.listeners={}}addEventListener(e,t,r){let o=this.listeners[e]||[];r?o.unshift(t):o.push(t),this.listeners[e]=o}removeEventListener(e,t){let r=this.listeners[e]||[],o=r.findIndex(n=>n===t);o>-1&&(r.splice(o,1),this.listeners[e]=r)}dispatch(e){let t=this.listeners[e.type];if(t)for(let r=0,o=t.length;rString.fromCharCode(t)).join("")}var Zx=class{constructor(e,t,r){this.name=(r||e.tag||"").trim(),this.length=e.length,this.start=e.offset,this.offset=0,this.data=t,["getInt8","getUint8","getInt16","getUint16","getInt32","getUint32","getBigInt64","getBigUint64"].forEach(o=>{let n=o.replace(/get(Big)?/,"").toLowerCase(),s=parseInt(o.replace(/[^\d]/g,""))/8;Object.defineProperty(this,n,{get:()=>this.getValue(o,s)})})}get currentPosition(){return this.start+this.offset}set currentPosition(e){this.start=e,this.offset=0}skip(e=0,t=8){this.offset+=e*t/8}getValue(e,t){let r=this.start+this.offset;this.offset+=t;try{return this.data[e](r)}catch(o){throw console.error("parser",e,t,this),console.error("parser",this.start,this.offset),o}}flags(e){if(e===8||e===16||e===32||e===64)return this[`uint${e}`].toString(2).padStart(e,0).split("").map(t=>t==="1");console.error("Error parsing flags: flag types can only be 1, 2, 4, or 8 bytes long"),console.trace()}get tag(){let e=this.uint32;return qx([e>>24&255,e>>16&255,e>>8&255,e&255])}get fixed(){let e=this.int16,t=Math.round(1e3*this.uint16/65356);return e+t/1e3}get legacyFixed(){let e=this.uint16,t=this.uint16.toString(16).padStart(4,0);return parseFloat(`${e}.${t}`)}get uint24(){return(this.uint8<<16)+(this.uint8<<8)+this.uint8}get uint128(){let e=0;for(let t=0;t<5;t++){let r=this.uint8;if(e=e*128+(r&127),r<128)break}return e}get longdatetime(){return new Date(Yx+1e3*parseInt(this.int64.toString()))}get fword(){return this.int16}get ufword(){return this.uint16}get Offset16(){return this.uint16}get Offset32(){return this.uint32}get F2DOT14(){let e=p.uint16,t=[0,1,-2,-1][e>>14],r=e&16383;return t+r/16384}verifyLength(){this.offset!=this.length&&console.error(`unexpected parsed table size (${this.offset}) for "${this.name}" (expected ${this.length})`)}readBytes(e=0,t=0,r=8,o=!1){if(e=e||this.length,e===0)return[];t&&(this.currentPosition=t);let n=`${o?"":"u"}int${r}`,s=[];for(;e--;)s.push(this[n]);return s}},ct=class{constructor(e){Object.defineProperty(this,"parser",{enumerable:!1,get:()=>e});let r=e.currentPosition;Object.defineProperty(this,"start",{enumerable:!1,get:()=>r})}load(e){Object.keys(e).forEach(t=>{let r=Object.getOwnPropertyDescriptor(e,t);r.get?this[t]=r.get.bind(this):r.value!==void 0&&(this[t]=r.value)}),this.parser.length&&this.parser.verifyLength()}},Pe=class extends ct{constructor(e,t,r){let{parser:o,start:n}=super(new Zx(e,t,r));Object.defineProperty(this,"p",{enumerable:!1,get:()=>o}),Object.defineProperty(this,"tableStart",{enumerable:!1,get:()=>n})}};function ae(e,t,r){let o;Object.defineProperty(e,t,{get:()=>o||(o=r(),o),enumerable:!0})}var Xx=class extends Pe{constructor(e,t,r){let{p:o}=super({offset:0,length:12},t,"sfnt");this.version=o.uint32,this.numTables=o.uint16,this.searchRange=o.uint16,this.entrySelector=o.uint16,this.rangeShift=o.uint16,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new Kx(o)),this.tables={},this.directory.forEach(n=>{let s=()=>r(this.tables,{tag:n.tag,offset:n.offset,length:n.length},t);ae(this.tables,n.tag.trim(),s)})}},Kx=class{constructor(e){this.tag=e.tag,this.checksum=e.uint32,this.offset=e.uint32,this.length=e.uint32}},Kg=Xg.inflate||void 0,Jg=void 0,Jx=class extends Pe{constructor(e,t,r){let{p:o}=super({offset:0,length:44},t,"woff");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new Qx(o)),$x(this,t,r)}},Qx=class{constructor(e){this.tag=e.tag,this.offset=e.uint32,this.compLength=e.uint32,this.origLength=e.uint32,this.origChecksum=e.uint32}};function $x(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=0,s=t;if(o.compLength!==o.origLength){let i=t.buffer.slice(o.offset,o.offset+o.compLength),a;if(Kg)a=Kg(new Uint8Array(i));else if(Jg)a=Jg(new Uint8Array(i));else{let u="no brotli decoder available to decode WOFF2 font";throw font.onerror&&font.onerror(u),new Error(u)}s=new DataView(a.buffer)}else n=o.offset;return r(e.tables,{tag:o.tag,offset:n,length:o.origLength},s)})})}var Qg=Zg,$g=void 0,eS=class extends Pe{constructor(e,t,r){let{p:o}=super({offset:0,length:48},t,"woff2");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.totalCompressedSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(a=>new tS(o));let n=o.currentPosition;this.directory[0].offset=0,this.directory.forEach((a,u)=>{let l=this.directory[u+1];l&&(l.offset=a.offset+(a.transformLength!==void 0?a.transformLength:a.origLength))});let s,i=t.buffer.slice(n);if(Qg)s=Qg(new Uint8Array(i));else if($g)s=new Uint8Array($g(i));else{let a="no brotli decoder available to decode WOFF2 font";throw e.onerror&&e.onerror(a),new Error(a)}rS(this,s,r)}},tS=class{constructor(e){this.flags=e.uint8;let t=this.tagNumber=this.flags&63;t===63?this.tag=e.tag:this.tag=oS(t);let o=(this.transformVersion=(this.flags&192)>>6)!==0;(this.tag==="glyf"||this.tag==="loca")&&(o=this.transformVersion!==3),this.origLength=e.uint128,o&&(this.transformLength=e.uint128)}};function rS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=o.offset,s=n+(o.transformLength?o.transformLength:o.origLength),i=new DataView(t.slice(n,s).buffer);try{return r(e.tables,{tag:o.tag,offset:0,length:o.origLength},i)}catch(a){console.error(a)}})})}function oS(e){return["cmap","head","hhea","hmtx","maxp","name","OS/2","post","cvt ","fpgm","glyf","loca","prep","CFF ","VORG","EBDT","EBLC","gasp","hdmx","kern","LTSH","PCLT","VDMX","vhea","vmtx","BASE","GDEF","GPOS","GSUB","EBSC","JSTF","MATH","CBDT","CBLC","COLR","CPAL","SVG ","sbix","acnt","avar","bdat","bloc","bsln","cvar","fdsc","feat","fmtx","fvar","gvar","hsty","just","lcar","mort","morx","opbd","prop","trak","Zapf","Silf","Glat","Gloc","Feat","Sill"][e&63]}var iy={},ay=!1;Promise.all([Promise.resolve().then(function(){return FS}),Promise.resolve().then(function(){return IS}),Promise.resolve().then(function(){return NS}),Promise.resolve().then(function(){return VS}),Promise.resolve().then(function(){return jS}),Promise.resolve().then(function(){return GS}),Promise.resolve().then(function(){return qS}),Promise.resolve().then(function(){return XS}),Promise.resolve().then(function(){return sC}),Promise.resolve().then(function(){return gC}),Promise.resolve().then(function(){return oR}),Promise.resolve().then(function(){return sR}),Promise.resolve().then(function(){return cR}),Promise.resolve().then(function(){return pR}),Promise.resolve().then(function(){return hR}),Promise.resolve().then(function(){return yR}),Promise.resolve().then(function(){return wR}),Promise.resolve().then(function(){return SR}),Promise.resolve().then(function(){return RR}),Promise.resolve().then(function(){return TR}),Promise.resolve().then(function(){return PR}),Promise.resolve().then(function(){return kR}),Promise.resolve().then(function(){return IR}),Promise.resolve().then(function(){return DR}),Promise.resolve().then(function(){return MR}),Promise.resolve().then(function(){return BR}),Promise.resolve().then(function(){return zR}),Promise.resolve().then(function(){return HR}),Promise.resolve().then(function(){return GR}),Promise.resolve().then(function(){return ZR}),Promise.resolve().then(function(){return eE}),Promise.resolve().then(function(){return nE}),Promise.resolve().then(function(){return aE}),Promise.resolve().then(function(){return fE}),Promise.resolve().then(function(){return pE}),Promise.resolve().then(function(){return hE}),Promise.resolve().then(function(){return vE}),Promise.resolve().then(function(){return wE}),Promise.resolve().then(function(){return EE}),Promise.resolve().then(function(){return _E}),Promise.resolve().then(function(){return kE})]).then(e=>{e.forEach(t=>{let r=Object.keys(t)[0];iy[r]=t[r]}),ay=!0});function nS(e,t,r){let o=t.tag.replace(/[^\w\d]/g,""),n=iy[o];return n?new n(t,r,e):(console.warn(`lib-font has no definition for ${o}. The table was skipped.`),{})}function sS(){let e=0;function t(r,o){if(!ay)return e>10?o(new Error("loading took too long")):(e++,setTimeout(()=>t(r),250));r(nS)}return new Promise((r,o)=>t(r))}function iS(e,t){let r=e.lastIndexOf("."),o=(e.substring(r+1)||"").toLowerCase(),n={ttf:"truetype",otf:"opentype",woff:"woff",woff2:"woff2"}[o];if(n)return n;let s={eot:"The .eot format is not supported: it died in January 12, 2016, when Microsoft retired all versions of IE that didn't already support WOFF.",svg:"The .svg format is not supported: SVG fonts (not to be confused with OpenType with embedded SVG) were so bad we took the entire fonts chapter out of the SVG specification again.",fon:"The .fon format is not supported: this is an ancient Windows bitmap font format.",ttc:"Based on the current CSS specification, font collections are not (yet?) supported."}[o];if(s||(s=`${e} is not a known webfont format.`),t)throw new Error(s);console.warn(`Could not load font: ${s}`)}async function aS(e,t,r={}){if(!globalThis.document)return;let o=iS(t,r.errorOnStyle);if(!o)return;let n=document.createElement("style");n.className="injected-by-Font-js";let s=[];return r.styleRules&&(s=Object.entries(r.styleRules).map(([i,a])=>`${i}: ${a};`)),n.textContent=` +`}var zh={mobile:"480px",tablet:"782px"},Hh=/^(\d+|\d*\.\d+)(px|em|rem)$/,fx=16;function dx(e){return"mobile"in e||"tablet"in e}function px(e){return!e||typeof e!="object"?{}:dx(e)?e:e.settings?.viewport??{}}function mx(e){return typeof e=="string"&&Hh.test(e.trim())}function Tc(e){if(typeof e=="number")return e;if(typeof e!="string")return;let t=e.trim().match(Hh);if(!t)return;let r=Number.parseFloat(t[1]);return t[2]==="px"?r:r*fx}function Pc(e){let t=px(e),r={},o={};Object.keys(zh).forEach(a=>{let u=a,l=t[u],c=Tc(l);c!==void 0&&mx(l)&&(r[u]=l.trim(),o[u]=c)});let n=Object.keys(r);if(!n.length)return{...zh};if(n.length===1)return r;let i=r.mobile,s=r.tablet;return o.mobile>=o.tablet?{mobile:i}:{mobile:i,tablet:s}}function Uh(e){let t=Pc(e),r={};return t.mobile&&(r["@mobile"]=`@media (width <= ${t.mobile})`),t.tablet&&(r["@tablet"]=t.mobile?`@media (${t.mobile} < width <= ${t.tablet})`:`@media (width <= ${t.tablet})`),r}function Bs(e,t,r,{resolveRefs:o=!0}={}){if(!e?.styles?.blocks?.[t]?.variations?.[r])return;let n=s=>{Object.keys(s).forEach(a=>{let u=s[a];if(typeof u=="object"&&u!==null)if(u.ref!==void 0)if(typeof u.ref!="string"||u.ref.trim()==="")delete s[a];else{let l=ht(e,u.ref);l!=null?s[a]=l:delete s[a]}else n(u),Object.keys(u).length===0&&delete s[a]})},i=JSON.parse(JSON.stringify(e.styles.blocks[t].variations[r]));return o&&n(i),i}var Fc="default";function qh(e){let t=e?.viewport,r=e?.pseudoState;return(!t||t===Fc)&&(!r||r===Fc)}function hx(e){return qh(e)?[]:[e.viewport,e.pseudoState].filter(t=>!!t&&t!==Fc)}function gx(e,t){let r=hx(t);return r.length?ht(e,r):e}var yx=new Set(["blocks","variations","css"]),Oc=Object.freeze({value:{},sources:{}}),vx={root:{layer:"root"},element:{layer:"element"},block:{layer:"block"},blockVariation:{layer:"blockVariation"}};function wo(e){let t=vx[e];return t?{...t}:null}function xo(e,t){return!e||!t?null:{styles:e,source:t}}function bx(e){return e.join(".")}function wx(e){return{...e}}function Zh(e){return e===""||e===null||typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0}function kc(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&typeof e.ref=="string"}function So(e){if(!e||typeof e!="object"||Array.isArray(e))return null;let t={};for(let r of Object.keys(e))if(!yx.has(r)){if(r==="elements"){e.elements&&typeof e.elements=="object"&&(t.elements=e.elements);continue}Zh(e[r])||(t[r]=e[r])}return Object.keys(t).length===0?null:t}var Wh=new Set(["backgroundImage"]);function Xh(e,t,r,o,n,i=[]){if(!t||typeof t!="object"||Array.isArray(t))return e;for(let s of Object.keys(t)){let a=t[s];if(Zh(a))continue;if(kc(a)){if(a.ref.trim()==="")continue;let l=ht(r,a.ref);if(l==null||kc(l))continue;a=l}let u=[...i,s];if(!Wh.has(s)&&a!==null&&typeof a=="object"&&!Array.isArray(a)&&!kc(a)){let l=e[s]&&typeof e[s]=="object"&&!Array.isArray(e[s])?e[s]:{};e[s]=Xh({...l},a,r,o,n,u)}else e[s]=Wh.has(s)&&a!==null&&typeof a=="object"&&!Array.isArray(a)?{...a}:a,o&&n&&(n[bx(u)]=wx(o))}return e}function js(e,t){if(!e)return null;let r=gx(e,t);return r&&typeof r=="object"&&!Array.isArray(r)?r:null}var xx=["color.background","color.gradient","background","spacing","dimensions","border","shadow","filter"];function Sx(e){return e.startsWith("elements.")?!1:xx.some(t=>e===t||e.startsWith(`${t}.`))}function Kh(e,t){if(!e||typeof e!="object")return;let[r,...o]=t;if(o.length===0){delete e[r];return}let n=e[r];n&&typeof n=="object"&&(Kh(n,o),Object.keys(n).length===0&&delete e[r])}function Cx(e,t){for(let r of Object.keys(t))t[r].layer==="root"&&Sx(r)&&(Kh(e,r.split(".")),delete t[r])}function _x(e,t,r){let o=e?.background?.backgroundImage;if(!o)return;let n=gh(o,{...t,_links:r??void 0});n!==void 0&&(e.background.backgroundImage=n)}function Gh(e,{blockName:t,variationName:r=null,elements:o=null,viewport:n=null,pseudoState:i=null}={}){if(!e||!e.styles||!t)return Oc;let s=e.styles,a={viewport:n,pseudoState:i},u=s,l=s.blocks?.[t]??null,c=(o??[]).map(w=>s.elements?.[w]??null).filter(w=>!!w),m=r?Bs(e,t,r)??null:null,d=[xo(So(u),wo("root")),...c.map(w=>xo(So(w),wo("element"))),l?xo(So(l),wo("block")):null,m?xo(So(m),wo("blockVariation")):null];qh(a)||d.push(xo(So(js(u,a)),wo("root")),...c.map(w=>xo(So(js(w,a)),wo("element"))),l?xo(So(js(l,a)),wo("block")):null,m?xo(So(js(m,a)),wo("blockVariation")):null);let h=d.filter(Boolean);if(h.length===0)return Oc;let g={},b=h.reduce((w,C)=>Xh(w,C.styles,e,C.source,g),{});return Cx(b,g),_x(b,e,e._links??null),{value:b,sources:g}}var Rx={},Yh=new WeakMap;function Jh(e,t={}){let r=e?.styles;if(!r||typeof r!="object")return Gh(e,t);let o=Yh.get(r);o||(o=new WeakMap,Yh.set(r,o));let n=e?._links??Rx,i=o.get(n);i||(i=new Map,o.set(n,i));let s=`${t.elements?.join(",")??""}:${t.viewport??""}:${t.pseudoState??""}`,a=(t.blockName||"")+""+(t.variationName||"")+""+s;if(i.has(a))return i.get(a);let u=Gh(e,t);return i.set(a,u),u}var Qh=f(li(),1),{lock:$h,unlock:vI}=(0,Qh.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-engine");var Tn={};$h(Tn,{getResponsiveMediaQueries:Uh,getViewportBreakpoints:Pc,getViewportBreakpointValueInPixels:Tc,getDuotoneFilter:jh,getDuotoneStylesheet:Bh,getDuotoneUnsetStylesheet:Dh,resolveStyle:Jh,getVariationStyle:Bs});var Ac=f(Te(),1);var eg=f(Te(),1),gt=(0,eg.createContext)({user:{styles:{},settings:{}},base:{styles:{},settings:{}},merged:{styles:{},settings:{}},onChange:()=>{},fontLibraryEnabled:!1});var tg=f(Z(),1);function gi({children:e,value:t,baseValue:r,onChange:o,fontLibraryEnabled:n}){let i=(0,Ac.useMemo)(()=>Go(r,t),[r,t]),s=(0,Ac.useMemo)(()=>({user:t,base:r,merged:i,onChange:o,fontLibraryEnabled:n}),[t,r,i,o,n]);return(0,tg.jsx)(gt.Provider,{value:s,children:e})}var eo=f(ue(),1),bg=f(ge(),1);var Bx=f(Kt(),1),jx=f(sr(),1);var rg=f(Z(),1);function Ic({className:e,...t}){return(0,rg.jsx)(ai,{className:We(e,"global-styles-ui-icon-with-current-color"),...t})}var Co=f(ue(),1);var Yo=f(Z(),1);function Ex({icon:e,children:t,...r}){return(0,Yo.jsxs)(Co.__experimentalItem,{...r,children:[e&&(0,Yo.jsxs)(Co.__experimentalHStack,{justify:"flex-start",children:[(0,Yo.jsx)(Ic,{icon:e,size:24}),(0,Yo.jsx)(Co.FlexItem,{children:t})]}),!e&&t]})}function Qr(e){return(0,Yo.jsx)(Co.Navigator.Button,{as:Ex,...e})}var Ox=f(ue(),1);var kx=f(ge(),1),cg=f(Dt(),1);var Lc=function(e){var t=e/255;return t<.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},Nc=function(e){return .2126*Lc(e.r)+.7152*Lc(e.g)+.0722*Lc(e.b)};function og(e){e.prototype.luminance=function(){return t=Nc(this.rgba),(r=2)===void 0&&(r=0),o===void 0&&(o=Math.pow(10,r)),Math.round(o*t)/o+0;var t,r,o},e.prototype.contrast=function(t){t===void 0&&(t="#FFF");var r,o,n,i,s,a,u,l=t instanceof e?t:new e(t);return i=this.rgba,s=l.toRgb(),a=Nc(i),u=Nc(s),r=a>u?(a+.05)/(u+.05):(u+.05)/(a+.05),(o=2)===void 0&&(o=0),n===void 0&&(n=Math.pow(10,o)),Math.floor(n*r)/n+0},e.prototype.isReadable=function(t,r){return t===void 0&&(t="#FFF"),r===void 0&&(r={}),this.contrast(t)>=(a=(s=(o=r).size)===void 0?"normal":s,(i=(n=o.level)===void 0?"AA":n)==="AAA"&&a==="normal"?7:i==="AA"&&a==="large"?3:4.5);var o,n,i,s,a}}var Rr=f(Te(),1),ag=f(Kt(),1),lg=f(sr(),1),Vc=f(ge(),1);var dt=f(ge(),1);var ng=f(li(),1),{lock:WI,unlock:Ve}=(0,ng.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-ui");var{getViewportBreakpoints:ZI}=Ve(Tn),XI={link:[{value:":link",label:(0,dt.__)("Link")},{value:":any-link",label:(0,dt.__)("Any Link")},{value:":visited",label:(0,dt.__)("Visited")},{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}],button:[{value:":link",label:(0,dt.__)("Link")},{value:":any-link",label:(0,dt.__)("Any Link")},{value:":visited",label:(0,dt.__)("Visited")},{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}]},KI={"core/button":[{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}]},JI=[{value:"@tablet",label:(0,dt.__)("Tablet")},{value:"@mobile",label:(0,dt.__)("Mobile")}];function Mc(e,t){if(!t?.length||typeof e!="object"||!e||!Object.keys(e).length)return e;for(let r in e)t.includes(r)?delete e[r]:typeof e[r]=="object"&&Mc(e[r],t);return e}var zs=(e,t)=>{if(!e||!t?.length)return{};let r={};return Object.keys(e).forEach(o=>{if(t.includes(o))r[o]=e[o];else if(typeof e[o]=="object"){let n=zs(e[o],t);Object.keys(n).length&&(r[o]=n)}}),r};function yi(e,t){let r=zs(structuredClone(e),t);return pi(r,e)}function ig(e,t){if(!Array.isArray(e)||!t)return null;let o=t.replace("var(","").replace(")","")?.split("--").slice(-1)[0];return e.find(n=>n.slug===o)}function sg(e){let t=e?.settings?.typography?.fontFamilies?.theme,r=e?.settings?.typography?.fontFamilies?.custom,o=[];t&&r?o=[...t,...r]:t?o=t:r&&(o=r);let n=e?.styles?.typography?.fontFamily,i=ig(o,n),s=e?.styles?.elements?.heading?.typography?.fontFamily,a;return s?a=ig(o,e?.styles?.elements?.heading?.typography?.fontFamily):a=i,[i,a]}Vh([og]);function qe(e,t,r="merged",o=!0,n){let{user:i,base:s,merged:a,onChange:u}=(0,Rr.useContext)(gt),l=n?.split(".").filter(Boolean)??[],c=l.find(w=>w.startsWith(":")),m=l.filter(w=>!w.startsWith(":")).join("."),d=[e,m].filter(Boolean).join("."),h=a;r==="base"?h=s:r==="user"&&(h=i);let g=(0,Rr.useMemo)(()=>{let w=Vs(h,d,t,o);return c?w?.[c]??{}:w},[h,d,t,o,c]),b=(0,Rr.useCallback)(w=>{let C=w;c&&(C={...Vs(i,d,t,!1),[c]:w});let x=wc(i,d,C,t);u(x)},[i,u,d,t,c]);return[g,b]}function Ke(e,t,r="merged"){let{user:o,base:n,merged:i,onChange:s}=(0,Rr.useContext)(gt),a=i;r==="base"?a=n:r==="user"&&(a=o);let u=(0,Rr.useMemo)(()=>yc(a,e,t),[a,e,t]),l=(0,Rr.useCallback)(c=>{let m=vc(o,e,c,t);s(m)},[o,s,e,t]);return[u,l]}var Tx=[];function Px({title:e,settings:t,styles:r}){return e===(0,Vc.__)("Default")||Object.keys(t||{}).length>0||Object.keys(r||{}).length>0}function Hs(e=[]){let{variationsFromTheme:t}=(0,ag.useSelect)(o=>({variationsFromTheme:o(lg.store).__experimentalGetCurrentThemeGlobalStylesVariations?.()||Tx}),[]),{user:r}=(0,Rr.useContext)(gt);return(0,Rr.useMemo)(()=>{let o=structuredClone(r),n=Mc(o,e);n.title=(0,Vc.__)("Default");let i=t.filter(a=>yi(a,e)).map(a=>Go(n,a)),s=[n,...i];return s?.length?s.filter(Px):[]},[e,r,t])}var Dc=f(Z(),1),{useHasDimensionsPanel:lL,useHasTypographyPanel:cL,useHasColorPanel:uL,useSettingsForBlockElement:fL,useHasBackgroundPanel:dL}=Ve(cg.privateApis);var zr=f(ue(),1);function Pn(){let[e="black"]=qe("color.text"),[t="white"]=qe("color.background"),[r=e]=qe("elements.h1.color.text"),[o=r]=qe("elements.link.color.text"),[n=o]=qe("elements.button.color.background"),[i]=Ke("color.palette.core")||[],[s]=Ke("color.palette.theme")||[],[a]=Ke("color.palette.custom")||[],u=(s??[]).concat(a??[]).concat(i??[]),l=u.filter(({color:d})=>d===e),c=u.filter(({color:d})=>d===n),m=l.concat(c).concat(u).filter(({color:d})=>d!==t).slice(0,2);return{paletteColors:u,highlightedColors:m}}var pg=f(Te(),1),mg=f(ue(),1),zc=f(ge(),1);function Fx(e,t){return t.length===0?null:(t.sort((r,o)=>Math.abs(e-r)-Math.abs(e-o)),t[0])}var Ax={normal:400,bold:700};function ug(e){return e!==void 0&&Number.isFinite(e)&&e>=1&&e<=1e3}function Bc(e){let t=String(e??"").trim().toLowerCase().split(/\s+/).filter(Boolean).map(n=>Ax[n]??Number(n)),[r,o]=t;return ug(r)?t.length!==2||!ug(o)?String(r):String(Math.min(Math.max(400,r),o)):"400"}function fg(e){let t=/^(?!generic\([ a-zA-Z\-]+\)$)(?!^[a-zA-Z\-]+$).+/,r=e.trim(),o=n=>(n=n.trim(),n.match(t)?(n=n.replace(/^["']|["']$/g,""),`"${n}"`):n);return r.includes(",")?r.split(",").map(o).filter(n=>n!=="").join(", "):o(r)}function jc(e){if(!e)return"";let t=e.trim();return t.includes(",")&&(t=(t.split(",").find(r=>r.trim()!=="")??"").trim()),t=t.replace(/^["']|["']$/g,""),window.navigator.userAgent.toLowerCase().includes("firefox")&&(t=`"${t}"`),t}function On(e){let t={fontFamily:fg(e.fontFamily)};if(!("fontFace"in e)||!Array.isArray(e.fontFace))return t.fontWeight="400",t.fontStyle="normal",t;if(e.fontFace){let r=e.fontFace.filter(o=>o?.fontStyle&&o.fontStyle.toLowerCase()==="normal");if(r.length>0){t.fontStyle="normal";let o=r.map(n=>Number(Bc(n.fontWeight)));t.fontWeight=String(Fx(400,o)??400)}else t.fontStyle=e.fontFace.length&&e.fontFace[0].fontStyle||"normal",t.fontWeight=e.fontFace.length&&Bc(e.fontFace[0].fontWeight)||"400"}return t}function dg(e){return{fontFamily:fg(e.fontFamily),fontStyle:e.fontStyle||"normal",fontWeight:Bc(e.fontWeight)}}var vi=f(Z(),1);function Us({fontSize:e,variation:t}){let{base:r}=(0,pg.useContext)(gt),o=r;t&&(o={...r,...t});let[n]=qe("color.text"),[i,s]=sg(o),a=i?On(i):{},u=s?On(s):{};return n&&(a.color=n,u.color=n),e&&(a.fontSize=e,u.fontSize=e),(0,vi.jsxs)(mg.__unstableMotion.div,{animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:.3,type:"tween"},style:{textAlign:"center",lineHeight:1},children:[(0,vi.jsx)("span",{style:u,children:(0,zc._x)("A","Uppercase letter A")}),(0,vi.jsx)("span",{style:a,children:(0,zc._x)("a","Lowercase letter A")})]})}var hg=f(ue(),1);var gg=f(Z(),1);function yg({normalizedColorSwatchSize:e,ratio:t}){let{highlightedColors:r}=Pn(),o=e*t;return r.map(({slug:n,color:i},s)=>(0,gg.jsx)(hg.__unstableMotion.div,{style:{height:o,width:o,background:i,borderRadius:o/2},animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:s===1?.2:.1}},`${n}-${s}`))}var vg=f(ue(),1),kn=f(yo(),1),qo=f(Te(),1);var $r=f(Z(),1),Hc=248,Uc=152,Ix={leading:!0,trailing:!0};function Lx({children:e,label:t,isFocused:r,withHoverView:o}){let[n="white"]=qe("color.background"),[i]=qe("color.gradient"),s=(0,kn.useReducedMotion)(),[a,u]=(0,qo.useState)(!1),[l,{width:c}]=(0,kn.useResizeObserver)(),[m,d]=(0,qo.useState)(c),[h,g]=(0,qo.useState)(),b=(0,kn.useThrottle)(d,250,Ix);(0,qo.useLayoutEffect)(()=>{c&&b(c)},[c,b]),(0,qo.useLayoutEffect)(()=>{let v=m?m/Hc:1,_=v-(h||0);(Math.abs(_)>.1||!h)&&g(v)},[m,h]);let w=c?c/Hc:1,C=h||w,x=!!c;return(0,$r.jsxs)($r.Fragment,{children:[(0,$r.jsx)("div",{style:{position:"relative"},children:l}),!x&&(0,$r.jsx)(ui,{className:"global-styles-ui-preview__wrapper",style:{aspectRatio:Hc/Uc}}),x&&(0,$r.jsx)("div",{className:We("global-styles-ui-preview__wrapper",{"is-hoverable":o}),style:{height:Uc*C},onMouseEnter:()=>u(!0),onMouseLeave:()=>u(!1),tabIndex:-1,children:(0,$r.jsx)(vg.__unstableMotion.div,{style:{height:Uc*C,width:"100%",background:i??n},initial:"start",animate:(a||r)&&!s&&t?"hover":"start",children:[].concat(e).map((v,_)=>v({ratio:C,key:_}))})})]})}var Fn=Lx;var Jt=f(Z(),1),Nx={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},Mx={hover:{opacity:1},start:{opacity:.5}},Vx={hover:{scale:1,opacity:1},start:{scale:0,opacity:0}};function Dx({label:e,isFocused:t,withHoverView:r,variation:o}){let[n]=qe("typography.fontWeight"),[i="serif"]=qe("typography.fontFamily"),[s=i]=qe("elements.h1.typography.fontFamily"),[a=n]=qe("elements.h1.typography.fontWeight"),[u="black"]=qe("color.text"),[l=u]=qe("elements.h1.color.text"),{paletteColors:c}=Pn();return(0,Jt.jsxs)(Fn,{label:e,isFocused:t,withHoverView:r,children:[({ratio:m,key:d})=>(0,Jt.jsx)(zr.__unstableMotion.div,{variants:Nx,style:{height:"100%",overflow:"hidden"},children:(0,Jt.jsxs)(zr.__experimentalHStack,{spacing:10*m,justify:"center",style:{height:"100%",overflow:"hidden"},children:[(0,Jt.jsx)(Us,{fontSize:65*m,variation:o}),(0,Jt.jsx)(zr.__experimentalVStack,{spacing:4*m,children:(0,Jt.jsx)(yg,{normalizedColorSwatchSize:32,ratio:m})})]})},d),({key:m})=>(0,Jt.jsx)(zr.__unstableMotion.div,{variants:r?Mx:void 0,style:{height:"100%",width:"100%",position:"absolute",top:0,overflow:"hidden",filter:"blur(60px)",opacity:.1},children:(0,Jt.jsx)(zr.__experimentalHStack,{spacing:0,justify:"flex-start",style:{height:"100%",overflow:"hidden"},children:c.slice(0,4).map(({color:d},h)=>(0,Jt.jsx)("div",{style:{height:"100%",background:d,flexGrow:1}},h))})},m),({ratio:m,key:d})=>(0,Jt.jsx)(zr.__unstableMotion.div,{variants:Vx,style:{height:"100%",width:"100%",overflow:"hidden",position:"absolute",top:0},children:(0,Jt.jsx)(zr.__experimentalVStack,{spacing:3*m,justify:"center",style:{height:"100%",overflow:"hidden",padding:10*m,boxSizing:"border-box"},children:e&&(0,Jt.jsx)("div",{style:{fontSize:40*m,fontFamily:s,color:l,fontWeight:a,lineHeight:"1em",textAlign:"center"},children:e})})},d)]})}var Wc=Dx;var wg=f(Z(),1);var qc=f(_n(),1),Ro=f(ge(),1),Hr=f(ue(),1);var Zc=f(Kt(),1),pr=f(Te(),1),Ws=f(Dt(),1),Eg=f(yo(),1);import{speak as Wx}from"@wordpress/a11y";var xg=f(_n(),1),Sg=f(Kt(),1),zx=f(ue(),1);var Hx=f(Z(),1);function Ux(e,t){return e?.filter(r=>r.source==="block"||t.includes(r.name))||[]}function Gc(e){let t=(0,Sg.useSelect)(n=>{let{getBlockStyles:i}=n(xg.store);return i(e)},[e]),[r]=qe("variations",e),o=Object.keys(r??{});return Ux(t,o)}var _o=f(ue(),1),Cg=f(ge(),1);var _g=f(Dt(),1);var Rg=f(Z(),1),{StateControl:WL,StateControlBadges:GL}=Ve(_g.privateApis);var Bt=f(Z(),1),{useHasDimensionsPanel:Gx,useHasTypographyPanel:Yx,useHasBorderPanel:qx,useSettingsForBlockElement:Zx,useHasColorPanel:Xx,useHasBackgroundPanel:Kx}=Ve(Ws.privateApis),{Menu:tN}=Ve(Hr.privateApis);function Yc(e){return e==null?!1:Array.isArray(e)?e.length>0:typeof e=="object"?Object.values(e).some(Yc):!0}function Jx(e,t){return Yc(e?.styles?.blocks?.[t])||Yc(e?.settings?.blocks?.[t])}function Qx(){let e=(0,Zc.useSelect)(n=>n(qc.store).getBlockTypes(),[]),t=(n,i)=>{let{core:s,noncore:a}=n;return(i.name.startsWith("core/")?s:a).push(i),n},{core:r,noncore:o}=e.reduce(t,{core:[],noncore:[]});return[...r,...o]}function $x(e){let[t]=Ke("",e),r=Zx(t,e),o=Yx(r),n=Xx(r),i=Kx(r),s=qx(r),a=Gx(r),u=s||a,l=!!Gc(e)?.length;return o||n||i||u||l}function eS({block:e,isCustomized:t}){return $x(e.name)?(0,Bt.jsx)(Qr,{path:"/blocks/"+encodeURIComponent(e.name),children:(0,Bt.jsxs)(Hr.__experimentalHStack,{justify:"flex-start",spacing:2,children:[(0,Bt.jsx)(Ws.BlockIcon,{className:"global-styles-ui-block-types-item__icon",icon:e.icon}),(0,Bt.jsx)(Hr.FlexItem,{children:e.title}),t&&(0,Bt.jsxs)(Bt.Fragment,{children:[(0,Bt.jsx)(ec,{children:(0,Ro.__)("Has custom styles")}),(0,Bt.jsx)("span",{"aria-hidden":"true",className:"global-styles-ui-block-types-item__indicator"})]})]})}):null}function tS({filterValue:e,styleFilter:t}){let r=t==="customized"&&!e?(0,Ro.__)("You haven't customized any blocks yet."):(0,Ro.__)("No blocks found.");return(0,Bt.jsx)(Hr.__experimentalText,{align:"center",as:"p",className:"global-styles-ui-block-types-item-list__no-results",children:r})}function rS({filterValue:e,styleFilter:t}){let r=Qx(),o=(0,Eg.useDebounce)(Wx,500),{isMatchingSearchTerm:n}=(0,Zc.useSelect)(qc.store),{user:i}=(0,pr.useContext)(gt),s=(0,pr.useMemo)(()=>{let m=new Set;return[...Object.keys(i?.styles?.blocks??{}),...Object.keys(i?.settings?.blocks??{})].forEach(h=>{Jx(i,h)&&m.add(h)}),m},[i]),a=e?r.filter(m=>n(m,e)):r,u=t==="customized"?a.filter(m=>s.has(m.name)):a,l=(0,pr.useRef)(null),c=u.length>0;return(0,pr.useEffect)(()=>{if(!e&&t==="all")return;let m=c&&l.current?.childElementCount||0,d=(0,Ro.sprintf)((0,Ro._n)("%d result found.","%d results found.",m),m);o(d,"polite")},[e,t,c,o]),(0,Bt.jsx)("div",{ref:l,className:"global-styles-ui-block-types-item-list",role:"list",children:u.length===0?(0,Bt.jsx)(tS,{filterValue:e,styleFilter:t}):u.map(m=>(0,Bt.jsx)(eS,{block:m,isCustomized:s.has(m.name)},"menu-itemblock-"+m.name))})}var rN=(0,pr.memo)(rS);var aS=f(_n(),1),kg=f(Dt(),1),Xc=f(Te(),1),lS=f(Kt(),1),cS=f(sr(),1),Kc=f(ue(),1),Fg=f(ge(),1);var oS=f(Dt(),1),Tg=f(_n(),1),nS=f(ue(),1),iS=f(Te(),1);var sS=f(Z(),1),{getViewportBreakpoints:cN,getViewportBreakpointValueInPixels:uN}=Ve(Tn);var Pg=f(ue(),1),Og=f(Z(),1);function Er({children:e,level:t=2}){return(0,Og.jsx)(Pg.__experimentalHeading,{className:"global-styles-ui-subtitle",level:t,children:e})}var Jc=f(Z(),1);var{useHasDimensionsPanel:RN,useHasTypographyPanel:EN,useHasBorderPanel:TN,useSettingsForBlockElement:PN,useHasColorPanel:ON,useHasFiltersPanel:kN,useHasImageSettingsPanel:FN,useHasBackgroundPanel:AN,BackgroundPanel:IN,BorderPanel:LN,ColorPanel:NN,TypographyPanel:MN,DimensionsPanel:VN,FiltersPanel:DN,ImageSettingsPanel:BN,AdvancedPanel:jN}=Ve(kg.privateApis);var S2=f(ge(),1),C2=f(ue(),1),_2=f(Te(),1);var uS=f(ue(),1);var fS=f(Z(),1);var dS=f(ge(),1),Gs=f(ue(),1);var Ag=f(Z(),1);var Zs=f(ue(),1);var Ig=f(ue(),1);var Ys=f(Z(),1),pS=({variation:e,isFocused:t,withHoverView:r})=>(0,Ys.jsx)(Fn,{label:e.title,isFocused:t,withHoverView:r,children:({ratio:o,key:n})=>(0,Ys.jsx)(Ig.__experimentalHStack,{spacing:10*o,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Ys.jsx)(Us,{variation:e,fontSize:85*o})},n)}),Lg=pS;var Zo=f(Te(),1),Mg=f(Qc(),1),qs=f(ge(),1);var Eo=f(Z(),1);function An({variation:e,children:t,isPill:r=!1,properties:o,showTooltip:n=!1}){let[i,s]=(0,Zo.useState)(!1),{base:a,user:u,onChange:l}=(0,Zo.useContext)(gt),c=(0,Zo.useMemo)(()=>{let w=Go(a,e);return o&&(w=zs(w,o)),{user:e,base:a,merged:w,onChange:()=>{}}},[e,a,o]),m=()=>l(e),d=w=>{w.keyCode===Mg.ENTER&&(w.preventDefault(),m())},h=(0,Zo.useMemo)(()=>pi(u,e),[u,e]),g=e?.title;e?.description&&(g=(0,qs.sprintf)((0,qs._x)("%1$s (%2$s)","variation label"),e?.title,e?.description));let b=(0,Eo.jsx)("div",{className:We("global-styles-ui-variations_item",{"is-active":h}),role:"button",onClick:m,onKeyDown:d,tabIndex:0,"aria-label":g,"aria-current":h,onFocus:()=>s(!0),onBlur:()=>s(!1),children:(0,Eo.jsx)("div",{className:We("global-styles-ui-variations_item-preview",{"is-pill":r}),children:t(i)})});return(0,Eo.jsx)(gt.Provider,{value:c,children:n?(0,Eo.jsxs)(Sn.Root,{children:[(0,Eo.jsx)(Sn.Trigger,{render:b}),(0,Eo.jsx)(Sn.Popup,{children:e?.title})]}):b})}var Xo=f(Z(),1),Vg=["typography"];function Xs({title:e,gap:t=2}){let r=Hs(Vg);return r?.length<=1?null:(0,Xo.jsxs)(Zs.__experimentalVStack,{spacing:3,children:[e&&(0,Xo.jsx)(Er,{level:3,children:e}),(0,Xo.jsx)(Zs.__experimentalGrid,{columns:3,gap:t,className:"global-styles-ui-style-variations-container",children:r.map((o,n)=>(0,Xo.jsx)(An,{variation:o,properties:Vg,showTooltip:!0,children:()=>(0,Xo.jsx)(Lg,{variation:o})},n))})]})}var w2=f(ge(),1),Ri=f(ue(),1);var x2=f(Te(),1);var to=f(Te(),1),ko=f(Kt(),1),Oo=f(sr(),1),ru=f(ge(),1);var $c=f(Bg(),1),jg=f(sr(),1),zg="/wp/v2/font-families";function Hg(e){let{receiveEntityRecords:t}=e.dispatch(jg.store);t("postType","wp_font_family",[],void 0,!0)}async function Ug(e,t){let o=await(0,$c.default)({path:zg,method:"POST",body:e});return Hg(t),{id:o.id,...o.font_family_settings,fontFace:[]}}async function Wg(e,t,r){let o={path:`${zg}/${e}/font-faces`,method:"POST",body:t},n=await(0,$c.default)(o);return Hg(r),{id:n.id,...n.font_face_settings}}var In=function(){return In=Object.assign||function(t){for(var r,o=1,n=arguments.length;o{o.forEach(n=>{n.family===jc(e?.fontFamily)&&n.weight===e?.fontWeight&&n.style===e?.fontStyle&&o.delete(n)})};if((t==="document"||t==="all")&&r(document.fonts),t==="iframe"||t==="all"){let o=document.querySelector('iframe[name="editor-canvas"]');o?.contentDocument&&r(o.contentDocument.fonts)}}function Ln(e){if(!e)return;let t;if(Array.isArray(e)?t=e[0]:t=e,!t.startsWith("file:."))return gS(t)||(t=encodeURI(t)),t}function ey(e){let t=new FormData,{fontFace:r,category:o,...n}=e,i={...n,slug:Ks(e.slug)};return t.append("font_family_settings",JSON.stringify(i)),t}function ty(e){return(e?.fontFace??[]).map((r,o)=>{let n={...r},i=new FormData;if(n.file){let s=Array.isArray(n.file)?n.file:[n.file],a=[];s.forEach((u,l)=>{let c=`file-${o}-${l}`;i.append(c,u,u.name),a.push(c)}),n.src=a.length===1?a[0]:a,delete n.file,i.append("font_face_settings",JSON.stringify(n))}else i.append("font_face_settings",JSON.stringify(n));return i})}async function ry(e,t,r){let o=[];for(let i of t)try{let s=await Wg(e,i,r);o.push({status:"fulfilled",value:s})}catch(s){o.push({status:"rejected",reason:s})}let n={errors:[],successes:[]};return o.forEach((i,s)=>{if(i.status==="fulfilled"&&i.value){let a=i.value;n.successes.push(a)}else i.reason&&n.errors.push({data:t[s],message:i.reason.message})}),n}async function oy(e){e=Array.isArray(e)?e:[e];let t=await Promise.all(e.map(async r=>fetch(new Request(r)).then(o=>{if(!o.ok)throw new Error(`Error downloading font face asset from ${r}. Server responded with status: ${o.status}`);return o.blob()}).then(o=>{let n=r.split("/").pop();return new Qg([o],n,{type:o.type})})));return t.length===1?t[0]:t}function tu(e,t){return t.findIndex(r=>r.fontWeight===e.fontWeight&&r.fontStyle===e.fontStyle)!==-1}function ny(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let i of t){let s=n[i];n=n[i]=Array.isArray(s)?[...s]:{...s}}return n[o]=r,e}function Qs(e,t,r=[]){let o=u=>u.slug===e.slug,n=u=>u.find(o),i=u=>u?r.filter(l=>!o(l)):[...r,e],s=u=>{let l=m=>m.fontWeight===t.fontWeight&&m.fontStyle===t.fontStyle;if(!u)return[...r,{...e,fontFace:[t]}];let c=u.fontFace||[];return c.find(l)?c=c.filter(m=>!l(m)):c=[...c,t],c.length===0?r.filter(m=>!o(m)):r.map(m=>o(m)?{...m,fontFace:c}:m)},a=n(r);return t?s(a):i(a)}var iy=f(Z(),1),jt=(0,to.createContext)({});jt.displayName="FontLibraryContext";function vS({children:e}){let t=(0,ko.useRegistry)(),{saveEntityRecord:r,deleteEntityRecord:o}=(0,ko.useDispatch)(Oo.store),{globalStylesId:n}=(0,ko.useSelect)(R=>{let{__experimentalGetCurrentGlobalStylesId:B}=R(Oo.store);return{globalStylesId:B()}},[]),i=(0,Oo.useEntityRecord)("root","globalStyles",n),[s,a]=(0,to.useState)(!1),{records:u=[],isResolving:l}=(0,Oo.useEntityRecords)("postType","wp_font_family",{_embed:!0}),c=(u||[]).map(R=>({id:R.id,...R.font_family_settings||{},fontFace:R?._embedded?.font_faces?.map(B=>B.font_face_settings)||[]}))||[],[m,d]=Ke("typography.fontFamilies"),h=async R=>{if(!i.record)return;let B=i.record,re=ny(B??{},["settings","typography","fontFamilies"],R);await r("root","globalStyles",re)},[g,b]=(0,to.useState)(""),[w,C]=(0,to.useState)(void 0),x=m?.theme?m.theme.map(R=>To(R,{source:"theme"})).sort((R,B)=>R.name.localeCompare(B.name)):[],v=m?.custom?m.custom.map(R=>To(R,{source:"custom"})).sort((R,B)=>R.name.localeCompare(B.name)):[],_=c?c.map(R=>To(R,{source:"custom"})).sort((R,B)=>R.name.localeCompare(B.name)):[];(0,to.useEffect)(()=>{g||C(void 0)},[g]);let k=R=>{if(!R){C(void 0);return}let re=(R.source==="theme"?x:_).find(P=>P.slug===R.slug);C({...re||R,source:R.source})},[E]=(0,to.useState)(new Set),T=R=>R.reduce((re,P)=>{let W=P?.fontFace&&P.fontFace?.length>0?P?.fontFace.map(ne=>`${ne.fontStyle??""}${ne.fontWeight??""}`):["normal400"];return re[P.slug]=W,re},{}),O=R=>T(R==="theme"?x:v),I=(R,B,re,P)=>!B&&!re?!!O(P)[R]:!!O(P)[R]?.includes((B??"")+(re??"")),J=(R,B)=>O(B)[R]||[];async function D(R){a(!0);try{let B=[],re=[];for(let W of R){let ne=!1,xe=await(0,ko.resolveSelect)(Oo.store).getEntityRecords("postType","wp_font_family",{slug:W.slug,per_page:1,_embed:!0}),se=xe&&xe.length>0?xe[0]:null,be=se?{id:se.id,...se.font_family_settings,fontFace:(se?._embedded?.font_faces??[]).map(Fe=>Fe.font_face_settings)||[]}:null;be||(ne=!0,be=await Ug(ey(W),t));let ye=be.fontFace&&W.fontFace?be.fontFace.filter(Fe=>Fe&&W.fontFace&&tu(Fe,W.fontFace)):[];be.fontFace&&W.fontFace&&(W.fontFace=W.fontFace.filter(Fe=>!tu(Fe,be.fontFace)));let $=[],_e=[];if(W?.fontFace?.length??!1){let Fe=await ry(be.id,ty(W),t);$=Fe?.successes,_e=Fe?.errors}($?.length>0||ye?.length>0)&&(be.fontFace=[...$],B.push(be)),be&&!W?.fontFace?.length&&B.push(be),ne&&(W?.fontFace?.length??0)>0&&$?.length===0&&await o("postType","wp_font_family",be.id,{force:!0}),re=re.concat(_e)}let P=re.reduce((W,ne)=>W.includes(ne.message)?W:[...W,ne.message],[]);if(B.length>0){let W=Y(B);await h(W)}if(P.length>0){let W=new Error((0,ru.__)("There was an error installing fonts."));throw W.installationErrors=P,W}}finally{a(!1)}}async function S(R){if(!R?.id)throw new Error((0,ru.__)("Font family to uninstall is not defined."));try{await o("postType","wp_font_family",R.id,{force:!0});let B=L(R);return await h(B),{deleted:!0}}catch(B){throw console.error("There was an error uninstalling the font family:",B),B}}let L=R=>{let re=(m?.[R.source??""]??[]).filter(W=>W.slug!==R.slug),P={...m,[R.source??""]:re};return d(P),R.fontFace&&R.fontFace.forEach(W=>{bi(W,"all")}),P},Y=R=>{let B=A(R),re={...m,custom:$g(m?.custom,B)};return d(re),N(B),re},A=R=>R.map(({id:B,fontFace:re,...P})=>({...P,...re&&re.length>0?{fontFace:re.map(({id:W,...ne})=>ne)}:{}})),N=R=>{R.forEach(B=>{B.fontFace&&B.fontFace.forEach(re=>{let P=Ln(re?.src??"");P&&Po(re,P,"all")})})},q=(R,B)=>{let re=m?.[R.source??""]??[],P=Qs(R,B,re);d({...m,[R.source??""]:P});let W=I(R.slug,B?.fontStyle??"",B?.fontWeight??"",R.source??"custom");if(B&&W)bi(B,"all");else{let ne=Ln(B?.src??"");B&&ne&&Po(B,ne,"all")}},U=async R=>{if(!R.src)return;let B=Ln(R.src);!B||E.has(B)||(Po(R,B,"document"),E.add(B))};return(0,iy.jsx)(jt.Provider,{value:{libraryFontSelected:w,handleSetLibraryFontSelected:k,fontFamilies:m??{},baseCustomFonts:_,isFontActivated:I,getFontFacesActivated:J,loadFontFaceAsset:U,installFonts:D,uninstallFontFamily:S,toggleActivateFont:q,getAvailableFontsOutline:T,modalTabOpen:g,setModalTabOpen:b,saveFontFamilies:h,isResolvingLibrary:l,isInstalling:s},children:e})}var $s=vS;var ma=f(ge(),1),au=f(ue(),1),zy=f(sr(),1),v2=f(Kt(),1);var Ie=f(ue(),1),xi=f(sr(),1),ou=f(Kt(),1),Wr=f(Te(),1),st=f(ge(),1);var Mn=f(ge(),1),ea=f(Te(),1),hr=f(ue(),1);var Tr=f(Te(),1);var ro=f(Z(),1),sy=new Set;function bS(e){if(e.preview)return e.preview;if(e.src)return Array.isArray(e.src)?e.src[0]:e.src}function wS(e){return"fontStyle"in e&&e.fontStyle||"fontWeight"in e&&e.fontWeight?e:"fontFace"in e&&e.fontFace&&e.fontFace.length?e.fontFace.find(t=>t.fontStyle==="normal"&&t.fontWeight==="400")||e.fontFace[0]:{fontStyle:"normal",fontWeight:"400",fontFamily:e.fontFamily}}function xS({font:e,text:t}){let r=(0,Tr.useRef)(null),o=wS(e),n=On(e);t=t||("name"in e?e.name:"");let s=e.preview??bS(o),a=!!(s&&/\.(png|jpg|jpeg|gif|svg)$/i.test(s)),[u,l]=(0,Tr.useState)(!1),[c,m]=(0,Tr.useState)(!1),[d,h]=(0,Tr.useState)(),{loadFontFaceAsset:g}=(0,Tr.useContext)(jt),b=a?!!s&&(sy.has(s)||d===s):c,w=Math.min(Math.max(t.length*12,48),300),C=dg(o),x={fontSize:"18px",lineHeight:1,opacity:b?"1":"0",...n,...C};return(0,Tr.useEffect)(()=>{if(a)return;let v=new window.IntersectionObserver(([_])=>{l(_.isIntersecting)},{});return r.current&&v.observe(r.current),()=>v.disconnect()},[a]),(0,Tr.useEffect)(()=>{(async()=>u&&!a&&(o.src&&await g(o),m(!0)))()},[o,u,g,a]),(0,ro.jsx)("div",{ref:r,className:"font-library__font-demo",children:a?(0,ro.jsxs)(ro.Fragment,{children:[!b&&(0,ro.jsx)(ui,{className:"font-library__font-variant-demo-skeleton",style:{width:w}}),(0,ro.jsx)("img",{src:s,loading:"lazy",alt:t,onLoad:()=>{s&&sy.add(s),h(s)},onError:()=>h(s),className:We("font-library__font-variant_demo-image",{"is-loading":!b})})]}):(0,ro.jsx)("span",{style:x,className:"font-library__font-variant_demo-text",children:t})})}var Nn=xS;var Ur=f(Z(),1);function SS({font:e,onClick:t,variantsText:r,navigatorPath:o,shouldFocus:n}){let i=e.fontFace?.length||1,s={cursor:t?"pointer":"default"},a=(0,hr.useNavigator)(),u=(0,ea.useRef)(null);return(0,ea.useEffect)(()=>{n&&u.current?.focus()},[n]),(0,Ur.jsx)(hr.Button,{ref:u,__next40pxDefaultSize:!0,onClick:()=>{t(),o&&a.goTo(o)},style:s,className:"font-library__font-card",children:(0,Ur.jsxs)(hr.Flex,{justify:"space-between",wrap:!1,children:[(0,Ur.jsx)(Nn,{font:e}),(0,Ur.jsxs)(hr.Flex,{justify:"flex-end",children:[(0,Ur.jsx)(hr.FlexItem,{children:(0,Ur.jsx)(hr.__experimentalText,{className:"font-library__font-card__count",children:r||(0,Mn.sprintf)((0,Mn._n)("%d variant","%d variants",i),i)})}),(0,Ur.jsx)(hr.FlexItem,{children:(0,Ur.jsx)(ai,{icon:(0,Mn.isRTL)()?Uo:Wo})})]})]})})}var wi=SS;var ta=f(Te(),1),ra=f(ue(),1);var Ko=f(Z(),1);function CS({face:e,font:t}){let{isFontActivated:r,toggleActivateFont:o}=(0,ta.useContext)(jt),n=(t?.fontFace?.length??0)>0?r(t.slug,e.fontStyle,e.fontWeight,t.source):r(t.slug,void 0,void 0,t.source),i=()=>{if((t?.fontFace?.length??0)>0){o(t,e);return}o(t)},s=t.name+" "+Js(e),a=(0,ta.useId)();return(0,Ko.jsx)("div",{className:"font-library__font-card",children:(0,Ko.jsxs)(ra.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Ko.jsx)(ra.CheckboxControl,{checked:n,onChange:i,id:a}),(0,Ko.jsx)("label",{htmlFor:a,children:(0,Ko.jsx)(Nn,{font:e,text:s,onClick:i})})]})})}var ay=CS;function ly(e){switch(e){case"normal":return 400;case"bold":return 700;case"bolder":return 500;case"lighter":return 300;default:return parseInt(e,10)}}function oa(e){return e.sort((t,r)=>t.fontStyle==="normal"&&r.fontStyle!=="normal"?-1:r.fontStyle==="normal"&&t.fontStyle!=="normal"?1:t.fontStyle===r.fontStyle?ly(t.fontWeight?.toString()??"normal")-ly(r.fontWeight?.toString()??"normal"):!t.fontStyle||!r.fontStyle?t.fontStyle?-1:1:t.fontStyle.localeCompare(r.fontStyle))}var Ee=f(Z(),1);function cy(e){if(!e)return"";let t={};for(let r of Object.keys(e).sort())t[r]=(e[r]??[]).map(o=>({slug:o.slug,fontFace:(o.fontFace??[]).map(n=>`${n.fontStyle}-${n.fontWeight}`).sort()})).sort((o,n)=>o.slug.localeCompare(n.slug));return JSON.stringify(t)}function _S(){let{baseCustomFonts:e,libraryFontSelected:t,handleSetLibraryFontSelected:r,uninstallFontFamily:o,isResolvingLibrary:n,isInstalling:i,saveFontFamilies:s,getFontFacesActivated:a}=(0,Wr.useContext)(jt),[u,l]=Ke("typography.fontFamilies"),[c,m]=(0,Wr.useState)(void 0),[d,h]=(0,Wr.useState)(!1),[g,b]=(0,Wr.useState)(null),[w]=Ke("typography.fontFamilies",void 0,"base"),C=(0,ou.useSelect)(P=>{let{__experimentalGetCurrentGlobalStylesId:W}=P(xi.store);return W()},[]),x=(0,xi.useEntityRecord)("root","globalStyles",C),v=x?.edits?.settings?.typography?.fontFamilies,_=x?.record?.settings?.typography?.fontFamilies,k=(0,Wr.useMemo)(()=>v===void 0?!1:cy(v)!==cy(_),[v,_]),E=u?.theme?u.theme.map(P=>To(P,{source:"theme"})).sort((P,W)=>P.name.localeCompare(W.name)):[],T=new Set(E.map(P=>P.slug)),O=w?.theme?E.concat(w.theme.filter(P=>!T.has(P.slug)).map(P=>To(P,{source:"theme"})).sort((P,W)=>P.name.localeCompare(W.name))):[],I=t?.source==="custom"&&t?.id,J=(0,ou.useSelect)(P=>{let{canUser:W}=P(xi.store);return I&&W("delete",{kind:"postType",name:"wp_font_family",id:I})},[I]),D=!!t&&t?.source!=="theme"&&J,S=()=>{h(!0)},L=async()=>{b(null);try{await s(u),b({type:"success",message:(0,st.__)("Font family updated successfully.")})}catch(P){b({type:"error",message:(0,st.sprintf)((0,st.__)("There was an error updating the font family. %s"),P.message)})}},Y=P=>P?!P.fontFace||!P.fontFace.length?[{fontFamily:P.fontFamily,fontStyle:"normal",fontWeight:"400"}]:oa(P.fontFace):[],A=P=>{let W=P?.fontFace&&(P?.fontFace?.length??0)>0?P.fontFace.length:1,ne=a(P.slug,P.source).length;return(0,st.sprintf)((0,st.__)("%1$d of %2$d active"),ne,W)};(0,Wr.useEffect)(()=>{r(t)},[]);let N=t?a(t.slug,t.source).length:0,q=t?.fontFace?.length??(t?.fontFamily?1:0),U=N>0&&N!==q,R=N===q,B=()=>{if(!t||!t?.source)return;let P=u?.[t.source]?.filter(ne=>ne.slug!==t.slug)??[],W=R?P:[...P,t];l({...u,[t.source]:W}),t.fontFace&&t.fontFace.forEach(ne=>{if(R)bi(ne,"all");else{let xe=Ln(ne?.src??"");xe&&Po(ne,xe,"all")}})},re=O.length>0||e.length>0;return(0,Ee.jsxs)("div",{className:"font-library__tabpanel-layout",children:[n&&(0,Ee.jsx)("div",{className:"font-library__loading",children:(0,Ee.jsx)(Ie.ProgressBar,{})}),!n&&(0,Ee.jsxs)(Ee.Fragment,{children:[(0,Ee.jsxs)(Ie.Navigator,{initialPath:t?"/fontFamily":"/",children:[(0,Ee.jsx)(Ie.Navigator.Screen,{path:"/",children:(0,Ee.jsxs)(Ie.__experimentalVStack,{spacing:"8",children:[g&&(0,Ee.jsx)(Ie.Notice,{status:g.type,onRemove:()=>b(null),children:g.message}),!re&&(0,Ee.jsx)(Ie.__experimentalText,{as:"p",children:(0,st.__)("No fonts installed.")}),O.length>0&&(0,Ee.jsxs)(Ie.__experimentalVStack,{children:[(0,Ee.jsx)("h2",{className:"font-library__fonts-title",children:(0,st._x)("Theme","font source")}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:O.map(P=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(wi,{font:P,navigatorPath:"/fontFamily",variantsText:A(P),shouldFocus:P.slug===c,onClick:()=>{b(null),r(P)}})},P.slug))})]}),e.length>0&&(0,Ee.jsxs)(Ie.__experimentalVStack,{children:[(0,Ee.jsx)("h2",{className:"font-library__fonts-title",children:(0,st._x)("Custom","font source")}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:e.map(P=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(wi,{font:P,navigatorPath:"/fontFamily",variantsText:A(P),shouldFocus:P.slug===c,onClick:()=>{b(null),r(P)}})},P.slug))})]})]})}),(0,Ee.jsxs)(Ie.Navigator.Screen,{path:"/fontFamily",children:[t&&(0,Ee.jsx)(RS,{font:t,isOpen:d,setIsOpen:h,setNotice:b,uninstallFontFamily:o,handleSetLibraryFontSelected:r}),(0,Ee.jsxs)(Ie.Flex,{justify:"flex-start",children:[(0,Ee.jsx)(Ie.Navigator.BackButton,{icon:(0,st.isRTL)()?Wo:Uo,size:"small",onClick:()=>{m(t?.slug),r(void 0),b(null)},label:(0,st.__)("Back")}),(0,Ee.jsx)(Ie.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:t?.name})]}),g&&(0,Ee.jsxs)(Ee.Fragment,{children:[(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:1}),(0,Ee.jsx)(Ie.Notice,{status:g.type,onRemove:()=>b(null),children:g.message}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:1})]}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Ee.jsx)(Ie.__experimentalText,{children:(0,st.__)("Choose font variants. Keep in mind that too many variants could make your site slower.")}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Ee.jsxs)(Ie.__experimentalVStack,{spacing:0,children:[(0,Ee.jsx)(Ie.CheckboxControl,{className:"font-library__select-all",label:(0,st.__)("Select all"),checked:R,onChange:B,indeterminate:U}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:8}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:t&&Y(t).map((P,W)=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(ay,{font:t,face:P},`face${W}`)},`face${W}`))})]})]})]}),(0,Ee.jsxs)(Ie.__experimentalHStack,{justify:"flex-end",className:"font-library__footer",children:[i&&(0,Ee.jsx)(Ie.ProgressBar,{}),D&&(0,Ee.jsx)(Ie.Button,{__next40pxDefaultSize:!0,isDestructive:!0,variant:"tertiary",onClick:S,children:(0,st.__)("Delete")}),(0,Ee.jsx)(Ie.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:L,disabled:!k,accessibleWhenDisabled:!0,children:(0,st.__)("Update")})]})]})]})}function RS({font:e,isOpen:t,setIsOpen:r,setNotice:o,uninstallFontFamily:n,handleSetLibraryFontSelected:i}){let s=(0,Ie.useNavigator)(),a=async()=>{o(null),r(!1);try{await n(e),s.goBack(),i(void 0),o({type:"success",message:(0,st.__)("Font family uninstalled successfully.")})}catch(l){o({type:"error",message:(0,st.__)("There was an error uninstalling the font family.")+l.message})}},u=()=>{r(!1)};return(0,Ee.jsx)(Ie.__experimentalConfirmDialog,{isOpen:t,cancelButtonText:(0,st.__)("Cancel"),confirmButtonText:(0,st.__)("Delete"),onCancel:u,onConfirm:a,size:"medium",children:e&&(0,st.sprintf)((0,st.__)('Are you sure you want to delete "%s" font and all its variants and assets?'),e.name)})}var na=_S;var yt=f(Te(),1),Ce=f(ue(),1),yy=f(yo(),1),rt=f(ge(),1);var vy=f(sr(),1);function uy(e,t){let{category:r,search:o}=t,n=e||[];return r&&r!=="all"&&(n=n.filter(i=>i.categories&&i.categories.indexOf(r)!==-1)),o&&(n=n.filter(i=>i.font_family_settings&&i.font_family_settings.name.toLowerCase().includes(o.toLowerCase()))),n}function fy(e){return e.reduce((t,r)=>({...t,[r.slug]:(r?.fontFace||[]).reduce((o,n)=>({...o,[`${n.fontStyle}-${n.fontWeight}`]:!0}),{})}),{})}function dy(e,t,r){return t?!!r[e]?.[`${t.fontStyle}-${t.fontWeight}`]:!!r[e]}var Si=f(ge(),1),zt=f(ue(),1),gr=f(Z(),1);function ES(){let e=()=>{window.localStorage.setItem("wp-font-library-google-fonts-permission","true"),window.dispatchEvent(new Event("storage"))};return(0,gr.jsx)("div",{className:"font-library__google-fonts-confirm",children:(0,gr.jsx)(zt.Card,{children:(0,gr.jsxs)(zt.CardBody,{children:[(0,gr.jsx)(zt.__experimentalHeading,{level:2,children:(0,Si.__)("Connect to Google Fonts")}),(0,gr.jsx)(zt.__experimentalSpacer,{margin:6}),(0,gr.jsx)(zt.__experimentalText,{as:"p",children:(0,Si.__)("To install fonts from Google you must give permission to connect directly to Google servers. The fonts you install will be downloaded from Google and stored on your site. Your site will then use these locally-hosted fonts.")}),(0,gr.jsx)(zt.__experimentalSpacer,{margin:3}),(0,gr.jsx)(zt.__experimentalText,{as:"p",children:(0,Si.__)("You can alternatively upload files directly on the Upload tab.")}),(0,gr.jsx)(zt.__experimentalSpacer,{margin:6}),(0,gr.jsx)(zt.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:e,children:(0,Si.__)("Allow access to Google Fonts")})]})})})}var py=ES;var my=f(Te(),1),ia=f(ue(),1);var Jo=f(Z(),1);function TS({face:e,font:t,handleToggleVariant:r,selected:o}){let n=()=>{if(t?.fontFace){r(t,e);return}r(t)},i=t.name+" "+Js(e),s=(0,my.useId)();return(0,Jo.jsx)("div",{className:"font-library__font-card",children:(0,Jo.jsxs)(ia.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Jo.jsx)(ia.CheckboxControl,{checked:o,onChange:n,id:s}),(0,Jo.jsx)("label",{htmlFor:s,children:(0,Jo.jsx)(Nn,{font:e,text:i,onClick:n})})]})})}var hy=TS;var de=f(Z(),1),PS={slug:"all",name:(0,rt._x)("All","font categories")},gy="wp-font-library-google-fonts-permission",OS=500;function kS({slug:e}){let t=e==="google-fonts",r=()=>window.localStorage.getItem(gy)==="true",[o,n]=(0,yt.useState)(null),[i,s]=(0,yt.useState)(void 0),[a,u]=(0,yt.useState)(null),[l,c]=(0,yt.useState)([]),[m,d]=(0,yt.useState)(1),[h,g]=(0,yt.useState)({}),[b,w]=(0,yt.useState)(t&&!r()),{installFonts:C,isInstalling:x}=(0,yt.useContext)(jt),{record:v,isResolving:_}=(0,vy.useEntityRecord)("root","fontCollection",e);(0,yt.useEffect)(()=>{let $=()=>{w(t&&!r())};return $(),window.addEventListener("storage",$),()=>window.removeEventListener("storage",$)},[e,t]);let k=()=>{window.localStorage.setItem(gy,"false"),window.dispatchEvent(new Event("storage"))};(0,yt.useEffect)(()=>{n(null)},[e]),(0,yt.useEffect)(()=>{c([])},[o]);let E=(0,yt.useMemo)(()=>v?.font_families??[],[v]),T=v?.categories??[],O=[PS,...T],I=(0,yt.useMemo)(()=>uy(E,h),[E,h]),J=Math.max(window.innerHeight,OS),D=Math.floor((J-417)/61),S=Math.ceil(I.length/D),L=(m-1)*D,Y=m*D,A=I.slice(L,Y),N=$=>{g({...h,category:$}),d(1)},U=(0,yy.debounce)($=>{g({...h,search:$}),d(1)},300),R=($,_e)=>{let Fe=Qs($,_e,l);c(Fe)},B=fy(l),re=()=>{c([])},P=l.length>0?l[0]?.fontFace?.length??0:0,W=P>0&&P!==o?.fontFace?.length,ne=P===o?.fontFace?.length,xe=()=>{let $=[];!ne&&o&&$.push(o),c($)},se=async()=>{u(null);let $=l[0];try{$?.fontFace&&await Promise.all($.fontFace.map(async _e=>{_e.src&&(_e.file=await oy(_e.src))}))}catch{u({type:"error",message:(0,rt.__)("Error installing the fonts, could not be downloaded.")});return}try{await C([$]),u({type:"success",message:(0,rt.__)("Fonts were installed successfully.")})}catch(_e){u({type:"error",message:_e.message})}re()},be=$=>$?!$.fontFace||!$.fontFace.length?[{fontFamily:$.fontFamily,fontStyle:"normal",fontWeight:"400"}]:oa($.fontFace):[];if(b)return(0,de.jsx)(py,{});let ye=e==="google-fonts"&&!b&&!o;return(0,de.jsxs)("div",{className:"font-library__tabpanel-layout",children:[_&&(0,de.jsx)("div",{className:"font-library__loading",children:(0,de.jsx)(Ce.ProgressBar,{})}),!_&&v&&(0,de.jsxs)(de.Fragment,{children:[(0,de.jsxs)(Ce.Navigator,{initialPath:"/",className:"font-library__tabpanel-layout",children:[(0,de.jsxs)(Ce.Navigator.Screen,{path:"/",children:[(0,de.jsxs)(Ce.__experimentalHStack,{justify:"space-between",children:[(0,de.jsxs)(Ce.__experimentalVStack,{children:[(0,de.jsx)(Ce.__experimentalHeading,{level:2,size:13,children:v.name}),(0,de.jsx)(Ce.__experimentalText,{children:v.description})]}),ye&&(0,de.jsx)(Ce.DropdownMenu,{icon:jl,label:(0,rt.__)("Actions"),popoverProps:{position:"bottom left"},controls:[{title:(0,rt.__)("Revoke access to Google Fonts"),onClick:k}]})]}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,de.jsxs)(Ce.__experimentalHStack,{spacing:4,justify:"space-between",children:[(0,de.jsx)(Ce.SearchControl,{className:"font-library__search",value:h.search,placeholder:(0,rt.__)("Font name\u2026"),label:(0,rt.__)("Search"),onChange:U,hideLabelFromVision:!1}),(0,de.jsx)(Ce.SelectControl,{label:(0,rt.__)("Category"),value:h.category,onChange:N,children:O&&O.map($=>(0,de.jsx)("option",{value:$.slug,children:$.name},$.slug))})]}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),!!v?.font_families?.length&&!I.length&&(0,de.jsx)(Ce.__experimentalText,{children:(0,rt.__)("No fonts found. Try with a different search term.")}),(0,de.jsx)("div",{className:"font-library__fonts-grid__main",children:(0,de.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:A.map($=>(0,de.jsx)("li",{className:"font-library__fonts-list-item",children:(0,de.jsx)(wi,{font:$.font_family_settings,navigatorPath:"/fontFamily",shouldFocus:$.font_family_settings.slug===i,onClick:()=>{n($.font_family_settings)}})},$.font_family_settings.slug))})})]}),(0,de.jsxs)(Ce.Navigator.Screen,{path:"/fontFamily",children:[(0,de.jsxs)(Ce.Flex,{justify:"flex-start",children:[(0,de.jsx)(Ce.Navigator.BackButton,{icon:(0,rt.isRTL)()?Wo:Uo,size:"small",onClick:()=>{s(o?.slug),n(null),u(null)},label:(0,rt.__)("Back")}),(0,de.jsx)(Ce.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:o?.name})]}),a&&(0,de.jsxs)(de.Fragment,{children:[(0,de.jsx)(Ce.__experimentalSpacer,{margin:1}),(0,de.jsx)(Ce.Notice,{status:a.type,onRemove:()=>u(null),children:a.message}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:1})]}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,de.jsx)(Ce.__experimentalText,{children:(0,rt.__)("Select font variants to install.")}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,de.jsx)(Ce.CheckboxControl,{className:"font-library__select-all",label:(0,rt.__)("Select all"),checked:ne,onChange:xe,indeterminate:W}),(0,de.jsx)(Ce.__experimentalVStack,{spacing:0,children:(0,de.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:o&&be(o).map(($,_e)=>(0,de.jsx)("li",{className:"font-library__fonts-list-item",children:(0,de.jsx)(hy,{font:o,face:$,handleToggleVariant:R,selected:dy(o.slug,o.fontFace?$:null,B)})},`face${_e}`))})}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:16})]})]}),o&&(0,de.jsx)(Ce.Flex,{justify:"flex-end",className:"font-library__footer",children:(0,de.jsx)(Ce.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:se,isBusy:x,disabled:l.length===0||x,accessibleWhenDisabled:!0,children:(0,rt.__)("Install")})}),!o&&(0,de.jsxs)(Ce.__experimentalHStack,{expanded:!1,className:"font-library__footer",justify:"end",spacing:6,children:[(0,de.jsx)(Ce.__experimentalHStack,{justify:"flex-start",expanded:!1,spacing:1,className:"font-library__page-selection",children:(0,yt.createInterpolateElement)((0,rt.sprintf)((0,rt._x)("
    Page
    %1$s
    of %2$d
    ","paging"),"",S),{div:(0,de.jsx)("div",{"aria-hidden":!0}),CurrentPage:(0,de.jsx)(Ce.SelectControl,{"aria-label":(0,rt.__)("Current page"),value:m.toString(),options:[...Array(S)].map(($,_e)=>({label:(_e+1).toString(),value:(_e+1).toString()})),onChange:$=>d(parseInt($)),size:"small",variant:"minimal"})})}),(0,de.jsxs)(Ce.__experimentalHStack,{expanded:!1,spacing:1,children:[(0,de.jsx)(Ce.Button,{onClick:()=>d(m-1),disabled:m===1,accessibleWhenDisabled:!0,label:(0,rt.__)("Previous page"),icon:(0,rt.isRTL)()?Os:Fs,showTooltip:!0,size:"compact",tooltipPosition:"top"}),(0,de.jsx)(Ce.Button,{onClick:()=>d(m+1),disabled:m===S,accessibleWhenDisabled:!0,label:(0,rt.__)("Next page"),icon:(0,rt.isRTL)()?Fs:Os,showTooltip:!0,size:"compact",tooltipPosition:"top"})]})]})]})]})}var sa=kS;var Vn=f(ge(),1),Ot=f(ue(),1),_i=f(Te(),1);var aa=(e=>typeof Wt<"u"?Wt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof Wt<"u"?Wt:t)[r]}):e)(function(e){if(typeof Wt<"u")return Wt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),by=(function(){var e,t,r;return(function(){function o(n,i,s){function a(c,m){if(!i[c]){if(!n[c]){var d=typeof aa=="function"&&aa;if(!m&&d)return d(c,!0);if(u)return u(c,!0);var h=new Error("Cannot find module '"+c+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[c]={exports:{}};n[c][0].call(g.exports,function(b){var w=n[c][1][b];return a(w||b)},g,g.exports,o,n,i,s)}return i[c].exports}for(var u=typeof aa=="function"&&aa,l=0;l0},c.prototype.readMoreInput=function(){if(!(this.bit_end_pos_>256))if(this.eos_){if(this.bit_pos_>this.bit_end_pos_)throw new Error("Unexpected end of input "+this.bit_pos_+" "+this.bit_end_pos_)}else{var m=this.buf_ptr_,d=this.input_.read(this.buf_,m,s);if(d<0)throw new Error("Unexpected end of input");if(d=8;)this.val_>>>=8,this.val_|=this.buf_[this.pos_&u]<<24,++this.pos_,this.bit_pos_=this.bit_pos_-8>>>0,this.bit_end_pos_=this.bit_end_pos_-8>>>0},c.prototype.readBits=function(m){32-this.bit_pos_>>this.bit_pos_&l[m];return this.bit_pos_+=m,d},n.exports=c},{}],2:[function(o,n,i){var s=0,a=1,u=2,l=3;i.lookup=new Uint8Array([0,0,0,0,0,0,0,0,0,4,4,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,12,16,12,12,20,12,16,24,28,12,12,32,12,36,12,44,44,44,44,44,44,44,44,44,44,32,32,24,40,28,12,12,48,52,52,52,48,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,24,12,28,12,12,12,56,60,60,60,56,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,24,12,28,12,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,56,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,10,10,10,10,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,22,22,22,22,23,23,23,23,24,24,24,24,25,25,25,25,26,26,26,26,27,27,27,27,28,28,28,28,29,29,29,29,30,30,30,30,31,31,31,31,32,32,32,32,33,33,33,33,34,34,34,34,35,35,35,35,36,36,36,36,37,37,37,37,38,38,38,38,39,39,39,39,40,40,40,40,41,41,41,41,42,42,42,42,43,43,43,43,44,44,44,44,45,45,45,45,46,46,46,46,47,47,47,47,48,48,48,48,49,49,49,49,50,50,50,50,51,51,51,51,52,52,52,52,53,53,53,53,54,54,54,54,55,55,55,55,56,56,56,56,57,57,57,57,58,58,58,58,59,59,59,59,60,60,60,60,61,61,61,61,62,62,62,62,63,63,63,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),i.lookupOffsets=new Uint16Array([1024,1536,1280,1536,0,256,768,512])},{}],3:[function(o,n,i){var s=o("./streams").BrotliInput,a=o("./streams").BrotliOutput,u=o("./bit_reader"),l=o("./dictionary"),c=o("./huffman").HuffmanCode,m=o("./huffman").BrotliBuildHuffmanTable,d=o("./context"),h=o("./prefix"),g=o("./transform"),b=8,w=16,C=256,x=704,v=26,_=6,k=2,E=8,T=255,O=1080,I=18,J=new Uint8Array([1,2,3,4,0,5,17,6,16,7,8,9,10,11,12,13,14,15]),D=16,S=new Uint8Array([3,2,1,0,3,3,3,3,3,3,2,2,2,2,2,2]),L=new Int8Array([0,0,0,0,-1,1,-2,2,-3,3,-1,1,-2,2,-3,3]),Y=new Uint16Array([256,402,436,468,500,534,566,598,630,662,694,726,758,790,822,854,886,920,952,984,1016,1048,1080]);function A(X){var M;return X.readBits(1)===0?16:(M=X.readBits(3),M>0?17+M:(M=X.readBits(3),M>0?8+M:17))}function N(X){if(X.readBits(1)){var M=X.readBits(3);return M===0?1:X.readBits(M)+(1<1&&pe===0)throw new Error("Invalid size byte");M.meta_block_length|=pe<4&&le===0)throw new Error("Invalid size nibble");M.meta_block_length|=le<>>K.bit_pos_&T,Q=X[M].bits-E,Q>0&&(K.bit_pos_+=E,M+=X[M].value,M+=K.val_>>>K.bit_pos_&(1<0;){var te=0,Ne;if(H.readMoreInput(),H.fillBitWindow(),te+=H.val_>>>H.bit_pos_&31,H.bit_pos_+=he[te].bits,Ne=he[te].value&255,Ne>Ne);else{var He=Ne-14,ot,Ze,Be=0;if(Ne===w&&(Be=pe),fe!==Be&&(le=0,fe=Be),ot=le,le>0&&(le-=2,le<<=He),le+=H.readBits(He)+3,Ze=le-ot,Q+Ze>M)throw new Error("[ReadHuffmanCodeLengths] symbol + repeat_delta > num_symbols");for(var Ue=0;Ue0;++fe){var Be=J[fe],Ue=0,ct;H.fillBitWindow(),Ue+=H.val_>>>H.bit_pos_&15,H.bit_pos_+=Ze[Ue].bits,ct=Ze[Ue].value,Ne[Be]=ct,ct!==0&&(He-=32>>ct,++ot)}if(!(ot===1||He===0))throw new Error("[ReadHuffmanCode] invalid num_codes or space");B(Ne,X,le,H)}if(Q=m(M,K,E,le,X),Q===0)throw new Error("[ReadHuffmanCode] BuildHuffmanTable failed: ");return Q}function P(X,M,K){var H,Q;return H=R(X,M,K),Q=h.kBlockLengthPrefixCode[H].nbits,h.kBlockLengthPrefixCode[H].offset+K.readBits(Q)}function W(X,M,K){var H;return X>>5]),this.htrees=new Uint32Array(M)}se.prototype.decode=function(X){var M,K,H=0;for(M=0;M=X)throw new Error("[DecodeContextMap] i >= context_map_size");me[le]=0,++le}else me[le]=he-Q,++le}return M.readBits(1)&&xe(me,X),K}function ye(X,M,K,H,Q,pe,le){var fe=K*2,me=K,he=R(M,K*O,le),V;he===0?V=Q[fe+(pe[me]&1)]:he===1?V=Q[fe+(pe[me]-1&1)]+1:V=he-2,V>=X&&(V-=X),H[K]=V,Q[fe+(pe[me]&1)]=V,++pe[me]}function $(X,M,K,H,Q,pe){var le=Q+1,fe=K&Q,me=pe.pos_&u.IBUF_MASK,he;if(M<8||pe.bit_pos_+(M<<3)0;)pe.readMoreInput(),H[fe++]=pe.readBits(8),fe===le&&(X.write(H,le),fe=0);return}if(pe.bit_end_pos_<32)throw new Error("[CopyUncompressedBlockToOutput] br.bit_end_pos_ < 32");for(;pe.bit_pos_<32;)H[fe]=pe.val_>>>pe.bit_pos_,pe.bit_pos_+=8,++fe,--M;if(he=pe.bit_end_pos_-pe.bit_pos_>>3,me+he>u.IBUF_MASK){for(var V=u.IBUF_MASK+1-me,te=0;te=le){X.write(H,le),fe-=le;for(var te=0;te=le;){if(he=le-fe,pe.input_.read(H,fe,he)M.buffer.length){var Fo=new Uint8Array(H+Ye);Fo.set(M.buffer),M.buffer=Fo}if(Q=wr.input_end,Yr=wr.is_uncompressed,wr.is_metadata){for(_e(Se);Ye>0;--Ye)Se.readMoreInput(),Se.readBits(8);continue}if(Ye!==0){if(Yr){Se.bit_pos_=Se.bit_pos_+7&-8,$(M,Ye,H,V,he,Se),H+=Ye;continue}for(K=0;K<3;++K)vt[K]=N(Se)+1,vt[K]>=2&&(re(vt[K]+2,Ue,K*O,Se),re(v,ct,K*O,Se),St[K]=P(ct,K*O,Se),G[K]=1);for(Se.readMoreInput(),y=Se.readBits(2),oe=D+(Se.readBits(4)<0;){var ft,At,Ht,en,Ta,Ut,er,qr,Hn,tn,Un;for(Se.readMoreInput(),St[1]===0&&(ye(vt[1],Ue,1,kt,F,G,Se),St[1]=P(ct,O,Se),pt=Be[1].htrees[kt[1]]),--St[1],ft=R(Be[1].codes,pt,Se),At=ft>>6,At>=2?(At-=2,er=-1):er=0,Ht=h.kInsertRangeLut[At]+(ft>>3&7),en=h.kCopyRangeLut[At]+(ft&7),Ta=h.kInsertLengthPrefixCode[Ht].offset+Se.readBits(h.kInsertLengthPrefixCode[Ht].nbits),Ut=h.kCopyLengthPrefixCode[en].offset+Se.readBits(h.kCopyLengthPrefixCode[en].nbits),ot=V[H-1&he],Ze=V[H-2&he],tn=0;tn4?3:Ut-2)&255,et=j[Or+Hn],er=R(Be[2].codes,Be[2].htrees[et],Se),er>=oe){var Pa,Vu,Wn;er-=oe,Vu=er&Ae,er>>=y,Pa=(er>>1)+1,Wn=(2+(er&1)<fe)if(Ut>=l.minDictionaryWordLength&&Ut<=l.maxDictionaryWordLength){var Wn=l.offsetsByLength[Ut],Du=qr-fe-1,Bu=l.sizeBitsByLength[Ut],zv=(1<>Bu;if(Wn+=Hv*Ut,ju=te){M.write(V,me);for(var Fi=0;Fi0&&(Ne[He&3]=qr,++He),Ut>Ye)throw new Error("Invalid backward reference. pos: "+H+" distance: "+qr+" len: "+Ut+" bytes left: "+Ye);for(tn=0;tn>=1;return(m&h-1)+h}function l(m,d,h,g,b){do g-=h,m[d+g]=new s(b.bits,b.value);while(g>0)}function c(m,d,h){for(var g=1<0;--S[x])C=new s(x&255,D[v++]&65535),l(m,d+_,k,I,C),_=u(_,x);for(T=J-1,E=-1,x=h+1,k=2;x<=a;++x,k<<=1)for(;S[x]>0;--S[x])(_&T)!==E&&(d+=I,O=c(S,x,h),I=1<>h),k,I,C),_=u(_,x);return J}},{}],8:[function(o,n,i){"use strict";i.byteLength=h,i.toByteArray=b,i.fromByteArray=x;for(var s=[],a=[],u=typeof Uint8Array<"u"?Uint8Array:Array,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=0,m=l.length;c0)throw new Error("Invalid string. Length must be a multiple of 4");var k=v.indexOf("=");k===-1&&(k=_);var E=k===_?0:4-k%4;return[k,E]}function h(v){var _=d(v),k=_[0],E=_[1];return(k+E)*3/4-E}function g(v,_,k){return(_+k)*3/4-k}function b(v){for(var _,k=d(v),E=k[0],T=k[1],O=new u(g(v,E,T)),I=0,J=T>0?E-4:E,D=0;D>16&255,O[I++]=_>>8&255,O[I++]=_&255;return T===2&&(_=a[v.charCodeAt(D)]<<2|a[v.charCodeAt(D+1)]>>4,O[I++]=_&255),T===1&&(_=a[v.charCodeAt(D)]<<10|a[v.charCodeAt(D+1)]<<4|a[v.charCodeAt(D+2)]>>2,O[I++]=_>>8&255,O[I++]=_&255),O}function w(v){return s[v>>18&63]+s[v>>12&63]+s[v>>6&63]+s[v&63]}function C(v,_,k){for(var E,T=[],O=_;OJ?J:I+O));return E===1?(_=v[k-1],T.push(s[_>>2]+s[_<<4&63]+"==")):E===2&&(_=(v[k-2]<<8)+v[k-1],T.push(s[_>>10]+s[_>>4&63]+s[_<<2&63]+"=")),T.join("")}},{}],9:[function(o,n,i){function s(a,u){this.offset=a,this.nbits=u}i.kBlockLengthPrefixCode=[new s(1,2),new s(5,2),new s(9,2),new s(13,2),new s(17,3),new s(25,3),new s(33,3),new s(41,3),new s(49,4),new s(65,4),new s(81,4),new s(97,4),new s(113,5),new s(145,5),new s(177,5),new s(209,5),new s(241,6),new s(305,6),new s(369,7),new s(497,8),new s(753,9),new s(1265,10),new s(2289,11),new s(4337,12),new s(8433,13),new s(16625,24)],i.kInsertLengthPrefixCode=[new s(0,0),new s(1,0),new s(2,0),new s(3,0),new s(4,0),new s(5,0),new s(6,1),new s(8,1),new s(10,2),new s(14,2),new s(18,3),new s(26,3),new s(34,4),new s(50,4),new s(66,5),new s(98,5),new s(130,6),new s(194,7),new s(322,8),new s(578,9),new s(1090,10),new s(2114,12),new s(6210,14),new s(22594,24)],i.kCopyLengthPrefixCode=[new s(2,0),new s(3,0),new s(4,0),new s(5,0),new s(6,0),new s(7,0),new s(8,0),new s(9,0),new s(10,1),new s(12,1),new s(14,2),new s(18,2),new s(22,3),new s(30,3),new s(38,4),new s(54,4),new s(70,5),new s(102,5),new s(134,6),new s(198,7),new s(326,8),new s(582,9),new s(1094,10),new s(2118,24)],i.kInsertRangeLut=[0,0,8,8,0,16,8,16,16],i.kCopyRangeLut=[0,8,0,8,16,0,16,8,16]},{}],10:[function(o,n,i){function s(u){this.buffer=u,this.pos=0}s.prototype.read=function(u,l,c){this.pos+c>this.buffer.length&&(c=this.buffer.length-this.pos);for(var m=0;mthis.buffer.length)throw new Error("Output buffer is not large enough");return this.buffer.set(u.subarray(0,l),this.pos),this.pos+=l,l},i.BrotliOutput=a},{}],11:[function(o,n,i){var s=o("./dictionary"),a=0,u=1,l=2,c=3,m=4,d=5,h=6,g=7,b=8,w=9,C=10,x=11,v=12,_=13,k=14,E=15,T=16,O=17,I=18,J=19,D=20;function S(A,N,q){this.prefix=new Uint8Array(A.length),this.transform=N,this.suffix=new Uint8Array(q.length);for(var U=0;U'),new S("",a,` +`),new S("",c,""),new S("",a,"]"),new S("",a," for "),new S("",k,""),new S("",l,""),new S("",a," a "),new S("",a," that "),new S(" ",C,""),new S("",a,". "),new S(".",a,""),new S(" ",a,", "),new S("",E,""),new S("",a," with "),new S("",a,"'"),new S("",a," from "),new S("",a," by "),new S("",T,""),new S("",O,""),new S(" the ",a,""),new S("",m,""),new S("",a,". The "),new S("",x,""),new S("",a," on "),new S("",a," as "),new S("",a," is "),new S("",g,""),new S("",u,"ing "),new S("",a,` + `),new S("",a,":"),new S(" ",a,". "),new S("",a,"ed "),new S("",D,""),new S("",I,""),new S("",h,""),new S("",a,"("),new S("",C,", "),new S("",b,""),new S("",a," at "),new S("",a,"ly "),new S(" the ",a," of "),new S("",d,""),new S("",w,""),new S(" ",C,", "),new S("",C,'"'),new S(".",a,"("),new S("",x," "),new S("",C,'">'),new S("",a,'="'),new S(" ",a,"."),new S(".com/",a,""),new S(" the ",a," of the "),new S("",C,"'"),new S("",a,". This "),new S("",a,","),new S(".",a," "),new S("",C,"("),new S("",C,"."),new S("",a," not "),new S(" ",a,'="'),new S("",a,"er "),new S(" ",x," "),new S("",a,"al "),new S(" ",x,""),new S("",a,"='"),new S("",x,'"'),new S("",C,". "),new S(" ",a,"("),new S("",a,"ful "),new S(" ",C,". "),new S("",a,"ive "),new S("",a,"less "),new S("",x,"'"),new S("",a,"est "),new S(" ",C,"."),new S("",x,'">'),new S(" ",a,"='"),new S("",C,","),new S("",a,"ize "),new S("",x,"."),new S("\xC2\xA0",a,""),new S(" ",a,","),new S("",C,'="'),new S("",x,'="'),new S("",a,"ous "),new S("",x,", "),new S("",C,"='"),new S(" ",C,","),new S(" ",x,'="'),new S(" ",x,", "),new S("",x,","),new S("",x,"("),new S("",x,". "),new S(" ",x,"."),new S("",x,"='"),new S(" ",x,". "),new S(" ",C,'="'),new S(" ",x,"='"),new S(" ",C,"='")];i.kTransforms=L,i.kNumTransforms=L.length;function Y(A,N){return A[N]<192?(A[N]>=97&&A[N]<=122&&(A[N]^=32),1):A[N]<224?(A[N+1]^=32,2):(A[N+2]^=5,3)}i.transformDictionaryWord=function(A,N,q,U,R){var B=L[R].prefix,re=L[R].suffix,P=L[R].transform,W=PU&&(W=U);for(var be=0;be0;){var ye=Y(A,se);se+=ye,U-=ye}for(var $=0;$typeof Wt<"u"?Wt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof Wt<"u"?Wt:t)[r]}):e)(function(e){if(typeof Wt<"u")return Wt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),wy=(function(){var e,t,r;return(function(){function o(n,i,s){function a(c,m){if(!i[c]){if(!n[c]){var d=typeof la=="function"&&la;if(!m&&d)return d(c,!0);if(u)return u(c,!0);var h=new Error("Cannot find module '"+c+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[c]={exports:{}};n[c][0].call(g.exports,function(b){var w=n[c][1][b];return a(w||b)},g,g.exports,o,n,i,s)}return i[c].exports}for(var u=typeof la=="function"&&la,l=0;l=252?6:c>=248?5:c>=240?4:c>=224?3:c>=192?2:1;l[254]=l[254]=1,i.string2buf=function(d){var h,g,b,w,C,x=d.length,v=0;for(w=0;w>>6,h[C++]=128|g&63):g<65536?(h[C++]=224|g>>>12,h[C++]=128|g>>>6&63,h[C++]=128|g&63):(h[C++]=240|g>>>18,h[C++]=128|g>>>12&63,h[C++]=128|g>>>6&63,h[C++]=128|g&63);return h};function m(d,h){if(h<65534&&(d.subarray&&u||!d.subarray&&a))return String.fromCharCode.apply(null,s.shrinkBuf(d,h));for(var g="",b=0;b4){v[b++]=65533,g+=C-1;continue}for(w&=C===2?31:C===3?15:7;C>1&&g1){v[b++]=65533;continue}w<65536?v[b++]=w:(w-=65536,v[b++]=55296|w>>10&1023,v[b++]=56320|w&1023)}return m(v,b)},i.utf8border=function(d,h){var g;for(h=h||d.length,h>d.length&&(h=d.length),g=h-1;g>=0&&(d[g]&192)===128;)g--;return g<0||g===0?h:g+l[d[g]]>h?g:h}},{"./common":1}],3:[function(o,n,i){"use strict";function s(a,u,l,c){for(var m=a&65535|0,d=a>>>16&65535|0,h=0;l!==0;){h=l>2e3?2e3:l,l-=h;do m=m+u[c++]|0,d=d+m|0;while(--h);m%=65521,d%=65521}return m|d<<16|0}n.exports=s},{}],4:[function(o,n,i){"use strict";n.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],5:[function(o,n,i){"use strict";function s(){for(var l,c=[],m=0;m<256;m++){l=m;for(var d=0;d<8;d++)l=l&1?3988292384^l>>>1:l>>>1;c[m]=l}return c}var a=s();function u(l,c,m,d){var h=a,g=d+m;l^=-1;for(var b=d;b>>8^h[(l^c[b])&255];return l^-1}n.exports=u},{}],6:[function(o,n,i){"use strict";function s(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}n.exports=s},{}],7:[function(o,n,i){"use strict";var s=30,a=12;n.exports=function(l,c){var m,d,h,g,b,w,C,x,v,_,k,E,T,O,I,J,D,S,L,Y,A,N,q,U,R;m=l.state,d=l.next_in,U=l.input,h=d+(l.avail_in-5),g=l.next_out,R=l.output,b=g-(c-l.avail_out),w=g+(l.avail_out-257),C=m.dmax,x=m.wsize,v=m.whave,_=m.wnext,k=m.window,E=m.hold,T=m.bits,O=m.lencode,I=m.distcode,J=(1<>>24,E>>>=L,T-=L,L=S>>>16&255,L===0)R[g++]=S&65535;else if(L&16){Y=S&65535,L&=15,L&&(T>>=L,T-=L),T<15&&(E+=U[d++]<>>24,E>>>=L,T-=L,L=S>>>16&255,L&16){if(A=S&65535,L&=15,TC){l.msg="invalid distance too far back",m.mode=s;break e}if(E>>>=L,T-=L,L=g-b,A>L){if(L=A-L,L>v&&m.sane){l.msg="invalid distance too far back",m.mode=s;break e}if(N=0,q=k,_===0){if(N+=x-L,L2;)R[g++]=q[N++],R[g++]=q[N++],R[g++]=q[N++],Y-=3;Y&&(R[g++]=q[N++],Y>1&&(R[g++]=q[N++]))}else{N=g-A;do R[g++]=R[N++],R[g++]=R[N++],R[g++]=R[N++],Y-=3;while(Y>2);Y&&(R[g++]=R[N++],Y>1&&(R[g++]=R[N++]))}}else if((L&64)===0){S=I[(S&65535)+(E&(1<>3,d-=Y,T-=Y<<3,E&=(1<>>24&255)+(F>>>8&65280)+((F&65280)<<8)+((F&255)<<24)}function Ne(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new s.Buf16(320),this.work=new s.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function He(F){var G;return!F||!F.state?_:(G=F.state,F.total_in=F.total_out=G.total=0,F.msg="",G.wrap&&(F.adler=G.wrap&1),G.mode=I,G.last=0,G.havedict=0,G.dmax=32768,G.head=null,G.hold=0,G.bits=0,G.lencode=G.lendyn=new s.Buf32(fe),G.distcode=G.distdyn=new s.Buf32(me),G.sane=1,G.back=-1,C)}function ot(F){var G;return!F||!F.state?_:(G=F.state,G.wsize=0,G.whave=0,G.wnext=0,He(F))}function Ze(F,G){var y,oe;return!F||!F.state||(oe=F.state,G<0?(y=0,G=-G):(y=(G>>4)+1,G<48&&(G&=15)),G&&(G<8||G>15))?_:(oe.window!==null&&oe.wbits!==G&&(oe.window=null),oe.wrap=y,oe.wbits=G,ot(F))}function Be(F,G){var y,oe;return F?(oe=new Ne,F.state=oe,oe.window=null,y=Ze(F,G),y!==C&&(F.state=null),y):_}function Ue(F){return Be(F,V)}var ct=!0,Se,Pr;function $t(F){if(ct){var G;for(Se=new s.Buf32(512),Pr=new s.Buf32(32),G=0;G<144;)F.lens[G++]=8;for(;G<256;)F.lens[G++]=9;for(;G<280;)F.lens[G++]=7;for(;G<288;)F.lens[G++]=8;for(c(d,F.lens,0,288,Se,0,F.work,{bits:9}),G=0;G<32;)F.lens[G++]=5;c(h,F.lens,0,32,Pr,0,F.work,{bits:5}),ct=!1}F.lencode=Se,F.lenbits=9,F.distcode=Pr,F.distbits=5}function Ye(F,G,y,oe){var Ae,ee=F.state;return ee.window===null&&(ee.wsize=1<=ee.wsize?(s.arraySet(ee.window,G,y-ee.wsize,ee.wsize,0),ee.wnext=0,ee.whave=ee.wsize):(Ae=ee.wsize-ee.wnext,Ae>oe&&(Ae=oe),s.arraySet(ee.window,G,y-oe,Ae,ee.wnext),oe-=Ae,oe?(s.arraySet(ee.window,G,y-oe,oe,0),ee.wnext=oe,ee.whave=ee.wsize):(ee.wnext+=Ae,ee.wnext===ee.wsize&&(ee.wnext=0),ee.whave>>8&255,y.check=u(y.check,ft,2,0),j=0,z=0,y.mode=J;break}if(y.flags=0,y.head&&(y.head.done=!1),!(y.wrap&1)||(((j&255)<<8)+(j>>8))%31){F.msg="incorrect header check",y.mode=Q;break}if((j&15)!==O){F.msg="unknown compression method",y.mode=Q;break}if(j>>>=4,z-=4,at=(j&15)+8,y.wbits===0)y.wbits=at;else if(at>y.wbits){F.msg="invalid window size",y.mode=Q;break}y.dmax=1<>8&1),y.flags&512&&(ft[0]=j&255,ft[1]=j>>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0,y.mode=D;case D:for(;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>8&255,ft[2]=j>>>16&255,ft[3]=j>>>24&255,y.check=u(y.check,ft,4,0)),j=0,z=0,y.mode=S;case S:for(;z<16;){if(ie===0)break e;ie--,j+=oe[ee++]<>8),y.flags&512&&(ft[0]=j&255,ft[1]=j>>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0,y.mode=L;case L:if(y.flags&1024){for(;z<16;){if(ie===0)break e;ie--,j+=oe[ee++]<>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0}else y.head&&(y.head.extra=null);y.mode=Y;case Y:if(y.flags&1024&&(ce=y.length,ce>ie&&(ce=ie),ce&&(y.head&&(at=y.head.extra_len-y.length,y.head.extra||(y.head.extra=new Array(y.head.extra_len)),s.arraySet(y.head.extra,oe,ee,ce,at)),y.flags&512&&(y.check=u(y.check,oe,ce,ee)),ie-=ce,ee+=ce,y.length-=ce),y.length))break e;y.length=0,y.mode=A;case A:if(y.flags&2048){if(ie===0)break e;ce=0;do at=oe[ee+ce++],y.head&&at&&y.length<65536&&(y.head.name+=String.fromCharCode(at));while(at&&ce>9&1,y.head.done=!0),F.adler=y.check=0,y.mode=B;break;case U:for(;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=z&7,z-=z&7,y.mode=M;break}for(;z<3;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=1,z-=1,j&3){case 0:y.mode=P;break;case 1:if($t(y),y.mode=ye,G===w){j>>>=2,z-=2;break e}break;case 2:y.mode=xe;break;case 3:F.msg="invalid block type",y.mode=Q}j>>>=2,z-=2;break;case P:for(j>>>=z&7,z-=z&7;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>16^65535)){F.msg="invalid stored block lengths",y.mode=Q;break}if(y.length=j&65535,j=0,z=0,y.mode=W,G===w)break e;case W:y.mode=ne;case ne:if(ce=y.length,ce){if(ce>ie&&(ce=ie),ce>Je&&(ce=Je),ce===0)break e;s.arraySet(Ae,oe,ee,ce,Qe),ie-=ce,ee+=ce,Je-=ce,Qe+=ce,y.length-=ce;break}y.mode=B;break;case xe:for(;z<14;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=5,z-=5,y.ndist=(j&31)+1,j>>>=5,z-=5,y.ncode=(j&15)+4,j>>>=4,z-=4,y.nlen>286||y.ndist>30){F.msg="too many length or distance symbols",y.mode=Q;break}y.have=0,y.mode=se;case se:for(;y.have>>=3,z-=3}for(;y.have<19;)y.lens[en[y.have++]]=0;if(y.lencode=y.lendyn,y.lenbits=7,At={bits:y.lenbits},Ft=c(m,y.lens,0,19,y.lencode,0,y.work,At),y.lenbits=At.bits,Ft){F.msg="invalid code lengths set",y.mode=Q;break}y.have=0,y.mode=be;case be:for(;y.have>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=Me,z-=Me,y.lens[y.have++]=ut;else{if(ut===16){for(Ht=Me+2;z>>=Me,z-=Me,y.have===0){F.msg="invalid bit length repeat",y.mode=Q;break}at=y.lens[y.have-1],ce=3+(j&3),j>>>=2,z-=2}else if(ut===17){for(Ht=Me+3;z>>=Me,z-=Me,at=0,ce=3+(j&7),j>>>=3,z-=3}else{for(Ht=Me+7;z>>=Me,z-=Me,at=0,ce=11+(j&127),j>>>=7,z-=7}if(y.have+ce>y.nlen+y.ndist){F.msg="invalid bit length repeat",y.mode=Q;break}for(;ce--;)y.lens[y.have++]=at}}if(y.mode===Q)break;if(y.lens[256]===0){F.msg="invalid code -- missing end-of-block",y.mode=Q;break}if(y.lenbits=9,At={bits:y.lenbits},Ft=c(d,y.lens,0,y.nlen,y.lencode,0,y.work,At),y.lenbits=At.bits,Ft){F.msg="invalid literal/lengths set",y.mode=Q;break}if(y.distbits=6,y.distcode=y.distdyn,At={bits:y.distbits},Ft=c(h,y.lens,y.nlen,y.ndist,y.distcode,0,y.work,At),y.distbits=At.bits,Ft){F.msg="invalid distances set",y.mode=Q;break}if(y.mode=ye,G===w)break e;case ye:y.mode=$;case $:if(ie>=6&&Je>=258){F.next_out=Qe,F.avail_out=Je,F.next_in=ee,F.avail_in=ie,y.hold=j,y.bits=z,l(F,je),Qe=F.next_out,Ae=F.output,Je=F.avail_out,ee=F.next_in,oe=F.input,ie=F.avail_in,j=y.hold,z=y.bits,y.mode===B&&(y.back=-1);break}for(y.back=0;et=y.lencode[j&(1<>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>pt)],Me=et>>>24,$e=et>>>16&255,ut=et&65535,!(pt+Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=pt,z-=pt,y.back+=pt}if(j>>>=Me,z-=Me,y.back+=Me,y.length=ut,$e===0){y.mode=X;break}if($e&32){y.back=-1,y.mode=B;break}if($e&64){F.msg="invalid literal/length code",y.mode=Q;break}y.extra=$e&15,y.mode=_e;case _e:if(y.extra){for(Ht=y.extra;z>>=y.extra,z-=y.extra,y.back+=y.extra}y.was=y.length,y.mode=Fe;case Fe:for(;et=y.distcode[j&(1<>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>pt)],Me=et>>>24,$e=et>>>16&255,ut=et&65535,!(pt+Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=pt,z-=pt,y.back+=pt}if(j>>>=Me,z-=Me,y.back+=Me,$e&64){F.msg="invalid distance code",y.mode=Q;break}y.offset=ut,y.extra=$e&15,y.mode=xt;case xt:if(y.extra){for(Ht=y.extra;z>>=y.extra,z-=y.extra,y.back+=y.extra}if(y.offset>y.dmax){F.msg="invalid distance too far back",y.mode=Q;break}y.mode=Le;case Le:if(Je===0)break e;if(ce=je-Je,y.offset>ce){if(ce=y.offset-ce,ce>y.whave&&y.sane){F.msg="invalid distance too far back",y.mode=Q;break}ce>y.wnext?(ce-=y.wnext,br=y.wsize-ce):br=y.wnext-ce,ce>y.length&&(ce=y.length),Or=y.window}else Or=Ae,br=Qe-y.offset,ce=y.length;ce>Je&&(ce=Je),Je-=ce,y.length-=ce;do Ae[Qe++]=Or[br++];while(--ce);y.length===0&&(y.mode=$);break;case X:if(Je===0)break e;Ae[Qe++]=y.length,Je--,y.mode=$;break;case M:if(y.wrap){for(;z<32;){if(ie===0)break e;ie--,j|=oe[ee++]<=1&&$[Y]===0;Y--);if(A>Y&&(A=Y),Y===0)return E[T++]=1<<24|64<<16|0,E[T++]=1<<24|64<<16|0,I.bits=1,0;for(L=1;L0&&(x===c||Y!==1))return-1;for(_e[1]=0,D=1;Du||x===d&&R>l)return 1;for(;;){Le=D-q,O[S]ye?(X=Fe[xt+O[S]],M=se[be+O[S]]):(X=96,M=0),re=1<>q)+P]=Le<<24|X<<16|M|0;while(P!==0);for(re=1<>=1;if(re!==0?(B&=re-1,B+=re):B=0,S++,--$[D]===0){if(D===Y)break;D=v[_+O[S]]}if(D>A&&(B&ne)!==W){for(q===0&&(q=A),xe+=L,N=D-q,U=1<u||x===d&&R>l)return 1;W=B&ne,E[W]=A<<24|N<<16|xe-T|0}}return B!==0&&(E[xe+B]=D-q<<24|64<<16|0),I.bits=A,0}},{"../utils/common":1}],10:[function(o,n,i){"use strict";n.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],11:[function(o,n,i){"use strict";function s(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}n.exports=s},{}],"/lib/inflate.js":[function(o,n,i){"use strict";var s=o("./zlib/inflate"),a=o("./utils/common"),u=o("./utils/strings"),l=o("./zlib/constants"),c=o("./zlib/messages"),m=o("./zlib/zstream"),d=o("./zlib/gzheader"),h=Object.prototype.toString;function g(C){if(!(this instanceof g))return new g(C);this.options=a.assign({chunkSize:16384,windowBits:0,to:""},C||{});var x=this.options;x.raw&&x.windowBits>=0&&x.windowBits<16&&(x.windowBits=-x.windowBits,x.windowBits===0&&(x.windowBits=-15)),x.windowBits>=0&&x.windowBits<16&&!(C&&C.windowBits)&&(x.windowBits+=32),x.windowBits>15&&x.windowBits<48&&(x.windowBits&15)===0&&(x.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new m,this.strm.avail_out=0;var v=s.inflateInit2(this.strm,x.windowBits);if(v!==l.Z_OK)throw new Error(c[v]);if(this.header=new d,s.inflateGetHeader(this.strm,this.header),x.dictionary&&(typeof x.dictionary=="string"?x.dictionary=u.string2buf(x.dictionary):h.call(x.dictionary)==="[object ArrayBuffer]"&&(x.dictionary=new Uint8Array(x.dictionary)),x.raw&&(v=s.inflateSetDictionary(this.strm,x.dictionary),v!==l.Z_OK)))throw new Error(c[v])}g.prototype.push=function(C,x){var v=this.strm,_=this.options.chunkSize,k=this.options.dictionary,E,T,O,I,J,D=!1;if(this.ended)return!1;T=x===~~x?x:x===!0?l.Z_FINISH:l.Z_NO_FLUSH,typeof C=="string"?v.input=u.binstring2buf(C):h.call(C)==="[object ArrayBuffer]"?v.input=new Uint8Array(C):v.input=C,v.next_in=0,v.avail_in=v.input.length;do{if(v.avail_out===0&&(v.output=new a.Buf8(_),v.next_out=0,v.avail_out=_),E=s.inflate(v,l.Z_NO_FLUSH),E===l.Z_NEED_DICT&&k&&(E=s.inflateSetDictionary(this.strm,k)),E===l.Z_BUF_ERROR&&D===!0&&(E=l.Z_OK,D=!1),E!==l.Z_STREAM_END&&E!==l.Z_OK)return this.onEnd(E),this.ended=!0,!1;v.next_out&&(v.avail_out===0||E===l.Z_STREAM_END||v.avail_in===0&&(T===l.Z_FINISH||T===l.Z_SYNC_FLUSH))&&(this.options.to==="string"?(O=u.utf8border(v.output,v.next_out),I=v.next_out-O,J=u.buf2string(v.output,O),v.next_out=I,v.avail_out=_-I,I&&a.arraySet(v.output,v.output,O,I,0),this.onData(J)):this.onData(a.shrinkBuf(v.output,v.next_out))),v.avail_in===0&&v.avail_out===0&&(D=!0)}while((v.avail_in>0||v.avail_out===0)&&E!==l.Z_STREAM_END);return E===l.Z_STREAM_END&&(T=l.Z_FINISH),T===l.Z_FINISH?(E=s.inflateEnd(this.strm),this.onEnd(E),this.ended=!0,E===l.Z_OK):(T===l.Z_SYNC_FLUSH&&(this.onEnd(l.Z_OK),v.avail_out=0),!0)},g.prototype.onData=function(C){this.chunks.push(C)},g.prototype.onEnd=function(C){C===l.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=C,this.msg=this.strm.msg};function b(C,x){var v=new g(x);if(v.push(C,!0),v.err)throw v.msg||c[v.err];return v.result}function w(C,x){return x=x||{},x.raw=!0,b(C,x)}i.Inflate=g,i.inflate=b,i.inflateRaw=w,i.ungzip=b},{"./utils/common":1,"./utils/strings":2,"./zlib/constants":4,"./zlib/gzheader":6,"./zlib/inflate":8,"./zlib/messages":10,"./zlib/zstream":11}]},{},[])("/lib/inflate.js")})();var TM=globalThis.fetch,ca=class{constructor(e,t={},r){this.type=e,this.detail=t,this.msg=r,Object.defineProperty(this,"__mayPropagate",{enumerable:!1,writable:!0}),this.__mayPropagate=!0}preventDefault(){}stopPropagation(){this.__mayPropagate=!1}valueOf(){return this}toString(){return this.msg?`[${this.type} event]: ${this.msg}`:`[${this.type} event]`}},FS=class{constructor(){this.listeners={}}addEventListener(e,t,r){let o=this.listeners[e]||[];r?o.unshift(t):o.push(t),this.listeners[e]=o}removeEventListener(e,t){let r=this.listeners[e]||[],o=r.findIndex(n=>n===t);o>-1&&(r.splice(o,1),this.listeners[e]=r)}dispatch(e){let t=this.listeners[e.type];if(t)for(let r=0,o=t.length;rString.fromCharCode(t)).join("")}var LS=class{constructor(e,t,r){this.name=(r||e.tag||"").trim(),this.length=e.length,this.start=e.offset,this.offset=0,this.data=t,["getInt8","getUint8","getInt16","getUint16","getInt32","getUint32","getBigInt64","getBigUint64"].forEach(o=>{let n=o.replace(/get(Big)?/,"").toLowerCase(),i=parseInt(o.replace(/[^\d]/g,""))/8;Object.defineProperty(this,n,{get:()=>this.getValue(o,i)})})}get currentPosition(){return this.start+this.offset}set currentPosition(e){this.start=e,this.offset=0}skip(e=0,t=8){this.offset+=e*t/8}getValue(e,t){let r=this.start+this.offset;this.offset+=t;try{return this.data[e](r)}catch(o){throw console.error("parser",e,t,this),console.error("parser",this.start,this.offset),o}}flags(e){if(e===8||e===16||e===32||e===64)return this[`uint${e}`].toString(2).padStart(e,0).split("").map(t=>t==="1");console.error("Error parsing flags: flag types can only be 1, 2, 4, or 8 bytes long"),console.trace()}get tag(){let e=this.uint32;return IS([e>>24&255,e>>16&255,e>>8&255,e&255])}get fixed(){let e=this.int16,t=Math.round(1e3*this.uint16/65356);return e+t/1e3}get legacyFixed(){let e=this.uint16,t=this.uint16.toString(16).padStart(4,0);return parseFloat(`${e}.${t}`)}get uint24(){return(this.uint8<<16)+(this.uint8<<8)+this.uint8}get uint128(){let e=0;for(let t=0;t<5;t++){let r=this.uint8;if(e=e*128+(r&127),r<128)break}return e}get longdatetime(){return new Date(AS+1e3*parseInt(this.int64.toString()))}get fword(){return this.int16}get ufword(){return this.uint16}get Offset16(){return this.uint16}get Offset32(){return this.uint32}get F2DOT14(){let e=p.uint16,t=[0,1,-2,-1][e>>14],r=e&16383;return t+r/16384}verifyLength(){this.offset!=this.length&&console.error(`unexpected parsed table size (${this.offset}) for "${this.name}" (expected ${this.length})`)}readBytes(e=0,t=0,r=8,o=!1){if(e=e||this.length,e===0)return[];t&&(this.currentPosition=t);let n=`${o?"":"u"}int${r}`,i=[];for(;e--;)i.push(this[n]);return i}},lt=class{constructor(e){Object.defineProperty(this,"parser",{enumerable:!1,get:()=>e});let r=e.currentPosition;Object.defineProperty(this,"start",{enumerable:!1,get:()=>r})}load(e){Object.keys(e).forEach(t=>{let r=Object.getOwnPropertyDescriptor(e,t);r.get?this[t]=r.get.bind(this):r.value!==void 0&&(this[t]=r.value)}),this.parser.length&&this.parser.verifyLength()}},ke=class extends lt{constructor(e,t,r){let{parser:o,start:n}=super(new LS(e,t,r));Object.defineProperty(this,"p",{enumerable:!1,get:()=>o}),Object.defineProperty(this,"tableStart",{enumerable:!1,get:()=>n})}};function ae(e,t,r){let o;Object.defineProperty(e,t,{get:()=>o||(o=r(),o),enumerable:!0})}var NS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:12},t,"sfnt");this.version=o.uint32,this.numTables=o.uint16,this.searchRange=o.uint16,this.entrySelector=o.uint16,this.rangeShift=o.uint16,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new MS(o)),this.tables={},this.directory.forEach(n=>{let i=()=>r(this.tables,{tag:n.tag,offset:n.offset,length:n.length},t);ae(this.tables,n.tag.trim(),i)})}},MS=class{constructor(e){this.tag=e.tag,this.checksum=e.uint32,this.offset=e.uint32,this.length=e.uint32}},xy=wy.inflate||void 0,Sy=void 0,VS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:44},t,"woff");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new DS(o)),BS(this,t,r)}},DS=class{constructor(e){this.tag=e.tag,this.offset=e.uint32,this.compLength=e.uint32,this.origLength=e.uint32,this.origChecksum=e.uint32}};function BS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=0,i=t;if(o.compLength!==o.origLength){let s=t.buffer.slice(o.offset,o.offset+o.compLength),a;if(xy)a=xy(new Uint8Array(s));else if(Sy)a=Sy(new Uint8Array(s));else{let u="no brotli decoder available to decode WOFF2 font";throw font.onerror&&font.onerror(u),new Error(u)}i=new DataView(a.buffer)}else n=o.offset;return r(e.tables,{tag:o.tag,offset:n,length:o.origLength},i)})})}var Cy=by,_y=void 0,jS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:48},t,"woff2");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.totalCompressedSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(a=>new zS(o));let n=o.currentPosition;this.directory[0].offset=0,this.directory.forEach((a,u)=>{let l=this.directory[u+1];l&&(l.offset=a.offset+(a.transformLength!==void 0?a.transformLength:a.origLength))});let i,s=t.buffer.slice(n);if(Cy)i=Cy(new Uint8Array(s));else if(_y)i=new Uint8Array(_y(s));else{let a="no brotli decoder available to decode WOFF2 font";throw e.onerror&&e.onerror(a),new Error(a)}HS(this,i,r)}},zS=class{constructor(e){this.flags=e.uint8;let t=this.tagNumber=this.flags&63;t===63?this.tag=e.tag:this.tag=US(t);let o=(this.transformVersion=(this.flags&192)>>6)!==0;(this.tag==="glyf"||this.tag==="loca")&&(o=this.transformVersion!==3),this.origLength=e.uint128,o&&(this.transformLength=e.uint128)}};function HS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=o.offset,i=n+(o.transformLength?o.transformLength:o.origLength),s=new DataView(t.slice(n,i).buffer);try{return r(e.tables,{tag:o.tag,offset:0,length:o.origLength},s)}catch(a){console.error(a)}})})}function US(e){return["cmap","head","hhea","hmtx","maxp","name","OS/2","post","cvt ","fpgm","glyf","loca","prep","CFF ","VORG","EBDT","EBLC","gasp","hdmx","kern","LTSH","PCLT","VDMX","vhea","vmtx","BASE","GDEF","GPOS","GSUB","EBSC","JSTF","MATH","CBDT","CBLC","COLR","CPAL","SVG ","sbix","acnt","avar","bdat","bloc","bsln","cvar","fdsc","feat","fmtx","fvar","gvar","hsty","just","lcar","mort","morx","opbd","prop","trak","Zapf","Silf","Glat","Gloc","Feat","Sill"][e&63]}var Fy={},Ay=!1;Promise.all([Promise.resolve().then(function(){return yC}),Promise.resolve().then(function(){return bC}),Promise.resolve().then(function(){return xC}),Promise.resolve().then(function(){return _C}),Promise.resolve().then(function(){return EC}),Promise.resolve().then(function(){return FC}),Promise.resolve().then(function(){return IC}),Promise.resolve().then(function(){return NC}),Promise.resolve().then(function(){return GC}),Promise.resolve().then(function(){return r_}),Promise.resolve().then(function(){return U_}),Promise.resolve().then(function(){return G_}),Promise.resolve().then(function(){return X_}),Promise.resolve().then(function(){return $_}),Promise.resolve().then(function(){return tR}),Promise.resolve().then(function(){return oR}),Promise.resolve().then(function(){return sR}),Promise.resolve().then(function(){return lR}),Promise.resolve().then(function(){return uR}),Promise.resolve().then(function(){return dR}),Promise.resolve().then(function(){return mR}),Promise.resolve().then(function(){return gR}),Promise.resolve().then(function(){return bR}),Promise.resolve().then(function(){return SR}),Promise.resolve().then(function(){return CR}),Promise.resolve().then(function(){return RR}),Promise.resolve().then(function(){return TR}),Promise.resolve().then(function(){return OR}),Promise.resolve().then(function(){return FR}),Promise.resolve().then(function(){return LR}),Promise.resolve().then(function(){return jR}),Promise.resolve().then(function(){return WR}),Promise.resolve().then(function(){return qR}),Promise.resolve().then(function(){return JR}),Promise.resolve().then(function(){return $R}),Promise.resolve().then(function(){return t2}),Promise.resolve().then(function(){return n2}),Promise.resolve().then(function(){return s2}),Promise.resolve().then(function(){return f2}),Promise.resolve().then(function(){return p2}),Promise.resolve().then(function(){return g2})]).then(e=>{e.forEach(t=>{let r=Object.keys(t)[0];Fy[r]=t[r]}),Ay=!0});function WS(e,t,r){let o=t.tag.replace(/[^\w\d]/g,""),n=Fy[o];return n?new n(t,r,e):(console.warn(`lib-font has no definition for ${o}. The table was skipped.`),{})}function GS(){let e=0;function t(r,o){if(!Ay)return e>10?o(new Error("loading took too long")):(e++,setTimeout(()=>t(r),250));r(WS)}return new Promise((r,o)=>t(r))}function YS(e,t){let r=e.lastIndexOf("."),o=(e.substring(r+1)||"").toLowerCase(),n={ttf:"truetype",otf:"opentype",woff:"woff",woff2:"woff2"}[o];if(n)return n;let i={eot:"The .eot format is not supported: it died in January 12, 2016, when Microsoft retired all versions of IE that didn't already support WOFF.",svg:"The .svg format is not supported: SVG fonts (not to be confused with OpenType with embedded SVG) were so bad we took the entire fonts chapter out of the SVG specification again.",fon:"The .fon format is not supported: this is an ancient Windows bitmap font format.",ttc:"Based on the current CSS specification, font collections are not (yet?) supported."}[o];if(i||(i=`${e} is not a known webfont format.`),t)throw new Error(i);console.warn(`Could not load font: ${i}`)}async function qS(e,t,r={}){if(!globalThis.document)return;let o=YS(t,r.errorOnStyle);if(!o)return;let n=document.createElement("style");n.className="injected-by-Font-js";let i=[];return r.styleRules&&(i=Object.entries(r.styleRules).map(([s,a])=>`${s}: ${a};`)),n.textContent=` @font-face { font-family: "${e}"; - ${s.join(` + ${i.join(` `)} src: url("${t}") format("${o}"); -}`,globalThis.document.head.appendChild(n),n}var lS=[0,1,0,0],cS=[79,84,84,79],uS=[119,79,70,70],fS=[119,79,70,50];function na(e,t){if(e.length===t.length){for(let r=0;r(globalThis.document&&!this.options.skipStyleSheet&&await aS(this.name,e,this.options),this.loadFont(e)))()}async loadFont(e,t){fetch(e).then(r=>pS(r)&&r.arrayBuffer()).then(r=>this.fromDataBuffer(r,t||e)).catch(r=>{let o=new oa("error",r,`Failed to load font at ${t||e}`);this.dispatch(o),this.onerror&&this.onerror(o)})}async fromDataBuffer(e,t){this.fontData=new DataView(e);let r=dS(this.fontData);if(!r)throw new Error(`${t} is either an unsupported font format, or not a font at all.`);await this.parseBasicData(r);let o=new oa("load",{font:this});this.dispatch(o),this.onload&&this.onload(o)}async parseBasicData(e){return sS().then(t=>(e==="SFNT"&&(this.opentype=new Xx(this,this.fontData,t)),e==="WOFF"&&(this.opentype=new Jx(this,this.fontData,t)),e==="WOFF2"&&(this.opentype=new eS(this,this.fontData,t)),this.opentype))}getGlyphId(e){return this.opentype.tables.cmap.getGlyphId(e)}reverse(e){return this.opentype.tables.cmap.reverse(e)}supports(e){return this.getGlyphId(e)!==0}supportsVariation(e){return this.opentype.tables.cmap.supportsVariation(e)!==!1}measureText(e,t=16){if(this.__unloaded)throw new Error("Cannot measure text: font was unloaded. Please reload before calling measureText()");let r=document.createElement("div");r.textContent=e,r.style.fontFamily=this.name,r.style.fontSize=`${t}px`,r.style.color="transparent",r.style.background="transparent",r.style.top="0",r.style.left="0",r.style.position="absolute",document.body.appendChild(r);let o=r.getBoundingClientRect();document.body.removeChild(r);let n=this.opentype.tables["OS/2"];return o.fontSize=t,o.ascender=n.sTypoAscender,o.descender=n.sTypoDescender,o}unload(){if(this.styleElement.parentNode){this.styleElement.parentNode.removeElement(this.styleElement);let e=new oa("unload",{font:this});this.dispatch(e),this.onunload&&this.onunload(e)}this._unloaded=!0}load(){if(this.__unloaded){delete this.__unloaded,document.head.appendChild(this.styleElement);let e=new oa("load",{font:this});this.dispatch(e),this.onload&&this.onload(e)}}};globalThis.Font=ia;var $r=class extends ct{constructor(e,t,r){super(e),this.plaformID=t,this.encodingID=r}},mS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=0,this.length=e.uint16,this.language=e.uint16,this.glyphIdArray=[...new Array(256)].map(o=>e.uint8)}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 0. only supports(id) is implemented.")),0<=e&&e<=255}reverse(e){return console.warn("reverse not implemented for cmap subtable format 0"),{}}getSupportedCharCodes(){return[{start:1,end:256}]}},hS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=2,this.length=e.uint16,this.language=e.uint16,this.subHeaderKeys=[...new Array(256)].map(i=>e.uint16);let o=Math.max(...this.subHeaderKeys),n=e.currentPosition;ae(this,"subHeaders",()=>(e.currentPosition=n,[...new Array(o)].map(i=>new gS(e))));let s=n+o*8;ae(this,"glyphIndexArray",()=>(e.currentPosition=s,[...new Array(o)].map(i=>e.uint16)))}supports(e){e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 2. only supports(id) is implemented."));let t=e&&255,r=e&&65280,o=this.subHeaders[r],n=this.subHeaders[o],s=n.firstCode,i=s+n.entryCount;return s<=t&&t<=i}reverse(e){return console.warn("reverse not implemented for cmap subtable format 2"),{}}getSupportedCharCodes(e=!1){return e?this.subHeaders.map(t=>({firstCode:t.firstCode,lastCode:t.lastCode})):this.subHeaders.map(t=>({start:t.firstCode,end:t.lastCode}))}},gS=class{constructor(e){this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.first+this.entryCount,this.idDelta=e.int16,this.idRangeOffset=e.uint16}},yS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=4,this.length=e.uint16,this.language=e.uint16,this.segCountX2=e.uint16,this.segCount=this.segCountX2/2,this.searchRange=e.uint16,this.entrySelector=e.uint16,this.rangeShift=e.uint16;let o=e.currentPosition;ae(this,"endCode",()=>e.readBytes(this.segCount,o,16));let n=o+2+this.segCountX2;ae(this,"startCode",()=>e.readBytes(this.segCount,n,16));let s=n+this.segCountX2;ae(this,"idDelta",()=>e.readBytes(this.segCount,s,16,!0));let i=s+this.segCountX2;ae(this,"idRangeOffset",()=>e.readBytes(this.segCount,i,16));let a=i+this.segCountX2,u=this.length-(a-this.tableStart);ae(this,"glyphIdArray",()=>e.readBytes(u,a,16)),ae(this,"segments",()=>this.buildSegments(i,a,e))}buildSegments(e,t,r){let o=(n,s)=>{let i=this.startCode[s],a=this.endCode[s],u=this.idDelta[s],l=this.idRangeOffset[s],c=e+2*s,f=[];if(l===0)for(let m=i+u,g=a+u;m<=g;m++)f.push(m);else for(let m=0,g=a-i;m<=g;m++)r.currentPosition=c+l+m*2,f.push(r.uint16);return{startCode:i,endCode:a,idDelta:u,idRangeOffset:l,glyphIDs:f}};return[...new Array(this.segCount)].map(o)}reverse(e){let t=this.segments.find(o=>o.glyphIDs.includes(e));if(!t)return{};let r=t.startCode+t.glyphIDs.indexOf(e);return{code:r,unicode:String.fromCodePoint(r)}}getGlyphId(e){if(e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535)return 0;let t=this.segments.find(r=>r.startCode<=e&&e<=r.endCode);return t?t.glyphIDs[e-t.startCode]:0}supports(e){return this.getGlyphId(e)!==0}getSupportedCharCodes(e=!1){return e?this.segments:this.segments.map(t=>({start:t.startCode,end:t.endCode}))}},vS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=6,this.length=e.uint16,this.language=e.uint16,this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.firstCode+this.entryCount-1,ae(this,"glyphIdArray",()=>[...new Array(this.entryCount)].map(n=>e.uint16))}supports(e){if(e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 6. only supports(id) is implemented.")),ethis.firstCode+this.entryCount)return{};let t=e-this.firstCode;return{code:t,unicode:String.fromCodePoint(t)}}reverse(e){let t=this.glyphIdArray.indexOf(e);if(t>-1)return this.firstCode+t}getSupportedCharCodes(e=!1){return e?[{firstCode:this.firstCode,lastCode:this.lastCode}]:[{start:this.firstCode,end:this.lastCode}]}},bS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=8,e.uint16,this.length=e.uint32,this.language=e.uint32,this.is32=[...new Array(8192)].map(n=>e.uint8),this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new wS(e)))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 8. only supports(id) is implemented.")),this.groups.findIndex(t=>t.startcharCode<=e&&e<=t.endcharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 8"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startcharCode,end:t.endcharCode}))}},wS=class{constructor(e){this.startcharCode=e.uint32,this.endcharCode=e.uint32,this.startGlyphID=e.uint32}},xS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=10,e.uint16,this.length=e.uint32,this.language=e.uint32,this.startCharCode=e.uint32,this.numChars=e.uint32,this.endCharCode=this.startCharCode+this.numChars,ae(this,"glyphs",()=>[...new Array(this.numChars)].map(n=>e.uint16))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 10. only supports(id) is implemented.")),ethis.startCharCode+this.numChars?!1:e-this.startCharCode}reverse(e){return console.warn("reverse not implemented for cmap subtable format 10"),{}}getSupportedCharCodes(e=!1){return e?[{startCharCode:this.startCharCode,endCharCode:this.endCharCode}]:[{start:this.startCharCode,end:this.endCharCode}]}},SS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=12,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new CS(e)))}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535?0:this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){for(let t of this.groups){let r=t.startGlyphID;if(r>e)continue;if(r===e)return t.startCharCode;if(r+(t.endCharCode-t.startCharCode)({start:t.startCharCode,end:t.endCharCode}))}},CS=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.startGlyphID=e.uint32}},RS=class extends $r{constructor(e,t,r){super(e,t,r),this.format=13,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32;let o=[...new Array(this.numGroups)].map(n=>new ES(e));ae(this,"groups",o)}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 13"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startCharCode,end:t.endCharCode}))}},ES=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.glyphID=e.uint32}},TS=class extends $r{constructor(e,t,r){super(e,t,r),this.subTableStart=e.currentPosition,this.format=14,this.length=e.uint32,this.numVarSelectorRecords=e.uint32,ae(this,"varSelectors",()=>[...new Array(this.numVarSelectorRecords)].map(o=>new _S(e)))}supports(){return console.warn("supports not implemented for cmap subtable format 14"),0}getSupportedCharCodes(){return console.warn("getSupportedCharCodes not implemented for cmap subtable format 14"),[]}reverse(e){return console.warn("reverse not implemented for cmap subtable format 14"),{}}supportsVariation(e){let t=this.varSelector.find(r=>r.varSelector===e);return t||!1}getSupportedVariations(){return this.varSelectors.map(e=>e.varSelector)}},_S=class{constructor(e){this.varSelector=e.uint24,this.defaultUVSOffset=e.Offset32,this.nonDefaultUVSOffset=e.Offset32}};function PS(e,t,r){let o=e.uint16;return o===0?new mS(e,t,r):o===2?new hS(e,t,r):o===4?new yS(e,t,r):o===6?new vS(e,t,r):o===8?new bS(e,t,r):o===10?new xS(e,t,r):o===12?new SS(e,t,r):o===13?new RS(e,t,r):o===14?new TS(e,t,r):{}}var OS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numTables=r.uint16,this.encodingRecords=[...new Array(this.numTables)].map(o=>new kS(r,this.tableStart))}getSubTable(e){return this.encodingRecords[e].table}getSupportedEncodings(){return this.encodingRecords.map(e=>({platformID:e.platformID,encodingId:e.encodingID}))}getSupportedCharCodes(e,t){let r=this.encodingRecords.findIndex(n=>n.platformID===e&&n.encodingID===t);return r===-1?!1:this.getSubTable(r).getSupportedCharCodes()}reverse(e){for(let t=0;t{let n=this.getSubTable(o);return n.getGlyphId?(t=n.getGlyphId(e),t!==0):!1}),t}supports(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supports&&o.supports(e)!==!1})}supportsVariation(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supportsVariation&&o.supportsVariation(e)!==!1})}},kS=class{constructor(e,t){let r=this.platformID=e.uint16,o=this.encodingID=e.uint16,n=this.offset=e.Offset32;ae(this,"table",()=>(e.currentPosition=t+n,PS(e,r,o)))}},FS=Object.freeze({__proto__:null,cmap:OS}),AS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.load({majorVersion:r.uint16,minorVersion:r.uint16,fontRevision:r.fixed,checkSumAdjustment:r.uint32,magicNumber:r.uint32,flags:r.flags(16),unitsPerEm:r.uint16,created:r.longdatetime,modified:r.longdatetime,xMin:r.int16,yMin:r.int16,xMax:r.int16,yMax:r.int16,macStyle:r.flags(16),lowestRecPPEM:r.uint16,fontDirectionHint:r.uint16,indexToLocFormat:r.uint16,glyphDataFormat:r.uint16})}},IS=Object.freeze({__proto__:null,head:AS}),LS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.ascender=r.fword,this.descender=r.fword,this.lineGap=r.fword,this.advanceWidthMax=r.ufword,this.minLeftSideBearing=r.fword,this.minRightSideBearing=r.fword,this.xMaxExtent=r.fword,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,r.int16,r.int16,r.int16,r.int16,this.metricDataFormat=r.int16,this.numberOfHMetrics=r.uint16,r.verifyLength()}},NS=Object.freeze({__proto__:null,hhea:LS}),DS=class extends Pe{constructor(e,t,r){let{p:o}=super(e,t),n=r.hhea.numberOfHMetrics,s=r.maxp.numGlyphs,i=o.currentPosition;if(ae(this,"hMetrics",()=>(o.currentPosition=i,[...new Array(n)].map(a=>new MS(o.uint16,o.int16)))),n(o.currentPosition=a,[...new Array(s-n)].map(u=>o.int16)))}}},MS=class{constructor(e,t){this.advanceWidth=e,this.lsb=t}},VS=Object.freeze({__proto__:null,hmtx:DS}),BS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.legacyFixed,this.numGlyphs=r.uint16,this.version===1&&(this.maxPoints=r.uint16,this.maxContours=r.uint16,this.maxCompositePoints=r.uint16,this.maxCompositeContours=r.uint16,this.maxZones=r.uint16,this.maxTwilightPoints=r.uint16,this.maxStorage=r.uint16,this.maxFunctionDefs=r.uint16,this.maxInstructionDefs=r.uint16,this.maxStackElements=r.uint16,this.maxSizeOfInstructions=r.uint16,this.maxComponentElements=r.uint16,this.maxComponentDepth=r.uint16),r.verifyLength()}},jS=Object.freeze({__proto__:null,maxp:BS}),zS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.format=r.uint16,this.count=r.uint16,this.stringOffset=r.Offset16,this.nameRecords=[...new Array(this.count)].map(o=>new HS(r,this)),this.format===1&&(this.langTagCount=r.uint16,this.langTagRecords=[...new Array(this.langTagCount)].map(o=>new US(r.uint16,r.Offset16))),this.stringStart=this.tableStart+this.stringOffset}get(e){let t=this.nameRecords.find(r=>r.nameID===e);if(t)return t.string}},US=class{constructor(e,t){this.length=e,this.offset=t}},HS=class{constructor(e,t){this.platformID=e.uint16,this.encodingID=e.uint16,this.languageID=e.uint16,this.nameID=e.uint16,this.length=e.uint16,this.offset=e.Offset16,ae(this,"string",()=>(e.currentPosition=t.stringStart+this.offset,WS(e,this)))}};function WS(e,t){let{platformID:r,length:o}=t;if(o===0)return"";if(r===0||r===3){let i=[];for(let a=0,u=o/2;ar.uint8),this.ulUnicodeRange1=r.flags(32),this.ulUnicodeRange2=r.flags(32),this.ulUnicodeRange3=r.flags(32),this.ulUnicodeRange4=r.flags(32),this.achVendID=r.tag,this.fsSelection=r.uint16,this.usFirstCharIndex=r.uint16,this.usLastCharIndex=r.uint16,this.sTypoAscender=r.int16,this.sTypoDescender=r.int16,this.sTypoLineGap=r.int16,this.usWinAscent=r.uint16,this.usWinDescent=r.uint16,this.version===0||(this.ulCodePageRange1=r.flags(32),this.ulCodePageRange2=r.flags(32),this.version===1)||(this.sxHeight=r.int16,this.sCapHeight=r.int16,this.usDefaultChar=r.uint16,this.usBreakChar=r.uint16,this.usMaxContext=r.uint16,this.version<=4)||(this.usLowerOpticalPointSize=r.uint16,this.usUpperOpticalPointSize=r.uint16,this.version===5))return r.verifyLength()}},qS=Object.freeze({__proto__:null,OS2:YS}),ZS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);if(this.version=r.legacyFixed,this.italicAngle=r.fixed,this.underlinePosition=r.fword,this.underlineThickness=r.fword,this.isFixedPitch=r.uint32,this.minMemType42=r.uint32,this.maxMemType42=r.uint32,this.minMemType1=r.uint32,this.maxMemType1=r.uint32,this.version===1||this.version===3)return r.verifyLength();if(this.numGlyphs=r.uint16,this.version===2){this.glyphNameIndex=[...new Array(this.numGlyphs)].map(o=>r.uint16),this.namesOffset=r.currentPosition,this.glyphNameOffsets=[1];for(let o=0;or.int8))}getGlyphName(e){if(this.version!==2)return console.warn(`post table version ${this.version} does not support glyph name lookups`),"";let t=this.glyphNameIndex[e];if(t<258)return ey[t];let r=this.glyphNameOffsets[e],n=this.glyphNameOffsets[e+1]-r-1;return n===0?".notdef.":(this.parser.currentPosition=this.namesOffset+r,this.parser.readBytes(n,this.namesOffset+r,8,!0).map(i=>String.fromCharCode(i)).join(""))}},ey=[".notdef",".null","nonmarkingreturn","space","exclam","quotedbl","numbersign","dollar","percent","ampersand","quotesingle","parenleft","parenright","asterisk","plus","comma","hyphen","period","slash","zero","one","two","three","four","five","six","seven","eight","nine","colon","semicolon","less","equal","greater","question","at","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","bracketleft","backslash","bracketright","asciicircum","underscore","grave","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","braceleft","bar","braceright","asciitilde","Adieresis","Aring","Ccedilla","Eacute","Ntilde","Odieresis","Udieresis","aacute","agrave","acircumflex","adieresis","atilde","aring","ccedilla","eacute","egrave","ecircumflex","edieresis","iacute","igrave","icircumflex","idieresis","ntilde","oacute","ograve","ocircumflex","odieresis","otilde","uacute","ugrave","ucircumflex","udieresis","dagger","degree","cent","sterling","section","bullet","paragraph","germandbls","registered","copyright","trademark","acute","dieresis","notequal","AE","Oslash","infinity","plusminus","lessequal","greaterequal","yen","mu","partialdiff","summation","product","pi","integral","ordfeminine","ordmasculine","Omega","ae","oslash","questiondown","exclamdown","logicalnot","radical","florin","approxequal","Delta","guillemotleft","guillemotright","ellipsis","nonbreakingspace","Agrave","Atilde","Otilde","OE","oe","endash","emdash","quotedblleft","quotedblright","quoteleft","quoteright","divide","lozenge","ydieresis","Ydieresis","fraction","currency","guilsinglleft","guilsinglright","fi","fl","daggerdbl","periodcentered","quotesinglbase","quotedblbase","perthousand","Acircumflex","Ecircumflex","Aacute","Edieresis","Egrave","Iacute","Icircumflex","Idieresis","Igrave","Oacute","Ocircumflex","apple","Ograve","Uacute","Ucircumflex","Ugrave","dotlessi","circumflex","tilde","macron","breve","dotaccent","ring","cedilla","hungarumlaut","ogonek","caron","Lslash","lslash","Scaron","scaron","Zcaron","zcaron","brokenbar","Eth","eth","Yacute","yacute","Thorn","thorn","minus","multiply","onesuperior","twosuperior","threesuperior","onehalf","onequarter","threequarters","franc","Gbreve","gbreve","Idotaccent","Scedilla","scedilla","Cacute","cacute","Ccaron","ccaron","dcroat"],XS=Object.freeze({__proto__:null,post:ZS}),KS=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.horizAxisOffset=r.Offset16,this.vertAxisOffset=r.Offset16,ae(this,"horizAxis",()=>new Yc({offset:e.offset+this.horizAxisOffset},t)),ae(this,"vertAxis",()=>new Yc({offset:e.offset+this.vertAxisOffset},t)),this.majorVersion===1&&this.minorVersion===1&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>new Yc({offset:e.offset+this.itemVarStoreOffset},t)))}},Yc=class extends Pe{constructor(e,t){let{p:r}=super(e,t,"AxisTable");this.baseTagListOffset=r.Offset16,this.baseScriptListOffset=r.Offset16,ae(this,"baseTagList",()=>new JS({offset:e.offset+this.baseTagListOffset},t)),ae(this,"baseScriptList",()=>new QS({offset:e.offset+this.baseScriptListOffset},t))}},JS=class extends Pe{constructor(e,t){let{p:r}=super(e,t,"BaseTagListTable");this.baseTagCount=r.uint16,this.baselineTags=[...new Array(this.baseTagCount)].map(o=>r.tag)}},QS=class extends Pe{constructor(e,t){let{p:r}=super(e,t,"BaseScriptListTable");this.baseScriptCount=r.uint16;let o=r.currentPosition;ae(this,"baseScriptRecords",()=>(r.currentPosition=o,[...new Array(this.baseScriptCount)].map(n=>new $S(this.start,r))))}},$S=class{constructor(e,t){this.baseScriptTag=t.tag,this.baseScriptOffset=t.Offset16,ae(this,"baseScriptTable",()=>(t.currentPosition=e+this.baseScriptOffset,new eC(t)))}},eC=class{constructor(e){this.start=e.currentPosition,this.baseValuesOffset=e.Offset16,this.defaultMinMaxOffset=e.Offset16,this.baseLangSysCount=e.uint16,this.baseLangSysRecords=[...new Array(this.baseLangSysCount)].map(t=>new tC(this.start,e)),ae(this,"baseValues",()=>(e.currentPosition=this.start+this.baseValuesOffset,new rC(e))),ae(this,"defaultMinMax",()=>(e.currentPosition=this.start+this.defaultMinMaxOffset,new ly(e)))}},tC=class{constructor(e,t){this.baseLangSysTag=t.tag,this.minMaxOffset=t.Offset16,ae(this,"minMax",()=>(t.currentPosition=e+this.minMaxOffset,new ly(t)))}},rC=class{constructor(e){this.parser=e,this.start=e.currentPosition,this.defaultBaselineIndex=e.uint16,this.baseCoordCount=e.uint16,this.baseCoords=[...new Array(this.baseCoordCount)].map(t=>e.Offset16)}getTable(e){return this.parser.currentPosition=this.start+this.baseCoords[e],new nC(this.parser)}},ly=class{constructor(e){this.minCoord=e.Offset16,this.maxCoord=e.Offset16,this.featMinMaxCount=e.uint16;let t=e.currentPosition;ae(this,"featMinMaxRecords",()=>(e.currentPosition=t,[...new Array(this.featMinMaxCount)].map(r=>new oC(e))))}},oC=class{constructor(e){this.featureTableTag=e.tag,this.minCoord=e.Offset16,this.maxCoord=e.Offset16}},nC=class{constructor(e){this.baseCoordFormat=e.uint16,this.coordinate=e.int16,this.baseCoordFormat===2&&(this.referenceGlyph=e.uint16,this.baseCoordPoint=e.uint16),this.baseCoordFormat===3&&(this.deviceTable=e.Offset16)}},sC=Object.freeze({__proto__:null,BASE:KS}),ty=class{constructor(e){this.classFormat=e.uint16,this.classFormat===1&&(this.startGlyphID=e.uint16,this.glyphCount=e.uint16,this.classValueArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.classFormat===2&&(this.classRangeCount=e.uint16,this.classRangeRecords=[...new Array(this.classRangeCount)].map(t=>new iC(e)))}},iC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.class=e.uint16}},xs=class extends ct{constructor(e){super(e),this.coverageFormat=e.uint16,this.coverageFormat===1&&(this.glyphCount=e.uint16,this.glyphArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.coverageFormat===2&&(this.rangeCount=e.uint16,this.rangeRecords=[...new Array(this.rangeCount)].map(t=>new aC(e)))}},aC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.startCoverageIndex=e.uint16}},lC=class{constructor(e,t){this.table=e,this.parser=t,this.start=t.currentPosition,this.format=t.uint16,this.variationRegionListOffset=t.Offset32,this.itemVariationDataCount=t.uint16,this.itemVariationDataOffsets=[...new Array(this.itemVariationDataCount)].map(r=>t.Offset32)}},cC=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.glyphClassDefOffset=r.Offset16,ae(this,"glyphClassDefs",()=>{if(this.glyphClassDefOffset!==0)return r.currentPosition=this.tableStart+this.glyphClassDefOffset,new ty(r)}),this.attachListOffset=r.Offset16,ae(this,"attachList",()=>{if(this.attachListOffset!==0)return r.currentPosition=this.tableStart+this.attachListOffset,new uC(r)}),this.ligCaretListOffset=r.Offset16,ae(this,"ligCaretList",()=>{if(this.ligCaretListOffset!==0)return r.currentPosition=this.tableStart+this.ligCaretListOffset,new dC(r)}),this.markAttachClassDefOffset=r.Offset16,ae(this,"markAttachClassDef",()=>{if(this.markAttachClassDefOffset!==0)return r.currentPosition=this.tableStart+this.markAttachClassDefOffset,new ty(r)}),this.minorVersion>=2&&(this.markGlyphSetsDefOffset=r.Offset16,ae(this,"markGlyphSetsDef",()=>{if(this.markGlyphSetsDefOffset!==0)return r.currentPosition=this.tableStart+this.markGlyphSetsDefOffset,new hC(r)})),this.minorVersion===3&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>{if(this.itemVarStoreOffset!==0)return r.currentPosition=this.tableStart+this.itemVarStoreOffset,new lC(r)}))}},uC=class extends ct{constructor(e){super(e),this.coverageOffset=e.Offset16,this.glyphCount=e.uint16,this.attachPointOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16)}getPoint(e){return this.parser.currentPosition=this.start+this.attachPointOffsets[e],new fC(this.parser)}},fC=class{constructor(e){this.pointCount=e.uint16,this.pointIndices=[...new Array(this.pointCount)].map(t=>e.uint16)}},dC=class extends ct{constructor(e){super(e),this.coverageOffset=e.Offset16,ae(this,"coverage",()=>(e.currentPosition=this.start+this.coverageOffset,new xs(e))),this.ligGlyphCount=e.uint16,this.ligGlyphOffsets=[...new Array(this.ligGlyphCount)].map(t=>e.Offset16)}getLigGlyph(e){return this.parser.currentPosition=this.start+this.ligGlyphOffsets[e],new pC(this.parser)}},pC=class extends ct{constructor(e){super(e),this.caretCount=e.uint16,this.caretValueOffsets=[...new Array(this.caretCount)].map(t=>e.Offset16)}getCaretValue(e){return this.parser.currentPosition=this.start+this.caretValueOffsets[e],new mC(this.parser)}},mC=class{constructor(e){this.caretValueFormat=e.uint16,this.caretValueFormat===1&&(this.coordinate=e.int16),this.caretValueFormat===2&&(this.caretValuePointIndex=e.uint16),this.caretValueFormat===3&&(this.coordinate=e.int16,this.deviceOffset=e.Offset16)}},hC=class extends ct{constructor(e){super(e),this.markGlyphSetTableFormat=e.uint16,this.markGlyphSetCount=e.uint16,this.coverageOffsets=[...new Array(this.markGlyphSetCount)].map(t=>e.Offset32)}getMarkGlyphSet(e){return this.parser.currentPosition=this.start+this.coverageOffsets[e],new xs(this.parser)}},gC=Object.freeze({__proto__:null,GDEF:cC}),ry=class extends ct{static EMPTY={scriptCount:0,scriptRecords:[]};constructor(e){super(e),this.scriptCount=e.uint16,this.scriptRecords=[...new Array(this.scriptCount)].map(t=>new yC(e))}},yC=class{constructor(e){this.scriptTag=e.tag,this.scriptOffset=e.Offset16}},vC=class extends ct{constructor(e){super(e),this.defaultLangSys=e.Offset16,this.langSysCount=e.uint16,this.langSysRecords=[...new Array(this.langSysCount)].map(t=>new bC(e))}},bC=class{constructor(e){this.langSysTag=e.tag,this.langSysOffset=e.Offset16}},oy=class{constructor(e){this.lookupOrder=e.Offset16,this.requiredFeatureIndex=e.uint16,this.featureIndexCount=e.uint16,this.featureIndices=[...new Array(this.featureIndexCount)].map(t=>e.uint16)}},ny=class extends ct{static EMPTY={featureCount:0,featureRecords:[]};constructor(e){super(e),this.featureCount=e.uint16,this.featureRecords=[...new Array(this.featureCount)].map(t=>new wC(e))}},wC=class{constructor(e){this.featureTag=e.tag,this.featureOffset=e.Offset16}},xC=class extends ct{constructor(e){super(e),this.featureParams=e.Offset16,this.lookupIndexCount=e.uint16,this.lookupListIndices=[...new Array(this.lookupIndexCount)].map(t=>e.uint16)}getFeatureParams(){if(this.featureParams>0){let e=this.parser;e.currentPosition=this.start+this.featureParams;let t=this.featureTag;if(t==="size")return new CC(e);if(t.startsWith("cc"))return new SC(e);if(t.startsWith("ss"))return new RC(e)}}},SC=class{constructor(e){this.format=e.uint16,this.featUiLabelNameId=e.uint16,this.featUiTooltipTextNameId=e.uint16,this.sampleTextNameId=e.uint16,this.numNamedParameters=e.uint16,this.firstParamUiLabelNameId=e.uint16,this.charCount=e.uint16,this.character=[...new Array(this.charCount)].map(t=>e.uint24)}},CC=class{constructor(e){this.designSize=e.uint16,this.subfamilyIdentifier=e.uint16,this.subfamilyNameID=e.uint16,this.smallEnd=e.uint16,this.largeEnd=e.uint16}},RC=class{constructor(e){this.version=e.uint16,this.UINameID=e.uint16}};function cy(e){e.parser.currentPosition-=2,delete e.coverageOffset,delete e.getCoverageTable}var Zo=class extends ct{constructor(e){super(e),this.substFormat=e.uint16,this.coverageOffset=e.Offset16}getCoverageTable(){let e=this.parser;return e.currentPosition=this.start+this.coverageOffset,new xs(e)}},Zc=class{constructor(e){this.glyphSequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},EC=class extends Zo{constructor(e){super(e),this.deltaGlyphID=e.int16}},TC=class extends Zo{constructor(e){super(e),this.sequenceCount=e.uint16,this.sequenceOffsets=[...new Array(this.sequenceCount)].map(t=>e.Offset16)}getSequence(e){let t=this.parser;return t.currentPosition=this.start+this.sequenceOffsets[e],new _C(t)}},_C=class{constructor(e){this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},PC=class extends Zo{constructor(e){super(e),this.alternateSetCount=e.uint16,this.alternateSetOffsets=[...new Array(this.alternateSetCount)].map(t=>e.Offset16)}getAlternateSet(e){let t=this.parser;return t.currentPosition=this.start+this.alternateSetOffsets[e],new OC(t)}},OC=class{constructor(e){this.glyphCount=e.uint16,this.alternateGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},kC=class extends Zo{constructor(e){super(e),this.ligatureSetCount=e.uint16,this.ligatureSetOffsets=[...new Array(this.ligatureSetCount)].map(t=>e.Offset16)}getLigatureSet(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureSetOffsets[e],new FC(t)}},FC=class extends ct{constructor(e){super(e),this.ligatureCount=e.uint16,this.ligatureOffsets=[...new Array(this.ligatureCount)].map(t=>e.Offset16)}getLigature(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureOffsets[e],new AC(t)}},AC=class{constructor(e){this.ligatureGlyph=e.uint16,this.componentCount=e.uint16,this.componentGlyphIDs=[...new Array(this.componentCount-1)].map(t=>e.uint16)}},IC=class extends Zo{constructor(e){super(e),this.substFormat===1&&(this.subRuleSetCount=e.uint16,this.subRuleSetOffsets=[...new Array(this.subRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.classDefOffset=e.Offset16,this.subClassSetCount=e.uint16,this.subClassSetOffsets=[...new Array(this.subClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(cy(this),this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.coverageOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new Zc(e)))}getSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 5.${this.substFormat} has no subrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.subRuleSetOffsets[e],new LC(t)}getSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 5.${this.substFormat} has no subclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.subClassSetOffsets[e],new NC(t)}getCoverageTable(e){if(this.substFormat!==3&&!e)return super.getCoverageTable();if(!e)throw new Error(`lookup type 5.${this.substFormat} requires an coverage table index.`);let t=this.parser;return t.currentPosition=this.start+this.coverageOffsets[e],new xs(t)}},LC=class extends ct{constructor(e){super(e),this.subRuleCount=e.uint16,this.subRuleOffsets=[...new Array(this.subRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.subRuleOffsets[e],new uy(t)}},uy=class{constructor(e){this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.inputSequence=[...new Array(this.glyphCount-1)].map(t=>e.uint16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new Zc(e))}},NC=class extends ct{constructor(e){super(e),this.subClassRuleCount=e.uint16,this.subClassRuleOffsets=[...new Array(this.subClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.subClassRuleOffsets[e],new DC(t)}},DC=class extends uy{constructor(e){super(e)}},MC=class extends Zo{constructor(e){super(e),this.substFormat===1&&(this.chainSubRuleSetCount=e.uint16,this.chainSubRuleSetOffsets=[...new Array(this.chainSubRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.backtrackClassDefOffset=e.Offset16,this.inputClassDefOffset=e.Offset16,this.lookaheadClassDefOffset=e.Offset16,this.chainSubClassSetCount=e.uint16,this.chainSubClassSetOffsets=[...new Array(this.chainSubClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(cy(this),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.inputGlyphCount=e.uint16,this.inputCoverageOffsets=[...new Array(this.inputGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[...new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.seqLookupCount=e.uint16,this.seqLookupRecords=[...new Array(this.substitutionCount)].map(t=>new fy(e)))}getChainSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 6.${this.substFormat} has no chainsubrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleSetOffsets[e],new VC(t)}getChainSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 6.${this.substFormat} has no chainsubclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubClassSetOffsets[e],new jC(t)}getCoverageFromOffset(e){if(this.substFormat!==3)throw new Error(`lookup type 6.${this.substFormat} does not use contextual coverage offsets.`);let t=this.parser;return t.currentPosition=this.start+e,new xs(t)}},VC=class extends ct{constructor(e){super(e),this.chainSubRuleCount=e.uint16,this.chainSubRuleOffsets=[...new Array(this.chainSubRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new BC(t)}},BC=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.SubstCount)].map(t=>new Zc(e))}},jC=class extends ct{constructor(e){super(e),this.chainSubClassRuleCount=e.uint16,this.chainSubClassRuleOffsets=[...new Array(this.chainSubClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new zC(t)}},zC=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new fy(e))}},fy=class extends ct{constructor(e){super(e),this.sequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},UC=class extends ct{constructor(e){super(e),this.substFormat=e.uint16,this.extensionLookupType=e.uint16,this.extensionOffset=e.Offset32}},HC=class extends Zo{constructor(e){super(e),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},WC={buildSubtable:function(e,t){let r=new[void 0,EC,TC,PC,kC,IC,MC,UC,HC][e](t);return r.type=e,r}},eo=class extends ct{constructor(e){super(e)}},GC=class extends eo{constructor(e){super(e),console.log("lookup type 1")}},YC=class extends eo{constructor(e){super(e),console.log("lookup type 2")}},qC=class extends eo{constructor(e){super(e),console.log("lookup type 3")}},ZC=class extends eo{constructor(e){super(e),console.log("lookup type 4")}},XC=class extends eo{constructor(e){super(e),console.log("lookup type 5")}},KC=class extends eo{constructor(e){super(e),console.log("lookup type 6")}},JC=class extends eo{constructor(e){super(e),console.log("lookup type 7")}},QC=class extends eo{constructor(e){super(e),console.log("lookup type 8")}},$C=class extends eo{constructor(e){super(e),console.log("lookup type 9")}},eR={buildSubtable:function(e,t){let r=new[void 0,GC,YC,qC,ZC,XC,KC,JC,QC,$C][e](t);return r.type=e,r}},sy=class extends ct{static EMPTY={lookupCount:0,lookups:[]};constructor(e){super(e),this.lookupCount=e.uint16,this.lookups=[...new Array(this.lookupCount)].map(t=>e.Offset16)}},tR=class extends ct{constructor(e,t){super(e),this.ctType=t,this.lookupType=e.uint16,this.lookupFlag=e.uint16,this.subTableCount=e.uint16,this.subtableOffsets=[...new Array(this.subTableCount)].map(r=>e.Offset16),this.markFilteringSet=e.uint16}get rightToLeft(){return this.lookupFlag&!0}get ignoreBaseGlyphs(){return this.lookupFlag&!0}get ignoreLigatures(){return this.lookupFlag&!0}get ignoreMarks(){return this.lookupFlag&!0}get useMarkFilteringSet(){return this.lookupFlag&!0}get markAttachmentType(){return this.lookupFlag&!0}getSubTable(e){let t=this.ctType==="GSUB"?WC:eR;return this.parser.currentPosition=this.start+this.subtableOffsets[e],t.buildSubtable(this.lookupType,this.parser)}},dy=class extends Pe{constructor(e,t,r){let{p:o,tableStart:n}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.scriptListOffset=o.Offset16,this.featureListOffset=o.Offset16,this.lookupListOffset=o.Offset16,this.majorVersion===1&&this.minorVersion===1&&(this.featureVariationsOffset=o.Offset32);let s=!(this.scriptListOffset||this.featureListOffset||this.lookupListOffset);ae(this,"scriptList",()=>s?ry.EMPTY:(o.currentPosition=n+this.scriptListOffset,new ry(o))),ae(this,"featureList",()=>s?ny.EMPTY:(o.currentPosition=n+this.featureListOffset,new ny(o))),ae(this,"lookupList",()=>s?sy.EMPTY:(o.currentPosition=n+this.lookupListOffset,new sy(o))),this.featureVariationsOffset&&ae(this,"featureVariations",()=>s?FeatureVariations.EMPTY:(o.currentPosition=n+this.featureVariationsOffset,new FeatureVariations(o)))}getSupportedScripts(){return this.scriptList.scriptRecords.map(e=>e.scriptTag)}getScriptTable(e){let t=this.scriptList.scriptRecords.find(o=>o.scriptTag===e);this.parser.currentPosition=this.scriptList.start+t.scriptOffset;let r=new vC(this.parser);return r.scriptTag=e,r}ensureScriptTable(e){return typeof e=="string"?this.getScriptTable(e):e}getSupportedLangSys(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys!==0,r=e.langSysRecords.map(o=>o.langSysTag);return t&&r.unshift("dflt"),r}getDefaultLangSysTable(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys;if(t!==0){this.parser.currentPosition=e.start+t;let r=new oy(this.parser);return r.langSysTag="",r.defaultForScript=e.scriptTag,r}}getLangSysTable(e,t="dflt"){if(t==="dflt")return this.getDefaultLangSysTable(e);e=this.ensureScriptTable(e);let r=e.langSysRecords.find(n=>n.langSysTag===t);this.parser.currentPosition=e.start+r.langSysOffset;let o=new oy(this.parser);return o.langSysTag=t,o}getFeatures(e){return e.featureIndices.map(t=>this.getFeature(t))}getFeature(e){let t;if(parseInt(e)==e?t=this.featureList.featureRecords[e]:t=this.featureList.featureRecords.find(o=>o.featureTag===e),!t)return;this.parser.currentPosition=this.featureList.start+t.featureOffset;let r=new xC(this.parser);return r.featureTag=t.featureTag,r}getLookups(e){return e.lookupListIndices.map(t=>this.getLookup(t))}getLookup(e,t){let r=this.lookupList.lookups[e];return this.parser.currentPosition=this.lookupList.start+r,new tR(this.parser,t)}},rR=class extends dy{constructor(e,t){super(e,t,"GSUB")}getLookup(e){return super.getLookup(e,"GSUB")}},oR=Object.freeze({__proto__:null,GSUB:rR}),nR=class extends dy{constructor(e,t){super(e,t,"GPOS")}getLookup(e){return super.getLookup(e,"GPOS")}},sR=Object.freeze({__proto__:null,GPOS:nR}),iR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.offsetToSVGDocumentList=r.Offset32,r.currentPosition=this.tableStart+this.offsetToSVGDocumentList,this.documentList=new aR(r)}},aR=class extends ct{constructor(e){super(e),this.numEntries=e.uint16,this.documentRecords=[...new Array(this.numEntries)].map(t=>new lR(e))}getDocument(e){let t=this.documentRecords[e];if(!t)return"";let r=this.start+t.svgDocOffset;return this.parser.currentPosition=r,this.parser.readBytes(t.svgDocLength)}getDocumentForGlyph(e){let t=this.documentRecords.findIndex(r=>r.startGlyphID<=e&&e<=r.endGlyphID);return t===-1?"":this.getDocument(t)}},lR=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.svgDocOffset=e.Offset32,this.svgDocLength=e.uint32}},cR=Object.freeze({__proto__:null,SVG:iR}),uR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.axesArrayOffset=r.Offset16,r.uint16,this.axisCount=r.uint16,this.axisSize=r.uint16,this.instanceCount=r.uint16,this.instanceSize=r.uint16;let o=this.tableStart+this.axesArrayOffset;ae(this,"axes",()=>(r.currentPosition=o,[...new Array(this.axisCount)].map(s=>new fR(r))));let n=o+this.axisCount*this.axisSize;ae(this,"instances",()=>{let s=[];for(let i=0;ie.tag)}getAxis(e){return this.axes.find(t=>t.tag===e)}},fR=class{constructor(e){this.tag=e.tag,this.minValue=e.fixed,this.defaultValue=e.fixed,this.maxValue=e.fixed,this.flags=e.flags(16),this.axisNameID=e.uint16}},dR=class{constructor(e,t,r){let o=e.currentPosition;this.subfamilyNameID=e.uint16,e.uint16,this.coordinates=[...new Array(t)].map(n=>e.fixed),e.currentPosition-o[...new Array(o)].map(n=>r.fword))}},hR=Object.freeze({__proto__:null,cvt:mR}),gR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},yR=Object.freeze({__proto__:null,fpgm:gR}),vR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRanges=r.uint16,ae(this,"gaspRanges",()=>[...new Array(this.numRanges)].map(n=>new bR(r)))}},bR=class{constructor(e){this.rangeMaxPPEM=e.uint16,this.rangeGaspBehavior=e.uint16}},wR=Object.freeze({__proto__:null,gasp:vR}),xR=class extends Pe{constructor(e,t){super(e,t)}getGlyphData(e,t){return this.parser.currentPosition=this.tableStart+e,this.parser.readBytes(t)}},SR=Object.freeze({__proto__:null,glyf:xR}),CR=class extends Pe{constructor(e,t,r){let{p:o}=super(e,t),n=r.maxp.numGlyphs+1;r.head.indexToLocFormat===0?(this.x2=!0,ae(this,"offsets",()=>[...new Array(n)].map(s=>o.Offset16))):ae(this,"offsets",()=>[...new Array(n)].map(s=>o.Offset32))}getGlyphDataOffsetAndLength(e){let t=this.offsets[e]*this.x2?2:1,r=this.offsets[e+1]*this.x2?2:1;return{offset:t,length:r-t}}},RR=Object.freeze({__proto__:null,loca:CR}),ER=class extends Pe{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},TR=Object.freeze({__proto__:null,prep:ER}),_R=class extends Pe{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},PR=Object.freeze({__proto__:null,CFF:_R}),OR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},kR=Object.freeze({__proto__:null,CFF2:OR}),FR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.defaultVertOriginY=r.int16,this.numVertOriginYMetrics=r.uint16,ae(this,"vertORiginYMetrics",()=>[...new Array(this.numVertOriginYMetrics)].map(o=>new AR(r)))}},AR=class{constructor(e){this.glyphIndex=e.uint16,this.vertOriginY=e.int16}},IR=Object.freeze({__proto__:null,VORG:FR}),LR=class{constructor(e){this.indexSubTableArrayOffset=e.Offset32,this.indexTablesSize=e.uint32,this.numberofIndexSubTables=e.uint32,this.colorRef=e.uint32,this.hori=new sa(e),this.vert=new sa(e),this.startGlyphIndex=e.uint16,this.endGlyphIndex=e.uint16,this.ppemX=e.uint8,this.ppemY=e.uint8,this.bitDepth=e.uint8,this.flags=e.int8}},NR=class{constructor(e){this.hori=new sa(e),this.vert=new sa(e),this.ppemX=e.uint8,this.ppemY=e.uint8,this.substitutePpemX=e.uint8,this.substitutePpemY=e.uint8}},sa=class{constructor(e){this.ascender=e.int8,this.descender=e.int8,this.widthMax=e.uint8,this.caretSlopeNumerator=e.int8,this.caretSlopeDenominator=e.int8,this.caretOffset=e.int8,this.minOriginSB=e.int8,this.minAdvanceSB=e.int8,this.maxBeforeBL=e.int8,this.minAfterBL=e.int8,this.pad1=e.int8,this.pad2=e.int8}},py=class extends Pe{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.numSizes=o.uint32,ae(this,"bitMapSizes",()=>[...new Array(this.numSizes)].map(n=>new LR(o)))}},DR=Object.freeze({__proto__:null,EBLC:py}),my=class extends Pe{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16}},MR=Object.freeze({__proto__:null,EBDT:my}),VR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.numSizes=r.uint32,ae(this,"bitmapScales",()=>[...new Array(this.numSizes)].map(o=>new NR(r)))}},BR=Object.freeze({__proto__:null,EBSC:VR}),jR=class extends py{constructor(e,t){super(e,t,"CBLC")}},zR=Object.freeze({__proto__:null,CBLC:jR}),UR=class extends my{constructor(e,t){super(e,t,"CBDT")}},HR=Object.freeze({__proto__:null,CBDT:UR}),WR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.flags=r.flags(16),this.numStrikes=r.uint32,ae(this,"strikeOffsets",()=>[...new Array(this.numStrikes)].map(o=>r.Offset32))}},GR=Object.freeze({__proto__:null,sbix:WR}),YR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numBaseGlyphRecords=r.uint16,this.baseGlyphRecordsOffset=r.Offset32,this.layerRecordsOffset=r.Offset32,this.numLayerRecords=r.uint16}getBaseGlyphRecord(e){let t=this.tableStart+this.baseGlyphRecordsOffset;this.parser.currentPosition=t;let r=new qc(this.parser),o=r.gID,n=this.tableStart+this.layerRecordsOffset-6;this.parser.currentPosition=n;let s=new qc(this.parser),i=s.gID;if(o===e)return r;if(i===e)return s;for(;t!==n;){let a=t+(n-t)/12;this.parser.currentPosition=a;let u=new qc(this.parser),l=u.gID;if(l===e)return u;l>e?n=a:lnew qR(p))}},qc=class{constructor(e){this.gID=e.uint16,this.firstLayerIndex=e.uint16,this.numLayers=e.uint16}},qR=class{constructor(e){this.gID=e.uint16,this.paletteIndex=e.uint16}},ZR=Object.freeze({__proto__:null,COLR:YR}),XR=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numPaletteEntries=r.uint16;let o=this.numPalettes=r.uint16;this.numColorRecords=r.uint16,this.offsetFirstColorRecord=r.Offset32,this.colorRecordIndices=[...new Array(this.numPalettes)].map(n=>r.uint16),ae(this,"colorRecords",()=>(r.currentPosition=this.tableStart+this.offsetFirstColorRecord,[...new Array(this.numColorRecords)].map(n=>new KR(r)))),this.version===1&&(this.offsetPaletteTypeArray=r.Offset32,this.offsetPaletteLabelArray=r.Offset32,this.offsetPaletteEntryLabelArray=r.Offset32,ae(this,"paletteTypeArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteTypeArray,new JR(r,o))),ae(this,"paletteLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteLabelArray,new QR(r,o))),ae(this,"paletteEntryLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteEntryLabelArray,new $R(r,o))))}},KR=class{constructor(e){this.blue=e.uint8,this.green=e.uint8,this.red=e.uint8,this.alpha=e.uint8}},JR=class{constructor(e,t){this.paletteTypes=[...new Array(t)].map(r=>e.uint32)}},QR=class{constructor(e,t){this.paletteLabels=[...new Array(t)].map(r=>e.uint16)}},$R=class{constructor(e,t){this.paletteEntryLabels=[...new Array(t)].map(r=>e.uint16)}},eE=Object.freeze({__proto__:null,CPAL:XR}),tE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.numSignatures=r.uint16,this.flags=r.uint16,this.signatureRecords=[...new Array(this.numSignatures)].map(o=>new rE(r))}getData(e){let t=this.signatureRecords[e];return this.parser.currentPosition=this.tableStart+t.offset,new oE(this.parser)}},rE=class{constructor(e){this.format=e.uint32,this.length=e.uint32,this.offset=e.Offset32}},oE=class{constructor(e){e.uint16,e.uint16,this.signatureLength=e.uint32,this.signature=e.readBytes(this.signatureLength)}},nE=Object.freeze({__proto__:null,DSIG:tE}),sE=class extends Pe{constructor(e,t,r){let{p:o}=super(e,t),n=r.hmtx.numGlyphs;this.version=o.uint16,this.numRecords=o.int16,this.sizeDeviceRecord=o.int32,this.records=[...new Array(numRecords)].map(s=>new iE(o,n))}},iE=class{constructor(e,t){this.pixelSize=e.uint8,this.maxWidth=e.uint8,this.widths=e.readBytes(t)}},aE=Object.freeze({__proto__:null,hdmx:sE}),lE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.nTables=r.uint16,ae(this,"tables",()=>{let o=this.tableStart+4,n=[];for(let s=0;s[...new Array(this.nPairs)].map(t=>new uE(e)))),this.format===2&&console.warn("Kern subtable format 2 is not supported: this parser currently only parses universal table data.")}get horizontal(){return this.coverage[0]}get minimum(){return this.coverage[1]}get crossstream(){return this.coverage[2]}get override(){return this.coverage[3]}},uE=class{constructor(e){this.left=e.uint16,this.right=e.uint16,this.value=e.fword}},fE=Object.freeze({__proto__:null,kern:lE}),dE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numGlyphs=r.uint16,this.yPels=r.readBytes(this.numGlyphs)}},pE=Object.freeze({__proto__:null,LTSH:dE}),mE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.mergeClassCount=r.uint16,this.mergeDataOffset=r.Offset16,this.classDefCount=r.uint16,this.offsetToClassDefOffsets=r.Offset16,ae(this,"mergeEntryMatrix",()=>[...new Array(this.mergeClassCount)].map(o=>r.readBytes(this.mergeClassCount))),console.warn("Full MERG parsing is currently not supported."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},hE=Object.freeze({__proto__:null,MERG:mE}),gE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.flags=r.uint32,r.uint32,this.dataMapsCount=r.uint32,this.dataMaps=[...new Array(this.dataMapsCount)].map(o=>new yE(this.tableStart,r))}},yE=class{constructor(e,t){this.tableStart=e,this.parser=t,this.tag=t.tag,this.dataOffset=t.Offset32,this.dataLength=t.uint32}getData(){return this.parser.currentField=this.tableStart+this.dataOffset,this.parser.readBytes(this.dataLength)}},vE=Object.freeze({__proto__:null,meta:gE}),bE=class extends Pe{constructor(e,t){super(e,t),console.warn("This font uses a PCLT table, which is currently not supported by this parser."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},wE=Object.freeze({__proto__:null,PCLT:bE}),xE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRecs=r.uint16,this.numRatios=r.uint16,this.ratRanges=[...new Array(this.numRatios)].map(o=>new SE(r)),this.offsets=[...new Array(this.numRatios)].map(o=>r.Offset16),this.VDMXGroups=[...new Array(this.numRecs)].map(o=>new CE(r))}},SE=class{constructor(e){this.bCharSet=e.uint8,this.xRatio=e.uint8,this.yStartRatio=e.uint8,this.yEndRatio=e.uint8}},CE=class{constructor(e){this.recs=e.uint16,this.startsz=e.uint8,this.endsz=e.uint8,this.records=[...new Array(this.recs)].map(t=>new RE(e))}},RE=class{constructor(e){this.yPelHeight=e.uint16,this.yMax=e.int16,this.yMin=e.int16}},EE=Object.freeze({__proto__:null,VDMX:xE}),TE=class extends Pe{constructor(e,t){let{p:r}=super(e,t);this.version=r.fixed,this.ascent=this.vertTypoAscender=r.int16,this.descent=this.vertTypoDescender=r.int16,this.lineGap=this.vertTypoLineGap=r.int16,this.advanceHeightMax=r.int16,this.minTopSideBearing=r.int16,this.minBottomSideBearing=r.int16,this.yMaxExtent=r.int16,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.metricDataFormat=r.int16,this.numOfLongVerMetrics=r.uint16,r.verifyLength()}},_E=Object.freeze({__proto__:null,vhea:TE}),PE=class extends Pe{constructor(e,t,r){super(e,t);let o=r.vhea.numOfLongVerMetrics,n=r.maxp.numGlyphs,s=p.currentPosition;if(lazy(this,"vMetrics",()=>(p.currentPosition=s,[...new Array(o)].map(i=>new OE(p.uint16,p.int16)))),o(p.currentPosition=i,[...new Array(n-o)].map(a=>p.int16)))}}},OE=class{constructor(e,t){this.advanceHeight=e,this.topSideBearing=t}},kE=Object.freeze({__proto__:null,vmtx:PE});function hy(e){let t=e.reduce((r,o)=>(r[o.fontFamily]||(r[o.fontFamily]={name:o.fontFamily,fontFamily:o.fontFamily,slug:Hi(o.fontFamily.toLowerCase()),fontFace:[]}),r[o.fontFamily].fontFace.push(o),r),{});return Object.values(t)}var Jt=h(Y(),1);function FE(){let{installFonts:e}=(0,Ss.useContext)(Mt),[t,r]=(0,Ss.useState)(!1),[o,n]=(0,Ss.useState)(null),s=g=>{a(g)},i=g=>{a(g.target.files)},a=async g=>{if(!g)return;n(null),r(!0);let d=new Set,v=[...g],x=!1,C=v.map(async b=>{if(!await l(b))return x=!0,null;if(d.has(b.name))return null;let A=(((b.name??"").split(".")??[]).pop()??"").toLowerCase();return Uc.includes(A)?(d.add(b.name),b):null}),w=(await Promise.all(C)).filter(b=>b!==null);if(w.length>0)u(w);else{let b=x?(0,Dn.__)("Sorry, you are not allowed to upload this file type."):(0,Dn.__)("No fonts found to install.");n({type:"error",message:b}),r(!1)}},u=async g=>{let d=await Promise.all(g.map(async v=>{let x=await f(v);return await xo(x,x.file,"all"),x}));m(d)};async function l(g){let d=new ia("Uploaded Font");try{let v=await c(g);return await d.fromDataBuffer(v,"font"),!0}catch{return!1}}async function c(g){return new Promise((d,v)=>{let x=new window.FileReader;x.readAsArrayBuffer(g),x.onload=()=>d(x.result),x.onerror=v})}let f=async g=>{let d=await c(g),v=new ia("Uploaded Font");v.fromDataBuffer(d,g.name);let C=(await new Promise(N=>v.onload=N)).detail.font,{name:w}=C.opentype.tables,b=w.get(16)||w.get(1),R=w.get(2).toLowerCase().includes("italic"),A=C.opentype.tables["OS/2"].usWeightClass||"normal",_=!!C.opentype.tables.fvar&&C.opentype.tables.fvar.axes.find(({tag:N})=>N==="wght"),P=_?`${_.minValue} ${_.maxValue}`:null;return{file:g,fontFamily:b,fontStyle:R?"italic":"normal",fontWeight:P||A}},m=async g=>{let d=hy(g);try{await e(d),n({type:"success",message:(0,Dn.__)("Fonts were installed successfully.")})}catch(v){let x=v;n({type:"error",message:x.message,errors:x?.installationErrors})}r(!1)};return(0,Jt.jsxs)("div",{className:"font-library__tabpanel-layout",children:[(0,Jt.jsx)(Ft.DropZone,{onFilesDrop:s}),(0,Jt.jsxs)(Ft.__experimentalVStack,{className:"font-library__local-fonts",justify:"start",children:[o&&(0,Jt.jsxs)(Ft.Notice,{status:o.type,__unstableHTML:!0,onRemove:()=>n(null),children:[o.message,o.errors&&(0,Jt.jsx)("ul",{children:o.errors.map((g,d)=>(0,Jt.jsx)("li",{children:g},d))})]}),t&&(0,Jt.jsx)(Ft.FlexItem,{children:(0,Jt.jsx)("div",{className:"font-library__upload-area",children:(0,Jt.jsx)(Ft.ProgressBar,{})})}),!t&&(0,Jt.jsx)(Ft.FormFileUpload,{accept:Uc.map(g=>`.${g}`).join(","),multiple:!0,onChange:i,render:({openFileDialog:g})=>(0,Jt.jsx)(Ft.Button,{__next40pxDefaultSize:!0,className:"font-library__upload-area",onClick:g,children:(0,Dn.__)("Upload font")})}),(0,Jt.jsx)(Ft.__experimentalText,{className:"font-library__upload-area__text",children:(0,Dn.__)("Uploaded fonts appear in your library and can be used in your theme. Supported formats: .ttf, .otf, .woff, and .woff2.")})]})]})}var aa=FE;var yy=h(Y(),1),{Tabs:HV}=Be(Xc.privateApis),WV={id:"installed-fonts",title:(0,la._x)("Library","Font library")},GV={id:"upload-fonts",title:(0,la._x)("Upload","noun")};var vy=h(xe(),1),Kc=h(ce(),1),IE=h(ke(),1);var by=h(Y(),1);var Jc=h(Y(),1);var wy=h(xe(),1),ca=h(ce(),1);var xy=h(Y(),1);var $c=h(Y(),1);var mr=h(xe(),1),eu=h(ce(),1),zE=h(ke(),1);var Sy=h(Dt(),1);var BE=h(Y(),1),{useSettingsForBlockElement:xB,TypographyPanel:SB}=Be(Sy.privateApis);var jE=h(Y(),1);var tu=h(Y(),1),FB={text:{description:(0,mr.__)("Manage the fonts used on the site."),title:(0,mr.__)("Text")},link:{description:(0,mr.__)("Manage the fonts and typography used on the links."),title:(0,mr.__)("Links")},heading:{description:(0,mr.__)("Manage the fonts and typography used on headings."),title:(0,mr.__)("Headings")},caption:{description:(0,mr.__)("Manage the fonts and typography used on captions."),title:(0,mr.__)("Captions")},button:{description:(0,mr.__)("Manage the fonts and typography used on buttons."),title:(0,mr.__)("Buttons")}};var GE=h(xe(),1),YE=h(ce(),1),Ry=h(Dt(),1);var Mn=h(ce(),1),Cy=h(xe(),1);var WE=h(ke(),1);var UE=h(ce(),1),HE=h(Y(),1);var ru=h(Y(),1);var ou=h(Y(),1),{useSettingsForBlockElement:qB,ColorPanel:ZB}=Be(Ry.privateApis);var $E=h(xe(),1);var XE=h(No(),1),nu=h(ce(),1),KE=h(xe(),1);var fa=h(ce(),1);var ua=h(ce(),1);var Ey=h(Y(),1);function Ty(){let{paletteColors:e}=Tn();return e.slice(0,4).map(({slug:t,color:r},o)=>(0,Ey.jsx)("div",{style:{flexGrow:1,height:"100%",background:r}},`${t}-${o}`))}var Rs=h(Y(),1),qE={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},ZE=({label:e,isFocused:t,withHoverView:r})=>(0,Rs.jsx)(On,{label:e,isFocused:t,withHoverView:r,children:({key:o})=>(0,Rs.jsx)(ua.__unstableMotion.div,{variants:qE,style:{height:"100%",overflow:"hidden"},children:(0,Rs.jsx)(ua.__experimentalHStack,{spacing:0,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Rs.jsx)(Ty,{})})},o)}),_y=ZE;var Xo=h(Y(),1),Py=["color"];function da({title:e,gap:t=2}){let r=Ni(Py);return r?.length<=1?null:(0,Xo.jsxs)(fa.__experimentalVStack,{spacing:3,children:[e&&(0,Xo.jsx)(ur,{level:3,children:e}),(0,Xo.jsx)(fa.__experimentalGrid,{gap:t,children:r.map((o,n)=>(0,Xo.jsx)(Fn,{variation:o,isPill:!0,properties:Py,showTooltip:!0,children:()=>(0,Xo.jsx)(_y,{})},n))})]})}var Oy=h(Y(),1);var JE=h(No(),1),pa=h(ce(),1),QE=h(xe(),1);var ky=h(Y(),1);var su=h(Y(),1);var t2=h(xe(),1),Ay=h(Dt(),1),r2=h(ce(),1);var Fy=h(Dt(),1);var e2=h(Y(),1);var{BackgroundPanel:xj}=Be(Fy.privateApis);var iu=h(Y(),1),{useHasBackgroundPanel:Pj}=Be(Ay.privateApis);var Ly=h(xe(),1);var Es=h(ce(),1),i2=h(xe(),1);var a2=h(ke(),1);var o2=h(ce(),1),n2=h(xe(),1),s2=h(Y(),1);var Iy=h(Y(),1),{Menu:Dj}=Be(Es.privateApis);var lu=h(Y(),1);var hr=h(ce(),1),My=h(xe(),1);var ma=h(ke(),1);var Ts=h(ce(),1);var Ny=h(Y(),1),{Menu:Kj}=Be(Ts.privateApis);var u2=h(ce(),1),f2=h(xe(),1),d2=h(Y(),1);var cu=h(ce(),1),p2=h(xe(),1),m2=h(ke(),1);var Dy=h(Y(),1);var uu=h(Y(),1);var v2=h(Y(),1);var x2=h(xe(),1),By=h(Dt(),1);var Vy=h(Dt(),1),b2=h(ke(),1);var w2=h(Y(),1),{useSettingsForBlockElement:xz,DimensionsPanel:Sz}=Be(Vy.privateApis);var fu=h(Y(),1),{useHasDimensionsPanel:Oz,useSettingsForBlockElement:kz}=Be(By.privateApis);var Gy=h(ce(),1),E2=h(xe(),1);var C2=h(xe(),1),R2=h(ce(),1);var jy=h(nr(),1),zy=h(Xt(),1),ga=h(ke(),1),Uy=h(ce(),1),Hy=h(xe(),1);var ha=h(Y(),1);function S2({gap:e=2}){let{user:t}=(0,ga.useContext)(Tt),r=t?.styles,n=(0,zy.useSelect)(i=>{let a=i(jy.store).__experimentalGetCurrentThemeGlobalStylesVariations();return Array.isArray(a)?a:void 0},[])?.filter(i=>!hs(i,["color"])&&!hs(i,["typography","spacing"])),s=(0,ga.useMemo)(()=>[...[{title:(0,Hy.__)("Default"),settings:{},styles:{}},...n??[]].map(a=>{let u=a?.styles?.blocks?{...a.styles.blocks}:{};r?.blocks&&Object.keys(r.blocks).forEach(m=>{if(r.blocks?.[m]?.css){let g=u[m]||{},d={css:`${u[m]?.css||""} ${r.blocks?.[m]?.css?.trim()||""}`};u[m]={...g,...d}}});let l=r?.css||a.styles?.css?{css:`${a.styles?.css||""} ${r?.css||""}`}:{},c=Object.keys(u).length>0?{blocks:u}:{},f={...a.styles,...l,...c};return{...a,settings:a.settings??{},styles:f}})],[n,r?.blocks,r?.css]);return!n||n.length<1?null:(0,ha.jsx)(Uy.__experimentalGrid,{columns:2,className:"global-styles-ui-style-variations-container",gap:e,children:s.map((i,a)=>(0,ha.jsx)(Fn,{variation:i,children:u=>(0,ha.jsx)(Ic,{label:i?.title,withHoverView:!0,isFocused:u,variation:i})},a))})}var du=S2;var Wy=h(Y(),1);var pu=h(Y(),1);var T2=h(xe(),1),_2=h(ce(),1),Yy=h(Dt(),1);var mu=h(Y(),1),{AdvancedPanel:Zz}=Be(Yy.privateApis);var ev=h(xe(),1),gu=h(ce(),1),yu=h(ke(),1);var P2=h(Xt(),1),O2=h(nr(),1),qy=h(ke(),1);var Ky=h(xe(),1),ya=h(ce(),1),va=h(Xy(),1),k2=h(nr(),1),F2=h(Xt(),1);var Jy=h(jc(),1);var Qy=h(Y(),1),{Badge:e7}=Be(ya.privateApis),t7=3600*1e3*24;var hu=h(ce(),1),_s=h(xe(),1);var $y=h(Y(),1);var vu=h(Y(),1);var tv=h(xe(),1),rv=h(ce(),1);var ov=h(Y(),1);var sv=h(xe(),1),Ps=h(ce(),1),iv=h(ke(),1);var I2=h(Dt(),1),L2=h(xe(),1);var N2=h(Y(),1);var to=h(ce(),1),nv=h(Y(),1);var bu=h(Y(),1);var xu=h(Y(),1);var Su=h(Y(),1);function Vn(e){return function({value:r,baseValue:o,onChange:n,...s}){return(0,Su.jsx)(ms,{value:r,baseValue:o,onChange:n,children:(0,Su.jsx)(e,{...s})})}}var B2=Vn(du);var j2=Vn(da);var z2=Vn(Ui);var Bn=h(Y(),1);function Cu({value:e,baseValue:t,onChange:r,activeTab:o="installed-fonts"}){let n;switch(o){case"upload-fonts":n=(0,Bn.jsx)(aa,{});break;case"installed-fonts":n=(0,Bn.jsx)(Qi,{});break;default:n=(0,Bn.jsx)(ea,{slug:o})}return(0,Bn.jsx)(ms,{value:e,baseValue:t,onChange:r,children:(0,Bn.jsx)(Yi,{children:n})})}var cv=h(as()),{unlock:Ru}=(0,cv.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/font-list-route");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='9553e553cd']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","9553e553cd"),e.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid #ddd;bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-card{border:1px solid #ddd;box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid #ddd;position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid #ddd;height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid #ddd;bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-search{margin-bottom:10px;padding:0 16px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__remove-button.global-styles-ui__shadow-editor__remove-button{border:none}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;max-height:calc(100% - 110px);overflow:auto}.font-library-page:has(.font-library__footer) .font-library-page__tab-panel{max-height:calc(100% - 198px)}')),document.head.appendChild(e)}var{Tabs:ba}=Ru(uv.privateApis),{useGlobalStyles:U2}=Ru(fv.privateApis);function H2(){let{records:e=[]}=(0,wa.useEntityRecords)("root","fontCollection",{_fields:"slug,name,description"}),[t,r]=(0,pv.useState)("installed-fonts"),{base:o,user:n,setUser:s,isReady:i}=U2(),a=(0,dv.useSelect)(l=>l(wa.store).canUser("create",{kind:"postType",name:"wp_font_family"}),[]);if(!i)return null;let u=[{id:"installed-fonts",title:(0,jn._x)("Library","Font library")}];return a&&(u.push({id:"upload-fonts",title:(0,jn._x)("Upload","noun")}),u.push(...(e||[]).map(({slug:l,name:c})=>({id:l,title:e&&e.length===1&&l==="google-fonts"?(0,jn.__)("Install Fonts"):c})))),React.createElement(ic,{title:(0,jn.__)("Fonts"),className:"font-library-page"},React.createElement(ba,{selectedTabId:t,onSelect:l=>r(l)},React.createElement("div",{className:"font-library-page__tablist"},React.createElement(ba.TabList,null,u.map(({id:l,title:c})=>React.createElement(ba.Tab,{key:l,tabId:l},c)))),u.map(({id:l})=>React.createElement(ba.TabPanel,{key:l,tabId:l,focusable:!1,className:"font-library-page__tab-panel"},React.createElement(Cu,{value:n,baseValue:o,onChange:s,activeTab:l})))))}function W2(){return React.createElement(H2,null)}var G2=W2;export{G2 as stage}; +}`,globalThis.document.head.appendChild(n),n}var ZS=[0,1,0,0],XS=[79,84,84,79],KS=[119,79,70,70],JS=[119,79,70,50];function ua(e,t){if(e.length===t.length){for(let r=0;r(globalThis.document&&!this.options.skipStyleSheet&&await qS(this.name,e,this.options),this.loadFont(e)))()}async loadFont(e,t){fetch(e).then(r=>$S(r)&&r.arrayBuffer()).then(r=>this.fromDataBuffer(r,t||e)).catch(r=>{let o=new ca("error",r,`Failed to load font at ${t||e}`);this.dispatch(o),this.onerror&&this.onerror(o)})}async fromDataBuffer(e,t){this.fontData=new DataView(e);let r=QS(this.fontData);if(!r)throw new Error(`${t} is either an unsupported font format, or not a font at all.`);await this.parseBasicData(r);let o=new ca("load",{font:this});this.dispatch(o),this.onload&&this.onload(o)}async parseBasicData(e){return GS().then(t=>(e==="SFNT"&&(this.opentype=new NS(this,this.fontData,t)),e==="WOFF"&&(this.opentype=new VS(this,this.fontData,t)),e==="WOFF2"&&(this.opentype=new jS(this,this.fontData,t)),this.opentype))}getGlyphId(e){return this.opentype.tables.cmap.getGlyphId(e)}reverse(e){return this.opentype.tables.cmap.reverse(e)}supports(e){return this.getGlyphId(e)!==0}supportsVariation(e){return this.opentype.tables.cmap.supportsVariation(e)!==!1}measureText(e,t=16){if(this.__unloaded)throw new Error("Cannot measure text: font was unloaded. Please reload before calling measureText()");let r=document.createElement("div");r.textContent=e,r.style.fontFamily=this.name,r.style.fontSize=`${t}px`,r.style.color="transparent",r.style.background="transparent",r.style.top="0",r.style.left="0",r.style.position="absolute",document.body.appendChild(r);let o=r.getBoundingClientRect();document.body.removeChild(r);let n=this.opentype.tables["OS/2"];return o.fontSize=t,o.ascender=n.sTypoAscender,o.descender=n.sTypoDescender,o}unload(){if(this.styleElement.parentNode){this.styleElement.parentNode.removeElement(this.styleElement);let e=new ca("unload",{font:this});this.dispatch(e),this.onunload&&this.onunload(e)}this._unloaded=!0}load(){if(this.__unloaded){delete this.__unloaded,document.head.appendChild(this.styleElement);let e=new ca("load",{font:this});this.dispatch(e),this.onload&&this.onload(e)}}};globalThis.Font=da;var oo=class extends lt{constructor(e,t,r){super(e),this.plaformID=t,this.encodingID=r}},eC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=0,this.length=e.uint16,this.language=e.uint16,this.glyphIdArray=[...new Array(256)].map(o=>e.uint8)}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 0. only supports(id) is implemented.")),0<=e&&e<=255}reverse(e){return console.warn("reverse not implemented for cmap subtable format 0"),{}}getSupportedCharCodes(){return[{start:1,end:256}]}},tC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=2,this.length=e.uint16,this.language=e.uint16,this.subHeaderKeys=[...new Array(256)].map(s=>e.uint16);let o=Math.max(...this.subHeaderKeys),n=e.currentPosition;ae(this,"subHeaders",()=>(e.currentPosition=n,[...new Array(o)].map(s=>new rC(e))));let i=n+o*8;ae(this,"glyphIndexArray",()=>(e.currentPosition=i,[...new Array(o)].map(s=>e.uint16)))}supports(e){e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 2. only supports(id) is implemented."));let t=e&&255,r=e&&65280,o=this.subHeaders[r],n=this.subHeaders[o],i=n.firstCode,s=i+n.entryCount;return i<=t&&t<=s}reverse(e){return console.warn("reverse not implemented for cmap subtable format 2"),{}}getSupportedCharCodes(e=!1){return e?this.subHeaders.map(t=>({firstCode:t.firstCode,lastCode:t.lastCode})):this.subHeaders.map(t=>({start:t.firstCode,end:t.lastCode}))}},rC=class{constructor(e){this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.first+this.entryCount,this.idDelta=e.int16,this.idRangeOffset=e.uint16}},oC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=4,this.length=e.uint16,this.language=e.uint16,this.segCountX2=e.uint16,this.segCount=this.segCountX2/2,this.searchRange=e.uint16,this.entrySelector=e.uint16,this.rangeShift=e.uint16;let o=e.currentPosition;ae(this,"endCode",()=>e.readBytes(this.segCount,o,16));let n=o+2+this.segCountX2;ae(this,"startCode",()=>e.readBytes(this.segCount,n,16));let i=n+this.segCountX2;ae(this,"idDelta",()=>e.readBytes(this.segCount,i,16,!0));let s=i+this.segCountX2;ae(this,"idRangeOffset",()=>e.readBytes(this.segCount,s,16));let a=s+this.segCountX2,u=this.length-(a-this.tableStart);ae(this,"glyphIdArray",()=>e.readBytes(u,a,16)),ae(this,"segments",()=>this.buildSegments(s,a,e))}buildSegments(e,t,r){let o=(n,i)=>{let s=this.startCode[i],a=this.endCode[i],u=this.idDelta[i],l=this.idRangeOffset[i],c=e+2*i,m=[];if(l===0)for(let d=s+u,h=a+u;d<=h;d++)m.push(d);else for(let d=0,h=a-s;d<=h;d++)r.currentPosition=c+l+d*2,m.push(r.uint16);return{startCode:s,endCode:a,idDelta:u,idRangeOffset:l,glyphIDs:m}};return[...new Array(this.segCount)].map(o)}reverse(e){let t=this.segments.find(o=>o.glyphIDs.includes(e));if(!t)return{};let r=t.startCode+t.glyphIDs.indexOf(e);return{code:r,unicode:String.fromCodePoint(r)}}getGlyphId(e){if(e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535)return 0;let t=this.segments.find(r=>r.startCode<=e&&e<=r.endCode);return t?t.glyphIDs[e-t.startCode]:0}supports(e){return this.getGlyphId(e)!==0}getSupportedCharCodes(e=!1){return e?this.segments:this.segments.map(t=>({start:t.startCode,end:t.endCode}))}},nC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=6,this.length=e.uint16,this.language=e.uint16,this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.firstCode+this.entryCount-1,ae(this,"glyphIdArray",()=>[...new Array(this.entryCount)].map(n=>e.uint16))}supports(e){if(e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 6. only supports(id) is implemented.")),ethis.firstCode+this.entryCount)return{};let t=e-this.firstCode;return{code:t,unicode:String.fromCodePoint(t)}}reverse(e){let t=this.glyphIdArray.indexOf(e);if(t>-1)return this.firstCode+t}getSupportedCharCodes(e=!1){return e?[{firstCode:this.firstCode,lastCode:this.lastCode}]:[{start:this.firstCode,end:this.lastCode}]}},iC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=8,e.uint16,this.length=e.uint32,this.language=e.uint32,this.is32=[...new Array(8192)].map(n=>e.uint8),this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new sC(e)))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 8. only supports(id) is implemented.")),this.groups.findIndex(t=>t.startcharCode<=e&&e<=t.endcharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 8"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startcharCode,end:t.endcharCode}))}},sC=class{constructor(e){this.startcharCode=e.uint32,this.endcharCode=e.uint32,this.startGlyphID=e.uint32}},aC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=10,e.uint16,this.length=e.uint32,this.language=e.uint32,this.startCharCode=e.uint32,this.numChars=e.uint32,this.endCharCode=this.startCharCode+this.numChars,ae(this,"glyphs",()=>[...new Array(this.numChars)].map(n=>e.uint16))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 10. only supports(id) is implemented.")),ethis.startCharCode+this.numChars?!1:e-this.startCharCode}reverse(e){return console.warn("reverse not implemented for cmap subtable format 10"),{}}getSupportedCharCodes(e=!1){return e?[{startCharCode:this.startCharCode,endCharCode:this.endCharCode}]:[{start:this.startCharCode,end:this.endCharCode}]}},lC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=12,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new cC(e)))}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535?0:this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){for(let t of this.groups){let r=t.startGlyphID;if(r>e)continue;if(r===e)return t.startCharCode;if(r+(t.endCharCode-t.startCharCode)({start:t.startCharCode,end:t.endCharCode}))}},cC=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.startGlyphID=e.uint32}},uC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=13,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32;let o=[...new Array(this.numGroups)].map(n=>new fC(e));ae(this,"groups",o)}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 13"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startCharCode,end:t.endCharCode}))}},fC=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.glyphID=e.uint32}},dC=class extends oo{constructor(e,t,r){super(e,t,r),this.subTableStart=e.currentPosition,this.format=14,this.length=e.uint32,this.numVarSelectorRecords=e.uint32,ae(this,"varSelectors",()=>[...new Array(this.numVarSelectorRecords)].map(o=>new pC(e)))}supports(){return console.warn("supports not implemented for cmap subtable format 14"),0}getSupportedCharCodes(){return console.warn("getSupportedCharCodes not implemented for cmap subtable format 14"),[]}reverse(e){return console.warn("reverse not implemented for cmap subtable format 14"),{}}supportsVariation(e){let t=this.varSelector.find(r=>r.varSelector===e);return t||!1}getSupportedVariations(){return this.varSelectors.map(e=>e.varSelector)}},pC=class{constructor(e){this.varSelector=e.uint24,this.defaultUVSOffset=e.Offset32,this.nonDefaultUVSOffset=e.Offset32}};function mC(e,t,r){let o=e.uint16;return o===0?new eC(e,t,r):o===2?new tC(e,t,r):o===4?new oC(e,t,r):o===6?new nC(e,t,r):o===8?new iC(e,t,r):o===10?new aC(e,t,r):o===12?new lC(e,t,r):o===13?new uC(e,t,r):o===14?new dC(e,t,r):{}}var hC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numTables=r.uint16,this.encodingRecords=[...new Array(this.numTables)].map(o=>new gC(r,this.tableStart))}getSubTable(e){return this.encodingRecords[e].table}getSupportedEncodings(){return this.encodingRecords.map(e=>({platformID:e.platformID,encodingId:e.encodingID}))}getSupportedCharCodes(e,t){let r=this.encodingRecords.findIndex(n=>n.platformID===e&&n.encodingID===t);return r===-1?!1:this.getSubTable(r).getSupportedCharCodes()}reverse(e){for(let t=0;t{let n=this.getSubTable(o);return n.getGlyphId?(t=n.getGlyphId(e),t!==0):!1}),t}supports(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supports&&o.supports(e)!==!1})}supportsVariation(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supportsVariation&&o.supportsVariation(e)!==!1})}},gC=class{constructor(e,t){let r=this.platformID=e.uint16,o=this.encodingID=e.uint16,n=this.offset=e.Offset32;ae(this,"table",()=>(e.currentPosition=t+n,mC(e,r,o)))}},yC=Object.freeze({__proto__:null,cmap:hC}),vC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.load({majorVersion:r.uint16,minorVersion:r.uint16,fontRevision:r.fixed,checkSumAdjustment:r.uint32,magicNumber:r.uint32,flags:r.flags(16),unitsPerEm:r.uint16,created:r.longdatetime,modified:r.longdatetime,xMin:r.int16,yMin:r.int16,xMax:r.int16,yMax:r.int16,macStyle:r.flags(16),lowestRecPPEM:r.uint16,fontDirectionHint:r.uint16,indexToLocFormat:r.uint16,glyphDataFormat:r.uint16})}},bC=Object.freeze({__proto__:null,head:vC}),wC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.ascender=r.fword,this.descender=r.fword,this.lineGap=r.fword,this.advanceWidthMax=r.ufword,this.minLeftSideBearing=r.fword,this.minRightSideBearing=r.fword,this.xMaxExtent=r.fword,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,r.int16,r.int16,r.int16,r.int16,this.metricDataFormat=r.int16,this.numberOfHMetrics=r.uint16,r.verifyLength()}},xC=Object.freeze({__proto__:null,hhea:wC}),SC=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.hhea.numberOfHMetrics,i=r.maxp.numGlyphs,s=o.currentPosition;if(ae(this,"hMetrics",()=>(o.currentPosition=s,[...new Array(n)].map(a=>new CC(o.uint16,o.int16)))),n(o.currentPosition=a,[...new Array(i-n)].map(u=>o.int16)))}}},CC=class{constructor(e,t){this.advanceWidth=e,this.lsb=t}},_C=Object.freeze({__proto__:null,hmtx:SC}),RC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.legacyFixed,this.numGlyphs=r.uint16,this.version===1&&(this.maxPoints=r.uint16,this.maxContours=r.uint16,this.maxCompositePoints=r.uint16,this.maxCompositeContours=r.uint16,this.maxZones=r.uint16,this.maxTwilightPoints=r.uint16,this.maxStorage=r.uint16,this.maxFunctionDefs=r.uint16,this.maxInstructionDefs=r.uint16,this.maxStackElements=r.uint16,this.maxSizeOfInstructions=r.uint16,this.maxComponentElements=r.uint16,this.maxComponentDepth=r.uint16),r.verifyLength()}},EC=Object.freeze({__proto__:null,maxp:RC}),TC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.format=r.uint16,this.count=r.uint16,this.stringOffset=r.Offset16,this.nameRecords=[...new Array(this.count)].map(o=>new OC(r,this)),this.format===1&&(this.langTagCount=r.uint16,this.langTagRecords=[...new Array(this.langTagCount)].map(o=>new PC(r.uint16,r.Offset16))),this.stringStart=this.tableStart+this.stringOffset}get(e){let t=this.nameRecords.find(r=>r.nameID===e);if(t)return t.string}},PC=class{constructor(e,t){this.length=e,this.offset=t}},OC=class{constructor(e,t){this.platformID=e.uint16,this.encodingID=e.uint16,this.languageID=e.uint16,this.nameID=e.uint16,this.length=e.uint16,this.offset=e.Offset16,ae(this,"string",()=>(e.currentPosition=t.stringStart+this.offset,kC(e,this)))}};function kC(e,t){let{platformID:r,length:o}=t;if(o===0)return"";if(r===0||r===3){let s=[];for(let a=0,u=o/2;ar.uint8),this.ulUnicodeRange1=r.flags(32),this.ulUnicodeRange2=r.flags(32),this.ulUnicodeRange3=r.flags(32),this.ulUnicodeRange4=r.flags(32),this.achVendID=r.tag,this.fsSelection=r.uint16,this.usFirstCharIndex=r.uint16,this.usLastCharIndex=r.uint16,this.sTypoAscender=r.int16,this.sTypoDescender=r.int16,this.sTypoLineGap=r.int16,this.usWinAscent=r.uint16,this.usWinDescent=r.uint16,this.version===0||(this.ulCodePageRange1=r.flags(32),this.ulCodePageRange2=r.flags(32),this.version===1)||(this.sxHeight=r.int16,this.sCapHeight=r.int16,this.usDefaultChar=r.uint16,this.usBreakChar=r.uint16,this.usMaxContext=r.uint16,this.version<=4)||(this.usLowerOpticalPointSize=r.uint16,this.usUpperOpticalPointSize=r.uint16,this.version===5))return r.verifyLength()}},IC=Object.freeze({__proto__:null,OS2:AC}),LC=class extends ke{constructor(e,t){let{p:r}=super(e,t);if(this.version=r.legacyFixed,this.italicAngle=r.fixed,this.underlinePosition=r.fword,this.underlineThickness=r.fword,this.isFixedPitch=r.uint32,this.minMemType42=r.uint32,this.maxMemType42=r.uint32,this.minMemType1=r.uint32,this.maxMemType1=r.uint32,this.version===1||this.version===3)return r.verifyLength();if(this.numGlyphs=r.uint16,this.version===2){this.glyphNameIndex=[...new Array(this.numGlyphs)].map(o=>r.uint16),this.namesOffset=r.currentPosition,this.glyphNameOffsets=[1];for(let o=0;or.int8))}getGlyphName(e){if(this.version!==2)return console.warn(`post table version ${this.version} does not support glyph name lookups`),"";let t=this.glyphNameIndex[e];if(t<258)return Ry[t];let r=this.glyphNameOffsets[e],n=this.glyphNameOffsets[e+1]-r-1;return n===0?".notdef.":(this.parser.currentPosition=this.namesOffset+r,this.parser.readBytes(n,this.namesOffset+r,8,!0).map(s=>String.fromCharCode(s)).join(""))}},Ry=[".notdef",".null","nonmarkingreturn","space","exclam","quotedbl","numbersign","dollar","percent","ampersand","quotesingle","parenleft","parenright","asterisk","plus","comma","hyphen","period","slash","zero","one","two","three","four","five","six","seven","eight","nine","colon","semicolon","less","equal","greater","question","at","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","bracketleft","backslash","bracketright","asciicircum","underscore","grave","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","braceleft","bar","braceright","asciitilde","Adieresis","Aring","Ccedilla","Eacute","Ntilde","Odieresis","Udieresis","aacute","agrave","acircumflex","adieresis","atilde","aring","ccedilla","eacute","egrave","ecircumflex","edieresis","iacute","igrave","icircumflex","idieresis","ntilde","oacute","ograve","ocircumflex","odieresis","otilde","uacute","ugrave","ucircumflex","udieresis","dagger","degree","cent","sterling","section","bullet","paragraph","germandbls","registered","copyright","trademark","acute","dieresis","notequal","AE","Oslash","infinity","plusminus","lessequal","greaterequal","yen","mu","partialdiff","summation","product","pi","integral","ordfeminine","ordmasculine","Omega","ae","oslash","questiondown","exclamdown","logicalnot","radical","florin","approxequal","Delta","guillemotleft","guillemotright","ellipsis","nonbreakingspace","Agrave","Atilde","Otilde","OE","oe","endash","emdash","quotedblleft","quotedblright","quoteleft","quoteright","divide","lozenge","ydieresis","Ydieresis","fraction","currency","guilsinglleft","guilsinglright","fi","fl","daggerdbl","periodcentered","quotesinglbase","quotedblbase","perthousand","Acircumflex","Ecircumflex","Aacute","Edieresis","Egrave","Iacute","Icircumflex","Idieresis","Igrave","Oacute","Ocircumflex","apple","Ograve","Uacute","Ucircumflex","Ugrave","dotlessi","circumflex","tilde","macron","breve","dotaccent","ring","cedilla","hungarumlaut","ogonek","caron","Lslash","lslash","Scaron","scaron","Zcaron","zcaron","brokenbar","Eth","eth","Yacute","yacute","Thorn","thorn","minus","multiply","onesuperior","twosuperior","threesuperior","onehalf","onequarter","threequarters","franc","Gbreve","gbreve","Idotaccent","Scedilla","scedilla","Cacute","cacute","Ccaron","ccaron","dcroat"],NC=Object.freeze({__proto__:null,post:LC}),MC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.horizAxisOffset=r.Offset16,this.vertAxisOffset=r.Offset16,ae(this,"horizAxis",()=>new nu({offset:e.offset+this.horizAxisOffset},t)),ae(this,"vertAxis",()=>new nu({offset:e.offset+this.vertAxisOffset},t)),this.majorVersion===1&&this.minorVersion===1&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>new nu({offset:e.offset+this.itemVarStoreOffset},t)))}},nu=class extends ke{constructor(e,t){let{p:r}=super(e,t,"AxisTable");this.baseTagListOffset=r.Offset16,this.baseScriptListOffset=r.Offset16,ae(this,"baseTagList",()=>new VC({offset:e.offset+this.baseTagListOffset},t)),ae(this,"baseScriptList",()=>new DC({offset:e.offset+this.baseScriptListOffset},t))}},VC=class extends ke{constructor(e,t){let{p:r}=super(e,t,"BaseTagListTable");this.baseTagCount=r.uint16,this.baselineTags=[...new Array(this.baseTagCount)].map(o=>r.tag)}},DC=class extends ke{constructor(e,t){let{p:r}=super(e,t,"BaseScriptListTable");this.baseScriptCount=r.uint16;let o=r.currentPosition;ae(this,"baseScriptRecords",()=>(r.currentPosition=o,[...new Array(this.baseScriptCount)].map(n=>new BC(this.start,r))))}},BC=class{constructor(e,t){this.baseScriptTag=t.tag,this.baseScriptOffset=t.Offset16,ae(this,"baseScriptTable",()=>(t.currentPosition=e+this.baseScriptOffset,new jC(t)))}},jC=class{constructor(e){this.start=e.currentPosition,this.baseValuesOffset=e.Offset16,this.defaultMinMaxOffset=e.Offset16,this.baseLangSysCount=e.uint16,this.baseLangSysRecords=[...new Array(this.baseLangSysCount)].map(t=>new zC(this.start,e)),ae(this,"baseValues",()=>(e.currentPosition=this.start+this.baseValuesOffset,new HC(e))),ae(this,"defaultMinMax",()=>(e.currentPosition=this.start+this.defaultMinMaxOffset,new Iy(e)))}},zC=class{constructor(e,t){this.baseLangSysTag=t.tag,this.minMaxOffset=t.Offset16,ae(this,"minMax",()=>(t.currentPosition=e+this.minMaxOffset,new Iy(t)))}},HC=class{constructor(e){this.parser=e,this.start=e.currentPosition,this.defaultBaselineIndex=e.uint16,this.baseCoordCount=e.uint16,this.baseCoords=[...new Array(this.baseCoordCount)].map(t=>e.Offset16)}getTable(e){return this.parser.currentPosition=this.start+this.baseCoords[e],new WC(this.parser)}},Iy=class{constructor(e){this.minCoord=e.Offset16,this.maxCoord=e.Offset16,this.featMinMaxCount=e.uint16;let t=e.currentPosition;ae(this,"featMinMaxRecords",()=>(e.currentPosition=t,[...new Array(this.featMinMaxCount)].map(r=>new UC(e))))}},UC=class{constructor(e){this.featureTableTag=e.tag,this.minCoord=e.Offset16,this.maxCoord=e.Offset16}},WC=class{constructor(e){this.baseCoordFormat=e.uint16,this.coordinate=e.int16,this.baseCoordFormat===2&&(this.referenceGlyph=e.uint16,this.baseCoordPoint=e.uint16),this.baseCoordFormat===3&&(this.deviceTable=e.Offset16)}},GC=Object.freeze({__proto__:null,BASE:MC}),Ey=class{constructor(e){this.classFormat=e.uint16,this.classFormat===1&&(this.startGlyphID=e.uint16,this.glyphCount=e.uint16,this.classValueArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.classFormat===2&&(this.classRangeCount=e.uint16,this.classRangeRecords=[...new Array(this.classRangeCount)].map(t=>new YC(e)))}},YC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.class=e.uint16}},Ci=class extends lt{constructor(e){super(e),this.coverageFormat=e.uint16,this.coverageFormat===1&&(this.glyphCount=e.uint16,this.glyphArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.coverageFormat===2&&(this.rangeCount=e.uint16,this.rangeRecords=[...new Array(this.rangeCount)].map(t=>new qC(e)))}},qC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.startCoverageIndex=e.uint16}},ZC=class{constructor(e,t){this.table=e,this.parser=t,this.start=t.currentPosition,this.format=t.uint16,this.variationRegionListOffset=t.Offset32,this.itemVariationDataCount=t.uint16,this.itemVariationDataOffsets=[...new Array(this.itemVariationDataCount)].map(r=>t.Offset32)}},XC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.glyphClassDefOffset=r.Offset16,ae(this,"glyphClassDefs",()=>{if(this.glyphClassDefOffset!==0)return r.currentPosition=this.tableStart+this.glyphClassDefOffset,new Ey(r)}),this.attachListOffset=r.Offset16,ae(this,"attachList",()=>{if(this.attachListOffset!==0)return r.currentPosition=this.tableStart+this.attachListOffset,new KC(r)}),this.ligCaretListOffset=r.Offset16,ae(this,"ligCaretList",()=>{if(this.ligCaretListOffset!==0)return r.currentPosition=this.tableStart+this.ligCaretListOffset,new QC(r)}),this.markAttachClassDefOffset=r.Offset16,ae(this,"markAttachClassDef",()=>{if(this.markAttachClassDefOffset!==0)return r.currentPosition=this.tableStart+this.markAttachClassDefOffset,new Ey(r)}),this.minorVersion>=2&&(this.markGlyphSetsDefOffset=r.Offset16,ae(this,"markGlyphSetsDef",()=>{if(this.markGlyphSetsDefOffset!==0)return r.currentPosition=this.tableStart+this.markGlyphSetsDefOffset,new t_(r)})),this.minorVersion===3&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>{if(this.itemVarStoreOffset!==0)return r.currentPosition=this.tableStart+this.itemVarStoreOffset,new ZC(r)}))}},KC=class extends lt{constructor(e){super(e),this.coverageOffset=e.Offset16,this.glyphCount=e.uint16,this.attachPointOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16)}getPoint(e){return this.parser.currentPosition=this.start+this.attachPointOffsets[e],new JC(this.parser)}},JC=class{constructor(e){this.pointCount=e.uint16,this.pointIndices=[...new Array(this.pointCount)].map(t=>e.uint16)}},QC=class extends lt{constructor(e){super(e),this.coverageOffset=e.Offset16,ae(this,"coverage",()=>(e.currentPosition=this.start+this.coverageOffset,new Ci(e))),this.ligGlyphCount=e.uint16,this.ligGlyphOffsets=[...new Array(this.ligGlyphCount)].map(t=>e.Offset16)}getLigGlyph(e){return this.parser.currentPosition=this.start+this.ligGlyphOffsets[e],new $C(this.parser)}},$C=class extends lt{constructor(e){super(e),this.caretCount=e.uint16,this.caretValueOffsets=[...new Array(this.caretCount)].map(t=>e.Offset16)}getCaretValue(e){return this.parser.currentPosition=this.start+this.caretValueOffsets[e],new e_(this.parser)}},e_=class{constructor(e){this.caretValueFormat=e.uint16,this.caretValueFormat===1&&(this.coordinate=e.int16),this.caretValueFormat===2&&(this.caretValuePointIndex=e.uint16),this.caretValueFormat===3&&(this.coordinate=e.int16,this.deviceOffset=e.Offset16)}},t_=class extends lt{constructor(e){super(e),this.markGlyphSetTableFormat=e.uint16,this.markGlyphSetCount=e.uint16,this.coverageOffsets=[...new Array(this.markGlyphSetCount)].map(t=>e.Offset32)}getMarkGlyphSet(e){return this.parser.currentPosition=this.start+this.coverageOffsets[e],new Ci(this.parser)}},r_=Object.freeze({__proto__:null,GDEF:XC}),Ty=class extends lt{static EMPTY={scriptCount:0,scriptRecords:[]};constructor(e){super(e),this.scriptCount=e.uint16,this.scriptRecords=[...new Array(this.scriptCount)].map(t=>new o_(e))}},o_=class{constructor(e){this.scriptTag=e.tag,this.scriptOffset=e.Offset16}},n_=class extends lt{constructor(e){super(e),this.defaultLangSys=e.Offset16,this.langSysCount=e.uint16,this.langSysRecords=[...new Array(this.langSysCount)].map(t=>new i_(e))}},i_=class{constructor(e){this.langSysTag=e.tag,this.langSysOffset=e.Offset16}},Py=class{constructor(e){this.lookupOrder=e.Offset16,this.requiredFeatureIndex=e.uint16,this.featureIndexCount=e.uint16,this.featureIndices=[...new Array(this.featureIndexCount)].map(t=>e.uint16)}},Oy=class extends lt{static EMPTY={featureCount:0,featureRecords:[]};constructor(e){super(e),this.featureCount=e.uint16,this.featureRecords=[...new Array(this.featureCount)].map(t=>new s_(e))}},s_=class{constructor(e){this.featureTag=e.tag,this.featureOffset=e.Offset16}},a_=class extends lt{constructor(e){super(e),this.featureParams=e.Offset16,this.lookupIndexCount=e.uint16,this.lookupListIndices=[...new Array(this.lookupIndexCount)].map(t=>e.uint16)}getFeatureParams(){if(this.featureParams>0){let e=this.parser;e.currentPosition=this.start+this.featureParams;let t=this.featureTag;if(t==="size")return new c_(e);if(t.startsWith("cc"))return new l_(e);if(t.startsWith("ss"))return new u_(e)}}},l_=class{constructor(e){this.format=e.uint16,this.featUiLabelNameId=e.uint16,this.featUiTooltipTextNameId=e.uint16,this.sampleTextNameId=e.uint16,this.numNamedParameters=e.uint16,this.firstParamUiLabelNameId=e.uint16,this.charCount=e.uint16,this.character=[...new Array(this.charCount)].map(t=>e.uint24)}},c_=class{constructor(e){this.designSize=e.uint16,this.subfamilyIdentifier=e.uint16,this.subfamilyNameID=e.uint16,this.smallEnd=e.uint16,this.largeEnd=e.uint16}},u_=class{constructor(e){this.version=e.uint16,this.UINameID=e.uint16}};function Ly(e){e.parser.currentPosition-=2,delete e.coverageOffset,delete e.getCoverageTable}var Qo=class extends lt{constructor(e){super(e),this.substFormat=e.uint16,this.coverageOffset=e.Offset16}getCoverageTable(){let e=this.parser;return e.currentPosition=this.start+this.coverageOffset,new Ci(e)}},su=class{constructor(e){this.glyphSequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},f_=class extends Qo{constructor(e){super(e),this.deltaGlyphID=e.int16}},d_=class extends Qo{constructor(e){super(e),this.sequenceCount=e.uint16,this.sequenceOffsets=[...new Array(this.sequenceCount)].map(t=>e.Offset16)}getSequence(e){let t=this.parser;return t.currentPosition=this.start+this.sequenceOffsets[e],new p_(t)}},p_=class{constructor(e){this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},m_=class extends Qo{constructor(e){super(e),this.alternateSetCount=e.uint16,this.alternateSetOffsets=[...new Array(this.alternateSetCount)].map(t=>e.Offset16)}getAlternateSet(e){let t=this.parser;return t.currentPosition=this.start+this.alternateSetOffsets[e],new h_(t)}},h_=class{constructor(e){this.glyphCount=e.uint16,this.alternateGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},g_=class extends Qo{constructor(e){super(e),this.ligatureSetCount=e.uint16,this.ligatureSetOffsets=[...new Array(this.ligatureSetCount)].map(t=>e.Offset16)}getLigatureSet(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureSetOffsets[e],new y_(t)}},y_=class extends lt{constructor(e){super(e),this.ligatureCount=e.uint16,this.ligatureOffsets=[...new Array(this.ligatureCount)].map(t=>e.Offset16)}getLigature(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureOffsets[e],new v_(t)}},v_=class{constructor(e){this.ligatureGlyph=e.uint16,this.componentCount=e.uint16,this.componentGlyphIDs=[...new Array(this.componentCount-1)].map(t=>e.uint16)}},b_=class extends Qo{constructor(e){super(e),this.substFormat===1&&(this.subRuleSetCount=e.uint16,this.subRuleSetOffsets=[...new Array(this.subRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.classDefOffset=e.Offset16,this.subClassSetCount=e.uint16,this.subClassSetOffsets=[...new Array(this.subClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(Ly(this),this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.coverageOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new su(e)))}getSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 5.${this.substFormat} has no subrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.subRuleSetOffsets[e],new w_(t)}getSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 5.${this.substFormat} has no subclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.subClassSetOffsets[e],new x_(t)}getCoverageTable(e){if(this.substFormat!==3&&!e)return super.getCoverageTable();if(!e)throw new Error(`lookup type 5.${this.substFormat} requires an coverage table index.`);let t=this.parser;return t.currentPosition=this.start+this.coverageOffsets[e],new Ci(t)}},w_=class extends lt{constructor(e){super(e),this.subRuleCount=e.uint16,this.subRuleOffsets=[...new Array(this.subRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.subRuleOffsets[e],new Ny(t)}},Ny=class{constructor(e){this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.inputSequence=[...new Array(this.glyphCount-1)].map(t=>e.uint16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new su(e))}},x_=class extends lt{constructor(e){super(e),this.subClassRuleCount=e.uint16,this.subClassRuleOffsets=[...new Array(this.subClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.subClassRuleOffsets[e],new S_(t)}},S_=class extends Ny{constructor(e){super(e)}},C_=class extends Qo{constructor(e){super(e),this.substFormat===1&&(this.chainSubRuleSetCount=e.uint16,this.chainSubRuleSetOffsets=[...new Array(this.chainSubRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.backtrackClassDefOffset=e.Offset16,this.inputClassDefOffset=e.Offset16,this.lookaheadClassDefOffset=e.Offset16,this.chainSubClassSetCount=e.uint16,this.chainSubClassSetOffsets=[...new Array(this.chainSubClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(Ly(this),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.inputGlyphCount=e.uint16,this.inputCoverageOffsets=[...new Array(this.inputGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[...new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.seqLookupCount=e.uint16,this.seqLookupRecords=[...new Array(this.substitutionCount)].map(t=>new My(e)))}getChainSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 6.${this.substFormat} has no chainsubrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleSetOffsets[e],new __(t)}getChainSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 6.${this.substFormat} has no chainsubclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubClassSetOffsets[e],new E_(t)}getCoverageFromOffset(e){if(this.substFormat!==3)throw new Error(`lookup type 6.${this.substFormat} does not use contextual coverage offsets.`);let t=this.parser;return t.currentPosition=this.start+e,new Ci(t)}},__=class extends lt{constructor(e){super(e),this.chainSubRuleCount=e.uint16,this.chainSubRuleOffsets=[...new Array(this.chainSubRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new R_(t)}},R_=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.SubstCount)].map(t=>new su(e))}},E_=class extends lt{constructor(e){super(e),this.chainSubClassRuleCount=e.uint16,this.chainSubClassRuleOffsets=[...new Array(this.chainSubClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new T_(t)}},T_=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new My(e))}},My=class extends lt{constructor(e){super(e),this.sequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},P_=class extends lt{constructor(e){super(e),this.substFormat=e.uint16,this.extensionLookupType=e.uint16,this.extensionOffset=e.Offset32}},O_=class extends Qo{constructor(e){super(e),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},k_={buildSubtable:function(e,t){let r=new[void 0,f_,d_,m_,g_,b_,C_,P_,O_][e](t);return r.type=e,r}},no=class extends lt{constructor(e){super(e)}},F_=class extends no{constructor(e){super(e),console.log("lookup type 1")}},A_=class extends no{constructor(e){super(e),console.log("lookup type 2")}},I_=class extends no{constructor(e){super(e),console.log("lookup type 3")}},L_=class extends no{constructor(e){super(e),console.log("lookup type 4")}},N_=class extends no{constructor(e){super(e),console.log("lookup type 5")}},M_=class extends no{constructor(e){super(e),console.log("lookup type 6")}},V_=class extends no{constructor(e){super(e),console.log("lookup type 7")}},D_=class extends no{constructor(e){super(e),console.log("lookup type 8")}},B_=class extends no{constructor(e){super(e),console.log("lookup type 9")}},j_={buildSubtable:function(e,t){let r=new[void 0,F_,A_,I_,L_,N_,M_,V_,D_,B_][e](t);return r.type=e,r}},ky=class extends lt{static EMPTY={lookupCount:0,lookups:[]};constructor(e){super(e),this.lookupCount=e.uint16,this.lookups=[...new Array(this.lookupCount)].map(t=>e.Offset16)}},z_=class extends lt{constructor(e,t){super(e),this.ctType=t,this.lookupType=e.uint16,this.lookupFlag=e.uint16,this.subTableCount=e.uint16,this.subtableOffsets=[...new Array(this.subTableCount)].map(r=>e.Offset16),this.markFilteringSet=e.uint16}get rightToLeft(){return this.lookupFlag&!0}get ignoreBaseGlyphs(){return this.lookupFlag&!0}get ignoreLigatures(){return this.lookupFlag&!0}get ignoreMarks(){return this.lookupFlag&!0}get useMarkFilteringSet(){return this.lookupFlag&!0}get markAttachmentType(){return this.lookupFlag&!0}getSubTable(e){let t=this.ctType==="GSUB"?k_:j_;return this.parser.currentPosition=this.start+this.subtableOffsets[e],t.buildSubtable(this.lookupType,this.parser)}},Vy=class extends ke{constructor(e,t,r){let{p:o,tableStart:n}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.scriptListOffset=o.Offset16,this.featureListOffset=o.Offset16,this.lookupListOffset=o.Offset16,this.majorVersion===1&&this.minorVersion===1&&(this.featureVariationsOffset=o.Offset32);let i=!(this.scriptListOffset||this.featureListOffset||this.lookupListOffset);ae(this,"scriptList",()=>i?Ty.EMPTY:(o.currentPosition=n+this.scriptListOffset,new Ty(o))),ae(this,"featureList",()=>i?Oy.EMPTY:(o.currentPosition=n+this.featureListOffset,new Oy(o))),ae(this,"lookupList",()=>i?ky.EMPTY:(o.currentPosition=n+this.lookupListOffset,new ky(o))),this.featureVariationsOffset&&ae(this,"featureVariations",()=>i?FeatureVariations.EMPTY:(o.currentPosition=n+this.featureVariationsOffset,new FeatureVariations(o)))}getSupportedScripts(){return this.scriptList.scriptRecords.map(e=>e.scriptTag)}getScriptTable(e){let t=this.scriptList.scriptRecords.find(o=>o.scriptTag===e);this.parser.currentPosition=this.scriptList.start+t.scriptOffset;let r=new n_(this.parser);return r.scriptTag=e,r}ensureScriptTable(e){return typeof e=="string"?this.getScriptTable(e):e}getSupportedLangSys(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys!==0,r=e.langSysRecords.map(o=>o.langSysTag);return t&&r.unshift("dflt"),r}getDefaultLangSysTable(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys;if(t!==0){this.parser.currentPosition=e.start+t;let r=new Py(this.parser);return r.langSysTag="",r.defaultForScript=e.scriptTag,r}}getLangSysTable(e,t="dflt"){if(t==="dflt")return this.getDefaultLangSysTable(e);e=this.ensureScriptTable(e);let r=e.langSysRecords.find(n=>n.langSysTag===t);this.parser.currentPosition=e.start+r.langSysOffset;let o=new Py(this.parser);return o.langSysTag=t,o}getFeatures(e){return e.featureIndices.map(t=>this.getFeature(t))}getFeature(e){let t;if(parseInt(e)==e?t=this.featureList.featureRecords[e]:t=this.featureList.featureRecords.find(o=>o.featureTag===e),!t)return;this.parser.currentPosition=this.featureList.start+t.featureOffset;let r=new a_(this.parser);return r.featureTag=t.featureTag,r}getLookups(e){return e.lookupListIndices.map(t=>this.getLookup(t))}getLookup(e,t){let r=this.lookupList.lookups[e];return this.parser.currentPosition=this.lookupList.start+r,new z_(this.parser,t)}},H_=class extends Vy{constructor(e,t){super(e,t,"GSUB")}getLookup(e){return super.getLookup(e,"GSUB")}},U_=Object.freeze({__proto__:null,GSUB:H_}),W_=class extends Vy{constructor(e,t){super(e,t,"GPOS")}getLookup(e){return super.getLookup(e,"GPOS")}},G_=Object.freeze({__proto__:null,GPOS:W_}),Y_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.offsetToSVGDocumentList=r.Offset32,r.currentPosition=this.tableStart+this.offsetToSVGDocumentList,this.documentList=new q_(r)}},q_=class extends lt{constructor(e){super(e),this.numEntries=e.uint16,this.documentRecords=[...new Array(this.numEntries)].map(t=>new Z_(e))}getDocument(e){let t=this.documentRecords[e];if(!t)return"";let r=this.start+t.svgDocOffset;return this.parser.currentPosition=r,this.parser.readBytes(t.svgDocLength)}getDocumentForGlyph(e){let t=this.documentRecords.findIndex(r=>r.startGlyphID<=e&&e<=r.endGlyphID);return t===-1?"":this.getDocument(t)}},Z_=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.svgDocOffset=e.Offset32,this.svgDocLength=e.uint32}},X_=Object.freeze({__proto__:null,SVG:Y_}),K_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.axesArrayOffset=r.Offset16,r.uint16,this.axisCount=r.uint16,this.axisSize=r.uint16,this.instanceCount=r.uint16,this.instanceSize=r.uint16;let o=this.tableStart+this.axesArrayOffset;ae(this,"axes",()=>(r.currentPosition=o,[...new Array(this.axisCount)].map(i=>new J_(r))));let n=o+this.axisCount*this.axisSize;ae(this,"instances",()=>{let i=[];for(let s=0;se.tag)}getAxis(e){return this.axes.find(t=>t.tag===e)}},J_=class{constructor(e){this.tag=e.tag,this.minValue=e.fixed,this.defaultValue=e.fixed,this.maxValue=e.fixed,this.flags=e.flags(16),this.axisNameID=e.uint16}},Q_=class{constructor(e,t,r){let o=e.currentPosition;this.subfamilyNameID=e.uint16,e.uint16,this.coordinates=[...new Array(t)].map(n=>e.fixed),e.currentPosition-o[...new Array(o)].map(n=>r.fword))}},tR=Object.freeze({__proto__:null,cvt:eR}),rR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},oR=Object.freeze({__proto__:null,fpgm:rR}),nR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRanges=r.uint16,ae(this,"gaspRanges",()=>[...new Array(this.numRanges)].map(n=>new iR(r)))}},iR=class{constructor(e){this.rangeMaxPPEM=e.uint16,this.rangeGaspBehavior=e.uint16}},sR=Object.freeze({__proto__:null,gasp:nR}),aR=class extends ke{constructor(e,t){super(e,t)}getGlyphData(e,t){return this.parser.currentPosition=this.tableStart+e,this.parser.readBytes(t)}},lR=Object.freeze({__proto__:null,glyf:aR}),cR=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.maxp.numGlyphs+1;r.head.indexToLocFormat===0?(this.x2=!0,ae(this,"offsets",()=>[...new Array(n)].map(i=>o.Offset16))):ae(this,"offsets",()=>[...new Array(n)].map(i=>o.Offset32))}getGlyphDataOffsetAndLength(e){let t=this.offsets[e]*this.x2?2:1,r=this.offsets[e+1]*this.x2?2:1;return{offset:t,length:r-t}}},uR=Object.freeze({__proto__:null,loca:cR}),fR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},dR=Object.freeze({__proto__:null,prep:fR}),pR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},mR=Object.freeze({__proto__:null,CFF:pR}),hR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},gR=Object.freeze({__proto__:null,CFF2:hR}),yR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.defaultVertOriginY=r.int16,this.numVertOriginYMetrics=r.uint16,ae(this,"vertORiginYMetrics",()=>[...new Array(this.numVertOriginYMetrics)].map(o=>new vR(r)))}},vR=class{constructor(e){this.glyphIndex=e.uint16,this.vertOriginY=e.int16}},bR=Object.freeze({__proto__:null,VORG:yR}),wR=class{constructor(e){this.indexSubTableArrayOffset=e.Offset32,this.indexTablesSize=e.uint32,this.numberofIndexSubTables=e.uint32,this.colorRef=e.uint32,this.hori=new fa(e),this.vert=new fa(e),this.startGlyphIndex=e.uint16,this.endGlyphIndex=e.uint16,this.ppemX=e.uint8,this.ppemY=e.uint8,this.bitDepth=e.uint8,this.flags=e.int8}},xR=class{constructor(e){this.hori=new fa(e),this.vert=new fa(e),this.ppemX=e.uint8,this.ppemY=e.uint8,this.substitutePpemX=e.uint8,this.substitutePpemY=e.uint8}},fa=class{constructor(e){this.ascender=e.int8,this.descender=e.int8,this.widthMax=e.uint8,this.caretSlopeNumerator=e.int8,this.caretSlopeDenominator=e.int8,this.caretOffset=e.int8,this.minOriginSB=e.int8,this.minAdvanceSB=e.int8,this.maxBeforeBL=e.int8,this.minAfterBL=e.int8,this.pad1=e.int8,this.pad2=e.int8}},Dy=class extends ke{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.numSizes=o.uint32,ae(this,"bitMapSizes",()=>[...new Array(this.numSizes)].map(n=>new wR(o)))}},SR=Object.freeze({__proto__:null,EBLC:Dy}),By=class extends ke{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16}},CR=Object.freeze({__proto__:null,EBDT:By}),_R=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.numSizes=r.uint32,ae(this,"bitmapScales",()=>[...new Array(this.numSizes)].map(o=>new xR(r)))}},RR=Object.freeze({__proto__:null,EBSC:_R}),ER=class extends Dy{constructor(e,t){super(e,t,"CBLC")}},TR=Object.freeze({__proto__:null,CBLC:ER}),PR=class extends By{constructor(e,t){super(e,t,"CBDT")}},OR=Object.freeze({__proto__:null,CBDT:PR}),kR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.flags=r.flags(16),this.numStrikes=r.uint32,ae(this,"strikeOffsets",()=>[...new Array(this.numStrikes)].map(o=>r.Offset32))}},FR=Object.freeze({__proto__:null,sbix:kR}),AR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numBaseGlyphRecords=r.uint16,this.baseGlyphRecordsOffset=r.Offset32,this.layerRecordsOffset=r.Offset32,this.numLayerRecords=r.uint16}getBaseGlyphRecord(e){let t=this.tableStart+this.baseGlyphRecordsOffset;this.parser.currentPosition=t;let r=new iu(this.parser),o=r.gID,n=this.tableStart+this.layerRecordsOffset-6;this.parser.currentPosition=n;let i=new iu(this.parser),s=i.gID;if(o===e)return r;if(s===e)return i;for(;t!==n;){let a=t+(n-t)/12;this.parser.currentPosition=a;let u=new iu(this.parser),l=u.gID;if(l===e)return u;l>e?n=a:lnew IR(p))}},iu=class{constructor(e){this.gID=e.uint16,this.firstLayerIndex=e.uint16,this.numLayers=e.uint16}},IR=class{constructor(e){this.gID=e.uint16,this.paletteIndex=e.uint16}},LR=Object.freeze({__proto__:null,COLR:AR}),NR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numPaletteEntries=r.uint16;let o=this.numPalettes=r.uint16;this.numColorRecords=r.uint16,this.offsetFirstColorRecord=r.Offset32,this.colorRecordIndices=[...new Array(this.numPalettes)].map(n=>r.uint16),ae(this,"colorRecords",()=>(r.currentPosition=this.tableStart+this.offsetFirstColorRecord,[...new Array(this.numColorRecords)].map(n=>new MR(r)))),this.version===1&&(this.offsetPaletteTypeArray=r.Offset32,this.offsetPaletteLabelArray=r.Offset32,this.offsetPaletteEntryLabelArray=r.Offset32,ae(this,"paletteTypeArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteTypeArray,new VR(r,o))),ae(this,"paletteLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteLabelArray,new DR(r,o))),ae(this,"paletteEntryLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteEntryLabelArray,new BR(r,o))))}},MR=class{constructor(e){this.blue=e.uint8,this.green=e.uint8,this.red=e.uint8,this.alpha=e.uint8}},VR=class{constructor(e,t){this.paletteTypes=[...new Array(t)].map(r=>e.uint32)}},DR=class{constructor(e,t){this.paletteLabels=[...new Array(t)].map(r=>e.uint16)}},BR=class{constructor(e,t){this.paletteEntryLabels=[...new Array(t)].map(r=>e.uint16)}},jR=Object.freeze({__proto__:null,CPAL:NR}),zR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.numSignatures=r.uint16,this.flags=r.uint16,this.signatureRecords=[...new Array(this.numSignatures)].map(o=>new HR(r))}getData(e){let t=this.signatureRecords[e];return this.parser.currentPosition=this.tableStart+t.offset,new UR(this.parser)}},HR=class{constructor(e){this.format=e.uint32,this.length=e.uint32,this.offset=e.Offset32}},UR=class{constructor(e){e.uint16,e.uint16,this.signatureLength=e.uint32,this.signature=e.readBytes(this.signatureLength)}},WR=Object.freeze({__proto__:null,DSIG:zR}),GR=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.hmtx.numGlyphs;this.version=o.uint16,this.numRecords=o.int16,this.sizeDeviceRecord=o.int32,this.records=[...new Array(numRecords)].map(i=>new YR(o,n))}},YR=class{constructor(e,t){this.pixelSize=e.uint8,this.maxWidth=e.uint8,this.widths=e.readBytes(t)}},qR=Object.freeze({__proto__:null,hdmx:GR}),ZR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.nTables=r.uint16,ae(this,"tables",()=>{let o=this.tableStart+4,n=[];for(let i=0;i[...new Array(this.nPairs)].map(t=>new KR(e)))),this.format===2&&console.warn("Kern subtable format 2 is not supported: this parser currently only parses universal table data.")}get horizontal(){return this.coverage[0]}get minimum(){return this.coverage[1]}get crossstream(){return this.coverage[2]}get override(){return this.coverage[3]}},KR=class{constructor(e){this.left=e.uint16,this.right=e.uint16,this.value=e.fword}},JR=Object.freeze({__proto__:null,kern:ZR}),QR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numGlyphs=r.uint16,this.yPels=r.readBytes(this.numGlyphs)}},$R=Object.freeze({__proto__:null,LTSH:QR}),e2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.mergeClassCount=r.uint16,this.mergeDataOffset=r.Offset16,this.classDefCount=r.uint16,this.offsetToClassDefOffsets=r.Offset16,ae(this,"mergeEntryMatrix",()=>[...new Array(this.mergeClassCount)].map(o=>r.readBytes(this.mergeClassCount))),console.warn("Full MERG parsing is currently not supported."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},t2=Object.freeze({__proto__:null,MERG:e2}),r2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.flags=r.uint32,r.uint32,this.dataMapsCount=r.uint32,this.dataMaps=[...new Array(this.dataMapsCount)].map(o=>new o2(this.tableStart,r))}},o2=class{constructor(e,t){this.tableStart=e,this.parser=t,this.tag=t.tag,this.dataOffset=t.Offset32,this.dataLength=t.uint32}getData(){return this.parser.currentField=this.tableStart+this.dataOffset,this.parser.readBytes(this.dataLength)}},n2=Object.freeze({__proto__:null,meta:r2}),i2=class extends ke{constructor(e,t){super(e,t),console.warn("This font uses a PCLT table, which is currently not supported by this parser."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},s2=Object.freeze({__proto__:null,PCLT:i2}),a2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRecs=r.uint16,this.numRatios=r.uint16,this.ratRanges=[...new Array(this.numRatios)].map(o=>new l2(r)),this.offsets=[...new Array(this.numRatios)].map(o=>r.Offset16),this.VDMXGroups=[...new Array(this.numRecs)].map(o=>new c2(r))}},l2=class{constructor(e){this.bCharSet=e.uint8,this.xRatio=e.uint8,this.yStartRatio=e.uint8,this.yEndRatio=e.uint8}},c2=class{constructor(e){this.recs=e.uint16,this.startsz=e.uint8,this.endsz=e.uint8,this.records=[...new Array(this.recs)].map(t=>new u2(e))}},u2=class{constructor(e){this.yPelHeight=e.uint16,this.yMax=e.int16,this.yMin=e.int16}},f2=Object.freeze({__proto__:null,VDMX:a2}),d2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.fixed,this.ascent=this.vertTypoAscender=r.int16,this.descent=this.vertTypoDescender=r.int16,this.lineGap=this.vertTypoLineGap=r.int16,this.advanceHeightMax=r.int16,this.minTopSideBearing=r.int16,this.minBottomSideBearing=r.int16,this.yMaxExtent=r.int16,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.metricDataFormat=r.int16,this.numOfLongVerMetrics=r.uint16,r.verifyLength()}},p2=Object.freeze({__proto__:null,vhea:d2}),m2=class extends ke{constructor(e,t,r){super(e,t);let o=r.vhea.numOfLongVerMetrics,n=r.maxp.numGlyphs,i=p.currentPosition;if(lazy(this,"vMetrics",()=>(p.currentPosition=i,[...new Array(o)].map(s=>new h2(p.uint16,p.int16)))),o(p.currentPosition=s,[...new Array(n-o)].map(a=>p.int16)))}}},h2=class{constructor(e,t){this.advanceHeight=e,this.topSideBearing=t}},g2=Object.freeze({__proto__:null,vmtx:m2});function jy(e){let t=e.reduce((r,o)=>(r[o.fontFamily]||(r[o.fontFamily]={name:o.fontFamily,fontFamily:o.fontFamily,slug:Ks(o.fontFamily.toLowerCase()),fontFace:[]}),r[o.fontFamily].fontFace.push(o),r),{});return Object.values(t)}var Qt=f(Z(),1);function y2(){let{installFonts:e}=(0,_i.useContext)(jt),[t,r]=(0,_i.useState)(!1),[o,n]=(0,_i.useState)(null),i=h=>{a(h)},s=h=>{a(h.target.files)},a=async h=>{if(!h)return;n(null),r(!0);let g=new Set,b=[...h],w=!1,C=b.map(async v=>{if(!await l(v))return w=!0,null;if(g.has(v.name))return null;let k=(((v.name??"").split(".")??[]).pop()??"").toLowerCase();return eu.includes(k)?(g.add(v.name),v):null}),x=(await Promise.all(C)).filter(v=>v!==null);if(x.length>0)u(x);else{let v=w?(0,Vn.__)("Sorry, you are not allowed to upload this file type."):(0,Vn.__)("No fonts found to install.");n({type:"error",message:v}),r(!1)}},u=async h=>{let g=await Promise.all(h.map(async b=>{let w=await m(b);return await Po(w,w.file,"all"),w}));d(g)};async function l(h){let g=new da("Uploaded Font");try{let b=await c(h);return await g.fromDataBuffer(b,"font"),!0}catch{return!1}}async function c(h){return new Promise((g,b)=>{let w=new window.FileReader;w.readAsArrayBuffer(h),w.onload=()=>g(w.result),w.onerror=b})}let m=async h=>{let g=await c(h),b=new da("Uploaded Font");b.fromDataBuffer(g,h.name);let C=(await new Promise(I=>b.onload=I)).detail.font,{name:x}=C.opentype.tables,v=x.get(16)||x.get(1),_=x.get(2).toLowerCase().includes("italic"),k=C.opentype.tables["OS/2"].usWeightClass||"normal",T=!!C.opentype.tables.fvar&&C.opentype.tables.fvar.axes.find(({tag:I})=>I==="wght"),O=T?`${T.minValue} ${T.maxValue}`:null;return{file:h,fontFamily:v,fontStyle:_?"italic":"normal",fontWeight:O||k}},d=async h=>{let g=jy(h);try{await e(g),n({type:"success",message:(0,Vn.__)("Fonts were installed successfully.")})}catch(b){let w=b;n({type:"error",message:w.message,errors:w?.installationErrors})}r(!1)};return(0,Qt.jsxs)("div",{className:"font-library__tabpanel-layout",children:[(0,Qt.jsx)(Ot.DropZone,{onFilesDrop:i}),(0,Qt.jsxs)(Ot.__experimentalVStack,{className:"font-library__local-fonts",justify:"start",children:[o&&(0,Qt.jsxs)(Ot.Notice,{status:o.type,__unstableHTML:!0,onRemove:()=>n(null),children:[o.message,o.errors&&(0,Qt.jsx)("ul",{children:o.errors.map((h,g)=>(0,Qt.jsx)("li",{children:h},g))})]}),t&&(0,Qt.jsx)(Ot.FlexItem,{children:(0,Qt.jsx)("div",{className:"font-library__upload-area",children:(0,Qt.jsx)(Ot.ProgressBar,{})})}),!t&&(0,Qt.jsx)(Ot.FormFileUpload,{accept:eu.map(h=>`.${h}`).join(","),multiple:!0,onChange:s,render:({openFileDialog:h})=>(0,Qt.jsx)(Ot.Button,{__next40pxDefaultSize:!0,className:"font-library__upload-area",onClick:h,children:(0,Vn.__)("Upload font")})}),(0,Qt.jsx)(Ot.__experimentalText,{className:"font-library__upload-area__text",children:(0,Vn.__)("Uploaded fonts appear in your library and can be used in your theme. Supported formats: .ttf, .otf, .woff, and .woff2.")})]})]})}var pa=y2;var Hy=f(Z(),1),{Tabs:WB}=Ve(au.privateApis),GB={id:"installed-fonts",title:(0,ma._x)("Library","Font library")},YB={id:"upload-fonts",title:(0,ma._x)("Upload","noun")};var Uy=f(ge(),1),lu=f(ue(),1),b2=f(Te(),1);var Wy=f(Z(),1);var cu=f(Z(),1);var Gy=f(ge(),1),ha=f(ue(),1);var Yy=f(Z(),1);var fu=f(Z(),1);var wt=f(ge(),1),du=f(ue(),1),T2=f(Te(),1);var qy=f(Dt(),1);var R2=f(Z(),1),{useSettingsForBlockElement:Sj,TypographyPanel:Cj}=Ve(qy.privateApis);var E2=f(Z(),1);var pu=f(Z(),1),Aj={text:{description:(0,wt.__)("Manage the fonts used on the site."),title:(0,wt.__)("Text")},link:{description:(0,wt.__)("Manage the fonts and typography used on the links."),title:(0,wt.__)("Links")},heading:{description:(0,wt.__)("Manage the fonts and typography used on headings."),title:(0,wt.__)("Headings")},caption:{description:(0,wt.__)("Manage the fonts and typography used on captions."),title:(0,wt.__)("Captions")},cite:{description:(0,wt.__)("Manage the fonts and typography used on citations."),title:(0,wt.__)("Citations")},button:{description:(0,wt.__)("Manage the fonts and typography used on buttons."),title:(0,wt.__)("Buttons")},textInput:{description:(0,wt.__)("Manage the fonts and typography used on inputs."),title:(0,wt.__)("Inputs")},select:{description:(0,wt.__)("Manage the fonts and typography used on selects."),title:(0,wt.__)("Selects")}};var ga=f(ge(),1),F2=f(ue(),1),Xy=f(Dt(),1);var Dn=f(ue(),1),Zy=f(ge(),1);var k2=f(Te(),1);var P2=f(ue(),1),O2=f(Z(),1);var mu=f(Z(),1);var hu=f(Z(),1),{useSettingsForBlockElement:Zj,ColorPanel:Xj}=Ve(Xy.privateApis),Kj=[{name:"cite",label:(0,ga.__)("Citations")},{name:"textInput",label:(0,ga.__)("Inputs")},{name:"select",label:(0,ga.__)("Selects")}];var H2=f(ge(),1);var L2=f(yo(),1),gu=f(ue(),1),N2=f(ge(),1);var va=f(ue(),1);var ya=f(ue(),1);var Ky=f(Z(),1);function Jy(){let{paletteColors:e}=Pn();return e.slice(0,4).map(({slug:t,color:r},o)=>(0,Ky.jsx)("div",{style:{flexGrow:1,height:"100%",background:r}},`${t}-${o}`))}var Ei=f(Z(),1),A2={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},I2=({label:e,isFocused:t,withHoverView:r})=>(0,Ei.jsx)(Fn,{label:e,isFocused:t,withHoverView:r,children:({key:o})=>(0,Ei.jsx)(ya.__unstableMotion.div,{variants:A2,style:{height:"100%",overflow:"hidden"},children:(0,Ei.jsx)(ya.__experimentalHStack,{spacing:0,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Ei.jsx)(Jy,{})})},o)}),Qy=I2;var $o=f(Z(),1),$y=["color"];function ba({title:e,gap:t=2}){let r=Hs($y);return r?.length<=1?null:(0,$o.jsxs)(va.__experimentalVStack,{spacing:3,children:[e&&(0,$o.jsx)(Er,{level:3,children:e}),(0,$o.jsx)(va.__experimentalGrid,{gap:t,children:r.map((o,n)=>(0,$o.jsx)(An,{variation:o,isPill:!0,properties:$y,showTooltip:!0,children:()=>(0,$o.jsx)(Qy,{})},n))})]})}var ev=f(Z(),1);var M2=f(yo(),1),tv=f(ue(),1),V2=f(ge(),1);var rv=f(Z(),1);var D2=f(yo(),1),B2=f(Te(),1),j2=f(ue(),1);var z2=f(ge(),1);var ov=f(Z(),1);var yu=f(Z(),1);var W2=f(ge(),1),iv=f(Dt(),1),G2=f(ue(),1);var nv=f(Dt(),1);var U2=f(Z(),1);var{BackgroundPanel:E9}=Ve(nv.privateApis);var vu=f(Z(),1),{useHasBackgroundPanel:I9}=Ve(iv.privateApis);var av=f(ge(),1);var Ti=f(ue(),1),X2=f(ge(),1);var K2=f(Te(),1);var Y2=f(ue(),1),q2=f(ge(),1),Z2=f(Z(),1);var sv=f(Z(),1),{Menu:z9}=Ve(Ti.privateApis);var wu=f(Z(),1);var yr=f(ue(),1),uv=f(ge(),1);var wa=f(Te(),1);var Pi=f(ue(),1);var lv=f(Z(),1),{Menu:tz}=Ve(Pi.privateApis);var $2=f(ue(),1),eE=f(ge(),1),tE=f(Z(),1);var xu=f(ue(),1),rE=f(ge(),1),oE=f(Te(),1);var cv=f(Z(),1);var Su=f(Z(),1);var aE=f(Z(),1);var uE=f(ge(),1),dv=f(Dt(),1);var fv=f(Dt(),1),lE=f(Te(),1);var cE=f(Z(),1),{useSettingsForBlockElement:Ez,DimensionsPanel:Tz}=Ve(fv.privateApis);var Cu=f(Z(),1),{useHasDimensionsPanel:Lz,useSettingsForBlockElement:Nz}=Ve(dv.privateApis);var vv=f(ue(),1),mE=f(ge(),1);var dE=f(ge(),1),pE=f(ue(),1);var pv=f(sr(),1),mv=f(Kt(),1),Sa=f(Te(),1),hv=f(ue(),1),gv=f(ge(),1);var xa=f(Z(),1);function fE({gap:e=2}){let{user:t}=(0,Sa.useContext)(gt),r=t?.styles,n=(0,mv.useSelect)(s=>{let a=s(pv.store).__experimentalGetCurrentThemeGlobalStylesVariations();return Array.isArray(a)?a:void 0},[])?.filter(s=>!yi(s,["color"])&&!yi(s,["typography","spacing"])),i=(0,Sa.useMemo)(()=>[...[{title:(0,gv.__)("Default"),settings:{},styles:{}},...n??[]].map(a=>{let u=a?.styles?.blocks?{...a.styles.blocks}:{};r?.blocks&&Object.keys(r.blocks).forEach(d=>{if(r.blocks?.[d]?.css){let h=u[d]||{},g={css:`${u[d]?.css||""} ${r.blocks?.[d]?.css?.trim()||""}`};u[d]={...h,...g}}});let l=r?.css||a.styles?.css?{css:`${a.styles?.css||""} ${r?.css||""}`}:{},c=Object.keys(u).length>0?{blocks:u}:{},m={...a.styles,...l,...c};return{...a,settings:a.settings??{},styles:m}})],[n,r?.blocks,r?.css]);return!n||n.length<1?null:(0,xa.jsx)(hv.__experimentalGrid,{columns:2,className:"global-styles-ui-style-variations-container",gap:e,children:i.map((s,a)=>(0,xa.jsx)(An,{variation:s,children:u=>(0,xa.jsx)(Wc,{label:s?.title,withHoverView:!0,isFocused:u,variation:s})},a))})}var _u=fE;var yv=f(Z(),1);var Ru=f(Z(),1);var hE=f(ge(),1),gE=f(ue(),1),bv=f(Dt(),1);var Eu=f(Z(),1),{AdvancedPanel:$z}=Ve(bv.privateApis);var Tv=f(ge(),1),Pu=f(ue(),1),Ou=f(Te(),1);var yE=f(Kt(),1),vE=f(sr(),1),wv=f(Te(),1);var Cv=f(ge(),1),Ca=f(ue(),1),_a=f(Sv(),1),bE=f(sr(),1),wE=f(Kt(),1);var _v=f(Qc(),1);var Rv=f(Z(),1),{Badge:i7}=Ve(Ca.privateApis),s7=3600*1e3*24;var Tu=f(ue(),1),Oi=f(ge(),1);var Ev=f(Z(),1);var ku=f(Z(),1);var Pv=f(ge(),1),Ov=f(ue(),1);var kv=f(Z(),1);var Av=f(ge(),1),ki=f(ue(),1),Iv=f(Te(),1);var SE=f(Dt(),1),CE=f(ge(),1);var _E=f(Z(),1);var io=f(ue(),1),Fv=f(Z(),1);var Fu=f(Z(),1);var Iu=f(Z(),1);var Lu=f(Z(),1);function Bn(e){return function({value:r,baseValue:o,onChange:n,...i}){return(0,Lu.jsx)(gi,{value:r,baseValue:o,onChange:n,children:(0,Lu.jsx)(e,{...i})})}}var PE=Bn(_u);var OE=Bn(ba);var kE=Bn(Xs);var jn=f(Z(),1);function Nu({value:e,baseValue:t,onChange:r,activeTab:o="installed-fonts"}){let n;switch(o){case"upload-fonts":n=(0,jn.jsx)(pa,{});break;case"installed-fonts":n=(0,jn.jsx)(na,{});break;default:n=(0,jn.jsx)(sa,{slug:o})}return(0,jn.jsx)(gi,{value:e,baseValue:t,onChange:r,children:(0,jn.jsx)($s,{children:n})})}var Mv=f(li()),{unlock:Mu}=(0,Mv.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/font-list-route");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='8316bac515']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","8316bac515"),e.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-demo{position:relative}.font-library__font-card{border:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-image{transition:opacity var(--wpds-motion-duration-lg,.3s) var(--wpds-motion-easing-subtle,cubic-bezier(.15,0,.15,1))}}.font-library__font-card .font-library__font-variant_demo-image.is-loading{left:0;opacity:0;position:absolute;top:0}.font-library__font-card .font-library__font-variant-demo-skeleton{border-radius:var(--wpds-border-radius-sm,2px);height:24px}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-filter{margin-bottom:12px;padding:0 16px}.global-styles-ui-block-types-search{flex-grow:1}.global-styles-ui-block-types-item-list .global-styles-ui-block-types-item__icon{min-width:24px}.global-styles-ui-block-types-item-list__no-results{padding-top:16px}.global-styles-ui-block-types-item__indicator{background:var(--wp-admin-theme-color);border-radius:50%;flex:none;height:6px;margin-left:auto;width:6px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-duotone-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;max-height:calc(100% - 110px);overflow:auto}.font-library-page:has(.font-library__footer) .font-library-page__tab-panel{max-height:calc(100% - 198px)}')),document.head.appendChild(e)}var Gr=f(Z()),{Tabs:Ra}=Mu(Vv.privateApis),{useGlobalStyles:FE}=Mu(Dv.privateApis);function AE(){let{records:e=[]}=(0,Ea.useEntityRecords)("root","fontCollection",{_fields:"slug,name,description"}),[t,r]=(0,jv.useState)("installed-fonts"),{base:o,user:n,setUser:i,isReady:s}=FE(),a=(0,Bv.useSelect)(l=>l(Ea.store).canUser("create",{kind:"postType",name:"wp_font_family"}),[]);if(!s)return null;let u=[{id:"installed-fonts",title:(0,zn._x)("Library","Font library")}];return a&&(u.push({id:"upload-fonts",title:(0,zn._x)("Upload","noun")}),u.push(...(e||[]).map(({slug:l,name:c})=>({id:l,title:e&&e.length===1&&l==="google-fonts"?(0,zn.__)("Install Fonts"):c})))),(0,Gr.jsx)(gc,{title:(0,zn.__)("Fonts"),className:"font-library-page",children:(0,Gr.jsxs)(Ra,{selectedTabId:t,onSelect:l=>r(l),children:[(0,Gr.jsx)("div",{className:"font-library-page__tablist",children:(0,Gr.jsx)(Ra.TabList,{children:u.map(({id:l,title:c})=>(0,Gr.jsx)(Ra.Tab,{tabId:l,children:c},l))})}),u.map(({id:l})=>(0,Gr.jsx)(Ra.TabPanel,{tabId:l,focusable:!1,className:"font-library-page__tab-panel",children:(0,Gr.jsx)(Nu,{value:n,baseValue:o,onChange:i,activeTab:l})},l))]})})}function IE(){return(0,Gr.jsx)(AE,{})}var LE=IE;export{LE as stage}; /*! Bundled license information: use-sync-external-store/cjs/use-sync-external-store-shim.production.js: From 7ff053bd755f41f56694cb129c9ddc986fc265df Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Tue, 8 Sep 2026 15:58:32 +0000 Subject: [PATCH 160/363] Administration: Ensure the Activity Dashboard widget links are distinguished from surrounding text. Links within blocks of text must be distinguished in a way that does not rely on color. Developed in https://github.com/WordPress/wordpress-develop/pull/13357 Props khokansardar, afercia, joedolson. Fixes #66017. git-svn-id: https://develop.svn.wordpress.org/trunk@63536 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/dashboard.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-admin/css/dashboard.css b/src/wp-admin/css/dashboard.css index 7b0d0fe01c493..09f49cbe4daf9 100644 --- a/src/wp-admin/css/dashboard.css +++ b/src/wp-admin/css/dashboard.css @@ -1066,7 +1066,7 @@ body #dashboard-widgets .postbox form .submit { min-width: 0; } -#dashboard-widgets li a, +#dashboard-widgets li:not(.activity-block li):not(.comment) a, #dashboard-widgets .button-link, .community-events-footer a { text-decoration: none; From 0b05b54fce6dc00b984bd144a5337716aeb5da65 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Tue, 8 Sep 2026 16:22:58 +0000 Subject: [PATCH 161/363] Build/Test Tools: Await post title assertions in E2E tests. Await the title assertions after publishing and quick editing a post so each test waits for its assertion result before completing. Use one-time dialog handlers for application password revocation confirmations. Developed in: https://github.com/WordPress/wordpress-develop/pull/13425 Props adrianmoldovanwp, lucatume. Fixes #66068. git-svn-id: https://develop.svn.wordpress.org/trunk@63537 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/e2e/specs/edit-posts.test.js | 4 ++-- tests/e2e/specs/profile/applications-passwords.test.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/e2e/specs/edit-posts.test.js b/tests/e2e/specs/edit-posts.test.js index 9b8cd37c60e50..b6d600afdebc8 100644 --- a/tests/e2e/specs/edit-posts.test.js +++ b/tests/e2e/specs/edit-posts.test.js @@ -36,7 +36,7 @@ test.describe( 'Edit Posts', () => { await expect( posts ).toHaveCount( 1 ); // Expect the title of the post to be correct. - expect( posts.first() ).toHaveText( title ); + await expect( posts.first() ).toHaveText( title ); } ); test( 'allows an existing post to be edited using the Edit button', async ( { @@ -104,7 +104,7 @@ test.describe( 'Edit Posts', () => { await expect( posts ).toHaveCount( 1 ); // Expect the title of the post to be correct. - expect( posts.first() ).toHaveText( `${ title } Edited` ); + await expect( posts.first() ).toHaveText( `${ title } Edited` ); } ); test( 'allows an existing post to be deleted using the Trash button', async ( { diff --git a/tests/e2e/specs/profile/applications-passwords.test.js b/tests/e2e/specs/profile/applications-passwords.test.js index f6c5cf7a781b7..aa7d2938d2c4f 100644 --- a/tests/e2e/specs/profile/applications-passwords.test.js +++ b/tests/e2e/specs/profile/applications-passwords.test.js @@ -50,7 +50,7 @@ test.describe( 'Manage applications passwords', () => { await expect( revokeButton ).toBeVisible(); // Revoke password. - page.on( 'dialog', ( dialog ) => dialog.accept() ); + page.once( 'dialog', ( dialog ) => dialog.accept() ); await revokeButton.click(); await expect( @@ -73,7 +73,7 @@ test.describe( 'Manage applications passwords', () => { await expect( revokeAllButton ).toBeVisible(); // Confirms revoking action. - page.on( 'dialog', ( dialog ) => dialog.accept() ); + page.once( 'dialog', ( dialog ) => dialog.accept() ); await revokeAllButton.click(); await expect( From 515a891cba4981689718d4d4d623aa845706b5c3 Mon Sep 17 00:00:00 2001 From: Jonathan Desrosiers Date: Tue, 8 Sep 2026 16:40:56 +0000 Subject: [PATCH 162/363] General: Bump the pinned hash for Gutenberg to `5a4cc50`. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This updates the pinned commit hash of the Gutenberg repository from `658c8cbe89db5d90279051d3bb816ca210fe4646 ` (version `23.8.0`) to `5a4cc502d43016f1efa66f8f6d9bd3bb4bb24d85`, which contains the latest changes up until the Node.js version was bumped from 20.x to 24.x. A full list of changes included in this commit can be found on GitHub: https://github.com/WordPress/gutenberg/compare/658c8cbe89db5d90279051d3bb816ca210fe4646..5a4cc502d43016f1efa66f8f6d9bd3bb4bb24d85. - Menu: Stabilize iframe reload test (https://github.com/WordPress/gutenberg/pull/82081) - Packages: Recover August 26 npm release metadata (https://github.com/WordPress/gutenberg/pull/82085) - Storybook: Demonstrate light, dark, and nested themes (https://github.com/WordPress/gutenberg/pull/82039) - Project Management: Add validation for missing GitHub labels configuration (https://github.com/WordPress/gutenberg/pull/76263) - Automated Testing: Enforce `.tsx` for all new React files (https://github.com/WordPress/gutenberg/pull/80123) - UI: Use root theme for portaled overlays (https://github.com/WordPress/gutenberg/pull/82038) - Menu: Stabilize portaled iframe test (https://github.com/WordPress/gutenberg/pull/82092) - Theme: Move post-release changelog entry to Unreleased (https://github.com/WordPress/gutenberg/pull/82093) - Media: Refuse a multi-file drop on a placeholder that takes one file (https://github.com/WordPress/gutenberg/pull/82046) - Font Library: Keep CSS custom properties unquoted in font previews (https://github.com/WordPress/gutenberg/pull/82010) - Add "reading settings" link to Front Page template (https://github.com/WordPress/gutenberg/pull/81987) - Docs: Fix grammar in documentation (https://github.com/WordPress/gutenberg/pull/82032) - Media Editor: refactor the panel layout (https://github.com/WordPress/gutenberg/pull/81840) - DataViews layout storybook: action names and primary status (https://github.com/WordPress/gutenberg/pull/82104) - Make `@wordpress/reusable-blocks` a no-op compatibility package (https://github.com/WordPress/gutenberg/pull/79186) - Widget Dashboard: add a Policy provider to govern what users may do (https://github.com/WordPress/gutenberg/pull/81967) - Build Package: Restore Core Boot layout compatibility (https://github.com/WordPress/gutenberg/pull/82112) - Edit Widgets: Guard canInsertBlockInWidgetArea against an empty block list (https://github.com/WordPress/gutenberg/pull/82107) - Build: Enforce NodeNext resolution for ESM packages (https://github.com/WordPress/gutenberg/pull/82088) - UI: Remove unused outset-ring--focus-within-visible class. (https://github.com/WordPress/gutenberg/pull/82077) - Inserter: Keep the block preview inside the viewport (https://github.com/WordPress/gutenberg/pull/82060) - Test: Enforce Vitest conventions and CI guardrails (https://github.com/WordPress/gutenberg/pull/81040) - Editor: Apply the showListViewByDefault preference in the shared editor (https://github.com/WordPress/gutenberg/pull/82119) - Release: Use CLI runtime for package publishing (https://github.com/WordPress/gutenberg/pull/82122) - Reusable Blocks: Remove leftover merge conflict markers from the changelog (https://github.com/WordPress/gutenberg/pull/82126) - chore: Update grep settings and remove comments (https://github.com/WordPress/gutenberg/pull/82121) - Fix: Content Guidelines: UX/UI Accessibility issues (https://github.com/WordPress/gutenberg/pull/80306) - Extensible Site Editor: Let menu items be added from the navigation screen (https://github.com/WordPress/gutenberg/pull/82125) - Navigation: Change WCText to Text (https://github.com/WordPress/gutenberg/pull/82130) - Storybook: Persist sidebar theme in URL (https://github.com/WordPress/gutenberg/pull/82111) - Editor assets endpoint: prime the theme JSON resolver before capturing (https://github.com/WordPress/gutenberg/pull/82134) - Remove unused dependencies across the monorepo (https://github.com/WordPress/gutenberg/pull/82103) - Update changelog instructions for agents (https://github.com/WordPress/gutenberg/pull/82097) - Build: Normalize JSX file extensions (https://github.com/WordPress/gutenberg/pull/80990) - Fix pattern export filenames by normalizing special characters (https://github.com/WordPress/gutenberg/pull/77033) - Site editor v2: navigation takes view config from endpoint (https://github.com/WordPress/gutenberg/pull/82138) - Extensible Site Editor: Load media assets before the media fields open (https://github.com/WordPress/gutenberg/pull/82135) - Site editor v2: pages take view config from endpoint (https://github.com/WordPress/gutenberg/pull/82140) - Extensible site editor: Add a revisions entry point to the Styles route (https://github.com/WordPress/gutenberg/pull/82142) - List: outdent an empty middle item without adding an item (https://github.com/WordPress/gutenberg/pull/82011) - Extensible site editor: Fall back to the raw title in edit route document titles (https://github.com/WordPress/gutenberg/pull/82143) - Blocks: Make BlockTransform a discriminated union over its type (https://github.com/WordPress/gutenberg/pull/81831) - Theme: add LightningCSS WPDS token fallback plugin (https://github.com/WordPress/gutenberg/pull/80401) - UI: Add popupWidth prop to item popup components (https://github.com/WordPress/gutenberg/pull/82087) - Snackbar: Restart timeout when a notice is recreated (https://github.com/WordPress/gutenberg/pull/81764) - Media: Report server upload failures in plain language (https://github.com/WordPress/gutenberg/pull/81735) - Format library: visualise non-breaking spaces (https://github.com/WordPress/gutenberg/pull/74040) - Bump the github-actions group across 1 directory with 2 updates (https://github.com/WordPress/gutenberg/pull/81932) - Try adding a Grid block variation to Gallery (https://github.com/WordPress/gutenberg/pull/81909) - Components: Keep foreign items out of a ToolsPanel menu (https://github.com/WordPress/gutenberg/pull/82127) - Enable Gallery columns and crop controls in viewport states (https://github.com/WordPress/gutenberg/pull/82003) - Query: Don't write excludeCurrent into blocks that never had it (https://github.com/WordPress/gutenberg/pull/82147) - Site title: Add fit-text support. (https://github.com/WordPress/gutenberg/pull/82074) - Accordion Panel: Reset padding-block when panel is hidden (https://github.com/WordPress/gutenberg/pull/81782) - Replace npm-run-all with native npm script chaining (https://github.com/WordPress/gutenberg/pull/82166) - Grid: per-item tile size limits (https://github.com/WordPress/gutenberg/pull/81899) - Fix: Tabs block: Anchor links in tab panels are not functional (https://github.com/WordPress/gutenberg/pull/81744) - Validate tsconfig references against declared dependencies (https://github.com/WordPress/gutenberg/pull/82106) - Performance tests: Build once and shard the suites across parallel CI jobs (https://github.com/WordPress/gutenberg/pull/82160) - Site Health widget: route the body's review link through the host (https://github.com/WordPress/gutenberg/pull/82066) - Build: allow wp-theme 2.x peer deps (https://github.com/WordPress/gutenberg/pull/82139) - Bundled packages: Add a check for transitive private API usage (https://github.com/WordPress/gutenberg/pull/82027) - List: try to preserve indentation level of children after outdenting+merging their parent (https://github.com/WordPress/gutenberg/pull/82145) - Block Library: Fix categories block handling of invalid taxonomy (https://github.com/WordPress/gutenberg/pull/82153) - useViewConfig: don't request the view config twice (https://github.com/WordPress/gutenberg/pull/82141) - Documentation: Remove invalid references to Babel in packages README (https://github.com/WordPress/gutenberg/pull/82176) - Automated Testing: Fix failing categories test on trunk (https://github.com/WordPress/gutenberg/pull/82182) - Jest: Update to 30.5.0 (https://github.com/WordPress/gutenberg/pull/82181) - Fix: Retain focus and caret position after Backspace undo of a prefix block transform (https://github.com/WordPress/gutenberg/pull/82116) - Scaffold e2e tests for the editor inspector consolidation experiment (https://github.com/WordPress/gutenberg/pull/82178) - Package lock: Deduplicate Jest dependencies (https://github.com/WordPress/gutenberg/pull/82187) - Components: Migrate remaining JSX files to TypeScript (https://github.com/WordPress/gutenberg/pull/82132) - Text: Use pretty wrapping by default (https://github.com/WordPress/gutenberg/pull/82133) - Build Tooling: Add browserslist config for build targeting (https://github.com/WordPress/gutenberg/pull/82179) - Columns: Fix appender drop zone visibility when dragging into empty column (https://github.com/WordPress/gutenberg/pull/77852) - Build: Require explicit JSX file extensions (https://github.com/WordPress/gutenberg/pull/82189) - Icons: Redraw 35 prominent icons with consistent stroke widths (https://github.com/WordPress/gutenberg/pull/78808) - Test: Classify and enforce unit test environments by filename (https://github.com/WordPress/gutenberg/pull/80991) - Test: Fix CI failures on trunk (https://github.com/WordPress/gutenberg/pull/82201) - Fix editor link colour cascade order for nested blocks (https://github.com/WordPress/gutenberg/pull/77833) - Add New Template: Show the design system focus ring instead of legacy box-shadow rings (https://github.com/WordPress/gutenberg/pull/82164) - List View: Don’t focus the last Table cell on keyboard activation (https://github.com/WordPress/gutenberg/pull/81964) - Fix spelling typos in docs and inline comments (https://github.com/WordPress/gutenberg/pull/82217) - CI: Pin npm version in the private API check job (https://github.com/WordPress/gutenberg/pull/82222) - Private APIs: Add back '@wordpress/dataviews' to the allowed core modules (https://github.com/WordPress/gutenberg/pull/82221) - Editor: Mark __unstableSaveForPreview options as optional (https://github.com/WordPress/gutenberg/pull/81858) - Docs: Explain when the Cover block's overlay controls appear (https://github.com/WordPress/gutenberg/pull/82234) - Menu: Use Text for item labels and descriptions (https://github.com/WordPress/gutenberg/pull/82237) - Test: Type pipe's supported array inputs (https://github.com/WordPress/gutenberg/pull/82210) - Widget Dashboard: keep the plain anchor for an empty-string download (https://github.com/WordPress/gutenberg/pull/82073) - CI: Read the required npm version from a single source (https://github.com/WordPress/gutenberg/pull/82235) - Components: Add `defaultShown`, `onShownChange` to `ToolsPanelItem` (https://github.com/WordPress/gutenberg/pull/78010) - Storybook: Drop unused support for js-as-jsx (https://github.com/WordPress/gutenberg/pull/82192) - Math: Declare clientNavigation interactivity support (https://github.com/WordPress/gutenberg/pull/82248) - Point to docmumentation about release assets (https://github.com/WordPress/gutenberg/pull/82250) - Change stray `ubuntu-latest` to `ubuntu-24.04`. (https://github.com/WordPress/gutenberg/pull/82156) - Performance tests: Reuse the plugin an earlier trunk run already built (https://github.com/WordPress/gutenberg/pull/82223) - Breadcrumb: Add UI component (https://github.com/WordPress/gutenberg/pull/80425) - Components: Cut the ToolsPanel render cascade (https://github.com/WordPress/gutenberg/pull/82180) - Fix: alert dialog box cancel button color (https://github.com/WordPress/gutenberg/pull/82261) - UI: Add Form best practices Storybook page (https://github.com/WordPress/gutenberg/pull/82197) - Media: Stop claiming "Upload complete" when upload failed (https://github.com/WordPress/gutenberg/pull/81397) - Boot, Site Editor: Seed content surfaces with default background color (https://github.com/WordPress/gutenberg/pull/81646) - Format Library: Fix Edit as HTML crash with background-only highlight (https://github.com/WordPress/gutenberg/pull/82215) - Remove the template activation experiment (https://github.com/WordPress/gutenberg/pull/82241) - Packages: Add cross-version compatibility skill (https://github.com/WordPress/gutenberg/pull/81890) - Show the block outline where the grab cursor shows (https://github.com/WordPress/gutenberg/pull/81798) - DataViews: Scope the search field's fixed width to the default UI search row (https://github.com/WordPress/gutenberg/pull/82128) - Background image: support setting the image from a URL (https://github.com/WordPress/gutenberg/pull/82230) - Border Box Control: Try moving the unlink button to the label row, and rename the panel to Borders (https://github.com/WordPress/gutenberg/pull/82163) - Widget Dashboard: govern Reset to default through the policy (https://github.com/WordPress/gutenberg/pull/82255) - Media: Attach unattached media to the current post on save/publish (https://github.com/WordPress/gutenberg/pull/81977) - Widget Dashboard: make the column count a host decision (https://github.com/WordPress/gutenberg/pull/82204) - Global styles: resolve theme-relative background image URLs for display (https://github.com/WordPress/gutenberg/pull/82242) - CI: Unify the automation comments into a single PR comment (https://github.com/WordPress/gutenberg/pull/82249) - Core Data: Convert hooks tests to renderHook and drop JSX (https://github.com/WordPress/gutenberg/pull/82276) - Release: Map [Type] Flaky Test to the Tools changelog section (https://github.com/WordPress/gutenberg/pull/82078) - DateTime tests: freeze the clock in the empty-value calendar test (https://github.com/WordPress/gutenberg/pull/82282) - DataForm: treat combined form fields purely as layout containers (https://github.com/WordPress/gutenberg/pull/82175) - Global styles engine: return a copy from getResolvedValue instead of mutating (https://github.com/WordPress/gutenberg/pull/82278) - Test: Migrate Node unit tests to Vitest (https://github.com/WordPress/gutenberg/pull/82211) - Icons: Redraw 64 icons to be stroke-based. (https://github.com/WordPress/gutenberg/pull/78812) - Tests: Fix Vitest setup and stale jest types under non-hoisting installs (https://github.com/WordPress/gutenberg/pull/82290) - UI: Rename Popup `popupWidth` prop to `width` (https://github.com/WordPress/gutenberg/pull/82193) - Query: Replace the "Reload full page enabled" modal with a snackbar notice (https://github.com/WordPress/gutenberg/pull/82246) - Project Management: Update CODEOWNERS to reflect current participation (https://github.com/WordPress/gutenberg/pull/82262) - Editor: Refactor the Options menu to use the Menu component (https://github.com/WordPress/gutenberg/pull/81564) - UI: Add Field.VisualLabel (https://github.com/WordPress/gutenberg/pull/82095) - Update Stylelint to v17 and related packages (https://github.com/WordPress/gutenberg/pull/80738) - Media: keep indexed PNG sub-sizes indexed (https://github.com/WordPress/gutenberg/pull/81884) - UI: Add Combobox and Autocomplete Status (https://github.com/WordPress/gutenberg/pull/82195) - UI: Drop Status and Empty live region test assertions (https://github.com/WordPress/gutenberg/pull/82300) - Project Management: Remove empty entries from CODEOWNERS (https://github.com/WordPress/gutenberg/pull/82292) - Documentation: Add recommended bulk suppressions configuration for ESLint (https://github.com/WordPress/gutenberg/pull/82303) - UI: Hide Input field ring when a slot control is focused (https://github.com/WordPress/gutenberg/pull/82257) - Widgets: Surface debugging details in the ErrorBoundary (https://github.com/WordPress/gutenberg/pull/82099) - TypeScript: Migrate format-library package to TS (https://github.com/WordPress/gutenberg/pull/79486) - BorderBoxControl: Make sure the group of controls is associated with the label (https://github.com/WordPress/gutenberg/pull/82279) - Image block cropping: Sync image size and link destination settings (https://github.com/WordPress/gutenberg/pull/82316) - Menu: Support multiple item descriptions (https://github.com/WordPress/gutenberg/pull/81825) - CI: Do not fail the type label check on a newly opened pull request (https://github.com/WordPress/gutenberg/pull/82322) - UI: Align overlay Trigger props with Base UI (https://github.com/WordPress/gutenberg/pull/81824) - Gallery block: Fix 'Crop images to fit' broken in editor (https://github.com/WordPress/gutenberg/pull/82318) - Widget Dashboard: enforce the policy on the staging layer for every instance operation (https://github.com/WordPress/gutenberg/pull/82256) - DataForm: Communicate the timezone in the datetime control (https://github.com/WordPress/gutenberg/pull/82291) - Add more e2e tests for the editor inspector consolidation experiment (https://github.com/WordPress/gutenberg/pull/82239) - Framework: Error on npm versions older than the required floor (https://github.com/WordPress/gutenberg/pull/82320) - Document every type for DataViews/DataForm/Field API (https://github.com/WordPress/gutenberg/pull/82326) - ESLint plugin: remove usage of Babel parser (https://github.com/WordPress/gutenberg/pull/82144) - DataViews: remove the rich text options from the control config type (https://github.com/WordPress/gutenberg/pull/82330) - Meta Boxes: Move meta box markup with moveBefore to keep classic editors alive (https://github.com/WordPress/gutenberg/pull/82243) - Add more e2e tests for the editor inspector consolidation experiment (https://github.com/WordPress/gutenberg/pull/82327) - Test: Enforce JavaScript test runner ownership (https://github.com/WordPress/gutenberg/pull/82299) - DataViews: clamp page after delete (https://github.com/WordPress/gutenberg/pull/82244) - Stylelint tools: Resolve test config extends from the workspace (https://github.com/WordPress/gutenberg/pull/82336) - Editor: Deprecate the `as` prop of the plugin menu item components (https://github.com/WordPress/gutenberg/pull/82319) - Icons: Convert Search icon to strokes (https://github.com/WordPress/gutenberg/pull/82338) - DataViews: Document that table column styles do not apply to the primary column (https://github.com/WordPress/gutenberg/pull/82238) - DataViews: add hierarchical levels story (https://github.com/WordPress/gutenberg/pull/82344) - CI: Add "Required changes from trunk" PR check (https://github.com/WordPress/gutenberg/pull/82272) - feat: Improve TypeScript definitions in the getEntityRecord function (https://github.com/WordPress/gutenberg/pull/81863) - Framework: Update Node.js to v24 LTS and npm to v11 (https://github.com/WordPress/gutenberg/pull/80395) - Revert "Framework: Update Node.js to v24 LTS and npm to v11 (https://github.com/WordPress/gutenberg/pull/80395)" (https://github.com/WordPress/gutenberg/pull/82355) - UI: Remove ValidityIndicator outer margin (https://github.com/WordPress/gutenberg/pull/82267) - Span the writing flow focus capture elements over the canvas (https://github.com/WordPress/gutenberg/pull/82354) - Fields: Hide the slug field for posts without a permalink (https://github.com/WordPress/gutenberg/pull/82341) - Fix: Responsive horizontal orientation does not override a vertical layout. (https://github.com/WordPress/gutenberg/pull/82364) - View Config: Move the table column style descriptions to the 7.2 compat layer (https://github.com/WordPress/gutenberg/pull/82372) - Block Library: Allow themes to override the padding added via background color (https://github.com/WordPress/gutenberg/pull/82024) - DataViews: Append an ellipsis to action labels that open a dialog (https://github.com/WordPress/gutenberg/pull/81994) - Pages: require authentication and a capability to render generated standalone pages (https://github.com/WordPress/gutenberg/pull/82254) - Build/Test Tools: Replace npx with npm exec --no (https://github.com/WordPress/gutenberg/pull/82331) - Navigation: restore flex-grow on container when accessible label is present (https://github.com/WordPress/gutenberg/pull/78447) - DOM Ready: Exclude src from published package files (https://github.com/WordPress/gutenberg/pull/77302) - UI: Support custom targets on Link and Menu.LinkItem (https://github.com/WordPress/gutenberg/pull/82347) - Escape HTML: Exclude src from published package files (https://github.com/WordPress/gutenberg/pull/77304) - keycodes: Exclude src from published files (https://github.com/WordPress/gutenberg/pull/77306) - Packages: Exclude src from block-serialization-default-parser published package (https://github.com/WordPress/gutenberg/pull/77307) - A11y: Exclude src from published package files (https://github.com/WordPress/gutenberg/pull/77309) - Packages: Exclude src from autop published package (https://github.com/WordPress/gutenberg/pull/77283) - Blob: Exclude src from published package files (https://github.com/WordPress/gutenberg/pull/77289) - Packages: Exclude src from deprecated published package (https://github.com/WordPress/gutenberg/pull/77303) - fix(list-reusable-blocks): exclude src from published files (https://github.com/WordPress/gutenberg/pull/77305) - Admin UI: Exclude src from published files and sideEffects (https://github.com/WordPress/gutenberg/pull/77285) - Standardize 'Back' and 'Go back' labels (https://github.com/WordPress/gutenberg/pull/79211) - Audio: Update autoplay help text for clarity (https://github.com/WordPress/gutenberg/pull/69978) - Theme JSON: Avoid rebuilding identical block schemas during sanitization (https://github.com/WordPress/gutenberg/pull/82203) - Docs: Improve setAttributes updater function wording (https://github.com/WordPress/gutenberg/pull/82405) - Query Loop: Rename the "Keyword" filter to "Search terms" and add help text (https://github.com/WordPress/gutenberg/pull/82387) - CI: add a per-workflow status check job and filter paths (https://github.com/WordPress/gutenberg/pull/81015) - ESLint: Thin use-recommended-components tests (https://github.com/WordPress/gutenberg/pull/82407) - UI: Fix enabled input placeholder contrast (https://github.com/WordPress/gutenberg/pull/82304) - Tab trap escape hatch: leave/enter the canvas with Escape/Enter (https://github.com/WordPress/gutenberg/pull/82314) - List: preserve client IDs on indent, just like outdent (https://github.com/WordPress/gutenberg/pull/59216) - Templates REST API: prevent fatal error when a null template reaches prepare_item_for_response (https://github.com/WordPress/gutenberg/pull/82374) - Editor: Refactor the View menu to use the Menu component (https://github.com/WordPress/gutenberg/pull/82321) - CSS Styling: Cleanup focus outline override for grid component (https://github.com/WordPress/gutenberg/pull/82337) - E2E: Run the site editor suite against the extensible site editor too (https://github.com/WordPress/gutenberg/pull/82117) - Fields: Remove unused CSS rule from slug field control (https://github.com/WordPress/gutenberg/pull/77961) - Fix: Footnote IDs can start with a digit and break CSS selectors (https://github.com/WordPress/gutenberg/pull/82398) - feat: Introduce 'Add Media' in the block controls for media-text block (https://github.com/WordPress/gutenberg/pull/82420) - fix: Audio element to have it's own name (https://github.com/WordPress/gutenberg/pull/82389) - Docs: Update Playground CLI wording (https://github.com/WordPress/gutenberg/pull/77579) - Upgrade React 19 to 19.2.8, read version from package.json (https://github.com/WordPress/gutenberg/pull/82439) - Tab Panel: Show focus with outline instead of legacy box-shadow ring (https://github.com/WordPress/gutenberg/pull/82421) - Editor: Fix disabled and link items of the more menu adapter (https://github.com/WordPress/gutenberg/pull/82428) - UI: Fix Menu.LinkItem target detection (https://github.com/WordPress/gutenberg/pull/82442) - SearchableSelect: Add form primitive to @wordpress/ui (https://github.com/WordPress/gutenberg/pull/80961) - Validated form controls: Use design token for invalid focus rings (https://github.com/WordPress/gutenberg/pull/82410) - feat: Update layout icons (https://github.com/WordPress/gutenberg/pull/82025) - Widgets: Replace {TODO} placeholder with PR number in changelog entries (https://github.com/WordPress/gutenberg/pull/82450) - UI: Remove ESLint ref suppressions and refactor AlertDialog state (https://github.com/WordPress/gutenberg/pull/82131) - Menu: Align selection indicators and prefix icons with item labels (https://github.com/WordPress/gutenberg/pull/82346) - ToggleGroupControl: Honor the root disabled prop (https://github.com/WordPress/gutenberg/pull/82259) - Block Library: Remove the form blocks experiment (https://github.com/WordPress/gutenberg/pull/82451) - List: indent and outdent multi-selected items with Tab (https://github.com/WordPress/gutenberg/pull/82411) - CodeRabbit: Only review on request, keep PR descriptions untouched (https://github.com/WordPress/gutenberg/pull/82448) - Privacy policy page badge: make it visible in Site Editor > Pages and Editor Inspector (https://github.com/WordPress/gutenberg/pull/82422) - Support `isAny` and `isNone` filter operators for numeric fields. (https://github.com/WordPress/gutenberg/pull/77942) - UI: Keep focus rings visible in overlay content (https://github.com/WordPress/gutenberg/pull/82443) - Menu: Correct alignment documentation and changelog (https://github.com/WordPress/gutenberg/pull/82455) - UI: Name unlabeled form primitive stories (https://github.com/WordPress/gutenberg/pull/82311) - UI: Re-read the native validity on blur in ControlWithError (https://github.com/WordPress/gutenberg/pull/82376) - Media Utils: Preserve arrays in multipart form data (https://github.com/WordPress/gutenberg/pull/82353) - fix: Remove stories from performance tests (https://github.com/WordPress/gutenberg/pull/82459) - Add the template e2e tests for the editor inspector consolidation experiment (https://github.com/WordPress/gutenberg/pull/82394) - UI: Fix Link target detection (https://github.com/WordPress/gutenberg/pull/82447) - Fix privacy policy page setting unit test on multisite (https://github.com/WordPress/gutenberg/pull/82467) - UI, DataViews: Give input and selection controls solid backgrounds (https://github.com/WordPress/gutenberg/pull/82391) - Fix LocationPicker popover alignment with InputGroup (https://github.com/WordPress/gutenberg/pull/82090) - List: indent and outdent a fully selected list item with Tab (https://github.com/WordPress/gutenberg/pull/82460) - UI: Fix Minimal Select popup width (https://github.com/WordPress/gutenberg/pull/82461) - Rich text: resolve owned event listeners once instead of per subscriber (https://github.com/WordPress/gutenberg/pull/80605) - UI: Keep borderless InputLayout chrome when disabled (https://github.com/WordPress/gutenberg/pull/82468) - Theme: Cache luminance for contrast checks (https://github.com/WordPress/gutenberg/pull/82445) - Add promptfoo for testing agent development setup and skills (https://github.com/WordPress/gutenberg/pull/80812) - wp-env: Fix Docker build errors with Debian Bullseye repositories (https://github.com/WordPress/gutenberg/pull/82478) - Query Loop: Fall back to `post` when the query has no `postType` (https://github.com/WordPress/gutenberg/pull/82465) - Block Supports: Bail early in state styles when a block has no style attribute (https://github.com/WordPress/gutenberg/pull/81908) - CSS Styling: Represent focus with outline for list view component (https://github.com/WordPress/gutenberg/pull/82129) - Icons: Remove the obsolete forced colors mode hack (https://github.com/WordPress/gutenberg/pull/82481) - Docs: Remove invalid `@return` tag from the `block_core_social_link_get_services` hook docblock (https://github.com/WordPress/gutenberg/pull/82488) - Site Editor: Add a root error boundary to prevent a blank screen (https://github.com/WordPress/gutenberg/pull/82486) - Writing Flow: Bail out of Enter handling when no block is selected (https://github.com/WordPress/gutenberg/pull/82424) - Docs: Remove the blank line between @param and @return in test docblocks (https://github.com/WordPress/gutenberg/pull/81907) - List View: Disable block icon colors while the block is selected (https://github.com/WordPress/gutenberg/pull/82498) - Fix: Restore layout styles for block style variations (https://github.com/WordPress/gutenberg/pull/82335) - Post slug: prefer server sanitization in the editor (https://github.com/WordPress/gutenberg/pull/78135) - Media Modal Experiment: Allow filtering by attached to the post, or unattached (https://github.com/WordPress/gutenberg/pull/81974) - Media editor: Lock the editing tools while a save is running (https://github.com/WordPress/gutenberg/pull/82417) - DataViews: Restrict the isAll filter operator to array fields (https://github.com/WordPress/gutenberg/pull/82463) - Media Fields: Pass the field's disabled state to the textarea controls (https://github.com/WordPress/gutenberg/pull/82516) - Theme: Make chroma capacity caching deterministic (https://github.com/WordPress/gutenberg/pull/82505) - Global Styles: Remove the color randomizer experiment (https://github.com/WordPress/gutenberg/pull/82452) - DataViews: Fix Field.sort TypeScript type definition (https://github.com/WordPress/gutenberg/pull/82162) - Migrate __experimentalText and __experimentalHeading to @wordpress/ui Text in Inspector Popover Header (https://github.com/WordPress/gutenberg/pull/77449) - Migrate __experimentalText to @wordpress/ui Text in Block switcher bindings hint (https://github.com/WordPress/gutenberg/pull/77366) - UI: Add Radio form primitive (https://github.com/WordPress/gutenberg/pull/82214) - Migrate __experimentalText to @wordpress/ui Text in Allowed Blocks Modal (https://github.com/WordPress/gutenberg/pull/78119) - UI: Add CheckboxControl (https://github.com/WordPress/gutenberg/pull/82213) - Core Data: Scope revisionId to the entity it is provided for (https://github.com/WordPress/gutenberg/pull/82517) - Migrate __experimentalText to @wordpress/ui Text in Pattern Overrides Dropdown (https://github.com/WordPress/gutenberg/pull/77492) - ProgressBar: Respect reduced motion preferences (https://github.com/WordPress/gutenberg/pull/82490) - Theme: Clarify color seed and warning guarantees (https://github.com/WordPress/gutenberg/pull/82526) - Theme: Build default ramps before token artifacts (https://github.com/WordPress/gutenberg/pull/82525) - CodeRabbit: Disable the review status comment (https://github.com/WordPress/gutenberg/pull/82534) - Project Management: Restore CODEOWNERS exclusions for suppression lists (https://github.com/WordPress/gutenberg/pull/82538) - Editor: merge duplicate "Enhancements" changelog sections (https://github.com/WordPress/gutenberg/pull/82533) - UI: Validate compound component context (https://github.com/WordPress/gutenberg/pull/82510) - Docs: Document isolated worktree setup (https://github.com/WordPress/gutenberg/pull/82524) - DataForm: render untyped fields without an edit control that are read-only (https://github.com/WordPress/gutenberg/pull/82514) - API Fetch: Add unregister to remove a registered middleware (https://github.com/WordPress/gutenberg/pull/82408) - Editor: Show revision data in Post Title component (https://github.com/WordPress/gutenberg/pull/82536) - Components: Add compound component composition diagnostics (https://github.com/WordPress/gutenberg/pull/82509) - Fieldset: Fix gap token to match spec (https://github.com/WordPress/gutenberg/pull/75479) - Test: Migrate deterministic JSDOM tests and harden Vitest isolation (https://github.com/WordPress/gutenberg/pull/82212) - Release: Make npm publication verification resumable (https://github.com/WordPress/gutenberg/pull/82089) - Block Library: Use 'useEntityProp' in Site Title and Tagline blocks (https://github.com/WordPress/gutenberg/pull/82518) - Theme: Migrate Terrazzo modes to resolvers (https://github.com/WordPress/gutenberg/pull/82537) - Fix auto-capitalization after Enter on iOS Safari (https://github.com/WordPress/gutenberg/pull/82475) - Update navigation link block name, use a default variation for custom link (https://github.com/WordPress/gutenberg/pull/82375) - API Fetch: Expose defaultFetchHandler so overrides can restore it (https://github.com/WordPress/gutenberg/pull/82553) - Core Data: Return a stable record for equivalent `_fields` queries (https://github.com/WordPress/gutenberg/pull/82552) - API Fetch: Rename defaultFetchHandler parameter to options (https://github.com/WordPress/gutenberg/pull/82588) - Fields: remove unused custom sort from the author fields (https://github.com/WordPress/gutenberg/pull/82559) - Fields: Declare the caption, alt text, description and ping status controls through the Field API (https://github.com/WordPress/gutenberg/pull/82539) - Docs: Align @param tag columns in phpunit/ docblocks (https://github.com/WordPress/gutenberg/pull/81904) - Docs: Align @param tag columns in lib/ docblocks (https://github.com/WordPress/gutenberg/pull/81902) - Docs: Align @param tag columns in packages/ docblocks (https://github.com/WordPress/gutenberg/pull/81903) - Fix help paragraph color contrast ratio in the Connectors page. (https://github.com/WordPress/gutenberg/pull/82378) - DataViews: Declare transitive dependencies imported by the ./wp bundle (https://github.com/WordPress/gutenberg/pull/81843) - DataForm: Add a `showPlaceholderIfEmpty` option to the panel layout (https://github.com/WordPress/gutenberg/pull/82527) - Global Styles UI: migrate revisions Active Badge to UI Badge (https://github.com/WordPress/gutenberg/pull/82560) - UI: Put overflow on Select.List instead of a nested wrapper (https://github.com/WordPress/gutenberg/pull/82470) - Editor: migrate post-card-panel Badge to UI Badge (https://github.com/WordPress/gutenberg/pull/82500) - Fields: migrate page-title Badge to UI Badge (https://github.com/WordPress/gutenberg/pull/82499) - DataViews: Skip table columns for field ids without a field definition (https://github.com/WordPress/gutenberg/pull/82601) - View config: remove stale fields from the wp_template default view (https://github.com/WordPress/gutenberg/pull/82602) - Rich text: restore contenteditable on pointercancel (https://github.com/WordPress/gutenberg/pull/82598) - Components: Add an Emotion-to-SCSS migration skill and guide (https://github.com/WordPress/gutenberg/pull/82567) See #66070. git-svn-id: https://develop.svn.wordpress.org/trunk@63538 602fd350-edb4-49c9-b593-d223f7449a82 --- package.json | 2 +- .../assets/script-loader-packages.php | 58 +- .../assets/script-modules-packages.php | 18 +- src/wp-includes/blocks/accordion-item.php | 2 +- src/wp-includes/blocks/accordion.php | 4 +- src/wp-includes/blocks/blocks-json.php | 13 +- src/wp-includes/blocks/breadcrumbs.php | 8 +- src/wp-includes/blocks/categories.php | 4 + src/wp-includes/blocks/comment-template.php | 4 +- src/wp-includes/blocks/gallery.php | 290 +++-- src/wp-includes/blocks/gallery/block.json | 7 +- src/wp-includes/blocks/heading.php | 2 +- src/wp-includes/blocks/home-link.php | 4 +- src/wp-includes/blocks/icon.php | 24 +- src/wp-includes/blocks/list.php | 2 +- src/wp-includes/blocks/math/block.json | 3 + src/wp-includes/blocks/navigation-link.php | 10 +- .../blocks/navigation-link/block.json | 2 +- src/wp-includes/blocks/navigation.php | 28 +- src/wp-includes/blocks/page-list.php | 20 +- .../blocks/post-author-biography.php | 6 +- src/wp-includes/blocks/post-author-name.php | 6 +- src/wp-includes/blocks/post-author.php | 6 +- src/wp-includes/blocks/post-comments-link.php | 8 +- src/wp-includes/blocks/post-content.php | 2 +- src/wp-includes/blocks/post-time-to-read.php | 6 +- src/wp-includes/blocks/query.php | 4 +- src/wp-includes/blocks/read-more.php | 2 +- src/wp-includes/blocks/search.php | 2 +- src/wp-includes/blocks/site-logo.php | 2 +- src/wp-includes/blocks/site-title/block.json | 1 + src/wp-includes/blocks/social-link.php | 1 - src/wp-includes/blocks/tab-list.php | 4 +- src/wp-includes/blocks/tabs.php | 3 +- src/wp-includes/blocks/widget-group.php | 6 +- src/wp-includes/build/constants.php | 2 +- .../pages/font-library/page-wp-admin.php | 8 +- .../build/pages/font-library/page.php | 16 + .../options-connectors/page-wp-admin.php | 8 +- .../build/pages/options-connectors/page.php | 16 + .../build/routes/connectors-home/content.js | 1009 +++++++++-------- .../connectors-home/content.min.asset.php | 2 +- .../routes/connectors-home/content.min.js | 2 +- .../build/routes/font-list/content.js | 597 +++++----- .../routes/font-list/content.min.asset.php | 2 +- .../build/routes/font-list/content.min.js | 10 +- .../images/icon-library/arrow-down-left.svg | 4 +- .../images/icon-library/arrow-down-right.svg | 4 +- .../images/icon-library/arrow-down.svg | 4 +- .../images/icon-library/arrow-left.svg | 4 +- .../images/icon-library/arrow-right.svg | 4 +- .../images/icon-library/arrow-up-left.svg | 4 +- .../images/icon-library/arrow-up-right.svg | 4 +- .../images/icon-library/arrow-up.svg | 4 +- .../images/icon-library/block-meta.svg | 4 +- .../images/icon-library/category.svg | 7 +- .../images/icon-library/caution.svg | 4 +- .../images/icon-library/chart-bar.svg | 4 +- src/wp-includes/images/icon-library/check.svg | 4 +- .../icon-library/chevron-down-small.svg | 4 +- .../images/icon-library/chevron-down.svg | 4 +- .../icon-library/chevron-left-small.svg | 4 +- .../images/icon-library/chevron-left.svg | 4 +- .../icon-library/chevron-right-small.svg | 4 +- .../images/icon-library/chevron-right.svg | 4 +- .../images/icon-library/chevron-up-down.svg | 4 +- .../images/icon-library/chevron-up-small.svg | 4 +- .../images/icon-library/chevron-up.svg | 4 +- src/wp-includes/images/icon-library/cover.svg | 5 +- .../images/icon-library/create.svg | 4 +- .../images/icon-library/download.svg | 4 +- src/wp-includes/images/icon-library/help.svg | 5 +- src/wp-includes/images/icon-library/image.svg | 4 +- src/wp-includes/images/icon-library/info.svg | 4 +- src/wp-includes/images/icon-library/menu.svg | 4 +- src/wp-includes/images/icon-library/next.svg | 4 +- .../images/icon-library/paragraph.svg | 5 +- .../images/icon-library/plus-circle.svg | 5 +- src/wp-includes/images/icon-library/plus.svg | 4 +- .../images/icon-library/previous.svg | 4 +- .../images/icon-library/published.svg | 5 +- src/wp-includes/images/icon-library/rss.svg | 5 +- .../images/icon-library/scheduled.svg | 5 +- .../images/icon-library/search.svg | 4 +- .../images/icon-library/star-empty.svg | 4 +- .../images/icon-library/star-filled.svg | 4 +- .../images/icon-library/star-half.svg | 5 +- .../images/icon-library/styles.svg | 5 +- src/wp-includes/images/icon-library/tip.svg | 4 +- .../images/icon-library/upload.svg | 4 +- 90 files changed, 1291 insertions(+), 1133 deletions(-) diff --git a/package.json b/package.json index 8158bc2ee96f6..7c9e99a625534 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "url": "https://develop.svn.wordpress.org/trunk" }, "gutenberg": { - "sha": "658c8cbe89db5d90279051d3bb816ca210fe4646", + "sha": "5a4cc502d43016f1efa66f8f6d9bd3bb4bb24d85", "ghcrRepo": "WordPress/gutenberg/gutenberg-wp-develop-build" }, "engines": { diff --git a/src/wp-includes/assets/script-loader-packages.php b/src/wp-includes/assets/script-loader-packages.php index 84e2e5c25f3b2..c6a755c4e2a0a 100644 --- a/src/wp-includes/assets/script-loader-packages.php +++ b/src/wp-includes/assets/script-loader-packages.php @@ -21,7 +21,7 @@ 'wp-private-apis', 'wp-url' ), - 'version' => '6f2a4faeee3c722b1e57' + 'version' => '5cae250de64a68ada734' ), 'autop.js' => array( 'dependencies' => array( @@ -67,7 +67,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '251bed20addbd4898951' + 'version' => '24621af54a8dc0a92a8e' ), 'block-editor.js' => array( 'dependencies' => array( @@ -105,7 +105,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '03664008984afcc5acd9' + 'version' => 'bb7e4c9d559d1e395318' ), 'block-library.js' => array( 'dependencies' => array( @@ -151,7 +151,7 @@ 'import' => 'dynamic' ) ), - 'version' => '98b1e389bb9bedd78731' + 'version' => '8e0f81358a96113469a4' ), 'block-serialization-default-parser.js' => array( 'dependencies' => array( @@ -184,7 +184,7 @@ 'wp-shortcode', 'wp-warning' ), - 'version' => '4f4d0c2b0372d76cb1cf' + 'version' => '49562ec003979bd1595c' ), 'commands.js' => array( 'dependencies' => array( @@ -201,7 +201,7 @@ 'wp-primitives', 'wp-private-apis' ), - 'version' => '709b81f6965aa3f3fad1' + 'version' => '3df8385dbb6e2a481531' ), 'components.js' => array( 'dependencies' => array( @@ -226,7 +226,7 @@ 'wp-theme', 'wp-warning' ), - 'version' => '7d125f63c887366dc3c5' + 'version' => '5b148bfc313b70dc9a4b' ), 'compose.js' => array( 'dependencies' => array( @@ -283,7 +283,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '09960f621ea22390d652' + 'version' => '168b7542169d2fde8357' ), 'customize-widgets.js' => array( 'dependencies' => array( @@ -319,7 +319,7 @@ 'import' => 'static' ) ), - 'version' => 'b63345eff7801e61c8d8' + 'version' => '2483be73e6c08b1b7857' ), 'data.js' => array( 'dependencies' => array( @@ -410,7 +410,7 @@ 'import' => 'static' ) ), - 'version' => '1879e16de755e7c0c695' + 'version' => '585373eb7cbed3a73194' ), 'edit-site.js' => array( 'dependencies' => array( @@ -459,7 +459,7 @@ 'import' => 'static' ) ), - 'version' => '251e0a5d7d1c24545199' + 'version' => '0ed65d6f92588618d88d' ), 'edit-widgets.js' => array( 'dependencies' => array( @@ -501,7 +501,7 @@ 'import' => 'static' ) ), - 'version' => 'aa6a14fc303abfc52e8c' + 'version' => '3d65e74685d1cddb700a' ), 'editor.js' => array( 'dependencies' => array( @@ -552,7 +552,7 @@ 'import' => 'static' ) ), - 'version' => 'b3fca63dd478300ba9a3' + 'version' => 'ca21417bde93de2233f3' ), 'element.js' => array( 'dependencies' => array( @@ -594,7 +594,7 @@ 'import' => 'dynamic' ) ), - 'version' => '7bb348819bb9bb6642b1' + 'version' => '255ba1a7c73110ccd6b2' ), 'hooks.js' => array( 'dependencies' => array( @@ -645,7 +645,7 @@ 'wp-element', 'wp-i18n' ), - 'version' => '68a57d388ce085b9691e' + 'version' => 'da035ad6b481354267f8' ), 'media-utils.js' => array( 'dependencies' => array( @@ -672,7 +672,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '957851f36fe387c2272e' + 'version' => 'ae94af80c12fd82c2a18' ), 'notices.js' => array( 'dependencies' => array( @@ -711,7 +711,7 @@ 'wp-url', 'wp-warning' ), - 'version' => '74662e7976508e52fa17' + 'version' => '10c0f0e7da90fc1de354' ), 'plugins.js' => array( 'dependencies' => array( @@ -739,7 +739,7 @@ 'wp-primitives', 'wp-private-apis' ), - 'version' => '4d5774967128e9bf2193' + 'version' => 'f7e32b791afe5c65affa' ), 'preferences-persistence.js' => array( 'dependencies' => array( @@ -764,7 +764,7 @@ 'dependencies' => array( ), - 'version' => '91c41cc1d8b79a320132' + 'version' => 'df3615fd5cb379fb7ffe' ), 'react-i18n.js' => array( 'dependencies' => array( @@ -782,20 +782,10 @@ ), 'reusable-blocks.js' => array( 'dependencies' => array( - 'react-jsx-runtime', - 'wp-block-editor', - 'wp-blocks', - 'wp-components', - 'wp-core-data', 'wp-data', - 'wp-deprecated', - 'wp-element', - 'wp-i18n', - 'wp-notices', - 'wp-primitives', - 'wp-url' + 'wp-deprecated' ), - 'version' => 'dd1bd3b09f7d73c21d0e' + 'version' => 'fd62928dce12a860a327' ), 'rich-text.js' => array( 'dependencies' => array( @@ -810,7 +800,7 @@ 'wp-keycodes', 'wp-private-apis' ), - 'version' => '3e5852e42cee1c239bae' + 'version' => '7f83233b1caefc2146bb' ), 'router.js' => array( 'dependencies' => array( @@ -864,7 +854,7 @@ 'wp-element', 'wp-private-apis' ), - 'version' => '763f42e590ad17dfa74c' + 'version' => '3543b084ef1597ce5852' ), 'token-list.js' => array( 'dependencies' => array( @@ -899,7 +889,7 @@ 'import' => 'dynamic' ) ), - 'version' => 'f7174b0617bcd68e57c3' + 'version' => '996352700f53b76866a5' ), 'url.js' => array( 'dependencies' => array( diff --git a/src/wp-includes/assets/script-modules-packages.php b/src/wp-includes/assets/script-modules-packages.php index b13e153a0fad4..38fcd0e5821fa 100644 --- a/src/wp-includes/assets/script-modules-packages.php +++ b/src/wp-includes/assets/script-modules-packages.php @@ -48,12 +48,6 @@ ), 'version' => 'a9114a756e418400594c' ), - 'block-library/form/view.js' => array( - 'dependencies' => array( - - ), - 'version' => '5542f8ad251fe43ef09e' - ), 'block-library/image/view.js' => array( 'dependencies' => array( @@ -128,7 +122,7 @@ 'import' => 'static' ) ), - 'version' => '92c832aff6e4039db1ce' + 'version' => '0684c8bb3dc8582b92ea' ), 'boot/index.js' => array( 'dependencies' => array( @@ -168,7 +162,7 @@ 'import' => 'static' ) ), - 'version' => '8cc5f2c749590d7b592a' + 'version' => '561d400a81b4d92e0ab6' ), 'connectors/index.js' => array( 'dependencies' => array( @@ -225,7 +219,7 @@ 'import' => 'static' ) ), - 'version' => 'f6fe09cfa8a820e494b9' + 'version' => 'cbb305a20ffe909edb3f' ), 'interactivity/index.js' => array( 'dependencies' => array( @@ -293,7 +287,7 @@ 'wp-private-apis', 'wp-style-engine' ), - 'version' => '26702529626be08dab3c' + 'version' => '68563009a3346a87bfa0' ), 'route/index.js' => array( 'dependencies' => array( @@ -338,7 +332,7 @@ 'dependencies' => array( ), - 'version' => '685442d334b2d3e70832' + 'version' => '7e33cd8c4128731126e8' ), 'widget-primitives/index.js' => array( 'dependencies' => array( @@ -370,6 +364,6 @@ 'import' => 'dynamic' ) ), - 'version' => '090d73e88a5ee2c08223' + 'version' => '7a2d585edd951178791a' ) ); \ No newline at end of file diff --git a/src/wp-includes/blocks/accordion-item.php b/src/wp-includes/blocks/accordion-item.php index 0b83c3a8d04bd..1bda149d97dd0 100644 --- a/src/wp-includes/blocks/accordion-item.php +++ b/src/wp-includes/blocks/accordion-item.php @@ -7,7 +7,7 @@ * @since 6.9.0 * * @param array{ openByDefault: bool } $attributes The block attributes. - * @param string $content The block content. + * @param string $content The block content. * @return string Returns the updated markup. */ function block_core_accordion_item_render( array $attributes, string $content ): string { diff --git a/src/wp-includes/blocks/accordion.php b/src/wp-includes/blocks/accordion.php index 537904a6e402d..a840fe7dfed69 100644 --- a/src/wp-includes/blocks/accordion.php +++ b/src/wp-includes/blocks/accordion.php @@ -5,8 +5,8 @@ * @package WordPress * @since 6.9.0 * - * @param array $attributes The block attributes. - * @param string $content The block content. + * @param array $attributes The block attributes. + * @param string $content The block content. * * @return string Returns the updated markup. */ diff --git a/src/wp-includes/blocks/blocks-json.php b/src/wp-includes/blocks/blocks-json.php index 208e13036dd6c..1db9063e0b42b 100644 --- a/src/wp-includes/blocks/blocks-json.php +++ b/src/wp-includes/blocks/blocks-json.php @@ -2838,7 +2838,12 @@ 'layout' => array( 'allowSwitching' => false, 'allowInheriting' => false, - 'allowEditing' => false, + 'allowEditing' => true, + 'allowOrientation' => false, + 'allowJustification' => false, + 'allowVerticalAlignment' => false, + 'allowWrap' => false, + 'allowSizingOnChildren' => true, 'default' => array( 'type' => 'flex' ) @@ -3935,6 +3940,9 @@ '__experimentalDefaultControls' => array( 'fontSize' => true ) + ), + 'interactivity' => array( + 'clientNavigation' => true ) ), 'attributes' => array( @@ -4360,7 +4368,7 @@ '$schema' => 'https://schemas.wp.org/trunk/block.json', 'apiVersion' => 3, 'name' => 'core/navigation-link', - 'title' => 'Custom Link', + 'title' => 'Navigation Link', 'category' => 'design', 'parent' => array( 'core/navigation' @@ -7657,6 +7665,7 @@ '__experimentalFontWeight' => true, '__experimentalLetterSpacing' => true, '__experimentalWritingMode' => true, + 'fitText' => true, '__experimentalDefaultControls' => array( 'fontSize' => true ) diff --git a/src/wp-includes/blocks/breadcrumbs.php b/src/wp-includes/blocks/breadcrumbs.php index 4fd9cee4b5aad..b633a9bc62ac1 100644 --- a/src/wp-includes/blocks/breadcrumbs.php +++ b/src/wp-includes/blocks/breadcrumbs.php @@ -263,8 +263,8 @@ function block_core_breadcrumbs_create_page_number_item( $query_var = 'paged' ) * * @since 7.0.0 * - * @param string $text The text content. - * @param bool $is_paged Whether we're on a paginated view. + * @param string $text The text content. + * @param bool $is_paged Whether we're on a paginated view. * * @return array The breadcrumb item data. */ @@ -298,7 +298,7 @@ function block_core_breadcrumbs_get_post_title( $post_id_or_object ) { * * @since 7.0.0 * - * @param int $post_id The post ID. + * @param int $post_id The post ID. * * @return array Array of breadcrumb item data. */ @@ -524,7 +524,7 @@ function block_core_breadcrumbs_get_terms_breadcrumbs( $post_id, $post_type ) { * * @since 7.0.0 * - * @param array $settings { + * @param array $settings { * Array of breadcrumb settings. Default empty array. * * @type string $taxonomy Optional. Taxonomy slug to use for breadcrumbs. diff --git a/src/wp-includes/blocks/categories.php b/src/wp-includes/blocks/categories.php index 9789bf5ca5b1b..5c4d40c5f4420 100644 --- a/src/wp-includes/blocks/categories.php +++ b/src/wp-includes/blocks/categories.php @@ -23,6 +23,10 @@ function render_block_core_categories( $attributes, $content, $block ) { $taxonomy = get_taxonomy( $attributes['taxonomy'] ); + if ( ! $taxonomy ) { + return ''; + } + $args = array( 'echo' => false, 'hierarchical' => ! empty( $attributes['showHierarchy'] ), diff --git a/src/wp-includes/blocks/comment-template.php b/src/wp-includes/blocks/comment-template.php index ec462e6a050de..de74313977f80 100644 --- a/src/wp-includes/blocks/comment-template.php +++ b/src/wp-includes/blocks/comment-template.php @@ -12,8 +12,8 @@ * * @global int $comment_depth * - * @param WP_Comment[] $comments The array of comments. - * @param WP_Block $block Block instance. + * @param WP_Comment[] $comments The array of comments. + * @param WP_Block $block Block instance. * @return string */ function block_core_comment_template_render_comments( $comments, $block ) { diff --git a/src/wp-includes/blocks/gallery.php b/src/wp-includes/blocks/gallery.php index 7823921975d0c..1a323e4fbb61c 100644 --- a/src/wp-includes/blocks/gallery.php +++ b/src/wp-includes/blocks/gallery.php @@ -87,6 +87,91 @@ function block_core_gallery_get_column_gap_value( $gap, $fallback_gap ) { return '0' === $gap_column ? '0px' : $gap_column; } +/** + * Returns Gallery-specific responsive Flex rules for a viewport. + * + * @since 7.1.0 + * + * @param string $selector Gallery block selector. + * @param mixed $viewport_style Viewport style data. + * @param string $media_query Viewport media query. + * @return array[] Gallery responsive Flex rules. + */ +function block_core_gallery_get_responsive_flex_style_rules( $selector, $viewport_style, $media_query ) { + if ( ! is_array( $viewport_style ) || ! is_string( $media_query ) ) { + return array(); + } + + $rules = array(); + $gallery_selector = "{$selector}.wp-block-gallery.has-nested-images:where(.is-layout-flex)"; + $image_selector = "{$gallery_selector} figure.wp-block-image:not(#individual-image)"; + $columns = $viewport_style['columns'] ?? null; + + if ( is_int( $columns ) && $columns >= 1 && $columns <= 8 ) { + $width = 1 === $columns + ? '100%' + : sprintf( + 'calc((100%% - (var(--wp--style--unstable-gallery-gap, 16px) * %1$d)) / %2$d)', + $columns - 1, + $columns + ); + $rules[] = array( + 'selector' => $image_selector, + 'declarations' => array( 'width' => "{$width} !important" ), + 'rules_group' => $media_query, + ); + } + + $image_crop = $viewport_style['imageCrop'] ?? null; + if ( ! is_bool( $image_crop ) ) { + return $rules; + } + + $rules[] = array( + 'selector' => $image_selector, + 'declarations' => $image_crop + ? array( + 'align-self' => 'inherit !important', + 'margin-bottom' => '0 !important', + ) + : array( + 'align-self' => 'auto !important', + 'margin-top' => '0 !important', + 'margin-bottom' => 'auto !important', + ), + 'rules_group' => $media_query, + ); + $rules[] = array( + 'selector' => "{$image_selector} > div:not(.components-drop-zone)", + 'declarations' => array( 'display' => $image_crop ? 'flex !important' : 'block !important' ), + 'rules_group' => $media_query, + ); + $rules[] = array( + 'selector' => "{$image_selector} > a", + 'declarations' => array( 'display' => $image_crop ? 'flex !important' : 'inline-block !important' ), + 'rules_group' => $media_query, + ); + $rules[] = array( + 'selector' => "{$image_selector} a,{$image_selector} img", + 'declarations' => $image_crop + ? array( + 'width' => '100% !important', + 'flex' => '1 0 0% !important', + 'height' => '100% !important', + 'object-fit' => 'cover !important', + ) + : array( + 'width' => 'auto !important', + 'flex' => '0 1 auto !important', + 'height' => 'auto !important', + 'object-fit' => 'fill !important', + ), + 'rules_group' => $media_query, + ); + + return $rules; +} + /** * Resolves a Gallery block's `dynamicContent` to an ordered list of image * attachment IDs. @@ -309,8 +394,15 @@ function block_core_gallery_render_dynamic_image( $attachment_id, $attributes, $ function block_core_gallery_render( $attributes, $content, $block ) { static $global_styles = null; + // Gallery blocks created before layout variations existed do not have an + // explicit layout attribute. Missing and malformed layout data therefore + // falls back to Flex so existing galleries retain their current appearance. + $layout = is_array( $attributes['layout'] ?? null ) ? $attributes['layout'] : array(); + $layout_type = $layout['type'] ?? null; + $is_flex_layout = ! is_string( $layout_type ) || '' === $layout_type || 'flex' === $layout_type; + // In dynamic mode the gallery's images are resolved at render time instead of - // being authored as inner blocks, so `save.js` persists at most the + // being authored as inner blocks, so `save.jsx` persists at most the // gallery-level caption — a bare `
    `, or nothing when there is no // caption. Resolve the configured source to a list of attachments, render an // image block for each, and build the gallery `
    ` wrapper from scratch. @@ -357,124 +449,134 @@ function block_core_gallery_render( $attributes, $content, $block ) { // Build the wrapper rather than parsing/splicing saved markup. // `get_block_wrapper_attributes()` supplies the block-support // classes/styles (align, color, border, spacing, anchor id); the layout - // render filter adds the flex layout classes downstream — the same way a + // render filter adds the active layout classes downstream — the same way a // static gallery's wrapper is composed (`useBlockProps.save()` plus that // filter). Only the gallery-specific classes are added explicitly, and - // they mirror `save.js` (kept in sync deliberately — see that file). - $gallery_classes = 'wp-block-gallery has-nested-images'; - $gallery_classes .= isset( $attributes['columns'] ) - ? ' columns-' . (int) $attributes['columns'] - : ' columns-default'; - if ( $attributes['imageCrop'] ?? true ) { - $gallery_classes .= ' is-cropped'; + // they mirror `save.jsx` (kept in sync deliberately — see that file). + $gallery_classes = 'wp-block-gallery has-nested-images'; + if ( $is_flex_layout ) { + $gallery_classes .= isset( $attributes['columns'] ) + ? ' columns-' . (int) $attributes['columns'] + : ' columns-default'; + if ( $attributes['imageCrop'] ?? true ) { + $gallery_classes .= ' is-cropped'; + } } $wrapper_attributes = get_block_wrapper_attributes( array( 'class' => $gallery_classes ) ); - // In dynamic mode `save.js` persists only the gallery-level caption, so + // In dynamic mode `save.jsx` persists only the gallery-level caption, so // `$content` is the saved `
    ` (or empty). Append it after the // resolved images — matching the static gallery's `{images}{caption}` // order — without parsing it. $content = sprintf( '
    %s%s
    ', $wrapper_attributes, $images_markup, $content ); } - // Adds a style tag for the --wp--style--unstable-gallery-gap var. - // The Gallery block needs to recalculate Image block width based on - // the current gap setting in order to maintain the number of flex columns - // so a css var is added to allow this. - - $style_attr = is_array( $attributes['style'] ?? null ) - ? $attributes['style'] - : array(); - if ( - defined( 'IS_GUTENBERG_PLUGIN' ) && - IS_GUTENBERG_PLUGIN && - function_exists( 'gutenberg_resolve_style_state_aliases' ) - ) { - $style_attr = gutenberg_resolve_style_state_aliases( $style_attr, 'core/gallery' ); - } - - $unique_gallery_classname = wp_unique_id( 'wp-block-gallery-' ); - $processed_content = new WP_HTML_Tag_Processor( $content ); + $processed_content = new WP_HTML_Tag_Processor( $content ); $processed_content->next_tag(); - $processed_content->add_class( $unique_gallery_classname ); - // --gallery-block--gutter-size is deprecated. --wp--style--gallery-gap-default should be used by themes that want to set a default - // gap on the gallery. - $fallback_gap = 'var( --wp--style--gallery-gap-default, var( --gallery-block--gutter-size, var( --wp--style--block-gap, 0.5em ) ) )'; + if ( $is_flex_layout ) { + // Add a style tag for the --wp--style--unstable-gallery-gap var. The + // Gallery's custom Flex layout recalculates Image block widths based on + // the current gap so it can maintain the selected number of columns. + $style_attr = is_array( $attributes['style'] ?? null ) + ? $attributes['style'] + : array(); + if ( + defined( 'IS_GUTENBERG_PLUGIN' ) && + IS_GUTENBERG_PLUGIN && + function_exists( 'gutenberg_resolve_style_state_aliases' ) + ) { + $style_attr = gutenberg_resolve_style_state_aliases( $style_attr, 'core/gallery' ); + } - if ( null === $global_styles ) { - $global_styles = function_exists( 'wp_get_global_styles' ) ? wp_get_global_styles() : array(); - } + $unique_gallery_classname = wp_unique_id( 'wp-block-gallery-' ); + $processed_content->add_class( $unique_gallery_classname ); - $global_gallery_styles = $global_styles['blocks']['core/gallery'] ?? array(); - $global_gallery_gap = $global_gallery_styles['spacing']['blockGap'] ?? $fallback_gap; - $has_block_gap = is_array( $style_attr['spacing'] ?? null ) && array_key_exists( 'blockGap', $style_attr['spacing'] ); - // Prefer the block's own gap value, then Gallery global styles. Missing - // values fall back to the Gallery blockGap default. - $block_gap = $has_block_gap - ? $style_attr['spacing']['blockGap'] - : $global_gallery_gap; - $gap_column = block_core_gallery_get_column_gap_value( $block_gap, $fallback_gap ); - - // Set the CSS variable to the column value for Gallery's flex width calculations. - $gallery_styles = array( - array( - 'selector' => ".wp-block-gallery.{$unique_gallery_classname}", - 'declarations' => array( - '--wp--style--unstable-gallery-gap' => $gap_column, - ), - ), - ); + // --gallery-block--gutter-size is deprecated. --wp--style--gallery-gap-default should be used by themes that want to set a default + // gap on the gallery. + $fallback_gap = 'var( --wp--style--gallery-gap-default, var( --gallery-block--gutter-size, var( --wp--style--block-gap, 0.5em ) ) )'; - $global_settings = wp_get_global_settings(); - $viewport_settings = $global_settings['viewport'] ?? null; - $responsive_media_queries = array(); - foreach ( array( 'WP_Theme_JSON_Gutenberg', 'WP_Theme_JSON' ) as $theme_json_class_name ) { - if ( method_exists( $theme_json_class_name, 'get_viewport_media_queries' ) ) { - $responsive_media_queries = $theme_json_class_name::get_viewport_media_queries( $viewport_settings ); - break; + if ( null === $global_styles ) { + $global_styles = function_exists( 'wp_get_global_styles' ) ? wp_get_global_styles() : array(); } - } - foreach ( $responsive_media_queries as $breakpoint => $media_query ) { - $viewport_style = $style_attr[ $breakpoint ] ?? null; - $has_viewport_block_gap = is_array( $viewport_style ) && - is_array( $viewport_style['spacing'] ?? null ) && - array_key_exists( 'blockGap', $viewport_style['spacing'] ); - $has_global_viewport_block_gap = is_array( $global_gallery_styles[ $breakpoint ]['spacing'] ?? null ) && - array_key_exists( 'blockGap', $global_gallery_styles[ $breakpoint ]['spacing'] ); - - // Viewport-specific block values win. Gallery global viewport values - // only apply when the block has no base gap, so they do not override an instance value. - if ( $has_viewport_block_gap ) { - $viewport_gap = $viewport_style['spacing']['blockGap']; - } elseif ( ! $has_block_gap && $has_global_viewport_block_gap ) { - $viewport_gap = $global_gallery_styles[ $breakpoint ]['spacing']['blockGap']; - } else { - continue; + $global_gallery_styles = $global_styles['blocks']['core/gallery'] ?? array(); + $global_gallery_gap = $global_gallery_styles['spacing']['blockGap'] ?? $fallback_gap; + $has_block_gap = is_array( $style_attr['spacing'] ?? null ) && array_key_exists( 'blockGap', $style_attr['spacing'] ); + // Prefer the block's own gap value, then Gallery global styles. Missing + // values fall back to the Gallery blockGap default. + $block_gap = $has_block_gap + ? $style_attr['spacing']['blockGap'] + : $global_gallery_gap; + $gap_column = block_core_gallery_get_column_gap_value( $block_gap, $fallback_gap ); + + // Set the CSS variable to the column value for Gallery's flex width calculations. + $gallery_styles = array( + array( + 'selector' => ".wp-block-gallery.{$unique_gallery_classname}", + 'declarations' => array( + '--wp--style--unstable-gallery-gap' => $gap_column, + ), + ), + ); + + $global_settings = wp_get_global_settings(); + $viewport_settings = $global_settings['viewport'] ?? null; + $responsive_media_queries = array(); + foreach ( array( 'WP_Theme_JSON_Gutenberg', 'WP_Theme_JSON' ) as $theme_json_class_name ) { + if ( method_exists( $theme_json_class_name, 'get_viewport_media_queries' ) ) { + $responsive_media_queries = $theme_json_class_name::get_viewport_media_queries( $viewport_settings ); + break; + } } - if ( null === $viewport_gap ) { - continue; + foreach ( $responsive_media_queries as $breakpoint => $media_query ) { + $viewport_style = $style_attr[ $breakpoint ] ?? null; + $has_viewport_block_gap = is_array( $viewport_style ) && + is_array( $viewport_style['spacing'] ?? null ) && + array_key_exists( 'blockGap', $viewport_style['spacing'] ); + $has_global_viewport_block_gap = is_array( $global_gallery_styles[ $breakpoint ]['spacing'] ?? null ) && + array_key_exists( 'blockGap', $global_gallery_styles[ $breakpoint ]['spacing'] ); + + // Viewport-specific block values win. Gallery global viewport values + // only apply when the block has no base gap, so they do not override an instance value. + if ( $has_viewport_block_gap ) { + $viewport_gap = $viewport_style['spacing']['blockGap']; + } elseif ( ! $has_block_gap && $has_global_viewport_block_gap ) { + $viewport_gap = $global_gallery_styles[ $breakpoint ]['spacing']['blockGap']; + } else { + $viewport_gap = null; + } + + if ( null !== $viewport_gap ) { + $gallery_styles[] = array( + 'selector' => ".wp-block-gallery.{$unique_gallery_classname}", + 'declarations' => array( + '--wp--style--unstable-gallery-gap' => block_core_gallery_get_column_gap_value( + $viewport_gap, + $fallback_gap + ), + ), + 'rules_group' => $media_query, + ); + } + + $gallery_styles = array_merge( + $gallery_styles, + block_core_gallery_get_responsive_flex_style_rules( + ".{$unique_gallery_classname}", + $viewport_style, + $media_query + ) + ); } - $gallery_styles[] = array( - 'selector' => ".wp-block-gallery.{$unique_gallery_classname}", - 'declarations' => array( - '--wp--style--unstable-gallery-gap' => block_core_gallery_get_column_gap_value( - $viewport_gap, - $fallback_gap - ), - ), - 'rules_group' => $media_query, + wp_style_engine_get_stylesheet_from_css_rules( + $gallery_styles, + array( 'context' => 'block-supports' ) ); } - wp_style_engine_get_stylesheet_from_css_rules( - $gallery_styles, - array( 'context' => 'block-supports' ) - ); - // The WP_HTML_Tag_Processor class calls get_updated_html() internally // when the instance is treated as a string, but here we explicitly // convert it to a string. diff --git a/src/wp-includes/blocks/gallery/block.json b/src/wp-includes/blocks/gallery/block.json index 1c53921757918..5f0ae512718ec 100644 --- a/src/wp-includes/blocks/gallery/block.json +++ b/src/wp-includes/blocks/gallery/block.json @@ -160,7 +160,12 @@ "layout": { "allowSwitching": false, "allowInheriting": false, - "allowEditing": false, + "allowEditing": true, + "allowOrientation": false, + "allowJustification": false, + "allowVerticalAlignment": false, + "allowWrap": false, + "allowSizingOnChildren": true, "default": { "type": "flex" } diff --git a/src/wp-includes/blocks/heading.php b/src/wp-includes/blocks/heading.php index 471e31f19f2ee..b712e9b631670 100644 --- a/src/wp-includes/blocks/heading.php +++ b/src/wp-includes/blocks/heading.php @@ -17,7 +17,7 @@ * @since 6.2.0 * * @param array $attributes Attributes of the block being rendered. - * @param string $content Content of the block being rendered. + * @param string $content Content of the block being rendered. * * @return string The content of the block being rendered. */ diff --git a/src/wp-includes/blocks/home-link.php b/src/wp-includes/blocks/home-link.php index fc2d18592ee75..d3b52c7ca946f 100644 --- a/src/wp-includes/blocks/home-link.php +++ b/src/wp-includes/blocks/home-link.php @@ -11,7 +11,7 @@ * * @since 6.0.0 * - * @param array $context home link block context. + * @param array $context home link block context. * @return array Colors CSS classes and inline styles. */ function block_core_home_link_build_css_colors( $context ) { @@ -64,7 +64,7 @@ function block_core_home_link_build_css_colors( $context ) { * * @since 6.0.0 * - * @param array $context Home link block context. + * @param array $context Home link block context. * @return string The li wrapper attributes. */ function block_core_home_link_build_li_wrapper_attributes( $context ) { diff --git a/src/wp-includes/blocks/icon.php b/src/wp-includes/blocks/icon.php index c010e7148346b..749ea140b27b4 100644 --- a/src/wp-includes/blocks/icon.php +++ b/src/wp-includes/blocks/icon.php @@ -96,7 +96,17 @@ function render_block_core_icon( $attributes ) { $processor = new WP_HTML_Tag_Processor( $svg ); if ( $processor->next_tag( 'svg' ) ) { if ( ! empty( $styles['css'] ) ) { - $processor->set_attribute( 'style', $styles['css'] ); + // Merge with the SVG's intrinsic style (e.g. `fill: none` on + // stroke-based icons) so it is preserved. The block styles come last + // so they win on any conflicting property. + $existing_style = $processor->get_attribute( 'style' ); + $trimmed_style = is_string( $existing_style ) + ? rtrim( trim( $existing_style ), ';' ) + : ''; + $merged_style = '' !== $trimmed_style + ? $trimmed_style . '; ' . $styles['css'] + : $styles['css']; + $processor->set_attribute( 'style', $merged_style ); } // Apply flip classes to the SVG. @@ -115,11 +125,13 @@ function render_block_core_icon( $attributes ) { if ( $rotation ) { $current_style = $processor->get_attribute( 'style' ) ?? ''; $rotation_css = 'rotate: ' . $rotation . 'deg;'; - if ( $current_style ) { - $processor->set_attribute( 'style', $current_style . ' ' . $rotation_css ); - } else { - $processor->set_attribute( 'style', $rotation_css ); - } + $trimmed_style = is_string( $current_style ) + ? rtrim( trim( $current_style ), ';' ) + : ''; + $merged_style = '' !== $trimmed_style + ? $trimmed_style . '; ' . $rotation_css + : $rotation_css; + $processor->set_attribute( 'style', $merged_style ); } $svg = $processor->get_updated_html(); diff --git a/src/wp-includes/blocks/list.php b/src/wp-includes/blocks/list.php index 1bffd81324857..5a5aecfb28078 100644 --- a/src/wp-includes/blocks/list.php +++ b/src/wp-includes/blocks/list.php @@ -15,7 +15,7 @@ * @see https://github.com/WordPress/gutenberg/issues/12420 * * @param array $attributes Attributes of the block being rendered. - * @param string $content Content of the block being rendered. + * @param string $content Content of the block being rendered. * * @return string The content of the block being rendered. */ diff --git a/src/wp-includes/blocks/math/block.json b/src/wp-includes/blocks/math/block.json index a305900ab9961..e8a09d5443300 100644 --- a/src/wp-includes/blocks/math/block.json +++ b/src/wp-includes/blocks/math/block.json @@ -36,6 +36,9 @@ "__experimentalDefaultControls": { "fontSize": true } + }, + "interactivity": { + "clientNavigation": true } }, "attributes": { diff --git a/src/wp-includes/blocks/navigation-link.php b/src/wp-includes/blocks/navigation-link.php index b941e35857c40..d6f329939b9e4 100644 --- a/src/wp-includes/blocks/navigation-link.php +++ b/src/wp-includes/blocks/navigation-link.php @@ -14,9 +14,9 @@ * * @since 5.9.0 * - * @param array $context Navigation block context. - * @param array $attributes Block attributes. - * @param bool $is_sub_menu Whether the link is part of a sub-menu. Default false. + * @param array $context Navigation block context. + * @param array $attributes Block attributes. + * @param bool $is_sub_menu Whether the link is part of a sub-menu. Default false. * @return array Colors CSS classes and inline styles. */ function block_core_navigation_link_build_css_colors( $context, $attributes, $is_sub_menu = false ) { @@ -90,7 +90,7 @@ function block_core_navigation_link_build_css_colors( $context, $attributes, $is * @since 5.9.0 * @deprecated 7.0.0 * - * @param array $context Navigation block context. + * @param array $context Navigation block context. * @return array Font size CSS classes and inline styles. */ function block_core_navigation_link_build_css_font_sizes( $context ) { @@ -308,7 +308,7 @@ function render_block_core_navigation_link( $attributes, $content, $block ) { * @since 5.9.0 * * @param WP_Taxonomy|WP_Post_Type $entity post type or taxonomy entity. - * @param string $kind string of value 'taxonomy' or 'post-type'. + * @param string $kind string of value 'taxonomy' or 'post-type'. * * @return array */ diff --git a/src/wp-includes/blocks/navigation-link/block.json b/src/wp-includes/blocks/navigation-link/block.json index 8cab34bc4d064..1e63f70a5cb3e 100644 --- a/src/wp-includes/blocks/navigation-link/block.json +++ b/src/wp-includes/blocks/navigation-link/block.json @@ -2,7 +2,7 @@ "$schema": "https://schemas.wp.org/trunk/block.json", "apiVersion": 3, "name": "core/navigation-link", - "title": "Custom Link", + "title": "Navigation Link", "category": "design", "parent": [ "core/navigation" ], "allowedBlocks": [ diff --git a/src/wp-includes/blocks/navigation.php b/src/wp-includes/blocks/navigation.php index 48af8ba468626..e67f727c60542 100644 --- a/src/wp-includes/blocks/navigation.php +++ b/src/wp-includes/blocks/navigation.php @@ -417,7 +417,7 @@ private static function disable_overlay_menu_for_nested_navigation_blocks( $bloc * @since 6.5.0 * * @param string $overlay_template_part_id The overlay template part ID in format "theme//slug". - * @param array $attributes The block attributes. + * @param array $attributes The block attributes. * @return WP_Block_List Returns the inner blocks for the overlay template part. */ private static function get_overlay_blocks_from_template_part( $overlay_template_part_id, $attributes ) { @@ -518,7 +518,7 @@ private static function get_overlay_blocks_from_template_part( $overlay_template * @since 6.5.0 * * @param array $attributes The block attributes. - * @param WP_Block $block The parsed block. + * @param WP_Block $block The parsed block. * @return WP_Block_List Returns the inner blocks for the navigation block. */ private static function get_inner_blocks( $attributes, $block ) { @@ -740,8 +740,8 @@ private static function get_overlay_inline_styles( $has_custom_overlay, $colors * * @since 6.5.0 * - * @param array $attributes The block attributes. - * @param WP_Block_List $inner_blocks The list of inner blocks. + * @param array $attributes The block attributes. + * @param WP_Block_List $inner_blocks The list of inner blocks. * @param string $inner_blocks_html The markup for the inner blocks. * @return string Returns the container markup. */ @@ -892,8 +892,8 @@ private static function get_responsive_container_markup( $attributes, $inner_blo * * @since 6.5.0 * - * @param array $attributes The block attributes. - * @param WP_Block_List $inner_blocks A list of inner blocks. + * @param array $attributes The block attributes. + * @param WP_Block_List $inner_blocks A list of inner blocks. * @return string Returns the navigation block markup. */ private static function get_nav_attributes( $attributes, $inner_blocks ) { @@ -979,7 +979,7 @@ private static function handle_view_script_module_loading( $attributes, $block, * * @since 6.5.0 * - * @param array $attributes The block attributes. + * @param array $attributes The block attributes. * @param WP_Block_List $inner_blocks The list of inner blocks. * @return string Returns the navigation wrapper markup. */ @@ -1786,12 +1786,12 @@ function block_core_navigation_typographic_presets_backcompatibility( $parsed_bl * * @deprecated 6.3.0 Use WP_Navigation_Fallback::parse_blocks_from_menu_items() instead. * - * @param array $menu_items An array of menu items that represent - * an individual level of a menu. - * @param array $menu_items_by_parent_id An array keyed by the id of the - * parent menu where each element is an - * array of menu items that belong to - * that parent. + * @param array $menu_items An array of menu items that represent + * an individual level of a menu. + * @param array $menu_items_by_parent_id An array keyed by the id of the + * parent menu where each element is an + * array of menu items that belong to + * that parent. * @return array An array of parsed block data. */ function block_core_navigation_parse_blocks_from_menu_items( $menu_items, $menu_items_by_parent_id ) { @@ -1891,7 +1891,7 @@ static function ( $a, $b ) { * * @deprecated 6.3.0 Use WP_Navigation_Fallback::get_classic_menu_fallback_blocks() instead. * - * @param object $classic_nav_menu WP_Term The classic navigation object to convert. + * @param object $classic_nav_menu WP_Term The classic navigation object to convert. * @return array the normalized parsed blocks. */ function block_core_navigation_get_classic_menu_fallback_blocks( $classic_nav_menu ) { diff --git a/src/wp-includes/blocks/page-list.php b/src/wp-includes/blocks/page-list.php index 395702068ec83..cf812a67d0ccb 100644 --- a/src/wp-includes/blocks/page-list.php +++ b/src/wp-includes/blocks/page-list.php @@ -36,8 +36,8 @@ function block_core_page_list_get_submenu_visibility( $context ) { * * @since 5.8.0 * - * @param array $attributes Block attributes. - * @param array $context Navigation block context. + * @param array $attributes Block attributes. + * @param array $context Navigation block context. * @return array Colors CSS classes and inline styles. */ function block_core_page_list_build_css_colors( $attributes, $context ) { @@ -128,14 +128,14 @@ function block_core_page_list_build_css_colors( $attributes, $context ) { * * @since 5.8.0 * - * @param string $submenu_visibility The submenu visibility mode: 'hover', 'click', or 'always'. - * @param boolean $show_submenu_icons Whether to show submenu indicator icons. - * @param boolean $is_navigation_child If block is a child of Navigation block. - * @param array $nested_pages The array of nested pages. - * @param boolean $is_nested Whether the submenu is nested or not. + * @param string $submenu_visibility The submenu visibility mode: 'hover', 'click', or 'always'. + * @param boolean $show_submenu_icons Whether to show submenu indicator icons. + * @param boolean $is_navigation_child If block is a child of Navigation block. + * @param array $nested_pages The array of nested pages. + * @param boolean $is_nested Whether the submenu is nested or not. * @param array $active_page_ancestor_ids An array of ancestor ids for active page. - * @param array $colors Color information for overlay styles. - * @param integer $depth The nesting depth. + * @param array $colors Color information for overlay styles. + * @param integer $depth The nesting depth. * * @return string List markup. */ @@ -227,7 +227,7 @@ function block_core_page_list_render_nested_page_list( $submenu_visibility, $sho * @since 5.8.0 * * @param array $current_level The level being iterated through. - * @param array $children The children grouped by parent post ID. + * @param array $children The children grouped by parent post ID. * * @return array The nested array of pages. */ diff --git a/src/wp-includes/blocks/post-author-biography.php b/src/wp-includes/blocks/post-author-biography.php index bd983f79e7609..5ef7f433d7709 100644 --- a/src/wp-includes/blocks/post-author-biography.php +++ b/src/wp-includes/blocks/post-author-biography.php @@ -10,9 +10,9 @@ * * @since 6.0.0 * - * @param array $attributes Block attributes. - * @param string $content Block default content. - * @param WP_Block $block Block instance. + * @param array $attributes Block attributes. + * @param string $content Block default content. + * @param WP_Block $block Block instance. * @return string Returns the rendered post author biography block. */ function render_block_core_post_author_biography( $attributes, $content, $block ) { diff --git a/src/wp-includes/blocks/post-author-name.php b/src/wp-includes/blocks/post-author-name.php index 73113eb1efc4b..f729696b781e8 100644 --- a/src/wp-includes/blocks/post-author-name.php +++ b/src/wp-includes/blocks/post-author-name.php @@ -10,9 +10,9 @@ * * @since 6.2.0 * - * @param array $attributes Block attributes. - * @param string $content Block default content. - * @param WP_Block $block Block instance. + * @param array $attributes Block attributes. + * @param string $content Block default content. + * @param WP_Block $block Block instance. * @return string Returns the rendered post author name block. */ function render_block_core_post_author_name( $attributes, $content, $block ) { diff --git a/src/wp-includes/blocks/post-author.php b/src/wp-includes/blocks/post-author.php index a4880f8a9e744..682fabb2805f1 100644 --- a/src/wp-includes/blocks/post-author.php +++ b/src/wp-includes/blocks/post-author.php @@ -10,9 +10,9 @@ * * @since 5.9.0 * - * @param array $attributes Block attributes. - * @param string $content Block default content. - * @param WP_Block $block Block instance. + * @param array $attributes Block attributes. + * @param string $content Block default content. + * @param WP_Block $block Block instance. * @return string Returns the rendered author block. */ function render_block_core_post_author( $attributes, $content, $block ) { diff --git a/src/wp-includes/blocks/post-comments-link.php b/src/wp-includes/blocks/post-comments-link.php index c6d33eb0cd65c..6f183a79eac2c 100644 --- a/src/wp-includes/blocks/post-comments-link.php +++ b/src/wp-includes/blocks/post-comments-link.php @@ -10,10 +10,10 @@ * * @since 6.9.0 * - * @param array $attributes Block attributes. - * @param string $content Block default content. - * @param WP_Block $block Block instance. - * @return string Returns the rendered link. + * @param array $attributes Block attributes. + * @param string $content Block default content. + * @param WP_Block $block Block instance. + * @return string Returns the rendered link. */ function render_block_core_post_comments_link( $attributes, $content, $block ) { if ( diff --git a/src/wp-includes/blocks/post-content.php b/src/wp-includes/blocks/post-content.php index b75d7144dab98..56429cd22a165 100644 --- a/src/wp-includes/blocks/post-content.php +++ b/src/wp-includes/blocks/post-content.php @@ -60,7 +60,7 @@ function render_block_core_post_content( $attributes, $content, $block ) { /** * The allowed tag names match the options offered in the editor. * - * @see packages/block-library/src/post-content/edit.js + * @see packages/block-library/src/post-content/edit.jsx */ $allowed_tag_names = array( 'div', 'main', 'section', 'article' ); $normalized_tag_name = strtolower( $attributes['tagName'] ); diff --git a/src/wp-includes/blocks/post-time-to-read.php b/src/wp-includes/blocks/post-time-to-read.php index 74a091d97c335..f3f336fbe932d 100644 --- a/src/wp-includes/blocks/post-time-to-read.php +++ b/src/wp-includes/blocks/post-time-to-read.php @@ -92,9 +92,9 @@ function block_core_post_time_to_read_word_count( $text, $type ) { * * @since 6.9.0 * - * @param array $attributes Block attributes. - * @param string $content Block default content. - * @param WP_Block $block Block instance. + * @param array $attributes Block attributes. + * @param string $content Block default content. + * @param WP_Block $block Block instance. * @return string Returns the rendered post author name block. */ function render_block_core_post_time_to_read( $attributes, $content, $block ) { diff --git a/src/wp-includes/blocks/query.php b/src/wp-includes/blocks/query.php index 73fc9a50928c1..404d8ac1b66e3 100644 --- a/src/wp-includes/blocks/query.php +++ b/src/wp-includes/blocks/query.php @@ -108,8 +108,8 @@ function block_core_query_disable_enhanced_pagination( $parsed_block ) { * by adding an attribute called `data-wp-navigation-disabled` which * is later handled by the front-end logic. * - * @param string $content The block content. - * @param array $block The full block, including name and attributes. + * @param string $content The block content. + * @param array $block The full block, including name and attributes. * @return string Returns the modified output of the query block. */ $render_query_callback = static function ( $content, $block ) use ( &$enhanced_query_stack, &$dirty_enhanced_queries, &$render_query_callback ) { diff --git a/src/wp-includes/blocks/read-more.php b/src/wp-includes/blocks/read-more.php index bf14f8ea242e8..81c4f0f0ba69d 100644 --- a/src/wp-includes/blocks/read-more.php +++ b/src/wp-includes/blocks/read-more.php @@ -13,7 +13,7 @@ * @param array $attributes Block attributes. * @param string $content Block default content. * @param WP_Block $block Block instance. - * @return string Returns the post link. + * @return string Returns the post link. */ function render_block_core_read_more( $attributes, $content, $block ) { if ( ! isset( $block->context['postId'] ) ) { diff --git a/src/wp-includes/blocks/search.php b/src/wp-includes/blocks/search.php index 8811e005e7f01..8a453bcfd1908 100644 --- a/src/wp-includes/blocks/search.php +++ b/src/wp-includes/blocks/search.php @@ -360,7 +360,7 @@ function apply_block_core_search_border_styles( $attributes, $property, &$wrappe * * @since 5.8.0 * - * @param array $attributes The block attributes. + * @param array $attributes The block attributes. * * @return array Style HTML attribute. */ diff --git a/src/wp-includes/blocks/site-logo.php b/src/wp-includes/blocks/site-logo.php index 915563461e30c..29357c9a8f3cf 100644 --- a/src/wp-includes/blocks/site-logo.php +++ b/src/wp-includes/blocks/site-logo.php @@ -139,7 +139,7 @@ function _override_custom_logo_theme_mod( $custom_logo ) { * * @since 5.8.0 * - * @param mixed $value Attachment ID of the custom logo or an empty value. + * @param mixed $value Attachment ID of the custom logo or an empty value. * @return mixed */ function _sync_custom_logo_to_site_logo( $value ) { diff --git a/src/wp-includes/blocks/site-title/block.json b/src/wp-includes/blocks/site-title/block.json index 0631de6560ba4..8bf5202643003 100644 --- a/src/wp-includes/blocks/site-title/block.json +++ b/src/wp-includes/blocks/site-title/block.json @@ -61,6 +61,7 @@ "__experimentalFontWeight": true, "__experimentalLetterSpacing": true, "__experimentalWritingMode": true, + "fitText": true, "__experimentalDefaultControls": { "fontSize": true } diff --git a/src/wp-includes/blocks/social-link.php b/src/wp-includes/blocks/social-link.php index 85a907c234e7a..60064f64a525c 100644 --- a/src/wp-includes/blocks/social-link.php +++ b/src/wp-includes/blocks/social-link.php @@ -349,7 +349,6 @@ function block_core_social_link_services( $service = '', $field = '' ) { * @since 6.9.0 * * @param array $services_data The list of services. Each item is an array containing a 'name' and 'icon' key. - * @return array The list of social services. */ $services_data = apply_filters( 'block_core_social_link_get_services', $services_data ); diff --git a/src/wp-includes/blocks/tab-list.php b/src/wp-includes/blocks/tab-list.php index eb587ef78fd2d..f45de5def38e9 100644 --- a/src/wp-includes/blocks/tab-list.php +++ b/src/wp-includes/blocks/tab-list.php @@ -9,14 +9,14 @@ * Render callback for core/tab-list. * * Injects IAPI directives into the saved button HTML. The buttons already - * carry color/border/padding styles from save.js; this callback adds + * carry color/border/padding styles from save.jsx; this callback adds * tab-specific attributes (id, aria-controls, context) and interactivity * directives using data from the tabs-list context. * * @since 7.1.0 * * @param array $attributes Block attributes. - * @param string $content Block content (rendered buttons from save.js). + * @param string $content Block content (rendered buttons from save.jsx). * @param \WP_Block $block WP_Block instance. * * @return string Updated HTML. diff --git a/src/wp-includes/blocks/tabs.php b/src/wp-includes/blocks/tabs.php index e7a3d63775886..a8d9dcc4b0327 100644 --- a/src/wp-includes/blocks/tabs.php +++ b/src/wp-includes/blocks/tabs.php @@ -104,7 +104,8 @@ function block_core_tabs_render_block_callback( array $attributes, string $conte ) ) ); - $tag_processor->set_attribute( 'data-wp-init', 'callbacks.onTabsInit' ); + $tag_processor->set_attribute( 'data-wp-init', 'callbacks.activateTabByHash' ); + $tag_processor->set_attribute( 'data-wp-on-window--hashchange', 'callbacks.activateTabByHash' ); $tag_processor->set_attribute( 'data-wp-on--keydown', 'actions.handleTabKeyDown' ); $output = $tag_processor->get_updated_html(); diff --git a/src/wp-includes/blocks/widget-group.php b/src/wp-includes/blocks/widget-group.php index e8769612a2f17..ac4474deef5ea 100644 --- a/src/wp-includes/blocks/widget-group.php +++ b/src/wp-includes/blocks/widget-group.php @@ -14,8 +14,8 @@ * @global int|string $_sidebar_being_rendered * * @param array $attributes The block attributes. - * @param string $content The block content. - * @param WP_Block $block The block. + * @param string $content The block content. + * @param WP_Block $block The block. * * @return string Rendered block. */ @@ -70,7 +70,7 @@ function register_block_core_widget_group() { * * @global int|string $_sidebar_being_rendered * - * @param int|string $index Index, name, or ID of the dynamic sidebar. + * @param int|string $index Index, name, or ID of the dynamic sidebar. */ function note_sidebar_being_rendered( $index ) { global $_sidebar_being_rendered; diff --git a/src/wp-includes/build/constants.php b/src/wp-includes/build/constants.php index c2a539ac31272..365f89d9e3ecf 100644 --- a/src/wp-includes/build/constants.php +++ b/src/wp-includes/build/constants.php @@ -9,6 +9,6 @@ */ return array( - 'version' => '23.9.0', + 'version' => '23.9.1', 'build_url' => includes_url( 'build/' ), ); diff --git a/src/wp-includes/build/pages/font-library/page-wp-admin.php b/src/wp-includes/build/pages/font-library/page-wp-admin.php index 98cb4028c9541..bc5625319a725 100644 --- a/src/wp-includes/build/pages/font-library/page-wp-admin.php +++ b/src/wp-includes/build/pages/font-library/page-wp-admin.php @@ -328,10 +328,14 @@ function wp_font_library_wp_admin_render_page() { ); ?>
    -
    + +
    -
    + +
    *{pointer-events:auto}}}"); } -var style_default3 = { "button": "_97b0fc33c028be1a__button", "is-unstyled": "abbb272e2ce49bd6__is-unstyled", "is-loading": "_914b42f315c0e580__is-loading", "is-small": "_908205475f9f2a92__is-small", "icon": "_9f6fc6553aeb36fe__icon", "is-brand": "dd460c965226cc77__is-brand", "is-outline": "_62d5a778b7b258ee__is-outline", "is-minimal": "ad0619a3217c6a5b__is-minimal", "is-neutral": "e722a8f96726aa99__is-neutral", "is-solid": "b50b3358c5fb4d0b__is-solid", "is-compact": "cf59cf1b69629838__is-compact", "loading-animation": "_5a1d53da6f830c8d__loading-animation" }; -if (typeof process === "undefined" || true) { - registerStyle3("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); +var wp_compat_overlay_slot_default = { "slot": "_11fc52b637ff8a7e__slot" }; +var WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE = "data-wp-compat-overlay-slot"; +function resolveOwnerDocument() { + return typeof document === "undefined" ? null : document; } -var resets_default = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; -if (typeof process === "undefined" || true) { - registerStyle3("96553466c8", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); +function isInWordPressEnvironment() { + let topWp; + try { + topWp = window.top?.wp; + } catch { + } + const wp = topWp ?? window.wp; + return typeof wp?.components === "object" && wp.components !== null; } -var focus_module_default = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-within-visible": "_64de9947bf305b7a__outset-ring--focus-within-visible", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; -if (typeof process === "undefined" || true) { - registerStyle3("af6d9984a6", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}"); +var cachedSlot = null; +function ensureSlotIsAccessible(element) { + element.setAttribute("aria-hidden", "false"); + return element; } -var global_css_defense_default2 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a" }; -var Button3 = (0, import_element12.forwardRef)( - function Button22({ - tone = "brand", - variant = "solid", - size: size4 = "default", - className, - focusableWhenDisabled = true, - disabled: disabled2, - loading, - loadingAnnouncement = (0, import_i18n.__)("Loading"), - children, - ...props - }, ref) { - const mergedClassName = clsx_default( - global_css_defense_default2.button, - resets_default["box-sizing"], - focus_module_default["outset-ring--focus-except-active"], - variant !== "unstyled" && style_default3.button, - style_default3[`is-${tone}`], - style_default3[`is-${variant}`], - style_default3[`is-${size4}`], - loading && style_default3["is-loading"], - className - ); - (0, import_element12.useEffect)(() => { - if (loading && loadingAnnouncement) { - speak(loadingAnnouncement); - } - }, [loading, loadingAnnouncement]); +function createSlot(ownerDocument2) { + const element = ownerDocument2.createElement("div"); + element.setAttribute(WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE, ""); + if (wp_compat_overlay_slot_default.slot) { + element.classList.add(wp_compat_overlay_slot_default.slot); + } + ownerDocument2.body.appendChild(element); + return element; +} +function getWpCompatOverlaySlot() { + if (typeof window === "undefined") { + return void 0; + } + if (!isInWordPressEnvironment() && window.__wpUiCompatOverlaySlotEnabled !== true) { + return void 0; + } + const ownerDocument2 = resolveOwnerDocument(); + if (!ownerDocument2 || !ownerDocument2.body) { + return void 0; + } + if (cachedSlot && cachedSlot.ownerDocument === ownerDocument2 && cachedSlot.isConnected) { + return ensureSlotIsAccessible(cachedSlot); + } + const existing = ownerDocument2.querySelector( + `[${WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE}]` + ); + if (existing instanceof HTMLDivElement) { + cachedSlot = ensureSlotIsAccessible(existing); + return cachedSlot; + } + if (cachedSlot?.isConnected) { + cachedSlot.remove(); + } + cachedSlot = ensureSlotIsAccessible(createSlot(ownerDocument2)); + return cachedSlot; +} + +// packages/ui/build-module/tooltip/portal.mjs +var import_jsx_runtime13 = __toESM(require_jsx_runtime(), 1); +var Portal = (0, import_element12.forwardRef)( + function TooltipPortal3({ container, ...restProps }, ref) { return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)( - Button, + index_parts_exports.Portal, { - ref, - className: mergedClassName, - focusableWhenDisabled, - disabled: disabled2 ?? loading, - ...props, - children + container: container ?? getWpCompatOverlaySlot(), + ...restProps, + ref } ); } ); -// packages/ui/build-module/button/icon.mjs -var import_element14 = __toESM(require_element(), 1); - -// packages/ui/build-module/icon/icon.mjs +// packages/ui/build-module/tooltip/positioner.mjs var import_element13 = __toESM(require_element(), 1); -var import_primitives = __toESM(require_primitives(), 1); var import_jsx_runtime14 = __toESM(require_jsx_runtime(), 1); -var Icon = (0, import_element13.forwardRef)(function Icon2({ icon, size: size4 = 24, ...restProps }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)( - import_primitives.SVG, - { - ref, - ...icon.props, - ...restProps, - width: size4, - height: size4 - } - ); -}); - -// packages/ui/build-module/button/icon.mjs -var import_jsx_runtime15 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE4 = "data-wp-hash"; function getRuntime4() { const globalScope = globalThis; @@ -9129,69 +9127,68 @@ function registerStyle4(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle4("effc4e3032", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); + registerStyle4("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); } -var style_default4 = { "button": "_97b0fc33c028be1a__button", "is-unstyled": "abbb272e2ce49bd6__is-unstyled", "is-loading": "_914b42f315c0e580__is-loading", "is-small": "_908205475f9f2a92__is-small", "icon": "_9f6fc6553aeb36fe__icon", "is-brand": "dd460c965226cc77__is-brand", "is-outline": "_62d5a778b7b258ee__is-outline", "is-minimal": "ad0619a3217c6a5b__is-minimal", "is-neutral": "e722a8f96726aa99__is-neutral", "is-solid": "b50b3358c5fb4d0b__is-solid", "is-compact": "cf59cf1b69629838__is-compact", "loading-animation": "_5a1d53da6f830c8d__loading-animation" }; -var ButtonIcon = (0, import_element14.forwardRef)( - function ButtonIcon2({ className, icon, ...props }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)( - Icon, +var resets_default = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; +if (typeof process === "undefined" || true) { + registerStyle4("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); +} +var style_default3 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; +var Positioner = (0, import_element13.forwardRef)( + function TooltipPositioner3({ align = "center", className, side = "top", sideOffset = 4, ...props }, ref) { + return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)( + index_parts_exports.Positioner, { ref, - icon, - className: clsx_default(style_default4.icon, className), - size: 24, - ...props + align, + side, + sideOffset, + ...props, + className: clsx_default( + resets_default["box-sizing"], + style_default3.positioner, + className + ) } ); } ); -// packages/ui/build-module/button/index.mjs -ButtonIcon.displayName = "Button.Icon"; -var Button4 = Object.assign(Button3, { - /** - * An icon component specifically designed to work well when rendered inside - * a `Button` component. - */ - Icon: ButtonIcon -}); - -// packages/icons/build-module/library/caution.mjs -var import_primitives2 = __toESM(require_primitives(), 1); -var import_jsx_runtime16 = __toESM(require_jsx_runtime(), 1); -var caution_default = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_primitives2.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_primitives2.Path, { fillRule: "evenodd", clipRule: "evenodd", d: "M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-.75 12v-1.5h1.5V16h-1.5Zm0-8v5h1.5V8h-1.5Z" }) }); - -// packages/icons/build-module/library/close-small.mjs -var import_primitives3 = __toESM(require_primitives(), 1); -var import_jsx_runtime17 = __toESM(require_jsx_runtime(), 1); -var close_small_default = /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_primitives3.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_primitives3.Path, { d: "M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z" }) }); - -// packages/icons/build-module/library/error.mjs -var import_primitives4 = __toESM(require_primitives(), 1); -var import_jsx_runtime18 = __toESM(require_jsx_runtime(), 1); -var error_default = /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_primitives4.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_primitives4.Path, { fillRule: "evenodd", clipRule: "evenodd", d: "M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z" }) }); +// packages/ui/build-module/utils/render-slot-with-children.mjs +var import_element14 = __toESM(require_element(), 1); +function renderSlotWithChildren(slot, defaultSlot, children) { + return (0, import_element14.cloneElement)(slot ?? defaultSlot, { children }); +} -// packages/icons/build-module/library/info.mjs -var import_primitives5 = __toESM(require_primitives(), 1); -var import_jsx_runtime19 = __toESM(require_jsx_runtime(), 1); -var info_default = /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_primitives5.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_primitives5.Path, { fillRule: "evenodd", clipRule: "evenodd", d: "M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm.75 4v1.5h-1.5V8h1.5Zm0 8v-5h-1.5v5h1.5Z" }) }); +// packages/ui/build-module/utils/theme-provider.mjs +var theme = __toESM(require_theme(), 1); -// packages/icons/build-module/library/published.mjs -var import_primitives6 = __toESM(require_primitives(), 1); -var import_jsx_runtime20 = __toESM(require_jsx_runtime(), 1); -var published_default = /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives6.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives6.Path, { fillRule: "evenodd", clipRule: "evenodd", d: "M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm11.53-1.47-1.06-1.06L11 12.94l-1.47-1.47-1.06 1.06L11 15.06l4.53-4.53Z" }) }); +// packages/ui/build-module/lock-unlock.mjs +var import_private_apis = __toESM(require_private_apis(), 1); +var { lock, unlock } = (0, import_private_apis.__dangerousOptInToUnstableAPIsOnlyForCoreModules)( + "I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.", + "@wordpress/ui" +); -// packages/ui/build-module/icon-button/icon-button.mjs -var import_element22 = __toESM(require_element(), 1); +// packages/ui/build-module/utils/theme-provider.mjs +function getThemeProvider() { + const themePackage = theme; + if (themePackage.ThemeProvider) { + return themePackage.ThemeProvider; + } + if (!themePackage.privateApis) { + throw new Error( + "@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`." + ); + } + return unlock( + themePackage.privateApis + ).ThemeProvider; +} +var ThemeProvider = getThemeProvider(); // packages/ui/build-module/tooltip/popup.mjs -var import_element18 = __toESM(require_element(), 1); - -// packages/ui/build-module/tooltip/portal.mjs -var import_element15 = __toESM(require_element(), 1); - -// packages/ui/build-module/utils/wp-compat-overlay-slot.mjs +var import_jsx_runtime15 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE5 = "data-wp-hash"; function getRuntime5() { const globalScope = globalThis; @@ -9273,82 +9270,54 @@ function registerStyle5(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle5("be37f31c1e", "._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}"); -} -var wp_compat_overlay_slot_default = { "slot": "_11fc52b637ff8a7e__slot" }; -var WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE = "data-wp-compat-overlay-slot"; -function resolveOwnerDocument() { - return typeof document === "undefined" ? null : document; + registerStyle5("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); } -function isInWordPressEnvironment() { - let topWp; - try { - topWp = window.top?.wp; - } catch { +var style_default4 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; +var POPUP_COLOR = { background: "#1e1e1e" }; +var Popup = (0, import_element15.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { + const popupContent = /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(ThemeProvider, { color: POPUP_COLOR, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)( + index_parts_exports.Popup, + { + ref, + className: clsx_default(style_default4.popup, className), + ...props, + children + } + ) }); + const positionedPopup = renderSlotWithChildren( + positioner, + /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Positioner, {}), + popupContent + ); + return renderSlotWithChildren(portal, /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Portal, {}), positionedPopup); +}); + +// packages/ui/build-module/tooltip/trigger.mjs +var import_element16 = __toESM(require_element(), 1); +var import_jsx_runtime16 = __toESM(require_jsx_runtime(), 1); +var Trigger = (0, import_element16.forwardRef)( + function TooltipTrigger3(props, ref) { + return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(index_parts_exports.Trigger, { ref, ...props }); } - const wp = topWp ?? window.wp; - return typeof wp?.components === "object" && wp.components !== null; +); + +// packages/ui/build-module/utils/direction-provider.mjs +var import_i18n = __toESM(require_i18n(), 1); +var import_jsx_runtime17 = __toESM(require_jsx_runtime(), 1); +function DirectionProvider3({ children }) { + return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(DirectionProvider, { direction: (0, import_i18n.isRTL)() ? "rtl" : "ltr", children }); } -var cachedSlot = null; -function ensureSlotIsAccessible(element) { - element.setAttribute("aria-hidden", "false"); - return element; + +// packages/ui/build-module/tooltip/root.mjs +var import_jsx_runtime18 = __toESM(require_jsx_runtime(), 1); +function Root(props) { + return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(DirectionProvider3, { children: /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(index_parts_exports.Root, { ...props }) }); } -function createSlot(ownerDocument2) { - const element = ownerDocument2.createElement("div"); - element.setAttribute(WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE, ""); - if (wp_compat_overlay_slot_default.slot) { - element.classList.add(wp_compat_overlay_slot_default.slot); - } - ownerDocument2.body.appendChild(element); - return element; -} -function getWpCompatOverlaySlot() { - if (typeof window === "undefined") { - return void 0; - } - if (!isInWordPressEnvironment() && window.__wpUiCompatOverlaySlotEnabled !== true) { - return void 0; - } - const ownerDocument2 = resolveOwnerDocument(); - if (!ownerDocument2 || !ownerDocument2.body) { - return void 0; - } - if (cachedSlot && cachedSlot.ownerDocument === ownerDocument2 && cachedSlot.isConnected) { - return ensureSlotIsAccessible(cachedSlot); - } - const existing = ownerDocument2.querySelector( - `[${WP_COMPAT_OVERLAY_SLOT_ATTRIBUTE}]` - ); - if (existing instanceof HTMLDivElement) { - cachedSlot = ensureSlotIsAccessible(existing); - return cachedSlot; - } - if (cachedSlot?.isConnected) { - cachedSlot.remove(); - } - cachedSlot = ensureSlotIsAccessible(createSlot(ownerDocument2)); - return cachedSlot; -} - -// packages/ui/build-module/tooltip/portal.mjs -var import_jsx_runtime21 = __toESM(require_jsx_runtime(), 1); -var Portal = (0, import_element15.forwardRef)( - function TooltipPortal3({ container, ...restProps }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)( - index_parts_exports.Portal, - { - container: container ?? getWpCompatOverlaySlot(), - ...restProps, - ref - } - ); - } -); -// packages/ui/build-module/tooltip/positioner.mjs -var import_element16 = __toESM(require_element(), 1); -var import_jsx_runtime22 = __toESM(require_jsx_runtime(), 1); +// packages/ui/build-module/link/link.mjs +var import_element17 = __toESM(require_element(), 1); +var import_i18n2 = __toESM(require_i18n(), 1); +var import_jsx_runtime19 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE6 = "data-wp-hash"; function getRuntime6() { const globalScope = globalThis; @@ -9434,64 +9403,115 @@ if (typeof process === "undefined" || true) { } var resets_default2 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; if (typeof process === "undefined" || true) { - registerStyle6("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); + registerStyle6("08122b3d53", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); } -var style_default5 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; -var Positioner = (0, import_element16.forwardRef)( - function TooltipPositioner3({ align = "center", className, side = "top", sideOffset = 4, ...props }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)( - index_parts_exports.Positioner, - { - ref, - align, - side, - sideOffset, - ...props, - className: clsx_default( - resets_default2["box-sizing"], - style_default5.positioner, - className - ) - } - ); - } -); - -// packages/ui/build-module/utils/render-slot-with-children.mjs -var import_element17 = __toESM(require_element(), 1); -function renderSlotWithChildren(slot, defaultSlot, children) { - return (0, import_element17.cloneElement)(slot ?? defaultSlot, { children }); +var focus_module_default = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; +if (typeof process === "undefined" || true) { + registerStyle6("e8e6a9be37", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}'); } +var style_default5 = { "link": "d4250949359b05ce__link", "is-brand": "c6055659b8e2cd2c__is-brand", "is-neutral": "_92e0dfcaeee15b88__is-neutral", "is-unstyled": "cf122a9bf1035d42__is-unstyled", "link-icon": "_0cb411afac4c86c7__link-icon" }; +if (typeof process === "undefined" || true) { + registerStyle6("e8e31009f5", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}"); +} +var global_css_defense_default2 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a", "ol": "c59a0ebebd71fa4a__ol", "li": "_46b5cb0c8e24e8c9__li" }; +var Link = (0, import_element17.forwardRef)(function Link2({ + children, + variant = "default", + tone = "brand", + openInNewTab = false, + target, + render, + className, + ...props +}, ref) { + const shouldShowNewTabIndicator = openInNewTab || /^_blank$/i.test(target ?? ""); + const element = useRender({ + render, + defaultTagName: "a", + ref, + props: mergeProps(props, { + className: clsx_default( + global_css_defense_default2.a, + resets_default2["box-sizing"], + focus_module_default["outset-ring--focus-except-active"], + variant !== "unstyled" && style_default5.link, + variant !== "unstyled" && style_default5[`is-${tone}`], + variant === "unstyled" && style_default5["is-unstyled"], + className + ), + target: target ?? (openInNewTab ? "_blank" : void 0), + children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(import_jsx_runtime19.Fragment, { children: [ + children, + shouldShowNewTabIndicator && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)( + "span", + { + className: style_default5["link-icon"], + role: "img", + "aria-label": ( + /* translators: accessibility text appended to link text */ + (0, import_i18n2.__)("(opens in a new tab)") + ) + } + ) + ] }) + }) + }); + return element; +}); -// packages/ui/build-module/utils/theme-provider.mjs -var theme = __toESM(require_theme(), 1); +// packages/icons/build-module/library/caution.mjs +var import_primitives = __toESM(require_primitives(), 1); +var import_jsx_runtime20 = __toESM(require_jsx_runtime(), 1); +var caution_default = /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives.Path, { d: "M12 8L12 13M12 14.5L12 16M4.75 12C4.75 7.99593 7.99594 4.75 12 4.75C16.0041 4.75 19.25 7.99594 19.25 12C19.25 16.0041 16.0041 19.25 12 19.25C7.99594 19.25 4.75 16.0041 4.75 12Z", strokeLinejoin: "round", vectorEffect: "non-scaling-stroke" }) }); -// packages/ui/build-module/lock-unlock.mjs -var import_private_apis = __toESM(require_private_apis(), 1); -var { lock, unlock } = (0, import_private_apis.__dangerousOptInToUnstableAPIsOnlyForCoreModules)( - "I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.", - "@wordpress/ui" -); +// packages/icons/build-module/library/close-small.mjs +var import_primitives2 = __toESM(require_primitives(), 1); +var import_jsx_runtime21 = __toESM(require_jsx_runtime(), 1); +var close_small_default = /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_primitives2.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_primitives2.Path, { d: "M7.75 16.25L16.25 7.75M16.25 16.25L7.75 7.75", vectorEffect: "non-scaling-stroke" }) }); -// packages/ui/build-module/utils/theme-provider.mjs -function getThemeProvider() { - const themePackage = theme; - if (themePackage.ThemeProvider) { - return themePackage.ThemeProvider; - } - if (!themePackage.privateApis) { - throw new Error( - "@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`." - ); - } - return unlock( - themePackage.privateApis - ).ThemeProvider; -} -var ThemeProvider = getThemeProvider(); +// packages/icons/build-module/library/error.mjs +var import_primitives3 = __toESM(require_primitives(), 1); +var import_jsx_runtime22 = __toESM(require_jsx_runtime(), 1); +var error_default = /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_primitives3.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_primitives3.Path, { fillRule: "evenodd", clipRule: "evenodd", d: "M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z" }) }); -// packages/ui/build-module/tooltip/popup.mjs +// packages/icons/build-module/library/info.mjs +var import_primitives4 = __toESM(require_primitives(), 1); var import_jsx_runtime23 = __toESM(require_jsx_runtime(), 1); +var info_default = /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_primitives4.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_primitives4.Path, { d: "M12 16V11M12 9.5V8M19.25 12C19.25 16.0041 16.0041 19.25 12 19.25C7.99594 19.25 4.75 16.0041 4.75 12C4.75 7.99594 7.99594 4.75 12 4.75C16.0041 4.75 19.25 7.99594 19.25 12Z", strokeLinejoin: "round", vectorEffect: "non-scaling-stroke" }) }); + +// packages/icons/build-module/library/published.mjs +var import_primitives5 = __toESM(require_primitives(), 1); +var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); +var published_default = /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_primitives5.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: [ + /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_primitives5.Path, { d: "M12 19.25C16.0041 19.25 19.25 16.0041 19.25 12C19.25 7.99594 16.0041 4.75 12 4.75C7.99594 4.75 4.75 7.99594 4.75 12C4.75 16.0041 7.99594 19.25 12 19.25Z", strokeLinejoin: "round", vectorEffect: "non-scaling-stroke" }), + /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_primitives5.Path, { d: "M9 12L11 14L15 10", vectorEffect: "non-scaling-stroke" }) +] }); + +// packages/ui/build-module/icon/icon.mjs +var import_element18 = __toESM(require_element(), 1); +var import_primitives6 = __toESM(require_primitives(), 1); +var import_jsx_runtime25 = __toESM(require_jsx_runtime(), 1); +var Icon = (0, import_element18.forwardRef)(function Icon2({ icon, size: size4 = 24, style, ...restProps }, ref) { + const mergedStyle = icon.props.style || style ? { ...icon.props.style, ...style } : void 0; + return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)( + import_primitives6.SVG, + { + ref, + ...icon.props, + ...restProps, + ...mergedStyle ? { style: mergedStyle } : {}, + width: size4, + height: size4 + } + ); +}); + +// packages/ui/build-module/utils/keyboard-shortcut.mjs +var import_element20 = __toESM(require_element(), 1); +var import_i18n3 = __toESM(require_i18n(), 1); + +// packages/ui/build-module/visually-hidden/visually-hidden.mjs +var import_element19 = __toESM(require_element(), 1); var STYLE_HASH_ATTRIBUTE7 = "data-wp-hash"; function getRuntime7() { const globalScope = globalThis; @@ -9573,56 +9593,69 @@ function registerStyle7(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle7("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); + registerStyle7("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); } -var style_default6 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; -var POPUP_COLOR = { background: "#1e1e1e" }; -var Popup = (0, import_element18.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { - const popupContent = /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(ThemeProvider, { color: POPUP_COLOR, children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)( - index_parts_exports.Popup, - { +var style_default6 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; +var VisuallyHidden = (0, import_element19.forwardRef)( + function VisuallyHidden2({ render, ...restProps }, ref) { + const element = useRender({ + render, ref, - className: clsx_default(style_default6.popup, className), - ...props, - children - } - ) }); - const positionedPopup = renderSlotWithChildren( - positioner, - /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Positioner, {}), - popupContent - ); - return renderSlotWithChildren(portal, /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(Portal, {}), positionedPopup); -}); - -// packages/ui/build-module/tooltip/trigger.mjs -var import_element19 = __toESM(require_element(), 1); -var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); -var Trigger = (0, import_element19.forwardRef)( - function TooltipTrigger3(props, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(index_parts_exports.Trigger, { ref, ...props }); + props: mergeProps( + { className: style_default6["visually-hidden"] }, + restProps, + { + // @ts-expect-error Arbitrary data-* attributes aren't indexable on the typed div props. Kept hardcoded so consumers can't change or remove it. + "data-visually-hidden": "" + } + ) + }); + return element; } ); -// packages/ui/build-module/utils/direction-provider.mjs -var import_i18n2 = __toESM(require_i18n(), 1); -var import_jsx_runtime25 = __toESM(require_jsx_runtime(), 1); -function DirectionProvider3({ children }) { - return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(DirectionProvider, { direction: (0, import_i18n2.isRTL)() ? "rtl" : "ltr", children }); -} - -// packages/ui/build-module/tooltip/root.mjs +// packages/ui/build-module/utils/keyboard-shortcut.mjs var import_jsx_runtime26 = __toESM(require_jsx_runtime(), 1); -function Root(props) { - return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(DirectionProvider3, { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(index_parts_exports.Root, { ...props }) }); +function useKeyboardShortcutProps({ + "aria-describedby": ariaDescribedBy, + "aria-keyshortcuts": ariaKeyShortcuts, + shortcut +}) { + const generatedDescriptionId = (0, import_element20.useId)(); + const descriptionId = shortcut ? generatedDescriptionId : void 0; + const describedBy = [ariaDescribedBy, descriptionId].filter(Boolean).join(" "); + return { + descriptionId, + targetProps: { + "aria-describedby": describedBy || void 0, + "aria-keyshortcuts": shortcut?.ariaKeyShortcut ?? ariaKeyShortcuts + } + }; } +var KeyboardShortcutDescription = (0, import_element20.forwardRef)(function KeyboardShortcutDescription2({ descriptionId, shortcut }, ref) { + return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)( + VisuallyHidden, + { + id: descriptionId, + "aria-hidden": "true", + render: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { ref }), + children: (0, import_i18n3.sprintf)( + /* translators: %s: keyboard shortcut. */ + (0, import_i18n3.__)("Keyboard shortcut: %s"), + shortcut.label ?? shortcut.ariaKeyShortcut + ) + } + ); +}); +var KeyboardShortcutDisplay = (0, import_element20.forwardRef)(function KeyboardShortcutDisplay2({ className, shortcut }, ref) { + return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { ref, "aria-hidden": "true", className, dir: "ltr", children: shortcut.displayShortcut }); +}); -// packages/ui/build-module/utils/keyboard-shortcut.mjs +// packages/ui/build-module/button/button.mjs var import_element21 = __toESM(require_element(), 1); -var import_i18n3 = __toESM(require_i18n(), 1); - -// packages/ui/build-module/visually-hidden/visually-hidden.mjs -var import_element20 = __toESM(require_element(), 1); +var import_i18n4 = __toESM(require_i18n(), 1); +var import_jsx_runtime27 = __toESM(require_jsx_runtime(), 1); +import { speak } from "@wordpress/a11y"; var STYLE_HASH_ATTRIBUTE8 = "data-wp-hash"; function getRuntime8() { const globalScope = globalThis; @@ -9704,65 +9737,66 @@ function registerStyle8(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle8("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); + registerStyle8("effc4e3032", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); } -var style_default7 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; -var VisuallyHidden = (0, import_element20.forwardRef)( - function VisuallyHidden2({ render, ...restProps }, ref) { - const element = useRender({ - render, - ref, - props: mergeProps( - { className: style_default7["visually-hidden"] }, - restProps, - { - // @ts-expect-error Arbitrary data-* attributes aren't indexable on the typed div props. Kept hardcoded so consumers can't change or remove it. - "data-visually-hidden": "" - } - ) - }); - return element; +var style_default7 = { "button": "_97b0fc33c028be1a__button", "is-unstyled": "abbb272e2ce49bd6__is-unstyled", "is-loading": "_914b42f315c0e580__is-loading", "is-small": "_908205475f9f2a92__is-small", "icon": "_9f6fc6553aeb36fe__icon", "is-brand": "dd460c965226cc77__is-brand", "is-outline": "_62d5a778b7b258ee__is-outline", "is-minimal": "ad0619a3217c6a5b__is-minimal", "is-neutral": "e722a8f96726aa99__is-neutral", "is-solid": "b50b3358c5fb4d0b__is-solid", "is-compact": "cf59cf1b69629838__is-compact", "loading-animation": "_5a1d53da6f830c8d__loading-animation" }; +if (typeof process === "undefined" || true) { + registerStyle8("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); +} +var resets_default3 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; +if (typeof process === "undefined" || true) { + registerStyle8("08122b3d53", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); +} +var focus_module_default2 = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; +if (typeof process === "undefined" || true) { + registerStyle8("e8e31009f5", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}"); +} +var global_css_defense_default3 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a", "ol": "c59a0ebebd71fa4a__ol", "li": "_46b5cb0c8e24e8c9__li" }; +var Button3 = (0, import_element21.forwardRef)( + function Button22({ + tone = "brand", + variant = "solid", + size: size4 = "default", + className, + focusableWhenDisabled = true, + disabled: disabled2, + loading, + loadingAnnouncement = (0, import_i18n4.__)("Loading"), + children, + ...props + }, ref) { + const mergedClassName = clsx_default( + global_css_defense_default3.button, + resets_default3["box-sizing"], + focus_module_default2["outset-ring--focus-except-active"], + variant !== "unstyled" && style_default7.button, + style_default7[`is-${tone}`], + style_default7[`is-${variant}`], + style_default7[`is-${size4}`], + loading && style_default7["is-loading"], + className + ); + (0, import_element21.useEffect)(() => { + if (loading && loadingAnnouncement) { + speak(loadingAnnouncement); + } + }, [loading, loadingAnnouncement]); + return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( + Button, + { + ref, + className: mergedClassName, + focusableWhenDisabled, + disabled: disabled2 ?? loading, + ...props, + children + } + ); } ); -// packages/ui/build-module/utils/keyboard-shortcut.mjs -var import_jsx_runtime27 = __toESM(require_jsx_runtime(), 1); -function useKeyboardShortcutProps({ - "aria-describedby": ariaDescribedBy, - "aria-keyshortcuts": ariaKeyShortcuts, - shortcut -}) { - const generatedDescriptionId = (0, import_element21.useId)(); - const descriptionId = shortcut ? generatedDescriptionId : void 0; - const describedBy = [ariaDescribedBy, descriptionId].filter(Boolean).join(" "); - return { - descriptionId, - targetProps: { - "aria-describedby": describedBy || void 0, - "aria-keyshortcuts": shortcut?.ariaKeyShortcut ?? ariaKeyShortcuts - } - }; -} -var KeyboardShortcutDescription = (0, import_element21.forwardRef)(function KeyboardShortcutDescription2({ descriptionId, shortcut }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)( - VisuallyHidden, - { - id: descriptionId, - "aria-hidden": "true", - render: /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { ref }), - children: (0, import_i18n3.sprintf)( - /* translators: %s: keyboard shortcut. */ - (0, import_i18n3.__)("Keyboard shortcut: %s"), - shortcut.label ?? shortcut.ariaKeyShortcut - ) - } - ); -}); -var KeyboardShortcutDisplay = (0, import_element21.forwardRef)(function KeyboardShortcutDisplay2({ className, shortcut }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("span", { ref, "aria-hidden": "true", className, dir: "ltr", children: shortcut.displayShortcut }); -}); - -// packages/ui/build-module/icon-button/icon-button.mjs +// packages/ui/build-module/button/icon.mjs +var import_element22 = __toESM(require_element(), 1); var import_jsx_runtime28 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE9 = "data-wp-hash"; function getRuntime9() { @@ -9845,74 +9879,37 @@ function registerStyle9(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle9("c5cdafb1bc", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}"); + registerStyle9("effc4e3032", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}'); } -var style_default8 = { "icon-button": "_28cfdc260e755391__icon-button", "icon": "f1c70d719989a85a__icon" }; -var IconButton = (0, import_element22.forwardRef)( - function IconButton2({ - label, - className, - // Prevent accidental forwarding of `children` - children: _children, - disabled: disabled2, - focusableWhenDisabled = true, - icon, - size: size4, - shortcut, - positioner, - "aria-describedby": ariaDescribedBy, - "aria-keyshortcuts": ariaKeyShortcuts, - ...restProps - }, ref) { - const classes = clsx_default(style_default8["icon-button"], className); - const { descriptionId, targetProps } = useKeyboardShortcutProps({ - "aria-describedby": ariaDescribedBy, - "aria-keyshortcuts": ariaKeyShortcuts, - shortcut - }); - return /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(Root, { children: [ - /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)( - Trigger, - { - ref, - ...targetProps, - disabled: disabled2 && !focusableWhenDisabled, - render: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( - Button4, - { - ...restProps, - size: size4, - "aria-label": label, - disabled: disabled2, - focusableWhenDisabled - } - ), - className: classes, - children: [ - /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Icon, { icon, size: 24, className: style_default8.icon }), - shortcut && descriptionId && /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( - KeyboardShortcutDescription, - { - descriptionId, - shortcut - } - ) - ] - } - ), - /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(Popup, { positioner, children: [ - label, - shortcut && /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_jsx_runtime28.Fragment, { children: [ - " ", - /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(KeyboardShortcutDisplay, { shortcut }) - ] }) - ] }) - ] }); +var style_default8 = { "button": "_97b0fc33c028be1a__button", "is-unstyled": "abbb272e2ce49bd6__is-unstyled", "is-loading": "_914b42f315c0e580__is-loading", "is-small": "_908205475f9f2a92__is-small", "icon": "_9f6fc6553aeb36fe__icon", "is-brand": "dd460c965226cc77__is-brand", "is-outline": "_62d5a778b7b258ee__is-outline", "is-minimal": "ad0619a3217c6a5b__is-minimal", "is-neutral": "e722a8f96726aa99__is-neutral", "is-solid": "b50b3358c5fb4d0b__is-solid", "is-compact": "cf59cf1b69629838__is-compact", "loading-animation": "_5a1d53da6f830c8d__loading-animation" }; +var ButtonIcon = (0, import_element22.forwardRef)( + function ButtonIcon2({ className, icon, ...props }, ref) { + return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)( + Icon, + { + ref, + icon, + className: clsx_default(style_default8.icon, className), + size: 24, + ...props + } + ); } ); -// packages/ui/build-module/stack/stack.mjs +// packages/ui/build-module/button/index.mjs +ButtonIcon.displayName = "Button.Icon"; +var Button4 = Object.assign(Button3, { + /** + * An icon component specifically designed to work well when rendered inside + * a `Button` component. + */ + Icon: ButtonIcon +}); + +// packages/ui/build-module/icon-button/icon-button.mjs var import_element23 = __toESM(require_element(), 1); +var import_jsx_runtime29 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE10 = "data-wp-hash"; function getRuntime10() { const globalScope = globalThis; @@ -9994,38 +9991,74 @@ function registerStyle10(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle10("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); + registerStyle10("c5cdafb1bc", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}"); } -var style_default9 = { "stack": "_19ce0419607e1896__stack" }; -var gapTokens = { - xs: "var(--wpds-dimension-gap-xs, 4px)", - sm: "var(--wpds-dimension-gap-sm, 8px)", - md: "var(--wpds-dimension-gap-md, 12px)", - lg: "var(--wpds-dimension-gap-lg, 16px)", - xl: "var(--wpds-dimension-gap-xl, 24px)", - "2xl": "var(--wpds-dimension-gap-2xl, 32px)", - "3xl": "var(--wpds-dimension-gap-3xl, 40px)" -}; -var Stack = (0, import_element23.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { - const style = { - gap: gap && gapTokens[gap], - alignItems: align, - justifyContent: justify, - flexDirection: direction, - flexWrap: wrap - }; - const element = useRender({ - render, - ref, - props: mergeProps(props, { style, className: style_default9.stack }) - }); - return element; -}); +var style_default9 = { "icon-button": "_28cfdc260e755391__icon-button", "icon": "f1c70d719989a85a__icon" }; +var IconButton = (0, import_element23.forwardRef)( + function IconButton2({ + label, + className, + // Prevent accidental forwarding of `children` + children: _children, + disabled: disabled2, + focusableWhenDisabled = true, + icon, + size: size4, + shortcut, + positioner, + "aria-describedby": ariaDescribedBy, + "aria-keyshortcuts": ariaKeyShortcuts, + ...restProps + }, ref) { + const classes = clsx_default(style_default9["icon-button"], className); + const { descriptionId, targetProps } = useKeyboardShortcutProps({ + "aria-describedby": ariaDescribedBy, + "aria-keyshortcuts": ariaKeyShortcuts, + shortcut + }); + return /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(Root, { children: [ + /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)( + Trigger, + { + ref, + ...targetProps, + disabled: disabled2 && !focusableWhenDisabled, + render: /* @__PURE__ */ (0, import_jsx_runtime29.jsx)( + Button4, + { + ...restProps, + size: size4, + "aria-label": label, + disabled: disabled2, + focusableWhenDisabled + } + ), + className: classes, + children: [ + /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(Icon, { icon, size: 24, className: style_default9.icon }), + shortcut && descriptionId && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)( + KeyboardShortcutDescription, + { + descriptionId, + shortcut + } + ) + ] + } + ), + /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(Popup, { positioner, children: [ + label, + shortcut && /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_jsx_runtime29.Fragment, { children: [ + " ", + /* @__PURE__ */ (0, import_jsx_runtime29.jsx)(KeyboardShortcutDisplay, { shortcut }) + ] }) + ] }) + ] }); + } +); -// packages/ui/build-module/link/link.mjs +// packages/ui/build-module/stack/stack.mjs var import_element24 = __toESM(require_element(), 1); -var import_i18n4 = __toESM(require_i18n(), 1); -var import_jsx_runtime29 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE11 = "data-wp-hash"; function getRuntime11() { const globalScope = globalThis; @@ -10107,60 +10140,30 @@ function registerStyle11(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle11("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); -} -var resets_default3 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; -if (typeof process === "undefined" || true) { - registerStyle11("96553466c8", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); -} -var focus_module_default2 = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-within-visible": "_64de9947bf305b7a__outset-ring--focus-within-visible", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; -if (typeof process === "undefined" || true) { - registerStyle11("e8e6a9be37", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}'); -} -var style_default10 = { "link": "d4250949359b05ce__link", "is-brand": "c6055659b8e2cd2c__is-brand", "is-neutral": "_92e0dfcaeee15b88__is-neutral", "is-unstyled": "cf122a9bf1035d42__is-unstyled", "link-icon": "_0cb411afac4c86c7__link-icon" }; -if (typeof process === "undefined" || true) { - registerStyle11("af6d9984a6", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}"); + registerStyle11("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); } -var global_css_defense_default3 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a" }; -var Link = (0, import_element24.forwardRef)(function Link2({ - children, - variant = "default", - tone = "brand", - openInNewTab = false, - render, - className, - ...props -}, ref) { +var style_default10 = { "stack": "_19ce0419607e1896__stack" }; +var gapTokens = { + xs: "var(--wpds-dimension-gap-xs, 4px)", + sm: "var(--wpds-dimension-gap-sm, 8px)", + md: "var(--wpds-dimension-gap-md, 12px)", + lg: "var(--wpds-dimension-gap-lg, 16px)", + xl: "var(--wpds-dimension-gap-xl, 24px)", + "2xl": "var(--wpds-dimension-gap-2xl, 32px)", + "3xl": "var(--wpds-dimension-gap-3xl, 40px)" +}; +var Stack = (0, import_element24.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { + const style = { + gap: gap && gapTokens[gap], + alignItems: align, + justifyContent: justify, + flexDirection: direction, + flexWrap: wrap + }; const element = useRender({ render, - defaultTagName: "a", ref, - props: mergeProps(props, { - className: clsx_default( - global_css_defense_default3.a, - resets_default3["box-sizing"], - focus_module_default2["outset-ring--focus-except-active"], - variant !== "unstyled" && style_default10.link, - variant !== "unstyled" && style_default10[`is-${tone}`], - variant === "unstyled" && style_default10["is-unstyled"], - className - ), - target: openInNewTab ? "_blank" : void 0, - children: /* @__PURE__ */ (0, import_jsx_runtime29.jsxs)(import_jsx_runtime29.Fragment, { children: [ - children, - openInNewTab && /* @__PURE__ */ (0, import_jsx_runtime29.jsx)( - "span", - { - className: style_default10["link-icon"], - role: "img", - "aria-label": ( - /* translators: accessibility text appended to link text */ - (0, import_i18n4.__)("(opens in a new tab)") - ) - } - ) - ] }) - }) + props: mergeProps(props, { style, className: style_default10.stack }) }); return element; }); @@ -10266,7 +10269,7 @@ if (typeof process === "undefined" || true) { } var resets_default4 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; if (typeof process === "undefined" || true) { - registerStyle12("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle12("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default11 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var icons = { @@ -10424,7 +10427,7 @@ function registerStyle13(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle13("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle13("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default12 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var Title = (0, import_element26.forwardRef)( @@ -10525,7 +10528,7 @@ function registerStyle14(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle14("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle14("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default13 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var Description = (0, import_element27.forwardRef)( @@ -10625,7 +10628,7 @@ function registerStyle15(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle15("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle15("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default14 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var Actions = (0, import_element28.forwardRef)( @@ -10730,7 +10733,7 @@ function registerStyle16(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle16("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle16("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default15 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var CloseIcon = (0, import_element29.forwardRef)( @@ -10835,7 +10838,7 @@ function registerStyle17(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle17("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle17("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default16 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var ActionButton = (0, import_element30.forwardRef)( @@ -10944,7 +10947,7 @@ function registerStyle18(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle18("726c480820", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); + registerStyle18("42aad93a67", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}"); } var style_default17 = { "notice": "_4145abab73d17514__notice", "icon": "d0a25570cb528528__icon", "title": "b5397fb9d05389e3__title", "description": "_1904b570a89bb815__description", "actions": "_0a1270dcdd79c031__actions", "action-button": "_983740ab855c4e09__action-button", "action-link": "d329e7416d368d31__action-link", "close-icon": "_487e6a5c1375f7dc__close-icon", "is-info": "_531c140826094795__is-info", "is-warning": "ae2e1004697cce95__is-warning", "is-success": "_2e614a76af494837__is-success", "is-error": "af00331ae17a0065__is-error", "is-action-button-outline": "_8ddb8fb33fbf3d38__is-action-button-outline", "is-action-button-minimal": "_77bbde495a8a0af3__is-action-button-minimal" }; var ActionLink = (0, import_element31.forwardRef)( @@ -11476,10 +11479,10 @@ var { lock: lock2, unlock: unlock2 } = (0, import_private_apis2.__dangerousOptIn ); // routes/connectors-home/style.scss -if (typeof document !== "undefined" && true && !document.head.querySelector("style[data-wp-hash='09e9b056ea']")) { +if (typeof document !== "undefined" && true && !document.head.querySelector("style[data-wp-hash='3ac7d2cc0e']")) { const style = document.createElement("style"); - style.setAttribute("data-wp-hash", "09e9b056ea"); - style.appendChild(document.createTextNode(".connectors-page{box-sizing:border-box;margin:0 auto;max-width:680px;padding:24px;width:100%}.connectors-page .components-item{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;padding:20px;scroll-margin-top:120px}.connectors-page .connector-settings__error{color:#cc1818}.connectors-page .connector-settings .components-text-control__input{font-family:monospace;scroll-margin-top:120px}.connectors-page__file-mods-notice{margin-bottom:16px}.connectors-page--empty{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:32px;justify-content:center;text-align:center}.connectors-page .ai-plugin-callout{background-color:#e7d4e4;background-image:radial-gradient(ellipse 70% 120% at 18% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 92% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 58% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%);border-radius:8px;overflow:hidden;padding:24px;padding-inline-end:150px;position:relative}[dir=rtl] .connectors-page .ai-plugin-callout{background-image:radial-gradient(ellipse 70% 120% at 82% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 8% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 42% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%)}.connectors-page .ai-plugin-callout__content{align-items:flex-start;display:flex;flex-direction:column;gap:12px;padding-top:2px}.connectors-page .ai-plugin-callout__content p{font-size:13px;line-height:20px;margin:0}.connectors-page .ai-plugin-callout__decoration{height:110px;inset-inline-end:16px;position:absolute;top:12px;width:110px}.connectors-page>p{color:#949494}@media (max-width:680px){.connectors-page .ai-plugin-callout{padding:12px;padding-inline-end:100px}.connectors-page .ai-plugin-callout__decoration{height:75px;inset-inline-end:8px;top:8px;width:75px}}@media (max-width:480px){.connectors-page{padding:8px}.connectors-page .ai-plugin-callout{padding-inline-end:130px}.connectors-page .components-item{padding:12px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child svg{height:32px;width:32px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child>.components-h-stack:last-child{align-items:flex-end;flex-direction:column}}")); + style.setAttribute("data-wp-hash", "3ac7d2cc0e"); + style.appendChild(document.createTextNode(".connectors-page{box-sizing:border-box;margin:0 auto;max-width:680px;padding:24px;width:100%}.connectors-page .components-item{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;padding:20px;scroll-margin-top:120px}.connectors-page .connector-settings__error{color:#cc1818}.connectors-page .connector-settings .components-text-control__input{font-family:monospace;scroll-margin-top:120px}.connectors-page__file-mods-notice{margin-bottom:16px}.connectors-page--empty{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:32px;justify-content:center;text-align:center}.connectors-page .ai-plugin-callout{background-color:#e7d4e4;background-image:radial-gradient(ellipse 70% 120% at 18% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 92% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 58% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%);border-radius:8px;overflow:hidden;padding:24px;padding-inline-end:150px;position:relative}[dir=rtl] .connectors-page .ai-plugin-callout{background-image:radial-gradient(ellipse 70% 120% at 82% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 8% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 42% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%)}.connectors-page .ai-plugin-callout__content{align-items:flex-start;display:flex;flex-direction:column;gap:12px;padding-top:2px}.connectors-page .ai-plugin-callout__content p{font-size:13px;line-height:20px;margin:0}.connectors-page .ai-plugin-callout__decoration{height:110px;inset-inline-end:16px;position:absolute;top:12px;width:110px}.connectors-page__help-text{color:#757575}@media (max-width:680px){.connectors-page .ai-plugin-callout{padding:12px;padding-inline-end:100px}.connectors-page .ai-plugin-callout__decoration{height:75px;inset-inline-end:8px;top:8px;width:75px}}@media (max-width:480px){.connectors-page{padding:8px}.connectors-page .ai-plugin-callout{padding-inline-end:130px}.connectors-page .components-item{padding:12px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child svg{height:32px;width:32px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child>.components-h-stack:last-child{align-items:flex-end;flex-direction:column}}")); document.head.appendChild(style); } @@ -12690,7 +12693,7 @@ function ConnectorsPage() { } ) }) ] }), - canInstallPlugins && !isFileModDisabled && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("p", { children: (0, import_element36.createInterpolateElement)( + canInstallPlugins && !isFileModDisabled && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("p", { className: "connectors-page__help-text", children: (0, import_element36.createInterpolateElement)( (0, import_i18n10.__)( "If the connector you need is not listed, search the plugin directory to see if a connector is available." ), diff --git a/src/wp-includes/build/routes/connectors-home/content.min.asset.php b/src/wp-includes/build/routes/connectors-home/content.min.asset.php index 1dda70de8f9a3..218d4f7011497 100644 --- a/src/wp-includes/build/routes/connectors-home/content.min.asset.php +++ b/src/wp-includes/build/routes/connectors-home/content.min.asset.php @@ -1 +1 @@ - array('react', 'react-dom', 'react-jsx-runtime', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-private-apis', 'wp-theme', 'wp-url', 'wp-warning'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/connectors', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '9c97839e08e086000847'); \ No newline at end of file + array('react', 'react-dom', 'react-jsx-runtime', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-private-apis', 'wp-theme', 'wp-url', 'wp-warning'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/connectors', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '16b7fec75bfa6a8fa4db'); \ No newline at end of file diff --git a/src/wp-includes/build/routes/connectors-home/content.min.js b/src/wp-includes/build/routes/connectors-home/content.min.js index 2296c11a9ccd8..341bc8c92e33d 100644 --- a/src/wp-includes/build/routes/connectors-home/content.min.js +++ b/src/wp-includes/build/routes/connectors-home/content.min.js @@ -1,4 +1,4 @@ -var Zf=Object.create;var Ir=Object.defineProperty;var Qf=Object.getOwnPropertyDescriptor;var Jf=Object.getOwnPropertyNames;var $f=Object.getPrototypeOf,ep=Object.prototype.hasOwnProperty;var Te=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Mt=(e,t)=>{for(var o in t)Ir(e,o,{get:t[o],enumerable:!0})},tp=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Jf(t))!ep.call(e,r)&&r!==o&&Ir(e,r,{get:()=>t[r],enumerable:!(n=Qf(t,r))||n.enumerable});return e};var b=(e,t,o)=>(o=e!=null?Zf($f(e)):{},tp(t||!e||!e.__esModule?Ir(o,"default",{value:e,enumerable:!0}):o,e));var st=Te(($h,da)=>{da.exports=window.wp.i18n});var ce=Te((t0,fa)=>{fa.exports=window.wp.element});var z=Te((o0,pa)=>{pa.exports=window.React});var W=Te((l0,ha)=>{ha.exports=window.ReactJSXRuntime});var Ht=Te((bw,Ua)=>{Ua.exports=window.ReactDOM});var Gc=Te(Uc=>{"use strict";var xo=z();function ng(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var rg=typeof Object.is=="function"?Object.is:ng,ig=xo.useState,sg=xo.useEffect,ag=xo.useLayoutEffect,cg=xo.useDebugValue;function lg(e,t){var o=t(),n=ig({inst:{value:o,getSnapshot:t}}),r=n[0].inst,i=n[1];return ag(function(){r.value=o,r.getSnapshot=t,bi(r)&&i({inst:r})},[e,o,t]),sg(function(){return bi(r)&&i({inst:r}),e(function(){bi(r)&&i({inst:r})})},[e]),cg(o),o}function bi(e){var t=e.getSnapshot;e=e.value;try{var o=t();return!rg(e,o)}catch{return!0}}function dg(e,t){return t()}var ug=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?dg:lg;Uc.useSyncExternalStore=xo.useSyncExternalStore!==void 0?xo.useSyncExternalStore:ug});var Un=Te((av,Kc)=>{"use strict";Kc.exports=Gc()});var qc=Te(Xc=>{"use strict";var Gn=z(),fg=Un();function pg(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var mg=typeof Object.is=="function"?Object.is:pg,gg=fg.useSyncExternalStore,bg=Gn.useRef,hg=Gn.useEffect,wg=Gn.useMemo,vg=Gn.useDebugValue;Xc.useSyncExternalStoreWithSelector=function(e,t,o,n,r){var i=bg(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=wg(function(){function l(f){if(!c){if(c=!0,d=f,f=n(f),r!==void 0&&s.hasValue){var p=s.value;if(r(p,f))return m=p}return m=f}if(p=m,mg(d,f))return p;var g=n(f);return r!==void 0&&r(p,g)?(d=f,p):(d=f,m=g)}var c=!1,d,m,u=o===void 0?null:o;return[function(){return l(t())},u===null?void 0:function(){return l(u())}]},[t,o,n,r]);var a=gg(e,i[0],i[1]);return hg(function(){s.hasValue=!0,s.value=a},[a]),vg(a),a}});var Qc=Te((lv,Zc)=>{"use strict";Zc.exports=qc()});var so=Te((C4,Bd)=>{Bd.exports=window.wp.primitives});var nu=Te((r3,ou)=>{ou.exports=window.wp.theme});var fs=Te((i3,ru)=>{ru.exports=window.wp.privateApis});var rn=Te((U5,lf)=>{lf.exports=window.wp.components});var an=Te((i8,hf)=>{hf.exports=window.wp.data});var Tr=Te((s8,wf)=>{wf.exports=window.wp.coreData});var ea=Te((l8,_f)=>{_f.exports=window.wp.notices});var xf=Te((d8,yf)=>{yf.exports=window.wp.url});function ua(e){var t,o,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;te();function Y(e){let t=ke(ip).current;return t.next=e,rp(t.effect),t.trampoline}function ip(){let e={next:void 0,callback:sp,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function sp(){}var ba=b(z(),1),ap=()=>{},F=typeof document<"u"?ba.useLayoutEffect:ap;function cp(e,t){return function(n,...r){let i=new URL(e);return i.searchParams.set("code",n.toString()),r.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${n}; visit ${i} for the full message.`}}var lp=cp("https://base-ui.com/production-error","Base UI"),De=lp;var qt=b(z(),1);function Mr(e,t,o,n){let r=ke(va).current;return dp(r,e,t,o,n)&&_a(r,[e,t,o,n]),r.callback}function wa(e){let t=ke(va).current;return up(t,e)&&_a(t,e),t.callback}function va(){return{callback:null,cleanup:null,refs:[]}}function dp(e,t,o,n,r){return e.refs[0]!==t||e.refs[1]!==o||e.refs[2]!==n||e.refs[3]!==r}function up(e,t){return e.refs.length!==t.length||e.refs.some((o,n)=>o!==t[n])}function _a(e,t){if(e.refs=t,t.every(o=>o==null)){e.callback=null;return}e.callback=o=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),o!=null){let n=Array(t.length).fill(null);for(let r=0;r{for(let r=0;r=e}function Br(e){if(!xa.isValidElement(e))return null;let t=e,o=t.props;return(po(19)?o?.ref:t.ref)??null}function zo(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function Ge(){}var Sa=Object.freeze([]),me=Object.freeze({});function Ra(e,t){let o={};for(let n in e){let r=e[n];if(t?.hasOwnProperty(n)){let i=t[n](r);i!=null&&Object.assign(o,i);continue}r===!0?o[`data-${n.toLowerCase()}`]="":r&&(o[`data-${n.toLowerCase()}`]=r.toString())}return o}function Ea(e,t){return typeof e=="function"?e(t):e}function Ta(e,t){return typeof e=="function"?e(t):e}var Hr={};function ve(e,t,o,n,r){if(!o&&!n&&!r&&!e)return _n(t);let i=_n(e);return t&&(i=Do(i,t)),o&&(i=Do(i,o)),n&&(i=Do(i,n)),r&&(i=Do(i,r)),i}function ka(e){if(e.length===0)return Hr;if(e.length===1)return _n(e[0]);let t=_n(e[0]);for(let o=1;o=65&&r<=90&&(typeof t=="function"||typeof t>"u")}function zr(e){return typeof e=="function"}function Ca(e,t){return zr(e)?e(t):e??Hr}function gp(e,t){return t?e?(...o)=>{let n=o[0];if(Oa(n)){let i=n;jo(i);let s=t(...o);return i.baseUIHandlerPrevented||e?.(...o),s}let r=t(...o);return e?.(...o),r}:Aa(t):e}function Aa(e){return e&&((...t)=>{let o=t[0];return Oa(o)&&jo(o),e(...t)})}function jo(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Dr(e,t){return t?e?t+" "+e:t:e}function Oa(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var jr=b(z(),1);function Oe(e,t,o={}){let n=t.render,r=bp(t,o);if(o.enabled===!1)return null;let i=o.state??me;return vp(e,n,r,i)}function bp(e,t={}){let{className:o,style:n,render:r}=e,{state:i=me,ref:s,props:a,stateAttributesMapping:l,enabled:c=!0}=t,d=c?Ea(o,i):void 0,m=c?Ta(n,i):void 0,u=c?Ra(i,l):me,f=c&&a?hp(a):void 0,p=c?zo(u,f)??{}:me;return typeof document<"u"&&(c?Array.isArray(s)?p.ref=wa([p.ref,Br(r),...s]):p.ref=Mr(p.ref,Br(r),s):Mr(null,null)),c?(d!==void 0&&(p.className=Dr(p.className,d)),m!==void 0&&(p.style=zo(p.style,m)),p):me}function hp(e){return Array.isArray(e)?ka(e):ve(void 0,e)}var wp=Symbol.for("react.lazy");function vp(e,t,o,n){if(t){if(typeof t=="function")return t(o,n);let r=ve(o,t.props);r.ref=o.ref;let i=t;return i?.$$typeof===wp&&(i=qt.Children.toArray(t)[0]),qt.cloneElement(i,r)}if(e&&typeof e=="string")return _p(e,o);throw new Error(De(8))}function _p(e,t){return e==="button"?(0,jr.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,jr.createElement)("img",{alt:"",...t,key:t.key}):qt.createElement(e,t)}var yn=b(z(),1);var Na=0;function yp(e,t="mui"){let[o,n]=yn.useState(e),r=e||o;return yn.useEffect(()=>{o==null&&(Na+=1,n(`${t}-${Na}`))},[o,t]),r}var Ia=Ho.useId;function mo(e,t){if(Ia!==void 0){let o=Ia();return e??(t?`${t}-${o}`:o)}return yp(e,t)}function La(e){return mo(e,"base-ui")}var G={};Mt(G,{cancelOpen:()=>qp,chipRemovePress:()=>Op,clearPress:()=>Ap,closePress:()=>Pp,closeWatcher:()=>Vp,decrementPress:()=>Lp,disabled:()=>Qp,drag:()=>Gp,escapeKey:()=>Fp,focusOut:()=>jp,imperativeAction:()=>em,incrementPress:()=>Ip,initial:()=>$p,inputBlur:()=>Hp,inputChange:()=>Mp,inputClear:()=>Bp,inputPaste:()=>zp,inputPress:()=>Dp,itemPress:()=>kp,keyboard:()=>Yp,linkPress:()=>Cp,listNavigation:()=>Wp,missing:()=>Jp,none:()=>xp,outsidePress:()=>Tp,pointer:()=>Up,scrub:()=>Xp,siblingOpen:()=>Zp,swipe:()=>tm,trackPress:()=>Np,triggerFocus:()=>Ep,triggerHover:()=>Rp,triggerPress:()=>Sp,wheel:()=>Kp,windowResize:()=>om});var xp="none",Sp="trigger-press",Rp="trigger-hover",Ep="trigger-focus",Tp="outside-press",kp="item-press",Pp="close-press",Cp="link-press",Ap="clear-press",Op="chip-remove-press",Np="track-press",Ip="increment-press",Lp="decrement-press",Mp="input-change",Bp="input-clear",Hp="input-blur",zp="input-paste",Dp="input-press",jp="focus-out",Fp="escape-key",Vp="close-watcher",Wp="list-navigation",Yp="keyboard",Up="pointer",Gp="drag",Kp="wheel",Xp="scrub",qp="cancel-open",Zp="sibling-open",Qp="disabled",Jp="missing",$p="initial",em="imperative-action",tm="swipe",om="window-resize";function ee(e,t,o,n){let r=!1,i=!1,s=n??me;return{reason:e,event:t??new Event("base-ui"),cancel(){r=!0},allowPropagation(){i=!0},get isCanceled(){return r},get isPropagationAllowed(){return i},trigger:o,...s}}var Vr=b(z(),1);var Ma=b(z(),1);function go(e){Ma.useEffect(e,Sa)}var xn=null,Y0=globalThis.requestAnimationFrame,Fr=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let o=this.callbacks,n=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,n>0)for(let r=0;r=this.callbacks.length||(this.callbacks[o]=null,this.callbacksCount-=1)}},Sn=new Fr;var gt=class e{static create(){return new e}static request(t){return Sn.request(t)}static cancel(t){return Sn.cancel(t)}currentId=xn;request(t){this.cancel(),this.currentId=Sn.request(()=>{this.currentId=xn,t()})}cancel=()=>{this.currentId!==xn&&(Sn.cancel(this.currentId),this.currentId=xn)};disposeEffect=()=>this.cancel};function bo(){let e=ke(gt.create).current;return go(e.disposeEffect),e}function Ba(e,t=!1,o=!1){let[n,r]=Vr.useState(e&&t?"idle":void 0),[i,s]=Vr.useState(e);return e&&!i&&(s(!0),r("starting")),!e&&i&&n!=="ending"&&!o&&r("ending"),!e&&!i&&n==="ending"&&r(void 0),F(()=>{if(!e&&i&&n!=="ending"&&o){let a=gt.request(()=>{r("ending")});return()=>{gt.cancel(a)}}},[e,i,n,o]),F(()=>{if(!e||t)return;let a=gt.request(()=>{r(void 0)});return()=>{gt.cancel(a)}},[t,e]),F(()=>{if(!e||!t)return;e&&i&&n!=="idle"&&r("starting");let a=gt.request(()=>{r("idle")});return()=>{gt.cancel(a)}},[t,e,i,n]),{mounted:i,setMounted:s,transitionStatus:n}}var Wr=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),nm={"data-starting-style":""},rm={"data-ending-style":""},Ha={transitionStatus(e){return e==="starting"?nm:e==="ending"?rm:null}};var wo=b(z(),1);function Rn(){return typeof window<"u"}function Qt(e){return En(e)?(e.nodeName||"").toLowerCase():"#document"}function fe(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function ht(e){var t;return(t=(En(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function En(e){return Rn()?e instanceof Node||e instanceof fe(e).Node:!1}function U(e){return Rn()?e instanceof Element||e instanceof fe(e).Element:!1}function he(e){return Rn()?e instanceof HTMLElement||e instanceof fe(e).HTMLElement:!1}function ho(e){return!Rn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof fe(e).ShadowRoot}function Fo(e){let{overflow:t,overflowX:o,overflowY:n,display:r}=Le(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+o)&&r!=="inline"&&r!=="contents"}function za(e){return/^(table|td|th)$/.test(Qt(e))}function Vo(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var im=/transform|translate|scale|rotate|perspective|filter/,sm=/paint|layout|strict|content/,Zt=e=>!!e&&e!=="none",Yr;function Tn(e){let t=U(e)?Le(e):e;return Zt(t.transform)||Zt(t.translate)||Zt(t.scale)||Zt(t.rotate)||Zt(t.perspective)||!kn()&&(Zt(t.backdropFilter)||Zt(t.filter))||im.test(t.willChange||"")||sm.test(t.contain||"")}function Da(e){let t=bt(e);for(;he(t)&&!wt(t);){if(Tn(t))return t;if(Vo(t))return null;t=bt(t)}return null}function kn(){return Yr==null&&(Yr=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Yr}function wt(e){return/^(html|body|#document)$/.test(Qt(e))}function Le(e){return fe(e).getComputedStyle(e)}function Wo(e){return U(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function bt(e){if(Qt(e)==="html")return e;let t=e.assignedSlot||e.parentNode||ho(e)&&e.host||ht(e);return ho(t)?t.host:t}function ja(e){let t=bt(e);return wt(t)?(e.ownerDocument||e).body:he(t)&&Fo(t)?t:ja(t)}function Bt(e,t,o){var n;t===void 0&&(t=[]),o===void 0&&(o=!0);let r=ja(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),s=fe(r);if(i){let a=Pn(s);return t.concat(s,s.visualViewport||[],Fo(r)?r:[],a&&o?Bt(a):[])}else return t.concat(r,Bt(r,[],o))}function Pn(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}var Cn=b(z(),1),am=Cn.createContext(void 0);function Fa(e=!1){let t=Cn.useContext(am);if(t===void 0&&!e)throw new Error(De(16));return t}var Va=b(z(),1);function Wa(e){let{focusableWhenDisabled:t,disabled:o,composite:n=!1,tabIndex:r=0,isNativeButton:i}=e,s=n&&t!==!1,a=n&&t===!1;return{props:Va.useMemo(()=>{let c={onKeyDown(d){o&&t&&d.key!=="Tab"&&d.preventDefault()}};return n||(c.tabIndex=r,!i&&o&&(c.tabIndex=t?r:-1)),(i&&(t||s)||!i&&o)&&(c["aria-disabled"]=o),i&&(!t||a)&&(c.disabled=o),c},[n,o,t,s,a,i,r])}}function Pe(e){return e?.ownerDocument||document}function An(e,t,{detail:o=0}={}){e.dispatchEvent(new(fe(e)).PointerEvent("click",{bubbles:!0,cancelable:!0,composed:!0,detail:o,shiftKey:t.shiftKey,ctrlKey:t.ctrlKey,altKey:t.altKey,metaKey:t.metaKey}))}function Ya(e={}){let{disabled:t=!1,focusableWhenDisabled:o,tabIndex:n=0,native:r=!0,composite:i}=e,s=wo.useRef(null),a=Fa(!0),l=i??a!==void 0,{props:c}=Wa({focusableWhenDisabled:o,disabled:t,composite:l,tabIndex:n,isNativeButton:r}),d=wo.useCallback(()=>{let f=s.current;Ur(f)&&l&&t&&c.disabled===void 0&&f.disabled&&(f.disabled=!1)},[t,c.disabled,l]);F(d,[d]);let m=wo.useCallback((f={})=>{let{onClick:p,onMouseDown:g,onKeyUp:h,onKeyDown:y,onPointerDown:_,...v}=f;return ve({onClick(w){if(t){w.preventDefault();return}p?.(w)},onMouseDown(w){t||g?.(w)},onKeyDown(w){if(t||(jo(w),y?.(w),w.baseUIHandlerPrevented))return;let R=w.target===w.currentTarget,x=w.currentTarget,S=Ur(x),E=!r&&cm(x),T=R&&(r?S:!E),P=w.key==="Enter",N=w.key===" ",H=x.getAttribute("role"),j=H?.startsWith("menuitem")||H==="option"||H==="gridcell";if(R&&l&&N){if(w.defaultPrevented&&j)return;w.preventDefault(),(!r||S)&&(w.preventBaseUIHandler(),An(x,w));return}if(!T||r||!N&&!P){R&&E&&N&&w.preventDefault();return}w.defaultPrevented||(w.preventDefault(),P&&(w.preventBaseUIHandler(),An(x,w)))},onKeyUp(w){if(!t){if(jo(w),h?.(w),w.target===w.currentTarget&&r&&l&&Ur(w.currentTarget)&&w.key===" "){w.preventDefault();return}w.baseUIHandlerPrevented||w.target===w.currentTarget&&!r&&!l&&!w.defaultPrevented&&w.key===" "&&(w.preventBaseUIHandler(),An(w.currentTarget,w))}},onPointerDown(w){if(t){w.preventDefault();return}_?.(w)}},r?{type:"button"}:{role:"button"},c,v)},[t,c,l,r]),u=Y(f=>{s.current=f,d()});return{getButtonProps:m,buttonRef:u}}function Ur(e){return he(e)&&e.tagName==="BUTTON"}function cm(e){return he(e)&&e.tagName==="A"&&!!e.href}function oe(e,t,o,n){return e.addEventListener(t,o,n),()=>{e.removeEventListener(t,o,n)}}function je(e){let t=ke(lm,e).current;return t.next=e,F(t.effect),t}function lm(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var Xa=b(z(),1);var Ka=b(Ht(),1);function Ga(e){return e==null?e:"current"in e?e.current:e}function vo(e,t=!1){let o=bo();return Y((n,r=null)=>{o.cancel();let i=Ga(e);if(i==null)return;let s=i,a=()=>{Ka.flushSync(n)};if(typeof s.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){n();return}function l(){Promise.all(s.getAnimations().map(c=>c.finished)).then(()=>{r?.aborted||a()},()=>{if(r?.aborted)return;if(s.getAnimations().some(d=>d.pending||d.playState!=="finished")){l();return}a()})}if(t){let c="data-starting-style";if(!s.hasAttribute(c)){o.request(l);return}let d=new MutationObserver(()=>{s.hasAttribute(c)||(d.disconnect(),l())});d.observe(s,{attributes:!0,attributeFilter:[c]}),r?.addEventListener("abort",()=>d.disconnect(),{once:!0});return}o.request(l)})}function On(e){let{enabled:t=!0,open:o,ref:n,onComplete:r}=e,i=Y(r),s=vo(n,o);Xa.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,o,i,s])}var kt={};Mt(kt,{engine:()=>Zr,env:()=>Jr,os:()=>Xr,screenReader:()=>Qr});var Xr={};Mt(Xr,{android:()=>Qa,apple:()=>Kr,ios:()=>Gr,linux:()=>mm,mac:()=>Ja,windows:()=>pm});function dm(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:um,platform:fm,maxTouchPoints:qa}=dm(),Jt=um.toLowerCase(),$t=fm.toLowerCase();var Gr=/^i(os$|p)/.test($t)||$t==="macintel"&&qa>1,Za="android",Qa=$t===Za||Jt.includes(Za),Ja=!Gr&&$t.startsWith("mac"),pm=$t.startsWith("win"),mm=!Qa&&/^(linux|chrome os)/.test($t),Kr=Ja||Gr;var Zr={};Mt(Zr,{blink:()=>bm,gecko:()=>gm,webkit:()=>qr});var qr=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),gm=!qr&&Jt.includes("firefox"),bm=!qr&&Jt.includes("chrom");var Qr={};Mt(Qr,{voiceOver:()=>hm});var hm=Kr;var Jr={};Mt(Jr,{jsdom:()=>wm});var wm=/jsdom|happydom/.test(Jt);var Yo=0,Ke=class e{static create(){return new e}currentId=Yo;start(t,o){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Yo,o()},t)}isStarted(){return this.currentId!==Yo}clear=()=>{this.currentId!==Yo&&(clearTimeout(this.currentId),this.currentId=Yo)};disposeEffect=()=>this.clear};function at(){let e=ke(Ke.create).current;return go(e.disposeEffect),e}var Be=b(z(),1);function $a(e){return"nativeEvent"in e}function Pt(e,t){let o=["mouse","pen"];return t||o.push("",void 0),o.includes(e)}function ec(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var $r="data-base-ui-focusable";var ei="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Nn(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function re(e,t){if(!e||!t)return!1;let o=t.getRootNode?.();if(e.contains(t))return!0;if(o&&ho(o)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function Me(e){return"composedPath"in e?e.composedPath()[0]:e.target}function zt(e,t){if(!U(e))return!1;let o=e;if(t.hasElement(o))return!o.hasAttribute("data-trigger-disabled");for(let[,n]of t.entries())if(re(n,o))return!n.hasAttribute("data-trigger-disabled");return!1}function In(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let o=e;return o.target!=null&&t.contains(o.target)}function tc(e){return e.matches("html,body")}function oc(e){return he(e)&&e.matches(ei)}function ti(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${ei}`)!=null}function nc(e){if(!e||kt.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function vm(e,t){return t!=null&&!Pt(t)?0:typeof e=="function"?e():e}function $e(e,t,o){let n=vm(e,o);return typeof n=="number"?n:n?.[t]}function oi(e){return typeof e=="function"?e():e}function Ln(e,t){return t||e==="click"||e==="mousedown"}function rc(e){return e?.includes("mouse")&&e!=="mousedown"}var ic=b(W(),1),sc=Be.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new Ke,currentIdRef:{current:null},currentContextRef:{current:null}});function _m(e,t){e.current=t.current}function ni(e){let{children:t,delay:o,timeoutMs:n=0}=e,r=Be.useRef(o),i=Be.useRef(o),s=Be.useRef(null),a=Be.useRef(null),l=at();return F(()=>{if(i.current=o,!s.current){r.current=o;return}r.current={open:$e(r.current,"open"),close:$e(o,"close")}},[o,s,r,i]),(0,ic.jsx)(sc.Provider,{value:Be.useMemo(()=>({hasProvider:!0,delayRef:r,initialDelayRef:i,currentIdRef:s,timeoutMs:n,currentContextRef:a,timeout:l}),[n,l]),children:t})}function ri(e,t={open:!1}){let{open:o}=t,n="rootStore"in e?e.rootStore:e,r=n.useState("floatingId"),i=Be.useContext(sc),{currentIdRef:s,delayRef:a,timeoutMs:l,initialDelayRef:c,currentContextRef:d,hasProvider:m,timeout:u}=i,[f,p]=Be.useState(!1),g=Be.useRef(o);return F(()=>{g.current=o},[o]),F(()=>{function h(){d.current?.setIsInstantPhase(!1),s.current=null,d.current=null,a.current=c.current,u.clear()}if(s.current&&!o&&s.current===r){if(p(!1),l){let y=r;return u.start(l,()=>{n.select("open")||s.current&&s.current!==y||h()}),()=>{(g.current||s.current!==y)&&u.clear()}}h()}},[o,r,s,a,l,c,d,u,n]),F(()=>{if(!o)return;let h=d.current,y=s.current;u.clear(),d.current={onOpenChange:n.setOpen,setIsInstantPhase:p},s.current=r,a.current={open:0,close:$e(c.current,"close")},y!==null&&y!==r?(p(!0),h?.setIsInstantPhase(!0),h?.onOpenChange(!1,ee(G.none))):(p(!1),h?.setIsInstantPhase(!1))},[o,r,n,s,a,c,d,u]),F(()=>()=>{if(s.current===r){if(d.current=null,!g.current)return;s.current=null,_m(a,c),u.clear()}},[d,s,a,r,c,u]),Be.useMemo(()=>({hasProvider:m,delayRef:a,isInstantPhase:f}),[m,a,f])}function ct(...e){return()=>{for(let t=0;t({x:e,y:e}),ym={left:"right",right:"left",bottom:"top",top:"bottom"};function Bn(e,t,o){return lt(e,Dt(t,o))}function _t(e,t){return typeof e=="function"?e(t):e}function Ne(e){return e.split("-")[0]}function dt(e){return e.split("-")[1]}function Hn(e){return e==="x"?"y":"x"}function Ko(e){return e==="y"?"height":"width"}function Fe(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function Xo(e){return Hn(Fe(e))}function lc(e,t,o){o===void 0&&(o=!1);let n=dt(e),r=Xo(e),i=Ko(r),s=r==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Uo(s)),[s,Uo(s)]}function dc(e){let t=Uo(e);return[Mn(e),t,Mn(t)]}function Mn(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var ac=["left","right"],cc=["right","left"],xm=["top","bottom"],Sm=["bottom","top"];function Rm(e,t,o){switch(e){case"top":case"bottom":return o?t?cc:ac:t?ac:cc;case"left":case"right":return t?xm:Sm;default:return[]}}function uc(e,t,o,n){let r=dt(e),i=Rm(Ne(e),o==="start",n);return r&&(i=i.map(s=>s+"-"+r),t&&(i=i.concat(i.map(Mn)))),i}function Uo(e){let t=Ne(e);return ym[t]+e.slice(t.length)}function Em(e){var t,o,n,r;return{top:(t=e.top)!=null?t:0,right:(o=e.right)!=null?o:0,bottom:(n=e.bottom)!=null?n:0,left:(r=e.left)!=null?r:0}}function zn(e){return typeof e!="number"?Em(e):{top:e,right:e,bottom:e,left:e}}function eo(e){let{x:t,y:o,width:n,height:r}=e;return{width:n,height:r,top:o,left:t,right:t+n,bottom:o+r,x:t,y:o}}function Ct(e,t,o=!0){return e.filter(r=>r.parentId===t).flatMap(r=>[...!o||r.context?.open?[r]:[],...Ct(e,r.id,o)])}function _o(e){return`data-base-ui-${e}`}var He=b(z(),1),mc=b(Ht(),1);var fc={style:{transition:"none"}};var Tm="data-base-ui-swipe-ignore",km="data-swipe-ignore",o1=`[${Tm}]`,n1=`[${km}]`;var pc={fallbackAxisSide:"end"};var gc=b(W(),1),Pm=He.createContext(null),Cm=()=>He.useContext(Pm),Am=_o("portal");function bc(e={}){let{ref:t,container:o,componentProps:n=me,elementProps:r}=e,i=mo(),a=Cm()?.portalNode,[l,c]=He.useState(null),[d,m]=He.useState(null),u=Y(h=>{h!==null&&m(h)}),f=He.useRef(null);F(()=>{if(o===null){f.current&&(f.current=null,m(null),c(null));return}let h=(o&&(En(o)?o:o.current))??a??document.body;if(h==null){f.current&&(f.current=null,m(null),c(null));return}f.current!==h&&(f.current=h,m(null),c(h))},[o,a]);let p=Oe("div",n,{ref:[t,u],props:[{id:i,[Am]:""},r]}),g=l&&p?mc.createPortal(p,l):null;return{node:d,nodeId:He.isValidElement(p)?p.props.id:void 0,subtree:g}}var to=b(z(),1);function hc(){let e=new Map;return{emit(t,o){e.get(t)?.forEach(n=>n(o))},on(t,o){e.has(t)||e.set(t,new Set),e.get(t).add(o)},off(t,o){e.get(t)?.delete(o)}}}var Om=b(W(),1),Nm=to.createContext(null),Im=to.createContext(null),Dn=()=>to.useContext(Nm)?.id||null,Ft=e=>{let t=to.useContext(Im);return e??t};var Ve=b(z(),1);function Lm(e,t){let o=null,n=null,r=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",l=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",c=i.width,d=i.height,m=i.x,u=i.y;return o==null&&t.x&&s&&(o=i.x-t.x),n==null&&t.y&&a&&(n=i.y-t.y),m-=o||0,u-=n||0,c=0,d=0,!r||l?(c=t.axis==="y"?i.width:0,d=t.axis==="x"?i.height:0,m=s&&t.x!=null?t.x:m,u=a&&t.y!=null?t.y:u):r&&!l&&(d=t.axis==="x"?i.height:d,c=t.axis==="y"?i.width:c),r=!0,{width:c,height:d,x:m,y:u,top:u,right:m+c,bottom:u+d,left:m}}}}function wc(e){return e!=null&&e.clientX!=null}function ii(e,t={}){let{enabled:o=!0,axis:n="both"}=t,r="rootStore"in e?e.rootStore:e,i=r.useState("open"),s=r.useState("floatingElement"),a=r.useState("domReferenceElement"),l=r.context.dataRef,c=Ve.useRef(!1),d=Ve.useRef(null),[m,u]=Ve.useState(),[f,p]=Ve.useState([]),g=Y(w=>{r.set("positionReference",w)}),h=Y((w,R,x)=>{c.current||l.current.openEvent&&!wc(l.current.openEvent)||r.set("positionReference",Lm(x??a,{x:w,y:R,axis:n,dataRef:l,pointerType:m}))}),y=Y(w=>{i?d.current||(h(w.clientX,w.clientY,w.currentTarget),p([])):h(w.clientX,w.clientY,w.currentTarget)}),_=Pt(m)?s:i;Ve.useEffect(()=>{if(!o){g(a);return}if(!_)return;function w(){d.current?.(),d.current=null}let R=fe(s);function x(S){let E=Me(S);re(s,E)?w():h(S.clientX,S.clientY)}return!l.current.openEvent||wc(l.current.openEvent)?d.current=oe(R,"mousemove",x):g(a),w},[_,o,s,l,a,r,h,g,f]),Ve.useEffect(()=>()=>{r.set("positionReference",null)},[r]),Ve.useEffect(()=>{o&&!s&&(c.current=!1)},[o,s]),Ve.useEffect(()=>{!o&&i&&(c.current=!0)},[o,i]);let v=Ve.useMemo(()=>{function w(R){u(R.pointerType)}return{onPointerDown:w,onPointerEnter:w,onMouseMove:y,onMouseEnter:y}},[y]);return Ve.useMemo(()=>o?{reference:v,trigger:v}:{},[o,v])}var Xe=b(z(),1);function Mm(){return!1}function Bm(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function si(e,t={}){let{enabled:o=!0,escapeKey:n=!0,outsidePress:r=!0,outsidePressEvent:i="sloppy",referencePress:s=Mm,bubbles:a,externalTree:l}=t,c="rootStore"in e?e.rootStore:e,d=c.useState("open"),m=c.useState("floatingElement"),{dataRef:u}=c.context,f=Ft(l),p=Y(typeof r=="function"?r:()=>!1),g=typeof r=="function"?p:r,h=g!==!1,y=Y(()=>i),{escapeKey:_,outsidePress:v}=Bm(a),w=Xe.useRef(!1),R=Xe.useRef(!1),x=Xe.useRef(!1),S=Xe.useRef(!1),E=Xe.useRef(""),T=Xe.useRef(null),P=at(),N=at(),H=Y(()=>{N.clear(),u.current.insideReactTree=!1}),j=Y(O=>{let V=u.current.floatingContext?.nodeId;return(f?Ct(f.nodesRef.current,V):[]).some(ie=>ie.context?.open&&!ie.context.dataRef.current[O])}),L=Y(O=>In(O,c.select("floatingElement"))||In(O,c.select("domReferenceElement"))),k=Y(O=>{s()&&c.setOpen(!1,ee(G.triggerPress,O.nativeEvent))}),I=Y(O=>{if(!d||!o||!n||O.key!=="Escape"||S.current||!_&&j("__escapeKeyBubbles"))return;let V=$a(O)?O.nativeEvent:O,Z=ee(G.escapeKey,V);c.setOpen(!1,Z),Z.isCanceled||O.preventDefault(),!_&&!Z.isPropagationAllowed&&O.stopPropagation()}),C=Y(()=>{u.current.insideReactTree=!0,N.start(0,H)}),A=Y(O=>{if(!d||!o||O.button!==0)return;let V=Me(O.nativeEvent);re(c.select("floatingElement"),V)&&(w.current||(w.current=!0,R.current=!1))}),M=Y(O=>{!d||!o||(O.defaultPrevented||O.nativeEvent.defaultPrevented)&&w.current&&(R.current=!0)});Xe.useEffect(()=>{if(!d||!o)return H;u.current.__escapeKeyBubbles=_,u.current.__outsidePressBubbles=v;let O=new Ke,V=new Ke;function Z(){O.clear(),S.current=!0}function ie(){O.start(kt.engine.webkit?5:0,()=>{S.current=!1})}function K(){x.current=!0,V.start(0,()=>{x.current=!1})}function Q(){w.current=!1,R.current=!1}function q(){let B=E.current,D=B==="pen"||!B?"mouse":B,Se=y(),Ae=typeof Se=="function"?Se():Se;return typeof Ae=="string"?Ae:Ae[D]}function $(B){let D=q();return D==="intentional"&&B.type!=="click"||D==="sloppy"&&B.type==="click"}function ne(B){let D=u.current.floatingContext?.nodeId,Se=f&&Ct(f.nodesRef.current,D).some(Ae=>In(B,Ae.context?.elements.floating));return L(B)||Se}function se(B){if($(B)){B.type!=="click"&&!L(B)&&(V.clear(),x.current=!1),H();return}if(u.current.insideReactTree){H();return}let D=Me(B),Se=`[${_o("inert")}]`,Ae=U(D)?D.getRootNode():null,Nt=Array.from((ho(Ae)?Ae:Pe(c.select("floatingElement"))).querySelectorAll(Se)),it=c.context.triggerElements;if(D&&(it.hasElement(D)||it.hasMatchingElement(Ye=>re(Ye,D))))return;let It=U(D)?D:null;for(;It&&!wt(It);){let Ye=bt(It);if(wt(Ye)||!U(Ye))break;It=Ye}if(!(Nt.length&&U(D)&&!tc(D)&&!re(D,c.select("floatingElement"))&&Nt.every(Ye=>!re(It,Ye)))){if(he(D)&&!("touches"in B)){let Ye=wt(D),uo=Le(D),Xt=/auto|scroll/,pn=Ye||Xt.test(uo.overflowX),fo=Ye||Xt.test(uo.overflowY),Lt=pn&&D.clientWidth>0&&D.scrollWidth>D.clientWidth,mn=fo&&D.clientHeight>0&&D.scrollHeight>D.clientHeight,gn=uo.direction==="rtl",bn=mn&&(gn?B.offsetX<=D.offsetWidth-D.clientWidth:B.offsetX>D.clientWidth),hn=Lt&&B.offsetY>D.clientHeight;if(bn||hn)return}if(!ne(B)){if(q()==="intentional"&&x.current){V.clear(),x.current=!1;return}typeof g=="function"&&!g(B)||j("__outsidePressBubbles")||(c.setOpen(!1,ee(G.outsidePress,B)),H())}}}function ze(B){q()!=="sloppy"||B.pointerType==="touch"||!c.select("open")||!o||L(B)||se(B)}function ae(B){if(q()!=="sloppy"||!c.select("open")||!o||L(B))return;let D=B.touches[0];D&&(T.current={startTime:Date.now(),startX:D.clientX,startY:D.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},P.start(1e3,()=>{T.current&&(T.current.dismissOnTouchEnd=!1,T.current.dismissOnMouseDown=!1)}))}function ge(B,D){let Se=Me(B);if(!Se)return;let Ae=oe(Se,B.type,()=>{D(B),Ae()})}function be(B){E.current="touch",ge(B,ae)}function Ee(B){P.clear(),B.type==="pointerdown"&&(E.current=B.pointerType),!(B.type==="mousedown"&&T.current&&!T.current.dismissOnMouseDown)&&ge(B,D=>{D.type==="pointerdown"?ze(D):se(D)})}function ye(B){if(!w.current)return;let D=R.current;if(Q(),q()==="intentional"){if(B.type==="pointercancel"){D&&K();return}if(!ne(B)){if(D){K();return}typeof g=="function"&&!g(B)||(V.clear(),x.current=!0,H())}}}function Kt(B){if(q()!=="sloppy"||!T.current||L(B))return;let D=B.touches[0];if(!D)return;let Se=Math.abs(D.clientX-T.current.startX),Ae=Math.abs(D.clientY-T.current.startY),Nt=Math.sqrt(Se*Se+Ae*Ae);Nt>5&&(T.current.dismissOnTouchEnd=!0),Nt>10&&(se(B),P.clear(),T.current=null)}function rt(B){ge(B,Kt)}function ft(B){q()!=="sloppy"||!T.current||L(B)||(T.current.dismissOnTouchEnd&&se(B),P.clear(),T.current=null)}function Ot(B){ge(B,ft)}let xe=Pe(m),fn=ct(n&&ct(oe(xe,"keydown",I),oe(xe,"compositionstart",Z),oe(xe,"compositionend",ie)),h&&ct(oe(xe,"click",Ee,!0),oe(xe,"pointerdown",Ee,!0),oe(xe,"pointerup",ye,!0),oe(xe,"pointercancel",ye,!0),oe(xe,"mousedown",Ee,!0),oe(xe,"mouseup",ye,!0),oe(xe,"touchstart",be,!0),oe(xe,"touchmove",rt,!0),oe(xe,"touchend",Ot,!0)));return()=>{fn(),O.clear(),V.clear(),Q(),x.current=!1,H()}},[u,m,n,h,g,d,o,_,v,I,H,y,j,L,f,c,P]);let X=Xe.useMemo(()=>({onKeyDown:I,onPointerDown:k,onClick:k}),[I,k]),de=Xe.useMemo(()=>({onKeyDown:I,onPointerDown:M,onMouseDown:M,onClickCapture:C,onMouseDownCapture(O){C(),A(O)},onPointerDownCapture(O){C(),A(O)},onMouseUpCapture:C,onTouchEndCapture:C,onTouchMoveCapture:C}),[I,C,A,M]);return Xe.useMemo(()=>o?{reference:X,floating:de,trigger:X}:{},[o,X,de])}var Ie=b(z(),1);function vc(e,t,o){let{reference:n,floating:r}=e,i=Fe(t),s=Xo(t),a=Ko(s),l=Ne(t),c=i==="y",d=n.x+n.width/2-r.width/2,m=n.y+n.height/2-r.height/2,u=n[a]/2-r[a]/2,f;switch(l){case"top":f={x:d,y:n.y-r.height};break;case"bottom":f={x:d,y:n.y+n.height};break;case"right":f={x:n.x+n.width,y:m};break;case"left":f={x:n.x-r.width,y:m};break;default:f={x:n.x,y:n.y}}let p=dt(t);return p&&(f[s]+=u*(p==="end"?1:-1)*(o&&c?-1:1)),f}async function _c(e,t){var o;t===void 0&&(t={});let{x:n,y:r,platform:i,rects:s,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:m="floating",altBoundary:u=!1,padding:f=0}=_t(t,e),p=zn(f),h=a[u?m==="floating"?"reference":"floating":m],y=eo(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(h)))==null||o?h:h.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:d,strategy:l})),_=m==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),w=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},R=eo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:v,strategy:l}):_);return{top:(y.top-R.top+p.top)/w.y,bottom:(R.bottom-y.bottom+p.bottom)/w.y,left:(y.left-R.left+p.left)/w.x,right:(R.right-y.right+p.right)/w.x}}var Hm=50,yc=async(e,t,o)=>{let{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:s}=o,a=s.detectOverflow?s:{...s,detectOverflow:_c},l=await(s.isRTL==null?void 0:s.isRTL(t)),c=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:d,y:m}=vc(c,n,l),u=n,f=0,p={};for(let g=0;gL<=0)){var N,H;let L=(((N=i.flip)==null?void 0:N.index)||0)+1,k=S[L];if(k&&(!(m==="alignment"?_!==Fe(k):!1)||P.every(A=>Fe(A.placement)===_?A.overflows[0]>0:!0)))return{data:{index:L,overflows:P},reset:{placement:k}};let I=(H=P.filter(C=>C.overflows[0]<=0).sort((C,A)=>C.overflows[1]-A.overflows[1])[0])==null?void 0:H.placement;if(!I)switch(f){case"bestFit":{var j;let C=(j=P.filter(A=>{if(x){let M=Fe(A.placement);return M===_||M==="y"}return!0}).map(A=>[A.placement,A.overflows.filter(M=>M>0).reduce((M,X)=>M+X,0)]).sort((A,M)=>A[1]-M[1])[0])==null?void 0:j[0];C&&(I=C);break}case"initialPlacement":I=a;break}if(r!==I)return{reset:{placement:I}}}return{}}}};var Sc=new Set(["left","top"]);async function zm(e,t){let{placement:o,platform:n,elements:r}=e,i=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=Ne(o),a=dt(o),l=Fe(o)==="y",c=Sc.has(s)?-1:1,d=i&&l?-1:1,m=_t(t,e),{mainAxis:u,crossAxis:f,alignmentAxis:p}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return a&&typeof p=="number"&&(f=a==="end"?p*-1:p),l?{x:f*d,y:u*c}:{x:u*c,y:f*d}}var Rc=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var o,n;let{x:r,y:i,placement:s,middlewareData:a}=t,l=await zm(t,e);return s===((o=a.offset)==null?void 0:o.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:i+l.y,data:{...l,placement:s}}}}},Ec=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:o,y:n,placement:r,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:l={fn:_=>{let{x:v,y:w}=_;return{x:v,y:w}}},...c}=_t(e,t),d={x:o,y:n},m=await i.detectOverflow(t,c),u=Fe(r),f=Hn(u),p=d[f],g=d[u],h=(_,v)=>Bn(v+m[_==="y"?"top":"left"],v,v-m[_==="y"?"bottom":"right"]);s&&(p=h(f,p)),a&&(g=h(u,g));let y=l.fn({...t,[f]:p,[u]:g});return{...y,data:{x:y.x-o,y:y.y-n,enabled:{[f]:s,[u]:a}}}}}},Tc=function(e){return e===void 0&&(e={}),{options:e,fn(t){var o,n;let{x:r,y:i,placement:s,rects:a,middlewareData:l}=t,{offset:c=0,mainAxis:d=!0,crossAxis:m=!0}=_t(e,t),u={x:r,y:i},f=Fe(s),p=Hn(f),g=u[p],h=u[f],y=_t(c,t),_=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:(o=y.mainAxis)!=null?o:0,crossAxis:(n=y.crossAxis)!=null?n:0};if(d){let R=p==="y"?"height":"width",x=a.reference[p]-a.floating[R]+_.mainAxis,S=a.reference[p]+a.reference[R]-_.mainAxis;gS&&(g=S)}if(m){var v,w;let R=p==="y"?"width":"height",x=Sc.has(Ne(s)),S=a.reference[f]-a.floating[R]+(x&&((v=l.offset)==null?void 0:v[f])||0)+(x?0:_.crossAxis),E=a.reference[f]+a.reference[R]+(x?0:((w=l.offset)==null?void 0:w[f])||0)-(x?_.crossAxis:0);hE&&(h=E)}return{[p]:g,[f]:h}}}},kc=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:o,rects:n,platform:r,elements:i}=t,{apply:s=()=>{},...a}=_t(e,t),l=await r.detectOverflow(t,a),c=Ne(o),d=dt(o),m=Fe(o)==="y",{width:u,height:f}=n.floating,p,g;c==="top"||c==="bottom"?(p=c,g=d===(await(r.isRTL==null?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(g=c,p=d==="end"?"top":"bottom");let h=f-l.top-l.bottom,y=u-l.left-l.right,_=Dt(f-l[p],h),v=Dt(u-l[g],y),w=t.middlewareData.shift,R=!w,x=_,S=v;w!=null&&w.enabled.x&&(S=y),w!=null&&w.enabled.y&&(x=h),R&&!d&&(m?S=u-2*lt(l.left,l.right):x=f-2*lt(l.top,l.bottom)),await s({...t,availableWidth:S,availableHeight:x});let E=await r.getDimensions(i.floating);return u!==E.width||f!==E.height?{reset:{rects:!0}}:{}}}};function Ac(e){let t=Le(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=he(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n,a=jt(o)!==i||jt(n)!==s;return a&&(o=i,n=s),{width:o,height:n,$:a}}function ci(e){return U(e)?e:e.contextElement}function yo(e){let t=ci(e);if(!he(t))return vt(1);let o=t.getBoundingClientRect(),{width:n,height:r,$:i}=Ac(t),s=(i?jt(o.width):o.width)/n,a=(i?jt(o.height):o.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Dm=vt(0);function Oc(e){let t=fe(e);return!kn()||!t.visualViewport?Dm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function jm(e,t,o){return t===void 0&&(t=!1),!!o&&t&&o===fe(e)}function oo(e,t,o,n){t===void 0&&(t=!1),o===void 0&&(o=!1);let r=e.getBoundingClientRect(),i=ci(e),s=vt(1);t&&(n?U(n)&&(s=yo(n)):s=yo(e));let a=jm(i,o,n)?Oc(i):vt(0),l=(r.left+a.x)/s.x,c=(r.top+a.y)/s.y,d=r.width/s.x,m=r.height/s.y;if(i&&n){let u=fe(i),f=U(n)?fe(n):n,p=u,g=Pn(p);for(;g&&f!==p;){let h=yo(g),y=g.getBoundingClientRect(),_=Le(g),v=y.left+(g.clientLeft+parseFloat(_.paddingLeft))*h.x,w=y.top+(g.clientTop+parseFloat(_.paddingTop))*h.y;l*=h.x,c*=h.y,d*=h.x,m*=h.y,l+=v,c+=w,p=fe(g),g=Pn(p)}}return eo({width:d,height:m,x:l,y:c})}function jn(e,t){let o=Wo(e).scrollLeft;return t?t.left+o:oo(ht(e)).left+o}function Nc(e,t){let o=e.getBoundingClientRect(),n=o.left+t.scrollLeft-jn(e,o),r=o.top+t.scrollTop;return{x:n,y:r}}function Fm(e){let{elements:t,rect:o,offsetParent:n,strategy:r}=e,i=r==="fixed",s=ht(n),a=t?Vo(t.floating):!1;if(n===s||a&&i)return o;let l={scrollLeft:0,scrollTop:0},c=vt(1),d=vt(0),m=he(n);if((m||!i)&&((Qt(n)!=="body"||Fo(s))&&(l=Wo(n)),m)){let f=oo(n);c=yo(n),d.x=f.x+n.clientLeft,d.y=f.y+n.clientTop}let u=s&&!m&&!i?Nc(s,l):vt(0);return{width:o.width*c.x,height:o.height*c.y,x:o.x*c.x-l.scrollLeft*c.x+d.x+u.x,y:o.y*c.y-l.scrollTop*c.y+d.y+u.y}}function Vm(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function Wm(e){let t=Wo(e),o=e.ownerDocument.body,n=lt(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),r=lt(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight),i=-t.scrollLeft+jn(e),s=-t.scrollTop;return Le(o).direction==="rtl"&&(i+=lt(e.clientWidth,o.clientWidth)-n),{width:n,height:r,x:i,y:s}}var Ym=25;function Um(e,t,o){o===void 0&&(o="viewport");let n=o==="layoutViewport",r=fe(e),i=ht(e),s=r.visualViewport,a=i.clientWidth,l=i.clientHeight,c=0,d=0;if(s){let u=!kn()||t==="fixed";n?u||(c=-s.offsetLeft,d=-s.offsetTop):(a=s.width,l=s.height,u&&(c=s.offsetLeft,d=s.offsetTop))}if(jn(i)<=0){let u=i.ownerDocument,f=u.body,p=getComputedStyle(f),g=u.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,h=Math.abs(i.clientWidth-f.clientWidth-g),y=getComputedStyle(i).scrollbarGutter==="stable both-edges"?h/2:h;y<=Ym&&(a-=y)}return{width:a,height:l,x:c,y:d}}function Gm(e,t){let o=oo(e,!0,t==="fixed"),n=o.top+e.clientTop,r=o.left+e.clientLeft,i=yo(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,l=r*i.x,c=n*i.y;return{width:s,height:a,x:l,y:c}}function Pc(e,t,o){let n;if(t==="viewport"||t==="layoutViewport")n=Um(e,o,t);else if(t==="document")n=Wm(ht(e));else if(U(t))n=Gm(t,o);else{let r=Oc(e);n={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return eo(n)}function Km(e,t){let o=t.get(e);if(o)return o;let n=Bt(e,[],!1).filter(a=>U(a)&&Qt(a)!=="body"),r=null,i=Le(e).position==="fixed",s=i?bt(e):e;for(;U(s)&&!wt(s);){let a=Le(s),l=Tn(s),c=r?r.position:i?"fixed":"";!l&&(c==="fixed"||c==="absolute"&&a.position==="static")?n=n.filter(m=>m!==s):r=a,s=bt(s)}return t.set(e,n),n}function Xm(e){let{element:t,boundary:o,rootBoundary:n,strategy:r}=e,s=[...o==="clippingAncestors"?Vo(t)?[]:Km(t,this._c):[].concat(o),n],a=Pc(t,s[0],r),l=a.top,c=a.right,d=a.bottom,m=a.left;for(let u=1;u{a(!1,1e-7)},1e3)}S=!1}try{n=new IntersectionObserver(E,{...x,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,x)}n.observe(e)}let l=fe(e),c=()=>a(o);return l.addEventListener("resize",c),a(!0),()=>{l.removeEventListener("resize",c),s()}}function qo(e,t,o,n){n===void 0&&(n={});let{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=ci(e),d=r||i?[...c?Bt(c):[],...t?Bt(t):[]]:[];d.forEach(y=>{r&&y.addEventListener("scroll",o),i&&y.addEventListener("resize",o)});let m=c&&a?$m(c,o,i):null,u=-1,f=null;s&&(f=new ResizeObserver(y=>{let[_]=y;_&&_.target===c&&f&&t&&(f.unobserve(t),cancelAnimationFrame(u),u=requestAnimationFrame(()=>{var v;(v=f)==null||v.observe(t)})),o()}),c&&!l&&f.observe(c),t&&f.observe(t));let p,g=l?oo(e):null;l&&h();function h(){let y=oo(e);g&&!Lc(g,y)&&o(),g=y,p=requestAnimationFrame(h)}return o(),()=>{var y;d.forEach(_=>{r&&_.removeEventListener("scroll",o),i&&_.removeEventListener("resize",o)}),m?.(),(y=f)==null||y.disconnect(),f=null,l&&cancelAnimationFrame(p)}}var Mc=Rc;var Bc=Ec,Hc=xc,zc=kc;var Dc=Tc,Fn=(e,t,o)=>{let n=new Map,r=o??{},i={...li,...r.platform,_c:n};return yc(e,t,{...r,platform:i})};var we=b(z(),1),Fc=b(z(),1),Vc=b(Ht(),1),tg=typeof document<"u",og=function(){},Vn=tg?Fc.useLayoutEffect:og;function Wn(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let o,n,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(o=e.length,o!==t.length)return!1;for(n=o;n--!==0;)if(!Wn(e[n],t[n]))return!1;return!0}if(r=Object.keys(e),o=r.length,o!==Object.keys(t).length)return!1;for(n=o;n--!==0;)if(!{}.hasOwnProperty.call(t,r[n]))return!1;for(n=o;n--!==0;){let i=r[n];if(!(i==="_owner"&&e.$$typeof)&&!Wn(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Wc(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function jc(e,t){let o=Wc(e);return Math.round(t*o)/o}function di(e){let t=we.useRef(e);return Vn(()=>{t.current=e}),t}function Yc(e){e===void 0&&(e={});let{placement:t="bottom",strategy:o="absolute",middleware:n=[],platform:r,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:l,open:c}=e,[d,m]=we.useState({x:0,y:0,strategy:o,placement:t,middlewareData:{},isPositioned:!1}),[u,f]=we.useState(n);Wn(u,n)||f(n);let[p,g]=we.useState(null),[h,y]=we.useState(null),_=we.useCallback(A=>{A!==x.current&&(x.current=A,g(A))},[]),v=we.useCallback(A=>{A!==S.current&&(S.current=A,y(A))},[]),w=i||p,R=s||h,x=we.useRef(null),S=we.useRef(null),E=we.useRef(d),T=l!=null,P=di(l),N=di(r),H=di(c),j=we.useCallback(()=>{if(!x.current||!S.current)return;let A={placement:t,strategy:o,middleware:u};N.current&&(A.platform=N.current),Fn(x.current,S.current,A).then(M=>{let X={...M,isPositioned:H.current!==!1};L.current&&!Wn(E.current,X)&&(E.current=X,Vc.flushSync(()=>{m(X)}))})},[u,t,o,N,H]);Vn(()=>{c===!1&&E.current.isPositioned&&(E.current.isPositioned=!1,m(A=>({...A,isPositioned:!1})))},[c]);let L=we.useRef(!1);Vn(()=>(L.current=!0,()=>{L.current=!1}),[]),Vn(()=>{if(w&&(x.current=w),R&&(S.current=R),w&&R){if(P.current)return P.current(w,R,j);j()}},[w,R,j,P,T]);let k=we.useMemo(()=>({reference:x,floating:S,setReference:_,setFloating:v}),[_,v]),I=we.useMemo(()=>({reference:w,floating:R}),[w,R]),C=we.useMemo(()=>{let A={position:o,left:0,top:0};if(!I.floating)return A;let M=jc(I.floating,d.x),X=jc(I.floating,d.y);return a?{...A,transform:"translate("+M+"px, "+X+"px)",...Wc(I.floating)>=1.5&&{willChange:"transform"}}:{position:o,left:M,top:X}},[o,a,I.floating,d.x,d.y]);return we.useMemo(()=>({...d,update:j,refs:k,elements:I,floatingStyles:C}),[d,j,k,I,C])}var ui=(e,t)=>{let o=Mc(e);return{name:o.name,fn:o.fn,options:[e,t]}},fi=(e,t)=>{let o=Bc(e);return{name:o.name,fn:o.fn,options:[e,t]}},pi=(e,t)=>({fn:Dc(e).fn,options:[e,t]}),mi=(e,t)=>{let o=Hc(e);return{name:o.name,fn:o.fn,options:[e,t]}},gi=(e,t)=>{let o=zc(e);return{name:o.name,fn:o.fn,options:[e,t]}};var Yn=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,o,n=!0){this.fallbackStore=t,this.componentName=o,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let o=this.attachedStores.lastIndexOf(t);o!==-1&&this.attachedStores.splice(o,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(o=>{o()}))}openByTrigger(t){let o=this.attachedStore;if(o===null)return;let n;if(t){for(let r=this.attachedStores.length-1;r>=0&&!n;r-=1)n=this.attachedStores[r].context.triggerElements.getById(t);n??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!n&&this.throwOnMissingTrigger)throw new Error(De(99,this.componentName,t,this.componentName));o.setOpen(!0,ee(G.imperativeAction,void 0,n))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,ee(G.imperativeAction))}};var ro=b(z(),1),sl=b(Ht(),1);var rl=b(z(),1);var ol=b(z(),1),_i=b(Un(),1),nl=b(Qc(),1);var Jc=b(z(),1);var hi=[],wi;function $c(){return wi}function el(e){hi.push(e)}function vi(e){let t=(o,n)=>{let r=ke(_g).current,i;try{wi=r;for(let s of hi)s.before(r);i=e(o,n);for(let s of hi)s.after(r);r.didInitialize=!0}finally{wi=void 0}return i};return t.displayName=e.displayName||e.name,t}function tl(e){return Jc.forwardRef(vi(e))}function _g(){return{didInitialize:!1}}var yg=po(19),xg=yg?Rg:Eg;function Kn(e,t,o,n,r){return xg(e,t,o,n,r)}function Sg(e,t,o,n,r){let i=ol.useCallback(()=>t(e.getSnapshot(),o,n,r),[e,t,o,n,r]);return(0,_i.useSyncExternalStore)(e.subscribe,i,i)}el({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let o=0;o0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let o=new Set;for(let r of e.syncHooks)o.add(r.store);let n=[];for(let r of o)n.push(r.subscribe(t));return()=>{for(let r of n)r()}}),(0,_i.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function Rg(e,t,o,n,r){let i=$c();if(!i)return Sg(e,t,o,n,r);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,o)||!Object.is(a.a2,n)||!Object.is(a.a3,r))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=o,a.a2=n,a.a3=r,a.value=t(e.getSnapshot(),o,n,r))):(a={store:e,selector:t,a1:o,a2:n,a3:r,value:t(e.getSnapshot(),o,n,r)},i.syncHooks.push(a)),a.value}function Eg(e,t,o,n,r){return(0,nl.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,o,n,r))}var Xn=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let o=this.updateTick;for(let n of this.listeners){if(o!==this.updateTick)return;n(t)}}update(t){for(let o in t)if(!Object.is(this.state[o],t[o])){this.setState({...this.state,...t});return}}set(t,o){Object.is(this.state[t],o)||this.setState({...this.state,[t]:o})}notifyAll(){let t={...this.state};this.setState(t)}use(t,o,n,r){return Kn(this,t,o,n,r)}};var no=b(z(),1);var Vt=class extends Xn{constructor(t,o={},n){super(t),this.context=o,this.selectors=n}useSyncedValue(t,o){no.useDebugValue(t);let n=this;F(()=>{n.state[t]!==o&&n.set(t,o)},[n,t,o])}useSyncedValueWithCleanup(t,o){let n=this;F(()=>(n.state[t]!==o&&n.set(t,o),()=>{n.set(t,void 0)}),[n,t,o])}useSyncedValues(t){let o=this,n=Object.values(t);F(()=>{o.update(t)},[o,...n])}useControlledProp(t,o){no.useDebugValue(t);let n=this,r=o!==void 0;F(()=>{r&&!Object.is(n.state[t],o)&&n.setState({...n.state,[t]:o})},[n,t,o,r])}select(t,o,n,r){let i=this.selectors[t];return i(this.state,o,n,r)}useState(t,o,n,r){return no.useDebugValue(t),Kn(this,this.selectors[t],o,n,r)}useContextCallback(t,o){no.useDebugValue(t);let n=Y(o??Ge);this.context[t]=n}useStateSetter(t){let o=no.useRef(void 0);return o.current===void 0&&(o.current=n=>{this.set(t,n)}),o.current}observe(t,o){let n;typeof t=="function"?n=t:n=this.selectors[t];let r=n(this.state);return o(r,r,this),this.subscribe(i=>{let s=n(i);if(!Object.is(r,s)){let a=r;r=s,o(s,a,this)}})}};var Tg={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},Wt=class extends Vt{constructor(t){let{syncOnly:o,nested:n,onOpenChange:r,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:r,dataRef:{current:{}},events:hc(),nested:n,triggerElements:i},Tg),this.syncOnly=o}syncOpenEvent=(t,o)=>{(!t||!this.state.open||o!=null&&ec(o))&&(this.context.dataRef.current.openEvent=t?o:void 0)};dispatchOpenChange=(t,o)=>{this.syncOpenEvent(t,o.event);let n={open:t,reason:o.reason,nativeEvent:o.event,nested:this.context.nested,triggerElement:o.trigger};this.context.events.emit("openchange",n)};setOpen=(t,o)=>{if(this.syncOnly){this.context.onOpenChange?.(t,o);return}this.dispatchOpenChange(t,o),this.context.onOpenChange?.(t,o)}};function il(e){let{popupStore:t,treatPopupAsFloatingElement:o=!1,floatingRootContext:n,floatingId:r,nested:i,onOpenChange:s}=e,a=t.useState("open"),l=t.useState("activeTriggerElement"),c=t.useState(o?"popupElement":"positionerElement"),d=t.context.triggerElements,m=s,u=rl.useRef(null);n===void 0&&u.current===null&&(u.current=new Wt({open:a,transitionStatus:void 0,referenceElement:l,floatingElement:c,triggerElements:d,onOpenChange:m,floatingId:r,syncOnly:!0,nested:i}));let f=n??u.current;return t.useSyncedValue("floatingId",r),F(()=>{let p={open:a,floatingId:r,referenceElement:l,floatingElement:c};U(l)&&(p.domReferenceElement=l),f.state.positionReference===f.state.referenceElement&&(p.positionReference=l),f.update(p)},[a,r,l,c,f]),f.context.onOpenChange=m,f.context.nested=i,f}var al={tabIndex:-1,[$r]:""};function cl(e,t=!1){let o=mo(),n=Dn()!=null,r=ke(()=>e(o,n)).current;return il({popupStore:r,treatPopupAsFloatingElement:t,floatingRootContext:r.state.floatingRootContext,floatingId:o,nested:n,onOpenChange:r.setOpen}),r}function ll({handle:e,store:t}){return F(()=>e.attachStore(t),[e,t]),null}function kg(e,t){let o=ro.useRef(null),n=ro.useRef(null);return ro.useCallback(r=>{if(e===void 0)return;let i=!1;if(o.current!==null){let s=o.current,a=n.current,l=t.context.triggerElements.getById(s);a&&l===a&&(t.context.triggerElements.delete(s),i=!0),o.current=null,n.current=null}if(r!==null&&(o.current=e,n.current=r,t.context.triggerElements.add(e,r),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function Pg(e,t,o,n=!1){t?e.preventUnmountingOnClose=!1:n&&(e.preventUnmountingOnClose=!0);let r=o?.id??null;(r||t)&&(e.activeTriggerId=r,e.activeTriggerElement=o??null)}function Cg(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function dl(e,t,o,n={}){let r=o.reason,i=r===G.triggerHover,s=t&&r===G.triggerFocus,a=!t&&(r===G.triggerPress||r===G.escapeKey),l=Cg(o);if(e.context.onOpenChange?.(t,o),o.isCanceled)return;n.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,o);let c=()=>{let d={...n.extraState,open:t};s?d.instantType="focus":a?d.instantType="dismiss":i&&(d.instantType=void 0),Pg(d,t,o.trigger,l()),e.update(d)};i?sl.flushSync(c):c()}function ul(e,t,o,n){let r=o.useState("isMountedByTrigger",e),i=kg(e,o),s=Y(l=>{let c=o.select("open"),d=o.select("activeTriggerId");if(d===e){o.update({activeTriggerElement:l,...c?n:null});return}d==null&&c&&o.update({activeTriggerId:e,activeTriggerElement:l,...n})}),a=ro.useCallback(l=>{i(l),l&&s(l)},[i,s]);return F(()=>{r&&o.update({activeTriggerElement:t.current,...n})},[r,o,t,...Object.values(n)]),{registerTrigger:a,isMountedByThisTrigger:r}}function fl(e,t={}){let{closeOnActiveTriggerUnmount:o=!1}=t,n=ro.useRef(null),r=e.useState("open"),i=e.useState("triggerCount"),s=e.useState("activeTriggerId"),a=e.useState("activeTriggerElement");F(()=>{if(!r){n.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let l=e.context.triggerElements.size,c={};e.state.triggerCount!==l&&(c.triggerCount=l);let d=e.select("activeTriggerId"),m=null;if(d){let u=e.context.triggerElements.getById(d);if(u)n.current=d,u!==e.state.activeTriggerElement&&(c.activeTriggerElement=u);else{for(let[f,p]of e.context.triggerElements.entries())if(p===e.state.activeTriggerElement){c.activeTriggerId=f,c.activeTriggerElement=p,n.current=f;break}c.activeTriggerId===void 0&&(n.current===d?m=d:n.current=null)}}else n.current=null;if(!m&&!d&&l===1){let u=e.context.triggerElements.entries().next();if(!u.done){let[f,p]=u.value;c.activeTriggerId=f,c.activeTriggerElement=p,n.current=f}}(c.triggerCount!==void 0||c.activeTriggerId!==void 0||c.activeTriggerElement!==void 0)&&e.update(c),m&&o&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===m&&!e.context.triggerElements.getById(m)){let u=ee(G.none);e.setOpen(!1,u),u.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[r,e,i,s,a,o])}function pl(e,t,o){let{mounted:n,setMounted:r,transitionStatus:i}=Ba(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:n,transitionStatus:i,preventUnmountingOnClose:a});let l=Y(()=>{r(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),o?.(),t.context.onOpenChangeComplete?.(!1)});return On({enabled:n&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||l()}}),{forceUnmount:l,transitionStatus:i}}function ml(e,t){e.useSyncedValues(t),F(()=>()=>{e.update({activeTriggerProps:me,inactiveTriggerProps:me,popupProps:me})},[e])}var io=class{constructor(){this.idMap=new Map}add(t,o){this.idMap.set(t,o)}delete(t){this.idMap.delete(t)}hasElement(t){for(let o of this.idMap.values())if(o===t)return!0;return!1}hasMatchingElement(t){for(let o of this.idMap.values())if(t(o))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function gl(){return new Wt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new io,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function hl(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:gl(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:me,inactiveTriggerProps:me,popupProps:me}}function wl(e,t,o=!1){return new Wt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:o,onOpenChange:void 0})}var Zo=e=>e.triggerIdProp??e.activeTriggerId,yi=e=>e.openProp??e.open,bl=e=>(e.popupElement?.id??e.floatingId)||void 0;function vl(e,t){return t!==void 0&&yi(e)&&Zo(e)===t}function Ag(e,t){return vl(e,t)?!0:t!==void 0&&yi(e)&&Zo(e)==null&&e.triggerCount===1}var _l={open:yi,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:Zo,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:bl,isTriggerActive:(e,t)=>t!==void 0&&Zo(e)===t,isOpenedByTrigger:(e,t)=>vl(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&Zo(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>Ag(e,t)?bl(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var xi=b(z(),1),yl=b(Un(),1);function xl(e){let t=xi.useCallback(n=>e===void 0?Ge:e.subscribeStore(n),[e]),o=xi.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,yl.useSyncExternalStore)(t,o,()=>e?.serverStore)}function Sl(e){return Og(e,e.rootContext)}function Og(e,t){let{nodeId:o,externalTree:n}=e,r=t.useState("referenceElement"),i=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),l=t.useState("floatingId"),[c,d]=Ie.useState(null),[m,u]=Ie.useState(void 0),[f,p]=Ie.useState(void 0),g=Ie.useRef(null),h=Ft(n),y=Ie.useMemo(()=>({reference:r,floating:i,domReference:s}),[r,i,s]),_=Yc({...e,elements:{...y,...c&&{reference:c}}}),v=U(m)?m:null,w=f===void 0?t.state.floatingElement:f;t.useSyncedValue("referenceElement",m??null),t.useSyncedValue("domReferenceElement",m===void 0?s:v),t.useSyncedValue("floatingElement",w);let R=Ie.useCallback(N=>{let H=U(N)?{getBoundingClientRect:()=>N.getBoundingClientRect(),getClientRects:()=>N.getClientRects(),contextElement:N}:N;d(H),_.refs.setReference(H)},[_.refs]),x=Ie.useCallback(N=>{(U(N)||N===null)&&(g.current=N,u(N)),(U(_.refs.reference.current)||_.refs.reference.current===null||N!==null&&!U(N))&&_.refs.setReference(N)},[_.refs,u]),S=Ie.useCallback(N=>{p(N),_.refs.setFloating(N)},[_.refs]),E=Ie.useMemo(()=>({..._.refs,setReference:x,setFloating:S,setPositionReference:R,domReference:g}),[_.refs,x,S,R]),T=Ie.useMemo(()=>({..._.elements,domReference:s}),[_.elements,s]),P=Ie.useMemo(()=>({..._,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:l,refs:E,elements:T,nodeId:o,rootStore:t}),[_,E,T,o,t,a,l]);return F(()=>{s&&(g.current=s)},[s]),F(()=>{t.context.dataRef.current.floatingContext=P;let N=h?.nodesRef.current.find(H=>H.id===o);N&&(N.context=P)}),Ie.useMemo(()=>({..._,context:P,refs:E,elements:T,rootStore:t}),[_,E,T,P,t])}var yt=b(z(),1);var Si=kt.os.mac&&kt.engine.webkit;function Ri(e,t={}){let{enabled:o=!0,delay:n}=t,r="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=r.context,a=yt.useRef(!1),l=yt.useRef(null),c=yt.useRef(!0),d=at();yt.useEffect(()=>{let u=r.select("domReferenceElement");if(!o)return;let f=fe(u);function p(){let y=r.select("domReferenceElement");!r.select("open")&&he(y)&&y===Nn(Pe(y))&&(a.current=!0)}function g(){c.current=!0}function h(){c.current=!1}return ct(oe(f,"blur",p),Si&&oe(f,"keydown",g,!0),Si&&oe(f,"pointerdown",h,!0))},[r,o]),yt.useEffect(()=>{if(!o)return;function u(f){if(f.reason===G.triggerPress||f.reason===G.escapeKey){let p=r.select("domReferenceElement");U(p)&&(l.current=p,a.current=!0)}}return i.on("openchange",u),()=>{i.off("openchange",u)}},[i,o,r]);let m=yt.useMemo(()=>{function u(){a.current=!1,l.current=null}return{onMouseLeave(){u()},onFocus(f){let p=f.currentTarget;if(a.current){if(l.current===p)return;u()}let g=Me(f.nativeEvent);if(U(g)){if(Si&&!f.relatedTarget){if(!c.current&&!oc(g))return}else if(!nc(g))return}let h=zt(f.relatedTarget,r.context.triggerElements),{nativeEvent:y,currentTarget:_}=f,v=typeof n=="function"?n():n;if(r.select("open")&&h||v===0||v===void 0){r.setOpen(!0,ee(G.triggerFocus,y,_));return}d.start(v,()=>{a.current||r.setOpen(!0,ee(G.triggerFocus,y,_))})},onBlur(f){u();let p=f.relatedTarget,g=f.nativeEvent,h=U(p)&&p.hasAttribute(_o("focus-guard"))&&p.getAttribute("data-type")==="outside";d.start(0,()=>{let y=r.select("domReferenceElement"),_=Nn(Pe(y));!p&&_===y||re(s.current.floatingContext?.refs.floating.current,_)||re(y,_)||h||zt(p??_,r.context.triggerElements)||r.setOpen(!1,ee(G.triggerFocus,g))})}}},[s,n,r,d]);return yt.useMemo(()=>o?{reference:m,trigger:m}:{},[o,m])}var Ti=b(z(),1);var Ei=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new Ke,this.restTimeout=new Ke,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},qn=new WeakMap;function So(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&qn.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),qn.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function Zn(e,t){let{scopeElement:o,referenceElement:n,floatingElement:r}=t,i=qn.get(o);i&&i!==e&&So(i),So(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=o,e.pointerEventsReferenceElement=n,e.pointerEventsFloatingElement=r,qn.set(o,e),o.style.pointerEvents="none",n.style.pointerEvents="auto",r.style.pointerEvents="auto"}function Ro(e){let t=e.context.dataRef.current,o=ke(()=>t.hoverInteractionState??Ei.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=o),go(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function ki(e,t={}){let{enabled:o=!0,closeDelay:n=0,nodeId:r}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),l=i.useState("domReferenceElement"),{dataRef:c}=i.context,d=Ft(),m=Dn(),u=Ro(i),f=at(),p=Y(()=>Ln(c.current.openEvent?.type,u.interactedInside)),g=Y(()=>rc(c.current.openEvent?.type)),h=Y(()=>{So(u)});F(()=>{s||(u.pointerType=void 0,u.restTimeoutPending=!1,u.interactedInside=!1,h())},[s,u,h]),Ti.useEffect(()=>h,[h]),F(()=>{if(o&&s&&u.handleCloseOptions?.blockPointerEvents&&g()&&U(l)&&a){let y=l,_=a,v=Pe(a),w=d?.nodesRef.current.find(E=>E.id===m)?.context?.elements.floating;w&&(w.style.pointerEvents="");let R=u.pointerEventsScopeElement!==_?u.pointerEventsScopeElement:null,x=w!==_?w:null,S=u.handleCloseOptions?.getScope?.()??R??x??y.closest("[data-rootownerid]")??v.body;return Zn(u,{scopeElement:S,referenceElement:y,floatingElement:_}),()=>{h()}}},[o,s,l,a,u,g,d,m,h]),Ti.useEffect(()=>{if(!o)return;function y(){return!!(d&&m&&Ct(d.nodesRef.current,m).length>0)}function _(E){let T=$e(n,"close",u.pointerType),P=()=>{i.setOpen(!1,ee(G.triggerHover,E)),d?.events.emit("floating.closed",E)};T?u.openChangeTimeout.start(T,P):(u.openChangeTimeout.clear(),P())}function v(E){let T=Me(E);if(!ti(T)){u.interactedInside=!1;return}u.interactedInside=T?.closest("[aria-haspopup]")!=null}function w(){u.openChangeTimeout.clear(),f.clear(),d?.events.off("floating.closed",x),h()}function R(E){if(y()&&d){d.events.on("floating.closed",x);return}if(zt(E.relatedTarget,i.context.triggerElements))return;let T=c.current.floatingContext?.nodeId??r,P=E.relatedTarget;if(!(d&&T&&U(P)&&Ct(d.nodesRef.current,T,!1).some(H=>re(H.context?.elements.floating,P)))){if(u.handler){u.handler(E);return}h(),g()&&!p()&&_(E)}}function x(E){!d||!m||y()||f.start(0,()=>{d.events.off("floating.closed",x),i.setOpen(!1,ee(G.triggerHover,E)),d.events.emit("floating.closed",E)})}let S=a;return ct(S&&oe(S,"mouseenter",w),S&&oe(S,"mouseleave",R),S&&oe(S,"pointerdown",v,!0),()=>{d?.events.off("floating.closed",x)})},[o,a,i,c,n,r,g,p,h,u,d,m,f])}var Yt=b(z(),1),Rl=b(Ht(),1);var Ng={current:null};function Pi(e,t={}){let{enabled:o=!0,delay:n=0,handleClose:r=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:l=Ng,externalTree:c,isActiveTrigger:d=!0,getHandleCloseContext:m,isClosing:u,shouldOpen:f,guardStaleOpen:p=!1}=t,g="rootStore"in e?e.rootStore:e,{dataRef:h,events:y}=g.context,_=Ft(c),v=Ro(g),w=Yt.useRef(!1),R=je(r),x=je(n),S=je(s),E=je(o),T=je(f),P=je(u),N=Y(()=>Ln(h.current.openEvent?.type,v.interactedInside)),H=Y(()=>T.current?.()!==!1),j=Y((I,C,A)=>{let M=g.context.triggerElements;if(M.hasElement(C))return!I||!re(I,C);if(!U(A))return!1;let X=A;return M.hasMatchingElement(de=>re(de,X))&&(!I||!re(I,X))}),L=Y(()=>{if(!v.handler)return;Pe(g.select("domReferenceElement")).removeEventListener("mousemove",v.handler),v.handler=void 0}),k=Y(()=>{So(v)});return d&&(v.handleCloseOptions=R.current?.__options),Yt.useEffect(()=>L,[L]),Yt.useEffect(()=>{if(!o)return;function I(C){C.open?w.current=!1:(w.current=C.reason===G.triggerHover,L(),v.openChangeTimeout.clear(),v.restTimeout.clear(),v.blockMouseMove=!0,v.restTimeoutPending=!1)}return y.on("openchange",I),()=>{y.off("openchange",I)}},[o,y,v,L]),Yt.useEffect(()=>{if(!o)return;function I(O,V=!0){let Z=$e(x.current,"close",v.pointerType);Z?v.openChangeTimeout.start(Z,()=>{g.setOpen(!1,ee(G.triggerHover,O)),_?.events.emit("floating.closed",O)}):V&&(v.openChangeTimeout.clear(),g.setOpen(!1,ee(G.triggerHover,O)),_?.events.emit("floating.closed",O))}let C=l.current??(d?g.select("domReferenceElement"):null);if(!U(C))return;function A(O){if(v.openChangeTimeout.clear(),v.blockMouseMove=!1,i&&!Pt(v.pointerType))return;let V=oi(S.current),Z=$e(x.current,"open",v.pointerType),ie=Me(O),K=O.currentTarget??null,Q=g.select("domReferenceElement"),q=K;if(U(ie)&&!g.context.triggerElements.hasElement(ie)){for(let ye of g.context.triggerElements.elements())if(re(ye,ie)){q=ye;break}}U(K)&&U(Q)&&!g.context.triggerElements.hasElement(K)&&re(K,Q)&&(q=Q);let $=q==null?!1:j(Q,q,ie),ne=g.select("open"),se=P.current?.()??g.select("transitionStatus")==="ending",ze=!ne&&se&&w.current,ae=!$&&U(q)&&U(Q)&&re(Q,q)&&ze,ge=V>0&&!Z,be=$&&(ne||ze)||ae,Ee=!ne||$;if(be){H()&&g.setOpen(!0,ee(G.triggerHover,O,q));return}ge||(Z?v.openChangeTimeout.start(Z,()=>{Ee&&H()&&g.setOpen(!0,ee(G.triggerHover,O,q))}):Ee&&H()&&g.setOpen(!0,ee(G.triggerHover,O,q)))}function M(O){if(N()){k();return}L();let V=g.select("domReferenceElement"),Z=Pe(V);v.restTimeout.clear(),v.restTimeoutPending=!1;let ie=h.current.floatingContext??m?.();if(zt(O.relatedTarget,g.context.triggerElements))return;if(R.current&&ie){g.select("open")||v.openChangeTimeout.clear();let Q=l.current;v.handler=R.current({...ie,tree:_,x:O.clientX,y:O.clientY,onClose(){k(),L(),E.current&&!N()&&Q===g.select("domReferenceElement")&&I(O,!0)}}),Z.addEventListener("mousemove",v.handler),v.handler(O);return}(v.pointerType!=="touch"||!re(g.select("floatingElement"),O.relatedTarget))&&I(O)}function X(O){re(C,O.relatedTarget)||(v.openChangeTimeout.clear(),v.restTimeout.clear(),v.restTimeoutPending=!1)}let de=p?oe(C,"mouseout",X):void 0;return a?ct(oe(C,"mousemove",A,{once:!0}),oe(C,"mouseenter",A),oe(C,"mouseleave",M),de):ct(oe(C,"mouseenter",A),oe(C,"mouseleave",M),de)},[L,k,h,x,g,o,R,v,d,j,N,i,a,S,l,_,E,m,P,H,p]),Yt.useMemo(()=>{if(!o)return;function I(C){v.pointerType=C.pointerType}return{onPointerDown:I,onPointerEnter:I,onMouseMove(C){let{nativeEvent:A}=C,M=C.currentTarget,X=g.select("domReferenceElement"),de=g.select("open"),O=j(X,M,C.target);if(i&&!Pt(v.pointerType))return;if(de&&O&&v.handleCloseOptions?.blockPointerEvents){let ie=g.select("floatingElement");if(ie){let K=v.handleCloseOptions?.getScope?.()??M.ownerDocument.body;Zn(v,{scopeElement:K,referenceElement:M,floatingElement:ie})}}let V=oi(S.current);if(de&&!O||V===0||!O&&v.restTimeoutPending&&C.movementX**2+C.movementY**2<2)return;v.restTimeout.clear();function Z(){if(v.restTimeoutPending=!1,N())return;let ie=g.select("open");!v.blockMouseMove&&(!ie||O)&&H()&&g.setOpen(!0,ee(G.triggerHover,A,M))}v.pointerType==="touch"?Rl.flushSync(()=>{Z()}):O&&de?Z():(v.restTimeoutPending=!0,v.restTimeout.start(V,Z))}}},[o,v,N,j,i,g,S,H])}var El=.1,Ig=El*El,le=.5;function Qn(e,t,o,n,r,i){return n>=t!=i>=t&&e<=(r-o)*(t-n)/(i-n)+o}function Jn(e,t,o,n,r,i,s,a,l,c){let d=!1;return Qn(e,t,o,n,r,i)&&(d=!d),Qn(e,t,r,i,s,a)&&(d=!d),Qn(e,t,s,a,l,c)&&(d=!d),Qn(e,t,l,c,o,n)&&(d=!d),d}function Lg(e,t,o){return e>=o.x&&e<=o.x+o.width&&t>=o.y&&t<=o.y+o.height}function $n(e,t,o,n,r,i){let s=Math.min(o,r),a=Math.max(o,r),l=Math.min(n,i),c=Math.max(n,i);return e>=s&&e<=a&&t>=l&&t<=c}function Ci(e={}){let{blockPointerEvents:t=!1}=e,o=new Ke,n=({x:r,y:i,placement:s,elements:a,onClose:l,nodeId:c,tree:d})=>{let m=s?.split("-")[0],u=!1,f=null,p=null,g=typeof performance<"u"?performance.now():0;function h(_,v){let w=performance.now(),R=w-g;if(f===null||p===null||R===0)return f=_,p=v,g=w,!1;let x=_-f,S=v-p,E=x*x+S*S,T=R*R*Ig;return f=_,p=v,g=w,E0)}function j(){H()||y()}if(H())return;let L=w.getBoundingClientRect(),k=R.getBoundingClientRect(),I=r>k.right-k.width/2,C=i>k.bottom-k.height/2,A=k.width>L.width,M=k.height>L.height,X=(A?L:k).left,de=(A?L:k).right,O=(M?L:k).top,V=(M?L:k).bottom;if(m==="top"&&i>=L.bottom-1||m==="bottom"&&i<=L.top+1||m==="left"&&r>=L.right-1||m==="right"&&r<=L.left+1){j();return}let Z=!1;switch(m){case"top":Z=$n(x,S,X,L.top+1,de,k.bottom-1);break;case"bottom":Z=$n(x,S,X,k.top+1,de,L.bottom-1);break;case"left":Z=$n(x,S,k.right-1,V,L.left+1,O);break;case"right":Z=$n(x,S,L.right-1,V,k.left+1,O);break;default:}if(Z)return;if(u&&!Lg(x,S,L)){j();return}if(!T&&h(x,S)){j();return}let ie=!1;switch(m){case"top":{let K=A?le/2:le*4,Q=A||I?r+K:r-K,q=A?r-K:I?r+K:r-K,$=i+le+1,ne=I||A?k.bottom-le:k.top,se=I?A?k.bottom-le:k.top:k.bottom-le;ie=Jn(x,S,Q,$,q,$,k.left,ne,k.right,se);break}case"bottom":{let K=A?le/2:le*4,Q=A||I?r+K:r-K,q=A?r-K:I?r+K:r-K,$=i-le,ne=I||A?k.top+le:k.bottom,se=I?A?k.top+le:k.bottom:k.top+le;ie=Jn(x,S,Q,$,q,$,k.left,ne,k.right,se);break}case"left":{let K=M?le/2:le*4,Q=M||C?i+K:i-K,q=M?i-K:C?i+K:i-K,$=r+le+1,ne=C||M?k.right-le:k.left,se=C?M?k.right-le:k.left:k.right-le;ie=Jn(x,S,ne,k.top,se,k.bottom,$,Q,$,q);break}case"right":{let K=M?le/2:le*4,Q=M||C?i+K:i-K,q=M?i-K:C?i+K:i-K,$=r-le,ne=C||M?k.left+le:k.right,se=C?M?k.left+le:k.right:k.left+le;ie=Jn(x,S,$,Q,$,q,ne,k.top,se,k.bottom);break}default:}ie?u||o.start(40,j):j()}};return n.__options={...e,blockPointerEvents:t},n}var er=class extends Vt{setState(t){}update(t){}set(t,o){}notifyAll(){}};var hy=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=Wr.startingStyle]="startingStyle",e[e.endingStyle=Wr.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({});var Mg={"data-popup-open":""};var Bg={"data-open":""},Hg={"data-closed":""},zg={"data-anchor-hidden":""},Tl={open(e){return e?Mg:null}};var Qo={open(e){return e?Bg:Hg},anchorHidden(e){return e?zg:null}},kl={...Qo,...Ha};function Pl(e){return po(19)?e:e?"true":void 0}var tr=b(z(),1),Ai=tr.createContext(void 0);function Eo(){return tr.useContext(Ai)?.direction??"ltr"}var qe=b(z(),1);var Dg=e=>({name:"arrow",options:e,async fn(t){let{x:o,y:n,placement:r,rects:i,platform:s,elements:a,middlewareData:l}=t,{element:c,padding:d=0,offsetParent:m="real"}=_t(e,t)||{};if(c==null)return{};let u=zn(d),f={x:o,y:n},p=Xo(r),g=Ko(p),h=await s.getDimensions(c),y=p==="y",_=y?"top":"left",v=y?"bottom":"right",w=y?"clientHeight":"clientWidth",R=i.reference[g]+i.reference[p]-f[p]-i.floating[g],x=f[p]-i.reference[p],S=m==="real"?await s.getOffsetParent?.(c):a.floating,E=a.floating[w]||i.floating[g];(!E||!await s.isElement?.(S))&&(E=a.floating[w]||i.floating[g]);let T=R/2-x/2,P=E/2-h[g]/2-1,N=Math.min(u[_],P),H=Math.min(u[v],P),j=N,L=E-h[g]-H,k=E/2-h[g]/2+T,I=Bn(j,k,L),C=!l.arrow&&dt(r)!=null&&k!==I&&i.reference[g]/2-(k({...Dg(e),options:[e,t]});var Al={name:"hide",async fn(e){let{width:t,height:o,x:n,y:r}=e.rects.reference,i=t===0&&o===0&&n===0&&r===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-o>=0||s.right-t>=0||s.bottom-o>=0||s.left-t>=0||i}}}};var To={sideX:"left",sideY:"top"};var Ol="--available-width",Nl="--available-height";function Ml(e,t,o){let n=e==="inline-start"||e==="inline-end";return{top:"top",right:n?o?"inline-start":"inline-end":"right",bottom:"bottom",left:n?o?"inline-end":"inline-start":"left"}[t]}function Il(e,t,o){let{rects:n,placement:r}=e;return{side:Ml(t,Ne(r),o),align:dt(r)||"center",anchor:{width:n.reference.width,height:n.reference.height},positioner:{width:n.floating.width,height:n.floating.height}}}function Bl(e){return jg(e,Sl)}function jg(e,t){let{anchor:o,positionMethod:n="absolute",side:r="bottom",sideOffset:i=0,align:s="center",alignOffset:a=0,collisionBoundary:l,collisionPadding:c=5,sticky:d=!1,arrowPadding:m=5,disableAnchorTracking:u=!1,inline:f,keepMounted:p=!1,floatingRootContext:g,mounted:h,collisionAvoidance:y,shift:_,nodeId:v,adaptiveOrigin:w,lazyFlip:R=!1,externalTree:x}=e,[S,E]=qe.useState(null);!h&&S!==null&&E(null);let T=y.side||"flip",P=y.align||"flip",N=y.fallbackAxisSide||"end",H=_?.crossAxis??!1,j=_?.rootBoundary,L=typeof o=="function"?o:void 0,k=Y(L),I=L?k:o,C=je(o),A=je(h),X=Eo()==="rtl",de=S||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":X?"left":"right","inline-start":X?"right":"left"}[r],O=s==="center"?de:`${de}-${s}`,V=c;typeof V=="number"?V={top:V,right:V,bottom:V,left:V}:V&&(V={top:V.top||0,right:V.right||0,bottom:V.bottom||0,left:V.left||0});let Z=1,ie=r==="bottom"?Z:0,K=r==="top"?Z:0,Q=r==="right"?Z:0,q=r==="left"?Z:0,$={boundary:l==="clipping-ancestors"?"clippingAncestors":l,padding:V},ne=qe.useRef(null),se=je(i),ze=je(a),ae=typeof i!="function"?i:0,ge=typeof a!="function"?a:0,be=[];f&&be.push(f),be.push(ui(te=>{let Je=Il(te,r,X),pt=typeof se.current=="function"?se.current(Je):se.current,Ue=typeof ze.current=="function"?ze.current(Je):ze.current;return{mainAxis:pt,crossAxis:Ue,alignmentAxis:Ue}},[ae,ge,X,r]));let Ee=P==="none"&&T!=="shift",ye=!Ee&&(d||H||T==="shift"),Kt=T==="none"?null:mi({...$,padding:{top:V.top+Z+ie,right:V.right+Z+q,bottom:V.bottom+Z+K,left:V.left+Z+Q},mainAxis:!H&&T==="flip",crossAxis:P==="flip"?"alignment":!1,fallbackAxisSideDirection:N}),rt=Ee?null:fi({...$,rootBoundary:j,mainAxis:P!=="none",crossAxis:ye,limiter:d||H?void 0:pi(te=>{if(!ne.current)return{};let{width:Je,height:pt}=ne.current.getBoundingClientRect(),Ue=Fe(Ne(te.placement)),Tt=Ue==="y"?Je:pt,mt=Ue==="y"?V.left+V.right:V.top+V.bottom;return{offset:Tt/2+mt/2}})},[$,d,H,j,V,P]);T==="shift"||P==="shift"||s==="center"?be.push(rt,Kt):be.push(Kt,rt),be.push(gi({...$,apply({elements:{floating:te},availableWidth:Je,availableHeight:pt,rects:Ue}){if(!A.current)return;let Tt=te.style;Tt.setProperty(Ol,`${Je}px`),Tt.setProperty(Nl,`${pt}px`);let mt=fe(te).devicePixelRatio||1,{x:Mo,y:wn,width:vn,height:Cr}=Ue.reference,Ar=(Math.round((Mo+vn)*mt)-Math.round(Mo*mt))/mt,Or=(Math.round((wn+Cr)*mt)-Math.round(wn*mt))/mt;Tt.setProperty("--anchor-width",`${Ar}px`),Tt.setProperty("--anchor-height",`${Or}px`)}}),Cl(te=>({element:ne.current||Pe(te.elements.floating).createElement("div"),padding:m,offsetParent:"floating"}),[m]),{name:"transformOrigin",fn(te){let{elements:Je,middlewareData:pt,placement:Ue,rects:Tt,y:mt}=te,Mo=Ne(Ue),wn=Fe(Mo),vn=ne.current,Cr=pt.arrow?.x||0,Ar=pt.arrow?.y||0,Or=vn?.clientWidth||0,Yf=vn?.clientHeight||0,Nr=Cr+Or/2,la=Ar+Yf/2,Uf=Math.abs(pt.shift?.y||0),Gf=Tt.reference.height/2,Bo=typeof i=="function"?i(Il(te,r,X)):i,Kf=Uf>Bo,Xf={top:`${Nr}px calc(100% + ${Bo}px)`,bottom:`${Nr}px ${-Bo}px`,left:`calc(100% + ${Bo}px) ${la}px`,right:`${-Bo}px ${la}px`}[Mo],qf=`${Nr}px ${Tt.reference.y+Gf-mt}px`;return Je.floating.style.setProperty("--transform-origin",ye&&wn==="y"&&Kf?qf:Xf),{}}},Al,w),F(()=>{!h&&g&&g.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[h,g]);let ft=qe.useMemo(()=>({elementResize:!u&&typeof ResizeObserver<"u",layoutShift:!u&&typeof IntersectionObserver<"u"}),[u]),{refs:Ot,elements:xe,x:fn,y:B,middlewareData:D,update:Se,placement:Ae,context:Nt,isPositioned:it,floatingStyles:It}=t({rootContext:g,open:p?h:void 0,placement:O,middleware:be,strategy:n,whileElementsMounted:p?void 0:(...te)=>qo(...te,ft),nodeId:v,externalTree:x}),{sideX:Ye,sideY:uo}=D.adaptiveOrigin||To,Xt=it?n:"fixed",pn=qe.useMemo(()=>{let te;return it?w?te={position:Xt,[Ye]:fn,[uo]:B}:te={...It,position:Xt}:te={position:Xt,top:0,left:0},te[Ol]="100vw",te[Nl]="100vh",it||(te.opacity=0),te},[w,Xt,Ye,fn,uo,B,It,it]),fo=qe.useRef(null);F(()=>{if(!h)return;let te=C.current,Je=typeof te=="function"?te():te,Ue=(Ll(Je)?Je.current:Je)||null||null;Ue!==fo.current&&(Ot.setPositionReference(Ue),fo.current=Ue)},[h,Ot,I,C]),qe.useEffect(()=>{if(!h)return;let te=C.current;typeof te!="function"&&Ll(te)&&te.current!==fo.current&&(Ot.setPositionReference(te.current),fo.current=te.current)},[h,Ot,I,C]),qe.useEffect(()=>{if(p&&h&&xe.reference&&xe.floating)return qo(xe.reference,xe.floating,Se,ft)},[p,h,xe,Se,ft]);let Lt=Ne(Ae),mn=Ml(r,Lt,X),gn=dt(Ae)||"center",bn=!!D.hide?.referenceHidden;F(()=>{R&&h&&it&&Lt!==de&&E(Lt)},[R,h,it,Lt,de]);let hn=qe.useMemo(()=>({position:"absolute",top:D.arrow?.y,left:D.arrow?.x}),[D.arrow]),ca=D.arrow?.centerOffset!==0;return qe.useMemo(()=>({positionerStyles:pn,arrowStyles:hn,arrowRef:ne,arrowUncentered:ca,side:mn,align:gn,physicalSide:Lt,anchorHidden:bn,refs:Ot,context:Nt,isPositioned:it,update:Se}),[pn,hn,ne,ca,mn,gn,Lt,bn,Ot,Nt,it,Se])}function Ll(e){return e!=null&&"current"in e}function or(e){return e==="starting"?fc:me}function Hl(e,t,{styles:o,transitionStatus:n,props:r,refs:i,hidden:s,inert:a=!1}){let l={...o};return a&&(l.pointerEvents="none"),Oe("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:l},or(n),r],stateAttributesMapping:Qo})}var zl=b(z(),1);var Oi=zl.forwardRef(function(t,o){let{render:n,className:r,disabled:i=!1,focusableWhenDisabled:s=!1,nativeButton:a=!0,style:l,...c}=t,{getButtonProps:d,buttonRef:m}=Ya({disabled:i,focusableWhenDisabled:s,native:a});return Oe("button",t,{state:{disabled:i},ref:[o,m],props:[c,d]})});var Ce=b(z(),1),Kl=b(Ht(),1);var Dl=b(z(),1);function jl(e){let[t,o]=Dl.useState({current:e,previous:null});return Object.is(e,t.current)||o({current:e,previous:t.current}),t.previous}var ko=b(z(),1);function Ni(e){let t=Le(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=he(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n;return(jt(o)!==i||jt(n)!==s)&&(o=i,n=s),{width:o,height:n}}function Vl(e){let{popupElement:t,positionerElement:o,content:n,mounted:r,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:l}=e,c=vo(t,!0),d=bo(),m=ko.useRef(null),u=ko.useRef(!0),f=ko.useRef(Ge),p=Y(i),g=Y(s),h=ko.useMemo(()=>Fg(a,l),[a,l]);F(()=>{if(!r){f.current=Ge,u.current=!0,m.current=null;return}if(!t||!o)return;f.current=Fl(t,h),Ii(t,"auto");let y=rr(t,"position","static"),_=rr(t,"transform","none"),v=rr(t,"scale","1"),w=Fl(o,{"--available-width":"max-content","--available-height":"max-content"});function R(){y(),_(),w()}function x(){R(),v()}if(p?.(),u.current||m.current===null){nr(o,"max-content");let P=Ni(t);return m.current=P,nr(o,P),x(),g?.(null,P),u.current=!1,()=>{f.current(),f.current=Ge}}nr(o,"max-content");let S=m.current,E=Ni(t);m.current=E,Ii(t,S),x(),g?.(S,E),nr(o,E);let T=new AbortController;return d.request(()=>{Ii(t,E),c(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},T.signal)}),()=>{T.abort(),d.cancel(),f.current(),f.current=Ge}},[n,t,o,c,d,r,p,g,h])}function Fg(e,t){let o=e==="top",n=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!o&&!n?me:{position:"absolute",[o?"bottom":"top"]:"0",[n?"right":"left"]:"0"}}function rr(e,t,o){let n=e.style.getPropertyValue(t);return e.style.setProperty(t,o),()=>{e.style.setProperty(t,n)}}function Fl(e,t){let o=[];for(let[n,r]of Object.entries(t))o.push(rr(e,n,r));return o.length?()=>{o.forEach(n=>n())}:Ge}function Ii(e,t){let o=t==="auto"?"auto":`${t.width}px`,n=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",o),e.style.setProperty("--popup-height",n)}function nr(e,t){let o=t==="max-content"?"max-content":`${t.width}px`,n=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",o),e.style.setProperty("--positioner-height",n)}var Wl=b(z(),1);var Yl=b(W(),1),ir=function(t){let{direction:o="ltr"}=t,n=Wl.useMemo(()=>({direction:o}),[o]);return(0,Yl.jsx)(Ai.Provider,{value:n,children:t.children})};var Ul={name:"adaptiveOrigin",async fn(e){let{x:t,y:o,rects:{floating:n},elements:{floating:r},platform:i,strategy:s,placement:a}=e,l=fe(r),c=l.getComputedStyle(r);if(!(c.transitionDuration!=="0s"&&c.transitionDuration!==""))return{x:t,y:o,data:To};let m=await i.getOffsetParent?.(r),u={width:0,height:0};if(s==="fixed"&&l?.visualViewport)u={width:l.visualViewport.width,height:l.visualViewport.height};else if(m===l){let _=Pe(r);u={width:_.documentElement.clientWidth,height:_.documentElement.clientHeight}}else await i.isElement?.(m)&&(u=await i.getDimensions(m));let f=Ne(a),p=t,g=o;f==="left"&&(p=u.width-(t+n.width)),f==="top"&&(g=u.height-(o+n.height));let h=f==="left"?"right":To.sideX,y=f==="top"?"bottom":To.sideY;return{x:p,y:g,data:{sideX:h,sideY:y}}}};var Po=b(W(),1),Xl={activationDirection:e=>e?{"data-activation-direction":e}:null};function ql(e){let{store:t,side:o,children:n}=e,r=Eo(),i=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),a=t.useState("open"),l=t.useState("payload"),c=t.useState("mounted"),d=t.useState("popupElement"),m=t.useState("positionerElement"),u=jl(a?i:null),f=Yg(s,l),p=Ce.useRef(null),[g,h]=Ce.useState(null),[y,_]=Ce.useState(null),v=Ce.useRef(null),w=Ce.useRef(null),R=vo(v,!0),x=bo(),S=Ce.useRef(null),[E,T]=Ce.useState(null),[P,N]=Ce.useState(!1);F(()=>(t.set("adaptiveOrigin",Ul),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let H=Y(()=>{v.current?.style.setProperty("animation","none"),v.current?.style.setProperty("transition","none"),w.current?.style.setProperty("display","none")}),j=Y(M=>{v.current?.style.removeProperty("animation"),v.current?.style.removeProperty("transition"),w.current?.style.removeProperty("display"),M&&T(M)}),L=Y(()=>{S.current?.abort();let M=new AbortController;S.current=M,R(()=>{h(null),T(null),p.current=null},M.signal)}),k=Ce.useRef(null);F(()=>{(!a||!c)&&(k.current=null)},[a,c]),F(()=>{if(i&&u&&i!==u&&k.current!==i&&p.current){h(p.current),N(!0);let M=Wg(u,i);_(M),k.current=i}},[i,u]),F(()=>{g!=null&&(S.current?.abort(),N(!0),x.request(()=>{Kl.flushSync(()=>{N(!1)}),L()}))},[f,g,L,x]),F(()=>{let M=v.current;if(!M)return;let X=Pe(M).createElement("div");for(let de of Array.from(M.childNodes))X.appendChild(de.cloneNode(!0));p.current=X});let I=g!=null,C;I?C=(0,Po.jsxs)(Ce.Fragment,{children:[(0,Po.jsx)("div",{"data-previous":!0,inert:Pl(!0),ref:w,style:{...E?{"--popup-width":`${E.width}px`,"--popup-height":`${E.height}px`}:null,position:"absolute"},"data-ending-style":P?void 0:""},"previous"),(0,Po.jsx)("div",{"data-current":!0,ref:v,"data-starting-style":P?"":void 0,children:n},f)]}):C=(0,Po.jsx)("div",{"data-current":!0,ref:v,children:n},f),F(()=>{let M=w.current;!M||!g||M.replaceChildren(...Array.from(g.childNodes))},[g]),Vl({popupElement:d,positionerElement:m,mounted:c,content:l,onMeasureLayout:H,onMeasureLayoutComplete:j,side:o,direction:r});let A={activationDirection:Vg(y),transitioning:I};return{children:C,state:A}}function Vg(e){if(e)return`${Gl(e.horizontal,5,"right","left")} ${Gl(e.vertical,5,"down","up")}`}function Gl(e,t,o,n){return e>t?o:e<-t?n:""}function Wg(e,t){let o=e.getBoundingClientRect(),n=t.getBoundingClientRect(),r={x:o.left+o.width/2,y:o.top+o.height/2},i={x:n.left+n.width/2,y:n.top+n.height/2};return{horizontal:i.x-r.x,vertical:i.y-r.y}}function Yg(e,t){let[o,n]=Ce.useState(0),r=Ce.useRef(e),i=Ce.useRef(t),s=Ce.useRef(!1);return F(()=>{let a=r.current,l=i.current,c=e!==a,d=t!==l;c?(n(m=>m+1),s.current=!d):s.current&&d&&(n(m=>m+1),s.current=!1),r.current=e,i.current=t},[e,t]),`${e??"current"}-${o}`}var sr=b(z(),1),Zl=b(Ht(),1);var Ql=b(W(),1),Jl=sr.forwardRef(function(t,o){let{children:n,container:r,className:i,render:s,style:a,...l}=t,{node:c,subtree:d}=bc({container:r,ref:o,componentProps:t,elementProps:l});return!d&&!c?null:(0,Ql.jsxs)(sr.Fragment,{children:[d,c&&Zl.createPortal(n,c)]})});var tt={};Mt(tt,{Arrow:()=>hd,Handle:()=>$o,Popup:()=>gd,Portal:()=>ud,Positioner:()=>pd,Provider:()=>vd,Root:()=>rd,Trigger:()=>cd,Viewport:()=>yd,createHandle:()=>xd});var Co=b(z(),1);var ar=b(z(),1),Li=ar.createContext(void 0);function et(e){let t=ar.useContext(Li);if(t===void 0&&!e)throw new Error(De(72));return t}var $l=b(z(),1);var ed={..._l,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},cr=class extends Vt{constructor(t,o,n){let r=new io;super(od(t,r,o,n),nd(r),ed)}setOpen=(t,o)=>{dl(this,t,o,{extraState:{openChangeReason:o.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,ee(G.triggerPress,t))}};function td(){let e=new io,t=new er(Object.freeze(od(void 0,e)),Object.freeze(nd(e)),ed);return Object.assign(t,{setOpen:Ge,cancelPendingOpen:Ge})}function od(e,t,o,n=!1){let r={...hl(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e};return r.floatingRootContext=wl(t,o,n),r}function nd(e){return{popupRef:$l.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var Jo=b(W(),1),rd=vi(function(t){let{disabled:o=!1,defaultOpen:n=!1,open:r,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:l,onOpenChangeComplete:c,handle:d,triggerId:m,defaultTriggerId:u=null,children:f}=t,p=cl((N,H)=>new cr({open:n,openProp:r,activeTriggerId:u,triggerIdProp:m},N,H));p.useControlledProp("openProp",r),p.useControlledProp("triggerIdProp",m),p.useContextCallback("onOpenChange",l),p.useContextCallback("onOpenChangeComplete",c);let g=p.useState("open"),h=!o&&g,y=p.useState("activeTriggerId"),_=p.useState("mounted"),v=p.useState("payload");p.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i,disabled:o}),fl(p,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:w,transitionStatus:R}=pl(h,p),x=p.useState("isInstantPhase"),S=p.useState("instantType"),E=p.useState("lastOpenChangeReason"),T=Co.useRef(null);F(()=>{g&&o&&p.setOpen(!1,ee(G.disabled))},[g,o,p]),F(()=>{R==="ending"&&E===G.none||R!=="ending"&&x?(S!=="delay"&&(T.current=S),p.set("instantType","delay")):T.current!==null&&(p.set("instantType",T.current),T.current=null)},[R,x,E,S,p]),F(()=>{h&&y==null&&p.set("payload",void 0)},[p,y,h]),Co.useImperativeHandle(a,()=>({unmount:w,close:()=>p.setOpen(!1,ee(G.imperativeAction))}),[w,p]);let P=h||_||!o&&s!=="none";return(0,Jo.jsxs)(Li.Provider,{value:p,children:[d&&(0,Jo.jsx)(ll,{handle:d,store:p}),P&&(0,Jo.jsx)(Ug,{store:p,disabled:o,trackCursorAxis:s}),typeof f=="function"?f({payload:v}):f]})});function Ug({store:e,disabled:t,trackCursorAxis:o}){let n=e.useState("floatingRootContext"),r=si(n,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=ii(n,{enabled:!t&&o!=="none",axis:o==="none"?void 0:o}),s=Co.useMemo(()=>ve(i.reference,r.reference),[i.reference,r.reference]);return ml(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:r.floating??me}),null}var dr=b(z(),1);var lr=b(z(),1),Mi=lr.createContext(void 0);function id(){return lr.useContext(Mi)}var ad="data-base-ui-tooltip-trigger";function sd(e){if("composedPath"in e){let o=e.composedPath();for(let n=0;nh.select("transitionStatus")==="ending",shouldOpen(){return!X.current}}),Q=Ri(w,{enabled:!I}).reference,q=ae=>{let ge=X.current,be=sd(ae),Ee=ie(be),ye=R.current,Kt=ye&&be&&re(ye,be);if(Ee&&h.select("open")&&h.select("lastOpenChangeReason")===G.triggerHover){h.setOpen(!1,ee(G.triggerHover,ae));return}if(ge&&!Ee&&Kt&&!C.current&&!h.select("open")&&ye&&Pt(O.current)){let rt=()=>{!X.current&&!C.current&&!h.select("open")&&h.setOpen(!0,ee(G.triggerHover,ae,ye))},ft=V();ft===0?(de.clear(),rt()):de.start(ft,rt)}},$=h.useState("triggerProps",T);return Oe("button",t,{state:{open:v},ref:[o,E,R],props:[K,Q,T||A!=="none"?$:void 0,{onMouseOver(ae){q(ae.nativeEvent)},onFocus(ae){Z(sd(ae.nativeEvent))&&ae.preventBaseUIHandler()},onMouseLeave(){X.current=!1,de.clear(),O.current=void 0},onPointerEnter(ae){O.current=ae.pointerType},onPointerDown(ae){O.current=ae.pointerType,h.set("closeOnClick",d),d&&!h.select("open")&&h.cancelPendingOpen(ae.nativeEvent)},onClick(ae){d&&!h.select("open")&&h.cancelPendingOpen(ae.nativeEvent)},id:y,"data-trigger-disabled":I?"":void 0,[ad]:I?void 0:""},f],stateAttributesMapping:Tl})});var dd=b(z(),1);var ur=b(z(),1),Bi=ur.createContext(void 0);function ld(){let e=ur.useContext(Bi);if(e===void 0)throw new Error(De(70));return e}var Hi=b(W(),1),ud=dd.forwardRef(function(t,o){let{keepMounted:n=!1,...r}=t;return et().useState("mounted")||n?(0,Hi.jsx)(Bi.Provider,{value:n,children:(0,Hi.jsx)(Jl,{ref:o,...r})}):null});var pr=b(z(),1);var fr=b(z(),1),zi=fr.createContext(void 0);function Ao(){let e=fr.useContext(zi);if(e===void 0)throw new Error(De(71));return e}var fd=b(W(),1),pd=pr.forwardRef(function(t,o){let{render:n,className:r,anchor:i,positionMethod:s="absolute",side:a="top",align:l="center",sideOffset:c=0,alignOffset:d=0,collisionBoundary:m="clipping-ancestors",collisionPadding:u=5,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:g=!1,collisionAvoidance:h=pc,style:y,..._}=t,v=et(),w=ld(),R=v.useState("open"),x=v.useState("mounted"),S=v.useState("trackCursorAxis"),E=v.useState("disableHoverablePopup"),T=v.useState("floatingRootContext"),P=v.useState("instantType"),N=v.useState("transitionStatus"),H=v.useState("adaptiveOrigin"),j=Bl({anchor:i,positionMethod:s,floatingRootContext:T,mounted:x,side:a,sideOffset:c,align:l,alignOffset:d,collisionBoundary:m,collisionPadding:u,sticky:p,arrowPadding:f,disableAnchorTracking:g,keepMounted:w,collisionAvoidance:h,adaptiveOrigin:H}),L=pr.useMemo(()=>({open:R,side:j.side,align:j.align,anchorHidden:j.anchorHidden,instant:S!=="none"?"tracking-cursor":P}),[R,j.side,j.align,j.anchorHidden,S,P]),k=Hl(t,L,{styles:j.positionerStyles,transitionStatus:N,props:_,refs:[o,v.useStateSetter("positionerElement")],hidden:!x,inert:!R||S==="both"||E});return(0,fd.jsx)(zi.Provider,{value:j,children:k})});var md=b(z(),1);var gd=md.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=et(),{side:l,align:c}=Ao(),d=a.useState("open"),m=a.useState("instantType"),u=a.useState("transitionStatus"),f=a.useState("popupProps"),p=a.useState("floatingRootContext"),g=a.useState("disabled"),h=a.useState("closeDelay");On({open:d,ref:a.context.popupRef,onComplete(){d&&a.context.onOpenChangeComplete?.(!0)}}),ki(p,{enabled:!g,closeDelay:h});let y=a.useStateSetter("popupElement");return Oe("div",t,{state:{open:d,side:l,align:c,instant:m,transitionStatus:u},ref:[o,a.context.popupRef,y],props:[al,f,or(u),s],stateAttributesMapping:kl})});var bd=b(z(),1);var hd=bd.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=et(),{arrowRef:l,side:c,align:d,arrowUncentered:m,arrowStyles:u}=Ao(),f=a.useState("open"),p=a.useState("instantType");return Oe("div",t,{state:{open:f,side:c,align:d,uncentered:m,instant:p},ref:[o,l],props:[{style:u,"aria-hidden":!0},s],stateAttributesMapping:Qo})});var wd=b(z(),1);var Di=b(W(),1),vd=function(t){let{delay:o,closeDelay:n,timeout:r=400}=t,i=wd.useMemo(()=>({open:o,close:n}),[o,n]);return(0,Di.jsx)(Mi.Provider,{value:o,children:(0,Di.jsx)(ni,{delay:i,timeoutMs:r,children:t.children})})};var _d=b(z(),1);var yd=_d.forwardRef(function(t,o){let{render:n,className:r,style:i,children:s,...a}=t,l=et(),c=Ao(),d=l.useState("instantType"),{children:m,state:u}=ql({store:l,side:c.side,children:s}),f={activationDirection:u.activationDirection,transitioning:u.transitioning,instant:d};return Oe("div",t,{state:f,ref:o,props:[a,{children:m}],stateAttributesMapping:Xl})});var $o=class extends Yn{constructor(){super(td(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function xd(){return new $o}function ot(e){return Oe(e.defaultTagName??"div",e,e)}var Ed=b(ce(),1),ji="data-wp-hash";function Fi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&qg(document)),e.__wpStyleRuntime}function Xg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ji}]`))if(o.getAttribute(ji)===t)return!0;return!1}function Td(e,t,o){if(!e.head)return;let n=Fi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Xg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ji,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function qg(e){let t=Fi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Td(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function kd(e,t){let o=Fi();o.styles.set(e,t);for(let n of o.documents.keys())Td(n,e,t)}typeof process>"u",kd("a495f9d138",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Sd={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",kd("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Rd={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},We=(0,Ed.forwardRef)(function({variant:t="body-md",render:o,className:n,...r},i){return ot({render:o,defaultTagName:"span",ref:i,props:ve(r,{className:J(Sd.text,Rd.heading,Rd.p,Sd[t],n)})})});var Od=b(W(),1),Vi="data-wp-hash";function Wi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Qg(document)),e.__wpStyleRuntime}function Zg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Vi}]`))if(o.getAttribute(Vi)===t)return!0;return!1}function Ad(e,t,o){if(!e.head)return;let n=Wi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Zg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Vi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Qg(e){let t=Wi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ad(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Jg(e,t){let o=Wi();o.styles.set(e,t);for(let n of o.documents.keys())Ad(n,e,t)}typeof process>"u",Jg("9db2873e7f","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._96e6251aad1a6136__badge{border-radius:var(--wpds-border-radius-lg,8px);padding-block:var(--wpds-dimension-padding-xs,4px);padding-inline:var(--wpds-dimension-padding-sm,8px)}._99f7158cb520f750__is-high-intent{background-color:var(--wpds-color-background-surface-error,#f6e6e3);color:var(--wpds-color-foreground-content-error,#470000)}.c20ebef2365bc8b7__is-medium-intent{background-color:var(--wpds-color-background-surface-warning,#fde6be);color:var(--wpds-color-foreground-content-warning,#2e1900)}._365e1626c6202e52__is-low-intent{background-color:var(--wpds-color-background-surface-caution,#fee995);color:var(--wpds-color-foreground-content-caution,#281d00)}._33f8198127ddf4ef__is-stable-intent{background-color:var(--wpds-color-background-surface-success,#c6f7cd);color:var(--wpds-color-foreground-content-success,#002900)}._04c1aca8fc449412__is-informational-intent{background-color:var(--wpds-color-background-surface-info,#deebfa);color:var(--wpds-color-foreground-content-info,#001b4f)}._90726e69d495ec19__is-draft-intent{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);color:var(--wpds-color-foreground-content-neutral,#1e1e1e)}._898f4a544993bd39__is-none-intent{background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);padding-block:calc(var(--wpds-dimension-padding-xs, 4px) - var(--wpds-border-width-xs, 1px));padding-inline:calc(var(--wpds-dimension-padding-sm, 8px) - var(--wpds-border-width-xs, 1px))}}}");var Pd={badge:"_96e6251aad1a6136__badge","is-high-intent":"_99f7158cb520f750__is-high-intent","is-medium-intent":"c20ebef2365bc8b7__is-medium-intent","is-low-intent":"_365e1626c6202e52__is-low-intent","is-stable-intent":"_33f8198127ddf4ef__is-stable-intent","is-informational-intent":"_04c1aca8fc449412__is-informational-intent","is-draft-intent":"_90726e69d495ec19__is-draft-intent","is-none-intent":"_898f4a544993bd39__is-none-intent"},Yi=(0,Cd.forwardRef)(function({intent:t="none",className:o,...n},r){return(0,Od.jsx)(We,{ref:r,className:J(Pd.badge,Pd[`is-${t}-intent`],o),...n,variant:"body-sm"})});var mr=b(ce(),1),Nd=b(st(),1),Ld=b(W(),1);import{speak as $g}from"@wordpress/a11y";var Ui="data-wp-hash";function Gi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&tb(document)),e.__wpStyleRuntime}function eb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ui}]`))if(o.getAttribute(Ui)===t)return!0;return!1}function Id(e,t,o){if(!e.head)return;let n=Gi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(eb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ui,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function tb(e){let t=Gi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Id(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function gr(e,t){let o=Gi();o.styles.set(e,t);for(let n of o.documents.keys())Id(n,e,t)}typeof process>"u",gr("effc4e3032",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var en={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"};typeof process>"u",gr("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var ob={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",gr("96553466c8","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var nb={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",gr("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var rb={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},Md=(0,mr.forwardRef)(function({tone:t="brand",variant:o="solid",size:n="default",className:r,focusableWhenDisabled:i=!0,disabled:s,loading:a,loadingAnnouncement:l=(0,Nd.__)("Loading"),children:c,...d},m){let u=J(rb.button,ob["box-sizing"],nb["outset-ring--focus-except-active"],o!=="unstyled"&&en.button,en[`is-${t}`],en[`is-${o}`],en[`is-${n}`],a&&en["is-loading"],r);return(0,mr.useEffect)(()=>{a&&l&&$g(l)},[a,l]),(0,Ld.jsx)(Oi,{ref:m,className:u,focusableWhenDisabled:i,disabled:s??a,...d,children:c})});var jd=b(ce(),1);var Hd=b(ce(),1),zd=b(so(),1),Dd=b(W(),1),ao=(0,Hd.forwardRef)(function({icon:t,size:o=24,...n},r){return(0,Dd.jsx)(zd.SVG,{ref:r,...t.props,...n,width:o,height:o})});var Vd=b(W(),1),Ki="data-wp-hash";function Xi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&sb(document)),e.__wpStyleRuntime}function ib(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ki}]`))if(o.getAttribute(Ki)===t)return!0;return!1}function Fd(e,t,o){if(!e.head)return;let n=Xi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(ib(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ki,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function sb(e){let t=Xi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Fd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ab(e,t){let o=Xi();o.styles.set(e,t);for(let n of o.documents.keys())Fd(n,e,t)}typeof process>"u",ab("effc4e3032",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var cb={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"},qi=(0,jd.forwardRef)(function({className:t,icon:o,...n},r){return(0,Vd.jsx)(ao,{ref:r,icon:o,className:J(cb.icon,t),size:24,...n})});qi.displayName="Button.Icon";var br=Object.assign(Md,{Icon:qi});var hr=b(so(),1),Zi=b(W(),1),Qi=(0,Zi.jsx)(hr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Zi.jsx)(hr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm-.75 12v-1.5h1.5V16h-1.5Zm0-8v5h1.5V8h-1.5Z"})});var wr=b(so(),1),Ji=b(W(),1),$i=(0,Ji.jsx)(wr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Ji.jsx)(wr.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})});var vr=b(so(),1),es=b(W(),1),ts=(0,es.jsx)(vr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,es.jsx)(vr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z"})});var _r=b(so(),1),os=b(W(),1),ns=(0,os.jsx)(_r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,os.jsx)(_r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 12a6.5 6.5 0 1 0 13 0 6.5 6.5 0 0 0-13 0ZM12 4a8 8 0 1 0 0 16 8 8 0 0 0 0-16Zm.75 4v1.5h-1.5V8h1.5Zm0 8v-5h-1.5v5h1.5Z"})});var yr=b(so(),1),rs=b(W(),1),is=(0,rs.jsx)(yr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,rs.jsx)(yr.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12 18.5a6.5 6.5 0 1 1 0-13 6.5 6.5 0 0 1 0 13ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Zm11.53-1.47-1.06-1.06L11 12.94l-1.47-1.47-1.06 1.06L11 15.06l4.53-4.53Z"})});var yu=b(ce(),1);var cu=b(ce(),1);var Kd=b(ce(),1);var as="data-wp-hash";function cs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&db(document)),e.__wpStyleRuntime}function lb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${as}]`))if(o.getAttribute(as)===t)return!0;return!1}function Yd(e,t,o){if(!e.head)return;let n=cs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(lb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(as,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function db(e){let t=cs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Yd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ub(e,t){let o=cs();o.styles.set(e,t);for(let n of o.documents.keys())Yd(n,e,t)}typeof process>"u",ub("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var Wd={slot:"_11fc52b637ff8a7e__slot"},Ud="data-wp-compat-overlay-slot";function fb(){return typeof document>"u"?null:document}function pb(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var xt=null;function ss(e){return e.setAttribute("aria-hidden","false"),e}function mb(e){let t=e.createElement("div");return t.setAttribute(Ud,""),Wd.slot&&t.classList.add(Wd.slot),e.body.appendChild(t),t}function Gd(){if(typeof window>"u"||!pb()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=fb();if(!e||!e.body)return;if(xt&&xt.ownerDocument===e&&xt.isConnected)return ss(xt);let t=e.querySelector(`[${Ud}]`);return t instanceof HTMLDivElement?(xt=ss(t),xt):(xt?.isConnected&&xt.remove(),xt=ss(mb(e)),xt)}var Xd=b(W(),1),qd=(0,Kd.forwardRef)(function({container:t,...o},n){return(0,Xd.jsx)(tt.Portal,{container:t??Gd(),...o,ref:n})});var Zd=b(ce(),1),$d=b(W(),1),ls="data-wp-hash";function ds(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&bb(document)),e.__wpStyleRuntime}function gb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ls}]`))if(o.getAttribute(ls)===t)return!0;return!1}function Qd(e,t,o){if(!e.head)return;let n=ds(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(gb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ls,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function bb(e){let t=ds();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Qd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Jd(e,t){let o=ds();o.styles.set(e,t);for(let n of o.documents.keys())Qd(n,e,t)}typeof process>"u",Jd("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var hb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Jd("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var wb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},eu=(0,Zd.forwardRef)(function({align:t="center",className:o,side:n="top",sideOffset:r=4,...i},s){return(0,$d.jsx)(tt.Positioner,{ref:s,align:t,side:n,sideOffset:r,...i,className:J(hb["box-sizing"],wb.positioner,o)})});var tu=b(ce(),1);function us(e,t,o){return(0,tu.cloneElement)(e??t,{children:o})}var vb=b(nu(),1);var iu=b(fs(),1),{lock:s3,unlock:su}=(0,iu.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function _b(){let e=vb;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return su(e.privateApis).ThemeProvider}var au=_b();var tn=b(W(),1),ps="data-wp-hash";function ms(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&xb(document)),e.__wpStyleRuntime}function yb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ps}]`))if(o.getAttribute(ps)===t)return!0;return!1}function lu(e,t,o){if(!e.head)return;let n=ms(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(yb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ps,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function xb(e){let t=ms();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)lu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Sb(e,t){let o=ms();o.styles.set(e,t);for(let n of o.documents.keys())lu(n,e,t)}typeof process>"u",Sb("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Rb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Eb={background:"#1e1e1e"},gs=(0,cu.forwardRef)(function({portal:t,positioner:o,children:n,className:r,...i},s){let a=(0,tn.jsx)(au,{color:Eb,children:(0,tn.jsx)(tt.Popup,{ref:s,className:J(Rb.popup,r),...i,children:n})}),l=us(o,(0,tn.jsx)(eu,{}),a);return us(t,(0,tn.jsx)(qd,{}),l)});var du=b(ce(),1),uu=b(W(),1),bs=(0,du.forwardRef)(function(t,o){return(0,uu.jsx)(tt.Trigger,{ref:o,...t})});var fu=b(st(),1),pu=b(W(),1);function mu({children:e}){return(0,pu.jsx)(ir,{direction:(0,fu.isRTL)()?"rtl":"ltr",children:e})}var hs=b(W(),1);function ws(e){return(0,hs.jsx)(mu,{children:(0,hs.jsx)(tt.Root,{...e})})}var on=b(ce(),1),Sr=b(st(),1);var gu=b(ce(),1),vs="data-wp-hash";function _s(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Pb(document)),e.__wpStyleRuntime}function kb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${vs}]`))if(o.getAttribute(vs)===t)return!0;return!1}function bu(e,t,o){if(!e.head)return;let n=_s(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(kb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Pb(e){let t=_s();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)bu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Cb(e,t){let o=_s();o.styles.set(e,t);for(let n of o.documents.keys())bu(n,e,t)}typeof process>"u",Cb("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var Ab={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},ys=(0,gu.forwardRef)(function({render:t,...o},n){return ot({render:t,ref:n,props:ve({className:Ab["visually-hidden"]},o,{"data-visually-hidden":""})})});var xr=b(W(),1);function hu({"aria-describedby":e,"aria-keyshortcuts":t,shortcut:o}){let n=(0,on.useId)(),r=o?n:void 0,i=[e,r].filter(Boolean).join(" ");return{descriptionId:r,targetProps:{"aria-describedby":i||void 0,"aria-keyshortcuts":o?.ariaKeyShortcut??t}}}var wu=(0,on.forwardRef)(function({descriptionId:t,shortcut:o},n){return(0,xr.jsx)(ys,{id:t,"aria-hidden":"true",render:(0,xr.jsx)("span",{ref:n}),children:(0,Sr.sprintf)((0,Sr.__)("Keyboard shortcut: %s"),o.label??o.ariaKeyShortcut)})}),vu=(0,on.forwardRef)(function({className:t,shortcut:o},n){return(0,xr.jsx)("span",{ref:n,"aria-hidden":"true",className:t,dir:"ltr",children:o.displayShortcut})});var nt=b(W(),1),xs="data-wp-hash";function Ss(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Nb(document)),e.__wpStyleRuntime}function Ob(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${xs}]`))if(o.getAttribute(xs)===t)return!0;return!1}function xu(e,t,o){if(!e.head)return;let n=Ss(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ob(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(xs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Nb(e){let t=Ss();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)xu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Ib(e,t){let o=Ss();o.styles.set(e,t);for(let n of o.documents.keys())xu(n,e,t)}typeof process>"u",Ib("c5cdafb1bc","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}");var _u={"icon-button":"_28cfdc260e755391__icon-button",icon:"f1c70d719989a85a__icon"},Rs=(0,yu.forwardRef)(function({label:t,className:o,children:n,disabled:r,focusableWhenDisabled:i=!0,icon:s,size:a,shortcut:l,positioner:c,"aria-describedby":d,"aria-keyshortcuts":m,...u},f){let p=J(_u["icon-button"],o),{descriptionId:g,targetProps:h}=hu({"aria-describedby":d,"aria-keyshortcuts":m,shortcut:l});return(0,nt.jsxs)(ws,{children:[(0,nt.jsxs)(bs,{ref:f,...h,disabled:r&&!i,render:(0,nt.jsx)(br,{...u,size:a,"aria-label":t,disabled:r,focusableWhenDisabled:i}),className:p,children:[(0,nt.jsx)(ao,{icon:s,size:24,className:_u.icon}),l&&g&&(0,nt.jsx)(wu,{descriptionId:g,shortcut:l})]}),(0,nt.jsxs)(gs,{positioner:c,children:[t,l&&(0,nt.jsxs)(nt.Fragment,{children:[" ",(0,nt.jsx)(vu,{shortcut:l})]})]})]})});var Su=b(ce(),1),Es="data-wp-hash";function Ts(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Mb(document)),e.__wpStyleRuntime}function Lb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Es}]`))if(o.getAttribute(Es)===t)return!0;return!1}function Ru(e,t,o){if(!e.head)return;let n=Ts(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Lb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Es,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Mb(e){let t=Ts();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ru(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Bb(e,t){let o=Ts();o.styles.set(e,t);for(let n of o.documents.keys())Ru(n,e,t)}typeof process>"u",Bb("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var Hb={stack:"_19ce0419607e1896__stack"},zb={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},Ut=(0,Su.forwardRef)(function({direction:t,gap:o,align:n,justify:r,wrap:i,render:s,...a},l){let c={gap:o&&zb[o],alignItems:n,justifyContent:r,flexDirection:t,flexWrap:i};return ot({render:s,ref:l,props:ve(a,{style:c,className:Hb.stack})})});var Eu=b(ce(),1),Tu=b(st(),1),Oo=b(W(),1),ks="data-wp-hash";function Ps(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&jb(document)),e.__wpStyleRuntime}function Db(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ks}]`))if(o.getAttribute(ks)===t)return!0;return!1}function ku(e,t,o){if(!e.head)return;let n=Ps(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Db(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ks,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function jb(e){let t=Ps();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ku(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Er(e,t){let o=Ps();o.styles.set(e,t);for(let n of o.documents.keys())ku(n,e,t)}typeof process>"u",Er("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Fb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Er("96553466c8","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var Vb={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",Er("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var Rr={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",Er("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Wb={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},co=(0,Eu.forwardRef)(function({children:t,variant:o="default",tone:n="brand",openInNewTab:r=!1,render:i,className:s,...a},l){return ot({render:i,defaultTagName:"a",ref:l,props:ve(a,{className:J(Wb.a,Fb["box-sizing"],Vb["outset-ring--focus-except-active"],o!=="unstyled"&&Rr.link,o!=="unstyled"&&Rr[`is-${n}`],o==="unstyled"&&Rr["is-unstyled"],s),target:r?"_blank":void 0,children:(0,Oo.jsxs)(Oo.Fragment,{children:[t,r&&(0,Oo.jsx)("span",{className:Rr["link-icon"],role:"img","aria-label":(0,Tu.__)("(opens in a new tab)")})]})})})});var nn={};Mt(nn,{ActionButton:()=>Qu,ActionLink:()=>ef,Actions:()=>Fu,CloseIcon:()=>Gu,Description:()=>zu,Root:()=>Au,Title:()=>Lu});var No=b(ce(),1);import{speak as Yb}from"@wordpress/a11y";var Io=b(W(),1),As="data-wp-hash";function Os(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Gb(document)),e.__wpStyleRuntime}function Ub(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${As}]`))if(o.getAttribute(As)===t)return!0;return!1}function Pu(e,t,o){if(!e.head)return;let n=Os(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ub(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(As,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Gb(e){let t=Os();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Pu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Cu(e,t){let o=Os();o.styles.set(e,t);for(let n of o.documents.keys())Pu(n,e,t)}typeof process>"u",Cu("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Kb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Cu("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Cs={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Xb={neutral:null,info:ns,warning:Qi,success:is,error:ts};function qb(e){return e==="error"?"assertive":"polite"}function Zb(e){if(e){if(typeof e=="string")return e;try{return(0,No.renderToString)(e)}catch{return}}}function Qb(e,t){let o=Zb(e);(0,No.useEffect)(()=>{o&&Yb(o,t)},[o,t])}var Au=(0,No.forwardRef)(function({intent:t="neutral",children:o,icon:n,spokenMessage:r=o,politeness:i=qb(t),render:s,...a},l){Qb(r,i);let c=n===null?null:n??Xb[t],d=J(Cs.notice,Cs[`is-${t}`],Kb["box-sizing"]);return ot({defaultTagName:"div",render:s,ref:l,props:ve({className:d,children:(0,Io.jsxs)(Io.Fragment,{children:[o,c&&(0,Io.jsx)(ao,{className:Cs.icon,icon:c})]})},a)})});var Ou=b(ce(),1);var Iu=b(W(),1),Ns="data-wp-hash";function Is(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&$b(document)),e.__wpStyleRuntime}function Jb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ns}]`))if(o.getAttribute(Ns)===t)return!0;return!1}function Nu(e,t,o){if(!e.head)return;let n=Is(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Jb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ns,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function $b(e){let t=Is();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Nu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function eh(e,t){let o=Is();o.styles.set(e,t);for(let n of o.documents.keys())Nu(n,e,t)}typeof process>"u",eh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var th={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Lu=(0,Ou.forwardRef)(function({className:t,...o},n){return(0,Iu.jsx)(We,{ref:n,variant:"heading-md",className:J(th.title,t),...o})});var Mu=b(ce(),1);var Hu=b(W(),1),Ls="data-wp-hash";function Ms(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&nh(document)),e.__wpStyleRuntime}function oh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ls}]`))if(o.getAttribute(Ls)===t)return!0;return!1}function Bu(e,t,o){if(!e.head)return;let n=Ms(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(oh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ls,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function nh(e){let t=Ms();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Bu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function rh(e,t){let o=Ms();o.styles.set(e,t);for(let n of o.documents.keys())Bu(n,e,t)}typeof process>"u",rh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var ih={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},zu=(0,Mu.forwardRef)(function({className:t,...o},n){return(0,Hu.jsx)(We,{ref:n,variant:"body-md",className:J(ih.description,t),...o})});var Du=b(ce(),1);var Bs="data-wp-hash";function Hs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&ah(document)),e.__wpStyleRuntime}function sh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Bs}]`))if(o.getAttribute(Bs)===t)return!0;return!1}function ju(e,t,o){if(!e.head)return;let n=Hs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(sh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Bs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function ah(e){let t=Hs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ju(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ch(e,t){let o=Hs();o.styles.set(e,t);for(let n of o.documents.keys())ju(n,e,t)}typeof process>"u",ch("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var lh={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Fu=(0,Du.forwardRef)(function({render:t,...o},n){return ot({defaultTagName:"div",render:t,ref:n,props:ve({className:lh.actions},o)})});var Vu=b(ce(),1),Wu=b(st(),1);var Uu=b(W(),1),zs="data-wp-hash";function Ds(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&uh(document)),e.__wpStyleRuntime}function dh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${zs}]`))if(o.getAttribute(zs)===t)return!0;return!1}function Yu(e,t,o){if(!e.head)return;let n=Ds(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(dh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(zs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function uh(e){let t=Ds();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Yu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function fh(e,t){let o=Ds();o.styles.set(e,t);for(let n of o.documents.keys())Yu(n,e,t)}typeof process>"u",fh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var ph={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Gu=(0,Vu.forwardRef)(function({className:t,icon:o=$i,label:n=(0,Wu.__)("Dismiss"),...r},i){return(0,Uu.jsx)(Rs,{...r,ref:i,className:J(ph["close-icon"],t),variant:"minimal",size:"small",tone:"neutral",icon:o,label:n})});var Xu=b(ce(),1);var Zu=b(W(),1),js="data-wp-hash";function Fs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&gh(document)),e.__wpStyleRuntime}function mh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${js}]`))if(o.getAttribute(js)===t)return!0;return!1}function qu(e,t,o){if(!e.head)return;let n=Fs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(mh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(js,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function gh(e){let t=Fs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)qu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function bh(e,t){let o=Fs();o.styles.set(e,t);for(let n of o.documents.keys())qu(n,e,t)}typeof process>"u",bh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Ku={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Qu=(0,Xu.forwardRef)(function({className:t,loading:o,loadingAnnouncement:n,variant:r,...i},s){return(0,Zu.jsx)(br,{...i,...o!==void 0?{loading:o,loadingAnnouncement:n??""}:{},ref:s,size:"compact",tone:"neutral",variant:r,className:J(Ku["action-button"],Ku[`is-action-button-${r}`],t)})});var Ju=b(ce(),1);var Ws=b(W(),1),Vs="data-wp-hash";function Ys(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&wh(document)),e.__wpStyleRuntime}function hh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Vs}]`))if(o.getAttribute(Vs)===t)return!0;return!1}function $u(e,t,o){if(!e.head)return;let n=Ys(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(hh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function wh(e){let t=Ys();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)$u(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function vh(e,t){let o=Ys();o.styles.set(e,t);for(let n of o.documents.keys())$u(n,e,t)}typeof process>"u",vh("726c480820","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._1904b570a89bb815__description{text-wrap:pretty}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f3f9ff);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#a9c6e7);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#fff7e1);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1bc7c);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#926300)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#ebffed);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#94d29e);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#008030)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#fff6f5);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dab1aa);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var _h={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},ef=(0,Ju.forwardRef)(function({className:t,render:o,...n},r){return(0,Ws.jsx)(We,{ref:r,className:J(_h["action-link"],t),...n,variant:"body-md",render:(0,Ws.jsx)(co,{tone:"neutral",variant:"default",render:o})})});var tf=b(ce(),1),of=b(W(),1),nf=(0,tf.forwardRef)(({children:e,className:t,ariaLabel:o,as:n="div",...r},i)=>(0,of.jsx)(n,{ref:i,className:J("admin-ui-navigable-region",t),"aria-label":o,role:"region",tabIndex:"-1",...r,children:e}));nf.displayName="NavigableRegion";var rf=nf;var sf=b(st(),1);var Gt=b(W(),1),Gs="data-wp-hash";function Ks(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&xh(document)),e.__wpStyleRuntime}function yh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Gs}]`))if(o.getAttribute(Gs)===t)return!0;return!1}function af(e,t,o){if(!e.head)return;let n=Ks(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(yh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Gs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function xh(e){let t=Ks();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)af(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Sh(e,t){let o=Ks();o.styles.set(e,t);for(let n of o.documents.keys())af(n,e,t)}typeof process>"u",Sh("72ef022400",".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}");var Us={list:"bfb5a2dd8cceebd3__list",li:"a4759b4cb2c8bd92__li",item:"_07da506d3f2d9afe__item"},Rh=({items:e,currentHref:t,ariaLabel:o=(0,sf.__)("Sections"),linkComponent:n,className:r})=>{if(!e.length)return null;let i=n??"a";return(0,Gt.jsx)("nav",{"aria-label":o,className:r,children:(0,Gt.jsx)(Ut,{render:(0,Gt.jsx)("ul",{role:"list"}),direction:"row",align:"center",gap:"md",className:Us.list,children:e.map(s=>(0,Gt.jsx)("li",{className:Us.li,children:(0,Gt.jsx)(We,{variant:"body-md",className:Us.item,render:(0,Gt.jsx)(co,{variant:"unstyled","aria-current":s.href===t?"page":void 0,render:(0,Gt.jsx)(i,{href:s.href})}),children:s.label})},s.href))})})},cf=Rh;var df=b(rn(),1),{Fill:uf,Slot:ff}=(0,df.createSlotFill)("SidebarToggle");var Ze=b(W(),1),Xs="data-wp-hash";function qs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Th(document)),e.__wpStyleRuntime}function Eh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Xs}]`))if(o.getAttribute(Xs)===t)return!0;return!1}function pf(e,t,o){if(!e.head)return;let n=qs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Eh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Xs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Th(e){let t=qs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)pf(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function kh(e,t){let o=qs();o.styles.set(e,t);for(let n of o.documents.keys())pf(n,e,t)}typeof process>"u",kh("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var St={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function mf({headingLevel:e=1,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:s,navigation:a,components:l,showSidebarToggle:c=!0}){let d=`h${e}`,m=!!a?.items?.length;return(0,Ze.jsxs)(Ut,{direction:"column",className:J(St.header,m&&St["has-navigation"]),children:[(0,Ze.jsxs)(Ut,{className:St["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,Ze.jsxs)(Ut,{direction:"row",gap:"sm",align:"center",justify:"start",className:St["header-lockup"],children:[c&&(0,Ze.jsx)(ff,{bubblesVirtually:!0,className:St["sidebar-toggle-slot"]}),n&&(0,Ze.jsx)("div",{className:St["header-visual"],"aria-hidden":"true",children:n}),r&&(0,Ze.jsx)(We,{className:St["header-title"],render:(0,Ze.jsx)(d,{}),variant:"heading-lg",children:r}),t,o]}),s&&(0,Ze.jsx)(Ut,{align:"center",className:St["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,Ze.jsx)(We,{render:(0,Ze.jsx)("p",{}),variant:"body-md",className:St["header-subtitle"],children:i}),m&&(0,Ze.jsx)(cf,{...a,linkComponent:l?.link,className:St["header-navigation"]})]})}var sn=b(W(),1),Qs="data-wp-hash";function Js(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Ch(document)),e.__wpStyleRuntime}function Ph(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Qs}]`))if(o.getAttribute(Qs)===t)return!0;return!1}function gf(e,t,o){if(!e.head)return;let n=Js(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ph(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Qs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Ch(e){let t=Js();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)gf(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Ah(e,t){let o=Js();o.styles.set(e,t);for(let n of o.documents.keys())gf(n,e,t)}typeof process>"u",Ah("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Zs={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function bf({headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,children:s,className:a,actions:l,navigation:c,components:d,ariaLabel:m,hasPadding:u=!1,showSidebarToggle:f=!0}){let p=J(Zs.page,a);return(0,sn.jsxs)(rf,{className:p,ariaLabel:m??(typeof r=="string"?r:""),children:[(r||t||o||l||n||!!c?.items?.length)&&(0,sn.jsx)(mf,{headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:l,navigation:c,components:d,showSidebarToggle:f}),u?(0,sn.jsx)("div",{className:J(Zs.content,Zs["has-padding"]),children:s}):s]})}bf.SidebarToggleFill=uf;var $s=bf;var ut=b(rn()),Ff=b(an()),Vf=b(ce()),At=b(st()),Wf=b(Tr());import{privateApis as Kh}from"@wordpress/connectors";var vf=b(fs()),{lock:a8,unlock:Lo}=(0,vf.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/routes");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='09e9b056ea']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","09e9b056ea"),e.appendChild(document.createTextNode(".connectors-page{box-sizing:border-box;margin:0 auto;max-width:680px;padding:24px;width:100%}.connectors-page .components-item{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;padding:20px;scroll-margin-top:120px}.connectors-page .connector-settings__error{color:#cc1818}.connectors-page .connector-settings .components-text-control__input{font-family:monospace;scroll-margin-top:120px}.connectors-page__file-mods-notice{margin-bottom:16px}.connectors-page--empty{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:32px;justify-content:center;text-align:center}.connectors-page .ai-plugin-callout{background-color:#e7d4e4;background-image:radial-gradient(ellipse 70% 120% at 18% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 92% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 58% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%);border-radius:8px;overflow:hidden;padding:24px;padding-inline-end:150px;position:relative}[dir=rtl] .connectors-page .ai-plugin-callout{background-image:radial-gradient(ellipse 70% 120% at 82% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 8% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 42% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%)}.connectors-page .ai-plugin-callout__content{align-items:flex-start;display:flex;flex-direction:column;gap:12px;padding-top:2px}.connectors-page .ai-plugin-callout__content p{font-size:13px;line-height:20px;margin:0}.connectors-page .ai-plugin-callout__decoration{height:110px;inset-inline-end:16px;position:absolute;top:12px;width:110px}.connectors-page>p{color:#949494}@media (max-width:680px){.connectors-page .ai-plugin-callout{padding:12px;padding-inline-end:100px}.connectors-page .ai-plugin-callout__decoration{height:75px;inset-inline-end:8px;top:8px;width:75px}}@media (max-width:480px){.connectors-page{padding:8px}.connectors-page .ai-plugin-callout{padding-inline-end:130px}.connectors-page .components-item{padding:12px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child svg{height:32px;width:32px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child>.components-h-stack:last-child{align-items:flex-end;flex-direction:column}}")),document.head.appendChild(e)}var dn=b(rn()),sa=b(Tr()),un=b(an()),Et=b(ce()),Qe=b(st()),Hf=b(ea()),zf=b(xf());var kr=b(rn()),na=b(ce()),Af=b(an()),lo=b(st());import{__experimentalRegisterConnector as Oh,__experimentalConnectorItem as Cf,__experimentalDefaultConnectorSettings as Nh,__experimentalApplicationPasswordConnectorSettings as Ih,privateApis as Lh}from"@wordpress/connectors";var ta=b(Tr()),ln=b(an()),cn=b(ce()),pe=b(st()),Sf=b(ea());function oa({file:e,settingName:t,connectorName:o,isInstalled:n,isActivated:r,keySource:i="none",initialIsConnected:s=!1}){let[a,l]=(0,cn.useState)(!1),[c,d]=(0,cn.useState)(!1),[m,u]=(0,cn.useState)(s),[f,p]=(0,cn.useState)(null),g=e?.replace(/\.php$/,""),h=g?.includes("/")?g.split("/")[0]:g,{derivedPluginStatus:y,canManagePlugins:_,currentApiKey:v,currentUsername:w,hasStoredCredentials:R,hasResolvedSettings:x,canInstallPlugins:S}=(0,ln.useSelect)(Q=>{let q=Q(ta.store),ne=q.getEntityRecord("root","site")?.[t],se=typeof ne=="string"?ne:"",ze=typeof ne=="object"&&ne!==null?ne:void 0,ae=ze!==void 0?!!ze.username&&!!ze.password:!!se,ge=q.hasFinishedResolution("getEntityRecord",["root","site"]),be=!!q.canUser("create",{kind:"root",name:"plugin"}),Ee={currentApiKey:se,currentUsername:ze?.username??"",hasStoredCredentials:ae,hasResolvedSettings:ge,canInstallPlugins:be};if(!e)return{...Ee,derivedPluginStatus:ge?"active":"checking",canManagePlugins:void 0};let ye=q.getEntityRecord("root","plugin",g);if(!q.hasFinishedResolution("getEntityRecord",["root","plugin",g]))return{...Ee,derivedPluginStatus:"checking",canManagePlugins:void 0};if(ye){let ft=ye.status==="active"||ye.status==="network-active";return{...Ee,derivedPluginStatus:ft?"active":"inactive",canManagePlugins:!0}}let rt="not-installed";return r?rt="active":n&&(rt="inactive"),{...Ee,derivedPluginStatus:rt,canManagePlugins:!1}},[e,g,t,n,r]),E=f??y,T=_,P=E==="active"&&m||f==="active"&&R,{saveEntityRecord:N,invalidateResolution:H}=(0,ln.useDispatch)(ta.store),{createSuccessNotice:j,createErrorNotice:L}=(0,ln.useDispatch)(Sf.store),k=Q=>N("root","site",{[t]:Q},{throwOnError:!0}),I=()=>{j((0,pe.sprintf)((0,pe.__)("%s connected successfully."),o),{id:"connector-connect-success",type:"snackbar"})},C=()=>{j((0,pe.sprintf)((0,pe.__)("%s disconnected."),o),{id:"connector-disconnect-success",type:"snackbar"})},A=()=>{L((0,pe.sprintf)((0,pe.__)("Failed to disconnect %s."),o),{id:"connector-disconnect-error",type:"snackbar"})},M=async()=>{if(h){d(!0);try{await N("root","plugin",{slug:h,status:"active"},{throwOnError:!0}),p("active"),H("getEntityRecord",["root","site"]),l(!0),j((0,pe.sprintf)((0,pe.__)("Plugin for %s installed and activated successfully."),o),{id:"connector-plugin-install-success",type:"snackbar"})}catch{L((0,pe.sprintf)((0,pe.__)("Failed to install plugin for %s."),o),{id:"connector-plugin-install-error",type:"snackbar"})}finally{d(!1)}}},X=async()=>{if(e){d(!0);try{await N("root","plugin",{plugin:g,status:"active"},{throwOnError:!0}),p("active"),H("getEntityRecord",["root","site"]),l(!0),j((0,pe.sprintf)((0,pe.__)("Plugin for %s activated successfully."),o),{id:"connector-plugin-activate-success",type:"snackbar"})}catch{L((0,pe.sprintf)((0,pe.__)("Failed to activate plugin for %s."),o),{id:"connector-plugin-activate-error",type:"snackbar"})}finally{d(!1)}}};return{pluginStatus:E,canInstallPlugins:S,canActivatePlugins:T,isExpanded:a,setIsExpanded:l,isBusy:c,isConnected:P,currentApiKey:v,currentUsername:w,hasResolvedSettings:x,keySource:i,handleButtonClick:()=>{if(E==="not-installed"){if(S===!1)return;M()}else if(E==="inactive"){if(T===!1)return;X()}else l(!a)},getButtonLabel:()=>{if(c)return E==="not-installed"?(0,pe.__)("Installing\u2026"):(0,pe.__)("Activating\u2026");if(a)return(0,pe.__)("Cancel");if(P)return(0,pe.__)("Edit");switch(E){case"checking":return(0,pe.__)("Checking\u2026");case"not-installed":return(0,pe.__)("Install");case"inactive":return(0,pe.__)("Activate");case"active":return(0,pe.__)("Set up")}},saveApiKey:async Q=>{let q=v;try{let se=(await k(Q))?.[t];if(Q&&(se===q||!se))throw new Error("It was not possible to connect to the provider using this key.");u(!0),I()}catch($){throw console.error("Failed to save API key:",$),$}},removeApiKey:async()=>{try{await k(""),u(!1),C()}catch(Q){console.error("Failed to remove API key:",Q),A()}},saveCredentials:async({username:Q,applicationPassword:q})=>{try{let se=(await k({username:Q,password:q}))?.[t];if(!se?.username||!se?.password)throw new Error((0,pe.__)("It was not possible to save these credentials."));u(!0),I()}catch($){throw console.error("Failed to save credentials:",$),$}},removeCredentials:async()=>{try{await k({username:"",password:""}),u(!1),C()}catch(Q){console.error("Failed to remove credentials:",Q),A()}}}}var ue=b(W()),Rf=()=>(0,ue.jsx)("svg",{width:"40",height:"40",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:(0,ue.jsx)("path",{d:"M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364l2.0201-1.1685a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.4043-.6813zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z",fill:"currentColor"})}),Ef=()=>(0,ue.jsx)("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:(0,ue.jsx)("path",{d:"M6.2 21.024L12.416 17.536L12.52 17.232L12.416 17.064H12.112L11.072 17L7.52 16.904L4.44 16.776L1.456 16.616L0.704 16.456L0 15.528L0.072 15.064L0.704 14.64L1.608 14.72L3.608 14.856L6.608 15.064L8.784 15.192L12.008 15.528H12.52L12.592 15.32L12.416 15.192L12.28 15.064L9.176 12.96L5.816 10.736L4.056 9.456L3.104 8.808L2.624 8.2L2.416 6.872L3.28 5.92L4.44 6L4.736 6.08L5.912 6.984L8.424 8.928L11.704 11.344L12.184 11.744L12.376 11.608L12.4 11.512L12.184 11.152L10.4 7.928L8.496 4.648L7.648 3.288L7.424 2.472C7.344 2.136 7.288 1.856 7.288 1.512L8.272 0.176L8.816 0L10.128 0.176L10.68 0.656L11.496 2.52L12.816 5.456L14.864 9.448L15.464 10.632L15.784 11.728L15.904 12.064H16.112V11.872L16.28 9.624L16.592 6.864L16.896 3.312L17 2.312L17.496 1.112L18.48 0.464L19.248 0.832L19.88 1.736L19.792 2.32L19.416 4.76L18.68 8.584L18.2 11.144H18.48L18.8 10.824L20.096 9.104L22.272 6.384L23.232 5.304L24.352 4.112L25.072 3.544H26.432L27.432 5.032L26.984 6.568L25.584 8.344L24.424 9.848L22.76 12.088L21.72 13.88L21.816 14.024L22.064 14L25.824 13.2L27.856 12.832L30.28 12.416L31.376 12.928L31.496 13.448L31.064 14.512L28.472 15.152L25.432 15.76L20.904 16.832L20.848 16.872L20.912 16.952L22.952 17.144L23.824 17.192H25.96L29.936 17.488L30.976 18.176L31.6 19.016L31.496 19.656L29.896 20.472L27.736 19.96L22.696 18.76L20.968 18.328H20.728V18.472L22.168 19.88L24.808 22.264L28.112 25.336L28.28 26.096L27.856 26.696L27.408 26.632L24.504 24.448L23.384 23.464L20.848 21.328H20.68V21.552L21.264 22.408L24.352 27.048L24.512 28.472L24.288 28.936L23.488 29.216L22.608 29.056L20.8 26.52L18.936 23.664L17.432 21.104L17.248 21.208L16.36 30.768L15.944 31.256L14.984 31.624L14.184 31.016L13.76 30.032L14.184 28.088L14.696 25.552L15.112 23.536L15.488 21.032L15.712 20.2L15.696 20.144L15.512 20.168L13.624 22.76L10.752 26.64L8.48 29.072L7.936 29.288L6.992 28.8L7.08 27.928L7.608 27.152L10.752 23.152L12.648 20.672L13.872 19.24L13.864 19.032H13.792L5.44 24.456L3.952 24.648L3.312 24.048L3.392 23.064L3.696 22.744L6.208 21.016L6.2 21.024Z",fill:"#D97757"})}),Tf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("path",{d:"M0 4C0 1.79086 1.79086 0 4 0H28C30.2091 0 32 1.79086 32 4V28C32 30.2091 30.2091 32 28 32H4C1.79086 32 0 30.2091 0 28V4Z",fill:"#F0F0F0"}),(0,ue.jsx)("path",{d:"M14.5 8V12H17.5V8H19V12H20.5C20.7652 12 21.0196 12.1054 21.2071 12.2929C21.3946 12.4804 21.5 12.7348 21.5 13V17L18.5 21V23C18.5 23.2652 18.3946 23.5196 18.2071 23.7071C18.0196 23.8946 17.7652 24 17.5 24H14.5C14.2348 24 13.9804 23.8946 13.7929 23.7071C13.6054 23.5196 13.5 23.2652 13.5 23V21L10.5 17V13C10.5 12.7348 10.6054 12.4804 10.7929 12.2929C10.9804 12.1054 11.2348 12 11.5 12H13V8H14.5ZM15 20.5V22.5H17V20.5L20 16.5V13.5H12V16.5L15 20.5Z",fill:"#949494"})]}),kf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 44 44",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("rect",{width:"44",height:"44",fill:"#357B49",rx:"6"}),(0,ue.jsx)("path",{fill:"#fff",fillRule:"evenodd",d:"m29.746 28.31-6.392-16.797c-.152-.397-.305-.672-.789-.675-.673 0-1.408.611-1.746 1.316l-7.378 16.154c-.072.16-.143.311-.214.454-.5.995-1.045 1.546-2.357 1.626a.399.399 0 0 0-.16.033l-.01.004a.399.399 0 0 0-.23.392v.01c0 .054.01.106.03.155l.004.01a.416.416 0 0 0 .394.252h6.212a.417.417 0 0 0 .307-.12.416.416 0 0 0 .124-.305.398.398 0 0 0-.105-.302.399.399 0 0 0-.294-.127c-.757 0-2.197-.062-2.197-1.164.02-.318.103-.63.245-.916l1.399-3.152c.52-1.163 1.654-1.163 2.572-1.163h5.843c.023 0 .044 0 .062.003.13.014.16.081.214.242l1.534 4.07a2.857 2.857 0 0 1 .216 1.04c0 .054-.003.104-.01.153-.09.726-.831.887-1.49.887a.4.4 0 0 0-.294.127l-.007.008-.007.008a.401.401 0 0 0-.092.286v.01c0 .054.01.106.03.155l.005.01a.42.42 0 0 0 .395.252h7.011a.413.413 0 0 0 .279-.13.412.412 0 0 0 .11-.297.387.387 0 0 0-.09-.294.388.388 0 0 0-.277-.135c-1.448-.122-2.295-.643-2.847-2.08Zm-11.985-5.844 2.847-6.304c.361-.728.659-1.486.889-2.265 0-.06.03-.092.06-.092s.061.032.061.091c.02.122.045.247.073.374.197.888.584 1.878.914 2.723l.176.453 1.684 4.529a.927.927 0 0 1 .092.4.473.473 0 0 1-.009.094c-.041.202-.228.272-.602.272h-6.063c-.122 0-.184-.03-.184-.092a.36.36 0 0 1 .062-.183Zm17.107-.721c0 .786-.446 1.231-1.25 1.231-.806 0-1.125-.409-1.125-1.034 0-.786.465-1.231 1.25-1.231.785 0 1.125.427 1.125 1.034ZM9.629 23.002c.803 0 1.25-.447 1.25-1.231 0-.607-.343-1.036-1.128-1.036-.785 0-1.25.447-1.25 1.231 0 .625.325 1.036 1.128 1.036Z",clipRule:"evenodd"})]}),Pf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",style:{flex:"none",lineHeight:1},viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"#3186FF"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-0)"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-1)"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-2)"}),(0,ue.jsxs)("defs",{children:[(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-0",x1:"7",x2:"11",y1:"15.5",y2:"12",children:[(0,ue.jsx)("stop",{stopColor:"#08B962"}),(0,ue.jsx)("stop",{offset:"1",stopColor:"#08B962",stopOpacity:"0"})]}),(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-1",x1:"8",x2:"11.5",y1:"5.5",y2:"11",children:[(0,ue.jsx)("stop",{stopColor:"#F94543"}),(0,ue.jsx)("stop",{offset:"1",stopColor:"#F94543",stopOpacity:"0"})]}),(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-2",x1:"3.5",x2:"17.5",y1:"13.5",y2:"12",children:[(0,ue.jsx)("stop",{stopColor:"#FABC12"}),(0,ue.jsx)("stop",{offset:".46",stopColor:"#FABC12",stopOpacity:"0"})]})]})]});var _e=b(W()),{store:Mh}=Lo(Lh);function Of(){try{return JSON.parse(document.getElementById("wp-script-module-data-options-connectors-wp-admin")?.textContent??"{}")}catch{return{}}}function ra(){return Of().connectors??{}}function Nf(){return!!Of().isFileModDisabled}var Bh={google:Pf,openai:Rf,anthropic:Ef,akismet:kf};function Hh(e,t){if(t)return(0,_e.jsx)("img",{src:t,alt:"",width:40,height:40});let o=Bh[e];return o?(0,_e.jsx)(o,{}):(0,_e.jsx)(Tf,{})}var zh=()=>(0,_e.jsx)("span",{style:{color:"#345b37",backgroundColor:"#eff8f0",padding:"4px 12px",borderRadius:"2px",fontSize:"13px",fontWeight:"var(--wpds-typography-font-weight-emphasis)",whiteSpace:"nowrap"},children:(0,lo.__)("Connected")}),Dh=({slug:e})=>(0,_e.jsx)(co,{href:(0,lo.sprintf)((0,lo.__)("https://wordpress.org/plugins/%s/"),e),openInNewTab:!0,children:(0,lo.__)("Learn more")}),jh=()=>(0,_e.jsx)(Yi,{children:(0,lo.__)("Not available")});function If({isConnected:e,showUnavailableBadge:t,pluginSlug:o,isExpanded:n,isBusy:r,pluginStatus:i,actionButtonRef:s,handleButtonClick:a,getButtonLabel:l}){return(0,_e.jsxs)(kr.__experimentalHStack,{spacing:3,expanded:!1,children:[e&&(0,_e.jsx)(zh,{}),t&&(o?(0,_e.jsx)(Dh,{slug:o}):(0,_e.jsx)(jh,{})),!t&&(0,_e.jsx)(kr.Button,{ref:s,variant:n||e?"tertiary":"secondary",size:"compact",onClick:a,disabled:i==="checking"||r,isBusy:r,accessibleWhenDisabled:!0,children:l()})]})}function Lf(e){let t=e?.replace(/\.php$/,"");return t?.includes("/")?t.split("/")[0]:t}function Fh({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="api_key"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=Lf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:m,isExpanded:u,setIsExpanded:f,isBusy:p,isConnected:g,currentApiKey:h,hasResolvedSettings:y,keySource:_,handleButtonClick:v,getButtonLabel:w,saveApiKey:R,removeApiKey:x}=oa({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),S=_==="env"||_==="constant",E=c==="not-installed"&&d===!1||c==="inactive"&&m===!1,T=(0,na.useRef)(null);return(0,_e.jsx)(Cf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:(0,_e.jsx)(If,{isConnected:g,showUnavailableBadge:E,pluginSlug:l,isExpanded:u,isBusy:p,pluginStatus:c,actionButtonRef:T,handleButtonClick:v,getButtonLabel:w}),children:u&&c==="active"&&y&&(0,_e.jsx)(Nh,{initialValue:S?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":h,helpUrl:a,readOnly:g||S,keySource:_,onRemove:S?void 0:async()=>{await x(),T.current?.focus()},onSave:async P=>{await R(P),f(!1),T.current?.focus()}},g?"connected":"setup")})}function Vh({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="application_password"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=Lf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:m,isExpanded:u,setIsExpanded:f,isBusy:p,isConnected:g,currentUsername:h,hasResolvedSettings:y,keySource:_,handleButtonClick:v,getButtonLabel:w,saveCredentials:R,removeCredentials:x}=oa({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),S=_==="env"||_==="constant",E=(0,na.useRef)(null),T=c==="not-installed"&&d===!1||c==="inactive"&&m===!1;return(0,_e.jsx)(Cf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:(0,_e.jsx)(If,{isConnected:g,showUnavailableBadge:T,pluginSlug:l,isExpanded:u,isBusy:p,pluginStatus:c,actionButtonRef:E,handleButtonClick:v,getButtonLabel:w}),children:u&&c==="active"&&y&&(0,_e.jsx)(Ih,{initialUsername:S?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":h,helpUrl:a,readOnly:g||S,keySource:_,onRemove:S?void 0:async()=>{await x(),E.current?.focus()},onSave:async P=>{await R(P),f(!1),E.current?.focus()}},g?"connected":"setup")})}function Mf(){let e=ra(),t=o=>o.replace(/[^a-z0-9-_]/gi,"-");for(let[o,n]of Object.entries(e)){if(o==="akismet"&&!n.plugin?.isInstalled)continue;let{authentication:r}=n,i=t(o),s={name:n.name,description:n.description,type:n.type,logo:Hh(o,n.logoUrl),authentication:r,plugin:n.plugin},a=Lo((0,Af.select)(Mh)).getConnector(i);r.method==="api_key"&&!a?.render?s.render=Fh:r.method==="application_password"&&!a?.render&&(s.render=Vh),Oh(i,s)}}var Pr=b(W());function Bf(){return(0,Pr.jsx)("div",{className:"ai-plugin-callout__decoration","aria-hidden":"true",children:(0,Pr.jsx)("svg",{viewBox:"0 0 248 248",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",focusable:"false",style:{width:"100%",height:"100%"},children:(0,Pr.jsx)("image",{href:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAQAElEQVR4AezdC3ojWW5tYflOzPbIbI/M9sh8+WdrdZ+KpiiKL5FB5KedwN7AeSFIpHRYmfX/PubXVGAqMBV4kQpMw3qRBzXbnApMBT4+pmHNq2AqMBV4mQpMw3qZR3X9RmeGqcCrV2Aa1qs/wdn/VOCNKjAN640e9hx1KvDqFZiG9epPcPY/FThWgZ1q07B2+mDnWFOBPVZgGtYen+qcaSqw0wpMw9rpg51jTQX2WIFpWMee6mhTganAU1ZgGtZTPpbZ1FRgKnCsAtOwjlVltKnAVOApKzAN6ykfy2zqcRWYlV6pAtOwXulpzV6nAm9egWlYb/4CmONPBV6pAtOwXulpve9e//Nw9P/7xL8d7Hy9aQWubFhvWrU59qMr8D+HBcPBna93rcA0rHd98q91bs3q3w9bBv7Bna93rMA0rHd86nPmqcCLVmAa1os+uF/Y9m8u6Q7rvw8bgLnDOhTiXb+mYb3rk3+tc//rYbsaVTjQP18amct4+h9hftt3BaZh7fv57v107rNg7+ec831WYBrWZyHGPHUF/vewu//6xNqg+HMRfyjMrb+edb5pWM/6ZGZfawX86Bc0qTU2/htVYBrWGz3sOepU4NUrMA3r1Z/g7H8q8EYVmIZ1h4c9U04FpgL3qcA0rPvUdWadCkwF7lCBaVh3KOpMORWYCtynAtOw7lPXmfVdKjDnfGgFpmE9tNyz2FRgKnBNBaZhXVO9GTsVmAo8tALTsB5a7llsKjAVuKYCv9uwrtn5jJ0KTAXergLTsN7ukc+BpwKvW4FpWK/77GbnU4G3q8A0rLd75L914Fl3KnB9BaZhXV/DmWEqMBV4UAWmYT2o0LPMVGAqcH0FpmFdX8OZYSowFfhrBe7GpmHdrbQz8VRgKnDrCkzDunVFZ76pwFTgbhWYhnW30s7EU4GpwK0rMA3r1hW9fr6ZYSowFfiiAtOwvijMyFOBqcDzVWAa1vM9k9nRVGAq8EUFpmF9UZiRpwKPqMCs8bMKTMP6Wb0meyowFfjFCkzD+sXiz9JTganAzyowDetn9ZrsqcBU4Bcr8NIN6xfrNktPBaYCv1CBaVi/UPRZciowFbisAtOwLqvbjJoKTAV+oQLTsH6h6LPkBRWYIVOBQwWmYR2KMF9TganAa1RgGtZrPKfZ5VRgKnCowDSsQxHmayowFXimCny9l2lYX9dmIlOBqcCTVWAa1pM9kNnOVGAq8HUFpmF9XZuJTAWmAk9WgWlYT/ZArt/OzDAV2G8FpmHt99nOyaYCu6vANKzdPdK7HOjfDrP+9yf4B/fP138efoeDma+pwP0rMA3r/jXewwqaVFjP8x8HAmIHd74eXIG3W24a1ts98pse+H8Os8HBzNdU4P4VmIZ1/xrvYQU/9v3L4SCwNqh/P2iwagdpvqYC96nANKz71HVmnQpMBe5QgXduWHco526n9B3W9tJ91fi7Pfwc7HkqMA3reZ7FM+/kXw+bc7EeDvTPV1z8jzC/TQXuWYFpWPes7sw9FZgK3LQC07BuWs7dTva/h5P91ye6YGfT2EP4eb9mZ/uowDSsfTzHe5/CHVXQqKzHbjX6YCpwtwpMw7pbaX808f8dsoN7oQOdr6nAVGBbgWlY24o8hvvEzXcnp1YTl3cq51ExTdRe7GldE6ev2vhTgbtV4KyGdbfV33diDeC7T9bE5T1LlezFntb94PRVG38qcLcKTMO6W2lPTuy/GPdfiJfED+6G6Lg8/m/Dnuxne7lOe5Y9/naNZv0HVGAa1gOKfMYSGkI4I/1XUp59f79SlFn0sRWYhvXYereaex/3PyunQT9iiePlPMbOKlOBJ67ANKzfeTiakvufVsdDmjgtPnYq8PYVmIb1Oy8B9z7uf06tLi7vVM7EpgJvVYFpWM/xuF1mB3dFz7Gr2cXOK/B6x5uG9RzPzH1VeI4dzS6mAk9YgWlYT/hQZktTganA8QpMwzpel1GnAlOBJ6zANKyLH8oMnApMBR5dgWlYj674rDcVmApcXIFpWBeXbgZOBaYCj67ANKxHV3zWe8UKzJ6fpALTsJ7kQcw2pgJTge8rMA3r+xpNxlRgKvAkFZiG9SQPYrYxFZgKfF+BRzSs73cxGVOBqcBU4IwKTMM6o0iTMhWYCjxHBaZhPcdzmF1MBaYCZ1RgGtYZRXrSFP9Wln/gD/htEwd/mTqNT4Nyj2ny+7/3sDgYh4NxNBYHcdrH4Tc8HOifL/E044hsmjgN0tj2Ko6DcfLE8EADcfmAg1w64IMXrcA0rNd5cN6Y3njrjnE4pvkHANP58iCNxQO+B3x11v84HA6c9+DO1ytWYBrW6zw1/6Df/FtZlz8vtYPLZ5iRv16BaVi//gjO3sD2zYb7F0mB30Q4aHBpfBqU68cjHPjl4iHNPy5oDljH4yBeLh7SxNN+Mr7cY+PFmpNtLf52/2suv9yx11TgF8ZOw/qFor/gkt7kKzrCJZox9xzf3GN3WIFpWK/xUN27hHbsuyIXyyBGZ/FAgzgrh7aO59PE5AQaiKfJ2WriNCiPPZabxsqBa8ebw9rAD9agmX+r0QcvVoFpWK/xwLzxvOFcGq87pof0OHtKE5MDLqpxwAMO4mksDfggjgMecBBPY2lsEKdBGouDOB5oEGdx4Ac8pLFpY1+sAtOwfuuBXb+uN/H1s9x2hm0zWH/8u+1KM9tbVmAa1ms8dj/SuEh2odyOXUSHtTGksadyjZETjuWm/e/BKc+4A/1g09iPw69j2kH+OHe8XHMF89GOjaeXx+LAD41nt5rcwYtVYBrWiz2wZbvehBoZ8IVYPNAgzuKw5vK32prLD8dy08xRHosDP5TLbrVtLg7lscbRWDzQIM7isObyaYMXrMA0rBd8aN9s2Y9lodQ4m/ZK1r7Duu80Np0f0n7ZzvK3qsA0rFtV8vHzeFP6r9+Bbwesy/lAgzgrh8YaC+t3I3SclRdoEGflbDU6TYwfaBBn5Ww1fN2nPB820ECcZiweaLDmyqGBcSunDV6sAtOwXuyBPWC73tTe9NulaNuLfhqsuY1nV13eOeONMRb4t4Q93HK+mevBFZiG9eCC33i5ay+S3efAui3fibjc3+o06625OH3VjKOZZ9V9aCB/1XC5q2YczTyrfq7vgt5YWMc076qN/2IVeIGG9WIVfdx2vSG9CaFVaRpDSI+zcuisxgDrHMXYFfLhO018m0eDrY6D2AoapNmjvUN7FcdDueLyQU762B1UYBrWDh7iHGEq8C4VmIa1vyfdJbTvNDqdi/Ww3g3JgfKe1TpT+2+/zpHGtne6HEgbu5MKTMPayYNcjuENC9sL7iXl765LaPi78MvOLZZ3dmc65/y3WG/meGAFpmE9sNhPuJQ7HhffT7i1i7fkTODy/eJJZuBzVmAa1nM+l2t21SW0S+fm4Qdv5lV/hR+dNNXt/p0jje1M6a9wrvY89swKTMM6s1AvnuZNHF7xKO092xnibNrYF6nAJduchnVJ1Z57jO8sQjt1aR3c8aS/inWe7f6dI43tLPSQNnYnFZiGtZMHuRzDhTOsl869gdkl9cOna7Bqz+g7i72H9hhnV00DU4O0sTupwDSsnTzIOcZU4B0qMA3rRZ/yiW27gAYX1aXxw3rf0wV9ec9qfeJ3bP9pbHv346NzqUHa2J1UYBrWTh7kcgwNKSR7E4e0V7LtnXU2e2fxQBvsvALTsHb+gD+P544nfEovZdo7u24cD6s+/k4rMA1rfw/WJTq4eO50/OANvtXjz2pdoLd/31HZp3OksTQQx1n89TEn+HsFpmH9vRRv6XjTw94O70w+Wdzbud7+PNOw9vcScLcDLqq/O52Lafgu75Xizu5M60X8K+1/9nqiAtOwThTnRUPerLD+SORTs+AN3dH4EH9W6zztv3PZdxrb3ukhbexOKrD/hrWTBzXHmApMBT4+pmHt71Xgwhn6TsQJXcIH9zs04AP/meE87b9z2Xca2/7pciBt7E4qMA1rJw9yOYY3LJxz6awRwDL85V1n96niOed/+cO+2wGmYb3bE//reXd21/PncJ3pnA8d/gyY316nAtOwXudZnbvTfzkkgovqg/vnix+8of+Ih9/SDu5Tf/nEr722fzaN7QDp8yNhFdmRnYa1o4d54ijexOFE2tOG2nu2jcbZtLE7rsA0rP09XN9ZhE7nniq440l/Fes82/07Rxr7KmeZfV5RgaVhXTHLDH2mCrhwhvXS2Zs7rHutEazaM/rO0v7Z9sgPac7kU8NpYlVkR3Ya1o4e5hzlLxWYS/e/lGMfZBrWPp7jeoouqNl0fljve3w3sl5Yl/9sVvM5tv80tj07kw8d2LSxO6nANKydPMjlGN6omhIk0wLt1dDe2c7F4uHVzjT7vaAC07AuKNoLDumeh33B7X/Yd/hYfqWxizzuXiswDWt/T9aFM6yXzvywvrnTnr0KPkRor76jsl/nSGNpII6z+GBHFZiGtaOHecFRvOnhgqFPPcSZfLL41Jt81Ob2tM40rD09zb+dxd0OuKj+m/L17y7c4euM14v4zsqZ1ov41zvF7PhoBaZhHS3LS4verOCN20F8ahY0s3Q+xJ/VOk/771z2ncauexeDVRt/BxWYhrWDhzhHmAq8SwWmYX3zpF8w7MIZ+k7EEVzCB/c7NOAD/5nhPO2/c9l3Gtv+6XIgbexOKjANaycPcjmGNyycc+msEcAy/OVdZ/ep4jnnf/nDvtsBpmG92xP/63nd88Bf1ddmzgPnfOjw2id9w91Pw9rfQ3cBDS6qOx0/eDNv9fizWp/4bffvHGlse0//+Y+EzTD2aSswDetpH81NN+ZNHG468YMma+/Zlo2zaWN3XIFpWPt7uL6zCJ0uzrrjSX+Utaa1gW9dFg+0r7Dm8strLJs2dscVmIa1v4frwhnWS2c8rCf26Rqs2j381mZrOCwO617pPghg24uckM6mseVqXs5kjrSxO6nA7RrWTgoyx3iaCmhIT7OZ2chzVGAa1nM8h1vuwgV1aN44u973uJyH8u5lfWJnbWh9Fg+tTXeJ7jultGPjxRrL4mCcM5kDH+yoAtOwdvQwP4/iDQve+J/SBx4+fuFXa7Pti8WBf2pbckK5bBp7avzEdlKBaVg7eZDfHMOPV+Gb1HPCP85pbbbB/BXpx+xXeV/px+YYbQcVmIa1g4e4OYILZ1gvnfnBm7wh8mDVil1jfcezzulSvPXFzC2eJk4DcTqLgzgN0tfxdHkgjrP4YEcVmIa1o4f5w6N4w/9wyFnp5tVgzkr+Iskc6yeHX6R9KV87/suJJ/C7FZiG9bv1v8fq7nbARfWp+eW4rIZTeT+NmdeFN/vTsfKNsyfAf4prx/90vb3nP9X5pmE91eO4yWY0C1h/JPKpWfCGbiE5sGrFrrHb+eyn9a1nbjZNnAbGirE4iJcrRhNPY2lAl8Pigx1VYBrWjh7mHGUqsPcKTMPa3xN24Qy+y+h0LtaD+x06Kwfwe8Ia9gTWtRaLgzjtK8hpoPtu7gAAEABJREFU/+Uan8Y2li4H0sbupALTsO77IH9jdm9YOOfS2uU4yL/3Xq0B6zo4nLPXddwp33zOdMs5T603sQdWYBrWA4s9Sz2kAu6u4LsPHR6ymVnkthWYhnXbej7DbC6gwUV1++EHb2Y6Kw/4tHvBj2fWgdZi29N3nwiKl2ucfbJpLA3SrYkPdlSBaVg7epgnjuJNHE6kPTzUnthTi4uvKPeYVuzhdha8fwWmYd2/xo9ewR0OrN9h8INYe+JD/FmtPR7bfxr7rHuffd2wAtOwbljMJ5nKJ2qwXjq7hA5tUxOQB/z0Z7TtnW2vLB7at+blU0PnShu7kwpMw9rJg5xjTAXeoQJP07DeodgPOqML6tCSx+56aC6rgV/uM1qf+NkjrPvDQ7rvsJxJDdLG7qQC07B28iCXY3jDgjdysjdwWHU+lPes1nnaP98+7TuNpQUxiI/dSQWmYe3kQX5zDPc94ZvUpwy3d3bdIB5WffydVmAa1v4erAtnWC+d+cEb3KlZecCnPQY/X8XFevvvOyx7TmObVRxn08bupALTsHbyIOcYf6mAZrZ+SvqX4JDXrcA0rNd9dl/t3N0NuKj+Kocux8U04HvBXs+1l+dz1TmmYV1Vvqcc7AIa1h+J/JWY4A3dxuXAqhV7Jus87d9+7c2e01ga0OWw+OBXK3Dbxadh3baeM9tUYCpwxwpMw7pjcR8wtbsaaCm+S/SQHmflpL+K9R2Ti3Ro/6zzhM4iJ8hJH7uDCkzDeu2H2Bvz0lNoBHDp+EeO03zCqXXLYU/lTewFKzAN66kf2rebc08D3yZ+kaBZXTP+i2lHngrcpwLTsO5T10fN6jIaWk/zwUN6nJWTzm457dmgsdo7tF8WD+05zspJH7uDCkzD2sFD3BzBmzQUirNpr2btPbT3OHtKKzb2xSswDet1H6A7Gt95AL+T4CFNPKTtwXZOtvPwgzNv9VUr9gx29nBGBaZhnVGkJ03xxvNXVoBvmyweaEC/9oLePM8EZ+qc63/Vnsa2Xw0MB+PSx75YBaZhvdgDm+1OBd65AtOwXvfpu7cJ6ynS2HTfYbiEhrQ9WH+tKHQe515Bx8vj0wYvWIG9NKwXLP3VW/bG04BAQzLhqtFpQQzir26dxbmB33mcO6SJywN++tgXq8A0rBd7YMt23cWERf5IYz/u+Mv8K1rqmFbsEfbY+se0R+xl1rhxBaZh3bigd5rOhfn2r6B4E9LBdw6WXjU67RZo3tYxZ5p1XGbTAA84GNf+jaMBH/iXwFhzs41vbTadxUF+uXScTRv7xBWYhvXED+fJtuZNvX4ad4vtmVMT+dFcS7Lxa7NcQme5144/a5FJul0FpmHdrpb3nMm/beXuBe65zqm5u7Q+lXMqZu+w5vjuZv2nYdbYOb753Fex5+Rvc6x/zfjtfMPvXIFpWHcu8I2m743lzdWUNG924NO9cfFAuwXMaw22+fDWWfeVxq65cmCdo/il1lywjrduKLbulb/ml7Nq4z9pBaZhPemDmW1NBaYCHx8fmyJMw9oU5AmoexXfBbBtpwtrNl2O+x9IK/8aay5Y57CGtcG6YiwO4jTAAw7iacbRrEGHNPq1MJc5oblop9Zfcxsz9gkrMA3r+R6KS2Twhv5ud3JCubg3aPyn1nhvYPanY3+abw245WW+ucwJ3+1HTvgud+JPUIFpWE/wEDZb6IJ9I59N3cnA2QM2ica6YGc3oaFTgd+twDSs363/sdV9d+Rymi2OhxqJ+FYr/285sZ9ZY829jtLAtmvJSRMvP41NE8fB/HQWB3HaLWAuc0LzrXu1Lp2VE2iDJ6/ANKwnf0Cf2/PmCp/SH5PG/hHu9Jv5V7TMJZoxp8YXu9SaP6xzpLHp/JA29okrMA3r+R6O7wZCu4uz7lzS+RC/hbVGaD5rpPHpbBpLA37AYc3lbzX5tHvBmtYAfuvgIU08jZ8+9gkqMA3rdx+CNwS0C74L95AeZ9PkuhwHfvq11hqhueJsa7E4uOg+lntMM47OGgvrePqtz2RO6wB/uz6dBvyAvwjeY5vTsH73OXvzwLFd+FHlmH5P7au93HPNY3PbBxyLjfbGFZiG9bsPvx891l1oVODTwnQ8rFoXxmLp11qX1qG57MUakMYP4sf0NPFy0+Ks+Kr7L9XVJu1aa43OxG8+fkizl2O5xcf+YgWmYf1i8Y8s7c1TE1rfsGmsnIbyIX6tNZd1Q/Ph1gY+XS4OaXQ84CCexqd9NV7s1rCWdYFvfrY9sTSQE/DBE1VgGtafh/FUv/lRKLSxOJt2L2uN0Bpx9pj2lX4q15gV5T7SHlv/mPbIPc1aJyowDetEce4c8qf4uX9dxCV08IZqa3yIX2vN1Tps87mExsG+6WuuOA3kBBzE04yjsWniNDA/ncVvAWtVa745WesEGsRZOTTg33JP5hz8sALTsH5YsCdL9yaCJ9vWVdvxiaEzsVdNdOPBmirceNqZ7icVmIb1k2rdNtcdSrh0Zn/iw6Xjn3GcS291YW+5P3PCpXO6iF/vui6dZ8ZdUYFpWFcU78qh3jzeAFDTofmELLREnJWTfmtrbmuE5rfHtPbKpomXm8amieNgHJ3FQZwGdJzFbwHnMifwzclaO9AgzsqhAR/4g1+qwDSsXyr8LDsVmAr8vALTsH5es0tGuJPxHQM0nu9iF8TpLB5oEGfl0G453lzmNLc1Ag3E0+RsNXEalMfiII7DT8Yfy01jzResA3FWDu3Y+mJygjyIs3Jo63g+bfALFfhpw/qFLe5iSZe1sF4k870hQgeNs6c0MTkBhziLAz/gIc1etppYmjge0uPiW00sTRwP6XHxrSaWJo6H9Dh7ShOTE3CIszjwAx7S7CVt7IMrMA3rwQWf5aYCU4HLKzAN6/La/WSky16XuGzj+tSJ1mUui4dy46wcuh9NcEhj8SAP4qwc2jreXmhicgINxNPk0I6Np5fH4nDp+NY6Nl7MGsE6EGfl0Na9prFygjyIs3Jo63h7oQ1+oQLTsH6h6J9LejOs+JQ/ztU+Dr/OzT2Wdxj+cUz/u/bxj1+rxi/CD+dq8s/NPZZ3yXjzGBdwiLM48AMe0ti0sQ+uwDSsxxTcn9DBXYhV2a1GT2Nx4AfjaOxWo6exOPCDcTQ2jaUBP+Cw5vK3mnwa8AMOxqTxaZDG4sAP5bJbbZuLQ3mscTQWBz4N8IBDnC2XxYM8iLP44M4VmIZ15wJ/Tu/CPXxKH3HWG4LO4oEGcRaHNZe/1dZcfpAHxqR1kbxqYvKAH+TQ2LTG09NYOV9p3uRy4KvxxoKc0JxsGisP+AGHNZe/1eTTgB9wMCbtu73KH9ypAtOw7lTYN53WG/tNj/7ix36R7U/DesyDcu+xwqr+6kkaHtLYn2ryjQs4xFkc+MFeaJDG4iCOAw78IL7VitHFV06Ls+I0wAMO4luNnsbiwA84xFk84OFczV7KdQEf0sbesQLTsO5Y3GVqnziFZD8SpfHp3jxpLA34QQ6NTbv3ePOfWkvcnqA8FgdxHPi0Y/unywlyaMak8WliaSwN+EEOjU271XjzmivggztXYBrWnQv8Ob0flcKn9BHPfnz+irOf0gc/fCy/0thkfjiliZXH4sAPOMSzNIizOPADDvEsDeIsDvyAQzxLgziLAz/gIY39qSbfuIBDnMUHd67ANKxbFPgfc3jh9u8u+ZO3iL/mEeTQXeJuNbE0Vh7wgxya+beaWBorD/hBDm0dby80sfJYGojjIId2bDxdTsDh0vGtdWy8WOuw1gF+kENb95rGlsfKA36QQ1vH2wtNrDyWFsTyx96wAtOwbljMmWoq8FkBDUyT+6RjblWBaVi3quQ/5nFfEv6hjvdOFfC3GrwG3unMDznrNKzbltmLtMtdfrN7AYd0eWn9aSyWxp4ab4wc4Mu9dLy9nBovbh1oLRYHceMBDziIpxlHY9PEaZDGOg9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4P/y8fFhLzSxNJa2Qnzl49+gAtOwblDEmWIqMBV4TAWmYV1XZ5er0Cz+JHZ/Afx0PJQvvtXE0thHjbcXa321vrj9gBy5q8angZyAg3jaT8Yfy01jm5O1DvCDHNqx9cXKY+UBP8ihreP5NLHyWBqI4yCHNrhRBaZhXV5IL0Yvyj41aiY6rH+FAw/liaex6fxwShMrj8WBH3CIs3jAwV62Gj1NHA/pcfGtJpYmjof0uPhWE0sTx0N6nD2lickJOMRZHPgBD2n2stXE0sRxSBt7owo8uGHdaNfPM417ivW/fH6enc1OpgI7rMA0rMsfqmblAtaPAM1C669qsOn8IIeu0W01epq5cUhjG8/iwJcHOPxkvHxjgR9wOLZXa5bHygN+wOHS8db4ajy9dVgc+KHx7Fbb5uJQHmscjcUDDeIsDny1B+NogxtVYBrWjQr5OY0XqAYG/E/5Aw8fn7/ibLksDvzP1A88fHz+Ek/jk9mtRk9jcTiWu2prLj/I+Wo8vTwWB364x3hzWwf4AQdrpvG3mhgN+AEHY9L4W02MBuIBH9ywAtOwLi+mOwovVOCbicUDDeKsHBqLA58GeMAhzpbL4sCXB3jAIc6Wy+JBHsRZHNZc/lZbc/kA8sAYHPhbjU4DfjiWm7bNxaGxbLksDnx5gAcc4my5LB7kQZzFYc3lb7U1V2zwgwpMw/pBsTapLtvD+sJMc/nakDT2mHZs/Fe5jTdGDvDpLB5oEGdxWHPb66qtufwg56vx9PJYHPjhHuPNbR3gBxysmcbfamI04AccjEm7Za3MPfhBBaZh/aBYkzoVmAr8bgWmYV1efxfJ27uKOCve7HhIE99qYmksDvyAQ5zFAx7O1ezlVK74qTnFHz3eeu2JxYEfcIizeMDDudotz9qaL28fdYBpWJdX2l2ET4KAbyYvfhzS6HiQQxNP49PE0lga8IMcGpt27/HmP7WWuD1BeSwO4jjwacf2T5cT5NCMSePTxNJYGvCDHBqbdu/x5j+1lrg9DS6owDSsC4r2OcS9xopP+eMSzZiPz1/88Cl9xNmP5RcekuPsKU1MTsAhzuLAX0GDSzRjjAV+wCHO4sBfQYNztZ/kHpvz0vHmMhb4AR9cUIFpWOcVzZ+K/qt2thEuYWnghUgXx0GcBngoV3yriaWxxgI/yKGta6Wx5bHygB/k0Nbx9kITK4+lgTgOcmjHxtPlBBwuHd9ax8aLtQ5rHeAHObR1r2lseaw84Ac5tHW8vdDEymNpII6DHNqx8fTBDyswDeu8gvlkyIuPPW/ED7Im9a0r4B98fOsC/OTw07DOq5aLVvcg7HkjJmsqcF4Fjv3TNOeNfMOsaVjnPXTf0rtIZRuBe7FBOouDeLl40Pjo4mnG0cTSWBrwgxyaMWl8mlgaSwN+kEMzJs1eaGJpLA3EcTCOxuIgTgM84CCeZhyNTROnQRprPzRxHIyjieGBBnFWDs0YHPg0MTzQIM7KoRmDg73QxPBAA/E042hsmjhtcEEFpmFdUFjYef8AAA5ZSURBVLQZMhW4uAIz8KoKTMP65/K5q4I14gI1FPOn5ilNvDnKY0+NF5MTHjW+vX61vnh7kmNfq8anQXksDuI4/GT8sdw01nzBOhBn5dCOrS8mJ8iDOCuHto7n08TkBBqIp8nZauI0KI/FB99UYBrWPxfIiwd6scngBxxcwKexNOCDOA54wEE8jaUBP+AQZ/GAh59q8htrLziksTiI44EGcXEc0lgcxPFAg7g4DmksDuJ4oEGcxYEf8JDG/lSTbxzYCw54wEE8jaUBH8RxwAM++KYC07C+KdCEpwJTgeepwGs1rMfUrctRl6qt6N84Cuk+MdxqYmnsT8fLNw7Wy1k8WEMeu9XoaSwO/GAcjU1jacAPOFx6VmPh0vH2+NV4evtkceCD+jWepQFfHuABhzhbLosHeRBncfjJWe0xGDv4pgLTsL4p0GfYvUP4lD7irBf0x+EXiwP/IP35wsMf4fBbnC2XxYF/SPvzhYc/wuE38TT+Qfpg09iPz1/88Cl9rLn8j8Mvtjz2IP354gc5RHar0dNYHPjBOBq71ehpLA78YByNTWNpwAdxHPg04G81Og34AQdj0vhbTYwG/HAsN00uP+CDbyowDeuvBXKf0IuNLcoPcujsVqOnsTjwg3E0dqvR01gc+ME4GrvV6GksDvxgHI1NY2nADzisufytJp8G/ICDMWl8GqSxOPBDuexW2+biUB5rHI3FgU8DPOAgnsbfamI04AccjEnjbzUxGvADDsYEfLBUYBrWUoyD64Xir1bAejmKh0Pan684axzRiw+HS8abx9hgToizOKy5/K225vKDPDAmrb2umpg84Ac5NDat8fQ0Fgd+MI72Ta0+5MsDfmg8m8bKA37AYc3lbzX5NOAHHIxJ66yrJiYP+EEOjU1rPD2NxUGuD30AHywVmIa1FONM17fwZ6ZO2gtWQMN4wW2/x5anYf31OWtGweVp0TQ2TRyHNH4QP6aniZebxqaxOPADDnEWD3g4V7OXU7nip+YUf/R467UnFgd+wCHO4gEP52r3Pqv9uMSH9jT2swLTsD4L8Wm8WPrUxo8sn/Kf/z15epp4Gp9+zng5co05NV5MHvBD49k0c8lbNTEa8IMcGpv23XjxU7ni5oTyWBzEceDTjq1PlxPk0IxJ49PE0lga8IMcGpt27/HmP7WWuD1BeSwO9ioH8HfA2WechvXPpfIjQSgaZ49pX+nHco9pl4w3j3EBhziLAz/gIY09V/tJ7rE5f2O8fVg34BBnceAHPKSx52o/yT025zq++Fvbd29Y/hSDXgR8l52wXoTioVzxtF5Y54wv99h4seZkW4sf5NDXtdLY8lh5wA9yaOt4e6GJlcfSQBwHObRj4+lyAg6Xjm+tY+PFWoe1DvCDHNq61zS2PFYeHFtrHS8u79rx5rBuwMH8adagDT4r8M4Ny4vBi2P91OazLGOmAlOBZ6zAOzcsz8PFJvBfFbPv21bAH2S3nXFmu1kF3rlhdbnJVlDf+vdXc9aL0DS2XHEcjKOzOIjTAA+tJ55mnDyxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaZDG2g9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4GAvNDE80EA8zTgamyZOgzQWB3EcjKMNPivwzg3rswRjpgJTgVepwDs3LH96bS83V43fcyyPTRPHoR8jVo1frpxwLDeNLY991Pj2+tX64vYDcuxr1fg0kBNwEE/7yfhjuWlsc7LWAX6QQzu2vlh5rDw4lrtqfHnXjjeHdQMO5k+zBg3o/3lwVu1A3+vrnRuWy3YPP/Tk4+JbTSxNHA/pcfGtJpYmjof0OHtKE5MTcIizOPADHtLsZauJpYnjIT0uvtXE0sTxkB4X32piaeJ4SI+zpzQxOQGHOIvDuhYe5ID4VqOnieMhPS6+1cTSxPGQ7gMioKe9nX3nhvV2D3sOfFYF3rohnFWhX0x654blr1j4hBBcoHoMLB5oEGdxuHS8Nb4aT7dGwCHONp7FgS8P8IBDnC2XxYM8iLM4XHpWY+HS8fb41Xi6PQYc4i6vG8+m8+VBGosDP5TLprHygB9wuPSsxsKx8XSX8OBHQ/wt8VYNa/OEPfjgBSnMbjV6GosDPxhHY7caPY3FgR+Mo7FpLA34AYc1l7/V5NOAH3AwJo2/1cRowA/HctO2uTg0li2XxYEvD/CAQ5wtl8WDPIiL48Df6qsmJg/4AYc1l7/V5NOAH47lpm1zcWgsu+aKvT3epWH5Nj/00HEvCuDTWTzQIM7KobE48LcanQb8cCw3bZuLQ2PZclkc+PIADzjE2XJZPMiDOIvDmsvfamsuP8gDY9L4W02MBvxwLDdtm4tDY9lyWRz48gAPOIin8beaGA34AQdj0vhbTYwG/ICDMWn8rSZGe0u8S8PqUxe2B+0CM6wvjDSXn8dyj2n3GG8fx9ZKs6Yc4NNZPNAgzuKw5nbWVVtz+UHOV+Pp5bE48MM9xpvbOsAPOFgzjb/VxGjgNYIDDsbg8Ey1sre3wrs0rLd6qHPYj4+PKcIuK/AuDauLUbYH6XLTHQGk8YP4MT1NvNy0OCt+TE8TlwdpLB5wiLM48AMe0thzNXs5lStuPjiWJ35MTxM3FtL4QfyYniZebhqbxuLADzjEWTzg4VzNXk7lip+aU/xW45vnbey7NCw/94ceLu6TJODTvdBwSKPjQQ5NPI1PE9tq9DRWDs0YHPg0MTzQIM7KobE43Hu8+a0D/K/Wp8sJOBiTxqcd2z+9PFYOzRgc+DQxPNAgzsqhsTjce7z5rQP8r9anywk4GJPGpx3bP/3t8C4N6+0e7Bx4KrDHChxvWPs7qYtU6E8sJ8T/7+BAOouD+CH85wsPLmCJ4mnG0dg0cRqksafGi8kJxkKclUNb1+LTxOQEGsRZOTRjcGivYniQB+JpxtHYNHEapLE4iONgHI3FQZwGeLAfmniacTSxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaW+Jd2lYXlzQJzxv+bDn0FOBV6/AuzQsdwCwXni++rOb/U8F3q4C79KwtpeYHjTNX3UA33LTWBzEaYAHjY8mnmYcjU0Tp0Eae2q8mJxgLMRZObR1LT5NTE6gQZyVQzPmXz4+PmjtVQwP8kA8zTgamyZOgzQWB3EcjKOxOIjTAA/2QxNPM44mlsbSgB/k0IxJ49PE0lga8IMcmjFp9kITS2NpII6DcTQWB3Ea4AEH8TTjaGyaOO0t8S4N6y0f7hx6KrC3Crxzw/KnlgtMcL/l2a4anwZywrHcNLa8a8ebx9rAD9agmX+riaWx8oAf5NDW8XyaWHksDcRxkLPVxGkgJ+AgnvaT8cdy09jmZK0D/CCHdmx9sfJYecAPcmjreD5NrDyWBuI4yNlq4jSQE3AQT2s8nQ/8t8U7NywX8F4AsL4AcBBPx0OaeBpLZ4M4DdJYHMTxQIM4iwM/4CGN/akm3ziwFxzwgIN4GksDPojjgAccxNNYGvBBHAc84CCextKAH3CIs3jAw081+Y21FxzSWBzE8UCDuDgOaSwO4niggb8WpJHR8Uvw8mPeuWG9/MObA7xVBXxg5N7srQ69Pew7Nyx/TccFJvRCYOmhesVZOXQvIBzSWDzIgzgrh3ZsPF1OwCHONp7FgS8PcHAuHPBQLpvGygN+wOHYXh8x3hpfrU9vnywO/NB4dqttc3EojzWOxuKBBnEWh3vUyrx+VPRM7QV/S7xzw/LgQw8f98IAfjoejmnlsuXxj+Ue08plG88ey01bc/l01jjg0wAPOIin8beaGA344Vhu2jYXh8ay5bI48OUBHnCIs+WyeJAHcRaHNZe/1dZcfpAHxqTxt5oYDfjhWG7aNheHxrJrrtjb450b1rGH735gRTlePEGczp7SxOQBPxhHY7caPY3FgR+Mo7FbjZ7G4sAPxtHYNJYG/IDDmsvfavJpwA84GJPG32piNOCHY7lp21wcGsuWy+LAlwd4wCHOlsviQR7EWRzWXP5WW3P5QR4YE/DBUoFpWEsxDq4XiotNcMl5kP588cMf4fBbnDXuIH2wOLg8/fj8hYdP6SPOGkdn8UCDOIvDmsvfamsuP8gDY9La66qJyQN+kENj0xpPT2Nx4AfjaGzatePNY07gBxzWtfhbTT4N+AEHY9La66qJyQN+kENj0xpPT2NxkOv1B3za4LMC07A+CzFmKjAVeP4KTMP66zNyZxBcnhZNY9PEcUjjB/Fjepp4uWlsGosDP+AQZ/GAh3M1ezmVK35qTvFHj7dee2Jx4Acc4iwe8PAX7UDoB/Pnix/ufVbruMQH/p8NzG9/q8A0rL/Vod+9QHwSA+4W0vEghy6exqeJbTV6GiuHZgwOfJoYHmgQZ+XQWBzuPd781gH+V+vT5QQcjEnj047tn14eK4dmDA58mhgeaBBn5dBYHO493vzWAf5X69PlBBzs1TjAB0sFpmEtxRh3KjAVeO4KTMN67ufzTLv7yQXwT3Kf6YyzlyevwF0a1pOfebZ3ugKajX8sbpvlkyyxVceP/ejiE641b/ypwE0qMA3rJmXc1STuUPxTJttDuWsRW3X8WMM6Nn4dN/5U4KIKTMO6qGwzaCowFfiNCkzD+o2q72nNOctU4IEVmIb1wGLPUlOBqcB1FZiGdV39ZvRUYCrwwApMw3pgsWepqcBrV+D3dz8N6/efwexgKjAVOLMC07DOLNSkTQWmAr9fgWlYv/8MZgdTganAmRWYhnVmoa5PmxmmAlOBayswDevaCs74qcBU4GEVmIb1sFLPQlOBqcC1FZiGdW0FZ/xU4J8rMMqdKjAN606FnWmnAlOB21dgGtbtazozTgWmAneqwDSsOxV2pp0KTAVuX4H/DwAA//9sB2hHAAAABklEQVQDAB9QlitZA9bLAAAAAElFTkSuQmCC",width:"248",height:"248",style:{mixBlendMode:"multiply"}})})})}var Rt=b(W()),Wh="ai",Yh="ai-wp-admin",ia="ai/ai",Uh="https://wordpress.org/plugins/ai/",aa=Object.values(ra()),Gh=aa.some(e=>e.type==="ai_provider"),Df=[];for(let e of aa)e.type==="ai_provider"&&e.authentication.method==="api_key"&&Df.push(e.authentication.settingName);function jf(){let[e,t]=(0,Et.useState)(!1),[o,n]=(0,Et.useState)(!1),r=(0,Et.useRef)(null);(0,Et.useEffect)(()=>{o&&r.current?.focus()},[o]);let i=(0,Et.useRef)(aa.some(R=>R.type==="ai_provider"&&R.authentication.method==="api_key"&&R.authentication.isConnected)).current,{pluginStatus:s,canInstallPlugins:a,canManagePlugins:l,hasConnectedProvider:c}=(0,un.useSelect)(R=>{let x=R(sa.store),S=!!x.canUser("create",{kind:"root",name:"plugin"}),E=x.getEntityRecord("root","site"),T=i||Df.some(H=>!!E?.[H]),P=x.getEntityRecord("root","plugin",ia);return x.hasFinishedResolution("getEntityRecord",["root","plugin",ia])?P?{pluginStatus:P.status==="active"?"active":"inactive",canInstallPlugins:S,canManagePlugins:!0,hasConnectedProvider:T}:{pluginStatus:"not-installed",canInstallPlugins:S,canManagePlugins:S,hasConnectedProvider:T}:{pluginStatus:"checking",canInstallPlugins:S,canManagePlugins:void 0,hasConnectedProvider:T}},[]),{saveEntityRecord:d}=(0,un.useDispatch)(sa.store),{createSuccessNotice:m,createErrorNotice:u}=(0,un.useDispatch)(Hf.store),f=async()=>{t(!0);try{await d("root","plugin",{slug:Wh,status:"active"},{throwOnError:!0}),n(!0),m((0,Qe.__)("AI plugin installed and activated successfully."),{id:"ai-plugin-install-success",type:"snackbar"})}catch{u((0,Qe.__)("Failed to install the AI plugin."),{id:"ai-plugin-install-error",type:"snackbar"})}finally{t(!1)}},p=async()=>{t(!0);try{await d("root","plugin",{plugin:ia,status:"active"},{throwOnError:!0}),n(!0),m((0,Qe.__)("AI plugin activated successfully."),{id:"ai-plugin-activate-success",type:"snackbar"})}catch{u((0,Qe.__)("Failed to activate the AI plugin."),{id:"ai-plugin-activate-error",type:"snackbar"})}finally{t(!1)}};if(!Gh||s==="checking"||s==="active"&&i&&!o||s==="inactive"&&l===!1)return null;let g=s==="active"&&!c,h=s==="active"&&c&&(!i||o),y=s==="not-installed"||s==="inactive",_=s==="not-installed"&&a===!1,v=()=>h?(0,Qe.__)("The AI plugin is ready to use. You can use it to generate featured images, alt text, titles, excerpts and more. Learn more"):g?(0,Qe.__)("The AI plugin is installed. Connect an AI provider below to generate featured images, alt text, titles, excerpts, and more. Learn more"):(0,Qe.__)("The AI plugin can use your AI connectors to generate featured images, alt text, titles, excerpts and more. Learn more"),w=()=>s==="not-installed"?{label:e?(0,Qe.__)("Installing\u2026"):(0,Qe.__)("Install the AI plugin"),disabled:e,onClick:e?void 0:f}:{label:e?(0,Qe.__)("Activating\u2026"):(0,Qe.__)("Activate the AI plugin"),disabled:e,onClick:e?void 0:p};return(0,Rt.jsxs)("div",{className:"ai-plugin-callout",children:[(0,Rt.jsxs)("div",{className:"ai-plugin-callout__content",children:[(0,Rt.jsx)("p",{children:(0,Et.createInterpolateElement)(v(),{strong:(0,Rt.jsx)("strong",{}),a:(0,Rt.jsx)(dn.ExternalLink,{href:Uh})})}),!_&&(y?(0,Rt.jsx)(dn.Button,{variant:"primary",size:"compact",isBusy:e,disabled:w().disabled,accessibleWhenDisabled:!0,onClick:w().onClick,children:w().label}):(0,Rt.jsx)(dn.Button,{ref:r,variant:"secondary",size:"compact",href:(0,zf.addQueryArgs)("options-general.php",{page:Yh}),children:(0,Qe.__)("Control features in the AI plugin")}))]}),(0,Rt.jsx)(Bf,{})]})}var Re=b(W()),{store:Xh}=Lo(Kh);Mf();function qh(){let e=Nf(),{connectors:t,canInstallPlugins:o,isAiPluginInstalled:n}=(0,Ff.useSelect)(c=>{let d=c(Wf.store),m=d.getEntityRecord("root","plugin","ai/ai");return{connectors:Lo(c(Xh)).getConnectors(),canInstallPlugins:d.canUser("create",{kind:"root",name:"plugin"}),isAiPluginInstalled:!!m}},[]),r=t.filter(c=>c.render),i=Array.from(new Set(t.filter(c=>c.type==="ai_provider").map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c))).sort(),s=new Set(t.filter(c=>c.plugin?.isInstalled).map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c));n&&s.add("ai");let a=["ai",...i].filter(c=>!s.has(c)),l=r.length===0;return(0,Re.jsx)($s,{title:(0,At.__)("Connectors"),subTitle:(0,At.__)("All of your API keys and credentials are stored here and shared across plugins. Configure once and use everywhere."),children:(0,Re.jsxs)("div",{className:`connectors-page${l?" connectors-page--empty":""}`,children:[a.length>0&&(e||!o)&&(0,Re.jsx)(nn.Root,{intent:"info",className:"connectors-page__file-mods-notice",children:(0,Re.jsx)(nn.Description,{children:e?(0,At.__)("Plugins cannot be installed here due to your site configuration. Install them manually using your normal deployment workflow."):(0,At.__)("You do not have permission to install plugins. Please ask a site administrator to install them for you.")})}),l?(0,Re.jsxs)(ut.__experimentalVStack,{alignment:"center",spacing:3,style:{maxWidth:480},children:[(0,Re.jsxs)(ut.__experimentalVStack,{alignment:"center",spacing:2,children:[(0,Re.jsx)(ut.__experimentalHeading,{level:2,size:15,children:(0,At.__)("No connectors yet")}),(0,Re.jsx)(ut.__experimentalText,{size:12,children:(0,At.__)("Connectors appear here when you install plugins that use external services. Each plugin registers the API keys it needs, and you manage them all in one place.")})]}),(0,Re.jsx)(ut.Button,{variant:"secondary",href:"plugin-install.php",__next40pxDefaultSize:!0,children:(0,At.__)("Learn more")})]}):(0,Re.jsxs)(ut.__experimentalVStack,{spacing:3,children:[(0,Re.jsx)(jf,{}),(0,Re.jsx)(ut.__experimentalVStack,{spacing:3,role:"list",children:t.map(c=>c.render?(0,Re.jsx)(c.render,{slug:c.slug,name:c.name,description:c.description,type:c.type,logo:c.logo,authentication:c.authentication,plugin:c.plugin},c.slug):null)})]}),o&&!e&&(0,Re.jsx)("p",{children:(0,Vf.createInterpolateElement)((0,At.__)("If the connector you need is not listed, search the plugin directory to see if a connector is available."),{a:(0,Re.jsx)("a",{href:"plugin-install.php?s=connector&tab=search&type=tag"})})})]})})}function Zh(){return(0,Re.jsx)(qh,{})}var Qh=Zh;export{Qh as stage}; +var Zf=Object.create;var Lr=Object.defineProperty;var Qf=Object.getOwnPropertyDescriptor;var Jf=Object.getOwnPropertyNames;var $f=Object.getPrototypeOf,ep=Object.prototype.hasOwnProperty;var ke=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Mt=(e,t)=>{for(var o in t)Lr(e,o,{get:t[o],enumerable:!0})},tp=(e,t,o,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Jf(t))!ep.call(e,r)&&r!==o&&Lr(e,r,{get:()=>t[r],enumerable:!(n=Qf(t,r))||n.enumerable});return e};var b=(e,t,o)=>(o=e!=null?Zf($f(e)):{},tp(t||!e||!e.__esModule?Lr(o,"default",{value:e,enumerable:!0}):o,e));var st=ke(($h,da)=>{da.exports=window.wp.i18n});var ce=ke((t0,fa)=>{fa.exports=window.wp.element});var z=ke((o0,pa)=>{pa.exports=window.React});var W=ke((l0,ha)=>{ha.exports=window.ReactJSXRuntime});var Ht=ke((bw,Ua)=>{Ua.exports=window.ReactDOM});var Gc=ke(Uc=>{"use strict";var xo=z();function ng(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var rg=typeof Object.is=="function"?Object.is:ng,ig=xo.useState,sg=xo.useEffect,ag=xo.useLayoutEffect,cg=xo.useDebugValue;function lg(e,t){var o=t(),n=ig({inst:{value:o,getSnapshot:t}}),r=n[0].inst,i=n[1];return ag(function(){r.value=o,r.getSnapshot=t,hi(r)&&i({inst:r})},[e,o,t]),sg(function(){return hi(r)&&i({inst:r}),e(function(){hi(r)&&i({inst:r})})},[e]),cg(o),o}function hi(e){var t=e.getSnapshot;e=e.value;try{var o=t();return!rg(e,o)}catch{return!0}}function dg(e,t){return t()}var ug=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?dg:lg;Uc.useSyncExternalStore=xo.useSyncExternalStore!==void 0?xo.useSyncExternalStore:ug});var Kn=ke((av,Kc)=>{"use strict";Kc.exports=Gc()});var qc=ke(Xc=>{"use strict";var Xn=z(),fg=Kn();function pg(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var mg=typeof Object.is=="function"?Object.is:pg,gg=fg.useSyncExternalStore,bg=Xn.useRef,hg=Xn.useEffect,wg=Xn.useMemo,vg=Xn.useDebugValue;Xc.useSyncExternalStoreWithSelector=function(e,t,o,n,r){var i=bg(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=wg(function(){function l(f){if(!c){if(c=!0,d=f,f=n(f),r!==void 0&&s.hasValue){var p=s.value;if(r(p,f))return m=p}return m=f}if(p=m,mg(d,f))return p;var g=n(f);return r!==void 0&&r(p,g)?(d=f,p):(d=f,m=g)}var c=!1,d,m,u=o===void 0?null:o;return[function(){return l(t())},u===null?void 0:function(){return l(u())}]},[t,o,n,r]);var a=gg(e,i[0],i[1]);return hg(function(){s.hasValue=!0,s.value=a},[a]),vg(a),a}});var Qc=ke((lv,Zc)=>{"use strict";Zc.exports=qc()});var Gd=ke((I4,Ud)=>{Ud.exports=window.wp.theme});var Ji=ke((L4,Kd)=>{Kd.exports=window.wp.privateApis});var ao=ke((a5,au)=>{au.exports=window.wp.primitives});var an=ke((U3,lf)=>{lf.exports=window.wp.components});var ln=ke((i8,hf)=>{hf.exports=window.wp.data});var Tr=ke((s8,wf)=>{wf.exports=window.wp.coreData});var ea=ke((l8,_f)=>{_f.exports=window.wp.notices});var xf=ke((d8,yf)=>{yf.exports=window.wp.url});function ua(e){var t,o,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var r=e.length;for(t=0;te();function Y(e){let t=Te(ip).current;return t.next=e,rp(t.effect),t.trampoline}function ip(){let e={next:void 0,callback:sp,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function sp(){}var ba=b(z(),1),ap=()=>{},F=typeof document<"u"?ba.useLayoutEffect:ap;function cp(e,t){return function(n,...r){let i=new URL(e);return i.searchParams.set("code",n.toString()),r.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${n}; visit ${i} for the full message.`}}var lp=cp("https://base-ui.com/production-error","Base UI"),De=lp;var qt=b(z(),1);function Br(e,t,o,n){let r=Te(va).current;return dp(r,e,t,o,n)&&_a(r,[e,t,o,n]),r.callback}function wa(e){let t=Te(va).current;return up(t,e)&&_a(t,e),t.callback}function va(){return{callback:null,cleanup:null,refs:[]}}function dp(e,t,o,n,r){return e.refs[0]!==t||e.refs[1]!==o||e.refs[2]!==n||e.refs[3]!==r}function up(e,t){return e.refs.length!==t.length||e.refs.some((o,n)=>o!==t[n])}function _a(e,t){if(e.refs=t,t.every(o=>o==null)){e.callback=null;return}e.callback=o=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),o!=null){let n=Array(t.length).fill(null);for(let r=0;r{for(let r=0;r=e}function Hr(e){if(!xa.isValidElement(e))return null;let t=e,o=t.props;return(po(19)?o?.ref:t.ref)??null}function zo(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function Ge(){}var Sa=Object.freeze([]),me=Object.freeze({});function Ra(e,t){let o={};for(let n in e){let r=e[n];if(t?.hasOwnProperty(n)){let i=t[n](r);i!=null&&Object.assign(o,i);continue}r===!0?o[`data-${n.toLowerCase()}`]="":r&&(o[`data-${n.toLowerCase()}`]=r.toString())}return o}function Ea(e,t){return typeof e=="function"?e(t):e}function ka(e,t){return typeof e=="function"?e(t):e}var zr={};function ve(e,t,o,n,r){if(!o&&!n&&!r&&!e)return xn(t);let i=xn(e);return t&&(i=Do(i,t)),o&&(i=Do(i,o)),n&&(i=Do(i,n)),r&&(i=Do(i,r)),i}function Ta(e){if(e.length===0)return zr;if(e.length===1)return xn(e[0]);let t=xn(e[0]);for(let o=1;o=65&&r<=90&&(typeof t=="function"||typeof t>"u")}function Dr(e){return typeof e=="function"}function Ca(e,t){return Dr(e)?e(t):e??zr}function gp(e,t){return t?e?(...o)=>{let n=o[0];if(Oa(n)){let i=n;jo(i);let s=t(...o);return i.baseUIHandlerPrevented||e?.(...o),s}let r=t(...o);return e?.(...o),r}:Aa(t):e}function Aa(e){return e&&((...t)=>{let o=t[0];return Oa(o)&&jo(o),e(...t)})}function jo(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function jr(e,t){return t?e?t+" "+e:t:e}function Oa(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var Fr=b(z(),1);function Oe(e,t,o={}){let n=t.render,r=bp(t,o);if(o.enabled===!1)return null;let i=o.state??me;return vp(e,n,r,i)}function bp(e,t={}){let{className:o,style:n,render:r}=e,{state:i=me,ref:s,props:a,stateAttributesMapping:l,enabled:c=!0}=t,d=c?Ea(o,i):void 0,m=c?ka(n,i):void 0,u=c?Ra(i,l):me,f=c&&a?hp(a):void 0,p=c?zo(u,f)??{}:me;return typeof document<"u"&&(c?Array.isArray(s)?p.ref=wa([p.ref,Hr(r),...s]):p.ref=Br(p.ref,Hr(r),s):Br(null,null)),c?(d!==void 0&&(p.className=jr(p.className,d)),m!==void 0&&(p.style=zo(p.style,m)),p):me}function hp(e){return Array.isArray(e)?Ta(e):ve(void 0,e)}var wp=Symbol.for("react.lazy");function vp(e,t,o,n){if(t){if(typeof t=="function")return t(o,n);let r=ve(o,t.props);r.ref=o.ref;let i=t;return i?.$$typeof===wp&&(i=qt.Children.toArray(t)[0]),qt.cloneElement(i,r)}if(e&&typeof e=="string")return _p(e,o);throw new Error(De(8))}function _p(e,t){return e==="button"?(0,Fr.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,Fr.createElement)("img",{alt:"",...t,key:t.key}):qt.createElement(e,t)}var Sn=b(z(),1);var Na=0;function yp(e,t="mui"){let[o,n]=Sn.useState(e),r=e||o;return Sn.useEffect(()=>{o==null&&(Na+=1,n(`${t}-${Na}`))},[o,t]),r}var Ia=Ho.useId;function mo(e,t){if(Ia!==void 0){let o=Ia();return e??(t?`${t}-${o}`:o)}return yp(e,t)}function La(e){return mo(e,"base-ui")}var G={};Mt(G,{cancelOpen:()=>qp,chipRemovePress:()=>Op,clearPress:()=>Ap,closePress:()=>Pp,closeWatcher:()=>Vp,decrementPress:()=>Lp,disabled:()=>Qp,drag:()=>Gp,escapeKey:()=>Fp,focusOut:()=>jp,imperativeAction:()=>em,incrementPress:()=>Ip,initial:()=>$p,inputBlur:()=>Hp,inputChange:()=>Mp,inputClear:()=>Bp,inputPaste:()=>zp,inputPress:()=>Dp,itemPress:()=>Tp,keyboard:()=>Yp,linkPress:()=>Cp,listNavigation:()=>Wp,missing:()=>Jp,none:()=>xp,outsidePress:()=>kp,pointer:()=>Up,scrub:()=>Xp,siblingOpen:()=>Zp,swipe:()=>tm,trackPress:()=>Np,triggerFocus:()=>Ep,triggerHover:()=>Rp,triggerPress:()=>Sp,wheel:()=>Kp,windowResize:()=>om});var xp="none",Sp="trigger-press",Rp="trigger-hover",Ep="trigger-focus",kp="outside-press",Tp="item-press",Pp="close-press",Cp="link-press",Ap="clear-press",Op="chip-remove-press",Np="track-press",Ip="increment-press",Lp="decrement-press",Mp="input-change",Bp="input-clear",Hp="input-blur",zp="input-paste",Dp="input-press",jp="focus-out",Fp="escape-key",Vp="close-watcher",Wp="list-navigation",Yp="keyboard",Up="pointer",Gp="drag",Kp="wheel",Xp="scrub",qp="cancel-open",Zp="sibling-open",Qp="disabled",Jp="missing",$p="initial",em="imperative-action",tm="swipe",om="window-resize";function ee(e,t,o,n){let r=!1,i=!1,s=n??me;return{reason:e,event:t??new Event("base-ui"),cancel(){r=!0},allowPropagation(){i=!0},get isCanceled(){return r},get isPropagationAllowed(){return i},trigger:o,...s}}var Wr=b(z(),1);var Ma=b(z(),1);function go(e){Ma.useEffect(e,Sa)}var Rn=null,Y0=globalThis.requestAnimationFrame,Vr=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let o=this.callbacks,n=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,n>0)for(let r=0;r=this.callbacks.length||(this.callbacks[o]=null,this.callbacksCount-=1)}},En=new Vr;var gt=class e{static create(){return new e}static request(t){return En.request(t)}static cancel(t){return En.cancel(t)}currentId=Rn;request(t){this.cancel(),this.currentId=En.request(()=>{this.currentId=Rn,t()})}cancel=()=>{this.currentId!==Rn&&(En.cancel(this.currentId),this.currentId=Rn)};disposeEffect=()=>this.cancel};function bo(){let e=Te(gt.create).current;return go(e.disposeEffect),e}function Ba(e,t=!1,o=!1){let[n,r]=Wr.useState(e&&t?"idle":void 0),[i,s]=Wr.useState(e);return e&&!i&&(s(!0),r("starting")),!e&&i&&n!=="ending"&&!o&&r("ending"),!e&&!i&&n==="ending"&&r(void 0),F(()=>{if(!e&&i&&n!=="ending"&&o){let a=gt.request(()=>{r("ending")});return()=>{gt.cancel(a)}}},[e,i,n,o]),F(()=>{if(!e||t)return;let a=gt.request(()=>{r(void 0)});return()=>{gt.cancel(a)}},[t,e]),F(()=>{if(!e||!t)return;e&&i&&n!=="idle"&&r("starting");let a=gt.request(()=>{r("idle")});return()=>{gt.cancel(a)}},[t,e,i,n]),{mounted:i,setMounted:s,transitionStatus:n}}var Yr=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),nm={"data-starting-style":""},rm={"data-ending-style":""},Ha={transitionStatus(e){return e==="starting"?nm:e==="ending"?rm:null}};var wo=b(z(),1);function kn(){return typeof window<"u"}function Qt(e){return Tn(e)?(e.nodeName||"").toLowerCase():"#document"}function fe(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function ht(e){var t;return(t=(Tn(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Tn(e){return kn()?e instanceof Node||e instanceof fe(e).Node:!1}function U(e){return kn()?e instanceof Element||e instanceof fe(e).Element:!1}function he(e){return kn()?e instanceof HTMLElement||e instanceof fe(e).HTMLElement:!1}function ho(e){return!kn()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof fe(e).ShadowRoot}function Fo(e){let{overflow:t,overflowX:o,overflowY:n,display:r}=Le(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+o)&&r!=="inline"&&r!=="contents"}function za(e){return/^(table|td|th)$/.test(Qt(e))}function Vo(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var im=/transform|translate|scale|rotate|perspective|filter/,sm=/paint|layout|strict|content/,Zt=e=>!!e&&e!=="none",Ur;function Pn(e){let t=U(e)?Le(e):e;return Zt(t.transform)||Zt(t.translate)||Zt(t.scale)||Zt(t.rotate)||Zt(t.perspective)||!Cn()&&(Zt(t.backdropFilter)||Zt(t.filter))||im.test(t.willChange||"")||sm.test(t.contain||"")}function Da(e){let t=bt(e);for(;he(t)&&!wt(t);){if(Pn(t))return t;if(Vo(t))return null;t=bt(t)}return null}function Cn(){return Ur==null&&(Ur=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),Ur}function wt(e){return/^(html|body|#document)$/.test(Qt(e))}function Le(e){return fe(e).getComputedStyle(e)}function Wo(e){return U(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function bt(e){if(Qt(e)==="html")return e;let t=e.assignedSlot||e.parentNode||ho(e)&&e.host||ht(e);return ho(t)?t.host:t}function ja(e){let t=bt(e);return wt(t)?(e.ownerDocument||e).body:he(t)&&Fo(t)?t:ja(t)}function Bt(e,t,o){var n;t===void 0&&(t=[]),o===void 0&&(o=!0);let r=ja(e),i=r===((n=e.ownerDocument)==null?void 0:n.body),s=fe(r);if(i){let a=An(s);return t.concat(s,s.visualViewport||[],Fo(r)?r:[],a&&o?Bt(a):[])}else return t.concat(r,Bt(r,[],o))}function An(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}var On=b(z(),1),am=On.createContext(void 0);function Fa(e=!1){let t=On.useContext(am);if(t===void 0&&!e)throw new Error(De(16));return t}var Va=b(z(),1);function Wa(e){let{focusableWhenDisabled:t,disabled:o,composite:n=!1,tabIndex:r=0,isNativeButton:i}=e,s=n&&t!==!1,a=n&&t===!1;return{props:Va.useMemo(()=>{let c={onKeyDown(d){o&&t&&d.key!=="Tab"&&d.preventDefault()}};return n||(c.tabIndex=r,!i&&o&&(c.tabIndex=t?r:-1)),(i&&(t||s)||!i&&o)&&(c["aria-disabled"]=o),i&&(!t||a)&&(c.disabled=o),c},[n,o,t,s,a,i,r])}}function Pe(e){return e?.ownerDocument||document}function Nn(e,t,{detail:o=0}={}){e.dispatchEvent(new(fe(e)).PointerEvent("click",{bubbles:!0,cancelable:!0,composed:!0,detail:o,shiftKey:t.shiftKey,ctrlKey:t.ctrlKey,altKey:t.altKey,metaKey:t.metaKey}))}function Ya(e={}){let{disabled:t=!1,focusableWhenDisabled:o,tabIndex:n=0,native:r=!0,composite:i}=e,s=wo.useRef(null),a=Fa(!0),l=i??a!==void 0,{props:c}=Wa({focusableWhenDisabled:o,disabled:t,composite:l,tabIndex:n,isNativeButton:r}),d=wo.useCallback(()=>{let f=s.current;Gr(f)&&l&&t&&c.disabled===void 0&&f.disabled&&(f.disabled=!1)},[t,c.disabled,l]);F(d,[d]);let m=wo.useCallback((f={})=>{let{onClick:p,onMouseDown:g,onKeyUp:h,onKeyDown:y,onPointerDown:_,...v}=f;return ve({onClick(w){if(t){w.preventDefault();return}p?.(w)},onMouseDown(w){t||g?.(w)},onKeyDown(w){if(t||(jo(w),y?.(w),w.baseUIHandlerPrevented))return;let R=w.target===w.currentTarget,x=w.currentTarget,S=Gr(x),E=!r&&cm(x),k=R&&(r?S:!E),P=w.key==="Enter",N=w.key===" ",H=x.getAttribute("role"),j=H?.startsWith("menuitem")||H==="option"||H==="gridcell";if(R&&l&&N){if(w.defaultPrevented&&j)return;w.preventDefault(),(!r||S)&&(w.preventBaseUIHandler(),Nn(x,w));return}if(!k||r||!N&&!P){R&&E&&N&&w.preventDefault();return}w.defaultPrevented||(w.preventDefault(),P&&(w.preventBaseUIHandler(),Nn(x,w)))},onKeyUp(w){if(!t){if(jo(w),h?.(w),w.target===w.currentTarget&&r&&l&&Gr(w.currentTarget)&&w.key===" "){w.preventDefault();return}w.baseUIHandlerPrevented||w.target===w.currentTarget&&!r&&!l&&!w.defaultPrevented&&w.key===" "&&(w.preventBaseUIHandler(),Nn(w.currentTarget,w))}},onPointerDown(w){if(t){w.preventDefault();return}_?.(w)}},r?{type:"button"}:{role:"button"},c,v)},[t,c,l,r]),u=Y(f=>{s.current=f,d()});return{getButtonProps:m,buttonRef:u}}function Gr(e){return he(e)&&e.tagName==="BUTTON"}function cm(e){return he(e)&&e.tagName==="A"&&!!e.href}function oe(e,t,o,n){return e.addEventListener(t,o,n),()=>{e.removeEventListener(t,o,n)}}function je(e){let t=Te(lm,e).current;return t.next=e,F(t.effect),t}function lm(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var Xa=b(z(),1);var Ka=b(Ht(),1);function Ga(e){return e==null?e:"current"in e?e.current:e}function vo(e,t=!1){let o=bo();return Y((n,r=null)=>{o.cancel();let i=Ga(e);if(i==null)return;let s=i,a=()=>{Ka.flushSync(n)};if(typeof s.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){n();return}function l(){Promise.all(s.getAnimations().map(c=>c.finished)).then(()=>{r?.aborted||a()},()=>{if(r?.aborted)return;if(s.getAnimations().some(d=>d.pending||d.playState!=="finished")){l();return}a()})}if(t){let c="data-starting-style";if(!s.hasAttribute(c)){o.request(l);return}let d=new MutationObserver(()=>{s.hasAttribute(c)||(d.disconnect(),l())});d.observe(s,{attributes:!0,attributeFilter:[c]}),r?.addEventListener("abort",()=>d.disconnect(),{once:!0});return}o.request(l)})}function In(e){let{enabled:t=!0,open:o,ref:n,onComplete:r}=e,i=Y(r),s=vo(n,o);Xa.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,o,i,s])}var Tt={};Mt(Tt,{engine:()=>Qr,env:()=>$r,os:()=>qr,screenReader:()=>Jr});var qr={};Mt(qr,{android:()=>Qa,apple:()=>Xr,ios:()=>Kr,linux:()=>mm,mac:()=>Ja,windows:()=>pm});function dm(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:um,platform:fm,maxTouchPoints:qa}=dm(),Jt=um.toLowerCase(),$t=fm.toLowerCase();var Kr=/^i(os$|p)/.test($t)||$t==="macintel"&&qa>1,Za="android",Qa=$t===Za||Jt.includes(Za),Ja=!Kr&&$t.startsWith("mac"),pm=$t.startsWith("win"),mm=!Qa&&/^(linux|chrome os)/.test($t),Xr=Ja||Kr;var Qr={};Mt(Qr,{blink:()=>bm,gecko:()=>gm,webkit:()=>Zr});var Zr=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),gm=!Zr&&Jt.includes("firefox"),bm=!Zr&&Jt.includes("chrom");var Jr={};Mt(Jr,{voiceOver:()=>hm});var hm=Xr;var $r={};Mt($r,{jsdom:()=>wm});var wm=/jsdom|happydom/.test(Jt);var Yo=0,Ke=class e{static create(){return new e}currentId=Yo;start(t,o){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Yo,o()},t)}isStarted(){return this.currentId!==Yo}clear=()=>{this.currentId!==Yo&&(clearTimeout(this.currentId),this.currentId=Yo)};disposeEffect=()=>this.clear};function at(){let e=Te(Ke.create).current;return go(e.disposeEffect),e}var Be=b(z(),1);function $a(e){return"nativeEvent"in e}function Pt(e,t){let o=["mouse","pen"];return t||o.push("",void 0),o.includes(e)}function ec(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var ei="data-base-ui-focusable";var ti="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Ln(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function re(e,t){if(!e||!t)return!1;let o=t.getRootNode?.();if(e.contains(t))return!0;if(o&&ho(o)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function Me(e){return"composedPath"in e?e.composedPath()[0]:e.target}function zt(e,t){if(!U(e))return!1;let o=e;if(t.hasElement(o))return!o.hasAttribute("data-trigger-disabled");for(let[,n]of t.entries())if(re(n,o))return!n.hasAttribute("data-trigger-disabled");return!1}function Mn(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let o=e;return o.target!=null&&t.contains(o.target)}function tc(e){return e.matches("html,body")}function oc(e){return he(e)&&e.matches(ti)}function oi(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${ti}`)!=null}function nc(e){if(!e||Tt.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function vm(e,t){return t!=null&&!Pt(t)?0:typeof e=="function"?e():e}function $e(e,t,o){let n=vm(e,o);return typeof n=="number"?n:n?.[t]}function ni(e){return typeof e=="function"?e():e}function Bn(e,t){return t||e==="click"||e==="mousedown"}function rc(e){return e?.includes("mouse")&&e!=="mousedown"}var ic=b(W(),1),sc=Be.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new Ke,currentIdRef:{current:null},currentContextRef:{current:null}});function _m(e,t){e.current=t.current}function ri(e){let{children:t,delay:o,timeoutMs:n=0}=e,r=Be.useRef(o),i=Be.useRef(o),s=Be.useRef(null),a=Be.useRef(null),l=at();return F(()=>{if(i.current=o,!s.current){r.current=o;return}r.current={open:$e(r.current,"open"),close:$e(o,"close")}},[o,s,r,i]),(0,ic.jsx)(sc.Provider,{value:Be.useMemo(()=>({hasProvider:!0,delayRef:r,initialDelayRef:i,currentIdRef:s,timeoutMs:n,currentContextRef:a,timeout:l}),[n,l]),children:t})}function ii(e,t={open:!1}){let{open:o}=t,n="rootStore"in e?e.rootStore:e,r=n.useState("floatingId"),i=Be.useContext(sc),{currentIdRef:s,delayRef:a,timeoutMs:l,initialDelayRef:c,currentContextRef:d,hasProvider:m,timeout:u}=i,[f,p]=Be.useState(!1),g=Be.useRef(o);return F(()=>{g.current=o},[o]),F(()=>{function h(){d.current?.setIsInstantPhase(!1),s.current=null,d.current=null,a.current=c.current,u.clear()}if(s.current&&!o&&s.current===r){if(p(!1),l){let y=r;return u.start(l,()=>{n.select("open")||s.current&&s.current!==y||h()}),()=>{(g.current||s.current!==y)&&u.clear()}}h()}},[o,r,s,a,l,c,d,u,n]),F(()=>{if(!o)return;let h=d.current,y=s.current;u.clear(),d.current={onOpenChange:n.setOpen,setIsInstantPhase:p},s.current=r,a.current={open:0,close:$e(c.current,"close")},y!==null&&y!==r?(p(!0),h?.setIsInstantPhase(!0),h?.onOpenChange(!1,ee(G.none))):(p(!1),h?.setIsInstantPhase(!1))},[o,r,n,s,a,c,d,u]),F(()=>()=>{if(s.current===r){if(d.current=null,!g.current)return;s.current=null,_m(a,c),u.clear()}},[d,s,a,r,c,u]),Be.useMemo(()=>({hasProvider:m,delayRef:a,isInstantPhase:f}),[m,a,f])}function ct(...e){return()=>{for(let t=0;t({x:e,y:e}),ym={left:"right",right:"left",bottom:"top",top:"bottom"};function zn(e,t,o){return lt(e,Dt(t,o))}function _t(e,t){return typeof e=="function"?e(t):e}function Ne(e){return e.split("-")[0]}function dt(e){return e.split("-")[1]}function Dn(e){return e==="x"?"y":"x"}function Ko(e){return e==="y"?"height":"width"}function Fe(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function Xo(e){return Dn(Fe(e))}function lc(e,t,o){o===void 0&&(o=!1);let n=dt(e),r=Xo(e),i=Ko(r),s=r==="x"?n===(o?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Uo(s)),[s,Uo(s)]}function dc(e){let t=Uo(e);return[Hn(e),t,Hn(t)]}function Hn(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var ac=["left","right"],cc=["right","left"],xm=["top","bottom"],Sm=["bottom","top"];function Rm(e,t,o){switch(e){case"top":case"bottom":return o?t?cc:ac:t?ac:cc;case"left":case"right":return t?xm:Sm;default:return[]}}function uc(e,t,o,n){let r=dt(e),i=Rm(Ne(e),o==="start",n);return r&&(i=i.map(s=>s+"-"+r),t&&(i=i.concat(i.map(Hn)))),i}function Uo(e){let t=Ne(e);return ym[t]+e.slice(t.length)}function Em(e){var t,o,n,r;return{top:(t=e.top)!=null?t:0,right:(o=e.right)!=null?o:0,bottom:(n=e.bottom)!=null?n:0,left:(r=e.left)!=null?r:0}}function jn(e){return typeof e!="number"?Em(e):{top:e,right:e,bottom:e,left:e}}function eo(e){let{x:t,y:o,width:n,height:r}=e;return{width:n,height:r,top:o,left:t,right:t+n,bottom:o+r,x:t,y:o}}function Ct(e,t,o=!0){return e.filter(r=>r.parentId===t).flatMap(r=>[...!o||r.context?.open?[r]:[],...Ct(e,r.id,o)])}function _o(e){return`data-base-ui-${e}`}var He=b(z(),1),mc=b(Ht(),1);var fc={style:{transition:"none"}};var km="data-base-ui-swipe-ignore",Tm="data-swipe-ignore",o1=`[${km}]`,n1=`[${Tm}]`;var pc={fallbackAxisSide:"end"};var gc=b(W(),1),Pm=He.createContext(null),Cm=()=>He.useContext(Pm),Am=_o("portal");function bc(e={}){let{ref:t,container:o,componentProps:n=me,elementProps:r}=e,i=mo(),a=Cm()?.portalNode,[l,c]=He.useState(null),[d,m]=He.useState(null),u=Y(h=>{h!==null&&m(h)}),f=He.useRef(null);F(()=>{if(o===null){f.current&&(f.current=null,m(null),c(null));return}let h=(o&&(Tn(o)?o:o.current))??a??document.body;if(h==null){f.current&&(f.current=null,m(null),c(null));return}f.current!==h&&(f.current=h,m(null),c(h))},[o,a]);let p=Oe("div",n,{ref:[t,u],props:[{id:i,[Am]:""},r]}),g=l&&p?mc.createPortal(p,l):null;return{node:d,nodeId:He.isValidElement(p)?p.props.id:void 0,subtree:g}}var to=b(z(),1);function hc(){let e=new Map;return{emit(t,o){e.get(t)?.forEach(n=>n(o))},on(t,o){e.has(t)||e.set(t,new Set),e.get(t).add(o)},off(t,o){e.get(t)?.delete(o)}}}var Om=b(W(),1),Nm=to.createContext(null),Im=to.createContext(null),Fn=()=>to.useContext(Nm)?.id||null,Ft=e=>{let t=to.useContext(Im);return e??t};var Ve=b(z(),1);function Lm(e,t){let o=null,n=null,r=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",l=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",c=i.width,d=i.height,m=i.x,u=i.y;return o==null&&t.x&&s&&(o=i.x-t.x),n==null&&t.y&&a&&(n=i.y-t.y),m-=o||0,u-=n||0,c=0,d=0,!r||l?(c=t.axis==="y"?i.width:0,d=t.axis==="x"?i.height:0,m=s&&t.x!=null?t.x:m,u=a&&t.y!=null?t.y:u):r&&!l&&(d=t.axis==="x"?i.height:d,c=t.axis==="y"?i.width:c),r=!0,{width:c,height:d,x:m,y:u,top:u,right:m+c,bottom:u+d,left:m}}}}function wc(e){return e!=null&&e.clientX!=null}function si(e,t={}){let{enabled:o=!0,axis:n="both"}=t,r="rootStore"in e?e.rootStore:e,i=r.useState("open"),s=r.useState("floatingElement"),a=r.useState("domReferenceElement"),l=r.context.dataRef,c=Ve.useRef(!1),d=Ve.useRef(null),[m,u]=Ve.useState(),[f,p]=Ve.useState([]),g=Y(w=>{r.set("positionReference",w)}),h=Y((w,R,x)=>{c.current||l.current.openEvent&&!wc(l.current.openEvent)||r.set("positionReference",Lm(x??a,{x:w,y:R,axis:n,dataRef:l,pointerType:m}))}),y=Y(w=>{i?d.current||(h(w.clientX,w.clientY,w.currentTarget),p([])):h(w.clientX,w.clientY,w.currentTarget)}),_=Pt(m)?s:i;Ve.useEffect(()=>{if(!o){g(a);return}if(!_)return;function w(){d.current?.(),d.current=null}let R=fe(s);function x(S){let E=Me(S);re(s,E)?w():h(S.clientX,S.clientY)}return!l.current.openEvent||wc(l.current.openEvent)?d.current=oe(R,"mousemove",x):g(a),w},[_,o,s,l,a,r,h,g,f]),Ve.useEffect(()=>()=>{r.set("positionReference",null)},[r]),Ve.useEffect(()=>{o&&!s&&(c.current=!1)},[o,s]),Ve.useEffect(()=>{!o&&i&&(c.current=!0)},[o,i]);let v=Ve.useMemo(()=>{function w(R){u(R.pointerType)}return{onPointerDown:w,onPointerEnter:w,onMouseMove:y,onMouseEnter:y}},[y]);return Ve.useMemo(()=>o?{reference:v,trigger:v}:{},[o,v])}var Xe=b(z(),1);function Mm(){return!1}function Bm(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function ai(e,t={}){let{enabled:o=!0,escapeKey:n=!0,outsidePress:r=!0,outsidePressEvent:i="sloppy",referencePress:s=Mm,bubbles:a,externalTree:l}=t,c="rootStore"in e?e.rootStore:e,d=c.useState("open"),m=c.useState("floatingElement"),{dataRef:u}=c.context,f=Ft(l),p=Y(typeof r=="function"?r:()=>!1),g=typeof r=="function"?p:r,h=g!==!1,y=Y(()=>i),{escapeKey:_,outsidePress:v}=Bm(a),w=Xe.useRef(!1),R=Xe.useRef(!1),x=Xe.useRef(!1),S=Xe.useRef(!1),E=Xe.useRef(""),k=Xe.useRef(null),P=at(),N=at(),H=Y(()=>{N.clear(),u.current.insideReactTree=!1}),j=Y(O=>{let V=u.current.floatingContext?.nodeId;return(f?Ct(f.nodesRef.current,V):[]).some(ie=>ie.context?.open&&!ie.context.dataRef.current[O])}),L=Y(O=>Mn(O,c.select("floatingElement"))||Mn(O,c.select("domReferenceElement"))),T=Y(O=>{s()&&c.setOpen(!1,ee(G.triggerPress,O.nativeEvent))}),I=Y(O=>{if(!d||!o||!n||O.key!=="Escape"||S.current||!_&&j("__escapeKeyBubbles"))return;let V=$a(O)?O.nativeEvent:O,Z=ee(G.escapeKey,V);c.setOpen(!1,Z),Z.isCanceled||O.preventDefault(),!_&&!Z.isPropagationAllowed&&O.stopPropagation()}),C=Y(()=>{u.current.insideReactTree=!0,N.start(0,H)}),A=Y(O=>{if(!d||!o||O.button!==0)return;let V=Me(O.nativeEvent);re(c.select("floatingElement"),V)&&(w.current||(w.current=!0,R.current=!1))}),M=Y(O=>{!d||!o||(O.defaultPrevented||O.nativeEvent.defaultPrevented)&&w.current&&(R.current=!0)});Xe.useEffect(()=>{if(!d||!o)return H;u.current.__escapeKeyBubbles=_,u.current.__outsidePressBubbles=v;let O=new Ke,V=new Ke;function Z(){O.clear(),S.current=!0}function ie(){O.start(Tt.engine.webkit?5:0,()=>{S.current=!1})}function K(){x.current=!0,V.start(0,()=>{x.current=!1})}function Q(){w.current=!1,R.current=!1}function q(){let B=E.current,D=B==="pen"||!B?"mouse":B,Se=y(),Ae=typeof Se=="function"?Se():Se;return typeof Ae=="string"?Ae:Ae[D]}function $(B){let D=q();return D==="intentional"&&B.type!=="click"||D==="sloppy"&&B.type==="click"}function ne(B){let D=u.current.floatingContext?.nodeId,Se=f&&Ct(f.nodesRef.current,D).some(Ae=>Mn(B,Ae.context?.elements.floating));return L(B)||Se}function se(B){if($(B)){B.type!=="click"&&!L(B)&&(V.clear(),x.current=!1),H();return}if(u.current.insideReactTree){H();return}let D=Me(B),Se=`[${_o("inert")}]`,Ae=U(D)?D.getRootNode():null,Nt=Array.from((ho(Ae)?Ae:Pe(c.select("floatingElement"))).querySelectorAll(Se)),it=c.context.triggerElements;if(D&&(it.hasElement(D)||it.hasMatchingElement(Ye=>re(Ye,D))))return;let It=U(D)?D:null;for(;It&&!wt(It);){let Ye=bt(It);if(wt(Ye)||!U(Ye))break;It=Ye}if(!(Nt.length&&U(D)&&!tc(D)&&!re(D,c.select("floatingElement"))&&Nt.every(Ye=>!re(It,Ye)))){if(he(D)&&!("touches"in B)){let Ye=wt(D),uo=Le(D),Xt=/auto|scroll/,gn=Ye||Xt.test(uo.overflowX),fo=Ye||Xt.test(uo.overflowY),Lt=gn&&D.clientWidth>0&&D.scrollWidth>D.clientWidth,bn=fo&&D.clientHeight>0&&D.scrollHeight>D.clientHeight,hn=uo.direction==="rtl",wn=bn&&(hn?B.offsetX<=D.offsetWidth-D.clientWidth:B.offsetX>D.clientWidth),vn=Lt&&B.offsetY>D.clientHeight;if(wn||vn)return}if(!ne(B)){if(q()==="intentional"&&x.current){V.clear(),x.current=!1;return}typeof g=="function"&&!g(B)||j("__outsidePressBubbles")||(c.setOpen(!1,ee(G.outsidePress,B)),H())}}}function ze(B){q()!=="sloppy"||B.pointerType==="touch"||!c.select("open")||!o||L(B)||se(B)}function ae(B){if(q()!=="sloppy"||!c.select("open")||!o||L(B))return;let D=B.touches[0];D&&(k.current={startTime:Date.now(),startX:D.clientX,startY:D.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},P.start(1e3,()=>{k.current&&(k.current.dismissOnTouchEnd=!1,k.current.dismissOnMouseDown=!1)}))}function ge(B,D){let Se=Me(B);if(!Se)return;let Ae=oe(Se,B.type,()=>{D(B),Ae()})}function be(B){E.current="touch",ge(B,ae)}function Ee(B){P.clear(),B.type==="pointerdown"&&(E.current=B.pointerType),!(B.type==="mousedown"&&k.current&&!k.current.dismissOnMouseDown)&&ge(B,D=>{D.type==="pointerdown"?ze(D):se(D)})}function ye(B){if(!w.current)return;let D=R.current;if(Q(),q()==="intentional"){if(B.type==="pointercancel"){D&&K();return}if(!ne(B)){if(D){K();return}typeof g=="function"&&!g(B)||(V.clear(),x.current=!0,H())}}}function Kt(B){if(q()!=="sloppy"||!k.current||L(B))return;let D=B.touches[0];if(!D)return;let Se=Math.abs(D.clientX-k.current.startX),Ae=Math.abs(D.clientY-k.current.startY),Nt=Math.sqrt(Se*Se+Ae*Ae);Nt>5&&(k.current.dismissOnTouchEnd=!0),Nt>10&&(se(B),P.clear(),k.current=null)}function rt(B){ge(B,Kt)}function ft(B){q()!=="sloppy"||!k.current||L(B)||(k.current.dismissOnTouchEnd&&se(B),P.clear(),k.current=null)}function Ot(B){ge(B,ft)}let xe=Pe(m),mn=ct(n&&ct(oe(xe,"keydown",I),oe(xe,"compositionstart",Z),oe(xe,"compositionend",ie)),h&&ct(oe(xe,"click",Ee,!0),oe(xe,"pointerdown",Ee,!0),oe(xe,"pointerup",ye,!0),oe(xe,"pointercancel",ye,!0),oe(xe,"mousedown",Ee,!0),oe(xe,"mouseup",ye,!0),oe(xe,"touchstart",be,!0),oe(xe,"touchmove",rt,!0),oe(xe,"touchend",Ot,!0)));return()=>{mn(),O.clear(),V.clear(),Q(),x.current=!1,H()}},[u,m,n,h,g,d,o,_,v,I,H,y,j,L,f,c,P]);let X=Xe.useMemo(()=>({onKeyDown:I,onPointerDown:T,onClick:T}),[I,T]),de=Xe.useMemo(()=>({onKeyDown:I,onPointerDown:M,onMouseDown:M,onClickCapture:C,onMouseDownCapture(O){C(),A(O)},onPointerDownCapture(O){C(),A(O)},onMouseUpCapture:C,onTouchEndCapture:C,onTouchMoveCapture:C}),[I,C,A,M]);return Xe.useMemo(()=>o?{reference:X,floating:de,trigger:X}:{},[o,X,de])}var Ie=b(z(),1);function vc(e,t,o){let{reference:n,floating:r}=e,i=Fe(t),s=Xo(t),a=Ko(s),l=Ne(t),c=i==="y",d=n.x+n.width/2-r.width/2,m=n.y+n.height/2-r.height/2,u=n[a]/2-r[a]/2,f;switch(l){case"top":f={x:d,y:n.y-r.height};break;case"bottom":f={x:d,y:n.y+n.height};break;case"right":f={x:n.x+n.width,y:m};break;case"left":f={x:n.x-r.width,y:m};break;default:f={x:n.x,y:n.y}}let p=dt(t);return p&&(f[s]+=u*(p==="end"?1:-1)*(o&&c?-1:1)),f}async function _c(e,t){var o;t===void 0&&(t={});let{x:n,y:r,platform:i,rects:s,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:m="floating",altBoundary:u=!1,padding:f=0}=_t(t,e),p=jn(f),h=a[u?m==="floating"?"reference":"floating":m],y=eo(await i.getClippingRect({element:(o=await(i.isElement==null?void 0:i.isElement(h)))==null||o?h:h.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:d,strategy:l})),_=m==="floating"?{x:n,y:r,width:s.floating.width,height:s.floating.height}:s.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),w=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},R=eo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:_,offsetParent:v,strategy:l}):_);return{top:(y.top-R.top+p.top)/w.y,bottom:(R.bottom-y.bottom+p.bottom)/w.y,left:(y.left-R.left+p.left)/w.x,right:(R.right-y.right+p.right)/w.x}}var Hm=50,yc=async(e,t,o)=>{let{placement:n="bottom",strategy:r="absolute",middleware:i=[],platform:s}=o,a=s.detectOverflow?s:{...s,detectOverflow:_c},l=await(s.isRTL==null?void 0:s.isRTL(t)),c=await s.getElementRects({reference:e,floating:t,strategy:r}),{x:d,y:m}=vc(c,n,l),u=n,f=0,p={};for(let g=0;gL<=0)){var N,H;let L=(((N=i.flip)==null?void 0:N.index)||0)+1,T=S[L];if(T&&(!(m==="alignment"?_!==Fe(T):!1)||P.every(A=>Fe(A.placement)===_?A.overflows[0]>0:!0)))return{data:{index:L,overflows:P},reset:{placement:T}};let I=(H=P.filter(C=>C.overflows[0]<=0).sort((C,A)=>C.overflows[1]-A.overflows[1])[0])==null?void 0:H.placement;if(!I)switch(f){case"bestFit":{var j;let C=(j=P.filter(A=>{if(x){let M=Fe(A.placement);return M===_||M==="y"}return!0}).map(A=>[A.placement,A.overflows.filter(M=>M>0).reduce((M,X)=>M+X,0)]).sort((A,M)=>A[1]-M[1])[0])==null?void 0:j[0];C&&(I=C);break}case"initialPlacement":I=a;break}if(r!==I)return{reset:{placement:I}}}return{}}}};var Sc=new Set(["left","top"]);async function zm(e,t){let{placement:o,platform:n,elements:r}=e,i=await(n.isRTL==null?void 0:n.isRTL(r.floating)),s=Ne(o),a=dt(o),l=Fe(o)==="y",c=Sc.has(s)?-1:1,d=i&&l?-1:1,m=_t(t,e),{mainAxis:u,crossAxis:f,alignmentAxis:p}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return a&&typeof p=="number"&&(f=a==="end"?p*-1:p),l?{x:f*d,y:u*c}:{x:u*c,y:f*d}}var Rc=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var o,n;let{x:r,y:i,placement:s,middlewareData:a}=t,l=await zm(t,e);return s===((o=a.offset)==null?void 0:o.placement)&&(n=a.arrow)!=null&&n.alignmentOffset?{}:{x:r+l.x,y:i+l.y,data:{...l,placement:s}}}}},Ec=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:o,y:n,placement:r,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:l={fn:_=>{let{x:v,y:w}=_;return{x:v,y:w}}},...c}=_t(e,t),d={x:o,y:n},m=await i.detectOverflow(t,c),u=Fe(r),f=Dn(u),p=d[f],g=d[u],h=(_,v)=>zn(v+m[_==="y"?"top":"left"],v,v-m[_==="y"?"bottom":"right"]);s&&(p=h(f,p)),a&&(g=h(u,g));let y=l.fn({...t,[f]:p,[u]:g});return{...y,data:{x:y.x-o,y:y.y-n,enabled:{[f]:s,[u]:a}}}}}},kc=function(e){return e===void 0&&(e={}),{options:e,fn(t){var o,n;let{x:r,y:i,placement:s,rects:a,middlewareData:l}=t,{offset:c=0,mainAxis:d=!0,crossAxis:m=!0}=_t(e,t),u={x:r,y:i},f=Fe(s),p=Dn(f),g=u[p],h=u[f],y=_t(c,t),_=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:(o=y.mainAxis)!=null?o:0,crossAxis:(n=y.crossAxis)!=null?n:0};if(d){let R=p==="y"?"height":"width",x=a.reference[p]-a.floating[R]+_.mainAxis,S=a.reference[p]+a.reference[R]-_.mainAxis;gS&&(g=S)}if(m){var v,w;let R=p==="y"?"width":"height",x=Sc.has(Ne(s)),S=a.reference[f]-a.floating[R]+(x&&((v=l.offset)==null?void 0:v[f])||0)+(x?0:_.crossAxis),E=a.reference[f]+a.reference[R]+(x?0:((w=l.offset)==null?void 0:w[f])||0)-(x?_.crossAxis:0);hE&&(h=E)}return{[p]:g,[f]:h}}}},Tc=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:o,rects:n,platform:r,elements:i}=t,{apply:s=()=>{},...a}=_t(e,t),l=await r.detectOverflow(t,a),c=Ne(o),d=dt(o),m=Fe(o)==="y",{width:u,height:f}=n.floating,p,g;c==="top"||c==="bottom"?(p=c,g=d===(await(r.isRTL==null?void 0:r.isRTL(i.floating))?"start":"end")?"left":"right"):(g=c,p=d==="end"?"top":"bottom");let h=f-l.top-l.bottom,y=u-l.left-l.right,_=Dt(f-l[p],h),v=Dt(u-l[g],y),w=t.middlewareData.shift,R=!w,x=_,S=v;w!=null&&w.enabled.x&&(S=y),w!=null&&w.enabled.y&&(x=h),R&&!d&&(m?S=u-2*lt(l.left,l.right):x=f-2*lt(l.top,l.bottom)),await s({...t,availableWidth:S,availableHeight:x});let E=await r.getDimensions(i.floating);return u!==E.width||f!==E.height?{reset:{rects:!0}}:{}}}};function Ac(e){let t=Le(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=he(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n,a=jt(o)!==i||jt(n)!==s;return a&&(o=i,n=s),{width:o,height:n,$:a}}function li(e){return U(e)?e:e.contextElement}function yo(e){let t=li(e);if(!he(t))return vt(1);let o=t.getBoundingClientRect(),{width:n,height:r,$:i}=Ac(t),s=(i?jt(o.width):o.width)/n,a=(i?jt(o.height):o.height)/r;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var Dm=vt(0);function Oc(e){let t=fe(e);return!Cn()||!t.visualViewport?Dm:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function jm(e,t,o){return t===void 0&&(t=!1),!!o&&t&&o===fe(e)}function oo(e,t,o,n){t===void 0&&(t=!1),o===void 0&&(o=!1);let r=e.getBoundingClientRect(),i=li(e),s=vt(1);t&&(n?U(n)&&(s=yo(n)):s=yo(e));let a=jm(i,o,n)?Oc(i):vt(0),l=(r.left+a.x)/s.x,c=(r.top+a.y)/s.y,d=r.width/s.x,m=r.height/s.y;if(i&&n){let u=fe(i),f=U(n)?fe(n):n,p=u,g=An(p);for(;g&&f!==p;){let h=yo(g),y=g.getBoundingClientRect(),_=Le(g),v=y.left+(g.clientLeft+parseFloat(_.paddingLeft))*h.x,w=y.top+(g.clientTop+parseFloat(_.paddingTop))*h.y;l*=h.x,c*=h.y,d*=h.x,m*=h.y,l+=v,c+=w,p=fe(g),g=An(p)}}return eo({width:d,height:m,x:l,y:c})}function Vn(e,t){let o=Wo(e).scrollLeft;return t?t.left+o:oo(ht(e)).left+o}function Nc(e,t){let o=e.getBoundingClientRect(),n=o.left+t.scrollLeft-Vn(e,o),r=o.top+t.scrollTop;return{x:n,y:r}}function Fm(e){let{elements:t,rect:o,offsetParent:n,strategy:r}=e,i=r==="fixed",s=ht(n),a=t?Vo(t.floating):!1;if(n===s||a&&i)return o;let l={scrollLeft:0,scrollTop:0},c=vt(1),d=vt(0),m=he(n);if((m||!i)&&((Qt(n)!=="body"||Fo(s))&&(l=Wo(n)),m)){let f=oo(n);c=yo(n),d.x=f.x+n.clientLeft,d.y=f.y+n.clientTop}let u=s&&!m&&!i?Nc(s,l):vt(0);return{width:o.width*c.x,height:o.height*c.y,x:o.x*c.x-l.scrollLeft*c.x+d.x+u.x,y:o.y*c.y-l.scrollTop*c.y+d.y+u.y}}function Vm(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function Wm(e){let t=Wo(e),o=e.ownerDocument.body,n=lt(e.scrollWidth,e.clientWidth,o.scrollWidth,o.clientWidth),r=lt(e.scrollHeight,e.clientHeight,o.scrollHeight,o.clientHeight),i=-t.scrollLeft+Vn(e),s=-t.scrollTop;return Le(o).direction==="rtl"&&(i+=lt(e.clientWidth,o.clientWidth)-n),{width:n,height:r,x:i,y:s}}var Ym=25;function Um(e,t,o){o===void 0&&(o="viewport");let n=o==="layoutViewport",r=fe(e),i=ht(e),s=r.visualViewport,a=i.clientWidth,l=i.clientHeight,c=0,d=0;if(s){let u=!Cn()||t==="fixed";n?u||(c=-s.offsetLeft,d=-s.offsetTop):(a=s.width,l=s.height,u&&(c=s.offsetLeft,d=s.offsetTop))}if(Vn(i)<=0){let u=i.ownerDocument,f=u.body,p=getComputedStyle(f),g=u.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,h=Math.abs(i.clientWidth-f.clientWidth-g),y=getComputedStyle(i).scrollbarGutter==="stable both-edges"?h/2:h;y<=Ym&&(a-=y)}return{width:a,height:l,x:c,y:d}}function Gm(e,t){let o=oo(e,!0,t==="fixed"),n=o.top+e.clientTop,r=o.left+e.clientLeft,i=yo(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,l=r*i.x,c=n*i.y;return{width:s,height:a,x:l,y:c}}function Pc(e,t,o){let n;if(t==="viewport"||t==="layoutViewport")n=Um(e,o,t);else if(t==="document")n=Wm(ht(e));else if(U(t))n=Gm(t,o);else{let r=Oc(e);n={x:t.x-r.x,y:t.y-r.y,width:t.width,height:t.height}}return eo(n)}function Km(e,t){let o=t.get(e);if(o)return o;let n=Bt(e,[],!1).filter(a=>U(a)&&Qt(a)!=="body"),r=null,i=Le(e).position==="fixed",s=i?bt(e):e;for(;U(s)&&!wt(s);){let a=Le(s),l=Pn(s),c=r?r.position:i?"fixed":"";!l&&(c==="fixed"||c==="absolute"&&a.position==="static")?n=n.filter(m=>m!==s):r=a,s=bt(s)}return t.set(e,n),n}function Xm(e){let{element:t,boundary:o,rootBoundary:n,strategy:r}=e,s=[...o==="clippingAncestors"?Vo(t)?[]:Km(t,this._c):[].concat(o),n],a=Pc(t,s[0],r),l=a.top,c=a.right,d=a.bottom,m=a.left;for(let u=1;u{a(!1,1e-7)},1e3)}S=!1}try{n=new IntersectionObserver(E,{...x,root:i.ownerDocument})}catch{n=new IntersectionObserver(E,x)}n.observe(e)}let l=fe(e),c=()=>a(o);return l.addEventListener("resize",c),a(!0),()=>{l.removeEventListener("resize",c),s()}}function qo(e,t,o,n){n===void 0&&(n={});let{ancestorScroll:r=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,c=li(e),d=r||i?[...c?Bt(c):[],...t?Bt(t):[]]:[];d.forEach(y=>{r&&y.addEventListener("scroll",o),i&&y.addEventListener("resize",o)});let m=c&&a?$m(c,o,i):null,u=-1,f=null;s&&(f=new ResizeObserver(y=>{let[_]=y;_&&_.target===c&&f&&t&&(f.unobserve(t),cancelAnimationFrame(u),u=requestAnimationFrame(()=>{var v;(v=f)==null||v.observe(t)})),o()}),c&&!l&&f.observe(c),t&&f.observe(t));let p,g=l?oo(e):null;l&&h();function h(){let y=oo(e);g&&!Lc(g,y)&&o(),g=y,p=requestAnimationFrame(h)}return o(),()=>{var y;d.forEach(_=>{r&&_.removeEventListener("scroll",o),i&&_.removeEventListener("resize",o)}),m?.(),(y=f)==null||y.disconnect(),f=null,l&&cancelAnimationFrame(p)}}var Mc=Rc;var Bc=Ec,Hc=xc,zc=Tc;var Dc=kc,Wn=(e,t,o)=>{let n=new Map,r=o??{},i={...di,...r.platform,_c:n};return yc(e,t,{...r,platform:i})};var we=b(z(),1),Fc=b(z(),1),Vc=b(Ht(),1),tg=typeof document<"u",og=function(){},Yn=tg?Fc.useLayoutEffect:og;function Un(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let o,n,r;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(o=e.length,o!==t.length)return!1;for(n=o;n--!==0;)if(!Un(e[n],t[n]))return!1;return!0}if(r=Object.keys(e),o=r.length,o!==Object.keys(t).length)return!1;for(n=o;n--!==0;)if(!{}.hasOwnProperty.call(t,r[n]))return!1;for(n=o;n--!==0;){let i=r[n];if(!(i==="_owner"&&e.$$typeof)&&!Un(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Wc(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function jc(e,t){let o=Wc(e);return Math.round(t*o)/o}function ui(e){let t=we.useRef(e);return Yn(()=>{t.current=e}),t}function Yc(e){e===void 0&&(e={});let{placement:t="bottom",strategy:o="absolute",middleware:n=[],platform:r,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:l,open:c}=e,[d,m]=we.useState({x:0,y:0,strategy:o,placement:t,middlewareData:{},isPositioned:!1}),[u,f]=we.useState(n);Un(u,n)||f(n);let[p,g]=we.useState(null),[h,y]=we.useState(null),_=we.useCallback(A=>{A!==x.current&&(x.current=A,g(A))},[]),v=we.useCallback(A=>{A!==S.current&&(S.current=A,y(A))},[]),w=i||p,R=s||h,x=we.useRef(null),S=we.useRef(null),E=we.useRef(d),k=l!=null,P=ui(l),N=ui(r),H=ui(c),j=we.useCallback(()=>{if(!x.current||!S.current)return;let A={placement:t,strategy:o,middleware:u};N.current&&(A.platform=N.current),Wn(x.current,S.current,A).then(M=>{let X={...M,isPositioned:H.current!==!1};L.current&&!Un(E.current,X)&&(E.current=X,Vc.flushSync(()=>{m(X)}))})},[u,t,o,N,H]);Yn(()=>{c===!1&&E.current.isPositioned&&(E.current.isPositioned=!1,m(A=>({...A,isPositioned:!1})))},[c]);let L=we.useRef(!1);Yn(()=>(L.current=!0,()=>{L.current=!1}),[]),Yn(()=>{if(w&&(x.current=w),R&&(S.current=R),w&&R){if(P.current)return P.current(w,R,j);j()}},[w,R,j,P,k]);let T=we.useMemo(()=>({reference:x,floating:S,setReference:_,setFloating:v}),[_,v]),I=we.useMemo(()=>({reference:w,floating:R}),[w,R]),C=we.useMemo(()=>{let A={position:o,left:0,top:0};if(!I.floating)return A;let M=jc(I.floating,d.x),X=jc(I.floating,d.y);return a?{...A,transform:"translate("+M+"px, "+X+"px)",...Wc(I.floating)>=1.5&&{willChange:"transform"}}:{position:o,left:M,top:X}},[o,a,I.floating,d.x,d.y]);return we.useMemo(()=>({...d,update:j,refs:T,elements:I,floatingStyles:C}),[d,j,T,I,C])}var fi=(e,t)=>{let o=Mc(e);return{name:o.name,fn:o.fn,options:[e,t]}},pi=(e,t)=>{let o=Bc(e);return{name:o.name,fn:o.fn,options:[e,t]}},mi=(e,t)=>({fn:Dc(e).fn,options:[e,t]}),gi=(e,t)=>{let o=Hc(e);return{name:o.name,fn:o.fn,options:[e,t]}},bi=(e,t)=>{let o=zc(e);return{name:o.name,fn:o.fn,options:[e,t]}};var Gn=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,o,n=!0){this.fallbackStore=t,this.componentName=o,this.throwOnMissingTrigger=n}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let o=this.attachedStores.lastIndexOf(t);o!==-1&&this.attachedStores.splice(o,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(o=>{o()}))}openByTrigger(t){let o=this.attachedStore;if(o===null)return;let n;if(t){for(let r=this.attachedStores.length-1;r>=0&&!n;r-=1)n=this.attachedStores[r].context.triggerElements.getById(t);n??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!n&&this.throwOnMissingTrigger)throw new Error(De(99,this.componentName,t,this.componentName));o.setOpen(!0,ee(G.imperativeAction,void 0,n))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,ee(G.imperativeAction))}};var ro=b(z(),1),sl=b(Ht(),1);var rl=b(z(),1);var ol=b(z(),1),yi=b(Kn(),1),nl=b(Qc(),1);var Jc=b(z(),1);var wi=[],vi;function $c(){return vi}function el(e){wi.push(e)}function _i(e){let t=(o,n)=>{let r=Te(_g).current,i;try{vi=r;for(let s of wi)s.before(r);i=e(o,n);for(let s of wi)s.after(r);r.didInitialize=!0}finally{vi=void 0}return i};return t.displayName=e.displayName||e.name,t}function tl(e){return Jc.forwardRef(_i(e))}function _g(){return{didInitialize:!1}}var yg=po(19),xg=yg?Rg:Eg;function qn(e,t,o,n,r){return xg(e,t,o,n,r)}function Sg(e,t,o,n,r){let i=ol.useCallback(()=>t(e.getSnapshot(),o,n,r),[e,t,o,n,r]);return(0,yi.useSyncExternalStore)(e.subscribe,i,i)}el({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let o=0;o0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let o=new Set;for(let r of e.syncHooks)o.add(r.store);let n=[];for(let r of o)n.push(r.subscribe(t));return()=>{for(let r of n)r()}}),(0,yi.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function Rg(e,t,o,n,r){let i=$c();if(!i)return Sg(e,t,o,n,r);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,o)||!Object.is(a.a2,n)||!Object.is(a.a3,r))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=o,a.a2=n,a.a3=r,a.value=t(e.getSnapshot(),o,n,r))):(a={store:e,selector:t,a1:o,a2:n,a3:r,value:t(e.getSnapshot(),o,n,r)},i.syncHooks.push(a)),a.value}function Eg(e,t,o,n,r){return(0,nl.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,o,n,r))}var Zn=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let o=this.updateTick;for(let n of this.listeners){if(o!==this.updateTick)return;n(t)}}update(t){for(let o in t)if(!Object.is(this.state[o],t[o])){this.setState({...this.state,...t});return}}set(t,o){Object.is(this.state[t],o)||this.setState({...this.state,[t]:o})}notifyAll(){let t={...this.state};this.setState(t)}use(t,o,n,r){return qn(this,t,o,n,r)}};var no=b(z(),1);var Vt=class extends Zn{constructor(t,o={},n){super(t),this.context=o,this.selectors=n}useSyncedValue(t,o){no.useDebugValue(t);let n=this;F(()=>{n.state[t]!==o&&n.set(t,o)},[n,t,o])}useSyncedValueWithCleanup(t,o){let n=this;F(()=>(n.state[t]!==o&&n.set(t,o),()=>{n.set(t,void 0)}),[n,t,o])}useSyncedValues(t){let o=this,n=Object.values(t);F(()=>{o.update(t)},[o,...n])}useControlledProp(t,o){no.useDebugValue(t);let n=this,r=o!==void 0;F(()=>{r&&!Object.is(n.state[t],o)&&n.setState({...n.state,[t]:o})},[n,t,o,r])}select(t,o,n,r){let i=this.selectors[t];return i(this.state,o,n,r)}useState(t,o,n,r){return no.useDebugValue(t),qn(this,this.selectors[t],o,n,r)}useContextCallback(t,o){no.useDebugValue(t);let n=Y(o??Ge);this.context[t]=n}useStateSetter(t){let o=no.useRef(void 0);return o.current===void 0&&(o.current=n=>{this.set(t,n)}),o.current}observe(t,o){let n;typeof t=="function"?n=t:n=this.selectors[t];let r=n(this.state);return o(r,r,this),this.subscribe(i=>{let s=n(i);if(!Object.is(r,s)){let a=r;r=s,o(s,a,this)}})}};var kg={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},Wt=class extends Vt{constructor(t){let{syncOnly:o,nested:n,onOpenChange:r,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:r,dataRef:{current:{}},events:hc(),nested:n,triggerElements:i},kg),this.syncOnly=o}syncOpenEvent=(t,o)=>{(!t||!this.state.open||o!=null&&ec(o))&&(this.context.dataRef.current.openEvent=t?o:void 0)};dispatchOpenChange=(t,o)=>{this.syncOpenEvent(t,o.event);let n={open:t,reason:o.reason,nativeEvent:o.event,nested:this.context.nested,triggerElement:o.trigger};this.context.events.emit("openchange",n)};setOpen=(t,o)=>{if(this.syncOnly){this.context.onOpenChange?.(t,o);return}this.dispatchOpenChange(t,o),this.context.onOpenChange?.(t,o)}};function il(e){let{popupStore:t,treatPopupAsFloatingElement:o=!1,floatingRootContext:n,floatingId:r,nested:i,onOpenChange:s}=e,a=t.useState("open"),l=t.useState("activeTriggerElement"),c=t.useState(o?"popupElement":"positionerElement"),d=t.context.triggerElements,m=s,u=rl.useRef(null);n===void 0&&u.current===null&&(u.current=new Wt({open:a,transitionStatus:void 0,referenceElement:l,floatingElement:c,triggerElements:d,onOpenChange:m,floatingId:r,syncOnly:!0,nested:i}));let f=n??u.current;return t.useSyncedValue("floatingId",r),F(()=>{let p={open:a,floatingId:r,referenceElement:l,floatingElement:c};U(l)&&(p.domReferenceElement=l),f.state.positionReference===f.state.referenceElement&&(p.positionReference=l),f.update(p)},[a,r,l,c,f]),f.context.onOpenChange=m,f.context.nested=i,f}var al={tabIndex:-1,[ei]:""};function cl(e,t=!1){let o=mo(),n=Fn()!=null,r=Te(()=>e(o,n)).current;return il({popupStore:r,treatPopupAsFloatingElement:t,floatingRootContext:r.state.floatingRootContext,floatingId:o,nested:n,onOpenChange:r.setOpen}),r}function ll({handle:e,store:t}){return F(()=>e.attachStore(t),[e,t]),null}function Tg(e,t){let o=ro.useRef(null),n=ro.useRef(null);return ro.useCallback(r=>{if(e===void 0)return;let i=!1;if(o.current!==null){let s=o.current,a=n.current,l=t.context.triggerElements.getById(s);a&&l===a&&(t.context.triggerElements.delete(s),i=!0),o.current=null,n.current=null}if(r!==null&&(o.current=e,n.current=r,t.context.triggerElements.add(e,r),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function Pg(e,t,o,n=!1){t?e.preventUnmountingOnClose=!1:n&&(e.preventUnmountingOnClose=!0);let r=o?.id??null;(r||t)&&(e.activeTriggerId=r,e.activeTriggerElement=o??null)}function Cg(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function dl(e,t,o,n={}){let r=o.reason,i=r===G.triggerHover,s=t&&r===G.triggerFocus,a=!t&&(r===G.triggerPress||r===G.escapeKey),l=Cg(o);if(e.context.onOpenChange?.(t,o),o.isCanceled)return;n.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,o);let c=()=>{let d={...n.extraState,open:t};s?d.instantType="focus":a?d.instantType="dismiss":i&&(d.instantType=void 0),Pg(d,t,o.trigger,l()),e.update(d)};i?sl.flushSync(c):c()}function ul(e,t,o,n){let r=o.useState("isMountedByTrigger",e),i=Tg(e,o),s=Y(l=>{let c=o.select("open"),d=o.select("activeTriggerId");if(d===e){o.update({activeTriggerElement:l,...c?n:null});return}d==null&&c&&o.update({activeTriggerId:e,activeTriggerElement:l,...n})}),a=ro.useCallback(l=>{i(l),l&&s(l)},[i,s]);return F(()=>{r&&o.update({activeTriggerElement:t.current,...n})},[r,o,t,...Object.values(n)]),{registerTrigger:a,isMountedByThisTrigger:r}}function fl(e,t={}){let{closeOnActiveTriggerUnmount:o=!1}=t,n=ro.useRef(null),r=e.useState("open"),i=e.useState("triggerCount"),s=e.useState("activeTriggerId"),a=e.useState("activeTriggerElement");F(()=>{if(!r){n.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let l=e.context.triggerElements.size,c={};e.state.triggerCount!==l&&(c.triggerCount=l);let d=e.select("activeTriggerId"),m=null;if(d){let u=e.context.triggerElements.getById(d);if(u)n.current=d,u!==e.state.activeTriggerElement&&(c.activeTriggerElement=u);else{for(let[f,p]of e.context.triggerElements.entries())if(p===e.state.activeTriggerElement){c.activeTriggerId=f,c.activeTriggerElement=p,n.current=f;break}c.activeTriggerId===void 0&&(n.current===d?m=d:n.current=null)}}else n.current=null;if(!m&&!d&&l===1){let u=e.context.triggerElements.entries().next();if(!u.done){let[f,p]=u.value;c.activeTriggerId=f,c.activeTriggerElement=p,n.current=f}}(c.triggerCount!==void 0||c.activeTriggerId!==void 0||c.activeTriggerElement!==void 0)&&e.update(c),m&&o&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===m&&!e.context.triggerElements.getById(m)){let u=ee(G.none);e.setOpen(!1,u),u.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[r,e,i,s,a,o])}function pl(e,t,o){let{mounted:n,setMounted:r,transitionStatus:i}=Ba(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:n,transitionStatus:i,preventUnmountingOnClose:a});let l=Y(()=>{r(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),o?.(),t.context.onOpenChangeComplete?.(!1)});return In({enabled:n&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||l()}}),{forceUnmount:l,transitionStatus:i}}function ml(e,t){e.useSyncedValues(t),F(()=>()=>{e.update({activeTriggerProps:me,inactiveTriggerProps:me,popupProps:me})},[e])}var io=class{constructor(){this.idMap=new Map}add(t,o){this.idMap.set(t,o)}delete(t){this.idMap.delete(t)}hasElement(t){for(let o of this.idMap.values())if(o===t)return!0;return!1}hasMatchingElement(t){for(let o of this.idMap.values())if(t(o))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function gl(){return new Wt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new io,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function hl(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:gl(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:me,inactiveTriggerProps:me,popupProps:me}}function wl(e,t,o=!1){return new Wt({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:o,onOpenChange:void 0})}var Zo=e=>e.triggerIdProp??e.activeTriggerId,xi=e=>e.openProp??e.open,bl=e=>(e.popupElement?.id??e.floatingId)||void 0;function vl(e,t){return t!==void 0&&xi(e)&&Zo(e)===t}function Ag(e,t){return vl(e,t)?!0:t!==void 0&&xi(e)&&Zo(e)==null&&e.triggerCount===1}var _l={open:xi,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:Zo,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:bl,isTriggerActive:(e,t)=>t!==void 0&&Zo(e)===t,isOpenedByTrigger:(e,t)=>vl(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&Zo(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>Ag(e,t)?bl(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var Si=b(z(),1),yl=b(Kn(),1);function xl(e){let t=Si.useCallback(n=>e===void 0?Ge:e.subscribeStore(n),[e]),o=Si.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,yl.useSyncExternalStore)(t,o,()=>e?.serverStore)}function Sl(e){return Og(e,e.rootContext)}function Og(e,t){let{nodeId:o,externalTree:n}=e,r=t.useState("referenceElement"),i=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),l=t.useState("floatingId"),[c,d]=Ie.useState(null),[m,u]=Ie.useState(void 0),[f,p]=Ie.useState(void 0),g=Ie.useRef(null),h=Ft(n),y=Ie.useMemo(()=>({reference:r,floating:i,domReference:s}),[r,i,s]),_=Yc({...e,elements:{...y,...c&&{reference:c}}}),v=U(m)?m:null,w=f===void 0?t.state.floatingElement:f;t.useSyncedValue("referenceElement",m??null),t.useSyncedValue("domReferenceElement",m===void 0?s:v),t.useSyncedValue("floatingElement",w);let R=Ie.useCallback(N=>{let H=U(N)?{getBoundingClientRect:()=>N.getBoundingClientRect(),getClientRects:()=>N.getClientRects(),contextElement:N}:N;d(H),_.refs.setReference(H)},[_.refs]),x=Ie.useCallback(N=>{(U(N)||N===null)&&(g.current=N,u(N)),(U(_.refs.reference.current)||_.refs.reference.current===null||N!==null&&!U(N))&&_.refs.setReference(N)},[_.refs,u]),S=Ie.useCallback(N=>{p(N),_.refs.setFloating(N)},[_.refs]),E=Ie.useMemo(()=>({..._.refs,setReference:x,setFloating:S,setPositionReference:R,domReference:g}),[_.refs,x,S,R]),k=Ie.useMemo(()=>({..._.elements,domReference:s}),[_.elements,s]),P=Ie.useMemo(()=>({..._,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:l,refs:E,elements:k,nodeId:o,rootStore:t}),[_,E,k,o,t,a,l]);return F(()=>{s&&(g.current=s)},[s]),F(()=>{t.context.dataRef.current.floatingContext=P;let N=h?.nodesRef.current.find(H=>H.id===o);N&&(N.context=P)}),Ie.useMemo(()=>({..._,context:P,refs:E,elements:k,rootStore:t}),[_,E,k,P,t])}var yt=b(z(),1);var Ri=Tt.os.mac&&Tt.engine.webkit;function Ei(e,t={}){let{enabled:o=!0,delay:n}=t,r="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=r.context,a=yt.useRef(!1),l=yt.useRef(null),c=yt.useRef(!0),d=at();yt.useEffect(()=>{let u=r.select("domReferenceElement");if(!o)return;let f=fe(u);function p(){let y=r.select("domReferenceElement");!r.select("open")&&he(y)&&y===Ln(Pe(y))&&(a.current=!0)}function g(){c.current=!0}function h(){c.current=!1}return ct(oe(f,"blur",p),Ri&&oe(f,"keydown",g,!0),Ri&&oe(f,"pointerdown",h,!0))},[r,o]),yt.useEffect(()=>{if(!o)return;function u(f){if(f.reason===G.triggerPress||f.reason===G.escapeKey){let p=r.select("domReferenceElement");U(p)&&(l.current=p,a.current=!0)}}return i.on("openchange",u),()=>{i.off("openchange",u)}},[i,o,r]);let m=yt.useMemo(()=>{function u(){a.current=!1,l.current=null}return{onMouseLeave(){u()},onFocus(f){let p=f.currentTarget;if(a.current){if(l.current===p)return;u()}let g=Me(f.nativeEvent);if(U(g)){if(Ri&&!f.relatedTarget){if(!c.current&&!oc(g))return}else if(!nc(g))return}let h=zt(f.relatedTarget,r.context.triggerElements),{nativeEvent:y,currentTarget:_}=f,v=typeof n=="function"?n():n;if(r.select("open")&&h||v===0||v===void 0){r.setOpen(!0,ee(G.triggerFocus,y,_));return}d.start(v,()=>{a.current||r.setOpen(!0,ee(G.triggerFocus,y,_))})},onBlur(f){u();let p=f.relatedTarget,g=f.nativeEvent,h=U(p)&&p.hasAttribute(_o("focus-guard"))&&p.getAttribute("data-type")==="outside";d.start(0,()=>{let y=r.select("domReferenceElement"),_=Ln(Pe(y));!p&&_===y||re(s.current.floatingContext?.refs.floating.current,_)||re(y,_)||h||zt(p??_,r.context.triggerElements)||r.setOpen(!1,ee(G.triggerFocus,g))})}}},[s,n,r,d]);return yt.useMemo(()=>o?{reference:m,trigger:m}:{},[o,m])}var Ti=b(z(),1);var ki=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new Ke,this.restTimeout=new Ke,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},Qn=new WeakMap;function So(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&Qn.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),Qn.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function Jn(e,t){let{scopeElement:o,referenceElement:n,floatingElement:r}=t,i=Qn.get(o);i&&i!==e&&So(i),So(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=o,e.pointerEventsReferenceElement=n,e.pointerEventsFloatingElement=r,Qn.set(o,e),o.style.pointerEvents="none",n.style.pointerEvents="auto",r.style.pointerEvents="auto"}function Ro(e){let t=e.context.dataRef.current,o=Te(()=>t.hoverInteractionState??ki.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=o),go(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function Pi(e,t={}){let{enabled:o=!0,closeDelay:n=0,nodeId:r}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),l=i.useState("domReferenceElement"),{dataRef:c}=i.context,d=Ft(),m=Fn(),u=Ro(i),f=at(),p=Y(()=>Bn(c.current.openEvent?.type,u.interactedInside)),g=Y(()=>rc(c.current.openEvent?.type)),h=Y(()=>{So(u)});F(()=>{s||(u.pointerType=void 0,u.restTimeoutPending=!1,u.interactedInside=!1,h())},[s,u,h]),Ti.useEffect(()=>h,[h]),F(()=>{if(o&&s&&u.handleCloseOptions?.blockPointerEvents&&g()&&U(l)&&a){let y=l,_=a,v=Pe(a),w=d?.nodesRef.current.find(E=>E.id===m)?.context?.elements.floating;w&&(w.style.pointerEvents="");let R=u.pointerEventsScopeElement!==_?u.pointerEventsScopeElement:null,x=w!==_?w:null,S=u.handleCloseOptions?.getScope?.()??R??x??y.closest("[data-rootownerid]")??v.body;return Jn(u,{scopeElement:S,referenceElement:y,floatingElement:_}),()=>{h()}}},[o,s,l,a,u,g,d,m,h]),Ti.useEffect(()=>{if(!o)return;function y(){return!!(d&&m&&Ct(d.nodesRef.current,m).length>0)}function _(E){let k=$e(n,"close",u.pointerType),P=()=>{i.setOpen(!1,ee(G.triggerHover,E)),d?.events.emit("floating.closed",E)};k?u.openChangeTimeout.start(k,P):(u.openChangeTimeout.clear(),P())}function v(E){let k=Me(E);if(!oi(k)){u.interactedInside=!1;return}u.interactedInside=k?.closest("[aria-haspopup]")!=null}function w(){u.openChangeTimeout.clear(),f.clear(),d?.events.off("floating.closed",x),h()}function R(E){if(y()&&d){d.events.on("floating.closed",x);return}if(zt(E.relatedTarget,i.context.triggerElements))return;let k=c.current.floatingContext?.nodeId??r,P=E.relatedTarget;if(!(d&&k&&U(P)&&Ct(d.nodesRef.current,k,!1).some(H=>re(H.context?.elements.floating,P)))){if(u.handler){u.handler(E);return}h(),g()&&!p()&&_(E)}}function x(E){!d||!m||y()||f.start(0,()=>{d.events.off("floating.closed",x),i.setOpen(!1,ee(G.triggerHover,E)),d.events.emit("floating.closed",E)})}let S=a;return ct(S&&oe(S,"mouseenter",w),S&&oe(S,"mouseleave",R),S&&oe(S,"pointerdown",v,!0),()=>{d?.events.off("floating.closed",x)})},[o,a,i,c,n,r,g,p,h,u,d,m,f])}var Yt=b(z(),1),Rl=b(Ht(),1);var Ng={current:null};function Ci(e,t={}){let{enabled:o=!0,delay:n=0,handleClose:r=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:l=Ng,externalTree:c,isActiveTrigger:d=!0,getHandleCloseContext:m,isClosing:u,shouldOpen:f,guardStaleOpen:p=!1}=t,g="rootStore"in e?e.rootStore:e,{dataRef:h,events:y}=g.context,_=Ft(c),v=Ro(g),w=Yt.useRef(!1),R=je(r),x=je(n),S=je(s),E=je(o),k=je(f),P=je(u),N=Y(()=>Bn(h.current.openEvent?.type,v.interactedInside)),H=Y(()=>k.current?.()!==!1),j=Y((I,C,A)=>{let M=g.context.triggerElements;if(M.hasElement(C))return!I||!re(I,C);if(!U(A))return!1;let X=A;return M.hasMatchingElement(de=>re(de,X))&&(!I||!re(I,X))}),L=Y(()=>{if(!v.handler)return;Pe(g.select("domReferenceElement")).removeEventListener("mousemove",v.handler),v.handler=void 0}),T=Y(()=>{So(v)});return d&&(v.handleCloseOptions=R.current?.__options),Yt.useEffect(()=>L,[L]),Yt.useEffect(()=>{if(!o)return;function I(C){C.open?w.current=!1:(w.current=C.reason===G.triggerHover,L(),v.openChangeTimeout.clear(),v.restTimeout.clear(),v.blockMouseMove=!0,v.restTimeoutPending=!1)}return y.on("openchange",I),()=>{y.off("openchange",I)}},[o,y,v,L]),Yt.useEffect(()=>{if(!o)return;function I(O,V=!0){let Z=$e(x.current,"close",v.pointerType);Z?v.openChangeTimeout.start(Z,()=>{g.setOpen(!1,ee(G.triggerHover,O)),_?.events.emit("floating.closed",O)}):V&&(v.openChangeTimeout.clear(),g.setOpen(!1,ee(G.triggerHover,O)),_?.events.emit("floating.closed",O))}let C=l.current??(d?g.select("domReferenceElement"):null);if(!U(C))return;function A(O){if(v.openChangeTimeout.clear(),v.blockMouseMove=!1,i&&!Pt(v.pointerType))return;let V=ni(S.current),Z=$e(x.current,"open",v.pointerType),ie=Me(O),K=O.currentTarget??null,Q=g.select("domReferenceElement"),q=K;if(U(ie)&&!g.context.triggerElements.hasElement(ie)){for(let ye of g.context.triggerElements.elements())if(re(ye,ie)){q=ye;break}}U(K)&&U(Q)&&!g.context.triggerElements.hasElement(K)&&re(K,Q)&&(q=Q);let $=q==null?!1:j(Q,q,ie),ne=g.select("open"),se=P.current?.()??g.select("transitionStatus")==="ending",ze=!ne&&se&&w.current,ae=!$&&U(q)&&U(Q)&&re(Q,q)&&ze,ge=V>0&&!Z,be=$&&(ne||ze)||ae,Ee=!ne||$;if(be){H()&&g.setOpen(!0,ee(G.triggerHover,O,q));return}ge||(Z?v.openChangeTimeout.start(Z,()=>{Ee&&H()&&g.setOpen(!0,ee(G.triggerHover,O,q))}):Ee&&H()&&g.setOpen(!0,ee(G.triggerHover,O,q)))}function M(O){if(N()){T();return}L();let V=g.select("domReferenceElement"),Z=Pe(V);v.restTimeout.clear(),v.restTimeoutPending=!1;let ie=h.current.floatingContext??m?.();if(zt(O.relatedTarget,g.context.triggerElements))return;if(R.current&&ie){g.select("open")||v.openChangeTimeout.clear();let Q=l.current;v.handler=R.current({...ie,tree:_,x:O.clientX,y:O.clientY,onClose(){T(),L(),E.current&&!N()&&Q===g.select("domReferenceElement")&&I(O,!0)}}),Z.addEventListener("mousemove",v.handler),v.handler(O);return}(v.pointerType!=="touch"||!re(g.select("floatingElement"),O.relatedTarget))&&I(O)}function X(O){re(C,O.relatedTarget)||(v.openChangeTimeout.clear(),v.restTimeout.clear(),v.restTimeoutPending=!1)}let de=p?oe(C,"mouseout",X):void 0;return a?ct(oe(C,"mousemove",A,{once:!0}),oe(C,"mouseenter",A),oe(C,"mouseleave",M),de):ct(oe(C,"mouseenter",A),oe(C,"mouseleave",M),de)},[L,T,h,x,g,o,R,v,d,j,N,i,a,S,l,_,E,m,P,H,p]),Yt.useMemo(()=>{if(!o)return;function I(C){v.pointerType=C.pointerType}return{onPointerDown:I,onPointerEnter:I,onMouseMove(C){let{nativeEvent:A}=C,M=C.currentTarget,X=g.select("domReferenceElement"),de=g.select("open"),O=j(X,M,C.target);if(i&&!Pt(v.pointerType))return;if(de&&O&&v.handleCloseOptions?.blockPointerEvents){let ie=g.select("floatingElement");if(ie){let K=v.handleCloseOptions?.getScope?.()??M.ownerDocument.body;Jn(v,{scopeElement:K,referenceElement:M,floatingElement:ie})}}let V=ni(S.current);if(de&&!O||V===0||!O&&v.restTimeoutPending&&C.movementX**2+C.movementY**2<2)return;v.restTimeout.clear();function Z(){if(v.restTimeoutPending=!1,N())return;let ie=g.select("open");!v.blockMouseMove&&(!ie||O)&&H()&&g.setOpen(!0,ee(G.triggerHover,A,M))}v.pointerType==="touch"?Rl.flushSync(()=>{Z()}):O&&de?Z():(v.restTimeoutPending=!0,v.restTimeout.start(V,Z))}}},[o,v,N,j,i,g,S,H])}var El=.1,Ig=El*El,le=.5;function $n(e,t,o,n,r,i){return n>=t!=i>=t&&e<=(r-o)*(t-n)/(i-n)+o}function er(e,t,o,n,r,i,s,a,l,c){let d=!1;return $n(e,t,o,n,r,i)&&(d=!d),$n(e,t,r,i,s,a)&&(d=!d),$n(e,t,s,a,l,c)&&(d=!d),$n(e,t,l,c,o,n)&&(d=!d),d}function Lg(e,t,o){return e>=o.x&&e<=o.x+o.width&&t>=o.y&&t<=o.y+o.height}function tr(e,t,o,n,r,i){let s=Math.min(o,r),a=Math.max(o,r),l=Math.min(n,i),c=Math.max(n,i);return e>=s&&e<=a&&t>=l&&t<=c}function Ai(e={}){let{blockPointerEvents:t=!1}=e,o=new Ke,n=({x:r,y:i,placement:s,elements:a,onClose:l,nodeId:c,tree:d})=>{let m=s?.split("-")[0],u=!1,f=null,p=null,g=typeof performance<"u"?performance.now():0;function h(_,v){let w=performance.now(),R=w-g;if(f===null||p===null||R===0)return f=_,p=v,g=w,!1;let x=_-f,S=v-p,E=x*x+S*S,k=R*R*Ig;return f=_,p=v,g=w,E0)}function j(){H()||y()}if(H())return;let L=w.getBoundingClientRect(),T=R.getBoundingClientRect(),I=r>T.right-T.width/2,C=i>T.bottom-T.height/2,A=T.width>L.width,M=T.height>L.height,X=(A?L:T).left,de=(A?L:T).right,O=(M?L:T).top,V=(M?L:T).bottom;if(m==="top"&&i>=L.bottom-1||m==="bottom"&&i<=L.top+1||m==="left"&&r>=L.right-1||m==="right"&&r<=L.left+1){j();return}let Z=!1;switch(m){case"top":Z=tr(x,S,X,L.top+1,de,T.bottom-1);break;case"bottom":Z=tr(x,S,X,T.top+1,de,L.bottom-1);break;case"left":Z=tr(x,S,T.right-1,V,L.left+1,O);break;case"right":Z=tr(x,S,L.right-1,V,T.left+1,O);break;default:}if(Z)return;if(u&&!Lg(x,S,L)){j();return}if(!k&&h(x,S)){j();return}let ie=!1;switch(m){case"top":{let K=A?le/2:le*4,Q=A||I?r+K:r-K,q=A?r-K:I?r+K:r-K,$=i+le+1,ne=I||A?T.bottom-le:T.top,se=I?A?T.bottom-le:T.top:T.bottom-le;ie=er(x,S,Q,$,q,$,T.left,ne,T.right,se);break}case"bottom":{let K=A?le/2:le*4,Q=A||I?r+K:r-K,q=A?r-K:I?r+K:r-K,$=i-le,ne=I||A?T.top+le:T.bottom,se=I?A?T.top+le:T.bottom:T.top+le;ie=er(x,S,Q,$,q,$,T.left,ne,T.right,se);break}case"left":{let K=M?le/2:le*4,Q=M||C?i+K:i-K,q=M?i-K:C?i+K:i-K,$=r+le+1,ne=C||M?T.right-le:T.left,se=C?M?T.right-le:T.left:T.right-le;ie=er(x,S,ne,T.top,se,T.bottom,$,Q,$,q);break}case"right":{let K=M?le/2:le*4,Q=M||C?i+K:i-K,q=M?i-K:C?i+K:i-K,$=r-le,ne=C||M?T.left+le:T.right,se=C?M?T.left+le:T.right:T.left+le;ie=er(x,S,$,Q,$,q,ne,T.top,se,T.bottom);break}default:}ie?u||o.start(40,j):j()}};return n.__options={...e,blockPointerEvents:t},n}var or=class extends Vt{setState(t){}update(t){}set(t,o){}notifyAll(){}};var hy=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=Yr.startingStyle]="startingStyle",e[e.endingStyle=Yr.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({});var Mg={"data-popup-open":""};var Bg={"data-open":""},Hg={"data-closed":""},zg={"data-anchor-hidden":""},kl={open(e){return e?Mg:null}};var Qo={open(e){return e?Bg:Hg},anchorHidden(e){return e?zg:null}},Tl={...Qo,...Ha};function Pl(e){return po(19)?e:e?"true":void 0}var nr=b(z(),1),Oi=nr.createContext(void 0);function Eo(){return nr.useContext(Oi)?.direction??"ltr"}var qe=b(z(),1);var Dg=e=>({name:"arrow",options:e,async fn(t){let{x:o,y:n,placement:r,rects:i,platform:s,elements:a,middlewareData:l}=t,{element:c,padding:d=0,offsetParent:m="real"}=_t(e,t)||{};if(c==null)return{};let u=jn(d),f={x:o,y:n},p=Xo(r),g=Ko(p),h=await s.getDimensions(c),y=p==="y",_=y?"top":"left",v=y?"bottom":"right",w=y?"clientHeight":"clientWidth",R=i.reference[g]+i.reference[p]-f[p]-i.floating[g],x=f[p]-i.reference[p],S=m==="real"?await s.getOffsetParent?.(c):a.floating,E=a.floating[w]||i.floating[g];(!E||!await s.isElement?.(S))&&(E=a.floating[w]||i.floating[g]);let k=R/2-x/2,P=E/2-h[g]/2-1,N=Math.min(u[_],P),H=Math.min(u[v],P),j=N,L=E-h[g]-H,T=E/2-h[g]/2+k,I=zn(j,T,L),C=!l.arrow&&dt(r)!=null&&T!==I&&i.reference[g]/2-(T({...Dg(e),options:[e,t]});var Al={name:"hide",async fn(e){let{width:t,height:o,x:n,y:r}=e.rects.reference,i=t===0&&o===0&&n===0&&r===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-o>=0||s.right-t>=0||s.bottom-o>=0||s.left-t>=0||i}}}};var ko={sideX:"left",sideY:"top"};var Ol="--available-width",Nl="--available-height";function Ml(e,t,o){let n=e==="inline-start"||e==="inline-end";return{top:"top",right:n?o?"inline-start":"inline-end":"right",bottom:"bottom",left:n?o?"inline-end":"inline-start":"left"}[t]}function Il(e,t,o){let{rects:n,placement:r}=e;return{side:Ml(t,Ne(r),o),align:dt(r)||"center",anchor:{width:n.reference.width,height:n.reference.height},positioner:{width:n.floating.width,height:n.floating.height}}}function Bl(e){return jg(e,Sl)}function jg(e,t){let{anchor:o,positionMethod:n="absolute",side:r="bottom",sideOffset:i=0,align:s="center",alignOffset:a=0,collisionBoundary:l,collisionPadding:c=5,sticky:d=!1,arrowPadding:m=5,disableAnchorTracking:u=!1,inline:f,keepMounted:p=!1,floatingRootContext:g,mounted:h,collisionAvoidance:y,shift:_,nodeId:v,adaptiveOrigin:w,lazyFlip:R=!1,externalTree:x}=e,[S,E]=qe.useState(null);!h&&S!==null&&E(null);let k=y.side||"flip",P=y.align||"flip",N=y.fallbackAxisSide||"end",H=_?.crossAxis??!1,j=_?.rootBoundary,L=typeof o=="function"?o:void 0,T=Y(L),I=L?T:o,C=je(o),A=je(h),X=Eo()==="rtl",de=S||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":X?"left":"right","inline-start":X?"right":"left"}[r],O=s==="center"?de:`${de}-${s}`,V=c;typeof V=="number"?V={top:V,right:V,bottom:V,left:V}:V&&(V={top:V.top||0,right:V.right||0,bottom:V.bottom||0,left:V.left||0});let Z=1,ie=r==="bottom"?Z:0,K=r==="top"?Z:0,Q=r==="right"?Z:0,q=r==="left"?Z:0,$={boundary:l==="clipping-ancestors"?"clippingAncestors":l,padding:V},ne=qe.useRef(null),se=je(i),ze=je(a),ae=typeof i!="function"?i:0,ge=typeof a!="function"?a:0,be=[];f&&be.push(f),be.push(fi(te=>{let Je=Il(te,r,X),pt=typeof se.current=="function"?se.current(Je):se.current,Ue=typeof ze.current=="function"?ze.current(Je):ze.current;return{mainAxis:pt,crossAxis:Ue,alignmentAxis:Ue}},[ae,ge,X,r]));let Ee=P==="none"&&k!=="shift",ye=!Ee&&(d||H||k==="shift"),Kt=k==="none"?null:gi({...$,padding:{top:V.top+Z+ie,right:V.right+Z+q,bottom:V.bottom+Z+K,left:V.left+Z+Q},mainAxis:!H&&k==="flip",crossAxis:P==="flip"?"alignment":!1,fallbackAxisSideDirection:N}),rt=Ee?null:pi({...$,rootBoundary:j,mainAxis:P!=="none",crossAxis:ye,limiter:d||H?void 0:mi(te=>{if(!ne.current)return{};let{width:Je,height:pt}=ne.current.getBoundingClientRect(),Ue=Fe(Ne(te.placement)),kt=Ue==="y"?Je:pt,mt=Ue==="y"?V.left+V.right:V.top+V.bottom;return{offset:kt/2+mt/2}})},[$,d,H,j,V,P]);k==="shift"||P==="shift"||s==="center"?be.push(rt,Kt):be.push(Kt,rt),be.push(bi({...$,apply({elements:{floating:te},availableWidth:Je,availableHeight:pt,rects:Ue}){if(!A.current)return;let kt=te.style;kt.setProperty(Ol,`${Je}px`),kt.setProperty(Nl,`${pt}px`);let mt=fe(te).devicePixelRatio||1,{x:Mo,y:_n,width:yn,height:Ar}=Ue.reference,Or=(Math.round((Mo+yn)*mt)-Math.round(Mo*mt))/mt,Nr=(Math.round((_n+Ar)*mt)-Math.round(_n*mt))/mt;kt.setProperty("--anchor-width",`${Or}px`),kt.setProperty("--anchor-height",`${Nr}px`)}}),Cl(te=>({element:ne.current||Pe(te.elements.floating).createElement("div"),padding:m,offsetParent:"floating"}),[m]),{name:"transformOrigin",fn(te){let{elements:Je,middlewareData:pt,placement:Ue,rects:kt,y:mt}=te,Mo=Ne(Ue),_n=Fe(Mo),yn=ne.current,Ar=pt.arrow?.x||0,Or=pt.arrow?.y||0,Nr=yn?.clientWidth||0,Yf=yn?.clientHeight||0,Ir=Ar+Nr/2,la=Or+Yf/2,Uf=Math.abs(pt.shift?.y||0),Gf=kt.reference.height/2,Bo=typeof i=="function"?i(Il(te,r,X)):i,Kf=Uf>Bo,Xf={top:`${Ir}px calc(100% + ${Bo}px)`,bottom:`${Ir}px ${-Bo}px`,left:`calc(100% + ${Bo}px) ${la}px`,right:`${-Bo}px ${la}px`}[Mo],qf=`${Ir}px ${kt.reference.y+Gf-mt}px`;return Je.floating.style.setProperty("--transform-origin",ye&&_n==="y"&&Kf?qf:Xf),{}}},Al,w),F(()=>{!h&&g&&g.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[h,g]);let ft=qe.useMemo(()=>({elementResize:!u&&typeof ResizeObserver<"u",layoutShift:!u&&typeof IntersectionObserver<"u"}),[u]),{refs:Ot,elements:xe,x:mn,y:B,middlewareData:D,update:Se,placement:Ae,context:Nt,isPositioned:it,floatingStyles:It}=t({rootContext:g,open:p?h:void 0,placement:O,middleware:be,strategy:n,whileElementsMounted:p?void 0:(...te)=>qo(...te,ft),nodeId:v,externalTree:x}),{sideX:Ye,sideY:uo}=D.adaptiveOrigin||ko,Xt=it?n:"fixed",gn=qe.useMemo(()=>{let te;return it?w?te={position:Xt,[Ye]:mn,[uo]:B}:te={...It,position:Xt}:te={position:Xt,top:0,left:0},te[Ol]="100vw",te[Nl]="100vh",it||(te.opacity=0),te},[w,Xt,Ye,mn,uo,B,It,it]),fo=qe.useRef(null);F(()=>{if(!h)return;let te=C.current,Je=typeof te=="function"?te():te,Ue=(Ll(Je)?Je.current:Je)||null||null;Ue!==fo.current&&(Ot.setPositionReference(Ue),fo.current=Ue)},[h,Ot,I,C]),qe.useEffect(()=>{if(!h)return;let te=C.current;typeof te!="function"&&Ll(te)&&te.current!==fo.current&&(Ot.setPositionReference(te.current),fo.current=te.current)},[h,Ot,I,C]),qe.useEffect(()=>{if(p&&h&&xe.reference&&xe.floating)return qo(xe.reference,xe.floating,Se,ft)},[p,h,xe,Se,ft]);let Lt=Ne(Ae),bn=Ml(r,Lt,X),hn=dt(Ae)||"center",wn=!!D.hide?.referenceHidden;F(()=>{R&&h&&it&&Lt!==de&&E(Lt)},[R,h,it,Lt,de]);let vn=qe.useMemo(()=>({position:"absolute",top:D.arrow?.y,left:D.arrow?.x}),[D.arrow]),ca=D.arrow?.centerOffset!==0;return qe.useMemo(()=>({positionerStyles:gn,arrowStyles:vn,arrowRef:ne,arrowUncentered:ca,side:bn,align:hn,physicalSide:Lt,anchorHidden:wn,refs:Ot,context:Nt,isPositioned:it,update:Se}),[gn,vn,ne,ca,bn,hn,Lt,wn,Ot,Nt,it,Se])}function Ll(e){return e!=null&&"current"in e}function rr(e){return e==="starting"?fc:me}function Hl(e,t,{styles:o,transitionStatus:n,props:r,refs:i,hidden:s,inert:a=!1}){let l={...o};return a&&(l.pointerEvents="none"),Oe("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:l},rr(n),r],stateAttributesMapping:Qo})}var zl=b(z(),1);var Ni=zl.forwardRef(function(t,o){let{render:n,className:r,disabled:i=!1,focusableWhenDisabled:s=!1,nativeButton:a=!0,style:l,...c}=t,{getButtonProps:d,buttonRef:m}=Ya({disabled:i,focusableWhenDisabled:s,native:a});return Oe("button",t,{state:{disabled:i},ref:[o,m],props:[c,d]})});var Ce=b(z(),1),Kl=b(Ht(),1);var Dl=b(z(),1);function jl(e){let[t,o]=Dl.useState({current:e,previous:null});return Object.is(e,t.current)||o({current:e,previous:t.current}),t.previous}var To=b(z(),1);function Ii(e){let t=Le(e),o=parseFloat(t.width)||0,n=parseFloat(t.height)||0,r=he(e),i=r?e.offsetWidth:o,s=r?e.offsetHeight:n;return(jt(o)!==i||jt(n)!==s)&&(o=i,n=s),{width:o,height:n}}function Vl(e){let{popupElement:t,positionerElement:o,content:n,mounted:r,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:l}=e,c=vo(t,!0),d=bo(),m=To.useRef(null),u=To.useRef(!0),f=To.useRef(Ge),p=Y(i),g=Y(s),h=To.useMemo(()=>Fg(a,l),[a,l]);F(()=>{if(!r){f.current=Ge,u.current=!0,m.current=null;return}if(!t||!o)return;f.current=Fl(t,h),Li(t,"auto");let y=sr(t,"position","static"),_=sr(t,"transform","none"),v=sr(t,"scale","1"),w=Fl(o,{"--available-width":"max-content","--available-height":"max-content"});function R(){y(),_(),w()}function x(){R(),v()}if(p?.(),u.current||m.current===null){ir(o,"max-content");let P=Ii(t);return m.current=P,ir(o,P),x(),g?.(null,P),u.current=!1,()=>{f.current(),f.current=Ge}}ir(o,"max-content");let S=m.current,E=Ii(t);m.current=E,Li(t,S),x(),g?.(S,E),ir(o,E);let k=new AbortController;return d.request(()=>{Li(t,E),c(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},k.signal)}),()=>{k.abort(),d.cancel(),f.current(),f.current=Ge}},[n,t,o,c,d,r,p,g,h])}function Fg(e,t){let o=e==="top",n=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!o&&!n?me:{position:"absolute",[o?"bottom":"top"]:"0",[n?"right":"left"]:"0"}}function sr(e,t,o){let n=e.style.getPropertyValue(t);return e.style.setProperty(t,o),()=>{e.style.setProperty(t,n)}}function Fl(e,t){let o=[];for(let[n,r]of Object.entries(t))o.push(sr(e,n,r));return o.length?()=>{o.forEach(n=>n())}:Ge}function Li(e,t){let o=t==="auto"?"auto":`${t.width}px`,n=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",o),e.style.setProperty("--popup-height",n)}function ir(e,t){let o=t==="max-content"?"max-content":`${t.width}px`,n=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",o),e.style.setProperty("--positioner-height",n)}var Wl=b(z(),1);var Yl=b(W(),1),ar=function(t){let{direction:o="ltr"}=t,n=Wl.useMemo(()=>({direction:o}),[o]);return(0,Yl.jsx)(Oi.Provider,{value:n,children:t.children})};var Ul={name:"adaptiveOrigin",async fn(e){let{x:t,y:o,rects:{floating:n},elements:{floating:r},platform:i,strategy:s,placement:a}=e,l=fe(r),c=l.getComputedStyle(r);if(!(c.transitionDuration!=="0s"&&c.transitionDuration!==""))return{x:t,y:o,data:ko};let m=await i.getOffsetParent?.(r),u={width:0,height:0};if(s==="fixed"&&l?.visualViewport)u={width:l.visualViewport.width,height:l.visualViewport.height};else if(m===l){let _=Pe(r);u={width:_.documentElement.clientWidth,height:_.documentElement.clientHeight}}else await i.isElement?.(m)&&(u=await i.getDimensions(m));let f=Ne(a),p=t,g=o;f==="left"&&(p=u.width-(t+n.width)),f==="top"&&(g=u.height-(o+n.height));let h=f==="left"?"right":ko.sideX,y=f==="top"?"bottom":ko.sideY;return{x:p,y:g,data:{sideX:h,sideY:y}}}};var Po=b(W(),1),Xl={activationDirection:e=>e?{"data-activation-direction":e}:null};function ql(e){let{store:t,side:o,children:n}=e,r=Eo(),i=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),a=t.useState("open"),l=t.useState("payload"),c=t.useState("mounted"),d=t.useState("popupElement"),m=t.useState("positionerElement"),u=jl(a?i:null),f=Yg(s,l),p=Ce.useRef(null),[g,h]=Ce.useState(null),[y,_]=Ce.useState(null),v=Ce.useRef(null),w=Ce.useRef(null),R=vo(v,!0),x=bo(),S=Ce.useRef(null),[E,k]=Ce.useState(null),[P,N]=Ce.useState(!1);F(()=>(t.set("adaptiveOrigin",Ul),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let H=Y(()=>{v.current?.style.setProperty("animation","none"),v.current?.style.setProperty("transition","none"),w.current?.style.setProperty("display","none")}),j=Y(M=>{v.current?.style.removeProperty("animation"),v.current?.style.removeProperty("transition"),w.current?.style.removeProperty("display"),M&&k(M)}),L=Y(()=>{S.current?.abort();let M=new AbortController;S.current=M,R(()=>{h(null),k(null),p.current=null},M.signal)}),T=Ce.useRef(null);F(()=>{(!a||!c)&&(T.current=null)},[a,c]),F(()=>{if(i&&u&&i!==u&&T.current!==i&&p.current){h(p.current),N(!0);let M=Wg(u,i);_(M),T.current=i}},[i,u]),F(()=>{g!=null&&(S.current?.abort(),N(!0),x.request(()=>{Kl.flushSync(()=>{N(!1)}),L()}))},[f,g,L,x]),F(()=>{let M=v.current;if(!M)return;let X=Pe(M).createElement("div");for(let de of Array.from(M.childNodes))X.appendChild(de.cloneNode(!0));p.current=X});let I=g!=null,C;I?C=(0,Po.jsxs)(Ce.Fragment,{children:[(0,Po.jsx)("div",{"data-previous":!0,inert:Pl(!0),ref:w,style:{...E?{"--popup-width":`${E.width}px`,"--popup-height":`${E.height}px`}:null,position:"absolute"},"data-ending-style":P?void 0:""},"previous"),(0,Po.jsx)("div",{"data-current":!0,ref:v,"data-starting-style":P?"":void 0,children:n},f)]}):C=(0,Po.jsx)("div",{"data-current":!0,ref:v,children:n},f),F(()=>{let M=w.current;!M||!g||M.replaceChildren(...Array.from(g.childNodes))},[g]),Vl({popupElement:d,positionerElement:m,mounted:c,content:l,onMeasureLayout:H,onMeasureLayoutComplete:j,side:o,direction:r});let A={activationDirection:Vg(y),transitioning:I};return{children:C,state:A}}function Vg(e){if(e)return`${Gl(e.horizontal,5,"right","left")} ${Gl(e.vertical,5,"down","up")}`}function Gl(e,t,o,n){return e>t?o:e<-t?n:""}function Wg(e,t){let o=e.getBoundingClientRect(),n=t.getBoundingClientRect(),r={x:o.left+o.width/2,y:o.top+o.height/2},i={x:n.left+n.width/2,y:n.top+n.height/2};return{horizontal:i.x-r.x,vertical:i.y-r.y}}function Yg(e,t){let[o,n]=Ce.useState(0),r=Ce.useRef(e),i=Ce.useRef(t),s=Ce.useRef(!1);return F(()=>{let a=r.current,l=i.current,c=e!==a,d=t!==l;c?(n(m=>m+1),s.current=!d):s.current&&d&&(n(m=>m+1),s.current=!1),r.current=e,i.current=t},[e,t]),`${e??"current"}-${o}`}var cr=b(z(),1),Zl=b(Ht(),1);var Ql=b(W(),1),Jl=cr.forwardRef(function(t,o){let{children:n,container:r,className:i,render:s,style:a,...l}=t,{node:c,subtree:d}=bc({container:r,ref:o,componentProps:t,elementProps:l});return!d&&!c?null:(0,Ql.jsxs)(cr.Fragment,{children:[d,c&&Zl.createPortal(n,c)]})});var tt={};Mt(tt,{Arrow:()=>hd,Handle:()=>$o,Popup:()=>gd,Portal:()=>ud,Positioner:()=>pd,Provider:()=>vd,Root:()=>rd,Trigger:()=>cd,Viewport:()=>yd,createHandle:()=>xd});var Co=b(z(),1);var lr=b(z(),1),Mi=lr.createContext(void 0);function et(e){let t=lr.useContext(Mi);if(t===void 0&&!e)throw new Error(De(72));return t}var $l=b(z(),1);var ed={..._l,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},dr=class extends Vt{constructor(t,o,n){let r=new io;super(od(t,r,o,n),nd(r),ed)}setOpen=(t,o)=>{dl(this,t,o,{extraState:{openChangeReason:o.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,ee(G.triggerPress,t))}};function td(){let e=new io,t=new or(Object.freeze(od(void 0,e)),Object.freeze(nd(e)),ed);return Object.assign(t,{setOpen:Ge,cancelPendingOpen:Ge})}function od(e,t,o,n=!1){let r={...hl(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e};return r.floatingRootContext=wl(t,o,n),r}function nd(e){return{popupRef:$l.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var Jo=b(W(),1),rd=_i(function(t){let{disabled:o=!1,defaultOpen:n=!1,open:r,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:l,onOpenChangeComplete:c,handle:d,triggerId:m,defaultTriggerId:u=null,children:f}=t,p=cl((N,H)=>new dr({open:n,openProp:r,activeTriggerId:u,triggerIdProp:m},N,H));p.useControlledProp("openProp",r),p.useControlledProp("triggerIdProp",m),p.useContextCallback("onOpenChange",l),p.useContextCallback("onOpenChangeComplete",c);let g=p.useState("open"),h=!o&&g,y=p.useState("activeTriggerId"),_=p.useState("mounted"),v=p.useState("payload");p.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i,disabled:o}),fl(p,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:w,transitionStatus:R}=pl(h,p),x=p.useState("isInstantPhase"),S=p.useState("instantType"),E=p.useState("lastOpenChangeReason"),k=Co.useRef(null);F(()=>{g&&o&&p.setOpen(!1,ee(G.disabled))},[g,o,p]),F(()=>{R==="ending"&&E===G.none||R!=="ending"&&x?(S!=="delay"&&(k.current=S),p.set("instantType","delay")):k.current!==null&&(p.set("instantType",k.current),k.current=null)},[R,x,E,S,p]),F(()=>{h&&y==null&&p.set("payload",void 0)},[p,y,h]),Co.useImperativeHandle(a,()=>({unmount:w,close:()=>p.setOpen(!1,ee(G.imperativeAction))}),[w,p]);let P=h||_||!o&&s!=="none";return(0,Jo.jsxs)(Mi.Provider,{value:p,children:[d&&(0,Jo.jsx)(ll,{handle:d,store:p}),P&&(0,Jo.jsx)(Ug,{store:p,disabled:o,trackCursorAxis:s}),typeof f=="function"?f({payload:v}):f]})});function Ug({store:e,disabled:t,trackCursorAxis:o}){let n=e.useState("floatingRootContext"),r=ai(n,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=si(n,{enabled:!t&&o!=="none",axis:o==="none"?void 0:o}),s=Co.useMemo(()=>ve(i.reference,r.reference),[i.reference,r.reference]);return ml(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:r.floating??me}),null}var fr=b(z(),1);var ur=b(z(),1),Bi=ur.createContext(void 0);function id(){return ur.useContext(Bi)}var ad="data-base-ui-tooltip-trigger";function sd(e){if("composedPath"in e){let o=e.composedPath();for(let n=0;nh.select("transitionStatus")==="ending",shouldOpen(){return!X.current}}),Q=Ei(w,{enabled:!I}).reference,q=ae=>{let ge=X.current,be=sd(ae),Ee=ie(be),ye=R.current,Kt=ye&&be&&re(ye,be);if(Ee&&h.select("open")&&h.select("lastOpenChangeReason")===G.triggerHover){h.setOpen(!1,ee(G.triggerHover,ae));return}if(ge&&!Ee&&Kt&&!C.current&&!h.select("open")&&ye&&Pt(O.current)){let rt=()=>{!X.current&&!C.current&&!h.select("open")&&h.setOpen(!0,ee(G.triggerHover,ae,ye))},ft=V();ft===0?(de.clear(),rt()):de.start(ft,rt)}},$=h.useState("triggerProps",k);return Oe("button",t,{state:{open:v},ref:[o,E,R],props:[K,Q,k||A!=="none"?$:void 0,{onMouseOver(ae){q(ae.nativeEvent)},onFocus(ae){Z(sd(ae.nativeEvent))&&ae.preventBaseUIHandler()},onMouseLeave(){X.current=!1,de.clear(),O.current=void 0},onPointerEnter(ae){O.current=ae.pointerType},onPointerDown(ae){O.current=ae.pointerType,h.set("closeOnClick",d),d&&!h.select("open")&&h.cancelPendingOpen(ae.nativeEvent)},onClick(ae){d&&!h.select("open")&&h.cancelPendingOpen(ae.nativeEvent)},id:y,"data-trigger-disabled":I?"":void 0,[ad]:I?void 0:""},f],stateAttributesMapping:kl})});var dd=b(z(),1);var pr=b(z(),1),Hi=pr.createContext(void 0);function ld(){let e=pr.useContext(Hi);if(e===void 0)throw new Error(De(70));return e}var zi=b(W(),1),ud=dd.forwardRef(function(t,o){let{keepMounted:n=!1,...r}=t;return et().useState("mounted")||n?(0,zi.jsx)(Hi.Provider,{value:n,children:(0,zi.jsx)(Jl,{ref:o,...r})}):null});var gr=b(z(),1);var mr=b(z(),1),Di=mr.createContext(void 0);function Ao(){let e=mr.useContext(Di);if(e===void 0)throw new Error(De(71));return e}var fd=b(W(),1),pd=gr.forwardRef(function(t,o){let{render:n,className:r,anchor:i,positionMethod:s="absolute",side:a="top",align:l="center",sideOffset:c=0,alignOffset:d=0,collisionBoundary:m="clipping-ancestors",collisionPadding:u=5,arrowPadding:f=5,sticky:p=!1,disableAnchorTracking:g=!1,collisionAvoidance:h=pc,style:y,..._}=t,v=et(),w=ld(),R=v.useState("open"),x=v.useState("mounted"),S=v.useState("trackCursorAxis"),E=v.useState("disableHoverablePopup"),k=v.useState("floatingRootContext"),P=v.useState("instantType"),N=v.useState("transitionStatus"),H=v.useState("adaptiveOrigin"),j=Bl({anchor:i,positionMethod:s,floatingRootContext:k,mounted:x,side:a,sideOffset:c,align:l,alignOffset:d,collisionBoundary:m,collisionPadding:u,sticky:p,arrowPadding:f,disableAnchorTracking:g,keepMounted:w,collisionAvoidance:h,adaptiveOrigin:H}),L=gr.useMemo(()=>({open:R,side:j.side,align:j.align,anchorHidden:j.anchorHidden,instant:S!=="none"?"tracking-cursor":P}),[R,j.side,j.align,j.anchorHidden,S,P]),T=Hl(t,L,{styles:j.positionerStyles,transitionStatus:N,props:_,refs:[o,v.useStateSetter("positionerElement")],hidden:!x,inert:!R||S==="both"||E});return(0,fd.jsx)(Di.Provider,{value:j,children:T})});var md=b(z(),1);var gd=md.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=et(),{side:l,align:c}=Ao(),d=a.useState("open"),m=a.useState("instantType"),u=a.useState("transitionStatus"),f=a.useState("popupProps"),p=a.useState("floatingRootContext"),g=a.useState("disabled"),h=a.useState("closeDelay");In({open:d,ref:a.context.popupRef,onComplete(){d&&a.context.onOpenChangeComplete?.(!0)}}),Pi(p,{enabled:!g,closeDelay:h});let y=a.useStateSetter("popupElement");return Oe("div",t,{state:{open:d,side:l,align:c,instant:m,transitionStatus:u},ref:[o,a.context.popupRef,y],props:[al,f,rr(u),s],stateAttributesMapping:Tl})});var bd=b(z(),1);var hd=bd.forwardRef(function(t,o){let{render:n,className:r,style:i,...s}=t,a=et(),{arrowRef:l,side:c,align:d,arrowUncentered:m,arrowStyles:u}=Ao(),f=a.useState("open"),p=a.useState("instantType");return Oe("div",t,{state:{open:f,side:c,align:d,uncentered:m,instant:p},ref:[o,l],props:[{style:u,"aria-hidden":!0},s],stateAttributesMapping:Qo})});var wd=b(z(),1);var ji=b(W(),1),vd=function(t){let{delay:o,closeDelay:n,timeout:r=400}=t,i=wd.useMemo(()=>({open:o,close:n}),[o,n]);return(0,ji.jsx)(Bi.Provider,{value:o,children:(0,ji.jsx)(ri,{delay:i,timeoutMs:r,children:t.children})})};var _d=b(z(),1);var yd=_d.forwardRef(function(t,o){let{render:n,className:r,style:i,children:s,...a}=t,l=et(),c=Ao(),d=l.useState("instantType"),{children:m,state:u}=ql({store:l,side:c.side,children:s}),f={activationDirection:u.activationDirection,transitioning:u.transitioning,instant:d};return Oe("div",t,{state:f,ref:o,props:[a,{children:m}],stateAttributesMapping:Xl})});var $o=class extends Gn{constructor(){super(td(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function xd(){return new $o}function ot(e){return Oe(e.defaultTagName??"div",e,e)}var Ed=b(ce(),1),Fi="data-wp-hash";function Vi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&qg(document)),e.__wpStyleRuntime}function Xg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Fi}]`))if(o.getAttribute(Fi)===t)return!0;return!1}function kd(e,t,o){if(!e.head)return;let n=Vi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Xg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Fi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function qg(e){let t=Vi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)kd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Td(e,t){let o=Vi();o.styles.set(e,t);for(let n of o.documents.keys())kd(n,e,t)}typeof process>"u",Td("3167e7d116",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{text-wrap:pretty;margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Sd={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",Td("e8e31009f5","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}");var Rd={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a",ol:"c59a0ebebd71fa4a__ol",li:"_46b5cb0c8e24e8c9__li"},We=(0,Ed.forwardRef)(function({variant:t="body-md",render:o,className:n,...r},i){return ot({render:o,defaultTagName:"span",ref:i,props:ve(r,{className:J(Sd.text,Rd.heading,Rd.p,Sd[t],n)})})});var Od=b(W(),1),Wi="data-wp-hash";function Yi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Qg(document)),e.__wpStyleRuntime}function Zg(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Wi}]`))if(o.getAttribute(Wi)===t)return!0;return!1}function Ad(e,t,o){if(!e.head)return;let n=Yi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Zg(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Wi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Qg(e){let t=Yi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Ad(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Jg(e,t){let o=Yi();o.styles.set(e,t);for(let n of o.documents.keys())Ad(n,e,t)}typeof process>"u",Jg("59353631d1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._96e6251aad1a6136__badge{border-radius:var(--wpds-border-radius-lg,8px);padding-block:var(--wpds-dimension-padding-xs,4px);padding-inline:var(--wpds-dimension-padding-sm,8px)}._99f7158cb520f750__is-high-intent{background-color:var(--wpds-color-background-surface-error,#f7e6e3);color:var(--wpds-color-foreground-content-error,#470000)}.c20ebef2365bc8b7__is-medium-intent{background-color:var(--wpds-color-background-surface-warning,#fae8c8);color:var(--wpds-color-foreground-content-warning,#2e1900)}._365e1626c6202e52__is-low-intent{background-color:var(--wpds-color-background-surface-caution,#ffea8f);color:var(--wpds-color-foreground-content-caution,#281d00)}._33f8198127ddf4ef__is-stable-intent{background-color:var(--wpds-color-background-surface-success,#ccf4d2);color:var(--wpds-color-foreground-content-success,#002900)}._04c1aca8fc449412__is-informational-intent{background-color:var(--wpds-color-background-surface-info,#e0ebf8);color:var(--wpds-color-foreground-content-info,#001b4f)}._90726e69d495ec19__is-draft-intent{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);color:var(--wpds-color-foreground-content-neutral,#1e1e1e)}._898f4a544993bd39__is-none-intent{background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);padding-block:calc(var(--wpds-dimension-padding-xs, 4px) - var(--wpds-border-width-xs, 1px));padding-inline:calc(var(--wpds-dimension-padding-sm, 8px) - var(--wpds-border-width-xs, 1px))}}}");var Pd={badge:"_96e6251aad1a6136__badge","is-high-intent":"_99f7158cb520f750__is-high-intent","is-medium-intent":"c20ebef2365bc8b7__is-medium-intent","is-low-intent":"_365e1626c6202e52__is-low-intent","is-stable-intent":"_33f8198127ddf4ef__is-stable-intent","is-informational-intent":"_04c1aca8fc449412__is-informational-intent","is-draft-intent":"_90726e69d495ec19__is-draft-intent","is-none-intent":"_898f4a544993bd39__is-none-intent"},Ui=(0,Cd.forwardRef)(function({intent:t="none",className:o,...n},r){return(0,Od.jsx)(We,{ref:r,className:J(Pd.badge,Pd[`is-${t}-intent`],o),...n,variant:"body-sm"})});var Qd=b(ce(),1);var Bd=b(ce(),1);var Ki="data-wp-hash";function Xi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&eb(document)),e.__wpStyleRuntime}function $g(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ki}]`))if(o.getAttribute(Ki)===t)return!0;return!1}function Id(e,t,o){if(!e.head)return;let n=Xi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if($g(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ki,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function eb(e){let t=Xi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Id(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function tb(e,t){let o=Xi();o.styles.set(e,t);for(let n of o.documents.keys())Id(n,e,t)}typeof process>"u",tb("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var Nd={slot:"_11fc52b637ff8a7e__slot"},Ld="data-wp-compat-overlay-slot";function ob(){return typeof document>"u"?null:document}function nb(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var xt=null;function Gi(e){return e.setAttribute("aria-hidden","false"),e}function rb(e){let t=e.createElement("div");return t.setAttribute(Ld,""),Nd.slot&&t.classList.add(Nd.slot),e.body.appendChild(t),t}function Md(){if(typeof window>"u"||!nb()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=ob();if(!e||!e.body)return;if(xt&&xt.ownerDocument===e&&xt.isConnected)return Gi(xt);let t=e.querySelector(`[${Ld}]`);return t instanceof HTMLDivElement?(xt=Gi(t),xt):(xt?.isConnected&&xt.remove(),xt=Gi(rb(e)),xt)}var Hd=b(W(),1),zd=(0,Bd.forwardRef)(function({container:t,...o},n){return(0,Hd.jsx)(tt.Portal,{container:t??Md(),...o,ref:n})});var Dd=b(ce(),1),Vd=b(W(),1),qi="data-wp-hash";function Zi(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&sb(document)),e.__wpStyleRuntime}function ib(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${qi}]`))if(o.getAttribute(qi)===t)return!0;return!1}function jd(e,t,o){if(!e.head)return;let n=Zi(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(ib(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(qi,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function sb(e){let t=Zi();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)jd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Fd(e,t){let o=Zi();o.styles.set(e,t);for(let n of o.documents.keys())jd(n,e,t)}typeof process>"u",Fd("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var ab={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Fd("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var cb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Wd=(0,Dd.forwardRef)(function({align:t="center",className:o,side:n="top",sideOffset:r=4,...i},s){return(0,Vd.jsx)(tt.Positioner,{ref:s,align:t,side:n,sideOffset:r,...i,className:J(ab["box-sizing"],cb.positioner,o)})});var Yd=b(ce(),1);function Qi(e,t,o){return(0,Yd.cloneElement)(e??t,{children:o})}var lb=b(Gd(),1);var Xd=b(Ji(),1),{lock:M4,unlock:qd}=(0,Xd.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function db(){let e=lb;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return qd(e.privateApis).ThemeProvider}var Zd=db();var en=b(W(),1),$i="data-wp-hash";function es(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&fb(document)),e.__wpStyleRuntime}function ub(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${$i}]`))if(o.getAttribute($i)===t)return!0;return!1}function Jd(e,t,o){if(!e.head)return;let n=es(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(ub(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute($i,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function fb(e){let t=es();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Jd(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function pb(e,t){let o=es();o.styles.set(e,t);for(let n of o.documents.keys())Jd(n,e,t)}typeof process>"u",pb("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var mb={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},gb={background:"#1e1e1e"},ts=(0,Qd.forwardRef)(function({portal:t,positioner:o,children:n,className:r,...i},s){let a=(0,en.jsx)(Zd,{color:gb,children:(0,en.jsx)(tt.Popup,{ref:s,className:J(mb.popup,r),...i,children:n})}),l=Qi(o,(0,en.jsx)(Wd,{}),a);return Qi(t,(0,en.jsx)(zd,{}),l)});var $d=b(ce(),1),eu=b(W(),1),os=(0,$d.forwardRef)(function(t,o){return(0,eu.jsx)(tt.Trigger,{ref:o,...t})});var tu=b(st(),1),ou=b(W(),1);function nu({children:e}){return(0,ou.jsx)(ar,{direction:(0,tu.isRTL)()?"rtl":"ltr",children:e})}var ns=b(W(),1);function rs(e){return(0,ns.jsx)(nu,{children:(0,ns.jsx)(tt.Root,{...e})})}var ru=b(ce(),1),iu=b(st(),1),Oo=b(W(),1),is="data-wp-hash";function ss(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&wb(document)),e.__wpStyleRuntime}function hb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${is}]`))if(o.getAttribute(is)===t)return!0;return!1}function su(e,t,o){if(!e.head)return;let n=ss(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(hb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(is,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function wb(e){let t=ss();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)su(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function hr(e,t){let o=ss();o.styles.set(e,t);for(let n of o.documents.keys())su(n,e,t)}typeof process>"u",hr("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var vb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",hr("08122b3d53","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var _b={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",hr("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var br={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",hr("e8e31009f5","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}");var yb={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a",ol:"c59a0ebebd71fa4a__ol",li:"_46b5cb0c8e24e8c9__li"},so=(0,ru.forwardRef)(function({children:t,variant:o="default",tone:n="brand",openInNewTab:r=!1,target:i,render:s,className:a,...l},c){let d=r||/^_blank$/i.test(i??"");return ot({render:s,defaultTagName:"a",ref:c,props:ve(l,{className:J(yb.a,vb["box-sizing"],_b["outset-ring--focus-except-active"],o!=="unstyled"&&br.link,o!=="unstyled"&&br[`is-${n}`],o==="unstyled"&&br["is-unstyled"],a),target:i??(r?"_blank":void 0),children:(0,Oo.jsxs)(Oo.Fragment,{children:[t,d&&(0,Oo.jsx)("span",{className:br["link-icon"],role:"img","aria-label":(0,iu.__)("(opens in a new tab)")})]})})})});var wr=b(ao(),1),as=b(W(),1),cs=(0,as.jsx)(wr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,as.jsx)(wr.Path,{d:"M12 8L12 13M12 14.5L12 16M4.75 12C4.75 7.99593 7.99594 4.75 12 4.75C16.0041 4.75 19.25 7.99594 19.25 12C19.25 16.0041 16.0041 19.25 12 19.25C7.99594 19.25 4.75 16.0041 4.75 12Z",strokeLinejoin:"round",vectorEffect:"non-scaling-stroke"})});var vr=b(ao(),1),ls=b(W(),1),ds=(0,ls.jsx)(vr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,ls.jsx)(vr.Path,{d:"M7.75 16.25L16.25 7.75M16.25 16.25L7.75 7.75",vectorEffect:"non-scaling-stroke"})});var _r=b(ao(),1),us=b(W(),1),fs=(0,us.jsx)(_r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,us.jsx)(_r.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M12.218 5.377a.25.25 0 0 0-.436 0l-7.29 12.96a.25.25 0 0 0 .218.373h14.58a.25.25 0 0 0 .218-.372l-7.29-12.96Zm-1.743-.735c.669-1.19 2.381-1.19 3.05 0l7.29 12.96a1.75 1.75 0 0 1-1.525 2.608H4.71a1.75 1.75 0 0 1-1.525-2.608l7.29-12.96ZM12.75 17.46h-1.5v-1.5h1.5v1.5Zm-1.5-3h1.5v-5h-1.5v5Z"})});var yr=b(ao(),1),ps=b(W(),1),ms=(0,ps.jsx)(yr.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,ps.jsx)(yr.Path,{d:"M12 16V11M12 9.5V8M19.25 12C19.25 16.0041 16.0041 19.25 12 19.25C7.99594 19.25 4.75 16.0041 4.75 12C4.75 7.99594 7.99594 4.75 12 4.75C16.0041 4.75 19.25 7.99594 19.25 12Z",strokeLinejoin:"round",vectorEffect:"non-scaling-stroke"})});var tn=b(ao(),1),on=b(W(),1),gs=(0,on.jsxs)(tn.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:[(0,on.jsx)(tn.Path,{d:"M12 19.25C16.0041 19.25 19.25 16.0041 19.25 12C19.25 7.99594 16.0041 4.75 12 4.75C7.99594 4.75 4.75 7.99594 4.75 12C4.75 16.0041 7.99594 19.25 12 19.25Z",strokeLinejoin:"round",vectorEffect:"non-scaling-stroke"}),(0,on.jsx)(tn.Path,{d:"M9 12L11 14L15 10",vectorEffect:"non-scaling-stroke"})]});var cu=b(ce(),1),lu=b(ao(),1),du=b(W(),1),co=(0,cu.forwardRef)(function({icon:t,size:o=24,style:n,...r},i){let s=t.props.style||n?{...t.props.style,...n}:void 0;return(0,du.jsx)(lu.SVG,{ref:i,...t.props,...r,...s?{style:s}:{},width:o,height:o})});var nn=b(ce(),1),Sr=b(st(),1);var uu=b(ce(),1),bs="data-wp-hash";function hs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Sb(document)),e.__wpStyleRuntime}function xb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${bs}]`))if(o.getAttribute(bs)===t)return!0;return!1}function fu(e,t,o){if(!e.head)return;let n=hs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(xb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(bs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Sb(e){let t=hs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)fu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Rb(e,t){let o=hs();o.styles.set(e,t);for(let n of o.documents.keys())fu(n,e,t)}typeof process>"u",Rb("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var Eb={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},ws=(0,uu.forwardRef)(function({render:t,...o},n){return ot({render:t,ref:n,props:ve({className:Eb["visually-hidden"]},o,{"data-visually-hidden":""})})});var xr=b(W(),1);function pu({"aria-describedby":e,"aria-keyshortcuts":t,shortcut:o}){let n=(0,nn.useId)(),r=o?n:void 0,i=[e,r].filter(Boolean).join(" ");return{descriptionId:r,targetProps:{"aria-describedby":i||void 0,"aria-keyshortcuts":o?.ariaKeyShortcut??t}}}var mu=(0,nn.forwardRef)(function({descriptionId:t,shortcut:o},n){return(0,xr.jsx)(ws,{id:t,"aria-hidden":"true",render:(0,xr.jsx)("span",{ref:n}),children:(0,Sr.sprintf)((0,Sr.__)("Keyboard shortcut: %s"),o.label??o.ariaKeyShortcut)})}),gu=(0,nn.forwardRef)(function({className:t,shortcut:o},n){return(0,xr.jsx)("span",{ref:n,"aria-hidden":"true",className:t,dir:"ltr",children:o.displayShortcut})});var Rr=b(ce(),1),bu=b(st(),1),wu=b(W(),1);import{speak as kb}from"@wordpress/a11y";var vs="data-wp-hash";function _s(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Pb(document)),e.__wpStyleRuntime}function Tb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${vs}]`))if(o.getAttribute(vs)===t)return!0;return!1}function hu(e,t,o){if(!e.head)return;let n=_s(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Tb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Pb(e){let t=_s();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)hu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Er(e,t){let o=_s();o.styles.set(e,t);for(let n of o.documents.keys())hu(n,e,t)}typeof process>"u",Er("effc4e3032",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var rn={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"};typeof process>"u",Er("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Cb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Er("08122b3d53","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var Ab={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",Er("e8e31009f5","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}");var Ob={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a",ol:"c59a0ebebd71fa4a__ol",li:"_46b5cb0c8e24e8c9__li"},vu=(0,Rr.forwardRef)(function({tone:t="brand",variant:o="solid",size:n="default",className:r,focusableWhenDisabled:i=!0,disabled:s,loading:a,loadingAnnouncement:l=(0,bu.__)("Loading"),children:c,...d},m){let u=J(Ob.button,Cb["box-sizing"],Ab["outset-ring--focus-except-active"],o!=="unstyled"&&rn.button,rn[`is-${t}`],rn[`is-${o}`],rn[`is-${n}`],a&&rn["is-loading"],r);return(0,Rr.useEffect)(()=>{a&&l&&kb(l)},[a,l]),(0,wu.jsx)(Ni,{ref:m,className:u,focusableWhenDisabled:i,disabled:s??a,...d,children:c})});var _u=b(ce(),1);var xu=b(W(),1),ys="data-wp-hash";function xs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Ib(document)),e.__wpStyleRuntime}function Nb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${ys}]`))if(o.getAttribute(ys)===t)return!0;return!1}function yu(e,t,o){if(!e.head)return;let n=xs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Nb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(ys,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Ib(e){let t=xs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)yu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Lb(e,t){let o=xs();o.styles.set(e,t);for(let n of o.documents.keys())yu(n,e,t)}typeof process>"u",Lb("effc4e3032",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._97b0fc33c028be1a__button,.abbb272e2ce49bd6__is-unstyled{appearance:none;padding:0}._97b0fc33c028be1a__button{--wp-ui-button-font-weight:var(--wpds-typography-font-weight-emphasis,600);--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-strong,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-strong-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 93%,#000));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand-strong,#fff);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-strong-active,#fff);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-strong-disabled,#8d8d8d);--wp-ui-button-padding-block:var(--wpds-dimension-padding-xs,4px);--wp-ui-button-padding-inline:var(--wpds-dimension-padding-md,12px);--wp-ui-button-height:var(--wpds-dimension-size-lg,40px);--wp-ui-button-aspect-ratio:auto;--wp-ui-button-font-size:var(--wpds-typography-font-size-md,13px);--wp-ui-button-min-width:calc(4ch + var(--wp-ui-button-padding-inline)*2);--wp-ui-button-icon-margin:calc((var(--wpds-dimension-size-2xs, 16px) - var(--wpds-dimension-size-sm, 24px))/2);--wp-ui-button-border-color:var(--wp-ui-button-background-color);--wp-ui-button-border-color-active:var(--wp-ui-button-background-color-active);--wp-ui-button-border-color-disabled:var(--wp-ui-button-background-color-disabled);--_gcd-button-font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);--_gcd-button-font-size:var(--wp-ui-button-font-size);--_gcd-button-font-weight:var(--wp-ui-button-font-weight);align-items:center;aspect-ratio:var(--wp-ui-button-aspect-ratio);background-clip:border-box;background-color:var(--wp-ui-button-background-color);border-color:var(--wp-ui-button-border-color);border-radius:var(--wpds-border-radius-sm,2px);border-style:solid;border-width:1px;color:var(--wp-ui-button-foreground-color);display:inline-flex;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wp-ui-button-font-size);font-weight:var(--wp-ui-button-font-weight);gap:var(--wpds-dimension-gap-sm,8px);justify-content:center;line-height:var(--wpds-typography-line-height-sm,20px);max-width:100%;min-height:var(--wp-ui-button-height);min-width:var(--wp-ui-button-min-width);overflow-wrap:anywhere;padding-block:var(--wp-ui-button-padding-block);padding-inline:var(--wp-ui-button-padding-inline);position:relative;text-align:center;text-decoration:none;&:not([data-disabled]){cursor:var(--wpds-cursor-control,pointer)}@media not (prefers-reduced-motion){transition:color .1s ease-out;*{transition:opacity .1s ease-out}}&[href]{cursor:pointer}[href]{color:inherit;text-decoration:inherit}&:not([data-disabled]):is(:hover,:active,:focus){background-color:var(--wp-ui-button-background-color-active);border-color:var(--wp-ui-button-border-color-active);color:var(--wp-ui-button-foreground-color-active)}&[data-disabled]:not(._914b42f315c0e580__is-loading){background-color:var(--wp-ui-button-background-color-disabled);border-color:var(--wp-ui-button-border-color-disabled);color:var(--wp-ui-button-foreground-color-disabled);@media (forced-colors:active){border-bottom-color:GrayText;border-left-color:GrayText;border-right-color:GrayText;border-top-color:GrayText;color:GrayText}}&:before{aspect-ratio:1;border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid;border-block-end-color:transparent;border-block-start-color:var(--wp-ui-button-foreground-color);border-inline-end-color:var(--wp-ui-button-foreground-color);border-inline-start-color:transparent;border-radius:50%;box-sizing:border-box;content:"";display:block;height:var(--wp-ui-button-font-size);left:50%;opacity:0;pointer-events:none;position:absolute;top:50%;transform:translate(-50%,-50%);@media not (prefers-reduced-motion){transition:opacity .1s ease-out}@media (forced-colors:active){border-block-end-style:none;border-bottom-color:ButtonText;border-inline-start-style:none;border-left-color:ButtonText;border-right-color:ButtonText;border-top-color:ButtonText}}}._908205475f9f2a92__is-small{--wp-ui-button-padding-block:0px;--wp-ui-button-padding-inline:var(--wpds-dimension-padding-sm,8px);--wp-ui-button-height:var(--wpds-dimension-size-sm,24px)}._9f6fc6553aeb36fe__icon{margin:var(--wp-ui-button-icon-margin)}.dd460c965226cc77__is-brand{&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-brand-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-brand,var(--wp-admin-theme-color,#3858e9));--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 85%,#000));--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-brand-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal{--wp-ui-button-background-color:var(--wpds-color-background-interactive-brand-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-brand-weak-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 12%,#fff));--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-brand-weak-disabled,#0000)}}.e722a8f96726aa99__is-neutral{&.ad0619a3217c6a5b__is-minimal[aria-pressed=true],&.b50b3358c5fb4d0b__is-solid{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-strong,#2d2d2d);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-strong-active,#1e1e1e);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-strong-disabled,#e6e6e6);--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral-strong,#f0f0f0);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-strong-active,#f0f0f0);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-strong-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline,&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-foreground-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);--wp-ui-button-foreground-color-active:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);--wp-ui-button-foreground-color-disabled:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d)}&._62d5a778b7b258ee__is-outline{--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000);--wp-ui-button-border-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d);--wp-ui-button-border-color-active:var(--wpds-color-stroke-interactive-neutral-active,#6e6e6e);--wp-ui-button-border-color-disabled:var(--wpds-color-stroke-interactive-neutral-disabled,#dbdbdb)}&.ad0619a3217c6a5b__is-minimal:not([aria-pressed=true]){--wp-ui-button-background-color:var(--wpds-color-background-interactive-neutral-weak,#0000);--wp-ui-button-background-color-active:var(--wpds-color-background-interactive-neutral-weak-active,#ededed);--wp-ui-button-background-color-disabled:var(--wpds-color-background-interactive-neutral-weak-disabled,#0000)}}.abbb272e2ce49bd6__is-unstyled{background:none;border:none;min-width:unset}.cf59cf1b69629838__is-compact{--wp-ui-button-height:var(--wpds-dimension-size-md,32px)}._914b42f315c0e580__is-loading:not(.abbb272e2ce49bd6__is-unstyled){color:transparent;&:not([data-disabled]):is(:hover,:active,:focus){color:transparent}@media (forced-colors:active){color:ButtonFace}*{opacity:0}&:before{opacity:1;transition-delay:.05s;@media not (prefers-reduced-motion){animation:_5a1d53da6f830c8d__loading-animation 1s linear infinite}}}}@keyframes _5a1d53da6f830c8d__loading-animation{0%{transform:translate(-50%,-50%) rotate(0deg)}to{transform:translate(-50%,-50%) rotate(1turn)}}}');var Mb={button:"_97b0fc33c028be1a__button","is-unstyled":"abbb272e2ce49bd6__is-unstyled","is-loading":"_914b42f315c0e580__is-loading","is-small":"_908205475f9f2a92__is-small",icon:"_9f6fc6553aeb36fe__icon","is-brand":"dd460c965226cc77__is-brand","is-outline":"_62d5a778b7b258ee__is-outline","is-minimal":"ad0619a3217c6a5b__is-minimal","is-neutral":"e722a8f96726aa99__is-neutral","is-solid":"b50b3358c5fb4d0b__is-solid","is-compact":"cf59cf1b69629838__is-compact","loading-animation":"_5a1d53da6f830c8d__loading-animation"},Ss=(0,_u.forwardRef)(function({className:t,icon:o,...n},r){return(0,xu.jsx)(co,{ref:r,icon:o,className:J(Mb.icon,t),size:24,...n})});Ss.displayName="Button.Icon";var kr=Object.assign(vu,{Icon:Ss});var Ru=b(ce(),1);var nt=b(W(),1),Rs="data-wp-hash";function Es(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Hb(document)),e.__wpStyleRuntime}function Bb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Rs}]`))if(o.getAttribute(Rs)===t)return!0;return!1}function Eu(e,t,o){if(!e.head)return;let n=Es(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Bb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Rs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Hb(e){let t=Es();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Eu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function zb(e,t){let o=Es();o.styles.set(e,t);for(let n of o.documents.keys())Eu(n,e,t)}typeof process>"u",zb("c5cdafb1bc","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer compositions{._28cfdc260e755391__icon-button{--wp-ui-button-aspect-ratio:1;--wp-ui-button-padding-inline:0px;--wp-ui-button-min-width:unset}.f1c70d719989a85a__icon{margin:-1px}}}");var Su={"icon-button":"_28cfdc260e755391__icon-button",icon:"f1c70d719989a85a__icon"},ks=(0,Ru.forwardRef)(function({label:t,className:o,children:n,disabled:r,focusableWhenDisabled:i=!0,icon:s,size:a,shortcut:l,positioner:c,"aria-describedby":d,"aria-keyshortcuts":m,...u},f){let p=J(Su["icon-button"],o),{descriptionId:g,targetProps:h}=pu({"aria-describedby":d,"aria-keyshortcuts":m,shortcut:l});return(0,nt.jsxs)(rs,{children:[(0,nt.jsxs)(os,{ref:f,...h,disabled:r&&!i,render:(0,nt.jsx)(kr,{...u,size:a,"aria-label":t,disabled:r,focusableWhenDisabled:i}),className:p,children:[(0,nt.jsx)(co,{icon:s,size:24,className:Su.icon}),l&&g&&(0,nt.jsx)(mu,{descriptionId:g,shortcut:l})]}),(0,nt.jsxs)(ts,{positioner:c,children:[t,l&&(0,nt.jsxs)(nt.Fragment,{children:[" ",(0,nt.jsx)(gu,{shortcut:l})]})]})]})});var ku=b(ce(),1),Ts="data-wp-hash";function Ps(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&jb(document)),e.__wpStyleRuntime}function Db(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ts}]`))if(o.getAttribute(Ts)===t)return!0;return!1}function Tu(e,t,o){if(!e.head)return;let n=Ps(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Db(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ts,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function jb(e){let t=Ps();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Tu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Fb(e,t){let o=Ps();o.styles.set(e,t);for(let n of o.documents.keys())Tu(n,e,t)}typeof process>"u",Fb("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var Vb={stack:"_19ce0419607e1896__stack"},Wb={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},Ut=(0,ku.forwardRef)(function({direction:t,gap:o,align:n,justify:r,wrap:i,render:s,...a},l){let c={gap:o&&Wb[o],alignItems:n,justifyContent:r,flexDirection:t,flexWrap:i};return ot({render:s,ref:l,props:ve(a,{style:c,className:Vb.stack})})});var sn={};Mt(sn,{ActionButton:()=>Qu,ActionLink:()=>ef,Actions:()=>Fu,CloseIcon:()=>Gu,Description:()=>zu,Root:()=>Au,Title:()=>Lu});var No=b(ce(),1);import{speak as Yb}from"@wordpress/a11y";var Io=b(W(),1),As="data-wp-hash";function Os(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Gb(document)),e.__wpStyleRuntime}function Ub(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${As}]`))if(o.getAttribute(As)===t)return!0;return!1}function Pu(e,t,o){if(!e.head)return;let n=Os(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ub(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(As,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Gb(e){let t=Os();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Pu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Cu(e,t){let o=Os();o.styles.set(e,t);for(let n of o.documents.keys())Pu(n,e,t)}typeof process>"u",Cu("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Kb={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Cu("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Cs={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Xb={neutral:null,info:ms,warning:cs,success:gs,error:fs};function qb(e){return e==="error"?"assertive":"polite"}function Zb(e){if(e){if(typeof e=="string")return e;try{return(0,No.renderToString)(e)}catch{return}}}function Qb(e,t){let o=Zb(e);(0,No.useEffect)(()=>{o&&Yb(o,t)},[o,t])}var Au=(0,No.forwardRef)(function({intent:t="neutral",children:o,icon:n,spokenMessage:r=o,politeness:i=qb(t),render:s,...a},l){Qb(r,i);let c=n===null?null:n??Xb[t],d=J(Cs.notice,Cs[`is-${t}`],Kb["box-sizing"]);return ot({defaultTagName:"div",render:s,ref:l,props:ve({className:d,children:(0,Io.jsxs)(Io.Fragment,{children:[o,c&&(0,Io.jsx)(co,{className:Cs.icon,icon:c})]})},a)})});var Ou=b(ce(),1);var Iu=b(W(),1),Ns="data-wp-hash";function Is(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&$b(document)),e.__wpStyleRuntime}function Jb(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ns}]`))if(o.getAttribute(Ns)===t)return!0;return!1}function Nu(e,t,o){if(!e.head)return;let n=Is(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Jb(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ns,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function $b(e){let t=Is();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Nu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function eh(e,t){let o=Is();o.styles.set(e,t);for(let n of o.documents.keys())Nu(n,e,t)}typeof process>"u",eh("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var th={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Lu=(0,Ou.forwardRef)(function({className:t,...o},n){return(0,Iu.jsx)(We,{ref:n,variant:"heading-md",className:J(th.title,t),...o})});var Mu=b(ce(),1);var Hu=b(W(),1),Ls="data-wp-hash";function Ms(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&nh(document)),e.__wpStyleRuntime}function oh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Ls}]`))if(o.getAttribute(Ls)===t)return!0;return!1}function Bu(e,t,o){if(!e.head)return;let n=Ms(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(oh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Ls,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function nh(e){let t=Ms();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Bu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function rh(e,t){let o=Ms();o.styles.set(e,t);for(let n of o.documents.keys())Bu(n,e,t)}typeof process>"u",rh("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var ih={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},zu=(0,Mu.forwardRef)(function({className:t,...o},n){return(0,Hu.jsx)(We,{ref:n,variant:"body-md",className:J(ih.description,t),...o})});var Du=b(ce(),1);var Bs="data-wp-hash";function Hs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&ah(document)),e.__wpStyleRuntime}function sh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Bs}]`))if(o.getAttribute(Bs)===t)return!0;return!1}function ju(e,t,o){if(!e.head)return;let n=Hs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(sh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Bs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function ah(e){let t=Hs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)ju(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function ch(e,t){let o=Hs();o.styles.set(e,t);for(let n of o.documents.keys())ju(n,e,t)}typeof process>"u",ch("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var lh={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Fu=(0,Du.forwardRef)(function({render:t,...o},n){return ot({defaultTagName:"div",render:t,ref:n,props:ve({className:lh.actions},o)})});var Vu=b(ce(),1),Wu=b(st(),1);var Uu=b(W(),1),zs="data-wp-hash";function Ds(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&uh(document)),e.__wpStyleRuntime}function dh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${zs}]`))if(o.getAttribute(zs)===t)return!0;return!1}function Yu(e,t,o){if(!e.head)return;let n=Ds(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(dh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(zs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function uh(e){let t=Ds();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)Yu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function fh(e,t){let o=Ds();o.styles.set(e,t);for(let n of o.documents.keys())Yu(n,e,t)}typeof process>"u",fh("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var ph={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Gu=(0,Vu.forwardRef)(function({className:t,icon:o=ds,label:n=(0,Wu.__)("Dismiss"),...r},i){return(0,Uu.jsx)(ks,{...r,ref:i,className:J(ph["close-icon"],t),variant:"minimal",size:"small",tone:"neutral",icon:o,label:n})});var Xu=b(ce(),1);var Zu=b(W(),1),js="data-wp-hash";function Fs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&gh(document)),e.__wpStyleRuntime}function mh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${js}]`))if(o.getAttribute(js)===t)return!0;return!1}function qu(e,t,o){if(!e.head)return;let n=Fs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(mh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(js,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function gh(e){let t=Fs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)qu(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function bh(e,t){let o=Fs();o.styles.set(e,t);for(let n of o.documents.keys())qu(n,e,t)}typeof process>"u",bh("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var Ku={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},Qu=(0,Xu.forwardRef)(function({className:t,loading:o,loadingAnnouncement:n,variant:r,...i},s){return(0,Zu.jsx)(kr,{...i,...o!==void 0?{loading:o,loadingAnnouncement:n??""}:{},ref:s,size:"compact",tone:"neutral",variant:r,className:J(Ku["action-button"],Ku[`is-action-button-${r}`],t)})});var Ju=b(ce(),1);var Ws=b(W(),1),Vs="data-wp-hash";function Ys(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&wh(document)),e.__wpStyleRuntime}function hh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Vs}]`))if(o.getAttribute(Vs)===t)return!0;return!1}function $u(e,t,o){if(!e.head)return;let n=Ys(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(hh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Vs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function wh(e){let t=Ys();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)$u(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function vh(e,t){let o=Ys();o.styles.set(e,t);for(let n of o.documents.keys())$u(n,e,t)}typeof process>"u",vh("42aad93a67","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._4145abab73d17514__notice{--icon-height:var(--wpds-dimension-size-sm,24px);--text-vertical-padding:calc((var(--icon-height) - var(--wpds-typography-line-height-sm, 20px))/2);--wp-ui-notice-background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-neutral,#dbdbdb);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-neutral,#1e1e1e);align-items:start;background-color:var(--wp-ui-notice-background-color);border:1px solid var(--wp-ui-notice-border-color);border-radius:var(--wpds-border-radius-lg,8px);container-type:inline-size;display:grid;grid-template-columns:auto 1fr auto;padding:var(--wpds-dimension-padding-md,12px)}.d0a25570cb528528__icon{color:var(--wp-ui-notice-decorative-icon-color);grid-column:1;grid-row:1;margin-inline-end:var(--wpds-dimension-gap-xs,4px)}._1904b570a89bb815__description,.b5397fb9d05389e3__title{color:var(--wp-ui-notice-text-color);grid-column:2;padding-block:var(--text-vertical-padding)}._0a1270dcdd79c031__actions{display:flex;flex-wrap:wrap;gap:var(--wpds-dimension-gap-md,12px);grid-column:2}._4145abab73d17514__notice:has(._1904b570a89bb815__description) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions{margin-block-start:var(--wpds-dimension-gap-sm,8px)}._983740ab855c4e09__action-button{flex-shrink:0}.d329e7416d368d31__action-link{flex-shrink:0;&:not(:first-child){margin-inline-start:var(--wpds-dimension-gap-xs,4px)}&:not(:last-child){margin-inline-end:var(--wpds-dimension-gap-xs,4px)}}._487e6a5c1375f7dc__close-icon{grid-column:3;grid-row:1;margin-inline-start:var(--wpds-dimension-gap-xs,4px)}._531c140826094795__is-info{--wp-ui-notice-background-color:var(--wpds-color-background-surface-info-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-info,#aac6e5);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-info,#001b4f);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-info-weak,#006bd7)}.ae2e1004697cce95__is-warning{--wp-ui-notice-background-color:var(--wpds-color-background-surface-warning-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-warning,#e1be80);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-warning,#2e1900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-warning-weak,#936400)}._2e614a76af494837__is-success{--wp-ui-notice-background-color:var(--wpds-color-background-surface-success-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-success,#92d19d);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-success,#002900);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-success-weak,#007f2f)}.af00331ae17a0065__is-error{--wp-ui-notice-background-color:var(--wpds-color-background-surface-error-weak,#f8f8f8);--wp-ui-notice-border-color:var(--wpds-color-stroke-surface-error,#dfafa8);--wp-ui-notice-text-color:var(--wpds-color-foreground-content-error,#470000);--wp-ui-notice-decorative-icon-color:var(--wpds-color-foreground-content-error-weak,#cc1818)}@container (max-width: 320px){._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._0a1270dcdd79c031__actions,._4145abab73d17514__notice:has(.b5397fb9d05389e3__title) ._1904b570a89bb815__description{grid-column:1/3}}}@layer compositions{.d329e7416d368d31__action-link{margin-block:auto}._487e6a5c1375f7dc__close-icon,._983740ab855c4e09__action-button:is(._8ddb8fb33fbf3d38__is-action-button-outline,._77bbde495a8a0af3__is-action-button-minimal){--wp-ui-button-background-color-active:color-mix(in srgb,transparent 50%,var(--wpds-color-background-interactive-neutral-weak-active,#ededed))}}}");var _h={notice:"_4145abab73d17514__notice",icon:"d0a25570cb528528__icon",title:"b5397fb9d05389e3__title",description:"_1904b570a89bb815__description",actions:"_0a1270dcdd79c031__actions","action-button":"_983740ab855c4e09__action-button","action-link":"d329e7416d368d31__action-link","close-icon":"_487e6a5c1375f7dc__close-icon","is-info":"_531c140826094795__is-info","is-warning":"ae2e1004697cce95__is-warning","is-success":"_2e614a76af494837__is-success","is-error":"af00331ae17a0065__is-error","is-action-button-outline":"_8ddb8fb33fbf3d38__is-action-button-outline","is-action-button-minimal":"_77bbde495a8a0af3__is-action-button-minimal"},ef=(0,Ju.forwardRef)(function({className:t,render:o,...n},r){return(0,Ws.jsx)(We,{ref:r,className:J(_h["action-link"],t),...n,variant:"body-md",render:(0,Ws.jsx)(so,{tone:"neutral",variant:"default",render:o})})});var tf=b(ce(),1),of=b(W(),1),nf=(0,tf.forwardRef)(({children:e,className:t,ariaLabel:o,as:n="div",...r},i)=>(0,of.jsx)(n,{ref:i,className:J("admin-ui-navigable-region",t),"aria-label":o,role:"region",tabIndex:"-1",...r,children:e}));nf.displayName="NavigableRegion";var rf=nf;var sf=b(st(),1);var Gt=b(W(),1),Gs="data-wp-hash";function Ks(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&xh(document)),e.__wpStyleRuntime}function yh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Gs}]`))if(o.getAttribute(Gs)===t)return!0;return!1}function af(e,t,o){if(!e.head)return;let n=Ks(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(yh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Gs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function xh(e){let t=Ks();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)af(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Sh(e,t){let o=Ks();o.styles.set(e,t);for(let n of o.documents.keys())af(n,e,t)}typeof process>"u",Sh("72ef022400",".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}");var Us={list:"bfb5a2dd8cceebd3__list",li:"a4759b4cb2c8bd92__li",item:"_07da506d3f2d9afe__item"},Rh=({items:e,currentHref:t,ariaLabel:o=(0,sf.__)("Sections"),linkComponent:n,className:r})=>{if(!e.length)return null;let i=n??"a";return(0,Gt.jsx)("nav",{"aria-label":o,className:r,children:(0,Gt.jsx)(Ut,{render:(0,Gt.jsx)("ul",{role:"list"}),direction:"row",align:"center",gap:"md",className:Us.list,children:e.map(s=>(0,Gt.jsx)("li",{className:Us.li,children:(0,Gt.jsx)(We,{variant:"body-md",className:Us.item,render:(0,Gt.jsx)(so,{variant:"unstyled","aria-current":s.href===t?"page":void 0,render:(0,Gt.jsx)(i,{href:s.href})}),children:s.label})},s.href))})})},cf=Rh;var df=b(an(),1),{Fill:uf,Slot:ff}=(0,df.createSlotFill)("SidebarToggle");var Ze=b(W(),1),Xs="data-wp-hash";function qs(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&kh(document)),e.__wpStyleRuntime}function Eh(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Xs}]`))if(o.getAttribute(Xs)===t)return!0;return!1}function pf(e,t,o){if(!e.head)return;let n=qs(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Eh(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Xs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function kh(e){let t=qs();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)pf(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Th(e,t){let o=qs();o.styles.set(e,t);for(let n of o.documents.keys())pf(n,e,t)}typeof process>"u",Th("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var St={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function mf({headingLevel:e=1,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:s,navigation:a,components:l,showSidebarToggle:c=!0}){let d=`h${e}`,m=!!a?.items?.length;return(0,Ze.jsxs)(Ut,{direction:"column",className:J(St.header,m&&St["has-navigation"]),children:[(0,Ze.jsxs)(Ut,{className:St["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,Ze.jsxs)(Ut,{direction:"row",gap:"sm",align:"center",justify:"start",className:St["header-lockup"],children:[c&&(0,Ze.jsx)(ff,{bubblesVirtually:!0,className:St["sidebar-toggle-slot"]}),n&&(0,Ze.jsx)("div",{className:St["header-visual"],"aria-hidden":"true",children:n}),r&&(0,Ze.jsx)(We,{className:St["header-title"],render:(0,Ze.jsx)(d,{}),variant:"heading-lg",children:r}),t,o]}),s&&(0,Ze.jsx)(Ut,{align:"center",className:St["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,Ze.jsx)(We,{render:(0,Ze.jsx)("p",{}),variant:"body-md",className:St["header-subtitle"],children:i}),m&&(0,Ze.jsx)(cf,{...a,linkComponent:l?.link,className:St["header-navigation"]})]})}var cn=b(W(),1),Qs="data-wp-hash";function Js(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Ch(document)),e.__wpStyleRuntime}function Ph(e,t){if(!e.head)return!1;for(let o of e.head.querySelectorAll(`style[${Qs}]`))if(o.getAttribute(Qs)===t)return!0;return!1}function gf(e,t,o){if(!e.head)return;let n=Js(),r=n.injectedStyles.get(e);if(r||(r=new Set,n.injectedStyles.set(e,r)),r.has(t))return;if(Ph(e,t)){r.add(t);return}let i=e.createElement("style");i.setAttribute(Qs,t),i.appendChild(e.createTextNode(o)),e.head.appendChild(i),r.add(t)}function Ch(e){let t=Js();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[o,n]of t.styles)gf(e,o,n);return()=>{let o=t.documents.get(e);if(o!==void 0){if(o<=1){t.documents.delete(e);return}t.documents.set(e,o-1)}}}function Ah(e,t){let o=Js();o.styles.set(e,t);for(let n of o.documents.keys())gf(n,e,t)}typeof process>"u",Ah("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Zs={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function bf({headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,children:s,className:a,actions:l,navigation:c,components:d,ariaLabel:m,hasPadding:u=!1,showSidebarToggle:f=!0}){let p=J(Zs.page,a);return(0,cn.jsxs)(rf,{className:p,ariaLabel:m??(typeof r=="string"?r:""),children:[(r||t||o||l||n||!!c?.items?.length)&&(0,cn.jsx)(mf,{headingLevel:e,breadcrumbs:t,badges:o,visual:n,title:r,subTitle:i,actions:l,navigation:c,components:d,showSidebarToggle:f}),u?(0,cn.jsx)("div",{className:J(Zs.content,Zs["has-padding"]),children:s}):s]})}bf.SidebarToggleFill=uf;var $s=bf;var ut=b(an()),Ff=b(ln()),Vf=b(ce()),At=b(st()),Wf=b(Tr());import{privateApis as Kh}from"@wordpress/connectors";var vf=b(Ji()),{lock:a8,unlock:Lo}=(0,vf.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/routes");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='3ac7d2cc0e']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","3ac7d2cc0e"),e.appendChild(document.createTextNode(".connectors-page{box-sizing:border-box;margin:0 auto;max-width:680px;padding:24px;width:100%}.connectors-page .components-item{background:#fff;border:1px solid #ddd;border-radius:8px;overflow:hidden;padding:20px;scroll-margin-top:120px}.connectors-page .connector-settings__error{color:#cc1818}.connectors-page .connector-settings .components-text-control__input{font-family:monospace;scroll-margin-top:120px}.connectors-page__file-mods-notice{margin-bottom:16px}.connectors-page--empty{align-items:center;display:flex;flex-direction:column;flex-grow:1;gap:32px;justify-content:center;text-align:center}.connectors-page .ai-plugin-callout{background-color:#e7d4e4;background-image:radial-gradient(ellipse 70% 120% at 18% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 92% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 58% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%);border-radius:8px;overflow:hidden;padding:24px;padding-inline-end:150px;position:relative}[dir=rtl] .connectors-page .ai-plugin-callout{background-image:radial-gradient(ellipse 70% 120% at 82% 115%,rgba(202,158,198,.75) 0,rgba(202,158,198,0) 60%),radial-gradient(ellipse 55% 110% at 8% -15%,rgba(208,175,217,.7) 0,rgba(208,175,217,0) 65%),radial-gradient(ellipse 40% 85% at 42% -10%,rgba(170,130,184,.45) 0,rgba(170,130,184,0) 70%)}.connectors-page .ai-plugin-callout__content{align-items:flex-start;display:flex;flex-direction:column;gap:12px;padding-top:2px}.connectors-page .ai-plugin-callout__content p{font-size:13px;line-height:20px;margin:0}.connectors-page .ai-plugin-callout__decoration{height:110px;inset-inline-end:16px;position:absolute;top:12px;width:110px}.connectors-page__help-text{color:#757575}@media (max-width:680px){.connectors-page .ai-plugin-callout{padding:12px;padding-inline-end:100px}.connectors-page .ai-plugin-callout__decoration{height:75px;inset-inline-end:8px;top:8px;width:75px}}@media (max-width:480px){.connectors-page{padding:8px}.connectors-page .ai-plugin-callout{padding-inline-end:130px}.connectors-page .components-item{padding:12px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child svg{height:32px;width:32px}.connectors-page .components-item>.components-v-stack>.components-h-stack:first-child>.components-h-stack:last-child{align-items:flex-end;flex-direction:column}}")),document.head.appendChild(e)}var fn=b(an()),sa=b(Tr()),pn=b(ln()),Et=b(ce()),Qe=b(st()),Hf=b(ea()),zf=b(xf());var Pr=b(an()),na=b(ce()),Af=b(ln()),lo=b(st());import{__experimentalRegisterConnector as Oh,__experimentalConnectorItem as Cf,__experimentalDefaultConnectorSettings as Nh,__experimentalApplicationPasswordConnectorSettings as Ih,privateApis as Lh}from"@wordpress/connectors";var ta=b(Tr()),un=b(ln()),dn=b(ce()),pe=b(st()),Sf=b(ea());function oa({file:e,settingName:t,connectorName:o,isInstalled:n,isActivated:r,keySource:i="none",initialIsConnected:s=!1}){let[a,l]=(0,dn.useState)(!1),[c,d]=(0,dn.useState)(!1),[m,u]=(0,dn.useState)(s),[f,p]=(0,dn.useState)(null),g=e?.replace(/\.php$/,""),h=g?.includes("/")?g.split("/")[0]:g,{derivedPluginStatus:y,canManagePlugins:_,currentApiKey:v,currentUsername:w,hasStoredCredentials:R,hasResolvedSettings:x,canInstallPlugins:S}=(0,un.useSelect)(Q=>{let q=Q(ta.store),ne=q.getEntityRecord("root","site")?.[t],se=typeof ne=="string"?ne:"",ze=typeof ne=="object"&&ne!==null?ne:void 0,ae=ze!==void 0?!!ze.username&&!!ze.password:!!se,ge=q.hasFinishedResolution("getEntityRecord",["root","site"]),be=!!q.canUser("create",{kind:"root",name:"plugin"}),Ee={currentApiKey:se,currentUsername:ze?.username??"",hasStoredCredentials:ae,hasResolvedSettings:ge,canInstallPlugins:be};if(!e)return{...Ee,derivedPluginStatus:ge?"active":"checking",canManagePlugins:void 0};let ye=q.getEntityRecord("root","plugin",g);if(!q.hasFinishedResolution("getEntityRecord",["root","plugin",g]))return{...Ee,derivedPluginStatus:"checking",canManagePlugins:void 0};if(ye){let ft=ye.status==="active"||ye.status==="network-active";return{...Ee,derivedPluginStatus:ft?"active":"inactive",canManagePlugins:!0}}let rt="not-installed";return r?rt="active":n&&(rt="inactive"),{...Ee,derivedPluginStatus:rt,canManagePlugins:!1}},[e,g,t,n,r]),E=f??y,k=_,P=E==="active"&&m||f==="active"&&R,{saveEntityRecord:N,invalidateResolution:H}=(0,un.useDispatch)(ta.store),{createSuccessNotice:j,createErrorNotice:L}=(0,un.useDispatch)(Sf.store),T=Q=>N("root","site",{[t]:Q},{throwOnError:!0}),I=()=>{j((0,pe.sprintf)((0,pe.__)("%s connected successfully."),o),{id:"connector-connect-success",type:"snackbar"})},C=()=>{j((0,pe.sprintf)((0,pe.__)("%s disconnected."),o),{id:"connector-disconnect-success",type:"snackbar"})},A=()=>{L((0,pe.sprintf)((0,pe.__)("Failed to disconnect %s."),o),{id:"connector-disconnect-error",type:"snackbar"})},M=async()=>{if(h){d(!0);try{await N("root","plugin",{slug:h,status:"active"},{throwOnError:!0}),p("active"),H("getEntityRecord",["root","site"]),l(!0),j((0,pe.sprintf)((0,pe.__)("Plugin for %s installed and activated successfully."),o),{id:"connector-plugin-install-success",type:"snackbar"})}catch{L((0,pe.sprintf)((0,pe.__)("Failed to install plugin for %s."),o),{id:"connector-plugin-install-error",type:"snackbar"})}finally{d(!1)}}},X=async()=>{if(e){d(!0);try{await N("root","plugin",{plugin:g,status:"active"},{throwOnError:!0}),p("active"),H("getEntityRecord",["root","site"]),l(!0),j((0,pe.sprintf)((0,pe.__)("Plugin for %s activated successfully."),o),{id:"connector-plugin-activate-success",type:"snackbar"})}catch{L((0,pe.sprintf)((0,pe.__)("Failed to activate plugin for %s."),o),{id:"connector-plugin-activate-error",type:"snackbar"})}finally{d(!1)}}};return{pluginStatus:E,canInstallPlugins:S,canActivatePlugins:k,isExpanded:a,setIsExpanded:l,isBusy:c,isConnected:P,currentApiKey:v,currentUsername:w,hasResolvedSettings:x,keySource:i,handleButtonClick:()=>{if(E==="not-installed"){if(S===!1)return;M()}else if(E==="inactive"){if(k===!1)return;X()}else l(!a)},getButtonLabel:()=>{if(c)return E==="not-installed"?(0,pe.__)("Installing\u2026"):(0,pe.__)("Activating\u2026");if(a)return(0,pe.__)("Cancel");if(P)return(0,pe.__)("Edit");switch(E){case"checking":return(0,pe.__)("Checking\u2026");case"not-installed":return(0,pe.__)("Install");case"inactive":return(0,pe.__)("Activate");case"active":return(0,pe.__)("Set up")}},saveApiKey:async Q=>{let q=v;try{let se=(await T(Q))?.[t];if(Q&&(se===q||!se))throw new Error("It was not possible to connect to the provider using this key.");u(!0),I()}catch($){throw console.error("Failed to save API key:",$),$}},removeApiKey:async()=>{try{await T(""),u(!1),C()}catch(Q){console.error("Failed to remove API key:",Q),A()}},saveCredentials:async({username:Q,applicationPassword:q})=>{try{let se=(await T({username:Q,password:q}))?.[t];if(!se?.username||!se?.password)throw new Error((0,pe.__)("It was not possible to save these credentials."));u(!0),I()}catch($){throw console.error("Failed to save credentials:",$),$}},removeCredentials:async()=>{try{await T({username:"",password:""}),u(!1),C()}catch(Q){console.error("Failed to remove credentials:",Q),A()}}}}var ue=b(W()),Rf=()=>(0,ue.jsx)("svg",{width:"40",height:"40",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:(0,ue.jsx)("path",{d:"M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364l2.0201-1.1685a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.4043-.6813zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z",fill:"currentColor"})}),Ef=()=>(0,ue.jsx)("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:(0,ue.jsx)("path",{d:"M6.2 21.024L12.416 17.536L12.52 17.232L12.416 17.064H12.112L11.072 17L7.52 16.904L4.44 16.776L1.456 16.616L0.704 16.456L0 15.528L0.072 15.064L0.704 14.64L1.608 14.72L3.608 14.856L6.608 15.064L8.784 15.192L12.008 15.528H12.52L12.592 15.32L12.416 15.192L12.28 15.064L9.176 12.96L5.816 10.736L4.056 9.456L3.104 8.808L2.624 8.2L2.416 6.872L3.28 5.92L4.44 6L4.736 6.08L5.912 6.984L8.424 8.928L11.704 11.344L12.184 11.744L12.376 11.608L12.4 11.512L12.184 11.152L10.4 7.928L8.496 4.648L7.648 3.288L7.424 2.472C7.344 2.136 7.288 1.856 7.288 1.512L8.272 0.176L8.816 0L10.128 0.176L10.68 0.656L11.496 2.52L12.816 5.456L14.864 9.448L15.464 10.632L15.784 11.728L15.904 12.064H16.112V11.872L16.28 9.624L16.592 6.864L16.896 3.312L17 2.312L17.496 1.112L18.48 0.464L19.248 0.832L19.88 1.736L19.792 2.32L19.416 4.76L18.68 8.584L18.2 11.144H18.48L18.8 10.824L20.096 9.104L22.272 6.384L23.232 5.304L24.352 4.112L25.072 3.544H26.432L27.432 5.032L26.984 6.568L25.584 8.344L24.424 9.848L22.76 12.088L21.72 13.88L21.816 14.024L22.064 14L25.824 13.2L27.856 12.832L30.28 12.416L31.376 12.928L31.496 13.448L31.064 14.512L28.472 15.152L25.432 15.76L20.904 16.832L20.848 16.872L20.912 16.952L22.952 17.144L23.824 17.192H25.96L29.936 17.488L30.976 18.176L31.6 19.016L31.496 19.656L29.896 20.472L27.736 19.96L22.696 18.76L20.968 18.328H20.728V18.472L22.168 19.88L24.808 22.264L28.112 25.336L28.28 26.096L27.856 26.696L27.408 26.632L24.504 24.448L23.384 23.464L20.848 21.328H20.68V21.552L21.264 22.408L24.352 27.048L24.512 28.472L24.288 28.936L23.488 29.216L22.608 29.056L20.8 26.52L18.936 23.664L17.432 21.104L17.248 21.208L16.36 30.768L15.944 31.256L14.984 31.624L14.184 31.016L13.76 30.032L14.184 28.088L14.696 25.552L15.112 23.536L15.488 21.032L15.712 20.2L15.696 20.144L15.512 20.168L13.624 22.76L10.752 26.64L8.48 29.072L7.936 29.288L6.992 28.8L7.08 27.928L7.608 27.152L10.752 23.152L12.648 20.672L13.872 19.24L13.864 19.032H13.792L5.44 24.456L3.952 24.648L3.312 24.048L3.392 23.064L3.696 22.744L6.208 21.016L6.2 21.024Z",fill:"#D97757"})}),kf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("path",{d:"M0 4C0 1.79086 1.79086 0 4 0H28C30.2091 0 32 1.79086 32 4V28C32 30.2091 30.2091 32 28 32H4C1.79086 32 0 30.2091 0 28V4Z",fill:"#F0F0F0"}),(0,ue.jsx)("path",{d:"M14.5 8V12H17.5V8H19V12H20.5C20.7652 12 21.0196 12.1054 21.2071 12.2929C21.3946 12.4804 21.5 12.7348 21.5 13V17L18.5 21V23C18.5 23.2652 18.3946 23.5196 18.2071 23.7071C18.0196 23.8946 17.7652 24 17.5 24H14.5C14.2348 24 13.9804 23.8946 13.7929 23.7071C13.6054 23.5196 13.5 23.2652 13.5 23V21L10.5 17V13C10.5 12.7348 10.6054 12.4804 10.7929 12.2929C10.9804 12.1054 11.2348 12 11.5 12H13V8H14.5ZM15 20.5V22.5H17V20.5L20 16.5V13.5H12V16.5L15 20.5Z",fill:"#949494"})]}),Tf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",viewBox:"0 0 44 44",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("rect",{width:"44",height:"44",fill:"#357B49",rx:"6"}),(0,ue.jsx)("path",{fill:"#fff",fillRule:"evenodd",d:"m29.746 28.31-6.392-16.797c-.152-.397-.305-.672-.789-.675-.673 0-1.408.611-1.746 1.316l-7.378 16.154c-.072.16-.143.311-.214.454-.5.995-1.045 1.546-2.357 1.626a.399.399 0 0 0-.16.033l-.01.004a.399.399 0 0 0-.23.392v.01c0 .054.01.106.03.155l.004.01a.416.416 0 0 0 .394.252h6.212a.417.417 0 0 0 .307-.12.416.416 0 0 0 .124-.305.398.398 0 0 0-.105-.302.399.399 0 0 0-.294-.127c-.757 0-2.197-.062-2.197-1.164.02-.318.103-.63.245-.916l1.399-3.152c.52-1.163 1.654-1.163 2.572-1.163h5.843c.023 0 .044 0 .062.003.13.014.16.081.214.242l1.534 4.07a2.857 2.857 0 0 1 .216 1.04c0 .054-.003.104-.01.153-.09.726-.831.887-1.49.887a.4.4 0 0 0-.294.127l-.007.008-.007.008a.401.401 0 0 0-.092.286v.01c0 .054.01.106.03.155l.005.01a.42.42 0 0 0 .395.252h7.011a.413.413 0 0 0 .279-.13.412.412 0 0 0 .11-.297.387.387 0 0 0-.09-.294.388.388 0 0 0-.277-.135c-1.448-.122-2.295-.643-2.847-2.08Zm-11.985-5.844 2.847-6.304c.361-.728.659-1.486.889-2.265 0-.06.03-.092.06-.092s.061.032.061.091c.02.122.045.247.073.374.197.888.584 1.878.914 2.723l.176.453 1.684 4.529a.927.927 0 0 1 .092.4.473.473 0 0 1-.009.094c-.041.202-.228.272-.602.272h-6.063c-.122 0-.184-.03-.184-.092a.36.36 0 0 1 .062-.183Zm17.107-.721c0 .786-.446 1.231-1.25 1.231-.806 0-1.125-.409-1.125-1.034 0-.786.465-1.231 1.25-1.231.785 0 1.125.427 1.125 1.034ZM9.629 23.002c.803 0 1.25-.447 1.25-1.231 0-.607-.343-1.036-1.128-1.036-.785 0-1.25.447-1.25 1.231 0 .625.325 1.036 1.128 1.036Z",clipRule:"evenodd"})]}),Pf=()=>(0,ue.jsxs)("svg",{width:"40",height:"40",style:{flex:"none",lineHeight:1},viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:[(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"#3186FF"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-0)"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-1)"}),(0,ue.jsx)("path",{d:"M20.616 10.835a14.147 14.147 0 01-4.45-3.001 14.111 14.111 0 01-3.678-6.452.503.503 0 00-.975 0 14.134 14.134 0 01-3.679 6.452 14.155 14.155 0 01-4.45 3.001c-.65.28-1.318.505-2.002.678a.502.502 0 000 .975c.684.172 1.35.397 2.002.677a14.147 14.147 0 014.45 3.001 14.112 14.112 0 013.679 6.453.502.502 0 00.975 0c.172-.685.397-1.351.677-2.003a14.145 14.145 0 013.001-4.45 14.113 14.113 0 016.453-3.678.503.503 0 000-.975 13.245 13.245 0 01-2.003-.678z",fill:"url(#lobe-icons-gemini-fill-2)"}),(0,ue.jsxs)("defs",{children:[(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-0",x1:"7",x2:"11",y1:"15.5",y2:"12",children:[(0,ue.jsx)("stop",{stopColor:"#08B962"}),(0,ue.jsx)("stop",{offset:"1",stopColor:"#08B962",stopOpacity:"0"})]}),(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-1",x1:"8",x2:"11.5",y1:"5.5",y2:"11",children:[(0,ue.jsx)("stop",{stopColor:"#F94543"}),(0,ue.jsx)("stop",{offset:"1",stopColor:"#F94543",stopOpacity:"0"})]}),(0,ue.jsxs)("linearGradient",{gradientUnits:"userSpaceOnUse",id:"lobe-icons-gemini-fill-2",x1:"3.5",x2:"17.5",y1:"13.5",y2:"12",children:[(0,ue.jsx)("stop",{stopColor:"#FABC12"}),(0,ue.jsx)("stop",{offset:".46",stopColor:"#FABC12",stopOpacity:"0"})]})]})]});var _e=b(W()),{store:Mh}=Lo(Lh);function Of(){try{return JSON.parse(document.getElementById("wp-script-module-data-options-connectors-wp-admin")?.textContent??"{}")}catch{return{}}}function ra(){return Of().connectors??{}}function Nf(){return!!Of().isFileModDisabled}var Bh={google:Pf,openai:Rf,anthropic:Ef,akismet:Tf};function Hh(e,t){if(t)return(0,_e.jsx)("img",{src:t,alt:"",width:40,height:40});let o=Bh[e];return o?(0,_e.jsx)(o,{}):(0,_e.jsx)(kf,{})}var zh=()=>(0,_e.jsx)("span",{style:{color:"#345b37",backgroundColor:"#eff8f0",padding:"4px 12px",borderRadius:"2px",fontSize:"13px",fontWeight:"var(--wpds-typography-font-weight-emphasis)",whiteSpace:"nowrap"},children:(0,lo.__)("Connected")}),Dh=({slug:e})=>(0,_e.jsx)(so,{href:(0,lo.sprintf)((0,lo.__)("https://wordpress.org/plugins/%s/"),e),openInNewTab:!0,children:(0,lo.__)("Learn more")}),jh=()=>(0,_e.jsx)(Ui,{children:(0,lo.__)("Not available")});function If({isConnected:e,showUnavailableBadge:t,pluginSlug:o,isExpanded:n,isBusy:r,pluginStatus:i,actionButtonRef:s,handleButtonClick:a,getButtonLabel:l}){return(0,_e.jsxs)(Pr.__experimentalHStack,{spacing:3,expanded:!1,children:[e&&(0,_e.jsx)(zh,{}),t&&(o?(0,_e.jsx)(Dh,{slug:o}):(0,_e.jsx)(jh,{})),!t&&(0,_e.jsx)(Pr.Button,{ref:s,variant:n||e?"tertiary":"secondary",size:"compact",onClick:a,disabled:i==="checking"||r,isBusy:r,accessibleWhenDisabled:!0,children:l()})]})}function Lf(e){let t=e?.replace(/\.php$/,"");return t?.includes("/")?t.split("/")[0]:t}function Fh({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="api_key"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=Lf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:m,isExpanded:u,setIsExpanded:f,isBusy:p,isConnected:g,currentApiKey:h,hasResolvedSettings:y,keySource:_,handleButtonClick:v,getButtonLabel:w,saveApiKey:R,removeApiKey:x}=oa({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),S=_==="env"||_==="constant",E=c==="not-installed"&&d===!1||c==="inactive"&&m===!1,k=(0,na.useRef)(null);return(0,_e.jsx)(Cf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:(0,_e.jsx)(If,{isConnected:g,showUnavailableBadge:E,pluginSlug:l,isExpanded:u,isBusy:p,pluginStatus:c,actionButtonRef:k,handleButtonClick:v,getButtonLabel:w}),children:u&&c==="active"&&y&&(0,_e.jsx)(Nh,{initialValue:S?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":h,helpUrl:a,readOnly:g||S,keySource:_,onRemove:S?void 0:async()=>{await x(),k.current?.focus()},onSave:async P=>{await R(P),f(!1),k.current?.focus()}},g?"connected":"setup")})}function Vh({name:e,description:t,logo:o,authentication:n,plugin:r}){let i=n?.method==="application_password"?n:void 0,s=i?.settingName??"",a=i?.credentialsUrl??void 0,l=Lf(r?.file),{pluginStatus:c,canInstallPlugins:d,canActivatePlugins:m,isExpanded:u,setIsExpanded:f,isBusy:p,isConnected:g,currentUsername:h,hasResolvedSettings:y,keySource:_,handleButtonClick:v,getButtonLabel:w,saveCredentials:R,removeCredentials:x}=oa({file:r?.file,settingName:s,connectorName:e,isInstalled:r?.isInstalled,isActivated:r?.isActivated,keySource:i?.keySource,initialIsConnected:i?.isConnected}),S=_==="env"||_==="constant",E=(0,na.useRef)(null),k=c==="not-installed"&&d===!1||c==="inactive"&&m===!1;return(0,_e.jsx)(Cf,{className:l?`connector-item--${l}`:void 0,logo:o,name:e,description:t,actionArea:(0,_e.jsx)(If,{isConnected:g,showUnavailableBadge:k,pluginSlug:l,isExpanded:u,isBusy:p,pluginStatus:c,actionButtonRef:E,handleButtonClick:v,getButtonLabel:w}),children:u&&c==="active"&&y&&(0,_e.jsx)(Ih,{initialUsername:S?"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022":h,helpUrl:a,readOnly:g||S,keySource:_,onRemove:S?void 0:async()=>{await x(),E.current?.focus()},onSave:async P=>{await R(P),f(!1),E.current?.focus()}},g?"connected":"setup")})}function Mf(){let e=ra(),t=o=>o.replace(/[^a-z0-9-_]/gi,"-");for(let[o,n]of Object.entries(e)){if(o==="akismet"&&!n.plugin?.isInstalled)continue;let{authentication:r}=n,i=t(o),s={name:n.name,description:n.description,type:n.type,logo:Hh(o,n.logoUrl),authentication:r,plugin:n.plugin},a=Lo((0,Af.select)(Mh)).getConnector(i);r.method==="api_key"&&!a?.render?s.render=Fh:r.method==="application_password"&&!a?.render&&(s.render=Vh),Oh(i,s)}}var Cr=b(W());function Bf(){return(0,Cr.jsx)("div",{className:"ai-plugin-callout__decoration","aria-hidden":"true",children:(0,Cr.jsx)("svg",{viewBox:"0 0 248 248",xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink",focusable:"false",style:{width:"100%",height:"100%"},children:(0,Cr.jsx)("image",{href:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAASwAAAEsCAYAAAB5fY51AAAQAElEQVR4AezdC3ojWW5tYflOzPbIbI/M9sh8+WdrdZ+KpiiKL5FB5KedwN7AeSFIpHRYmfX/PubXVGAqMBV4kQpMw3qRBzXbnApMBT4+pmHNq2AqMBV4mQpMw3qZR3X9RmeGqcCrV2Aa1qs/wdn/VOCNKjAN640e9hx1KvDqFZiG9epPcPY/FThWgZ1q07B2+mDnWFOBPVZgGtYen+qcaSqw0wpMw9rpg51jTQX2WIFpWMee6mhTganAU1ZgGtZTPpbZ1FRgKnCsAtOwjlVltKnAVOApKzAN6ykfy2zqcRWYlV6pAtOwXulpzV6nAm9egWlYb/4CmONPBV6pAtOwXulpve9e//Nw9P/7xL8d7Hy9aQWubFhvWrU59qMr8D+HBcPBna93rcA0rHd98q91bs3q3w9bBv7Bna93rMA0rHd86nPmqcCLVmAa1os+uF/Y9m8u6Q7rvw8bgLnDOhTiXb+mYb3rk3+tc//rYbsaVTjQP18amct4+h9hftt3BaZh7fv57v107rNg7+ec831WYBrWZyHGPHUF/vewu//6xNqg+HMRfyjMrb+edb5pWM/6ZGZfawX86Bc0qTU2/htVYBrWGz3sOepU4NUrMA3r1Z/g7H8q8EYVmIZ1h4c9U04FpgL3qcA0rPvUdWadCkwF7lCBaVh3KOpMORWYCtynAtOw7lPXmfVdKjDnfGgFpmE9tNyz2FRgKnBNBaZhXVO9GTsVmAo8tALTsB5a7llsKjAVuKYCv9uwrtn5jJ0KTAXergLTsN7ukc+BpwKvW4FpWK/77GbnU4G3q8A0rLd75L914Fl3KnB9BaZhXV/DmWEqMBV4UAWmYT2o0LPMVGAqcH0FpmFdX8OZYSowFfhrBe7GpmHdrbQz8VRgKnDrCkzDunVFZ76pwFTgbhWYhnW30s7EU4GpwK0rMA3r1hW9fr6ZYSowFfiiAtOwvijMyFOBqcDzVWAa1vM9k9nRVGAq8EUFpmF9UZiRpwKPqMCs8bMKTMP6Wb0meyowFfjFCkzD+sXiz9JTganAzyowDetn9ZrsqcBU4Bcr8NIN6xfrNktPBaYCv1CBaVi/UPRZciowFbisAtOwLqvbjJoKTAV+oQLTsH6h6LPkBRWYIVOBQwWmYR2KMF9TganAa1RgGtZrPKfZ5VRgKnCowDSsQxHmayowFXimCny9l2lYX9dmIlOBqcCTVWAa1pM9kNnOVGAq8HUFpmF9XZuJTAWmAk9WgWlYT/ZArt/OzDAV2G8FpmHt99nOyaYCu6vANKzdPdK7HOjfDrP+9yf4B/fP138efoeDma+pwP0rMA3r/jXewwqaVFjP8x8HAmIHd74eXIG3W24a1ts98pse+H8Os8HBzNdU4P4VmIZ1/xrvYQU/9v3L4SCwNqh/P2iwagdpvqYC96nANKz71HVmnQpMBe5QgXduWHco526n9B3W9tJ91fi7Pfwc7HkqMA3reZ7FM+/kXw+bc7EeDvTPV1z8jzC/TQXuWYFpWPes7sw9FZgK3LQC07BuWs7dTva/h5P91ye6YGfT2EP4eb9mZ/uowDSsfTzHe5/CHVXQqKzHbjX6YCpwtwpMw7pbaX808f8dsoN7oQOdr6nAVGBbgWlY24o8hvvEzXcnp1YTl3cq51ExTdRe7GldE6ev2vhTgbtV4KyGdbfV33diDeC7T9bE5T1LlezFntb94PRVG38qcLcKTMO6W2lPTuy/GPdfiJfED+6G6Lg8/m/Dnuxne7lOe5Y9/naNZv0HVGAa1gOKfMYSGkI4I/1XUp59f79SlFn0sRWYhvXYereaex/3PyunQT9iiePlPMbOKlOBJ67ANKzfeTiakvufVsdDmjgtPnYq8PYVmIb1Oy8B9z7uf06tLi7vVM7EpgJvVYFpWM/xuF1mB3dFz7Gr2cXOK/B6x5uG9RzPzH1VeI4dzS6mAk9YgWlYT/hQZktTganA8QpMwzpel1GnAlOBJ6zANKyLH8oMnApMBR5dgWlYj674rDcVmApcXIFpWBeXbgZOBaYCj67ANKxHV3zWe8UKzJ6fpALTsJ7kQcw2pgJTge8rMA3r+xpNxlRgKvAkFZiG9SQPYrYxFZgKfF+BRzSs73cxGVOBqcBU4IwKTMM6o0iTMhWYCjxHBaZhPcdzmF1MBaYCZ1RgGtYZRXrSFP9Wln/gD/htEwd/mTqNT4Nyj2ny+7/3sDgYh4NxNBYHcdrH4Tc8HOifL/E044hsmjgN0tj2Ko6DcfLE8EADcfmAg1w64IMXrcA0rNd5cN6Y3njrjnE4pvkHANP58iCNxQO+B3x11v84HA6c9+DO1ytWYBrW6zw1/6Df/FtZlz8vtYPLZ5iRv16BaVi//gjO3sD2zYb7F0mB30Q4aHBpfBqU68cjHPjl4iHNPy5oDljH4yBeLh7SxNN+Mr7cY+PFmpNtLf52/2suv9yx11TgF8ZOw/qFor/gkt7kKzrCJZox9xzf3GN3WIFpWK/xUN27hHbsuyIXyyBGZ/FAgzgrh7aO59PE5AQaiKfJ2WriNCiPPZabxsqBa8ebw9rAD9agmX+r0QcvVoFpWK/xwLzxvOFcGq87pof0OHtKE5MDLqpxwAMO4mksDfggjgMecBBPY2lsEKdBGouDOB5oEGdx4Ac8pLFpY1+sAtOwfuuBXb+uN/H1s9x2hm0zWH/8u+1KM9tbVmAa1ms8dj/SuEh2odyOXUSHtTGksadyjZETjuWm/e/BKc+4A/1g09iPw69j2kH+OHe8XHMF89GOjaeXx+LAD41nt5rcwYtVYBrWiz2wZbvehBoZ8IVYPNAgzuKw5vK32prLD8dy08xRHosDP5TLbrVtLg7lscbRWDzQIM7isObyaYMXrMA0rBd8aN9s2Y9lodQ4m/ZK1r7Duu80Np0f0n7ZzvK3qsA0rFtV8vHzeFP6r9+Bbwesy/lAgzgrh8YaC+t3I3SclRdoEGflbDU6TYwfaBBn5Ww1fN2nPB820ECcZiweaLDmyqGBcSunDV6sAtOwXuyBPWC73tTe9NulaNuLfhqsuY1nV13eOeONMRb4t4Q93HK+mevBFZiG9eCC33i5ay+S3efAui3fibjc3+o06625OH3VjKOZZ9V9aCB/1XC5q2YczTyrfq7vgt5YWMc076qN/2IVeIGG9WIVfdx2vSG9CaFVaRpDSI+zcuisxgDrHMXYFfLhO018m0eDrY6D2AoapNmjvUN7FcdDueLyQU762B1UYBrWDh7iHGEq8C4VmIa1vyfdJbTvNDqdi/Ww3g3JgfKe1TpT+2+/zpHGtne6HEgbu5MKTMPayYNcjuENC9sL7iXl765LaPi78MvOLZZ3dmc65/y3WG/meGAFpmE9sNhPuJQ7HhffT7i1i7fkTODy/eJJZuBzVmAa1nM+l2t21SW0S+fm4Qdv5lV/hR+dNNXt/p0jje1M6a9wrvY89swKTMM6s1AvnuZNHF7xKO092xnibNrYF6nAJduchnVJ1Z57jO8sQjt1aR3c8aS/inWe7f6dI43tLPSQNnYnFZiGtZMHuRzDhTOsl869gdkl9cOna7Bqz+g7i72H9hhnV00DU4O0sTupwDSsnTzIOcZU4B0qMA3rRZ/yiW27gAYX1aXxw3rf0wV9ec9qfeJ3bP9pbHv346NzqUHa2J1UYBrWTh7kcgwNKSR7E4e0V7LtnXU2e2fxQBvsvALTsHb+gD+P544nfEovZdo7u24cD6s+/k4rMA1rfw/WJTq4eO50/OANvtXjz2pdoLd/31HZp3OksTQQx1n89TEn+HsFpmH9vRRv6XjTw94O70w+Wdzbud7+PNOw9vcScLcDLqq/O52Lafgu75Xizu5M60X8K+1/9nqiAtOwThTnRUPerLD+SORTs+AN3dH4EH9W6zztv3PZdxrb3ukhbexOKrD/hrWTBzXHmApMBT4+pmHt71Xgwhn6TsQJXcIH9zs04AP/meE87b9z2Xca2/7pciBt7E4qMA1rJw9yOYY3LJxz6awRwDL85V1n96niOed/+cO+2wGmYb3bE//reXd21/PncJ3pnA8d/gyY316nAtOwXudZnbvTfzkkgovqg/vnix+8of+Ih9/SDu5Tf/nEr722fzaN7QDp8yNhFdmRnYa1o4d54ijexOFE2tOG2nu2jcbZtLE7rsA0rP09XN9ZhE7nniq440l/Fes82/07Rxr7KmeZfV5RgaVhXTHLDH2mCrhwhvXS2Zs7rHutEazaM/rO0v7Z9sgPac7kU8NpYlVkR3Ya1o4e5hzlLxWYS/e/lGMfZBrWPp7jeoouqNl0fljve3w3sl5Yl/9sVvM5tv80tj07kw8d2LSxO6nANKydPMjlGN6omhIk0wLt1dDe2c7F4uHVzjT7vaAC07AuKNoLDumeh33B7X/Yd/hYfqWxizzuXiswDWt/T9aFM6yXzvywvrnTnr0KPkRor76jsl/nSGNpII6z+GBHFZiGtaOHecFRvOnhgqFPPcSZfLL41Jt81Ob2tM40rD09zb+dxd0OuKj+m/L17y7c4euM14v4zsqZ1ov41zvF7PhoBaZhHS3LS4verOCN20F8ahY0s3Q+xJ/VOk/771z2ncauexeDVRt/BxWYhrWDhzhHmAq8SwWmYX3zpF8w7MIZ+k7EEVzCB/c7NOAD/5nhPO2/c9l3Gtv+6XIgbexOKjANaycPcjmGNyycc+msEcAy/OVdZ/ep4jnnf/nDvtsBpmG92xP/63nd88Bf1ddmzgPnfOjw2id9w91Pw9rfQ3cBDS6qOx0/eDNv9fizWp/4bffvHGlse0//+Y+EzTD2aSswDetpH81NN+ZNHG468YMma+/Zlo2zaWN3XIFpWPt7uL6zCJ0uzrrjSX+Utaa1gW9dFg+0r7Dm8strLJs2dscVmIa1v4frwhnWS2c8rCf26Rqs2j381mZrOCwO617pPghg24uckM6mseVqXs5kjrSxO6nA7RrWTgoyx3iaCmhIT7OZ2chzVGAa1nM8h1vuwgV1aN44u973uJyH8u5lfWJnbWh9Fg+tTXeJ7jultGPjxRrL4mCcM5kDH+yoAtOwdvQwP4/iDQve+J/SBx4+fuFXa7Pti8WBf2pbckK5bBp7avzEdlKBaVg7eZDfHMOPV+Gb1HPCP85pbbbB/BXpx+xXeV/px+YYbQcVmIa1g4e4OYILZ1gvnfnBm7wh8mDVil1jfcezzulSvPXFzC2eJk4DcTqLgzgN0tfxdHkgjrP4YEcVmIa1o4f5w6N4w/9wyFnp5tVgzkr+Iskc6yeHX6R9KV87/suJJ/C7FZiG9bv1v8fq7nbARfWp+eW4rIZTeT+NmdeFN/vTsfKNsyfAf4prx/90vb3nP9X5pmE91eO4yWY0C1h/JPKpWfCGbiE5sGrFrrHb+eyn9a1nbjZNnAbGirE4iJcrRhNPY2lAl8Pigx1VYBrWjh7mHGUqsPcKTMPa3xN24Qy+y+h0LtaD+x06Kwfwe8Ia9gTWtRaLgzjtK8hpoPtu7gAAEABJREFU/+Uan8Y2li4H0sbupALTsO77IH9jdm9YOOfS2uU4yL/3Xq0B6zo4nLPXddwp33zOdMs5T603sQdWYBrWA4s9Sz2kAu6u4LsPHR6ymVnkthWYhnXbej7DbC6gwUV1++EHb2Y6Kw/4tHvBj2fWgdZi29N3nwiKl2ucfbJpLA3SrYkPdlSBaVg7epgnjuJNHE6kPTzUnthTi4uvKPeYVuzhdha8fwWmYd2/xo9ewR0OrN9h8INYe+JD/FmtPR7bfxr7rHuffd2wAtOwbljMJ5nKJ2qwXjq7hA5tUxOQB/z0Z7TtnW2vLB7at+blU0PnShu7kwpMw9rJg5xjTAXeoQJP07DeodgPOqML6tCSx+56aC6rgV/uM1qf+NkjrPvDQ7rvsJxJDdLG7qQC07B28iCXY3jDgjdysjdwWHU+lPes1nnaP98+7TuNpQUxiI/dSQWmYe3kQX5zDPc94ZvUpwy3d3bdIB5WffydVmAa1v4erAtnWC+d+cEb3KlZecCnPQY/X8XFevvvOyx7TmObVRxn08bupALTsHbyIOcYf6mAZrZ+SvqX4JDXrcA0rNd9dl/t3N0NuKj+Kocux8U04HvBXs+1l+dz1TmmYV1Vvqcc7AIa1h+J/JWY4A3dxuXAqhV7Jus87d9+7c2e01ga0OWw+OBXK3Dbxadh3baeM9tUYCpwxwpMw7pjcR8wtbsaaCm+S/SQHmflpL+K9R2Ti3Ro/6zzhM4iJ8hJH7uDCkzDeu2H2Bvz0lNoBHDp+EeO03zCqXXLYU/lTewFKzAN66kf2rebc08D3yZ+kaBZXTP+i2lHngrcpwLTsO5T10fN6jIaWk/zwUN6nJWTzm457dmgsdo7tF8WD+05zspJH7uDCkzD2sFD3BzBmzQUirNpr2btPbT3OHtKKzb2xSswDet1H6A7Gt95AL+T4CFNPKTtwXZOtvPwgzNv9VUr9gx29nBGBaZhnVGkJ03xxvNXVoBvmyweaEC/9oLePM8EZ+qc63/Vnsa2Xw0MB+PSx75YBaZhvdgDm+1OBd65AtOwXvfpu7cJ6ynS2HTfYbiEhrQ9WH+tKHQe515Bx8vj0wYvWIG9NKwXLP3VW/bG04BAQzLhqtFpQQzir26dxbmB33mcO6SJywN++tgXq8A0rBd7YMt23cWERf5IYz/u+Mv8K1rqmFbsEfbY+se0R+xl1rhxBaZh3bigd5rOhfn2r6B4E9LBdw6WXjU67RZo3tYxZ5p1XGbTAA84GNf+jaMBH/iXwFhzs41vbTadxUF+uXScTRv7xBWYhvXED+fJtuZNvX4ad4vtmVMT+dFcS7Lxa7NcQme5144/a5FJul0FpmHdrpb3nMm/beXuBe65zqm5u7Q+lXMqZu+w5vjuZv2nYdbYOb753Fex5+Rvc6x/zfjtfMPvXIFpWHcu8I2m743lzdWUNG924NO9cfFAuwXMaw22+fDWWfeVxq65cmCdo/il1lywjrduKLbulb/ml7Nq4z9pBaZhPemDmW1NBaYCHx8fmyJMw9oU5AmoexXfBbBtpwtrNl2O+x9IK/8aay5Y57CGtcG6YiwO4jTAAw7iacbRrEGHNPq1MJc5oblop9Zfcxsz9gkrMA3r+R6KS2Twhv5ud3JCubg3aPyn1nhvYPanY3+abw245WW+ucwJ3+1HTvgud+JPUIFpWE/wEDZb6IJ9I59N3cnA2QM2ica6YGc3oaFTgd+twDSs363/sdV9d+Rymi2OhxqJ+FYr/285sZ9ZY829jtLAtmvJSRMvP41NE8fB/HQWB3HaLWAuc0LzrXu1Lp2VE2iDJ6/ANKwnf0Cf2/PmCp/SH5PG/hHu9Jv5V7TMJZoxp8YXu9SaP6xzpLHp/JA29okrMA3r+R6O7wZCu4uz7lzS+RC/hbVGaD5rpPHpbBpLA37AYc3lbzX5tHvBmtYAfuvgIU08jZ8+9gkqMA3rdx+CNwS0C74L95AeZ9PkuhwHfvq11hqhueJsa7E4uOg+lntMM47OGgvrePqtz2RO6wB/uz6dBvyAvwjeY5vTsH73OXvzwLFd+FHlmH5P7au93HPNY3PbBxyLjfbGFZiG9bsPvx891l1oVODTwnQ8rFoXxmLp11qX1qG57MUakMYP4sf0NPFy0+Ks+Kr7L9XVJu1aa43OxG8+fkizl2O5xcf+YgWmYf1i8Y8s7c1TE1rfsGmsnIbyIX6tNZd1Q/Ph1gY+XS4OaXQ84CCexqd9NV7s1rCWdYFvfrY9sTSQE/DBE1VgGtafh/FUv/lRKLSxOJt2L2uN0Bpx9pj2lX4q15gV5T7SHlv/mPbIPc1aJyowDetEce4c8qf4uX9dxCV08IZqa3yIX2vN1Tps87mExsG+6WuuOA3kBBzE04yjsWniNDA/ncVvAWtVa745WesEGsRZOTTg33JP5hz8sALTsH5YsCdL9yaCJ9vWVdvxiaEzsVdNdOPBmirceNqZ7icVmIb1k2rdNtcdSrh0Zn/iw6Xjn3GcS291YW+5P3PCpXO6iF/vui6dZ8ZdUYFpWFcU78qh3jzeAFDTofmELLREnJWTfmtrbmuE5rfHtPbKpomXm8amieNgHJ3FQZwGdJzFbwHnMifwzclaO9AgzsqhAR/4g1+qwDSsXyr8LDsVmAr8vALTsH5es0tGuJPxHQM0nu9iF8TpLB5oEGfl0G453lzmNLc1Ag3E0+RsNXEalMfiII7DT8Yfy01jzResA3FWDu3Y+mJygjyIs3Jo63g+bfALFfhpw/qFLe5iSZe1sF4k870hQgeNs6c0MTkBhziLAz/gIc1etppYmjge0uPiW00sTRwP6XHxrSaWJo6H9Dh7ShOTE3CIszjwAx7S7CVt7IMrMA3rwQWf5aYCU4HLKzAN6/La/WSky16XuGzj+tSJ1mUui4dy46wcuh9NcEhj8SAP4qwc2jreXmhicgINxNPk0I6Np5fH4nDp+NY6Nl7MGsE6EGfl0Na9prFygjyIs3Jo63h7oQ1+oQLTsH6h6J9LejOs+JQ/ztU+Dr/OzT2Wdxj+cUz/u/bxj1+rxi/CD+dq8s/NPZZ3yXjzGBdwiLM48AMe0ti0sQ+uwDSsxxTcn9DBXYhV2a1GT2Nx4AfjaOxWo6exOPCDcTQ2jaUBP+Cw5vK3mnwa8AMOxqTxaZDG4sAP5bJbbZuLQ3mscTQWBz4N8IBDnC2XxYM8iLP44M4VmIZ15wJ/Tu/CPXxKH3HWG4LO4oEGcRaHNZe/1dZcfpAHxqR1kbxqYvKAH+TQ2LTG09NYOV9p3uRy4KvxxoKc0JxsGisP+AGHNZe/1eTTgB9wMCbtu73KH9ypAtOw7lTYN53WG/tNj/7ix36R7U/DesyDcu+xwqr+6kkaHtLYn2ryjQs4xFkc+MFeaJDG4iCOAw78IL7VitHFV06Ls+I0wAMO4luNnsbiwA84xFk84OFczV7KdQEf0sbesQLTsO5Y3GVqnziFZD8SpfHp3jxpLA34QQ6NTbv3ePOfWkvcnqA8FgdxHPi0Y/unywlyaMak8WliaSwN+EEOjU271XjzmivggztXYBrWnQv8Ob0flcKn9BHPfnz+irOf0gc/fCy/0thkfjiliZXH4sAPOMSzNIizOPADDvEsDeIsDvyAQzxLgziLAz/gIY39qSbfuIBDnMUHd67ANKxbFPgfc3jh9u8u+ZO3iL/mEeTQXeJuNbE0Vh7wgxya+beaWBorD/hBDm0dby80sfJYGojjIId2bDxdTsDh0vGtdWy8WOuw1gF+kENb95rGlsfKA36QQ1vH2wtNrDyWFsTyx96wAtOwbljMmWoq8FkBDUyT+6RjblWBaVi3quQ/5nFfEv6hjvdOFfC3GrwG3unMDznrNKzbltmLtMtdfrN7AYd0eWn9aSyWxp4ab4wc4Mu9dLy9nBovbh1oLRYHceMBDziIpxlHY9PEaZDGOg9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4P/y8fFhLzSxNJa2Qnzl49+gAtOwblDEmWIqMBV4TAWmYV1XZ5er0Cz+JHZ/Afx0PJQvvtXE0thHjbcXa321vrj9gBy5q8angZyAg3jaT8Yfy01jm5O1DvCDHNqx9cXKY+UBP8ihreP5NLHyWBqI4yCHNrhRBaZhXV5IL0Yvyj41aiY6rH+FAw/liaex6fxwShMrj8WBH3CIs3jAwV62Gj1NHA/pcfGtJpYmjof0uPhWE0sTx0N6nD2lickJOMRZHPgBD2n2stXE0sRxSBt7owo8uGHdaNfPM417ivW/fH6enc1OpgI7rMA0rMsfqmblAtaPAM1C669qsOn8IIeu0W01epq5cUhjG8/iwJcHOPxkvHxjgR9wOLZXa5bHygN+wOHS8db4ajy9dVgc+KHx7Fbb5uJQHmscjcUDDeIsDny1B+NogxtVYBrWjQr5OY0XqAYG/E/5Aw8fn7/ibLksDvzP1A88fHz+Ek/jk9mtRk9jcTiWu2prLj/I+Wo8vTwWB364x3hzWwf4AQdrpvG3mhgN+AEHY9L4W02MBuIBH9ywAtOwLi+mOwovVOCbicUDDeKsHBqLA58GeMAhzpbL4sCXB3jAIc6Wy+JBHsRZHNZc/lZbc/kA8sAYHPhbjU4DfjiWm7bNxaGxbLksDnx5gAcc4my5LB7kQZzFYc3lb7U1V2zwgwpMw/pBsTapLtvD+sJMc/nakDT2mHZs/Fe5jTdGDvDpLB5oEGdxWHPb66qtufwg56vx9PJYHPjhHuPNbR3gBxysmcbfamI04AccjEm7Za3MPfhBBaZh/aBYkzoVmAr8bgWmYV1efxfJ27uKOCve7HhIE99qYmksDvyAQ5zFAx7O1ezlVK74qTnFHz3eeu2JxYEfcIizeMDDudotz9qaL28fdYBpWJdX2l2ET4KAbyYvfhzS6HiQQxNP49PE0lga8IMcGpt27/HmP7WWuD1BeSwO4jjwacf2T5cT5NCMSePTxNJYGvCDHBqbdu/x5j+1lrg9DS6owDSsC4r2OcS9xopP+eMSzZiPz1/88Cl9xNmP5RcekuPsKU1MTsAhzuLAX0GDSzRjjAV+wCHO4sBfQYNztZ/kHpvz0vHmMhb4AR9cUIFpWOcVzZ+K/qt2thEuYWnghUgXx0GcBngoV3yriaWxxgI/yKGta6Wx5bHygB/k0Nbx9kITK4+lgTgOcmjHxtPlBBwuHd9ax8aLtQ5rHeAHObR1r2lseaw84Ac5tHW8vdDEymNpII6DHNqx8fTBDyswDeu8gvlkyIuPPW/ED7Im9a0r4B98fOsC/OTw07DOq5aLVvcg7HkjJmsqcF4Fjv3TNOeNfMOsaVjnPXTf0rtIZRuBe7FBOouDeLl40Pjo4mnG0cTSWBrwgxyaMWl8mlgaSwN+kEMzJs1eaGJpLA3EcTCOxuIgTgM84CCeZhyNTROnQRprPzRxHIyjieGBBnFWDs0YHPg0MTzQIM7KoRmDg73QxPBAA/E042hsmjhtcEEFpmFdUFjYef8AAA5ZSURBVLQZMhW4uAIz8KoKTMP65/K5q4I14gI1FPOn5ilNvDnKY0+NF5MTHjW+vX61vnh7kmNfq8anQXksDuI4/GT8sdw01nzBOhBn5dCOrS8mJ8iDOCuHto7n08TkBBqIp8nZauI0KI/FB99UYBrWPxfIiwd6scngBxxcwKexNOCDOA54wEE8jaUBP+AQZ/GAh59q8htrLziksTiI44EGcXEc0lgcxPFAg7g4DmksDuJ4oEGcxYEf8JDG/lSTbxzYCw54wEE8jaUBH8RxwAM++KYC07C+KdCEpwJTgeepwGs1rMfUrctRl6qt6N84Cuk+MdxqYmnsT8fLNw7Wy1k8WEMeu9XoaSwO/GAcjU1jacAPOFx6VmPh0vH2+NV4evtkceCD+jWepQFfHuABhzhbLosHeRBncfjJWe0xGDv4pgLTsL4p0GfYvUP4lD7irBf0x+EXiwP/IP35wsMf4fBbnC2XxYF/SPvzhYc/wuE38TT+Qfpg09iPz1/88Cl9rLn8j8Mvtjz2IP354gc5RHar0dNYHPjBOBq71ehpLA78YByNTWNpwAdxHPg04G81Og34AQdj0vhbTYwG/HAsN00uP+CDbyowDeuvBXKf0IuNLcoPcujsVqOnsTjwg3E0dqvR01gc+ME4GrvV6GksDvxgHI1NY2nADzisufytJp8G/ICDMWl8GqSxOPBDuexW2+biUB5rHI3FgU8DPOAgnsbfamI04AccjEnjbzUxGvADDsYEfLBUYBrWUoyD64Xir1bAejmKh0Pan684axzRiw+HS8abx9hgToizOKy5/K225vKDPDAmrb2umpg84Ac5NDat8fQ0Fgd+MI72Ta0+5MsDfmg8m8bKA37AYc3lbzX5NOAHHIxJ66yrJiYP+EEOjU1rPD2NxUGuD30AHywVmIa1FONM17fwZ6ZO2gtWQMN4wW2/x5anYf31OWtGweVp0TQ2TRyHNH4QP6aniZebxqaxOPADDnEWD3g4V7OXU7nip+YUf/R467UnFgd+wCHO4gEP52r3Pqv9uMSH9jT2swLTsD4L8Wm8WPrUxo8sn/Kf/z15epp4Gp9+zng5co05NV5MHvBD49k0c8lbNTEa8IMcGpv23XjxU7ni5oTyWBzEceDTjq1PlxPk0IxJ49PE0lga8IMcGpt27/HmP7WWuD1BeSwO9ioH8HfA2WechvXPpfIjQSgaZ49pX+nHco9pl4w3j3EBhziLAz/gIY09V/tJ7rE5f2O8fVg34BBnceAHPKSx52o/yT025zq++Fvbd29Y/hSDXgR8l52wXoTioVzxtF5Y54wv99h4seZkW4sf5NDXtdLY8lh5wA9yaOt4e6GJlcfSQBwHObRj4+lyAg6Xjm+tY+PFWoe1DvCDHNq61zS2PFYeHFtrHS8u79rx5rBuwMH8adagDT4r8M4Ny4vBi2P91OazLGOmAlOBZ6zAOzcsz8PFJvBfFbPv21bAH2S3nXFmu1kF3rlhdbnJVlDf+vdXc9aL0DS2XHEcjKOzOIjTAA+tJ55mnDyxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaZDG2g9NHAfjaGJ4oEGclUMzBgc+TQwPNIizcmjG4GAvNDE80EA8zTgamyZOgzQWB3EcjKMNPivwzg3rswRjpgJTgVepwDs3LH96bS83V43fcyyPTRPHoR8jVo1frpxwLDeNLY991Pj2+tX64vYDcuxr1fg0kBNwEE/7yfhjuWlsc7LWAX6QQzu2vlh5rDw4lrtqfHnXjjeHdQMO5k+zBg3o/3lwVu1A3+vrnRuWy3YPP/Tk4+JbTSxNHA/pcfGtJpYmjof0OHtKE5MTcIizOPADHtLsZauJpYnjIT0uvtXE0sTxkB4X32piaeJ4SI+zpzQxOQGHOIvDuhYe5ID4VqOnieMhPS6+1cTSxPGQ7gMioKe9nX3nhvV2D3sOfFYF3rohnFWhX0x654blr1j4hBBcoHoMLB5oEGdxuHS8Nb4aT7dGwCHONp7FgS8P8IBDnC2XxYM8iLM4XHpWY+HS8fb41Xi6PQYc4i6vG8+m8+VBGosDP5TLprHygB9wuPSsxsKx8XSX8OBHQ/wt8VYNa/OEPfjgBSnMbjV6GosDPxhHY7caPY3FgR+Mo7FpLA34AYc1l7/V5NOAH3AwJo2/1cRowA/HctO2uTg0li2XxYEvD/CAQ5wtl8WDPIiL48Df6qsmJg/4AYc1l7/V5NOAH47lpm1zcWgsu+aKvT3epWH5Nj/00HEvCuDTWTzQIM7KobE48LcanQb8cCw3bZuLQ2PZclkc+PIADzjE2XJZPMiDOIvDmsvfamsuP8gDY9L4W02MBvxwLDdtm4tDY9lyWRz48gAPOIin8beaGA34AQdj0vhbTYwG/ICDMWn8rSZGe0u8S8PqUxe2B+0CM6wvjDSXn8dyj2n3GG8fx9ZKs6Yc4NNZPNAgzuKw5nbWVVtz+UHOV+Pp5bE48MM9xpvbOsAPOFgzjb/VxGjgNYIDDsbg8Ey1sre3wrs0rLd6qHPYj4+PKcIuK/AuDauLUbYH6XLTHQGk8YP4MT1NvNy0OCt+TE8TlwdpLB5wiLM48AMe0thzNXs5lStuPjiWJ35MTxM3FtL4QfyYniZebhqbxuLADzjEWTzg4VzNXk7lip+aU/xW45vnbey7NCw/94ceLu6TJODTvdBwSKPjQQ5NPI1PE9tq9DRWDs0YHPg0MTzQIM7KobE43Hu8+a0D/K/Wp8sJOBiTxqcd2z+9PFYOzRgc+DQxPNAgzsqhsTjce7z5rQP8r9anywk4GJPGpx3bP/3t8C4N6+0e7Bx4KrDHChxvWPs7qYtU6E8sJ8T/7+BAOouD+CH85wsPLmCJ4mnG0dg0cRqksafGi8kJxkKclUNb1+LTxOQEGsRZOTRjcGivYniQB+JpxtHYNHEapLE4iONgHI3FQZwGeLAfmniacTSxNJYG/CCHZkwanyaWxtKAH+TQjEmzF5pYGksDcRyMo7E4iNMADziIpxlHY9PEaW+Jd2lYXlzQJzxv+bDn0FOBV6/AuzQsdwCwXni++rOb/U8F3q4C79KwtpeYHjTNX3UA33LTWBzEaYAHjY8mnmYcjU0Tp0Eae2q8mJxgLMRZObR1LT5NTE6gQZyVQzPmXz4+PmjtVQwP8kA8zTgamyZOgzQWB3EcjKOxOIjTAA/2QxNPM44mlsbSgB/k0IxJ49PE0lga8IMcmjFp9kITS2NpII6DcTQWB3Ea4AEH8TTjaGyaOO0t8S4N6y0f7hx6KrC3Crxzw/KnlgtMcL/l2a4anwZywrHcNLa8a8ebx9rAD9agmX+riaWx8oAf5NDW8XyaWHksDcRxkLPVxGkgJ+AgnvaT8cdy09jmZK0D/CCHdmx9sfJYecAPcmjreD5NrDyWBuI4yNlq4jSQE3AQT2s8nQ/8t8U7NywX8F4AsL4AcBBPx0OaeBpLZ4M4DdJYHMTxQIM4iwM/4CGN/akm3ziwFxzwgIN4GksDPojjgAccxNNYGvBBHAc84CCextKAH3CIs3jAw081+Y21FxzSWBzE8UCDuDgOaSwO4niggb8WpJHR8Uvw8mPeuWG9/MObA7xVBXxg5N7srQ69Pew7Nyx/TccFJvRCYOmhesVZOXQvIBzSWDzIgzgrh3ZsPF1OwCHONp7FgS8PcHAuHPBQLpvGygN+wOHYXh8x3hpfrU9vnywO/NB4dqttc3EojzWOxuKBBnEWh3vUyrx+VPRM7QV/S7xzw/LgQw8f98IAfjoejmnlsuXxj+Ue08plG88ey01bc/l01jjg0wAPOIin8beaGA344Vhu2jYXh8ay5bI48OUBHnCIs+WyeJAHcRaHNZe/1dZcfpAHxqTxt5oYDfjhWG7aNheHxrJrrtjb450b1rGH735gRTlePEGczp7SxOQBPxhHY7caPY3FgR+Mo7FbjZ7G4sAPxtHYNJYG/IDDmsvfavJpwA84GJPG32piNOCHY7lp21wcGsuWy+LAlwd4wCHOlsviQR7EWRzWXP5WW3P5QR4YE/DBUoFpWEsxDq4XiotNcMl5kP588cMf4fBbnDXuIH2wOLg8/fj8hYdP6SPOGkdn8UCDOIvDmsvfamsuP8gDY9La66qJyQN+kENj0xpPT2Nx4AfjaGzatePNY07gBxzWtfhbTT4N+AEHY9La66qJyQN+kENj0xpPT2NxkOv1B3za4LMC07A+CzFmKjAVeP4KTMP66zNyZxBcnhZNY9PEcUjjB/Fjepp4uWlsGosDP+AQZ/GAh3M1ezmVK35qTvFHj7dee2Jx4Acc4iwe8PAX7UDoB/Pnix/ufVbruMQH/p8NzG9/q8A0rL/Vod+9QHwSA+4W0vEghy6exqeJbTV6GiuHZgwOfJoYHmgQZ+XQWBzuPd781gH+V+vT5QQcjEnj047tn14eK4dmDA58mhgeaBBn5dBYHO493vzWAf5X69PlBBzs1TjAB0sFpmEtxRh3KjAVeO4KTMN67ufzTLv7yQXwT3Kf6YyzlyevwF0a1pOfebZ3ugKajX8sbpvlkyyxVceP/ejiE641b/ypwE0qMA3rJmXc1STuUPxTJttDuWsRW3X8WMM6Nn4dN/5U4KIKTMO6qGwzaCowFfiNCkzD+o2q72nNOctU4IEVmIb1wGLPUlOBqcB1FZiGdV39ZvRUYCrwwApMw3pgsWepqcBrV+D3dz8N6/efwexgKjAVOLMC07DOLNSkTQWmAr9fgWlYv/8MZgdTganAmRWYhnVmoa5PmxmmAlOBayswDevaCs74qcBU4GEVmIb1sFLPQlOBqcC1FZiGdW0FZ/xU4J8rMMqdKjAN606FnWmnAlOB21dgGtbtazozTgWmAneqwDSsOxV2pp0KTAVuX4H/DwAA//9sB2hHAAAABklEQVQDAB9QlitZA9bLAAAAAElFTkSuQmCC",width:"248",height:"248",style:{mixBlendMode:"multiply"}})})})}var Rt=b(W()),Wh="ai",Yh="ai-wp-admin",ia="ai/ai",Uh="https://wordpress.org/plugins/ai/",aa=Object.values(ra()),Gh=aa.some(e=>e.type==="ai_provider"),Df=[];for(let e of aa)e.type==="ai_provider"&&e.authentication.method==="api_key"&&Df.push(e.authentication.settingName);function jf(){let[e,t]=(0,Et.useState)(!1),[o,n]=(0,Et.useState)(!1),r=(0,Et.useRef)(null);(0,Et.useEffect)(()=>{o&&r.current?.focus()},[o]);let i=(0,Et.useRef)(aa.some(R=>R.type==="ai_provider"&&R.authentication.method==="api_key"&&R.authentication.isConnected)).current,{pluginStatus:s,canInstallPlugins:a,canManagePlugins:l,hasConnectedProvider:c}=(0,pn.useSelect)(R=>{let x=R(sa.store),S=!!x.canUser("create",{kind:"root",name:"plugin"}),E=x.getEntityRecord("root","site"),k=i||Df.some(H=>!!E?.[H]),P=x.getEntityRecord("root","plugin",ia);return x.hasFinishedResolution("getEntityRecord",["root","plugin",ia])?P?{pluginStatus:P.status==="active"?"active":"inactive",canInstallPlugins:S,canManagePlugins:!0,hasConnectedProvider:k}:{pluginStatus:"not-installed",canInstallPlugins:S,canManagePlugins:S,hasConnectedProvider:k}:{pluginStatus:"checking",canInstallPlugins:S,canManagePlugins:void 0,hasConnectedProvider:k}},[]),{saveEntityRecord:d}=(0,pn.useDispatch)(sa.store),{createSuccessNotice:m,createErrorNotice:u}=(0,pn.useDispatch)(Hf.store),f=async()=>{t(!0);try{await d("root","plugin",{slug:Wh,status:"active"},{throwOnError:!0}),n(!0),m((0,Qe.__)("AI plugin installed and activated successfully."),{id:"ai-plugin-install-success",type:"snackbar"})}catch{u((0,Qe.__)("Failed to install the AI plugin."),{id:"ai-plugin-install-error",type:"snackbar"})}finally{t(!1)}},p=async()=>{t(!0);try{await d("root","plugin",{plugin:ia,status:"active"},{throwOnError:!0}),n(!0),m((0,Qe.__)("AI plugin activated successfully."),{id:"ai-plugin-activate-success",type:"snackbar"})}catch{u((0,Qe.__)("Failed to activate the AI plugin."),{id:"ai-plugin-activate-error",type:"snackbar"})}finally{t(!1)}};if(!Gh||s==="checking"||s==="active"&&i&&!o||s==="inactive"&&l===!1)return null;let g=s==="active"&&!c,h=s==="active"&&c&&(!i||o),y=s==="not-installed"||s==="inactive",_=s==="not-installed"&&a===!1,v=()=>h?(0,Qe.__)("The AI plugin is ready to use. You can use it to generate featured images, alt text, titles, excerpts and more. Learn more"):g?(0,Qe.__)("The AI plugin is installed. Connect an AI provider below to generate featured images, alt text, titles, excerpts, and more. Learn more"):(0,Qe.__)("The AI plugin can use your AI connectors to generate featured images, alt text, titles, excerpts and more. Learn more"),w=()=>s==="not-installed"?{label:e?(0,Qe.__)("Installing\u2026"):(0,Qe.__)("Install the AI plugin"),disabled:e,onClick:e?void 0:f}:{label:e?(0,Qe.__)("Activating\u2026"):(0,Qe.__)("Activate the AI plugin"),disabled:e,onClick:e?void 0:p};return(0,Rt.jsxs)("div",{className:"ai-plugin-callout",children:[(0,Rt.jsxs)("div",{className:"ai-plugin-callout__content",children:[(0,Rt.jsx)("p",{children:(0,Et.createInterpolateElement)(v(),{strong:(0,Rt.jsx)("strong",{}),a:(0,Rt.jsx)(fn.ExternalLink,{href:Uh})})}),!_&&(y?(0,Rt.jsx)(fn.Button,{variant:"primary",size:"compact",isBusy:e,disabled:w().disabled,accessibleWhenDisabled:!0,onClick:w().onClick,children:w().label}):(0,Rt.jsx)(fn.Button,{ref:r,variant:"secondary",size:"compact",href:(0,zf.addQueryArgs)("options-general.php",{page:Yh}),children:(0,Qe.__)("Control features in the AI plugin")}))]}),(0,Rt.jsx)(Bf,{})]})}var Re=b(W()),{store:Xh}=Lo(Kh);Mf();function qh(){let e=Nf(),{connectors:t,canInstallPlugins:o,isAiPluginInstalled:n}=(0,Ff.useSelect)(c=>{let d=c(Wf.store),m=d.getEntityRecord("root","plugin","ai/ai");return{connectors:Lo(c(Xh)).getConnectors(),canInstallPlugins:d.canUser("create",{kind:"root",name:"plugin"}),isAiPluginInstalled:!!m}},[]),r=t.filter(c=>c.render),i=Array.from(new Set(t.filter(c=>c.type==="ai_provider").map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c))).sort(),s=new Set(t.filter(c=>c.plugin?.isInstalled).map(c=>c.plugin?.file?.split("/")[0]).filter(c=>!!c));n&&s.add("ai");let a=["ai",...i].filter(c=>!s.has(c)),l=r.length===0;return(0,Re.jsx)($s,{title:(0,At.__)("Connectors"),subTitle:(0,At.__)("All of your API keys and credentials are stored here and shared across plugins. Configure once and use everywhere."),children:(0,Re.jsxs)("div",{className:`connectors-page${l?" connectors-page--empty":""}`,children:[a.length>0&&(e||!o)&&(0,Re.jsx)(sn.Root,{intent:"info",className:"connectors-page__file-mods-notice",children:(0,Re.jsx)(sn.Description,{children:e?(0,At.__)("Plugins cannot be installed here due to your site configuration. Install them manually using your normal deployment workflow."):(0,At.__)("You do not have permission to install plugins. Please ask a site administrator to install them for you.")})}),l?(0,Re.jsxs)(ut.__experimentalVStack,{alignment:"center",spacing:3,style:{maxWidth:480},children:[(0,Re.jsxs)(ut.__experimentalVStack,{alignment:"center",spacing:2,children:[(0,Re.jsx)(ut.__experimentalHeading,{level:2,size:15,children:(0,At.__)("No connectors yet")}),(0,Re.jsx)(ut.__experimentalText,{size:12,children:(0,At.__)("Connectors appear here when you install plugins that use external services. Each plugin registers the API keys it needs, and you manage them all in one place.")})]}),(0,Re.jsx)(ut.Button,{variant:"secondary",href:"plugin-install.php",__next40pxDefaultSize:!0,children:(0,At.__)("Learn more")})]}):(0,Re.jsxs)(ut.__experimentalVStack,{spacing:3,children:[(0,Re.jsx)(jf,{}),(0,Re.jsx)(ut.__experimentalVStack,{spacing:3,role:"list",children:t.map(c=>c.render?(0,Re.jsx)(c.render,{slug:c.slug,name:c.name,description:c.description,type:c.type,logo:c.logo,authentication:c.authentication,plugin:c.plugin},c.slug):null)})]}),o&&!e&&(0,Re.jsx)("p",{className:"connectors-page__help-text",children:(0,Vf.createInterpolateElement)((0,At.__)("If the connector you need is not listed, search the plugin directory to see if a connector is available."),{a:(0,Re.jsx)("a",{href:"plugin-install.php?s=connector&tab=search&type=tag"})})})]})})}function Zh(){return(0,Re.jsx)(qh,{})}var Qh=Zh;export{Qh as stage}; /*! Bundled license information: use-sync-external-store/cjs/use-sync-external-store-shim.production.js: diff --git a/src/wp-includes/build/routes/font-list/content.js b/src/wp-includes/build/routes/font-list/content.js index 6f0404e093d80..42109fc02956a 100644 --- a/src/wp-includes/build/routes/font-list/content.js +++ b/src/wp-includes/build/routes/font-list/content.js @@ -224,13 +224,6 @@ var require_with_selector = __commonJS({ } }); -// package-external:@wordpress/primitives -var require_primitives = __commonJS({ - "package-external:@wordpress/primitives"(exports, module) { - module.exports = window.wp.primitives; - } -}); - // package-external:@wordpress/compose var require_compose = __commonJS({ "package-external:@wordpress/compose"(exports, module) { @@ -252,6 +245,13 @@ var require_private_apis = __commonJS({ } }); +// package-external:@wordpress/primitives +var require_primitives = __commonJS({ + "package-external:@wordpress/primitives"(exports, module) { + module.exports = window.wp.primitives; + } +}); + // package-external:@wordpress/components var require_components = __commonJS({ "package-external:@wordpress/components"(exports, module) { @@ -483,16 +483,16 @@ var require_date = __commonJS({ // node_modules/clsx/dist/clsx.mjs function r(e2) { - var t3, f2, n2 = ""; + var t2, f2, n2 = ""; if ("string" == typeof e2 || "number" == typeof e2) n2 += e2; else if ("object" == typeof e2) if (Array.isArray(e2)) { - var o3 = e2.length; - for (t3 = 0; t3 < o3; t3++) e2[t3] && (f2 = r(e2[t3])) && (n2 && (n2 += " "), n2 += f2); + var o2 = e2.length; + for (t2 = 0; t2 < o2; t2++) e2[t2] && (f2 = r(e2[t2])) && (n2 && (n2 += " "), n2 += f2); } else for (f2 in e2) e2[f2] && (n2 && (n2 += " "), n2 += f2); return n2; } function clsx() { - for (var e2, t3, f2 = 0, n2 = "", o3 = arguments.length; f2 < o3; f2++) (e2 = arguments[f2]) && (t3 = r(e2)) && (n2 && (n2 += " "), n2 += t3); + for (var e2, t2, f2 = 0, n2 = "", o2 = arguments.length; f2 < o2; f2++) (e2 = arguments[f2]) && (t2 = r(e2)) && (n2 && (n2 += " "), n2 += t2); return n2; } var clsx_default = clsx; @@ -8679,13 +8679,13 @@ function registerStyle(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle("a495f9d138", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}'); + registerStyle("3167e7d116", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{text-wrap:pretty;margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}'); } var style_default = { "text": "_83ed8a8da5dd50ea__text", "heading-2xl": "_14437cfb77831647__heading-2xl", "heading-xl": "_3c78b7fa9b4072dd__heading-xl", "heading-lg": "aa58f227716bcde2__heading-lg", "heading-md": "fc4da56d8dfe52c4__heading-md", "heading-sm": "a9b78c7c82e8dff7__heading-sm", "body-xl": "_305ff559e52180d5__body-xl", "body-lg": "ca1aa3fc2029e958__body-lg", "body-md": "_131101940be12424__body-md", "body-sm": "_0e8d87a42c1f75fa__body-sm" }; if (typeof process === "undefined" || true) { - registerStyle("af6d9984a6", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}"); + registerStyle("e8e31009f5", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}"); } -var global_css_defense_default = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a" }; +var global_css_defense_default = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a", "ol": "c59a0ebebd71fa4a__ol", "li": "_46b5cb0c8e24e8c9__li" }; var Text = (0, import_element10.forwardRef)(function Text2({ variant = "body-md", render, className, ...props }, ref) { const element = useRender({ render, @@ -8704,44 +8704,6 @@ var Text = (0, import_element10.forwardRef)(function Text2({ variant = "body-md" return element; }); -// packages/icons/build-module/icon/index.mjs -var import_element11 = __toESM(require_element(), 1); -var icon_default = (0, import_element11.forwardRef)( - ({ icon, size: size4 = 24, ...props }, ref) => { - return (0, import_element11.cloneElement)(icon, { - width: size4, - height: size4, - ...props, - ref - }); - } -); - -// packages/icons/build-module/library/chevron-left.mjs -var import_primitives = __toESM(require_primitives(), 1); -var import_jsx_runtime12 = __toESM(require_jsx_runtime(), 1); -var chevron_left_default = /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_primitives.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_primitives.Path, { d: "M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z" }) }); - -// packages/icons/build-module/library/chevron-right.mjs -var import_primitives2 = __toESM(require_primitives(), 1); -var import_jsx_runtime13 = __toESM(require_jsx_runtime(), 1); -var chevron_right_default = /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_primitives2.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_primitives2.Path, { d: "M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z" }) }); - -// packages/icons/build-module/library/more-vertical.mjs -var import_primitives3 = __toESM(require_primitives(), 1); -var import_jsx_runtime14 = __toESM(require_jsx_runtime(), 1); -var more_vertical_default = /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_primitives3.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_primitives3.Path, { d: "M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z" }) }); - -// packages/icons/build-module/library/next.mjs -var import_primitives4 = __toESM(require_primitives(), 1); -var import_jsx_runtime15 = __toESM(require_jsx_runtime(), 1); -var next_default = /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_primitives4.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_primitives4.Path, { d: "M6.6 6L5.4 7l4.5 5-4.5 5 1.1 1 5.5-6-5.4-6zm6 0l-1.1 1 4.5 5-4.5 5 1.1 1 5.5-6-5.5-6z" }) }); - -// packages/icons/build-module/library/previous.mjs -var import_primitives5 = __toESM(require_primitives(), 1); -var import_jsx_runtime16 = __toESM(require_jsx_runtime(), 1); -var previous_default = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_primitives5.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_primitives5.Path, { d: "M11.6 7l-1.1-1L5 12l5.5 6 1.1-1L7 12l4.6-5zm6 0l-1.1-1-5.5 6 5.5 6 1.1-1-4.6-5 4.6-5z" }) }); - // packages/ui/build-module/tooltip/index.mjs var tooltip_exports = {}; __export(tooltip_exports, { @@ -8754,10 +8716,10 @@ __export(tooltip_exports, { }); // packages/ui/build-module/tooltip/popup.mjs -var import_element15 = __toESM(require_element(), 1); +var import_element14 = __toESM(require_element(), 1); // packages/ui/build-module/tooltip/portal.mjs -var import_element12 = __toESM(require_element(), 1); +var import_element11 = __toESM(require_element(), 1); // packages/ui/build-module/utils/wp-compat-overlay-slot.mjs var STYLE_HASH_ATTRIBUTE2 = "data-wp-hash"; @@ -8900,10 +8862,10 @@ function getWpCompatOverlaySlot() { } // packages/ui/build-module/tooltip/portal.mjs -var import_jsx_runtime17 = __toESM(require_jsx_runtime(), 1); -var Portal = (0, import_element12.forwardRef)( +var import_jsx_runtime12 = __toESM(require_jsx_runtime(), 1); +var Portal = (0, import_element11.forwardRef)( function TooltipPortal3({ container, ...restProps }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)( index_parts_exports.Portal, { container: container ?? getWpCompatOverlaySlot(), @@ -8915,8 +8877,8 @@ var Portal = (0, import_element12.forwardRef)( ); // packages/ui/build-module/tooltip/positioner.mjs -var import_element13 = __toESM(require_element(), 1); -var import_jsx_runtime18 = __toESM(require_jsx_runtime(), 1); +var import_element12 = __toESM(require_element(), 1); +var import_jsx_runtime13 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE3 = "data-wp-hash"; function getRuntime3() { const globalScope = globalThis; @@ -9005,9 +8967,9 @@ if (typeof process === "undefined" || true) { registerStyle3("19fcc06039", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}'); } var style_default2 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; -var Positioner = (0, import_element13.forwardRef)( +var Positioner = (0, import_element12.forwardRef)( function TooltipPositioner3({ align = "center", className, side = "top", sideOffset = 4, ...props }, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)( + return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)( index_parts_exports.Positioner, { ref, @@ -9026,9 +8988,9 @@ var Positioner = (0, import_element13.forwardRef)( ); // packages/ui/build-module/utils/render-slot-with-children.mjs -var import_element14 = __toESM(require_element(), 1); +var import_element13 = __toESM(require_element(), 1); function renderSlotWithChildren(slot, defaultSlot, children) { - return (0, import_element14.cloneElement)(slot ?? defaultSlot, { children }); + return (0, import_element13.cloneElement)(slot ?? defaultSlot, { children }); } // packages/ui/build-module/utils/theme-provider.mjs @@ -9059,7 +9021,7 @@ function getThemeProvider() { var ThemeProvider = getThemeProvider(); // packages/ui/build-module/tooltip/popup.mjs -var import_jsx_runtime19 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime14 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE4 = "data-wp-hash"; function getRuntime4() { const globalScope = globalThis; @@ -9145,8 +9107,8 @@ if (typeof process === "undefined" || true) { } var style_default3 = { "positioner": "_480b748dd3510e64__positioner", "popup": "_50096b232db7709d__popup" }; var POPUP_COLOR = { background: "#1e1e1e" }; -var Popup = (0, import_element15.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { - const popupContent = /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(ThemeProvider, { color: POPUP_COLOR, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)( +var Popup = (0, import_element14.forwardRef)(function TooltipPopup3({ portal, positioner, children, className, ...props }, ref) { + const popupContent = /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(ThemeProvider, { color: POPUP_COLOR, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)( index_parts_exports.Popup, { ref, @@ -9157,42 +9119,44 @@ var Popup = (0, import_element15.forwardRef)(function TooltipPopup3({ portal, po ) }); const positionedPopup = renderSlotWithChildren( positioner, - /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Positioner, {}), + /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Positioner, {}), popupContent ); - return renderSlotWithChildren(portal, /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(Portal, {}), positionedPopup); + return renderSlotWithChildren(portal, /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(Portal, {}), positionedPopup); }); // packages/ui/build-module/tooltip/trigger.mjs -var import_element16 = __toESM(require_element(), 1); -var import_jsx_runtime20 = __toESM(require_jsx_runtime(), 1); -var Trigger = (0, import_element16.forwardRef)( +var import_element15 = __toESM(require_element(), 1); +var import_jsx_runtime15 = __toESM(require_jsx_runtime(), 1); +var Trigger = (0, import_element15.forwardRef)( function TooltipTrigger3(props, ref) { - return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(index_parts_exports.Trigger, { ref, ...props }); + return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(index_parts_exports.Trigger, { ref, ...props }); } ); // packages/ui/build-module/utils/direction-provider.mjs var import_i18n = __toESM(require_i18n(), 1); -var import_jsx_runtime21 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime16 = __toESM(require_jsx_runtime(), 1); function DirectionProvider3({ children }) { - return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(DirectionProvider, { direction: (0, import_i18n.isRTL)() ? "rtl" : "ltr", children }); + return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(DirectionProvider, { direction: (0, import_i18n.isRTL)() ? "rtl" : "ltr", children }); } // packages/ui/build-module/tooltip/root.mjs -var import_jsx_runtime22 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime17 = __toESM(require_jsx_runtime(), 1); function Root(props) { - return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(DirectionProvider3, { children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(index_parts_exports.Root, { ...props }) }); + return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(DirectionProvider3, { children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(index_parts_exports.Root, { ...props }) }); } // packages/ui/build-module/tooltip/provider.mjs -var import_jsx_runtime23 = __toESM(require_jsx_runtime(), 1); +var import_jsx_runtime18 = __toESM(require_jsx_runtime(), 1); function Provider({ ...props }) { - return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(index_parts_exports.Provider, { ...props }); + return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(index_parts_exports.Provider, { ...props }); } -// packages/ui/build-module/visually-hidden/visually-hidden.mjs -var import_element17 = __toESM(require_element(), 1); +// packages/ui/build-module/link/link.mjs +var import_element16 = __toESM(require_element(), 1); +var import_i18n2 = __toESM(require_i18n(), 1); +var import_jsx_runtime19 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE5 = "data-wp-hash"; function getRuntime5() { const globalScope = globalThis; @@ -9274,28 +9238,111 @@ function registerStyle5(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle5("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); + registerStyle5("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); } -var style_default4 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; -var VisuallyHidden = (0, import_element17.forwardRef)( - function VisuallyHidden2({ render, ...restProps }, ref) { - const element = useRender({ - render, - ref, - props: mergeProps( - { className: style_default4["visually-hidden"] }, - restProps, - { - // @ts-expect-error Arbitrary data-* attributes aren't indexable on the typed div props. Kept hardcoded so consumers can't change or remove it. - "data-visually-hidden": "" - } - ) +var resets_default2 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; +if (typeof process === "undefined" || true) { + registerStyle5("08122b3d53", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); +} +var focus_module_default = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; +if (typeof process === "undefined" || true) { + registerStyle5("e8e6a9be37", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}'); +} +var style_default4 = { "link": "d4250949359b05ce__link", "is-brand": "c6055659b8e2cd2c__is-brand", "is-neutral": "_92e0dfcaeee15b88__is-neutral", "is-unstyled": "cf122a9bf1035d42__is-unstyled", "link-icon": "_0cb411afac4c86c7__link-icon" }; +if (typeof process === "undefined" || true) { + registerStyle5("e8e31009f5", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}"); +} +var global_css_defense_default2 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a", "ol": "c59a0ebebd71fa4a__ol", "li": "_46b5cb0c8e24e8c9__li" }; +var Link = (0, import_element16.forwardRef)(function Link2({ + children, + variant = "default", + tone = "brand", + openInNewTab = false, + target, + render, + className, + ...props +}, ref) { + const shouldShowNewTabIndicator = openInNewTab || /^_blank$/i.test(target ?? ""); + const element = useRender({ + render, + defaultTagName: "a", + ref, + props: mergeProps(props, { + className: clsx_default( + global_css_defense_default2.a, + resets_default2["box-sizing"], + focus_module_default["outset-ring--focus-except-active"], + variant !== "unstyled" && style_default4.link, + variant !== "unstyled" && style_default4[`is-${tone}`], + variant === "unstyled" && style_default4["is-unstyled"], + className + ), + target: target ?? (openInNewTab ? "_blank" : void 0), + children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(import_jsx_runtime19.Fragment, { children: [ + children, + shouldShowNewTabIndicator && /* @__PURE__ */ (0, import_jsx_runtime19.jsx)( + "span", + { + className: style_default4["link-icon"], + role: "img", + "aria-label": ( + /* translators: accessibility text appended to link text */ + (0, import_i18n2.__)("(opens in a new tab)") + ) + } + ) + ] }) + }) + }); + return element; +}); + +// packages/icons/build-module/icon/index.mjs +var import_element17 = __toESM(require_element(), 1); +var icon_default = (0, import_element17.forwardRef)( + ({ icon, size: size4 = 24, style, ...props }, ref) => { + const intrinsicStyle = icon.props.style; + const mergedStyle = intrinsicStyle || style ? { ...intrinsicStyle, ...style } : void 0; + return (0, import_element17.cloneElement)(icon, { + width: size4, + height: size4, + ...props, + // Merge styles so the icon's intrinsic style (e.g. `fill: none` on + // stroke-based icons) is preserved unless the consumer overrides + // the same property explicitly. + ...mergedStyle ? { style: mergedStyle } : {}, + ref }); - return element; } ); -// packages/ui/build-module/stack/stack.mjs +// packages/icons/build-module/library/chevron-left.mjs +var import_primitives = __toESM(require_primitives(), 1); +var import_jsx_runtime20 = __toESM(require_jsx_runtime(), 1); +var chevron_left_default = /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_primitives.Path, { d: "M14 6.5L9 12L14 17.5", vectorEffect: "non-scaling-stroke" }) }); + +// packages/icons/build-module/library/chevron-right.mjs +var import_primitives2 = __toESM(require_primitives(), 1); +var import_jsx_runtime21 = __toESM(require_jsx_runtime(), 1); +var chevron_right_default = /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_primitives2.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_primitives2.Path, { d: "M10 6.5L15 12L10 17.5", vectorEffect: "non-scaling-stroke" }) }); + +// packages/icons/build-module/library/more-vertical.mjs +var import_primitives3 = __toESM(require_primitives(), 1); +var import_jsx_runtime22 = __toESM(require_jsx_runtime(), 1); +var more_vertical_default = /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_primitives3.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_primitives3.Path, { d: "M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z" }) }); + +// packages/icons/build-module/library/next.mjs +var import_primitives4 = __toESM(require_primitives(), 1); +var import_jsx_runtime23 = __toESM(require_jsx_runtime(), 1); +var next_default = /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_primitives4.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_primitives4.Path, { d: "M7 17.5L12 12L7 6.5M13 17.5L18 12L13 6.5", vectorEffect: "non-scaling-stroke" }) }); + +// packages/icons/build-module/library/previous.mjs +var import_primitives5 = __toESM(require_primitives(), 1); +var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); +var previous_default = /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_primitives5.SVG, { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", style: { fill: "none" }, stroke: "currentColor", strokeWidth: "1.5", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_primitives5.Path, { d: "M17 6.5L12 12L17 17.5M11 6.5L6 12L11 17.5", vectorEffect: "non-scaling-stroke" }) }); + +// packages/ui/build-module/visually-hidden/visually-hidden.mjs var import_element18 = __toESM(require_element(), 1); var STYLE_HASH_ATTRIBUTE6 = "data-wp-hash"; function getRuntime6() { @@ -9378,38 +9425,29 @@ function registerStyle6(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle6("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); + registerStyle6("fa606a57ae", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}"); } -var style_default5 = { "stack": "_19ce0419607e1896__stack" }; -var gapTokens = { - xs: "var(--wpds-dimension-gap-xs, 4px)", - sm: "var(--wpds-dimension-gap-sm, 8px)", - md: "var(--wpds-dimension-gap-md, 12px)", - lg: "var(--wpds-dimension-gap-lg, 16px)", - xl: "var(--wpds-dimension-gap-xl, 24px)", - "2xl": "var(--wpds-dimension-gap-2xl, 32px)", - "3xl": "var(--wpds-dimension-gap-3xl, 40px)" -}; -var Stack = (0, import_element18.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { - const style = { - gap: gap && gapTokens[gap], - alignItems: align, - justifyContent: justify, - flexDirection: direction, - flexWrap: wrap - }; - const element = useRender({ - render, - ref, - props: mergeProps(props, { style, className: style_default5.stack }) - }); - return element; -}); +var style_default5 = { "visually-hidden": "f37b9e2e191ebd66__visually-hidden" }; +var VisuallyHidden = (0, import_element18.forwardRef)( + function VisuallyHidden2({ render, ...restProps }, ref) { + const element = useRender({ + render, + ref, + props: mergeProps( + { className: style_default5["visually-hidden"] }, + restProps, + { + // @ts-expect-error Arbitrary data-* attributes aren't indexable on the typed div props. Kept hardcoded so consumers can't change or remove it. + "data-visually-hidden": "" + } + ) + }); + return element; + } +); -// packages/ui/build-module/link/link.mjs +// packages/ui/build-module/stack/stack.mjs var import_element19 = __toESM(require_element(), 1); -var import_i18n2 = __toESM(require_i18n(), 1); -var import_jsx_runtime24 = __toESM(require_jsx_runtime(), 1); var STYLE_HASH_ATTRIBUTE7 = "data-wp-hash"; function getRuntime7() { const globalScope = globalThis; @@ -9491,60 +9529,30 @@ function registerStyle7(hash, css) { } } if (typeof process === "undefined" || true) { - registerStyle7("10f3806643", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}"); -} -var resets_default2 = { "box-sizing": "_336cd3e4e743482f__box-sizing" }; -if (typeof process === "undefined" || true) { - registerStyle7("96553466c8", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}"); -} -var focus_module_default = { "outset-ring--focus": "af79fb116edb0dd7__outset-ring--focus", "outset-ring--focus-visible": "dfcfdc28396e5d98__outset-ring--focus-visible", "outset-ring--focus-within": "e5cd9ee879f6403a__outset-ring--focus-within", "outset-ring--focus-within-visible": "_64de9947bf305b7a__outset-ring--focus-within-visible", "outset-ring--focus-parent-visible": "_81935a08e952f267__outset-ring--focus-parent-visible", "outset-ring--focus-except-active": "abc777e9713fa711__outset-ring--focus-except-active", "outset-ring--focus-within-except-active": "_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active" }; -if (typeof process === "undefined" || true) { - registerStyle7("e8e6a9be37", '@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}'); + registerStyle7("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}"); } -var style_default6 = { "link": "d4250949359b05ce__link", "is-brand": "c6055659b8e2cd2c__is-brand", "is-neutral": "_92e0dfcaeee15b88__is-neutral", "is-unstyled": "cf122a9bf1035d42__is-unstyled", "link-icon": "_0cb411afac4c86c7__link-icon" }; -if (typeof process === "undefined" || true) { - registerStyle7("af6d9984a6", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}"); -} -var global_css_defense_default2 = { "button": "_6defc79820e382c6__button", "input": "d2cff2e5dea83bd1__input", "textarea": "_547d86373d02e108__textarea", "div": "_8c15fd0ed9f28ba4__div", "p": "_43cec3e1eec1066d__p", "heading": "e97669c6d9a38497__heading", "a": "_2c0831b0499dbd6e__a" }; -var Link = (0, import_element19.forwardRef)(function Link2({ - children, - variant = "default", - tone = "brand", - openInNewTab = false, - render, - className, - ...props -}, ref) { +var style_default6 = { "stack": "_19ce0419607e1896__stack" }; +var gapTokens = { + xs: "var(--wpds-dimension-gap-xs, 4px)", + sm: "var(--wpds-dimension-gap-sm, 8px)", + md: "var(--wpds-dimension-gap-md, 12px)", + lg: "var(--wpds-dimension-gap-lg, 16px)", + xl: "var(--wpds-dimension-gap-xl, 24px)", + "2xl": "var(--wpds-dimension-gap-2xl, 32px)", + "3xl": "var(--wpds-dimension-gap-3xl, 40px)" +}; +var Stack = (0, import_element19.forwardRef)(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) { + const style = { + gap: gap && gapTokens[gap], + alignItems: align, + justifyContent: justify, + flexDirection: direction, + flexWrap: wrap + }; const element = useRender({ render, - defaultTagName: "a", ref, - props: mergeProps(props, { - className: clsx_default( - global_css_defense_default2.a, - resets_default2["box-sizing"], - focus_module_default["outset-ring--focus-except-active"], - variant !== "unstyled" && style_default6.link, - variant !== "unstyled" && style_default6[`is-${tone}`], - variant === "unstyled" && style_default6["is-unstyled"], - className - ), - target: openInNewTab ? "_blank" : void 0, - children: /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [ - children, - openInNewTab && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)( - "span", - { - className: style_default6["link-icon"], - role: "img", - "aria-label": ( - /* translators: accessibility text appended to link text */ - (0, import_i18n2.__)("(opens in a new tab)") - ) - } - ) - ] }) - }) + props: mergeProps(props, { style, className: style_default6.stack }) }); return element; }); @@ -10602,10 +10610,13 @@ function getResolvedValue(ruleValue, tree) { } const resolvedValue = getResolvedRefValue(ruleValue, tree); if (typeof resolvedValue === "object" && resolvedValue !== null && "url" in resolvedValue && resolvedValue?.url) { - resolvedValue.url = getResolvedThemeFilePath( - resolvedValue.url, - tree?._links?.["wp:theme-file"] - ); + return { + ...resolvedValue, + url: getResolvedThemeFilePath( + resolvedValue.url, + tree?._links?.["wp:theme-file"] + ) + }; } return resolvedValue; } @@ -10845,13 +10856,13 @@ function areGlobalStylesEqual(original, variation) { var import_deepmerge = __toESM(require_cjs(), 1); // node_modules/is-plain-object/dist/is-plain-object.mjs -function isObject(o3) { - return Object.prototype.toString.call(o3) === "[object Object]"; +function isObject(o2) { + return Object.prototype.toString.call(o2) === "[object Object]"; } -function isPlainObject(o3) { +function isPlainObject(o2) { var ctor, prot; - if (isObject(o3) === false) return false; - ctor = o3.constructor; + if (isObject(o2) === false) return false; + ctor = o2.constructor; if (ctor === void 0) return true; prot = ctor.prototype; if (isObject(prot) === false) return false; @@ -10893,11 +10904,11 @@ var r2 = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) }; var t = function(r3) { return "string" == typeof r3 ? r3.length > 0 : "number" == typeof r3; }; -var n = function(r3, t3, n2) { - return void 0 === t3 && (t3 = 0), void 0 === n2 && (n2 = Math.pow(10, t3)), Math.round(n2 * r3) / n2 + 0; +var n = function(r3, t2, n2) { + return void 0 === t2 && (t2 = 0), void 0 === n2 && (n2 = Math.pow(10, t2)), Math.round(n2 * r3) / n2 + 0; }; -var e = function(r3, t3, n2) { - return void 0 === t3 && (t3 = 0), void 0 === n2 && (n2 = 1), r3 > n2 ? n2 : r3 > t3 ? r3 : t3; +var e = function(r3, t2, n2) { + return void 0 === t2 && (t2 = 0), void 0 === n2 && (n2 = 1), r3 > n2 ? n2 : r3 > t2 ? r3 : t2; }; var u = function(r3) { return (r3 = isFinite(r3) ? r3 % 360 : 0) > 0 ? r3 : r3 + 360; @@ -10910,18 +10921,18 @@ var o = function(r3) { }; var i = /^#([0-9a-f]{3,8})$/i; var s = function(r3) { - var t3 = r3.toString(16); - return t3.length < 2 ? "0" + t3 : t3; + var t2 = r3.toString(16); + return t2.length < 2 ? "0" + t2 : t2; }; var h = function(r3) { - var t3 = r3.r, n2 = r3.g, e2 = r3.b, u2 = r3.a, a2 = Math.max(t3, n2, e2), o3 = a2 - Math.min(t3, n2, e2), i2 = o3 ? a2 === t3 ? (n2 - e2) / o3 : a2 === n2 ? 2 + (e2 - t3) / o3 : 4 + (t3 - n2) / o3 : 0; - return { h: 60 * (i2 < 0 ? i2 + 6 : i2), s: a2 ? o3 / a2 * 100 : 0, v: a2 / 255 * 100, a: u2 }; + var t2 = r3.r, n2 = r3.g, e2 = r3.b, u2 = r3.a, a2 = Math.max(t2, n2, e2), o2 = a2 - Math.min(t2, n2, e2), i2 = o2 ? a2 === t2 ? (n2 - e2) / o2 : a2 === n2 ? 2 + (e2 - t2) / o2 : 4 + (t2 - n2) / o2 : 0; + return { h: 60 * (i2 < 0 ? i2 + 6 : i2), s: a2 ? o2 / a2 * 100 : 0, v: a2 / 255 * 100, a: u2 }; }; var b = function(r3) { - var t3 = r3.h, n2 = r3.s, e2 = r3.v, u2 = r3.a; - t3 = t3 / 360 * 6, n2 /= 100, e2 /= 100; - var a2 = Math.floor(t3), o3 = e2 * (1 - n2), i2 = e2 * (1 - (t3 - a2) * n2), s2 = e2 * (1 - (1 - t3 + a2) * n2), h2 = a2 % 6; - return { r: 255 * [e2, i2, o3, o3, s2, e2][h2], g: 255 * [s2, e2, e2, i2, o3, o3][h2], b: 255 * [o3, o3, s2, e2, e2, i2][h2], a: u2 }; + var t2 = r3.h, n2 = r3.s, e2 = r3.v, u2 = r3.a; + t2 = t2 / 360 * 6, n2 /= 100, e2 /= 100; + var a2 = Math.floor(t2), o2 = e2 * (1 - n2), i2 = e2 * (1 - (t2 - a2) * n2), s2 = e2 * (1 - (1 - t2 + a2) * n2), h2 = a2 % 6; + return { r: 255 * [e2, i2, o2, o2, s2, e2][h2], g: 255 * [s2, e2, e2, i2, o2, o2][h2], b: 255 * [o2, o2, s2, e2, e2, i2][h2], a: u2 }; }; var g = function(r3) { return { h: u(r3.h), s: e(r3.s, 0, 100), l: e(r3.l, 0, 100), a: e(r3.a) }; @@ -10930,64 +10941,64 @@ var d = function(r3) { return { h: n(r3.h), s: n(r3.s), l: n(r3.l), a: n(r3.a, 3) }; }; var f = function(r3) { - return b((n2 = (t3 = r3).s, { h: t3.h, s: (n2 *= ((e2 = t3.l) < 50 ? e2 : 100 - e2) / 100) > 0 ? 2 * n2 / (e2 + n2) * 100 : 0, v: e2 + n2, a: t3.a })); - var t3, n2, e2; + return b((n2 = (t2 = r3).s, { h: t2.h, s: (n2 *= ((e2 = t2.l) < 50 ? e2 : 100 - e2) / 100) > 0 ? 2 * n2 / (e2 + n2) * 100 : 0, v: e2 + n2, a: t2.a })); + var t2, n2, e2; }; var c = function(r3) { - return { h: (t3 = h(r3)).h, s: (u2 = (200 - (n2 = t3.s)) * (e2 = t3.v) / 100) > 0 && u2 < 200 ? n2 * e2 / 100 / (u2 <= 100 ? u2 : 200 - u2) * 100 : 0, l: u2 / 2, a: t3.a }; - var t3, n2, e2, u2; + return { h: (t2 = h(r3)).h, s: (u2 = (200 - (n2 = t2.s)) * (e2 = t2.v) / 100) > 0 && u2 < 200 ? n2 * e2 / 100 / (u2 <= 100 ? u2 : 200 - u2) * 100 : 0, l: u2 / 2, a: t2.a }; + var t2, n2, e2, u2; }; var l = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i; var p2 = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i; var v = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i; var m = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i; var y = { string: [[function(r3) { - var t3 = i.exec(r3); - return t3 ? (r3 = t3[1]).length <= 4 ? { r: parseInt(r3[0] + r3[0], 16), g: parseInt(r3[1] + r3[1], 16), b: parseInt(r3[2] + r3[2], 16), a: 4 === r3.length ? n(parseInt(r3[3] + r3[3], 16) / 255, 2) : 1 } : 6 === r3.length || 8 === r3.length ? { r: parseInt(r3.substr(0, 2), 16), g: parseInt(r3.substr(2, 2), 16), b: parseInt(r3.substr(4, 2), 16), a: 8 === r3.length ? n(parseInt(r3.substr(6, 2), 16) / 255, 2) : 1 } : null : null; + var t2 = i.exec(r3); + return t2 ? (r3 = t2[1]).length <= 4 ? { r: parseInt(r3[0] + r3[0], 16), g: parseInt(r3[1] + r3[1], 16), b: parseInt(r3[2] + r3[2], 16), a: 4 === r3.length ? n(parseInt(r3[3] + r3[3], 16) / 255, 2) : 1 } : 6 === r3.length || 8 === r3.length ? { r: parseInt(r3.substr(0, 2), 16), g: parseInt(r3.substr(2, 2), 16), b: parseInt(r3.substr(4, 2), 16), a: 8 === r3.length ? n(parseInt(r3.substr(6, 2), 16) / 255, 2) : 1 } : null : null; }, "hex"], [function(r3) { - var t3 = v.exec(r3) || m.exec(r3); - return t3 ? t3[2] !== t3[4] || t3[4] !== t3[6] ? null : a({ r: Number(t3[1]) / (t3[2] ? 100 / 255 : 1), g: Number(t3[3]) / (t3[4] ? 100 / 255 : 1), b: Number(t3[5]) / (t3[6] ? 100 / 255 : 1), a: void 0 === t3[7] ? 1 : Number(t3[7]) / (t3[8] ? 100 : 1) }) : null; -}, "rgb"], [function(t3) { - var n2 = l.exec(t3) || p2.exec(t3); + var t2 = v.exec(r3) || m.exec(r3); + return t2 ? t2[2] !== t2[4] || t2[4] !== t2[6] ? null : a({ r: Number(t2[1]) / (t2[2] ? 100 / 255 : 1), g: Number(t2[3]) / (t2[4] ? 100 / 255 : 1), b: Number(t2[5]) / (t2[6] ? 100 / 255 : 1), a: void 0 === t2[7] ? 1 : Number(t2[7]) / (t2[8] ? 100 : 1) }) : null; +}, "rgb"], [function(t2) { + var n2 = l.exec(t2) || p2.exec(t2); if (!n2) return null; var e2, u2, a2 = g({ h: (e2 = n2[1], u2 = n2[2], void 0 === u2 && (u2 = "deg"), Number(e2) * (r2[u2] || 1)), s: Number(n2[3]), l: Number(n2[4]), a: void 0 === n2[5] ? 1 : Number(n2[5]) / (n2[6] ? 100 : 1) }); return f(a2); }, "hsl"]], object: [[function(r3) { - var n2 = r3.r, e2 = r3.g, u2 = r3.b, o3 = r3.a, i2 = void 0 === o3 ? 1 : o3; + var n2 = r3.r, e2 = r3.g, u2 = r3.b, o2 = r3.a, i2 = void 0 === o2 ? 1 : o2; return t(n2) && t(e2) && t(u2) ? a({ r: Number(n2), g: Number(e2), b: Number(u2), a: Number(i2) }) : null; }, "rgb"], [function(r3) { - var n2 = r3.h, e2 = r3.s, u2 = r3.l, a2 = r3.a, o3 = void 0 === a2 ? 1 : a2; + var n2 = r3.h, e2 = r3.s, u2 = r3.l, a2 = r3.a, o2 = void 0 === a2 ? 1 : a2; if (!t(n2) || !t(e2) || !t(u2)) return null; - var i2 = g({ h: Number(n2), s: Number(e2), l: Number(u2), a: Number(o3) }); + var i2 = g({ h: Number(n2), s: Number(e2), l: Number(u2), a: Number(o2) }); return f(i2); }, "hsl"], [function(r3) { - var n2 = r3.h, a2 = r3.s, o3 = r3.v, i2 = r3.a, s2 = void 0 === i2 ? 1 : i2; - if (!t(n2) || !t(a2) || !t(o3)) return null; + var n2 = r3.h, a2 = r3.s, o2 = r3.v, i2 = r3.a, s2 = void 0 === i2 ? 1 : i2; + if (!t(n2) || !t(a2) || !t(o2)) return null; var h2 = (function(r4) { return { h: u(r4.h), s: e(r4.s, 0, 100), v: e(r4.v, 0, 100), a: e(r4.a) }; - })({ h: Number(n2), s: Number(a2), v: Number(o3), a: Number(s2) }); + })({ h: Number(n2), s: Number(a2), v: Number(o2), a: Number(s2) }); return b(h2); }, "hsv"]] }; -var N = function(r3, t3) { - for (var n2 = 0; n2 < t3.length; n2++) { - var e2 = t3[n2][0](r3); - if (e2) return [e2, t3[n2][1]]; +var N = function(r3, t2) { + for (var n2 = 0; n2 < t2.length; n2++) { + var e2 = t2[n2][0](r3); + if (e2) return [e2, t2[n2][1]]; } return [null, void 0]; }; var x = function(r3) { return "string" == typeof r3 ? N(r3.trim(), y.string) : "object" == typeof r3 && null !== r3 ? N(r3, y.object) : [null, void 0]; }; -var M = function(r3, t3) { +var M = function(r3, t2) { var n2 = c(r3); - return { h: n2.h, s: e(n2.s + 100 * t3, 0, 100), l: n2.l, a: n2.a }; + return { h: n2.h, s: e(n2.s + 100 * t2, 0, 100), l: n2.l, a: n2.a }; }; var H = function(r3) { return (299 * r3.r + 587 * r3.g + 114 * r3.b) / 1e3 / 255; }; -var $ = function(r3, t3) { +var $ = function(r3, t2) { var n2 = c(r3); - return { h: n2.h, s: n2.s, l: e(n2.l + 100 * t3, 0, 100), a: n2.a }; + return { h: n2.h, s: n2.s, l: e(n2.l + 100 * t2, 0, 100), a: n2.a }; }; var j = (function() { function r3(r4) { @@ -11002,18 +11013,18 @@ var j = (function() { }, r3.prototype.isLight = function() { return H(this.rgba) >= 0.5; }, r3.prototype.toHex = function() { - return r4 = o(this.rgba), t3 = r4.r, e2 = r4.g, u2 = r4.b, i2 = (a2 = r4.a) < 1 ? s(n(255 * a2)) : "", "#" + s(t3) + s(e2) + s(u2) + i2; - var r4, t3, e2, u2, a2, i2; + return r4 = o(this.rgba), t2 = r4.r, e2 = r4.g, u2 = r4.b, i2 = (a2 = r4.a) < 1 ? s(n(255 * a2)) : "", "#" + s(t2) + s(e2) + s(u2) + i2; + var r4, t2, e2, u2, a2, i2; }, r3.prototype.toRgb = function() { return o(this.rgba); }, r3.prototype.toRgbString = function() { - return r4 = o(this.rgba), t3 = r4.r, n2 = r4.g, e2 = r4.b, (u2 = r4.a) < 1 ? "rgba(" + t3 + ", " + n2 + ", " + e2 + ", " + u2 + ")" : "rgb(" + t3 + ", " + n2 + ", " + e2 + ")"; - var r4, t3, n2, e2, u2; + return r4 = o(this.rgba), t2 = r4.r, n2 = r4.g, e2 = r4.b, (u2 = r4.a) < 1 ? "rgba(" + t2 + ", " + n2 + ", " + e2 + ", " + u2 + ")" : "rgb(" + t2 + ", " + n2 + ", " + e2 + ")"; + var r4, t2, n2, e2, u2; }, r3.prototype.toHsl = function() { return d(c(this.rgba)); }, r3.prototype.toHslString = function() { - return r4 = d(c(this.rgba)), t3 = r4.h, n2 = r4.s, e2 = r4.l, (u2 = r4.a) < 1 ? "hsla(" + t3 + ", " + n2 + "%, " + e2 + "%, " + u2 + ")" : "hsl(" + t3 + ", " + n2 + "%, " + e2 + "%)"; - var r4, t3, n2, e2, u2; + return r4 = d(c(this.rgba)), t2 = r4.h, n2 = r4.s, e2 = r4.l, (u2 = r4.a) < 1 ? "hsla(" + t2 + ", " + n2 + "%, " + e2 + "%, " + u2 + ")" : "hsl(" + t2 + ", " + n2 + "%, " + e2 + "%)"; + var r4, t2, n2, e2, u2; }, r3.prototype.toHsv = function() { return r4 = h(this.rgba), { h: n(r4.h), s: n(r4.s), v: n(r4.v), a: n(r4.a, 3) }; var r4; @@ -11033,11 +11044,11 @@ var j = (function() { }, r3.prototype.rotate = function(r4) { return void 0 === r4 && (r4 = 15), this.hue(this.hue() + r4); }, r3.prototype.alpha = function(r4) { - return "number" == typeof r4 ? w({ r: (t3 = this.rgba).r, g: t3.g, b: t3.b, a: r4 }) : n(this.rgba.a, 3); - var t3; + return "number" == typeof r4 ? w({ r: (t2 = this.rgba).r, g: t2.g, b: t2.b, a: r4 }) : n(this.rgba.a, 3); + var t2; }, r3.prototype.hue = function(r4) { - var t3 = c(this.rgba); - return "number" == typeof r4 ? w({ h: r4, s: t3.s, l: t3.l, a: t3.a }) : n(t3.h); + var t2 = c(this.rgba); + return "number" == typeof r4 ? w({ h: r4, s: t2.s, l: t2.l, a: t2.a }) : n(t2.h); }, r3.prototype.isEqual = function(r4) { return this.toHex() === w(r4).toHex(); }, r3; @@ -11045,12 +11056,6 @@ var j = (function() { var w = function(r3) { return r3 instanceof j ? r3 : new j(r3); }; -var S = []; -var k = function(r3) { - r3.forEach(function(r4) { - S.indexOf(r4) < 0 && (r4(j, y), S.push(r4)); - }); -}; // packages/global-styles-engine/build-module/utils/duotone.mjs function getValuesFromColors(colors = []) { @@ -11650,28 +11655,6 @@ var import_components3 = __toESM(require_components(), 1); var import_i18n6 = __toESM(require_i18n(), 1); var import_block_editor = __toESM(require_block_editor(), 1); -// node_modules/colord/plugins/a11y.mjs -var o2 = function(o3) { - var t3 = o3 / 255; - return t3 < 0.04045 ? t3 / 12.92 : Math.pow((t3 + 0.055) / 1.055, 2.4); -}; -var t2 = function(t3) { - return 0.2126 * o2(t3.r) + 0.7152 * o2(t3.g) + 0.0722 * o2(t3.b); -}; -function a11y_default(o3) { - o3.prototype.luminance = function() { - return o4 = t2(this.rgba), void 0 === (r3 = 2) && (r3 = 0), void 0 === n2 && (n2 = Math.pow(10, r3)), Math.round(n2 * o4) / n2 + 0; - var o4, r3, n2; - }, o3.prototype.contrast = function(r3) { - void 0 === r3 && (r3 = "#FFF"); - var n2, a2, i2, e2, v2, u2, d2, c2 = r3 instanceof o3 ? r3 : new o3(r3); - return e2 = this.rgba, v2 = c2.toRgb(), u2 = t2(e2), d2 = t2(v2), n2 = u2 > d2 ? (u2 + 0.05) / (d2 + 0.05) : (d2 + 0.05) / (u2 + 0.05), void 0 === (a2 = 2) && (a2 = 0), void 0 === i2 && (i2 = Math.pow(10, a2)), Math.floor(i2 * n2) / i2 + 0; - }, o3.prototype.isReadable = function(o4, t3) { - return void 0 === o4 && (o4 = "#FFF"), void 0 === t3 && (t3 = {}), this.contrast(o4) >= (e2 = void 0 === (i2 = (r3 = t3).size) ? "normal" : i2, "AAA" === (a2 = void 0 === (n2 = r3.level) ? "AA" : n2) && "normal" === e2 ? 7 : "AA" === a2 && "large" === e2 ? 3 : 4.5); - var r3, n2, a2, i2, e2; - }; -} - // packages/global-styles-ui/build-module/hooks.mjs var import_element24 = __toESM(require_element(), 1); var import_data = __toESM(require_data(), 1); @@ -11805,7 +11788,6 @@ function getFontFamilies(themeJson) { } // packages/global-styles-ui/build-module/hooks.mjs -k([a11y_default]); function useStyle(path, blockName, readFrom = "merged", shouldDecodeEncode = true, state) { const { user, base, merged, onChange } = (0, import_element24.useContext)(GlobalStylesContext); const statePathParts = state?.split(".").filter(Boolean) ?? []; @@ -12010,7 +11992,7 @@ function resolveFontWeight(fontWeight) { return String(Math.min(Math.max(400, start), end)); } function formatFontFamily(input) { - const regex = /^(?!generic\([ a-zA-Z\-]+\)$)(?!^[a-zA-Z\-]+$).+/; + const regex = /^(?!generic\([ a-zA-Z\-]+\)$)(?!var\(\s*--[\w-]+\s*\)$)(?!^[a-zA-Z\-]+$).+/; const output = input.trim(); const formatItem = (item) => { item = item.trim(); @@ -12922,12 +12904,12 @@ async function fetchInstallFontFace(fontFamilyId, data, registry) { // node_modules/tslib/tslib.es6.mjs var __assign = function() { - __assign = Object.assign || function __assign2(t3) { + __assign = Object.assign || function __assign2(t2) { for (var s2, i2 = 1, n2 = arguments.length; i2 < n2; i2++) { s2 = arguments[i2]; - for (var p3 in s2) if (Object.prototype.hasOwnProperty.call(s2, p3)) t3[p3] = s2[p3]; + for (var p3 in s2) if (Object.prototype.hasOwnProperty.call(s2, p3)) t2[p3] = s2[p3]; } - return t3; + return t2; }; return __assign.apply(this, arguments); }; @@ -13305,7 +13287,8 @@ function FontLibraryProvider({ children }) { const globalStyles = (0, import_core_data5.useEntityRecord)( "root", "globalStyles", - globalStylesId + globalStylesId ?? 0, + { enabled: globalStylesId !== void 0 } ); const [isInstalling, setIsInstalling] = (0, import_element31.useState)(false); const { records: libraryPosts = [], isResolving: isResolvingLibrary } = (0, import_core_data5.useEntityRecords)( @@ -13934,7 +13917,8 @@ function InstalledFonts() { const globalStyles = (0, import_core_data6.useEntityRecord)( "root", "globalStyles", - globalStylesId + globalStylesId ?? 0, + { enabled: globalStylesId !== void 0 } ); const editedFontFamilies = globalStyles?.edits?.settings?.typography?.fontFamilies; const savedFontFamilies = globalStyles?.record?.settings?.typography?.fontFamilies; @@ -14903,8 +14887,8 @@ var __require2 = /* @__PURE__ */ ((x2) => typeof __require !== "undefined" ? __r var unbrotli_default = (function() { var define, module, exports; return (/* @__PURE__ */ (function() { - function r3(e2, n2, t3) { - function o3(i22, f2) { + function r3(e2, n2, t2) { + function o2(i22, f2) { if (!n2[i22]) { if (!e2[i22]) { var c2 = "function" == typeof __require2 && __require2; @@ -14918,21 +14902,21 @@ var unbrotli_default = (function() { p3.exports, function(r22) { var n22 = e2[i22][1][r22]; - return o3(n22 || r22); + return o2(n22 || r22); }, p3, p3.exports, r3, e2, n2, - t3 + t2 ); } return n2[i22].exports; } - for (var u2 = "function" == typeof __require2 && __require2, i2 = 0; i2 < t3.length; i2++) - o3(t3[i2]); - return o3; + for (var u2 = "function" == typeof __require2 && __require2, i2 = 0; i2 < t2.length; i2++) + o2(t2[i2]); + return o2; } return r3; })())( @@ -18508,8 +18492,8 @@ var unbrotli_default = (function() { exports2.transformDictionaryWord = function(dst, idx, word, len, transform) { var prefix = kTransforms[transform].prefix; var suffix = kTransforms[transform].suffix; - var t3 = kTransforms[transform].transform; - var skip = t3 < kOmitFirst1 ? 0 : t3 - (kOmitFirst1 - 1); + var t2 = kTransforms[transform].transform; + var skip = t2 < kOmitFirst1 ? 0 : t2 - (kOmitFirst1 - 1); var i2 = 0; var start_idx = idx; var uppercase; @@ -18522,16 +18506,16 @@ var unbrotli_default = (function() { } word += skip; len -= skip; - if (t3 <= kOmitLast9) { - len -= t3; + if (t2 <= kOmitLast9) { + len -= t2; } for (i2 = 0; i2 < len; i2++) { dst[idx++] = BrotliDictionary.dictionary[word + i2]; } uppercase = idx - len; - if (t3 === kUppercaseFirst) { + if (t2 === kUppercaseFirst) { ToUpperCase(dst, uppercase); - } else if (t3 === kUppercaseAll) { + } else if (t2 === kUppercaseAll) { while (len > 0) { var step = ToUpperCase(dst, uppercase); uppercase += step; @@ -18569,8 +18553,8 @@ var __require3 = /* @__PURE__ */ ((x2) => typeof __require !== "undefined" ? __r var inflate_default = (function() { var define, module, exports; return (/* @__PURE__ */ (function() { - function r3(e2, n2, t3) { - function o3(i22, f2) { + function r3(e2, n2, t2) { + function o2(i22, f2) { if (!n2[i22]) { if (!e2[i22]) { var c2 = "function" == typeof __require3 && __require3; @@ -18584,21 +18568,21 @@ var inflate_default = (function() { p3.exports, function(r22) { var n22 = e2[i22][1][r22]; - return o3(n22 || r22); + return o2(n22 || r22); }, p3, p3.exports, r3, e2, n2, - t3 + t2 ); } return n2[i22].exports; } - for (var u2 = "function" == typeof __require3 && __require3, i2 = 0; i2 < t3.length; i2++) - o3(t3[i2]); - return o3; + for (var u2 = "function" == typeof __require3 && __require3, i2 = 0; i2 < t2.length; i2++) + o2(t2[i2]); + return o2; } return r3; })())( @@ -18918,7 +18902,7 @@ var inflate_default = (function() { var c2, table = []; for (var n2 = 0; n2 < 256; n2++) { c2 = n2; - for (var k2 = 0; k2 < 8; k2++) { + for (var k = 0; k < 8; k++) { c2 = c2 & 1 ? 3988292384 ^ c2 >>> 1 : c2 >>> 1; } table[n2] = c2; @@ -18927,10 +18911,10 @@ var inflate_default = (function() { } var crcTable = makeTable(); function crc32(crc, buf, len, pos) { - var t3 = crcTable, end = pos + len; + var t2 = crcTable, end = pos + len; crc ^= -1; for (var i2 = pos; i2 < end; i2++) { - crc = crc >>> 8 ^ t3[(crc ^ buf[i2]) & 255]; + crc = crc >>> 8 ^ t2[(crc ^ buf[i2]) & 255]; } return crc ^ -1; } @@ -21287,12 +21271,12 @@ var Parser = class { console.trace(); } get tag() { - const t3 = this.uint32; + const t2 = this.uint32; return asText([ - t3 >> 24 & 255, - t3 >> 16 & 255, - t3 >> 8 & 255, - t3 & 255 + t2 >> 24 & 255, + t2 >> 16 & 255, + t2 >> 8 & 255, + t2 & 255 ]); } get fixed() { @@ -22493,23 +22477,23 @@ var cmap = class extends SimpleTable { getGlyphId(char) { let last = 0; this.encodingRecords.some((_, tableID) => { - let t3 = this.getSubTable(tableID); - if (!t3.getGlyphId) return false; - last = t3.getGlyphId(char); + let t2 = this.getSubTable(tableID); + if (!t2.getGlyphId) return false; + last = t2.getGlyphId(char); return last !== 0; }); return last; } supports(char) { return this.encodingRecords.some((_, tableID) => { - const t3 = this.getSubTable(tableID); - return t3.supports && t3.supports(char) !== false; + const t2 = this.getSubTable(tableID); + return t2.supports && t2.supports(char) !== false; }); } supportsVariation(variation) { return this.encodingRecords.some((_, tableID) => { - const t3 = this.getSubTable(tableID); - return t3.supportsVariation && t3.supportsVariation(variation) !== false; + const t2 = this.getSubTable(tableID); + return t2.supportsVariation && t2.supportsVariation(variation) !== false; }); } }; @@ -25558,7 +25542,6 @@ var import_core_data11 = __toESM(require_core_data(), 1); var import_data11 = __toESM(require_data(), 1); var import_keycodes2 = __toESM(require_keycodes(), 1); var import_jsx_runtime92 = __toESM(require_jsx_runtime(), 1); -var { Badge: WCBadge } = unlock3(import_components51.privateApis); var DAY_IN_MILLISECONDS = 60 * 60 * 1e3 * 24; // packages/global-styles-ui/build-module/pagination/index.mjs @@ -25662,10 +25645,10 @@ var { unlock: unlock4 } = (0, import_private_apis5.__dangerousOptInToUnstableAPI ); // routes/font-list/style.scss -if (typeof document !== "undefined" && true && !document.head.querySelector("style[data-wp-hash='8316bac515']")) { +if (typeof document !== "undefined" && true && !document.head.querySelector("style[data-wp-hash='cb0e994672']")) { const style = document.createElement("style"); - style.setAttribute("data-wp-hash", "8316bac515"); - style.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-demo{position:relative}.font-library__font-card{border:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-image{transition:opacity var(--wpds-motion-duration-lg,.3s) var(--wpds-motion-easing-subtle,cubic-bezier(.15,0,.15,1))}}.font-library__font-card .font-library__font-variant_demo-image.is-loading{left:0;opacity:0;position:absolute;top:0}.font-library__font-card .font-library__font-variant-demo-skeleton{border-radius:var(--wpds-border-radius-sm,2px);height:24px}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-filter{margin-bottom:12px;padding:0 16px}.global-styles-ui-block-types-search{flex-grow:1}.global-styles-ui-block-types-item-list .global-styles-ui-block-types-item__icon{min-width:24px}.global-styles-ui-block-types-item-list__no-results{padding-top:16px}.global-styles-ui-block-types-item__indicator{background:var(--wp-admin-theme-color);border-radius:50%;flex:none;height:6px;margin-left:auto;width:6px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-duotone-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;max-height:calc(100% - 110px);overflow:auto}.font-library-page:has(.font-library__footer) .font-library-page__tab-panel{max-height:calc(100% - 198px)}')); + style.setAttribute("data-wp-hash", "cb0e994672"); + style.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-demo{position:relative}.font-library__font-card{border:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-image{transition:opacity var(--wpds-motion-duration-lg,.3s) var(--wpds-motion-easing-subtle,cubic-bezier(.15,0,.15,1))}}.font-library__font-card .font-library__font-variant_demo-image.is-loading{left:0;opacity:0;position:absolute;top:0}.font-library__font-card .font-library__font-variant-demo-skeleton{border-radius:var(--wpds-border-radius-sm,2px);height:24px}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-filter{margin-bottom:12px;padding:0 16px}.global-styles-ui-block-types-search{flex-grow:1}.global-styles-ui-block-types-item-list .global-styles-ui-block-types-item__icon{min-width:24px}.global-styles-ui-block-types-item-list__no-results{padding-top:16px}.global-styles-ui-block-types-item__indicator{background:var(--wp-admin-theme-color);border-radius:50%;flex:none;height:6px;margin-left:auto;width:6px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-duotone-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__content{background-color:var(--wpds-color-background-surface-neutral-strong,#fff);display:flex;flex-direction:column;flex-grow:1;min-height:0}.font-library-page:has(.font-library__footer) .font-library-page__content{padding-bottom:90px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;flex-shrink:0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;min-height:0;overflow:auto}')); document.head.appendChild(style); } @@ -25706,7 +25689,7 @@ function FontLibraryPage() { })) ); } - return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(page_default, { title: (0, import_i18n51.__)("Fonts"), className: "font-library-page", children: /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)( + return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(page_default, { title: (0, import_i18n51.__)("Fonts"), className: "font-library-page", children: /* @__PURE__ */ (0, import_jsx_runtime102.jsx)("div", { className: "font-library-page__content", children: /* @__PURE__ */ (0, import_jsx_runtime102.jsxs)( Tabs2, { selectedTabId: activeTab, @@ -25733,7 +25716,7 @@ function FontLibraryPage() { )) ] } - ) }); + ) }) }); } function Stage() { return /* @__PURE__ */ (0, import_jsx_runtime102.jsx)(FontLibraryPage, {}); diff --git a/src/wp-includes/build/routes/font-list/content.min.asset.php b/src/wp-includes/build/routes/font-list/content.min.asset.php index a14c8d81d4ff1..52c94b60391d7 100644 --- a/src/wp-includes/build/routes/font-list/content.min.asset.php +++ b/src/wp-includes/build/routes/font-list/content.min.asset.php @@ -1 +1 @@ - array('react', 'react-dom', 'react-jsx-runtime', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-date', 'wp-editor', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-private-apis', 'wp-style-engine', 'wp-theme', 'wp-warning'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '104b97a0cdd454e16bdd'); \ No newline at end of file + array('react', 'react-dom', 'react-jsx-runtime', 'wp-api-fetch', 'wp-block-editor', 'wp-blocks', 'wp-components', 'wp-compose', 'wp-core-data', 'wp-data', 'wp-date', 'wp-editor', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-private-apis', 'wp-style-engine', 'wp-theme', 'wp-warning'), 'module_dependencies' => array(array('id' => '@wordpress/a11y', 'import' => 'static'), array('id' => '@wordpress/route', 'import' => 'static')), 'version' => '2f4e31ce4772e1e3bc39'); \ No newline at end of file diff --git a/src/wp-includes/build/routes/font-list/content.min.js b/src/wp-includes/build/routes/font-list/content.min.js index 9b907e95bf431..9d11c3c25f435 100644 --- a/src/wp-includes/build/routes/font-list/content.min.js +++ b/src/wp-includes/build/routes/font-list/content.min.js @@ -1,4 +1,4 @@ -var Uv=Object.create;var ka=Object.defineProperty;var Wv=Object.getOwnPropertyDescriptor;var Gv=Object.getOwnPropertyNames;var Yv=Object.getPrototypeOf,qv=Object.prototype.hasOwnProperty;var Wt=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var tt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),so=(e,t)=>{for(var r in t)ka(e,r,{get:t[r],enumerable:!0})},Zv=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of Gv(t))!qv.call(e,n)&&n!==r&&ka(e,n,{get:()=>t[n],enumerable:!(o=Wv(t,n))||o.enumerable});return e};var f=(e,t,r)=>(r=e!=null?Uv(Yv(e)):{},Zv(t||!e||!e.__esModule?ka(r,"default",{value:e,enumerable:!0}):r,e));var ge=tt((ME,zu)=>{zu.exports=window.wp.i18n});var Te=tt((DE,Uu)=>{Uu.exports=window.wp.element});var ve=tt((BE,Wu)=>{Wu.exports=window.React});var Z=tt((YE,Zu)=>{Zu.exports=window.ReactJSXRuntime});var lo=tt((jT,wf)=>{wf.exports=window.ReactDOM});var xd=tt(wd=>{"use strict";var fn=ve();function Z0(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var X0=typeof Object.is=="function"?Object.is:Z0,K0=fn.useState,J0=fn.useEffect,Q0=fn.useLayoutEffect,$0=fn.useDebugValue;function ew(e,t){var r=t(),o=K0({inst:{value:r,getSnapshot:t}}),n=o[0].inst,i=o[1];return Q0(function(){n.value=r,n.getSnapshot=t,dl(n)&&i({inst:n})},[e,r,t]),J0(function(){return dl(n)&&i({inst:n}),e(function(){dl(n)&&i({inst:n})})},[e]),$0(r),r}function dl(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!X0(e,r)}catch{return!0}}function tw(e,t){return t()}var rw=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?tw:ew;wd.useSyncExternalStore=fn.useSyncExternalStore!==void 0?fn.useSyncExternalStore:rw});var ts=tt((FO,Sd)=>{"use strict";Sd.exports=xd()});var _d=tt(Cd=>{"use strict";var rs=ve(),ow=ts();function nw(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var iw=typeof Object.is=="function"?Object.is:nw,sw=ow.useSyncExternalStore,aw=rs.useRef,lw=rs.useEffect,cw=rs.useMemo,uw=rs.useDebugValue;Cd.useSyncExternalStoreWithSelector=function(e,t,r,o,n){var i=aw(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=cw(function(){function u(h){if(!l){if(l=!0,c=h,h=o(h),n!==void 0&&s.hasValue){var g=s.value;if(n(g,h))return m=g}return m=h}if(g=m,iw(c,h))return g;var b=o(h);return n!==void 0&&n(g,b)?(c=h,g):(c=h,m=b)}var l=!1,c,m,d=r===void 0?null:r;return[function(){return u(t())},d===null?void 0:function(){return u(d())}]},[t,r,o,n]);var a=sw(e,i[0],i[1]);return lw(function(){s.hasValue=!0,s.value=a},[a]),uw(a),a}});var Ed=tt((IO,Rd)=>{"use strict";Rd.exports=_d()});var xn=tt((B5,rm)=>{rm.exports=window.wp.primitives});var yo=tt((j5,om)=>{om.exports=window.wp.compose});var gm=tt((uA,hm)=>{hm.exports=window.wp.theme});var li=tt((fA,ym)=>{ym.exports=window.wp.privateApis});var ue=tt((w4,Jm)=>{Jm.exports=window.wp.components});var sh=tt((L4,ih)=>{ih.exports=window.wp.editor});var sr=tt((N4,ah)=>{ah.exports=window.wp.coreData});var Kt=tt((M4,lh)=>{lh.exports=window.wp.data});var _n=tt((V4,ch)=>{ch.exports=window.wp.blocks});var Dt=tt((D4,uh)=>{uh.exports=window.wp.blockEditor});var dh=tt((W4,fh)=>{fh.exports=window.wp.styleEngine});var bh=tt((rI,vh)=>{"use strict";vh.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var o,n,i;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;for(n of t.entries())if(!e(n[1],r.get(n[0])))return!1;return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(t[n]!==r[n])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),o=i.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[n]))return!1;for(n=o;n--!==0;){var s=i[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var Ch=tt((nI,Sh)=>{"use strict";var W1=function(t){return G1(t)&&!Y1(t)};function G1(e){return!!e&&typeof e=="object"}function Y1(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||X1(e)}var q1=typeof Symbol=="function"&&Symbol.for,Z1=q1?Symbol.for("react.element"):60103;function X1(e){return e.$$typeof===Z1}function K1(e){return Array.isArray(e)?[]:{}}function mi(e,t){return t.clone!==!1&&t.isMergeableObject(e)?En(K1(e),e,t):e}function J1(e,t,r){return e.concat(t).map(function(o){return mi(o,r)})}function Q1(e,t){if(!t.customMerge)return En;var r=t.customMerge(e);return typeof r=="function"?r:En}function $1(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function wh(e){return Object.keys(e).concat($1(e))}function xh(e,t){try{return t in e}catch{return!1}}function ex(e,t){return xh(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function tx(e,t,r){var o={};return r.isMergeableObject(e)&&wh(e).forEach(function(n){o[n]=mi(e[n],r)}),wh(t).forEach(function(n){ex(e,n)||(xh(e,n)&&r.isMergeableObject(t[n])?o[n]=Q1(n,r)(e[n],t[n],r):o[n]=mi(t[n],r))}),o}function En(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||J1,r.isMergeableObject=r.isMergeableObject||W1,r.cloneUnlessOtherwiseSpecified=mi;var o=Array.isArray(t),n=Array.isArray(e),i=o===n;return i?o?r.arrayMerge(e,t,r):tx(e,t,r):mi(t,r)}En.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(o,n){return En(o,n,r)},{})};var rx=En;Sh.exports=rx});var Qc=tt((JN,Ng)=>{Ng.exports=window.wp.keycodes});var Bg=tt((c8,Dg)=>{Dg.exports=window.wp.apiFetch});var Sv=tt((o7,xv)=>{xv.exports=window.wp.date});function Hu(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;te();function Pe(e){let t=Ct(Qv).current;return t.next=e,Jv(t.effect),t.trampoline}function Qv(){let e={next:void 0,callback:$v,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function $v(){}var qu=f(ve(),1),eb=()=>{},we=typeof document<"u"?qu.useLayoutEffect:eb;function tb(e,t){return function(o,...n){let i=new URL(e);return i.searchParams.set("code",o.toString()),n.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${o}; visit ${i} for the full message.`}}var rb=tb("https://base-ui.com/production-error","Base UI"),lr=rb;var Ao=f(ve(),1);function Aa(e,t,r,o){let n=Ct(Ku).current;return ob(n,e,t,r,o)&&Ju(n,[e,t,r,o]),n.callback}function Xu(e){let t=Ct(Ku).current;return nb(t,e)&&Ju(t,e),t.callback}function Ku(){return{callback:null,cleanup:null,refs:[]}}function ob(e,t,r,o,n){return e.refs[0]!==t||e.refs[1]!==r||e.refs[2]!==o||e.refs[3]!==n}function nb(e,t){return e.refs.length!==t.length||e.refs.some((r,o)=>r!==t[o])}function Ju(e,t){if(e.refs=t,t.every(r=>r==null)){e.callback=null;return}e.callback=r=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),r!=null){let o=Array(t.length).fill(null);for(let n=0;n{for(let n=0;n=e}function Ia(e){if(!$u.isValidElement(e))return null;let t=e,r=t.props;return(rn(19)?r?.ref:t.ref)??null}function Yn(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function tr(){}var ef=Object.freeze([]),nt=Object.freeze({});function tf(e,t){let r={};for(let o in e){let n=e[o];if(t?.hasOwnProperty(o)){let i=t[o](n);i!=null&&Object.assign(r,i);continue}n===!0?r[`data-${o.toLowerCase()}`]="":n&&(r[`data-${o.toLowerCase()}`]=n.toString())}return r}function rf(e,t){return typeof e=="function"?e(t):e}function of(e,t){return typeof e=="function"?e(t):e}var La={};function It(e,t,r,o,n){if(!r&&!o&&!n&&!e)return Ai(t);let i=Ai(e);return t&&(i=qn(i,t)),r&&(i=qn(i,r)),o&&(i=qn(i,o)),n&&(i=qn(i,n)),i}function nf(e){if(e.length===0)return La;if(e.length===1)return Ai(e[0]);let t=Ai(e[0]);for(let r=1;r=65&&n<=90&&(typeof t=="function"||typeof t>"u")}function Na(e){return typeof e=="function"}function af(e,t){return Na(e)?e(t):e??La}function lb(e,t){return t?e?(...r)=>{let o=r[0];if(uf(o)){let i=o;cf(i);let s=t(...r);return i.baseUIHandlerPrevented||e?.(...r),s}let n=t(...r);return e?.(...r),n}:lf(t):e}function lf(e){return e&&((...t)=>{let r=t[0];return uf(r)&&cf(r),e(...t)})}function cf(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Ma(e,t){return t?e?t+" "+e:t:e}function uf(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var Va=f(ve(),1);function Gt(e,t,r={}){let o=t.render,n=cb(t,r);if(r.enabled===!1)return null;let i=r.state??nt;return db(e,o,n,i)}function cb(e,t={}){let{className:r,style:o,render:n}=e,{state:i=nt,ref:s,props:a,stateAttributesMapping:u,enabled:l=!0}=t,c=l?rf(r,i):void 0,m=l?of(o,i):void 0,d=l?tf(i,u):nt,h=l&&a?ub(a):void 0,g=l?Yn(d,h)??{}:nt;return typeof document<"u"&&(l?Array.isArray(s)?g.ref=Xu([g.ref,Ia(n),...s]):g.ref=Aa(g.ref,Ia(n),s):Aa(null,null)),l?(c!==void 0&&(g.className=Ma(g.className,c)),m!==void 0&&(g.style=Yn(g.style,m)),g):nt}function ub(e){return Array.isArray(e)?nf(e):It(void 0,e)}var fb=Symbol.for("react.lazy");function db(e,t,r,o){if(t){if(typeof t=="function")return t(r,o);let n=It(r,t.props);n.ref=r.ref;let i=t;return i?.$$typeof===fb&&(i=Ao.Children.toArray(t)[0]),Ao.cloneElement(i,n)}if(e&&typeof e=="string")return pb(e,r);throw new Error(lr(8))}function pb(e,t){return e==="button"?(0,Va.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,Va.createElement)("img",{alt:"",...t,key:t.key}):Ao.createElement(e,t)}var Ii=f(ve(),1);var ff=0;function mb(e,t="mui"){let[r,o]=Ii.useState(e),n=e||r;return Ii.useEffect(()=>{r==null&&(ff+=1,o(`${t}-${ff}`))},[r,t]),n}var df=Gn.useId;function on(e,t){if(df!==void 0){let r=df();return e??(t?`${t}-${r}`:r)}return mb(e,t)}function pf(e){return on(e,"base-ui")}var Oe={};so(Oe,{cancelOpen:()=>Hb,chipRemovePress:()=>_b,clearPress:()=>Cb,closePress:()=>xb,closeWatcher:()=>Nb,decrementPress:()=>Tb,disabled:()=>Wb,drag:()=>Bb,escapeKey:()=>Lb,focusOut:()=>Ib,imperativeAction:()=>qb,incrementPress:()=>Eb,initial:()=>Yb,inputBlur:()=>kb,inputChange:()=>Pb,inputClear:()=>Ob,inputPaste:()=>Fb,inputPress:()=>Ab,itemPress:()=>wb,keyboard:()=>Vb,linkPress:()=>Sb,listNavigation:()=>Mb,missing:()=>Gb,none:()=>hb,outsidePress:()=>bb,pointer:()=>Db,scrub:()=>zb,siblingOpen:()=>Ub,swipe:()=>Zb,trackPress:()=>Rb,triggerFocus:()=>vb,triggerHover:()=>yb,triggerPress:()=>gb,wheel:()=>jb,windowResize:()=>Xb});var hb="none",gb="trigger-press",yb="trigger-hover",vb="trigger-focus",bb="outside-press",wb="item-press",xb="close-press",Sb="link-press",Cb="clear-press",_b="chip-remove-press",Rb="track-press",Eb="increment-press",Tb="decrement-press",Pb="input-change",Ob="input-clear",kb="input-blur",Fb="input-paste",Ab="input-press",Ib="focus-out",Lb="escape-key",Nb="close-watcher",Mb="list-navigation",Vb="keyboard",Db="pointer",Bb="drag",jb="wheel",zb="scrub",Hb="cancel-open",Ub="sibling-open",Wb="disabled",Gb="missing",Yb="initial",qb="imperative-action",Zb="swipe",Xb="window-resize";function De(e,t,r,o){let n=!1,i=!1,s=o??nt;return{reason:e,event:t??new Event("base-ui"),cancel(){n=!0},allowPropagation(){i=!0},get isCanceled(){return n},get isPropagationAllowed(){return i},trigger:r,...s}}var Ba=f(ve(),1);var mf=f(ve(),1);function nn(e){mf.useEffect(e,ef)}var Li=null,TT=globalThis.requestAnimationFrame,Da=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let r=this.callbacks,o=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,o>0)for(let n=0;n=this.callbacks.length||(this.callbacks[r]=null,this.callbacksCount-=1)}},Ni=new Da;var kr=class e{static create(){return new e}static request(t){return Ni.request(t)}static cancel(t){return Ni.cancel(t)}currentId=Li;request(t){this.cancel(),this.currentId=Ni.request(()=>{this.currentId=Li,t()})}cancel=()=>{this.currentId!==Li&&(Ni.cancel(this.currentId),this.currentId=Li)};disposeEffect=()=>this.cancel};function sn(){let e=Ct(kr.create).current;return nn(e.disposeEffect),e}function hf(e,t=!1,r=!1){let[o,n]=Ba.useState(e&&t?"idle":void 0),[i,s]=Ba.useState(e);return e&&!i&&(s(!0),n("starting")),!e&&i&&o!=="ending"&&!r&&n("ending"),!e&&!i&&o==="ending"&&n(void 0),we(()=>{if(!e&&i&&o!=="ending"&&r){let a=kr.request(()=>{n("ending")});return()=>{kr.cancel(a)}}},[e,i,o,r]),we(()=>{if(!e||t)return;let a=kr.request(()=>{n(void 0)});return()=>{kr.cancel(a)}},[t,e]),we(()=>{if(!e||!t)return;e&&i&&o!=="idle"&&n("starting");let a=kr.request(()=>{n("idle")});return()=>{kr.cancel(a)}},[t,e,i,o]),{mounted:i,setMounted:s,transitionStatus:o}}var ja=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),Kb={"data-starting-style":""},Jb={"data-ending-style":""},gf={transitionStatus(e){return e==="starting"?Kb:e==="ending"?Jb:null}};function Mi(){return typeof window<"u"}function Lo(e){return Vi(e)?(e.nodeName||"").toLowerCase():"#document"}function it(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ar(e){var t;return(t=(Vi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Vi(e){return Mi()?e instanceof Node||e instanceof it(e).Node:!1}function Re(e){return Mi()?e instanceof Element||e instanceof it(e).Element:!1}function _t(e){return Mi()?e instanceof HTMLElement||e instanceof it(e).HTMLElement:!1}function an(e){return!Mi()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof it(e).ShadowRoot}function Zn(e){let{overflow:t,overflowX:r,overflowY:o,display:n}=Lt(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+r)&&n!=="inline"&&n!=="contents"}function yf(e){return/^(table|td|th)$/.test(Lo(e))}function Xn(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var Qb=/transform|translate|scale|rotate|perspective|filter/,$b=/paint|layout|strict|content/,Io=e=>!!e&&e!=="none",za;function Di(e){let t=Re(e)?Lt(e):e;return Io(t.transform)||Io(t.translate)||Io(t.scale)||Io(t.rotate)||Io(t.perspective)||!Bi()&&(Io(t.backdropFilter)||Io(t.filter))||Qb.test(t.willChange||"")||$b.test(t.contain||"")}function vf(e){let t=Fr(e);for(;_t(t)&&!Ir(t);){if(Di(t))return t;if(Xn(t))return null;t=Fr(t)}return null}function Bi(){return za==null&&(za=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),za}function Ir(e){return/^(html|body|#document)$/.test(Lo(e))}function Lt(e){return it(e).getComputedStyle(e)}function Kn(e){return Re(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Fr(e){if(Lo(e)==="html")return e;let t=e.assignedSlot||e.parentNode||an(e)&&e.host||Ar(e);return an(t)?t.host:t}function bf(e){let t=Fr(e);return Ir(t)?(e.ownerDocument||e).body:_t(t)&&Zn(t)?t:bf(t)}function ao(e,t,r){var o;t===void 0&&(t=[]),r===void 0&&(r=!0);let n=bf(e),i=n===((o=e.ownerDocument)==null?void 0:o.body),s=it(n);if(i){let a=ji(s);return t.concat(s,s.visualViewport||[],Zn(n)?n:[],a&&r?ao(a):[])}else return t.concat(n,ao(n,[],r))}function ji(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Rt(e){return e?.ownerDocument||document}function ze(e,t,r,o){return e.addEventListener(t,r,o),()=>{e.removeEventListener(t,r,o)}}function Yt(e){let t=Ct(e0,e).current;return t.next=e,we(t.effect),t}function e0(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var Cf=f(ve(),1);var Sf=f(lo(),1);function xf(e){return e==null?e:"current"in e?e.current:e}function ln(e,t=!1){let r=sn();return Pe((o,n=null)=>{r.cancel();let i=xf(e);if(i==null)return;let s=i,a=()=>{Sf.flushSync(o)};if(typeof s.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){o();return}function u(){Promise.all(s.getAnimations().map(l=>l.finished)).then(()=>{n?.aborted||a()},()=>{if(n?.aborted)return;if(s.getAnimations().some(c=>c.pending||c.playState!=="finished")){u();return}a()})}if(t){let l="data-starting-style";if(!s.hasAttribute(l)){r.request(u);return}let c=new MutationObserver(()=>{s.hasAttribute(l)||(c.disconnect(),u())});c.observe(s,{attributes:!0,attributeFilter:[l]}),n?.addEventListener("abort",()=>c.disconnect(),{once:!0});return}r.request(u)})}function zi(e){let{enabled:t=!0,open:r,ref:o,onComplete:n}=e,i=Pe(n),s=ln(o,r);Cf.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,r,i,s])}var Zr={};so(Zr,{engine:()=>Ya,env:()=>Za,os:()=>Wa,screenReader:()=>qa});var Wa={};so(Wa,{android:()=>Ef,apple:()=>Ua,ios:()=>Ha,linux:()=>i0,mac:()=>Tf,windows:()=>n0});function t0(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:r0,platform:o0,maxTouchPoints:_f}=t0(),No=r0.toLowerCase(),Mo=o0.toLowerCase();var Ha=/^i(os$|p)/.test(Mo)||Mo==="macintel"&&_f>1,Rf="android",Ef=Mo===Rf||No.includes(Rf),Tf=!Ha&&Mo.startsWith("mac"),n0=Mo.startsWith("win"),i0=!Ef&&/^(linux|chrome os)/.test(Mo),Ua=Tf||Ha;var Ya={};so(Ya,{blink:()=>a0,gecko:()=>s0,webkit:()=>Ga});var Ga=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),s0=!Ga&&No.includes("firefox"),a0=!Ga&&No.includes("chrom");var qa={};so(qa,{voiceOver:()=>l0});var l0=Ua;var Za={};so(Za,{jsdom:()=>c0});var c0=/jsdom|happydom/.test(No);var Jn=0,rr=class e{static create(){return new e}currentId=Jn;start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Jn,r()},t)}isStarted(){return this.currentId!==Jn}clear=()=>{this.currentId!==Jn&&(clearTimeout(this.currentId),this.currentId=Jn)};disposeEffect=()=>this.clear};function xr(){let e=Ct(rr.create).current;return nn(e.disposeEffect),e}var Mt=f(ve(),1);function Pf(e){return"nativeEvent"in e}function Xr(e,t){let r=["mouse","pen"];return t||r.push("",void 0),r.includes(e)}function Of(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var Xa="data-base-ui-focusable";var Ka="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Hi(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function Ge(e,t){if(!e||!t)return!1;let r=t.getRootNode?.();if(e.contains(t))return!0;if(r&&an(r)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Nt(e){return"composedPath"in e?e.composedPath()[0]:e.target}function co(e,t){if(!Re(e))return!1;let r=e;if(t.hasElement(r))return!r.hasAttribute("data-trigger-disabled");for(let[,o]of t.entries())if(Ge(o,r))return!o.hasAttribute("data-trigger-disabled");return!1}function Ui(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let r=e;return r.target!=null&&t.contains(r.target)}function kf(e){return e.matches("html,body")}function Ff(e){return _t(e)&&e.matches(Ka)}function Ja(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${Ka}`)!=null}function Af(e){if(!e||Zr.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function u0(e,t){return t!=null&&!Xr(t)?0:typeof e=="function"?e():e}function cr(e,t,r){let o=u0(e,r);return typeof o=="number"?o:o?.[t]}function Qa(e){return typeof e=="function"?e():e}function Wi(e,t){return t||e==="click"||e==="mousedown"}function If(e){return e?.includes("mouse")&&e!=="mousedown"}var Lf=f(Z(),1),Nf=Mt.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new rr,currentIdRef:{current:null},currentContextRef:{current:null}});function f0(e,t){e.current=t.current}function $a(e){let{children:t,delay:r,timeoutMs:o=0}=e,n=Mt.useRef(r),i=Mt.useRef(r),s=Mt.useRef(null),a=Mt.useRef(null),u=xr();return we(()=>{if(i.current=r,!s.current){n.current=r;return}n.current={open:cr(n.current,"open"),close:cr(r,"close")}},[r,s,n,i]),(0,Lf.jsx)(Nf.Provider,{value:Mt.useMemo(()=>({hasProvider:!0,delayRef:n,initialDelayRef:i,currentIdRef:s,timeoutMs:o,currentContextRef:a,timeout:u}),[o,u]),children:t})}function el(e,t={open:!1}){let{open:r}=t,o="rootStore"in e?e.rootStore:e,n=o.useState("floatingId"),i=Mt.useContext(Nf),{currentIdRef:s,delayRef:a,timeoutMs:u,initialDelayRef:l,currentContextRef:c,hasProvider:m,timeout:d}=i,[h,g]=Mt.useState(!1),b=Mt.useRef(r);return we(()=>{b.current=r},[r]),we(()=>{function w(){c.current?.setIsInstantPhase(!1),s.current=null,c.current=null,a.current=l.current,d.clear()}if(s.current&&!r&&s.current===n){if(g(!1),u){let C=n;return d.start(u,()=>{o.select("open")||s.current&&s.current!==C||w()}),()=>{(b.current||s.current!==C)&&d.clear()}}w()}},[r,n,s,a,u,l,c,d,o]),we(()=>{if(!r)return;let w=c.current,C=s.current;d.clear(),c.current={onOpenChange:o.setOpen,setIsInstantPhase:g},s.current=n,a.current={open:0,close:cr(l.current,"close")},C!==null&&C!==n?(g(!0),w?.setIsInstantPhase(!0),w?.onOpenChange(!1,De(Oe.none))):(g(!1),w?.setIsInstantPhase(!1))},[r,n,o,s,a,l,c,d]),we(()=>()=>{if(s.current===n){if(c.current=null,!b.current)return;s.current=null,f0(a,l),d.clear()}},[c,s,a,n,l,d]),Mt.useMemo(()=>({hasProvider:m,delayRef:a,isInstantPhase:h}),[m,a,h])}function Sr(...e){return()=>{for(let t=0;t({x:e,y:e}),d0={left:"right",right:"left",bottom:"top",top:"bottom"};function Yi(e,t,r){return Cr(e,uo(t,r))}function Nr(e,t){return typeof e=="function"?e(t):e}function Tt(e){return e.split("-")[0]}function _r(e){return e.split("-")[1]}function qi(e){return e==="x"?"y":"x"}function ei(e){return e==="y"?"height":"width"}function qt(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function ti(e){return qi(qt(e))}function Df(e,t,r){r===void 0&&(r=!1);let o=_r(e),n=ti(e),i=ei(n),s=n==="x"?o===(r?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Qn(s)),[s,Qn(s)]}function Bf(e){let t=Qn(e);return[Gi(e),t,Gi(t)]}function Gi(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var Mf=["left","right"],Vf=["right","left"],p0=["top","bottom"],m0=["bottom","top"];function h0(e,t,r){switch(e){case"top":case"bottom":return r?t?Vf:Mf:t?Mf:Vf;case"left":case"right":return t?p0:m0;default:return[]}}function jf(e,t,r,o){let n=_r(e),i=h0(Tt(e),r==="start",o);return n&&(i=i.map(s=>s+"-"+n),t&&(i=i.concat(i.map(Gi)))),i}function Qn(e){let t=Tt(e);return d0[t]+e.slice(t.length)}function g0(e){var t,r,o,n;return{top:(t=e.top)!=null?t:0,right:(r=e.right)!=null?r:0,bottom:(o=e.bottom)!=null?o:0,left:(n=e.left)!=null?n:0}}function Zi(e){return typeof e!="number"?g0(e):{top:e,right:e,bottom:e,left:e}}function Vo(e){let{x:t,y:r,width:o,height:n}=e;return{width:o,height:n,top:r,left:t,right:t+o,bottom:r+n,x:t,y:r}}function Kr(e,t,r=!0){return e.filter(n=>n.parentId===t).flatMap(n=>[...!r||n.context?.open?[n]:[],...Kr(e,n.id,r)])}function cn(e){return`data-base-ui-${e}`}var Vt=f(ve(),1),Uf=f(lo(),1);var zf={style:{transition:"none"}};var y0="data-base-ui-swipe-ignore",v0="data-swipe-ignore",EP=`[${y0}]`,TP=`[${v0}]`;var Hf={fallbackAxisSide:"end"};var Wf=f(Z(),1),b0=Vt.createContext(null),w0=()=>Vt.useContext(b0),x0=cn("portal");function Gf(e={}){let{ref:t,container:r,componentProps:o=nt,elementProps:n}=e,i=on(),a=w0()?.portalNode,[u,l]=Vt.useState(null),[c,m]=Vt.useState(null),d=Pe(w=>{w!==null&&m(w)}),h=Vt.useRef(null);we(()=>{if(r===null){h.current&&(h.current=null,m(null),l(null));return}let w=(r&&(Vi(r)?r:r.current))??a??document.body;if(w==null){h.current&&(h.current=null,m(null),l(null));return}h.current!==w&&(h.current=w,m(null),l(w))},[r,a]);let g=Gt("div",o,{ref:[t,d],props:[{id:i,[x0]:""},n]}),b=u&&g?Uf.createPortal(g,u):null;return{node:c,nodeId:Vt.isValidElement(g)?g.props.id:void 0,subtree:b}}var Do=f(ve(),1);function Yf(){let e=new Map;return{emit(t,r){e.get(t)?.forEach(o=>o(r))},on(t,r){e.has(t)||e.set(t,new Set),e.get(t).add(r)},off(t,r){e.get(t)?.delete(r)}}}var S0=f(Z(),1),C0=Do.createContext(null),_0=Do.createContext(null),Xi=()=>Do.useContext(C0)?.id||null,po=e=>{let t=Do.useContext(_0);return e??t};var Zt=f(ve(),1);function R0(e,t){let r=null,o=null,n=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",u=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",l=i.width,c=i.height,m=i.x,d=i.y;return r==null&&t.x&&s&&(r=i.x-t.x),o==null&&t.y&&a&&(o=i.y-t.y),m-=r||0,d-=o||0,l=0,c=0,!n||u?(l=t.axis==="y"?i.width:0,c=t.axis==="x"?i.height:0,m=s&&t.x!=null?t.x:m,d=a&&t.y!=null?t.y:d):n&&!u&&(c=t.axis==="x"?i.height:c,l=t.axis==="y"?i.width:l),n=!0,{width:l,height:c,x:m,y:d,top:d,right:m+l,bottom:d+c,left:m}}}}function qf(e){return e!=null&&e.clientX!=null}function tl(e,t={}){let{enabled:r=!0,axis:o="both"}=t,n="rootStore"in e?e.rootStore:e,i=n.useState("open"),s=n.useState("floatingElement"),a=n.useState("domReferenceElement"),u=n.context.dataRef,l=Zt.useRef(!1),c=Zt.useRef(null),[m,d]=Zt.useState(),[h,g]=Zt.useState([]),b=Pe(_=>{n.set("positionReference",_)}),w=Pe((_,k,E)=>{l.current||u.current.openEvent&&!qf(u.current.openEvent)||n.set("positionReference",R0(E??a,{x:_,y:k,axis:o,dataRef:u,pointerType:m}))}),C=Pe(_=>{i?c.current||(w(_.clientX,_.clientY,_.currentTarget),g([])):w(_.clientX,_.clientY,_.currentTarget)}),x=Xr(m)?s:i;Zt.useEffect(()=>{if(!r){b(a);return}if(!x)return;function _(){c.current?.(),c.current=null}let k=it(s);function E(T){let O=Nt(T);Ge(s,O)?_():w(T.clientX,T.clientY)}return!u.current.openEvent||qf(u.current.openEvent)?c.current=ze(k,"mousemove",E):b(a),_},[x,r,s,u,a,n,w,b,h]),Zt.useEffect(()=>()=>{n.set("positionReference",null)},[n]),Zt.useEffect(()=>{r&&!s&&(l.current=!1)},[r,s]),Zt.useEffect(()=>{!r&&i&&(l.current=!0)},[r,i]);let v=Zt.useMemo(()=>{function _(k){d(k.pointerType)}return{onPointerDown:_,onPointerEnter:_,onMouseMove:C,onMouseEnter:C}},[C]);return Zt.useMemo(()=>r?{reference:v,trigger:v}:{},[r,v])}var or=f(ve(),1);function E0(){return!1}function T0(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function rl(e,t={}){let{enabled:r=!0,escapeKey:o=!0,outsidePress:n=!0,outsidePressEvent:i="sloppy",referencePress:s=E0,bubbles:a,externalTree:u}=t,l="rootStore"in e?e.rootStore:e,c=l.useState("open"),m=l.useState("floatingElement"),{dataRef:d}=l.context,h=po(u),g=Pe(typeof n=="function"?n:()=>!1),b=typeof n=="function"?g:n,w=b!==!1,C=Pe(()=>i),{escapeKey:x,outsidePress:v}=T0(a),_=or.useRef(!1),k=or.useRef(!1),E=or.useRef(!1),T=or.useRef(!1),O=or.useRef(""),I=or.useRef(null),J=xr(),D=xr(),S=Pe(()=>{D.clear(),d.current.insideReactTree=!1}),L=Pe(P=>{let W=d.current.floatingContext?.nodeId;return(h?Kr(h.nodesRef.current,W):[]).some(xe=>xe.context?.open&&!xe.context.dataRef.current[P])}),Y=Pe(P=>Ui(P,l.select("floatingElement"))||Ui(P,l.select("domReferenceElement"))),A=Pe(P=>{s()&&l.setOpen(!1,De(Oe.triggerPress,P.nativeEvent))}),N=Pe(P=>{if(!c||!r||!o||P.key!=="Escape"||T.current||!x&&L("__escapeKeyBubbles"))return;let W=Pf(P)?P.nativeEvent:P,ne=De(Oe.escapeKey,W);l.setOpen(!1,ne),ne.isCanceled||P.preventDefault(),!x&&!ne.isPropagationAllowed&&P.stopPropagation()}),q=Pe(()=>{d.current.insideReactTree=!0,D.start(0,S)}),U=Pe(P=>{if(!c||!r||P.button!==0)return;let W=Nt(P.nativeEvent);Ge(l.select("floatingElement"),W)&&(_.current||(_.current=!0,k.current=!1))}),R=Pe(P=>{!c||!r||(P.defaultPrevented||P.nativeEvent.defaultPrevented)&&_.current&&(k.current=!0)});or.useEffect(()=>{if(!c||!r)return S;d.current.__escapeKeyBubbles=x,d.current.__outsidePressBubbles=v;let P=new rr,W=new rr;function ne(){P.clear(),T.current=!0}function xe(){P.start(Zr.engine.webkit?5:0,()=>{T.current=!1})}function se(){E.current=!0,W.start(0,()=>{E.current=!1})}function be(){_.current=!1,k.current=!1}function ye(){let V=O.current,te=V==="pen"||!V?"mouse":V,Ne=C(),He=typeof Ne=="function"?Ne():Ne;return typeof He=="string"?He:He[te]}function $(V){let te=ye();return te==="intentional"&&V.type!=="click"||te==="sloppy"&&V.type==="click"}function _e(V){let te=d.current.floatingContext?.nodeId,Ne=h&&Kr(h.nodesRef.current,te).some(He=>Ui(V,He.context?.elements.floating));return Y(V)||Ne}function Fe(V){if($(V)){V.type!=="click"&&!Y(V)&&(W.clear(),E.current=!1),S();return}if(d.current.insideReactTree){S();return}let te=Nt(V),Ne=`[${cn("inert")}]`,He=Re(te)?te.getRootNode():null,ot=Array.from((an(He)?He:Rt(l.select("floatingElement"))).querySelectorAll(Ne)),Ze=l.context.triggerElements;if(te&&(Ze.hasElement(te)||Ze.hasMatchingElement(Ue=>Ge(Ue,te))))return;let Be=Re(te)?te:null;for(;Be&&!Ir(Be);){let Ue=Fr(Be);if(Ir(Ue)||!Re(Ue))break;Be=Ue}if(!(ot.length&&Re(te)&&!kf(te)&&!Ge(te,l.select("floatingElement"))&&ot.every(Ue=>!Ge(Be,Ue)))){if(_t(te)&&!("touches"in V)){let Ue=Ir(te),ct=Lt(te),Se=/auto|scroll/,Pr=Ue||Se.test(ct.overflowX),$t=Ue||Se.test(ct.overflowY),Ye=Pr&&te.clientWidth>0&&te.scrollWidth>te.clientWidth,Yr=$t&&te.clientHeight>0&&te.scrollHeight>te.clientHeight,St=ct.direction==="rtl",kt=Yr&&(St?V.offsetX<=te.offsetWidth-te.clientWidth:V.offsetX>te.clientWidth),vt=Ye&&V.offsetY>te.clientHeight;if(kt||vt)return}if(!_e(V)){if(ye()==="intentional"&&E.current){W.clear(),E.current=!1;return}typeof b=="function"&&!b(V)||L("__outsidePressBubbles")||(l.setOpen(!1,De(Oe.outsidePress,V)),S())}}}function xt(V){ye()!=="sloppy"||V.pointerType==="touch"||!l.select("open")||!r||Y(V)||Fe(V)}function Le(V){if(ye()!=="sloppy"||!l.select("open")||!r||Y(V))return;let te=V.touches[0];te&&(I.current={startTime:Date.now(),startX:te.clientX,startY:te.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},J.start(1e3,()=>{I.current&&(I.current.dismissOnTouchEnd=!1,I.current.dismissOnMouseDown=!1)}))}function X(V,te){let Ne=Nt(V);if(!Ne)return;let He=ze(Ne,V.type,()=>{te(V),He()})}function M(V){O.current="touch",X(V,Le)}function K(V){J.clear(),V.type==="pointerdown"&&(O.current=V.pointerType),!(V.type==="mousedown"&&I.current&&!I.current.dismissOnMouseDown)&&X(V,te=>{te.type==="pointerdown"?xt(te):Fe(te)})}function H(V){if(!_.current)return;let te=k.current;if(be(),ye()==="intentional"){if(V.type==="pointercancel"){te&&se();return}if(!_e(V)){if(te){se();return}typeof b=="function"&&!b(V)||(W.clear(),E.current=!0,S())}}}function Q(V){if(ye()!=="sloppy"||!I.current||Y(V))return;let te=V.touches[0];if(!te)return;let Ne=Math.abs(te.clientX-I.current.startX),He=Math.abs(te.clientY-I.current.startY),ot=Math.sqrt(Ne*Ne+He*He);ot>5&&(I.current.dismissOnTouchEnd=!0),ot>10&&(Fe(V),J.clear(),I.current=null)}function pe(V){X(V,Q)}function le(V){ye()!=="sloppy"||!I.current||Y(V)||(I.current.dismissOnTouchEnd&&Fe(V),J.clear(),I.current=null)}function fe(V){X(V,le)}let me=Rt(m),he=Sr(o&&Sr(ze(me,"keydown",N),ze(me,"compositionstart",ne),ze(me,"compositionend",xe)),w&&Sr(ze(me,"click",K,!0),ze(me,"pointerdown",K,!0),ze(me,"pointerup",H,!0),ze(me,"pointercancel",H,!0),ze(me,"mousedown",K,!0),ze(me,"mouseup",H,!0),ze(me,"touchstart",M,!0),ze(me,"touchmove",pe,!0),ze(me,"touchend",fe,!0)));return()=>{he(),P.clear(),W.clear(),be(),E.current=!1,S()}},[d,m,o,w,b,c,r,x,v,N,S,C,L,Y,h,l,J]);let B=or.useMemo(()=>({onKeyDown:N,onPointerDown:A,onClick:A}),[N,A]),re=or.useMemo(()=>({onKeyDown:N,onPointerDown:R,onMouseDown:R,onClickCapture:q,onMouseDownCapture(P){q(),U(P)},onPointerDownCapture(P){q(),U(P)},onMouseUpCapture:q,onTouchEndCapture:q,onTouchMoveCapture:q}),[N,q,U,R]);return or.useMemo(()=>r?{reference:B,floating:re,trigger:B}:{},[r,B,re])}var Pt=f(ve(),1);function Zf(e,t,r){let{reference:o,floating:n}=e,i=qt(t),s=ti(t),a=ei(s),u=Tt(t),l=i==="y",c=o.x+o.width/2-n.width/2,m=o.y+o.height/2-n.height/2,d=o[a]/2-n[a]/2,h;switch(u){case"top":h={x:c,y:o.y-n.height};break;case"bottom":h={x:c,y:o.y+o.height};break;case"right":h={x:o.x+o.width,y:m};break;case"left":h={x:o.x-n.width,y:m};break;default:h={x:o.x,y:o.y}}let g=_r(t);return g&&(h[s]+=d*(g==="end"?1:-1)*(r&&l?-1:1)),h}async function Xf(e,t){var r;t===void 0&&(t={});let{x:o,y:n,platform:i,rects:s,elements:a,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:m="floating",altBoundary:d=!1,padding:h=0}=Nr(t,e),g=Zi(h),w=a[d?m==="floating"?"reference":"floating":m],C=Vo(await i.getClippingRect({element:(r=await(i.isElement==null?void 0:i.isElement(w)))==null||r?w:w.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:l,rootBoundary:c,strategy:u})),x=m==="floating"?{x:o,y:n,width:s.floating.width,height:s.floating.height}:s.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),_=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},k=Vo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:x,offsetParent:v,strategy:u}):x);return{top:(C.top-k.top+g.top)/_.y,bottom:(k.bottom-C.bottom+g.bottom)/_.y,left:(C.left-k.left+g.left)/_.x,right:(k.right-C.right+g.right)/_.x}}var P0=50,Kf=async(e,t,r)=>{let{placement:o="bottom",strategy:n="absolute",middleware:i=[],platform:s}=r,a=s.detectOverflow?s:{...s,detectOverflow:Xf},u=await(s.isRTL==null?void 0:s.isRTL(t)),l=await s.getElementRects({reference:e,floating:t,strategy:n}),{x:c,y:m}=Zf(l,o,u),d=o,h=0,g={};for(let b=0;bY<=0)){var D,S;let Y=(((D=i.flip)==null?void 0:D.index)||0)+1,A=T[Y];if(A&&(!(m==="alignment"?x!==qt(A):!1)||J.every(U=>qt(U.placement)===x?U.overflows[0]>0:!0)))return{data:{index:Y,overflows:J},reset:{placement:A}};let N=(S=J.filter(q=>q.overflows[0]<=0).sort((q,U)=>q.overflows[1]-U.overflows[1])[0])==null?void 0:S.placement;if(!N)switch(h){case"bestFit":{var L;let q=(L=J.filter(U=>{if(E){let R=qt(U.placement);return R===x||R==="y"}return!0}).map(U=>[U.placement,U.overflows.filter(R=>R>0).reduce((R,B)=>R+B,0)]).sort((U,R)=>U[1]-R[1])[0])==null?void 0:L[0];q&&(N=q);break}case"initialPlacement":N=a;break}if(n!==N)return{reset:{placement:N}}}return{}}}};var Qf=new Set(["left","top"]);async function O0(e,t){let{placement:r,platform:o,elements:n}=e,i=await(o.isRTL==null?void 0:o.isRTL(n.floating)),s=Tt(r),a=_r(r),u=qt(r)==="y",l=Qf.has(s)?-1:1,c=i&&u?-1:1,m=Nr(t,e),{mainAxis:d,crossAxis:h,alignmentAxis:g}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return a&&typeof g=="number"&&(h=a==="end"?g*-1:g),u?{x:h*c,y:d*l}:{x:d*l,y:h*c}}var $f=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,o;let{x:n,y:i,placement:s,middlewareData:a}=t,u=await O0(t,e);return s===((r=a.offset)==null?void 0:r.placement)&&(o=a.arrow)!=null&&o.alignmentOffset?{}:{x:n+u.x,y:i+u.y,data:{...u,placement:s}}}}},ed=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:r,y:o,placement:n,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:u={fn:x=>{let{x:v,y:_}=x;return{x:v,y:_}}},...l}=Nr(e,t),c={x:r,y:o},m=await i.detectOverflow(t,l),d=qt(n),h=qi(d),g=c[h],b=c[d],w=(x,v)=>Yi(v+m[x==="y"?"top":"left"],v,v-m[x==="y"?"bottom":"right"]);s&&(g=w(h,g)),a&&(b=w(d,b));let C=u.fn({...t,[h]:g,[d]:b});return{...C,data:{x:C.x-r,y:C.y-o,enabled:{[h]:s,[d]:a}}}}}},td=function(e){return e===void 0&&(e={}),{options:e,fn(t){var r,o;let{x:n,y:i,placement:s,rects:a,middlewareData:u}=t,{offset:l=0,mainAxis:c=!0,crossAxis:m=!0}=Nr(e,t),d={x:n,y:i},h=qt(s),g=qi(h),b=d[g],w=d[h],C=Nr(l,t),x=typeof C=="number"?{mainAxis:C,crossAxis:0}:{mainAxis:(r=C.mainAxis)!=null?r:0,crossAxis:(o=C.crossAxis)!=null?o:0};if(c){let k=g==="y"?"height":"width",E=a.reference[g]-a.floating[k]+x.mainAxis,T=a.reference[g]+a.reference[k]-x.mainAxis;bT&&(b=T)}if(m){var v,_;let k=g==="y"?"width":"height",E=Qf.has(Tt(s)),T=a.reference[h]-a.floating[k]+(E&&((v=u.offset)==null?void 0:v[h])||0)+(E?0:x.crossAxis),O=a.reference[h]+a.reference[k]+(E?0:((_=u.offset)==null?void 0:_[h])||0)-(E?x.crossAxis:0);wO&&(w=O)}return{[g]:b,[h]:w}}}},rd=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:r,rects:o,platform:n,elements:i}=t,{apply:s=()=>{},...a}=Nr(e,t),u=await n.detectOverflow(t,a),l=Tt(r),c=_r(r),m=qt(r)==="y",{width:d,height:h}=o.floating,g,b;l==="top"||l==="bottom"?(g=l,b=c===(await(n.isRTL==null?void 0:n.isRTL(i.floating))?"start":"end")?"left":"right"):(b=l,g=c==="end"?"top":"bottom");let w=h-u.top-u.bottom,C=d-u.left-u.right,x=uo(h-u[g],w),v=uo(d-u[b],C),_=t.middlewareData.shift,k=!_,E=x,T=v;_!=null&&_.enabled.x&&(T=C),_!=null&&_.enabled.y&&(E=w),k&&!c&&(m?T=d-2*Cr(u.left,u.right):E=h-2*Cr(u.top,u.bottom)),await s({...t,availableWidth:T,availableHeight:E});let O=await n.getDimensions(i.floating);return d!==O.width||h!==O.height?{reset:{rects:!0}}:{}}}};function id(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=_t(e),i=n?e.offsetWidth:r,s=n?e.offsetHeight:o,a=fo(r)!==i||fo(o)!==s;return a&&(r=i,o=s),{width:r,height:o,$:a}}function nl(e){return Re(e)?e:e.contextElement}function un(e){let t=nl(e);if(!_t(t))return Lr(1);let r=t.getBoundingClientRect(),{width:o,height:n,$:i}=id(t),s=(i?fo(r.width):r.width)/o,a=(i?fo(r.height):r.height)/n;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var k0=Lr(0);function sd(e){let t=it(e);return!Bi()||!t.visualViewport?k0:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function F0(e,t,r){return t===void 0&&(t=!1),!!r&&t&&r===it(e)}function Bo(e,t,r,o){t===void 0&&(t=!1),r===void 0&&(r=!1);let n=e.getBoundingClientRect(),i=nl(e),s=Lr(1);t&&(o?Re(o)&&(s=un(o)):s=un(e));let a=F0(i,r,o)?sd(i):Lr(0),u=(n.left+a.x)/s.x,l=(n.top+a.y)/s.y,c=n.width/s.x,m=n.height/s.y;if(i&&o){let d=it(i),h=Re(o)?it(o):o,g=d,b=ji(g);for(;b&&h!==g;){let w=un(b),C=b.getBoundingClientRect(),x=Lt(b),v=C.left+(b.clientLeft+parseFloat(x.paddingLeft))*w.x,_=C.top+(b.clientTop+parseFloat(x.paddingTop))*w.y;u*=w.x,l*=w.y,c*=w.x,m*=w.y,u+=v,l+=_,g=it(b),b=ji(g)}}return Vo({width:c,height:m,x:u,y:l})}function Ki(e,t){let r=Kn(e).scrollLeft;return t?t.left+r:Bo(Ar(e)).left+r}function ad(e,t){let r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-Ki(e,r),n=r.top+t.scrollTop;return{x:o,y:n}}function A0(e){let{elements:t,rect:r,offsetParent:o,strategy:n}=e,i=n==="fixed",s=Ar(o),a=t?Xn(t.floating):!1;if(o===s||a&&i)return r;let u={scrollLeft:0,scrollTop:0},l=Lr(1),c=Lr(0),m=_t(o);if((m||!i)&&((Lo(o)!=="body"||Zn(s))&&(u=Kn(o)),m)){let h=Bo(o);l=un(o),c.x=h.x+o.clientLeft,c.y=h.y+o.clientTop}let d=s&&!m&&!i?ad(s,u):Lr(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-u.scrollLeft*l.x+c.x+d.x,y:r.y*l.y-u.scrollTop*l.y+c.y+d.y}}function I0(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function L0(e){let t=Kn(e),r=e.ownerDocument.body,o=Cr(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),n=Cr(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight),i=-t.scrollLeft+Ki(e),s=-t.scrollTop;return Lt(r).direction==="rtl"&&(i+=Cr(e.clientWidth,r.clientWidth)-o),{width:o,height:n,x:i,y:s}}var N0=25;function M0(e,t,r){r===void 0&&(r="viewport");let o=r==="layoutViewport",n=it(e),i=Ar(e),s=n.visualViewport,a=i.clientWidth,u=i.clientHeight,l=0,c=0;if(s){let d=!Bi()||t==="fixed";o?d||(l=-s.offsetLeft,c=-s.offsetTop):(a=s.width,u=s.height,d&&(l=s.offsetLeft,c=s.offsetTop))}if(Ki(i)<=0){let d=i.ownerDocument,h=d.body,g=getComputedStyle(h),b=d.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,w=Math.abs(i.clientWidth-h.clientWidth-b),C=getComputedStyle(i).scrollbarGutter==="stable both-edges"?w/2:w;C<=N0&&(a-=C)}return{width:a,height:u,x:l,y:c}}function V0(e,t){let r=Bo(e,!0,t==="fixed"),o=r.top+e.clientTop,n=r.left+e.clientLeft,i=un(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,u=n*i.x,l=o*i.y;return{width:s,height:a,x:u,y:l}}function od(e,t,r){let o;if(t==="viewport"||t==="layoutViewport")o=M0(e,r,t);else if(t==="document")o=L0(Ar(e));else if(Re(t))o=V0(t,r);else{let n=sd(e);o={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Vo(o)}function D0(e,t){let r=t.get(e);if(r)return r;let o=ao(e,[],!1).filter(a=>Re(a)&&Lo(a)!=="body"),n=null,i=Lt(e).position==="fixed",s=i?Fr(e):e;for(;Re(s)&&!Ir(s);){let a=Lt(s),u=Di(s),l=n?n.position:i?"fixed":"";!u&&(l==="fixed"||l==="absolute"&&a.position==="static")?o=o.filter(m=>m!==s):n=a,s=Fr(s)}return t.set(e,o),o}function B0(e){let{element:t,boundary:r,rootBoundary:o,strategy:n}=e,s=[...r==="clippingAncestors"?Xn(t)?[]:D0(t,this._c):[].concat(r),o],a=od(t,s[0],n),u=a.top,l=a.right,c=a.bottom,m=a.left;for(let d=1;d{a(!1,1e-7)},1e3)}T=!1}try{o=new IntersectionObserver(O,{...E,root:i.ownerDocument})}catch{o=new IntersectionObserver(O,E)}o.observe(e)}let u=it(e),l=()=>a(r);return u.addEventListener("resize",l),a(!0),()=>{u.removeEventListener("resize",l),s()}}function ri(e,t,r,o){o===void 0&&(o={});let{ancestorScroll:n=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:u=!1}=o,l=nl(e),c=n||i?[...l?ao(l):[],...t?ao(t):[]]:[];c.forEach(C=>{n&&C.addEventListener("scroll",r),i&&C.addEventListener("resize",r)});let m=l&&a?W0(l,r,i):null,d=-1,h=null;s&&(h=new ResizeObserver(C=>{let[x]=C;x&&x.target===l&&h&&t&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var v;(v=h)==null||v.observe(t)})),r()}),l&&!u&&h.observe(l),t&&h.observe(t));let g,b=u?Bo(e):null;u&&w();function w(){let C=Bo(e);b&&!cd(b,C)&&r(),b=C,g=requestAnimationFrame(w)}return r(),()=>{var C;c.forEach(x=>{n&&x.removeEventListener("scroll",r),i&&x.removeEventListener("resize",r)}),m?.(),(C=h)==null||C.disconnect(),h=null,u&&cancelAnimationFrame(g)}}var ud=$f;var fd=ed,dd=Jf,pd=rd;var md=td,Ji=(e,t,r)=>{let o=new Map,n=r??{},i={...il,...n.platform,_c:o};return Kf(e,t,{...n,platform:i})};var mt=f(ve(),1),gd=f(ve(),1),yd=f(lo(),1),Y0=typeof document<"u",q0=function(){},Qi=Y0?gd.useLayoutEffect:q0;function $i(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,o,n;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(o=r;o--!==0;)if(!$i(e[o],t[o]))return!1;return!0}if(n=Object.keys(e),r=n.length,r!==Object.keys(t).length)return!1;for(o=r;o--!==0;)if(!{}.hasOwnProperty.call(t,n[o]))return!1;for(o=r;o--!==0;){let i=n[o];if(!(i==="_owner"&&e.$$typeof)&&!$i(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function vd(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function hd(e,t){let r=vd(e);return Math.round(t*r)/r}function sl(e){let t=mt.useRef(e);return Qi(()=>{t.current=e}),t}function bd(e){e===void 0&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:o=[],platform:n,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:u,open:l}=e,[c,m]=mt.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[d,h]=mt.useState(o);$i(d,o)||h(o);let[g,b]=mt.useState(null),[w,C]=mt.useState(null),x=mt.useCallback(U=>{U!==E.current&&(E.current=U,b(U))},[]),v=mt.useCallback(U=>{U!==T.current&&(T.current=U,C(U))},[]),_=i||g,k=s||w,E=mt.useRef(null),T=mt.useRef(null),O=mt.useRef(c),I=u!=null,J=sl(u),D=sl(n),S=sl(l),L=mt.useCallback(()=>{if(!E.current||!T.current)return;let U={placement:t,strategy:r,middleware:d};D.current&&(U.platform=D.current),Ji(E.current,T.current,U).then(R=>{let B={...R,isPositioned:S.current!==!1};Y.current&&!$i(O.current,B)&&(O.current=B,yd.flushSync(()=>{m(B)}))})},[d,t,r,D,S]);Qi(()=>{l===!1&&O.current.isPositioned&&(O.current.isPositioned=!1,m(U=>({...U,isPositioned:!1})))},[l]);let Y=mt.useRef(!1);Qi(()=>(Y.current=!0,()=>{Y.current=!1}),[]),Qi(()=>{if(_&&(E.current=_),k&&(T.current=k),_&&k){if(J.current)return J.current(_,k,L);L()}},[_,k,L,J,I]);let A=mt.useMemo(()=>({reference:E,floating:T,setReference:x,setFloating:v}),[x,v]),N=mt.useMemo(()=>({reference:_,floating:k}),[_,k]),q=mt.useMemo(()=>{let U={position:r,left:0,top:0};if(!N.floating)return U;let R=hd(N.floating,c.x),B=hd(N.floating,c.y);return a?{...U,transform:"translate("+R+"px, "+B+"px)",...vd(N.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:R,top:B}},[r,a,N.floating,c.x,c.y]);return mt.useMemo(()=>({...c,update:L,refs:A,elements:N,floatingStyles:q}),[c,L,A,N,q])}var al=(e,t)=>{let r=ud(e);return{name:r.name,fn:r.fn,options:[e,t]}},ll=(e,t)=>{let r=fd(e);return{name:r.name,fn:r.fn,options:[e,t]}},cl=(e,t)=>({fn:md(e).fn,options:[e,t]}),ul=(e,t)=>{let r=dd(e);return{name:r.name,fn:r.fn,options:[e,t]}},fl=(e,t)=>{let r=pd(e);return{name:r.name,fn:r.fn,options:[e,t]}};var es=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,r,o=!0){this.fallbackStore=t,this.componentName=r,this.throwOnMissingTrigger=o}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let r=this.attachedStores.lastIndexOf(t);r!==-1&&this.attachedStores.splice(r,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(r=>{r()}))}openByTrigger(t){let r=this.attachedStore;if(r===null)return;let o;if(t){for(let n=this.attachedStores.length-1;n>=0&&!o;n-=1)o=this.attachedStores[n].context.triggerElements.getById(t);o??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!o&&this.throwOnMissingTrigger)throw new Error(lr(99,this.componentName,t,this.componentName));r.setOpen(!0,De(Oe.imperativeAction,void 0,o))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,De(Oe.imperativeAction))}};var zo=f(ve(),1),Nd=f(lo(),1);var Id=f(ve(),1);var Fd=f(ve(),1),gl=f(ts(),1),Ad=f(Ed(),1);var Td=f(ve(),1);var pl=[],ml;function Pd(){return ml}function Od(e){pl.push(e)}function hl(e){let t=(r,o)=>{let n=Ct(fw).current,i;try{ml=n;for(let s of pl)s.before(n);i=e(r,o);for(let s of pl)s.after(n);n.didInitialize=!0}finally{ml=void 0}return i};return t.displayName=e.displayName||e.name,t}function kd(e){return Td.forwardRef(hl(e))}function fw(){return{didInitialize:!1}}var dw=rn(19),pw=dw?hw:gw;function os(e,t,r,o,n){return pw(e,t,r,o,n)}function mw(e,t,r,o,n){let i=Fd.useCallback(()=>t(e.getSnapshot(),r,o,n),[e,t,r,o,n]);return(0,gl.useSyncExternalStore)(e.subscribe,i,i)}Od({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let r=0;r0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let r=new Set;for(let n of e.syncHooks)r.add(n.store);let o=[];for(let n of r)o.push(n.subscribe(t));return()=>{for(let n of o)n()}}),(0,gl.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function hw(e,t,r,o,n){let i=Pd();if(!i)return mw(e,t,r,o,n);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,r)||!Object.is(a.a2,o)||!Object.is(a.a3,n))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=r,a.a2=o,a.a3=n,a.value=t(e.getSnapshot(),r,o,n))):(a={store:e,selector:t,a1:r,a2:o,a3:n,value:t(e.getSnapshot(),r,o,n)},i.syncHooks.push(a)),a.value}function gw(e,t,r,o,n){return(0,Ad.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,r,o,n))}var ns=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let r=this.updateTick;for(let o of this.listeners){if(r!==this.updateTick)return;o(t)}}update(t){for(let r in t)if(!Object.is(this.state[r],t[r])){this.setState({...this.state,...t});return}}set(t,r){Object.is(this.state[t],r)||this.setState({...this.state,[t]:r})}notifyAll(){let t={...this.state};this.setState(t)}use(t,r,o,n){return os(this,t,r,o,n)}};var jo=f(ve(),1);var mo=class extends ns{constructor(t,r={},o){super(t),this.context=r,this.selectors=o}useSyncedValue(t,r){jo.useDebugValue(t);let o=this;we(()=>{o.state[t]!==r&&o.set(t,r)},[o,t,r])}useSyncedValueWithCleanup(t,r){let o=this;we(()=>(o.state[t]!==r&&o.set(t,r),()=>{o.set(t,void 0)}),[o,t,r])}useSyncedValues(t){let r=this,o=Object.values(t);we(()=>{r.update(t)},[r,...o])}useControlledProp(t,r){jo.useDebugValue(t);let o=this,n=r!==void 0;we(()=>{n&&!Object.is(o.state[t],r)&&o.setState({...o.state,[t]:r})},[o,t,r,n])}select(t,r,o,n){let i=this.selectors[t];return i(this.state,r,o,n)}useState(t,r,o,n){return jo.useDebugValue(t),os(this,this.selectors[t],r,o,n)}useContextCallback(t,r){jo.useDebugValue(t);let o=Pe(r??tr);this.context[t]=o}useStateSetter(t){let r=jo.useRef(void 0);return r.current===void 0&&(r.current=o=>{this.set(t,o)}),r.current}observe(t,r){let o;typeof t=="function"?o=t:o=this.selectors[t];let n=o(this.state);return r(n,n,this),this.subscribe(i=>{let s=o(i);if(!Object.is(n,s)){let a=n;n=s,r(s,a,this)}})}};var yw={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},ho=class extends mo{constructor(t){let{syncOnly:r,nested:o,onOpenChange:n,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:n,dataRef:{current:{}},events:Yf(),nested:o,triggerElements:i},yw),this.syncOnly=r}syncOpenEvent=(t,r)=>{(!t||!this.state.open||r!=null&&Of(r))&&(this.context.dataRef.current.openEvent=t?r:void 0)};dispatchOpenChange=(t,r)=>{this.syncOpenEvent(t,r.event);let o={open:t,reason:r.reason,nativeEvent:r.event,nested:this.context.nested,triggerElement:r.trigger};this.context.events.emit("openchange",o)};setOpen=(t,r)=>{if(this.syncOnly){this.context.onOpenChange?.(t,r);return}this.dispatchOpenChange(t,r),this.context.onOpenChange?.(t,r)}};function Ld(e){let{popupStore:t,treatPopupAsFloatingElement:r=!1,floatingRootContext:o,floatingId:n,nested:i,onOpenChange:s}=e,a=t.useState("open"),u=t.useState("activeTriggerElement"),l=t.useState(r?"popupElement":"positionerElement"),c=t.context.triggerElements,m=s,d=Id.useRef(null);o===void 0&&d.current===null&&(d.current=new ho({open:a,transitionStatus:void 0,referenceElement:u,floatingElement:l,triggerElements:c,onOpenChange:m,floatingId:n,syncOnly:!0,nested:i}));let h=o??d.current;return t.useSyncedValue("floatingId",n),we(()=>{let g={open:a,floatingId:n,referenceElement:u,floatingElement:l};Re(u)&&(g.domReferenceElement=u),h.state.positionReference===h.state.referenceElement&&(g.positionReference=u),h.update(g)},[a,n,u,l,h]),h.context.onOpenChange=m,h.context.nested=i,h}var Md={tabIndex:-1,[Xa]:""};function Vd(e,t=!1){let r=on(),o=Xi()!=null,n=Ct(()=>e(r,o)).current;return Ld({popupStore:n,treatPopupAsFloatingElement:t,floatingRootContext:n.state.floatingRootContext,floatingId:r,nested:o,onOpenChange:n.setOpen}),n}function Dd({handle:e,store:t}){return we(()=>e.attachStore(t),[e,t]),null}function vw(e,t){let r=zo.useRef(null),o=zo.useRef(null);return zo.useCallback(n=>{if(e===void 0)return;let i=!1;if(r.current!==null){let s=r.current,a=o.current,u=t.context.triggerElements.getById(s);a&&u===a&&(t.context.triggerElements.delete(s),i=!0),r.current=null,o.current=null}if(n!==null&&(r.current=e,o.current=n,t.context.triggerElements.add(e,n),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function bw(e,t,r,o=!1){t?e.preventUnmountingOnClose=!1:o&&(e.preventUnmountingOnClose=!0);let n=r?.id??null;(n||t)&&(e.activeTriggerId=n,e.activeTriggerElement=r??null)}function ww(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function Bd(e,t,r,o={}){let n=r.reason,i=n===Oe.triggerHover,s=t&&n===Oe.triggerFocus,a=!t&&(n===Oe.triggerPress||n===Oe.escapeKey),u=ww(r);if(e.context.onOpenChange?.(t,r),r.isCanceled)return;o.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,r);let l=()=>{let c={...o.extraState,open:t};s?c.instantType="focus":a?c.instantType="dismiss":i&&(c.instantType=void 0),bw(c,t,r.trigger,u()),e.update(c)};i?Nd.flushSync(l):l()}function jd(e,t,r,o){let n=r.useState("isMountedByTrigger",e),i=vw(e,r),s=Pe(u=>{let l=r.select("open"),c=r.select("activeTriggerId");if(c===e){r.update({activeTriggerElement:u,...l?o:null});return}c==null&&l&&r.update({activeTriggerId:e,activeTriggerElement:u,...o})}),a=zo.useCallback(u=>{i(u),u&&s(u)},[i,s]);return we(()=>{n&&r.update({activeTriggerElement:t.current,...o})},[n,r,t,...Object.values(o)]),{registerTrigger:a,isMountedByThisTrigger:n}}function zd(e,t={}){let{closeOnActiveTriggerUnmount:r=!1}=t,o=zo.useRef(null),n=e.useState("open"),i=e.useState("triggerCount"),s=e.useState("activeTriggerId"),a=e.useState("activeTriggerElement");we(()=>{if(!n){o.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let u=e.context.triggerElements.size,l={};e.state.triggerCount!==u&&(l.triggerCount=u);let c=e.select("activeTriggerId"),m=null;if(c){let d=e.context.triggerElements.getById(c);if(d)o.current=c,d!==e.state.activeTriggerElement&&(l.activeTriggerElement=d);else{for(let[h,g]of e.context.triggerElements.entries())if(g===e.state.activeTriggerElement){l.activeTriggerId=h,l.activeTriggerElement=g,o.current=h;break}l.activeTriggerId===void 0&&(o.current===c?m=c:o.current=null)}}else o.current=null;if(!m&&!c&&u===1){let d=e.context.triggerElements.entries().next();if(!d.done){let[h,g]=d.value;l.activeTriggerId=h,l.activeTriggerElement=g,o.current=h}}(l.triggerCount!==void 0||l.activeTriggerId!==void 0||l.activeTriggerElement!==void 0)&&e.update(l),m&&r&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===m&&!e.context.triggerElements.getById(m)){let d=De(Oe.none);e.setOpen(!1,d),d.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[n,e,i,s,a,r])}function Hd(e,t,r){let{mounted:o,setMounted:n,transitionStatus:i}=hf(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:o,transitionStatus:i,preventUnmountingOnClose:a});let u=Pe(()=>{n(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),r?.(),t.context.onOpenChangeComplete?.(!1)});return zi({enabled:o&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||u()}}),{forceUnmount:u,transitionStatus:i}}function Ud(e,t){e.useSyncedValues(t),we(()=>()=>{e.update({activeTriggerProps:nt,inactiveTriggerProps:nt,popupProps:nt})},[e])}var Ho=class{constructor(){this.idMap=new Map}add(t,r){this.idMap.set(t,r)}delete(t){this.idMap.delete(t)}hasElement(t){for(let r of this.idMap.values())if(r===t)return!0;return!1}hasMatchingElement(t){for(let r of this.idMap.values())if(t(r))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function Wd(){return new ho({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new Ho,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function Yd(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:Wd(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:nt,inactiveTriggerProps:nt,popupProps:nt}}function qd(e,t,r=!1){return new ho({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:r,onOpenChange:void 0})}var oi=e=>e.triggerIdProp??e.activeTriggerId,yl=e=>e.openProp??e.open,Gd=e=>(e.popupElement?.id??e.floatingId)||void 0;function Zd(e,t){return t!==void 0&&yl(e)&&oi(e)===t}function xw(e,t){return Zd(e,t)?!0:t!==void 0&&yl(e)&&oi(e)==null&&e.triggerCount===1}var Xd={open:yl,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:oi,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:Gd,isTriggerActive:(e,t)=>t!==void 0&&oi(e)===t,isOpenedByTrigger:(e,t)=>Zd(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&oi(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>xw(e,t)?Gd(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var vl=f(ve(),1),Kd=f(ts(),1);function Jd(e){let t=vl.useCallback(o=>e===void 0?tr:e.subscribeStore(o),[e]),r=vl.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,Kd.useSyncExternalStore)(t,r,()=>e?.serverStore)}function Qd(e){return Sw(e,e.rootContext)}function Sw(e,t){let{nodeId:r,externalTree:o}=e,n=t.useState("referenceElement"),i=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),u=t.useState("floatingId"),[l,c]=Pt.useState(null),[m,d]=Pt.useState(void 0),[h,g]=Pt.useState(void 0),b=Pt.useRef(null),w=po(o),C=Pt.useMemo(()=>({reference:n,floating:i,domReference:s}),[n,i,s]),x=bd({...e,elements:{...C,...l&&{reference:l}}}),v=Re(m)?m:null,_=h===void 0?t.state.floatingElement:h;t.useSyncedValue("referenceElement",m??null),t.useSyncedValue("domReferenceElement",m===void 0?s:v),t.useSyncedValue("floatingElement",_);let k=Pt.useCallback(D=>{let S=Re(D)?{getBoundingClientRect:()=>D.getBoundingClientRect(),getClientRects:()=>D.getClientRects(),contextElement:D}:D;c(S),x.refs.setReference(S)},[x.refs]),E=Pt.useCallback(D=>{(Re(D)||D===null)&&(b.current=D,d(D)),(Re(x.refs.reference.current)||x.refs.reference.current===null||D!==null&&!Re(D))&&x.refs.setReference(D)},[x.refs,d]),T=Pt.useCallback(D=>{g(D),x.refs.setFloating(D)},[x.refs]),O=Pt.useMemo(()=>({...x.refs,setReference:E,setFloating:T,setPositionReference:k,domReference:b}),[x.refs,E,T,k]),I=Pt.useMemo(()=>({...x.elements,domReference:s}),[x.elements,s]),J=Pt.useMemo(()=>({...x,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:u,refs:O,elements:I,nodeId:r,rootStore:t}),[x,O,I,r,t,a,u]);return we(()=>{s&&(b.current=s)},[s]),we(()=>{t.context.dataRef.current.floatingContext=J;let D=w?.nodesRef.current.find(S=>S.id===r);D&&(D.context=J)}),Pt.useMemo(()=>({...x,context:J,refs:O,elements:I,rootStore:t}),[x,O,I,J,t])}var Mr=f(ve(),1);var bl=Zr.os.mac&&Zr.engine.webkit;function wl(e,t={}){let{enabled:r=!0,delay:o}=t,n="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=n.context,a=Mr.useRef(!1),u=Mr.useRef(null),l=Mr.useRef(!0),c=xr();Mr.useEffect(()=>{let d=n.select("domReferenceElement");if(!r)return;let h=it(d);function g(){let C=n.select("domReferenceElement");!n.select("open")&&_t(C)&&C===Hi(Rt(C))&&(a.current=!0)}function b(){l.current=!0}function w(){l.current=!1}return Sr(ze(h,"blur",g),bl&&ze(h,"keydown",b,!0),bl&&ze(h,"pointerdown",w,!0))},[n,r]),Mr.useEffect(()=>{if(!r)return;function d(h){if(h.reason===Oe.triggerPress||h.reason===Oe.escapeKey){let g=n.select("domReferenceElement");Re(g)&&(u.current=g,a.current=!0)}}return i.on("openchange",d),()=>{i.off("openchange",d)}},[i,r,n]);let m=Mr.useMemo(()=>{function d(){a.current=!1,u.current=null}return{onMouseLeave(){d()},onFocus(h){let g=h.currentTarget;if(a.current){if(u.current===g)return;d()}let b=Nt(h.nativeEvent);if(Re(b)){if(bl&&!h.relatedTarget){if(!l.current&&!Ff(b))return}else if(!Af(b))return}let w=co(h.relatedTarget,n.context.triggerElements),{nativeEvent:C,currentTarget:x}=h,v=typeof o=="function"?o():o;if(n.select("open")&&w||v===0||v===void 0){n.setOpen(!0,De(Oe.triggerFocus,C,x));return}c.start(v,()=>{a.current||n.setOpen(!0,De(Oe.triggerFocus,C,x))})},onBlur(h){d();let g=h.relatedTarget,b=h.nativeEvent,w=Re(g)&&g.hasAttribute(cn("focus-guard"))&&g.getAttribute("data-type")==="outside";c.start(0,()=>{let C=n.select("domReferenceElement"),x=Hi(Rt(C));!g&&x===C||Ge(s.current.floatingContext?.refs.floating.current,x)||Ge(C,x)||w||co(g??x,n.context.triggerElements)||n.setOpen(!1,De(Oe.triggerFocus,b))})}}},[s,o,n,c]);return Mr.useMemo(()=>r?{reference:m,trigger:m}:{},[r,m])}var Sl=f(ve(),1);var xl=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new rr,this.restTimeout=new rr,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},is=new WeakMap;function dn(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&is.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),is.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ss(e,t){let{scopeElement:r,referenceElement:o,floatingElement:n}=t,i=is.get(r);i&&i!==e&&dn(i),dn(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=r,e.pointerEventsReferenceElement=o,e.pointerEventsFloatingElement=n,is.set(r,e),r.style.pointerEvents="none",o.style.pointerEvents="auto",n.style.pointerEvents="auto"}function pn(e){let t=e.context.dataRef.current,r=Ct(()=>t.hoverInteractionState??xl.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=r),nn(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function Cl(e,t={}){let{enabled:r=!0,closeDelay:o=0,nodeId:n}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),u=i.useState("domReferenceElement"),{dataRef:l}=i.context,c=po(),m=Xi(),d=pn(i),h=xr(),g=Pe(()=>Wi(l.current.openEvent?.type,d.interactedInside)),b=Pe(()=>If(l.current.openEvent?.type)),w=Pe(()=>{dn(d)});we(()=>{s||(d.pointerType=void 0,d.restTimeoutPending=!1,d.interactedInside=!1,w())},[s,d,w]),Sl.useEffect(()=>w,[w]),we(()=>{if(r&&s&&d.handleCloseOptions?.blockPointerEvents&&b()&&Re(u)&&a){let C=u,x=a,v=Rt(a),_=c?.nodesRef.current.find(O=>O.id===m)?.context?.elements.floating;_&&(_.style.pointerEvents="");let k=d.pointerEventsScopeElement!==x?d.pointerEventsScopeElement:null,E=_!==x?_:null,T=d.handleCloseOptions?.getScope?.()??k??E??C.closest("[data-rootownerid]")??v.body;return ss(d,{scopeElement:T,referenceElement:C,floatingElement:x}),()=>{w()}}},[r,s,u,a,d,b,c,m,w]),Sl.useEffect(()=>{if(!r)return;function C(){return!!(c&&m&&Kr(c.nodesRef.current,m).length>0)}function x(O){let I=cr(o,"close",d.pointerType),J=()=>{i.setOpen(!1,De(Oe.triggerHover,O)),c?.events.emit("floating.closed",O)};I?d.openChangeTimeout.start(I,J):(d.openChangeTimeout.clear(),J())}function v(O){let I=Nt(O);if(!Ja(I)){d.interactedInside=!1;return}d.interactedInside=I?.closest("[aria-haspopup]")!=null}function _(){d.openChangeTimeout.clear(),h.clear(),c?.events.off("floating.closed",E),w()}function k(O){if(C()&&c){c.events.on("floating.closed",E);return}if(co(O.relatedTarget,i.context.triggerElements))return;let I=l.current.floatingContext?.nodeId??n,J=O.relatedTarget;if(!(c&&I&&Re(J)&&Kr(c.nodesRef.current,I,!1).some(S=>Ge(S.context?.elements.floating,J)))){if(d.handler){d.handler(O);return}w(),b()&&!g()&&x(O)}}function E(O){!c||!m||C()||h.start(0,()=>{c.events.off("floating.closed",E),i.setOpen(!1,De(Oe.triggerHover,O)),c.events.emit("floating.closed",O)})}let T=a;return Sr(T&&ze(T,"mouseenter",_),T&&ze(T,"mouseleave",k),T&&ze(T,"pointerdown",v,!0),()=>{c?.events.off("floating.closed",E)})},[r,a,i,l,o,n,b,g,w,d,c,m,h])}var go=f(ve(),1),$d=f(lo(),1);var Cw={current:null};function _l(e,t={}){let{enabled:r=!0,delay:o=0,handleClose:n=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:u=Cw,externalTree:l,isActiveTrigger:c=!0,getHandleCloseContext:m,isClosing:d,shouldOpen:h,guardStaleOpen:g=!1}=t,b="rootStore"in e?e.rootStore:e,{dataRef:w,events:C}=b.context,x=po(l),v=pn(b),_=go.useRef(!1),k=Yt(n),E=Yt(o),T=Yt(s),O=Yt(r),I=Yt(h),J=Yt(d),D=Pe(()=>Wi(w.current.openEvent?.type,v.interactedInside)),S=Pe(()=>I.current?.()!==!1),L=Pe((N,q,U)=>{let R=b.context.triggerElements;if(R.hasElement(q))return!N||!Ge(N,q);if(!Re(U))return!1;let B=U;return R.hasMatchingElement(re=>Ge(re,B))&&(!N||!Ge(N,B))}),Y=Pe(()=>{if(!v.handler)return;Rt(b.select("domReferenceElement")).removeEventListener("mousemove",v.handler),v.handler=void 0}),A=Pe(()=>{dn(v)});return c&&(v.handleCloseOptions=k.current?.__options),go.useEffect(()=>Y,[Y]),go.useEffect(()=>{if(!r)return;function N(q){q.open?_.current=!1:(_.current=q.reason===Oe.triggerHover,Y(),v.openChangeTimeout.clear(),v.restTimeout.clear(),v.blockMouseMove=!0,v.restTimeoutPending=!1)}return C.on("openchange",N),()=>{C.off("openchange",N)}},[r,C,v,Y]),go.useEffect(()=>{if(!r)return;function N(P,W=!0){let ne=cr(E.current,"close",v.pointerType);ne?v.openChangeTimeout.start(ne,()=>{b.setOpen(!1,De(Oe.triggerHover,P)),x?.events.emit("floating.closed",P)}):W&&(v.openChangeTimeout.clear(),b.setOpen(!1,De(Oe.triggerHover,P)),x?.events.emit("floating.closed",P))}let q=u.current??(c?b.select("domReferenceElement"):null);if(!Re(q))return;function U(P){if(v.openChangeTimeout.clear(),v.blockMouseMove=!1,i&&!Xr(v.pointerType))return;let W=Qa(T.current),ne=cr(E.current,"open",v.pointerType),xe=Nt(P),se=P.currentTarget??null,be=b.select("domReferenceElement"),ye=se;if(Re(xe)&&!b.context.triggerElements.hasElement(xe)){for(let H of b.context.triggerElements.elements())if(Ge(H,xe)){ye=H;break}}Re(se)&&Re(be)&&!b.context.triggerElements.hasElement(se)&&Ge(se,be)&&(ye=be);let $=ye==null?!1:L(be,ye,xe),_e=b.select("open"),Fe=J.current?.()??b.select("transitionStatus")==="ending",xt=!_e&&Fe&&_.current,Le=!$&&Re(ye)&&Re(be)&&Ge(be,ye)&&xt,X=W>0&&!ne,M=$&&(_e||xt)||Le,K=!_e||$;if(M){S()&&b.setOpen(!0,De(Oe.triggerHover,P,ye));return}X||(ne?v.openChangeTimeout.start(ne,()=>{K&&S()&&b.setOpen(!0,De(Oe.triggerHover,P,ye))}):K&&S()&&b.setOpen(!0,De(Oe.triggerHover,P,ye)))}function R(P){if(D()){A();return}Y();let W=b.select("domReferenceElement"),ne=Rt(W);v.restTimeout.clear(),v.restTimeoutPending=!1;let xe=w.current.floatingContext??m?.();if(co(P.relatedTarget,b.context.triggerElements))return;if(k.current&&xe){b.select("open")||v.openChangeTimeout.clear();let be=u.current;v.handler=k.current({...xe,tree:x,x:P.clientX,y:P.clientY,onClose(){A(),Y(),O.current&&!D()&&be===b.select("domReferenceElement")&&N(P,!0)}}),ne.addEventListener("mousemove",v.handler),v.handler(P);return}(v.pointerType!=="touch"||!Ge(b.select("floatingElement"),P.relatedTarget))&&N(P)}function B(P){Ge(q,P.relatedTarget)||(v.openChangeTimeout.clear(),v.restTimeout.clear(),v.restTimeoutPending=!1)}let re=g?ze(q,"mouseout",B):void 0;return a?Sr(ze(q,"mousemove",U,{once:!0}),ze(q,"mouseenter",U),ze(q,"mouseleave",R),re):Sr(ze(q,"mouseenter",U),ze(q,"mouseleave",R),re)},[Y,A,w,E,b,r,k,v,c,L,D,i,a,T,u,x,O,m,J,S,g]),go.useMemo(()=>{if(!r)return;function N(q){v.pointerType=q.pointerType}return{onPointerDown:N,onPointerEnter:N,onMouseMove(q){let{nativeEvent:U}=q,R=q.currentTarget,B=b.select("domReferenceElement"),re=b.select("open"),P=L(B,R,q.target);if(i&&!Xr(v.pointerType))return;if(re&&P&&v.handleCloseOptions?.blockPointerEvents){let xe=b.select("floatingElement");if(xe){let se=v.handleCloseOptions?.getScope?.()??R.ownerDocument.body;ss(v,{scopeElement:se,referenceElement:R,floatingElement:xe})}}let W=Qa(T.current);if(re&&!P||W===0||!P&&v.restTimeoutPending&&q.movementX**2+q.movementY**2<2)return;v.restTimeout.clear();function ne(){if(v.restTimeoutPending=!1,D())return;let xe=b.select("open");!v.blockMouseMove&&(!xe||P)&&S()&&b.setOpen(!0,De(Oe.triggerHover,U,R))}v.pointerType==="touch"?$d.flushSync(()=>{ne()}):P&&re?ne():(v.restTimeoutPending=!0,v.restTimeout.start(W,ne))}}},[r,v,D,L,i,b,T,S])}var ep=.1,_w=ep*ep,Xe=.5;function as(e,t,r,o,n,i){return o>=t!=i>=t&&e<=(n-r)*(t-o)/(i-o)+r}function ls(e,t,r,o,n,i,s,a,u,l){let c=!1;return as(e,t,r,o,n,i)&&(c=!c),as(e,t,n,i,s,a)&&(c=!c),as(e,t,s,a,u,l)&&(c=!c),as(e,t,u,l,r,o)&&(c=!c),c}function Rw(e,t,r){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height}function cs(e,t,r,o,n,i){let s=Math.min(r,n),a=Math.max(r,n),u=Math.min(o,i),l=Math.max(o,i);return e>=s&&e<=a&&t>=u&&t<=l}function Rl(e={}){let{blockPointerEvents:t=!1}=e,r=new rr,o=({x:n,y:i,placement:s,elements:a,onClose:u,nodeId:l,tree:c})=>{let m=s?.split("-")[0],d=!1,h=null,g=null,b=typeof performance<"u"?performance.now():0;function w(x,v){let _=performance.now(),k=_-b;if(h===null||g===null||k===0)return h=x,g=v,b=_,!1;let E=x-h,T=v-g,O=E*E+T*T,I=k*k*_w;return h=x,g=v,b=_,O0)}function L(){S()||C()}if(S())return;let Y=_.getBoundingClientRect(),A=k.getBoundingClientRect(),N=n>A.right-A.width/2,q=i>A.bottom-A.height/2,U=A.width>Y.width,R=A.height>Y.height,B=(U?Y:A).left,re=(U?Y:A).right,P=(R?Y:A).top,W=(R?Y:A).bottom;if(m==="top"&&i>=Y.bottom-1||m==="bottom"&&i<=Y.top+1||m==="left"&&n>=Y.right-1||m==="right"&&n<=Y.left+1){L();return}let ne=!1;switch(m){case"top":ne=cs(E,T,B,Y.top+1,re,A.bottom-1);break;case"bottom":ne=cs(E,T,B,A.top+1,re,Y.bottom-1);break;case"left":ne=cs(E,T,A.right-1,W,Y.left+1,P);break;case"right":ne=cs(E,T,Y.right-1,W,A.left+1,P);break;default:}if(ne)return;if(d&&!Rw(E,T,Y)){L();return}if(!I&&w(E,T)){L();return}let xe=!1;switch(m){case"top":{let se=U?Xe/2:Xe*4,be=U||N?n+se:n-se,ye=U?n-se:N?n+se:n-se,$=i+Xe+1,_e=N||U?A.bottom-Xe:A.top,Fe=N?U?A.bottom-Xe:A.top:A.bottom-Xe;xe=ls(E,T,be,$,ye,$,A.left,_e,A.right,Fe);break}case"bottom":{let se=U?Xe/2:Xe*4,be=U||N?n+se:n-se,ye=U?n-se:N?n+se:n-se,$=i-Xe,_e=N||U?A.top+Xe:A.bottom,Fe=N?U?A.top+Xe:A.bottom:A.top+Xe;xe=ls(E,T,be,$,ye,$,A.left,_e,A.right,Fe);break}case"left":{let se=R?Xe/2:Xe*4,be=R||q?i+se:i-se,ye=R?i-se:q?i+se:i-se,$=n+Xe+1,_e=q||R?A.right-Xe:A.left,Fe=q?R?A.right-Xe:A.left:A.right-Xe;xe=ls(E,T,_e,A.top,Fe,A.bottom,$,be,$,ye);break}case"right":{let se=R?Xe/2:Xe*4,be=R||q?i+se:i-se,ye=R?i-se:q?i+se:i-se,$=n-Xe,_e=q||R?A.left+Xe:A.right,Fe=q?R?A.left+Xe:A.right:A.left+Xe;xe=ls(E,T,$,be,$,ye,_e,A.top,Fe,A.bottom);break}default:}xe?d||r.start(40,L):L()}};return o.__options={...e,blockPointerEvents:t},o}var us=class extends mo{setState(t){}update(t){}set(t,r){}notifyAll(){}};var zk=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=ja.startingStyle]="startingStyle",e[e.endingStyle=ja.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({});var Ew={"data-popup-open":""};var Tw={"data-open":""},Pw={"data-closed":""},Ow={"data-anchor-hidden":""},tp={open(e){return e?Ew:null}};var ni={open(e){return e?Tw:Pw},anchorHidden(e){return e?Ow:null}},rp={...ni,...gf};function op(e){return rn(19)?e:e?"true":void 0}var fs=f(ve(),1),El=fs.createContext(void 0);function mn(){return fs.useContext(El)?.direction??"ltr"}var nr=f(ve(),1);var kw=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:o,placement:n,rects:i,platform:s,elements:a,middlewareData:u}=t,{element:l,padding:c=0,offsetParent:m="real"}=Nr(e,t)||{};if(l==null)return{};let d=Zi(c),h={x:r,y:o},g=ti(n),b=ei(g),w=await s.getDimensions(l),C=g==="y",x=C?"top":"left",v=C?"bottom":"right",_=C?"clientHeight":"clientWidth",k=i.reference[b]+i.reference[g]-h[g]-i.floating[b],E=h[g]-i.reference[g],T=m==="real"?await s.getOffsetParent?.(l):a.floating,O=a.floating[_]||i.floating[b];(!O||!await s.isElement?.(T))&&(O=a.floating[_]||i.floating[b]);let I=k/2-E/2,J=O/2-w[b]/2-1,D=Math.min(d[x],J),S=Math.min(d[v],J),L=D,Y=O-w[b]-S,A=O/2-w[b]/2+I,N=Yi(L,A,Y),q=!u.arrow&&_r(n)!=null&&A!==N&&i.reference[b]/2-(A({...kw(e),options:[e,t]});var ip={name:"hide",async fn(e){let{width:t,height:r,x:o,y:n}=e.rects.reference,i=t===0&&r===0&&o===0&&n===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-r>=0||s.right-t>=0||s.bottom-r>=0||s.left-t>=0||i}}}};var hn={sideX:"left",sideY:"top"};var sp="--available-width",ap="--available-height";function up(e,t,r){let o=e==="inline-start"||e==="inline-end";return{top:"top",right:o?r?"inline-start":"inline-end":"right",bottom:"bottom",left:o?r?"inline-end":"inline-start":"left"}[t]}function lp(e,t,r){let{rects:o,placement:n}=e;return{side:up(t,Tt(n),r),align:_r(n)||"center",anchor:{width:o.reference.width,height:o.reference.height},positioner:{width:o.floating.width,height:o.floating.height}}}function fp(e){return Fw(e,Qd)}function Fw(e,t){let{anchor:r,positionMethod:o="absolute",side:n="bottom",sideOffset:i=0,align:s="center",alignOffset:a=0,collisionBoundary:u,collisionPadding:l=5,sticky:c=!1,arrowPadding:m=5,disableAnchorTracking:d=!1,inline:h,keepMounted:g=!1,floatingRootContext:b,mounted:w,collisionAvoidance:C,shift:x,nodeId:v,adaptiveOrigin:_,lazyFlip:k=!1,externalTree:E}=e,[T,O]=nr.useState(null);!w&&T!==null&&O(null);let I=C.side||"flip",J=C.align||"flip",D=C.fallbackAxisSide||"end",S=x?.crossAxis??!1,L=x?.rootBoundary,Y=typeof r=="function"?r:void 0,A=Pe(Y),N=Y?A:r,q=Yt(r),U=Yt(w),B=mn()==="rtl",re=T||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":B?"left":"right","inline-start":B?"right":"left"}[n],P=s==="center"?re:`${re}-${s}`,W=l;typeof W=="number"?W={top:W,right:W,bottom:W,left:W}:W&&(W={top:W.top||0,right:W.right||0,bottom:W.bottom||0,left:W.left||0});let ne=1,xe=n==="bottom"?ne:0,se=n==="top"?ne:0,be=n==="right"?ne:0,ye=n==="left"?ne:0,$={boundary:u==="clipping-ancestors"?"clippingAncestors":u,padding:W},_e=nr.useRef(null),Fe=Yt(i),xt=Yt(a),Le=typeof i!="function"?i:0,X=typeof a!="function"?a:0,M=[];h&&M.push(h),M.push(al(G=>{let y=lp(G,n,B),oe=typeof Fe.current=="function"?Fe.current(y):Fe.current,Ae=typeof xt.current=="function"?xt.current(y):xt.current;return{mainAxis:oe,crossAxis:Ae,alignmentAxis:Ae}},[Le,X,B,n]));let K=J==="none"&&I!=="shift",H=!K&&(c||S||I==="shift"),Q=I==="none"?null:ul({...$,padding:{top:W.top+ne+xe,right:W.right+ne+ye,bottom:W.bottom+ne+se,left:W.left+ne+be},mainAxis:!S&&I==="flip",crossAxis:J==="flip"?"alignment":!1,fallbackAxisSideDirection:D}),pe=K?null:ll({...$,rootBoundary:L,mainAxis:J!=="none",crossAxis:H,limiter:c||S?void 0:cl(G=>{if(!_e.current)return{};let{width:y,height:oe}=_e.current.getBoundingClientRect(),Ae=qt(Tt(G.placement)),ee=Ae==="y"?y:oe,Qe=Ae==="y"?W.left+W.right:W.top+W.bottom;return{offset:ee/2+Qe/2}})},[$,c,S,L,W,J]);I==="shift"||J==="shift"||s==="center"?M.push(pe,Q):M.push(Q,pe),M.push(fl({...$,apply({elements:{floating:G},availableWidth:y,availableHeight:oe,rects:Ae}){if(!U.current)return;let ee=G.style;ee.setProperty(sp,`${y}px`),ee.setProperty(ap,`${oe}px`);let Qe=it(G).devicePixelRatio||1,{x:ie,y:Je,width:j,height:z}=Ae.reference,vr=(Math.round((ie+j)*Qe)-Math.round(ie*Qe))/Qe,je=(Math.round((Je+z)*Qe)-Math.round(Je*Qe))/Qe;ee.setProperty("--anchor-width",`${vr}px`),ee.setProperty("--anchor-height",`${je}px`)}}),np(G=>({element:_e.current||Rt(G.elements.floating).createElement("div"),padding:m,offsetParent:"floating"}),[m]),{name:"transformOrigin",fn(G){let{elements:y,middlewareData:oe,placement:Ae,rects:ee,y:Qe}=G,ie=Tt(Ae),Je=qt(ie),j=_e.current,z=oe.arrow?.x||0,vr=oe.arrow?.y||0,je=j?.clientWidth||0,ce=j?.clientHeight||0,br=z+je/2,Or=vr+ce/2,et=Math.abs(oe.shift?.y||0),Me=ee.reference.height/2,$e=typeof i=="function"?i(lp(G,n,B)):i,ut=et>$e,pt={top:`${br}px calc(100% + ${$e}px)`,bottom:`${br}px ${-$e}px`,left:`calc(100% + ${$e}px) ${Or}px`,right:`${-$e}px ${Or}px`}[ie],wr=`${br}px ${ee.reference.y+Me-Qe}px`;return y.floating.style.setProperty("--transform-origin",H&&Je==="y"&&ut?wr:pt),{}}},ip,_),we(()=>{!w&&b&&b.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[w,b]);let le=nr.useMemo(()=>({elementResize:!d&&typeof ResizeObserver<"u",layoutShift:!d&&typeof IntersectionObserver<"u"}),[d]),{refs:fe,elements:me,x:he,y:V,middlewareData:te,update:Ne,placement:He,context:ot,isPositioned:Ze,floatingStyles:Be}=t({rootContext:b,open:g?w:void 0,placement:P,middleware:M,strategy:o,whileElementsMounted:g?void 0:(...G)=>ri(...G,le),nodeId:v,externalTree:E}),{sideX:Ue,sideY:ct}=te.adaptiveOrigin||hn,Se=Ze?o:"fixed",Pr=nr.useMemo(()=>{let G;return Ze?_?G={position:Se,[Ue]:he,[ct]:V}:G={...Be,position:Se}:G={position:Se,top:0,left:0},G[sp]="100vw",G[ap]="100vh",Ze||(G.opacity=0),G},[_,Se,Ue,he,ct,V,Be,Ze]),$t=nr.useRef(null);we(()=>{if(!w)return;let G=q.current,y=typeof G=="function"?G():G,Ae=(cp(y)?y.current:y)||null||null;Ae!==$t.current&&(fe.setPositionReference(Ae),$t.current=Ae)},[w,fe,N,q]),nr.useEffect(()=>{if(!w)return;let G=q.current;typeof G!="function"&&cp(G)&&G.current!==$t.current&&(fe.setPositionReference(G.current),$t.current=G.current)},[w,fe,N,q]),nr.useEffect(()=>{if(g&&w&&me.reference&&me.floating)return ri(me.reference,me.floating,Ne,le)},[g,w,me,Ne,le]);let Ye=Tt(He),Yr=up(n,Ye,B),St=_r(He)||"center",kt=!!te.hide?.referenceHidden;we(()=>{k&&w&&Ze&&Ye!==re&&O(Ye)},[k,w,Ze,Ye,re]);let vt=nr.useMemo(()=>({position:"absolute",top:te.arrow?.y,left:te.arrow?.x}),[te.arrow]),F=te.arrow?.centerOffset!==0;return nr.useMemo(()=>({positionerStyles:Pr,arrowStyles:vt,arrowRef:_e,arrowUncentered:F,side:Yr,align:St,physicalSide:Ye,anchorHidden:kt,refs:fe,context:ot,isPositioned:Ze,update:Ne}),[Pr,vt,_e,F,Yr,St,Ye,kt,fe,ot,Ze,Ne])}function cp(e){return e!=null&&"current"in e}function ds(e){return e==="starting"?zf:nt}function dp(e,t,{styles:r,transitionStatus:o,props:n,refs:i,hidden:s,inert:a=!1}){let u={...r};return a&&(u.pointerEvents="none"),Gt("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:u},ds(o),n],stateAttributesMapping:ni})}var Et=f(ve(),1),xp=f(lo(),1);var pp=f(ve(),1);function mp(e){let[t,r]=pp.useState({current:e,previous:null});return Object.is(e,t.current)||r({current:e,previous:t.current}),t.previous}var gn=f(ve(),1);function Tl(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=_t(e),i=n?e.offsetWidth:r,s=n?e.offsetHeight:o;return(fo(r)!==i||fo(o)!==s)&&(r=i,o=s),{width:r,height:o}}function gp(e){let{popupElement:t,positionerElement:r,content:o,mounted:n,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:u}=e,l=ln(t,!0),c=sn(),m=gn.useRef(null),d=gn.useRef(!0),h=gn.useRef(tr),g=Pe(i),b=Pe(s),w=gn.useMemo(()=>Aw(a,u),[a,u]);we(()=>{if(!n){h.current=tr,d.current=!0,m.current=null;return}if(!t||!r)return;h.current=hp(t,w),Pl(t,"auto");let C=ms(t,"position","static"),x=ms(t,"transform","none"),v=ms(t,"scale","1"),_=hp(r,{"--available-width":"max-content","--available-height":"max-content"});function k(){C(),x(),_()}function E(){k(),v()}if(g?.(),d.current||m.current===null){ps(r,"max-content");let J=Tl(t);return m.current=J,ps(r,J),E(),b?.(null,J),d.current=!1,()=>{h.current(),h.current=tr}}ps(r,"max-content");let T=m.current,O=Tl(t);m.current=O,Pl(t,T),E(),b?.(T,O),ps(r,O);let I=new AbortController;return c.request(()=>{Pl(t,O),l(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},I.signal)}),()=>{I.abort(),c.cancel(),h.current(),h.current=tr}},[o,t,r,l,c,n,g,b,w])}function Aw(e,t){let r=e==="top",o=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!r&&!o?nt:{position:"absolute",[r?"bottom":"top"]:"0",[o?"right":"left"]:"0"}}function ms(e,t,r){let o=e.style.getPropertyValue(t);return e.style.setProperty(t,r),()=>{e.style.setProperty(t,o)}}function hp(e,t){let r=[];for(let[o,n]of Object.entries(t))r.push(ms(e,o,n));return r.length?()=>{r.forEach(o=>o())}:tr}function Pl(e,t){let r=t==="auto"?"auto":`${t.width}px`,o=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",r),e.style.setProperty("--popup-height",o)}function ps(e,t){let r=t==="max-content"?"max-content":`${t.width}px`,o=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",r),e.style.setProperty("--positioner-height",o)}var yp=f(ve(),1);var vp=f(Z(),1),hs=function(t){let{direction:r="ltr"}=t,o=yp.useMemo(()=>({direction:r}),[r]);return(0,vp.jsx)(El.Provider,{value:o,children:t.children})};var bp={name:"adaptiveOrigin",async fn(e){let{x:t,y:r,rects:{floating:o},elements:{floating:n},platform:i,strategy:s,placement:a}=e,u=it(n),l=u.getComputedStyle(n);if(!(l.transitionDuration!=="0s"&&l.transitionDuration!==""))return{x:t,y:r,data:hn};let m=await i.getOffsetParent?.(n),d={width:0,height:0};if(s==="fixed"&&u?.visualViewport)d={width:u.visualViewport.width,height:u.visualViewport.height};else if(m===u){let x=Rt(n);d={width:x.documentElement.clientWidth,height:x.documentElement.clientHeight}}else await i.isElement?.(m)&&(d=await i.getDimensions(m));let h=Tt(a),g=t,b=r;h==="left"&&(g=d.width-(t+o.width)),h==="top"&&(b=d.height-(r+o.height));let w=h==="left"?"right":hn.sideX,C=h==="top"?"bottom":hn.sideY;return{x:g,y:b,data:{sideX:w,sideY:C}}}};var yn=f(Z(),1),Sp={activationDirection:e=>e?{"data-activation-direction":e}:null};function Cp(e){let{store:t,side:r,children:o}=e,n=mn(),i=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),a=t.useState("open"),u=t.useState("payload"),l=t.useState("mounted"),c=t.useState("popupElement"),m=t.useState("positionerElement"),d=mp(a?i:null),h=Nw(s,u),g=Et.useRef(null),[b,w]=Et.useState(null),[C,x]=Et.useState(null),v=Et.useRef(null),_=Et.useRef(null),k=ln(v,!0),E=sn(),T=Et.useRef(null),[O,I]=Et.useState(null),[J,D]=Et.useState(!1);we(()=>(t.set("adaptiveOrigin",bp),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let S=Pe(()=>{v.current?.style.setProperty("animation","none"),v.current?.style.setProperty("transition","none"),_.current?.style.setProperty("display","none")}),L=Pe(R=>{v.current?.style.removeProperty("animation"),v.current?.style.removeProperty("transition"),_.current?.style.removeProperty("display"),R&&I(R)}),Y=Pe(()=>{T.current?.abort();let R=new AbortController;T.current=R,k(()=>{w(null),I(null),g.current=null},R.signal)}),A=Et.useRef(null);we(()=>{(!a||!l)&&(A.current=null)},[a,l]),we(()=>{if(i&&d&&i!==d&&A.current!==i&&g.current){w(g.current),D(!0);let R=Lw(d,i);x(R),A.current=i}},[i,d]),we(()=>{b!=null&&(T.current?.abort(),D(!0),E.request(()=>{xp.flushSync(()=>{D(!1)}),Y()}))},[h,b,Y,E]),we(()=>{let R=v.current;if(!R)return;let B=Rt(R).createElement("div");for(let re of Array.from(R.childNodes))B.appendChild(re.cloneNode(!0));g.current=B});let N=b!=null,q;N?q=(0,yn.jsxs)(Et.Fragment,{children:[(0,yn.jsx)("div",{"data-previous":!0,inert:op(!0),ref:_,style:{...O?{"--popup-width":`${O.width}px`,"--popup-height":`${O.height}px`}:null,position:"absolute"},"data-ending-style":J?void 0:""},"previous"),(0,yn.jsx)("div",{"data-current":!0,ref:v,"data-starting-style":J?"":void 0,children:o},h)]}):q=(0,yn.jsx)("div",{"data-current":!0,ref:v,children:o},h),we(()=>{let R=_.current;!R||!b||R.replaceChildren(...Array.from(b.childNodes))},[b]),gp({popupElement:c,positionerElement:m,mounted:l,content:u,onMeasureLayout:S,onMeasureLayoutComplete:L,side:r,direction:n});let U={activationDirection:Iw(C),transitioning:N};return{children:q,state:U}}function Iw(e){if(e)return`${wp(e.horizontal,5,"right","left")} ${wp(e.vertical,5,"down","up")}`}function wp(e,t,r,o){return e>t?r:e<-t?o:""}function Lw(e,t){let r=e.getBoundingClientRect(),o=t.getBoundingClientRect(),n={x:r.left+r.width/2,y:r.top+r.height/2},i={x:o.left+o.width/2,y:o.top+o.height/2};return{horizontal:i.x-n.x,vertical:i.y-n.y}}function Nw(e,t){let[r,o]=Et.useState(0),n=Et.useRef(e),i=Et.useRef(t),s=Et.useRef(!1);return we(()=>{let a=n.current,u=i.current,l=e!==a,c=t!==u;l?(o(m=>m+1),s.current=!c):s.current&&c&&(o(m=>m+1),s.current=!1),n.current=e,i.current=t},[e,t]),`${e??"current"}-${r}`}var gs=f(ve(),1),_p=f(lo(),1);var Rp=f(Z(),1),Ep=gs.forwardRef(function(t,r){let{children:o,container:n,className:i,render:s,style:a,...u}=t,{node:l,subtree:c}=Gf({container:n,ref:r,componentProps:t,elementProps:u});return!c&&!l?null:(0,Rp.jsxs)(gs.Fragment,{children:[c,l&&_p.createPortal(o,l)]})});var Xt={};so(Xt,{Arrow:()=>Gp,Handle:()=>si,Popup:()=>Up,Portal:()=>Bp,Positioner:()=>zp,Provider:()=>qp,Root:()=>Ap,Trigger:()=>Mp,Viewport:()=>Xp,createHandle:()=>Kp});var vn=f(ve(),1);var ys=f(ve(),1),Ol=ys.createContext(void 0);function ur(e){let t=ys.useContext(Ol);if(t===void 0&&!e)throw new Error(lr(72));return t}var Tp=f(ve(),1);var Pp={...Xd,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},vs=class extends mo{constructor(t,r,o){let n=new Ho;super(kp(t,n,r,o),Fp(n),Pp)}setOpen=(t,r)=>{Bd(this,t,r,{extraState:{openChangeReason:r.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,De(Oe.triggerPress,t))}};function Op(){let e=new Ho,t=new us(Object.freeze(kp(void 0,e)),Object.freeze(Fp(e)),Pp);return Object.assign(t,{setOpen:tr,cancelPendingOpen:tr})}function kp(e,t,r,o=!1){let n={...Yd(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e};return n.floatingRootContext=qd(t,r,o),n}function Fp(e){return{popupRef:Tp.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var ii=f(Z(),1),Ap=hl(function(t){let{disabled:r=!1,defaultOpen:o=!1,open:n,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:u,onOpenChangeComplete:l,handle:c,triggerId:m,defaultTriggerId:d=null,children:h}=t,g=Vd((D,S)=>new vs({open:o,openProp:n,activeTriggerId:d,triggerIdProp:m},D,S));g.useControlledProp("openProp",n),g.useControlledProp("triggerIdProp",m),g.useContextCallback("onOpenChange",u),g.useContextCallback("onOpenChangeComplete",l);let b=g.useState("open"),w=!r&&b,C=g.useState("activeTriggerId"),x=g.useState("mounted"),v=g.useState("payload");g.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i,disabled:r}),zd(g,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:_,transitionStatus:k}=Hd(w,g),E=g.useState("isInstantPhase"),T=g.useState("instantType"),O=g.useState("lastOpenChangeReason"),I=vn.useRef(null);we(()=>{b&&r&&g.setOpen(!1,De(Oe.disabled))},[b,r,g]),we(()=>{k==="ending"&&O===Oe.none||k!=="ending"&&E?(T!=="delay"&&(I.current=T),g.set("instantType","delay")):I.current!==null&&(g.set("instantType",I.current),I.current=null)},[k,E,O,T,g]),we(()=>{w&&C==null&&g.set("payload",void 0)},[g,C,w]),vn.useImperativeHandle(a,()=>({unmount:_,close:()=>g.setOpen(!1,De(Oe.imperativeAction))}),[_,g]);let J=w||x||!r&&s!=="none";return(0,ii.jsxs)(Ol.Provider,{value:g,children:[c&&(0,ii.jsx)(Dd,{handle:c,store:g}),J&&(0,ii.jsx)(Mw,{store:g,disabled:r,trackCursorAxis:s}),typeof h=="function"?h({payload:v}):h]})});function Mw({store:e,disabled:t,trackCursorAxis:r}){let o=e.useState("floatingRootContext"),n=rl(o,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=tl(o,{enabled:!t&&r!=="none",axis:r==="none"?void 0:r}),s=vn.useMemo(()=>It(i.reference,n.reference),[i.reference,n.reference]);return Ud(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:n.floating??nt}),null}var ws=f(ve(),1);var bs=f(ve(),1),kl=bs.createContext(void 0);function Ip(){return bs.useContext(kl)}var Np="data-base-ui-tooltip-trigger";function Lp(e){if("composedPath"in e){let r=e.composedPath();for(let o=0;ow.select("transitionStatus")==="ending",shouldOpen(){return!B.current}}),be=wl(_,{enabled:!N}).reference,ye=Le=>{let X=B.current,M=Lp(Le),K=xe(M),H=k.current,Q=H&&M&&Ge(H,M);if(K&&w.select("open")&&w.select("lastOpenChangeReason")===Oe.triggerHover){w.setOpen(!1,De(Oe.triggerHover,Le));return}if(X&&!K&&Q&&!q.current&&!w.select("open")&&H&&Xr(P.current)){let pe=()=>{!B.current&&!q.current&&!w.select("open")&&w.setOpen(!0,De(Oe.triggerHover,Le,H))},le=W();le===0?(re.clear(),pe()):re.start(le,pe)}},$=w.useState("triggerProps",I);return Gt("button",t,{state:{open:v},ref:[r,O,k],props:[se,be,I||U!=="none"?$:void 0,{onMouseOver(Le){ye(Le.nativeEvent)},onFocus(Le){ne(Lp(Le.nativeEvent))&&Le.preventBaseUIHandler()},onMouseLeave(){B.current=!1,re.clear(),P.current=void 0},onPointerEnter(Le){P.current=Le.pointerType},onPointerDown(Le){P.current=Le.pointerType,w.set("closeOnClick",c),c&&!w.select("open")&&w.cancelPendingOpen(Le.nativeEvent)},onClick(Le){c&&!w.select("open")&&w.cancelPendingOpen(Le.nativeEvent)},id:C,"data-trigger-disabled":N?"":void 0,[Np]:N?void 0:""},h],stateAttributesMapping:tp})});var Dp=f(ve(),1);var xs=f(ve(),1),Fl=xs.createContext(void 0);function Vp(){let e=xs.useContext(Fl);if(e===void 0)throw new Error(lr(70));return e}var Al=f(Z(),1),Bp=Dp.forwardRef(function(t,r){let{keepMounted:o=!1,...n}=t;return ur().useState("mounted")||o?(0,Al.jsx)(Fl.Provider,{value:o,children:(0,Al.jsx)(Ep,{ref:r,...n})}):null});var Cs=f(ve(),1);var Ss=f(ve(),1),Il=Ss.createContext(void 0);function bn(){let e=Ss.useContext(Il);if(e===void 0)throw new Error(lr(71));return e}var jp=f(Z(),1),zp=Cs.forwardRef(function(t,r){let{render:o,className:n,anchor:i,positionMethod:s="absolute",side:a="top",align:u="center",sideOffset:l=0,alignOffset:c=0,collisionBoundary:m="clipping-ancestors",collisionPadding:d=5,arrowPadding:h=5,sticky:g=!1,disableAnchorTracking:b=!1,collisionAvoidance:w=Hf,style:C,...x}=t,v=ur(),_=Vp(),k=v.useState("open"),E=v.useState("mounted"),T=v.useState("trackCursorAxis"),O=v.useState("disableHoverablePopup"),I=v.useState("floatingRootContext"),J=v.useState("instantType"),D=v.useState("transitionStatus"),S=v.useState("adaptiveOrigin"),L=fp({anchor:i,positionMethod:s,floatingRootContext:I,mounted:E,side:a,sideOffset:l,align:u,alignOffset:c,collisionBoundary:m,collisionPadding:d,sticky:g,arrowPadding:h,disableAnchorTracking:b,keepMounted:_,collisionAvoidance:w,adaptiveOrigin:S}),Y=Cs.useMemo(()=>({open:k,side:L.side,align:L.align,anchorHidden:L.anchorHidden,instant:T!=="none"?"tracking-cursor":J}),[k,L.side,L.align,L.anchorHidden,T,J]),A=dp(t,Y,{styles:L.positionerStyles,transitionStatus:D,props:x,refs:[r,v.useStateSetter("positionerElement")],hidden:!E,inert:!k||T==="both"||O});return(0,jp.jsx)(Il.Provider,{value:L,children:A})});var Hp=f(ve(),1);var Up=Hp.forwardRef(function(t,r){let{render:o,className:n,style:i,...s}=t,a=ur(),{side:u,align:l}=bn(),c=a.useState("open"),m=a.useState("instantType"),d=a.useState("transitionStatus"),h=a.useState("popupProps"),g=a.useState("floatingRootContext"),b=a.useState("disabled"),w=a.useState("closeDelay");zi({open:c,ref:a.context.popupRef,onComplete(){c&&a.context.onOpenChangeComplete?.(!0)}}),Cl(g,{enabled:!b,closeDelay:w});let C=a.useStateSetter("popupElement");return Gt("div",t,{state:{open:c,side:u,align:l,instant:m,transitionStatus:d},ref:[r,a.context.popupRef,C],props:[Md,h,ds(d),s],stateAttributesMapping:rp})});var Wp=f(ve(),1);var Gp=Wp.forwardRef(function(t,r){let{render:o,className:n,style:i,...s}=t,a=ur(),{arrowRef:u,side:l,align:c,arrowUncentered:m,arrowStyles:d}=bn(),h=a.useState("open"),g=a.useState("instantType");return Gt("div",t,{state:{open:h,side:l,align:c,uncentered:m,instant:g},ref:[r,u],props:[{style:d,"aria-hidden":!0},s],stateAttributesMapping:ni})});var Yp=f(ve(),1);var Ll=f(Z(),1),qp=function(t){let{delay:r,closeDelay:o,timeout:n=400}=t,i=Yp.useMemo(()=>({open:r,close:o}),[r,o]);return(0,Ll.jsx)(kl.Provider,{value:r,children:(0,Ll.jsx)($a,{delay:i,timeoutMs:n,children:t.children})})};var Zp=f(ve(),1);var Xp=Zp.forwardRef(function(t,r){let{render:o,className:n,style:i,children:s,...a}=t,u=ur(),l=bn(),c=u.useState("instantType"),{children:m,state:d}=Cp({store:u,side:l.side,children:s}),h={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:c};return Gt("div",t,{state:h,ref:r,props:[a,{children:m}],stateAttributesMapping:Sp})});var si=class extends es{constructor(){super(Op(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function Kp(){return new si}function Vr(e){return Gt(e.defaultTagName??"div",e,e)}var $p=f(Te(),1),Nl="data-wp-hash";function Ml(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&jw(document)),e.__wpStyleRuntime}function Bw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Nl}]`))if(r.getAttribute(Nl)===t)return!0;return!1}function em(e,t,r){if(!e.head)return;let o=Ml(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Bw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Nl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function jw(e){let t=Ml();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)em(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function tm(e,t){let r=Ml();r.styles.set(e,t);for(let o of r.documents.keys())em(o,e,t)}typeof process>"u",tm("a495f9d138",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Jp={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",tm("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var Qp={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},wn=(0,$p.forwardRef)(function({variant:t="body-md",render:r,className:o,...n},i){return Vr({render:r,defaultTagName:"span",ref:i,props:It(n,{className:We(Jp.text,Qp.heading,Qp.p,Jp[t],o)})})});var _s=f(Te(),1),ai=(0,_s.forwardRef)(({icon:e,size:t=24,...r},o)=>(0,_s.cloneElement)(e,{width:t,height:t,...r,ref:o}));var Rs=f(xn(),1),Vl=f(Z(),1),Uo=(0,Vl.jsx)(Rs.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Vl.jsx)(Rs.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"})});var Es=f(xn(),1),Dl=f(Z(),1),Wo=(0,Dl.jsx)(Es.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Dl.jsx)(Es.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"})});var Ts=f(xn(),1),Bl=f(Z(),1),jl=(0,Bl.jsx)(Ts.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Bl.jsx)(Ts.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"})});var Ps=f(xn(),1),zl=f(Z(),1),Os=(0,zl.jsx)(Ps.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,zl.jsx)(Ps.Path,{d:"M6.6 6L5.4 7l4.5 5-4.5 5 1.1 1 5.5-6-5.4-6zm6 0l-1.1 1 4.5 5-4.5 5 1.1 1 5.5-6-5.5-6z"})});var ks=f(xn(),1),Hl=f(Z(),1),Fs=(0,Hl.jsx)(ks.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Hl.jsx)(ks.Path,{d:"M11.6 7l-1.1-1L5 12l5.5 6 1.1-1L7 12l4.6-5zm6 0l-1.1-1-5.5 6 5.5 6 1.1-1-4.6-5 4.6-5z"})});var Sn={};so(Sn,{Popup:()=>Cm,Portal:()=>As,Positioner:()=>Is,Provider:()=>Am,Root:()=>km,Trigger:()=>Em});var xm=f(Te(),1);var lm=f(Te(),1);var Wl="data-wp-hash";function Gl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Hw(document)),e.__wpStyleRuntime}function zw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Wl}]`))if(r.getAttribute(Wl)===t)return!0;return!1}function im(e,t,r){if(!e.head)return;let o=Gl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(zw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Wl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Hw(e){let t=Gl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)im(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Uw(e,t){let r=Gl();r.styles.set(e,t);for(let o of r.documents.keys())im(o,e,t)}typeof process>"u",Uw("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var nm={slot:"_11fc52b637ff8a7e__slot"},sm="data-wp-compat-overlay-slot";function Ww(){return typeof document>"u"?null:document}function Gw(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var Dr=null;function Ul(e){return e.setAttribute("aria-hidden","false"),e}function Yw(e){let t=e.createElement("div");return t.setAttribute(sm,""),nm.slot&&t.classList.add(nm.slot),e.body.appendChild(t),t}function am(){if(typeof window>"u"||!Gw()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=Ww();if(!e||!e.body)return;if(Dr&&Dr.ownerDocument===e&&Dr.isConnected)return Ul(Dr);let t=e.querySelector(`[${sm}]`);return t instanceof HTMLDivElement?(Dr=Ul(t),Dr):(Dr?.isConnected&&Dr.remove(),Dr=Ul(Yw(e)),Dr)}var cm=f(Z(),1),As=(0,lm.forwardRef)(function({container:t,...r},o){return(0,cm.jsx)(Xt.Portal,{container:t??am(),...r,ref:o})});var um=f(Te(),1),pm=f(Z(),1),Yl="data-wp-hash";function ql(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Zw(document)),e.__wpStyleRuntime}function qw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Yl}]`))if(r.getAttribute(Yl)===t)return!0;return!1}function fm(e,t,r){if(!e.head)return;let o=ql(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(qw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Yl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Zw(e){let t=ql();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)fm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function dm(e,t){let r=ql();r.styles.set(e,t);for(let o of r.documents.keys())fm(o,e,t)}typeof process>"u",dm("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Xw={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",dm("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Kw={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Is=(0,um.forwardRef)(function({align:t="center",className:r,side:o="top",sideOffset:n=4,...i},s){return(0,pm.jsx)(Xt.Positioner,{ref:s,align:t,side:o,sideOffset:n,...i,className:We(Xw["box-sizing"],Kw.positioner,r)})});var mm=f(Te(),1);function Zl(e,t,r){return(0,mm.cloneElement)(e??t,{children:r})}var Jw=f(gm(),1);var vm=f(li(),1),{lock:dA,unlock:bm}=(0,vm.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function Qw(){let e=Jw;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return bm(e.privateApis).ThemeProvider}var wm=Qw();var ci=f(Z(),1),Xl="data-wp-hash";function Kl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&e1(document)),e.__wpStyleRuntime}function $w(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Xl}]`))if(r.getAttribute(Xl)===t)return!0;return!1}function Sm(e,t,r){if(!e.head)return;let o=Kl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if($w(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Xl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function e1(e){let t=Kl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Sm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function t1(e,t){let r=Kl();r.styles.set(e,t);for(let o of r.documents.keys())Sm(o,e,t)}typeof process>"u",t1("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var r1={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},o1={background:"#1e1e1e"},Cm=(0,xm.forwardRef)(function({portal:t,positioner:r,children:o,className:n,...i},s){let a=(0,ci.jsx)(wm,{color:o1,children:(0,ci.jsx)(Xt.Popup,{ref:s,className:We(r1.popup,n),...i,children:o})}),u=Zl(r,(0,ci.jsx)(Is,{}),a);return Zl(t,(0,ci.jsx)(As,{}),u)});var _m=f(Te(),1),Rm=f(Z(),1),Em=(0,_m.forwardRef)(function(t,r){return(0,Rm.jsx)(Xt.Trigger,{ref:r,...t})});var Tm=f(ge(),1),Pm=f(Z(),1);function Om({children:e}){return(0,Pm.jsx)(hs,{direction:(0,Tm.isRTL)()?"rtl":"ltr",children:e})}var Jl=f(Z(),1);function km(e){return(0,Jl.jsx)(Om,{children:(0,Jl.jsx)(Xt.Root,{...e})})}var Fm=f(Z(),1);function Am({...e}){return(0,Fm.jsx)(Xt.Provider,{...e})}var Im=f(Te(),1),Ql="data-wp-hash";function $l(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&i1(document)),e.__wpStyleRuntime}function n1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Ql}]`))if(r.getAttribute(Ql)===t)return!0;return!1}function Lm(e,t,r){if(!e.head)return;let o=$l(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(n1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Ql,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function i1(e){let t=$l();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Lm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function s1(e,t){let r=$l();r.styles.set(e,t);for(let o of r.documents.keys())Lm(o,e,t)}typeof process>"u",s1("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var a1={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},ec=(0,Im.forwardRef)(function({render:t,...r},o){return Vr({render:t,ref:o,props:It({className:a1["visually-hidden"]},r,{"data-visually-hidden":""})})});var Nm=f(Te(),1),tc="data-wp-hash";function rc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&c1(document)),e.__wpStyleRuntime}function l1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${tc}]`))if(r.getAttribute(tc)===t)return!0;return!1}function Mm(e,t,r){if(!e.head)return;let o=rc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(l1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(tc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function c1(e){let t=rc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Mm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function u1(e,t){let r=rc();r.styles.set(e,t);for(let o of r.documents.keys())Mm(o,e,t)}typeof process>"u",u1("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var f1={stack:"_19ce0419607e1896__stack"},d1={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},vo=(0,Nm.forwardRef)(function({direction:t,gap:r,align:o,justify:n,wrap:i,render:s,...a},u){let l={gap:r&&d1[r],alignItems:o,justifyContent:n,flexDirection:t,flexWrap:i};return Vr({render:s,ref:u,props:It(a,{style:l,className:f1.stack})})});var Vm=f(Te(),1),Dm=f(ge(),1),Cn=f(Z(),1),oc="data-wp-hash";function nc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&m1(document)),e.__wpStyleRuntime}function p1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${oc}]`))if(r.getAttribute(oc)===t)return!0;return!1}function Bm(e,t,r){if(!e.head)return;let o=nc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(p1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(oc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function m1(e){let t=nc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Bm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Ns(e,t){let r=nc();r.styles.set(e,t);for(let o of r.documents.keys())Bm(o,e,t)}typeof process>"u",Ns("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var h1={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Ns("96553466c8","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._64de9947bf305b7a__outset-ring--focus-within-visible:focus-within:has(:focus-visible),.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var g1={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-within-visible":"_64de9947bf305b7a__outset-ring--focus-within-visible","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",Ns("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var Ls={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",Ns("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");var y1={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a"},ic=(0,Vm.forwardRef)(function({children:t,variant:r="default",tone:o="brand",openInNewTab:n=!1,render:i,className:s,...a},u){return Vr({render:i,defaultTagName:"a",ref:u,props:It(a,{className:We(y1.a,h1["box-sizing"],g1["outset-ring--focus-except-active"],r!=="unstyled"&&Ls.link,r!=="unstyled"&&Ls[`is-${o}`],r==="unstyled"&&Ls["is-unstyled"],s),target:n?"_blank":void 0,children:(0,Cn.jsxs)(Cn.Fragment,{children:[t,n&&(0,Cn.jsx)("span",{className:Ls["link-icon"],role:"img","aria-label":(0,Dm.__)("(opens in a new tab)")})]})})})});var zm=f(Te(),1),sc="data-wp-hash";function ac(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&b1(document)),e.__wpStyleRuntime}function v1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${sc}]`))if(r.getAttribute(sc)===t)return!0;return!1}function Hm(e,t,r){if(!e.head)return;let o=ac(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(v1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(sc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function b1(e){let t=ac();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Hm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Um(e,t){let r=ac();r.styles.set(e,t);for(let o of r.documents.keys())Hm(o,e,t)}typeof process>"u",Um("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var w1={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Um("ed2c39ec90","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.b20cc1690085c2f0__skeleton{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);display:block;@media (forced-colors:active){border:var(--wpds-border-width-xs,1px) solid CanvasText}}._9b143194fdb45f93__pulse{@media not (prefers-reduced-motion){animation:e2b9fe0690281bc8__skeleton-pulse 1.5s ease-in-out infinite}}@keyframes e2b9fe0690281bc8__skeleton-pulse{0%,to{opacity:1}50%{opacity:.4}}}}");var jm={skeleton:"b20cc1690085c2f0__skeleton",pulse:"_9b143194fdb45f93__pulse","skeleton-pulse":"e2b9fe0690281bc8__skeleton-pulse"},ui=(0,zm.forwardRef)(function({render:t,...r},o){return Vr({render:t,ref:o,props:It({className:We(jm.skeleton,jm.pulse,w1["box-sizing"]),"aria-hidden":!0},r)})});var Wm=f(Te(),1),Gm=f(Z(),1),Ym=(0,Wm.forwardRef)(({children:e,className:t,ariaLabel:r,as:o="div",...n},i)=>(0,Gm.jsx)(o,{ref:i,className:We("admin-ui-navigable-region",t),"aria-label":r,role:"region",tabIndex:"-1",...n,children:e}));Ym.displayName="NavigableRegion";var qm=Ym;var Zm=f(ge(),1);var bo=f(Z(),1),cc="data-wp-hash";function uc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&S1(document)),e.__wpStyleRuntime}function x1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${cc}]`))if(r.getAttribute(cc)===t)return!0;return!1}function Xm(e,t,r){if(!e.head)return;let o=uc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(x1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(cc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function S1(e){let t=uc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Xm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function C1(e,t){let r=uc();r.styles.set(e,t);for(let o of r.documents.keys())Xm(o,e,t)}typeof process>"u",C1("72ef022400",".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}");var lc={list:"bfb5a2dd8cceebd3__list",li:"a4759b4cb2c8bd92__li",item:"_07da506d3f2d9afe__item"},_1=({items:e,currentHref:t,ariaLabel:r=(0,Zm.__)("Sections"),linkComponent:o,className:n})=>{if(!e.length)return null;let i=o??"a";return(0,bo.jsx)("nav",{"aria-label":r,className:n,children:(0,bo.jsx)(vo,{render:(0,bo.jsx)("ul",{role:"list"}),direction:"row",align:"center",gap:"md",className:lc.list,children:e.map(s=>(0,bo.jsx)("li",{className:lc.li,children:(0,bo.jsx)(wn,{variant:"body-md",className:lc.item,render:(0,bo.jsx)(ic,{variant:"unstyled","aria-current":s.href===t?"page":void 0,render:(0,bo.jsx)(i,{href:s.href})}),children:s.label})},s.href))})})},Km=_1;var Qm=f(ue(),1),{Fill:$m,Slot:eh}=(0,Qm.createSlotFill)("SidebarToggle");var ir=f(Z(),1),fc="data-wp-hash";function dc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&E1(document)),e.__wpStyleRuntime}function R1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${fc}]`))if(r.getAttribute(fc)===t)return!0;return!1}function th(e,t,r){if(!e.head)return;let o=dc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(R1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(fc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function E1(e){let t=dc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)th(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function T1(e,t){let r=dc();r.styles.set(e,t);for(let o of r.documents.keys())th(o,e,t)}typeof process>"u",T1("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var Br={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function rh({headingLevel:e=1,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,actions:s,navigation:a,components:u,showSidebarToggle:l=!0}){let c=`h${e}`,m=!!a?.items?.length;return(0,ir.jsxs)(vo,{direction:"column",className:We(Br.header,m&&Br["has-navigation"]),children:[(0,ir.jsxs)(vo,{className:Br["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,ir.jsxs)(vo,{direction:"row",gap:"sm",align:"center",justify:"start",className:Br["header-lockup"],children:[l&&(0,ir.jsx)(eh,{bubblesVirtually:!0,className:Br["sidebar-toggle-slot"]}),o&&(0,ir.jsx)("div",{className:Br["header-visual"],"aria-hidden":"true",children:o}),n&&(0,ir.jsx)(wn,{className:Br["header-title"],render:(0,ir.jsx)(c,{}),variant:"heading-lg",children:n}),t,r]}),s&&(0,ir.jsx)(vo,{align:"center",className:Br["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,ir.jsx)(wn,{render:(0,ir.jsx)("p",{}),variant:"body-md",className:Br["header-subtitle"],children:i}),m&&(0,ir.jsx)(Km,{...a,linkComponent:u?.link,className:Br["header-navigation"]})]})}var fi=f(Z(),1),mc="data-wp-hash";function hc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&O1(document)),e.__wpStyleRuntime}function P1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${mc}]`))if(r.getAttribute(mc)===t)return!0;return!1}function oh(e,t,r){if(!e.head)return;let o=hc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(P1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(mc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function O1(e){let t=hc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)oh(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function k1(e,t){let r=hc();r.styles.set(e,t);for(let o of r.documents.keys())oh(o,e,t)}typeof process>"u",k1("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var pc={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function nh({headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,children:s,className:a,actions:u,navigation:l,components:c,ariaLabel:m,hasPadding:d=!1,showSidebarToggle:h=!0}){let g=We(pc.page,a);return(0,fi.jsxs)(qm,{className:g,ariaLabel:m??(typeof n=="string"?n:""),children:[(n||t||r||u||o||!!l?.items?.length)&&(0,fi.jsx)(rh,{headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,actions:u,navigation:l,components:c,showSidebarToggle:h}),d?(0,fi.jsx)("div",{className:We(pc.content,pc["has-padding"]),children:s}):s]})}nh.SidebarToggleFill=$m;var gc=nh;var zn=f(ge()),Vv=f(ue()),Dv=f(sh()),Ea=f(sr()),Bv=f(Kt()),jv=f(Te());var Lv=f(ue(),1),Nv=f(_n(),1),RE=f(Kt(),1),EE=f(Dt(),1),Au=f(Te(),1),TE=f(yo(),1);function Rn(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let i of t){let s=n[i];n=n[i]=Array.isArray(s)?[...s]:{...s}}return n[o]=r,e}var ht=(e,t,r)=>{let o=Array.isArray(t)?t:t.split("."),n=e;return o.forEach(i=>{n=n?.[i]}),n??r};var F1=["appearanceTools","useRootPaddingAwareAlignments","background.backgroundImage","background.backgroundRepeat","background.backgroundSize","background.backgroundPosition","background.gradient","border.color","border.radius","border.radiusSizes","border.style","border.width","shadow.presets","shadow.defaultPresets","color.background","color.button","color.caption","color.custom","color.customDuotone","color.customGradient","color.defaultDuotone","color.defaultGradients","color.defaultPalette","color.duotone","color.gradients","color.heading","color.link","color.palette","color.text","custom","dimensions.aspectRatio","dimensions.height","dimensions.minHeight","dimensions.minWidth","dimensions.width","dimensions.dimensionSizes","layout.contentSize","layout.definitions","layout.wideSize","lightbox.enabled","lightbox.allowEditing","position.fixed","position.sticky","spacing.customSpacingSize","spacing.defaultSpacingSizes","spacing.spacingSizes","spacing.spacingScale","spacing.blockGap","spacing.margin","spacing.padding","spacing.units","typography.fluid","typography.customFontSize","typography.defaultFontSizes","typography.dropCap","typography.fontFamilies","typography.fontSizes","typography.fontStyle","typography.fontWeight","typography.letterSpacing","typography.lineHeight","typography.textAlign","typography.textColumns","typography.textDecoration","typography.textIndent","typography.textTransform","typography.writingMode","viewport.mobile","viewport.tablet"];function yc(e,t,r){let o=r?".blocks."+r:"",n=t?"."+t:"",i=`settings${o}${n}`,s=`settings${n}`;if(t)return ht(e,i)??ht(e,s);let a={};return F1.forEach(u=>{let l=ht(e,`settings${o}.${u}`)??ht(e,`settings.${u}`);l!==void 0&&(a=Rn(a,u.split("."),l))}),a}function vc(e,t,r,o){let n=o?".blocks."+o:"",i=t?"."+t:"",s=`settings${n}${i}`;return Rn(e,s.split("."),r)}var hh=f(dh(),1);var A1="1600px",I1="320px",L1=1,N1=.25,M1=.75,V1="14px";function ph({minimumFontSize:e,maximumFontSize:t,fontSize:r,minimumViewportWidth:o=I1,maximumViewportWidth:n=A1,scaleFactor:i=L1,minimumFontSizeLimit:s}){if(s=jr(s)?s:V1,r){let v=jr(r);if(!v?.unit||!v?.value)return null;let _=jr(s,{coerceTo:v.unit});if(_?.value&&!e&&!t&&v?.value<=_?.value)return null;if(t||(t=`${v.value}${v.unit}`),!e){let k=v.unit==="px"?v.value:v.value*16,E=Math.min(Math.max(1-.075*Math.log2(k),N1),M1),T=di(v.value*E,3);_?.value&&T<_?.value?e=`${_.value}${_.unit}`:e=`${T}${v.unit}`}}let a=jr(e),u=a?.unit||"rem",l=jr(t,{coerceTo:u});if(!a||!l)return null;let c=jr(e,{coerceTo:"rem"}),m=jr(n,{coerceTo:u}),d=jr(o,{coerceTo:u});if(!m||!d||!c)return null;let h=m.value-d.value;if(!h)return null;let g=di(d.value/100,3),b=di(g,3)+u,w=100*((l.value-a.value)/h),C=di((w||1)*i,3),x=`${c.value}${c.unit} + ((1vw - ${b}) * ${C})`;return`clamp(${e}, ${x}, ${t})`}function jr(e,t={}){if(typeof e!="string"&&typeof e!="number")return null;isFinite(e)&&(e=`${e}px`);let{coerceTo:r,rootSizeValue:o,acceptableUnits:n}={coerceTo:"",rootSizeValue:16,acceptableUnits:["rem","px","em"],...t},i=n?.join("|"),s=new RegExp(`^(\\d*\\.?\\d+)(${i}){1,1}$`),a=e.toString().match(s);if(!a||a.length<3)return null;let[,u,l]=a,c=parseFloat(u);return r==="px"&&(l==="em"||l==="rem")&&(c=c*o,l=r),l==="px"&&(r==="em"||r==="rem")&&(c=c/o,l=r),(r==="em"||r==="rem")&&(l==="em"||l==="rem")&&(l=r),l?{value:di(c,3),unit:l}:null}function di(e,t=3){let r=Math.pow(10,t);return Math.round(e*r)/r}function bc(e){let t=e?.fluid;return t===!0||t&&typeof t=="object"&&Object.keys(t).length>0}function D1(e){let t=e?.typography??{},r=e?.layout,o=jr(r?.wideSize)?r?.wideSize:null;return bc(t)&&o?{fluid:{maxViewportWidth:o,...typeof t.fluid=="object"?t.fluid:{}}}:{fluid:t?.fluid}}function mh(e,t){let{size:r}=e;if(!r||r==="0"||e?.fluid===!1||!bc(t?.typography)&&!bc(e))return r;let o=D1(t)?.fluid??{},n=ph({minimumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.min,maximumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.max,fontSize:r,minimumFontSizeLimit:typeof o=="object"?o?.minFontSize:void 0,maximumViewportWidth:typeof o=="object"?o?.maxViewportWidth:void 0,minimumViewportWidth:typeof o=="object"?o?.minViewportWidth:void 0});return n||r}var B1=[{path:["color","palette"],valueKey:"color",cssVarInfix:"color",classes:[{classSuffix:"color",propertyName:"color"},{classSuffix:"background-color",propertyName:"background-color"},{classSuffix:"border-color",propertyName:"border-color"}]},{path:["color","gradients"],valueKey:"gradient",cssVarInfix:"gradient",classes:[{classSuffix:"gradient-background",propertyName:"background"}]},{path:["color","duotone"],valueKey:"colors",cssVarInfix:"duotone",valueFunc:({slug:e})=>`url( '#wp-duotone-${e}' )`,classes:[]},{path:["shadow","presets"],valueKey:"shadow",cssVarInfix:"shadow",classes:[]},{path:["typography","fontSizes"],valueFunc:(e,t)=>mh(e,t),valueKey:"size",cssVarInfix:"font-size",classes:[{classSuffix:"font-size",propertyName:"font-size"}]},{path:["typography","fontFamilies"],valueKey:"fontFamily",cssVarInfix:"font-family",classes:[{classSuffix:"font-family",propertyName:"font-family"}]},{path:["spacing","spacingSizes"],valueKey:"size",cssVarInfix:"spacing",valueFunc:({size:e})=>e,classes:[]},{path:["border","radiusSizes"],valueKey:"size",cssVarInfix:"border-radius",classes:[]},{path:["dimensions","dimensionSizes"],valueKey:"size",cssVarInfix:"dimension",classes:[]}];function j1(e,t){if(!e||!t)return e;if(typeof e=="object"&&"ref"in e&&e?.ref){let r=(0,hh.getCSSValueFromRawStyle)(ht(t,e.ref));return typeof r=="object"&&r!==null&&"ref"in r&&r?.ref?void 0:r===void 0?e:r}return e}function z1(e,t){if(!e||!t||!Array.isArray(t))return e;let r=t.find(o=>o?.name===e);return r?.href?r?.href:e}function gh(e,t){if(!e||!t)return e;let r=j1(e,t);return typeof r=="object"&&r!==null&&"url"in r&&r?.url&&(r.url=z1(r.url,t?._links?.["wp:theme-file"])),r}function yh(e,t,r=[],o="slug",n){let i=[t?ht(e,["blocks",t,...r]):void 0,ht(e,r)].filter(Boolean);for(let s of i)if(s){let a=["custom","theme","default"];for(let u of a){let l=s[u];if(l){let c=l.find(m=>m[o]===n);if(c)return o==="slug"||yh(e,t,r,"slug",c.slug)[o]===c[o]?c:void 0}}}}function H1(e,t,r,[o,n]=[]){let i=B1.find(a=>a.cssVarInfix===o);if(!i||!e.settings)return r;let s=yh(e.settings,t,i.path,"slug",n);if(s){let{valueKey:a}=i,u=s[a];return Ms(e,t,u)}return r}function U1(e,t,r,o=[]){let n=(t?ht(e?.settings??{},["blocks",t,"custom",...o]):void 0)??ht(e?.settings??{},["custom",...o]);return n?Ms(e,t,n):r}function Ms(e,t,r){if(!r||typeof r!="string")if(typeof r=="object"&&r!==null&&"ref"in r&&typeof r.ref=="string"){let l=ht(e,r.ref);if(!l||typeof l=="object"&&"ref"in l)return l;r=l}else return r;let o="var:",n="var(--wp--",i=")",s;if(r.startsWith(o))s=r.slice(o.length).split("|");else if(r.startsWith(n)&&r.endsWith(i))s=r.slice(n.length,-i.length).split("--");else return r;let[a,...u]=s;return a==="preset"?H1(e,t,r,u):a==="custom"?U1(e,t,r,u):r}function Vs(e,t,r,o=!0){let n=t?"."+t:"",i=r?`styles.blocks.${r}${n}`:`styles${n}`;if(!e)return;let s=ht(e,i),a=void 0;if(s===void 0&&a){let l=!0,c=e;for(let m of i.split(".")){if(!c||typeof c!="object"||!Object.hasOwn(c,m)){l=!1;break}c=c[m]}l||(s=ht(e,a))}return o?Ms(e,r,s):s}function wc(e,t,r,o){let n=t?"."+t:"",i=o?`styles.blocks.${o}${n}`:`styles${n}`;return Rn(e,i.split("."),r)}var xc=f(bh(),1);function pi(e,t){return typeof e!="object"||typeof t!="object"?e===t:(0,xc.default)(e?.styles,t?.styles)&&(0,xc.default)(e?.settings,t?.settings)}var Eh=f(Ch(),1);function _h(e){return Object.prototype.toString.call(e)==="[object Object]"}function Rh(e){var t,r;return _h(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(_h(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}function Go(e,t){return(0,Eh.default)(e,t,{isMergeableObject:Rh,customMerge:r=>{if(r==="backgroundImage")return(o,n)=>n??o}})}var ox={grad:.9,turn:360,rad:360/(2*Math.PI)},Jr=function(e){return typeof e=="string"?e.length>0:typeof e=="number"},bt=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=Math.pow(10,t)),Math.round(r*e)/r+0},dr=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=1),e>r?r:e>t?e:t},Lh=function(e){return(e=isFinite(e)?e%360:0)>0?e:e+360},Th=function(e){return{r:dr(e.r,0,255),g:dr(e.g,0,255),b:dr(e.b,0,255),a:dr(e.a)}},Sc=function(e){return{r:bt(e.r),g:bt(e.g),b:bt(e.b),a:bt(e.a,3)}},nx=/^#([0-9a-f]{3,8})$/i,Ds=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},Nh=function(e){var t=e.r,r=e.g,o=e.b,n=e.a,i=Math.max(t,r,o),s=i-Math.min(t,r,o),a=s?i===t?(r-o)/s:i===r?2+(o-t)/s:4+(t-r)/s:0;return{h:60*(a<0?a+6:a),s:i?s/i*100:0,v:i/255*100,a:n}},Mh=function(e){var t=e.h,r=e.s,o=e.v,n=e.a;t=t/360*6,r/=100,o/=100;var i=Math.floor(t),s=o*(1-r),a=o*(1-(t-i)*r),u=o*(1-(1-t+i)*r),l=i%6;return{r:255*[o,a,s,s,u,o][l],g:255*[u,o,o,a,s,s][l],b:255*[s,s,u,o,o,a][l],a:n}},Ph=function(e){return{h:Lh(e.h),s:dr(e.s,0,100),l:dr(e.l,0,100),a:dr(e.a)}},Oh=function(e){return{h:bt(e.h),s:bt(e.s),l:bt(e.l),a:bt(e.a,3)}},kh=function(e){return Mh((r=(t=e).s,{h:t.h,s:(r*=((o=t.l)<50?o:100-o)/100)>0?2*r/(o+r)*100:0,v:o+r,a:t.a}));var t,r,o},hi=function(e){return{h:(t=Nh(e)).h,s:(n=(200-(r=t.s))*(o=t.v)/100)>0&&n<200?r*o/100/(n<=100?n:200-n)*100:0,l:n/2,a:t.a};var t,r,o,n},ix=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,sx=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ax=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,lx=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Rc={string:[[function(e){var t=nx.exec(e);return t?(e=t[1]).length<=4?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:e.length===4?bt(parseInt(e[3]+e[3],16)/255,2):1}:e.length===6||e.length===8?{r:parseInt(e.substr(0,2),16),g:parseInt(e.substr(2,2),16),b:parseInt(e.substr(4,2),16),a:e.length===8?bt(parseInt(e.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(e){var t=ax.exec(e)||lx.exec(e);return t?t[2]!==t[4]||t[4]!==t[6]?null:Th({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:t[7]===void 0?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(e){var t=ix.exec(e)||sx.exec(e);if(!t)return null;var r,o,n=Ph({h:(r=t[1],o=t[2],o===void 0&&(o="deg"),Number(r)*(ox[o]||1)),s:Number(t[3]),l:Number(t[4]),a:t[5]===void 0?1:Number(t[5])/(t[6]?100:1)});return kh(n)},"hsl"]],object:[[function(e){var t=e.r,r=e.g,o=e.b,n=e.a,i=n===void 0?1:n;return Jr(t)&&Jr(r)&&Jr(o)?Th({r:Number(t),g:Number(r),b:Number(o),a:Number(i)}):null},"rgb"],[function(e){var t=e.h,r=e.s,o=e.l,n=e.a,i=n===void 0?1:n;if(!Jr(t)||!Jr(r)||!Jr(o))return null;var s=Ph({h:Number(t),s:Number(r),l:Number(o),a:Number(i)});return kh(s)},"hsl"],[function(e){var t=e.h,r=e.s,o=e.v,n=e.a,i=n===void 0?1:n;if(!Jr(t)||!Jr(r)||!Jr(o))return null;var s=(function(a){return{h:Lh(a.h),s:dr(a.s,0,100),v:dr(a.v,0,100),a:dr(a.a)}})({h:Number(t),s:Number(r),v:Number(o),a:Number(i)});return Mh(s)},"hsv"]]},Fh=function(e,t){for(var r=0;r=.5},e.prototype.toHex=function(){return t=Sc(this.rgba),r=t.r,o=t.g,n=t.b,s=(i=t.a)<1?Ds(bt(255*i)):"","#"+Ds(r)+Ds(o)+Ds(n)+s;var t,r,o,n,i,s},e.prototype.toRgb=function(){return Sc(this.rgba)},e.prototype.toRgbString=function(){return t=Sc(this.rgba),r=t.r,o=t.g,n=t.b,(i=t.a)<1?"rgba("+r+", "+o+", "+n+", "+i+")":"rgb("+r+", "+o+", "+n+")";var t,r,o,n,i},e.prototype.toHsl=function(){return Oh(hi(this.rgba))},e.prototype.toHslString=function(){return t=Oh(hi(this.rgba)),r=t.h,o=t.s,n=t.l,(i=t.a)<1?"hsla("+r+", "+o+"%, "+n+"%, "+i+")":"hsl("+r+", "+o+"%, "+n+"%)";var t,r,o,n,i},e.prototype.toHsv=function(){return t=Nh(this.rgba),{h:bt(t.h),s:bt(t.s),v:bt(t.v),a:bt(t.a,3)};var t},e.prototype.invert=function(){return fr({r:255-(t=this.rgba).r,g:255-t.g,b:255-t.b,a:t.a});var t},e.prototype.saturate=function(t){return t===void 0&&(t=.1),fr(Cc(this.rgba,t))},e.prototype.desaturate=function(t){return t===void 0&&(t=.1),fr(Cc(this.rgba,-t))},e.prototype.grayscale=function(){return fr(Cc(this.rgba,-1))},e.prototype.lighten=function(t){return t===void 0&&(t=.1),fr(Ah(this.rgba,t))},e.prototype.darken=function(t){return t===void 0&&(t=.1),fr(Ah(this.rgba,-t))},e.prototype.rotate=function(t){return t===void 0&&(t=15),this.hue(this.hue()+t)},e.prototype.alpha=function(t){return typeof t=="number"?fr({r:(r=this.rgba).r,g:r.g,b:r.b,a:t}):bt(this.rgba.a,3);var r},e.prototype.hue=function(t){var r=hi(this.rgba);return typeof t=="number"?fr({h:t,s:r.s,l:r.l,a:r.a}):bt(r.h)},e.prototype.isEqual=function(t){return this.toHex()===fr(t).toHex()},e})(),fr=function(e){return e instanceof Ec?e:new Ec(e)},Ih=[],Vh=function(e){e.forEach(function(t){Ih.indexOf(t)<0&&(t(Ec,Rc),Ih.push(t))})};function ux(e=[]){let t={r:[],g:[],b:[],a:[]};return e.forEach(r=>{let o=fr(r).toRgb();t.r.push(o.r/255),t.g.push(o.g/255),t.b.push(o.b/255),t.a.push(o.a)}),t}function Dh(e){return`${e}{filter:none}`}function Bh(e,t){return`${e}{filter:url(#${t})}`}function jh(e,t){let r=ux(t);return` +var Dv=Object.create;var Oa=Object.defineProperty;var Bv=Object.getOwnPropertyDescriptor;var jv=Object.getOwnPropertyNames;var zv=Object.getPrototypeOf,Hv=Object.prototype.hasOwnProperty;var Wt=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var tt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),so=(e,t)=>{for(var r in t)Oa(e,r,{get:t[r],enumerable:!0})},Uv=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of jv(t))!Hv.call(e,n)&&n!==r&&Oa(e,n,{get:()=>t[n],enumerable:!(o=Bv(t,n))||o.enumerable});return e};var f=(e,t,r)=>(r=e!=null?Dv(zv(e)):{},Uv(t||!e||!e.__esModule?Oa(r,"default",{value:e,enumerable:!0}):r,e));var ge=tt((AE,Mu)=>{Mu.exports=window.wp.i18n});var Te=tt((LE,Du)=>{Du.exports=window.wp.element});var ve=tt((NE,Bu)=>{Bu.exports=window.React});var Z=tt((HE,Uu)=>{Uu.exports=window.ReactJSXRuntime});var lo=tt((MT,hf)=>{hf.exports=window.ReactDOM});var gd=tt(hd=>{"use strict";var fn=ve();function U0(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var W0=typeof Object.is=="function"?Object.is:U0,G0=fn.useState,Y0=fn.useEffect,q0=fn.useLayoutEffect,Z0=fn.useDebugValue;function X0(e,t){var r=t(),o=G0({inst:{value:r,getSnapshot:t}}),n=o[0].inst,i=o[1];return q0(function(){n.value=r,n.getSnapshot=t,fl(n)&&i({inst:n})},[e,r,t]),Y0(function(){return fl(n)&&i({inst:n}),e(function(){fl(n)&&i({inst:n})})},[e]),Z0(r),r}function fl(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!W0(e,r)}catch{return!0}}function K0(e,t){return t()}var J0=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?K0:X0;hd.useSyncExternalStore=fn.useSyncExternalStore!==void 0?fn.useSyncExternalStore:J0});var ts=tt((TO,yd)=>{"use strict";yd.exports=gd()});var bd=tt(vd=>{"use strict";var rs=ve(),Q0=ts();function $0(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var ew=typeof Object.is=="function"?Object.is:$0,tw=Q0.useSyncExternalStore,rw=rs.useRef,ow=rs.useEffect,nw=rs.useMemo,iw=rs.useDebugValue;vd.useSyncExternalStoreWithSelector=function(e,t,r,o,n){var i=rw(null);if(i.current===null){var s={hasValue:!1,value:null};i.current=s}else s=i.current;i=nw(function(){function u(h){if(!l){if(l=!0,c=h,h=o(h),n!==void 0&&s.hasValue){var g=s.value;if(n(g,h))return m=g}return m=h}if(g=m,ew(c,h))return g;var b=o(h);return n!==void 0&&n(g,b)?(c=h,g):(c=h,m=b)}var l=!1,c,m,d=r===void 0?null:r;return[function(){return u(t())},d===null?void 0:function(){return u(d())}]},[t,r,o,n]);var a=tw(e,i[0],i[1]);return ow(function(){s.hasValue=!0,s.value=a},[a]),iw(a),a}});var xd=tt((OO,wd)=>{"use strict";wd.exports=bd()});var yo=tt((NA,Jp)=>{Jp.exports=window.wp.compose});var um=tt((WA,cm)=>{cm.exports=window.wp.theme});var ai=tt((GA,fm)=>{fm.exports=window.wp.privateApis});var _n=tt((C5,km)=>{km.exports=window.wp.primitives});var ue=tt((g4,Ym)=>{Ym.exports=window.wp.components});var th=tt((k4,eh)=>{eh.exports=window.wp.editor});var sr=tt((F4,rh)=>{rh.exports=window.wp.coreData});var Kt=tt((A4,oh)=>{oh.exports=window.wp.data});var Cn=tt((I4,nh)=>{nh.exports=window.wp.blocks});var Dt=tt((L4,ih)=>{ih.exports=window.wp.blockEditor});var ah=tt((j4,sh)=>{sh.exports=window.wp.styleEngine});var ph=tt((Q4,dh)=>{"use strict";dh.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var o,n,i;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;for(n of t.entries())if(!e(n[1],r.get(n[0])))return!1;return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(t[n]!==r[n])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),o=i.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[n]))return!1;for(n=o;n--!==0;){var s=i[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var yh=tt((eI,gh)=>{"use strict";var B1=function(t){return j1(t)&&!z1(t)};function j1(e){return!!e&&typeof e=="object"}function z1(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||W1(e)}var H1=typeof Symbol=="function"&&Symbol.for,U1=H1?Symbol.for("react.element"):60103;function W1(e){return e.$$typeof===U1}function G1(e){return Array.isArray(e)?[]:{}}function mi(e,t){return t.clone!==!1&&t.isMergeableObject(e)?En(G1(e),e,t):e}function Y1(e,t,r){return e.concat(t).map(function(o){return mi(o,r)})}function q1(e,t){if(!t.customMerge)return En;var r=t.customMerge(e);return typeof r=="function"?r:En}function Z1(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function mh(e){return Object.keys(e).concat(Z1(e))}function hh(e,t){try{return t in e}catch{return!1}}function X1(e,t){return hh(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function K1(e,t,r){var o={};return r.isMergeableObject(e)&&mh(e).forEach(function(n){o[n]=mi(e[n],r)}),mh(t).forEach(function(n){X1(e,n)||(hh(e,n)&&r.isMergeableObject(t[n])?o[n]=q1(n,r)(e[n],t[n],r):o[n]=mi(t[n],r))}),o}function En(e,t,r){r=r||{},r.arrayMerge=r.arrayMerge||Y1,r.isMergeableObject=r.isMergeableObject||B1,r.cloneUnlessOtherwiseSpecified=mi;var o=Array.isArray(t),n=Array.isArray(e),i=o===n;return i?o?r.arrayMerge(e,t,r):K1(e,t,r):mi(t,r)}En.all=function(t,r){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(o,n){return En(o,n,r)},{})};var J1=En;gh.exports=J1});var Zc=tt((WN,Pg)=>{Pg.exports=window.wp.keycodes});var Ag=tt((r8,Fg)=>{Fg.exports=window.wp.apiFetch});var gv=tt((X9,hv)=>{hv.exports=window.wp.date});function Vu(e){var t,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e)){var n=e.length;for(t=0;te();function Pe(e){let t=_t(qv).current;return t.next=e,Yv(t.effect),t.trampoline}function qv(){let e={next:void 0,callback:Zv,trampoline:(...t)=>e.callback?.(...t),effect:()=>{e.callback=e.next}};return e}function Zv(){}var Hu=f(ve(),1),Xv=()=>{},we=typeof document<"u"?Hu.useLayoutEffect:Xv;function Kv(e,t){return function(o,...n){let i=new URL(e);return i.searchParams.set("code",o.toString()),n.forEach(s=>i.searchParams.append("args[]",s)),`${t} error #${o}; visit ${i} for the full message.`}}var Jv=Kv("https://base-ui.com/production-error","Base UI"),lr=Jv;var Ao=f(ve(),1);function Fa(e,t,r,o){let n=_t(Gu).current;return Qv(n,e,t,r,o)&&Yu(n,[e,t,r,o]),n.callback}function Wu(e){let t=_t(Gu).current;return $v(t,e)&&Yu(t,e),t.callback}function Gu(){return{callback:null,cleanup:null,refs:[]}}function Qv(e,t,r,o,n){return e.refs[0]!==t||e.refs[1]!==r||e.refs[2]!==o||e.refs[3]!==n}function $v(e,t){return e.refs.length!==t.length||e.refs.some((r,o)=>r!==t[o])}function Yu(e,t){if(e.refs=t,t.every(r=>r==null)){e.callback=null;return}e.callback=r=>{if(e.cleanup&&(e.cleanup(),e.cleanup=null),r!=null){let o=Array(t.length).fill(null);for(let n=0;n{for(let n=0;n=e}function Aa(e){if(!Zu.isValidElement(e))return null;let t=e,r=t.props;return(rn(19)?r?.ref:t.ref)??null}function Yn(e,t){if(e&&!t)return e;if(!e&&t)return t;if(e||t)return{...e,...t}}function tr(){}var Xu=Object.freeze([]),nt=Object.freeze({});function Ku(e,t){let r={};for(let o in e){let n=e[o];if(t?.hasOwnProperty(o)){let i=t[o](n);i!=null&&Object.assign(r,i);continue}n===!0?r[`data-${o.toLowerCase()}`]="":n&&(r[`data-${o.toLowerCase()}`]=n.toString())}return r}function Ju(e,t){return typeof e=="function"?e(t):e}function Qu(e,t){return typeof e=="function"?e(t):e}var Ia={};function It(e,t,r,o,n){if(!r&&!o&&!n&&!e)return Ai(t);let i=Ai(e);return t&&(i=qn(i,t)),r&&(i=qn(i,r)),o&&(i=qn(i,o)),n&&(i=qn(i,n)),i}function $u(e){if(e.length===0)return Ia;if(e.length===1)return Ai(e[0]);let t=Ai(e[0]);for(let r=1;r=65&&n<=90&&(typeof t=="function"||typeof t>"u")}function La(e){return typeof e=="function"}function tf(e,t){return La(e)?e(t):e??Ia}function ob(e,t){return t?e?(...r)=>{let o=r[0];if(nf(o)){let i=o;of(i);let s=t(...r);return i.baseUIHandlerPrevented||e?.(...r),s}let n=t(...r);return e?.(...r),n}:rf(t):e}function rf(e){return e&&((...t)=>{let r=t[0];return nf(r)&&of(r),e(...t)})}function of(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}function Na(e,t){return t?e?t+" "+e:t:e}function nf(e){return e!=null&&typeof e=="object"&&"nativeEvent"in e}var Ma=f(ve(),1);function Gt(e,t,r={}){let o=t.render,n=nb(t,r);if(r.enabled===!1)return null;let i=r.state??nt;return ab(e,o,n,i)}function nb(e,t={}){let{className:r,style:o,render:n}=e,{state:i=nt,ref:s,props:a,stateAttributesMapping:u,enabled:l=!0}=t,c=l?Ju(r,i):void 0,m=l?Qu(o,i):void 0,d=l?Ku(i,u):nt,h=l&&a?ib(a):void 0,g=l?Yn(d,h)??{}:nt;return typeof document<"u"&&(l?Array.isArray(s)?g.ref=Wu([g.ref,Aa(n),...s]):g.ref=Fa(g.ref,Aa(n),s):Fa(null,null)),l?(c!==void 0&&(g.className=Na(g.className,c)),m!==void 0&&(g.style=Yn(g.style,m)),g):nt}function ib(e){return Array.isArray(e)?$u(e):It(void 0,e)}var sb=Symbol.for("react.lazy");function ab(e,t,r,o){if(t){if(typeof t=="function")return t(r,o);let n=It(r,t.props);n.ref=r.ref;let i=t;return i?.$$typeof===sb&&(i=Ao.Children.toArray(t)[0]),Ao.cloneElement(i,n)}if(e&&typeof e=="string")return lb(e,r);throw new Error(lr(8))}function lb(e,t){return e==="button"?(0,Ma.createElement)("button",{type:"button",...t,key:t.key}):e==="img"?(0,Ma.createElement)("img",{alt:"",...t,key:t.key}):Ao.createElement(e,t)}var Ii=f(ve(),1);var sf=0;function cb(e,t="mui"){let[r,o]=Ii.useState(e),n=e||r;return Ii.useEffect(()=>{r==null&&(sf+=1,o(`${t}-${sf}`))},[r,t]),n}var af=Gn.useId;function on(e,t){if(af!==void 0){let r=af();return e??(t?`${t}-${r}`:r)}return cb(e,t)}function lf(e){return on(e,"base-ui")}var Oe={};so(Oe,{cancelOpen:()=>Vb,chipRemovePress:()=>bb,clearPress:()=>vb,closePress:()=>gb,closeWatcher:()=>kb,decrementPress:()=>Sb,disabled:()=>Bb,drag:()=>Lb,escapeKey:()=>Ob,focusOut:()=>Pb,imperativeAction:()=>Hb,incrementPress:()=>xb,initial:()=>zb,inputBlur:()=>Rb,inputChange:()=>_b,inputClear:()=>Cb,inputPaste:()=>Eb,inputPress:()=>Tb,itemPress:()=>hb,keyboard:()=>Ab,linkPress:()=>yb,listNavigation:()=>Fb,missing:()=>jb,none:()=>ub,outsidePress:()=>mb,pointer:()=>Ib,scrub:()=>Mb,siblingOpen:()=>Db,swipe:()=>Ub,trackPress:()=>wb,triggerFocus:()=>pb,triggerHover:()=>db,triggerPress:()=>fb,wheel:()=>Nb,windowResize:()=>Wb});var ub="none",fb="trigger-press",db="trigger-hover",pb="trigger-focus",mb="outside-press",hb="item-press",gb="close-press",yb="link-press",vb="clear-press",bb="chip-remove-press",wb="track-press",xb="increment-press",Sb="decrement-press",_b="input-change",Cb="input-clear",Rb="input-blur",Eb="input-paste",Tb="input-press",Pb="focus-out",Ob="escape-key",kb="close-watcher",Fb="list-navigation",Ab="keyboard",Ib="pointer",Lb="drag",Nb="wheel",Mb="scrub",Vb="cancel-open",Db="sibling-open",Bb="disabled",jb="missing",zb="initial",Hb="imperative-action",Ub="swipe",Wb="window-resize";function Ve(e,t,r,o){let n=!1,i=!1,s=o??nt;return{reason:e,event:t??new Event("base-ui"),cancel(){n=!0},allowPropagation(){i=!0},get isCanceled(){return n},get isPropagationAllowed(){return i},trigger:r,...s}}var Da=f(ve(),1);var cf=f(ve(),1);function nn(e){cf.useEffect(e,Xu)}var Li=null,_T=globalThis.requestAnimationFrame,Va=class{callbacks=[];callbacksCount=0;nextId=1;startId=1;isScheduled=!1;tick=t=>{this.isScheduled=!1;let r=this.callbacks,o=this.callbacksCount;if(this.callbacks=[],this.callbacksCount=0,this.startId=this.nextId,o>0)for(let n=0;n=this.callbacks.length||(this.callbacks[r]=null,this.callbacksCount-=1)}},Ni=new Va;var Fr=class e{static create(){return new e}static request(t){return Ni.request(t)}static cancel(t){return Ni.cancel(t)}currentId=Li;request(t){this.cancel(),this.currentId=Ni.request(()=>{this.currentId=Li,t()})}cancel=()=>{this.currentId!==Li&&(Ni.cancel(this.currentId),this.currentId=Li)};disposeEffect=()=>this.cancel};function sn(){let e=_t(Fr.create).current;return nn(e.disposeEffect),e}function uf(e,t=!1,r=!1){let[o,n]=Da.useState(e&&t?"idle":void 0),[i,s]=Da.useState(e);return e&&!i&&(s(!0),n("starting")),!e&&i&&o!=="ending"&&!r&&n("ending"),!e&&!i&&o==="ending"&&n(void 0),we(()=>{if(!e&&i&&o!=="ending"&&r){let a=Fr.request(()=>{n("ending")});return()=>{Fr.cancel(a)}}},[e,i,o,r]),we(()=>{if(!e||t)return;let a=Fr.request(()=>{n(void 0)});return()=>{Fr.cancel(a)}},[t,e]),we(()=>{if(!e||!t)return;e&&i&&o!=="idle"&&n("starting");let a=Fr.request(()=>{n("idle")});return()=>{Fr.cancel(a)}},[t,e,i,o]),{mounted:i,setMounted:s,transitionStatus:o}}var Ba=(function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e})({}),Gb={"data-starting-style":""},Yb={"data-ending-style":""},ff={transitionStatus(e){return e==="starting"?Gb:e==="ending"?Yb:null}};function Mi(){return typeof window<"u"}function Lo(e){return Vi(e)?(e.nodeName||"").toLowerCase():"#document"}function it(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Ir(e){var t;return(t=(Vi(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Vi(e){return Mi()?e instanceof Node||e instanceof it(e).Node:!1}function Re(e){return Mi()?e instanceof Element||e instanceof it(e).Element:!1}function Ct(e){return Mi()?e instanceof HTMLElement||e instanceof it(e).HTMLElement:!1}function an(e){return!Mi()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof it(e).ShadowRoot}function Zn(e){let{overflow:t,overflowX:r,overflowY:o,display:n}=Lt(e);return/auto|scroll|overlay|hidden|clip/.test(t+o+r)&&n!=="inline"&&n!=="contents"}function df(e){return/^(table|td|th)$/.test(Lo(e))}function Xn(e){try{if(e.matches(":popover-open"))return!0}catch{}try{return e.matches(":modal")}catch{return!1}}var qb=/transform|translate|scale|rotate|perspective|filter/,Zb=/paint|layout|strict|content/,Io=e=>!!e&&e!=="none",ja;function Di(e){let t=Re(e)?Lt(e):e;return Io(t.transform)||Io(t.translate)||Io(t.scale)||Io(t.rotate)||Io(t.perspective)||!Bi()&&(Io(t.backdropFilter)||Io(t.filter))||qb.test(t.willChange||"")||Zb.test(t.contain||"")}function pf(e){let t=Ar(e);for(;Ct(t)&&!Lr(t);){if(Di(t))return t;if(Xn(t))return null;t=Ar(t)}return null}function Bi(){return ja==null&&(ja=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),ja}function Lr(e){return/^(html|body|#document)$/.test(Lo(e))}function Lt(e){return it(e).getComputedStyle(e)}function Kn(e){return Re(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ar(e){if(Lo(e)==="html")return e;let t=e.assignedSlot||e.parentNode||an(e)&&e.host||Ir(e);return an(t)?t.host:t}function mf(e){let t=Ar(e);return Lr(t)?(e.ownerDocument||e).body:Ct(t)&&Zn(t)?t:mf(t)}function ao(e,t,r){var o;t===void 0&&(t=[]),r===void 0&&(r=!0);let n=mf(e),i=n===((o=e.ownerDocument)==null?void 0:o.body),s=it(n);if(i){let a=ji(s);return t.concat(s,s.visualViewport||[],Zn(n)?n:[],a&&r?ao(a):[])}else return t.concat(n,ao(n,[],r))}function ji(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Rt(e){return e?.ownerDocument||document}function ze(e,t,r,o){return e.addEventListener(t,r,o),()=>{e.removeEventListener(t,r,o)}}function Yt(e){let t=_t(Xb,e).current;return t.next=e,we(t.effect),t}function Xb(e){let t={current:e,next:e,effect:()=>{t.current=t.next}};return t}var vf=f(ve(),1);var yf=f(lo(),1);function gf(e){return e==null?e:"current"in e?e.current:e}function ln(e,t=!1){let r=sn();return Pe((o,n=null)=>{r.cancel();let i=gf(e);if(i==null)return;let s=i,a=()=>{yf.flushSync(o)};if(typeof s.getAnimations!="function"||globalThis.BASE_UI_ANIMATIONS_DISABLED){o();return}function u(){Promise.all(s.getAnimations().map(l=>l.finished)).then(()=>{n?.aborted||a()},()=>{if(n?.aborted)return;if(s.getAnimations().some(c=>c.pending||c.playState!=="finished")){u();return}a()})}if(t){let l="data-starting-style";if(!s.hasAttribute(l)){r.request(u);return}let c=new MutationObserver(()=>{s.hasAttribute(l)||(c.disconnect(),u())});c.observe(s,{attributes:!0,attributeFilter:[l]}),n?.addEventListener("abort",()=>c.disconnect(),{once:!0});return}r.request(u)})}function zi(e){let{enabled:t=!0,open:r,ref:o,onComplete:n}=e,i=Pe(n),s=ln(o,r);vf.useEffect(()=>{if(!t)return;let a=new AbortController;return s(i,a.signal),()=>{a.abort()}},[t,r,i,s])}var Zr={};so(Zr,{engine:()=>Ga,env:()=>qa,os:()=>Ua,screenReader:()=>Ya});var Ua={};so(Ua,{android:()=>xf,apple:()=>Ha,ios:()=>za,linux:()=>e0,mac:()=>Sf,windows:()=>$b});function Kb(){return typeof navigator>"u"?{userAgent:"",platform:"",maxTouchPoints:0}:{userAgent:navigator.userAgent,platform:navigator.platform??"",maxTouchPoints:navigator.maxTouchPoints??0}}var{userAgent:Jb,platform:Qb,maxTouchPoints:bf}=Kb(),No=Jb.toLowerCase(),Mo=Qb.toLowerCase();var za=/^i(os$|p)/.test(Mo)||Mo==="macintel"&&bf>1,wf="android",xf=Mo===wf||No.includes(wf),Sf=!za&&Mo.startsWith("mac"),$b=Mo.startsWith("win"),e0=!xf&&/^(linux|chrome os)/.test(Mo),Ha=Sf||za;var Ga={};so(Ga,{blink:()=>r0,gecko:()=>t0,webkit:()=>Wa});var Wa=typeof CSS<"u"&&!!CSS.supports?.("-webkit-backdrop-filter:none"),t0=!Wa&&No.includes("firefox"),r0=!Wa&&No.includes("chrom");var Ya={};so(Ya,{voiceOver:()=>o0});var o0=Ha;var qa={};so(qa,{jsdom:()=>n0});var n0=/jsdom|happydom/.test(No);var Jn=0,rr=class e{static create(){return new e}currentId=Jn;start(t,r){this.clear(),this.currentId=setTimeout(()=>{this.currentId=Jn,r()},t)}isStarted(){return this.currentId!==Jn}clear=()=>{this.currentId!==Jn&&(clearTimeout(this.currentId),this.currentId=Jn)};disposeEffect=()=>this.clear};function wr(){let e=_t(rr.create).current;return nn(e.disposeEffect),e}var Mt=f(ve(),1);function _f(e){return"nativeEvent"in e}function Xr(e,t){let r=["mouse","pen"];return t||r.push("",void 0),r.includes(e)}function Cf(e){let t=e.type;return t==="click"||t==="mousedown"||t==="keydown"||t==="keyup"}var Za="data-base-ui-focusable";var Xa="input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";function Hi(e){let t=e.activeElement;for(;t?.shadowRoot?.activeElement!=null;)t=t.shadowRoot.activeElement;return t}function Ge(e,t){if(!e||!t)return!1;let r=t.getRootNode?.();if(e.contains(t))return!0;if(r&&an(r)){let o=t;for(;o;){if(e===o)return!0;o=o.parentNode||o.host}}return!1}function Nt(e){return"composedPath"in e?e.composedPath()[0]:e.target}function co(e,t){if(!Re(e))return!1;let r=e;if(t.hasElement(r))return!r.hasAttribute("data-trigger-disabled");for(let[,o]of t.entries())if(Ge(o,r))return!o.hasAttribute("data-trigger-disabled");return!1}function Ui(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);let r=e;return r.target!=null&&t.contains(r.target)}function Rf(e){return e.matches("html,body")}function Ef(e){return Ct(e)&&e.matches(Xa)}function Ka(e){return e?.closest(`button,a[href],[role="button"],select,[tabindex]:not([tabindex="-1"]),${Xa}`)!=null}function Tf(e){if(!e||Zr.env.jsdom)return!0;try{return e.matches(":focus-visible")}catch{return!0}}function i0(e,t){return t!=null&&!Xr(t)?0:typeof e=="function"?e():e}function cr(e,t,r){let o=i0(e,r);return typeof o=="number"?o:o?.[t]}function Ja(e){return typeof e=="function"?e():e}function Wi(e,t){return t||e==="click"||e==="mousedown"}function Pf(e){return e?.includes("mouse")&&e!=="mousedown"}var Of=f(Z(),1),kf=Mt.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeout:new rr,currentIdRef:{current:null},currentContextRef:{current:null}});function s0(e,t){e.current=t.current}function Qa(e){let{children:t,delay:r,timeoutMs:o=0}=e,n=Mt.useRef(r),i=Mt.useRef(r),s=Mt.useRef(null),a=Mt.useRef(null),u=wr();return we(()=>{if(i.current=r,!s.current){n.current=r;return}n.current={open:cr(n.current,"open"),close:cr(r,"close")}},[r,s,n,i]),(0,Of.jsx)(kf.Provider,{value:Mt.useMemo(()=>({hasProvider:!0,delayRef:n,initialDelayRef:i,currentIdRef:s,timeoutMs:o,currentContextRef:a,timeout:u}),[o,u]),children:t})}function $a(e,t={open:!1}){let{open:r}=t,o="rootStore"in e?e.rootStore:e,n=o.useState("floatingId"),i=Mt.useContext(kf),{currentIdRef:s,delayRef:a,timeoutMs:u,initialDelayRef:l,currentContextRef:c,hasProvider:m,timeout:d}=i,[h,g]=Mt.useState(!1),b=Mt.useRef(r);return we(()=>{b.current=r},[r]),we(()=>{function w(){c.current?.setIsInstantPhase(!1),s.current=null,c.current=null,a.current=l.current,d.clear()}if(s.current&&!r&&s.current===n){if(g(!1),u){let _=n;return d.start(u,()=>{o.select("open")||s.current&&s.current!==_||w()}),()=>{(b.current||s.current!==_)&&d.clear()}}w()}},[r,n,s,a,u,l,c,d,o]),we(()=>{if(!r)return;let w=c.current,_=s.current;d.clear(),c.current={onOpenChange:o.setOpen,setIsInstantPhase:g},s.current=n,a.current={open:0,close:cr(l.current,"close")},_!==null&&_!==n?(g(!0),w?.setIsInstantPhase(!0),w?.onOpenChange(!1,Ve(Oe.none))):(g(!1),w?.setIsInstantPhase(!1))},[r,n,o,s,a,l,c,d]),we(()=>()=>{if(s.current===n){if(c.current=null,!b.current)return;s.current=null,s0(a,l),d.clear()}},[c,s,a,n,l,d]),Mt.useMemo(()=>({hasProvider:m,delayRef:a,isInstantPhase:h}),[m,a,h])}function xr(...e){return()=>{for(let t=0;t({x:e,y:e}),a0={left:"right",right:"left",bottom:"top",top:"bottom"};function Yi(e,t,r){return Sr(e,uo(t,r))}function Mr(e,t){return typeof e=="function"?e(t):e}function Tt(e){return e.split("-")[0]}function _r(e){return e.split("-")[1]}function qi(e){return e==="x"?"y":"x"}function ei(e){return e==="y"?"height":"width"}function qt(e){let t=e[0];return t==="t"||t==="b"?"y":"x"}function ti(e){return qi(qt(e))}function If(e,t,r){r===void 0&&(r=!1);let o=_r(e),n=ti(e),i=ei(n),s=n==="x"?o===(r?"end":"start")?"right":"left":o==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(s=Qn(s)),[s,Qn(s)]}function Lf(e){let t=Qn(e);return[Gi(e),t,Gi(t)]}function Gi(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}var Ff=["left","right"],Af=["right","left"],l0=["top","bottom"],c0=["bottom","top"];function u0(e,t,r){switch(e){case"top":case"bottom":return r?t?Af:Ff:t?Ff:Af;case"left":case"right":return t?l0:c0;default:return[]}}function Nf(e,t,r,o){let n=_r(e),i=u0(Tt(e),r==="start",o);return n&&(i=i.map(s=>s+"-"+n),t&&(i=i.concat(i.map(Gi)))),i}function Qn(e){let t=Tt(e);return a0[t]+e.slice(t.length)}function f0(e){var t,r,o,n;return{top:(t=e.top)!=null?t:0,right:(r=e.right)!=null?r:0,bottom:(o=e.bottom)!=null?o:0,left:(n=e.left)!=null?n:0}}function Zi(e){return typeof e!="number"?f0(e):{top:e,right:e,bottom:e,left:e}}function Vo(e){let{x:t,y:r,width:o,height:n}=e;return{width:o,height:n,top:r,left:t,right:t+o,bottom:r+n,x:t,y:r}}function Kr(e,t,r=!0){return e.filter(n=>n.parentId===t).flatMap(n=>[...!r||n.context?.open?[n]:[],...Kr(e,n.id,r)])}function cn(e){return`data-base-ui-${e}`}var Vt=f(ve(),1),Df=f(lo(),1);var Mf={style:{transition:"none"}};var d0="data-base-ui-swipe-ignore",p0="data-swipe-ignore",SP=`[${d0}]`,_P=`[${p0}]`;var Vf={fallbackAxisSide:"end"};var Bf=f(Z(),1),m0=Vt.createContext(null),h0=()=>Vt.useContext(m0),g0=cn("portal");function jf(e={}){let{ref:t,container:r,componentProps:o=nt,elementProps:n}=e,i=on(),a=h0()?.portalNode,[u,l]=Vt.useState(null),[c,m]=Vt.useState(null),d=Pe(w=>{w!==null&&m(w)}),h=Vt.useRef(null);we(()=>{if(r===null){h.current&&(h.current=null,m(null),l(null));return}let w=(r&&(Vi(r)?r:r.current))??a??document.body;if(w==null){h.current&&(h.current=null,m(null),l(null));return}h.current!==w&&(h.current=w,m(null),l(w))},[r,a]);let g=Gt("div",o,{ref:[t,d],props:[{id:i,[g0]:""},n]}),b=u&&g?Df.createPortal(g,u):null;return{node:c,nodeId:Vt.isValidElement(g)?g.props.id:void 0,subtree:b}}var Do=f(ve(),1);function zf(){let e=new Map;return{emit(t,r){e.get(t)?.forEach(o=>o(r))},on(t,r){e.has(t)||e.set(t,new Set),e.get(t).add(r)},off(t,r){e.get(t)?.delete(r)}}}var y0=f(Z(),1),v0=Do.createContext(null),b0=Do.createContext(null),Xi=()=>Do.useContext(v0)?.id||null,po=e=>{let t=Do.useContext(b0);return e??t};var Zt=f(ve(),1);function w0(e,t){let r=null,o=null,n=!1;return{contextElement:e||void 0,getBoundingClientRect(){let i=e?.getBoundingClientRect()||{width:0,height:0,x:0,y:0},s=t.axis==="x"||t.axis==="both",a=t.axis==="y"||t.axis==="both",u=["mouseenter","mousemove"].includes(t.dataRef.current.openEvent?.type||"")&&t.pointerType!=="touch",l=i.width,c=i.height,m=i.x,d=i.y;return r==null&&t.x&&s&&(r=i.x-t.x),o==null&&t.y&&a&&(o=i.y-t.y),m-=r||0,d-=o||0,l=0,c=0,!n||u?(l=t.axis==="y"?i.width:0,c=t.axis==="x"?i.height:0,m=s&&t.x!=null?t.x:m,d=a&&t.y!=null?t.y:d):n&&!u&&(c=t.axis==="x"?i.height:c,l=t.axis==="y"?i.width:l),n=!0,{width:l,height:c,x:m,y:d,top:d,right:m+l,bottom:d+c,left:m}}}}function Hf(e){return e!=null&&e.clientX!=null}function el(e,t={}){let{enabled:r=!0,axis:o="both"}=t,n="rootStore"in e?e.rootStore:e,i=n.useState("open"),s=n.useState("floatingElement"),a=n.useState("domReferenceElement"),u=n.context.dataRef,l=Zt.useRef(!1),c=Zt.useRef(null),[m,d]=Zt.useState(),[h,g]=Zt.useState([]),b=Pe(C=>{n.set("positionReference",C)}),w=Pe((C,k,E)=>{l.current||u.current.openEvent&&!Hf(u.current.openEvent)||n.set("positionReference",w0(E??a,{x:C,y:k,axis:o,dataRef:u,pointerType:m}))}),_=Pe(C=>{i?c.current||(w(C.clientX,C.clientY,C.currentTarget),g([])):w(C.clientX,C.clientY,C.currentTarget)}),x=Xr(m)?s:i;Zt.useEffect(()=>{if(!r){b(a);return}if(!x)return;function C(){c.current?.(),c.current=null}let k=it(s);function E(T){let O=Nt(T);Ge(s,O)?C():w(T.clientX,T.clientY)}return!u.current.openEvent||Hf(u.current.openEvent)?c.current=ze(k,"mousemove",E):b(a),C},[x,r,s,u,a,n,w,b,h]),Zt.useEffect(()=>()=>{n.set("positionReference",null)},[n]),Zt.useEffect(()=>{r&&!s&&(l.current=!1)},[r,s]),Zt.useEffect(()=>{!r&&i&&(l.current=!0)},[r,i]);let v=Zt.useMemo(()=>{function C(k){d(k.pointerType)}return{onPointerDown:C,onPointerEnter:C,onMouseMove:_,onMouseEnter:_}},[_]);return Zt.useMemo(()=>r?{reference:v,trigger:v}:{},[r,v])}var or=f(ve(),1);function x0(){return!1}function S0(e){return{escapeKey:typeof e=="boolean"?e:e?.escapeKey??!1,outsidePress:typeof e=="boolean"?e:e?.outsidePress??!0}}function tl(e,t={}){let{enabled:r=!0,escapeKey:o=!0,outsidePress:n=!0,outsidePressEvent:i="sloppy",referencePress:s=x0,bubbles:a,externalTree:u}=t,l="rootStore"in e?e.rootStore:e,c=l.useState("open"),m=l.useState("floatingElement"),{dataRef:d}=l.context,h=po(u),g=Pe(typeof n=="function"?n:()=>!1),b=typeof n=="function"?g:n,w=b!==!1,_=Pe(()=>i),{escapeKey:x,outsidePress:v}=S0(a),C=or.useRef(!1),k=or.useRef(!1),E=or.useRef(!1),T=or.useRef(!1),O=or.useRef(""),I=or.useRef(null),J=wr(),D=wr(),S=Pe(()=>{D.clear(),d.current.insideReactTree=!1}),L=Pe(P=>{let W=d.current.floatingContext?.nodeId;return(h?Kr(h.nodesRef.current,W):[]).some(xe=>xe.context?.open&&!xe.context.dataRef.current[P])}),Y=Pe(P=>Ui(P,l.select("floatingElement"))||Ui(P,l.select("domReferenceElement"))),A=Pe(P=>{s()&&l.setOpen(!1,Ve(Oe.triggerPress,P.nativeEvent))}),N=Pe(P=>{if(!c||!r||!o||P.key!=="Escape"||T.current||!x&&L("__escapeKeyBubbles"))return;let W=_f(P)?P.nativeEvent:P,ne=Ve(Oe.escapeKey,W);l.setOpen(!1,ne),ne.isCanceled||P.preventDefault(),!x&&!ne.isPropagationAllowed&&P.stopPropagation()}),q=Pe(()=>{d.current.insideReactTree=!0,D.start(0,S)}),U=Pe(P=>{if(!c||!r||P.button!==0)return;let W=Nt(P.nativeEvent);Ge(l.select("floatingElement"),W)&&(C.current||(C.current=!0,k.current=!1))}),R=Pe(P=>{!c||!r||(P.defaultPrevented||P.nativeEvent.defaultPrevented)&&C.current&&(k.current=!0)});or.useEffect(()=>{if(!c||!r)return S;d.current.__escapeKeyBubbles=x,d.current.__outsidePressBubbles=v;let P=new rr,W=new rr;function ne(){P.clear(),T.current=!0}function xe(){P.start(Zr.engine.webkit?5:0,()=>{T.current=!1})}function se(){E.current=!0,W.start(0,()=>{E.current=!1})}function be(){C.current=!1,k.current=!1}function ye(){let V=O.current,te=V==="pen"||!V?"mouse":V,Ne=_(),He=typeof Ne=="function"?Ne():Ne;return typeof He=="string"?He:He[te]}function $(V){let te=ye();return te==="intentional"&&V.type!=="click"||te==="sloppy"&&V.type==="click"}function Ce(V){let te=d.current.floatingContext?.nodeId,Ne=h&&Kr(h.nodesRef.current,te).some(He=>Ui(V,He.context?.elements.floating));return Y(V)||Ne}function Fe(V){if($(V)){V.type!=="click"&&!Y(V)&&(W.clear(),E.current=!1),S();return}if(d.current.insideReactTree){S();return}let te=Nt(V),Ne=`[${cn("inert")}]`,He=Re(te)?te.getRootNode():null,ot=Array.from((an(He)?He:Rt(l.select("floatingElement"))).querySelectorAll(Ne)),Ze=l.context.triggerElements;if(te&&(Ze.hasElement(te)||Ze.hasMatchingElement(Ue=>Ge(Ue,te))))return;let Be=Re(te)?te:null;for(;Be&&!Lr(Be);){let Ue=Ar(Be);if(Lr(Ue)||!Re(Ue))break;Be=Ue}if(!(ot.length&&Re(te)&&!Rf(te)&&!Ge(te,l.select("floatingElement"))&&ot.every(Ue=>!Ge(Be,Ue)))){if(Ct(te)&&!("touches"in V)){let Ue=Lr(te),ct=Lt(te),Se=/auto|scroll/,Or=Ue||Se.test(ct.overflowX),$t=Ue||Se.test(ct.overflowY),Ye=Or&&te.clientWidth>0&&te.scrollWidth>te.clientWidth,Yr=$t&&te.clientHeight>0&&te.scrollHeight>te.clientHeight,St=ct.direction==="rtl",kt=Yr&&(St?V.offsetX<=te.offsetWidth-te.clientWidth:V.offsetX>te.clientWidth),vt=Ye&&V.offsetY>te.clientHeight;if(kt||vt)return}if(!Ce(V)){if(ye()==="intentional"&&E.current){W.clear(),E.current=!1;return}typeof b=="function"&&!b(V)||L("__outsidePressBubbles")||(l.setOpen(!1,Ve(Oe.outsidePress,V)),S())}}}function xt(V){ye()!=="sloppy"||V.pointerType==="touch"||!l.select("open")||!r||Y(V)||Fe(V)}function Le(V){if(ye()!=="sloppy"||!l.select("open")||!r||Y(V))return;let te=V.touches[0];te&&(I.current={startTime:Date.now(),startX:te.clientX,startY:te.clientY,dismissOnTouchEnd:!1,dismissOnMouseDown:!0},J.start(1e3,()=>{I.current&&(I.current.dismissOnTouchEnd=!1,I.current.dismissOnMouseDown=!1)}))}function X(V,te){let Ne=Nt(V);if(!Ne)return;let He=ze(Ne,V.type,()=>{te(V),He()})}function M(V){O.current="touch",X(V,Le)}function K(V){J.clear(),V.type==="pointerdown"&&(O.current=V.pointerType),!(V.type==="mousedown"&&I.current&&!I.current.dismissOnMouseDown)&&X(V,te=>{te.type==="pointerdown"?xt(te):Fe(te)})}function H(V){if(!C.current)return;let te=k.current;if(be(),ye()==="intentional"){if(V.type==="pointercancel"){te&&se();return}if(!Ce(V)){if(te){se();return}typeof b=="function"&&!b(V)||(W.clear(),E.current=!0,S())}}}function Q(V){if(ye()!=="sloppy"||!I.current||Y(V))return;let te=V.touches[0];if(!te)return;let Ne=Math.abs(te.clientX-I.current.startX),He=Math.abs(te.clientY-I.current.startY),ot=Math.sqrt(Ne*Ne+He*He);ot>5&&(I.current.dismissOnTouchEnd=!0),ot>10&&(Fe(V),J.clear(),I.current=null)}function pe(V){X(V,Q)}function le(V){ye()!=="sloppy"||!I.current||Y(V)||(I.current.dismissOnTouchEnd&&Fe(V),J.clear(),I.current=null)}function fe(V){X(V,le)}let me=Rt(m),he=xr(o&&xr(ze(me,"keydown",N),ze(me,"compositionstart",ne),ze(me,"compositionend",xe)),w&&xr(ze(me,"click",K,!0),ze(me,"pointerdown",K,!0),ze(me,"pointerup",H,!0),ze(me,"pointercancel",H,!0),ze(me,"mousedown",K,!0),ze(me,"mouseup",H,!0),ze(me,"touchstart",M,!0),ze(me,"touchmove",pe,!0),ze(me,"touchend",fe,!0)));return()=>{he(),P.clear(),W.clear(),be(),E.current=!1,S()}},[d,m,o,w,b,c,r,x,v,N,S,_,L,Y,h,l,J]);let B=or.useMemo(()=>({onKeyDown:N,onPointerDown:A,onClick:A}),[N,A]),re=or.useMemo(()=>({onKeyDown:N,onPointerDown:R,onMouseDown:R,onClickCapture:q,onMouseDownCapture(P){q(),U(P)},onPointerDownCapture(P){q(),U(P)},onMouseUpCapture:q,onTouchEndCapture:q,onTouchMoveCapture:q}),[N,q,U,R]);return or.useMemo(()=>r?{reference:B,floating:re,trigger:B}:{},[r,B,re])}var Pt=f(ve(),1);function Uf(e,t,r){let{reference:o,floating:n}=e,i=qt(t),s=ti(t),a=ei(s),u=Tt(t),l=i==="y",c=o.x+o.width/2-n.width/2,m=o.y+o.height/2-n.height/2,d=o[a]/2-n[a]/2,h;switch(u){case"top":h={x:c,y:o.y-n.height};break;case"bottom":h={x:c,y:o.y+o.height};break;case"right":h={x:o.x+o.width,y:m};break;case"left":h={x:o.x-n.width,y:m};break;default:h={x:o.x,y:o.y}}let g=_r(t);return g&&(h[s]+=d*(g==="end"?1:-1)*(r&&l?-1:1)),h}async function Wf(e,t){var r;t===void 0&&(t={});let{x:o,y:n,platform:i,rects:s,elements:a,strategy:u}=e,{boundary:l="clippingAncestors",rootBoundary:c="viewport",elementContext:m="floating",altBoundary:d=!1,padding:h=0}=Mr(t,e),g=Zi(h),w=a[d?m==="floating"?"reference":"floating":m],_=Vo(await i.getClippingRect({element:(r=await(i.isElement==null?void 0:i.isElement(w)))==null||r?w:w.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:l,rootBoundary:c,strategy:u})),x=m==="floating"?{x:o,y:n,width:s.floating.width,height:s.floating.height}:s.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),C=await(i.isElement==null?void 0:i.isElement(v))&&await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1},k=Vo(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:x,offsetParent:v,strategy:u}):x);return{top:(_.top-k.top+g.top)/C.y,bottom:(k.bottom-_.bottom+g.bottom)/C.y,left:(_.left-k.left+g.left)/C.x,right:(k.right-_.right+g.right)/C.x}}var _0=50,Gf=async(e,t,r)=>{let{placement:o="bottom",strategy:n="absolute",middleware:i=[],platform:s}=r,a=s.detectOverflow?s:{...s,detectOverflow:Wf},u=await(s.isRTL==null?void 0:s.isRTL(t)),l=await s.getElementRects({reference:e,floating:t,strategy:n}),{x:c,y:m}=Uf(l,o,u),d=o,h=0,g={};for(let b=0;bY<=0)){var D,S;let Y=(((D=i.flip)==null?void 0:D.index)||0)+1,A=T[Y];if(A&&(!(m==="alignment"?x!==qt(A):!1)||J.every(U=>qt(U.placement)===x?U.overflows[0]>0:!0)))return{data:{index:Y,overflows:J},reset:{placement:A}};let N=(S=J.filter(q=>q.overflows[0]<=0).sort((q,U)=>q.overflows[1]-U.overflows[1])[0])==null?void 0:S.placement;if(!N)switch(h){case"bestFit":{var L;let q=(L=J.filter(U=>{if(E){let R=qt(U.placement);return R===x||R==="y"}return!0}).map(U=>[U.placement,U.overflows.filter(R=>R>0).reduce((R,B)=>R+B,0)]).sort((U,R)=>U[1]-R[1])[0])==null?void 0:L[0];q&&(N=q);break}case"initialPlacement":N=a;break}if(n!==N)return{reset:{placement:N}}}return{}}}};var qf=new Set(["left","top"]);async function C0(e,t){let{placement:r,platform:o,elements:n}=e,i=await(o.isRTL==null?void 0:o.isRTL(n.floating)),s=Tt(r),a=_r(r),u=qt(r)==="y",l=qf.has(s)?-1:1,c=i&&u?-1:1,m=Mr(t,e),{mainAxis:d,crossAxis:h,alignmentAxis:g}=typeof m=="number"?{mainAxis:m,crossAxis:0,alignmentAxis:null}:{mainAxis:m.mainAxis||0,crossAxis:m.crossAxis||0,alignmentAxis:m.alignmentAxis};return a&&typeof g=="number"&&(h=a==="end"?g*-1:g),u?{x:h*c,y:d*l}:{x:d*l,y:h*c}}var Zf=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,o;let{x:n,y:i,placement:s,middlewareData:a}=t,u=await C0(t,e);return s===((r=a.offset)==null?void 0:r.placement)&&(o=a.arrow)!=null&&o.alignmentOffset?{}:{x:n+u.x,y:i+u.y,data:{...u,placement:s}}}}},Xf=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){let{x:r,y:o,placement:n,platform:i}=t,{mainAxis:s=!0,crossAxis:a=!1,limiter:u={fn:x=>{let{x:v,y:C}=x;return{x:v,y:C}}},...l}=Mr(e,t),c={x:r,y:o},m=await i.detectOverflow(t,l),d=qt(n),h=qi(d),g=c[h],b=c[d],w=(x,v)=>Yi(v+m[x==="y"?"top":"left"],v,v-m[x==="y"?"bottom":"right"]);s&&(g=w(h,g)),a&&(b=w(d,b));let _=u.fn({...t,[h]:g,[d]:b});return{..._,data:{x:_.x-r,y:_.y-o,enabled:{[h]:s,[d]:a}}}}}},Kf=function(e){return e===void 0&&(e={}),{options:e,fn(t){var r,o;let{x:n,y:i,placement:s,rects:a,middlewareData:u}=t,{offset:l=0,mainAxis:c=!0,crossAxis:m=!0}=Mr(e,t),d={x:n,y:i},h=qt(s),g=qi(h),b=d[g],w=d[h],_=Mr(l,t),x=typeof _=="number"?{mainAxis:_,crossAxis:0}:{mainAxis:(r=_.mainAxis)!=null?r:0,crossAxis:(o=_.crossAxis)!=null?o:0};if(c){let k=g==="y"?"height":"width",E=a.reference[g]-a.floating[k]+x.mainAxis,T=a.reference[g]+a.reference[k]-x.mainAxis;bT&&(b=T)}if(m){var v,C;let k=g==="y"?"width":"height",E=qf.has(Tt(s)),T=a.reference[h]-a.floating[k]+(E&&((v=u.offset)==null?void 0:v[h])||0)+(E?0:x.crossAxis),O=a.reference[h]+a.reference[k]+(E?0:((C=u.offset)==null?void 0:C[h])||0)-(E?x.crossAxis:0);wO&&(w=O)}return{[g]:b,[h]:w}}}},Jf=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){let{placement:r,rects:o,platform:n,elements:i}=t,{apply:s=()=>{},...a}=Mr(e,t),u=await n.detectOverflow(t,a),l=Tt(r),c=_r(r),m=qt(r)==="y",{width:d,height:h}=o.floating,g,b;l==="top"||l==="bottom"?(g=l,b=c===(await(n.isRTL==null?void 0:n.isRTL(i.floating))?"start":"end")?"left":"right"):(b=l,g=c==="end"?"top":"bottom");let w=h-u.top-u.bottom,_=d-u.left-u.right,x=uo(h-u[g],w),v=uo(d-u[b],_),C=t.middlewareData.shift,k=!C,E=x,T=v;C!=null&&C.enabled.x&&(T=_),C!=null&&C.enabled.y&&(E=w),k&&!c&&(m?T=d-2*Sr(u.left,u.right):E=h-2*Sr(u.top,u.bottom)),await s({...t,availableWidth:T,availableHeight:E});let O=await n.getDimensions(i.floating);return d!==O.width||h!==O.height?{reset:{rects:!0}}:{}}}};function ed(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=Ct(e),i=n?e.offsetWidth:r,s=n?e.offsetHeight:o,a=fo(r)!==i||fo(o)!==s;return a&&(r=i,o=s),{width:r,height:o,$:a}}function ol(e){return Re(e)?e:e.contextElement}function un(e){let t=ol(e);if(!Ct(t))return Nr(1);let r=t.getBoundingClientRect(),{width:o,height:n,$:i}=ed(t),s=(i?fo(r.width):r.width)/o,a=(i?fo(r.height):r.height)/n;return(!s||!Number.isFinite(s))&&(s=1),(!a||!Number.isFinite(a))&&(a=1),{x:s,y:a}}var R0=Nr(0);function td(e){let t=it(e);return!Bi()||!t.visualViewport?R0:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function E0(e,t,r){return t===void 0&&(t=!1),!!r&&t&&r===it(e)}function Bo(e,t,r,o){t===void 0&&(t=!1),r===void 0&&(r=!1);let n=e.getBoundingClientRect(),i=ol(e),s=Nr(1);t&&(o?Re(o)&&(s=un(o)):s=un(e));let a=E0(i,r,o)?td(i):Nr(0),u=(n.left+a.x)/s.x,l=(n.top+a.y)/s.y,c=n.width/s.x,m=n.height/s.y;if(i&&o){let d=it(i),h=Re(o)?it(o):o,g=d,b=ji(g);for(;b&&h!==g;){let w=un(b),_=b.getBoundingClientRect(),x=Lt(b),v=_.left+(b.clientLeft+parseFloat(x.paddingLeft))*w.x,C=_.top+(b.clientTop+parseFloat(x.paddingTop))*w.y;u*=w.x,l*=w.y,c*=w.x,m*=w.y,u+=v,l+=C,g=it(b),b=ji(g)}}return Vo({width:c,height:m,x:u,y:l})}function Ki(e,t){let r=Kn(e).scrollLeft;return t?t.left+r:Bo(Ir(e)).left+r}function rd(e,t){let r=e.getBoundingClientRect(),o=r.left+t.scrollLeft-Ki(e,r),n=r.top+t.scrollTop;return{x:o,y:n}}function T0(e){let{elements:t,rect:r,offsetParent:o,strategy:n}=e,i=n==="fixed",s=Ir(o),a=t?Xn(t.floating):!1;if(o===s||a&&i)return r;let u={scrollLeft:0,scrollTop:0},l=Nr(1),c=Nr(0),m=Ct(o);if((m||!i)&&((Lo(o)!=="body"||Zn(s))&&(u=Kn(o)),m)){let h=Bo(o);l=un(o),c.x=h.x+o.clientLeft,c.y=h.y+o.clientTop}let d=s&&!m&&!i?rd(s,u):Nr(0);return{width:r.width*l.x,height:r.height*l.y,x:r.x*l.x-u.scrollLeft*l.x+c.x+d.x,y:r.y*l.y-u.scrollTop*l.y+c.y+d.y}}function P0(e){return e.getClientRects?Array.from(e.getClientRects()):[]}function O0(e){let t=Kn(e),r=e.ownerDocument.body,o=Sr(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),n=Sr(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight),i=-t.scrollLeft+Ki(e),s=-t.scrollTop;return Lt(r).direction==="rtl"&&(i+=Sr(e.clientWidth,r.clientWidth)-o),{width:o,height:n,x:i,y:s}}var k0=25;function F0(e,t,r){r===void 0&&(r="viewport");let o=r==="layoutViewport",n=it(e),i=Ir(e),s=n.visualViewport,a=i.clientWidth,u=i.clientHeight,l=0,c=0;if(s){let d=!Bi()||t==="fixed";o?d||(l=-s.offsetLeft,c=-s.offsetTop):(a=s.width,u=s.height,d&&(l=s.offsetLeft,c=s.offsetTop))}if(Ki(i)<=0){let d=i.ownerDocument,h=d.body,g=getComputedStyle(h),b=d.compatMode==="CSS1Compat"&&parseFloat(g.marginLeft)+parseFloat(g.marginRight)||0,w=Math.abs(i.clientWidth-h.clientWidth-b),_=getComputedStyle(i).scrollbarGutter==="stable both-edges"?w/2:w;_<=k0&&(a-=_)}return{width:a,height:u,x:l,y:c}}function A0(e,t){let r=Bo(e,!0,t==="fixed"),o=r.top+e.clientTop,n=r.left+e.clientLeft,i=un(e),s=e.clientWidth*i.x,a=e.clientHeight*i.y,u=n*i.x,l=o*i.y;return{width:s,height:a,x:u,y:l}}function Qf(e,t,r){let o;if(t==="viewport"||t==="layoutViewport")o=F0(e,r,t);else if(t==="document")o=O0(Ir(e));else if(Re(t))o=A0(t,r);else{let n=td(e);o={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return Vo(o)}function I0(e,t){let r=t.get(e);if(r)return r;let o=ao(e,[],!1).filter(a=>Re(a)&&Lo(a)!=="body"),n=null,i=Lt(e).position==="fixed",s=i?Ar(e):e;for(;Re(s)&&!Lr(s);){let a=Lt(s),u=Di(s),l=n?n.position:i?"fixed":"";!u&&(l==="fixed"||l==="absolute"&&a.position==="static")?o=o.filter(m=>m!==s):n=a,s=Ar(s)}return t.set(e,o),o}function L0(e){let{element:t,boundary:r,rootBoundary:o,strategy:n}=e,s=[...r==="clippingAncestors"?Xn(t)?[]:I0(t,this._c):[].concat(r),o],a=Qf(t,s[0],n),u=a.top,l=a.right,c=a.bottom,m=a.left;for(let d=1;d{a(!1,1e-7)},1e3)}T=!1}try{o=new IntersectionObserver(O,{...E,root:i.ownerDocument})}catch{o=new IntersectionObserver(O,E)}o.observe(e)}let u=it(e),l=()=>a(r);return u.addEventListener("resize",l),a(!0),()=>{u.removeEventListener("resize",l),s()}}function ri(e,t,r,o){o===void 0&&(o={});let{ancestorScroll:n=!0,ancestorResize:i=!0,elementResize:s=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:u=!1}=o,l=ol(e),c=n||i?[...l?ao(l):[],...t?ao(t):[]]:[];c.forEach(_=>{n&&_.addEventListener("scroll",r),i&&_.addEventListener("resize",r)});let m=l&&a?B0(l,r,i):null,d=-1,h=null;s&&(h=new ResizeObserver(_=>{let[x]=_;x&&x.target===l&&h&&t&&(h.unobserve(t),cancelAnimationFrame(d),d=requestAnimationFrame(()=>{var v;(v=h)==null||v.observe(t)})),r()}),l&&!u&&h.observe(l),t&&h.observe(t));let g,b=u?Bo(e):null;u&&w();function w(){let _=Bo(e);b&&!nd(b,_)&&r(),b=_,g=requestAnimationFrame(w)}return r(),()=>{var _;c.forEach(x=>{n&&x.removeEventListener("scroll",r),i&&x.removeEventListener("resize",r)}),m?.(),(_=h)==null||_.disconnect(),h=null,u&&cancelAnimationFrame(g)}}var id=Zf;var sd=Xf,ad=Yf,ld=Jf;var cd=Kf,Ji=(e,t,r)=>{let o=new Map,n=r??{},i={...nl,...n.platform,_c:o};return Gf(e,t,{...n,platform:i})};var mt=f(ve(),1),fd=f(ve(),1),dd=f(lo(),1),z0=typeof document<"u",H0=function(){},Qi=z0?fd.useLayoutEffect:H0;function $i(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,o,n;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(o=r;o--!==0;)if(!$i(e[o],t[o]))return!1;return!0}if(n=Object.keys(e),r=n.length,r!==Object.keys(t).length)return!1;for(o=r;o--!==0;)if(!{}.hasOwnProperty.call(t,n[o]))return!1;for(o=r;o--!==0;){let i=n[o];if(!(i==="_owner"&&e.$$typeof)&&!$i(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function pd(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function ud(e,t){let r=pd(e);return Math.round(t*r)/r}function il(e){let t=mt.useRef(e);return Qi(()=>{t.current=e}),t}function md(e){e===void 0&&(e={});let{placement:t="bottom",strategy:r="absolute",middleware:o=[],platform:n,elements:{reference:i,floating:s}={},transform:a=!0,whileElementsMounted:u,open:l}=e,[c,m]=mt.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[d,h]=mt.useState(o);$i(d,o)||h(o);let[g,b]=mt.useState(null),[w,_]=mt.useState(null),x=mt.useCallback(U=>{U!==E.current&&(E.current=U,b(U))},[]),v=mt.useCallback(U=>{U!==T.current&&(T.current=U,_(U))},[]),C=i||g,k=s||w,E=mt.useRef(null),T=mt.useRef(null),O=mt.useRef(c),I=u!=null,J=il(u),D=il(n),S=il(l),L=mt.useCallback(()=>{if(!E.current||!T.current)return;let U={placement:t,strategy:r,middleware:d};D.current&&(U.platform=D.current),Ji(E.current,T.current,U).then(R=>{let B={...R,isPositioned:S.current!==!1};Y.current&&!$i(O.current,B)&&(O.current=B,dd.flushSync(()=>{m(B)}))})},[d,t,r,D,S]);Qi(()=>{l===!1&&O.current.isPositioned&&(O.current.isPositioned=!1,m(U=>({...U,isPositioned:!1})))},[l]);let Y=mt.useRef(!1);Qi(()=>(Y.current=!0,()=>{Y.current=!1}),[]),Qi(()=>{if(C&&(E.current=C),k&&(T.current=k),C&&k){if(J.current)return J.current(C,k,L);L()}},[C,k,L,J,I]);let A=mt.useMemo(()=>({reference:E,floating:T,setReference:x,setFloating:v}),[x,v]),N=mt.useMemo(()=>({reference:C,floating:k}),[C,k]),q=mt.useMemo(()=>{let U={position:r,left:0,top:0};if(!N.floating)return U;let R=ud(N.floating,c.x),B=ud(N.floating,c.y);return a?{...U,transform:"translate("+R+"px, "+B+"px)",...pd(N.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:R,top:B}},[r,a,N.floating,c.x,c.y]);return mt.useMemo(()=>({...c,update:L,refs:A,elements:N,floatingStyles:q}),[c,L,A,N,q])}var sl=(e,t)=>{let r=id(e);return{name:r.name,fn:r.fn,options:[e,t]}},al=(e,t)=>{let r=sd(e);return{name:r.name,fn:r.fn,options:[e,t]}},ll=(e,t)=>({fn:cd(e).fn,options:[e,t]}),cl=(e,t)=>{let r=ad(e);return{name:r.name,fn:r.fn,options:[e,t]}},ul=(e,t)=>{let r=ld(e);return{name:r.name,fn:r.fn,options:[e,t]}};var es=class{attachedStores=[];attachedStoreValue=null;storeListeners=new Set;constructor(t,r,o=!0){this.fallbackStore=t,this.componentName=r,this.throwOnMissingTrigger=o}get attachedStore(){return this.attachedStoreValue}get store(){return this.attachedStoreValue??this.fallbackStore}get serverStore(){return this.fallbackStore}subscribeStore(t){return this.storeListeners.add(t),()=>{this.storeListeners.delete(t)}}attachStore(t){return this.attachedStores.push(t),this.setActiveStore(t),()=>{let r=this.attachedStores.lastIndexOf(t);r!==-1&&this.attachedStores.splice(r,1),this.setActiveStore(this.attachedStores[this.attachedStores.length-1]??null)}}setActiveStore(t){this.attachedStoreValue!==t&&(this.attachedStoreValue=t,this.storeListeners.forEach(r=>{r()}))}openByTrigger(t){let r=this.attachedStore;if(r===null)return;let o;if(t){for(let n=this.attachedStores.length-1;n>=0&&!o;n-=1)o=this.attachedStores[n].context.triggerElements.getById(t);o??=this.fallbackStore.context.triggerElements.getById(t)}if(t&&!o&&this.throwOnMissingTrigger)throw new Error(lr(99,this.componentName,t,this.componentName));r.setOpen(!0,Ve(Oe.imperativeAction,void 0,o))}closePopup(){let t=this.attachedStore;t!==null&&t.setOpen(!1,Ve(Oe.imperativeAction))}};var zo=f(ve(),1),kd=f(lo(),1);var Pd=f(ve(),1);var Ed=f(ve(),1),hl=f(ts(),1),Td=f(xd(),1);var Sd=f(ve(),1);var dl=[],pl;function _d(){return pl}function Cd(e){dl.push(e)}function ml(e){let t=(r,o)=>{let n=_t(sw).current,i;try{pl=n;for(let s of dl)s.before(n);i=e(r,o);for(let s of dl)s.after(n);n.didInitialize=!0}finally{pl=void 0}return i};return t.displayName=e.displayName||e.name,t}function Rd(e){return Sd.forwardRef(ml(e))}function sw(){return{didInitialize:!1}}var aw=rn(19),lw=aw?uw:fw;function os(e,t,r,o,n){return lw(e,t,r,o,n)}function cw(e,t,r,o,n){let i=Ed.useCallback(()=>t(e.getSnapshot(),r,o,n),[e,t,r,o,n]);return(0,hl.useSyncExternalStore)(e.subscribe,i,i)}Cd({before(e){e.syncIndex=0,e.didInitialize||(e.syncTick=1,e.syncHooks=[],e.didChangeStore=!0,e.getSnapshot=()=>{let t=!1;for(let r=0;r0&&(e.didChangeStore&&(e.didChangeStore=!1,e.subscribe=t=>{let r=new Set;for(let n of e.syncHooks)r.add(n.store);let o=[];for(let n of r)o.push(n.subscribe(t));return()=>{for(let n of o)n()}}),(0,hl.useSyncExternalStore)(e.subscribe,e.getSnapshot,e.getSnapshot))}});function uw(e,t,r,o,n){let i=_d();if(!i)return cw(e,t,r,o,n);let s=i.syncIndex;i.syncIndex+=1;let a;return i.didInitialize?(a=i.syncHooks[s],(a.store!==e||a.selector!==t||!Object.is(a.a1,r)||!Object.is(a.a2,o)||!Object.is(a.a3,n))&&(a.store!==e&&(i.didChangeStore=!0),a.store=e,a.selector=t,a.a1=r,a.a2=o,a.a3=n,a.value=t(e.getSnapshot(),r,o,n))):(a={store:e,selector:t,a1:r,a2:o,a3:n,value:t(e.getSnapshot(),r,o,n)},i.syncHooks.push(a)),a.value}function fw(e,t,r,o,n){return(0,Td.useSyncExternalStoreWithSelector)(e.subscribe,e.getSnapshot,e.getSnapshot,i=>t(i,r,o,n))}var ns=class{constructor(t){this.state=t,this.listeners=new Set,this.updateTick=0}subscribe=t=>(this.listeners.add(t),()=>{this.listeners.delete(t)});getSnapshot=()=>this.state;setState(t){if(this.state===t)return;this.state=t,this.updateTick+=1;let r=this.updateTick;for(let o of this.listeners){if(r!==this.updateTick)return;o(t)}}update(t){for(let r in t)if(!Object.is(this.state[r],t[r])){this.setState({...this.state,...t});return}}set(t,r){Object.is(this.state[t],r)||this.setState({...this.state,[t]:r})}notifyAll(){let t={...this.state};this.setState(t)}use(t,r,o,n){return os(this,t,r,o,n)}};var jo=f(ve(),1);var mo=class extends ns{constructor(t,r={},o){super(t),this.context=r,this.selectors=o}useSyncedValue(t,r){jo.useDebugValue(t);let o=this;we(()=>{o.state[t]!==r&&o.set(t,r)},[o,t,r])}useSyncedValueWithCleanup(t,r){let o=this;we(()=>(o.state[t]!==r&&o.set(t,r),()=>{o.set(t,void 0)}),[o,t,r])}useSyncedValues(t){let r=this,o=Object.values(t);we(()=>{r.update(t)},[r,...o])}useControlledProp(t,r){jo.useDebugValue(t);let o=this,n=r!==void 0;we(()=>{n&&!Object.is(o.state[t],r)&&o.setState({...o.state,[t]:r})},[o,t,r,n])}select(t,r,o,n){let i=this.selectors[t];return i(this.state,r,o,n)}useState(t,r,o,n){return jo.useDebugValue(t),os(this,this.selectors[t],r,o,n)}useContextCallback(t,r){jo.useDebugValue(t);let o=Pe(r??tr);this.context[t]=o}useStateSetter(t){let r=jo.useRef(void 0);return r.current===void 0&&(r.current=o=>{this.set(t,o)}),r.current}observe(t,r){let o;typeof t=="function"?o=t:o=this.selectors[t];let n=o(this.state);return r(n,n,this),this.subscribe(i=>{let s=o(i);if(!Object.is(n,s)){let a=n;n=s,r(s,a,this)}})}};var dw={open:e=>e.open,transitionStatus:e=>e.transitionStatus,domReferenceElement:e=>e.domReferenceElement,referenceElement:e=>e.positionReference??e.referenceElement,floatingElement:e=>e.floatingElement,floatingId:e=>e.floatingId},ho=class extends mo{constructor(t){let{syncOnly:r,nested:o,onOpenChange:n,triggerElements:i,...s}=t;super({...s,positionReference:s.referenceElement,domReferenceElement:s.referenceElement},{onOpenChange:n,dataRef:{current:{}},events:zf(),nested:o,triggerElements:i},dw),this.syncOnly=r}syncOpenEvent=(t,r)=>{(!t||!this.state.open||r!=null&&Cf(r))&&(this.context.dataRef.current.openEvent=t?r:void 0)};dispatchOpenChange=(t,r)=>{this.syncOpenEvent(t,r.event);let o={open:t,reason:r.reason,nativeEvent:r.event,nested:this.context.nested,triggerElement:r.trigger};this.context.events.emit("openchange",o)};setOpen=(t,r)=>{if(this.syncOnly){this.context.onOpenChange?.(t,r);return}this.dispatchOpenChange(t,r),this.context.onOpenChange?.(t,r)}};function Od(e){let{popupStore:t,treatPopupAsFloatingElement:r=!1,floatingRootContext:o,floatingId:n,nested:i,onOpenChange:s}=e,a=t.useState("open"),u=t.useState("activeTriggerElement"),l=t.useState(r?"popupElement":"positionerElement"),c=t.context.triggerElements,m=s,d=Pd.useRef(null);o===void 0&&d.current===null&&(d.current=new ho({open:a,transitionStatus:void 0,referenceElement:u,floatingElement:l,triggerElements:c,onOpenChange:m,floatingId:n,syncOnly:!0,nested:i}));let h=o??d.current;return t.useSyncedValue("floatingId",n),we(()=>{let g={open:a,floatingId:n,referenceElement:u,floatingElement:l};Re(u)&&(g.domReferenceElement=u),h.state.positionReference===h.state.referenceElement&&(g.positionReference=u),h.update(g)},[a,n,u,l,h]),h.context.onOpenChange=m,h.context.nested=i,h}var Fd={tabIndex:-1,[Za]:""};function Ad(e,t=!1){let r=on(),o=Xi()!=null,n=_t(()=>e(r,o)).current;return Od({popupStore:n,treatPopupAsFloatingElement:t,floatingRootContext:n.state.floatingRootContext,floatingId:r,nested:o,onOpenChange:n.setOpen}),n}function Id({handle:e,store:t}){return we(()=>e.attachStore(t),[e,t]),null}function pw(e,t){let r=zo.useRef(null),o=zo.useRef(null);return zo.useCallback(n=>{if(e===void 0)return;let i=!1;if(r.current!==null){let s=r.current,a=o.current,u=t.context.triggerElements.getById(s);a&&u===a&&(t.context.triggerElements.delete(s),i=!0),r.current=null,o.current=null}if(n!==null&&(r.current=e,o.current=n,t.context.triggerElements.add(e,n),i=!0),i){let s=t.context.triggerElements.size;t.select("open")&&t.state.triggerCount!==s&&t.set("triggerCount",s)}},[t,e])}function mw(e,t,r,o=!1){t?e.preventUnmountingOnClose=!1:o&&(e.preventUnmountingOnClose=!0);let n=r?.id??null;(n||t)&&(e.activeTriggerId=n,e.activeTriggerElement=r??null)}function hw(e){let t=!1;return e.preventUnmountOnClose=()=>{t=!0},()=>t}function Ld(e,t,r,o={}){let n=r.reason,i=n===Oe.triggerHover,s=t&&n===Oe.triggerFocus,a=!t&&(n===Oe.triggerPress||n===Oe.escapeKey),u=hw(r);if(e.context.onOpenChange?.(t,r),r.isCanceled)return;o.onBeforeDispatch?.(),e.state.floatingRootContext.dispatchOpenChange(t,r);let l=()=>{let c={...o.extraState,open:t};s?c.instantType="focus":a?c.instantType="dismiss":i&&(c.instantType=void 0),mw(c,t,r.trigger,u()),e.update(c)};i?kd.flushSync(l):l()}function Nd(e,t,r,o){let n=r.useState("isMountedByTrigger",e),i=pw(e,r),s=Pe(u=>{let l=r.select("open"),c=r.select("activeTriggerId");if(c===e){r.update({activeTriggerElement:u,...l?o:null});return}c==null&&l&&r.update({activeTriggerId:e,activeTriggerElement:u,...o})}),a=zo.useCallback(u=>{i(u),u&&s(u)},[i,s]);return we(()=>{n&&r.update({activeTriggerElement:t.current,...o})},[n,r,t,...Object.values(o)]),{registerTrigger:a,isMountedByThisTrigger:n}}function Md(e,t={}){let{closeOnActiveTriggerUnmount:r=!1}=t,o=zo.useRef(null),n=e.useState("open"),i=e.useState("triggerCount"),s=e.useState("activeTriggerId"),a=e.useState("activeTriggerElement");we(()=>{if(!n){o.current=null,e.state.triggerCount!==0&&e.set("triggerCount",0);return}let u=e.context.triggerElements.size,l={};e.state.triggerCount!==u&&(l.triggerCount=u);let c=e.select("activeTriggerId"),m=null;if(c){let d=e.context.triggerElements.getById(c);if(d)o.current=c,d!==e.state.activeTriggerElement&&(l.activeTriggerElement=d);else{for(let[h,g]of e.context.triggerElements.entries())if(g===e.state.activeTriggerElement){l.activeTriggerId=h,l.activeTriggerElement=g,o.current=h;break}l.activeTriggerId===void 0&&(o.current===c?m=c:o.current=null)}}else o.current=null;if(!m&&!c&&u===1){let d=e.context.triggerElements.entries().next();if(!d.done){let[h,g]=d.value;l.activeTriggerId=h,l.activeTriggerElement=g,o.current=h}}(l.triggerCount!==void 0||l.activeTriggerId!==void 0||l.activeTriggerElement!==void 0)&&e.update(l),m&&r&&queueMicrotask(()=>{if(e.select("open")&&e.select("activeTriggerId")===m&&!e.context.triggerElements.getById(m)){let d=Ve(Oe.none);e.setOpen(!1,d),d.isCanceled||e.update({activeTriggerId:null,activeTriggerElement:null})}})},[n,e,i,s,a,r])}function Vd(e,t,r){let{mounted:o,setMounted:n,transitionStatus:i}=uf(e),s=t.useState("preventUnmountingOnClose"),a=e?!1:s;t.useSyncedValues({mounted:o,transitionStatus:i,preventUnmountingOnClose:a});let u=Pe(()=>{n(!1),t.update({activeTriggerId:null,activeTriggerElement:null,mounted:!1,preventUnmountingOnClose:!1}),r?.(),t.context.onOpenChangeComplete?.(!1)});return zi({enabled:o&&!e&&!a,open:e,ref:t.context.popupRef,onComplete(){e||u()}}),{forceUnmount:u,transitionStatus:i}}function Dd(e,t){e.useSyncedValues(t),we(()=>()=>{e.update({activeTriggerProps:nt,inactiveTriggerProps:nt,popupProps:nt})},[e])}var Ho=class{constructor(){this.idMap=new Map}add(t,r){this.idMap.set(t,r)}delete(t){this.idMap.delete(t)}hasElement(t){for(let r of this.idMap.values())if(r===t)return!0;return!1}hasMatchingElement(t){for(let r of this.idMap.values())if(t(r))return!0;return!1}getById(t){return this.idMap.get(t)}entries(){return this.idMap.entries()}elements(){return this.idMap.values()}get size(){return this.idMap.size}};function Bd(){return new ho({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:new Ho,floatingId:void 0,syncOnly:!1,nested:!1,onOpenChange:void 0})}function zd(){return{open:!1,openProp:void 0,mounted:!1,transitionStatus:void 0,floatingRootContext:Bd(),floatingId:void 0,triggerCount:0,preventUnmountingOnClose:!1,payload:void 0,activeTriggerId:null,activeTriggerElement:null,triggerIdProp:void 0,popupElement:null,positionerElement:null,activeTriggerProps:nt,inactiveTriggerProps:nt,popupProps:nt}}function Hd(e,t,r=!1){return new ho({open:!1,transitionStatus:void 0,floatingElement:null,referenceElement:null,triggerElements:e,floatingId:t,syncOnly:!0,nested:r,onOpenChange:void 0})}var oi=e=>e.triggerIdProp??e.activeTriggerId,gl=e=>e.openProp??e.open,jd=e=>(e.popupElement?.id??e.floatingId)||void 0;function Ud(e,t){return t!==void 0&&gl(e)&&oi(e)===t}function gw(e,t){return Ud(e,t)?!0:t!==void 0&&gl(e)&&oi(e)==null&&e.triggerCount===1}var Wd={open:gl,mounted:e=>e.mounted,transitionStatus:e=>e.transitionStatus,floatingRootContext:e=>e.floatingRootContext,triggerCount:e=>e.triggerCount,preventUnmountingOnClose:e=>e.preventUnmountingOnClose,payload:e=>e.payload,activeTriggerId:oi,activeTriggerElement:e=>e.mounted?e.activeTriggerElement:null,popupId:jd,isTriggerActive:(e,t)=>t!==void 0&&oi(e)===t,isOpenedByTrigger:(e,t)=>Ud(e,t),isMountedByTrigger:(e,t)=>t!==void 0&&oi(e)===t&&e.mounted,triggerProps:(e,t)=>t?e.activeTriggerProps:e.inactiveTriggerProps,triggerPopupId:(e,t)=>gw(e,t)?jd(e):void 0,popupProps:e=>e.popupProps,popupElement:e=>e.popupElement,positionerElement:e=>e.positionerElement};var yl=f(ve(),1),Gd=f(ts(),1);function Yd(e){let t=yl.useCallback(o=>e===void 0?tr:e.subscribeStore(o),[e]),r=yl.useCallback(()=>e===void 0?void 0:e.store,[e]);return(0,Gd.useSyncExternalStore)(t,r,()=>e?.serverStore)}function qd(e){return yw(e,e.rootContext)}function yw(e,t){let{nodeId:r,externalTree:o}=e,n=t.useState("referenceElement"),i=t.useState("floatingElement"),s=t.useState("domReferenceElement"),a=t.useState("open"),u=t.useState("floatingId"),[l,c]=Pt.useState(null),[m,d]=Pt.useState(void 0),[h,g]=Pt.useState(void 0),b=Pt.useRef(null),w=po(o),_=Pt.useMemo(()=>({reference:n,floating:i,domReference:s}),[n,i,s]),x=md({...e,elements:{..._,...l&&{reference:l}}}),v=Re(m)?m:null,C=h===void 0?t.state.floatingElement:h;t.useSyncedValue("referenceElement",m??null),t.useSyncedValue("domReferenceElement",m===void 0?s:v),t.useSyncedValue("floatingElement",C);let k=Pt.useCallback(D=>{let S=Re(D)?{getBoundingClientRect:()=>D.getBoundingClientRect(),getClientRects:()=>D.getClientRects(),contextElement:D}:D;c(S),x.refs.setReference(S)},[x.refs]),E=Pt.useCallback(D=>{(Re(D)||D===null)&&(b.current=D,d(D)),(Re(x.refs.reference.current)||x.refs.reference.current===null||D!==null&&!Re(D))&&x.refs.setReference(D)},[x.refs,d]),T=Pt.useCallback(D=>{g(D),x.refs.setFloating(D)},[x.refs]),O=Pt.useMemo(()=>({...x.refs,setReference:E,setFloating:T,setPositionReference:k,domReference:b}),[x.refs,E,T,k]),I=Pt.useMemo(()=>({...x.elements,domReference:s}),[x.elements,s]),J=Pt.useMemo(()=>({...x,dataRef:t.context.dataRef,open:a,onOpenChange:t.setOpen,events:t.context.events,floatingId:u,refs:O,elements:I,nodeId:r,rootStore:t}),[x,O,I,r,t,a,u]);return we(()=>{s&&(b.current=s)},[s]),we(()=>{t.context.dataRef.current.floatingContext=J;let D=w?.nodesRef.current.find(S=>S.id===r);D&&(D.context=J)}),Pt.useMemo(()=>({...x,context:J,refs:O,elements:I,rootStore:t}),[x,O,I,J,t])}var Vr=f(ve(),1);var vl=Zr.os.mac&&Zr.engine.webkit;function bl(e,t={}){let{enabled:r=!0,delay:o}=t,n="rootStore"in e?e.rootStore:e,{events:i,dataRef:s}=n.context,a=Vr.useRef(!1),u=Vr.useRef(null),l=Vr.useRef(!0),c=wr();Vr.useEffect(()=>{let d=n.select("domReferenceElement");if(!r)return;let h=it(d);function g(){let _=n.select("domReferenceElement");!n.select("open")&&Ct(_)&&_===Hi(Rt(_))&&(a.current=!0)}function b(){l.current=!0}function w(){l.current=!1}return xr(ze(h,"blur",g),vl&&ze(h,"keydown",b,!0),vl&&ze(h,"pointerdown",w,!0))},[n,r]),Vr.useEffect(()=>{if(!r)return;function d(h){if(h.reason===Oe.triggerPress||h.reason===Oe.escapeKey){let g=n.select("domReferenceElement");Re(g)&&(u.current=g,a.current=!0)}}return i.on("openchange",d),()=>{i.off("openchange",d)}},[i,r,n]);let m=Vr.useMemo(()=>{function d(){a.current=!1,u.current=null}return{onMouseLeave(){d()},onFocus(h){let g=h.currentTarget;if(a.current){if(u.current===g)return;d()}let b=Nt(h.nativeEvent);if(Re(b)){if(vl&&!h.relatedTarget){if(!l.current&&!Ef(b))return}else if(!Tf(b))return}let w=co(h.relatedTarget,n.context.triggerElements),{nativeEvent:_,currentTarget:x}=h,v=typeof o=="function"?o():o;if(n.select("open")&&w||v===0||v===void 0){n.setOpen(!0,Ve(Oe.triggerFocus,_,x));return}c.start(v,()=>{a.current||n.setOpen(!0,Ve(Oe.triggerFocus,_,x))})},onBlur(h){d();let g=h.relatedTarget,b=h.nativeEvent,w=Re(g)&&g.hasAttribute(cn("focus-guard"))&&g.getAttribute("data-type")==="outside";c.start(0,()=>{let _=n.select("domReferenceElement"),x=Hi(Rt(_));!g&&x===_||Ge(s.current.floatingContext?.refs.floating.current,x)||Ge(_,x)||w||co(g??x,n.context.triggerElements)||n.setOpen(!1,Ve(Oe.triggerFocus,b))})}}},[s,o,n,c]);return Vr.useMemo(()=>r?{reference:m,trigger:m}:{},[r,m])}var xl=f(ve(),1);var wl=class e{constructor(){this.pointerType=void 0,this.interactedInside=!1,this.handler=void 0,this.blockMouseMove=!0,this.performedPointerEventsMutation=!1,this.pointerEventsScopeElement=null,this.pointerEventsReferenceElement=null,this.pointerEventsFloatingElement=null,this.restTimeoutPending=!1,this.openChangeTimeout=new rr,this.restTimeout=new rr,this.handleCloseOptions=void 0}static create(){return new e}dispose=()=>{this.openChangeTimeout.clear(),this.restTimeout.clear()};disposeEffect=()=>this.dispose},is=new WeakMap;function dn(e){if(!e.performedPointerEventsMutation)return;let t=e.pointerEventsScopeElement;t&&is.get(t)===e&&(e.pointerEventsScopeElement?.style.removeProperty("pointer-events"),e.pointerEventsReferenceElement?.style.removeProperty("pointer-events"),e.pointerEventsFloatingElement?.style.removeProperty("pointer-events"),is.delete(t)),e.performedPointerEventsMutation=!1,e.pointerEventsScopeElement=null,e.pointerEventsReferenceElement=null,e.pointerEventsFloatingElement=null}function ss(e,t){let{scopeElement:r,referenceElement:o,floatingElement:n}=t,i=is.get(r);i&&i!==e&&dn(i),dn(e),e.performedPointerEventsMutation=!0,e.pointerEventsScopeElement=r,e.pointerEventsReferenceElement=o,e.pointerEventsFloatingElement=n,is.set(r,e),r.style.pointerEvents="none",o.style.pointerEvents="auto",n.style.pointerEvents="auto"}function pn(e){let t=e.context.dataRef.current,r=_t(()=>t.hoverInteractionState??wl.create()).current;return t.hoverInteractionState||(t.hoverInteractionState=r),nn(t.hoverInteractionState.disposeEffect),t.hoverInteractionState}function Sl(e,t={}){let{enabled:r=!0,closeDelay:o=0,nodeId:n}=t,i="rootStore"in e?e.rootStore:e,s=i.useState("open"),a=i.useState("floatingElement"),u=i.useState("domReferenceElement"),{dataRef:l}=i.context,c=po(),m=Xi(),d=pn(i),h=wr(),g=Pe(()=>Wi(l.current.openEvent?.type,d.interactedInside)),b=Pe(()=>Pf(l.current.openEvent?.type)),w=Pe(()=>{dn(d)});we(()=>{s||(d.pointerType=void 0,d.restTimeoutPending=!1,d.interactedInside=!1,w())},[s,d,w]),xl.useEffect(()=>w,[w]),we(()=>{if(r&&s&&d.handleCloseOptions?.blockPointerEvents&&b()&&Re(u)&&a){let _=u,x=a,v=Rt(a),C=c?.nodesRef.current.find(O=>O.id===m)?.context?.elements.floating;C&&(C.style.pointerEvents="");let k=d.pointerEventsScopeElement!==x?d.pointerEventsScopeElement:null,E=C!==x?C:null,T=d.handleCloseOptions?.getScope?.()??k??E??_.closest("[data-rootownerid]")??v.body;return ss(d,{scopeElement:T,referenceElement:_,floatingElement:x}),()=>{w()}}},[r,s,u,a,d,b,c,m,w]),xl.useEffect(()=>{if(!r)return;function _(){return!!(c&&m&&Kr(c.nodesRef.current,m).length>0)}function x(O){let I=cr(o,"close",d.pointerType),J=()=>{i.setOpen(!1,Ve(Oe.triggerHover,O)),c?.events.emit("floating.closed",O)};I?d.openChangeTimeout.start(I,J):(d.openChangeTimeout.clear(),J())}function v(O){let I=Nt(O);if(!Ka(I)){d.interactedInside=!1;return}d.interactedInside=I?.closest("[aria-haspopup]")!=null}function C(){d.openChangeTimeout.clear(),h.clear(),c?.events.off("floating.closed",E),w()}function k(O){if(_()&&c){c.events.on("floating.closed",E);return}if(co(O.relatedTarget,i.context.triggerElements))return;let I=l.current.floatingContext?.nodeId??n,J=O.relatedTarget;if(!(c&&I&&Re(J)&&Kr(c.nodesRef.current,I,!1).some(S=>Ge(S.context?.elements.floating,J)))){if(d.handler){d.handler(O);return}w(),b()&&!g()&&x(O)}}function E(O){!c||!m||_()||h.start(0,()=>{c.events.off("floating.closed",E),i.setOpen(!1,Ve(Oe.triggerHover,O)),c.events.emit("floating.closed",O)})}let T=a;return xr(T&&ze(T,"mouseenter",C),T&&ze(T,"mouseleave",k),T&&ze(T,"pointerdown",v,!0),()=>{c?.events.off("floating.closed",E)})},[r,a,i,l,o,n,b,g,w,d,c,m,h])}var go=f(ve(),1),Zd=f(lo(),1);var vw={current:null};function _l(e,t={}){let{enabled:r=!0,delay:o=0,handleClose:n=null,mouseOnly:i=!1,restMs:s=0,move:a=!0,triggerElementRef:u=vw,externalTree:l,isActiveTrigger:c=!0,getHandleCloseContext:m,isClosing:d,shouldOpen:h,guardStaleOpen:g=!1}=t,b="rootStore"in e?e.rootStore:e,{dataRef:w,events:_}=b.context,x=po(l),v=pn(b),C=go.useRef(!1),k=Yt(n),E=Yt(o),T=Yt(s),O=Yt(r),I=Yt(h),J=Yt(d),D=Pe(()=>Wi(w.current.openEvent?.type,v.interactedInside)),S=Pe(()=>I.current?.()!==!1),L=Pe((N,q,U)=>{let R=b.context.triggerElements;if(R.hasElement(q))return!N||!Ge(N,q);if(!Re(U))return!1;let B=U;return R.hasMatchingElement(re=>Ge(re,B))&&(!N||!Ge(N,B))}),Y=Pe(()=>{if(!v.handler)return;Rt(b.select("domReferenceElement")).removeEventListener("mousemove",v.handler),v.handler=void 0}),A=Pe(()=>{dn(v)});return c&&(v.handleCloseOptions=k.current?.__options),go.useEffect(()=>Y,[Y]),go.useEffect(()=>{if(!r)return;function N(q){q.open?C.current=!1:(C.current=q.reason===Oe.triggerHover,Y(),v.openChangeTimeout.clear(),v.restTimeout.clear(),v.blockMouseMove=!0,v.restTimeoutPending=!1)}return _.on("openchange",N),()=>{_.off("openchange",N)}},[r,_,v,Y]),go.useEffect(()=>{if(!r)return;function N(P,W=!0){let ne=cr(E.current,"close",v.pointerType);ne?v.openChangeTimeout.start(ne,()=>{b.setOpen(!1,Ve(Oe.triggerHover,P)),x?.events.emit("floating.closed",P)}):W&&(v.openChangeTimeout.clear(),b.setOpen(!1,Ve(Oe.triggerHover,P)),x?.events.emit("floating.closed",P))}let q=u.current??(c?b.select("domReferenceElement"):null);if(!Re(q))return;function U(P){if(v.openChangeTimeout.clear(),v.blockMouseMove=!1,i&&!Xr(v.pointerType))return;let W=Ja(T.current),ne=cr(E.current,"open",v.pointerType),xe=Nt(P),se=P.currentTarget??null,be=b.select("domReferenceElement"),ye=se;if(Re(xe)&&!b.context.triggerElements.hasElement(xe)){for(let H of b.context.triggerElements.elements())if(Ge(H,xe)){ye=H;break}}Re(se)&&Re(be)&&!b.context.triggerElements.hasElement(se)&&Ge(se,be)&&(ye=be);let $=ye==null?!1:L(be,ye,xe),Ce=b.select("open"),Fe=J.current?.()??b.select("transitionStatus")==="ending",xt=!Ce&&Fe&&C.current,Le=!$&&Re(ye)&&Re(be)&&Ge(be,ye)&&xt,X=W>0&&!ne,M=$&&(Ce||xt)||Le,K=!Ce||$;if(M){S()&&b.setOpen(!0,Ve(Oe.triggerHover,P,ye));return}X||(ne?v.openChangeTimeout.start(ne,()=>{K&&S()&&b.setOpen(!0,Ve(Oe.triggerHover,P,ye))}):K&&S()&&b.setOpen(!0,Ve(Oe.triggerHover,P,ye)))}function R(P){if(D()){A();return}Y();let W=b.select("domReferenceElement"),ne=Rt(W);v.restTimeout.clear(),v.restTimeoutPending=!1;let xe=w.current.floatingContext??m?.();if(co(P.relatedTarget,b.context.triggerElements))return;if(k.current&&xe){b.select("open")||v.openChangeTimeout.clear();let be=u.current;v.handler=k.current({...xe,tree:x,x:P.clientX,y:P.clientY,onClose(){A(),Y(),O.current&&!D()&&be===b.select("domReferenceElement")&&N(P,!0)}}),ne.addEventListener("mousemove",v.handler),v.handler(P);return}(v.pointerType!=="touch"||!Ge(b.select("floatingElement"),P.relatedTarget))&&N(P)}function B(P){Ge(q,P.relatedTarget)||(v.openChangeTimeout.clear(),v.restTimeout.clear(),v.restTimeoutPending=!1)}let re=g?ze(q,"mouseout",B):void 0;return a?xr(ze(q,"mousemove",U,{once:!0}),ze(q,"mouseenter",U),ze(q,"mouseleave",R),re):xr(ze(q,"mouseenter",U),ze(q,"mouseleave",R),re)},[Y,A,w,E,b,r,k,v,c,L,D,i,a,T,u,x,O,m,J,S,g]),go.useMemo(()=>{if(!r)return;function N(q){v.pointerType=q.pointerType}return{onPointerDown:N,onPointerEnter:N,onMouseMove(q){let{nativeEvent:U}=q,R=q.currentTarget,B=b.select("domReferenceElement"),re=b.select("open"),P=L(B,R,q.target);if(i&&!Xr(v.pointerType))return;if(re&&P&&v.handleCloseOptions?.blockPointerEvents){let xe=b.select("floatingElement");if(xe){let se=v.handleCloseOptions?.getScope?.()??R.ownerDocument.body;ss(v,{scopeElement:se,referenceElement:R,floatingElement:xe})}}let W=Ja(T.current);if(re&&!P||W===0||!P&&v.restTimeoutPending&&q.movementX**2+q.movementY**2<2)return;v.restTimeout.clear();function ne(){if(v.restTimeoutPending=!1,D())return;let xe=b.select("open");!v.blockMouseMove&&(!xe||P)&&S()&&b.setOpen(!0,Ve(Oe.triggerHover,U,R))}v.pointerType==="touch"?Zd.flushSync(()=>{ne()}):P&&re?ne():(v.restTimeoutPending=!0,v.restTimeout.start(W,ne))}}},[r,v,D,L,i,b,T,S])}var Xd=.1,bw=Xd*Xd,Xe=.5;function as(e,t,r,o,n,i){return o>=t!=i>=t&&e<=(n-r)*(t-o)/(i-o)+r}function ls(e,t,r,o,n,i,s,a,u,l){let c=!1;return as(e,t,r,o,n,i)&&(c=!c),as(e,t,n,i,s,a)&&(c=!c),as(e,t,s,a,u,l)&&(c=!c),as(e,t,u,l,r,o)&&(c=!c),c}function ww(e,t,r){return e>=r.x&&e<=r.x+r.width&&t>=r.y&&t<=r.y+r.height}function cs(e,t,r,o,n,i){let s=Math.min(r,n),a=Math.max(r,n),u=Math.min(o,i),l=Math.max(o,i);return e>=s&&e<=a&&t>=u&&t<=l}function Cl(e={}){let{blockPointerEvents:t=!1}=e,r=new rr,o=({x:n,y:i,placement:s,elements:a,onClose:u,nodeId:l,tree:c})=>{let m=s?.split("-")[0],d=!1,h=null,g=null,b=typeof performance<"u"?performance.now():0;function w(x,v){let C=performance.now(),k=C-b;if(h===null||g===null||k===0)return h=x,g=v,b=C,!1;let E=x-h,T=v-g,O=E*E+T*T,I=k*k*bw;return h=x,g=v,b=C,O0)}function L(){S()||_()}if(S())return;let Y=C.getBoundingClientRect(),A=k.getBoundingClientRect(),N=n>A.right-A.width/2,q=i>A.bottom-A.height/2,U=A.width>Y.width,R=A.height>Y.height,B=(U?Y:A).left,re=(U?Y:A).right,P=(R?Y:A).top,W=(R?Y:A).bottom;if(m==="top"&&i>=Y.bottom-1||m==="bottom"&&i<=Y.top+1||m==="left"&&n>=Y.right-1||m==="right"&&n<=Y.left+1){L();return}let ne=!1;switch(m){case"top":ne=cs(E,T,B,Y.top+1,re,A.bottom-1);break;case"bottom":ne=cs(E,T,B,A.top+1,re,Y.bottom-1);break;case"left":ne=cs(E,T,A.right-1,W,Y.left+1,P);break;case"right":ne=cs(E,T,Y.right-1,W,A.left+1,P);break;default:}if(ne)return;if(d&&!ww(E,T,Y)){L();return}if(!I&&w(E,T)){L();return}let xe=!1;switch(m){case"top":{let se=U?Xe/2:Xe*4,be=U||N?n+se:n-se,ye=U?n-se:N?n+se:n-se,$=i+Xe+1,Ce=N||U?A.bottom-Xe:A.top,Fe=N?U?A.bottom-Xe:A.top:A.bottom-Xe;xe=ls(E,T,be,$,ye,$,A.left,Ce,A.right,Fe);break}case"bottom":{let se=U?Xe/2:Xe*4,be=U||N?n+se:n-se,ye=U?n-se:N?n+se:n-se,$=i-Xe,Ce=N||U?A.top+Xe:A.bottom,Fe=N?U?A.top+Xe:A.bottom:A.top+Xe;xe=ls(E,T,be,$,ye,$,A.left,Ce,A.right,Fe);break}case"left":{let se=R?Xe/2:Xe*4,be=R||q?i+se:i-se,ye=R?i-se:q?i+se:i-se,$=n+Xe+1,Ce=q||R?A.right-Xe:A.left,Fe=q?R?A.right-Xe:A.left:A.right-Xe;xe=ls(E,T,Ce,A.top,Fe,A.bottom,$,be,$,ye);break}case"right":{let se=R?Xe/2:Xe*4,be=R||q?i+se:i-se,ye=R?i-se:q?i+se:i-se,$=n-Xe,Ce=q||R?A.left+Xe:A.right,Fe=q?R?A.left+Xe:A.right:A.left+Xe;xe=ls(E,T,$,be,$,ye,Ce,A.top,Fe,A.bottom);break}default:}xe?d||r.start(40,L):L()}};return o.__options={...e,blockPointerEvents:t},o}var us=class extends mo{setState(t){}update(t){}set(t,r){}notifyAll(){}};var V6=(function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=Ba.startingStyle]="startingStyle",e[e.endingStyle=Ba.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e.side="data-side",e.align="data-align",e})({});var xw={"data-popup-open":""};var Sw={"data-open":""},_w={"data-closed":""},Cw={"data-anchor-hidden":""},Kd={open(e){return e?xw:null}};var ni={open(e){return e?Sw:_w},anchorHidden(e){return e?Cw:null}},Jd={...ni,...ff};function Qd(e){return rn(19)?e:e?"true":void 0}var fs=f(ve(),1),Rl=fs.createContext(void 0);function mn(){return fs.useContext(Rl)?.direction??"ltr"}var nr=f(ve(),1);var Rw=e=>({name:"arrow",options:e,async fn(t){let{x:r,y:o,placement:n,rects:i,platform:s,elements:a,middlewareData:u}=t,{element:l,padding:c=0,offsetParent:m="real"}=Mr(e,t)||{};if(l==null)return{};let d=Zi(c),h={x:r,y:o},g=ti(n),b=ei(g),w=await s.getDimensions(l),_=g==="y",x=_?"top":"left",v=_?"bottom":"right",C=_?"clientHeight":"clientWidth",k=i.reference[b]+i.reference[g]-h[g]-i.floating[b],E=h[g]-i.reference[g],T=m==="real"?await s.getOffsetParent?.(l):a.floating,O=a.floating[C]||i.floating[b];(!O||!await s.isElement?.(T))&&(O=a.floating[C]||i.floating[b]);let I=k/2-E/2,J=O/2-w[b]/2-1,D=Math.min(d[x],J),S=Math.min(d[v],J),L=D,Y=O-w[b]-S,A=O/2-w[b]/2+I,N=Yi(L,A,Y),q=!u.arrow&&_r(n)!=null&&A!==N&&i.reference[b]/2-(A({...Rw(e),options:[e,t]});var ep={name:"hide",async fn(e){let{width:t,height:r,x:o,y:n}=e.rects.reference,i=t===0&&r===0&&o===0&&n===0,s=await e.platform.detectOverflow(e,{elementContext:"reference"});return{data:{referenceHidden:s.top-r>=0||s.right-t>=0||s.bottom-r>=0||s.left-t>=0||i}}}};var hn={sideX:"left",sideY:"top"};var tp="--available-width",rp="--available-height";function ip(e,t,r){let o=e==="inline-start"||e==="inline-end";return{top:"top",right:o?r?"inline-start":"inline-end":"right",bottom:"bottom",left:o?r?"inline-end":"inline-start":"left"}[t]}function op(e,t,r){let{rects:o,placement:n}=e;return{side:ip(t,Tt(n),r),align:_r(n)||"center",anchor:{width:o.reference.width,height:o.reference.height},positioner:{width:o.floating.width,height:o.floating.height}}}function sp(e){return Ew(e,qd)}function Ew(e,t){let{anchor:r,positionMethod:o="absolute",side:n="bottom",sideOffset:i=0,align:s="center",alignOffset:a=0,collisionBoundary:u,collisionPadding:l=5,sticky:c=!1,arrowPadding:m=5,disableAnchorTracking:d=!1,inline:h,keepMounted:g=!1,floatingRootContext:b,mounted:w,collisionAvoidance:_,shift:x,nodeId:v,adaptiveOrigin:C,lazyFlip:k=!1,externalTree:E}=e,[T,O]=nr.useState(null);!w&&T!==null&&O(null);let I=_.side||"flip",J=_.align||"flip",D=_.fallbackAxisSide||"end",S=x?.crossAxis??!1,L=x?.rootBoundary,Y=typeof r=="function"?r:void 0,A=Pe(Y),N=Y?A:r,q=Yt(r),U=Yt(w),B=mn()==="rtl",re=T||{top:"top",right:"right",bottom:"bottom",left:"left","inline-end":B?"left":"right","inline-start":B?"right":"left"}[n],P=s==="center"?re:`${re}-${s}`,W=l;typeof W=="number"?W={top:W,right:W,bottom:W,left:W}:W&&(W={top:W.top||0,right:W.right||0,bottom:W.bottom||0,left:W.left||0});let ne=1,xe=n==="bottom"?ne:0,se=n==="top"?ne:0,be=n==="right"?ne:0,ye=n==="left"?ne:0,$={boundary:u==="clipping-ancestors"?"clippingAncestors":u,padding:W},Ce=nr.useRef(null),Fe=Yt(i),xt=Yt(a),Le=typeof i!="function"?i:0,X=typeof a!="function"?a:0,M=[];h&&M.push(h),M.push(sl(G=>{let y=op(G,n,B),oe=typeof Fe.current=="function"?Fe.current(y):Fe.current,Ae=typeof xt.current=="function"?xt.current(y):xt.current;return{mainAxis:oe,crossAxis:Ae,alignmentAxis:Ae}},[Le,X,B,n]));let K=J==="none"&&I!=="shift",H=!K&&(c||S||I==="shift"),Q=I==="none"?null:cl({...$,padding:{top:W.top+ne+xe,right:W.right+ne+ye,bottom:W.bottom+ne+se,left:W.left+ne+be},mainAxis:!S&&I==="flip",crossAxis:J==="flip"?"alignment":!1,fallbackAxisSideDirection:D}),pe=K?null:al({...$,rootBoundary:L,mainAxis:J!=="none",crossAxis:H,limiter:c||S?void 0:ll(G=>{if(!Ce.current)return{};let{width:y,height:oe}=Ce.current.getBoundingClientRect(),Ae=qt(Tt(G.placement)),ee=Ae==="y"?y:oe,Qe=Ae==="y"?W.left+W.right:W.top+W.bottom;return{offset:ee/2+Qe/2}})},[$,c,S,L,W,J]);I==="shift"||J==="shift"||s==="center"?M.push(pe,Q):M.push(Q,pe),M.push(ul({...$,apply({elements:{floating:G},availableWidth:y,availableHeight:oe,rects:Ae}){if(!U.current)return;let ee=G.style;ee.setProperty(tp,`${y}px`),ee.setProperty(rp,`${oe}px`);let Qe=it(G).devicePixelRatio||1,{x:ie,y:Je,width:j,height:z}=Ae.reference,yr=(Math.round((ie+j)*Qe)-Math.round(ie*Qe))/Qe,je=(Math.round((Je+z)*Qe)-Math.round(Je*Qe))/Qe;ee.setProperty("--anchor-width",`${yr}px`),ee.setProperty("--anchor-height",`${je}px`)}}),$d(G=>({element:Ce.current||Rt(G.elements.floating).createElement("div"),padding:m,offsetParent:"floating"}),[m]),{name:"transformOrigin",fn(G){let{elements:y,middlewareData:oe,placement:Ae,rects:ee,y:Qe}=G,ie=Tt(Ae),Je=qt(ie),j=Ce.current,z=oe.arrow?.x||0,yr=oe.arrow?.y||0,je=j?.clientWidth||0,ce=j?.clientHeight||0,vr=z+je/2,kr=yr+ce/2,et=Math.abs(oe.shift?.y||0),Me=ee.reference.height/2,$e=typeof i=="function"?i(op(G,n,B)):i,ut=et>$e,pt={top:`${vr}px calc(100% + ${$e}px)`,bottom:`${vr}px ${-$e}px`,left:`calc(100% + ${$e}px) ${kr}px`,right:`${-$e}px ${kr}px`}[ie],br=`${vr}px ${ee.reference.y+Me-Qe}px`;return y.floating.style.setProperty("--transform-origin",H&&Je==="y"&&ut?br:pt),{}}},ep,C),we(()=>{!w&&b&&b.update({referenceElement:null,floatingElement:null,domReferenceElement:null,positionReference:null})},[w,b]);let le=nr.useMemo(()=>({elementResize:!d&&typeof ResizeObserver<"u",layoutShift:!d&&typeof IntersectionObserver<"u"}),[d]),{refs:fe,elements:me,x:he,y:V,middlewareData:te,update:Ne,placement:He,context:ot,isPositioned:Ze,floatingStyles:Be}=t({rootContext:b,open:g?w:void 0,placement:P,middleware:M,strategy:o,whileElementsMounted:g?void 0:(...G)=>ri(...G,le),nodeId:v,externalTree:E}),{sideX:Ue,sideY:ct}=te.adaptiveOrigin||hn,Se=Ze?o:"fixed",Or=nr.useMemo(()=>{let G;return Ze?C?G={position:Se,[Ue]:he,[ct]:V}:G={...Be,position:Se}:G={position:Se,top:0,left:0},G[tp]="100vw",G[rp]="100vh",Ze||(G.opacity=0),G},[C,Se,Ue,he,ct,V,Be,Ze]),$t=nr.useRef(null);we(()=>{if(!w)return;let G=q.current,y=typeof G=="function"?G():G,Ae=(np(y)?y.current:y)||null||null;Ae!==$t.current&&(fe.setPositionReference(Ae),$t.current=Ae)},[w,fe,N,q]),nr.useEffect(()=>{if(!w)return;let G=q.current;typeof G!="function"&&np(G)&&G.current!==$t.current&&(fe.setPositionReference(G.current),$t.current=G.current)},[w,fe,N,q]),nr.useEffect(()=>{if(g&&w&&me.reference&&me.floating)return ri(me.reference,me.floating,Ne,le)},[g,w,me,Ne,le]);let Ye=Tt(He),Yr=ip(n,Ye,B),St=_r(He)||"center",kt=!!te.hide?.referenceHidden;we(()=>{k&&w&&Ze&&Ye!==re&&O(Ye)},[k,w,Ze,Ye,re]);let vt=nr.useMemo(()=>({position:"absolute",top:te.arrow?.y,left:te.arrow?.x}),[te.arrow]),F=te.arrow?.centerOffset!==0;return nr.useMemo(()=>({positionerStyles:Or,arrowStyles:vt,arrowRef:Ce,arrowUncentered:F,side:Yr,align:St,physicalSide:Ye,anchorHidden:kt,refs:fe,context:ot,isPositioned:Ze,update:Ne}),[Or,vt,Ce,F,Yr,St,Ye,kt,fe,ot,Ze,Ne])}function np(e){return e!=null&&"current"in e}function ds(e){return e==="starting"?Mf:nt}function ap(e,t,{styles:r,transitionStatus:o,props:n,refs:i,hidden:s,inert:a=!1}){let u={...r};return a&&(u.pointerEvents="none"),Gt("div",e,{state:t,ref:i,props:[{role:"presentation",hidden:s,style:u},ds(o),n],stateAttributesMapping:ni})}var Et=f(ve(),1),gp=f(lo(),1);var lp=f(ve(),1);function cp(e){let[t,r]=lp.useState({current:e,previous:null});return Object.is(e,t.current)||r({current:e,previous:t.current}),t.previous}var gn=f(ve(),1);function El(e){let t=Lt(e),r=parseFloat(t.width)||0,o=parseFloat(t.height)||0,n=Ct(e),i=n?e.offsetWidth:r,s=n?e.offsetHeight:o;return(fo(r)!==i||fo(o)!==s)&&(r=i,o=s),{width:r,height:o}}function fp(e){let{popupElement:t,positionerElement:r,content:o,mounted:n,onMeasureLayout:i,onMeasureLayoutComplete:s,side:a,direction:u}=e,l=ln(t,!0),c=sn(),m=gn.useRef(null),d=gn.useRef(!0),h=gn.useRef(tr),g=Pe(i),b=Pe(s),w=gn.useMemo(()=>Tw(a,u),[a,u]);we(()=>{if(!n){h.current=tr,d.current=!0,m.current=null;return}if(!t||!r)return;h.current=up(t,w),Tl(t,"auto");let _=ms(t,"position","static"),x=ms(t,"transform","none"),v=ms(t,"scale","1"),C=up(r,{"--available-width":"max-content","--available-height":"max-content"});function k(){_(),x(),C()}function E(){k(),v()}if(g?.(),d.current||m.current===null){ps(r,"max-content");let J=El(t);return m.current=J,ps(r,J),E(),b?.(null,J),d.current=!1,()=>{h.current(),h.current=tr}}ps(r,"max-content");let T=m.current,O=El(t);m.current=O,Tl(t,T),E(),b?.(T,O),ps(r,O);let I=new AbortController;return c.request(()=>{Tl(t,O),l(()=>{t.style.setProperty("--popup-width","auto"),t.style.setProperty("--popup-height","auto")},I.signal)}),()=>{I.abort(),c.cancel(),h.current(),h.current=tr}},[o,t,r,l,c,n,g,b,w])}function Tw(e,t){let r=e==="top",o=e==="left"||e===(t==="rtl"?"inline-end":"inline-start");return!r&&!o?nt:{position:"absolute",[r?"bottom":"top"]:"0",[o?"right":"left"]:"0"}}function ms(e,t,r){let o=e.style.getPropertyValue(t);return e.style.setProperty(t,r),()=>{e.style.setProperty(t,o)}}function up(e,t){let r=[];for(let[o,n]of Object.entries(t))r.push(ms(e,o,n));return r.length?()=>{r.forEach(o=>o())}:tr}function Tl(e,t){let r=t==="auto"?"auto":`${t.width}px`,o=t==="auto"?"auto":`${t.height}px`;e.style.setProperty("--popup-width",r),e.style.setProperty("--popup-height",o)}function ps(e,t){let r=t==="max-content"?"max-content":`${t.width}px`,o=t==="max-content"?"max-content":`${t.height}px`;e.style.setProperty("--positioner-width",r),e.style.setProperty("--positioner-height",o)}var dp=f(ve(),1);var pp=f(Z(),1),hs=function(t){let{direction:r="ltr"}=t,o=dp.useMemo(()=>({direction:r}),[r]);return(0,pp.jsx)(Rl.Provider,{value:o,children:t.children})};var mp={name:"adaptiveOrigin",async fn(e){let{x:t,y:r,rects:{floating:o},elements:{floating:n},platform:i,strategy:s,placement:a}=e,u=it(n),l=u.getComputedStyle(n);if(!(l.transitionDuration!=="0s"&&l.transitionDuration!==""))return{x:t,y:r,data:hn};let m=await i.getOffsetParent?.(n),d={width:0,height:0};if(s==="fixed"&&u?.visualViewport)d={width:u.visualViewport.width,height:u.visualViewport.height};else if(m===u){let x=Rt(n);d={width:x.documentElement.clientWidth,height:x.documentElement.clientHeight}}else await i.isElement?.(m)&&(d=await i.getDimensions(m));let h=Tt(a),g=t,b=r;h==="left"&&(g=d.width-(t+o.width)),h==="top"&&(b=d.height-(r+o.height));let w=h==="left"?"right":hn.sideX,_=h==="top"?"bottom":hn.sideY;return{x:g,y:b,data:{sideX:w,sideY:_}}}};var yn=f(Z(),1),yp={activationDirection:e=>e?{"data-activation-direction":e}:null};function vp(e){let{store:t,side:r,children:o}=e,n=mn(),i=t.useState("activeTriggerElement"),s=t.useState("activeTriggerId"),a=t.useState("open"),u=t.useState("payload"),l=t.useState("mounted"),c=t.useState("popupElement"),m=t.useState("positionerElement"),d=cp(a?i:null),h=kw(s,u),g=Et.useRef(null),[b,w]=Et.useState(null),[_,x]=Et.useState(null),v=Et.useRef(null),C=Et.useRef(null),k=ln(v,!0),E=sn(),T=Et.useRef(null),[O,I]=Et.useState(null),[J,D]=Et.useState(!1);we(()=>(t.set("adaptiveOrigin",mp),()=>{t.set("adaptiveOrigin",void 0)}),[t]);let S=Pe(()=>{v.current?.style.setProperty("animation","none"),v.current?.style.setProperty("transition","none"),C.current?.style.setProperty("display","none")}),L=Pe(R=>{v.current?.style.removeProperty("animation"),v.current?.style.removeProperty("transition"),C.current?.style.removeProperty("display"),R&&I(R)}),Y=Pe(()=>{T.current?.abort();let R=new AbortController;T.current=R,k(()=>{w(null),I(null),g.current=null},R.signal)}),A=Et.useRef(null);we(()=>{(!a||!l)&&(A.current=null)},[a,l]),we(()=>{if(i&&d&&i!==d&&A.current!==i&&g.current){w(g.current),D(!0);let R=Ow(d,i);x(R),A.current=i}},[i,d]),we(()=>{b!=null&&(T.current?.abort(),D(!0),E.request(()=>{gp.flushSync(()=>{D(!1)}),Y()}))},[h,b,Y,E]),we(()=>{let R=v.current;if(!R)return;let B=Rt(R).createElement("div");for(let re of Array.from(R.childNodes))B.appendChild(re.cloneNode(!0));g.current=B});let N=b!=null,q;N?q=(0,yn.jsxs)(Et.Fragment,{children:[(0,yn.jsx)("div",{"data-previous":!0,inert:Qd(!0),ref:C,style:{...O?{"--popup-width":`${O.width}px`,"--popup-height":`${O.height}px`}:null,position:"absolute"},"data-ending-style":J?void 0:""},"previous"),(0,yn.jsx)("div",{"data-current":!0,ref:v,"data-starting-style":J?"":void 0,children:o},h)]}):q=(0,yn.jsx)("div",{"data-current":!0,ref:v,children:o},h),we(()=>{let R=C.current;!R||!b||R.replaceChildren(...Array.from(b.childNodes))},[b]),fp({popupElement:c,positionerElement:m,mounted:l,content:u,onMeasureLayout:S,onMeasureLayoutComplete:L,side:r,direction:n});let U={activationDirection:Pw(_),transitioning:N};return{children:q,state:U}}function Pw(e){if(e)return`${hp(e.horizontal,5,"right","left")} ${hp(e.vertical,5,"down","up")}`}function hp(e,t,r,o){return e>t?r:e<-t?o:""}function Ow(e,t){let r=e.getBoundingClientRect(),o=t.getBoundingClientRect(),n={x:r.left+r.width/2,y:r.top+r.height/2},i={x:o.left+o.width/2,y:o.top+o.height/2};return{horizontal:i.x-n.x,vertical:i.y-n.y}}function kw(e,t){let[r,o]=Et.useState(0),n=Et.useRef(e),i=Et.useRef(t),s=Et.useRef(!1);return we(()=>{let a=n.current,u=i.current,l=e!==a,c=t!==u;l?(o(m=>m+1),s.current=!c):s.current&&c&&(o(m=>m+1),s.current=!1),n.current=e,i.current=t},[e,t]),`${e??"current"}-${r}`}var gs=f(ve(),1),bp=f(lo(),1);var wp=f(Z(),1),xp=gs.forwardRef(function(t,r){let{children:o,container:n,className:i,render:s,style:a,...u}=t,{node:l,subtree:c}=jf({container:n,ref:r,componentProps:t,elementProps:u});return!c&&!l?null:(0,wp.jsxs)(gs.Fragment,{children:[c,l&&bp.createPortal(o,l)]})});var Xt={};so(Xt,{Arrow:()=>jp,Handle:()=>si,Popup:()=>Dp,Portal:()=>Lp,Positioner:()=>Mp,Provider:()=>Hp,Root:()=>Tp,Trigger:()=>Fp,Viewport:()=>Wp,createHandle:()=>Gp});var vn=f(ve(),1);var ys=f(ve(),1),Pl=ys.createContext(void 0);function ur(e){let t=ys.useContext(Pl);if(t===void 0&&!e)throw new Error(lr(72));return t}var Sp=f(ve(),1);var _p={...Wd,disabled:e=>e.disabled,instantType:e=>e.instantType,isInstantPhase:e=>e.isInstantPhase,trackCursorAxis:e=>e.trackCursorAxis,disableHoverablePopup:e=>e.disableHoverablePopup,lastOpenChangeReason:e=>e.openChangeReason,closeOnClick:e=>e.closeOnClick,closeDelay:e=>e.closeDelay,adaptiveOrigin:e=>e.adaptiveOrigin},vs=class extends mo{constructor(t,r,o){let n=new Ho;super(Rp(t,n,r,o),Ep(n),_p)}setOpen=(t,r)=>{Ld(this,t,r,{extraState:{openChangeReason:r.reason}})};cancelPendingOpen(t){this.state.floatingRootContext.dispatchOpenChange(!1,Ve(Oe.triggerPress,t))}};function Cp(){let e=new Ho,t=new us(Object.freeze(Rp(void 0,e)),Object.freeze(Ep(e)),_p);return Object.assign(t,{setOpen:tr,cancelPendingOpen:tr})}function Rp(e,t,r,o=!1){let n={...zd(),disabled:!1,instantType:void 0,isInstantPhase:!1,trackCursorAxis:"none",disableHoverablePopup:!1,openChangeReason:null,closeOnClick:!0,closeDelay:0,adaptiveOrigin:void 0,...e};return n.floatingRootContext=Hd(t,r,o),n}function Ep(e){return{popupRef:Sp.createRef(),onOpenChange:void 0,onOpenChangeComplete:void 0,triggerElements:e}}var ii=f(Z(),1),Tp=ml(function(t){let{disabled:r=!1,defaultOpen:o=!1,open:n,disableHoverablePopup:i=!1,trackCursorAxis:s="none",actionsRef:a,onOpenChange:u,onOpenChangeComplete:l,handle:c,triggerId:m,defaultTriggerId:d=null,children:h}=t,g=Ad((D,S)=>new vs({open:o,openProp:n,activeTriggerId:d,triggerIdProp:m},D,S));g.useControlledProp("openProp",n),g.useControlledProp("triggerIdProp",m),g.useContextCallback("onOpenChange",u),g.useContextCallback("onOpenChangeComplete",l);let b=g.useState("open"),w=!r&&b,_=g.useState("activeTriggerId"),x=g.useState("mounted"),v=g.useState("payload");g.useSyncedValues({trackCursorAxis:s,disableHoverablePopup:i,disabled:r}),Md(g,{closeOnActiveTriggerUnmount:!0});let{forceUnmount:C,transitionStatus:k}=Vd(w,g),E=g.useState("isInstantPhase"),T=g.useState("instantType"),O=g.useState("lastOpenChangeReason"),I=vn.useRef(null);we(()=>{b&&r&&g.setOpen(!1,Ve(Oe.disabled))},[b,r,g]),we(()=>{k==="ending"&&O===Oe.none||k!=="ending"&&E?(T!=="delay"&&(I.current=T),g.set("instantType","delay")):I.current!==null&&(g.set("instantType",I.current),I.current=null)},[k,E,O,T,g]),we(()=>{w&&_==null&&g.set("payload",void 0)},[g,_,w]),vn.useImperativeHandle(a,()=>({unmount:C,close:()=>g.setOpen(!1,Ve(Oe.imperativeAction))}),[C,g]);let J=w||x||!r&&s!=="none";return(0,ii.jsxs)(Pl.Provider,{value:g,children:[c&&(0,ii.jsx)(Id,{handle:c,store:g}),J&&(0,ii.jsx)(Fw,{store:g,disabled:r,trackCursorAxis:s}),typeof h=="function"?h({payload:v}):h]})});function Fw({store:e,disabled:t,trackCursorAxis:r}){let o=e.useState("floatingRootContext"),n=tl(o,{enabled:!t,referencePress:()=>e.select("closeOnClick")}),i=el(o,{enabled:!t&&r!=="none",axis:r==="none"?void 0:r}),s=vn.useMemo(()=>It(i.reference,n.reference),[i.reference,n.reference]);return Dd(e,{activeTriggerProps:s,inactiveTriggerProps:s,popupProps:n.floating??nt}),null}var ws=f(ve(),1);var bs=f(ve(),1),Ol=bs.createContext(void 0);function Pp(){return bs.useContext(Ol)}var kp="data-base-ui-tooltip-trigger";function Op(e){if("composedPath"in e){let r=e.composedPath();for(let o=0;ow.select("transitionStatus")==="ending",shouldOpen(){return!B.current}}),be=bl(C,{enabled:!N}).reference,ye=Le=>{let X=B.current,M=Op(Le),K=xe(M),H=k.current,Q=H&&M&&Ge(H,M);if(K&&w.select("open")&&w.select("lastOpenChangeReason")===Oe.triggerHover){w.setOpen(!1,Ve(Oe.triggerHover,Le));return}if(X&&!K&&Q&&!q.current&&!w.select("open")&&H&&Xr(P.current)){let pe=()=>{!B.current&&!q.current&&!w.select("open")&&w.setOpen(!0,Ve(Oe.triggerHover,Le,H))},le=W();le===0?(re.clear(),pe()):re.start(le,pe)}},$=w.useState("triggerProps",I);return Gt("button",t,{state:{open:v},ref:[r,O,k],props:[se,be,I||U!=="none"?$:void 0,{onMouseOver(Le){ye(Le.nativeEvent)},onFocus(Le){ne(Op(Le.nativeEvent))&&Le.preventBaseUIHandler()},onMouseLeave(){B.current=!1,re.clear(),P.current=void 0},onPointerEnter(Le){P.current=Le.pointerType},onPointerDown(Le){P.current=Le.pointerType,w.set("closeOnClick",c),c&&!w.select("open")&&w.cancelPendingOpen(Le.nativeEvent)},onClick(Le){c&&!w.select("open")&&w.cancelPendingOpen(Le.nativeEvent)},id:_,"data-trigger-disabled":N?"":void 0,[kp]:N?void 0:""},h],stateAttributesMapping:Kd})});var Ip=f(ve(),1);var xs=f(ve(),1),kl=xs.createContext(void 0);function Ap(){let e=xs.useContext(kl);if(e===void 0)throw new Error(lr(70));return e}var Fl=f(Z(),1),Lp=Ip.forwardRef(function(t,r){let{keepMounted:o=!1,...n}=t;return ur().useState("mounted")||o?(0,Fl.jsx)(kl.Provider,{value:o,children:(0,Fl.jsx)(xp,{ref:r,...n})}):null});var _s=f(ve(),1);var Ss=f(ve(),1),Al=Ss.createContext(void 0);function bn(){let e=Ss.useContext(Al);if(e===void 0)throw new Error(lr(71));return e}var Np=f(Z(),1),Mp=_s.forwardRef(function(t,r){let{render:o,className:n,anchor:i,positionMethod:s="absolute",side:a="top",align:u="center",sideOffset:l=0,alignOffset:c=0,collisionBoundary:m="clipping-ancestors",collisionPadding:d=5,arrowPadding:h=5,sticky:g=!1,disableAnchorTracking:b=!1,collisionAvoidance:w=Vf,style:_,...x}=t,v=ur(),C=Ap(),k=v.useState("open"),E=v.useState("mounted"),T=v.useState("trackCursorAxis"),O=v.useState("disableHoverablePopup"),I=v.useState("floatingRootContext"),J=v.useState("instantType"),D=v.useState("transitionStatus"),S=v.useState("adaptiveOrigin"),L=sp({anchor:i,positionMethod:s,floatingRootContext:I,mounted:E,side:a,sideOffset:l,align:u,alignOffset:c,collisionBoundary:m,collisionPadding:d,sticky:g,arrowPadding:h,disableAnchorTracking:b,keepMounted:C,collisionAvoidance:w,adaptiveOrigin:S}),Y=_s.useMemo(()=>({open:k,side:L.side,align:L.align,anchorHidden:L.anchorHidden,instant:T!=="none"?"tracking-cursor":J}),[k,L.side,L.align,L.anchorHidden,T,J]),A=ap(t,Y,{styles:L.positionerStyles,transitionStatus:D,props:x,refs:[r,v.useStateSetter("positionerElement")],hidden:!E,inert:!k||T==="both"||O});return(0,Np.jsx)(Al.Provider,{value:L,children:A})});var Vp=f(ve(),1);var Dp=Vp.forwardRef(function(t,r){let{render:o,className:n,style:i,...s}=t,a=ur(),{side:u,align:l}=bn(),c=a.useState("open"),m=a.useState("instantType"),d=a.useState("transitionStatus"),h=a.useState("popupProps"),g=a.useState("floatingRootContext"),b=a.useState("disabled"),w=a.useState("closeDelay");zi({open:c,ref:a.context.popupRef,onComplete(){c&&a.context.onOpenChangeComplete?.(!0)}}),Sl(g,{enabled:!b,closeDelay:w});let _=a.useStateSetter("popupElement");return Gt("div",t,{state:{open:c,side:u,align:l,instant:m,transitionStatus:d},ref:[r,a.context.popupRef,_],props:[Fd,h,ds(d),s],stateAttributesMapping:Jd})});var Bp=f(ve(),1);var jp=Bp.forwardRef(function(t,r){let{render:o,className:n,style:i,...s}=t,a=ur(),{arrowRef:u,side:l,align:c,arrowUncentered:m,arrowStyles:d}=bn(),h=a.useState("open"),g=a.useState("instantType");return Gt("div",t,{state:{open:h,side:l,align:c,uncentered:m,instant:g},ref:[r,u],props:[{style:d,"aria-hidden":!0},s],stateAttributesMapping:ni})});var zp=f(ve(),1);var Il=f(Z(),1),Hp=function(t){let{delay:r,closeDelay:o,timeout:n=400}=t,i=zp.useMemo(()=>({open:r,close:o}),[r,o]);return(0,Il.jsx)(Ol.Provider,{value:r,children:(0,Il.jsx)(Qa,{delay:i,timeoutMs:n,children:t.children})})};var Up=f(ve(),1);var Wp=Up.forwardRef(function(t,r){let{render:o,className:n,style:i,children:s,...a}=t,u=ur(),l=bn(),c=u.useState("instantType"),{children:m,state:d}=vp({store:u,side:l.side,children:s}),h={activationDirection:d.activationDirection,transitioning:d.transitioning,instant:c};return Gt("div",t,{state:h,ref:r,props:[a,{children:m}],stateAttributesMapping:yp})});var si=class extends es{constructor(){super(Cp(),"Tooltip")}open(t){this.openByTrigger(t)}close(){this.closePopup()}get isOpen(){return this.attachedStore?.select("open")??!1}};function Gp(){return new si}function Dr(e){return Gt(e.defaultTagName??"div",e,e)}var Zp=f(Te(),1),Ll="data-wp-hash";function Nl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Nw(document)),e.__wpStyleRuntime}function Lw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Ll}]`))if(r.getAttribute(Ll)===t)return!0;return!1}function Xp(e,t,r){if(!e.head)return;let o=Nl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Lw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Ll,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Nw(e){let t=Nl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Xp(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Kp(e,t){let r=Nl();r.styles.set(e,t);for(let o of r.documents.keys())Xp(o,e,t)}typeof process>"u",Kp("3167e7d116",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{text-wrap:pretty;margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-emphasis,600);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-typography-font-weight-default,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-default,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}');var Yp={text:"_83ed8a8da5dd50ea__text","heading-2xl":"_14437cfb77831647__heading-2xl","heading-xl":"_3c78b7fa9b4072dd__heading-xl","heading-lg":"aa58f227716bcde2__heading-lg","heading-md":"fc4da56d8dfe52c4__heading-md","heading-sm":"a9b78c7c82e8dff7__heading-sm","body-xl":"_305ff559e52180d5__body-xl","body-lg":"ca1aa3fc2029e958__body-lg","body-md":"_131101940be12424__body-md","body-sm":"_0e8d87a42c1f75fa__body-sm"};typeof process>"u",Kp("e8e31009f5","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}");var qp={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a",ol:"c59a0ebebd71fa4a__ol",li:"_46b5cb0c8e24e8c9__li"},wn=(0,Zp.forwardRef)(function({variant:t="body-md",render:r,className:o,...n},i){return Dr({render:r,defaultTagName:"span",ref:i,props:It(n,{className:We(Yp.text,qp.heading,qp.p,Yp[t],o)})})});var xn={};so(xn,{Popup:()=>ym,Portal:()=>Cs,Positioner:()=>Rs,Provider:()=>Em,Root:()=>Cm,Trigger:()=>wm});var hm=f(Te(),1);var rm=f(Te(),1);var Vl="data-wp-hash";function Dl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Vw(document)),e.__wpStyleRuntime}function Mw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Vl}]`))if(r.getAttribute(Vl)===t)return!0;return!1}function $p(e,t,r){if(!e.head)return;let o=Dl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Mw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Vl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Vw(e){let t=Dl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)$p(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Dw(e,t){let r=Dl();r.styles.set(e,t);for(let o of r.documents.keys())$p(o,e,t)}typeof process>"u",Dw("be37f31c1e","._11fc52b637ff8a7e__slot{inset:0;isolation:isolate;pointer-events:none;position:fixed;z-index:1000000003}@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._11fc52b637ff8a7e__slot>*{pointer-events:auto}}}");var Qp={slot:"_11fc52b637ff8a7e__slot"},em="data-wp-compat-overlay-slot";function Bw(){return typeof document>"u"?null:document}function jw(){let e;try{e=window.top?.wp}catch{}let t=e??window.wp;return typeof t?.components=="object"&&t.components!==null}var Br=null;function Ml(e){return e.setAttribute("aria-hidden","false"),e}function zw(e){let t=e.createElement("div");return t.setAttribute(em,""),Qp.slot&&t.classList.add(Qp.slot),e.body.appendChild(t),t}function tm(){if(typeof window>"u"||!jw()&&window.__wpUiCompatOverlaySlotEnabled!==!0)return;let e=Bw();if(!e||!e.body)return;if(Br&&Br.ownerDocument===e&&Br.isConnected)return Ml(Br);let t=e.querySelector(`[${em}]`);return t instanceof HTMLDivElement?(Br=Ml(t),Br):(Br?.isConnected&&Br.remove(),Br=Ml(zw(e)),Br)}var om=f(Z(),1),Cs=(0,rm.forwardRef)(function({container:t,...r},o){return(0,om.jsx)(Xt.Portal,{container:t??tm(),...r,ref:o})});var nm=f(Te(),1),am=f(Z(),1),Bl="data-wp-hash";function jl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Uw(document)),e.__wpStyleRuntime}function Hw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Bl}]`))if(r.getAttribute(Bl)===t)return!0;return!1}function im(e,t,r){if(!e.head)return;let o=jl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Hw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Bl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Uw(e){let t=jl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)im(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function sm(e,t){let r=jl();r.styles.set(e,t);for(let o of r.documents.keys())im(o,e,t)}typeof process>"u",sm("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var Ww={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",sm("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Gw={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Rs=(0,nm.forwardRef)(function({align:t="center",className:r,side:o="top",sideOffset:n=4,...i},s){return(0,am.jsx)(Xt.Positioner,{ref:s,align:t,side:o,sideOffset:n,...i,className:We(Ww["box-sizing"],Gw.positioner,r)})});var lm=f(Te(),1);function zl(e,t,r){return(0,lm.cloneElement)(e??t,{children:r})}var Yw=f(um(),1);var dm=f(ai(),1),{lock:YA,unlock:pm}=(0,dm.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/ui");function qw(){let e=Yw;if(e.ThemeProvider)return e.ThemeProvider;if(!e.privateApis)throw new Error("@wordpress/ui: @wordpress/theme must expose `ThemeProvider` or `privateApis.ThemeProvider`.");return pm(e.privateApis).ThemeProvider}var mm=qw();var li=f(Z(),1),Hl="data-wp-hash";function Ul(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&Xw(document)),e.__wpStyleRuntime}function Zw(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Hl}]`))if(r.getAttribute(Hl)===t)return!0;return!1}function gm(e,t,r){if(!e.head)return;let o=Ul(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(Zw(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Hl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function Xw(e){let t=Ul();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)gm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Kw(e,t){let r=Ul();r.styles.set(e,t);for(let o of r.documents.keys())gm(o,e,t)}typeof process>"u",Kw("19fcc06039",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._480b748dd3510e64__positioner{z-index:var(--wp-ui-tooltip-z-index,initial)}._50096b232db7709d__popup{--_wp-ui-elevation-sm:0 1px 2px rgba(0,0,0,.05),0 2px 3px rgba(0,0,0,.04),0 6px 6px rgba(0,0,0,.03),0 8px 8px rgba(0,0,0,.02);background-color:var(--wpds-color-background-surface-neutral-strong,#fff);border-radius:var(--wpds-border-radius-md,4px);box-shadow:var(--_wp-ui-elevation-sm);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-sm,12px);line-height:1.4;padding:var(--wpds-dimension-padding-xs,4px) var(--wpds-dimension-padding-sm,8px);@media (forced-colors:active){border-bottom-color:CanvasText;border-bottom-style:solid;border-bottom-width:1px;border-left-color:CanvasText;border-left-style:solid;border-left-width:1px;border-right-color:CanvasText;border-right-style:solid;border-right-width:1px;border-top-color:CanvasText;border-top-style:solid;border-top-width:1px}}}}');var Jw={positioner:"_480b748dd3510e64__positioner",popup:"_50096b232db7709d__popup"},Qw={background:"#1e1e1e"},ym=(0,hm.forwardRef)(function({portal:t,positioner:r,children:o,className:n,...i},s){let a=(0,li.jsx)(mm,{color:Qw,children:(0,li.jsx)(Xt.Popup,{ref:s,className:We(Jw.popup,n),...i,children:o})}),u=zl(r,(0,li.jsx)(Rs,{}),a);return zl(t,(0,li.jsx)(Cs,{}),u)});var vm=f(Te(),1),bm=f(Z(),1),wm=(0,vm.forwardRef)(function(t,r){return(0,bm.jsx)(Xt.Trigger,{ref:r,...t})});var xm=f(ge(),1),Sm=f(Z(),1);function _m({children:e}){return(0,Sm.jsx)(hs,{direction:(0,xm.isRTL)()?"rtl":"ltr",children:e})}var Wl=f(Z(),1);function Cm(e){return(0,Wl.jsx)(_m,{children:(0,Wl.jsx)(Xt.Root,{...e})})}var Rm=f(Z(),1);function Em({...e}){return(0,Rm.jsx)(Xt.Provider,{...e})}var Tm=f(Te(),1),Pm=f(ge(),1),Sn=f(Z(),1),Gl="data-wp-hash";function Yl(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&e1(document)),e.__wpStyleRuntime}function $w(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${Gl}]`))if(r.getAttribute(Gl)===t)return!0;return!1}function Om(e,t,r){if(!e.head)return;let o=Yl(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if($w(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(Gl,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function e1(e){let t=Yl();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Om(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Ts(e,t){let r=Yl();r.styles.set(e,t);for(let o of r.documents.keys())Om(o,e,t)}typeof process>"u",Ts("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var t1={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Ts("08122b3d53","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{.af79fb116edb0dd7__outset-ring--focus:focus,.dfcfdc28396e5d98__outset-ring--focus-visible:focus-visible,.e5cd9ee879f6403a__outset-ring--focus-within:focus-within,:focus-visible ._81935a08e952f267__outset-ring--focus-parent-visible{--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within,.abc777e9713fa711__outset-ring--focus-except-active:focus{outline:none}._3c9f5ee9fc9c136d__outset-ring--focus-within-except-active:focus-within:not(:has(:active)),.abc777e9713fa711__outset-ring--focus-except-active:focus:not(:active){--_gcd-a-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));--_gcd-div-outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--focus-color,var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9)));outline-offset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}}");var r1={"outset-ring--focus":"af79fb116edb0dd7__outset-ring--focus","outset-ring--focus-visible":"dfcfdc28396e5d98__outset-ring--focus-visible","outset-ring--focus-within":"e5cd9ee879f6403a__outset-ring--focus-within","outset-ring--focus-parent-visible":"_81935a08e952f267__outset-ring--focus-parent-visible","outset-ring--focus-except-active":"abc777e9713fa711__outset-ring--focus-except-active","outset-ring--focus-within-except-active":"_3c9f5ee9fc9c136d__outset-ring--focus-within-except-active"};typeof process>"u",Ts("e8e6a9be37",'@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.d4250949359b05ce__link{text-decoration-thickness:from-font;text-underline-offset:.2em}.c6055659b8e2cd2c__is-brand,.c6055659b8e2cd2c__is-brand:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9));color:var(--wpds-color-foreground-interactive-brand,var(--wp-admin-theme-color,#3858e9))}.c6055659b8e2cd2c__is-brand:active,.c6055659b8e2cd2c__is-brand:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000));color:var(--wpds-color-foreground-interactive-brand-active,color-mix(in oklch,var(--wp-admin-theme-color,#3858e9) 52%,#000))}._92e0dfcaeee15b88__is-neutral,._92e0dfcaeee15b88__is-neutral:visited{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);text-decoration-color:var(--wpds-color-stroke-interactive-neutral,#8d8d8d)}._92e0dfcaeee15b88__is-neutral:active,._92e0dfcaeee15b88__is-neutral:hover{--_gcd-a-color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e);color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}.cf122a9bf1035d42__is-unstyled{--_gcd-a-color:inherit;color:inherit;text-decoration:none}._0cb411afac4c86c7__link-icon{display:inline-block;font-weight:var(--wpds-typography-font-weight-default,400);line-height:1;margin-inline-start:var(--wpds-dimension-padding-xs,4px);text-decoration:none}._0cb411afac4c86c7__link-icon:after{content:"\\2197"}._0cb411afac4c86c7__link-icon:dir(rtl):after{content:"\\2196"}}}');var Es={link:"d4250949359b05ce__link","is-brand":"c6055659b8e2cd2c__is-brand","is-neutral":"_92e0dfcaeee15b88__is-neutral","is-unstyled":"cf122a9bf1035d42__is-unstyled","link-icon":"_0cb411afac4c86c7__link-icon"};typeof process>"u",Ts("e8e31009f5","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-weak,#707070))}&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-emphasis,600));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}.c59a0ebebd71fa4a__ol{list-style:var(--_gcd-ol-list-style,none);margin:var(--_gcd-ol-margin,0);padding-block:var(--_gcd-ol-padding-block,0);padding-inline:var(--_gcd-ol-padding-inline,0)}._46b5cb0c8e24e8c9__li{margin:var(--_gcd-li-margin,0)}");var o1={button:"_6defc79820e382c6__button",input:"d2cff2e5dea83bd1__input",textarea:"_547d86373d02e108__textarea",div:"_8c15fd0ed9f28ba4__div",p:"_43cec3e1eec1066d__p",heading:"e97669c6d9a38497__heading",a:"_2c0831b0499dbd6e__a",ol:"c59a0ebebd71fa4a__ol",li:"_46b5cb0c8e24e8c9__li"},ql=(0,Tm.forwardRef)(function({children:t,variant:r="default",tone:o="brand",openInNewTab:n=!1,target:i,render:s,className:a,...u},l){let c=n||/^_blank$/i.test(i??"");return Dr({render:s,defaultTagName:"a",ref:l,props:It(u,{className:We(o1.a,t1["box-sizing"],r1["outset-ring--focus-except-active"],r!=="unstyled"&&Es.link,r!=="unstyled"&&Es[`is-${o}`],r==="unstyled"&&Es["is-unstyled"],a),target:i??(n?"_blank":void 0),children:(0,Sn.jsxs)(Sn.Fragment,{children:[t,c&&(0,Sn.jsx)("span",{className:Es["link-icon"],role:"img","aria-label":(0,Pm.__)("(opens in a new tab)")})]})})})});var Ps=f(Te(),1),ci=(0,Ps.forwardRef)(({icon:e,size:t=24,style:r,...o},n)=>{let i=e.props.style,s=i||r?{...i,...r}:void 0;return(0,Ps.cloneElement)(e,{width:t,height:t,...o,...s?{style:s}:{},ref:n})});var Os=f(_n(),1),Zl=f(Z(),1),Uo=(0,Zl.jsx)(Os.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,Zl.jsx)(Os.Path,{d:"M14 6.5L9 12L14 17.5",vectorEffect:"non-scaling-stroke"})});var ks=f(_n(),1),Xl=f(Z(),1),Wo=(0,Xl.jsx)(ks.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,Xl.jsx)(ks.Path,{d:"M10 6.5L15 12L10 17.5",vectorEffect:"non-scaling-stroke"})});var Fs=f(_n(),1),Kl=f(Z(),1),Jl=(0,Kl.jsx)(Fs.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",children:(0,Kl.jsx)(Fs.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"})});var As=f(_n(),1),Ql=f(Z(),1),Is=(0,Ql.jsx)(As.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,Ql.jsx)(As.Path,{d:"M7 17.5L12 12L7 6.5M13 17.5L18 12L13 6.5",vectorEffect:"non-scaling-stroke"})});var Ls=f(_n(),1),$l=f(Z(),1),Ns=(0,$l.jsx)(Ls.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",style:{fill:"none"},stroke:"currentColor",strokeWidth:"1.5",children:(0,$l.jsx)(Ls.Path,{d:"M17 6.5L12 12L17 17.5M11 6.5L6 12L11 17.5",vectorEffect:"non-scaling-stroke"})});var Fm=f(Te(),1),ec="data-wp-hash";function tc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&i1(document)),e.__wpStyleRuntime}function n1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${ec}]`))if(r.getAttribute(ec)===t)return!0;return!1}function Am(e,t,r){if(!e.head)return;let o=tc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(n1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(ec,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function i1(e){let t=tc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Am(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function s1(e,t){let r=tc();r.styles.set(e,t);for(let o of r.documents.keys())Am(o,e,t)}typeof process>"u",s1("fa606a57ae","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.f37b9e2e191ebd66__visually-hidden{word-wrap:normal;border:0;clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;word-break:normal}}}");var a1={"visually-hidden":"f37b9e2e191ebd66__visually-hidden"},rc=(0,Fm.forwardRef)(function({render:t,...r},o){return Dr({render:t,ref:o,props:It({className:a1["visually-hidden"]},r,{"data-visually-hidden":""})})});var Im=f(Te(),1),oc="data-wp-hash";function nc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&c1(document)),e.__wpStyleRuntime}function l1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${oc}]`))if(r.getAttribute(oc)===t)return!0;return!1}function Lm(e,t,r){if(!e.head)return;let o=nc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(l1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(oc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function c1(e){let t=nc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Lm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function u1(e,t){let r=nc();r.styles.set(e,t);for(let o of r.documents.keys())Lm(o,e,t)}typeof process>"u",u1("32aba35fe1","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");var f1={stack:"_19ce0419607e1896__stack"},d1={xs:"var(--wpds-dimension-gap-xs, 4px)",sm:"var(--wpds-dimension-gap-sm, 8px)",md:"var(--wpds-dimension-gap-md, 12px)",lg:"var(--wpds-dimension-gap-lg, 16px)",xl:"var(--wpds-dimension-gap-xl, 24px)","2xl":"var(--wpds-dimension-gap-2xl, 32px)","3xl":"var(--wpds-dimension-gap-3xl, 40px)"},vo=(0,Im.forwardRef)(function({direction:t,gap:r,align:o,justify:n,wrap:i,render:s,...a},u){let l={gap:r&&d1[r],alignItems:o,justifyContent:n,flexDirection:t,flexWrap:i};return Dr({render:s,ref:u,props:It(a,{style:l,className:f1.stack})})});var Mm=f(Te(),1),ic="data-wp-hash";function sc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&m1(document)),e.__wpStyleRuntime}function p1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${ic}]`))if(r.getAttribute(ic)===t)return!0;return!1}function Vm(e,t,r){if(!e.head)return;let o=sc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(p1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(ic,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function m1(e){let t=sc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Vm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function Dm(e,t){let r=sc();r.styles.set(e,t);for(let o of r.documents.keys())Vm(o,e,t)}typeof process>"u",Dm("10f3806643","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer utilities{._336cd3e4e743482f__box-sizing{box-sizing:border-box;*,:after,:before{box-sizing:inherit}}}}");var h1={"box-sizing":"_336cd3e4e743482f__box-sizing"};typeof process>"u",Dm("ed2c39ec90","@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{.b20cc1690085c2f0__skeleton{background-color:var(--wpds-color-background-surface-neutral-weak,#f4f4f4);display:block;@media (forced-colors:active){border:var(--wpds-border-width-xs,1px) solid CanvasText}}._9b143194fdb45f93__pulse{@media not (prefers-reduced-motion){animation:e2b9fe0690281bc8__skeleton-pulse 1.5s ease-in-out infinite}}@keyframes e2b9fe0690281bc8__skeleton-pulse{0%,to{opacity:1}50%{opacity:.4}}}}");var Nm={skeleton:"b20cc1690085c2f0__skeleton",pulse:"_9b143194fdb45f93__pulse","skeleton-pulse":"e2b9fe0690281bc8__skeleton-pulse"},ui=(0,Mm.forwardRef)(function({render:t,...r},o){return Dr({render:t,ref:o,props:It({className:We(Nm.skeleton,Nm.pulse,h1["box-sizing"]),"aria-hidden":!0},r)})});var Bm=f(Te(),1),jm=f(Z(),1),zm=(0,Bm.forwardRef)(({children:e,className:t,ariaLabel:r,as:o="div",...n},i)=>(0,jm.jsx)(o,{ref:i,className:We("admin-ui-navigable-region",t),"aria-label":r,role:"region",tabIndex:"-1",...n,children:e}));zm.displayName="NavigableRegion";var Hm=zm;var Um=f(ge(),1);var bo=f(Z(),1),lc="data-wp-hash";function cc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&y1(document)),e.__wpStyleRuntime}function g1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${lc}]`))if(r.getAttribute(lc)===t)return!0;return!1}function Wm(e,t,r){if(!e.head)return;let o=cc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(g1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(lc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function y1(e){let t=cc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Wm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function v1(e,t){let r=cc();r.styles.set(e,t);for(let o of r.documents.keys())Wm(o,e,t)}typeof process>"u",v1("72ef022400",".bfb5a2dd8cceebd3__list{--focus-ring-size:calc(var(--wpds-border-width-focus, var(--wp-admin-border-width-focus, 2px))*2);list-style:none;margin:calc(var(--focus-ring-size)*-1);overflow-x:auto;padding:var(--focus-ring-size);scroll-padding:var(--focus-ring-size)}.a4759b4cb2c8bd92__li{flex-shrink:0}._07da506d3f2d9afe__item{align-items:center;color:var(--wpds-color-foreground-interactive-neutral-weak,#707070);display:flex;font-weight:var(--wpds-typography-font-weight-default,400);min-block-size:44px;min-inline-size:44px;text-decoration:none}._07da506d3f2d9afe__item:hover,._07da506d3f2d9afe__item[aria-current=page]{color:var(--wpds-color-foreground-interactive-neutral-weak-active,#1e1e1e)}._07da506d3f2d9afe__item[aria-current=page]{font-weight:var(--wpds-typography-font-weight-emphasis,600)}");var ac={list:"bfb5a2dd8cceebd3__list",li:"a4759b4cb2c8bd92__li",item:"_07da506d3f2d9afe__item"},b1=({items:e,currentHref:t,ariaLabel:r=(0,Um.__)("Sections"),linkComponent:o,className:n})=>{if(!e.length)return null;let i=o??"a";return(0,bo.jsx)("nav",{"aria-label":r,className:n,children:(0,bo.jsx)(vo,{render:(0,bo.jsx)("ul",{role:"list"}),direction:"row",align:"center",gap:"md",className:ac.list,children:e.map(s=>(0,bo.jsx)("li",{className:ac.li,children:(0,bo.jsx)(wn,{variant:"body-md",className:ac.item,render:(0,bo.jsx)(ql,{variant:"unstyled","aria-current":s.href===t?"page":void 0,render:(0,bo.jsx)(i,{href:s.href})}),children:s.label})},s.href))})})},Gm=b1;var qm=f(ue(),1),{Fill:Zm,Slot:Xm}=(0,qm.createSlotFill)("SidebarToggle");var ir=f(Z(),1),uc="data-wp-hash";function fc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&x1(document)),e.__wpStyleRuntime}function w1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${uc}]`))if(r.getAttribute(uc)===t)return!0;return!1}function Km(e,t,r){if(!e.head)return;let o=fc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(w1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(uc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function x1(e){let t=fc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Km(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function S1(e,t){let r=fc();r.styles.set(e,t);for(let o of r.documents.keys())Km(o,e,t)}typeof process>"u",S1("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var jr={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function Jm({headingLevel:e=1,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,actions:s,navigation:a,components:u,showSidebarToggle:l=!0}){let c=`h${e}`,m=!!a?.items?.length;return(0,ir.jsxs)(vo,{direction:"column",className:We(jr.header,m&&jr["has-navigation"]),children:[(0,ir.jsxs)(vo,{className:jr["header-content"],direction:"row",gap:"sm",justify:"space-between",children:[(0,ir.jsxs)(vo,{direction:"row",gap:"sm",align:"center",justify:"start",className:jr["header-lockup"],children:[l&&(0,ir.jsx)(Xm,{bubblesVirtually:!0,className:jr["sidebar-toggle-slot"]}),o&&(0,ir.jsx)("div",{className:jr["header-visual"],"aria-hidden":"true",children:o}),n&&(0,ir.jsx)(wn,{className:jr["header-title"],render:(0,ir.jsx)(c,{}),variant:"heading-lg",children:n}),t,r]}),s&&(0,ir.jsx)(vo,{align:"center",className:jr["header-actions"],direction:"row",gap:"sm",children:s})]}),i&&(0,ir.jsx)(wn,{render:(0,ir.jsx)("p",{}),variant:"body-md",className:jr["header-subtitle"],children:i}),m&&(0,ir.jsx)(Gm,{...a,linkComponent:u?.link,className:jr["header-navigation"]})]})}var fi=f(Z(),1),pc="data-wp-hash";function mc(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&C1(document)),e.__wpStyleRuntime}function _1(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${pc}]`))if(r.getAttribute(pc)===t)return!0;return!1}function Qm(e,t,r){if(!e.head)return;let o=mc(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(_1(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(pc,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function C1(e){let t=mc();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)Qm(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function R1(e,t){let r=mc();r.styles.set(e,t);for(let o of r.documents.keys())Qm(o,e,t)}typeof process>"u",R1("1f3750277d","._956b6df0898efed0__page{text-wrap:pretty;background-color:var(--wpds-color-background-surface-neutral,#fcfcfc);color:var(--wpds-color-foreground-content-neutral,#1e1e1e);display:flex;flex-flow:column;height:100%;position:relative;z-index:1}._0625b55e82a0d93d__header{background:var(--wpds-color-background-surface-neutral-strong,#fff);border-block-end:var(--wpds-border-width-xs,1px) solid var(--wpds-color-stroke-surface-neutral-weak,#f0f0f0);inset-block-start:0;padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px);position:sticky;z-index:1}.a43c44d5ae28b2e8__header-content{min-height:var(--wpds-dimension-size-md,32px)}.b7cb5b9daf3a3b25__header-actions{flex-shrink:0}._8bcd33103b451f30__header-lockup{min-width:0}._8113be94e7caf73c__header-title{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._9a776c7f70996f61__header-visual{display:grid;flex-shrink:0;grid-template-columns:1fr;grid-template-rows:1fr;height:var(--wpds-dimension-size-sm,24px);width:var(--wpds-dimension-size-sm,24px);>*{grid-column:1/-1;grid-row:1/-1;max-height:100%;max-width:100%}}.d5e0920cd15d35bc__sidebar-toggle-slot:empty{display:none}._60fea2f6bf5319cd__header-subtitle{color:var(--wpds-color-foreground-content-neutral-weak,#707070);padding-block-end:var(--wpds-dimension-padding-xs,4px)}._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation,._0625b55e82a0d93d__header._4b0f17e503d11619__has-navigation ._60fea2f6bf5319cd__header-subtitle{padding-block-end:0}._673c99dcbfb58211__header-navigation{margin-block-start:var(--wpds-dimension-gap-md,12px)}.be5e57d029ec4036__content{display:flex;flex-direction:column;flex-grow:1;overflow:auto;&._128806d0b26e3a50__has-padding{padding:var(--wpds-dimension-padding-lg,16px) var(--wpds-dimension-padding-2xl,24px)}}");var dc={page:"_956b6df0898efed0__page",header:"_0625b55e82a0d93d__header","header-content":"a43c44d5ae28b2e8__header-content","header-actions":"b7cb5b9daf3a3b25__header-actions","header-lockup":"_8bcd33103b451f30__header-lockup","header-title":"_8113be94e7caf73c__header-title","header-visual":"_9a776c7f70996f61__header-visual","sidebar-toggle-slot":"d5e0920cd15d35bc__sidebar-toggle-slot","header-subtitle":"_60fea2f6bf5319cd__header-subtitle","has-navigation":"_4b0f17e503d11619__has-navigation","header-navigation":"_673c99dcbfb58211__header-navigation",content:"be5e57d029ec4036__content","has-padding":"_128806d0b26e3a50__has-padding"};function $m({headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,children:s,className:a,actions:u,navigation:l,components:c,ariaLabel:m,hasPadding:d=!1,showSidebarToggle:h=!0}){let g=We(dc.page,a);return(0,fi.jsxs)(Hm,{className:g,ariaLabel:m??(typeof n=="string"?n:""),children:[(n||t||r||u||o||!!l?.items?.length)&&(0,fi.jsx)(Jm,{headingLevel:e,breadcrumbs:t,badges:r,visual:o,title:n,subTitle:i,actions:u,navigation:l,components:c,showSidebarToggle:h}),d?(0,fi.jsx)("div",{className:We(dc.content,dc["has-padding"]),children:s}):s]})}$m.SidebarToggleFill=Zm;var hc=$m;var zn=f(ge()),Av=f(ue()),Iv=f(th()),Ra=f(sr()),Lv=f(Kt()),Nv=f(Te());var Ov=f(ue(),1),kv=f(Cn(),1),xE=f(Kt(),1),SE=f(Dt(),1),Tu=f(Te(),1),_E=f(yo(),1);function Rn(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let i of t){let s=n[i];n=n[i]=Array.isArray(s)?[...s]:{...s}}return n[o]=r,e}var ht=(e,t,r)=>{let o=Array.isArray(t)?t:t.split("."),n=e;return o.forEach(i=>{n=n?.[i]}),n??r};var E1=["appearanceTools","useRootPaddingAwareAlignments","background.backgroundImage","background.backgroundRepeat","background.backgroundSize","background.backgroundPosition","background.gradient","border.color","border.radius","border.radiusSizes","border.style","border.width","shadow.presets","shadow.defaultPresets","color.background","color.button","color.caption","color.custom","color.customDuotone","color.customGradient","color.defaultDuotone","color.defaultGradients","color.defaultPalette","color.duotone","color.gradients","color.heading","color.link","color.palette","color.text","custom","dimensions.aspectRatio","dimensions.height","dimensions.minHeight","dimensions.minWidth","dimensions.width","dimensions.dimensionSizes","layout.contentSize","layout.definitions","layout.wideSize","lightbox.enabled","lightbox.allowEditing","position.fixed","position.sticky","spacing.customSpacingSize","spacing.defaultSpacingSizes","spacing.spacingSizes","spacing.spacingScale","spacing.blockGap","spacing.margin","spacing.padding","spacing.units","typography.fluid","typography.customFontSize","typography.defaultFontSizes","typography.dropCap","typography.fontFamilies","typography.fontSizes","typography.fontStyle","typography.fontWeight","typography.letterSpacing","typography.lineHeight","typography.textAlign","typography.textColumns","typography.textDecoration","typography.textIndent","typography.textTransform","typography.writingMode","viewport.mobile","viewport.tablet"];function gc(e,t,r){let o=r?".blocks."+r:"",n=t?"."+t:"",i=`settings${o}${n}`,s=`settings${n}`;if(t)return ht(e,i)??ht(e,s);let a={};return E1.forEach(u=>{let l=ht(e,`settings${o}.${u}`)??ht(e,`settings.${u}`);l!==void 0&&(a=Rn(a,u.split("."),l))}),a}function yc(e,t,r,o){let n=o?".blocks."+o:"",i=t?"."+t:"",s=`settings${n}${i}`;return Rn(e,s.split("."),r)}var uh=f(ah(),1);var T1="1600px",P1="320px",O1=1,k1=.25,F1=.75,A1="14px";function lh({minimumFontSize:e,maximumFontSize:t,fontSize:r,minimumViewportWidth:o=P1,maximumViewportWidth:n=T1,scaleFactor:i=O1,minimumFontSizeLimit:s}){if(s=zr(s)?s:A1,r){let v=zr(r);if(!v?.unit||!v?.value)return null;let C=zr(s,{coerceTo:v.unit});if(C?.value&&!e&&!t&&v?.value<=C?.value)return null;if(t||(t=`${v.value}${v.unit}`),!e){let k=v.unit==="px"?v.value:v.value*16,E=Math.min(Math.max(1-.075*Math.log2(k),k1),F1),T=di(v.value*E,3);C?.value&&T0}function I1(e){let t=e?.typography??{},r=e?.layout,o=zr(r?.wideSize)?r?.wideSize:null;return vc(t)&&o?{fluid:{maxViewportWidth:o,...typeof t.fluid=="object"?t.fluid:{}}}:{fluid:t?.fluid}}function ch(e,t){let{size:r}=e;if(!r||r==="0"||e?.fluid===!1||!vc(t?.typography)&&!vc(e))return r;let o=I1(t)?.fluid??{},n=lh({minimumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.min,maximumFontSize:typeof e?.fluid=="boolean"?void 0:e?.fluid?.max,fontSize:r,minimumFontSizeLimit:typeof o=="object"?o?.minFontSize:void 0,maximumViewportWidth:typeof o=="object"?o?.maxViewportWidth:void 0,minimumViewportWidth:typeof o=="object"?o?.minViewportWidth:void 0});return n||r}var L1=[{path:["color","palette"],valueKey:"color",cssVarInfix:"color",classes:[{classSuffix:"color",propertyName:"color"},{classSuffix:"background-color",propertyName:"background-color"},{classSuffix:"border-color",propertyName:"border-color"}]},{path:["color","gradients"],valueKey:"gradient",cssVarInfix:"gradient",classes:[{classSuffix:"gradient-background",propertyName:"background"}]},{path:["color","duotone"],valueKey:"colors",cssVarInfix:"duotone",valueFunc:({slug:e})=>`url( '#wp-duotone-${e}' )`,classes:[]},{path:["shadow","presets"],valueKey:"shadow",cssVarInfix:"shadow",classes:[]},{path:["typography","fontSizes"],valueFunc:(e,t)=>ch(e,t),valueKey:"size",cssVarInfix:"font-size",classes:[{classSuffix:"font-size",propertyName:"font-size"}]},{path:["typography","fontFamilies"],valueKey:"fontFamily",cssVarInfix:"font-family",classes:[{classSuffix:"font-family",propertyName:"font-family"}]},{path:["spacing","spacingSizes"],valueKey:"size",cssVarInfix:"spacing",valueFunc:({size:e})=>e,classes:[]},{path:["border","radiusSizes"],valueKey:"size",cssVarInfix:"border-radius",classes:[]},{path:["dimensions","dimensionSizes"],valueKey:"size",cssVarInfix:"dimension",classes:[]}];function N1(e,t){if(!e||!t)return e;if(typeof e=="object"&&"ref"in e&&e?.ref){let r=(0,uh.getCSSValueFromRawStyle)(ht(t,e.ref));return typeof r=="object"&&r!==null&&"ref"in r&&r?.ref?void 0:r===void 0?e:r}return e}function M1(e,t){if(!e||!t||!Array.isArray(t))return e;let r=t.find(o=>o?.name===e);return r?.href?r?.href:e}function bc(e,t){if(!e||!t)return e;let r=N1(e,t);return typeof r=="object"&&r!==null&&"url"in r&&r?.url?{...r,url:M1(r.url,t?._links?.["wp:theme-file"])}:r}function fh(e,t,r=[],o="slug",n){let i=[t?ht(e,["blocks",t,...r]):void 0,ht(e,r)].filter(Boolean);for(let s of i)if(s){let a=["custom","theme","default"];for(let u of a){let l=s[u];if(l){let c=l.find(m=>m[o]===n);if(c)return o==="slug"||fh(e,t,r,"slug",c.slug)[o]===c[o]?c:void 0}}}}function V1(e,t,r,[o,n]=[]){let i=L1.find(a=>a.cssVarInfix===o);if(!i||!e.settings)return r;let s=fh(e.settings,t,i.path,"slug",n);if(s){let{valueKey:a}=i,u=s[a];return Ms(e,t,u)}return r}function D1(e,t,r,o=[]){let n=(t?ht(e?.settings??{},["blocks",t,"custom",...o]):void 0)??ht(e?.settings??{},["custom",...o]);return n?Ms(e,t,n):r}function Ms(e,t,r){if(!r||typeof r!="string")if(typeof r=="object"&&r!==null&&"ref"in r&&typeof r.ref=="string"){let l=ht(e,r.ref);if(!l||typeof l=="object"&&"ref"in l)return l;r=l}else return r;let o="var:",n="var(--wp--",i=")",s;if(r.startsWith(o))s=r.slice(o.length).split("|");else if(r.startsWith(n)&&r.endsWith(i))s=r.slice(n.length,-i.length).split("--");else return r;let[a,...u]=s;return a==="preset"?V1(e,t,r,u):a==="custom"?D1(e,t,r,u):r}function Vs(e,t,r,o=!0){let n=t?"."+t:"",i=r?`styles.blocks.${r}${n}`:`styles${n}`;if(!e)return;let s=ht(e,i),a=void 0;if(s===void 0&&a){let l=!0,c=e;for(let m of i.split(".")){if(!c||typeof c!="object"||!Object.hasOwn(c,m)){l=!1;break}c=c[m]}l||(s=ht(e,a))}return o?Ms(e,r,s):s}function wc(e,t,r,o){let n=t?"."+t:"",i=o?`styles.blocks.${o}${n}`:`styles${n}`;return Rn(e,i.split("."),r)}var xc=f(ph(),1);function pi(e,t){return typeof e!="object"||typeof t!="object"?e===t:(0,xc.default)(e?.styles,t?.styles)&&(0,xc.default)(e?.settings,t?.settings)}var wh=f(yh(),1);function vh(e){return Object.prototype.toString.call(e)==="[object Object]"}function bh(e){var t,r;return vh(e)===!1?!1:(t=e.constructor,t===void 0?!0:(r=t.prototype,!(vh(r)===!1||r.hasOwnProperty("isPrototypeOf")===!1)))}function Go(e,t){return(0,wh.default)(e,t,{isMergeableObject:bh,customMerge:r=>{if(r==="backgroundImage")return(o,n)=>n??o}})}var Q1={grad:.9,turn:360,rad:360/(2*Math.PI)},Jr=function(e){return typeof e=="string"?e.length>0:typeof e=="number"},bt=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=Math.pow(10,t)),Math.round(r*e)/r+0},fr=function(e,t,r){return t===void 0&&(t=0),r===void 0&&(r=1),e>r?r:e>t?e:t},Oh=function(e){return(e=isFinite(e)?e%360:0)>0?e:e+360},xh=function(e){return{r:fr(e.r,0,255),g:fr(e.g,0,255),b:fr(e.b,0,255),a:fr(e.a)}},Sc=function(e){return{r:bt(e.r),g:bt(e.g),b:bt(e.b),a:bt(e.a,3)}},$1=/^#([0-9a-f]{3,8})$/i,Ds=function(e){var t=e.toString(16);return t.length<2?"0"+t:t},kh=function(e){var t=e.r,r=e.g,o=e.b,n=e.a,i=Math.max(t,r,o),s=i-Math.min(t,r,o),a=s?i===t?(r-o)/s:i===r?2+(o-t)/s:4+(t-r)/s:0;return{h:60*(a<0?a+6:a),s:i?s/i*100:0,v:i/255*100,a:n}},Fh=function(e){var t=e.h,r=e.s,o=e.v,n=e.a;t=t/360*6,r/=100,o/=100;var i=Math.floor(t),s=o*(1-r),a=o*(1-(t-i)*r),u=o*(1-(1-t+i)*r),l=i%6;return{r:255*[o,a,s,s,u,o][l],g:255*[u,o,o,a,s,s][l],b:255*[s,s,u,o,o,a][l],a:n}},Sh=function(e){return{h:Oh(e.h),s:fr(e.s,0,100),l:fr(e.l,0,100),a:fr(e.a)}},_h=function(e){return{h:bt(e.h),s:bt(e.s),l:bt(e.l),a:bt(e.a,3)}},Ch=function(e){return Fh((r=(t=e).s,{h:t.h,s:(r*=((o=t.l)<50?o:100-o)/100)>0?2*r/(o+r)*100:0,v:o+r,a:t.a}));var t,r,o},hi=function(e){return{h:(t=kh(e)).h,s:(n=(200-(r=t.s))*(o=t.v)/100)>0&&n<200?r*o/100/(n<=100?n:200-n)*100:0,l:n/2,a:t.a};var t,r,o,n},ex=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,tx=/^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,rx=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,ox=/^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i,Rh={string:[[function(e){var t=$1.exec(e);return t?(e=t[1]).length<=4?{r:parseInt(e[0]+e[0],16),g:parseInt(e[1]+e[1],16),b:parseInt(e[2]+e[2],16),a:e.length===4?bt(parseInt(e[3]+e[3],16)/255,2):1}:e.length===6||e.length===8?{r:parseInt(e.substr(0,2),16),g:parseInt(e.substr(2,2),16),b:parseInt(e.substr(4,2),16),a:e.length===8?bt(parseInt(e.substr(6,2),16)/255,2):1}:null:null},"hex"],[function(e){var t=rx.exec(e)||ox.exec(e);return t?t[2]!==t[4]||t[4]!==t[6]?null:xh({r:Number(t[1])/(t[2]?100/255:1),g:Number(t[3])/(t[4]?100/255:1),b:Number(t[5])/(t[6]?100/255:1),a:t[7]===void 0?1:Number(t[7])/(t[8]?100:1)}):null},"rgb"],[function(e){var t=ex.exec(e)||tx.exec(e);if(!t)return null;var r,o,n=Sh({h:(r=t[1],o=t[2],o===void 0&&(o="deg"),Number(r)*(Q1[o]||1)),s:Number(t[3]),l:Number(t[4]),a:t[5]===void 0?1:Number(t[5])/(t[6]?100:1)});return Ch(n)},"hsl"]],object:[[function(e){var t=e.r,r=e.g,o=e.b,n=e.a,i=n===void 0?1:n;return Jr(t)&&Jr(r)&&Jr(o)?xh({r:Number(t),g:Number(r),b:Number(o),a:Number(i)}):null},"rgb"],[function(e){var t=e.h,r=e.s,o=e.l,n=e.a,i=n===void 0?1:n;if(!Jr(t)||!Jr(r)||!Jr(o))return null;var s=Sh({h:Number(t),s:Number(r),l:Number(o),a:Number(i)});return Ch(s)},"hsl"],[function(e){var t=e.h,r=e.s,o=e.v,n=e.a,i=n===void 0?1:n;if(!Jr(t)||!Jr(r)||!Jr(o))return null;var s=(function(a){return{h:Oh(a.h),s:fr(a.s,0,100),v:fr(a.v,0,100),a:fr(a.a)}})({h:Number(t),s:Number(r),v:Number(o),a:Number(i)});return Fh(s)},"hsv"]]},Eh=function(e,t){for(var r=0;r=.5},e.prototype.toHex=function(){return t=Sc(this.rgba),r=t.r,o=t.g,n=t.b,s=(i=t.a)<1?Ds(bt(255*i)):"","#"+Ds(r)+Ds(o)+Ds(n)+s;var t,r,o,n,i,s},e.prototype.toRgb=function(){return Sc(this.rgba)},e.prototype.toRgbString=function(){return t=Sc(this.rgba),r=t.r,o=t.g,n=t.b,(i=t.a)<1?"rgba("+r+", "+o+", "+n+", "+i+")":"rgb("+r+", "+o+", "+n+")";var t,r,o,n,i},e.prototype.toHsl=function(){return _h(hi(this.rgba))},e.prototype.toHslString=function(){return t=_h(hi(this.rgba)),r=t.h,o=t.s,n=t.l,(i=t.a)<1?"hsla("+r+", "+o+"%, "+n+"%, "+i+")":"hsl("+r+", "+o+"%, "+n+"%)";var t,r,o,n,i},e.prototype.toHsv=function(){return t=kh(this.rgba),{h:bt(t.h),s:bt(t.s),v:bt(t.v),a:bt(t.a,3)};var t},e.prototype.invert=function(){return Cr({r:255-(t=this.rgba).r,g:255-t.g,b:255-t.b,a:t.a});var t},e.prototype.saturate=function(t){return t===void 0&&(t=.1),Cr(_c(this.rgba,t))},e.prototype.desaturate=function(t){return t===void 0&&(t=.1),Cr(_c(this.rgba,-t))},e.prototype.grayscale=function(){return Cr(_c(this.rgba,-1))},e.prototype.lighten=function(t){return t===void 0&&(t=.1),Cr(Th(this.rgba,t))},e.prototype.darken=function(t){return t===void 0&&(t=.1),Cr(Th(this.rgba,-t))},e.prototype.rotate=function(t){return t===void 0&&(t=15),this.hue(this.hue()+t)},e.prototype.alpha=function(t){return typeof t=="number"?Cr({r:(r=this.rgba).r,g:r.g,b:r.b,a:t}):bt(this.rgba.a,3);var r},e.prototype.hue=function(t){var r=hi(this.rgba);return typeof t=="number"?Cr({h:t,s:r.s,l:r.l,a:r.a}):bt(r.h)},e.prototype.isEqual=function(t){return this.toHex()===Cr(t).toHex()},e})(),Cr=function(e){return e instanceof Ph?e:new Ph(e)};function ix(e=[]){let t={r:[],g:[],b:[],a:[]};return e.forEach(r=>{let o=Cr(r).toRgb();t.r.push(o.r/255),t.g.push(o.g/255),t.b.push(o.b/255),t.a.push(o.a)}),t}function Ah(e){return`${e}{filter:none}`}function Ih(e,t){return`${e}{filter:url(#${t})}`}function Lh(e,t){let r=ix(t);return` -`}var zh={mobile:"480px",tablet:"782px"},Hh=/^(\d+|\d*\.\d+)(px|em|rem)$/,fx=16;function dx(e){return"mobile"in e||"tablet"in e}function px(e){return!e||typeof e!="object"?{}:dx(e)?e:e.settings?.viewport??{}}function mx(e){return typeof e=="string"&&Hh.test(e.trim())}function Tc(e){if(typeof e=="number")return e;if(typeof e!="string")return;let t=e.trim().match(Hh);if(!t)return;let r=Number.parseFloat(t[1]);return t[2]==="px"?r:r*fx}function Pc(e){let t=px(e),r={},o={};Object.keys(zh).forEach(a=>{let u=a,l=t[u],c=Tc(l);c!==void 0&&mx(l)&&(r[u]=l.trim(),o[u]=c)});let n=Object.keys(r);if(!n.length)return{...zh};if(n.length===1)return r;let i=r.mobile,s=r.tablet;return o.mobile>=o.tablet?{mobile:i}:{mobile:i,tablet:s}}function Uh(e){let t=Pc(e),r={};return t.mobile&&(r["@mobile"]=`@media (width <= ${t.mobile})`),t.tablet&&(r["@tablet"]=t.mobile?`@media (${t.mobile} < width <= ${t.tablet})`:`@media (width <= ${t.tablet})`),r}function Bs(e,t,r,{resolveRefs:o=!0}={}){if(!e?.styles?.blocks?.[t]?.variations?.[r])return;let n=s=>{Object.keys(s).forEach(a=>{let u=s[a];if(typeof u=="object"&&u!==null)if(u.ref!==void 0)if(typeof u.ref!="string"||u.ref.trim()==="")delete s[a];else{let l=ht(e,u.ref);l!=null?s[a]=l:delete s[a]}else n(u),Object.keys(u).length===0&&delete s[a]})},i=JSON.parse(JSON.stringify(e.styles.blocks[t].variations[r]));return o&&n(i),i}var Fc="default";function qh(e){let t=e?.viewport,r=e?.pseudoState;return(!t||t===Fc)&&(!r||r===Fc)}function hx(e){return qh(e)?[]:[e.viewport,e.pseudoState].filter(t=>!!t&&t!==Fc)}function gx(e,t){let r=hx(t);return r.length?ht(e,r):e}var yx=new Set(["blocks","variations","css"]),Oc=Object.freeze({value:{},sources:{}}),vx={root:{layer:"root"},element:{layer:"element"},block:{layer:"block"},blockVariation:{layer:"blockVariation"}};function wo(e){let t=vx[e];return t?{...t}:null}function xo(e,t){return!e||!t?null:{styles:e,source:t}}function bx(e){return e.join(".")}function wx(e){return{...e}}function Zh(e){return e===""||e===null||typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0}function kc(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&typeof e.ref=="string"}function So(e){if(!e||typeof e!="object"||Array.isArray(e))return null;let t={};for(let r of Object.keys(e))if(!yx.has(r)){if(r==="elements"){e.elements&&typeof e.elements=="object"&&(t.elements=e.elements);continue}Zh(e[r])||(t[r]=e[r])}return Object.keys(t).length===0?null:t}var Wh=new Set(["backgroundImage"]);function Xh(e,t,r,o,n,i=[]){if(!t||typeof t!="object"||Array.isArray(t))return e;for(let s of Object.keys(t)){let a=t[s];if(Zh(a))continue;if(kc(a)){if(a.ref.trim()==="")continue;let l=ht(r,a.ref);if(l==null||kc(l))continue;a=l}let u=[...i,s];if(!Wh.has(s)&&a!==null&&typeof a=="object"&&!Array.isArray(a)&&!kc(a)){let l=e[s]&&typeof e[s]=="object"&&!Array.isArray(e[s])?e[s]:{};e[s]=Xh({...l},a,r,o,n,u)}else e[s]=Wh.has(s)&&a!==null&&typeof a=="object"&&!Array.isArray(a)?{...a}:a,o&&n&&(n[bx(u)]=wx(o))}return e}function js(e,t){if(!e)return null;let r=gx(e,t);return r&&typeof r=="object"&&!Array.isArray(r)?r:null}var xx=["color.background","color.gradient","background","spacing","dimensions","border","shadow","filter"];function Sx(e){return e.startsWith("elements.")?!1:xx.some(t=>e===t||e.startsWith(`${t}.`))}function Kh(e,t){if(!e||typeof e!="object")return;let[r,...o]=t;if(o.length===0){delete e[r];return}let n=e[r];n&&typeof n=="object"&&(Kh(n,o),Object.keys(n).length===0&&delete e[r])}function Cx(e,t){for(let r of Object.keys(t))t[r].layer==="root"&&Sx(r)&&(Kh(e,r.split(".")),delete t[r])}function _x(e,t,r){let o=e?.background?.backgroundImage;if(!o)return;let n=gh(o,{...t,_links:r??void 0});n!==void 0&&(e.background.backgroundImage=n)}function Gh(e,{blockName:t,variationName:r=null,elements:o=null,viewport:n=null,pseudoState:i=null}={}){if(!e||!e.styles||!t)return Oc;let s=e.styles,a={viewport:n,pseudoState:i},u=s,l=s.blocks?.[t]??null,c=(o??[]).map(w=>s.elements?.[w]??null).filter(w=>!!w),m=r?Bs(e,t,r)??null:null,d=[xo(So(u),wo("root")),...c.map(w=>xo(So(w),wo("element"))),l?xo(So(l),wo("block")):null,m?xo(So(m),wo("blockVariation")):null];qh(a)||d.push(xo(So(js(u,a)),wo("root")),...c.map(w=>xo(So(js(w,a)),wo("element"))),l?xo(So(js(l,a)),wo("block")):null,m?xo(So(js(m,a)),wo("blockVariation")):null);let h=d.filter(Boolean);if(h.length===0)return Oc;let g={},b=h.reduce((w,C)=>Xh(w,C.styles,e,C.source,g),{});return Cx(b,g),_x(b,e,e._links??null),{value:b,sources:g}}var Rx={},Yh=new WeakMap;function Jh(e,t={}){let r=e?.styles;if(!r||typeof r!="object")return Gh(e,t);let o=Yh.get(r);o||(o=new WeakMap,Yh.set(r,o));let n=e?._links??Rx,i=o.get(n);i||(i=new Map,o.set(n,i));let s=`${t.elements?.join(",")??""}:${t.viewport??""}:${t.pseudoState??""}`,a=(t.blockName||"")+""+(t.variationName||"")+""+s;if(i.has(a))return i.get(a);let u=Gh(e,t);return i.set(a,u),u}var Qh=f(li(),1),{lock:$h,unlock:vI}=(0,Qh.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-engine");var Tn={};$h(Tn,{getResponsiveMediaQueries:Uh,getViewportBreakpoints:Pc,getViewportBreakpointValueInPixels:Tc,getDuotoneFilter:jh,getDuotoneStylesheet:Bh,getDuotoneUnsetStylesheet:Dh,resolveStyle:Jh,getVariationStyle:Bs});var Ac=f(Te(),1);var eg=f(Te(),1),gt=(0,eg.createContext)({user:{styles:{},settings:{}},base:{styles:{},settings:{}},merged:{styles:{},settings:{}},onChange:()=>{},fontLibraryEnabled:!1});var tg=f(Z(),1);function gi({children:e,value:t,baseValue:r,onChange:o,fontLibraryEnabled:n}){let i=(0,Ac.useMemo)(()=>Go(r,t),[r,t]),s=(0,Ac.useMemo)(()=>({user:t,base:r,merged:i,onChange:o,fontLibraryEnabled:n}),[t,r,i,o,n]);return(0,tg.jsx)(gt.Provider,{value:s,children:e})}var eo=f(ue(),1),bg=f(ge(),1);var Bx=f(Kt(),1),jx=f(sr(),1);var rg=f(Z(),1);function Ic({className:e,...t}){return(0,rg.jsx)(ai,{className:We(e,"global-styles-ui-icon-with-current-color"),...t})}var Co=f(ue(),1);var Yo=f(Z(),1);function Ex({icon:e,children:t,...r}){return(0,Yo.jsxs)(Co.__experimentalItem,{...r,children:[e&&(0,Yo.jsxs)(Co.__experimentalHStack,{justify:"flex-start",children:[(0,Yo.jsx)(Ic,{icon:e,size:24}),(0,Yo.jsx)(Co.FlexItem,{children:t})]}),!e&&t]})}function Qr(e){return(0,Yo.jsx)(Co.Navigator.Button,{as:Ex,...e})}var Ox=f(ue(),1);var kx=f(ge(),1),cg=f(Dt(),1);var Lc=function(e){var t=e/255;return t<.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)},Nc=function(e){return .2126*Lc(e.r)+.7152*Lc(e.g)+.0722*Lc(e.b)};function og(e){e.prototype.luminance=function(){return t=Nc(this.rgba),(r=2)===void 0&&(r=0),o===void 0&&(o=Math.pow(10,r)),Math.round(o*t)/o+0;var t,r,o},e.prototype.contrast=function(t){t===void 0&&(t="#FFF");var r,o,n,i,s,a,u,l=t instanceof e?t:new e(t);return i=this.rgba,s=l.toRgb(),a=Nc(i),u=Nc(s),r=a>u?(a+.05)/(u+.05):(u+.05)/(a+.05),(o=2)===void 0&&(o=0),n===void 0&&(n=Math.pow(10,o)),Math.floor(n*r)/n+0},e.prototype.isReadable=function(t,r){return t===void 0&&(t="#FFF"),r===void 0&&(r={}),this.contrast(t)>=(a=(s=(o=r).size)===void 0?"normal":s,(i=(n=o.level)===void 0?"AA":n)==="AAA"&&a==="normal"?7:i==="AA"&&a==="large"?3:4.5);var o,n,i,s,a}}var Rr=f(Te(),1),ag=f(Kt(),1),lg=f(sr(),1),Vc=f(ge(),1);var dt=f(ge(),1);var ng=f(li(),1),{lock:WI,unlock:Ve}=(0,ng.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-ui");var{getViewportBreakpoints:ZI}=Ve(Tn),XI={link:[{value:":link",label:(0,dt.__)("Link")},{value:":any-link",label:(0,dt.__)("Any Link")},{value:":visited",label:(0,dt.__)("Visited")},{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}],button:[{value:":link",label:(0,dt.__)("Link")},{value:":any-link",label:(0,dt.__)("Any Link")},{value:":visited",label:(0,dt.__)("Visited")},{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}]},KI={"core/button":[{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}]},JI=[{value:"@tablet",label:(0,dt.__)("Tablet")},{value:"@mobile",label:(0,dt.__)("Mobile")}];function Mc(e,t){if(!t?.length||typeof e!="object"||!e||!Object.keys(e).length)return e;for(let r in e)t.includes(r)?delete e[r]:typeof e[r]=="object"&&Mc(e[r],t);return e}var zs=(e,t)=>{if(!e||!t?.length)return{};let r={};return Object.keys(e).forEach(o=>{if(t.includes(o))r[o]=e[o];else if(typeof e[o]=="object"){let n=zs(e[o],t);Object.keys(n).length&&(r[o]=n)}}),r};function yi(e,t){let r=zs(structuredClone(e),t);return pi(r,e)}function ig(e,t){if(!Array.isArray(e)||!t)return null;let o=t.replace("var(","").replace(")","")?.split("--").slice(-1)[0];return e.find(n=>n.slug===o)}function sg(e){let t=e?.settings?.typography?.fontFamilies?.theme,r=e?.settings?.typography?.fontFamilies?.custom,o=[];t&&r?o=[...t,...r]:t?o=t:r&&(o=r);let n=e?.styles?.typography?.fontFamily,i=ig(o,n),s=e?.styles?.elements?.heading?.typography?.fontFamily,a;return s?a=ig(o,e?.styles?.elements?.heading?.typography?.fontFamily):a=i,[i,a]}Vh([og]);function qe(e,t,r="merged",o=!0,n){let{user:i,base:s,merged:a,onChange:u}=(0,Rr.useContext)(gt),l=n?.split(".").filter(Boolean)??[],c=l.find(w=>w.startsWith(":")),m=l.filter(w=>!w.startsWith(":")).join("."),d=[e,m].filter(Boolean).join("."),h=a;r==="base"?h=s:r==="user"&&(h=i);let g=(0,Rr.useMemo)(()=>{let w=Vs(h,d,t,o);return c?w?.[c]??{}:w},[h,d,t,o,c]),b=(0,Rr.useCallback)(w=>{let C=w;c&&(C={...Vs(i,d,t,!1),[c]:w});let x=wc(i,d,C,t);u(x)},[i,u,d,t,c]);return[g,b]}function Ke(e,t,r="merged"){let{user:o,base:n,merged:i,onChange:s}=(0,Rr.useContext)(gt),a=i;r==="base"?a=n:r==="user"&&(a=o);let u=(0,Rr.useMemo)(()=>yc(a,e,t),[a,e,t]),l=(0,Rr.useCallback)(c=>{let m=vc(o,e,c,t);s(m)},[o,s,e,t]);return[u,l]}var Tx=[];function Px({title:e,settings:t,styles:r}){return e===(0,Vc.__)("Default")||Object.keys(t||{}).length>0||Object.keys(r||{}).length>0}function Hs(e=[]){let{variationsFromTheme:t}=(0,ag.useSelect)(o=>({variationsFromTheme:o(lg.store).__experimentalGetCurrentThemeGlobalStylesVariations?.()||Tx}),[]),{user:r}=(0,Rr.useContext)(gt);return(0,Rr.useMemo)(()=>{let o=structuredClone(r),n=Mc(o,e);n.title=(0,Vc.__)("Default");let i=t.filter(a=>yi(a,e)).map(a=>Go(n,a)),s=[n,...i];return s?.length?s.filter(Px):[]},[e,r,t])}var Dc=f(Z(),1),{useHasDimensionsPanel:lL,useHasTypographyPanel:cL,useHasColorPanel:uL,useSettingsForBlockElement:fL,useHasBackgroundPanel:dL}=Ve(cg.privateApis);var zr=f(ue(),1);function Pn(){let[e="black"]=qe("color.text"),[t="white"]=qe("color.background"),[r=e]=qe("elements.h1.color.text"),[o=r]=qe("elements.link.color.text"),[n=o]=qe("elements.button.color.background"),[i]=Ke("color.palette.core")||[],[s]=Ke("color.palette.theme")||[],[a]=Ke("color.palette.custom")||[],u=(s??[]).concat(a??[]).concat(i??[]),l=u.filter(({color:d})=>d===e),c=u.filter(({color:d})=>d===n),m=l.concat(c).concat(u).filter(({color:d})=>d!==t).slice(0,2);return{paletteColors:u,highlightedColors:m}}var pg=f(Te(),1),mg=f(ue(),1),zc=f(ge(),1);function Fx(e,t){return t.length===0?null:(t.sort((r,o)=>Math.abs(e-r)-Math.abs(e-o)),t[0])}var Ax={normal:400,bold:700};function ug(e){return e!==void 0&&Number.isFinite(e)&&e>=1&&e<=1e3}function Bc(e){let t=String(e??"").trim().toLowerCase().split(/\s+/).filter(Boolean).map(n=>Ax[n]??Number(n)),[r,o]=t;return ug(r)?t.length!==2||!ug(o)?String(r):String(Math.min(Math.max(400,r),o)):"400"}function fg(e){let t=/^(?!generic\([ a-zA-Z\-]+\)$)(?!^[a-zA-Z\-]+$).+/,r=e.trim(),o=n=>(n=n.trim(),n.match(t)?(n=n.replace(/^["']|["']$/g,""),`"${n}"`):n);return r.includes(",")?r.split(",").map(o).filter(n=>n!=="").join(", "):o(r)}function jc(e){if(!e)return"";let t=e.trim();return t.includes(",")&&(t=(t.split(",").find(r=>r.trim()!=="")??"").trim()),t=t.replace(/^["']|["']$/g,""),window.navigator.userAgent.toLowerCase().includes("firefox")&&(t=`"${t}"`),t}function On(e){let t={fontFamily:fg(e.fontFamily)};if(!("fontFace"in e)||!Array.isArray(e.fontFace))return t.fontWeight="400",t.fontStyle="normal",t;if(e.fontFace){let r=e.fontFace.filter(o=>o?.fontStyle&&o.fontStyle.toLowerCase()==="normal");if(r.length>0){t.fontStyle="normal";let o=r.map(n=>Number(Bc(n.fontWeight)));t.fontWeight=String(Fx(400,o)??400)}else t.fontStyle=e.fontFace.length&&e.fontFace[0].fontStyle||"normal",t.fontWeight=e.fontFace.length&&Bc(e.fontFace[0].fontWeight)||"400"}return t}function dg(e){return{fontFamily:fg(e.fontFamily),fontStyle:e.fontStyle||"normal",fontWeight:Bc(e.fontWeight)}}var vi=f(Z(),1);function Us({fontSize:e,variation:t}){let{base:r}=(0,pg.useContext)(gt),o=r;t&&(o={...r,...t});let[n]=qe("color.text"),[i,s]=sg(o),a=i?On(i):{},u=s?On(s):{};return n&&(a.color=n,u.color=n),e&&(a.fontSize=e,u.fontSize=e),(0,vi.jsxs)(mg.__unstableMotion.div,{animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:.3,type:"tween"},style:{textAlign:"center",lineHeight:1},children:[(0,vi.jsx)("span",{style:u,children:(0,zc._x)("A","Uppercase letter A")}),(0,vi.jsx)("span",{style:a,children:(0,zc._x)("a","Lowercase letter A")})]})}var hg=f(ue(),1);var gg=f(Z(),1);function yg({normalizedColorSwatchSize:e,ratio:t}){let{highlightedColors:r}=Pn(),o=e*t;return r.map(({slug:n,color:i},s)=>(0,gg.jsx)(hg.__unstableMotion.div,{style:{height:o,width:o,background:i,borderRadius:o/2},animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:s===1?.2:.1}},`${n}-${s}`))}var vg=f(ue(),1),kn=f(yo(),1),qo=f(Te(),1);var $r=f(Z(),1),Hc=248,Uc=152,Ix={leading:!0,trailing:!0};function Lx({children:e,label:t,isFocused:r,withHoverView:o}){let[n="white"]=qe("color.background"),[i]=qe("color.gradient"),s=(0,kn.useReducedMotion)(),[a,u]=(0,qo.useState)(!1),[l,{width:c}]=(0,kn.useResizeObserver)(),[m,d]=(0,qo.useState)(c),[h,g]=(0,qo.useState)(),b=(0,kn.useThrottle)(d,250,Ix);(0,qo.useLayoutEffect)(()=>{c&&b(c)},[c,b]),(0,qo.useLayoutEffect)(()=>{let v=m?m/Hc:1,_=v-(h||0);(Math.abs(_)>.1||!h)&&g(v)},[m,h]);let w=c?c/Hc:1,C=h||w,x=!!c;return(0,$r.jsxs)($r.Fragment,{children:[(0,$r.jsx)("div",{style:{position:"relative"},children:l}),!x&&(0,$r.jsx)(ui,{className:"global-styles-ui-preview__wrapper",style:{aspectRatio:Hc/Uc}}),x&&(0,$r.jsx)("div",{className:We("global-styles-ui-preview__wrapper",{"is-hoverable":o}),style:{height:Uc*C},onMouseEnter:()=>u(!0),onMouseLeave:()=>u(!1),tabIndex:-1,children:(0,$r.jsx)(vg.__unstableMotion.div,{style:{height:Uc*C,width:"100%",background:i??n},initial:"start",animate:(a||r)&&!s&&t?"hover":"start",children:[].concat(e).map((v,_)=>v({ratio:C,key:_}))})})]})}var Fn=Lx;var Jt=f(Z(),1),Nx={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},Mx={hover:{opacity:1},start:{opacity:.5}},Vx={hover:{scale:1,opacity:1},start:{scale:0,opacity:0}};function Dx({label:e,isFocused:t,withHoverView:r,variation:o}){let[n]=qe("typography.fontWeight"),[i="serif"]=qe("typography.fontFamily"),[s=i]=qe("elements.h1.typography.fontFamily"),[a=n]=qe("elements.h1.typography.fontWeight"),[u="black"]=qe("color.text"),[l=u]=qe("elements.h1.color.text"),{paletteColors:c}=Pn();return(0,Jt.jsxs)(Fn,{label:e,isFocused:t,withHoverView:r,children:[({ratio:m,key:d})=>(0,Jt.jsx)(zr.__unstableMotion.div,{variants:Nx,style:{height:"100%",overflow:"hidden"},children:(0,Jt.jsxs)(zr.__experimentalHStack,{spacing:10*m,justify:"center",style:{height:"100%",overflow:"hidden"},children:[(0,Jt.jsx)(Us,{fontSize:65*m,variation:o}),(0,Jt.jsx)(zr.__experimentalVStack,{spacing:4*m,children:(0,Jt.jsx)(yg,{normalizedColorSwatchSize:32,ratio:m})})]})},d),({key:m})=>(0,Jt.jsx)(zr.__unstableMotion.div,{variants:r?Mx:void 0,style:{height:"100%",width:"100%",position:"absolute",top:0,overflow:"hidden",filter:"blur(60px)",opacity:.1},children:(0,Jt.jsx)(zr.__experimentalHStack,{spacing:0,justify:"flex-start",style:{height:"100%",overflow:"hidden"},children:c.slice(0,4).map(({color:d},h)=>(0,Jt.jsx)("div",{style:{height:"100%",background:d,flexGrow:1}},h))})},m),({ratio:m,key:d})=>(0,Jt.jsx)(zr.__unstableMotion.div,{variants:Vx,style:{height:"100%",width:"100%",overflow:"hidden",position:"absolute",top:0},children:(0,Jt.jsx)(zr.__experimentalVStack,{spacing:3*m,justify:"center",style:{height:"100%",overflow:"hidden",padding:10*m,boxSizing:"border-box"},children:e&&(0,Jt.jsx)("div",{style:{fontSize:40*m,fontFamily:s,color:l,fontWeight:a,lineHeight:"1em",textAlign:"center"},children:e})})},d)]})}var Wc=Dx;var wg=f(Z(),1);var qc=f(_n(),1),Ro=f(ge(),1),Hr=f(ue(),1);var Zc=f(Kt(),1),pr=f(Te(),1),Ws=f(Dt(),1),Eg=f(yo(),1);import{speak as Wx}from"@wordpress/a11y";var xg=f(_n(),1),Sg=f(Kt(),1),zx=f(ue(),1);var Hx=f(Z(),1);function Ux(e,t){return e?.filter(r=>r.source==="block"||t.includes(r.name))||[]}function Gc(e){let t=(0,Sg.useSelect)(n=>{let{getBlockStyles:i}=n(xg.store);return i(e)},[e]),[r]=qe("variations",e),o=Object.keys(r??{});return Ux(t,o)}var _o=f(ue(),1),Cg=f(ge(),1);var _g=f(Dt(),1);var Rg=f(Z(),1),{StateControl:WL,StateControlBadges:GL}=Ve(_g.privateApis);var Bt=f(Z(),1),{useHasDimensionsPanel:Gx,useHasTypographyPanel:Yx,useHasBorderPanel:qx,useSettingsForBlockElement:Zx,useHasColorPanel:Xx,useHasBackgroundPanel:Kx}=Ve(Ws.privateApis),{Menu:tN}=Ve(Hr.privateApis);function Yc(e){return e==null?!1:Array.isArray(e)?e.length>0:typeof e=="object"?Object.values(e).some(Yc):!0}function Jx(e,t){return Yc(e?.styles?.blocks?.[t])||Yc(e?.settings?.blocks?.[t])}function Qx(){let e=(0,Zc.useSelect)(n=>n(qc.store).getBlockTypes(),[]),t=(n,i)=>{let{core:s,noncore:a}=n;return(i.name.startsWith("core/")?s:a).push(i),n},{core:r,noncore:o}=e.reduce(t,{core:[],noncore:[]});return[...r,...o]}function $x(e){let[t]=Ke("",e),r=Zx(t,e),o=Yx(r),n=Xx(r),i=Kx(r),s=qx(r),a=Gx(r),u=s||a,l=!!Gc(e)?.length;return o||n||i||u||l}function eS({block:e,isCustomized:t}){return $x(e.name)?(0,Bt.jsx)(Qr,{path:"/blocks/"+encodeURIComponent(e.name),children:(0,Bt.jsxs)(Hr.__experimentalHStack,{justify:"flex-start",spacing:2,children:[(0,Bt.jsx)(Ws.BlockIcon,{className:"global-styles-ui-block-types-item__icon",icon:e.icon}),(0,Bt.jsx)(Hr.FlexItem,{children:e.title}),t&&(0,Bt.jsxs)(Bt.Fragment,{children:[(0,Bt.jsx)(ec,{children:(0,Ro.__)("Has custom styles")}),(0,Bt.jsx)("span",{"aria-hidden":"true",className:"global-styles-ui-block-types-item__indicator"})]})]})}):null}function tS({filterValue:e,styleFilter:t}){let r=t==="customized"&&!e?(0,Ro.__)("You haven't customized any blocks yet."):(0,Ro.__)("No blocks found.");return(0,Bt.jsx)(Hr.__experimentalText,{align:"center",as:"p",className:"global-styles-ui-block-types-item-list__no-results",children:r})}function rS({filterValue:e,styleFilter:t}){let r=Qx(),o=(0,Eg.useDebounce)(Wx,500),{isMatchingSearchTerm:n}=(0,Zc.useSelect)(qc.store),{user:i}=(0,pr.useContext)(gt),s=(0,pr.useMemo)(()=>{let m=new Set;return[...Object.keys(i?.styles?.blocks??{}),...Object.keys(i?.settings?.blocks??{})].forEach(h=>{Jx(i,h)&&m.add(h)}),m},[i]),a=e?r.filter(m=>n(m,e)):r,u=t==="customized"?a.filter(m=>s.has(m.name)):a,l=(0,pr.useRef)(null),c=u.length>0;return(0,pr.useEffect)(()=>{if(!e&&t==="all")return;let m=c&&l.current?.childElementCount||0,d=(0,Ro.sprintf)((0,Ro._n)("%d result found.","%d results found.",m),m);o(d,"polite")},[e,t,c,o]),(0,Bt.jsx)("div",{ref:l,className:"global-styles-ui-block-types-item-list",role:"list",children:u.length===0?(0,Bt.jsx)(tS,{filterValue:e,styleFilter:t}):u.map(m=>(0,Bt.jsx)(eS,{block:m,isCustomized:s.has(m.name)},"menu-itemblock-"+m.name))})}var rN=(0,pr.memo)(rS);var aS=f(_n(),1),kg=f(Dt(),1),Xc=f(Te(),1),lS=f(Kt(),1),cS=f(sr(),1),Kc=f(ue(),1),Fg=f(ge(),1);var oS=f(Dt(),1),Tg=f(_n(),1),nS=f(ue(),1),iS=f(Te(),1);var sS=f(Z(),1),{getViewportBreakpoints:cN,getViewportBreakpointValueInPixels:uN}=Ve(Tn);var Pg=f(ue(),1),Og=f(Z(),1);function Er({children:e,level:t=2}){return(0,Og.jsx)(Pg.__experimentalHeading,{className:"global-styles-ui-subtitle",level:t,children:e})}var Jc=f(Z(),1);var{useHasDimensionsPanel:RN,useHasTypographyPanel:EN,useHasBorderPanel:TN,useSettingsForBlockElement:PN,useHasColorPanel:ON,useHasFiltersPanel:kN,useHasImageSettingsPanel:FN,useHasBackgroundPanel:AN,BackgroundPanel:IN,BorderPanel:LN,ColorPanel:NN,TypographyPanel:MN,DimensionsPanel:VN,FiltersPanel:DN,ImageSettingsPanel:BN,AdvancedPanel:jN}=Ve(kg.privateApis);var S2=f(ge(),1),C2=f(ue(),1),_2=f(Te(),1);var uS=f(ue(),1);var fS=f(Z(),1);var dS=f(ge(),1),Gs=f(ue(),1);var Ag=f(Z(),1);var Zs=f(ue(),1);var Ig=f(ue(),1);var Ys=f(Z(),1),pS=({variation:e,isFocused:t,withHoverView:r})=>(0,Ys.jsx)(Fn,{label:e.title,isFocused:t,withHoverView:r,children:({ratio:o,key:n})=>(0,Ys.jsx)(Ig.__experimentalHStack,{spacing:10*o,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Ys.jsx)(Us,{variation:e,fontSize:85*o})},n)}),Lg=pS;var Zo=f(Te(),1),Mg=f(Qc(),1),qs=f(ge(),1);var Eo=f(Z(),1);function An({variation:e,children:t,isPill:r=!1,properties:o,showTooltip:n=!1}){let[i,s]=(0,Zo.useState)(!1),{base:a,user:u,onChange:l}=(0,Zo.useContext)(gt),c=(0,Zo.useMemo)(()=>{let w=Go(a,e);return o&&(w=zs(w,o)),{user:e,base:a,merged:w,onChange:()=>{}}},[e,a,o]),m=()=>l(e),d=w=>{w.keyCode===Mg.ENTER&&(w.preventDefault(),m())},h=(0,Zo.useMemo)(()=>pi(u,e),[u,e]),g=e?.title;e?.description&&(g=(0,qs.sprintf)((0,qs._x)("%1$s (%2$s)","variation label"),e?.title,e?.description));let b=(0,Eo.jsx)("div",{className:We("global-styles-ui-variations_item",{"is-active":h}),role:"button",onClick:m,onKeyDown:d,tabIndex:0,"aria-label":g,"aria-current":h,onFocus:()=>s(!0),onBlur:()=>s(!1),children:(0,Eo.jsx)("div",{className:We("global-styles-ui-variations_item-preview",{"is-pill":r}),children:t(i)})});return(0,Eo.jsx)(gt.Provider,{value:c,children:n?(0,Eo.jsxs)(Sn.Root,{children:[(0,Eo.jsx)(Sn.Trigger,{render:b}),(0,Eo.jsx)(Sn.Popup,{children:e?.title})]}):b})}var Xo=f(Z(),1),Vg=["typography"];function Xs({title:e,gap:t=2}){let r=Hs(Vg);return r?.length<=1?null:(0,Xo.jsxs)(Zs.__experimentalVStack,{spacing:3,children:[e&&(0,Xo.jsx)(Er,{level:3,children:e}),(0,Xo.jsx)(Zs.__experimentalGrid,{columns:3,gap:t,className:"global-styles-ui-style-variations-container",children:r.map((o,n)=>(0,Xo.jsx)(An,{variation:o,properties:Vg,showTooltip:!0,children:()=>(0,Xo.jsx)(Lg,{variation:o})},n))})]})}var w2=f(ge(),1),Ri=f(ue(),1);var x2=f(Te(),1);var to=f(Te(),1),ko=f(Kt(),1),Oo=f(sr(),1),ru=f(ge(),1);var $c=f(Bg(),1),jg=f(sr(),1),zg="/wp/v2/font-families";function Hg(e){let{receiveEntityRecords:t}=e.dispatch(jg.store);t("postType","wp_font_family",[],void 0,!0)}async function Ug(e,t){let o=await(0,$c.default)({path:zg,method:"POST",body:e});return Hg(t),{id:o.id,...o.font_family_settings,fontFace:[]}}async function Wg(e,t,r){let o={path:`${zg}/${e}/font-faces`,method:"POST",body:t},n=await(0,$c.default)(o);return Hg(r),{id:n.id,...n.font_face_settings}}var In=function(){return In=Object.assign||function(t){for(var r,o=1,n=arguments.length;o{o.forEach(n=>{n.family===jc(e?.fontFamily)&&n.weight===e?.fontWeight&&n.style===e?.fontStyle&&o.delete(n)})};if((t==="document"||t==="all")&&r(document.fonts),t==="iframe"||t==="all"){let o=document.querySelector('iframe[name="editor-canvas"]');o?.contentDocument&&r(o.contentDocument.fonts)}}function Ln(e){if(!e)return;let t;if(Array.isArray(e)?t=e[0]:t=e,!t.startsWith("file:."))return gS(t)||(t=encodeURI(t)),t}function ey(e){let t=new FormData,{fontFace:r,category:o,...n}=e,i={...n,slug:Ks(e.slug)};return t.append("font_family_settings",JSON.stringify(i)),t}function ty(e){return(e?.fontFace??[]).map((r,o)=>{let n={...r},i=new FormData;if(n.file){let s=Array.isArray(n.file)?n.file:[n.file],a=[];s.forEach((u,l)=>{let c=`file-${o}-${l}`;i.append(c,u,u.name),a.push(c)}),n.src=a.length===1?a[0]:a,delete n.file,i.append("font_face_settings",JSON.stringify(n))}else i.append("font_face_settings",JSON.stringify(n));return i})}async function ry(e,t,r){let o=[];for(let i of t)try{let s=await Wg(e,i,r);o.push({status:"fulfilled",value:s})}catch(s){o.push({status:"rejected",reason:s})}let n={errors:[],successes:[]};return o.forEach((i,s)=>{if(i.status==="fulfilled"&&i.value){let a=i.value;n.successes.push(a)}else i.reason&&n.errors.push({data:t[s],message:i.reason.message})}),n}async function oy(e){e=Array.isArray(e)?e:[e];let t=await Promise.all(e.map(async r=>fetch(new Request(r)).then(o=>{if(!o.ok)throw new Error(`Error downloading font face asset from ${r}. Server responded with status: ${o.status}`);return o.blob()}).then(o=>{let n=r.split("/").pop();return new Qg([o],n,{type:o.type})})));return t.length===1?t[0]:t}function tu(e,t){return t.findIndex(r=>r.fontWeight===e.fontWeight&&r.fontStyle===e.fontStyle)!==-1}function ny(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let i of t){let s=n[i];n=n[i]=Array.isArray(s)?[...s]:{...s}}return n[o]=r,e}function Qs(e,t,r=[]){let o=u=>u.slug===e.slug,n=u=>u.find(o),i=u=>u?r.filter(l=>!o(l)):[...r,e],s=u=>{let l=m=>m.fontWeight===t.fontWeight&&m.fontStyle===t.fontStyle;if(!u)return[...r,{...e,fontFace:[t]}];let c=u.fontFace||[];return c.find(l)?c=c.filter(m=>!l(m)):c=[...c,t],c.length===0?r.filter(m=>!o(m)):r.map(m=>o(m)?{...m,fontFace:c}:m)},a=n(r);return t?s(a):i(a)}var iy=f(Z(),1),jt=(0,to.createContext)({});jt.displayName="FontLibraryContext";function vS({children:e}){let t=(0,ko.useRegistry)(),{saveEntityRecord:r,deleteEntityRecord:o}=(0,ko.useDispatch)(Oo.store),{globalStylesId:n}=(0,ko.useSelect)(R=>{let{__experimentalGetCurrentGlobalStylesId:B}=R(Oo.store);return{globalStylesId:B()}},[]),i=(0,Oo.useEntityRecord)("root","globalStyles",n),[s,a]=(0,to.useState)(!1),{records:u=[],isResolving:l}=(0,Oo.useEntityRecords)("postType","wp_font_family",{_embed:!0}),c=(u||[]).map(R=>({id:R.id,...R.font_family_settings||{},fontFace:R?._embedded?.font_faces?.map(B=>B.font_face_settings)||[]}))||[],[m,d]=Ke("typography.fontFamilies"),h=async R=>{if(!i.record)return;let B=i.record,re=ny(B??{},["settings","typography","fontFamilies"],R);await r("root","globalStyles",re)},[g,b]=(0,to.useState)(""),[w,C]=(0,to.useState)(void 0),x=m?.theme?m.theme.map(R=>To(R,{source:"theme"})).sort((R,B)=>R.name.localeCompare(B.name)):[],v=m?.custom?m.custom.map(R=>To(R,{source:"custom"})).sort((R,B)=>R.name.localeCompare(B.name)):[],_=c?c.map(R=>To(R,{source:"custom"})).sort((R,B)=>R.name.localeCompare(B.name)):[];(0,to.useEffect)(()=>{g||C(void 0)},[g]);let k=R=>{if(!R){C(void 0);return}let re=(R.source==="theme"?x:_).find(P=>P.slug===R.slug);C({...re||R,source:R.source})},[E]=(0,to.useState)(new Set),T=R=>R.reduce((re,P)=>{let W=P?.fontFace&&P.fontFace?.length>0?P?.fontFace.map(ne=>`${ne.fontStyle??""}${ne.fontWeight??""}`):["normal400"];return re[P.slug]=W,re},{}),O=R=>T(R==="theme"?x:v),I=(R,B,re,P)=>!B&&!re?!!O(P)[R]:!!O(P)[R]?.includes((B??"")+(re??"")),J=(R,B)=>O(B)[R]||[];async function D(R){a(!0);try{let B=[],re=[];for(let W of R){let ne=!1,xe=await(0,ko.resolveSelect)(Oo.store).getEntityRecords("postType","wp_font_family",{slug:W.slug,per_page:1,_embed:!0}),se=xe&&xe.length>0?xe[0]:null,be=se?{id:se.id,...se.font_family_settings,fontFace:(se?._embedded?.font_faces??[]).map(Fe=>Fe.font_face_settings)||[]}:null;be||(ne=!0,be=await Ug(ey(W),t));let ye=be.fontFace&&W.fontFace?be.fontFace.filter(Fe=>Fe&&W.fontFace&&tu(Fe,W.fontFace)):[];be.fontFace&&W.fontFace&&(W.fontFace=W.fontFace.filter(Fe=>!tu(Fe,be.fontFace)));let $=[],_e=[];if(W?.fontFace?.length??!1){let Fe=await ry(be.id,ty(W),t);$=Fe?.successes,_e=Fe?.errors}($?.length>0||ye?.length>0)&&(be.fontFace=[...$],B.push(be)),be&&!W?.fontFace?.length&&B.push(be),ne&&(W?.fontFace?.length??0)>0&&$?.length===0&&await o("postType","wp_font_family",be.id,{force:!0}),re=re.concat(_e)}let P=re.reduce((W,ne)=>W.includes(ne.message)?W:[...W,ne.message],[]);if(B.length>0){let W=Y(B);await h(W)}if(P.length>0){let W=new Error((0,ru.__)("There was an error installing fonts."));throw W.installationErrors=P,W}}finally{a(!1)}}async function S(R){if(!R?.id)throw new Error((0,ru.__)("Font family to uninstall is not defined."));try{await o("postType","wp_font_family",R.id,{force:!0});let B=L(R);return await h(B),{deleted:!0}}catch(B){throw console.error("There was an error uninstalling the font family:",B),B}}let L=R=>{let re=(m?.[R.source??""]??[]).filter(W=>W.slug!==R.slug),P={...m,[R.source??""]:re};return d(P),R.fontFace&&R.fontFace.forEach(W=>{bi(W,"all")}),P},Y=R=>{let B=A(R),re={...m,custom:$g(m?.custom,B)};return d(re),N(B),re},A=R=>R.map(({id:B,fontFace:re,...P})=>({...P,...re&&re.length>0?{fontFace:re.map(({id:W,...ne})=>ne)}:{}})),N=R=>{R.forEach(B=>{B.fontFace&&B.fontFace.forEach(re=>{let P=Ln(re?.src??"");P&&Po(re,P,"all")})})},q=(R,B)=>{let re=m?.[R.source??""]??[],P=Qs(R,B,re);d({...m,[R.source??""]:P});let W=I(R.slug,B?.fontStyle??"",B?.fontWeight??"",R.source??"custom");if(B&&W)bi(B,"all");else{let ne=Ln(B?.src??"");B&&ne&&Po(B,ne,"all")}},U=async R=>{if(!R.src)return;let B=Ln(R.src);!B||E.has(B)||(Po(R,B,"document"),E.add(B))};return(0,iy.jsx)(jt.Provider,{value:{libraryFontSelected:w,handleSetLibraryFontSelected:k,fontFamilies:m??{},baseCustomFonts:_,isFontActivated:I,getFontFacesActivated:J,loadFontFaceAsset:U,installFonts:D,uninstallFontFamily:S,toggleActivateFont:q,getAvailableFontsOutline:T,modalTabOpen:g,setModalTabOpen:b,saveFontFamilies:h,isResolvingLibrary:l,isInstalling:s},children:e})}var $s=vS;var ma=f(ge(),1),au=f(ue(),1),zy=f(sr(),1),v2=f(Kt(),1);var Ie=f(ue(),1),xi=f(sr(),1),ou=f(Kt(),1),Wr=f(Te(),1),st=f(ge(),1);var Mn=f(ge(),1),ea=f(Te(),1),hr=f(ue(),1);var Tr=f(Te(),1);var ro=f(Z(),1),sy=new Set;function bS(e){if(e.preview)return e.preview;if(e.src)return Array.isArray(e.src)?e.src[0]:e.src}function wS(e){return"fontStyle"in e&&e.fontStyle||"fontWeight"in e&&e.fontWeight?e:"fontFace"in e&&e.fontFace&&e.fontFace.length?e.fontFace.find(t=>t.fontStyle==="normal"&&t.fontWeight==="400")||e.fontFace[0]:{fontStyle:"normal",fontWeight:"400",fontFamily:e.fontFamily}}function xS({font:e,text:t}){let r=(0,Tr.useRef)(null),o=wS(e),n=On(e);t=t||("name"in e?e.name:"");let s=e.preview??bS(o),a=!!(s&&/\.(png|jpg|jpeg|gif|svg)$/i.test(s)),[u,l]=(0,Tr.useState)(!1),[c,m]=(0,Tr.useState)(!1),[d,h]=(0,Tr.useState)(),{loadFontFaceAsset:g}=(0,Tr.useContext)(jt),b=a?!!s&&(sy.has(s)||d===s):c,w=Math.min(Math.max(t.length*12,48),300),C=dg(o),x={fontSize:"18px",lineHeight:1,opacity:b?"1":"0",...n,...C};return(0,Tr.useEffect)(()=>{if(a)return;let v=new window.IntersectionObserver(([_])=>{l(_.isIntersecting)},{});return r.current&&v.observe(r.current),()=>v.disconnect()},[a]),(0,Tr.useEffect)(()=>{(async()=>u&&!a&&(o.src&&await g(o),m(!0)))()},[o,u,g,a]),(0,ro.jsx)("div",{ref:r,className:"font-library__font-demo",children:a?(0,ro.jsxs)(ro.Fragment,{children:[!b&&(0,ro.jsx)(ui,{className:"font-library__font-variant-demo-skeleton",style:{width:w}}),(0,ro.jsx)("img",{src:s,loading:"lazy",alt:t,onLoad:()=>{s&&sy.add(s),h(s)},onError:()=>h(s),className:We("font-library__font-variant_demo-image",{"is-loading":!b})})]}):(0,ro.jsx)("span",{style:x,className:"font-library__font-variant_demo-text",children:t})})}var Nn=xS;var Ur=f(Z(),1);function SS({font:e,onClick:t,variantsText:r,navigatorPath:o,shouldFocus:n}){let i=e.fontFace?.length||1,s={cursor:t?"pointer":"default"},a=(0,hr.useNavigator)(),u=(0,ea.useRef)(null);return(0,ea.useEffect)(()=>{n&&u.current?.focus()},[n]),(0,Ur.jsx)(hr.Button,{ref:u,__next40pxDefaultSize:!0,onClick:()=>{t(),o&&a.goTo(o)},style:s,className:"font-library__font-card",children:(0,Ur.jsxs)(hr.Flex,{justify:"space-between",wrap:!1,children:[(0,Ur.jsx)(Nn,{font:e}),(0,Ur.jsxs)(hr.Flex,{justify:"flex-end",children:[(0,Ur.jsx)(hr.FlexItem,{children:(0,Ur.jsx)(hr.__experimentalText,{className:"font-library__font-card__count",children:r||(0,Mn.sprintf)((0,Mn._n)("%d variant","%d variants",i),i)})}),(0,Ur.jsx)(hr.FlexItem,{children:(0,Ur.jsx)(ai,{icon:(0,Mn.isRTL)()?Uo:Wo})})]})]})})}var wi=SS;var ta=f(Te(),1),ra=f(ue(),1);var Ko=f(Z(),1);function CS({face:e,font:t}){let{isFontActivated:r,toggleActivateFont:o}=(0,ta.useContext)(jt),n=(t?.fontFace?.length??0)>0?r(t.slug,e.fontStyle,e.fontWeight,t.source):r(t.slug,void 0,void 0,t.source),i=()=>{if((t?.fontFace?.length??0)>0){o(t,e);return}o(t)},s=t.name+" "+Js(e),a=(0,ta.useId)();return(0,Ko.jsx)("div",{className:"font-library__font-card",children:(0,Ko.jsxs)(ra.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Ko.jsx)(ra.CheckboxControl,{checked:n,onChange:i,id:a}),(0,Ko.jsx)("label",{htmlFor:a,children:(0,Ko.jsx)(Nn,{font:e,text:s,onClick:i})})]})})}var ay=CS;function ly(e){switch(e){case"normal":return 400;case"bold":return 700;case"bolder":return 500;case"lighter":return 300;default:return parseInt(e,10)}}function oa(e){return e.sort((t,r)=>t.fontStyle==="normal"&&r.fontStyle!=="normal"?-1:r.fontStyle==="normal"&&t.fontStyle!=="normal"?1:t.fontStyle===r.fontStyle?ly(t.fontWeight?.toString()??"normal")-ly(r.fontWeight?.toString()??"normal"):!t.fontStyle||!r.fontStyle?t.fontStyle?-1:1:t.fontStyle.localeCompare(r.fontStyle))}var Ee=f(Z(),1);function cy(e){if(!e)return"";let t={};for(let r of Object.keys(e).sort())t[r]=(e[r]??[]).map(o=>({slug:o.slug,fontFace:(o.fontFace??[]).map(n=>`${n.fontStyle}-${n.fontWeight}`).sort()})).sort((o,n)=>o.slug.localeCompare(n.slug));return JSON.stringify(t)}function _S(){let{baseCustomFonts:e,libraryFontSelected:t,handleSetLibraryFontSelected:r,uninstallFontFamily:o,isResolvingLibrary:n,isInstalling:i,saveFontFamilies:s,getFontFacesActivated:a}=(0,Wr.useContext)(jt),[u,l]=Ke("typography.fontFamilies"),[c,m]=(0,Wr.useState)(void 0),[d,h]=(0,Wr.useState)(!1),[g,b]=(0,Wr.useState)(null),[w]=Ke("typography.fontFamilies",void 0,"base"),C=(0,ou.useSelect)(P=>{let{__experimentalGetCurrentGlobalStylesId:W}=P(xi.store);return W()},[]),x=(0,xi.useEntityRecord)("root","globalStyles",C),v=x?.edits?.settings?.typography?.fontFamilies,_=x?.record?.settings?.typography?.fontFamilies,k=(0,Wr.useMemo)(()=>v===void 0?!1:cy(v)!==cy(_),[v,_]),E=u?.theme?u.theme.map(P=>To(P,{source:"theme"})).sort((P,W)=>P.name.localeCompare(W.name)):[],T=new Set(E.map(P=>P.slug)),O=w?.theme?E.concat(w.theme.filter(P=>!T.has(P.slug)).map(P=>To(P,{source:"theme"})).sort((P,W)=>P.name.localeCompare(W.name))):[],I=t?.source==="custom"&&t?.id,J=(0,ou.useSelect)(P=>{let{canUser:W}=P(xi.store);return I&&W("delete",{kind:"postType",name:"wp_font_family",id:I})},[I]),D=!!t&&t?.source!=="theme"&&J,S=()=>{h(!0)},L=async()=>{b(null);try{await s(u),b({type:"success",message:(0,st.__)("Font family updated successfully.")})}catch(P){b({type:"error",message:(0,st.sprintf)((0,st.__)("There was an error updating the font family. %s"),P.message)})}},Y=P=>P?!P.fontFace||!P.fontFace.length?[{fontFamily:P.fontFamily,fontStyle:"normal",fontWeight:"400"}]:oa(P.fontFace):[],A=P=>{let W=P?.fontFace&&(P?.fontFace?.length??0)>0?P.fontFace.length:1,ne=a(P.slug,P.source).length;return(0,st.sprintf)((0,st.__)("%1$d of %2$d active"),ne,W)};(0,Wr.useEffect)(()=>{r(t)},[]);let N=t?a(t.slug,t.source).length:0,q=t?.fontFace?.length??(t?.fontFamily?1:0),U=N>0&&N!==q,R=N===q,B=()=>{if(!t||!t?.source)return;let P=u?.[t.source]?.filter(ne=>ne.slug!==t.slug)??[],W=R?P:[...P,t];l({...u,[t.source]:W}),t.fontFace&&t.fontFace.forEach(ne=>{if(R)bi(ne,"all");else{let xe=Ln(ne?.src??"");xe&&Po(ne,xe,"all")}})},re=O.length>0||e.length>0;return(0,Ee.jsxs)("div",{className:"font-library__tabpanel-layout",children:[n&&(0,Ee.jsx)("div",{className:"font-library__loading",children:(0,Ee.jsx)(Ie.ProgressBar,{})}),!n&&(0,Ee.jsxs)(Ee.Fragment,{children:[(0,Ee.jsxs)(Ie.Navigator,{initialPath:t?"/fontFamily":"/",children:[(0,Ee.jsx)(Ie.Navigator.Screen,{path:"/",children:(0,Ee.jsxs)(Ie.__experimentalVStack,{spacing:"8",children:[g&&(0,Ee.jsx)(Ie.Notice,{status:g.type,onRemove:()=>b(null),children:g.message}),!re&&(0,Ee.jsx)(Ie.__experimentalText,{as:"p",children:(0,st.__)("No fonts installed.")}),O.length>0&&(0,Ee.jsxs)(Ie.__experimentalVStack,{children:[(0,Ee.jsx)("h2",{className:"font-library__fonts-title",children:(0,st._x)("Theme","font source")}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:O.map(P=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(wi,{font:P,navigatorPath:"/fontFamily",variantsText:A(P),shouldFocus:P.slug===c,onClick:()=>{b(null),r(P)}})},P.slug))})]}),e.length>0&&(0,Ee.jsxs)(Ie.__experimentalVStack,{children:[(0,Ee.jsx)("h2",{className:"font-library__fonts-title",children:(0,st._x)("Custom","font source")}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:e.map(P=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(wi,{font:P,navigatorPath:"/fontFamily",variantsText:A(P),shouldFocus:P.slug===c,onClick:()=>{b(null),r(P)}})},P.slug))})]})]})}),(0,Ee.jsxs)(Ie.Navigator.Screen,{path:"/fontFamily",children:[t&&(0,Ee.jsx)(RS,{font:t,isOpen:d,setIsOpen:h,setNotice:b,uninstallFontFamily:o,handleSetLibraryFontSelected:r}),(0,Ee.jsxs)(Ie.Flex,{justify:"flex-start",children:[(0,Ee.jsx)(Ie.Navigator.BackButton,{icon:(0,st.isRTL)()?Wo:Uo,size:"small",onClick:()=>{m(t?.slug),r(void 0),b(null)},label:(0,st.__)("Back")}),(0,Ee.jsx)(Ie.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:t?.name})]}),g&&(0,Ee.jsxs)(Ee.Fragment,{children:[(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:1}),(0,Ee.jsx)(Ie.Notice,{status:g.type,onRemove:()=>b(null),children:g.message}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:1})]}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Ee.jsx)(Ie.__experimentalText,{children:(0,st.__)("Choose font variants. Keep in mind that too many variants could make your site slower.")}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Ee.jsxs)(Ie.__experimentalVStack,{spacing:0,children:[(0,Ee.jsx)(Ie.CheckboxControl,{className:"font-library__select-all",label:(0,st.__)("Select all"),checked:R,onChange:B,indeterminate:U}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:8}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:t&&Y(t).map((P,W)=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(ay,{font:t,face:P},`face${W}`)},`face${W}`))})]})]})]}),(0,Ee.jsxs)(Ie.__experimentalHStack,{justify:"flex-end",className:"font-library__footer",children:[i&&(0,Ee.jsx)(Ie.ProgressBar,{}),D&&(0,Ee.jsx)(Ie.Button,{__next40pxDefaultSize:!0,isDestructive:!0,variant:"tertiary",onClick:S,children:(0,st.__)("Delete")}),(0,Ee.jsx)(Ie.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:L,disabled:!k,accessibleWhenDisabled:!0,children:(0,st.__)("Update")})]})]})]})}function RS({font:e,isOpen:t,setIsOpen:r,setNotice:o,uninstallFontFamily:n,handleSetLibraryFontSelected:i}){let s=(0,Ie.useNavigator)(),a=async()=>{o(null),r(!1);try{await n(e),s.goBack(),i(void 0),o({type:"success",message:(0,st.__)("Font family uninstalled successfully.")})}catch(l){o({type:"error",message:(0,st.__)("There was an error uninstalling the font family.")+l.message})}},u=()=>{r(!1)};return(0,Ee.jsx)(Ie.__experimentalConfirmDialog,{isOpen:t,cancelButtonText:(0,st.__)("Cancel"),confirmButtonText:(0,st.__)("Delete"),onCancel:u,onConfirm:a,size:"medium",children:e&&(0,st.sprintf)((0,st.__)('Are you sure you want to delete "%s" font and all its variants and assets?'),e.name)})}var na=_S;var yt=f(Te(),1),Ce=f(ue(),1),yy=f(yo(),1),rt=f(ge(),1);var vy=f(sr(),1);function uy(e,t){let{category:r,search:o}=t,n=e||[];return r&&r!=="all"&&(n=n.filter(i=>i.categories&&i.categories.indexOf(r)!==-1)),o&&(n=n.filter(i=>i.font_family_settings&&i.font_family_settings.name.toLowerCase().includes(o.toLowerCase()))),n}function fy(e){return e.reduce((t,r)=>({...t,[r.slug]:(r?.fontFace||[]).reduce((o,n)=>({...o,[`${n.fontStyle}-${n.fontWeight}`]:!0}),{})}),{})}function dy(e,t,r){return t?!!r[e]?.[`${t.fontStyle}-${t.fontWeight}`]:!!r[e]}var Si=f(ge(),1),zt=f(ue(),1),gr=f(Z(),1);function ES(){let e=()=>{window.localStorage.setItem("wp-font-library-google-fonts-permission","true"),window.dispatchEvent(new Event("storage"))};return(0,gr.jsx)("div",{className:"font-library__google-fonts-confirm",children:(0,gr.jsx)(zt.Card,{children:(0,gr.jsxs)(zt.CardBody,{children:[(0,gr.jsx)(zt.__experimentalHeading,{level:2,children:(0,Si.__)("Connect to Google Fonts")}),(0,gr.jsx)(zt.__experimentalSpacer,{margin:6}),(0,gr.jsx)(zt.__experimentalText,{as:"p",children:(0,Si.__)("To install fonts from Google you must give permission to connect directly to Google servers. The fonts you install will be downloaded from Google and stored on your site. Your site will then use these locally-hosted fonts.")}),(0,gr.jsx)(zt.__experimentalSpacer,{margin:3}),(0,gr.jsx)(zt.__experimentalText,{as:"p",children:(0,Si.__)("You can alternatively upload files directly on the Upload tab.")}),(0,gr.jsx)(zt.__experimentalSpacer,{margin:6}),(0,gr.jsx)(zt.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:e,children:(0,Si.__)("Allow access to Google Fonts")})]})})})}var py=ES;var my=f(Te(),1),ia=f(ue(),1);var Jo=f(Z(),1);function TS({face:e,font:t,handleToggleVariant:r,selected:o}){let n=()=>{if(t?.fontFace){r(t,e);return}r(t)},i=t.name+" "+Js(e),s=(0,my.useId)();return(0,Jo.jsx)("div",{className:"font-library__font-card",children:(0,Jo.jsxs)(ia.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Jo.jsx)(ia.CheckboxControl,{checked:o,onChange:n,id:s}),(0,Jo.jsx)("label",{htmlFor:s,children:(0,Jo.jsx)(Nn,{font:e,text:i,onClick:n})})]})})}var hy=TS;var de=f(Z(),1),PS={slug:"all",name:(0,rt._x)("All","font categories")},gy="wp-font-library-google-fonts-permission",OS=500;function kS({slug:e}){let t=e==="google-fonts",r=()=>window.localStorage.getItem(gy)==="true",[o,n]=(0,yt.useState)(null),[i,s]=(0,yt.useState)(void 0),[a,u]=(0,yt.useState)(null),[l,c]=(0,yt.useState)([]),[m,d]=(0,yt.useState)(1),[h,g]=(0,yt.useState)({}),[b,w]=(0,yt.useState)(t&&!r()),{installFonts:C,isInstalling:x}=(0,yt.useContext)(jt),{record:v,isResolving:_}=(0,vy.useEntityRecord)("root","fontCollection",e);(0,yt.useEffect)(()=>{let $=()=>{w(t&&!r())};return $(),window.addEventListener("storage",$),()=>window.removeEventListener("storage",$)},[e,t]);let k=()=>{window.localStorage.setItem(gy,"false"),window.dispatchEvent(new Event("storage"))};(0,yt.useEffect)(()=>{n(null)},[e]),(0,yt.useEffect)(()=>{c([])},[o]);let E=(0,yt.useMemo)(()=>v?.font_families??[],[v]),T=v?.categories??[],O=[PS,...T],I=(0,yt.useMemo)(()=>uy(E,h),[E,h]),J=Math.max(window.innerHeight,OS),D=Math.floor((J-417)/61),S=Math.ceil(I.length/D),L=(m-1)*D,Y=m*D,A=I.slice(L,Y),N=$=>{g({...h,category:$}),d(1)},U=(0,yy.debounce)($=>{g({...h,search:$}),d(1)},300),R=($,_e)=>{let Fe=Qs($,_e,l);c(Fe)},B=fy(l),re=()=>{c([])},P=l.length>0?l[0]?.fontFace?.length??0:0,W=P>0&&P!==o?.fontFace?.length,ne=P===o?.fontFace?.length,xe=()=>{let $=[];!ne&&o&&$.push(o),c($)},se=async()=>{u(null);let $=l[0];try{$?.fontFace&&await Promise.all($.fontFace.map(async _e=>{_e.src&&(_e.file=await oy(_e.src))}))}catch{u({type:"error",message:(0,rt.__)("Error installing the fonts, could not be downloaded.")});return}try{await C([$]),u({type:"success",message:(0,rt.__)("Fonts were installed successfully.")})}catch(_e){u({type:"error",message:_e.message})}re()},be=$=>$?!$.fontFace||!$.fontFace.length?[{fontFamily:$.fontFamily,fontStyle:"normal",fontWeight:"400"}]:oa($.fontFace):[];if(b)return(0,de.jsx)(py,{});let ye=e==="google-fonts"&&!b&&!o;return(0,de.jsxs)("div",{className:"font-library__tabpanel-layout",children:[_&&(0,de.jsx)("div",{className:"font-library__loading",children:(0,de.jsx)(Ce.ProgressBar,{})}),!_&&v&&(0,de.jsxs)(de.Fragment,{children:[(0,de.jsxs)(Ce.Navigator,{initialPath:"/",className:"font-library__tabpanel-layout",children:[(0,de.jsxs)(Ce.Navigator.Screen,{path:"/",children:[(0,de.jsxs)(Ce.__experimentalHStack,{justify:"space-between",children:[(0,de.jsxs)(Ce.__experimentalVStack,{children:[(0,de.jsx)(Ce.__experimentalHeading,{level:2,size:13,children:v.name}),(0,de.jsx)(Ce.__experimentalText,{children:v.description})]}),ye&&(0,de.jsx)(Ce.DropdownMenu,{icon:jl,label:(0,rt.__)("Actions"),popoverProps:{position:"bottom left"},controls:[{title:(0,rt.__)("Revoke access to Google Fonts"),onClick:k}]})]}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,de.jsxs)(Ce.__experimentalHStack,{spacing:4,justify:"space-between",children:[(0,de.jsx)(Ce.SearchControl,{className:"font-library__search",value:h.search,placeholder:(0,rt.__)("Font name\u2026"),label:(0,rt.__)("Search"),onChange:U,hideLabelFromVision:!1}),(0,de.jsx)(Ce.SelectControl,{label:(0,rt.__)("Category"),value:h.category,onChange:N,children:O&&O.map($=>(0,de.jsx)("option",{value:$.slug,children:$.name},$.slug))})]}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),!!v?.font_families?.length&&!I.length&&(0,de.jsx)(Ce.__experimentalText,{children:(0,rt.__)("No fonts found. Try with a different search term.")}),(0,de.jsx)("div",{className:"font-library__fonts-grid__main",children:(0,de.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:A.map($=>(0,de.jsx)("li",{className:"font-library__fonts-list-item",children:(0,de.jsx)(wi,{font:$.font_family_settings,navigatorPath:"/fontFamily",shouldFocus:$.font_family_settings.slug===i,onClick:()=>{n($.font_family_settings)}})},$.font_family_settings.slug))})})]}),(0,de.jsxs)(Ce.Navigator.Screen,{path:"/fontFamily",children:[(0,de.jsxs)(Ce.Flex,{justify:"flex-start",children:[(0,de.jsx)(Ce.Navigator.BackButton,{icon:(0,rt.isRTL)()?Wo:Uo,size:"small",onClick:()=>{s(o?.slug),n(null),u(null)},label:(0,rt.__)("Back")}),(0,de.jsx)(Ce.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:o?.name})]}),a&&(0,de.jsxs)(de.Fragment,{children:[(0,de.jsx)(Ce.__experimentalSpacer,{margin:1}),(0,de.jsx)(Ce.Notice,{status:a.type,onRemove:()=>u(null),children:a.message}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:1})]}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,de.jsx)(Ce.__experimentalText,{children:(0,rt.__)("Select font variants to install.")}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:4}),(0,de.jsx)(Ce.CheckboxControl,{className:"font-library__select-all",label:(0,rt.__)("Select all"),checked:ne,onChange:xe,indeterminate:W}),(0,de.jsx)(Ce.__experimentalVStack,{spacing:0,children:(0,de.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:o&&be(o).map(($,_e)=>(0,de.jsx)("li",{className:"font-library__fonts-list-item",children:(0,de.jsx)(hy,{font:o,face:$,handleToggleVariant:R,selected:dy(o.slug,o.fontFace?$:null,B)})},`face${_e}`))})}),(0,de.jsx)(Ce.__experimentalSpacer,{margin:16})]})]}),o&&(0,de.jsx)(Ce.Flex,{justify:"flex-end",className:"font-library__footer",children:(0,de.jsx)(Ce.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:se,isBusy:x,disabled:l.length===0||x,accessibleWhenDisabled:!0,children:(0,rt.__)("Install")})}),!o&&(0,de.jsxs)(Ce.__experimentalHStack,{expanded:!1,className:"font-library__footer",justify:"end",spacing:6,children:[(0,de.jsx)(Ce.__experimentalHStack,{justify:"flex-start",expanded:!1,spacing:1,className:"font-library__page-selection",children:(0,yt.createInterpolateElement)((0,rt.sprintf)((0,rt._x)("
    Page
    %1$s
    of %2$d
    ","paging"),"",S),{div:(0,de.jsx)("div",{"aria-hidden":!0}),CurrentPage:(0,de.jsx)(Ce.SelectControl,{"aria-label":(0,rt.__)("Current page"),value:m.toString(),options:[...Array(S)].map(($,_e)=>({label:(_e+1).toString(),value:(_e+1).toString()})),onChange:$=>d(parseInt($)),size:"small",variant:"minimal"})})}),(0,de.jsxs)(Ce.__experimentalHStack,{expanded:!1,spacing:1,children:[(0,de.jsx)(Ce.Button,{onClick:()=>d(m-1),disabled:m===1,accessibleWhenDisabled:!0,label:(0,rt.__)("Previous page"),icon:(0,rt.isRTL)()?Os:Fs,showTooltip:!0,size:"compact",tooltipPosition:"top"}),(0,de.jsx)(Ce.Button,{onClick:()=>d(m+1),disabled:m===S,accessibleWhenDisabled:!0,label:(0,rt.__)("Next page"),icon:(0,rt.isRTL)()?Fs:Os,showTooltip:!0,size:"compact",tooltipPosition:"top"})]})]})]})]})}var sa=kS;var Vn=f(ge(),1),Ot=f(ue(),1),_i=f(Te(),1);var aa=(e=>typeof Wt<"u"?Wt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof Wt<"u"?Wt:t)[r]}):e)(function(e){if(typeof Wt<"u")return Wt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),by=(function(){var e,t,r;return(function(){function o(n,i,s){function a(c,m){if(!i[c]){if(!n[c]){var d=typeof aa=="function"&&aa;if(!m&&d)return d(c,!0);if(u)return u(c,!0);var h=new Error("Cannot find module '"+c+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[c]={exports:{}};n[c][0].call(g.exports,function(b){var w=n[c][1][b];return a(w||b)},g,g.exports,o,n,i,s)}return i[c].exports}for(var u=typeof aa=="function"&&aa,l=0;l0},c.prototype.readMoreInput=function(){if(!(this.bit_end_pos_>256))if(this.eos_){if(this.bit_pos_>this.bit_end_pos_)throw new Error("Unexpected end of input "+this.bit_pos_+" "+this.bit_end_pos_)}else{var m=this.buf_ptr_,d=this.input_.read(this.buf_,m,s);if(d<0)throw new Error("Unexpected end of input");if(d=8;)this.val_>>>=8,this.val_|=this.buf_[this.pos_&u]<<24,++this.pos_,this.bit_pos_=this.bit_pos_-8>>>0,this.bit_end_pos_=this.bit_end_pos_-8>>>0},c.prototype.readBits=function(m){32-this.bit_pos_>>this.bit_pos_&l[m];return this.bit_pos_+=m,d},n.exports=c},{}],2:[function(o,n,i){var s=0,a=1,u=2,l=3;i.lookup=new Uint8Array([0,0,0,0,0,0,0,0,0,4,4,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,12,16,12,12,20,12,16,24,28,12,12,32,12,36,12,44,44,44,44,44,44,44,44,44,44,32,32,24,40,28,12,12,48,52,52,52,48,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,24,12,28,12,12,12,56,60,60,60,56,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,24,12,28,12,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,56,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,10,10,10,10,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,22,22,22,22,23,23,23,23,24,24,24,24,25,25,25,25,26,26,26,26,27,27,27,27,28,28,28,28,29,29,29,29,30,30,30,30,31,31,31,31,32,32,32,32,33,33,33,33,34,34,34,34,35,35,35,35,36,36,36,36,37,37,37,37,38,38,38,38,39,39,39,39,40,40,40,40,41,41,41,41,42,42,42,42,43,43,43,43,44,44,44,44,45,45,45,45,46,46,46,46,47,47,47,47,48,48,48,48,49,49,49,49,50,50,50,50,51,51,51,51,52,52,52,52,53,53,53,53,54,54,54,54,55,55,55,55,56,56,56,56,57,57,57,57,58,58,58,58,59,59,59,59,60,60,60,60,61,61,61,61,62,62,62,62,63,63,63,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),i.lookupOffsets=new Uint16Array([1024,1536,1280,1536,0,256,768,512])},{}],3:[function(o,n,i){var s=o("./streams").BrotliInput,a=o("./streams").BrotliOutput,u=o("./bit_reader"),l=o("./dictionary"),c=o("./huffman").HuffmanCode,m=o("./huffman").BrotliBuildHuffmanTable,d=o("./context"),h=o("./prefix"),g=o("./transform"),b=8,w=16,C=256,x=704,v=26,_=6,k=2,E=8,T=255,O=1080,I=18,J=new Uint8Array([1,2,3,4,0,5,17,6,16,7,8,9,10,11,12,13,14,15]),D=16,S=new Uint8Array([3,2,1,0,3,3,3,3,3,3,2,2,2,2,2,2]),L=new Int8Array([0,0,0,0,-1,1,-2,2,-3,3,-1,1,-2,2,-3,3]),Y=new Uint16Array([256,402,436,468,500,534,566,598,630,662,694,726,758,790,822,854,886,920,952,984,1016,1048,1080]);function A(X){var M;return X.readBits(1)===0?16:(M=X.readBits(3),M>0?17+M:(M=X.readBits(3),M>0?8+M:17))}function N(X){if(X.readBits(1)){var M=X.readBits(3);return M===0?1:X.readBits(M)+(1<1&&pe===0)throw new Error("Invalid size byte");M.meta_block_length|=pe<4&&le===0)throw new Error("Invalid size nibble");M.meta_block_length|=le<>>K.bit_pos_&T,Q=X[M].bits-E,Q>0&&(K.bit_pos_+=E,M+=X[M].value,M+=K.val_>>>K.bit_pos_&(1<0;){var te=0,Ne;if(H.readMoreInput(),H.fillBitWindow(),te+=H.val_>>>H.bit_pos_&31,H.bit_pos_+=he[te].bits,Ne=he[te].value&255,Ne>Ne);else{var He=Ne-14,ot,Ze,Be=0;if(Ne===w&&(Be=pe),fe!==Be&&(le=0,fe=Be),ot=le,le>0&&(le-=2,le<<=He),le+=H.readBits(He)+3,Ze=le-ot,Q+Ze>M)throw new Error("[ReadHuffmanCodeLengths] symbol + repeat_delta > num_symbols");for(var Ue=0;Ue0;++fe){var Be=J[fe],Ue=0,ct;H.fillBitWindow(),Ue+=H.val_>>>H.bit_pos_&15,H.bit_pos_+=Ze[Ue].bits,ct=Ze[Ue].value,Ne[Be]=ct,ct!==0&&(He-=32>>ct,++ot)}if(!(ot===1||He===0))throw new Error("[ReadHuffmanCode] invalid num_codes or space");B(Ne,X,le,H)}if(Q=m(M,K,E,le,X),Q===0)throw new Error("[ReadHuffmanCode] BuildHuffmanTable failed: ");return Q}function P(X,M,K){var H,Q;return H=R(X,M,K),Q=h.kBlockLengthPrefixCode[H].nbits,h.kBlockLengthPrefixCode[H].offset+K.readBits(Q)}function W(X,M,K){var H;return X>>5]),this.htrees=new Uint32Array(M)}se.prototype.decode=function(X){var M,K,H=0;for(M=0;M=X)throw new Error("[DecodeContextMap] i >= context_map_size");me[le]=0,++le}else me[le]=he-Q,++le}return M.readBits(1)&&xe(me,X),K}function ye(X,M,K,H,Q,pe,le){var fe=K*2,me=K,he=R(M,K*O,le),V;he===0?V=Q[fe+(pe[me]&1)]:he===1?V=Q[fe+(pe[me]-1&1)]+1:V=he-2,V>=X&&(V-=X),H[K]=V,Q[fe+(pe[me]&1)]=V,++pe[me]}function $(X,M,K,H,Q,pe){var le=Q+1,fe=K&Q,me=pe.pos_&u.IBUF_MASK,he;if(M<8||pe.bit_pos_+(M<<3)0;)pe.readMoreInput(),H[fe++]=pe.readBits(8),fe===le&&(X.write(H,le),fe=0);return}if(pe.bit_end_pos_<32)throw new Error("[CopyUncompressedBlockToOutput] br.bit_end_pos_ < 32");for(;pe.bit_pos_<32;)H[fe]=pe.val_>>>pe.bit_pos_,pe.bit_pos_+=8,++fe,--M;if(he=pe.bit_end_pos_-pe.bit_pos_>>3,me+he>u.IBUF_MASK){for(var V=u.IBUF_MASK+1-me,te=0;te=le){X.write(H,le),fe-=le;for(var te=0;te=le;){if(he=le-fe,pe.input_.read(H,fe,he)M.buffer.length){var Fo=new Uint8Array(H+Ye);Fo.set(M.buffer),M.buffer=Fo}if(Q=wr.input_end,Yr=wr.is_uncompressed,wr.is_metadata){for(_e(Se);Ye>0;--Ye)Se.readMoreInput(),Se.readBits(8);continue}if(Ye!==0){if(Yr){Se.bit_pos_=Se.bit_pos_+7&-8,$(M,Ye,H,V,he,Se),H+=Ye;continue}for(K=0;K<3;++K)vt[K]=N(Se)+1,vt[K]>=2&&(re(vt[K]+2,Ue,K*O,Se),re(v,ct,K*O,Se),St[K]=P(ct,K*O,Se),G[K]=1);for(Se.readMoreInput(),y=Se.readBits(2),oe=D+(Se.readBits(4)<0;){var ft,At,Ht,en,Ta,Ut,er,qr,Hn,tn,Un;for(Se.readMoreInput(),St[1]===0&&(ye(vt[1],Ue,1,kt,F,G,Se),St[1]=P(ct,O,Se),pt=Be[1].htrees[kt[1]]),--St[1],ft=R(Be[1].codes,pt,Se),At=ft>>6,At>=2?(At-=2,er=-1):er=0,Ht=h.kInsertRangeLut[At]+(ft>>3&7),en=h.kCopyRangeLut[At]+(ft&7),Ta=h.kInsertLengthPrefixCode[Ht].offset+Se.readBits(h.kInsertLengthPrefixCode[Ht].nbits),Ut=h.kCopyLengthPrefixCode[en].offset+Se.readBits(h.kCopyLengthPrefixCode[en].nbits),ot=V[H-1&he],Ze=V[H-2&he],tn=0;tn4?3:Ut-2)&255,et=j[Or+Hn],er=R(Be[2].codes,Be[2].htrees[et],Se),er>=oe){var Pa,Vu,Wn;er-=oe,Vu=er&Ae,er>>=y,Pa=(er>>1)+1,Wn=(2+(er&1)<fe)if(Ut>=l.minDictionaryWordLength&&Ut<=l.maxDictionaryWordLength){var Wn=l.offsetsByLength[Ut],Du=qr-fe-1,Bu=l.sizeBitsByLength[Ut],zv=(1<>Bu;if(Wn+=Hv*Ut,ju=te){M.write(V,me);for(var Fi=0;Fi0&&(Ne[He&3]=qr,++He),Ut>Ye)throw new Error("Invalid backward reference. pos: "+H+" distance: "+qr+" len: "+Ut+" bytes left: "+Ye);for(tn=0;tn>=1;return(m&h-1)+h}function l(m,d,h,g,b){do g-=h,m[d+g]=new s(b.bits,b.value);while(g>0)}function c(m,d,h){for(var g=1<0;--S[x])C=new s(x&255,D[v++]&65535),l(m,d+_,k,I,C),_=u(_,x);for(T=J-1,E=-1,x=h+1,k=2;x<=a;++x,k<<=1)for(;S[x]>0;--S[x])(_&T)!==E&&(d+=I,O=c(S,x,h),I=1<>h),k,I,C),_=u(_,x);return J}},{}],8:[function(o,n,i){"use strict";i.byteLength=h,i.toByteArray=b,i.fromByteArray=x;for(var s=[],a=[],u=typeof Uint8Array<"u"?Uint8Array:Array,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=0,m=l.length;c0)throw new Error("Invalid string. Length must be a multiple of 4");var k=v.indexOf("=");k===-1&&(k=_);var E=k===_?0:4-k%4;return[k,E]}function h(v){var _=d(v),k=_[0],E=_[1];return(k+E)*3/4-E}function g(v,_,k){return(_+k)*3/4-k}function b(v){for(var _,k=d(v),E=k[0],T=k[1],O=new u(g(v,E,T)),I=0,J=T>0?E-4:E,D=0;D>16&255,O[I++]=_>>8&255,O[I++]=_&255;return T===2&&(_=a[v.charCodeAt(D)]<<2|a[v.charCodeAt(D+1)]>>4,O[I++]=_&255),T===1&&(_=a[v.charCodeAt(D)]<<10|a[v.charCodeAt(D+1)]<<4|a[v.charCodeAt(D+2)]>>2,O[I++]=_>>8&255,O[I++]=_&255),O}function w(v){return s[v>>18&63]+s[v>>12&63]+s[v>>6&63]+s[v&63]}function C(v,_,k){for(var E,T=[],O=_;OJ?J:I+O));return E===1?(_=v[k-1],T.push(s[_>>2]+s[_<<4&63]+"==")):E===2&&(_=(v[k-2]<<8)+v[k-1],T.push(s[_>>10]+s[_>>4&63]+s[_<<2&63]+"=")),T.join("")}},{}],9:[function(o,n,i){function s(a,u){this.offset=a,this.nbits=u}i.kBlockLengthPrefixCode=[new s(1,2),new s(5,2),new s(9,2),new s(13,2),new s(17,3),new s(25,3),new s(33,3),new s(41,3),new s(49,4),new s(65,4),new s(81,4),new s(97,4),new s(113,5),new s(145,5),new s(177,5),new s(209,5),new s(241,6),new s(305,6),new s(369,7),new s(497,8),new s(753,9),new s(1265,10),new s(2289,11),new s(4337,12),new s(8433,13),new s(16625,24)],i.kInsertLengthPrefixCode=[new s(0,0),new s(1,0),new s(2,0),new s(3,0),new s(4,0),new s(5,0),new s(6,1),new s(8,1),new s(10,2),new s(14,2),new s(18,3),new s(26,3),new s(34,4),new s(50,4),new s(66,5),new s(98,5),new s(130,6),new s(194,7),new s(322,8),new s(578,9),new s(1090,10),new s(2114,12),new s(6210,14),new s(22594,24)],i.kCopyLengthPrefixCode=[new s(2,0),new s(3,0),new s(4,0),new s(5,0),new s(6,0),new s(7,0),new s(8,0),new s(9,0),new s(10,1),new s(12,1),new s(14,2),new s(18,2),new s(22,3),new s(30,3),new s(38,4),new s(54,4),new s(70,5),new s(102,5),new s(134,6),new s(198,7),new s(326,8),new s(582,9),new s(1094,10),new s(2118,24)],i.kInsertRangeLut=[0,0,8,8,0,16,8,16,16],i.kCopyRangeLut=[0,8,0,8,16,0,16,8,16]},{}],10:[function(o,n,i){function s(u){this.buffer=u,this.pos=0}s.prototype.read=function(u,l,c){this.pos+c>this.buffer.length&&(c=this.buffer.length-this.pos);for(var m=0;mthis.buffer.length)throw new Error("Output buffer is not large enough");return this.buffer.set(u.subarray(0,l),this.pos),this.pos+=l,l},i.BrotliOutput=a},{}],11:[function(o,n,i){var s=o("./dictionary"),a=0,u=1,l=2,c=3,m=4,d=5,h=6,g=7,b=8,w=9,C=10,x=11,v=12,_=13,k=14,E=15,T=16,O=17,I=18,J=19,D=20;function S(A,N,q){this.prefix=new Uint8Array(A.length),this.transform=N,this.suffix=new Uint8Array(q.length);for(var U=0;U'),new S("",a,` -`),new S("",c,""),new S("",a,"]"),new S("",a," for "),new S("",k,""),new S("",l,""),new S("",a," a "),new S("",a," that "),new S(" ",C,""),new S("",a,". "),new S(".",a,""),new S(" ",a,", "),new S("",E,""),new S("",a," with "),new S("",a,"'"),new S("",a," from "),new S("",a," by "),new S("",T,""),new S("",O,""),new S(" the ",a,""),new S("",m,""),new S("",a,". The "),new S("",x,""),new S("",a," on "),new S("",a," as "),new S("",a," is "),new S("",g,""),new S("",u,"ing "),new S("",a,` - `),new S("",a,":"),new S(" ",a,". "),new S("",a,"ed "),new S("",D,""),new S("",I,""),new S("",h,""),new S("",a,"("),new S("",C,", "),new S("",b,""),new S("",a," at "),new S("",a,"ly "),new S(" the ",a," of "),new S("",d,""),new S("",w,""),new S(" ",C,", "),new S("",C,'"'),new S(".",a,"("),new S("",x," "),new S("",C,'">'),new S("",a,'="'),new S(" ",a,"."),new S(".com/",a,""),new S(" the ",a," of the "),new S("",C,"'"),new S("",a,". This "),new S("",a,","),new S(".",a," "),new S("",C,"("),new S("",C,"."),new S("",a," not "),new S(" ",a,'="'),new S("",a,"er "),new S(" ",x," "),new S("",a,"al "),new S(" ",x,""),new S("",a,"='"),new S("",x,'"'),new S("",C,". "),new S(" ",a,"("),new S("",a,"ful "),new S(" ",C,". "),new S("",a,"ive "),new S("",a,"less "),new S("",x,"'"),new S("",a,"est "),new S(" ",C,"."),new S("",x,'">'),new S(" ",a,"='"),new S("",C,","),new S("",a,"ize "),new S("",x,"."),new S("\xC2\xA0",a,""),new S(" ",a,","),new S("",C,'="'),new S("",x,'="'),new S("",a,"ous "),new S("",x,", "),new S("",C,"='"),new S(" ",C,","),new S(" ",x,'="'),new S(" ",x,", "),new S("",x,","),new S("",x,"("),new S("",x,". "),new S(" ",x,"."),new S("",x,"='"),new S(" ",x,". "),new S(" ",C,'="'),new S(" ",x,"='"),new S(" ",C,"='")];i.kTransforms=L,i.kNumTransforms=L.length;function Y(A,N){return A[N]<192?(A[N]>=97&&A[N]<=122&&(A[N]^=32),1):A[N]<224?(A[N+1]^=32,2):(A[N+2]^=5,3)}i.transformDictionaryWord=function(A,N,q,U,R){var B=L[R].prefix,re=L[R].suffix,P=L[R].transform,W=PU&&(W=U);for(var be=0;be0;){var ye=Y(A,se);se+=ye,U-=ye}for(var $=0;$typeof Wt<"u"?Wt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof Wt<"u"?Wt:t)[r]}):e)(function(e){if(typeof Wt<"u")return Wt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),wy=(function(){var e,t,r;return(function(){function o(n,i,s){function a(c,m){if(!i[c]){if(!n[c]){var d=typeof la=="function"&&la;if(!m&&d)return d(c,!0);if(u)return u(c,!0);var h=new Error("Cannot find module '"+c+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[c]={exports:{}};n[c][0].call(g.exports,function(b){var w=n[c][1][b];return a(w||b)},g,g.exports,o,n,i,s)}return i[c].exports}for(var u=typeof la=="function"&&la,l=0;l=252?6:c>=248?5:c>=240?4:c>=224?3:c>=192?2:1;l[254]=l[254]=1,i.string2buf=function(d){var h,g,b,w,C,x=d.length,v=0;for(w=0;w>>6,h[C++]=128|g&63):g<65536?(h[C++]=224|g>>>12,h[C++]=128|g>>>6&63,h[C++]=128|g&63):(h[C++]=240|g>>>18,h[C++]=128|g>>>12&63,h[C++]=128|g>>>6&63,h[C++]=128|g&63);return h};function m(d,h){if(h<65534&&(d.subarray&&u||!d.subarray&&a))return String.fromCharCode.apply(null,s.shrinkBuf(d,h));for(var g="",b=0;b4){v[b++]=65533,g+=C-1;continue}for(w&=C===2?31:C===3?15:7;C>1&&g1){v[b++]=65533;continue}w<65536?v[b++]=w:(w-=65536,v[b++]=55296|w>>10&1023,v[b++]=56320|w&1023)}return m(v,b)},i.utf8border=function(d,h){var g;for(h=h||d.length,h>d.length&&(h=d.length),g=h-1;g>=0&&(d[g]&192)===128;)g--;return g<0||g===0?h:g+l[d[g]]>h?g:h}},{"./common":1}],3:[function(o,n,i){"use strict";function s(a,u,l,c){for(var m=a&65535|0,d=a>>>16&65535|0,h=0;l!==0;){h=l>2e3?2e3:l,l-=h;do m=m+u[c++]|0,d=d+m|0;while(--h);m%=65521,d%=65521}return m|d<<16|0}n.exports=s},{}],4:[function(o,n,i){"use strict";n.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],5:[function(o,n,i){"use strict";function s(){for(var l,c=[],m=0;m<256;m++){l=m;for(var d=0;d<8;d++)l=l&1?3988292384^l>>>1:l>>>1;c[m]=l}return c}var a=s();function u(l,c,m,d){var h=a,g=d+m;l^=-1;for(var b=d;b>>8^h[(l^c[b])&255];return l^-1}n.exports=u},{}],6:[function(o,n,i){"use strict";function s(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}n.exports=s},{}],7:[function(o,n,i){"use strict";var s=30,a=12;n.exports=function(l,c){var m,d,h,g,b,w,C,x,v,_,k,E,T,O,I,J,D,S,L,Y,A,N,q,U,R;m=l.state,d=l.next_in,U=l.input,h=d+(l.avail_in-5),g=l.next_out,R=l.output,b=g-(c-l.avail_out),w=g+(l.avail_out-257),C=m.dmax,x=m.wsize,v=m.whave,_=m.wnext,k=m.window,E=m.hold,T=m.bits,O=m.lencode,I=m.distcode,J=(1<>>24,E>>>=L,T-=L,L=S>>>16&255,L===0)R[g++]=S&65535;else if(L&16){Y=S&65535,L&=15,L&&(T>>=L,T-=L),T<15&&(E+=U[d++]<>>24,E>>>=L,T-=L,L=S>>>16&255,L&16){if(A=S&65535,L&=15,TC){l.msg="invalid distance too far back",m.mode=s;break e}if(E>>>=L,T-=L,L=g-b,A>L){if(L=A-L,L>v&&m.sane){l.msg="invalid distance too far back",m.mode=s;break e}if(N=0,q=k,_===0){if(N+=x-L,L2;)R[g++]=q[N++],R[g++]=q[N++],R[g++]=q[N++],Y-=3;Y&&(R[g++]=q[N++],Y>1&&(R[g++]=q[N++]))}else{N=g-A;do R[g++]=R[N++],R[g++]=R[N++],R[g++]=R[N++],Y-=3;while(Y>2);Y&&(R[g++]=R[N++],Y>1&&(R[g++]=R[N++]))}}else if((L&64)===0){S=I[(S&65535)+(E&(1<>3,d-=Y,T-=Y<<3,E&=(1<>>24&255)+(F>>>8&65280)+((F&65280)<<8)+((F&255)<<24)}function Ne(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new s.Buf16(320),this.work=new s.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function He(F){var G;return!F||!F.state?_:(G=F.state,F.total_in=F.total_out=G.total=0,F.msg="",G.wrap&&(F.adler=G.wrap&1),G.mode=I,G.last=0,G.havedict=0,G.dmax=32768,G.head=null,G.hold=0,G.bits=0,G.lencode=G.lendyn=new s.Buf32(fe),G.distcode=G.distdyn=new s.Buf32(me),G.sane=1,G.back=-1,C)}function ot(F){var G;return!F||!F.state?_:(G=F.state,G.wsize=0,G.whave=0,G.wnext=0,He(F))}function Ze(F,G){var y,oe;return!F||!F.state||(oe=F.state,G<0?(y=0,G=-G):(y=(G>>4)+1,G<48&&(G&=15)),G&&(G<8||G>15))?_:(oe.window!==null&&oe.wbits!==G&&(oe.window=null),oe.wrap=y,oe.wbits=G,ot(F))}function Be(F,G){var y,oe;return F?(oe=new Ne,F.state=oe,oe.window=null,y=Ze(F,G),y!==C&&(F.state=null),y):_}function Ue(F){return Be(F,V)}var ct=!0,Se,Pr;function $t(F){if(ct){var G;for(Se=new s.Buf32(512),Pr=new s.Buf32(32),G=0;G<144;)F.lens[G++]=8;for(;G<256;)F.lens[G++]=9;for(;G<280;)F.lens[G++]=7;for(;G<288;)F.lens[G++]=8;for(c(d,F.lens,0,288,Se,0,F.work,{bits:9}),G=0;G<32;)F.lens[G++]=5;c(h,F.lens,0,32,Pr,0,F.work,{bits:5}),ct=!1}F.lencode=Se,F.lenbits=9,F.distcode=Pr,F.distbits=5}function Ye(F,G,y,oe){var Ae,ee=F.state;return ee.window===null&&(ee.wsize=1<=ee.wsize?(s.arraySet(ee.window,G,y-ee.wsize,ee.wsize,0),ee.wnext=0,ee.whave=ee.wsize):(Ae=ee.wsize-ee.wnext,Ae>oe&&(Ae=oe),s.arraySet(ee.window,G,y-oe,Ae,ee.wnext),oe-=Ae,oe?(s.arraySet(ee.window,G,y-oe,oe,0),ee.wnext=oe,ee.whave=ee.wsize):(ee.wnext+=Ae,ee.wnext===ee.wsize&&(ee.wnext=0),ee.whave>>8&255,y.check=u(y.check,ft,2,0),j=0,z=0,y.mode=J;break}if(y.flags=0,y.head&&(y.head.done=!1),!(y.wrap&1)||(((j&255)<<8)+(j>>8))%31){F.msg="incorrect header check",y.mode=Q;break}if((j&15)!==O){F.msg="unknown compression method",y.mode=Q;break}if(j>>>=4,z-=4,at=(j&15)+8,y.wbits===0)y.wbits=at;else if(at>y.wbits){F.msg="invalid window size",y.mode=Q;break}y.dmax=1<>8&1),y.flags&512&&(ft[0]=j&255,ft[1]=j>>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0,y.mode=D;case D:for(;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>8&255,ft[2]=j>>>16&255,ft[3]=j>>>24&255,y.check=u(y.check,ft,4,0)),j=0,z=0,y.mode=S;case S:for(;z<16;){if(ie===0)break e;ie--,j+=oe[ee++]<>8),y.flags&512&&(ft[0]=j&255,ft[1]=j>>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0,y.mode=L;case L:if(y.flags&1024){for(;z<16;){if(ie===0)break e;ie--,j+=oe[ee++]<>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0}else y.head&&(y.head.extra=null);y.mode=Y;case Y:if(y.flags&1024&&(ce=y.length,ce>ie&&(ce=ie),ce&&(y.head&&(at=y.head.extra_len-y.length,y.head.extra||(y.head.extra=new Array(y.head.extra_len)),s.arraySet(y.head.extra,oe,ee,ce,at)),y.flags&512&&(y.check=u(y.check,oe,ce,ee)),ie-=ce,ee+=ce,y.length-=ce),y.length))break e;y.length=0,y.mode=A;case A:if(y.flags&2048){if(ie===0)break e;ce=0;do at=oe[ee+ce++],y.head&&at&&y.length<65536&&(y.head.name+=String.fromCharCode(at));while(at&&ce>9&1,y.head.done=!0),F.adler=y.check=0,y.mode=B;break;case U:for(;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=z&7,z-=z&7,y.mode=M;break}for(;z<3;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=1,z-=1,j&3){case 0:y.mode=P;break;case 1:if($t(y),y.mode=ye,G===w){j>>>=2,z-=2;break e}break;case 2:y.mode=xe;break;case 3:F.msg="invalid block type",y.mode=Q}j>>>=2,z-=2;break;case P:for(j>>>=z&7,z-=z&7;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>16^65535)){F.msg="invalid stored block lengths",y.mode=Q;break}if(y.length=j&65535,j=0,z=0,y.mode=W,G===w)break e;case W:y.mode=ne;case ne:if(ce=y.length,ce){if(ce>ie&&(ce=ie),ce>Je&&(ce=Je),ce===0)break e;s.arraySet(Ae,oe,ee,ce,Qe),ie-=ce,ee+=ce,Je-=ce,Qe+=ce,y.length-=ce;break}y.mode=B;break;case xe:for(;z<14;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=5,z-=5,y.ndist=(j&31)+1,j>>>=5,z-=5,y.ncode=(j&15)+4,j>>>=4,z-=4,y.nlen>286||y.ndist>30){F.msg="too many length or distance symbols",y.mode=Q;break}y.have=0,y.mode=se;case se:for(;y.have>>=3,z-=3}for(;y.have<19;)y.lens[en[y.have++]]=0;if(y.lencode=y.lendyn,y.lenbits=7,At={bits:y.lenbits},Ft=c(m,y.lens,0,19,y.lencode,0,y.work,At),y.lenbits=At.bits,Ft){F.msg="invalid code lengths set",y.mode=Q;break}y.have=0,y.mode=be;case be:for(;y.have>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=Me,z-=Me,y.lens[y.have++]=ut;else{if(ut===16){for(Ht=Me+2;z>>=Me,z-=Me,y.have===0){F.msg="invalid bit length repeat",y.mode=Q;break}at=y.lens[y.have-1],ce=3+(j&3),j>>>=2,z-=2}else if(ut===17){for(Ht=Me+3;z>>=Me,z-=Me,at=0,ce=3+(j&7),j>>>=3,z-=3}else{for(Ht=Me+7;z>>=Me,z-=Me,at=0,ce=11+(j&127),j>>>=7,z-=7}if(y.have+ce>y.nlen+y.ndist){F.msg="invalid bit length repeat",y.mode=Q;break}for(;ce--;)y.lens[y.have++]=at}}if(y.mode===Q)break;if(y.lens[256]===0){F.msg="invalid code -- missing end-of-block",y.mode=Q;break}if(y.lenbits=9,At={bits:y.lenbits},Ft=c(d,y.lens,0,y.nlen,y.lencode,0,y.work,At),y.lenbits=At.bits,Ft){F.msg="invalid literal/lengths set",y.mode=Q;break}if(y.distbits=6,y.distcode=y.distdyn,At={bits:y.distbits},Ft=c(h,y.lens,y.nlen,y.ndist,y.distcode,0,y.work,At),y.distbits=At.bits,Ft){F.msg="invalid distances set",y.mode=Q;break}if(y.mode=ye,G===w)break e;case ye:y.mode=$;case $:if(ie>=6&&Je>=258){F.next_out=Qe,F.avail_out=Je,F.next_in=ee,F.avail_in=ie,y.hold=j,y.bits=z,l(F,je),Qe=F.next_out,Ae=F.output,Je=F.avail_out,ee=F.next_in,oe=F.input,ie=F.avail_in,j=y.hold,z=y.bits,y.mode===B&&(y.back=-1);break}for(y.back=0;et=y.lencode[j&(1<>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>pt)],Me=et>>>24,$e=et>>>16&255,ut=et&65535,!(pt+Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=pt,z-=pt,y.back+=pt}if(j>>>=Me,z-=Me,y.back+=Me,y.length=ut,$e===0){y.mode=X;break}if($e&32){y.back=-1,y.mode=B;break}if($e&64){F.msg="invalid literal/length code",y.mode=Q;break}y.extra=$e&15,y.mode=_e;case _e:if(y.extra){for(Ht=y.extra;z>>=y.extra,z-=y.extra,y.back+=y.extra}y.was=y.length,y.mode=Fe;case Fe:for(;et=y.distcode[j&(1<>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>pt)],Me=et>>>24,$e=et>>>16&255,ut=et&65535,!(pt+Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=pt,z-=pt,y.back+=pt}if(j>>>=Me,z-=Me,y.back+=Me,$e&64){F.msg="invalid distance code",y.mode=Q;break}y.offset=ut,y.extra=$e&15,y.mode=xt;case xt:if(y.extra){for(Ht=y.extra;z>>=y.extra,z-=y.extra,y.back+=y.extra}if(y.offset>y.dmax){F.msg="invalid distance too far back",y.mode=Q;break}y.mode=Le;case Le:if(Je===0)break e;if(ce=je-Je,y.offset>ce){if(ce=y.offset-ce,ce>y.whave&&y.sane){F.msg="invalid distance too far back",y.mode=Q;break}ce>y.wnext?(ce-=y.wnext,br=y.wsize-ce):br=y.wnext-ce,ce>y.length&&(ce=y.length),Or=y.window}else Or=Ae,br=Qe-y.offset,ce=y.length;ce>Je&&(ce=Je),Je-=ce,y.length-=ce;do Ae[Qe++]=Or[br++];while(--ce);y.length===0&&(y.mode=$);break;case X:if(Je===0)break e;Ae[Qe++]=y.length,Je--,y.mode=$;break;case M:if(y.wrap){for(;z<32;){if(ie===0)break e;ie--,j|=oe[ee++]<=1&&$[Y]===0;Y--);if(A>Y&&(A=Y),Y===0)return E[T++]=1<<24|64<<16|0,E[T++]=1<<24|64<<16|0,I.bits=1,0;for(L=1;L0&&(x===c||Y!==1))return-1;for(_e[1]=0,D=1;Du||x===d&&R>l)return 1;for(;;){Le=D-q,O[S]ye?(X=Fe[xt+O[S]],M=se[be+O[S]]):(X=96,M=0),re=1<>q)+P]=Le<<24|X<<16|M|0;while(P!==0);for(re=1<>=1;if(re!==0?(B&=re-1,B+=re):B=0,S++,--$[D]===0){if(D===Y)break;D=v[_+O[S]]}if(D>A&&(B&ne)!==W){for(q===0&&(q=A),xe+=L,N=D-q,U=1<u||x===d&&R>l)return 1;W=B&ne,E[W]=A<<24|N<<16|xe-T|0}}return B!==0&&(E[xe+B]=D-q<<24|64<<16|0),I.bits=A,0}},{"../utils/common":1}],10:[function(o,n,i){"use strict";n.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],11:[function(o,n,i){"use strict";function s(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}n.exports=s},{}],"/lib/inflate.js":[function(o,n,i){"use strict";var s=o("./zlib/inflate"),a=o("./utils/common"),u=o("./utils/strings"),l=o("./zlib/constants"),c=o("./zlib/messages"),m=o("./zlib/zstream"),d=o("./zlib/gzheader"),h=Object.prototype.toString;function g(C){if(!(this instanceof g))return new g(C);this.options=a.assign({chunkSize:16384,windowBits:0,to:""},C||{});var x=this.options;x.raw&&x.windowBits>=0&&x.windowBits<16&&(x.windowBits=-x.windowBits,x.windowBits===0&&(x.windowBits=-15)),x.windowBits>=0&&x.windowBits<16&&!(C&&C.windowBits)&&(x.windowBits+=32),x.windowBits>15&&x.windowBits<48&&(x.windowBits&15)===0&&(x.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new m,this.strm.avail_out=0;var v=s.inflateInit2(this.strm,x.windowBits);if(v!==l.Z_OK)throw new Error(c[v]);if(this.header=new d,s.inflateGetHeader(this.strm,this.header),x.dictionary&&(typeof x.dictionary=="string"?x.dictionary=u.string2buf(x.dictionary):h.call(x.dictionary)==="[object ArrayBuffer]"&&(x.dictionary=new Uint8Array(x.dictionary)),x.raw&&(v=s.inflateSetDictionary(this.strm,x.dictionary),v!==l.Z_OK)))throw new Error(c[v])}g.prototype.push=function(C,x){var v=this.strm,_=this.options.chunkSize,k=this.options.dictionary,E,T,O,I,J,D=!1;if(this.ended)return!1;T=x===~~x?x:x===!0?l.Z_FINISH:l.Z_NO_FLUSH,typeof C=="string"?v.input=u.binstring2buf(C):h.call(C)==="[object ArrayBuffer]"?v.input=new Uint8Array(C):v.input=C,v.next_in=0,v.avail_in=v.input.length;do{if(v.avail_out===0&&(v.output=new a.Buf8(_),v.next_out=0,v.avail_out=_),E=s.inflate(v,l.Z_NO_FLUSH),E===l.Z_NEED_DICT&&k&&(E=s.inflateSetDictionary(this.strm,k)),E===l.Z_BUF_ERROR&&D===!0&&(E=l.Z_OK,D=!1),E!==l.Z_STREAM_END&&E!==l.Z_OK)return this.onEnd(E),this.ended=!0,!1;v.next_out&&(v.avail_out===0||E===l.Z_STREAM_END||v.avail_in===0&&(T===l.Z_FINISH||T===l.Z_SYNC_FLUSH))&&(this.options.to==="string"?(O=u.utf8border(v.output,v.next_out),I=v.next_out-O,J=u.buf2string(v.output,O),v.next_out=I,v.avail_out=_-I,I&&a.arraySet(v.output,v.output,O,I,0),this.onData(J)):this.onData(a.shrinkBuf(v.output,v.next_out))),v.avail_in===0&&v.avail_out===0&&(D=!0)}while((v.avail_in>0||v.avail_out===0)&&E!==l.Z_STREAM_END);return E===l.Z_STREAM_END&&(T=l.Z_FINISH),T===l.Z_FINISH?(E=s.inflateEnd(this.strm),this.onEnd(E),this.ended=!0,E===l.Z_OK):(T===l.Z_SYNC_FLUSH&&(this.onEnd(l.Z_OK),v.avail_out=0),!0)},g.prototype.onData=function(C){this.chunks.push(C)},g.prototype.onEnd=function(C){C===l.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=C,this.msg=this.strm.msg};function b(C,x){var v=new g(x);if(v.push(C,!0),v.err)throw v.msg||c[v.err];return v.result}function w(C,x){return x=x||{},x.raw=!0,b(C,x)}i.Inflate=g,i.inflate=b,i.inflateRaw=w,i.ungzip=b},{"./utils/common":1,"./utils/strings":2,"./zlib/constants":4,"./zlib/gzheader":6,"./zlib/inflate":8,"./zlib/messages":10,"./zlib/zstream":11}]},{},[])("/lib/inflate.js")})();var TM=globalThis.fetch,ca=class{constructor(e,t={},r){this.type=e,this.detail=t,this.msg=r,Object.defineProperty(this,"__mayPropagate",{enumerable:!1,writable:!0}),this.__mayPropagate=!0}preventDefault(){}stopPropagation(){this.__mayPropagate=!1}valueOf(){return this}toString(){return this.msg?`[${this.type} event]: ${this.msg}`:`[${this.type} event]`}},FS=class{constructor(){this.listeners={}}addEventListener(e,t,r){let o=this.listeners[e]||[];r?o.unshift(t):o.push(t),this.listeners[e]=o}removeEventListener(e,t){let r=this.listeners[e]||[],o=r.findIndex(n=>n===t);o>-1&&(r.splice(o,1),this.listeners[e]=r)}dispatch(e){let t=this.listeners[e.type];if(t)for(let r=0,o=t.length;rString.fromCharCode(t)).join("")}var LS=class{constructor(e,t,r){this.name=(r||e.tag||"").trim(),this.length=e.length,this.start=e.offset,this.offset=0,this.data=t,["getInt8","getUint8","getInt16","getUint16","getInt32","getUint32","getBigInt64","getBigUint64"].forEach(o=>{let n=o.replace(/get(Big)?/,"").toLowerCase(),i=parseInt(o.replace(/[^\d]/g,""))/8;Object.defineProperty(this,n,{get:()=>this.getValue(o,i)})})}get currentPosition(){return this.start+this.offset}set currentPosition(e){this.start=e,this.offset=0}skip(e=0,t=8){this.offset+=e*t/8}getValue(e,t){let r=this.start+this.offset;this.offset+=t;try{return this.data[e](r)}catch(o){throw console.error("parser",e,t,this),console.error("parser",this.start,this.offset),o}}flags(e){if(e===8||e===16||e===32||e===64)return this[`uint${e}`].toString(2).padStart(e,0).split("").map(t=>t==="1");console.error("Error parsing flags: flag types can only be 1, 2, 4, or 8 bytes long"),console.trace()}get tag(){let e=this.uint32;return IS([e>>24&255,e>>16&255,e>>8&255,e&255])}get fixed(){let e=this.int16,t=Math.round(1e3*this.uint16/65356);return e+t/1e3}get legacyFixed(){let e=this.uint16,t=this.uint16.toString(16).padStart(4,0);return parseFloat(`${e}.${t}`)}get uint24(){return(this.uint8<<16)+(this.uint8<<8)+this.uint8}get uint128(){let e=0;for(let t=0;t<5;t++){let r=this.uint8;if(e=e*128+(r&127),r<128)break}return e}get longdatetime(){return new Date(AS+1e3*parseInt(this.int64.toString()))}get fword(){return this.int16}get ufword(){return this.uint16}get Offset16(){return this.uint16}get Offset32(){return this.uint32}get F2DOT14(){let e=p.uint16,t=[0,1,-2,-1][e>>14],r=e&16383;return t+r/16384}verifyLength(){this.offset!=this.length&&console.error(`unexpected parsed table size (${this.offset}) for "${this.name}" (expected ${this.length})`)}readBytes(e=0,t=0,r=8,o=!1){if(e=e||this.length,e===0)return[];t&&(this.currentPosition=t);let n=`${o?"":"u"}int${r}`,i=[];for(;e--;)i.push(this[n]);return i}},lt=class{constructor(e){Object.defineProperty(this,"parser",{enumerable:!1,get:()=>e});let r=e.currentPosition;Object.defineProperty(this,"start",{enumerable:!1,get:()=>r})}load(e){Object.keys(e).forEach(t=>{let r=Object.getOwnPropertyDescriptor(e,t);r.get?this[t]=r.get.bind(this):r.value!==void 0&&(this[t]=r.value)}),this.parser.length&&this.parser.verifyLength()}},ke=class extends lt{constructor(e,t,r){let{parser:o,start:n}=super(new LS(e,t,r));Object.defineProperty(this,"p",{enumerable:!1,get:()=>o}),Object.defineProperty(this,"tableStart",{enumerable:!1,get:()=>n})}};function ae(e,t,r){let o;Object.defineProperty(e,t,{get:()=>o||(o=r(),o),enumerable:!0})}var NS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:12},t,"sfnt");this.version=o.uint32,this.numTables=o.uint16,this.searchRange=o.uint16,this.entrySelector=o.uint16,this.rangeShift=o.uint16,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new MS(o)),this.tables={},this.directory.forEach(n=>{let i=()=>r(this.tables,{tag:n.tag,offset:n.offset,length:n.length},t);ae(this.tables,n.tag.trim(),i)})}},MS=class{constructor(e){this.tag=e.tag,this.checksum=e.uint32,this.offset=e.uint32,this.length=e.uint32}},xy=wy.inflate||void 0,Sy=void 0,VS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:44},t,"woff");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new DS(o)),BS(this,t,r)}},DS=class{constructor(e){this.tag=e.tag,this.offset=e.uint32,this.compLength=e.uint32,this.origLength=e.uint32,this.origChecksum=e.uint32}};function BS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=0,i=t;if(o.compLength!==o.origLength){let s=t.buffer.slice(o.offset,o.offset+o.compLength),a;if(xy)a=xy(new Uint8Array(s));else if(Sy)a=Sy(new Uint8Array(s));else{let u="no brotli decoder available to decode WOFF2 font";throw font.onerror&&font.onerror(u),new Error(u)}i=new DataView(a.buffer)}else n=o.offset;return r(e.tables,{tag:o.tag,offset:n,length:o.origLength},i)})})}var Cy=by,_y=void 0,jS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:48},t,"woff2");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.totalCompressedSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(a=>new zS(o));let n=o.currentPosition;this.directory[0].offset=0,this.directory.forEach((a,u)=>{let l=this.directory[u+1];l&&(l.offset=a.offset+(a.transformLength!==void 0?a.transformLength:a.origLength))});let i,s=t.buffer.slice(n);if(Cy)i=Cy(new Uint8Array(s));else if(_y)i=new Uint8Array(_y(s));else{let a="no brotli decoder available to decode WOFF2 font";throw e.onerror&&e.onerror(a),new Error(a)}HS(this,i,r)}},zS=class{constructor(e){this.flags=e.uint8;let t=this.tagNumber=this.flags&63;t===63?this.tag=e.tag:this.tag=US(t);let o=(this.transformVersion=(this.flags&192)>>6)!==0;(this.tag==="glyf"||this.tag==="loca")&&(o=this.transformVersion!==3),this.origLength=e.uint128,o&&(this.transformLength=e.uint128)}};function HS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=o.offset,i=n+(o.transformLength?o.transformLength:o.origLength),s=new DataView(t.slice(n,i).buffer);try{return r(e.tables,{tag:o.tag,offset:0,length:o.origLength},s)}catch(a){console.error(a)}})})}function US(e){return["cmap","head","hhea","hmtx","maxp","name","OS/2","post","cvt ","fpgm","glyf","loca","prep","CFF ","VORG","EBDT","EBLC","gasp","hdmx","kern","LTSH","PCLT","VDMX","vhea","vmtx","BASE","GDEF","GPOS","GSUB","EBSC","JSTF","MATH","CBDT","CBLC","COLR","CPAL","SVG ","sbix","acnt","avar","bdat","bloc","bsln","cvar","fdsc","feat","fmtx","fvar","gvar","hsty","just","lcar","mort","morx","opbd","prop","trak","Zapf","Silf","Glat","Gloc","Feat","Sill"][e&63]}var Fy={},Ay=!1;Promise.all([Promise.resolve().then(function(){return yC}),Promise.resolve().then(function(){return bC}),Promise.resolve().then(function(){return xC}),Promise.resolve().then(function(){return _C}),Promise.resolve().then(function(){return EC}),Promise.resolve().then(function(){return FC}),Promise.resolve().then(function(){return IC}),Promise.resolve().then(function(){return NC}),Promise.resolve().then(function(){return GC}),Promise.resolve().then(function(){return r_}),Promise.resolve().then(function(){return U_}),Promise.resolve().then(function(){return G_}),Promise.resolve().then(function(){return X_}),Promise.resolve().then(function(){return $_}),Promise.resolve().then(function(){return tR}),Promise.resolve().then(function(){return oR}),Promise.resolve().then(function(){return sR}),Promise.resolve().then(function(){return lR}),Promise.resolve().then(function(){return uR}),Promise.resolve().then(function(){return dR}),Promise.resolve().then(function(){return mR}),Promise.resolve().then(function(){return gR}),Promise.resolve().then(function(){return bR}),Promise.resolve().then(function(){return SR}),Promise.resolve().then(function(){return CR}),Promise.resolve().then(function(){return RR}),Promise.resolve().then(function(){return TR}),Promise.resolve().then(function(){return OR}),Promise.resolve().then(function(){return FR}),Promise.resolve().then(function(){return LR}),Promise.resolve().then(function(){return jR}),Promise.resolve().then(function(){return WR}),Promise.resolve().then(function(){return qR}),Promise.resolve().then(function(){return JR}),Promise.resolve().then(function(){return $R}),Promise.resolve().then(function(){return t2}),Promise.resolve().then(function(){return n2}),Promise.resolve().then(function(){return s2}),Promise.resolve().then(function(){return f2}),Promise.resolve().then(function(){return p2}),Promise.resolve().then(function(){return g2})]).then(e=>{e.forEach(t=>{let r=Object.keys(t)[0];Fy[r]=t[r]}),Ay=!0});function WS(e,t,r){let o=t.tag.replace(/[^\w\d]/g,""),n=Fy[o];return n?new n(t,r,e):(console.warn(`lib-font has no definition for ${o}. The table was skipped.`),{})}function GS(){let e=0;function t(r,o){if(!Ay)return e>10?o(new Error("loading took too long")):(e++,setTimeout(()=>t(r),250));r(WS)}return new Promise((r,o)=>t(r))}function YS(e,t){let r=e.lastIndexOf("."),o=(e.substring(r+1)||"").toLowerCase(),n={ttf:"truetype",otf:"opentype",woff:"woff",woff2:"woff2"}[o];if(n)return n;let i={eot:"The .eot format is not supported: it died in January 12, 2016, when Microsoft retired all versions of IE that didn't already support WOFF.",svg:"The .svg format is not supported: SVG fonts (not to be confused with OpenType with embedded SVG) were so bad we took the entire fonts chapter out of the SVG specification again.",fon:"The .fon format is not supported: this is an ancient Windows bitmap font format.",ttc:"Based on the current CSS specification, font collections are not (yet?) supported."}[o];if(i||(i=`${e} is not a known webfont format.`),t)throw new Error(i);console.warn(`Could not load font: ${i}`)}async function qS(e,t,r={}){if(!globalThis.document)return;let o=YS(t,r.errorOnStyle);if(!o)return;let n=document.createElement("style");n.className="injected-by-Font-js";let i=[];return r.styleRules&&(i=Object.entries(r.styleRules).map(([s,a])=>`${s}: ${a};`)),n.textContent=` +`}var Nh={mobile:"480px",tablet:"782px"},Mh=/^(\d+|\d*\.\d+)(px|em|rem)$/,sx=16;function ax(e){return"mobile"in e||"tablet"in e}function lx(e){return!e||typeof e!="object"?{}:ax(e)?e:e.settings?.viewport??{}}function cx(e){return typeof e=="string"&&Mh.test(e.trim())}function Rc(e){if(typeof e=="number")return e;if(typeof e!="string")return;let t=e.trim().match(Mh);if(!t)return;let r=Number.parseFloat(t[1]);return t[2]==="px"?r:r*sx}function Ec(e){let t=lx(e),r={},o={};Object.keys(Nh).forEach(a=>{let u=a,l=t[u],c=Rc(l);c!==void 0&&cx(l)&&(r[u]=l.trim(),o[u]=c)});let n=Object.keys(r);if(!n.length)return{...Nh};if(n.length===1)return r;let i=r.mobile,s=r.tablet;return o.mobile>=o.tablet?{mobile:i}:{mobile:i,tablet:s}}function Vh(e){let t=Ec(e),r={};return t.mobile&&(r["@mobile"]=`@media (width <= ${t.mobile})`),t.tablet&&(r["@tablet"]=t.mobile?`@media (${t.mobile} < width <= ${t.tablet})`:`@media (width <= ${t.tablet})`),r}function Bs(e,t,r,{resolveRefs:o=!0}={}){if(!e?.styles?.blocks?.[t]?.variations?.[r])return;let n=s=>{Object.keys(s).forEach(a=>{let u=s[a];if(typeof u=="object"&&u!==null)if(u.ref!==void 0)if(typeof u.ref!="string"||u.ref.trim()==="")delete s[a];else{let l=ht(e,u.ref);l!=null?s[a]=l:delete s[a]}else n(u),Object.keys(u).length===0&&delete s[a]})},i=JSON.parse(JSON.stringify(e.styles.blocks[t].variations[r]));return o&&n(i),i}var Oc="default";function zh(e){let t=e?.viewport,r=e?.pseudoState;return(!t||t===Oc)&&(!r||r===Oc)}function ux(e){return zh(e)?[]:[e.viewport,e.pseudoState].filter(t=>!!t&&t!==Oc)}function fx(e,t){let r=ux(t);return r.length?ht(e,r):e}var dx=new Set(["blocks","variations","css"]),Tc=Object.freeze({value:{},sources:{}}),px={root:{layer:"root"},element:{layer:"element"},block:{layer:"block"},blockVariation:{layer:"blockVariation"}};function wo(e){let t=px[e];return t?{...t}:null}function xo(e,t){return!e||!t?null:{styles:e,source:t}}function mx(e){return e.join(".")}function hx(e){return{...e}}function Hh(e){return e===""||e===null||typeof e=="object"&&!Array.isArray(e)&&Object.keys(e).length===0}function Pc(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&typeof e.ref=="string"}function So(e){if(!e||typeof e!="object"||Array.isArray(e))return null;let t={};for(let r of Object.keys(e))if(!dx.has(r)){if(r==="elements"){e.elements&&typeof e.elements=="object"&&(t.elements=e.elements);continue}Hh(e[r])||(t[r]=e[r])}return Object.keys(t).length===0?null:t}var Dh=new Set(["backgroundImage"]);function Uh(e,t,r,o,n,i=[]){if(!t||typeof t!="object"||Array.isArray(t))return e;for(let s of Object.keys(t)){let a=t[s];if(Hh(a))continue;if(Pc(a)){if(a.ref.trim()==="")continue;let l=ht(r,a.ref);if(l==null||Pc(l))continue;a=l}let u=[...i,s];if(!Dh.has(s)&&a!==null&&typeof a=="object"&&!Array.isArray(a)&&!Pc(a)){let l=e[s]&&typeof e[s]=="object"&&!Array.isArray(e[s])?e[s]:{};e[s]=Uh({...l},a,r,o,n,u)}else e[s]=Dh.has(s)&&a!==null&&typeof a=="object"&&!Array.isArray(a)?{...a}:a,o&&n&&(n[mx(u)]=hx(o))}return e}function js(e,t){if(!e)return null;let r=fx(e,t);return r&&typeof r=="object"&&!Array.isArray(r)?r:null}var gx=["color.background","color.gradient","background","spacing","dimensions","border","shadow","filter"];function yx(e){return e.startsWith("elements.")?!1:gx.some(t=>e===t||e.startsWith(`${t}.`))}function Wh(e,t){if(!e||typeof e!="object")return;let[r,...o]=t;if(o.length===0){delete e[r];return}let n=e[r];n&&typeof n=="object"&&(Wh(n,o),Object.keys(n).length===0&&delete e[r])}function vx(e,t){for(let r of Object.keys(t))t[r].layer==="root"&&yx(r)&&(Wh(e,r.split(".")),delete t[r])}function bx(e,t,r){let o=e?.background?.backgroundImage;if(!o)return;let n=bc(o,{...t,_links:r??void 0});n!==void 0&&(e.background.backgroundImage=n)}function Bh(e,{blockName:t,variationName:r=null,elements:o=null,viewport:n=null,pseudoState:i=null}={}){if(!e||!e.styles||!t)return Tc;let s=e.styles,a={viewport:n,pseudoState:i},u=s,l=s.blocks?.[t]??null,c=(o??[]).map(w=>s.elements?.[w]??null).filter(w=>!!w),m=r?Bs(e,t,r)??null:null,d=[xo(So(u),wo("root")),...c.map(w=>xo(So(w),wo("element"))),l?xo(So(l),wo("block")):null,m?xo(So(m),wo("blockVariation")):null];zh(a)||d.push(xo(So(js(u,a)),wo("root")),...c.map(w=>xo(So(js(w,a)),wo("element"))),l?xo(So(js(l,a)),wo("block")):null,m?xo(So(js(m,a)),wo("blockVariation")):null);let h=d.filter(Boolean);if(h.length===0)return Tc;let g={},b=h.reduce((w,_)=>Uh(w,_.styles,e,_.source,g),{});return vx(b,g),bx(b,e,e._links??null),{value:b,sources:g}}var wx={},jh=new WeakMap;function Gh(e,t={}){let r=e?.styles;if(!r||typeof r!="object")return Bh(e,t);let o=jh.get(r);o||(o=new WeakMap,jh.set(r,o));let n=e?._links??wx,i=o.get(n);i||(i=new Map,o.set(n,i));let s=`${t.elements?.join(",")??""}:${t.viewport??""}:${t.pseudoState??""}`,a=(t.blockName||"")+""+(t.variationName||"")+""+s;if(i.has(a))return i.get(a);let u=Bh(e,t);return i.set(a,u),u}var Yh=f(ai(),1),{lock:qh,unlock:mI}=(0,Yh.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-engine");var Tn={};qh(Tn,{getResponsiveMediaQueries:Vh,getViewportBreakpoints:Ec,getViewportBreakpointValueInPixels:Rc,getDuotoneFilter:Lh,getDuotoneStylesheet:Ih,getDuotoneUnsetStylesheet:Ah,resolveStyle:Gh,getVariationStyle:Bs});var kc=f(Te(),1);var Zh=f(Te(),1),gt=(0,Zh.createContext)({user:{styles:{},settings:{}},base:{styles:{},settings:{}},merged:{styles:{},settings:{}},onChange:()=>{},fontLibraryEnabled:!1});var Xh=f(Z(),1);function gi({children:e,value:t,baseValue:r,onChange:o,fontLibraryEnabled:n}){let i=(0,kc.useMemo)(()=>Go(r,t),[r,t]),s=(0,kc.useMemo)(()=>({user:t,base:r,merged:i,onChange:o,fontLibraryEnabled:n}),[t,r,i,o,n]);return(0,Xh.jsx)(gt.Provider,{value:s,children:e})}var eo=f(ue(),1),dg=f(ge(),1);var Lx=f(Kt(),1),Nx=f(sr(),1);var Kh=f(Z(),1);function Fc({className:e,...t}){return(0,Kh.jsx)(ci,{className:We(e,"global-styles-ui-icon-with-current-color"),...t})}var _o=f(ue(),1);var Yo=f(Z(),1);function xx({icon:e,children:t,...r}){return(0,Yo.jsxs)(_o.__experimentalItem,{...r,children:[e&&(0,Yo.jsxs)(_o.__experimentalHStack,{justify:"flex-start",children:[(0,Yo.jsx)(Fc,{icon:e,size:24}),(0,Yo.jsx)(_o.FlexItem,{children:t})]}),!e&&t]})}function Qr(e){return(0,Yo.jsx)(_o.Navigator.Button,{as:xx,...e})}var Cx=f(ue(),1);var Rx=f(ge(),1),rg=f(Dt(),1);var Rr=f(Te(),1),eg=f(Kt(),1),tg=f(sr(),1),Ic=f(ge(),1);var dt=f(ge(),1);var Jh=f(ai(),1),{lock:BI,unlock:De}=(0,Jh.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/global-styles-ui");var{getViewportBreakpoints:UI}=De(Tn),WI={link:[{value:":link",label:(0,dt.__)("Link")},{value:":any-link",label:(0,dt.__)("Any Link")},{value:":visited",label:(0,dt.__)("Visited")},{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}],button:[{value:":link",label:(0,dt.__)("Link")},{value:":any-link",label:(0,dt.__)("Any Link")},{value:":visited",label:(0,dt.__)("Visited")},{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}]},GI={"core/button":[{value:":hover",label:(0,dt.__)("Hover")},{value:":focus",label:(0,dt.__)("Focus")},{value:":focus-visible",label:(0,dt.__)("Focus-visible")},{value:":active",label:(0,dt.__)("Active")}]},YI=[{value:"@tablet",label:(0,dt.__)("Tablet")},{value:"@mobile",label:(0,dt.__)("Mobile")}];function Ac(e,t){if(!t?.length||typeof e!="object"||!e||!Object.keys(e).length)return e;for(let r in e)t.includes(r)?delete e[r]:typeof e[r]=="object"&&Ac(e[r],t);return e}var zs=(e,t)=>{if(!e||!t?.length)return{};let r={};return Object.keys(e).forEach(o=>{if(t.includes(o))r[o]=e[o];else if(typeof e[o]=="object"){let n=zs(e[o],t);Object.keys(n).length&&(r[o]=n)}}),r};function yi(e,t){let r=zs(structuredClone(e),t);return pi(r,e)}function Qh(e,t){if(!Array.isArray(e)||!t)return null;let o=t.replace("var(","").replace(")","")?.split("--").slice(-1)[0];return e.find(n=>n.slug===o)}function $h(e){let t=e?.settings?.typography?.fontFamilies?.theme,r=e?.settings?.typography?.fontFamilies?.custom,o=[];t&&r?o=[...t,...r]:t?o=t:r&&(o=r);let n=e?.styles?.typography?.fontFamily,i=Qh(o,n),s=e?.styles?.elements?.heading?.typography?.fontFamily,a;return s?a=Qh(o,e?.styles?.elements?.heading?.typography?.fontFamily):a=i,[i,a]}function qe(e,t,r="merged",o=!0,n){let{user:i,base:s,merged:a,onChange:u}=(0,Rr.useContext)(gt),l=n?.split(".").filter(Boolean)??[],c=l.find(w=>w.startsWith(":")),m=l.filter(w=>!w.startsWith(":")).join("."),d=[e,m].filter(Boolean).join("."),h=a;r==="base"?h=s:r==="user"&&(h=i);let g=(0,Rr.useMemo)(()=>{let w=Vs(h,d,t,o);return c?w?.[c]??{}:w},[h,d,t,o,c]),b=(0,Rr.useCallback)(w=>{let _=w;c&&(_={...Vs(i,d,t,!1),[c]:w});let x=wc(i,d,_,t);u(x)},[i,u,d,t,c]);return[g,b]}function Ke(e,t,r="merged"){let{user:o,base:n,merged:i,onChange:s}=(0,Rr.useContext)(gt),a=i;r==="base"?a=n:r==="user"&&(a=o);let u=(0,Rr.useMemo)(()=>gc(a,e,t),[a,e,t]),l=(0,Rr.useCallback)(c=>{let m=yc(o,e,c,t);s(m)},[o,s,e,t]);return[u,l]}var Sx=[];function _x({title:e,settings:t,styles:r}){return e===(0,Ic.__)("Default")||Object.keys(t||{}).length>0||Object.keys(r||{}).length>0}function Hs(e=[]){let{variationsFromTheme:t}=(0,eg.useSelect)(o=>({variationsFromTheme:o(tg.store).__experimentalGetCurrentThemeGlobalStylesVariations?.()||Sx}),[]),{user:r}=(0,Rr.useContext)(gt);return(0,Rr.useMemo)(()=>{let o=structuredClone(r),n=Ac(o,e);n.title=(0,Ic.__)("Default");let i=t.filter(a=>yi(a,e)).map(a=>Go(n,a)),s=[n,...i];return s?.length?s.filter(_x):[]},[e,r,t])}var Lc=f(Z(),1),{useHasDimensionsPanel:tL,useHasTypographyPanel:rL,useHasColorPanel:oL,useSettingsForBlockElement:nL,useHasBackgroundPanel:iL}=De(rg.privateApis);var Hr=f(ue(),1);function Pn(){let[e="black"]=qe("color.text"),[t="white"]=qe("color.background"),[r=e]=qe("elements.h1.color.text"),[o=r]=qe("elements.link.color.text"),[n=o]=qe("elements.button.color.background"),[i]=Ke("color.palette.core")||[],[s]=Ke("color.palette.theme")||[],[a]=Ke("color.palette.custom")||[],u=(s??[]).concat(a??[]).concat(i??[]),l=u.filter(({color:d})=>d===e),c=u.filter(({color:d})=>d===n),m=l.concat(c).concat(u).filter(({color:d})=>d!==t).slice(0,2);return{paletteColors:u,highlightedColors:m}}var sg=f(Te(),1),ag=f(ue(),1),Vc=f(ge(),1);function Ex(e,t){return t.length===0?null:(t.sort((r,o)=>Math.abs(e-r)-Math.abs(e-o)),t[0])}var Tx={normal:400,bold:700};function og(e){return e!==void 0&&Number.isFinite(e)&&e>=1&&e<=1e3}function Nc(e){let t=String(e??"").trim().toLowerCase().split(/\s+/).filter(Boolean).map(n=>Tx[n]??Number(n)),[r,o]=t;return og(r)?t.length!==2||!og(o)?String(r):String(Math.min(Math.max(400,r),o)):"400"}function ng(e){let t=/^(?!generic\([ a-zA-Z\-]+\)$)(?!var\(\s*--[\w-]+\s*\)$)(?!^[a-zA-Z\-]+$).+/,r=e.trim(),o=n=>(n=n.trim(),n.match(t)?(n=n.replace(/^["']|["']$/g,""),`"${n}"`):n);return r.includes(",")?r.split(",").map(o).filter(n=>n!=="").join(", "):o(r)}function Mc(e){if(!e)return"";let t=e.trim();return t.includes(",")&&(t=(t.split(",").find(r=>r.trim()!=="")??"").trim()),t=t.replace(/^["']|["']$/g,""),window.navigator.userAgent.toLowerCase().includes("firefox")&&(t=`"${t}"`),t}function On(e){let t={fontFamily:ng(e.fontFamily)};if(!("fontFace"in e)||!Array.isArray(e.fontFace))return t.fontWeight="400",t.fontStyle="normal",t;if(e.fontFace){let r=e.fontFace.filter(o=>o?.fontStyle&&o.fontStyle.toLowerCase()==="normal");if(r.length>0){t.fontStyle="normal";let o=r.map(n=>Number(Nc(n.fontWeight)));t.fontWeight=String(Ex(400,o)??400)}else t.fontStyle=e.fontFace.length&&e.fontFace[0].fontStyle||"normal",t.fontWeight=e.fontFace.length&&Nc(e.fontFace[0].fontWeight)||"400"}return t}function ig(e){return{fontFamily:ng(e.fontFamily),fontStyle:e.fontStyle||"normal",fontWeight:Nc(e.fontWeight)}}var vi=f(Z(),1);function Us({fontSize:e,variation:t}){let{base:r}=(0,sg.useContext)(gt),o=r;t&&(o={...r,...t});let[n]=qe("color.text"),[i,s]=$h(o),a=i?On(i):{},u=s?On(s):{};return n&&(a.color=n,u.color=n),e&&(a.fontSize=e,u.fontSize=e),(0,vi.jsxs)(ag.__unstableMotion.div,{animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:.3,type:"tween"},style:{textAlign:"center",lineHeight:1},children:[(0,vi.jsx)("span",{style:u,children:(0,Vc._x)("A","Uppercase letter A")}),(0,vi.jsx)("span",{style:a,children:(0,Vc._x)("a","Lowercase letter A")})]})}var lg=f(ue(),1);var cg=f(Z(),1);function ug({normalizedColorSwatchSize:e,ratio:t}){let{highlightedColors:r}=Pn(),o=e*t;return r.map(({slug:n,color:i},s)=>(0,cg.jsx)(lg.__unstableMotion.div,{style:{height:o,width:o,background:i,borderRadius:o/2},animate:{scale:1,opacity:1},initial:{scale:.1,opacity:0},transition:{delay:s===1?.2:.1}},`${n}-${s}`))}var fg=f(ue(),1),kn=f(yo(),1),qo=f(Te(),1);var $r=f(Z(),1),Dc=248,Bc=152,Px={leading:!0,trailing:!0};function Ox({children:e,label:t,isFocused:r,withHoverView:o}){let[n="white"]=qe("color.background"),[i]=qe("color.gradient"),s=(0,kn.useReducedMotion)(),[a,u]=(0,qo.useState)(!1),[l,{width:c}]=(0,kn.useResizeObserver)(),[m,d]=(0,qo.useState)(c),[h,g]=(0,qo.useState)(),b=(0,kn.useThrottle)(d,250,Px);(0,qo.useLayoutEffect)(()=>{c&&b(c)},[c,b]),(0,qo.useLayoutEffect)(()=>{let v=m?m/Dc:1,C=v-(h||0);(Math.abs(C)>.1||!h)&&g(v)},[m,h]);let w=c?c/Dc:1,_=h||w,x=!!c;return(0,$r.jsxs)($r.Fragment,{children:[(0,$r.jsx)("div",{style:{position:"relative"},children:l}),!x&&(0,$r.jsx)(ui,{className:"global-styles-ui-preview__wrapper",style:{aspectRatio:Dc/Bc}}),x&&(0,$r.jsx)("div",{className:We("global-styles-ui-preview__wrapper",{"is-hoverable":o}),style:{height:Bc*_},onMouseEnter:()=>u(!0),onMouseLeave:()=>u(!1),tabIndex:-1,children:(0,$r.jsx)(fg.__unstableMotion.div,{style:{height:Bc*_,width:"100%",background:i??n},initial:"start",animate:(a||r)&&!s&&t?"hover":"start",children:[].concat(e).map((v,C)=>v({ratio:_,key:C}))})})]})}var Fn=Ox;var Jt=f(Z(),1),kx={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},Fx={hover:{opacity:1},start:{opacity:.5}},Ax={hover:{scale:1,opacity:1},start:{scale:0,opacity:0}};function Ix({label:e,isFocused:t,withHoverView:r,variation:o}){let[n]=qe("typography.fontWeight"),[i="serif"]=qe("typography.fontFamily"),[s=i]=qe("elements.h1.typography.fontFamily"),[a=n]=qe("elements.h1.typography.fontWeight"),[u="black"]=qe("color.text"),[l=u]=qe("elements.h1.color.text"),{paletteColors:c}=Pn();return(0,Jt.jsxs)(Fn,{label:e,isFocused:t,withHoverView:r,children:[({ratio:m,key:d})=>(0,Jt.jsx)(Hr.__unstableMotion.div,{variants:kx,style:{height:"100%",overflow:"hidden"},children:(0,Jt.jsxs)(Hr.__experimentalHStack,{spacing:10*m,justify:"center",style:{height:"100%",overflow:"hidden"},children:[(0,Jt.jsx)(Us,{fontSize:65*m,variation:o}),(0,Jt.jsx)(Hr.__experimentalVStack,{spacing:4*m,children:(0,Jt.jsx)(ug,{normalizedColorSwatchSize:32,ratio:m})})]})},d),({key:m})=>(0,Jt.jsx)(Hr.__unstableMotion.div,{variants:r?Fx:void 0,style:{height:"100%",width:"100%",position:"absolute",top:0,overflow:"hidden",filter:"blur(60px)",opacity:.1},children:(0,Jt.jsx)(Hr.__experimentalHStack,{spacing:0,justify:"flex-start",style:{height:"100%",overflow:"hidden"},children:c.slice(0,4).map(({color:d},h)=>(0,Jt.jsx)("div",{style:{height:"100%",background:d,flexGrow:1}},h))})},m),({ratio:m,key:d})=>(0,Jt.jsx)(Hr.__unstableMotion.div,{variants:Ax,style:{height:"100%",width:"100%",overflow:"hidden",position:"absolute",top:0},children:(0,Jt.jsx)(Hr.__experimentalVStack,{spacing:3*m,justify:"center",style:{height:"100%",overflow:"hidden",padding:10*m,boxSizing:"border-box"},children:e&&(0,Jt.jsx)("div",{style:{fontSize:40*m,fontFamily:s,color:l,fontWeight:a,lineHeight:"1em",textAlign:"center"},children:e})})},d)]})}var jc=Ix;var pg=f(Z(),1);var Uc=f(Cn(),1),Ro=f(ge(),1),Ur=f(ue(),1);var Wc=f(Kt(),1),dr=f(Te(),1),Ws=f(Dt(),1),bg=f(yo(),1);import{speak as Bx}from"@wordpress/a11y";var mg=f(Cn(),1),hg=f(Kt(),1),Mx=f(ue(),1);var Vx=f(Z(),1);function Dx(e,t){return e?.filter(r=>r.source==="block"||t.includes(r.name))||[]}function zc(e){let t=(0,hg.useSelect)(n=>{let{getBlockStyles:i}=n(mg.store);return i(e)},[e]),[r]=qe("variations",e),o=Object.keys(r??{});return Dx(t,o)}var Co=f(ue(),1),gg=f(ge(),1);var yg=f(Dt(),1);var vg=f(Z(),1),{StateControl:VL,StateControlBadges:DL}=De(yg.privateApis);var Bt=f(Z(),1),{useHasDimensionsPanel:jx,useHasTypographyPanel:zx,useHasBorderPanel:Hx,useSettingsForBlockElement:Ux,useHasColorPanel:Wx,useHasBackgroundPanel:Gx}=De(Ws.privateApis),{Menu:ZL}=De(Ur.privateApis);function Hc(e){return e==null?!1:Array.isArray(e)?e.length>0:typeof e=="object"?Object.values(e).some(Hc):!0}function Yx(e,t){return Hc(e?.styles?.blocks?.[t])||Hc(e?.settings?.blocks?.[t])}function qx(){let e=(0,Wc.useSelect)(n=>n(Uc.store).getBlockTypes(),[]),t=(n,i)=>{let{core:s,noncore:a}=n;return(i.name.startsWith("core/")?s:a).push(i),n},{core:r,noncore:o}=e.reduce(t,{core:[],noncore:[]});return[...r,...o]}function Zx(e){let[t]=Ke("",e),r=Ux(t,e),o=zx(r),n=Wx(r),i=Gx(r),s=Hx(r),a=jx(r),u=s||a,l=!!zc(e)?.length;return o||n||i||u||l}function Xx({block:e,isCustomized:t}){return Zx(e.name)?(0,Bt.jsx)(Qr,{path:"/blocks/"+encodeURIComponent(e.name),children:(0,Bt.jsxs)(Ur.__experimentalHStack,{justify:"flex-start",spacing:2,children:[(0,Bt.jsx)(Ws.BlockIcon,{className:"global-styles-ui-block-types-item__icon",icon:e.icon}),(0,Bt.jsx)(Ur.FlexItem,{children:e.title}),t&&(0,Bt.jsxs)(Bt.Fragment,{children:[(0,Bt.jsx)(rc,{children:(0,Ro.__)("Has custom styles")}),(0,Bt.jsx)("span",{"aria-hidden":"true",className:"global-styles-ui-block-types-item__indicator"})]})]})}):null}function Kx({filterValue:e,styleFilter:t}){let r=t==="customized"&&!e?(0,Ro.__)("You haven't customized any blocks yet."):(0,Ro.__)("No blocks found.");return(0,Bt.jsx)(Ur.__experimentalText,{align:"center",as:"p",className:"global-styles-ui-block-types-item-list__no-results",children:r})}function Jx({filterValue:e,styleFilter:t}){let r=qx(),o=(0,bg.useDebounce)(Bx,500),{isMatchingSearchTerm:n}=(0,Wc.useSelect)(Uc.store),{user:i}=(0,dr.useContext)(gt),s=(0,dr.useMemo)(()=>{let m=new Set;return[...Object.keys(i?.styles?.blocks??{}),...Object.keys(i?.settings?.blocks??{})].forEach(h=>{Yx(i,h)&&m.add(h)}),m},[i]),a=e?r.filter(m=>n(m,e)):r,u=t==="customized"?a.filter(m=>s.has(m.name)):a,l=(0,dr.useRef)(null),c=u.length>0;return(0,dr.useEffect)(()=>{if(!e&&t==="all")return;let m=c&&l.current?.childElementCount||0,d=(0,Ro.sprintf)((0,Ro._n)("%d result found.","%d results found.",m),m);o(d,"polite")},[e,t,c,o]),(0,Bt.jsx)("div",{ref:l,className:"global-styles-ui-block-types-item-list",role:"list",children:u.length===0?(0,Bt.jsx)(Kx,{filterValue:e,styleFilter:t}):u.map(m=>(0,Bt.jsx)(Xx,{block:m,isCustomized:s.has(m.name)},"menu-itemblock-"+m.name))})}var XL=(0,dr.memo)(Jx);var oS=f(Cn(),1),_g=f(Dt(),1),Gc=f(Te(),1),nS=f(Kt(),1),iS=f(sr(),1),Yc=f(ue(),1),Cg=f(ge(),1);var Qx=f(Dt(),1),wg=f(Cn(),1),$x=f(ue(),1),eS=f(Te(),1);var tS=f(Z(),1),{getViewportBreakpoints:rN,getViewportBreakpointValueInPixels:oN}=De(Tn);var xg=f(ue(),1),Sg=f(Z(),1);function Er({children:e,level:t=2}){return(0,Sg.jsx)(xg.__experimentalHeading,{className:"global-styles-ui-subtitle",level:t,children:e})}var qc=f(Z(),1);var{useHasDimensionsPanel:vN,useHasTypographyPanel:bN,useHasBorderPanel:wN,useSettingsForBlockElement:xN,useHasColorPanel:SN,useHasFiltersPanel:_N,useHasImageSettingsPanel:CN,useHasBackgroundPanel:RN,BackgroundPanel:EN,BorderPanel:TN,ColorPanel:PN,TypographyPanel:ON,DimensionsPanel:kN,FiltersPanel:FN,ImageSettingsPanel:AN,AdvancedPanel:IN}=De(_g.privateApis);var v2=f(ge(),1),b2=f(ue(),1),w2=f(Te(),1);var sS=f(ue(),1);var aS=f(Z(),1);var lS=f(ge(),1),Gs=f(ue(),1);var Rg=f(Z(),1);var Zs=f(ue(),1);var Eg=f(ue(),1);var Ys=f(Z(),1),cS=({variation:e,isFocused:t,withHoverView:r})=>(0,Ys.jsx)(Fn,{label:e.title,isFocused:t,withHoverView:r,children:({ratio:o,key:n})=>(0,Ys.jsx)(Eg.__experimentalHStack,{spacing:10*o,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Ys.jsx)(Us,{variation:e,fontSize:85*o})},n)}),Tg=cS;var Zo=f(Te(),1),Og=f(Zc(),1),qs=f(ge(),1);var Eo=f(Z(),1);function An({variation:e,children:t,isPill:r=!1,properties:o,showTooltip:n=!1}){let[i,s]=(0,Zo.useState)(!1),{base:a,user:u,onChange:l}=(0,Zo.useContext)(gt),c=(0,Zo.useMemo)(()=>{let w=Go(a,e);return o&&(w=zs(w,o)),{user:e,base:a,merged:w,onChange:()=>{}}},[e,a,o]),m=()=>l(e),d=w=>{w.keyCode===Og.ENTER&&(w.preventDefault(),m())},h=(0,Zo.useMemo)(()=>pi(u,e),[u,e]),g=e?.title;e?.description&&(g=(0,qs.sprintf)((0,qs._x)("%1$s (%2$s)","variation label"),e?.title,e?.description));let b=(0,Eo.jsx)("div",{className:We("global-styles-ui-variations_item",{"is-active":h}),role:"button",onClick:m,onKeyDown:d,tabIndex:0,"aria-label":g,"aria-current":h,onFocus:()=>s(!0),onBlur:()=>s(!1),children:(0,Eo.jsx)("div",{className:We("global-styles-ui-variations_item-preview",{"is-pill":r}),children:t(i)})});return(0,Eo.jsx)(gt.Provider,{value:c,children:n?(0,Eo.jsxs)(xn.Root,{children:[(0,Eo.jsx)(xn.Trigger,{render:b}),(0,Eo.jsx)(xn.Popup,{children:e?.title})]}):b})}var Xo=f(Z(),1),kg=["typography"];function Xs({title:e,gap:t=2}){let r=Hs(kg);return r?.length<=1?null:(0,Xo.jsxs)(Zs.__experimentalVStack,{spacing:3,children:[e&&(0,Xo.jsx)(Er,{level:3,children:e}),(0,Xo.jsx)(Zs.__experimentalGrid,{columns:3,gap:t,className:"global-styles-ui-style-variations-container",children:r.map((o,n)=>(0,Xo.jsx)(An,{variation:o,properties:kg,showTooltip:!0,children:()=>(0,Xo.jsx)(Tg,{variation:o})},n))})]})}var g2=f(ge(),1),Ri=f(ue(),1);var y2=f(Te(),1);var to=f(Te(),1),ko=f(Kt(),1),Oo=f(sr(),1),Qc=f(ge(),1);var Xc=f(Ag(),1),Ig=f(sr(),1),Lg="/wp/v2/font-families";function Ng(e){let{receiveEntityRecords:t}=e.dispatch(Ig.store);t("postType","wp_font_family",[],void 0,!0)}async function Mg(e,t){let o=await(0,Xc.default)({path:Lg,method:"POST",body:e});return Ng(t),{id:o.id,...o.font_family_settings,fontFace:[]}}async function Vg(e,t,r){let o={path:`${Lg}/${e}/font-faces`,method:"POST",body:t},n=await(0,Xc.default)(o);return Ng(r),{id:n.id,...n.font_face_settings}}var In=function(){return In=Object.assign||function(t){for(var r,o=1,n=arguments.length;o{o.forEach(n=>{n.family===Mc(e?.fontFamily)&&n.weight===e?.fontWeight&&n.style===e?.fontStyle&&o.delete(n)})};if((t==="document"||t==="all")&&r(document.fonts),t==="iframe"||t==="all"){let o=document.querySelector('iframe[name="editor-canvas"]');o?.contentDocument&&r(o.contentDocument.fonts)}}function Ln(e){if(!e)return;let t;if(Array.isArray(e)?t=e[0]:t=e,!t.startsWith("file:."))return dS(t)||(t=encodeURI(t)),t}function qg(e){let t=new FormData,{fontFace:r,category:o,...n}=e,i={...n,slug:Ks(e.slug)};return t.append("font_family_settings",JSON.stringify(i)),t}function Zg(e){return(e?.fontFace??[]).map((r,o)=>{let n={...r},i=new FormData;if(n.file){let s=Array.isArray(n.file)?n.file:[n.file],a=[];s.forEach((u,l)=>{let c=`file-${o}-${l}`;i.append(c,u,u.name),a.push(c)}),n.src=a.length===1?a[0]:a,delete n.file,i.append("font_face_settings",JSON.stringify(n))}else i.append("font_face_settings",JSON.stringify(n));return i})}async function Xg(e,t,r){let o=[];for(let i of t)try{let s=await Vg(e,i,r);o.push({status:"fulfilled",value:s})}catch(s){o.push({status:"rejected",reason:s})}let n={errors:[],successes:[]};return o.forEach((i,s)=>{if(i.status==="fulfilled"&&i.value){let a=i.value;n.successes.push(a)}else i.reason&&n.errors.push({data:t[s],message:i.reason.message})}),n}async function Kg(e){e=Array.isArray(e)?e:[e];let t=await Promise.all(e.map(async r=>fetch(new Request(r)).then(o=>{if(!o.ok)throw new Error(`Error downloading font face asset from ${r}. Server responded with status: ${o.status}`);return o.blob()}).then(o=>{let n=r.split("/").pop();return new Gg([o],n,{type:o.type})})));return t.length===1?t[0]:t}function Jc(e,t){return t.findIndex(r=>r.fontWeight===e.fontWeight&&r.fontStyle===e.fontStyle)!==-1}function Jg(e,t,r){t=Array.isArray(t)?[...t]:[t],e=Array.isArray(e)?[...e]:{...e};let o=t.pop(),n=e;for(let i of t){let s=n[i];n=n[i]=Array.isArray(s)?[...s]:{...s}}return n[o]=r,e}function Qs(e,t,r=[]){let o=u=>u.slug===e.slug,n=u=>u.find(o),i=u=>u?r.filter(l=>!o(l)):[...r,e],s=u=>{let l=m=>m.fontWeight===t.fontWeight&&m.fontStyle===t.fontStyle;if(!u)return[...r,{...e,fontFace:[t]}];let c=u.fontFace||[];return c.find(l)?c=c.filter(m=>!l(m)):c=[...c,t],c.length===0?r.filter(m=>!o(m)):r.map(m=>o(m)?{...m,fontFace:c}:m)},a=n(r);return t?s(a):i(a)}var Qg=f(Z(),1),jt=(0,to.createContext)({});jt.displayName="FontLibraryContext";function mS({children:e}){let t=(0,ko.useRegistry)(),{saveEntityRecord:r,deleteEntityRecord:o}=(0,ko.useDispatch)(Oo.store),{globalStylesId:n}=(0,ko.useSelect)(R=>{let{__experimentalGetCurrentGlobalStylesId:B}=R(Oo.store);return{globalStylesId:B()}},[]),i=(0,Oo.useEntityRecord)("root","globalStyles",n??0,{enabled:n!==void 0}),[s,a]=(0,to.useState)(!1),{records:u=[],isResolving:l}=(0,Oo.useEntityRecords)("postType","wp_font_family",{_embed:!0}),c=(u||[]).map(R=>({id:R.id,...R.font_family_settings||{},fontFace:R?._embedded?.font_faces?.map(B=>B.font_face_settings)||[]}))||[],[m,d]=Ke("typography.fontFamilies"),h=async R=>{if(!i.record)return;let B=i.record,re=Jg(B??{},["settings","typography","fontFamilies"],R);await r("root","globalStyles",re)},[g,b]=(0,to.useState)(""),[w,_]=(0,to.useState)(void 0),x=m?.theme?m.theme.map(R=>To(R,{source:"theme"})).sort((R,B)=>R.name.localeCompare(B.name)):[],v=m?.custom?m.custom.map(R=>To(R,{source:"custom"})).sort((R,B)=>R.name.localeCompare(B.name)):[],C=c?c.map(R=>To(R,{source:"custom"})).sort((R,B)=>R.name.localeCompare(B.name)):[];(0,to.useEffect)(()=>{g||_(void 0)},[g]);let k=R=>{if(!R){_(void 0);return}let re=(R.source==="theme"?x:C).find(P=>P.slug===R.slug);_({...re||R,source:R.source})},[E]=(0,to.useState)(new Set),T=R=>R.reduce((re,P)=>{let W=P?.fontFace&&P.fontFace?.length>0?P?.fontFace.map(ne=>`${ne.fontStyle??""}${ne.fontWeight??""}`):["normal400"];return re[P.slug]=W,re},{}),O=R=>T(R==="theme"?x:v),I=(R,B,re,P)=>!B&&!re?!!O(P)[R]:!!O(P)[R]?.includes((B??"")+(re??"")),J=(R,B)=>O(B)[R]||[];async function D(R){a(!0);try{let B=[],re=[];for(let W of R){let ne=!1,xe=await(0,ko.resolveSelect)(Oo.store).getEntityRecords("postType","wp_font_family",{slug:W.slug,per_page:1,_embed:!0}),se=xe&&xe.length>0?xe[0]:null,be=se?{id:se.id,...se.font_family_settings,fontFace:(se?._embedded?.font_faces??[]).map(Fe=>Fe.font_face_settings)||[]}:null;be||(ne=!0,be=await Mg(qg(W),t));let ye=be.fontFace&&W.fontFace?be.fontFace.filter(Fe=>Fe&&W.fontFace&&Jc(Fe,W.fontFace)):[];be.fontFace&&W.fontFace&&(W.fontFace=W.fontFace.filter(Fe=>!Jc(Fe,be.fontFace)));let $=[],Ce=[];if(W?.fontFace?.length??!1){let Fe=await Xg(be.id,Zg(W),t);$=Fe?.successes,Ce=Fe?.errors}($?.length>0||ye?.length>0)&&(be.fontFace=[...$],B.push(be)),be&&!W?.fontFace?.length&&B.push(be),ne&&(W?.fontFace?.length??0)>0&&$?.length===0&&await o("postType","wp_font_family",be.id,{force:!0}),re=re.concat(Ce)}let P=re.reduce((W,ne)=>W.includes(ne.message)?W:[...W,ne.message],[]);if(B.length>0){let W=Y(B);await h(W)}if(P.length>0){let W=new Error((0,Qc.__)("There was an error installing fonts."));throw W.installationErrors=P,W}}finally{a(!1)}}async function S(R){if(!R?.id)throw new Error((0,Qc.__)("Font family to uninstall is not defined."));try{await o("postType","wp_font_family",R.id,{force:!0});let B=L(R);return await h(B),{deleted:!0}}catch(B){throw console.error("There was an error uninstalling the font family:",B),B}}let L=R=>{let re=(m?.[R.source??""]??[]).filter(W=>W.slug!==R.slug),P={...m,[R.source??""]:re};return d(P),R.fontFace&&R.fontFace.forEach(W=>{bi(W,"all")}),P},Y=R=>{let B=A(R),re={...m,custom:Yg(m?.custom,B)};return d(re),N(B),re},A=R=>R.map(({id:B,fontFace:re,...P})=>({...P,...re&&re.length>0?{fontFace:re.map(({id:W,...ne})=>ne)}:{}})),N=R=>{R.forEach(B=>{B.fontFace&&B.fontFace.forEach(re=>{let P=Ln(re?.src??"");P&&Po(re,P,"all")})})},q=(R,B)=>{let re=m?.[R.source??""]??[],P=Qs(R,B,re);d({...m,[R.source??""]:P});let W=I(R.slug,B?.fontStyle??"",B?.fontWeight??"",R.source??"custom");if(B&&W)bi(B,"all");else{let ne=Ln(B?.src??"");B&&ne&&Po(B,ne,"all")}},U=async R=>{if(!R.src)return;let B=Ln(R.src);!B||E.has(B)||(Po(R,B,"document"),E.add(B))};return(0,Qg.jsx)(jt.Provider,{value:{libraryFontSelected:w,handleSetLibraryFontSelected:k,fontFamilies:m??{},baseCustomFonts:C,isFontActivated:I,getFontFacesActivated:J,loadFontFaceAsset:U,installFonts:D,uninstallFontFamily:S,toggleActivateFont:q,getAvailableFontsOutline:T,modalTabOpen:g,setModalTabOpen:b,saveFontFamilies:h,isResolvingLibrary:l,isInstalling:s},children:e})}var $s=mS;var ma=f(ge(),1),ou=f(ue(),1),Ly=f(sr(),1),m2=f(Kt(),1);var Ie=f(ue(),1),xi=f(sr(),1),$c=f(Kt(),1),Gr=f(Te(),1),st=f(ge(),1);var Mn=f(ge(),1),ea=f(Te(),1),mr=f(ue(),1);var Tr=f(Te(),1);var ro=f(Z(),1),$g=new Set;function hS(e){if(e.preview)return e.preview;if(e.src)return Array.isArray(e.src)?e.src[0]:e.src}function gS(e){return"fontStyle"in e&&e.fontStyle||"fontWeight"in e&&e.fontWeight?e:"fontFace"in e&&e.fontFace&&e.fontFace.length?e.fontFace.find(t=>t.fontStyle==="normal"&&t.fontWeight==="400")||e.fontFace[0]:{fontStyle:"normal",fontWeight:"400",fontFamily:e.fontFamily}}function yS({font:e,text:t}){let r=(0,Tr.useRef)(null),o=gS(e),n=On(e);t=t||("name"in e?e.name:"");let s=e.preview??hS(o),a=!!(s&&/\.(png|jpg|jpeg|gif|svg)$/i.test(s)),[u,l]=(0,Tr.useState)(!1),[c,m]=(0,Tr.useState)(!1),[d,h]=(0,Tr.useState)(),{loadFontFaceAsset:g}=(0,Tr.useContext)(jt),b=a?!!s&&($g.has(s)||d===s):c,w=Math.min(Math.max(t.length*12,48),300),_=ig(o),x={fontSize:"18px",lineHeight:1,opacity:b?"1":"0",...n,..._};return(0,Tr.useEffect)(()=>{if(a)return;let v=new window.IntersectionObserver(([C])=>{l(C.isIntersecting)},{});return r.current&&v.observe(r.current),()=>v.disconnect()},[a]),(0,Tr.useEffect)(()=>{(async()=>u&&!a&&(o.src&&await g(o),m(!0)))()},[o,u,g,a]),(0,ro.jsx)("div",{ref:r,className:"font-library__font-demo",children:a?(0,ro.jsxs)(ro.Fragment,{children:[!b&&(0,ro.jsx)(ui,{className:"font-library__font-variant-demo-skeleton",style:{width:w}}),(0,ro.jsx)("img",{src:s,loading:"lazy",alt:t,onLoad:()=>{s&&$g.add(s),h(s)},onError:()=>h(s),className:We("font-library__font-variant_demo-image",{"is-loading":!b})})]}):(0,ro.jsx)("span",{style:x,className:"font-library__font-variant_demo-text",children:t})})}var Nn=yS;var Wr=f(Z(),1);function vS({font:e,onClick:t,variantsText:r,navigatorPath:o,shouldFocus:n}){let i=e.fontFace?.length||1,s={cursor:t?"pointer":"default"},a=(0,mr.useNavigator)(),u=(0,ea.useRef)(null);return(0,ea.useEffect)(()=>{n&&u.current?.focus()},[n]),(0,Wr.jsx)(mr.Button,{ref:u,__next40pxDefaultSize:!0,onClick:()=>{t(),o&&a.goTo(o)},style:s,className:"font-library__font-card",children:(0,Wr.jsxs)(mr.Flex,{justify:"space-between",wrap:!1,children:[(0,Wr.jsx)(Nn,{font:e}),(0,Wr.jsxs)(mr.Flex,{justify:"flex-end",children:[(0,Wr.jsx)(mr.FlexItem,{children:(0,Wr.jsx)(mr.__experimentalText,{className:"font-library__font-card__count",children:r||(0,Mn.sprintf)((0,Mn._n)("%d variant","%d variants",i),i)})}),(0,Wr.jsx)(mr.FlexItem,{children:(0,Wr.jsx)(ci,{icon:(0,Mn.isRTL)()?Uo:Wo})})]})]})})}var wi=vS;var ta=f(Te(),1),ra=f(ue(),1);var Ko=f(Z(),1);function bS({face:e,font:t}){let{isFontActivated:r,toggleActivateFont:o}=(0,ta.useContext)(jt),n=(t?.fontFace?.length??0)>0?r(t.slug,e.fontStyle,e.fontWeight,t.source):r(t.slug,void 0,void 0,t.source),i=()=>{if((t?.fontFace?.length??0)>0){o(t,e);return}o(t)},s=t.name+" "+Js(e),a=(0,ta.useId)();return(0,Ko.jsx)("div",{className:"font-library__font-card",children:(0,Ko.jsxs)(ra.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Ko.jsx)(ra.CheckboxControl,{checked:n,onChange:i,id:a}),(0,Ko.jsx)("label",{htmlFor:a,children:(0,Ko.jsx)(Nn,{font:e,text:s,onClick:i})})]})})}var ey=bS;function ty(e){switch(e){case"normal":return 400;case"bold":return 700;case"bolder":return 500;case"lighter":return 300;default:return parseInt(e,10)}}function oa(e){return e.sort((t,r)=>t.fontStyle==="normal"&&r.fontStyle!=="normal"?-1:r.fontStyle==="normal"&&t.fontStyle!=="normal"?1:t.fontStyle===r.fontStyle?ty(t.fontWeight?.toString()??"normal")-ty(r.fontWeight?.toString()??"normal"):!t.fontStyle||!r.fontStyle?t.fontStyle?-1:1:t.fontStyle.localeCompare(r.fontStyle))}var Ee=f(Z(),1);function ry(e){if(!e)return"";let t={};for(let r of Object.keys(e).sort())t[r]=(e[r]??[]).map(o=>({slug:o.slug,fontFace:(o.fontFace??[]).map(n=>`${n.fontStyle}-${n.fontWeight}`).sort()})).sort((o,n)=>o.slug.localeCompare(n.slug));return JSON.stringify(t)}function wS(){let{baseCustomFonts:e,libraryFontSelected:t,handleSetLibraryFontSelected:r,uninstallFontFamily:o,isResolvingLibrary:n,isInstalling:i,saveFontFamilies:s,getFontFacesActivated:a}=(0,Gr.useContext)(jt),[u,l]=Ke("typography.fontFamilies"),[c,m]=(0,Gr.useState)(void 0),[d,h]=(0,Gr.useState)(!1),[g,b]=(0,Gr.useState)(null),[w]=Ke("typography.fontFamilies",void 0,"base"),_=(0,$c.useSelect)(P=>{let{__experimentalGetCurrentGlobalStylesId:W}=P(xi.store);return W()},[]),x=(0,xi.useEntityRecord)("root","globalStyles",_??0,{enabled:_!==void 0}),v=x?.edits?.settings?.typography?.fontFamilies,C=x?.record?.settings?.typography?.fontFamilies,k=(0,Gr.useMemo)(()=>v===void 0?!1:ry(v)!==ry(C),[v,C]),E=u?.theme?u.theme.map(P=>To(P,{source:"theme"})).sort((P,W)=>P.name.localeCompare(W.name)):[],T=new Set(E.map(P=>P.slug)),O=w?.theme?E.concat(w.theme.filter(P=>!T.has(P.slug)).map(P=>To(P,{source:"theme"})).sort((P,W)=>P.name.localeCompare(W.name))):[],I=t?.source==="custom"&&t?.id,J=(0,$c.useSelect)(P=>{let{canUser:W}=P(xi.store);return I&&W("delete",{kind:"postType",name:"wp_font_family",id:I})},[I]),D=!!t&&t?.source!=="theme"&&J,S=()=>{h(!0)},L=async()=>{b(null);try{await s(u),b({type:"success",message:(0,st.__)("Font family updated successfully.")})}catch(P){b({type:"error",message:(0,st.sprintf)((0,st.__)("There was an error updating the font family. %s"),P.message)})}},Y=P=>P?!P.fontFace||!P.fontFace.length?[{fontFamily:P.fontFamily,fontStyle:"normal",fontWeight:"400"}]:oa(P.fontFace):[],A=P=>{let W=P?.fontFace&&(P?.fontFace?.length??0)>0?P.fontFace.length:1,ne=a(P.slug,P.source).length;return(0,st.sprintf)((0,st.__)("%1$d of %2$d active"),ne,W)};(0,Gr.useEffect)(()=>{r(t)},[]);let N=t?a(t.slug,t.source).length:0,q=t?.fontFace?.length??(t?.fontFamily?1:0),U=N>0&&N!==q,R=N===q,B=()=>{if(!t||!t?.source)return;let P=u?.[t.source]?.filter(ne=>ne.slug!==t.slug)??[],W=R?P:[...P,t];l({...u,[t.source]:W}),t.fontFace&&t.fontFace.forEach(ne=>{if(R)bi(ne,"all");else{let xe=Ln(ne?.src??"");xe&&Po(ne,xe,"all")}})},re=O.length>0||e.length>0;return(0,Ee.jsxs)("div",{className:"font-library__tabpanel-layout",children:[n&&(0,Ee.jsx)("div",{className:"font-library__loading",children:(0,Ee.jsx)(Ie.ProgressBar,{})}),!n&&(0,Ee.jsxs)(Ee.Fragment,{children:[(0,Ee.jsxs)(Ie.Navigator,{initialPath:t?"/fontFamily":"/",children:[(0,Ee.jsx)(Ie.Navigator.Screen,{path:"/",children:(0,Ee.jsxs)(Ie.__experimentalVStack,{spacing:"8",children:[g&&(0,Ee.jsx)(Ie.Notice,{status:g.type,onRemove:()=>b(null),children:g.message}),!re&&(0,Ee.jsx)(Ie.__experimentalText,{as:"p",children:(0,st.__)("No fonts installed.")}),O.length>0&&(0,Ee.jsxs)(Ie.__experimentalVStack,{children:[(0,Ee.jsx)("h2",{className:"font-library__fonts-title",children:(0,st._x)("Theme","font source")}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:O.map(P=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(wi,{font:P,navigatorPath:"/fontFamily",variantsText:A(P),shouldFocus:P.slug===c,onClick:()=>{b(null),r(P)}})},P.slug))})]}),e.length>0&&(0,Ee.jsxs)(Ie.__experimentalVStack,{children:[(0,Ee.jsx)("h2",{className:"font-library__fonts-title",children:(0,st._x)("Custom","font source")}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:e.map(P=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(wi,{font:P,navigatorPath:"/fontFamily",variantsText:A(P),shouldFocus:P.slug===c,onClick:()=>{b(null),r(P)}})},P.slug))})]})]})}),(0,Ee.jsxs)(Ie.Navigator.Screen,{path:"/fontFamily",children:[t&&(0,Ee.jsx)(xS,{font:t,isOpen:d,setIsOpen:h,setNotice:b,uninstallFontFamily:o,handleSetLibraryFontSelected:r}),(0,Ee.jsxs)(Ie.Flex,{justify:"flex-start",children:[(0,Ee.jsx)(Ie.Navigator.BackButton,{icon:(0,st.isRTL)()?Wo:Uo,size:"small",onClick:()=>{m(t?.slug),r(void 0),b(null)},label:(0,st.__)("Back")}),(0,Ee.jsx)(Ie.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:t?.name})]}),g&&(0,Ee.jsxs)(Ee.Fragment,{children:[(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:1}),(0,Ee.jsx)(Ie.Notice,{status:g.type,onRemove:()=>b(null),children:g.message}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:1})]}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Ee.jsx)(Ie.__experimentalText,{children:(0,st.__)("Choose font variants. Keep in mind that too many variants could make your site slower.")}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:4}),(0,Ee.jsxs)(Ie.__experimentalVStack,{spacing:0,children:[(0,Ee.jsx)(Ie.CheckboxControl,{className:"font-library__select-all",label:(0,st.__)("Select all"),checked:R,onChange:B,indeterminate:U}),(0,Ee.jsx)(Ie.__experimentalSpacer,{margin:8}),(0,Ee.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:t&&Y(t).map((P,W)=>(0,Ee.jsx)("li",{className:"font-library__fonts-list-item",children:(0,Ee.jsx)(ey,{font:t,face:P},`face${W}`)},`face${W}`))})]})]})]}),(0,Ee.jsxs)(Ie.__experimentalHStack,{justify:"flex-end",className:"font-library__footer",children:[i&&(0,Ee.jsx)(Ie.ProgressBar,{}),D&&(0,Ee.jsx)(Ie.Button,{__next40pxDefaultSize:!0,isDestructive:!0,variant:"tertiary",onClick:S,children:(0,st.__)("Delete")}),(0,Ee.jsx)(Ie.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:L,disabled:!k,accessibleWhenDisabled:!0,children:(0,st.__)("Update")})]})]})]})}function xS({font:e,isOpen:t,setIsOpen:r,setNotice:o,uninstallFontFamily:n,handleSetLibraryFontSelected:i}){let s=(0,Ie.useNavigator)(),a=async()=>{o(null),r(!1);try{await n(e),s.goBack(),i(void 0),o({type:"success",message:(0,st.__)("Font family uninstalled successfully.")})}catch(l){o({type:"error",message:(0,st.__)("There was an error uninstalling the font family.")+l.message})}},u=()=>{r(!1)};return(0,Ee.jsx)(Ie.__experimentalConfirmDialog,{isOpen:t,cancelButtonText:(0,st.__)("Cancel"),confirmButtonText:(0,st.__)("Delete"),onCancel:u,onConfirm:a,size:"medium",children:e&&(0,st.sprintf)((0,st.__)('Are you sure you want to delete "%s" font and all its variants and assets?'),e.name)})}var na=wS;var yt=f(Te(),1),_e=f(ue(),1),uy=f(yo(),1),rt=f(ge(),1);var fy=f(sr(),1);function oy(e,t){let{category:r,search:o}=t,n=e||[];return r&&r!=="all"&&(n=n.filter(i=>i.categories&&i.categories.indexOf(r)!==-1)),o&&(n=n.filter(i=>i.font_family_settings&&i.font_family_settings.name.toLowerCase().includes(o.toLowerCase()))),n}function ny(e){return e.reduce((t,r)=>({...t,[r.slug]:(r?.fontFace||[]).reduce((o,n)=>({...o,[`${n.fontStyle}-${n.fontWeight}`]:!0}),{})}),{})}function iy(e,t,r){return t?!!r[e]?.[`${t.fontStyle}-${t.fontWeight}`]:!!r[e]}var Si=f(ge(),1),zt=f(ue(),1),hr=f(Z(),1);function SS(){let e=()=>{window.localStorage.setItem("wp-font-library-google-fonts-permission","true"),window.dispatchEvent(new Event("storage"))};return(0,hr.jsx)("div",{className:"font-library__google-fonts-confirm",children:(0,hr.jsx)(zt.Card,{children:(0,hr.jsxs)(zt.CardBody,{children:[(0,hr.jsx)(zt.__experimentalHeading,{level:2,children:(0,Si.__)("Connect to Google Fonts")}),(0,hr.jsx)(zt.__experimentalSpacer,{margin:6}),(0,hr.jsx)(zt.__experimentalText,{as:"p",children:(0,Si.__)("To install fonts from Google you must give permission to connect directly to Google servers. The fonts you install will be downloaded from Google and stored on your site. Your site will then use these locally-hosted fonts.")}),(0,hr.jsx)(zt.__experimentalSpacer,{margin:3}),(0,hr.jsx)(zt.__experimentalText,{as:"p",children:(0,Si.__)("You can alternatively upload files directly on the Upload tab.")}),(0,hr.jsx)(zt.__experimentalSpacer,{margin:6}),(0,hr.jsx)(zt.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:e,children:(0,Si.__)("Allow access to Google Fonts")})]})})})}var sy=SS;var ay=f(Te(),1),ia=f(ue(),1);var Jo=f(Z(),1);function _S({face:e,font:t,handleToggleVariant:r,selected:o}){let n=()=>{if(t?.fontFace){r(t,e);return}r(t)},i=t.name+" "+Js(e),s=(0,ay.useId)();return(0,Jo.jsx)("div",{className:"font-library__font-card",children:(0,Jo.jsxs)(ia.Flex,{justify:"flex-start",align:"center",gap:"1rem",children:[(0,Jo.jsx)(ia.CheckboxControl,{checked:o,onChange:n,id:s}),(0,Jo.jsx)("label",{htmlFor:s,children:(0,Jo.jsx)(Nn,{font:e,text:i,onClick:n})})]})})}var ly=_S;var de=f(Z(),1),CS={slug:"all",name:(0,rt._x)("All","font categories")},cy="wp-font-library-google-fonts-permission",RS=500;function ES({slug:e}){let t=e==="google-fonts",r=()=>window.localStorage.getItem(cy)==="true",[o,n]=(0,yt.useState)(null),[i,s]=(0,yt.useState)(void 0),[a,u]=(0,yt.useState)(null),[l,c]=(0,yt.useState)([]),[m,d]=(0,yt.useState)(1),[h,g]=(0,yt.useState)({}),[b,w]=(0,yt.useState)(t&&!r()),{installFonts:_,isInstalling:x}=(0,yt.useContext)(jt),{record:v,isResolving:C}=(0,fy.useEntityRecord)("root","fontCollection",e);(0,yt.useEffect)(()=>{let $=()=>{w(t&&!r())};return $(),window.addEventListener("storage",$),()=>window.removeEventListener("storage",$)},[e,t]);let k=()=>{window.localStorage.setItem(cy,"false"),window.dispatchEvent(new Event("storage"))};(0,yt.useEffect)(()=>{n(null)},[e]),(0,yt.useEffect)(()=>{c([])},[o]);let E=(0,yt.useMemo)(()=>v?.font_families??[],[v]),T=v?.categories??[],O=[CS,...T],I=(0,yt.useMemo)(()=>oy(E,h),[E,h]),J=Math.max(window.innerHeight,RS),D=Math.floor((J-417)/61),S=Math.ceil(I.length/D),L=(m-1)*D,Y=m*D,A=I.slice(L,Y),N=$=>{g({...h,category:$}),d(1)},U=(0,uy.debounce)($=>{g({...h,search:$}),d(1)},300),R=($,Ce)=>{let Fe=Qs($,Ce,l);c(Fe)},B=ny(l),re=()=>{c([])},P=l.length>0?l[0]?.fontFace?.length??0:0,W=P>0&&P!==o?.fontFace?.length,ne=P===o?.fontFace?.length,xe=()=>{let $=[];!ne&&o&&$.push(o),c($)},se=async()=>{u(null);let $=l[0];try{$?.fontFace&&await Promise.all($.fontFace.map(async Ce=>{Ce.src&&(Ce.file=await Kg(Ce.src))}))}catch{u({type:"error",message:(0,rt.__)("Error installing the fonts, could not be downloaded.")});return}try{await _([$]),u({type:"success",message:(0,rt.__)("Fonts were installed successfully.")})}catch(Ce){u({type:"error",message:Ce.message})}re()},be=$=>$?!$.fontFace||!$.fontFace.length?[{fontFamily:$.fontFamily,fontStyle:"normal",fontWeight:"400"}]:oa($.fontFace):[];if(b)return(0,de.jsx)(sy,{});let ye=e==="google-fonts"&&!b&&!o;return(0,de.jsxs)("div",{className:"font-library__tabpanel-layout",children:[C&&(0,de.jsx)("div",{className:"font-library__loading",children:(0,de.jsx)(_e.ProgressBar,{})}),!C&&v&&(0,de.jsxs)(de.Fragment,{children:[(0,de.jsxs)(_e.Navigator,{initialPath:"/",className:"font-library__tabpanel-layout",children:[(0,de.jsxs)(_e.Navigator.Screen,{path:"/",children:[(0,de.jsxs)(_e.__experimentalHStack,{justify:"space-between",children:[(0,de.jsxs)(_e.__experimentalVStack,{children:[(0,de.jsx)(_e.__experimentalHeading,{level:2,size:13,children:v.name}),(0,de.jsx)(_e.__experimentalText,{children:v.description})]}),ye&&(0,de.jsx)(_e.DropdownMenu,{icon:Jl,label:(0,rt.__)("Actions"),popoverProps:{position:"bottom left"},controls:[{title:(0,rt.__)("Revoke access to Google Fonts"),onClick:k}]})]}),(0,de.jsx)(_e.__experimentalSpacer,{margin:4}),(0,de.jsxs)(_e.__experimentalHStack,{spacing:4,justify:"space-between",children:[(0,de.jsx)(_e.SearchControl,{className:"font-library__search",value:h.search,placeholder:(0,rt.__)("Font name\u2026"),label:(0,rt.__)("Search"),onChange:U,hideLabelFromVision:!1}),(0,de.jsx)(_e.SelectControl,{label:(0,rt.__)("Category"),value:h.category,onChange:N,children:O&&O.map($=>(0,de.jsx)("option",{value:$.slug,children:$.name},$.slug))})]}),(0,de.jsx)(_e.__experimentalSpacer,{margin:4}),!!v?.font_families?.length&&!I.length&&(0,de.jsx)(_e.__experimentalText,{children:(0,rt.__)("No fonts found. Try with a different search term.")}),(0,de.jsx)("div",{className:"font-library__fonts-grid__main",children:(0,de.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:A.map($=>(0,de.jsx)("li",{className:"font-library__fonts-list-item",children:(0,de.jsx)(wi,{font:$.font_family_settings,navigatorPath:"/fontFamily",shouldFocus:$.font_family_settings.slug===i,onClick:()=>{n($.font_family_settings)}})},$.font_family_settings.slug))})})]}),(0,de.jsxs)(_e.Navigator.Screen,{path:"/fontFamily",children:[(0,de.jsxs)(_e.Flex,{justify:"flex-start",children:[(0,de.jsx)(_e.Navigator.BackButton,{icon:(0,rt.isRTL)()?Wo:Uo,size:"small",onClick:()=>{s(o?.slug),n(null),u(null)},label:(0,rt.__)("Back")}),(0,de.jsx)(_e.__experimentalHeading,{level:2,size:13,className:"global-styles-ui-header",children:o?.name})]}),a&&(0,de.jsxs)(de.Fragment,{children:[(0,de.jsx)(_e.__experimentalSpacer,{margin:1}),(0,de.jsx)(_e.Notice,{status:a.type,onRemove:()=>u(null),children:a.message}),(0,de.jsx)(_e.__experimentalSpacer,{margin:1})]}),(0,de.jsx)(_e.__experimentalSpacer,{margin:4}),(0,de.jsx)(_e.__experimentalText,{children:(0,rt.__)("Select font variants to install.")}),(0,de.jsx)(_e.__experimentalSpacer,{margin:4}),(0,de.jsx)(_e.CheckboxControl,{className:"font-library__select-all",label:(0,rt.__)("Select all"),checked:ne,onChange:xe,indeterminate:W}),(0,de.jsx)(_e.__experimentalVStack,{spacing:0,children:(0,de.jsx)("ul",{role:"list",className:"font-library__fonts-list",children:o&&be(o).map(($,Ce)=>(0,de.jsx)("li",{className:"font-library__fonts-list-item",children:(0,de.jsx)(ly,{font:o,face:$,handleToggleVariant:R,selected:iy(o.slug,o.fontFace?$:null,B)})},`face${Ce}`))})}),(0,de.jsx)(_e.__experimentalSpacer,{margin:16})]})]}),o&&(0,de.jsx)(_e.Flex,{justify:"flex-end",className:"font-library__footer",children:(0,de.jsx)(_e.Button,{__next40pxDefaultSize:!0,variant:"primary",onClick:se,isBusy:x,disabled:l.length===0||x,accessibleWhenDisabled:!0,children:(0,rt.__)("Install")})}),!o&&(0,de.jsxs)(_e.__experimentalHStack,{expanded:!1,className:"font-library__footer",justify:"end",spacing:6,children:[(0,de.jsx)(_e.__experimentalHStack,{justify:"flex-start",expanded:!1,spacing:1,className:"font-library__page-selection",children:(0,yt.createInterpolateElement)((0,rt.sprintf)((0,rt._x)("
    Page
    %1$s
    of %2$d
    ","paging"),"",S),{div:(0,de.jsx)("div",{"aria-hidden":!0}),CurrentPage:(0,de.jsx)(_e.SelectControl,{"aria-label":(0,rt.__)("Current page"),value:m.toString(),options:[...Array(S)].map(($,Ce)=>({label:(Ce+1).toString(),value:(Ce+1).toString()})),onChange:$=>d(parseInt($)),size:"small",variant:"minimal"})})}),(0,de.jsxs)(_e.__experimentalHStack,{expanded:!1,spacing:1,children:[(0,de.jsx)(_e.Button,{onClick:()=>d(m-1),disabled:m===1,accessibleWhenDisabled:!0,label:(0,rt.__)("Previous page"),icon:(0,rt.isRTL)()?Is:Ns,showTooltip:!0,size:"compact",tooltipPosition:"top"}),(0,de.jsx)(_e.Button,{onClick:()=>d(m+1),disabled:m===S,accessibleWhenDisabled:!0,label:(0,rt.__)("Next page"),icon:(0,rt.isRTL)()?Ns:Is,showTooltip:!0,size:"compact",tooltipPosition:"top"})]})]})]})]})}var sa=ES;var Vn=f(ge(),1),Ot=f(ue(),1),Ci=f(Te(),1);var aa=(e=>typeof Wt<"u"?Wt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof Wt<"u"?Wt:t)[r]}):e)(function(e){if(typeof Wt<"u")return Wt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),dy=(function(){var e,t,r;return(function(){function o(n,i,s){function a(c,m){if(!i[c]){if(!n[c]){var d=typeof aa=="function"&&aa;if(!m&&d)return d(c,!0);if(u)return u(c,!0);var h=new Error("Cannot find module '"+c+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[c]={exports:{}};n[c][0].call(g.exports,function(b){var w=n[c][1][b];return a(w||b)},g,g.exports,o,n,i,s)}return i[c].exports}for(var u=typeof aa=="function"&&aa,l=0;l0},c.prototype.readMoreInput=function(){if(!(this.bit_end_pos_>256))if(this.eos_){if(this.bit_pos_>this.bit_end_pos_)throw new Error("Unexpected end of input "+this.bit_pos_+" "+this.bit_end_pos_)}else{var m=this.buf_ptr_,d=this.input_.read(this.buf_,m,s);if(d<0)throw new Error("Unexpected end of input");if(d=8;)this.val_>>>=8,this.val_|=this.buf_[this.pos_&u]<<24,++this.pos_,this.bit_pos_=this.bit_pos_-8>>>0,this.bit_end_pos_=this.bit_end_pos_-8>>>0},c.prototype.readBits=function(m){32-this.bit_pos_>>this.bit_pos_&l[m];return this.bit_pos_+=m,d},n.exports=c},{}],2:[function(o,n,i){var s=0,a=1,u=2,l=3;i.lookup=new Uint8Array([0,0,0,0,0,0,0,0,0,4,4,0,0,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,8,12,16,12,12,20,12,16,24,28,12,12,32,12,36,12,44,44,44,44,44,44,44,44,44,44,32,32,24,40,28,12,12,48,52,52,52,48,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,48,52,52,52,52,52,24,12,28,12,12,12,56,60,60,60,56,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,56,60,60,60,60,60,24,12,28,12,0,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,2,3,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,1,1,1,1,1,1,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,1,1,1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,2,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,0,8,8,8,8,8,8,8,8,8,8,8,8,8,8,8,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,16,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,32,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,40,48,48,48,48,48,48,48,48,48,48,48,48,48,48,48,56,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,6,6,6,6,7,7,7,7,8,8,8,8,9,9,9,9,10,10,10,10,11,11,11,11,12,12,12,12,13,13,13,13,14,14,14,14,15,15,15,15,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,22,22,22,22,23,23,23,23,24,24,24,24,25,25,25,25,26,26,26,26,27,27,27,27,28,28,28,28,29,29,29,29,30,30,30,30,31,31,31,31,32,32,32,32,33,33,33,33,34,34,34,34,35,35,35,35,36,36,36,36,37,37,37,37,38,38,38,38,39,39,39,39,40,40,40,40,41,41,41,41,42,42,42,42,43,43,43,43,44,44,44,44,45,45,45,45,46,46,46,46,47,47,47,47,48,48,48,48,49,49,49,49,50,50,50,50,51,51,51,51,52,52,52,52,53,53,53,53,54,54,54,54,55,55,55,55,56,56,56,56,57,57,57,57,58,58,58,58,59,59,59,59,60,60,60,60,61,61,61,61,62,62,62,62,63,63,63,63,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),i.lookupOffsets=new Uint16Array([1024,1536,1280,1536,0,256,768,512])},{}],3:[function(o,n,i){var s=o("./streams").BrotliInput,a=o("./streams").BrotliOutput,u=o("./bit_reader"),l=o("./dictionary"),c=o("./huffman").HuffmanCode,m=o("./huffman").BrotliBuildHuffmanTable,d=o("./context"),h=o("./prefix"),g=o("./transform"),b=8,w=16,_=256,x=704,v=26,C=6,k=2,E=8,T=255,O=1080,I=18,J=new Uint8Array([1,2,3,4,0,5,17,6,16,7,8,9,10,11,12,13,14,15]),D=16,S=new Uint8Array([3,2,1,0,3,3,3,3,3,3,2,2,2,2,2,2]),L=new Int8Array([0,0,0,0,-1,1,-2,2,-3,3,-1,1,-2,2,-3,3]),Y=new Uint16Array([256,402,436,468,500,534,566,598,630,662,694,726,758,790,822,854,886,920,952,984,1016,1048,1080]);function A(X){var M;return X.readBits(1)===0?16:(M=X.readBits(3),M>0?17+M:(M=X.readBits(3),M>0?8+M:17))}function N(X){if(X.readBits(1)){var M=X.readBits(3);return M===0?1:X.readBits(M)+(1<1&&pe===0)throw new Error("Invalid size byte");M.meta_block_length|=pe<4&&le===0)throw new Error("Invalid size nibble");M.meta_block_length|=le<>>K.bit_pos_&T,Q=X[M].bits-E,Q>0&&(K.bit_pos_+=E,M+=X[M].value,M+=K.val_>>>K.bit_pos_&(1<0;){var te=0,Ne;if(H.readMoreInput(),H.fillBitWindow(),te+=H.val_>>>H.bit_pos_&31,H.bit_pos_+=he[te].bits,Ne=he[te].value&255,Ne>Ne);else{var He=Ne-14,ot,Ze,Be=0;if(Ne===w&&(Be=pe),fe!==Be&&(le=0,fe=Be),ot=le,le>0&&(le-=2,le<<=He),le+=H.readBits(He)+3,Ze=le-ot,Q+Ze>M)throw new Error("[ReadHuffmanCodeLengths] symbol + repeat_delta > num_symbols");for(var Ue=0;Ue0;++fe){var Be=J[fe],Ue=0,ct;H.fillBitWindow(),Ue+=H.val_>>>H.bit_pos_&15,H.bit_pos_+=Ze[Ue].bits,ct=Ze[Ue].value,Ne[Be]=ct,ct!==0&&(He-=32>>ct,++ot)}if(!(ot===1||He===0))throw new Error("[ReadHuffmanCode] invalid num_codes or space");B(Ne,X,le,H)}if(Q=m(M,K,E,le,X),Q===0)throw new Error("[ReadHuffmanCode] BuildHuffmanTable failed: ");return Q}function P(X,M,K){var H,Q;return H=R(X,M,K),Q=h.kBlockLengthPrefixCode[H].nbits,h.kBlockLengthPrefixCode[H].offset+K.readBits(Q)}function W(X,M,K){var H;return X>>5]),this.htrees=new Uint32Array(M)}se.prototype.decode=function(X){var M,K,H=0;for(M=0;M=X)throw new Error("[DecodeContextMap] i >= context_map_size");me[le]=0,++le}else me[le]=he-Q,++le}return M.readBits(1)&&xe(me,X),K}function ye(X,M,K,H,Q,pe,le){var fe=K*2,me=K,he=R(M,K*O,le),V;he===0?V=Q[fe+(pe[me]&1)]:he===1?V=Q[fe+(pe[me]-1&1)]+1:V=he-2,V>=X&&(V-=X),H[K]=V,Q[fe+(pe[me]&1)]=V,++pe[me]}function $(X,M,K,H,Q,pe){var le=Q+1,fe=K&Q,me=pe.pos_&u.IBUF_MASK,he;if(M<8||pe.bit_pos_+(M<<3)0;)pe.readMoreInput(),H[fe++]=pe.readBits(8),fe===le&&(X.write(H,le),fe=0);return}if(pe.bit_end_pos_<32)throw new Error("[CopyUncompressedBlockToOutput] br.bit_end_pos_ < 32");for(;pe.bit_pos_<32;)H[fe]=pe.val_>>>pe.bit_pos_,pe.bit_pos_+=8,++fe,--M;if(he=pe.bit_end_pos_-pe.bit_pos_>>3,me+he>u.IBUF_MASK){for(var V=u.IBUF_MASK+1-me,te=0;te=le){X.write(H,le),fe-=le;for(var te=0;te=le;){if(he=le-fe,pe.input_.read(H,fe,he)M.buffer.length){var Fo=new Uint8Array(H+Ye);Fo.set(M.buffer),M.buffer=Fo}if(Q=br.input_end,Yr=br.is_uncompressed,br.is_metadata){for(Ce(Se);Ye>0;--Ye)Se.readMoreInput(),Se.readBits(8);continue}if(Ye!==0){if(Yr){Se.bit_pos_=Se.bit_pos_+7&-8,$(M,Ye,H,V,he,Se),H+=Ye;continue}for(K=0;K<3;++K)vt[K]=N(Se)+1,vt[K]>=2&&(re(vt[K]+2,Ue,K*O,Se),re(v,ct,K*O,Se),St[K]=P(ct,K*O,Se),G[K]=1);for(Se.readMoreInput(),y=Se.readBits(2),oe=D+(Se.readBits(4)<0;){var ft,At,Ht,en,Ea,Ut,er,qr,Hn,tn,Un;for(Se.readMoreInput(),St[1]===0&&(ye(vt[1],Ue,1,kt,F,G,Se),St[1]=P(ct,O,Se),pt=Be[1].htrees[kt[1]]),--St[1],ft=R(Be[1].codes,pt,Se),At=ft>>6,At>=2?(At-=2,er=-1):er=0,Ht=h.kInsertRangeLut[At]+(ft>>3&7),en=h.kCopyRangeLut[At]+(ft&7),Ea=h.kInsertLengthPrefixCode[Ht].offset+Se.readBits(h.kInsertLengthPrefixCode[Ht].nbits),Ut=h.kCopyLengthPrefixCode[en].offset+Se.readBits(h.kCopyLengthPrefixCode[en].nbits),ot=V[H-1&he],Ze=V[H-2&he],tn=0;tn4?3:Ut-2)&255,et=j[kr+Hn],er=R(Be[2].codes,Be[2].htrees[et],Se),er>=oe){var Ta,Au,Wn;er-=oe,Au=er&Ae,er>>=y,Ta=(er>>1)+1,Wn=(2+(er&1)<fe)if(Ut>=l.minDictionaryWordLength&&Ut<=l.maxDictionaryWordLength){var Wn=l.offsetsByLength[Ut],Iu=qr-fe-1,Lu=l.sizeBitsByLength[Ut],Mv=(1<>Lu;if(Wn+=Vv*Ut,Nu=te){M.write(V,me);for(var Fi=0;Fi0&&(Ne[He&3]=qr,++He),Ut>Ye)throw new Error("Invalid backward reference. pos: "+H+" distance: "+qr+" len: "+Ut+" bytes left: "+Ye);for(tn=0;tn>=1;return(m&h-1)+h}function l(m,d,h,g,b){do g-=h,m[d+g]=new s(b.bits,b.value);while(g>0)}function c(m,d,h){for(var g=1<0;--S[x])_=new s(x&255,D[v++]&65535),l(m,d+C,k,I,_),C=u(C,x);for(T=J-1,E=-1,x=h+1,k=2;x<=a;++x,k<<=1)for(;S[x]>0;--S[x])(C&T)!==E&&(d+=I,O=c(S,x,h),I=1<>h),k,I,_),C=u(C,x);return J}},{}],8:[function(o,n,i){"use strict";i.byteLength=h,i.toByteArray=b,i.fromByteArray=x;for(var s=[],a=[],u=typeof Uint8Array<"u"?Uint8Array:Array,l="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=0,m=l.length;c0)throw new Error("Invalid string. Length must be a multiple of 4");var k=v.indexOf("=");k===-1&&(k=C);var E=k===C?0:4-k%4;return[k,E]}function h(v){var C=d(v),k=C[0],E=C[1];return(k+E)*3/4-E}function g(v,C,k){return(C+k)*3/4-k}function b(v){for(var C,k=d(v),E=k[0],T=k[1],O=new u(g(v,E,T)),I=0,J=T>0?E-4:E,D=0;D>16&255,O[I++]=C>>8&255,O[I++]=C&255;return T===2&&(C=a[v.charCodeAt(D)]<<2|a[v.charCodeAt(D+1)]>>4,O[I++]=C&255),T===1&&(C=a[v.charCodeAt(D)]<<10|a[v.charCodeAt(D+1)]<<4|a[v.charCodeAt(D+2)]>>2,O[I++]=C>>8&255,O[I++]=C&255),O}function w(v){return s[v>>18&63]+s[v>>12&63]+s[v>>6&63]+s[v&63]}function _(v,C,k){for(var E,T=[],O=C;OJ?J:I+O));return E===1?(C=v[k-1],T.push(s[C>>2]+s[C<<4&63]+"==")):E===2&&(C=(v[k-2]<<8)+v[k-1],T.push(s[C>>10]+s[C>>4&63]+s[C<<2&63]+"=")),T.join("")}},{}],9:[function(o,n,i){function s(a,u){this.offset=a,this.nbits=u}i.kBlockLengthPrefixCode=[new s(1,2),new s(5,2),new s(9,2),new s(13,2),new s(17,3),new s(25,3),new s(33,3),new s(41,3),new s(49,4),new s(65,4),new s(81,4),new s(97,4),new s(113,5),new s(145,5),new s(177,5),new s(209,5),new s(241,6),new s(305,6),new s(369,7),new s(497,8),new s(753,9),new s(1265,10),new s(2289,11),new s(4337,12),new s(8433,13),new s(16625,24)],i.kInsertLengthPrefixCode=[new s(0,0),new s(1,0),new s(2,0),new s(3,0),new s(4,0),new s(5,0),new s(6,1),new s(8,1),new s(10,2),new s(14,2),new s(18,3),new s(26,3),new s(34,4),new s(50,4),new s(66,5),new s(98,5),new s(130,6),new s(194,7),new s(322,8),new s(578,9),new s(1090,10),new s(2114,12),new s(6210,14),new s(22594,24)],i.kCopyLengthPrefixCode=[new s(2,0),new s(3,0),new s(4,0),new s(5,0),new s(6,0),new s(7,0),new s(8,0),new s(9,0),new s(10,1),new s(12,1),new s(14,2),new s(18,2),new s(22,3),new s(30,3),new s(38,4),new s(54,4),new s(70,5),new s(102,5),new s(134,6),new s(198,7),new s(326,8),new s(582,9),new s(1094,10),new s(2118,24)],i.kInsertRangeLut=[0,0,8,8,0,16,8,16,16],i.kCopyRangeLut=[0,8,0,8,16,0,16,8,16]},{}],10:[function(o,n,i){function s(u){this.buffer=u,this.pos=0}s.prototype.read=function(u,l,c){this.pos+c>this.buffer.length&&(c=this.buffer.length-this.pos);for(var m=0;mthis.buffer.length)throw new Error("Output buffer is not large enough");return this.buffer.set(u.subarray(0,l),this.pos),this.pos+=l,l},i.BrotliOutput=a},{}],11:[function(o,n,i){var s=o("./dictionary"),a=0,u=1,l=2,c=3,m=4,d=5,h=6,g=7,b=8,w=9,_=10,x=11,v=12,C=13,k=14,E=15,T=16,O=17,I=18,J=19,D=20;function S(A,N,q){this.prefix=new Uint8Array(A.length),this.transform=N,this.suffix=new Uint8Array(q.length);for(var U=0;U'),new S("",a,` +`),new S("",c,""),new S("",a,"]"),new S("",a," for "),new S("",k,""),new S("",l,""),new S("",a," a "),new S("",a," that "),new S(" ",_,""),new S("",a,". "),new S(".",a,""),new S(" ",a,", "),new S("",E,""),new S("",a," with "),new S("",a,"'"),new S("",a," from "),new S("",a," by "),new S("",T,""),new S("",O,""),new S(" the ",a,""),new S("",m,""),new S("",a,". The "),new S("",x,""),new S("",a," on "),new S("",a," as "),new S("",a," is "),new S("",g,""),new S("",u,"ing "),new S("",a,` + `),new S("",a,":"),new S(" ",a,". "),new S("",a,"ed "),new S("",D,""),new S("",I,""),new S("",h,""),new S("",a,"("),new S("",_,", "),new S("",b,""),new S("",a," at "),new S("",a,"ly "),new S(" the ",a," of "),new S("",d,""),new S("",w,""),new S(" ",_,", "),new S("",_,'"'),new S(".",a,"("),new S("",x," "),new S("",_,'">'),new S("",a,'="'),new S(" ",a,"."),new S(".com/",a,""),new S(" the ",a," of the "),new S("",_,"'"),new S("",a,". This "),new S("",a,","),new S(".",a," "),new S("",_,"("),new S("",_,"."),new S("",a," not "),new S(" ",a,'="'),new S("",a,"er "),new S(" ",x," "),new S("",a,"al "),new S(" ",x,""),new S("",a,"='"),new S("",x,'"'),new S("",_,". "),new S(" ",a,"("),new S("",a,"ful "),new S(" ",_,". "),new S("",a,"ive "),new S("",a,"less "),new S("",x,"'"),new S("",a,"est "),new S(" ",_,"."),new S("",x,'">'),new S(" ",a,"='"),new S("",_,","),new S("",a,"ize "),new S("",x,"."),new S("\xC2\xA0",a,""),new S(" ",a,","),new S("",_,'="'),new S("",x,'="'),new S("",a,"ous "),new S("",x,", "),new S("",_,"='"),new S(" ",_,","),new S(" ",x,'="'),new S(" ",x,", "),new S("",x,","),new S("",x,"("),new S("",x,". "),new S(" ",x,"."),new S("",x,"='"),new S(" ",x,". "),new S(" ",_,'="'),new S(" ",x,"='"),new S(" ",_,"='")];i.kTransforms=L,i.kNumTransforms=L.length;function Y(A,N){return A[N]<192?(A[N]>=97&&A[N]<=122&&(A[N]^=32),1):A[N]<224?(A[N+1]^=32,2):(A[N+2]^=5,3)}i.transformDictionaryWord=function(A,N,q,U,R){var B=L[R].prefix,re=L[R].suffix,P=L[R].transform,W=PU&&(W=U);for(var be=0;be0;){var ye=Y(A,se);se+=ye,U-=ye}for(var $=0;$typeof Wt<"u"?Wt:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof Wt<"u"?Wt:t)[r]}):e)(function(e){if(typeof Wt<"u")return Wt.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),py=(function(){var e,t,r;return(function(){function o(n,i,s){function a(c,m){if(!i[c]){if(!n[c]){var d=typeof la=="function"&&la;if(!m&&d)return d(c,!0);if(u)return u(c,!0);var h=new Error("Cannot find module '"+c+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[c]={exports:{}};n[c][0].call(g.exports,function(b){var w=n[c][1][b];return a(w||b)},g,g.exports,o,n,i,s)}return i[c].exports}for(var u=typeof la=="function"&&la,l=0;l=252?6:c>=248?5:c>=240?4:c>=224?3:c>=192?2:1;l[254]=l[254]=1,i.string2buf=function(d){var h,g,b,w,_,x=d.length,v=0;for(w=0;w>>6,h[_++]=128|g&63):g<65536?(h[_++]=224|g>>>12,h[_++]=128|g>>>6&63,h[_++]=128|g&63):(h[_++]=240|g>>>18,h[_++]=128|g>>>12&63,h[_++]=128|g>>>6&63,h[_++]=128|g&63);return h};function m(d,h){if(h<65534&&(d.subarray&&u||!d.subarray&&a))return String.fromCharCode.apply(null,s.shrinkBuf(d,h));for(var g="",b=0;b4){v[b++]=65533,g+=_-1;continue}for(w&=_===2?31:_===3?15:7;_>1&&g1){v[b++]=65533;continue}w<65536?v[b++]=w:(w-=65536,v[b++]=55296|w>>10&1023,v[b++]=56320|w&1023)}return m(v,b)},i.utf8border=function(d,h){var g;for(h=h||d.length,h>d.length&&(h=d.length),g=h-1;g>=0&&(d[g]&192)===128;)g--;return g<0||g===0?h:g+l[d[g]]>h?g:h}},{"./common":1}],3:[function(o,n,i){"use strict";function s(a,u,l,c){for(var m=a&65535|0,d=a>>>16&65535|0,h=0;l!==0;){h=l>2e3?2e3:l,l-=h;do m=m+u[c++]|0,d=d+m|0;while(--h);m%=65521,d%=65521}return m|d<<16|0}n.exports=s},{}],4:[function(o,n,i){"use strict";n.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],5:[function(o,n,i){"use strict";function s(){for(var l,c=[],m=0;m<256;m++){l=m;for(var d=0;d<8;d++)l=l&1?3988292384^l>>>1:l>>>1;c[m]=l}return c}var a=s();function u(l,c,m,d){var h=a,g=d+m;l^=-1;for(var b=d;b>>8^h[(l^c[b])&255];return l^-1}n.exports=u},{}],6:[function(o,n,i){"use strict";function s(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}n.exports=s},{}],7:[function(o,n,i){"use strict";var s=30,a=12;n.exports=function(l,c){var m,d,h,g,b,w,_,x,v,C,k,E,T,O,I,J,D,S,L,Y,A,N,q,U,R;m=l.state,d=l.next_in,U=l.input,h=d+(l.avail_in-5),g=l.next_out,R=l.output,b=g-(c-l.avail_out),w=g+(l.avail_out-257),_=m.dmax,x=m.wsize,v=m.whave,C=m.wnext,k=m.window,E=m.hold,T=m.bits,O=m.lencode,I=m.distcode,J=(1<>>24,E>>>=L,T-=L,L=S>>>16&255,L===0)R[g++]=S&65535;else if(L&16){Y=S&65535,L&=15,L&&(T>>=L,T-=L),T<15&&(E+=U[d++]<>>24,E>>>=L,T-=L,L=S>>>16&255,L&16){if(A=S&65535,L&=15,T_){l.msg="invalid distance too far back",m.mode=s;break e}if(E>>>=L,T-=L,L=g-b,A>L){if(L=A-L,L>v&&m.sane){l.msg="invalid distance too far back",m.mode=s;break e}if(N=0,q=k,C===0){if(N+=x-L,L2;)R[g++]=q[N++],R[g++]=q[N++],R[g++]=q[N++],Y-=3;Y&&(R[g++]=q[N++],Y>1&&(R[g++]=q[N++]))}else{N=g-A;do R[g++]=R[N++],R[g++]=R[N++],R[g++]=R[N++],Y-=3;while(Y>2);Y&&(R[g++]=R[N++],Y>1&&(R[g++]=R[N++]))}}else if((L&64)===0){S=I[(S&65535)+(E&(1<>3,d-=Y,T-=Y<<3,E&=(1<>>24&255)+(F>>>8&65280)+((F&65280)<<8)+((F&255)<<24)}function Ne(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new s.Buf16(320),this.work=new s.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function He(F){var G;return!F||!F.state?C:(G=F.state,F.total_in=F.total_out=G.total=0,F.msg="",G.wrap&&(F.adler=G.wrap&1),G.mode=I,G.last=0,G.havedict=0,G.dmax=32768,G.head=null,G.hold=0,G.bits=0,G.lencode=G.lendyn=new s.Buf32(fe),G.distcode=G.distdyn=new s.Buf32(me),G.sane=1,G.back=-1,_)}function ot(F){var G;return!F||!F.state?C:(G=F.state,G.wsize=0,G.whave=0,G.wnext=0,He(F))}function Ze(F,G){var y,oe;return!F||!F.state||(oe=F.state,G<0?(y=0,G=-G):(y=(G>>4)+1,G<48&&(G&=15)),G&&(G<8||G>15))?C:(oe.window!==null&&oe.wbits!==G&&(oe.window=null),oe.wrap=y,oe.wbits=G,ot(F))}function Be(F,G){var y,oe;return F?(oe=new Ne,F.state=oe,oe.window=null,y=Ze(F,G),y!==_&&(F.state=null),y):C}function Ue(F){return Be(F,V)}var ct=!0,Se,Or;function $t(F){if(ct){var G;for(Se=new s.Buf32(512),Or=new s.Buf32(32),G=0;G<144;)F.lens[G++]=8;for(;G<256;)F.lens[G++]=9;for(;G<280;)F.lens[G++]=7;for(;G<288;)F.lens[G++]=8;for(c(d,F.lens,0,288,Se,0,F.work,{bits:9}),G=0;G<32;)F.lens[G++]=5;c(h,F.lens,0,32,Or,0,F.work,{bits:5}),ct=!1}F.lencode=Se,F.lenbits=9,F.distcode=Or,F.distbits=5}function Ye(F,G,y,oe){var Ae,ee=F.state;return ee.window===null&&(ee.wsize=1<=ee.wsize?(s.arraySet(ee.window,G,y-ee.wsize,ee.wsize,0),ee.wnext=0,ee.whave=ee.wsize):(Ae=ee.wsize-ee.wnext,Ae>oe&&(Ae=oe),s.arraySet(ee.window,G,y-oe,Ae,ee.wnext),oe-=Ae,oe?(s.arraySet(ee.window,G,y-oe,oe,0),ee.wnext=oe,ee.whave=ee.wsize):(ee.wnext+=Ae,ee.wnext===ee.wsize&&(ee.wnext=0),ee.whave>>8&255,y.check=u(y.check,ft,2,0),j=0,z=0,y.mode=J;break}if(y.flags=0,y.head&&(y.head.done=!1),!(y.wrap&1)||(((j&255)<<8)+(j>>8))%31){F.msg="incorrect header check",y.mode=Q;break}if((j&15)!==O){F.msg="unknown compression method",y.mode=Q;break}if(j>>>=4,z-=4,at=(j&15)+8,y.wbits===0)y.wbits=at;else if(at>y.wbits){F.msg="invalid window size",y.mode=Q;break}y.dmax=1<>8&1),y.flags&512&&(ft[0]=j&255,ft[1]=j>>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0,y.mode=D;case D:for(;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>8&255,ft[2]=j>>>16&255,ft[3]=j>>>24&255,y.check=u(y.check,ft,4,0)),j=0,z=0,y.mode=S;case S:for(;z<16;){if(ie===0)break e;ie--,j+=oe[ee++]<>8),y.flags&512&&(ft[0]=j&255,ft[1]=j>>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0,y.mode=L;case L:if(y.flags&1024){for(;z<16;){if(ie===0)break e;ie--,j+=oe[ee++]<>>8&255,y.check=u(y.check,ft,2,0)),j=0,z=0}else y.head&&(y.head.extra=null);y.mode=Y;case Y:if(y.flags&1024&&(ce=y.length,ce>ie&&(ce=ie),ce&&(y.head&&(at=y.head.extra_len-y.length,y.head.extra||(y.head.extra=new Array(y.head.extra_len)),s.arraySet(y.head.extra,oe,ee,ce,at)),y.flags&512&&(y.check=u(y.check,oe,ce,ee)),ie-=ce,ee+=ce,y.length-=ce),y.length))break e;y.length=0,y.mode=A;case A:if(y.flags&2048){if(ie===0)break e;ce=0;do at=oe[ee+ce++],y.head&&at&&y.length<65536&&(y.head.name+=String.fromCharCode(at));while(at&&ce>9&1,y.head.done=!0),F.adler=y.check=0,y.mode=B;break;case U:for(;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=z&7,z-=z&7,y.mode=M;break}for(;z<3;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=1,z-=1,j&3){case 0:y.mode=P;break;case 1:if($t(y),y.mode=ye,G===w){j>>>=2,z-=2;break e}break;case 2:y.mode=xe;break;case 3:F.msg="invalid block type",y.mode=Q}j>>>=2,z-=2;break;case P:for(j>>>=z&7,z-=z&7;z<32;){if(ie===0)break e;ie--,j+=oe[ee++]<>>16^65535)){F.msg="invalid stored block lengths",y.mode=Q;break}if(y.length=j&65535,j=0,z=0,y.mode=W,G===w)break e;case W:y.mode=ne;case ne:if(ce=y.length,ce){if(ce>ie&&(ce=ie),ce>Je&&(ce=Je),ce===0)break e;s.arraySet(Ae,oe,ee,ce,Qe),ie-=ce,ee+=ce,Je-=ce,Qe+=ce,y.length-=ce;break}y.mode=B;break;case xe:for(;z<14;){if(ie===0)break e;ie--,j+=oe[ee++]<>>=5,z-=5,y.ndist=(j&31)+1,j>>>=5,z-=5,y.ncode=(j&15)+4,j>>>=4,z-=4,y.nlen>286||y.ndist>30){F.msg="too many length or distance symbols",y.mode=Q;break}y.have=0,y.mode=se;case se:for(;y.have>>=3,z-=3}for(;y.have<19;)y.lens[en[y.have++]]=0;if(y.lencode=y.lendyn,y.lenbits=7,At={bits:y.lenbits},Ft=c(m,y.lens,0,19,y.lencode,0,y.work,At),y.lenbits=At.bits,Ft){F.msg="invalid code lengths set",y.mode=Q;break}y.have=0,y.mode=be;case be:for(;y.have>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=Me,z-=Me,y.lens[y.have++]=ut;else{if(ut===16){for(Ht=Me+2;z>>=Me,z-=Me,y.have===0){F.msg="invalid bit length repeat",y.mode=Q;break}at=y.lens[y.have-1],ce=3+(j&3),j>>>=2,z-=2}else if(ut===17){for(Ht=Me+3;z>>=Me,z-=Me,at=0,ce=3+(j&7),j>>>=3,z-=3}else{for(Ht=Me+7;z>>=Me,z-=Me,at=0,ce=11+(j&127),j>>>=7,z-=7}if(y.have+ce>y.nlen+y.ndist){F.msg="invalid bit length repeat",y.mode=Q;break}for(;ce--;)y.lens[y.have++]=at}}if(y.mode===Q)break;if(y.lens[256]===0){F.msg="invalid code -- missing end-of-block",y.mode=Q;break}if(y.lenbits=9,At={bits:y.lenbits},Ft=c(d,y.lens,0,y.nlen,y.lencode,0,y.work,At),y.lenbits=At.bits,Ft){F.msg="invalid literal/lengths set",y.mode=Q;break}if(y.distbits=6,y.distcode=y.distdyn,At={bits:y.distbits},Ft=c(h,y.lens,y.nlen,y.ndist,y.distcode,0,y.work,At),y.distbits=At.bits,Ft){F.msg="invalid distances set",y.mode=Q;break}if(y.mode=ye,G===w)break e;case ye:y.mode=$;case $:if(ie>=6&&Je>=258){F.next_out=Qe,F.avail_out=Je,F.next_in=ee,F.avail_in=ie,y.hold=j,y.bits=z,l(F,je),Qe=F.next_out,Ae=F.output,Je=F.avail_out,ee=F.next_in,oe=F.input,ie=F.avail_in,j=y.hold,z=y.bits,y.mode===B&&(y.back=-1);break}for(y.back=0;et=y.lencode[j&(1<>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>pt)],Me=et>>>24,$e=et>>>16&255,ut=et&65535,!(pt+Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=pt,z-=pt,y.back+=pt}if(j>>>=Me,z-=Me,y.back+=Me,y.length=ut,$e===0){y.mode=X;break}if($e&32){y.back=-1,y.mode=B;break}if($e&64){F.msg="invalid literal/length code",y.mode=Q;break}y.extra=$e&15,y.mode=Ce;case Ce:if(y.extra){for(Ht=y.extra;z>>=y.extra,z-=y.extra,y.back+=y.extra}y.was=y.length,y.mode=Fe;case Fe:for(;et=y.distcode[j&(1<>>24,$e=et>>>16&255,ut=et&65535,!(Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>pt)],Me=et>>>24,$e=et>>>16&255,ut=et&65535,!(pt+Me<=z);){if(ie===0)break e;ie--,j+=oe[ee++]<>>=pt,z-=pt,y.back+=pt}if(j>>>=Me,z-=Me,y.back+=Me,$e&64){F.msg="invalid distance code",y.mode=Q;break}y.offset=ut,y.extra=$e&15,y.mode=xt;case xt:if(y.extra){for(Ht=y.extra;z>>=y.extra,z-=y.extra,y.back+=y.extra}if(y.offset>y.dmax){F.msg="invalid distance too far back",y.mode=Q;break}y.mode=Le;case Le:if(Je===0)break e;if(ce=je-Je,y.offset>ce){if(ce=y.offset-ce,ce>y.whave&&y.sane){F.msg="invalid distance too far back",y.mode=Q;break}ce>y.wnext?(ce-=y.wnext,vr=y.wsize-ce):vr=y.wnext-ce,ce>y.length&&(ce=y.length),kr=y.window}else kr=Ae,vr=Qe-y.offset,ce=y.length;ce>Je&&(ce=Je),Je-=ce,y.length-=ce;do Ae[Qe++]=kr[vr++];while(--ce);y.length===0&&(y.mode=$);break;case X:if(Je===0)break e;Ae[Qe++]=y.length,Je--,y.mode=$;break;case M:if(y.wrap){for(;z<32;){if(ie===0)break e;ie--,j|=oe[ee++]<=1&&$[Y]===0;Y--);if(A>Y&&(A=Y),Y===0)return E[T++]=1<<24|64<<16|0,E[T++]=1<<24|64<<16|0,I.bits=1,0;for(L=1;L0&&(x===c||Y!==1))return-1;for(Ce[1]=0,D=1;Du||x===d&&R>l)return 1;for(;;){Le=D-q,O[S]ye?(X=Fe[xt+O[S]],M=se[be+O[S]]):(X=96,M=0),re=1<>q)+P]=Le<<24|X<<16|M|0;while(P!==0);for(re=1<>=1;if(re!==0?(B&=re-1,B+=re):B=0,S++,--$[D]===0){if(D===Y)break;D=v[C+O[S]]}if(D>A&&(B&ne)!==W){for(q===0&&(q=A),xe+=L,N=D-q,U=1<u||x===d&&R>l)return 1;W=B&ne,E[W]=A<<24|N<<16|xe-T|0}}return B!==0&&(E[xe+B]=D-q<<24|64<<16|0),I.bits=A,0}},{"../utils/common":1}],10:[function(o,n,i){"use strict";n.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],11:[function(o,n,i){"use strict";function s(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}n.exports=s},{}],"/lib/inflate.js":[function(o,n,i){"use strict";var s=o("./zlib/inflate"),a=o("./utils/common"),u=o("./utils/strings"),l=o("./zlib/constants"),c=o("./zlib/messages"),m=o("./zlib/zstream"),d=o("./zlib/gzheader"),h=Object.prototype.toString;function g(_){if(!(this instanceof g))return new g(_);this.options=a.assign({chunkSize:16384,windowBits:0,to:""},_||{});var x=this.options;x.raw&&x.windowBits>=0&&x.windowBits<16&&(x.windowBits=-x.windowBits,x.windowBits===0&&(x.windowBits=-15)),x.windowBits>=0&&x.windowBits<16&&!(_&&_.windowBits)&&(x.windowBits+=32),x.windowBits>15&&x.windowBits<48&&(x.windowBits&15)===0&&(x.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new m,this.strm.avail_out=0;var v=s.inflateInit2(this.strm,x.windowBits);if(v!==l.Z_OK)throw new Error(c[v]);if(this.header=new d,s.inflateGetHeader(this.strm,this.header),x.dictionary&&(typeof x.dictionary=="string"?x.dictionary=u.string2buf(x.dictionary):h.call(x.dictionary)==="[object ArrayBuffer]"&&(x.dictionary=new Uint8Array(x.dictionary)),x.raw&&(v=s.inflateSetDictionary(this.strm,x.dictionary),v!==l.Z_OK)))throw new Error(c[v])}g.prototype.push=function(_,x){var v=this.strm,C=this.options.chunkSize,k=this.options.dictionary,E,T,O,I,J,D=!1;if(this.ended)return!1;T=x===~~x?x:x===!0?l.Z_FINISH:l.Z_NO_FLUSH,typeof _=="string"?v.input=u.binstring2buf(_):h.call(_)==="[object ArrayBuffer]"?v.input=new Uint8Array(_):v.input=_,v.next_in=0,v.avail_in=v.input.length;do{if(v.avail_out===0&&(v.output=new a.Buf8(C),v.next_out=0,v.avail_out=C),E=s.inflate(v,l.Z_NO_FLUSH),E===l.Z_NEED_DICT&&k&&(E=s.inflateSetDictionary(this.strm,k)),E===l.Z_BUF_ERROR&&D===!0&&(E=l.Z_OK,D=!1),E!==l.Z_STREAM_END&&E!==l.Z_OK)return this.onEnd(E),this.ended=!0,!1;v.next_out&&(v.avail_out===0||E===l.Z_STREAM_END||v.avail_in===0&&(T===l.Z_FINISH||T===l.Z_SYNC_FLUSH))&&(this.options.to==="string"?(O=u.utf8border(v.output,v.next_out),I=v.next_out-O,J=u.buf2string(v.output,O),v.next_out=I,v.avail_out=C-I,I&&a.arraySet(v.output,v.output,O,I,0),this.onData(J)):this.onData(a.shrinkBuf(v.output,v.next_out))),v.avail_in===0&&v.avail_out===0&&(D=!0)}while((v.avail_in>0||v.avail_out===0)&&E!==l.Z_STREAM_END);return E===l.Z_STREAM_END&&(T=l.Z_FINISH),T===l.Z_FINISH?(E=s.inflateEnd(this.strm),this.onEnd(E),this.ended=!0,E===l.Z_OK):(T===l.Z_SYNC_FLUSH&&(this.onEnd(l.Z_OK),v.avail_out=0),!0)},g.prototype.onData=function(_){this.chunks.push(_)},g.prototype.onEnd=function(_){_===l.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=a.flattenChunks(this.chunks)),this.chunks=[],this.err=_,this.msg=this.strm.msg};function b(_,x){var v=new g(x);if(v.push(_,!0),v.err)throw v.msg||c[v.err];return v.result}function w(_,x){return x=x||{},x.raw=!0,b(_,x)}i.Inflate=g,i.inflate=b,i.inflateRaw=w,i.ungzip=b},{"./utils/common":1,"./utils/strings":2,"./zlib/constants":4,"./zlib/gzheader":6,"./zlib/inflate":8,"./zlib/messages":10,"./zlib/zstream":11}]},{},[])("/lib/inflate.js")})();var wM=globalThis.fetch,ca=class{constructor(e,t={},r){this.type=e,this.detail=t,this.msg=r,Object.defineProperty(this,"__mayPropagate",{enumerable:!1,writable:!0}),this.__mayPropagate=!0}preventDefault(){}stopPropagation(){this.__mayPropagate=!1}valueOf(){return this}toString(){return this.msg?`[${this.type} event]: ${this.msg}`:`[${this.type} event]`}},TS=class{constructor(){this.listeners={}}addEventListener(e,t,r){let o=this.listeners[e]||[];r?o.unshift(t):o.push(t),this.listeners[e]=o}removeEventListener(e,t){let r=this.listeners[e]||[],o=r.findIndex(n=>n===t);o>-1&&(r.splice(o,1),this.listeners[e]=r)}dispatch(e){let t=this.listeners[e.type];if(t)for(let r=0,o=t.length;rString.fromCharCode(t)).join("")}var kS=class{constructor(e,t,r){this.name=(r||e.tag||"").trim(),this.length=e.length,this.start=e.offset,this.offset=0,this.data=t,["getInt8","getUint8","getInt16","getUint16","getInt32","getUint32","getBigInt64","getBigUint64"].forEach(o=>{let n=o.replace(/get(Big)?/,"").toLowerCase(),i=parseInt(o.replace(/[^\d]/g,""))/8;Object.defineProperty(this,n,{get:()=>this.getValue(o,i)})})}get currentPosition(){return this.start+this.offset}set currentPosition(e){this.start=e,this.offset=0}skip(e=0,t=8){this.offset+=e*t/8}getValue(e,t){let r=this.start+this.offset;this.offset+=t;try{return this.data[e](r)}catch(o){throw console.error("parser",e,t,this),console.error("parser",this.start,this.offset),o}}flags(e){if(e===8||e===16||e===32||e===64)return this[`uint${e}`].toString(2).padStart(e,0).split("").map(t=>t==="1");console.error("Error parsing flags: flag types can only be 1, 2, 4, or 8 bytes long"),console.trace()}get tag(){let e=this.uint32;return OS([e>>24&255,e>>16&255,e>>8&255,e&255])}get fixed(){let e=this.int16,t=Math.round(1e3*this.uint16/65356);return e+t/1e3}get legacyFixed(){let e=this.uint16,t=this.uint16.toString(16).padStart(4,0);return parseFloat(`${e}.${t}`)}get uint24(){return(this.uint8<<16)+(this.uint8<<8)+this.uint8}get uint128(){let e=0;for(let t=0;t<5;t++){let r=this.uint8;if(e=e*128+(r&127),r<128)break}return e}get longdatetime(){return new Date(PS+1e3*parseInt(this.int64.toString()))}get fword(){return this.int16}get ufword(){return this.uint16}get Offset16(){return this.uint16}get Offset32(){return this.uint32}get F2DOT14(){let e=p.uint16,t=[0,1,-2,-1][e>>14],r=e&16383;return t+r/16384}verifyLength(){this.offset!=this.length&&console.error(`unexpected parsed table size (${this.offset}) for "${this.name}" (expected ${this.length})`)}readBytes(e=0,t=0,r=8,o=!1){if(e=e||this.length,e===0)return[];t&&(this.currentPosition=t);let n=`${o?"":"u"}int${r}`,i=[];for(;e--;)i.push(this[n]);return i}},lt=class{constructor(e){Object.defineProperty(this,"parser",{enumerable:!1,get:()=>e});let r=e.currentPosition;Object.defineProperty(this,"start",{enumerable:!1,get:()=>r})}load(e){Object.keys(e).forEach(t=>{let r=Object.getOwnPropertyDescriptor(e,t);r.get?this[t]=r.get.bind(this):r.value!==void 0&&(this[t]=r.value)}),this.parser.length&&this.parser.verifyLength()}},ke=class extends lt{constructor(e,t,r){let{parser:o,start:n}=super(new kS(e,t,r));Object.defineProperty(this,"p",{enumerable:!1,get:()=>o}),Object.defineProperty(this,"tableStart",{enumerable:!1,get:()=>n})}};function ae(e,t,r){let o;Object.defineProperty(e,t,{get:()=>o||(o=r(),o),enumerable:!0})}var FS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:12},t,"sfnt");this.version=o.uint32,this.numTables=o.uint16,this.searchRange=o.uint16,this.entrySelector=o.uint16,this.rangeShift=o.uint16,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new AS(o)),this.tables={},this.directory.forEach(n=>{let i=()=>r(this.tables,{tag:n.tag,offset:n.offset,length:n.length},t);ae(this.tables,n.tag.trim(),i)})}},AS=class{constructor(e){this.tag=e.tag,this.checksum=e.uint32,this.offset=e.uint32,this.length=e.uint32}},my=py.inflate||void 0,hy=void 0,IS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:44},t,"woff");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(n=>new LS(o)),NS(this,t,r)}},LS=class{constructor(e){this.tag=e.tag,this.offset=e.uint32,this.compLength=e.uint32,this.origLength=e.uint32,this.origChecksum=e.uint32}};function NS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=0,i=t;if(o.compLength!==o.origLength){let s=t.buffer.slice(o.offset,o.offset+o.compLength),a;if(my)a=my(new Uint8Array(s));else if(hy)a=hy(new Uint8Array(s));else{let u="no brotli decoder available to decode WOFF2 font";throw font.onerror&&font.onerror(u),new Error(u)}i=new DataView(a.buffer)}else n=o.offset;return r(e.tables,{tag:o.tag,offset:n,length:o.origLength},i)})})}var gy=dy,yy=void 0,MS=class extends ke{constructor(e,t,r){let{p:o}=super({offset:0,length:48},t,"woff2");this.signature=o.tag,this.flavor=o.uint32,this.length=o.uint32,this.numTables=o.uint16,o.uint16,this.totalSfntSize=o.uint32,this.totalCompressedSize=o.uint32,this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.metaOffset=o.uint32,this.metaLength=o.uint32,this.metaOrigLength=o.uint32,this.privOffset=o.uint32,this.privLength=o.uint32,o.verifyLength(),this.directory=[...new Array(this.numTables)].map(a=>new VS(o));let n=o.currentPosition;this.directory[0].offset=0,this.directory.forEach((a,u)=>{let l=this.directory[u+1];l&&(l.offset=a.offset+(a.transformLength!==void 0?a.transformLength:a.origLength))});let i,s=t.buffer.slice(n);if(gy)i=gy(new Uint8Array(s));else if(yy)i=new Uint8Array(yy(s));else{let a="no brotli decoder available to decode WOFF2 font";throw e.onerror&&e.onerror(a),new Error(a)}DS(this,i,r)}},VS=class{constructor(e){this.flags=e.uint8;let t=this.tagNumber=this.flags&63;t===63?this.tag=e.tag:this.tag=BS(t);let o=(this.transformVersion=(this.flags&192)>>6)!==0;(this.tag==="glyf"||this.tag==="loca")&&(o=this.transformVersion!==3),this.origLength=e.uint128,o&&(this.transformLength=e.uint128)}};function DS(e,t,r){e.tables={},e.directory.forEach(o=>{ae(e.tables,o.tag.trim(),()=>{let n=o.offset,i=n+(o.transformLength?o.transformLength:o.origLength),s=new DataView(t.slice(n,i).buffer);try{return r(e.tables,{tag:o.tag,offset:0,length:o.origLength},s)}catch(a){console.error(a)}})})}function BS(e){return["cmap","head","hhea","hmtx","maxp","name","OS/2","post","cvt ","fpgm","glyf","loca","prep","CFF ","VORG","EBDT","EBLC","gasp","hdmx","kern","LTSH","PCLT","VDMX","vhea","vmtx","BASE","GDEF","GPOS","GSUB","EBSC","JSTF","MATH","CBDT","CBLC","COLR","CPAL","SVG ","sbix","acnt","avar","bdat","bloc","bsln","cvar","fdsc","feat","fmtx","fvar","gvar","hsty","just","lcar","mort","morx","opbd","prop","trak","Zapf","Silf","Glat","Gloc","Feat","Sill"][e&63]}var Cy={},Ry=!1;Promise.all([Promise.resolve().then(function(){return p_}),Promise.resolve().then(function(){return h_}),Promise.resolve().then(function(){return y_}),Promise.resolve().then(function(){return w_}),Promise.resolve().then(function(){return S_}),Promise.resolve().then(function(){return T_}),Promise.resolve().then(function(){return O_}),Promise.resolve().then(function(){return F_}),Promise.resolve().then(function(){return z_}),Promise.resolve().then(function(){return Q_}),Promise.resolve().then(function(){return BC}),Promise.resolve().then(function(){return zC}),Promise.resolve().then(function(){return GC}),Promise.resolve().then(function(){return XC}),Promise.resolve().then(function(){return JC}),Promise.resolve().then(function(){return $C}),Promise.resolve().then(function(){return rR}),Promise.resolve().then(function(){return nR}),Promise.resolve().then(function(){return sR}),Promise.resolve().then(function(){return lR}),Promise.resolve().then(function(){return uR}),Promise.resolve().then(function(){return dR}),Promise.resolve().then(function(){return hR}),Promise.resolve().then(function(){return vR}),Promise.resolve().then(function(){return bR}),Promise.resolve().then(function(){return xR}),Promise.resolve().then(function(){return _R}),Promise.resolve().then(function(){return RR}),Promise.resolve().then(function(){return TR}),Promise.resolve().then(function(){return kR}),Promise.resolve().then(function(){return MR}),Promise.resolve().then(function(){return jR}),Promise.resolve().then(function(){return UR}),Promise.resolve().then(function(){return qR}),Promise.resolve().then(function(){return XR}),Promise.resolve().then(function(){return JR}),Promise.resolve().then(function(){return e2}),Promise.resolve().then(function(){return r2}),Promise.resolve().then(function(){return a2}),Promise.resolve().then(function(){return c2}),Promise.resolve().then(function(){return d2})]).then(e=>{e.forEach(t=>{let r=Object.keys(t)[0];Cy[r]=t[r]}),Ry=!0});function jS(e,t,r){let o=t.tag.replace(/[^\w\d]/g,""),n=Cy[o];return n?new n(t,r,e):(console.warn(`lib-font has no definition for ${o}. The table was skipped.`),{})}function zS(){let e=0;function t(r,o){if(!Ry)return e>10?o(new Error("loading took too long")):(e++,setTimeout(()=>t(r),250));r(jS)}return new Promise((r,o)=>t(r))}function HS(e,t){let r=e.lastIndexOf("."),o=(e.substring(r+1)||"").toLowerCase(),n={ttf:"truetype",otf:"opentype",woff:"woff",woff2:"woff2"}[o];if(n)return n;let i={eot:"The .eot format is not supported: it died in January 12, 2016, when Microsoft retired all versions of IE that didn't already support WOFF.",svg:"The .svg format is not supported: SVG fonts (not to be confused with OpenType with embedded SVG) were so bad we took the entire fonts chapter out of the SVG specification again.",fon:"The .fon format is not supported: this is an ancient Windows bitmap font format.",ttc:"Based on the current CSS specification, font collections are not (yet?) supported."}[o];if(i||(i=`${e} is not a known webfont format.`),t)throw new Error(i);console.warn(`Could not load font: ${i}`)}async function US(e,t,r={}){if(!globalThis.document)return;let o=HS(t,r.errorOnStyle);if(!o)return;let n=document.createElement("style");n.className="injected-by-Font-js";let i=[];return r.styleRules&&(i=Object.entries(r.styleRules).map(([s,a])=>`${s}: ${a};`)),n.textContent=` @font-face { font-family: "${e}"; ${i.join(` `)} src: url("${t}") format("${o}"); -}`,globalThis.document.head.appendChild(n),n}var ZS=[0,1,0,0],XS=[79,84,84,79],KS=[119,79,70,70],JS=[119,79,70,50];function ua(e,t){if(e.length===t.length){for(let r=0;r(globalThis.document&&!this.options.skipStyleSheet&&await qS(this.name,e,this.options),this.loadFont(e)))()}async loadFont(e,t){fetch(e).then(r=>$S(r)&&r.arrayBuffer()).then(r=>this.fromDataBuffer(r,t||e)).catch(r=>{let o=new ca("error",r,`Failed to load font at ${t||e}`);this.dispatch(o),this.onerror&&this.onerror(o)})}async fromDataBuffer(e,t){this.fontData=new DataView(e);let r=QS(this.fontData);if(!r)throw new Error(`${t} is either an unsupported font format, or not a font at all.`);await this.parseBasicData(r);let o=new ca("load",{font:this});this.dispatch(o),this.onload&&this.onload(o)}async parseBasicData(e){return GS().then(t=>(e==="SFNT"&&(this.opentype=new NS(this,this.fontData,t)),e==="WOFF"&&(this.opentype=new VS(this,this.fontData,t)),e==="WOFF2"&&(this.opentype=new jS(this,this.fontData,t)),this.opentype))}getGlyphId(e){return this.opentype.tables.cmap.getGlyphId(e)}reverse(e){return this.opentype.tables.cmap.reverse(e)}supports(e){return this.getGlyphId(e)!==0}supportsVariation(e){return this.opentype.tables.cmap.supportsVariation(e)!==!1}measureText(e,t=16){if(this.__unloaded)throw new Error("Cannot measure text: font was unloaded. Please reload before calling measureText()");let r=document.createElement("div");r.textContent=e,r.style.fontFamily=this.name,r.style.fontSize=`${t}px`,r.style.color="transparent",r.style.background="transparent",r.style.top="0",r.style.left="0",r.style.position="absolute",document.body.appendChild(r);let o=r.getBoundingClientRect();document.body.removeChild(r);let n=this.opentype.tables["OS/2"];return o.fontSize=t,o.ascender=n.sTypoAscender,o.descender=n.sTypoDescender,o}unload(){if(this.styleElement.parentNode){this.styleElement.parentNode.removeElement(this.styleElement);let e=new ca("unload",{font:this});this.dispatch(e),this.onunload&&this.onunload(e)}this._unloaded=!0}load(){if(this.__unloaded){delete this.__unloaded,document.head.appendChild(this.styleElement);let e=new ca("load",{font:this});this.dispatch(e),this.onload&&this.onload(e)}}};globalThis.Font=da;var oo=class extends lt{constructor(e,t,r){super(e),this.plaformID=t,this.encodingID=r}},eC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=0,this.length=e.uint16,this.language=e.uint16,this.glyphIdArray=[...new Array(256)].map(o=>e.uint8)}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 0. only supports(id) is implemented.")),0<=e&&e<=255}reverse(e){return console.warn("reverse not implemented for cmap subtable format 0"),{}}getSupportedCharCodes(){return[{start:1,end:256}]}},tC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=2,this.length=e.uint16,this.language=e.uint16,this.subHeaderKeys=[...new Array(256)].map(s=>e.uint16);let o=Math.max(...this.subHeaderKeys),n=e.currentPosition;ae(this,"subHeaders",()=>(e.currentPosition=n,[...new Array(o)].map(s=>new rC(e))));let i=n+o*8;ae(this,"glyphIndexArray",()=>(e.currentPosition=i,[...new Array(o)].map(s=>e.uint16)))}supports(e){e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 2. only supports(id) is implemented."));let t=e&&255,r=e&&65280,o=this.subHeaders[r],n=this.subHeaders[o],i=n.firstCode,s=i+n.entryCount;return i<=t&&t<=s}reverse(e){return console.warn("reverse not implemented for cmap subtable format 2"),{}}getSupportedCharCodes(e=!1){return e?this.subHeaders.map(t=>({firstCode:t.firstCode,lastCode:t.lastCode})):this.subHeaders.map(t=>({start:t.firstCode,end:t.lastCode}))}},rC=class{constructor(e){this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.first+this.entryCount,this.idDelta=e.int16,this.idRangeOffset=e.uint16}},oC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=4,this.length=e.uint16,this.language=e.uint16,this.segCountX2=e.uint16,this.segCount=this.segCountX2/2,this.searchRange=e.uint16,this.entrySelector=e.uint16,this.rangeShift=e.uint16;let o=e.currentPosition;ae(this,"endCode",()=>e.readBytes(this.segCount,o,16));let n=o+2+this.segCountX2;ae(this,"startCode",()=>e.readBytes(this.segCount,n,16));let i=n+this.segCountX2;ae(this,"idDelta",()=>e.readBytes(this.segCount,i,16,!0));let s=i+this.segCountX2;ae(this,"idRangeOffset",()=>e.readBytes(this.segCount,s,16));let a=s+this.segCountX2,u=this.length-(a-this.tableStart);ae(this,"glyphIdArray",()=>e.readBytes(u,a,16)),ae(this,"segments",()=>this.buildSegments(s,a,e))}buildSegments(e,t,r){let o=(n,i)=>{let s=this.startCode[i],a=this.endCode[i],u=this.idDelta[i],l=this.idRangeOffset[i],c=e+2*i,m=[];if(l===0)for(let d=s+u,h=a+u;d<=h;d++)m.push(d);else for(let d=0,h=a-s;d<=h;d++)r.currentPosition=c+l+d*2,m.push(r.uint16);return{startCode:s,endCode:a,idDelta:u,idRangeOffset:l,glyphIDs:m}};return[...new Array(this.segCount)].map(o)}reverse(e){let t=this.segments.find(o=>o.glyphIDs.includes(e));if(!t)return{};let r=t.startCode+t.glyphIDs.indexOf(e);return{code:r,unicode:String.fromCodePoint(r)}}getGlyphId(e){if(e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535)return 0;let t=this.segments.find(r=>r.startCode<=e&&e<=r.endCode);return t?t.glyphIDs[e-t.startCode]:0}supports(e){return this.getGlyphId(e)!==0}getSupportedCharCodes(e=!1){return e?this.segments:this.segments.map(t=>({start:t.startCode,end:t.endCode}))}},nC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=6,this.length=e.uint16,this.language=e.uint16,this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.firstCode+this.entryCount-1,ae(this,"glyphIdArray",()=>[...new Array(this.entryCount)].map(n=>e.uint16))}supports(e){if(e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 6. only supports(id) is implemented.")),ethis.firstCode+this.entryCount)return{};let t=e-this.firstCode;return{code:t,unicode:String.fromCodePoint(t)}}reverse(e){let t=this.glyphIdArray.indexOf(e);if(t>-1)return this.firstCode+t}getSupportedCharCodes(e=!1){return e?[{firstCode:this.firstCode,lastCode:this.lastCode}]:[{start:this.firstCode,end:this.lastCode}]}},iC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=8,e.uint16,this.length=e.uint32,this.language=e.uint32,this.is32=[...new Array(8192)].map(n=>e.uint8),this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new sC(e)))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 8. only supports(id) is implemented.")),this.groups.findIndex(t=>t.startcharCode<=e&&e<=t.endcharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 8"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startcharCode,end:t.endcharCode}))}},sC=class{constructor(e){this.startcharCode=e.uint32,this.endcharCode=e.uint32,this.startGlyphID=e.uint32}},aC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=10,e.uint16,this.length=e.uint32,this.language=e.uint32,this.startCharCode=e.uint32,this.numChars=e.uint32,this.endCharCode=this.startCharCode+this.numChars,ae(this,"glyphs",()=>[...new Array(this.numChars)].map(n=>e.uint16))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 10. only supports(id) is implemented.")),ethis.startCharCode+this.numChars?!1:e-this.startCharCode}reverse(e){return console.warn("reverse not implemented for cmap subtable format 10"),{}}getSupportedCharCodes(e=!1){return e?[{startCharCode:this.startCharCode,endCharCode:this.endCharCode}]:[{start:this.startCharCode,end:this.endCharCode}]}},lC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=12,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new cC(e)))}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535?0:this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){for(let t of this.groups){let r=t.startGlyphID;if(r>e)continue;if(r===e)return t.startCharCode;if(r+(t.endCharCode-t.startCharCode)({start:t.startCharCode,end:t.endCharCode}))}},cC=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.startGlyphID=e.uint32}},uC=class extends oo{constructor(e,t,r){super(e,t,r),this.format=13,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32;let o=[...new Array(this.numGroups)].map(n=>new fC(e));ae(this,"groups",o)}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 13"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startCharCode,end:t.endCharCode}))}},fC=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.glyphID=e.uint32}},dC=class extends oo{constructor(e,t,r){super(e,t,r),this.subTableStart=e.currentPosition,this.format=14,this.length=e.uint32,this.numVarSelectorRecords=e.uint32,ae(this,"varSelectors",()=>[...new Array(this.numVarSelectorRecords)].map(o=>new pC(e)))}supports(){return console.warn("supports not implemented for cmap subtable format 14"),0}getSupportedCharCodes(){return console.warn("getSupportedCharCodes not implemented for cmap subtable format 14"),[]}reverse(e){return console.warn("reverse not implemented for cmap subtable format 14"),{}}supportsVariation(e){let t=this.varSelector.find(r=>r.varSelector===e);return t||!1}getSupportedVariations(){return this.varSelectors.map(e=>e.varSelector)}},pC=class{constructor(e){this.varSelector=e.uint24,this.defaultUVSOffset=e.Offset32,this.nonDefaultUVSOffset=e.Offset32}};function mC(e,t,r){let o=e.uint16;return o===0?new eC(e,t,r):o===2?new tC(e,t,r):o===4?new oC(e,t,r):o===6?new nC(e,t,r):o===8?new iC(e,t,r):o===10?new aC(e,t,r):o===12?new lC(e,t,r):o===13?new uC(e,t,r):o===14?new dC(e,t,r):{}}var hC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numTables=r.uint16,this.encodingRecords=[...new Array(this.numTables)].map(o=>new gC(r,this.tableStart))}getSubTable(e){return this.encodingRecords[e].table}getSupportedEncodings(){return this.encodingRecords.map(e=>({platformID:e.platformID,encodingId:e.encodingID}))}getSupportedCharCodes(e,t){let r=this.encodingRecords.findIndex(n=>n.platformID===e&&n.encodingID===t);return r===-1?!1:this.getSubTable(r).getSupportedCharCodes()}reverse(e){for(let t=0;t{let n=this.getSubTable(o);return n.getGlyphId?(t=n.getGlyphId(e),t!==0):!1}),t}supports(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supports&&o.supports(e)!==!1})}supportsVariation(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supportsVariation&&o.supportsVariation(e)!==!1})}},gC=class{constructor(e,t){let r=this.platformID=e.uint16,o=this.encodingID=e.uint16,n=this.offset=e.Offset32;ae(this,"table",()=>(e.currentPosition=t+n,mC(e,r,o)))}},yC=Object.freeze({__proto__:null,cmap:hC}),vC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.load({majorVersion:r.uint16,minorVersion:r.uint16,fontRevision:r.fixed,checkSumAdjustment:r.uint32,magicNumber:r.uint32,flags:r.flags(16),unitsPerEm:r.uint16,created:r.longdatetime,modified:r.longdatetime,xMin:r.int16,yMin:r.int16,xMax:r.int16,yMax:r.int16,macStyle:r.flags(16),lowestRecPPEM:r.uint16,fontDirectionHint:r.uint16,indexToLocFormat:r.uint16,glyphDataFormat:r.uint16})}},bC=Object.freeze({__proto__:null,head:vC}),wC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.ascender=r.fword,this.descender=r.fword,this.lineGap=r.fword,this.advanceWidthMax=r.ufword,this.minLeftSideBearing=r.fword,this.minRightSideBearing=r.fword,this.xMaxExtent=r.fword,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,r.int16,r.int16,r.int16,r.int16,this.metricDataFormat=r.int16,this.numberOfHMetrics=r.uint16,r.verifyLength()}},xC=Object.freeze({__proto__:null,hhea:wC}),SC=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.hhea.numberOfHMetrics,i=r.maxp.numGlyphs,s=o.currentPosition;if(ae(this,"hMetrics",()=>(o.currentPosition=s,[...new Array(n)].map(a=>new CC(o.uint16,o.int16)))),n(o.currentPosition=a,[...new Array(i-n)].map(u=>o.int16)))}}},CC=class{constructor(e,t){this.advanceWidth=e,this.lsb=t}},_C=Object.freeze({__proto__:null,hmtx:SC}),RC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.legacyFixed,this.numGlyphs=r.uint16,this.version===1&&(this.maxPoints=r.uint16,this.maxContours=r.uint16,this.maxCompositePoints=r.uint16,this.maxCompositeContours=r.uint16,this.maxZones=r.uint16,this.maxTwilightPoints=r.uint16,this.maxStorage=r.uint16,this.maxFunctionDefs=r.uint16,this.maxInstructionDefs=r.uint16,this.maxStackElements=r.uint16,this.maxSizeOfInstructions=r.uint16,this.maxComponentElements=r.uint16,this.maxComponentDepth=r.uint16),r.verifyLength()}},EC=Object.freeze({__proto__:null,maxp:RC}),TC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.format=r.uint16,this.count=r.uint16,this.stringOffset=r.Offset16,this.nameRecords=[...new Array(this.count)].map(o=>new OC(r,this)),this.format===1&&(this.langTagCount=r.uint16,this.langTagRecords=[...new Array(this.langTagCount)].map(o=>new PC(r.uint16,r.Offset16))),this.stringStart=this.tableStart+this.stringOffset}get(e){let t=this.nameRecords.find(r=>r.nameID===e);if(t)return t.string}},PC=class{constructor(e,t){this.length=e,this.offset=t}},OC=class{constructor(e,t){this.platformID=e.uint16,this.encodingID=e.uint16,this.languageID=e.uint16,this.nameID=e.uint16,this.length=e.uint16,this.offset=e.Offset16,ae(this,"string",()=>(e.currentPosition=t.stringStart+this.offset,kC(e,this)))}};function kC(e,t){let{platformID:r,length:o}=t;if(o===0)return"";if(r===0||r===3){let s=[];for(let a=0,u=o/2;ar.uint8),this.ulUnicodeRange1=r.flags(32),this.ulUnicodeRange2=r.flags(32),this.ulUnicodeRange3=r.flags(32),this.ulUnicodeRange4=r.flags(32),this.achVendID=r.tag,this.fsSelection=r.uint16,this.usFirstCharIndex=r.uint16,this.usLastCharIndex=r.uint16,this.sTypoAscender=r.int16,this.sTypoDescender=r.int16,this.sTypoLineGap=r.int16,this.usWinAscent=r.uint16,this.usWinDescent=r.uint16,this.version===0||(this.ulCodePageRange1=r.flags(32),this.ulCodePageRange2=r.flags(32),this.version===1)||(this.sxHeight=r.int16,this.sCapHeight=r.int16,this.usDefaultChar=r.uint16,this.usBreakChar=r.uint16,this.usMaxContext=r.uint16,this.version<=4)||(this.usLowerOpticalPointSize=r.uint16,this.usUpperOpticalPointSize=r.uint16,this.version===5))return r.verifyLength()}},IC=Object.freeze({__proto__:null,OS2:AC}),LC=class extends ke{constructor(e,t){let{p:r}=super(e,t);if(this.version=r.legacyFixed,this.italicAngle=r.fixed,this.underlinePosition=r.fword,this.underlineThickness=r.fword,this.isFixedPitch=r.uint32,this.minMemType42=r.uint32,this.maxMemType42=r.uint32,this.minMemType1=r.uint32,this.maxMemType1=r.uint32,this.version===1||this.version===3)return r.verifyLength();if(this.numGlyphs=r.uint16,this.version===2){this.glyphNameIndex=[...new Array(this.numGlyphs)].map(o=>r.uint16),this.namesOffset=r.currentPosition,this.glyphNameOffsets=[1];for(let o=0;or.int8))}getGlyphName(e){if(this.version!==2)return console.warn(`post table version ${this.version} does not support glyph name lookups`),"";let t=this.glyphNameIndex[e];if(t<258)return Ry[t];let r=this.glyphNameOffsets[e],n=this.glyphNameOffsets[e+1]-r-1;return n===0?".notdef.":(this.parser.currentPosition=this.namesOffset+r,this.parser.readBytes(n,this.namesOffset+r,8,!0).map(s=>String.fromCharCode(s)).join(""))}},Ry=[".notdef",".null","nonmarkingreturn","space","exclam","quotedbl","numbersign","dollar","percent","ampersand","quotesingle","parenleft","parenright","asterisk","plus","comma","hyphen","period","slash","zero","one","two","three","four","five","six","seven","eight","nine","colon","semicolon","less","equal","greater","question","at","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","bracketleft","backslash","bracketright","asciicircum","underscore","grave","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","braceleft","bar","braceright","asciitilde","Adieresis","Aring","Ccedilla","Eacute","Ntilde","Odieresis","Udieresis","aacute","agrave","acircumflex","adieresis","atilde","aring","ccedilla","eacute","egrave","ecircumflex","edieresis","iacute","igrave","icircumflex","idieresis","ntilde","oacute","ograve","ocircumflex","odieresis","otilde","uacute","ugrave","ucircumflex","udieresis","dagger","degree","cent","sterling","section","bullet","paragraph","germandbls","registered","copyright","trademark","acute","dieresis","notequal","AE","Oslash","infinity","plusminus","lessequal","greaterequal","yen","mu","partialdiff","summation","product","pi","integral","ordfeminine","ordmasculine","Omega","ae","oslash","questiondown","exclamdown","logicalnot","radical","florin","approxequal","Delta","guillemotleft","guillemotright","ellipsis","nonbreakingspace","Agrave","Atilde","Otilde","OE","oe","endash","emdash","quotedblleft","quotedblright","quoteleft","quoteright","divide","lozenge","ydieresis","Ydieresis","fraction","currency","guilsinglleft","guilsinglright","fi","fl","daggerdbl","periodcentered","quotesinglbase","quotedblbase","perthousand","Acircumflex","Ecircumflex","Aacute","Edieresis","Egrave","Iacute","Icircumflex","Idieresis","Igrave","Oacute","Ocircumflex","apple","Ograve","Uacute","Ucircumflex","Ugrave","dotlessi","circumflex","tilde","macron","breve","dotaccent","ring","cedilla","hungarumlaut","ogonek","caron","Lslash","lslash","Scaron","scaron","Zcaron","zcaron","brokenbar","Eth","eth","Yacute","yacute","Thorn","thorn","minus","multiply","onesuperior","twosuperior","threesuperior","onehalf","onequarter","threequarters","franc","Gbreve","gbreve","Idotaccent","Scedilla","scedilla","Cacute","cacute","Ccaron","ccaron","dcroat"],NC=Object.freeze({__proto__:null,post:LC}),MC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.horizAxisOffset=r.Offset16,this.vertAxisOffset=r.Offset16,ae(this,"horizAxis",()=>new nu({offset:e.offset+this.horizAxisOffset},t)),ae(this,"vertAxis",()=>new nu({offset:e.offset+this.vertAxisOffset},t)),this.majorVersion===1&&this.minorVersion===1&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>new nu({offset:e.offset+this.itemVarStoreOffset},t)))}},nu=class extends ke{constructor(e,t){let{p:r}=super(e,t,"AxisTable");this.baseTagListOffset=r.Offset16,this.baseScriptListOffset=r.Offset16,ae(this,"baseTagList",()=>new VC({offset:e.offset+this.baseTagListOffset},t)),ae(this,"baseScriptList",()=>new DC({offset:e.offset+this.baseScriptListOffset},t))}},VC=class extends ke{constructor(e,t){let{p:r}=super(e,t,"BaseTagListTable");this.baseTagCount=r.uint16,this.baselineTags=[...new Array(this.baseTagCount)].map(o=>r.tag)}},DC=class extends ke{constructor(e,t){let{p:r}=super(e,t,"BaseScriptListTable");this.baseScriptCount=r.uint16;let o=r.currentPosition;ae(this,"baseScriptRecords",()=>(r.currentPosition=o,[...new Array(this.baseScriptCount)].map(n=>new BC(this.start,r))))}},BC=class{constructor(e,t){this.baseScriptTag=t.tag,this.baseScriptOffset=t.Offset16,ae(this,"baseScriptTable",()=>(t.currentPosition=e+this.baseScriptOffset,new jC(t)))}},jC=class{constructor(e){this.start=e.currentPosition,this.baseValuesOffset=e.Offset16,this.defaultMinMaxOffset=e.Offset16,this.baseLangSysCount=e.uint16,this.baseLangSysRecords=[...new Array(this.baseLangSysCount)].map(t=>new zC(this.start,e)),ae(this,"baseValues",()=>(e.currentPosition=this.start+this.baseValuesOffset,new HC(e))),ae(this,"defaultMinMax",()=>(e.currentPosition=this.start+this.defaultMinMaxOffset,new Iy(e)))}},zC=class{constructor(e,t){this.baseLangSysTag=t.tag,this.minMaxOffset=t.Offset16,ae(this,"minMax",()=>(t.currentPosition=e+this.minMaxOffset,new Iy(t)))}},HC=class{constructor(e){this.parser=e,this.start=e.currentPosition,this.defaultBaselineIndex=e.uint16,this.baseCoordCount=e.uint16,this.baseCoords=[...new Array(this.baseCoordCount)].map(t=>e.Offset16)}getTable(e){return this.parser.currentPosition=this.start+this.baseCoords[e],new WC(this.parser)}},Iy=class{constructor(e){this.minCoord=e.Offset16,this.maxCoord=e.Offset16,this.featMinMaxCount=e.uint16;let t=e.currentPosition;ae(this,"featMinMaxRecords",()=>(e.currentPosition=t,[...new Array(this.featMinMaxCount)].map(r=>new UC(e))))}},UC=class{constructor(e){this.featureTableTag=e.tag,this.minCoord=e.Offset16,this.maxCoord=e.Offset16}},WC=class{constructor(e){this.baseCoordFormat=e.uint16,this.coordinate=e.int16,this.baseCoordFormat===2&&(this.referenceGlyph=e.uint16,this.baseCoordPoint=e.uint16),this.baseCoordFormat===3&&(this.deviceTable=e.Offset16)}},GC=Object.freeze({__proto__:null,BASE:MC}),Ey=class{constructor(e){this.classFormat=e.uint16,this.classFormat===1&&(this.startGlyphID=e.uint16,this.glyphCount=e.uint16,this.classValueArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.classFormat===2&&(this.classRangeCount=e.uint16,this.classRangeRecords=[...new Array(this.classRangeCount)].map(t=>new YC(e)))}},YC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.class=e.uint16}},Ci=class extends lt{constructor(e){super(e),this.coverageFormat=e.uint16,this.coverageFormat===1&&(this.glyphCount=e.uint16,this.glyphArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.coverageFormat===2&&(this.rangeCount=e.uint16,this.rangeRecords=[...new Array(this.rangeCount)].map(t=>new qC(e)))}},qC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.startCoverageIndex=e.uint16}},ZC=class{constructor(e,t){this.table=e,this.parser=t,this.start=t.currentPosition,this.format=t.uint16,this.variationRegionListOffset=t.Offset32,this.itemVariationDataCount=t.uint16,this.itemVariationDataOffsets=[...new Array(this.itemVariationDataCount)].map(r=>t.Offset32)}},XC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.glyphClassDefOffset=r.Offset16,ae(this,"glyphClassDefs",()=>{if(this.glyphClassDefOffset!==0)return r.currentPosition=this.tableStart+this.glyphClassDefOffset,new Ey(r)}),this.attachListOffset=r.Offset16,ae(this,"attachList",()=>{if(this.attachListOffset!==0)return r.currentPosition=this.tableStart+this.attachListOffset,new KC(r)}),this.ligCaretListOffset=r.Offset16,ae(this,"ligCaretList",()=>{if(this.ligCaretListOffset!==0)return r.currentPosition=this.tableStart+this.ligCaretListOffset,new QC(r)}),this.markAttachClassDefOffset=r.Offset16,ae(this,"markAttachClassDef",()=>{if(this.markAttachClassDefOffset!==0)return r.currentPosition=this.tableStart+this.markAttachClassDefOffset,new Ey(r)}),this.minorVersion>=2&&(this.markGlyphSetsDefOffset=r.Offset16,ae(this,"markGlyphSetsDef",()=>{if(this.markGlyphSetsDefOffset!==0)return r.currentPosition=this.tableStart+this.markGlyphSetsDefOffset,new t_(r)})),this.minorVersion===3&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>{if(this.itemVarStoreOffset!==0)return r.currentPosition=this.tableStart+this.itemVarStoreOffset,new ZC(r)}))}},KC=class extends lt{constructor(e){super(e),this.coverageOffset=e.Offset16,this.glyphCount=e.uint16,this.attachPointOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16)}getPoint(e){return this.parser.currentPosition=this.start+this.attachPointOffsets[e],new JC(this.parser)}},JC=class{constructor(e){this.pointCount=e.uint16,this.pointIndices=[...new Array(this.pointCount)].map(t=>e.uint16)}},QC=class extends lt{constructor(e){super(e),this.coverageOffset=e.Offset16,ae(this,"coverage",()=>(e.currentPosition=this.start+this.coverageOffset,new Ci(e))),this.ligGlyphCount=e.uint16,this.ligGlyphOffsets=[...new Array(this.ligGlyphCount)].map(t=>e.Offset16)}getLigGlyph(e){return this.parser.currentPosition=this.start+this.ligGlyphOffsets[e],new $C(this.parser)}},$C=class extends lt{constructor(e){super(e),this.caretCount=e.uint16,this.caretValueOffsets=[...new Array(this.caretCount)].map(t=>e.Offset16)}getCaretValue(e){return this.parser.currentPosition=this.start+this.caretValueOffsets[e],new e_(this.parser)}},e_=class{constructor(e){this.caretValueFormat=e.uint16,this.caretValueFormat===1&&(this.coordinate=e.int16),this.caretValueFormat===2&&(this.caretValuePointIndex=e.uint16),this.caretValueFormat===3&&(this.coordinate=e.int16,this.deviceOffset=e.Offset16)}},t_=class extends lt{constructor(e){super(e),this.markGlyphSetTableFormat=e.uint16,this.markGlyphSetCount=e.uint16,this.coverageOffsets=[...new Array(this.markGlyphSetCount)].map(t=>e.Offset32)}getMarkGlyphSet(e){return this.parser.currentPosition=this.start+this.coverageOffsets[e],new Ci(this.parser)}},r_=Object.freeze({__proto__:null,GDEF:XC}),Ty=class extends lt{static EMPTY={scriptCount:0,scriptRecords:[]};constructor(e){super(e),this.scriptCount=e.uint16,this.scriptRecords=[...new Array(this.scriptCount)].map(t=>new o_(e))}},o_=class{constructor(e){this.scriptTag=e.tag,this.scriptOffset=e.Offset16}},n_=class extends lt{constructor(e){super(e),this.defaultLangSys=e.Offset16,this.langSysCount=e.uint16,this.langSysRecords=[...new Array(this.langSysCount)].map(t=>new i_(e))}},i_=class{constructor(e){this.langSysTag=e.tag,this.langSysOffset=e.Offset16}},Py=class{constructor(e){this.lookupOrder=e.Offset16,this.requiredFeatureIndex=e.uint16,this.featureIndexCount=e.uint16,this.featureIndices=[...new Array(this.featureIndexCount)].map(t=>e.uint16)}},Oy=class extends lt{static EMPTY={featureCount:0,featureRecords:[]};constructor(e){super(e),this.featureCount=e.uint16,this.featureRecords=[...new Array(this.featureCount)].map(t=>new s_(e))}},s_=class{constructor(e){this.featureTag=e.tag,this.featureOffset=e.Offset16}},a_=class extends lt{constructor(e){super(e),this.featureParams=e.Offset16,this.lookupIndexCount=e.uint16,this.lookupListIndices=[...new Array(this.lookupIndexCount)].map(t=>e.uint16)}getFeatureParams(){if(this.featureParams>0){let e=this.parser;e.currentPosition=this.start+this.featureParams;let t=this.featureTag;if(t==="size")return new c_(e);if(t.startsWith("cc"))return new l_(e);if(t.startsWith("ss"))return new u_(e)}}},l_=class{constructor(e){this.format=e.uint16,this.featUiLabelNameId=e.uint16,this.featUiTooltipTextNameId=e.uint16,this.sampleTextNameId=e.uint16,this.numNamedParameters=e.uint16,this.firstParamUiLabelNameId=e.uint16,this.charCount=e.uint16,this.character=[...new Array(this.charCount)].map(t=>e.uint24)}},c_=class{constructor(e){this.designSize=e.uint16,this.subfamilyIdentifier=e.uint16,this.subfamilyNameID=e.uint16,this.smallEnd=e.uint16,this.largeEnd=e.uint16}},u_=class{constructor(e){this.version=e.uint16,this.UINameID=e.uint16}};function Ly(e){e.parser.currentPosition-=2,delete e.coverageOffset,delete e.getCoverageTable}var Qo=class extends lt{constructor(e){super(e),this.substFormat=e.uint16,this.coverageOffset=e.Offset16}getCoverageTable(){let e=this.parser;return e.currentPosition=this.start+this.coverageOffset,new Ci(e)}},su=class{constructor(e){this.glyphSequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},f_=class extends Qo{constructor(e){super(e),this.deltaGlyphID=e.int16}},d_=class extends Qo{constructor(e){super(e),this.sequenceCount=e.uint16,this.sequenceOffsets=[...new Array(this.sequenceCount)].map(t=>e.Offset16)}getSequence(e){let t=this.parser;return t.currentPosition=this.start+this.sequenceOffsets[e],new p_(t)}},p_=class{constructor(e){this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},m_=class extends Qo{constructor(e){super(e),this.alternateSetCount=e.uint16,this.alternateSetOffsets=[...new Array(this.alternateSetCount)].map(t=>e.Offset16)}getAlternateSet(e){let t=this.parser;return t.currentPosition=this.start+this.alternateSetOffsets[e],new h_(t)}},h_=class{constructor(e){this.glyphCount=e.uint16,this.alternateGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},g_=class extends Qo{constructor(e){super(e),this.ligatureSetCount=e.uint16,this.ligatureSetOffsets=[...new Array(this.ligatureSetCount)].map(t=>e.Offset16)}getLigatureSet(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureSetOffsets[e],new y_(t)}},y_=class extends lt{constructor(e){super(e),this.ligatureCount=e.uint16,this.ligatureOffsets=[...new Array(this.ligatureCount)].map(t=>e.Offset16)}getLigature(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureOffsets[e],new v_(t)}},v_=class{constructor(e){this.ligatureGlyph=e.uint16,this.componentCount=e.uint16,this.componentGlyphIDs=[...new Array(this.componentCount-1)].map(t=>e.uint16)}},b_=class extends Qo{constructor(e){super(e),this.substFormat===1&&(this.subRuleSetCount=e.uint16,this.subRuleSetOffsets=[...new Array(this.subRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.classDefOffset=e.Offset16,this.subClassSetCount=e.uint16,this.subClassSetOffsets=[...new Array(this.subClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(Ly(this),this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.coverageOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new su(e)))}getSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 5.${this.substFormat} has no subrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.subRuleSetOffsets[e],new w_(t)}getSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 5.${this.substFormat} has no subclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.subClassSetOffsets[e],new x_(t)}getCoverageTable(e){if(this.substFormat!==3&&!e)return super.getCoverageTable();if(!e)throw new Error(`lookup type 5.${this.substFormat} requires an coverage table index.`);let t=this.parser;return t.currentPosition=this.start+this.coverageOffsets[e],new Ci(t)}},w_=class extends lt{constructor(e){super(e),this.subRuleCount=e.uint16,this.subRuleOffsets=[...new Array(this.subRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.subRuleOffsets[e],new Ny(t)}},Ny=class{constructor(e){this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.inputSequence=[...new Array(this.glyphCount-1)].map(t=>e.uint16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new su(e))}},x_=class extends lt{constructor(e){super(e),this.subClassRuleCount=e.uint16,this.subClassRuleOffsets=[...new Array(this.subClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.subClassRuleOffsets[e],new S_(t)}},S_=class extends Ny{constructor(e){super(e)}},C_=class extends Qo{constructor(e){super(e),this.substFormat===1&&(this.chainSubRuleSetCount=e.uint16,this.chainSubRuleSetOffsets=[...new Array(this.chainSubRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.backtrackClassDefOffset=e.Offset16,this.inputClassDefOffset=e.Offset16,this.lookaheadClassDefOffset=e.Offset16,this.chainSubClassSetCount=e.uint16,this.chainSubClassSetOffsets=[...new Array(this.chainSubClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(Ly(this),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.inputGlyphCount=e.uint16,this.inputCoverageOffsets=[...new Array(this.inputGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[...new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.seqLookupCount=e.uint16,this.seqLookupRecords=[...new Array(this.substitutionCount)].map(t=>new My(e)))}getChainSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 6.${this.substFormat} has no chainsubrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleSetOffsets[e],new __(t)}getChainSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 6.${this.substFormat} has no chainsubclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubClassSetOffsets[e],new E_(t)}getCoverageFromOffset(e){if(this.substFormat!==3)throw new Error(`lookup type 6.${this.substFormat} does not use contextual coverage offsets.`);let t=this.parser;return t.currentPosition=this.start+e,new Ci(t)}},__=class extends lt{constructor(e){super(e),this.chainSubRuleCount=e.uint16,this.chainSubRuleOffsets=[...new Array(this.chainSubRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new R_(t)}},R_=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.SubstCount)].map(t=>new su(e))}},E_=class extends lt{constructor(e){super(e),this.chainSubClassRuleCount=e.uint16,this.chainSubClassRuleOffsets=[...new Array(this.chainSubClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new T_(t)}},T_=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new My(e))}},My=class extends lt{constructor(e){super(e),this.sequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},P_=class extends lt{constructor(e){super(e),this.substFormat=e.uint16,this.extensionLookupType=e.uint16,this.extensionOffset=e.Offset32}},O_=class extends Qo{constructor(e){super(e),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},k_={buildSubtable:function(e,t){let r=new[void 0,f_,d_,m_,g_,b_,C_,P_,O_][e](t);return r.type=e,r}},no=class extends lt{constructor(e){super(e)}},F_=class extends no{constructor(e){super(e),console.log("lookup type 1")}},A_=class extends no{constructor(e){super(e),console.log("lookup type 2")}},I_=class extends no{constructor(e){super(e),console.log("lookup type 3")}},L_=class extends no{constructor(e){super(e),console.log("lookup type 4")}},N_=class extends no{constructor(e){super(e),console.log("lookup type 5")}},M_=class extends no{constructor(e){super(e),console.log("lookup type 6")}},V_=class extends no{constructor(e){super(e),console.log("lookup type 7")}},D_=class extends no{constructor(e){super(e),console.log("lookup type 8")}},B_=class extends no{constructor(e){super(e),console.log("lookup type 9")}},j_={buildSubtable:function(e,t){let r=new[void 0,F_,A_,I_,L_,N_,M_,V_,D_,B_][e](t);return r.type=e,r}},ky=class extends lt{static EMPTY={lookupCount:0,lookups:[]};constructor(e){super(e),this.lookupCount=e.uint16,this.lookups=[...new Array(this.lookupCount)].map(t=>e.Offset16)}},z_=class extends lt{constructor(e,t){super(e),this.ctType=t,this.lookupType=e.uint16,this.lookupFlag=e.uint16,this.subTableCount=e.uint16,this.subtableOffsets=[...new Array(this.subTableCount)].map(r=>e.Offset16),this.markFilteringSet=e.uint16}get rightToLeft(){return this.lookupFlag&!0}get ignoreBaseGlyphs(){return this.lookupFlag&!0}get ignoreLigatures(){return this.lookupFlag&!0}get ignoreMarks(){return this.lookupFlag&!0}get useMarkFilteringSet(){return this.lookupFlag&!0}get markAttachmentType(){return this.lookupFlag&!0}getSubTable(e){let t=this.ctType==="GSUB"?k_:j_;return this.parser.currentPosition=this.start+this.subtableOffsets[e],t.buildSubtable(this.lookupType,this.parser)}},Vy=class extends ke{constructor(e,t,r){let{p:o,tableStart:n}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.scriptListOffset=o.Offset16,this.featureListOffset=o.Offset16,this.lookupListOffset=o.Offset16,this.majorVersion===1&&this.minorVersion===1&&(this.featureVariationsOffset=o.Offset32);let i=!(this.scriptListOffset||this.featureListOffset||this.lookupListOffset);ae(this,"scriptList",()=>i?Ty.EMPTY:(o.currentPosition=n+this.scriptListOffset,new Ty(o))),ae(this,"featureList",()=>i?Oy.EMPTY:(o.currentPosition=n+this.featureListOffset,new Oy(o))),ae(this,"lookupList",()=>i?ky.EMPTY:(o.currentPosition=n+this.lookupListOffset,new ky(o))),this.featureVariationsOffset&&ae(this,"featureVariations",()=>i?FeatureVariations.EMPTY:(o.currentPosition=n+this.featureVariationsOffset,new FeatureVariations(o)))}getSupportedScripts(){return this.scriptList.scriptRecords.map(e=>e.scriptTag)}getScriptTable(e){let t=this.scriptList.scriptRecords.find(o=>o.scriptTag===e);this.parser.currentPosition=this.scriptList.start+t.scriptOffset;let r=new n_(this.parser);return r.scriptTag=e,r}ensureScriptTable(e){return typeof e=="string"?this.getScriptTable(e):e}getSupportedLangSys(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys!==0,r=e.langSysRecords.map(o=>o.langSysTag);return t&&r.unshift("dflt"),r}getDefaultLangSysTable(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys;if(t!==0){this.parser.currentPosition=e.start+t;let r=new Py(this.parser);return r.langSysTag="",r.defaultForScript=e.scriptTag,r}}getLangSysTable(e,t="dflt"){if(t==="dflt")return this.getDefaultLangSysTable(e);e=this.ensureScriptTable(e);let r=e.langSysRecords.find(n=>n.langSysTag===t);this.parser.currentPosition=e.start+r.langSysOffset;let o=new Py(this.parser);return o.langSysTag=t,o}getFeatures(e){return e.featureIndices.map(t=>this.getFeature(t))}getFeature(e){let t;if(parseInt(e)==e?t=this.featureList.featureRecords[e]:t=this.featureList.featureRecords.find(o=>o.featureTag===e),!t)return;this.parser.currentPosition=this.featureList.start+t.featureOffset;let r=new a_(this.parser);return r.featureTag=t.featureTag,r}getLookups(e){return e.lookupListIndices.map(t=>this.getLookup(t))}getLookup(e,t){let r=this.lookupList.lookups[e];return this.parser.currentPosition=this.lookupList.start+r,new z_(this.parser,t)}},H_=class extends Vy{constructor(e,t){super(e,t,"GSUB")}getLookup(e){return super.getLookup(e,"GSUB")}},U_=Object.freeze({__proto__:null,GSUB:H_}),W_=class extends Vy{constructor(e,t){super(e,t,"GPOS")}getLookup(e){return super.getLookup(e,"GPOS")}},G_=Object.freeze({__proto__:null,GPOS:W_}),Y_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.offsetToSVGDocumentList=r.Offset32,r.currentPosition=this.tableStart+this.offsetToSVGDocumentList,this.documentList=new q_(r)}},q_=class extends lt{constructor(e){super(e),this.numEntries=e.uint16,this.documentRecords=[...new Array(this.numEntries)].map(t=>new Z_(e))}getDocument(e){let t=this.documentRecords[e];if(!t)return"";let r=this.start+t.svgDocOffset;return this.parser.currentPosition=r,this.parser.readBytes(t.svgDocLength)}getDocumentForGlyph(e){let t=this.documentRecords.findIndex(r=>r.startGlyphID<=e&&e<=r.endGlyphID);return t===-1?"":this.getDocument(t)}},Z_=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.svgDocOffset=e.Offset32,this.svgDocLength=e.uint32}},X_=Object.freeze({__proto__:null,SVG:Y_}),K_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.axesArrayOffset=r.Offset16,r.uint16,this.axisCount=r.uint16,this.axisSize=r.uint16,this.instanceCount=r.uint16,this.instanceSize=r.uint16;let o=this.tableStart+this.axesArrayOffset;ae(this,"axes",()=>(r.currentPosition=o,[...new Array(this.axisCount)].map(i=>new J_(r))));let n=o+this.axisCount*this.axisSize;ae(this,"instances",()=>{let i=[];for(let s=0;se.tag)}getAxis(e){return this.axes.find(t=>t.tag===e)}},J_=class{constructor(e){this.tag=e.tag,this.minValue=e.fixed,this.defaultValue=e.fixed,this.maxValue=e.fixed,this.flags=e.flags(16),this.axisNameID=e.uint16}},Q_=class{constructor(e,t,r){let o=e.currentPosition;this.subfamilyNameID=e.uint16,e.uint16,this.coordinates=[...new Array(t)].map(n=>e.fixed),e.currentPosition-o[...new Array(o)].map(n=>r.fword))}},tR=Object.freeze({__proto__:null,cvt:eR}),rR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},oR=Object.freeze({__proto__:null,fpgm:rR}),nR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRanges=r.uint16,ae(this,"gaspRanges",()=>[...new Array(this.numRanges)].map(n=>new iR(r)))}},iR=class{constructor(e){this.rangeMaxPPEM=e.uint16,this.rangeGaspBehavior=e.uint16}},sR=Object.freeze({__proto__:null,gasp:nR}),aR=class extends ke{constructor(e,t){super(e,t)}getGlyphData(e,t){return this.parser.currentPosition=this.tableStart+e,this.parser.readBytes(t)}},lR=Object.freeze({__proto__:null,glyf:aR}),cR=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.maxp.numGlyphs+1;r.head.indexToLocFormat===0?(this.x2=!0,ae(this,"offsets",()=>[...new Array(n)].map(i=>o.Offset16))):ae(this,"offsets",()=>[...new Array(n)].map(i=>o.Offset32))}getGlyphDataOffsetAndLength(e){let t=this.offsets[e]*this.x2?2:1,r=this.offsets[e+1]*this.x2?2:1;return{offset:t,length:r-t}}},uR=Object.freeze({__proto__:null,loca:cR}),fR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},dR=Object.freeze({__proto__:null,prep:fR}),pR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},mR=Object.freeze({__proto__:null,CFF:pR}),hR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},gR=Object.freeze({__proto__:null,CFF2:hR}),yR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.defaultVertOriginY=r.int16,this.numVertOriginYMetrics=r.uint16,ae(this,"vertORiginYMetrics",()=>[...new Array(this.numVertOriginYMetrics)].map(o=>new vR(r)))}},vR=class{constructor(e){this.glyphIndex=e.uint16,this.vertOriginY=e.int16}},bR=Object.freeze({__proto__:null,VORG:yR}),wR=class{constructor(e){this.indexSubTableArrayOffset=e.Offset32,this.indexTablesSize=e.uint32,this.numberofIndexSubTables=e.uint32,this.colorRef=e.uint32,this.hori=new fa(e),this.vert=new fa(e),this.startGlyphIndex=e.uint16,this.endGlyphIndex=e.uint16,this.ppemX=e.uint8,this.ppemY=e.uint8,this.bitDepth=e.uint8,this.flags=e.int8}},xR=class{constructor(e){this.hori=new fa(e),this.vert=new fa(e),this.ppemX=e.uint8,this.ppemY=e.uint8,this.substitutePpemX=e.uint8,this.substitutePpemY=e.uint8}},fa=class{constructor(e){this.ascender=e.int8,this.descender=e.int8,this.widthMax=e.uint8,this.caretSlopeNumerator=e.int8,this.caretSlopeDenominator=e.int8,this.caretOffset=e.int8,this.minOriginSB=e.int8,this.minAdvanceSB=e.int8,this.maxBeforeBL=e.int8,this.minAfterBL=e.int8,this.pad1=e.int8,this.pad2=e.int8}},Dy=class extends ke{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.numSizes=o.uint32,ae(this,"bitMapSizes",()=>[...new Array(this.numSizes)].map(n=>new wR(o)))}},SR=Object.freeze({__proto__:null,EBLC:Dy}),By=class extends ke{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16}},CR=Object.freeze({__proto__:null,EBDT:By}),_R=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.numSizes=r.uint32,ae(this,"bitmapScales",()=>[...new Array(this.numSizes)].map(o=>new xR(r)))}},RR=Object.freeze({__proto__:null,EBSC:_R}),ER=class extends Dy{constructor(e,t){super(e,t,"CBLC")}},TR=Object.freeze({__proto__:null,CBLC:ER}),PR=class extends By{constructor(e,t){super(e,t,"CBDT")}},OR=Object.freeze({__proto__:null,CBDT:PR}),kR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.flags=r.flags(16),this.numStrikes=r.uint32,ae(this,"strikeOffsets",()=>[...new Array(this.numStrikes)].map(o=>r.Offset32))}},FR=Object.freeze({__proto__:null,sbix:kR}),AR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numBaseGlyphRecords=r.uint16,this.baseGlyphRecordsOffset=r.Offset32,this.layerRecordsOffset=r.Offset32,this.numLayerRecords=r.uint16}getBaseGlyphRecord(e){let t=this.tableStart+this.baseGlyphRecordsOffset;this.parser.currentPosition=t;let r=new iu(this.parser),o=r.gID,n=this.tableStart+this.layerRecordsOffset-6;this.parser.currentPosition=n;let i=new iu(this.parser),s=i.gID;if(o===e)return r;if(s===e)return i;for(;t!==n;){let a=t+(n-t)/12;this.parser.currentPosition=a;let u=new iu(this.parser),l=u.gID;if(l===e)return u;l>e?n=a:lnew IR(p))}},iu=class{constructor(e){this.gID=e.uint16,this.firstLayerIndex=e.uint16,this.numLayers=e.uint16}},IR=class{constructor(e){this.gID=e.uint16,this.paletteIndex=e.uint16}},LR=Object.freeze({__proto__:null,COLR:AR}),NR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numPaletteEntries=r.uint16;let o=this.numPalettes=r.uint16;this.numColorRecords=r.uint16,this.offsetFirstColorRecord=r.Offset32,this.colorRecordIndices=[...new Array(this.numPalettes)].map(n=>r.uint16),ae(this,"colorRecords",()=>(r.currentPosition=this.tableStart+this.offsetFirstColorRecord,[...new Array(this.numColorRecords)].map(n=>new MR(r)))),this.version===1&&(this.offsetPaletteTypeArray=r.Offset32,this.offsetPaletteLabelArray=r.Offset32,this.offsetPaletteEntryLabelArray=r.Offset32,ae(this,"paletteTypeArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteTypeArray,new VR(r,o))),ae(this,"paletteLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteLabelArray,new DR(r,o))),ae(this,"paletteEntryLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteEntryLabelArray,new BR(r,o))))}},MR=class{constructor(e){this.blue=e.uint8,this.green=e.uint8,this.red=e.uint8,this.alpha=e.uint8}},VR=class{constructor(e,t){this.paletteTypes=[...new Array(t)].map(r=>e.uint32)}},DR=class{constructor(e,t){this.paletteLabels=[...new Array(t)].map(r=>e.uint16)}},BR=class{constructor(e,t){this.paletteEntryLabels=[...new Array(t)].map(r=>e.uint16)}},jR=Object.freeze({__proto__:null,CPAL:NR}),zR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.numSignatures=r.uint16,this.flags=r.uint16,this.signatureRecords=[...new Array(this.numSignatures)].map(o=>new HR(r))}getData(e){let t=this.signatureRecords[e];return this.parser.currentPosition=this.tableStart+t.offset,new UR(this.parser)}},HR=class{constructor(e){this.format=e.uint32,this.length=e.uint32,this.offset=e.Offset32}},UR=class{constructor(e){e.uint16,e.uint16,this.signatureLength=e.uint32,this.signature=e.readBytes(this.signatureLength)}},WR=Object.freeze({__proto__:null,DSIG:zR}),GR=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.hmtx.numGlyphs;this.version=o.uint16,this.numRecords=o.int16,this.sizeDeviceRecord=o.int32,this.records=[...new Array(numRecords)].map(i=>new YR(o,n))}},YR=class{constructor(e,t){this.pixelSize=e.uint8,this.maxWidth=e.uint8,this.widths=e.readBytes(t)}},qR=Object.freeze({__proto__:null,hdmx:GR}),ZR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.nTables=r.uint16,ae(this,"tables",()=>{let o=this.tableStart+4,n=[];for(let i=0;i[...new Array(this.nPairs)].map(t=>new KR(e)))),this.format===2&&console.warn("Kern subtable format 2 is not supported: this parser currently only parses universal table data.")}get horizontal(){return this.coverage[0]}get minimum(){return this.coverage[1]}get crossstream(){return this.coverage[2]}get override(){return this.coverage[3]}},KR=class{constructor(e){this.left=e.uint16,this.right=e.uint16,this.value=e.fword}},JR=Object.freeze({__proto__:null,kern:ZR}),QR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numGlyphs=r.uint16,this.yPels=r.readBytes(this.numGlyphs)}},$R=Object.freeze({__proto__:null,LTSH:QR}),e2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.mergeClassCount=r.uint16,this.mergeDataOffset=r.Offset16,this.classDefCount=r.uint16,this.offsetToClassDefOffsets=r.Offset16,ae(this,"mergeEntryMatrix",()=>[...new Array(this.mergeClassCount)].map(o=>r.readBytes(this.mergeClassCount))),console.warn("Full MERG parsing is currently not supported."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},t2=Object.freeze({__proto__:null,MERG:e2}),r2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.flags=r.uint32,r.uint32,this.dataMapsCount=r.uint32,this.dataMaps=[...new Array(this.dataMapsCount)].map(o=>new o2(this.tableStart,r))}},o2=class{constructor(e,t){this.tableStart=e,this.parser=t,this.tag=t.tag,this.dataOffset=t.Offset32,this.dataLength=t.uint32}getData(){return this.parser.currentField=this.tableStart+this.dataOffset,this.parser.readBytes(this.dataLength)}},n2=Object.freeze({__proto__:null,meta:r2}),i2=class extends ke{constructor(e,t){super(e,t),console.warn("This font uses a PCLT table, which is currently not supported by this parser."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},s2=Object.freeze({__proto__:null,PCLT:i2}),a2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRecs=r.uint16,this.numRatios=r.uint16,this.ratRanges=[...new Array(this.numRatios)].map(o=>new l2(r)),this.offsets=[...new Array(this.numRatios)].map(o=>r.Offset16),this.VDMXGroups=[...new Array(this.numRecs)].map(o=>new c2(r))}},l2=class{constructor(e){this.bCharSet=e.uint8,this.xRatio=e.uint8,this.yStartRatio=e.uint8,this.yEndRatio=e.uint8}},c2=class{constructor(e){this.recs=e.uint16,this.startsz=e.uint8,this.endsz=e.uint8,this.records=[...new Array(this.recs)].map(t=>new u2(e))}},u2=class{constructor(e){this.yPelHeight=e.uint16,this.yMax=e.int16,this.yMin=e.int16}},f2=Object.freeze({__proto__:null,VDMX:a2}),d2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.fixed,this.ascent=this.vertTypoAscender=r.int16,this.descent=this.vertTypoDescender=r.int16,this.lineGap=this.vertTypoLineGap=r.int16,this.advanceHeightMax=r.int16,this.minTopSideBearing=r.int16,this.minBottomSideBearing=r.int16,this.yMaxExtent=r.int16,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.metricDataFormat=r.int16,this.numOfLongVerMetrics=r.uint16,r.verifyLength()}},p2=Object.freeze({__proto__:null,vhea:d2}),m2=class extends ke{constructor(e,t,r){super(e,t);let o=r.vhea.numOfLongVerMetrics,n=r.maxp.numGlyphs,i=p.currentPosition;if(lazy(this,"vMetrics",()=>(p.currentPosition=i,[...new Array(o)].map(s=>new h2(p.uint16,p.int16)))),o(p.currentPosition=s,[...new Array(n-o)].map(a=>p.int16)))}}},h2=class{constructor(e,t){this.advanceHeight=e,this.topSideBearing=t}},g2=Object.freeze({__proto__:null,vmtx:m2});function jy(e){let t=e.reduce((r,o)=>(r[o.fontFamily]||(r[o.fontFamily]={name:o.fontFamily,fontFamily:o.fontFamily,slug:Ks(o.fontFamily.toLowerCase()),fontFace:[]}),r[o.fontFamily].fontFace.push(o),r),{});return Object.values(t)}var Qt=f(Z(),1);function y2(){let{installFonts:e}=(0,_i.useContext)(jt),[t,r]=(0,_i.useState)(!1),[o,n]=(0,_i.useState)(null),i=h=>{a(h)},s=h=>{a(h.target.files)},a=async h=>{if(!h)return;n(null),r(!0);let g=new Set,b=[...h],w=!1,C=b.map(async v=>{if(!await l(v))return w=!0,null;if(g.has(v.name))return null;let k=(((v.name??"").split(".")??[]).pop()??"").toLowerCase();return eu.includes(k)?(g.add(v.name),v):null}),x=(await Promise.all(C)).filter(v=>v!==null);if(x.length>0)u(x);else{let v=w?(0,Vn.__)("Sorry, you are not allowed to upload this file type."):(0,Vn.__)("No fonts found to install.");n({type:"error",message:v}),r(!1)}},u=async h=>{let g=await Promise.all(h.map(async b=>{let w=await m(b);return await Po(w,w.file,"all"),w}));d(g)};async function l(h){let g=new da("Uploaded Font");try{let b=await c(h);return await g.fromDataBuffer(b,"font"),!0}catch{return!1}}async function c(h){return new Promise((g,b)=>{let w=new window.FileReader;w.readAsArrayBuffer(h),w.onload=()=>g(w.result),w.onerror=b})}let m=async h=>{let g=await c(h),b=new da("Uploaded Font");b.fromDataBuffer(g,h.name);let C=(await new Promise(I=>b.onload=I)).detail.font,{name:x}=C.opentype.tables,v=x.get(16)||x.get(1),_=x.get(2).toLowerCase().includes("italic"),k=C.opentype.tables["OS/2"].usWeightClass||"normal",T=!!C.opentype.tables.fvar&&C.opentype.tables.fvar.axes.find(({tag:I})=>I==="wght"),O=T?`${T.minValue} ${T.maxValue}`:null;return{file:h,fontFamily:v,fontStyle:_?"italic":"normal",fontWeight:O||k}},d=async h=>{let g=jy(h);try{await e(g),n({type:"success",message:(0,Vn.__)("Fonts were installed successfully.")})}catch(b){let w=b;n({type:"error",message:w.message,errors:w?.installationErrors})}r(!1)};return(0,Qt.jsxs)("div",{className:"font-library__tabpanel-layout",children:[(0,Qt.jsx)(Ot.DropZone,{onFilesDrop:i}),(0,Qt.jsxs)(Ot.__experimentalVStack,{className:"font-library__local-fonts",justify:"start",children:[o&&(0,Qt.jsxs)(Ot.Notice,{status:o.type,__unstableHTML:!0,onRemove:()=>n(null),children:[o.message,o.errors&&(0,Qt.jsx)("ul",{children:o.errors.map((h,g)=>(0,Qt.jsx)("li",{children:h},g))})]}),t&&(0,Qt.jsx)(Ot.FlexItem,{children:(0,Qt.jsx)("div",{className:"font-library__upload-area",children:(0,Qt.jsx)(Ot.ProgressBar,{})})}),!t&&(0,Qt.jsx)(Ot.FormFileUpload,{accept:eu.map(h=>`.${h}`).join(","),multiple:!0,onChange:s,render:({openFileDialog:h})=>(0,Qt.jsx)(Ot.Button,{__next40pxDefaultSize:!0,className:"font-library__upload-area",onClick:h,children:(0,Vn.__)("Upload font")})}),(0,Qt.jsx)(Ot.__experimentalText,{className:"font-library__upload-area__text",children:(0,Vn.__)("Uploaded fonts appear in your library and can be used in your theme. Supported formats: .ttf, .otf, .woff, and .woff2.")})]})]})}var pa=y2;var Hy=f(Z(),1),{Tabs:WB}=Ve(au.privateApis),GB={id:"installed-fonts",title:(0,ma._x)("Library","Font library")},YB={id:"upload-fonts",title:(0,ma._x)("Upload","noun")};var Uy=f(ge(),1),lu=f(ue(),1),b2=f(Te(),1);var Wy=f(Z(),1);var cu=f(Z(),1);var Gy=f(ge(),1),ha=f(ue(),1);var Yy=f(Z(),1);var fu=f(Z(),1);var wt=f(ge(),1),du=f(ue(),1),T2=f(Te(),1);var qy=f(Dt(),1);var R2=f(Z(),1),{useSettingsForBlockElement:Sj,TypographyPanel:Cj}=Ve(qy.privateApis);var E2=f(Z(),1);var pu=f(Z(),1),Aj={text:{description:(0,wt.__)("Manage the fonts used on the site."),title:(0,wt.__)("Text")},link:{description:(0,wt.__)("Manage the fonts and typography used on the links."),title:(0,wt.__)("Links")},heading:{description:(0,wt.__)("Manage the fonts and typography used on headings."),title:(0,wt.__)("Headings")},caption:{description:(0,wt.__)("Manage the fonts and typography used on captions."),title:(0,wt.__)("Captions")},cite:{description:(0,wt.__)("Manage the fonts and typography used on citations."),title:(0,wt.__)("Citations")},button:{description:(0,wt.__)("Manage the fonts and typography used on buttons."),title:(0,wt.__)("Buttons")},textInput:{description:(0,wt.__)("Manage the fonts and typography used on inputs."),title:(0,wt.__)("Inputs")},select:{description:(0,wt.__)("Manage the fonts and typography used on selects."),title:(0,wt.__)("Selects")}};var ga=f(ge(),1),F2=f(ue(),1),Xy=f(Dt(),1);var Dn=f(ue(),1),Zy=f(ge(),1);var k2=f(Te(),1);var P2=f(ue(),1),O2=f(Z(),1);var mu=f(Z(),1);var hu=f(Z(),1),{useSettingsForBlockElement:Zj,ColorPanel:Xj}=Ve(Xy.privateApis),Kj=[{name:"cite",label:(0,ga.__)("Citations")},{name:"textInput",label:(0,ga.__)("Inputs")},{name:"select",label:(0,ga.__)("Selects")}];var H2=f(ge(),1);var L2=f(yo(),1),gu=f(ue(),1),N2=f(ge(),1);var va=f(ue(),1);var ya=f(ue(),1);var Ky=f(Z(),1);function Jy(){let{paletteColors:e}=Pn();return e.slice(0,4).map(({slug:t,color:r},o)=>(0,Ky.jsx)("div",{style:{flexGrow:1,height:"100%",background:r}},`${t}-${o}`))}var Ei=f(Z(),1),A2={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},I2=({label:e,isFocused:t,withHoverView:r})=>(0,Ei.jsx)(Fn,{label:e,isFocused:t,withHoverView:r,children:({key:o})=>(0,Ei.jsx)(ya.__unstableMotion.div,{variants:A2,style:{height:"100%",overflow:"hidden"},children:(0,Ei.jsx)(ya.__experimentalHStack,{spacing:0,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Ei.jsx)(Jy,{})})},o)}),Qy=I2;var $o=f(Z(),1),$y=["color"];function ba({title:e,gap:t=2}){let r=Hs($y);return r?.length<=1?null:(0,$o.jsxs)(va.__experimentalVStack,{spacing:3,children:[e&&(0,$o.jsx)(Er,{level:3,children:e}),(0,$o.jsx)(va.__experimentalGrid,{gap:t,children:r.map((o,n)=>(0,$o.jsx)(An,{variation:o,isPill:!0,properties:$y,showTooltip:!0,children:()=>(0,$o.jsx)(Qy,{})},n))})]})}var ev=f(Z(),1);var M2=f(yo(),1),tv=f(ue(),1),V2=f(ge(),1);var rv=f(Z(),1);var D2=f(yo(),1),B2=f(Te(),1),j2=f(ue(),1);var z2=f(ge(),1);var ov=f(Z(),1);var yu=f(Z(),1);var W2=f(ge(),1),iv=f(Dt(),1),G2=f(ue(),1);var nv=f(Dt(),1);var U2=f(Z(),1);var{BackgroundPanel:E9}=Ve(nv.privateApis);var vu=f(Z(),1),{useHasBackgroundPanel:I9}=Ve(iv.privateApis);var av=f(ge(),1);var Ti=f(ue(),1),X2=f(ge(),1);var K2=f(Te(),1);var Y2=f(ue(),1),q2=f(ge(),1),Z2=f(Z(),1);var sv=f(Z(),1),{Menu:z9}=Ve(Ti.privateApis);var wu=f(Z(),1);var yr=f(ue(),1),uv=f(ge(),1);var wa=f(Te(),1);var Pi=f(ue(),1);var lv=f(Z(),1),{Menu:tz}=Ve(Pi.privateApis);var $2=f(ue(),1),eE=f(ge(),1),tE=f(Z(),1);var xu=f(ue(),1),rE=f(ge(),1),oE=f(Te(),1);var cv=f(Z(),1);var Su=f(Z(),1);var aE=f(Z(),1);var uE=f(ge(),1),dv=f(Dt(),1);var fv=f(Dt(),1),lE=f(Te(),1);var cE=f(Z(),1),{useSettingsForBlockElement:Ez,DimensionsPanel:Tz}=Ve(fv.privateApis);var Cu=f(Z(),1),{useHasDimensionsPanel:Lz,useSettingsForBlockElement:Nz}=Ve(dv.privateApis);var vv=f(ue(),1),mE=f(ge(),1);var dE=f(ge(),1),pE=f(ue(),1);var pv=f(sr(),1),mv=f(Kt(),1),Sa=f(Te(),1),hv=f(ue(),1),gv=f(ge(),1);var xa=f(Z(),1);function fE({gap:e=2}){let{user:t}=(0,Sa.useContext)(gt),r=t?.styles,n=(0,mv.useSelect)(s=>{let a=s(pv.store).__experimentalGetCurrentThemeGlobalStylesVariations();return Array.isArray(a)?a:void 0},[])?.filter(s=>!yi(s,["color"])&&!yi(s,["typography","spacing"])),i=(0,Sa.useMemo)(()=>[...[{title:(0,gv.__)("Default"),settings:{},styles:{}},...n??[]].map(a=>{let u=a?.styles?.blocks?{...a.styles.blocks}:{};r?.blocks&&Object.keys(r.blocks).forEach(d=>{if(r.blocks?.[d]?.css){let h=u[d]||{},g={css:`${u[d]?.css||""} ${r.blocks?.[d]?.css?.trim()||""}`};u[d]={...h,...g}}});let l=r?.css||a.styles?.css?{css:`${a.styles?.css||""} ${r?.css||""}`}:{},c=Object.keys(u).length>0?{blocks:u}:{},m={...a.styles,...l,...c};return{...a,settings:a.settings??{},styles:m}})],[n,r?.blocks,r?.css]);return!n||n.length<1?null:(0,xa.jsx)(hv.__experimentalGrid,{columns:2,className:"global-styles-ui-style-variations-container",gap:e,children:i.map((s,a)=>(0,xa.jsx)(An,{variation:s,children:u=>(0,xa.jsx)(Wc,{label:s?.title,withHoverView:!0,isFocused:u,variation:s})},a))})}var _u=fE;var yv=f(Z(),1);var Ru=f(Z(),1);var hE=f(ge(),1),gE=f(ue(),1),bv=f(Dt(),1);var Eu=f(Z(),1),{AdvancedPanel:$z}=Ve(bv.privateApis);var Tv=f(ge(),1),Pu=f(ue(),1),Ou=f(Te(),1);var yE=f(Kt(),1),vE=f(sr(),1),wv=f(Te(),1);var Cv=f(ge(),1),Ca=f(ue(),1),_a=f(Sv(),1),bE=f(sr(),1),wE=f(Kt(),1);var _v=f(Qc(),1);var Rv=f(Z(),1),{Badge:i7}=Ve(Ca.privateApis),s7=3600*1e3*24;var Tu=f(ue(),1),Oi=f(ge(),1);var Ev=f(Z(),1);var ku=f(Z(),1);var Pv=f(ge(),1),Ov=f(ue(),1);var kv=f(Z(),1);var Av=f(ge(),1),ki=f(ue(),1),Iv=f(Te(),1);var SE=f(Dt(),1),CE=f(ge(),1);var _E=f(Z(),1);var io=f(ue(),1),Fv=f(Z(),1);var Fu=f(Z(),1);var Iu=f(Z(),1);var Lu=f(Z(),1);function Bn(e){return function({value:r,baseValue:o,onChange:n,...i}){return(0,Lu.jsx)(gi,{value:r,baseValue:o,onChange:n,children:(0,Lu.jsx)(e,{...i})})}}var PE=Bn(_u);var OE=Bn(ba);var kE=Bn(Xs);var jn=f(Z(),1);function Nu({value:e,baseValue:t,onChange:r,activeTab:o="installed-fonts"}){let n;switch(o){case"upload-fonts":n=(0,jn.jsx)(pa,{});break;case"installed-fonts":n=(0,jn.jsx)(na,{});break;default:n=(0,jn.jsx)(sa,{slug:o})}return(0,jn.jsx)(gi,{value:e,baseValue:t,onChange:r,children:(0,jn.jsx)($s,{children:n})})}var Mv=f(li()),{unlock:Mu}=(0,Mv.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/font-list-route");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='8316bac515']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","8316bac515"),e.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-demo{position:relative}.font-library__font-card{border:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-image{transition:opacity var(--wpds-motion-duration-lg,.3s) var(--wpds-motion-easing-subtle,cubic-bezier(.15,0,.15,1))}}.font-library__font-card .font-library__font-variant_demo-image.is-loading{left:0;opacity:0;position:absolute;top:0}.font-library__font-card .font-library__font-variant-demo-skeleton{border-radius:var(--wpds-border-radius-sm,2px);height:24px}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-filter{margin-bottom:12px;padding:0 16px}.global-styles-ui-block-types-search{flex-grow:1}.global-styles-ui-block-types-item-list .global-styles-ui-block-types-item__icon{min-width:24px}.global-styles-ui-block-types-item-list__no-results{padding-top:16px}.global-styles-ui-block-types-item__indicator{background:var(--wp-admin-theme-color);border-radius:50%;flex:none;height:6px;margin-left:auto;width:6px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-duotone-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;max-height:calc(100% - 110px);overflow:auto}.font-library-page:has(.font-library__footer) .font-library-page__tab-panel{max-height:calc(100% - 198px)}')),document.head.appendChild(e)}var Gr=f(Z()),{Tabs:Ra}=Mu(Vv.privateApis),{useGlobalStyles:FE}=Mu(Dv.privateApis);function AE(){let{records:e=[]}=(0,Ea.useEntityRecords)("root","fontCollection",{_fields:"slug,name,description"}),[t,r]=(0,jv.useState)("installed-fonts"),{base:o,user:n,setUser:i,isReady:s}=FE(),a=(0,Bv.useSelect)(l=>l(Ea.store).canUser("create",{kind:"postType",name:"wp_font_family"}),[]);if(!s)return null;let u=[{id:"installed-fonts",title:(0,zn._x)("Library","Font library")}];return a&&(u.push({id:"upload-fonts",title:(0,zn._x)("Upload","noun")}),u.push(...(e||[]).map(({slug:l,name:c})=>({id:l,title:e&&e.length===1&&l==="google-fonts"?(0,zn.__)("Install Fonts"):c})))),(0,Gr.jsx)(gc,{title:(0,zn.__)("Fonts"),className:"font-library-page",children:(0,Gr.jsxs)(Ra,{selectedTabId:t,onSelect:l=>r(l),children:[(0,Gr.jsx)("div",{className:"font-library-page__tablist",children:(0,Gr.jsx)(Ra.TabList,{children:u.map(({id:l,title:c})=>(0,Gr.jsx)(Ra.Tab,{tabId:l,children:c},l))})}),u.map(({id:l})=>(0,Gr.jsx)(Ra.TabPanel,{tabId:l,focusable:!1,className:"font-library-page__tab-panel",children:(0,Gr.jsx)(Nu,{value:n,baseValue:o,onChange:i,activeTab:l})},l))]})})}function IE(){return(0,Gr.jsx)(AE,{})}var LE=IE;export{LE as stage}; +}`,globalThis.document.head.appendChild(n),n}var WS=[0,1,0,0],GS=[79,84,84,79],YS=[119,79,70,70],qS=[119,79,70,50];function ua(e,t){if(e.length===t.length){for(let r=0;r(globalThis.document&&!this.options.skipStyleSheet&&await US(this.name,e,this.options),this.loadFont(e)))()}async loadFont(e,t){fetch(e).then(r=>XS(r)&&r.arrayBuffer()).then(r=>this.fromDataBuffer(r,t||e)).catch(r=>{let o=new ca("error",r,`Failed to load font at ${t||e}`);this.dispatch(o),this.onerror&&this.onerror(o)})}async fromDataBuffer(e,t){this.fontData=new DataView(e);let r=ZS(this.fontData);if(!r)throw new Error(`${t} is either an unsupported font format, or not a font at all.`);await this.parseBasicData(r);let o=new ca("load",{font:this});this.dispatch(o),this.onload&&this.onload(o)}async parseBasicData(e){return zS().then(t=>(e==="SFNT"&&(this.opentype=new FS(this,this.fontData,t)),e==="WOFF"&&(this.opentype=new IS(this,this.fontData,t)),e==="WOFF2"&&(this.opentype=new MS(this,this.fontData,t)),this.opentype))}getGlyphId(e){return this.opentype.tables.cmap.getGlyphId(e)}reverse(e){return this.opentype.tables.cmap.reverse(e)}supports(e){return this.getGlyphId(e)!==0}supportsVariation(e){return this.opentype.tables.cmap.supportsVariation(e)!==!1}measureText(e,t=16){if(this.__unloaded)throw new Error("Cannot measure text: font was unloaded. Please reload before calling measureText()");let r=document.createElement("div");r.textContent=e,r.style.fontFamily=this.name,r.style.fontSize=`${t}px`,r.style.color="transparent",r.style.background="transparent",r.style.top="0",r.style.left="0",r.style.position="absolute",document.body.appendChild(r);let o=r.getBoundingClientRect();document.body.removeChild(r);let n=this.opentype.tables["OS/2"];return o.fontSize=t,o.ascender=n.sTypoAscender,o.descender=n.sTypoDescender,o}unload(){if(this.styleElement.parentNode){this.styleElement.parentNode.removeElement(this.styleElement);let e=new ca("unload",{font:this});this.dispatch(e),this.onunload&&this.onunload(e)}this._unloaded=!0}load(){if(this.__unloaded){delete this.__unloaded,document.head.appendChild(this.styleElement);let e=new ca("load",{font:this});this.dispatch(e),this.onload&&this.onload(e)}}};globalThis.Font=da;var oo=class extends lt{constructor(e,t,r){super(e),this.plaformID=t,this.encodingID=r}},KS=class extends oo{constructor(e,t,r){super(e,t,r),this.format=0,this.length=e.uint16,this.language=e.uint16,this.glyphIdArray=[...new Array(256)].map(o=>e.uint8)}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 0. only supports(id) is implemented.")),0<=e&&e<=255}reverse(e){return console.warn("reverse not implemented for cmap subtable format 0"),{}}getSupportedCharCodes(){return[{start:1,end:256}]}},JS=class extends oo{constructor(e,t,r){super(e,t,r),this.format=2,this.length=e.uint16,this.language=e.uint16,this.subHeaderKeys=[...new Array(256)].map(s=>e.uint16);let o=Math.max(...this.subHeaderKeys),n=e.currentPosition;ae(this,"subHeaders",()=>(e.currentPosition=n,[...new Array(o)].map(s=>new QS(e))));let i=n+o*8;ae(this,"glyphIndexArray",()=>(e.currentPosition=i,[...new Array(o)].map(s=>e.uint16)))}supports(e){e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 2. only supports(id) is implemented."));let t=e&&255,r=e&&65280,o=this.subHeaders[r],n=this.subHeaders[o],i=n.firstCode,s=i+n.entryCount;return i<=t&&t<=s}reverse(e){return console.warn("reverse not implemented for cmap subtable format 2"),{}}getSupportedCharCodes(e=!1){return e?this.subHeaders.map(t=>({firstCode:t.firstCode,lastCode:t.lastCode})):this.subHeaders.map(t=>({start:t.firstCode,end:t.lastCode}))}},QS=class{constructor(e){this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.first+this.entryCount,this.idDelta=e.int16,this.idRangeOffset=e.uint16}},$S=class extends oo{constructor(e,t,r){super(e,t,r),this.format=4,this.length=e.uint16,this.language=e.uint16,this.segCountX2=e.uint16,this.segCount=this.segCountX2/2,this.searchRange=e.uint16,this.entrySelector=e.uint16,this.rangeShift=e.uint16;let o=e.currentPosition;ae(this,"endCode",()=>e.readBytes(this.segCount,o,16));let n=o+2+this.segCountX2;ae(this,"startCode",()=>e.readBytes(this.segCount,n,16));let i=n+this.segCountX2;ae(this,"idDelta",()=>e.readBytes(this.segCount,i,16,!0));let s=i+this.segCountX2;ae(this,"idRangeOffset",()=>e.readBytes(this.segCount,s,16));let a=s+this.segCountX2,u=this.length-(a-this.tableStart);ae(this,"glyphIdArray",()=>e.readBytes(u,a,16)),ae(this,"segments",()=>this.buildSegments(s,a,e))}buildSegments(e,t,r){let o=(n,i)=>{let s=this.startCode[i],a=this.endCode[i],u=this.idDelta[i],l=this.idRangeOffset[i],c=e+2*i,m=[];if(l===0)for(let d=s+u,h=a+u;d<=h;d++)m.push(d);else for(let d=0,h=a-s;d<=h;d++)r.currentPosition=c+l+d*2,m.push(r.uint16);return{startCode:s,endCode:a,idDelta:u,idRangeOffset:l,glyphIDs:m}};return[...new Array(this.segCount)].map(o)}reverse(e){let t=this.segments.find(o=>o.glyphIDs.includes(e));if(!t)return{};let r=t.startCode+t.glyphIDs.indexOf(e);return{code:r,unicode:String.fromCodePoint(r)}}getGlyphId(e){if(e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535)return 0;let t=this.segments.find(r=>r.startCode<=e&&e<=r.endCode);return t?t.glyphIDs[e-t.startCode]:0}supports(e){return this.getGlyphId(e)!==0}getSupportedCharCodes(e=!1){return e?this.segments:this.segments.map(t=>({start:t.startCode,end:t.endCode}))}},e_=class extends oo{constructor(e,t,r){super(e,t,r),this.format=6,this.length=e.uint16,this.language=e.uint16,this.firstCode=e.uint16,this.entryCount=e.uint16,this.lastCode=this.firstCode+this.entryCount-1,ae(this,"glyphIdArray",()=>[...new Array(this.entryCount)].map(n=>e.uint16))}supports(e){if(e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 6. only supports(id) is implemented.")),ethis.firstCode+this.entryCount)return{};let t=e-this.firstCode;return{code:t,unicode:String.fromCodePoint(t)}}reverse(e){let t=this.glyphIdArray.indexOf(e);if(t>-1)return this.firstCode+t}getSupportedCharCodes(e=!1){return e?[{firstCode:this.firstCode,lastCode:this.lastCode}]:[{start:this.firstCode,end:this.lastCode}]}},t_=class extends oo{constructor(e,t,r){super(e,t,r),this.format=8,e.uint16,this.length=e.uint32,this.language=e.uint32,this.is32=[...new Array(8192)].map(n=>e.uint8),this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new r_(e)))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 8. only supports(id) is implemented.")),this.groups.findIndex(t=>t.startcharCode<=e&&e<=t.endcharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 8"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startcharCode,end:t.endcharCode}))}},r_=class{constructor(e){this.startcharCode=e.uint32,this.endcharCode=e.uint32,this.startGlyphID=e.uint32}},o_=class extends oo{constructor(e,t,r){super(e,t,r),this.format=10,e.uint16,this.length=e.uint32,this.language=e.uint32,this.startCharCode=e.uint32,this.numChars=e.uint32,this.endCharCode=this.startCharCode+this.numChars,ae(this,"glyphs",()=>[...new Array(this.numChars)].map(n=>e.uint16))}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 10. only supports(id) is implemented.")),ethis.startCharCode+this.numChars?!1:e-this.startCharCode}reverse(e){return console.warn("reverse not implemented for cmap subtable format 10"),{}}getSupportedCharCodes(e=!1){return e?[{startCharCode:this.startCharCode,endCharCode:this.endCharCode}]:[{start:this.startCharCode,end:this.endCharCode}]}},n_=class extends oo{constructor(e,t,r){super(e,t,r),this.format=12,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32,ae(this,"groups",()=>[...new Array(this.numGroups)].map(n=>new i_(e)))}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),55296<=e&&e<=57343||(e&65534)===65534||(e&65535)===65535?0:this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){for(let t of this.groups){let r=t.startGlyphID;if(r>e)continue;if(r===e)return t.startCharCode;if(r+(t.endCharCode-t.startCharCode)({start:t.startCharCode,end:t.endCharCode}))}},i_=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.startGlyphID=e.uint32}},s_=class extends oo{constructor(e,t,r){super(e,t,r),this.format=13,e.uint16,this.length=e.uint32,this.language=e.uint32,this.numGroups=e.uint32;let o=[...new Array(this.numGroups)].map(n=>new a_(e));ae(this,"groups",o)}supports(e){return e.charCodeAt&&(e=e.charCodeAt(0)),this.groups.findIndex(t=>t.startCharCode<=e&&e<=t.endCharCode)!==-1}reverse(e){return console.warn("reverse not implemented for cmap subtable format 13"),{}}getSupportedCharCodes(e=!1){return e?this.groups:this.groups.map(t=>({start:t.startCharCode,end:t.endCharCode}))}},a_=class{constructor(e){this.startCharCode=e.uint32,this.endCharCode=e.uint32,this.glyphID=e.uint32}},l_=class extends oo{constructor(e,t,r){super(e,t,r),this.subTableStart=e.currentPosition,this.format=14,this.length=e.uint32,this.numVarSelectorRecords=e.uint32,ae(this,"varSelectors",()=>[...new Array(this.numVarSelectorRecords)].map(o=>new c_(e)))}supports(){return console.warn("supports not implemented for cmap subtable format 14"),0}getSupportedCharCodes(){return console.warn("getSupportedCharCodes not implemented for cmap subtable format 14"),[]}reverse(e){return console.warn("reverse not implemented for cmap subtable format 14"),{}}supportsVariation(e){let t=this.varSelector.find(r=>r.varSelector===e);return t||!1}getSupportedVariations(){return this.varSelectors.map(e=>e.varSelector)}},c_=class{constructor(e){this.varSelector=e.uint24,this.defaultUVSOffset=e.Offset32,this.nonDefaultUVSOffset=e.Offset32}};function u_(e,t,r){let o=e.uint16;return o===0?new KS(e,t,r):o===2?new JS(e,t,r):o===4?new $S(e,t,r):o===6?new e_(e,t,r):o===8?new t_(e,t,r):o===10?new o_(e,t,r):o===12?new n_(e,t,r):o===13?new s_(e,t,r):o===14?new l_(e,t,r):{}}var f_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numTables=r.uint16,this.encodingRecords=[...new Array(this.numTables)].map(o=>new d_(r,this.tableStart))}getSubTable(e){return this.encodingRecords[e].table}getSupportedEncodings(){return this.encodingRecords.map(e=>({platformID:e.platformID,encodingId:e.encodingID}))}getSupportedCharCodes(e,t){let r=this.encodingRecords.findIndex(n=>n.platformID===e&&n.encodingID===t);return r===-1?!1:this.getSubTable(r).getSupportedCharCodes()}reverse(e){for(let t=0;t{let n=this.getSubTable(o);return n.getGlyphId?(t=n.getGlyphId(e),t!==0):!1}),t}supports(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supports&&o.supports(e)!==!1})}supportsVariation(e){return this.encodingRecords.some((t,r)=>{let o=this.getSubTable(r);return o.supportsVariation&&o.supportsVariation(e)!==!1})}},d_=class{constructor(e,t){let r=this.platformID=e.uint16,o=this.encodingID=e.uint16,n=this.offset=e.Offset32;ae(this,"table",()=>(e.currentPosition=t+n,u_(e,r,o)))}},p_=Object.freeze({__proto__:null,cmap:f_}),m_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.load({majorVersion:r.uint16,minorVersion:r.uint16,fontRevision:r.fixed,checkSumAdjustment:r.uint32,magicNumber:r.uint32,flags:r.flags(16),unitsPerEm:r.uint16,created:r.longdatetime,modified:r.longdatetime,xMin:r.int16,yMin:r.int16,xMax:r.int16,yMax:r.int16,macStyle:r.flags(16),lowestRecPPEM:r.uint16,fontDirectionHint:r.uint16,indexToLocFormat:r.uint16,glyphDataFormat:r.uint16})}},h_=Object.freeze({__proto__:null,head:m_}),g_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.ascender=r.fword,this.descender=r.fword,this.lineGap=r.fword,this.advanceWidthMax=r.ufword,this.minLeftSideBearing=r.fword,this.minRightSideBearing=r.fword,this.xMaxExtent=r.fword,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,r.int16,r.int16,r.int16,r.int16,this.metricDataFormat=r.int16,this.numberOfHMetrics=r.uint16,r.verifyLength()}},y_=Object.freeze({__proto__:null,hhea:g_}),v_=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.hhea.numberOfHMetrics,i=r.maxp.numGlyphs,s=o.currentPosition;if(ae(this,"hMetrics",()=>(o.currentPosition=s,[...new Array(n)].map(a=>new b_(o.uint16,o.int16)))),n(o.currentPosition=a,[...new Array(i-n)].map(u=>o.int16)))}}},b_=class{constructor(e,t){this.advanceWidth=e,this.lsb=t}},w_=Object.freeze({__proto__:null,hmtx:v_}),x_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.legacyFixed,this.numGlyphs=r.uint16,this.version===1&&(this.maxPoints=r.uint16,this.maxContours=r.uint16,this.maxCompositePoints=r.uint16,this.maxCompositeContours=r.uint16,this.maxZones=r.uint16,this.maxTwilightPoints=r.uint16,this.maxStorage=r.uint16,this.maxFunctionDefs=r.uint16,this.maxInstructionDefs=r.uint16,this.maxStackElements=r.uint16,this.maxSizeOfInstructions=r.uint16,this.maxComponentElements=r.uint16,this.maxComponentDepth=r.uint16),r.verifyLength()}},S_=Object.freeze({__proto__:null,maxp:x_}),__=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.format=r.uint16,this.count=r.uint16,this.stringOffset=r.Offset16,this.nameRecords=[...new Array(this.count)].map(o=>new R_(r,this)),this.format===1&&(this.langTagCount=r.uint16,this.langTagRecords=[...new Array(this.langTagCount)].map(o=>new C_(r.uint16,r.Offset16))),this.stringStart=this.tableStart+this.stringOffset}get(e){let t=this.nameRecords.find(r=>r.nameID===e);if(t)return t.string}},C_=class{constructor(e,t){this.length=e,this.offset=t}},R_=class{constructor(e,t){this.platformID=e.uint16,this.encodingID=e.uint16,this.languageID=e.uint16,this.nameID=e.uint16,this.length=e.uint16,this.offset=e.Offset16,ae(this,"string",()=>(e.currentPosition=t.stringStart+this.offset,E_(e,this)))}};function E_(e,t){let{platformID:r,length:o}=t;if(o===0)return"";if(r===0||r===3){let s=[];for(let a=0,u=o/2;ar.uint8),this.ulUnicodeRange1=r.flags(32),this.ulUnicodeRange2=r.flags(32),this.ulUnicodeRange3=r.flags(32),this.ulUnicodeRange4=r.flags(32),this.achVendID=r.tag,this.fsSelection=r.uint16,this.usFirstCharIndex=r.uint16,this.usLastCharIndex=r.uint16,this.sTypoAscender=r.int16,this.sTypoDescender=r.int16,this.sTypoLineGap=r.int16,this.usWinAscent=r.uint16,this.usWinDescent=r.uint16,this.version===0||(this.ulCodePageRange1=r.flags(32),this.ulCodePageRange2=r.flags(32),this.version===1)||(this.sxHeight=r.int16,this.sCapHeight=r.int16,this.usDefaultChar=r.uint16,this.usBreakChar=r.uint16,this.usMaxContext=r.uint16,this.version<=4)||(this.usLowerOpticalPointSize=r.uint16,this.usUpperOpticalPointSize=r.uint16,this.version===5))return r.verifyLength()}},O_=Object.freeze({__proto__:null,OS2:P_}),k_=class extends ke{constructor(e,t){let{p:r}=super(e,t);if(this.version=r.legacyFixed,this.italicAngle=r.fixed,this.underlinePosition=r.fword,this.underlineThickness=r.fword,this.isFixedPitch=r.uint32,this.minMemType42=r.uint32,this.maxMemType42=r.uint32,this.minMemType1=r.uint32,this.maxMemType1=r.uint32,this.version===1||this.version===3)return r.verifyLength();if(this.numGlyphs=r.uint16,this.version===2){this.glyphNameIndex=[...new Array(this.numGlyphs)].map(o=>r.uint16),this.namesOffset=r.currentPosition,this.glyphNameOffsets=[1];for(let o=0;or.int8))}getGlyphName(e){if(this.version!==2)return console.warn(`post table version ${this.version} does not support glyph name lookups`),"";let t=this.glyphNameIndex[e];if(t<258)return vy[t];let r=this.glyphNameOffsets[e],n=this.glyphNameOffsets[e+1]-r-1;return n===0?".notdef.":(this.parser.currentPosition=this.namesOffset+r,this.parser.readBytes(n,this.namesOffset+r,8,!0).map(s=>String.fromCharCode(s)).join(""))}},vy=[".notdef",".null","nonmarkingreturn","space","exclam","quotedbl","numbersign","dollar","percent","ampersand","quotesingle","parenleft","parenright","asterisk","plus","comma","hyphen","period","slash","zero","one","two","three","four","five","six","seven","eight","nine","colon","semicolon","less","equal","greater","question","at","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","bracketleft","backslash","bracketright","asciicircum","underscore","grave","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","braceleft","bar","braceright","asciitilde","Adieresis","Aring","Ccedilla","Eacute","Ntilde","Odieresis","Udieresis","aacute","agrave","acircumflex","adieresis","atilde","aring","ccedilla","eacute","egrave","ecircumflex","edieresis","iacute","igrave","icircumflex","idieresis","ntilde","oacute","ograve","ocircumflex","odieresis","otilde","uacute","ugrave","ucircumflex","udieresis","dagger","degree","cent","sterling","section","bullet","paragraph","germandbls","registered","copyright","trademark","acute","dieresis","notequal","AE","Oslash","infinity","plusminus","lessequal","greaterequal","yen","mu","partialdiff","summation","product","pi","integral","ordfeminine","ordmasculine","Omega","ae","oslash","questiondown","exclamdown","logicalnot","radical","florin","approxequal","Delta","guillemotleft","guillemotright","ellipsis","nonbreakingspace","Agrave","Atilde","Otilde","OE","oe","endash","emdash","quotedblleft","quotedblright","quoteleft","quoteright","divide","lozenge","ydieresis","Ydieresis","fraction","currency","guilsinglleft","guilsinglright","fi","fl","daggerdbl","periodcentered","quotesinglbase","quotedblbase","perthousand","Acircumflex","Ecircumflex","Aacute","Edieresis","Egrave","Iacute","Icircumflex","Idieresis","Igrave","Oacute","Ocircumflex","apple","Ograve","Uacute","Ucircumflex","Ugrave","dotlessi","circumflex","tilde","macron","breve","dotaccent","ring","cedilla","hungarumlaut","ogonek","caron","Lslash","lslash","Scaron","scaron","Zcaron","zcaron","brokenbar","Eth","eth","Yacute","yacute","Thorn","thorn","minus","multiply","onesuperior","twosuperior","threesuperior","onehalf","onequarter","threequarters","franc","Gbreve","gbreve","Idotaccent","Scedilla","scedilla","Cacute","cacute","Ccaron","ccaron","dcroat"],F_=Object.freeze({__proto__:null,post:k_}),A_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.horizAxisOffset=r.Offset16,this.vertAxisOffset=r.Offset16,ae(this,"horizAxis",()=>new eu({offset:e.offset+this.horizAxisOffset},t)),ae(this,"vertAxis",()=>new eu({offset:e.offset+this.vertAxisOffset},t)),this.majorVersion===1&&this.minorVersion===1&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>new eu({offset:e.offset+this.itemVarStoreOffset},t)))}},eu=class extends ke{constructor(e,t){let{p:r}=super(e,t,"AxisTable");this.baseTagListOffset=r.Offset16,this.baseScriptListOffset=r.Offset16,ae(this,"baseTagList",()=>new I_({offset:e.offset+this.baseTagListOffset},t)),ae(this,"baseScriptList",()=>new L_({offset:e.offset+this.baseScriptListOffset},t))}},I_=class extends ke{constructor(e,t){let{p:r}=super(e,t,"BaseTagListTable");this.baseTagCount=r.uint16,this.baselineTags=[...new Array(this.baseTagCount)].map(o=>r.tag)}},L_=class extends ke{constructor(e,t){let{p:r}=super(e,t,"BaseScriptListTable");this.baseScriptCount=r.uint16;let o=r.currentPosition;ae(this,"baseScriptRecords",()=>(r.currentPosition=o,[...new Array(this.baseScriptCount)].map(n=>new N_(this.start,r))))}},N_=class{constructor(e,t){this.baseScriptTag=t.tag,this.baseScriptOffset=t.Offset16,ae(this,"baseScriptTable",()=>(t.currentPosition=e+this.baseScriptOffset,new M_(t)))}},M_=class{constructor(e){this.start=e.currentPosition,this.baseValuesOffset=e.Offset16,this.defaultMinMaxOffset=e.Offset16,this.baseLangSysCount=e.uint16,this.baseLangSysRecords=[...new Array(this.baseLangSysCount)].map(t=>new V_(this.start,e)),ae(this,"baseValues",()=>(e.currentPosition=this.start+this.baseValuesOffset,new D_(e))),ae(this,"defaultMinMax",()=>(e.currentPosition=this.start+this.defaultMinMaxOffset,new Ey(e)))}},V_=class{constructor(e,t){this.baseLangSysTag=t.tag,this.minMaxOffset=t.Offset16,ae(this,"minMax",()=>(t.currentPosition=e+this.minMaxOffset,new Ey(t)))}},D_=class{constructor(e){this.parser=e,this.start=e.currentPosition,this.defaultBaselineIndex=e.uint16,this.baseCoordCount=e.uint16,this.baseCoords=[...new Array(this.baseCoordCount)].map(t=>e.Offset16)}getTable(e){return this.parser.currentPosition=this.start+this.baseCoords[e],new j_(this.parser)}},Ey=class{constructor(e){this.minCoord=e.Offset16,this.maxCoord=e.Offset16,this.featMinMaxCount=e.uint16;let t=e.currentPosition;ae(this,"featMinMaxRecords",()=>(e.currentPosition=t,[...new Array(this.featMinMaxCount)].map(r=>new B_(e))))}},B_=class{constructor(e){this.featureTableTag=e.tag,this.minCoord=e.Offset16,this.maxCoord=e.Offset16}},j_=class{constructor(e){this.baseCoordFormat=e.uint16,this.coordinate=e.int16,this.baseCoordFormat===2&&(this.referenceGlyph=e.uint16,this.baseCoordPoint=e.uint16),this.baseCoordFormat===3&&(this.deviceTable=e.Offset16)}},z_=Object.freeze({__proto__:null,BASE:A_}),by=class{constructor(e){this.classFormat=e.uint16,this.classFormat===1&&(this.startGlyphID=e.uint16,this.glyphCount=e.uint16,this.classValueArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.classFormat===2&&(this.classRangeCount=e.uint16,this.classRangeRecords=[...new Array(this.classRangeCount)].map(t=>new H_(e)))}},H_=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.class=e.uint16}},_i=class extends lt{constructor(e){super(e),this.coverageFormat=e.uint16,this.coverageFormat===1&&(this.glyphCount=e.uint16,this.glyphArray=[...new Array(this.glyphCount)].map(t=>e.uint16)),this.coverageFormat===2&&(this.rangeCount=e.uint16,this.rangeRecords=[...new Array(this.rangeCount)].map(t=>new U_(e)))}},U_=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.startCoverageIndex=e.uint16}},W_=class{constructor(e,t){this.table=e,this.parser=t,this.start=t.currentPosition,this.format=t.uint16,this.variationRegionListOffset=t.Offset32,this.itemVariationDataCount=t.uint16,this.itemVariationDataOffsets=[...new Array(this.itemVariationDataCount)].map(r=>t.Offset32)}},G_=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.glyphClassDefOffset=r.Offset16,ae(this,"glyphClassDefs",()=>{if(this.glyphClassDefOffset!==0)return r.currentPosition=this.tableStart+this.glyphClassDefOffset,new by(r)}),this.attachListOffset=r.Offset16,ae(this,"attachList",()=>{if(this.attachListOffset!==0)return r.currentPosition=this.tableStart+this.attachListOffset,new Y_(r)}),this.ligCaretListOffset=r.Offset16,ae(this,"ligCaretList",()=>{if(this.ligCaretListOffset!==0)return r.currentPosition=this.tableStart+this.ligCaretListOffset,new Z_(r)}),this.markAttachClassDefOffset=r.Offset16,ae(this,"markAttachClassDef",()=>{if(this.markAttachClassDefOffset!==0)return r.currentPosition=this.tableStart+this.markAttachClassDefOffset,new by(r)}),this.minorVersion>=2&&(this.markGlyphSetsDefOffset=r.Offset16,ae(this,"markGlyphSetsDef",()=>{if(this.markGlyphSetsDefOffset!==0)return r.currentPosition=this.tableStart+this.markGlyphSetsDefOffset,new J_(r)})),this.minorVersion===3&&(this.itemVarStoreOffset=r.Offset32,ae(this,"itemVarStore",()=>{if(this.itemVarStoreOffset!==0)return r.currentPosition=this.tableStart+this.itemVarStoreOffset,new W_(r)}))}},Y_=class extends lt{constructor(e){super(e),this.coverageOffset=e.Offset16,this.glyphCount=e.uint16,this.attachPointOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16)}getPoint(e){return this.parser.currentPosition=this.start+this.attachPointOffsets[e],new q_(this.parser)}},q_=class{constructor(e){this.pointCount=e.uint16,this.pointIndices=[...new Array(this.pointCount)].map(t=>e.uint16)}},Z_=class extends lt{constructor(e){super(e),this.coverageOffset=e.Offset16,ae(this,"coverage",()=>(e.currentPosition=this.start+this.coverageOffset,new _i(e))),this.ligGlyphCount=e.uint16,this.ligGlyphOffsets=[...new Array(this.ligGlyphCount)].map(t=>e.Offset16)}getLigGlyph(e){return this.parser.currentPosition=this.start+this.ligGlyphOffsets[e],new X_(this.parser)}},X_=class extends lt{constructor(e){super(e),this.caretCount=e.uint16,this.caretValueOffsets=[...new Array(this.caretCount)].map(t=>e.Offset16)}getCaretValue(e){return this.parser.currentPosition=this.start+this.caretValueOffsets[e],new K_(this.parser)}},K_=class{constructor(e){this.caretValueFormat=e.uint16,this.caretValueFormat===1&&(this.coordinate=e.int16),this.caretValueFormat===2&&(this.caretValuePointIndex=e.uint16),this.caretValueFormat===3&&(this.coordinate=e.int16,this.deviceOffset=e.Offset16)}},J_=class extends lt{constructor(e){super(e),this.markGlyphSetTableFormat=e.uint16,this.markGlyphSetCount=e.uint16,this.coverageOffsets=[...new Array(this.markGlyphSetCount)].map(t=>e.Offset32)}getMarkGlyphSet(e){return this.parser.currentPosition=this.start+this.coverageOffsets[e],new _i(this.parser)}},Q_=Object.freeze({__proto__:null,GDEF:G_}),wy=class extends lt{static EMPTY={scriptCount:0,scriptRecords:[]};constructor(e){super(e),this.scriptCount=e.uint16,this.scriptRecords=[...new Array(this.scriptCount)].map(t=>new $_(e))}},$_=class{constructor(e){this.scriptTag=e.tag,this.scriptOffset=e.Offset16}},eC=class extends lt{constructor(e){super(e),this.defaultLangSys=e.Offset16,this.langSysCount=e.uint16,this.langSysRecords=[...new Array(this.langSysCount)].map(t=>new tC(e))}},tC=class{constructor(e){this.langSysTag=e.tag,this.langSysOffset=e.Offset16}},xy=class{constructor(e){this.lookupOrder=e.Offset16,this.requiredFeatureIndex=e.uint16,this.featureIndexCount=e.uint16,this.featureIndices=[...new Array(this.featureIndexCount)].map(t=>e.uint16)}},Sy=class extends lt{static EMPTY={featureCount:0,featureRecords:[]};constructor(e){super(e),this.featureCount=e.uint16,this.featureRecords=[...new Array(this.featureCount)].map(t=>new rC(e))}},rC=class{constructor(e){this.featureTag=e.tag,this.featureOffset=e.Offset16}},oC=class extends lt{constructor(e){super(e),this.featureParams=e.Offset16,this.lookupIndexCount=e.uint16,this.lookupListIndices=[...new Array(this.lookupIndexCount)].map(t=>e.uint16)}getFeatureParams(){if(this.featureParams>0){let e=this.parser;e.currentPosition=this.start+this.featureParams;let t=this.featureTag;if(t==="size")return new iC(e);if(t.startsWith("cc"))return new nC(e);if(t.startsWith("ss"))return new sC(e)}}},nC=class{constructor(e){this.format=e.uint16,this.featUiLabelNameId=e.uint16,this.featUiTooltipTextNameId=e.uint16,this.sampleTextNameId=e.uint16,this.numNamedParameters=e.uint16,this.firstParamUiLabelNameId=e.uint16,this.charCount=e.uint16,this.character=[...new Array(this.charCount)].map(t=>e.uint24)}},iC=class{constructor(e){this.designSize=e.uint16,this.subfamilyIdentifier=e.uint16,this.subfamilyNameID=e.uint16,this.smallEnd=e.uint16,this.largeEnd=e.uint16}},sC=class{constructor(e){this.version=e.uint16,this.UINameID=e.uint16}};function Ty(e){e.parser.currentPosition-=2,delete e.coverageOffset,delete e.getCoverageTable}var Qo=class extends lt{constructor(e){super(e),this.substFormat=e.uint16,this.coverageOffset=e.Offset16}getCoverageTable(){let e=this.parser;return e.currentPosition=this.start+this.coverageOffset,new _i(e)}},ru=class{constructor(e){this.glyphSequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},aC=class extends Qo{constructor(e){super(e),this.deltaGlyphID=e.int16}},lC=class extends Qo{constructor(e){super(e),this.sequenceCount=e.uint16,this.sequenceOffsets=[...new Array(this.sequenceCount)].map(t=>e.Offset16)}getSequence(e){let t=this.parser;return t.currentPosition=this.start+this.sequenceOffsets[e],new cC(t)}},cC=class{constructor(e){this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},uC=class extends Qo{constructor(e){super(e),this.alternateSetCount=e.uint16,this.alternateSetOffsets=[...new Array(this.alternateSetCount)].map(t=>e.Offset16)}getAlternateSet(e){let t=this.parser;return t.currentPosition=this.start+this.alternateSetOffsets[e],new fC(t)}},fC=class{constructor(e){this.glyphCount=e.uint16,this.alternateGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},dC=class extends Qo{constructor(e){super(e),this.ligatureSetCount=e.uint16,this.ligatureSetOffsets=[...new Array(this.ligatureSetCount)].map(t=>e.Offset16)}getLigatureSet(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureSetOffsets[e],new pC(t)}},pC=class extends lt{constructor(e){super(e),this.ligatureCount=e.uint16,this.ligatureOffsets=[...new Array(this.ligatureCount)].map(t=>e.Offset16)}getLigature(e){let t=this.parser;return t.currentPosition=this.start+this.ligatureOffsets[e],new mC(t)}},mC=class{constructor(e){this.ligatureGlyph=e.uint16,this.componentCount=e.uint16,this.componentGlyphIDs=[...new Array(this.componentCount-1)].map(t=>e.uint16)}},hC=class extends Qo{constructor(e){super(e),this.substFormat===1&&(this.subRuleSetCount=e.uint16,this.subRuleSetOffsets=[...new Array(this.subRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.classDefOffset=e.Offset16,this.subClassSetCount=e.uint16,this.subClassSetOffsets=[...new Array(this.subClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(Ty(this),this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.coverageOffsets=[...new Array(this.glyphCount)].map(t=>e.Offset16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new ru(e)))}getSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 5.${this.substFormat} has no subrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.subRuleSetOffsets[e],new gC(t)}getSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 5.${this.substFormat} has no subclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.subClassSetOffsets[e],new yC(t)}getCoverageTable(e){if(this.substFormat!==3&&!e)return super.getCoverageTable();if(!e)throw new Error(`lookup type 5.${this.substFormat} requires an coverage table index.`);let t=this.parser;return t.currentPosition=this.start+this.coverageOffsets[e],new _i(t)}},gC=class extends lt{constructor(e){super(e),this.subRuleCount=e.uint16,this.subRuleOffsets=[...new Array(this.subRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.subRuleOffsets[e],new Py(t)}},Py=class{constructor(e){this.glyphCount=e.uint16,this.substitutionCount=e.uint16,this.inputSequence=[...new Array(this.glyphCount-1)].map(t=>e.uint16),this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new ru(e))}},yC=class extends lt{constructor(e){super(e),this.subClassRuleCount=e.uint16,this.subClassRuleOffsets=[...new Array(this.subClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.subClassRuleOffsets[e],new vC(t)}},vC=class extends Py{constructor(e){super(e)}},bC=class extends Qo{constructor(e){super(e),this.substFormat===1&&(this.chainSubRuleSetCount=e.uint16,this.chainSubRuleSetOffsets=[...new Array(this.chainSubRuleSetCount)].map(t=>e.Offset16)),this.substFormat===2&&(this.backtrackClassDefOffset=e.Offset16,this.inputClassDefOffset=e.Offset16,this.lookaheadClassDefOffset=e.Offset16,this.chainSubClassSetCount=e.uint16,this.chainSubClassSetOffsets=[...new Array(this.chainSubClassSetCount)].map(t=>e.Offset16)),this.substFormat===3&&(Ty(this),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.inputGlyphCount=e.uint16,this.inputCoverageOffsets=[...new Array(this.inputGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[...new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.seqLookupCount=e.uint16,this.seqLookupRecords=[...new Array(this.substitutionCount)].map(t=>new Oy(e)))}getChainSubRuleSet(e){if(this.substFormat!==1)throw new Error(`lookup type 6.${this.substFormat} has no chainsubrule sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleSetOffsets[e],new wC(t)}getChainSubClassSet(e){if(this.substFormat!==2)throw new Error(`lookup type 6.${this.substFormat} has no chainsubclass sets.`);let t=this.parser;return t.currentPosition=this.start+this.chainSubClassSetOffsets[e],new SC(t)}getCoverageFromOffset(e){if(this.substFormat!==3)throw new Error(`lookup type 6.${this.substFormat} does not use contextual coverage offsets.`);let t=this.parser;return t.currentPosition=this.start+e,new _i(t)}},wC=class extends lt{constructor(e){super(e),this.chainSubRuleCount=e.uint16,this.chainSubRuleOffsets=[...new Array(this.chainSubRuleCount)].map(t=>e.Offset16)}getSubRule(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new xC(t)}},xC=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.SubstCount)].map(t=>new ru(e))}},SC=class extends lt{constructor(e){super(e),this.chainSubClassRuleCount=e.uint16,this.chainSubClassRuleOffsets=[...new Array(this.chainSubClassRuleCount)].map(t=>e.Offset16)}getSubClass(e){let t=this.parser;return t.currentPosition=this.start+this.chainSubRuleOffsets[e],new _C(t)}},_C=class{constructor(e){this.backtrackGlyphCount=e.uint16,this.backtrackSequence=[...new Array(this.backtrackGlyphCount)].map(t=>e.uint16),this.inputGlyphCount=e.uint16,this.inputSequence=[...new Array(this.inputGlyphCount-1)].map(t=>e.uint16),this.lookaheadGlyphCount=e.uint16,this.lookAheadSequence=[...new Array(this.lookAheadGlyphCount)].map(t=>e.uint16),this.substitutionCount=e.uint16,this.substLookupRecords=[...new Array(this.substitutionCount)].map(t=>new Oy(e))}},Oy=class extends lt{constructor(e){super(e),this.sequenceIndex=e.uint16,this.lookupListIndex=e.uint16}},CC=class extends lt{constructor(e){super(e),this.substFormat=e.uint16,this.extensionLookupType=e.uint16,this.extensionOffset=e.Offset32}},RC=class extends Qo{constructor(e){super(e),this.backtrackGlyphCount=e.uint16,this.backtrackCoverageOffsets=[...new Array(this.backtrackGlyphCount)].map(t=>e.Offset16),this.lookaheadGlyphCount=e.uint16,this.lookaheadCoverageOffsets=[new Array(this.lookaheadGlyphCount)].map(t=>e.Offset16),this.glyphCount=e.uint16,this.substituteGlyphIDs=[...new Array(this.glyphCount)].map(t=>e.uint16)}},EC={buildSubtable:function(e,t){let r=new[void 0,aC,lC,uC,dC,hC,bC,CC,RC][e](t);return r.type=e,r}},no=class extends lt{constructor(e){super(e)}},TC=class extends no{constructor(e){super(e),console.log("lookup type 1")}},PC=class extends no{constructor(e){super(e),console.log("lookup type 2")}},OC=class extends no{constructor(e){super(e),console.log("lookup type 3")}},kC=class extends no{constructor(e){super(e),console.log("lookup type 4")}},FC=class extends no{constructor(e){super(e),console.log("lookup type 5")}},AC=class extends no{constructor(e){super(e),console.log("lookup type 6")}},IC=class extends no{constructor(e){super(e),console.log("lookup type 7")}},LC=class extends no{constructor(e){super(e),console.log("lookup type 8")}},NC=class extends no{constructor(e){super(e),console.log("lookup type 9")}},MC={buildSubtable:function(e,t){let r=new[void 0,TC,PC,OC,kC,FC,AC,IC,LC,NC][e](t);return r.type=e,r}},_y=class extends lt{static EMPTY={lookupCount:0,lookups:[]};constructor(e){super(e),this.lookupCount=e.uint16,this.lookups=[...new Array(this.lookupCount)].map(t=>e.Offset16)}},VC=class extends lt{constructor(e,t){super(e),this.ctType=t,this.lookupType=e.uint16,this.lookupFlag=e.uint16,this.subTableCount=e.uint16,this.subtableOffsets=[...new Array(this.subTableCount)].map(r=>e.Offset16),this.markFilteringSet=e.uint16}get rightToLeft(){return this.lookupFlag&!0}get ignoreBaseGlyphs(){return this.lookupFlag&!0}get ignoreLigatures(){return this.lookupFlag&!0}get ignoreMarks(){return this.lookupFlag&!0}get useMarkFilteringSet(){return this.lookupFlag&!0}get markAttachmentType(){return this.lookupFlag&!0}getSubTable(e){let t=this.ctType==="GSUB"?EC:MC;return this.parser.currentPosition=this.start+this.subtableOffsets[e],t.buildSubtable(this.lookupType,this.parser)}},ky=class extends ke{constructor(e,t,r){let{p:o,tableStart:n}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.scriptListOffset=o.Offset16,this.featureListOffset=o.Offset16,this.lookupListOffset=o.Offset16,this.majorVersion===1&&this.minorVersion===1&&(this.featureVariationsOffset=o.Offset32);let i=!(this.scriptListOffset||this.featureListOffset||this.lookupListOffset);ae(this,"scriptList",()=>i?wy.EMPTY:(o.currentPosition=n+this.scriptListOffset,new wy(o))),ae(this,"featureList",()=>i?Sy.EMPTY:(o.currentPosition=n+this.featureListOffset,new Sy(o))),ae(this,"lookupList",()=>i?_y.EMPTY:(o.currentPosition=n+this.lookupListOffset,new _y(o))),this.featureVariationsOffset&&ae(this,"featureVariations",()=>i?FeatureVariations.EMPTY:(o.currentPosition=n+this.featureVariationsOffset,new FeatureVariations(o)))}getSupportedScripts(){return this.scriptList.scriptRecords.map(e=>e.scriptTag)}getScriptTable(e){let t=this.scriptList.scriptRecords.find(o=>o.scriptTag===e);this.parser.currentPosition=this.scriptList.start+t.scriptOffset;let r=new eC(this.parser);return r.scriptTag=e,r}ensureScriptTable(e){return typeof e=="string"?this.getScriptTable(e):e}getSupportedLangSys(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys!==0,r=e.langSysRecords.map(o=>o.langSysTag);return t&&r.unshift("dflt"),r}getDefaultLangSysTable(e){e=this.ensureScriptTable(e);let t=e.defaultLangSys;if(t!==0){this.parser.currentPosition=e.start+t;let r=new xy(this.parser);return r.langSysTag="",r.defaultForScript=e.scriptTag,r}}getLangSysTable(e,t="dflt"){if(t==="dflt")return this.getDefaultLangSysTable(e);e=this.ensureScriptTable(e);let r=e.langSysRecords.find(n=>n.langSysTag===t);this.parser.currentPosition=e.start+r.langSysOffset;let o=new xy(this.parser);return o.langSysTag=t,o}getFeatures(e){return e.featureIndices.map(t=>this.getFeature(t))}getFeature(e){let t;if(parseInt(e)==e?t=this.featureList.featureRecords[e]:t=this.featureList.featureRecords.find(o=>o.featureTag===e),!t)return;this.parser.currentPosition=this.featureList.start+t.featureOffset;let r=new oC(this.parser);return r.featureTag=t.featureTag,r}getLookups(e){return e.lookupListIndices.map(t=>this.getLookup(t))}getLookup(e,t){let r=this.lookupList.lookups[e];return this.parser.currentPosition=this.lookupList.start+r,new VC(this.parser,t)}},DC=class extends ky{constructor(e,t){super(e,t,"GSUB")}getLookup(e){return super.getLookup(e,"GSUB")}},BC=Object.freeze({__proto__:null,GSUB:DC}),jC=class extends ky{constructor(e,t){super(e,t,"GPOS")}getLookup(e){return super.getLookup(e,"GPOS")}},zC=Object.freeze({__proto__:null,GPOS:jC}),HC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.offsetToSVGDocumentList=r.Offset32,r.currentPosition=this.tableStart+this.offsetToSVGDocumentList,this.documentList=new UC(r)}},UC=class extends lt{constructor(e){super(e),this.numEntries=e.uint16,this.documentRecords=[...new Array(this.numEntries)].map(t=>new WC(e))}getDocument(e){let t=this.documentRecords[e];if(!t)return"";let r=this.start+t.svgDocOffset;return this.parser.currentPosition=r,this.parser.readBytes(t.svgDocLength)}getDocumentForGlyph(e){let t=this.documentRecords.findIndex(r=>r.startGlyphID<=e&&e<=r.endGlyphID);return t===-1?"":this.getDocument(t)}},WC=class{constructor(e){this.startGlyphID=e.uint16,this.endGlyphID=e.uint16,this.svgDocOffset=e.Offset32,this.svgDocLength=e.uint32}},GC=Object.freeze({__proto__:null,SVG:HC}),YC=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.axesArrayOffset=r.Offset16,r.uint16,this.axisCount=r.uint16,this.axisSize=r.uint16,this.instanceCount=r.uint16,this.instanceSize=r.uint16;let o=this.tableStart+this.axesArrayOffset;ae(this,"axes",()=>(r.currentPosition=o,[...new Array(this.axisCount)].map(i=>new qC(r))));let n=o+this.axisCount*this.axisSize;ae(this,"instances",()=>{let i=[];for(let s=0;se.tag)}getAxis(e){return this.axes.find(t=>t.tag===e)}},qC=class{constructor(e){this.tag=e.tag,this.minValue=e.fixed,this.defaultValue=e.fixed,this.maxValue=e.fixed,this.flags=e.flags(16),this.axisNameID=e.uint16}},ZC=class{constructor(e,t,r){let o=e.currentPosition;this.subfamilyNameID=e.uint16,e.uint16,this.coordinates=[...new Array(t)].map(n=>e.fixed),e.currentPosition-o[...new Array(o)].map(n=>r.fword))}},JC=Object.freeze({__proto__:null,cvt:KC}),QC=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},$C=Object.freeze({__proto__:null,fpgm:QC}),eR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRanges=r.uint16,ae(this,"gaspRanges",()=>[...new Array(this.numRanges)].map(n=>new tR(r)))}},tR=class{constructor(e){this.rangeMaxPPEM=e.uint16,this.rangeGaspBehavior=e.uint16}},rR=Object.freeze({__proto__:null,gasp:eR}),oR=class extends ke{constructor(e,t){super(e,t)}getGlyphData(e,t){return this.parser.currentPosition=this.tableStart+e,this.parser.readBytes(t)}},nR=Object.freeze({__proto__:null,glyf:oR}),iR=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.maxp.numGlyphs+1;r.head.indexToLocFormat===0?(this.x2=!0,ae(this,"offsets",()=>[...new Array(n)].map(i=>o.Offset16))):ae(this,"offsets",()=>[...new Array(n)].map(i=>o.Offset32))}getGlyphDataOffsetAndLength(e){let t=this.offsets[e]*this.x2?2:1,r=this.offsets[e+1]*this.x2?2:1;return{offset:t,length:r-t}}},sR=Object.freeze({__proto__:null,loca:iR}),aR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"instructions",()=>[...new Array(e.length)].map(o=>r.uint8))}},lR=Object.freeze({__proto__:null,prep:aR}),cR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},uR=Object.freeze({__proto__:null,CFF:cR}),fR=class extends ke{constructor(e,t){let{p:r}=super(e,t);ae(this,"data",()=>r.readBytes())}},dR=Object.freeze({__proto__:null,CFF2:fR}),pR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.defaultVertOriginY=r.int16,this.numVertOriginYMetrics=r.uint16,ae(this,"vertORiginYMetrics",()=>[...new Array(this.numVertOriginYMetrics)].map(o=>new mR(r)))}},mR=class{constructor(e){this.glyphIndex=e.uint16,this.vertOriginY=e.int16}},hR=Object.freeze({__proto__:null,VORG:pR}),gR=class{constructor(e){this.indexSubTableArrayOffset=e.Offset32,this.indexTablesSize=e.uint32,this.numberofIndexSubTables=e.uint32,this.colorRef=e.uint32,this.hori=new fa(e),this.vert=new fa(e),this.startGlyphIndex=e.uint16,this.endGlyphIndex=e.uint16,this.ppemX=e.uint8,this.ppemY=e.uint8,this.bitDepth=e.uint8,this.flags=e.int8}},yR=class{constructor(e){this.hori=new fa(e),this.vert=new fa(e),this.ppemX=e.uint8,this.ppemY=e.uint8,this.substitutePpemX=e.uint8,this.substitutePpemY=e.uint8}},fa=class{constructor(e){this.ascender=e.int8,this.descender=e.int8,this.widthMax=e.uint8,this.caretSlopeNumerator=e.int8,this.caretSlopeDenominator=e.int8,this.caretOffset=e.int8,this.minOriginSB=e.int8,this.minAdvanceSB=e.int8,this.maxBeforeBL=e.int8,this.minAfterBL=e.int8,this.pad1=e.int8,this.pad2=e.int8}},Fy=class extends ke{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16,this.numSizes=o.uint32,ae(this,"bitMapSizes",()=>[...new Array(this.numSizes)].map(n=>new gR(o)))}},vR=Object.freeze({__proto__:null,EBLC:Fy}),Ay=class extends ke{constructor(e,t,r){let{p:o}=super(e,t,r);this.majorVersion=o.uint16,this.minorVersion=o.uint16}},bR=Object.freeze({__proto__:null,EBDT:Ay}),wR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.majorVersion=r.uint16,this.minorVersion=r.uint16,this.numSizes=r.uint32,ae(this,"bitmapScales",()=>[...new Array(this.numSizes)].map(o=>new yR(r)))}},xR=Object.freeze({__proto__:null,EBSC:wR}),SR=class extends Fy{constructor(e,t){super(e,t,"CBLC")}},_R=Object.freeze({__proto__:null,CBLC:SR}),CR=class extends Ay{constructor(e,t){super(e,t,"CBDT")}},RR=Object.freeze({__proto__:null,CBDT:CR}),ER=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.flags=r.flags(16),this.numStrikes=r.uint32,ae(this,"strikeOffsets",()=>[...new Array(this.numStrikes)].map(o=>r.Offset32))}},TR=Object.freeze({__proto__:null,sbix:ER}),PR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numBaseGlyphRecords=r.uint16,this.baseGlyphRecordsOffset=r.Offset32,this.layerRecordsOffset=r.Offset32,this.numLayerRecords=r.uint16}getBaseGlyphRecord(e){let t=this.tableStart+this.baseGlyphRecordsOffset;this.parser.currentPosition=t;let r=new tu(this.parser),o=r.gID,n=this.tableStart+this.layerRecordsOffset-6;this.parser.currentPosition=n;let i=new tu(this.parser),s=i.gID;if(o===e)return r;if(s===e)return i;for(;t!==n;){let a=t+(n-t)/12;this.parser.currentPosition=a;let u=new tu(this.parser),l=u.gID;if(l===e)return u;l>e?n=a:lnew OR(p))}},tu=class{constructor(e){this.gID=e.uint16,this.firstLayerIndex=e.uint16,this.numLayers=e.uint16}},OR=class{constructor(e){this.gID=e.uint16,this.paletteIndex=e.uint16}},kR=Object.freeze({__proto__:null,COLR:PR}),FR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numPaletteEntries=r.uint16;let o=this.numPalettes=r.uint16;this.numColorRecords=r.uint16,this.offsetFirstColorRecord=r.Offset32,this.colorRecordIndices=[...new Array(this.numPalettes)].map(n=>r.uint16),ae(this,"colorRecords",()=>(r.currentPosition=this.tableStart+this.offsetFirstColorRecord,[...new Array(this.numColorRecords)].map(n=>new AR(r)))),this.version===1&&(this.offsetPaletteTypeArray=r.Offset32,this.offsetPaletteLabelArray=r.Offset32,this.offsetPaletteEntryLabelArray=r.Offset32,ae(this,"paletteTypeArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteTypeArray,new IR(r,o))),ae(this,"paletteLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteLabelArray,new LR(r,o))),ae(this,"paletteEntryLabelArray",()=>(r.currentPosition=this.tableStart+this.offsetPaletteEntryLabelArray,new NR(r,o))))}},AR=class{constructor(e){this.blue=e.uint8,this.green=e.uint8,this.red=e.uint8,this.alpha=e.uint8}},IR=class{constructor(e,t){this.paletteTypes=[...new Array(t)].map(r=>e.uint32)}},LR=class{constructor(e,t){this.paletteLabels=[...new Array(t)].map(r=>e.uint16)}},NR=class{constructor(e,t){this.paletteEntryLabels=[...new Array(t)].map(r=>e.uint16)}},MR=Object.freeze({__proto__:null,CPAL:FR}),VR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.numSignatures=r.uint16,this.flags=r.uint16,this.signatureRecords=[...new Array(this.numSignatures)].map(o=>new DR(r))}getData(e){let t=this.signatureRecords[e];return this.parser.currentPosition=this.tableStart+t.offset,new BR(this.parser)}},DR=class{constructor(e){this.format=e.uint32,this.length=e.uint32,this.offset=e.Offset32}},BR=class{constructor(e){e.uint16,e.uint16,this.signatureLength=e.uint32,this.signature=e.readBytes(this.signatureLength)}},jR=Object.freeze({__proto__:null,DSIG:VR}),zR=class extends ke{constructor(e,t,r){let{p:o}=super(e,t),n=r.hmtx.numGlyphs;this.version=o.uint16,this.numRecords=o.int16,this.sizeDeviceRecord=o.int32,this.records=[...new Array(numRecords)].map(i=>new HR(o,n))}},HR=class{constructor(e,t){this.pixelSize=e.uint8,this.maxWidth=e.uint8,this.widths=e.readBytes(t)}},UR=Object.freeze({__proto__:null,hdmx:zR}),WR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.nTables=r.uint16,ae(this,"tables",()=>{let o=this.tableStart+4,n=[];for(let i=0;i[...new Array(this.nPairs)].map(t=>new YR(e)))),this.format===2&&console.warn("Kern subtable format 2 is not supported: this parser currently only parses universal table data.")}get horizontal(){return this.coverage[0]}get minimum(){return this.coverage[1]}get crossstream(){return this.coverage[2]}get override(){return this.coverage[3]}},YR=class{constructor(e){this.left=e.uint16,this.right=e.uint16,this.value=e.fword}},qR=Object.freeze({__proto__:null,kern:WR}),ZR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numGlyphs=r.uint16,this.yPels=r.readBytes(this.numGlyphs)}},XR=Object.freeze({__proto__:null,LTSH:ZR}),KR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.mergeClassCount=r.uint16,this.mergeDataOffset=r.Offset16,this.classDefCount=r.uint16,this.offsetToClassDefOffsets=r.Offset16,ae(this,"mergeEntryMatrix",()=>[...new Array(this.mergeClassCount)].map(o=>r.readBytes(this.mergeClassCount))),console.warn("Full MERG parsing is currently not supported."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},JR=Object.freeze({__proto__:null,MERG:KR}),QR=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint32,this.flags=r.uint32,r.uint32,this.dataMapsCount=r.uint32,this.dataMaps=[...new Array(this.dataMapsCount)].map(o=>new $R(this.tableStart,r))}},$R=class{constructor(e,t){this.tableStart=e,this.parser=t,this.tag=t.tag,this.dataOffset=t.Offset32,this.dataLength=t.uint32}getData(){return this.parser.currentField=this.tableStart+this.dataOffset,this.parser.readBytes(this.dataLength)}},e2=Object.freeze({__proto__:null,meta:QR}),t2=class extends ke{constructor(e,t){super(e,t),console.warn("This font uses a PCLT table, which is currently not supported by this parser."),console.warn("If you need this table parsed, please file an issue, or better yet, a PR.")}},r2=Object.freeze({__proto__:null,PCLT:t2}),o2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.uint16,this.numRecs=r.uint16,this.numRatios=r.uint16,this.ratRanges=[...new Array(this.numRatios)].map(o=>new n2(r)),this.offsets=[...new Array(this.numRatios)].map(o=>r.Offset16),this.VDMXGroups=[...new Array(this.numRecs)].map(o=>new i2(r))}},n2=class{constructor(e){this.bCharSet=e.uint8,this.xRatio=e.uint8,this.yStartRatio=e.uint8,this.yEndRatio=e.uint8}},i2=class{constructor(e){this.recs=e.uint16,this.startsz=e.uint8,this.endsz=e.uint8,this.records=[...new Array(this.recs)].map(t=>new s2(e))}},s2=class{constructor(e){this.yPelHeight=e.uint16,this.yMax=e.int16,this.yMin=e.int16}},a2=Object.freeze({__proto__:null,VDMX:o2}),l2=class extends ke{constructor(e,t){let{p:r}=super(e,t);this.version=r.fixed,this.ascent=this.vertTypoAscender=r.int16,this.descent=this.vertTypoDescender=r.int16,this.lineGap=this.vertTypoLineGap=r.int16,this.advanceHeightMax=r.int16,this.minTopSideBearing=r.int16,this.minBottomSideBearing=r.int16,this.yMaxExtent=r.int16,this.caretSlopeRise=r.int16,this.caretSlopeRun=r.int16,this.caretOffset=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.reserved=r.int16,this.metricDataFormat=r.int16,this.numOfLongVerMetrics=r.uint16,r.verifyLength()}},c2=Object.freeze({__proto__:null,vhea:l2}),u2=class extends ke{constructor(e,t,r){super(e,t);let o=r.vhea.numOfLongVerMetrics,n=r.maxp.numGlyphs,i=p.currentPosition;if(lazy(this,"vMetrics",()=>(p.currentPosition=i,[...new Array(o)].map(s=>new f2(p.uint16,p.int16)))),o(p.currentPosition=s,[...new Array(n-o)].map(a=>p.int16)))}}},f2=class{constructor(e,t){this.advanceHeight=e,this.topSideBearing=t}},d2=Object.freeze({__proto__:null,vmtx:u2});function Iy(e){let t=e.reduce((r,o)=>(r[o.fontFamily]||(r[o.fontFamily]={name:o.fontFamily,fontFamily:o.fontFamily,slug:Ks(o.fontFamily.toLowerCase()),fontFace:[]}),r[o.fontFamily].fontFace.push(o),r),{});return Object.values(t)}var Qt=f(Z(),1);function p2(){let{installFonts:e}=(0,Ci.useContext)(jt),[t,r]=(0,Ci.useState)(!1),[o,n]=(0,Ci.useState)(null),i=h=>{a(h)},s=h=>{a(h.target.files)},a=async h=>{if(!h)return;n(null),r(!0);let g=new Set,b=[...h],w=!1,_=b.map(async v=>{if(!await l(v))return w=!0,null;if(g.has(v.name))return null;let k=(((v.name??"").split(".")??[]).pop()??"").toLowerCase();return Kc.includes(k)?(g.add(v.name),v):null}),x=(await Promise.all(_)).filter(v=>v!==null);if(x.length>0)u(x);else{let v=w?(0,Vn.__)("Sorry, you are not allowed to upload this file type."):(0,Vn.__)("No fonts found to install.");n({type:"error",message:v}),r(!1)}},u=async h=>{let g=await Promise.all(h.map(async b=>{let w=await m(b);return await Po(w,w.file,"all"),w}));d(g)};async function l(h){let g=new da("Uploaded Font");try{let b=await c(h);return await g.fromDataBuffer(b,"font"),!0}catch{return!1}}async function c(h){return new Promise((g,b)=>{let w=new window.FileReader;w.readAsArrayBuffer(h),w.onload=()=>g(w.result),w.onerror=b})}let m=async h=>{let g=await c(h),b=new da("Uploaded Font");b.fromDataBuffer(g,h.name);let _=(await new Promise(I=>b.onload=I)).detail.font,{name:x}=_.opentype.tables,v=x.get(16)||x.get(1),C=x.get(2).toLowerCase().includes("italic"),k=_.opentype.tables["OS/2"].usWeightClass||"normal",T=!!_.opentype.tables.fvar&&_.opentype.tables.fvar.axes.find(({tag:I})=>I==="wght"),O=T?`${T.minValue} ${T.maxValue}`:null;return{file:h,fontFamily:v,fontStyle:C?"italic":"normal",fontWeight:O||k}},d=async h=>{let g=Iy(h);try{await e(g),n({type:"success",message:(0,Vn.__)("Fonts were installed successfully.")})}catch(b){let w=b;n({type:"error",message:w.message,errors:w?.installationErrors})}r(!1)};return(0,Qt.jsxs)("div",{className:"font-library__tabpanel-layout",children:[(0,Qt.jsx)(Ot.DropZone,{onFilesDrop:i}),(0,Qt.jsxs)(Ot.__experimentalVStack,{className:"font-library__local-fonts",justify:"start",children:[o&&(0,Qt.jsxs)(Ot.Notice,{status:o.type,__unstableHTML:!0,onRemove:()=>n(null),children:[o.message,o.errors&&(0,Qt.jsx)("ul",{children:o.errors.map((h,g)=>(0,Qt.jsx)("li",{children:h},g))})]}),t&&(0,Qt.jsx)(Ot.FlexItem,{children:(0,Qt.jsx)("div",{className:"font-library__upload-area",children:(0,Qt.jsx)(Ot.ProgressBar,{})})}),!t&&(0,Qt.jsx)(Ot.FormFileUpload,{accept:Kc.map(h=>`.${h}`).join(","),multiple:!0,onChange:s,render:({openFileDialog:h})=>(0,Qt.jsx)(Ot.Button,{__next40pxDefaultSize:!0,className:"font-library__upload-area",onClick:h,children:(0,Vn.__)("Upload font")})}),(0,Qt.jsx)(Ot.__experimentalText,{className:"font-library__upload-area__text",children:(0,Vn.__)("Uploaded fonts appear in your library and can be used in your theme. Supported formats: .ttf, .otf, .woff, and .woff2.")})]})]})}var pa=p2;var Ny=f(Z(),1),{Tabs:VB}=De(ou.privateApis),DB={id:"installed-fonts",title:(0,ma._x)("Library","Font library")},BB={id:"upload-fonts",title:(0,ma._x)("Upload","noun")};var My=f(ge(),1),nu=f(ue(),1),h2=f(Te(),1);var Vy=f(Z(),1);var iu=f(Z(),1);var Dy=f(ge(),1),ha=f(ue(),1);var By=f(Z(),1);var au=f(Z(),1);var wt=f(ge(),1),lu=f(ue(),1),_2=f(Te(),1);var jy=f(Dt(),1);var x2=f(Z(),1),{useSettingsForBlockElement:hj,TypographyPanel:gj}=De(jy.privateApis);var S2=f(Z(),1);var cu=f(Z(),1),Rj={text:{description:(0,wt.__)("Manage the fonts used on the site."),title:(0,wt.__)("Text")},link:{description:(0,wt.__)("Manage the fonts and typography used on the links."),title:(0,wt.__)("Links")},heading:{description:(0,wt.__)("Manage the fonts and typography used on headings."),title:(0,wt.__)("Headings")},caption:{description:(0,wt.__)("Manage the fonts and typography used on captions."),title:(0,wt.__)("Captions")},cite:{description:(0,wt.__)("Manage the fonts and typography used on citations."),title:(0,wt.__)("Citations")},button:{description:(0,wt.__)("Manage the fonts and typography used on buttons."),title:(0,wt.__)("Buttons")},textInput:{description:(0,wt.__)("Manage the fonts and typography used on inputs."),title:(0,wt.__)("Inputs")},select:{description:(0,wt.__)("Manage the fonts and typography used on selects."),title:(0,wt.__)("Selects")}};var ga=f(ge(),1),T2=f(ue(),1),Hy=f(Dt(),1);var Dn=f(ue(),1),zy=f(ge(),1);var E2=f(Te(),1);var C2=f(ue(),1),R2=f(Z(),1);var uu=f(Z(),1);var fu=f(Z(),1),{useSettingsForBlockElement:zj,ColorPanel:Hj}=De(Hy.privateApis),Uj=[{name:"cite",label:(0,ga.__)("Citations")},{name:"textInput",label:(0,ga.__)("Inputs")},{name:"select",label:(0,ga.__)("Selects")}];var D2=f(ge(),1);var k2=f(yo(),1),qy=f(ue(),1),F2=f(ge(),1);var va=f(ue(),1);var ya=f(ue(),1);var Uy=f(Z(),1);function Wy(){let{paletteColors:e}=Pn();return e.slice(0,4).map(({slug:t,color:r},o)=>(0,Uy.jsx)("div",{style:{flexGrow:1,height:"100%",background:r}},`${t}-${o}`))}var Ei=f(Z(),1),P2={start:{scale:1,opacity:1},hover:{scale:0,opacity:0}},O2=({label:e,isFocused:t,withHoverView:r})=>(0,Ei.jsx)(Fn,{label:e,isFocused:t,withHoverView:r,children:({key:o})=>(0,Ei.jsx)(ya.__unstableMotion.div,{variants:P2,style:{height:"100%",overflow:"hidden"},children:(0,Ei.jsx)(ya.__experimentalHStack,{spacing:0,justify:"center",style:{height:"100%",overflow:"hidden"},children:(0,Ei.jsx)(Wy,{})})},o)}),Gy=O2;var $o=f(Z(),1),Yy=["color"];function ba({title:e,gap:t=2}){let r=Hs(Yy);return r?.length<=1?null:(0,$o.jsxs)(va.__experimentalVStack,{spacing:3,children:[e&&(0,$o.jsx)(Er,{level:3,children:e}),(0,$o.jsx)(va.__experimentalGrid,{gap:t,children:r.map((o,n)=>(0,$o.jsx)(An,{variation:o,isPill:!0,properties:Yy,showTooltip:!0,children:()=>(0,$o.jsx)(Gy,{})},n))})]})}var Zy=f(Z(),1);var A2=f(yo(),1),Xy=f(ue(),1),I2=f(ge(),1);var Ky=f(Z(),1);var L2=f(yo(),1),N2=f(Te(),1),M2=f(ue(),1);var V2=f(ge(),1);var Jy=f(Z(),1);var du=f(Z(),1);var j2=f(ge(),1),$y=f(Dt(),1),z2=f(ue(),1);var Qy=f(Dt(),1);var B2=f(Z(),1);var{BackgroundPanel:v7}=De(Qy.privateApis);var pu=f(Z(),1),{useHasBackgroundPanel:R7}=De($y.privateApis);var tv=f(ge(),1);var Ti=f(ue(),1),G2=f(ge(),1);var Y2=f(Te(),1);var H2=f(ue(),1),U2=f(ge(),1),W2=f(Z(),1);var ev=f(Z(),1),{Menu:I7}=De(Ti.privateApis);var hu=f(Z(),1);var gr=f(ue(),1),nv=f(ge(),1);var wa=f(Te(),1);var Pi=f(ue(),1);var rv=f(Z(),1),{Menu:q7}=De(Pi.privateApis);var X2=f(ue(),1),K2=f(ge(),1),J2=f(Z(),1);var gu=f(ue(),1),Q2=f(ge(),1),$2=f(Te(),1);var ov=f(Z(),1);var yu=f(Z(),1);var oE=f(Z(),1);var sE=f(ge(),1),sv=f(Dt(),1);var iv=f(Dt(),1),nE=f(Te(),1);var iE=f(Z(),1),{useSettingsForBlockElement:v9,DimensionsPanel:b9}=De(iv.privateApis);var vu=f(Z(),1),{useHasDimensionsPanel:E9,useSettingsForBlockElement:T9}=De(sv.privateApis);var dv=f(ue(),1),uE=f(ge(),1);var lE=f(ge(),1),cE=f(ue(),1);var av=f(sr(),1),lv=f(Kt(),1),Sa=f(Te(),1),cv=f(ue(),1),uv=f(ge(),1);var xa=f(Z(),1);function aE({gap:e=2}){let{user:t}=(0,Sa.useContext)(gt),r=t?.styles,n=(0,lv.useSelect)(s=>{let a=s(av.store).__experimentalGetCurrentThemeGlobalStylesVariations();return Array.isArray(a)?a:void 0},[])?.filter(s=>!yi(s,["color"])&&!yi(s,["typography","spacing"])),i=(0,Sa.useMemo)(()=>[...[{title:(0,uv.__)("Default"),settings:{},styles:{}},...n??[]].map(a=>{let u=a?.styles?.blocks?{...a.styles.blocks}:{};r?.blocks&&Object.keys(r.blocks).forEach(d=>{if(r.blocks?.[d]?.css){let h=u[d]||{},g={css:`${u[d]?.css||""} ${r.blocks?.[d]?.css?.trim()||""}`};u[d]={...h,...g}}});let l=r?.css||a.styles?.css?{css:`${a.styles?.css||""} ${r?.css||""}`}:{},c=Object.keys(u).length>0?{blocks:u}:{},m={...a.styles,...l,...c};return{...a,settings:a.settings??{},styles:m}})],[n,r?.blocks,r?.css]);return!n||n.length<1?null:(0,xa.jsx)(cv.__experimentalGrid,{columns:2,className:"global-styles-ui-style-variations-container",gap:e,children:i.map((s,a)=>(0,xa.jsx)(An,{variation:s,children:u=>(0,xa.jsx)(jc,{label:s?.title,withHoverView:!0,isFocused:u,variation:s})},a))})}var bu=aE;var fv=f(Z(),1);var wu=f(Z(),1);var fE=f(ge(),1),dE=f(ue(),1),pv=f(Dt(),1);var xu=f(Z(),1),{AdvancedPanel:G9}=De(pv.privateApis);var Sv=f(ge(),1),_u=f(ue(),1),Cu=f(Te(),1);var pE=f(Kt(),1),mE=f(sr(),1),mv=f(Te(),1);var yv=f(ge(),1),vv=f(ue(),1),_a=f(gv(),1),hE=f(sr(),1),gE=f(Kt(),1);var bv=f(Zc(),1);var wv=f(Z(),1),K9=3600*1e3*24;var Su=f(ue(),1),Oi=f(ge(),1);var xv=f(Z(),1);var Ru=f(Z(),1);var _v=f(ge(),1),Cv=f(ue(),1);var Rv=f(Z(),1);var Tv=f(ge(),1),ki=f(ue(),1),Pv=f(Te(),1);var vE=f(Dt(),1),bE=f(ge(),1);var wE=f(Z(),1);var io=f(ue(),1),Ev=f(Z(),1);var Eu=f(Z(),1);var Pu=f(Z(),1);var Ou=f(Z(),1);function Bn(e){return function({value:r,baseValue:o,onChange:n,...i}){return(0,Ou.jsx)(gi,{value:r,baseValue:o,onChange:n,children:(0,Ou.jsx)(e,{...i})})}}var CE=Bn(bu);var RE=Bn(ba);var EE=Bn(Xs);var jn=f(Z(),1);function ku({value:e,baseValue:t,onChange:r,activeTab:o="installed-fonts"}){let n;switch(o){case"upload-fonts":n=(0,jn.jsx)(pa,{});break;case"installed-fonts":n=(0,jn.jsx)(na,{});break;default:n=(0,jn.jsx)(sa,{slug:o})}return(0,jn.jsx)(gi,{value:e,baseValue:t,onChange:r,children:(0,jn.jsx)($s,{children:n})})}var Fv=f(ai()),{unlock:Fu}=(0,Fv.__dangerousOptInToUnstableAPIsOnlyForCoreModules)("I acknowledge private features are not for use in themes or plugins and doing so will break in the next version of WordPress.","@wordpress/font-list-route");if(typeof document<"u"&&!document.head.querySelector("style[data-wp-hash='cb0e994672']")){let e=document.createElement("style");e.setAttribute("data-wp-hash","cb0e994672"),e.appendChild(document.createTextNode('@media (min-width:782px){.font-library-modal.font-library-modal{width:65vw}}.font-library-modal .components-modal__header{border-bottom:none}.font-library-modal .components-modal__content{margin-bottom:90px;padding:0}.font-library-modal .font-library__subtitle{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.font-library-modal__tab-panel{height:calc(100% - 50px)}.font-library__tabpanel-layout{display:flex;flex-direction:column;height:100%}.font-library__tabpanel-layout>div{flex-grow:1}.font-library__tabpanel-layout .font-library__loading{align-items:center;box-sizing:border-box;display:flex;height:100%;justify-content:center;left:0;padding-top:124px;position:absolute;top:0;width:100%}.font-library__footer,.font-library__tabpanel-layout .components-navigator-screen{padding:24px;width:100%}.font-library__footer{background-color:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;flex-grow:0!important;flex-shrink:0;height:90px;position:absolute}.font-library__page-selection{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}@media (min-width:600px){.font-library__page-selection .components-select-control__input{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)}}.font-library__search{width:240px}.font-library__fonts-title{font-size:11px;font-weight:var(--wpds-typography-font-weight-emphasis,600);margin-bottom:0;margin-top:0;text-transform:uppercase}.font-library__fonts-list{list-style:none;margin-bottom:0;margin-top:0;padding:0}.font-library__fonts-list-item{margin-bottom:0}.font-library__font-demo{position:relative}.font-library__font-card{border:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);box-sizing:border-box;height:auto!important;margin-top:-1px;padding:16px;width:100%}.font-library__font-card:hover{background-color:#f0f0f0}.font-library__font-card:focus{position:relative}.font-library__font-card .font-library__font-card__name{font-weight:700}.font-library__font-card .font-library__font-card__count{color:#757575}.font-library__font-card .font-library__font-variant_demo-image{display:block;height:24px;width:auto}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-image{transition:opacity var(--wpds-motion-duration-lg,.3s) var(--wpds-motion-easing-subtle,cubic-bezier(.15,0,.15,1))}}.font-library__font-card .font-library__font-variant_demo-image.is-loading{left:0;opacity:0;position:absolute;top:0}.font-library__font-card .font-library__font-variant-demo-skeleton{border-radius:var(--wpds-border-radius-sm,2px);height:24px}.font-library__font-card .font-library__font-variant_demo-text{flex-shrink:0;white-space:nowrap}@media not (prefers-reduced-motion){.font-library__font-card .font-library__font-variant_demo-text{transition:opacity .3s ease-in-out}}.font-library-modal__tablist-container{background:#fff;border-bottom:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);position:sticky;top:0;z-index:1}.font-library__upload-area{align-items:center;display:flex;height:256px!important;justify-content:center;width:100%}button.font-library__upload-area{background-color:#f0f0f0}.font-library__local-fonts{margin:24px auto;width:80%}.font-library__local-fonts .font-library__upload-area__text{color:#757575}.font-library__google-fonts-confirm{align-items:center;display:flex;justify-content:center;margin-top:64px}.font-library__google-fonts-confirm p{line-height:1.4}.font-library__google-fonts-confirm h2{font-size:1.2rem;font-weight:400}.font-library__google-fonts-confirm .components-card{padding:16px;width:400px}.font-library__google-fonts-confirm .components-button{justify-content:center;width:100%}.font-library__select-all{padding:16px 16px 16px 17px}.font-library__select-all .components-checkbox-control__label{padding-left:16px}.global-styles-ui-pagination .components-button.is-tertiary{height:32px;justify-content:center;width:32px}.global-styles-ui-screen-revisions__revisions-list{flex-grow:1;list-style:none;margin:0 16px 16px}.global-styles-ui-screen-revisions__revisions-list li{margin-bottom:0}.global-styles-ui-screen-revisions__revision-item{cursor:var(--wpds-cursor-control,pointer);display:flex;flex-direction:column;position:relative}.global-styles-ui-screen-revisions__revision-item[role=option]:active,.global-styles-ui-screen-revisions__revision-item[role=option]:focus{box-shadow:0 0 0 var(--wp-admin-border-width-focus) var(--wp-admin-theme-color);outline:2px solid transparent}.global-styles-ui-screen-revisions__revision-item:hover{background:rgba(var(--wp-admin-theme-color--rgb),.04)}.global-styles-ui-screen-revisions__revision-item:hover .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item:after,.global-styles-ui-screen-revisions__revision-item:before{content:"\\a";display:block;position:absolute}.global-styles-ui-screen-revisions__revision-item:before{background:#ddd;border:4px solid transparent;border-radius:50%;height:8px;left:17px;top:18px;transform:translate(-50%,-50%);width:8px;z-index:1}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]{background:rgba(var(--wp-admin-theme-color--rgb),.04);border-radius:2px;color:var(--wp-admin-theme-color);outline:3px solid transparent;outline-offset:-2px}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__date{color:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true]:before{background:var(--wp-admin-theme-color)}.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__changes>li,.global-styles-ui-screen-revisions__revision-item[aria-selected=true] .global-styles-ui-screen-revisions__meta{color:#1e1e1e}.global-styles-ui-screen-revisions__revision-item:after{border:.5px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);height:100%;left:16px;top:0;width:0}.global-styles-ui-screen-revisions__revision-item:first-child:after{top:18px}.global-styles-ui-screen-revisions__revision-item:last-child:after{height:18px}.global-styles-ui-screen-revisions__revision-item-wrapper{display:block;padding:12px 12px 4px 40px}.global-styles-ui-screen-revisions__active-badge,.global-styles-ui-screen-revisions__apply-button.is-primary{align-self:flex-start;margin:0 12px 12px 40px}.global-styles-ui-screen-revisions__changes,.global-styles-ui-screen-revisions__meta{color:#757575;font-size:12px}.global-styles-ui-screen-revisions__description{align-items:flex-start;display:flex;flex-direction:column;gap:8px}.global-styles-ui-screen-revisions__description .global-styles-ui-screen-revisions__date{font-size:12px;font-weight:var(--wpds-typography-font-weight-emphasis,600);text-transform:uppercase}.global-styles-ui-screen-revisions__meta{align-items:flex-start;display:flex;justify-content:start;margin-bottom:4px;text-align:left;width:100%}.global-styles-ui-screen-revisions__meta img{border-radius:100%;height:16px;margin-right:8px;width:16px}.global-styles-ui-screen-revisions__loading{margin:24px auto!important}.global-styles-ui-screen-revisions__changes{line-height:1.4;list-style:disc;margin-left:12px;text-align:left}.global-styles-ui-screen-revisions__changes li{margin-bottom:4px}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination{gap:2px;justify-content:space-between}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .edit-site-pagination__total{height:1px;left:-1000px;margin:-1px;overflow:hidden;position:absolute}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-text{font-size:12px;will-change:opacity}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary{color:#1e1e1e}.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary:disabled,.global-styles-ui-screen-revisions__pagination.global-styles-ui-screen-revisions__pagination .components-button.is-tertiary[aria-disabled=true]{color:#949494}.global-styles-ui-screen-revisions__footer{background:#fff;border-top:1px solid var(--wpds-color-stroke-surface-neutral,#dbdbdb);bottom:0;box-sizing:border-box;height:56px;min-width:100%;padding:12px;position:sticky;z-index:1}.global-styles-ui-variations_item{box-sizing:border-box;cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{border-radius:2px;outline:1px solid rgba(0,0,0,.1);outline-offset:-1px;overflow:hidden;position:relative}@media not (prefers-reduced-motion){.global-styles-ui-variations_item .global-styles-ui-variations_item-preview{transition:outline .1s linear}}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill{height:32px}.global-styles-ui-variations_item .global-styles-ui-variations_item-preview.is-pill .block-editor-iframe__scale-container{overflow:hidden}.global-styles-ui-variations_item:not(.is-active):hover .global-styles-ui-variations_item-preview{outline-color:rgba(0,0,0,.3)}.global-styles-ui-variations_item.is-active .global-styles-ui-variations_item-preview,.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:#1e1e1e;outline-offset:1px;outline-width:var(--wp-admin-border-width-focus)}.global-styles-ui-variations_item:focus-visible .global-styles-ui-variations_item-preview{outline-color:var(--wp-admin-theme-color)}.global-styles-ui-preview__wrapper{display:block;max-width:100%;width:100%}.global-styles-ui-preview__wrapper.is-hoverable{cursor:var(--wpds-cursor-control,pointer)}.global-styles-ui-typography-preview{align-items:center;background:#f0f0f0;border-radius:2px;display:flex;justify-content:center;margin-bottom:20px;min-height:100px;overflow:hidden}.global-styles-ui-font-size__item{line-break:anywhere;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.global-styles-ui-font-size__item-value{color:#757575}.global-styles-ui-screen-typography__indicator{align-items:center;border-radius:2px;display:flex!important;font-size:14px;height:24px;justify-content:center;width:24px}.global-styles-ui-block-types-filter{margin-bottom:12px;padding:0 16px}.global-styles-ui-block-types-search{flex-grow:1}.global-styles-ui-block-types-item-list .global-styles-ui-block-types-item__icon{min-width:24px}.global-styles-ui-block-types-item-list__no-results{padding-top:16px}.global-styles-ui-block-types-item__indicator{background:var(--wp-admin-theme-color);border-radius:50%;flex:none;height:6px;margin-left:auto;width:6px}.global-styles-ui-screen-typography__font-variants-count{color:#757575}.global-styles-ui-font-families__manage-fonts{justify-content:center}.global-styles-ui-screen .color-block-support-panel{border-top:none;padding-left:0;padding-right:0;padding-top:0;row-gap:12px}.global-styles-ui-header{line-height:1.9!important;margin-bottom:0!important}.global-styles-ui-subtitle{font-size:11px!important;font-weight:var(--wpds-typography-font-weight-emphasis,600)!important;margin-bottom:0!important;text-transform:uppercase}.global-styles-ui-section-title{color:#2f2f2f;font-weight:var(--wpds-typography-font-weight-emphasis,600);line-height:1.2;margin:0;padding:16px 16px 0}.global-styles-ui-icon-with-current-color{fill:currentColor}.global-styles-ui__color-indicator-wrapper{flex-shrink:0;height:24px}.global-styles-ui__shadows-panel__options-container,.global-styles-ui__typography-panel__options-container{height:24px}.global-styles-ui__block-preview-panel{border:1px solid #ddd;border-radius:2px;overflow:hidden;position:relative;width:100%}.global-styles-ui__shadow-preview-panel{background-image:repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0),repeating-linear-gradient(45deg,#e0e0e0 25%,transparent 0,transparent 75%,#e0e0e0 0,#e0e0e0);background-position:0 0,8px 8px;background-size:16px 16px;border:1px solid #ddd;border-radius:2px;height:144px;overflow:auto}.global-styles-ui__shadow-preview-panel .global-styles-ui__shadow-preview-block{background-color:#fff;border:1px solid #ddd;border-radius:2px;height:60px;width:60%}.global-styles-ui__shadow-editor__dropdown-content{width:280px}.global-styles-ui__shadow-editor-panel{margin-bottom:4px}.global-styles-ui__shadow-editor__dropdown{position:relative;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle{border-radius:inherit;height:auto;padding-bottom:8px;padding-top:8px;text-align:left;width:100%}.global-styles-ui__shadow-editor__dropdown-toggle.is-open{background:#f0f0f0;color:var(--wp-admin-theme-color)}.global-styles-ui__shadow-editor__remove-button{opacity:0;position:absolute;right:8px;top:8px}.global-styles-ui__shadow-editor__dropdown-toggle:hover+.global-styles-ui__shadow-editor__remove-button,.global-styles-ui__shadow-editor__remove-button:focus,.global-styles-ui__shadow-editor__remove-button:hover{opacity:1}@media (hover:none){.global-styles-ui__shadow-editor__remove-button{opacity:1}}.global-styles-ui-screen-css{display:flex;flex:1 1 auto;flex-direction:column;margin:16px}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel{flex:1 1 auto}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input,.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input .components-base-control__field{display:flex;flex:1 1 auto;flex-direction:column}.global-styles-ui-screen-css .block-editor-global-styles-advanced-panel__custom-css-input textarea{flex:1 1 auto}.global-styles-ui-screen-css-help-link{display:inline-block;margin-top:8px}.global-styles-ui-screen-variations{border-top:1px solid #ddd;margin-top:16px}.global-styles-ui-screen-variations>*{margin:24px 16px}.global-styles-ui-sidebar__navigator-provider{height:100%}.global-styles-ui-sidebar__navigator-screen{display:flex;flex-direction:column;height:100%}.global-styles-ui-color-palette__tablist-container{border-bottom:1px solid #ddd}.global-styles-ui-color-palette__tablist{margin-bottom:-1px}.global-styles-ui-sidebar__navigator-screen .single-column{grid-column:span 1}.global-styles-ui-screen-root.global-styles-ui-screen-root,.global-styles-ui-screen-style-variations.global-styles-ui-screen-style-variations{background:unset;color:inherit}.global-styles-ui-sidebar__panel .block-editor-block-icon svg{fill:currentColor}.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile,.global-styles-ui-screen-root__active-style-tile.global-styles-ui-screen-root__active-style-tile .global-styles-ui-screen-root__active-style-tile-preview{border-radius:2px}.global-styles-ui-screen-root__active-style-tile-preview{clip-path:border-box}.global-styles-ui-color-palette-panel,.global-styles-ui-duotone-palette-panel,.global-styles-ui-gradient-palette-panel{padding:16px}.font-library-page__content{background-color:var(--wpds-color-background-surface-neutral-strong,#fff);display:flex;flex-direction:column;flex-grow:1;min-height:0}.font-library-page:has(.font-library__footer) .font-library-page__content{padding-bottom:90px}.font-library-page__tablist{border-bottom:1px solid #f0f0f0;flex-shrink:0;padding:0 24px}.font-library-page__tab-panel{flex-grow:1;min-height:0;overflow:auto}')),document.head.appendChild(e)}var Pr=f(Z()),{Tabs:Ca}=Fu(Av.privateApis),{useGlobalStyles:TE}=Fu(Iv.privateApis);function PE(){let{records:e=[]}=(0,Ra.useEntityRecords)("root","fontCollection",{_fields:"slug,name,description"}),[t,r]=(0,Nv.useState)("installed-fonts"),{base:o,user:n,setUser:i,isReady:s}=TE(),a=(0,Lv.useSelect)(l=>l(Ra.store).canUser("create",{kind:"postType",name:"wp_font_family"}),[]);if(!s)return null;let u=[{id:"installed-fonts",title:(0,zn._x)("Library","Font library")}];return a&&(u.push({id:"upload-fonts",title:(0,zn._x)("Upload","noun")}),u.push(...(e||[]).map(({slug:l,name:c})=>({id:l,title:e&&e.length===1&&l==="google-fonts"?(0,zn.__)("Install Fonts"):c})))),(0,Pr.jsx)(hc,{title:(0,zn.__)("Fonts"),className:"font-library-page",children:(0,Pr.jsx)("div",{className:"font-library-page__content",children:(0,Pr.jsxs)(Ca,{selectedTabId:t,onSelect:l=>r(l),children:[(0,Pr.jsx)("div",{className:"font-library-page__tablist",children:(0,Pr.jsx)(Ca.TabList,{children:u.map(({id:l,title:c})=>(0,Pr.jsx)(Ca.Tab,{tabId:l,children:c},l))})}),u.map(({id:l})=>(0,Pr.jsx)(Ca.TabPanel,{tabId:l,focusable:!1,className:"font-library-page__tab-panel",children:(0,Pr.jsx)(ku,{value:n,baseValue:o,onChange:i,activeTab:l})},l))]})})})}function OE(){return(0,Pr.jsx)(PE,{})}var kE=OE;export{kE as stage}; /*! Bundled license information: use-sync-external-store/cjs/use-sync-external-store-shim.production.js: diff --git a/src/wp-includes/images/icon-library/arrow-down-left.svg b/src/wp-includes/images/icon-library/arrow-down-left.svg index af4f173f3988b..81581dceafb99 100644 --- a/src/wp-includes/images/icon-library/arrow-down-left.svg +++ b/src/wp-includes/images/icon-library/arrow-down-left.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-down-right.svg b/src/wp-includes/images/icon-library/arrow-down-right.svg index d8a31b6ed447a..e7435f7e8c979 100644 --- a/src/wp-includes/images/icon-library/arrow-down-right.svg +++ b/src/wp-includes/images/icon-library/arrow-down-right.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-down.svg b/src/wp-includes/images/icon-library/arrow-down.svg index ef8fdd02e3c9e..c32a6d28f6e4c 100644 --- a/src/wp-includes/images/icon-library/arrow-down.svg +++ b/src/wp-includes/images/icon-library/arrow-down.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-left.svg b/src/wp-includes/images/icon-library/arrow-left.svg index e2a3e95d405d1..5890d0d13ccda 100644 --- a/src/wp-includes/images/icon-library/arrow-left.svg +++ b/src/wp-includes/images/icon-library/arrow-left.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-right.svg b/src/wp-includes/images/icon-library/arrow-right.svg index 225418a59e24f..ab99d246cc925 100644 --- a/src/wp-includes/images/icon-library/arrow-right.svg +++ b/src/wp-includes/images/icon-library/arrow-right.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-up-left.svg b/src/wp-includes/images/icon-library/arrow-up-left.svg index 054ebcfe3755d..0f61d3d4f59ee 100644 --- a/src/wp-includes/images/icon-library/arrow-up-left.svg +++ b/src/wp-includes/images/icon-library/arrow-up-left.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-up-right.svg b/src/wp-includes/images/icon-library/arrow-up-right.svg index 6a8f3a4445980..d828f0fe648a0 100644 --- a/src/wp-includes/images/icon-library/arrow-up-right.svg +++ b/src/wp-includes/images/icon-library/arrow-up-right.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/arrow-up.svg b/src/wp-includes/images/icon-library/arrow-up.svg index 8e4e1dcbb5ca4..581102424165c 100644 --- a/src/wp-includes/images/icon-library/arrow-up.svg +++ b/src/wp-includes/images/icon-library/arrow-up.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/block-meta.svg b/src/wp-includes/images/icon-library/block-meta.svg index 88095ac76494c..3fad51d72e8f8 100644 --- a/src/wp-includes/images/icon-library/block-meta.svg +++ b/src/wp-includes/images/icon-library/block-meta.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/category.svg b/src/wp-includes/images/icon-library/category.svg index bb70f4a56a6a5..5dfaa1b2f9f5b 100644 --- a/src/wp-includes/images/icon-library/category.svg +++ b/src/wp-includes/images/icon-library/category.svg @@ -1,3 +1,6 @@ - - + + + + + diff --git a/src/wp-includes/images/icon-library/caution.svg b/src/wp-includes/images/icon-library/caution.svg index 11ab2d31d15f3..11ec7b1df426f 100644 --- a/src/wp-includes/images/icon-library/caution.svg +++ b/src/wp-includes/images/icon-library/caution.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chart-bar.svg b/src/wp-includes/images/icon-library/chart-bar.svg index 5469b91d71508..813fcb5045d61 100644 --- a/src/wp-includes/images/icon-library/chart-bar.svg +++ b/src/wp-includes/images/icon-library/chart-bar.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/check.svg b/src/wp-includes/images/icon-library/check.svg index 9eaf43d2f4122..0a6f0a20d2f1b 100644 --- a/src/wp-includes/images/icon-library/check.svg +++ b/src/wp-includes/images/icon-library/check.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-down-small.svg b/src/wp-includes/images/icon-library/chevron-down-small.svg index 411c1c2bb266f..d7a727bd702c0 100644 --- a/src/wp-includes/images/icon-library/chevron-down-small.svg +++ b/src/wp-includes/images/icon-library/chevron-down-small.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-down.svg b/src/wp-includes/images/icon-library/chevron-down.svg index 2c4553d3cac28..d7c5227261d4d 100644 --- a/src/wp-includes/images/icon-library/chevron-down.svg +++ b/src/wp-includes/images/icon-library/chevron-down.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-left-small.svg b/src/wp-includes/images/icon-library/chevron-left-small.svg index d00996331ecb4..4fc8981f250eb 100644 --- a/src/wp-includes/images/icon-library/chevron-left-small.svg +++ b/src/wp-includes/images/icon-library/chevron-left-small.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-left.svg b/src/wp-includes/images/icon-library/chevron-left.svg index f1eeafd04a233..d7a40c2c1c7eb 100644 --- a/src/wp-includes/images/icon-library/chevron-left.svg +++ b/src/wp-includes/images/icon-library/chevron-left.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-right-small.svg b/src/wp-includes/images/icon-library/chevron-right-small.svg index e98c0fd7decc8..872d7494a6659 100644 --- a/src/wp-includes/images/icon-library/chevron-right-small.svg +++ b/src/wp-includes/images/icon-library/chevron-right-small.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-right.svg b/src/wp-includes/images/icon-library/chevron-right.svg index 6f521fc34f116..44c37174dd001 100644 --- a/src/wp-includes/images/icon-library/chevron-right.svg +++ b/src/wp-includes/images/icon-library/chevron-right.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-up-down.svg b/src/wp-includes/images/icon-library/chevron-up-down.svg index 28e96c3369d80..7253e57b8a8b7 100644 --- a/src/wp-includes/images/icon-library/chevron-up-down.svg +++ b/src/wp-includes/images/icon-library/chevron-up-down.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-up-small.svg b/src/wp-includes/images/icon-library/chevron-up-small.svg index 897cea7292c16..bee27a88a28f8 100644 --- a/src/wp-includes/images/icon-library/chevron-up-small.svg +++ b/src/wp-includes/images/icon-library/chevron-up-small.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/chevron-up.svg b/src/wp-includes/images/icon-library/chevron-up.svg index d19e61474c583..8afc261bc0592 100644 --- a/src/wp-includes/images/icon-library/chevron-up.svg +++ b/src/wp-includes/images/icon-library/chevron-up.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/cover.svg b/src/wp-includes/images/icon-library/cover.svg index 20587c08a45e2..0a45590c3a76b 100644 --- a/src/wp-includes/images/icon-library/cover.svg +++ b/src/wp-includes/images/icon-library/cover.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/create.svg b/src/wp-includes/images/icon-library/create.svg index 5b1e766f81993..18b49120fbb90 100644 --- a/src/wp-includes/images/icon-library/create.svg +++ b/src/wp-includes/images/icon-library/create.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/download.svg b/src/wp-includes/images/icon-library/download.svg index 783c301be5b24..d222df20da821 100644 --- a/src/wp-includes/images/icon-library/download.svg +++ b/src/wp-includes/images/icon-library/download.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/help.svg b/src/wp-includes/images/icon-library/help.svg index e4174a83fa7ac..85d465377f0d0 100644 --- a/src/wp-includes/images/icon-library/help.svg +++ b/src/wp-includes/images/icon-library/help.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/image.svg b/src/wp-includes/images/icon-library/image.svg index e3516dccbeef5..36aa667cdb6e1 100644 --- a/src/wp-includes/images/icon-library/image.svg +++ b/src/wp-includes/images/icon-library/image.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/info.svg b/src/wp-includes/images/icon-library/info.svg index c33d9dc59689b..ebd757078da72 100644 --- a/src/wp-includes/images/icon-library/info.svg +++ b/src/wp-includes/images/icon-library/info.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/menu.svg b/src/wp-includes/images/icon-library/menu.svg index c911e7b176242..2564551e038fd 100644 --- a/src/wp-includes/images/icon-library/menu.svg +++ b/src/wp-includes/images/icon-library/menu.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/next.svg b/src/wp-includes/images/icon-library/next.svg index c7f3c872176b3..9c436f08d79dc 100644 --- a/src/wp-includes/images/icon-library/next.svg +++ b/src/wp-includes/images/icon-library/next.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/paragraph.svg b/src/wp-includes/images/icon-library/paragraph.svg index 2a6681576be80..b76197865e9d7 100644 --- a/src/wp-includes/images/icon-library/paragraph.svg +++ b/src/wp-includes/images/icon-library/paragraph.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/plus-circle.svg b/src/wp-includes/images/icon-library/plus-circle.svg index b6c6ecbd74ef1..c03320908c329 100644 --- a/src/wp-includes/images/icon-library/plus-circle.svg +++ b/src/wp-includes/images/icon-library/plus-circle.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/plus.svg b/src/wp-includes/images/icon-library/plus.svg index 555d8c2e0125e..13ab663720dc1 100644 --- a/src/wp-includes/images/icon-library/plus.svg +++ b/src/wp-includes/images/icon-library/plus.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/previous.svg b/src/wp-includes/images/icon-library/previous.svg index e986f1d5064c8..6213f948de87e 100644 --- a/src/wp-includes/images/icon-library/previous.svg +++ b/src/wp-includes/images/icon-library/previous.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/published.svg b/src/wp-includes/images/icon-library/published.svg index 6f5ad1027d8d1..534c6282f33a9 100644 --- a/src/wp-includes/images/icon-library/published.svg +++ b/src/wp-includes/images/icon-library/published.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/rss.svg b/src/wp-includes/images/icon-library/rss.svg index 4906420f5edbe..a6dcd21385bd5 100644 --- a/src/wp-includes/images/icon-library/rss.svg +++ b/src/wp-includes/images/icon-library/rss.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/scheduled.svg b/src/wp-includes/images/icon-library/scheduled.svg index a0d26f8adb8b0..d2b32b43f7de8 100644 --- a/src/wp-includes/images/icon-library/scheduled.svg +++ b/src/wp-includes/images/icon-library/scheduled.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/search.svg b/src/wp-includes/images/icon-library/search.svg index 5cae09d19eebf..e1c49101f6433 100644 --- a/src/wp-includes/images/icon-library/search.svg +++ b/src/wp-includes/images/icon-library/search.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/star-empty.svg b/src/wp-includes/images/icon-library/star-empty.svg index 9f18b42ce0830..8137f625c22f9 100644 --- a/src/wp-includes/images/icon-library/star-empty.svg +++ b/src/wp-includes/images/icon-library/star-empty.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/star-filled.svg b/src/wp-includes/images/icon-library/star-filled.svg index 9343997cdb066..4c407ff2cc1ea 100644 --- a/src/wp-includes/images/icon-library/star-filled.svg +++ b/src/wp-includes/images/icon-library/star-filled.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/star-half.svg b/src/wp-includes/images/icon-library/star-half.svg index 813d3e1c7276d..391acb64a7492 100644 --- a/src/wp-includes/images/icon-library/star-half.svg +++ b/src/wp-includes/images/icon-library/star-half.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/styles.svg b/src/wp-includes/images/icon-library/styles.svg index d9dddbd2e41b8..e3d2906a27248 100644 --- a/src/wp-includes/images/icon-library/styles.svg +++ b/src/wp-includes/images/icon-library/styles.svg @@ -1,3 +1,4 @@ - - + + + diff --git a/src/wp-includes/images/icon-library/tip.svg b/src/wp-includes/images/icon-library/tip.svg index 79fdb4c1f25d5..c698691bbeaa4 100644 --- a/src/wp-includes/images/icon-library/tip.svg +++ b/src/wp-includes/images/icon-library/tip.svg @@ -1,3 +1,3 @@ - - + + diff --git a/src/wp-includes/images/icon-library/upload.svg b/src/wp-includes/images/icon-library/upload.svg index 0af97ce70f172..0b797bcf3e5fa 100644 --- a/src/wp-includes/images/icon-library/upload.svg +++ b/src/wp-includes/images/icon-library/upload.svg @@ -1,3 +1,3 @@ - - + + From 62439bbb0ae8dc2e73f32bd42372a356e8ea55c1 Mon Sep 17 00:00:00 2001 From: Jonathan Desrosiers Date: Tue, 8 Sep 2026 16:55:39 +0000 Subject: [PATCH 163/363] Build/Test Tools: Upgrade Node.js to 24.x. This updates the minimum required version of Node.js in Core to `24.18.0`. Gutenberg has already been bumped, and the `gutenberg.sha` value is being updated to point to the corresponding merge commit. The Twenty Nineteen and Twenty Twenty themes are remaining on 20.x and 16.x for the time being until a compatibility issue in each dependency tree can be resolved. Props desrosj, manzoorwanijk, ciampo, SirLouen, jsnajdr, aduth, barry, mukesh27, jonsurrell. git-svn-id: https://develop.svn.wordpress.org/trunk@63539 602fd350-edb4-49c9-b593-d223f7449a82 --- .nvmrc | 2 +- package-lock.json | 4 ++-- package.json | 6 +++--- src/wp-content/themes/twentytwentyfive/.nvmrc | 2 +- .../themes/twentytwentyfive/package-lock.json | 7 ++----- src/wp-content/themes/twentytwentyfive/package.json | 12 ++++++------ src/wp-content/themes/twentytwentyone/.nvmrc | 2 +- .../themes/twentytwentyone/package-lock.json | 4 ++-- src/wp-content/themes/twentytwentyone/package.json | 4 ++-- src/wp-content/themes/twentytwentytwo/.nvmrc | 2 +- .../themes/twentytwentytwo/package-lock.json | 7 ++----- src/wp-content/themes/twentytwentytwo/package.json | 4 ++-- 12 files changed, 25 insertions(+), 31 deletions(-) diff --git a/.nvmrc b/.nvmrc index 209e3ef4b6247..82d5d714347ef 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -20 +24.18 diff --git a/package-lock.json b/package-lock.json index f1d7ebd89b2c4..fd069ad47879c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -95,8 +95,8 @@ "webpack": "5.108.4" }, "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" } }, "node_modules/@asamuzakjp/css-color": { diff --git a/package.json b/package.json index 7c9e99a625534..ca760568737a3 100644 --- a/package.json +++ b/package.json @@ -7,12 +7,12 @@ "url": "https://develop.svn.wordpress.org/trunk" }, "gutenberg": { - "sha": "5a4cc502d43016f1efa66f8f6d9bd3bb4bb24d85", + "sha": "5715a61334c4d29f21b67cf34b46061dc1b62502", "ghcrRepo": "WordPress/gutenberg/gutenberg-wp-develop-build" }, "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" }, "author": "The WordPress Contributors", "license": "GPL-2.0-or-later", diff --git a/src/wp-content/themes/twentytwentyfive/.nvmrc b/src/wp-content/themes/twentytwentyfive/.nvmrc index 209e3ef4b6247..82d5d714347ef 100644 --- a/src/wp-content/themes/twentytwentyfive/.nvmrc +++ b/src/wp-content/themes/twentytwentyfive/.nvmrc @@ -1 +1 @@ -20 +24.18 diff --git a/src/wp-content/themes/twentytwentyfive/package-lock.json b/src/wp-content/themes/twentytwentyfive/package-lock.json index 3e364a3c43d01..26fc86bf03862 100644 --- a/src/wp-content/themes/twentytwentyfive/package-lock.json +++ b/src/wp-content/themes/twentytwentyfive/package-lock.json @@ -15,8 +15,8 @@ "postcss-cli": "^11.0.1" }, "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" } }, "node_modules/@wordpress/browserslist-config": { @@ -133,7 +133,6 @@ } ], "license": "MIT", - "peer": true, "dependencies": { "baseline-browser-mapping": "^2.8.25", "caniuse-lite": "^1.0.30001754", @@ -825,7 +824,6 @@ } ], "license": "MIT", - "peer": true, "dependencies": { "nanoid": "^3.3.11", "picocolors": "^1.1.1", @@ -1582,7 +1580,6 @@ "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=12" }, diff --git a/src/wp-content/themes/twentytwentyfive/package.json b/src/wp-content/themes/twentytwentyfive/package.json index 9da89b58c35e0..04dab98c23949 100644 --- a/src/wp-content/themes/twentytwentyfive/package.json +++ b/src/wp-content/themes/twentytwentyfive/package.json @@ -13,8 +13,8 @@ }, "homepage": "https://wordpress.org/themes/twentytwentyfive/", "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" }, "devDependencies": { "@wordpress/browserslist-config": "^6.34.0", @@ -25,8 +25,8 @@ "browserslist": [ "extends @wordpress/browserslist-config" ], - "scripts": { - "build": "postcss style.css --use cssnano -o style.min.css --no-map", - "watch": "postcss style.css --use cssnano -o style.min.css --no-map --watch" - } + "scripts": { + "build": "postcss style.css --use cssnano -o style.min.css --no-map", + "watch": "postcss style.css --use cssnano -o style.min.css --no-map --watch" + } } diff --git a/src/wp-content/themes/twentytwentyone/.nvmrc b/src/wp-content/themes/twentytwentyone/.nvmrc index 209e3ef4b6247..82d5d714347ef 100644 --- a/src/wp-content/themes/twentytwentyone/.nvmrc +++ b/src/wp-content/themes/twentytwentyone/.nvmrc @@ -1 +1 @@ -20 +24.18 diff --git a/src/wp-content/themes/twentytwentyone/package-lock.json b/src/wp-content/themes/twentytwentyone/package-lock.json index c91af0fd29418..947acba18edcc 100644 --- a/src/wp-content/themes/twentytwentyone/package-lock.json +++ b/src/wp-content/themes/twentytwentyone/package-lock.json @@ -33,8 +33,8 @@ "stylelint-config-recommended-scss": "^16.0.2" }, "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" } }, "node_modules/@aashutoshrathi/word-wrap": { diff --git a/src/wp-content/themes/twentytwentyone/package.json b/src/wp-content/themes/twentytwentyone/package.json index 2e546c99eb612..7097e3f65f70f 100644 --- a/src/wp-content/themes/twentytwentyone/package.json +++ b/src/wp-content/themes/twentytwentyone/package.json @@ -13,8 +13,8 @@ }, "homepage": "https://wordpress.org/themes/twentytwentyone/", "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" }, "devDependencies": { "@wordpress/browserslist-config": "^6.34.0", diff --git a/src/wp-content/themes/twentytwentytwo/.nvmrc b/src/wp-content/themes/twentytwentytwo/.nvmrc index 209e3ef4b6247..82d5d714347ef 100644 --- a/src/wp-content/themes/twentytwentytwo/.nvmrc +++ b/src/wp-content/themes/twentytwentytwo/.nvmrc @@ -1 +1 @@ -20 +24.18 diff --git a/src/wp-content/themes/twentytwentytwo/package-lock.json b/src/wp-content/themes/twentytwentytwo/package-lock.json index 8d0f405241eb9..ffde012248aad 100644 --- a/src/wp-content/themes/twentytwentytwo/package-lock.json +++ b/src/wp-content/themes/twentytwentytwo/package-lock.json @@ -15,8 +15,8 @@ "postcss-cli": "^11.0.1" }, "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" } }, "node_modules/@wordpress/browserslist-config": { @@ -133,7 +133,6 @@ } ], "license": "MIT", - "peer": true, "dependencies": { "baseline-browser-mapping": "^2.8.25", "caniuse-lite": "^1.0.30001754", @@ -825,7 +824,6 @@ } ], "license": "MIT", - "peer": true, "dependencies": { "nanoid": "^3.3.11", "picocolors": "^1.1.1", @@ -1582,7 +1580,6 @@ "integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==", "dev": true, "license": "MIT", - "peer": true, "engines": { "node": ">=12" }, diff --git a/src/wp-content/themes/twentytwentytwo/package.json b/src/wp-content/themes/twentytwentytwo/package.json index 842b94e80f1f1..b0b1a5e15f736 100644 --- a/src/wp-content/themes/twentytwentytwo/package.json +++ b/src/wp-content/themes/twentytwentytwo/package.json @@ -13,8 +13,8 @@ }, "homepage": "https://wordpress.org/themes/twentytwentytwo/", "engines": { - "node": ">=20.10.0", - "npm": ">=10.2.3" + "node": ">=24.18.0", + "npm": ">=11.16.0" }, "devDependencies": { "@wordpress/browserslist-config": "^6.34.0", From f03710d84744c509102c74e4a7e5149822bef26e Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Tue, 8 Sep 2026 18:35:49 +0000 Subject: [PATCH 164/363] Code Quality: Narrow the `esc_sql()` parameter and return types. Narrow the documented types of `esc_sql()` and `wpdb::_escape()` from `string|array` to `string|string[]`, since neither function is meant to operate on anything other than strings and flat arrays of strings. Add `@phpstan-` prefixed annotations with a key template and a conditional return type, so static analysis knows that a `string` yields a `string` and that an array yields an array of strings with its keys preserved. Developed in https://github.com/WordPress/wordpress-develop/pull/12975. Follow-up to r24986, r62672. Props johnbillion, westonruter, irozum. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63540 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wpdb.php | 15 +++++++++++++-- src/wp-includes/formatting.php | 8 ++++++-- 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/src/wp-includes/class-wpdb.php b/src/wp-includes/class-wpdb.php index 5cf9508f8fbdf..869111efd0797 100644 --- a/src/wp-includes/class-wpdb.php +++ b/src/wp-includes/class-wpdb.php @@ -1291,12 +1291,23 @@ public function _real_escape( $data ) { /** * Escapes data. Works on arrays. * + * The `$data is string` case must come first in the conditional return type below. PHPStan + * does not treat the documented types as certain, so it still analyzes the nested + * `is_array()` check even though `$v` is a `string`, narrowing `$v` to `never` there. A + * `never` argument satisfies whichever case is tested first, so testing for `string` first + * makes the recursive call resolve to `string`. Testing for the array case first would + * instead resolve it to an array, widening `$data` and contradicting the return type. + * * @since 2.8.0 * * @uses wpdb::_real_escape() * - * @param string|array $data Data to escape. - * @return string|array Escaped data, in the same type as supplied. + * @param string|string[] $data Data to escape. + * @return string|string[] Escaped data, in the same type as supplied. + * + * @phpstan-template TKey of array-key + * @phpstan-param string|array $data + * @phpstan-return ( $data is string ? string : array ) */ public function _escape( $data ) { if ( is_array( $data ) ) { diff --git a/src/wp-includes/formatting.php b/src/wp-includes/formatting.php index b9d551d59d51b..abbf18c3b74d2 100644 --- a/src/wp-includes/formatting.php +++ b/src/wp-includes/formatting.php @@ -4521,8 +4521,12 @@ function _deep_replace( $search, $subject ) { * * @global wpdb $wpdb WordPress database abstraction object. * - * @param string|array $data Unescaped data. - * @return string|array Escaped data, in the same type as supplied. + * @param string|string[] $data Unescaped data. + * @return string|string[] Escaped data, in the same type as supplied. + * + * @phpstan-template TKey of array-key + * @phpstan-param string|array $data + * @phpstan-return ( $data is string ? string : array ) */ function esc_sql( $data ) { global $wpdb; From 40a1782bb916a2797b5e1397a6ada9a7794ca6f2 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 8 Sep 2026 19:35:37 +0000 Subject: [PATCH 165/363] Code Modernization: Use the null coalescing assignment operator for registration argument defaults. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replaces the “assign a default only if not already set” guard blocks in `WP_Post_Type::set_props()` and `WP_Taxonomy::set_props()` with the null coalescing assignment operator (`??=`). Both classes normalize their registration arguments with the same idiom, so the two methods now read identically. **Scope** This covers `WP_Post_Type::set_props()` and `WP_Taxonomy::set_props()` completely: every guard in those two methods that `??=` can express is converted, so the two methods are internally consistent rather than half-modernized. The same pattern exists elsewhere in core; that is left for separate follow-ups on the same ticket so each one stays reviewable. Developed in https://github.com/WordPress/wordpress-develop/pull/13418. Follow-up to r63443, r63501, r63509. Props Soean, westonruter. See #65823. git-svn-id: https://develop.svn.wordpress.org/trunk@63541 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-post-type.php | 44 ++++++++------------------ src/wp-includes/class-wp-taxonomy.php | 20 +++--------- 2 files changed, 19 insertions(+), 45 deletions(-) diff --git a/src/wp-includes/class-wp-post-type.php b/src/wp-includes/class-wp-post-type.php index 88fecd08c868c..f1919062686d0 100644 --- a/src/wp-includes/class-wp-post-type.php +++ b/src/wp-includes/class-wp-post-type.php @@ -570,19 +570,13 @@ public function set_props( $args ) { $args['name'] = $this->name; // If not set, default to the setting for 'public'. - if ( null === $args['publicly_queryable'] ) { - $args['publicly_queryable'] = $args['public']; - } + $args['publicly_queryable'] ??= $args['public']; // If not set, default to the setting for 'public'. - if ( null === $args['show_ui'] ) { - $args['show_ui'] = $args['public']; - } + $args['show_ui'] ??= $args['public']; // If not set, default to the setting for 'public'. - if ( null === $args['embeddable'] ) { - $args['embeddable'] = $args['public']; - } + $args['embeddable'] ??= $args['public']; // If not set, default rest_namespace to wp/v2 if show_in_rest is true. if ( false === $args['rest_namespace'] && ! empty( $args['show_in_rest'] ) ) { @@ -595,19 +589,13 @@ public function set_props( $args ) { } // If not set, default to the setting for 'show_in_menu'. - if ( null === $args['show_in_admin_bar'] ) { - $args['show_in_admin_bar'] = (bool) $args['show_in_menu']; - } + $args['show_in_admin_bar'] ??= (bool) $args['show_in_menu']; // If not set, default to the setting for 'public'. - if ( null === $args['show_in_nav_menus'] ) { - $args['show_in_nav_menus'] = $args['public']; - } + $args['show_in_nav_menus'] ??= $args['public']; // If not set, default to true if not public, false if public. - if ( null === $args['exclude_from_search'] ) { - $args['exclude_from_search'] = ! $args['public']; - } + $args['exclude_from_search'] ??= ! $args['public']; // Back compat with quirky handling in version 3.0. #14122. if ( empty( $args['capabilities'] ) @@ -617,9 +605,7 @@ public function set_props( $args ) { } // If not set, default to false. - if ( null === $args['map_meta_cap'] ) { - $args['map_meta_cap'] = false; - } + $args['map_meta_cap'] ??= false; // If there's no specified edit link and no UI, remove the edit link. if ( ! $args['show_ui'] && ! $has_edit_link ) { @@ -645,21 +631,19 @@ public function set_props( $args ) { if ( ! is_array( $args['rewrite'] ) ) { $args['rewrite'] = array(); } + if ( empty( $args['rewrite']['slug'] ) ) { $args['rewrite']['slug'] = $this->name; } - if ( ! isset( $args['rewrite']['with_front'] ) ) { - $args['rewrite']['with_front'] = true; - } - if ( ! isset( $args['rewrite']['pages'] ) ) { - $args['rewrite']['pages'] = true; - } + + $args['rewrite']['with_front'] ??= true; + $args['rewrite']['pages'] ??= true; + if ( ! isset( $args['rewrite']['feeds'] ) || ! $args['has_archive'] ) { $args['rewrite']['feeds'] = (bool) $args['has_archive']; } - if ( ! isset( $args['rewrite']['ep_mask'] ) ) { - $args['rewrite']['ep_mask'] = $args['permalink_epmask'] ?? EP_PERMALINK; - } + + $args['rewrite']['ep_mask'] ??= $args['permalink_epmask'] ?? EP_PERMALINK; } foreach ( $args as $property_name => $property_value ) { diff --git a/src/wp-includes/class-wp-taxonomy.php b/src/wp-includes/class-wp-taxonomy.php index 0c7ffa8c7d6dd..f44ce34a11def 100644 --- a/src/wp-includes/class-wp-taxonomy.php +++ b/src/wp-includes/class-wp-taxonomy.php @@ -376,9 +376,7 @@ public function set_props( $object_type, $args ) { $args = array_merge( $defaults, $args ); // If not set, default to the setting for 'public'. - if ( null === $args['publicly_queryable'] ) { - $args['publicly_queryable'] = $args['public']; - } + $args['publicly_queryable'] ??= $args['public']; if ( false !== $args['query_var'] && ( is_admin() || false !== $args['publicly_queryable'] ) ) { if ( true === $args['query_var'] ) { @@ -407,9 +405,7 @@ public function set_props( $object_type, $args ) { } // If not set, default to the setting for 'public'. - if ( null === $args['show_ui'] ) { - $args['show_ui'] = $args['public']; - } + $args['show_ui'] ??= $args['public']; // If not set, default to the setting for 'show_ui'. if ( null === $args['show_in_menu'] || ! $args['show_ui'] ) { @@ -417,19 +413,13 @@ public function set_props( $object_type, $args ) { } // If not set, default to the setting for 'public'. - if ( null === $args['show_in_nav_menus'] ) { - $args['show_in_nav_menus'] = $args['public']; - } + $args['show_in_nav_menus'] ??= $args['public']; // If not set, default to the setting for 'show_ui'. - if ( null === $args['show_tagcloud'] ) { - $args['show_tagcloud'] = $args['show_ui']; - } + $args['show_tagcloud'] ??= $args['show_ui']; // If not set, default to the setting for 'show_ui'. - if ( null === $args['show_in_quick_edit'] ) { - $args['show_in_quick_edit'] = $args['show_ui']; - } + $args['show_in_quick_edit'] ??= $args['show_ui']; // If not set, default rest_namespace to wp/v2 if show_in_rest is true. if ( false === $args['rest_namespace'] && ! empty( $args['show_in_rest'] ) ) { From ea146ac5205800a0ca9c87a2743856f5056ba092 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Tue, 8 Sep 2026 20:05:22 +0000 Subject: [PATCH 166/363] Code Quality: Remove redundant boolean sub-expressions. Each of three conditions re-tests something the surrounding expression has already established, so PHPStan reports the redundant operand as always true: 1. In `wp_render_typography_support()`, `! empty()` already requires the `fitText` attribute to be truthy, so a following truthiness check on the same value can never fail. 2. In `_get_block_templates_files()`, the right operand of an `||` is only evaluated when `! $post_type` was false, so a leading `$post_type &&` there is always true. 3. In `Walker::display_element()`, `$newlevel` is a local variable that is only ever assigned the literal `true`, so the truthiness test adds nothing to the `isset()`. All three are simplifications with no change in behavior. This resolves two `booleanAnd.rightAlwaysTrue` occurrences and one `booleanAnd.leftAlwaysTrue` occurrence, and the corresponding PHPStan baselines are regenerated. Developed in https://github.com/WordPress/wordpress-develop/pull/13086. Follow-up to r55687, r61246, r63023. Props tstokes8040. See #65817. git-svn-id: https://develop.svn.wordpress.org/trunk@63542 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/block-supports/typography.php | 2 +- src/wp-includes/block-template-utils.php | 2 +- src/wp-includes/class-wp-walker.php | 2 +- tests/phpstan/baselines/booleanAnd.leftAlwaysTrue.neon | 5 ----- .../phpstan/baselines/booleanAnd.rightAlwaysTrue.neon | 10 ---------- 5 files changed, 3 insertions(+), 18 deletions(-) diff --git a/src/wp-includes/block-supports/typography.php b/src/wp-includes/block-supports/typography.php index e99d0254fb43d..3e920f6b3daa8 100644 --- a/src/wp-includes/block-supports/typography.php +++ b/src/wp-includes/block-supports/typography.php @@ -304,7 +304,7 @@ function wp_typography_get_preset_inline_style_value( $style_value, $css_propert * @return string Filtered block content. */ function wp_render_typography_support( $block_content, $block ) { - if ( ! empty( $block['attrs']['fitText'] ) && $block['attrs']['fitText'] && ! is_admin() ) { + if ( ! empty( $block['attrs']['fitText'] ) && ! is_admin() ) { wp_enqueue_script_module( '@wordpress/block-editor/utils/fit-text-frontend' ); // Add Interactivity API directives for fit text to work with client-side navigation. diff --git a/src/wp-includes/block-template-utils.php b/src/wp-includes/block-template-utils.php index 4dcba75c6d8af..fa7a30edaeae3 100644 --- a/src/wp-includes/block-template-utils.php +++ b/src/wp-includes/block-template-utils.php @@ -459,7 +459,7 @@ function _get_block_templates_files( $template_type, $query = array() ) { if ( ! $post_type || - ( $post_type && isset( $candidate['postTypes'] ) && in_array( $post_type, $candidate['postTypes'], true ) ) + ( isset( $candidate['postTypes'] ) && in_array( $post_type, $candidate['postTypes'], true ) ) ) { $template_files[ $template_slug ] = $candidate; } diff --git a/src/wp-includes/class-wp-walker.php b/src/wp-includes/class-wp-walker.php index 7361520cbdccc..3937d5b89dff4 100644 --- a/src/wp-includes/class-wp-walker.php +++ b/src/wp-includes/class-wp-walker.php @@ -164,7 +164,7 @@ public function display_element( $element, &$children_elements, $max_depth, $dep unset( $children_elements[ $id ] ); } - if ( isset( $newlevel ) && $newlevel ) { + if ( isset( $newlevel ) ) { // End the child delimiter. $this->end_lvl( $output, $depth, ...array_values( $args ) ); } diff --git a/tests/phpstan/baselines/booleanAnd.leftAlwaysTrue.neon b/tests/phpstan/baselines/booleanAnd.leftAlwaysTrue.neon index c64a48177e085..69e4b48b16039 100644 --- a/tests/phpstan/baselines/booleanAnd.leftAlwaysTrue.neon +++ b/tests/phpstan/baselines/booleanAnd.leftAlwaysTrue.neon @@ -28,11 +28,6 @@ parameters: identifier: booleanAnd.leftAlwaysTrue count: 1 path: ../../../src/wp-admin/themes.php - - - message: '#^Left side of && is always true\.$#' - identifier: booleanAnd.leftAlwaysTrue - count: 1 - path: ../../../src/wp-includes/block-template-utils.php - message: '#^Left side of && is always true\.$#' identifier: booleanAnd.leftAlwaysTrue diff --git a/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon b/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon index 6bd091f5adffc..99d44e7b84f43 100644 --- a/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon +++ b/tests/phpstan/baselines/booleanAnd.rightAlwaysTrue.neon @@ -28,16 +28,6 @@ parameters: identifier: booleanAnd.rightAlwaysTrue count: 1 path: ../../../src/wp-content/themes/twentynineteen/header.php - - - message: '#^Right side of && is always true\.$#' - identifier: booleanAnd.rightAlwaysTrue - count: 1 - path: ../../../src/wp-includes/block-supports/typography.php - - - message: '#^Right side of && is always true\.$#' - identifier: booleanAnd.rightAlwaysTrue - count: 1 - path: ../../../src/wp-includes/class-wp-walker.php - message: '#^Right side of && is always true\.$#' identifier: booleanAnd.rightAlwaysTrue From 3e181d38c95bd8bf47b010c9e859a9f8d0c8c368 Mon Sep 17 00:00:00 2001 From: Joe Dolson Date: Tue, 8 Sep 2026 21:08:30 +0000 Subject: [PATCH 167/363] Administration: Prevent errors in wp-tooltip.js on browsers without popover support. Add a feature gate so that the tooltip JS hides popover panels on browsers without popover support, and doesn't execute calls that can trigger errors. There are no browsers within the WordPress support matrix without popover support, but gating this feature gives users of older browsers a better experience with minimal change. Props wolf45, wildworks, adamsilverstein, joedolson. Fixes #65943. git-svn-id: https://develop.svn.wordpress.org/trunk@63543 602fd350-edb4-49c9-b593-d223f7449a82 --- src/js/_enqueues/wp/wp-tooltip.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/js/_enqueues/wp/wp-tooltip.js b/src/js/_enqueues/wp/wp-tooltip.js index 70fe2bfe7c1b2..87e4401e37fd2 100644 --- a/src/js/_enqueues/wp/wp-tooltip.js +++ b/src/js/_enqueues/wp/wp-tooltip.js @@ -8,6 +8,12 @@ */ (() => { + const supportsPopover = /** @type {boolean} */ ( Object.prototype.hasOwnProperty.call( HTMLElement.prototype, 'popover' ) ); + let hidePopover = false; + if ( ! supportsPopover ) { + hidePopover = true; + } + const popovers = /** @type {NodeListOf} */ ( document.querySelectorAll( '.wp-is-tooltip' ) ); /** @type {ReturnType} */ @@ -16,7 +22,11 @@ popovers.forEach( function( popover ) { const trigger = /** @type {HTMLButtonElement|HTMLAnchorElement|null} */ ( popover.querySelector( '.wp-tooltip__toggle' ) ); const panel = /** @type {HTMLSpanElement|null} */ ( popover.querySelector( 'span.wp-tooltip__bubble' ) ); + if ( hidePopover && panel ) { + panel.classList.add( 'hidden' ); + return; + } if ( ! trigger || ! panel ) { return; } From 46ab13cdec61c271787e83ac4831a59d58c7dff1 Mon Sep 17 00:00:00 2001 From: Joe Dolson Date: Tue, 8 Sep 2026 21:30:28 +0000 Subject: [PATCH 168/363] Multisite: Restore missing user reassignment dropdown when deleting user. Explicitly pass the `blog_id` attribute to `wp_dropdown_users` in `confirm_delete_users()` so that the dropdown renders the list of users appropriate to the current site, rather than attempting to fallback to the main site despite the limits set by the `include` parameter, which limited to members of the subsite. This resulted in an empty list in any case where there was no overlap between members of the current subset and members of the primary network site. Props mgyura, johnbillion, adamsilverstein, joedolson. Fixes #66012. git-svn-id: https://develop.svn.wordpress.org/trunk@63544 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/ms.php | 1 + tests/phpunit/tests/user/wpDropdownUsers.php | 39 ++++++++++++++++++++ 2 files changed, 40 insertions(+) diff --git a/src/wp-admin/includes/ms.php b/src/wp-admin/includes/ms.php index 56e17113653d2..155170aaf4f41 100644 --- a/src/wp-admin/includes/ms.php +++ b/src/wp-admin/includes/ms.php @@ -1003,6 +1003,7 @@ function confirm_delete_users( $users ) { 'include' => $blog_users, 'show' => 'display_name_with_login', 'id' => "reassign_user_{$details->userblog_id}_{$delete_user->ID}", + 'blog_id' => $details->userblog_id, ) ); ?> diff --git a/tests/phpunit/tests/user/wpDropdownUsers.php b/tests/phpunit/tests/user/wpDropdownUsers.php index a0b6501eb96d4..052dec318f896 100644 --- a/tests/phpunit/tests/user/wpDropdownUsers.php +++ b/tests/phpunit/tests/user/wpDropdownUsers.php @@ -201,4 +201,43 @@ public function test_role__not_in() { $this->assertStringNotContainsString( $u1->user_login, $found ); $this->assertStringContainsString( $u2->user_login, $found ); } + + /** + * @ticket 66012 + * @group ms-required + */ + public function test_multisite_users_in_blog_id() { + $blog_id = self::factory()->blog->create(); + $users = self::factory()->user->create_many( 2 ); + + add_user_to_blog( $blog_id, $users[0], 'author' ); + add_user_to_blog( $blog_id, $users[1], 'author' ); + + // The main site has no authors, so the dropdown should be empty. + $found_main_site = wp_dropdown_users( + array( + 'echo' => false, + 'role' => 'author', + 'show' => 'user_login', + 'blog_id' => get_current_blog_id(), + ) + ); + + $this->assertSame( '', $found_main_site ); + + $found_sub_site = wp_dropdown_users( + array( + 'echo' => false, + 'role' => 'author', + 'show' => 'user_login', + 'blog_id' => $blog_id, + ) + ); + + $user1 = get_userdata( $users[0] ); + $user2 = get_userdata( $users[1] ); + + $this->assertStringContainsString( $user1->user_login, $found_sub_site ); + $this->assertStringContainsString( $user2->user_login, $found_sub_site ); + } } From 2419dda9f396bf8d8d6c655a3939d072b7f7e362 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Tue, 8 Sep 2026 21:33:53 +0000 Subject: [PATCH 169/363] Administration: Wrap more one-liner inline scripts. Continuing the migration begun in r63481, the raw one-liner `SCRIPT` tags in `wp-admin/admin-footer.php`, `wp-admin/install.php` and `wp-admin/async-upload.php` now print through `wp_print_inline_script_tag()`, so `wp_inline_script_attributes` can attach a per-request nonce to these as well. The upload error handler is reworked in the process: 1. Its data now crosses into JavaScript as a single `wp_json_encode()` object rather than being interpolated into the script text, which also removes the raw interpolation of the dismiss button's generated `id`. 2. The jQuery object arrives as an argument instead of being read from the global scope four times. 3. `setTimeout()` replaces the lone `_.delay()` call, which was all the snippet wanted from Underscore. The two blocks that take an argument carry a JSDoc block naming its type, following the convention already used for the jQuery wrapper in `wp-admin/js`. These particular blocks are not reached by `lint:jsdoc`, which reads JavaScript files rather than heredocs embedded in PHP, but IDEs do check them. Developed in https://github.com/WordPress/wordpress-develop/pull/13393. Follow-up to r60263, r60520, r60681, r63481. Props thanhtinpk, westonruter. See #59446, #66033. git-svn-id: https://develop.svn.wordpress.org/trunk@63545 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/admin-footer.php | 10 +++++++++- src/wp-admin/async-upload.php | 37 ++++++++++++++++++++++++++++++++++- src/wp-admin/install.php | 29 +++++++++++++++++++-------- 3 files changed, 66 insertions(+), 10 deletions(-) diff --git a/src/wp-admin/admin-footer.php b/src/wp-admin/admin-footer.php index fef0c06bbf725..32f24e536e599 100644 --- a/src/wp-admin/admin-footer.php +++ b/src/wp-admin/admin-footer.php @@ -114,6 +114,14 @@ ?>
    - + diff --git a/src/wp-admin/async-upload.php b/src/wp-admin/async-upload.php index 5fbdd370c5c1a..0bd955e5d0428 100644 --- a/src/wp-admin/async-upload.php +++ b/src/wp-admin/async-upload.php @@ -145,7 +145,42 @@ $_FILES['async-upload']['name'] ); - echo '\n"; + $js_function = <<<'JS' + /** + * Announces the upload failure and wires up its dismiss button. + * + * @param {JQueryStatic} $ The jQuery object. + * @param {Object} args PHP exports. + * @param {string} args.speakMessage Message announced to assistive technology. + * @param {string} args.buttonSelector Selector for the notice's dismiss button. + * @return {void} + */ + ( $, { speakMessage, buttonSelector } ) => { + setTimeout( () => wp.a11y.speak( speakMessage ), 1500 ); + $( buttonSelector ).on( 'click', function () { + $( this ) + .parents( 'div.media-item' ) + .slideUp( 200, function () { + $( this ).remove(); + wp.a11y.speak( wp.i18n.__( 'Error dismissed.' ) ); + $( '#plupload-browse-button' ).trigger( 'focus' ); + } ); + } ); + } + JS; + wp_print_inline_script_tag( + sprintf( + '( %s )( jQuery, %s )', + $js_function, + wp_json_encode( + array( + 'speakMessage' => $speak_message, + 'buttonSelector' => 'button#' . $button_unique_id, + ), + JSON_HEX_TAG | JSON_UNESCAPED_SLASHES + ) + ) + ); exit; } diff --git a/src/wp-admin/install.php b/src/wp-admin/install.php index b6b7a08f2a5aa..977e231cccdf1 100644 --- a/src/wp-admin/install.php +++ b/src/wp-admin/install.php @@ -470,17 +470,30 @@ function display_setup_form( $error = null ) { } if ( ! wp_is_mobile() ) { - ?> - - - From e075d868ac2dc42ea835302f93562d36e8596b4b Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Wed, 9 Sep 2026 00:01:37 +0000 Subject: [PATCH 170/363] Tests: Remove unrelated option setup in REST settings test. Remove the `posts_per_page` update from `test_update_item_with_invalid_enum()`, which only checks rejection of an invalid default_ping_status value. Developed in: https://github.com/WordPress/wordpress-develop/pull/13450 Props wongjn. See #65819. git-svn-id: https://develop.svn.wordpress.org/trunk@63546 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/rest-api/rest-settings-controller.php | 2 -- 1 file changed, 2 deletions(-) diff --git a/tests/phpunit/tests/rest-api/rest-settings-controller.php b/tests/phpunit/tests/rest-api/rest-settings-controller.php index 5bee862ef5247..153a898947fe7 100644 --- a/tests/phpunit/tests/rest-api/rest-settings-controller.php +++ b/tests/phpunit/tests/rest-api/rest-settings-controller.php @@ -683,8 +683,6 @@ public function test_update_item_with_null() { } public function test_update_item_with_invalid_enum() { - update_option( 'posts_per_page', 9 ); - wp_set_current_user( self::$administrator ); $request = new WP_REST_Request( 'PUT', '/wp/v2/settings' ); $request->set_param( 'default_ping_status', 'open&closed' ); From 447d765c17ecbd06edf523ef434987bb29bed9e0 Mon Sep 17 00:00:00 2001 From: Joe Dolson Date: Wed, 9 Sep 2026 01:53:06 +0000 Subject: [PATCH 171/363] Administration: Prevent race condition in wp-tooltip.js delay timer. Move the timer variable `openTimeout` from the outer scope of the wrapper function to the inner scope, preventing reuse of the same timer instance by different tooltips. Props fahimmurshed, westonruter, joedolson. Fixes #65674. git-svn-id: https://develop.svn.wordpress.org/trunk@63549 602fd350-edb4-49c9-b593-d223f7449a82 --- src/js/_enqueues/wp/wp-tooltip.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/_enqueues/wp/wp-tooltip.js b/src/js/_enqueues/wp/wp-tooltip.js index 87e4401e37fd2..d00a0d5f6ae07 100644 --- a/src/js/_enqueues/wp/wp-tooltip.js +++ b/src/js/_enqueues/wp/wp-tooltip.js @@ -16,9 +16,6 @@ const popovers = /** @type {NodeListOf} */ ( document.querySelectorAll( '.wp-is-tooltip' ) ); - /** @type {ReturnType} */ - let openTimeout; - popovers.forEach( function( popover ) { const trigger = /** @type {HTMLButtonElement|HTMLAnchorElement|null} */ ( popover.querySelector( '.wp-tooltip__toggle' ) ); const panel = /** @type {HTMLSpanElement|null} */ ( popover.querySelector( 'span.wp-tooltip__bubble' ) ); @@ -31,6 +28,9 @@ return; } + /** @type {ReturnType} */ + let openTimeout; + // Show Tooltip Function (with delay to prevent flickering). const showTooltip = () => { clearTimeout( openTimeout ); From 08b0ba94f0e5050d23515742b36115994fff134e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Maneiro?= Date: Wed, 9 Sep 2026 08:37:26 +0000 Subject: [PATCH 172/363] View config: remove stale fields from wp_template. Props oandregal, ntsekouras. Part of #65981. git-svn-id: https://develop.svn.wordpress.org/trunk@63551 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/view-config.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wp-includes/view-config.php b/src/wp-includes/view-config.php index dd77063aff3f5..d972515c12438 100644 --- a/src/wp-includes/view-config.php +++ b/src/wp-includes/view-config.php @@ -566,7 +566,7 @@ function _wp_get_entity_view_config_posttype_wp_template( $data ) { 'titleField' => 'title', 'descriptionField' => 'description', 'mediaField' => 'preview', - 'fields' => array( 'author', 'active', 'slug', 'theme' ), + 'fields' => array( 'author' ), 'filters' => array(), 'showMedia' => true, ); From ad4aa65c0be41833a16160fb769591540702492d Mon Sep 17 00:00:00 2001 From: Marin Atanasov Date: Wed, 9 Sep 2026 09:49:57 +0000 Subject: [PATCH 173/363] Toolbar: Remove the light background behind the Admin Bar site icon. The site icon in the admin bar was given a `#f0f0f1` background to match the my-account (user avatar) node. Unlike avatars, which are always opaque, site icons are frequently transparent PNGs with a non-square shape, and the light square showed through them against the dark admin bar, breaking the icon's intended silhouette. Removing the background lets transparent icons blend into the toolbar. Opaque icons are unaffected, and icons that lack contrast against the admin bar are considered the site owner's responsibility, consistent with how a favicon must already work against varying browser chrome. Developed in https://github.com/WordPress/wordpress-develop/pull/13229 Props w3bdsgn, afercia, jorbin, audrasjb, r1k0, wildworks, sabernhardt, darshitrajyaguru97, fushar, ugyensupport, nkpathan, joen, adrianduffell, adamsilverstein, tyxla. Fixes #65924. git-svn-id: https://develop.svn.wordpress.org/trunk@63552 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/admin-bar.css | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wp-includes/css/admin-bar.css b/src/wp-includes/css/admin-bar.css index ad8d2c286b805..e3d6412ce746c 100644 --- a/src/wp-includes/css/admin-bar.css +++ b/src/wp-includes/css/admin-bar.css @@ -593,7 +593,6 @@ html:lang(he-il) .rtl #wpadminbar * { #wpadminbar #wp-admin-bar-site-name > .ab-item .site-icon { width: 20px; height: 20px; - background: #f0f0f1; /* matching my-account (user avatar) node's background */ border-radius: 2px; } From 3290a8d5d3ecbf4c6b2d79a464c90fdd6ebcc151 Mon Sep 17 00:00:00 2001 From: Marin Atanasov Date: Wed, 9 Sep 2026 10:33:28 +0000 Subject: [PATCH 174/363] Toolbar: Prevent the site title from showing behind the site icon on narrow screens. Below 783px the Admin Bar hides each node's text label with `text-indent`, which has no effect on the site name node because setting a site icon makes it a flex container. Depending on the browser engine, the title then renders unindented and clipped, with the absolutely positioned icon drawn on top of it. Reset the node to a block container within the `max-width: 782px` media query. Flex serves no purpose there, as the icon is taken out of flow anyway. Developed in: https://github.com/WordPress/wordpress-develop/pull/13434 Props hbhalodia, jdab, audrasjb, adamsilverstein, fushar, tyxla. Fixes #66064. git-svn-id: https://develop.svn.wordpress.org/trunk@63554 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/css/admin-bar.css | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/wp-includes/css/admin-bar.css b/src/wp-includes/css/admin-bar.css index e3d6412ce746c..61f240be3a6f5 100644 --- a/src/wp-includes/css/admin-bar.css +++ b/src/wp-includes/css/admin-bar.css @@ -934,6 +934,14 @@ html:lang(he-il) .rtl #wpadminbar * { -moz-osx-font-smoothing: grayscale; } + /* + * Flex prevents `text-indent` from hiding the site title, and is unused here + * since the icon is positioned absolutely below. + */ + #wpadminbar #wp-admin-bar-site-name.has-site-icon > .ab-item { + display: block; + } + #wpadminbar #wp-admin-bar-site-name > .ab-item .site-icon { position: absolute; top: 9px; From eddb8539f8ff03ed6c052b48a972059b3a780c72 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Wed, 9 Sep 2026 12:02:40 +0000 Subject: [PATCH 175/363] General: Add missing JS docblocks. Also, enables the JSDoc rule `jsdoc/require-jsdoc`. Part of the effort to improve JS inline documentation for 7.2. Developed in https://github.com/WordPress/wordpress-develop/pull/13439 Props afercia, westonruter. See #66033. git-svn-id: https://develop.svn.wordpress.org/trunk@63556 602fd350-edb4-49c9-b593-d223f7449a82 --- .eslintrc-jsdoc.js | 1 + Gruntfile.js | 33 +++++++++- src/js/_enqueues/admin/password-toggle.js | 9 ++- src/js/_enqueues/admin/plugin-install.js | 31 ++++++--- src/js/_enqueues/admin/privacy-tools.js | 76 +++++++++++++++++++++- src/js/_enqueues/admin/site-health.js | 15 ++++- src/js/_enqueues/admin/tags-suggest.js | 20 +++++- src/js/_enqueues/admin/user-profile.js | 31 +++++++++ src/js/_enqueues/lib/embed-template.js | 10 ++- src/js/_enqueues/lib/link.js | 14 +++- src/js/_enqueues/lib/nav-menu.js | 23 +++++++ src/js/_enqueues/lib/quicktags.js | 11 ++++ src/js/_enqueues/wp/api-request.js | 27 ++++++++ src/js/_enqueues/wp/autosave.js | 6 ++ src/js/_enqueues/wp/custom-header.js | 5 ++ src/js/_enqueues/wp/customize/controls.js | 70 +++++++++++++++++++- src/js/_enqueues/wp/customize/widgets.js | 5 ++ src/js/_enqueues/wp/editor/base.js | 9 +++ src/js/_enqueues/wp/editor/dfw.js | 12 ++++ src/js/_enqueues/wp/embed.js | 3 + src/js/_enqueues/wp/mce-view.js | 27 +++++++- src/js/_enqueues/wp/theme-plugin-editor.js | 24 ++++++- 22 files changed, 434 insertions(+), 28 deletions(-) diff --git a/.eslintrc-jsdoc.js b/.eslintrc-jsdoc.js index 34e10ed4b581e..12d2bf9a0922d 100644 --- a/.eslintrc-jsdoc.js +++ b/.eslintrc-jsdoc.js @@ -56,6 +56,7 @@ module.exports = [ 'jsdoc/require-returns-type': 'error', 'jsdoc/check-syntax': 'error', 'jsdoc/require-description': 'error', + 'jsdoc/require-jsdoc': 'error', }, }, ]; diff --git a/Gruntfile.js b/Gruntfile.js index 139cb6fb5b286..08da38fb748e2 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -154,7 +154,11 @@ module.exports = function(grunt) { ] }; - // Load grunt-* tasks. + /** + * Loads the Grunt tasks for the given dependency. + * + * @param {string} dependency The name of the Grunt task to load. + */ function loadGruntTasks( dependency ) { var contrib = key === 'contrib' ? 'contrib-' : ''; grunt.loadNpmTasks( 'grunt-' + contrib + dependency ); @@ -1797,6 +1801,11 @@ module.exports = function(grunt) { path.dirname( __dirname ) + '/.svn' ] ); + /** + * Searches for the first version control directory in the given set. + * + * @param {string[]} set Array of directory paths to check. + */ function find( set ) { var dir; @@ -1809,6 +1818,9 @@ module.exports = function(grunt) { } } + /** + * Runs all tasks. + */ function runAllTasks() { grunt.log.writeln( 'Cannot determine which files are modified as SVN and GIT are not available.' ); grunt.log.writeln( 'Running all tasks and all tests.' ); @@ -1824,6 +1836,11 @@ module.exports = function(grunt) { done(); } + /** + * Determines which precommit tasks to run based on modified files detected by version control. + * + * @param {string} type The version control type: 'git' or 'svn'. + */ function run( type ) { var command = map[ type ].split( ' ' ); @@ -1833,13 +1850,23 @@ module.exports = function(grunt) { }, function( error, result, code ) { var taskList = []; - // Callback for finding modified paths. + /** + * Checks if the given path appears in the version control status output. + * + * @param {string} path The path to check. + * @return {boolean} True if the path is found, false otherwise. + */ function testPath( path ) { var regex = new RegExp( ' ' + path + '$', 'm' ); return regex.test( result.stdout ); } - // Callback for finding modified files by extension. + /** + * Checks if files with the given extension appear in the version control status output. + * + * @param {string} extension The file extension to check for. + * @return {boolean} True if the file with the given extension is found, false otherwise. + */ function testExtension( extension ) { var regex = new RegExp( '\.' + extension + '$', 'm' ); return regex.test( result.stdout ); diff --git a/src/js/_enqueues/admin/password-toggle.js b/src/js/_enqueues/admin/password-toggle.js index 5bfaa3b122c01..bdd98f8bb7359 100644 --- a/src/js/_enqueues/admin/password-toggle.js +++ b/src/js/_enqueues/admin/password-toggle.js @@ -1,10 +1,12 @@ +/** + * @output wp-admin/js/password-toggle.js + */ + /** * Adds functionality for password visibility buttons to toggle between text and password input types. * * @since 6.3.0 - * @output wp-admin/js/password-toggle.js */ - ( function () { var toggleElements, status, input, icon, label, __ = wp.i18n.__; @@ -15,6 +17,9 @@ toggle.addEventListener( 'click', togglePassword ); } ); + /** + * Toggles the password input field visibility. + */ function togglePassword() { status = this.getAttribute( 'data-toggle' ); input = this.parentElement.children.namedItem( 'pwd' ); diff --git a/src/js/_enqueues/admin/plugin-install.js b/src/js/_enqueues/admin/plugin-install.js index 1e994763e1fda..b79931a7e7791 100644 --- a/src/js/_enqueues/admin/plugin-install.js +++ b/src/js/_enqueues/admin/plugin-install.js @@ -6,6 +6,11 @@ /* global tb_click, tb_remove, tb_position */ +/** + * Initializes the plugin install screens. + * + * @param {JQueryStatic} $ The jQuery object. + */ jQuery( function( $ ) { var tbWindow, @@ -78,6 +83,9 @@ jQuery( function( $ ) { $focusedBefore.trigger( 'focus' ); }); + /** + * Initializes the plugin details modal dialog after the iframe has fully loaded. + */ function iframeLoaded() { var $iframe = tbWindow.find( '#TB_iframeContent' ); @@ -109,8 +117,9 @@ jQuery( function( $ ) { }); } - /* - * Get the tabbable elements and detach/attach the keydown event. + /** + * Gets the tabbable elements and detaches/attaches the keydown event. + * * Called after the iframe has fully loaded so we have all the elements we need. * Called again each time a Tab gets clicked. * @todo Consider to implement a WordPress general utility for this and don't use jQuery UI. @@ -133,7 +142,11 @@ jQuery( function( $ ) { }); } - // Constrain tabbing within the plugin modal dialog. + /** + * Constrains tabbing within the plugin modal dialog. + * + * @param {JQuery.Event} event The keydown event. + */ function constrainTabbing( event ) { if ( 9 !== event.which ) { return; @@ -148,11 +161,13 @@ jQuery( function( $ ) { } } - /* - * Open the Plugin details modal. The event is delegated to get also the links - * in the plugins search tab, after the Ajax search rebuilds the HTML. It's - * delegated on the closest ancestor and not on the body to avoid conflicts - * with other handlers, see Trac ticket #43082. + /** + * Opens the Plugin details modal. + * + * The event is delegated to get also the links in the plugins search tab, + * after the Ajax search rebuilds the HTML. It's delegated on the closest + * ancestor and not on the body to avoid conflicts with other handlers, see + * Trac ticket #43082. */ $( '.wrap' ).on( 'click', '.thickbox.open-plugin-details-modal', function( e ) { // The `data-title` attribute is used only in the Plugin screens. diff --git a/src/js/_enqueues/admin/privacy-tools.js b/src/js/_enqueues/admin/privacy-tools.js index 480766ad051d7..df24538ffaefc 100644 --- a/src/js/_enqueues/admin/privacy-tools.js +++ b/src/js/_enqueues/admin/privacy-tools.js @@ -1,19 +1,34 @@ /** - * Interactions used by the User Privacy tools in WordPress. - * * @output wp-admin/js/privacy-tools.js */ -// Privacy request action handling. +/** + * Sets the interactions used by the User Privacy tools in WordPress. + * + * @param {jQueryStatic} $ The jQuery object. + */ jQuery( function( $ ) { var __ = wp.i18n.__, copiedNoticeTimeout; + /** + * Sets the state of the action. + * + * @param {jQuery} $action The action to set the state for. + * @param {string} state The state to set the action to. + * @return {void} + */ function setActionState( $action, state ) { $action.children().addClass( 'hidden' ); $action.children( '.' + state ).removeClass( 'hidden' ); } + /** + * Clears any results row after the request row. + * + * @param {jQuery} $requestRow The request row to clear results for. + * @return {void} + */ function clearResultsAfterRow( $requestRow ) { $requestRow.removeClass( 'has-request-results' ); @@ -22,6 +37,15 @@ jQuery( function( $ ) { } } + /** + * Appends a results row after the request row. + * + * @param {jQuery} $requestRow The request row to append the results after. + * @param {string} classes The classes to add to the results row. + * @param {string} summaryMessage The summary message to display in the results row. + * @param {string[]} additionalMessages Additional messages to display in the results row. + * @return {void} + */ function appendResultsAfterRow( $requestRow, classes, summaryMessage, additionalMessages ) { var itemList = '', resultRowClasses = 'request-results'; @@ -76,6 +100,12 @@ jQuery( function( $ ) { clearResultsAfterRow( $requestRow ); setExportProgress( 0 ); + /** + * Handles a successful export. + * + * @param {string} zipUrl The URL of the generated ZIP file, if available. + * @return {void} + */ function onExportDoneSuccess( zipUrl ) { var summaryMessage = __( 'This user’s personal data export link was sent.' ); @@ -96,6 +126,12 @@ jQuery( function( $ ) { setTimeout( function() { $rowActions.removeClass( 'processing' ); }, 500 ); } + /** + * Handles an export failure. + * + * @param {string} errorMessage The error message to display. + * @return {void} + */ function onExportFailure( errorMessage ) { var summaryMessage = __( 'An error occurred while attempting to export personal data.' ); @@ -108,6 +144,12 @@ jQuery( function( $ ) { setTimeout( function() { $rowActions.removeClass( 'processing' ); }, 500 ); } + /** + * Updates the progress of the export process. + * + * @param {number} exporterIndex The index of the exporter to process. + * @return {void} + */ function setExportProgress( exporterIndex ) { var progress = ( exportersCount > 0 ? exporterIndex / exportersCount : 0 ), progressString = Math.round( progress * 100 ).toString() + '%'; @@ -115,6 +157,13 @@ jQuery( function( $ ) { $progress.html( progressString ); } + /** + * Performs the next export request. + * + * @param {number} exporterIndex The index of the exporter to process. + * @param {number} pageIndex The index of the page to process for the current exporter. + * @return {void} + */ function doNextExport( exporterIndex, pageIndex ) { $.ajax( { @@ -181,6 +230,11 @@ jQuery( function( $ ) { clearResultsAfterRow( $requestRow ); setErasureProgress( 0 ); + /** + * Handles a successful erasure. + * + * @return {void} + */ function onErasureDoneSuccess() { var summaryMessage = __( 'No personal data was found for this user.' ), classes = 'notice-success'; @@ -207,6 +261,9 @@ jQuery( function( $ ) { setTimeout( function() { $rowActions.removeClass( 'processing' ); }, 500 ); } + /** + * Handles an erasure failure. + */ function onErasureFailure() { var summaryMessage = __( 'An error occurred while attempting to find and erase personal data.' ); @@ -217,6 +274,12 @@ jQuery( function( $ ) { setTimeout( function() { $rowActions.removeClass( 'processing' ); }, 500 ); } + /** + * Updates the progress of the erasure process. + * + * @param {number} eraserIndex The index of the eraser to process. + * @return {void} + */ function setErasureProgress( eraserIndex ) { var progress = ( erasersCount > 0 ? eraserIndex / erasersCount : 0 ), progressString = Math.round( progress * 100 ).toString() + '%'; @@ -224,6 +287,13 @@ jQuery( function( $ ) { $progress.html( progressString ); } + /** + * Performs the next erasure request. + * + * @param {number} eraserIndex The index of the eraser to process. + * @param {number} pageIndex The index of the page to process for the current eraser. + * @return {void} + */ function doNextErasure( eraserIndex, pageIndex ) { $.ajax({ url: window.ajaxurl, diff --git a/src/js/_enqueues/admin/site-health.js b/src/js/_enqueues/admin/site-health.js index 98aaedc427c0e..dc9107a3ebc2f 100644 --- a/src/js/_enqueues/admin/site-health.js +++ b/src/js/_enqueues/admin/site-health.js @@ -1,11 +1,14 @@ /** - * Interactions used by the Site Health modules in WordPress. - * * @output wp-admin/js/site-health.js */ /* global ajaxurl, ClipboardJS, SiteHealth, wp */ +/** + * Handles the interactions used by the Site Health modules in WordPress. + * + * @param {JQueryStatic} $ The jQuery object. + */ jQuery( function( $ ) { var __ = wp.i18n.__, @@ -393,6 +396,9 @@ jQuery( function( $ ) { } } + /** + * Get the sizes of the directories in the Site Health Info section. + */ function getDirectorySizes() { var timestamp = ( new Date().getTime() ); @@ -434,6 +440,11 @@ jQuery( function( $ ) { } ); } + /** + * Updates the directory sizes in the Site Health Info section. + * + * @param {Object} data The directory sizes data. + */ function updateDirSizes( data ) { var copyButton = $( 'button.button.copy-button' ); var clipboardText = copyButton.attr( 'data-clipboard-text' ); diff --git a/src/js/_enqueues/admin/tags-suggest.js b/src/js/_enqueues/admin/tags-suggest.js index 08bea1464bbbe..e7469cfea2286 100644 --- a/src/js/_enqueues/admin/tags-suggest.js +++ b/src/js/_enqueues/admin/tags-suggest.js @@ -1,7 +1,9 @@ /** - * Default settings for jQuery UI Autocomplete for use with non-hierarchical taxonomies. - * * @output wp-admin/js/tags-suggest.js + */ + +/** + * Default settings for jQuery UI Autocomplete for use with non-hierarchical taxonomies. * * @param {JQueryStatic} $ The jQuery object. */ @@ -12,16 +14,28 @@ _n = wp.i18n._n, sprintf = wp.i18n.sprintf; + /** + * Splits a string into an array of terms based on the separator. + * + * @param {string} val The string to split. + * @return {string[]} An array of terms. + */ function split( val ) { return val.split( new RegExp( separator + '\\s*' ) ); } + /** + * Gets the last term from a string based on the separator. + * + * @param {string} term The string to get the last term from. + * @return {string} The last term. + */ function getLast( term ) { return split( term ).pop(); } /** - * Add UI Autocomplete to an input or textarea element with presets for use + * Adds UI Autocomplete to an input or textarea element with presets for use * with non-hierarchical taxonomies. * * Example: `$( element ).wpTagsSuggest( options )`. diff --git a/src/js/_enqueues/admin/user-profile.js b/src/js/_enqueues/admin/user-profile.js index e6b79f616fbc3..dc0b5e8ccd6e0 100644 --- a/src/js/_enqueues/admin/user-profile.js +++ b/src/js/_enqueues/admin/user-profile.js @@ -32,6 +32,17 @@ isSafari = window.safari !== 'undefined' && typeof window.safari === 'object', isFirefox = ua.indexOf( 'firefox' ) !== -1; + /** + * Generates a password and updates the password input field. + * + * If zxcvbn is not yet loaded, it will wait and try again. If the password + * input field is empty or the password wrapper is open, it will set the + * password to the generated value. If the user has already entered a + * password, it will check the strength of that password. It also binds + * the toggle button to show or hide the password and sets the initial state + * of the toggle button based on whether the password should be masked or + * not. Finally, it updates the label for confirming weak passwords. + */ function generatePassword() { if ( typeof zxcvbn !== 'function' ) { setTimeout( generatePassword, 50 ); @@ -67,6 +78,9 @@ $( '#pw-weak-text-label' ).text( __( 'Confirm use of weak password' ) ); } + /** + * Binds the password input field to update the current password and refresh the password strength area when the user types in the field. + */ function bindPass1() { currentPass = $pass1.val(); @@ -89,6 +103,11 @@ bindCapsLockWarning( $pass1 ); } + /** + * Resets the toggle button to show or hide the password. + * + * @param {boolean} show Whether to show the password or not. + */ function resetToggle( show ) { $toggleButton .attr({ @@ -102,6 +121,9 @@ .addClass( show ? 'dashicons-visibility' : 'dashicons-hidden' ); } + /** + * Binds the toggle button to show or hide the password. Also ensures that the password input type is set to password when the form is submitted. + */ function bindToggleButton() { if ( !! $toggleButton ) { // Do not rebind. @@ -193,6 +215,9 @@ $this.before( resultDiv ); } + /** + * Initializes the password form, including the password strength meter, weak password checkbox, and show/hide password toggle button. + */ function bindPasswordForm() { var $generateButton, $cancelButton; @@ -309,6 +334,9 @@ }); } + /** + * Sets CSS classes to the password strength results based on the password strength. + */ function check_pass_strength() { var pass1 = $('#pass1').val(), strength; @@ -414,6 +442,9 @@ return event.getModifierState( 'CapsLock' ); } + /** + * Toggles the visibility of the weak password checkbox. + */ function showOrHideWeakPasswordCheckbox() { var passStrengthResult = $('#pass-strength-result'); diff --git a/src/js/_enqueues/lib/embed-template.js b/src/js/_enqueues/lib/embed-template.js index b053be7cc88ee..e43ef97b8fe96 100644 --- a/src/js/_enqueues/lib/embed-template.js +++ b/src/js/_enqueues/lib/embed-template.js @@ -5,8 +5,8 @@ /** * IIFE setup function. * - * @param {Window} window Global window object. - * @param {Document} document Global document object. + * @param {Window} window The global window object. + * @param {Document} document The global document object. */ (function ( window, document ) { 'use strict'; @@ -17,6 +17,12 @@ secretTimeout, resizing; + /** + * Sends a message to the parent window. + * + * @param {string} message The message type (e.g., 'height', 'link'). + * @param {*} value The message value. Type depends on message (number for height, string for link). + */ function sendEmbedMessage( message, value ) { window.parent.postMessage( { message: message, diff --git a/src/js/_enqueues/lib/link.js b/src/js/_enqueues/lib/link.js index a2500a9069648..0d1a5a923e978 100644 --- a/src/js/_enqueues/lib/link.js +++ b/src/js/_enqueues/lib/link.js @@ -2,8 +2,15 @@ * @output wp-includes/js/wplink.js */ - /* global wpLink */ +/* global wpLink */ +/** + * The WordPress Link Modal dialog. + * + * @param {JQueryStatic} $ The jQuery object. + * @param {Object} wpLinkL10n The WordPress Link localization object. + * @param {Object} wp The WordPress global object. + */ ( function( $, wpLinkL10n, wp ) { var editor, searchTimer, River, Query, correctedURL, emailRegexp = /^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,63}$/i, @@ -12,6 +19,11 @@ rivers = {}, isTouch = ( 'ontouchend' in document ); + /** + * Gets the currently selected link in the editor. + * + * @return {JQuery} The currently selected link element. + */ function getLink() { if ( editor ) { return editor.$( 'a[data-wplink-edit="true"]' ); diff --git a/src/js/_enqueues/lib/nav-menu.js b/src/js/_enqueues/lib/nav-menu.js index f70ca7c99fe3a..5e94a2b34f3c9 100644 --- a/src/js/_enqueues/lib/nav-menu.js +++ b/src/js/_enqueues/lib/nav-menu.js @@ -1013,6 +1013,11 @@ } }); + /** + * Updates the shared variables used to determine the depth of the menu item being moved. + * + * @param {Object} ui The jQuery UI object for the menu item being moved. + */ function updateSharedVars(ui) { var depth; @@ -1033,17 +1038,35 @@ maxDepth = 0; } + /** + * Updates the current depth of the menu item being moved. + * + * @param {Object} ui The jQuery UI object for the menu item being moved. + * @param {number} depth The new depth of the menu item being moved. + * @return {void} + */ function updateCurrentDepth(ui, depth) { ui.placeholder.updateDepthClass( depth, currentDepth ); currentDepth = depth; } + /** + * Determines the initial menu max depth class on the body element. + * + * @return {number} The initial menu max depth. + */ function initialMenuMaxDepth() { if( ! body[0].className ) return 0; var match = body[0].className.match(/menu-max-depth-(\d+)/); return match && match[1] ? parseInt( match[1], 10 ) : 0; } + /** + * Updates the menu max depth class on the body element. + * + * @param {number} depthChange The change in depth of the menu item being moved. + * @return {void} + */ function updateMenuMaxDepth( depthChange ) { var depth, newDepth = menuMaxDepth; if ( depthChange === 0 ) { diff --git a/src/js/_enqueues/lib/quicktags.js b/src/js/_enqueues/lib/quicktags.js index 621fab1058315..bdb978750e549 100644 --- a/src/js/_enqueues/lib/quicktags.js +++ b/src/js/_enqueues/lib/quicktags.js @@ -233,6 +233,12 @@ window.edToolbar = function(){}; t.init(); }; + /** + * Escapes HTML special characters in a string. + * + * @param {string} text The string to escape. + * @return {string} The escaped string. + */ function _escape( text ) { text = text || ''; text = text.replace( /&([^#])(?![a-z1-4]{1,8};)/gi, '&$1' ); @@ -248,6 +254,11 @@ window.edToolbar = function(){}; qt._buttonsInit = function( id ) { var t = this; + /** + * Initializes the Quicktags buttons for a specific instance. + * + * @param {string} instanceId The ID of the Quicktags instance to initialize buttons for. + */ function _init( instanceId ) { var canvas, name, settings, theButtons, html, ed, id, i, use, defaults = ',strong,em,link,block,del,ins,img,ul,ol,li,code,more,close,'; diff --git a/src/js/_enqueues/wp/api-request.js b/src/js/_enqueues/wp/api-request.js index a72fd08b376de..4762a37f658e2 100644 --- a/src/js/_enqueues/wp/api-request.js +++ b/src/js/_enqueues/wp/api-request.js @@ -21,11 +21,38 @@ ( function( $ ) { var wpApiSettings = window.wpApiSettings; + /** + * Makes an API request. + * + * @param {Object} options The options for the API request. + * @param {string} [options.url] The full URL for the request. + * @param {string} [options.path] The API path (e.g., 'wp/v2/posts'). Used if url is not provided. + * @param {string} [options.namespace] The API namespace (e.g., 'wp/v2'). Used with endpoint to build path. + * @param {string} [options.endpoint] The API endpoint (e.g., 'posts'). Used with namespace to build path. + * @param {string} [options.method] The HTTP method (GET, POST, PUT, DELETE, etc.). + * @param {Object} [options.data] The request data to send. + * @param {string} [options.data._wpnonce] Nonce for security. + * @param {Object} [options.headers] Custom headers to include in the request. + * @return {JQueryXHR} The jQuery XHR object. + */ function apiRequest( options ) { options = apiRequest.buildAjaxOptions( options ); return apiRequest.transport( options ); } + /** + * Builds the options for the jQuery.ajax request. + * + * @param {Object} options The options for the API request. + * @param {string} [options.url] The full URL for the request. + * @param {string} [options.path] The API path (e.g., 'wp/v2/posts'). Used if url is not provided. + * @param {string} [options.namespace] The API namespace (e.g., 'wp/v2'). Used with endpoint to build path. + * @param {string} [options.endpoint] The API endpoint (e.g., 'posts'). Used with namespace to build path. + * @param {string} [options.method] The HTTP method (GET, POST, PUT, DELETE, etc.). + * @param {Object} [options.data] The request data to send. + * @param {Object} [options.headers] Custom headers to include in the request. + * @return {Object} The options for the jQuery.ajax request. + */ apiRequest.buildAjaxOptions = function( options ) { var url = options.url; var path = options.path; diff --git a/src/js/_enqueues/wp/autosave.js b/src/js/_enqueues/wp/autosave.js index 35d7a055ed98e..4ad4e7fe56133 100644 --- a/src/js/_enqueues/wp/autosave.js +++ b/src/js/_enqueues/wp/autosave.js @@ -449,6 +449,12 @@ window.autosave = function() { * @return {boolean} True if the strings are the same. */ function compare( str1, str2 ) { + /** + * Removes all whitespace characters from a string. + * + * @param {string} string The string to remove whitespace from. + * @return {string} The string without whitespace characters. + */ function removeSpaces( string ) { return string.toString().replace(/[\x20\t\r\n\f]+/g, ''); } diff --git a/src/js/_enqueues/wp/custom-header.js b/src/js/_enqueues/wp/custom-header.js index 1771ce7505544..7d4fa98d7cc53 100644 --- a/src/js/_enqueues/wp/custom-header.js +++ b/src/js/_enqueues/wp/custom-header.js @@ -244,6 +244,11 @@ BaseHandler.extend = function( protoProps ) { var prop; + /** + * Creates a custom handler instance. + * + * @return {CustomHandler} A custom handler instance, when called with new. + */ function CustomHandler() { var result = BaseHandler.apply( this, arguments ); return result; diff --git a/src/js/_enqueues/wp/customize/controls.js b/src/js/_enqueues/wp/customize/controls.js index 2a1818b8bba42..94693163c0240 100644 --- a/src/js/_enqueues/wp/customize/controls.js +++ b/src/js/_enqueues/wp/customize/controls.js @@ -843,6 +843,9 @@ options ); + /** + * Cancels the reminder, preventing the button from being highlighted. + */ function cancelReminder() { canceled = true; } @@ -1981,6 +1984,9 @@ api.section( 'wporg_themes' ).focus(); }); + /** + * Updates the section header to reflect the expanded state. + */ function updateSelectedState() { var el = section.headerContainer.find( '.customize-themes-section-title' ); el.toggleClass( 'selected', section.expanded() ); @@ -2025,6 +2031,9 @@ return; } + /** + * Expands the section. + */ function expand() { // Try to load controls if none are loaded yet. @@ -2625,11 +2634,21 @@ .fadeIn( 'fast' ) .focus(); + /** + * Disables the switch buttons if the theme cannot be switched to. + * + * @return {boolean} True if the switch buttons should be disabled, false otherwise. + */ function disableSwitchButtons() { return ! panel.canSwitchTheme( theme.id ); } // Temporary special function since supplying SFTP credentials does not work yet. See #42184. + /** + * Disables the install buttons if the theme cannot be installed or if filesystem credentials are needed. + * + * @return {boolean} True if the install buttons should be disabled, false otherwise. + */ function disableInstallButtons() { return disableSwitchButtons() || false === api.settings.theme._canInstall || true === api.settings.theme._filesystemCredentialsNeeded; } @@ -3137,6 +3156,9 @@ } ) ); } + /** + * Toggles the theme switch unavailable notification based on whether switching is possible. + */ function toggleDisabledNotifications() { if ( panel.canSwitchTheme() ) { panel.notifications.remove( 'theme_switch_unavailable' ); @@ -5215,14 +5237,28 @@ ready: function() { var control = this, panel = api.panel( 'themes' ); + /** + * Disables the preview buttons if the theme cannot be switched to. + * + * @return {boolean} True if the preview buttons should be disabled, false otherwise. + */ function disableSwitchButtons() { return ! panel.canSwitchTheme( control.params.theme.id ); } // Temporary special function since supplying SFTP credentials does not work yet. See #42184. + /** + * Disables the install buttons if the theme cannot be installed or if filesystem credentials are needed. + * + * @return {boolean} True if the install buttons should be disabled, false otherwise. + */ function disableInstallButtons() { return disableSwitchButtons() || false === api.settings.theme._canInstall || true === api.settings.theme._filesystemCredentialsNeeded; } + + /** + * Updates the state of the preview and install buttons based on whether the theme can be switched to or installed. + */ function updateButtons() { control.container.find( 'button.preview, button.preview-theme' ).toggleClass( 'disabled', disableSwitchButtons() ); control.container.find( 'button.theme-install' ).toggleClass( 'disabled', disableInstallButtons() ); @@ -7336,6 +7372,9 @@ updateButtonsState(); section.active.bind( updateButtonsState ); + /** + * Highlights the schedule button to remind the user to schedule the changes. + */ function highlightScheduleButton() { if ( ! cancelScheduleButtonReminder ) { cancelScheduleButtonReminder = api.utils.highlightButton( btnWrapper, { @@ -7350,6 +7389,10 @@ } ); } } + + /** + * Cancels the highlight reminder for the schedule button. + */ function cancelHighlightScheduleButton() { if ( cancelScheduleButtonReminder ) { cancelScheduleButtonReminder(); @@ -7591,6 +7634,11 @@ api.state( 'saving' ).set( true ); + /** + * Captures a setting as modified during the save process. + * + * @param {wp.customize.Setting} setting The setting that was modified. + */ function captureSettingModifiedDuringSave( setting ) { modifiedWhileSaving[ setting.id ] = true; } @@ -8933,6 +8981,11 @@ (function() { var isInsideIframe = false; + /** + * Determine whether the Customizer is in a clean state. + * + * @return {boolean} True if the Customizer is in a clean state, false otherwise. + */ function isCleanState() { var defaultChangesetStatus; @@ -8969,6 +9022,9 @@ isInsideIframe = true; }); + /** + * Starts prompting the user before unloading the Customizer if there are unsaved changes. + */ function startPromptingBeforeUnload() { api.unbind( 'change', startPromptingBeforeUnload ); api.state( 'selectedChangesetStatus' ).unbind( startPromptingBeforeUnload ); @@ -8988,6 +9044,11 @@ api.state( 'selectedChangesetStatus' ).bind( startPromptingBeforeUnload ); api.state( 'selectedChangesetDate' ).bind( startPromptingBeforeUnload ); + /** + * Requests to close the Customizer, prompting the user to save changes if necessary. + * + * @return {JQuery.Promise} A promise that resolves if the user is cleared to close the Customizer, or rejects if the user cancels the close. + */ function requestClose() { var clearedToClose = $.Deferred(), dismissAutoSave = false, dismissLock = false; @@ -9377,12 +9438,19 @@ api.previewer.send( 'edit-shortcut-visibility', visibility ); } ); - // Autosave changeset. + /** + * Starts autosaving changeset when a change is made. + */ function startAutosaving() { var timeoutId, updateChangesetWithReschedule, scheduleChangesetUpdate, updatePending = false; api.unbind( 'change', startAutosaving ); // Ensure startAutosaving only fires once. + /** + * Handles changes to the saved state of the changeset. + * + * @param {boolean} isSaved Whether the changeset is saved or not. + */ function onChangeSaved( isSaved ) { if ( ! isSaved && ! api.settings.changeset.autosaved ) { api.settings.changeset.autosaved = true; // Once a change is made then autosaving kicks in. diff --git a/src/js/_enqueues/wp/customize/widgets.js b/src/js/_enqueues/wp/customize/widgets.js index 5f8faf29709dd..5af1e8007de83 100644 --- a/src/js/_enqueues/wp/customize/widgets.js +++ b/src/js/_enqueues/wp/customize/widgets.js @@ -2358,6 +2358,11 @@ */ function focusConstructWithBreadcrumb( focusConstruct, returnConstruct ) { focusConstruct.focus(); + /** + * Determines whether to return focus to the returnConstruct after the focusConstruct is collapsed. + * + * @param {boolean} isExpanded Whether the focusConstruct is expanded. + */ function onceCollapsed( isExpanded ) { if ( ! isExpanded ) { focusConstruct.expanded.unbind( onceCollapsed ); diff --git a/src/js/_enqueues/wp/editor/base.js b/src/js/_enqueues/wp/editor/base.js index c2c264e3f8045..0c3485ca7d661 100644 --- a/src/js/_enqueues/wp/editor/base.js +++ b/src/js/_enqueues/wp/editor/base.js @@ -4,6 +4,12 @@ window.wp = window.wp || {}; +/** + * The editor functionality. + * + * @param {JQueryStatic} $ The jQuery object. + * @param {Object} wp The WordPress global object. + */ ( function( $, wp ) { wp.editor = wp.editor || {}; @@ -17,6 +23,9 @@ window.wp = window.wp || {}; var tinymce, $$, exports = {}; + /** + * Initializes the editor utility functions. + */ function init() { if ( ! tinymce && window.tinymce ) { tinymce = window.tinymce; diff --git a/src/js/_enqueues/wp/editor/dfw.js b/src/js/_enqueues/wp/editor/dfw.js index 3e5276ed3ef4f..d6a563e8f7872 100644 --- a/src/js/_enqueues/wp/editor/dfw.js +++ b/src/js/_enqueues/wp/editor/dfw.js @@ -1360,6 +1360,12 @@ setTimeout( function() { var position = document.activeElement.compareDocumentPosition( $editor.get( 0 ) ); + /** + * Determines whether the passed element has focus. + * + * @param {jQuery} $el The element to check for focus. + * @return {boolean} True if the element has focus, false otherwise. + */ function hasFocus( $el ) { return $.contains( $el.get( 0 ), document.activeElement ); } @@ -1524,10 +1530,16 @@ $document.on( 'tinymce-editor-init.focus', function( event, editor ) { var mceBind, mceUnbind; + /** + * Tracks when the TinyMCE editor receives focus. + */ function focus() { editorHasFocus = true; } + /** + * Tracks when the TinyMCE editor loses focus. + */ function blur() { editorHasFocus = false; } diff --git a/src/js/_enqueues/wp/embed.js b/src/js/_enqueues/wp/embed.js index 724daa3283e93..5522fb824a38c 100644 --- a/src/js/_enqueues/wp/embed.js +++ b/src/js/_enqueues/wp/embed.js @@ -87,6 +87,9 @@ } }; + /** + * Initializes the embed script on DOMContentLoaded. + */ function onLoad() { var iframes = document.querySelectorAll( 'iframe.wp-embedded-content' ), i, source, secret; diff --git a/src/js/_enqueues/wp/mce-view.js b/src/js/_enqueues/wp/mce-view.js index 01dbaedf1f122..4bbd71efc31f0 100644 --- a/src/js/_enqueues/wp/mce-view.js +++ b/src/js/_enqueues/wp/mce-view.js @@ -4,7 +4,7 @@ /* global tinymce */ -/* +/** * The TinyMCE view API. * * Note: this API is "experimental" meaning that it will probably change @@ -25,6 +25,11 @@ * | | |- ... * |- registered view * | |- ... + * + * @param {Window} window The global window object. + * @param {Object} wp The WordPress global object. + * @param {Object} shortcode The shortcode API. + * @param {JQueryStatic} $ The jQuery object. */ ( function( window, wp, shortcode, $ ) { 'use strict'; @@ -615,6 +620,9 @@ iframeDoc.close(); + /** + * Resizes the iframe to fit its content. + */ function resize() { var $iframe; @@ -643,6 +651,9 @@ }, 3000 ); } + /** + * Adds a MutationObserver to the iframe's body to watch for changes and resize accordingly. + */ function addObserver() { observer = new MutationObserver( _.debounce( resize, 100 ) ); @@ -763,15 +774,27 @@ } ); } )( window, window.wp, window.wp.shortcode, window.jQuery ); -/* +/** * The WordPress core TinyMCE views. + * * Views for the gallery, audio, video, playlist and embed shortcodes, * and a view for embeddable URLs. + * + * @param {Window} window The global window object. + * @param {Object} views The wp.mce.views object. + * @param {Object} media The wp.media object. + * @param {JQueryStatic} $ The jQuery object. */ ( function( window, views, media, $ ) { var base, gallery, av, embed, schema, parser, serializer; + /** + * Verifies that a given string is valid HTML. + * + * @param {string} string The string to verify. + * @return {string} The verified string. + */ function verifyHTML( string ) { var settings = {}; diff --git a/src/js/_enqueues/wp/theme-plugin-editor.js b/src/js/_enqueues/wp/theme-plugin-editor.js index 88c985be42012..74e0634f94e45 100644 --- a/src/js/_enqueues/wp/theme-plugin-editor.js +++ b/src/js/_enqueues/wp/theme-plugin-editor.js @@ -418,6 +418,9 @@ wp.themePluginEditor = (function( $ ) { editor = wp.codeEditor.initialize( $( '#newcontent' ), codeEditorSettings ); editor.codemirror.on( 'change', component.onChange ); + /** + * Handles the save shortcut (Ctrl+S / Cmd+S). + */ function onSaveShortcut() { component.form.trigger( 'submit' ); } @@ -601,10 +604,22 @@ wp.themePluginEditor = (function( $ ) { var flag = false, _char = event.key; + /** + * Determines whether a character is a printable character. + * + * @param {string} str The character to check. + * @return {boolean} True if the character is printable, false otherwise. + */ function isPrintableCharacter(str) { return str.length === 1 && str.match(/\S/); } + /** + * Handles printable character key press. + * + * @param {TreeitemLink} item The tree item link instance. + * @return {void} + */ function printableCharacter(item) { if (_char == '*') { item.tree.expandAllSiblingItems(item); @@ -808,7 +823,14 @@ wp.themePluginEditor = (function( $ ) { }; TreeLinks.prototype.init = function () { - + /** + * Finds all treeitems and groups and creates object instances. + * + * @param {Element} node The DOM node to search for treeitems. + * @param {TreeLinks} tree The TreeLinks instance. + * @param {TreeitemLink|boolean} group The parent TreeitemLink instance or false if there is no parent. + * @return {void} + */ function findTreeitems(node, tree, group) { var elem = node.firstElementChild; From 83ba0ce32b7ef7ae7e90a78da516f44702444661 Mon Sep 17 00:00:00 2001 From: Jonathan Desrosiers Date: Wed, 9 Sep 2026 12:35:58 +0000 Subject: [PATCH 176/363] Build/Test Tools: Increase PHPUnit workflow `timeout-minutes`. There has been a considerable number of PHPUnit test workflow runs recently that have been hitting the default configured `timeout-minutes` value of `20`. This increases the value to `30` to avoid runs being cancelled prematurely until the speed of the test suite can be improved. See #65845. git-svn-id: https://develop.svn.wordpress.org/trunk@63557 602fd350-edb4-49c9-b593-d223f7449a82 --- .github/workflows/reusable-phpunit-tests-v3.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/reusable-phpunit-tests-v3.yml b/.github/workflows/reusable-phpunit-tests-v3.yml index 459ad5fda8823..6348d2a5cfbbf 100644 --- a/.github/workflows/reusable-phpunit-tests-v3.yml +++ b/.github/workflows/reusable-phpunit-tests-v3.yml @@ -154,7 +154,7 @@ jobs: phpunit-tests: name: ${{ ( inputs.phpunit-test-groups || inputs.coverage-report ) && format( 'PHP {0} with ', inputs.php ) || '' }} ${{ 'mariadb' == inputs.db-type && 'MariaDB' || 'MySQL' }} ${{ inputs.db-version }}${{ inputs.multisite && ' multisite' || '' }}${{ inputs.db-innovation && ' (innovation release)' || '' }}${{ inputs.memcached && ' with memcached' || '' }}${{ inputs.report && ' (test reporting enabled)' || '' }} ${{ 'example.org' != inputs.tests-domain && inputs.tests-domain || '' }} runs-on: ${{ vars.RUNNERS_NAME || inputs.os }} - timeout-minutes: ${{ inputs.coverage-report && 120 || inputs.php == '8.4' && 30 || 20 }} + timeout-minutes: ${{ inputs.coverage-report && 120 || 30 }} permissions: contents: read From 0f36f52ddf1733ff3acaaae76dee920491c3d0eb Mon Sep 17 00:00:00 2001 From: Jonathan Desrosiers Date: Wed, 9 Sep 2026 12:39:32 +0000 Subject: [PATCH 177/363] Build/Test Tools: Increase Gutenberg artifact retention. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It’s common for nuanced workflow run failures to be investigated over the course of several days following the initial run. In these cases, the entire workflow must be rerun even one only one or two jobs had failed because the artifact has expired. This increases the artifact retention of the built Gutenberg asset from `1` day to `7` to help with this workflow. See #65845. git-svn-id: https://develop.svn.wordpress.org/trunk@63558 602fd350-edb4-49c9-b593-d223f7449a82 --- .github/workflows/reusable-prepare-gutenberg.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/reusable-prepare-gutenberg.yml b/.github/workflows/reusable-prepare-gutenberg.yml index 83c22cffb1b55..2d2c407ecdc7a 100644 --- a/.github/workflows/reusable-prepare-gutenberg.yml +++ b/.github/workflows/reusable-prepare-gutenberg.yml @@ -106,4 +106,4 @@ jobs: path: gutenberg/ if-no-files-found: error include-hidden-files: true - retention-days: 1 + retention-days: 7 From 8edab75a6f51433606e71d8e916f923462c13bc3 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Wed, 9 Sep 2026 14:02:43 +0000 Subject: [PATCH 178/363] Administration: Remove usage of the #787c82 gray color. This light gray color is used for controls that contain only icons. For example, the next / previous / close buttons in the media and themes browsers. Same for some icon-only controls in the Customizer. These icons must meet a 4.5:1 minimum color contrast ratio. The remaining usages are so limited that don't justify the introduction of a dedicated color so it's reasonable to remove it entirely. Developed in https://github.com/WordPress/wordpress-develop/pull/13320 Fixes #65995. git-svn-id: https://develop.svn.wordpress.org/trunk@63559 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/css/common.css | 4 ++-- src/wp-admin/css/customize-nav-menus.css | 4 ++-- src/wp-admin/css/customize-widgets.css | 2 +- src/wp-admin/css/edit.css | 4 ++-- src/wp-admin/css/forms.css | 2 +- src/wp-admin/css/list-tables.css | 2 +- src/wp-admin/css/media.css | 2 +- src/wp-admin/css/themes.css | 4 ++-- src/wp-admin/css/widgets.css | 2 +- src/wp-includes/css/wp-auth-check.css | 2 +- src/wp-includes/css/wp-pointer.css | 2 +- 11 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/wp-admin/css/common.css b/src/wp-admin/css/common.css index 980702d31fb80..a3c5c05dcda81 100644 --- a/src/wp-admin/css/common.css +++ b/src/wp-admin/css/common.css @@ -2553,7 +2553,7 @@ h1.nav-tab-wrapper, /* Back-compat for pre-4.4 */ position: absolute; right: 10px; left: auto; - color: #787c82; + color: #50575e; border-radius: 50px; top: 50%; transform: translateY(-50%); @@ -3372,7 +3372,7 @@ img { .bulk-action-notice .toggle-indicator::before { line-height: 16px; vertical-align: top; - color: #787c82; + color: #50575e; } .postbox .handle-order-higher:focus, diff --git a/src/wp-admin/css/customize-nav-menus.css b/src/wp-admin/css/customize-nav-menus.css index 37008d6d8e29a..9c98728841bc3 100644 --- a/src/wp-admin/css/customize-nav-menus.css +++ b/src/wp-admin/css/customize-nav-menus.css @@ -329,7 +329,7 @@ display: block; padding: 1px 2px 1px 0; border-radius: 50%; - color: #787c82; + color: #50575e; font: normal 20px/1 dashicons; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; @@ -770,7 +770,7 @@ body.adding-menu-items #customize-preview iframe { cursor: default; opacity: .5; background: #fff; - color: #787c82; + color: #50575e; } .added-menu-item .menu-item-handle { diff --git a/src/wp-admin/css/customize-widgets.css b/src/wp-admin/css/customize-widgets.css index 6e1bda06b13dc..db86274af00f1 100644 --- a/src/wp-admin/css/customize-widgets.css +++ b/src/wp-admin/css/customize-widgets.css @@ -25,7 +25,7 @@ } .customize-control .widget-action { - color: #787c82; + color: #50575e; } .customize-control .widget-top:hover .widget-action, diff --git a/src/wp-admin/css/edit.css b/src/wp-admin/css/edit.css index c02a15aa3995a..e564d362a5a85 100644 --- a/src/wp-admin/css/edit.css +++ b/src/wp-admin/css/edit.css @@ -876,7 +876,7 @@ form#tags-filter { .privacy-settings-tab:focus, .health-check-tab:focus { color: #1d2327; - outline: 1px solid #787c82; + outline: 1px solid #50575e; box-shadow: none; } @@ -1087,7 +1087,7 @@ form#tags-filter { .privacy-settings-accordion-panel div > *:not(h1):not(h2):not(h3):not(h4):not(h5):not(h6):not(div):not(.privacy-policy-tutorial):not(.wp-policy-help):not(.privacy-text-copy):not(span.success):not(.notice p) { margin: 0; padding: 1em; - border-left: 2px solid #787c82; + border-left: 2px solid #50575e; } /* Media queries */ diff --git a/src/wp-admin/css/forms.css b/src/wp-admin/css/forms.css index 42a07d16fc9f2..fe45e848a3a91 100644 --- a/src/wp-admin/css/forms.css +++ b/src/wp-admin/css/forms.css @@ -1188,7 +1188,7 @@ table.form-table td .updated p { } .pressthis-bookmarklet span:before { - color: #787c82; + color: #50575e; font: normal 20px/1 dashicons; content: "\f157"; content: "\f157" / ''; diff --git a/src/wp-admin/css/list-tables.css b/src/wp-admin/css/list-tables.css index f6abda748bf1a..66078669f4107 100644 --- a/src/wp-admin/css/list-tables.css +++ b/src/wp-admin/css/list-tables.css @@ -793,7 +793,7 @@ th.sorted a span { .view-switch a:hover:before, .view-switch a:focus:before { - color: #787c82; + color: #1e1e1e; } .view-switch a.current:before { diff --git a/src/wp-admin/css/media.css b/src/wp-admin/css/media.css index 3d7b0c9455c83..09c69d83cbb41 100644 --- a/src/wp-admin/css/media.css +++ b/src/wp-admin/css/media.css @@ -675,7 +675,7 @@ border color while dragging a file over the uploader drop area */ .edit-attachment-frame .edit-media-header .left, .edit-attachment-frame .edit-media-header .right { cursor: pointer; - color: #787c82; + color: #50575e; background-color: transparent; height: 50px; width: 50px; diff --git a/src/wp-admin/css/themes.css b/src/wp-admin/css/themes.css index 24be8ac58c5be..5ffb62ca033cd 100644 --- a/src/wp-admin/css/themes.css +++ b/src/wp-admin/css/themes.css @@ -453,7 +453,7 @@ body.js .theme-browser.search-loading { .theme-overlay .theme-header .close:before { font: normal 22px/50px dashicons !important; - color: #787c82; + color: #50575e; display: inline-block; content: "\f335"; content: "\f335" / ''; @@ -464,7 +464,7 @@ body.js .theme-browser.search-loading { .theme-overlay .theme-header .right, .theme-overlay .theme-header .left { cursor: pointer; - color: #787c82; + color: #50575e; background-color: transparent; height: 48px; width: 54px; diff --git a/src/wp-admin/css/widgets.css b/src/wp-admin/css/widgets.css index 99039d3c7c66a..44a3eaf03f6a7 100644 --- a/src/wp-admin/css/widgets.css +++ b/src/wp-admin/css/widgets.css @@ -516,7 +516,7 @@ div#widgets-right .closed .widgets-sortables { /* Dragging a widget over a closed sidebar */ #widgets-right .widgets-holder-wrap.widget-hover { - border-color: #787c82; + border-color: #50575e; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3); } diff --git a/src/wp-includes/css/wp-auth-check.css b/src/wp-includes/css/wp-auth-check.css index 904dbab4fe9c5..046e87b0b8be6 100644 --- a/src/wp-includes/css/wp-auth-check.css +++ b/src/wp-includes/css/wp-auth-check.css @@ -86,7 +86,7 @@ right: 5px; height: 22px; width: 22px; - color: #787c82; + color: #50575e; text-decoration: none; text-align: center; } diff --git a/src/wp-includes/css/wp-pointer.css b/src/wp-includes/css/wp-pointer.css index ccf7ddc560397..0d6238796d12c 100644 --- a/src/wp-includes/css/wp-pointer.css +++ b/src/wp-includes/css/wp-pointer.css @@ -64,7 +64,7 @@ .wp-pointer-buttons a.close::before { background: none; - color: #787c82; + color: #50575e; content: "\f153"; content: "\f153" / ""; display: block !important; From dafbbffcce918ed637fc69e21e6b543257ba1f52 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Wed, 9 Sep 2026 14:23:57 +0000 Subject: [PATCH 179/363] Build/Test Tools: Block ungrouped external HTTP requests. Fail core tests that make unmocked HTTP requests outside the external-http group, and block those requests before they reach the network. Preserve mocked responses and leave plugin and theme test suites unaffected. Add the missing external-http annotation to the oEmbed shortcode test. Developed in: https://github.com/WordPress/wordpress-develop/pull/13407 Props peterwilsoncc, adrianmoldovanwp, westonruter. See #63083. git-svn-id: https://develop.svn.wordpress.org/trunk@63560 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/includes/abstract-testcase.php | 49 ++++++++++++++++++++ tests/phpunit/tests/oembed/WpEmbed.php | 2 + 2 files changed, 51 insertions(+) diff --git a/tests/phpunit/includes/abstract-testcase.php b/tests/phpunit/includes/abstract-testcase.php index c87e5e7fd077c..25b207092c110 100644 --- a/tests/phpunit/includes/abstract-testcase.php +++ b/tests/phpunit/includes/abstract-testcase.php @@ -22,6 +22,13 @@ abstract class WP_UnitTestCase_Base extends PHPUnit_Adapter_TestCase { /** @var non-empty-string[] */ protected $caught_doing_it_wrong = array(); + /** + * URLs of blocked external HTTP requests made during the current test. + * + * @var list + */ + protected array $blocked_http_requests = array(); + protected static $hooks_saved = array(); protected static $ignore_files; @@ -143,6 +150,12 @@ public function set_up() { $this->expectDeprecated(); add_filter( 'wp_die_handler', array( $this, 'get_wp_die_handler' ) ); add_filter( 'wp_hash_password_options', array( $this, 'wp_hash_password_options' ), 1, 2 ); + + if ( defined( 'WP_RUN_CORE_TESTS' ) && WP_RUN_CORE_TESTS + && ! in_array( 'external-http', $this->getGroups(), true ) + ) { + add_filter( 'pre_http_request', array( $this, 'block_external_http_request' ), PHP_INT_MAX, 3 ); + } } /** @@ -685,6 +698,34 @@ public function expectedDeprecated() { } } + /** + * Blocks an external HTTP request that no other filter has answered. + * + * Added by set_up() for tests that are not in the `external-http` group, and + * runs last on the filter so any mock set up by the test itself gets the + * first say. Requests reaching this point are recorded and fail the test in + * assert_post_conditions(). + * + * @since 7.2.0 + * + * @param false|array|WP_Error $response A preemptive response, or false when none was given. + * @param array $args Request arguments. + * @param string $url The request URL. + * @return array|WP_Error The preemptive response, or an error for a blocked request. + */ + public function block_external_http_request( $response, array $args, string $url ) { + if ( false !== $response ) { + return $response; + } + + $this->blocked_http_requests[] = $url; + + return new WP_Error( + 'test_external_http_blocked', + 'External HTTP requests are blocked in tests that are not in the `external-http` group.' + ); + } + /** * Detects post-test failure conditions. * @@ -694,6 +735,14 @@ public function expectedDeprecated() { */ protected function assert_post_conditions() { $this->expectedDeprecated(); + + if ( $this->blocked_http_requests ) { + $this->fail( + "This test made an external HTTP request but is not in the `external-http` group.\n" + . "Add `@group external-http` to it, or mock the request with the `pre_http_request` filter.\n" + . '- ' . implode( "\n- ", array_unique( $this->blocked_http_requests ) ) + ); + } } /** diff --git a/tests/phpunit/tests/oembed/WpEmbed.php b/tests/phpunit/tests/oembed/WpEmbed.php index 42d9c9e0f4ed9..f95fbde7b92dd 100644 --- a/tests/phpunit/tests/oembed/WpEmbed.php +++ b/tests/phpunit/tests/oembed/WpEmbed.php @@ -405,6 +405,8 @@ public function test_shortcode_should_make_link_for_unknown_url() { } /** + * @group external-http + * * @covers ::run_shortcode */ public function test_run_shortcode_url_only() { From 4c988a30bdce85a3f6ba89d7ab0a06416db723f8 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Wed, 9 Sep 2026 14:29:00 +0000 Subject: [PATCH 180/363] Tests: Remove unused sitemap taxonomy test variables. Remove unused post variables and closure captures from the sitemap taxonomy tests. Use the post factory create() method to assign and count the test terms, and correct the fixture comment. Developed in: https://github.com/WordPress/wordpress-develop/pull/13455 Props soean. See #65819. git-svn-id: https://develop.svn.wordpress.org/trunk@63561 602fd350-edb4-49c9-b593-d223f7449a82 --- .../phpunit/tests/sitemaps/wpSitemapsTaxonomies.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/phpunit/tests/sitemaps/wpSitemapsTaxonomies.php b/tests/phpunit/tests/sitemaps/wpSitemapsTaxonomies.php index 456efe06e922f..f3d292dd26a34 100644 --- a/tests/phpunit/tests/sitemaps/wpSitemapsTaxonomies.php +++ b/tests/phpunit/tests/sitemaps/wpSitemapsTaxonomies.php @@ -45,8 +45,8 @@ public function test_get_url_list_taxonomies() { // Add the default category to the list of categories we're testing. $categories = array_merge( array( 1 ), self::$cats ); - // Create a test post to calculate update times. - $post = self::factory()->post->create_and_get( + // Create a test post so the test terms are assigned and counted. + self::factory()->post->create( array( 'tags_input' => self::$post_tags, 'post_category' => $categories, @@ -58,7 +58,7 @@ public function test_get_url_list_taxonomies() { $cat_list = $tax_provider->get_url_list( 1, 'category' ); $expected_cats = array_map( - static function ( $id ) use ( $post ) { + static function ( $id ) { return array( 'loc' => get_term_link( $id, 'category' ), ); @@ -71,7 +71,7 @@ static function ( $id ) use ( $post ) { $tag_list = $tax_provider->get_url_list( 1, 'post_tag' ); $expected_tags = array_map( - static function ( $id ) use ( $post ) { + static function ( $id ) { return array( 'loc' => get_term_link( $id, 'post_tag' ), ); @@ -97,10 +97,10 @@ public function test_get_url_list_custom_taxonomy() { $terms = self::factory()->term->create_many( 10, array( 'taxonomy' => $taxonomy ) ); // Create a test post applied to all test terms. - $post = self::factory()->post->create_and_get( array( 'tax_input' => array( $taxonomy => $terms ) ) ); + self::factory()->post->create( array( 'tax_input' => array( $taxonomy => $terms ) ) ); $expected = array_map( - static function ( $id ) use ( $taxonomy, $post ) { + static function ( $id ) use ( $taxonomy ) { return array( 'loc' => get_term_link( $id, $taxonomy ), ); From 6e3e6967de1ad584a852cd4d68077278800d000f Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Wed, 9 Sep 2026 14:30:58 +0000 Subject: [PATCH 181/363] Tests: Simplify mocks in WP_Upgrader tests. Use `createMock()` for the upgrader skin and filesystem mocks. These test doubles need no custom builder configuration, original constructor, or cloning behavior. Developed in: https://github.com/WordPress/wordpress-develop/pull/13458 Props soean. See #65819. git-svn-id: https://develop.svn.wordpress.org/trunk@63562 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/admin/wpUpgrader.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/phpunit/tests/admin/wpUpgrader.php b/tests/phpunit/tests/admin/wpUpgrader.php index ffea594ae87bc..59930164a238a 100644 --- a/tests/phpunit/tests/admin/wpUpgrader.php +++ b/tests/phpunit/tests/admin/wpUpgrader.php @@ -49,11 +49,11 @@ public static function set_up_before_class() { public function set_up() { parent::set_up(); - self::$upgrader_skin_mock = $this->getMockBuilder( 'WP_Upgrader_Skin' )->getMock(); + self::$upgrader_skin_mock = $this->createMock( 'WP_Upgrader_Skin' ); self::$instance = new WP_Upgrader( self::$upgrader_skin_mock ); - self::$wp_filesystem_mock = $this->getMockBuilder( 'WP_Filesystem_Base' )->getMock(); + self::$wp_filesystem_mock = $this->createMock( 'WP_Filesystem_Base' ); if ( array_key_exists( 'wp_filesystem', $GLOBALS ) ) { self::$wp_filesystem_backup = $GLOBALS['wp_filesystem']; From d6b0c206946b091745bfef66b432ec46100c073e Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Wed, 9 Sep 2026 14:50:06 +0000 Subject: [PATCH 182/363] Tests: Reduce repeated core block style registration. Register core block styles once per scenario, then check all block handles. Replace per-block data-provider cases with loops, retaining the assertions and adding block names to failure messages. Developed in: https://github.com/WordPress/wordpress-develop/pull/13457 Props sainathpoojary. See #66074. git-svn-id: https://develop.svn.wordpress.org/trunk@63563 602fd350-edb4-49c9-b593-d223f7449a82 --- .../blocks/registerCoreBlockStyleHandles.php | 129 +++++++++--------- 1 file changed, 63 insertions(+), 66 deletions(-) diff --git a/tests/phpunit/tests/blocks/registerCoreBlockStyleHandles.php b/tests/phpunit/tests/blocks/registerCoreBlockStyleHandles.php index 7d5249b3236c0..cb798b20ba527 100644 --- a/tests/phpunit/tests/blocks/registerCoreBlockStyleHandles.php +++ b/tests/phpunit/tests/blocks/registerCoreBlockStyleHandles.php @@ -54,26 +54,24 @@ public function tear_down() { /** * @ticket 58528 * - * @dataProvider data_block_data - * * @covers ::register_core_block_style_handles * @covers ::wp_should_load_separate_core_block_assets - * - * @param string $name The block name. - * @param array $schema The block's schema. */ - public function test_wp_should_load_separate_core_block_assets_false( $name, $schema ) { + public function test_wp_should_load_separate_core_block_assets_false() { add_filter( 'should_load_separate_core_block_assets', '__return_false' ); - $this->assertFalse( wp_should_load_separate_core_block_assets(), 'Core blocks are not expected to load separate assets' ); register_core_block_style_handles(); - foreach ( self::STYLE_FIELDS as $style_field => $filename ) { - $style_handle = $schema[ $style_field ]; - if ( is_array( $style_handle ) ) { - continue; - } + foreach ( $this->get_block_data() as $name => $schema ) { + $this->assertFalse( wp_should_load_separate_core_block_assets(), "Block {$name}: Core blocks are not expected to load separate assets" ); + + foreach ( self::STYLE_FIELDS as $style_field => $filename ) { + $style_handle = $schema[ $style_field ]; + if ( is_array( $style_handle ) ) { + continue; + } - $this->assertArrayNotHasKey( $style_handle, $GLOBALS['wp_styles']->registered, 'The key should not exist, as this style should not be registered' ); + $this->assertArrayNotHasKey( $style_handle, $GLOBALS['wp_styles']->registered, "Block {$name}: The key should not exist, as this style should not be registered" ); + } } } @@ -81,74 +79,66 @@ public function test_wp_should_load_separate_core_block_assets_false( $name, $sc /** * @ticket 58528 * - * @dataProvider data_block_data - * * @covers ::register_core_block_style_handles * @covers ::wp_should_load_separate_core_block_assets - * - * @param string $name The block name. - * @param array $schema The block's schema. */ - public function test_wp_should_load_separate_core_block_assets_true( $name, $schema ) { + public function test_wp_should_load_separate_core_block_assets_true() { add_filter( 'should_load_separate_core_block_assets', '__return_true' ); - $this->assertTrue( wp_should_load_separate_core_block_assets(), 'Core assets are expected to load separately' ); register_core_block_style_handles(); $wp_styles = $GLOBALS['wp_styles']; - foreach ( self::STYLE_FIELDS as $style_field => $filename ) { - $style_handle = $schema[ $style_field ]; - if ( is_array( $style_handle ) ) { - continue; - } - - $this->assertArrayHasKey( $style_handle, $wp_styles->registered, 'The key should exist, as this style should be registered' ); - if ( false === $wp_styles->registered[ $style_handle ]->src ) { - $this->assertEmpty( $wp_styles->registered[ $style_handle ]->extra, 'If source is false, style path should not be set' ); - } else { - $this->assertStringContainsString( $this->includes_url, $wp_styles->registered[ $style_handle ]->src, 'Source of style should contain the includes url' ); - $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra, 'The path of the style should exist' ); - $this->assertArrayHasKey( 'path', $wp_styles->registered[ $style_handle ]->extra, 'The path key of the style should exist in extra array' ); - $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra['path'], 'The path key of the style should not be empty' ); + foreach ( $this->get_block_data() as $name => $schema ) { + $this->assertTrue( wp_should_load_separate_core_block_assets(), "Block {$name}: Core assets are expected to load separately" ); + + foreach ( self::STYLE_FIELDS as $style_field => $filename ) { + $style_handle = $schema[ $style_field ]; + if ( is_array( $style_handle ) ) { + continue; + } + + $this->assertArrayHasKey( $style_handle, $wp_styles->registered, "Block {$name}: The key should exist, as this style should be registered" ); + if ( false === $wp_styles->registered[ $style_handle ]->src ) { + $this->assertEmpty( $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: If source is false, style path should not be set" ); + } else { + $this->assertStringContainsString( $this->includes_url, $wp_styles->registered[ $style_handle ]->src, "Block {$name}: Source of style should contain the includes url" ); + $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The path of the style should exist" ); + $this->assertArrayHasKey( 'path', $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The path key of the style should exist in extra array" ); + $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra['path'], "Block {$name}: The path key of the style should not be empty" ); + } } } } /** * @ticket 58560 - * - * @dataProvider data_block_data - * - * @param string $name The block name. */ - public function test_wp_should_load_separate_core_block_assets_current_theme_supports( $name ) { + public function test_wp_should_load_separate_core_block_assets_current_theme_supports() { add_filter( 'should_load_separate_core_block_assets', '__return_true' ); add_theme_support( 'wp-block-styles' ); register_core_block_style_handles(); $wp_styles = $GLOBALS['wp_styles']; - $style_handle = "wp-block-{$name}-theme"; + foreach ( array_keys( $this->get_block_data() ) as $name ) { + $style_handle = "wp-block-{$name}-theme"; - $this->assertArrayHasKey( $style_handle, $wp_styles->registered, 'The key should exist, as this style should be registered' ); - if ( false === $wp_styles->registered[ $style_handle ]->src ) { - $this->assertEmpty( $wp_styles->registered[ $style_handle ]->extra, 'If source is false, style path should not be set' ); - } else { - $this->assertStringContainsString( $this->includes_url, $wp_styles->registered[ $style_handle ]->src, 'Source of style should contain the includes url' ); - $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra, 'The path of the style should exist' ); - $this->assertArrayHasKey( 'path', $wp_styles->registered[ $style_handle ]->extra, 'The path key of the style should exist in extra array' ); - $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra['path'], 'The path key of the style should not be empty' ); + $this->assertArrayHasKey( $style_handle, $wp_styles->registered, "Block {$name}: The key should exist, as this style should be registered" ); + if ( false === $wp_styles->registered[ $style_handle ]->src ) { + $this->assertEmpty( $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: If source is false, style path should not be set" ); + } else { + $this->assertStringContainsString( $this->includes_url, $wp_styles->registered[ $style_handle ]->src, "Block {$name}: Source of style should contain the includes url" ); + $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The path of the style should exist" ); + $this->assertArrayHasKey( 'path', $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The path key of the style should exist in extra array" ); + $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra['path'], "Block {$name}: The path key of the style should not be empty" ); + } } } /** * @ticket 59715 - * - * @dataProvider data_block_data - * - * @param string $name The block name. */ - public function test_register_core_block_style_handles_should_load_rtl_stylesheets_for_rtl_text_direction( $name ) { + public function test_register_core_block_style_handles_should_load_rtl_stylesheets_for_rtl_text_direction() { global $wp_locale; $orig_text_dir = $wp_locale->text_direction; @@ -159,23 +149,30 @@ public function test_register_core_block_style_handles_should_load_rtl_styleshee $wp_styles = $GLOBALS['wp_styles']; - $style_handle = "wp-block-{$name}-theme"; - $wp_locale->text_direction = $orig_text_dir; - $this->assertArrayHasKey( $style_handle, $wp_styles->registered, 'The key should exist, as this style should be registered' ); - if ( false === $wp_styles->registered[ $style_handle ]->src ) { - $this->assertEmpty( $wp_styles->registered[ $style_handle ]->extra, 'If source is false, style path should not be set' ); - } else { - $this->assertStringContainsString( $this->includes_url, $wp_styles->registered[ $style_handle ]->src, 'Source of style should contain the includes url' ); - $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra, 'The path of the style should exist' ); - $this->assertArrayHasKey( 'path', $wp_styles->registered[ $style_handle ]->extra, 'The path key of the style should exist in extra array' ); - $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra['path'], 'The path key of the style should not be empty' ); - $this->assertArrayHasKey( 'rtl', $wp_styles->registered[ $style_handle ]->extra, 'The rtl key of the style should exist in extra array' ); + foreach ( array_keys( $this->get_block_data() ) as $name ) { + $style_handle = "wp-block-{$name}-theme"; + + $this->assertArrayHasKey( $style_handle, $wp_styles->registered, "Block {$name}: The key should exist, as this style should be registered" ); + if ( false === $wp_styles->registered[ $style_handle ]->src ) { + $this->assertEmpty( $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: If source is false, style path should not be set" ); + } else { + $this->assertStringContainsString( $this->includes_url, $wp_styles->registered[ $style_handle ]->src, "Block {$name}: Source of style should contain the includes url" ); + $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The path of the style should exist" ); + $this->assertArrayHasKey( 'path', $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The path key of the style should exist in extra array" ); + $this->assertNotEmpty( $wp_styles->registered[ $style_handle ]->extra['path'], "Block {$name}: The path key of the style should not be empty" ); + $this->assertArrayHasKey( 'rtl', $wp_styles->registered[ $style_handle ]->extra, "Block {$name}: The rtl key of the style should exist in extra array" ); + } } } - public function data_block_data() { + /** + * Gets the blocks to check after registering styles once per scenario. + * + * @return array[] Block schemas keyed by block name. + */ + private function get_block_data() { $core_blocks_meta = require ABSPATH . WPINC . '/blocks/blocks-json.php'; // Remove this blocks for now, as they are registered elsewhere. @@ -191,7 +188,7 @@ public function data_block_data() { $schema['editorStyle'] = "wp-block-{$name}-editor"; } - $data[ $name ] = array( $name, $schema ); + $data[ $name ] = $schema; } return $data; From 37a5d59ef68354d92a7966d66044ac6381bb77d6 Mon Sep 17 00:00:00 2001 From: Adam Silverstein Date: Wed, 9 Sep 2026 16:18:49 +0000 Subject: [PATCH 183/363] Media: Prepare the attachment finalize response from the current post data. `finalize_item()` prepares its response from the `$post` fetched before the `wp_generate_attachment_metadata` filter runs, so anything a callback writes to the post row is missing from the response. The editor now stores that response as the attachment record instead of refetching, so re-read the post after the metadata is written and return the `WP_Error` if a callback deleted the attachment. See https://github.com/WordPress/gutenberg/issues/81844 and https://github.com/WordPress/gutenberg/pull/81947. Props gregbenz, andrewserong. Fixes #66056. git-svn-id: https://develop.svn.wordpress.org/trunk@63564 602fd350-edb4-49c9-b593-d223f7449a82 --- .../class-wp-rest-attachments-controller.php | 15 ++ .../rest-api/rest-attachments-controller.php | 198 ++++++++++++++++++ 2 files changed, 213 insertions(+) diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php index b95b061b3399e..9807ac9cf15b5 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-attachments-controller.php @@ -3453,6 +3453,21 @@ public function finalize_item( WP_REST_Request $request ) { $response_request['_fields'] = $request['_fields']; } + /* + * Re-read the post. The 'wp_generate_attachment_metadata' filter above + * runs long after $post was fetched, and a callback that rewrites the + * post row - an optimizer changing post_mime_type once it has + * converted the file, say - would otherwise be missing from this + * response. The editor stores the response as its copy of the record + * rather than reading the attachment again, so a stale row here is + * what it keeps. A callback that deleted the attachment instead leaves + * nothing to respond with, so that is reported as the error it is. + */ + $post = $this->get_post( $attachment_id ); + if ( is_wp_error( $post ) ) { + return $post; + } + return $this->prepare_item_for_response( $post, $response_request ); } } diff --git a/tests/phpunit/tests/rest-api/rest-attachments-controller.php b/tests/phpunit/tests/rest-api/rest-attachments-controller.php index 4dd0b60172cb4..282c0f6b95e22 100644 --- a/tests/phpunit/tests/rest-api/rest-attachments-controller.php +++ b/tests/phpunit/tests/rest-api/rest-attachments-controller.php @@ -5128,6 +5128,204 @@ public function test_finalize_preserves_image_meta(): void { $this->assertSame( $original_image_meta['iso'], $metadata['image_meta']['iso'], 'ISO should be preserved.' ); } + /** + * Verifies that the finalize response carries the generated sub-sizes. + * + * The response is prepared after the sub-size metadata has been written, so + * it is the finished attachment record. The editor stores it as-is instead + * of fetching the attachment again to pick the sizes up. + * + * @ticket 66056 + * + * @covers WP_REST_Attachments_Controller::finalize_item + */ + public function test_finalize_response_contains_generated_sub_sizes(): void { + $this->enable_client_side_media_processing(); + + wp_set_current_user( self::$author_id ); + + $request = new WP_REST_Request( 'POST', '/wp/v2/media' ); + $request->set_header( 'Content-Type', 'image/jpeg' ); + $request->set_header( 'Content-Disposition', 'attachment; filename=finalize-response-test.jpg' ); + $request->set_param( 'generate_sub_sizes', false ); + $request->set_body( (string) file_get_contents( DIR_TESTDATA . '/images/canola.jpg' ) ); + + $response = rest_get_server()->dispatch( $request ); + $data = $response->get_data(); + $attachment_id = $data['id']; + + // Nothing has generated sub-sizes yet, which is the window in which the + // editor's first read of the attachment happens. + $this->assertEmpty( + (array) $data['media_details']['sizes'], + 'The create response should not carry sub-sizes yet.' + ); + + $request = new WP_REST_Request( 'POST', "/wp/v2/media/{$attachment_id}/sideload" ); + $request->set_header( 'Content-Type', 'image/jpeg' ); + $request->set_header( 'Content-Disposition', 'attachment; filename=finalize-response-test-150x150.jpg' ); + $request->set_param( 'image_size', 'thumbnail' ); + $request->set_body( (string) file_get_contents( DIR_TESTDATA . '/images/test-image.jpg' ) ); + + $response = rest_get_server()->dispatch( $request ); + $thumbnail_data = $response->get_data(); + $this->assertSame( 200, $response->get_status(), 'Sideloading the thumbnail should succeed.' ); + + $request = new WP_REST_Request( 'POST', "/wp/v2/media/{$attachment_id}/finalize" ); + $request->set_param( 'sub_sizes', array( $thumbnail_data ) ); + + $response = rest_get_server()->dispatch( $request ); + $this->assertSame( 200, $response->get_status() ); + + $data = $response->get_data(); + $this->assertArrayHasKey( 'media_details', $data ); + $this->assertArrayHasKey( + 'thumbnail', + $data['media_details']['sizes'], + 'The finalize response should list the sideloaded sub-size.' + ); + + // source_url is what the Image block's Resolution control offers. + $this->assertArrayHasKey( + 'source_url', + $data['media_details']['sizes']['thumbnail'], + 'Each sub-size in the finalize response should carry its URL.' + ); + $this->assertStringEndsWith( + 'finalize-response-test-150x150.jpg', + $data['media_details']['sizes']['thumbnail']['source_url'] + ); + + // The finalize response must match what a later read would return, as + // the editor stores it in place of that read. + $request = new WP_REST_Request( 'GET', "/wp/v2/media/{$attachment_id}" ); + $request->set_param( 'context', 'view' ); + $fetched = rest_get_server()->dispatch( $request )->get_data(); + + $this->assertSame( + array_keys( (array) $fetched['media_details']['sizes'] ), + array_keys( (array) $data['media_details']['sizes'] ), + 'The finalize response should carry the same sizes a refetch would.' + ); + } + + /** + * Verifies that the finalize response reflects the post row as it stands + * after the metadata has been generated. + * + * finalize_item() applies the 'wp_generate_attachment_metadata' filter + * before preparing its response, and a callback is free to rewrite the + * attachment's post row - an optimizer that converts the file updates + * post_mime_type, for instance. The editor stores this response as its + * copy of the record rather than reading the attachment again, so + * anything stale here is what the block keeps for the session. + * + * @ticket 66056 + * + * @covers WP_REST_Attachments_Controller::finalize_item + */ + public function test_finalize_response_reflects_post_row_changed_by_metadata_filter(): void { + $this->enable_client_side_media_processing(); + + wp_set_current_user( self::$author_id ); + + $request = new WP_REST_Request( 'POST', '/wp/v2/media' ); + $request->set_header( 'Content-Type', 'image/jpeg' ); + $request->set_header( 'Content-Disposition', 'attachment; filename=filtered-post-row.jpg' ); + $request->set_param( 'generate_sub_sizes', false ); + $request->set_param( 'title', 'Original title' ); + $request->set_body( (string) file_get_contents( DIR_TESTDATA . '/images/canola.jpg' ) ); + + $attachment_id = rest_get_server()->dispatch( $request )->get_data()['id']; + + $request = new WP_REST_Request( 'POST', "/wp/v2/media/{$attachment_id}/sideload" ); + $request->set_header( 'Content-Type', 'image/jpeg' ); + $request->set_header( 'Content-Disposition', 'attachment; filename=filtered-post-row-150x150.jpg' ); + $request->set_param( 'image_size', 'thumbnail' ); + $request->set_body( (string) file_get_contents( DIR_TESTDATA . '/images/test-image.jpg' ) ); + + $thumbnail_data = rest_get_server()->dispatch( $request )->get_data(); + + // Stands in for a plugin that rewrites the post row as the metadata is + // generated. Added after the upload so only finalize runs it. + add_filter( + 'wp_generate_attachment_metadata', + static function ( $metadata, $id ) { + wp_update_post( + array( + 'ID' => $id, + 'post_title' => 'Rewritten while generating metadata', + ) + ); + return $metadata; + }, + 10, + 2 + ); + + $request = new WP_REST_Request( 'POST', "/wp/v2/media/{$attachment_id}/finalize" ); + $request->set_param( 'sub_sizes', array( $thumbnail_data ) ); + + $response = rest_get_server()->dispatch( $request ); + $this->assertSame( 200, $response->get_status() ); + + $this->assertSame( + 'Rewritten while generating metadata', + get_post( $attachment_id )->post_title, + 'The filter should have rewritten the stored post row.' + ); + + $this->assertSame( + 'Rewritten while generating metadata', + $response->get_data()['title']['raw'], + 'The finalize response should carry the rewritten post row, not the row as it was before the metadata was generated.' + ); + } + + /** + * Verifies that finalize fails when the attachment no longer exists by the + * time its response is prepared. + * + * A 'wp_generate_attachment_metadata' callback that rejects the file and + * deletes the attachment must not be answered with a 200 built from the row + * as it was before the callback ran: the editor would store that stale + * record and report the upload as complete. + * + * @ticket 66056 + * + * @covers WP_REST_Attachments_Controller::finalize_item + */ + public function test_finalize_fails_when_metadata_filter_deletes_attachment(): void { + $this->enable_client_side_media_processing(); + + wp_set_current_user( self::$author_id ); + + $request = new WP_REST_Request( 'POST', '/wp/v2/media' ); + $request->set_header( 'Content-Type', 'image/jpeg' ); + $request->set_header( 'Content-Disposition', 'attachment; filename=deleted-while-finalizing.jpg' ); + $request->set_param( 'generate_sub_sizes', false ); + $request->set_body( (string) file_get_contents( DIR_TESTDATA . '/images/canola.jpg' ) ); + + $attachment_id = rest_get_server()->dispatch( $request )->get_data()['id']; + + add_filter( + 'wp_generate_attachment_metadata', + static function ( $metadata, $id ) { + wp_delete_attachment( $id, true ); + return $metadata; + }, + 10, + 2 + ); + + $request = new WP_REST_Request( 'POST', "/wp/v2/media/{$attachment_id}/finalize" ); + $request->set_param( 'sub_sizes', array() ); + + $response = rest_get_server()->dispatch( $request ); + + $this->assertErrorResponse( 'rest_post_invalid_id', $response, 404 ); + } + /** * Tests that the sideload route declares `convert_format` as a boolean arg. * From 126a9ea87e6dcef5cae9e4b405215fd5a2babd75 Mon Sep 17 00:00:00 2001 From: Joe Dolson Date: Wed, 9 Sep 2026 19:38:38 +0000 Subject: [PATCH 184/363] Administration: Prevent fatal error in sprintf replacement in tooltips. If HTML passed directly the `button` argument of `wp_get_tooltip_helper()` contained a `%` character, this was interpreted as a placeholder for `sprintf()`, causing a PHP fatal due to a mismatch in argument count. Use the WP_HTML_Tag_Processor to fully construct the button HTML before running sprintf, so that supplied `%` characters are part of the value instead of the format string. Props ekamran, parthjoginyusoft, sc0ttkclark, jack960330, adamsilverstein, joedolson. Fixes #65914. git-svn-id: https://develop.svn.wordpress.org/trunk@63566 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/general-template.php | 96 ++++++++++------ tests/phpunit/tests/general/wpGetTooltip.php | 115 +++++++++++++++++++ 2 files changed, 177 insertions(+), 34 deletions(-) diff --git a/src/wp-includes/general-template.php b/src/wp-includes/general-template.php index 63a3aa67123b2..0e35894fd47c4 100644 --- a/src/wp-includes/general-template.php +++ b/src/wp-includes/general-template.php @@ -390,7 +390,7 @@ function get_search_form( $args = array() ) { * @type string $id Unique ID for the popover element. Default is a * generated unique ID. * @type string $button Existing `button` or `a` markup. Used instead of generated button. - * Default standard button HTML. + * Default empty string. * @type string $label Not used for tooltips. * @type string $close_label Not used for tooltips. * @type string $icon Dashicons icon class for the toggle button. @@ -420,7 +420,7 @@ function wp_get_tooltip( $content, $args = array() ) { * @type string $id Unique ID for the popover element. Default is a * generated unique ID. * @type string $button Existing `button` markup. Used instead of generated button. - * Default standard button HTML. + * Default empty string. * @type string $label Accessible label for the toggle button. * Default 'Help', matching the default icon. * Ignored for tooltips. @@ -455,7 +455,7 @@ function wp_get_toggletip( $content, $args = array() ) { * @type string $id Unique ID for the popover element. Default is a * generated unique ID. * @type string $button Existing `button` or `a` markup. Used instead of generated button. - * Default standard button HTML. + * Default empty string. * @type string $label Accessible label for the toggle button. * Default 'Help', matching the default icon. * Ignored for tooltips. @@ -479,7 +479,7 @@ function wp_get_tooltip_helper( $content, $args = array() ) { $defaults = array( 'id' => wp_unique_id( 'wp-tooltip-' ), - 'button' => '', + 'button' => '', 'label' => __( 'Help' ), 'close_label' => __( 'Close' ), 'icon' => 'dashicons-editor-help', @@ -494,39 +494,67 @@ function wp_get_tooltip_helper( $content, $args = array() ) { $classes .= ' ' . $args['class']; } - $icon = ( $args['icon'] ) ? trim( $args['icon'] ) : $defaults['icon']; - $id = ( $args['id'] ) ? $args['id'] : $defaults['id']; - $button = ( $args['button'] ) ? $args['button'] : $defaults['button']; - $processed = false; + $icon = ( $args['icon'] ) ? trim( $args['icon'] ) : $defaults['icon']; + $id = ( $args['id'] ) ? $args['id'] : $defaults['id']; + + // Tooltips use the content as the accessible name; toggletips use the label. + $label = ( 'tooltip' === $args['type'] ) ? wp_strip_all_tags( $content, true ) : $args['label']; + + /* + * The generated button is a plain skeleton. Every dynamic attribute is + * added through the tag processor below, so caller-supplied markup is + * never scanned or substituted and a percent sign in custom markup, + * such as a percent-encoded URL, is never treated as a conversion + * specification. + */ + $default_button = ''; + + $is_default = ! $args['button']; + $button = ( $args['button'] ) ? $args['button'] : $default_button; + + // The accepted root element is a `button`, or an `a` for tooltips. + $tag = false; $processor = new WP_HTML_Tag_Processor( $button ); if ( true === $processor->next_tag( 'button' ) ) { - $processor->add_class( 'wp-tooltip__toggle' ); - if ( 'tooltip' !== $args['type'] ) { - $processor->set_attribute( 'popovertarget', '%2$s' ); - $processor->set_attribute( 'aria-haspopup', 'dialog' ); - } - $button = $processor->get_updated_html(); - $processed = true; + $tag = 'button'; } else { - // Reset processor. $processor = new WP_HTML_Tag_Processor( $button ); - if ( true === $processor->next_tag( 'a' ) && 'tooltip' === $args['type'] ) { - $processor->add_class( 'wp-tooltip__toggle' ); - $button = $processor->get_updated_html(); - $processed = true; + if ( 'tooltip' === $args['type'] && true === $processor->next_tag( 'a' ) ) { + $tag = 'a'; } } - if ( ! $processed ) { - // Button HTML passed was not valid. - $processor = new WP_HTML_Tag_Processor( $defaults['button'] ); - $processor->add_class( 'wp-tooltip__toggle' ); - if ( 'tooltip' !== $args['type'] ) { - $processor->set_attribute( 'popovertarget', '%2$s' ); - $processor->set_attribute( 'aria-haspopup', 'dialog' ); - } - $button = $processor->get_updated_html(); + + if ( false === $tag ) { + // Button HTML passed was not valid. Reset to default. + $is_default = true; + $button = $default_button; + $processor = new WP_HTML_Tag_Processor( $button ); + $processor->next_tag( 'button' ); + $tag = 'button'; } + /* + * Attributes that apply to every accepted button are added in one pass. + * Attributes that name the control are only added when the caller's + * markup did not already provide them. + */ + if ( null === $processor->get_attribute( 'aria-label' ) ) { + $processor->set_attribute( 'aria-label', $label ); + } + $processor->add_class( 'wp-tooltip__toggle' ); + if ( 'button' === $tag && 'tooltip' !== $args['type'] ) { + $processor->set_attribute( 'popovertarget', $id ); + $processor->set_attribute( 'aria-haspopup', 'dialog' ); + } + + // The generated button also carries the dashicon on its inner span. + if ( $is_default && true === $processor->next_tag( 'span' ) ) { + $processor->set_attribute( 'class', 'dashicons ' . $icon ); + $processor->set_attribute( 'aria-hidden', 'true' ); + } + + $button = $processor->get_updated_html(); + /* * The markup only uses phrasing content so it is valid when nested * in a phrasing context. Sectioning content (e.g. `div`, `dialog`) will @@ -534,11 +562,9 @@ function wp_get_tooltip_helper( $content, $args = array() ) { * the layout. See #65660. */ if ( 'tooltip' === $args['type'] ) { - // Tooltips are only used to visually display labels. - $label = wp_strip_all_tags( $content, true ); $markup = sprintf( ' - ' . $button . ' + %6$s ' . '%5$s' . '' . @@ -548,6 +574,7 @@ function wp_get_tooltip_helper( $content, $args = array() ) { esc_attr( $label ), esc_attr( $icon ), esc_html( $content ), + $button, ); } else { /* @@ -557,7 +584,7 @@ function wp_get_tooltip_helper( $content, $args = array() ) { */ $markup = sprintf( ' - ' . $button . ' + %7$s ' . '%5$s' . '', + ) + ); + + $this->assertStringContainsString( 'aria-label="Helpful text."', $html, 'A custom button without an accessible name should gain one from the content.' ); + + $html2 = wp_get_tooltip( + 'Helpful text.', + array( + 'button' => '', + ) + ); + + $this->assertStringContainsString( 'aria-label="Custom name"', $html2, 'A caller-supplied aria-label should be preserved.' ); + $this->assertStringNotContainsString( 'aria-label="Helpful text."', $html2, 'The generated label should not overwrite the caller-supplied one.' ); + } + /** * Tests that the accessible labels are output and escaped in attributes. * @@ -206,6 +233,94 @@ public function test_wp_get_toggletip_bubble_uses_dialog_role_and_autofocus() { $this->assertStringContainsString( 'tabindex="-1" autofocus>', $html ); } + /** + * Tests that a percent sign in the button markup is not treated as a + * `sprintf()` conversion specification. + * + * @ticket 65914 + * + * @dataProvider data_button_markup_containing_percent_signs + * + * @param string $button Button markup containing a percent sign. + * @param string $expected Substring that must be preserved in the output. + */ + public function test_wp_get_tooltip_preserves_percent_signs_in_button_markup( $button, $expected ) { + $this->assertStringContainsString( + $expected, + wp_get_tooltip( 'Helpful text.', array( 'button' => $button ) ), + 'The tooltip did not preserve the percent sign.' + ); + $this->assertStringContainsString( + $expected, + wp_get_toggletip( 'Helpful text.', array( 'button' => $button ) ), + 'The toggletip did not preserve the percent sign.' + ); + } + + /** + * Tests that a percent-encoded URL in anchor markup is not rewritten. + * + * @ticket 65914 + * + * @dataProvider data_percent_encoded_hrefs + * + * @param string $href A percent-encoded URL. + */ + public function test_wp_get_tooltip_preserves_percent_encoding_in_anchor_href( $href ) { + $html = wp_get_tooltip( + 'Helpful text.', + array( 'button' => 'Search' ) + ); + + $this->assertStringContainsString( 'href="' . $href . '"', $html ); + } + + /** + * Data provider. + * + * @return array[] + */ + public function data_percent_encoded_hrefs() { + return array( + 'an encoded space' => array( '/wp-admin/edit.php?s=hello%20world' ), + 'an encoded slash' => array( '/x?p=a%2Fb' ), + ); + } + + /** + * Data provider. + * + * @return array[] + */ + public function data_button_markup_containing_percent_signs() { + return array( + 'a literal percent sign' => array( + '', + '100% done', + ), + 'a percent sign then a word' => array( + '', + 'Save 20%!', + ), + 'an unknown format specifier' => array( + '', + 'Buy %q now', + ), + 'a percent sign in an ID' => array( + '', + 'aria-describedby="box_100%_complete-title"', + ), + 'a percent-encoded ID' => array( + '', + 'aria-describedby="meta-%d0%b8%d0%b3%d1%80%d0%b0-title"', + ), + 'text resembling a argnum' => array( + '', + 'Use %2$s in your code', + ), + ); + } + /** * Data provider. * From 8f6799a4e5ed4071ead29572c020fa9c1df0a7f5 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Wed, 9 Sep 2026 19:49:38 +0000 Subject: [PATCH 185/363] Code Modernization: Use `array_key_first()` to read the first key of an array. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Reading the first key of an array through `array_keys()` allocates a full array of every key just to keep one entry and discard the rest. `array_key_first()` reads the first bucket directly. Follow-up to r63297 / #65773, which is scoped to the two nested `current( array_keys( $array ) )` call sites. This commit covers a second shape of the same idea, which that ticket does not include: the key array is assigned to a variable first, then read on the next line. {{{ $keys = array_keys( $wp_registered_sidebars ); $sidebar = reset( $keys ); }}} {{{ $sidebar = array_key_first( $wp_registered_sidebars ); }}} 13 occurrences across 11 files, in two shapes — `reset( $keys )` and `$keys[0]`. In every case the intermediate variable existed only to carry the key array to the next line and is never read again afterwards. **One change that goes further** In `spawn_cron()` and `_wp_cron()` the surrounding check is dropped too: {{{ $keys = array_keys( $crons ); if ( isset( $keys[0] ) && $keys[0] > $gmt_time ) { }}} {{{ if ( array_key_first( $crons ) > $gmt_time ) { }}} Both functions return early a few lines above when `$crons` is empty, so `isset( $keys[0] )` can never be false there. **Behavior notes** - On an empty array `reset()` returns `false` while `array_key_first()` returns `null`. None of the touched call sites compares the result with `===`, and most sit behind an `empty()` guard. - Where the old code used `$keys[0]`, the new code is strictly safer: `$keys[0]` emitted a notice on an empty array, `array_key_first()` returns `null` quietly. Developed in https://github.com/WordPress/wordpress-develop/pull/12790. Follow-up to r63297. Props Soean, mukesh27. See #65773. git-svn-id: https://develop.svn.wordpress.org/trunk@63567 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/import.php | 3 +-- src/wp-admin/includes/class-plugin-upgrader.php | 4 +--- src/wp-admin/includes/media.php | 7 +++---- src/wp-admin/includes/plugin-install.php | 3 +-- src/wp-admin/includes/revision.php | 3 +-- src/wp-admin/plugin-editor.php | 3 +-- src/wp-admin/widgets-form.php | 3 +-- src/wp-includes/class-wp-query.php | 5 ++--- src/wp-includes/cron.php | 6 ++---- .../endpoints/class-wp-rest-block-directory-controller.php | 4 +--- src/wp-includes/widgets/class-wp-widget-tag-cloud.php | 3 +-- 11 files changed, 15 insertions(+), 29 deletions(-) diff --git a/src/wp-admin/import.php b/src/wp-admin/import.php index ce17a70f20cf3..98ecd9bb3836a 100644 --- a/src/wp-admin/import.php +++ b/src/wp-admin/import.php @@ -118,8 +118,7 @@ // Looks like an importer is installed, but not active. $plugins = get_plugins( '/' . $plugin_slug ); if ( ! empty( $plugins ) ) { - $keys = array_keys( $plugins ); - $plugin_file = $plugin_slug . '/' . $keys[0]; + $plugin_file = $plugin_slug . '/' . array_key_first( $plugins ); $url = wp_nonce_url( add_query_arg( array( diff --git a/src/wp-admin/includes/class-plugin-upgrader.php b/src/wp-admin/includes/class-plugin-upgrader.php index f5290ff5258f6..5361c63821c14 100644 --- a/src/wp-admin/includes/class-plugin-upgrader.php +++ b/src/wp-admin/includes/class-plugin-upgrader.php @@ -542,9 +542,7 @@ public function plugin_info() { } // Assume the requested plugin is the first in the list. - $plugin_files = array_keys( $plugin ); - - return $this->result['destination_name'] . '/' . $plugin_files[0]; + return $this->result['destination_name'] . '/' . array_key_first( $plugin ); } /** diff --git a/src/wp-admin/includes/media.php b/src/wp-admin/includes/media.php index be10d2f7bf0b6..beaf88101e648 100644 --- a/src/wp-admin/includes/media.php +++ b/src/wp-admin/includes/media.php @@ -796,8 +796,7 @@ function media_upload_form_handler() { $errors = null; if ( isset( $_POST['send'] ) ) { - $keys = array_keys( $_POST['send'] ); - $send_id = (int) reset( $keys ); + $send_id = (int) array_key_first( $_POST['send'] ); } if ( ! empty( $_POST['attachments'] ) ) { @@ -1685,8 +1684,8 @@ function get_media_item( $attachment_id, $args = null ) { $title = esc_attr( $post->post_title ); $post_mime_types = get_post_mime_types(); - $keys = array_keys( wp_match_mime_types( array_keys( $post_mime_types ), $post->post_mime_type ) ); - $type = reset( $keys ); + $matched_types = wp_match_mime_types( array_keys( $post_mime_types ), $post->post_mime_type ); + $type = array_key_first( $matched_types ) ?? ''; $type_html = ""; $form_fields = get_attachment_fields_to_edit( $post, $parsed_args['errors'] ); diff --git a/src/wp-admin/includes/plugin-install.php b/src/wp-admin/includes/plugin-install.php index 62e93a36eef5d..b37b956d3455c 100644 --- a/src/wp-admin/includes/plugin-install.php +++ b/src/wp-admin/includes/plugin-install.php @@ -593,8 +593,7 @@ function install_plugin_information() { // Default to the Description tab, Do not translate, API returns English. $section = isset( $_REQUEST['section'] ) ? wp_unslash( $_REQUEST['section'] ) : 'description'; if ( empty( $section ) || ! isset( $api->sections[ $section ] ) ) { - $section_titles = array_keys( (array) $api->sections ); - $section = reset( $section_titles ); + $section = array_key_first( (array) $api->sections ); } iframe_header( __( 'Plugin Installation' ) ); diff --git a/src/wp-admin/includes/revision.php b/src/wp-admin/includes/revision.php index 2f15f1c9e2faf..ec58011f7a3a0 100644 --- a/src/wp-admin/includes/revision.php +++ b/src/wp-admin/includes/revision.php @@ -325,8 +325,7 @@ function wp_prepare_revisions_for_js( $post, $selected_revision_id, $from = null if ( ! $compare_two_mode ) { $found = array_search( $selected_revision_id, array_keys( $revisions ), true ); if ( $found ) { - $from = array_keys( array_slice( $revisions, $found - 1, 1, true ) ); - $from = reset( $from ); + $from = array_key_first( array_slice( $revisions, $found - 1, 1, true ) ); } else { $from = 0; } diff --git a/src/wp-admin/plugin-editor.php b/src/wp-admin/plugin-editor.php index 4beee7b8409da..b129a7652b28b 100644 --- a/src/wp-admin/plugin-editor.php +++ b/src/wp-admin/plugin-editor.php @@ -71,8 +71,7 @@ $plugin = $file; } } else { - $plugin = array_keys( $plugins ); - $plugin = $plugin[0]; + $plugin = array_key_first( $plugins ); } } diff --git a/src/wp-admin/widgets-form.php b/src/wp-admin/widgets-form.php index e47905c5d0099..25ee8215b9678 100644 --- a/src/wp-admin/widgets-form.php +++ b/src/wp-admin/widgets-form.php @@ -229,8 +229,7 @@ if ( isset( $_GET['addnew'] ) ) { // Default to the first sidebar. - $keys = array_keys( $wp_registered_sidebars ); - $sidebar = reset( $keys ); + $sidebar = array_key_first( $wp_registered_sidebars ); if ( isset( $_GET['base'] ) && isset( $_GET['num'] ) ) { // Multi-widget. // Copy minimal info from an existing instance of this widget to a new instance. diff --git a/src/wp-includes/class-wp-query.php b/src/wp-includes/class-wp-query.php index 9385ae832ff66..1d6b652c5a610 100644 --- a/src/wp-includes/class-wp-query.php +++ b/src/wp-includes/class-wp-query.php @@ -4028,9 +4028,8 @@ public function get_queried_object() { } else { // For other tax queries, grab the first term from the first clause. if ( ! empty( $this->tax_query->queried_terms ) ) { - $queried_taxonomies = array_keys( $this->tax_query->queried_terms ); - $matched_taxonomy = reset( $queried_taxonomies ); - $query = $this->tax_query->queried_terms[ $matched_taxonomy ]; + $matched_taxonomy = array_key_first( $this->tax_query->queried_terms ); + $query = $this->tax_query->queried_terms[ $matched_taxonomy ]; if ( ! empty( $query['terms'] ) ) { if ( 'term_id' === $query['field'] ) { diff --git a/src/wp-includes/cron.php b/src/wp-includes/cron.php index 82889d7cc7e2f..1070ae4680b91 100644 --- a/src/wp-includes/cron.php +++ b/src/wp-includes/cron.php @@ -929,8 +929,7 @@ function spawn_cron( $gmt_time = 0 ) { return false; } - $keys = array_keys( $crons ); - if ( isset( $keys[0] ) && $keys[0] > $gmt_time ) { + if ( array_key_first( $crons ) > $gmt_time ) { return false; } @@ -1059,8 +1058,7 @@ function _wp_cron() { } $gmt_time = microtime( true ); - $keys = array_keys( $crons ); - if ( isset( $keys[0] ) && $keys[0] > $gmt_time ) { + if ( array_key_first( $crons ) > $gmt_time ) { return 0; } diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-block-directory-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-block-directory-controller.php index c2c92efbbcd22..31267f9600671 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-block-directory-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-block-directory-controller.php @@ -200,9 +200,7 @@ protected function find_plugin_for_slug( $slug ) { return ''; } - $plugin_files = array_keys( $plugin_files ); - - return $slug . '/' . reset( $plugin_files ); + return $slug . '/' . array_key_first( $plugin_files ); } /** diff --git a/src/wp-includes/widgets/class-wp-widget-tag-cloud.php b/src/wp-includes/widgets/class-wp-widget-tag-cloud.php index c56a774b111a4..aeb3c09ce8e10 100644 --- a/src/wp-includes/widgets/class-wp-widget-tag-cloud.php +++ b/src/wp-includes/widgets/class-wp-widget-tag-cloud.php @@ -169,8 +169,7 @@ public function form( $instance ) { // Just a single tag cloud supporting taxonomy found, no need to display a select. case 1: - $keys = array_keys( $taxonomies ); - $taxonomy = reset( $keys ); + $taxonomy = array_key_first( $taxonomies ); ?> Date: Wed, 9 Sep 2026 21:11:48 +0000 Subject: [PATCH 186/363] Docs: Update outdated upstream Chrome documentation link in `WP_Site_Icon`. Props mayur8991, harishtewari, logicrays, sabernhardt. Fixes #65940. git-svn-id: https://develop.svn.wordpress.org/trunk@63568 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-site-icon.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/wp-admin/includes/class-wp-site-icon.php b/src/wp-admin/includes/class-wp-site-icon.php index ea0ab35007327..542bddbb4a1e7 100644 --- a/src/wp-admin/includes/class-wp-site-icon.php +++ b/src/wp-admin/includes/class-wp-site-icon.php @@ -48,8 +48,7 @@ class WP_Site_Icon { /* * App icon for Android/Chrome. * - * @link https://developers.google.com/web/updates/2014/11/Support-for-theme-color-in-Chrome-39-for-Android - * @link https://developer.chrome.com/multidevice/android/installtohomescreen + * @link https://developer.chrome.com/blog/support-for-theme-color-in-chrome-39-for-android */ 192, From 27cb8012ac0b45c47f339fc04bb53b0f69af2f50 Mon Sep 17 00:00:00 2001 From: Jb Audras Date: Wed, 9 Sep 2026 21:17:25 +0000 Subject: [PATCH 187/363] Docs: Replace `@see` with `@link` in `WP_Site_Icon` various docblocks. This changeset ensures these external links declaration is consistent with WordPress/PHP Documentation Standards. See #65860. git-svn-id: https://develop.svn.wordpress.org/trunk@63569 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-site-icon.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-admin/includes/class-wp-site-icon.php b/src/wp-admin/includes/class-wp-site-icon.php index 542bddbb4a1e7..411302385cda9 100644 --- a/src/wp-admin/includes/class-wp-site-icon.php +++ b/src/wp-admin/includes/class-wp-site-icon.php @@ -41,7 +41,7 @@ class WP_Site_Icon { /* * Square, medium sized tiles for IE11+. * - * See https://msdn.microsoft.com/library/dn455106(v=vs.85).aspx + * @link https://msdn.microsoft.com/library/dn455106(v=vs.85).aspx */ 270, @@ -55,7 +55,7 @@ class WP_Site_Icon { /* * App icons up to iPhone 6 Plus. * - * See https://developer.apple.com/library/prerelease/ios/documentation/UserExperience/Conceptual/MobileHIG/IconMatrix.html + * @link https://developer.apple.com/library/prerelease/ios/documentation/UserExperience/Conceptual/MobileHIG/IconMatrix.html */ 180, From 285d4d10cdb2edf19c01d5592cabb32452014f16 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Wed, 9 Sep 2026 22:24:50 +0000 Subject: [PATCH 188/363] Sitemaps: Don't 404 valid sitemaps on sites with no posts. `WP::handle_404()` sets a 404 when the main query matches no posts and no exception applies. Sitemap requests were never among those exceptions; they were shielded only incidentally, by falling through to `is_home`, and in r62664 that fallthrough was removed. A site with no published posts therefore served a complete, valid sitemap under a 404 status, which search engines discard. Exempt sitemap and stylesheet routes there, alongside the existing admin, robots and favicon exceptions. Since `handle_404()` no longer decides the status for these requests, every sitemap 404 now has to be issued by `WP_Sitemaps::render_sitemaps()` instead: an unregistered provider, an unrecognized stylesheet type, and a route whose query vars do not survive `sanitize_text_field()` would each otherwise be served as a 200 on an arbitrary URL. These share a `send_404()` helper, which also sends the no-cache headers `handle_404()` was previously contributing, so an intermediary does not retain a 404 for a route that becomes valid once the site has more content. Sitemaps disabled via the `wp_sitemaps_enabled` filter, and providers with an empty URL list, keep the status they already had; whether the latter should render an empty sitemap instead is #61293. Developed in https://github.com/WordPress/wordpress-develop/pull/13247. Follow-up to r48072, r48523, r62664. Props iamchitti, westonruter, fernandot, wildworks, harishtewari, l1onofjudah, luksusspokoju, abrahamfariaz, andreasca, siliconforks, adamsilverstein, audrasjb, ocean90, mrkenobi. See #39157, #61293. Fixes #65945. git-svn-id: https://develop.svn.wordpress.org/trunk@63570 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp.php | 5 +- .../sitemaps/class-wp-sitemaps.php | 52 ++++++-- tests/phpunit/tests/sitemaps/sitemaps.php | 104 ++++++++++++++++ tests/phpunit/tests/wp/handle404.php | 117 ++++++++++++++++++ 4 files changed, 268 insertions(+), 10 deletions(-) create mode 100644 tests/phpunit/tests/wp/handle404.php diff --git a/src/wp-includes/class-wp.php b/src/wp-includes/class-wp.php index f1664747d4042..ad6ce74b1716e 100644 --- a/src/wp-includes/class-wp.php +++ b/src/wp-includes/class-wp.php @@ -746,8 +746,9 @@ public function handle_404() { $set_404 = true; - // Never 404 for the admin, robots, or favicon. - if ( is_admin() || is_robots() || is_favicon() ) { + // Never 404 here for the admin, robots, favicon, or sitemaps. + // Sitemap routes send their own status in WP_Sitemaps::render_sitemaps(). + if ( is_admin() || is_robots() || is_favicon() || is_sitemap() || get_query_var( 'sitemap-stylesheet' ) ) { $set_404 = false; // If posts were found, check for paged content. diff --git a/src/wp-includes/sitemaps/class-wp-sitemaps.php b/src/wp-includes/sitemaps/class-wp-sitemaps.php index d4bbe38c86b11..87b3765b3f2e3 100644 --- a/src/wp-includes/sitemaps/class-wp-sitemaps.php +++ b/src/wp-includes/sitemaps/class-wp-sitemaps.php @@ -157,30 +157,45 @@ public function register_rewrites() { * Renders sitemap templates based on rewrite rules. * * @since 5.5.0 - * - * @global WP_Query $wp_query WordPress Query object. */ public function render_sitemaps() { - global $wp_query; + /* + * Bail early if this isn't a sitemap or stylesheet route. + * + * This runs on every front-end request, so it comes before any + * sanitizing. The raw query vars are tested here, matching + * WP::handle_404(), which exempts sitemap requests from its own 404 on + * the same basis. Testing the sanitized values instead would let a + * request that handle_404() exempted fall through both, leaving it a 200. + */ + if ( ! get_query_var( 'sitemap' ) && ! get_query_var( 'sitemap-stylesheet' ) ) { + return; + } $sitemap = sanitize_text_field( get_query_var( 'sitemap' ) ); $object_subtype = sanitize_text_field( get_query_var( 'sitemap-subtype' ) ); $stylesheet_type = sanitize_text_field( get_query_var( 'sitemap-stylesheet' ) ); $paged = absint( get_query_var( 'paged' ) ); - // Bail early if this isn't a sitemap or stylesheet route. + // Force a 404 and bail early if the route did not survive sanitizing. if ( ! ( $sitemap || $stylesheet_type ) ) { + $this->send_404(); return; } if ( ! $this->sitemaps_enabled() ) { - $wp_query->set_404(); - status_header( 404 ); + $this->send_404(); return; } // Render stylesheet if this is stylesheet route. if ( $stylesheet_type ) { + // Force a 404 and bail early if the stylesheet type is not recognized. + if ( ! in_array( $stylesheet_type, array( 'sitemap', 'index' ), true ) ) { + $this->send_404(); + return; + } + $stylesheet = new WP_Sitemaps_Stylesheet(); $stylesheet->render_stylesheet( $stylesheet_type ); @@ -197,7 +212,9 @@ public function render_sitemaps() { $provider = $this->registry->get_provider( $sitemap ); + // Force a 404 and bail early if the requested provider is not registered. if ( ! $provider ) { + $this->send_404(); return; } @@ -209,8 +226,7 @@ public function render_sitemaps() { // Force a 404 and bail early if no URLs are present. if ( empty( $url_list ) ) { - $wp_query->set_404(); - status_header( 404 ); + $this->send_404(); return; } @@ -218,6 +234,26 @@ public function render_sitemaps() { exit; } + /** + * Sends a 404 for a sitemap route that cannot be served. + * + * WP::handle_404() exempts sitemap requests, so every sitemap 404 is issued + * here instead. That includes the no-cache headers handle_404() sends with + * its own 404, so an intermediary does not retain a 404 for a route that + * becomes valid once the site has more content. + * + * @since 7.1.1 + * + * @global WP_Query $wp_query WordPress Query object. + */ + private function send_404(): void { + global $wp_query; + + $wp_query->set_404(); + status_header( 404 ); + nocache_headers(); + } + /** * Redirects a URL to the wp-sitemap.xml * diff --git a/tests/phpunit/tests/sitemaps/sitemaps.php b/tests/phpunit/tests/sitemaps/sitemaps.php index 24243787d5068..3a0d3adc4e675 100644 --- a/tests/phpunit/tests/sitemaps/sitemaps.php +++ b/tests/phpunit/tests/sitemaps/sitemaps.php @@ -493,4 +493,108 @@ public function test_empty_url_list_should_return_404() { $this->assertTrue( is_404() ); } + + /** + * Ensures a paged subtype route with no URLs still 404s, now that + * WP::handle_404() no longer sets a 404 for sitemap requests. + * + * @ticket 65945 + */ + public function test_empty_url_list_for_subtype_should_return_404() { + wp_register_sitemap_provider( 'foo', new WP_Sitemaps_Empty_Test_Provider( 'foo' ) ); + + $this->go_to( home_url( '/?sitemap=foo&sitemap-subtype=bar&paged=2' ) ); + + wp_sitemaps_get_server()->render_sitemaps(); + + $this->assertTrue( is_404() ); + } + + /** + * Ensures a sitemap query var that does not survive sanitizing 404s. + * + * WP::handle_404() exempts these requests on the raw query var, while + * render_sitemaps() acts on the sanitized value. Without a matching bail + * they fall through both and an arbitrary URL is served as a 200. + * + * @ticket 65945 + * + * @dataProvider data_unusable_sitemap_query_vars + * + * @param non-falsy-string $query_string Query string to append to a nonexistent URL. + */ + public function test_unusable_sitemap_query_var_should_return_404( string $query_string ) { + $this->set_permalink_structure( '/%postname%/' ); + + // Instantiate the server before navigating: registering the sitemap + // rewrite tags is what adds the query vars to `$wp->public_query_vars`. + $sitemaps = wp_sitemaps_get_server(); + + $this->go_to( home_url( '/this-page-does-not-exist/' . $query_string ) ); + + $this->assertFalse( is_404(), 'WP::handle_404() should not have set a 404.' ); + + $sitemaps->render_sitemaps(); + + $this->assertTrue( is_404(), 'render_sitemaps() should have set a 404.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_unusable_sitemap_query_vars(): array { + return array( + 'value stripped by sanitizing' => array( '?sitemap=<>' ), + 'array sitemap value' => array( '?sitemap[]=index' ), + 'array stylesheet value' => array( '?sitemap-stylesheet[]=sitemap' ), + ); + } + + /** + * Ensures an unrecognized stylesheet type 404s from render_sitemaps(). + * + * WP::handle_404() exempts any request carrying a `sitemap-stylesheet` + * query var, and WP_Sitemaps_Stylesheet::render_stylesheet() echoes nothing + * for a type other than 'sitemap' or 'index', so this route would otherwise + * be served as a 200 with an empty body. + * + * @ticket 65945 + */ + public function test_unrecognized_stylesheet_type_should_return_404() { + // Instantiate the server before navigating: registering the sitemap rewrite + // tags is what adds `sitemap-stylesheet` to `$wp->public_query_vars`. + $sitemaps = wp_sitemaps_get_server(); + + $this->go_to( home_url( '/?sitemap-stylesheet=this-is-not-a-stylesheet' ) ); + + $this->assertFalse( is_404(), 'WP::handle_404() should not have set a 404.' ); + + $sitemaps->render_sitemaps(); + + $this->assertTrue( is_404(), 'render_sitemaps() should have set a 404.' ); + } + + /** + * Ensures an unregistered provider 404s from render_sitemaps(). + * + * WP::handle_404() exempts every sitemap request, so this route would + * otherwise be served with a 200. + * + * @ticket 65945 + */ + public function test_unregistered_provider_should_return_404() { + // Instantiate the server before navigating: registering the sitemap + // rewrite tags is what adds `sitemap` to `$wp->public_query_vars`. + $sitemaps = wp_sitemaps_get_server(); + + $this->go_to( home_url( '/?sitemap=this-provider-does-not-exist' ) ); + + $this->assertFalse( is_404(), 'WP::handle_404() should not have set a 404.' ); + + $sitemaps->render_sitemaps(); + + $this->assertTrue( is_404(), 'render_sitemaps() should have set a 404.' ); + } } diff --git a/tests/phpunit/tests/wp/handle404.php b/tests/phpunit/tests/wp/handle404.php new file mode 100644 index 0000000000000..4b6b55064367e --- /dev/null +++ b/tests/phpunit/tests/wp/handle404.php @@ -0,0 +1,117 @@ +set_permalink_structure( '/%postname%/' ); + + /* + * Priming the server re-registers the sitemap query vars. tear_down() + * replaces the $wp global with a fresh WP instance, which carries only + * the built-in public query vars, and nulls $GLOBALS['wp_sitemaps'] so + * that this call re-runs WP_Sitemaps::init() and adds them back. + */ + wp_sitemaps_get_server(); + } + + /** + * A sitemap request must not be turned into a 404 by an empty main query. + * + * Whether the sitemap exists is decided later by WP_Sitemaps::render_sitemaps(), + * so some of these URLs still 404 in a full request, just not from here. + * + * @ticket 65945 + * + * @dataProvider data_sitemap_requests + * + * @param non-falsy-string $url Sitemap URL to request. + */ + public function test_sitemap_requests_should_not_be_404ed_by_an_empty_main_query( string $url ) { + $this->go_to( home_url( $url ) ); + + $this->assertTrue( is_sitemap(), 'The request should be recognized as a sitemap request.' ); + $this->assertFalse( is_404(), 'WP::handle_404() should not have set a 404.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_sitemap_requests(): array { + return array( + 'index' => array( '/?sitemap=index' ), + 'posts provider' => array( '/?sitemap=posts&sitemap-subtype=post' ), + 'posts provider, paged' => array( '/?sitemap=posts&sitemap-subtype=post&paged=2' ), + 'pages provider, paged' => array( '/?sitemap=posts&sitemap-subtype=page&paged=2' ), + 'taxonomies provider' => array( '/?sitemap=taxonomies&sitemap-subtype=category' ), + 'taxonomies provider,paged' => array( '/?sitemap=taxonomies&sitemap-subtype=category&paged=3' ), + 'users provider, paged' => array( '/?sitemap=users&paged=2' ), + ); + } + + /** + * The sitemap stylesheet routes must not be 404ed either. + * + * Covered separately because is_sitemap() only reflects the `sitemap` query var. + * + * @ticket 65945 + * + * @dataProvider data_sitemap_stylesheet_requests + * + * @param non-falsy-string $url Stylesheet URL to request. + */ + public function test_sitemap_stylesheet_requests_should_not_be_404ed_by_an_empty_main_query( string $url ) { + $this->go_to( home_url( $url ) ); + + $this->assertFalse( is_404(), 'WP::handle_404() should not have set a 404.' ); + } + + /** + * Data provider. + * + * @return array + */ + public function data_sitemap_stylesheet_requests(): array { + return array( + 'sitemap stylesheet' => array( '/?sitemap-stylesheet=sitemap' ), + 'index stylesheet' => array( '/?sitemap-stylesheet=index' ), + // Not a real route, but the only stylesheet case is_home() doesn't already cover. + 'sitemap stylesheet, paged' => array( '/?sitemap-stylesheet=sitemap&paged=2' ), + ); + } + + /** + * A genuinely unknown URL must still 404. + * + * @ticket 65945 + */ + public function test_non_sitemap_request_should_still_404() { + $this->go_to( home_url( '/this-page-does-not-exist/' ) ); + + $this->assertFalse( is_sitemap(), 'The request should not be a sitemap request.' ); + $this->assertTrue( is_404(), 'An unknown URL should still be a 404.' ); + } + + /** + * An unregistered sitemap provider must not be turned into a 404 here. + * + * render_sitemaps() sends that status itself, covered in Tests_Sitemaps_Sitemaps. + * + * @ticket 65945 + */ + public function test_unregistered_sitemap_provider_should_not_404_in_handle_404() { + $this->go_to( home_url( '/?sitemap=this-provider-does-not-exist' ) ); + + $this->assertTrue( is_sitemap(), 'The request should be recognized as a sitemap request.' ); + $this->assertFalse( is_404(), 'WP::handle_404() should not have set a 404.' ); + } +} From 90dcece80797dab5aa9688bc712225fc0899c7d7 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Thu, 10 Sep 2026 09:03:16 +0000 Subject: [PATCH 189/363] General: Enable the JSDoc rule require-param-name. Also, sorts the rules alphabetically in `.eslintrc-jsdoc.js`. Part of the effort to improve JS inline documentation for 7.2. Developed in https://github.com/WordPress/wordpress-develop/pull/13473 See #66033. git-svn-id: https://develop.svn.wordpress.org/trunk@63577 602fd350-edb4-49c9-b593-d223f7449a82 --- .eslintrc-jsdoc.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.eslintrc-jsdoc.js b/.eslintrc-jsdoc.js index 12d2bf9a0922d..e3c98d449f3c5 100644 --- a/.eslintrc-jsdoc.js +++ b/.eslintrc-jsdoc.js @@ -37,7 +37,7 @@ module.exports = [ }, rules: { 'jsdoc/check-param-names': 'error', - 'jsdoc/check-types': 'error', + 'jsdoc/check-syntax': 'error', 'jsdoc/check-tag-names': [ 'error', { definedTags: [ 'memberOf', @@ -46,17 +46,18 @@ module.exports = [ 'link', ], } ], + 'jsdoc/check-types': 'error', + 'jsdoc/require-description': 'error', + 'jsdoc/require-jsdoc': 'error', 'jsdoc/require-param': [ 'error', { enableFixer: false, } ], + 'jsdoc/require-param-name': 'error', 'jsdoc/require-param-type': 'error', + 'jsdoc/require-returns': 'error', 'jsdoc/require-returns-check': 'error', 'jsdoc/require-returns-description': 'error', - 'jsdoc/require-returns': 'error', 'jsdoc/require-returns-type': 'error', - 'jsdoc/check-syntax': 'error', - 'jsdoc/require-description': 'error', - 'jsdoc/require-jsdoc': 'error', }, }, ]; From 50d75551577d0c637d1955dc8ebbb360dd6bf9ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Maneiro?= Date: Thu, 10 Sep 2026 09:48:17 +0000 Subject: [PATCH 190/363] View Config: add form info for root/site entity. Props oandregal, ntsekouras. Part of #65981. git-svn-id: https://develop.svn.wordpress.org/trunk@63578 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/default-filters.php | 1 + src/wp-includes/view-config.php | 33 +++++++++++++++++++ .../rest-api/rest-view-config-controller.php | 29 ++++++++++++++++ 3 files changed, 63 insertions(+) diff --git a/src/wp-includes/default-filters.php b/src/wp-includes/default-filters.php index d16979c9c8fb5..a839ef92966b4 100644 --- a/src/wp-includes/default-filters.php +++ b/src/wp-includes/default-filters.php @@ -834,5 +834,6 @@ 5 ); } +add_filter( 'get_entity_view_config_root_site', '_wp_get_entity_view_config_root_site', 5 ); unset( $filter, $action, $post_type ); diff --git a/src/wp-includes/view-config.php b/src/wp-includes/view-config.php index d972515c12438..8765a5d095008 100644 --- a/src/wp-includes/view-config.php +++ b/src/wp-includes/view-config.php @@ -769,3 +769,36 @@ function _wp_get_entity_view_config_posttype_wp_template( $data ) { return $data; } + +/** + * Provides the view configuration for the `root`/`site` entity. + * + * The site settings are a singleton record edited through a form (the site + * editor's Identity screen) rather than listed in a view, so only the `form` + * is defined here. The generic `default_view`, `default_layouts`, and + * `view_list` built by wp_get_entity_view_config() are left untouched. + * + * @since 7.2.0 + * + * @param WP_View_Config_Data $data The view configuration container for the entity. + * @return WP_View_Config_Data The updated view configuration container. + */ +function _wp_get_entity_view_config_root_site( $data ) { + return $data->set( + array( + 'form' => array( + 'layout' => array( + 'type' => 'regular', + 'labelPosition' => 'top', + ), + 'fields' => array( + 'title', + 'description', + 'site_logo', + 'site_icon', + ), + ), + ), + 1 + ); +} diff --git a/tests/phpunit/tests/rest-api/rest-view-config-controller.php b/tests/phpunit/tests/rest-api/rest-view-config-controller.php index 34fcd55e2466d..c6a7ed86b816d 100644 --- a/tests/phpunit/tests/rest-api/rest-view-config-controller.php +++ b/tests/phpunit/tests/rest-api/rest-view-config-controller.php @@ -302,6 +302,35 @@ public function test_get_items_matches_underlying_config() { $this->assertSame( $config['form'], $data['form'] ); } + /** + * The `root`/`site` entity provides the form of the site identity screen. + * + * @ticket 65981 + * + * @covers ::get_items + */ + public function test_get_items_root_site_form() { + // Admin: reading root config requires `manage_options`. + wp_set_current_user( self::$admin_id ); + + $response = $this->dispatch_request( 'root', 'site' ); + $this->assertSame( 200, $response->get_status() ); + + $data = json_decode( wp_json_encode( $response->get_data() ), true ); + + $this->assertSame( + array( + 'type' => 'regular', + 'labelPosition' => 'top', + ), + $data['form']['layout'] + ); + $this->assertSame( + array( 'title', 'description', 'site_logo', 'site_icon' ), + $data['form']['fields'] + ); + } + /** * Empty object-typed config values serialize as JSON objects ({}), not arrays ([]). * From 8fd586426d7da9034ad1f0808e0914a8390f5521 Mon Sep 17 00:00:00 2001 From: Jon Surrell Date: Thu, 10 Sep 2026 10:48:20 +0000 Subject: [PATCH 191/363] Script Loader: Avoid a false entry in inline script data. `WP_Scripts::get_data()` returns `false` when a handle has no `before` or `after` data, and casting that to an array produced `array( false )`. The first inline script added for a handle was therefore stored after an unused `false` entry. Missing inline script data is now treated as an empty array. Developed in: https://github.com/WordPress/wordpress-develop/pull/12217 Follow-up to r36633. Props vanyukov, sukhendu2002, jonsurrell, apermo. Fixes #52320. git-svn-id: https://develop.svn.wordpress.org/trunk@63579 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-scripts.php | 3 +- tests/phpunit/tests/dependencies/scripts.php | 32 ++++++++++++++++++++ 2 files changed, 34 insertions(+), 1 deletion(-) diff --git a/src/wp-includes/class-wp-scripts.php b/src/wp-includes/class-wp-scripts.php index f8d32d375d040..36a0487bede56 100644 --- a/src/wp-includes/class-wp-scripts.php +++ b/src/wp-includes/class-wp-scripts.php @@ -527,7 +527,8 @@ public function add_inline_script( $handle, $data, $position = 'after' ) { $position = 'before'; } - $script = (array) $this->get_data( $handle, $position ); + $script = $this->get_data( $handle, $position ); + $script = false === $script ? array() : (array) $script; $script[] = $data; return $this->add_data( $handle, $position, $script ); diff --git a/tests/phpunit/tests/dependencies/scripts.php b/tests/phpunit/tests/dependencies/scripts.php index 1fabd1dbe4f35..63e5947e50abe 100644 --- a/tests/phpunit/tests/dependencies/scripts.php +++ b/tests/phpunit/tests/dependencies/scripts.php @@ -230,6 +230,38 @@ public function data_provider_delayed_strategies() { ); } + /** + * Tests that inline scripts do not include a false entry when no data exists yet. + * + * @ticket 52320 + * @dataProvider data_inline_script_positions + * + * @param string $position Inline script position. + */ + public function test_add_inline_script_does_not_store_false_for_empty_existing_data( $position ): void { + $handle = 'test-inline-script-' . $position; + + wp_register_script( $handle, '/test.js', array(), null ); + wp_add_inline_script( $handle, 'console.log( "test" );', $position ); + + $this->assertSame( + array( 'console.log( "test" );' ), + wp_scripts()->get_data( $handle, $position ) + ); + } + + /** + * Data provider for inline script positions. + * + * @return array Inline script positions. + */ + public function data_inline_script_positions(): array { + return array( + 'before' => array( 'before' ), + 'after' => array( 'after' ), + ); + } + /** * Tests that inline scripts in the `after` position, attached to delayed main scripts, remain unaffected. * From 3b66b016e8fbfa828a0c48b16320efdc67ef2aa3 Mon Sep 17 00:00:00 2001 From: Jon Surrell Date: Thu, 10 Sep 2026 11:18:52 +0000 Subject: [PATCH 192/363] I18N: Validate cached translation file lists. Prevent possible fatal errors on bad cached values by validating the caches is an array of strings. Developed in: https://github.com/WordPress/wordpress-develop/pull/13429 Props josephscott, jonsurrell. Fixes #66063. git-svn-id: https://develop.svn.wordpress.org/trunk@63580 602fd350-edb4-49c9-b593-d223f7449a82 --- .../class-wp-textdomain-registry.php | 8 +++ .../tests/l10n/wpTextdomainRegistry.php | 69 +++++++++++++++++++ 2 files changed, 77 insertions(+) diff --git a/src/wp-includes/class-wp-textdomain-registry.php b/src/wp-includes/class-wp-textdomain-registry.php index 7d924d5abdf1d..8387d382ec1c0 100644 --- a/src/wp-includes/class-wp-textdomain-registry.php +++ b/src/wp-includes/class-wp-textdomain-registry.php @@ -209,6 +209,14 @@ public function get_language_files_from_path( $path ) { $cache_key = md5( $path ); $files = wp_cache_get( $cache_key, 'translation_files' ); + /* + * Verify that the cached value is an array and that all entries in that array + * are strings. + */ + if ( ! is_array( $files ) || array_filter( $files, 'is_string' ) !== $files ) { + $files = false; + } + if ( false === $files ) { $files = glob( $path . '*.mo' ); if ( false === $files ) { diff --git a/tests/phpunit/tests/l10n/wpTextdomainRegistry.php b/tests/phpunit/tests/l10n/wpTextdomainRegistry.php index 1402a86ce0ad4..60661830c464c 100644 --- a/tests/phpunit/tests/l10n/wpTextdomainRegistry.php +++ b/tests/phpunit/tests/l10n/wpTextdomainRegistry.php @@ -111,6 +111,75 @@ public function test_get_language_files_from_path_short_circuit() { $this->assertFalse( $cache ); } + /** + * A cached value that is not an array of strings is discarded and replaced + * by a fresh lookup. + * + * @ticket 66063 + * + * @covers ::get_language_files_from_path + * + * @dataProvider data_get_language_files_from_path_ignores_invalid_cached_values + * + * @param mixed $cached_value Value seeded into the cache. + */ + public function test_get_language_files_from_path_ignores_invalid_cached_values( $cached_value ): void { + $path = WP_LANG_DIR . '/plugins/'; + $cache_key = md5( $path ); + + wp_cache_set( $cache_key, $cached_value, 'translation_files' ); + + $result = $this->instance->get_language_files_from_path( $path ); + + $this->assertIsArray( $result, 'An array should be returned' ); + $this->assertNotEmpty( $result, 'The files should have been looked up instead of using the cached value' ); + foreach ( $result as $file ) { + $this->assertIsString( $file, 'All returned entries should be strings' ); + } + $this->assertSame( + $result, + wp_cache_get( $cache_key, 'translation_files' ), + 'The invalid cached value should have been replaced' + ); + } + + /** + * Data provider. + * + * @return array[] + */ + public static function data_get_language_files_from_path_ignores_invalid_cached_values(): array { + return array( + 'string' => array( 'not-an-array' ), + 'integer' => array( 1 ), + 'null' => array( null ), + 'object' => array( (object) array( WP_LANG_DIR . '/plugins/foo-de_DE.mo' ) ), + 'array with an array' => array( array( WP_LANG_DIR . '/plugins/foo-de_DE.mo', array( 'bar-de_DE.mo' ) ) ), + 'array with an integer' => array( array( WP_LANG_DIR . '/plugins/foo-de_DE.mo', 1 ) ), + 'array with null' => array( array( null ) ), + ); + } + + /** + * An empty array is a valid cached result for a directory without translation + * files and must not cause a new lookup. + * + * @ticket 66063 + * + * @covers ::get_language_files_from_path + */ + public function test_get_language_files_from_path_keeps_cached_empty_array(): void { + $path = WP_LANG_DIR . '/plugins/'; + + wp_cache_set( md5( $path ), array(), 'translation_files' ); + + $this->assertSame( + array(), + $this->instance->get_language_files_from_path( $path ), + 'A cached empty array should be returned without looking up the files' + ); + } + /** * @covers ::invalidate_mo_files_cache */ From ecb1850a895d570e79aad68c9dc353aa3816983c Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Thu, 10 Sep 2026 13:28:17 +0000 Subject: [PATCH 193/363] Privacy: Correct closing tag in results row on personal data tables. Developed in https://github.com/WordPress/wordpress-develop/pull/13470. Follow-up to r43216. Props hbhalodia, dhruvang21, afercia, sabernhardt. Fixes #66085. git-svn-id: https://develop.svn.wordpress.org/trunk@63581 602fd350-edb4-49c9-b593-d223f7449a82 --- src/js/_enqueues/admin/privacy-tools.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/_enqueues/admin/privacy-tools.js b/src/js/_enqueues/admin/privacy-tools.js index df24538ffaefc..0ffecfc1e9535 100644 --- a/src/js/_enqueues/admin/privacy-tools.js +++ b/src/js/_enqueues/admin/privacy-tools.js @@ -75,7 +75,7 @@ jQuery( function( $ ) { '

    ' + summaryMessage + '

    ' + itemList + '
    ' + - '' + + '' + ''; }); } From 032936fe3ea1ac616153e47c50ce22e10886cf3b Mon Sep 17 00:00:00 2001 From: John Blackbourn Date: Thu, 10 Sep 2026 13:58:33 +0000 Subject: [PATCH 194/363] Application Passwords: Send email notification when an application password is added. This introduces a filterable email notification so users get alerted when an application password is added to their account. The email can be filtered via the `wp_application_password_created_email` filter and disabled via the `wp_send_application_password_created_email` filter. Props prasadkarmalkar, johnbillion, audrasjb. Developed in https://github.com/WordPress/wordpress-develop/pull/9795 Fixes #63927 git-svn-id: https://develop.svn.wordpress.org/trunk@63582 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/default-filters.php | 3 + src/wp-includes/functions.php | 115 ++++++++++++++++++++++++++++ 2 files changed, 118 insertions(+) diff --git a/src/wp-includes/default-filters.php b/src/wp-includes/default-filters.php index a839ef92966b4..025a371781200 100644 --- a/src/wp-includes/default-filters.php +++ b/src/wp-includes/default-filters.php @@ -345,6 +345,9 @@ add_filter( 'rest_authentication_errors', 'rest_application_password_check_errors', 90 ); add_filter( 'rest_authentication_errors', 'rest_cookie_check_errors', 100 ); +// Application password notifications. +add_action( 'wp_create_application_password', 'wp_application_password_created_notification', 10, 2 ); + // Actions. add_action( 'wp_head', '_wp_render_title_tag', 1 ); add_action( 'wp_head', 'wp_enqueue_scripts', 1 ); diff --git a/src/wp-includes/functions.php b/src/wp-includes/functions.php index 4c323812991d7..4f5916a322620 100644 --- a/src/wp-includes/functions.php +++ b/src/wp-includes/functions.php @@ -9464,3 +9464,118 @@ function wp_verify_fast_hash( return hash_equals( $hash, wp_fast_hash( $message ) ); } + +/** + * Sends an email to the user when a new application password is created. + * + * @since 7.2.0 + * + * @param int $user_id The user ID. + * @param array $new_item The application password details. + */ +function wp_application_password_created_notification( $user_id, $new_item ) { + $send = true; + + // Get current user data. + $user = get_userdata( $user_id ); + + if ( ! $user ) { + return; + } + + if ( ! is_email( $user->user_email ) ) { + return; + } + + // Validate that the application password has a name. + if ( empty( $new_item['name'] ) ) { + return; + } + + /** + * Filters whether to send the application password created notification email. + * + * @since 7.2.0 + * + * @param bool $send Whether to send the email notification. + * @param WP_User $user The user object. + * @param array $new_item The application password details. + */ + $send = apply_filters( 'wp_send_application_password_created_email', $send, $user, $new_item ); + + if ( ! $send ) { + return; + } + + /* translators: Do not translate USERNAME, APPLICATION_PASSWORD_NAME, SITENAME, SITEURL, EMAIL: those are placeholders. */ + $application_password_create_text = __( + 'Hi ###USERNAME###, + +A new application password was added to your account on ###SITENAME###. This password allows access to your account via the REST API. + +If you did not expect this, please contact the Site Administrator at +###ADMIN_EMAIL### + +Application password name: ###APPLICATION_PASSWORD_NAME### +Site: ###SITEURL### + +You can manage your application passwords in your account settings. + +This email has been sent to ###EMAIL### + +Regards, +All at ###SITENAME### +###SITEURL###' + ); + + $email = array( + 'to' => $user->user_email, + /* translators: Application password creation email subject. %s: Site title. */ + 'subject' => __( '[%s] Application Password Created' ), + 'message' => $application_password_create_text, + 'headers' => '', + ); + + // Get site name. + $site_name = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ); + + /** + * Filters the contents of the email notification sent to a user when a new application password is created. + * + * @since 7.2.0 + * + * @param array $email { + * Used to build wp_mail(). + * + * @type string $to The email address of the intended recipient. + * @type string $subject The subject of the email. + * @type string $message The content of the email. + * The following strings have a special meaning and will get replaced dynamically: + * - `###USERNAME###` The user's display name. + * - `###APPLICATION_PASSWORD_NAME###` The name of the application password. + * - `###EMAIL###` The user's email address. + * - `###SITENAME###` The name of the site. + * - `###SITEURL###` The URL to the site. + * @type string $headers Headers. + * } + * @param WP_User $user The user object. + * @param array $new_item The application password details. + */ + $email = apply_filters( 'wp_application_password_created_email', $email, $user, $new_item ); + + $email['message'] = str_replace( '###USERNAME###', $user->display_name, $email['message'] ); + $email['message'] = str_replace( '###APPLICATION_PASSWORD_NAME###', $new_item['name'], $email['message'] ); + $email['message'] = str_replace( '###EMAIL###', $user->user_email, $email['message'] ); + $email['message'] = str_replace( '###SITENAME###', $site_name, $email['message'] ); + $email['message'] = str_replace( '###SITEURL###', home_url(), $email['message'] ); + + wp_mail( + $email['to'], + sprintf( + $email['subject'], + $site_name + ), + $email['message'], + $email['headers'] + ); +} From 9a2e38e2f3804f97ed47f241dc7f3081220b5f40 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 14:24:56 +0000 Subject: [PATCH 195/363] Build/Test Tools: Log relevant URLs in GitHub Actions. Log the workflow run, pull request, Trac ticket, and SVN changeset URLs handled by the automation workflows. Report skipped reruns and empty pull request searches, and avoid processing the same pull request more than once. Await comment creation so failures are reported and success notices reflect completed requests. Developed in: https://github.com/WordPress/wordpress-develop/pull/11223 Props arkaprabhachowdhury, adrianmoldovanwp, desrosj. Fixes #64299. git-svn-id: https://develop.svn.wordpress.org/trunk@63583 602fd350-edb4-49c9-b593-d223f7449a82 --- .github/workflows/failed-workflow.yml | 3 +++ .github/workflows/props-bot.yml | 5 +++++ .github/workflows/pull-request-comments.yml | 6 ++++-- .github/workflows/reusable-cleanup-pull-requests.yml | 11 ++++++++++- 4 files changed, 22 insertions(+), 3 deletions(-) diff --git a/.github/workflows/failed-workflow.yml b/.github/workflows/failed-workflow.yml index 288a2a9e0e930..2da0ff56989d7 100644 --- a/.github/workflows/failed-workflow.yml +++ b/.github/workflows/failed-workflow.yml @@ -43,9 +43,12 @@ jobs: // Only rerun after the first run attempt. if ( workflow_run.data.run_attempt > 1 ) { + core.info(`Skipping rerun, attempt ${workflow_run.data.run_attempt}: ${workflow_run.data.html_url}`); return; } + core.notice(`Rerunning workflow run "${workflow_run.data.name}" on ${workflow_run.data.head_branch}: ${workflow_run.data.html_url}`); + const rerun = await github.rest.actions.reRunWorkflowFailedJobs({ owner: context.repo.owner, repo: context.repo.repo, diff --git a/.github/workflows/props-bot.yml b/.github/workflows/props-bot.yml index 38acc07113c2c..eea736f5c4ea3 100644 --- a/.github/workflows/props-bot.yml +++ b/.github/workflows/props-bot.yml @@ -70,6 +70,11 @@ jobs: ( ! github.event.pull_request.draft && github.event.pull_request.state == 'open' || ! github.event.issue.draft && github.event.issue.state == 'open' ) steps: + - name: Output PR link + env: + PR_URL: ${{ github.event.pull_request.html_url || github.event.issue.html_url }} + run: 'echo "::notice::Pull request: $PR_URL"' + - name: Gather a list of contributors uses: WordPress/props-bot-action@trunk with: diff --git a/.github/workflows/pull-request-comments.yml b/.github/workflows/pull-request-comments.yml index 8dff8e1c1fcce..6c56326774b8d 100644 --- a/.github/workflows/pull-request-comments.yml +++ b/.github/workflows/pull-request-comments.yml @@ -121,7 +121,8 @@ jobs: [Test this pull request with WordPress Playground](https://playground.wordpress.net/wordpress.html?pr=${ issue_number }). `; - github.rest.issues.createComment( commentInfo ); + await github.rest.issues.createComment( commentInfo ); + core.notice( `Created Playground comment for pull request: ${ pr.data.html_url }` ); # Manages comments reminding contributors to include a Trac ticket link when opening a pull request. trac-ticket-check: @@ -160,7 +161,8 @@ jobs: const tracTicketMatches = prBody.match( tracTicketRegex ) || prTitle.match( tracTicketRegex ); if ( ! tracTicketMatches ) { - github.rest.issues.createComment( { + core.info( `Creating missing Trac ticket comment for pull request: ${ pr.html_url }` ); + await github.rest.issues.createComment( { owner, repo, issue_number: number, diff --git a/.github/workflows/reusable-cleanup-pull-requests.yml b/.github/workflows/reusable-cleanup-pull-requests.yml index 012f99adbec3b..a4c1e57d4ab5e 100644 --- a/.github/workflows/reusable-cleanup-pull-requests.yml +++ b/.github/workflows/reusable-cleanup-pull-requests.yml @@ -56,10 +56,14 @@ jobs: const githubSha = process.env.GITHUB_SHA; let prNumbers = []; + core.notice(`Processing pull request cleanup for SVN changeset: https://core.trac.wordpress.org/changeset/${svnRevisionNumber}`); + for (const ticket of fixedList) { const tracTicketUrl = `https://core.trac.wordpress.org/ticket/${ticket}`; const corePrefix = `core-${ticket}`; + core.info(`Ticket: ${tracTicketUrl}`); + const query = ` query($searchQuery: String!) { search(query: $searchQuery, type: ISSUE_ADVANCED, first: 20) { @@ -97,8 +101,13 @@ jobs: This PR will be closed, but please confirm the accuracy of this and reopen if there is more work to be done.`; + const uniquePrNumbers = [...new Set(prNumbers)]; + core.info(`Found ${uniquePrNumbers.length} pull request(s) to close.`); + // Update all matched pull requests. - for (const prNumber of prNumbers) { + for (const prNumber of uniquePrNumbers) { + core.info(`Closing pull request: https://github.com/${context.repo.owner}/${context.repo.repo}/pull/${prNumber}`); + // Comment on the pull request with details. await github.rest.issues.createComment({ owner: context.repo.owner, From 43e329df4bf23e55aff0b10132c93847f5121882 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 15:14:03 +0000 Subject: [PATCH 196/363] Build/Test Tools: Trim the routine PHPUnit database matrix. Test MySQL 5.7, 8.0, and 8.4 and MariaDB 5.5, 10.6, 10.11, 11.4, and 11.8 on pushes, pull requests, and manual runs. Keep the complete database matrix on the weekly schedule. Reduce routine coverage from 86 to 68 jobs while retaining the 182-job weekly matrix. Preserve the reporting, memcached, alternate-domain, HTML API, innovation-release, and PHP prerelease configurations. Developed in: https://github.com/WordPress/wordpress-develop/pull/13447 Props lucatume, adrianmoldovanwp. Fixes #66069. git-svn-id: https://develop.svn.wordpress.org/trunk@63584 602fd350-edb4-49c9-b593-d223f7449a82 --- .github/workflows/phpunit-tests.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/phpunit-tests.yml b/.github/workflows/phpunit-tests.yml index 8223d78780750..906674e285e2f 100644 --- a/.github/workflows/phpunit-tests.yml +++ b/.github/workflows/phpunit-tests.yml @@ -113,7 +113,8 @@ jobs: # The scheduled run tests every supported PHP version. Other events test the highest and lowest of each major. php: ${{ github.event_name == 'schedule' && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} db-type: [ 'mysql' ] - db-version: [ '5.7', '8.0', '8.4', '9.7' ] + # The scheduled run tests the full database matrix. Other events retain MySQL 5.7 compatibility and the widely used 8.x releases. + db-version: ${{ github.event_name == 'schedule' && fromJSON('["5.7","8.0","8.4","9.7"]') || fromJSON('["5.7","8.0","8.4"]') }} tests-domain: [ 'example.org' ] multisite: [ false, true ] memcached: [ false ] @@ -173,8 +174,8 @@ jobs: # # Creates a PHPUnit test job for each PHP/MariaDB combination. # - # All LTS versions of MariaDB supported by WordPress with greater than 1% usage according to w.org/stats should be - # tested. The exceptions to this rule are the most recent LTS and version 5.5. + # The scheduled run tests all LTS versions of MariaDB supported by WordPress with greater than 1% usage according to + # w.org/stats. The exceptions to this rule are the most recent LTS and version 5.5. # # The 5.5 release was intended as a drop-in replacement for MySQL. Because the MySQL 5.5 Docker containers do not # work, this ensures some level of MySQL 5.5 testing. @@ -205,7 +206,8 @@ jobs: # The scheduled run tests every supported PHP version. Other events test the highest and lowest of each major. php: ${{ github.event_name == 'schedule' && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} db-type: [ 'mariadb' ] - db-version: [ '5.5', '10.3', '10.5', '10.6', '10.11', '11.4', '11.8' ] + # The scheduled run tests the full database matrix. Other events retain MariaDB 5.5 compatibility, 10.6, and newer LTS releases. + db-version: ${{ github.event_name == 'schedule' && fromJSON('["5.5","10.3","10.5","10.6","10.11","11.4","11.8"]') || fromJSON('["5.5","10.6","10.11","11.4","11.8"]') }} multisite: [ false, true ] memcached: [ false ] From 0ee9f304ac249547bdcba342fdb156b875313095 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 15:16:09 +0000 Subject: [PATCH 197/363] Build/Test Tools: Run the full PHPUnit matrix by label. Allow reviewers to trigger the weekly PHP and database matrix on eligible pull requests by adding the Full PHPUnit Matrix label. Keep full coverage on subsequent commits while the label remains. Use a separate label-triggered workflow so unrelated labels do not replace PHPUnit checks or cancel active runs. Preserve the existing path filters and document the manual request process for contributors without label access. Developed in: https://github.com/WordPress/wordpress-develop/pull/13448 Props lucatume, adrianmoldovanwp. Fixes #66071. git-svn-id: https://develop.svn.wordpress.org/trunk@63585 602fd350-edb4-49c9-b593-d223f7449a82 --- .../workflows/phpunit-tests-full-matrix.yml | 65 +++++++++++++++++++ .github/workflows/phpunit-tests.yml | 43 ++++++++---- tests/phpunit/README.md | 12 ++++ 3 files changed, 108 insertions(+), 12 deletions(-) create mode 100644 .github/workflows/phpunit-tests-full-matrix.yml diff --git a/.github/workflows/phpunit-tests-full-matrix.yml b/.github/workflows/phpunit-tests-full-matrix.yml new file mode 100644 index 0000000000000..a6b42f6401174 --- /dev/null +++ b/.github/workflows/phpunit-tests-full-matrix.yml @@ -0,0 +1,65 @@ +name: PHPUnit Tests (label) +run-name: PHPUnit Tests${{ github.event.label.name == 'Full PHPUnit Matrix' && ' (full matrix)' || ' (ignored label)' }} + +on: + pull_request: + types: [ labeled ] + branches: + - trunk + - '3.[7-9]' + - '[4-9].[0-9]' + # Keep these paths in sync with phpunit-tests.yml. + paths: + - '**' + # Documentation and repository metadata. + - '!**.md' + - '!.devcontainer/**' + - '!.editorconfig' + - '!.git-blame-ignore-revs' + - '!.gitignore' + - '!.mailmap' + - '!typings/**' + # Configuration for unrelated checks. + - '!.eslintrc-jsdoc.js' + - '!.prettierrc.js' + - '!.version-support-*.json' + - '!eslint.config.js' + - '!jsdoc.conf.json' + - '!phpcompat.xml.dist' + - '!phpcs.xml.dist' + - '!phpstan.neon.dist' + - '!tsconfig.json' + # Other test suites, tools, and workflows do not affect these tests. + - '!tests/**' + - '!tools/**' + - '!.github/**' + # Re-include documentation, tests, tools, and workflows used here. + - 'SECURITY.md' + - 'src/license.txt' + - 'tests/phpunit/**' + - 'tools/gutenberg/**' + - 'tools/local-env/**' + - 'tools/vendors/**' + - 'tools/webpack/**' + - 'phpunit.xml.dist' + - '.github/workflows/phpunit-tests.yml' + - '.github/workflows/phpunit-tests-full-matrix.yml' + - '.github/workflows/reusable-phpunit-tests-*.yml' + - '.github/workflows/reusable-prepare-gutenberg.yml' + +# Disable permissions for all available scopes by default. +permissions: {} + +# The called workflow manages concurrency. Unrelated labels never enter it. +jobs: + full-matrix: + if: github.event.label.name == 'Full PHPUnit Matrix' + permissions: + # Required by the called workflow's recovery job, which is skipped on PR events. + actions: write + contents: read + uses: ./.github/workflows/phpunit-tests.yml + secrets: + CODEVITALS_PROJECT_TOKEN: ${{ secrets.CODEVITALS_PROJECT_TOKEN }} + CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} + WPT_REPORT_API_KEY: ${{ secrets.WPT_REPORT_API_KEY }} diff --git a/.github/workflows/phpunit-tests.yml b/.github/workflows/phpunit-tests.yml index 906674e285e2f..1e4a22bb61afc 100644 --- a/.github/workflows/phpunit-tests.yml +++ b/.github/workflows/phpunit-tests.yml @@ -1,4 +1,5 @@ name: PHPUnit Tests +run-name: PHPUnit Tests${{ ( github.event_name == 'schedule' || ( github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'Full PHPUnit Matrix' ) ) ) && ' (full matrix)' || '' }} on: push: @@ -11,6 +12,7 @@ on: - trunk - '3.[7-9]' - '[4-9].[0-9]' + # Keep these paths in sync with phpunit-tests-full-matrix.yml. paths: - '**' # Documentation and repository metadata. @@ -45,9 +47,26 @@ on: - 'tools/webpack/**' - 'phpunit.xml.dist' - '.github/workflows/phpunit-tests.yml' + - '.github/workflows/phpunit-tests-full-matrix.yml' - '.github/workflows/reusable-phpunit-tests-*.yml' - '.github/workflows/reusable-prepare-gutenberg.yml' workflow_dispatch: + workflow_call: + secrets: + CODEVITALS_PROJECT_TOKEN: + required: false + CODECOV_TOKEN: + required: false + WPT_REPORT_API_KEY: + required: false + SLACK_GHA_SUCCESS_WEBHOOK: + required: false + SLACK_GHA_CANCELLED_WEBHOOK: + required: false + SLACK_GHA_FIXED_WEBHOOK: + required: false + SLACK_GHA_FAILURE_WEBHOOK: + required: false # Once weekly On Sundays at 00:00 UTC. schedule: - cron: '0 0 * * 0' @@ -110,11 +129,11 @@ jobs: fail-fast: false matrix: os: [ ubuntu-24.04 ] - # The scheduled run tests every supported PHP version. Other events test the highest and lowest of each major. - php: ${{ github.event_name == 'schedule' && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} + # Scheduled and labeled runs test every supported PHP version. Other runs test the highest and lowest of each major. + php: ${{ ( github.event_name == 'schedule' || ( github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'Full PHPUnit Matrix' ) ) ) && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} db-type: [ 'mysql' ] - # The scheduled run tests the full database matrix. Other events retain MySQL 5.7 compatibility and the widely used 8.x releases. - db-version: ${{ github.event_name == 'schedule' && fromJSON('["5.7","8.0","8.4","9.7"]') || fromJSON('["5.7","8.0","8.4"]') }} + # Scheduled and labeled runs test the full database matrix. Other runs retain MySQL 5.7 compatibility and the widely used 8.x releases. + db-version: ${{ ( github.event_name == 'schedule' || ( github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'Full PHPUnit Matrix' ) ) ) && fromJSON('["5.7","8.0","8.4","9.7"]') || fromJSON('["5.7","8.0","8.4"]') }} tests-domain: [ 'example.org' ] multisite: [ false, true ] memcached: [ false ] @@ -174,8 +193,8 @@ jobs: # # Creates a PHPUnit test job for each PHP/MariaDB combination. # - # The scheduled run tests all LTS versions of MariaDB supported by WordPress with greater than 1% usage according to - # w.org/stats. The exceptions to this rule are the most recent LTS and version 5.5. + # Scheduled and labeled runs test all LTS versions of MariaDB supported by WordPress with greater than 1% usage + # according to w.org/stats. The exceptions to this rule are the most recent LTS and version 5.5. # # The 5.5 release was intended as a drop-in replacement for MySQL. Because the MySQL 5.5 Docker containers do not # work, this ensures some level of MySQL 5.5 testing. @@ -203,11 +222,11 @@ jobs: fail-fast: false matrix: os: [ ubuntu-24.04 ] - # The scheduled run tests every supported PHP version. Other events test the highest and lowest of each major. - php: ${{ github.event_name == 'schedule' && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} + # Scheduled and labeled runs test every supported PHP version. Other runs test the highest and lowest of each major. + php: ${{ ( github.event_name == 'schedule' || ( github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'Full PHPUnit Matrix' ) ) ) && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} db-type: [ 'mariadb' ] - # The scheduled run tests the full database matrix. Other events retain MariaDB 5.5 compatibility, 10.6, and newer LTS releases. - db-version: ${{ github.event_name == 'schedule' && fromJSON('["5.5","10.3","10.5","10.6","10.11","11.4","11.8"]') || fromJSON('["5.5","10.6","10.11","11.4","11.8"]') }} + # Scheduled and labeled runs test the full database matrix. Other runs retain MariaDB 5.5 compatibility, 10.6, and newer LTS releases. + db-version: ${{ ( github.event_name == 'schedule' || ( github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'Full PHPUnit Matrix' ) ) ) && fromJSON('["5.5","10.3","10.5","10.6","10.11","11.4","11.8"]') || fromJSON('["5.5","10.6","10.11","11.4","11.8"]') }} multisite: [ false, true ] memcached: [ false ] @@ -271,8 +290,8 @@ jobs: fail-fast: false matrix: os: [ ubuntu-24.04 ] - # The scheduled run tests every supported PHP version. Other events test the highest and lowest of each major. - php: ${{ github.event_name == 'schedule' && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} + # Scheduled and labeled runs test every supported PHP version. Other runs test the highest and lowest of each major. + php: ${{ ( github.event_name == 'schedule' || ( github.event_name == 'pull_request' && contains( github.event.pull_request.labels.*.name, 'Full PHPUnit Matrix' ) ) ) && fromJSON('["7.4","8.0","8.1","8.2","8.3","8.4","8.5"]') || fromJSON('["7.4","8.0","8.5"]') }} db-type: [ 'mysql', 'mariadb' ] db-version: [ '12.1' ] multisite: [ false, true ] diff --git a/tests/phpunit/README.md b/tests/phpunit/README.md index b5fd1513600d6..679ed831112d2 100644 --- a/tests/phpunit/README.md +++ b/tests/phpunit/README.md @@ -5,3 +5,15 @@ PHPUnit is the official testing framework chosen by the core team to test PHP co For more information, please review the relevant Core Handbook pages: - [PHP: PHPUnit](https://make.wordpress.org/core/handbook/testing/automated-testing/phpunit/) - [Writing PHP Tests](https://make.wordpress.org/core/handbook/testing/automated-testing/writing-phpunit-tests/) + +## Run the full matrix on a pull request + +Add the `Full PHPUnit Matrix` label to a pull request in `WordPress/wordpress-develop` to run the same PHP and database combinations as the weekly scheduled run. The label-triggered workflow uses the same path filters as normal PHPUnit runs. + +If you cannot apply labels, leave a PR comment asking a reviewer with triage access to add it. Fork PRs follow GitHub's usual workflow approval requirements. + +Adding the label starts a separate run without another code push. An existing reduced-matrix run continues alongside it; its checks and results are preserved. New commits run the full matrix while the label remains. Remove and reapply it to request another run for the current revision, or remove it to return subsequent runs to the reduced matrix. + +Unrelated labels skip only the label-triggered workflow's `full-matrix` job and do not replace or cancel PHPUnit checks. + +Look for `PHPUnit Tests (full matrix)` in GitHub Actions and the PHPUnit checks on the PR. Each run tests the PR's merge commit and retains its own logs and results, so check the revision before relying on an older run. From 2c6ec190fed195492439cd75177223bdf0812016 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 15:32:10 +0000 Subject: [PATCH 198/363] Build/Test Tools: Delete attachment files during test cleanup. Delete attachments before the bulk database cleanup so their uploaded files and generated image sizes are removed while attachment metadata is still available. Preserve the existing bulk SQL cleanup for other records. Add regression coverage for attachment file and post deletion. Developed in: https://github.com/WordPress/wordpress-develop/pull/8898 Props sirlouen, johnbillion, adrianmoldovanwp. Fixes #41978. git-svn-id: https://develop.svn.wordpress.org/trunk@63586 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/includes/functions.php | 10 ++++++- tests/phpunit/tests/includes/functions.php | 33 ++++++++++++++++++++++ 2 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 tests/phpunit/tests/includes/functions.php diff --git a/tests/phpunit/includes/functions.php b/tests/phpunit/includes/functions.php index d27af5c172a7a..473ed341e9571 100644 --- a/tests/phpunit/includes/functions.php +++ b/tests/phpunit/includes/functions.php @@ -105,11 +105,19 @@ function _test_filter_build_unique_id( $hook_name, $callback, $priority ) { } /** - * Deletes all data from the database. + * Deletes all data from the database, except: + * - The default category. + * - The default user. */ function _delete_all_data() { global $wpdb; + // Retrieve all attachment posts, and delete them along with the attached media. + $attachments = $wpdb->get_col( "SELECT ID FROM {$wpdb->posts} WHERE post_type = 'attachment'" ); + foreach ( $attachments as $attachment ) { + wp_delete_attachment( $attachment, true ); + } + foreach ( array( $wpdb->posts, $wpdb->postmeta, diff --git a/tests/phpunit/tests/includes/functions.php b/tests/phpunit/tests/includes/functions.php new file mode 100644 index 0000000000000..df5fc31a6156e --- /dev/null +++ b/tests/phpunit/tests/includes/functions.php @@ -0,0 +1,33 @@ +attachment->create_upload_object( + DIR_TESTDATA . '/images/waffles.jpg' + ); + + // Retrieve the path to the image. + $attachment_file = get_attached_file( $attachment_id ); + $this->assertFileExists( $attachment_file ); + + _delete_all_data(); + + // Verify that the image has been deleted along with the attachment. + $this->assertFileDoesNotExist( $attachment_file ); + $this->assertNull( get_post( $attachment_id ) ); + } +} From f8fb8d026abe119d2d5fcd2e3152e2d47e524f9b Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 20:29:08 +0000 Subject: [PATCH 199/363] Build/Test Tools: Discard stale roles before test installation. Discard the roles object loaded before the test tables are dropped. Let WordPress recreate it from the fresh tables so capabilities from a previous test run do not survive reinstallation. Developed in: https://github.com/WordPress/wordpress-develop/pull/13286 Props ekamran. Fixes #65972. git-svn-id: https://develop.svn.wordpress.org/trunk@63590 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/includes/install.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/phpunit/includes/install.php b/tests/phpunit/includes/install.php index 61b27e22dd097..01b438289b6f5 100644 --- a/tests/phpunit/includes/install.php +++ b/tests/phpunit/includes/install.php @@ -79,6 +79,15 @@ } $wpdb->query( 'SET foreign_key_checks = 1' ); +/* + * Discard the roles object created while bootstrapping WordPress above, as it + * holds role data loaded from the tables that were just dropped. If it were + * kept, populate_roles() would see the default roles as already existing and + * write the stale capabilities back to the database. The next call to + * wp_roles() recreates the object after the fresh tables are in place. + */ +unset( $GLOBALS['wp_roles'] ); + // Prefill a permalink structure so that WP doesn't try to determine one itself. add_action( 'populate_options', '_set_default_permalink_structure_for_tests' ); From a1c3fe13303f79c5492681d795b6b6821dbcecee Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 20:53:44 +0000 Subject: [PATCH 200/363] Tests: Reduce repeated token map test setup. Check all HTML5 named character references within each token map test instead of running a separate test for every token. Preserve the per-token assertions and include token names in failure messages. Reduce test invocations from 4,474 to 14, avoiding repeated test runner setup and teardown. Developed in: https://github.com/WordPress/wordpress-develop/pull/13478 Props sainathpoojary. See #66074. git-svn-id: https://develop.svn.wordpress.org/trunk@63591 602fd350-edb4-49c9-b593-d223f7449a82 --- .../phpunit/tests/wp-token-map/wpTokenMap.php | 83 +++++++++---------- 1 file changed, 38 insertions(+), 45 deletions(-) diff --git a/tests/phpunit/tests/wp-token-map/wpTokenMap.php b/tests/phpunit/tests/wp-token-map/wpTokenMap.php index 23edc5de80b94..85311eeb76e7c 100644 --- a/tests/phpunit/tests/wp-token-map/wpTokenMap.php +++ b/tests/phpunit/tests/wp-token-map/wpTokenMap.php @@ -306,68 +306,63 @@ public static function data_short_substring_matches_of_each_other() { * Ensures that Token Map searches at appropriate starting offset. * * @ticket 60698 - * - * @dataProvider data_html5_test_dataset - * - * @param string $token Token to find. - * @param string $replacement Replacement string for token. */ - public function test_reads_token_at_given_offset( $token, $replacement ) { - $document = "& another {$token} & then some"; - $map = self::get_html5_token_map(); + public function test_reads_token_at_given_offset() { + $map = self::get_html5_token_map(); - $skip_bytes = 0; - $this->assertNull( - $map->read_token( $document, 0, $skip_bytes ), - "Shouldn't have found token at start of document." - ); + foreach ( $this->get_html5_test_dataset() as $token => $replacement ) { + $document = "& another {$token} & then some"; - $response = $map->read_token( $document, 10, $skip_bytes ); + $skip_bytes = 0; + $this->assertNull( + $map->read_token( $document, 0, $skip_bytes ), + "Shouldn't have found token '{$token}' at start of document." + ); - $this->assertSame( - strlen( $token ), - $skip_bytes, - "Found the wrong length for token '{$token}'." - ); + $response = $map->read_token( $document, 10, $skip_bytes ); - $this->assertSame( - $response, - $replacement, - 'Found the wrong replacement value for the token.' - ); + $this->assertSame( + strlen( $token ), + $skip_bytes, + "Found the wrong length for token '{$token}'." + ); + + $this->assertSame( + $response, + $replacement, + "Found the wrong replacement value for token '{$token}'." + ); + } } /** * Ensures that all given tokens exist inside a constructed Token Map. * * @ticket 60698 - * - * @dataProvider data_html5_test_dataset - * - * @param string $token Token to find. - * @param string $replacement Not used in this test. */ - public function test_detects_all_tokens( $token, $replacement ) { + public function test_detects_all_tokens() { $map = self::get_html5_token_map(); - $this->assertTrue( - $map->contains( $token ), - "Should have found '{$token}' inside the Token Map, but didn't." - ); + foreach ( $this->get_html5_test_dataset() as $token => $replacement ) { + $this->assertTrue( + $map->contains( $token ), + "Should have found '{$token}' inside the Token Map, but didn't." + ); - $double_escaped_token = str_replace( '&', '&', $token ); - $this->assertFalse( - $map->contains( $double_escaped_token ), - "Should not have found '{$double_escaped_token}' in Token Map, but did." - ); + $double_escaped_token = str_replace( '&', '&', $token ); + $this->assertFalse( + $map->contains( $double_escaped_token ), + "Should not have found '{$double_escaped_token}' in Token Map, but did." + ); + } } /** - * Data provider. + * Gets all HTML5 named character references to check within each test. * - * @return array[]. + * @return string[] Replacement strings keyed by token. */ - public function data_html5_test_dataset() { + private function get_html5_test_dataset() { $html5 = self::get_test_input_array( 'HTML5' ); $this->assertSame( @@ -376,9 +371,7 @@ public function data_html5_test_dataset() { 'Found the wrong number of HTML5 named character references: confirm the entities.json file."' ); - foreach ( $html5 as $token => $replacement ) { - yield $token => array( $token, $replacement ); - } + return $html5; } /** From fe4400bf5d35fb98d207c78eff4775099e94be32 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 21:10:52 +0000 Subject: [PATCH 201/363] Build/Test Tools: Reset comment globals between tests. Clear the global comment fixture after author URL link tests and reset the comment-loop flag between tests to prevent order-dependent failures. Developed in: https://github.com/WordPress/wordpress-develop/pull/13186 Props jonsurrell. See #65893. git-svn-id: https://develop.svn.wordpress.org/trunk@63592 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/includes/abstract-testcase.php | 2 +- tests/phpunit/tests/comment/getCommentAuthorUrlLink.php | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/tests/phpunit/includes/abstract-testcase.php b/tests/phpunit/includes/abstract-testcase.php index 25b207092c110..7116d3076266b 100644 --- a/tests/phpunit/includes/abstract-testcase.php +++ b/tests/phpunit/includes/abstract-testcase.php @@ -220,7 +220,7 @@ public function tear_down() { } // Reset comment globals. - $comment_globals = array( 'comment_alt', 'comment_depth', 'comment_thread_alt' ); + $comment_globals = array( 'comment_alt', 'comment_depth', 'comment_thread_alt', 'in_comment_loop' ); foreach ( $comment_globals as $global ) { $GLOBALS[ $global ] = null; } diff --git a/tests/phpunit/tests/comment/getCommentAuthorUrlLink.php b/tests/phpunit/tests/comment/getCommentAuthorUrlLink.php index ee964d96d9de0..043d38869e5e6 100644 --- a/tests/phpunit/tests/comment/getCommentAuthorUrlLink.php +++ b/tests/phpunit/tests/comment/getCommentAuthorUrlLink.php @@ -9,6 +9,12 @@ class Tests_Comment_GetCommentAuthorUrlLink extends WP_UnitTestCase { protected static $comments = array(); + public function tear_down() { + unset( $GLOBALS['comment'] ); + + parent::tear_down(); + } + public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { unset( $GLOBALS['comment'] ); From a508c69fe88c7c4a58da5ee454e64719375e40b0 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 21:20:48 +0000 Subject: [PATCH 202/363] Tests: Restore core Ajax hooks before each test. Register core Ajax callbacks during each test setup so restoring the shared hook snapshot cannot leave later tests without their required callbacks. Remove the automatic update checks from admin_init during each setup as well. Developed in: https://github.com/WordPress/wordpress-develop/pull/13191 Props jonsurrell. See #65893. git-svn-id: https://develop.svn.wordpress.org/trunk@63593 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/includes/testcase-ajax.php | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/tests/phpunit/includes/testcase-ajax.php b/tests/phpunit/includes/testcase-ajax.php index 2e86c29e67284..dcba2e58c3a5c 100644 --- a/tests/phpunit/includes/testcase-ajax.php +++ b/tests/phpunit/includes/testcase-ajax.php @@ -122,7 +122,13 @@ public static function set_up_before_class() { remove_action( 'admin_init', '_maybe_update_plugins' ); remove_action( 'admin_init', '_maybe_update_themes' ); - // Register the core actions. + self::register_core_actions(); + } + + /** + * Registers the core Ajax actions. + */ + protected static function register_core_actions() { foreach ( array_merge( self::$_core_actions_get, self::$_core_actions_post ) as $action ) { if ( function_exists( 'wp_ajax_' . str_replace( '-', '_', $action ) ) ) { add_action( 'wp_ajax_' . $action, 'wp_ajax_' . str_replace( '-', '_', $action ), 1 ); @@ -138,6 +144,15 @@ public static function set_up_before_class() { public function set_up() { parent::set_up(); + /* + * The shared hook snapshot may have been captured before an Ajax test case + * registered these callbacks, then restored after another randomized test. + */ + self::register_core_actions(); + remove_action( 'admin_init', '_maybe_update_core' ); + remove_action( 'admin_init', '_maybe_update_plugins' ); + remove_action( 'admin_init', '_maybe_update_themes' ); + add_filter( 'wp_doing_ajax', '__return_true' ); add_filter( 'wp_die_ajax_handler', array( $this, 'getDieHandler' ), 1, 1 ); From ac38246ae9c515094105800c8da25613375421e9 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 21:32:50 +0000 Subject: [PATCH 203/363] Tests: Improve isolation of rewrite tests. Flush rewrite rules after registering the initial taxonomies in conditional-query test setup. Clear the HTTPS server flag during rewrite test teardown so later tests do not inherit it. Developed in: https://github.com/WordPress/wordpress-develop/pull/13193 Props jonsurrell. See #65893. git-svn-id: https://develop.svn.wordpress.org/trunk@63594 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/query/conditionals.php | 1 + tests/phpunit/tests/rewrite.php | 1 + 2 files changed, 2 insertions(+) diff --git a/tests/phpunit/tests/query/conditionals.php b/tests/phpunit/tests/query/conditionals.php index 4b473178897ae..913e19f650de6 100644 --- a/tests/phpunit/tests/query/conditionals.php +++ b/tests/phpunit/tests/query/conditionals.php @@ -39,6 +39,7 @@ public function set_up() { $this->set_permalink_structure( '/%year%/%monthnum%/%day%/%postname%/' ); create_initial_taxonomies(); + flush_rewrite_rules(); } public function test_home() { diff --git a/tests/phpunit/tests/rewrite.php b/tests/phpunit/tests/rewrite.php index 085998e4b7eec..3ffb3ba2a81a2 100644 --- a/tests/phpunit/tests/rewrite.php +++ b/tests/phpunit/tests/rewrite.php @@ -31,6 +31,7 @@ public function tear_down() { $wp_rewrite->init(); update_option( 'home', $this->home_url ); + unset( $_SERVER['HTTPS'] ); unset( $this->blog_id_35531 ); parent::tear_down(); } From f07d9757b32ff72eb688f791bbcb1b0df4e56013 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Thu, 10 Sep 2026 21:39:21 +0000 Subject: [PATCH 204/363] Tests: Restore themes after block tests. Save the incoming stylesheet in block and theme test fixtures and switch back during teardown when it changes. Restore the theme before database rollback so theme-related runtime state and caches do not leak into later tests. Developed in: https://github.com/WordPress/wordpress-develop/pull/13205 Props jonsurrell. See #65893. git-svn-id: https://develop.svn.wordpress.org/trunk@63595 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/blocks/editor.php | 13 +++++++++++++ tests/phpunit/tests/blocks/getBlockAssetUrl.php | 12 ++++++++++++ tests/phpunit/tests/blocks/getBlockTemplates.php | 16 ++++++++++++++++ tests/phpunit/tests/blocks/getHookedBlocks.php | 16 ++++++++++++++++ tests/phpunit/tests/blocks/register.php | 12 ++++++++++++ .../tests/blocks/wpBlockPatternsRegistry.php | 13 +++++++++++++ .../tests/theme/wpThemeGetBlockPatterns.php | 13 +++++++++++++ 7 files changed, 95 insertions(+) diff --git a/tests/phpunit/tests/blocks/editor.php b/tests/phpunit/tests/blocks/editor.php index 1de4dbf1719a6..ed740a35bbcbc 100644 --- a/tests/phpunit/tests/blocks/editor.php +++ b/tests/phpunit/tests/blocks/editor.php @@ -16,6 +16,7 @@ public function set_up() { global $post; parent::set_up(); + $this->original_stylesheet = get_stylesheet(); remove_action( 'wp_print_styles', 'print_emoji_styles' ); @@ -51,6 +52,11 @@ public function tear_down() { $wp_rest_server = null; global $post_ID; $post_ID = null; + + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + parent::tear_down(); } @@ -64,6 +70,13 @@ public function tear_down() { */ protected $original_wp_styles; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + public function filter_set_block_categories_post( $block_categories, $post ) { if ( empty( $post ) ) { return $block_categories; diff --git a/tests/phpunit/tests/blocks/getBlockAssetUrl.php b/tests/phpunit/tests/blocks/getBlockAssetUrl.php index ee1c541cf0c2c..fba6757369242 100644 --- a/tests/phpunit/tests/blocks/getBlockAssetUrl.php +++ b/tests/phpunit/tests/blocks/getBlockAssetUrl.php @@ -18,10 +18,18 @@ class Tests_Get_Block_Asset_Url extends WP_UnitTestCase { */ private $orig_theme_dir; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + public function set_up() { global $wp_theme_directories; parent::set_up(); + $this->original_stylesheet = get_stylesheet(); // Sets up the `wp-content/themes/` directory to ensure consistency when running tests. $this->orig_theme_dir = $wp_theme_directories; @@ -34,6 +42,10 @@ public function set_up() { public function tear_down() { global $wp_theme_directories; + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + $wp_theme_directories = $this->orig_theme_dir; wp_clean_themes_cache(); diff --git a/tests/phpunit/tests/blocks/getBlockTemplates.php b/tests/phpunit/tests/blocks/getBlockTemplates.php index 791f449a163c5..783dfbabfd1eb 100644 --- a/tests/phpunit/tests/blocks/getBlockTemplates.php +++ b/tests/phpunit/tests/blocks/getBlockTemplates.php @@ -9,6 +9,13 @@ class Tests_Blocks_GetBlockTemplates extends WP_UnitTestCase { const TEST_THEME = 'block-theme'; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + /** * @var WP_Post */ @@ -91,9 +98,18 @@ public static function wpTearDownAfterClass() { public function set_up() { parent::set_up(); + $this->original_stylesheet = get_stylesheet(); switch_theme( self::TEST_THEME ); } + public function tear_down() { + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + + parent::tear_down(); + } + /** * Gets the template IDs from the given array. * diff --git a/tests/phpunit/tests/blocks/getHookedBlocks.php b/tests/phpunit/tests/blocks/getHookedBlocks.php index 83a741b4d0771..d0d17886bd4d8 100644 --- a/tests/phpunit/tests/blocks/getHookedBlocks.php +++ b/tests/phpunit/tests/blocks/getHookedBlocks.php @@ -16,6 +16,18 @@ class Tests_Blocks_GetHookedBlocks extends WP_UnitTestCase { const TEST_THEME_NAME = 'block-theme-with-hooked-blocks'; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + + public function set_up() { + parent::set_up(); + $this->original_stylesheet = get_stylesheet(); + } + /** * Tear down after each test. * @@ -43,6 +55,10 @@ public function tear_down() { } } + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + parent::tear_down(); } diff --git a/tests/phpunit/tests/blocks/register.php b/tests/phpunit/tests/blocks/register.php index d2a836ba85e68..81cebf27c798c 100644 --- a/tests/phpunit/tests/blocks/register.php +++ b/tests/phpunit/tests/blocks/register.php @@ -20,6 +20,13 @@ class Tests_Blocks_Register extends WP_UnitTestCase { */ protected $original_wp_styles; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + /** * ID for a test post. * @@ -61,6 +68,7 @@ public function render_stub() {} */ public function set_up() { parent::set_up(); + $this->original_stylesheet = get_stylesheet(); global $wp_scripts, $wp_styles; $this->original_wp_scripts = $wp_scripts; @@ -96,6 +104,10 @@ public function tear_down() { $wp_scripts = $this->original_wp_scripts; $wp_styles = $this->original_wp_styles; + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + parent::tear_down(); } diff --git a/tests/phpunit/tests/blocks/wpBlockPatternsRegistry.php b/tests/phpunit/tests/blocks/wpBlockPatternsRegistry.php index 738d086f4a30e..b4b83be1048f3 100644 --- a/tests/phpunit/tests/blocks/wpBlockPatternsRegistry.php +++ b/tests/phpunit/tests/blocks/wpBlockPatternsRegistry.php @@ -27,6 +27,13 @@ class Tests_Blocks_wpBlockPatternsRegistry extends WP_UnitTestCase { */ private $original_registered_patterns = null; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + /** * Set up each test method. * @@ -37,6 +44,7 @@ public function set_up() { $this->registry = new WP_Block_Patterns_Registry(); $this->original_registered_patterns = $this->get_registered_patterns_variable_value(); + $this->original_stylesheet = get_stylesheet(); } /** @@ -54,6 +62,11 @@ public function tear_down() { } $this->set_registered_patterns_variable_value( $this->original_registered_patterns ); + + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + parent::tear_down(); } diff --git a/tests/phpunit/tests/theme/wpThemeGetBlockPatterns.php b/tests/phpunit/tests/theme/wpThemeGetBlockPatterns.php index cd27aa00fd034..cc1827496a92f 100644 --- a/tests/phpunit/tests/theme/wpThemeGetBlockPatterns.php +++ b/tests/phpunit/tests/theme/wpThemeGetBlockPatterns.php @@ -19,14 +19,27 @@ class Tests_Theme_WPThemeGetBlockPatterns extends WP_UnitTestCase { */ private $initial_cache_object; + /** + * Original stylesheet. + * + * @var string + */ + private $original_stylesheet; + public function set_up() { parent::set_up(); $this->initial_cache_object = wp_using_ext_object_cache(); + $this->original_stylesheet = get_stylesheet(); } public function tear_down() { wp_using_ext_object_cache( $this->initial_cache_object ); + + if ( get_stylesheet() !== $this->original_stylesheet ) { + switch_theme( $this->original_stylesheet ); + } + parent::tear_down(); } From 2a616e3e7cd70b40f718ff0ebaba3fadccf00587 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 10 Sep 2026 22:57:55 +0000 Subject: [PATCH 205/363] Docs: Use the `bool` and `int` short type forms in PHPDoc. The PHP inline documentation standards call for `bool` and `int` in `@param`, `@return` and `@global` tags, but six docblocks in `src/wp-includes` still carried the long `boolean` and `integer` spellings. Developed in https://github.com/WordPress/wordpress-develop/pull/13476. Follow-up to r63495. Props njones35. See #65860. git-svn-id: https://develop.svn.wordpress.org/trunk@63596 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-theme-json.php | 12 ++++++------ src/wp-includes/global-styles-and-settings.php | 2 +- .../html-api/class-wp-html-tag-processor.php | 2 +- src/wp-includes/media.php | 2 +- .../class-wp-rest-global-styles-controller.php | 2 +- .../endpoints/class-wp-rest-templates-controller.php | 2 +- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/wp-includes/class-wp-theme-json.php b/src/wp-includes/class-wp-theme-json.php index 1252ca6736fd6..e91d547eb58f1 100644 --- a/src/wp-includes/class-wp-theme-json.php +++ b/src/wp-includes/class-wp-theme-json.php @@ -3009,12 +3009,12 @@ protected static function flatten_tree( $tree, $prefix = '', $token = '--' ) { * @since 6.6.0 Pass current theme JSON settings to wp_get_typography_font_size_value(), and process background properties. * @since 6.7.0 `ref` resolution of background properties, and assigning custom default values. * - * @param array $styles Styles to process. - * @param array $settings Theme settings. - * @param array $properties Properties metadata. - * @param array $theme_json Theme JSON array. - * @param string $selector The style block selector. - * @param boolean $use_root_padding Whether to add custom properties at root level. + * @param array $styles Styles to process. + * @param array $settings Theme settings. + * @param array $properties Properties metadata. + * @param array $theme_json Theme JSON array. + * @param string $selector The style block selector. + * @param bool $use_root_padding Whether to add custom properties at root level. * @return array Returns the modified $declarations. */ protected static function compute_style_properties( $styles, $settings = array(), $properties = null, $theme_json = null, $selector = null, $use_root_padding = null ) { diff --git a/src/wp-includes/global-styles-and-settings.php b/src/wp-includes/global-styles-and-settings.php index 0534d8b0dee58..c4a3284dadb91 100644 --- a/src/wp-includes/global-styles-and-settings.php +++ b/src/wp-includes/global-styles-and-settings.php @@ -497,7 +497,7 @@ function wp_get_theme_data_template_parts() { * * @param WP_Block_Type $block_type The block's type. * @param string|array $target The desired selector's target, `root` or array path. - * @param boolean $fallback Whether to fall back to broader selector. + * @param bool $fallback Whether to fall back to broader selector. * @return string|null CSS selector or `null` if no selector available. */ function wp_get_block_css_selector( $block_type, $target = 'root', $fallback = false ) { diff --git a/src/wp-includes/html-api/class-wp-html-tag-processor.php b/src/wp-includes/html-api/class-wp-html-tag-processor.php index b59baaf5a81cb..cd5814f0a4ad3 100644 --- a/src/wp-includes/html-api/class-wp-html-tag-processor.php +++ b/src/wp-includes/html-api/class-wp-html-tag-processor.php @@ -2789,7 +2789,7 @@ private static function sort_start_ascending( WP_HTML_Text_Replacement $a, WP_HT * @ignore * * @param string $comparable_name The attribute name in its comparable form. - * @return string|boolean|null Value of enqueued update if present, otherwise false. + * @return string|bool|null Value of enqueued update if present, otherwise false. */ private function get_enqueued_attribute_value( string $comparable_name ) { if ( self::STATE_MATCHED_TAG !== $this->parser_state ) { diff --git a/src/wp-includes/media.php b/src/wp-includes/media.php index be0b2fbf098cc..1e0b86655e82a 100644 --- a/src/wp-includes/media.php +++ b/src/wp-includes/media.php @@ -2120,7 +2120,7 @@ function wp_img_tag_add_auto_sizes( string $image ): string { * * @since 6.7.1 * - * @param boolean $enabled Whether auto-sizes for lazy loaded images is enabled. + * @param bool $enabled Whether auto-sizes for lazy loaded images is enabled. */ if ( ! apply_filters( 'wp_img_tag_add_auto_sizes', true ) ) { return $image; diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php index ed8195cbb91b7..83466acad0948 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-controller.php @@ -386,7 +386,7 @@ public function prepare_item_for_response( $post, $request ) { * @since 5.9.0 * @since 6.3.0 Adds revisions count and rest URL href to version-history. * - * @param integer $id ID. + * @param int $id ID. * @return array Links for the given post. */ protected function prepare_links( $id ) { diff --git a/src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php b/src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php index 0941ee4ea53e3..190eea6b203bb 100644 --- a/src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php +++ b/src/wp-includes/rest-api/endpoints/class-wp-rest-templates-controller.php @@ -967,7 +967,7 @@ private static function get_wp_templates_author_text_field( $template_object ) { * * @since 5.8.0 * - * @param integer $id ID. + * @param int $id ID. * @return array Links for the given post. */ protected function prepare_links( $id ) { From 5aac49a2d6bf28944a3c9ed5827a622e02696649 Mon Sep 17 00:00:00 2001 From: Weston Ruter Date: Thu, 10 Sep 2026 23:07:39 +0000 Subject: [PATCH 206/363] Build/Test Tools: Add `libxml` to the suggested extensions in `composer.json`. There are `LIBXML_*` constants conditionally used in SimplePie, ID3, and PHPUnit tests. Follow-up to r63004. See #65819, #65571. git-svn-id: https://develop.svn.wordpress.org/trunk@63597 602fd350-edb4-49c9-b593-d223f7449a82 --- composer.json | 1 + 1 file changed, 1 insertion(+) diff --git a/composer.json b/composer.json index 06edbbf0e776d..b510b99156d53 100644 --- a/composer.json +++ b/composer.json @@ -29,6 +29,7 @@ "ext-igbinary": "*", "ext-imagick": "*", "ext-intl": "*", + "ext-libxml": "*", "ext-mbstring": "*", "ext-memcached": "*", "ext-mysqli": "*", From 501d9201eba3c12fdb761ea49c27b720ee112713 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 11 Sep 2026 06:29:08 +0000 Subject: [PATCH 207/363] General: Enable the JSDoc rule require-param-description. Enables the JSDoc rule `require-param-description` and fixes all the reported violations. Part of the effort to improve JS inline documentation for 7.2. Developed in https://github.com/WordPress/wordpress-develop/pull/13475 Props afercia, westonruter. See #66033. git-svn-id: https://develop.svn.wordpress.org/trunk@63598 602fd350-edb4-49c9-b593-d223f7449a82 --- .eslintrc-jsdoc.js | 1 + src/js/_enqueues/admin/postbox.js | 8 ++-- src/js/_enqueues/admin/site-health.js | 4 +- src/js/_enqueues/lib/embed-template.js | 4 +- src/js/_enqueues/lib/lists.js | 4 +- src/js/_enqueues/wp/api.js | 2 +- src/js/_enqueues/wp/dashboard.js | 4 +- src/js/_enqueues/wp/heartbeat.js | 4 +- src/js/_enqueues/wp/media/editor.js | 10 ++--- src/js/_enqueues/wp/media/models.js | 14 +++--- src/js/_enqueues/wp/media/views.js | 4 +- src/js/_enqueues/wp/updates.js | 10 ++--- src/js/media/controllers/embed.js | 2 +- src/js/media/controllers/library.js | 10 ++--- src/js/media/controllers/region.js | 10 ++--- src/js/media/controllers/state-machine.js | 4 +- src/js/media/models/attachment.js | 12 +++--- src/js/media/models/attachments.js | 52 +++++++++++------------ src/js/media/models/query.js | 40 ++++++++--------- src/js/media/models/selection.js | 10 ++--- src/js/media/views/attachment-compat.js | 4 +- src/js/media/views/attachment.js | 42 +++++++++--------- src/js/media/views/attachments.js | 2 +- src/js/media/views/button.js | 2 +- src/js/media/views/embed.js | 2 +- src/js/media/views/frame.js | 6 +-- src/js/media/views/frame/post.js | 6 +-- src/js/media/views/frame/select.js | 8 ++-- src/js/media/views/media-details.js | 6 +-- src/js/media/views/media-frame.js | 12 +++--- src/js/media/views/menu.js | 4 +- src/js/media/views/modal.js | 11 ++--- src/js/media/views/priority-list.js | 12 +++--- src/js/media/views/settings.js | 4 +- src/js/media/views/toolbar.js | 12 +++--- src/js/media/views/uploader/status.js | 4 +- 36 files changed, 176 insertions(+), 170 deletions(-) diff --git a/.eslintrc-jsdoc.js b/.eslintrc-jsdoc.js index e3c98d449f3c5..dc6559c520cbe 100644 --- a/.eslintrc-jsdoc.js +++ b/.eslintrc-jsdoc.js @@ -52,6 +52,7 @@ module.exports = [ 'jsdoc/require-param': [ 'error', { enableFixer: false, } ], + 'jsdoc/require-param-description': 'error', 'jsdoc/require-param-name': 'error', 'jsdoc/require-param-type': 'error', 'jsdoc/require-returns': 'error', diff --git a/src/js/_enqueues/admin/postbox.js b/src/js/_enqueues/admin/postbox.js index b6d1b6569dc84..1f101d3fd1c41 100644 --- a/src/js/_enqueues/admin/postbox.js +++ b/src/js/_enqueues/admin/postbox.js @@ -246,10 +246,10 @@ * * @memberof postboxes * - * @param {string} page The page we are currently on. - * @param {Object} [args] - * @param {Function} args.pbshow A callback that is called when a postbox opens. - * @param {Function} args.pbhide A callback that is called when a postbox closes. + * @param {string} page The page we are currently on. + * @param {Object} [args] Optional arguments for the postbox toggles. + * @param {Function} [args.pbshow] A callback that is called when a postbox opens. + * @param {Function} [args.pbhide] A callback that is called when a postbox closes. * @return {void} */ add_postbox_toggles : function (page, args) { diff --git a/src/js/_enqueues/admin/site-health.js b/src/js/_enqueues/admin/site-health.js index dc9107a3ebc2f..0a1b052e56f3b 100644 --- a/src/js/_enqueues/admin/site-health.js +++ b/src/js/_enqueues/admin/site-health.js @@ -350,8 +350,8 @@ jQuery( function( $ ) { /** * Add the details of a failed asynchronous test to the list of test results. * - * @param {string} url - * @param {string} description + * @param {string} url The URL of the failed test. + * @param {string} description The description of the failed test. * @since 5.6.0 */ function addFailedSiteHealthCheckNotice( url, description ) { diff --git a/src/js/_enqueues/lib/embed-template.js b/src/js/_enqueues/lib/embed-template.js index e43ef97b8fe96..85c1369322b98 100644 --- a/src/js/_enqueues/lib/embed-template.js +++ b/src/js/_enqueues/lib/embed-template.js @@ -196,7 +196,7 @@ /** * Detect clicks to external (_top) links. * - * @param {MouseEvent} event + * @param {MouseEvent} event The click event object. */ function linkClickHandler( event ) { /* @@ -237,7 +237,7 @@ /** * Message handler. * - * @param {MessageEvent} event + * @param {MessageEvent} event The message event object. */ function onMessage( event ) { var data = event.data; diff --git a/src/js/_enqueues/lib/lists.js b/src/js/_enqueues/lib/lists.js index 3f667a043478a..44e71a84ed488 100644 --- a/src/js/_enqueues/lib/lists.js +++ b/src/js/_enqueues/lib/lists.js @@ -739,7 +739,7 @@ wpList = { /** * Registers event handlers to add, delete, and dim items. * - * @param {string} elementId + * @param {string} elementId ID of the element to process, including leading #. */ process: function( elementId ) { var list = this, @@ -812,7 +812,7 @@ wpList = { /** * Initializes wpList object. * - * @param {Object} settings + * @param {Object} settings The settings for the wpList instance. * @param {string} settings.url URL for ajax calls. Default: ajaxurl. * @param {string} settings.type The HTTP method to use for Ajax requests. Default: 'POST'. * @param {string} settings.response ID of the element the parsed ajax response will be stored in. diff --git a/src/js/_enqueues/wp/api.js b/src/js/_enqueues/wp/api.js index a66d96c3fb81c..b15a74628a92c 100644 --- a/src/js/_enqueues/wp/api.js +++ b/src/js/_enqueues/wp/api.js @@ -1546,7 +1546,7 @@ /** * Initialize the wp-api, optionally passing the API root. * - * @param {Object} [args] + * @param {Object} [args] The arguments for initializing the wp-api. * @param {string} [args.nonce] The nonce. Optional, defaults to wpApiSettings.nonce. * @param {string} [args.apiRoot] The api root. Optional, defaults to wpApiSettings.root. * @param {string} [args.versionString] The version string. Optional, defaults to wpApiSettings.root. diff --git a/src/js/_enqueues/wp/dashboard.js b/src/js/_enqueues/wp/dashboard.js index 31c9cd7cb1547..595133d790782 100644 --- a/src/js/_enqueues/wp/dashboard.js +++ b/src/js/_enqueues/wp/dashboard.js @@ -703,7 +703,7 @@ jQuery( function( $ ) { * * @since 5.5.2 * - * @param {number} startTimestamp + * @param {number} startTimestamp The start timestamp of the event. * * @return {number} The offset from UTC in minutes, with the sign flipped to be more intuitive. */ @@ -716,7 +716,7 @@ jQuery( function( $ ) { * * @since 5.5.2 * - * @param {number} startTimestamp + * @param {number} startTimestamp The start timestamp of the event. * * @return {string} A short time zone name, like `PST`, or a string like `GMT+5` if the abbreviation can't be determined. */ diff --git a/src/js/_enqueues/wp/heartbeat.js b/src/js/_enqueues/wp/heartbeat.js index e7abe77bb378f..e816959bda1bf 100644 --- a/src/js/_enqueues/wp/heartbeat.js +++ b/src/js/_enqueues/wp/heartbeat.js @@ -244,8 +244,8 @@ /** * Handles pageshow event, specifically when page navigation is restored from back/forward cache. * - * @param {jQuery.Event} event - * @param {PageTransitionEvent} event.originalEvent + * @param {JQuery.Event} event The jQuery event object. + * @param {PageTransitionEvent} event.originalEvent The original PageTransitionEvent object. */ function ( event ) { if ( event.originalEvent.persisted ) { diff --git a/src/js/_enqueues/wp/media/editor.js b/src/js/_enqueues/wp/media/editor.js index bec97f27f0dd3..b6357520db557 100644 --- a/src/js/_enqueues/wp/media/editor.js +++ b/src/js/_enqueues/wp/media/editor.js @@ -341,7 +341,7 @@ * * @class wp.media.collection * - * @param {Object} attributes + * @param {Object} attributes The attributes for the media collection. */ wp.media.collection = function(attributes) { var collections = {}; @@ -786,8 +786,8 @@ * Setup 'workflow' and add to the 'workflows' cache. 'open' can * subsequently be called upon it. * - * @param {string} id A slug used to identify the workflow. - * @param {Object} [options={}] + * @param {string} id A slug used to identify the workflow. + * @param {Object} [options={}] The options for the media workflow. * * @this wp.media.editor * @@ -1001,7 +1001,7 @@ /** * Called when 'Insert From URL' source is not an image. Example: YouTube url. * - * @param {Object} embed + * @param {Object} embed The embed object containing the link URL and link text. * @return {Promise} A promise that resolves when the link has been sent to the editor. */ link: function( embed ) { @@ -1018,7 +1018,7 @@ * Opens a workflow. * * @param {string} [id=undefined] Optional. A slug used to identify the workflow. - * @param {Object} [options={}] + * @param {Object} [options={}] The options for the media workflow. * * @this wp.media.editor * diff --git a/src/js/_enqueues/wp/media/models.js b/src/js/_enqueues/wp/media/models.js index f184ebdba60ad..e10db02bfd4b2 100644 --- a/src/js/_enqueues/wp/media/models.js +++ b/src/js/_enqueues/wp/media/models.js @@ -136,7 +136,11 @@ _.extend( media, /** @lends wp.media */{ /** * Scales a set of dimensions to fit within bounding dimensions. * - * @param {Object} dimensions + * @param {Object} dimensions The dimensions to scale. + * @param {number} dimensions.width The width to scale. + * @param {number} dimensions.height The height to scale. + * @param {number} dimensions.maxWidth The maxWidth to scale. + * @param {number} dimensions.maxHeight The maxHeight to scale. * @return {Object} The scaled dimensions. */ fit: function( dimensions ) { @@ -182,9 +186,9 @@ _.extend( media, /** @lends wp.media */{ * Truncates a string by injecting an ellipsis into the middle. * Useful for filenames. * - * @param {string} string - * @param {number} [length=30] - * @param {string} [replacement=…] + * @param {string} string The string to truncate. + * @param {number} [length=30] The maximum length of the truncated string. + * @param {string} [replacement=…] The string to use as the ellipsis replacement. * @return {string} The string, unless length is greater than string.length. */ truncate: function( string, length, replacement ) { @@ -228,7 +232,7 @@ Attachments.all = new Attachments(); * * Shorthand for creating a new Attachments Query. * - * @param {Object} [props] + * @param {Object} [props] The properties to filter the attachments by. * @return {wp.media.model.Attachments} A collection of attachments matching the query. */ media.query = function( props ) { diff --git a/src/js/_enqueues/wp/media/views.js b/src/js/_enqueues/wp/media/views.js index 2f845bb7a82c5..1eec769227e12 100644 --- a/src/js/_enqueues/wp/media/views.js +++ b/src/js/_enqueues/wp/media/views.js @@ -47,8 +47,8 @@ media.events = _.extend( {}, Backbone.Events ); /** * Makes it easier to bind events using transitions. * - * @param {string} selector - * @param {number} sensitivity + * @param {string} selector The CSS selector for the element to bind the transition event to. + * @param {number} sensitivity The maximum time to wait for the transition event before resolving the promise. * @return {Promise} A promise that resolves when the transition has completed. */ media.transition = function( selector, sensitivity ) { diff --git a/src/js/_enqueues/wp/updates.js b/src/js/_enqueues/wp/updates.js index 22e7ac886ff30..7c971f4bb7d80 100644 --- a/src/js/_enqueues/wp/updates.js +++ b/src/js/_enqueues/wp/updates.js @@ -241,7 +241,7 @@ * * @since 4.6.0 * - * @param {Object} data + * @param {Object} data The data for the admin notice. * @param {*} [data.selector] Optional. Selector of an element to be replaced with the admin notice. * @param {string} [data.id] Optional. Unique id that will be used as the notice's id attribute. * @param {string} [data.className] Optional. Class names that will be used in the admin notice. @@ -334,7 +334,7 @@ * * @since 4.6.0 * - * @param {Object} response + * @param {Object} response The response object from the Ajax request. * @param {Array} [response.debug] Optional. Debug information. * @param {string} [response.errorCode] Optional. Error code for an error that occurred. */ @@ -1594,7 +1594,7 @@ * @since 4.6.0 * @since 5.5.0 Auto-update "time to next update" text cleared. * - * @param {Object} response + * @param {Object} response The response object from the Ajax request. * @param {string} response.slug Slug of the theme to be updated. * @param {Object} response.theme Updated theme. * @param {string} response.oldVersion Old version of the theme. @@ -1709,7 +1709,7 @@ * * @since 4.6.0 * - * @param {Object} args + * @param {Object} args The arguments for the theme installation request. * @param {string} args.slug Theme stylesheet. * @param {installThemeSuccess} args.success Optional. Success callback. Default: wp.updates.installThemeSuccess * @param {installThemeError} args.error Optional. Error callback. Default: wp.updates.installThemeError @@ -1901,7 +1901,7 @@ * * @since 4.6.0 * - * @param {Object} args + * @param {Object} args The arguments for the theme deletion request. * @param {string} args.slug Theme stylesheet. * @param {deleteThemeSuccess} args.success Optional. Success callback. Default: wp.updates.deleteThemeSuccess * @param {deleteThemeError} args.error Optional. Error callback. Default: wp.updates.deleteThemeError diff --git a/src/js/media/controllers/embed.js b/src/js/media/controllers/embed.js index 3c33769704c68..e485260cc5fe3 100644 --- a/src/js/media/controllers/embed.js +++ b/src/js/media/controllers/embed.js @@ -89,7 +89,7 @@ Embed = wp.media.controller.State.extend(/** @lends wp.media.controller.Embed.pr /** * Try scanning the embed as an image to discover its dimensions. * - * @param {Object} attributes + * @param {Object} attributes The attributes for the embed scan. */ scanImage: function( attributes ) { var frame = this.frame, diff --git a/src/js/media/controllers/library.js b/src/js/media/controllers/library.js index 231b49b718256..4d41d5ed0e353 100644 --- a/src/js/media/controllers/library.js +++ b/src/js/media/controllers/library.js @@ -158,7 +158,7 @@ Library = wp.media.controller.State.extend(/** @lends wp.media.controller.Librar * * @since 3.5.0 * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment for which to create display settings. * @return {Backbone.Model} A model representing the display settings for the attachment. */ display: function( attachment ) { @@ -175,7 +175,7 @@ Library = wp.media.controller.State.extend(/** @lends wp.media.controller.Librar * * @since 3.6.0 * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment for which to get the default display settings. * @return {Object} The default display settings for the attachment. */ defaultDisplaySettings: function( attachment ) { @@ -196,7 +196,7 @@ Library = wp.media.controller.State.extend(/** @lends wp.media.controller.Librar * * @since 4.4.1 * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to check. * @return {boolean} True if the attachment is an image, false otherwise. */ isImageAttachment: function( attachment ) { @@ -213,7 +213,7 @@ Library = wp.media.controller.State.extend(/** @lends wp.media.controller.Librar * * @since 3.6.0 * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to check. * @return {boolean} True if the attachment can be embedded, false otherwise. */ canEmbed: function( attachment ) { @@ -262,7 +262,7 @@ Library = wp.media.controller.State.extend(/** @lends wp.media.controller.Librar * * @since 3.5.0 * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment that was uploaded. */ uploading: function( attachment ) { var content = this.frame.content; diff --git a/src/js/media/controllers/region.js b/src/js/media/controllers/region.js index 982182469b12a..120b43f2937c4 100644 --- a/src/js/media/controllers/region.js +++ b/src/js/media/controllers/region.js @@ -33,7 +33,7 @@ _.extend( Region.prototype,/** @lends wp.media.controller.Region.prototype */{ * * @since 3.5.0 * - * @param {string} mode + * @param {string} mode The mode to activate on the region. * * @fires Region#activate * @fires Region#deactivate @@ -72,7 +72,7 @@ _.extend( Region.prototype,/** @lends wp.media.controller.Region.prototype */{ * * @since 3.5.0 * - * @param {string} mode + * @param {string} mode The mode to render on the region. * * @fires Region#create * @fires Region#render @@ -131,8 +131,8 @@ _.extend( Region.prototype,/** @lends wp.media.controller.Region.prototype */{ * * @since 3.5.0 * - * @param {Array|Object} views - * @param {Object} [options={}] + * @param {Array|Object} views The views to set on the region. + * @param {Object} [options={}] Optional. Additional options for setting the views on the region. * @return {wp.Backbone.Subviews} Subviews is returned to allow chaining. */ set: function( views, options ) { @@ -147,7 +147,7 @@ _.extend( Region.prototype,/** @lends wp.media.controller.Region.prototype */{ * * @since 3.5.0 * - * @param {string} event + * @param {string} event The event to trigger on the region. * @return {undefined|wp.media.controller.Region} Returns itself to allow chaining. */ trigger: function( event ) { diff --git a/src/js/media/controllers/state-machine.js b/src/js/media/controllers/state-machine.js index fb97c4e3cac58..d7ebd815a2c52 100644 --- a/src/js/media/controllers/state-machine.js +++ b/src/js/media/controllers/state-machine.js @@ -35,7 +35,7 @@ _.extend( StateMachine.prototype, Backbone.Events,/** @lends wp.media.controller * * @since 3.5.0 * - * @param {string} id + * @param {string} id The ID of the state to fetch. If omitted, the active state is returned. * @return {wp.media.controller.State} Returns a State model from * the StateMachine collection. */ @@ -60,7 +60,7 @@ _.extend( StateMachine.prototype, Backbone.Events,/** @lends wp.media.controller * * @since 3.5.0 * - * @param {string} id + * @param {string} id The ID of the state to set as active. * * @fires wp.media.controller.State#deactivate * @fires wp.media.controller.State#activate diff --git a/src/js/media/models/attachment.js b/src/js/media/models/attachment.js index c10f87447e0c2..a116edf4add40 100644 --- a/src/js/media/models/attachment.js +++ b/src/js/media/models/attachment.js @@ -14,9 +14,9 @@ Attachment = Backbone.Model.extend(/** @lends wp.media.model.Attachment.prototyp * Triggered when attachment details change * Overrides Backbone.Model.sync * - * @param {string} method - * @param {wp.media.model.Attachment} model - * @param {Object} [options={}] + * @param {string} method The method to be performed: 'read', 'update', or 'delete'. + * @param {wp.media.model.Attachment} model The attachment model being synced. + * @param {Object} [options={}] Optional. Additional options for the sync operation. * * @return {jQuery.Promise} A jQuery Promise that is resolved or rejected based on the success of the sync operation. */ @@ -144,7 +144,7 @@ Attachment = Backbone.Model.extend(/** @lends wp.media.model.Attachment.prototyp * * @static * - * @param {Object} attrs + * @param {Object} attrs The attributes for the new attachment model. * @return {wp.media.model.Attachment} The newly created attachment model. */ create: function( attrs ) { @@ -158,8 +158,8 @@ Attachment = Backbone.Model.extend(/** @lends wp.media.model.Attachment.prototyp * it returns the specified attachment. * * @static - * @param {string} id A string used to identify a model. - * @param {Backbone.Model|undefined} attachment + * @param {string} id A string used to identify a model. + * @param {Backbone.Model|undefined} attachment The attachment model to retrieve or create. * @return {wp.media.model.Attachment} */ get: _.memoize( function( id, attachment ) { diff --git a/src/js/media/models/attachments.js b/src/js/media/models/attachments.js index 80289cb43a061..fc6d79632d745 100644 --- a/src/js/media/models/attachments.js +++ b/src/js/media/models/attachments.js @@ -30,8 +30,8 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen /** * Initializes the Attachments collection. * - * @param {Array} [models=[]] Array of models used to populate the collection. - * @param {Object} [options={}] + * @param {Array} [models=[]] Optional. Array of models used to populate the collection. + * @param {Object} [options={}] Optional. Additional options for the collection. */ initialize: function( models, options ) { var normalizedOrder; @@ -81,8 +81,8 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * * @access private * - * @param {Backbone.Model} model - * @param {string} orderby + * @param {Backbone.Model} model The model that triggered the change. + * @param {string} orderby The new orderby value. */ _changeOrderby: function( model, orderby ) { // If a different comparator is defined, bail. @@ -101,8 +101,8 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * * @access private * - * @param {Backbone.Model} model - * @param {boolean} query + * @param {Backbone.Model} model The model that triggered the change. + * @param {boolean} query The new query value. */ _changeQuery: function( model, query ) { if ( query ) { @@ -117,7 +117,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * * @access private * - * @param {Backbone.Model} model + * @param {Backbone.Model} model The model that triggered the change. */ _changeFilteredProps: function( model ) { // If this is a query, updating the collection will be handled by @@ -163,7 +163,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen /** * Checks whether an attachment is valid. * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to validate. * @return {boolean} True if the attachment is valid, false otherwise. */ validator: function( attachment ) { @@ -178,8 +178,8 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen /** * Adds or removes an attachment to the collection depending on its validity. * - * @param {wp.media.model.Attachment} attachment - * @param {Object} options + * @param {wp.media.model.Attachment} attachment The attachment to validate and potentially add or remove. + * @param {Object} options Additional options for the operation. * @return {wp.media.model.Attachments} Returns itself to allow chaining. */ validate: function( attachment, options ) { @@ -198,8 +198,8 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen /** * Adds or removes all attachments from another collection depending on each one's validity. * - * @param {wp.media.model.Attachments} attachments - * @param {Object} [options={}] + * @param {wp.media.model.Attachments} attachments The attachments collection to validate against. + * @param {Object} [options={}] Additional options for the operation. * * @fires wp.media.model.Attachments#reset * @@ -281,9 +281,9 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * * @access private * - * @param {wp.media.model.Attachments} attachment - * @param {wp.media.model.Attachments} attachments - * @param {Object} options + * @param {wp.media.model.Attachments} attachment The attachment to validate. + * @param {wp.media.model.Attachments} attachments The attachments collection the attachment belongs to. + * @param {Object} options Additional options for the operation. * * @return {wp.media.model.Attachments} Returns itself to allow chaining. */ @@ -301,8 +301,8 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * * @access private * - * @param {wp.media.model.Attachments} attachments - * @param {Object} options + * @param {wp.media.model.Attachments} attachments The attachments collection to validate against. + * @param {Object} options Additional options for the operation. * @return {wp.media.model.Attachments} Returns itself to allow chaining. */ _validateAllHandler: function( attachments, options ) { @@ -355,7 +355,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * and forwards to its `more` method. This collection class doesn't have * server persistence by itself. * - * @param {Object} options + * @param {Object} options Additional options for the operation. * @return {Promise} A promise that resolves when the request is complete. */ more: function( options ) { @@ -424,7 +424,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * the collection items. * * @param {Object|Array} response The raw response Object/Array. - * @param {Object} xhr + * @param {Object} xhr The XMLHttpRequest object. * @return {Array} The array of model attributes to be added to the collection */ parse: function( response, xhr ) { @@ -505,9 +505,9 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * Used as the default comparator for instances of wp.media.model.Attachments * and its subclasses. @see wp.media.model.Attachments._changeOrderby(). * - * @param {Backbone.Model} a - * @param {Backbone.Model} b - * @param {Object} options + * @param {Backbone.Model} a The first attachment model to compare. + * @param {Backbone.Model} b The second attachment model to compare. + * @param {Object} options Additional options for the comparison. * @return {number} -1 if the first model should come before the second, * 0 if they are of the same rank and * 1 if the first model should come after. @@ -542,7 +542,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * Note that this client-side searching is *not* equivalent * to our server-side searching. * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to filter based on the search query. * * @this wp.media.model.Attachments * @@ -562,7 +562,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * Filters attachments based on their type. * * @static - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to filter based on its type. * * @this wp.media.model.Attachments * @@ -591,7 +591,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * Filters attachments based on their uploadedTo property. * * @static - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to filter based on its uploadedTo property. * * @this wp.media.model.Attachments * @@ -609,7 +609,7 @@ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachmen * Filters attachments based on their status property. * * @static - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment to filter based on its status property. * * @this wp.media.model.Attachments * diff --git a/src/js/media/models/query.js b/src/js/media/models/query.js index db6008a6fecf4..dbcdb87d77466 100644 --- a/src/js/media/models/query.js +++ b/src/js/media/models/query.js @@ -25,7 +25,7 @@ Query = Attachments.extend(/** @lends wp.media.model.Query.prototype */{ * Initializes the Query collection. * * @param {Array} [models=[]] Array of initial models to populate the collection. - * @param {Object} [options={}] + * @param {Object} [options={}] Additional options for initializing the query. */ initialize: function( models, options ) { var allowed; @@ -96,7 +96,7 @@ Query = Attachments.extend(/** @lends wp.media.model.Query.prototype */{ /** * Fetch more attachments from the server for the collection. * - * @param {Object} [options={}] + * @param {Object} [options={}] Additional options for fetching more attachments. * @return {Promise} A promise that resolves when the fetch is complete. */ more: function( options ) { @@ -124,9 +124,9 @@ Query = Attachments.extend(/** @lends wp.media.model.Query.prototype */{ * Overrides Backbone.Collection.sync * Overrides wp.media.model.Attachments.sync * - * @param {string} method - * @param {Backbone.Model} model - * @param {Object} [options={}] + * @param {string} method The sync method to be used (e.g., 'read', 'create', 'update', 'delete'). + * @param {Backbone.Model} model The model to be synced. + * @param {Object} [options={}] Additional options for syncing the query. * @return {Promise} A promise that resolves when the sync is complete. */ sync: function( method, model, options ) { @@ -214,19 +214,19 @@ Query = Attachments.extend(/** @lends wp.media.model.Query.prototype */{ * @static * @function * - * @param {Object} [props] - * @param {Object} [props.order] - * @param {Object} [props.orderby] - * @param {Object} [props.include] - * @param {Object} [props.exclude] - * @param {Object} [props.s] - * @param {Object} [props.post_mime_type] - * @param {Object} [props.posts_per_page] - * @param {Object} [props.menu_order] - * @param {Object} [props.post_parent] - * @param {Object} [props.post_status] - * @param {Object} [props.author] - * @param {Object} [options] + * @param {Object} [props] The properties to initialize the query with. + * @param {Object} [props.order] The order in which to sort the query results. + * @param {Object} [props.orderby] The property by which to order the query results. + * @param {Object} [props.include] The IDs of attachments to include in the query. + * @param {Object} [props.exclude] The IDs of attachments to exclude from the query. + * @param {Object} [props.s] The search term to filter attachments by. + * @param {Object} [props.post_mime_type] The MIME type to filter attachments by. + * @param {Object} [props.posts_per_page] The number of attachments to retrieve per page. + * @param {Object} [props.menu_order] The menu order to filter attachments by. + * @param {Object} [props.post_parent] The parent post ID to filter attachments by. + * @param {Object} [props.post_status] The status to filter attachments by. + * @param {Object} [props.author] The author ID to filter attachments by. + * @param {Object} [options] Additional options for the query. * * @return {wp.media.model.Query} A new Attachments Query collection. */ @@ -240,8 +240,8 @@ Query = Attachments.extend(/** @lends wp.media.model.Query.prototype */{ /** * Creates and returns an Attachments Query collection given the properties. * - * @param {Object} [props] - * @param {Object} [options] + * @param {Object} [props] The properties to initialize the query with. + * @param {Object} [options] Additional options for the query. * @return {Query} A new Attachments Query collection. */ return function( props, options ) { diff --git a/src/js/media/models/selection.js b/src/js/media/models/selection.js index b7ae7bbadd816..7e03ce4f4119e 100644 --- a/src/js/media/models/selection.js +++ b/src/js/media/models/selection.js @@ -18,8 +18,8 @@ Selection = Attachments.extend(/** @lends wp.media.model.Selection.prototype */{ * Binds `single` instead of using the context argument to ensure * it receives no parameters. * - * @param {Array} [models=[]] Array of models used to populate the collection. - * @param {Object} [options={}] + * @param {Array} [models=[]] Array of models used to populate the collection. + * @param {Object} [options={}] Additional options for the selection. */ initialize: function( models, options ) { /** @@ -35,8 +35,8 @@ Selection = Attachments.extend(/** @lends wp.media.model.Selection.prototype */{ * If the workflow does not support multi-select, clear out the selection * before adding a new attachment to it. * - * @param {Array} models - * @param {Object} options + * @param {Array} models The models to add to the selection. + * @param {Object} options Additional options for adding the models. * @return {wp.media.model.Attachment[]} The added attachments. */ add: function( models, options ) { @@ -52,7 +52,7 @@ Selection = Attachments.extend(/** @lends wp.media.model.Selection.prototype */{ /** * Fired when toggling (clicking on) an attachment in the modal. * - * @param {undefined|boolean|wp.media.model.Attachment} model + * @param {undefined|boolean|wp.media.model.Attachment} model The model to set as the single selection, or a boolean to clear it. * * @fires wp.media.model.Selection#selection:single * @fires wp.media.model.Selection#selection:unsingle diff --git a/src/js/media/views/attachment-compat.js b/src/js/media/views/attachment-compat.js index 3871b6e43f3fb..f2ba1872d76c4 100644 --- a/src/js/media/views/attachment-compat.js +++ b/src/js/media/views/attachment-compat.js @@ -62,7 +62,7 @@ AttachmentCompat = View.extend(/** @lends wp.media.view.AttachmentCompat.prototy /** * Prevents the default action of the event. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object associated with the action. */ preventDefault: function( event ) { event.preventDefault(); @@ -70,7 +70,7 @@ AttachmentCompat = View.extend(/** @lends wp.media.view.AttachmentCompat.prototy /** * Saves the attachment compat data. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object associated with the action. */ save: function( event ) { var data = {}; diff --git a/src/js/media/views/attachment.js b/src/js/media/views/attachment.js index e0033d355a1c6..152c150200a75 100644 --- a/src/js/media/views/attachment.js +++ b/src/js/media/views/attachment.js @@ -173,7 +173,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Toggles the selection state of the attachment. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object that triggered the selection toggle. */ toggleSelectionHandler: function( event ) { var method; @@ -229,7 +229,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Toggles the selection state of the attachment. * - * @param {Object} options + * @param {Object} options The options for toggling the selection state of the attachment. */ toggleSelection: function( options ) { var collection = this.collection, @@ -322,8 +322,8 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Selects the model in the selection. * - * @param {Backbone.Model} model - * @param {Backbone.Collection} collection + * @param {Backbone.Model} model The model to select. + * @param {Backbone.Collection} collection The collection containing the model. */ select: function( model, collection ) { var selection = this.options.selection, @@ -353,8 +353,8 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Deselects the model in the selection. * - * @param {Backbone.Model} model - * @param {Backbone.Collection} collection + * @param {Backbone.Model} model The model to deselect. + * @param {Backbone.Collection} collection The collection containing the model. */ deselect: function( model, collection ) { var selection = this.options.selection; @@ -373,8 +373,8 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Updates the view to reflect whether the model is the single model in the selection. * - * @param {Backbone.Model} model - * @param {Backbone.Collection} collection + * @param {Backbone.Model} model The model to check for details. + * @param {Backbone.Collection} collection The collection containing the model. */ details: function( model, collection ) { var selection = this.options.selection, @@ -390,7 +390,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Gets the image size object for the specified size. * - * @param {string} size + * @param {string} size The desired image size. * @return {Object} Returns an object containing the image size information. */ imageSize: function( size ) { @@ -425,7 +425,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Update the model's setting with the value from the input. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object that triggered the setting update. */ updateSetting: function( event ) { var $setting = $( event.target ).closest('[data-setting]'), @@ -478,7 +478,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Updates the view's save status. * - * @param {string} status + * @param {string} status The new save status to apply to the view. * @return {wp.media.view.Attachment} Returns itself to allow chaining. */ updateSave: function( status ) { @@ -522,7 +522,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ /** * Removes the model from the collection. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object that triggered the removal from the library. */ removeFromLibrary: function( event ) { // Catch enter and space events. @@ -540,7 +540,7 @@ Attachment = View.extend(/** @lends wp.media.view.Attachment.prototype */{ * Adds the model if it isn't in the selection, if it is in the selection, * removes it. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object that triggered the selection toggle. * @return {void} */ checkClickHandler: function ( event ) { @@ -576,8 +576,8 @@ _.each({ * @memberOf wp.media.view.Attachment * @instance * - * @param {Backbone.Model} model - * @param {string} value + * @param {Backbone.Model} model The model containing the caption. + * @param {string} value The new caption value. * @return {wp.media.view.Attachment} Returns itself to allow chaining. */ /** @@ -587,8 +587,8 @@ _.each({ * @memberOf wp.media.view.Attachment * @instance * - * @param {Backbone.Model} model - * @param {string} value + * @param {Backbone.Model} model The model containing the title. + * @param {string} value The new title value. * @return {wp.media.view.Attachment} Returns itself to allow chaining. */ /** @@ -598,8 +598,8 @@ _.each({ * @memberOf wp.media.view.Attachment * @instance * - * @param {Backbone.Model} model - * @param {string} value + * @param {Backbone.Model} model The model containing the artist. + * @param {string} value The new artist value. * @return {wp.media.view.Attachment} Returns itself to allow chaining. */ /** @@ -609,8 +609,8 @@ _.each({ * @memberOf wp.media.view.Attachment * @instance * - * @param {Backbone.Model} model - * @param {string} value + * @param {Backbone.Model} model The model containing the album. + * @param {string} value The new album value. * @return {wp.media.view.Attachment} Returns itself to allow chaining. */ Attachment.prototype[ method ] = function( model, value ) { diff --git a/src/js/media/views/attachments.js b/src/js/media/views/attachments.js index b2e91624cb159..5b8d91426c38c 100644 --- a/src/js/media/views/attachments.js +++ b/src/js/media/views/attachments.js @@ -365,7 +365,7 @@ Attachments = View.extend(/** @lends wp.media.view.Attachments.prototype */{ * * @since 3.5.0 * - * @param {wp.media.model.Attachment} attachment + * @param {wp.media.model.Attachment} attachment The attachment model for which to create a view. * * @return {wp.media.View} The created view. */ diff --git a/src/js/media/views/button.js b/src/js/media/views/button.js index a4fe1d7b7b2b2..0c8316340c2bb 100644 --- a/src/js/media/views/button.js +++ b/src/js/media/views/button.js @@ -74,7 +74,7 @@ var Button = wp.media.View.extend(/** @lends wp.media.view.Button.prototype */{ /** * Handles the click event. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object for the click action. */ click: function( event ) { if ( '#' === this.attributes.href ) { diff --git a/src/js/media/views/embed.js b/src/js/media/views/embed.js index a842974ba6c37..286eb16f8378c 100644 --- a/src/js/media/views/embed.js +++ b/src/js/media/views/embed.js @@ -32,7 +32,7 @@ var Embed = wp.media.View.extend(/** @lends wp.media.view.Embed.prototype */{ /** * Sets the settings for the embed view. * - * @param {Object} view + * @param {Object} view The view object to be set as the settings for the embed view. */ settings: function( view ) { if ( this._settings ) { diff --git a/src/js/media/views/frame.js b/src/js/media/views/frame.js index 851557d9f3ccb..3bbf47c7f8bb1 100644 --- a/src/js/media/views/frame.js +++ b/src/js/media/views/frame.js @@ -89,9 +89,9 @@ var Frame = wp.media.View.extend(/** @lends wp.media.view.Frame.prototype */{ /** * Map activeMode collection events to the frame. * - * @param {Backbone.Model} model - * @param {Backbone.Collection} collection - * @param {Object} options + * @param {Backbone.Model} model The model that triggered the event. + * @param {Backbone.Collection} collection The collection to which the model belongs. + * @param {Object} options The options object associated with the event. */ triggerModeEvents: function( model, collection, options ) { var collectionEvent, diff --git a/src/js/media/views/frame/post.js b/src/js/media/views/frame/post.js index e106b5457ae32..632779d56e7cb 100644 --- a/src/js/media/views/frame/post.js +++ b/src/js/media/views/frame/post.js @@ -263,7 +263,7 @@ Post = Select.extend(/** @lends wp.media.view.MediaFrame.Post.prototype */{ /** * Handles the main menu for the frame. * - * @param {wp.Backbone.View} view + * @param {wp.Backbone.View} view The menu view for the main menu. */ mainMenu: function( view ) { view.set({ @@ -294,7 +294,7 @@ Post = Select.extend(/** @lends wp.media.view.MediaFrame.Post.prototype */{ /** * Handles the gallery menu for the frame. * - * @param {wp.Backbone.View} view + * @param {wp.Backbone.View} view The menu view for the gallery menu. */ galleryMenu: function( view ) { var lastState = this.lastState(), @@ -326,7 +326,7 @@ Post = Select.extend(/** @lends wp.media.view.MediaFrame.Post.prototype */{ /** * Handles the playlist menu for the frame. * - * @param {wp.Backbone.View} view The menu view. + * @param {wp.Backbone.View} view The menu view for the playlist menu. */ playlistMenu: function( view ) { var lastState = this.lastState(), diff --git a/src/js/media/views/frame/select.js b/src/js/media/views/frame/select.js index 3f3c0642eea53..f736aa33be2a2 100644 --- a/src/js/media/views/frame/select.js +++ b/src/js/media/views/frame/select.js @@ -108,7 +108,7 @@ Select = MediaFrame.extend(/** @lends wp.media.view.MediaFrame.Select.prototype /** * Render callback for the router region in the `browse` mode. * - * @param {wp.media.view.Router} routerView + * @param {wp.media.view.Router} routerView The router view for the `browse` mode. */ browseRouter: function( routerView ) { routerView.set({ @@ -126,7 +126,7 @@ Select = MediaFrame.extend(/** @lends wp.media.view.MediaFrame.Select.prototype /** * Render callback for the content region in the `browse` mode. * - * @param {wp.media.controller.Region} contentRegion + * @param {wp.media.controller.Region} contentRegion The content region for the `browse` mode. */ browseContent: function( contentRegion ) { var state = this.state(); @@ -167,8 +167,8 @@ Select = MediaFrame.extend(/** @lends wp.media.view.MediaFrame.Select.prototype /** * Toolbars * - * @param {Object} toolbar - * @param {Object} [options={}] + * @param {Object} toolbar The toolbar object for the `select` mode. + * @param {Object} [options={}] The options for creating the select toolbar view. * @this wp.media.controller.Region */ createSelectToolbar: function( toolbar, options ) { diff --git a/src/js/media/views/media-details.js b/src/js/media/views/media-details.js index 988c6a88b2fb7..02286a55617bd 100644 --- a/src/js/media/views/media-details.js +++ b/src/js/media/views/media-details.js @@ -61,7 +61,7 @@ MediaDetails = AttachmentDisplay.extend(/** @lends wp.media.view.MediaDetails.pr * * @fires wp.media.view.MediaDetails#media:setting:remove * - * @param {Event} e + * @param {JQuery.Event} e The jQuery event object. */ removeSetting : function(e) { var wrap = $( e.currentTarget ).parent(), setting; @@ -94,7 +94,7 @@ MediaDetails = AttachmentDisplay.extend(/** @lends wp.media.view.MediaDetails.pr /** * Adds a source to the media details view. * - * @param {JQuery.Event} e The event object. + * @param {JQuery.Event} e The jQuery event object. */ addSource : function( e ) { this.controller.lastMime = $( e.currentTarget ).data( 'mime' ); @@ -184,7 +184,7 @@ MediaDetails = AttachmentDisplay.extend(/** @lends wp.media.view.MediaDetails.pr /** * When multiple players in the DOM contain the same src, things get weird. * - * @param {HTMLElement} elem + * @param {HTMLElement} elem The HTML element containing the media sources to be prepared. * @return {HTMLElement} The prepared element. */ prepareSrc : function( elem ) { diff --git a/src/js/media/views/media-frame.js b/src/js/media/views/media-frame.js index 2eb567051c885..99dfc675729da 100644 --- a/src/js/media/views/media-frame.js +++ b/src/js/media/views/media-frame.js @@ -160,7 +160,7 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ /** * Creates the title view. * - * @param {Object} title + * @param {Object} title The title object for creating the title view. * @this wp.media.controller.Region */ createTitle: function( title ) { @@ -172,7 +172,7 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ /** * Creates the menu view. * - * @param {Object} menu + * @param {Object} menu The menu object for creating the menu view. * @this wp.media.controller.Region */ createMenu: function( menu ) { @@ -203,7 +203,7 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ /** * Creates the toolbar view. * - * @param {Object} toolbar + * @param {Object} toolbar The toolbar object for creating the toolbar view. * @this wp.media.controller.Region */ createToolbar: function( toolbar ) { @@ -214,7 +214,7 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ /** * Creates the router view. * - * @param {Object} router + * @param {Object} router The router object for creating the router view. * @this wp.media.controller.Region */ createRouter: function( router ) { @@ -232,7 +232,7 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ /** * Creates the iframe states. * - * @param {Object} options + * @param {Object} options The options for creating the iframe states. */ createIframeStates: function( options ) { var settings = wp.media.view.settings, @@ -271,7 +271,7 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ /** * Creates the iframe content view. * - * @param {Object} content + * @param {Object} content The content object for creating the iframe content view. * @this wp.media.controller.Region */ iframeContent: function( content ) { diff --git a/src/js/media/views/menu.js b/src/js/media/views/menu.js index e970b2dc436e3..e0e2324402636 100644 --- a/src/js/media/views/menu.js +++ b/src/js/media/views/menu.js @@ -51,8 +51,8 @@ Menu = PriorityList.extend(/** @lends wp.media.view.Menu.prototype */{ /** * Creates a view for the given options and id. * - * @param {Object} options - * @param {string} id + * @param {Object} options The options for creating the view. + * @param {string} id The id of the view to create. * @return {wp.media.View} The view instance. */ toView: function( options, id ) { diff --git a/src/js/media/views/modal.js b/src/js/media/views/modal.js index 29150515a45cd..42f8da3c5024a 100644 --- a/src/js/media/views/modal.js +++ b/src/js/media/views/modal.js @@ -134,7 +134,8 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ /** * Closes the modal and triggers the close event. * - * @param {Object} options + * @param {Object} [options={}] The options for closing the modal. + * @param {boolean} [options.escape] Whether the modal is being closed due to the escape key. * @return {wp.media.view.Modal} Returns itself to allow chaining. */ close: function( options ) { @@ -187,7 +188,7 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ /** * Handles the escape key press event to close the modal. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object. */ escapeHandler: function( event ) { event.preventDefault(); @@ -199,7 +200,7 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ * * @since 6.7 * - * @param {Object} event The keydown event object. + * @param {JQuery.Event} event The jQuery event object. */ selectHandler: function( event ) { var selection = this.controller.state().get( 'selection' ); @@ -232,7 +233,7 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ * Triggers a modal event and if the `propagate` option is set, * forwards events to the modal's controller. * - * @param {string} id + * @param {string} id The ID of the event to propagate. * @return {wp.media.view.Modal} Returns itself to allow chaining. */ propagate: function( id ) { @@ -247,7 +248,7 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ /** * Handles keydown events within the modal. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery keydown event object. */ keydown: function( event ) { // Close the modal when escape is pressed. diff --git a/src/js/media/views/priority-list.js b/src/js/media/views/priority-list.js index 28a83f753d78b..f0ed9dbeab84e 100644 --- a/src/js/media/views/priority-list.js +++ b/src/js/media/views/priority-list.js @@ -24,9 +24,9 @@ var PriorityList = wp.media.View.extend(/** @lends wp.media.view.PriorityList.pr /** * Adds a view to the list, sorted by its priority. * - * @param {string} id - * @param {wp.media.View|Object} view - * @param {Object} options + * @param {string} id The ID of the view to set. + * @param {wp.media.View|Object} view The view to set. + * @param {Object} options The options for setting the view. * @return {wp.media.view.PriorityList} Returns itself to allow chaining. */ set: function( id, view, options ) { @@ -69,7 +69,7 @@ var PriorityList = wp.media.View.extend(/** @lends wp.media.view.PriorityList.pr /** * Retrieves a view by its ID. * - * @param {string} id + * @param {string} id The ID of the view to retrieve. * @return {wp.media.View} Returns the view if found, otherwise undefined. */ get: function( id ) { @@ -78,7 +78,7 @@ var PriorityList = wp.media.View.extend(/** @lends wp.media.view.PriorityList.pr /** * Removes a view by its ID. * - * @param {string} id + * @param {string} id The ID of the view to remove. * @return {wp.media.view.PriorityList} Returns itself to allow chaining. */ unset: function( id ) { @@ -94,7 +94,7 @@ var PriorityList = wp.media.View.extend(/** @lends wp.media.view.PriorityList.pr /** * Creates a view from an object of options. * - * @param {Object} options + * @param {Object} options The options for creating the view. * @return {wp.media.View} Returns the created view. */ toView: function( options ) { diff --git a/src/js/media/views/settings.js b/src/js/media/views/settings.js index 0bbe7da8b21fd..c737a3b52e0bb 100644 --- a/src/js/media/views/settings.js +++ b/src/js/media/views/settings.js @@ -52,7 +52,7 @@ Settings = View.extend(/** @lends wp.media.view.Settings.prototype */{ /** * Updates the selected value for a setting. * - * @param {string} key + * @param {string} key The key of the setting to update. */ update: function( key ) { var value = this.model.get( key ), @@ -101,7 +101,7 @@ Settings = View.extend(/** @lends wp.media.view.Settings.prototype */{ /** * Updates the model when a setting is changed. * - * @param {Object} event + * @param {JQuery.Event} event The jQuery event object associated with the setting change. */ updateHandler: function( event ) { var $setting = $( event.target ).closest('[data-setting]'), diff --git a/src/js/media/views/toolbar.js b/src/js/media/views/toolbar.js index 99b88bfaa1d65..68d58d93faffc 100644 --- a/src/js/media/views/toolbar.js +++ b/src/js/media/views/toolbar.js @@ -83,9 +83,9 @@ Toolbar = View.extend(/** @lends wp.media.view.Toolbar.prototype */{ /** * Sets a view by its ID. * - * @param {string} id - * @param {Backbone.View|Object} view - * @param {Object} [options={}] + * @param {string} id The ID of the view to set. + * @param {Backbone.View|Object} view The view to set. + * @param {Object} [options={}] The options for setting the view. * @return {wp.media.view.Toolbar} Returns itself to allow chaining. */ set: function( id, view, options ) { @@ -121,7 +121,7 @@ Toolbar = View.extend(/** @lends wp.media.view.Toolbar.prototype */{ /** * Retrieves a view by its ID. * - * @param {string} id + * @param {string} id The ID of the view to retrieve. * @return {wp.media.view.Button} The view associated with the given ID, or undefined if no view is found. */ get: function( id ) { @@ -130,8 +130,8 @@ Toolbar = View.extend(/** @lends wp.media.view.Toolbar.prototype */{ /** * Unsets a view by its ID. * - * @param {string} id - * @param {Object} options + * @param {string} id The ID of the view to unset. + * @param {Object} [options={}] The options for unsetting the view. * @return {wp.media.view.Toolbar} Returns itself to allow chaining. */ unset: function( id, options ) { diff --git a/src/js/media/views/uploader/status.js b/src/js/media/views/uploader/status.js index 370f4df223ece..390b17f9155ec 100644 --- a/src/js/media/views/uploader/status.js +++ b/src/js/media/views/uploader/status.js @@ -107,7 +107,7 @@ UploaderStatus = View.extend(/** @lends wp.media.view.UploaderStatus.prototype * /** * Escapes the filename to prevent XSS attacks. * - * @param {string} filename + * @param {string} filename The name of the file to be escaped. * @return {string} Escaped filename. */ filename: function( filename ) { @@ -116,7 +116,7 @@ UploaderStatus = View.extend(/** @lends wp.media.view.UploaderStatus.prototype * /** * Handles an error event from the uploader queue. * - * @param {Backbone.Model} error + * @param {Backbone.Model} error The error model from the uploader queue. * @return {void} */ error: function( error ) { From 5b1696e12c15d8354061f079ad6cca4273a895f6 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Fri, 11 Sep 2026 07:56:45 +0000 Subject: [PATCH 208/363] Docs: Add missing blank line after `@since` in block parser The PHP inline documentation standards require a blank line between the `@since` tag and the following `@param`/`@return` tags. Developed in: https://github.com/WordPress/wordpress-develop/pull/13482 Props mukesh27, wildworks. See #65818. git-svn-id: https://develop.svn.wordpress.org/trunk@63599 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-block-parser.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/wp-includes/class-wp-block-parser.php b/src/wp-includes/class-wp-block-parser.php index 81cb7a8fa21f7..c7e087ece8711 100644 --- a/src/wp-includes/class-wp-block-parser.php +++ b/src/wp-includes/class-wp-block-parser.php @@ -85,6 +85,7 @@ public function parse( $document ) { * * @internal * @since 5.0.0 + * * @return bool */ public function proceed() { @@ -231,6 +232,7 @@ public function proceed() { * @internal * @since 5.0.0 * @since 4.6.1 fixed a bug in attribute parsing which caused catastrophic backtracking on invalid block comments + * * @return array */ public function next_token() { @@ -318,6 +320,7 @@ public function freeform( $inner_html ) { * * @internal * @since 5.0.0 + * * @param null|int $length How many bytes of document text to output. */ public function add_freeform( $length = null ) { @@ -336,6 +339,7 @@ public function add_freeform( $length = null ) { * * @internal * @since 5.0.0 + * * @param WP_Block_Parser_Block $block The block to add to the output. * @param int $token_start Byte offset into the document where the first token for the block starts. * @param int $token_length Byte length of entire block from start of opening token to end of closing token. @@ -360,6 +364,7 @@ public function add_inner_block( WP_Block_Parser_Block $block, $token_start, $to * * @internal * @since 5.0.0 + * * @param int|null $end_offset byte offset into document for where we should stop sending text output as HTML. */ public function add_block_from_stack( $end_offset = null ) { From 27e5189217d8a28c4bbf05e0827b3a17319aa951 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Fri, 11 Sep 2026 10:50:50 +0000 Subject: [PATCH 209/363] General: Fix indentation and alignments in JavaScript inline documentation blocks. Enables the following JSDoc rules: - `jsdoc/check-alignment` - `jsdoc/check-indentation` - `jsdoc/check-line-alignment` - `jsdoc/require-hyphen-before-param-description` -> never Fixes all the reported violations. Also removes hyphens before descriptions. Part of the effort to improve JS inline documentation for 7.2. Developed in https://github.com/WordPress/wordpress-develop/pull/13490 Props afercia, mukesh27. See #66033. git-svn-id: https://develop.svn.wordpress.org/trunk@63600 602fd350-edb4-49c9-b593-d223f7449a82 --- .eslintrc-jsdoc.js | 16 ++ .../_enqueues/admin/application-passwords.js | 4 +- src/js/_enqueues/admin/common.js | 21 ++- src/js/_enqueues/admin/custom-background.js | 2 +- src/js/_enqueues/admin/edit-comments.js | 26 +-- src/js/_enqueues/admin/inline-edit-post.js | 8 +- src/js/_enqueues/admin/inline-edit-tax.js | 13 +- src/js/_enqueues/admin/media.js | 2 +- src/js/_enqueues/admin/postbox.js | 4 +- src/js/_enqueues/admin/tags-box.js | 14 +- src/js/_enqueues/admin/widgets.js | 2 +- src/js/_enqueues/lib/accordion.js | 3 + src/js/_enqueues/lib/admin-bar.js | 12 +- src/js/_enqueues/lib/auth-check.js | 5 +- .../_enqueues/lib/codemirror/htmlhint-kses.js | 6 +- .../lib/codemirror/javascript-lint.js | 22 +-- src/js/_enqueues/lib/color-picker.js | 8 +- src/js/_enqueues/lib/cookies.js | 12 +- src/js/_enqueues/lib/emoji-loader.js | 22 +-- src/js/_enqueues/lib/image-edit.js | 32 ++-- src/js/_enqueues/lib/lists.js | 2 +- src/js/_enqueues/lib/pointer.js | 2 +- src/js/_enqueues/lib/quicktags.js | 8 +- src/js/_enqueues/lib/user-suggest.js | 8 +- src/js/_enqueues/wp/api.js | 11 +- src/js/_enqueues/wp/backbone.js | 6 +- src/js/_enqueues/wp/code-editor.js | 160 +++++++++--------- src/js/_enqueues/wp/custom-header.js | 2 +- src/js/_enqueues/wp/customize/base.js | 2 +- src/js/_enqueues/wp/customize/controls.js | 2 +- src/js/_enqueues/wp/customize/loader.js | 2 +- src/js/_enqueues/wp/dashboard.js | 8 +- src/js/_enqueues/wp/editor/base.js | 41 +++-- src/js/_enqueues/wp/editor/dfw.js | 10 +- src/js/_enqueues/wp/embed.js | 2 +- src/js/_enqueues/wp/emoji.js | 4 +- src/js/_enqueues/wp/heartbeat.js | 9 +- src/js/_enqueues/wp/media/audiovideo.js | 4 +- src/js/_enqueues/wp/media/editor.js | 38 ++--- .../_enqueues/wp/password-strength-meter.js | 6 +- src/js/_enqueues/wp/sanitize.js | 4 +- src/js/_enqueues/wp/theme-plugin-editor.js | 48 +++--- src/js/_enqueues/wp/theme.js | 4 +- src/js/_enqueues/wp/updates.js | 8 +- src/js/_enqueues/wp/utils/word-count.js | 4 +- src/js/_enqueues/wp/widgets/custom-html.js | 22 +-- src/js/_enqueues/wp/widgets/media-audio.js | 2 +- src/js/_enqueues/wp/widgets/media-gallery.js | 10 +- src/js/_enqueues/wp/widgets/media-image.js | 2 +- src/js/_enqueues/wp/widgets/media-video.js | 2 +- src/js/_enqueues/wp/widgets/media.js | 46 ++--- src/js/_enqueues/wp/widgets/text.js | 14 +- src/js/media/controllers/state.js | 12 +- src/js/media/models/attachment.js | 2 +- src/js/media/models/attachments.js | 4 +- src/js/media/models/post-media.js | 2 +- src/js/media/models/query.js | 2 +- src/js/media/views/attachments/browser.js | 4 +- src/js/media/views/focus-manager.js | 16 +- tools/gutenberg/copy.js | 36 ++-- 60 files changed, 421 insertions(+), 384 deletions(-) diff --git a/.eslintrc-jsdoc.js b/.eslintrc-jsdoc.js index dc6559c520cbe..93c13a857b7b3 100644 --- a/.eslintrc-jsdoc.js +++ b/.eslintrc-jsdoc.js @@ -36,6 +36,21 @@ module.exports = [ }, }, rules: { + 'jsdoc/check-alignment': 'error', + 'jsdoc/check-indentation': [ 'error', { + excludeTags: [ + 'deprecated', + 'example', + 'param', + 'property', + 'return', + 'since', + 'todo', + ], + } ], + 'jsdoc/check-line-alignment': [ 'error', 'always', { + tags: [ 'param', 'property' ], + } ], 'jsdoc/check-param-names': 'error', 'jsdoc/check-syntax': 'error', 'jsdoc/check-tag-names': [ 'error', { @@ -48,6 +63,7 @@ module.exports = [ } ], 'jsdoc/check-types': 'error', 'jsdoc/require-description': 'error', + 'jsdoc/require-hyphen-before-param-description': [ 'error', 'never' ], 'jsdoc/require-jsdoc': 'error', 'jsdoc/require-param': [ 'error', { enableFixer: false, diff --git a/src/js/_enqueues/admin/application-passwords.js b/src/js/_enqueues/admin/application-passwords.js index ab3d2fc4de35a..21fbeb65820af 100644 --- a/src/js/_enqueues/admin/application-passwords.js +++ b/src/js/_enqueues/admin/application-passwords.js @@ -172,8 +172,8 @@ * * @since 5.6.0 * - * @param {jqXHR} xhr The XHR object from the ajax call. - * @param {string} textStatus The string categorizing the ajax request's status. + * @param {jqXHR} xhr The XHR object from the ajax call. + * @param {string} textStatus The string categorizing the ajax request's status. * @param {string} errorThrown The HTTP status error text. */ function handleErrorResponse( xhr, textStatus, errorThrown ) { diff --git a/src/js/_enqueues/admin/common.js b/src/js/_enqueues/admin/common.js index 735a9aeeaabef..fe83cc7e9f2ae 100644 --- a/src/js/_enqueues/admin/common.js +++ b/src/js/_enqueues/admin/common.js @@ -2,15 +2,14 @@ * @output wp-admin/js/common.js */ -/* global setUserSetting, ajaxurl, alert, confirm, pagenow */ -/* global columns, screenMeta */ +/* global setUserSetting, ajaxurl, alert, confirm, pagenow, columns, screenMeta */ /** - * Adds common WordPress functionality to the window. + * Adds common WordPress functionality to the window. * - * @param {JQueryStatic} $ The jQuery object. - * @param {Object} window The window object. - * @param {*} undefined Unused. + * @param {JQueryStatic} $ The jQuery object. + * @param {Object} window The window object. + * @param {*} undefined Unused. */ ( function( $, window, undefined ) { var $document = $( document ), @@ -568,8 +567,8 @@ window.showNotice = { * @since 3.2.0 * * @type {{element: null, toggles: null, page: null, init: screenMeta.init, - * toggleEvent: screenMeta.toggleEvent, open: screenMeta.open, - * close: screenMeta.close}} + * toggleEvent: screenMeta.toggleEvent, open: screenMeta.open, + * close: screenMeta.close}} * * @return {void} */ @@ -980,8 +979,8 @@ $( function() { /* * Show the sub instead of following the link if: - * - the submenu is not open. - * - the submenu is not shown inline or the menu is not folded. + * - the submenu is not open. + * - the submenu is not shown inline or the menu is not folded. */ if ( ! $menuItem.hasClass( 'opensub' ) && ( ! $menuItem.hasClass( 'wp-menu-open' ) || $menuItem.width() < 40 ) ) { event.preventDefault(); @@ -1485,7 +1484,7 @@ $( function() { * @param {Event} e The event object. * * @return {void} - */ + */ $('#contextual-help-link, #show-settings-link').on( 'focus.scroll-into-view', function(e){ if ( e.target.scrollIntoViewIfNeeded ) e.target.scrollIntoViewIfNeeded(false); diff --git a/src/js/_enqueues/admin/custom-background.js b/src/js/_enqueues/admin/custom-background.js index d8ef84e618bc1..b10a72296d2c6 100644 --- a/src/js/_enqueues/admin/custom-background.js +++ b/src/js/_enqueues/admin/custom-background.js @@ -124,7 +124,7 @@ * @since 3.5.0 * * @return {void} - */ + */ frame.on( 'select', function() { // Grab the selected attachment. var attachment = frame.state().get('selection').first(); diff --git a/src/js/_enqueues/admin/edit-comments.js b/src/js/_enqueues/admin/edit-comments.js index b6763c386149e..7e89f1c0dd7cb 100644 --- a/src/js/_enqueues/admin/edit-comments.js +++ b/src/js/_enqueues/admin/edit-comments.js @@ -42,7 +42,7 @@ var getCount, updateCount, updateCountText, updatePending, updateApproved, * @access private * * @param {jQuery} el The jQuery element to update. - * @param {number} n Number to be put in the element. + * @param {number} n Number to be put in the element. * * @return {void} */ @@ -68,7 +68,7 @@ var getCount, updateCount, updateCountText, updatePending, updateApproved, * @since 4.4.0 * @access private * - * @param {number} diff The amount to lower or raise the approved count with. + * @param {number} diff The amount to lower or raise the approved count with. * @param {number} commentPostId The ID of the post to be updated. * * @return {void} @@ -122,7 +122,7 @@ var getCount, updateCount, updateCountText, updatePending, updateApproved, * * @param {string} selector The jQuery selector for elements to update a count * for. - * @param {number} diff The amount to lower or raise the count with. + * @param {number} diff The amount to lower or raise the count with. * * @return {void} */ @@ -231,7 +231,7 @@ var getCount, updateCount, updateCountText, updatePending, updateApproved, * @since 3.2.0 * @access private * - * @param {number} diff The amount to lower or raise the pending count with. + * @param {number} diff The amount to lower or raise the pending count with. * @param {number} commentPostId The ID of the post to be updated. * * @return {void} @@ -322,9 +322,9 @@ window.setCommentsList = function() { * @since 2.8.0 * @access private * - * @param {number} total Total number of comments. - * @param {number} time Unix timestamp of response. - * @param {boolean} setConfidentTime Whether to update the last confident time + * @param {number} total Total number of comments. + * @param {number} time Unix timestamp of response. + * @param {boolean} setConfidentTime Whether to update the last confident time * with the given time. * * @return {void} @@ -345,7 +345,7 @@ window.setCommentsList = function() { * @since 2.5.0 * @access private * - * @param {Object} r Ajax response object. + * @param {Object} r Ajax response object. * @param {Object} settings Settings for the wpList object. * * @return {void} @@ -398,8 +398,8 @@ window.setCommentsList = function() { * @since 2.8.0 * @access private * - * @param {Object} settings Settings for the wpList object. - * @param {HTMLElement} list Comments table element. + * @param {Object} settings Settings for the wpList object. + * @param {HTMLElement} list Comments table element. * * @return {Object} The settings object. */ @@ -471,7 +471,7 @@ window.setCommentsList = function() { * @since 2.5.0 * @access private * - * @param {Object} r Ajax response object. + * @param {Object} r Ajax response object. * @param {Object} settings Settings for the wpList object. * * @return {void} @@ -945,8 +945,8 @@ window.commentReply = { * @memberof commentReply * * @param {number} comment_id The comment ID to open an editor for. - * @param {number} post_id The post ID to open an editor for. - * @param {string} action The action to perform. Either 'edit' or 'replyto'. + * @param {number} post_id The post ID to open an editor for. + * @param {string} action The action to perform. Either 'edit' or 'replyto'. * * @return {boolean} Always false. */ diff --git a/src/js/_enqueues/admin/inline-edit-post.js b/src/js/_enqueues/admin/inline-edit-post.js index 7f469137fc1bd..aaf4bcc5bc3ec 100644 --- a/src/js/_enqueues/admin/inline-edit-post.js +++ b/src/js/_enqueues/admin/inline-edit-post.js @@ -18,11 +18,11 @@ window.wp = window.wp || {}; * * @type {Object} * - * @property {string} type The type of inline editor. - * @property {string} what The prefix before the post ID. + * @property {string} type The type of inline editor. + * @property {string} what The prefix before the post ID. * - * @param {JQueryStatic} $ The jQuery object. - * @param {wp} wp The WordPress global object. + * @param {JQueryStatic} $ The jQuery object. + * @param {wp} wp The WordPress global object. * */ ( function( $, wp ) { diff --git a/src/js/_enqueues/admin/inline-edit-tax.js b/src/js/_enqueues/admin/inline-edit-tax.js index 620533455f6be..cedbefa256d93 100644 --- a/src/js/_enqueues/admin/inline-edit-tax.js +++ b/src/js/_enqueues/admin/inline-edit-tax.js @@ -13,12 +13,11 @@ window.wp = window.wp || {}; * * @namespace inlineEditTax * - * @property {string} type The type of inline edit we are currently on. - * @property {string} what The type property with a hash prefixed and a dash - * suffixed. + * @property {string} type The type of inline edit we are currently on. + * @property {string} what The type property with a hash prefixed and a dash suffixed. * - * @param {JQueryStatic} $ The jQuery object. - * @param {Object} wp The WordPress object. + * @param {JQueryStatic} $ The jQuery object. + * @param {Object} wp The WordPress object. */ ( function( $, wp ) { @@ -117,7 +116,7 @@ window.inlineEditTax = { * * @param {string|HTMLElement} id The ID of the term we want to quick edit or an * element within the table row or the - * table row itself. + * table row itself. * @return {boolean} Always returns false. */ edit : function(id) { @@ -164,7 +163,7 @@ window.inlineEditTax = { * * @param {string|HTMLElement} id The ID of the term we want to quick edit or an * element within the table row or the - * table row itself. + * table row itself. * @return {boolean} Always returns false. */ save : function(id) { diff --git a/src/js/_enqueues/admin/media.js b/src/js/_enqueues/admin/media.js index db61220b50e5f..f464fe960b03f 100644 --- a/src/js/_enqueues/admin/media.js +++ b/src/js/_enqueues/admin/media.js @@ -24,7 +24,7 @@ * @memberOf findPosts * * @param {string} af_name The name of the affected element. - * @param {string} af_val The value of the affected post element. + * @param {string} af_val The value of the affected post element. * * @return {boolean} Always returns false. */ diff --git a/src/js/_enqueues/admin/postbox.js b/src/js/_enqueues/admin/postbox.js index 1f101d3fd1c41..fd227b798eafb 100644 --- a/src/js/_enqueues/admin/postbox.js +++ b/src/js/_enqueues/admin/postbox.js @@ -353,8 +353,8 @@ * * @memberof postboxes * - * @param {string} page The page we are currently on. - * @param {Object} [args={}] The arguments for the postbox initializer. + * @param {string} page The page we are currently on. + * @param {Object} [args={}] The arguments for the postbox initializer. * @param {Function} args.pbshow A callback that is called when a postbox opens. * @param {Function} args.pbhide A callback that is called when a postbox * closes. diff --git a/src/js/_enqueues/admin/tags-box.js b/src/js/_enqueues/admin/tags-box.js index 99d664691c9c8..a3e1e901be22c 100644 --- a/src/js/_enqueues/admin/tags-box.js +++ b/src/js/_enqueues/admin/tags-box.js @@ -219,11 +219,11 @@ * * @memberOf tagBox * - * @param {Object} el The container HTML element. - * @param {Object|boolean} a When this is an HTML element the text of that - * element will be used for the new tag. - * @param {number|boolean} f If this value is not passed then the tag input - * field is focused. + * @param {Object} el The container HTML element. + * @param {Object|boolean} a When this is an HTML element the text of that + * element will be used for the new tag. + * @param {number|boolean} f If this value is not passed then the tag input + * field is focused. * * @return {boolean} Always returns false. */ @@ -287,8 +287,8 @@ * * @since 2.9.0 * - * @param {number|string} r The response message from the Ajax call. - * @param {string} stat The status of the Ajax request. + * @param {number|string} r The response message from the Ajax call. + * @param {string} stat The status of the Ajax request. * * @return {void} */ diff --git a/src/js/_enqueues/admin/widgets.js b/src/js/_enqueues/admin/widgets.js index cbd8f8dd4a222..f63f0182853ef 100644 --- a/src/js/_enqueues/admin/widgets.js +++ b/src/js/_enqueues/admin/widgets.js @@ -752,7 +752,7 @@ $( function(){ wpWidgets.init(); } ); * @deprecated 5.5.0 * * @type {Object} -*/ + */ wpWidgets.l10n = wpWidgets.l10n || { save: '', saved: '', diff --git a/src/js/_enqueues/lib/accordion.js b/src/js/_enqueues/lib/accordion.js index 867b6d7ac0a04..1310033f4c1ff 100644 --- a/src/js/_enqueues/lib/accordion.js +++ b/src/js/_enqueues/lib/accordion.js @@ -5,6 +5,8 @@ * with one section opening at a time when its title is clicked. * Use the following markup structure for accordion behavior: * + * @example + * ```html *
    *
    *

    @@ -22,6 +24,7 @@ *
    *
    *
    + * ``` * * Note that any appropriate tags may be used, as long as the above classes are present. * diff --git a/src/js/_enqueues/lib/admin-bar.js b/src/js/_enqueues/lib/admin-bar.js index 3d6f4e3c8b94d..4430ccc7ecb77 100644 --- a/src/js/_enqueues/lib/admin-bar.js +++ b/src/js/_enqueues/lib/admin-bar.js @@ -174,7 +174,7 @@ * @since 5.3.1 * * @param {NodeList} topMenuItems All menu items. - * @param {Event} event The click event. + * @param {Event} event The click event. */ function mobileHover( topMenuItems, event ) { var wrapper; @@ -260,7 +260,7 @@ * * @since 5.3.1 * - * @param {HTMLElement} element The HTML element. + * @param {HTMLElement} element The HTML element. * @param {string} className The class name. * @return {boolean} Whether the element has the className. */ @@ -286,7 +286,7 @@ * * @since 5.3.1 * - * @param {HTMLElement} element The HTML element. + * @param {HTMLElement} element The HTML element. * @param {string} className The class name. */ function addClass( element, className ) { @@ -315,7 +315,7 @@ * * @since 5.3.1 * - * @param {HTMLElement} element The HTML element. + * @param {HTMLElement} element The HTML element. * @param {string} className The class name. */ function removeClass( element, className ) { @@ -395,8 +395,8 @@ * * @since 5.3.1 * - * @param {HTMLElement} el Element to get parent. - * @param {string} selector CSS selector to match. + * @param {HTMLElement} el Element to get parent. + * @param {string} selector CSS selector to match. * * @return {HTMLElement|null} The closest matching element or null if not found. */ diff --git a/src/js/_enqueues/lib/auth-check.js b/src/js/_enqueues/lib/auth-check.js index 1617da0cb25bd..f05d6643bf776 100644 --- a/src/js/_enqueues/lib/auth-check.js +++ b/src/js/_enqueues/lib/auth-check.js @@ -137,14 +137,13 @@ * Binds to the Heartbeat Tick event. * * - Shows the authentication form popup if user is not logged in. - * - Hides the authentication form popup if it is already visible and user is - * logged in. + * - Hides the authentication form popup if it is already visible and user is logged in. * * @ignore * * @since 3.6.0 * - * @param {Object} e The heartbeat-tick event that has been triggered. + * @param {Object} e The heartbeat-tick event that has been triggered. * @param {Object} data Response data. */ $( function() { diff --git a/src/js/_enqueues/lib/codemirror/htmlhint-kses.js b/src/js/_enqueues/lib/codemirror/htmlhint-kses.js index e08c4c0f5b756..e40a8ca8f3631 100644 --- a/src/js/_enqueues/lib/codemirror/htmlhint-kses.js +++ b/src/js/_enqueues/lib/codemirror/htmlhint-kses.js @@ -8,9 +8,9 @@ HTMLHint.addRule( { * Initialize. * * @this {import('htmlhint/types').Rule} - * @param {import('htmlhint').HTMLParser} parser - Parser. - * @param {import('htmlhint').Reporter} reporter - Reporter. - * @param {Record>} options - KSES options. + * @param {import('htmlhint').HTMLParser} parser Parser. + * @param {import('htmlhint').Reporter} reporter Reporter. + * @param {Record>} options KSES options. * @return {void} */ init: function ( parser, reporter, options ) { diff --git a/src/js/_enqueues/lib/codemirror/javascript-lint.js b/src/js/_enqueues/lib/codemirror/javascript-lint.js index 74c4cbacc0c5f..15fefe832805c 100644 --- a/src/js/_enqueues/lib/codemirror/javascript-lint.js +++ b/src/js/_enqueues/lib/codemirror/javascript-lint.js @@ -12,10 +12,10 @@ import CodeMirror from 'codemirror'; * @see https://codemirror.net/5/doc/manual.html#addon_lint * * @typedef {Object} CodeMirrorLintError - * @property {string} message Error message. - * @property {'error'} severity Severity. - * @property {CodeMirror.Position} from From position. - * @property {CodeMirror.Position} to To position. + * @property {string} message Error message. + * @property {'error'} severity Severity. + * @property {CodeMirror.Position} from From position. + * @property {CodeMirror.Position} to To position. */ /** @@ -25,12 +25,12 @@ import CodeMirror from 'codemirror'; * @see https://www.npmjs.com/package/espree#options * * @typedef {Object} SupportedJSHintOptions - * @property {import('espree').Options['ecmaVersion']} [esversion] "This option is used to specify the ECMAScript version to which the code must adhere." - * @property {boolean} [es5] "This option enables syntax first defined in the ECMAScript 5.1 specification. This includes allowing reserved keywords as object properties." - * @property {boolean} [es3] "This option tells JSHint that your code needs to adhere to ECMAScript 3 specification. Use this option if you need your program to be executable in older browsers—such as Internet Explorer 6/7/8/9—and other legacy JavaScript environments." - * @property {boolean} [module] "This option informs JSHint that the input code describes an ECMAScript 6 module. All module code is interpreted as strict mode code." - * @property {'implied'} [strict] "This option requires the code to run in ECMAScript 5's strict mode." - * @property {string} [espreeModuleUrl] The URL to the espree script module. + * @property {import('espree').Options['ecmaVersion']} [esversion] "This option is used to specify the ECMAScript version to which the code must adhere." + * @property {boolean} [es5] "This option enables syntax first defined in the ECMAScript 5.1 specification. This includes allowing reserved keywords as object properties." + * @property {boolean} [es3] "This option tells JSHint that your code needs to adhere to ECMAScript 3 specification. Use this option if you need your program to be executable in older browsers—such as Internet Explorer 6/7/8/9—and other legacy JavaScript environments." + * @property {boolean} [module] "This option informs JSHint that the input code describes an ECMAScript 6 module. All module code is interpreted as strict mode code." + * @property {'implied'} [strict] "This option requires the code to run in ECMAScript 5's strict mode." + * @property {string} [espreeModuleUrl] The URL to the espree script module. */ /** @@ -38,7 +38,7 @@ import CodeMirror from 'codemirror'; * * @since 7.0.0 * - * @param {string} text Source. + * @param {string} text Source. * @param {SupportedJSHintOptions} options Linting options. * @return {Promise} Linting errors. */ diff --git a/src/js/_enqueues/lib/color-picker.js b/src/js/_enqueues/lib/color-picker.js index bcf3d0eb842a4..d8258c53de22c 100644 --- a/src/js/_enqueues/lib/color-picker.js +++ b/src/js/_enqueues/lib/color-picker.js @@ -69,8 +69,8 @@ * * @ignore * - * @param {Event} event The event that's being called. - * @param {HTMLElement} ui The HTMLElement containing the color picker. + * @param {Event} event The event that's being called. + * @param {HTMLElement} ui The HTMLElement containing the color picker. * * @return {void} */ @@ -189,8 +189,8 @@ * * @ignore * - * @param {Event} event The event that's being called. - * @param {HTMLElement} ui The HTMLElement containing the color picker. + * @param {Event} event The event that's being called. + * @param {HTMLElement} ui The HTMLElement containing the color picker. * * @return {void} */ diff --git a/src/js/_enqueues/lib/cookies.js b/src/js/_enqueues/lib/cookies.js index 30a29d496a02e..bb398fe8ce487 100644 --- a/src/js/_enqueues/lib/cookies.js +++ b/src/js/_enqueues/lib/cookies.js @@ -63,12 +63,12 @@ window.wpCookies = { * * 'values_obj' is the JS object that is stored. It is encoded as URI in wpCookies.set(). * - * @param {string} name The name of the cookie. - * @param {Object} values_obj The values to store in the cookie. - * @param {number|Date} [expires] Optional. Expiration time in seconds or a Date object. - * @param {string} [path] Optional. The path on the server in which the cookie will be available on. - * @param {string} [domain] Optional. The domain that the cookie is available to. - * @param {boolean} [secure] Optional. Whether the cookie should only be transmitted over a secure HTTPS connection. + * @param {string} name The name of the cookie. + * @param {Object} values_obj The values to store in the cookie. + * @param {number|Date} [expires] Optional. Expiration time in seconds or a Date object. + * @param {string} [path] Optional. The path on the server in which the cookie will be available on. + * @param {string} [domain] Optional. The domain that the cookie is available to. + * @param {boolean} [secure] Optional. Whether the cookie should only be transmitted over a secure HTTPS connection. */ setHash: function( name, values_obj, expires, path, domain, secure ) { var str = ''; diff --git a/src/js/_enqueues/lib/emoji-loader.js b/src/js/_enqueues/lib/emoji-loader.js index 86963a2a3af24..5bce5aa43a44e 100644 --- a/src/js/_enqueues/lib/emoji-loader.js +++ b/src/js/_enqueues/lib/emoji-loader.js @@ -57,7 +57,7 @@ function supportsWorkerOffloading() { /** * @typedef SessionSupportTests * @type {Object} - * @property {number} timestamp + * @property {number} timestamp * @property {SupportTests} supportTests */ @@ -128,8 +128,8 @@ function setSessionSupportTests( supportTests ) { * @private * * @param {CanvasRenderingContext2D} context 2D Context. - * @param {string} set1 Set of Emoji to test. - * @param {string} set2 Set of Emoji to test. + * @param {string} set1 Set of Emoji to test. + * @param {string} set2 Set of Emoji to test. * * @return {boolean} True if the two sets render the same. */ @@ -178,7 +178,7 @@ function emojiSetsRenderIdentically( context, set1, set2 ) { * @private * * @param {CanvasRenderingContext2D} context 2D Context. - * @param {string} emoji Emoji to test. + * @param {string} emoji Emoji to test. * * @return {boolean} True if the center point is empty. */ @@ -209,10 +209,10 @@ function emojiRendersEmptyCenterPoint( context, emoji ) { * * @private * - * @param {CanvasRenderingContext2D} context 2D Context. - * @param {string} type Whether to test for support of "flag" or "emoji". - * @param {Function} emojiSetsRenderIdentically Reference to emojiSetsRenderIdentically function, needed due to minification. - * @param {Function} emojiRendersEmptyCenterPoint Reference to emojiRendersEmptyCenterPoint function, needed due to minification. + * @param {CanvasRenderingContext2D} context 2D Context. + * @param {string} type Whether to test for support of "flag" or "emoji". + * @param {Function} emojiSetsRenderIdentically Reference to emojiSetsRenderIdentically function, needed due to minification. + * @param {Function} emojiRendersEmptyCenterPoint Reference to emojiRendersEmptyCenterPoint function, needed due to minification. * * @return {boolean} True if the browser can render emoji, false if it cannot. */ @@ -302,9 +302,9 @@ function browserSupportsEmoji( context, type, emojiSetsRenderIdentically, emojiR * * @private * - * @param {string[]} tests Tests. - * @param {Function} browserSupportsEmoji Reference to browserSupportsEmoji function, needed due to minification. - * @param {Function} emojiSetsRenderIdentically Reference to emojiSetsRenderIdentically function, needed due to minification. + * @param {string[]} tests Tests. + * @param {Function} browserSupportsEmoji Reference to browserSupportsEmoji function, needed due to minification. + * @param {Function} emojiSetsRenderIdentically Reference to emojiSetsRenderIdentically function, needed due to minification. * @param {Function} emojiRendersEmptyCenterPoint Reference to emojiRendersEmptyCenterPoint function, needed due to minification. * * @return {SupportTests} Support tests. diff --git a/src/js/_enqueues/lib/image-edit.js b/src/js/_enqueues/lib/image-edit.js index 0431551aeb615..3ddc6eded840e 100644 --- a/src/js/_enqueues/lib/image-edit.js +++ b/src/js/_enqueues/lib/image-edit.js @@ -307,8 +307,8 @@ * * @memberof imageEdit * - * @param {Event} event The key or click event. - * @param {HTMLElement} el The current element. + * @param {Event} event The key or click event. + * @param {HTMLElement} el The current element. * * @return {boolean} Always returns false. */ @@ -438,10 +438,10 @@ * * @memberof imageEdit * - * @param {number} postid The current post ID. - * @param {number} x Is 0 when it applies the y-axis - * and 1 when applicable for the x-axis. - * @param {jQuery} el Element. + * @param {number} postid The current post ID. + * @param {number} x Is 0 when it applies the y-axis + * and 1 when applicable for the x-axis. + * @param {jQuery} el Element. * * @return {void} */ @@ -732,8 +732,8 @@ * * @memberof imageEdit * - * @param {number} postid The post ID to get the image from the database. - * @param {string} nonce The nonce to verify the request. + * @param {number} postid The post ID to get the image from the database. + * @param {string} nonce The nonce to verify the request. * * @return {boolean|void} If the actions are successfully saved a response message is shown. * Returns false if there is no image editing history, @@ -801,9 +801,9 @@ * * @memberof imageEdit * - * @param {number} postid The post ID for the image. - * @param {string} nonce The nonce to verify the request. - * @param {Object} view The image editor view to be used for the editing. + * @param {number} postid The post ID for the image. + * @param {string} nonce The nonce to verify the request. + * @param {Object} view The image editor view to be used for the editing. * * @return {void|promise} Either returns void if the button was already activated * or returns an instance of the image editor, wrapped in a promise. @@ -1290,8 +1290,8 @@ * * @memberof imageEdit * - * @param {number} postid The post ID. - * @param {string} nonce The nonce. + * @param {number} postid The post ID. + * @param {string} nonce The nonce. * * @return {void|false} Returns false if the undo button is disabled. */ @@ -1448,9 +1448,9 @@ * * @memberof imageEdit * - * @param {number} postid The post ID. - * @param {number} n The ratio to set. - * @param {jQuery} el The element containing the values. + * @param {number} postid The post ID. + * @param {number} n The ratio to set. + * @param {jQuery} el The element containing the values. * * @return {void} */ diff --git a/src/js/_enqueues/lib/lists.js b/src/js/_enqueues/lib/lists.js index 44e71a84ed488..deb1814bf9214 100644 --- a/src/js/_enqueues/lib/lists.js +++ b/src/js/_enqueues/lib/lists.js @@ -226,7 +226,7 @@ wpList = { * data[2] - ID of the parent element of all inputs necessary for the request. * data[3] - Hex color to be used in this request. If data[0] is 'dim', dim class. * data[4] - Additional arguments in query syntax that are added to the request. Example: 'post_id=1234'. - * If data[0] is 'dim', dim add color. + * If data[0] is 'dim', dim add color. * data[5] - Only available if data[0] is 'dim', dim delete color. * data[6] - Only available if data[0] is 'dim', additional arguments in query syntax that are added to the request. * diff --git a/src/js/_enqueues/lib/pointer.js b/src/js/_enqueues/lib/pointer.js index d946d6c015121..7e63d0e009b53 100644 --- a/src/js/_enqueues/lib/pointer.js +++ b/src/js/_enqueues/lib/pointer.js @@ -74,7 +74,7 @@ * There are 4 special values that do something extra: * * - `document` will transfer the pointer to the body of the new document - * specified by the value. + * specified by the value. * - `pointerClass` will change the class of the pointer element. * - `position` will reposition the pointer. * - `content` will update the content of the pointer. diff --git a/src/js/_enqueues/lib/quicktags.js b/src/js/_enqueues/lib/quicktags.js index bdb978750e549..ffdbfaeef7349 100644 --- a/src/js/_enqueues/lib/quicktags.js +++ b/src/js/_enqueues/lib/quicktags.js @@ -333,12 +333,12 @@ window.edToolbar = function(){}; * use add_action( 'admin_print_footer_scripts', 'output_my_js', 100 ) or add_action( 'wp_footer', 'output_my_js', 100 ) * * Minimum required to add a button that calls an external function: - * QTags.addButton( 'my_id', 'my button', my_callback ); - * function my_callback() { alert('yeah!'); } + * QTags.addButton( 'my_id', 'my button', my_callback ); + * function my_callback() { alert('yeah!'); } * * Minimum required to add a button that inserts a tag: - * QTags.addButton( 'my_id', 'my button', '', '' ); - * QTags.addButton( 'my_id2', 'my button', '
    ' ); + * QTags.addButton( 'my_id', 'my button', '', '' ); + * QTags.addButton( 'my_id2', 'my button', '
    ' ); * * @param {string} id Required. Button HTML ID * @param {string} display Required. Button's value="..." diff --git a/src/js/_enqueues/lib/user-suggest.js b/src/js/_enqueues/lib/user-suggest.js index f05b7ffa8892f..fc58ac4ef0044 100644 --- a/src/js/_enqueues/lib/user-suggest.js +++ b/src/js/_enqueues/lib/user-suggest.js @@ -34,11 +34,11 @@ * * Optional data-attributes: * - data-autocomplete-type (add, search) - * The action that is going to be performed: search for existing users - * or add a new one. Default: add + * The action that is going to be performed: search for existing users + * or add a new one. Default: add * - data-autocomplete-field (user_login, user_email) - * The field that is returned as the value for the suggestion. - * Default: user_login + * The field that is returned as the value for the suggestion. + * Default: user_login * * @see wp-admin/includes/admin-actions.php:wp_ajax_autocomplete_user() */ diff --git a/src/js/_enqueues/wp/api.js b/src/js/_enqueues/wp/api.js index b15a74628a92c..c91558b20a200 100644 --- a/src/js/_enqueues/wp/api.js +++ b/src/js/_enqueues/wp/api.js @@ -206,8 +206,8 @@ /** * Extract a route part based on negative index. * - * @param {string} route The endpoint route. - * @param {number} part The number of parts from the end of the route to retrieve. Default 1. + * @param {string} route The endpoint route. + * @param {number} part The number of parts from the end of the route to retrieve. Default 1. * Example route `/a/b/c`: part 1 is `c`, part 2 is `b`, part 3 is `a`. * @param {string} [versionString] Version string, defaults to `wp.api.versionString`. * @param {boolean} [reverse] Whether to reverse the order when extracting the route part. Optional, default false. @@ -313,7 +313,7 @@ * * @param {Backbone Model} model The model to attach helpers and mixins to. * @param {string} modelClassName The classname of the constructed model. - * @param {Object} loadingObjects An object containing the models and collections we are building. + * @param {Object} loadingObjects An object containing the models and collections we are building. * @return {undefined} No return value. */ wp.api.utils.addMixinsAndHelpers = function( model, modelClassName, loadingObjects ) { @@ -858,9 +858,8 @@ initialize: function() { /** - * Types that don't support trashing require passing ?force=true to delete. - * - */ + * Types that don't support trashing require passing ?force=true to delete. + */ if ( -1 === _.indexOf( trashableTypes, this.name ) ) { this.requireForceForDelete = true; } diff --git a/src/js/_enqueues/wp/backbone.js b/src/js/_enqueues/wp/backbone.js index 4fd194f5737d5..2c8e62d23cca3 100644 --- a/src/js/_enqueues/wp/backbone.js +++ b/src/js/_enqueues/wp/backbone.js @@ -284,7 +284,7 @@ window.wp = window.wp || {}; * @since 3.5.0 * * @return {wp.Backbone.Subviews} The current Subviews instance. - */ + */ render: function() { var options = { ready: this._isReady() @@ -314,7 +314,7 @@ window.wp = window.wp || {}; * the master views' parent. * * @return {wp.Backbone.Subviews} The current Subviews instance. - */ + */ remove: function( options ) { if ( ! options || ! options.silent ) { if ( this.parent && this.parent.views ) @@ -338,7 +338,7 @@ window.wp = window.wp || {}; * @since 3.5.0 * * @param {string} $target Selector where to put the elements. - * @param {*} els HTML or elements to put into the selector's HTML. + * @param {*} els HTML or elements to put into the selector's HTML. * * @return {wp.Backbone.Subviews} The current Subviews instance. */ diff --git a/src/js/_enqueues/wp/code-editor.js b/src/js/_enqueues/wp/code-editor.js index a40a943fed4ad..18451a0a7881e 100644 --- a/src/js/_enqueues/wp/code-editor.js +++ b/src/js/_enqueues/wp/code-editor.js @@ -19,89 +19,89 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * @typedef {Object} CodeMirrorState - * @property {boolean} [completionActive] - Whether completion is active. - * @property {boolean} [focused] - Whether the editor is focused. + * @property {boolean} [completionActive] Whether completion is active. + * @property {boolean} [focused] Whether the editor is focused. */ /** * @typedef {import('codemirror').EditorFromTextArea & { - * options: import('codemirror').EditorConfiguration, - * performLint?: () => void, - * showHint?: (options: import('codemirror').ShowHintOptions) => void, - * state: CodeMirrorState + * options: import('codemirror').EditorConfiguration, + * performLint?: () => void, + * showHint?: (options: import('codemirror').ShowHintOptions) => void, + * state: CodeMirrorState * }} CodeMirrorEditor */ /** * @typedef {Object} LintAnnotation - * @property {string} message - Message. - * @property {'error'|'warning'} severity - Severity. - * @property {import('codemirror').Position} from - From position. - * @property {import('codemirror').Position} to - To position. + * @property {string} message Message. + * @property {'error'|'warning'} severity Severity. + * @property {import('codemirror').Position} from From position. + * @property {import('codemirror').Position} to To position. */ /** * @typedef {Object} CodeMirrorTokenState - * @property {Object} [htmlState] - HTML state. - * @property {string} [htmlState.tagName] - Tag name. - * @property {CodeMirrorTokenState} [curState] - Current state. + * @property {Object} [htmlState] HTML state. + * @property {string} [htmlState.tagName] Tag name. + * @property {CodeMirrorTokenState} [curState] Current state. */ /** * @typedef {import('codemirror').EditorConfiguration & { - * lint?: boolean | CombinedLintOptions, - * autoCloseBrackets?: boolean, - * matchBrackets?: boolean, - * continueComments?: boolean, - * styleActiveLine?: boolean + * lint?: boolean | CombinedLintOptions, + * autoCloseBrackets?: boolean, + * matchBrackets?: boolean, + * continueComments?: boolean, + * styleActiveLine?: boolean * }} CodeMirrorSettings */ /** * @typedef {Object} CSSLintRules - * @property {boolean} [errors] - Errors. - * @property {boolean} [box-model] - Box model rules. - * @property {boolean} [display-property-grouping] - Display property grouping rules. - * @property {boolean} [duplicate-properties] - Duplicate properties rules. - * @property {boolean} [known-properties] - Known properties rules. - * @property {boolean} [outline-none] - Outline none rules. + * @property {boolean} [errors] Errors. + * @property {boolean} [box-model] Box model rules. + * @property {boolean} [display-property-grouping] Display property grouping rules. + * @property {boolean} [duplicate-properties] Duplicate properties rules. + * @property {boolean} [known-properties] Known properties rules. + * @property {boolean} [outline-none] Outline none rules. */ /** * @typedef {Object} JSHintRules - * @property {number} [esversion] - ECMAScript version. - * @property {boolean} [module] - Whether to use modules. - * @property {boolean} [boss] - Whether to allow assignments in control expressions. - * @property {boolean} [curly] - Whether to require curly braces. - * @property {boolean} [eqeqeq] - Whether to require === and !==. - * @property {boolean} [eqnull] - Whether to allow == null. - * @property {boolean} [expr] - Whether to allow expressions. - * @property {boolean} [immed] - Whether to require immediate function invocation. - * @property {boolean} [noarg] - Whether to prohibit arguments.caller/callee. - * @property {boolean} [nonbsp] - Whether to prohibit non-breaking spaces. - * @property {string} [quotmark] - Quote mark preference. - * @property {boolean} [undef] - Whether to prohibit undefined variables. - * @property {boolean} [unused] - Whether to prohibit unused variables. - * @property {boolean} [browser] - Whether to enable browser globals. - * @property {Record} [globals] - Global variables. + * @property {number} [esversion] ECMAScript version. + * @property {boolean} [module] Whether to use modules. + * @property {boolean} [boss] Whether to allow assignments in control expressions. + * @property {boolean} [curly] Whether to require curly braces. + * @property {boolean} [eqeqeq] Whether to require === and !==. + * @property {boolean} [eqnull] Whether to allow == null. + * @property {boolean} [expr] Whether to allow expressions. + * @property {boolean} [immed] Whether to require immediate function invocation. + * @property {boolean} [noarg] Whether to prohibit arguments.caller/callee. + * @property {boolean} [nonbsp] Whether to prohibit non-breaking spaces. + * @property {string} [quotmark] Quote mark preference. + * @property {boolean} [undef] Whether to prohibit undefined variables. + * @property {boolean} [unused] Whether to prohibit unused variables. + * @property {boolean} [browser] Whether to enable browser globals. + * @property {Record} [globals] Global variables. */ /** * @typedef {Object} HTMLHintRules - * @property {boolean} [tagname-lowercase] - Tag name lowercase rules. - * @property {boolean} [attr-lowercase] - Attribute lowercase rules. - * @property {boolean} [attr-value-double-quotes] - Attribute value double quotes rules. - * @property {boolean} [doctype-first] - Doctype first rules. - * @property {boolean} [tag-pair] - Tag pair rules. - * @property {boolean} [spec-char-escape] - Spec char escape rules. - * @property {boolean} [id-unique] - ID unique rules. - * @property {boolean} [src-not-empty] - Src not empty rules. - * @property {boolean} [attr-no-duplication] - Attribute no duplication rules. - * @property {boolean} [alt-require] - Alt require rules. - * @property {string} [space-tab-mixed-disabled] - Space tab mixed disabled rules. - * @property {boolean} [attr-unsafe-chars] - Attribute unsafe chars rules. - * @property {JSHintRules} [jshint] - JSHint rules. - * @property {CSSLintRules} [csslint] - CSSLint rules. + * @property {boolean} [tagname-lowercase] Tag name lowercase rules. + * @property {boolean} [attr-lowercase] Attribute lowercase rules. + * @property {boolean} [attr-value-double-quotes] Attribute value double quotes rules. + * @property {boolean} [doctype-first] Doctype first rules. + * @property {boolean} [tag-pair] Tag pair rules. + * @property {boolean} [spec-char-escape] Spec char escape rules. + * @property {boolean} [id-unique] ID unique rules. + * @property {boolean} [src-not-empty] Src not empty rules. + * @property {boolean} [attr-no-duplication] Attribute no duplication rules. + * @property {boolean} [alt-require] Alt require rules. + * @property {string} [space-tab-mixed-disabled] Space tab mixed disabled rules. + * @property {boolean} [attr-unsafe-chars] Attribute unsafe chars rules. + * @property {JSHintRules} [jshint] JSHint rules. + * @property {CSSLintRules} [csslint] CSSLint rules. */ /** @@ -109,15 +109,15 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { * * @typedef {Object} CodeEditorSettings * - * @property {CodeMirrorSettings} [codemirror] - CodeMirror settings. - * @property {CSSLintRules} [csslint] - CSSLint rules. - * @property {JSHintRules} [jshint] - JSHint rules. - * @property {HTMLHintRules} [htmlhint] - HTMLHint rules. + * @property {CodeMirrorSettings} [codemirror] CodeMirror settings. + * @property {CSSLintRules} [csslint] CSSLint rules. + * @property {JSHintRules} [jshint] JSHint rules. + * @property {HTMLHintRules} [htmlhint] HTMLHint rules. * - * @property {(codemirror: CodeMirrorEditor, event: KeyboardEvent|JQuery.KeyDownEvent) => void} [onTabNext] - Callback to handle tabbing to the next tabbable element. - * @property {(codemirror: CodeMirrorEditor, event: KeyboardEvent|JQuery.KeyDownEvent) => void} [onTabPrevious] - Callback to handle tabbing to the previous tabbable element. - * @property {(errorAnnotations: LintAnnotation[], annotations: LintAnnotation[], annotationsSorted: LintAnnotation[], cm: CodeMirrorEditor) => void} [onChangeLintingErrors] - Callback for when the linting errors have changed. - * @property {(errorAnnotations: LintAnnotation[], editor: CodeMirrorEditor) => void} [onUpdateErrorNotice] - Callback for when error notice should be displayed. + * @property {(codemirror: CodeMirrorEditor, event: KeyboardEvent|JQuery.KeyDownEvent) => void} [onTabNext] Callback to handle tabbing to the next tabbable element. + * @property {(codemirror: CodeMirrorEditor, event: KeyboardEvent|JQuery.KeyDownEvent) => void} [onTabPrevious] Callback to handle tabbing to the previous tabbable element. + * @property {(errorAnnotations: LintAnnotation[], annotations: LintAnnotation[], annotationsSorted: LintAnnotation[], cm: CodeMirrorEditor) => void} [onChangeLintingErrors] Callback for when the linting errors have changed. + * @property {(errorAnnotations: LintAnnotation[], editor: CodeMirrorEditor) => void} [onUpdateErrorNotice] Callback for when error notice should be displayed. */ /** @@ -126,15 +126,15 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * @typedef {Object} CodeEditorInstance - * @property {CodeEditorSettings} settings - The code editor settings. - * @property {CodeMirrorEditor} codemirror - The CodeMirror instance. - * @property {() => void} updateErrorNotice - Force update the error notice. + * @property {CodeEditorSettings} settings The code editor settings. + * @property {CodeMirrorEditor} codemirror The CodeMirror instance. + * @property {() => void} updateErrorNotice Force update the error notice. */ /** * @typedef {Object} WpCodeEditor - * @property {CodeEditorSettings} defaultSettings - Default settings. - * @property {(textarea: string|JQuery|Element, settings?: CodeEditorSettings) => CodeEditorInstance} initialize - Initialize. + * @property {CodeEditorSettings} defaultSettings Default settings. + * @property {(textarea: string|JQuery|Element, settings?: CodeEditorSettings) => CodeEditorInstance} initialize Initialize. */ /** @@ -166,7 +166,7 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * Configures linting. * - * @param {CodeEditorSettings} settings - Code editor settings. + * @param {CodeEditorSettings} settings Code editor settings. * * @return {LintingController} Linting controller. */ @@ -180,7 +180,7 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * Call the onUpdateErrorNotice if there are new errors to show. * - * @param {import('codemirror').Editor} editor - Editor. + * @param {import('codemirror').Editor} editor Editor. * @return {void} */ function updateErrorNotice( editor ) { @@ -237,9 +237,9 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * Wraps the onUpdateLinting event to filter errors, detect state changes, and manage error notice visibility. * - * @param {LintAnnotation[]} annotations - Annotations. - * @param {LintAnnotation[]} annotationsSorted - Sorted annotations. - * @param {CodeMirrorEditor} cm - Editor. + * @param {LintAnnotation[]} annotations Annotations. + * @param {LintAnnotation[]} annotationsSorted Sorted annotations. + * @param {CodeMirrorEditor} cm Editor. */ return function( annotations, annotationsSorted, cm ) { const errorAnnotations = annotations.filter( function( annotation ) { @@ -281,7 +281,7 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * Initializes the CodeMirror editor. * - * @param {CodeMirrorEditor} editor - Editor instance. + * @param {CodeMirrorEditor} editor Editor instance. * @return {void} */ init: function( editor ) { @@ -349,7 +349,7 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { } ); }, /** - * @param {CodeMirrorEditor} editor - Editor instance. + * @param {CodeMirrorEditor} editor Editor instance. * @return {void} */ updateErrorNotice, @@ -359,8 +359,8 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * Configure tabbing. * - * @param {CodeMirrorEditor} codemirror - Editor. - * @param {CodeEditorSettings} settings - Code editor settings. + * @param {CodeMirrorEditor} codemirror Editor. + * @param {CodeEditorSettings} settings Code editor settings. * * @return {void} */ @@ -399,9 +399,9 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { /** * @typedef {Object} LintingController - * @property {() => CombinedLintOptions|false} getLintOptions - Get lint options. - * @property {(editor: CodeMirrorEditor) => void} init - Initialize. - * @property {(editor: import('codemirror').Editor) => void} updateErrorNotice - Update error notice. + * @property {() => CombinedLintOptions|false} getLintOptions Get lint options. + * @property {(editor: CodeMirrorEditor) => void} init Initialize. + * @property {(editor: import('codemirror').Editor) => void} updateErrorNotice Update error notice. */ /** @@ -409,8 +409,8 @@ if ( 'undefined' === typeof window.wp.codeEditor ) { * * @since 4.9.0 * - * @param {string|JQuery|HTMLElement} textarea - The HTML id, jQuery object, or DOM Element for the textarea that is used for the editor. - * @param {CodeEditorSettings} [settings] - Settings to override defaults. + * @param {string|JQuery|HTMLElement} textarea The HTML id, jQuery object, or DOM Element for the textarea that is used for the editor. + * @param {CodeEditorSettings} [settings] Settings to override defaults. * * @return {CodeEditorInstance} Instance. */ diff --git a/src/js/_enqueues/wp/custom-header.js b/src/js/_enqueues/wp/custom-header.js index 7d4fa98d7cc53..fccab2565b164 100644 --- a/src/js/_enqueues/wp/custom-header.js +++ b/src/js/_enqueues/wp/custom-header.js @@ -19,7 +19,7 @@ * Trigger an event. * * @param {Element} target HTML element to dispatch the event on. - * @param {string} name Event name. + * @param {string} name Event name. */ function trigger( target, name ) { var evt; diff --git a/src/js/_enqueues/wp/customize/base.js b/src/js/_enqueues/wp/customize/base.js index 2b694b9a021c1..44e23ae35740d 100644 --- a/src/js/_enqueues/wp/customize/base.js +++ b/src/js/_enqueues/wp/customize/base.js @@ -568,7 +568,7 @@ window.wp = window.wp || {}; * when( ids*, [callback] ); * * For example: - * when( id1, id2, id3, function( value1, value2, value3 ) {} ); + * when( id1, id2, id3, function( value1, value2, value3 ) {} ); * * @param {...(string|Function)} ids Zero or more IDs of items to wait for, optionally followed by * a callback function to invoke once they are all available. diff --git a/src/js/_enqueues/wp/customize/controls.js b/src/js/_enqueues/wp/customize/controls.js index 94693163c0240..64bfd3fe754be 100644 --- a/src/js/_enqueues/wp/customize/controls.js +++ b/src/js/_enqueues/wp/customize/controls.js @@ -3101,7 +3101,7 @@ api.ThemesPanel = api.Panel.extend(/** @lends wp.customize.ThemesPanel.prototype */{ /** - * Class wp.customize.ThemesPanel. + * Class wp.customize.ThemesPanel. * * Custom section for themes that displays without the customize preview. * diff --git a/src/js/_enqueues/wp/customize/loader.js b/src/js/_enqueues/wp/customize/loader.js index 152d5d48dc780..0f053f4c69505 100644 --- a/src/js/_enqueues/wp/customize/loader.js +++ b/src/js/_enqueues/wp/customize/loader.js @@ -33,7 +33,7 @@ window.wp = window.wp || {}; * By default, any element in the body with the load-customize class will open * an iframe overlay with the URL specified. * - * e.g. Open Customizer + * e.g. Open Customizer * * @memberOf wp.customize * diff --git a/src/js/_enqueues/wp/dashboard.js b/src/js/_enqueues/wp/dashboard.js index 595133d790782..1fbfdec57a508 100644 --- a/src/js/_enqueues/wp/dashboard.js +++ b/src/js/_enqueues/wp/dashboard.js @@ -67,7 +67,7 @@ jQuery( function($) { * @type {string[]} * * @global - */ + */ window.ajaxWidgets = ['dashboard_primary']; /** @@ -85,7 +85,7 @@ jQuery( function($) { /** * Fetch the latest representation of the widget via Ajax and show it. * - * @param {number} i Number of half-seconds to use as the timeout. + * @param {number} i Number of half-seconds to use as the timeout. * @param {string} id ID of the element which is going to be checked for changes. * * @return {void} @@ -163,7 +163,7 @@ jQuery( function($) { * Highlights the latest post for one second. * * @return {void} - */ + */ function highlightLatestPost () { var latestPost = $( '.drafts ul li' ) .first(), errorNotice = $( '#quick-press .notice-error' ); @@ -835,7 +835,7 @@ jQuery( function( $ ) { * @deprecated 5.6.0 * * @type {Object} -*/ + */ window.communityEventsData.l10n = window.communityEventsData.l10n || { enter_closest_city: '', error_occurred_please_try_again: '', diff --git a/src/js/_enqueues/wp/editor/base.js b/src/js/_enqueues/wp/editor/base.js index 0c3485ca7d661..d7618acdafe3d 100644 --- a/src/js/_enqueues/wp/editor/base.js +++ b/src/js/_enqueues/wp/editor/base.js @@ -78,7 +78,7 @@ window.wp = window.wp || {}; * * @memberof switchEditors * - * @param {string} id The id of the editor you want to change the editor mode for. Default: `content`. + * @param {string} id The id of the editor you want to change the editor mode for. Default: `content`. * @param {string} mode The mode you want to switch to. Default: `toggle`. * @return {void} */ @@ -201,7 +201,7 @@ window.wp = window.wp || {}; * the tag type, if it is a closing tag and check if the HTML tag is inside a shortcode tag, * e.g. `[caption]..`. * - * @param {string} content The test content where the cursor is. + * @param {string} content The test content where the cursor is. * @param {number} cursorPosition The cursor position inside the content. * * @return {(null|Object)} Null if cursor is not in a tag, Object if the cursor is inside a tag. @@ -246,8 +246,8 @@ window.wp = window.wp || {}; * Moving the selection to before or after the short code is better, since it allows to select * something, instead of just losing focus and going to the start of the content. * - * @param {string} content The text content to check against. - * @param {number} cursorPosition The cursor position to check. + * @param {string} content The text content to check against. + * @param {number} cursorPosition The cursor position to check. * * @return {void|Object} Undefined if the cursor is not wrapped in a shortcode tag. * Information about the wrapping shortcode tag if it's wrapped in one. @@ -372,7 +372,7 @@ window.wp = window.wp || {}; * * Using DomQuery syntax to create it, since it's used as both text and as a DOM element. * - * @param {Object} domLib DOM library instance. + * @param {Object} domLib DOM library instance. * @param {string} content The content to insert into the cursor marker element. * @return {Object} The cursor marker element. */ @@ -395,7 +395,7 @@ window.wp = window.wp || {}; * * @link getShortcodeWrapperInfo * - * @param {string} content Textarea content that the cursors are in + * @param {string} content Textarea content that the cursors are in * @param {{cursorStart: number, cursorEnd: number}} cursorPositions Cursor start and end positions * * @return {{cursorStart: number, cursorEnd: number}} Adjusted cursor positions with `cursorStart` and `cursorEnd` properties. @@ -585,7 +585,7 @@ window.wp = window.wp || {}; * I order to achieve the proper positioning, the editor media bar and toolbar are subtracted * from the window height, to get the proper viewport window, that the user sees. * - * @param {Object} editor TinyMCE editor instance. + * @param {Object} editor TinyMCE editor instance. * @param {Object} element HTMLElement that should be scrolled into view. */ function scrollVisualModeToStartElement( editor, element ) { @@ -825,7 +825,7 @@ window.wp = window.wp || {}; * For `selection` parameter: * @link findBookmarkedPosition * - * @param {Object} editor TinyMCE's editor instance. + * @param {Object} editor TinyMCE's editor instance. * @param {Object} selection Selection data. */ function selectTextInTextArea( editor, selection ) { @@ -1224,9 +1224,27 @@ window.wp = window.wp || {}; * * @since 4.8.0 * - * @param {string} id The HTML id of the textarea that is used for the editor. - * Has to be jQuery compliant. No brackets, special chars, etc. - * @param {Object} settings Example: + * @param {string} id The HTML id of the textarea that is used for the editor. + * Has to be jQuery compliant. No brackets, special chars, etc. + * @param {Object} settings The settings for initializing the editor. + * + * @example + * ```javascript + * settings = { + * // See https://www.tinymce.com/docs/configure/integration-and-setup/. + * // Alternatively set to `true` to use the defaults. + * tinymce: { + * setup: function( editor ) { + * console.log( 'Editor initialized', editor ); + * } + * } + * + * // Alternatively set to `true` to use the defaults. + * quicktags: { + * buttons: 'strong,em,link' + * } + * } + * * settings = { * // See https://www.tinymce.com/docs/configure/integration-and-setup/. * // Alternatively set to `true` to use the defaults. @@ -1241,6 +1259,7 @@ window.wp = window.wp || {}; * buttons: 'strong,em,link' * } * } + * ``` */ wp.editor.initialize = function( id, settings ) { var init; diff --git a/src/js/_enqueues/wp/editor/dfw.js b/src/js/_enqueues/wp/editor/dfw.js index d6a563e8f7872..ff640ca9dd121 100644 --- a/src/js/_enqueues/wp/editor/dfw.js +++ b/src/js/_enqueues/wp/editor/dfw.js @@ -173,7 +173,7 @@ * * @since 4.0.0 * - * @param {event} event The TinyMCE editor init event. + * @param {event} event The TinyMCE editor init event. * @param {Object} editor The editor to bind the vents on. * * @return {void} @@ -1473,7 +1473,7 @@ * * @since 4.1.0 * - * @param {event} event The TinyMCE editor setup event. + * @param {event} event The TinyMCE editor setup event. * @param {Object} editor The editor to add the button to. * * @return {void} @@ -1522,7 +1522,7 @@ * * @since 4.1.0 * - * @param {event} event The TinyMCE editor init event. + * @param {event} event The TinyMCE editor init event. * @param {Object} editor The editor to bind events on. * * @return {void} @@ -1581,11 +1581,11 @@ } ); /** - * Binds events on quicktags init. + * Binds events on quicktags init. * * @since 4.1.0 * - * @param {event} event The quicktags init event. + * @param {event} event The quicktags init event. * @param {Object} editor The editor to bind events on. * * @return {void} diff --git a/src/js/_enqueues/wp/embed.js b/src/js/_enqueues/wp/embed.js index 5522fb824a38c..1f34177c3362f 100644 --- a/src/js/_enqueues/wp/embed.js +++ b/src/js/_enqueues/wp/embed.js @@ -1,7 +1,7 @@ /** * WordPress inline HTML embed * - * @param {Window} window The global window object. + * @param {Window} window The global window object. * @param {Document} document The global document object. * @since 4.4.0 * @output wp-includes/js/wp-embed.js diff --git a/src/js/_enqueues/wp/emoji.js b/src/js/_enqueues/wp/emoji.js index 1c134e2dfef85..274868f52d859 100644 --- a/src/js/_enqueues/wp/emoji.js +++ b/src/js/_enqueues/wp/emoji.js @@ -2,7 +2,7 @@ * wp-emoji.js is used to replace emoji with images in browsers when the browser * doesn't support emoji natively. * - * @param {Window} window The global window object. + * @param {Window} window The global window object. * @param {Object} settings The settings object. * @output wp-includes/js/wp-emoji.js */ @@ -190,7 +190,7 @@ * * - When passed an element the emoji characters are replaced inline. * - When passed a string the emoji characters are replaced and the result is - * returned. + * returned. * * @since 4.2.0 * diff --git a/src/js/_enqueues/wp/heartbeat.js b/src/js/_enqueues/wp/heartbeat.js index e816959bda1bf..6f89e1db47b6c 100644 --- a/src/js/_enqueues/wp/heartbeat.js +++ b/src/js/_enqueues/wp/heartbeat.js @@ -790,12 +790,17 @@ /** * Enqueues data to send with the next XHR. * - * As the data is send asynchronously, this function doesn't return the XHR + * As the data is sent asynchronously, this function doesn't return the XHR * response. To see the response, use the custom jQuery event 'heartbeat-tick' - * on the document, example: + * on the document. + * + * @example + * ```javascript * $(document).on( 'heartbeat-tick.myname', function( event, data, textStatus, jqXHR ) { * // code * }); + * ``` + * * If the same 'handle' is used more than once, the data is not overwritten when * the third argument is 'true'. Use `wp.heartbeat.isQueued('handle')` to see if * any data is already queued for that handle. diff --git a/src/js/_enqueues/wp/media/audiovideo.js b/src/js/_enqueues/wp/media/audiovideo.js index 485a1699726bf..d330831c490eb 100644 --- a/src/js/_enqueues/wp/media/audiovideo.js +++ b/src/js/_enqueues/wp/media/audiovideo.js @@ -197,8 +197,8 @@ wp.media.audio = { /** * Shortcode modeling for video. * - * `edit()` prepares the shortcode for the media modal. - * `shortcode()` builds the new shortcode after update. + * `edit()` prepares the shortcode for the media modal. + * `shortcode()` builds the new shortcode after update. * * @since 4.2.0 * diff --git a/src/js/_enqueues/wp/media/editor.js b/src/js/_enqueues/wp/media/editor.js index b6357520db557..3c0678c38e6d6 100644 --- a/src/js/_enqueues/wp/media/editor.js +++ b/src/js/_enqueues/wp/media/editor.js @@ -20,11 +20,11 @@ /** * A helper mixin function to avoid truthy and falsey values being - * passed as an input that expects booleans. If key is undefined in the map, - * but has a default value, set it. + * passed as an input that expects booleans. If key is undefined in the map, + * but has a default value, set it. * * @param {Object} attrs Map of props from a shortcode or settings. - * @param {string} key The key within the passed map to check for a value. + * @param {string} key The key within the passed map to check for a value. * @return {mixed|undefined} The original or coerced value of key within attrs. */ wp.media.coerce = function ( attrs, key ) { @@ -111,7 +111,7 @@ /** * Create link markup that is suitable for passing to the editor * - * @param {Object} props Attachment details (align, link, size, etc). + * @param {Object} props Attachment details (align, link, size, etc). * @param {Object} attachment The attachment object, media version of Post. * @return {string} The link markup */ @@ -137,7 +137,7 @@ /** * Create an Audio shortcode string that is suitable for passing to the editor * - * @param {Object} props Attachment details (align, link, size, etc). + * @param {Object} props Attachment details (align, link, size, etc). * @param {Object} attachment The attachment object, media version of Post. * @return {string} The audio shortcode */ @@ -147,7 +147,7 @@ /** * Create a Video shortcode string that is suitable for passing to the editor * - * @param {Object} props Attachment details (align, link, size, etc). + * @param {Object} props Attachment details (align, link, size, etc). * @param {Object} attachment The attachment object, media version of Post. * @return {string} The video shortcode */ @@ -159,8 +159,8 @@ * * @access private * - * @param {string} type The shortcode tag name: 'audio' or 'video'. - * @param {Object} props Attachment details (align, link, size, etc). + * @param {string} type The shortcode tag name: 'audio' or 'video'. + * @param {Object} props Attachment details (align, link, size, etc). * @param {Object} attachment The attachment object, media version of Post. * @return {string} The media shortcode */ @@ -206,9 +206,9 @@ }, /** * Create image markup, optionally with a link and/or wrapped in a caption shortcode, - * that is suitable for passing to the editor + * that is suitable for passing to the editor * - * @param {Object} props Attachment details (align, link, size, etc). + * @param {Object} props Attachment details (align, link, size, etc). * @param {Object} attachment The attachment object, media version of Post. * @return {string} The image markup. */ @@ -418,9 +418,9 @@ * Triggered when clicking 'Insert {label}' or 'Update {label}' * * @param {wp.media.model.Attachments} attachments A Backbone.Collection containing - * the media items belonging to a collection. - * The query[ this.tag ] property is a Backbone.Model - * containing the 'props' for the collection. + * the media items belonging to a collection. + * The query[ this.tag ] property is a Backbone.Model + * containing the 'props' for the collection. * @return {wp.shortcode} A wp.shortcode instance representing the collection. */ shortcode: function( attachments ) { @@ -485,10 +485,10 @@ }, /** * Triggered when double-clicking a collection shortcode placeholder - * in the editor + * in the editor * * @param {string} content Content that is searched for possible - * shortcode markup matching the passed tag name, + * shortcode markup matching the passed tag name, * * @this wp.media.{prop} * @@ -689,7 +689,7 @@ }, /** * 'select' callback for Featured Image workflow, triggered when - * the 'Set Featured Image' button is clicked in the media modal. + * the 'Set Featured Image' button is clicked in the media modal. * * @this wp.media.controller.FeaturedImage */ @@ -784,7 +784,7 @@ /** * Setup 'workflow' and add to the 'workflows' cache. 'open' can - * subsequently be called upon it. + * subsequently be called upon it. * * @param {string} id A slug used to identify the workflow. * @param {Object} [options={}] The options for the media workflow. @@ -943,9 +943,9 @@ send: { /** * Called when sending an attachment to the editor - * from the medial modal. + * from the medial modal. * - * @param {Object} props Attachment details (align, link, size, etc). + * @param {Object} props Attachment details (align, link, size, etc). * @param {Object} attachment The attachment object, media version of Post. * @return {Promise} A promise that resolves when the attachment has been sent to the editor. */ diff --git a/src/js/_enqueues/wp/password-strength-meter.js b/src/js/_enqueues/wp/password-strength-meter.js index 6aba8749adffa..3ed6d48d5ef25 100644 --- a/src/js/_enqueues/wp/password-strength-meter.js +++ b/src/js/_enqueues/wp/password-strength-meter.js @@ -26,10 +26,10 @@ window.wp = window.wp || {}; * * @since 3.7.0 * - * @param {string} password1 The subject password. + * @param {string} password1 The subject password. * @param {Array} disallowedList An array of words that will lower the entropy of - * the password. - * @param {string} password2 The password confirmation. + * the password. + * @param {string} password2 The password confirmation. * * @return {number} The password strength score. */ diff --git a/src/js/_enqueues/wp/sanitize.js b/src/js/_enqueues/wp/sanitize.js index c5c97f6c37564..f67a8fd25a97f 100644 --- a/src/js/_enqueues/wp/sanitize.js +++ b/src/js/_enqueues/wp/sanitize.js @@ -19,7 +19,7 @@ /** * Strip HTML tags. * - * @param {string} text - Text to strip the HTML tags from. + * @param {string} text Text to strip the HTML tags from. * * @return {string} Stripped text. */ @@ -52,7 +52,7 @@ /** * Strip HTML tags and convert HTML entities. * - * @param {string} text - Text to strip tags and convert HTML entities. + * @param {string} text Text to strip tags and convert HTML entities. * * @return {string} Sanitized text. */ diff --git a/src/js/_enqueues/wp/theme-plugin-editor.js b/src/js/_enqueues/wp/theme-plugin-editor.js index 74e0634f94e45..72a4471a93994 100644 --- a/src/js/_enqueues/wp/theme-plugin-editor.js +++ b/src/js/_enqueues/wp/theme-plugin-editor.js @@ -29,9 +29,9 @@ wp.themePluginEditor = (function( $ ) { * * @since 4.9.0 * - * @param {jQuery} form - Form element. - * @param {Object} settings - Settings. - * @param {Object|boolean} settings.codeEditor - Code editor settings (or `false` if syntax highlighting is disabled). + * @param {jQuery} form Form element. + * @param {Object} settings Settings. + * @param {Object|boolean} settings.codeEditor Code editor settings (or `false` if syntax highlighting is disabled). * @return {void} */ component.init = function init( form, settings ) { @@ -187,7 +187,7 @@ wp.themePluginEditor = (function( $ ) { * Submit file via Ajax. * * @since 4.9.0 - * @param {jQuery.Event} event - Event. + * @param {jQuery.Event} event Event. * @return {void} */ component.submit = function( event ) { @@ -273,12 +273,12 @@ wp.themePluginEditor = (function( $ ) { * * @since 4.9.0 * - * @param {Object} notice - Notice. - * @param {string} notice.code - Code. - * @param {string} notice.type - Type. - * @param {string} notice.message - Message. - * @param {boolean} [notice.dismissible=false] - Dismissible. - * @param {Function} [notice.onDismiss] - Callback for when a user dismisses the notice. + * @param {Object} notice Notice. + * @param {string} notice.code Code. + * @param {string} notice.type Type. + * @param {string} notice.message Message. + * @param {boolean} [notice.dismissible=false] Dismissible. + * @param {Function} [notice.onDismiss] Callback for when a user dismisses the notice. * @return {jQuery} Notice element. */ component.addNotice = function( notice ) { @@ -314,7 +314,7 @@ wp.themePluginEditor = (function( $ ) { * * @since 4.9.0 * - * @param {string} code - Notice code. + * @param {string} code Notice code. * @return {boolean} Whether a notice was removed. */ component.removeNotice = function( code ) { @@ -366,7 +366,7 @@ wp.themePluginEditor = (function( $ ) { * * @since 4.9.0 * - * @param {Array} errors - List of linting errors. + * @param {Array} errors List of linting errors. * @return {void} */ codeEditorSettings.onChangeLintingErrors = function( errors ) { @@ -383,7 +383,7 @@ wp.themePluginEditor = (function( $ ) { * * @since 4.9.0 * - * @param {Array} errorAnnotations - Error annotations. + * @param {Array} errorAnnotations Error annotations. * @return {void} */ codeEditorSettings.onUpdateErrorNotice = function onUpdateErrorNotice( errorAnnotations ) { @@ -491,26 +491,24 @@ wp.themePluginEditor = (function( $ ) { */ var TreeitemLink = (function () { /** - * This content is licensed according to the W3C Software License at - * https://www.w3.org/Consortium/Legal/2015/copyright-software-and-document + * This content is licensed according to the W3C Software License at + * https://www.w3.org/Consortium/Legal/2015/copyright-software-and-document * - * File: TreeitemLink.js + * File: TreeitemLink.js * - * Desc: Treeitem widget that implements ARIA Authoring Practices - * for a tree being used as a file viewer + * Desc: Treeitem widget that implements ARIA Authoring Practices + * for a tree being used as a file viewer * - * Author: Jon Gunderson, Ku Ja Eun and Nicholas Hoyt + * Author: Jon Gunderson, Ku Ja Eun and Nicholas Hoyt */ /** - * @class + * @class * - * @description - * Treeitem object for representing the state and user interactions for a - * treeItem widget + * Treeitem object for representing the state and user interactions for a + * treeItem widget * - * @param node - * An element with the role=tree attribute + * @param node An element with the role=tree attribute */ var TreeitemLink = function (node, treeObj, group) { diff --git a/src/js/_enqueues/wp/theme.js b/src/js/_enqueues/wp/theme.js index 2249495ea4d1b..396fd4e3c9c41 100644 --- a/src/js/_enqueues/wp/theme.js +++ b/src/js/_enqueues/wp/theme.js @@ -1485,8 +1485,8 @@ themes.view.Search = wp.Backbone.View.extend({ * * @since 4.9.0 * - * @param {string} url - URL to navigate to. - * @param {Object} state - State. + * @param {string} url URL to navigate to. + * @param {Object} state State. * @return {void} */ function navigateRouter( url, state ) { diff --git a/src/js/_enqueues/wp/updates.js b/src/js/_enqueues/wp/updates.js index 7c971f4bb7d80..635a32975db48 100644 --- a/src/js/_enqueues/wp/updates.js +++ b/src/js/_enqueues/wp/updates.js @@ -1115,10 +1115,10 @@ * * @since 6.5.0 * - * @param {Object} response Response from the server. - * @param {string} response.slug Slug of the activated plugin. - * @param {string} response.pluginName Name of the activated plugin. - * @param {string} response.plugin The plugin file, relative to the plugins directory. + * @param {Object} response Response from the server. + * @param {string} response.slug Slug of the activated plugin. + * @param {string} response.pluginName Name of the activated plugin. + * @param {string} response.plugin The plugin file, relative to the plugins directory. */ wp.updates.activatePluginSuccess = function( response ) { var $message = $( '.plugin-card-' + response.slug + ', #plugin-information-footer' ).find( '.activating-message' ), diff --git a/src/js/_enqueues/wp/utils/word-count.js b/src/js/_enqueues/wp/utils/word-count.js index 066fc5817b491..4c336582ecf63 100644 --- a/src/js/_enqueues/wp/utils/word-count.js +++ b/src/js/_enqueues/wp/utils/word-count.js @@ -148,8 +148,8 @@ * * @memberof wp.utils.wordcounter * - * @param {string} text Text to count elements in. - * @param {string} type Optional. Specify type to use. + * @param {string} text Text to count elements in. + * @param {string} type Optional. Specify type to use. * * @return {number} The number of items counted. */ diff --git a/src/js/_enqueues/wp/widgets/custom-html.js b/src/js/_enqueues/wp/widgets/custom-html.js index 984233ecddfcb..73faf12af61da 100644 --- a/src/js/_enqueues/wp/widgets/custom-html.js +++ b/src/js/_enqueues/wp/widgets/custom-html.js @@ -42,9 +42,9 @@ wp.customHtmlWidgets = ( function( $ ) { * @augments Backbone.View * @abstract * - * @param {Object} options - Options. - * @param {jQuery} options.el - Control field container element. - * @param {jQuery} options.syncContainer - Container element where fields are synced for the server. + * @param {Object} options Options. + * @param {jQuery} options.el Control field container element. + * @param {jQuery} options.syncContainer Container element where fields are synced for the server. * * @return {void} */ @@ -124,7 +124,7 @@ wp.customHtmlWidgets = ( function( $ ) { /** * Show linting error notice. * - * @param {Array} errorAnnotations - Error annotations. + * @param {Array} errorAnnotations Error annotations. * @return {void} */ updateErrorNotice: function( errorAnnotations ) { @@ -205,7 +205,7 @@ wp.customHtmlWidgets = ( function( $ ) { * * @ignore * - * @param {Array} errorAnnotations - Error notifications. + * @param {Array} errorAnnotations Error notifications. * @return {void} */ onChangeLintingErrors: function onChangeLintingErrors( errorAnnotations ) { @@ -217,7 +217,7 @@ wp.customHtmlWidgets = ( function( $ ) { * * @ignore * - * @param {Array} errorAnnotations - Error annotations. + * @param {Array} errorAnnotations Error annotations. * @return {void} */ onUpdateErrorNotice: function onUpdateErrorNotice( errorAnnotations ) { @@ -287,8 +287,8 @@ wp.customHtmlWidgets = ( function( $ ) { * * @alias wp.customHtmlWidgets.handleWidgetAdded * - * @param {jQuery.Event} event - Event. - * @param {jQuery} widgetContainer - Widget container element. + * @param {jQuery.Event} event Event. + * @param {jQuery} widgetContainer Widget container element. * * @return {void} */ @@ -384,8 +384,8 @@ wp.customHtmlWidgets = ( function( $ ) { * * @alias wp.customHtmlWidgets.handleWidgetUpdated * - * @param {jQuery.Event} event - Event. - * @param {jQuery} widgetContainer - Widget container element. + * @param {jQuery.Event} event Event. + * @param {jQuery} widgetContainer Widget container element. * @return {void} */ component.handleWidgetUpdated = function handleWidgetUpdated( event, widgetContainer ) { @@ -415,7 +415,7 @@ wp.customHtmlWidgets = ( function( $ ) { * * @alias wp.customHtmlWidgets.init * - * @param {Object} settings - Options for code editor, exported from PHP. + * @param {Object} settings Options for code editor, exported from PHP. * * @return {void} */ diff --git a/src/js/_enqueues/wp/widgets/media-audio.js b/src/js/_enqueues/wp/widgets/media-audio.js index a57925364da70..ea85263298ed4 100644 --- a/src/js/_enqueues/wp/widgets/media-audio.js +++ b/src/js/_enqueues/wp/widgets/media-audio.js @@ -69,7 +69,7 @@ /** * Map model props to media frame props. * - * @param {Object} modelProps - Model props. + * @param {Object} modelProps Model props. * @return {Object} Media frame props. */ mapModelToMediaFrameProps: function mapModelToMediaFrameProps( modelProps ) { diff --git a/src/js/_enqueues/wp/widgets/media-gallery.js b/src/js/_enqueues/wp/widgets/media-gallery.js index 497fecd0fbd42..fe9f93cb381db 100644 --- a/src/js/_enqueues/wp/widgets/media-gallery.js +++ b/src/js/_enqueues/wp/widgets/media-gallery.js @@ -84,10 +84,10 @@ * @augments wp.mediaWidgets.MediaWidgetControl * * @since 4.9.0 - * @param {Object} options - Options. - * @param {Backbone.Model} options.model - Model. - * @param {jQuery} options.el - Control field container element. - * @param {jQuery} options.syncContainer - Container element where fields are synced for the server. + * @param {Object} options Options. + * @param {Backbone.Model} options.model Model. + * @param {jQuery} options.el Control field container element. + * @param {jQuery} options.syncContainer Container element where fields are synced for the server. * @return {void} */ initialize: function initialize( options ) { @@ -320,7 +320,7 @@ * Clear the selected attachment when it is deleted in the media select frame. * * @since 4.9.0 - * @param {wp.media.models.Attachment} attachment - Attachment. + * @param {wp.media.models.Attachment} attachment Attachment. * @return {void} */ handleAttachmentDestroy: function handleAttachmentDestroy( attachment ) { diff --git a/src/js/_enqueues/wp/widgets/media-image.js b/src/js/_enqueues/wp/widgets/media-image.js index c16600c022c2f..ff0b996d275ad 100644 --- a/src/js/_enqueues/wp/widgets/media-image.js +++ b/src/js/_enqueues/wp/widgets/media-image.js @@ -137,7 +137,7 @@ * * Prevent the image_title attribute from being initially set when adding an image from the media library. * - * @param {wp.media.view.MediaFrame.Select} mediaFrame - Select frame. + * @param {wp.media.view.MediaFrame.Select} mediaFrame Select frame. * @return {Object} Props. */ getModelPropsFromMediaFrame: function getModelPropsFromMediaFrame( mediaFrame ) { diff --git a/src/js/_enqueues/wp/widgets/media-video.js b/src/js/_enqueues/wp/widgets/media-video.js index 56a8ff1f3d5a4..180797f0ae291 100644 --- a/src/js/_enqueues/wp/widgets/media-video.js +++ b/src/js/_enqueues/wp/widgets/media-video.js @@ -87,7 +87,7 @@ /** * Map model props to media frame props. * - * @param {Object} modelProps - Model props. + * @param {Object} modelProps Model props. * @return {Object} Media frame props. */ mapModelToMediaFrameProps: function mapModelToMediaFrameProps( modelProps ) { diff --git a/src/js/_enqueues/wp/widgets/media.js b/src/js/_enqueues/wp/widgets/media.js index 66ec8e4306554..5d339308c5881 100644 --- a/src/js/_enqueues/wp/widgets/media.js +++ b/src/js/_enqueues/wp/widgets/media.js @@ -45,7 +45,7 @@ wp.mediaWidgets = ( function( $ ) { * @constructs wp.mediaWidgets.PersistentDisplaySettingsLibrary * @augments wp.media.controller.Library * - * @param {Object} options - Options. + * @param {Object} options Options. * * @return {void} */ @@ -57,7 +57,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Sync changes to the current display settings back into the current customized. * - * @param {Backbone.Model} displaySettings - Modified display settings. + * @param {Backbone.Model} displaySettings Modified display settings. * @return {void} */ handleDisplaySettingChange: function handleDisplaySettingChange( displaySettings ) { @@ -72,7 +72,7 @@ wp.mediaWidgets = ( function( $ ) { * will sync back into the model storing the session's customized display * settings. * - * @param {Backbone.Model} model - Display settings model. + * @param {Backbone.Model} model Display settings model. * @return {Backbone.Model} Display settings model. */ display: function getDisplaySettingsModel( model ) { @@ -102,7 +102,7 @@ wp.mediaWidgets = ( function( $ ) { * * @since 4.9.0 * - * @param {Object} options - Options. + * @param {Object} options Options. * @return {void} */ initialize: function( options ) { @@ -137,7 +137,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Set the disabled state on the Add to Widget button. * - * @param {boolean} disabled - Disabled. + * @param {boolean} disabled Disabled. * @return {void} */ setAddToWidgetButtonDisabled: function setAddToWidgetButtonDisabled( disabled ) { @@ -147,7 +147,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Set or clear an error notice. * - * @param {string} notice - Notice. + * @param {string} notice Notice. * @return {void} */ setErrorNotice: function setErrorNotice( notice ) { @@ -358,7 +358,7 @@ wp.mediaWidgets = ( function( $ ) { * * Forked override of {wp.media.view.MediaFrame.Post#mainInsertToolbar()} to override text. * - * @param {wp.Backbone.View} view - Toolbar view. + * @param {wp.Backbone.View} view Toolbar view. * @this {wp.media.controller.Library} * @return {void} */ @@ -393,7 +393,7 @@ wp.mediaWidgets = ( function( $ ) { * * Forked override of {wp.media.view.MediaFrame.Post#mainEmbedToolbar()} to override text. * - * @param {wp.Backbone.View} toolbar - Toolbar view. + * @param {wp.Backbone.View} toolbar Toolbar view. * @this {wp.media.controller.Library} * @return {void} */ @@ -486,10 +486,10 @@ wp.mediaWidgets = ( function( $ ) { * @augments Backbone.View * @abstract * - * @param {Object} options - Options. - * @param {Backbone.Model} options.model - Model. - * @param {jQuery} options.el - Control field container element. - * @param {jQuery} options.syncContainer - Container element where fields are synced for the server. + * @param {Object} options Options. + * @param {Backbone.Model} options.model Model. + * @param {jQuery} options.el Control field container element. + * @param {jQuery} options.syncContainer Container element where fields are synced for the server. * * @return {void} */ @@ -721,7 +721,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Handle click on link to Media Library to open modal, such as the link that appears when in the missing attachment error notice. * - * @param {jQuery.Event} event - Event. + * @param {jQuery.Event} event Event. * @return {void} */ handleMediaLibraryLinkClick: function handleMediaLibraryLinkClick( event ) { @@ -819,7 +819,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Get the instance props from the media selection frame. * - * @param {wp.media.view.MediaFrame.Select} mediaFrame - Select frame. + * @param {wp.media.view.MediaFrame.Select} mediaFrame Select frame. * @return {Object} Props. */ getModelPropsFromMediaFrame: function getModelPropsFromMediaFrame( mediaFrame ) { @@ -868,7 +868,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Map media frame props to model props. * - * @param {Object} mediaFrameProps - Media frame props. + * @param {Object} mediaFrameProps Media frame props. * @return {Object} Model props. */ mapMediaToModelProps: function mapMediaToModelProps( mediaFrameProps ) { @@ -919,7 +919,7 @@ wp.mediaWidgets = ( function( $ ) { /** * Map model props to media frame props. * - * @param {Object} modelProps - Model props. + * @param {Object} modelProps Model props. * @return {Object} Media frame props. */ mapModelToMediaFrameProps: function mapModelToMediaFrameProps( modelProps ) { @@ -1028,9 +1028,9 @@ wp.mediaWidgets = ( function( $ ) { * cast the attribute values from the hidden inputs' string values into * the appropriate data types (integers or booleans). * - * @param {string|Object} key - Attribute name or attribute pairs. - * @param {mixed|Object} [val] - Attribute value or options object. - * @param {Object} [options] - Options when attribute name and value are passed separately. + * @param {string|Object} key Attribute name or attribute pairs. + * @param {mixed|Object} [val] Attribute value or options object. + * @param {Object} [options] Options when attribute name and value are passed separately. * @return {wp.mediaWidgets.MediaWidgetModel} This model. */ set: function set( key, val, options ) { @@ -1119,8 +1119,8 @@ wp.mediaWidgets = ( function( $ ) { * * @memberOf wp.mediaWidgets * - * @param {jQuery.Event} event - Event. - * @param {jQuery} widgetContainer - Widget container element. + * @param {jQuery.Event} event Event. + * @param {jQuery} widgetContainer Widget container element. * * @return {void} */ @@ -1256,8 +1256,8 @@ wp.mediaWidgets = ( function( $ ) { * * @memberOf wp.mediaWidgets * - * @param {jQuery.Event} event - Event. - * @param {jQuery} widgetContainer - Widget container element. + * @param {jQuery.Event} event Event. + * @param {jQuery} widgetContainer Widget container element. * * @return {void} */ diff --git a/src/js/_enqueues/wp/widgets/text.js b/src/js/_enqueues/wp/widgets/text.js index df09ab40974ef..4b7af2e0d4a80 100644 --- a/src/js/_enqueues/wp/widgets/text.js +++ b/src/js/_enqueues/wp/widgets/text.js @@ -34,9 +34,9 @@ wp.textWidgets = ( function( $ ) { * @augments Backbone.View * @abstract * - * @param {Object} options - Options. - * @param {jQuery} options.el - Control field container element. - * @param {jQuery} options.syncContainer - Container element where fields are synced for the server. + * @param {Object} options Options. + * @param {jQuery} options.el Control field container element. + * @param {jQuery} options.syncContainer Container element where fields are synced for the server. * * @return {void} */ @@ -376,8 +376,8 @@ wp.textWidgets = ( function( $ ) { * * @memberOf wp.textWidgets * - * @param {jQuery.Event} event - Event. - * @param {jQuery} widgetContainer - Widget container element. + * @param {jQuery.Event} event Event. + * @param {jQuery} widgetContainer Widget container element. * * @return {void} */ @@ -484,8 +484,8 @@ wp.textWidgets = ( function( $ ) { * * @memberOf wp.textWidgets * - * @param {jQuery.Event} event - Event. - * @param {jQuery} widgetContainer - Widget container element. + * @param {jQuery.Event} event Event. + * @param {jQuery} widgetContainer Widget container element. * @return {void} */ component.handleWidgetUpdated = function handleWidgetUpdated( event, widgetContainer ) { diff --git a/src/js/media/controllers/state.js b/src/js/media/controllers/state.js index 12c07816251bc..1bacae9c0e734 100644 --- a/src/js/media/controllers/state.js +++ b/src/js/media/controllers/state.js @@ -6,11 +6,11 @@ * * A state has an event-driven lifecycle: * - * 'ready' triggers when a state is added to a state machine's collection. - * 'activate' triggers when a state is activated by a state machine. - * 'deactivate' triggers when a state is deactivated by a state machine. - * 'reset' is not triggered automatically. It should be invoked by the - * proper controller to reset the state to its default. + * 'ready' triggers when a state is added to a state machine's collection. + * 'activate' triggers when a state is activated by a state machine. + * 'deactivate' triggers when a state is deactivated by a state machine. + * 'reset' is not triggered automatically. It should be invoked by the + * proper controller to reset the state to its default. * * @memberOf wp.media.controller * @@ -85,7 +85,7 @@ var State = Backbone.Model.extend(/** @lends wp.media.controller.State.prototype * * @since 3.5.0 * @access private - */ + */ _preActivate: function() { this.active = true; }, diff --git a/src/js/media/models/attachment.js b/src/js/media/models/attachment.js index a116edf4add40..5c18eec27bf11 100644 --- a/src/js/media/models/attachment.js +++ b/src/js/media/models/attachment.js @@ -115,7 +115,7 @@ Attachment = Backbone.Model.extend(/** @lends wp.media.model.Attachment.prototyp /** * Saves attachment details using the `save-attachment-compat` action. * - * @param {Object} data The properties to be saved. + * @param {Object} data The properties to be saved. * @param {Object} options Sync options. e.g. patch, wait, success, error. * * @this Backbone.Model diff --git a/src/js/media/models/attachments.js b/src/js/media/models/attachments.js index fc6d79632d745..98d60e34726f5 100644 --- a/src/js/media/models/attachments.js +++ b/src/js/media/models/attachments.js @@ -18,8 +18,8 @@ * @param {string} [options.props.order] Initial order (ASC or DESC) for the collection. * @param {string} [options.props.orderby] Initial attribute key to order the collection by. * @param {string} [options.props.query] Whether the collection is linked to an attachments query. - * @param {string} [options.observe] An attachments collection to observe and mirror. - * @param {string} [options.filters] Filters to apply to the collection. + * @param {string} [options.observe] An attachments collection to observe and mirror. + * @param {string} [options.filters] Filters to apply to the collection. * */ var Attachments = Backbone.Collection.extend(/** @lends wp.media.model.Attachments.prototype */{ diff --git a/src/js/media/models/post-media.js b/src/js/media/models/post-media.js index fd642a724f6e1..56d76bbd24d0e 100644 --- a/src/js/media/models/post-media.js +++ b/src/js/media/models/post-media.js @@ -2,7 +2,7 @@ * wp.media.model.PostMedia * * Shared model class for audio and video. Updates the model after - * "Add Audio|Video Source" and "Replace Audio|Video" states return + * "Add Audio|Video Source" and "Replace Audio|Video" states return * * @memberOf wp.media.model * diff --git a/src/js/media/models/query.js b/src/js/media/models/query.js index dbcdb87d77466..74559c8320b3e 100644 --- a/src/js/media/models/query.js +++ b/src/js/media/models/query.js @@ -7,7 +7,7 @@ var Attachments = wp.media.model.Attachments, * A collection of attachments that match the supplied query arguments. * * Note: Do NOT change this.args after the query has been initialized. - * Things will break. + * Things will break. * * @memberOf wp.media.model * diff --git a/src/js/media/views/attachments/browser.js b/src/js/media/views/attachments/browser.js index 3726d39e2f145..8d7d4dca51b76 100644 --- a/src/js/media/views/attachments/browser.js +++ b/src/js/media/views/attachments/browser.js @@ -187,8 +187,8 @@ AttachmentsBrowser = View.extend(/** @lends wp.media.view.AttachmentsBrowser.pro } /** - * @member {wp.media.view.Toolbar} - */ + * @member {wp.media.view.Toolbar} + */ this.toolbar = new wp.media.view.Toolbar( toolbarOptions ); this.views.add( this.toolbar ); diff --git a/src/js/media/views/focus-manager.js b/src/js/media/views/focus-manager.js index 36ef6a851b0da..749d283c7245d 100644 --- a/src/js/media/views/focus-manager.js +++ b/src/js/media/views/focus-manager.js @@ -31,14 +31,14 @@ var FocusManager = wp.media.View.extend(/** @lends wp.media.view.FocusManager.pr }, /** - * Determines which focus management mode to use. - * - * @since 5.3.0 - * - * @param {Object} event jQuery event object. - * - * @return {void} - */ + * Determines which focus management mode to use. + * + * @since 5.3.0 + * + * @param {Object} event jQuery event object. + * + * @return {void} + */ focusManagementMode: function( event ) { if ( this.mode === 'constrainTabbing' ) { this.constrainTabbing( event ); diff --git a/tools/gutenberg/copy.js b/tools/gutenberg/copy.js index 3da78e4b14611..367da7ba53127 100644 --- a/tools/gutenberg/copy.js +++ b/tools/gutenberg/copy.js @@ -34,10 +34,10 @@ const wpIncludesDir = path.join( rootDir, 'src', 'wp-includes' ); * * @typedef ScriptsConfig * @type {object} - * @property {string} source - Gutenberg-relative source directory (e.g. `'scripts'`). - * @property {string} destination - Subpath under `wp-includes/` where packages land (e.g. `'js/dist'`). - * @property {boolean} copyDirectories - Whether to copy whole directories (with optional renames) as-is. - * @property {Record} directoryRenames - Map of source directory name → destination directory name. + * @property {string} source Gutenberg-relative source directory (e.g. `'scripts'`). + * @property {string} destination Subpath under `wp-includes/` where packages land (e.g. `'js/dist'`). + * @property {boolean} copyDirectories Whether to copy whole directories (with optional renames) as-is. + * @property {Record} directoryRenames Map of source directory name → destination directory name. */ /** @@ -45,10 +45,10 @@ const wpIncludesDir = path.join( rootDir, 'src', 'wp-includes' ); * * @typedef BlockConfigSource * @type {object} - * @property {string} name - Human-readable label (e.g. `'block-library'`, `'widgets'`). - * @property {string} scripts - Gutenberg-relative path to the block scripts directory. - * @property {string} styles - Gutenberg-relative path to the block styles directory. - * @property {string} php - Gutenberg-relative path to the block PHP directory. + * @property {string} name Human-readable label (e.g. `'block-library'`, `'widgets'`). + * @property {string} scripts Gutenberg-relative path to the block scripts directory. + * @property {string} styles Gutenberg-relative path to the block styles directory. + * @property {string} php Gutenberg-relative path to the block PHP directory. */ /** @@ -56,8 +56,8 @@ const wpIncludesDir = path.join( rootDir, 'src', 'wp-includes' ); * * @typedef BlockConfig * @type {object} - * @property {string} destination - Subpath under `wp-includes/` where blocks land (e.g. `'blocks'`). - * @property {BlockConfigSource[]} sources - One entry per block family. + * @property {string} destination Subpath under `wp-includes/` where blocks land (e.g. `'blocks'`). + * @property {BlockConfigSource[]} sources One entry per block family. */ /** @@ -118,7 +118,7 @@ function readReturnedValueFromPHPFile( phpFilepath ) { /** * Check if a block is experimental by reading its block.json. * - * @param {string} blockJsonPath - Path to block.json file. + * @param {string} blockJsonPath Path to block.json file. * @return {boolean} True if block is experimental. */ function isExperimentalBlock( blockJsonPath ) { @@ -140,7 +140,7 @@ function isExperimentalBlock( blockJsonPath ) { * * Blocks marked as `"__experimental": true` in a `block.json` file are excluded. * - * @param {string} scriptsSrc - Path to the Gutenberg scripts source (e.g. `scripts/block-library`). + * @param {string} scriptsSrc Path to the Gutenberg scripts source (e.g. `scripts/block-library`). * @return {string[]} Stable block directory names. */ function getStableBlocks( scriptsSrc ) { @@ -159,7 +159,7 @@ function getStableBlocks( scriptsSrc ) { /** * Copy JavaScript files. * - * @param {ScriptsConfig} config - Scripts configuration from `COPY_CONFIG.scripts`. + * @param {ScriptsConfig} config Scripts configuration from `COPY_CONFIG.scripts`. */ function copyScripts( config ) { const scriptsSrc = path.join( gutenbergBuildDir, config.source ); @@ -248,7 +248,7 @@ function copyScripts( config ) { /** * Copy `block.json` files for every stable block. * - * @param {BlockConfig} config - Block configuration from `COPY_CONFIG.blocks`. + * @param {BlockConfig} config Block configuration from `COPY_CONFIG.blocks`. */ function copyBlockJson( config ) { const blocksDest = path.join( wpIncludesDir, config.destination ); @@ -283,7 +283,7 @@ function copyBlockJson( config ) { * Handles both the top-level `.php` dynamic block files and any nested * `*.php` helpers under `/` (e.g. `navigation-link/shared/render-submenu-icon.php`). * - * @param {BlockConfig} config - Block configuration from `COPY_CONFIG.blocks`. + * @param {BlockConfig} config Block configuration from `COPY_CONFIG.blocks`. */ function copyBlockPhp( config ) { const blocksDest = path.join( wpIncludesDir, config.destination ); @@ -338,7 +338,7 @@ function copyBlockPhp( config ) { /** * Copy per-block CSS files for every stable block. * - * @param {BlockConfig} config - Block configuration from `COPY_CONFIG.blocks`. + * @param {BlockConfig} config Block configuration from `COPY_CONFIG.blocks`. */ function copyBlockStyles( config ) { const blocksDest = path.join( wpIncludesDir, config.destination ); @@ -391,8 +391,8 @@ function generateScriptModulesPackages() { /** * Recursively process directory to find .asset.php files. * - * @param {string} dir - Directory to process. - * @param {string} baseDir - Base directory for relative paths. + * @param {string} dir Directory to process. + * @param {string} baseDir Base directory for relative paths. */ function processDirectory( dir, baseDir ) { if ( ! fs.existsSync( dir ) ) { From 73ea9ac3c79e058c869bb85aa0ae0ef95bf38b42 Mon Sep 17 00:00:00 2001 From: Aki Hamano Date: Fri, 11 Sep 2026 11:05:35 +0000 Subject: [PATCH 210/363] Code Modernization: Use null coalescing operator in `WP_Block_Parser` Two methods used a ternary that treats a falsy value as not provided even though the parameters accept `0` as valid input, so this switches to the null coalescing operator, which tests only for `null`. Developed in: https://github.com/WordPress/wordpress-develop/pull/13484 Props mukesh27, wildworks. See #65818. git-svn-id: https://develop.svn.wordpress.org/trunk@63601 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-block-parser.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-includes/class-wp-block-parser.php b/src/wp-includes/class-wp-block-parser.php index c7e087ece8711..3b50c8e30cfe4 100644 --- a/src/wp-includes/class-wp-block-parser.php +++ b/src/wp-includes/class-wp-block-parser.php @@ -324,7 +324,7 @@ public function freeform( $inner_html ) { * @param null|int $length How many bytes of document text to output. */ public function add_freeform( $length = null ) { - $length = $length ? $length : strlen( $this->document ) - $this->offset; + $length = $length ?? strlen( $this->document ) - $this->offset; if ( 0 === $length ) { return; @@ -356,7 +356,7 @@ public function add_inner_block( WP_Block_Parser_Block $block, $token_start, $to } $parent->block->innerContent[] = null; - $parent->prev_offset = $last_offset ? $last_offset : $token_start + $token_length; + $parent->prev_offset = $last_offset ?? $token_start + $token_length; } /** From c176fdbd3a0a7b3615c7ebce54ae7179c3a99e6a Mon Sep 17 00:00:00 2001 From: Jorge Costa Date: Fri, 11 Sep 2026 16:13:44 +0000 Subject: [PATCH 211/363] Block Editor: Output `flex-direction: row` when a viewport override switches a flex layout to horizontal. `row` is the flex default, so the base layout never declares it. When a Tablet or Mobile override switched a vertical (Stack) layout to horizontal, the base `flex-direction: column` kept applying and the block stayed vertical. Backports https://github.com/WordPress/gutenberg/pull/82364. Developed in https://github.com/WordPress/wordpress-develop/pull/13370. Props jorgefilipecosta, talldanwp, firdaus666. Fixes #66096. git-svn-id: https://develop.svn.wordpress.org/trunk@63602 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/block-supports/layout.php | 11 ++++ tests/phpunit/tests/block-supports/layout.php | 61 +++++++++++++++++++ 2 files changed, 72 insertions(+) diff --git a/src/wp-includes/block-supports/layout.php b/src/wp-includes/block-supports/layout.php index 24431a05bb74a..b7c0503d3b5da 100644 --- a/src/wp-includes/block-supports/layout.php +++ b/src/wp-includes/block-supports/layout.php @@ -792,6 +792,17 @@ function wp_get_layout_style( $selector, $layout, $has_block_gap_support = false $flex_vertical_alignment = $layout_for_styles['verticalAlignment'] ?? null; if ( 'horizontal' === $layout_orientation ) { + /* + * `row` is the flex default, so the base layout never declares it. A viewport + * override that switches a vertical base layout to horizontal has to declare + * it explicitly, otherwise the base `flex-direction: column` keeps applying. + */ + if ( null !== $viewport_overrides && $has_viewport_property_override( 'orientation' ) ) { + $layout_styles[] = array( + 'selector' => $selector, + 'declarations' => array( 'flex-direction' => 'row' ), + ); + } /* * Add this style only if is not empty for backwards compatibility, * since we intend to convert blocks that had flex layout implemented diff --git a/tests/phpunit/tests/block-supports/layout.php b/tests/phpunit/tests/block-supports/layout.php index cda17660d67aa..2a8c7fc88cd6b 100644 --- a/tests/phpunit/tests/block-supports/layout.php +++ b/tests/phpunit/tests/block-supports/layout.php @@ -1233,6 +1233,67 @@ public function test_wp_get_layout_style_with_non_string_flex_alignment() { $this->assertIsString( $layout_styles, 'Flex layout should not fatal when alignment values are not strings.' ); } + /** + * Tests that a viewport override switching a vertical flex layout to horizontal + * outputs an explicit `flex-direction: row`, so the base `flex-direction: column` + * no longer applies on that viewport. + * + * @covers ::wp_get_layout_style + */ + public function test_wp_get_layout_style_outputs_flex_direction_row_for_horizontal_viewport_override() { + $layout_styles = wp_get_layout_style( + '.wp-layout', + array( + 'type' => 'flex', + 'orientation' => 'vertical', + 'flexWrap' => 'nowrap', + 'justifyContent' => 'center', + ), + false, + null, + false, + '0.5em', + null, + array( + 'viewport_overrides' => array( + 'orientation' => 'horizontal', + 'justifyContent' => 'left', + ), + ) + ); + + $this->assertSame( '.wp-layout{flex-direction:row;justify-content:flex-start;}', $layout_styles ); + } + + /** + * Tests that a viewport override which does not change a horizontal orientation + * keeps relying on the flex default and does not output `flex-direction`. + * + * @covers ::wp_get_layout_style + */ + public function test_wp_get_layout_style_keeps_flex_direction_implicit_without_orientation_override() { + $layout_styles = wp_get_layout_style( + '.wp-layout', + array( + 'type' => 'flex', + 'orientation' => 'horizontal', + 'justifyContent' => 'left', + ), + false, + null, + false, + '0.5em', + null, + array( + 'viewport_overrides' => array( + 'justifyContent' => 'right', + ), + ) + ); + + $this->assertSame( '.wp-layout{justify-content:flex-end;}', $layout_styles ); + } + /** * Tests that a responsive grid child with a non-string parent minimumColumnWidth * does not cause a fatal error in the explode() call. From 01248eefccfa2a60f23417e0e2f9046a18b6ed19 Mon Sep 17 00:00:00 2001 From: Jonny Harris Date: Fri, 11 Sep 2026 16:50:51 +0000 Subject: [PATCH 212/363] Meta: Support site meta subtype in get_object_subtype(). Add a 'blog' case to get_object_subtype() so register_meta() can resolve subtypes for site meta, matching the support already in place for posts, terms, comments, and users. Introduce register_site_meta() and unregister_site_meta() wrapper functions for registering and unregistering meta for sites, consistent with the existing site meta wrapper functions. Props sainathpoojary, spacedmonkey, flixos90, johnbillion. Fixes #44387. git-svn-id: https://develop.svn.wordpress.org/trunk@63603 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/meta.php | 14 ++++ src/wp-includes/ms-site.php | 26 +++++++ tests/phpunit/tests/meta/registerMeta.php | 94 +++++++++++++++++++++++ 3 files changed, 134 insertions(+) diff --git a/src/wp-includes/meta.php b/src/wp-includes/meta.php index 577785c2163a0..7bce5f40c059b 100644 --- a/src/wp-includes/meta.php +++ b/src/wp-includes/meta.php @@ -1789,6 +1789,7 @@ function _wp_register_meta_args_allowed_list( $args, $default_args ) { * Returns the object subtype for a given object ID of a specific type. * * @since 4.9.8 + * @since 7.2.0 Added support for 'blog' object type in multisite. * * @param string $object_type Type of object metadata is for. Accepts 'blog', 'post', 'comment', 'term', * 'user', or any other object type with an associated meta table. @@ -1834,6 +1835,19 @@ function get_object_subtype( $object_type, $object_id ) { $object_subtype = 'user'; break; + + case 'blog': + if ( ! is_multisite() || $object_id <= 0 ) { + break; + } + + $site = get_site( $object_id ); + if ( ! $site ) { + break; + } + + $object_subtype = 'blog'; + break; } /** diff --git a/src/wp-includes/ms-site.php b/src/wp-includes/ms-site.php index 6399dab72e881..65f5259fe12d0 100644 --- a/src/wp-includes/ms-site.php +++ b/src/wp-includes/ms-site.php @@ -1129,6 +1129,32 @@ function delete_site_meta_by_key( $meta_key ) { return delete_metadata( 'blog', null, $meta_key, '', true ); } +/** + * Registers a meta key for sites. + * + * @since 7.2.0 + * + * @param string $meta_key The meta key to register. + * @param array $args Data used to describe the meta key when registered. See + * {@see register_meta()} for a list of supported arguments. + * @return bool True if the meta key was successfully registered, false if not. + */ +function register_site_meta( $meta_key, array $args ) { + return register_meta( 'blog', $meta_key, $args ); +} + +/** + * Unregisters a meta key for sites. + * + * @since 7.2.0 + * + * @param string $meta_key The meta key to unregister. + * @return bool True on success, false if the meta key was not previously registered. + */ +function unregister_site_meta( $meta_key ) { + return unregister_meta_key( 'blog', $meta_key ); +} + /** * Updates the count of sites for a network based on a changed site. * diff --git a/tests/phpunit/tests/meta/registerMeta.php b/tests/phpunit/tests/meta/registerMeta.php index 30b6920bdea0d..4ffe6d751d99b 100644 --- a/tests/phpunit/tests/meta/registerMeta.php +++ b/tests/phpunit/tests/meta/registerMeta.php @@ -8,12 +8,17 @@ class Tests_Meta_Register_Meta extends WP_UnitTestCase { protected static $term_id; protected static $comment_id; protected static $user_id; + protected static $blog_id; public static function wpSetUpBeforeClass( WP_UnitTest_Factory $factory ) { self::$post_id = $factory->post->create( array( 'post_type' => 'page' ) ); self::$term_id = $factory->term->create( array( 'taxonomy' => 'category' ) ); self::$comment_id = $factory->comment->create(); self::$user_id = $factory->user->create(); + + if ( is_multisite() ) { + self::$blog_id = $factory->blog->create(); + } } public static function wpTearDownAfterClass() { @@ -21,6 +26,11 @@ public static function wpTearDownAfterClass() { wp_delete_term( self::$term_id, 'category' ); wp_delete_comment( self::$comment_id, true ); self::delete_user( self::$user_id ); + + if ( is_multisite() ) { + wp_delete_site( self::$blog_id ); + wp_update_network_site_counts(); + } } public function _old_sanitize_meta_cb( $meta_value, $meta_key, $meta_type ) { @@ -1105,6 +1115,60 @@ public function data_get_types_and_subtypes() { ); } + /** + * @ticket 44387 + * @group ms-required + */ + public function test_get_object_subtype_for_blog_returns_blog_when_site_exists() { + $this->assertSame( 'blog', get_object_subtype( 'blog', self::$blog_id ) ); + } + + /** + * @ticket 44387 + * @group ms-required + */ + public function test_get_object_subtype_for_blog_returns_empty_string_for_invalid_site() { + $this->assertSame( '', get_object_subtype( 'blog', 0 ) ); + $this->assertSame( '', get_object_subtype( 'blog', 999999 ) ); + } + + /** + * @ticket 44387 + * @group ms-excluded + */ + public function test_get_object_subtype_for_blog_returns_empty_string_no_multisite() { + $this->assertSame( '', get_object_subtype( 'blog', 0 ) ); + } + + /** + * @ticket 44387 + * @group ms-required + */ + public function test_get_object_subtype_for_blog_with_registered_meta() { + if ( ! is_site_meta_supported() ) { + $this->markTestSkipped( 'Test only runs with the blogmeta database table installed.' ); + } + + $this->assertSame( 'blog', get_object_subtype( 'blog', self::$blog_id ) ); + + register_meta( + 'blog', + 'site_rating', + array( + 'single' => true, + 'object_subtype' => 'blog', + ) + ); + add_site_meta( self::$blog_id, 'site_rating', '5' ); + + $meta = get_registered_metadata( 'blog', self::$blog_id, 'site_rating' ); + + unregister_meta_key( 'blog', 'site_rating', 'blog' ); + delete_site_meta( self::$blog_id, 'site_rating' ); + + $this->assertSame( '5', $meta ); + } + /** * Test that attempting to register meta with revisions_enabled set to true on a * post type that does not have revisions enabled fails and throws a `doing_it_wrong` notice. @@ -1135,4 +1199,34 @@ public function test_register_meta_with_revisions_enabled_on_post_type_without_r $this->assertFalse( $register ); } + + /** + * @ticket 44387 + * @group ms-required + */ + public function test_register_site_meta_returns_true_on_success() { + if ( ! is_site_meta_supported() ) { + $this->markTestSkipped( 'Test only runs with the blogmeta database table installed.' ); + } + + $result = register_site_meta( 'test_site_meta_key', array( 'single' => true ) ); + unregister_site_meta( 'test_site_meta_key' ); + + $this->assertTrue( $result ); + } + + /** + * @ticket 44387 + * @group ms-required + */ + public function test_unregister_site_meta_returns_true_on_success() { + if ( ! is_site_meta_supported() ) { + $this->markTestSkipped( 'Test only runs with the blogmeta database table installed.' ); + } + + register_site_meta( 'test_site_meta_key', array( 'single' => true ) ); + $result = unregister_site_meta( 'test_site_meta_key' ); + + $this->assertTrue( $result ); + } } From 1dfb754c2b80a32456b91bf3604ff7a003a73286 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Fri, 11 Sep 2026 20:59:28 +0000 Subject: [PATCH 213/363] Tests: Use `assertSame()` in `WP_Customize_Nav_Menu_Item_Setting` tests. This ensures that not only the return values match the expected results, but also that their type is the same. Where a loose comparison is intentional, inline comments now explain why: post meta returns IDs as strings, and some objects are compared by value. Developed in: https://github.com/WordPress/wordpress-develop/pull/13451 Props r1k0, mukesh27. See #64895. git-svn-id: https://develop.svn.wordpress.org/trunk@63604 602fd350-edb4-49c9-b593-d223f7449a82 --- .../tests/customize/nav-menu-item-setting.php | 23 +++++++++++++++++-- .../tests/customize/nav-menu-setting.php | 4 ++++ tests/phpunit/tests/customize/widgets.php | 2 ++ 3 files changed, 27 insertions(+), 2 deletions(-) diff --git a/tests/phpunit/tests/customize/nav-menu-item-setting.php b/tests/phpunit/tests/customize/nav-menu-item-setting.php index 0c832f3c6887c..124015557be92 100644 --- a/tests/phpunit/tests/customize/nav-menu-item-setting.php +++ b/tests/phpunit/tests/customize/nav-menu-item-setting.php @@ -190,7 +190,7 @@ public function test_value_type_post_type() { $value = $setting->value(); $this->assertSame( $menu_item->title, $value['title'] ); $this->assertSame( $menu_item->type, $value['type'] ); - $this->assertEquals( $menu_item->object_id, $value['object_id'] ); + $this->assertSame( (int) $menu_item->object_id, $value['object_id'] ); $this->assertSame( $menu_id, $value['nav_menu_term_id'] ); $this->assertSame( 'Hello World', $value['original_title'] ); @@ -273,7 +273,7 @@ public function test_value_type_taxonomy() { $value = $setting->value(); $this->assertSame( $menu_item->title, $value['title'] ); $this->assertSame( $menu_item->type, $value['type'] ); - $this->assertEquals( $menu_item->object_id, $value['object_id'] ); + $this->assertSame( (int) $menu_item->object_id, $value['object_id'] ); $this->assertSame( $menu_id, $value['nav_menu_term_id'] ); $this->assertSame( 'Salutations', $value['original_title'] ); } @@ -632,8 +632,17 @@ public function test_sanitize() { $post = get_post( $nav_menu_item_id ); $nav_menu_item = wp_setup_nav_menu_item( clone $post ); + /* + * Keep assertEquals() because sanitize() returns object_id as an integer + * while wp_setup_nav_menu_item() retrieves it as a string from post meta. + */ $this->assertEquals( $expected_sanitized['object_id'], $nav_menu_item->object_id ); $this->assertSame( $expected_sanitized['object'], $nav_menu_item->object ); + + /* + * Keep assertEquals() because sanitize() returns menu_item_parent as an integer, + * while wp_setup_nav_menu_item() retrieves it as a string from post meta. + */ $this->assertEquals( $expected_sanitized['menu_item_parent'], $nav_menu_item->menu_item_parent ); $this->assertSame( $expected_sanitized['position'], $post->menu_order ); $this->assertSame( $expected_sanitized['type'], $nav_menu_item->type ); @@ -697,6 +706,11 @@ public function test_save_updated() { $updated_item = $menu_items[ $i ]; $post_value['post_status'] = $post_value['status']; unset( $post_value['status'] ); + + /* + * Keep assertEquals() because object_id is an integer in $post_value + * but is returned as a string from post meta by wp_setup_nav_menu_item(). + */ foreach ( $post_value as $key => $value ) { $this->assertEquals( $value, $updated_item->$key, "Key $key mismatch" ); } @@ -770,6 +784,11 @@ public function test_save_inserted() { unset( $post_value['status'] ); $post_value['menu_order'] = $post_value['position']; unset( $post_value['position'] ); + + /* + * Keep assertEquals() because object_id is an integer in $post_value + * but is returned as a string from post meta by wp_setup_nav_menu_item(). + */ foreach ( $post_value as $key => $value ) { $this->assertEquals( $value, $last_item->$key, "Mismatch for $key property." ); } diff --git a/tests/phpunit/tests/customize/nav-menu-setting.php b/tests/phpunit/tests/customize/nav-menu-setting.php index 1348c86395a92..b7f9f9b057f4b 100644 --- a/tests/phpunit/tests/customize/nav-menu-setting.php +++ b/tests/phpunit/tests/customize/nav-menu-setting.php @@ -232,6 +232,8 @@ public function test_preview_updated() { $this->assertSameSets( $value, wp_array_slice_assoc( $term, array_keys( $value ) ) ); $menu_object = wp_get_nav_menu_object( $menu_id ); + + // Keep assertEquals() because the objects are intentionally compared by value. $this->assertEquals( (object) $term, $menu_object ); $this->assertSame( $post_value['name'], $menu_object->name ); @@ -277,6 +279,8 @@ public function test_preview_inserted() { $this->assertSame( $menu_id, $term['term_taxonomy_id'] ); $menu_object = wp_get_nav_menu_object( $menu_id ); + + // Keep assertEquals() because the objects are intentionally compared by value. $this->assertEquals( (object) $term, $menu_object ); $this->assertSame( $post_value['name'], $menu_object->name ); diff --git a/tests/phpunit/tests/customize/widgets.php b/tests/phpunit/tests/customize/widgets.php index c2ed6dbc661e2..b28246ac35a3f 100644 --- a/tests/phpunit/tests/customize/widgets.php +++ b/tests/phpunit/tests/customize/widgets.php @@ -515,6 +515,8 @@ public function test_sanitize_widget_instance_raw_instance() { $this->assertSame( '', $sanitized_for_js['title'] ); $this->assertTrue( $sanitized_for_js['is_widget_customizer_js_value'] ); $this->assertArrayHasKey( 'instance_hash_key', $sanitized_for_js ); + + // Keep assertEquals() because the objects are intentionally compared by value. $this->assertEquals( (object) $block_instance, $sanitized_for_js['raw_instance'] ); $unsanitized_from_js = $this->manager->widgets->sanitize_widget_instance( $sanitized_for_js ); From 98a8a2f0aba9011b0b9e8be2afc0bca5255bdc38 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Fri, 11 Sep 2026 23:14:49 +0000 Subject: [PATCH 214/363] Docs: Remove Screencast from the list of supported oEmbed providers. This is just a documentation change, as support for screencast.com has already been removed as of WordPress 6.8.2. This commit updates the list of supported providers in the `oembed_providers` filter DocBlock to reflect that change. Developed in https://github.com/WordPress/wordpress-develop/pull/13479. Follow-up to r60345. Props maheshpawar2012, westonruter, SergeyBiryukov. Fixes #66090. git-svn-id: https://develop.svn.wordpress.org/trunk@63605 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-oembed.php | 1 - 1 file changed, 1 deletion(-) diff --git a/src/wp-includes/class-wp-oembed.php b/src/wp-includes/class-wp-oembed.php index fa307092d409c..9d55a7adb1d05 100644 --- a/src/wp-includes/class-wp-oembed.php +++ b/src/wp-includes/class-wp-oembed.php @@ -175,7 +175,6 @@ public function __construct() { * | Twitter | twitter.com/user | 4.7.0 | * | Twitter | twitter.com/likes | 4.7.0 | * | Twitter | twitter.com/lists | 4.7.0 | - * | Screencast | screencast.com | 4.8.0 | * | Amazon | amazon.com (com.mx, com.br, ca) | 4.9.0 | * | Amazon | amazon.de (fr, it, es, in, nl, ru, co.uk) | 4.9.0 | * | Amazon | amazon.co.jp (com.au) | 4.9.0 | From 5c4fd7dc0db6b33cf1808bed18b2170ee378d9a0 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Sat, 12 Sep 2026 23:25:20 +0000 Subject: [PATCH 215/363] Tests: Use strict assertions in XML-RPC tests. Use type-strict comparisons for XML-RPC results and persisted values, matching the documented string ID contracts. Add explicit string checks where negative comparisons and numeric-format assertions do not enforce types. Correct the profile email test to inspect user_email, so it detects an unintended email change. Retain the loose term-array comparison because the internal and XML-RPC representations use different ID types. Developed in: https://github.com/WordPress/wordpress-develop/pull/13503 Props haritpanchal. See #64895. git-svn-id: https://develop.svn.wordpress.org/trunk@63606 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/xmlrpc/mw/editPost.php | 12 ++++++------ tests/phpunit/tests/xmlrpc/mw/newPost.php | 7 ++++--- tests/phpunit/tests/xmlrpc/wp/editPost.php | 14 +++++++------- tests/phpunit/tests/xmlrpc/wp/editProfile.php | 2 +- tests/phpunit/tests/xmlrpc/wp/editTerm.php | 2 +- tests/phpunit/tests/xmlrpc/wp/getComment.php | 10 +++++----- tests/phpunit/tests/xmlrpc/wp/getComments.php | 2 +- tests/phpunit/tests/xmlrpc/wp/getPost.php | 6 +++--- tests/phpunit/tests/xmlrpc/wp/getPosts.php | 2 +- tests/phpunit/tests/xmlrpc/wp/getProfile.php | 6 +++--- tests/phpunit/tests/xmlrpc/wp/getTerm.php | 11 ++++++++++- tests/phpunit/tests/xmlrpc/wp/getTerms.php | 4 ++-- tests/phpunit/tests/xmlrpc/wp/getUser.php | 10 +++++----- tests/phpunit/tests/xmlrpc/wp/getUsers.php | 2 +- tests/phpunit/tests/xmlrpc/wp/newPost.php | 7 ++++--- 15 files changed, 54 insertions(+), 43 deletions(-) diff --git a/tests/phpunit/tests/xmlrpc/mw/editPost.php b/tests/phpunit/tests/xmlrpc/mw/editPost.php index eb996787acc09..23515233325ff 100644 --- a/tests/phpunit/tests/xmlrpc/mw/editPost.php +++ b/tests/phpunit/tests/xmlrpc/mw/editPost.php @@ -88,7 +88,7 @@ public function test_capable_reassign_author() { $this->assertTrue( $result ); $out = get_post( $post_id ); - $this->assertEquals( $author_id, $out->post_author ); + $this->assertSame( (string) $author_id, $out->post_author ); } public function test_incapable_reassign_author() { @@ -107,7 +107,7 @@ public function test_incapable_reassign_author() { $this->assertSame( 401, $result->code ); $out = get_post( $post_id ); - $this->assertEquals( $contributor_id, $out->post_author ); + $this->assertSame( (string) $contributor_id, $out->post_author ); } /** @@ -129,7 +129,7 @@ public function test_capable_reassign_author_to_self() { $this->assertTrue( $result ); $out = get_post( $post_id ); - $this->assertEquals( $editor_id, $out->post_author ); + $this->assertSame( (string) $editor_id, $out->post_author ); } /** @@ -156,13 +156,13 @@ public function test_post_thumbnail() { $post2 = array( 'wp_post_thumbnail' => $attachment_id ); $result = $this->myxmlrpcserver->mw_editPost( array( $post_id, 'author', 'author', $post2 ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); // Edit the post without supplying a post_thumbnail and check that it didn't change. $post3 = array( 'post_content' => 'Updated post' ); $result = $this->myxmlrpcserver->mw_editPost( array( $post_id, 'author', 'author', $post3 ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); // Create another attachment. $attachment2_id = self::factory()->attachment->create_upload_object( $filename, $post_id ); @@ -171,7 +171,7 @@ public function test_post_thumbnail() { $post4 = array( 'wp_post_thumbnail' => $attachment2_id ); $result = $this->myxmlrpcserver->mw_editPost( array( $post_id, 'author', 'author', $post4 ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment2_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment2_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); // Unset the post's post_thumbnail. $post5 = array( 'wp_post_thumbnail' => '' ); diff --git a/tests/phpunit/tests/xmlrpc/mw/newPost.php b/tests/phpunit/tests/xmlrpc/mw/newPost.php index 3637d28536475..e7c4af0cee01f 100644 --- a/tests/phpunit/tests/xmlrpc/mw/newPost.php +++ b/tests/phpunit/tests/xmlrpc/mw/newPost.php @@ -49,7 +49,8 @@ public function test_ignore_id() { ); $result = $this->myxmlrpcserver->mw_newPost( array( 1, 'author', 'author', $post ) ); $this->assertNotIXRError( $result ); - $this->assertNotEquals( '103948', $result ); + $this->assertIsString( $result ); + $this->assertNotSame( '103948', $result ); } public function test_capable_publish() { @@ -124,7 +125,7 @@ public function test_empty_author() { $this->assertStringMatchesFormat( '%d', $result ); $out = get_post( $result ); - $this->assertEquals( $my_author_id, $out->post_author ); + $this->assertSame( (string) $my_author_id, $out->post_author ); $this->assertSame( 'Test', $out->post_title ); } @@ -146,7 +147,7 @@ public function test_post_thumbnail() { ); $result = $this->myxmlrpcserver->mw_newPost( array( 1, 'author', 'author', $post ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment_id, get_post_meta( $result, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment_id, get_post_meta( $result, '_thumbnail_id', true ) ); remove_theme_support( 'post-thumbnails' ); } diff --git a/tests/phpunit/tests/xmlrpc/wp/editPost.php b/tests/phpunit/tests/xmlrpc/wp/editPost.php index b5f27b85488d8..dacd64573a6d5 100644 --- a/tests/phpunit/tests/xmlrpc/wp/editPost.php +++ b/tests/phpunit/tests/xmlrpc/wp/editPost.php @@ -88,7 +88,7 @@ public function test_capable_reassign_author() { $this->assertTrue( $result ); $out = get_post( $post_id ); - $this->assertEquals( $author_id, $out->post_author ); + $this->assertSame( (string) $author_id, $out->post_author ); } public function test_incapable_reassign_author() { @@ -107,7 +107,7 @@ public function test_incapable_reassign_author() { $this->assertSame( 401, $result->code ); $out = get_post( $post_id ); - $this->assertEquals( $contributor_id, $out->post_author ); + $this->assertSame( (string) $contributor_id, $out->post_author ); } /** @@ -129,7 +129,7 @@ public function test_capable_reassign_author_to_self() { $this->assertTrue( $result ); $out = get_post( $post_id ); - $this->assertEquals( $editor_id, $out->post_author ); + $this->assertSame( (string) $editor_id, $out->post_author ); } /** @@ -156,20 +156,20 @@ public function test_post_thumbnail() { $post2 = array( 'post_thumbnail' => $attachment_id ); $result = $this->myxmlrpcserver->wp_editPost( array( 1, 'author', 'author', $post_id, $post2 ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); // Fetch the post to verify that it appears. $result = $this->myxmlrpcserver->wp_getPost( array( 1, 'author', 'author', $post_id ) ); $this->assertNotIXRError( $result ); $this->assertArrayHasKey( 'post_thumbnail', $result ); $this->assertIsArray( $result['post_thumbnail'] ); - $this->assertEquals( $attachment_id, $result['post_thumbnail']['attachment_id'] ); + $this->assertSame( (string) $attachment_id, $result['post_thumbnail']['attachment_id'] ); // Edit the post without supplying a post_thumbnail and check that it didn't change. $post3 = array( 'post_content' => 'Updated post' ); $result = $this->myxmlrpcserver->wp_editPost( array( 1, 'author', 'author', $post_id, $post3 ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); // Create another attachment. $attachment2_id = self::factory()->attachment->create_upload_object( $filename, $post_id ); @@ -178,7 +178,7 @@ public function test_post_thumbnail() { $post4 = array( 'post_thumbnail' => $attachment2_id ); $result = $this->myxmlrpcserver->wp_editPost( array( 1, 'author', 'author', $post_id, $post4 ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment2_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment2_id, get_post_meta( $post_id, '_thumbnail_id', true ) ); // Unset the post's post_thumbnail. $post5 = array( 'post_thumbnail' => '' ); diff --git a/tests/phpunit/tests/xmlrpc/wp/editProfile.php b/tests/phpunit/tests/xmlrpc/wp/editProfile.php index 2789dbe460095..579f82c33fceb 100644 --- a/tests/phpunit/tests/xmlrpc/wp/editProfile.php +++ b/tests/phpunit/tests/xmlrpc/wp/editProfile.php @@ -64,6 +64,6 @@ public function test_ignore_email_change() { $this->assertTrue( $result ); $user_data = get_userdata( $editor_id ); - $this->assertNotEquals( $new_email, $user_data->email ); + $this->assertNotSame( $new_email, $user_data->user_email ); } } diff --git a/tests/phpunit/tests/xmlrpc/wp/editTerm.php b/tests/phpunit/tests/xmlrpc/wp/editTerm.php index fbc310ac7ea4f..0f6d9cf891e2e 100644 --- a/tests/phpunit/tests/xmlrpc/wp/editTerm.php +++ b/tests/phpunit/tests/xmlrpc/wp/editTerm.php @@ -190,7 +190,7 @@ public function test_parent_null() { $this->assertIsBool( $result ); $term = get_term( self::$child_term, 'category' ); - $this->assertEquals( '0', $term->parent ); + $this->assertSame( 0, $term->parent ); } public function test_parent_invalid() { diff --git a/tests/phpunit/tests/xmlrpc/wp/getComment.php b/tests/phpunit/tests/xmlrpc/wp/getComment.php index 08cd4a5b00174..1eb64c23ec8c6 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getComment.php +++ b/tests/phpunit/tests/xmlrpc/wp/getComment.php @@ -74,10 +74,10 @@ public function test_valid_comment() { $this->assertStringMatchesFormat( '%d', $result['comment_id'] ); $this->assertStringMatchesFormat( '%d', $result['parent'] ); $this->assertStringMatchesFormat( '%d', $result['post_id'] ); - $this->assertEquals( self::$parent_comment_id, $result['comment_id'] ); - $this->assertEquals( 0, $result['parent'] ); + $this->assertSame( (string) self::$parent_comment_id, $result['comment_id'] ); + $this->assertSame( '0', $result['parent'] ); $this->assertSame( self::$parent_comment_data['comment_content'], $result['content'] ); - $this->assertEquals( self::$post_id, $result['post_id'] ); + $this->assertSame( (string) self::$post_id, $result['post_id'] ); $this->assertSame( self::$parent_comment_data['comment_author'], $result['author'] ); $this->assertSame( self::$parent_comment_data['comment_author_url'], $result['author_url'] ); $this->assertSame( self::$parent_comment_data['comment_author_email'], $result['author_email'] ); @@ -89,8 +89,8 @@ public function test_valid_child_comment() { $result = $this->myxmlrpcserver->wp_getComment( array( 1, 'editor', 'editor', self::$child_comment_id ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( self::$child_comment_id, $result['comment_id'] ); - $this->assertEquals( self::$parent_comment_id, $result['parent'] ); + $this->assertSame( (string) self::$child_comment_id, $result['comment_id'] ); + $this->assertSame( (string) self::$parent_comment_id, $result['parent'] ); } public function test_invalid_id() { diff --git a/tests/phpunit/tests/xmlrpc/wp/getComments.php b/tests/phpunit/tests/xmlrpc/wp/getComments.php index 606f9e0e855cf..acd131a1eef10 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getComments.php +++ b/tests/phpunit/tests/xmlrpc/wp/getComments.php @@ -56,7 +56,7 @@ public function test_post_filter() { $this->assertNotEmpty( $results ); foreach ( $results as $result ) { - $this->assertEquals( $this->post_id, $result['post_id'] ); + $this->assertSame( (string) $this->post_id, $result['post_id'] ); } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getPost.php b/tests/phpunit/tests/xmlrpc/wp/getPost.php index 72a0685a8a11a..8f2e28b5fd6ae 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getPost.php +++ b/tests/phpunit/tests/xmlrpc/wp/getPost.php @@ -72,9 +72,9 @@ public function test_valid_post() { $this->assertSame( $this->post_data['post_excerpt'], $result['post_excerpt'] ); $this->assertSame( $this->post_data['post_content'], $result['post_content'] ); $this->assertSame( url_to_postid( $result['link'] ), $this->post_id ); - $this->assertEquals( $this->post_custom_field['id'], $result['custom_fields'][0]['id'] ); + $this->assertSame( (string) $this->post_custom_field['id'], $result['custom_fields'][0]['id'] ); $this->assertSame( $this->post_custom_field['key'], $result['custom_fields'][0]['key'] ); - $this->assertEquals( $this->post_custom_field['value'], $result['custom_fields'][0]['value'] ); + $this->assertSame( (string) $this->post_custom_field['value'], $result['custom_fields'][0]['value'] ); remove_theme_support( 'post-thumbnails' ); } @@ -144,7 +144,7 @@ public function test_valid_page() { $this->assertIsString( $result['post_mime_type'] ); $this->assertSame( 'page', $result['post_type'] ); - $this->assertEquals( $parent_page_id, $result['post_parent'] ); + $this->assertSame( (string) $parent_page_id, $result['post_parent'] ); $this->assertSame( 2, $result['menu_order'] ); } diff --git a/tests/phpunit/tests/xmlrpc/wp/getPosts.php b/tests/phpunit/tests/xmlrpc/wp/getPosts.php index b1ab560886eb9..4ac3c46ab6069 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getPosts.php +++ b/tests/phpunit/tests/xmlrpc/wp/getPosts.php @@ -120,7 +120,7 @@ public function test_filters() { $results3 = $this->myxmlrpcserver->wp_getPosts( array( 1, 'editor', 'editor', $filter3 ) ); $this->assertNotIXRError( $results3 ); $this->assertCount( 1, $results3 ); - $this->assertEquals( $post->ID, $results3[0]['post_id'] ); + $this->assertSame( (string) $post->ID, $results3[0]['post_id'] ); _unregister_post_type( $cpt_name ); } diff --git a/tests/phpunit/tests/xmlrpc/wp/getProfile.php b/tests/phpunit/tests/xmlrpc/wp/getProfile.php index c9325ade3d670..60122d84769db 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getProfile.php +++ b/tests/phpunit/tests/xmlrpc/wp/getProfile.php @@ -17,7 +17,7 @@ public function test_subscriber() { $result = $this->myxmlrpcserver->wp_getProfile( array( 1, 'subscriber', 'subscriber' ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $subscriber_id, $result['user_id'] ); + $this->assertSame( (string) $subscriber_id, $result['user_id'] ); $this->assertContains( 'subscriber', $result['roles'] ); } @@ -26,7 +26,7 @@ public function test_administrator() { $result = $this->myxmlrpcserver->wp_getProfile( array( 1, 'administrator', 'administrator' ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $administrator_id, $result['user_id'] ); + $this->assertSame( (string) $administrator_id, $result['user_id'] ); $this->assertContains( 'administrator', $result['roles'] ); } @@ -37,7 +37,7 @@ public function test_arbitrary_fields() { $result = $this->myxmlrpcserver->wp_getProfile( array( 1, 'editor', 'editor', $fields ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $editor_id, $result['user_id'] ); + $this->assertSame( (string) $editor_id, $result['user_id'] ); $expected_fields = array( 'user_id', 'email', 'bio' ); $keys = array_keys( $result ); diff --git a/tests/phpunit/tests/xmlrpc/wp/getTerm.php b/tests/phpunit/tests/xmlrpc/wp/getTerm.php index 7eb1d3e2e4aff..c6ebe2645e449 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getTerm.php +++ b/tests/phpunit/tests/xmlrpc/wp/getTerm.php @@ -76,7 +76,12 @@ public function test_valid_term() { $result = $this->myxmlrpcserver->wp_getTerm( array( 1, 'editor', 'editor', 'category', self::$term_id ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $result, $term ); + /* + * This comparison stays loose: wp.getTerm returns the IDs as strings so that they + * cannot exceed what an XML-RPC integer can describe, while get_term() returns them + * as integers. The individual types are asserted below. + */ + $this->assertEquals( $term, $result ); // Check data types. $this->assertIsString( $result['name'] ); @@ -86,6 +91,10 @@ public function test_valid_term() { $this->assertIsInt( $result['count'] ); // We expect all ID's to be strings not integers so we don't return something larger than an XMLRPC integer can describe. + $this->assertIsString( $result['term_id'] ); + $this->assertIsString( $result['term_group'] ); + $this->assertIsString( $result['term_taxonomy_id'] ); + $this->assertIsString( $result['parent'] ); $this->assertStringMatchesFormat( '%d', $result['term_id'] ); $this->assertStringMatchesFormat( '%d', $result['term_group'] ); $this->assertStringMatchesFormat( '%d', $result['term_taxonomy_id'] ); diff --git a/tests/phpunit/tests/xmlrpc/wp/getTerms.php b/tests/phpunit/tests/xmlrpc/wp/getTerms.php index d538a4efd2b8e..729a1e6b4ad2f 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getTerms.php +++ b/tests/phpunit/tests/xmlrpc/wp/getTerms.php @@ -143,7 +143,7 @@ public function test_terms_search() { $this->assertNotIXRError( $results ); $this->assertCount( 1, $results ); $this->assertSame( $name, $results[0]['name'] ); - $this->assertEquals( $name_id, $results[0]['term_id'] ); + $this->assertSame( (string) $name_id, $results[0]['term_id'] ); // Search by partial name. $filter = array( 'search' => substr( $name, 0, 10 ) ); @@ -151,6 +151,6 @@ public function test_terms_search() { $this->assertNotIXRError( $results2 ); $this->assertCount( 1, $results2 ); $this->assertSame( $name, $results2[0]['name'] ); - $this->assertEquals( $name_id, $results2[0]['term_id'] ); + $this->assertSame( (string) $name_id, $results2[0]['term_id'] ); } } diff --git a/tests/phpunit/tests/xmlrpc/wp/getUser.php b/tests/phpunit/tests/xmlrpc/wp/getUser.php index 8cfb34ae3e7eb..ca7a6bb6b1ba9 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getUser.php +++ b/tests/phpunit/tests/xmlrpc/wp/getUser.php @@ -43,7 +43,7 @@ public function test_subscriber_self() { $result = $this->myxmlrpcserver->wp_getUser( array( 1, 'subscriber', 'subscriber', $subscriber_id ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $subscriber_id, $result['user_id'] ); + $this->assertSame( (string) $subscriber_id, $result['user_id'] ); } public function test_valid_user() { @@ -83,7 +83,7 @@ public function test_valid_user() { $this->assertIsArray( $result['roles'] ); // Check expected values. - $this->assertEquals( $user_id, $result['user_id'] ); + $this->assertSame( (string) $user_id, $result['user_id'] ); $this->assertSame( $user_data['user_login'], $result['username'] ); $this->assertSame( $user_data['first_name'], $result['first_name'] ); $this->assertSame( $user_data['last_name'], $result['last_name'] ); @@ -105,7 +105,7 @@ public function test_no_fields() { $result = $this->myxmlrpcserver->wp_getUser( array( 1, 'administrator', 'administrator', $editor_id, array() ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $editor_id, $result['user_id'] ); + $this->assertSame( (string) $editor_id, $result['user_id'] ); $expected_fields = array( 'user_id' ); $this->assertSame( $expected_fields, array_keys( $result ) ); @@ -116,7 +116,7 @@ public function test_basic_fields() { $result = $this->myxmlrpcserver->wp_getUser( array( 1, 'administrator', 'administrator', $editor_id, array( 'basic' ) ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $editor_id, $result['user_id'] ); + $this->assertSame( (string) $editor_id, $result['user_id'] ); $expected_fields = array( 'user_id', 'username', 'email', 'registered', 'display_name', 'nicename' ); $keys = array_keys( $result ); @@ -132,7 +132,7 @@ public function test_arbitrary_fields() { $result = $this->myxmlrpcserver->wp_getUser( array( 1, 'administrator', 'administrator', $editor_id, $fields ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $editor_id, $result['user_id'] ); + $this->assertSame( (string) $editor_id, $result['user_id'] ); $expected_fields = array( 'user_id', 'email', 'bio' ); $keys = array_keys( $result ); diff --git a/tests/phpunit/tests/xmlrpc/wp/getUsers.php b/tests/phpunit/tests/xmlrpc/wp/getUsers.php index a0eeee4026645..a442ad4969d92 100644 --- a/tests/phpunit/tests/xmlrpc/wp/getUsers.php +++ b/tests/phpunit/tests/xmlrpc/wp/getUsers.php @@ -70,7 +70,7 @@ public function test_role_filter() { $results = $this->myxmlrpcserver->wp_getUsers( array( 1, 'administrator', 'administrator', $filter ) ); $this->assertNotIXRError( $results ); $this->assertCount( 1, $results ); - $this->assertEquals( $editor_id, $results[0]['user_id'] ); + $this->assertSame( (string) $editor_id, $results[0]['user_id'] ); // Test 'authors', which should return all non-subscribers. $filter2 = array( 'who' => 'authors' ); diff --git a/tests/phpunit/tests/xmlrpc/wp/newPost.php b/tests/phpunit/tests/xmlrpc/wp/newPost.php index b98b06c01d55b..c6386a1f23d5b 100644 --- a/tests/phpunit/tests/xmlrpc/wp/newPost.php +++ b/tests/phpunit/tests/xmlrpc/wp/newPost.php @@ -46,7 +46,8 @@ public function test_ignore_id() { ); $result = $this->myxmlrpcserver->wp_newPost( array( 1, 'author', 'author', $post ) ); $this->assertNotIXRError( $result ); - $this->assertNotEquals( '103948', $result ); + $this->assertIsString( $result ); + $this->assertNotSame( '103948', $result ); } public function test_capable_publish() { @@ -141,7 +142,7 @@ public function test_empty_author() { $this->assertStringMatchesFormat( '%d', $result ); $out = get_post( $result ); - $this->assertEquals( $my_author_id, $out->post_author ); + $this->assertSame( (string) $my_author_id, $out->post_author ); $this->assertSame( 'Test', $out->post_title ); } @@ -163,7 +164,7 @@ public function test_post_thumbnail() { ); $result = $this->myxmlrpcserver->wp_newPost( array( 1, 'author', 'author', $post ) ); $this->assertNotIXRError( $result ); - $this->assertEquals( $attachment_id, get_post_meta( $result, '_thumbnail_id', true ) ); + $this->assertSame( (string) $attachment_id, get_post_meta( $result, '_thumbnail_id', true ) ); remove_theme_support( 'post-thumbnails' ); } From 81e3c7f291036dbe3e8a31057e6620180542fe19 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sat, 12 Sep 2026 23:54:44 +0000 Subject: [PATCH 216/363] Code Modernization: Use the null coalescing assignment operator for query variable defaults. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replaces the “assign a default only if not already set” guard blocks in `WP_Query`, `WP_Tax_Query`, `WP_Date_Query` and `WP_Metadata_Lazyloader` with the null coalescing assignment operator (`??=`). Follow-up to r63443, r63501, r63509, r63541. Props Soean, mukesh27. See #65823. git-svn-id: https://develop.svn.wordpress.org/trunk@63607 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-date-query.php | 4 +- .../class-wp-metadata-lazyloader.php | 8 +-- src/wp-includes/class-wp-query.php | 58 +++++-------------- src/wp-includes/class-wp-tax-query.php | 9 +-- 4 files changed, 20 insertions(+), 59 deletions(-) diff --git a/src/wp-includes/class-wp-date-query.php b/src/wp-includes/class-wp-date-query.php index 4a6e6ca2ed426..abfacce6cdde8 100644 --- a/src/wp-includes/class-wp-date-query.php +++ b/src/wp-includes/class-wp-date-query.php @@ -784,9 +784,7 @@ protected function get_sql_for_clause( $query, $parent_query ) { if ( isset( $query['hour'] ) || isset( $query['minute'] ) || isset( $query['second'] ) ) { // Avoid notices. foreach ( array( 'hour', 'minute', 'second' ) as $unit ) { - if ( ! isset( $query[ $unit ] ) ) { - $query[ $unit ] = null; - } + $query[ $unit ] ??= null; } $time_query = $this->build_time_query( $column, $compare, $query['hour'], $query['minute'], $query['second'] ); diff --git a/src/wp-includes/class-wp-metadata-lazyloader.php b/src/wp-includes/class-wp-metadata-lazyloader.php index f9c02391d2b1d..2725cbfee32c6 100644 --- a/src/wp-includes/class-wp-metadata-lazyloader.php +++ b/src/wp-includes/class-wp-metadata-lazyloader.php @@ -84,15 +84,11 @@ public function queue_objects( $object_type, $object_ids ) { $type_settings = $this->settings[ $object_type ]; - if ( ! isset( $this->pending_objects[ $object_type ] ) ) { - $this->pending_objects[ $object_type ] = array(); - } + $this->pending_objects[ $object_type ] ??= array(); foreach ( $object_ids as $object_id ) { // Keyed by ID for faster lookup. - if ( ! isset( $this->pending_objects[ $object_type ][ $object_id ] ) ) { - $this->pending_objects[ $object_type ][ $object_id ] = 1; - } + $this->pending_objects[ $object_type ][ $object_id ] ??= 1; } add_filter( $type_settings['filter'], $type_settings['callback'], 10, 5 ); diff --git a/src/wp-includes/class-wp-query.php b/src/wp-includes/class-wp-query.php index 1d6b652c5a610..2835da604bef5 100644 --- a/src/wp-includes/class-wp-query.php +++ b/src/wp-includes/class-wp-query.php @@ -618,9 +618,7 @@ public function fill_query_vars( $query_vars ) { ); foreach ( $keys as $key ) { - if ( ! isset( $query_vars[ $key ] ) ) { - $query_vars[ $key ] = ''; - } + $query_vars[ $key ] ??= ''; } $array_keys = array( @@ -643,9 +641,7 @@ public function fill_query_vars( $query_vars ) { ); foreach ( $array_keys as $key ) { - if ( ! isset( $query_vars[ $key ] ) ) { - $query_vars[ $key ] = array(); - } + $query_vars[ $key ] ??= array(); } return $query_vars; @@ -1279,10 +1275,8 @@ public function parse_tax_query( &$query_vars ) { } if ( ! empty( $query_vars['category__and'] ) && 1 === count( (array) $query_vars['category__and'] ) ) { - $query_vars['category__and'] = (array) $query_vars['category__and']; - if ( ! isset( $query_vars['category__in'] ) ) { - $query_vars['category__in'] = array(); - } + $query_vars['category__and'] = (array) $query_vars['category__and']; + $query_vars['category__in'] ??= array(); $query_vars['category__in'][] = absint( reset( $query_vars['category__and'] ) ); unset( $query_vars['category__and'] ); } @@ -1967,30 +1961,14 @@ public function get_posts() { ) ); - if ( ! isset( $query_vars['ignore_sticky_posts'] ) ) { - $query_vars['ignore_sticky_posts'] = $query_vars['caller_get_posts']; - } + $query_vars['ignore_sticky_posts'] ??= $query_vars['caller_get_posts']; } - if ( ! isset( $query_vars['ignore_sticky_posts'] ) ) { - $query_vars['ignore_sticky_posts'] = false; - } - - if ( ! isset( $query_vars['suppress_filters'] ) ) { - $query_vars['suppress_filters'] = false; - } - - if ( ! isset( $query_vars['cache_results'] ) ) { - $query_vars['cache_results'] = true; - } - - if ( ! isset( $query_vars['update_post_term_cache'] ) ) { - $query_vars['update_post_term_cache'] = true; - } - - if ( ! isset( $query_vars['update_menu_item_cache'] ) ) { - $query_vars['update_menu_item_cache'] = false; - } + $query_vars['ignore_sticky_posts'] ??= false; + $query_vars['suppress_filters'] ??= false; + $query_vars['cache_results'] ??= true; + $query_vars['update_post_term_cache'] ??= true; + $query_vars['update_menu_item_cache'] ??= false; if ( ! isset( $query_vars['lazy_load_term_meta'] ) ) { $query_vars['lazy_load_term_meta'] = $query_vars['update_post_term_cache']; @@ -1998,9 +1976,7 @@ public function get_posts() { $query_vars['update_post_term_cache'] = true; } - if ( ! isset( $query_vars['update_post_meta_cache'] ) ) { - $query_vars['update_post_meta_cache'] = true; - } + $query_vars['update_post_meta_cache'] ??= true; if ( ! isset( $query_vars['post_type'] ) ) { if ( $this->is_search ) { @@ -3322,9 +3298,7 @@ public function get_posts() { } if ( 'ids' === $query_vars['fields'] ) { - if ( null === $this->posts ) { - $this->posts = $wpdb->get_col( $this->request ); - } + $this->posts ??= $wpdb->get_col( $this->request ); /** @var int[] */ $this->posts = array_map( 'intval', $this->posts ); @@ -3345,9 +3319,7 @@ public function get_posts() { } if ( 'id=>parent' === $query_vars['fields'] ) { - if ( null === $this->posts ) { - $this->posts = $wpdb->get_results( $this->request ); - } + $this->posts ??= $wpdb->get_results( $this->request ); $this->post_count = count( $this->posts ); $this->set_found_posts( $query_vars, $limits ); @@ -5081,9 +5053,7 @@ protected function generate_cache_key( array $args, $sql ) { } // Add a default orderby value of date to ensure same cache key generation. - if ( ! isset( $args['orderby'] ) ) { - $args['orderby'] = 'date'; - } + $args['orderby'] ??= 'date'; $placeholder = $wpdb->placeholder_escape(); array_walk_recursive( diff --git a/src/wp-includes/class-wp-tax-query.php b/src/wp-includes/class-wp-tax-query.php index c6ec3258cc201..7e254b1275c9f 100644 --- a/src/wp-includes/class-wp-tax-query.php +++ b/src/wp-includes/class-wp-tax-query.php @@ -161,9 +161,8 @@ public function sanitize_query( $queries ) { */ if ( ! empty( $cleaned_clause['taxonomy'] ) && 'NOT IN' !== $cleaned_clause['operator'] ) { $taxonomy = $cleaned_clause['taxonomy']; - if ( ! isset( $this->queried_terms[ $taxonomy ] ) ) { - $this->queried_terms[ $taxonomy ] = array(); - } + + $this->queried_terms[ $taxonomy ] ??= array(); /* * Backward compatibility: Only store the first @@ -184,9 +183,7 @@ public function sanitize_query( $queries ) { if ( ! empty( $cleaned_subquery ) ) { // All queries with children must have a relation. - if ( ! isset( $cleaned_subquery['relation'] ) ) { - $cleaned_subquery['relation'] = 'AND'; - } + $cleaned_subquery['relation'] ??= 'AND'; $cleaned_query[] = $cleaned_subquery; } From c88f5157ae60afaaa90fa89bfc46f2fed8841f91 Mon Sep 17 00:00:00 2001 From: Lance Willett Date: Sun, 13 Sep 2026 16:21:34 +0000 Subject: [PATCH 217/363] Tests: Improve isolation of admin tests. Reset menu registries and plugin-dependency static properties before and after tests. Remove the temporary MU-plugin directory after its fixture files are deleted. Give list-table fixtures distinct screens and preserve whether the original hook suffix was set. Align the comments table's expected primary column with its declared default. Allow updater tests to load Composer dependencies outside the checkout while exercising open_basedir restrictions. Developed in: https://github.com/WordPress/wordpress-develop/pull/13181 Props jonsurrell, mindctrl. See #65893. git-svn-id: https://develop.svn.wordpress.org/trunk@63608 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/admin/includesPlugin.php | 24 ++++++++++++++ .../tests/admin/plugin-dependencies/base.php | 18 ++++++++-- .../tests/admin/wpAutomaticUpdater.php | 31 ++++++++++++++--- tests/phpunit/tests/admin/wpListTable.php | 33 ++++++++++++------- 4 files changed, 88 insertions(+), 18 deletions(-) diff --git a/tests/phpunit/tests/admin/includesPlugin.php b/tests/phpunit/tests/admin/includesPlugin.php index 4d47fb7db0a81..21e3064ff6b55 100644 --- a/tests/phpunit/tests/admin/includesPlugin.php +++ b/tests/phpunit/tests/admin/includesPlugin.php @@ -12,6 +12,29 @@ class Tests_Admin_IncludesPlugin extends WP_UnitTestCase { */ public static $admin_id; + public function set_up() { + parent::set_up(); + $this->reset_menu_globals(); + } + + public function tear_down() { + $this->reset_menu_globals(); + parent::tear_down(); + } + + /** + * Resets the global menu registries modified by the menu API tests. + */ + private function reset_menu_globals() { + global $menu, $submenu, $admin_page_hooks, $_registered_pages, $_parent_pages; + + $menu = array(); + $submenu = array(); + $admin_page_hooks = array(); + $_registered_pages = array(); + $_parent_pages = array(); + } + public static function wpSetUpBeforeClass( $factory ) { self::$admin_id = $factory->user->create( array( 'role' => 'administrator' ) ); self::_back_up_mu_plugins(); @@ -501,6 +524,7 @@ public function test_get_mu_plugins_should_ignore_files_without_php_extensions() // Clean up. unlink( WPMU_PLUGIN_DIR . '/foo.php' ); unlink( WPMU_PLUGIN_DIR . '/bar.txt' ); + rmdir( WPMU_PLUGIN_DIR ); $this->assertSame( array( 'foo.php' ), array_keys( $found ) ); } diff --git a/tests/phpunit/tests/admin/plugin-dependencies/base.php b/tests/phpunit/tests/admin/plugin-dependencies/base.php index 22c509807b205..badd4cfe63c92 100644 --- a/tests/phpunit/tests/admin/plugin-dependencies/base.php +++ b/tests/phpunit/tests/admin/plugin-dependencies/base.php @@ -60,15 +60,29 @@ public static function tear_down_after_class() { parent::tear_down_after_class(); } + /** + * Resets all static properties to a default value before each test. + */ + public function set_up() { + parent::set_up(); + $this->reset_static_properties(); + } + /** * Resets all static properties to a default value after each test. */ public function tear_down() { + $this->reset_static_properties(); + parent::tear_down(); + } + + /** + * Resets all static properties to their default values. + */ + private function reset_static_properties() { foreach ( self::$static_properties as $name => $default_value ) { $this->set_property_value( $name, $default_value ); } - - parent::tear_down(); } /** diff --git a/tests/phpunit/tests/admin/wpAutomaticUpdater.php b/tests/phpunit/tests/admin/wpAutomaticUpdater.php index ee52f44daf9c1..2aca85616cb5f 100644 --- a/tests/phpunit/tests/admin/wpAutomaticUpdater.php +++ b/tests/phpunit/tests/admin/wpAutomaticUpdater.php @@ -40,6 +40,31 @@ public function set_up() { add_filter( 'pre_wp_mail', '__return_false' ); } + /** + * Builds an open_basedir value that allows PHPUnit to load Composer dependencies. + * + * Composer dependencies may live outside a secondary worktree, and PHPUnit can + * load assertion-related classes after the restriction is set. + * + * @param string $abspath_grandparent Directory containing the repository. + * @return string The open_basedir value. + */ + private function get_open_basedir_for_tests( $abspath_grandparent ) { + $composer_vendor_dir = dirname( + ( new ReflectionClass( Composer\Autoload\ClassLoader::class ) )->getFileName(), + 2 + ); + + return implode( + PATH_SEPARATOR, + array( + sys_get_temp_dir(), + wp_normalize_path( $abspath_grandparent ), + wp_normalize_path( $composer_vendor_dir ), + ) + ); + } + /** * Tests that `WP_Automatic_Updater::send_plugin_theme_email()` appends * plugin URLs. @@ -612,8 +637,7 @@ public function test_is_allowed_dir_should_return_true_if_open_basedir_is_set_an $abspath_grandparent = trailingslashit( dirname( $abspath_parent ) ); $open_basedir_backup = ini_get( 'open_basedir' ); - // Allow access to the directory one level above the repository. - ini_set( 'open_basedir', sys_get_temp_dir() . PATH_SEPARATOR . wp_normalize_path( $abspath_grandparent ) ); + ini_set( 'open_basedir', $this->get_open_basedir_for_tests( $abspath_grandparent ) ); // Checking an allowed directory should succeed. $actual = self::$updater->is_allowed_dir( wp_normalize_path( ABSPATH ) ); @@ -647,8 +671,7 @@ public function test_is_allowed_dir_should_return_false_if_open_basedir_is_set_a $abspath_grandparent = trailingslashit( dirname( $abspath_parent ) ); $open_basedir_backup = ini_get( 'open_basedir' ); - // Allow access to the directory one level above the repository. - ini_set( 'open_basedir', sys_get_temp_dir() . PATH_SEPARATOR . wp_normalize_path( $abspath_grandparent ) ); + ini_set( 'open_basedir', $this->get_open_basedir_for_tests( $abspath_grandparent ) ); // Checking a directory not within the allowed path should trigger an `open_basedir` warning. $actual = self::$updater->is_allowed_dir( '/.git' ); diff --git a/tests/phpunit/tests/admin/wpListTable.php b/tests/phpunit/tests/admin/wpListTable.php index b3de66659b308..ebaafc62beb20 100644 --- a/tests/phpunit/tests/admin/wpListTable.php +++ b/tests/phpunit/tests/admin/wpListTable.php @@ -17,14 +17,22 @@ class Tests_Admin_WpListTable extends WP_UnitTestCase { /** * Original value of $GLOBALS['hook_suffix']. * - * @var string + * @var string|null */ private static $original_hook_suffix; + /** + * Whether $GLOBALS['hook_suffix'] existed before the test class ran. + * + * @var bool + */ + private static $hook_suffix_was_set; + public static function set_up_before_class() { parent::set_up_before_class(); - static::$original_hook_suffix = $GLOBALS['hook_suffix']; + static::$hook_suffix_was_set = array_key_exists( 'hook_suffix', $GLOBALS ); + static::$original_hook_suffix = $GLOBALS['hook_suffix'] ?? null; require_once ABSPATH . 'wp-admin/includes/class-wp-list-table.php'; } @@ -37,8 +45,12 @@ public function set_up() { } public function clean_up_global_scope() { - global $hook_suffix; - $hook_suffix = static::$original_hook_suffix; + if ( static::$hook_suffix_was_set ) { + $GLOBALS['hook_suffix'] = static::$original_hook_suffix; + } else { + unset( $GLOBALS['hook_suffix'] ); + } + parent::clean_up_global_scope(); } @@ -61,13 +73,10 @@ public function test_should_only_add_primary_column_when_needed( $list_class, $h $hook = new MockAction(); add_filter( 'list_table_primary_column', array( $hook, 'filter' ) ); - /* - * Set a dummy value for the current screen in the admin to prevent - * `_get_list_table()` throwing. - */ - $GLOBALS['hook_suffix'] = 'my-hook'; - - $list_table = _get_list_table( $list_class ); + $list_table = _get_list_table( + $list_class, + array( 'screen' => 'wp-list-table-test-' . sanitize_key( $list_class ) ) + ); $column_headers = new ReflectionProperty( $list_table, '_column_headers' ); if ( PHP_VERSION_ID < 80100 ) { @@ -97,7 +106,7 @@ public function data_should_only_add_primary_column_when_needed() { */ $list_primary_columns = array( 'WP_Application_Passwords_List_Table' => 'name', - 'WP_Comments_List_Table' => 'author', + 'WP_Comments_List_Table' => 'comment', 'WP_Links_List_Table' => 'name', 'WP_Media_List_Table' => 'title', 'WP_MS_Sites_List_Table' => 'blogname', From c141ea30eba0402931c0f9ba90190db72101b1af Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sun, 13 Sep 2026 23:46:12 +0000 Subject: [PATCH 218/363] Code Modernization: Use the null coalescing operator in `wp_get_chromium_major_version()` tests. `Tests_Media_wpGetChromiumMajorVersion::set_up()` stores the original `$_SERVER['HTTP_USER_AGENT']` value using an `isset()` ternary that repeats the array access. This replaces it with the null coalescing operator, which is shorter and expresses the same intent. The null coalescing operator is available since PHP 7.0, and WordPress requires PHP 7.4 or later, so no compatibility concerns apply. It is already used widely across the codebase, so this makes the style more consistent. Developed in https://github.com/WordPress/wordpress-develop/pull/13469. Follow-up to r62428. Props Soean, mukesh27. See #65819. git-svn-id: https://develop.svn.wordpress.org/trunk@63609 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpunit/tests/media/wpGetChromiumMajorVersion.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/phpunit/tests/media/wpGetChromiumMajorVersion.php b/tests/phpunit/tests/media/wpGetChromiumMajorVersion.php index 7249d9b91b665..eb03985116451 100644 --- a/tests/phpunit/tests/media/wpGetChromiumMajorVersion.php +++ b/tests/phpunit/tests/media/wpGetChromiumMajorVersion.php @@ -17,7 +17,7 @@ class Tests_Media_wpGetChromiumMajorVersion extends WP_UnitTestCase { public function set_up() { parent::set_up(); - $this->original_user_agent = isset( $_SERVER['HTTP_USER_AGENT'] ) ? $_SERVER['HTTP_USER_AGENT'] : null; + $this->original_user_agent = $_SERVER['HTTP_USER_AGENT'] ?? null; } public function tear_down() { From ce1aa14a3a94550e95a660edb38499160573a8f0 Mon Sep 17 00:00:00 2001 From: ramonopoly Date: Mon, 14 Sep 2026 01:50:28 +0000 Subject: [PATCH 219/363] Editor: Retain responsive styles in block style variation partials MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Responsive `@tablet` and `@mobile` styles were silently dropped from block style variations declared in a standalone JSON partial in a theme's `styles/` directory. This commit adds the responsive breakpoint states to the top-level styles schema, mirroring what the block style variation branch already does. This restores the parity to the two schemas. Developed in: https://github.com/WordPress/wordpress-develop/pull/13325 Props adamsilverstein, andraganescu, andrewserong, firdaus666, mitgiselle, pbiron, ramonopoly, talldanwp. Fixes #65992. git-svn-id: https://develop.svn.wordpress.org/trunk@63610 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-includes/class-wp-theme-json.php | 44 ++- .../styles/block-style-variation-pseudo.json | 26 ++ .../block-style-variation-responsive.json | 21 ++ .../block-supports/block-style-variations.php | 299 ++++++++++++++++++ .../tests/theme/wpThemeJsonResolver.php | 49 +++ 5 files changed, 438 insertions(+), 1 deletion(-) create mode 100644 tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-pseudo.json create mode 100644 tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-responsive.json diff --git a/src/wp-includes/class-wp-theme-json.php b/src/wp-includes/class-wp-theme-json.php index e91d547eb58f1..fb41bde81aa8c 100644 --- a/src/wp-includes/class-wp-theme-json.php +++ b/src/wp-includes/class-wp-theme-json.php @@ -1266,6 +1266,8 @@ protected static function do_opt_in_into_settings( &$context ) { * @since 5.9.0 Added the `$valid_block_names` and `$valid_element_name` parameters. * @since 6.3.0 Added the `$valid_variations` parameter. * @since 6.6.0 Updated schema to allow extended block style variations. + * @since 7.1.1 Updated schema to allow responsive breakpoint states and pseudo-selectors + * at the top level of `styles` for block style variation partials. * * @param array $input Structure to sanitize. * @param array $valid_block_names List of valid block names. @@ -1427,7 +1429,6 @@ protected static function sanitize( $input, $valid_block_names, $valid_element_n foreach ( array_keys( $responsive_media_queries ) as $breakpoint_state ) { $variation_schema[ $breakpoint_state ] = $styles_non_top_level; $variation_schema[ $breakpoint_state ]['elements'] = $schema_styles_elements; - $variation_schema[ $breakpoint_state ]['blocks'] = $schema_styles_blocks; if ( isset( static::VALID_BLOCK_PSEUDO_SELECTORS[ $block ] ) ) { foreach ( static::VALID_BLOCK_PSEUDO_SELECTORS[ $block ] as $pseudo_selector ) { @@ -1457,6 +1458,47 @@ protected static function sanitize( $input, $valid_block_names, $valid_element_n $schema['settings']['blocks'] = $schema_settings_blocks; $schema['settings']['typography']['fontFamilies'] = static::schema_in_root_and_per_origin( static::FONT_FAMILY_SCHEMA ); + /* + * Add block style variation states to the top-level styles schema. + * + * Block style variations defined in a standalone JSON partial within a + * theme's `styles` directory declare their styles at the root of the + * `styles` object, so they are sanitized against the top-level schema. + * It needs to allow the same states that are allowed for variations + * declared inline in theme.json, otherwise those states are silently + * removed as unknown keys. + * + * The `blockTypes` property is only present on block style variation + * partials, so it both identifies the config as a variation and + * determines which pseudo-selectors are valid for it. Regular + * theme.json files are unaffected. + */ + if ( ! empty( $input['blockTypes'] ) && is_array( $input['blockTypes'] ) ) { + $variation_pseudo_selectors = array(); + foreach ( $input['blockTypes'] as $variation_block_type ) { + if ( isset( static::VALID_BLOCK_PSEUDO_SELECTORS[ $variation_block_type ] ) ) { + $variation_pseudo_selectors = array_merge( + $variation_pseudo_selectors, + static::VALID_BLOCK_PSEUDO_SELECTORS[ $variation_block_type ] + ); + } + } + $variation_pseudo_selectors = array_unique( $variation_pseudo_selectors ); + + foreach ( array_keys( $responsive_media_queries ) as $breakpoint_state ) { + $schema['styles'][ $breakpoint_state ] = $styles_non_top_level; + $schema['styles'][ $breakpoint_state ]['elements'] = $schema_styles_elements; + + foreach ( $variation_pseudo_selectors as $pseudo_selector ) { + $schema['styles'][ $breakpoint_state ][ $pseudo_selector ] = $styles_non_top_level; + } + } + + foreach ( $variation_pseudo_selectors as $pseudo_selector ) { + $schema['styles'][ $pseudo_selector ] = $styles_non_top_level; + } + } + // Remove anything that's not present in the schema. foreach ( array( 'styles', 'settings' ) as $subtree ) { if ( ! isset( $input[ $subtree ] ) ) { diff --git a/tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-pseudo.json b/tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-pseudo.json new file mode 100644 index 0000000000000..14962fd679f9b --- /dev/null +++ b/tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-pseudo.json @@ -0,0 +1,26 @@ +{ + "version": 3, + "blockTypes": [ "core/navigation-link" ], + "slug": "pseudo-variation", + "title": "Pseudo Variation", + "styles": { + "color": { + "text": "red" + }, + ":hover": { + "color": { + "text": "blue" + } + }, + "@tablet": { + "color": { + "text": "green" + }, + ":hover": { + "color": { + "text": "purple" + } + } + } + } +} diff --git a/tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-responsive.json b/tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-responsive.json new file mode 100644 index 0000000000000..ef1750251aee3 --- /dev/null +++ b/tests/phpunit/data/themedir1/block-theme/styles/block-style-variation-responsive.json @@ -0,0 +1,21 @@ +{ + "version": 3, + "blockTypes": [ "core/preformatted" ], + "slug": "responsive-variation", + "title": "Responsive Variation", + "styles": { + "typography": { + "fontSize": "40px" + }, + "@tablet": { + "typography": { + "fontSize": "28px" + } + }, + "@mobile": { + "typography": { + "fontSize": "16px" + } + } + } +} diff --git a/tests/phpunit/tests/block-supports/block-style-variations.php b/tests/phpunit/tests/block-supports/block-style-variations.php index 0627820bd8d4d..3898178099e7e 100644 --- a/tests/phpunit/tests/block-supports/block-style-variations.php +++ b/tests/phpunit/tests/block-supports/block-style-variations.php @@ -247,6 +247,305 @@ public function test_block_style_variation_state_styles_use_custom_viewport_brea } } + /** + * Tests that responsive breakpoint styles defined in a standalone block style + * variation partial within a theme's `/styles` directory are preserved when + * the partial is sanitized. + * + * @ticket 65992 + * + * @covers WP_Theme_JSON_Resolver::get_style_variations + */ + public function test_block_style_variation_partial_retains_responsive_styles() { + switch_theme( 'block-theme' ); + + $variations = WP_Theme_JSON_Resolver::get_style_variations( 'block' ); + $actual = null; + + foreach ( $variations as $variation ) { + if ( isset( $variation['slug'] ) && 'responsive-variation' === $variation['slug'] ) { + $actual = $variation; + break; + } + } + + $this->assertNotNull( $actual, 'The responsive block style variation partial was not found.' ); + $this->assertSame( + array( 'fontSize' => '28px' ), + $actual['styles']['@tablet']['typography'] ?? null, + 'Tablet styles should be preserved when reading a block style variation partial.' + ); + $this->assertSame( + array( 'fontSize' => '16px' ), + $actual['styles']['@mobile']['typography'] ?? null, + 'Mobile styles should be preserved when reading a block style variation partial.' + ); + } + + /** + * Tests that responsive breakpoint styles defined in a standalone block style + * variation partial generate the expected media query CSS. + * + * @ticket 65992 + * + * @covers ::wp_render_block_style_variation_support_styles + */ + public function test_block_style_variation_partial_responsive_styles_generate_css() { + switch_theme( 'block-theme' ); + + try { + $parsed_block = array( + 'blockName' => 'core/preformatted', + 'attrs' => array( + 'className' => 'wp-block-preformatted is-style-responsive-variation', + ), + ); + + wp_render_block_style_variation_support_styles( $parsed_block ); + $inline_styles = wp_styles()->get_data( 'block-style-variation-styles', 'after' ); + $actual_stylesheet = is_array( $inline_styles ) ? implode( '', $inline_styles ) : ''; + + $this->assertStringContainsString( + '@media (480px < width <= 782px)', + $actual_stylesheet, + 'CSS should contain the tablet viewport media query.' + ); + $this->assertStringContainsString( + '@media (width <= 480px)', + $actual_stylesheet, + 'CSS should contain the mobile viewport media query.' + ); + } finally { + wp_deregister_style( 'block-style-variation-styles' ); + WP_Theme_JSON_Resolver::clean_cached_data(); + } + } + + /** + * Tests that pseudo-selector styles defined in a standalone block style + * variation partial are preserved when the partial is sanitized, both at + * the root of `styles` and within a responsive breakpoint state. + * + * @ticket 65992 + * + * @covers WP_Theme_JSON_Resolver::get_style_variations + */ + public function test_block_style_variation_partial_retains_pseudo_selector_styles() { + switch_theme( 'block-theme' ); + + $actual = null; + foreach ( WP_Theme_JSON_Resolver::get_style_variations( 'block' ) as $variation ) { + if ( isset( $variation['slug'] ) && 'pseudo-variation' === $variation['slug'] ) { + $actual = $variation; + break; + } + } + + $this->assertNotNull( $actual, 'The pseudo-selector block style variation partial was not found.' ); + $this->assertSame( + array( 'text' => 'blue' ), + $actual['styles'][':hover']['color'] ?? null, + 'Pseudo-selector styles should be preserved when reading a block style variation partial.' + ); + $this->assertSame( + array( 'text' => 'purple' ), + $actual['styles']['@tablet'][':hover']['color'] ?? null, + 'Pseudo-selector styles within a breakpoint state should be preserved.' + ); + } + + /** + * Tests that pseudo-selector styles defined in a standalone block style + * variation partial generate the expected CSS, including within a + * responsive breakpoint state. + * + * @ticket 65992 + * + * @covers ::wp_render_block_style_variation_support_styles + */ + public function test_block_style_variation_partial_pseudo_selector_styles_generate_css() { + switch_theme( 'block-theme' ); + + try { + $parsed_block = array( + 'blockName' => 'core/navigation-link', + 'attrs' => array( + 'className' => 'wp-block-navigation-link is-style-pseudo-variation', + ), + ); + + wp_render_block_style_variation_support_styles( $parsed_block ); + $inline_styles = wp_styles()->get_data( 'block-style-variation-styles', 'after' ); + $actual_stylesheet = is_array( $inline_styles ) ? implode( '', $inline_styles ) : ''; + + $this->assertStringContainsString( + ':hover', + $actual_stylesheet, + 'CSS should contain the pseudo-selector rule.' + ); + $this->assertStringContainsString( + 'blue', + $actual_stylesheet, + 'CSS should contain the pseudo-selector declaration value.' + ); + $this->assertStringContainsString( + 'purple', + $actual_stylesheet, + 'CSS should contain the pseudo-selector declaration value from the breakpoint state.' + ); + } finally { + wp_deregister_style( 'block-style-variation-styles' ); + WP_Theme_JSON_Resolver::clean_cached_data(); + } + } + + /** + * Tests that the block style variation states allowed at the root of a + * partial are not allowed at the root of a regular theme.json file, which + * has no `blockTypes` property. + * + * @ticket 65992 + * + * @covers WP_Theme_JSON::sanitize + */ + public function test_theme_json_root_styles_do_not_allow_variation_states() { + $theme_json = new WP_Theme_JSON( + array( + 'version' => WP_Theme_JSON::LATEST_SCHEMA, + 'styles' => array( + 'color' => array( 'text' => 'red' ), + '@tablet' => array( 'color' => array( 'text' => 'green' ) ), + ':hover' => array( 'color' => array( 'text' => 'blue' ) ), + ), + ) + ); + + $actual = $theme_json->get_raw_data()['styles']; + + $this->assertSame( + array( 'text' => 'red' ), + $actual['color'] ?? null, + 'Base root styles should be retained.' + ); + $this->assertArrayNotHasKey( + '@tablet', + $actual, + 'Responsive breakpoint states should not be allowed at the root of a regular theme.json.' + ); + $this->assertArrayNotHasKey( + ':hover', + $actual, + 'Pseudo-selectors should not be allowed at the root of a regular theme.json.' + ); + } + + /** + * Tests that `blocks` nested within a responsive breakpoint state is not + * retained for a block style variation partial, since that shape generates + * no CSS. The supported shape nests the breakpoint state within `blocks`. + * + * @ticket 65992 + * + * @covers WP_Theme_JSON::sanitize + */ + public function test_block_style_variation_partial_does_not_allow_blocks_within_breakpoint_state() { + $theme_json = new WP_Theme_JSON( + array( + 'version' => WP_Theme_JSON::LATEST_SCHEMA, + 'blockTypes' => array( 'core/group' ), + 'styles' => array( + 'blocks' => array( + 'core/heading' => array( + '@mobile' => array( + 'typography' => array( 'fontSize' => '18px' ), + ), + ), + ), + '@mobile' => array( + 'blocks' => array( + 'core/heading' => array( + 'typography' => array( 'fontSize' => '18px' ), + ), + ), + ), + ), + ) + ); + + $actual = $theme_json->get_raw_data()['styles']; + + $this->assertSame( + array( 'fontSize' => '18px' ), + $actual['blocks']['core/heading']['@mobile']['typography'] ?? null, + 'A breakpoint state nested within `blocks` should be retained.' + ); + $this->assertArrayNotHasKey( + 'blocks', + $actual['@mobile'] ?? array(), + '`blocks` nested within a breakpoint state should not be retained.' + ); + } + + /** + * Tests that `blocks` nested within a responsive breakpoint state is not + * retained for a block style variation declared inline in theme.json, + * matching the behaviour for variation partials. + * + * @ticket 65992 + * + * @covers WP_Theme_JSON::sanitize + */ + public function test_block_style_variation_does_not_allow_blocks_within_breakpoint_state() { + register_block_style( + 'core/group', + array( + 'name' => 'blocks-in-breakpoint', + 'label' => 'Blocks In Breakpoint', + ) + ); + + try { + $theme_json = new WP_Theme_JSON( + array( + 'version' => WP_Theme_JSON::LATEST_SCHEMA, + 'styles' => array( + 'blocks' => array( + 'core/group' => array( + 'variations' => array( + 'blocks-in-breakpoint' => array( + '@mobile' => array( + 'color' => array( 'text' => 'red' ), + 'blocks' => array( + 'core/heading' => array( + 'typography' => array( 'fontSize' => '18px' ), + ), + ), + ), + ), + ), + ), + ), + ), + ) + ); + + $variation = $theme_json->get_raw_data()['styles']['blocks']['core/group']['variations']['blocks-in-breakpoint'] ?? array(); + + $this->assertSame( + array( 'text' => 'red' ), + $variation['@mobile']['color'] ?? null, + 'Style properties within a breakpoint state should be retained.' + ); + $this->assertArrayNotHasKey( + 'blocks', + $variation['@mobile'] ?? array(), + '`blocks` nested within a breakpoint state should not be retained.' + ); + } finally { + unregister_block_style( 'core/group', 'blocks-in-breakpoint' ); + } + } + /** * Tests that block style variations resolve any `ref` values when generating styles. * diff --git a/tests/phpunit/tests/theme/wpThemeJsonResolver.php b/tests/phpunit/tests/theme/wpThemeJsonResolver.php index ce5609a396f18..539fb8cd7f682 100644 --- a/tests/phpunit/tests/theme/wpThemeJsonResolver.php +++ b/tests/phpunit/tests/theme/wpThemeJsonResolver.php @@ -1170,6 +1170,55 @@ public function data_get_style_variations() { ), ), ), + // @ticket 65992 + array( + 'blockTypes' => array( 'core/navigation-link' ), + 'version' => 3, + 'slug' => 'pseudo-variation', + 'title' => 'Pseudo Variation', + 'styles' => array( + 'color' => array( + 'text' => 'red', + ), + ':hover' => array( + 'color' => array( + 'text' => 'blue', + ), + ), + '@tablet' => array( + 'color' => array( + 'text' => 'green', + ), + ':hover' => array( + 'color' => array( + 'text' => 'purple', + ), + ), + ), + ), + ), + // @ticket 65992 + array( + 'blockTypes' => array( 'core/preformatted' ), + 'version' => 3, + 'slug' => 'responsive-variation', + 'title' => 'Responsive Variation', + 'styles' => array( + 'typography' => array( + 'fontSize' => '40px', + ), + '@tablet' => array( + 'typography' => array( + 'fontSize' => '28px', + ), + ), + '@mobile' => array( + 'typography' => array( + 'fontSize' => '16px', + ), + ), + ), + ), // @ticket 61440 array( 'blockTypes' => array( 'core/group', 'core/columns' ), From 6d7dc473e3b0ab1c07940c4699cc051196f9ee41 Mon Sep 17 00:00:00 2001 From: ramonopoly Date: Mon, 14 Sep 2026 02:16:55 +0000 Subject: [PATCH 220/363] Code Quality: Update PHPStan baseline MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit r63607 changed two `WP_Query::$posts` assignments to `??=`. PHPStan level 5 accepts the resulting union type, so those two `assign.propertyType` errors disappear and the baseline's `count: 2` entries fail with `ignore.count`. Both counts should be 1. The mismatches remain; level 7 still reports them. Developed in: https://github.com/WordPress/wordpress-develop/pull/13506 Props ramonopoly, westonruter. Follow-up to [65823]. git-svn-id: https://develop.svn.wordpress.org/trunk@63611 602fd350-edb4-49c9-b593-d223f7449a82 --- tests/phpstan/baselines/assign.propertyType.neon | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/phpstan/baselines/assign.propertyType.neon b/tests/phpstan/baselines/assign.propertyType.neon index 97c3032b91309..be2401759f2c8 100644 --- a/tests/phpstan/baselines/assign.propertyType.neon +++ b/tests/phpstan/baselines/assign.propertyType.neon @@ -36,12 +36,12 @@ parameters: - message: '#^Property WP_Query\:\:\$posts \(array\\|null\) does not accept list\\|null\.$#' identifier: assign.propertyType - count: 2 + count: 1 path: ../../../src/wp-includes/class-wp-query.php - message: '#^Property WP_Query\:\:\$posts \(array\\|null\) does not accept list\\.$#' identifier: assign.propertyType - count: 2 + count: 1 path: ../../../src/wp-includes/class-wp-query.php - message: '#^Property WP_Rewrite\:\:\$rules \(array\\) does not accept string\.$#' From ba9d19e41ef42a3ec5e7dd611329f91f1ad871e8 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Mon, 14 Sep 2026 09:12:31 +0000 Subject: [PATCH 221/363] Media: Fix accessibility violations reported by Axe-core. - Fixes the labelling of the media modal dialog. - Fixes the semantics of the attachments browser list: given each attachment has a role=checkbox, the list itself must have a role=group. Developed in https://github.com/WordPress/wordpress-develop/pull/13368 Props khokansardar, arkaprabhachowdhury, afercia. Fixes #66025. git-svn-id: https://develop.svn.wordpress.org/trunk@63612 602fd350-edb4-49c9-b593-d223f7449a82 --- src/js/media/views/attachments.js | 1 + src/js/media/views/media-frame.js | 4 +++- src/js/media/views/modal.js | 7 ++++++- src/wp-includes/media-template.php | 4 ++-- 4 files changed, 12 insertions(+), 4 deletions(-) diff --git a/src/js/media/views/attachments.js b/src/js/media/views/attachments.js index 5b8d91426c38c..a4712eab01497 100644 --- a/src/js/media/views/attachments.js +++ b/src/js/media/views/attachments.js @@ -8,6 +8,7 @@ Attachments = View.extend(/** @lends wp.media.view.Attachments.prototype */{ className: 'attachments', attributes: { + role: 'group', tabIndex: -1 }, diff --git a/src/js/media/views/media-frame.js b/src/js/media/views/media-frame.js index 99dfc675729da..4cc645ff908fd 100644 --- a/src/js/media/views/media-frame.js +++ b/src/js/media/views/media-frame.js @@ -164,9 +164,11 @@ MediaFrame = Frame.extend(/** @lends wp.media.view.MediaFrame.prototype */{ * @this wp.media.controller.Region */ createTitle: function( title ) { + // A modal's dialog element points `aria-labelledby` at its frame heading. title.view = new wp.media.View({ controller: this, - tagName: 'h1' + tagName: 'h1', + attributes: this.modal ? { id: this.modal.titleId } : {} }); }, /** diff --git a/src/js/media/views/modal.js b/src/js/media/views/modal.js index 42f8da3c5024a..629329ed88789 100644 --- a/src/js/media/views/modal.js +++ b/src/js/media/views/modal.js @@ -32,6 +32,8 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ hasCloseButton: true }); + this.titleId = _.uniqueId( 'media-frame-title-' ); + this.focusManager = new wp.media.view.FocusManager({ el: this.el }); @@ -39,12 +41,15 @@ Modal = wp.media.View.extend(/** @lends wp.media.view.Modal.prototype */{ /** * Prepares the data for the modal template. * + * @since 7.2.0 Added the `titleId` property. + * * @return {Object} The prepared data. */ prepare: function() { return { title: this.options.title, - hasCloseButton: this.options.hasCloseButton + hasCloseButton: this.options.hasCloseButton, + titleId: this.titleId }; }, diff --git a/src/wp-includes/media-template.php b/src/wp-includes/media-template.php index 460cf3b3020e5..70e75e0d28567 100644 --- a/src/wp-includes/media-template.php +++ b/src/wp-includes/media-template.php @@ -178,7 +178,7 @@ function wp_print_media_templates() { +#errors #document | | @@ -903,6 +1015,7 @@ there=1?> #data +#errors #document | | @@ -912,6 +1025,7 @@ there=1?> #data +#errors #document | | @@ -920,6 +1034,7 @@ there=1?> #data +#errors #document | | @@ -928,6 +1043,7 @@ there=1?> #data +#errors #document | | @@ -936,6 +1052,7 @@ there=1?> #data +#errors #document | | @@ -944,6 +1061,7 @@ there=1?> #data +#errors #document | | @@ -952,6 +1070,7 @@ there=1?> #data +#errors #document | | @@ -960,6 +1079,7 @@ there=1?> #data +#errors #document | | @@ -970,6 +1090,7 @@ there=1?> #data +#errors #document | | @@ -979,6 +1100,7 @@ there=1?> #data <?something> +#errors #document | | @@ -988,6 +1110,7 @@ there=1?> #data