From 56241e937a875abeab1b2a55476bb1377e72f045 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 18:19:47 -0700 Subject: [PATCH 001/151] fix(handle_error.py): don't return backend exception to user - can contain prompt leakage Fixes https://github.com/BerriAI/litellm/issues/13329 --- litellm/router_utils/handle_error.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/litellm/router_utils/handle_error.py b/litellm/router_utils/handle_error.py index ba12e1cbed..c61a97a9b7 100644 --- a/litellm/router_utils/handle_error.py +++ b/litellm/router_utils/handle_error.py @@ -82,9 +82,14 @@ async def async_raise_no_deployment_exception( litellm_router_instance=litellm_router_instance, parent_otel_span=parent_otel_span, ) + verbose_router_logger.info( + f"No deployment found for model: {model}, cooldown_list with debug info: {_cooldown_list}" + ) + + cooldown_list_ids = [cooldown_model[0] for cooldown_model in _cooldown_list] return RouterRateLimitError( model=model, cooldown_time=_cooldown_time, enable_pre_call_checks=litellm_router_instance.enable_pre_call_checks, - cooldown_list=_cooldown_list, + cooldown_list=cooldown_list_ids, ) From dab3acdd26dcd48d16e8e8430a9b67e4dca923e2 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 18:25:30 -0700 Subject: [PATCH 002/151] fix(handle_error.py): add unit tests --- litellm/router_utils/handle_error.py | 2 +- .../test_router_handle_error.py | 145 ++++++++++++++++++ 2 files changed, 146 insertions(+), 1 deletion(-) diff --git a/litellm/router_utils/handle_error.py b/litellm/router_utils/handle_error.py index c61a97a9b7..63231923f1 100644 --- a/litellm/router_utils/handle_error.py +++ b/litellm/router_utils/handle_error.py @@ -86,7 +86,7 @@ async def async_raise_no_deployment_exception( f"No deployment found for model: {model}, cooldown_list with debug info: {_cooldown_list}" ) - cooldown_list_ids = [cooldown_model[0] for cooldown_model in _cooldown_list] + cooldown_list_ids = [cooldown_model[0] for cooldown_model in (_cooldown_list or [])] return RouterRateLimitError( model=model, cooldown_time=_cooldown_time, diff --git a/tests/router_unit_tests/test_router_handle_error.py b/tests/router_unit_tests/test_router_handle_error.py index 39b9814ccc..660b388512 100644 --- a/tests/router_unit_tests/test_router_handle_error.py +++ b/tests/router_unit_tests/test_router_handle_error.py @@ -1,6 +1,7 @@ import sys, os, time import traceback, asyncio import pytest +from typing import List sys.path.insert( 0, os.path.abspath("../..") @@ -111,3 +112,147 @@ async def test_send_llm_exception_alert_when_proxy_server_request_in_kwargs(): # Assert that no exception was raised and the function completed successfully mock_router.slack_alerting_logger.send_alert.assert_not_called() + + +@pytest.mark.asyncio +async def test_async_raise_no_deployment_exception(): + """ + Test that async_raise_no_deployment_exception returns a RouterRateLimitError + with cooldown_list containing just IDs (not tuples with debug info). + """ + from litellm.router_utils.handle_error import async_raise_no_deployment_exception + from litellm.types.router import RouterRateLimitError + from unittest.mock import patch + + # Create a mock LitellmRouter instance + mock_router = MagicMock() + mock_router.get_model_ids.return_value = ["deployment-1", "deployment-2"] + mock_router.cooldown_cache.get_min_cooldown.return_value = 30.0 + mock_router.enable_pre_call_checks = True + + # Mock the _async_get_cooldown_deployments_with_debug_info function + # It should return a list of tuples where each tuple contains (model_id, debug_info) + mock_cooldown_list = [ + ("deployment-1", {"error": "rate_limit", "time": "2024-01-01"}), + ("deployment-2", {"error": "server_error", "time": "2024-01-01"}), + ("deployment-3", {"error": "timeout", "time": "2024-01-01"}), + ] + + with patch( + "litellm.router_utils.handle_error._async_get_cooldown_deployments_with_debug_info", + return_value=mock_cooldown_list, + ): + # Call the function + result = await async_raise_no_deployment_exception( + litellm_router_instance=mock_router, + model="gpt-3.5-turbo", + parent_otel_span=None, + ) + + # Assert that the function returns a RouterRateLimitError + assert isinstance(result, RouterRateLimitError) + + # Assert that the error has the correct properties + assert result.model == "gpt-3.5-turbo" + assert result.cooldown_time == 30.0 + assert result.enable_pre_call_checks is True + + # Assert that cooldown_list contains only IDs (extracted from tuples) + expected_cooldown_list = ["deployment-1", "deployment-2", "deployment-3"] + assert result.cooldown_list == expected_cooldown_list + + # Verify that cooldown_list contains only strings (IDs), not tuples + for item in result.cooldown_list: + assert isinstance(item, str), f"Expected string ID, got {type(item)}: {item}" + + # Verify mock calls + mock_router.get_model_ids.assert_called_once_with(model_name="gpt-3.5-turbo") + mock_router.cooldown_cache.get_min_cooldown.assert_called_once_with( + model_ids=["deployment-1", "deployment-2"], parent_otel_span=None + ) + + +@pytest.mark.asyncio +async def test_async_raise_no_deployment_exception_empty_cooldown_list(): + """ + Test that async_raise_no_deployment_exception handles empty cooldown list correctly. + """ + from litellm.router_utils.handle_error import async_raise_no_deployment_exception + from litellm.types.router import RouterRateLimitError + from unittest.mock import patch + + # Create a mock LitellmRouter instance + mock_router = MagicMock() + mock_router.get_model_ids.return_value = ["deployment-1", "deployment-2"] + mock_router.cooldown_cache.get_min_cooldown.return_value = 15.0 + mock_router.enable_pre_call_checks = False + + # Mock empty cooldown list + mock_cooldown_list: List = [] + + with patch( + "litellm.router_utils.handle_error._async_get_cooldown_deployments_with_debug_info", + return_value=mock_cooldown_list, + ): + # Call the function + result = await async_raise_no_deployment_exception( + litellm_router_instance=mock_router, + model="claude-3-sonnet", + parent_otel_span=None, + ) + + # Assert that the function returns a RouterRateLimitError + assert isinstance(result, RouterRateLimitError) + + # Assert that the error has the correct properties + assert result.model == "claude-3-sonnet" + assert result.cooldown_time == 15.0 + assert result.enable_pre_call_checks is False + + # Assert that cooldown_list is an empty list when no cooldowns exist + assert result.cooldown_list == [] + assert isinstance(result.cooldown_list, list) + + +@pytest.mark.asyncio +async def test_async_raise_no_deployment_exception_none_cooldown_list(): + """ + Test that async_raise_no_deployment_exception handles None cooldown list correctly. + Note: In practice, _async_get_cooldown_deployments_with_debug_info should never return None + based on the implementation, but this tests defensive programming. + """ + from litellm.router_utils.handle_error import async_raise_no_deployment_exception + from litellm.types.router import RouterRateLimitError + from unittest.mock import patch + + # Create a mock LitellmRouter instance + mock_router = MagicMock() + mock_router.get_model_ids.return_value = [] + mock_router.cooldown_cache.get_min_cooldown.return_value = 45.0 + mock_router.enable_pre_call_checks = True + + # Mock None cooldown list (though this shouldn't happen in practice) + mock_cooldown_list = None + + with patch( + "litellm.router_utils.handle_error._async_get_cooldown_deployments_with_debug_info", + return_value=mock_cooldown_list, + ): + # After the defensive fix, this should handle None gracefully and return empty list + result = await async_raise_no_deployment_exception( + litellm_router_instance=mock_router, + model="gpt-4", + parent_otel_span=None, + ) + + # Assert that the function returns a RouterRateLimitError + assert isinstance(result, RouterRateLimitError) + + # Assert that the error has the correct properties + assert result.model == "gpt-4" + assert result.cooldown_time == 45.0 + assert result.enable_pre_call_checks is True + + # Assert that cooldown_list is an empty list when cooldown_list is None + assert result.cooldown_list == [] + assert isinstance(result.cooldown_list, list) From bc9d0484e4946532aeab9cc34204a9897f10ab52 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 18:37:57 -0700 Subject: [PATCH 003/151] fix(cooldown_cache.py): mask error string to avoid leaking sensitive prompt data Fixes https://github.com/BerriAI/litellm/issues/13329 --- .../sensitive_data_masker.py | 7 +- litellm/router_utils/cooldown_cache.py | 11 +- litellm/router_utils/cooldown_handlers.py | 20 +- .../router_utils/test_cooldown_cache.py | 257 ++++++++++++++++++ 4 files changed, 283 insertions(+), 12 deletions(-) create mode 100644 tests/test_litellm/router_utils/test_cooldown_cache.py diff --git a/litellm/litellm_core_utils/sensitive_data_masker.py b/litellm/litellm_core_utils/sensitive_data_masker.py index 900239602d..07f652ecb9 100644 --- a/litellm/litellm_core_utils/sensitive_data_masker.py +++ b/litellm/litellm_core_utils/sensitive_data_masker.py @@ -33,7 +33,12 @@ class SensitiveDataMasker: value_str = str(value) masked_length = len(value_str) - (self.visible_prefix + self.visible_suffix) - return f"{value_str[:self.visible_prefix]}{self.mask_char * masked_length}{value_str[-self.visible_suffix:]}" + + # Handle the case where visible_suffix is 0 to avoid showing the entire string + if self.visible_suffix == 0: + return f"{value_str[:self.visible_prefix]}{self.mask_char * masked_length}" + else: + return f"{value_str[:self.visible_prefix]}{self.mask_char * masked_length}{value_str[-self.visible_suffix:]}" def is_sensitive_key(self, key: str) -> bool: key_lower = str(key).lower() diff --git a/litellm/router_utils/cooldown_cache.py b/litellm/router_utils/cooldown_cache.py index d987ab9444..0a199d4b75 100644 --- a/litellm/router_utils/cooldown_cache.py +++ b/litellm/router_utils/cooldown_cache.py @@ -8,6 +8,7 @@ from typing import TYPE_CHECKING, Any, List, Optional, Tuple, TypedDict, Union from litellm import verbose_logger from litellm.caching.caching import DualCache from litellm.caching.in_memory_cache import InMemoryCache +from litellm.litellm_core_utils.sensitive_data_masker import SensitiveDataMasker if TYPE_CHECKING: from opentelemetry.trace import Span as _Span @@ -29,6 +30,12 @@ class CooldownCache: self.cache = cache self.default_cooldown_time = default_cooldown_time self.in_memory_cache = InMemoryCache() + # Initialize the masker with custom settings for exception strings + self.exception_masker = SensitiveDataMasker( + visible_prefix=50, # Show first 50 characters + visible_suffix=0, # Show last 0 characters + mask_char="*", # Use * for masking + ) def _common_add_cooldown_logic( self, model_id: str, original_exception, exception_status, cooldown_time: float @@ -39,7 +46,9 @@ class CooldownCache: # Store the cooldown information for the deployment separately cooldown_data = CooldownCacheValue( - exception_received=str(original_exception), + exception_received=self.exception_masker._mask_value( + str(original_exception) + ), status_code=str(exception_status), timestamp=current_time, cooldown_time=cooldown_time, diff --git a/litellm/router_utils/cooldown_handlers.py b/litellm/router_utils/cooldown_handlers.py index 101159ad12..88bf1c0b27 100644 --- a/litellm/router_utils/cooldown_handlers.py +++ b/litellm/router_utils/cooldown_handlers.py @@ -118,16 +118,16 @@ def _should_run_cooldown_logic( "Should Not Run Cooldown Logic: deployment id is none or model group can't be found." ) return False - + ######################################################### # If time_to_cooldown is 0 or 0.0000000, don't run cooldown logic ######################################################### if time_to_cooldown is not None and math.isclose( - a=time_to_cooldown, - b=0.0, - abs_tol=1e-9 + a=time_to_cooldown, b=0.0, abs_tol=1e-9 ): - verbose_router_logger.debug("Should Not Run Cooldown Logic: time_to_cooldown is effectively 0") + verbose_router_logger.debug( + "Should Not Run Cooldown Logic: time_to_cooldown is effectively 0" + ) return False if litellm_router_instance.disable_cooldowns: @@ -275,8 +275,8 @@ def _set_cooldown_deployments( if ( _should_run_cooldown_logic( litellm_router_instance=litellm_router_instance, - deployment=deployment, - exception_status=exception_status, + deployment=deployment, + exception_status=exception_status, original_exception=original_exception, time_to_cooldown=time_to_cooldown, ) @@ -290,9 +290,9 @@ def _set_cooldown_deployments( verbose_router_logger.debug(f"Attempting to add {deployment} to cooldown list") if _should_cooldown_deployment( - litellm_router_instance=litellm_router_instance, - deployment=deployment, - exception_status=exception_status, + litellm_router_instance=litellm_router_instance, + deployment=deployment, + exception_status=exception_status, original_exception=original_exception, ): litellm_router_instance.cooldown_cache.add_deployment_to_cooldown( diff --git a/tests/test_litellm/router_utils/test_cooldown_cache.py b/tests/test_litellm/router_utils/test_cooldown_cache.py new file mode 100644 index 0000000000..52fe151eff --- /dev/null +++ b/tests/test_litellm/router_utils/test_cooldown_cache.py @@ -0,0 +1,257 @@ +""" +Unit tests for CooldownCache exception masking functionality +""" + +import os +import sys +from unittest.mock import MagicMock + +import pytest + +# Add the parent directory to the system path +sys.path.insert(0, os.path.abspath("../../..")) + +from litellm.caching.dual_cache import DualCache +from litellm.caching.in_memory_cache import InMemoryCache +from litellm.litellm_core_utils.sensitive_data_masker import SensitiveDataMasker +from litellm.router_utils.cooldown_cache import CooldownCache, CooldownCacheValue + + +class TestCooldownCacheExceptionMasking: + """Test suite for CooldownCache exception masking functionality""" + + @pytest.fixture + def cooldown_cache(self): + """Create a CooldownCache instance for testing""" + mock_dual_cache = MagicMock(spec=DualCache) + return CooldownCache(cache=mock_dual_cache, default_cooldown_time=60.0) + + def test_exception_masker_initialization(self, cooldown_cache): + """Test that the exception masker is properly initialized""" + assert isinstance(cooldown_cache.exception_masker, SensitiveDataMasker) + assert cooldown_cache.exception_masker.visible_prefix == 50 + assert cooldown_cache.exception_masker.visible_suffix == 0 + assert cooldown_cache.exception_masker.mask_char == "*" + + def test_short_exception_string_not_masked(self, cooldown_cache): + """Test that short exception strings are not masked""" + short_exception = "Short error" + model_id = "test-model" + exception_status = 500 + cooldown_time = 30.0 + + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=Exception(short_exception), + exception_status=exception_status, + cooldown_time=cooldown_time, + ) + + # Short exception should not be masked + assert cooldown_data["exception_received"] == short_exception + assert cooldown_key == f"deployment:{model_id}:cooldown" + + def test_long_exception_string_masked(self, cooldown_cache): + """Test that long exception strings are properly masked""" + # Create a long exception string that simulates prompt leakage + long_exception = ( + "litellm.proxy.proxy_server._handle_llm_api_exception(): Exception occurred - " + "No deployments available for selected model, Try again in 5 seconds. " + "Passed model=anthropic_claude_sonnet_4_v1_0. pre-call-checks=False, " + "cooldown_list=[('deepseek_r1-eastus', {'exception_received': " + "'litellm.RateLimitError: RateLimitError: Azure_aiException - " + '{"error":{"code":"Invalid input","status":422,"message":"invalid input error",' + '"details":[{"type":"model_attributes_type","loc":["body"],' + '"msg":"Tell me a story about a dragon and a princess in a magical kingdom ' + "where the dragon is actually protecting the princess from an evil wizard " + 'who wants to steal her magical powers and use them to conquer the world"}]}' + ) + + model_id = "test-model" + exception_status = 429 + cooldown_time = 60.0 + + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=Exception(long_exception), + exception_status=exception_status, + cooldown_time=cooldown_time, + ) + + masked_exception = cooldown_data["exception_received"] + + # Should start with first 50 characters + assert masked_exception.startswith(long_exception[:50]) + + # Should contain masking characters + assert "*" in masked_exception + + # Should be same length (prefix + asterisks) + assert len(masked_exception) == len(long_exception) + + # Should not contain the sensitive prompt content + assert "Tell me a story about a dragon" not in masked_exception + assert "magical kingdom" not in masked_exception + + # Should preserve the error type information at the beginning (first 50 chars) + assert masked_exception.startswith( + "litellm.proxy.proxy_server._handle_llm_api_excepti" + ) + + def test_exception_with_api_keys_masked(self, cooldown_cache): + """Test that API keys in exceptions are properly masked""" + exception_with_key = ( + "Authentication failed with api_key=sk-1234567890abcdefghijklmnopqrstuvwxyz " + "and token=bearer_token_123456789 for model gpt-4" + ) + + model_id = "test-model" + exception_status = 401 + cooldown_time = 30.0 + + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=Exception(exception_with_key), + exception_status=exception_status, + cooldown_time=cooldown_time, + ) + + masked_exception = cooldown_data["exception_received"] + + # Should mask the sensitive content while preserving structure + assert masked_exception.startswith( + "Authentication failed with api_key=sk-12345678" + ) + assert "*" in masked_exception + assert len(masked_exception) == len(exception_with_key) + + def test_cooldown_data_structure(self, cooldown_cache): + """Test that the cooldown data structure is correctly formed""" + exception_msg = "Test exception for structure validation" + model_id = "test-model" + exception_status = 500 + cooldown_time = 45.0 + + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=Exception(exception_msg), + exception_status=exception_status, + cooldown_time=cooldown_time, + ) + + # Verify cooldown data structure + assert isinstance(cooldown_data, dict) + assert "exception_received" in cooldown_data + assert "status_code" in cooldown_data + assert "timestamp" in cooldown_data + assert "cooldown_time" in cooldown_data + + # Verify data types + assert isinstance(cooldown_data["exception_received"], str) + assert isinstance(cooldown_data["status_code"], str) + assert isinstance(cooldown_data["timestamp"], float) + assert isinstance(cooldown_data["cooldown_time"], float) + + # Verify values + assert cooldown_data["status_code"] == str(exception_status) + assert cooldown_data["cooldown_time"] == cooldown_time + assert cooldown_data["exception_received"] == exception_msg + + def test_exception_object_conversion(self, cooldown_cache): + """Test that different exception types are properly converted to strings""" + # Test with different exception types + exceptions = [ + ValueError("Invalid value provided"), + KeyError("Missing required key"), + RuntimeError("Runtime error occurred"), + Exception("Generic exception"), + ] + + for exc in exceptions: + model_id = f"test-model-{exc.__class__.__name__}" + + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=exc, + exception_status=500, + cooldown_time=30.0, + ) + + # Should successfully convert exception to string + assert isinstance(cooldown_data["exception_received"], str) + assert ( + str(exc) == cooldown_data["exception_received"] + ) # Short exceptions not masked + + def test_masking_preserves_error_debugging_info(self, cooldown_cache): + """Test that masking preserves essential debugging information""" + debugging_exception = ( + "RateLimitError: Rate limit exceeded for model gpt-4. " + "Current usage: 1000 tokens/minute. Limit: 500 tokens/minute. " + "Request details: model=gpt-4, user_id=user123, " + "prompt='Write a comprehensive analysis of the economic implications " + "of artificial intelligence adoption in the healthcare sector, including " + "potential cost savings, job displacement, and regulatory challenges'" + ) + + model_id = "gpt-4-deployment" + exception_status = 429 + cooldown_time = 120.0 + + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=Exception(debugging_exception), + exception_status=exception_status, + cooldown_time=cooldown_time, + ) + + masked_exception = cooldown_data["exception_received"] + + # Should preserve error type and initial debugging info (first 50 chars) + assert masked_exception.startswith( + "RateLimitError: Rate limit exceeded for model gpt-" + ) + + # Should mask the prompt content + assert "Write a comprehensive analysis" not in masked_exception + assert "healthcare sector" not in masked_exception + + # Should contain masking indicator + assert "*" in masked_exception + + def test_error_handling_in_common_add_cooldown_logic(self, cooldown_cache): + """Test error handling in the _common_add_cooldown_logic method""" + # This test ensures that edge cases are properly handled + model_id = "test-model" + + # Test with None exception (edge case) - should be handled gracefully + cooldown_key, cooldown_data = cooldown_cache._common_add_cooldown_logic( + model_id=model_id, + original_exception=None, + exception_status=500, + cooldown_time=30.0, + ) + + # Should handle None by converting to string + assert cooldown_data["exception_received"] == "None" + assert cooldown_key == f"deployment:{model_id}:cooldown" + + def test_custom_masker_settings(self): + """Test that custom masker settings work correctly""" + mock_dual_cache = MagicMock(spec=DualCache) + + # Create cooldown cache and verify default settings + cache = CooldownCache(cache=mock_dual_cache, default_cooldown_time=60.0) + + # Test that we can access and verify the masker configuration + assert cache.exception_masker.visible_prefix == 50 + assert cache.exception_masker.visible_suffix == 0 + assert cache.exception_masker.mask_char == "*" + + # Test masking behavior with these settings + long_string = "A" * 100 # 100 character string + masked = cache.exception_masker._mask_value(long_string) + + # Should show first 50 characters, then all asterisks + expected = "A" * 50 + "*" * 50 + assert masked == expected From ca642d32e11ebae998967ab64dd09a7c8fd5b997 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 22:53:45 -0700 Subject: [PATCH 004/151] fix(azure/common_utils.py): add default api version for openai responses api calls --- litellm/constants.py | 3 ++ litellm/llms/azure/common_utils.py | 62 +++++++++++++++++------------- 2 files changed, 38 insertions(+), 27 deletions(-) diff --git a/litellm/constants.py b/litellm/constants.py index 18f384b4ff..8d502afaf2 100644 --- a/litellm/constants.py +++ b/litellm/constants.py @@ -1,6 +1,9 @@ import os from typing import List, Literal +AZURE_DEFAULT_RESPONSES_API_VERSION = str( + os.getenv("AZURE_DEFAULT_RESPONSES_API_VERSION", "2025-04-01-preview") +) ROUTER_MAX_FALLBACKS = int(os.getenv("ROUTER_MAX_FALLBACKS", 5)) DEFAULT_BATCH_SIZE = int(os.getenv("DEFAULT_BATCH_SIZE", 512)) DEFAULT_FLUSH_INTERVAL_SECONDS = int(os.getenv("DEFAULT_FLUSH_INTERVAL_SECONDS", 5)) diff --git a/litellm/llms/azure/common_utils.py b/litellm/llms/azure/common_utils.py index 94abd2f814..8581339d88 100644 --- a/litellm/llms/azure/common_utils.py +++ b/litellm/llms/azure/common_utils.py @@ -365,14 +365,16 @@ def get_azure_ad_token( azure_ad_token_provider = get_azure_ad_token_provider(azure_scope=scope) except ValueError: verbose_logger.debug("Azure AD Token Provider could not be used.") - + ######################################################### # If litellm.enable_azure_ad_token_refresh is True and no other token provider is available, # try to get DefaultAzureCredential provider ######################################################### if azure_ad_token_provider is None and azure_ad_token is None: - azure_ad_token_provider = BaseAzureLLM._try_get_default_azure_credential_provider( - scope=scope, + azure_ad_token_provider = ( + BaseAzureLLM._try_get_default_azure_credential_provider( + scope=scope, + ) ) # Execute the token provider to get the token if available @@ -403,27 +405,27 @@ class BaseAzureLLM(BaseOpenAILLM): ) -> Optional[Callable[[], str]]: """ Try to get DefaultAzureCredential provider - + Args: scope: Azure scope for the token - + Returns: Token provider callable if DefaultAzureCredential is enabled and available, None otherwise """ from litellm.types.secret_managers.get_azure_ad_token_provider import ( AzureCredentialType, ) - - verbose_logger.debug( - "Attempting to use DefaultAzureCredential for Azure Auth" - ) - + + verbose_logger.debug("Attempting to use DefaultAzureCredential for Azure Auth") + try: azure_ad_token_provider = get_azure_ad_token_provider( azure_scope=scope, azure_credential=AzureCredentialType.DefaultAzureCredential, ) - verbose_logger.debug("Successfully obtained Azure AD token provider using DefaultAzureCredential") + verbose_logger.debug( + "Successfully obtained Azure AD token provider using DefaultAzureCredential" + ) return azure_ad_token_provider except Exception as e: verbose_logger.debug(f"DefaultAzureCredential failed: {str(e)}") @@ -656,17 +658,17 @@ class BaseAzureLLM(BaseOpenAILLM): else: client = AzureOpenAI(**azure_client_params) # type: ignore return client - + @staticmethod def _base_validate_azure_environment( - headers: dict, litellm_params: Optional[GenericLiteLLMParams] + headers: dict, litellm_params: Optional[GenericLiteLLMParams] ) -> dict: litellm_params = litellm_params or GenericLiteLLMParams() - + # If api-key is already in headers, preserve it if "api-key" in headers: return headers - + api_key = ( litellm_params.api_key or litellm.api_key @@ -686,13 +688,15 @@ class BaseAzureLLM(BaseOpenAILLM): headers["Authorization"] = f"Bearer {azure_ad_token}" return headers - + @staticmethod def _get_base_azure_url( api_base: Optional[str], litellm_params: Optional[Union[GenericLiteLLMParams, Dict[str, Any]]], - route: Literal["/openai/responses", "/openai/vector_stores"] + route: Literal["/openai/responses", "/openai/vector_stores"], ) -> str: + from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION + api_base = api_base or litellm.api_base or get_secret_str("AZURE_API_BASE") if api_base is None: raise ValueError( @@ -702,35 +706,39 @@ class BaseAzureLLM(BaseOpenAILLM): # Extract api_version or use default litellm_params = litellm_params or {} - api_version = cast(Optional[str], litellm_params.get("api_version")) + api_version = ( + cast(Optional[str], litellm_params.get("api_version")) + or AZURE_DEFAULT_RESPONSES_API_VERSION + ) # Create a new dictionary with existing params query_params = dict(original_url.params) # Add api_version if needed - if "api-version" not in query_params and api_version: + if "api-version" not in query_params: query_params["api-version"] = api_version - + # Add the path to the base URL if route not in api_base: - new_url = _add_path_to_api_base( - api_base=api_base, ending_path=route - ) + new_url = _add_path_to_api_base(api_base=api_base, ending_path=route) else: new_url = api_base - + if BaseAzureLLM._is_azure_v1_api_version(api_version): # ensure the request go to /openai/v1 and not just /openai if "/openai/v1" not in new_url: parsed_url = httpx.URL(new_url) - new_url = str(parsed_url.copy_with(path=parsed_url.path.replace("/openai", "/openai/v1"))) - + new_url = str( + parsed_url.copy_with( + path=parsed_url.path.replace("/openai", "/openai/v1") + ) + ) # Use the new query_params dictionary final_url = httpx.URL(new_url).copy_with(params=query_params) return str(final_url) - + @staticmethod def _is_azure_v1_api_version(api_version: Optional[str]) -> bool: if api_version is None: From 72c7e82ef814ad2422ea09d4f5f8665fd6ce1794 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 22:54:44 -0700 Subject: [PATCH 005/151] fix(azure/common_utils.py): generify api version logic --- litellm/llms/azure/common_utils.py | 5 +++-- litellm/llms/azure/responses/transformation.py | 7 ++++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/litellm/llms/azure/common_utils.py b/litellm/llms/azure/common_utils.py index 8581339d88..5764fcdd1b 100644 --- a/litellm/llms/azure/common_utils.py +++ b/litellm/llms/azure/common_utils.py @@ -694,6 +694,7 @@ class BaseAzureLLM(BaseOpenAILLM): api_base: Optional[str], litellm_params: Optional[Union[GenericLiteLLMParams, Dict[str, Any]]], route: Literal["/openai/responses", "/openai/vector_stores"], + default_api_version: Optional[str] = None, ) -> str: from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION @@ -708,14 +709,14 @@ class BaseAzureLLM(BaseOpenAILLM): litellm_params = litellm_params or {} api_version = ( cast(Optional[str], litellm_params.get("api_version")) - or AZURE_DEFAULT_RESPONSES_API_VERSION + or default_api_version ) # Create a new dictionary with existing params query_params = dict(original_url.params) # Add api_version if needed - if "api-version" not in query_params: + if "api-version" not in query_params and api_version: query_params["api-version"] = api_version # Add the path to the base URL diff --git a/litellm/llms/azure/responses/transformation.py b/litellm/llms/azure/responses/transformation.py index e3d37c8a15..063d1af9c3 100644 --- a/litellm/llms/azure/responses/transformation.py +++ b/litellm/llms/azure/responses/transformation.py @@ -70,8 +70,13 @@ class AzureOpenAIResponsesAPIConfig(OpenAIResponsesAPIConfig): - A complete URL string, e.g., "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2024-05-01-preview" """ + from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION + return BaseAzureLLM._get_base_azure_url( - api_base=api_base, litellm_params=litellm_params, route="/openai/responses" + api_base=api_base, + litellm_params=litellm_params, + route="/openai/responses", + default_api_version=AZURE_DEFAULT_RESPONSES_API_VERSION, ) ######################################################### From 2aacf64db198c4d2251b014d4898db5b811fea49 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 22:58:58 -0700 Subject: [PATCH 006/151] test: add unit tests --- .../test_openai_responses_transformation.py | 53 ++++++++++++++++--- 1 file changed, 45 insertions(+), 8 deletions(-) diff --git a/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py b/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py index 1ed2266d1f..a587832a1a 100644 --- a/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py +++ b/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py @@ -147,7 +147,7 @@ class TestOpenAIResponsesAPIConfig: assert result.type == ResponsesAPIStreamEvents.RESPONSE_COMPLETED assert result.response.id == "resp_123" - + @pytest.mark.serial def test_validate_environment(self): """Test that validate_environment correctly sets the Authorization header""" @@ -292,27 +292,64 @@ class TestAzureResponsesAPIConfig: def test_azure_get_complete_url_with_version_types(self): """Test Azure get_complete_url with different API version types""" base_url = "https://litellm8397336933.openai.azure.com" - + # Test with preview version - should use openai/v1/responses result_preview = self.config.get_complete_url( api_base=base_url, litellm_params={"api_version": "preview"}, ) - assert result_preview == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=preview" - - # Test with latest version - should use openai/v1/responses + assert ( + result_preview + == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=preview" + ) + + # Test with latest version - should use openai/v1/responses result_latest = self.config.get_complete_url( api_base=base_url, litellm_params={"api_version": "latest"}, ) - assert result_latest == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=latest" - + assert ( + result_latest + == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=latest" + ) + # Test with date-based version - should use openai/responses result_date = self.config.get_complete_url( api_base=base_url, litellm_params={"api_version": "2025-01-01"}, ) - assert result_date == "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2025-01-01" + assert ( + result_date + == "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2025-01-01" + ) + + def test_azure_get_complete_url_with_default_api_version(self): + """Test Azure get_complete_url uses default API version when none is provided""" + from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION + + base_url = "https://litellm8397336933.openai.azure.com" + + # Test with no api_version provided - should use default + result_no_version = self.config.get_complete_url( + api_base=base_url, + litellm_params={}, + ) + expected_url = f"https://litellm8397336933.openai.azure.com/openai/responses?api-version={AZURE_DEFAULT_RESPONSES_API_VERSION}" + assert result_no_version == expected_url + + # Test with empty litellm_params - should use default + result_empty_params = self.config.get_complete_url( + api_base=base_url, + litellm_params={}, + ) + assert result_empty_params == expected_url + + # Test with None api_version - should use default + result_none_version = self.config.get_complete_url( + api_base=base_url, + litellm_params={"api_version": None}, + ) + assert result_none_version == expected_url class TestTransformListInputItemsRequest: From e1fd49ce91315b7bc7b165a0fc1fc7dafd5934c2 Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 23:26:06 -0700 Subject: [PATCH 007/151] build(model_prices_and_context_window.json): fix claude-sonnet-4 on openrouter Fixes https://github.com/BerriAI/litellm/issues/13520 --- litellm/model_prices_and_context_window_backup.json | 4 ++-- litellm/proxy/_new_secret_config.yaml | 9 +++++++++ model_prices_and_context_window.json | 4 ++-- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.json index 28dec7cce9..f9acea81a1 100644 --- a/litellm/model_prices_and_context_window_backup.json +++ b/litellm/model_prices_and_context_window_backup.json @@ -11432,9 +11432,9 @@ }, "openrouter/anthropic/claude-sonnet-4": { "supports_computer_use": true, - "max_tokens": 8192, + "max_tokens": 64000, "max_input_tokens": 200000, - "max_output_tokens": 8192, + "max_output_tokens": 64000, "input_cost_per_token": 3e-06, "output_cost_per_token": 1.5e-05, "input_cost_per_image": 0.0048, diff --git a/litellm/proxy/_new_secret_config.yaml b/litellm/proxy/_new_secret_config.yaml index b48fe5be1c..c7bf8cdb0a 100644 --- a/litellm/proxy/_new_secret_config.yaml +++ b/litellm/proxy/_new_secret_config.yaml @@ -4,6 +4,15 @@ model_list: model: openai/fake api_key: fake-key api_base: https://exampleopenaiendpoint-production.up.railway.app/ + - model_name: gpt-5-mini + litellm_params: + model: azure/gpt-5-mini + api_base: os.environ/AZURE_GPT_5_MINI_API_BASE # runs os.getenv("AZURE_API_BASE") + api_key: os.environ/AZURE_GPT_5_MINI_API_KEY # runs os.getenv("AZURE_API_KEY") + stream_timeout: 60 + merge_reasoning_content_in_choices: true + model_info: + mode: chat litellm_settings: cache: true diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.json index 28dec7cce9..f9acea81a1 100644 --- a/model_prices_and_context_window.json +++ b/model_prices_and_context_window.json @@ -11432,9 +11432,9 @@ }, "openrouter/anthropic/claude-sonnet-4": { "supports_computer_use": true, - "max_tokens": 8192, + "max_tokens": 64000, "max_input_tokens": 200000, - "max_output_tokens": 8192, + "max_output_tokens": 64000, "input_cost_per_token": 3e-06, "output_cost_per_token": 1.5e-05, "input_cost_per_image": 0.0048, From 79e262d12bf409deb674da1d96378cb4d3b9ebfc Mon Sep 17 00:00:00 2001 From: Krrish Dholakia Date: Mon, 11 Aug 2025 23:40:05 -0700 Subject: [PATCH 008/151] feat(common_utils.py): make default azure openai responses api use `/openai/v1/responses` logic Fixes https://github.com/BerriAI/litellm/issues/13527#issuecomment-3177882103 --- litellm/constants.py | 2 +- litellm/llms/azure/common_utils.py | 12 +- tests/llm_translation/test_azure_openai.py | 14 ++ .../response/test_azure_transformation.py | 140 +++++++++++++----- .../test_openai_responses_transformation.py | 69 --------- 5 files changed, 129 insertions(+), 108 deletions(-) diff --git a/litellm/constants.py b/litellm/constants.py index 8d502afaf2..afdb207362 100644 --- a/litellm/constants.py +++ b/litellm/constants.py @@ -2,7 +2,7 @@ import os from typing import List, Literal AZURE_DEFAULT_RESPONSES_API_VERSION = str( - os.getenv("AZURE_DEFAULT_RESPONSES_API_VERSION", "2025-04-01-preview") + os.getenv("AZURE_DEFAULT_RESPONSES_API_VERSION", "preview") ) ROUTER_MAX_FALLBACKS = int(os.getenv("ROUTER_MAX_FALLBACKS", 5)) DEFAULT_BATCH_SIZE = int(os.getenv("DEFAULT_BATCH_SIZE", 512)) diff --git a/litellm/llms/azure/common_utils.py b/litellm/llms/azure/common_utils.py index 5764fcdd1b..09b1888e04 100644 --- a/litellm/llms/azure/common_utils.py +++ b/litellm/llms/azure/common_utils.py @@ -694,9 +694,17 @@ class BaseAzureLLM(BaseOpenAILLM): api_base: Optional[str], litellm_params: Optional[Union[GenericLiteLLMParams, Dict[str, Any]]], route: Literal["/openai/responses", "/openai/vector_stores"], - default_api_version: Optional[str] = None, + default_api_version: Optional[Union[str, Literal["latest", "preview"]]] = None, ) -> str: - from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION + """ + Get the base Azure URL for the given route and API version. + + Args: + api_base: The base URL of the Azure API. + litellm_params: The litellm parameters. + route: The route to the API. + default_api_version: The default API version to use if no api_version is provided. If 'latest', it will use `openai/v1/...` route. + """ api_base = api_base or litellm.api_base or get_secret_str("AZURE_API_BASE") if api_base is None: diff --git a/tests/llm_translation/test_azure_openai.py b/tests/llm_translation/test_azure_openai.py index a27d0dd165..a1b05cbb4a 100644 --- a/tests/llm_translation/test_azure_openai.py +++ b/tests/llm_translation/test_azure_openai.py @@ -630,3 +630,17 @@ def test_azure_openai_responses_bridge(): == "test-azure-computer-use-preview" ) assert mock_responses.call_args.kwargs["custom_llm_provider"] == "azure" + + +def test_azure_openai_gpt_5_responses_api(): + from litellm import responses + + litellm._turn_on_debug() + + response = responses( + model="azure/gpt-5", + input="Hello world", + api_key=os.getenv("AZURE_SWEDEN_API_KEY"), + api_base=os.getenv("AZURE_SWEDEN_API_BASE"), + ) + print(f"response: {response}") diff --git a/tests/test_litellm/llms/azure/response/test_azure_transformation.py b/tests/test_litellm/llms/azure/response/test_azure_transformation.py index 51edf91b70..5a0db987ef 100644 --- a/tests/test_litellm/llms/azure/response/test_azure_transformation.py +++ b/tests/test_litellm/llms/azure/response/test_azure_transformation.py @@ -8,10 +8,14 @@ sys.path.insert( 0, os.path.abspath("../../../../..") ) # Adds the parent directory to the system path +from unittest.mock import MagicMock + +from litellm.llms.azure.responses.o_series_transformation import ( + AzureOpenAIOSeriesResponsesAPIConfig, +) from litellm.llms.azure.responses.transformation import AzureOpenAIResponsesAPIConfig -from litellm.llms.azure.responses.o_series_transformation import AzureOpenAIOSeriesResponsesAPIConfig -from litellm.types.router import GenericLiteLLMParams from litellm.types.llms.openai import ResponsesAPIOptionalRequestParams +from litellm.types.router import GenericLiteLLMParams @pytest.mark.serial @@ -27,6 +31,7 @@ def test_validate_environment_api_key_within_litellm_params(): assert result == expected + @pytest.mark.serial def test_validate_environment_api_key_within_litellm(): azure_openai_responses_apiconfig = AzureOpenAIResponsesAPIConfig() @@ -41,6 +46,7 @@ def test_validate_environment_api_key_within_litellm(): assert result == expected + @pytest.mark.serial def test_validate_environment_azure_key_within_litellm(): azure_openai_responses_apiconfig = AzureOpenAIResponsesAPIConfig() @@ -55,6 +61,7 @@ def test_validate_environment_azure_key_within_litellm(): assert result == expected + @pytest.mark.serial def test_validate_environment_azure_key_within_headers(): azure_openai_responses_apiconfig = AzureOpenAIResponsesAPIConfig() @@ -93,10 +100,10 @@ def test_azure_o_series_responses_api_supported_params(): """Test that Azure OpenAI O-series responses API excludes temperature from supported parameters.""" config = AzureOpenAIOSeriesResponsesAPIConfig() supported_params = config.get_supported_openai_params("o_series/gpt-o1") - + # Temperature should not be in supported params for O-series models assert "temperature" not in supported_params - + # Other parameters should still be supported assert "input" in supported_params assert "max_output_tokens" in supported_params @@ -108,35 +115,32 @@ def test_azure_o_series_responses_api_supported_params(): def test_azure_o_series_responses_api_drop_temperature_param(): """Test that temperature parameter is dropped when drop_params is True for O-series models.""" config = AzureOpenAIOSeriesResponsesAPIConfig() - + # Create request params with temperature request_params = ResponsesAPIOptionalRequestParams( - temperature=0.7, - max_output_tokens=1000, - stream=False, - top_p=0.9 + temperature=0.7, max_output_tokens=1000, stream=False, top_p=0.9 ) - + # Test with drop_params=True mapped_params_with_drop = config.map_openai_params( response_api_optional_params=request_params, model="o_series/gpt-o1", - drop_params=True + drop_params=True, ) - + # Temperature should be dropped assert "temperature" not in mapped_params_with_drop # Other params should remain assert mapped_params_with_drop["max_output_tokens"] == 1000 assert mapped_params_with_drop["top_p"] == 0.9 - + # Test with drop_params=False mapped_params_without_drop = config.map_openai_params( response_api_optional_params=request_params, model="o_series/gpt-o1", - drop_params=False + drop_params=False, ) - + # Temperature should still be present when drop_params=False assert mapped_params_without_drop["temperature"] == 0.7 assert mapped_params_without_drop["max_output_tokens"] == 1000 @@ -147,21 +151,19 @@ def test_azure_o_series_responses_api_drop_temperature_param(): def test_azure_o_series_responses_api_drop_params_no_temperature(): """Test that map_openai_params works correctly when temperature is not present for O-series models.""" config = AzureOpenAIOSeriesResponsesAPIConfig() - + # Create request params without temperature request_params = ResponsesAPIOptionalRequestParams( - max_output_tokens=1000, - stream=False, - top_p=0.9 + max_output_tokens=1000, stream=False, top_p=0.9 ) - + # Should work fine even with drop_params=True mapped_params = config.map_openai_params( response_api_optional_params=request_params, model="o_series/gpt-o1", - drop_params=True + drop_params=True, ) - + assert "temperature" not in mapped_params assert mapped_params["max_output_tokens"] == 1000 assert mapped_params["top_p"] == 0.9 @@ -172,10 +174,10 @@ def test_azure_regular_responses_api_supports_temperature(): """Test that regular Azure OpenAI responses API (non-O-series) supports temperature parameter.""" config = AzureOpenAIResponsesAPIConfig() supported_params = config.get_supported_openai_params("gpt-4o") - + # Regular Azure models should support temperature assert "temperature" in supported_params - + # Other parameters should still be supported assert "input" in supported_params assert "max_output_tokens" in supported_params @@ -187,11 +189,11 @@ def test_azure_regular_responses_api_supports_temperature(): def test_o_series_model_detection(): """Test that the O-series configuration correctly identifies O-series models.""" config = AzureOpenAIOSeriesResponsesAPIConfig() - + # Test explicit o_series naming assert config.is_o_series_model("o_series/gpt-o1") == True assert config.is_o_series_model("azure/o_series/gpt-o3") == True - + # Test regular models assert config.is_o_series_model("gpt-4o") == False assert config.is_o_series_model("gpt-3.5-turbo") == False @@ -200,28 +202,94 @@ def test_o_series_model_detection(): @pytest.mark.serial def test_provider_config_manager_o_series_selection(): """Test that ProviderConfigManager returns the correct config for O-series vs regular models.""" - from litellm.utils import ProviderConfigManager import litellm - + from litellm.utils import ProviderConfigManager + # Test O-series model selection o_series_config = ProviderConfigManager.get_provider_responses_api_config( - provider=litellm.LlmProviders.AZURE, - model="o_series/gpt-o1" + provider=litellm.LlmProviders.AZURE, model="o_series/gpt-o1" ) assert isinstance(o_series_config, AzureOpenAIOSeriesResponsesAPIConfig) - + # Test regular model selection regular_config = ProviderConfigManager.get_provider_responses_api_config( - provider=litellm.LlmProviders.AZURE, - model="gpt-4o" + provider=litellm.LlmProviders.AZURE, model="gpt-4o" ) assert isinstance(regular_config, AzureOpenAIResponsesAPIConfig) assert not isinstance(regular_config, AzureOpenAIOSeriesResponsesAPIConfig) - + # Test with no model specified (should default to regular) default_config = ProviderConfigManager.get_provider_responses_api_config( - provider=litellm.LlmProviders.AZURE, - model=None + provider=litellm.LlmProviders.AZURE, model=None ) assert isinstance(default_config, AzureOpenAIResponsesAPIConfig) assert not isinstance(default_config, AzureOpenAIOSeriesResponsesAPIConfig) + + +class TestAzureResponsesAPIConfig: + def setup_method(self): + self.config = AzureOpenAIResponsesAPIConfig() + self.model = "gpt-4o" + self.logging_obj = MagicMock() + + def test_azure_get_complete_url_with_version_types(self): + """Test Azure get_complete_url with different API version types""" + base_url = "https://litellm8397336933.openai.azure.com" + + # Test with preview version - should use openai/v1/responses + result_preview = self.config.get_complete_url( + api_base=base_url, + litellm_params={"api_version": "preview"}, + ) + assert ( + result_preview + == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=preview" + ) + + # Test with latest version - should use openai/v1/responses + result_latest = self.config.get_complete_url( + api_base=base_url, + litellm_params={"api_version": "latest"}, + ) + assert ( + result_latest + == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=latest" + ) + + # Test with date-based version - should use openai/responses + result_date = self.config.get_complete_url( + api_base=base_url, + litellm_params={"api_version": "2025-01-01"}, + ) + assert ( + result_date + == "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2025-01-01" + ) + + def test_azure_get_complete_url_with_default_api_version(self): + """Test Azure get_complete_url uses default API version when none is provided""" + from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION + + base_url = "https://litellm8397336933.openai.azure.com" + + # Test with no api_version provided - should use default + result_no_version = self.config.get_complete_url( + api_base=base_url, + litellm_params={}, + ) + expected_url = f"https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version={AZURE_DEFAULT_RESPONSES_API_VERSION}" + assert result_no_version == expected_url + + # Test with empty litellm_params - should use default + result_empty_params = self.config.get_complete_url( + api_base=base_url, + litellm_params={}, + ) + assert result_empty_params == expected_url + + # Test with None api_version - should use default + result_none_version = self.config.get_complete_url( + api_base=base_url, + litellm_params={"api_version": None}, + ) + assert result_none_version == expected_url diff --git a/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py b/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py index a587832a1a..9b8e56ab49 100644 --- a/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py +++ b/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py @@ -283,75 +283,6 @@ class TestOpenAIResponsesAPIConfig: assert result.type == "test" -class TestAzureResponsesAPIConfig: - def setup_method(self): - self.config = AzureOpenAIResponsesAPIConfig() - self.model = "gpt-4o" - self.logging_obj = MagicMock() - - def test_azure_get_complete_url_with_version_types(self): - """Test Azure get_complete_url with different API version types""" - base_url = "https://litellm8397336933.openai.azure.com" - - # Test with preview version - should use openai/v1/responses - result_preview = self.config.get_complete_url( - api_base=base_url, - litellm_params={"api_version": "preview"}, - ) - assert ( - result_preview - == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=preview" - ) - - # Test with latest version - should use openai/v1/responses - result_latest = self.config.get_complete_url( - api_base=base_url, - litellm_params={"api_version": "latest"}, - ) - assert ( - result_latest - == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=latest" - ) - - # Test with date-based version - should use openai/responses - result_date = self.config.get_complete_url( - api_base=base_url, - litellm_params={"api_version": "2025-01-01"}, - ) - assert ( - result_date - == "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2025-01-01" - ) - - def test_azure_get_complete_url_with_default_api_version(self): - """Test Azure get_complete_url uses default API version when none is provided""" - from litellm.constants import AZURE_DEFAULT_RESPONSES_API_VERSION - - base_url = "https://litellm8397336933.openai.azure.com" - - # Test with no api_version provided - should use default - result_no_version = self.config.get_complete_url( - api_base=base_url, - litellm_params={}, - ) - expected_url = f"https://litellm8397336933.openai.azure.com/openai/responses?api-version={AZURE_DEFAULT_RESPONSES_API_VERSION}" - assert result_no_version == expected_url - - # Test with empty litellm_params - should use default - result_empty_params = self.config.get_complete_url( - api_base=base_url, - litellm_params={}, - ) - assert result_empty_params == expected_url - - # Test with None api_version - should use default - result_none_version = self.config.get_complete_url( - api_base=base_url, - litellm_params={"api_version": None}, - ) - assert result_none_version == expected_url - - class TestTransformListInputItemsRequest: """Test suite for transform_list_input_items_request function""" From 89f71af4cd1f5bbaecc7adeb460964b04abf7b9c Mon Sep 17 00:00:00 2001 From: Mattias Andersson Date: Thu, 14 Aug 2025 17:08:26 +0200 Subject: [PATCH 009/151] Add possibility to configure resources for migrations-job in Helm chart --- deploy/charts/litellm-helm/Chart.yaml | 2 +- deploy/charts/litellm-helm/templates/migrations-job.yaml | 4 ++++ deploy/charts/litellm-helm/values.yaml | 4 ++++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/deploy/charts/litellm-helm/Chart.yaml b/deploy/charts/litellm-helm/Chart.yaml index bd63ca6bfc..b6ac264a22 100644 --- a/deploy/charts/litellm-helm/Chart.yaml +++ b/deploy/charts/litellm-helm/Chart.yaml @@ -18,7 +18,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.4.4 +version: 0.4.5 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/deploy/charts/litellm-helm/templates/migrations-job.yaml b/deploy/charts/litellm-helm/templates/migrations-job.yaml index cf10be0a76..ec80e86b21 100644 --- a/deploy/charts/litellm-helm/templates/migrations-job.yaml +++ b/deploy/charts/litellm-helm/templates/migrations-job.yaml @@ -73,6 +73,10 @@ spec: volumeMounts: {{- toYaml . | nindent 12 }} {{- end }} + {{- with .Values.migrationJob.resources }} + resources: + {{- toYaml . | nindent 12 }} + {{- end }} {{- with .Values.migrationJob.extraContainers }} {{- toYaml . | nindent 8 }} {{- end }} diff --git a/deploy/charts/litellm-helm/values.yaml b/deploy/charts/litellm-helm/values.yaml index f99204cbb4..e9a96b23de 100644 --- a/deploy/charts/litellm-helm/values.yaml +++ b/deploy/charts/litellm-helm/values.yaml @@ -206,6 +206,10 @@ migrationJob: disableSchemaUpdate: false # Skip schema migrations for specific environments. When True, the job will exit with code 0. annotations: {} ttlSecondsAfterFinished: 120 + resources: {} + # requests: + # cpu: 100m + # memory: 100Mi extraContainers: [] # Hook configuration From f88e6afbb7251393bd296307e408766673c60c57 Mon Sep 17 00:00:00 2001 From: tanjiro <56165694+NANDINI-star@users.noreply.github.com> Date: Fri, 15 Aug 2025 01:42:32 +0900 Subject: [PATCH 010/151] fix query param --- ui/litellm-dashboard/src/components/networking.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ui/litellm-dashboard/src/components/networking.tsx b/ui/litellm-dashboard/src/components/networking.tsx index 93ae040c86..a046d32488 100644 --- a/ui/litellm-dashboard/src/components/networking.tsx +++ b/ui/litellm-dashboard/src/components/networking.tsx @@ -4731,7 +4731,7 @@ export const deletePassThroughEndpointsCall = async ( try { let url = proxyBaseUrl ? `${proxyBaseUrl}/config/pass_through_endpoint?endpoint_id=${endpointId}` - : `/config/pass_through_endpoint${endpointId}`; + : `/config/pass_through_endpoint?endpoint_id=${endpointId}`; //message.info("Requesting model data"); const response = await fetch(url, { From 0e6cf7fb9daa8691abfcc4734b30e4578b8983fd Mon Sep 17 00:00:00 2001 From: tanjiro <56165694+NANDINI-star@users.noreply.github.com> Date: Fri, 15 Aug 2025 03:25:29 +0900 Subject: [PATCH 011/151] edit budget_duration. - make sure edit view and info view have similar setting names --- .../src/components/bulk_edit_user.tsx | 4 ++++ .../budget_duration_dropdown.tsx | 2 +- .../src/components/edit_user.tsx | 9 ++++++++ .../src/components/user_edit_view.tsx | 7 +++++++ .../src/components/view_users/types.ts | 3 ++- .../components/view_users/user_info_view.tsx | 21 +++++++++++++++++-- 6 files changed, 42 insertions(+), 4 deletions(-) diff --git a/ui/litellm-dashboard/src/components/bulk_edit_user.tsx b/ui/litellm-dashboard/src/components/bulk_edit_user.tsx index c4ae4a97d3..25b70b9f49 100644 --- a/ui/litellm-dashboard/src/components/bulk_edit_user.tsx +++ b/ui/litellm-dashboard/src/components/bulk_edit_user.tsx @@ -104,6 +104,10 @@ const BulkEditUserModal: React.FC = ({ updatePayload.models = formValues.models; } + if (formValues.budget_duration && formValues.budget_duration !== "") { + updatePayload.budget_duration = formValues.budget_duration; + } + if (formValues.metadata && Object.keys(formValues.metadata).length > 0) { updatePayload.metadata = formValues.metadata; } diff --git a/ui/litellm-dashboard/src/components/common_components/budget_duration_dropdown.tsx b/ui/litellm-dashboard/src/components/common_components/budget_duration_dropdown.tsx index 9171e13381..23e0dd331c 100644 --- a/ui/litellm-dashboard/src/components/common_components/budget_duration_dropdown.tsx +++ b/ui/litellm-dashboard/src/components/common_components/budget_duration_dropdown.tsx @@ -5,7 +5,7 @@ const { Option } = Select; interface BudgetDurationDropdownProps { value?: string | null; - onChange: (value: string) => void; + onChange?: (value: string) => void; className?: string; style?: React.CSSProperties; } diff --git a/ui/litellm-dashboard/src/components/edit_user.tsx b/ui/litellm-dashboard/src/components/edit_user.tsx index 1cd47ffec2..4f49eb821f 100644 --- a/ui/litellm-dashboard/src/components/edit_user.tsx +++ b/ui/litellm-dashboard/src/components/edit_user.tsx @@ -22,6 +22,7 @@ import { } from "antd"; import NumericalInput from "./shared/numerical_input"; +import BudgetDurationDropdown from "./common_components/budget_duration_dropdown"; interface EditUserModalProps { visible: boolean; @@ -126,6 +127,14 @@ const EditUserModal: React.FC = ({ visible, possibleUIRoles, + + + + +
+ Save +
+
Save
diff --git a/ui/litellm-dashboard/src/components/user_edit_view.tsx b/ui/litellm-dashboard/src/components/user_edit_view.tsx index c79d343094..bfe00290eb 100644 --- a/ui/litellm-dashboard/src/components/user_edit_view.tsx +++ b/ui/litellm-dashboard/src/components/user_edit_view.tsx @@ -5,6 +5,8 @@ import { Button } from "@tremor/react"; import { getModelDisplayName } from "./key_team_helpers/fetch_available_models_team_key"; import { all_admin_roles } from "../utils/roles"; import { InfoCircleOutlined } from "@ant-design/icons"; +import BudgetDurationDropdown from "./common_components/budget_duration_dropdown"; + interface UserEditViewProps { userData: any; onCancel: () => void; @@ -40,6 +42,7 @@ export function UserEditView({ user_role: userData.user_info?.user_role, models: userData.user_info?.models || [], max_budget: userData.user_info?.max_budget, + budget_duration: userData.user_info?.budget_duration, metadata: userData.user_info?.metadata ? JSON.stringify(userData.user_info.metadata, null, 2) : undefined, }); }, [userData, form]); @@ -154,6 +157,10 @@ export function UserEditView({ /> + + + + | null created_at: string | null @@ -137,6 +139,7 @@ export default function UserInfoView({ user_email: formValues.user_email, models: formValues.models, max_budget: formValues.max_budget, + budget_duration: formValues.budget_duration, metadata: formValues.metadata, }, }) @@ -355,7 +358,7 @@ export default function UserInfoView({
- Role + Global Proxy Role {userData.user_info?.user_role || "Not Set"}
@@ -393,7 +396,7 @@ export default function UserInfoView({
- Models + Personal Models
{userData.user_info?.models?.length && userData.user_info?.models?.length > 0 ? ( userData.user_info?.models?.map((model, index) => ( @@ -422,6 +425,20 @@ export default function UserInfoView({
+
+ Max Budget + + {userData.user_info?.max_budget !== null && userData.user_info?.max_budget !== undefined + ? `$${formatNumberWithCommas(userData.user_info.max_budget, 4)}` + : "Unlimited"} + +
+ +
+ Budget Reset + {getBudgetDurationLabel(userData.user_info?.budget_duration ?? null)} +
+
Metadata

From 4b51e5787c781f43c221167126388593fd3580da Mon Sep 17 00:00:00 2001
From: Tasmay Pankaj Tibrewal
 <85983760+Tasmay-Tibrewal@users.noreply.github.com>
Date: Fri, 15 Aug 2025 04:33:49 +0530
Subject: [PATCH 012/151] added qwen3, deepseek r1 0528 throughput, glm 4.5 and
 gpt oss models

---
 model_prices_and_context_window.json | 88 ++++++++++++++++++++++++++++
 1 file changed, 88 insertions(+)

diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.json
index 9668053888..5e43113113 100644
--- a/model_prices_and_context_window.json
+++ b/model_prices_and_context_window.json
@@ -14649,6 +14649,50 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
+    "deepseek-ai/Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
+        "input_cost_per_token": 2e-07,
+        "output_cost_per_token": 6e-06,
+        "max_input_tokens": 262000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-235b-a22b-instruct-2507-fp8"
+    },
+    "deepseek-ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
+        "input_cost_per_token": 2e-06,
+        "output_cost_per_token": 2e-06,
+        "max_input_tokens": 256000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-coder-480b-a35b-instruct"
+    },
+    "deepseek-ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
+        "input_cost_per_token": 6.5e-07,
+        "output_cost_per_token": 3e-06,
+        "max_input_tokens": 256000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-235b-a22b-thinking-2507"
+    },
+    "deepseek-ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
+        "input_cost_per_token": 2e-07,
+        "output_cost_per_token": 6e-07,
+        "max_input_tokens": 40000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-235b-a22b-fp8-tput"
+    },
     "together_ai/deepseek-ai/DeepSeek-V3": {
         "input_cost_per_token": 1.25e-06,
         "output_cost_per_token": 1.25e-06,
@@ -14673,6 +14717,17 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
+    "deepseek-ai/DeepSeek-R1-0528-tput": {
+        "input_cost_per_token": 5.5e-07,
+        "output_cost_per_token": 2.19e-06,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/deepseek-r1-0528-throughput"
+    },
     "together_ai/mistralai/Mistral-Small-24B-Instruct-2501": {
         "litellm_provider": "together_ai",
         "supports_function_calling": true,
@@ -14690,6 +14745,39 @@
         "mode": "chat",
         "source": "https://www.together.ai/models/kimi-k2-instruct"
     },
+    "together_ai/openai/gpt-oss-120b": {
+        "input_cost_per_token": 1.5e-07,
+        "output_cost_per_token": 6e-07,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_tool_choice": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "source": "https://www.together.ai/models/gpt-oss-120b"
+    },
+    "together_ai/OpenAI/gpt-oss-20B": {
+        "input_cost_per_token": 5e-08,
+        "output_cost_per_token": 2e-07,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_tool_choice": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "source": "https://www.together.ai/models/gpt-oss-20b"
+    },
+    "together_ai/zai-org/GLM-4.5-Air-FP8": {
+        "input_cost_per_token": 2e-07,
+        "output_cost_per_token": 1.1e-06,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_tool_choice": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "source": "https://www.together.ai/models/glm-4-5-air"
+    },
     "ollama/codegemma": {
         "max_tokens": 8192,
         "max_input_tokens": 8192,

From a85ab9d2044e34514982396210ea95ad8a91e99a Mon Sep 17 00:00:00 2001
From: Tasmay Pankaj Tibrewal
 <85983760+Tasmay-Tibrewal@users.noreply.github.com>
Date: Fri, 15 Aug 2025 04:34:55 +0530
Subject: [PATCH 013/151] added qwen3, deepseek r1 0528 throughput, glm 4.5 and
 gpt oss models

---
 ...odel_prices_and_context_window_backup.json | 88 +++++++++++++++++++
 1 file changed, 88 insertions(+)

diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.json
index 9668053888..5e43113113 100644
--- a/litellm/model_prices_and_context_window_backup.json
+++ b/litellm/model_prices_and_context_window_backup.json
@@ -14649,6 +14649,50 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
+    "deepseek-ai/Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
+        "input_cost_per_token": 2e-07,
+        "output_cost_per_token": 6e-06,
+        "max_input_tokens": 262000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-235b-a22b-instruct-2507-fp8"
+    },
+    "deepseek-ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
+        "input_cost_per_token": 2e-06,
+        "output_cost_per_token": 2e-06,
+        "max_input_tokens": 256000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-coder-480b-a35b-instruct"
+    },
+    "deepseek-ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
+        "input_cost_per_token": 6.5e-07,
+        "output_cost_per_token": 3e-06,
+        "max_input_tokens": 256000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-235b-a22b-thinking-2507"
+    },
+    "deepseek-ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
+        "input_cost_per_token": 2e-07,
+        "output_cost_per_token": 6e-07,
+        "max_input_tokens": 40000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/qwen3-235b-a22b-fp8-tput"
+    },
     "together_ai/deepseek-ai/DeepSeek-V3": {
         "input_cost_per_token": 1.25e-06,
         "output_cost_per_token": 1.25e-06,
@@ -14673,6 +14717,17 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
+    "deepseek-ai/DeepSeek-R1-0528-tput": {
+        "input_cost_per_token": 5.5e-07,
+        "output_cost_per_token": 2.19e-06,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "supports_tool_choice": false
+        "source": "https://www.together.ai/models/deepseek-r1-0528-throughput"
+    },
     "together_ai/mistralai/Mistral-Small-24B-Instruct-2501": {
         "litellm_provider": "together_ai",
         "supports_function_calling": true,
@@ -14690,6 +14745,39 @@
         "mode": "chat",
         "source": "https://www.together.ai/models/kimi-k2-instruct"
     },
+    "together_ai/openai/gpt-oss-120b": {
+        "input_cost_per_token": 1.5e-07,
+        "output_cost_per_token": 6e-07,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_tool_choice": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "source": "https://www.together.ai/models/gpt-oss-120b"
+    },
+    "together_ai/OpenAI/gpt-oss-20B": {
+        "input_cost_per_token": 5e-08,
+        "output_cost_per_token": 2e-07,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_tool_choice": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "source": "https://www.together.ai/models/gpt-oss-20b"
+    },
+    "together_ai/zai-org/GLM-4.5-Air-FP8": {
+        "input_cost_per_token": 2e-07,
+        "output_cost_per_token": 1.1e-06,
+        "max_input_tokens": 128000,
+        "litellm_provider": "together_ai",
+        "supports_function_calling": false,
+        "supports_tool_choice": false,
+        "supports_parallel_function_calling": false,
+        "mode": "chat",
+        "source": "https://www.together.ai/models/glm-4-5-air"
+    },
     "ollama/codegemma": {
         "max_tokens": 8192,
         "max_input_tokens": 8192,

From d20391101b3a5024ee1aeb33d1218fce9f194830 Mon Sep 17 00:00:00 2001
From: Tasmay Pankaj Tibrewal
 <85983760+Tasmay-Tibrewal@users.noreply.github.com>
Date: Fri, 15 Aug 2025 04:43:52 +0530
Subject: [PATCH 014/151] fixed together ai provider name mistake

---
 model_prices_and_context_window.json | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.json
index 5e43113113..071ade6e5a 100644
--- a/model_prices_and_context_window.json
+++ b/model_prices_and_context_window.json
@@ -14649,7 +14649,7 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
-    "deepseek-ai/Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
+    "together_ai/Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
         "input_cost_per_token": 2e-07,
         "output_cost_per_token": 6e-06,
         "max_input_tokens": 262000,
@@ -14660,7 +14660,7 @@
         "supports_tool_choice": false
         "source": "https://www.together.ai/models/qwen3-235b-a22b-instruct-2507-fp8"
     },
-    "deepseek-ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
+    "together_ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
         "input_cost_per_token": 2e-06,
         "output_cost_per_token": 2e-06,
         "max_input_tokens": 256000,
@@ -14671,7 +14671,7 @@
         "supports_tool_choice": false
         "source": "https://www.together.ai/models/qwen3-coder-480b-a35b-instruct"
     },
-    "deepseek-ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
+    "together_ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
         "input_cost_per_token": 6.5e-07,
         "output_cost_per_token": 3e-06,
         "max_input_tokens": 256000,
@@ -14682,7 +14682,7 @@
         "supports_tool_choice": false
         "source": "https://www.together.ai/models/qwen3-235b-a22b-thinking-2507"
     },
-    "deepseek-ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
+    "together_ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
         "input_cost_per_token": 2e-07,
         "output_cost_per_token": 6e-07,
         "max_input_tokens": 40000,
@@ -14717,7 +14717,7 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
-    "deepseek-ai/DeepSeek-R1-0528-tput": {
+    "together_ai/deepseek-ai/DeepSeek-R1-0528-tput": {
         "input_cost_per_token": 5.5e-07,
         "output_cost_per_token": 2.19e-06,
         "max_input_tokens": 128000,

From 0a83aecb5c334a514ca87181dcb7682cf16a8f00 Mon Sep 17 00:00:00 2001
From: Tasmay Pankaj Tibrewal
 <85983760+Tasmay-Tibrewal@users.noreply.github.com>
Date: Fri, 15 Aug 2025 04:44:43 +0530
Subject: [PATCH 015/151] fixed together ai provider name mistake

---
 litellm/model_prices_and_context_window_backup.json | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.json
index 5e43113113..071ade6e5a 100644
--- a/litellm/model_prices_and_context_window_backup.json
+++ b/litellm/model_prices_and_context_window_backup.json
@@ -14649,7 +14649,7 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
-    "deepseek-ai/Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
+    "together_ai/Qwen/Qwen3-235B-A22B-Instruct-2507-tput": {
         "input_cost_per_token": 2e-07,
         "output_cost_per_token": 6e-06,
         "max_input_tokens": 262000,
@@ -14660,7 +14660,7 @@
         "supports_tool_choice": false
         "source": "https://www.together.ai/models/qwen3-235b-a22b-instruct-2507-fp8"
     },
-    "deepseek-ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
+    "together_ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
         "input_cost_per_token": 2e-06,
         "output_cost_per_token": 2e-06,
         "max_input_tokens": 256000,
@@ -14671,7 +14671,7 @@
         "supports_tool_choice": false
         "source": "https://www.together.ai/models/qwen3-coder-480b-a35b-instruct"
     },
-    "deepseek-ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
+    "together_ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
         "input_cost_per_token": 6.5e-07,
         "output_cost_per_token": 3e-06,
         "max_input_tokens": 256000,
@@ -14682,7 +14682,7 @@
         "supports_tool_choice": false
         "source": "https://www.together.ai/models/qwen3-235b-a22b-thinking-2507"
     },
-    "deepseek-ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
+    "together_ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
         "input_cost_per_token": 2e-07,
         "output_cost_per_token": 6e-07,
         "max_input_tokens": 40000,
@@ -14717,7 +14717,7 @@
         "mode": "chat",
         "supports_tool_choice": true
     },
-    "deepseek-ai/DeepSeek-R1-0528-tput": {
+    "together_ai/deepseek-ai/DeepSeek-R1-0528-tput": {
         "input_cost_per_token": 5.5e-07,
         "output_cost_per_token": 2.19e-06,
         "max_input_tokens": 128000,

From d9105a99abb7dab774b5c3858aebf0407cab83cb Mon Sep 17 00:00:00 2001
From: Tasmay Pankaj Tibrewal
 <85983760+Tasmay-Tibrewal@users.noreply.github.com>
Date: Fri, 15 Aug 2025 05:07:46 +0530
Subject: [PATCH 016/151] fixed comma delimeter issue

---
 model_prices_and_context_window.json | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.json
index 071ade6e5a..a39f81897b 100644
--- a/model_prices_and_context_window.json
+++ b/model_prices_and_context_window.json
@@ -14657,7 +14657,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-235b-a22b-instruct-2507-fp8"
     },
     "together_ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
@@ -14668,7 +14668,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-coder-480b-a35b-instruct"
     },
     "together_ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
@@ -14679,7 +14679,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-235b-a22b-thinking-2507"
     },
     "together_ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
@@ -14690,7 +14690,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-235b-a22b-fp8-tput"
     },
     "together_ai/deepseek-ai/DeepSeek-V3": {
@@ -14725,7 +14725,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/deepseek-r1-0528-throughput"
     },
     "together_ai/mistralai/Mistral-Small-24B-Instruct-2501": {

From d8a9509890e5ed6c7d2e095946e14f939d90a1b5 Mon Sep 17 00:00:00 2001
From: Tasmay Pankaj Tibrewal
 <85983760+Tasmay-Tibrewal@users.noreply.github.com>
Date: Fri, 15 Aug 2025 05:08:20 +0530
Subject: [PATCH 017/151] fixed comma delimeter issue

---
 litellm/model_prices_and_context_window_backup.json | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.json
index 071ade6e5a..a39f81897b 100644
--- a/litellm/model_prices_and_context_window_backup.json
+++ b/litellm/model_prices_and_context_window_backup.json
@@ -14657,7 +14657,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-235b-a22b-instruct-2507-fp8"
     },
     "together_ai/Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
@@ -14668,7 +14668,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-coder-480b-a35b-instruct"
     },
     "together_ai/Qwen/Qwen3-235B-A22B-Thinking-2507": {
@@ -14679,7 +14679,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-235b-a22b-thinking-2507"
     },
     "together_ai/Qwen/Qwen3-235B-A22B-fp8-tput": {
@@ -14690,7 +14690,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/qwen3-235b-a22b-fp8-tput"
     },
     "together_ai/deepseek-ai/DeepSeek-V3": {
@@ -14725,7 +14725,7 @@
         "supports_function_calling": false,
         "supports_parallel_function_calling": false,
         "mode": "chat",
-        "supports_tool_choice": false
+        "supports_tool_choice": false,
         "source": "https://www.together.ai/models/deepseek-r1-0528-throughput"
     },
     "together_ai/mistralai/Mistral-Small-24B-Instruct-2501": {

From 790d2d08306189f97b5595aae8b59626ffcfd333 Mon Sep 17 00:00:00 2001
From: Jugal Bhatt 
Date: Fri, 15 Aug 2025 10:57:39 -0700
Subject: [PATCH 018/151] [Update] Adjust max_input_tokens for azure/gpt-5-chat
 models in JSON configuration

* Reduced max_input_tokens from 400000 to 272000 for both azure/gpt-5-chat and azure/gpt-5-chat-latest to optimize resource usage and align with updated model specifications.
---
 litellm/model_prices_and_context_window_backup.json | 4 ++--
 model_prices_and_context_window.json                | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/litellm/model_prices_and_context_window_backup.json b/litellm/model_prices_and_context_window_backup.json
index 9668053888..3874549760 100644
--- a/litellm/model_prices_and_context_window_backup.json
+++ b/litellm/model_prices_and_context_window_backup.json
@@ -2457,7 +2457,7 @@
     },
     "azure/gpt-5-chat": {
         "max_tokens": 128000,
-        "max_input_tokens": 400000,
+        "max_input_tokens": 272000,
         "max_output_tokens": 128000,
         "input_cost_per_token": 1.25e-06,
         "output_cost_per_token": 1e-05,
@@ -2490,7 +2490,7 @@
     },
     "azure/gpt-5-chat-latest": {
         "max_tokens": 128000,
-        "max_input_tokens": 400000,
+        "max_input_tokens": 272000,
         "max_output_tokens": 128000,
         "input_cost_per_token": 1.25e-06,
         "output_cost_per_token": 1e-05,
diff --git a/model_prices_and_context_window.json b/model_prices_and_context_window.json
index 9668053888..3874549760 100644
--- a/model_prices_and_context_window.json
+++ b/model_prices_and_context_window.json
@@ -2457,7 +2457,7 @@
     },
     "azure/gpt-5-chat": {
         "max_tokens": 128000,
-        "max_input_tokens": 400000,
+        "max_input_tokens": 272000,
         "max_output_tokens": 128000,
         "input_cost_per_token": 1.25e-06,
         "output_cost_per_token": 1e-05,
@@ -2490,7 +2490,7 @@
     },
     "azure/gpt-5-chat-latest": {
         "max_tokens": 128000,
-        "max_input_tokens": 400000,
+        "max_input_tokens": 272000,
         "max_output_tokens": 128000,
         "input_cost_per_token": 1.25e-06,
         "output_cost_per_token": 1e-05,

From b83b1686c227d1d24e269edd59de25e5ec303d4c Mon Sep 17 00:00:00 2001
From: Krrish Dholakia 
Date: Sat, 16 Aug 2025 00:23:37 -0700
Subject: [PATCH 019/151] 
 feat(support-allowed_openai_params-for-responses-api): Fixes
 https://github.com/BerriAI/litellm/issues/13559

---
 .../llms/azure/responses/transformation.py    |   5 +
 .../llms/base_llm/responses/transformation.py |   6 ++
 .../llms/openai/responses/transformation.py   |  15 ++-
 litellm/responses/main.py                     |  86 +++++++++------
 litellm/responses/utils.py                    | 100 +++++++++++++-----
 litellm/types/llms/openai.py                  |   4 +
 tests/llm_translation/test_optional_params.py |  29 +++++
 7 files changed, 183 insertions(+), 62 deletions(-)

diff --git a/litellm/llms/azure/responses/transformation.py b/litellm/llms/azure/responses/transformation.py
index e3d37c8a15..a31ccacf34 100644
--- a/litellm/llms/azure/responses/transformation.py
+++ b/litellm/llms/azure/responses/transformation.py
@@ -6,6 +6,7 @@ from litellm.llms.openai.responses.transformation import OpenAIResponsesAPIConfi
 from litellm.types.llms.openai import *
 from litellm.types.responses.main import *
 from litellm.types.router import GenericLiteLLMParams
+from litellm.types.utils import LlmProviders
 
 if TYPE_CHECKING:
     from litellm.litellm_core_utils.litellm_logging import Logging as _LiteLLMLoggingObj
@@ -16,6 +17,10 @@ else:
 
 
 class AzureOpenAIResponsesAPIConfig(OpenAIResponsesAPIConfig):
+    @property
+    def custom_llm_provider(self) -> LlmProviders:
+        return LlmProviders.AZURE
+
     def validate_environment(
         self, headers: dict, model: str, litellm_params: Optional[GenericLiteLLMParams]
     ) -> dict:
diff --git a/litellm/llms/base_llm/responses/transformation.py b/litellm/llms/base_llm/responses/transformation.py
index e2f89da5e8..4da4f7652e 100644
--- a/litellm/llms/base_llm/responses/transformation.py
+++ b/litellm/llms/base_llm/responses/transformation.py
@@ -12,6 +12,7 @@ from litellm.types.llms.openai import (
 )
 from litellm.types.responses.main import *
 from litellm.types.router import GenericLiteLLMParams
+from litellm.types.utils import LlmProviders
 
 if TYPE_CHECKING:
     from litellm.litellm_core_utils.litellm_logging import Logging as _LiteLLMLoggingObj
@@ -29,6 +30,11 @@ class BaseResponsesAPIConfig(ABC):
     def __init__(self):
         pass
 
+    @property
+    @abstractmethod
+    def custom_llm_provider(self) -> LlmProviders:
+        pass
+
     @classmethod
     def get_config(cls):
         return {
diff --git a/litellm/llms/openai/responses/transformation.py b/litellm/llms/openai/responses/transformation.py
index 501941fdc5..40aae5a1ce 100644
--- a/litellm/llms/openai/responses/transformation.py
+++ b/litellm/llms/openai/responses/transformation.py
@@ -13,6 +13,7 @@ from litellm.secret_managers.main import get_secret_str
 from litellm.types.llms.openai import *
 from litellm.types.responses.main import *
 from litellm.types.router import GenericLiteLLMParams
+from litellm.types.utils import LlmProviders
 
 from ..common_utils import OpenAIError
 
@@ -25,6 +26,10 @@ else:
 
 
 class OpenAIResponsesAPIConfig(BaseResponsesAPIConfig):
+    @property
+    def custom_llm_provider(self) -> LlmProviders:
+        return LlmProviders.OPENAI
+
     def get_supported_openai_params(self, model: str) -> list:
         """
         All OpenAI Responses API params are supported
@@ -85,8 +90,10 @@ class OpenAIResponsesAPIConfig(BaseResponsesAPIConfig):
         )
 
         return final_request_params
-    
-    def _validate_input_param(self, input: Union[str, ResponseInputParam]) -> Union[str, ResponseInputParam]:
+
+    def _validate_input_param(
+        self, input: Union[str, ResponseInputParam]
+    ) -> Union[str, ResponseInputParam]:
         """
         Ensure all input fields if pydantic are converted to dict
 
@@ -114,7 +121,9 @@ class OpenAIResponsesAPIConfig(BaseResponsesAPIConfig):
         """No transform applied since outputs are in OpenAI spec already"""
         try:
             raw_response_json = raw_response.json()
-            raw_response_json["created_at"] = _safe_convert_created_field(raw_response_json["created_at"])
+            raw_response_json["created_at"] = _safe_convert_created_field(
+                raw_response_json["created_at"]
+            )
         except Exception:
             raise OpenAIError(
                 message=raw_response.text, status_code=raw_response.status_code
diff --git a/litellm/responses/main.py b/litellm/responses/main.py
index b5f18cf9e1..ebd0ad4f42 100644
--- a/litellm/responses/main.py
+++ b/litellm/responses/main.py
@@ -1,7 +1,7 @@
 import asyncio
 import contextvars
 from functools import partial
-from typing import Any, Coroutine, Dict, Iterable, List, Literal, Optional, Union
+from typing import Any, Coroutine, Dict, Iterable, List, Literal, Optional, Union, cast
 
 import httpx
 
@@ -89,6 +89,7 @@ def mock_responses_api_response(
         }
     )
 
+
 async def aresponses_api_with_mcp(
     input: Union[str, ResponseInputParam],
     model: str,
@@ -122,7 +123,7 @@ async def aresponses_api_with_mcp(
 ) -> Union[ResponsesAPIResponse, BaseResponsesAPIStreamingIterator]:
     """
     Async version of responses API with MCP integration.
-    
+
     When MCP tools with server_url="litellm_proxy" are provided, this function will:
     1. Get available tools from the MCP server manager
     2. Insert the tools into the messages/input
@@ -134,19 +135,25 @@ async def aresponses_api_with_mcp(
     )
 
     # Parse MCP tools and separate from other tools
-    mcp_tools_with_litellm_proxy, other_tools = LiteLLM_Proxy_MCP_Handler._parse_mcp_tools(tools)
-    
+    mcp_tools_with_litellm_proxy, other_tools = (
+        LiteLLM_Proxy_MCP_Handler._parse_mcp_tools(tools)
+    )
+
     # Get available tools from MCP manager if we have MCP tools
     openai_tools = []
     mcp_tools_fetched = []
     if mcp_tools_with_litellm_proxy:
         user_api_key_auth = kwargs.get("user_api_key_auth")
-        mcp_tools_fetched = await LiteLLM_Proxy_MCP_Handler._get_mcp_tools_from_manager(user_api_key_auth)
-        openai_tools = LiteLLM_Proxy_MCP_Handler._transform_mcp_tools_to_openai(mcp_tools_fetched)
-    
+        mcp_tools_fetched = await LiteLLM_Proxy_MCP_Handler._get_mcp_tools_from_manager(
+            user_api_key_auth
+        )
+        openai_tools = LiteLLM_Proxy_MCP_Handler._transform_mcp_tools_to_openai(
+            mcp_tools_fetched
+        )
+
     # Combine with other tools
     all_tools = openai_tools + other_tools if (openai_tools or other_tools) else None
-    
+
     # Prepare call parameters for reuse
     call_params = {
         "include": include,
@@ -172,7 +179,7 @@ async def aresponses_api_with_mcp(
         "custom_llm_provider": custom_llm_provider,
         **kwargs,
     }
-    
+
     # Make initial response API call
     # TODO: if should auto-execute  is True, then this first response should not be streamed
     response = await aresponses(
@@ -180,45 +187,54 @@ async def aresponses_api_with_mcp(
         model=model,
         tools=all_tools,
         previous_response_id=previous_response_id,
-        **call_params
+        **call_params,
     )
-    
+
     # Check if we need to auto-execute tool calls (only for non-streaming responses)
-    if (mcp_tools_with_litellm_proxy and 
-        isinstance(response, ResponsesAPIResponse) and
-        LiteLLM_Proxy_MCP_Handler._should_auto_execute_tools(mcp_tools_with_litellm_proxy=mcp_tools_with_litellm_proxy)):  # type: ignore
-        tool_calls = LiteLLM_Proxy_MCP_Handler._extract_tool_calls_from_response(response=response)
-        
+    if (
+        mcp_tools_with_litellm_proxy
+        and isinstance(response, ResponsesAPIResponse)
+        and LiteLLM_Proxy_MCP_Handler._should_auto_execute_tools(
+            mcp_tools_with_litellm_proxy=mcp_tools_with_litellm_proxy
+        )
+    ):  # type: ignore
+        tool_calls = LiteLLM_Proxy_MCP_Handler._extract_tool_calls_from_response(
+            response=response
+        )
+
         if tool_calls:
-            user_api_key_auth = kwargs.get("litellm_metadata", {}).get("user_api_key_auth")
-            tool_results = await LiteLLM_Proxy_MCP_Handler._execute_tool_calls(tool_calls=tool_calls, user_api_key_auth=user_api_key_auth)
-            
+            user_api_key_auth = kwargs.get("litellm_metadata", {}).get(
+                "user_api_key_auth"
+            )
+            tool_results = await LiteLLM_Proxy_MCP_Handler._execute_tool_calls(
+                tool_calls=tool_calls, user_api_key_auth=user_api_key_auth
+            )
+
             if tool_results:
                 follow_up_input = LiteLLM_Proxy_MCP_Handler._create_follow_up_input(
-                    response=response, 
-                    tool_results=tool_results, 
-                    original_input=input
+                    response=response, tool_results=tool_results, original_input=input
                 )
-                
+
                 final_response = await LiteLLM_Proxy_MCP_Handler._make_follow_up_call(
                     follow_up_input=follow_up_input,
                     model=model,
                     all_tools=all_tools,
                     response_id=response.id,
-                    **call_params
+                    **call_params,
                 )
-                
+
                 # Add custom output elements to the final response
                 if isinstance(final_response, ResponsesAPIResponse):
-                    final_response = LiteLLM_Proxy_MCP_Handler._add_mcp_output_elements_to_response(
-                        response=final_response,
-                        mcp_tools_fetched=mcp_tools_fetched,
-                        tool_results=tool_results
+                    final_response = (
+                        LiteLLM_Proxy_MCP_Handler._add_mcp_output_elements_to_response(
+                            response=final_response,
+                            mcp_tools_fetched=mcp_tools_fetched,
+                            tool_results=tool_results,
+                        )
                     )
                 return final_response
-    
-    return response
 
+    return response
 
 
 @client
@@ -319,7 +335,9 @@ async def aresponses(
             )
 
         if response is None:
-            raise ValueError(f"Got an unexpected None response from the Responses API: {response}")
+            raise ValueError(
+                f"Got an unexpected None response from the Responses API: {response}"
+            )
 
         return response
     except Exception as e:
@@ -363,6 +381,7 @@ def responses(
     extra_body: Optional[Dict[str, Any]] = None,
     timeout: Optional[Union[float, httpx.Timeout]] = None,
     # LiteLLM specific params,
+    allowed_openai_params: Optional[List[str]] = None,
     custom_llm_provider: Optional[str] = None,
     **kwargs,
 ):
@@ -373,7 +392,7 @@ def responses(
     from litellm.responses.mcp.litellm_proxy_mcp_handler import (
         LiteLLM_Proxy_MCP_Handler,
     )
-    
+
     local_vars = locals()
     try:
         litellm_logging_obj: LiteLLMLoggingObj = kwargs.get("litellm_logging_obj")  # type: ignore
@@ -445,6 +464,7 @@ def responses(
                 model=model,
                 responses_api_provider_config=responses_api_provider_config,
                 response_api_optional_params=response_api_optional_params,
+                allowed_openai_params=allowed_openai_params,
             )
         )
 
diff --git a/litellm/responses/utils.py b/litellm/responses/utils.py
index b50c84ad46..2b3d178c26 100644
--- a/litellm/responses/utils.py
+++ b/litellm/responses/utils.py
@@ -1,5 +1,5 @@
 import base64
-from typing import Any, Dict, Optional, Union, cast, get_type_hints, overload
+from typing import Any, Dict, List, Optional, Union, cast, get_type_hints, overload
 
 import litellm
 from litellm._logging import verbose_logger
@@ -16,11 +16,38 @@ from litellm.types.utils import SpecialEnums, Usage
 class ResponsesAPIRequestUtils:
     """Helper utils for constructing ResponseAPI requests"""
 
+    @staticmethod
+    def _check_valid_arg(
+        supported_params: Optional[List[str]],
+        non_default_params: Dict,
+        drop_params: Optional[bool],
+        custom_llm_provider: Optional[str],
+        model: str,
+    ):
+
+        if supported_params is None:
+            return
+        unsupported_params = {}
+        for k in non_default_params.keys():
+            if k not in supported_params:
+                unsupported_params[k] = non_default_params[k]
+        if unsupported_params:
+            if litellm.drop_params is True or (
+                drop_params is not None and drop_params is True
+            ):
+                pass
+            else:
+                raise litellm.UnsupportedParamsError(
+                    status_code=500,
+                    message=f"{custom_llm_provider} does not support parameters: {unsupported_params}, for model={model}. To drop these, set `litellm.drop_params=True` or for proxy:\n\n`litellm_settings:\n drop_params: true`\n",
+                )
+
     @staticmethod
     def get_optional_params_responses_api(
         model: str,
         responses_api_provider_config: BaseResponsesAPIConfig,
         response_api_optional_params: ResponsesAPIOptionalRequestParams,
+        allowed_openai_params: Optional[List[str]] = None,
     ) -> Dict:
         """
         Get optional parameters for the responses API.
@@ -33,25 +60,23 @@ class ResponsesAPIRequestUtils:
         Returns:
             A dictionary of supported parameters for the responses API
         """
-        # Remove None values and internal parameters
+        from litellm.utils import _apply_openai_param_overrides
 
+        # Remove None values and internal parameters
         # Get supported parameters for the model
         supported_params = responses_api_provider_config.get_supported_openai_params(
             model
         )
 
+        non_default_params = cast(Dict, response_api_optional_params)
         # Check for unsupported parameters
-        unsupported_params = [
-            param
-            for param in response_api_optional_params
-            if param not in supported_params
-        ]
-
-        if unsupported_params:
-            raise litellm.UnsupportedParamsError(
-                model=model,
-                message=f"The following parameters are not supported for model {model}: {', '.join(unsupported_params)}",
-            )
+        ResponsesAPIRequestUtils._check_valid_arg(
+            supported_params=supported_params + (allowed_openai_params or []),
+            non_default_params=non_default_params,
+            drop_params=litellm.drop_params,
+            custom_llm_provider=responses_api_provider_config.custom_llm_provider,
+            model=model,
+        )
 
         # Map parameters to provider-specific format
         mapped_params = responses_api_provider_config.map_openai_params(
@@ -60,6 +85,13 @@ class ResponsesAPIRequestUtils:
             drop_params=litellm.drop_params,
         )
 
+        # add any allowed_openai_params to the mapped_params
+        mapped_params = _apply_openai_param_overrides(
+            optional_params=mapped_params,
+            non_default_params=non_default_params,
+            allowed_openai_params=allowed_openai_params or [],
+        )
+
         return mapped_params
 
     @staticmethod
@@ -75,34 +107,48 @@ class ResponsesAPIRequestUtils:
         Returns:
             ResponsesAPIOptionalRequestParams instance with only the valid parameters
         """
+        from litellm.utils import PreProcessNonDefaultParams
+
         valid_keys = get_type_hints(ResponsesAPIOptionalRequestParams).keys()
-        filtered_params = {
-            k: v for k, v in params.items() if k in valid_keys and v is not None
-        }
+        custom_llm_provider = params.pop("custom_llm_provider", None)
+        special_params = params.pop("kwargs")
+
+        additional_drop_params = params.pop("additional_drop_params", None)
+        non_default_params = (
+            PreProcessNonDefaultParams.base_pre_process_non_default_params(
+                passed_params=params,
+                special_params=special_params,
+                custom_llm_provider=custom_llm_provider,
+                additional_drop_params=additional_drop_params,
+                default_param_values={k: None for k in valid_keys},
+                additional_endpoint_specific_params=["input"],
+            )
+        )
 
         # decode previous_response_id if it's a litellm encoded id
-        if "previous_response_id" in filtered_params:
+        if "previous_response_id" in non_default_params:
             decoded_previous_response_id = ResponsesAPIRequestUtils.decode_previous_response_id_to_original_previous_response_id(
-                filtered_params["previous_response_id"]
+                non_default_params["previous_response_id"]
             )
-            filtered_params["previous_response_id"] = decoded_previous_response_id
+            non_default_params["previous_response_id"] = decoded_previous_response_id
 
-        if "metadata" in filtered_params:
+        if "metadata" in non_default_params:
             from litellm.utils import add_openai_metadata
 
-            filtered_params["metadata"] = add_openai_metadata(
-                filtered_params["metadata"]
+            non_default_params["metadata"] = add_openai_metadata(
+                non_default_params["metadata"]
             )
 
-        return cast(ResponsesAPIOptionalRequestParams, filtered_params)
-    
+        return cast(ResponsesAPIOptionalRequestParams, non_default_params)
+
+    # fmt: off
     @overload
     @staticmethod
     def _update_responses_api_response_id_with_model_id(
         responses_api_response: ResponsesAPIResponse,
         custom_llm_provider: Optional[str],
         litellm_metadata: Optional[Dict[str, Any]] = None,
-    ) -> ResponsesAPIResponse:
+    ) -> ResponsesAPIResponse: 
         ...
 
     @overload
@@ -111,9 +157,11 @@ class ResponsesAPIRequestUtils:
         responses_api_response: Dict[str, Any],
         custom_llm_provider: Optional[str],
         litellm_metadata: Optional[Dict[str, Any]] = None,
-    ) -> Dict[str, Any]:
+    ) -> Dict[str, Any]: 
         ...
 
+    # fmt: on
+
     @staticmethod
     def _update_responses_api_response_id_with_model_id(
         responses_api_response: Union[ResponsesAPIResponse, Dict[str, Any]],
diff --git a/litellm/types/llms/openai.py b/litellm/types/llms/openai.py
index f2f64fa3c5..db35037801 100644
--- a/litellm/types/llms/openai.py
+++ b/litellm/types/llms/openai.py
@@ -968,6 +968,10 @@ class ResponsesAPIOptionalRequestParams(TypedDict, total=False):
     service_tier: Optional[str]
     safety_identifier: Optional[str]
     prompt: Optional[PromptObject]
+    max_tool_calls: Optional[int]
+    prompt_cache_key: Optional[str]
+    stream_options: Optional[dict]
+    top_logprobs: Optional[int]
 
 
 class ResponsesAPIRequestParams(ResponsesAPIOptionalRequestParams, total=False):
diff --git a/tests/llm_translation/test_optional_params.py b/tests/llm_translation/test_optional_params.py
index 52f6d99fdf..0e1e34362b 100644
--- a/tests/llm_translation/test_optional_params.py
+++ b/tests/llm_translation/test_optional_params.py
@@ -1562,3 +1562,32 @@ def test_optional_params_image_gen_with_aspect_ratio():
         aspect_ratio="16:9",
     )
     assert optional_params["aspect_ratio"] == "16:9"
+
+
+def test_optional_params_responses_api_allowed_openai_params():
+    from litellm import responses
+    from unittest.mock import patch, MagicMock
+    from litellm.llms.custom_httpx.http_handler import HTTPHandler
+
+    client = HTTPHandler()
+
+    with patch.object(client, "post") as mock_post:
+        try:
+            response = litellm.responses(
+                model="openai/o1-pro",
+                input="Tell me a three sentence bedtime story about a unicorn.",
+                max_output_tokens=100,
+                top_logprobs=10,
+                allowed_openai_params=["top_logprobs"],
+                client=client,
+            )
+        except Exception as e:
+            import traceback
+
+            traceback.print_exc()
+            print("error: ", e)
+
+        mock_post.assert_called_once()
+        request_body = mock_post.call_args.kwargs
+        print("request_body: ", request_body)
+        assert "top_logprobs" in request_body["json"]

From ff7bdb629031c77dd40f570887f9c999565756cb Mon Sep 17 00:00:00 2001
From: Krrish Dholakia 
Date: Sat, 16 Aug 2025 00:41:11 -0700
Subject: [PATCH 020/151] fix(mistral/chat/transformation.py): handle empty
 message content for mistral calls

Fixes https://github.com/BerriAI/litellm/issues/13355
---
 litellm/llms/mistral/chat/transformation.py   |  95 +++++--
 .../llms/openai/chat/gpt_transformation.py    |   1 +
 tests/llm_translation/test_mistral_api.py     |  15 +
 .../test_mistral_chat_transformation.py       | 264 ++++++++++--------
 4 files changed, 232 insertions(+), 143 deletions(-)

diff --git a/litellm/llms/mistral/chat/transformation.py b/litellm/llms/mistral/chat/transformation.py
index b38a498247..dda497dac8 100644
--- a/litellm/llms/mistral/chat/transformation.py
+++ b/litellm/llms/mistral/chat/transformation.py
@@ -6,7 +6,18 @@ Why separate file? Make it easy to see how transformation works
 Docs - https://docs.mistral.ai/api/
 """
 
-from typing import Any, Coroutine, List, Literal, Optional, Tuple, Union, cast, overload
+from typing import (
+    Any,
+    Coroutine,
+    List,
+    Literal,
+    Optional,
+    Tuple,
+    Union,
+    cast,
+    get_type_hints,
+    overload,
+)
 
 import httpx
 
@@ -145,7 +156,9 @@ class MistralConfig(OpenAIGPTConfig):
         for param, value in non_default_params.items():
             if param == "max_tokens":
                 optional_params["max_tokens"] = value
-            if param == "max_completion_tokens":  # max_completion_tokens should take priority
+            if (
+                param == "max_completion_tokens"
+            ):  # max_completion_tokens should take priority
                 optional_params["max_tokens"] = value
             if param == "tools":
                 # Clean tools to remove problematic schema fields for Mistral API
@@ -159,7 +172,9 @@ class MistralConfig(OpenAIGPTConfig):
             if param == "stop":
                 optional_params["stop"] = value
             if param == "tool_choice" and isinstance(value, str):
-                optional_params["tool_choice"] = self._map_tool_choice(tool_choice=value)
+                optional_params["tool_choice"] = self._map_tool_choice(
+                    tool_choice=value
+                )
             if param == "seed":
                 optional_params["extra_body"] = {"random_seed": value}
             if param == "response_format":
@@ -185,7 +200,9 @@ class MistralConfig(OpenAIGPTConfig):
         )  # type: ignore
 
         # if api_base does not end with /v1 we add it
-        if api_base is not None and not api_base.endswith("/v1"):  # Mistral always needs a /v1 at the end
+        if api_base is not None and not api_base.endswith(
+            "/v1"
+        ):  # Mistral always needs a /v1 at the end
             api_base = api_base + "/v1"
         dynamic_api_key = (
             api_key
@@ -194,10 +211,12 @@ class MistralConfig(OpenAIGPTConfig):
         )
         return api_base, dynamic_api_key
 
+    # fmt: off
+
     @overload
     def _transform_messages(
         self, messages: List[AllMessageValues], model: str, is_async: Literal[True]
-    ) -> Coroutine[Any, Any, List[AllMessageValues]]:
+    ) -> Coroutine[Any, Any, List[AllMessageValues]]: 
         ...
 
     @overload
@@ -206,8 +225,9 @@ class MistralConfig(OpenAIGPTConfig):
         messages: List[AllMessageValues],
         model: str,
         is_async: Literal[False] = False,
-    ) -> List[AllMessageValues]:
+    ) -> List[AllMessageValues]: 
         ...
+    # fmt: on
 
     def _transform_messages(
         self, messages: List[AllMessageValues], model: str, is_async: bool = False
@@ -239,6 +259,8 @@ class MistralConfig(OpenAIGPTConfig):
         for m in messages:
             m = MistralConfig._handle_name_in_message(m)
             m = MistralConfig._handle_tool_call_message(m)
+            if MistralConfig._is_empty_assistant_message(m):
+                continue
             m = strip_none_values_from_message(m)  # prevents 'extra_forbidden' error
             new_messages.append(m)
 
@@ -269,20 +291,30 @@ class MistralConfig(OpenAIGPTConfig):
                     # Handle both string and list content, preserving original format
                     if isinstance(existing_content, str):
                         # String content - prepend reasoning prompt
-                        new_content: Union[str, list] = f"{reasoning_prompt}\n\n{existing_content}"
+                        new_content: Union[str, list] = (
+                            f"{reasoning_prompt}\n\n{existing_content}"
+                        )
                     elif isinstance(existing_content, list):
                         # List content - prepend reasoning prompt as text block
-                        new_content = [{"type": "text", "text": reasoning_prompt + "\n\n"}] + existing_content
+                        new_content = [
+                            {"type": "text", "text": reasoning_prompt + "\n\n"}
+                        ] + existing_content
                     else:
                         # Fallback for any other type - convert to string
                         new_content = f"{reasoning_prompt}\n\n{str(existing_content)}"
 
-                    messages[i] = cast(AllMessageValues, {**msg, "content": new_content})
+                    messages[i] = cast(
+                        AllMessageValues, {**msg, "content": new_content}
+                    )
                     break
         else:
             # Add new system message with reasoning instructions
             reasoning_message: AllMessageValues = cast(
-                AllMessageValues, {"role": "system", "content": self._get_mistral_reasoning_system_prompt()}
+                AllMessageValues,
+                {
+                    "role": "system",
+                    "content": self._get_mistral_reasoning_system_prompt(),
+                },
             )
             messages = [reasoning_message] + messages
 
@@ -294,32 +326,34 @@ class MistralConfig(OpenAIGPTConfig):
     def _clean_tool_schema_for_mistral(cls, tools: list) -> list:
         """
         Clean tool schemas to remove fields that cause issues with Mistral API.
-        
+
         Removes:
         - $id and $schema fields (cause grammar validation errors)
         - additionalProperties=False (causes OpenAI API schema errors)
         - strict field (not supported by Mistral)
-        
+
         Args:
             tools: List of tool definitions
             max_depth: Maximum recursion depth for schema cleaning (default: 10)
-        
+
         Returns:
             Cleaned tools list
         """
         if not tools:
             return tools
-            
+
         import copy
 
         from litellm.constants import DEFAULT_MAX_RECURSE_DEPTH
         from litellm.utils import _remove_json_schema_refs
 
         cleaned_tools = copy.deepcopy(tools)
-        
+
         # Apply all cleaning functions with max_depth protection
-        cleaned_tools = _remove_json_schema_refs(cleaned_tools, max_depth=DEFAULT_MAX_RECURSE_DEPTH)
-        
+        cleaned_tools = _remove_json_schema_refs(
+            cleaned_tools, max_depth=DEFAULT_MAX_RECURSE_DEPTH
+        )
+
         return cleaned_tools
 
     @classmethod
@@ -360,6 +394,25 @@ class MistralConfig(OpenAIGPTConfig):
             message["tool_calls"] = mistral_tool_calls  # type: ignore
         return message
 
+    @classmethod
+    def _is_empty_assistant_message(cls, message: AllMessageValues) -> bool:
+        """
+        Mistral API does not support empty string in assistant content.
+        """
+        from litellm.types.llms.openai import ChatCompletionAssistantMessage
+
+        set_keys = get_type_hints(ChatCompletionAssistantMessage).keys()
+
+        all_expected_values_are_empty = True
+        for key in set_keys:
+            if key != "role" and message.get(key) is not None:
+                if key == "content" and message.get(key) == "":
+                    continue
+                else:
+                    all_expected_values_are_empty = False
+                    break
+        return all_expected_values_are_empty
+
     @staticmethod
     def _handle_empty_content_response(response_data: dict) -> dict:
         """
@@ -396,8 +449,12 @@ class MistralConfig(OpenAIGPTConfig):
             dict: The transformed request. Sent as the body of the API call.
         """
         # Add reasoning system prompt if needed (for magistral models)
-        if "magistral" in model.lower() and optional_params.get("_add_reasoning_prompt", False):
-            messages = self._add_reasoning_system_prompt_if_needed(messages, optional_params)
+        if "magistral" in model.lower() and optional_params.get(
+            "_add_reasoning_prompt", False
+        ):
+            messages = self._add_reasoning_system_prompt_if_needed(
+                messages, optional_params
+            )
 
         # Call parent transform_request which handles _transform_messages
         return super().transform_request(
diff --git a/litellm/llms/openai/chat/gpt_transformation.py b/litellm/llms/openai/chat/gpt_transformation.py
index 396d59145f..6e97fde3fe 100644
--- a/litellm/llms/openai/chat/gpt_transformation.py
+++ b/litellm/llms/openai/chat/gpt_transformation.py
@@ -348,6 +348,7 @@ class OpenAIGPTConfig(BaseLLMModelInfo, BaseConfig):
             for message in messages:
                 message_content = message.get("content")
                 message_role = message.get("role")
+
                 if (
                     message_role == "user"
                     and message_content
diff --git a/tests/llm_translation/test_mistral_api.py b/tests/llm_translation/test_mistral_api.py
index 8cf704fbe8..04a9243420 100644
--- a/tests/llm_translation/test_mistral_api.py
+++ b/tests/llm_translation/test_mistral_api.py
@@ -37,3 +37,18 @@ class TestMistralCompletion(BaseLLMChatTest):
     def test_tool_call_no_arguments(self, tool_call_no_arguments):
         """Test that tool calls with no arguments is translated correctly. Relevant issue: https://github.com/BerriAI/litellm/issues/6833"""
         pass
+
+
+def test_empty_str_in_assistant_content():
+    """Test that empty string in assistant content is converted to None."""
+    litellm._turn_on_debug()
+    response = litellm.completion(
+        model="mistral/mistral-medium-latest",
+        messages=[
+            {"role": "user", "content": "Hello, how are you?"},
+            {"role": "assistant", "content": ""},
+            {"role": "user", "content": "Hi again"},
+        ],
+        max_tokens=10,
+    )
+    assert response.choices[0].message.content is not None
diff --git a/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py b/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py
index 3e4d3ddb30..dd48bae392 100644
--- a/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py
+++ b/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py
@@ -40,21 +40,25 @@ class TestMistralReasoningSupport:
     def test_get_supported_openai_params_magistral_model(self):
         """Test that magistral models support reasoning parameters."""
         mistral_config = MistralConfig()
-        
+
         # Test magistral model supports reasoning parameters
-        supported_params = mistral_config.get_supported_openai_params("mistral/magistral-medium-2506")
+        supported_params = mistral_config.get_supported_openai_params(
+            "mistral/magistral-medium-2506"
+        )
         assert "reasoning_effort" in supported_params
         assert "thinking" in supported_params
-        
+
         # Test non-magistral model doesn't include reasoning parameters
-        supported_params_normal = mistral_config.get_supported_openai_params("mistral/mistral-large-latest")
+        supported_params_normal = mistral_config.get_supported_openai_params(
+            "mistral/mistral-large-latest"
+        )
         assert "reasoning_effort" not in supported_params_normal
         assert "thinking" not in supported_params_normal
 
     def test_map_openai_params_reasoning_effort(self):
         """Test that reasoning_effort parameter is properly mapped for magistral models."""
         mistral_config = MistralConfig()
-        
+
         # Test reasoning_effort mapping for magistral model
         optional_params = {}
         result = mistral_config.map_openai_params(
@@ -63,9 +67,9 @@ class TestMistralReasoningSupport:
             model="mistral/magistral-medium-2506",
             drop_params=False,
         )
-        
+
         assert result.get("_add_reasoning_prompt") is True
-        
+
         # Test reasoning_effort ignored for non-magistral model
         optional_params_normal = {}
         result_normal = mistral_config.map_openai_params(
@@ -74,13 +78,13 @@ class TestMistralReasoningSupport:
             model="mistral/mistral-large-latest",
             drop_params=False,
         )
-        
+
         assert "_add_reasoning_prompt" not in result_normal
 
     def test_map_openai_params_thinking(self):
         """Test that thinking parameter is properly mapped for magistral models."""
         mistral_config = MistralConfig()
-        
+
         # Test thinking mapping for magistral model
         optional_params = {}
         result = mistral_config.map_openai_params(
@@ -89,7 +93,7 @@ class TestMistralReasoningSupport:
             model="mistral/magistral-small-2506",
             drop_params=False,
         )
-        
+
         assert result.get("_add_reasoning_prompt") is True
 
     def test_get_mistral_reasoning_system_prompt(self):
@@ -101,109 +105,123 @@ class TestMistralReasoningSupport:
     def test_add_reasoning_system_prompt_no_existing_system_message(self):
         """Test adding reasoning system prompt when no system message exists."""
         mistral_config = MistralConfig()
-        
-        messages = [
-            {"role": "user", "content": "What is 2+2?"}
-        ]
+
+        messages = [{"role": "user", "content": "What is 2+2?"}]
         optional_params = {"_add_reasoning_prompt": True}
-        
-        result = mistral_config._add_reasoning_system_prompt_if_needed(messages, optional_params)
-        
+
+        result = mistral_config._add_reasoning_system_prompt_if_needed(
+            messages, optional_params
+        )
+
         # Should add a new system message at the beginning
         assert len(result) == 2
         assert result[0]["role"] == "system"
         assert "" in result[0]["content"]
         assert result[1]["role"] == "user"
         assert result[1]["content"] == "What is 2+2?"
-        
+
         # Should remove the internal flag
         assert "_add_reasoning_prompt" not in optional_params
 
     def test_add_reasoning_system_prompt_with_existing_system_message(self):
         """Test adding reasoning system prompt when system message already exists."""
         mistral_config = MistralConfig()
-        
+
         messages = [
             {"role": "system", "content": "You are a helpful assistant."},
-            {"role": "user", "content": "What is 2+2?"}
+            {"role": "user", "content": "What is 2+2?"},
         ]
         optional_params = {"_add_reasoning_prompt": True}
-        
-        result = mistral_config._add_reasoning_system_prompt_if_needed(messages, optional_params)
-        
+
+        result = mistral_config._add_reasoning_system_prompt_if_needed(
+            messages, optional_params
+        )
+
         # Should modify existing system message
         assert len(result) == 2
         assert result[0]["role"] == "system"
         assert "" in result[0]["content"]
         assert "You are a helpful assistant." in result[0]["content"]
         assert result[1]["role"] == "user"
-        
+
         # Should remove the internal flag
         assert "_add_reasoning_prompt" not in optional_params
 
     def test_add_reasoning_system_prompt_with_existing_list_content(self):
         """Test adding reasoning system prompt when system message has list content."""
         mistral_config = MistralConfig()
-        
+
         messages = [
             {
-                "role": "system", 
+                "role": "system",
                 "content": [
                     {"type": "text", "text": "You are a helpful assistant."},
-                    {"type": "text", "text": "You always provide detailed explanations."}
-                ]
+                    {
+                        "type": "text",
+                        "text": "You always provide detailed explanations.",
+                    },
+                ],
             },
-            {"role": "user", "content": "What is 2+2?"}
+            {"role": "user", "content": "What is 2+2?"},
         ]
         optional_params = {"_add_reasoning_prompt": True}
-        
-        result = mistral_config._add_reasoning_system_prompt_if_needed(messages, optional_params)
-        
+
+        result = mistral_config._add_reasoning_system_prompt_if_needed(
+            messages, optional_params
+        )
+
         # Should modify existing system message preserving list format
         assert len(result) == 2
         assert result[0]["role"] == "system"
         assert isinstance(result[0]["content"], list)
-        
+
         # First item should be the reasoning prompt
         assert result[0]["content"][0]["type"] == "text"
         assert "" in result[0]["content"][0]["text"]
-        
+
         # Original content should be preserved
         assert "You are a helpful assistant." in result[0]["content"][1]["text"]
-        assert "You always provide detailed explanations." in result[0]["content"][2]["text"]
-        
+        assert (
+            "You always provide detailed explanations."
+            in result[0]["content"][2]["text"]
+        )
+
         assert result[1]["role"] == "user"
-        
+
         # Should remove the internal flag
         assert "_add_reasoning_prompt" not in optional_params
 
     def test_add_reasoning_system_prompt_preserves_content_types(self):
         """Test that reasoning prompt preserves original content types (string vs list)."""
         mistral_config = MistralConfig()
-        
+
         # Test with string content
         string_messages = [
             {"role": "system", "content": "You are helpful."},
-            {"role": "user", "content": "Hello"}
+            {"role": "user", "content": "Hello"},
         ]
         string_params = {"_add_reasoning_prompt": True}
-        
-        string_result = mistral_config._add_reasoning_system_prompt_if_needed(string_messages, string_params)
+
+        string_result = mistral_config._add_reasoning_system_prompt_if_needed(
+            string_messages, string_params
+        )
         assert isinstance(string_result[0]["content"], str)
         assert "" in string_result[0]["content"]
         assert "You are helpful." in string_result[0]["content"]
-        
+
         # Test with list content
         list_messages = [
             {
-                "role": "system", 
-                "content": [{"type": "text", "text": "You are helpful."}]
+                "role": "system",
+                "content": [{"type": "text", "text": "You are helpful."}],
             },
-            {"role": "user", "content": "Hello"}
+            {"role": "user", "content": "Hello"},
         ]
         list_params = {"_add_reasoning_prompt": True}
-        
-        list_result = mistral_config._add_reasoning_system_prompt_if_needed(list_messages, list_params)
+
+        list_result = mistral_config._add_reasoning_system_prompt_if_needed(
+            list_messages, list_params
+        )
         assert isinstance(list_result[0]["content"], list)
         assert list_result[0]["content"][0]["type"] == "text"
         assert "" in list_result[0]["content"][0]["text"]
@@ -212,14 +230,14 @@ class TestMistralReasoningSupport:
     def test_add_reasoning_system_prompt_no_flag(self):
         """Test that no modification happens when _add_reasoning_prompt flag is not set."""
         mistral_config = MistralConfig()
-        
-        messages = [
-            {"role": "user", "content": "What is 2+2?"}
-        ]
+
+        messages = [{"role": "user", "content": "What is 2+2?"}]
         optional_params = {}
-        
-        result = mistral_config._add_reasoning_system_prompt_if_needed(messages, optional_params)
-        
+
+        result = mistral_config._add_reasoning_system_prompt_if_needed(
+            messages, optional_params
+        )
+
         # Should return messages unchanged
         assert result == messages
         assert len(result) == 1
@@ -227,46 +245,42 @@ class TestMistralReasoningSupport:
     def test_transform_request_magistral_with_reasoning(self):
         """Test transform_request method for magistral model with reasoning."""
         mistral_config = MistralConfig()
-        
-        messages = [
-            {"role": "user", "content": "What is 15 * 7?"}
-        ]
+
+        messages = [{"role": "user", "content": "What is 15 * 7?"}]
         optional_params = {"_add_reasoning_prompt": True}
-        
+
         result = mistral_config.transform_request(
             model="mistral/magistral-medium-2506",
             messages=messages,
             optional_params=optional_params,
             litellm_params={},
-            headers={}
+            headers={},
         )
-        
+
         # Should have added system message
         assert len(result["messages"]) == 2
         assert result["messages"][0]["role"] == "system"
         assert "" in result["messages"][0]["content"]
         assert result["messages"][1]["role"] == "user"
-        
+
         # Should remove internal flag from optional_params
         assert "_add_reasoning_prompt" not in result
 
     def test_transform_request_magistral_without_reasoning(self):
         """Test transform_request method for magistral model without reasoning."""
         mistral_config = MistralConfig()
-        
-        messages = [
-            {"role": "user", "content": "What is 15 * 7?"}
-        ]
+
+        messages = [{"role": "user", "content": "What is 15 * 7?"}]
         optional_params = {}
-        
+
         result = mistral_config.transform_request(
             model="mistral/magistral-medium-2506",
             messages=messages,
             optional_params=optional_params,
             litellm_params={},
-            headers={}
+            headers={},
         )
-        
+
         # Should not modify messages
         assert len(result["messages"]) == 1
         assert result["messages"][0]["role"] == "user"
@@ -274,20 +288,18 @@ class TestMistralReasoningSupport:
     def test_transform_request_non_magistral_with_reasoning_params(self):
         """Test that non-magistral models ignore reasoning parameters."""
         mistral_config = MistralConfig()
-        
-        messages = [
-            {"role": "user", "content": "What is 15 * 7?"}
-        ]
+
+        messages = [{"role": "user", "content": "What is 15 * 7?"}]
         optional_params = {"_add_reasoning_prompt": True}
-        
+
         result = mistral_config.transform_request(
             model="mistral/mistral-large-latest",
             messages=messages,
             optional_params=optional_params,
             litellm_params={},
-            headers={}
+            headers={},
         )
-        
+
         # Should not add system message for non-magistral models
         assert len(result["messages"]) == 1
         assert result["messages"][0]["role"] == "user"
@@ -295,15 +307,15 @@ class TestMistralReasoningSupport:
     def test_case_insensitive_magistral_detection(self):
         """Test that magistral model detection is case-insensitive."""
         mistral_config = MistralConfig()
-        
+
         # Test various case combinations
         models_to_test = [
             "mistral/Magistral-medium-2506",
             "mistral/MAGISTRAL-MEDIUM-2506",
             "mistral/magistral-SMALL-2506",
-            "MaGiStRaL-medium-2506"
+            "MaGiStRaL-medium-2506",
         ]
-        
+
         for model in models_to_test:
             supported_params = mistral_config.get_supported_openai_params(model)
             assert "reasoning_effort" in supported_params, f"Failed for model: {model}"
@@ -311,7 +323,7 @@ class TestMistralReasoningSupport:
     def test_end_to_end_reasoning_workflow(self):
         """Test the complete workflow from parameter to system prompt injection."""
         mistral_config = MistralConfig()
-        
+
         # Step 1: Map parameters
         optional_params = {}
         mapped_params = mistral_config.map_openai_params(
@@ -320,23 +332,21 @@ class TestMistralReasoningSupport:
             model="mistral/magistral-medium-2506",
             drop_params=False,
         )
-        
+
         assert mapped_params.get("_add_reasoning_prompt") is True
         assert mapped_params.get("temperature") == 0.7
-        
+
         # Step 2: Transform request
-        messages = [
-            {"role": "user", "content": "Solve for x: 2x + 5 = 13"}
-        ]
-        
+        messages = [{"role": "user", "content": "Solve for x: 2x + 5 = 13"}]
+
         result = mistral_config.transform_request(
             model="mistral/magistral-medium-2506",
             messages=messages,
             optional_params=mapped_params,
             litellm_params={},
-            headers={}
+            headers={},
         )
-        
+
         # Verify final result
         assert len(result["messages"]) == 2
         assert result["messages"][0]["role"] == "system"
@@ -347,7 +357,6 @@ class TestMistralReasoningSupport:
         assert "_add_reasoning_prompt" not in result
 
 
-
 class TestMistralNameHandling:
     """Test suite for Mistral name handling in messages."""
 
@@ -363,7 +372,11 @@ class TestMistralNameHandling:
     def test_handle_name_in_message_tool_role_valid_name_keeps_name(self):
         """Test that valid name is kept for tool messages."""
         # Test with normal function name
-        tool_message = {"role": "tool", "content": "Function result", "name": "get_weather"}
+        tool_message = {
+            "role": "tool",
+            "content": "Function result",
+            "name": "get_weather",
+        }
         result = MistralConfig._handle_name_in_message(tool_message)
         assert "name" in result
         assert result["name"] == "get_weather"
@@ -386,26 +399,26 @@ class TestMistralParallelToolCalls:
     def test_get_supported_openai_params_includes_parallel_tool_calls(self):
         """Test that parallel_tool_calls is in supported parameters."""
         mistral_config = MistralConfig()
-        supported_params = mistral_config.get_supported_openai_params("mistral/mistral-large-latest")
+        supported_params = mistral_config.get_supported_openai_params(
+            "mistral/mistral-large-latest"
+        )
         assert "parallel_tool_calls" in supported_params
 
     def test_transform_request_preserves_parallel_tool_calls(self):
         """Test that transform_request preserves parallel_tool_calls parameter."""
         mistral_config = MistralConfig()
-        
-        messages = [
-            {"role": "user", "content": "What's the weather like?"}
-        ]
+
+        messages = [{"role": "user", "content": "What's the weather like?"}]
         optional_params = {"parallel_tool_calls": True}
-        
+
         result = mistral_config.transform_request(
             model="mistral/mistral-large-latest",
             messages=messages,
             optional_params=optional_params,
             litellm_params={},
-            headers={}
+            headers={},
         )
-        
+
         assert result.get("parallel_tool_calls") is True
         assert len(result["messages"]) == 1
         assert result["messages"][0]["role"] == "user"
@@ -419,17 +432,14 @@ class TestMistralEmptyContentHandling:
         response_data = {
             "choices": [
                 {
-                    "message": {
-                        "content": "",
-                        "role": "assistant"
-                    },
-                    "finish_reason": "stop"
+                    "message": {"content": "", "role": "assistant"},
+                    "finish_reason": "stop",
                 }
             ]
         }
-        
+
         result = MistralConfig._handle_empty_content_response(response_data)
-        
+
         assert result["choices"][0]["message"]["content"] is None
 
     def test_handle_empty_content_response_preserves_actual_content(self):
@@ -439,41 +449,47 @@ class TestMistralEmptyContentHandling:
                 {
                     "message": {
                         "content": "Hello, how can I help you?",
-                        "role": "assistant"
+                        "role": "assistant",
                     },
-                    "finish_reason": "stop"
+                    "finish_reason": "stop",
                 }
             ]
         }
-        
+
         result = MistralConfig._handle_empty_content_response(response_data)
-        
-        assert result["choices"][0]["message"]["content"] == "Hello, how can I help you?"
+
+        assert (
+            result["choices"][0]["message"]["content"] == "Hello, how can I help you?"
+        )
 
     def test_handle_empty_content_response_handles_multiple_choices(self):
         """Test that only the first choice is processed for empty content."""
         response_data = {
             "choices": [
                 {
-                    "message": {
-                        "content": "",
-                        "role": "assistant"
-                    },
-                    "finish_reason": "stop"
+                    "message": {"content": "", "role": "assistant"},
+                    "finish_reason": "stop",
                 },
                 {
-                    "message": {
-                        "content": "",
-                        "role": "assistant"  
-                    },
-                    "finish_reason": "stop"
-                }
+                    "message": {"content": "", "role": "assistant"},
+                    "finish_reason": "stop",
+                },
             ]
         }
-        
+
         result = MistralConfig._handle_empty_content_response(response_data)
-        
+
         # Only first choice should be converted to None
         assert result["choices"][0]["message"]["content"] is None
         # Second choice should remain as empty string
-        assert result["choices"][1]["message"]["content"] is None
\ No newline at end of file
+        assert result["choices"][1]["message"]["content"] is None
+
+    def test_is_empty_assistant_message(self):
+        """Test that is_empty_assistant_message returns True for empty assistant message."""
+        message = {"role": "assistant", "content": ""}
+        assert MistralConfig._is_empty_assistant_message(message) is True
+
+    def test_is_empty_assistant_message_with_content(self):
+        """Test that is_empty_assistant_message returns False for assistant message with content."""
+        message = {"role": "assistant", "content": "Hello"}
+        assert MistralConfig._is_empty_assistant_message(message) is False

From 675d73fb9b80de90f56669b550ea22d5d9b26c9c Mon Sep 17 00:00:00 2001
From: Krrish Dholakia 
Date: Sat, 16 Aug 2025 01:16:01 -0700
Subject: [PATCH 021/151] fix(mistral/chat/transformation.py): Support new
 mistral thinking block

Closes https://github.com/BerriAI/litellm/issues/13416
---
 litellm/llms/mistral/chat/transformation.py   |  64 +++++++++-
 litellm/types/llms/mistral.py                 |  10 ++
 .../test_mistral_chat_transformation.py       | 110 ++++++++++++++++++
 3 files changed, 181 insertions(+), 3 deletions(-)

diff --git a/litellm/llms/mistral/chat/transformation.py b/litellm/llms/mistral/chat/transformation.py
index dda497dac8..385057bb45 100644
--- a/litellm/llms/mistral/chat/transformation.py
+++ b/litellm/llms/mistral/chat/transformation.py
@@ -28,7 +28,11 @@ from litellm.litellm_core_utils.prompt_templates.common_utils import (
 )
 from litellm.llms.openai.chat.gpt_transformation import OpenAIGPTConfig
 from litellm.secret_managers.main import get_secret_str
-from litellm.types.llms.mistral import MistralToolCallMessage
+from litellm.types.llms.mistral import (
+    MistralTextBlock,
+    MistralThinkingBlock,
+    MistralToolCallMessage,
+)
 from litellm.types.llms.openai import AllMessageValues
 from litellm.types.utils import ModelResponse
 from litellm.utils import convert_to_model_response_object
@@ -433,6 +437,58 @@ class MistralConfig(OpenAIGPTConfig):
                     choice["message"]["content"] = None
         return response_data
 
+    @staticmethod
+    def _convert_thinking_block_to_reasoning_content(
+        thinking_blocks: MistralThinkingBlock,
+    ) -> str:
+        """
+        Convert Mistral thinking blocks to reasoning content.
+        """
+        return "\n".join(
+            [block.get("text", "") for block in thinking_blocks["thinking"]]
+        )
+
+    @staticmethod
+    def _handle_content_list_to_str_conversion(response_data: dict) -> dict:
+        """
+        Handle Mistral's content list format and extract thinking content.
+
+        Map mistral's content list to string and extract thinking blocks:
+        - Thinking block -> reasoning_content field
+        - Text block -> content field
+        """
+
+        if response_data.get("choices") and len(response_data["choices"]) > 0:
+            for choice in response_data["choices"]:
+                if choice.get("message") and choice["message"].get("content"):
+                    content = choice["message"]["content"]
+
+                    # Only process if content is a list
+                    if isinstance(content, list):
+                        thinking_content = ""
+                        text_content = ""
+
+                        # Process each content block
+                        for block in content:
+                            if block.get("type") == "thinking":
+                                thinking_blocks = block.get("thinking", [])
+                                thinking_texts = []
+                                for thinking_block in thinking_blocks:
+                                    if thinking_block.get("type") == "text":
+                                        thinking_texts.append(
+                                            thinking_block.get("text", "")
+                                        )
+                                thinking_content = "\n".join(thinking_texts)
+                            elif block.get("type") == "text":
+                                text_content = block.get("text", "")
+
+                        # Set the extracted content
+                        choice["message"]["content"] = text_content
+                        if thinking_content:
+                            choice["message"]["reasoning_content"] = thinking_content
+
+        return response_data
+
     def transform_request(
         self,
         model: str,
@@ -481,14 +537,16 @@ class MistralConfig(OpenAIGPTConfig):
     ) -> ModelResponse:
         """
         Transform the raw response from Mistral API.
-        Handles Mistral-specific behavior like converting empty string content to None.
+        Handles Mistral-specific behavior like converting empty string content to None
+        and extracting thinking content from content lists.
         """
         logging_obj.post_call(original_response=raw_response.text)
         logging_obj.model_call_details["response_headers"] = raw_response.headers
 
-        # Handle Mistral-specific empty string content conversion to None
+        # Handle Mistral-specific response transformations
         response_data = raw_response.json()
         response_data = self._handle_empty_content_response(response_data)
+        response_data = self._handle_content_list_to_str_conversion(response_data)
 
         final_response_obj = cast(
             ModelResponse,
diff --git a/litellm/types/llms/mistral.py b/litellm/types/llms/mistral.py
index e9563a9ae3..375120e537 100644
--- a/litellm/types/llms/mistral.py
+++ b/litellm/types/llms/mistral.py
@@ -10,3 +10,13 @@ class MistralToolCallMessage(TypedDict):
     id: Optional[str]
     type: Literal["function"]
     function: Optional[FunctionCall]
+
+
+class MistralTextBlock(TypedDict):
+    type: Literal["text"]
+    text: str
+
+
+class MistralThinkingBlock(TypedDict):
+    type: Literal["thinking"]
+    thinking: List[MistralTextBlock]
diff --git a/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py b/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py
index dd48bae392..d1859c2c5b 100644
--- a/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py
+++ b/tests/test_litellm/llms/mistral/test_mistral_chat_transformation.py
@@ -9,6 +9,7 @@ sys.path.insert(
 )  # Adds the parent directory to the system path
 
 from litellm.llms.mistral.chat.transformation import MistralConfig
+from litellm.types.utils import ModelResponse
 
 
 @pytest.mark.asyncio
@@ -424,6 +425,115 @@ class TestMistralParallelToolCalls:
         assert result["messages"][0]["role"] == "user"
 
 
+class TestMistralThinkingContentHandling:
+    """Test suite for Mistral thinking content response handling functionality."""
+
+    def test_transform_response_with_thinking_content(self):
+        """Test that Mistral responses with thinking content are correctly transformed."""
+        import json
+        from unittest.mock import Mock
+
+        import litellm
+
+        # Raw response from Mistral with thinking content
+        raw_response_data = {
+            "id": "12a18e1439f24f95b9812a016e0af235",
+            "choices": [
+                {
+                    "finish_reason": "stop",
+                    "index": 0,
+                    "logprobs": None,
+                    "message": {
+                        "content": [
+                            {
+                                "type": "thinking",
+                                "thinking": [
+                                    {
+                                        "type": "text",
+                                        "text": "Well, the capital of France is a well-known fact. It's Paris. But just to be sure, I recall that Paris is indeed the capital city of France. I don't need to look it up because it's a common knowledge fact. But if I were unsure, I would double-check using a reliable source or a knowledge base. Since I'm confident about this, I can provide the answer directly.",
+                                    }
+                                ],
+                            },
+                            {"type": "text", "text": "The capital of France is Paris."},
+                        ],
+                        "refusal": None,
+                        "role": "assistant",
+                        "annotations": None,
+                        "audio": None,
+                        "function_call": None,
+                        "tool_calls": None,
+                    },
+                }
+            ],
+            "created": 1754654178,
+            "model": "magistral-medium-2507",
+            "object": "chat.completion",
+            "service_tier": None,
+            "system_fingerprint": None,
+            "usage": {
+                "completion_tokens": 93,
+                "prompt_tokens": 11,
+                "total_tokens": 104,
+                "completion_tokens_details": None,
+                "prompt_tokens_details": None,
+            },
+        }
+
+        # Mock httpx response
+        mock_response = Mock()
+        mock_response.json.return_value = raw_response_data
+        mock_response.headers = {}
+        mock_response.text = json.dumps(raw_response_data)
+
+        # Mock logging object with proper attributes
+        mock_logging_obj = Mock()
+        mock_logging_obj.model_call_details = {}
+
+        # Test the transformation
+        mistral_config = MistralConfig()
+        model_response = litellm.ModelResponse()
+
+        # Test transform_response method
+        final_response = mistral_config.transform_response(
+            model="mistral/magistral-medium-2507",
+            raw_response=mock_response,
+            model_response=model_response,
+            logging_obj=mock_logging_obj,
+            request_data={},
+            messages=[{"role": "user", "content": "What is the capital of France?"}],
+            optional_params={},
+            litellm_params={},
+            encoding=None,
+        )
+
+        # Verify the response structure
+        assert final_response is not None
+        assert len(final_response.choices) == 1
+        choice = final_response.choices[0]
+
+        # Verify message content
+        message = choice.message
+        assert message.role == "assistant"
+
+        # The content should be processed - either as text or as thinking blocks
+        # Content could be the text part or the full content list
+        content_str = str(message.content) if message.content else ""
+
+        # Verify the actual text content is preserved somewhere
+        assert "The capital of France is Paris." in content_str or (
+            hasattr(message, "thinking_blocks") and message.thinking_blocks
+        )
+
+        # Verify usage information
+        assert final_response.usage.completion_tokens == 93
+        assert final_response.usage.prompt_tokens == 11
+        assert final_response.usage.total_tokens == 104
+
+        # Verify model and metadata
+        assert final_response.id == "12a18e1439f24f95b9812a016e0af235"
+        assert final_response.created == 1754654178
+
+
 class TestMistralEmptyContentHandling:
     """Test suite for Mistral empty content response handling functionality."""
 

From 5b641380ab3df4c9c0435632c2e1658c05befa08 Mon Sep 17 00:00:00 2001
From: Krrish Dholakia 
Date: Sat, 16 Aug 2025 01:49:54 -0700
Subject: [PATCH 022/151] fix(openai/responses/transformation.py): update
 supported openai params

---
 .../llms/openai/responses/transformation.py   | 44 +++++++------------
 .../test_openai_responses_transformation.py   | 34 ++++++++++----
 2 files changed, 41 insertions(+), 37 deletions(-)

diff --git a/litellm/llms/openai/responses/transformation.py b/litellm/llms/openai/responses/transformation.py
index 40aae5a1ce..e70cadddaf 100644
--- a/litellm/llms/openai/responses/transformation.py
+++ b/litellm/llms/openai/responses/transformation.py
@@ -1,4 +1,4 @@
-from typing import TYPE_CHECKING, Any, Dict, Optional, Union, cast
+from typing import TYPE_CHECKING, Any, Dict, Optional, Union, cast, get_type_hints
 
 import httpx
 from pydantic import BaseModel
@@ -34,34 +34,20 @@ class OpenAIResponsesAPIConfig(BaseResponsesAPIConfig):
         """
         All OpenAI Responses API params are supported
         """
-        return [
-            "input",
-            "model",
-            "include",
-            "instructions",
-            "max_output_tokens",
-            "metadata",
-            "parallel_tool_calls",
-            "previous_response_id",
-            "reasoning",
-            "store",
-            "background",
-            "stream",
-            "prompt",
-            "temperature",
-            "text",
-            "tool_choice",
-            "tools",
-            "top_p",
-            "truncation",
-            "user",
-            "service_tier",
-            "safety_identifier",
-            "extra_headers",
-            "extra_query",
-            "extra_body",
-            "timeout",
-        ]
+        supported_params = get_type_hints(ResponsesAPIRequestParams).keys()
+        return list(
+            set(
+                [
+                    "input",
+                    "model",
+                    "extra_headers",
+                    "extra_query",
+                    "extra_body",
+                    "timeout",
+                ]
+                + list(supported_params)
+            )
+        )
 
     def map_openai_params(
         self,
diff --git a/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py b/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py
index 1ed2266d1f..6d46a40f6c 100644
--- a/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py
+++ b/tests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py
@@ -147,7 +147,7 @@ class TestOpenAIResponsesAPIConfig:
 
             assert result.type == ResponsesAPIStreamEvents.RESPONSE_COMPLETED
             assert result.response.id == "resp_123"
-    
+
     @pytest.mark.serial
     def test_validate_environment(self):
         """Test that validate_environment correctly sets the Authorization header"""
@@ -292,27 +292,36 @@ class TestAzureResponsesAPIConfig:
     def test_azure_get_complete_url_with_version_types(self):
         """Test Azure get_complete_url with different API version types"""
         base_url = "https://litellm8397336933.openai.azure.com"
-        
+
         # Test with preview version - should use openai/v1/responses
         result_preview = self.config.get_complete_url(
             api_base=base_url,
             litellm_params={"api_version": "preview"},
         )
-        assert result_preview == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=preview"
-        
-        # Test with latest version - should use openai/v1/responses  
+        assert (
+            result_preview
+            == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=preview"
+        )
+
+        # Test with latest version - should use openai/v1/responses
         result_latest = self.config.get_complete_url(
             api_base=base_url,
             litellm_params={"api_version": "latest"},
         )
-        assert result_latest == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=latest"
-        
+        assert (
+            result_latest
+            == "https://litellm8397336933.openai.azure.com/openai/v1/responses?api-version=latest"
+        )
+
         # Test with date-based version - should use openai/responses
         result_date = self.config.get_complete_url(
             api_base=base_url,
             litellm_params={"api_version": "2025-01-01"},
         )
-        assert result_date == "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2025-01-01"
+        assert (
+            result_date
+            == "https://litellm8397336933.openai.azure.com/openai/responses?api-version=2025-01-01"
+        )
 
 
 class TestTransformListInputItemsRequest:
@@ -650,3 +659,12 @@ class TestTransformListInputItemsRequest:
         for key, value in params.items():
             assert isinstance(key, str)
             assert value is not None
+
+
+def test_get_supported_openai_params():
+    config = OpenAIResponsesAPIConfig()
+    params = config.get_supported_openai_params("gpt-4o")
+    assert "temperature" in params
+    assert "stream" in params
+    assert "background" in params
+    assert "stream" in params

From 000ecad4e2c9b1410eecb7af27e8ae5c25610ae2 Mon Sep 17 00:00:00 2001
From: Cole McIntosh 
Date: Sat, 16 Aug 2025 08:32:22 -0500
Subject: [PATCH 023/151] Fix Groq streaming ASCII encoding issue
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Replace iter_lines()/aiter_lines() with iter_text()/aiter_text() using explicit
UTF-8 encoding to handle non-ASCII characters like µ in streaming responses.

- Added utf8_iter_lines() and utf8_aiter_lines() helper functions
- Ensures proper UTF-8 decoding of streaming response content
- Added comprehensive tests for Unicode character handling

Fixes #12660
---
 litellm/llms/openai_like/chat/handler.py      |  18 ++-
 scripts/test_groq_streaming_issue.py          |  54 ++++++++
 .../test_groq_streaming_encoding.py           | 129 ++++++++++++++++++
 3 files changed, 199 insertions(+), 2 deletions(-)
 create mode 100644 scripts/test_groq_streaming_issue.py
 create mode 100644 tests/test_litellm/test_groq_streaming_encoding.py

diff --git a/litellm/llms/openai_like/chat/handler.py b/litellm/llms/openai_like/chat/handler.py
index 821fc9b7f1..ae0a3cc355 100644
--- a/litellm/llms/openai_like/chat/handler.py
+++ b/litellm/llms/openai_like/chat/handler.py
@@ -49,8 +49,15 @@ async def make_call(
         model_response = ModelResponse(**response.json())
         completion_stream = MockResponseIterator(model_response=model_response)
     else:
+        # Use aiter_text with explicit UTF-8 encoding to avoid ASCII encoding errors
+        async def utf8_aiter_lines():
+            async for line in response.aiter_text(encoding='utf-8'):
+                for line_part in line.splitlines(keepends=True):
+                    if line_part.strip():
+                        yield line_part.rstrip('\r\n')
+        
         completion_stream = ModelResponseIterator(
-            streaming_response=response.aiter_lines(), sync_stream=False
+            streaming_response=utf8_aiter_lines(), sync_stream=False
         )
     # LOGGING
     logging_obj.post_call(
@@ -93,8 +100,15 @@ def make_sync_call(
         model_response = ModelResponse(**response.json())
         completion_stream = MockResponseIterator(model_response=model_response)
     else:
+        # Use iter_text with explicit UTF-8 encoding to avoid ASCII encoding errors
+        def utf8_iter_lines():
+            for line in response.iter_text(encoding='utf-8'):
+                for line_part in line.splitlines(keepends=True):
+                    if line_part.strip():
+                        yield line_part.rstrip('\r\n')
+        
         completion_stream = ModelResponseIterator(
-            streaming_response=response.iter_lines(), sync_stream=True
+            streaming_response=utf8_iter_lines(), sync_stream=True
         )
 
     # LOGGING
diff --git a/scripts/test_groq_streaming_issue.py b/scripts/test_groq_streaming_issue.py
new file mode 100644
index 0000000000..0a996c0c20
--- /dev/null
+++ b/scripts/test_groq_streaming_issue.py
@@ -0,0 +1,54 @@
+"""
+Test script to reproduce the Groq streaming ASCII encoding issue.
+
+This reproduces the issue described in #12660 where streaming responses
+containing non-ASCII characters like µ cause encoding errors.
+"""
+import asyncio
+import os
+import traceback
+from litellm import acompletion
+
+async def test_groq_streaming_with_special_chars():
+    """Test that reproduces the ASCII encoding issue with Groq streaming."""
+    try:
+        print("Testing acompletion + streaming with Groq...")
+        
+        # Test message that should trigger the µ character or similar non-ASCII content
+        test_messages = [
+            {"content": "What is the symbol for micro? Please include the µ symbol in your response.", "role": "user"}
+        ]
+        
+        # This should trigger the ASCII encoding error described in the issue
+        response = await acompletion(
+            model="groq/llama-3.3-70b-versatile",
+            messages=test_messages, 
+            stream=True
+        )
+        
+        print(f"Response type: {type(response)}")
+        
+        # Try to iterate through the stream
+        async for chunk in response:
+            print(f"Chunk: {chunk}")
+            
+        print("✅ Test completed successfully - no encoding errors!")
+        
+    except Exception as e:
+        print(f"❌ Error occurred: {e}")
+        print(f"Error type: {type(e)}")
+        print(f"Traceback:\n{traceback.format_exc()}")
+        return False
+        
+    return True
+
+if __name__ == "__main__":
+    # Note: This requires GROQ_API_KEY to be set
+    if not os.getenv("GROQ_API_KEY"):
+        print("⚠️  GROQ_API_KEY not set. Skipping test.")
+    else:
+        success = asyncio.run(test_groq_streaming_with_special_chars())
+        if success:
+            print("🎉 All tests passed!")
+        else:
+            print("💥 Test failed!")
\ No newline at end of file
diff --git a/tests/test_litellm/test_groq_streaming_encoding.py b/tests/test_litellm/test_groq_streaming_encoding.py
new file mode 100644
index 0000000000..cb1d69a4a1
--- /dev/null
+++ b/tests/test_litellm/test_groq_streaming_encoding.py
@@ -0,0 +1,129 @@
+"""
+Test for Groq streaming ASCII encoding issue fix.
+
+This test verifies that the OpenAI-like handler correctly handles
+UTF-8 encoded content in streaming responses, specifically fixing
+the ASCII encoding error described in issue #12660.
+"""
+import pytest
+import asyncio
+from unittest.mock import Mock, AsyncMock
+from litellm.llms.openai_like.chat.handler import make_call, make_sync_call
+
+class MockResponse:
+    """Mock httpx response for testing UTF-8 handling."""
+    
+    def __init__(self, test_content: str):
+        self.test_content = test_content
+        self.status_code = 200
+        
+    def iter_text(self, encoding='utf-8'):
+        """Mock iter_text that yields content with the specified encoding."""
+        yield self.test_content
+        
+    async def aiter_text(self, encoding='utf-8'):
+        """Mock aiter_text that yields content with the specified encoding."""
+        yield self.test_content
+        
+    def json(self):
+        return {"choices": [{"delta": {"content": "test"}}]}
+
+class MockSyncClient:
+    """Mock synchronous HTTP client for testing."""
+    
+    def __init__(self, response_content: str):
+        self.response_content = response_content
+        
+    def post(self, *args, **kwargs):
+        return MockResponse(self.response_content)
+
+class MockAsyncClient:
+    """Mock asynchronous HTTP client for testing."""
+    
+    def __init__(self, response_content: str):
+        self.response_content = response_content
+        
+    async def post(self, *args, **kwargs):
+        return MockResponse(self.response_content)
+
+def test_utf8_streaming_sync():
+    """Test that synchronous streaming handles UTF-8 characters correctly."""
+    # Content with the µ character that was causing issues
+    test_content = "data: {\"choices\":[{\"delta\":{\"content\":\"The symbol µ represents micro\"}}]}\n\n"
+    
+    mock_client = MockSyncClient(test_content)
+    mock_logging = Mock()
+    
+    # This should not raise an ASCII encoding error
+    completion_stream = make_sync_call(
+        client=mock_client,
+        api_base="https://test.com/v1/chat/completions",
+        headers={"Authorization": "Bearer test"},
+        data='{"model": "test", "messages": []}',
+        model="test-model",
+        messages=[],
+        logging_obj=mock_logging
+    )
+    
+    # Verify we can iterate through the stream without encoding errors
+    assert completion_stream is not None
+
+@pytest.mark.asyncio
+async def test_utf8_streaming_async():
+    """Test that asynchronous streaming handles UTF-8 characters correctly."""
+    # Content with the µ character that was causing issues
+    test_content = "data: {\"choices\":[{\"delta\":{\"content\":\"The symbol µ represents micro\"}}]}\n\n"
+    
+    mock_client = MockAsyncClient(test_content)
+    mock_logging = Mock()
+    
+    # This should not raise an ASCII encoding error
+    completion_stream = await make_call(
+        client=mock_client,
+        api_base="https://test.com/v1/chat/completions",
+        headers={"Authorization": "Bearer test"},
+        data='{"model": "test", "messages": []}',
+        model="test-model",
+        messages=[],
+        logging_obj=mock_logging
+    )
+    
+    # Verify we can iterate through the stream without encoding errors
+    assert completion_stream is not None
+
+def test_various_unicode_characters():
+    """Test streaming with various Unicode characters that could cause issues."""
+    unicode_test_cases = [
+        "µ",  # Micro symbol (the original issue)
+        "©",  # Copyright symbol
+        "™",  # Trademark symbol
+        "€",  # Euro symbol
+        "北京", # Chinese characters
+        "🚀", # Emoji
+        "Ñoño", # Spanish characters with tildes
+    ]
+    
+    for unicode_char in unicode_test_cases:
+        test_content = f"data: {{\"choices\":[{{\"delta\":{{\"content\":\"Testing {unicode_char} character\"}}}}]}}\n\n"
+        
+        mock_client = MockSyncClient(test_content)
+        mock_logging = Mock()
+        
+        # This should not raise an ASCII encoding error for any Unicode character
+        completion_stream = make_sync_call(
+            client=mock_client,
+            api_base="https://test.com/v1/chat/completions",
+            headers={"Authorization": "Bearer test"},
+            data='{"model": "test", "messages": []}',
+            model="test-model",
+            messages=[],
+            logging_obj=mock_logging
+        )
+        
+        assert completion_stream is not None, f"Failed to handle Unicode character: {unicode_char}"
+
+if __name__ == "__main__":
+    test_utf8_streaming_sync()
+    asyncio.run(test_utf8_streaming_async())
+    test_various_unicode_characters()
+    print("All UTF-8 streaming tests passed!")
\ No newline at end of file

From cac27be56a1e52ea24b55623bf921a67075955ff Mon Sep 17 00:00:00 2001
From: Ishaan Jaff 
Date: Sat, 16 Aug 2025 07:58:17 -0700
Subject: [PATCH 024/151] =?UTF-8?q?bump:=20version=201.75.7=20=E2=86=92=20?=
 =?UTF-8?q?1.75.8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 pyproject.toml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/pyproject.toml b/pyproject.toml
index 2dd6d902bc..ac6563f9a1 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -1,6 +1,6 @@
 [tool.poetry]
 name = "litellm"
-version = "1.75.7"
+version = "1.75.8"
 description = "Library to easily interface with LLM API providers"
 authors = ["BerriAI"]
 license = "MIT"
@@ -155,7 +155,7 @@ requires = ["poetry-core", "wheel"]
 build-backend = "poetry.core.masonry.api"
 
 [tool.commitizen]
-version = "1.75.7"
+version = "1.75.8"
 version_files = [
     "pyproject.toml:^version"
 ]

From 76939c5e73ceeb88bbd4585f4bfdd3c11fbe13ad Mon Sep 17 00:00:00 2001
From: Ishaan Jaff 
Date: Sat, 16 Aug 2025 07:59:18 -0700
Subject: [PATCH 025/151] ui new build

---
 .../_buildManifest.js                            |  0
 .../_ssgManifest.js                              |  0
 .../_next/static/chunks/154-686bf7931b450e3d.js  |  1 +
 .../_next/static/chunks/154-7bf3bbb913e68f71.js  |  1 -
 .../_next/static/chunks/172-25e8f67ccf021150.js  |  1 -
 .../_next/static/chunks/172-c602ad2ba592907b.js  |  1 +
 .../_next/static/chunks/50-d0da2dd7acce2eb9.js   |  1 +
 .../_next/static/chunks/682-52e4da3cfda27e50.js  | 16 ++++++++--------
 .../_next/static/chunks/85-52b9060394399707.js   |  1 -
 ...1803a09e9ae8da.js => 866-3523e0e07cf314f6.js} |  2 +-
 .../static/chunks/app/layout-25a743106e1c9456.js |  1 +
 .../static/chunks/app/layout-f4acf18888f0aa20.js |  1 -
 ...8a8dbd0d3984f.js => page-6daa1df7fb2c7a9d.js} |  2 +-
 ...235fc18df224f.js => page-aef41992dbd4614b.js} |  2 +-
 .../app/onboarding/page-3c5840c907b0a5c8.js      |  1 +
 .../app/onboarding/page-6b5d568180da3ccd.js      |  1 -
 .../static/chunks/app/page-2647f6b4be081b4f.js   |  1 +
 .../static/chunks/app/page-c64580821d04b2c5.js   |  1 -
 ...e681a6d94.js => main-app-475d6efe4080647d.js} |  2 +-
 .../out/_next/static/css/618290a32b9bb91a.css    |  3 +++
 .../out/_next/static/css/c8d591a6ccd18f71.css    |  3 ---
 litellm/proxy/_experimental/out/index.html       |  2 +-
 litellm/proxy/_experimental/out/index.txt        |  4 ++--
 litellm/proxy/_experimental/out/model_hub.txt    |  4 ++--
 .../index.html => model_hub_table.html}          |  2 +-
 .../proxy/_experimental/out/model_hub_table.txt  |  4 ++--
 litellm/proxy/_experimental/out/onboarding.html  |  1 +
 litellm/proxy/_experimental/out/onboarding.txt   |  4 ++--
 ui/litellm-dashboard/out/404.html                |  2 +-
 .../_buildManifest.js                            |  0
 .../_ssgManifest.js                              |  0
 .../_next/static/chunks/154-686bf7931b450e3d.js  |  1 +
 .../_next/static/chunks/154-7bf3bbb913e68f71.js  |  1 -
 .../_next/static/chunks/172-25e8f67ccf021150.js  |  1 -
 .../_next/static/chunks/172-c602ad2ba592907b.js  |  1 +
 .../_next/static/chunks/50-d0da2dd7acce2eb9.js   |  1 +
 .../_next/static/chunks/682-52e4da3cfda27e50.js  | 16 ++++++++--------
 .../_next/static/chunks/85-52b9060394399707.js   |  1 -
 ...1803a09e9ae8da.js => 866-3523e0e07cf314f6.js} |  2 +-
 .../static/chunks/app/layout-25a743106e1c9456.js |  1 +
 .../static/chunks/app/layout-f4acf18888f0aa20.js |  1 -
 ...8a8dbd0d3984f.js => page-6daa1df7fb2c7a9d.js} |  2 +-
 ...235fc18df224f.js => page-aef41992dbd4614b.js} |  2 +-
 .../app/onboarding/page-3c5840c907b0a5c8.js      |  1 +
 .../app/onboarding/page-6b5d568180da3ccd.js      |  1 -
 .../static/chunks/app/page-2647f6b4be081b4f.js   |  1 +
 .../static/chunks/app/page-c64580821d04b2c5.js   |  1 -
 ...e681a6d94.js => main-app-475d6efe4080647d.js} |  2 +-
 .../out/_next/static/css/618290a32b9bb91a.css    |  3 +++
 .../out/_next/static/css/c8d591a6ccd18f71.css    |  3 ---
 ui/litellm-dashboard/out/index.html              |  2 +-
 ui/litellm-dashboard/out/index.txt               |  4 ++--
 ui/litellm-dashboard/out/model_hub.html          |  2 +-
 ui/litellm-dashboard/out/model_hub.txt           |  4 ++--
 ui/litellm-dashboard/out/model_hub_table.html    |  2 +-
 ui/litellm-dashboard/out/model_hub_table.txt     |  4 ++--
 ui/litellm-dashboard/out/onboarding.html         |  2 +-
 ui/litellm-dashboard/out/onboarding.txt          |  4 ++--
 58 files changed, 66 insertions(+), 65 deletions(-)
 rename litellm/proxy/_experimental/out/_next/static/{ILJ2l6ZzNB2f7RRsIZVJI => 4H8_DZPfnSH0102u_DzG-}/_buildManifest.js (100%)
 rename litellm/proxy/_experimental/out/_next/static/{ILJ2l6ZzNB2f7RRsIZVJI => 4H8_DZPfnSH0102u_DzG-}/_ssgManifest.js (100%)
 create mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/154-686bf7931b450e3d.js
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/154-7bf3bbb913e68f71.js
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/172-25e8f67ccf021150.js
 create mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/172-c602ad2ba592907b.js
 create mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/50-d0da2dd7acce2eb9.js
 rename ui/litellm-dashboard/out/_next/static/chunks/247-7557228b7131016b.js => litellm/proxy/_experimental/out/_next/static/chunks/682-52e4da3cfda27e50.js (50%)
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/85-52b9060394399707.js
 rename litellm/proxy/_experimental/out/_next/static/chunks/{866-9e1803a09e9ae8da.js => 866-3523e0e07cf314f6.js} (99%)
 create mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/app/layout-25a743106e1c9456.js
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/app/layout-f4acf18888f0aa20.js
 rename litellm/proxy/_experimental/out/_next/static/chunks/app/model_hub/{page-72c8a8dbd0d3984f.js => page-6daa1df7fb2c7a9d.js} (50%)
 rename litellm/proxy/_experimental/out/_next/static/chunks/app/model_hub_table/{page-10c235fc18df224f.js => page-aef41992dbd4614b.js} (57%)
 create mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/app/onboarding/page-3c5840c907b0a5c8.js
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/app/onboarding/page-6b5d568180da3ccd.js
 create mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/app/page-2647f6b4be081b4f.js
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/chunks/app/page-c64580821d04b2c5.js
 rename litellm/proxy/_experimental/out/_next/static/chunks/{main-app-4f7318ae681a6d94.js => main-app-475d6efe4080647d.js} (54%)
 create mode 100644 litellm/proxy/_experimental/out/_next/static/css/618290a32b9bb91a.css
 delete mode 100644 litellm/proxy/_experimental/out/_next/static/css/c8d591a6ccd18f71.css
 rename litellm/proxy/_experimental/out/{model_hub_table/index.html => model_hub_table.html} (88%)
 create mode 100644 litellm/proxy/_experimental/out/onboarding.html
 rename ui/litellm-dashboard/out/_next/static/{ILJ2l6ZzNB2f7RRsIZVJI => 4H8_DZPfnSH0102u_DzG-}/_buildManifest.js (100%)
 rename ui/litellm-dashboard/out/_next/static/{ILJ2l6ZzNB2f7RRsIZVJI => 4H8_DZPfnSH0102u_DzG-}/_ssgManifest.js (100%)
 create mode 100644 ui/litellm-dashboard/out/_next/static/chunks/154-686bf7931b450e3d.js
 delete mode 100644 ui/litellm-dashboard/out/_next/static/chunks/154-7bf3bbb913e68f71.js
 delete mode 100644 ui/litellm-dashboard/out/_next/static/chunks/172-25e8f67ccf021150.js
 create mode 100644 ui/litellm-dashboard/out/_next/static/chunks/172-c602ad2ba592907b.js
 create mode 100644 ui/litellm-dashboard/out/_next/static/chunks/50-d0da2dd7acce2eb9.js
 rename litellm/proxy/_experimental/out/_next/static/chunks/247-7557228b7131016b.js => ui/litellm-dashboard/out/_next/static/chunks/682-52e4da3cfda27e50.js (50%)
 delete mode 100644 ui/litellm-dashboard/out/_next/static/chunks/85-52b9060394399707.js
 rename ui/litellm-dashboard/out/_next/static/chunks/{866-9e1803a09e9ae8da.js => 866-3523e0e07cf314f6.js} (99%)
 create mode 100644 ui/litellm-dashboard/out/_next/static/chunks/app/layout-25a743106e1c9456.js
 delete mode 100644 ui/litellm-dashboard/out/_next/static/chunks/app/layout-f4acf18888f0aa20.js
 rename ui/litellm-dashboard/out/_next/static/chunks/app/model_hub/{page-72c8a8dbd0d3984f.js => page-6daa1df7fb2c7a9d.js} (50%)
 rename ui/litellm-dashboard/out/_next/static/chunks/app/model_hub_table/{page-10c235fc18df224f.js => page-aef41992dbd4614b.js} (57%)
 create mode 100644 ui/litellm-dashboard/out/_next/static/chunks/app/onboarding/page-3c5840c907b0a5c8.js
 delete mode 100644 ui/litellm-dashboard/out/_next/static/chunks/app/onboarding/page-6b5d568180da3ccd.js
 create mode 100644 ui/litellm-dashboard/out/_next/static/chunks/app/page-2647f6b4be081b4f.js
 delete mode 100644 ui/litellm-dashboard/out/_next/static/chunks/app/page-c64580821d04b2c5.js
 rename ui/litellm-dashboard/out/_next/static/chunks/{main-app-4f7318ae681a6d94.js => main-app-475d6efe4080647d.js} (54%)
 create mode 100644 ui/litellm-dashboard/out/_next/static/css/618290a32b9bb91a.css
 delete mode 100644 ui/litellm-dashboard/out/_next/static/css/c8d591a6ccd18f71.css

diff --git a/litellm/proxy/_experimental/out/_next/static/ILJ2l6ZzNB2f7RRsIZVJI/_buildManifest.js b/litellm/proxy/_experimental/out/_next/static/4H8_DZPfnSH0102u_DzG-/_buildManifest.js
similarity index 100%
rename from litellm/proxy/_experimental/out/_next/static/ILJ2l6ZzNB2f7RRsIZVJI/_buildManifest.js
rename to litellm/proxy/_experimental/out/_next/static/4H8_DZPfnSH0102u_DzG-/_buildManifest.js
diff --git a/litellm/proxy/_experimental/out/_next/static/ILJ2l6ZzNB2f7RRsIZVJI/_ssgManifest.js b/litellm/proxy/_experimental/out/_next/static/4H8_DZPfnSH0102u_DzG-/_ssgManifest.js
similarity index 100%
rename from litellm/proxy/_experimental/out/_next/static/ILJ2l6ZzNB2f7RRsIZVJI/_ssgManifest.js
rename to litellm/proxy/_experimental/out/_next/static/4H8_DZPfnSH0102u_DzG-/_ssgManifest.js
diff --git a/litellm/proxy/_experimental/out/_next/static/chunks/154-686bf7931b450e3d.js b/litellm/proxy/_experimental/out/_next/static/chunks/154-686bf7931b450e3d.js
new file mode 100644
index 0000000000..914bf3b300
--- /dev/null
+++ b/litellm/proxy/_experimental/out/_next/static/chunks/154-686bf7931b450e3d.js
@@ -0,0 +1 @@
+"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[154],{31283:function(e,t,o){o.d(t,{o:function(){return a.Z}});var a=o(49566)},63610:function(e,t,o){o.d(t,{d:function(){return p}});var a=o(57437),r=o(2265),n=o(64482),l=o(52787),c=o(20577),i=o(13634),s=o(31283),d=o(15424),u=o(89970),h=o(19250);let p=["metadata","config","enforced_params","aliases"],g=(e,t)=>p.includes(e)||"json"===t.format,m=e=>{if(!e)return!0;try{return JSON.parse(e),!0}catch(e){return!1}},f=(e,t,o)=>{let a={max_budget:"Enter maximum budget in USD (e.g., 100.50)",budget_duration:"Select a time period for budget reset",tpm_limit:"Enter maximum tokens per minute (whole number)",rpm_limit:"Enter maximum requests per minute (whole number)",duration:"Enter duration (e.g., 30s, 24h, 7d)",metadata:'Enter JSON object with key-value pairs\nExample: {"team": "research", "project": "nlp"}',config:'Enter configuration as JSON object\nExample: {"setting": "value"}',permissions:"Enter comma-separated permission strings",enforced_params:'Enter parameters as JSON object\nExample: {"param": "value"}',blocked:"Enter true/false or specific block conditions",aliases:'Enter aliases as JSON object\nExample: {"alias1": "value1", "alias2": "value2"}',models:"Select one or more model names",key_alias:"Enter a unique identifier for this key",tags:"Enter comma-separated tag strings"}[e]||({string:"Text input",number:"Numeric input",integer:"Whole number input",boolean:"True/False value"})[o]||"Text input";return g(e,t)?"".concat(a,"\nMust be valid JSON format"):t.enum?"Select from available options\nAllowed values: ".concat(t.enum.join(", ")):a};t.Z=e=>{let{schemaComponent:t,excludedFields:o=[],form:p,overrideLabels:w={},overrideTooltips:y={},customValidation:j={},defaultValues:_={}}=e,[C,k]=(0,r.useState)(null),[v,T]=(0,r.useState)(null);(0,r.useEffect)(()=>{(async()=>{try{let e=(await (0,h.getOpenAPISchema)()).components.schemas[t];if(!e)throw Error('Schema component "'.concat(t,'" not found'));k(e);let a={};Object.keys(e.properties).filter(e=>!o.includes(e)&&void 0!==_[e]).forEach(e=>{a[e]=_[e]}),p.setFieldsValue(a)}catch(e){console.error("Schema fetch error:",e),T(e instanceof Error?e.message:"Failed to fetch schema")}})()},[t,p,o]);let E=e=>{if(e.type)return e.type;if(e.anyOf){let t=e.anyOf.map(e=>e.type);if(t.includes("number")||t.includes("integer"))return"number";t.includes("string")}return"string"},S=(e,t)=>{var o;let r;let h=E(t),p=null==C?void 0:null===(o=C.required)||void 0===o?void 0:o.includes(e),k=w[e]||t.title||e,v=y[e]||t.description,T=[];p&&T.push({required:!0,message:"".concat(k," is required")}),j[e]&&T.push({validator:j[e]}),g(e,t)&&T.push({validator:async(e,t)=>{if(t&&!m(t))throw Error("Please enter valid JSON")}});let S=v?(0,a.jsxs)("span",{children:[k," ",(0,a.jsx)(u.Z,{title:v,children:(0,a.jsx)(d.Z,{style:{marginLeft:"4px"}})})]}):k;return r=g(e,t)?(0,a.jsx)(n.default.TextArea,{rows:4,placeholder:"Enter as JSON",className:"font-mono"}):t.enum?(0,a.jsx)(l.default,{children:t.enum.map(e=>(0,a.jsx)(l.default.Option,{value:e,children:e},e))}):"number"===h||"integer"===h?(0,a.jsx)(c.Z,{style:{width:"100%"},precision:"integer"===h?0:void 0}):"duration"===e?(0,a.jsx)(s.o,{placeholder:"eg: 30s, 30h, 30d"}):(0,a.jsx)(s.o,{placeholder:v||""}),(0,a.jsx)(i.Z.Item,{label:S,name:e,className:"mt-8",rules:T,initialValue:_[e],help:(0,a.jsx)("div",{className:"text-xs text-gray-500",children:f(e,t,h)}),children:r},e)};return v?(0,a.jsxs)("div",{className:"text-red-500",children:["Error: ",v]}):(null==C?void 0:C.properties)?(0,a.jsx)("div",{children:Object.entries(C.properties).filter(e=>{let[t]=e;return!o.includes(t)}).map(e=>{let[t,o]=e;return S(t,o)})}):null}},9114:function(e,t,o){var a=o(57271),r=o(85968);function n(){return"topRight"}function l(e,t){var o;return"string"==typeof e?{message:t,description:e}:{message:null!==(o=e.message)&&void 0!==o?o:t,...e}}function c(e){return"number"==typeof e?e:"string"==typeof e&&/^\d+$/.test(e)?parseInt(e,10):void 0}let i=["invalid api key","invalid authorization header format","authentication error","invalid proxy server token","invalid jwt token","invalid jwt submitted","unauthorized access to metrics endpoint"],s=["admin-only endpoint","not allowed to access model","user does not have permission","access forbidden","invalid credentials used to access ui","user not allowed to access proxy"],d=["db not connected","database not initialized","no db connected","prisma client not initialized","service unhealthy"],u=["no models configured on proxy","llm router not initialized","no deployments available","no healthy deployment available","not allowed to access model due to tags configuration","invalid model name passed in"],h=["deployment over user-defined ratelimit","crossed tpm / rpm / max parallel request limit","max parallel request limit"],p=["budget exceeded","crossed budget","provider budget"],g=["must be a litellm enterprise user","only be available for liteLLM enterprise users","missing litellm-enterprise package","only available on the docker image","enterprise feature","premium user"],m=["invalid json payload","invalid request type","invalid key format","invalid hash key","invalid sort column","invalid sort order","invalid limit","invalid file type","invalid field","invalid date format"],f=["model not found","model with id","credential not found","user not found","team not found","organization not found","mcp server with id","tool '"],w=["already exists","team member is already in team","user already exists"],y=["violated openai moderation policy","violated jailbreak threshold","violated prompt_injection threshold","violated content safety policy","violated lasso guardrail policy","blocked by pillar security guardrail","violated azure prompt shield guardrail policy","content blocked by model armor","response blocked by model armor","streaming response blocked by model armor","guardrail","moderation"],j=["invalid purpose","service must be specified","invalid response - response.response is none"],_=["cloudzero settings not configured","failed to decrypt cloudzero api key","cloudzero settings not found"],C=["created successfully","updated successfully","deleted successfully","credential created successfully","model added successfully","team created successfully","user created successfully","organization created successfully","cloudzero settings initialized successfully","cloudzero settings updated successfully","cloudzero export completed successfully","mock llm request made","mock slack alert sent","mock email alert sent","spend for all api keys and teams reset successfully","monthlyglobalspend view refreshed","cache cleared successfully","cache set successfully","ip ","deleted successfully"],k=["rate limit reached for deployment","deployment cooldown period active"],v=["this feature is only available for litellm enterprise users","enterprise features are not available","regenerating virtual keys is an enterprise feature","trying to set allowed_routes. this is an enterprise feature"],T=["invalid maximum_spend_logs_retention_interval value","error has invalid or non-convertible code","failed to save health check to database"];t.Z={error(e){var t,o;let r=l(e,"Error");a.ZP.error({...r,placement:null!==(t=r.placement)&&void 0!==t?t:n(),duration:null!==(o=r.duration)&&void 0!==o?o:6})},warning(e){var t,o;let r=l(e,"Warning");a.ZP.warning({...r,placement:null!==(t=r.placement)&&void 0!==t?t:n(),duration:null!==(o=r.duration)&&void 0!==o?o:5})},info(e){var t,o;let r=l(e,"Info");a.ZP.info({...r,placement:null!==(t=r.placement)&&void 0!==t?t:n(),duration:null!==(o=r.duration)&&void 0!==o?o:4})},success(e){var t,o;let r=l(e,"Success");a.ZP.success({...r,placement:null!==(t=r.placement)&&void 0!==t?t:n(),duration:null!==(o=r.duration)&&void 0!==o?o:3.5})},fromBackend(e,t){var o,l,E,S,b,F,P,O,B,N,x,G;let J=null!==(G=null!==(x=c(null==e?void 0:null===(N=e.response)||void 0===N?void 0:N.status))&&void 0!==x?x:c(null==e?void 0:e.status_code))&&void 0!==G?G:c(null==e?void 0:e.code),A=function(e){var t,o,a,n,l,c,i,s,d,u,h,p;if("string"==typeof e)return e;let g=null!==(p=null!==(h=null!==(u=null!==(d=null!==(s=null==e?void 0:null===(a=e.response)||void 0===a?void 0:null===(o=a.data)||void 0===o?void 0:null===(t=o.error)||void 0===t?void 0:t.message)&&void 0!==s?s:null==e?void 0:null===(l=e.response)||void 0===l?void 0:null===(n=l.data)||void 0===n?void 0:n.message)&&void 0!==d?d:null==e?void 0:null===(i=e.response)||void 0===i?void 0:null===(c=i.data)||void 0===c?void 0:c.error)&&void 0!==u?u:null==e?void 0:e.detail)&&void 0!==h?h:null==e?void 0:e.message)&&void 0!==p?p:e;return(0,r.O)(g)}(e),U={...null!=t?t:{},description:A,placement:null!==(o=null==t?void 0:t.placement)&&void 0!==o?o:n()};if(void 0!==J||e instanceof Error||"string"==typeof e||e&&"object"==typeof e&&("error"in e||"detail"in e)){let e=function(e,t){var o,a,r,n,l;let c=(t||"").toLowerCase();return i.some(e=>c.includes(e))?"Authentication Error":s.some(e=>c.includes(e))?"Access Denied":(null==d?void 0:null===(o=d.some)||void 0===o?void 0:o.call(d,e=>c.includes(e)))||503===e?"Service Unavailable":(null==p?void 0:null===(a=p.some)||void 0===a?void 0:a.call(p,e=>c.includes(e)))?"Budget Exceeded":(null==g?void 0:null===(r=g.some)||void 0===r?void 0:r.call(g,e=>c.includes(e)))?"Feature Unavailable":(null==u?void 0:null===(n=u.some)||void 0===n?void 0:n.call(u,e=>c.includes(e)))?"Routing Error":w.some(e=>c.includes(e))?"Already Exists":y.some(e=>c.includes(e))?"Content Blocked":j.some(e=>c.includes(e))?"Validation Error":_.some(e=>c.includes(e))?"Integration Error":m.some(e=>c.includes(e))?"Validation Error":404===e||c.includes("not found")||f.some(e=>c.includes(e))?"Not Found":429===e||c.includes("rate limit")||c.includes("tpm")||c.includes("rpm")||(null==h?void 0:null===(l=h.some)||void 0===l?void 0:l.call(h,e=>c.includes(e)))?"Rate Limit Exceeded":e&&e>=500?"Server Error":401===e?"Authentication Error":403===e?"Access Denied":c.includes("enterprise")||c.includes("premium")?"Info":e&&e>=400?"Request Error":"Error"}(J,A),o={...U,message:e};if("Rate Limit Exceeded"===e||"Info"===e||"Budget Exceeded"===e||"Feature Unavailable"===e||"Content Blocked"===e||"Integration Error"===e){a.ZP.warning({...o,duration:null!==(l=null==t?void 0:t.duration)&&void 0!==l?l:7});return}if("Server Error"===e){a.ZP.error({...o,duration:null!==(E=null==t?void 0:t.duration)&&void 0!==E?E:8});return}if("Request Error"===e||"Authentication Error"===e||"Access Denied"===e||"Not Found"===e||"Error"===e){a.ZP.error({...o,duration:null!==(S=null==t?void 0:t.duration)&&void 0!==S?S:6});return}a.ZP.info({...o,duration:null!==(b=null==t?void 0:t.duration)&&void 0!==b?b:4});return}let R=function(e){let t=(e||"").toLowerCase();return C.some(e=>t.includes(e))?{kind:"success",title:"Success"}:v.some(e=>t.includes(e))?{kind:"warning",title:"Feature Notice"}:T.some(e=>t.includes(e))?{kind:"warning",title:"Configuration Warning"}:k.some(e=>t.includes(e))?{kind:"warning",title:"Rate Limit"}:null}(A),I={...U,message:null!==(F=null==R?void 0:R.title)&&void 0!==F?F:"Info"};if((null==R?void 0:R.kind)==="success"){a.ZP.success({...I,duration:null!==(P=null==t?void 0:t.duration)&&void 0!==P?P:3.5});return}if((null==R?void 0:R.kind)==="warning"){a.ZP.warning({...I,duration:null!==(O=null==t?void 0:t.duration)&&void 0!==O?O:6});return}a.ZP.info({...I,duration:null!==(B=null==t?void 0:t.duration)&&void 0!==B?B:4})},clear(){a.ZP.destroy()}}},19250:function(e,t,o){o.r(t),o.d(t,{DEFAULT_ORGANIZATION:function(){return p},PredictedSpendLogsCall:function(){return tl},addAllowedIP:function(){return em},adminGlobalActivity:function(){return eJ},adminGlobalActivityExceptions:function(){return eR},adminGlobalActivityExceptionsPerDeployment:function(){return eI},adminGlobalActivityPerModel:function(){return eU},adminGlobalCacheActivity:function(){return eA},adminSpendLogsCall:function(){return eB},adminTopEndUsersCall:function(){return ex},adminTopKeysCall:function(){return eN},adminTopModelsCall:function(){return eM},adminspendByProvider:function(){return eG},alertingSettingsCall:function(){return A},allEndUsersCall:function(){return eb},allTagNamesCall:function(){return eS},availableTeamListCall:function(){return W},budgetCreateCall:function(){return N},budgetDeleteCall:function(){return B},budgetUpdateCall:function(){return x},cachingHealthCheckCall:function(){return tv},callMCPTool:function(){return tq},cancelModelCostMapReload:function(){return S},claimOnboardingToken:function(){return el},convertPromptFileToJson:function(){return tx},createGuardrailCall:function(){return tJ},createMCPServer:function(){return tz},createPassThroughEndpoint:function(){return tf},createPromptCall:function(){return tO},credentialCreateCall:function(){return eQ},credentialDeleteCall:function(){return e1},credentialGetCall:function(){return e0},credentialListCall:function(){return eX},credentialUpdateCall:function(){return e2},defaultProxyBaseUrl:function(){return c},deleteAllowedIP:function(){return ef},deleteCallback:function(){return ou},deleteConfigFieldSetting:function(){return ty},deleteGuardrailCall:function(){return oe},deleteMCPServer:function(){return tD},deletePassThroughEndpointsCall:function(){return tj},deletePromptCall:function(){return tN},fetchMCPAccessGroups:function(){return tM},fetchMCPServers:function(){return tI},formatDate:function(){return l},getAllowedIPs:function(){return eg},getBudgetList:function(){return ts},getBudgetSettings:function(){return td},getCallbacksCall:function(){return tu},getConfigFieldSetting:function(){return tg},getDefaultTeamSettings:function(){return t$},getEmailEventSettings:function(){return t7},getGeneralSettingsCall:function(){return th},getGuardrailInfo:function(){return oa},getGuardrailProviderSpecificParams:function(){return oo},getGuardrailUISettings:function(){return ot},getGuardrailsList:function(){return tb},getInternalUserSettings:function(){return tU},getModelCostMapReloadStatus:function(){return b},getOnboardingCredentials:function(){return en},getOpenAPISchema:function(){return k},getPassThroughEndpointInfo:function(){return od},getPassThroughEndpointsCall:function(){return tp},getPossibleUserRoles:function(){return eK},getPromptInfo:function(){return tP},getPromptsList:function(){return tF},getProxyBaseUrl:function(){return u},getProxyUISettings:function(){return tS},getPublicModelHubInfo:function(){return C},getRemainingUsers:function(){return oi},getSSOSettings:function(){return on},getTeamPermissionsCall:function(){return tX},getTotalSpendCall:function(){return er},getUiConfig:function(){return _},healthCheckCall:function(){return tC},healthCheckHistoryCall:function(){return tT},individualModelHealthCheckCall:function(){return tk},invitationClaimCall:function(){return J},invitationCreateCall:function(){return G},keyCreateCall:function(){return R},keyCreateServiceAccountCall:function(){return U},keyDeleteCall:function(){return M},keyInfoCall:function(){return ez},keyInfoV1Call:function(){return eD},keyListCall:function(){return eV},keySpendLogsCall:function(){return ev},keyUpdateCall:function(){return e4},latestHealthChecksCall:function(){return tE},listMCPTools:function(){return tV},makeModelGroupPublic:function(){return j},mcpToolsCall:function(){return oh},modelAvailableCall:function(){return ek},modelCostMap:function(){return v},modelCreateCall:function(){return F},modelDeleteCall:function(){return O},modelExceptionsCall:function(){return e_},modelHubCall:function(){return ep},modelHubPublicModelsCall:function(){return eh},modelInfoCall:function(){return ed},modelInfoV1Call:function(){return eu},modelMetricsCall:function(){return ew},modelMetricsSlowResponsesCall:function(){return ej},modelPatchUpdateCall:function(){return e5},modelSettingsCall:function(){return P},modelUpdateCall:function(){return e6},organizationCreateCall:function(){return $},organizationDeleteCall:function(){return X},organizationInfoCall:function(){return K},organizationListCall:function(){return Y},organizationMemberAddCall:function(){return tt},organizationMemberDeleteCall:function(){return to},organizationMemberUpdateCall:function(){return ta},organizationUpdateCall:function(){return Q},patchPromptCall:function(){return tG},perUserAnalyticsCall:function(){return ok},proxyBaseUrl:function(){return s},regenerateKeyCall:function(){return ec},reloadModelCostMap:function(){return T},resetEmailEventSettings:function(){return t8},scheduleModelCostMapReload:function(){return E},serverRootPath:function(){return i},serviceHealthCheck:function(){return ti},sessionSpendLogsCall:function(){return t1},setCallbacksCall:function(){return t_},setGlobalLitellmHeaderName:function(){return y},slackBudgetAlertsHealthCheck:function(){return tc},spendUsersCall:function(){return eq},streamingModelMetricsCall:function(){return ey},tagCreateCall:function(){return tZ},tagDailyActivityCall:function(){return eo},tagDauCall:function(){return ow},tagDeleteCall:function(){return tK},tagDistinctCall:function(){return o_},tagInfoCall:function(){return tW},tagListCall:function(){return tY},tagMauCall:function(){return oj},tagUpdateCall:function(){return tH},tagWauCall:function(){return oy},tagsSpendLogsCall:function(){return eE},teamBulkMemberAddCall:function(){return e9},teamCreateCall:function(){return e$},teamDailyActivityCall:function(){return ea},teamDeleteCall:function(){return L},teamInfoCall:function(){return q},teamListCall:function(){return H},teamMemberAddCall:function(){return e7},teamMemberDeleteCall:function(){return te},teamMemberUpdateCall:function(){return e8},teamPermissionsUpdateCall:function(){return t0},teamSpendLogsCall:function(){return eT},teamUpdateCall:function(){return e3},testConnectionRequest:function(){return eL},testMCPConnectionRequest:function(){return op},testMCPToolsListRequest:function(){return og},transformRequestCall:function(){return ee},uiAuditLogsCall:function(){return oc},uiSpendLogDetailsCall:function(){return tA},uiSpendLogsCall:function(){return eO},updateConfigFieldSetting:function(){return tw},updateDefaultTeamSettings:function(){return tQ},updateEmailEventSettings:function(){return t9},updateGuardrailCall:function(){return or},updateInternalUserSettings:function(){return tR},updateMCPServer:function(){return tL},updatePassThroughEndpoint:function(){return os},updatePassThroughFieldSetting:function(){return tm},updatePromptCall:function(){return tB},updateSSOSettings:function(){return ol},updateUsefulLinksCall:function(){return eC},userAgentAnalyticsCall:function(){return of},userAgentSummaryCall:function(){return oC},userBulkUpdateUserCall:function(){return tn},userCreateCall:function(){return I},userDailyActivityAggregatedCall:function(){return eW},userDailyActivityCall:function(){return et},userDeleteCall:function(){return z},userFilterUICall:function(){return eF},userGetAllUsersCall:function(){return eY},userGetRequesedtModelsCall:function(){return eH},userInfoCall:function(){return V},userListCall:function(){return D},userRequestModelCall:function(){return eZ},userSpendLogsCall:function(){return eP},userUpdateUserCall:function(){return tr},v2TeamListCall:function(){return Z},vectorStoreCreateCall:function(){return t2},vectorStoreDeleteCall:function(){return t3},vectorStoreInfoCall:function(){return t5},vectorStoreListCall:function(){return t4},vectorStoreSearchCall:function(){return om},vectorStoreUpdateCall:function(){return t6}});var a=o(42264),r=o(63610),n=o(9114);let l=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)},c=null,i="/",s=null;console.log=function(){};let d=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=window.location.origin,a=t||o;console.log("proxyBaseUrl:",s),console.log("serverRootPath:",e),e.length>0&&!a.endsWith(e)&&"/"!=e&&(a+=e,s=a),console.log("Updated proxyBaseUrl:",s)},u=()=>s||window.location.origin,h={GET:"GET",DELETE:"DELETE"},p="default_organization",g=0,m=async e=>{let t=Date.now();t-g>6e4?(e.includes("Authentication Error - Expired Key")&&(a.ZP.info("UI Session Expired. Logging out."),g=t,document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;",window.location.href=window.location.pathname),g=t):console.log("Error suppressed to prevent spam:",e)},f="Authorization",w="x-mcp-auth";function y(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Authorization";console.log("setGlobalLitellmHeaderName: ".concat(e)),f=e}let j=async(e,t)=>{let o=s?"".concat(s,"/model_group/make_public"):"/model_group/make_public";return(await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({model_groups:t})})).json()},_=async()=>{console.log("Getting UI config");let e=await fetch(c?"".concat(c,"/litellm/.well-known/litellm-ui-config"):"/litellm/.well-known/litellm-ui-config"),t=await e.json();return console.log("jsonData in getUiConfig:",t),d(t.server_root_path,t.proxy_base_url),t},C=async()=>{let e=await fetch(c?"".concat(c,"/public/model_hub/info"):"/public/model_hub/info");return await e.json()},k=async()=>{let e=s?"".concat(s,"/openapi.json"):"/openapi.json",t=await fetch(e);return await t.json()},v=async e=>{try{let t=s?"".concat(s,"/get/litellm_model_cost_map"):"/get/litellm_model_cost_map",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("received litellm model cost data: ".concat(a)),a}catch(e){throw console.error("Failed to get model cost map:",e),e}},T=async e=>{try{let t=s?"".concat(s,"/reload/model_cost_map"):"/reload/model_cost_map",o=await fetch(t,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("Model cost map reload response: ".concat(a)),a}catch(e){throw console.error("Failed to reload model cost map:",e),e}},E=async(e,t)=>{try{let o=s?"".concat(s,"/schedule/model_cost_map_reload?hours=").concat(t):"/schedule/model_cost_map_reload?hours=".concat(t),a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}}),r=await a.json();return console.log("Schedule model cost map reload response: ".concat(r)),r}catch(e){throw console.error("Failed to schedule model cost map reload:",e),e}},S=async e=>{try{let t=s?"".concat(s,"/schedule/model_cost_map_reload"):"/schedule/model_cost_map_reload",o=await fetch(t,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("Cancel model cost map reload response: ".concat(a)),a}catch(e){throw console.error("Failed to cancel model cost map reload:",e),e}},b=async e=>{try{let t=s?"".concat(s,"/schedule/model_cost_map_reload/status"):"/schedule/model_cost_map_reload/status";console.log("Fetching status from URL:",t);let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){console.error("Status request failed with status: ".concat(o.status));let e=await o.text();throw console.error("Error response:",e),Error("HTTP ".concat(o.status,": ").concat(e))}let a=await o.json();return console.log("Model cost map reload status:",a),a}catch(e){throw console.error("Failed to get model cost map reload status:",e),e}},F=async(e,t)=>{try{let o=s?"".concat(s,"/model/new"):"/model/new",r=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("API Response:",n),a.ZP.destroy(),a.ZP.success("Model ".concat(t.model_name," created successfully"),2),n}catch(e){throw console.error("Failed to create key:",e),e}},P=async e=>{try{let t=s?"".concat(s,"/model/settings"):"/model/settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){console.error("Failed to get model settings:",e)}},O=async(e,t)=>{console.log("model_id in model delete call: ".concat(t));try{let o=s?"".concat(s,"/model/delete"):"/model/delete",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({id:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},B=async(e,t)=>{if(console.log("budget_id in budget delete call: ".concat(t)),null!=e)try{let o=s?"".concat(s,"/budget/delete"):"/budget/delete",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({id:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},N=async(e,t)=>{try{console.log("Form Values in budgetCreateCall:",t),console.log("Form Values after check:",t);let o=s?"".concat(s,"/budget/new"):"/budget/new",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},x=async(e,t)=>{try{console.log("Form Values in budgetUpdateCall:",t),console.log("Form Values after check:",t);let o=s?"".concat(s,"/budget/update"):"/budget/update",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},G=async(e,t)=>{try{let o=s?"".concat(s,"/invitation/new"):"/invitation/new",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},J=async(e,t)=>{try{console.log("Form Values in invitationCreateCall:",t),console.log("Form Values after check:",t);let o=s?"".concat(s,"/invitation/claim"):"/invitation/claim",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},A=async e=>{try{let t=s?"".concat(s,"/alerting/settings"):"/alerting/settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},U=async(e,t)=>{try{for(let e of(console.log("Form Values in keyCreateServiceAccountCall:",t),t.description&&(t.metadata||(t.metadata={}),t.metadata.description=t.description,delete t.description,t.metadata=JSON.stringify(t.metadata)),r.d))if(t[e]){console.log("formValues.".concat(e,":"),t[e]);try{t[e]=JSON.parse(t[e])}catch(t){throw Error("Failed to parse ".concat(e,": ")+t)}}console.log("Form Values after check:",t);let o=s?"".concat(s,"/key/service-account/generate"):"/key/service-account/generate",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw m(e),console.error("Error response from the server:",e),Error(e)}let n=await a.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},R=async(e,t,o)=>{try{for(let e of(console.log("Form Values in keyCreateCall:",o),o.description&&(o.metadata||(o.metadata={}),o.metadata.description=o.description,delete o.description,o.metadata=JSON.stringify(o.metadata)),r.d))if(o[e]){console.log("formValues.".concat(e,":"),o[e]);try{o[e]=JSON.parse(o[e])}catch(t){throw Error("Failed to parse ".concat(e,": ")+t)}}console.log("Form Values after check:",o);let a=s?"".concat(s,"/key/generate"):"/key/generate",n=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t,...o})});if(!n.ok){let e=await n.text();throw m(e),console.error("Error response from the server:",e),Error(e)}let l=await n.json();return console.log("API Response:",l),l}catch(e){throw console.error("Failed to create key:",e),e}},I=async(e,t,o)=>{try{if(console.log("Form Values in keyCreateCall:",o),o.description&&(o.metadata||(o.metadata={}),o.metadata.description=o.description,delete o.description,o.metadata=JSON.stringify(o.metadata)),o.auto_create_key=!1,o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}console.log("Form Values after check:",o);let a=s?"".concat(s,"/user/new"):"/user/new",r=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t,...o})});if(!r.ok){let e=await r.text();throw m(e),console.error("Error response from the server:",e),Error(e)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},M=async(e,t)=>{try{let o=s?"".concat(s,"/key/delete"):"/key/delete";console.log("in keyDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({keys:[t]})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},z=async(e,t)=>{try{let o=s?"".concat(s,"/user/delete"):"/user/delete";console.log("in userDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_ids:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete user(s):",e),e}},L=async(e,t)=>{try{let o=s?"".concat(s,"/team/delete"):"/team/delete";console.log("in teamDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_ids:[t]})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete key:",e),e}},D=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,n=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,l=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,c=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,i=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,d=arguments.length>9&&void 0!==arguments[9]?arguments[9]:null;try{let u=s?"".concat(s,"/user/list"):"/user/list";console.log("in userListCall");let h=new URLSearchParams;if(t&&t.length>0){let e=t.join(",");h.append("user_ids",e)}o&&h.append("page",o.toString()),a&&h.append("page_size",a.toString()),r&&h.append("user_email",r),n&&h.append("role",n),l&&h.append("team",l),c&&h.append("sso_user_ids",c),i&&h.append("sort_by",i),d&&h.append("sort_order",d);let p=h.toString();p&&(u+="?".concat(p));let g=await fetch(u,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!g.ok){let e=await g.json(),t=ov(e);throw m(t),Error(t)}let w=await g.json();return console.log("/user/list API Response:",w),w}catch(e){throw console.error("Failed to create key:",e),e}},V=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4?arguments[4]:void 0,n=arguments.length>5?arguments[5]:void 0,l=arguments.length>6&&void 0!==arguments[6]&&arguments[6];console.log("userInfoCall: ".concat(t,", ").concat(o,", ").concat(a,", ").concat(r,", ").concat(n,", ").concat(l));try{let c;if(a){c=s?"".concat(s,"/user/list"):"/user/list";let e=new URLSearchParams;null!=r&&e.append("page",r.toString()),null!=n&&e.append("page_size",n.toString()),c+="?".concat(e.toString())}else c=s?"".concat(s,"/user/info"):"/user/info",("Admin"!==o&&"Admin Viewer"!==o||l)&&t&&(c+="?user_id=".concat(t));console.log("Requesting user data from:",c);let i=await fetch(c,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.json(),t=ov(e);throw m(t),Error(t)}let d=await i.json();return console.log("API Response:",d),d}catch(e){throw console.error("Failed to fetch user data:",e),e}},q=async(e,t)=>{try{let o=s?"".concat(s,"/team/info"):"/team/info";t&&(o="".concat(o,"?team_id=").concat(t)),console.log("in teamInfoCall");let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},Z=async function(e,t){let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;arguments.length>5&&void 0!==arguments[5]&&arguments[5],arguments.length>6&&void 0!==arguments[6]&&arguments[6],arguments.length>7&&void 0!==arguments[7]&&arguments[7],arguments.length>8&&void 0!==arguments[8]&&arguments[8];try{let n=s?"".concat(s,"/v2/team/list"):"/v2/team/list";console.log("in teamInfoCall");let l=new URLSearchParams;o&&l.append("user_id",o.toString()),t&&l.append("organization_id",t.toString()),a&&l.append("team_id",a.toString()),r&&l.append("team_alias",r.toString());let c=l.toString();c&&(n+="?".concat(c));let i=await fetch(n,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.json(),t=ov(e);throw m(t),Error(t)}let d=await i.json();return console.log("/v2/team/list API Response:",d),d}catch(e){throw console.error("Failed to create key:",e),e}},H=async function(e,t){let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let n=s?"".concat(s,"/team/list"):"/team/list";console.log("in teamInfoCall");let l=new URLSearchParams;o&&l.append("user_id",o.toString()),t&&l.append("organization_id",t.toString()),a&&l.append("team_id",a.toString()),r&&l.append("team_alias",r.toString());let c=l.toString();c&&(n+="?".concat(c));let i=await fetch(n,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.json(),t=ov(e);throw m(t),Error(t)}let d=await i.json();return console.log("/team/list API Response:",d),d}catch(e){throw console.error("Failed to create key:",e),e}},W=async e=>{try{let t=s?"".concat(s,"/team/available"):"/team/available";console.log("in availableTeamListCall");let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("/team/available_teams API Response:",a),a}catch(e){throw e}},Y=async e=>{try{let t=s?"".concat(s,"/organization/list"):"/organization/list",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},K=async(e,t)=>{try{let o=s?"".concat(s,"/organization/info"):"/organization/info";t&&(o="".concat(o,"?organization_id=").concat(t)),console.log("in teamInfoCall");let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},$=async(e,t)=>{try{if(console.log("Form Values in organizationCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw console.error("Failed to parse metadata:",e),Error("Failed to parse metadata: "+e)}}let o=s?"".concat(s,"/organization/new"):"/organization/new",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},Q=async(e,t)=>{try{console.log("Form Values in organizationUpdateCall:",t);let o=s?"".concat(s,"/organization/update"):"/organization/update",a=await fetch(o,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("Update Team Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},X=async(e,t)=>{try{let o=s?"".concat(s,"/organization/delete"):"/organization/delete",a=await fetch(o,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_ids:[t]})});if(!a.ok){let e=await a.text();throw m(e),Error("Error deleting organization: ".concat(e))}return await a.json()}catch(e){throw console.error("Failed to delete organization:",e),e}},ee=async(e,t)=>{try{let o=s?"".concat(s,"/utils/transform_request"):"/utils/transform_request",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},et=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1;try{let r=s?"".concat(s,"/user/daily/activity"):"/user/daily/activity",n=new URLSearchParams;n.append("start_date",l(t)),n.append("end_date",l(o)),n.append("page_size","1000"),n.append("page",a.toString());let c=n.toString();c&&(r+="?".concat(c));let i=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.json(),t=ov(e);throw m(t),Error(t)}return await i.json()}catch(e){throw console.error("Failed to create key:",e),e}},eo=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let n=s?"".concat(s,"/tag/daily/activity"):"/tag/daily/activity",c=new URLSearchParams;c.append("start_date",l(t)),c.append("end_date",l(o)),c.append("page_size","1000"),c.append("page",a.toString()),r&&c.append("tags",r.join(","));let i=c.toString();i&&(n+="?".concat(i));let d=await fetch(n,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!d.ok){let e=await d.json(),t=ov(e);throw m(t),Error(t)}return await d.json()}catch(e){throw console.error("Failed to create key:",e),e}},ea=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let n=s?"".concat(s,"/team/daily/activity"):"/team/daily/activity",c=new URLSearchParams;c.append("start_date",l(t)),c.append("end_date",l(o)),c.append("page_size","1000"),c.append("page",a.toString()),r&&c.append("team_ids",r.join(",")),c.append("exclude_team_ids","litellm-dashboard");let i=c.toString();i&&(n+="?".concat(i));let d=await fetch(n,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!d.ok){let e=await d.json(),t=ov(e);throw m(t),Error(t)}return await d.json()}catch(e){throw console.error("Failed to create key:",e),e}},er=async e=>{try{let t=s?"".concat(s,"/global/spend"):"/global/spend",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},en=async e=>{try{let t=s?"".concat(s,"/onboarding/get_token"):"/onboarding/get_token";t+="?invite_link=".concat(e);let o=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},el=async(e,t,o,a)=>{let r=s?"".concat(s,"/onboarding/claim_token"):"/onboarding/claim_token";try{let n=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({invitation_link:t,user_id:o,password:a})});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log(l),l}catch(e){throw console.error("Failed to delete key:",e),e}},ec=async(e,t,o)=>{try{let a=s?"".concat(s,"/key/").concat(t,"/regenerate"):"/key/".concat(t,"/regenerate"),r=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("Regenerate key Response:",n),n}catch(e){throw console.error("Failed to regenerate key:",e),e}},ei=!1,es=null,ed=async(e,t,o)=>{try{console.log("modelInfoCall:",e,t,o);let r=s?"".concat(s,"/v2/model/info"):"/v2/model/info",n=new URLSearchParams;n.append("include_team_models","true"),n.toString()&&(r+="?".concat(n.toString()));let l=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!l.ok){let e=await l.text();throw e+="error shown=".concat(ei),ei||(e.includes("No model list passed")&&(e="No Models Exist. Click Add Model to get started."),a.ZP.info(e,10),ei=!0,es&&clearTimeout(es),es=setTimeout(()=>{ei=!1},1e4)),Error("Network response was not ok")}let c=await l.json();return console.log("modelInfoCall:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},eu=async(e,t)=>{try{let o=s?"".concat(s,"/v1/model/info"):"/v1/model/info";o+="?litellm_model_id=".concat(t);let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("modelInfoV1Call:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eh=async()=>{let e=s?"".concat(s,"/public/model_hub"):"/public/model_hub";return(await fetch(e,{method:"GET",headers:{"Content-Type":"application/json"}})).json()},ep=async e=>{try{let t=s?"".concat(s,"/model_group/info"):"/model_group/info",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("modelHubCall:",a),a}catch(e){throw console.error("Failed to create key:",e),e}},eg=async e=>{try{let t=s?"".concat(s,"/get/allowed_ips"):"/get/allowed_ips",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("getAllowedIPs:",a),a.data}catch(e){throw console.error("Failed to get allowed IPs:",e),e}},em=async(e,t)=>{try{let o=s?"".concat(s,"/add/allowed_ip"):"/add/allowed_ip",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({ip:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("addAllowedIP:",r),r}catch(e){throw console.error("Failed to add allowed IP:",e),e}},ef=async(e,t)=>{try{let o=s?"".concat(s,"/delete/allowed_ip"):"/delete/allowed_ip",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({ip:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("deleteAllowedIP:",r),r}catch(e){throw console.error("Failed to delete allowed IP:",e),e}},ew=async(e,t,o,a,r,n,l,c)=>{try{let t=s?"".concat(s,"/model/metrics"):"/model/metrics";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(n,"&api_key=").concat(l,"&customer=").concat(c));let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},ey=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/model/streaming_metrics"):"/model/streaming_metrics";t&&(r="".concat(r,"?_selected_model_group=").concat(t,"&startTime=").concat(o,"&endTime=").concat(a));let n=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}return await n.json()}catch(e){throw console.error("Failed to create key:",e),e}},ej=async(e,t,o,a,r,n,l,c)=>{try{let t=s?"".concat(s,"/model/metrics/slow_responses"):"/model/metrics/slow_responses";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(n,"&api_key=").concat(l,"&customer=").concat(c));let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},e_=async(e,t,o,a,r,n,l,c)=>{try{let t=s?"".concat(s,"/model/metrics/exceptions"):"/model/metrics/exceptions";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(n,"&api_key=").concat(l,"&customer=").concat(c));let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},eC=async(e,t)=>{try{let o=s?"".concat(s,"/model_hub/update_useful_links"):"/model_hub/update_useful_links",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({useful_links:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},ek=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,n=(arguments.length>5&&void 0!==arguments[5]&&arguments[5],arguments.length>6&&void 0!==arguments[6]&&arguments[6]);console.log("in /models calls, globalLitellmHeaderName",f);try{let t=s?"".concat(s,"/models"):"/models",o=new URLSearchParams;o.append("include_model_access_groups","True"),!0===a&&o.append("return_wildcard_routes","True"),!0===n&&o.append("only_model_access_groups","True"),r&&o.append("team_id",r.toString()),o.toString()&&(t+="?".concat(o.toString()));let l=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}return await l.json()}catch(e){throw console.error("Failed to create key:",e),e}},ev=async(e,t)=>{try{let o=s?"".concat(s,"/global/spend/logs"):"/global/spend/logs";console.log("in keySpendLogsCall:",o);let a=await fetch("".concat(o,"?api_key=").concat(t),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},eT=async e=>{try{let t=s?"".concat(s,"/global/spend/teams"):"/global/spend/teams";console.log("in teamSpendLogsCall:",t);let o=await fetch("".concat(t),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eE=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/global/spend/tags"):"/global/spend/tags";t&&o&&(r="".concat(r,"?start_date=").concat(t,"&end_date=").concat(o)),a&&(r+="".concat(r,"&tags=").concat(a.join(","))),console.log("in tagsSpendLogsCall:",r);let n=await fetch("".concat(r),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log(l),l}catch(e){throw console.error("Failed to create key:",e),e}},eS=async e=>{try{let t=s?"".concat(s,"/global/spend/all_tag_names"):"/global/spend/all_tag_names";console.log("in global/spend/all_tag_names call",t);let o=await fetch("".concat(t),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eb=async e=>{try{let t=s?"".concat(s,"/global/all_end_users"):"/global/all_end_users";console.log("in global/all_end_users call",t);let o=await fetch("".concat(t),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eF=async(e,t)=>{try{let o=s?"".concat(s,"/user/filter/ui"):"/user/filter/ui";t.get("user_email")&&(o+="?user_email=".concat(t.get("user_email"))),t.get("user_id")&&(o+="?user_id=".concat(t.get("user_id")));let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},eP=async(e,t,o,a,r,n)=>{try{console.log("user role in spend logs call: ".concat(o));let t=s?"".concat(s,"/spend/logs"):"/spend/logs";t="App Owner"==o?"".concat(t,"?user_id=").concat(a,"&start_date=").concat(r,"&end_date=").concat(n):"".concat(t,"?start_date=").concat(r,"&end_date=").concat(n);let l=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}let c=await l.json();return console.log(c),c}catch(e){throw console.error("Failed to create key:",e),e}},eO=async(e,t,o,a,r,n,l,c,i,d,u,h)=>{try{let p=s?"".concat(s,"/spend/logs/ui"):"/spend/logs/ui",g=new URLSearchParams;t&&g.append("api_key",t),o&&g.append("team_id",o),a&&g.append("request_id",a),r&&g.append("start_date",r),n&&g.append("end_date",n),l&&g.append("page",l.toString()),c&&g.append("page_size",c.toString()),i&&g.append("user_id",i),d&&g.append("end_user",d),u&&g.append("status_filter",u),h&&g.append("model",h);let w=g.toString();w&&(p+="?".concat(w));let y=await fetch(p,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!y.ok){let e=await y.json(),t=ov(e);throw m(t),Error(t)}let j=await y.json();return console.log("Spend Logs Response:",j),j}catch(e){throw console.error("Failed to fetch spend logs:",e),e}},eB=async e=>{try{let t=s?"".concat(s,"/global/spend/logs"):"/global/spend/logs",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eN=async e=>{try{let t=s?"".concat(s,"/global/spend/keys?limit=5"):"/global/spend/keys?limit=5",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ex=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/global/spend/end_users"):"/global/spend/end_users",n="";n=t?JSON.stringify({api_key:t,startTime:o,endTime:a}):JSON.stringify({startTime:o,endTime:a});let l={method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:n},c=await fetch(r,l);if(!c.ok){let e=await c.json(),t=ov(e);throw m(t),Error(t)}let i=await c.json();return console.log(i),i}catch(e){throw console.error("Failed to create key:",e),e}},eG=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/global/spend/provider"):"/global/spend/provider";o&&a&&(r+="?start_date=".concat(o,"&end_date=").concat(a)),t&&(r+="&api_key=".concat(t));let n={method:"GET",headers:{[f]:"Bearer ".concat(e)}},l=await fetch(r,n);if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}let c=await l.json();return console.log(c),c}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eJ=async(e,t,o)=>{try{let a=s?"".concat(s,"/global/activity"):"/global/activity";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[f]:"Bearer ".concat(e)}},n=await fetch(a,r);if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log(l),l}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eA=async(e,t,o)=>{try{let a=s?"".concat(s,"/global/activity/cache_hits"):"/global/activity/cache_hits";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[f]:"Bearer ".concat(e)}},n=await fetch(a,r);if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log(l),l}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eU=async(e,t,o)=>{try{let a=s?"".concat(s,"/global/activity/model"):"/global/activity/model";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[f]:"Bearer ".concat(e)}},n=await fetch(a,r);if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log(l),l}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eR=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/global/activity/exceptions"):"/global/activity/exceptions";t&&o&&(r+="?start_date=".concat(t,"&end_date=").concat(o)),a&&(r+="&model_group=".concat(a));let n={method:"GET",headers:{[f]:"Bearer ".concat(e)}},l=await fetch(r,n);if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}let c=await l.json();return console.log(c),c}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eI=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/global/activity/exceptions/deployment"):"/global/activity/exceptions/deployment";t&&o&&(r+="?start_date=".concat(t,"&end_date=").concat(o)),a&&(r+="&model_group=".concat(a));let n={method:"GET",headers:{[f]:"Bearer ".concat(e)}},l=await fetch(r,n);if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}let c=await l.json();return console.log(c),c}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eM=async e=>{try{let t=s?"".concat(s,"/global/spend/models?limit=5"):"/global/spend/models?limit=5",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ez=async(e,t)=>{try{let o=s?"".concat(s,"/v2/key/info"):"/v2/key/info",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({keys:t})});if(!a.ok){let e=await a.text();if(e.includes("Invalid proxy server token passed"))throw Error("Invalid proxy server token passed");throw m(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},eL=async(e,t,o)=>{try{console.log("Sending model connection test request:",JSON.stringify(t));let r=s?"".concat(s,"/health/test_connection"):"/health/test_connection",n=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json",[f]:"Bearer ".concat(e)},body:JSON.stringify({litellm_params:t,mode:o})}),l=n.headers.get("content-type");if(!l||!l.includes("application/json")){let e=await n.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(n.status,": ").concat(n.statusText,"). Check network tab for details."))}let c=await n.json();if(!n.ok||"error"===c.status){if("error"===c.status);else{var a;return{status:"error",message:(null===(a=c.error)||void 0===a?void 0:a.message)||"Connection test failed: ".concat(n.status," ").concat(n.statusText)}}}return c}catch(e){throw console.error("Model connection test error:",e),e}},eD=async(e,t)=>{try{console.log("entering keyInfoV1Call");let o=s?"".concat(s,"/key/info"):"/key/info";o="".concat(o,"?key=").concat(t);let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(console.log("response",a),!a.ok){let e=await a.text();m(e),n.Z.fromBackend("Failed to fetch key info - "+e)}let r=await a.json();return console.log("data",r),r}catch(e){throw console.error("Failed to fetch key info:",e),e}},eV=async function(e,t,o,a,r,n,l,c){let i=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,d=arguments.length>9&&void 0!==arguments[9]?arguments[9]:null;try{let u=s?"".concat(s,"/key/list"):"/key/list";console.log("in keyListCall");let h=new URLSearchParams;o&&h.append("team_id",o.toString()),t&&h.append("organization_id",t.toString()),a&&h.append("key_alias",a),n&&h.append("key_hash",n),r&&h.append("user_id",r.toString()),l&&h.append("page",l.toString()),c&&h.append("size",c.toString()),i&&h.append("sort_by",i),d&&h.append("sort_order",d),h.append("return_full_object","true"),h.append("include_team_keys","true");let p=h.toString();p&&(u+="?".concat(p));let g=await fetch(u,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!g.ok){let e=await g.json(),t=ov(e);throw m(t),Error(t)}let w=await g.json();return console.log("/team/list API Response:",w),w}catch(e){throw console.error("Failed to create key:",e),e}},eq=async(e,t)=>{try{let o=s?"".concat(s,"/spend/users"):"/spend/users";console.log("in spendUsersCall:",o);let a=await fetch("".concat(o,"?user_id=").concat(t),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to get spend for user",e),e}},eZ=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/user/request_model"):"/user/request_model",n=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({models:[t],user_id:o,justification:a})});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log(l),l}catch(e){throw console.error("Failed to create key:",e),e}},eH=async e=>{try{let t=s?"".concat(s,"/user/get_requests"):"/user/get_requests";console.log("in userGetRequesedtModelsCall:",t);let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to get requested models:",e),e}},eW=async(e,t,o)=>{try{let a=s?"".concat(s,"/user/daily/activity/aggregated"):"/user/daily/activity/aggregated",r=new URLSearchParams,n=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)};r.append("start_date",n(t)),r.append("end_date",n(o));let l=r.toString();l&&(a+="?".concat(l));let c=await fetch(a,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.json(),t=ov(e);throw m(t),Error(t)}return await c.json()}catch(e){throw console.error("Failed to fetch aggregated user daily activity:",e),e}},eY=async(e,t)=>{try{let o=s?"".concat(s,"/user/get_users?role=").concat(t):"/user/get_users?role=".concat(t);console.log("in userGetAllUsersCall:",o);let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to get requested models:",e),e}},eK=async e=>{try{let t=s?"".concat(s,"/user/available_roles"):"/user/available_roles",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("response from user/available_role",a),a}catch(e){throw e}},e$=async(e,t)=>{try{if(console.log("Form Values in teamCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let o=s?"".concat(s,"/team/new"):"/team/new",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eQ=async(e,t)=>{try{if(console.log("Form Values in credentialCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let o=s?"".concat(s,"/credentials"):"/credentials",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eX=async e=>{try{let t=s?"".concat(s,"/credentials"):"/credentials";console.log("in credentialListCall");let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("/credentials API Response:",a),a}catch(e){throw console.error("Failed to create key:",e),e}},e0=async(e,t,o)=>{try{let a=s?"".concat(s,"/credentials"):"/credentials";t?a+="/by_name/".concat(t):o&&(a+="/by_model/".concat(o)),console.log("in credentialListCall");let r=await fetch(a,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("/credentials API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},e1=async(e,t)=>{try{let o=s?"".concat(s,"/credentials/").concat(t):"/credentials/".concat(t);console.log("in credentialDeleteCall:",t);let a=await fetch(o,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete key:",e),e}},e2=async(e,t,o)=>{try{if(console.log("Form Values in credentialUpdateCall:",o),o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let a=s?"".concat(s,"/credentials/").concat(t):"/credentials/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...o})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},e4=async(e,t)=>{try{if(console.log("Form Values in keyUpdateCall:",t),t.model_tpm_limit){console.log("formValues.model_tpm_limit:",t.model_tpm_limit);try{t.model_tpm_limit=JSON.parse(t.model_tpm_limit)}catch(e){throw Error("Failed to parse model_tpm_limit: "+e)}}if(t.model_rpm_limit){console.log("formValues.model_rpm_limit:",t.model_rpm_limit);try{t.model_rpm_limit=JSON.parse(t.model_rpm_limit)}catch(e){throw Error("Failed to parse model_rpm_limit: "+e)}}let o=s?"".concat(s,"/key/update"):"/key/update",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw m(e),console.error("Error response from the server:",e),Error(e)}let r=await a.json();return console.log("Update key Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},e3=async(e,t)=>{try{console.log("Form Values in teamUpateCall:",t);let o=s?"".concat(s,"/team/update"):"/team/update",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw m(e),console.error("Error response from the server:",e),n.Z.fromBackend("Failed to update team settings: "+e),Error(e)}let r=await a.json();return console.log("Update Team Response:",r),r}catch(e){throw console.error("Failed to update team:",e),e}},e5=async(e,t,o)=>{try{console.log("Form Values in modelUpateCall:",t);let a=s?"".concat(s,"/model/").concat(o,"/update"):"/model/".concat(o,"/update"),r=await fetch(a,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!r.ok){let e=await r.text();throw m(e),console.error("Error update from the server:",e),Error("Network response was not ok")}let n=await r.json();return console.log("Update model Response:",n),n}catch(e){throw console.error("Failed to update model:",e),e}},e6=async(e,t)=>{try{console.log("Form Values in modelUpateCall:",t);let o=s?"".concat(s,"/model/update"):"/model/update",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw m(e),console.error("Error update from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update model Response:",r),r}catch(e){throw console.error("Failed to update model:",e),e}},e7=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let r=s?"".concat(s,"/team/member_add"):"/team/member_add",n=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,member:o})});if(!n.ok){var a;let e=await n.text(),t={};try{t=JSON.parse(e)}catch(t){console.warn("Failed to parse error body as JSON:",e)}let o=(null==t?void 0:null===(a=t.detail)||void 0===a?void 0:a.error)||"Failed to add team member",r=Error(o);throw r.raw=t,r}let l=await n.json();return console.log("API Response:",l),l}catch(e){throw console.error("Failed to create key:",e),e}},e9=async(e,t,o,a,r)=>{try{console.log("Bulk add team members:",{teamId:t,members:o,maxBudgetInTeam:a});let l=s?"".concat(s,"/team/bulk_member_add"):"/team/bulk_member_add",c={team_id:t};r?c.all_users=!0:c.members=o,null!=a&&(c.max_budget_in_team=a);let i=await fetch(l,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(c)});if(!i.ok){var n;let e=await i.text(),t={};try{t=JSON.parse(e)}catch(t){console.warn("Failed to parse error body as JSON:",e)}let o=(null==t?void 0:null===(n=t.detail)||void 0===n?void 0:n.error)||"Failed to bulk add team members",a=Error(o);throw a.raw=t,a}let d=await i.json();return console.log("Bulk team member add API Response:",d),d}catch(e){throw console.error("Failed to bulk add team members:",e),e}},e8=async(e,t,o)=>{try{console.log("Form Values in teamMemberUpdateCall:",o),console.log("Budget value:",o.max_budget_in_team),console.log("TPM limit:",o.tpm_limit),console.log("RPM limit:",o.rpm_limit);let r=s?"".concat(s,"/team/member_update"):"/team/member_update",n={team_id:t,role:o.role,user_id:o.user_id};void 0!==o.user_email&&(n.user_email=o.user_email),void 0!==o.max_budget_in_team&&null!==o.max_budget_in_team&&(n.max_budget_in_team=o.max_budget_in_team),void 0!==o.tpm_limit&&null!==o.tpm_limit&&(n.tpm_limit=o.tpm_limit),void 0!==o.rpm_limit&&null!==o.rpm_limit&&(n.rpm_limit=o.rpm_limit),console.log("Final request body:",n);let l=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(n)});if(!l.ok){var a;let e=await l.text(),t={};try{t=JSON.parse(e)}catch(t){console.warn("Failed to parse error body as JSON:",e)}let o=(null==t?void 0:null===(a=t.detail)||void 0===a?void 0:a.error)||"Failed to add team member",r=Error(o);throw r.raw=t,r}let c=await l.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to update team member:",e),e}},te=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=s?"".concat(s,"/team/member_delete"):"/team/member_delete",r=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,...void 0!==o.user_email&&{user_email:o.user_email},...void 0!==o.user_id&&{user_id:o.user_id}})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},tt=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=s?"".concat(s,"/organization/member_add"):"/organization/member_add",r=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,member:o})});if(!r.ok){let e=await r.text();throw m(e),console.error("Error response from the server:",e),Error(e)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create organization member:",e),e}},to=async(e,t,o)=>{try{console.log("Form Values in organizationMemberDeleteCall:",o);let a=s?"".concat(s,"/organization/member_delete"):"/organization/member_delete",r=await fetch(a,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,user_id:o})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to delete organization member:",e),e}},ta=async(e,t,o)=>{try{console.log("Form Values in organizationMemberUpdateCall:",o);let a=s?"".concat(s,"/organization/member_update"):"/organization/member_update",r=await fetch(a,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,...o})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to update organization member:",e),e}},tr=async(e,t,o)=>{try{console.log("Form Values in userUpdateUserCall:",t);let a=s?"".concat(s,"/user/update"):"/user/update",r={...t};null!==o&&(r.user_role=o),r=JSON.stringify(r);let n=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:r});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return console.log("API Response:",l),l}catch(e){throw console.error("Failed to create key:",e),e}},tn=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];try{let r;console.log("Form Values in userUpdateUserCall:",t);let n=s?"".concat(s,"/user/bulk_update"):"/user/bulk_update";if(a)r=JSON.stringify({all_users:!0,user_updates:t});else if(o&&o.length>0){let e=[];for(let a of o)e.push({user_id:a,...t});r=JSON.stringify({users:e})}else throw Error("Must provide either userIds or set allUsers=true");let l=await fetch(n,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:r});if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}let c=await l.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},tl=async(e,t)=>{try{let o=s?"".concat(s,"/global/predict/spend/logs"):"/global/predict/spend/logs",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({data:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},tc=async e=>{try{let t=s?"".concat(s,"/health/services?service=slack_budget_alerts"):"/health/services?service=slack_budget_alerts";console.log("Checking Slack Budget Alerts service health");let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error(e)}let r=await o.json();return a.ZP.success("Test Slack Alert worked - check your Slack!"),console.log("Service Health Response:",r),r}catch(e){throw console.error("Failed to perform health check:",e),e}},ti=async(e,t)=>{try{let o=s?"".concat(s,"/health/services?service=").concat(t):"/health/services?service=".concat(t);console.log("Checking Slack Budget Alerts service health");let a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw m(e),Error(e)}return await a.json()}catch(e){throw console.error("Failed to perform health check:",e),e}},ts=async e=>{try{let t=s?"".concat(s,"/budget/list"):"/budget/list",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},td=async e=>{try{let t=s?"".concat(s,"/budget/settings"):"/budget/settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tu=async(e,t,o)=>{try{let t=s?"".concat(s,"/get/config/callbacks"):"/get/config/callbacks",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},th=async e=>{try{let t=s?"".concat(s,"/config/list?config_type=general_settings"):"/config/list?config_type=general_settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tp=async e=>{try{let t=s?"".concat(s,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tg=async(e,t)=>{try{let o=s?"".concat(s,"/config/field/info?field_name=").concat(t):"/config/field/info?field_name=".concat(t),a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},tm=async(e,t,o)=>{try{let r=s?"".concat(s,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",n=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,field_value:o})});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return a.ZP.success("Successfully updated value!"),l}catch(e){throw console.error("Failed to set callbacks:",e),e}},tf=async(e,t)=>{try{let o=s?"".concat(s,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},tw=async(e,t,o)=>{try{let r=s?"".concat(s,"/config/field/update"):"/config/field/update",n=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,field_value:o,config_type:"general_settings"})});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return a.ZP.success("Successfully updated value!"),l}catch(e){throw console.error("Failed to set callbacks:",e),e}},ty=async(e,t)=>{try{let o=s?"".concat(s,"/config/field/delete"):"/config/field/delete",r=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,config_type:"general_settings"})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return a.ZP.success("Field reset on proxy"),n}catch(e){throw console.error("Failed to get callbacks:",e),e}},tj=async(e,t)=>{try{let o=s?"".concat(s,"/config/pass_through_endpoint?endpoint_id=").concat(t):"/config/pass_through_endpoint".concat(t),a=await fetch(o,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},t_=async(e,t)=>{try{let o=s?"".concat(s,"/config/update"):"/config/update",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},tC=async e=>{try{let t=s?"".concat(s,"/health"):"/health",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to call /health:",e),e}},tk=async(e,t)=>{try{let o=s?"".concat(s,"/health?model=").concat(encodeURIComponent(t)):"/health?model=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to call /health for model ".concat(t,":"),e),e}},tv=async e=>{try{let t=s?"".concat(s,"/cache/ping"):"/cache/ping",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error(e)}return await o.json()}catch(e){throw console.error("Failed to call /cache/ping:",e),e}},tT=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:100,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;try{let n=s?"".concat(s,"/health/history"):"/health/history",l=new URLSearchParams;t&&l.append("model",t),o&&l.append("status_filter",o),l.append("limit",a.toString()),l.append("offset",r.toString()),l.toString()&&(n+="?".concat(l.toString()));let c=await fetch(n,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw m(e),Error(e)}return await c.json()}catch(e){throw console.error("Failed to call /health/history:",e),e}},tE=async e=>{try{let t=s?"".concat(s,"/health/latest"):"/health/latest",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error(e)}return await o.json()}catch(e){throw console.error("Failed to call /health/latest:",e),e}},tS=async e=>{try{console.log("Getting proxy UI settings"),console.log("proxyBaseUrl in getProxyUISettings:",s);let t=s?"".concat(s,"/sso/get/ui_settings"):"/sso/get/ui_settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tb=async e=>{try{let t=s?"".concat(s,"/v2/guardrails/list"):"/v2/guardrails/list",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get guardrails list:",e),e}},tF=async e=>{try{let t=s?"".concat(s,"/prompts/list"):"/prompts/list",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to get prompts list:",e),e}},tP=async(e,t)=>{try{let o=s?"".concat(s,"/prompts/").concat(t,"/info"):"/prompts/".concat(t,"/info"),a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to get prompt info:",e),e}},tO=async(e,t)=>{try{let o=s?"".concat(s,"/prompts"):"/prompts",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to create prompt:",e),e}},tB=async(e,t,o)=>{try{let a=s?"".concat(s,"/prompts/").concat(t):"/prompts/".concat(t),r=await fetch(a,{method:"PUT",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}return await r.json()}catch(e){throw console.error("Failed to update prompt:",e),e}},tN=async(e,t)=>{try{let o=s?"".concat(s,"/prompts/").concat(t):"/prompts/".concat(t),a=await fetch(o,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to delete prompt:",e),e}},tx=async(e,t)=>{try{let o=new FormData;o.append("file",t);let a=s?"".concat(s,"/utils/dotprompt_json_converter"):"/utils/dotprompt_json_converter",r=await fetch(a,{method:"POST",headers:{[f]:"Bearer ".concat(e)},body:o});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}return await r.json()}catch(e){throw console.error("Failed to convert prompt file:",e),e}},tG=async(e,t,o)=>{try{let a=s?"".concat(s,"/prompts/").concat(t):"/prompts/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}return await r.json()}catch(e){throw console.error("Failed to patch prompt:",e),e}},tJ=async(e,t)=>{try{let o=s?"".concat(s,"/guardrails"):"/guardrails",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({guardrail:t})});if(!a.ok){let e=await a.text();throw m(e),Error(e)}let r=await a.json();return console.log("Create guardrail response:",r),r}catch(e){throw console.error("Failed to create guardrail:",e),e}},tA=async(e,t,o)=>{try{let a=s?"".concat(s,"/spend/logs/ui/").concat(t,"?start_date=").concat(encodeURIComponent(o)):"/spend/logs/ui/".concat(t,"?start_date=").concat(encodeURIComponent(o));console.log("Fetching log details from:",a);let r=await fetch(a,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("Fetched log details:",n),n}catch(e){throw console.error("Failed to fetch log details:",e),e}},tU=async e=>{try{let t=s?"".concat(s,"/get/internal_user_settings"):"/get/internal_user_settings";console.log("Fetching SSO settings from:",t);let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("Fetched SSO settings:",a),a}catch(e){throw console.error("Failed to fetch SSO settings:",e),e}},tR=async(e,t)=>{try{let o=s?"".concat(s,"/update/internal_user_settings"):"/update/internal_user_settings";console.log("Updating internal user settings:",t);let r=await fetch(o,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!r.ok){let e=await r.text();throw m(e),Error(e)}let n=await r.json();return console.log("Updated internal user settings:",n),a.ZP.success("Internal user settings updated successfully"),n}catch(e){throw console.error("Failed to update internal user settings:",e),e}},tI=async e=>{try{let t=s?"".concat(s,"/v1/mcp/server"):"/v1/mcp/server";console.log("Fetching MCP servers from:",t);let o=await fetch(t,{method:h.GET,headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("Fetched MCP servers:",a),a}catch(e){throw console.error("Failed to fetch MCP servers:",e),e}},tM=async e=>{try{let t=s?"".concat(s,"/v1/mcp/access_groups"):"/v1/mcp/access_groups";console.log("Fetching MCP access groups from:",t);let o=await fetch(t,{method:h.GET,headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("Fetched MCP access groups:",a),a.access_groups||[]}catch(e){throw console.error("Failed to fetch MCP access groups:",e),e}},tz=async(e,t)=>{try{console.log("Form Values in createMCPServer:",t);let o=s?"".concat(s,"/v1/mcp/server"):"/v1/mcp/server",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},tL=async(e,t)=>{try{let o=s?"".concat(s,"/v1/mcp/server"):"/v1/mcp/server",a=await fetch(o,{method:"PUT",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to update MCP server:",e),e}},tD=async(e,t)=>{try{let o=(s?"".concat(s):"")+"/v1/mcp/server/".concat(t);console.log("in deleteMCPServer:",t);let a=await fetch(o,{method:h.DELETE,headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}}catch(e){throw console.error("Failed to delete key:",e),e}},tV=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/mcp-rest/tools/list?server_id=").concat(t):"/mcp-rest/tools/list?server_id=".concat(t);console.log("Fetching MCP tools from:",r);let n={[f]:"Bearer ".concat(e),"Content-Type":"application/json"};a&&o?n["x-mcp-".concat(a,"-authorization")]=o:o&&(n[w]=o);let l=await fetch(r,{method:"GET",headers:n}),c=await l.json();if(console.log("Fetched MCP tools response:",c),!l.ok){if(c.error&&c.message)throw Error(c.message);throw Error("Failed to fetch MCP tools")}return c}catch(e){return console.error("Failed to fetch MCP tools:",e),{tools:[],error:"network_error",message:e instanceof Error?e.message:"Failed to fetch MCP tools"}}},tq=async(e,t,o,a,r)=>{try{let n=s?"".concat(s,"/mcp-rest/tools/call"):"/mcp-rest/tools/call";console.log("Calling MCP tool:",t,"with arguments:",o);let l={[f]:"Bearer ".concat(e),"Content-Type":"application/json"};r?l["x-mcp-".concat(r,"-authorization")]=a:l[w]=a;let c=await fetch(n,{method:"POST",headers:l,body:JSON.stringify({name:t,arguments:o})});if(!c.ok){let e="Network response was not ok",t=null,o=await c.text();try{let a=JSON.parse(o);a.detail?"string"==typeof a.detail?e=a.detail:"object"==typeof a.detail&&(e=a.detail.message||a.detail.error||"An error occurred",t=a.detail):e=a.message||a.error||e}catch(t){console.error("Failed to parse JSON error response:",t),o&&(e=o)}let a=Error(e);throw a.status=c.status,a.statusText=c.statusText,a.details=t,m(e),a}let i=await c.json();return console.log("MCP tool call response:",i),i}catch(e){throw console.error("Failed to call MCP tool:",e),console.error("Error type:",typeof e),e instanceof Error&&(console.error("Error message:",e.message),console.error("Error stack:",e.stack)),e}},tZ=async(e,t)=>{try{let o=s?"".concat(s,"/tag/new"):"/tag/new",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();await m(e);return}return await a.json()}catch(e){throw console.error("Error creating tag:",e),e}},tH=async(e,t)=>{try{let o=s?"".concat(s,"/tag/update"):"/tag/update",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();await m(e);return}return await a.json()}catch(e){throw console.error("Error updating tag:",e),e}},tW=async(e,t)=>{try{let o=s?"".concat(s,"/tag/info"):"/tag/info",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({names:t})});if(!a.ok){let e=await a.text();return await m(e),{}}return await a.json()}catch(e){throw console.error("Error getting tag info:",e),e}},tY=async e=>{try{let t=s?"".concat(s,"/tag/list"):"/tag/list",o=await fetch(t,{method:"GET",headers:{Authorization:"Bearer ".concat(e)}});if(!o.ok){let e=await o.text();return await m(e),{}}return await o.json()}catch(e){throw console.error("Error listing tags:",e),e}},tK=async(e,t)=>{try{let o=s?"".concat(s,"/tag/delete"):"/tag/delete",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({name:t})});if(!a.ok){let e=await a.text();await m(e);return}return await a.json()}catch(e){throw console.error("Error deleting tag:",e),e}},t$=async e=>{try{let t=s?"".concat(s,"/get/default_team_settings"):"/get/default_team_settings";console.log("Fetching default team settings from:",t);let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("Fetched default team settings:",a),a}catch(e){throw console.error("Failed to fetch default team settings:",e),e}},tQ=async(e,t)=>{try{let o=s?"".concat(s,"/update/default_team_settings"):"/update/default_team_settings";console.log("Updating default team settings:",t);let r=await fetch(o,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("Updated default team settings:",n),a.ZP.success("Default team settings updated successfully"),n}catch(e){throw console.error("Failed to update default team settings:",e),e}},tX=async(e,t)=>{try{let o=s?"".concat(s,"/team/permissions_list?team_id=").concat(t):"/team/permissions_list?team_id=".concat(t),a=await fetch(o,{method:"GET",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("Team permissions response:",r),r}catch(e){throw console.error("Failed to get team permissions:",e),e}},t0=async(e,t,o)=>{try{let a=s?"".concat(s,"/team/permissions_update"):"/team/permissions_update",r=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({team_id:t,team_member_permissions:o})});if(!r.ok){let e=await r.json(),t=ov(e);throw m(t),Error(t)}let n=await r.json();return console.log("Team permissions response:",n),n}catch(e){throw console.error("Failed to update team permissions:",e),e}},t1=async(e,t)=>{try{let o=s?"".concat(s,"/spend/logs/session/ui?session_id=").concat(encodeURIComponent(t)):"/spend/logs/session/ui?session_id=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to fetch session logs:",e),e}},t2=async(e,t)=>{try{let o=s?"".concat(s,"/vector_store/new"):"/vector_store/new",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to create vector store")}return await a.json()}catch(e){throw console.error("Error creating vector store:",e),e}},t4=async function(e){arguments.length>1&&void 0!==arguments[1]&&arguments[1],arguments.length>2&&void 0!==arguments[2]&&arguments[2];try{let t=s?"".concat(s,"/vector_store/list"):"/vector_store/list",o=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}});if(!o.ok){let e=await o.json();throw Error(e.detail||"Failed to list vector stores")}return await o.json()}catch(e){throw console.error("Error listing vector stores:",e),e}},t3=async(e,t)=>{try{let o=s?"".concat(s,"/vector_store/delete"):"/vector_store/delete",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({vector_store_id:t})});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to delete vector store")}return await a.json()}catch(e){throw console.error("Error deleting vector store:",e),e}},t5=async(e,t)=>{try{let o=s?"".concat(s,"/vector_store/info"):"/vector_store/info",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({vector_store_id:t})});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to get vector store info")}return await a.json()}catch(e){throw console.error("Error getting vector store info:",e),e}},t6=async(e,t)=>{try{let o=s?"".concat(s,"/vector_store/update"):"/vector_store/update",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to update vector store")}return await a.json()}catch(e){throw console.error("Error updating vector store:",e),e}},t7=async e=>{try{let t=s?"".concat(s,"/email/event_settings"):"/email/event_settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error("Failed to get email event settings")}let a=await o.json();return console.log("Email event settings response:",a),a}catch(e){throw console.error("Failed to get email event settings:",e),e}},t9=async(e,t)=>{try{let o=s?"".concat(s,"/email/event_settings"):"/email/event_settings",a=await fetch(o,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw m(e),Error("Failed to update email event settings")}let r=await a.json();return console.log("Update email event settings response:",r),r}catch(e){throw console.error("Failed to update email event settings:",e),e}},t8=async e=>{try{let t=s?"".concat(s,"/email/event_settings/reset"):"/email/event_settings/reset",o=await fetch(t,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error("Failed to reset email event settings")}let a=await o.json();return console.log("Reset email event settings response:",a),a}catch(e){throw console.error("Failed to reset email event settings:",e),e}},oe=async(e,t)=>{try{let o=s?"".concat(s,"/guardrails/").concat(t):"/guardrails/".concat(t),a=await fetch(o,{method:"DELETE",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw m(e),Error(e)}let r=await a.json();return console.log("Delete guardrail response:",r),r}catch(e){throw console.error("Failed to delete guardrail:",e),e}},ot=async e=>{try{let t=s?"".concat(s,"/guardrails/ui/add_guardrail_settings"):"/guardrails/ui/add_guardrail_settings",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error("Failed to get guardrail UI settings")}let a=await o.json();return console.log("Guardrail UI settings response:",a),a}catch(e){throw console.error("Failed to get guardrail UI settings:",e),e}},oo=async e=>{try{let t=s?"".concat(s,"/guardrails/ui/provider_specific_params"):"/guardrails/ui/provider_specific_params",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw m(e),Error("Failed to get guardrail provider specific parameters")}let a=await o.json();return console.log("Guardrail provider specific params response:",a),a}catch(e){throw console.error("Failed to get guardrail provider specific parameters:",e),e}},oa=async(e,t)=>{try{let o=s?"".concat(s,"/guardrails/").concat(t,"/info"):"/guardrails/".concat(t,"/info"),a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw m(e),Error("Failed to get guardrail info")}let r=await a.json();return console.log("Guardrail info response:",r),r}catch(e){throw console.error("Failed to get guardrail info:",e),e}},or=async(e,t,o)=>{try{let a=s?"".concat(s,"/guardrails/").concat(t):"/guardrails/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.text();throw m(e),Error("Failed to update guardrail")}let n=await r.json();return console.log("Update guardrail response:",n),n}catch(e){throw console.error("Failed to update guardrail:",e),e}},on=async e=>{try{let t=s?"".concat(s,"/get/sso_settings"):"/get/sso_settings";console.log("Fetching SSO configuration from:",t);let o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}let a=await o.json();return console.log("Fetched SSO configuration:",a),a}catch(e){throw console.error("Failed to fetch SSO configuration:",e),e}},ol=async(e,t)=>{try{let o=s?"".concat(s,"/update/sso_settings"):"/update/sso_settings";console.log("Updating SSO configuration:",t);let a=await fetch(o,{method:"PATCH",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=await a.json();return console.log("Updated SSO configuration:",r),r}catch(e){throw console.error("Failed to update SSO configuration:",e),e}},oc=async(e,t,o,a,r)=>{try{let t=s?"".concat(s,"/audit"):"/audit",o=new URLSearchParams;a&&o.append("page",a.toString()),r&&o.append("page_size",r.toString());let n=o.toString();n&&(t+="?".concat(n));let l=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!l.ok){let e=await l.json(),t=ov(e);throw m(t),Error(t)}return await l.json()}catch(e){throw console.error("Failed to fetch audit logs:",e),e}},oi=async e=>{try{let t=s?"".concat(s,"/user/available_users"):"/user/available_users",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e)}});if(!o.ok){if(404===o.status)return null;let e=await o.text();throw m(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to fetch remaining users:",e),e}},os=async(e,t,o)=>{try{let r=s?"".concat(s,"/config/pass_through_endpoint/").concat(encodeURIComponent(t)):"/config/pass_through_endpoint/".concat(encodeURIComponent(t)),n=await fetch(r,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!n.ok){let e=await n.json(),t=ov(e);throw m(t),Error(t)}let l=await n.json();return a.ZP.success("Pass through endpoint updated successfully"),l}catch(e){throw console.error("Failed to update pass through endpoint:",e),e}},od=async(e,t)=>{try{let o=s?"".concat(s,"/config/pass_through_endpoint?endpoint_id=").concat(encodeURIComponent(t)):"/config/pass_through_endpoint?endpoint_id=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}let r=(await a.json()).endpoints;if(!r||0===r.length)throw Error("Pass through endpoint not found");return r[0]}catch(e){throw console.error("Failed to get pass through endpoint info:",e),e}},ou=async(e,t)=>{try{let o=s?"".concat(s,"/config/callback/delete"):"/config/callback/delete",a=await fetch(o,{method:"POST",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({callback_name:t})});if(!a.ok){let e=await a.json(),t=ov(e);throw m(t),Error(t)}return await a.json()}catch(e){throw console.error("Failed to delete specific callback:",e),e}},oh=async e=>{let t=u(),o=await fetch("".concat(t,"/v1/mcp/tools"),{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw Error("HTTP error! status: ".concat(o.status));return await o.json()},op=async(e,t)=>{try{console.log("Testing MCP connection with config:",JSON.stringify(t));let a=s?"".concat(s,"/mcp-rest/test/connection"):"/mcp-rest/test/connection",r=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",[f]:"Bearer ".concat(e)},body:JSON.stringify(t)}),n=r.headers.get("content-type");if(!n||!n.includes("application/json")){let e=await r.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(r.status,": ").concat(r.statusText,"). Check network tab for details."))}let l=await r.json();if(!r.ok||"error"===l.status){if("error"===l.status);else{var o;return{status:"error",message:(null===(o=l.error)||void 0===o?void 0:o.message)||"MCP connection test failed: ".concat(r.status," ").concat(r.statusText)}}}return l}catch(e){throw console.error("MCP connection test error:",e),e}},og=async(e,t)=>{try{console.log("Testing MCP tools list with config:",JSON.stringify(t));let o=s?"".concat(s,"/mcp-rest/test/tools/list"):"/mcp-rest/test/tools/list",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",[f]:"Bearer ".concat(e)},body:JSON.stringify(t)}),r=a.headers.get("content-type");if(!r||!r.includes("application/json")){let e=await a.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(a.status,": ").concat(a.statusText,"). Check network tab for details."))}let n=await a.json();if((!a.ok||n.error)&&!n.error)return{tools:[],error:"request_failed",message:n.message||"MCP tools list failed: ".concat(a.status," ").concat(a.statusText)};return n}catch(e){throw console.error("MCP tools list test error:",e),e}},om=async(e,t,o)=>{try{let a="".concat(u(),"/v1/vector_stores/").concat(t,"/search"),r=await fetch(a,{method:"POST",headers:{Authorization:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({query:o})});if(!r.ok){let e=await r.text();return await m(e),null}return await r.json()}catch(e){throw console.error("Error testing vector store search:",e),e}},of=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:50,n=arguments.length>5?arguments[5]:void 0;try{let l=s?"".concat(s,"/tag/user-agent/analytics"):"/tag/user-agent/analytics",c=new URLSearchParams,i=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)};c.append("start_date",i(t)),c.append("end_date",i(o)),c.append("page",a.toString()),c.append("page_size",r.toString()),n&&c.append("user_agent_filter",n);let d=c.toString();d&&(l+="?".concat(d));let u=await fetch(l,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!u.ok){let e=await u.json(),t=ov(e);throw m(t),Error(t)}return await u.json()}catch(e){throw console.error("Failed to fetch user agent analytics:",e),e}},ow=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/tag/dau"):"/tag/dau",n=new URLSearchParams;n.append("end_date",(e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)})(t)),a&&a.length>0?a.forEach(e=>{n.append("tag_filters",e)}):o&&n.append("tag_filter",o);let l=n.toString();l&&(r+="?".concat(l));let c=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.json(),t=ov(e);throw m(t),Error(t)}return await c.json()}catch(e){throw console.error("Failed to fetch DAU:",e),e}},oy=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/tag/wau"):"/tag/wau",n=new URLSearchParams;n.append("end_date",(e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)})(t)),a&&a.length>0?a.forEach(e=>{n.append("tag_filters",e)}):o&&n.append("tag_filter",o);let l=n.toString();l&&(r+="?".concat(l));let c=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.json(),t=ov(e);throw m(t),Error(t)}return await c.json()}catch(e){throw console.error("Failed to fetch WAU:",e),e}},oj=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/tag/mau"):"/tag/mau",n=new URLSearchParams;n.append("end_date",(e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)})(t)),a&&a.length>0?a.forEach(e=>{n.append("tag_filters",e)}):o&&n.append("tag_filter",o);let l=n.toString();l&&(r+="?".concat(l));let c=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.json(),t=ov(e);throw m(t),Error(t)}return await c.json()}catch(e){throw console.error("Failed to fetch MAU:",e),e}},o_=async e=>{try{let t=s?"".concat(s,"/tag/distinct"):"/tag/distinct",o=await fetch(t,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.json(),t=ov(e);throw m(t),Error(t)}return await o.json()}catch(e){throw console.error("Failed to fetch distinct tags:",e),e}},oC=async(e,t,o,a)=>{try{let r=s?"".concat(s,"/tag/summary"):"/tag/summary",n=new URLSearchParams,l=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)};n.append("start_date",l(t)),n.append("end_date",l(o)),a&&a.length>0&&a.forEach(e=>{n.append("tag_filters",e)});let c=n.toString();c&&(r+="?".concat(c));let i=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.json(),t=ov(e);throw m(t),Error(t)}return await i.json()}catch(e){throw console.error("Failed to fetch user agent summary:",e),e}},ok=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:50,a=arguments.length>3?arguments[3]:void 0;try{let r=s?"".concat(s,"/tag/user-agent/per-user-analytics"):"/tag/user-agent/per-user-analytics",n=new URLSearchParams;n.append("page",t.toString()),n.append("page_size",o.toString()),a&&a.length>0&&a.forEach(e=>{n.append("tag_filters",e)});let l=n.toString();l&&(r+="?".concat(l));let c=await fetch(r,{method:"GET",headers:{[f]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.json(),t=ov(e);throw m(t),Error(t)}return await c.json()}catch(e){throw console.error("Failed to fetch per-user analytics:",e),e}},ov=e=>(null==e?void 0:e.error)&&(e.error.message||e.error)||(null==e?void 0:e.message)||(null==e?void 0:e.detail)||(null==e?void 0:e.error)||JSON.stringify(e)},85968:function(e,t,o){o.d(t,{O:function(){return a}});let a=e=>{if(!e)return"An unknown error occurred";if("string"==typeof e)return e;if(e.message)try{let t=JSON.parse(e.message);if(t.error&&t.error.message)return t.error.message;return"string"==typeof t?t:JSON.stringify(t,null,2)}catch(t){return e.message}if(e.response&&e.response.data){if("string"==typeof e.response.data)return e.response.data;if(e.response.data.message)return e.response.data.message;if(e.response.data.error)return"string"==typeof e.response.data.error?e.response.data.error:e.response.data.error.message||JSON.stringify(e.response.data.error)}return String(e)}},3914:function(e,t,o){function a(){let e=window.location.hostname,t=["Lax","Strict","None"];["/","/ui"].forEach(o=>{document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,";"),document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,"; domain=").concat(e,";"),t.forEach(t=>{let a="None"===t?" Secure;":"";document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,"; SameSite=").concat(t,";").concat(a),document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,"; domain=").concat(e,"; SameSite=").concat(t,";").concat(a)})}),console.log("After clearing cookies:",document.cookie)}function r(e){let t=document.cookie.split("; ").find(t=>t.startsWith(e+"="));return t?t.split("=")[1]:null}o.d(t,{b:function(){return a},e:function(){return r}})}}]);
\ No newline at end of file
diff --git a/litellm/proxy/_experimental/out/_next/static/chunks/154-7bf3bbb913e68f71.js b/litellm/proxy/_experimental/out/_next/static/chunks/154-7bf3bbb913e68f71.js
deleted file mode 100644
index da2cab320b..0000000000
--- a/litellm/proxy/_experimental/out/_next/static/chunks/154-7bf3bbb913e68f71.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[154],{31283:function(e,t,o){o.d(t,{o:function(){return a.Z}});var a=o(49566)},63610:function(e,t,o){o.d(t,{d:function(){return u}});var a=o(57437),r=o(2265),n=o(64482),c=o(52787),s=o(20577),l=o(13634),i=o(31283),d=o(15424),p=o(89970),h=o(19250);let u=["metadata","config","enforced_params","aliases"],w=(e,t)=>u.includes(e)||"json"===t.format,g=e=>{if(!e)return!0;try{return JSON.parse(e),!0}catch(e){return!1}},f=(e,t,o)=>{let a={max_budget:"Enter maximum budget in USD (e.g., 100.50)",budget_duration:"Select a time period for budget reset",tpm_limit:"Enter maximum tokens per minute (whole number)",rpm_limit:"Enter maximum requests per minute (whole number)",duration:"Enter duration (e.g., 30s, 24h, 7d)",metadata:'Enter JSON object with key-value pairs\nExample: {"team": "research", "project": "nlp"}',config:'Enter configuration as JSON object\nExample: {"setting": "value"}',permissions:"Enter comma-separated permission strings",enforced_params:'Enter parameters as JSON object\nExample: {"param": "value"}',blocked:"Enter true/false or specific block conditions",aliases:'Enter aliases as JSON object\nExample: {"alias1": "value1", "alias2": "value2"}',models:"Select one or more model names",key_alias:"Enter a unique identifier for this key",tags:"Enter comma-separated tag strings"}[e]||({string:"Text input",number:"Numeric input",integer:"Whole number input",boolean:"True/False value"})[o]||"Text input";return w(e,t)?"".concat(a,"\nMust be valid JSON format"):t.enum?"Select from available options\nAllowed values: ".concat(t.enum.join(", ")):a};t.Z=e=>{let{schemaComponent:t,excludedFields:o=[],form:u,overrideLabels:m={},overrideTooltips:y={},customValidation:k={},defaultValues:C={}}=e,[_,T]=(0,r.useState)(null),[E,j]=(0,r.useState)(null);(0,r.useEffect)(()=>{(async()=>{try{let e=(await (0,h.getOpenAPISchema)()).components.schemas[t];if(!e)throw Error('Schema component "'.concat(t,'" not found'));T(e);let a={};Object.keys(e.properties).filter(e=>!o.includes(e)&&void 0!==C[e]).forEach(e=>{a[e]=C[e]}),u.setFieldsValue(a)}catch(e){console.error("Schema fetch error:",e),j(e instanceof Error?e.message:"Failed to fetch schema")}})()},[t,u,o]);let S=e=>{if(e.type)return e.type;if(e.anyOf){let t=e.anyOf.map(e=>e.type);if(t.includes("number")||t.includes("integer"))return"number";t.includes("string")}return"string"},v=(e,t)=>{var o;let r;let h=S(t),u=null==_?void 0:null===(o=_.required)||void 0===o?void 0:o.includes(e),T=m[e]||t.title||e,E=y[e]||t.description,j=[];u&&j.push({required:!0,message:"".concat(T," is required")}),k[e]&&j.push({validator:k[e]}),w(e,t)&&j.push({validator:async(e,t)=>{if(t&&!g(t))throw Error("Please enter valid JSON")}});let v=E?(0,a.jsxs)("span",{children:[T," ",(0,a.jsx)(p.Z,{title:E,children:(0,a.jsx)(d.Z,{style:{marginLeft:"4px"}})})]}):T;return r=w(e,t)?(0,a.jsx)(n.default.TextArea,{rows:4,placeholder:"Enter as JSON",className:"font-mono"}):t.enum?(0,a.jsx)(c.default,{children:t.enum.map(e=>(0,a.jsx)(c.default.Option,{value:e,children:e},e))}):"number"===h||"integer"===h?(0,a.jsx)(s.Z,{style:{width:"100%"},precision:"integer"===h?0:void 0}):"duration"===e?(0,a.jsx)(i.o,{placeholder:"eg: 30s, 30h, 30d"}):(0,a.jsx)(i.o,{placeholder:E||""}),(0,a.jsx)(l.Z.Item,{label:v,name:e,className:"mt-8",rules:j,initialValue:C[e],help:(0,a.jsx)("div",{className:"text-xs text-gray-500",children:f(e,t,h)}),children:r},e)};return E?(0,a.jsxs)("div",{className:"text-red-500",children:["Error: ",E]}):(null==_?void 0:_.properties)?(0,a.jsx)("div",{children:Object.entries(_.properties).filter(e=>{let[t]=e;return!o.includes(t)}).map(e=>{let[t,o]=e;return v(t,o)})}):null}},19250:function(e,t,o){o.r(t),o.d(t,{DEFAULT_ORGANIZATION:function(){return h},PredictedSpendLogsCall:function(){return tn},addAllowedIP:function(){return ew},adminGlobalActivity:function(){return eG},adminGlobalActivityExceptions:function(){return eA},adminGlobalActivityExceptionsPerDeployment:function(){return eR},adminGlobalActivityPerModel:function(){return eU},adminGlobalCacheActivity:function(){return eJ},adminSpendLogsCall:function(){return ex},adminTopEndUsersCall:function(){return eO},adminTopKeysCall:function(){return eP},adminTopModelsCall:function(){return eI},adminspendByProvider:function(){return eB},alertingSettingsCall:function(){return J},allEndUsersCall:function(){return ev},allTagNamesCall:function(){return eS},availableTeamListCall:function(){return Z},budgetCreateCall:function(){return P},budgetDeleteCall:function(){return x},budgetUpdateCall:function(){return O},cachingHealthCheckCall:function(){return tT},callMCPTool:function(){return tV},cancelModelCostMapReload:function(){return S},claimOnboardingToken:function(){return en},convertPromptFileToJson:function(){return tO},createGuardrailCall:function(){return tG},createMCPServer:function(){return tM},createPassThroughEndpoint:function(){return tg},createPromptCall:function(){return tF},credentialCreateCall:function(){return eQ},credentialDeleteCall:function(){return e0},credentialGetCall:function(){return e$},credentialListCall:function(){return eX},credentialUpdateCall:function(){return e1},defaultProxyBaseUrl:function(){return c},deleteAllowedIP:function(){return eg},deleteCallback:function(){return od},deleteConfigFieldSetting:function(){return tm},deleteGuardrailCall:function(){return t8},deleteMCPServer:function(){return tz},deletePassThroughEndpointsCall:function(){return ty},deletePromptCall:function(){return tP},fetchMCPAccessGroups:function(){return tI},fetchMCPServers:function(){return tR},formatDate:function(){return n},getAllowedIPs:function(){return eu},getBudgetList:function(){return tl},getBudgetSettings:function(){return ti},getCallbacksCall:function(){return td},getConfigFieldSetting:function(){return tu},getDefaultTeamSettings:function(){return tK},getEmailEventSettings:function(){return t6},getGeneralSettingsCall:function(){return tp},getGuardrailInfo:function(){return oo},getGuardrailProviderSpecificParams:function(){return ot},getGuardrailUISettings:function(){return oe},getGuardrailsList:function(){return tv},getInternalUserSettings:function(){return tU},getModelCostMapReloadStatus:function(){return v},getOnboardingCredentials:function(){return er},getOpenAPISchema:function(){return _},getPassThroughEndpointInfo:function(){return oi},getPassThroughEndpointsCall:function(){return th},getPossibleUserRoles:function(){return eW},getPromptInfo:function(){return tN},getPromptsList:function(){return tb},getProxyBaseUrl:function(){return d},getProxyUISettings:function(){return tS},getPublicModelHubInfo:function(){return C},getRemainingUsers:function(){return os},getSSOSettings:function(){return or},getTeamPermissionsCall:function(){return tX},getTotalSpendCall:function(){return ea},getUiConfig:function(){return k},healthCheckCall:function(){return tC},healthCheckHistoryCall:function(){return tE},individualModelHealthCheckCall:function(){return t_},invitationClaimCall:function(){return G},invitationCreateCall:function(){return B},keyCreateCall:function(){return A},keyCreateServiceAccountCall:function(){return U},keyDeleteCall:function(){return I},keyInfoCall:function(){return eM},keyInfoV1Call:function(){return ez},keyListCall:function(){return eD},keySpendLogsCall:function(){return eT},keyUpdateCall:function(){return e2},latestHealthChecksCall:function(){return tj},listMCPTools:function(){return tD},makeModelGroupPublic:function(){return y},mcpToolsCall:function(){return op},modelAvailableCall:function(){return e_},modelCostMap:function(){return T},modelCreateCall:function(){return b},modelDeleteCall:function(){return F},modelExceptionsCall:function(){return ek},modelHubCall:function(){return eh},modelHubPublicModelsCall:function(){return ep},modelInfoCall:function(){return ei},modelInfoV1Call:function(){return ed},modelMetricsCall:function(){return ef},modelMetricsSlowResponsesCall:function(){return ey},modelPatchUpdateCall:function(){return e4},modelSettingsCall:function(){return N},modelUpdateCall:function(){return e5},organizationCreateCall:function(){return K},organizationDeleteCall:function(){return X},organizationInfoCall:function(){return W},organizationListCall:function(){return Y},organizationMemberAddCall:function(){return te},organizationMemberDeleteCall:function(){return tt},organizationMemberUpdateCall:function(){return to},organizationUpdateCall:function(){return Q},patchPromptCall:function(){return tB},perUserAnalyticsCall:function(){return o_},proxyBaseUrl:function(){return l},regenerateKeyCall:function(){return ec},reloadModelCostMap:function(){return E},resetEmailEventSettings:function(){return t9},scheduleModelCostMapReload:function(){return j},serverRootPath:function(){return s},serviceHealthCheck:function(){return ts},sessionSpendLogsCall:function(){return t0},setCallbacksCall:function(){return tk},setGlobalLitellmHeaderName:function(){return m},slackBudgetAlertsHealthCheck:function(){return tc},spendUsersCall:function(){return eV},streamingModelMetricsCall:function(){return em},tagCreateCall:function(){return tq},tagDailyActivityCall:function(){return et},tagDauCall:function(){return of},tagDeleteCall:function(){return tW},tagDistinctCall:function(){return ok},tagInfoCall:function(){return tZ},tagListCall:function(){return tY},tagMauCall:function(){return oy},tagUpdateCall:function(){return tH},tagWauCall:function(){return om},tagsSpendLogsCall:function(){return ej},teamBulkMemberAddCall:function(){return e7},teamCreateCall:function(){return eK},teamDailyActivityCall:function(){return eo},teamDeleteCall:function(){return L},teamInfoCall:function(){return V},teamListCall:function(){return H},teamMemberAddCall:function(){return e6},teamMemberDeleteCall:function(){return e8},teamMemberUpdateCall:function(){return e9},teamPermissionsUpdateCall:function(){return t$},teamSpendLogsCall:function(){return eE},teamUpdateCall:function(){return e3},testConnectionRequest:function(){return eL},testMCPConnectionRequest:function(){return oh},testMCPToolsListRequest:function(){return ou},transformRequestCall:function(){return $},uiAuditLogsCall:function(){return oc},uiSpendLogDetailsCall:function(){return tJ},uiSpendLogsCall:function(){return eF},updateConfigFieldSetting:function(){return tf},updateDefaultTeamSettings:function(){return tQ},updateEmailEventSettings:function(){return t7},updateGuardrailCall:function(){return oa},updateInternalUserSettings:function(){return tA},updateMCPServer:function(){return tL},updatePassThroughEndpoint:function(){return ol},updatePassThroughFieldSetting:function(){return tw},updatePromptCall:function(){return tx},updateSSOSettings:function(){return on},updateUsefulLinksCall:function(){return eC},userAgentAnalyticsCall:function(){return og},userAgentSummaryCall:function(){return oC},userBulkUpdateUserCall:function(){return tr},userCreateCall:function(){return R},userDailyActivityAggregatedCall:function(){return eZ},userDailyActivityCall:function(){return ee},userDeleteCall:function(){return M},userFilterUICall:function(){return eb},userGetAllUsersCall:function(){return eY},userGetRequesedtModelsCall:function(){return eH},userInfoCall:function(){return D},userListCall:function(){return z},userRequestModelCall:function(){return eq},userSpendLogsCall:function(){return eN},userUpdateUserCall:function(){return ta},v2TeamListCall:function(){return q},vectorStoreCreateCall:function(){return t1},vectorStoreDeleteCall:function(){return t3},vectorStoreInfoCall:function(){return t4},vectorStoreListCall:function(){return t2},vectorStoreSearchCall:function(){return ow},vectorStoreUpdateCall:function(){return t5}});var a=o(42264),r=o(63610);let n=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)},c=null,s="/",l=null;console.log=function(){};let i=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=window.location.origin,a=t||o;console.log("proxyBaseUrl:",l),console.log("serverRootPath:",e),e.length>0&&!a.endsWith(e)&&"/"!=e&&(a+=e,l=a),console.log("Updated proxyBaseUrl:",l)},d=()=>l||window.location.origin,p={GET:"GET",DELETE:"DELETE"},h="default_organization",u=0,w=async e=>{let t=Date.now();t-u>6e4?(e.includes("Authentication Error - Expired Key")&&(a.ZP.info("UI Session Expired. Logging out."),u=t,document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;",window.location.href=window.location.pathname),u=t):console.log("Error suppressed to prevent spam:",e)},g="Authorization",f="x-mcp-auth";function m(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Authorization";console.log("setGlobalLitellmHeaderName: ".concat(e)),g=e}let y=async(e,t)=>{let o=l?"".concat(l,"/model_group/make_public"):"/model_group/make_public";return(await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({model_groups:t})})).json()},k=async()=>{console.log("Getting UI config");let e=await fetch(c?"".concat(c,"/litellm/.well-known/litellm-ui-config"):"/litellm/.well-known/litellm-ui-config"),t=await e.json();return console.log("jsonData in getUiConfig:",t),i(t.server_root_path,t.proxy_base_url),t},C=async()=>{let e=await fetch(c?"".concat(c,"/public/model_hub/info"):"/public/model_hub/info");return await e.json()},_=async()=>{let e=l?"".concat(l,"/openapi.json"):"/openapi.json",t=await fetch(e);return await t.json()},T=async e=>{try{let t=l?"".concat(l,"/get/litellm_model_cost_map"):"/get/litellm_model_cost_map",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("received litellm model cost data: ".concat(a)),a}catch(e){throw console.error("Failed to get model cost map:",e),e}},E=async e=>{try{let t=l?"".concat(l,"/reload/model_cost_map"):"/reload/model_cost_map",o=await fetch(t,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("Model cost map reload response: ".concat(a)),a}catch(e){throw console.error("Failed to reload model cost map:",e),e}},j=async(e,t)=>{try{let o=l?"".concat(l,"/schedule/model_cost_map_reload?hours=").concat(t):"/schedule/model_cost_map_reload?hours=".concat(t),a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}}),r=await a.json();return console.log("Schedule model cost map reload response: ".concat(r)),r}catch(e){throw console.error("Failed to schedule model cost map reload:",e),e}},S=async e=>{try{let t=l?"".concat(l,"/schedule/model_cost_map_reload"):"/schedule/model_cost_map_reload",o=await fetch(t,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}}),a=await o.json();return console.log("Cancel model cost map reload response: ".concat(a)),a}catch(e){throw console.error("Failed to cancel model cost map reload:",e),e}},v=async e=>{try{let t=l?"".concat(l,"/schedule/model_cost_map_reload/status"):"/schedule/model_cost_map_reload/status";console.log("Fetching status from URL:",t);let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){console.error("Status request failed with status: ".concat(o.status));let e=await o.text();throw console.error("Error response:",e),Error("HTTP ".concat(o.status,": ").concat(e))}let a=await o.json();return console.log("Model cost map reload status:",a),a}catch(e){throw console.error("Failed to get model cost map reload status:",e),e}},b=async(e,t)=>{try{let o=l?"".concat(l,"/model/new"):"/model/new",r=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!r.ok){let e=await r.text()||"Network response was not ok";throw a.ZP.error(e),Error(e)}let n=await r.json();return console.log("API Response:",n),a.ZP.destroy(),a.ZP.success("Model ".concat(t.model_name," created successfully"),2),n}catch(e){throw console.error("Failed to create key:",e),e}},N=async e=>{try{let t=l?"".concat(l,"/model/settings"):"/model/settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){console.error("Failed to get model settings:",e)}},F=async(e,t)=>{console.log("model_id in model delete call: ".concat(t));try{let o=l?"".concat(l,"/model/delete"):"/model/delete",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({id:t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},x=async(e,t)=>{if(console.log("budget_id in budget delete call: ".concat(t)),null!=e)try{let o=l?"".concat(l,"/budget/delete"):"/budget/delete",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({id:t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},P=async(e,t)=>{try{console.log("Form Values in budgetCreateCall:",t),console.log("Form Values after check:",t);let o=l?"".concat(l,"/budget/new"):"/budget/new",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},O=async(e,t)=>{try{console.log("Form Values in budgetUpdateCall:",t),console.log("Form Values after check:",t);let o=l?"".concat(l,"/budget/update"):"/budget/update",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},B=async(e,t)=>{try{let o=l?"".concat(l,"/invitation/new"):"/invitation/new",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},G=async(e,t)=>{try{console.log("Form Values in invitationCreateCall:",t),console.log("Form Values after check:",t);let o=l?"".concat(l,"/invitation/claim"):"/invitation/claim",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},J=async e=>{try{let t=l?"".concat(l,"/alerting/settings"):"/alerting/settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},U=async(e,t)=>{try{for(let e of(console.log("Form Values in keyCreateServiceAccountCall:",t),t.description&&(t.metadata||(t.metadata={}),t.metadata.description=t.description,delete t.description,t.metadata=JSON.stringify(t.metadata)),r.d))if(t[e]){console.log("formValues.".concat(e,":"),t[e]);try{t[e]=JSON.parse(t[e])}catch(t){throw Error("Failed to parse ".concat(e,": ")+t)}}console.log("Form Values after check:",t);let o=l?"".concat(l,"/key/service-account/generate"):"/key/service-account/generate",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error(e)}let n=await a.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},A=async(e,t,o)=>{try{for(let e of(console.log("Form Values in keyCreateCall:",o),o.description&&(o.metadata||(o.metadata={}),o.metadata.description=o.description,delete o.description,o.metadata=JSON.stringify(o.metadata)),r.d))if(o[e]){console.log("formValues.".concat(e,":"),o[e]);try{o[e]=JSON.parse(o[e])}catch(t){throw Error("Failed to parse ".concat(e,": ")+t)}}console.log("Form Values after check:",o);let a=l?"".concat(l,"/key/generate"):"/key/generate",n=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t,...o})});if(!n.ok){let e=await n.text();throw w(e),console.error("Error response from the server:",e),Error(e)}let c=await n.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},R=async(e,t,o)=>{try{if(console.log("Form Values in keyCreateCall:",o),o.description&&(o.metadata||(o.metadata={}),o.metadata.description=o.description,delete o.description,o.metadata=JSON.stringify(o.metadata)),o.auto_create_key=!1,o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}console.log("Form Values after check:",o);let a=l?"".concat(l,"/user/new"):"/user/new",r=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_id:t,...o})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),Error(e)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},I=async(e,t)=>{try{let o=l?"".concat(l,"/key/delete"):"/key/delete";console.log("in keyDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({keys:[t]})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},M=async(e,t)=>{try{let o=l?"".concat(l,"/user/delete"):"/user/delete";console.log("in userDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({user_ids:t})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete user(s):",e),e}},L=async(e,t)=>{try{let o=l?"".concat(l,"/team/delete"):"/team/delete";console.log("in teamDeleteCall:",t);let a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_ids:[t]})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete key:",e),e}},z=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,n=arguments.length>5&&void 0!==arguments[5]?arguments[5]:null,c=arguments.length>6&&void 0!==arguments[6]?arguments[6]:null,s=arguments.length>7&&void 0!==arguments[7]?arguments[7]:null,i=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,d=arguments.length>9&&void 0!==arguments[9]?arguments[9]:null;try{let p=l?"".concat(l,"/user/list"):"/user/list";console.log("in userListCall");let h=new URLSearchParams;if(t&&t.length>0){let e=t.join(",");h.append("user_ids",e)}o&&h.append("page",o.toString()),a&&h.append("page_size",a.toString()),r&&h.append("user_email",r),n&&h.append("role",n),c&&h.append("team",c),s&&h.append("sso_user_ids",s),i&&h.append("sort_by",i),d&&h.append("sort_order",d);let u=h.toString();u&&(p+="?".concat(u));let f=await fetch(p,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!f.ok){let e=await f.text();throw w(e),Error("Network response was not ok")}let m=await f.json();return console.log("/user/list API Response:",m),m}catch(e){throw console.error("Failed to create key:",e),e}},D=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4?arguments[4]:void 0,n=arguments.length>5?arguments[5]:void 0,c=arguments.length>6&&void 0!==arguments[6]&&arguments[6];console.log("userInfoCall: ".concat(t,", ").concat(o,", ").concat(a,", ").concat(r,", ").concat(n,", ").concat(c));try{let s;if(a){s=l?"".concat(l,"/user/list"):"/user/list";let e=new URLSearchParams;null!=r&&e.append("page",r.toString()),null!=n&&e.append("page_size",n.toString()),s+="?".concat(e.toString())}else s=l?"".concat(l,"/user/info"):"/user/info",("Admin"!==o&&"Admin Viewer"!==o||c)&&t&&(s+="?user_id=".concat(t));console.log("Requesting user data from:",s);let i=await fetch(s,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.text();throw w(e),Error("Network response was not ok")}let d=await i.json();return console.log("API Response:",d),d}catch(e){throw console.error("Failed to fetch user data:",e),e}},V=async(e,t)=>{try{let o=l?"".concat(l,"/team/info"):"/team/info";t&&(o="".concat(o,"?team_id=").concat(t)),console.log("in teamInfoCall");let a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},q=async function(e,t){let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;arguments.length>5&&void 0!==arguments[5]&&arguments[5],arguments.length>6&&void 0!==arguments[6]&&arguments[6],arguments.length>7&&void 0!==arguments[7]&&arguments[7],arguments.length>8&&void 0!==arguments[8]&&arguments[8];try{let n=l?"".concat(l,"/v2/team/list"):"/v2/team/list";console.log("in teamInfoCall");let c=new URLSearchParams;o&&c.append("user_id",o.toString()),t&&c.append("organization_id",t.toString()),a&&c.append("team_id",a.toString()),r&&c.append("team_alias",r.toString());let s=c.toString();s&&(n+="?".concat(s));let i=await fetch(n,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.text();throw w(e),Error("Network response was not ok")}let d=await i.json();return console.log("/v2/team/list API Response:",d),d}catch(e){throw console.error("Failed to create key:",e),e}},H=async function(e,t){let o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let n=l?"".concat(l,"/team/list"):"/team/list";console.log("in teamInfoCall");let c=new URLSearchParams;o&&c.append("user_id",o.toString()),t&&c.append("organization_id",t.toString()),a&&c.append("team_id",a.toString()),r&&c.append("team_alias",r.toString());let s=c.toString();s&&(n+="?".concat(s));let i=await fetch(n,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.text();throw w(e),Error("Network response was not ok")}let d=await i.json();return console.log("/team/list API Response:",d),d}catch(e){throw console.error("Failed to create key:",e),e}},Z=async e=>{try{let t=l?"".concat(l,"/team/available"):"/team/available";console.log("in availableTeamListCall");let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("/team/available_teams API Response:",a),a}catch(e){throw e}},Y=async e=>{try{let t=l?"".concat(l,"/organization/list"):"/organization/list",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},W=async(e,t)=>{try{let o=l?"".concat(l,"/organization/info"):"/organization/info";t&&(o="".concat(o,"?organization_id=").concat(t)),console.log("in teamInfoCall");let a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},K=async(e,t)=>{try{if(console.log("Form Values in organizationCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw console.error("Failed to parse metadata:",e),Error("Failed to parse metadata: "+e)}}let o=l?"".concat(l,"/organization/new"):"/organization/new",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},Q=async(e,t)=>{try{console.log("Form Values in organizationUpdateCall:",t);let o=l?"".concat(l,"/organization/update"):"/organization/update",a=await fetch(o,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update Team Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},X=async(e,t)=>{try{let o=l?"".concat(l,"/organization/delete"):"/organization/delete",a=await fetch(o,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_ids:[t]})});if(!a.ok){let e=await a.text();throw w(e),Error("Error deleting organization: ".concat(e))}return await a.json()}catch(e){throw console.error("Failed to delete organization:",e),e}},$=async(e,t)=>{try{let o=l?"".concat(l,"/utils/transform_request"):"/utils/transform_request",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},ee=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1;try{let r=l?"".concat(l,"/user/daily/activity"):"/user/daily/activity",c=new URLSearchParams;c.append("start_date",n(t)),c.append("end_date",n(o)),c.append("page_size","1000"),c.append("page",a.toString());let s=c.toString();s&&(r+="?".concat(s));let i=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.text();throw w(e),Error("Network response was not ok")}return await i.json()}catch(e){throw console.error("Failed to create key:",e),e}},et=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let c=l?"".concat(l,"/tag/daily/activity"):"/tag/daily/activity",s=new URLSearchParams;s.append("start_date",n(t)),s.append("end_date",n(o)),s.append("page_size","1000"),s.append("page",a.toString()),r&&s.append("tags",r.join(","));let i=s.toString();i&&(c+="?".concat(i));let d=await fetch(c,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!d.ok){let e=await d.text();throw w(e),Error("Network response was not ok")}return await d.json()}catch(e){throw console.error("Failed to create key:",e),e}},eo=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null;try{let c=l?"".concat(l,"/team/daily/activity"):"/team/daily/activity",s=new URLSearchParams;s.append("start_date",n(t)),s.append("end_date",n(o)),s.append("page_size","1000"),s.append("page",a.toString()),r&&s.append("team_ids",r.join(",")),s.append("exclude_team_ids","litellm-dashboard");let i=s.toString();i&&(c+="?".concat(i));let d=await fetch(c,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!d.ok){let e=await d.text();throw w(e),Error("Network response was not ok")}return await d.json()}catch(e){throw console.error("Failed to create key:",e),e}},ea=async e=>{try{let t=l?"".concat(l,"/global/spend"):"/global/spend",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},er=async e=>{try{let t=l?"".concat(l,"/onboarding/get_token"):"/onboarding/get_token";t+="?invite_link=".concat(e);let o=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},en=async(e,t,o,a)=>{let r=l?"".concat(l,"/onboarding/claim_token"):"/onboarding/claim_token";try{let n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({invitation_link:t,user_id:o,password:a})});if(!n.ok){let e=await n.text();throw w(e),Error("Network response was not ok")}let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to delete key:",e),e}},ec=async(e,t,o)=>{try{let a=l?"".concat(l,"/key/").concat(t,"/regenerate"):"/key/".concat(t,"/regenerate"),r=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}let n=await r.json();return console.log("Regenerate key Response:",n),n}catch(e){throw console.error("Failed to regenerate key:",e),e}},es=!1,el=null,ei=async(e,t,o)=>{try{console.log("modelInfoCall:",e,t,o);let r=l?"".concat(l,"/v2/model/info"):"/v2/model/info",n=new URLSearchParams;n.append("include_team_models","true"),n.toString()&&(r+="?".concat(n.toString()));let c=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw e+="error shown=".concat(es),es||(e.includes("No model list passed")&&(e="No Models Exist. Click Add Model to get started."),a.ZP.info(e,10),es=!0,el&&clearTimeout(el),el=setTimeout(()=>{es=!1},1e4)),Error("Network response was not ok")}let s=await c.json();return console.log("modelInfoCall:",s),s}catch(e){throw console.error("Failed to create key:",e),e}},ed=async(e,t)=>{try{let o=l?"".concat(l,"/v1/model/info"):"/v1/model/info";o+="?litellm_model_id=".concat(t);let a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok)throw await a.text(),Error("Network response was not ok");let r=await a.json();return console.log("modelInfoV1Call:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},ep=async()=>{let e=l?"".concat(l,"/public/model_hub"):"/public/model_hub";return(await fetch(e,{method:"GET",headers:{"Content-Type":"application/json"}})).json()},eh=async e=>{try{let t=l?"".concat(l,"/model_group/info"):"/model_group/info",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log("modelHubCall:",a),a}catch(e){throw console.error("Failed to create key:",e),e}},eu=async e=>{try{let t=l?"".concat(l,"/get/allowed_ips"):"/get/allowed_ips",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw Error("Network response was not ok: ".concat(e))}let a=await o.json();return console.log("getAllowedIPs:",a),a.data}catch(e){throw console.error("Failed to get allowed IPs:",e),e}},ew=async(e,t)=>{try{let o=l?"".concat(l,"/add/allowed_ip"):"/add/allowed_ip",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({ip:t})});if(!a.ok){let e=await a.text();throw Error("Network response was not ok: ".concat(e))}let r=await a.json();return console.log("addAllowedIP:",r),r}catch(e){throw console.error("Failed to add allowed IP:",e),e}},eg=async(e,t)=>{try{let o=l?"".concat(l,"/delete/allowed_ip"):"/delete/allowed_ip",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({ip:t})});if(!a.ok){let e=await a.text();throw Error("Network response was not ok: ".concat(e))}let r=await a.json();return console.log("deleteAllowedIP:",r),r}catch(e){throw console.error("Failed to delete allowed IP:",e),e}},ef=async(e,t,o,a,r,n,c,s)=>{try{let t=l?"".concat(l,"/model/metrics"):"/model/metrics";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(n,"&api_key=").concat(c,"&customer=").concat(s));let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},em=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/model/streaming_metrics"):"/model/streaming_metrics";t&&(r="".concat(r,"?_selected_model_group=").concat(t,"&startTime=").concat(o,"&endTime=").concat(a));let n=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!n.ok){let e=await n.text();throw w(e),Error("Network response was not ok")}return await n.json()}catch(e){throw console.error("Failed to create key:",e),e}},ey=async(e,t,o,a,r,n,c,s)=>{try{let t=l?"".concat(l,"/model/metrics/slow_responses"):"/model/metrics/slow_responses";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(n,"&api_key=").concat(c,"&customer=").concat(s));let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},ek=async(e,t,o,a,r,n,c,s)=>{try{let t=l?"".concat(l,"/model/metrics/exceptions"):"/model/metrics/exceptions";a&&(t="".concat(t,"?_selected_model_group=").concat(a,"&startTime=").concat(r,"&endTime=").concat(n,"&api_key=").concat(c,"&customer=").concat(s));let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to create key:",e),e}},eC=async(e,t)=>{try{let o=l?"".concat(l,"/model_hub/update_useful_links"):"/model_hub/update_useful_links",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({useful_links:t})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},e_=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,n=(arguments.length>5&&void 0!==arguments[5]&&arguments[5],arguments.length>6&&void 0!==arguments[6]&&arguments[6]);console.log("in /models calls, globalLitellmHeaderName",g);try{let t=l?"".concat(l,"/models"):"/models",o=new URLSearchParams;o.append("include_model_access_groups","True"),!0===a&&o.append("return_wildcard_routes","True"),!0===n&&o.append("only_model_access_groups","True"),r&&o.append("team_id",r.toString()),o.toString()&&(t+="?".concat(o.toString()));let c=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw w(e),Error("Network response was not ok")}return await c.json()}catch(e){throw console.error("Failed to create key:",e),e}},eT=async(e,t)=>{try{let o=l?"".concat(l,"/global/spend/logs"):"/global/spend/logs";console.log("in keySpendLogsCall:",o);let a=await fetch("".concat(o,"?api_key=").concat(t),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},eE=async e=>{try{let t=l?"".concat(l,"/global/spend/teams"):"/global/spend/teams";console.log("in teamSpendLogsCall:",t);let o=await fetch("".concat(t),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ej=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/global/spend/tags"):"/global/spend/tags";t&&o&&(r="".concat(r,"?start_date=").concat(t,"&end_date=").concat(o)),a&&(r+="".concat(r,"&tags=").concat(a.join(","))),console.log("in tagsSpendLogsCall:",r);let n=await fetch("".concat(r),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!n.ok)throw await n.text(),Error("Network response was not ok");let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to create key:",e),e}},eS=async e=>{try{let t=l?"".concat(l,"/global/spend/all_tag_names"):"/global/spend/all_tag_names";console.log("in global/spend/all_tag_names call",t);let o=await fetch("".concat(t),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},ev=async e=>{try{let t=l?"".concat(l,"/global/all_end_users"):"/global/all_end_users";console.log("in global/all_end_users call",t);let o=await fetch("".concat(t),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eb=async(e,t)=>{try{let o=l?"".concat(l,"/user/filter/ui"):"/user/filter/ui";t.get("user_email")&&(o+="?user_email=".concat(t.get("user_email"))),t.get("user_id")&&(o+="?user_id=".concat(t.get("user_id")));let a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to create key:",e),e}},eN=async(e,t,o,a,r,n)=>{try{console.log("user role in spend logs call: ".concat(o));let t=l?"".concat(l,"/spend/logs"):"/spend/logs";t="App Owner"==o?"".concat(t,"?user_id=").concat(a,"&start_date=").concat(r,"&end_date=").concat(n):"".concat(t,"?start_date=").concat(r,"&end_date=").concat(n);let c=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw w(e),Error("Network response was not ok")}let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to create key:",e),e}},eF=async(e,t,o,a,r,n,c,s,i,d,p,h)=>{try{let u=l?"".concat(l,"/spend/logs/ui"):"/spend/logs/ui",f=new URLSearchParams;t&&f.append("api_key",t),o&&f.append("team_id",o),a&&f.append("request_id",a),r&&f.append("start_date",r),n&&f.append("end_date",n),c&&f.append("page",c.toString()),s&&f.append("page_size",s.toString()),i&&f.append("user_id",i),d&&f.append("end_user",d),p&&f.append("status_filter",p),h&&f.append("model",h);let m=f.toString();m&&(u+="?".concat(m));let y=await fetch(u,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!y.ok){let e=await y.text();throw w(e),Error("Network response was not ok")}let k=await y.json();return console.log("Spend Logs Response:",k),k}catch(e){throw console.error("Failed to fetch spend logs:",e),e}},ex=async e=>{try{let t=l?"".concat(l,"/global/spend/logs"):"/global/spend/logs",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eP=async e=>{try{let t=l?"".concat(l,"/global/spend/keys?limit=5"):"/global/spend/keys?limit=5",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eO=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/global/spend/end_users"):"/global/spend/end_users",n="";n=t?JSON.stringify({api_key:t,startTime:o,endTime:a}):JSON.stringify({startTime:o,endTime:a});let c={method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:n},s=await fetch(r,c);if(!s.ok){let e=await s.text();throw w(e),Error("Network response was not ok")}let i=await s.json();return console.log(i),i}catch(e){throw console.error("Failed to create key:",e),e}},eB=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/global/spend/provider"):"/global/spend/provider";o&&a&&(r+="?start_date=".concat(o,"&end_date=").concat(a)),t&&(r+="&api_key=".concat(t));let n={method:"GET",headers:{[g]:"Bearer ".concat(e)}},c=await fetch(r,n);if(!c.ok){let e=await c.text();throw w(e),Error("Network response was not ok")}let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eG=async(e,t,o)=>{try{let a=l?"".concat(l,"/global/activity"):"/global/activity";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[g]:"Bearer ".concat(e)}},n=await fetch(a,r);if(!n.ok)throw await n.text(),Error("Network response was not ok");let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eJ=async(e,t,o)=>{try{let a=l?"".concat(l,"/global/activity/cache_hits"):"/global/activity/cache_hits";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[g]:"Bearer ".concat(e)}},n=await fetch(a,r);if(!n.ok)throw await n.text(),Error("Network response was not ok");let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eU=async(e,t,o)=>{try{let a=l?"".concat(l,"/global/activity/model"):"/global/activity/model";t&&o&&(a+="?start_date=".concat(t,"&end_date=").concat(o));let r={method:"GET",headers:{[g]:"Bearer ".concat(e)}},n=await fetch(a,r);if(!n.ok)throw await n.text(),Error("Network response was not ok");let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eA=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/global/activity/exceptions"):"/global/activity/exceptions";t&&o&&(r+="?start_date=".concat(t,"&end_date=").concat(o)),a&&(r+="&model_group=".concat(a));let n={method:"GET",headers:{[g]:"Bearer ".concat(e)}},c=await fetch(r,n);if(!c.ok)throw await c.text(),Error("Network response was not ok");let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eR=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/global/activity/exceptions/deployment"):"/global/activity/exceptions/deployment";t&&o&&(r+="?start_date=".concat(t,"&end_date=").concat(o)),a&&(r+="&model_group=".concat(a));let n={method:"GET",headers:{[g]:"Bearer ".concat(e)}},c=await fetch(r,n);if(!c.ok)throw await c.text(),Error("Network response was not ok");let s=await c.json();return console.log(s),s}catch(e){throw console.error("Failed to fetch spend data:",e),e}},eI=async e=>{try{let t=l?"".concat(l,"/global/spend/models?limit=5"):"/global/spend/models?limit=5",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to create key:",e),e}},eM=async(e,t)=>{try{let o=l?"".concat(l,"/v2/key/info"):"/v2/key/info",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({keys:t})});if(!a.ok){let e=await a.text();if(e.includes("Invalid proxy server token passed"))throw Error("Invalid proxy server token passed");throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},eL=async(e,t,o)=>{try{console.log("Sending model connection test request:",JSON.stringify(t));let r=l?"".concat(l,"/health/test_connection"):"/health/test_connection",n=await fetch(r,{method:"POST",headers:{"Content-Type":"application/json",[g]:"Bearer ".concat(e)},body:JSON.stringify({litellm_params:t,mode:o})}),c=n.headers.get("content-type");if(!c||!c.includes("application/json")){let e=await n.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(n.status,": ").concat(n.statusText,"). Check network tab for details."))}let s=await n.json();if(!n.ok||"error"===s.status){if("error"===s.status);else{var a;return{status:"error",message:(null===(a=s.error)||void 0===a?void 0:a.message)||"Connection test failed: ".concat(n.status," ").concat(n.statusText)}}}return s}catch(e){throw console.error("Model connection test error:",e),e}},ez=async(e,t)=>{try{console.log("entering keyInfoV1Call");let o=l?"".concat(l,"/key/info"):"/key/info";o="".concat(o,"?key=").concat(t);let r=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(console.log("response",r),!r.ok){let e=await r.text();w(e),a.ZP.error("Failed to fetch key info - "+e)}let n=await r.json();return console.log("data",n),n}catch(e){throw console.error("Failed to fetch key info:",e),e}},eD=async function(e,t,o,a,r,n,c,s){let i=arguments.length>8&&void 0!==arguments[8]?arguments[8]:null,d=arguments.length>9&&void 0!==arguments[9]?arguments[9]:null;try{let p=l?"".concat(l,"/key/list"):"/key/list";console.log("in keyListCall");let h=new URLSearchParams;o&&h.append("team_id",o.toString()),t&&h.append("organization_id",t.toString()),a&&h.append("key_alias",a),n&&h.append("key_hash",n),r&&h.append("user_id",r.toString()),c&&h.append("page",c.toString()),s&&h.append("size",s.toString()),i&&h.append("sort_by",i),d&&h.append("sort_order",d),h.append("return_full_object","true"),h.append("include_team_keys","true");let u=h.toString();u&&(p+="?".concat(u));let f=await fetch(p,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!f.ok){let e=await f.text();throw w(e),Error("Network response was not ok")}let m=await f.json();return console.log("/team/list API Response:",m),m}catch(e){throw console.error("Failed to create key:",e),e}},eV=async(e,t)=>{try{let o=l?"".concat(l,"/spend/users"):"/spend/users";console.log("in spendUsersCall:",o);let a=await fetch("".concat(o,"?user_id=").concat(t),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to get spend for user",e),e}},eq=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/user/request_model"):"/user/request_model",n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({models:[t],user_id:o,justification:a})});if(!n.ok){let e=await n.text();throw w(e),Error("Network response was not ok")}let c=await n.json();return console.log(c),c}catch(e){throw console.error("Failed to create key:",e),e}},eH=async e=>{try{let t=l?"".concat(l,"/user/get_requests"):"/user/get_requests";console.log("in userGetRequesedtModelsCall:",t);let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log(a),a}catch(e){throw console.error("Failed to get requested models:",e),e}},eZ=async(e,t,o)=>{try{let a=l?"".concat(l,"/user/daily/activity/aggregated"):"/user/daily/activity/aggregated",r=new URLSearchParams,n=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)};r.append("start_date",n(t)),r.append("end_date",n(o));let c=r.toString();c&&(a+="?".concat(c));let s=await fetch(a,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw w(e),Error("Network response was not ok")}return await s.json()}catch(e){throw console.error("Failed to fetch aggregated user daily activity:",e),e}},eY=async(e,t)=>{try{let o=l?"".concat(l,"/user/get_users?role=").concat(t):"/user/get_users?role=".concat(t);console.log("in userGetAllUsersCall:",o);let a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to get requested models:",e),e}},eW=async e=>{try{let t=l?"".concat(l,"/user/available_roles"):"/user/available_roles",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");let a=await o.json();return console.log("response from user/available_role",a),a}catch(e){throw e}},eK=async(e,t)=>{try{if(console.log("Form Values in teamCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let o=l?"".concat(l,"/team/new"):"/team/new",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eQ=async(e,t)=>{try{if(console.log("Form Values in credentialCreateCall:",t),t.metadata){console.log("formValues.metadata:",t.metadata);try{t.metadata=JSON.parse(t.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let o=l?"".concat(l,"/credentials"):"/credentials",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},eX=async e=>{try{let t=l?"".concat(l,"/credentials"):"/credentials";console.log("in credentialListCall");let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("/credentials API Response:",a),a}catch(e){throw console.error("Failed to create key:",e),e}},e$=async(e,t,o)=>{try{let a=l?"".concat(l,"/credentials"):"/credentials";t?a+="/by_name/".concat(t):o&&(a+="/by_model/".concat(o)),console.log("in credentialListCall");let r=await fetch(a,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}let n=await r.json();return console.log("/credentials API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},e0=async(e,t)=>{try{let o=l?"".concat(l,"/credentials/").concat(t):"/credentials/".concat(t);console.log("in credentialDeleteCall:",t);let a=await fetch(o,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to delete key:",e),e}},e1=async(e,t,o)=>{try{if(console.log("Form Values in credentialUpdateCall:",o),o.metadata){console.log("formValues.metadata:",o.metadata);try{o.metadata=JSON.parse(o.metadata)}catch(e){throw Error("Failed to parse metadata: "+e)}}let a=l?"".concat(l,"/credentials/").concat(t):"/credentials/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...o})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},e2=async(e,t)=>{try{if(console.log("Form Values in keyUpdateCall:",t),t.model_tpm_limit){console.log("formValues.model_tpm_limit:",t.model_tpm_limit);try{t.model_tpm_limit=JSON.parse(t.model_tpm_limit)}catch(e){throw Error("Failed to parse model_tpm_limit: "+e)}}if(t.model_rpm_limit){console.log("formValues.model_rpm_limit:",t.model_rpm_limit);try{t.model_rpm_limit=JSON.parse(t.model_rpm_limit)}catch(e){throw Error("Failed to parse model_rpm_limit: "+e)}}let o=l?"".concat(l,"/key/update"):"/key/update",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update key Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},e3=async(e,t)=>{try{console.log("Form Values in teamUpateCall:",t);let o=l?"".concat(l,"/team/update"):"/team/update",r=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),a.ZP.error("Failed to update team settings: "+e),Error(e)}let n=await r.json();return console.log("Update Team Response:",n),n}catch(e){throw console.error("Failed to update team:",e),e}},e4=async(e,t,o)=>{try{console.log("Form Values in modelUpateCall:",t);let a=l?"".concat(l,"/model/").concat(o,"/update"):"/model/".concat(o,"/update"),r=await fetch(a,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error update from the server:",e),Error("Network response was not ok")}let n=await r.json();return console.log("Update model Response:",n),n}catch(e){throw console.error("Failed to update model:",e),e}},e5=async(e,t)=>{try{console.log("Form Values in modelUpateCall:",t);let o=l?"".concat(l,"/model/update"):"/model/update",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error update from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("Update model Response:",r),r}catch(e){throw console.error("Failed to update model:",e),e}},e6=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let r=l?"".concat(l,"/team/member_add"):"/team/member_add",n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,member:o})});if(!n.ok){var a;let e=await n.text(),t={};try{t=JSON.parse(e)}catch(t){console.warn("Failed to parse error body as JSON:",e)}let o=(null==t?void 0:null===(a=t.detail)||void 0===a?void 0:a.error)||"Failed to add team member",r=Error(o);throw r.raw=t,r}let c=await n.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},e7=async(e,t,o,a,r)=>{try{console.log("Bulk add team members:",{teamId:t,members:o,maxBudgetInTeam:a});let c=l?"".concat(l,"/team/bulk_member_add"):"/team/bulk_member_add",s={team_id:t};r?s.all_users=!0:s.members=o,null!=a&&(s.max_budget_in_team=a);let i=await fetch(c,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(s)});if(!i.ok){var n;let e=await i.text(),t={};try{t=JSON.parse(e)}catch(t){console.warn("Failed to parse error body as JSON:",e)}let o=(null==t?void 0:null===(n=t.detail)||void 0===n?void 0:n.error)||"Failed to bulk add team members",a=Error(o);throw a.raw=t,a}let d=await i.json();return console.log("Bulk team member add API Response:",d),d}catch(e){throw console.error("Failed to bulk add team members:",e),e}},e9=async(e,t,o)=>{try{console.log("Form Values in teamMemberUpdateCall:",o);let r=l?"".concat(l,"/team/member_update"):"/team/member_update",n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,role:o.role,user_id:o.user_id})});if(!n.ok){var a;let e=await n.text(),t={};try{t=JSON.parse(e)}catch(t){console.warn("Failed to parse error body as JSON:",e)}let o=(null==t?void 0:null===(a=t.detail)||void 0===a?void 0:a.error)||"Failed to add team member",r=Error(o);throw r.raw=t,r}let c=await n.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to update team member:",e),e}},e8=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=l?"".concat(l,"/team/member_delete"):"/team/member_delete",r=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({team_id:t,...void 0!==o.user_email&&{user_email:o.user_email},...void 0!==o.user_id&&{user_id:o.user_id}})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create key:",e),e}},te=async(e,t,o)=>{try{console.log("Form Values in teamMemberAddCall:",o);let a=l?"".concat(l,"/organization/member_add"):"/organization/member_add",r=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,member:o})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),Error(e)}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to create organization member:",e),e}},tt=async(e,t,o)=>{try{console.log("Form Values in organizationMemberDeleteCall:",o);let a=l?"".concat(l,"/organization/member_delete"):"/organization/member_delete",r=await fetch(a,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,user_id:o})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to delete organization member:",e),e}},to=async(e,t,o)=>{try{console.log("Form Values in organizationMemberUpdateCall:",o);let a=l?"".concat(l,"/organization/member_update"):"/organization/member_update",r=await fetch(a,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({organization_id:t,...o})});if(!r.ok){let e=await r.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let n=await r.json();return console.log("API Response:",n),n}catch(e){throw console.error("Failed to update organization member:",e),e}},ta=async(e,t,o)=>{try{console.log("Form Values in userUpdateUserCall:",t);let a=l?"".concat(l,"/user/update"):"/user/update",r={...t};null!==o&&(r.user_role=o),r=JSON.stringify(r);let n=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:r});if(!n.ok){let e=await n.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let c=await n.json();return console.log("API Response:",c),c}catch(e){throw console.error("Failed to create key:",e),e}},tr=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]&&arguments[3];try{let r;console.log("Form Values in userUpdateUserCall:",t);let n=l?"".concat(l,"/user/bulk_update"):"/user/bulk_update";if(a)r=JSON.stringify({all_users:!0,user_updates:t});else if(o&&o.length>0){let e=[];for(let a of o)e.push({user_id:a,...t});r=JSON.stringify({users:e})}else throw Error("Must provide either userIds or set allUsers=true");let c=await fetch(n,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:r});if(!c.ok){let e=await c.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let s=await c.json();return console.log("API Response:",s),s}catch(e){throw console.error("Failed to create key:",e),e}},tn=async(e,t)=>{try{let o=l?"".concat(l,"/global/predict/spend/logs"):"/global/predict/spend/logs",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({data:t})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log(r),r}catch(e){throw console.error("Failed to create key:",e),e}},tc=async e=>{try{let t=l?"".concat(l,"/health/services?service=slack_budget_alerts"):"/health/services?service=slack_budget_alerts";console.log("Checking Slack Budget Alerts service health");let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error(e)}let r=await o.json();return a.ZP.success("Test Slack Alert worked - check your Slack!"),console.log("Service Health Response:",r),r}catch(e){throw console.error("Failed to perform health check:",e),e}},ts=async(e,t)=>{try{let o=l?"".concat(l,"/health/services?service=").concat(t):"/health/services?service=".concat(t);console.log("Checking Slack Budget Alerts service health");let a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error(e)}return await a.json()}catch(e){throw console.error("Failed to perform health check:",e),e}},tl=async e=>{try{let t=l?"".concat(l,"/budget/list"):"/budget/list",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},ti=async e=>{try{let t=l?"".concat(l,"/budget/settings"):"/budget/settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},td=async(e,t,o)=>{try{let t=l?"".concat(l,"/get/config/callbacks"):"/get/config/callbacks",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tp=async e=>{try{let t=l?"".concat(l,"/config/list?config_type=general_settings"):"/config/list?config_type=general_settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},th=async e=>{try{let t=l?"".concat(l,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tu=async(e,t)=>{try{let o=l?"".concat(l,"/config/field/info?field_name=").concat(t):"/config/field/info?field_name=".concat(t),a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok)throw await a.text(),Error("Network response was not ok");return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},tw=async(e,t,o)=>{try{let r=l?"".concat(l,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,field_value:o})});if(!n.ok){let e=await n.text();throw w(e),Error("Network response was not ok")}let c=await n.json();return a.ZP.success("Successfully updated value!"),c}catch(e){throw console.error("Failed to set callbacks:",e),e}},tg=async(e,t)=>{try{let o=l?"".concat(l,"/config/pass_through_endpoint"):"/config/pass_through_endpoint",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},tf=async(e,t,o)=>{try{let r=l?"".concat(l,"/config/field/update"):"/config/field/update",n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,field_value:o,config_type:"general_settings"})});if(!n.ok){let e=await n.text();throw w(e),Error("Network response was not ok")}let c=await n.json();return a.ZP.success("Successfully updated value!"),c}catch(e){throw console.error("Failed to set callbacks:",e),e}},tm=async(e,t)=>{try{let o=l?"".concat(l,"/config/field/delete"):"/config/field/delete",r=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({field_name:t,config_type:"general_settings"})});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}let n=await r.json();return a.ZP.success("Field reset on proxy"),n}catch(e){throw console.error("Failed to get callbacks:",e),e}},ty=async(e,t)=>{try{let o=l?"".concat(l,"/config/pass_through_endpoint?endpoint_id=").concat(t):"/config/pass_through_endpoint".concat(t),a=await fetch(o,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tk=async(e,t)=>{try{let o=l?"".concat(l,"/config/update"):"/config/update",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to set callbacks:",e),e}},tC=async e=>{try{let t=l?"".concat(l,"/health"):"/health",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to call /health:",e),e}},t_=async(e,t)=>{try{let o=l?"".concat(l,"/health?model=").concat(encodeURIComponent(t)):"/health?model=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw Error(e||"Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to call /health for model ".concat(t,":"),e),e}},tT=async e=>{try{let t=l?"".concat(l,"/cache/ping"):"/cache/ping",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error(e)}return await o.json()}catch(e){throw console.error("Failed to call /cache/ping:",e),e}},tE=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:100,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0;try{let n=l?"".concat(l,"/health/history"):"/health/history",c=new URLSearchParams;t&&c.append("model",t),o&&c.append("status_filter",o),c.append("limit",a.toString()),c.append("offset",r.toString()),c.toString()&&(n+="?".concat(c.toString()));let s=await fetch(n,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw w(e),Error(e)}return await s.json()}catch(e){throw console.error("Failed to call /health/history:",e),e}},tj=async e=>{try{let t=l?"".concat(l,"/health/latest"):"/health/latest",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error(e)}return await o.json()}catch(e){throw console.error("Failed to call /health/latest:",e),e}},tS=async e=>{try{console.log("Getting proxy UI settings"),console.log("proxyBaseUrl in getProxyUISettings:",l);let t=l?"".concat(l,"/sso/get/ui_settings"):"/sso/get/ui_settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw await o.text(),Error("Network response was not ok");return await o.json()}catch(e){throw console.error("Failed to get callbacks:",e),e}},tv=async e=>{try{let t=l?"".concat(l,"/v2/guardrails/list"):"/v2/guardrails/list",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get guardrails list:",e),e}},tb=async e=>{try{let t=l?"".concat(l,"/prompts/list"):"/prompts/list",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to get prompts list:",e),e}},tN=async(e,t)=>{try{let o=l?"".concat(l,"/prompts/").concat(t,"/info"):"/prompts/".concat(t,"/info"),a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to get prompt info:",e),e}},tF=async(e,t)=>{try{let o=l?"".concat(l,"/prompts"):"/prompts",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to create prompt:",e),e}},tx=async(e,t,o)=>{try{let a=l?"".concat(l,"/prompts/").concat(t):"/prompts/".concat(t),r=await fetch(a,{method:"PUT",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}return await r.json()}catch(e){throw console.error("Failed to update prompt:",e),e}},tP=async(e,t)=>{try{let o=l?"".concat(l,"/prompts/").concat(t):"/prompts/".concat(t),a=await fetch(o,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to delete prompt:",e),e}},tO=async(e,t)=>{try{let o=new FormData;o.append("file",t);let a=l?"".concat(l,"/utils/dotprompt_json_converter"):"/utils/dotprompt_json_converter",r=await fetch(a,{method:"POST",headers:{[g]:"Bearer ".concat(e)},body:o});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}return await r.json()}catch(e){throw console.error("Failed to convert prompt file:",e),e}},tB=async(e,t,o)=>{try{let a=l?"".concat(l,"/prompts/").concat(t):"/prompts/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}return await r.json()}catch(e){throw console.error("Failed to patch prompt:",e),e}},tG=async(e,t)=>{try{let o=l?"".concat(l,"/guardrails"):"/guardrails",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({guardrail:t})});if(!a.ok){let e=await a.text();throw w(e),Error(e)}let r=await a.json();return console.log("Create guardrail response:",r),r}catch(e){throw console.error("Failed to create guardrail:",e),e}},tJ=async(e,t,o)=>{try{let a=l?"".concat(l,"/spend/logs/ui/").concat(t,"?start_date=").concat(encodeURIComponent(o)):"/spend/logs/ui/".concat(t,"?start_date=").concat(encodeURIComponent(o));console.log("Fetching log details from:",a);let r=await fetch(a,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}let n=await r.json();return console.log("Fetched log details:",n),n}catch(e){throw console.error("Failed to fetch log details:",e),e}},tU=async e=>{try{let t=l?"".concat(l,"/get/internal_user_settings"):"/get/internal_user_settings";console.log("Fetching SSO settings from:",t);let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched SSO settings:",a),a}catch(e){throw console.error("Failed to fetch SSO settings:",e),e}},tA=async(e,t)=>{try{let o=l?"".concat(l,"/update/internal_user_settings"):"/update/internal_user_settings";console.log("Updating internal user settings:",t);let r=await fetch(o,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!r.ok){let e=await r.text();throw w(e),Error(e)}let n=await r.json();return console.log("Updated internal user settings:",n),a.ZP.success("Internal user settings updated successfully"),n}catch(e){throw console.error("Failed to update internal user settings:",e),e}},tR=async e=>{try{let t=l?"".concat(l,"/v1/mcp/server"):"/v1/mcp/server";console.log("Fetching MCP servers from:",t);let o=await fetch(t,{method:p.GET,headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched MCP servers:",a),a}catch(e){throw console.error("Failed to fetch MCP servers:",e),e}},tI=async e=>{try{let t=l?"".concat(l,"/v1/mcp/access_groups"):"/v1/mcp/access_groups";console.log("Fetching MCP access groups from:",t);let o=await fetch(t,{method:p.GET,headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched MCP access groups:",a),a.access_groups||[]}catch(e){throw console.error("Failed to fetch MCP access groups:",e),e}},tM=async(e,t)=>{try{console.log("Form Values in createMCPServer:",t);let o=l?"".concat(l,"/v1/mcp/server"):"/v1/mcp/server",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({...t})});if(!a.ok){let e=await a.text();throw w(e),console.error("Error response from the server:",e),Error("Network response was not ok")}let r=await a.json();return console.log("API Response:",r),r}catch(e){throw console.error("Failed to create key:",e),e}},tL=async(e,t)=>{try{let o=l?"".concat(l,"/v1/mcp/server"):"/v1/mcp/server",a=await fetch(o,{method:"PUT",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to update MCP server:",e),e}},tz=async(e,t)=>{try{let o=(l?"".concat(l):"")+"/v1/mcp/server/".concat(t);console.log("in deleteMCPServer:",t);let a=await fetch(o,{method:p.DELETE,headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}}catch(e){throw console.error("Failed to delete key:",e),e}},tD=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/mcp-rest/tools/list?server_id=").concat(t):"/mcp-rest/tools/list?server_id=".concat(t);console.log("Fetching MCP tools from:",r);let n={[g]:"Bearer ".concat(e),"Content-Type":"application/json"};a&&o?n["x-mcp-".concat(a,"-authorization")]=o:o&&(n[f]=o);let c=await fetch(r,{method:"GET",headers:n}),s=await c.json();if(console.log("Fetched MCP tools response:",s),!c.ok){if(s.error&&s.message)throw Error(s.message);throw Error("Failed to fetch MCP tools")}return s}catch(e){return console.error("Failed to fetch MCP tools:",e),{tools:[],error:"network_error",message:e instanceof Error?e.message:"Failed to fetch MCP tools"}}},tV=async(e,t,o,a,r)=>{try{let n=l?"".concat(l,"/mcp-rest/tools/call"):"/mcp-rest/tools/call";console.log("Calling MCP tool:",t,"with arguments:",o);let c={[g]:"Bearer ".concat(e),"Content-Type":"application/json"};r?c["x-mcp-".concat(r,"-authorization")]=a:c[f]=a;let s=await fetch(n,{method:"POST",headers:c,body:JSON.stringify({name:t,arguments:o})});if(!s.ok){let e="Network response was not ok",t=null,o=await s.text();try{let a=JSON.parse(o);a.detail?"string"==typeof a.detail?e=a.detail:"object"==typeof a.detail&&(e=a.detail.message||a.detail.error||"An error occurred",t=a.detail):e=a.message||a.error||e}catch(t){console.error("Failed to parse JSON error response:",t),o&&(e=o)}let a=Error(e);throw a.status=s.status,a.statusText=s.statusText,a.details=t,w(e),a}let i=await s.json();return console.log("MCP tool call response:",i),i}catch(e){throw console.error("Failed to call MCP tool:",e),console.error("Error type:",typeof e),e instanceof Error&&(console.error("Error message:",e.message),console.error("Error stack:",e.stack)),e}},tq=async(e,t)=>{try{let o=l?"".concat(l,"/tag/new"):"/tag/new",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();await w(e);return}return await a.json()}catch(e){throw console.error("Error creating tag:",e),e}},tH=async(e,t)=>{try{let o=l?"".concat(l,"/tag/update"):"/tag/update",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();await w(e);return}return await a.json()}catch(e){throw console.error("Error updating tag:",e),e}},tZ=async(e,t)=>{try{let o=l?"".concat(l,"/tag/info"):"/tag/info",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({names:t})});if(!a.ok){let e=await a.text();return await w(e),{}}return await a.json()}catch(e){throw console.error("Error getting tag info:",e),e}},tY=async e=>{try{let t=l?"".concat(l,"/tag/list"):"/tag/list",o=await fetch(t,{method:"GET",headers:{Authorization:"Bearer ".concat(e)}});if(!o.ok){let e=await o.text();return await w(e),{}}return await o.json()}catch(e){throw console.error("Error listing tags:",e),e}},tW=async(e,t)=>{try{let o=l?"".concat(l,"/tag/delete"):"/tag/delete",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({name:t})});if(!a.ok){let e=await a.text();await w(e);return}return await a.json()}catch(e){throw console.error("Error deleting tag:",e),e}},tK=async e=>{try{let t=l?"".concat(l,"/get/default_team_settings"):"/get/default_team_settings";console.log("Fetching default team settings from:",t);let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched default team settings:",a),a}catch(e){throw console.error("Failed to fetch default team settings:",e),e}},tQ=async(e,t)=>{try{let o=l?"".concat(l,"/update/default_team_settings"):"/update/default_team_settings";console.log("Updating default team settings:",t);let r=await fetch(o,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}let n=await r.json();return console.log("Updated default team settings:",n),a.ZP.success("Default team settings updated successfully"),n}catch(e){throw console.error("Failed to update default team settings:",e),e}},tX=async(e,t)=>{try{let o=l?"".concat(l,"/team/permissions_list?team_id=").concat(t):"/team/permissions_list?team_id=".concat(t),a=await fetch(o,{method:"GET",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log("Team permissions response:",r),r}catch(e){throw console.error("Failed to get team permissions:",e),e}},t$=async(e,t,o)=>{try{let a=l?"".concat(l,"/team/permissions_update"):"/team/permissions_update",r=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({team_id:t,team_member_permissions:o})});if(!r.ok){let e=await r.text();throw w(e),Error("Network response was not ok")}let n=await r.json();return console.log("Team permissions response:",n),n}catch(e){throw console.error("Failed to update team permissions:",e),e}},t0=async(e,t)=>{try{let o=l?"".concat(l,"/spend/logs/session/ui?session_id=").concat(encodeURIComponent(t)):"/spend/logs/session/ui?session_id=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to fetch session logs:",e),e}},t1=async(e,t)=>{try{let o=l?"".concat(l,"/vector_store/new"):"/vector_store/new",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to create vector store")}return await a.json()}catch(e){throw console.error("Error creating vector store:",e),e}},t2=async function(e){arguments.length>1&&void 0!==arguments[1]&&arguments[1],arguments.length>2&&void 0!==arguments[2]&&arguments[2];try{let t=l?"".concat(l,"/vector_store/list"):"/vector_store/list",o=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)}});if(!o.ok){let e=await o.json();throw Error(e.detail||"Failed to list vector stores")}return await o.json()}catch(e){throw console.error("Error listing vector stores:",e),e}},t3=async(e,t)=>{try{let o=l?"".concat(l,"/vector_store/delete"):"/vector_store/delete",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({vector_store_id:t})});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to delete vector store")}return await a.json()}catch(e){throw console.error("Error deleting vector store:",e),e}},t4=async(e,t)=>{try{let o=l?"".concat(l,"/vector_store/info"):"/vector_store/info",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify({vector_store_id:t})});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to get vector store info")}return await a.json()}catch(e){throw console.error("Error getting vector store info:",e),e}},t5=async(e,t)=>{try{let o=l?"".concat(l,"/vector_store/update"):"/vector_store/update",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",Authorization:"Bearer ".concat(e)},body:JSON.stringify(t)});if(!a.ok){let e=await a.json();throw Error(e.detail||"Failed to update vector store")}return await a.json()}catch(e){throw console.error("Error updating vector store:",e),e}},t6=async e=>{try{let t=l?"".concat(l,"/email/event_settings"):"/email/event_settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Failed to get email event settings")}let a=await o.json();return console.log("Email event settings response:",a),a}catch(e){throw console.error("Failed to get email event settings:",e),e}},t7=async(e,t)=>{try{let o=l?"".concat(l,"/email/event_settings"):"/email/event_settings",a=await fetch(o,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw w(e),Error("Failed to update email event settings")}let r=await a.json();return console.log("Update email event settings response:",r),r}catch(e){throw console.error("Failed to update email event settings:",e),e}},t9=async e=>{try{let t=l?"".concat(l,"/email/event_settings/reset"):"/email/event_settings/reset",o=await fetch(t,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Failed to reset email event settings")}let a=await o.json();return console.log("Reset email event settings response:",a),a}catch(e){throw console.error("Failed to reset email event settings:",e),e}},t8=async(e,t)=>{try{let o=l?"".concat(l,"/guardrails/").concat(t):"/guardrails/".concat(t),a=await fetch(o,{method:"DELETE",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error(e)}let r=await a.json();return console.log("Delete guardrail response:",r),r}catch(e){throw console.error("Failed to delete guardrail:",e),e}},oe=async e=>{try{let t=l?"".concat(l,"/guardrails/ui/add_guardrail_settings"):"/guardrails/ui/add_guardrail_settings",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Failed to get guardrail UI settings")}let a=await o.json();return console.log("Guardrail UI settings response:",a),a}catch(e){throw console.error("Failed to get guardrail UI settings:",e),e}},ot=async e=>{try{let t=l?"".concat(l,"/guardrails/ui/provider_specific_params"):"/guardrails/ui/provider_specific_params",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Failed to get guardrail provider specific parameters")}let a=await o.json();return console.log("Guardrail provider specific params response:",a),a}catch(e){throw console.error("Failed to get guardrail provider specific parameters:",e),e}},oo=async(e,t)=>{try{let o=l?"".concat(l,"/guardrails/").concat(t,"/info"):"/guardrails/".concat(t,"/info"),a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Failed to get guardrail info")}let r=await a.json();return console.log("Guardrail info response:",r),r}catch(e){throw console.error("Failed to get guardrail info:",e),e}},oa=async(e,t,o)=>{try{let a=l?"".concat(l,"/guardrails/").concat(t):"/guardrails/".concat(t),r=await fetch(a,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!r.ok){let e=await r.text();throw w(e),Error("Failed to update guardrail")}let n=await r.json();return console.log("Update guardrail response:",n),n}catch(e){throw console.error("Failed to update guardrail:",e),e}},or=async e=>{try{let t=l?"".concat(l,"/get/sso_settings"):"/get/sso_settings";console.log("Fetching SSO configuration from:",t);let o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}let a=await o.json();return console.log("Fetched SSO configuration:",a),a}catch(e){throw console.error("Failed to fetch SSO configuration:",e),e}},on=async(e,t)=>{try{let o=l?"".concat(l,"/update/sso_settings"):"/update/sso_settings";console.log("Updating SSO configuration:",t);let a=await fetch(o,{method:"PATCH",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(t)});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=await a.json();return console.log("Updated SSO configuration:",r),r}catch(e){throw console.error("Failed to update SSO configuration:",e),e}},oc=async(e,t,o,a,r)=>{try{let t=l?"".concat(l,"/audit"):"/audit",o=new URLSearchParams;a&&o.append("page",a.toString()),r&&o.append("page_size",r.toString());let n=o.toString();n&&(t+="?".concat(n));let c=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!c.ok){let e=await c.text();throw w(e),Error("Network response was not ok")}return await c.json()}catch(e){throw console.error("Failed to fetch audit logs:",e),e}},os=async e=>{try{let t=l?"".concat(l,"/user/available_users"):"/user/available_users",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e)}});if(!o.ok){if(404===o.status)return null;let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to fetch remaining users:",e),e}},ol=async(e,t,o)=>{try{let r=l?"".concat(l,"/config/pass_through_endpoint/").concat(encodeURIComponent(t)):"/config/pass_through_endpoint/".concat(encodeURIComponent(t)),n=await fetch(r,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify(o)});if(!n.ok){let e=await n.text();throw w(e),Error("Network response was not ok")}let c=await n.json();return a.ZP.success("Pass through endpoint updated successfully"),c}catch(e){throw console.error("Failed to update pass through endpoint:",e),e}},oi=async(e,t)=>{try{let o=l?"".concat(l,"/config/pass_through_endpoint?endpoint_id=").concat(encodeURIComponent(t)):"/config/pass_through_endpoint?endpoint_id=".concat(encodeURIComponent(t)),a=await fetch(o,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}let r=(await a.json()).endpoints;if(!r||0===r.length)throw Error("Pass through endpoint not found");return r[0]}catch(e){throw console.error("Failed to get pass through endpoint info:",e),e}},od=async(e,t)=>{try{let o=l?"".concat(l,"/config/callback/delete"):"/config/callback/delete",a=await fetch(o,{method:"POST",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({callback_name:t})});if(!a.ok){let e=await a.text();throw w(e),Error("Network response was not ok")}return await a.json()}catch(e){throw console.error("Failed to delete specific callback:",e),e}},op=async e=>{let t=d(),o=await fetch("".concat(t,"/v1/mcp/tools"),{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok)throw Error("HTTP error! status: ".concat(o.status));return await o.json()},oh=async(e,t)=>{try{console.log("Testing MCP connection with config:",JSON.stringify(t));let a=l?"".concat(l,"/mcp-rest/test/connection"):"/mcp-rest/test/connection",r=await fetch(a,{method:"POST",headers:{"Content-Type":"application/json",[g]:"Bearer ".concat(e)},body:JSON.stringify(t)}),n=r.headers.get("content-type");if(!n||!n.includes("application/json")){let e=await r.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(r.status,": ").concat(r.statusText,"). Check network tab for details."))}let c=await r.json();if(!r.ok||"error"===c.status){if("error"===c.status);else{var o;return{status:"error",message:(null===(o=c.error)||void 0===o?void 0:o.message)||"MCP connection test failed: ".concat(r.status," ").concat(r.statusText)}}}return c}catch(e){throw console.error("MCP connection test error:",e),e}},ou=async(e,t)=>{try{console.log("Testing MCP tools list with config:",JSON.stringify(t));let o=l?"".concat(l,"/mcp-rest/test/tools/list"):"/mcp-rest/test/tools/list",a=await fetch(o,{method:"POST",headers:{"Content-Type":"application/json",[g]:"Bearer ".concat(e)},body:JSON.stringify(t)}),r=a.headers.get("content-type");if(!r||!r.includes("application/json")){let e=await a.text();throw console.error("Received non-JSON response:",e),Error("Received non-JSON response (".concat(a.status,": ").concat(a.statusText,"). Check network tab for details."))}let n=await a.json();if((!a.ok||n.error)&&!n.error)return{tools:[],error:"request_failed",message:n.message||"MCP tools list failed: ".concat(a.status," ").concat(a.statusText)};return n}catch(e){throw console.error("MCP tools list test error:",e),e}},ow=async(e,t,o)=>{try{let a="".concat(d(),"/v1/vector_stores/").concat(t,"/search"),r=await fetch(a,{method:"POST",headers:{Authorization:"Bearer ".concat(e),"Content-Type":"application/json"},body:JSON.stringify({query:o})});if(!r.ok){let e=await r.text();return await w(e),null}return await r.json()}catch(e){throw console.error("Error testing vector store search:",e),e}},og=async function(e,t,o){let a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:50,n=arguments.length>5?arguments[5]:void 0;try{let c=l?"".concat(l,"/tag/user-agent/analytics"):"/tag/user-agent/analytics",s=new URLSearchParams,i=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)};s.append("start_date",i(t)),s.append("end_date",i(o)),s.append("page",a.toString()),s.append("page_size",r.toString()),n&&s.append("user_agent_filter",n);let d=s.toString();d&&(c+="?".concat(d));let p=await fetch(c,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!p.ok){let e=await p.text();throw w(e),Error("Network response was not ok")}return await p.json()}catch(e){throw console.error("Failed to fetch user agent analytics:",e),e}},of=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/tag/dau"):"/tag/dau",n=new URLSearchParams;n.append("end_date",(e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)})(t)),a&&a.length>0?a.forEach(e=>{n.append("tag_filters",e)}):o&&n.append("tag_filter",o);let c=n.toString();c&&(r+="?".concat(c));let s=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw w(e),Error("Network response was not ok")}return await s.json()}catch(e){throw console.error("Failed to fetch DAU:",e),e}},om=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/tag/wau"):"/tag/wau",n=new URLSearchParams;n.append("end_date",(e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)})(t)),a&&a.length>0?a.forEach(e=>{n.append("tag_filters",e)}):o&&n.append("tag_filter",o);let c=n.toString();c&&(r+="?".concat(c));let s=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw w(e),Error("Network response was not ok")}return await s.json()}catch(e){throw console.error("Failed to fetch WAU:",e),e}},oy=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/tag/mau"):"/tag/mau",n=new URLSearchParams;n.append("end_date",(e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)})(t)),a&&a.length>0?a.forEach(e=>{n.append("tag_filters",e)}):o&&n.append("tag_filter",o);let c=n.toString();c&&(r+="?".concat(c));let s=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw w(e),Error("Network response was not ok")}return await s.json()}catch(e){throw console.error("Failed to fetch MAU:",e),e}},ok=async e=>{try{let t=l?"".concat(l,"/tag/distinct"):"/tag/distinct",o=await fetch(t,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!o.ok){let e=await o.text();throw w(e),Error("Network response was not ok")}return await o.json()}catch(e){throw console.error("Failed to fetch distinct tags:",e),e}},oC=async(e,t,o,a)=>{try{let r=l?"".concat(l,"/tag/summary"):"/tag/summary",n=new URLSearchParams,c=e=>{let t=e.getFullYear(),o=String(e.getMonth()+1).padStart(2,"0"),a=String(e.getDate()).padStart(2,"0");return"".concat(t,"-").concat(o,"-").concat(a)};n.append("start_date",c(t)),n.append("end_date",c(o)),a&&a.length>0&&a.forEach(e=>{n.append("tag_filters",e)});let s=n.toString();s&&(r+="?".concat(s));let i=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!i.ok){let e=await i.text();throw w(e),Error("Network response was not ok")}return await i.json()}catch(e){throw console.error("Failed to fetch user agent summary:",e),e}},o_=async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:50,a=arguments.length>3?arguments[3]:void 0;try{let r=l?"".concat(l,"/tag/user-agent/per-user-analytics"):"/tag/user-agent/per-user-analytics",n=new URLSearchParams;n.append("page",t.toString()),n.append("page_size",o.toString()),a&&a.length>0&&a.forEach(e=>{n.append("tag_filters",e)});let c=n.toString();c&&(r+="?".concat(c));let s=await fetch(r,{method:"GET",headers:{[g]:"Bearer ".concat(e),"Content-Type":"application/json"}});if(!s.ok){let e=await s.text();throw w(e),Error("Network response was not ok")}return await s.json()}catch(e){throw console.error("Failed to fetch per-user analytics:",e),e}}},3914:function(e,t,o){function a(){let e=window.location.hostname,t=["Lax","Strict","None"];["/","/ui"].forEach(o=>{document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,";"),document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,"; domain=").concat(e,";"),t.forEach(t=>{let a="None"===t?" Secure;":"";document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,"; SameSite=").concat(t,";").concat(a),document.cookie="token=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=".concat(o,"; domain=").concat(e,"; SameSite=").concat(t,";").concat(a)})}),console.log("After clearing cookies:",document.cookie)}function r(e){let t=document.cookie.split("; ").find(t=>t.startsWith(e+"="));return t?t.split("=")[1]:null}o.d(t,{b:function(){return a},e:function(){return r}})}}]);
\ No newline at end of file
diff --git a/litellm/proxy/_experimental/out/_next/static/chunks/172-25e8f67ccf021150.js b/litellm/proxy/_experimental/out/_next/static/chunks/172-25e8f67ccf021150.js
deleted file mode 100644
index 28e153daca..0000000000
--- a/litellm/proxy/_experimental/out/_next/static/chunks/172-25e8f67ccf021150.js
+++ /dev/null
@@ -1 +0,0 @@
-"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[172],{57018:function(e,s,l){l.d(s,{Ct:function(){return t.Z},Dx:function(){return i.Z},Zb:function(){return a.Z},xv:function(){return n.Z},zx:function(){return r.Z}});var t=l(41649),r=l(20831),a=l(12514),n=l(84264),i=l(96761)},95704:function(e,s,l){l.d(s,{Dx:function(){return x.Z},RM:function(){return a.Z},SC:function(){return o.Z},Zb:function(){return t.Z},iA:function(){return r.Z},pj:function(){return n.Z},ss:function(){return i.Z},xs:function(){return c.Z},xv:function(){return d.Z}});var t=l(12514),r=l(21626),a=l(97214),n=l(28241),i=l(58834),c=l(69552),o=l(71876),d=l(84264),x=l(96761)},36172:function(e,s,l){l.d(s,{Z:function(){return D}});var t=l(57437),r=l(2265),a=l(99376),n=l(19250),i=l(8048),c=l(41649),o=l(20831),d=l(84264),x=l(89970),m=l(3810),u=l(23639),p=l(15424);let h=e=>e.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),g=e=>Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).map(e=>{let[s]=e;return s}),j=e=>"$".concat((1e6*e).toFixed(2)),b=e=>e>=1e6?"".concat((e/1e6).toFixed(1),"M"):e>=1e3?"".concat((e/1e3).toFixed(1),"K"):e.toString(),v=function(e,s){let l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=[{header:"Public Model Name",accessorKey:"model_group",enableSorting:!0,sortingFn:"alphanumeric",cell:e=>{let{row:l}=e,r=l.original;return(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,t.jsx)(d.Z,{className:"font-medium text-sm",children:r.model_group}),(0,t.jsx)(x.Z,{title:"Copy model name",children:(0,t.jsx)(u.Z,{onClick:()=>s(r.model_group),className:"cursor-pointer text-gray-500 hover:text-blue-500 text-xs"})})]}),(0,t.jsx)("div",{className:"md:hidden",children:(0,t.jsx)(d.Z,{className:"text-xs text-gray-600",children:r.providers.join(", ")})})]})}},{header:"Provider",accessorKey:"providers",enableSorting:!0,sortingFn:(e,s)=>{let l=e.original.providers.join(", "),t=s.original.providers.join(", ");return l.localeCompare(t)},cell:e=>{let{row:s}=e,l=s.original;return(0,t.jsxs)("div",{className:"flex flex-wrap gap-1",children:[l.providers.slice(0,2).map(e=>(0,t.jsx)(m.Z,{color:"blue",className:"text-xs",children:e},e)),l.providers.length>2&&(0,t.jsxs)(d.Z,{className:"text-xs text-gray-500",children:["+",l.providers.length-2]})]})},meta:{className:"hidden md:table-cell"}},{header:"Mode",accessorKey:"mode",enableSorting:!0,sortingFn:"alphanumeric",cell:e=>{let{row:s}=e,l=s.original;return l.mode?(0,t.jsx)(c.Z,{color:"green",size:"sm",children:l.mode}):(0,t.jsx)(d.Z,{className:"text-gray-500",children:"-"})},meta:{className:"hidden lg:table-cell"}},{header:"Tokens",accessorKey:"max_input_tokens",enableSorting:!0,sortingFn:(e,s)=>(e.original.max_input_tokens||0)+(e.original.max_output_tokens||0)-((s.original.max_input_tokens||0)+(s.original.max_output_tokens||0)),cell:e=>{let{row:s}=e,l=s.original;return(0,t.jsx)("div",{className:"space-y-1",children:(0,t.jsxs)(d.Z,{className:"text-xs",children:[l.max_input_tokens?b(l.max_input_tokens):"-"," / ",l.max_output_tokens?b(l.max_output_tokens):"-"]})})},meta:{className:"hidden lg:table-cell"}},{header:"Cost/1M",accessorKey:"input_cost_per_token",enableSorting:!0,sortingFn:(e,s)=>(e.original.input_cost_per_token||0)+(e.original.output_cost_per_token||0)-((s.original.input_cost_per_token||0)+(s.original.output_cost_per_token||0)),cell:e=>{let{row:s}=e,l=s.original;return(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsx)(d.Z,{className:"text-xs",children:l.input_cost_per_token?j(l.input_cost_per_token):"-"}),(0,t.jsx)(d.Z,{className:"text-xs text-gray-500",children:l.output_cost_per_token?j(l.output_cost_per_token):"-"})]})}},{header:"Features",accessorKey:"capabilities",enableSorting:!1,cell:e=>{let{row:s}=e,l=g(s.original),r=["green","blue","purple","orange","red","yellow"];return(0,t.jsx)("div",{className:"flex flex-wrap gap-1",children:0===l.length?(0,t.jsx)(d.Z,{className:"text-gray-500 text-xs",children:"-"}):l.map((e,s)=>(0,t.jsx)(c.Z,{color:r[s%r.length],size:"xs",children:h(e)},e))})}},{header:"Public",accessorKey:"is_public_model_group",enableSorting:!0,sortingFn:(e,s)=>(!0===e.original.is_public_model_group?1:0)-(!0===s.original.is_public_model_group?1:0),cell:e=>{let{row:s}=e;return!0===s.original.is_public_model_group?(0,t.jsx)(c.Z,{color:"green",size:"xs",children:"Yes"}):(0,t.jsx)(c.Z,{color:"gray",size:"xs",children:"No"})},meta:{className:"hidden md:table-cell"}},{header:"Details",id:"details",enableSorting:!1,cell:s=>{let{row:l}=s,r=l.original;return(0,t.jsxs)(o.Z,{size:"xs",variant:"secondary",onClick:()=>e(r),icon:p.Z,children:[(0,t.jsx)("span",{className:"hidden lg:inline",children:"Details"}),(0,t.jsx)("span",{className:"lg:hidden",children:"Info"})]})}}];return l?r.filter(e=>!("accessorKey"in e)||"is_public_model_group"!==e.accessorKey):r};var y=l(72162),N=l(91810),f=l(13634),_=l(42264),k=l(61994),w=l(73002),Z=l(82680),C=l(96761),S=l(12514),P=e=>{let{modelHubData:s,onFilteredDataChange:l,showFiltersCard:a=!0,className:n=""}=e,[i,c]=(0,r.useState)(""),[o,x]=(0,r.useState)(""),[m,u]=(0,r.useState)(""),[p,h]=(0,r.useState)(""),g=(0,r.useRef)([]),j=(0,r.useMemo)(()=>(null==s?void 0:s.filter(e=>{let s=e.model_group.toLowerCase().includes(i.toLowerCase()),l=""===o||e.providers.includes(o),t=""===m||e.mode===m,r=""===p||Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).some(e=>{let[s]=e;return s.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ")===p});return s&&l&&t&&r}))||[],[s,i,o,m,p]);(0,r.useEffect)(()=>{(j.length!==g.current.length||j.some((e,s)=>{var l;return e.model_group!==(null===(l=g.current[s])||void 0===l?void 0:l.model_group)}))&&(g.current=j,l(j))},[j,l]);let b=(0,t.jsxs)("div",{className:"flex flex-wrap gap-4 items-center",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Search Models:"}),(0,t.jsx)("input",{type:"text",placeholder:"Search model names...",value:i,onChange:e=>c(e.target.value),className:"border rounded px-3 py-2 w-64 h-10 text-sm"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Provider:"}),(0,t.jsxs)("select",{value:o,onChange:e=>x(e.target.value),className:"border rounded px-3 py-2 text-sm text-gray-600 w-40 h-10",children:[(0,t.jsx)("option",{value:"",className:"text-sm text-gray-600",children:"All Providers"}),s&&(e=>{let s=new Set;return e.forEach(e=>{e.providers.forEach(e=>s.add(e))}),Array.from(s)})(s).map(e=>(0,t.jsx)("option",{value:e,className:"text-sm text-gray-800",children:e},e))]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Mode:"}),(0,t.jsxs)("select",{value:m,onChange:e=>u(e.target.value),className:"border rounded px-3 py-2 text-sm text-gray-600 w-32 h-10",children:[(0,t.jsx)("option",{value:"",className:"text-sm text-gray-600",children:"All Modes"}),s&&(e=>{let s=new Set;return e.forEach(e=>{e.mode&&s.add(e.mode)}),Array.from(s)})(s).map(e=>(0,t.jsx)("option",{value:e,className:"text-sm text-gray-800",children:e},e))]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Features:"}),(0,t.jsxs)("select",{value:p,onChange:e=>h(e.target.value),className:"border rounded px-3 py-2 text-sm text-gray-600 w-48 h-10",children:[(0,t.jsx)("option",{value:"",className:"text-sm text-gray-600",children:"All Features"}),s&&(e=>{let s=new Set;return e.forEach(e=>{Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).forEach(e=>{let[l]=e,t=l.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ");s.add(t)})}),Array.from(s).sort()})(s).map(e=>(0,t.jsx)("option",{value:e,className:"text-sm text-gray-800",children:e},e))]})]}),(i||o||m||p)&&(0,t.jsx)("div",{className:"flex items-end",children:(0,t.jsx)("button",{onClick:()=>{c(""),x(""),u(""),h("")},className:"text-blue-600 hover:text-blue-800 text-sm underline h-10 flex items-center",children:"Clear Filters"})})]});return a?(0,t.jsx)(S.Z,{className:"mb-6 ".concat(n),children:b}):(0,t.jsx)("div",{className:n,children:b})};let{Step:M}=N.default;var L=e=>{let{visible:s,onClose:l,accessToken:a,modelHubData:i,onSuccess:o}=e,[x,m]=(0,r.useState)(0),[u,p]=(0,r.useState)(new Set),[h,g]=(0,r.useState)([]),[j,b]=(0,r.useState)(!1),[v]=f.Z.useForm(),y=()=>{m(0),p(new Set),g([]),v.resetFields(),l()},S=(e,s)=>{let l=new Set(u);s?l.add(e):l.delete(e),p(l)},L=e=>{e?p(new Set(h.map(e=>e.model_group))):p(new Set)},A=(0,r.useCallback)(e=>{g(e)},[]);(0,r.useEffect)(()=>{s&&i.length>0&&(g(i),p(new Set(i.filter(e=>!0===e.is_public_model_group).map(e=>e.model_group))))},[s,i]);let F=async()=>{if(0===u.size){_.ZP.error("Please select at least one model to make public");return}b(!0);try{let e=Array.from(u);await (0,n.makeModelGroupPublic)(a,e),_.ZP.success("Successfully made ".concat(e.length," model group(s) public!")),y(),o()}catch(e){console.error("Error making model groups public:",e),_.ZP.error("Failed to make model groups public. Please try again.")}finally{b(!1)}},U=()=>{let e=h.length>0&&h.every(e=>u.has(e.model_group)),s=u.size>0&&!e;return(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)(C.Z,{children:"Select Models to Make Public"}),(0,t.jsx)("div",{className:"flex items-center space-x-2",children:(0,t.jsxs)(k.Z,{checked:e,indeterminate:s,onChange:e=>L(e.target.checked),disabled:0===h.length,children:["Select All ",h.length>0&&"(".concat(h.length,")")]})})]}),(0,t.jsx)(d.Z,{className:"text-sm text-gray-600",children:"Select the models you want to be visible on the public model hub. Users will still require a valid API key to use these models."}),(0,t.jsx)(P,{modelHubData:i,onFilteredDataChange:A,showFiltersCard:!1,className:"border rounded-lg p-4 bg-gray-50"}),(0,t.jsx)("div",{className:"max-h-96 overflow-y-auto border rounded-lg p-4",children:(0,t.jsx)("div",{className:"space-y-3",children:0===h.length?(0,t.jsx)("div",{className:"text-center py-8 text-gray-500",children:(0,t.jsx)(d.Z,{children:"No models match the current filters."})}):h.map(e=>(0,t.jsxs)("div",{className:"flex items-center space-x-3 p-3 border rounded-lg hover:bg-gray-50",children:[(0,t.jsx)(k.Z,{checked:u.has(e.model_group),onChange:s=>S(e.model_group,s.target.checked)}),(0,t.jsxs)("div",{className:"flex-1",children:[(0,t.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,t.jsx)(d.Z,{className:"font-medium",children:e.model_group}),e.mode&&(0,t.jsx)(c.Z,{color:"green",size:"sm",children:e.mode})]}),(0,t.jsx)("div",{className:"flex flex-wrap gap-1 mt-1",children:e.providers.map(e=>(0,t.jsx)(c.Z,{color:"blue",size:"xs",children:e},e))})]})]},e.model_group))})}),u.size>0&&(0,t.jsx)("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-3",children:(0,t.jsxs)(d.Z,{className:"text-sm text-blue-800",children:[(0,t.jsx)("strong",{children:u.size})," model",1!==u.size?"s":""," selected"]})})]})},z=()=>(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsx)(C.Z,{children:"Confirm Making Models Public"}),(0,t.jsx)("div",{className:"bg-yellow-50 border border-yellow-200 rounded-lg p-4",children:(0,t.jsxs)(d.Z,{className:"text-sm text-yellow-800",children:[(0,t.jsx)("strong",{children:"Warning:"})," Once you make these models public, anyone who can go to the ",(0,t.jsx)("code",{children:"/ui/model_hub_table"})," will be able to know they exist on the proxy."]})}),(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsx)(d.Z,{className:"font-medium",children:"Models to be made public:"}),(0,t.jsx)("div",{className:"max-h-48 overflow-y-auto border rounded-lg p-3",children:(0,t.jsx)("div",{className:"space-y-2",children:Array.from(u).map(e=>{let s=i.find(s=>s.model_group===e);return(0,t.jsx)("div",{className:"flex items-center justify-between p-2 bg-gray-50 rounded",children:(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"font-medium",children:e}),s&&(0,t.jsx)("div",{className:"flex flex-wrap gap-1 mt-1",children:s.providers.map(e=>(0,t.jsx)(c.Z,{color:"blue",size:"xs",children:e},e))})]})},e)})})})]}),(0,t.jsx)("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-3",children:(0,t.jsxs)(d.Z,{className:"text-sm text-blue-800",children:["Total: ",(0,t.jsx)("strong",{children:u.size})," model",1!==u.size?"s":""," will be made public"]})})]});return(0,t.jsx)(Z.Z,{title:"Make Models Public",open:s,onCancel:y,footer:null,width:1200,maskClosable:!1,children:(0,t.jsxs)(f.Z,{form:v,layout:"vertical",children:[(0,t.jsxs)(N.default,{current:x,className:"mb-6",children:[(0,t.jsx)(M,{title:"Select Models"}),(0,t.jsx)(M,{title:"Confirm"})]}),(()=>{switch(x){case 0:return U();case 1:return z();default:return null}})(),(0,t.jsxs)("div",{className:"flex justify-between mt-6",children:[(0,t.jsx)(w.ZP,{onClick:0===x?y:()=>{1===x&&m(0)},children:0===x?"Cancel":"Previous"}),(0,t.jsxs)("div",{className:"flex space-x-2",children:[0===x&&(0,t.jsx)(w.ZP,{onClick:()=>{if(0===x){if(0===u.size){_.ZP.error("Please select at least one model to make public");return}m(1)}},disabled:0===u.size,children:"Next"}),1===x&&(0,t.jsx)(w.ZP,{onClick:F,loading:j,children:"Make Public"})]})]})]})})},A=l(69870),F=l(57018),U=l(17906),z=l(78867),E=l(20347),D=e=>{var s,l;let{accessToken:c,publicPage:o,premiumUser:d,userRole:x}=e,[m,u]=(0,r.useState)(!1),[p,h]=(0,r.useState)(null),[g,j]=(0,r.useState)(!0),[b,N]=(0,r.useState)(!1),[f,k]=(0,r.useState)(!1),[w,C]=(0,r.useState)(null),[S,M]=(0,r.useState)([]),[D,R]=(0,r.useState)(!1),H=(0,a.useRouter)(),O=(0,r.useRef)(null);(0,r.useEffect)(()=>{let e=async e=>{try{j(!0);let s=await (0,n.modelHubCall)(e);console.log("ModelHubData:",s),h(s.data),(0,n.getConfigFieldSetting)(e,"enable_public_model_hub").then(e=>{console.log("data: ".concat(JSON.stringify(e))),!0==e.field_value&&u(!0)}).catch(e=>{})}catch(e){console.error("There was an error fetching the model data",e)}finally{j(!1)}},s=async()=>{try{var e,s;j(!0);let l=await (0,n.modelHubPublicModelsCall)();console.log("ModelHubData:",l),console.log("First model structure:",l[0]),console.log("Model has model_group?",null===(e=l[0])||void 0===e?void 0:e.model_group),console.log("Model has providers?",null===(s=l[0])||void 0===s?void 0:s.providers),h(l),u(!0)}catch(e){console.error("There was an error fetching the public model data",e)}finally{j(!1)}};c?e(c):o&&s()},[c,o]);let T=()=>{c&&R(!0)},I=()=>{N(!1),k(!1),C(null)},K=()=>{N(!1),k(!1),C(null)},Y=e=>{navigator.clipboard.writeText(e),_.ZP.success("Copied to clipboard!")},W=e=>e.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),B=e=>Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).map(e=>{let[s]=e;return s}),V=e=>"$".concat((1e6*e).toFixed(2)),q=(0,r.useCallback)(e=>{M(e)},[]);return(console.log("publicPage: ",o),console.log("publicPageAllowed: ",m),o&&m)?(0,t.jsx)(y.Z,{accessToken:c}):(0,t.jsxs)("div",{className:"w-full mx-4 h-[75vh]",children:[!1==o?(0,t.jsxs)("div",{className:"w-full m-2 mt-2 p-8",children:[(0,t.jsxs)("div",{className:"flex justify-between items-center mb-6",children:[(0,t.jsxs)("div",{className:"flex flex-col items-start",children:[(0,t.jsx)(F.Dx,{className:"text-center",children:"Model Hub"}),(0,E.tY)(x||"")?(0,t.jsx)("p",{className:"text-sm text-gray-600",children:"Make models public for developers to know what models are available on the proxy."}):(0,t.jsx)("p",{className:"text-sm text-gray-600",children:"A list of all public model names personally available to you."})]}),(0,t.jsxs)("div",{className:"flex items-center space-x-4",children:[(0,t.jsx)(F.xv,{children:"Model Hub URL:"}),(0,t.jsxs)("div",{className:"flex items-center bg-gray-200 px-2 py-1 rounded",children:[(0,t.jsx)(F.xv,{className:"mr-2",children:"".concat((0,n.getProxyBaseUrl)(),"/ui/model_hub_table")}),(0,t.jsx)("button",{onClick:()=>Y("".concat((0,n.getProxyBaseUrl)(),"/ui/model_hub_table")),className:"p-1 hover:bg-gray-300 rounded transition-colors",title:"Copy URL",children:(0,t.jsx)(z.Z,{size:16,className:"text-gray-600"})})]}),!1==o&&(0,E.tY)(x||"")&&(0,t.jsx)(F.zx,{className:"ml-4",onClick:()=>T(),children:"Make Public"})]})]}),(0,E.tY)(x||"")&&(0,t.jsx)("div",{className:"mt-8 mb-2",children:(0,t.jsx)(A.Z,{accessToken:c,userRole:x})}),(0,t.jsxs)(F.Zb,{children:[(0,t.jsx)(P,{modelHubData:p||[],onFilteredDataChange:q}),(0,t.jsx)(i.C,{columns:v(e=>{C(e),N(!0)},Y,o),data:S,isLoading:g,table:O,defaultSorting:[{id:"model_group",desc:!1}]})]}),(0,t.jsx)("div",{className:"mt-4 text-center space-y-2",children:(0,t.jsxs)(F.xv,{className:"text-sm text-gray-600",children:["Showing ",S.length," of ",(null==p?void 0:p.length)||0," models"]})})]}):(0,t.jsxs)(F.Zb,{className:"mx-auto max-w-xl mt-10",children:[(0,t.jsx)(F.xv,{className:"text-xl text-center mb-2 text-black",children:"Public Model Hub not enabled."}),(0,t.jsx)("p",{className:"text-base text-center text-slate-800",children:"Ask your proxy admin to enable this on their Admin UI."})]}),(0,t.jsx)(Z.Z,{title:"Public Model Hub",width:600,visible:f,footer:null,onOk:I,onCancel:K,children:(0,t.jsxs)("div",{className:"pt-5 pb-5",children:[(0,t.jsxs)("div",{className:"flex justify-between mb-4",children:[(0,t.jsx)(F.xv,{className:"text-base mr-2",children:"Shareable Link:"}),(0,t.jsx)(F.xv,{className:"max-w-sm ml-2 bg-gray-200 pr-2 pl-2 pt-1 pb-1 text-center rounded",children:"".concat((0,n.getProxyBaseUrl)(),"/ui/model_hub_table")})]}),(0,t.jsx)("div",{className:"flex justify-end",children:(0,t.jsx)(F.zx,{onClick:()=>{H.replace("/model_hub_table?key=".concat(c))},children:"See Page"})})]})}),(0,t.jsx)(Z.Z,{title:(null==w?void 0:w.model_group)||"Model Details",width:1e3,visible:b,footer:null,onOk:I,onCancel:K,children:w&&(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"text-lg font-semibold mb-4",children:"Model Overview"}),(0,t.jsxs)("div",{className:"grid grid-cols-2 gap-4 mb-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Model Group:"}),(0,t.jsx)(F.xv,{children:w.model_group})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Mode:"}),(0,t.jsx)(F.xv,{children:w.mode||"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Providers:"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-1 mt-1",children:w.providers.map(e=>(0,t.jsx)(F.Ct,{color:"blue",children:e},e))})]})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"text-lg font-semibold mb-4",children:"Token & Cost Information"}),(0,t.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Max Input Tokens:"}),(0,t.jsx)(F.xv,{children:(null===(s=w.max_input_tokens)||void 0===s?void 0:s.toLocaleString())||"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Max Output Tokens:"}),(0,t.jsx)(F.xv,{children:(null===(l=w.max_output_tokens)||void 0===l?void 0:l.toLocaleString())||"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Input Cost per 1M Tokens:"}),(0,t.jsx)(F.xv,{children:w.input_cost_per_token?V(w.input_cost_per_token):"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Output Cost per 1M Tokens:"}),(0,t.jsx)(F.xv,{children:w.output_cost_per_token?V(w.output_cost_per_token):"Not specified"})]})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"text-lg font-semibold mb-4",children:"Capabilities"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-2",children:(()=>{let e=B(w),s=["green","blue","purple","orange","red","yellow"];return 0===e.length?(0,t.jsx)(F.xv,{className:"text-gray-500",children:"No special capabilities listed"}):e.map((e,l)=>(0,t.jsx)(F.Ct,{color:s[l%s.length],children:W(e)},e))})()})]}),(w.tpm||w.rpm)&&(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"text-lg font-semibold mb-4",children:"Rate Limits"}),(0,t.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[w.tpm&&(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Tokens per Minute:"}),(0,t.jsx)(F.xv,{children:w.tpm.toLocaleString()})]}),w.rpm&&(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"font-medium",children:"Requests per Minute:"}),(0,t.jsx)(F.xv,{children:w.rpm.toLocaleString()})]})]})]}),w.supported_openai_params&&(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"text-lg font-semibold mb-4",children:"Supported OpenAI Parameters"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-2",children:w.supported_openai_params.map(e=>(0,t.jsx)(F.Ct,{color:"green",children:e},e))})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(F.xv,{className:"text-lg font-semibold mb-4",children:"Usage Example"}),(0,t.jsx)(U.Z,{language:"python",className:"text-sm",children:'import openai\n\nclient = openai.OpenAI(\n    api_key="your_api_key",\n    base_url="http://0.0.0.0:4000"  # Your LiteLLM Proxy URL\n)\n\nresponse = client.chat.completions.create(\n    model="'.concat(w.model_group,'",\n    messages=[\n        {\n            "role": "user",\n            "content": "Hello, how are you?"\n        }\n    ]\n)\n\nprint(response.choices[0].message.content)')})]})]})}),(0,t.jsx)(L,{visible:D,onClose:()=>R(!1),accessToken:c||"",modelHubData:p||[],onSuccess:()=>{c&&(async()=>{try{let e=await (0,n.modelHubCall)(c);h(e.data)}catch(e){console.error("Error refreshing model data:",e)}})()}})]})}},69870:function(e,s,l){var t=l(57437),r=l(2265),a=l(82680),n=l(42264),i=l(86462),c=l(47686),o=l(77355),d=l(93416),x=l(74998),m=l(20347),u=l(19250),p=l(95704);s.Z=e=>{let{accessToken:s,userRole:l}=e,[h,g]=(0,r.useState)([]),[j,b]=(0,r.useState)({url:"",displayName:""}),[v,y]=(0,r.useState)(null),[N,f]=(0,r.useState)(!1),[_,k]=(0,r.useState)(!0),w=async()=>{if(s)try{f(!0);let e=await (0,u.getPublicModelHubInfo)();if(e&&e.useful_links){let s=e.useful_links||{},l=Object.entries(s).map((e,s)=>{let[l,t]=e;return{id:"".concat(s,"-").concat(l),displayName:l,url:t}});g(l)}else g([])}catch(e){console.error("Error fetching useful links:",e),g([])}finally{f(!1)}};if((0,r.useEffect)(()=>{w()},[s]),!(0,m.tY)(l||""))return null;let Z=async e=>{if(!s)return!1;try{let l={};return e.forEach(e=>{l[e.displayName]=e.url}),await (0,u.updateUsefulLinksCall)(s,l),a.Z.success({title:"Links Saved Successfully",content:(0,t.jsxs)("div",{className:"py-4",children:[(0,t.jsx)("p",{className:"text-gray-600 mb-4",children:"Your useful links have been saved and are now visible on the public model hub."}),(0,t.jsxs)("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-4",children:[(0,t.jsx)("p",{className:"text-sm text-blue-800 mb-2 font-medium",children:"View your updated model hub:"}),(0,t.jsx)("a",{href:"".concat((0,u.getProxyBaseUrl)(),"/ui/model_hub_table"),target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center text-blue-600 hover:text-blue-800 underline text-sm font-medium",children:"Open Public Model Hub →"})]})]}),width:500,okText:"Close",maskClosable:!0,keyboard:!0}),!0}catch(e){return console.error("Error saving links:",e),n.ZP.error("Failed to save links - ".concat(e)),!1}},C=async()=>{if(!j.url||!j.displayName)return;try{new URL(j.url)}catch(e){n.ZP.error("Please enter a valid URL");return}if(h.some(e=>e.displayName===j.displayName)){n.ZP.error("A link with this display name already exists");return}let e=[...h,{id:"".concat(Date.now(),"-").concat(j.displayName),displayName:j.displayName,url:j.url}];await Z(e)&&(g(e),b({url:"",displayName:""}),n.ZP.success("Link added successfully"))},S=e=>{y({...e})},P=async()=>{if(!v)return;try{new URL(v.url)}catch(e){n.ZP.error("Please enter a valid URL");return}if(h.some(e=>e.id!==v.id&&e.displayName===v.displayName)){n.ZP.error("A link with this display name already exists");return}let e=h.map(e=>e.id===v.id?v:e);await Z(e)&&(g(e),y(null),n.ZP.success("Link updated successfully"))},M=()=>{y(null)},L=async e=>{let s=h.filter(s=>s.id!==e);await Z(s)&&(g(s),n.ZP.success("Link deleted successfully"))},A=e=>{window.open(e,"_blank")};return(0,t.jsxs)(p.Zb,{className:"mb-6",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between cursor-pointer",onClick:()=>k(!_),children:[(0,t.jsxs)("div",{className:"flex flex-col",children:[(0,t.jsx)(p.Dx,{className:"mb-0",children:"Link Management"}),(0,t.jsx)("p",{className:"text-sm text-gray-500",children:"Manage the links that are displayed under 'Useful Links' on the public model hub."})]}),(0,t.jsx)("div",{className:"flex items-center",children:_?(0,t.jsx)(i.Z,{className:"w-5 h-5 text-gray-500"}):(0,t.jsx)(c.Z,{className:"w-5 h-5 text-gray-500"})})]}),_&&(0,t.jsxs)("div",{className:"mt-4",children:[(0,t.jsxs)("div",{className:"mb-6",children:[(0,t.jsx)(p.xv,{className:"text-sm font-medium text-gray-700 mb-2",children:"Add New Link"}),(0,t.jsxs)("div",{className:"grid grid-cols-3 gap-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-xs text-gray-500 mb-1",children:"URL"}),(0,t.jsx)("input",{type:"text",value:j.url,onChange:e=>b({...j,url:e.target.value}),placeholder:"https://example.com",className:"w-full px-3 py-2 border border-gray-300 rounded-md text-sm"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-xs text-gray-500 mb-1",children:"Display Name"}),(0,t.jsx)("input",{type:"text",value:j.displayName,onChange:e=>b({...j,displayName:e.target.value}),placeholder:"Friendly name",className:"w-full px-3 py-2 border border-gray-300 rounded-md text-sm"})]}),(0,t.jsx)("div",{className:"flex items-end",children:(0,t.jsxs)("button",{onClick:C,disabled:!j.url||!j.displayName,className:"flex items-center px-4 py-2 rounded-md text-sm ".concat(j.url&&j.displayName?"bg-green-600 text-white hover:bg-green-700":"bg-gray-300 text-gray-500 cursor-not-allowed"),children:[(0,t.jsx)(o.Z,{className:"w-4 h-4 mr-1"}),"Add Link"]})})]})]}),(0,t.jsx)(p.xv,{className:"text-sm font-medium text-gray-700 mb-2",children:"Manage Existing Links"}),(0,t.jsx)("div",{className:"rounded-lg custom-border relative",children:(0,t.jsx)("div",{className:"overflow-x-auto",children:(0,t.jsxs)(p.iA,{className:"[&_td]:py-0.5 [&_th]:py-1",children:[(0,t.jsx)(p.ss,{children:(0,t.jsxs)(p.SC,{children:[(0,t.jsx)(p.xs,{className:"py-1 h-8",children:"Display Name"}),(0,t.jsx)(p.xs,{className:"py-1 h-8",children:"URL"}),(0,t.jsx)(p.xs,{className:"py-1 h-8",children:"Actions"})]})}),(0,t.jsxs)(p.RM,{children:[h.map(e=>(0,t.jsx)(p.SC,{className:"h-8",children:v&&v.id===e.id?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(p.pj,{className:"py-0.5",children:(0,t.jsx)("input",{type:"text",value:v.displayName,onChange:e=>y({...v,displayName:e.target.value}),className:"w-full px-2 py-1 border border-gray-300 rounded-md text-sm"})}),(0,t.jsx)(p.pj,{className:"py-0.5",children:(0,t.jsx)("input",{type:"text",value:v.url,onChange:e=>y({...v,url:e.target.value}),className:"w-full px-2 py-1 border border-gray-300 rounded-md text-sm"})}),(0,t.jsx)(p.pj,{className:"py-0.5 whitespace-nowrap",children:(0,t.jsxs)("div",{className:"flex space-x-2",children:[(0,t.jsx)("button",{onClick:P,className:"text-xs bg-blue-50 text-blue-600 px-2 py-1 rounded hover:bg-blue-100",children:"Save"}),(0,t.jsx)("button",{onClick:M,className:"text-xs bg-gray-50 text-gray-600 px-2 py-1 rounded hover:bg-gray-100",children:"Cancel"})]})})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(p.pj,{className:"py-0.5 text-sm text-gray-900",children:e.displayName}),(0,t.jsx)(p.pj,{className:"py-0.5 text-sm text-gray-500",children:e.url}),(0,t.jsx)(p.pj,{className:"py-0.5 whitespace-nowrap",children:(0,t.jsxs)("div",{className:"flex space-x-2",children:[(0,t.jsx)("button",{onClick:()=>A(e.url),className:"text-xs bg-green-50 text-green-600 px-2 py-1 rounded hover:bg-green-100",children:"Use"}),(0,t.jsx)("button",{onClick:()=>S(e),className:"text-xs bg-blue-50 text-blue-600 px-2 py-1 rounded hover:bg-blue-100",children:(0,t.jsx)(d.Z,{className:"w-3 h-3"})}),(0,t.jsx)("button",{onClick:()=>L(e.id),className:"text-xs bg-red-50 text-red-600 px-2 py-1 rounded hover:bg-red-100",children:(0,t.jsx)(x.Z,{className:"w-3 h-3"})})]})})]})},e.id)),0===h.length&&(0,t.jsx)(p.SC,{children:(0,t.jsx)(p.pj,{colSpan:3,className:"py-0.5 text-sm text-gray-500 text-center",children:"No links added yet. Add a new link above."})})]})]})})})]})]})}},20347:function(e,s,l){l.d(s,{LQ:function(){return a},ZL:function(){return t},lo:function(){return r},tY:function(){return n}});let t=["Admin","Admin Viewer","proxy_admin","proxy_admin_viewer","org_admin"],r=["Internal User","Internal Viewer"],a=["Internal User","Admin"],n=e=>t.includes(e)}}]);
\ No newline at end of file
diff --git a/litellm/proxy/_experimental/out/_next/static/chunks/172-c602ad2ba592907b.js b/litellm/proxy/_experimental/out/_next/static/chunks/172-c602ad2ba592907b.js
new file mode 100644
index 0000000000..edc2b21376
--- /dev/null
+++ b/litellm/proxy/_experimental/out/_next/static/chunks/172-c602ad2ba592907b.js
@@ -0,0 +1 @@
+"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[172],{57018:function(e,s,l){l.d(s,{Ct:function(){return t.Z},Dx:function(){return i.Z},Zb:function(){return r.Z},xv:function(){return n.Z},zx:function(){return a.Z}});var t=l(41649),a=l(20831),r=l(12514),n=l(84264),i=l(96761)},95704:function(e,s,l){l.d(s,{Dx:function(){return x.Z},RM:function(){return r.Z},SC:function(){return o.Z},Zb:function(){return t.Z},iA:function(){return a.Z},pj:function(){return n.Z},ss:function(){return i.Z},xs:function(){return c.Z},xv:function(){return d.Z}});var t=l(12514),a=l(21626),r=l(97214),n=l(28241),i=l(58834),c=l(69552),o=l(71876),d=l(84264),x=l(96761)},36172:function(e,s,l){l.d(s,{Z:function(){return R}});var t=l(57437),a=l(2265),r=l(99376),n=l(19250),i=l(8048),c=l(41649),o=l(20831),d=l(84264),x=l(89970),m=l(3810),u=l(23639),p=l(15424);let h=e=>e.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),g=e=>Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).map(e=>{let[s]=e;return s}),j=e=>"$".concat((1e6*e).toFixed(2)),b=e=>e>=1e6?"".concat((e/1e6).toFixed(1),"M"):e>=1e3?"".concat((e/1e3).toFixed(1),"K"):e.toString(),v=function(e,s){let l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=[{header:"Public Model Name",accessorKey:"model_group",enableSorting:!0,sortingFn:"alphanumeric",cell:e=>{let{row:l}=e,a=l.original;return(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,t.jsx)(d.Z,{className:"font-medium text-sm",children:a.model_group}),(0,t.jsx)(x.Z,{title:"Copy model name",children:(0,t.jsx)(u.Z,{onClick:()=>s(a.model_group),className:"cursor-pointer text-gray-500 hover:text-blue-500 text-xs"})})]}),(0,t.jsx)("div",{className:"md:hidden",children:(0,t.jsx)(d.Z,{className:"text-xs text-gray-600",children:a.providers.join(", ")})})]})}},{header:"Provider",accessorKey:"providers",enableSorting:!0,sortingFn:(e,s)=>{let l=e.original.providers.join(", "),t=s.original.providers.join(", ");return l.localeCompare(t)},cell:e=>{let{row:s}=e,l=s.original;return(0,t.jsxs)("div",{className:"flex flex-wrap gap-1",children:[l.providers.slice(0,2).map(e=>(0,t.jsx)(m.Z,{color:"blue",className:"text-xs",children:e},e)),l.providers.length>2&&(0,t.jsxs)(d.Z,{className:"text-xs text-gray-500",children:["+",l.providers.length-2]})]})},meta:{className:"hidden md:table-cell"}},{header:"Mode",accessorKey:"mode",enableSorting:!0,sortingFn:"alphanumeric",cell:e=>{let{row:s}=e,l=s.original;return l.mode?(0,t.jsx)(c.Z,{color:"green",size:"sm",children:l.mode}):(0,t.jsx)(d.Z,{className:"text-gray-500",children:"-"})},meta:{className:"hidden lg:table-cell"}},{header:"Tokens",accessorKey:"max_input_tokens",enableSorting:!0,sortingFn:(e,s)=>(e.original.max_input_tokens||0)+(e.original.max_output_tokens||0)-((s.original.max_input_tokens||0)+(s.original.max_output_tokens||0)),cell:e=>{let{row:s}=e,l=s.original;return(0,t.jsx)("div",{className:"space-y-1",children:(0,t.jsxs)(d.Z,{className:"text-xs",children:[l.max_input_tokens?b(l.max_input_tokens):"-"," / ",l.max_output_tokens?b(l.max_output_tokens):"-"]})})},meta:{className:"hidden lg:table-cell"}},{header:"Cost/1M",accessorKey:"input_cost_per_token",enableSorting:!0,sortingFn:(e,s)=>(e.original.input_cost_per_token||0)+(e.original.output_cost_per_token||0)-((s.original.input_cost_per_token||0)+(s.original.output_cost_per_token||0)),cell:e=>{let{row:s}=e,l=s.original;return(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsx)(d.Z,{className:"text-xs",children:l.input_cost_per_token?j(l.input_cost_per_token):"-"}),(0,t.jsx)(d.Z,{className:"text-xs text-gray-500",children:l.output_cost_per_token?j(l.output_cost_per_token):"-"})]})}},{header:"Features",accessorKey:"capabilities",enableSorting:!1,cell:e=>{let{row:s}=e,l=g(s.original),a=["green","blue","purple","orange","red","yellow"];return(0,t.jsx)("div",{className:"flex flex-wrap gap-1",children:0===l.length?(0,t.jsx)(d.Z,{className:"text-gray-500 text-xs",children:"-"}):l.map((e,s)=>(0,t.jsx)(c.Z,{color:a[s%a.length],size:"xs",children:h(e)},e))})}},{header:"Public",accessorKey:"is_public_model_group",enableSorting:!0,sortingFn:(e,s)=>(!0===e.original.is_public_model_group?1:0)-(!0===s.original.is_public_model_group?1:0),cell:e=>{let{row:s}=e;return!0===s.original.is_public_model_group?(0,t.jsx)(c.Z,{color:"green",size:"xs",children:"Yes"}):(0,t.jsx)(c.Z,{color:"gray",size:"xs",children:"No"})},meta:{className:"hidden md:table-cell"}},{header:"Details",id:"details",enableSorting:!1,cell:s=>{let{row:l}=s,a=l.original;return(0,t.jsxs)(o.Z,{size:"xs",variant:"secondary",onClick:()=>e(a),icon:p.Z,children:[(0,t.jsx)("span",{className:"hidden lg:inline",children:"Details"}),(0,t.jsx)("span",{className:"lg:hidden",children:"Info"})]})}}];return l?a.filter(e=>!("accessorKey"in e)||"is_public_model_group"!==e.accessorKey):a};var f=l(72162),y=l(91810),N=l(13634),_=l(42264),k=l(61994),w=l(73002),Z=l(82680),C=l(96761),S=l(12514),M=e=>{let{modelHubData:s,onFilteredDataChange:l,showFiltersCard:r=!0,className:n=""}=e,[i,c]=(0,a.useState)(""),[o,x]=(0,a.useState)(""),[m,u]=(0,a.useState)(""),[p,h]=(0,a.useState)(""),g=(0,a.useRef)([]),j=(0,a.useMemo)(()=>(null==s?void 0:s.filter(e=>{let s=e.model_group.toLowerCase().includes(i.toLowerCase()),l=""===o||e.providers.includes(o),t=""===m||e.mode===m,a=""===p||Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).some(e=>{let[s]=e;return s.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ")===p});return s&&l&&t&&a}))||[],[s,i,o,m,p]);(0,a.useEffect)(()=>{(j.length!==g.current.length||j.some((e,s)=>{var l;return e.model_group!==(null===(l=g.current[s])||void 0===l?void 0:l.model_group)}))&&(g.current=j,l(j))},[j,l]);let b=(0,t.jsxs)("div",{className:"flex flex-wrap gap-4 items-center",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Search Models:"}),(0,t.jsx)("input",{type:"text",placeholder:"Search model names...",value:i,onChange:e=>c(e.target.value),className:"border rounded px-3 py-2 w-64 h-10 text-sm"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Provider:"}),(0,t.jsxs)("select",{value:o,onChange:e=>x(e.target.value),className:"border rounded px-3 py-2 text-sm text-gray-600 w-40 h-10",children:[(0,t.jsx)("option",{value:"",className:"text-sm text-gray-600",children:"All Providers"}),s&&(e=>{let s=new Set;return e.forEach(e=>{e.providers.forEach(e=>s.add(e))}),Array.from(s)})(s).map(e=>(0,t.jsx)("option",{value:e,className:"text-sm text-gray-800",children:e},e))]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Mode:"}),(0,t.jsxs)("select",{value:m,onChange:e=>u(e.target.value),className:"border rounded px-3 py-2 text-sm text-gray-600 w-32 h-10",children:[(0,t.jsx)("option",{value:"",className:"text-sm text-gray-600",children:"All Modes"}),s&&(e=>{let s=new Set;return e.forEach(e=>{e.mode&&s.add(e.mode)}),Array.from(s)})(s).map(e=>(0,t.jsx)("option",{value:e,className:"text-sm text-gray-800",children:e},e))]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"text-sm font-medium mb-2",children:"Features:"}),(0,t.jsxs)("select",{value:p,onChange:e=>h(e.target.value),className:"border rounded px-3 py-2 text-sm text-gray-600 w-48 h-10",children:[(0,t.jsx)("option",{value:"",className:"text-sm text-gray-600",children:"All Features"}),s&&(e=>{let s=new Set;return e.forEach(e=>{Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).forEach(e=>{let[l]=e,t=l.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ");s.add(t)})}),Array.from(s).sort()})(s).map(e=>(0,t.jsx)("option",{value:e,className:"text-sm text-gray-800",children:e},e))]})]}),(i||o||m||p)&&(0,t.jsx)("div",{className:"flex items-end",children:(0,t.jsx)("button",{onClick:()=>{c(""),x(""),u(""),h("")},className:"text-blue-600 hover:text-blue-800 text-sm underline h-10 flex items-center",children:"Clear Filters"})})]});return r?(0,t.jsx)(S.Z,{className:"mb-6 ".concat(n),children:b}):(0,t.jsx)("div",{className:n,children:b})},P=l(9114);let{Step:L}=y.default;var A=e=>{let{visible:s,onClose:l,accessToken:r,modelHubData:i,onSuccess:o}=e,[x,m]=(0,a.useState)(0),[u,p]=(0,a.useState)(new Set),[h,g]=(0,a.useState)([]),[j,b]=(0,a.useState)(!1),[v]=N.Z.useForm(),f=()=>{m(0),p(new Set),g([]),v.resetFields(),l()},S=(e,s)=>{let l=new Set(u);s?l.add(e):l.delete(e),p(l)},A=e=>{e?p(new Set(h.map(e=>e.model_group))):p(new Set)},F=(0,a.useCallback)(e=>{g(e)},[]);(0,a.useEffect)(()=>{s&&i.length>0&&(g(i),p(new Set(i.filter(e=>!0===e.is_public_model_group).map(e=>e.model_group))))},[s,i]);let U=async()=>{if(0===u.size){P.Z.fromBackend("Please select at least one model to make public");return}b(!0);try{let e=Array.from(u);await (0,n.makeModelGroupPublic)(r,e),_.ZP.success("Successfully made ".concat(e.length," model group(s) public!")),f(),o()}catch(e){console.error("Error making model groups public:",e),P.Z.fromBackend("Failed to make model groups public. Please try again.")}finally{b(!1)}},z=()=>{let e=h.length>0&&h.every(e=>u.has(e.model_group)),s=u.size>0&&!e;return(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)(C.Z,{children:"Select Models to Make Public"}),(0,t.jsx)("div",{className:"flex items-center space-x-2",children:(0,t.jsxs)(k.Z,{checked:e,indeterminate:s,onChange:e=>A(e.target.checked),disabled:0===h.length,children:["Select All ",h.length>0&&"(".concat(h.length,")")]})})]}),(0,t.jsx)(d.Z,{className:"text-sm text-gray-600",children:"Select the models you want to be visible on the public model hub. Users will still require a valid API key to use these models."}),(0,t.jsx)(M,{modelHubData:i,onFilteredDataChange:F,showFiltersCard:!1,className:"border rounded-lg p-4 bg-gray-50"}),(0,t.jsx)("div",{className:"max-h-96 overflow-y-auto border rounded-lg p-4",children:(0,t.jsx)("div",{className:"space-y-3",children:0===h.length?(0,t.jsx)("div",{className:"text-center py-8 text-gray-500",children:(0,t.jsx)(d.Z,{children:"No models match the current filters."})}):h.map(e=>(0,t.jsxs)("div",{className:"flex items-center space-x-3 p-3 border rounded-lg hover:bg-gray-50",children:[(0,t.jsx)(k.Z,{checked:u.has(e.model_group),onChange:s=>S(e.model_group,s.target.checked)}),(0,t.jsxs)("div",{className:"flex-1",children:[(0,t.jsxs)("div",{className:"flex items-center space-x-2",children:[(0,t.jsx)(d.Z,{className:"font-medium",children:e.model_group}),e.mode&&(0,t.jsx)(c.Z,{color:"green",size:"sm",children:e.mode})]}),(0,t.jsx)("div",{className:"flex flex-wrap gap-1 mt-1",children:e.providers.map(e=>(0,t.jsx)(c.Z,{color:"blue",size:"xs",children:e},e))})]})]},e.model_group))})}),u.size>0&&(0,t.jsx)("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-3",children:(0,t.jsxs)(d.Z,{className:"text-sm text-blue-800",children:[(0,t.jsx)("strong",{children:u.size})," model",1!==u.size?"s":""," selected"]})})]})},E=()=>(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsx)(C.Z,{children:"Confirm Making Models Public"}),(0,t.jsx)("div",{className:"bg-yellow-50 border border-yellow-200 rounded-lg p-4",children:(0,t.jsxs)(d.Z,{className:"text-sm text-yellow-800",children:[(0,t.jsx)("strong",{children:"Warning:"})," Once you make these models public, anyone who can go to the ",(0,t.jsx)("code",{children:"/ui/model_hub_table"})," will be able to know they exist on the proxy."]})}),(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsx)(d.Z,{className:"font-medium",children:"Models to be made public:"}),(0,t.jsx)("div",{className:"max-h-48 overflow-y-auto border rounded-lg p-3",children:(0,t.jsx)("div",{className:"space-y-2",children:Array.from(u).map(e=>{let s=i.find(s=>s.model_group===e);return(0,t.jsx)("div",{className:"flex items-center justify-between p-2 bg-gray-50 rounded",children:(0,t.jsxs)("div",{children:[(0,t.jsx)(d.Z,{className:"font-medium",children:e}),s&&(0,t.jsx)("div",{className:"flex flex-wrap gap-1 mt-1",children:s.providers.map(e=>(0,t.jsx)(c.Z,{color:"blue",size:"xs",children:e},e))})]})},e)})})})]}),(0,t.jsx)("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-3",children:(0,t.jsxs)(d.Z,{className:"text-sm text-blue-800",children:["Total: ",(0,t.jsx)("strong",{children:u.size})," model",1!==u.size?"s":""," will be made public"]})})]});return(0,t.jsx)(Z.Z,{title:"Make Models Public",open:s,onCancel:f,footer:null,width:1200,maskClosable:!1,children:(0,t.jsxs)(N.Z,{form:v,layout:"vertical",children:[(0,t.jsxs)(y.default,{current:x,className:"mb-6",children:[(0,t.jsx)(L,{title:"Select Models"}),(0,t.jsx)(L,{title:"Confirm"})]}),(()=>{switch(x){case 0:return z();case 1:return E();default:return null}})(),(0,t.jsxs)("div",{className:"flex justify-between mt-6",children:[(0,t.jsx)(w.ZP,{onClick:0===x?f:()=>{1===x&&m(0)},children:0===x?"Cancel":"Previous"}),(0,t.jsxs)("div",{className:"flex space-x-2",children:[0===x&&(0,t.jsx)(w.ZP,{onClick:()=>{if(0===x){if(0===u.size){P.Z.fromBackend("Please select at least one model to make public");return}m(1)}},disabled:0===u.size,children:"Next"}),1===x&&(0,t.jsx)(w.ZP,{onClick:U,loading:j,children:"Make Public"})]})]})]})})},F=l(69870),U=l(57018),z=l(17906),E=l(78867),D=l(20347),R=e=>{var s,l;let{accessToken:c,publicPage:o,premiumUser:d,userRole:x}=e,[m,u]=(0,a.useState)(!1),[p,h]=(0,a.useState)(null),[g,j]=(0,a.useState)(!0),[b,y]=(0,a.useState)(!1),[N,k]=(0,a.useState)(!1),[w,C]=(0,a.useState)(null),[S,P]=(0,a.useState)([]),[L,R]=(0,a.useState)(!1),H=(0,r.useRouter)(),O=(0,a.useRef)(null);(0,a.useEffect)(()=>{let e=async e=>{try{j(!0);let s=await (0,n.modelHubCall)(e);console.log("ModelHubData:",s),h(s.data),(0,n.getConfigFieldSetting)(e,"enable_public_model_hub").then(e=>{console.log("data: ".concat(JSON.stringify(e))),!0==e.field_value&&u(!0)}).catch(e=>{})}catch(e){console.error("There was an error fetching the model data",e)}finally{j(!1)}},s=async()=>{try{var e,s;j(!0);let l=await (0,n.modelHubPublicModelsCall)();console.log("ModelHubData:",l),console.log("First model structure:",l[0]),console.log("Model has model_group?",null===(e=l[0])||void 0===e?void 0:e.model_group),console.log("Model has providers?",null===(s=l[0])||void 0===s?void 0:s.providers),h(l),u(!0)}catch(e){console.error("There was an error fetching the public model data",e)}finally{j(!1)}};c?e(c):o&&s()},[c,o]);let T=()=>{c&&R(!0)},B=()=>{y(!1),k(!1),C(null)},I=()=>{y(!1),k(!1),C(null)},K=e=>{navigator.clipboard.writeText(e),_.ZP.success("Copied to clipboard!")},Y=e=>e.replace(/^supports_/,"").split("_").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),W=e=>Object.entries(e).filter(e=>{let[s,l]=e;return s.startsWith("supports_")&&!0===l}).map(e=>{let[s]=e;return s}),V=e=>"$".concat((1e6*e).toFixed(2)),q=(0,a.useCallback)(e=>{P(e)},[]);return(console.log("publicPage: ",o),console.log("publicPageAllowed: ",m),o&&m)?(0,t.jsx)(f.Z,{accessToken:c}):(0,t.jsxs)("div",{className:"w-full mx-4 h-[75vh]",children:[!1==o?(0,t.jsxs)("div",{className:"w-full m-2 mt-2 p-8",children:[(0,t.jsxs)("div",{className:"flex justify-between items-center mb-6",children:[(0,t.jsxs)("div",{className:"flex flex-col items-start",children:[(0,t.jsx)(U.Dx,{className:"text-center",children:"Model Hub"}),(0,D.tY)(x||"")?(0,t.jsx)("p",{className:"text-sm text-gray-600",children:"Make models public for developers to know what models are available on the proxy."}):(0,t.jsx)("p",{className:"text-sm text-gray-600",children:"A list of all public model names personally available to you."})]}),(0,t.jsxs)("div",{className:"flex items-center space-x-4",children:[(0,t.jsx)(U.xv,{children:"Model Hub URL:"}),(0,t.jsxs)("div",{className:"flex items-center bg-gray-200 px-2 py-1 rounded",children:[(0,t.jsx)(U.xv,{className:"mr-2",children:"".concat((0,n.getProxyBaseUrl)(),"/ui/model_hub_table")}),(0,t.jsx)("button",{onClick:()=>K("".concat((0,n.getProxyBaseUrl)(),"/ui/model_hub_table")),className:"p-1 hover:bg-gray-300 rounded transition-colors",title:"Copy URL",children:(0,t.jsx)(E.Z,{size:16,className:"text-gray-600"})})]}),!1==o&&(0,D.tY)(x||"")&&(0,t.jsx)(U.zx,{className:"ml-4",onClick:()=>T(),children:"Make Public"})]})]}),(0,D.tY)(x||"")&&(0,t.jsx)("div",{className:"mt-8 mb-2",children:(0,t.jsx)(F.Z,{accessToken:c,userRole:x})}),(0,t.jsxs)(U.Zb,{children:[(0,t.jsx)(M,{modelHubData:p||[],onFilteredDataChange:q}),(0,t.jsx)(i.C,{columns:v(e=>{C(e),y(!0)},K,o),data:S,isLoading:g,table:O,defaultSorting:[{id:"model_group",desc:!1}]})]}),(0,t.jsx)("div",{className:"mt-4 text-center space-y-2",children:(0,t.jsxs)(U.xv,{className:"text-sm text-gray-600",children:["Showing ",S.length," of ",(null==p?void 0:p.length)||0," models"]})})]}):(0,t.jsxs)(U.Zb,{className:"mx-auto max-w-xl mt-10",children:[(0,t.jsx)(U.xv,{className:"text-xl text-center mb-2 text-black",children:"Public Model Hub not enabled."}),(0,t.jsx)("p",{className:"text-base text-center text-slate-800",children:"Ask your proxy admin to enable this on their Admin UI."})]}),(0,t.jsx)(Z.Z,{title:"Public Model Hub",width:600,visible:N,footer:null,onOk:B,onCancel:I,children:(0,t.jsxs)("div",{className:"pt-5 pb-5",children:[(0,t.jsxs)("div",{className:"flex justify-between mb-4",children:[(0,t.jsx)(U.xv,{className:"text-base mr-2",children:"Shareable Link:"}),(0,t.jsx)(U.xv,{className:"max-w-sm ml-2 bg-gray-200 pr-2 pl-2 pt-1 pb-1 text-center rounded",children:"".concat((0,n.getProxyBaseUrl)(),"/ui/model_hub_table")})]}),(0,t.jsx)("div",{className:"flex justify-end",children:(0,t.jsx)(U.zx,{onClick:()=>{H.replace("/model_hub_table?key=".concat(c))},children:"See Page"})})]})}),(0,t.jsx)(Z.Z,{title:(null==w?void 0:w.model_group)||"Model Details",width:1e3,visible:b,footer:null,onOk:B,onCancel:I,children:w&&(0,t.jsxs)("div",{className:"space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"text-lg font-semibold mb-4",children:"Model Overview"}),(0,t.jsxs)("div",{className:"grid grid-cols-2 gap-4 mb-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Model Group:"}),(0,t.jsx)(U.xv,{children:w.model_group})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Mode:"}),(0,t.jsx)(U.xv,{children:w.mode||"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Providers:"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-1 mt-1",children:w.providers.map(e=>(0,t.jsx)(U.Ct,{color:"blue",children:e},e))})]})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"text-lg font-semibold mb-4",children:"Token & Cost Information"}),(0,t.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Max Input Tokens:"}),(0,t.jsx)(U.xv,{children:(null===(s=w.max_input_tokens)||void 0===s?void 0:s.toLocaleString())||"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Max Output Tokens:"}),(0,t.jsx)(U.xv,{children:(null===(l=w.max_output_tokens)||void 0===l?void 0:l.toLocaleString())||"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Input Cost per 1M Tokens:"}),(0,t.jsx)(U.xv,{children:w.input_cost_per_token?V(w.input_cost_per_token):"Not specified"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Output Cost per 1M Tokens:"}),(0,t.jsx)(U.xv,{children:w.output_cost_per_token?V(w.output_cost_per_token):"Not specified"})]})]})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"text-lg font-semibold mb-4",children:"Capabilities"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-2",children:(()=>{let e=W(w),s=["green","blue","purple","orange","red","yellow"];return 0===e.length?(0,t.jsx)(U.xv,{className:"text-gray-500",children:"No special capabilities listed"}):e.map((e,l)=>(0,t.jsx)(U.Ct,{color:s[l%s.length],children:Y(e)},e))})()})]}),(w.tpm||w.rpm)&&(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"text-lg font-semibold mb-4",children:"Rate Limits"}),(0,t.jsxs)("div",{className:"grid grid-cols-2 gap-4",children:[w.tpm&&(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Tokens per Minute:"}),(0,t.jsx)(U.xv,{children:w.tpm.toLocaleString()})]}),w.rpm&&(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"font-medium",children:"Requests per Minute:"}),(0,t.jsx)(U.xv,{children:w.rpm.toLocaleString()})]})]})]}),w.supported_openai_params&&(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"text-lg font-semibold mb-4",children:"Supported OpenAI Parameters"}),(0,t.jsx)("div",{className:"flex flex-wrap gap-2",children:w.supported_openai_params.map(e=>(0,t.jsx)(U.Ct,{color:"green",children:e},e))})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)(U.xv,{className:"text-lg font-semibold mb-4",children:"Usage Example"}),(0,t.jsx)(z.Z,{language:"python",className:"text-sm",children:'import openai\n\nclient = openai.OpenAI(\n    api_key="your_api_key",\n    base_url="http://0.0.0.0:4000"  # Your LiteLLM Proxy URL\n)\n\nresponse = client.chat.completions.create(\n    model="'.concat(w.model_group,'",\n    messages=[\n        {\n            "role": "user",\n            "content": "Hello, how are you?"\n        }\n    ]\n)\n\nprint(response.choices[0].message.content)')})]})]})}),(0,t.jsx)(A,{visible:L,onClose:()=>R(!1),accessToken:c||"",modelHubData:p||[],onSuccess:()=>{c&&(async()=>{try{let e=await (0,n.modelHubCall)(c);h(e.data)}catch(e){console.error("Error refreshing model data:",e)}})()}})]})}},69870:function(e,s,l){var t=l(57437),a=l(2265),r=l(82680),n=l(42264),i=l(86462),c=l(47686),o=l(77355),d=l(93416),x=l(74998),m=l(20347),u=l(19250),p=l(95704),h=l(9114);s.Z=e=>{let{accessToken:s,userRole:l}=e,[g,j]=(0,a.useState)([]),[b,v]=(0,a.useState)({url:"",displayName:""}),[f,y]=(0,a.useState)(null),[N,_]=(0,a.useState)(!1),[k,w]=(0,a.useState)(!0),Z=async()=>{if(s)try{_(!0);let e=await (0,u.getPublicModelHubInfo)();if(e&&e.useful_links){let s=e.useful_links||{},l=Object.entries(s).map((e,s)=>{let[l,t]=e;return{id:"".concat(s,"-").concat(l),displayName:l,url:t}});j(l)}else j([])}catch(e){console.error("Error fetching useful links:",e),j([])}finally{_(!1)}};if((0,a.useEffect)(()=>{Z()},[s]),!(0,m.tY)(l||""))return null;let C=async e=>{if(!s)return!1;try{let l={};return e.forEach(e=>{l[e.displayName]=e.url}),await (0,u.updateUsefulLinksCall)(s,l),r.Z.success({title:"Links Saved Successfully",content:(0,t.jsxs)("div",{className:"py-4",children:[(0,t.jsx)("p",{className:"text-gray-600 mb-4",children:"Your useful links have been saved and are now visible on the public model hub."}),(0,t.jsxs)("div",{className:"bg-blue-50 border border-blue-200 rounded-lg p-4",children:[(0,t.jsx)("p",{className:"text-sm text-blue-800 mb-2 font-medium",children:"View your updated model hub:"}),(0,t.jsx)("a",{href:"".concat((0,u.getProxyBaseUrl)(),"/ui/model_hub_table"),target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center text-blue-600 hover:text-blue-800 underline text-sm font-medium",children:"Open Public Model Hub →"})]})]}),width:500,okText:"Close",maskClosable:!0,keyboard:!0}),!0}catch(e){return console.error("Error saving links:",e),h.Z.fromBackend("Failed to save links - ".concat(e)),!1}},S=async()=>{if(!b.url||!b.displayName)return;try{new URL(b.url)}catch(e){h.Z.fromBackend("Please enter a valid URL");return}if(g.some(e=>e.displayName===b.displayName)){h.Z.fromBackend("A link with this display name already exists");return}let e=[...g,{id:"".concat(Date.now(),"-").concat(b.displayName),displayName:b.displayName,url:b.url}];await C(e)&&(j(e),v({url:"",displayName:""}),n.ZP.success("Link added successfully"))},M=e=>{y({...e})},P=async()=>{if(!f)return;try{new URL(f.url)}catch(e){h.Z.fromBackend("Please enter a valid URL");return}if(g.some(e=>e.id!==f.id&&e.displayName===f.displayName)){h.Z.fromBackend("A link with this display name already exists");return}let e=g.map(e=>e.id===f.id?f:e);await C(e)&&(j(e),y(null),n.ZP.success("Link updated successfully"))},L=()=>{y(null)},A=async e=>{let s=g.filter(s=>s.id!==e);await C(s)&&(j(s),n.ZP.success("Link deleted successfully"))},F=e=>{window.open(e,"_blank")};return(0,t.jsxs)(p.Zb,{className:"mb-6",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between cursor-pointer",onClick:()=>w(!k),children:[(0,t.jsxs)("div",{className:"flex flex-col",children:[(0,t.jsx)(p.Dx,{className:"mb-0",children:"Link Management"}),(0,t.jsx)("p",{className:"text-sm text-gray-500",children:"Manage the links that are displayed under 'Useful Links' on the public model hub."})]}),(0,t.jsx)("div",{className:"flex items-center",children:k?(0,t.jsx)(i.Z,{className:"w-5 h-5 text-gray-500"}):(0,t.jsx)(c.Z,{className:"w-5 h-5 text-gray-500"})})]}),k&&(0,t.jsxs)("div",{className:"mt-4",children:[(0,t.jsxs)("div",{className:"mb-6",children:[(0,t.jsx)(p.xv,{className:"text-sm font-medium text-gray-700 mb-2",children:"Add New Link"}),(0,t.jsxs)("div",{className:"grid grid-cols-3 gap-4",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-xs text-gray-500 mb-1",children:"URL"}),(0,t.jsx)("input",{type:"text",value:b.url,onChange:e=>v({...b,url:e.target.value}),placeholder:"https://example.com",className:"w-full px-3 py-2 border border-gray-300 rounded-md text-sm"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("label",{className:"block text-xs text-gray-500 mb-1",children:"Display Name"}),(0,t.jsx)("input",{type:"text",value:b.displayName,onChange:e=>v({...b,displayName:e.target.value}),placeholder:"Friendly name",className:"w-full px-3 py-2 border border-gray-300 rounded-md text-sm"})]}),(0,t.jsx)("div",{className:"flex items-end",children:(0,t.jsxs)("button",{onClick:S,disabled:!b.url||!b.displayName,className:"flex items-center px-4 py-2 rounded-md text-sm ".concat(b.url&&b.displayName?"bg-green-600 text-white hover:bg-green-700":"bg-gray-300 text-gray-500 cursor-not-allowed"),children:[(0,t.jsx)(o.Z,{className:"w-4 h-4 mr-1"}),"Add Link"]})})]})]}),(0,t.jsx)(p.xv,{className:"text-sm font-medium text-gray-700 mb-2",children:"Manage Existing Links"}),(0,t.jsx)("div",{className:"rounded-lg custom-border relative",children:(0,t.jsx)("div",{className:"overflow-x-auto",children:(0,t.jsxs)(p.iA,{className:"[&_td]:py-0.5 [&_th]:py-1",children:[(0,t.jsx)(p.ss,{children:(0,t.jsxs)(p.SC,{children:[(0,t.jsx)(p.xs,{className:"py-1 h-8",children:"Display Name"}),(0,t.jsx)(p.xs,{className:"py-1 h-8",children:"URL"}),(0,t.jsx)(p.xs,{className:"py-1 h-8",children:"Actions"})]})}),(0,t.jsxs)(p.RM,{children:[g.map(e=>(0,t.jsx)(p.SC,{className:"h-8",children:f&&f.id===e.id?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(p.pj,{className:"py-0.5",children:(0,t.jsx)("input",{type:"text",value:f.displayName,onChange:e=>y({...f,displayName:e.target.value}),className:"w-full px-2 py-1 border border-gray-300 rounded-md text-sm"})}),(0,t.jsx)(p.pj,{className:"py-0.5",children:(0,t.jsx)("input",{type:"text",value:f.url,onChange:e=>y({...f,url:e.target.value}),className:"w-full px-2 py-1 border border-gray-300 rounded-md text-sm"})}),(0,t.jsx)(p.pj,{className:"py-0.5 whitespace-nowrap",children:(0,t.jsxs)("div",{className:"flex space-x-2",children:[(0,t.jsx)("button",{onClick:P,className:"text-xs bg-blue-50 text-blue-600 px-2 py-1 rounded hover:bg-blue-100",children:"Save"}),(0,t.jsx)("button",{onClick:L,className:"text-xs bg-gray-50 text-gray-600 px-2 py-1 rounded hover:bg-gray-100",children:"Cancel"})]})})]}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(p.pj,{className:"py-0.5 text-sm text-gray-900",children:e.displayName}),(0,t.jsx)(p.pj,{className:"py-0.5 text-sm text-gray-500",children:e.url}),(0,t.jsx)(p.pj,{className:"py-0.5 whitespace-nowrap",children:(0,t.jsxs)("div",{className:"flex space-x-2",children:[(0,t.jsx)("button",{onClick:()=>F(e.url),className:"text-xs bg-green-50 text-green-600 px-2 py-1 rounded hover:bg-green-100",children:"Use"}),(0,t.jsx)("button",{onClick:()=>M(e),className:"text-xs bg-blue-50 text-blue-600 px-2 py-1 rounded hover:bg-blue-100",children:(0,t.jsx)(d.Z,{className:"w-3 h-3"})}),(0,t.jsx)("button",{onClick:()=>A(e.id),className:"text-xs bg-red-50 text-red-600 px-2 py-1 rounded hover:bg-red-100",children:(0,t.jsx)(x.Z,{className:"w-3 h-3"})})]})})]})},e.id)),0===g.length&&(0,t.jsx)(p.SC,{children:(0,t.jsx)(p.pj,{colSpan:3,className:"py-0.5 text-sm text-gray-500 text-center",children:"No links added yet. Add a new link above."})})]})]})})})]})]})}},20347:function(e,s,l){l.d(s,{LQ:function(){return r},ZL:function(){return t},lo:function(){return a},tY:function(){return n}});let t=["Admin","Admin Viewer","proxy_admin","proxy_admin_viewer","org_admin"],a=["Internal User","Internal Viewer"],r=["Internal User","Admin"],n=e=>t.includes(e)}}]);
\ No newline at end of file
diff --git a/litellm/proxy/_experimental/out/_next/static/chunks/50-d0da2dd7acce2eb9.js b/litellm/proxy/_experimental/out/_next/static/chunks/50-d0da2dd7acce2eb9.js
new file mode 100644
index 0000000000..afbc623135
--- /dev/null
+++ b/litellm/proxy/_experimental/out/_next/static/chunks/50-d0da2dd7acce2eb9.js
@@ -0,0 +1 @@
+(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[50],{31373:function(e,t,n){"use strict";n.d(t,{iN:function(){return h},R_:function(){return d},EV:function(){return g},ez:function(){return f}});var r=n(82082),o=n(96021),a=[{index:7,opacity:.15},{index:6,opacity:.25},{index:5,opacity:.3},{index:5,opacity:.45},{index:5,opacity:.65},{index:5,opacity:.85},{index:4,opacity:.9},{index:3,opacity:.95},{index:2,opacity:.97},{index:1,opacity:.98}];function i(e){var t=e.r,n=e.g,o=e.b,a=(0,r.py)(t,n,o);return{h:360*a.h,s:a.s,v:a.v}}function c(e){var t=e.r,n=e.g,o=e.b;return"#".concat((0,r.vq)(t,n,o,!1))}function l(e,t,n){var r;return(r=Math.round(e.h)>=60&&240>=Math.round(e.h)?n?Math.round(e.h)-2*t:Math.round(e.h)+2*t:n?Math.round(e.h)+2*t:Math.round(e.h)-2*t)<0?r+=360:r>=360&&(r-=360),r}function s(e,t,n){var r;return 0===e.h&&0===e.s?e.s:((r=n?e.s-.16*t:4===t?e.s+.16:e.s+.05*t)>1&&(r=1),n&&5===t&&r>.1&&(r=.1),r<.06&&(r=.06),Number(r.toFixed(2)))}function u(e,t,n){var r;return(r=n?e.v+.05*t:e.v-.15*t)>1&&(r=1),Number(r.toFixed(2))}function d(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=[],r=(0,o.uA)(e),d=5;d>0;d-=1){var f=i(r),p=c((0,o.uA)({h:l(f,d,!0),s:s(f,d,!0),v:u(f,d,!0)}));n.push(p)}n.push(c(r));for(var m=1;m<=4;m+=1){var g=i(r),h=c((0,o.uA)({h:l(g,m),s:s(g,m),v:u(g,m)}));n.push(h)}return"dark"===t.theme?a.map(function(e){var r,a,i,l=e.index,s=e.opacity;return c((r=(0,o.uA)(t.backgroundColor||"#141414"),a=(0,o.uA)(n[l]),i=100*s/100,{r:(a.r-r.r)*i+r.r,g:(a.g-r.g)*i+r.g,b:(a.b-r.b)*i+r.b}))}):n}var f={red:"#F5222D",volcano:"#FA541C",orange:"#FA8C16",gold:"#FAAD14",yellow:"#FADB14",lime:"#A0D911",green:"#52C41A",cyan:"#13C2C2",blue:"#1677FF",geekblue:"#2F54EB",purple:"#722ED1",magenta:"#EB2F96",grey:"#666666"},p={},m={};Object.keys(f).forEach(function(e){p[e]=d(f[e]),p[e].primary=p[e][5],m[e]=d(f[e],{theme:"dark",backgroundColor:"#141414"}),m[e].primary=m[e][5]}),p.red,p.volcano;var g=p.gold;p.orange,p.yellow,p.lime,p.green,p.cyan;var h=p.blue;p.geekblue,p.purple,p.magenta,p.grey,p.grey},352:function(e,t,n){"use strict";n.d(t,{E4:function(){return ez},jG:function(){return M},ks:function(){return H},bf:function(){return L},CI:function(){return eA},fp:function(){return Y},xy:function(){return eT}});var r,o,a=n(11993),i=n(26365),c=n(83145),l=n(31686),s=function(e){for(var t,n=0,r=0,o=e.length;o>=4;++r,o-=4)t=(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))*1540483477+((t>>>16)*59797<<16),t^=t>>>24,n=(65535&t)*1540483477+((t>>>16)*59797<<16)^(65535&n)*1540483477+((n>>>16)*59797<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n^=255&e.charCodeAt(r),n=(65535&n)*1540483477+((n>>>16)*59797<<16)}return n^=n>>>13,(((n=(65535&n)*1540483477+((n>>>16)*59797<<16))^n>>>15)>>>0).toString(36)},u=n(21717),d=n(2265),f=n.t(d,2);n(6397),n(16671);var p=n(76405),m=n(25049);function g(e){return e.join("%")}var h=function(){function e(t){(0,p.Z)(this,e),(0,a.Z)(this,"instanceId",void 0),(0,a.Z)(this,"cache",new Map),this.instanceId=t}return(0,m.Z)(e,[{key:"get",value:function(e){return this.opGet(g(e))}},{key:"opGet",value:function(e){return this.cache.get(e)||null}},{key:"update",value:function(e,t){return this.opUpdate(g(e),t)}},{key:"opUpdate",value:function(e,t){var n=t(this.cache.get(e));null===n?this.cache.delete(e):this.cache.set(e,n)}}]),e}(),v="data-token-hash",b="data-css-hash",y="__cssinjs_instance__",x=d.createContext({hashPriority:"low",cache:function(){var e=Math.random().toString(12).slice(2);if("undefined"!=typeof document&&document.head&&document.body){var t=document.body.querySelectorAll("style[".concat(b,"]"))||[],n=document.head.firstChild;Array.from(t).forEach(function(t){t[y]=t[y]||e,t[y]===e&&document.head.insertBefore(t,n)});var r={};Array.from(document.querySelectorAll("style[".concat(b,"]"))).forEach(function(t){var n,o=t.getAttribute(b);r[o]?t[y]===e&&(null===(n=t.parentNode)||void 0===n||n.removeChild(t)):r[o]=!0})}return new h(e)}(),defaultCache:!0}),w=n(41154),E=n(94981),S=function(){function e(){(0,p.Z)(this,e),(0,a.Z)(this,"cache",void 0),(0,a.Z)(this,"keys",void 0),(0,a.Z)(this,"cacheCallTimes",void 0),this.cache=new Map,this.keys=[],this.cacheCallTimes=0}return(0,m.Z)(e,[{key:"size",value:function(){return this.keys.length}},{key:"internalGet",value:function(e){var t,n,r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o={map:this.cache};return e.forEach(function(e){if(o){var t;o=null===(t=o)||void 0===t||null===(t=t.map)||void 0===t?void 0:t.get(e)}else o=void 0}),null!==(t=o)&&void 0!==t&&t.value&&r&&(o.value[1]=this.cacheCallTimes++),null===(n=o)||void 0===n?void 0:n.value}},{key:"get",value:function(e){var t;return null===(t=this.internalGet(e,!0))||void 0===t?void 0:t[0]}},{key:"has",value:function(e){return!!this.internalGet(e)}},{key:"set",value:function(t,n){var r=this;if(!this.has(t)){if(this.size()+1>e.MAX_CACHE_SIZE+e.MAX_CACHE_OFFSET){var o=this.keys.reduce(function(e,t){var n=(0,i.Z)(e,2)[1];return r.internalGet(t)[1]0,"[Ant Design CSS-in-JS] Theme should have at least one derivative function."),Z+=1}return(0,m.Z)(e,[{key:"getDerivativeToken",value:function(e){return this.derivatives.reduce(function(t,n){return n(e,t)},void 0)}}]),e}(),k=new S;function M(e){var t=Array.isArray(e)?e:[e];return k.has(t)||k.set(t,new O(t)),k.get(t)}var R=new WeakMap,j={},I=new WeakMap;function N(e){var t=I.get(e)||"";return t||(Object.keys(e).forEach(function(n){var r=e[n];t+=n,r instanceof O?t+=r.id:r&&"object"===(0,w.Z)(r)?t+=N(r):t+=r}),I.set(e,t)),t}function P(e,t){return s("".concat(t,"_").concat(N(e)))}var T="random-".concat(Date.now(),"-").concat(Math.random()).replace(/\./g,""),F="_bAmBoO_",A=void 0,z=(0,E.Z)();function L(e){return"number"==typeof e?"".concat(e,"px"):e}function _(e,t,n){var r,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(i)return e;var c=(0,l.Z)((0,l.Z)({},o),{},(r={},(0,a.Z)(r,v,t),(0,a.Z)(r,b,n),r)),s=Object.keys(c).map(function(e){var t=c[e];return t?"".concat(e,'="').concat(t,'"'):null}).filter(function(e){return e}).join(" ");return"")}var H=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return"--".concat(t?"".concat(t,"-"):"").concat(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").replace(/([A-Z]+)([A-Z][a-z0-9]+)/g,"$1-$2").replace(/([a-z])([A-Z0-9])/g,"$1-$2").toLowerCase()},B=function(e,t,n){var r,o={},a={};return Object.entries(e).forEach(function(e){var t=(0,i.Z)(e,2),r=t[0],c=t[1];if(null!=n&&null!==(l=n.preserve)&&void 0!==l&&l[r])a[r]=c;else if(("string"==typeof c||"number"==typeof c)&&!(null!=n&&null!==(s=n.ignore)&&void 0!==s&&s[r])){var l,s,u,d=H(r,null==n?void 0:n.prefix);o[d]="number"!=typeof c||null!=n&&null!==(u=n.unitless)&&void 0!==u&&u[r]?String(c):"".concat(c,"px"),a[r]="var(".concat(d,")")}}),[a,(r={scope:null==n?void 0:n.scope},Object.keys(o).length?".".concat(t).concat(null!=r&&r.scope?".".concat(r.scope):"","{").concat(Object.entries(o).map(function(e){var t=(0,i.Z)(e,2),n=t[0],r=t[1];return"".concat(n,":").concat(r,";")}).join(""),"}"):"")]},D=n(27380),W=(0,l.Z)({},f).useInsertionEffect,V=W?function(e,t,n){return W(function(){return e(),t()},n)}:function(e,t,n){d.useMemo(e,n),(0,D.Z)(function(){return t(!0)},n)},q=void 0!==(0,l.Z)({},f).useInsertionEffect?function(e){var t=[],n=!1;return d.useEffect(function(){return n=!1,function(){n=!0,t.length&&t.forEach(function(e){return e()})}},e),function(e){n||t.push(e)}}:function(){return function(e){e()}};function G(e,t,n,r,o){var a=d.useContext(x).cache,l=g([e].concat((0,c.Z)(t))),s=q([l]),u=function(e){a.opUpdate(l,function(t){var r=(0,i.Z)(t||[void 0,void 0],2),o=r[0],a=[void 0===o?0:o,r[1]||n()];return e?e(a):a})};d.useMemo(function(){u()},[l]);var f=a.opGet(l)[1];return V(function(){null==o||o(f)},function(e){return u(function(t){var n=(0,i.Z)(t,2),r=n[0],a=n[1];return e&&0===r&&(null==o||o(f)),[r+1,a]}),function(){a.opUpdate(l,function(t){var n=(0,i.Z)(t||[],2),o=n[0],c=void 0===o?0:o,u=n[1];return 0==c-1?(s(function(){(e||!a.opGet(l))&&(null==r||r(u,!1))}),null):[c-1,u]})}},[l]),f}var X={},U=new Map,K=function(e,t,n,r){var o=n.getDerivativeToken(e),a=(0,l.Z)((0,l.Z)({},o),t);return r&&(a=r(a)),a},$="token";function Y(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=(0,d.useContext)(x),o=r.cache.instanceId,a=r.container,f=n.salt,p=void 0===f?"":f,m=n.override,g=void 0===m?X:m,h=n.formatToken,w=n.getComputedToken,E=n.cssVar,S=function(e,t){for(var n=R,r=0;r=(U.get(e)||0)}),n.length-r.length>0&&r.forEach(function(e){"undefined"!=typeof document&&document.querySelectorAll("style[".concat(v,'="').concat(e,'"]')).forEach(function(e){if(e[y]===o){var t;null===(t=e.parentNode)||void 0===t||t.removeChild(e)}}),U.delete(e)})},function(e){var t=(0,i.Z)(e,4),n=t[0],r=t[3];if(E&&r){var c=(0,u.hq)(r,s("css-variables-".concat(n._themeKey)),{mark:b,prepend:"queue",attachTo:a,priority:-999});c[y]=o,c.setAttribute(v,n._themeKey)}})}var Q=n(1119),J={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},ee="comm",et="rule",en="decl",er=Math.abs,eo=String.fromCharCode;function ea(e,t,n){return e.replace(t,n)}function ei(e,t){return 0|e.charCodeAt(t)}function ec(e,t,n){return e.slice(t,n)}function el(e){return e.length}function es(e,t){return t.push(e),e}function eu(e,t){for(var n="",r=0;r0?p[b]+" "+y:ea(y,/&\f/g,p[b])).trim())&&(l[v++]=x);return eb(e,t,n,0===o?et:c,l,s,u,d)}function eC(e,t,n,r,o){return eb(e,t,n,en,ec(e,0,r),ec(e,r+1,-1),r,o)}var eZ="data-ant-cssinjs-cache-path",eO="_FILE_STYLE__",ek=!0,eM="_multi_value_";function eR(e){var t,n,r;return eu((r=function e(t,n,r,o,a,i,c,l,s){for(var u,d,f,p=0,m=0,g=c,h=0,v=0,b=0,y=1,x=1,w=1,E=0,S="",C=a,Z=i,O=o,k=S;x;)switch(b=E,E=ey()){case 40:if(108!=b&&58==ei(k,g-1)){-1!=(d=k+=ea(eE(E),"&","&\f"),f=er(p?l[p-1]:0),d.indexOf("&\f",f))&&(w=-1);break}case 34:case 39:case 91:k+=eE(E);break;case 9:case 10:case 13:case 32:k+=function(e){for(;eh=ex();)if(eh<33)ey();else break;return ew(e)>2||ew(eh)>3?"":" "}(b);break;case 92:k+=function(e,t){for(var n;--t&&ey()&&!(eh<48)&&!(eh>102)&&(!(eh>57)||!(eh<65))&&(!(eh>70)||!(eh<97)););return n=eg+(t<6&&32==ex()&&32==ey()),ec(ev,e,n)}(eg-1,7);continue;case 47:switch(ex()){case 42:case 47:es(eb(u=function(e,t){for(;ey();)if(e+eh===57)break;else if(e+eh===84&&47===ex())break;return"/*"+ec(ev,t,eg-1)+"*"+eo(47===e?e:ey())}(ey(),eg),n,r,ee,eo(eh),ec(u,2,-2),0,s),s),(5==ew(b||1)||5==ew(ex()||1))&&el(k)&&" "!==ec(k,-1,void 0)&&(k+=" ");break;default:k+="/"}break;case 123*y:l[p++]=el(k)*w;case 125*y:case 59:case 0:switch(E){case 0:case 125:x=0;case 59+m:-1==w&&(k=ea(k,/\f/g,"")),v>0&&(el(k)-g||0===y&&47===b)&&es(v>32?eC(k+";",o,r,g-1,s):eC(ea(k," ","")+";",o,r,g-2,s),s);break;case 59:k+=";";default:if(es(O=eS(k,n,r,p,m,a,l,S,C=[],Z=[],g,i),i),123===E){if(0===m)e(k,n,O,O,C,i,g,l,Z);else{switch(h){case 99:if(110===ei(k,3))break;case 108:if(97===ei(k,2))break;default:m=0;case 100:case 109:case 115:}m?e(t,O,O,o&&es(eS(t,O,O,0,0,a,l,S,a,C=[],g,Z),Z),a,Z,g,l,o?C:Z):e(k,O,O,O,[""],Z,0,l,Z)}}}p=m=v=0,y=w=1,S=k="",g=c;break;case 58:g=1+el(k),v=b;default:if(y<1){if(123==E)--y;else if(125==E&&0==y++&&125==(eh=eg>0?ei(ev,--eg):0,ep--,10===eh&&(ep=1,ef--),eh))continue}switch(k+=eo(E),E*y){case 38:w=m>0?1:(k+="\f",-1);break;case 44:l[p++]=(el(k)-1)*w,w=1;break;case 64:45===ex()&&(k+=eE(ey())),h=ex(),m=g=el(S=k+=function(e){for(;!ew(ex());)ey();return ec(ev,e,eg)}(eg)),E++;break;case 45:45===b&&2==el(k)&&(y=0)}}return i}("",null,null,null,[""],(n=t=e,ef=ep=1,em=el(ev=n),eg=0,t=[]),0,[0],t),ev="",r),ed).replace(/\{%%%\:[^;];}/g,";")}var ej=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{root:!0,parentSelectors:[]},o=r.root,a=r.injectHash,s=r.parentSelectors,d=n.hashId,f=n.layer,p=(n.path,n.hashPriority),m=n.transformers,g=void 0===m?[]:m;n.linters;var h="",v={};function b(t){var r=t.getName(d);if(!v[r]){var o=e(t.style,n,{root:!1,parentSelectors:s}),a=(0,i.Z)(o,1)[0];v[r]="@keyframes ".concat(t.getName(d)).concat(a)}}if((function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return t.forEach(function(t){Array.isArray(t)?e(t,n):t&&n.push(t)}),n})(Array.isArray(t)?t:[t]).forEach(function(t){var r="string"!=typeof t||o?t:{};if("string"==typeof r)h+="".concat(r,"\n");else if(r._keyframe)b(r);else{var u=g.reduce(function(e,t){var n;return(null==t||null===(n=t.visit)||void 0===n?void 0:n.call(t,e))||e},r);Object.keys(u).forEach(function(t){var r=u[t];if("object"!==(0,w.Z)(r)||!r||"animationName"===t&&r._keyframe||"object"===(0,w.Z)(r)&&r&&("_skip_check_"in r||eM in r)){function f(e,t){var n=e.replace(/[A-Z]/g,function(e){return"-".concat(e.toLowerCase())}),r=t;J[e]||"number"!=typeof r||0===r||(r="".concat(r,"px")),"animationName"===e&&null!=t&&t._keyframe&&(b(t),r=t.getName(d)),h+="".concat(n,":").concat(r,";")}var m,g=null!==(m=null==r?void 0:r.value)&&void 0!==m?m:r;"object"===(0,w.Z)(r)&&null!=r&&r[eM]&&Array.isArray(g)?g.forEach(function(e){f(t,e)}):f(t,g)}else{var y=!1,x=t.trim(),E=!1;(o||a)&&d?x.startsWith("@")?y=!0:x=function(e,t,n){if(!t)return e;var r=".".concat(t),o="low"===n?":where(".concat(r,")"):r;return e.split(",").map(function(e){var t,n=e.trim().split(/\s+/),r=n[0]||"",a=(null===(t=r.match(/^\w+/))||void 0===t?void 0:t[0])||"";return[r="".concat(a).concat(o).concat(r.slice(a.length))].concat((0,c.Z)(n.slice(1))).join(" ")}).join(",")}(t,d,p):o&&!d&&("&"===x||""===x)&&(x="",E=!0);var S=e(r,n,{root:E,injectHash:y,parentSelectors:[].concat((0,c.Z)(s),[x])}),C=(0,i.Z)(S,2),Z=C[0],O=C[1];v=(0,l.Z)((0,l.Z)({},v),O),h+="".concat(x).concat(Z)}})}}),o){if(f&&(void 0===A&&(A=function(e,t,n){if((0,E.Z)()){(0,u.hq)(e,T);var r,o,a=document.createElement("div");a.style.position="fixed",a.style.left="0",a.style.top="0",null==t||t(a),document.body.appendChild(a);var i=null===(r=getComputedStyle(a).content)||void 0===r?void 0:r.includes(F);return null===(o=a.parentNode)||void 0===o||o.removeChild(a),(0,u.jL)(T),i}return!1}("@layer ".concat(T," { .").concat(T,' { content: "').concat(F,'"!important; } }'),function(e){e.className=T})),A)){var y=f.split(","),x=y[y.length-1].trim();h="@layer ".concat(x," {").concat(h,"}"),y.length>1&&(h="@layer ".concat(f,"{%%%:%}").concat(h))}}else h="{".concat(h,"}");return[h,v]};function eI(e,t){return s("".concat(e.join("%")).concat(t))}function eN(){return null}var eP="style";function eT(e,t){var n=e.token,o=e.path,l=e.hashId,s=e.layer,f=e.nonce,p=e.clientOnly,m=e.order,g=void 0===m?0:m,h=d.useContext(x),w=h.autoClear,S=(h.mock,h.defaultCache),C=h.hashPriority,Z=h.container,O=h.ssrInline,k=h.transformers,M=h.linters,R=h.cache,j=n._tokenKey,I=[j].concat((0,c.Z)(o)),N=G(eP,I,function(){var e=I.join("|");if(!function(){if(!r&&(r={},(0,E.Z)())){var e,t=document.createElement("div");t.className=eZ,t.style.position="fixed",t.style.visibility="hidden",t.style.top="-9999px",document.body.appendChild(t);var n=getComputedStyle(t).content||"";(n=n.replace(/^"/,"").replace(/"$/,"")).split(";").forEach(function(e){var t=e.split(":"),n=(0,i.Z)(t,2),o=n[0],a=n[1];r[o]=a});var o=document.querySelector("style[".concat(eZ,"]"));o&&(ek=!1,null===(e=o.parentNode)||void 0===e||e.removeChild(o)),document.body.removeChild(t)}}(),r[e]){var n=function(e){var t=r[e],n=null;if(t&&(0,E.Z)()){if(ek)n=eO;else{var o=document.querySelector("style[".concat(b,'="').concat(r[e],'"]'));o?n=o.innerHTML:delete r[e]}}return[n,t]}(e),a=(0,i.Z)(n,2),c=a[0],u=a[1];if(c)return[c,j,u,{},p,g]}var d=ej(t(),{hashId:l,hashPriority:C,layer:s,path:o.join("-"),transformers:k,linters:M}),f=(0,i.Z)(d,2),m=f[0],h=f[1],v=eR(m),y=eI(I,v);return[v,j,y,h,p,g]},function(e,t){var n=(0,i.Z)(e,3)[2];(t||w)&&z&&(0,u.jL)(n,{mark:b})},function(e){var t=(0,i.Z)(e,4),n=t[0],r=(t[1],t[2]),o=t[3];if(z&&n!==eO){var a={mark:b,prepend:"queue",attachTo:Z,priority:g},c="function"==typeof f?f():f;c&&(a.csp={nonce:c});var l=(0,u.hq)(n,r,a);l[y]=R.instanceId,l.setAttribute(v,j),Object.keys(o).forEach(function(e){(0,u.hq)(eR(o[e]),"_effect-".concat(e),a)})}}),P=(0,i.Z)(N,3),T=P[0],F=P[1],A=P[2];return function(e){var t,n;return t=O&&!z&&S?d.createElement("style",(0,Q.Z)({},(n={},(0,a.Z)(n,v,F),(0,a.Z)(n,b,A),n),{dangerouslySetInnerHTML:{__html:T}})):d.createElement(eN,null),d.createElement(d.Fragment,null,t,e)}}var eF="cssVar",eA=function(e,t){var n=e.key,r=e.prefix,o=e.unitless,a=e.ignore,l=e.token,s=e.scope,f=void 0===s?"":s,p=(0,d.useContext)(x),m=p.cache.instanceId,g=p.container,h=l._tokenKey,w=[].concat((0,c.Z)(e.path),[n,f,h]);return G(eF,w,function(){var e=B(t(),n,{prefix:r,unitless:o,ignore:a,scope:f}),c=(0,i.Z)(e,2),l=c[0],s=c[1],u=eI(w,s);return[l,s,u,n]},function(e){var t=(0,i.Z)(e,3)[2];z&&(0,u.jL)(t,{mark:b})},function(e){var t=(0,i.Z)(e,3),r=t[1],o=t[2];if(r){var a=(0,u.hq)(r,o,{mark:b,prepend:"queue",attachTo:g,priority:-999});a[y]=m,a.setAttribute(v,n)}})};o={},(0,a.Z)(o,eP,function(e,t,n){var r=(0,i.Z)(e,6),o=r[0],a=r[1],c=r[2],l=r[3],s=r[4],u=r[5],d=(n||{}).plain;if(s)return null;var f=o,p={"data-rc-order":"prependQueue","data-rc-priority":"".concat(u)};return f=_(o,a,c,p,d),l&&Object.keys(l).forEach(function(e){if(!t[e]){t[e]=!0;var n=eR(l[e]);f+=_(n,a,"_effect-".concat(e),p,d)}}),[u,c,f]}),(0,a.Z)(o,$,function(e,t,n){var r=(0,i.Z)(e,5),o=r[2],a=r[3],c=r[4],l=(n||{}).plain;if(!a)return null;var s=o._tokenKey,u=_(a,c,s,{"data-rc-order":"prependQueue","data-rc-priority":"".concat(-999)},l);return[-999,s,u]}),(0,a.Z)(o,eF,function(e,t,n){var r=(0,i.Z)(e,4),o=r[1],a=r[2],c=r[3],l=(n||{}).plain;if(!o)return null;var s=_(o,c,a,{"data-rc-order":"prependQueue","data-rc-priority":"".concat(-999)},l);return[-999,a,s]});var ez=function(){function e(t,n){(0,p.Z)(this,e),(0,a.Z)(this,"name",void 0),(0,a.Z)(this,"style",void 0),(0,a.Z)(this,"_keyframe",!0),this.name=t,this.style=n}return(0,m.Z)(e,[{key:"getName",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e?"".concat(e,"-").concat(this.name):this.name}}]),e}();function eL(e){return e.notSplit=!0,e}eL(["borderTop","borderBottom"]),eL(["borderTop"]),eL(["borderBottom"]),eL(["borderLeft","borderRight"]),eL(["borderLeft"]),eL(["borderRight"])},55015:function(e,t,n){"use strict";n.d(t,{Z:function(){return M}});var r=n(1119),o=n(26365),a=n(11993),i=n(6989),c=n(2265),l=n(36760),s=n.n(l),u=n(31373),d=n(20902),f=n(31686),p=n(41154),m=n(21717),g=n(13211),h=n(32559);function v(e){return"object"===(0,p.Z)(e)&&"string"==typeof e.name&&"string"==typeof e.theme&&("object"===(0,p.Z)(e.icon)||"function"==typeof e.icon)}function b(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return Object.keys(e).reduce(function(t,n){var r=e[n];return"class"===n?(t.className=r,delete t.class):(delete t[n],t[n.replace(/-(.)/g,function(e,t){return t.toUpperCase()})]=r),t},{})}function y(e){return(0,u.R_)(e)[0]}function x(e){return e?Array.isArray(e)?e:[e]:[]}var w=function(e){var t=(0,c.useContext)(d.Z),n=t.csp,r=t.prefixCls,o="\n.anticon {\n  display: inline-block;\n  color: inherit;\n  font-style: normal;\n  line-height: 0;\n  text-align: center;\n  text-transform: none;\n  vertical-align: -0.125em;\n  text-rendering: optimizeLegibility;\n  -webkit-font-smoothing: antialiased;\n  -moz-osx-font-smoothing: grayscale;\n}\n\n.anticon > * {\n  line-height: 1;\n}\n\n.anticon svg {\n  display: inline-block;\n}\n\n.anticon::before {\n  display: none;\n}\n\n.anticon .anticon-icon {\n  display: block;\n}\n\n.anticon[tabindex] {\n  cursor: pointer;\n}\n\n.anticon-spin::before,\n.anticon-spin {\n  display: inline-block;\n  -webkit-animation: loadingCircle 1s infinite linear;\n  animation: loadingCircle 1s infinite linear;\n}\n\n@-webkit-keyframes loadingCircle {\n  100% {\n    -webkit-transform: rotate(360deg);\n    transform: rotate(360deg);\n  }\n}\n\n@keyframes loadingCircle {\n  100% {\n    -webkit-transform: rotate(360deg);\n    transform: rotate(360deg);\n  }\n}\n";r&&(o=o.replace(/anticon/g,r)),(0,c.useEffect)(function(){var t=e.current,r=(0,g.A)(t);(0,m.hq)(o,"@ant-design-icons",{prepend:!0,csp:n,attachTo:r})},[])},E=["icon","className","onClick","style","primaryColor","secondaryColor"],S={primaryColor:"#333",secondaryColor:"#E6E6E6",calculated:!1},C=function(e){var t,n,r=e.icon,o=e.className,a=e.onClick,l=e.style,s=e.primaryColor,u=e.secondaryColor,d=(0,i.Z)(e,E),p=c.useRef(),m=S;if(s&&(m={primaryColor:s,secondaryColor:u||y(s)}),w(p),t=v(r),n="icon should be icon definiton, but got ".concat(r),(0,h.ZP)(t,"[@ant-design/icons] ".concat(n)),!v(r))return null;var g=r;return g&&"function"==typeof g.icon&&(g=(0,f.Z)((0,f.Z)({},g),{},{icon:g.icon(m.primaryColor,m.secondaryColor)})),function e(t,n,r){return r?c.createElement(t.tag,(0,f.Z)((0,f.Z)({key:n},b(t.attrs)),r),(t.children||[]).map(function(r,o){return e(r,"".concat(n,"-").concat(t.tag,"-").concat(o))})):c.createElement(t.tag,(0,f.Z)({key:n},b(t.attrs)),(t.children||[]).map(function(r,o){return e(r,"".concat(n,"-").concat(t.tag,"-").concat(o))}))}(g.icon,"svg-".concat(g.name),(0,f.Z)((0,f.Z)({className:o,onClick:a,style:l,"data-icon":g.name,width:"1em",height:"1em",fill:"currentColor","aria-hidden":"true"},d),{},{ref:p}))};function Z(e){var t=x(e),n=(0,o.Z)(t,2),r=n[0],a=n[1];return C.setTwoToneColors({primaryColor:r,secondaryColor:a})}C.displayName="IconReact",C.getTwoToneColors=function(){return(0,f.Z)({},S)},C.setTwoToneColors=function(e){var t=e.primaryColor,n=e.secondaryColor;S.primaryColor=t,S.secondaryColor=n||y(t),S.calculated=!!n};var O=["className","icon","spin","rotate","tabIndex","onClick","twoToneColor"];Z(u.iN.primary);var k=c.forwardRef(function(e,t){var n,l=e.className,u=e.icon,f=e.spin,p=e.rotate,m=e.tabIndex,g=e.onClick,h=e.twoToneColor,v=(0,i.Z)(e,O),b=c.useContext(d.Z),y=b.prefixCls,w=void 0===y?"anticon":y,E=b.rootClassName,S=s()(E,w,(n={},(0,a.Z)(n,"".concat(w,"-").concat(u.name),!!u.name),(0,a.Z)(n,"".concat(w,"-spin"),!!f||"loading"===u.name),n),l),Z=m;void 0===Z&&g&&(Z=-1);var k=x(h),M=(0,o.Z)(k,2),R=M[0],j=M[1];return c.createElement("span",(0,r.Z)({role:"img","aria-label":u.name},v,{ref:t,tabIndex:Z,onClick:g,className:S}),c.createElement(C,{icon:u,primaryColor:R,secondaryColor:j,style:p?{msTransform:"rotate(".concat(p,"deg)"),transform:"rotate(".concat(p,"deg)")}:void 0}))});k.displayName="AntdIcon",k.getTwoToneColor=function(){var e=C.getTwoToneColors();return e.calculated?[e.primaryColor,e.secondaryColor]:e.primaryColor},k.setTwoToneColor=Z;var M=k},20902:function(e,t,n){"use strict";var r=(0,n(2265).createContext)({});t.Z=r},8900:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm193.5 301.7l-210.6 292a31.8 31.8 0 01-51.7 0L318.5 484.9c-3.8-5.3 0-12.7 6.5-12.7h46.9c10.2 0 19.9 4.9 25.9 13.3l71.2 98.8 157.2-218c6-8.3 15.6-13.3 25.9-13.3H699c6.5 0 10.3 7.4 6.5 12.7z"}}]},name:"check-circle",theme:"filled"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},9738:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 00-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.3 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}}]},name:"check",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},39725:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64c247.4 0 448 200.6 448 448S759.4 960 512 960 64 759.4 64 512 264.6 64 512 64zm127.98 274.82h-.04l-.08.06L512 466.75 384.14 338.88c-.04-.05-.06-.06-.08-.06a.12.12 0 00-.07 0c-.03 0-.05.01-.09.05l-45.02 45.02a.2.2 0 00-.05.09.12.12 0 000 .07v.02a.27.27 0 00.06.06L466.75 512 338.88 639.86c-.05.04-.06.06-.06.08a.12.12 0 000 .07c0 .03.01.05.05.09l45.02 45.02a.2.2 0 00.09.05.12.12 0 00.07 0c.02 0 .04-.01.08-.05L512 557.25l127.86 127.87c.04.04.06.05.08.05a.12.12 0 00.07 0c.03 0 .05-.01.09-.05l45.02-45.02a.2.2 0 00.05-.09.12.12 0 000-.07v-.02a.27.27 0 00-.05-.06L557.25 512l127.87-127.86c.04-.04.05-.06.05-.08a.12.12 0 000-.07c0-.03-.01-.05-.05-.09l-45.02-45.02a.2.2 0 00-.09-.05.12.12 0 00-.07 0z"}}]},name:"close-circle",theme:"filled"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},49638:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{"fill-rule":"evenodd",viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M799.86 166.31c.02 0 .04.02.08.06l57.69 57.7c.04.03.05.05.06.08a.12.12 0 010 .06c0 .03-.02.05-.06.09L569.93 512l287.7 287.7c.04.04.05.06.06.09a.12.12 0 010 .07c0 .02-.02.04-.06.08l-57.7 57.69c-.03.04-.05.05-.07.06a.12.12 0 01-.07 0c-.03 0-.05-.02-.09-.06L512 569.93l-287.7 287.7c-.04.04-.06.05-.09.06a.12.12 0 01-.07 0c-.02 0-.04-.02-.08-.06l-57.69-57.7c-.04-.03-.05-.05-.06-.07a.12.12 0 010-.07c0-.03.02-.05.06-.09L454.07 512l-287.7-287.7c-.04-.04-.05-.06-.06-.09a.12.12 0 010-.07c0-.02.02-.04.06-.08l57.7-57.69c.03-.04.05-.05.07-.06a.12.12 0 01.07 0c.03 0 .05.02.09.06L512 454.07l287.7-287.7c.04-.04.06-.05.09-.06a.12.12 0 01.07 0z"}}]},name:"close",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},70464:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M884 256h-75c-5.1 0-9.9 2.5-12.9 6.6L512 654.2 227.9 262.6c-3-4.1-7.8-6.6-12.9-6.6h-75c-6.5 0-10.3 7.4-6.5 12.7l352.6 486.1c12.8 17.6 39 17.6 51.7 0l352.6-486.1c3.9-5.3.1-12.7-6.4-12.7z"}}]},name:"down",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},54537:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm-32 232c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V296zm32 440a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"exclamation-circle",theme:"filled"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},97416:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2Q889.47 375.11 816.7 305l-50.88 50.88C807.31 395.53 843.45 447.4 874.7 512 791.5 684.2 673.4 766 512 766q-72.67 0-133.87-22.38L323 798.75Q408 838 512 838q288.3 0 430.2-300.3a60.29 60.29 0 000-51.5zm-63.57-320.64L836 122.88a8 8 0 00-11.32 0L715.31 232.2Q624.86 186 512 186q-288.3 0-430.2 300.3a60.3 60.3 0 000 51.5q56.69 119.4 136.5 191.41L112.48 835a8 8 0 000 11.31L155.17 889a8 8 0 0011.31 0l712.15-712.12a8 8 0 000-11.32zM149.3 512C232.6 339.8 350.7 258 512 258c54.54 0 104.13 9.36 149.12 28.39l-70.3 70.3a176 176 0 00-238.13 238.13l-83.42 83.42C223.1 637.49 183.3 582.28 149.3 512zm246.7 0a112.11 112.11 0 01146.2-106.69L401.31 546.2A112 112 0 01396 512z"}},{tag:"path",attrs:{d:"M508 624c-3.46 0-6.87-.16-10.25-.47l-52.82 52.82a176.09 176.09 0 00227.42-227.42l-52.82 52.82c.31 3.38.47 6.79.47 10.25a111.94 111.94 0 01-112 112z"}}]},name:"eye-invisible",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},6520:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M942.2 486.2C847.4 286.5 704.1 186 512 186c-192.2 0-335.4 100.5-430.2 300.3a60.3 60.3 0 000 51.5C176.6 737.5 319.9 838 512 838c192.2 0 335.4-100.5 430.2-300.3 7.7-16.2 7.7-35 0-51.5zM512 766c-161.3 0-279.4-81.8-362.7-254C232.6 339.8 350.7 258 512 258c161.3 0 279.4 81.8 362.7 254C791.5 684.2 673.4 766 512 766zm-4-430c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm0 288c-61.9 0-112-50.1-112-112s50.1-112 112-112 112 50.1 112 112-50.1 112-112 112z"}}]},name:"eye",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},55726:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm32 664c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V456c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v272zm-32-344a48.01 48.01 0 010-96 48.01 48.01 0 010 96z"}}]},name:"info-circle",theme:"filled"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},15424:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M464 336a48 48 0 1096 0 48 48 0 10-96 0zm72 112h-48c-4.4 0-8 3.6-8 8v272c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V456c0-4.4-3.6-8-8-8z"}}]},name:"info-circle",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},61935:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"0 0 1024 1024",focusable:"false"},children:[{tag:"path",attrs:{d:"M988 548c-19.9 0-36-16.1-36-36 0-59.4-11.6-117-34.6-171.3a440.45 440.45 0 00-94.3-139.9 437.71 437.71 0 00-139.9-94.3C629 83.6 571.4 72 512 72c-19.9 0-36-16.1-36-36s16.1-36 36-36c69.1 0 136.2 13.5 199.3 40.3C772.3 66 827 103 874 150c47 47 83.9 101.8 109.7 162.7 26.7 63.1 40.2 130.2 40.2 199.3.1 19.9-16 36-35.9 36z"}}]},name:"loading",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},67187:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}},{tag:"path",attrs:{d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7-21.2 8.1-39.2 22.3-52.1 40.9-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0130.9-44.8c59-22.7 97.1-74.7 97.1-132.5.1-39.3-17.1-76-48.3-103.3zM472 732a40 40 0 1080 0 40 40 0 10-80 0z"}}]},name:"question-circle",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},29436:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(1119),o=n(2265),a={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.6 854.5L649.9 594.8C690.2 542.7 712 479 712 412c0-80.2-31.3-155.4-87.9-212.1-56.6-56.7-132-87.9-212.1-87.9s-155.5 31.3-212.1 87.9C143.2 256.5 112 331.8 112 412c0 80.1 31.3 155.5 87.9 212.1C256.5 680.8 331.8 712 412 712c67 0 130.6-21.8 182.7-62l259.7 259.6a8.2 8.2 0 0011.6 0l43.6-43.5a8.2 8.2 0 000-11.6zM570.4 570.4C528 612.7 471.8 636 412 636s-116-23.3-158.4-65.6C211.3 528 188 471.8 188 412s23.3-116.1 65.6-158.4C296 211.3 352.2 188 412 188s116.1 23.2 158.4 65.6S636 352.2 636 412s-23.3 116.1-65.6 158.4z"}}]},name:"search",theme:"outlined"},i=n(55015),c=o.forwardRef(function(e,t){return o.createElement(i.Z,(0,r.Z)({},e,{ref:t,icon:a}))})},82082:function(e,t,n){"use strict";n.d(t,{T6:function(){return f},VD:function(){return p},WE:function(){return s},Yt:function(){return m},lC:function(){return a},py:function(){return l},rW:function(){return o},s:function(){return d},ve:function(){return c},vq:function(){return u}});var r=n(58317);function o(e,t,n){return{r:255*(0,r.sh)(e,255),g:255*(0,r.sh)(t,255),b:255*(0,r.sh)(n,255)}}function a(e,t,n){var o=Math.max(e=(0,r.sh)(e,255),t=(0,r.sh)(t,255),n=(0,r.sh)(n,255)),a=Math.min(e,t,n),i=0,c=0,l=(o+a)/2;if(o===a)c=0,i=0;else{var s=o-a;switch(c=l>.5?s/(2-o-a):s/(o+a),o){case e:i=(t-n)/s+(t1&&(n-=1),n<1/6)?e+6*n*(t-e):n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function c(e,t,n){if(e=(0,r.sh)(e,360),t=(0,r.sh)(t,100),n=(0,r.sh)(n,100),0===t)a=n,c=n,o=n;else{var o,a,c,l=n<.5?n*(1+t):n+t-n*t,s=2*n-l;o=i(s,l,e+1/3),a=i(s,l,e),c=i(s,l,e-1/3)}return{r:255*o,g:255*a,b:255*c}}function l(e,t,n){var o=Math.max(e=(0,r.sh)(e,255),t=(0,r.sh)(t,255),n=(0,r.sh)(n,255)),a=Math.min(e,t,n),i=0,c=o-a;if(o===a)i=0;else{switch(o){case e:i=(t-n)/c+(t>16,g:(65280&e)>>8,b:255&e}}},28052:function(e,t,n){"use strict";n.d(t,{R:function(){return r}});var r={aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyan:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",goldenrod:"#daa520",gold:"#ffd700",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavenderblush:"#fff0f5",lavender:"#e6e6fa",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",steelblue:"#4682b4",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",tomato:"#ff6347",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"}},96021:function(e,t,n){"use strict";n.d(t,{uA:function(){return i}});var r=n(82082),o=n(28052),a=n(58317);function i(e){var t={r:0,g:0,b:0},n=1,i=null,c=null,l=null,s=!1,f=!1;return"string"==typeof e&&(e=function(e){if(0===(e=e.trim().toLowerCase()).length)return!1;var t=!1;if(o.R[e])e=o.R[e],t=!0;else if("transparent"===e)return{r:0,g:0,b:0,a:0,format:"name"};var n=u.rgb.exec(e);return n?{r:n[1],g:n[2],b:n[3]}:(n=u.rgba.exec(e))?{r:n[1],g:n[2],b:n[3],a:n[4]}:(n=u.hsl.exec(e))?{h:n[1],s:n[2],l:n[3]}:(n=u.hsla.exec(e))?{h:n[1],s:n[2],l:n[3],a:n[4]}:(n=u.hsv.exec(e))?{h:n[1],s:n[2],v:n[3]}:(n=u.hsva.exec(e))?{h:n[1],s:n[2],v:n[3],a:n[4]}:(n=u.hex8.exec(e))?{r:(0,r.VD)(n[1]),g:(0,r.VD)(n[2]),b:(0,r.VD)(n[3]),a:(0,r.T6)(n[4]),format:t?"name":"hex8"}:(n=u.hex6.exec(e))?{r:(0,r.VD)(n[1]),g:(0,r.VD)(n[2]),b:(0,r.VD)(n[3]),format:t?"name":"hex"}:(n=u.hex4.exec(e))?{r:(0,r.VD)(n[1]+n[1]),g:(0,r.VD)(n[2]+n[2]),b:(0,r.VD)(n[3]+n[3]),a:(0,r.T6)(n[4]+n[4]),format:t?"name":"hex8"}:!!(n=u.hex3.exec(e))&&{r:(0,r.VD)(n[1]+n[1]),g:(0,r.VD)(n[2]+n[2]),b:(0,r.VD)(n[3]+n[3]),format:t?"name":"hex"}}(e)),"object"==typeof e&&(d(e.r)&&d(e.g)&&d(e.b)?(t=(0,r.rW)(e.r,e.g,e.b),s=!0,f="%"===String(e.r).substr(-1)?"prgb":"rgb"):d(e.h)&&d(e.s)&&d(e.v)?(i=(0,a.JX)(e.s),c=(0,a.JX)(e.v),t=(0,r.WE)(e.h,i,c),s=!0,f="hsv"):d(e.h)&&d(e.s)&&d(e.l)&&(i=(0,a.JX)(e.s),l=(0,a.JX)(e.l),t=(0,r.ve)(e.h,i,l),s=!0,f="hsl"),Object.prototype.hasOwnProperty.call(e,"a")&&(n=e.a)),n=(0,a.Yq)(n),{ok:s,format:e.format||f,r:Math.min(255,Math.max(t.r,0)),g:Math.min(255,Math.max(t.g,0)),b:Math.min(255,Math.max(t.b,0)),a:n}}var c="(?:".concat("[-\\+]?\\d*\\.\\d+%?",")|(?:").concat("[-\\+]?\\d+%?",")"),l="[\\s|\\(]+(".concat(c,")[,|\\s]+(").concat(c,")[,|\\s]+(").concat(c,")\\s*\\)?"),s="[\\s|\\(]+(".concat(c,")[,|\\s]+(").concat(c,")[,|\\s]+(").concat(c,")[,|\\s]+(").concat(c,")\\s*\\)?"),u={CSS_UNIT:new RegExp(c),rgb:RegExp("rgb"+l),rgba:RegExp("rgba"+s),hsl:RegExp("hsl"+l),hsla:RegExp("hsla"+s),hsv:RegExp("hsv"+l),hsva:RegExp("hsva"+s),hex3:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex4:/^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex8:/^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/};function d(e){return!!u.CSS_UNIT.exec(String(e))}},36360:function(e,t,n){"use strict";n.d(t,{C:function(){return c}});var r=n(82082),o=n(28052),a=n(96021),i=n(58317),c=function(){function e(t,n){if(void 0===t&&(t=""),void 0===n&&(n={}),t instanceof e)return t;"number"==typeof t&&(t=(0,r.Yt)(t)),this.originalInput=t;var o,i=(0,a.uA)(t);this.originalInput=t,this.r=i.r,this.g=i.g,this.b=i.b,this.a=i.a,this.roundA=Math.round(100*this.a)/100,this.format=null!==(o=n.format)&&void 0!==o?o:i.format,this.gradientType=n.gradientType,this.r<1&&(this.r=Math.round(this.r)),this.g<1&&(this.g=Math.round(this.g)),this.b<1&&(this.b=Math.round(this.b)),this.isValid=i.ok}return e.prototype.isDark=function(){return 128>this.getBrightness()},e.prototype.isLight=function(){return!this.isDark()},e.prototype.getBrightness=function(){var e=this.toRgb();return(299*e.r+587*e.g+114*e.b)/1e3},e.prototype.getLuminance=function(){var e=this.toRgb(),t=e.r/255,n=e.g/255,r=e.b/255;return .2126*(t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4))+.7152*(n<=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4))+.0722*(r<=.03928?r/12.92:Math.pow((r+.055)/1.055,2.4))},e.prototype.getAlpha=function(){return this.a},e.prototype.setAlpha=function(e){return this.a=(0,i.Yq)(e),this.roundA=Math.round(100*this.a)/100,this},e.prototype.isMonochrome=function(){return 0===this.toHsl().s},e.prototype.toHsv=function(){var e=(0,r.py)(this.r,this.g,this.b);return{h:360*e.h,s:e.s,v:e.v,a:this.a}},e.prototype.toHsvString=function(){var e=(0,r.py)(this.r,this.g,this.b),t=Math.round(360*e.h),n=Math.round(100*e.s),o=Math.round(100*e.v);return 1===this.a?"hsv(".concat(t,", ").concat(n,"%, ").concat(o,"%)"):"hsva(".concat(t,", ").concat(n,"%, ").concat(o,"%, ").concat(this.roundA,")")},e.prototype.toHsl=function(){var e=(0,r.lC)(this.r,this.g,this.b);return{h:360*e.h,s:e.s,l:e.l,a:this.a}},e.prototype.toHslString=function(){var e=(0,r.lC)(this.r,this.g,this.b),t=Math.round(360*e.h),n=Math.round(100*e.s),o=Math.round(100*e.l);return 1===this.a?"hsl(".concat(t,", ").concat(n,"%, ").concat(o,"%)"):"hsla(".concat(t,", ").concat(n,"%, ").concat(o,"%, ").concat(this.roundA,")")},e.prototype.toHex=function(e){return void 0===e&&(e=!1),(0,r.vq)(this.r,this.g,this.b,e)},e.prototype.toHexString=function(e){return void 0===e&&(e=!1),"#"+this.toHex(e)},e.prototype.toHex8=function(e){return void 0===e&&(e=!1),(0,r.s)(this.r,this.g,this.b,this.a,e)},e.prototype.toHex8String=function(e){return void 0===e&&(e=!1),"#"+this.toHex8(e)},e.prototype.toHexShortString=function(e){return void 0===e&&(e=!1),1===this.a?this.toHexString(e):this.toHex8String(e)},e.prototype.toRgb=function(){return{r:Math.round(this.r),g:Math.round(this.g),b:Math.round(this.b),a:this.a}},e.prototype.toRgbString=function(){var e=Math.round(this.r),t=Math.round(this.g),n=Math.round(this.b);return 1===this.a?"rgb(".concat(e,", ").concat(t,", ").concat(n,")"):"rgba(".concat(e,", ").concat(t,", ").concat(n,", ").concat(this.roundA,")")},e.prototype.toPercentageRgb=function(){var e=function(e){return"".concat(Math.round(100*(0,i.sh)(e,255)),"%")};return{r:e(this.r),g:e(this.g),b:e(this.b),a:this.a}},e.prototype.toPercentageRgbString=function(){var e=function(e){return Math.round(100*(0,i.sh)(e,255))};return 1===this.a?"rgb(".concat(e(this.r),"%, ").concat(e(this.g),"%, ").concat(e(this.b),"%)"):"rgba(".concat(e(this.r),"%, ").concat(e(this.g),"%, ").concat(e(this.b),"%, ").concat(this.roundA,")")},e.prototype.toName=function(){if(0===this.a)return"transparent";if(this.a<1)return!1;for(var e="#"+(0,r.vq)(this.r,this.g,this.b,!1),t=0,n=Object.entries(o.R);t=0;return!t&&r&&(e.startsWith("hex")||"name"===e)?"name"===e&&0===this.a?this.toName():this.toRgbString():("rgb"===e&&(n=this.toRgbString()),"prgb"===e&&(n=this.toPercentageRgbString()),("hex"===e||"hex6"===e)&&(n=this.toHexString()),"hex3"===e&&(n=this.toHexString(!0)),"hex4"===e&&(n=this.toHex8String(!0)),"hex8"===e&&(n=this.toHex8String()),"name"===e&&(n=this.toName()),"hsl"===e&&(n=this.toHslString()),"hsv"===e&&(n=this.toHsvString()),n||this.toHexString())},e.prototype.toNumber=function(){return(Math.round(this.r)<<16)+(Math.round(this.g)<<8)+Math.round(this.b)},e.prototype.clone=function(){return new e(this.toString())},e.prototype.lighten=function(t){void 0===t&&(t=10);var n=this.toHsl();return n.l+=t/100,n.l=(0,i.V2)(n.l),new e(n)},e.prototype.brighten=function(t){void 0===t&&(t=10);var n=this.toRgb();return n.r=Math.max(0,Math.min(255,n.r-Math.round(-(t/100*255)))),n.g=Math.max(0,Math.min(255,n.g-Math.round(-(t/100*255)))),n.b=Math.max(0,Math.min(255,n.b-Math.round(-(t/100*255)))),new e(n)},e.prototype.darken=function(t){void 0===t&&(t=10);var n=this.toHsl();return n.l-=t/100,n.l=(0,i.V2)(n.l),new e(n)},e.prototype.tint=function(e){return void 0===e&&(e=10),this.mix("white",e)},e.prototype.shade=function(e){return void 0===e&&(e=10),this.mix("black",e)},e.prototype.desaturate=function(t){void 0===t&&(t=10);var n=this.toHsl();return n.s-=t/100,n.s=(0,i.V2)(n.s),new e(n)},e.prototype.saturate=function(t){void 0===t&&(t=10);var n=this.toHsl();return n.s+=t/100,n.s=(0,i.V2)(n.s),new e(n)},e.prototype.greyscale=function(){return this.desaturate(100)},e.prototype.spin=function(t){var n=this.toHsl(),r=(n.h+t)%360;return n.h=r<0?360+r:r,new e(n)},e.prototype.mix=function(t,n){void 0===n&&(n=50);var r=this.toRgb(),o=new e(t).toRgb(),a=n/100;return new e({r:(o.r-r.r)*a+r.r,g:(o.g-r.g)*a+r.g,b:(o.b-r.b)*a+r.b,a:(o.a-r.a)*a+r.a})},e.prototype.analogous=function(t,n){void 0===t&&(t=6),void 0===n&&(n=30);var r=this.toHsl(),o=360/n,a=[this];for(r.h=(r.h-(o*t>>1)+720)%360;--t;)r.h=(r.h+o)%360,a.push(new e(r));return a},e.prototype.complement=function(){var t=this.toHsl();return t.h=(t.h+180)%360,new e(t)},e.prototype.monochromatic=function(t){void 0===t&&(t=6);for(var n=this.toHsv(),r=n.h,o=n.s,a=n.v,i=[],c=1/t;t--;)i.push(new e({h:r,s:o,v:a})),a=(a+c)%1;return i},e.prototype.splitcomplement=function(){var t=this.toHsl(),n=t.h;return[this,new e({h:(n+72)%360,s:t.s,l:t.l}),new e({h:(n+216)%360,s:t.s,l:t.l})]},e.prototype.onBackground=function(t){var n=this.toRgb(),r=new e(t).toRgb(),o=n.a+r.a*(1-n.a);return new e({r:(n.r*n.a+r.r*r.a*(1-n.a))/o,g:(n.g*n.a+r.g*r.a*(1-n.a))/o,b:(n.b*n.a+r.b*r.a*(1-n.a))/o,a:o})},e.prototype.triad=function(){return this.polyad(3)},e.prototype.tetrad=function(){return this.polyad(4)},e.prototype.polyad=function(t){for(var n=this.toHsl(),r=n.h,o=[this],a=360/t,i=1;iMath.abs(e-t))?1:e=360===t?(e<0?e%t+t:e%t)/parseFloat(String(t)):e%t/parseFloat(String(t))}function o(e){return Math.min(1,Math.max(0,e))}function a(e){return(isNaN(e=parseFloat(e))||e<0||e>1)&&(e=1),e}function i(e){return e<=1?"".concat(100*Number(e),"%"):e}function c(e){return 1===e.length?"0"+e:String(e)}n.d(t,{FZ:function(){return c},JX:function(){return i},V2:function(){return o},Yq:function(){return a},sh:function(){return r}})},28036:function(e,t,n){"use strict";n.d(t,{Z:function(){return v}});var r=n(26365),o=n(2265),a=n(54887),i=n(94981);n(32559);var c=n(28791),l=o.createContext(null),s=n(83145),u=n(27380),d=[],f=n(21717),p=n(3208),m="rc-util-locker-".concat(Date.now()),g=0,h=function(e){return!1!==e&&((0,i.Z)()&&e?"string"==typeof e?document.querySelector(e):"function"==typeof e?e():e:null)},v=o.forwardRef(function(e,t){var n,v,b,y=e.open,x=e.autoLock,w=e.getContainer,E=(e.debug,e.autoDestroy),S=void 0===E||E,C=e.children,Z=o.useState(y),O=(0,r.Z)(Z,2),k=O[0],M=O[1],R=k||y;o.useEffect(function(){(S||y)&&M(y)},[y,S]);var j=o.useState(function(){return h(w)}),I=(0,r.Z)(j,2),N=I[0],P=I[1];o.useEffect(function(){var e=h(w);P(null!=e?e:null)});var T=function(e,t){var n=o.useState(function(){return(0,i.Z)()?document.createElement("div"):null}),a=(0,r.Z)(n,1)[0],c=o.useRef(!1),f=o.useContext(l),p=o.useState(d),m=(0,r.Z)(p,2),g=m[0],h=m[1],v=f||(c.current?void 0:function(e){h(function(t){return[e].concat((0,s.Z)(t))})});function b(){a.parentElement||document.body.appendChild(a),c.current=!0}function y(){var e;null===(e=a.parentElement)||void 0===e||e.removeChild(a),c.current=!1}return(0,u.Z)(function(){return e?f?f(b):b():y(),y},[e]),(0,u.Z)(function(){g.length&&(g.forEach(function(e){return e()}),h(d))},[g]),[a,v]}(R&&!N,0),F=(0,r.Z)(T,2),A=F[0],z=F[1],L=null!=N?N:A;n=!!(x&&y&&(0,i.Z)()&&(L===A||L===document.body)),v=o.useState(function(){return g+=1,"".concat(m,"_").concat(g)}),b=(0,r.Z)(v,1)[0],(0,u.Z)(function(){if(n){var e=(0,p.o)(document.body).width,t=document.body.scrollHeight>(window.innerHeight||document.documentElement.clientHeight)&&window.innerWidth>document.body.offsetWidth;(0,f.hq)("\nhtml body {\n  overflow-y: hidden;\n  ".concat(t?"width: calc(100% - ".concat(e,"px);"):"","\n}"),b)}else(0,f.jL)(b);return function(){(0,f.jL)(b)}},[n,b]);var _=null;C&&(0,c.Yr)(C)&&t&&(_=C.ref);var H=(0,c.x1)(_,t);if(!R||!(0,i.Z)()||void 0===N)return null;var B=!1===L,D=C;return t&&(D=o.cloneElement(C,{ref:H})),o.createElement(l.Provider,{value:z},B?D:(0,a.createPortal)(D,L))})},97821:function(e,t,n){"use strict";n.d(t,{Z:function(){return D}});var r=n(31686),o=n(26365),a=n(6989),i=n(28036),c=n(36760),l=n.n(c),s=n(31474),u=n(2868),d=n(13211),f=n(58525),p=n(92491),m=n(27380),g=n(79267),h=n(2265),v=n(1119),b=n(47970),y=n(28791);function x(e){var t=e.prefixCls,n=e.align,r=e.arrow,o=e.arrowPos,a=r||{},i=a.className,c=a.content,s=o.x,u=o.y,d=h.useRef();if(!n||!n.points)return null;var f={position:"absolute"};if(!1!==n.autoArrow){var p=n.points[0],m=n.points[1],g=p[0],v=p[1],b=m[0],y=m[1];g!==b&&["t","b"].includes(g)?"t"===g?f.top=0:f.bottom=0:f.top=void 0===u?0:u,v!==y&&["l","r"].includes(v)?"l"===v?f.left=0:f.right=0:f.left=void 0===s?0:s}return h.createElement("div",{ref:d,className:l()("".concat(t,"-arrow"),i),style:f},c)}function w(e){var t=e.prefixCls,n=e.open,r=e.zIndex,o=e.mask,a=e.motion;return o?h.createElement(b.ZP,(0,v.Z)({},a,{motionAppear:!0,visible:n,removeOnLeave:!0}),function(e){var n=e.className;return h.createElement("div",{style:{zIndex:r},className:l()("".concat(t,"-mask"),n)})}):null}var E=h.memo(function(e){return e.children},function(e,t){return t.cache}),S=h.forwardRef(function(e,t){var n=e.popup,a=e.className,i=e.prefixCls,c=e.style,u=e.target,d=e.onVisibleChanged,f=e.open,p=e.keepDom,g=e.fresh,S=e.onClick,C=e.mask,Z=e.arrow,O=e.arrowPos,k=e.align,M=e.motion,R=e.maskMotion,j=e.forceRender,I=e.getPopupContainer,N=e.autoDestroy,P=e.portal,T=e.zIndex,F=e.onMouseEnter,A=e.onMouseLeave,z=e.onPointerEnter,L=e.ready,_=e.offsetX,H=e.offsetY,B=e.offsetR,D=e.offsetB,W=e.onAlign,V=e.onPrepare,q=e.stretch,G=e.targetWidth,X=e.targetHeight,U="function"==typeof n?n():n,K=f||p,$=(null==I?void 0:I.length)>0,Y=h.useState(!I||!$),Q=(0,o.Z)(Y,2),J=Q[0],ee=Q[1];if((0,m.Z)(function(){!J&&$&&u&&ee(!0)},[J,$,u]),!J)return null;var et="auto",en={left:"-1000vw",top:"-1000vh",right:et,bottom:et};if(L||!f){var er,eo=k.points,ea=k.dynamicInset||(null===(er=k._experimental)||void 0===er?void 0:er.dynamicInset),ei=ea&&"r"===eo[0][1],ec=ea&&"b"===eo[0][0];ei?(en.right=B,en.left=et):(en.left=_,en.right=et),ec?(en.bottom=D,en.top=et):(en.top=H,en.bottom=et)}var el={};return q&&(q.includes("height")&&X?el.height=X:q.includes("minHeight")&&X&&(el.minHeight=X),q.includes("width")&&G?el.width=G:q.includes("minWidth")&&G&&(el.minWidth=G)),f||(el.pointerEvents="none"),h.createElement(P,{open:j||K,getContainer:I&&function(){return I(u)},autoDestroy:N},h.createElement(w,{prefixCls:i,open:f,zIndex:T,mask:C,motion:R}),h.createElement(s.Z,{onResize:W,disabled:!f},function(e){return h.createElement(b.ZP,(0,v.Z)({motionAppear:!0,motionEnter:!0,motionLeave:!0,removeOnLeave:!1,forceRender:j,leavedClassName:"".concat(i,"-hidden")},M,{onAppearPrepare:V,onEnterPrepare:V,visible:f,onVisibleChanged:function(e){var t;null==M||null===(t=M.onVisibleChanged)||void 0===t||t.call(M,e),d(e)}}),function(n,o){var s=n.className,u=n.style,d=l()(i,s,a);return h.createElement("div",{ref:(0,y.sQ)(e,t,o),className:d,style:(0,r.Z)((0,r.Z)((0,r.Z)((0,r.Z)({"--arrow-x":"".concat(O.x||0,"px"),"--arrow-y":"".concat(O.y||0,"px")},en),el),u),{},{boxSizing:"border-box",zIndex:T},c),onMouseEnter:F,onMouseLeave:A,onPointerEnter:z,onClick:S},Z&&h.createElement(x,{prefixCls:i,arrow:Z,arrowPos:O,align:k}),h.createElement(E,{cache:!f&&!g},U))})}))}),C=h.forwardRef(function(e,t){var n=e.children,r=e.getTriggerDOMNode,o=(0,y.Yr)(n),a=h.useCallback(function(e){(0,y.mH)(t,r?r(e):e)},[r]),i=(0,y.x1)(a,n.ref);return o?h.cloneElement(n,{ref:i}):n}),Z=h.createContext(null);function O(e){return e?Array.isArray(e)?e:[e]:[]}var k=n(2857);function M(e,t,n,r){return t||(n?{motionName:"".concat(e,"-").concat(n)}:r?{motionName:r}:null)}function R(e){return e.ownerDocument.defaultView}function j(e){for(var t=[],n=null==e?void 0:e.parentElement,r=["hidden","scroll","clip","auto"];n;){var o=R(n).getComputedStyle(n);[o.overflowX,o.overflowY,o.overflow].some(function(e){return r.includes(e)})&&t.push(n),n=n.parentElement}return t}function I(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return Number.isNaN(e)?t:e}function N(e){return I(parseFloat(e),0)}function P(e,t){var n=(0,r.Z)({},e);return(t||[]).forEach(function(e){if(!(e instanceof HTMLBodyElement||e instanceof HTMLHtmlElement)){var t=R(e).getComputedStyle(e),r=t.overflow,o=t.overflowClipMargin,a=t.borderTopWidth,i=t.borderBottomWidth,c=t.borderLeftWidth,l=t.borderRightWidth,s=e.getBoundingClientRect(),u=e.offsetHeight,d=e.clientHeight,f=e.offsetWidth,p=e.clientWidth,m=N(a),g=N(i),h=N(c),v=N(l),b=I(Math.round(s.width/f*1e3)/1e3),y=I(Math.round(s.height/u*1e3)/1e3),x=m*y,w=h*b,E=0,S=0;if("clip"===r){var C=N(o);E=C*b,S=C*y}var Z=s.x+w-E,O=s.y+x-S,k=Z+s.width+2*E-w-v*b-(f-p-h-v)*b,M=O+s.height+2*S-x-g*y-(u-d-m-g)*y;n.left=Math.max(n.left,Z),n.top=Math.max(n.top,O),n.right=Math.min(n.right,k),n.bottom=Math.min(n.bottom,M)}}),n}function T(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n="".concat(t),r=n.match(/^(.*)\%$/);return r?parseFloat(r[1])/100*e:parseFloat(n)}function F(e,t){var n=(0,o.Z)(t||[],2),r=n[0],a=n[1];return[T(e.width,r),T(e.height,a)]}function A(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return[e[0],e[1]]}function z(e,t){var n,r=t[0],o=t[1];return n="t"===r?e.y:"b"===r?e.y+e.height:e.y+e.height/2,{x:"l"===o?e.x:"r"===o?e.x+e.width:e.x+e.width/2,y:n}}function L(e,t){var n={t:"b",b:"t",l:"r",r:"l"};return e.map(function(e,r){return r===t?n[e]||"c":e}).join("")}var _=n(83145);n(32559);var H=n(53346),B=["prefixCls","children","action","showAction","hideAction","popupVisible","defaultPopupVisible","onPopupVisibleChange","afterPopupVisibleChange","mouseEnterDelay","mouseLeaveDelay","focusDelay","blurDelay","mask","maskClosable","getPopupContainer","forceRender","autoDestroy","destroyPopupOnHide","popup","popupClassName","popupStyle","popupPlacement","builtinPlacements","popupAlign","zIndex","stretch","getPopupClassNameFromAlign","fresh","alignPoint","onPopupClick","onPopupAlign","arrow","popupMotion","maskMotion","popupTransitionName","popupAnimation","maskTransitionName","maskAnimation","className","getTriggerDOMNode"],D=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:i.Z;return h.forwardRef(function(t,n){var i,c,v,b,y,x,w,E,N,T,D,W,V,q,G,X,U,K=t.prefixCls,$=void 0===K?"rc-trigger-popup":K,Y=t.children,Q=t.action,J=t.showAction,ee=t.hideAction,et=t.popupVisible,en=t.defaultPopupVisible,er=t.onPopupVisibleChange,eo=t.afterPopupVisibleChange,ea=t.mouseEnterDelay,ei=t.mouseLeaveDelay,ec=void 0===ei?.1:ei,el=t.focusDelay,es=t.blurDelay,eu=t.mask,ed=t.maskClosable,ef=t.getPopupContainer,ep=t.forceRender,em=t.autoDestroy,eg=t.destroyPopupOnHide,eh=t.popup,ev=t.popupClassName,eb=t.popupStyle,ey=t.popupPlacement,ex=t.builtinPlacements,ew=void 0===ex?{}:ex,eE=t.popupAlign,eS=t.zIndex,eC=t.stretch,eZ=t.getPopupClassNameFromAlign,eO=t.fresh,ek=t.alignPoint,eM=t.onPopupClick,eR=t.onPopupAlign,ej=t.arrow,eI=t.popupMotion,eN=t.maskMotion,eP=t.popupTransitionName,eT=t.popupAnimation,eF=t.maskTransitionName,eA=t.maskAnimation,ez=t.className,eL=t.getTriggerDOMNode,e_=(0,a.Z)(t,B),eH=h.useState(!1),eB=(0,o.Z)(eH,2),eD=eB[0],eW=eB[1];(0,m.Z)(function(){eW((0,g.Z)())},[]);var eV=h.useRef({}),eq=h.useContext(Z),eG=h.useMemo(function(){return{registerSubPopup:function(e,t){eV.current[e]=t,null==eq||eq.registerSubPopup(e,t)}}},[eq]),eX=(0,p.Z)(),eU=h.useState(null),eK=(0,o.Z)(eU,2),e$=eK[0],eY=eK[1],eQ=(0,f.Z)(function(e){(0,u.S)(e)&&e$!==e&&eY(e),null==eq||eq.registerSubPopup(eX,e)}),eJ=h.useState(null),e0=(0,o.Z)(eJ,2),e1=e0[0],e2=e0[1],e6=h.useRef(null),e5=(0,f.Z)(function(e){(0,u.S)(e)&&e1!==e&&(e2(e),e6.current=e)}),e4=h.Children.only(Y),e3=(null==e4?void 0:e4.props)||{},e8={},e9=(0,f.Z)(function(e){var t,n;return(null==e1?void 0:e1.contains(e))||(null===(t=(0,d.A)(e1))||void 0===t?void 0:t.host)===e||e===e1||(null==e$?void 0:e$.contains(e))||(null===(n=(0,d.A)(e$))||void 0===n?void 0:n.host)===e||e===e$||Object.values(eV.current).some(function(t){return(null==t?void 0:t.contains(e))||e===t})}),e7=M($,eI,eT,eP),te=M($,eN,eA,eF),tt=h.useState(en||!1),tn=(0,o.Z)(tt,2),tr=tn[0],to=tn[1],ta=null!=et?et:tr,ti=(0,f.Z)(function(e){void 0===et&&to(e)});(0,m.Z)(function(){to(et||!1)},[et]);var tc=h.useRef(ta);tc.current=ta;var tl=h.useRef([]);tl.current=[];var ts=(0,f.Z)(function(e){var t;ti(e),(null!==(t=tl.current[tl.current.length-1])&&void 0!==t?t:ta)!==e&&(tl.current.push(e),null==er||er(e))}),tu=h.useRef(),td=function(){clearTimeout(tu.current)},tf=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;td(),0===t?ts(e):tu.current=setTimeout(function(){ts(e)},1e3*t)};h.useEffect(function(){return td},[]);var tp=h.useState(!1),tm=(0,o.Z)(tp,2),tg=tm[0],th=tm[1];(0,m.Z)(function(e){(!e||ta)&&th(!0)},[ta]);var tv=h.useState(null),tb=(0,o.Z)(tv,2),ty=tb[0],tx=tb[1],tw=h.useState([0,0]),tE=(0,o.Z)(tw,2),tS=tE[0],tC=tE[1],tZ=function(e){tC([e.clientX,e.clientY])},tO=(i=ek?tS:e1,c=h.useState({ready:!1,offsetX:0,offsetY:0,offsetR:0,offsetB:0,arrowX:0,arrowY:0,scaleX:1,scaleY:1,align:ew[ey]||{}}),b=(v=(0,o.Z)(c,2))[0],y=v[1],x=h.useRef(0),w=h.useMemo(function(){return e$?j(e$):[]},[e$]),E=h.useRef({}),ta||(E.current={}),N=(0,f.Z)(function(){if(e$&&i&&ta){var e,t,n,a,c,l,s,d=e$.ownerDocument,f=R(e$).getComputedStyle(e$),p=f.width,m=f.height,g=f.position,h=e$.style.left,v=e$.style.top,b=e$.style.right,x=e$.style.bottom,S=e$.style.overflow,C=(0,r.Z)((0,r.Z)({},ew[ey]),eE),Z=d.createElement("div");if(null===(e=e$.parentElement)||void 0===e||e.appendChild(Z),Z.style.left="".concat(e$.offsetLeft,"px"),Z.style.top="".concat(e$.offsetTop,"px"),Z.style.position=g,Z.style.height="".concat(e$.offsetHeight,"px"),Z.style.width="".concat(e$.offsetWidth,"px"),e$.style.left="0",e$.style.top="0",e$.style.right="auto",e$.style.bottom="auto",e$.style.overflow="hidden",Array.isArray(i))n={x:i[0],y:i[1],width:0,height:0};else{var O=i.getBoundingClientRect();n={x:O.x,y:O.y,width:O.width,height:O.height}}var M=e$.getBoundingClientRect(),j=d.documentElement,N=j.clientWidth,T=j.clientHeight,_=j.scrollWidth,H=j.scrollHeight,B=j.scrollTop,D=j.scrollLeft,W=M.height,V=M.width,q=n.height,G=n.width,X=C.htmlRegion,U="visible",K="visibleFirst";"scroll"!==X&&X!==K&&(X=U);var $=X===K,Y=P({left:-D,top:-B,right:_-D,bottom:H-B},w),Q=P({left:0,top:0,right:N,bottom:T},w),J=X===U?Q:Y,ee=$?Q:J;e$.style.left="auto",e$.style.top="auto",e$.style.right="0",e$.style.bottom="0";var et=e$.getBoundingClientRect();e$.style.left=h,e$.style.top=v,e$.style.right=b,e$.style.bottom=x,e$.style.overflow=S,null===(t=e$.parentElement)||void 0===t||t.removeChild(Z);var en=I(Math.round(V/parseFloat(p)*1e3)/1e3),er=I(Math.round(W/parseFloat(m)*1e3)/1e3);if(!(0===en||0===er||(0,u.S)(i)&&!(0,k.Z)(i))){var eo=C.offset,ea=C.targetOffset,ei=F(M,eo),ec=(0,o.Z)(ei,2),el=ec[0],es=ec[1],eu=F(n,ea),ed=(0,o.Z)(eu,2),ef=ed[0],ep=ed[1];n.x-=ef,n.y-=ep;var em=C.points||[],eg=(0,o.Z)(em,2),eh=eg[0],ev=A(eg[1]),eb=A(eh),ex=z(n,ev),eS=z(M,eb),eC=(0,r.Z)({},C),eZ=ex.x-eS.x+el,eO=ex.y-eS.y+es,ek=tt(eZ,eO),eM=tt(eZ,eO,Q),ej=z(n,["t","l"]),eI=z(M,["t","l"]),eN=z(n,["b","r"]),eP=z(M,["b","r"]),eT=C.overflow||{},eF=eT.adjustX,eA=eT.adjustY,ez=eT.shiftX,eL=eT.shiftY,e_=function(e){return"boolean"==typeof e?e:e>=0};tn();var eH=e_(eA),eB=eb[0]===ev[0];if(eH&&"t"===eb[0]&&(c>ee.bottom||E.current.bt)){var eD=eO;eB?eD-=W-q:eD=ej.y-eP.y-es;var eW=tt(eZ,eD),eV=tt(eZ,eD,Q);eW>ek||eW===ek&&(!$||eV>=eM)?(E.current.bt=!0,eO=eD,es=-es,eC.points=[L(eb,0),L(ev,0)]):E.current.bt=!1}if(eH&&"b"===eb[0]&&(aek||eG===ek&&(!$||eX>=eM)?(E.current.tb=!0,eO=eq,es=-es,eC.points=[L(eb,0),L(ev,0)]):E.current.tb=!1}var eU=e_(eF),eK=eb[1]===ev[1];if(eU&&"l"===eb[1]&&(s>ee.right||E.current.rl)){var eY=eZ;eK?eY-=V-G:eY=ej.x-eP.x-el;var eQ=tt(eY,eO),eJ=tt(eY,eO,Q);eQ>ek||eQ===ek&&(!$||eJ>=eM)?(E.current.rl=!0,eZ=eY,el=-el,eC.points=[L(eb,1),L(ev,1)]):E.current.rl=!1}if(eU&&"r"===eb[1]&&(lek||e1===ek&&(!$||e2>=eM)?(E.current.lr=!0,eZ=e0,el=-el,eC.points=[L(eb,1),L(ev,1)]):E.current.lr=!1}tn();var e6=!0===ez?0:ez;"number"==typeof e6&&(lQ.right&&(eZ-=s-Q.right-el,n.x>Q.right-e6&&(eZ+=n.x-Q.right+e6)));var e5=!0===eL?0:eL;"number"==typeof e5&&(aQ.bottom&&(eO-=c-Q.bottom-es,n.y>Q.bottom-e5&&(eO+=n.y-Q.bottom+e5)));var e4=M.x+eZ,e3=M.y+eO,e8=n.x,e9=n.y;null==eR||eR(e$,eC);var e7=et.right-M.x-(eZ+M.width),te=et.bottom-M.y-(eO+M.height);y({ready:!0,offsetX:eZ/en,offsetY:eO/er,offsetR:e7/en,offsetB:te/er,arrowX:((Math.max(e4,e8)+Math.min(e4+V,e8+G))/2-e4)/en,arrowY:((Math.max(e3,e9)+Math.min(e3+W,e9+q))/2-e3)/er,scaleX:en,scaleY:er,align:eC})}function tt(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:J,r=M.x+e,o=M.y+t,a=Math.max(r,n.left),i=Math.max(o,n.top);return Math.max(0,(Math.min(r+V,n.right)-a)*(Math.min(o+W,n.bottom)-i))}function tn(){c=(a=M.y+eO)+W,s=(l=M.x+eZ)+V}}}),T=function(){y(function(e){return(0,r.Z)((0,r.Z)({},e),{},{ready:!1})})},(0,m.Z)(T,[ey]),(0,m.Z)(function(){ta||T()},[ta]),[b.ready,b.offsetX,b.offsetY,b.offsetR,b.offsetB,b.arrowX,b.arrowY,b.scaleX,b.scaleY,b.align,function(){x.current+=1;var e=x.current;Promise.resolve().then(function(){x.current===e&&N()})}]),tk=(0,o.Z)(tO,11),tM=tk[0],tR=tk[1],tj=tk[2],tI=tk[3],tN=tk[4],tP=tk[5],tT=tk[6],tF=tk[7],tA=tk[8],tz=tk[9],tL=tk[10],t_=(D=void 0===Q?"hover":Q,h.useMemo(function(){var e=O(null!=J?J:D),t=O(null!=ee?ee:D),n=new Set(e),r=new Set(t);return eD&&(n.has("hover")&&(n.delete("hover"),n.add("click")),r.has("hover")&&(r.delete("hover"),r.add("click"))),[n,r]},[eD,D,J,ee])),tH=(0,o.Z)(t_,2),tB=tH[0],tD=tH[1],tW=tB.has("click"),tV=tD.has("click")||tD.has("contextMenu"),tq=(0,f.Z)(function(){tg||tL()});W=function(){tc.current&&ek&&tV&&tf(!1)},(0,m.Z)(function(){if(ta&&e1&&e$){var e=j(e1),t=j(e$),n=R(e$),r=new Set([n].concat((0,_.Z)(e),(0,_.Z)(t)));function o(){tq(),W()}return r.forEach(function(e){e.addEventListener("scroll",o,{passive:!0})}),n.addEventListener("resize",o,{passive:!0}),tq(),function(){r.forEach(function(e){e.removeEventListener("scroll",o),n.removeEventListener("resize",o)})}}},[ta,e1,e$]),(0,m.Z)(function(){tq()},[tS,ey]),(0,m.Z)(function(){ta&&!(null!=ew&&ew[ey])&&tq()},[JSON.stringify(eE)]);var tG=h.useMemo(function(){var e=function(e,t,n,r){for(var o=n.points,a=Object.keys(e),i=0;i0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2?arguments[2]:void 0;return n?e[0]===t[0]:e[0]===t[0]&&e[1]===t[1]}(null===(c=e[l])||void 0===c?void 0:c.points,o,r))return"".concat(t,"-placement-").concat(l)}return""}(ew,$,tz,ek);return l()(e,null==eZ?void 0:eZ(tz))},[tz,eZ,ew,$,ek]);h.useImperativeHandle(n,function(){return{nativeElement:e6.current,forceAlign:tq}});var tX=h.useState(0),tU=(0,o.Z)(tX,2),tK=tU[0],t$=tU[1],tY=h.useState(0),tQ=(0,o.Z)(tY,2),tJ=tQ[0],t0=tQ[1],t1=function(){if(eC&&e1){var e=e1.getBoundingClientRect();t$(e.width),t0(e.height)}};function t2(e,t,n,r){e8[e]=function(o){var a;null==r||r(o),tf(t,n);for(var i=arguments.length,c=Array(i>1?i-1:0),l=1;l1?n-1:0),o=1;o1?n-1:0),o=1;o{var t=(0,r._T)(e,[]);return o.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"},t),o.createElement("path",{d:"M12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12C22 17.5228 17.5228 22 12 22ZM11 15V17H13V15H11ZM11 7V13H13V7H11Z"}))},i=e=>{var t=(0,r._T)(e,[]);return o.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"},t),o.createElement("path",{d:"M1.18164 12C2.12215 6.87976 6.60812 3 12.0003 3C17.3924 3 21.8784 6.87976 22.8189 12C21.8784 17.1202 17.3924 21 12.0003 21C6.60812 21 2.12215 17.1202 1.18164 12ZM12.0003 17C14.7617 17 17.0003 14.7614 17.0003 12C17.0003 9.23858 14.7617 7 12.0003 7C9.23884 7 7.00026 9.23858 7.00026 12C7.00026 14.7614 9.23884 17 12.0003 17ZM12.0003 15C10.3434 15 9.00026 13.6569 9.00026 12C9.00026 10.3431 10.3434 9 12.0003 9C13.6571 9 15.0003 10.3431 15.0003 12C15.0003 13.6569 13.6571 15 12.0003 15Z"}))},c=e=>{var t=(0,r._T)(e,[]);return o.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"},t),o.createElement("path",{d:"M4.52047 5.93457L1.39366 2.80777L2.80788 1.39355L22.6069 21.1925L21.1927 22.6068L17.8827 19.2968C16.1814 20.3755 14.1638 21.0002 12.0003 21.0002C6.60812 21.0002 2.12215 17.1204 1.18164 12.0002C1.61832 9.62282 2.81932 7.5129 4.52047 5.93457ZM14.7577 16.1718L13.2937 14.7078C12.902 14.8952 12.4634 15.0002 12.0003 15.0002C10.3434 15.0002 9.00026 13.657 9.00026 12.0002C9.00026 11.537 9.10522 11.0984 9.29263 10.7067L7.82866 9.24277C7.30514 10.0332 7.00026 10.9811 7.00026 12.0002C7.00026 14.7616 9.23884 17.0002 12.0003 17.0002C13.0193 17.0002 13.9672 16.6953 14.7577 16.1718ZM7.97446 3.76015C9.22127 3.26959 10.5793 3.00016 12.0003 3.00016C17.3924 3.00016 21.8784 6.87992 22.8189 12.0002C22.5067 13.6998 21.8038 15.2628 20.8068 16.5925L16.947 12.7327C16.9821 12.4936 17.0003 12.249 17.0003 12.0002C17.0003 9.23873 14.7617 7.00016 12.0003 7.00016C11.7514 7.00016 11.5068 7.01833 11.2677 7.05343L7.97446 3.76015Z"}))};var l=n(96398),s=n(97324),u=n(1153);let d=o.forwardRef((e,t)=>{let{value:n,defaultValue:d,type:f,placeholder:p="Type...",icon:m,error:g=!1,errorMessage:h,disabled:v=!1,stepper:b,makeInputClassName:y,className:x,onChange:w,onValueChange:E,autoFocus:S}=e,C=(0,r._T)(e,["value","defaultValue","type","placeholder","icon","error","errorMessage","disabled","stepper","makeInputClassName","className","onChange","onValueChange","autoFocus"]),[Z,O]=(0,o.useState)(S||!1),[k,M]=(0,o.useState)(!1),R=(0,o.useCallback)(()=>M(!k),[k,M]),j=(0,o.useRef)(null),I=(0,l.Uh)(n||d);return o.useEffect(()=>{let e=()=>O(!0),t=()=>O(!1),n=j.current;return n&&(n.addEventListener("focus",e),n.addEventListener("blur",t),S&&n.focus()),()=>{n&&(n.removeEventListener("focus",e),n.removeEventListener("blur",t))}},[S]),o.createElement(o.Fragment,null,o.createElement("div",{className:(0,s.q)(y("root"),"relative w-full flex items-center min-w-[10rem] outline-none rounded-tremor-default transition duration-100 border","shadow-tremor-input","dark:shadow-dark-tremor-input",(0,l.um)(I,v,g),Z&&(0,s.q)("ring-2","border-tremor-brand-subtle ring-tremor-brand-muted","dark:border-dark-tremor-brand-subtle dark:ring-dark-tremor-brand-muted"),x)},m?o.createElement(m,{className:(0,s.q)(y("icon"),"shrink-0 h-5 w-5 ml-2.5","text-tremor-content-subtle","dark:text-dark-tremor-content-subtle")}):null,o.createElement("input",Object.assign({ref:(0,u.lq)([j,t]),defaultValue:d,value:n,type:k?"text":f,className:(0,s.q)(y("input"),"w-full focus:outline-none focus:ring-0 border-none bg-transparent text-tremor-default rounded-tremor-default transition duration-100 py-2","text-tremor-content-emphasis","dark:text-dark-tremor-content-emphasis","[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none",m?"pl-2":"pl-3",g?"pr-3":"pr-4",v?"placeholder:text-tremor-content-subtle dark:placeholder:text-dark-tremor-content-subtle":"placeholder:text-tremor-content dark:placeholder:text-dark-tremor-content"),placeholder:p,disabled:v,"data-testid":"base-input",onChange:e=>{null==w||w(e),null==E||E(e.target.value)}},C)),"password"!==f||v?null:o.createElement("button",{className:(0,s.q)(y("toggleButton"),"mr-2"),type:"button",onClick:()=>R(),"aria-label":k?"Hide password":"Show Password"},k?o.createElement(c,{className:(0,s.q)("flex-none h-5 w-5 transition","text-tremor-content-subtle hover:text-tremor-content","dark:text-dark-tremor-content-subtle hover:dark:text-dark-tremor-content"),"aria-hidden":!0}):o.createElement(i,{className:(0,s.q)("flex-none h-5 w-5 transition","text-tremor-content-subtle hover:text-tremor-content","dark:text-dark-tremor-content-subtle hover:dark:text-dark-tremor-content"),"aria-hidden":!0})),g?o.createElement(a,{className:(0,s.q)(y("errorIcon"),"text-red-500 shrink-0 w-5 h-5 mr-2.5")}):null,null!=b?b:null),g&&h?o.createElement("p",{className:(0,s.q)(y("errorMessage"),"text-sm text-red-500 mt-1")},h):null)});d.displayName="BaseInput"},20831:function(e,t,n){"use strict";n.d(t,{Z:function(){return C}});var r=n(5853),o=n(1526),a=n(2265);let i=["preEnter","entering","entered","preExit","exiting","exited","unmounted"],c=e=>({_s:e,status:i[e],isEnter:e<3,isMounted:6!==e,isResolved:2===e||e>4}),l=e=>e?6:5,s=(e,t)=>{switch(e){case 1:case 0:return 2;case 4:case 3:return l(t)}},u=e=>"object"==typeof e?[e.enter,e.exit]:[e,e],d=(e,t)=>setTimeout(()=>{isNaN(document.body.offsetTop)||e(t+1)},0),f=(e,t,n,r,o)=>{clearTimeout(r.current);let a=c(e);t(a),n.current=a,o&&o({current:a})},p=({enter:e=!0,exit:t=!0,preEnter:n,preExit:r,timeout:o,initialEntered:i,mountOnEnter:p,unmountOnExit:m,onStateChange:g}={})=>{let[h,v]=(0,a.useState)(()=>c(i?2:l(p))),b=(0,a.useRef)(h),y=(0,a.useRef)(),[x,w]=u(o),E=(0,a.useCallback)(()=>{let e=s(b.current._s,m);e&&f(e,v,b,y,g)},[g,m]),S=(0,a.useCallback)(o=>{let a=e=>{switch(f(e,v,b,y,g),e){case 1:x>=0&&(y.current=setTimeout(E,x));break;case 4:w>=0&&(y.current=setTimeout(E,w));break;case 0:case 3:y.current=d(a,e)}},i=b.current.isEnter;"boolean"!=typeof o&&(o=!i),o?i||a(e?n?0:1:2):i&&a(t?r?3:4:l(m))},[E,g,e,t,n,r,x,w,m]);return(0,a.useEffect)(()=>()=>clearTimeout(y.current),[]),[h,S,E]};var m=n(7084),g=n(97324),h=n(1153);let v=e=>{var t=(0,r._T)(e,[]);return a.createElement("svg",Object.assign({},t,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor"}),a.createElement("path",{fill:"none",d:"M0 0h24v24H0z"}),a.createElement("path",{d:"M18.364 5.636L16.95 7.05A7 7 0 1 0 19 12h2a9 9 0 1 1-2.636-6.364z"}))};var b=n(26898);let y={xs:{height:"h-4",width:"w-4"},sm:{height:"h-5",width:"w-5"},md:{height:"h-5",width:"w-5"},lg:{height:"h-6",width:"w-6"},xl:{height:"h-6",width:"w-6"}},x=e=>"light"!==e?{xs:{paddingX:"px-2.5",paddingY:"py-1.5",fontSize:"text-xs"},sm:{paddingX:"px-4",paddingY:"py-2",fontSize:"text-sm"},md:{paddingX:"px-4",paddingY:"py-2",fontSize:"text-md"},lg:{paddingX:"px-4",paddingY:"py-2.5",fontSize:"text-lg"},xl:{paddingX:"px-4",paddingY:"py-3",fontSize:"text-xl"}}:{xs:{paddingX:"",paddingY:"",fontSize:"text-xs"},sm:{paddingX:"",paddingY:"",fontSize:"text-sm"},md:{paddingX:"",paddingY:"",fontSize:"text-md"},lg:{paddingX:"",paddingY:"",fontSize:"text-lg"},xl:{paddingX:"",paddingY:"",fontSize:"text-xl"}},w=(e,t)=>{switch(e){case"primary":return{textColor:t?(0,h.bM)("white").textColor:"text-tremor-brand-inverted dark:text-dark-tremor-brand-inverted",hoverTextColor:t?(0,h.bM)("white").textColor:"text-tremor-brand-inverted dark:text-dark-tremor-brand-inverted",bgColor:t?(0,h.bM)(t,b.K.background).bgColor:"bg-tremor-brand dark:bg-dark-tremor-brand",hoverBgColor:t?(0,h.bM)(t,b.K.darkBackground).hoverBgColor:"hover:bg-tremor-brand-emphasis dark:hover:bg-dark-tremor-brand-emphasis",borderColor:t?(0,h.bM)(t,b.K.border).borderColor:"border-tremor-brand dark:border-dark-tremor-brand",hoverBorderColor:t?(0,h.bM)(t,b.K.darkBorder).hoverBorderColor:"hover:border-tremor-brand-emphasis dark:hover:border-dark-tremor-brand-emphasis"};case"secondary":return{textColor:t?(0,h.bM)(t,b.K.text).textColor:"text-tremor-brand dark:text-dark-tremor-brand",hoverTextColor:t?(0,h.bM)(t,b.K.text).textColor:"hover:text-tremor-brand-emphasis dark:hover:text-dark-tremor-brand-emphasis",bgColor:(0,h.bM)("transparent").bgColor,hoverBgColor:t?(0,g.q)((0,h.bM)(t,b.K.background).hoverBgColor,"hover:bg-opacity-20 dark:hover:bg-opacity-20"):"hover:bg-tremor-brand-faint dark:hover:bg-dark-tremor-brand-faint",borderColor:t?(0,h.bM)(t,b.K.border).borderColor:"border-tremor-brand dark:border-dark-tremor-brand"};case"light":return{textColor:t?(0,h.bM)(t,b.K.text).textColor:"text-tremor-brand dark:text-dark-tremor-brand",hoverTextColor:t?(0,h.bM)(t,b.K.darkText).hoverTextColor:"hover:text-tremor-brand-emphasis dark:hover:text-dark-tremor-brand-emphasis",bgColor:(0,h.bM)("transparent").bgColor,borderColor:"",hoverBorderColor:""}}},E=(0,h.fn)("Button"),S=e=>{let{loading:t,iconSize:n,iconPosition:r,Icon:o,needMargin:i,transitionStatus:c}=e,l=i?r===m.zS.Left?(0,g.q)("-ml-1","mr-1.5"):(0,g.q)("-mr-1","ml-1.5"):"",s=(0,g.q)("w-0 h-0"),u={default:s,entering:s,entered:n,exiting:n,exited:s};return t?a.createElement(v,{className:(0,g.q)(E("icon"),"animate-spin shrink-0",l,u.default,u[c]),style:{transition:"width 150ms"}}):a.createElement(o,{className:(0,g.q)(E("icon"),"shrink-0",n,l)})},C=a.forwardRef((e,t)=>{let{icon:n,iconPosition:i=m.zS.Left,size:c=m.u8.SM,color:l,variant:s="primary",disabled:u,loading:d=!1,loadingText:f,children:v,tooltip:b,className:C}=e,Z=(0,r._T)(e,["icon","iconPosition","size","color","variant","disabled","loading","loadingText","children","tooltip","className"]),O=d||u,k=void 0!==n||d,M=d&&f,R=!(!v&&!M),j=(0,g.q)(y[c].height,y[c].width),I="light"!==s?(0,g.q)("rounded-tremor-default border","shadow-tremor-input","dark:shadow-dark-tremor-input"):"",N=w(s,l),P=x(s)[c],{tooltipProps:T,getReferenceProps:F}=(0,o.l)(300),[A,z]=p({timeout:50});return(0,a.useEffect)(()=>{z(d)},[d]),a.createElement("button",Object.assign({ref:(0,h.lq)([t,T.refs.setReference]),className:(0,g.q)(E("root"),"flex-shrink-0 inline-flex justify-center items-center group font-medium outline-none",I,P.paddingX,P.paddingY,P.fontSize,N.textColor,N.bgColor,N.borderColor,N.hoverBorderColor,O?"opacity-50 cursor-not-allowed":(0,g.q)(w(s,l).hoverTextColor,w(s,l).hoverBgColor,w(s,l).hoverBorderColor),C),disabled:O},F,Z),a.createElement(o.Z,Object.assign({text:b},T)),k&&i!==m.zS.Right?a.createElement(S,{loading:d,iconSize:j,iconPosition:i,Icon:n,transitionStatus:A.status,needMargin:R}):null,M||v?a.createElement("span",{className:(0,g.q)(E("text"),"text-tremor-default whitespace-nowrap")},M?f:v):null,k&&i===m.zS.Right?a.createElement(S,{loading:d,iconSize:j,iconPosition:i,Icon:n,transitionStatus:A.status,needMargin:R}):null)});C.displayName="Button"},49566:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(5853),o=n(2265);n(97324);var a=n(1153),i=n(69262);let c=(0,a.fn)("TextInput"),l=o.forwardRef((e,t)=>{let{type:n="text"}=e,a=(0,r._T)(e,["type"]);return o.createElement(i.Z,Object.assign({ref:t,type:n,makeInputClassName:c},a))});l.displayName="TextInput"},96398:function(e,t,n){"use strict";n.d(t,{Uh:function(){return s},n0:function(){return c},qg:function(){return a},sl:function(){return i},um:function(){return l}});var r=n(97324),o=n(2265);let a=e=>["string","number"].includes(typeof e)?e:e instanceof Array?e.map(a).join(""):"object"==typeof e&&e?a(e.props.children):void 0;function i(e){let t=new Map;return o.Children.map(e,e=>{var n;t.set(e.props.value,null!==(n=a(e))&&void 0!==n?n:e.props.value)}),t}function c(e,t){return o.Children.map(t,t=>{var n;if((null!==(n=a(t))&&void 0!==n?n:t.props.value).toLowerCase().includes(e.toLowerCase()))return t})}let l=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return(0,r.q)(t?"bg-tremor-background-subtle dark:bg-dark-tremor-background-subtle":"bg-tremor-background dark:bg-dark-tremor-background",!t&&"hover:bg-tremor-background-muted dark:hover:bg-dark-tremor-background-muted",e?"text-tremor-content-emphasis dark:text-dark-tremor-content-emphasis":"text-tremor-content dark:text-dark-tremor-content",t&&"text-tremor-content-subtle dark:text-dark-tremor-content-subtle",n&&"text-red-500",n?"border-red-500":"border-tremor-border dark:border-dark-tremor-border")};function s(e){return null!=e&&""!==e}},12514:function(e,t,n){"use strict";n.d(t,{Z:function(){return d}});var r=n(5853),o=n(2265),a=n(7084),i=n(26898),c=n(97324),l=n(1153);let s=(0,l.fn)("Card"),u=e=>{if(!e)return"";switch(e){case a.zS.Left:return"border-l-4";case a.m.Top:return"border-t-4";case a.zS.Right:return"border-r-4";case a.m.Bottom:return"border-b-4";default:return""}},d=o.forwardRef((e,t)=>{let{decoration:n="",decorationColor:a,children:d,className:f}=e,p=(0,r._T)(e,["decoration","decorationColor","children","className"]);return o.createElement("div",Object.assign({ref:t,className:(0,c.q)(s("root"),"relative w-full text-left ring-1 rounded-tremor-default p-6","bg-tremor-background ring-tremor-ring shadow-tremor-card","dark:bg-dark-tremor-background dark:ring-dark-tremor-ring dark:shadow-dark-tremor-card",a?(0,l.bM)(a,i.K.border).borderColor:"border-tremor-brand dark:border-dark-tremor-brand",u(n),f)},p),d)});d.displayName="Card"},84264:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(26898),o=n(97324),a=n(1153),i=n(2265);let c=i.forwardRef((e,t)=>{let{color:n,className:c,children:l}=e;return i.createElement("p",{ref:t,className:(0,o.q)("text-tremor-default",n?(0,a.bM)(n,r.K.text).textColor:(0,o.q)("text-tremor-content","dark:text-dark-tremor-content"),c)},l)});c.displayName="Text"},96761:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(5853),o=n(26898),a=n(97324),i=n(1153),c=n(2265);let l=c.forwardRef((e,t)=>{let{color:n,children:l,className:s}=e,u=(0,r._T)(e,["color","children","className"]);return c.createElement("p",Object.assign({ref:t,className:(0,a.q)("font-medium text-tremor-title",n?(0,i.bM)(n,o.K.darkText).textColor:"text-tremor-content-emphasis dark:text-dark-tremor-content-emphasis",s)},u),l)});l.displayName="Title"},1526:function(e,t,n){"use strict";n.d(t,{Z:function(){return eH},l:function(){return e_}});var r=n(2265),o=n.t(r,2),a=n(54887);function i(e){return s(e)?(e.nodeName||"").toLowerCase():"#document"}function c(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function l(e){var t;return null==(t=(s(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function s(e){return e instanceof Node||e instanceof c(e).Node}function u(e){return e instanceof Element||e instanceof c(e).Element}function d(e){return e instanceof HTMLElement||e instanceof c(e).HTMLElement}function f(e){return"undefined"!=typeof ShadowRoot&&(e instanceof ShadowRoot||e instanceof c(e).ShadowRoot)}function p(e){let{overflow:t,overflowX:n,overflowY:r,display:o}=b(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function m(e){let t=h(),n=b(e);return"none"!==n.transform||"none"!==n.perspective||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","perspective","filter"].some(e=>(n.willChange||"").includes(e))||["paint","layout","strict","content"].some(e=>(n.contain||"").includes(e))}function g(e){let t=x(e);for(;d(t)&&!v(t);){if(m(t))return t;t=x(t)}return null}function h(){return"undefined"!=typeof CSS&&!!CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")}function v(e){return["html","body","#document"].includes(i(e))}function b(e){return c(e).getComputedStyle(e)}function y(e){return u(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function x(e){if("html"===i(e))return e;let t=e.assignedSlot||e.parentNode||f(e)&&e.host||l(e);return f(t)?t.host:t}function w(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);let o=function e(t){let n=x(t);return v(n)?t.ownerDocument?t.ownerDocument.body:t.body:d(n)&&p(n)?n:e(n)}(e),a=o===(null==(r=e.ownerDocument)?void 0:r.body),i=c(o);return a?t.concat(i,i.visualViewport||[],p(o)?o:[],i.frameElement&&n?w(i.frameElement):[]):t.concat(o,w(o,[],n))}let E=Math.min,S=Math.max,C=Math.round,Z=Math.floor,O=e=>({x:e,y:e}),k={left:"right",right:"left",bottom:"top",top:"bottom"},M={start:"end",end:"start"};function R(e,t){return"function"==typeof e?e(t):e}function j(e){return e.split("-")[0]}function I(e){return e.split("-")[1]}function N(e){return"x"===e?"y":"x"}function P(e){return"y"===e?"height":"width"}function T(e){return["top","bottom"].includes(j(e))?"y":"x"}function F(e){return e.replace(/start|end/g,e=>M[e])}function A(e){return e.replace(/left|right|bottom|top/g,e=>k[e])}function z(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}function L(e,t,n){let r,{reference:o,floating:a}=e,i=T(t),c=N(T(t)),l=P(c),s=j(t),u="y"===i,d=o.x+o.width/2-a.width/2,f=o.y+o.height/2-a.height/2,p=o[l]/2-a[l]/2;switch(s){case"top":r={x:d,y:o.y-a.height};break;case"bottom":r={x:d,y:o.y+o.height};break;case"right":r={x:o.x+o.width,y:f};break;case"left":r={x:o.x-a.width,y:f};break;default:r={x:o.x,y:o.y}}switch(I(t)){case"start":r[c]-=p*(n&&u?-1:1);break;case"end":r[c]+=p*(n&&u?-1:1)}return r}let _=async(e,t,n)=>{let{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,c=a.filter(Boolean),l=await (null==i.isRTL?void 0:i.isRTL(t)),s=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:u,y:d}=L(s,r,l),f=r,p={},m=0;for(let n=0;n{!function(n){try{t=t||e.matches(n)}catch(e){}}(n)});let o=g(e);if(t&&o){let e=o.getBoundingClientRect();n=e.x,r=e.y}return[t,n,r]}function $(e){return X(l(e)).left+y(e).scrollLeft}function Y(e,t,n){let r;if("viewport"===t)r=function(e,t){let n=c(e),r=l(e),o=n.visualViewport,a=r.clientWidth,i=r.clientHeight,s=0,u=0;if(o){a=o.width,i=o.height;let e=h();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,u=o.offsetTop)}return{width:a,height:i,x:s,y:u}}(e,n);else if("document"===t)r=function(e){let t=l(e),n=y(e),r=e.ownerDocument.body,o=S(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=S(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight),i=-n.scrollLeft+$(e),c=-n.scrollTop;return"rtl"===b(r).direction&&(i+=S(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:i,y:c}}(l(e));else if(u(t))r=function(e,t){let n=X(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=d(e)?V(e):O(1),i=e.clientWidth*a.x;return{width:i,height:e.clientHeight*a.y,x:o*a.x,y:r*a.y}}(t,n);else{let n=G(e);r={...t,x:t.x-n.x,y:t.y-n.y}}return z(r)}function Q(e,t){return d(e)&&"fixed"!==b(e).position?t?t(e):e.offsetParent:null}function J(e,t){let n=c(e);if(!d(e))return n;let r=Q(e,t);for(;r&&["table","td","th"].includes(i(r))&&"static"===b(r).position;)r=Q(r,t);return r&&("html"===i(r)||"body"===i(r)&&"static"===b(r).position&&!m(r))?n:r||g(e)||n}let ee=async function(e){let t=this.getOffsetParent||J,n=this.getDimensions;return{reference:function(e,t,n,r){let o=d(t),a=l(t),c="fixed"===n,s=X(e,!0,c,t),u={scrollLeft:0,scrollTop:0},f=O(0);if(o||!o&&!c){if(("body"!==i(t)||p(a))&&(u=y(t)),o){let e=X(t,!0,c,t);f.x=e.x+t.clientLeft,f.y=e.y+t.clientTop}else a&&(f.x=$(a))}let m=s.left+u.scrollLeft-f.x,g=s.top+u.scrollTop-f.y,[h,v,b]=K(r);return h&&(m+=v,g+=b,o&&(m+=t.clientLeft,g+=t.clientTop)),{x:m,y:g,width:s.width,height:s.height}}(e.reference,await t(e.floating),e.strategy,e.floating),floating:{x:0,y:0,...await n(e.floating)}}},et={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e,a=l(r),[c]=t?K(t.floating):[!1];if(r===a||c)return n;let s={scrollLeft:0,scrollTop:0},u=O(1),f=O(0),m=d(r);if((m||!m&&"fixed"!==o)&&(("body"!==i(r)||p(a))&&(s=y(r)),d(r))){let e=X(r);u=V(r),f.x=e.x+r.clientLeft,f.y=e.y+r.clientTop}return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-s.scrollLeft*u.x+f.x,y:n.y*u.y-s.scrollTop*u.y+f.y}},getDocumentElement:l,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e,a=[..."clippingAncestors"===n?function(e,t){let n=t.get(e);if(n)return n;let r=w(e,[],!1).filter(e=>u(e)&&"body"!==i(e)),o=null,a="fixed"===b(e).position,c=a?x(e):e;for(;u(c)&&!v(c);){let t=b(c),n=m(c);n||"fixed"!==t.position||(o=null),(a?!n&&!o:!n&&"static"===t.position&&!!o&&["absolute","fixed"].includes(o.position)||p(c)&&!n&&function e(t,n){let r=x(t);return!(r===n||!u(r)||v(r))&&("fixed"===b(r).position||e(r,n))}(e,c))?r=r.filter(e=>e!==c):o=t,c=x(c)}return t.set(e,r),r}(t,this._c):[].concat(n),r],c=a[0],l=a.reduce((e,n)=>{let r=Y(t,n,o);return e.top=S(r.top,e.top),e.right=E(r.right,e.right),e.bottom=E(r.bottom,e.bottom),e.left=S(r.left,e.left),e},Y(t,c,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:J,getElementRects:ee,getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){let{width:t,height:n}=D(e);return{width:t,height:n}},getScale:V,isElement:u,isRTL:function(e){return"rtl"===b(e).direction}};function en(e,t,n,r){let o;void 0===r&&(r={});let{ancestorScroll:a=!0,ancestorResize:i=!0,elementResize:c="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:u=!1}=r,d=W(e),f=a||i?[...d?w(d):[],...w(t)]:[];f.forEach(e=>{a&&e.addEventListener("scroll",n,{passive:!0}),i&&e.addEventListener("resize",n)});let p=d&&s?function(e,t){let n,r=null,o=l(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return!function i(c,l){void 0===c&&(c=!1),void 0===l&&(l=1),a();let{left:s,top:u,width:d,height:f}=e.getBoundingClientRect();if(c||t(),!d||!f)return;let p=Z(u),m=Z(o.clientWidth-(s+d)),g={rootMargin:-p+"px "+-m+"px "+-Z(o.clientHeight-(u+f))+"px "+-Z(s)+"px",threshold:S(0,E(1,l))||1},h=!0;function v(e){let t=e[0].intersectionRatio;if(t!==l){if(!h)return i();t?i(!1,t):n=setTimeout(()=>{i(!1,1e-7)},100)}h=!1}try{r=new IntersectionObserver(v,{...g,root:o.ownerDocument})}catch(e){r=new IntersectionObserver(v,g)}r.observe(e)}(!0),a}(d,n):null,m=-1,g=null;c&&(g=new ResizeObserver(e=>{let[r]=e;r&&r.target===d&&g&&(g.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var e;null==(e=g)||e.observe(t)})),n()}),d&&!u&&g.observe(d),g.observe(t));let h=u?X(e):null;return u&&function t(){let r=X(e);h&&(r.x!==h.x||r.y!==h.y||r.width!==h.width||r.height!==h.height)&&n(),h=r,o=requestAnimationFrame(t)}(),n(),()=>{var e;f.forEach(e=>{a&&e.removeEventListener("scroll",n),i&&e.removeEventListener("resize",n)}),null==p||p(),null==(e=g)||e.disconnect(),g=null,u&&cancelAnimationFrame(o)}}let er=(e,t,n)=>{let r=new Map,o={platform:et,...n},a={...o.platform,_c:r};return _(e,t,{...o,platform:a})};var eo="undefined"!=typeof document?r.useLayoutEffect:r.useEffect;function ea(e,t){let n,r,o;if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if((n=e.length)!=t.length)return!1;for(r=n;0!=r--;)if(!ea(e[r],t[r]))return!1;return!0}if((n=(o=Object.keys(e)).length)!==Object.keys(t).length)return!1;for(r=n;0!=r--;)if(!Object.prototype.hasOwnProperty.call(t,o[r]))return!1;for(r=n;0!=r--;){let n=o[r];if(("_owner"!==n||!e.$$typeof)&&!ea(e[n],t[n]))return!1}return!0}return e!=e&&t!=t}function ei(e){let t=r.useRef(e);return eo(()=>{t.current=e}),t}var ec="undefined"!=typeof document?r.useLayoutEffect:r.useEffect;let el=!1,es=0,eu=()=>"floating-ui-"+es++,ed=o["useId".toString()]||function(){let[e,t]=r.useState(()=>el?eu():void 0);return ec(()=>{null==e&&t(eu())},[]),r.useEffect(()=>{el||(el=!0)},[]),e},ef=r.createContext(null),ep=r.createContext(null),em=()=>{var e;return(null==(e=r.useContext(ef))?void 0:e.id)||null},eg=()=>r.useContext(ep);function eh(e){return(null==e?void 0:e.ownerDocument)||document}function ev(e){return eh(e).defaultView||window}function eb(e){return!!e&&e instanceof ev(e).Element}function ey(e){return!!e&&e instanceof ev(e).HTMLElement}function ex(e,t){let n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}function ew(e){let t=(0,r.useRef)(e);return ec(()=>{t.current=e}),t}let eE="data-floating-ui-safe-polygon";function eS(e,t,n){return n&&!ex(n)?0:"number"==typeof e?e:null==e?void 0:e[t]}let eC=function(e,t){let{enabled:n=!0,delay:o=0,handleClose:a=null,mouseOnly:i=!1,restMs:c=0,move:l=!0}=void 0===t?{}:t,{open:s,onOpenChange:u,dataRef:d,events:f,elements:{domReference:p,floating:m},refs:g}=e,h=eg(),v=em(),b=ew(a),y=ew(o),x=r.useRef(),w=r.useRef(),E=r.useRef(),S=r.useRef(),C=r.useRef(!0),Z=r.useRef(!1),O=r.useRef(()=>{}),k=r.useCallback(()=>{var e;let t=null==(e=d.current.openEvent)?void 0:e.type;return(null==t?void 0:t.includes("mouse"))&&"mousedown"!==t},[d]);r.useEffect(()=>{if(n)return f.on("dismiss",e),()=>{f.off("dismiss",e)};function e(){clearTimeout(w.current),clearTimeout(S.current),C.current=!0}},[n,f]),r.useEffect(()=>{if(!n||!b.current||!s)return;function e(){k()&&u(!1)}let t=eh(m).documentElement;return t.addEventListener("mouseleave",e),()=>{t.removeEventListener("mouseleave",e)}},[m,s,u,n,b,d,k]);let M=r.useCallback(function(e){void 0===e&&(e=!0);let t=eS(y.current,"close",x.current);t&&!E.current?(clearTimeout(w.current),w.current=setTimeout(()=>u(!1),t)):e&&(clearTimeout(w.current),u(!1))},[y,u]),R=r.useCallback(()=>{O.current(),E.current=void 0},[]),j=r.useCallback(()=>{if(Z.current){let e=eh(g.floating.current).body;e.style.pointerEvents="",e.removeAttribute(eE),Z.current=!1}},[g]);return r.useEffect(()=>{if(n&&eb(p))return s&&p.addEventListener("mouseleave",a),null==m||m.addEventListener("mouseleave",a),l&&p.addEventListener("mousemove",r,{once:!0}),p.addEventListener("mouseenter",r),p.addEventListener("mouseleave",o),()=>{s&&p.removeEventListener("mouseleave",a),null==m||m.removeEventListener("mouseleave",a),l&&p.removeEventListener("mousemove",r),p.removeEventListener("mouseenter",r),p.removeEventListener("mouseleave",o)};function t(){return!!d.current.openEvent&&["click","mousedown"].includes(d.current.openEvent.type)}function r(e){if(clearTimeout(w.current),C.current=!1,i&&!ex(x.current)||c>0&&0===eS(y.current,"open"))return;d.current.openEvent=e;let t=eS(y.current,"open",x.current);t?w.current=setTimeout(()=>{u(!0)},t):u(!0)}function o(n){if(t())return;O.current();let r=eh(m);if(clearTimeout(S.current),b.current){s||clearTimeout(w.current),E.current=b.current({...e,tree:h,x:n.clientX,y:n.clientY,onClose(){j(),R(),M()}});let t=E.current;r.addEventListener("mousemove",t),O.current=()=>{r.removeEventListener("mousemove",t)};return}M()}function a(n){t()||null==b.current||b.current({...e,tree:h,x:n.clientX,y:n.clientY,onClose(){j(),R(),M()}})(n)}},[p,m,n,e,i,c,l,M,R,j,u,s,h,y,b,d]),ec(()=>{var e,t,r;if(n&&s&&null!=(e=b.current)&&e.__options.blockPointerEvents&&k()){let e=eh(m).body;if(e.setAttribute(eE,""),e.style.pointerEvents="none",Z.current=!0,eb(p)&&m){let e=null==h?void 0:null==(t=h.nodesRef.current.find(e=>e.id===v))?void 0:null==(r=t.context)?void 0:r.elements.floating;return e&&(e.style.pointerEvents=""),p.style.pointerEvents="auto",m.style.pointerEvents="auto",()=>{p.style.pointerEvents="",m.style.pointerEvents=""}}}},[n,s,v,m,p,h,b,d,k]),ec(()=>{s||(x.current=void 0,R(),j())},[s,R,j]),r.useEffect(()=>()=>{R(),clearTimeout(w.current),clearTimeout(S.current),j()},[n,R,j]),r.useMemo(()=>{if(!n)return{};function e(e){x.current=e.pointerType}return{reference:{onPointerDown:e,onPointerEnter:e,onMouseMove(){s||0===c||(clearTimeout(S.current),S.current=setTimeout(()=>{C.current||u(!0)},c))}},floating:{onMouseEnter(){clearTimeout(w.current)},onMouseLeave(){f.emit("dismiss",{type:"mouseLeave",data:{returnFocus:!1}}),M(!1)}}}},[f,n,c,s,u,M])};function eZ(e,t){if(!e||!t)return!1;let n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&function(e){if("undefined"==typeof ShadowRoot)return!1;let t=ev(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}(n)){let n=t;do{if(n&&e===n)return!0;n=n.parentNode||n.host}while(n)}return!1}function eO(e,t){let n=e.filter(e=>{var n;return e.parentId===t&&(null==(n=e.context)?void 0:n.open)})||[],r=n;for(;r.length;)r=e.filter(e=>{var t;return null==(t=r)?void 0:t.some(t=>{var n;return e.parentId===t.id&&(null==(n=e.context)?void 0:n.open)})})||[],n=n.concat(r);return n}let ek=o["useInsertionEffect".toString()]||(e=>e());function eM(e){let t=r.useRef(()=>{});return ek(()=>{t.current=e}),r.useCallback(function(){for(var e=arguments.length,n=Array(e),r=0;r!1),S="function"==typeof p?E:p,C=r.useRef(!1),{escapeKeyBubbles:Z,outsidePressBubbles:O}=eN(b);return r.useEffect(()=>{if(!n||!d)return;function e(e){if("Escape"===e.key){let e=y?eO(y.nodesRef.current,i):[];if(e.length>0){let t=!0;if(e.forEach(e=>{var n;if(null!=(n=e.context)&&n.open&&!e.context.dataRef.current.__escapeKeyBubbles){t=!1;return}}),!t)return}a.emit("dismiss",{type:"escapeKey",data:{returnFocus:{preventScroll:!1}}}),o(!1)}}function t(e){var t;let n=C.current;if(C.current=!1,n||"function"==typeof S&&!S(e))return;let r="composedPath"in e?e.composedPath()[0]:e.target;if(ey(r)&&s){let t=s.ownerDocument.defaultView||window,n=r.scrollWidth>r.clientWidth,o=r.scrollHeight>r.clientHeight,a=o&&e.offsetX>r.clientWidth;if(o&&"rtl"===t.getComputedStyle(r).direction&&(a=e.offsetX<=r.offsetWidth-r.clientWidth),a||n&&e.offsetY>r.clientHeight)return}let c=y&&eO(y.nodesRef.current,i).some(t=>{var n;return eR(e,null==(n=t.context)?void 0:n.elements.floating)});if(eR(e,s)||eR(e,l)||c)return;let u=y?eO(y.nodesRef.current,i):[];if(u.length>0){let e=!0;if(u.forEach(t=>{var n;if(null!=(n=t.context)&&n.open&&!t.context.dataRef.current.__outsidePressBubbles){e=!1;return}}),!e)return}a.emit("dismiss",{type:"outsidePress",data:{returnFocus:x?{preventScroll:!0}:function(e){if(0===e.mozInputSource&&e.isTrusted)return!0;let t=/Android/i;return(t.test(function(){let e=navigator.userAgentData;return null!=e&&e.platform?e.platform:navigator.platform}())||t.test(function(){let e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(e=>{let{brand:t,version:n}=e;return t+"/"+n}).join(" "):navigator.userAgent}()))&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType}(e)||0===(t=e).width&&0===t.height||1===t.width&&1===t.height&&0===t.pressure&&0===t.detail&&"mouse"!==t.pointerType||t.width<1&&t.height<1&&0===t.pressure&&0===t.detail}}),o(!1)}function r(){o(!1)}u.current.__escapeKeyBubbles=Z,u.current.__outsidePressBubbles=O;let p=eh(s);f&&p.addEventListener("keydown",e),S&&p.addEventListener(m,t);let g=[];return v&&(eb(l)&&(g=w(l)),eb(s)&&(g=g.concat(w(s))),!eb(c)&&c&&c.contextElement&&(g=g.concat(w(c.contextElement)))),(g=g.filter(e=>{var t;return e!==(null==(t=p.defaultView)?void 0:t.visualViewport)})).forEach(e=>{e.addEventListener("scroll",r,{passive:!0})}),()=>{f&&p.removeEventListener("keydown",e),S&&p.removeEventListener(m,t),g.forEach(e=>{e.removeEventListener("scroll",r)})}},[u,s,l,c,f,S,m,a,y,i,n,o,v,d,Z,O,x]),r.useEffect(()=>{C.current=!1},[S,m]),r.useMemo(()=>d?{reference:{[ej[h]]:()=>{g&&(a.emit("dismiss",{type:"referencePress",data:{returnFocus:!1}}),o(!1))}},floating:{[eI[m]]:()=>{C.current=!0}}}:{},[d,a,g,m,h,o])},eT=function(e,t){let{open:n,onOpenChange:o,dataRef:a,events:i,refs:c,elements:{floating:l,domReference:s}}=e,{enabled:u=!0,keyboardOnly:d=!0}=void 0===t?{}:t,f=r.useRef(""),p=r.useRef(!1),m=r.useRef();return r.useEffect(()=>{if(!u)return;let e=eh(l).defaultView||window;function t(){!n&&ey(s)&&s===function(e){let t=e.activeElement;for(;(null==(n=t)?void 0:null==(r=n.shadowRoot)?void 0:r.activeElement)!=null;){var n,r;t=t.shadowRoot.activeElement}return t}(eh(s))&&(p.current=!0)}return e.addEventListener("blur",t),()=>{e.removeEventListener("blur",t)}},[l,s,n,u]),r.useEffect(()=>{if(u)return i.on("dismiss",e),()=>{i.off("dismiss",e)};function e(e){("referencePress"===e.type||"escapeKey"===e.type)&&(p.current=!0)}},[i,u]),r.useEffect(()=>()=>{clearTimeout(m.current)},[]),r.useMemo(()=>u?{reference:{onPointerDown(e){let{pointerType:t}=e;f.current=t,p.current=!!(t&&d)},onMouseLeave(){p.current=!1},onFocus(e){var t;p.current||"focus"===e.type&&(null==(t=a.current.openEvent)?void 0:t.type)==="mousedown"&&a.current.openEvent&&eR(a.current.openEvent,s)||(a.current.openEvent=e.nativeEvent,o(!0))},onBlur(e){p.current=!1;let t=e.relatedTarget,n=eb(t)&&t.hasAttribute("data-floating-ui-focus-guard")&&"outside"===t.getAttribute("data-type");m.current=setTimeout(()=>{eZ(c.floating.current,t)||eZ(s,t)||n||o(!1)})}}}:{},[u,d,s,c,a,o])},eF=function(e,t){let{open:n}=e,{enabled:o=!0,role:a="dialog"}=void 0===t?{}:t,i=ed(),c=ed();return r.useMemo(()=>{let e={id:i,role:a};return o?"tooltip"===a?{reference:{"aria-describedby":n?i:void 0},floating:e}:{reference:{"aria-expanded":n?"true":"false","aria-haspopup":"alertdialog"===a?"dialog":a,"aria-controls":n?i:void 0,..."listbox"===a&&{role:"combobox"},..."menu"===a&&{id:c}},floating:{...e,..."menu"===a&&{"aria-labelledby":c}}}:{}},[o,a,n,i,c])};function eA(e,t,n){let r=new Map;return{..."floating"===n&&{tabIndex:-1},...e,...t.map(e=>e?e[n]:null).concat(e).reduce((e,t)=>(t&&Object.entries(t).forEach(t=>{let[n,o]=t;if(0===n.indexOf("on")){if(r.has(n)||r.set(n,[]),"function"==typeof o){var a;null==(a=r.get(n))||a.push(o),e[n]=function(){for(var e,t=arguments.length,o=Array(t),a=0;ae(...o))}}}else e[n]=o}),e),{})}}let ez=function(e){void 0===e&&(e=[]);let t=e,n=r.useCallback(t=>eA(t,e,"reference"),t),o=r.useCallback(t=>eA(t,e,"floating"),t),a=r.useCallback(t=>eA(t,e,"item"),e.map(e=>null==e?void 0:e.item));return r.useMemo(()=>({getReferenceProps:n,getFloatingProps:o,getItemProps:a}),[n,o,a])};var eL=n(97324);let e_=e=>{var t,n;let[o,i]=(0,r.useState)(!1),[c,l]=(0,r.useState)(),{x:s,y:u,refs:d,strategy:f,context:p}=function(e){void 0===e&&(e={});let{open:t=!1,onOpenChange:n,nodeId:o}=e,i=function(e){void 0===e&&(e={});let{placement:t="bottom",strategy:n="absolute",middleware:o=[],platform:i,whileElementsMounted:c,open:l}=e,[s,u]=r.useState({x:null,y:null,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[d,f]=r.useState(o);ea(d,o)||f(o);let p=r.useRef(null),m=r.useRef(null),g=r.useRef(s),h=ei(c),v=ei(i),[b,y]=r.useState(null),[x,w]=r.useState(null),E=r.useCallback(e=>{p.current!==e&&(p.current=e,y(e))},[]),S=r.useCallback(e=>{m.current!==e&&(m.current=e,w(e))},[]),C=r.useCallback(()=>{if(!p.current||!m.current)return;let e={placement:t,strategy:n,middleware:d};v.current&&(e.platform=v.current),er(p.current,m.current,e).then(e=>{let t={...e,isPositioned:!0};Z.current&&!ea(g.current,t)&&(g.current=t,a.flushSync(()=>{u(t)}))})},[d,t,n,v]);eo(()=>{!1===l&&g.current.isPositioned&&(g.current.isPositioned=!1,u(e=>({...e,isPositioned:!1})))},[l]);let Z=r.useRef(!1);eo(()=>(Z.current=!0,()=>{Z.current=!1}),[]),eo(()=>{if(b&&x){if(h.current)return h.current(b,x,C);C()}},[b,x,C,h]);let O=r.useMemo(()=>({reference:p,floating:m,setReference:E,setFloating:S}),[E,S]),k=r.useMemo(()=>({reference:b,floating:x}),[b,x]);return r.useMemo(()=>({...s,update:C,refs:O,elements:k,reference:E,floating:S}),[s,C,O,k,E,S])}(e),c=eg(),l=r.useRef(null),s=r.useRef({}),u=r.useState(()=>(function(){let e=new Map;return{emit(t,n){var r;null==(r=e.get(t))||r.forEach(e=>e(n))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){e.set(t,(e.get(t)||[]).filter(e=>e!==n))}}})())[0],[d,f]=r.useState(null),p=r.useCallback(e=>{let t=eb(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),contextElement:e}:e;i.refs.setReference(t)},[i.refs]),m=r.useCallback(e=>{(eb(e)||null===e)&&(l.current=e,f(e)),(eb(i.refs.reference.current)||null===i.refs.reference.current||null!==e&&!eb(e))&&i.refs.setReference(e)},[i.refs]),g=r.useMemo(()=>({...i.refs,setReference:m,setPositionReference:p,domReference:l}),[i.refs,m,p]),h=r.useMemo(()=>({...i.elements,domReference:d}),[i.elements,d]),v=eM(n),b=r.useMemo(()=>({...i,refs:g,elements:h,dataRef:s,nodeId:o,events:u,open:t,onOpenChange:v}),[i,o,u,t,v,g,h]);return ec(()=>{let e=null==c?void 0:c.nodesRef.current.find(e=>e.id===o);e&&(e.context=b)}),r.useMemo(()=>({...i,context:b,refs:g,reference:m,positionReference:p}),[i,g,b,m,p])}({open:o,onOpenChange:t=>{t&&e?l(setTimeout(()=>{i(t)},e)):(clearTimeout(c),i(t))},placement:"top",whileElementsMounted:en,middleware:[{name:"offset",options:5,async fn(e){var t,n;let{x:r,y:o,placement:a,middlewareData:i}=e,c=await B(e,5);return a===(null==(t=i.offset)?void 0:t.placement)&&null!=(n=i.arrow)&&n.alignmentOffset?{}:{x:r+c.x,y:o+c.y,data:{...c,placement:a}}}},{name:"flip",options:t={fallbackAxisSideDirection:"start"},async fn(e){var n,r,o,a,i;let{placement:c,middlewareData:l,rects:s,initialPlacement:u,platform:d,elements:f}=e,{mainAxis:p=!0,crossAxis:m=!0,fallbackPlacements:g,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:b=!0,...y}=R(t,e);if(null!=(n=l.arrow)&&n.alignmentOffset)return{};let x=j(c),w=j(u)===u,E=await (null==d.isRTL?void 0:d.isRTL(f.floating)),S=g||(w||!b?[A(u)]:function(e){let t=A(e);return[F(e),t,F(t)]}(u));g||"none"===v||S.push(...function(e,t,n,r){let o=I(e),a=function(e,t,n){let r=["left","right"],o=["right","left"];switch(e){case"top":case"bottom":if(n)return t?o:r;return t?r:o;case"left":case"right":return t?["top","bottom"]:["bottom","top"];default:return[]}}(j(e),"start"===n,r);return o&&(a=a.map(e=>e+"-"+o),t&&(a=a.concat(a.map(F)))),a}(u,b,v,E));let C=[u,...S],Z=await H(e,y),O=[],k=(null==(r=l.flip)?void 0:r.overflows)||[];if(p&&O.push(Z[x]),m){let e=function(e,t,n){void 0===n&&(n=!1);let r=I(e),o=N(T(e)),a=P(o),i="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=A(i)),[i,A(i)]}(c,s,E);O.push(Z[e[0]],Z[e[1]])}if(k=[...k,{placement:c,overflows:O}],!O.every(e=>e<=0)){let e=((null==(o=l.flip)?void 0:o.index)||0)+1,t=C[e];if(t)return{data:{index:e,overflows:k},reset:{placement:t}};let n=null==(a=k.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:a.placement;if(!n)switch(h){case"bestFit":{let e=null==(i=k.map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:i[0];e&&(n=e);break}case"initialPlacement":n=u}if(c!==n)return{reset:{placement:n}}}return{}}},(void 0===n&&(n={}),{name:"shift",options:n,async fn(e){let{x:t,y:r,placement:o}=e,{mainAxis:a=!0,crossAxis:i=!1,limiter:c={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=R(n,e),s={x:t,y:r},u=await H(e,l),d=T(j(o)),f=N(d),p=s[f],m=s[d];if(a){let e="y"===f?"top":"left",t="y"===f?"bottom":"right",n=p+u[e],r=p-u[t];p=S(n,E(p,r))}if(i){let e="y"===d?"top":"left",t="y"===d?"bottom":"right",n=m+u[e],r=m-u[t];m=S(n,E(m,r))}let g=c.fn({...e,[f]:p,[d]:m});return{...g,data:{x:g.x-t,y:g.y-r}}}})]}),m=eC(p,{move:!1}),{getReferenceProps:g,getFloatingProps:h}=ez([m,eT(p),eP(p),eF(p,{role:"tooltip"})]);return{tooltipProps:{open:o,x:s,y:u,refs:d,strategy:f,getFloatingProps:h},getReferenceProps:g}},eH=e=>{let{text:t,open:n,x:o,y:a,refs:i,strategy:c,getFloatingProps:l}=e;return n&&t?r.createElement("div",Object.assign({className:(0,eL.q)("max-w-xs text-sm z-20 rounded-tremor-default opacity-100 px-2.5 py-1","text-white bg-tremor-background-emphasis","text-white dark:bg-dark-tremor-background-subtle"),ref:i.setFloating,style:{position:c,top:null!=a?a:0,left:null!=o?o:0}},l()),t):null};eH.displayName="Tooltip"},7084:function(e,t,n){"use strict";n.d(t,{fr:function(){return o},m:function(){return c},u8:function(){return a},wu:function(){return r},zS:function(){return i}});let r={Increase:"increase",ModerateIncrease:"moderateIncrease",Decrease:"decrease",ModerateDecrease:"moderateDecrease",Unchanged:"unchanged"},o={Slate:"slate",Gray:"gray",Zinc:"zinc",Neutral:"neutral",Stone:"stone",Red:"red",Orange:"orange",Amber:"amber",Yellow:"yellow",Lime:"lime",Green:"green",Emerald:"emerald",Teal:"teal",Cyan:"cyan",Sky:"sky",Blue:"blue",Indigo:"indigo",Violet:"violet",Purple:"purple",Fuchsia:"fuchsia",Pink:"pink",Rose:"rose"},a={XS:"xs",SM:"sm",MD:"md",LG:"lg",XL:"xl"},i={Left:"left",Right:"right"},c={Top:"top",Bottom:"bottom"}},26898:function(e,t,n){"use strict";n.d(t,{K:function(){return o},s:function(){return a}});var r=n(7084);let o={canvasBackground:50,lightBackground:100,background:500,darkBackground:600,darkestBackground:800,lightBorder:200,border:500,darkBorder:700,lightRing:200,ring:300,lightText:400,text:500,darkText:700,darkestText:900,icon:500},a=[r.fr.Blue,r.fr.Cyan,r.fr.Sky,r.fr.Indigo,r.fr.Violet,r.fr.Purple,r.fr.Fuchsia,r.fr.Slate,r.fr.Gray,r.fr.Zinc,r.fr.Neutral,r.fr.Stone,r.fr.Red,r.fr.Orange,r.fr.Amber,r.fr.Yellow,r.fr.Lime,r.fr.Green,r.fr.Emerald,r.fr.Teal,r.fr.Pink,r.fr.Rose]},97324:function(e,t,n){"use strict";n.d(t,{q:function(){return z}});var r=/^\[(.+)\]$/;function o(e,t){var n=e;return t.split("-").forEach(function(e){n.nextPart.has(e)||n.nextPart.set(e,{nextPart:new Map,validators:[]}),n=n.nextPart.get(e)}),n}var a=/\s+/;function i(){for(var e,t,n=0,r="";ne&&(t=0,r=n,n=new Map)}return{get:function(e){var t=n.get(e);return void 0!==t?t:void 0!==(t=r.get(e))?(o(e,t),t):void 0},set:function(e,t){n.has(e)?n.set(e,t):o(e,t)}}}(e.cacheSize),splitModifiers:(n=1===(t=e.separator||":").length,a=t[0],i=t.length,function(e){for(var r,o=[],c=0,l=0,s=0;sl?r-l:void 0}}),...(u=e.theme,d=e.prefix,f={nextPart:new Map,validators:[]},(p=Object.entries(e.classGroups),d?p.map(function(e){return[e[0],e[1].map(function(e){return"string"==typeof e?d+e:"object"==typeof e?Object.fromEntries(Object.entries(e).map(function(e){return[d+e[0],e[1]]})):e})]}):p).forEach(function(e){var t=e[0];(function e(t,n,r,a){t.forEach(function(t){if("string"==typeof t){(""===t?n:o(n,t)).classGroupId=r;return}if("function"==typeof t){if(t.isThemeGetter){e(t(a),n,r,a);return}n.validators.push({validator:t,classGroupId:r});return}Object.entries(t).forEach(function(t){var i=t[0];e(t[1],o(n,i),r,a)})})})(e[1],f,t,u)}),c=e.conflictingClassGroups,s=void 0===(l=e.conflictingClassGroupModifiers)?{}:l,{getClassGroupId:function(e){var t=e.split("-");return""===t[0]&&1!==t.length&&t.shift(),function e(t,n){if(0===t.length)return n.classGroupId;var r,o=t[0],a=n.nextPart.get(o),i=a?e(t.slice(1),a):void 0;if(i)return i;if(0!==n.validators.length){var c=t.join("-");return null===(r=n.validators.find(function(e){return(0,e.validator)(c)}))||void 0===r?void 0:r.classGroupId}}(t,f)||function(e){if(r.test(e)){var t=r.exec(e)[1],n=null==t?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}}(e)},getConflictingClassGroupIds:function(e,t){var n=c[e]||[];return t&&s[e]?[].concat(n,s[e]):n}})}}(l.slice(1).reduce(function(e,t){return t(e)},i()))).cache.get,n=e.cache.set,u=d,d(a)};function d(r){var o,i,c,l,s,u=t(r);if(u)return u;var d=(i=(o=e).splitModifiers,c=o.getClassGroupId,l=o.getConflictingClassGroupIds,s=new Set,r.trim().split(a).map(function(e){var t=i(e),n=t.modifiers,r=t.hasImportantModifier,o=t.baseClassName,a=t.maybePostfixModifierPosition,l=c(a?o.substring(0,a):o),s=!!a;if(!l){if(!a||!(l=c(o)))return{isTailwindClass:!1,originalClassName:e};s=!1}var u=(function(e){if(e.length<=1)return e;var t=[],n=[];return e.forEach(function(e){"["===e[0]?(t.push.apply(t,n.sort().concat([e])),n=[]):n.push(e)}),t.push.apply(t,n.sort()),t})(n).join(":");return{isTailwindClass:!0,modifierId:r?u+"!":u,classGroupId:l,originalClassName:e,hasPostfixModifier:s}}).reverse().filter(function(e){if(!e.isTailwindClass)return!0;var t=e.modifierId,n=e.classGroupId,r=e.hasPostfixModifier,o=t+n;return!s.has(o)&&(s.add(o),l(n,r).forEach(function(e){return s.add(t+e)}),!0)}).reverse().map(function(e){return e.originalClassName}).join(" "));return n(r,d),d}return function(){return u(i.apply(null,arguments))}}function l(e){var t=function(t){return t[e]||[]};return t.isThemeGetter=!0,t}var s=/^\[(?:([a-z-]+):)?(.+)\]$/i,u=/^\d+\/\d+$/,d=new Set(["px","full","screen"]),f=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,p=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,m=/^-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/;function g(e){return w(e)||d.has(e)||u.test(e)||h(e)}function h(e){return M(e,"length",R)}function v(e){return M(e,"size",j)}function b(e){return M(e,"position",j)}function y(e){return M(e,"url",I)}function x(e){return M(e,"number",w)}function w(e){return!Number.isNaN(Number(e))}function E(e){return e.endsWith("%")&&w(e.slice(0,-1))}function S(e){return N(e)||M(e,"number",N)}function C(e){return s.test(e)}function Z(){return!0}function O(e){return f.test(e)}function k(e){return M(e,"",P)}function M(e,t,n){var r=s.exec(e);return!!r&&(r[1]?r[1]===t:n(r[2]))}function R(e){return p.test(e)}function j(){return!1}function I(e){return e.startsWith("url(")}function N(e){return Number.isInteger(Number(e))}function P(e){return m.test(e)}function T(){var e=l("colors"),t=l("spacing"),n=l("blur"),r=l("brightness"),o=l("borderColor"),a=l("borderRadius"),i=l("borderSpacing"),c=l("borderWidth"),s=l("contrast"),u=l("grayscale"),d=l("hueRotate"),f=l("invert"),p=l("gap"),m=l("gradientColorStops"),M=l("gradientColorStopPositions"),R=l("inset"),j=l("margin"),I=l("opacity"),N=l("padding"),P=l("saturate"),T=l("scale"),F=l("sepia"),A=l("skew"),z=l("space"),L=l("translate"),_=function(){return["auto","contain","none"]},H=function(){return["auto","hidden","clip","visible","scroll"]},B=function(){return["auto",C,t]},D=function(){return[C,t]},W=function(){return["",g]},V=function(){return["auto",w,C]},q=function(){return["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"]},G=function(){return["solid","dashed","dotted","double","none"]},X=function(){return["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter"]},U=function(){return["start","end","center","between","around","evenly","stretch"]},K=function(){return["","0",C]},$=function(){return["auto","avoid","all","avoid-page","page","left","right","column"]},Y=function(){return[w,x]},Q=function(){return[w,C]};return{cacheSize:500,theme:{colors:[Z],spacing:[g],blur:["none","",O,C],brightness:Y(),borderColor:[e],borderRadius:["none","","full",O,C],borderSpacing:D(),borderWidth:W(),contrast:Y(),grayscale:K(),hueRotate:Q(),invert:K(),gap:D(),gradientColorStops:[e],gradientColorStopPositions:[E,h],inset:B(),margin:B(),opacity:Y(),padding:D(),saturate:Y(),scale:Y(),sepia:K(),skew:Q(),space:D(),translate:D()},classGroups:{aspect:[{aspect:["auto","square","video",C]}],container:["container"],columns:[{columns:[O]}],"break-after":[{"break-after":$()}],"break-before":[{"break-before":$()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none"]}],clear:[{clear:["left","right","both","none"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[].concat(q(),[C])}],overflow:[{overflow:H()}],"overflow-x":[{"overflow-x":H()}],"overflow-y":[{"overflow-y":H()}],overscroll:[{overscroll:_()}],"overscroll-x":[{"overscroll-x":_()}],"overscroll-y":[{"overscroll-y":_()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[R]}],"inset-x":[{"inset-x":[R]}],"inset-y":[{"inset-y":[R]}],start:[{start:[R]}],end:[{end:[R]}],top:[{top:[R]}],right:[{right:[R]}],bottom:[{bottom:[R]}],left:[{left:[R]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",S]}],basis:[{basis:B()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",C]}],grow:[{grow:K()}],shrink:[{shrink:K()}],order:[{order:["first","last","none",S]}],"grid-cols":[{"grid-cols":[Z]}],"col-start-end":[{col:["auto",{span:["full",S]},C]}],"col-start":[{"col-start":V()}],"col-end":[{"col-end":V()}],"grid-rows":[{"grid-rows":[Z]}],"row-start-end":[{row:["auto",{span:[S]},C]}],"row-start":[{"row-start":V()}],"row-end":[{"row-end":V()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",C]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",C]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"justify-content":[{justify:["normal"].concat(U())}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal"].concat(U(),["baseline"])}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[].concat(U(),["baseline"])}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[N]}],px:[{px:[N]}],py:[{py:[N]}],ps:[{ps:[N]}],pe:[{pe:[N]}],pt:[{pt:[N]}],pr:[{pr:[N]}],pb:[{pb:[N]}],pl:[{pl:[N]}],m:[{m:[j]}],mx:[{mx:[j]}],my:[{my:[j]}],ms:[{ms:[j]}],me:[{me:[j]}],mt:[{mt:[j]}],mr:[{mr:[j]}],mb:[{mb:[j]}],ml:[{ml:[j]}],"space-x":[{"space-x":[z]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[z]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit",C,t]}],"min-w":[{"min-w":["min","max","fit",C,g]}],"max-w":[{"max-w":["0","none","full","min","max","fit","prose",{screen:[O]},O,C]}],h:[{h:[C,t,"auto","min","max","fit"]}],"min-h":[{"min-h":["min","max","fit",C,g]}],"max-h":[{"max-h":[C,t,"min","max","fit"]}],"font-size":[{text:["base",O,h]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",x]}],"font-family":[{font:[Z]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractons"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",C]}],"line-clamp":[{"line-clamp":["none",w,x]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",C,g]}],"list-image":[{"list-image":["none",C]}],"list-style-type":[{list:["none","disc","decimal",C]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[I]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[I]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[].concat(G(),["wavy"])}],"text-decoration-thickness":[{decoration:["auto","from-font",g]}],"underline-offset":[{"underline-offset":["auto",C,g]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],indent:[{indent:D()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",C]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",C]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[I]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[].concat(q(),[b])}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",v]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},y]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[M]}],"gradient-via-pos":[{via:[M]}],"gradient-to-pos":[{to:[M]}],"gradient-from":[{from:[m]}],"gradient-via":[{via:[m]}],"gradient-to":[{to:[m]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[c]}],"border-w-x":[{"border-x":[c]}],"border-w-y":[{"border-y":[c]}],"border-w-s":[{"border-s":[c]}],"border-w-e":[{"border-e":[c]}],"border-w-t":[{"border-t":[c]}],"border-w-r":[{"border-r":[c]}],"border-w-b":[{"border-b":[c]}],"border-w-l":[{"border-l":[c]}],"border-opacity":[{"border-opacity":[I]}],"border-style":[{border:[].concat(G(),["hidden"])}],"divide-x":[{"divide-x":[c]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[c]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[I]}],"divide-style":[{divide:G()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:[""].concat(G())}],"outline-offset":[{"outline-offset":[C,g]}],"outline-w":[{outline:[g]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:W()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[I]}],"ring-offset-w":[{"ring-offset":[g]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",O,k]}],"shadow-color":[{shadow:[Z]}],opacity:[{opacity:[I]}],"mix-blend":[{"mix-blend":X()}],"bg-blend":[{"bg-blend":X()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[s]}],"drop-shadow":[{"drop-shadow":["","none",O,C]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[f]}],saturate:[{saturate:[P]}],sepia:[{sepia:[F]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[s]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[f]}],"backdrop-opacity":[{"backdrop-opacity":[I]}],"backdrop-saturate":[{"backdrop-saturate":[P]}],"backdrop-sepia":[{"backdrop-sepia":[F]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",C]}],duration:[{duration:Q()}],ease:[{ease:["linear","in","out","in-out",C]}],delay:[{delay:Q()}],animate:[{animate:["none","spin","ping","pulse","bounce",C]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[T]}],"scale-x":[{"scale-x":[T]}],"scale-y":[{"scale-y":[T]}],rotate:[{rotate:[S,C]}],"translate-x":[{"translate-x":[L]}],"translate-y":[{"translate-y":[L]}],"skew-x":[{"skew-x":[A]}],"skew-y":[{"skew-y":[A]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",C]}],accent:[{accent:["auto",e]}],appearance:["appearance-none"],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",C]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":D()}],"scroll-mx":[{"scroll-mx":D()}],"scroll-my":[{"scroll-my":D()}],"scroll-ms":[{"scroll-ms":D()}],"scroll-me":[{"scroll-me":D()}],"scroll-mt":[{"scroll-mt":D()}],"scroll-mr":[{"scroll-mr":D()}],"scroll-mb":[{"scroll-mb":D()}],"scroll-ml":[{"scroll-ml":D()}],"scroll-p":[{"scroll-p":D()}],"scroll-px":[{"scroll-px":D()}],"scroll-py":[{"scroll-py":D()}],"scroll-ps":[{"scroll-ps":D()}],"scroll-pe":[{"scroll-pe":D()}],"scroll-pt":[{"scroll-pt":D()}],"scroll-pr":[{"scroll-pr":D()}],"scroll-pb":[{"scroll-pb":D()}],"scroll-pl":[{"scroll-pl":D()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","pinch-zoom","manipulation",{pan:["x","left","right","y","up","down"]}]}],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",C]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[g,x]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}}var F=Object.prototype.hasOwnProperty,A=new Set(["string","number","boolean"]);let z=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;ro.includes(e),i=(e,t)=>{if(t||e===r.wu.Unchanged)return e;switch(e){case r.wu.Increase:return r.wu.Decrease;case r.wu.ModerateIncrease:return r.wu.ModerateDecrease;case r.wu.Decrease:return r.wu.Increase;case r.wu.ModerateDecrease:return r.wu.ModerateIncrease}return""},c=e=>e.toString(),l=e=>e.reduce((e,t)=>e+t,0),s=(e,t)=>{for(let n=0;n{e.forEach(e=>{"function"==typeof e?e(t):null!=e&&(e.current=t)})}}function d(e){return t=>"tremor-".concat(e,"-").concat(t)}function f(e,t){let n=a(e);if("white"===e||"black"===e||"transparent"===e||!t||!n){let t=e.includes("#")||e.includes("--")||e.includes("rgb")?"[".concat(e,"]"):e;return{bgColor:"bg-".concat(t),hoverBgColor:"hover:bg-".concat(t),selectBgColor:"ui-selected:bg-".concat(t),textColor:"text-".concat(t),selectTextColor:"ui-selected:text-".concat(t),hoverTextColor:"hover:text-".concat(t),borderColor:"border-".concat(t),selectBorderColor:"ui-selected:border-".concat(t),hoverBorderColor:"hover:border-".concat(t),ringColor:"ring-".concat(t),strokeColor:"stroke-".concat(t),fillColor:"fill-".concat(t)}}return{bgColor:"bg-".concat(e,"-").concat(t),selectBgColor:"ui-selected:bg-".concat(e,"-").concat(t),hoverBgColor:"hover:bg-".concat(e,"-").concat(t),textColor:"text-".concat(e,"-").concat(t),selectTextColor:"ui-selected:text-".concat(e,"-").concat(t),hoverTextColor:"hover:text-".concat(e,"-").concat(t),borderColor:"border-".concat(e,"-").concat(t),selectBorderColor:"ui-selected:border-".concat(e,"-").concat(t),hoverBorderColor:"hover:border-".concat(e,"-").concat(t),ringColor:"ring-".concat(e,"-").concat(t),strokeColor:"stroke-".concat(e,"-").concat(t),fillColor:"fill-".concat(e,"-").concat(t)}}},93942:function(e,t,n){"use strict";n.d(t,{i:function(){return c}});var r=n(2265),o=n(50506),a=n(13959),i=n(71744);function c(e){return t=>r.createElement(a.ZP,{theme:{token:{motion:!1,zIndexPopupBase:0}}},r.createElement(e,Object.assign({},t)))}t.Z=(e,t,n,a)=>c(c=>{let{prefixCls:l,style:s}=c,u=r.useRef(null),[d,f]=r.useState(0),[p,m]=r.useState(0),[g,h]=(0,o.Z)(!1,{value:c.open}),{getPrefixCls:v}=r.useContext(i.E_),b=v(t||"select",l);r.useEffect(()=>{if(h(!0),"undefined"!=typeof ResizeObserver){let e=new ResizeObserver(e=>{let t=e[0].target;f(t.offsetHeight+8),m(t.offsetWidth)}),t=setInterval(()=>{var r;let o=n?".".concat(n(b)):".".concat(b,"-dropdown"),a=null===(r=u.current)||void 0===r?void 0:r.querySelector(o);a&&(clearInterval(t),e.observe(a))},10);return()=>{clearInterval(t),e.disconnect()}}},[]);let y=Object.assign(Object.assign({},c),{style:Object.assign(Object.assign({},s),{margin:0}),open:g,visible:g,getPopupContainer:()=>u.current});return a&&(y=a(y)),r.createElement("div",{ref:u,style:{paddingBottom:d,position:"relative",minWidth:p}},r.createElement(e,Object.assign({},y)))})},93350:function(e,t,n){"use strict";n.d(t,{o2:function(){return c},yT:function(){return l}});var r=n(83145),o=n(53454);let a=o.i.map(e=>"".concat(e,"-inverse")),i=["success","processing","error","default","warning"];function c(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return t?[].concat((0,r.Z)(a),(0,r.Z)(o.i)).includes(e):o.i.includes(e)}function l(e){return i.includes(e)}},62236:function(e,t,n){"use strict";n.d(t,{Cn:function(){return s},u6:function(){return i}});var r=n(2265),o=n(29961),a=n(95140);let i=1e3,c={Modal:100,Drawer:100,Popover:100,Popconfirm:100,Tooltip:100,Tour:100},l={SelectLike:50,Dropdown:50,DatePicker:50,Menu:50,ImagePreview:1};function s(e,t){let[,n]=(0,o.ZP)(),s=r.useContext(a.Z);if(void 0!==t)return[t,t];let u=null!=s?s:0;return e in c?(u+=(s?0:n.zIndexPopupBase)+c[e],u=Math.min(u,n.zIndexPopupBase+i)):u+=l[e],[void 0===s?t:u,u]}},68710:function(e,t,n){"use strict";n.d(t,{m:function(){return c}});let r=()=>({height:0,opacity:0}),o=e=>{let{scrollHeight:t}=e;return{height:t,opacity:1}},a=e=>({height:e?e.offsetHeight:0}),i=(e,t)=>(null==t?void 0:t.deadline)===!0||"height"===t.propertyName,c=(e,t,n)=>void 0!==n?n:"".concat(e,"-").concat(t);t.Z=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"ant";return{motionName:"".concat(e,"-motion-collapse"),onAppearStart:r,onEnterStart:r,onAppearActive:o,onEnterActive:o,onLeaveStart:a,onLeaveActive:r,onAppearEnd:i,onEnterEnd:i,onLeaveEnd:i,motionDeadline:500}}},92736:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(88260);let o={left:{points:["cr","cl"]},right:{points:["cl","cr"]},top:{points:["bc","tc"]},bottom:{points:["tc","bc"]},topLeft:{points:["bl","tl"]},leftTop:{points:["tr","tl"]},topRight:{points:["br","tr"]},rightTop:{points:["tl","tr"]},bottomRight:{points:["tr","br"]},rightBottom:{points:["bl","br"]},bottomLeft:{points:["tl","bl"]},leftBottom:{points:["br","bl"]}},a={topLeft:{points:["bl","tc"]},leftTop:{points:["tr","cl"]},topRight:{points:["br","tc"]},rightTop:{points:["tl","cr"]},bottomRight:{points:["tr","bc"]},rightBottom:{points:["bl","cr"]},bottomLeft:{points:["tl","bc"]},leftBottom:{points:["br","cl"]}},i=new Set(["topLeft","topRight","bottomLeft","bottomRight","leftTop","leftBottom","rightTop","rightBottom"]);function c(e){let{arrowWidth:t,autoAdjustOverflow:n,arrowPointAtCenter:c,offset:l,borderRadius:s,visibleFirst:u}=e,d=t/2,f={};return Object.keys(o).forEach(e=>{let p=Object.assign(Object.assign({},c&&a[e]||o[e]),{offset:[0,0],dynamicInset:!0});switch(f[e]=p,i.has(e)&&(p.autoArrow=!1),e){case"top":case"topLeft":case"topRight":p.offset[1]=-d-l;break;case"bottom":case"bottomLeft":case"bottomRight":p.offset[1]=d+l;break;case"left":case"leftTop":case"leftBottom":p.offset[0]=-d-l;break;case"right":case"rightTop":case"rightBottom":p.offset[0]=d+l}let m=(0,r.wZ)({contentRadius:s,limitVerticalRadius:!0});if(c)switch(e){case"topLeft":case"bottomLeft":p.offset[0]=-m.arrowOffsetHorizontal-d;break;case"topRight":case"bottomRight":p.offset[0]=m.arrowOffsetHorizontal+d;break;case"leftTop":case"rightTop":p.offset[1]=-m.arrowOffsetHorizontal-d;break;case"leftBottom":case"rightBottom":p.offset[1]=m.arrowOffsetHorizontal+d}p.overflow=function(e,t,n,r){if(!1===r)return{adjustX:!1,adjustY:!1};let o={};switch(e){case"top":case"bottom":o.shiftX=2*t.arrowOffsetHorizontal+n,o.shiftY=!0,o.adjustY=!0;break;case"left":case"right":o.shiftY=2*t.arrowOffsetVertical+n,o.shiftX=!0,o.adjustX=!0}let a=Object.assign(Object.assign({},o),r&&"object"==typeof r?r:{});return a.shiftX||(a.adjustX=!0),a.shiftY||(a.adjustY=!0),a}(e,m,t,n),u&&(p.htmlRegion="visibleFirst")}),f}},19722:function(e,t,n){"use strict";n.d(t,{M2:function(){return i},Tm:function(){return l},l$:function(){return a},wm:function(){return c}});var r,o=n(2265);let{isValidElement:a}=r||(r=n.t(o,2));function i(e){return e&&a(e)&&e.type===o.Fragment}function c(e,t,n){return a(e)?o.cloneElement(e,"function"==typeof n?n(e.props||{}):n):t}function l(e,t){return c(e,e,t)}},6543:function(e,t,n){"use strict";n.d(t,{ZP:function(){return l},c4:function(){return a}});var r=n(2265),o=n(29961);let a=["xxl","xl","lg","md","sm","xs"],i=e=>({xs:"(max-width: ".concat(e.screenXSMax,"px)"),sm:"(min-width: ".concat(e.screenSM,"px)"),md:"(min-width: ".concat(e.screenMD,"px)"),lg:"(min-width: ".concat(e.screenLG,"px)"),xl:"(min-width: ".concat(e.screenXL,"px)"),xxl:"(min-width: ".concat(e.screenXXL,"px)")}),c=e=>{let t=[].concat(a).reverse();return t.forEach((n,r)=>{let o=n.toUpperCase(),a="screen".concat(o,"Min"),i="screen".concat(o);if(!(e[a]<=e[i]))throw Error("".concat(a,"<=").concat(i," fails : !(").concat(e[a],"<=").concat(e[i],")"));if(r{let e=new Map,n=-1,r={};return{matchHandlers:{},dispatch:t=>(r=t,e.forEach(e=>e(r)),e.size>=1),subscribe(t){return e.size||this.register(),n+=1,e.set(n,t),t(r),n},unsubscribe(t){e.delete(t),e.size||this.unregister()},unregister(){Object.keys(t).forEach(e=>{let n=t[e],r=this.matchHandlers[n];null==r||r.mql.removeListener(null==r?void 0:r.listener)}),e.clear()},register(){Object.keys(t).forEach(e=>{let n=t[e],o=t=>{let{matches:n}=t;this.dispatch(Object.assign(Object.assign({},r),{[e]:n}))},a=window.matchMedia(n);a.addListener(o),this.matchHandlers[n]={mql:a,listener:o},o(a)})},responsiveMap:t}},[e])}},12757:function(e,t,n){"use strict";n.d(t,{F:function(){return i},Z:function(){return a}});var r=n(36760),o=n.n(r);function a(e,t,n){return o()({["".concat(e,"-status-success")]:"success"===t,["".concat(e,"-status-warning")]:"warning"===t,["".concat(e,"-status-error")]:"error"===t,["".concat(e,"-status-validating")]:"validating"===t,["".concat(e,"-has-feedback")]:n})}let i=(e,t)=>t||e},13613:function(e,t,n){"use strict";n.d(t,{G8:function(){return a},ln:function(){return i}});var r=n(2265);function o(){}n(32559);let a=r.createContext({}),i=()=>{let e=()=>{};return e.deprecated=o,e}},6694:function(e,t,n){"use strict";n.d(t,{Z:function(){return S}});var r=n(36760),o=n.n(r),a=n(28791),i=n(2857),c=n(2265),l=n(71744),s=n(19722),u=n(80669);let d=e=>{let{componentCls:t,colorPrimary:n}=e;return{[t]:{position:"absolute",background:"transparent",pointerEvents:"none",boxSizing:"border-box",color:"var(--wave-color, ".concat(n,")"),boxShadow:"0 0 0 0 currentcolor",opacity:.2,"&.wave-motion-appear":{transition:["box-shadow 0.4s ".concat(e.motionEaseOutCirc),"opacity 2s ".concat(e.motionEaseOutCirc)].join(","),"&-active":{boxShadow:"0 0 0 6px currentcolor",opacity:0},"&.wave-quick":{transition:["box-shadow 0.3s ".concat(e.motionEaseInOut),"opacity 0.35s ".concat(e.motionEaseInOut)].join(",")}}}}};var f=(0,u.ZP)("Wave",e=>[d(e)]),p=n(74126),m=n(53346),g=n(47970),h=n(18404);function v(e){return e&&"#fff"!==e&&"#ffffff"!==e&&"rgb(255, 255, 255)"!==e&&"rgba(255, 255, 255, 1)"!==e&&function(e){let t=(e||"").match(/rgba?\((\d*), (\d*), (\d*)(, [\d.]*)?\)/);return!t||!t[1]||!t[2]||!t[3]||!(t[1]===t[2]&&t[2]===t[3])}(e)&&!/rgba\((?:\d*, ){3}0\)/.test(e)&&"transparent"!==e}var b=n(34709);function y(e){return Number.isNaN(e)?0:e}let x=e=>{let{className:t,target:n,component:r}=e,a=c.useRef(null),[i,l]=c.useState(null),[s,u]=c.useState([]),[d,f]=c.useState(0),[p,x]=c.useState(0),[w,E]=c.useState(0),[S,C]=c.useState(0),[Z,O]=c.useState(!1),k={left:d,top:p,width:w,height:S,borderRadius:s.map(e=>"".concat(e,"px")).join(" ")};function M(){let e=getComputedStyle(n);l(function(e){let{borderTopColor:t,borderColor:n,backgroundColor:r}=getComputedStyle(e);return v(t)?t:v(n)?n:v(r)?r:null}(n));let t="static"===e.position,{borderLeftWidth:r,borderTopWidth:o}=e;f(t?n.offsetLeft:y(-parseFloat(r))),x(t?n.offsetTop:y(-parseFloat(o))),E(n.offsetWidth),C(n.offsetHeight);let{borderTopLeftRadius:a,borderTopRightRadius:i,borderBottomLeftRadius:c,borderBottomRightRadius:s}=e;u([a,i,s,c].map(e=>y(parseFloat(e))))}if(i&&(k["--wave-color"]=i),c.useEffect(()=>{if(n){let e;let t=(0,m.Z)(()=>{M(),O(!0)});return"undefined"!=typeof ResizeObserver&&(e=new ResizeObserver(M)).observe(n),()=>{m.Z.cancel(t),null==e||e.disconnect()}}},[]),!Z)return null;let R=("Checkbox"===r||"Radio"===r)&&(null==n?void 0:n.classList.contains(b.A));return c.createElement(g.ZP,{visible:!0,motionAppear:!0,motionName:"wave-motion",motionDeadline:5e3,onAppearEnd:(e,t)=>{var n;if(t.deadline||"opacity"===t.propertyName){let e=null===(n=a.current)||void 0===n?void 0:n.parentElement;(0,h.v)(e).then(()=>{null==e||e.remove()})}return!1}},e=>{let{className:n}=e;return c.createElement("div",{ref:a,className:o()(t,{"wave-quick":R},n),style:k})})};var w=(e,t)=>{var n;let{component:r}=t;if("Checkbox"===r&&!(null===(n=e.querySelector("input"))||void 0===n?void 0:n.checked))return;let o=document.createElement("div");o.style.position="absolute",o.style.left="0px",o.style.top="0px",null==e||e.insertBefore(o,null==e?void 0:e.firstChild),(0,h.s)(c.createElement(x,Object.assign({},t,{target:e})),o)},E=n(29961),S=e=>{let{children:t,disabled:n,component:r}=e,{getPrefixCls:u}=(0,c.useContext)(l.E_),d=(0,c.useRef)(null),g=u("wave"),[,h]=f(g),v=function(e,t,n){let{wave:r}=c.useContext(l.E_),[,o,a]=(0,E.ZP)(),i=(0,p.zX)(i=>{let c=e.current;if((null==r?void 0:r.disabled)||!c)return;let l=c.querySelector(".".concat(b.A))||c,{showEffect:s}=r||{};(s||w)(l,{className:t,token:o,component:n,event:i,hashId:a})}),s=c.useRef();return e=>{m.Z.cancel(s.current),s.current=(0,m.Z)(()=>{i(e)})}}(d,o()(g,h),r);if(c.useEffect(()=>{let e=d.current;if(!e||1!==e.nodeType||n)return;let t=t=>{!(0,i.Z)(t.target)||!e.getAttribute||e.getAttribute("disabled")||e.disabled||e.className.includes("disabled")||e.className.includes("-leave")||v(t)};return e.addEventListener("click",t,!0),()=>{e.removeEventListener("click",t,!0)}},[n]),!c.isValidElement(t))return null!=t?t:null;let y=(0,a.Yr)(t)?(0,a.sQ)(t.ref,d):d;return(0,s.Tm)(t,{ref:y})}},34709:function(e,t,n){"use strict";n.d(t,{A:function(){return r}});let r="ant-wave-target"},95140:function(e,t,n){"use strict";let r=n(2265).createContext(void 0);t.Z=r},52402:function(e,t,n){"use strict";n.d(t,{J:function(){return r}});let r=n(2265).createContext({})},51248:function(e,t,n){"use strict";n.d(t,{Te:function(){return s},aG:function(){return i},hU:function(){return u},nx:function(){return c}});var r=n(2265),o=n(19722);let a=/^[\u4e00-\u9fa5]{2}$/,i=a.test.bind(a);function c(e){return"danger"===e?{danger:!0}:{type:e}}function l(e){return"string"==typeof e}function s(e){return"text"===e||"link"===e}function u(e,t){let n=!1,a=[];return r.Children.forEach(e,e=>{let t=typeof e,r="string"===t||"number"===t;if(n&&r){let t=a.length-1,n=a[t];a[t]="".concat(n).concat(e)}else a.push(e);n=r}),r.Children.map(a,e=>(function(e,t){if(null==e)return;let n=t?" ":"";return"string"!=typeof e&&"number"!=typeof e&&l(e.type)&&i(e.props.children)?(0,o.Tm)(e,{children:e.props.children.split("").join(n)}):l(e)?i(e)?r.createElement("span",null,e.split("").join(n)):r.createElement("span",null,e):(0,o.M2)(e)?r.createElement("span",null,e):e})(e,t))}},73002:function(e,t,n){"use strict";n.d(t,{ZP:function(){return ea}});var r=n(2265),o=n(36760),a=n.n(o),i=n(18694),c=n(28791),l=n(6694),s=n(71744),u=n(86586),d=n(33759),f=n(65658),p=n(29961),m=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let g=r.createContext(void 0);var h=n(51248);let v=(0,r.forwardRef)((e,t)=>{let{className:n,style:o,children:i,prefixCls:c}=e,l=a()("".concat(c,"-icon"),n);return r.createElement("span",{ref:t,className:l,style:o},i)});var b=n(61935),y=n(47970);let x=(0,r.forwardRef)((e,t)=>{let{prefixCls:n,className:o,style:i,iconClassName:c}=e,l=a()("".concat(n,"-loading-icon"),o);return r.createElement(v,{prefixCls:n,className:l,style:i,ref:t},r.createElement(b.Z,{className:c}))}),w=()=>({width:0,opacity:0,transform:"scale(0)"}),E=e=>({width:e.scrollWidth,opacity:1,transform:"scale(1)"});var S=e=>{let{prefixCls:t,loading:n,existIcon:o,className:a,style:i}=e,c=!!n;return o?r.createElement(x,{prefixCls:t,className:a,style:i}):r.createElement(y.ZP,{visible:c,motionName:"".concat(t,"-loading-icon-motion"),motionLeave:c,removeOnLeave:!0,onAppearStart:w,onAppearActive:E,onEnterStart:w,onEnterActive:E,onLeaveStart:E,onLeaveActive:w},(e,n)=>{let{className:o,style:c}=e;return r.createElement(x,{prefixCls:t,className:a,style:Object.assign(Object.assign({},i),c),ref:n,iconClassName:o})})},C=n(352),Z=n(12918),O=n(3104),k=n(80669);let M=(e,t)=>({["> span, > ".concat(e)]:{"&:not(:last-child)":{["&, & > ".concat(e)]:{"&:not(:disabled)":{borderInlineEndColor:t}}},"&:not(:first-child)":{["&, & > ".concat(e)]:{"&:not(:disabled)":{borderInlineStartColor:t}}}}});var R=e=>{let{componentCls:t,fontSize:n,lineWidth:r,groupBorderColor:o,colorErrorHover:a}=e;return{["".concat(t,"-group")]:[{position:"relative",display:"inline-flex",["> span, > ".concat(t)]:{"&:not(:last-child)":{["&, & > ".concat(t)]:{borderStartEndRadius:0,borderEndEndRadius:0}},"&:not(:first-child)":{marginInlineStart:e.calc(r).mul(-1).equal(),["&, & > ".concat(t)]:{borderStartStartRadius:0,borderEndStartRadius:0}}},[t]:{position:"relative",zIndex:1,"&:hover,\n          &:focus,\n          &:active":{zIndex:2},"&[disabled]":{zIndex:0}},["".concat(t,"-icon-only")]:{fontSize:n}},M("".concat(t,"-primary"),o),M("".concat(t,"-danger"),a)]}},j=n(1319);let I=e=>{let{paddingInline:t,onlyIconSize:n,paddingBlock:r}=e;return(0,O.TS)(e,{buttonPaddingHorizontal:t,buttonPaddingVertical:r,buttonIconOnlyFontSize:n})},N=e=>{var t,n,r,o,a,i;let c=null!==(t=e.contentFontSize)&&void 0!==t?t:e.fontSize,l=null!==(n=e.contentFontSizeSM)&&void 0!==n?n:e.fontSize,s=null!==(r=e.contentFontSizeLG)&&void 0!==r?r:e.fontSizeLG,u=null!==(o=e.contentLineHeight)&&void 0!==o?o:(0,j.D)(c),d=null!==(a=e.contentLineHeightSM)&&void 0!==a?a:(0,j.D)(l),f=null!==(i=e.contentLineHeightLG)&&void 0!==i?i:(0,j.D)(s);return{fontWeight:400,defaultShadow:"0 ".concat(e.controlOutlineWidth,"px 0 ").concat(e.controlTmpOutline),primaryShadow:"0 ".concat(e.controlOutlineWidth,"px 0 ").concat(e.controlOutline),dangerShadow:"0 ".concat(e.controlOutlineWidth,"px 0 ").concat(e.colorErrorOutline),primaryColor:e.colorTextLightSolid,dangerColor:e.colorTextLightSolid,borderColorDisabled:e.colorBorder,defaultGhostColor:e.colorBgContainer,ghostBg:"transparent",defaultGhostBorderColor:e.colorBgContainer,paddingInline:e.paddingContentHorizontal-e.lineWidth,paddingInlineLG:e.paddingContentHorizontal-e.lineWidth,paddingInlineSM:8-e.lineWidth,onlyIconSize:e.fontSizeLG,onlyIconSizeSM:e.fontSizeLG-2,onlyIconSizeLG:e.fontSizeLG+2,groupBorderColor:e.colorPrimaryHover,linkHoverBg:"transparent",textHoverBg:e.colorBgTextHover,defaultColor:e.colorText,defaultBg:e.colorBgContainer,defaultBorderColor:e.colorBorder,defaultBorderColorDisabled:e.colorBorder,contentFontSize:c,contentFontSizeSM:l,contentFontSizeLG:s,contentLineHeight:u,contentLineHeightSM:d,contentLineHeightLG:f,paddingBlock:Math.max((e.controlHeight-c*u)/2-e.lineWidth,0),paddingBlockSM:Math.max((e.controlHeightSM-l*d)/2-e.lineWidth,0),paddingBlockLG:Math.max((e.controlHeightLG-s*f)/2-e.lineWidth,0)}},P=e=>{let{componentCls:t,iconCls:n,fontWeight:r}=e;return{[t]:{outline:"none",position:"relative",display:"inline-block",fontWeight:r,whiteSpace:"nowrap",textAlign:"center",backgroundImage:"none",background:"transparent",border:"".concat((0,C.bf)(e.lineWidth)," ").concat(e.lineType," transparent"),cursor:"pointer",transition:"all ".concat(e.motionDurationMid," ").concat(e.motionEaseInOut),userSelect:"none",touchAction:"manipulation",color:e.colorText,"&:disabled > *":{pointerEvents:"none"},"> span":{display:"inline-block"},["".concat(t,"-icon")]:{lineHeight:0},["> ".concat(n," + span, > span + ").concat(n)]:{marginInlineStart:e.marginXS},["&:not(".concat(t,"-icon-only) > ").concat(t,"-icon")]:{["&".concat(t,"-loading-icon, &:not(:last-child)")]:{marginInlineEnd:e.marginXS}},"> a":{color:"currentColor"},"&:not(:disabled)":Object.assign({},(0,Z.Qy)(e)),["&".concat(t,"-two-chinese-chars::first-letter")]:{letterSpacing:"0.34em"},["&".concat(t,"-two-chinese-chars > *:not(").concat(n,")")]:{marginInlineEnd:"-0.34em",letterSpacing:"0.34em"},["&-icon-only".concat(t,"-compact-item")]:{flex:"none"}}}},T=(e,t,n)=>({["&:not(:disabled):not(".concat(e,"-disabled)")]:{"&:hover":t,"&:active":n}}),F=e=>({minWidth:e.controlHeight,paddingInlineStart:0,paddingInlineEnd:0,borderRadius:"50%"}),A=e=>({borderRadius:e.controlHeight,paddingInlineStart:e.calc(e.controlHeight).div(2).equal(),paddingInlineEnd:e.calc(e.controlHeight).div(2).equal()}),z=e=>({cursor:"not-allowed",borderColor:e.borderColorDisabled,color:e.colorTextDisabled,background:e.colorBgContainerDisabled,boxShadow:"none"}),L=(e,t,n,r,o,a,i,c)=>({["&".concat(e,"-background-ghost")]:Object.assign(Object.assign({color:n||void 0,background:t,borderColor:r||void 0,boxShadow:"none"},T(e,Object.assign({background:t},i),Object.assign({background:t},c))),{"&:disabled":{cursor:"not-allowed",color:o||void 0,borderColor:a||void 0}})}),_=e=>({["&:disabled, &".concat(e.componentCls,"-disabled")]:Object.assign({},z(e))}),H=e=>Object.assign({},_(e)),B=e=>({["&:disabled, &".concat(e.componentCls,"-disabled")]:{cursor:"not-allowed",color:e.colorTextDisabled}}),D=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},H(e)),{background:e.defaultBg,borderColor:e.defaultBorderColor,color:e.defaultColor,boxShadow:e.defaultShadow}),T(e.componentCls,{color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})),L(e.componentCls,e.ghostBg,e.defaultGhostColor,e.defaultGhostBorderColor,e.colorTextDisabled,e.colorBorder)),{["&".concat(e.componentCls,"-dangerous")]:Object.assign(Object.assign(Object.assign({color:e.colorError,borderColor:e.colorError},T(e.componentCls,{color:e.colorErrorHover,borderColor:e.colorErrorBorderHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),L(e.componentCls,e.ghostBg,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder)),_(e))}),W=e=>Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},H(e)),{color:e.primaryColor,background:e.colorPrimary,boxShadow:e.primaryShadow}),T(e.componentCls,{color:e.colorTextLightSolid,background:e.colorPrimaryHover},{color:e.colorTextLightSolid,background:e.colorPrimaryActive})),L(e.componentCls,e.ghostBg,e.colorPrimary,e.colorPrimary,e.colorTextDisabled,e.colorBorder,{color:e.colorPrimaryHover,borderColor:e.colorPrimaryHover},{color:e.colorPrimaryActive,borderColor:e.colorPrimaryActive})),{["&".concat(e.componentCls,"-dangerous")]:Object.assign(Object.assign(Object.assign({background:e.colorError,boxShadow:e.dangerShadow,color:e.dangerColor},T(e.componentCls,{background:e.colorErrorHover},{background:e.colorErrorActive})),L(e.componentCls,e.ghostBg,e.colorError,e.colorError,e.colorTextDisabled,e.colorBorder,{color:e.colorErrorHover,borderColor:e.colorErrorHover},{color:e.colorErrorActive,borderColor:e.colorErrorActive})),_(e))}),V=e=>Object.assign(Object.assign({},D(e)),{borderStyle:"dashed"}),q=e=>Object.assign(Object.assign(Object.assign({color:e.colorLink},T(e.componentCls,{color:e.colorLinkHover,background:e.linkHoverBg},{color:e.colorLinkActive})),B(e)),{["&".concat(e.componentCls,"-dangerous")]:Object.assign(Object.assign({color:e.colorError},T(e.componentCls,{color:e.colorErrorHover},{color:e.colorErrorActive})),B(e))}),G=e=>Object.assign(Object.assign(Object.assign({},T(e.componentCls,{color:e.colorText,background:e.textHoverBg},{color:e.colorText,background:e.colorBgTextActive})),B(e)),{["&".concat(e.componentCls,"-dangerous")]:Object.assign(Object.assign({color:e.colorError},B(e)),T(e.componentCls,{color:e.colorErrorHover,background:e.colorErrorBg},{color:e.colorErrorHover,background:e.colorErrorBg}))}),X=e=>{let{componentCls:t}=e;return{["".concat(t,"-default")]:D(e),["".concat(t,"-primary")]:W(e),["".concat(t,"-dashed")]:V(e),["".concat(t,"-link")]:q(e),["".concat(t,"-text")]:G(e),["".concat(t,"-ghost")]:L(e.componentCls,e.ghostBg,e.colorBgContainer,e.colorBgContainer,e.colorTextDisabled,e.colorBorder)}},U=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",{componentCls:n,controlHeight:r,fontSize:o,lineHeight:a,borderRadius:i,buttonPaddingHorizontal:c,iconCls:l,buttonPaddingVertical:s}=e,u="".concat(n,"-icon-only");return[{["".concat(n).concat(t)]:{fontSize:o,lineHeight:a,height:r,padding:"".concat((0,C.bf)(s)," ").concat((0,C.bf)(c)),borderRadius:i,["&".concat(u)]:{width:r,paddingInlineStart:0,paddingInlineEnd:0,["&".concat(n,"-round")]:{width:"auto"},[l]:{fontSize:e.buttonIconOnlyFontSize}},["&".concat(n,"-loading")]:{opacity:e.opacityLoading,cursor:"default"},["".concat(n,"-loading-icon")]:{transition:"width ".concat(e.motionDurationSlow," ").concat(e.motionEaseInOut,", opacity ").concat(e.motionDurationSlow," ").concat(e.motionEaseInOut)}}},{["".concat(n).concat(n,"-circle").concat(t)]:F(e)},{["".concat(n).concat(n,"-round").concat(t)]:A(e)}]},K=e=>U((0,O.TS)(e,{fontSize:e.contentFontSize,lineHeight:e.contentLineHeight})),$=e=>U((0,O.TS)(e,{controlHeight:e.controlHeightSM,fontSize:e.contentFontSizeSM,lineHeight:e.contentLineHeightSM,padding:e.paddingXS,buttonPaddingHorizontal:e.paddingInlineSM,buttonPaddingVertical:e.paddingBlockSM,borderRadius:e.borderRadiusSM,buttonIconOnlyFontSize:e.onlyIconSizeSM}),"".concat(e.componentCls,"-sm")),Y=e=>U((0,O.TS)(e,{controlHeight:e.controlHeightLG,fontSize:e.contentFontSizeLG,lineHeight:e.contentLineHeightLG,buttonPaddingHorizontal:e.paddingInlineLG,buttonPaddingVertical:e.paddingBlockLG,borderRadius:e.borderRadiusLG,buttonIconOnlyFontSize:e.onlyIconSizeLG}),"".concat(e.componentCls,"-lg")),Q=e=>{let{componentCls:t}=e;return{[t]:{["&".concat(t,"-block")]:{width:"100%"}}}};var J=(0,k.I$)("Button",e=>{let t=I(e);return[P(t),$(t),K(t),Y(t),Q(t),X(t),R(t)]},N,{unitless:{fontWeight:!0,contentLineHeight:!0,contentLineHeightSM:!0,contentLineHeightLG:!0}}),ee=n(17691);let et=e=>{let{componentCls:t,calc:n}=e;return{[t]:{["&-compact-item".concat(t,"-primary")]:{["&:not([disabled]) + ".concat(t,"-compact-item").concat(t,"-primary:not([disabled])")]:{position:"relative","&:before":{position:"absolute",top:n(e.lineWidth).mul(-1).equal(),insetInlineStart:n(e.lineWidth).mul(-1).equal(),display:"inline-block",width:e.lineWidth,height:"calc(100% + ".concat((0,C.bf)(e.lineWidth)," * 2)"),backgroundColor:e.colorPrimaryHover,content:'""'}}},"&-compact-vertical-item":{["&".concat(t,"-primary")]:{["&:not([disabled]) + ".concat(t,"-compact-vertical-item").concat(t,"-primary:not([disabled])")]:{position:"relative","&:before":{position:"absolute",top:n(e.lineWidth).mul(-1).equal(),insetInlineStart:n(e.lineWidth).mul(-1).equal(),display:"inline-block",width:"calc(100% + ".concat((0,C.bf)(e.lineWidth)," * 2)"),height:e.lineWidth,backgroundColor:e.colorPrimaryHover,content:'""'}}}}}}};var en=(0,k.bk)(["Button","compact"],e=>{let t=I(e);return[(0,ee.c)(t),function(e){var t;let n="".concat(e.componentCls,"-compact-vertical");return{[n]:Object.assign(Object.assign({},{["&-item:not(".concat(n,"-last-item)")]:{marginBottom:e.calc(e.lineWidth).mul(-1).equal()},"&-item":{"&:hover,&:focus,&:active":{zIndex:2},"&[disabled]":{zIndex:0}}}),(t=e.componentCls,{["&-item:not(".concat(n,"-first-item):not(").concat(n,"-last-item)")]:{borderRadius:0},["&-item".concat(n,"-first-item:not(").concat(n,"-last-item)")]:{["&, &".concat(t,"-sm, &").concat(t,"-lg")]:{borderEndEndRadius:0,borderEndStartRadius:0}},["&-item".concat(n,"-last-item:not(").concat(n,"-first-item)")]:{["&, &".concat(t,"-sm, &").concat(t,"-lg")]:{borderStartStartRadius:0,borderStartEndRadius:0}}}))}}(t),et(t)]},N),er=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let eo=(0,r.forwardRef)((e,t)=>{var n,o;let{loading:p=!1,prefixCls:m,type:b="default",danger:y,shape:x="default",size:w,styles:E,disabled:C,className:Z,rootClassName:O,children:k,icon:M,ghost:R=!1,block:j=!1,htmlType:I="button",classNames:N,style:P={}}=e,T=er(e,["loading","prefixCls","type","danger","shape","size","styles","disabled","className","rootClassName","children","icon","ghost","block","htmlType","classNames","style"]),{getPrefixCls:F,autoInsertSpaceInButton:A,direction:z,button:L}=(0,r.useContext)(s.E_),_=F("btn",m),[H,B,D]=J(_),W=(0,r.useContext)(u.Z),V=null!=C?C:W,q=(0,r.useContext)(g),G=(0,r.useMemo)(()=>(function(e){if("object"==typeof e&&e){let t=null==e?void 0:e.delay;return{loading:(t=Number.isNaN(t)||"number"!=typeof t?0:t)<=0,delay:t}}return{loading:!!e,delay:0}})(p),[p]),[X,U]=(0,r.useState)(G.loading),[K,$]=(0,r.useState)(!1),Y=(0,r.createRef)(),Q=(0,c.sQ)(t,Y),ee=1===r.Children.count(k)&&!M&&!(0,h.Te)(b);(0,r.useEffect)(()=>{let e=null;return G.delay>0?e=setTimeout(()=>{e=null,U(!0)},G.delay):U(G.loading),function(){e&&(clearTimeout(e),e=null)}},[G]),(0,r.useEffect)(()=>{if(!Q||!Q.current||!1===A)return;let e=Q.current.textContent;ee&&(0,h.aG)(e)?K||$(!0):K&&$(!1)},[Q]);let et=t=>{let{onClick:n}=e;if(X||V){t.preventDefault();return}null==n||n(t)},eo=!1!==A,{compactSize:ea,compactItemClassnames:ei}=(0,f.ri)(_,z),ec=(0,d.Z)(e=>{var t,n;return null!==(n=null!==(t=null!=w?w:ea)&&void 0!==t?t:q)&&void 0!==n?n:e}),el=ec&&({large:"lg",small:"sm",middle:void 0})[ec]||"",es=X?"loading":M,eu=(0,i.Z)(T,["navigate"]),ed=a()(_,B,D,{["".concat(_,"-").concat(x)]:"default"!==x&&x,["".concat(_,"-").concat(b)]:b,["".concat(_,"-").concat(el)]:el,["".concat(_,"-icon-only")]:!k&&0!==k&&!!es,["".concat(_,"-background-ghost")]:R&&!(0,h.Te)(b),["".concat(_,"-loading")]:X,["".concat(_,"-two-chinese-chars")]:K&&eo&&!X,["".concat(_,"-block")]:j,["".concat(_,"-dangerous")]:!!y,["".concat(_,"-rtl")]:"rtl"===z},ei,Z,O,null==L?void 0:L.className),ef=Object.assign(Object.assign({},null==L?void 0:L.style),P),ep=a()(null==N?void 0:N.icon,null===(n=null==L?void 0:L.classNames)||void 0===n?void 0:n.icon),em=Object.assign(Object.assign({},(null==E?void 0:E.icon)||{}),(null===(o=null==L?void 0:L.styles)||void 0===o?void 0:o.icon)||{}),eg=M&&!X?r.createElement(v,{prefixCls:_,className:ep,style:em},M):r.createElement(S,{existIcon:!!M,prefixCls:_,loading:!!X}),eh=k||0===k?(0,h.hU)(k,ee&&eo):null;if(void 0!==eu.href)return H(r.createElement("a",Object.assign({},eu,{className:a()(ed,{["".concat(_,"-disabled")]:V}),href:V?void 0:eu.href,style:ef,onClick:et,ref:Q,tabIndex:V?-1:0}),eg,eh));let ev=r.createElement("button",Object.assign({},T,{type:I,className:ed,style:ef,onClick:et,disabled:V,ref:Q}),eg,eh,!!ei&&r.createElement(en,{key:"compact",prefixCls:_}));return(0,h.Te)(b)||(ev=r.createElement(l.Z,{component:"Button",disabled:!!X},ev)),H(ev)});eo.Group=e=>{let{getPrefixCls:t,direction:n}=r.useContext(s.E_),{prefixCls:o,size:i,className:c}=e,l=m(e,["prefixCls","size","className"]),u=t("btn-group",o),[,,d]=(0,p.ZP)(),f="";switch(i){case"large":f="lg";break;case"small":f="sm"}let h=a()(u,{["".concat(u,"-").concat(f)]:f,["".concat(u,"-rtl")]:"rtl"===n},c,d);return r.createElement(g.Provider,{value:i},r.createElement("div",Object.assign({},l,{className:h})))},eo.__ANT_BUTTON=!0;var ea=eo},86586:function(e,t,n){"use strict";n.d(t,{n:function(){return a}});var r=n(2265);let o=r.createContext(!1),a=e=>{let{children:t,disabled:n}=e,a=r.useContext(o);return r.createElement(o.Provider,{value:null!=n?n:a},t)};t.Z=o},59189:function(e,t,n){"use strict";n.d(t,{q:function(){return a}});var r=n(2265);let o=r.createContext(void 0),a=e=>{let{children:t,size:n}=e,a=r.useContext(o);return r.createElement(o.Provider,{value:n||a},t)};t.Z=o},71744:function(e,t,n){"use strict";n.d(t,{E_:function(){return a},oR:function(){return o}});var r=n(2265);let o="anticon",a=r.createContext({getPrefixCls:(e,t)=>t||(e?"ant-".concat(e):"ant"),iconPrefixCls:o}),{Consumer:i}=a},91086:function(e,t,n){"use strict";var r=n(2265),o=n(71744),a=n(85180);t.Z=e=>{let{componentName:t}=e,{getPrefixCls:n}=(0,r.useContext)(o.E_),i=n("empty");switch(t){case"Table":case"List":return r.createElement(a.Z,{image:a.Z.PRESENTED_IMAGE_SIMPLE});case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":return r.createElement(a.Z,{image:a.Z.PRESENTED_IMAGE_SIMPLE,className:"".concat(i,"-small")});default:return r.createElement(a.Z,null)}}},64024:function(e,t,n){"use strict";var r=n(29961);t.Z=e=>{let[,,,,t]=(0,r.ZP)();return t?"".concat(e,"-css-var"):""}},33759:function(e,t,n){"use strict";var r=n(2265),o=n(59189);t.Z=e=>{let t=r.useContext(o.Z);return r.useMemo(()=>e?"string"==typeof e?null!=e?e:t:e instanceof Function?e(t):t:t,[e,t])}},13959:function(e,t,n){"use strict";let r,o,a,i;n.d(t,{ZP:function(){return V},w6:function(){return B}});var c=n(2265),l=n.t(c,2),s=n(352),u=n(20902),d=n(6397),f=n(23789),p=n(13613),m=n(77360),g=n(92246),h=n(91325),v=e=>{let{locale:t={},children:n,_ANT_MARK__:r}=e;c.useEffect(()=>(0,g.f)(t&&t.Modal),[t]);let o=c.useMemo(()=>Object.assign(Object.assign({},t),{exist:!0}),[t]);return c.createElement(h.Z.Provider,{value:o},n)},b=n(13823),y=n(37516),x=n(70774),w=n(71744),E=n(31373),S=n(36360),C=n(94981),Z=n(21717);let O="-ant-".concat(Date.now(),"-").concat(Math.random());var k=n(86586),M=n(59189),R=n(16671);let{useId:j}=Object.assign({},l);var I=void 0===j?()=>"":j,N=n(47970),P=n(29961);function T(e){let{children:t}=e,[,n]=(0,P.ZP)(),{motion:r}=n,o=c.useRef(!1);return(o.current=o.current||!1===r,o.current)?c.createElement(N.zt,{motion:r},t):t}var F=()=>null,A=n(36198),z=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let L=["getTargetContainer","getPopupContainer","renderEmpty","pageHeader","input","pagination","form","select","button"];function _(){return r||"ant"}function H(){return o||w.oR}let B=()=>({getPrefixCls:(e,t)=>t||(e?"".concat(_(),"-").concat(e):_()),getIconPrefixCls:H,getRootPrefixCls:()=>r||_(),getTheme:()=>a,holderRender:i}),D=e=>{let{children:t,csp:n,autoInsertSpaceInButton:r,alert:o,anchor:a,form:i,locale:l,componentSize:g,direction:h,space:E,virtual:S,dropdownMatchSelectWidth:C,popupMatchSelectWidth:Z,popupOverflow:O,legacyLocale:j,parentContext:N,iconPrefixCls:P,theme:_,componentDisabled:H,segmented:B,statistic:D,spin:W,calendar:V,carousel:q,cascader:G,collapse:X,typography:U,checkbox:K,descriptions:$,divider:Y,drawer:Q,skeleton:J,steps:ee,image:et,layout:en,list:er,mentions:eo,modal:ea,progress:ei,result:ec,slider:el,breadcrumb:es,menu:eu,pagination:ed,input:ef,empty:ep,badge:em,radio:eg,rate:eh,switch:ev,transfer:eb,avatar:ey,message:ex,tag:ew,table:eE,card:eS,tabs:eC,timeline:eZ,timePicker:eO,upload:ek,notification:eM,tree:eR,colorPicker:ej,datePicker:eI,rangePicker:eN,flex:eP,wave:eT,dropdown:eF,warning:eA}=e,ez=c.useCallback((t,n)=>{let{prefixCls:r}=e;if(n)return n;let o=r||N.getPrefixCls("");return t?"".concat(o,"-").concat(t):o},[N.getPrefixCls,e.prefixCls]),eL=P||N.iconPrefixCls||w.oR,e_=n||N.csp;(0,A.Z)(eL,e_);let eH=function(e,t){(0,p.ln)("ConfigProvider");let n=e||{},r=!1!==n.inherit&&t?t:y.u_,o=I();return(0,d.Z)(()=>{var a,i;if(!e)return t;let c=Object.assign({},r.components);Object.keys(e.components||{}).forEach(t=>{c[t]=Object.assign(Object.assign({},c[t]),e.components[t])});let l="css-var-".concat(o.replace(/:/g,"")),s=(null!==(a=n.cssVar)&&void 0!==a?a:r.cssVar)&&Object.assign(Object.assign(Object.assign({prefix:"ant"},"object"==typeof r.cssVar?r.cssVar:{}),"object"==typeof n.cssVar?n.cssVar:{}),{key:"object"==typeof n.cssVar&&(null===(i=n.cssVar)||void 0===i?void 0:i.key)||l});return Object.assign(Object.assign(Object.assign({},r),n),{token:Object.assign(Object.assign({},r.token),n.token),components:c,cssVar:s})},[n,r],(e,t)=>e.some((e,n)=>{let r=t[n];return!(0,R.Z)(e,r,!0)}))}(_,N.theme),eB={csp:e_,autoInsertSpaceInButton:r,alert:o,anchor:a,locale:l||j,direction:h,space:E,virtual:S,popupMatchSelectWidth:null!=Z?Z:C,popupOverflow:O,getPrefixCls:ez,iconPrefixCls:eL,theme:eH,segmented:B,statistic:D,spin:W,calendar:V,carousel:q,cascader:G,collapse:X,typography:U,checkbox:K,descriptions:$,divider:Y,drawer:Q,skeleton:J,steps:ee,image:et,input:ef,layout:en,list:er,mentions:eo,modal:ea,progress:ei,result:ec,slider:el,breadcrumb:es,menu:eu,pagination:ed,empty:ep,badge:em,radio:eg,rate:eh,switch:ev,transfer:eb,avatar:ey,message:ex,tag:ew,table:eE,card:eS,tabs:eC,timeline:eZ,timePicker:eO,upload:ek,notification:eM,tree:eR,colorPicker:ej,datePicker:eI,rangePicker:eN,flex:eP,wave:eT,dropdown:eF,warning:eA},eD=Object.assign({},N);Object.keys(eB).forEach(e=>{void 0!==eB[e]&&(eD[e]=eB[e])}),L.forEach(t=>{let n=e[t];n&&(eD[t]=n)});let eW=(0,d.Z)(()=>eD,eD,(e,t)=>{let n=Object.keys(e),r=Object.keys(t);return n.length!==r.length||n.some(n=>e[n]!==t[n])}),eV=c.useMemo(()=>({prefixCls:eL,csp:e_}),[eL,e_]),eq=c.createElement(c.Fragment,null,c.createElement(F,{dropdownMatchSelectWidth:C}),t),eG=c.useMemo(()=>{var e,t,n,r;return(0,f.T)((null===(e=b.Z.Form)||void 0===e?void 0:e.defaultValidateMessages)||{},(null===(n=null===(t=eW.locale)||void 0===t?void 0:t.Form)||void 0===n?void 0:n.defaultValidateMessages)||{},(null===(r=eW.form)||void 0===r?void 0:r.validateMessages)||{},(null==i?void 0:i.validateMessages)||{})},[eW,null==i?void 0:i.validateMessages]);Object.keys(eG).length>0&&(eq=c.createElement(m.Z.Provider,{value:eG},eq)),l&&(eq=c.createElement(v,{locale:l,_ANT_MARK__:"internalMark"},eq)),(eL||e_)&&(eq=c.createElement(u.Z.Provider,{value:eV},eq)),g&&(eq=c.createElement(M.q,{size:g},eq)),eq=c.createElement(T,null,eq);let eX=c.useMemo(()=>{let e=eH||{},{algorithm:t,token:n,components:r,cssVar:o}=e,a=z(e,["algorithm","token","components","cssVar"]),i=t&&(!Array.isArray(t)||t.length>0)?(0,s.jG)(t):y.uH,c={};Object.entries(r||{}).forEach(e=>{let[t,n]=e,r=Object.assign({},n);"algorithm"in r&&(!0===r.algorithm?r.theme=i:(Array.isArray(r.algorithm)||"function"==typeof r.algorithm)&&(r.theme=(0,s.jG)(r.algorithm)),delete r.algorithm),c[t]=r});let l=Object.assign(Object.assign({},x.Z),n);return Object.assign(Object.assign({},a),{theme:i,token:l,components:c,override:Object.assign({override:l},c),cssVar:o})},[eH]);return _&&(eq=c.createElement(y.Mj.Provider,{value:eX},eq)),eW.warning&&(eq=c.createElement(p.G8.Provider,{value:eW.warning},eq)),void 0!==H&&(eq=c.createElement(k.n,{disabled:H},eq)),c.createElement(w.E_.Provider,{value:eW},eq)},W=e=>{let t=c.useContext(w.E_),n=c.useContext(h.Z);return c.createElement(D,Object.assign({parentContext:t,legacyLocale:n},e))};W.ConfigContext=w.E_,W.SizeContext=M.Z,W.config=e=>{let{prefixCls:t,iconPrefixCls:n,theme:c,holderRender:l}=e;void 0!==t&&(r=t),void 0!==n&&(o=n),"holderRender"in e&&(i=l),c&&(Object.keys(c).some(e=>e.endsWith("Color"))?function(e,t){let n=function(e,t){let n={},r=(e,t)=>{let n=e.clone();return(n=(null==t?void 0:t(n))||n).toRgbString()},o=(e,t)=>{let o=new S.C(e),a=(0,E.R_)(o.toRgbString());n["".concat(t,"-color")]=r(o),n["".concat(t,"-color-disabled")]=a[1],n["".concat(t,"-color-hover")]=a[4],n["".concat(t,"-color-active")]=a[6],n["".concat(t,"-color-outline")]=o.clone().setAlpha(.2).toRgbString(),n["".concat(t,"-color-deprecated-bg")]=a[0],n["".concat(t,"-color-deprecated-border")]=a[2]};if(t.primaryColor){o(t.primaryColor,"primary");let e=new S.C(t.primaryColor),a=(0,E.R_)(e.toRgbString());a.forEach((e,t)=>{n["primary-".concat(t+1)]=e}),n["primary-color-deprecated-l-35"]=r(e,e=>e.lighten(35)),n["primary-color-deprecated-l-20"]=r(e,e=>e.lighten(20)),n["primary-color-deprecated-t-20"]=r(e,e=>e.tint(20)),n["primary-color-deprecated-t-50"]=r(e,e=>e.tint(50)),n["primary-color-deprecated-f-12"]=r(e,e=>e.setAlpha(.12*e.getAlpha()));let i=new S.C(a[0]);n["primary-color-active-deprecated-f-30"]=r(i,e=>e.setAlpha(.3*e.getAlpha())),n["primary-color-active-deprecated-d-02"]=r(i,e=>e.darken(2))}t.successColor&&o(t.successColor,"success"),t.warningColor&&o(t.warningColor,"warning"),t.errorColor&&o(t.errorColor,"error"),t.infoColor&&o(t.infoColor,"info");let a=Object.keys(n).map(t=>"--".concat(e,"-").concat(t,": ").concat(n[t],";"));return"\n  :root {\n    ".concat(a.join("\n"),"\n  }\n  ").trim()}(e,t);(0,C.Z)()&&(0,Z.hq)(n,"".concat(O,"-dynamic-theme"))}(_(),c):a=c)},W.useConfig=function(){return{componentDisabled:(0,c.useContext)(k.Z),componentSize:(0,c.useContext)(M.Z)}},Object.defineProperty(W,"SizeContext",{get:()=>M.Z});var V=W},85180:function(e,t,n){"use strict";n.d(t,{Z:function(){return b}});var r=n(36760),o=n.n(r),a=n(2265),i=n(71744),c=n(55274),l=n(36360),s=n(29961),u=n(80669),d=n(3104);let f=e=>{let{componentCls:t,margin:n,marginXS:r,marginXL:o,fontSize:a,lineHeight:i}=e;return{[t]:{marginInline:r,fontSize:a,lineHeight:i,textAlign:"center",["".concat(t,"-image")]:{height:e.emptyImgHeight,marginBottom:r,opacity:e.opacityImage,img:{height:"100%"},svg:{maxWidth:"100%",height:"100%",margin:"auto"}},["".concat(t,"-description")]:{color:e.colorText},["".concat(t,"-footer")]:{marginTop:n},"&-normal":{marginBlock:o,color:e.colorTextDisabled,["".concat(t,"-description")]:{color:e.colorTextDisabled},["".concat(t,"-image")]:{height:e.emptyImgHeightMD}},"&-small":{marginBlock:r,color:e.colorTextDisabled,["".concat(t,"-image")]:{height:e.emptyImgHeightSM}}}}};var p=(0,u.I$)("Empty",e=>{let{componentCls:t,controlHeightLG:n,calc:r}=e;return[f((0,d.TS)(e,{emptyImgCls:"".concat(t,"-img"),emptyImgHeight:r(n).mul(2.5).equal(),emptyImgHeightMD:n,emptyImgHeightSM:r(n).mul(.875).equal()}))]}),m=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let g=a.createElement(()=>{let[,e]=(0,s.ZP)(),t=new l.C(e.colorBgBase).toHsl().l<.5?{opacity:.65}:{};return a.createElement("svg",{style:t,width:"184",height:"152",viewBox:"0 0 184 152",xmlns:"http://www.w3.org/2000/svg"},a.createElement("g",{fill:"none",fillRule:"evenodd"},a.createElement("g",{transform:"translate(24 31.67)"},a.createElement("ellipse",{fillOpacity:".8",fill:"#F5F5F7",cx:"67.797",cy:"106.89",rx:"67.797",ry:"12.668"}),a.createElement("path",{d:"M122.034 69.674L98.109 40.229c-1.148-1.386-2.826-2.225-4.593-2.225h-51.44c-1.766 0-3.444.839-4.592 2.225L13.56 69.674v15.383h108.475V69.674z",fill:"#AEB8C2"}),a.createElement("path",{d:"M101.537 86.214L80.63 61.102c-1.001-1.207-2.507-1.867-4.048-1.867H31.724c-1.54 0-3.047.66-4.048 1.867L6.769 86.214v13.792h94.768V86.214z",fill:"url(#linearGradient-1)",transform:"translate(13.56)"}),a.createElement("path",{d:"M33.83 0h67.933a4 4 0 0 1 4 4v93.344a4 4 0 0 1-4 4H33.83a4 4 0 0 1-4-4V4a4 4 0 0 1 4-4z",fill:"#F5F5F7"}),a.createElement("path",{d:"M42.678 9.953h50.237a2 2 0 0 1 2 2V36.91a2 2 0 0 1-2 2H42.678a2 2 0 0 1-2-2V11.953a2 2 0 0 1 2-2zM42.94 49.767h49.713a2.262 2.262 0 1 1 0 4.524H42.94a2.262 2.262 0 0 1 0-4.524zM42.94 61.53h49.713a2.262 2.262 0 1 1 0 4.525H42.94a2.262 2.262 0 0 1 0-4.525zM121.813 105.032c-.775 3.071-3.497 5.36-6.735 5.36H20.515c-3.238 0-5.96-2.29-6.734-5.36a7.309 7.309 0 0 1-.222-1.79V69.675h26.318c2.907 0 5.25 2.448 5.25 5.42v.04c0 2.971 2.37 5.37 5.277 5.37h34.785c2.907 0 5.277-2.421 5.277-5.393V75.1c0-2.972 2.343-5.426 5.25-5.426h26.318v33.569c0 .617-.077 1.216-.221 1.789z",fill:"#DCE0E6"})),a.createElement("path",{d:"M149.121 33.292l-6.83 2.65a1 1 0 0 1-1.317-1.23l1.937-6.207c-2.589-2.944-4.109-6.534-4.109-10.408C138.802 8.102 148.92 0 161.402 0 173.881 0 184 8.102 184 18.097c0 9.995-10.118 18.097-22.599 18.097-4.528 0-8.744-1.066-12.28-2.902z",fill:"#DCE0E6"}),a.createElement("g",{transform:"translate(149.65 15.383)",fill:"#FFF"},a.createElement("ellipse",{cx:"20.654",cy:"3.167",rx:"2.849",ry:"2.815"}),a.createElement("path",{d:"M5.698 5.63H0L2.898.704zM9.259.704h4.985V5.63H9.259z"}))))},null),h=a.createElement(()=>{let[,e]=(0,s.ZP)(),{colorFill:t,colorFillTertiary:n,colorFillQuaternary:r,colorBgContainer:o}=e,{borderColor:i,shadowColor:c,contentColor:u}=(0,a.useMemo)(()=>({borderColor:new l.C(t).onBackground(o).toHexShortString(),shadowColor:new l.C(n).onBackground(o).toHexShortString(),contentColor:new l.C(r).onBackground(o).toHexShortString()}),[t,n,r,o]);return a.createElement("svg",{width:"64",height:"41",viewBox:"0 0 64 41",xmlns:"http://www.w3.org/2000/svg"},a.createElement("g",{transform:"translate(0 1)",fill:"none",fillRule:"evenodd"},a.createElement("ellipse",{fill:c,cx:"32",cy:"33",rx:"32",ry:"7"}),a.createElement("g",{fillRule:"nonzero",stroke:i},a.createElement("path",{d:"M55 12.76L44.854 1.258C44.367.474 43.656 0 42.907 0H21.093c-.749 0-1.46.474-1.947 1.257L9 12.761V22h46v-9.24z"}),a.createElement("path",{d:"M41.613 15.931c0-1.605.994-2.93 2.227-2.931H55v18.137C55 33.26 53.68 35 52.05 35h-40.1C10.32 35 9 33.259 9 31.137V13h11.16c1.233 0 2.227 1.323 2.227 2.928v.022c0 1.605 1.005 2.901 2.237 2.901h14.752c1.232 0 2.237-1.308 2.237-2.913v-.007z",fill:u}))))},null),v=e=>{var{className:t,rootClassName:n,prefixCls:r,image:l=g,description:s,children:u,imageStyle:d,style:f}=e,v=m(e,["className","rootClassName","prefixCls","image","description","children","imageStyle","style"]);let{getPrefixCls:b,direction:y,empty:x}=a.useContext(i.E_),w=b("empty",r),[E,S,C]=p(w),[Z]=(0,c.Z)("Empty"),O=void 0!==s?s:null==Z?void 0:Z.description,k=null;return k="string"==typeof l?a.createElement("img",{alt:"string"==typeof O?O:"empty",src:l}):l,E(a.createElement("div",Object.assign({className:o()(S,C,w,null==x?void 0:x.className,{["".concat(w,"-normal")]:l===h,["".concat(w,"-rtl")]:"rtl"===y},t,n),style:Object.assign(Object.assign({},null==x?void 0:x.style),f)},v),a.createElement("div",{className:"".concat(w,"-image"),style:d},k),O&&a.createElement("div",{className:"".concat(w,"-description")},O),u&&a.createElement("div",{className:"".concat(w,"-footer")},u)))};v.PRESENTED_IMAGE_DEFAULT=g,v.PRESENTED_IMAGE_SIMPLE=h;var b=v},14605:function(e,t,n){"use strict";var r=n(83145),o=n(36760),a=n.n(o),i=n(47970),c=n(2265),l=n(68710),s=n(39109),u=n(4064),d=n(47713),f=n(64024);let p=[];function m(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;return{key:"string"==typeof e?e:"".concat(t,"-").concat(r),error:e,errorStatus:n}}t.Z=e=>{let{help:t,helpStatus:n,errors:o=p,warnings:g=p,className:h,fieldId:v,onVisibleChanged:b}=e,{prefixCls:y}=c.useContext(s.Rk),x="".concat(y,"-item-explain"),w=(0,f.Z)(y),[E,S,C]=(0,d.ZP)(y,w),Z=(0,c.useMemo)(()=>(0,l.Z)(y),[y]),O=(0,u.Z)(o),k=(0,u.Z)(g),M=c.useMemo(()=>null!=t?[m(t,"help",n)]:[].concat((0,r.Z)(O.map((e,t)=>m(e,"error","error",t))),(0,r.Z)(k.map((e,t)=>m(e,"warning","warning",t)))),[t,n,O,k]),R={};return v&&(R.id="".concat(v,"_help")),E(c.createElement(i.ZP,{motionDeadline:Z.motionDeadline,motionName:"".concat(y,"-show-help"),visible:!!M.length,onVisibleChanged:b},e=>{let{className:t,style:n}=e;return c.createElement("div",Object.assign({},R,{className:a()(x,t,C,w,h,S),style:n,role:"alert"}),c.createElement(i.V4,Object.assign({keys:M},(0,l.Z)(y),{motionName:"".concat(y,"-show-help-item"),component:!1}),e=>{let{key:t,error:n,errorStatus:r,className:o,style:i}=e;return c.createElement("div",{key:t,className:a()(o,{["".concat(x,"-").concat(r)]:r}),style:i},n)}))}))}},38994:function(e,t,n){"use strict";n.d(t,{Z:function(){return U}});var r=n(83145),o=n(2265),a=n(36760),i=n.n(a),c=n(64834),l=n(69819),s=n(28791),u=n(19722),d=n(13613),f=n(71744),p=n(64024),m=n(39109),g=n(45287);let h=()=>{let{status:e,errors:t=[],warnings:n=[]}=(0,o.useContext)(m.aM);return{status:e,errors:t,warnings:n}};h.Context=m.aM;var v=n(53346),b=n(47713),y=n(13861),x=n(2857),w=n(27380),E=n(18694),S=n(10295),C=n(54998),Z=n(14605),O=n(80669);let k=e=>{let{formItemCls:t}=e;return{"@media screen and (-ms-high-contrast: active), (-ms-high-contrast: none)":{["".concat(t,"-control")]:{display:"flex"}}}};var M=(0,O.bk)(["Form","item-item"],(e,t)=>{let{rootPrefixCls:n}=t;return[k((0,b.B4)(e,n))]}),R=e=>{let{prefixCls:t,status:n,wrapperCol:r,children:a,errors:c,warnings:l,_internalItemRender:s,extra:u,help:d,fieldId:f,marginBottom:p,onErrorVisibleChanged:g}=e,h="".concat(t,"-item"),v=o.useContext(m.q3),b=r||v.wrapperCol||{},y=i()("".concat(h,"-control"),b.className),x=o.useMemo(()=>Object.assign({},v),[v]);delete x.labelCol,delete x.wrapperCol;let w=o.createElement("div",{className:"".concat(h,"-control-input")},o.createElement("div",{className:"".concat(h,"-control-input-content")},a)),E=o.useMemo(()=>({prefixCls:t,status:n}),[t,n]),S=null!==p||c.length||l.length?o.createElement("div",{style:{display:"flex",flexWrap:"nowrap"}},o.createElement(m.Rk.Provider,{value:E},o.createElement(Z.Z,{fieldId:f,errors:c,warnings:l,help:d,helpStatus:n,className:"".concat(h,"-explain-connected"),onVisibleChanged:g})),!!p&&o.createElement("div",{style:{width:0,height:p}})):null,O={};f&&(O.id="".concat(f,"_extra"));let k=u?o.createElement("div",Object.assign({},O,{className:"".concat(h,"-extra")}),u):null,R=s&&"pro_table_render"===s.mark&&s.render?s.render(e,{input:w,errorList:S,extra:k}):o.createElement(o.Fragment,null,w,S,k);return o.createElement(m.q3.Provider,{value:x},o.createElement(C.Z,Object.assign({},b,{className:y}),R),o.createElement(M,{prefixCls:t}))},j=n(67187),I=n(13823),N=n(55274),P=n(89970),T=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n},F=e=>{var t;let{prefixCls:n,label:r,htmlFor:a,labelCol:c,labelAlign:l,colon:s,required:u,requiredMark:d,tooltip:f}=e,[p]=(0,N.Z)("Form"),{vertical:g,labelAlign:h,labelCol:v,labelWrap:b,colon:y}=o.useContext(m.q3);if(!r)return null;let x=c||v||{},w="".concat(n,"-item-label"),E=i()(w,"left"===(l||h)&&"".concat(w,"-left"),x.className,{["".concat(w,"-wrap")]:!!b}),S=r,Z=!0===s||!1!==y&&!1!==s;Z&&!g&&"string"==typeof r&&""!==r.trim()&&(S=r.replace(/[:|:]\s*$/,""));let O=f?"object"!=typeof f||o.isValidElement(f)?{title:f}:f:null;if(O){let{icon:e=o.createElement(j.Z,null)}=O,t=T(O,["icon"]),r=o.createElement(P.Z,Object.assign({},t),o.cloneElement(e,{className:"".concat(n,"-item-tooltip"),title:"",onClick:e=>{e.preventDefault()},tabIndex:null}));S=o.createElement(o.Fragment,null,S,r)}let k="optional"===d,M="function"==typeof d;M?S=d(S,{required:!!u}):k&&!u&&(S=o.createElement(o.Fragment,null,S,o.createElement("span",{className:"".concat(n,"-item-optional"),title:""},(null==p?void 0:p.optional)||(null===(t=I.Z.Form)||void 0===t?void 0:t.optional))));let R=i()({["".concat(n,"-item-required")]:u,["".concat(n,"-item-required-mark-optional")]:k||M,["".concat(n,"-item-no-colon")]:!Z});return o.createElement(C.Z,Object.assign({},x,{className:E}),o.createElement("label",{htmlFor:a,className:R,title:"string"==typeof r?r:""},S))},A=n(4064),z=n(8900),L=n(39725),_=n(54537),H=n(61935);let B={success:z.Z,warning:_.Z,error:L.Z,validating:H.Z};function D(e){let{children:t,errors:n,warnings:r,hasFeedback:a,validateStatus:c,prefixCls:l,meta:s,noStyle:u}=e,d="".concat(l,"-item"),{feedbackIcons:f}=o.useContext(m.q3),p=(0,y.lR)(n,r,s,null,!!a,c),{isFormItemInput:g,status:h,hasFeedback:v,feedbackIcon:b}=o.useContext(m.aM),x=o.useMemo(()=>{var e;let t;if(a){let c=!0!==a&&a.icons||f,l=p&&(null===(e=null==c?void 0:c({status:p,errors:n,warnings:r}))||void 0===e?void 0:e[p]),s=p&&B[p];t=!1!==l&&s?o.createElement("span",{className:i()("".concat(d,"-feedback-icon"),"".concat(d,"-feedback-icon-").concat(p))},l||o.createElement(s,null)):null}let c={status:p||"",errors:n,warnings:r,hasFeedback:!!a,feedbackIcon:t,isFormItemInput:!0};return u&&(c.status=(null!=p?p:h)||"",c.isFormItemInput=g,c.hasFeedback=!!(null!=a?a:v),c.feedbackIcon=void 0!==a?c.feedbackIcon:b),c},[p,a,u,g,h]);return o.createElement(m.aM.Provider,{value:x},t)}var W=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function V(e){let{prefixCls:t,className:n,rootClassName:r,style:a,help:c,errors:l,warnings:s,validateStatus:u,meta:d,hasFeedback:f,hidden:p,children:g,fieldId:h,required:v,isRequired:b,onSubItemMetaChange:C}=e,Z=W(e,["prefixCls","className","rootClassName","style","help","errors","warnings","validateStatus","meta","hasFeedback","hidden","children","fieldId","required","isRequired","onSubItemMetaChange"]),O="".concat(t,"-item"),{requiredMark:k}=o.useContext(m.q3),M=o.useRef(null),j=(0,A.Z)(l),I=(0,A.Z)(s),N=null!=c,P=!!(N||l.length||s.length),T=!!M.current&&(0,x.Z)(M.current),[z,L]=o.useState(null);(0,w.Z)(()=>{P&&M.current&&L(parseInt(getComputedStyle(M.current).marginBottom,10))},[P,T]);let _=function(){let e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=e?j:d.errors,n=e?I:d.warnings;return(0,y.lR)(t,n,d,"",!!f,u)}(),H=i()(O,n,r,{["".concat(O,"-with-help")]:N||j.length||I.length,["".concat(O,"-has-feedback")]:_&&f,["".concat(O,"-has-success")]:"success"===_,["".concat(O,"-has-warning")]:"warning"===_,["".concat(O,"-has-error")]:"error"===_,["".concat(O,"-is-validating")]:"validating"===_,["".concat(O,"-hidden")]:p});return o.createElement("div",{className:H,style:a,ref:M},o.createElement(S.Z,Object.assign({className:"".concat(O,"-row")},(0,E.Z)(Z,["_internalItemRender","colon","dependencies","extra","fieldKey","getValueFromEvent","getValueProps","htmlFor","id","initialValue","isListField","label","labelAlign","labelCol","labelWrap","messageVariables","name","normalize","noStyle","preserve","requiredMark","rules","shouldUpdate","trigger","tooltip","validateFirst","validateTrigger","valuePropName","wrapperCol","validateDebounce"])),o.createElement(F,Object.assign({htmlFor:h},e,{requiredMark:k,required:null!=v?v:b,prefixCls:t})),o.createElement(R,Object.assign({},e,d,{errors:j,warnings:I,prefixCls:t,status:_,help:c,marginBottom:z,onErrorVisibleChanged:e=>{e||L(null)}}),o.createElement(m.qI.Provider,{value:C},o.createElement(D,{prefixCls:t,meta:d,errors:d.errors,warnings:d.warnings,hasFeedback:f,validateStatus:_},g)))),!!z&&o.createElement("div",{className:"".concat(O,"-margin-offset"),style:{marginBottom:-z}}))}let q=o.memo(e=>{let{children:t}=e;return t},(e,t)=>(function(e,t){let n=Object.keys(e),r=Object.keys(t);return n.length===r.length&&n.every(n=>{let r=e[n],o=t[n];return r===o||"function"==typeof r||"function"==typeof o})})(e.control,t.control)&&e.update===t.update&&e.childProps.length===t.childProps.length&&e.childProps.every((e,n)=>e===t.childProps[n]));function G(){return{errors:[],warnings:[],touched:!1,validating:!1,name:[],validated:!1}}let X=function(e){let{name:t,noStyle:n,className:a,dependencies:h,prefixCls:x,shouldUpdate:w,rules:E,children:S,required:C,label:Z,messageVariables:O,trigger:k="onChange",validateTrigger:M,hidden:R,help:j}=e,{getPrefixCls:I}=o.useContext(f.E_),{name:N}=o.useContext(m.q3),P=function(e){if("function"==typeof e)return e;let t=(0,g.Z)(e);return t.length<=1?t[0]:t}(S),T="function"==typeof P,F=o.useContext(m.qI),{validateTrigger:A}=o.useContext(c.zb),z=void 0!==M?M:A,L=null!=t,_=I("form",x),H=(0,p.Z)(_),[B,W,X]=(0,b.ZP)(_,H);(0,d.ln)("Form.Item");let U=o.useContext(c.ZM),K=o.useRef(),[$,Y]=function(e){let[t,n]=o.useState(e),r=(0,o.useRef)(null),a=(0,o.useRef)([]),i=(0,o.useRef)(!1);return o.useEffect(()=>(i.current=!1,()=>{i.current=!0,v.Z.cancel(r.current),r.current=null}),[]),[t,function(e){i.current||(null===r.current&&(a.current=[],r.current=(0,v.Z)(()=>{r.current=null,n(e=>{let t=e;return a.current.forEach(e=>{t=e(t)}),t})})),a.current.push(e))}]}({}),[Q,J]=(0,l.Z)(()=>G()),ee=(e,t)=>{Y(n=>{let o=Object.assign({},n),a=[].concat((0,r.Z)(e.name.slice(0,-1)),(0,r.Z)(t)).join("__SPLIT__");return e.destroy?delete o[a]:o[a]=e,o})},[et,en]=o.useMemo(()=>{let e=(0,r.Z)(Q.errors),t=(0,r.Z)(Q.warnings);return Object.values($).forEach(n=>{e.push.apply(e,(0,r.Z)(n.errors||[])),t.push.apply(t,(0,r.Z)(n.warnings||[]))}),[e,t]},[$,Q.errors,Q.warnings]),er=function(){let{itemRef:e}=o.useContext(m.q3),t=o.useRef({});return function(n,r){let o=r&&"object"==typeof r&&r.ref,a=n.join("_");return(t.current.name!==a||t.current.originRef!==o)&&(t.current.name=a,t.current.originRef=o,t.current.ref=(0,s.sQ)(e(n),o)),t.current.ref}}();function eo(t,r,c){return n&&!R?o.createElement(D,{prefixCls:_,hasFeedback:e.hasFeedback,validateStatus:e.validateStatus,meta:Q,errors:et,warnings:en,noStyle:!0},t):o.createElement(V,Object.assign({key:"row"},e,{className:i()(a,X,H,W),prefixCls:_,fieldId:r,isRequired:c,errors:et,warnings:en,meta:Q,onSubItemMetaChange:ee}),t)}if(!L&&!T&&!h)return B(eo(P));let ea={};return"string"==typeof Z?ea.label=Z:t&&(ea.label=String(t)),O&&(ea=Object.assign(Object.assign({},ea),O)),B(o.createElement(c.gN,Object.assign({},e,{messageVariables:ea,trigger:k,validateTrigger:z,onMetaChange:e=>{let t=null==U?void 0:U.getKey(e.name);if(J(e.destroy?G():e,!0),n&&!1!==j&&F){let n=e.name;if(e.destroy)n=K.current||n;else if(void 0!==t){let[e,o]=t;n=[e].concat((0,r.Z)(o)),K.current=n}F(e,n)}}}),(n,a,i)=>{let c=(0,y.qo)(t).length&&a?a.name:[],l=(0,y.dD)(c,N),d=void 0!==C?C:!!(E&&E.some(e=>{if(e&&"object"==typeof e&&e.required&&!e.warningOnly)return!0;if("function"==typeof e){let t=e(i);return t&&t.required&&!t.warningOnly}return!1})),f=Object.assign({},n),p=null;if(Array.isArray(P)&&L)p=P;else if(T&&(!(w||h)||L));else if(!h||T||L){if((0,u.l$)(P)){let t=Object.assign(Object.assign({},P.props),f);if(t.id||(t.id=l),j||et.length>0||en.length>0||e.extra){let n=[];(j||et.length>0)&&n.push("".concat(l,"_help")),e.extra&&n.push("".concat(l,"_extra")),t["aria-describedby"]=n.join(" ")}et.length>0&&(t["aria-invalid"]="true"),d&&(t["aria-required"]="true"),(0,s.Yr)(P)&&(t.ref=er(c,P)),new Set([].concat((0,r.Z)((0,y.qo)(k)),(0,r.Z)((0,y.qo)(z)))).forEach(e=>{t[e]=function(){for(var t,n,r,o=arguments.length,a=Array(o),i=0;i{}}),c=r.createContext(null),l=e=>{let t=(0,a.Z)(e,["prefixCls"]);return r.createElement(o.RV,Object.assign({},t))},s=r.createContext({prefixCls:""}),u=r.createContext({}),d=e=>{let{children:t,status:n,override:o}=e,a=(0,r.useContext)(u),i=(0,r.useMemo)(()=>{let e=Object.assign({},a);return o&&delete e.isFormItemInput,n&&(delete e.status,delete e.hasFeedback,delete e.feedbackIcon),e},[n,o,a]);return r.createElement(u.Provider,{value:i},t)},f=(0,r.createContext)(void 0)},4064:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(2265);function o(e){let[t,n]=r.useState(e);return r.useEffect(()=>{let t=setTimeout(()=>{n(e)},e.length?0:10);return()=>{clearTimeout(t)}},[e]),t}},56250:function(e,t,n){"use strict";var r=n(2265),o=n(39109);let a=["outlined","borderless","filled"];t.Z=function(e){let t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,i=(0,r.useContext)(o.pg);t=void 0!==e?e:!1===n?"borderless":null!=i?i:"outlined";let c=a.includes(t);return[t,c]}},13634:function(e,t,n){"use strict";n.d(t,{Z:function(){return j}});var r=n(14605),o=n(2265),a=n(36760),i=n.n(a),c=n(64834),l=n(71744),s=n(86586),u=n(64024),d=n(33759),f=n(59189),p=n(39109);let m=e=>"object"==typeof e&&null!=e&&1===e.nodeType,g=(e,t)=>(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e,h=(e,t)=>{if(e.clientHeight{let t=(e=>{if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}})(e);return!!t&&(t.clientHeightat||a>e&&i=t&&c>=n?a-e-r:i>t&&cn?i-t+o:0,b=e=>{let t=e.parentElement;return null==t?e.getRootNode().host||null:t},y=(e,t)=>{var n,r,o,a;if("undefined"==typeof document)return[];let{scrollMode:i,block:c,inline:l,boundary:s,skipOverflowHiddenElements:u}=t,d="function"==typeof s?s:e=>e!==s;if(!m(e))throw TypeError("Invalid target");let f=document.scrollingElement||document.documentElement,p=[],g=e;for(;m(g)&&d(g);){if((g=b(g))===f){p.push(g);break}null!=g&&g===document.body&&h(g)&&!h(document.documentElement)||null!=g&&h(g,u)&&p.push(g)}let y=null!=(r=null==(n=window.visualViewport)?void 0:n.width)?r:innerWidth,x=null!=(a=null==(o=window.visualViewport)?void 0:o.height)?a:innerHeight,{scrollX:w,scrollY:E}=window,{height:S,width:C,top:Z,right:O,bottom:k,left:M}=e.getBoundingClientRect(),{top:R,right:j,bottom:I,left:N}=(e=>{let t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e),P="start"===c||"nearest"===c?Z-R:"end"===c?k+I:Z+S/2-R+I,T="center"===l?M+C/2-N+j:"end"===l?O+j:M-N,F=[];for(let e=0;e=0&&M>=0&&k<=x&&O<=y&&Z>=o&&k<=s&&M>=u&&O<=a)break;let d=getComputedStyle(t),m=parseInt(d.borderLeftWidth,10),g=parseInt(d.borderTopWidth,10),h=parseInt(d.borderRightWidth,10),b=parseInt(d.borderBottomWidth,10),R=0,j=0,I="offsetWidth"in t?t.offsetWidth-t.clientWidth-m-h:0,N="offsetHeight"in t?t.offsetHeight-t.clientHeight-g-b:0,A="offsetWidth"in t?0===t.offsetWidth?0:r/t.offsetWidth:0,z="offsetHeight"in t?0===t.offsetHeight?0:n/t.offsetHeight:0;if(f===t)R="start"===c?P:"end"===c?P-x:"nearest"===c?v(E,E+x,x,g,b,E+P,E+P+S,S):P-x/2,j="start"===l?T:"center"===l?T-y/2:"end"===l?T-y:v(w,w+y,y,m,h,w+T,w+T+C,C),R=Math.max(0,R+E),j=Math.max(0,j+w);else{R="start"===c?P-o-g:"end"===c?P-s+b+N:"nearest"===c?v(o,s,n,g,b+N,P,P+S,S):P-(o+n/2)+N/2,j="start"===l?T-u-m:"center"===l?T-(u+r/2)+I/2:"end"===l?T-a+h+I:v(u,a,r,m,h+I,T,T+C,C);let{scrollLeft:e,scrollTop:i}=t;R=0===z?0:Math.max(0,Math.min(i+R/z,t.scrollHeight-n/z+N)),j=0===A?0:Math.max(0,Math.min(e+j/A,t.scrollWidth-r/A+I)),P+=i-R,T+=e-j}F.push({el:t,top:R,left:j})}return F},x=e=>!1===e?{block:"end",inline:"nearest"}:e===Object(e)&&0!==Object.keys(e).length?e:{block:"start",inline:"nearest"};var w=n(13861);function E(e){return(0,w.qo)(e).join("_")}function S(e){let[t]=(0,c.cI)(),n=o.useRef({}),r=o.useMemo(()=>null!=e?e:Object.assign(Object.assign({},t),{__INTERNAL__:{itemRef:e=>t=>{let r=E(e);t?n.current[r]=t:delete n.current[r]}},scrollToField:function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(0,w.qo)(e),o=(0,w.dD)(n,r.__INTERNAL__.name),a=o?document.getElementById(o):null;a&&function(e,t){if(!e.isConnected||!(e=>{let t=e;for(;t&&t.parentNode;){if(t.parentNode===document)return!0;t=t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}return!1})(e))return;let n=(e=>{let t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);if("object"==typeof t&&"function"==typeof t.behavior)return t.behavior(y(e,t));let r="boolean"==typeof t||null==t?void 0:t.behavior;for(let{el:o,top:a,left:i}of y(e,x(t))){let e=a-n.top+n.bottom,t=i-n.left+n.right;o.scroll({top:e,left:t,behavior:r})}}(a,Object.assign({scrollMode:"if-needed",block:"nearest"},t))},getFieldInstance:e=>{let t=E(e);return n.current[t]}}),[e,t]);return[r]}var C=n(47713),Z=n(77360),O=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let k=o.forwardRef((e,t)=>{let n=o.useContext(s.Z),{getPrefixCls:r,direction:a,form:m}=o.useContext(l.E_),{prefixCls:g,className:h,rootClassName:v,size:b,disabled:y=n,form:x,colon:w,labelAlign:E,labelWrap:k,labelCol:M,wrapperCol:R,hideRequiredMark:j,layout:I="horizontal",scrollToFirstError:N,requiredMark:P,onFinishFailed:T,name:F,style:A,feedbackIcons:z,variant:L}=e,_=O(e,["prefixCls","className","rootClassName","size","disabled","form","colon","labelAlign","labelWrap","labelCol","wrapperCol","hideRequiredMark","layout","scrollToFirstError","requiredMark","onFinishFailed","name","style","feedbackIcons","variant"]),H=(0,d.Z)(b),B=o.useContext(Z.Z),D=(0,o.useMemo)(()=>void 0!==P?P:!j&&(!m||void 0===m.requiredMark||m.requiredMark),[j,P,m]),W=null!=w?w:null==m?void 0:m.colon,V=r("form",g),q=(0,u.Z)(V),[G,X,U]=(0,C.ZP)(V,q),K=i()(V,"".concat(V,"-").concat(I),{["".concat(V,"-hide-required-mark")]:!1===D,["".concat(V,"-rtl")]:"rtl"===a,["".concat(V,"-").concat(H)]:H},U,q,X,null==m?void 0:m.className,h,v),[$]=S(x),{__INTERNAL__:Y}=$;Y.name=F;let Q=(0,o.useMemo)(()=>({name:F,labelAlign:E,labelCol:M,labelWrap:k,wrapperCol:R,vertical:"vertical"===I,colon:W,requiredMark:D,itemRef:Y.itemRef,form:$,feedbackIcons:z}),[F,E,M,R,I,W,D,$,z]);o.useImperativeHandle(t,()=>$);let J=(e,t)=>{if(e){let n={block:"nearest"};"object"==typeof e&&(n=e),$.scrollToField(t,n)}};return G(o.createElement(p.pg.Provider,{value:L},o.createElement(s.n,{disabled:y},o.createElement(f.Z.Provider,{value:H},o.createElement(p.RV,{validateMessages:B},o.createElement(p.q3.Provider,{value:Q},o.createElement(c.ZP,Object.assign({id:F},_,{name:F,onFinishFailed:e=>{if(null==T||T(e),e.errorFields.length){let t=e.errorFields[0].name;if(void 0!==N){J(N,t);return}m&&void 0!==m.scrollToFirstError&&J(m.scrollToFirstError,t)}},form:$,style:Object.assign(Object.assign({},null==m?void 0:m.style),A),className:K}))))))))});var M=n(38994),R=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};k.Item=M.Z,k.List=e=>{var{prefixCls:t,children:n}=e,r=R(e,["prefixCls","children"]);let{getPrefixCls:a}=o.useContext(l.E_),i=a("form",t),s=o.useMemo(()=>({prefixCls:i,status:"error"}),[i]);return o.createElement(c.aV,Object.assign({},r),(e,t,r)=>o.createElement(p.Rk.Provider,{value:s},n(e.map(e=>Object.assign(Object.assign({},e),{fieldKey:e.key})),t,{errors:r.errors,warnings:r.warnings})))},k.ErrorList=r.Z,k.useForm=S,k.useFormInstance=function(){let{form:e}=(0,o.useContext)(p.q3);return e},k.useWatch=c.qo,k.Provider=p.RV,k.create=()=>{};var j=k},47713:function(e,t,n){"use strict";n.d(t,{ZP:function(){return x},B4:function(){return y}});var r=n(352),o=n(12918),a=n(691),i=n(63074),c=n(3104),l=n(80669),s=e=>{let{componentCls:t}=e,n="".concat(t,"-show-help"),r="".concat(t,"-show-help-item");return{[n]:{transition:"opacity ".concat(e.motionDurationSlow," ").concat(e.motionEaseInOut),"&-appear, &-enter":{opacity:0,"&-active":{opacity:1}},"&-leave":{opacity:1,"&-active":{opacity:0}},[r]:{overflow:"hidden",transition:"height ".concat(e.motionDurationSlow," ").concat(e.motionEaseInOut,",\n                     opacity ").concat(e.motionDurationSlow," ").concat(e.motionEaseInOut,",\n                     transform ").concat(e.motionDurationSlow," ").concat(e.motionEaseInOut," !important"),["&".concat(r,"-appear, &").concat(r,"-enter")]:{transform:"translateY(-5px)",opacity:0,"&-active":{transform:"translateY(0)",opacity:1}},["&".concat(r,"-leave-active")]:{transform:"translateY(-5px)"}}}}};let u=e=>({legend:{display:"block",width:"100%",marginBottom:e.marginLG,padding:0,color:e.colorTextDescription,fontSize:e.fontSizeLG,lineHeight:"inherit",border:0,borderBottom:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder)},'input[type="search"]':{boxSizing:"border-box"},'input[type="radio"], input[type="checkbox"]':{lineHeight:"normal"},'input[type="file"]':{display:"block"},'input[type="range"]':{display:"block",width:"100%"},"select[multiple], select[size]":{height:"auto"},"input[type='file']:focus,\n  input[type='radio']:focus,\n  input[type='checkbox']:focus":{outline:0,boxShadow:"0 0 0 ".concat((0,r.bf)(e.controlOutlineWidth)," ").concat(e.controlOutline)},output:{display:"block",paddingTop:15,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight}}),d=(e,t)=>{let{formItemCls:n}=e;return{[n]:{["".concat(n,"-label > label")]:{height:t},["".concat(n,"-control-input")]:{minHeight:t}}}},f=e=>{let{componentCls:t}=e;return{[e.componentCls]:Object.assign(Object.assign(Object.assign({},(0,o.Wf)(e)),u(e)),{["".concat(t,"-text")]:{display:"inline-block",paddingInlineEnd:e.paddingSM},"&-small":Object.assign({},d(e,e.controlHeightSM)),"&-large":Object.assign({},d(e,e.controlHeightLG))})}},p=e=>{let{formItemCls:t,iconCls:n,componentCls:r,rootPrefixCls:i,labelRequiredMarkColor:c,labelColor:l,labelFontSize:s,labelHeight:u,labelColonMarginInlineStart:d,labelColonMarginInlineEnd:f,itemMarginBottom:p}=e;return{[t]:Object.assign(Object.assign({},(0,o.Wf)(e)),{marginBottom:p,verticalAlign:"top","&-with-help":{transition:"none"},["&-hidden,\n        &-hidden.".concat(i,"-row")]:{display:"none"},"&-has-warning":{["".concat(t,"-split")]:{color:e.colorError}},"&-has-error":{["".concat(t,"-split")]:{color:e.colorWarning}},["".concat(t,"-label")]:{flexGrow:0,overflow:"hidden",whiteSpace:"nowrap",textAlign:"end",verticalAlign:"middle","&-left":{textAlign:"start"},"&-wrap":{overflow:"unset",lineHeight:e.lineHeight,whiteSpace:"unset"},"> label":{position:"relative",display:"inline-flex",alignItems:"center",maxWidth:"100%",height:u,color:l,fontSize:s,["> ".concat(n)]:{fontSize:e.fontSize,verticalAlign:"top"},["&".concat(t,"-required:not(").concat(t,"-required-mark-optional)::before")]:{display:"inline-block",marginInlineEnd:e.marginXXS,color:c,fontSize:e.fontSize,fontFamily:"SimSun, sans-serif",lineHeight:1,content:'"*"',["".concat(r,"-hide-required-mark &")]:{display:"none"}},["".concat(t,"-optional")]:{display:"inline-block",marginInlineStart:e.marginXXS,color:e.colorTextDescription,["".concat(r,"-hide-required-mark &")]:{display:"none"}},["".concat(t,"-tooltip")]:{color:e.colorTextDescription,cursor:"help",writingMode:"horizontal-tb",marginInlineStart:e.marginXXS},"&::after":{content:'":"',position:"relative",marginBlock:0,marginInlineStart:d,marginInlineEnd:f},["&".concat(t,"-no-colon::after")]:{content:'"\\a0"'}}},["".concat(t,"-control")]:{"--ant-display":"flex",flexDirection:"column",flexGrow:1,["&:first-child:not([class^=\"'".concat(i,"-col-'\"]):not([class*=\"' ").concat(i,"-col-'\"])")]:{width:"100%"},"&-input":{position:"relative",display:"flex",alignItems:"center",minHeight:e.controlHeight,"&-content":{flex:"auto",maxWidth:"100%"}}},[t]:{"&-explain, &-extra":{clear:"both",color:e.colorTextDescription,fontSize:e.fontSize,lineHeight:e.lineHeight},"&-explain-connected":{width:"100%"},"&-extra":{minHeight:e.controlHeightSM,transition:"color ".concat(e.motionDurationMid," ").concat(e.motionEaseOut)},"&-explain":{"&-error":{color:e.colorError},"&-warning":{color:e.colorWarning}}},["&-with-help ".concat(t,"-explain")]:{height:"auto",opacity:1},["".concat(t,"-feedback-icon")]:{fontSize:e.fontSize,textAlign:"center",visibility:"visible",animationName:a.kr,animationDuration:e.motionDurationMid,animationTimingFunction:e.motionEaseOutBack,pointerEvents:"none","&-success":{color:e.colorSuccess},"&-error":{color:e.colorError},"&-warning":{color:e.colorWarning},"&-validating":{color:e.colorPrimary}}})}},m=e=>{let{componentCls:t,formItemCls:n}=e;return{["".concat(t,"-horizontal")]:{["".concat(n,"-label")]:{flexGrow:0},["".concat(n,"-control")]:{flex:"1 1 0",minWidth:0},["".concat(n,"-label[class$='-24'], ").concat(n,"-label[class*='-24 ']")]:{["& + ".concat(n,"-control")]:{minWidth:"unset"}}}}},g=e=>{let{componentCls:t,formItemCls:n}=e;return{["".concat(t,"-inline")]:{display:"flex",flexWrap:"wrap",[n]:{flex:"none",marginInlineEnd:e.margin,marginBottom:0,"&-row":{flexWrap:"nowrap"},["> ".concat(n,"-label,\n        > ").concat(n,"-control")]:{display:"inline-block",verticalAlign:"top"},["> ".concat(n,"-label")]:{flex:"none"},["".concat(t,"-text")]:{display:"inline-block"},["".concat(n,"-has-feedback")]:{display:"inline-block"}}}}},h=e=>({padding:e.verticalLabelPadding,margin:e.verticalLabelMargin,whiteSpace:"initial",textAlign:"start","> label":{margin:0,"&::after":{visibility:"hidden"}}}),v=e=>{let{componentCls:t,formItemCls:n,rootPrefixCls:r}=e;return{["".concat(n," ").concat(n,"-label")]:h(e),["".concat(t,":not(").concat(t,"-inline)")]:{[n]:{flexWrap:"wrap",["".concat(n,"-label, ").concat(n,"-control")]:{['&:not([class*=" '.concat(r,'-col-xs"])')]:{flex:"0 0 100%",maxWidth:"100%"}}}}}},b=e=>{let{componentCls:t,formItemCls:n,rootPrefixCls:o}=e;return{["".concat(t,"-vertical")]:{[n]:{"&-row":{flexDirection:"column"},"&-label > label":{height:"auto"},["".concat(t,"-item-control")]:{width:"100%"}}},["".concat(t,"-vertical ").concat(n,"-label,\n      .").concat(o,"-col-24").concat(n,"-label,\n      .").concat(o,"-col-xl-24").concat(n,"-label")]:h(e),["@media (max-width: ".concat((0,r.bf)(e.screenXSMax),")")]:[v(e),{[t]:{[".".concat(o,"-col-xs-24").concat(n,"-label")]:h(e)}}],["@media (max-width: ".concat((0,r.bf)(e.screenSMMax),")")]:{[t]:{[".".concat(o,"-col-sm-24").concat(n,"-label")]:h(e)}},["@media (max-width: ".concat((0,r.bf)(e.screenMDMax),")")]:{[t]:{[".".concat(o,"-col-md-24").concat(n,"-label")]:h(e)}},["@media (max-width: ".concat((0,r.bf)(e.screenLGMax),")")]:{[t]:{[".".concat(o,"-col-lg-24").concat(n,"-label")]:h(e)}}}},y=(e,t)=>(0,c.TS)(e,{formItemCls:"".concat(e.componentCls,"-item"),rootPrefixCls:t});var x=(0,l.I$)("Form",(e,t)=>{let{rootPrefixCls:n}=t,r=y(e,n);return[f(r),p(r),s(r),m(r),g(r),b(r),(0,i.Z)(r),a.kr]},e=>({labelRequiredMarkColor:e.colorError,labelColor:e.colorTextHeading,labelFontSize:e.fontSize,labelHeight:e.controlHeight,labelColonMarginInlineStart:e.marginXXS/2,labelColonMarginInlineEnd:e.marginXS,itemMarginBottom:e.marginLG,verticalLabelPadding:"0 0 ".concat(e.paddingXS,"px"),verticalLabelMargin:0}),{order:-1e3})},13861:function(e,t,n){"use strict";n.d(t,{dD:function(){return a},lR:function(){return i},qo:function(){return o}});let r=["parentNode"];function o(e){return void 0===e||!1===e?[]:Array.isArray(e)?e:[e]}function a(e,t){if(!e.length)return;let n=e.join("_");return t?"".concat(t,"_").concat(n):r.includes(n)?"".concat("form_item","_").concat(n):n}function i(e,t,n,r,o,a){let i=r;return void 0!==a?i=a:n.validating?i="validating":e.length?i="error":t.length?i="warning":(n.touched||o&&n.validated)&&(i="success"),i}},77360:function(e,t,n){"use strict";var r=n(2265);t.Z=(0,r.createContext)(void 0)},62807:function(e,t,n){"use strict";let r=(0,n(2265).createContext)({});t.Z=r},54998:function(e,t,n){"use strict";var r=n(2265),o=n(36760),a=n.n(o),i=n(71744),c=n(62807),l=n(96776),s=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let u=["xs","sm","md","lg","xl","xxl"],d=r.forwardRef((e,t)=>{let{getPrefixCls:n,direction:o}=r.useContext(i.E_),{gutter:d,wrap:f}=r.useContext(c.Z),{prefixCls:p,span:m,order:g,offset:h,push:v,pull:b,className:y,children:x,flex:w,style:E}=e,S=s(e,["prefixCls","span","order","offset","push","pull","className","children","flex","style"]),C=n("col",p),[Z,O,k]=(0,l.cG)(C),M={};u.forEach(t=>{let n={},r=e[t];"number"==typeof r?n.span=r:"object"==typeof r&&(n=r||{}),delete S[t],M=Object.assign(Object.assign({},M),{["".concat(C,"-").concat(t,"-").concat(n.span)]:void 0!==n.span,["".concat(C,"-").concat(t,"-order-").concat(n.order)]:n.order||0===n.order,["".concat(C,"-").concat(t,"-offset-").concat(n.offset)]:n.offset||0===n.offset,["".concat(C,"-").concat(t,"-push-").concat(n.push)]:n.push||0===n.push,["".concat(C,"-").concat(t,"-pull-").concat(n.pull)]:n.pull||0===n.pull,["".concat(C,"-").concat(t,"-flex-").concat(n.flex)]:n.flex||"auto"===n.flex,["".concat(C,"-rtl")]:"rtl"===o})});let R=a()(C,{["".concat(C,"-").concat(m)]:void 0!==m,["".concat(C,"-order-").concat(g)]:g,["".concat(C,"-offset-").concat(h)]:h,["".concat(C,"-push-").concat(v)]:v,["".concat(C,"-pull-").concat(b)]:b},y,M,O,k),j={};if(d&&d[0]>0){let e=d[0]/2;j.paddingLeft=e,j.paddingRight=e}return w&&(j.flex="number"==typeof w?"".concat(w," ").concat(w," auto"):/^\d+(\.\d+)?(px|em|rem|%)$/.test(w)?"0 0 ".concat(w):w,!1!==f||j.minWidth||(j.minWidth=0)),Z(r.createElement("div",Object.assign({},S,{style:Object.assign(Object.assign({},j),E),className:R,ref:t}),x))});t.Z=d},10295:function(e,t,n){"use strict";var r=n(2265),o=n(36760),a=n.n(o),i=n(6543),c=n(71744),l=n(62807),s=n(96776),u=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function d(e,t){let[n,o]=r.useState("string"==typeof e?e:""),a=()=>{if("string"==typeof e&&o(e),"object"==typeof e)for(let n=0;n{a()},[JSON.stringify(e),t]),n}let f=r.forwardRef((e,t)=>{let{prefixCls:n,justify:o,align:f,className:p,style:m,children:g,gutter:h=0,wrap:v}=e,b=u(e,["prefixCls","justify","align","className","style","children","gutter","wrap"]),{getPrefixCls:y,direction:x}=r.useContext(c.E_),[w,E]=r.useState({xs:!0,sm:!0,md:!0,lg:!0,xl:!0,xxl:!0}),[S,C]=r.useState({xs:!1,sm:!1,md:!1,lg:!1,xl:!1,xxl:!1}),Z=d(f,S),O=d(o,S),k=r.useRef(h),M=(0,i.ZP)();r.useEffect(()=>{let e=M.subscribe(e=>{C(e);let t=k.current||0;(!Array.isArray(t)&&"object"==typeof t||Array.isArray(t)&&("object"==typeof t[0]||"object"==typeof t[1]))&&E(e)});return()=>M.unsubscribe(e)},[]);let R=y("row",n),[j,I,N]=(0,s.VM)(R),P=(()=>{let e=[void 0,void 0];return(Array.isArray(h)?h:[h,void 0]).forEach((t,n)=>{if("object"==typeof t)for(let r=0;r0?-(P[0]/2):void 0;A&&(F.marginLeft=A,F.marginRight=A),[,F.rowGap]=P;let[z,L]=P,_=r.useMemo(()=>({gutter:[z,L],wrap:v}),[z,L,v]);return j(r.createElement(l.Z.Provider,{value:_},r.createElement("div",Object.assign({},b,{className:T,style:Object.assign(Object.assign({},F),m),ref:t}),g)))});t.Z=f},96776:function(e,t,n){"use strict";n.d(t,{VM:function(){return u},cG:function(){return d}});var r=n(352),o=n(80669),a=n(3104);let i=e=>{let{componentCls:t}=e;return{[t]:{position:"relative",maxWidth:"100%",minHeight:1}}},c=(e,t)=>{let{componentCls:n,gridColumns:r}=e,o={};for(let e=r;e>=0;e--)0===e?(o["".concat(n).concat(t,"-").concat(e)]={display:"none"},o["".concat(n,"-push-").concat(e)]={insetInlineStart:"auto"},o["".concat(n,"-pull-").concat(e)]={insetInlineEnd:"auto"},o["".concat(n).concat(t,"-push-").concat(e)]={insetInlineStart:"auto"},o["".concat(n).concat(t,"-pull-").concat(e)]={insetInlineEnd:"auto"},o["".concat(n).concat(t,"-offset-").concat(e)]={marginInlineStart:0},o["".concat(n).concat(t,"-order-").concat(e)]={order:0}):(o["".concat(n).concat(t,"-").concat(e)]=[{"--ant-display":"block",display:"block"},{display:"var(--ant-display)",flex:"0 0 ".concat(e/r*100,"%"),maxWidth:"".concat(e/r*100,"%")}],o["".concat(n).concat(t,"-push-").concat(e)]={insetInlineStart:"".concat(e/r*100,"%")},o["".concat(n).concat(t,"-pull-").concat(e)]={insetInlineEnd:"".concat(e/r*100,"%")},o["".concat(n).concat(t,"-offset-").concat(e)]={marginInlineStart:"".concat(e/r*100,"%")},o["".concat(n).concat(t,"-order-").concat(e)]={order:e});return o},l=(e,t)=>c(e,t),s=(e,t,n)=>({["@media (min-width: ".concat((0,r.bf)(t),")")]:Object.assign({},l(e,n))}),u=(0,o.I$)("Grid",e=>{let{componentCls:t}=e;return{[t]:{display:"flex",flexFlow:"row wrap",minWidth:0,"&::before, &::after":{display:"flex"},"&-no-wrap":{flexWrap:"nowrap"},"&-start":{justifyContent:"flex-start"},"&-center":{justifyContent:"center"},"&-end":{justifyContent:"flex-end"},"&-space-between":{justifyContent:"space-between"},"&-space-around":{justifyContent:"space-around"},"&-space-evenly":{justifyContent:"space-evenly"},"&-top":{alignItems:"flex-start"},"&-middle":{alignItems:"center"},"&-bottom":{alignItems:"flex-end"}}}},()=>({})),d=(0,o.I$)("Grid",e=>{let t=(0,a.TS)(e,{gridColumns:24}),n={"-sm":t.screenSMMin,"-md":t.screenMDMin,"-lg":t.screenLGMin,"-xl":t.screenXLMin,"-xxl":t.screenXXLMin};return[i(t),l(t,""),l(t,"-xs"),Object.keys(n).map(e=>s(t,n[e],e)).reduce((e,t)=>Object.assign(Object.assign({},e),t),{})]},()=>({}))},20577:function(e,t,n){"use strict";n.d(t,{Z:function(){return eg}});var r=n(2265),o=n(70464),a=n(1119),i={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M890.5 755.3L537.9 269.2c-12.8-17.6-39-17.6-51.7 0L133.5 755.3A8 8 0 00140 768h75c5.1 0 9.9-2.5 12.9-6.6L512 369.8l284.1 391.6c3 4.1 7.8 6.6 12.9 6.6h75c6.5 0 10.3-7.4 6.5-12.7z"}}]},name:"up",theme:"outlined"},c=n(55015),l=r.forwardRef(function(e,t){return r.createElement(c.Z,(0,a.Z)({},e,{ref:t,icon:i}))}),s=n(36760),u=n.n(s),d=n(11993),f=n(41154),p=n(26365),m=n(6989),g=n(76405),h=n(25049);function v(){return"function"==typeof BigInt}function b(e){return!e&&0!==e&&!Number.isNaN(e)||!String(e).trim()}function y(e){var t=e.trim(),n=t.startsWith("-");n&&(t=t.slice(1)),(t=t.replace(/(\.\d*[^0])0*$/,"$1").replace(/\.0*$/,"").replace(/^0+/,"")).startsWith(".")&&(t="0".concat(t));var r=t||"0",o=r.split("."),a=o[0]||"0",i=o[1]||"0";"0"===a&&"0"===i&&(n=!1);var c=n?"-":"";return{negative:n,negativeStr:c,trimStr:r,integerStr:a,decimalStr:i,fullStr:"".concat(c).concat(r)}}function x(e){var t=String(e);return!Number.isNaN(Number(t))&&t.includes("e")}function w(e){var t=String(e);if(x(e)){var n=Number(t.slice(t.indexOf("e-")+2)),r=t.match(/\.(\d+)/);return null!=r&&r[1]&&(n+=r[1].length),n}return t.includes(".")&&S(t)?t.length-t.indexOf(".")-1:0}function E(e){var t=String(e);if(x(e)){if(e>Number.MAX_SAFE_INTEGER)return String(v()?BigInt(e).toString():Number.MAX_SAFE_INTEGER);if(e=this.add(e.negate().toString()).toNumber()}},{key:"toNumber",value:function(){return this.isNaN()?NaN:Number(this.toString())}},{key:"toString",value:function(){var e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];return e?this.isInvalidate()?"":y("".concat(this.getMark()).concat(this.getIntegerStr(),".").concat(this.getDecimalStr())).fullStr:this.origin}}]),e}(),Z=function(){function e(t){if((0,g.Z)(this,e),(0,d.Z)(this,"origin",""),(0,d.Z)(this,"number",void 0),(0,d.Z)(this,"empty",void 0),b(t)){this.empty=!0;return}this.origin=String(t),this.number=Number(t)}return(0,h.Z)(e,[{key:"negate",value:function(){return new e(-this.toNumber())}},{key:"add",value:function(t){if(this.isInvalidate())return new e(t);var n=Number(t);if(Number.isNaN(n))return this;var r=this.number+n;if(r>Number.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(rNumber.MAX_SAFE_INTEGER)return new e(Number.MAX_SAFE_INTEGER);if(r=this.add(e.negate().toString()).toNumber()}},{key:"toNumber",value:function(){return this.number}},{key:"toString",value:function(){var e=!(arguments.length>0)||void 0===arguments[0]||arguments[0];return e?this.isInvalidate()?"":E(this.number):this.origin}}]),e}();function O(e){return v()?new C(e):new Z(e)}function k(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(""===e)return"";var o=y(e),a=o.negativeStr,i=o.integerStr,c=o.decimalStr,l="".concat(t).concat(c),s="".concat(a).concat(i);if(n>=0){var u=Number(c[n]);return u>=5&&!r?k(O(e).add("".concat(a,"0.").concat("0".repeat(n)).concat(10-u)).toString(),t,n,r):0===n?s:"".concat(s).concat(t).concat(c.padEnd(n,"0").slice(0,n))}return".0"===l?s:"".concat(s).concat(l)}var M=n(2027),R=n(27380),j=n(28791),I=n(32559),N=n(79267),P=function(){var e=(0,r.useState)(!1),t=(0,p.Z)(e,2),n=t[0],o=t[1];return(0,R.Z)(function(){o((0,N.Z)())},[]),n},T=n(53346);function F(e){var t=e.prefixCls,n=e.upNode,o=e.downNode,i=e.upDisabled,c=e.downDisabled,l=e.onStep,s=r.useRef(),f=r.useRef([]),p=r.useRef();p.current=l;var m=function(){clearTimeout(s.current)},g=function(e,t){e.preventDefault(),m(),p.current(t),s.current=setTimeout(function e(){p.current(t),s.current=setTimeout(e,200)},600)};if(r.useEffect(function(){return function(){m(),f.current.forEach(function(e){return T.Z.cancel(e)})}},[]),P())return null;var h="".concat(t,"-handler"),v=u()(h,"".concat(h,"-up"),(0,d.Z)({},"".concat(h,"-up-disabled"),i)),b=u()(h,"".concat(h,"-down"),(0,d.Z)({},"".concat(h,"-down-disabled"),c)),y=function(){return f.current.push((0,T.Z)(m))},x={unselectable:"on",role:"button",onMouseUp:y,onMouseLeave:y};return r.createElement("div",{className:"".concat(h,"-wrap")},r.createElement("span",(0,a.Z)({},x,{onMouseDown:function(e){g(e,!0)},"aria-label":"Increase Value","aria-disabled":i,className:v}),n||r.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-up-inner")})),r.createElement("span",(0,a.Z)({},x,{onMouseDown:function(e){g(e,!1)},"aria-label":"Decrease Value","aria-disabled":c,className:b}),o||r.createElement("span",{unselectable:"on",className:"".concat(t,"-handler-down-inner")})))}function A(e){var t="number"==typeof e?E(e):y(e).fullStr;return t.includes(".")?y(t.replace(/(\d)\.(\d)/g,"$1$2.")).fullStr:e+"0"}var z=n(55041),L=function(){var e=(0,r.useRef)(0),t=function(){T.Z.cancel(e.current)};return(0,r.useEffect)(function(){return t},[]),function(n){t(),e.current=(0,T.Z)(function(){n()})}},_=["prefixCls","className","style","min","max","step","defaultValue","value","disabled","readOnly","upHandler","downHandler","keyboard","wheel","controls","classNames","stringMode","parser","formatter","precision","decimalSeparator","onChange","onInput","onPressEnter","onStep","changeOnBlur"],H=["disabled","style","prefixCls","value","prefix","suffix","addonBefore","addonAfter","className","classNames"],B=function(e,t){return e||t.isEmpty()?t.toString():t.toNumber()},D=function(e){var t=O(e);return t.isInvalidate()?null:t},W=r.forwardRef(function(e,t){var n,o,i,c=e.prefixCls,l=void 0===c?"rc-input-number":c,s=e.className,g=e.style,h=e.min,v=e.max,b=e.step,y=void 0===b?1:b,x=e.defaultValue,C=e.value,Z=e.disabled,M=e.readOnly,N=e.upHandler,P=e.downHandler,T=e.keyboard,z=e.wheel,H=e.controls,W=(e.classNames,e.stringMode),V=e.parser,q=e.formatter,G=e.precision,X=e.decimalSeparator,U=e.onChange,K=e.onInput,$=e.onPressEnter,Y=e.onStep,Q=e.changeOnBlur,J=void 0===Q||Q,ee=(0,m.Z)(e,_),et="".concat(l,"-input"),en=r.useRef(null),er=r.useState(!1),eo=(0,p.Z)(er,2),ea=eo[0],ei=eo[1],ec=r.useRef(!1),el=r.useRef(!1),es=r.useRef(!1),eu=r.useState(function(){return O(null!=C?C:x)}),ed=(0,p.Z)(eu,2),ef=ed[0],ep=ed[1],em=r.useCallback(function(e,t){return t?void 0:G>=0?G:Math.max(w(e),w(y))},[G,y]),eg=r.useCallback(function(e){var t=String(e);if(V)return V(t);var n=t;return X&&(n=n.replace(X,".")),n.replace(/[^\w.-]+/g,"")},[V,X]),eh=r.useRef(""),ev=r.useCallback(function(e,t){if(q)return q(e,{userTyping:t,input:String(eh.current)});var n="number"==typeof e?E(e):e;if(!t){var r=em(n,t);S(n)&&(X||r>=0)&&(n=k(n,X||".",r))}return n},[q,em,X]),eb=r.useState(function(){var e=null!=x?x:C;return ef.isInvalidate()&&["string","number"].includes((0,f.Z)(e))?Number.isNaN(e)?"":e:ev(ef.toString(),!1)}),ey=(0,p.Z)(eb,2),ex=ey[0],ew=ey[1];function eE(e,t){ew(ev(e.isInvalidate()?e.toString(!1):e.toString(!t),t))}eh.current=ex;var eS=r.useMemo(function(){return D(v)},[v,G]),eC=r.useMemo(function(){return D(h)},[h,G]),eZ=r.useMemo(function(){return!(!eS||!ef||ef.isInvalidate())&&eS.lessEquals(ef)},[eS,ef]),eO=r.useMemo(function(){return!(!eC||!ef||ef.isInvalidate())&&ef.lessEquals(eC)},[eC,ef]),ek=(n=en.current,o=(0,r.useRef)(null),[function(){try{var e=n.selectionStart,t=n.selectionEnd,r=n.value,a=r.substring(0,e),i=r.substring(t);o.current={start:e,end:t,value:r,beforeTxt:a,afterTxt:i}}catch(e){}},function(){if(n&&o.current&&ea)try{var e=n.value,t=o.current,r=t.beforeTxt,a=t.afterTxt,i=t.start,c=e.length;if(e.endsWith(a))c=e.length-o.current.afterTxt.length;else if(e.startsWith(r))c=r.length;else{var l=r[i-1],s=e.indexOf(l,i-1);-1!==s&&(c=s+1)}n.setSelectionRange(c,c)}catch(e){(0,I.ZP)(!1,"Something warning of cursor restore. Please fire issue about this: ".concat(e.message))}}]),eM=(0,p.Z)(ek,2),eR=eM[0],ej=eM[1],eI=function(e){return eS&&!e.lessEquals(eS)?eS:eC&&!eC.lessEquals(e)?eC:null},eN=function(e){return!eI(e)},eP=function(e,t){var n=e,r=eN(n)||n.isEmpty();if(n.isEmpty()||t||(n=eI(n)||n,r=!0),!M&&!Z&&r){var o,a=n.toString(),i=em(a,t);return i>=0&&!eN(n=O(k(a,".",i)))&&(n=O(k(a,".",i,!0))),n.equals(ef)||(o=n,void 0===C&&ep(o),null==U||U(n.isEmpty()?null:B(W,n)),void 0===C&&eE(n,t)),n}return ef},eT=L(),eF=function e(t){if(eR(),eh.current=t,ew(t),!el.current){var n=O(eg(t));n.isNaN()||eP(n,!0)}null==K||K(t),eT(function(){var n=t;V||(n=t.replace(/。/g,".")),n!==t&&e(n)})},eA=function(e){if((!e||!eZ)&&(e||!eO)){ec.current=!1;var t,n=O(es.current?A(y):y);e||(n=n.negate());var r=eP((ef||O(0)).add(n.toString()),!1);null==Y||Y(B(W,r),{offset:es.current?A(y):y,type:e?"up":"down"}),null===(t=en.current)||void 0===t||t.focus()}},ez=function(e){var t=O(eg(ex)),n=t;n=t.isNaN()?eP(ef,e):eP(t,e),void 0!==C?eE(ef,!1):n.isNaN()||eE(n,!1)};return r.useEffect(function(){var e=function(e){!1!==z&&(eA(e.deltaY<0),e.preventDefault())},t=en.current;if(t)return t.addEventListener("wheel",e),function(){return t.removeEventListener("wheel",e)}},[eA]),(0,R.o)(function(){ef.isInvalidate()||eE(ef,!1)},[G,q]),(0,R.o)(function(){var e=O(C);ep(e);var t=O(eg(ex));e.equals(t)&&ec.current&&!q||eE(e,ec.current)},[C]),(0,R.o)(function(){q&&ej()},[ex]),r.createElement("div",{className:u()(l,s,(i={},(0,d.Z)(i,"".concat(l,"-focused"),ea),(0,d.Z)(i,"".concat(l,"-disabled"),Z),(0,d.Z)(i,"".concat(l,"-readonly"),M),(0,d.Z)(i,"".concat(l,"-not-a-number"),ef.isNaN()),(0,d.Z)(i,"".concat(l,"-out-of-range"),!ef.isInvalidate()&&!eN(ef)),i)),style:g,onFocus:function(){ei(!0)},onBlur:function(){J&&ez(!1),ei(!1),ec.current=!1},onKeyDown:function(e){var t=e.key,n=e.shiftKey;ec.current=!0,es.current=n,"Enter"===t&&(el.current||(ec.current=!1),ez(!1),null==$||$(e)),!1!==T&&!el.current&&["Up","ArrowUp","Down","ArrowDown"].includes(t)&&(eA("Up"===t||"ArrowUp"===t),e.preventDefault())},onKeyUp:function(){ec.current=!1,es.current=!1},onCompositionStart:function(){el.current=!0},onCompositionEnd:function(){el.current=!1,eF(en.current.value)},onBeforeInput:function(){ec.current=!0}},(void 0===H||H)&&r.createElement(F,{prefixCls:l,upNode:N,downNode:P,upDisabled:eZ,downDisabled:eO,onStep:eA}),r.createElement("div",{className:"".concat(et,"-wrap")},r.createElement("input",(0,a.Z)({autoComplete:"off",role:"spinbutton","aria-valuemin":h,"aria-valuemax":v,"aria-valuenow":ef.isInvalidate()?null:ef.toString(),step:y},ee,{ref:(0,j.sQ)(en,t),className:et,value:ex,onChange:function(e){eF(e.target.value)},disabled:Z,readOnly:M}))))}),V=r.forwardRef(function(e,t){var n=e.disabled,o=e.style,i=e.prefixCls,c=e.value,l=e.prefix,s=e.suffix,u=e.addonBefore,d=e.addonAfter,f=e.className,p=e.classNames,g=(0,m.Z)(e,H),h=r.useRef(null);return r.createElement(M.Q,{className:f,triggerFocus:function(e){h.current&&(0,z.nH)(h.current,e)},prefixCls:i,value:c,disabled:n,style:o,prefix:l,suffix:s,addonAfter:d,addonBefore:u,classNames:p,components:{affixWrapper:"div",groupWrapper:"div",wrapper:"div",groupAddon:"div"}},r.createElement(W,(0,a.Z)({prefixCls:i,disabled:n,ref:(0,j.sQ)(h,t),className:null==p?void 0:p.input},g)))});V.displayName="InputNumber";var q=n(12757),G=n(71744),X=n(13959),U=n(86586),K=n(64024),$=n(33759),Y=n(39109),Q=n(56250),J=n(65658),ee=n(352),et=n(31282),en=n(37433),er=n(65265),eo=n(12918),ea=n(17691),ei=n(80669),ec=n(3104),el=n(36360);let es=(e,t)=>{let{componentCls:n,borderRadiusSM:r,borderRadiusLG:o}=e,a="lg"===t?o:r;return{["&-".concat(t)]:{["".concat(n,"-handler-wrap")]:{borderStartEndRadius:a,borderEndEndRadius:a},["".concat(n,"-handler-up")]:{borderStartEndRadius:a},["".concat(n,"-handler-down")]:{borderEndEndRadius:a}}}},eu=e=>{let{componentCls:t,lineWidth:n,lineType:r,borderRadius:o,fontSizeLG:a,controlHeightLG:i,controlHeightSM:c,colorError:l,paddingInlineSM:s,paddingBlockSM:u,paddingBlockLG:d,paddingInlineLG:f,colorTextDescription:p,motionDurationMid:m,handleHoverColor:g,paddingInline:h,paddingBlock:v,handleBg:b,handleActiveBg:y,colorTextDisabled:x,borderRadiusSM:w,borderRadiusLG:E,controlWidth:S,handleOpacity:C,handleBorderColor:Z,filledHandleBg:O,lineHeightLG:k,calc:M}=e;return[{[t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},(0,eo.Wf)(e)),(0,et.ik)(e)),{display:"inline-block",width:S,margin:0,padding:0,borderRadius:o}),(0,er.qG)(e,{["".concat(t,"-handler-wrap")]:{background:b,["".concat(t,"-handler-down")]:{borderBlockStart:"".concat((0,ee.bf)(n)," ").concat(r," ").concat(Z)}}})),(0,er.H8)(e,{["".concat(t,"-handler-wrap")]:{background:O,["".concat(t,"-handler-down")]:{borderBlockStart:"".concat((0,ee.bf)(n)," ").concat(r," ").concat(Z)}},"&:focus-within":{["".concat(t,"-handler-wrap")]:{background:b}}})),(0,er.Mu)(e)),{"&-rtl":{direction:"rtl",["".concat(t,"-input")]:{direction:"rtl"}},"&-lg":{padding:0,fontSize:a,lineHeight:k,borderRadius:E,["input".concat(t,"-input")]:{height:M(i).sub(M(n).mul(2)).equal(),padding:"".concat((0,ee.bf)(d)," ").concat((0,ee.bf)(f))}},"&-sm":{padding:0,borderRadius:w,["input".concat(t,"-input")]:{height:M(c).sub(M(n).mul(2)).equal(),padding:"".concat((0,ee.bf)(u)," ").concat((0,ee.bf)(s))}},"&-out-of-range":{["".concat(t,"-input-wrap")]:{input:{color:l}}},"&-group":Object.assign(Object.assign(Object.assign({},(0,eo.Wf)(e)),(0,et.s7)(e)),{"&-wrapper":Object.assign(Object.assign(Object.assign({display:"inline-block",textAlign:"start",verticalAlign:"top",["".concat(t,"-affix-wrapper")]:{width:"100%"},"&-lg":{["".concat(t,"-group-addon")]:{borderRadius:E,fontSize:e.fontSizeLG}},"&-sm":{["".concat(t,"-group-addon")]:{borderRadius:w}}},(0,er.ir)(e)),(0,er.S5)(e)),{["&:not(".concat(t,"-compact-first-item):not(").concat(t,"-compact-last-item)").concat(t,"-compact-item")]:{["".concat(t,", ").concat(t,"-group-addon")]:{borderRadius:0}},["&:not(".concat(t,"-compact-last-item)").concat(t,"-compact-first-item")]:{["".concat(t,", ").concat(t,"-group-addon")]:{borderStartEndRadius:0,borderEndEndRadius:0}},["&:not(".concat(t,"-compact-first-item)").concat(t,"-compact-last-item")]:{["".concat(t,", ").concat(t,"-group-addon")]:{borderStartStartRadius:0,borderEndStartRadius:0}}})}),["&-disabled ".concat(t,"-input")]:{cursor:"not-allowed"},[t]:{"&-input":Object.assign(Object.assign(Object.assign(Object.assign({},(0,eo.Wf)(e)),{width:"100%",padding:"".concat((0,ee.bf)(v)," ").concat((0,ee.bf)(h)),textAlign:"start",backgroundColor:"transparent",border:0,borderRadius:o,outline:0,transition:"all ".concat(m," linear"),appearance:"textfield",fontSize:"inherit"}),(0,et.nz)(e.colorTextPlaceholder)),{'&[type="number"]::-webkit-inner-spin-button, &[type="number"]::-webkit-outer-spin-button':{margin:0,webkitAppearance:"none",appearance:"none"}})}})},{[t]:Object.assign(Object.assign(Object.assign({["&:hover ".concat(t,"-handler-wrap, &-focused ").concat(t,"-handler-wrap")]:{opacity:1},["".concat(t,"-handler-wrap")]:{position:"absolute",insetBlockStart:0,insetInlineEnd:0,width:e.handleWidth,height:"100%",borderStartStartRadius:0,borderStartEndRadius:o,borderEndEndRadius:o,borderEndStartRadius:0,opacity:C,display:"flex",flexDirection:"column",alignItems:"stretch",transition:"opacity ".concat(m," linear ").concat(m),["".concat(t,"-handler")]:{display:"flex",alignItems:"center",justifyContent:"center",flex:"auto",height:"40%",["\n              ".concat(t,"-handler-up-inner,\n              ").concat(t,"-handler-down-inner\n            ")]:{marginInlineEnd:0,fontSize:e.handleFontSize}}},["".concat(t,"-handler")]:{height:"50%",overflow:"hidden",color:p,fontWeight:"bold",lineHeight:0,textAlign:"center",cursor:"pointer",borderInlineStart:"".concat((0,ee.bf)(n)," ").concat(r," ").concat(Z),transition:"all ".concat(m," linear"),"&:active":{background:y},"&:hover":{height:"60%",["\n              ".concat(t,"-handler-up-inner,\n              ").concat(t,"-handler-down-inner\n            ")]:{color:g}},"&-up-inner, &-down-inner":Object.assign(Object.assign({},(0,eo.Ro)()),{color:p,transition:"all ".concat(m," linear"),userSelect:"none"})},["".concat(t,"-handler-up")]:{borderStartEndRadius:o},["".concat(t,"-handler-down")]:{borderEndEndRadius:o}},es(e,"lg")),es(e,"sm")),{"&-disabled, &-readonly":{["".concat(t,"-handler-wrap")]:{display:"none"},["".concat(t,"-input")]:{color:"inherit"}},["\n          ".concat(t,"-handler-up-disabled,\n          ").concat(t,"-handler-down-disabled\n        ")]:{cursor:"not-allowed"},["\n          ".concat(t,"-handler-up-disabled:hover &-handler-up-inner,\n          ").concat(t,"-handler-down-disabled:hover &-handler-down-inner\n        ")]:{color:x}})}]},ed=e=>{let{componentCls:t,paddingBlock:n,paddingInline:r,inputAffixPadding:o,controlWidth:a,borderRadiusLG:i,borderRadiusSM:c,paddingInlineLG:l,paddingInlineSM:s,paddingBlockLG:u,paddingBlockSM:d}=e;return{["".concat(t,"-affix-wrapper")]:Object.assign(Object.assign({["input".concat(t,"-input")]:{padding:"".concat((0,ee.bf)(n)," 0")}},(0,et.ik)(e)),{position:"relative",display:"inline-flex",width:a,padding:0,paddingInlineStart:r,"&-lg":{borderRadius:i,paddingInlineStart:l,["input".concat(t,"-input")]:{padding:"".concat((0,ee.bf)(u)," 0")}},"&-sm":{borderRadius:c,paddingInlineStart:s,["input".concat(t,"-input")]:{padding:"".concat((0,ee.bf)(d)," 0")}},["&:not(".concat(t,"-disabled):hover")]:{zIndex:1},"&-focused, &:focus":{zIndex:1},["&-disabled > ".concat(t,"-disabled")]:{background:"transparent"},["> div".concat(t)]:{width:"100%",border:"none",outline:"none",["&".concat(t,"-focused")]:{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},["".concat(t,"-handler-wrap")]:{zIndex:2},[t]:{color:"inherit","&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center",pointerEvents:"none"},"&-prefix":{marginInlineEnd:o},"&-suffix":{position:"absolute",insetBlockStart:0,insetInlineEnd:0,zIndex:1,height:"100%",marginInlineEnd:r,marginInlineStart:o}}})}};var ef=(0,ei.I$)("InputNumber",e=>{let t=(0,ec.TS)(e,(0,en.e)(e));return[eu(t),ed(t),(0,ea.c)(t)]},e=>{var t;let n=null!==(t=e.handleVisible)&&void 0!==t?t:"auto";return Object.assign(Object.assign({},(0,en.T)(e)),{controlWidth:90,handleWidth:e.controlHeightSM-2*e.lineWidth,handleFontSize:e.fontSize/2,handleVisible:n,handleActiveBg:e.colorFillAlter,handleBg:e.colorBgContainer,filledHandleBg:new el.C(e.colorFillSecondary).onBackground(e.colorBgContainer).toHexString(),handleHoverColor:e.colorPrimary,handleBorderColor:e.colorBorder,handleOpacity:!0===n?1:0})},{unitless:{handleOpacity:!0}}),ep=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let em=r.forwardRef((e,t)=>{let{getPrefixCls:n,direction:a}=r.useContext(G.E_),i=r.useRef(null);r.useImperativeHandle(t,()=>i.current);let{className:c,rootClassName:s,size:d,disabled:f,prefixCls:p,addonBefore:m,addonAfter:g,prefix:h,bordered:v,readOnly:b,status:y,controls:x,variant:w}=e,E=ep(e,["className","rootClassName","size","disabled","prefixCls","addonBefore","addonAfter","prefix","bordered","readOnly","status","controls","variant"]),S=n("input-number",p),C=(0,K.Z)(S),[Z,O,k]=ef(S,C),{compactSize:M,compactItemClassnames:R}=(0,J.ri)(S,a),j=r.createElement(l,{className:"".concat(S,"-handler-up-inner")}),I=r.createElement(o.Z,{className:"".concat(S,"-handler-down-inner")});"object"==typeof x&&(j=void 0===x.upIcon?j:r.createElement("span",{className:"".concat(S,"-handler-up-inner")},x.upIcon),I=void 0===x.downIcon?I:r.createElement("span",{className:"".concat(S,"-handler-down-inner")},x.downIcon));let{hasFeedback:N,status:P,isFormItemInput:T,feedbackIcon:F}=r.useContext(Y.aM),A=(0,q.F)(P,y),z=(0,$.Z)(e=>{var t;return null!==(t=null!=d?d:M)&&void 0!==t?t:e}),L=r.useContext(U.Z),[_,H]=(0,Q.Z)(w,v),B=N&&r.createElement(r.Fragment,null,F),D=u()({["".concat(S,"-lg")]:"large"===z,["".concat(S,"-sm")]:"small"===z,["".concat(S,"-rtl")]:"rtl"===a,["".concat(S,"-in-form-item")]:T},O),W="".concat(S,"-group");return Z(r.createElement(V,Object.assign({ref:i,disabled:null!=f?f:L,className:u()(k,C,c,s,R),upHandler:j,downHandler:I,prefixCls:S,readOnly:b,controls:"boolean"==typeof x?x:void 0,prefix:h,suffix:B,addonAfter:g&&r.createElement(J.BR,null,r.createElement(Y.Ux,{override:!0,status:!0},g)),addonBefore:m&&r.createElement(J.BR,null,r.createElement(Y.Ux,{override:!0,status:!0},m)),classNames:{input:D,variant:u()({["".concat(S,"-").concat(_)]:H},(0,q.Z)(S,A,N)),affixWrapper:u()({["".concat(S,"-affix-wrapper-sm")]:"small"===z,["".concat(S,"-affix-wrapper-lg")]:"large"===z,["".concat(S,"-affix-wrapper-rtl")]:"rtl"===a},O),wrapper:u()({["".concat(W,"-rtl")]:"rtl"===a},O),groupWrapper:u()({["".concat(S,"-group-wrapper-sm")]:"small"===z,["".concat(S,"-group-wrapper-lg")]:"large"===z,["".concat(S,"-group-wrapper-rtl")]:"rtl"===a,["".concat(S,"-group-wrapper-").concat(_)]:H},(0,q.Z)("".concat(S,"-group-wrapper"),A,N),O)}},E)))});em._InternalPanelDoNotUseOrYouWillBeFired=e=>r.createElement(X.ZP,{theme:{components:{InputNumber:{handleVisible:!0}}}},r.createElement(em,Object.assign({},e)));var eg=em},65863:function(e,t,n){"use strict";n.d(t,{Z:function(){return E},n:function(){return w}});var r=n(2265),o=n(36760),a=n.n(o),i=n(2027),c=n(28791),l=n(12757),s=n(71744),u=n(86586),d=n(33759),f=n(39109),p=n(65658),m=n(39164),g=n(31282),h=n(64024),v=n(56250),b=n(39725),y=e=>{let t;return"object"==typeof e&&(null==e?void 0:e.clearIcon)?t=e:e&&(t={clearIcon:r.createElement(b.Z,null)}),t},x=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function w(e,t){if(!e)return;e.focus(t);let{cursor:n}=t||{};if(n){let t=e.value.length;switch(n){case"start":e.setSelectionRange(0,0);break;case"end":e.setSelectionRange(t,t);break;default:e.setSelectionRange(0,t)}}}var E=(0,r.forwardRef)((e,t)=>{var n;let{prefixCls:o,bordered:b=!0,status:w,size:E,disabled:S,onBlur:C,onFocus:Z,suffix:O,allowClear:k,addonAfter:M,addonBefore:R,className:j,style:I,styles:N,rootClassName:P,onChange:T,classNames:F,variant:A}=e,z=x(e,["prefixCls","bordered","status","size","disabled","onBlur","onFocus","suffix","allowClear","addonAfter","addonBefore","className","style","styles","rootClassName","onChange","classNames","variant"]),{getPrefixCls:L,direction:_,input:H}=r.useContext(s.E_),B=L("input",o),D=(0,r.useRef)(null),W=(0,h.Z)(B),[V,q,G]=(0,g.ZP)(B,W),{compactSize:X,compactItemClassnames:U}=(0,p.ri)(B,_),K=(0,d.Z)(e=>{var t;return null!==(t=null!=E?E:X)&&void 0!==t?t:e}),$=r.useContext(u.Z),{status:Y,hasFeedback:Q,feedbackIcon:J}=(0,r.useContext)(f.aM),ee=(0,l.F)(Y,w),et=!!(e.prefix||e.suffix||e.allowClear||e.showCount)||!!Q;(0,r.useRef)(et);let en=(0,m.Z)(D,!0),er=(Q||O)&&r.createElement(r.Fragment,null,O,Q&&J),eo=y(k),[ea,ei]=(0,v.Z)(A,b);return V(r.createElement(i.Z,Object.assign({ref:(0,c.sQ)(t,D),prefixCls:B,autoComplete:null==H?void 0:H.autoComplete},z,{disabled:null!=S?S:$,onBlur:e=>{en(),null==C||C(e)},onFocus:e=>{en(),null==Z||Z(e)},style:Object.assign(Object.assign({},null==H?void 0:H.style),I),styles:Object.assign(Object.assign({},null==H?void 0:H.styles),N),suffix:er,allowClear:eo,className:a()(j,P,G,W,U,null==H?void 0:H.className),onChange:e=>{en(),null==T||T(e)},addonAfter:M&&r.createElement(p.BR,null,r.createElement(f.Ux,{override:!0,status:!0},M)),addonBefore:R&&r.createElement(p.BR,null,r.createElement(f.Ux,{override:!0,status:!0},R)),classNames:Object.assign(Object.assign(Object.assign({},F),null==H?void 0:H.classNames),{input:a()({["".concat(B,"-sm")]:"small"===K,["".concat(B,"-lg")]:"large"===K,["".concat(B,"-rtl")]:"rtl"===_},null==F?void 0:F.input,null===(n=null==H?void 0:H.classNames)||void 0===n?void 0:n.input,q),variant:a()({["".concat(B,"-").concat(ea)]:ei},(0,l.Z)(B,ee)),affixWrapper:a()({["".concat(B,"-affix-wrapper-sm")]:"small"===K,["".concat(B,"-affix-wrapper-lg")]:"large"===K,["".concat(B,"-affix-wrapper-rtl")]:"rtl"===_},q),wrapper:a()({["".concat(B,"-group-rtl")]:"rtl"===_},q),groupWrapper:a()({["".concat(B,"-group-wrapper-sm")]:"small"===K,["".concat(B,"-group-wrapper-lg")]:"large"===K,["".concat(B,"-group-wrapper-rtl")]:"rtl"===_,["".concat(B,"-group-wrapper-").concat(ea)]:ei},(0,l.Z)("".concat(B,"-group-wrapper"),ee,Q),q)})})))})},90464:function(e,t,n){"use strict";n.d(t,{Z:function(){return L}});var r,o=n(2265),a=n(39725),i=n(36760),c=n.n(i),l=n(1119),s=n(11993),u=n(31686),d=n(83145),f=n(26365),p=n(6989),m=n(2027),g=n(96032),h=n(55041),v=n(50506),b=n(41154),y=n(31474),x=n(27380),w=n(53346),E=["letter-spacing","line-height","padding-top","padding-bottom","font-family","font-weight","font-size","font-variant","text-rendering","text-transform","width","text-indent","padding-left","padding-right","border-width","box-sizing","word-break","white-space"],S={},C=["prefixCls","onPressEnter","defaultValue","value","autoSize","onResize","className","style","disabled","onChange","onInternalAutoSize"],Z=o.forwardRef(function(e,t){var n=e.prefixCls,a=(e.onPressEnter,e.defaultValue),i=e.value,d=e.autoSize,m=e.onResize,g=e.className,h=e.style,Z=e.disabled,O=e.onChange,k=(e.onInternalAutoSize,(0,p.Z)(e,C)),M=(0,v.Z)(a,{value:i,postState:function(e){return null!=e?e:""}}),R=(0,f.Z)(M,2),j=R[0],I=R[1],N=o.useRef();o.useImperativeHandle(t,function(){return{textArea:N.current}});var P=o.useMemo(function(){return d&&"object"===(0,b.Z)(d)?[d.minRows,d.maxRows]:[]},[d]),T=(0,f.Z)(P,2),F=T[0],A=T[1],z=!!d,L=function(){try{if(document.activeElement===N.current){var e=N.current,t=e.selectionStart,n=e.selectionEnd,r=e.scrollTop;N.current.setSelectionRange(t,n),N.current.scrollTop=r}}catch(e){}},_=o.useState(2),H=(0,f.Z)(_,2),B=H[0],D=H[1],W=o.useState(),V=(0,f.Z)(W,2),q=V[0],G=V[1],X=function(){D(0)};(0,x.Z)(function(){z&&X()},[i,F,A,z]),(0,x.Z)(function(){if(0===B)D(1);else if(1===B){var e=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;r||((r=document.createElement("textarea")).setAttribute("tab-index","-1"),r.setAttribute("aria-hidden","true"),document.body.appendChild(r)),e.getAttribute("wrap")?r.setAttribute("wrap",e.getAttribute("wrap")):r.removeAttribute("wrap");var i=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=e.getAttribute("id")||e.getAttribute("data-reactid")||e.getAttribute("name");if(t&&S[n])return S[n];var r=window.getComputedStyle(e),o=r.getPropertyValue("box-sizing")||r.getPropertyValue("-moz-box-sizing")||r.getPropertyValue("-webkit-box-sizing"),a=parseFloat(r.getPropertyValue("padding-bottom"))+parseFloat(r.getPropertyValue("padding-top")),i=parseFloat(r.getPropertyValue("border-bottom-width"))+parseFloat(r.getPropertyValue("border-top-width")),c={sizingStyle:E.map(function(e){return"".concat(e,":").concat(r.getPropertyValue(e))}).join(";"),paddingSize:a,borderSize:i,boxSizing:o};return t&&n&&(S[n]=c),c}(e,n),c=i.paddingSize,l=i.borderSize,s=i.boxSizing,u=i.sizingStyle;r.setAttribute("style","".concat(u,";").concat("\n  min-height:0 !important;\n  max-height:none !important;\n  height:0 !important;\n  visibility:hidden !important;\n  overflow:hidden !important;\n  position:absolute !important;\n  z-index:-1000 !important;\n  top:0 !important;\n  right:0 !important;\n  pointer-events: none !important;\n")),r.value=e.value||e.placeholder||"";var d=void 0,f=void 0,p=r.scrollHeight;if("border-box"===s?p+=l:"content-box"===s&&(p-=c),null!==o||null!==a){r.value=" ";var m=r.scrollHeight-c;null!==o&&(d=m*o,"border-box"===s&&(d=d+c+l),p=Math.max(d,p)),null!==a&&(f=m*a,"border-box"===s&&(f=f+c+l),t=p>f?"":"hidden",p=Math.min(f,p))}var g={height:p,overflowY:t,resize:"none"};return d&&(g.minHeight=d),f&&(g.maxHeight=f),g}(N.current,!1,F,A);D(2),G(e)}else L()},[B]);var U=o.useRef(),K=function(){w.Z.cancel(U.current)};o.useEffect(function(){return K},[]);var $=(0,u.Z)((0,u.Z)({},h),z?q:null);return(0===B||1===B)&&($.overflowY="hidden",$.overflowX="hidden"),o.createElement(y.Z,{onResize:function(e){2===B&&(null==m||m(e),d&&(K(),U.current=(0,w.Z)(function(){X()})))},disabled:!(d||m)},o.createElement("textarea",(0,l.Z)({},k,{ref:N,style:$,className:c()(n,g,(0,s.Z)({},"".concat(n,"-disabled"),Z)),disabled:Z,value:j,onChange:function(e){I(e.target.value),null==O||O(e)}})))}),O=["defaultValue","value","onFocus","onBlur","onChange","allowClear","maxLength","onCompositionStart","onCompositionEnd","suffix","prefixCls","showCount","count","className","style","disabled","hidden","classNames","styles","onResize"],k=o.forwardRef(function(e,t){var n,r,a,i=e.defaultValue,b=e.value,y=e.onFocus,x=e.onBlur,w=e.onChange,E=e.allowClear,S=e.maxLength,C=e.onCompositionStart,k=e.onCompositionEnd,M=e.suffix,R=e.prefixCls,j=void 0===R?"rc-textarea":R,I=e.showCount,N=e.count,P=e.className,T=e.style,F=e.disabled,A=e.hidden,z=e.classNames,L=e.styles,_=e.onResize,H=(0,p.Z)(e,O),B=(0,v.Z)(i,{value:b,defaultValue:i}),D=(0,f.Z)(B,2),W=D[0],V=D[1],q=null==W?"":String(W),G=o.useState(!1),X=(0,f.Z)(G,2),U=X[0],K=X[1],$=o.useRef(!1),Y=o.useState(null),Q=(0,f.Z)(Y,2),J=Q[0],ee=Q[1],et=(0,o.useRef)(null),en=function(){var e;return null===(e=et.current)||void 0===e?void 0:e.textArea},er=function(){en().focus()};(0,o.useImperativeHandle)(t,function(){return{resizableTextArea:et.current,focus:er,blur:function(){en().blur()}}}),(0,o.useEffect)(function(){K(function(e){return!F&&e})},[F]);var eo=o.useState(null),ea=(0,f.Z)(eo,2),ei=ea[0],ec=ea[1];o.useEffect(function(){if(ei){var e;(e=en()).setSelectionRange.apply(e,(0,d.Z)(ei))}},[ei]);var el=(0,g.Z)(N,I),es=null!==(n=el.max)&&void 0!==n?n:S,eu=Number(es)>0,ed=el.strategy(q),ef=!!es&&ed>es,ep=function(e,t){var n=t;!$.current&&el.exceedFormatter&&el.max&&el.strategy(t)>el.max&&(n=el.exceedFormatter(t,{max:el.max}),t!==n&&ec([en().selectionStart||0,en().selectionEnd||0])),V(n),(0,h.rJ)(e.currentTarget,e,w,n)},em=M;el.show&&(a=el.showFormatter?el.showFormatter({value:q,count:ed,maxLength:es}):"".concat(ed).concat(eu?" / ".concat(es):""),em=o.createElement(o.Fragment,null,em,o.createElement("span",{className:c()("".concat(j,"-data-count"),null==z?void 0:z.count),style:null==L?void 0:L.count},a)));var eg=!H.autoSize&&!I&&!E;return o.createElement(m.Q,{value:q,allowClear:E,handleReset:function(e){V(""),er(),(0,h.rJ)(en(),e,w)},suffix:em,prefixCls:j,classNames:(0,u.Z)((0,u.Z)({},z),{},{affixWrapper:c()(null==z?void 0:z.affixWrapper,(r={},(0,s.Z)(r,"".concat(j,"-show-count"),I),(0,s.Z)(r,"".concat(j,"-textarea-allow-clear"),E),r))}),disabled:F,focused:U,className:c()(P,ef&&"".concat(j,"-out-of-range")),style:(0,u.Z)((0,u.Z)({},T),J&&!eg?{height:"auto"}:{}),dataAttrs:{affixWrapper:{"data-count":"string"==typeof a?a:void 0}},hidden:A},o.createElement(Z,(0,l.Z)({},H,{maxLength:S,onKeyDown:function(e){var t=H.onPressEnter,n=H.onKeyDown;"Enter"===e.key&&t&&t(e),null==n||n(e)},onChange:function(e){ep(e,e.target.value)},onFocus:function(e){K(!0),null==y||y(e)},onBlur:function(e){K(!1),null==x||x(e)},onCompositionStart:function(e){$.current=!0,null==C||C(e)},onCompositionEnd:function(e){$.current=!1,ep(e,e.currentTarget.value),null==k||k(e)},className:c()(null==z?void 0:z.textarea),style:(0,u.Z)((0,u.Z)({},null==L?void 0:L.textarea),{},{resize:null==T?void 0:T.resize}),disabled:F,prefixCls:j,onResize:function(e){var t;null==_||_(e),null!==(t=en())&&void 0!==t&&t.style.height&&ee(!0)},ref:et})))}),M=n(12757),R=n(71744),j=n(86586),I=n(33759),N=n(39109),P=n(65863),T=n(31282),F=n(64024),A=n(56250),z=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n},L=(0,o.forwardRef)((e,t)=>{var n;let r;let{prefixCls:i,bordered:l=!0,size:s,disabled:u,status:d,allowClear:f,classNames:p,rootClassName:m,className:g,variant:h}=e,v=z(e,["prefixCls","bordered","size","disabled","status","allowClear","classNames","rootClassName","className","variant"]),{getPrefixCls:b,direction:y}=o.useContext(R.E_),x=(0,I.Z)(s),w=o.useContext(j.Z),{status:E,hasFeedback:S,feedbackIcon:C}=o.useContext(N.aM),Z=(0,M.F)(E,d),O=o.useRef(null);o.useImperativeHandle(t,()=>{var e;return{resizableTextArea:null===(e=O.current)||void 0===e?void 0:e.resizableTextArea,focus:e=>{var t,n;(0,P.n)(null===(n=null===(t=O.current)||void 0===t?void 0:t.resizableTextArea)||void 0===n?void 0:n.textArea,e)},blur:()=>{var e;return null===(e=O.current)||void 0===e?void 0:e.blur()}}});let L=b("input",i);"object"==typeof f&&(null==f?void 0:f.clearIcon)?r=f:f&&(r={clearIcon:o.createElement(a.Z,null)});let _=(0,F.Z)(L),[H,B,D]=(0,T.ZP)(L,_),[W,V]=(0,A.Z)(h,l);return H(o.createElement(k,Object.assign({},v,{disabled:null!=u?u:w,allowClear:r,className:c()(D,_,g,m),classNames:Object.assign(Object.assign({},p),{textarea:c()({["".concat(L,"-sm")]:"small"===x,["".concat(L,"-lg")]:"large"===x},B,null==p?void 0:p.textarea),variant:c()({["".concat(L,"-").concat(W)]:V},(0,M.Z)(L,Z)),affixWrapper:c()("".concat(L,"-textarea-affix-wrapper"),{["".concat(L,"-affix-wrapper-rtl")]:"rtl"===y,["".concat(L,"-affix-wrapper-sm")]:"small"===x,["".concat(L,"-affix-wrapper-lg")]:"large"===x,["".concat(L,"-textarea-show-count")]:e.showCount||(null===(n=e.count)||void 0===n?void 0:n.show)},B)}),prefixCls:L,suffix:S&&o.createElement("span",{className:"".concat(L,"-textarea-suffix")},C),ref:O})))})},39164:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(2265);function o(e,t){let n=(0,r.useRef)([]),o=()=>{n.current.push(setTimeout(()=>{var t,n,r,o;(null===(t=e.current)||void 0===t?void 0:t.input)&&(null===(n=e.current)||void 0===n?void 0:n.input.getAttribute("type"))==="password"&&(null===(r=e.current)||void 0===r?void 0:r.input.hasAttribute("value"))&&(null===(o=e.current)||void 0===o||o.input.removeAttribute("value"))}))};return(0,r.useEffect)(()=>(t&&o(),()=>n.current.forEach(e=>{e&&clearTimeout(e)})),[]),o}},64482:function(e,t,n){"use strict";n.d(t,{default:function(){return M}});var r=n(2265),o=n(36760),a=n.n(o),i=n(71744),c=n(39109),l=n(31282),s=n(65863),u=n(97416),d=n(6520),f=n(18694),p=n(28791),m=n(39164),g=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let h=e=>e?r.createElement(d.Z,null):r.createElement(u.Z,null),v={click:"onClick",hover:"onMouseOver"},b=r.forwardRef((e,t)=>{let{visibilityToggle:n=!0}=e,o="object"==typeof n&&void 0!==n.visible,[c,l]=(0,r.useState)(()=>!!o&&n.visible),u=(0,r.useRef)(null);r.useEffect(()=>{o&&l(n.visible)},[o,n]);let d=(0,m.Z)(u),b=()=>{let{disabled:t}=e;t||(c&&d(),l(e=>{var t;let r=!e;return"object"==typeof n&&(null===(t=n.onVisibleChange)||void 0===t||t.call(n,r)),r}))},{className:y,prefixCls:x,inputPrefixCls:w,size:E}=e,S=g(e,["className","prefixCls","inputPrefixCls","size"]),{getPrefixCls:C}=r.useContext(i.E_),Z=C("input",w),O=C("input-password",x),k=n&&(t=>{let{action:n="click",iconRender:o=h}=e,a=v[n]||"",i=o(c);return r.cloneElement(r.isValidElement(i)?i:r.createElement("span",null,i),{[a]:b,className:"".concat(t,"-icon"),key:"passwordIcon",onMouseDown:e=>{e.preventDefault()},onMouseUp:e=>{e.preventDefault()}})})(O),M=a()(O,y,{["".concat(O,"-").concat(E)]:!!E}),R=Object.assign(Object.assign({},(0,f.Z)(S,["suffix","iconRender","visibilityToggle"])),{type:c?"text":"password",className:M,prefixCls:Z,suffix:k});return E&&(R.size=E),r.createElement(s.Z,Object.assign({ref:(0,p.sQ)(t,u)},R))});var y=n(29436),x=n(19722),w=n(73002),E=n(33759),S=n(65658),C=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let Z=r.forwardRef((e,t)=>{let n;let{prefixCls:o,inputPrefixCls:c,className:l,size:u,suffix:d,enterButton:f=!1,addonAfter:m,loading:g,disabled:h,onSearch:v,onChange:b,onCompositionStart:Z,onCompositionEnd:O}=e,k=C(e,["prefixCls","inputPrefixCls","className","size","suffix","enterButton","addonAfter","loading","disabled","onSearch","onChange","onCompositionStart","onCompositionEnd"]),{getPrefixCls:M,direction:R}=r.useContext(i.E_),j=r.useRef(!1),I=M("input-search",o),N=M("input",c),{compactSize:P}=(0,S.ri)(I,R),T=(0,E.Z)(e=>{var t;return null!==(t=null!=u?u:P)&&void 0!==t?t:e}),F=r.useRef(null),A=e=>{var t;document.activeElement===(null===(t=F.current)||void 0===t?void 0:t.input)&&e.preventDefault()},z=e=>{var t,n;v&&v(null===(n=null===(t=F.current)||void 0===t?void 0:t.input)||void 0===n?void 0:n.value,e,{source:"input"})},L="boolean"==typeof f?r.createElement(y.Z,null):null,_="".concat(I,"-button"),H=f||{},B=H.type&&!0===H.type.__ANT_BUTTON;n=B||"button"===H.type?(0,x.Tm)(H,Object.assign({onMouseDown:A,onClick:e=>{var t,n;null===(n=null===(t=null==H?void 0:H.props)||void 0===t?void 0:t.onClick)||void 0===n||n.call(t,e),z(e)},key:"enterButton"},B?{className:_,size:T}:{})):r.createElement(w.ZP,{className:_,type:f?"primary":void 0,size:T,disabled:h,key:"enterButton",onMouseDown:A,onClick:z,loading:g,icon:L},f),m&&(n=[n,(0,x.Tm)(m,{key:"addonAfter"})]);let D=a()(I,{["".concat(I,"-rtl")]:"rtl"===R,["".concat(I,"-").concat(T)]:!!T,["".concat(I,"-with-button")]:!!f},l);return r.createElement(s.Z,Object.assign({ref:(0,p.sQ)(F,t),onPressEnter:e=>{j.current||g||z(e)}},k,{size:T,onCompositionStart:e=>{j.current=!0,null==Z||Z(e)},onCompositionEnd:e=>{j.current=!1,null==O||O(e)},prefixCls:N,addonAfter:n,suffix:d,onChange:e=>{e&&e.target&&"click"===e.type&&v&&v(e.target.value,e,{source:"clear"}),b&&b(e)},className:D,disabled:h}))});var O=n(90464);let k=s.Z;k.Group=e=>{let{getPrefixCls:t,direction:n}=(0,r.useContext)(i.E_),{prefixCls:o,className:s}=e,u=t("input-group",o),d=t("input"),[f,p]=(0,l.ZP)(d),m=a()(u,{["".concat(u,"-lg")]:"large"===e.size,["".concat(u,"-sm")]:"small"===e.size,["".concat(u,"-compact")]:e.compact,["".concat(u,"-rtl")]:"rtl"===n},p,s),g=(0,r.useContext)(c.aM),h=(0,r.useMemo)(()=>Object.assign(Object.assign({},g),{isFormItemInput:!1}),[g]);return f(r.createElement("span",{className:m,style:e.style,onMouseEnter:e.onMouseEnter,onMouseLeave:e.onMouseLeave,onFocus:e.onFocus,onBlur:e.onBlur},r.createElement(c.aM.Provider,{value:h},e.children)))},k.Search=Z,k.TextArea=O.Z,k.Password=b;var M=k},31282:function(e,t,n){"use strict";n.d(t,{ik:function(){return p},nz:function(){return u},s7:function(){return m},x0:function(){return f}});var r=n(352),o=n(12918),a=n(17691),i=n(80669),c=n(3104),l=n(37433),s=n(65265);let u=e=>({"&::-moz-placeholder":{opacity:1},"&::placeholder":{color:e,userSelect:"none"},"&:placeholder-shown":{textOverflow:"ellipsis"}}),d=e=>{let{paddingBlockLG:t,lineHeightLG:n,borderRadiusLG:o,paddingInlineLG:a}=e;return{padding:"".concat((0,r.bf)(t)," ").concat((0,r.bf)(a)),fontSize:e.inputFontSizeLG,lineHeight:n,borderRadius:o}},f=e=>({padding:"".concat((0,r.bf)(e.paddingBlockSM)," ").concat((0,r.bf)(e.paddingInlineSM)),fontSize:e.inputFontSizeSM,borderRadius:e.borderRadiusSM}),p=e=>Object.assign(Object.assign({position:"relative",display:"inline-block",width:"100%",minWidth:0,padding:"".concat((0,r.bf)(e.paddingBlock)," ").concat((0,r.bf)(e.paddingInline)),color:e.colorText,fontSize:e.inputFontSize,lineHeight:e.lineHeight,borderRadius:e.borderRadius,transition:"all ".concat(e.motionDurationMid)},u(e.colorTextPlaceholder)),{"textarea&":{maxWidth:"100%",height:"auto",minHeight:e.controlHeight,lineHeight:e.lineHeight,verticalAlign:"bottom",transition:"all ".concat(e.motionDurationSlow,", height 0s"),resize:"vertical"},"&-lg":Object.assign({},d(e)),"&-sm":Object.assign({},f(e)),"&-rtl":{direction:"rtl"},"&-textarea-rtl":{direction:"rtl"}}),m=e=>{let{componentCls:t,antCls:n}=e;return{position:"relative",display:"table",width:"100%",borderCollapse:"separate",borderSpacing:0,"&[class*='col-']":{paddingInlineEnd:e.paddingXS,"&:last-child":{paddingInlineEnd:0}},["&-lg ".concat(t,", &-lg > ").concat(t,"-group-addon")]:Object.assign({},d(e)),["&-sm ".concat(t,", &-sm > ").concat(t,"-group-addon")]:Object.assign({},f(e)),["&-lg ".concat(n,"-select-single ").concat(n,"-select-selector")]:{height:e.controlHeightLG},["&-sm ".concat(n,"-select-single ").concat(n,"-select-selector")]:{height:e.controlHeightSM},["> ".concat(t)]:{display:"table-cell","&:not(:first-child):not(:last-child)":{borderRadius:0}},["".concat(t,"-group")]:{"&-addon, &-wrap":{display:"table-cell",width:1,whiteSpace:"nowrap",verticalAlign:"middle","&:not(:first-child):not(:last-child)":{borderRadius:0}},"&-wrap > *":{display:"block !important"},"&-addon":{position:"relative",padding:"0 ".concat((0,r.bf)(e.paddingInline)),color:e.colorText,fontWeight:"normal",fontSize:e.inputFontSize,textAlign:"center",borderRadius:e.borderRadius,transition:"all ".concat(e.motionDurationSlow),lineHeight:1,["".concat(n,"-select")]:{margin:"".concat((0,r.bf)(e.calc(e.paddingBlock).add(1).mul(-1).equal())," ").concat((0,r.bf)(e.calc(e.paddingInline).mul(-1).equal())),["&".concat(n,"-select-single:not(").concat(n,"-select-customize-input):not(").concat(n,"-pagination-size-changer)")]:{["".concat(n,"-select-selector")]:{backgroundColor:"inherit",border:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," transparent"),boxShadow:"none"}},"&-open, &-focused":{["".concat(n,"-select-selector")]:{color:e.colorPrimary}}},["".concat(n,"-cascader-picker")]:{margin:"-9px ".concat((0,r.bf)(e.calc(e.paddingInline).mul(-1).equal())),backgroundColor:"transparent",["".concat(n,"-cascader-input")]:{textAlign:"start",border:0,boxShadow:"none"}}}},["".concat(t)]:{width:"100%",marginBottom:0,textAlign:"inherit","&:focus":{zIndex:1,borderInlineEndWidth:1},"&:hover":{zIndex:1,borderInlineEndWidth:1,["".concat(t,"-search-with-button &")]:{zIndex:0}}},["> ".concat(t,":first-child, ").concat(t,"-group-addon:first-child")]:{borderStartEndRadius:0,borderEndEndRadius:0,["".concat(n,"-select ").concat(n,"-select-selector")]:{borderStartEndRadius:0,borderEndEndRadius:0}},["> ".concat(t,"-affix-wrapper")]:{["&:not(:first-child) ".concat(t)]:{borderStartStartRadius:0,borderEndStartRadius:0},["&:not(:last-child) ".concat(t)]:{borderStartEndRadius:0,borderEndEndRadius:0}},["> ".concat(t,":last-child, ").concat(t,"-group-addon:last-child")]:{borderStartStartRadius:0,borderEndStartRadius:0,["".concat(n,"-select ").concat(n,"-select-selector")]:{borderStartStartRadius:0,borderEndStartRadius:0}},["".concat(t,"-affix-wrapper")]:{"&:not(:last-child)":{borderStartEndRadius:0,borderEndEndRadius:0,["".concat(t,"-search &")]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius}},["&:not(:first-child), ".concat(t,"-search &:not(:first-child)")]:{borderStartStartRadius:0,borderEndStartRadius:0}},["&".concat(t,"-group-compact")]:Object.assign(Object.assign({display:"block"},(0,o.dF)()),{["".concat(t,"-group-addon, ").concat(t,"-group-wrap, > ").concat(t)]:{"&:not(:first-child):not(:last-child)":{borderInlineEndWidth:e.lineWidth,"&:hover":{zIndex:1},"&:focus":{zIndex:1}}},"& > *":{display:"inline-block",float:"none",verticalAlign:"top",borderRadius:0},["\n        & > ".concat(t,"-affix-wrapper,\n        & > ").concat(t,"-number-affix-wrapper,\n        & > ").concat(n,"-picker-range\n      ")]:{display:"inline-flex"},"& > *:not(:last-child)":{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal(),borderInlineEndWidth:e.lineWidth},["".concat(t)]:{float:"none"},["& > ".concat(n,"-select > ").concat(n,"-select-selector,\n      & > ").concat(n,"-select-auto-complete ").concat(t,",\n      & > ").concat(n,"-cascader-picker ").concat(t,",\n      & > ").concat(t,"-group-wrapper ").concat(t)]:{borderInlineEndWidth:e.lineWidth,borderRadius:0,"&:hover":{zIndex:1},"&:focus":{zIndex:1}},["& > ".concat(n,"-select-focused")]:{zIndex:1},["& > ".concat(n,"-select > ").concat(n,"-select-arrow")]:{zIndex:1},["& > *:first-child,\n      & > ".concat(n,"-select:first-child > ").concat(n,"-select-selector,\n      & > ").concat(n,"-select-auto-complete:first-child ").concat(t,",\n      & > ").concat(n,"-cascader-picker:first-child ").concat(t)]:{borderStartStartRadius:e.borderRadius,borderEndStartRadius:e.borderRadius},["& > *:last-child,\n      & > ".concat(n,"-select:last-child > ").concat(n,"-select-selector,\n      & > ").concat(n,"-cascader-picker:last-child ").concat(t,",\n      & > ").concat(n,"-cascader-picker-focused:last-child ").concat(t)]:{borderInlineEndWidth:e.lineWidth,borderStartEndRadius:e.borderRadius,borderEndEndRadius:e.borderRadius},["& > ".concat(n,"-select-auto-complete ").concat(t)]:{verticalAlign:"top"},["".concat(t,"-group-wrapper + ").concat(t,"-group-wrapper")]:{marginInlineStart:e.calc(e.lineWidth).mul(-1).equal(),["".concat(t,"-affix-wrapper")]:{borderRadius:0}},["".concat(t,"-group-wrapper:not(:last-child)")]:{["&".concat(t,"-search > ").concat(t,"-group")]:{["& > ".concat(t,"-group-addon > ").concat(t,"-search-button")]:{borderRadius:0},["& > ".concat(t)]:{borderStartStartRadius:e.borderRadius,borderStartEndRadius:0,borderEndEndRadius:0,borderEndStartRadius:e.borderRadius}}}})}},g=e=>{let{componentCls:t,controlHeightSM:n,lineWidth:r,calc:a}=e,i=a(n).sub(a(r).mul(2)).sub(16).div(2).equal();return{[t]:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},(0,o.Wf)(e)),p(e)),(0,s.qG)(e)),(0,s.H8)(e)),(0,s.Mu)(e)),{'&[type="color"]':{height:e.controlHeight,["&".concat(t,"-lg")]:{height:e.controlHeightLG},["&".concat(t,"-sm")]:{height:n,paddingTop:i,paddingBottom:i}},'&[type="search"]::-webkit-search-cancel-button, &[type="search"]::-webkit-search-decoration':{"-webkit-appearance":"none"}})}},h=e=>{let{componentCls:t}=e;return{["".concat(t,"-clear-icon")]:{margin:0,color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,verticalAlign:-1,cursor:"pointer",transition:"color ".concat(e.motionDurationSlow),"&:hover":{color:e.colorTextTertiary},"&:active":{color:e.colorText},"&-hidden":{visibility:"hidden"},"&-has-suffix":{margin:"0 ".concat((0,r.bf)(e.inputAffixPadding))}}}},v=e=>{let{componentCls:t,inputAffixPadding:n,colorTextDescription:r,motionDurationSlow:o,colorIcon:a,colorIconHover:i,iconCls:c}=e;return{["".concat(t,"-affix-wrapper")]:Object.assign(Object.assign(Object.assign(Object.assign({},p(e)),{display:"inline-flex",["&:not(".concat(t,"-disabled):hover")]:{zIndex:1,["".concat(t,"-search-with-button &")]:{zIndex:0}},"&-focused, &:focus":{zIndex:1},["> input".concat(t)]:{padding:0,fontSize:"inherit",border:"none",borderRadius:0,outline:"none",background:"transparent",color:"inherit","&::-ms-reveal":{display:"none"},"&:focus":{boxShadow:"none !important"}},"&::before":{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'},["".concat(t)]:{"&-prefix, &-suffix":{display:"flex",flex:"none",alignItems:"center","> *:not(:last-child)":{marginInlineEnd:e.paddingXS}},"&-show-count-suffix":{color:r},"&-show-count-has-suffix":{marginInlineEnd:e.paddingXXS},"&-prefix":{marginInlineEnd:n},"&-suffix":{marginInlineStart:n}}}),h(e)),{["".concat(c).concat(t,"-password-icon")]:{color:a,cursor:"pointer",transition:"all ".concat(o),"&:hover":{color:i}}})}},b=e=>{let{componentCls:t,borderRadiusLG:n,borderRadiusSM:r}=e;return{["".concat(t,"-group")]:Object.assign(Object.assign(Object.assign({},(0,o.Wf)(e)),m(e)),{"&-rtl":{direction:"rtl"},"&-wrapper":Object.assign(Object.assign(Object.assign({display:"inline-block",width:"100%",textAlign:"start",verticalAlign:"top","&-rtl":{direction:"rtl"},"&-lg":{["".concat(t,"-group-addon")]:{borderRadius:n,fontSize:e.inputFontSizeLG}},"&-sm":{["".concat(t,"-group-addon")]:{borderRadius:r}}},(0,s.ir)(e)),(0,s.S5)(e)),{["&:not(".concat(t,"-compact-first-item):not(").concat(t,"-compact-last-item)").concat(t,"-compact-item")]:{["".concat(t,", ").concat(t,"-group-addon")]:{borderRadius:0}},["&:not(".concat(t,"-compact-last-item)").concat(t,"-compact-first-item")]:{["".concat(t,", ").concat(t,"-group-addon")]:{borderStartEndRadius:0,borderEndEndRadius:0}},["&:not(".concat(t,"-compact-first-item)").concat(t,"-compact-last-item")]:{["".concat(t,", ").concat(t,"-group-addon")]:{borderStartStartRadius:0,borderEndStartRadius:0}}})})}},y=e=>{let{componentCls:t,antCls:n}=e,r="".concat(t,"-search");return{[r]:{["".concat(t)]:{"&:hover, &:focus":{borderColor:e.colorPrimaryHover,["+ ".concat(t,"-group-addon ").concat(r,"-button:not(").concat(n,"-btn-primary)")]:{borderInlineStartColor:e.colorPrimaryHover}}},["".concat(t,"-affix-wrapper")]:{borderRadius:0},["".concat(t,"-lg")]:{lineHeight:e.calc(e.lineHeightLG).sub(2e-4).equal({unit:!1})},["> ".concat(t,"-group")]:{["> ".concat(t,"-group-addon:last-child")]:{insetInlineStart:-1,padding:0,border:0,["".concat(r,"-button")]:{paddingTop:0,paddingBottom:0,borderStartStartRadius:0,borderStartEndRadius:e.borderRadius,borderEndEndRadius:e.borderRadius,borderEndStartRadius:0,boxShadow:"none"},["".concat(r,"-button:not(").concat(n,"-btn-primary)")]:{color:e.colorTextDescription,"&:hover":{color:e.colorPrimaryHover},"&:active":{color:e.colorPrimaryActive},["&".concat(n,"-btn-loading::before")]:{insetInlineStart:0,insetInlineEnd:0,insetBlockStart:0,insetBlockEnd:0}}}},["".concat(r,"-button")]:{height:e.controlHeight,"&:hover, &:focus":{zIndex:1}},["&-large ".concat(r,"-button")]:{height:e.controlHeightLG},["&-small ".concat(r,"-button")]:{height:e.controlHeightSM},"&-rtl":{direction:"rtl"},["&".concat(t,"-compact-item")]:{["&:not(".concat(t,"-compact-last-item)")]:{["".concat(t,"-group-addon")]:{["".concat(t,"-search-button")]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal(),borderRadius:0}}},["&:not(".concat(t,"-compact-first-item)")]:{["".concat(t,",").concat(t,"-affix-wrapper")]:{borderRadius:0}},["> ".concat(t,"-group-addon ").concat(t,"-search-button,\n        > ").concat(t,",\n        ").concat(t,"-affix-wrapper")]:{"&:hover,&:focus,&:active":{zIndex:2}},["> ".concat(t,"-affix-wrapper-focused")]:{zIndex:2}}}}},x=e=>{let{componentCls:t,paddingLG:n}=e,r="".concat(t,"-textarea");return{[r]:{position:"relative","&-show-count":{["> ".concat(t)]:{height:"100%"},["".concat(t,"-data-count")]:{position:"absolute",bottom:e.calc(e.fontSize).mul(e.lineHeight).mul(-1).equal(),insetInlineEnd:0,color:e.colorTextDescription,whiteSpace:"nowrap",pointerEvents:"none"}},"&-allow-clear":{["> ".concat(t)]:{paddingInlineEnd:n}},["&-affix-wrapper".concat(r,"-has-feedback")]:{["".concat(t)]:{paddingInlineEnd:n}},["&-affix-wrapper".concat(t,"-affix-wrapper")]:{padding:0,["> textarea".concat(t)]:{fontSize:"inherit",border:"none",outline:"none",background:"transparent","&:focus":{boxShadow:"none !important"}},["".concat(t,"-suffix")]:{margin:0,"> *:not(:last-child)":{marginInline:0},["".concat(t,"-clear-icon")]:{position:"absolute",insetInlineEnd:e.paddingXS,insetBlockStart:e.paddingXS},["".concat(r,"-suffix")]:{position:"absolute",top:0,insetInlineEnd:e.paddingInline,bottom:0,zIndex:1,display:"inline-flex",alignItems:"center",margin:"auto",pointerEvents:"none"}}}}}},w=e=>{let{componentCls:t}=e;return{["".concat(t,"-out-of-range")]:{["&, & input, & textarea, ".concat(t,"-show-count-suffix, ").concat(t,"-data-count")]:{color:e.colorError}}}};t.ZP=(0,i.I$)("Input",e=>{let t=(0,c.TS)(e,(0,l.e)(e));return[g(t),x(t),v(t),b(t),y(t),w(t),(0,a.c)(t)]},l.T)},37433:function(e,t,n){"use strict";n.d(t,{T:function(){return a},e:function(){return o}});var r=n(3104);function o(e){return(0,r.TS)(e,{inputAffixPadding:e.paddingXXS})}let a=e=>{let{controlHeight:t,fontSize:n,lineHeight:r,lineWidth:o,controlHeightSM:a,controlHeightLG:i,fontSizeLG:c,lineHeightLG:l,paddingSM:s,controlPaddingHorizontalSM:u,controlPaddingHorizontal:d,colorFillAlter:f,colorPrimaryHover:p,colorPrimary:m,controlOutlineWidth:g,controlOutline:h,colorErrorOutline:v,colorWarningOutline:b,colorBgContainer:y}=e;return{paddingBlock:Math.max(Math.round((t-n*r)/2*10)/10-o,0),paddingBlockSM:Math.max(Math.round((a-n*r)/2*10)/10-o,0),paddingBlockLG:Math.ceil((i-c*l)/2*10)/10-o,paddingInline:s-o,paddingInlineSM:u-o,paddingInlineLG:d-o,addonBg:f,activeBorderColor:m,hoverBorderColor:p,activeShadow:"0 0 0 ".concat(g,"px ").concat(h),errorActiveShadow:"0 0 0 ".concat(g,"px ").concat(v),warningActiveShadow:"0 0 0 ".concat(g,"px ").concat(b),hoverBg:y,activeBg:y,inputFontSize:n,inputFontSizeLG:c,inputFontSizeSM:n}}},65265:function(e,t,n){"use strict";n.d(t,{$U:function(){return c},H8:function(){return g},Mu:function(){return f},S5:function(){return v},Xy:function(){return i},ir:function(){return d},qG:function(){return s}});var r=n(352),o=n(3104);let a=e=>({borderColor:e.hoverBorderColor,backgroundColor:e.hoverBg}),i=e=>({color:e.colorTextDisabled,backgroundColor:e.colorBgContainerDisabled,borderColor:e.colorBorder,boxShadow:"none",cursor:"not-allowed",opacity:1,"&:hover:not([disabled])":Object.assign({},a((0,o.TS)(e,{hoverBorderColor:e.colorBorder,hoverBg:e.colorBgContainerDisabled})))}),c=(e,t)=>({background:e.colorBgContainer,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:t.borderColor,"&:hover":{borderColor:t.hoverBorderColor,backgroundColor:e.hoverBg},"&:focus, &:focus-within":{borderColor:t.activeBorderColor,boxShadow:t.activeShadow,outline:0,backgroundColor:e.activeBg}}),l=(e,t)=>({["&".concat(e.componentCls,"-status-").concat(t.status,":not(").concat(e.componentCls,"-disabled)")]:Object.assign(Object.assign({},c(e,t)),{["".concat(e.componentCls,"-prefix, ").concat(e.componentCls,"-suffix")]:{color:t.affixColor}})}),s=(e,t)=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},c(e,{borderColor:e.colorBorder,hoverBorderColor:e.colorPrimaryHover,activeBorderColor:e.colorPrimary,activeShadow:e.activeShadow})),{["&".concat(e.componentCls,"-disabled, &[disabled]")]:Object.assign({},i(e))}),l(e,{status:"error",borderColor:e.colorError,hoverBorderColor:e.colorErrorBorderHover,activeBorderColor:e.colorError,activeShadow:e.errorActiveShadow,affixColor:e.colorError})),l(e,{status:"warning",borderColor:e.colorWarning,hoverBorderColor:e.colorWarningBorderHover,activeBorderColor:e.colorWarning,activeShadow:e.warningActiveShadow,affixColor:e.colorWarning})),t)}),u=(e,t)=>({["&".concat(e.componentCls,"-group-wrapper-status-").concat(t.status)]:{["".concat(e.componentCls,"-group-addon")]:{borderColor:t.addonBorderColor,color:t.addonColor}}}),d=e=>({"&-outlined":Object.assign(Object.assign(Object.assign({["".concat(e.componentCls,"-group")]:{"&-addon":{background:e.addonBg,border:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder)},"&-addon:first-child":{borderInlineEnd:0},"&-addon:last-child":{borderInlineStart:0}}},u(e,{status:"error",addonBorderColor:e.colorError,addonColor:e.colorErrorText})),u(e,{status:"warning",addonBorderColor:e.colorWarning,addonColor:e.colorWarningText})),{["&".concat(e.componentCls,"-group-wrapper-disabled")]:{["".concat(e.componentCls,"-group-addon")]:Object.assign({},i(e))}})}),f=(e,t)=>({"&-borderless":Object.assign({background:"transparent",border:"none","&:focus, &:focus-within":{outline:"none"},["&".concat(e.componentCls,"-disabled, &[disabled]")]:{color:e.colorTextDisabled}},t)}),p=(e,t)=>({background:t.bg,borderWidth:e.lineWidth,borderStyle:e.lineType,borderColor:"transparent","input&, & input, textarea&, & textarea":{color:null==t?void 0:t.inputColor},"&:hover":{background:t.hoverBg},"&:focus, &:focus-within":{outline:0,borderColor:t.activeBorderColor,backgroundColor:e.activeBg}}),m=(e,t)=>({["&".concat(e.componentCls,"-status-").concat(t.status,":not(").concat(e.componentCls,"-disabled)")]:Object.assign(Object.assign({},p(e,t)),{["".concat(e.componentCls,"-prefix, ").concat(e.componentCls,"-suffix")]:{color:t.affixColor}})}),g=(e,t)=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},p(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.colorPrimary})),{["&".concat(e.componentCls,"-disabled, &[disabled]")]:Object.assign({},i(e))}),m(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,inputColor:e.colorErrorText,affixColor:e.colorError})),m(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,inputColor:e.colorWarningText,affixColor:e.colorWarning})),t)}),h=(e,t)=>({["&".concat(e.componentCls,"-group-wrapper-status-").concat(t.status)]:{["".concat(e.componentCls,"-group-addon")]:{background:t.addonBg,color:t.addonColor}}}),v=e=>({"&-filled":Object.assign(Object.assign(Object.assign({["".concat(e.componentCls,"-group")]:{"&-addon":{background:e.colorFillTertiary},["".concat(e.componentCls,"-filled:not(:focus):not(:focus-within)")]:{"&:not(:first-child)":{borderInlineStart:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorSplit)},"&:not(:last-child)":{borderInlineEnd:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorSplit)}}}},h(e,{status:"error",addonBg:e.colorErrorBg,addonColor:e.colorErrorText})),h(e,{status:"warning",addonBg:e.colorWarningBg,addonColor:e.colorWarningText})),{["&".concat(e.componentCls,"-group-wrapper-disabled")]:{["".concat(e.componentCls,"-group")]:{"&-addon":{background:e.colorFillTertiary,color:e.colorTextDisabled},"&-addon:first-child":{borderInlineStart:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder),borderTop:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder),borderBottom:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder)},"&-addon:last-child":{borderInlineEnd:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder),borderTop:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder),borderBottom:"".concat((0,r.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorBorder)}}}})})},91325:function(e,t,n){"use strict";let r=(0,n(2265).createContext)(void 0);t.Z=r},13823:function(e,t,n){"use strict";n.d(t,{Z:function(){return c}});var r=n(96257),o={placeholder:"Select time",rangePlaceholder:["Start time","End time"]};let a={lang:Object.assign({placeholder:"Select date",yearPlaceholder:"Select year",quarterPlaceholder:"Select quarter",monthPlaceholder:"Select month",weekPlaceholder:"Select week",rangePlaceholder:["Start date","End date"],rangeYearPlaceholder:["Start year","End year"],rangeQuarterPlaceholder:["Start quarter","End quarter"],rangeMonthPlaceholder:["Start month","End month"],rangeWeekPlaceholder:["Start week","End week"]},{locale:"en_US",today:"Today",now:"Now",backToToday:"Back to today",ok:"OK",clear:"Clear",month:"Month",year:"Year",timeSelect:"select time",dateSelect:"select date",weekSelect:"Choose a week",monthSelect:"Choose a month",yearSelect:"Choose a year",decadeSelect:"Choose a decade",yearFormat:"YYYY",dateFormat:"M/D/YYYY",dayFormat:"D",dateTimeFormat:"M/D/YYYY HH:mm:ss",monthBeforeYear:!0,previousMonth:"Previous month (PageUp)",nextMonth:"Next month (PageDown)",previousYear:"Last year (Control + left)",nextYear:"Next year (Control + right)",previousDecade:"Last decade",nextDecade:"Next decade",previousCentury:"Last century",nextCentury:"Next century"}),timePickerLocale:Object.assign({},o)},i="${label} is not a valid ${type}";var c={locale:"en",Pagination:r.Z,DatePicker:a,TimePicker:o,Calendar:a,global:{placeholder:"Please select"},Table:{filterTitle:"Filter menu",filterConfirm:"OK",filterReset:"Reset",filterEmptyText:"No filters",filterCheckall:"Select all items",filterSearchPlaceholder:"Search in filters",emptyText:"No data",selectAll:"Select current page",selectInvert:"Invert current page",selectNone:"Clear all data",selectionAll:"Select all data",sortTitle:"Sort",expand:"Expand row",collapse:"Collapse row",triggerDesc:"Click to sort descending",triggerAsc:"Click to sort ascending",cancelSort:"Click to cancel sorting"},Tour:{Next:"Next",Previous:"Previous",Finish:"Finish"},Modal:{okText:"OK",cancelText:"Cancel",justOkText:"OK"},Popconfirm:{okText:"OK",cancelText:"Cancel"},Transfer:{titles:["",""],searchPlaceholder:"Search here",itemUnit:"item",itemsUnit:"items",remove:"Remove",selectCurrent:"Select current page",removeCurrent:"Remove current page",selectAll:"Select all data",removeAll:"Remove all data",selectInvert:"Invert current page"},Upload:{uploading:"Uploading...",removeFile:"Remove file",uploadError:"Upload error",previewFile:"Preview file",downloadFile:"Download file"},Empty:{description:"No data"},Icon:{icon:"icon"},Text:{edit:"Edit",copy:"Copy",copied:"Copied",expand:"Expand"},PageHeader:{back:"Back"},Form:{optional:"(optional)",defaultValidateMessages:{default:"Field validation error for ${label}",required:"Please enter ${label}",enum:"${label} must be one of [${enum}]",whitespace:"${label} cannot be a blank character",date:{format:"${label} date format is invalid",parse:"${label} cannot be converted to a date",invalid:"${label} is an invalid date"},types:{string:i,method:i,array:i,object:i,number:i,date:i,boolean:i,integer:i,float:i,regexp:i,email:i,url:i,hex:i},string:{len:"${label} must be ${len} characters",min:"${label} must be at least ${min} characters",max:"${label} must be up to ${max} characters",range:"${label} must be between ${min}-${max} characters"},number:{len:"${label} must be equal to ${len}",min:"${label} must be minimum ${min}",max:"${label} must be maximum ${max}",range:"${label} must be between ${min}-${max}"},array:{len:"Must be ${len} ${label}",min:"At least ${min} ${label}",max:"At most ${max} ${label}",range:"The amount of ${label} must be between ${min}-${max}"},pattern:{mismatch:"${label} does not match the pattern ${pattern}"}}},Image:{preview:"Preview"},QRCode:{expired:"QR code expired",refresh:"Refresh",scanned:"Scanned"},ColorPicker:{presetEmpty:"Empty"}}},55274:function(e,t,n){"use strict";var r=n(2265),o=n(91325),a=n(13823);t.Z=(e,t)=>{let n=r.useContext(o.Z);return[r.useMemo(()=>{var r;let o=t||a.Z[e],i=null!==(r=null==n?void 0:n[e])&&void 0!==r?r:{};return Object.assign(Object.assign({},"function"==typeof o?o():o),i||{})},[e,t,n]),r.useMemo(()=>{let e=null==n?void 0:n.locale;return(null==n?void 0:n.exist)&&!e?a.Z.locale:e},[n])]}},42264:function(e,t,n){"use strict";n.d(t,{ZP:function(){return G}});var r=n(83145),o=n(2265),a=n(18404),i=n(52402),c=n(71744),l=n(13959),s=n(8900),u=n(39725),d=n(54537),f=n(55726),p=n(61935),m=n(36760),g=n.n(m),h=n(49283),v=n(352),b=n(62236),y=n(12918),x=n(80669),w=n(3104);let E=e=>{let{componentCls:t,iconCls:n,boxShadow:r,colorText:o,colorSuccess:a,colorError:i,colorWarning:c,colorInfo:l,fontSizeLG:s,motionEaseInOutCirc:u,motionDurationSlow:d,marginXS:f,paddingXS:p,borderRadiusLG:m,zIndexPopup:g,contentPadding:h,contentBg:b}=e,x="".concat(t,"-notice"),w=new v.E4("MessageMoveIn",{"0%":{padding:0,transform:"translateY(-100%)",opacity:0},"100%":{padding:p,transform:"translateY(0)",opacity:1}}),E=new v.E4("MessageMoveOut",{"0%":{maxHeight:e.height,padding:p,opacity:1},"100%":{maxHeight:0,padding:0,opacity:0}}),S={padding:p,textAlign:"center",["".concat(t,"-custom-content > ").concat(n)]:{verticalAlign:"text-bottom",marginInlineEnd:f,fontSize:s},["".concat(x,"-content")]:{display:"inline-block",padding:h,background:b,borderRadius:m,boxShadow:r,pointerEvents:"all"},["".concat(t,"-success > ").concat(n)]:{color:a},["".concat(t,"-error > ").concat(n)]:{color:i},["".concat(t,"-warning > ").concat(n)]:{color:c},["".concat(t,"-info > ").concat(n,",\n      ").concat(t,"-loading > ").concat(n)]:{color:l}};return[{[t]:Object.assign(Object.assign({},(0,y.Wf)(e)),{color:o,position:"fixed",top:f,width:"100%",pointerEvents:"none",zIndex:g,["".concat(t,"-move-up")]:{animationFillMode:"forwards"},["\n        ".concat(t,"-move-up-appear,\n        ").concat(t,"-move-up-enter\n      ")]:{animationName:w,animationDuration:d,animationPlayState:"paused",animationTimingFunction:u},["\n        ".concat(t,"-move-up-appear").concat(t,"-move-up-appear-active,\n        ").concat(t,"-move-up-enter").concat(t,"-move-up-enter-active\n      ")]:{animationPlayState:"running"},["".concat(t,"-move-up-leave")]:{animationName:E,animationDuration:d,animationPlayState:"paused",animationTimingFunction:u},["".concat(t,"-move-up-leave").concat(t,"-move-up-leave-active")]:{animationPlayState:"running"},"&-rtl":{direction:"rtl",span:{direction:"rtl"}}})},{[t]:{["".concat(x,"-wrapper")]:Object.assign({},S)}},{["".concat(t,"-notice-pure-panel")]:Object.assign(Object.assign({},S),{padding:0,textAlign:"start"})}]};var S=(0,x.I$)("Message",e=>[E((0,w.TS)(e,{height:150}))],e=>({zIndexPopup:e.zIndexPopupBase+b.u6+10,contentBg:e.colorBgElevated,contentPadding:"".concat((e.controlHeightLG-e.fontSize*e.lineHeight)/2,"px ").concat(e.paddingSM,"px")})),C=n(64024),Z=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let O={info:o.createElement(f.Z,null),success:o.createElement(s.Z,null),error:o.createElement(u.Z,null),warning:o.createElement(d.Z,null),loading:o.createElement(p.Z,null)},k=e=>{let{prefixCls:t,type:n,icon:r,children:a}=e;return o.createElement("div",{className:g()("".concat(t,"-custom-content"),"".concat(t,"-").concat(n))},r||O[n],o.createElement("span",null,a))};var M=n(49638),R=n(13613);function j(e){let t;let n=new Promise(n=>{t=e(()=>{n(!0)})}),r=()=>{null==t||t()};return r.then=(e,t)=>n.then(e,t),r.promise=n,r}var I=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let N=e=>{let{children:t,prefixCls:n}=e,r=(0,C.Z)(n),[a,i,c]=S(n,r);return a(o.createElement(h.JB,{classNames:{list:g()(i,c,r)}},t))},P=(e,t)=>{let{prefixCls:n,key:r}=t;return o.createElement(N,{prefixCls:n,key:r},e)},T=o.forwardRef((e,t)=>{let{top:n,prefixCls:r,getContainer:a,maxCount:i,duration:l=3,rtl:s,transitionName:u,onAllRemoved:d}=e,{getPrefixCls:f,getPopupContainer:p,message:m,direction:v}=o.useContext(c.E_),b=r||f("message"),y=o.createElement("span",{className:"".concat(b,"-close-x")},o.createElement(M.Z,{className:"".concat(b,"-close-icon")})),[x,w]=(0,h.lm)({prefixCls:b,style:()=>({left:"50%",transform:"translateX(-50%)",top:null!=n?n:8}),className:()=>g()({["".concat(b,"-rtl")]:null!=s?s:"rtl"===v}),motion:()=>({motionName:null!=u?u:"".concat(b,"-move-up")}),closable:!1,closeIcon:y,duration:l,getContainer:()=>(null==a?void 0:a())||(null==p?void 0:p())||document.body,maxCount:i,onAllRemoved:d,renderNotifications:P});return o.useImperativeHandle(t,()=>Object.assign(Object.assign({},x),{prefixCls:b,message:m})),w}),F=0;function A(e){let t=o.useRef(null);return(0,R.ln)("Message"),[o.useMemo(()=>{let e=e=>{var n;null===(n=t.current)||void 0===n||n.close(e)},n=n=>{if(!t.current){let e=()=>{};return e.then=()=>{},e}let{open:r,prefixCls:a,message:i}=t.current,c="".concat(a,"-notice"),{content:l,icon:s,type:u,key:d,className:f,style:p,onClose:m}=n,h=I(n,["content","icon","type","key","className","style","onClose"]),v=d;return null==v&&(F+=1,v="antd-message-".concat(F)),j(t=>(r(Object.assign(Object.assign({},h),{key:v,content:o.createElement(k,{prefixCls:a,type:u,icon:s},l),placement:"top",className:g()(u&&"".concat(c,"-").concat(u),f,null==i?void 0:i.className),style:Object.assign(Object.assign({},null==i?void 0:i.style),p),onClose:()=>{null==m||m(),t()}})),()=>{e(v)}))},r={open:n,destroy:n=>{var r;void 0!==n?e(n):null===(r=t.current)||void 0===r||r.destroy()}};return["info","success","warning","error","loading"].forEach(e=>{r[e]=(t,r,o)=>{let a,i,c;return a=t&&"object"==typeof t&&"content"in t?t:{content:t},"function"==typeof r?c=r:(i=r,c=o),n(Object.assign(Object.assign({onClose:c,duration:i},a),{type:e}))}}),r},[]),o.createElement(T,Object.assign({key:"message-holder"},e,{ref:t}))]}let z=null,L=e=>e(),_=[],H={};function B(){let{getContainer:e,duration:t,rtl:n,maxCount:r,top:o}=H,a=(null==e?void 0:e())||document.body;return{getContainer:()=>a,duration:t,rtl:n,maxCount:r,top:o}}let D=o.forwardRef((e,t)=>{let{messageConfig:n,sync:r}=e,{getPrefixCls:a}=(0,o.useContext)(c.E_),l=H.prefixCls||a("message"),s=(0,o.useContext)(i.J),[u,d]=A(Object.assign(Object.assign(Object.assign({},n),{prefixCls:l}),s.message));return o.useImperativeHandle(t,()=>{let e=Object.assign({},u);return Object.keys(e).forEach(t=>{e[t]=function(){return r(),u[t].apply(u,arguments)}}),{instance:e,sync:r}}),d}),W=o.forwardRef((e,t)=>{let[n,r]=o.useState(B),a=()=>{r(B)};o.useEffect(a,[]);let i=(0,l.w6)(),c=i.getRootPrefixCls(),s=i.getIconPrefixCls(),u=i.getTheme(),d=o.createElement(D,{ref:t,sync:a,messageConfig:n});return o.createElement(l.ZP,{prefixCls:c,iconPrefixCls:s,theme:u},i.holderRender?i.holderRender(d):d)});function V(){if(!z){let e=document.createDocumentFragment(),t={fragment:e};z=t,L(()=>{(0,a.s)(o.createElement(W,{ref:e=>{let{instance:n,sync:r}=e||{};Promise.resolve().then(()=>{!t.instance&&n&&(t.instance=n,t.sync=r,V())})}}),e)});return}z.instance&&(_.forEach(e=>{let{type:t,skipped:n}=e;if(!n)switch(t){case"open":L(()=>{let t=z.instance.open(Object.assign(Object.assign({},H),e.config));null==t||t.then(e.resolve),e.setCloseFn(t)});break;case"destroy":L(()=>{null==z||z.instance.destroy(e.key)});break;default:L(()=>{var n;let o=(n=z.instance)[t].apply(n,(0,r.Z)(e.args));null==o||o.then(e.resolve),e.setCloseFn(o)})}}),_=[])}let q={open:function(e){let t=j(t=>{let n;let r={type:"open",config:e,resolve:t,setCloseFn:e=>{n=e}};return _.push(r),()=>{n?L(()=>{n()}):r.skipped=!0}});return V(),t},destroy:function(e){_.push({type:"destroy",key:e}),V()},config:function(e){H=Object.assign(Object.assign({},H),e),L(()=>{var e;null===(e=null==z?void 0:z.sync)||void 0===e||e.call(z)})},useMessage:function(e){return A(e)},_InternalPanelDoNotUseOrYouWillBeFired:e=>{let{prefixCls:t,className:n,type:r,icon:a,content:i}=e,l=Z(e,["prefixCls","className","type","icon","content"]),{getPrefixCls:s}=o.useContext(c.E_),u=t||s("message"),d=(0,C.Z)(u),[f,p,m]=S(u,d);return f(o.createElement(h.qX,Object.assign({},l,{prefixCls:u,className:g()(n,p,"".concat(u,"-notice-pure-panel"),m,d),eventKey:"pure",duration:null,content:o.createElement(k,{prefixCls:u,type:r,icon:a},i)})))}};["success","info","warning","error","loading"].forEach(e=>{q[e]=function(){for(var t=arguments.length,n=Array(t),r=0;r{let r;let o={type:e,args:t,resolve:n,setCloseFn:e=>{r=e}};return _.push(o),()=>{r?L(()=>{r()}):o.skipped=!0}});return V(),n}(e,n)}});var G=q},92246:function(e,t,n){"use strict";n.d(t,{A:function(){return l},f:function(){return c}});var r=n(13823);let o=Object.assign({},r.Z.Modal),a=[],i=()=>a.reduce((e,t)=>Object.assign(Object.assign({},e),t),r.Z.Modal);function c(e){if(e){let t=Object.assign({},e);return a.push(t),o=i(),()=>{a=a.filter(e=>e!==t),o=i()}}o=Object.assign({},r.Z.Modal)}function l(){return o}},57271:function(e,t,n){"use strict";n.d(t,{ZP:function(){return er}});var r=n(2265),o=n(18404),a=n(52402),i=n(71744),c=n(13959),l=n(8900),s=n(39725),u=n(49638),d=n(54537),f=n(55726),p=n(61935),m=n(36760),g=n.n(m),h=n(49283),v=n(64024),b=n(352),y=n(62236),x=n(12918),w=n(3104),E=n(80669),S=e=>{let{componentCls:t,notificationMarginEdge:n,animationMaxHeight:r}=e,o="".concat(t,"-notice"),a=new b.E4("antNotificationFadeIn",{"0%":{transform:"translate3d(100%, 0, 0)",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",opacity:1}}),i=new b.E4("antNotificationTopFadeIn",{"0%":{top:-r,opacity:0},"100%":{top:0,opacity:1}}),c=new b.E4("antNotificationBottomFadeIn",{"0%":{bottom:e.calc(r).mul(-1).equal(),opacity:0},"100%":{bottom:0,opacity:1}}),l=new b.E4("antNotificationLeftFadeIn",{"0%":{transform:"translate3d(-100%, 0, 0)",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",opacity:1}});return{[t]:{["&".concat(t,"-top, &").concat(t,"-bottom")]:{marginInline:0,[o]:{marginInline:"auto auto"}},["&".concat(t,"-top")]:{["".concat(t,"-fade-enter").concat(t,"-fade-enter-active, ").concat(t,"-fade-appear").concat(t,"-fade-appear-active")]:{animationName:i}},["&".concat(t,"-bottom")]:{["".concat(t,"-fade-enter").concat(t,"-fade-enter-active, ").concat(t,"-fade-appear").concat(t,"-fade-appear-active")]:{animationName:c}},["&".concat(t,"-topRight, &").concat(t,"-bottomRight")]:{["".concat(t,"-fade-enter").concat(t,"-fade-enter-active, ").concat(t,"-fade-appear").concat(t,"-fade-appear-active")]:{animationName:a}},["&".concat(t,"-topLeft, &").concat(t,"-bottomLeft")]:{marginRight:{value:0,_skip_check_:!0},marginLeft:{value:n,_skip_check_:!0},[o]:{marginInlineEnd:"auto",marginInlineStart:0},["".concat(t,"-fade-enter").concat(t,"-fade-enter-active, ").concat(t,"-fade-appear").concat(t,"-fade-appear-active")]:{animationName:l}}}}};let C=["top","topLeft","topRight","bottom","bottomLeft","bottomRight"],Z={topLeft:"left",topRight:"right",bottomLeft:"left",bottomRight:"right",top:"left",bottom:"left"},O=(e,t)=>{let{componentCls:n}=e;return{["".concat(n,"-").concat(t)]:{["&".concat(n,"-stack > ").concat(n,"-notice-wrapper")]:{[t.startsWith("top")?"top":"bottom"]:0,[Z[t]]:{value:0,_skip_check_:!0}}}}},k=e=>{let t={};for(let n=1;n ".concat(e.componentCls,"-notice")]:{opacity:0,transition:"opacity ".concat(e.motionDurationMid)}};return Object.assign({["&:not(:nth-last-child(-n+".concat(e.notificationStackLayer,"))")]:{opacity:0,overflow:"hidden",color:"transparent",pointerEvents:"none"}},t)},M=e=>{let t={};for(let n=1;n{let{componentCls:t}=e;return Object.assign({["".concat(t,"-stack")]:{["& > ".concat(t,"-notice-wrapper")]:Object.assign({transition:"all ".concat(e.motionDurationSlow,", backdrop-filter 0s"),position:"absolute"},k(e))},["".concat(t,"-stack:not(").concat(t,"-stack-expanded)")]:{["& > ".concat(t,"-notice-wrapper")]:Object.assign({},M(e))},["".concat(t,"-stack").concat(t,"-stack-expanded")]:{["& > ".concat(t,"-notice-wrapper")]:{"&:not(:nth-last-child(-n + 1))":{opacity:1,overflow:"unset",color:"inherit",pointerEvents:"auto",["& > ".concat(e.componentCls,"-notice")]:{opacity:1}},"&:after":{content:'""',position:"absolute",height:e.margin,width:"100%",insetInline:0,bottom:e.calc(e.margin).mul(-1).equal(),background:"transparent",pointerEvents:"auto"}}}},C.map(t=>O(e,t)).reduce((e,t)=>Object.assign(Object.assign({},e),t),{}))};let j=e=>{let{iconCls:t,componentCls:n,boxShadow:r,fontSizeLG:o,notificationMarginBottom:a,borderRadiusLG:i,colorSuccess:c,colorInfo:l,colorWarning:s,colorError:u,colorTextHeading:d,notificationBg:f,notificationPadding:p,notificationMarginEdge:m,fontSize:g,lineHeight:h,width:v,notificationIconSize:y,colorText:x}=e,w="".concat(n,"-notice");return{position:"relative",marginBottom:a,marginInlineStart:"auto",background:f,borderRadius:i,boxShadow:r,[w]:{padding:p,width:v,maxWidth:"calc(100vw - ".concat((0,b.bf)(e.calc(m).mul(2).equal()),")"),overflow:"hidden",lineHeight:h,wordWrap:"break-word"},["".concat(n,"-close-icon")]:{fontSize:g,cursor:"pointer"},["".concat(w,"-message")]:{marginBottom:e.marginXS,color:d,fontSize:o,lineHeight:e.lineHeightLG},["".concat(w,"-description")]:{fontSize:g,color:x},["".concat(w,"-closable ").concat(w,"-message")]:{paddingInlineEnd:e.paddingLG},["".concat(w,"-with-icon ").concat(w,"-message")]:{marginBottom:e.marginXS,marginInlineStart:e.calc(e.marginSM).add(y).equal(),fontSize:o},["".concat(w,"-with-icon ").concat(w,"-description")]:{marginInlineStart:e.calc(e.marginSM).add(y).equal(),fontSize:g},["".concat(w,"-icon")]:{position:"absolute",fontSize:y,lineHeight:1,["&-success".concat(t)]:{color:c},["&-info".concat(t)]:{color:l},["&-warning".concat(t)]:{color:s},["&-error".concat(t)]:{color:u}},["".concat(w,"-close")]:{position:"absolute",top:e.notificationPaddingVertical,insetInlineEnd:e.notificationPaddingHorizontal,color:e.colorIcon,outline:"none",width:e.notificationCloseButtonSize,height:e.notificationCloseButtonSize,borderRadius:e.borderRadiusSM,transition:"background-color ".concat(e.motionDurationMid,", color ").concat(e.motionDurationMid),display:"flex",alignItems:"center",justifyContent:"center","&:hover":{color:e.colorIconHover,backgroundColor:e.closeBtnHoverBg}},["".concat(w,"-btn")]:{float:"right",marginTop:e.marginSM}}},I=e=>{let{componentCls:t,notificationMarginBottom:n,notificationMarginEdge:r,motionDurationMid:o,motionEaseInOut:a}=e,i="".concat(t,"-notice"),c=new b.E4("antNotificationFadeOut",{"0%":{maxHeight:e.animationMaxHeight,marginBottom:n},"100%":{maxHeight:0,marginBottom:0,paddingTop:0,paddingBottom:0,opacity:0}});return[{[t]:Object.assign(Object.assign({},(0,x.Wf)(e)),{position:"fixed",zIndex:e.zIndexPopup,marginRight:{value:r,_skip_check_:!0},["".concat(t,"-hook-holder")]:{position:"relative"},["".concat(t,"-fade-appear-prepare")]:{opacity:"0 !important"},["".concat(t,"-fade-enter, ").concat(t,"-fade-appear")]:{animationDuration:e.motionDurationMid,animationTimingFunction:a,animationFillMode:"both",opacity:0,animationPlayState:"paused"},["".concat(t,"-fade-leave")]:{animationTimingFunction:a,animationFillMode:"both",animationDuration:o,animationPlayState:"paused"},["".concat(t,"-fade-enter").concat(t,"-fade-enter-active, ").concat(t,"-fade-appear").concat(t,"-fade-appear-active")]:{animationPlayState:"running"},["".concat(t,"-fade-leave").concat(t,"-fade-leave-active")]:{animationName:c,animationPlayState:"running"},"&-rtl":{direction:"rtl",["".concat(i,"-btn")]:{float:"left"}}})},{[t]:{["".concat(i,"-wrapper")]:Object.assign({},j(e))}}]},N=e=>({zIndexPopup:e.zIndexPopupBase+y.u6+50,width:384,closeBtnHoverBg:e.wireframe?"transparent":e.colorFillContent}),P=e=>{let t=e.paddingMD,n=e.paddingLG;return(0,w.TS)(e,{notificationBg:e.colorBgElevated,notificationPaddingVertical:t,notificationPaddingHorizontal:n,notificationIconSize:e.calc(e.fontSizeLG).mul(e.lineHeightLG).equal(),notificationCloseButtonSize:e.calc(e.controlHeightLG).mul(.55).equal(),notificationMarginBottom:e.margin,notificationPadding:"".concat((0,b.bf)(e.paddingMD)," ").concat((0,b.bf)(e.paddingContentHorizontalLG)),notificationMarginEdge:e.marginLG,animationMaxHeight:150,notificationStackLayer:3})};var T=(0,E.I$)("Notification",e=>{let t=P(e);return[I(t),S(t),R(t)]},N),F=(0,E.bk)(["Notification","PurePanel"],e=>{let t="".concat(e.componentCls,"-notice"),n=P(e);return{["".concat(t,"-pure-panel")]:Object.assign(Object.assign({},j(n)),{width:n.width,maxWidth:"calc(100vw - ".concat((0,b.bf)(e.calc(n.notificationMarginEdge).mul(2).equal()),")"),margin:0})}},N),A=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function z(e,t){return null===t||!1===t?null:t||r.createElement("span",{className:"".concat(e,"-close-x")},r.createElement(u.Z,{className:"".concat(e,"-close-icon")}))}f.Z,l.Z,s.Z,d.Z,p.Z;let L={success:l.Z,info:f.Z,error:s.Z,warning:d.Z},_=e=>{let{prefixCls:t,icon:n,type:o,message:a,description:i,btn:c,role:l="alert"}=e,s=null;return n?s=r.createElement("span",{className:"".concat(t,"-icon")},n):o&&(s=r.createElement(L[o]||null,{className:g()("".concat(t,"-icon"),"".concat(t,"-icon-").concat(o))})),r.createElement("div",{className:g()({["".concat(t,"-with-icon")]:s}),role:l},s,r.createElement("div",{className:"".concat(t,"-message")},a),r.createElement("div",{className:"".concat(t,"-description")},i),c&&r.createElement("div",{className:"".concat(t,"-btn")},c))};var H=n(13613),B=n(29961),D=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let W=e=>{let{children:t,prefixCls:n}=e,o=(0,v.Z)(n),[a,i,c]=T(n,o);return a(r.createElement(h.JB,{classNames:{list:g()(i,c,o)}},t))},V=(e,t)=>{let{prefixCls:n,key:o}=t;return r.createElement(W,{prefixCls:n,key:o},e)},q=r.forwardRef((e,t)=>{let{top:n,bottom:o,prefixCls:a,getContainer:c,maxCount:l,rtl:s,onAllRemoved:u,stack:d}=e,{getPrefixCls:f,getPopupContainer:p,notification:m,direction:v}=(0,r.useContext)(i.E_),[,b]=(0,B.ZP)(),y=a||f("notification"),[x,w]=(0,h.lm)({prefixCls:y,style:e=>(function(e,t,n){let r;switch(e){case"top":r={left:"50%",transform:"translateX(-50%)",right:"auto",top:t,bottom:"auto"};break;case"topLeft":r={left:0,top:t,bottom:"auto"};break;case"topRight":r={right:0,top:t,bottom:"auto"};break;case"bottom":r={left:"50%",transform:"translateX(-50%)",right:"auto",top:"auto",bottom:n};break;case"bottomLeft":r={left:0,top:"auto",bottom:n};break;default:r={right:0,top:"auto",bottom:n}}return r})(e,null!=n?n:24,null!=o?o:24),className:()=>g()({["".concat(y,"-rtl")]:null!=s?s:"rtl"===v}),motion:()=>({motionName:"".concat(y,"-fade")}),closable:!0,closeIcon:z(y),duration:4.5,getContainer:()=>(null==c?void 0:c())||(null==p?void 0:p())||document.body,maxCount:l,onAllRemoved:u,renderNotifications:V,stack:!1!==d&&{threshold:"object"==typeof d?null==d?void 0:d.threshold:void 0,offset:8,gap:b.margin}});return r.useImperativeHandle(t,()=>Object.assign(Object.assign({},x),{prefixCls:y,notification:m})),w});function G(e){let t=r.useRef(null);return(0,H.ln)("Notification"),[r.useMemo(()=>{let n=n=>{var o;if(!t.current)return;let{open:a,prefixCls:i,notification:c}=t.current,l="".concat(i,"-notice"),{message:s,description:u,icon:d,type:f,btn:p,className:m,style:h,role:v="alert",closeIcon:b}=n,y=D(n,["message","description","icon","type","btn","className","style","role","closeIcon"]),x=z(l,b);return a(Object.assign(Object.assign({placement:null!==(o=null==e?void 0:e.placement)&&void 0!==o?o:"topRight"},y),{content:r.createElement(_,{prefixCls:l,icon:d,type:f,message:s,description:u,btn:p,role:v}),className:g()(f&&"".concat(l,"-").concat(f),m,null==c?void 0:c.className),style:Object.assign(Object.assign({},null==c?void 0:c.style),h),closeIcon:x,closable:!!x}))},o={open:n,destroy:e=>{var n,r;void 0!==e?null===(n=t.current)||void 0===n||n.close(e):null===(r=t.current)||void 0===r||r.destroy()}};return["success","info","warning","error"].forEach(e=>{o[e]=t=>n(Object.assign(Object.assign({},t),{type:e}))}),o},[]),r.createElement(q,Object.assign({key:"notification-holder"},e,{ref:t}))]}let X=null,U=e=>e(),K=[],$={};function Y(){let{getContainer:e,rtl:t,maxCount:n,top:r,bottom:o}=$,a=(null==e?void 0:e())||document.body;return{getContainer:()=>a,rtl:t,maxCount:n,top:r,bottom:o}}let Q=r.forwardRef((e,t)=>{let{notificationConfig:n,sync:o}=e,{getPrefixCls:c}=(0,r.useContext)(i.E_),l=$.prefixCls||c("notification"),s=(0,r.useContext)(a.J),[u,d]=G(Object.assign(Object.assign(Object.assign({},n),{prefixCls:l}),s.notification));return r.useEffect(o,[]),r.useImperativeHandle(t,()=>{let e=Object.assign({},u);return Object.keys(e).forEach(t=>{e[t]=function(){return o(),u[t].apply(u,arguments)}}),{instance:e,sync:o}}),d}),J=r.forwardRef((e,t)=>{let[n,o]=r.useState(Y),a=()=>{o(Y)};r.useEffect(a,[]);let i=(0,c.w6)(),l=i.getRootPrefixCls(),s=i.getIconPrefixCls(),u=i.getTheme(),d=r.createElement(Q,{ref:t,sync:a,notificationConfig:n});return r.createElement(c.ZP,{prefixCls:l,iconPrefixCls:s,theme:u},i.holderRender?i.holderRender(d):d)});function ee(){if(!X){let e=document.createDocumentFragment(),t={fragment:e};X=t,U(()=>{(0,o.s)(r.createElement(J,{ref:e=>{let{instance:n,sync:r}=e||{};Promise.resolve().then(()=>{!t.instance&&n&&(t.instance=n,t.sync=r,ee())})}}),e)});return}X.instance&&(K.forEach(e=>{switch(e.type){case"open":U(()=>{X.instance.open(Object.assign(Object.assign({},$),e.config))});break;case"destroy":U(()=>{null==X||X.instance.destroy(e.key)})}}),K=[])}function et(e){(0,c.w6)(),K.push({type:"open",config:e}),ee()}let en={open:et,destroy:function(e){K.push({type:"destroy",key:e}),ee()},config:function(e){$=Object.assign(Object.assign({},$),e),U(()=>{var e;null===(e=null==X?void 0:X.sync)||void 0===e||e.call(X)})},useNotification:function(e){return G(e)},_InternalPanelDoNotUseOrYouWillBeFired:e=>{let{prefixCls:t,className:n,icon:o,type:a,message:c,description:l,btn:s,closable:u=!0,closeIcon:d,className:f}=e,p=A(e,["prefixCls","className","icon","type","message","description","btn","closable","closeIcon","className"]),{getPrefixCls:m}=r.useContext(i.E_),b=t||m("notification"),y="".concat(b,"-notice"),x=(0,v.Z)(b),[w,E,S]=T(b,x);return w(r.createElement("div",{className:g()("".concat(y,"-pure-panel"),E,n,S,x)},r.createElement(F,{prefixCls:b}),r.createElement(h.qX,Object.assign({},p,{prefixCls:b,eventKey:"pure",duration:null,closable:u,className:g()({notificationClassName:f}),closeIcon:z(b,d),content:r.createElement(_,{prefixCls:y,icon:o,type:a,message:c,description:l,btn:s})}))))}};["success","info","warning","error"].forEach(e=>{en[e]=t=>et(Object.assign(Object.assign({},t),{type:e}))});var er=en},52787:function(e,t,n){"use strict";n.d(t,{default:function(){return tt}});var r=n(2265),o=n(36760),a=n.n(o),i=n(1119),c=n(83145),l=n(11993),s=n(31686),u=n(26365),d=n(6989),f=n(41154),p=n(50506),m=n(32559),g=n(27380),h=n(79267),v=n(95814),b=n(28791),y=function(e){var t=e.className,n=e.customizeIcon,o=e.customizeIconProps,i=e.children,c=e.onMouseDown,l=e.onClick,s="function"==typeof n?n(o):n;return r.createElement("span",{className:t,onMouseDown:function(e){e.preventDefault(),null==c||c(e)},style:{userSelect:"none",WebkitUserSelect:"none"},unselectable:"on",onClick:l,"aria-hidden":!0},void 0!==s?s:r.createElement("span",{className:a()(t.split(/\s+/).map(function(e){return"".concat(e,"-icon")}))},i))},x=function(e,t,n,o,a){var i=arguments.length>5&&void 0!==arguments[5]&&arguments[5],c=arguments.length>6?arguments[6]:void 0,l=arguments.length>7?arguments[7]:void 0,s=r.useMemo(function(){return"object"===(0,f.Z)(o)?o.clearIcon:a||void 0},[o,a]);return{allowClear:r.useMemo(function(){return!i&&!!o&&(!!n.length||!!c)&&!("combobox"===l&&""===c)},[o,i,n.length,c,l]),clearIcon:r.createElement(y,{className:"".concat(e,"-clear"),onMouseDown:t,customizeIcon:s},"\xd7")}},w=r.createContext(null);function E(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:250,t=r.useRef(null),n=r.useRef(null);return r.useEffect(function(){return function(){window.clearTimeout(n.current)}},[]),[function(){return t.current},function(r){(r||null===t.current)&&(t.current=r),window.clearTimeout(n.current),n.current=window.setTimeout(function(){t.current=null},e)}]}var S=n(18242),C=n(1699),Z=r.forwardRef(function(e,t){var n,o=e.prefixCls,i=e.id,c=e.inputElement,l=e.disabled,u=e.tabIndex,d=e.autoFocus,f=e.autoComplete,p=e.editable,g=e.activeDescendantId,h=e.value,v=e.maxLength,y=e.onKeyDown,x=e.onMouseDown,w=e.onChange,E=e.onPaste,S=e.onCompositionStart,C=e.onCompositionEnd,Z=e.open,O=e.attrs,k=c||r.createElement("input",null),M=k,R=M.ref,j=M.props,I=j.onKeyDown,N=j.onChange,P=j.onMouseDown,T=j.onCompositionStart,F=j.onCompositionEnd,A=j.style;return(0,m.Kp)(!("maxLength"in k.props),"Passing 'maxLength' to input element directly may not work because input in BaseSelect is controlled."),k=r.cloneElement(k,(0,s.Z)((0,s.Z)((0,s.Z)({type:"search"},j),{},{id:i,ref:(0,b.sQ)(t,R),disabled:l,tabIndex:u,autoComplete:f||"off",autoFocus:d,className:a()("".concat(o,"-selection-search-input"),null===(n=k)||void 0===n||null===(n=n.props)||void 0===n?void 0:n.className),role:"combobox","aria-expanded":Z||!1,"aria-haspopup":"listbox","aria-owns":"".concat(i,"_list"),"aria-autocomplete":"list","aria-controls":"".concat(i,"_list"),"aria-activedescendant":Z?g:void 0},O),{},{value:p?h:"",maxLength:v,readOnly:!p,unselectable:p?null:"on",style:(0,s.Z)((0,s.Z)({},A),{},{opacity:p?null:0}),onKeyDown:function(e){y(e),I&&I(e)},onMouseDown:function(e){x(e),P&&P(e)},onChange:function(e){w(e),N&&N(e)},onCompositionStart:function(e){S(e),T&&T(e)},onCompositionEnd:function(e){C(e),F&&F(e)},onPaste:E}))});function O(e){return Array.isArray(e)?e:void 0!==e?[e]:[]}var k="undefined"!=typeof window&&window.document&&window.document.documentElement;function M(e){return["string","number"].includes((0,f.Z)(e))}function R(e){var t=void 0;return e&&(M(e.title)?t=e.title.toString():M(e.label)&&(t=e.label.toString())),t}function j(e){var t;return null!==(t=e.key)&&void 0!==t?t:e.value}var I=function(e){e.preventDefault(),e.stopPropagation()},N=function(e){var t,n,o=e.id,i=e.prefixCls,c=e.values,s=e.open,d=e.searchValue,f=e.autoClearSearchValue,p=e.inputRef,m=e.placeholder,g=e.disabled,h=e.mode,v=e.showSearch,b=e.autoFocus,x=e.autoComplete,w=e.activeDescendantId,E=e.tabIndex,O=e.removeIcon,M=e.maxTagCount,N=e.maxTagTextLength,P=e.maxTagPlaceholder,T=void 0===P?function(e){return"+ ".concat(e.length," ...")}:P,F=e.tagRender,A=e.onToggleOpen,z=e.onRemove,L=e.onInputChange,_=e.onInputPaste,H=e.onInputKeyDown,B=e.onInputMouseDown,D=e.onInputCompositionStart,W=e.onInputCompositionEnd,V=r.useRef(null),q=(0,r.useState)(0),G=(0,u.Z)(q,2),X=G[0],U=G[1],K=(0,r.useState)(!1),$=(0,u.Z)(K,2),Y=$[0],Q=$[1],J="".concat(i,"-selection"),ee=s||"multiple"===h&&!1===f||"tags"===h?d:"",et="tags"===h||"multiple"===h&&!1===f||v&&(s||Y);t=function(){U(V.current.scrollWidth)},n=[ee],k?r.useLayoutEffect(t,n):r.useEffect(t,n);var en=function(e,t,n,o,i){return r.createElement("span",{title:R(e),className:a()("".concat(J,"-item"),(0,l.Z)({},"".concat(J,"-item-disabled"),n))},r.createElement("span",{className:"".concat(J,"-item-content")},t),o&&r.createElement(y,{className:"".concat(J,"-item-remove"),onMouseDown:I,onClick:i,customizeIcon:O},"\xd7"))},er=r.createElement("div",{className:"".concat(J,"-search"),style:{width:X},onFocus:function(){Q(!0)},onBlur:function(){Q(!1)}},r.createElement(Z,{ref:p,open:s,prefixCls:i,id:o,inputElement:null,disabled:g,autoFocus:b,autoComplete:x,editable:et,activeDescendantId:w,value:ee,onKeyDown:H,onMouseDown:B,onChange:L,onPaste:_,onCompositionStart:D,onCompositionEnd:W,tabIndex:E,attrs:(0,S.Z)(e,!0)}),r.createElement("span",{ref:V,className:"".concat(J,"-search-mirror"),"aria-hidden":!0},ee,"\xa0")),eo=r.createElement(C.Z,{prefixCls:"".concat(J,"-overflow"),data:c,renderItem:function(e){var t,n=e.disabled,o=e.label,a=e.value,i=!g&&!n,c=o;if("number"==typeof N&&("string"==typeof o||"number"==typeof o)){var l=String(c);l.length>N&&(c="".concat(l.slice(0,N),"..."))}var u=function(t){t&&t.stopPropagation(),z(e)};return"function"==typeof F?(t=c,r.createElement("span",{onMouseDown:function(e){I(e),A(!s)}},F({label:t,value:a,disabled:n,closable:i,onClose:u}))):en(e,c,n,i,u)},renderRest:function(e){var t="function"==typeof T?T(e):T;return en({title:t},t,!1)},suffix:er,itemKey:j,maxCount:M});return r.createElement(r.Fragment,null,eo,!c.length&&!ee&&r.createElement("span",{className:"".concat(J,"-placeholder")},m))},P=function(e){var t=e.inputElement,n=e.prefixCls,o=e.id,a=e.inputRef,i=e.disabled,c=e.autoFocus,l=e.autoComplete,s=e.activeDescendantId,d=e.mode,f=e.open,p=e.values,m=e.placeholder,g=e.tabIndex,h=e.showSearch,v=e.searchValue,b=e.activeValue,y=e.maxLength,x=e.onInputKeyDown,w=e.onInputMouseDown,E=e.onInputChange,C=e.onInputPaste,O=e.onInputCompositionStart,k=e.onInputCompositionEnd,M=e.title,j=r.useState(!1),I=(0,u.Z)(j,2),N=I[0],P=I[1],T="combobox"===d,F=T||h,A=p[0],z=v||"";T&&b&&!N&&(z=b),r.useEffect(function(){T&&P(!1)},[T,b]);var L=("combobox"===d||!!f||!!h)&&!!z,_=void 0===M?R(A):M,H=r.useMemo(function(){return A?null:r.createElement("span",{className:"".concat(n,"-selection-placeholder"),style:L?{visibility:"hidden"}:void 0},m)},[A,L,m,n]);return r.createElement(r.Fragment,null,r.createElement("span",{className:"".concat(n,"-selection-search")},r.createElement(Z,{ref:a,prefixCls:n,id:o,open:f,inputElement:t,disabled:i,autoFocus:c,autoComplete:l,editable:F,activeDescendantId:s,value:z,onKeyDown:x,onMouseDown:w,onChange:function(e){P(!0),E(e)},onPaste:C,onCompositionStart:O,onCompositionEnd:k,tabIndex:g,attrs:(0,S.Z)(e,!0),maxLength:T?y:void 0})),!T&&A?r.createElement("span",{className:"".concat(n,"-selection-item"),title:_,style:L?{visibility:"hidden"}:void 0},A.label):null,H)},T=r.forwardRef(function(e,t){var n=(0,r.useRef)(null),o=(0,r.useRef)(!1),a=e.prefixCls,c=e.open,l=e.mode,s=e.showSearch,d=e.tokenWithEnter,f=e.autoClearSearchValue,p=e.onSearch,m=e.onSearchSubmit,g=e.onToggleOpen,h=e.onInputKeyDown,b=e.domRef;r.useImperativeHandle(t,function(){return{focus:function(){n.current.focus()},blur:function(){n.current.blur()}}});var y=E(0),x=(0,u.Z)(y,2),w=x[0],S=x[1],C=(0,r.useRef)(null),Z=function(e){!1!==p(e,!0,o.current)&&g(!0)},O={inputRef:n,onInputKeyDown:function(e){var t=e.which;(t===v.Z.UP||t===v.Z.DOWN)&&e.preventDefault(),h&&h(e),t!==v.Z.ENTER||"tags"!==l||o.current||c||null==m||m(e.target.value),[v.Z.ESC,v.Z.SHIFT,v.Z.BACKSPACE,v.Z.TAB,v.Z.WIN_KEY,v.Z.ALT,v.Z.META,v.Z.WIN_KEY_RIGHT,v.Z.CTRL,v.Z.SEMICOLON,v.Z.EQUALS,v.Z.CAPS_LOCK,v.Z.CONTEXT_MENU,v.Z.F1,v.Z.F2,v.Z.F3,v.Z.F4,v.Z.F5,v.Z.F6,v.Z.F7,v.Z.F8,v.Z.F9,v.Z.F10,v.Z.F11,v.Z.F12].includes(t)||g(!0)},onInputMouseDown:function(){S(!0)},onInputChange:function(e){var t=e.target.value;if(d&&C.current&&/[\r\n]/.test(C.current)){var n=C.current.replace(/[\r\n]+$/,"").replace(/\r\n/g," ").replace(/[\r\n]/g," ");t=t.replace(n,C.current)}C.current=null,Z(t)},onInputPaste:function(e){var t=e.clipboardData,n=null==t?void 0:t.getData("text");C.current=n||""},onInputCompositionStart:function(){o.current=!0},onInputCompositionEnd:function(e){o.current=!1,"combobox"!==l&&Z(e.target.value)}},k="multiple"===l||"tags"===l?r.createElement(N,(0,i.Z)({},e,O)):r.createElement(P,(0,i.Z)({},e,O));return r.createElement("div",{ref:b,className:"".concat(a,"-selector"),onClick:function(e){e.target!==n.current&&(void 0!==document.body.style.msTouchAction?setTimeout(function(){n.current.focus()}):n.current.focus())},onMouseDown:function(e){var t=w();e.target===n.current||t||"combobox"===l||e.preventDefault(),("combobox"===l||s&&t)&&c||(c&&!1!==f&&p("",!0,!1),g())}},k)}),F=n(97821),A=["prefixCls","disabled","visible","children","popupElement","animation","transitionName","dropdownStyle","dropdownClassName","direction","placement","builtinPlacements","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","getPopupContainer","empty","getTriggerDOMNode","onPopupVisibleChange","onPopupMouseEnter"],z=function(e){var t=!0===e?0:1;return{bottomLeft:{points:["tl","bl"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},bottomRight:{points:["tr","br"],offset:[0,4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topLeft:{points:["bl","tl"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"},topRight:{points:["br","tr"],offset:[0,-4],overflow:{adjustX:t,adjustY:1},htmlRegion:"scroll"}}},L=r.forwardRef(function(e,t){var n=e.prefixCls,o=(e.disabled,e.visible),c=e.children,u=e.popupElement,f=e.animation,p=e.transitionName,m=e.dropdownStyle,g=e.dropdownClassName,h=e.direction,v=e.placement,b=e.builtinPlacements,y=e.dropdownMatchSelectWidth,x=e.dropdownRender,w=e.dropdownAlign,E=e.getPopupContainer,S=e.empty,C=e.getTriggerDOMNode,Z=e.onPopupVisibleChange,O=e.onPopupMouseEnter,k=(0,d.Z)(e,A),M="".concat(n,"-dropdown"),R=u;x&&(R=x(u));var j=r.useMemo(function(){return b||z(y)},[b,y]),I=f?"".concat(M,"-").concat(f):p,N="number"==typeof y,P=r.useMemo(function(){return N?null:!1===y?"minWidth":"width"},[y,N]),T=m;N&&(T=(0,s.Z)((0,s.Z)({},T),{},{width:y}));var L=r.useRef(null);return r.useImperativeHandle(t,function(){return{getPopupElement:function(){return L.current}}}),r.createElement(F.Z,(0,i.Z)({},k,{showAction:Z?["click"]:[],hideAction:Z?["click"]:[],popupPlacement:v||("rtl"===(void 0===h?"ltr":h)?"bottomRight":"bottomLeft"),builtinPlacements:j,prefixCls:M,popupTransitionName:I,popup:r.createElement("div",{ref:L,onMouseEnter:O},R),stretch:P,popupAlign:w,popupVisible:o,getPopupContainer:E,popupClassName:a()(g,(0,l.Z)({},"".concat(M,"-empty"),S)),popupStyle:T,getTriggerDOMNode:C,onPopupVisibleChange:Z}),c)}),_=n(87099);function H(e,t){var n,r=e.key;return("value"in e&&(n=e.value),null!=r)?r:void 0!==n?n:"rc-index-key-".concat(t)}function B(e,t){var n=e||{},r=n.label,o=n.value,a=n.options,i=n.groupLabel,c=r||(t?"children":"label");return{label:c,value:o||"value",options:a||"options",groupLabel:i||c}}function D(e){var t=(0,s.Z)({},e);return"props"in t||Object.defineProperty(t,"props",{get:function(){return(0,m.ZP)(!1,"Return type is option instead of Option instance. Please read value directly instead of reading from `props`."),t}}),t}var W=function(e,t,n){if(!t||!t.length)return null;var r=!1,o=function e(t,n){var o=(0,_.Z)(n),a=o[0],i=o.slice(1);if(!a)return[t];var l=t.split(a);return r=r||l.length>1,l.reduce(function(t,n){return[].concat((0,c.Z)(t),(0,c.Z)(e(n,i)))},[]).filter(Boolean)}(e,t);return r?void 0!==n?o.slice(0,n):o:null},V=r.createContext(null),q=["id","prefixCls","className","showSearch","tagRender","direction","omitDomProps","displayValues","onDisplayValuesChange","emptyOptions","notFoundContent","onClear","mode","disabled","loading","getInputElement","getRawInputElement","open","defaultOpen","onDropdownVisibleChange","activeValue","onActiveValueChange","activeDescendantId","searchValue","autoClearSearchValue","onSearch","onSearchSplit","tokenSeparators","allowClear","suffixIcon","clearIcon","OptionList","animation","transitionName","dropdownStyle","dropdownClassName","dropdownMatchSelectWidth","dropdownRender","dropdownAlign","placement","builtinPlacements","getPopupContainer","showAction","onFocus","onBlur","onKeyUp","onKeyDown","onMouseDown"],G=["value","onChange","removeIcon","placeholder","autoFocus","maxTagCount","maxTagTextLength","maxTagPlaceholder","choiceTransitionName","onInputKeyDown","onPopupScroll","tabIndex"],X=function(e){return"tags"===e||"multiple"===e},U=r.forwardRef(function(e,t){var n,o,m,S,C,Z,O,k,M=e.id,R=e.prefixCls,j=e.className,I=e.showSearch,N=e.tagRender,P=e.direction,F=e.omitDomProps,A=e.displayValues,z=e.onDisplayValuesChange,_=e.emptyOptions,H=e.notFoundContent,B=void 0===H?"Not Found":H,D=e.onClear,U=e.mode,K=e.disabled,$=e.loading,Y=e.getInputElement,Q=e.getRawInputElement,J=e.open,ee=e.defaultOpen,et=e.onDropdownVisibleChange,en=e.activeValue,er=e.onActiveValueChange,eo=e.activeDescendantId,ea=e.searchValue,ei=e.autoClearSearchValue,ec=e.onSearch,el=e.onSearchSplit,es=e.tokenSeparators,eu=e.allowClear,ed=e.suffixIcon,ef=e.clearIcon,ep=e.OptionList,em=e.animation,eg=e.transitionName,eh=e.dropdownStyle,ev=e.dropdownClassName,eb=e.dropdownMatchSelectWidth,ey=e.dropdownRender,ex=e.dropdownAlign,ew=e.placement,eE=e.builtinPlacements,eS=e.getPopupContainer,eC=e.showAction,eZ=void 0===eC?[]:eC,eO=e.onFocus,ek=e.onBlur,eM=e.onKeyUp,eR=e.onKeyDown,ej=e.onMouseDown,eI=(0,d.Z)(e,q),eN=X(U),eP=(void 0!==I?I:eN)||"combobox"===U,eT=(0,s.Z)({},eI);G.forEach(function(e){delete eT[e]}),null==F||F.forEach(function(e){delete eT[e]});var eF=r.useState(!1),eA=(0,u.Z)(eF,2),ez=eA[0],eL=eA[1];r.useEffect(function(){eL((0,h.Z)())},[]);var e_=r.useRef(null),eH=r.useRef(null),eB=r.useRef(null),eD=r.useRef(null),eW=r.useRef(null),eV=r.useRef(!1),eq=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:10,t=r.useState(!1),n=(0,u.Z)(t,2),o=n[0],a=n[1],i=r.useRef(null),c=function(){window.clearTimeout(i.current)};return r.useEffect(function(){return c},[]),[o,function(t,n){c(),i.current=window.setTimeout(function(){a(t),n&&n()},e)},c]}(),eG=(0,u.Z)(eq,3),eX=eG[0],eU=eG[1],eK=eG[2];r.useImperativeHandle(t,function(){var e,t;return{focus:null===(e=eD.current)||void 0===e?void 0:e.focus,blur:null===(t=eD.current)||void 0===t?void 0:t.blur,scrollTo:function(e){var t;return null===(t=eW.current)||void 0===t?void 0:t.scrollTo(e)}}});var e$=r.useMemo(function(){if("combobox"!==U)return ea;var e,t=null===(e=A[0])||void 0===e?void 0:e.value;return"string"==typeof t||"number"==typeof t?String(t):""},[ea,U,A]),eY="combobox"===U&&"function"==typeof Y&&Y()||null,eQ="function"==typeof Q&&Q(),eJ=(0,b.x1)(eH,null==eQ||null===(S=eQ.props)||void 0===S?void 0:S.ref),e0=r.useState(!1),e1=(0,u.Z)(e0,2),e2=e1[0],e6=e1[1];(0,g.Z)(function(){e6(!0)},[]);var e5=(0,p.Z)(!1,{defaultValue:ee,value:J}),e4=(0,u.Z)(e5,2),e3=e4[0],e8=e4[1],e9=!!e2&&e3,e7=!B&&_;(K||e7&&e9&&"combobox"===U)&&(e9=!1);var te=!e7&&e9,tt=r.useCallback(function(e){var t=void 0!==e?e:!e9;K||(e8(t),e9!==t&&(null==et||et(t)))},[K,e9,e8,et]),tn=r.useMemo(function(){return(es||[]).some(function(e){return["\n","\r\n"].includes(e)})},[es]),tr=r.useContext(V)||{},to=tr.maxCount,ta=tr.rawValues,ti=function(e,t,n){if(!((null==ta?void 0:ta.size)>=to)){var r=!0,o=e;null==er||er(null);var a=W(e,es,to&&to-ta.size),i=n?null:a;return"combobox"!==U&&i&&(o="",null==el||el(i),tt(!1),r=!1),ec&&e$!==o&&ec(o,{source:t?"typing":"effect"}),r}};r.useEffect(function(){e9||eN||"combobox"===U||ti("",!1,!1)},[e9]),r.useEffect(function(){e3&&K&&e8(!1),K&&!eV.current&&eU(!1)},[K]);var tc=E(),tl=(0,u.Z)(tc,2),ts=tl[0],tu=tl[1],td=r.useRef(!1),tf=[];r.useEffect(function(){return function(){tf.forEach(function(e){return clearTimeout(e)}),tf.splice(0,tf.length)}},[]);var tp=r.useState({}),tm=(0,u.Z)(tp,2)[1];eQ&&(Z=function(e){tt(e)}),n=function(){var e;return[e_.current,null===(e=eB.current)||void 0===e?void 0:e.getPopupElement()]},o=!!eQ,(m=r.useRef(null)).current={open:te,triggerOpen:tt,customizedTrigger:o},r.useEffect(function(){function e(e){if(null===(t=m.current)||void 0===t||!t.customizedTrigger){var t,r=e.target;r.shadowRoot&&e.composed&&(r=e.composedPath()[0]||r),m.current.open&&n().filter(function(e){return e}).every(function(e){return!e.contains(r)&&e!==r})&&m.current.triggerOpen(!1)}}return window.addEventListener("mousedown",e),function(){return window.removeEventListener("mousedown",e)}},[]);var tg=r.useMemo(function(){return(0,s.Z)((0,s.Z)({},e),{},{notFoundContent:B,open:e9,triggerOpen:te,id:M,showSearch:eP,multiple:eN,toggleOpen:tt})},[e,B,te,e9,M,eP,eN,tt]),th=!!ed||$;th&&(O=r.createElement(y,{className:a()("".concat(R,"-arrow"),(0,l.Z)({},"".concat(R,"-arrow-loading"),$)),customizeIcon:ed,customizeIconProps:{loading:$,searchValue:e$,open:e9,focused:eX,showSearch:eP}}));var tv=x(R,function(){var e;null==D||D(),null===(e=eD.current)||void 0===e||e.focus(),z([],{type:"clear",values:A}),ti("",!1,!1)},A,eu,ef,K,e$,U),tb=tv.allowClear,ty=tv.clearIcon,tx=r.createElement(ep,{ref:eW}),tw=a()(R,j,(C={},(0,l.Z)(C,"".concat(R,"-focused"),eX),(0,l.Z)(C,"".concat(R,"-multiple"),eN),(0,l.Z)(C,"".concat(R,"-single"),!eN),(0,l.Z)(C,"".concat(R,"-allow-clear"),eu),(0,l.Z)(C,"".concat(R,"-show-arrow"),th),(0,l.Z)(C,"".concat(R,"-disabled"),K),(0,l.Z)(C,"".concat(R,"-loading"),$),(0,l.Z)(C,"".concat(R,"-open"),e9),(0,l.Z)(C,"".concat(R,"-customize-input"),eY),(0,l.Z)(C,"".concat(R,"-show-search"),eP),C)),tE=r.createElement(L,{ref:eB,disabled:K,prefixCls:R,visible:te,popupElement:tx,animation:em,transitionName:eg,dropdownStyle:eh,dropdownClassName:ev,direction:P,dropdownMatchSelectWidth:eb,dropdownRender:ey,dropdownAlign:ex,placement:ew,builtinPlacements:eE,getPopupContainer:eS,empty:_,getTriggerDOMNode:function(){return eH.current},onPopupVisibleChange:Z,onPopupMouseEnter:function(){tm({})}},eQ?r.cloneElement(eQ,{ref:eJ}):r.createElement(T,(0,i.Z)({},e,{domRef:eH,prefixCls:R,inputElement:eY,ref:eD,id:M,showSearch:eP,autoClearSearchValue:ei,mode:U,activeDescendantId:eo,tagRender:N,values:A,open:e9,onToggleOpen:tt,activeValue:en,searchValue:e$,onSearch:ti,onSearchSubmit:function(e){e&&e.trim()&&ec(e,{source:"submit"})},onRemove:function(e){z(A.filter(function(t){return t!==e}),{type:"remove",values:[e]})},tokenWithEnter:tn})));return k=eQ?tE:r.createElement("div",(0,i.Z)({className:tw},eT,{ref:e_,onMouseDown:function(e){var t,n=e.target,r=null===(t=eB.current)||void 0===t?void 0:t.getPopupElement();if(r&&r.contains(n)){var o=setTimeout(function(){var e,t=tf.indexOf(o);-1!==t&&tf.splice(t,1),eK(),ez||r.contains(document.activeElement)||null===(e=eD.current)||void 0===e||e.focus()});tf.push(o)}for(var a=arguments.length,i=Array(a>1?a-1:0),c=1;c=0;i-=1){var l=o[i];if(!l.disabled){o.splice(i,1),a=l;break}}a&&z(o,{type:"remove",values:[a]})}for(var s=arguments.length,u=Array(s>1?s-1:0),d=1;d1?n-1:0),o=1;o=C},[p,C,null==j?void 0:j.size]),B=function(e){e.preventDefault()},D=function(e){var t;null===(t=_.current)||void 0===t||t.scrollTo("number"==typeof e?{index:e}:e)},W=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=L.length,r=0;r1&&void 0!==arguments[1]&&arguments[1];U(e);var n={source:t?"keyboard":"mouse"},r=L[e];if(!r){O(null,-1,n);return}O(r.value,e,n)};(0,r.useEffect)(function(){K(!1!==k?W(0):-1)},[L.length,g]);var $=r.useCallback(function(e){return j.has(e)&&"combobox"!==m},[m,(0,c.Z)(j).toString(),j.size]);(0,r.useEffect)(function(){var e,t=setTimeout(function(){if(!p&&f&&1===j.size){var e=Array.from(j)[0],t=L.findIndex(function(t){return t.data.value===e});-1!==t&&(K(t),D(t))}});return f&&(null===(e=_.current)||void 0===e||e.scrollTo(void 0)),function(){return clearTimeout(t)}},[f,g]);var en=function(e){void 0!==e&&M(e,{selected:!j.has(e)}),p||h(!1)};if(r.useImperativeHandle(t,function(){return{onKeyDown:function(e){var t=e.which,n=e.ctrlKey;switch(t){case v.Z.N:case v.Z.P:case v.Z.UP:case v.Z.DOWN:var r=0;if(t===v.Z.UP?r=-1:t===v.Z.DOWN?r=1:/(mac\sos|macintosh)/i.test(navigator.appVersion)&&n&&(t===v.Z.N?r=1:t===v.Z.P&&(r=-1)),0!==r){var o=W(X+r,r);D(o),K(o,!0)}break;case v.Z.ENTER:var a,i=L[X];!i||null!=i&&null!==(a=i.data)&&void 0!==a&&a.disabled||H?en(void 0):en(i.value),f&&e.preventDefault();break;case v.Z.ESC:h(!1),f&&e.stopPropagation()}},onKeyUp:function(){},scrollTo:function(e){D(e)}}}),0===L.length)return r.createElement("div",{role:"listbox",id:"".concat(s,"_list"),className:"".concat(z,"-empty"),onMouseDown:B},b);var er=Object.keys(I).map(function(e){return I[e]}),eo=function(e){return e.label};function ea(e,t){return{role:e.group?"presentation":"option",id:"".concat(s,"_list_").concat(t)}}var ei=function(e){var t=L[e];if(!t)return null;var n=t.data||{},o=n.value,a=t.group,c=(0,S.Z)(n,!0),l=eo(t);return t?r.createElement("div",(0,i.Z)({"aria-label":"string"!=typeof l||a?null:l},c,{key:e},ea(t,e),{"aria-selected":$(o)}),o):null},ec={role:"listbox",id:"".concat(s,"_list")};return r.createElement(r.Fragment,null,N&&r.createElement("div",(0,i.Z)({},ec,{style:{height:0,width:0,overflow:"hidden"}}),ei(X-1),ei(X),ei(X+1)),r.createElement(J.Z,{itemKey:"key",ref:_,data:L,height:T,itemHeight:F,fullHeight:!1,onMouseDown:B,onScroll:x,virtual:N,direction:P,innerProps:N?null:ec},function(e,t){var n=e.group,o=e.groupOption,c=e.data,s=e.label,u=e.value,f=c.key;if(n){var p,m,g=null!==(m=c.title)&&void 0!==m?m:et(s)?s.toString():void 0;return r.createElement("div",{className:a()(z,"".concat(z,"-group")),title:g},void 0!==s?s:f)}var h=c.disabled,v=c.title,b=(c.children,c.style),x=c.className,w=(0,d.Z)(c,ee),E=(0,Q.Z)(w,er),C=$(u),Z=h||!C&&H,O="".concat(z,"-option"),k=a()(z,O,x,(p={},(0,l.Z)(p,"".concat(O,"-grouped"),o),(0,l.Z)(p,"".concat(O,"-active"),X===t&&!Z),(0,l.Z)(p,"".concat(O,"-disabled"),Z),(0,l.Z)(p,"".concat(O,"-selected"),C),p)),M=eo(e),j=!R||"function"==typeof R||C,I="number"==typeof M?M:M||u,P=et(I)?I.toString():void 0;return void 0!==v&&(P=v),r.createElement("div",(0,i.Z)({},(0,S.Z)(E),N?{}:ea(e,t),{"aria-selected":C,className:k,title:P,onMouseMove:function(){X===t||Z||K(t)},onClick:function(){Z||en(u)},style:b}),r.createElement("div",{className:"".concat(O,"-content")},"function"==typeof A?A(e,{index:t}):I),r.isValidElement(R)||C,j&&r.createElement(y,{className:"".concat(z,"-option-state"),customizeIcon:R,customizeIconProps:{value:u,disabled:Z,isSelected:C}},C?"✓":null))}))}),er=function(e,t){var n=r.useRef({values:new Map,options:new Map});return[r.useMemo(function(){var r=n.current,o=r.values,a=r.options,i=e.map(function(e){if(void 0===e.label){var t;return(0,s.Z)((0,s.Z)({},e),{},{label:null===(t=o.get(e.value))||void 0===t?void 0:t.label})}return e}),c=new Map,l=new Map;return i.forEach(function(e){c.set(e.value,e),l.set(e.value,t.get(e.value)||a.get(e.value))}),n.current.values=c,n.current.options=l,i},[e,t]),r.useCallback(function(e){return t.get(e)||n.current.options.get(e)},[t])]};function eo(e,t){return O(e).join("").toUpperCase().includes(t)}var ea=n(94981),ei=0,ec=(0,ea.Z)(),el=n(45287),es=["children","value"],eu=["children"];function ed(e){var t=r.useRef();return t.current=e,r.useCallback(function(){return t.current.apply(t,arguments)},[])}var ef=["id","mode","prefixCls","backfill","fieldNames","inputValue","searchValue","onSearch","autoClearSearchValue","onSelect","onDeselect","dropdownMatchSelectWidth","filterOption","filterSort","optionFilterProp","optionLabelProp","options","optionRender","children","defaultActiveFirstOption","menuItemSelectedIcon","virtual","direction","listHeight","listItemHeight","value","defaultValue","labelInValue","onChange","maxCount"],ep=["inputValue"],em=r.forwardRef(function(e,t){var n,o,a,m,g,h=e.id,v=e.mode,b=e.prefixCls,y=e.backfill,x=e.fieldNames,w=e.inputValue,E=e.searchValue,S=e.onSearch,C=e.autoClearSearchValue,Z=void 0===C||C,k=e.onSelect,M=e.onDeselect,R=e.dropdownMatchSelectWidth,j=void 0===R||R,I=e.filterOption,N=e.filterSort,P=e.optionFilterProp,T=e.optionLabelProp,F=e.options,A=e.optionRender,z=e.children,L=e.defaultActiveFirstOption,_=e.menuItemSelectedIcon,W=e.virtual,q=e.direction,G=e.listHeight,K=void 0===G?200:G,$=e.listItemHeight,Y=void 0===$?20:$,Q=e.value,J=e.defaultValue,ee=e.labelInValue,et=e.onChange,ea=e.maxCount,em=(0,d.Z)(e,ef),eg=(n=r.useState(),a=(o=(0,u.Z)(n,2))[0],m=o[1],r.useEffect(function(){var e;m("rc_select_".concat((ec?(e=ei,ei+=1):e="TEST_OR_SSR",e)))},[]),h||a),eh=X(v),ev=!!(!F&&z),eb=r.useMemo(function(){return(void 0!==I||"combobox"!==v)&&I},[I,v]),ey=r.useMemo(function(){return B(x,ev)},[JSON.stringify(x),ev]),ex=(0,p.Z)("",{value:void 0!==E?E:w,postState:function(e){return e||""}}),ew=(0,u.Z)(ex,2),eE=ew[0],eS=ew[1],eC=r.useMemo(function(){var e=F;F||(e=function e(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return(0,el.Z)(t).map(function(t,o){if(!r.isValidElement(t)||!t.type)return null;var a,i,c,l,u,f=t.type.isSelectOptGroup,p=t.key,m=t.props,g=m.children,h=(0,d.Z)(m,eu);return n||!f?(a=t.key,c=(i=t.props).children,l=i.value,u=(0,d.Z)(i,es),(0,s.Z)({key:a,value:void 0!==l?l:a,children:c},u)):(0,s.Z)((0,s.Z)({key:"__RC_SELECT_GRP__".concat(null===p?o:p,"__"),label:p},h),{},{options:e(g)})}).filter(function(e){return e})}(z));var t=new Map,n=new Map,o=function(e,t,n){n&&"string"==typeof n&&e.set(t[n],t)};return function e(r){for(var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=0;i1&&void 0!==arguments[1]?arguments[1]:{},n=t.fieldNames,r=t.childrenAsData,o=[],a=B(n,!1),i=a.label,c=a.value,l=a.options,s=a.groupLabel;return!function e(t,n){Array.isArray(t)&&t.forEach(function(t){if(!n&&l in t){var a=t[s];void 0===a&&r&&(a=t.label),o.push({key:H(t,o.length),group:!0,data:t,label:a}),e(t[l],!0)}else{var u=t[c];o.push({key:H(t,o.length),groupOption:n,data:t,label:t[i],value:u})}})}(e,!1),o}(eD,{fieldNames:ey,childrenAsData:ev})},[eD,ey,ev]),eV=function(e){var t=eM(e);if(eN(t),et&&(t.length!==eF.length||t.some(function(e,t){var n;return(null===(n=eF[t])||void 0===n?void 0:n.value)!==(null==e?void 0:e.value)}))){var n=ee?t:t.map(function(e){return e.value}),r=t.map(function(e){return D(eA(e.value))});et(eh?n:n[0],eh?r:r[0])}},eq=r.useState(null),eG=(0,u.Z)(eq,2),eX=eG[0],eU=eG[1],eK=r.useState(0),e$=(0,u.Z)(eK,2),eY=e$[0],eQ=e$[1],eJ=void 0!==L?L:"combobox"!==v,e0=r.useCallback(function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.source;eQ(t),y&&"combobox"===v&&null!==e&&"keyboard"===(void 0===r?"keyboard":r)&&eU(String(e))},[y,v]),e1=function(e,t,n){var r=function(){var t,n=eA(e);return[ee?{label:null==n?void 0:n[ey.label],value:e,key:null!==(t=null==n?void 0:n.key)&&void 0!==t?t:e}:e,D(n)]};if(t&&k){var o=r(),a=(0,u.Z)(o,2);k(a[0],a[1])}else if(!t&&M&&"clear"!==n){var i=r(),c=(0,u.Z)(i,2);M(c[0],c[1])}},e2=ed(function(e,t){var n=!eh||t.selected;eV(n?eh?[].concat((0,c.Z)(eF),[e]):[e]:eF.filter(function(t){return t.value!==e})),e1(e,n),"combobox"===v?eU(""):(!X||Z)&&(eS(""),eU(""))}),e6=r.useMemo(function(){var e=!1!==W&&!1!==j;return(0,s.Z)((0,s.Z)({},eC),{},{flattenOptions:eW,onActiveValue:e0,defaultActiveFirstOption:eJ,onSelect:e2,menuItemSelectedIcon:_,rawValues:eL,fieldNames:ey,virtual:e,direction:q,listHeight:K,listItemHeight:Y,childrenAsData:ev,maxCount:ea,optionRender:A})},[ea,eC,eW,e0,eJ,e2,_,eL,ey,W,j,q,K,Y,ev,A]);return r.createElement(V.Provider,{value:e6},r.createElement(U,(0,i.Z)({},em,{id:eg,prefixCls:void 0===b?"rc-select":b,ref:t,omitDomProps:ep,mode:v,displayValues:ez,onDisplayValuesChange:function(e,t){eV(e);var n=t.type,r=t.values;("remove"===n||"clear"===n)&&r.forEach(function(e){e1(e.value,!1,n)})},direction:q,searchValue:eE,onSearch:function(e,t){if(eS(e),eU(null),"submit"===t.source){var n=(e||"").trim();n&&(eV(Array.from(new Set([].concat((0,c.Z)(eL),[n])))),e1(n,!0),eS(""));return}"blur"!==t.source&&("combobox"===v&&eV(e),null==S||S(e))},autoClearSearchValue:Z,onSearchSplit:function(e){var t=e;"tags"!==v&&(t=e.map(function(e){var t=eO.get(e);return null==t?void 0:t.value}).filter(function(e){return void 0!==e}));var n=Array.from(new Set([].concat((0,c.Z)(eL),(0,c.Z)(t))));eV(n),n.forEach(function(e){e1(e,!0)})},dropdownMatchSelectWidth:j,OptionList:en,emptyOptions:!eW.length,activeValue:eX,activeDescendantId:"".concat(eg,"_list_").concat(eY)})))});em.Option=$,em.OptGroup=K;var eg=n(62236),eh=n(68710),ev=n(93942),eb=n(12757),ey=n(71744),ex=n(91086),ew=n(86586),eE=n(64024),eS=n(33759),eC=n(39109),eZ=n(56250),eO=n(65658),ek=n(29961);let eM=e=>{let t={overflow:{adjustX:!0,adjustY:!0,shiftY:!0},htmlRegion:"scroll"===e?"scroll":"visible",dynamicInset:!0};return{bottomLeft:Object.assign(Object.assign({},t),{points:["tl","bl"],offset:[0,4]}),bottomRight:Object.assign(Object.assign({},t),{points:["tr","br"],offset:[0,4]}),topLeft:Object.assign(Object.assign({},t),{points:["bl","tl"],offset:[0,-4]}),topRight:Object.assign(Object.assign({},t),{points:["br","tr"],offset:[0,-4]})}};var eR=n(12918),ej=n(17691),eI=n(80669),eN=n(3104),eP=n(18544),eT=n(29382);let eF=e=>{let{optionHeight:t,optionFontSize:n,optionLineHeight:r,optionPadding:o}=e;return{position:"relative",display:"block",minHeight:t,padding:o,color:e.colorText,fontWeight:"normal",fontSize:n,lineHeight:r,boxSizing:"border-box"}};var eA=e=>{let{antCls:t,componentCls:n}=e,r="".concat(n,"-item"),o="&".concat(t,"-slide-up-enter").concat(t,"-slide-up-enter-active"),a="&".concat(t,"-slide-up-appear").concat(t,"-slide-up-appear-active"),i="&".concat(t,"-slide-up-leave").concat(t,"-slide-up-leave-active"),c="".concat(n,"-dropdown-placement-");return[{["".concat(n,"-dropdown")]:Object.assign(Object.assign({},(0,eR.Wf)(e)),{position:"absolute",top:-9999,zIndex:e.zIndexPopup,boxSizing:"border-box",padding:e.paddingXXS,overflow:"hidden",fontSize:e.fontSize,fontVariant:"initial",backgroundColor:e.colorBgElevated,borderRadius:e.borderRadiusLG,outline:"none",boxShadow:e.boxShadowSecondary,["\n          ".concat(o).concat(c,"bottomLeft,\n          ").concat(a).concat(c,"bottomLeft\n        ")]:{animationName:eP.fJ},["\n          ".concat(o).concat(c,"topLeft,\n          ").concat(a).concat(c,"topLeft,\n          ").concat(o).concat(c,"topRight,\n          ").concat(a).concat(c,"topRight\n        ")]:{animationName:eP.Qt},["".concat(i).concat(c,"bottomLeft")]:{animationName:eP.Uw},["\n          ".concat(i).concat(c,"topLeft,\n          ").concat(i).concat(c,"topRight\n        ")]:{animationName:eP.ly},"&-hidden":{display:"none"},["".concat(r)]:Object.assign(Object.assign({},eF(e)),{cursor:"pointer",transition:"background ".concat(e.motionDurationSlow," ease"),borderRadius:e.borderRadiusSM,"&-group":{color:e.colorTextDescription,fontSize:e.fontSizeSM,cursor:"default"},"&-option":{display:"flex","&-content":Object.assign({flex:"auto"},eR.vS),"&-state":{flex:"none",display:"flex",alignItems:"center"},["&-active:not(".concat(r,"-option-disabled)")]:{backgroundColor:e.optionActiveBg},["&-selected:not(".concat(r,"-option-disabled)")]:{color:e.optionSelectedColor,fontWeight:e.optionSelectedFontWeight,backgroundColor:e.optionSelectedBg,["".concat(r,"-option-state")]:{color:e.colorPrimary},["&:has(+ ".concat(r,"-option-selected:not(").concat(r,"-option-disabled))")]:{borderEndStartRadius:0,borderEndEndRadius:0,["& + ".concat(r,"-option-selected:not(").concat(r,"-option-disabled)")]:{borderStartStartRadius:0,borderStartEndRadius:0}}},"&-disabled":{["&".concat(r,"-option-selected")]:{backgroundColor:e.colorBgContainerDisabled},color:e.colorTextDisabled,cursor:"not-allowed"},"&-grouped":{paddingInlineStart:e.calc(e.controlPaddingHorizontal).mul(2).equal()}}}),"&-rtl":{direction:"rtl"}})},(0,eP.oN)(e,"slide-up"),(0,eP.oN)(e,"slide-down"),(0,eT.Fm)(e,"move-up"),(0,eT.Fm)(e,"move-down")]},ez=n(352);let eL=e=>{let{multipleSelectItemHeight:t,selectHeight:n,lineWidth:r}=e;return e.calc(n).sub(t).div(2).sub(r).equal()};function e_(e,t){let{componentCls:n,iconCls:r}=e,o="".concat(n,"-selection-overflow"),a=e.multipleSelectItemHeight,i=eL(e),c=t?"".concat(n,"-").concat(t):"";return{["".concat(n,"-multiple").concat(c)]:{fontSize:e.fontSize,[o]:{position:"relative",display:"flex",flex:"auto",flexWrap:"wrap",maxWidth:"100%","&-item":{flex:"none",alignSelf:"center",maxWidth:"100%",display:"inline-flex"}},["".concat(n,"-selector")]:{display:"flex",flexWrap:"wrap",alignItems:"center",height:"100%",paddingInline:e.calc(2).mul(2).equal(),paddingBlock:e.calc(i).sub(2).equal(),borderRadius:e.borderRadius,["".concat(n,"-show-search&")]:{cursor:"text"},["".concat(n,"-disabled&")]:{background:e.multipleSelectorBgDisabled,cursor:"not-allowed"},"&:after":{display:"inline-block",width:0,margin:"".concat((0,ez.bf)(2)," 0"),lineHeight:(0,ez.bf)(a),visibility:"hidden",content:'"\\a0"'}},["\n        &".concat(n,"-show-arrow ").concat(n,"-selector,\n        &").concat(n,"-allow-clear ").concat(n,"-selector\n      ")]:{paddingInlineEnd:e.calc(e.fontSizeIcon).add(e.controlPaddingHorizontal).equal()},["".concat(n,"-selection-item")]:{display:"flex",alignSelf:"center",flex:"none",boxSizing:"border-box",maxWidth:"100%",height:a,marginTop:2,marginBottom:2,lineHeight:(0,ez.bf)(e.calc(a).sub(e.calc(e.lineWidth).mul(2)).equal()),borderRadius:e.borderRadiusSM,cursor:"default",transition:"font-size ".concat(e.motionDurationSlow,", line-height ").concat(e.motionDurationSlow,", height ").concat(e.motionDurationSlow),marginInlineEnd:e.calc(2).mul(2).equal(),paddingInlineStart:e.paddingXS,paddingInlineEnd:e.calc(e.paddingXS).div(2).equal(),["".concat(n,"-disabled&")]:{color:e.multipleItemColorDisabled,borderColor:e.multipleItemBorderColorDisabled,cursor:"not-allowed"},"&-content":{display:"inline-block",marginInlineEnd:e.calc(e.paddingXS).div(2).equal(),overflow:"hidden",whiteSpace:"pre",textOverflow:"ellipsis"},"&-remove":Object.assign(Object.assign({},(0,eR.Ro)()),{display:"inline-flex",alignItems:"center",color:e.colorIcon,fontWeight:"bold",fontSize:10,lineHeight:"inherit",cursor:"pointer",["> ".concat(r)]:{verticalAlign:"-0.2em"},"&:hover":{color:e.colorIconHover}})},["".concat(o,"-item + ").concat(o,"-item")]:{["".concat(n,"-selection-search")]:{marginInlineStart:0}},["".concat(o,"-item-suffix")]:{height:"100%"},["".concat(n,"-selection-search")]:{display:"inline-flex",position:"relative",maxWidth:"100%",marginInlineStart:e.calc(e.inputPaddingHorizontalBase).sub(i).equal(),"\n          &-input,\n          &-mirror\n        ":{height:a,fontFamily:e.fontFamily,lineHeight:(0,ez.bf)(a),transition:"all ".concat(e.motionDurationSlow)},"&-input":{width:"100%",minWidth:4.1},"&-mirror":{position:"absolute",top:0,insetInlineStart:0,insetInlineEnd:"auto",zIndex:999,whiteSpace:"pre",visibility:"hidden"}},["".concat(n,"-selection-placeholder")]:{position:"absolute",top:"50%",insetInlineStart:e.inputPaddingHorizontalBase,insetInlineEnd:e.inputPaddingHorizontalBase,transform:"translateY(-50%)",transition:"all ".concat(e.motionDurationSlow)}}}}var eH=e=>{let{componentCls:t}=e,n=(0,eN.TS)(e,{selectHeight:e.controlHeightSM,multipleSelectItemHeight:e.controlHeightXS,borderRadius:e.borderRadiusSM,borderRadiusSM:e.borderRadiusXS}),r=(0,eN.TS)(e,{fontSize:e.fontSizeLG,selectHeight:e.controlHeightLG,multipleSelectItemHeight:e.multipleItemHeightLG,borderRadius:e.borderRadiusLG,borderRadiusSM:e.borderRadius});return[e_(e),e_(n,"sm"),{["".concat(t,"-multiple").concat(t,"-sm")]:{["".concat(t,"-selection-placeholder")]:{insetInline:e.calc(e.controlPaddingHorizontalSM).sub(e.lineWidth).equal()},["".concat(t,"-selection-search")]:{marginInlineStart:2}}},e_(r,"lg")]};function eB(e,t){let{componentCls:n,inputPaddingHorizontalBase:r,borderRadius:o}=e,a=e.calc(e.controlHeight).sub(e.calc(e.lineWidth).mul(2)).equal(),i=t?"".concat(n,"-").concat(t):"";return{["".concat(n,"-single").concat(i)]:{fontSize:e.fontSize,height:e.controlHeight,["".concat(n,"-selector")]:Object.assign(Object.assign({},(0,eR.Wf)(e,!0)),{display:"flex",borderRadius:o,["".concat(n,"-selection-search")]:{position:"absolute",top:0,insetInlineStart:r,insetInlineEnd:r,bottom:0,"&-input":{width:"100%",WebkitAppearance:"textfield"}},["\n          ".concat(n,"-selection-item,\n          ").concat(n,"-selection-placeholder\n        ")]:{padding:0,lineHeight:(0,ez.bf)(a),transition:"all ".concat(e.motionDurationSlow,", visibility 0s"),alignSelf:"center"},["".concat(n,"-selection-placeholder")]:{transition:"none",pointerEvents:"none"},[["&:after","".concat(n,"-selection-item:empty:after"),"".concat(n,"-selection-placeholder:empty:after")].join(",")]:{display:"inline-block",width:0,visibility:"hidden",content:'"\\a0"'}}),["\n        &".concat(n,"-show-arrow ").concat(n,"-selection-item,\n        &").concat(n,"-show-arrow ").concat(n,"-selection-placeholder\n      ")]:{paddingInlineEnd:e.showArrowPaddingInlineEnd},["&".concat(n,"-open ").concat(n,"-selection-item")]:{color:e.colorTextPlaceholder},["&:not(".concat(n,"-customize-input)")]:{["".concat(n,"-selector")]:{width:"100%",height:"100%",padding:"0 ".concat((0,ez.bf)(r)),["".concat(n,"-selection-search-input")]:{height:a},"&:after":{lineHeight:(0,ez.bf)(a)}}},["&".concat(n,"-customize-input")]:{["".concat(n,"-selector")]:{"&:after":{display:"none"},["".concat(n,"-selection-search")]:{position:"static",width:"100%"},["".concat(n,"-selection-placeholder")]:{position:"absolute",insetInlineStart:0,insetInlineEnd:0,padding:"0 ".concat((0,ez.bf)(r)),"&:after":{display:"none"}}}}}}}let eD=(e,t)=>{let{componentCls:n,antCls:r,controlOutlineWidth:o}=e;return{["&:not(".concat(n,"-customize-input) ").concat(n,"-selector")]:{border:"".concat((0,ez.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(t.borderColor),background:e.selectorBg},["&:not(".concat(n,"-disabled):not(").concat(n,"-customize-input):not(").concat(r,"-pagination-size-changer)")]:{["&:hover ".concat(n,"-selector")]:{borderColor:t.hoverBorderHover},["".concat(n,"-focused& ").concat(n,"-selector")]:{borderColor:t.activeBorderColor,boxShadow:"0 0 0 ".concat((0,ez.bf)(o)," ").concat(t.activeShadowColor),outline:0}}}},eW=(e,t)=>({["&".concat(e.componentCls,"-status-").concat(t.status)]:Object.assign({},eD(e,t))}),eV=e=>({"&-outlined":Object.assign(Object.assign(Object.assign(Object.assign({},eD(e,{borderColor:e.colorBorder,hoverBorderHover:e.colorPrimaryHover,activeBorderColor:e.colorPrimary,activeShadowColor:e.controlOutline})),eW(e,{status:"error",borderColor:e.colorError,hoverBorderHover:e.colorErrorHover,activeBorderColor:e.colorError,activeShadowColor:e.colorErrorOutline})),eW(e,{status:"warning",borderColor:e.colorWarning,hoverBorderHover:e.colorWarningHover,activeBorderColor:e.colorWarning,activeShadowColor:e.colorWarningOutline})),{["&".concat(e.componentCls,"-disabled")]:{["&:not(".concat(e.componentCls,"-customize-input) ").concat(e.componentCls,"-selector")]:{background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},["&".concat(e.componentCls,"-multiple ").concat(e.componentCls,"-selection-item")]:{background:e.multipleItemBg,border:"".concat((0,ez.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.multipleItemBorderColor)}})}),eq=(e,t)=>{let{componentCls:n,antCls:r}=e;return{["&:not(".concat(n,"-customize-input) ").concat(n,"-selector")]:{background:t.bg,border:"".concat((0,ez.bf)(e.lineWidth)," ").concat(e.lineType," transparent"),color:t.color},["&:not(".concat(n,"-disabled):not(").concat(n,"-customize-input):not(").concat(r,"-pagination-size-changer)")]:{["&:hover ".concat(n,"-selector")]:{background:t.hoverBg},["".concat(n,"-focused& ").concat(n,"-selector")]:{background:e.selectorBg,borderColor:t.activeBorderColor,outline:0}}}},eG=(e,t)=>({["&".concat(e.componentCls,"-status-").concat(t.status)]:Object.assign({},eq(e,t))}),eX=e=>({"&-filled":Object.assign(Object.assign(Object.assign(Object.assign({},eq(e,{bg:e.colorFillTertiary,hoverBg:e.colorFillSecondary,activeBorderColor:e.colorPrimary,color:e.colorText})),eG(e,{status:"error",bg:e.colorErrorBg,hoverBg:e.colorErrorBgHover,activeBorderColor:e.colorError,color:e.colorError})),eG(e,{status:"warning",bg:e.colorWarningBg,hoverBg:e.colorWarningBgHover,activeBorderColor:e.colorWarning,color:e.colorWarning})),{["&".concat(e.componentCls,"-disabled")]:{["&:not(".concat(e.componentCls,"-customize-input) ").concat(e.componentCls,"-selector")]:{borderColor:e.colorBorder,background:e.colorBgContainerDisabled,color:e.colorTextDisabled}},["&".concat(e.componentCls,"-multiple ").concat(e.componentCls,"-selection-item")]:{background:e.colorBgContainer,border:"".concat((0,ez.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.colorSplit)}})}),eU=e=>({"&-borderless":{["".concat(e.componentCls,"-selector")]:{background:"transparent",borderColor:"transparent"},["&".concat(e.componentCls,"-disabled")]:{["&:not(".concat(e.componentCls,"-customize-input) ").concat(e.componentCls,"-selector")]:{color:e.colorTextDisabled}},["&".concat(e.componentCls,"-multiple ").concat(e.componentCls,"-selection-item")]:{background:e.multipleItemBg,border:"".concat((0,ez.bf)(e.lineWidth)," ").concat(e.lineType," ").concat(e.multipleItemBorderColor)}}});var eK=e=>({[e.componentCls]:Object.assign(Object.assign(Object.assign({},eV(e)),eX(e)),eU(e))});let e$=e=>{let{componentCls:t}=e;return{position:"relative",transition:"all ".concat(e.motionDurationMid," ").concat(e.motionEaseInOut),input:{cursor:"pointer"},["".concat(t,"-show-search&")]:{cursor:"text",input:{cursor:"auto",color:"inherit",height:"100%"}},["".concat(t,"-disabled&")]:{cursor:"not-allowed",input:{cursor:"not-allowed"}}}},eY=e=>{let{componentCls:t}=e;return{["".concat(t,"-selection-search-input")]:{margin:0,padding:0,background:"transparent",border:"none",outline:"none",appearance:"none",fontFamily:"inherit","&::-webkit-search-cancel-button":{display:"none","-webkit-appearance":"none"}}}},eQ=e=>{let{antCls:t,componentCls:n,inputPaddingHorizontalBase:r,iconCls:o}=e;return{[n]:Object.assign(Object.assign({},(0,eR.Wf)(e)),{position:"relative",display:"inline-block",cursor:"pointer",["&:not(".concat(n,"-customize-input) ").concat(n,"-selector")]:Object.assign(Object.assign({},e$(e)),eY(e)),["".concat(n,"-selection-item")]:Object.assign(Object.assign({flex:1,fontWeight:"normal",position:"relative",userSelect:"none"},eR.vS),{["> ".concat(t,"-typography")]:{display:"inline"}}),["".concat(n,"-selection-placeholder")]:Object.assign(Object.assign({},eR.vS),{flex:1,color:e.colorTextPlaceholder,pointerEvents:"none"}),["".concat(n,"-arrow")]:Object.assign(Object.assign({},(0,eR.Ro)()),{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:r,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,lineHeight:1,textAlign:"center",pointerEvents:"none",display:"flex",alignItems:"center",transition:"opacity ".concat(e.motionDurationSlow," ease"),[o]:{verticalAlign:"top",transition:"transform ".concat(e.motionDurationSlow),"> svg":{verticalAlign:"top"},["&:not(".concat(n,"-suffix)")]:{pointerEvents:"auto"}},["".concat(n,"-disabled &")]:{cursor:"not-allowed"},"> *:not(:last-child)":{marginInlineEnd:8}}),["".concat(n,"-clear")]:{position:"absolute",top:"50%",insetInlineStart:"auto",insetInlineEnd:r,zIndex:1,display:"inline-block",width:e.fontSizeIcon,height:e.fontSizeIcon,marginTop:e.calc(e.fontSizeIcon).mul(-1).div(2).equal(),color:e.colorTextQuaternary,fontSize:e.fontSizeIcon,fontStyle:"normal",lineHeight:1,textAlign:"center",textTransform:"none",cursor:"pointer",opacity:0,transition:"color ".concat(e.motionDurationMid," ease, opacity ").concat(e.motionDurationSlow," ease"),textRendering:"auto","&:before":{display:"block"},"&:hover":{color:e.colorTextTertiary}},"&:hover":{["".concat(n,"-clear")]:{opacity:1},["".concat(n,"-arrow:not(:last-child)")]:{opacity:0}}}),["".concat(n,"-has-feedback")]:{["".concat(n,"-clear")]:{insetInlineEnd:e.calc(r).add(e.fontSize).add(e.paddingXS).equal()}}}},eJ=e=>{let{componentCls:t}=e;return[{[t]:{["&".concat(t,"-in-form-item")]:{width:"100%"}}},eQ(e),function(e){let{componentCls:t}=e,n=e.calc(e.controlPaddingHorizontalSM).sub(e.lineWidth).equal();return[eB(e),eB((0,eN.TS)(e,{controlHeight:e.controlHeightSM,borderRadius:e.borderRadiusSM}),"sm"),{["".concat(t,"-single").concat(t,"-sm")]:{["&:not(".concat(t,"-customize-input)")]:{["".concat(t,"-selection-search")]:{insetInlineStart:n,insetInlineEnd:n},["".concat(t,"-selector")]:{padding:"0 ".concat((0,ez.bf)(n))},["&".concat(t,"-show-arrow ").concat(t,"-selection-search")]:{insetInlineEnd:e.calc(n).add(e.calc(e.fontSize).mul(1.5)).equal()},["\n            &".concat(t,"-show-arrow ").concat(t,"-selection-item,\n            &").concat(t,"-show-arrow ").concat(t,"-selection-placeholder\n          ")]:{paddingInlineEnd:e.calc(e.fontSize).mul(1.5).equal()}}}},eB((0,eN.TS)(e,{controlHeight:e.singleItemHeightLG,fontSize:e.fontSizeLG,borderRadius:e.borderRadiusLG}),"lg")]}(e),eH(e),eA(e),{["".concat(t,"-rtl")]:{direction:"rtl"}},(0,ej.c)(e,{borderElCls:"".concat(t,"-selector"),focusElCls:"".concat(t,"-focused")})]};var e0=(0,eI.I$)("Select",(e,t)=>{let{rootPrefixCls:n}=t,r=(0,eN.TS)(e,{rootPrefixCls:n,inputPaddingHorizontalBase:e.calc(e.paddingSM).sub(1).equal(),multipleSelectItemHeight:e.multipleItemHeight,selectHeight:e.controlHeight});return[eJ(r),eK(r)]},e=>{let{fontSize:t,lineHeight:n,controlHeight:r,controlPaddingHorizontal:o,zIndexPopupBase:a,colorText:i,fontWeightStrong:c,controlItemBgActive:l,controlItemBgHover:s,colorBgContainer:u,colorFillSecondary:d,controlHeightLG:f,controlHeightSM:p,colorBgContainerDisabled:m,colorTextDisabled:g}=e;return{zIndexPopup:a+50,optionSelectedColor:i,optionSelectedFontWeight:c,optionSelectedBg:l,optionActiveBg:s,optionPadding:"".concat((r-t*n)/2,"px ").concat(o,"px"),optionFontSize:t,optionLineHeight:n,optionHeight:r,selectorBg:u,clearBg:u,singleItemHeightLG:f,multipleItemBg:d,multipleItemBorderColor:"transparent",multipleItemHeight:p,multipleItemHeightLG:r,multipleSelectorBgDisabled:m,multipleItemColorDisabled:g,multipleItemBorderColorDisabled:"transparent",showArrowPaddingInlineEnd:Math.ceil(1.25*e.fontSize)}},{unitless:{optionLineHeight:!0,optionSelectedFontWeight:!0}}),e1=n(9738),e2=n(39725),e6=n(49638),e5=n(70464),e4=n(61935),e3=n(29436),e8=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let e9="SECRET_COMBOBOX_MODE_DO_NOT_USE",e7=r.forwardRef((e,t)=>{var n,o,i;let c;let{prefixCls:l,bordered:s,className:u,rootClassName:d,getPopupContainer:f,popupClassName:p,dropdownClassName:m,listHeight:g=256,placement:h,listItemHeight:v,size:b,disabled:y,notFoundContent:x,status:w,builtinPlacements:E,dropdownMatchSelectWidth:S,popupMatchSelectWidth:C,direction:Z,style:O,allowClear:k,variant:M,dropdownStyle:R,transitionName:j,tagRender:I,maxCount:N}=e,P=e8(e,["prefixCls","bordered","className","rootClassName","getPopupContainer","popupClassName","dropdownClassName","listHeight","placement","listItemHeight","size","disabled","notFoundContent","status","builtinPlacements","dropdownMatchSelectWidth","popupMatchSelectWidth","direction","style","allowClear","variant","dropdownStyle","transitionName","tagRender","maxCount"]),{getPopupContainer:T,getPrefixCls:F,renderEmpty:A,direction:z,virtual:L,popupMatchSelectWidth:_,popupOverflow:H,select:B}=r.useContext(ey.E_),[,D]=(0,ek.ZP)(),W=null!=v?v:null==D?void 0:D.controlHeight,V=F("select",l),q=F(),G=null!=Z?Z:z,{compactSize:X,compactItemClassnames:U}=(0,eO.ri)(V,G),[K,$]=(0,eZ.Z)(M,s),Y=(0,eE.Z)(V),[J,ee,et]=e0(V,Y),en=r.useMemo(()=>{let{mode:t}=e;return"combobox"===t?void 0:t===e9?"combobox":t},[e.mode]),er="multiple"===en||"tags"===en,eo=(o=e.suffixIcon,void 0!==(i=e.showArrow)?i:null!==o),ea=null!==(n=null!=C?C:S)&&void 0!==n?n:_,{status:ei,hasFeedback:ec,isFormItemInput:el,feedbackIcon:es}=r.useContext(eC.aM),eu=(0,eb.F)(ei,w);c=void 0!==x?x:"combobox"===en?null:(null==A?void 0:A("Select"))||r.createElement(ex.Z,{componentName:"Select"});let{suffixIcon:ed,itemIcon:ef,removeIcon:ep,clearIcon:ev}=function(e){let{suffixIcon:t,clearIcon:n,menuItemSelectedIcon:o,removeIcon:a,loading:i,multiple:c,hasFeedback:l,prefixCls:s,showSuffixIcon:u,feedbackIcon:d,showArrow:f,componentName:p}=e,m=null!=n?n:r.createElement(e2.Z,null),g=e=>null!==t||l||f?r.createElement(r.Fragment,null,!1!==u&&e,l&&d):null,h=null;if(void 0!==t)h=g(t);else if(i)h=g(r.createElement(e4.Z,{spin:!0}));else{let e="".concat(s,"-suffix");h=t=>{let{open:n,showSearch:o}=t;return n&&o?g(r.createElement(e3.Z,{className:e})):g(r.createElement(e5.Z,{className:e}))}}let v=null;return v=void 0!==o?o:c?r.createElement(e1.Z,null):null,{clearIcon:m,suffixIcon:h,itemIcon:v,removeIcon:void 0!==a?a:r.createElement(e6.Z,null)}}(Object.assign(Object.assign({},P),{multiple:er,hasFeedback:ec,feedbackIcon:es,showSuffixIcon:eo,prefixCls:V,componentName:"Select"})),eR=(0,Q.Z)(P,["suffixIcon","itemIcon"]),ej=a()(p||m,{["".concat(V,"-dropdown-").concat(G)]:"rtl"===G},d,et,Y,ee),eI=(0,eS.Z)(e=>{var t;return null!==(t=null!=b?b:X)&&void 0!==t?t:e}),eN=r.useContext(ew.Z),eP=a()({["".concat(V,"-lg")]:"large"===eI,["".concat(V,"-sm")]:"small"===eI,["".concat(V,"-rtl")]:"rtl"===G,["".concat(V,"-").concat(K)]:$,["".concat(V,"-in-form-item")]:el},(0,eb.Z)(V,eu,ec),U,null==B?void 0:B.className,u,d,et,Y,ee),eT=r.useMemo(()=>void 0!==h?h:"rtl"===G?"bottomRight":"bottomLeft",[h,G]),[eF]=(0,eg.Cn)("SelectLike",null==R?void 0:R.zIndex);return J(r.createElement(em,Object.assign({ref:t,virtual:L,showSearch:null==B?void 0:B.showSearch},eR,{style:Object.assign(Object.assign({},null==B?void 0:B.style),O),dropdownMatchSelectWidth:ea,transitionName:(0,eh.m)(q,"slide-up",j),builtinPlacements:E||eM(H),listHeight:g,listItemHeight:W,mode:en,prefixCls:V,placement:eT,direction:G,suffixIcon:ed,menuItemSelectedIcon:ef,removeIcon:ep,allowClear:!0===k?{clearIcon:ev}:k,notFoundContent:c,className:eP,getPopupContainer:f||T,dropdownClassName:ej,disabled:null!=y?y:eN,dropdownStyle:Object.assign(Object.assign({},R),{zIndex:eF}),maxCount:er?N:void 0,tagRender:er?I:void 0})))}),te=(0,ev.Z)(e7);e7.SECRET_COMBOBOX_MODE_DO_NOT_USE=e9,e7.Option=$,e7.OptGroup=K,e7._InternalPanelDoNotUseOrYouWillBeFired=te;var tt=e7},65658:function(e,t,n){"use strict";n.d(t,{BR:function(){return p},ri:function(){return f}});var r=n(36760),o=n.n(r),a=n(45287),i=n(2265),c=n(71744),l=n(33759),s=n(4924),u=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let d=i.createContext(null),f=(e,t)=>{let n=i.useContext(d),r=i.useMemo(()=>{if(!n)return"";let{compactDirection:r,isFirstItem:a,isLastItem:i}=n,c="vertical"===r?"-vertical-":"-";return o()("".concat(e,"-compact").concat(c,"item"),{["".concat(e,"-compact").concat(c,"first-item")]:a,["".concat(e,"-compact").concat(c,"last-item")]:i,["".concat(e,"-compact").concat(c,"item-rtl")]:"rtl"===t})},[e,t,n]);return{compactSize:null==n?void 0:n.compactSize,compactDirection:null==n?void 0:n.compactDirection,compactItemClassnames:r}},p=e=>{let{children:t}=e;return i.createElement(d.Provider,{value:null},t)},m=e=>{var{children:t}=e,n=u(e,["children"]);return i.createElement(d.Provider,{value:n},t)};t.ZP=e=>{let{getPrefixCls:t,direction:n}=i.useContext(c.E_),{size:r,direction:f,block:p,prefixCls:g,className:h,rootClassName:v,children:b}=e,y=u(e,["size","direction","block","prefixCls","className","rootClassName","children"]),x=(0,l.Z)(e=>null!=r?r:e),w=t("space-compact",g),[E,S]=(0,s.Z)(w),C=o()(w,S,{["".concat(w,"-rtl")]:"rtl"===n,["".concat(w,"-block")]:p,["".concat(w,"-vertical")]:"vertical"===f},h,v),Z=i.useContext(d),O=(0,a.Z)(b),k=i.useMemo(()=>O.map((e,t)=>{let n=e&&e.key||"".concat(w,"-item-").concat(t);return i.createElement(m,{key:n,compactSize:x,compactDirection:f,isFirstItem:0===t&&(!Z||(null==Z?void 0:Z.isFirstItem)),isLastItem:t===O.length-1&&(!Z||(null==Z?void 0:Z.isLastItem))},e)}),[r,O,Z]);return 0===O.length?null:E(i.createElement("div",Object.assign({className:C},y),k))}},4924:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=n(80669),o=n(3104),a=e=>{let{componentCls:t}=e;return{[t]:{"&-block":{display:"flex",width:"100%"},"&-vertical":{flexDirection:"column"}}}};let i=e=>{let{componentCls:t}=e;return{[t]:{display:"inline-flex","&-rtl":{direction:"rtl"},"&-vertical":{flexDirection:"column"},"&-align":{flexDirection:"column","&-center":{alignItems:"center"},"&-start":{alignItems:"flex-start"},"&-end":{alignItems:"flex-end"},"&-baseline":{alignItems:"baseline"}},["".concat(t,"-item:empty")]:{display:"none"}}}},c=e=>{let{componentCls:t}=e;return{[t]:{"&-gap-row-small":{rowGap:e.spaceGapSmallSize},"&-gap-row-middle":{rowGap:e.spaceGapMiddleSize},"&-gap-row-large":{rowGap:e.spaceGapLargeSize},"&-gap-col-small":{columnGap:e.spaceGapSmallSize},"&-gap-col-middle":{columnGap:e.spaceGapMiddleSize},"&-gap-col-large":{columnGap:e.spaceGapLargeSize}}}};var l=(0,r.I$)("Space",e=>{let t=(0,o.TS)(e,{spaceGapSmallSize:e.paddingXS,spaceGapMiddleSize:e.padding,spaceGapLargeSize:e.paddingLG});return[i(t),c(t),a(t)]},()=>({}),{resetStyle:!1})},17691:function(e,t,n){"use strict";function r(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{focus:!0},{componentCls:n}=e,r="".concat(n,"-compact");return{[r]:Object.assign(Object.assign({},function(e,t,n){let{focusElCls:r,focus:o,borderElCls:a}=n,i=a?"> *":"",c=["hover",o?"focus":null,"active"].filter(Boolean).map(e=>"&:".concat(e," ").concat(i)).join(",");return{["&-item:not(".concat(t,"-last-item)")]:{marginInlineEnd:e.calc(e.lineWidth).mul(-1).equal()},"&-item":Object.assign(Object.assign({[c]:{zIndex:2}},r?{["&".concat(r)]:{zIndex:2}}:{}),{["&[disabled] ".concat(i)]:{zIndex:0}})}}(e,r,t)),function(e,t,n){let{borderElCls:r}=n,o=r?"> ".concat(r):"";return{["&-item:not(".concat(t,"-first-item):not(").concat(t,"-last-item) ").concat(o)]:{borderRadius:0},["&-item:not(".concat(t,"-last-item)").concat(t,"-first-item")]:{["& ".concat(o,", &").concat(e,"-sm ").concat(o,", &").concat(e,"-lg ").concat(o)]:{borderStartEndRadius:0,borderEndEndRadius:0}},["&-item:not(".concat(t,"-first-item)").concat(t,"-last-item")]:{["& ".concat(o,", &").concat(e,"-sm ").concat(o,", &").concat(e,"-lg ").concat(o)]:{borderStartStartRadius:0,borderEndStartRadius:0}}}}(n,r,t))}}n.d(t,{c:function(){return r}})},12918:function(e,t,n){"use strict";n.d(t,{Lx:function(){return l},Qy:function(){return d},Ro:function(){return i},Wf:function(){return a},dF:function(){return c},du:function(){return s},oN:function(){return u},vS:function(){return o}});var r=n(352);let o={overflow:"hidden",whiteSpace:"nowrap",textOverflow:"ellipsis"},a=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return{boxSizing:"border-box",margin:0,padding:0,color:e.colorText,fontSize:e.fontSize,lineHeight:e.lineHeight,listStyle:"none",fontFamily:t?"inherit":e.fontFamily}},i=()=>({display:"inline-flex",alignItems:"center",color:"inherit",fontStyle:"normal",lineHeight:0,textAlign:"center",textTransform:"none",verticalAlign:"-0.125em",textRendering:"optimizeLegibility","-webkit-font-smoothing":"antialiased","-moz-osx-font-smoothing":"grayscale","> *":{lineHeight:1},svg:{display:"inline-block"}}),c=()=>({"&::before":{display:"table",content:'""'},"&::after":{display:"table",clear:"both",content:'""'}}),l=e=>({a:{color:e.colorLink,textDecoration:e.linkDecoration,backgroundColor:"transparent",outline:"none",cursor:"pointer",transition:"color ".concat(e.motionDurationSlow),"-webkit-text-decoration-skip":"objects","&:hover":{color:e.colorLinkHover},"&:active":{color:e.colorLinkActive},"&:active,\n  &:hover":{textDecoration:e.linkHoverDecoration,outline:0},"&:focus":{textDecoration:e.linkFocusDecoration,outline:0},"&[disabled]":{color:e.colorTextDisabled,cursor:"not-allowed"}}}),s=(e,t)=>{let{fontFamily:n,fontSize:r}=e,o='[class^="'.concat(t,'"], [class*=" ').concat(t,'"]');return{[o]:{fontFamily:n,fontSize:r,boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"},[o]:{boxSizing:"border-box","&::before, &::after":{boxSizing:"border-box"}}}}},u=e=>({outline:"".concat((0,r.bf)(e.lineWidthFocus)," solid ").concat(e.colorPrimaryBorder),outlineOffset:1,transition:"outline-offset 0s, outline 0s"}),d=e=>({"&:focus-visible":Object.assign({},u(e))})},63074:function(e,t){"use strict";t.Z=e=>({[e.componentCls]:{["".concat(e.antCls,"-motion-collapse-legacy")]:{overflow:"hidden","&-active":{transition:"height ".concat(e.motionDurationMid," ").concat(e.motionEaseInOut,",\n        opacity ").concat(e.motionDurationMid," ").concat(e.motionEaseInOut," !important")}},["".concat(e.antCls,"-motion-collapse")]:{overflow:"hidden",transition:"height ".concat(e.motionDurationMid," ").concat(e.motionEaseInOut,",\n        opacity ").concat(e.motionDurationMid," ").concat(e.motionEaseInOut," !important")}}})},37133:function(e,t,n){"use strict";n.d(t,{R:function(){return a}});let r=e=>({animationDuration:e,animationFillMode:"both"}),o=e=>({animationDuration:e,animationFillMode:"both"}),a=function(e,t,n,a){let i=arguments.length>4&&void 0!==arguments[4]&&arguments[4],c=i?"&":"";return{["\n      ".concat(c).concat(e,"-enter,\n      ").concat(c).concat(e,"-appear\n    ")]:Object.assign(Object.assign({},r(a)),{animationPlayState:"paused"}),["".concat(c).concat(e,"-leave")]:Object.assign(Object.assign({},o(a)),{animationPlayState:"paused"}),["\n      ".concat(c).concat(e,"-enter").concat(e,"-enter-active,\n      ").concat(c).concat(e,"-appear").concat(e,"-appear-active\n    ")]:{animationName:t,animationPlayState:"running"},["".concat(c).concat(e,"-leave").concat(e,"-leave-active")]:{animationName:n,animationPlayState:"running",pointerEvents:"none"}}}},29382:function(e,t,n){"use strict";n.d(t,{Fm:function(){return f}});var r=n(352),o=n(37133);let a=new r.E4("antMoveDownIn",{"0%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),i=new r.E4("antMoveDownOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, 100%, 0)",transformOrigin:"0 0",opacity:0}}),c=new r.E4("antMoveLeftIn",{"0%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),l=new r.E4("antMoveLeftOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(-100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),s=new r.E4("antMoveRightIn",{"0%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),u=new r.E4("antMoveRightOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(100%, 0, 0)",transformOrigin:"0 0",opacity:0}}),d={"move-up":{inKeyframes:new r.E4("antMoveUpIn",{"0%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0},"100%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1}}),outKeyframes:new r.E4("antMoveUpOut",{"0%":{transform:"translate3d(0, 0, 0)",transformOrigin:"0 0",opacity:1},"100%":{transform:"translate3d(0, -100%, 0)",transformOrigin:"0 0",opacity:0}})},"move-down":{inKeyframes:a,outKeyframes:i},"move-left":{inKeyframes:c,outKeyframes:l},"move-right":{inKeyframes:s,outKeyframes:u}},f=(e,t)=>{let{antCls:n}=e,r="".concat(n,"-").concat(t),{inKeyframes:a,outKeyframes:i}=d[t];return[(0,o.R)(r,a,i,e.motionDurationMid),{["\n        ".concat(r,"-enter,\n        ").concat(r,"-appear\n      ")]:{opacity:0,animationTimingFunction:e.motionEaseOutCirc},["".concat(r,"-leave")]:{animationTimingFunction:e.motionEaseInOutCirc}}]}},18544:function(e,t,n){"use strict";n.d(t,{Qt:function(){return c},Uw:function(){return i},fJ:function(){return a},ly:function(){return l},oN:function(){return d}});var r=n(352),o=n(37133);let a=new r.E4("antSlideUpIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1}}),i=new r.E4("antSlideUpOut",{"0%":{transform:"scaleY(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"0% 0%",opacity:0}}),c=new r.E4("antSlideDownIn",{"0%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0},"100%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1}}),l=new r.E4("antSlideDownOut",{"0%":{transform:"scaleY(1)",transformOrigin:"100% 100%",opacity:1},"100%":{transform:"scaleY(0.8)",transformOrigin:"100% 100%",opacity:0}}),s=new r.E4("antSlideLeftIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1}}),u={"slide-up":{inKeyframes:a,outKeyframes:i},"slide-down":{inKeyframes:c,outKeyframes:l},"slide-left":{inKeyframes:s,outKeyframes:new r.E4("antSlideLeftOut",{"0%":{transform:"scaleX(1)",transformOrigin:"0% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"0% 0%",opacity:0}})},"slide-right":{inKeyframes:new r.E4("antSlideRightIn",{"0%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0},"100%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1}}),outKeyframes:new r.E4("antSlideRightOut",{"0%":{transform:"scaleX(1)",transformOrigin:"100% 0%",opacity:1},"100%":{transform:"scaleX(0.8)",transformOrigin:"100% 0%",opacity:0}})}},d=(e,t)=>{let{antCls:n}=e,r="".concat(n,"-").concat(t),{inKeyframes:a,outKeyframes:i}=u[t];return[(0,o.R)(r,a,i,e.motionDurationMid),{["\n      ".concat(r,"-enter,\n      ").concat(r,"-appear\n    ")]:{transform:"scale(0)",transformOrigin:"0% 0%",opacity:0,animationTimingFunction:e.motionEaseOutQuint,"&-prepare":{transform:"scale(1)"}},["".concat(r,"-leave")]:{animationTimingFunction:e.motionEaseInQuint}}]}},691:function(e,t,n){"use strict";n.d(t,{_y:function(){return g},kr:function(){return a}});var r=n(352),o=n(37133);let a=new r.E4("antZoomIn",{"0%":{transform:"scale(0.2)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),i=new r.E4("antZoomOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.2)",opacity:0}}),c=new r.E4("antZoomBigIn",{"0%":{transform:"scale(0.8)",opacity:0},"100%":{transform:"scale(1)",opacity:1}}),l=new r.E4("antZoomBigOut",{"0%":{transform:"scale(1)"},"100%":{transform:"scale(0.8)",opacity:0}}),s=new r.E4("antZoomUpIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 0%"}}),u=new r.E4("antZoomUpOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 0%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 0%",opacity:0}}),d=new r.E4("antZoomLeftIn",{"0%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"0% 50%"}}),f=new r.E4("antZoomLeftOut",{"0%":{transform:"scale(1)",transformOrigin:"0% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"0% 50%",opacity:0}}),p=new r.E4("antZoomRightIn",{"0%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"100% 50%"}}),m={zoom:{inKeyframes:a,outKeyframes:i},"zoom-big":{inKeyframes:c,outKeyframes:l},"zoom-big-fast":{inKeyframes:c,outKeyframes:l},"zoom-left":{inKeyframes:d,outKeyframes:f},"zoom-right":{inKeyframes:p,outKeyframes:new r.E4("antZoomRightOut",{"0%":{transform:"scale(1)",transformOrigin:"100% 50%"},"100%":{transform:"scale(0.8)",transformOrigin:"100% 50%",opacity:0}})},"zoom-up":{inKeyframes:s,outKeyframes:u},"zoom-down":{inKeyframes:new r.E4("antZoomDownIn",{"0%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0},"100%":{transform:"scale(1)",transformOrigin:"50% 100%"}}),outKeyframes:new r.E4("antZoomDownOut",{"0%":{transform:"scale(1)",transformOrigin:"50% 100%"},"100%":{transform:"scale(0.8)",transformOrigin:"50% 100%",opacity:0}})}},g=(e,t)=>{let{antCls:n}=e,r="".concat(n,"-").concat(t),{inKeyframes:a,outKeyframes:i}=m[t];return[(0,o.R)(r,a,i,"zoom-big-fast"===t?e.motionDurationFast:e.motionDurationMid),{["\n        ".concat(r,"-enter,\n        ").concat(r,"-appear\n      ")]:{transform:"scale(0)",opacity:0,animationTimingFunction:e.motionEaseOutCirc,"&-prepare":{transform:"none"}},["".concat(r,"-leave")]:{animationTimingFunction:e.motionEaseInOutCirc}}]}},88260:function(e,t,n){"use strict";n.d(t,{ZP:function(){return i},qN:function(){return o},wZ:function(){return a}});var r=n(34442);let o=8;function a(e){let{contentRadius:t,limitVerticalRadius:n}=e,r=t>12?t+2:12;return{arrowOffsetHorizontal:r,arrowOffsetVertical:n?o:r}}function i(e,t,n){var o,a,i,c,l,s,u,d;let{componentCls:f,boxShadowPopoverArrow:p,arrowOffsetVertical:m,arrowOffsetHorizontal:g}=e,{arrowDistance:h=0,arrowPlacement:v={left:!0,right:!0,top:!0,bottom:!0}}=n||{};return{[f]:Object.assign(Object.assign(Object.assign(Object.assign({["".concat(f,"-arrow")]:[Object.assign(Object.assign({position:"absolute",zIndex:1,display:"block"},(0,r.W)(e,t,p)),{"&:before":{background:t}})]},(o=!!v.top,a={[["&-placement-top > ".concat(f,"-arrow"),"&-placement-topLeft > ".concat(f,"-arrow"),"&-placement-topRight > ".concat(f,"-arrow")].join(",")]:{bottom:h,transform:"translateY(100%) rotate(180deg)"},["&-placement-top > ".concat(f,"-arrow")]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(100%) rotate(180deg)"},["&-placement-topLeft > ".concat(f,"-arrow")]:{left:{_skip_check_:!0,value:g}},["&-placement-topRight > ".concat(f,"-arrow")]:{right:{_skip_check_:!0,value:g}}},o?a:{})),(i=!!v.bottom,c={[["&-placement-bottom > ".concat(f,"-arrow"),"&-placement-bottomLeft > ".concat(f,"-arrow"),"&-placement-bottomRight > ".concat(f,"-arrow")].join(",")]:{top:h,transform:"translateY(-100%)"},["&-placement-bottom > ".concat(f,"-arrow")]:{left:{_skip_check_:!0,value:"50%"},transform:"translateX(-50%) translateY(-100%)"},["&-placement-bottomLeft > ".concat(f,"-arrow")]:{left:{_skip_check_:!0,value:g}},["&-placement-bottomRight > ".concat(f,"-arrow")]:{right:{_skip_check_:!0,value:g}}},i?c:{})),(l=!!v.left,s={[["&-placement-left > ".concat(f,"-arrow"),"&-placement-leftTop > ".concat(f,"-arrow"),"&-placement-leftBottom > ".concat(f,"-arrow")].join(",")]:{right:{_skip_check_:!0,value:h},transform:"translateX(100%) rotate(90deg)"},["&-placement-left > ".concat(f,"-arrow")]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(100%) rotate(90deg)"},["&-placement-leftTop > ".concat(f,"-arrow")]:{top:m},["&-placement-leftBottom > ".concat(f,"-arrow")]:{bottom:m}},l?s:{})),(u=!!v.right,d={[["&-placement-right > ".concat(f,"-arrow"),"&-placement-rightTop > ".concat(f,"-arrow"),"&-placement-rightBottom > ".concat(f,"-arrow")].join(",")]:{left:{_skip_check_:!0,value:h},transform:"translateX(-100%) rotate(-90deg)"},["&-placement-right > ".concat(f,"-arrow")]:{top:{_skip_check_:!0,value:"50%"},transform:"translateY(-50%) translateX(-100%) rotate(-90deg)"},["&-placement-rightTop > ".concat(f,"-arrow")]:{top:m},["&-placement-rightBottom > ".concat(f,"-arrow")]:{bottom:m}},u?d:{}))}}},34442:function(e,t,n){"use strict";n.d(t,{W:function(){return a},w:function(){return o}});var r=n(352);function o(e){let{sizePopupArrow:t,borderRadiusXS:n,borderRadiusOuter:r}=e,o=t/2,a=1*r/Math.sqrt(2),i=o-r*(1-1/Math.sqrt(2)),c=o-1/Math.sqrt(2)*n,l=r*(Math.sqrt(2)-1)+1/Math.sqrt(2)*n,s=2*o-c,u=2*o-a,d=2*o-0,f=o*Math.sqrt(2)+r*(Math.sqrt(2)-2),p=r*(Math.sqrt(2)-1),m="polygon(".concat(p,"px 100%, 50% ").concat(p,"px, ").concat(2*o-p,"px 100%, ").concat(p,"px 100%)");return{arrowShadowWidth:f,arrowPath:"path('M ".concat(0," ").concat(o," A ").concat(r," ").concat(r," 0 0 0 ").concat(a," ").concat(i," L ").concat(c," ").concat(l," A ").concat(n," ").concat(n," 0 0 1 ").concat(s," ").concat(l," L ").concat(u," ").concat(i," A ").concat(r," ").concat(r," 0 0 0 ").concat(d," ").concat(o," Z')"),arrowPolygon:m}}let a=(e,t,n)=>{let{sizePopupArrow:o,arrowPolygon:a,arrowPath:i,arrowShadowWidth:c,borderRadiusXS:l,calc:s}=e;return{pointerEvents:"none",width:o,height:o,overflow:"hidden","&::before":{position:"absolute",bottom:0,insetInlineStart:0,width:o,height:s(o).div(2).equal(),background:t,clipPath:{_multi_value_:!0,value:[a,i]},content:'""'},"&::after":{content:'""',position:"absolute",width:c,height:c,bottom:0,insetInline:0,margin:"auto",borderRadius:{_skip_check_:!0,value:"0 0 ".concat((0,r.bf)(l)," 0")},transform:"translateY(50%) rotate(-135deg)",boxShadow:n,zIndex:0,background:"transparent"}}}},37516:function(e,t,n){"use strict";n.d(t,{Mj:function(){return b},u_:function(){return v},uH:function(){return h}});var r=n(2265),o=n(352),a=n(31373),i=e=>{let{controlHeight:t}=e;return{controlHeightSM:.75*t,controlHeightXS:.5*t,controlHeightLG:1.25*t}},c=n(70774),l=n(36360),s=e=>{let t=e,n=e,r=e,o=e;return e<6&&e>=5?t=e+1:e<16&&e>=6?t=e+2:e>=16&&(t=16),e<7&&e>=5?n=4:e<8&&e>=7?n=5:e<14&&e>=8?n=6:e<16&&e>=14?n=7:e>=16&&(n=8),e<6&&e>=2?r=1:e>=6&&(r=2),e>4&&e<8?o=4:e>=8&&(o=6),{borderRadius:e,borderRadiusXS:r,borderRadiusSM:n,borderRadiusLG:t,borderRadiusOuter:o}};let u=(e,t)=>new l.C(e).setAlpha(t).toRgbString(),d=(e,t)=>new l.C(e).darken(t).toHexString(),f=e=>{let t=(0,a.R_)(e);return{1:t[0],2:t[1],3:t[2],4:t[3],5:t[4],6:t[5],7:t[6],8:t[4],9:t[5],10:t[6]}},p=(e,t)=>{let n=e||"#fff",r=t||"#000";return{colorBgBase:n,colorTextBase:r,colorText:u(r,.88),colorTextSecondary:u(r,.65),colorTextTertiary:u(r,.45),colorTextQuaternary:u(r,.25),colorFill:u(r,.15),colorFillSecondary:u(r,.06),colorFillTertiary:u(r,.04),colorFillQuaternary:u(r,.02),colorBgLayout:d(n,4),colorBgContainer:d(n,0),colorBgElevated:d(n,0),colorBgSpotlight:u(r,.85),colorBgBlur:"transparent",colorBorder:d(n,15),colorBorderSecondary:d(n,6)}};var m=n(1319),g=e=>{let t=(0,m.Z)(e),n=t.map(e=>e.size),r=t.map(e=>e.lineHeight),o=n[1],a=n[0],i=n[2],c=r[1],l=r[0],s=r[2];return{fontSizeSM:a,fontSize:o,fontSizeLG:i,fontSizeXL:n[3],fontSizeHeading1:n[6],fontSizeHeading2:n[5],fontSizeHeading3:n[4],fontSizeHeading4:n[3],fontSizeHeading5:n[2],lineHeight:c,lineHeightLG:s,lineHeightSM:l,fontHeight:Math.round(c*o),fontHeightLG:Math.round(s*i),fontHeightSM:Math.round(l*a),lineHeightHeading1:r[6],lineHeightHeading2:r[5],lineHeightHeading3:r[4],lineHeightHeading4:r[3],lineHeightHeading5:r[2]}};let h=(0,o.jG)(function(e){let t=Object.keys(c.M).map(t=>{let n=(0,a.R_)(e[t]);return Array(10).fill(1).reduce((e,r,o)=>(e["".concat(t,"-").concat(o+1)]=n[o],e["".concat(t).concat(o+1)]=n[o],e),{})}).reduce((e,t)=>e=Object.assign(Object.assign({},e),t),{});return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},e),t),function(e,t){let{generateColorPalettes:n,generateNeutralColorPalettes:r}=t,{colorSuccess:o,colorWarning:a,colorError:i,colorInfo:c,colorPrimary:s,colorBgBase:u,colorTextBase:d}=e,f=n(s),p=n(o),m=n(a),g=n(i),h=n(c),v=r(u,d),b=n(e.colorLink||e.colorInfo);return Object.assign(Object.assign({},v),{colorPrimaryBg:f[1],colorPrimaryBgHover:f[2],colorPrimaryBorder:f[3],colorPrimaryBorderHover:f[4],colorPrimaryHover:f[5],colorPrimary:f[6],colorPrimaryActive:f[7],colorPrimaryTextHover:f[8],colorPrimaryText:f[9],colorPrimaryTextActive:f[10],colorSuccessBg:p[1],colorSuccessBgHover:p[2],colorSuccessBorder:p[3],colorSuccessBorderHover:p[4],colorSuccessHover:p[4],colorSuccess:p[6],colorSuccessActive:p[7],colorSuccessTextHover:p[8],colorSuccessText:p[9],colorSuccessTextActive:p[10],colorErrorBg:g[1],colorErrorBgHover:g[2],colorErrorBorder:g[3],colorErrorBorderHover:g[4],colorErrorHover:g[5],colorError:g[6],colorErrorActive:g[7],colorErrorTextHover:g[8],colorErrorText:g[9],colorErrorTextActive:g[10],colorWarningBg:m[1],colorWarningBgHover:m[2],colorWarningBorder:m[3],colorWarningBorderHover:m[4],colorWarningHover:m[4],colorWarning:m[6],colorWarningActive:m[7],colorWarningTextHover:m[8],colorWarningText:m[9],colorWarningTextActive:m[10],colorInfoBg:h[1],colorInfoBgHover:h[2],colorInfoBorder:h[3],colorInfoBorderHover:h[4],colorInfoHover:h[4],colorInfo:h[6],colorInfoActive:h[7],colorInfoTextHover:h[8],colorInfoText:h[9],colorInfoTextActive:h[10],colorLinkHover:b[4],colorLink:b[6],colorLinkActive:b[7],colorBgMask:new l.C("#000").setAlpha(.45).toRgbString(),colorWhite:"#fff"})}(e,{generateColorPalettes:f,generateNeutralColorPalettes:p})),g(e.fontSize)),function(e){let{sizeUnit:t,sizeStep:n}=e;return{sizeXXL:t*(n+8),sizeXL:t*(n+4),sizeLG:t*(n+2),sizeMD:t*(n+1),sizeMS:t*n,size:t*n,sizeSM:t*(n-1),sizeXS:t*(n-2),sizeXXS:t*(n-3)}}(e)),i(e)),function(e){let{motionUnit:t,motionBase:n,borderRadius:r,lineWidth:o}=e;return Object.assign({motionDurationFast:"".concat((n+t).toFixed(1),"s"),motionDurationMid:"".concat((n+2*t).toFixed(1),"s"),motionDurationSlow:"".concat((n+3*t).toFixed(1),"s"),lineWidthBold:o+1},s(r))}(e))}),v={token:c.Z,override:{override:c.Z},hashed:!0},b=r.createContext(v)},53454:function(e,t,n){"use strict";n.d(t,{i:function(){return r}});let r=["blue","purple","cyan","green","magenta","pink","red","orange","yellow","volcano","geekblue","lime","gold"]},70774:function(e,t,n){"use strict";n.d(t,{M:function(){return r}});let r={blue:"#1677ff",purple:"#722ED1",cyan:"#13C2C2",green:"#52C41A",magenta:"#EB2F96",pink:"#eb2f96",red:"#F5222D",orange:"#FA8C16",yellow:"#FADB14",volcano:"#FA541C",geekblue:"#2F54EB",gold:"#FAAD14",lime:"#A0D911"},o=Object.assign(Object.assign({},r),{colorPrimary:"#1677ff",colorSuccess:"#52c41a",colorWarning:"#faad14",colorError:"#ff4d4f",colorInfo:"#1677ff",colorLink:"",colorTextBase:"",colorBgBase:"",fontFamily:"-apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial,\n'Noto Sans', sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol',\n'Noto Color Emoji'",fontFamilyCode:"'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, Courier, monospace",fontSize:14,lineWidth:1,lineType:"solid",motionUnit:.1,motionBase:0,motionEaseOutCirc:"cubic-bezier(0.08, 0.82, 0.17, 1)",motionEaseInOutCirc:"cubic-bezier(0.78, 0.14, 0.15, 0.86)",motionEaseOut:"cubic-bezier(0.215, 0.61, 0.355, 1)",motionEaseInOut:"cubic-bezier(0.645, 0.045, 0.355, 1)",motionEaseOutBack:"cubic-bezier(0.12, 0.4, 0.29, 1.46)",motionEaseInBack:"cubic-bezier(0.71, -0.46, 0.88, 0.6)",motionEaseInQuint:"cubic-bezier(0.755, 0.05, 0.855, 0.06)",motionEaseOutQuint:"cubic-bezier(0.23, 1, 0.32, 1)",borderRadius:6,sizeUnit:4,sizeStep:4,sizePopupArrow:16,controlHeight:32,zIndexBase:0,zIndexPopupBase:1e3,opacityImage:1,wireframe:!1,motion:!0});t.Z=o},1319:function(e,t,n){"use strict";function r(e){return(e+8)/e}function o(e){let t=Array(10).fill(null).map((t,n)=>{let r=e*Math.pow(2.71828,(n-1)/5);return 2*Math.floor((n>1?Math.floor(r):Math.ceil(r))/2)});return t[1]=e,t.map(e=>({size:e,lineHeight:r(e)}))}n.d(t,{D:function(){return r},Z:function(){return o}})},29961:function(e,t,n){"use strict";n.d(t,{ZP:function(){return v},ID:function(){return m},NJ:function(){return p}});var r=n(2265),o=n(352),a=n(37516),i=n(70774),c=n(36360);function l(e){return e>=0&&e<=255}var s=function(e,t){let{r:n,g:r,b:o,a:a}=new c.C(e).toRgb();if(a<1)return e;let{r:i,g:s,b:u}=new c.C(t).toRgb();for(let e=.01;e<=1;e+=.01){let t=Math.round((n-i*(1-e))/e),a=Math.round((r-s*(1-e))/e),d=Math.round((o-u*(1-e))/e);if(l(t)&&l(a)&&l(d))return new c.C({r:t,g:a,b:d,a:Math.round(100*e)/100}).toRgbString()}return new c.C({r:n,g:r,b:o,a:1}).toRgbString()},u=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};function d(e){let{override:t}=e,n=u(e,["override"]),r=Object.assign({},t);Object.keys(i.Z).forEach(e=>{delete r[e]});let o=Object.assign(Object.assign({},n),r);return!1===o.motion&&(o.motionDurationFast="0s",o.motionDurationMid="0s",o.motionDurationSlow="0s"),Object.assign(Object.assign(Object.assign({},o),{colorFillContent:o.colorFillSecondary,colorFillContentHover:o.colorFill,colorFillAlter:o.colorFillQuaternary,colorBgContainerDisabled:o.colorFillTertiary,colorBorderBg:o.colorBgContainer,colorSplit:s(o.colorBorderSecondary,o.colorBgContainer),colorTextPlaceholder:o.colorTextQuaternary,colorTextDisabled:o.colorTextQuaternary,colorTextHeading:o.colorText,colorTextLabel:o.colorTextSecondary,colorTextDescription:o.colorTextTertiary,colorTextLightSolid:o.colorWhite,colorHighlight:o.colorError,colorBgTextHover:o.colorFillSecondary,colorBgTextActive:o.colorFill,colorIcon:o.colorTextTertiary,colorIconHover:o.colorText,colorErrorOutline:s(o.colorErrorBg,o.colorBgContainer),colorWarningOutline:s(o.colorWarningBg,o.colorBgContainer),fontSizeIcon:o.fontSizeSM,lineWidthFocus:4*o.lineWidth,lineWidth:o.lineWidth,controlOutlineWidth:2*o.lineWidth,controlInteractiveSize:o.controlHeight/2,controlItemBgHover:o.colorFillTertiary,controlItemBgActive:o.colorPrimaryBg,controlItemBgActiveHover:o.colorPrimaryBgHover,controlItemBgActiveDisabled:o.colorFill,controlTmpOutline:o.colorFillQuaternary,controlOutline:s(o.colorPrimaryBg,o.colorBgContainer),lineType:o.lineType,borderRadius:o.borderRadius,borderRadiusXS:o.borderRadiusXS,borderRadiusSM:o.borderRadiusSM,borderRadiusLG:o.borderRadiusLG,fontWeightStrong:600,opacityLoading:.65,linkDecoration:"none",linkHoverDecoration:"none",linkFocusDecoration:"none",controlPaddingHorizontal:12,controlPaddingHorizontalSM:8,paddingXXS:o.sizeXXS,paddingXS:o.sizeXS,paddingSM:o.sizeSM,padding:o.size,paddingMD:o.sizeMD,paddingLG:o.sizeLG,paddingXL:o.sizeXL,paddingContentHorizontalLG:o.sizeLG,paddingContentVerticalLG:o.sizeMS,paddingContentHorizontal:o.sizeMS,paddingContentVertical:o.sizeSM,paddingContentHorizontalSM:o.size,paddingContentVerticalSM:o.sizeXS,marginXXS:o.sizeXXS,marginXS:o.sizeXS,marginSM:o.sizeSM,margin:o.size,marginMD:o.sizeMD,marginLG:o.sizeLG,marginXL:o.sizeXL,marginXXL:o.sizeXXL,boxShadow:"\n      0 6px 16px 0 rgba(0, 0, 0, 0.08),\n      0 3px 6px -4px rgba(0, 0, 0, 0.12),\n      0 9px 28px 8px rgba(0, 0, 0, 0.05)\n    ",boxShadowSecondary:"\n      0 6px 16px 0 rgba(0, 0, 0, 0.08),\n      0 3px 6px -4px rgba(0, 0, 0, 0.12),\n      0 9px 28px 8px rgba(0, 0, 0, 0.05)\n    ",boxShadowTertiary:"\n      0 1px 2px 0 rgba(0, 0, 0, 0.03),\n      0 1px 6px -1px rgba(0, 0, 0, 0.02),\n      0 2px 4px 0 rgba(0, 0, 0, 0.02)\n    ",screenXS:480,screenXSMin:480,screenXSMax:575,screenSM:576,screenSMMin:576,screenSMMax:767,screenMD:768,screenMDMin:768,screenMDMax:991,screenLG:992,screenLGMin:992,screenLGMax:1199,screenXL:1200,screenXLMin:1200,screenXLMax:1599,screenXXL:1600,screenXXLMin:1600,boxShadowPopoverArrow:"2px 2px 5px rgba(0, 0, 0, 0.05)",boxShadowCard:"\n      0 1px 2px -2px ".concat(new c.C("rgba(0, 0, 0, 0.16)").toRgbString(),",\n      0 3px 6px 0 ").concat(new c.C("rgba(0, 0, 0, 0.12)").toRgbString(),",\n      0 5px 12px 4px ").concat(new c.C("rgba(0, 0, 0, 0.09)").toRgbString(),"\n    "),boxShadowDrawerRight:"\n      -6px 0 16px 0 rgba(0, 0, 0, 0.08),\n      -3px 0 6px -4px rgba(0, 0, 0, 0.12),\n      -9px 0 28px 8px rgba(0, 0, 0, 0.05)\n    ",boxShadowDrawerLeft:"\n      6px 0 16px 0 rgba(0, 0, 0, 0.08),\n      3px 0 6px -4px rgba(0, 0, 0, 0.12),\n      9px 0 28px 8px rgba(0, 0, 0, 0.05)\n    ",boxShadowDrawerUp:"\n      0 6px 16px 0 rgba(0, 0, 0, 0.08),\n      0 3px 6px -4px rgba(0, 0, 0, 0.12),\n      0 9px 28px 8px rgba(0, 0, 0, 0.05)\n    ",boxShadowDrawerDown:"\n      0 -6px 16px 0 rgba(0, 0, 0, 0.08),\n      0 -3px 6px -4px rgba(0, 0, 0, 0.12),\n      0 -9px 28px 8px rgba(0, 0, 0, 0.05)\n    ",boxShadowTabsOverflowLeft:"inset 10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowRight:"inset -10px 0 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowTop:"inset 0 10px 8px -8px rgba(0, 0, 0, 0.08)",boxShadowTabsOverflowBottom:"inset 0 -10px 8px -8px rgba(0, 0, 0, 0.08)"}),r)}var f=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let p={lineHeight:!0,lineHeightSM:!0,lineHeightLG:!0,lineHeightHeading1:!0,lineHeightHeading2:!0,lineHeightHeading3:!0,lineHeightHeading4:!0,lineHeightHeading5:!0,opacityLoading:!0,fontWeightStrong:!0,zIndexPopupBase:!0,zIndexBase:!0},m={size:!0,sizeSM:!0,sizeLG:!0,sizeMD:!0,sizeXS:!0,sizeXXS:!0,sizeMS:!0,sizeXL:!0,sizeXXL:!0,sizeUnit:!0,sizeStep:!0,motionBase:!0,motionUnit:!0},g={screenXS:!0,screenXSMin:!0,screenXSMax:!0,screenSM:!0,screenSMMin:!0,screenSMMax:!0,screenMD:!0,screenMDMin:!0,screenMDMax:!0,screenLG:!0,screenLGMin:!0,screenLGMax:!0,screenXL:!0,screenXLMin:!0,screenXLMax:!0,screenXXL:!0,screenXXLMin:!0},h=(e,t,n)=>{let r=n.getDerivativeToken(e),{override:o}=t,a=f(t,["override"]),i=Object.assign(Object.assign({},r),{override:o});return i=d(i),a&&Object.entries(a).forEach(e=>{let[t,n]=e,{theme:r}=n,o=f(n,["theme"]),a=o;r&&(a=h(Object.assign(Object.assign({},i),o),{override:o},r)),i[t]=a}),i};function v(){let{token:e,hashed:t,theme:n,override:c,cssVar:l}=r.useContext(a.Mj),s="".concat("5.13.2","-").concat(t||""),u=n||a.uH,[f,v,b]=(0,o.fp)(u,[i.Z,e],{salt:s,override:c,getComputedToken:h,formatToken:d,cssVar:l&&{prefix:l.prefix,key:l.key,unitless:p,ignore:m,preserve:g}});return[u,b,t?v:"",f,l]}},80669:function(e,t,n){"use strict";n.d(t,{ZP:function(){return Z},I$:function(){return M},bk:function(){return O}});var r=n(2265),o=n(352);n(74126);var a=n(71744),i=n(12918),c=n(29961),l=n(76405),s=n(25049),u=n(37977),d=n(63929),f=n(24995),p=n(15354);let m=(0,s.Z)(function e(){(0,l.Z)(this,e)}),g=function(e){function t(e){var n,r,o;return(0,l.Z)(this,t),r=t,r=(0,f.Z)(r),(n=(0,u.Z)(this,(0,d.Z)()?Reflect.construct(r,[],(0,f.Z)(this).constructor):r.apply(this,o))).result=0,e instanceof t?n.result=e.result:"number"==typeof e&&(n.result=e),n}return(0,p.Z)(t,e),(0,s.Z)(t,[{key:"add",value:function(e){return e instanceof t?this.result+=e.result:"number"==typeof e&&(this.result+=e),this}},{key:"sub",value:function(e){return e instanceof t?this.result-=e.result:"number"==typeof e&&(this.result-=e),this}},{key:"mul",value:function(e){return e instanceof t?this.result*=e.result:"number"==typeof e&&(this.result*=e),this}},{key:"div",value:function(e){return e instanceof t?this.result/=e.result:"number"==typeof e&&(this.result/=e),this}},{key:"equal",value:function(){return this.result}}]),t}(m),h="CALC_UNIT";function v(e){return"number"==typeof e?"".concat(e).concat(h):e}let b=function(e){function t(e){var n,r,o;return(0,l.Z)(this,t),r=t,r=(0,f.Z)(r),(n=(0,u.Z)(this,(0,d.Z)()?Reflect.construct(r,[],(0,f.Z)(this).constructor):r.apply(this,o))).result="",e instanceof t?n.result="(".concat(e.result,")"):"number"==typeof e?n.result=v(e):"string"==typeof e&&(n.result=e),n}return(0,p.Z)(t,e),(0,s.Z)(t,[{key:"add",value:function(e){return e instanceof t?this.result="".concat(this.result," + ").concat(e.getResult()):("number"==typeof e||"string"==typeof e)&&(this.result="".concat(this.result," + ").concat(v(e))),this.lowPriority=!0,this}},{key:"sub",value:function(e){return e instanceof t?this.result="".concat(this.result," - ").concat(e.getResult()):("number"==typeof e||"string"==typeof e)&&(this.result="".concat(this.result," - ").concat(v(e))),this.lowPriority=!0,this}},{key:"mul",value:function(e){return this.lowPriority&&(this.result="(".concat(this.result,")")),e instanceof t?this.result="".concat(this.result," * ").concat(e.getResult(!0)):("number"==typeof e||"string"==typeof e)&&(this.result="".concat(this.result," * ").concat(e)),this.lowPriority=!1,this}},{key:"div",value:function(e){return this.lowPriority&&(this.result="(".concat(this.result,")")),e instanceof t?this.result="".concat(this.result," / ").concat(e.getResult(!0)):("number"==typeof e||"string"==typeof e)&&(this.result="".concat(this.result," / ").concat(e)),this.lowPriority=!1,this}},{key:"getResult",value:function(e){return this.lowPriority||e?"(".concat(this.result,")"):this.result}},{key:"equal",value:function(e){let{unit:t=!0}=e||{},n=RegExp("".concat(h),"g");return(this.result=this.result.replace(n,t?"px":""),void 0!==this.lowPriority)?"calc(".concat(this.result,")"):this.result}}]),t}(m);var y=e=>{let t="css"===e?b:g;return e=>new t(e)},x=n(3104),w=n(36198);let E=(e,t,n)=>{var r;return"function"==typeof n?n((0,x.TS)(t,null!==(r=t[e])&&void 0!==r?r:{})):null!=n?n:{}},S=(e,t,n,r)=>{let o=Object.assign({},t[e]);if(null==r?void 0:r.deprecatedTokens){let{deprecatedTokens:e}=r;e.forEach(e=>{var t;let[n,r]=e;((null==o?void 0:o[n])||(null==o?void 0:o[r]))&&(null!==(t=o[r])&&void 0!==t||(o[r]=null==o?void 0:o[n]))})}let a=Object.assign(Object.assign({},n),o);return Object.keys(a).forEach(e=>{a[e]===t[e]&&delete a[e]}),a},C=(e,t)=>"".concat([t,e.replace(/([A-Z]+)([A-Z][a-z]+)/g,"$1-$2").replace(/([a-z])([A-Z])/g,"$1-$2")].filter(Boolean).join("-"));function Z(e,t,n){let l=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},s=Array.isArray(e)?e:[e,e],[u]=s,d=s.join("-");return e=>{let[s,f,p,m,g]=(0,c.ZP)(),{getPrefixCls:h,iconPrefixCls:v,csp:b}=(0,r.useContext)(a.E_),Z=h(),O=g?"css":"js",k=y(O),{max:M,min:R}="js"===O?{max:Math.max,min:Math.min}:{max:function(){for(var e=arguments.length,t=Array(e),n=0;n(0,o.bf)(e)).join(","),")")},min:function(){for(var e=arguments.length,t=Array(e),n=0;n(0,o.bf)(e)).join(","),")")}},j={theme:s,token:m,hashId:p,nonce:()=>null==b?void 0:b.nonce,clientOnly:l.clientOnly,order:l.order||-999};return(0,o.xy)(Object.assign(Object.assign({},j),{clientOnly:!1,path:["Shared",Z]}),()=>[{"&":(0,i.Lx)(m)}]),(0,w.Z)(v,b),[(0,o.xy)(Object.assign(Object.assign({},j),{path:[d,e,v]}),()=>{if(!1===l.injectStyle)return[];let{token:r,flush:a}=(0,x.ZP)(m),c=E(u,f,n),s=".".concat(e),d=S(u,f,c,{deprecatedTokens:l.deprecatedTokens});g&&Object.keys(c).forEach(e=>{c[e]="var(".concat((0,o.ks)(e,C(u,g.prefix)),")")});let h=(0,x.TS)(r,{componentCls:s,prefixCls:e,iconCls:".".concat(v),antCls:".".concat(Z),calc:k,max:M,min:R},g?c:d),b=t(h,{hashId:p,prefixCls:e,rootPrefixCls:Z,iconPrefixCls:v});return a(u,d),[!1===l.resetStyle?null:(0,i.du)(h,e),b]}),p]}}let O=(e,t,n,r)=>{let o=Z(e,t,n,Object.assign({resetStyle:!1,order:-998},r));return e=>{let{prefixCls:t}=e;return o(t),null}},k=(e,t,n)=>{function a(t){return"".concat(e).concat(t.slice(0,1).toUpperCase()).concat(t.slice(1))}let{unitless:i={},injectStyle:l=!0}=null!=n?n:{},s={[a("zIndexPopup")]:!0};Object.keys(i).forEach(e=>{s[a(e)]=i[e]});let u=r=>{let{rootCls:i,cssVar:l}=r,[,u]=(0,c.ZP)();return(0,o.CI)({path:[e],prefix:l.prefix,key:null==l?void 0:l.key,unitless:Object.assign(Object.assign({},c.NJ),s),ignore:c.ID,token:u,scope:i},()=>{let r=E(e,u,t),o=S(e,u,r,{deprecatedTokens:null==n?void 0:n.deprecatedTokens});return Object.keys(r).forEach(e=>{o[a(e)]=o[e],delete o[e]}),o}),null};return t=>{let[,,,,n]=(0,c.ZP)();return[o=>l&&n?r.createElement(r.Fragment,null,r.createElement(u,{rootCls:t,cssVar:n,component:e}),o):o,null==n?void 0:n.key]}},M=(e,t,n,r)=>{let o=Z(e,t,n,r),a=k(Array.isArray(e)?e[0]:e,n,r);return function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,[,n]=o(e),[r,i]=a(t);return[r,n,i]}}},18536:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(53454);function o(e,t){return r.i.reduce((n,r)=>{let o=e["".concat(r,"1")],a=e["".concat(r,"3")],i=e["".concat(r,"6")],c=e["".concat(r,"7")];return Object.assign(Object.assign({},n),t(r,{lightColor:o,lightBorderColor:a,darkColor:i,textColor:c}))},{})}},3104:function(e,t,n){"use strict";n.d(t,{TS:function(){return a}});let r="undefined"!=typeof CSSINJS_STATISTIC,o=!0;function a(){for(var e=arguments.length,t=Array(e),n=0;n{Object.keys(e).forEach(t=>{Object.defineProperty(a,t,{configurable:!0,enumerable:!0,get:()=>e[t]})})}),o=!0,a}let i={};function c(){}t.ZP=e=>{let t;let n=e,a=c;return r&&"undefined"!=typeof Proxy&&(t=new Set,n=new Proxy(e,{get:(e,n)=>(o&&t.add(n),e[n])}),a=(e,n)=>{var r;i[e]={global:Array.from(t),component:Object.assign(Object.assign({},null===(r=i[e])||void 0===r?void 0:r.component),n)}}),{token:n,keys:t,flush:a}}},36198:function(e,t,n){"use strict";var r=n(352),o=n(12918),a=n(29961);t.Z=(e,t)=>{let[n,i]=(0,a.ZP)();return(0,r.xy)({theme:n,token:i,hashId:"",path:["ant-design-icons",e],nonce:()=>null==t?void 0:t.nonce},()=>[{[".".concat(e)]:Object.assign(Object.assign({},(0,o.Ro)()),{[".".concat(e," .").concat(e,"-icon")]:{display:"block"}})}])}},89970:function(e,t,n){"use strict";n.d(t,{Z:function(){return N}});var r=n(2265),o=n(36760),a=n.n(o),i=n(5769),c=n(50506),l=n(62236),s=n(68710),u=n(92736),d=n(19722),f=n(13613),p=n(95140),m=n(71744),g=n(65658),h=n(29961),v=n(12918),b=n(691),y=n(88260),x=n(18536),w=n(3104),E=n(80669),S=n(352),C=n(34442);let Z=e=>{let{componentCls:t,tooltipMaxWidth:n,tooltipColor:r,tooltipBg:o,tooltipBorderRadius:a,zIndexPopup:i,controlHeight:c,boxShadowSecondary:l,paddingSM:s,paddingXS:u}=e;return[{[t]:Object.assign(Object.assign(Object.assign(Object.assign({},(0,v.Wf)(e)),{position:"absolute",zIndex:i,display:"block",width:"max-content",maxWidth:n,visibility:"visible",transformOrigin:"var(--arrow-x, 50%) var(--arrow-y, 50%)","&-hidden":{display:"none"},"--antd-arrow-background-color":o,["".concat(t,"-inner")]:{minWidth:c,minHeight:c,padding:"".concat((0,S.bf)(e.calc(s).div(2).equal())," ").concat((0,S.bf)(u)),color:r,textAlign:"start",textDecoration:"none",wordWrap:"break-word",backgroundColor:o,borderRadius:a,boxShadow:l,boxSizing:"border-box"},"&-placement-left,&-placement-leftTop,&-placement-leftBottom,&-placement-right,&-placement-rightTop,&-placement-rightBottom":{["".concat(t,"-inner")]:{borderRadius:e.min(a,y.qN)}},["".concat(t,"-content")]:{position:"relative"}}),(0,x.Z)(e,(e,n)=>{let{darkColor:r}=n;return{["&".concat(t,"-").concat(e)]:{["".concat(t,"-inner")]:{backgroundColor:r},["".concat(t,"-arrow")]:{"--antd-arrow-background-color":r}}}})),{"&-rtl":{direction:"rtl"}})},(0,y.ZP)(e,"var(--antd-arrow-background-color)"),{["".concat(t,"-pure")]:{position:"relative",maxWidth:"none",margin:e.sizePopupArrow}}]},O=e=>Object.assign(Object.assign({zIndexPopup:e.zIndexPopupBase+70},(0,y.wZ)({contentRadius:e.borderRadius,limitVerticalRadius:!0})),(0,C.w)((0,w.TS)(e,{borderRadiusOuter:Math.min(e.borderRadiusOuter,4)})));function k(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return(0,E.I$)("Tooltip",e=>{let{borderRadius:t,colorTextLightSolid:n,colorBgSpotlight:r}=e;return[Z((0,w.TS)(e,{tooltipMaxWidth:250,tooltipColor:n,tooltipBorderRadius:t,tooltipBg:r})),(0,b._y)(e,"zoom-big-fast")]},O,{resetStyle:!1,injectStyle:t})(e)}var M=n(93350);function R(e,t){let n=(0,M.o2)(t),r=a()({["".concat(e,"-").concat(t)]:t&&n}),o={},i={};return t&&!n&&(o.background=t,i["--antd-arrow-background-color"]=t),{className:r,overlayStyle:o,arrowStyle:i}}var j=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&0>t.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var o=0,r=Object.getOwnPropertySymbols(e);ot.indexOf(r[o])&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n};let I=r.forwardRef((e,t)=>{var n,o;let{prefixCls:v,openClassName:b,getTooltipContainer:y,overlayClassName:x,color:w,overlayInnerStyle:E,children:S,afterOpenChange:C,afterVisibleChange:Z,destroyTooltipOnHide:O,arrow:M=!0,title:I,overlay:N,builtinPlacements:P,arrowPointAtCenter:T=!1,autoAdjustOverflow:F=!0}=e,A=!!M,[,z]=(0,h.ZP)(),{getPopupContainer:L,getPrefixCls:_,direction:H}=r.useContext(m.E_),B=(0,f.ln)("Tooltip"),D=r.useRef(null),W=()=>{var e;null===(e=D.current)||void 0===e||e.forceAlign()};r.useImperativeHandle(t,()=>({forceAlign:W,forcePopupAlign:()=>{B.deprecated(!1,"forcePopupAlign","forceAlign"),W()}}));let[V,q]=(0,c.Z)(!1,{value:null!==(n=e.open)&&void 0!==n?n:e.visible,defaultValue:null!==(o=e.defaultOpen)&&void 0!==o?o:e.defaultVisible}),G=!I&&!N&&0!==I,X=r.useMemo(()=>{var e,t;let n=T;return"object"==typeof M&&(n=null!==(t=null!==(e=M.pointAtCenter)&&void 0!==e?e:M.arrowPointAtCenter)&&void 0!==t?t:T),P||(0,u.Z)({arrowPointAtCenter:n,autoAdjustOverflow:F,arrowWidth:A?z.sizePopupArrow:0,borderRadius:z.borderRadius,offset:z.marginXXS,visibleFirst:!0})},[T,M,P,z]),U=r.useMemo(()=>0===I?I:N||I||"",[N,I]),K=r.createElement(g.BR,null,"function"==typeof U?U():U),{getPopupContainer:$,placement:Y="top",mouseEnterDelay:Q=.1,mouseLeaveDelay:J=.1,overlayStyle:ee,rootClassName:et}=e,en=j(e,["getPopupContainer","placement","mouseEnterDelay","mouseLeaveDelay","overlayStyle","rootClassName"]),er=_("tooltip",v),eo=_(),ea=e["data-popover-inject"],ei=V;"open"in e||"visible"in e||!G||(ei=!1);let ec=(0,d.l$)(S)&&!(0,d.M2)(S)?S:r.createElement("span",null,S),el=ec.props,es=el.className&&"string"!=typeof el.className?el.className:a()(el.className,b||"".concat(er,"-open")),[eu,ed,ef]=k(er,!ea),ep=R(er,w),em=ep.arrowStyle,eg=Object.assign(Object.assign({},E),ep.overlayStyle),eh=a()(x,{["".concat(er,"-rtl")]:"rtl"===H},ep.className,et,ed,ef),[ev,eb]=(0,l.Cn)("Tooltip",en.zIndex),ey=r.createElement(i.Z,Object.assign({},en,{zIndex:ev,showArrow:A,placement:Y,mouseEnterDelay:Q,mouseLeaveDelay:J,prefixCls:er,overlayClassName:eh,overlayStyle:Object.assign(Object.assign({},em),ee),getTooltipContainer:$||y||L,ref:D,builtinPlacements:X,overlay:K,visible:ei,onVisibleChange:t=>{var n,r;q(!G&&t),G||(null===(n=e.onOpenChange)||void 0===n||n.call(e,t),null===(r=e.onVisibleChange)||void 0===r||r.call(e,t))},afterVisibleChange:null!=C?C:Z,overlayInnerStyle:eg,arrowContent:r.createElement("span",{className:"".concat(er,"-arrow-content")}),motion:{motionName:(0,s.m)(eo,"zoom-big-fast",e.transitionName),motionDeadline:1e3},destroyTooltipOnHide:!!O}),ei?(0,d.Tm)(ec,{className:es}):ec);return eu(r.createElement(p.Z.Provider,{value:eb},ey))});I._InternalPanelDoNotUseOrYouWillBeFired=e=>{let{prefixCls:t,className:n,placement:o="top",title:c,color:l,overlayInnerStyle:s}=e,{getPrefixCls:u}=r.useContext(m.E_),d=u("tooltip",t),[f,p,g]=k(d),h=R(d,l),v=h.arrowStyle,b=Object.assign(Object.assign({},s),h.overlayStyle),y=a()(p,g,d,"".concat(d,"-pure"),"".concat(d,"-placement-").concat(o),n,h.className);return f(r.createElement("div",{className:y,style:v},r.createElement("div",{className:"".concat(d,"-arrow")}),r.createElement(i.G,Object.assign({},e,{className:p,prefixCls:d,overlayInnerStyle:b}),c)))};var N=I},99376:function(e,t,n){"use strict";var r=n(35475);n.o(r,"useRouter")&&n.d(t,{useRouter:function(){return r.useRouter}}),n.o(r,"useSearchParams")&&n.d(t,{useSearchParams:function(){return r.useSearchParams}})},40257:function(e,t,n){"use strict";var r,o;e.exports=(null==(r=n.g.process)?void 0:r.env)&&"object"==typeof(null==(o=n.g.process)?void 0:o.env)?n.g.process:n(44227)},44227:function(e){!function(){var t={229:function(e){var t,n,r,o=e.exports={};function a(){throw Error("setTimeout has not been defined")}function i(){throw Error("clearTimeout has not been defined")}function c(e){if(t===setTimeout)return setTimeout(e,0);if((t===a||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:a}catch(e){t=a}try{n="function"==typeof clearTimeout?clearTimeout:i}catch(e){n=i}}();var l=[],s=!1,u=-1;function d(){s&&r&&(s=!1,r.length?l=r.concat(l):u=-1,l.length&&f())}function f(){if(!s){var e=c(d);s=!0;for(var t=l.length;t;){for(r=l,l=[];++u1)for(var n=1;n1?t-1:0),r=1;r=a)return e;switch(e){case"%s":return String(n[o++]);case"%d":return Number(n[o++]);case"%j":try{return JSON.stringify(n[o++])}catch(e){return"[Circular]"}break;default:return e}}):e}function T(e,t){return!!(null==e||"array"===t&&Array.isArray(e)&&!e.length)||("string"===t||"url"===t||"hex"===t||"email"===t||"date"===t||"pattern"===t)&&"string"==typeof e&&!e}function F(e,t,n){var r=0,o=e.length;!function a(i){if(i&&i.length){n(i);return}var c=r;r+=1,c()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+\.)+[a-zA-Z\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}))$/,hex:/^#?([a-f0-9]{6}|[a-f0-9]{3})$/i},D={integer:function(e){return D.number(e)&&parseInt(e,10)===e},float:function(e){return D.number(e)&&!D.integer(e)},array:function(e){return Array.isArray(e)},regexp:function(e){if(e instanceof RegExp)return!0;try{return new RegExp(e),!0}catch(e){return!1}},date:function(e){return"function"==typeof e.getTime&&"function"==typeof e.getMonth&&"function"==typeof e.getYear&&!isNaN(e.getTime())},number:function(e){return!isNaN(e)&&"number"==typeof e},object:function(e){return"object"==typeof e&&!D.array(e)},method:function(e){return"function"==typeof e},email:function(e){return"string"==typeof e&&e.length<=320&&!!e.match(B.email)},url:function(e){return"string"==typeof e&&e.length<=2048&&!!e.match(H())},hex:function(e){return"string"==typeof e&&!!e.match(B.hex)}},W="enum",V={required:_,whitespace:function(e,t,n,r,o){(/^\s+$/.test(t)||""===t)&&r.push(P(o.messages.whitespace,e.fullField))},type:function(e,t,n,r,o){if(e.required&&void 0===t){_(e,t,n,r,o);return}var a=e.type;["integer","float","array","regexp","object","method","email","number","date","url","hex"].indexOf(a)>-1?D[a](t)||r.push(P(o.messages.types[a],e.fullField,e.type)):a&&typeof t!==e.type&&r.push(P(o.messages.types[a],e.fullField,e.type))},range:function(e,t,n,r,o){var a="number"==typeof e.len,i="number"==typeof e.min,c="number"==typeof e.max,l=t,s=null,u="number"==typeof t,d="string"==typeof t,f=Array.isArray(t);if(u?s="number":d?s="string":f&&(s="array"),!s)return!1;f&&(l=t.length),d&&(l=t.replace(/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,"_").length),a?l!==e.len&&r.push(P(o.messages[s].len,e.fullField,e.len)):i&&!c&&le.max?r.push(P(o.messages[s].max,e.fullField,e.max)):i&&c&&(le.max)&&r.push(P(o.messages[s].range,e.fullField,e.min,e.max))},enum:function(e,t,n,r,o){e[W]=Array.isArray(e[W])?e[W]:[],-1===e[W].indexOf(t)&&r.push(P(o.messages[W],e.fullField,e[W].join(", ")))},pattern:function(e,t,n,r,o){!e.pattern||(e.pattern instanceof RegExp?(e.pattern.lastIndex=0,e.pattern.test(t)||r.push(P(o.messages.pattern.mismatch,e.fullField,t,e.pattern))):"string"!=typeof e.pattern||new RegExp(e.pattern).test(t)||r.push(P(o.messages.pattern.mismatch,e.fullField,t,e.pattern)))}},q=function(e,t,n,r,o){var a=e.type,i=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t,a)&&!e.required)return n();V.required(e,t,r,i,o,a),T(t,a)||V.type(e,t,r,i,o)}n(i)},G={string:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t,"string")&&!e.required)return n();V.required(e,t,r,a,o,"string"),T(t,"string")||(V.type(e,t,r,a,o),V.range(e,t,r,a,o),V.pattern(e,t,r,a,o),!0===e.whitespace&&V.whitespace(e,t,r,a,o))}n(a)},method:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&V.type(e,t,r,a,o)}n(a)},number:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(""===t&&(t=void 0),T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&(V.type(e,t,r,a,o),V.range(e,t,r,a,o))}n(a)},boolean:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&V.type(e,t,r,a,o)}n(a)},regexp:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),T(t)||V.type(e,t,r,a,o)}n(a)},integer:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&(V.type(e,t,r,a,o),V.range(e,t,r,a,o))}n(a)},float:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&(V.type(e,t,r,a,o),V.range(e,t,r,a,o))}n(a)},array:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(null==t&&!e.required)return n();V.required(e,t,r,a,o,"array"),null!=t&&(V.type(e,t,r,a,o),V.range(e,t,r,a,o))}n(a)},object:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&V.type(e,t,r,a,o)}n(a)},enum:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o),void 0!==t&&V.enum(e,t,r,a,o)}n(a)},pattern:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t,"string")&&!e.required)return n();V.required(e,t,r,a,o),T(t,"string")||V.pattern(e,t,r,a,o)}n(a)},date:function(e,t,n,r,o){var a,i=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t,"date")&&!e.required)return n();V.required(e,t,r,i,o),!T(t,"date")&&(a=t instanceof Date?t:new Date(t),V.type(e,a,r,i,o),a&&V.range(e,a.getTime(),r,i,o))}n(i)},url:q,hex:q,email:q,required:function(e,t,n,r,o){var a=[],i=Array.isArray(t)?"array":typeof t;V.required(e,t,r,a,o,i),n(a)},any:function(e,t,n,r,o){var a=[];if(e.required||!e.required&&r.hasOwnProperty(e.field)){if(T(t)&&!e.required)return n();V.required(e,t,r,a,o)}n(a)}};function X(){return{default:"Validation error on field %s",required:"%s is required",enum:"%s must be one of %s",whitespace:"%s cannot be empty",date:{format:"%s date %s is invalid for format %s",parse:"%s date could not be parsed, %s is invalid ",invalid:"%s date %s is invalid"},types:{string:"%s is not a %s",method:"%s is not a %s (function)",array:"%s is not an %s",object:"%s is not an %s",number:"%s is not a %s",date:"%s is not a %s",boolean:"%s is not a %s",integer:"%s is not an %s",float:"%s is not a %s",regexp:"%s is not a valid %s",email:"%s is not a valid %s",url:"%s is not a valid %s",hex:"%s is not a valid %s"},string:{len:"%s must be exactly %s characters",min:"%s must be at least %s characters",max:"%s cannot be longer than %s characters",range:"%s must be between %s and %s characters"},number:{len:"%s must equal %s",min:"%s cannot be less than %s",max:"%s cannot be greater than %s",range:"%s must be between %s and %s"},array:{len:"%s must be exactly %s in length",min:"%s cannot be less than %s in length",max:"%s cannot be greater than %s in length",range:"%s must be between %s and %s in length"},pattern:{mismatch:"%s value %s does not match pattern %s"},clone:function(){var e=JSON.parse(JSON.stringify(this));return e.clone=this.clone,e}}}var U=X(),K=function(){function e(e){this.rules=null,this._messages=U,this.define(e)}var t=e.prototype;return t.define=function(e){var t=this;if(!e)throw Error("Cannot configure a schema with no rules");if("object"!=typeof e||Array.isArray(e))throw Error("Rules must be an object");this.rules={},Object.keys(e).forEach(function(n){var r=e[n];t.rules[n]=Array.isArray(r)?r:[r]})},t.messages=function(e){return e&&(this._messages=L(X(),e)),this._messages},t.validate=function(t,n,r){var o=this;void 0===n&&(n={}),void 0===r&&(r=function(){});var a=t,i=n,c=r;if("function"==typeof i&&(c=i,i={}),!this.rules||0===Object.keys(this.rules).length)return c&&c(null,a),Promise.resolve(a);if(i.messages){var l=this.messages();l===U&&(l=X()),L(l,i.messages),i.messages=l}else i.messages=this.messages();var s={};(i.keys||Object.keys(this.rules)).forEach(function(e){var n=o.rules[e],r=a[e];n.forEach(function(n){var i=n;"function"==typeof i.transform&&(a===t&&(a=O({},a)),r=a[e]=i.transform(r)),(i="function"==typeof i?{validator:i}:O({},i)).validator=o.getValidationMethod(i),i.validator&&(i.field=e,i.fullField=i.fullField||e,i.type=o.getType(i),s[e]=s[e]||[],s[e].push({rule:i,value:r,source:a,field:e}))})});var u={};return function(e,t,n,r,o){if(t.first){var a=new Promise(function(t,a){var i;F((i=[],Object.keys(e).forEach(function(t){i.push.apply(i,e[t]||[])}),i),n,function(e){return r(e),e.length?a(new A(e,N(e))):t(o)})});return a.catch(function(e){return e}),a}var i=!0===t.firstFields?Object.keys(e):t.firstFields||[],c=Object.keys(e),l=c.length,s=0,u=[],d=new Promise(function(t,a){var d=function(e){if(u.push.apply(u,e),++s===l)return r(u),u.length?a(new A(u,N(u))):t(o)};c.length||(r(u),t(o)),c.forEach(function(t){var r=e[t];-1!==i.indexOf(t)?F(r,n,d):function(e,t,n){var r=[],o=0,a=e.length;function i(e){r.push.apply(r,e||[]),++o===a&&n(r)}e.forEach(function(e){t(e,i)})}(r,n,d)})});return d.catch(function(e){return e}),d}(s,i,function(t,n){var r,o=t.rule,c=("object"===o.type||"array"===o.type)&&("object"==typeof o.fields||"object"==typeof o.defaultField);function l(e,t){return O({},t,{fullField:o.fullField+"."+e,fullFields:o.fullFields?[].concat(o.fullFields,[e]):[e]})}function s(r){void 0===r&&(r=[]);var s=Array.isArray(r)?r:[r];!i.suppressWarning&&s.length&&e.warning("async-validator:",s),s.length&&void 0!==o.message&&(s=[].concat(o.message));var d=s.map(z(o,a));if(i.first&&d.length)return u[o.field]=1,n(d);if(c){if(o.required&&!t.value)return void 0!==o.message?d=[].concat(o.message).map(z(o,a)):i.error&&(d=[i.error(o,P(i.messages.required,o.field))]),n(d);var f={};o.defaultField&&Object.keys(t.value).map(function(e){f[e]=o.defaultField});var p={};Object.keys(f=O({},f,t.rule.fields)).forEach(function(e){var t=f[e],n=Array.isArray(t)?t:[t];p[e]=n.map(l.bind(null,e))});var m=new e(p);m.messages(i.messages),t.rule.options&&(t.rule.options.messages=i.messages,t.rule.options.error=i.error),m.validate(t.value,t.rule.options||i,function(e){var t=[];d&&d.length&&t.push.apply(t,d),e&&e.length&&t.push.apply(t,e),n(t.length?t:null)})}else n(d)}if(c=c&&(o.required||!o.required&&t.value),o.field=t.field,o.asyncValidator)r=o.asyncValidator(o,t.value,s,t.source,i);else if(o.validator){try{r=o.validator(o,t.value,s,t.source,i)}catch(e){null==console.error||console.error(e),i.suppressValidatorError||setTimeout(function(){throw e},0),s(e.message)}!0===r?s():!1===r?s("function"==typeof o.message?o.message(o.fullField||o.field):o.message||(o.fullField||o.field)+" fails"):r instanceof Array?s(r):r instanceof Error&&s(r.message)}r&&r.then&&r.then(function(){return s()},function(e){return s(e)})},function(e){!function(e){for(var t=[],n={},r=0;r2&&void 0!==arguments[2]&&arguments[2];return e&&e.some(function(e){return es(t,e,n)})}function es(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];return!!e&&!!t&&(!!n||e.length===t.length)&&t.every(function(t,n){return e[n]===t})}function eu(e){var t=arguments.length<=1?void 0:arguments[1];return t&&t.target&&"object"===(0,eo.Z)(t.target)&&e in t.target?t.target[e]:t}function ed(e,t,n){var r=e.length;if(t<0||t>=r||n<0||n>=r)return e;var o=e[t],a=t-n;return a>0?[].concat((0,u.Z)(e.slice(0,n)),[o],(0,u.Z)(e.slice(n,t)),(0,u.Z)(e.slice(t+1,r))):a<0?[].concat((0,u.Z)(e.slice(0,t)),(0,u.Z)(e.slice(t+1,n+1)),[o],(0,u.Z)(e.slice(n+1,r))):e}var ef=["name"],ep=[];function em(e,t,n,r,o,a){return"function"==typeof e?e(t,n,"source"in a?{source:a.source}:{}):r!==o}var eg=function(e){(0,m.Z)(n,e);var t=(0,g.Z)(n);function n(e){var r;return(0,d.Z)(this,n),r=t.call(this,e),(0,h.Z)((0,p.Z)(r),"state",{resetCount:0}),(0,h.Z)((0,p.Z)(r),"cancelRegisterFunc",null),(0,h.Z)((0,p.Z)(r),"mounted",!1),(0,h.Z)((0,p.Z)(r),"touched",!1),(0,h.Z)((0,p.Z)(r),"dirty",!1),(0,h.Z)((0,p.Z)(r),"validatePromise",void 0),(0,h.Z)((0,p.Z)(r),"prevValidating",void 0),(0,h.Z)((0,p.Z)(r),"errors",ep),(0,h.Z)((0,p.Z)(r),"warnings",ep),(0,h.Z)((0,p.Z)(r),"cancelRegister",function(){var e=r.props,t=e.preserve,n=e.isListField,o=e.name;r.cancelRegisterFunc&&r.cancelRegisterFunc(n,t,ei(o)),r.cancelRegisterFunc=null}),(0,h.Z)((0,p.Z)(r),"getNamePath",function(){var e=r.props,t=e.name,n=e.fieldContext.prefixName;return void 0!==t?[].concat((0,u.Z)(void 0===n?[]:n),(0,u.Z)(t)):[]}),(0,h.Z)((0,p.Z)(r),"getRules",function(){var e=r.props,t=e.rules,n=e.fieldContext;return(void 0===t?[]:t).map(function(e){return"function"==typeof e?e(n):e})}),(0,h.Z)((0,p.Z)(r),"refresh",function(){r.mounted&&r.setState(function(e){return{resetCount:e.resetCount+1}})}),(0,h.Z)((0,p.Z)(r),"metaCache",null),(0,h.Z)((0,p.Z)(r),"triggerMetaEvent",function(e){var t=r.props.onMetaChange;if(t){var n=(0,s.Z)((0,s.Z)({},r.getMeta()),{},{destroy:e});(0,b.Z)(r.metaCache,n)||t(n),r.metaCache=n}else r.metaCache=null}),(0,h.Z)((0,p.Z)(r),"onStoreChange",function(e,t,n){var o=r.props,a=o.shouldUpdate,i=o.dependencies,c=void 0===i?[]:i,l=o.onReset,s=n.store,u=r.getNamePath(),d=r.getValue(e),f=r.getValue(s),p=t&&el(t,u);switch("valueUpdate"===n.type&&"external"===n.source&&d!==f&&(r.touched=!0,r.dirty=!0,r.validatePromise=null,r.errors=ep,r.warnings=ep,r.triggerMetaEvent()),n.type){case"reset":if(!t||p){r.touched=!1,r.dirty=!1,r.validatePromise=void 0,r.errors=ep,r.warnings=ep,r.triggerMetaEvent(),null==l||l(),r.refresh();return}break;case"remove":if(a){r.reRender();return}break;case"setField":var m=n.data;if(p){"touched"in m&&(r.touched=m.touched),"validating"in m&&!("originRCField"in m)&&(r.validatePromise=m.validating?Promise.resolve([]):null),"errors"in m&&(r.errors=m.errors||ep),"warnings"in m&&(r.warnings=m.warnings||ep),r.dirty=!0,r.triggerMetaEvent(),r.reRender();return}if("value"in m&&el(t,u,!0)||a&&!u.length&&em(a,e,s,d,f,n)){r.reRender();return}break;case"dependenciesUpdate":if(c.map(ei).some(function(e){return el(n.relatedFields,e)})){r.reRender();return}break;default:if(p||(!c.length||u.length||a)&&em(a,e,s,d,f,n)){r.reRender();return}}!0===a&&r.reRender()}),(0,h.Z)((0,p.Z)(r),"validateRules",function(e){var t=r.getNamePath(),n=r.getValue(),o=e||{},a=o.triggerName,i=o.validateOnly,d=Promise.resolve().then((0,l.Z)((0,c.Z)().mark(function o(){var i,f,p,m,g,h,v;return(0,c.Z)().wrap(function(o){for(;;)switch(o.prev=o.next){case 0:if(r.mounted){o.next=2;break}return o.abrupt("return",[]);case 2:if(p=void 0!==(f=(i=r.props).validateFirst)&&f,m=i.messageVariables,g=i.validateDebounce,h=r.getRules(),a&&(h=h.filter(function(e){return e}).filter(function(e){var t=e.validateTrigger;return!t||C(t).includes(a)})),!(g&&a)){o.next=10;break}return o.next=8,new Promise(function(e){setTimeout(e,g)});case 8:if(!(r.validatePromise!==d)){o.next=10;break}return o.abrupt("return",[]);case 10:return(v=function(e,t,n,r,o,a){var i,u,d=e.join("."),f=n.map(function(e,t){var n=e.validator,r=(0,s.Z)((0,s.Z)({},e),{},{ruleIndex:t});return n&&(r.validator=function(e,t,r){var o=!1,a=n(e,t,function(){for(var e=arguments.length,t=Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:ep;if(r.validatePromise===d){r.validatePromise=null;var t,n=[],o=[];null===(t=e.forEach)||void 0===t||t.call(e,function(e){var t=e.rule.warningOnly,r=e.errors,a=void 0===r?ep:r;t?o.push.apply(o,(0,u.Z)(a)):n.push.apply(n,(0,u.Z)(a))}),r.errors=n,r.warnings=o,r.triggerMetaEvent(),r.reRender()}}),o.abrupt("return",v);case 13:case"end":return o.stop()}},o)})));return void 0!==i&&i||(r.validatePromise=d,r.dirty=!0,r.errors=ep,r.warnings=ep,r.triggerMetaEvent(),r.reRender()),d}),(0,h.Z)((0,p.Z)(r),"isFieldValidating",function(){return!!r.validatePromise}),(0,h.Z)((0,p.Z)(r),"isFieldTouched",function(){return r.touched}),(0,h.Z)((0,p.Z)(r),"isFieldDirty",function(){return!!r.dirty||void 0!==r.props.initialValue||void 0!==(0,r.props.fieldContext.getInternalHooks(x).getInitialValue)(r.getNamePath())}),(0,h.Z)((0,p.Z)(r),"getErrors",function(){return r.errors}),(0,h.Z)((0,p.Z)(r),"getWarnings",function(){return r.warnings}),(0,h.Z)((0,p.Z)(r),"isListField",function(){return r.props.isListField}),(0,h.Z)((0,p.Z)(r),"isList",function(){return r.props.isList}),(0,h.Z)((0,p.Z)(r),"isPreserve",function(){return r.props.preserve}),(0,h.Z)((0,p.Z)(r),"getMeta",function(){return r.prevValidating=r.isFieldValidating(),{touched:r.isFieldTouched(),validating:r.prevValidating,errors:r.errors,warnings:r.warnings,name:r.getNamePath(),validated:null===r.validatePromise}}),(0,h.Z)((0,p.Z)(r),"getOnlyChild",function(e){if("function"==typeof e){var t=r.getMeta();return(0,s.Z)((0,s.Z)({},r.getOnlyChild(e(r.getControlled(),t,r.props.fieldContext))),{},{isFunction:!0})}var n=(0,v.Z)(e);return 1===n.length&&o.isValidElement(n[0])?{child:n[0],isFunction:!1}:{child:n,isFunction:!1}}),(0,h.Z)((0,p.Z)(r),"getValue",function(e){var t=r.props.fieldContext.getFieldsValue,n=r.getNamePath();return(0,ea.Z)(e||t(!0),n)}),(0,h.Z)((0,p.Z)(r),"getControlled",function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=r.props,n=t.trigger,o=t.validateTrigger,a=t.getValueFromEvent,i=t.normalize,c=t.valuePropName,l=t.getValueProps,u=t.fieldContext,d=void 0!==o?o:u.validateTrigger,f=r.getNamePath(),p=u.getInternalHooks,m=u.getFieldsValue,g=p(x).dispatch,v=r.getValue(),b=l||function(e){return(0,h.Z)({},c,e)},y=e[n],w=(0,s.Z)((0,s.Z)({},e),b(v));return w[n]=function(){r.touched=!0,r.dirty=!0,r.triggerMetaEvent();for(var e,t=arguments.length,n=Array(t),o=0;o=0&&t<=n.length?(f.keys=[].concat((0,u.Z)(f.keys.slice(0,t)),[f.id],(0,u.Z)(f.keys.slice(t))),o([].concat((0,u.Z)(n.slice(0,t)),[e],(0,u.Z)(n.slice(t))))):(f.keys=[].concat((0,u.Z)(f.keys),[f.id]),o([].concat((0,u.Z)(n),[e]))),f.id+=1},remove:function(e){var t=i(),n=new Set(Array.isArray(e)?e:[e]);n.size<=0||(f.keys=f.keys.filter(function(e,t){return!n.has(t)}),o(t.filter(function(e,t){return!n.has(t)})))},move:function(e,t){if(e!==t){var n=i();e<0||e>=n.length||t<0||t>=n.length||(f.keys=ed(f.keys,e,t),o(ed(n,e,t)))}}},t)})))},eb=n(26365),ey="__@field_split__";function ex(e){return e.map(function(e){return"".concat((0,eo.Z)(e),":").concat(e)}).join(ey)}var ew=function(){function e(){(0,d.Z)(this,e),(0,h.Z)(this,"kvs",new Map)}return(0,f.Z)(e,[{key:"set",value:function(e,t){this.kvs.set(ex(e),t)}},{key:"get",value:function(e){return this.kvs.get(ex(e))}},{key:"update",value:function(e,t){var n=t(this.get(e));n?this.set(e,n):this.delete(e)}},{key:"delete",value:function(e){this.kvs.delete(ex(e))}},{key:"map",value:function(e){return(0,u.Z)(this.kvs.entries()).map(function(t){var n=(0,eb.Z)(t,2),r=n[0],o=n[1];return e({key:r.split(ey).map(function(e){var t=e.match(/^([^:]*):(.*)$/),n=(0,eb.Z)(t,3),r=n[1],o=n[2];return"number"===r?Number(o):o}),value:o})})}},{key:"toJSON",value:function(){var e={};return this.map(function(t){var n=t.key,r=t.value;return e[n.join(".")]=r,null}),e}}]),e}(),eE=["name"],eS=(0,f.Z)(function e(t){var n=this;(0,d.Z)(this,e),(0,h.Z)(this,"formHooked",!1),(0,h.Z)(this,"forceRootUpdate",void 0),(0,h.Z)(this,"subscribable",!0),(0,h.Z)(this,"store",{}),(0,h.Z)(this,"fieldEntities",[]),(0,h.Z)(this,"initialValues",{}),(0,h.Z)(this,"callbacks",{}),(0,h.Z)(this,"validateMessages",null),(0,h.Z)(this,"preserve",null),(0,h.Z)(this,"lastValidatePromise",null),(0,h.Z)(this,"getForm",function(){return{getFieldValue:n.getFieldValue,getFieldsValue:n.getFieldsValue,getFieldError:n.getFieldError,getFieldWarning:n.getFieldWarning,getFieldsError:n.getFieldsError,isFieldsTouched:n.isFieldsTouched,isFieldTouched:n.isFieldTouched,isFieldValidating:n.isFieldValidating,isFieldsValidating:n.isFieldsValidating,resetFields:n.resetFields,setFields:n.setFields,setFieldValue:n.setFieldValue,setFieldsValue:n.setFieldsValue,validateFields:n.validateFields,submit:n.submit,_init:!0,getInternalHooks:n.getInternalHooks}}),(0,h.Z)(this,"getInternalHooks",function(e){return e===x?(n.formHooked=!0,{dispatch:n.dispatch,initEntityValue:n.initEntityValue,registerField:n.registerField,useSubscribe:n.useSubscribe,setInitialValues:n.setInitialValues,destroyForm:n.destroyForm,setCallbacks:n.setCallbacks,setValidateMessages:n.setValidateMessages,getFields:n.getFields,setPreserve:n.setPreserve,getInitialValue:n.getInitialValue,registerWatch:n.registerWatch}):((0,y.ZP)(!1,"`getInternalHooks` is internal usage. Should not call directly."),null)}),(0,h.Z)(this,"useSubscribe",function(e){n.subscribable=e}),(0,h.Z)(this,"prevWithoutPreserves",null),(0,h.Z)(this,"setInitialValues",function(e,t){if(n.initialValues=e||{},t){var r,o=(0,Q.T)(e,n.store);null===(r=n.prevWithoutPreserves)||void 0===r||r.map(function(t){var n=t.key;o=(0,Q.Z)(o,n,(0,ea.Z)(e,n))}),n.prevWithoutPreserves=null,n.updateStore(o)}}),(0,h.Z)(this,"destroyForm",function(){var e=new ew;n.getFieldEntities(!0).forEach(function(t){n.isMergedPreserve(t.isPreserve())||e.set(t.getNamePath(),!0)}),n.prevWithoutPreserves=e}),(0,h.Z)(this,"getInitialValue",function(e){var t=(0,ea.Z)(n.initialValues,e);return e.length?(0,Q.T)(t):t}),(0,h.Z)(this,"setCallbacks",function(e){n.callbacks=e}),(0,h.Z)(this,"setValidateMessages",function(e){n.validateMessages=e}),(0,h.Z)(this,"setPreserve",function(e){n.preserve=e}),(0,h.Z)(this,"watchList",[]),(0,h.Z)(this,"registerWatch",function(e){return n.watchList.push(e),function(){n.watchList=n.watchList.filter(function(t){return t!==e})}}),(0,h.Z)(this,"notifyWatch",function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];if(n.watchList.length){var t=n.getFieldsValue(),r=n.getFieldsValue(!0);n.watchList.forEach(function(n){n(t,r,e)})}}),(0,h.Z)(this,"timeoutId",null),(0,h.Z)(this,"warningUnhooked",function(){}),(0,h.Z)(this,"updateStore",function(e){n.store=e}),(0,h.Z)(this,"getFieldEntities",function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return e?n.fieldEntities.filter(function(e){return e.getNamePath().length}):n.fieldEntities}),(0,h.Z)(this,"getFieldsMap",function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=new ew;return n.getFieldEntities(e).forEach(function(e){var n=e.getNamePath();t.set(n,e)}),t}),(0,h.Z)(this,"getFieldEntitiesForNamePathList",function(e){if(!e)return n.getFieldEntities(!0);var t=n.getFieldsMap(!0);return e.map(function(e){var n=ei(e);return t.get(n)||{INVALIDATE_NAME_PATH:ei(e)}})}),(0,h.Z)(this,"getFieldsValue",function(e,t){if(n.warningUnhooked(),!0===e||Array.isArray(e)?(r=e,o=t):e&&"object"===(0,eo.Z)(e)&&(a=e.strict,o=e.filter),!0===r&&!o)return n.store;var r,o,a,i=n.getFieldEntitiesForNamePathList(Array.isArray(r)?r:null),c=[];return i.forEach(function(e){var t,n,i,l="INVALIDATE_NAME_PATH"in e?e.INVALIDATE_NAME_PATH:e.getNamePath();if(a){if(null!==(i=e.isList)&&void 0!==i&&i.call(e))return}else if(!r&&null!==(t=(n=e).isListField)&&void 0!==t&&t.call(n))return;if(o){var s="getMeta"in e?e.getMeta():null;o(s)&&c.push(l)}else c.push(l)}),ec(n.store,c.map(ei))}),(0,h.Z)(this,"getFieldValue",function(e){n.warningUnhooked();var t=ei(e);return(0,ea.Z)(n.store,t)}),(0,h.Z)(this,"getFieldsError",function(e){return n.warningUnhooked(),n.getFieldEntitiesForNamePathList(e).map(function(t,n){return!t||"INVALIDATE_NAME_PATH"in t?{name:ei(e[n]),errors:[],warnings:[]}:{name:t.getNamePath(),errors:t.getErrors(),warnings:t.getWarnings()}})}),(0,h.Z)(this,"getFieldError",function(e){n.warningUnhooked();var t=ei(e);return n.getFieldsError([t])[0].errors}),(0,h.Z)(this,"getFieldWarning",function(e){n.warningUnhooked();var t=ei(e);return n.getFieldsError([t])[0].warnings}),(0,h.Z)(this,"isFieldsTouched",function(){n.warningUnhooked();for(var e,t=arguments.length,r=Array(t),o=0;o0&&void 0!==arguments[0]?arguments[0]:{},r=new ew,o=n.getFieldEntities(!0);o.forEach(function(e){var t=e.props.initialValue,n=e.getNamePath();if(void 0!==t){var o=r.get(n)||new Set;o.add({entity:e,value:t}),r.set(n,o)}}),t.entities?e=t.entities:t.namePathList?(e=[],t.namePathList.forEach(function(t){var n,o=r.get(t);o&&(n=e).push.apply(n,(0,u.Z)((0,u.Z)(o).map(function(e){return e.entity})))})):e=o,function(e){e.forEach(function(e){if(void 0!==e.props.initialValue){var o=e.getNamePath();if(void 0!==n.getInitialValue(o))(0,y.ZP)(!1,"Form already set 'initialValues' with path '".concat(o.join("."),"'. Field can not overwrite it."));else{var a=r.get(o);if(a&&a.size>1)(0,y.ZP)(!1,"Multiple Field with path '".concat(o.join("."),"' set 'initialValue'. Can not decide which one to pick."));else if(a){var i=n.getFieldValue(o);e.isListField()||t.skipExist&&void 0!==i||n.updateStore((0,Q.Z)(n.store,o,(0,u.Z)(a)[0].value))}}}})}(e)}),(0,h.Z)(this,"resetFields",function(e){n.warningUnhooked();var t=n.store;if(!e){n.updateStore((0,Q.T)(n.initialValues)),n.resetWithFieldInitialValue(),n.notifyObservers(t,null,{type:"reset"}),n.notifyWatch();return}var r=e.map(ei);r.forEach(function(e){var t=n.getInitialValue(e);n.updateStore((0,Q.Z)(n.store,e,t))}),n.resetWithFieldInitialValue({namePathList:r}),n.notifyObservers(t,r,{type:"reset"}),n.notifyWatch(r)}),(0,h.Z)(this,"setFields",function(e){n.warningUnhooked();var t=n.store,r=[];e.forEach(function(e){var o=e.name,a=(0,i.Z)(e,eE),c=ei(o);r.push(c),"value"in a&&n.updateStore((0,Q.Z)(n.store,c,a.value)),n.notifyObservers(t,[c],{type:"setField",data:e})}),n.notifyWatch(r)}),(0,h.Z)(this,"getFields",function(){return n.getFieldEntities(!0).map(function(e){var t=e.getNamePath(),r=e.getMeta(),o=(0,s.Z)((0,s.Z)({},r),{},{name:t,value:n.getFieldValue(t)});return Object.defineProperty(o,"originRCField",{value:!0}),o})}),(0,h.Z)(this,"initEntityValue",function(e){var t=e.props.initialValue;if(void 0!==t){var r=e.getNamePath();void 0===(0,ea.Z)(n.store,r)&&n.updateStore((0,Q.Z)(n.store,r,t))}}),(0,h.Z)(this,"isMergedPreserve",function(e){var t=void 0!==e?e:n.preserve;return null==t||t}),(0,h.Z)(this,"registerField",function(e){n.fieldEntities.push(e);var t=e.getNamePath();if(n.notifyWatch([t]),void 0!==e.props.initialValue){var r=n.store;n.resetWithFieldInitialValue({entities:[e],skipExist:!0}),n.notifyObservers(r,[e.getNamePath()],{type:"valueUpdate",source:"internal"})}return function(r,o){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];if(n.fieldEntities=n.fieldEntities.filter(function(t){return t!==e}),!n.isMergedPreserve(o)&&(!r||a.length>1)){var i=r?void 0:n.getInitialValue(t);if(t.length&&n.getFieldValue(t)!==i&&n.fieldEntities.every(function(e){return!es(e.getNamePath(),t)})){var c=n.store;n.updateStore((0,Q.Z)(c,t,i,!0)),n.notifyObservers(c,[t],{type:"remove"}),n.triggerDependenciesUpdate(c,t)}}n.notifyWatch([t])}}),(0,h.Z)(this,"dispatch",function(e){switch(e.type){case"updateValue":var t=e.namePath,r=e.value;n.updateValue(t,r);break;case"validateField":var o=e.namePath,a=e.triggerName;n.validateFields([o],{triggerName:a})}}),(0,h.Z)(this,"notifyObservers",function(e,t,r){if(n.subscribable){var o=(0,s.Z)((0,s.Z)({},r),{},{store:n.getFieldsValue(!0)});n.getFieldEntities().forEach(function(n){(0,n.onStoreChange)(e,t,o)})}else n.forceRootUpdate()}),(0,h.Z)(this,"triggerDependenciesUpdate",function(e,t){var r=n.getDependencyChildrenFields(t);return r.length&&n.validateFields(r),n.notifyObservers(e,r,{type:"dependenciesUpdate",relatedFields:[t].concat((0,u.Z)(r))}),r}),(0,h.Z)(this,"updateValue",function(e,t){var r=ei(e),o=n.store;n.updateStore((0,Q.Z)(n.store,r,t)),n.notifyObservers(o,[r],{type:"valueUpdate",source:"internal"}),n.notifyWatch([r]);var a=n.triggerDependenciesUpdate(o,r),i=n.callbacks.onValuesChange;i&&i(ec(n.store,[r]),n.getFieldsValue()),n.triggerOnFieldsChange([r].concat((0,u.Z)(a)))}),(0,h.Z)(this,"setFieldsValue",function(e){n.warningUnhooked();var t=n.store;if(e){var r=(0,Q.T)(n.store,e);n.updateStore(r)}n.notifyObservers(t,null,{type:"valueUpdate",source:"external"}),n.notifyWatch()}),(0,h.Z)(this,"setFieldValue",function(e,t){n.setFields([{name:e,value:t}])}),(0,h.Z)(this,"getDependencyChildrenFields",function(e){var t=new Set,r=[],o=new ew;return n.getFieldEntities().forEach(function(e){(e.props.dependencies||[]).forEach(function(t){var n=ei(t);o.update(n,function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new Set;return t.add(e),t})})}),function e(n){(o.get(n)||new Set).forEach(function(n){if(!t.has(n)){t.add(n);var o=n.getNamePath();n.isFieldDirty()&&o.length&&(r.push(o),e(o))}})}(e),r}),(0,h.Z)(this,"triggerOnFieldsChange",function(e,t){var r=n.callbacks.onFieldsChange;if(r){var o=n.getFields();if(t){var a=new ew;t.forEach(function(e){var t=e.name,n=e.errors;a.set(t,n)}),o.forEach(function(e){e.errors=a.get(e.name)||e.errors})}var i=o.filter(function(t){return el(e,t.name)});i.length&&r(i,o)}}),(0,h.Z)(this,"validateFields",function(e,t){n.warningUnhooked(),Array.isArray(e)||"string"==typeof e||"string"==typeof t?(i=e,c=t):c=e;var r,o,a,i,c,l=!!i,d=l?i.map(ei):[],f=[],p=String(Date.now()),m=new Set,g=c||{},h=g.recursive,v=g.dirty;n.getFieldEntities(!0).forEach(function(e){if(l||d.push(e.getNamePath()),e.props.rules&&e.props.rules.length&&(!v||e.isFieldDirty())){var t=e.getNamePath();if(m.add(t.join(p)),!l||el(d,t,h)){var r=e.validateRules((0,s.Z)({validateMessages:(0,s.Z)((0,s.Z)({},Y),n.validateMessages)},c));f.push(r.then(function(){return{name:t,errors:[],warnings:[]}}).catch(function(e){var n,r=[],o=[];return(null===(n=e.forEach)||void 0===n||n.call(e,function(e){var t=e.rule.warningOnly,n=e.errors;t?o.push.apply(o,(0,u.Z)(n)):r.push.apply(r,(0,u.Z)(n))}),r.length)?Promise.reject({name:t,errors:r,warnings:o}):{name:t,errors:r,warnings:o}}))}}});var b=(r=!1,o=f.length,a=[],f.length?new Promise(function(e,t){f.forEach(function(n,i){n.catch(function(e){return r=!0,e}).then(function(n){o-=1,a[i]=n,o>0||(r&&t(a),e(a))})})}):Promise.resolve([]));n.lastValidatePromise=b,b.catch(function(e){return e}).then(function(e){var t=e.map(function(e){return e.name});n.notifyObservers(n.store,t,{type:"validateFinish"}),n.triggerOnFieldsChange(t,e)});var y=b.then(function(){return n.lastValidatePromise===b?Promise.resolve(n.getFieldsValue(d)):Promise.reject([])}).catch(function(e){var t=e.filter(function(e){return e&&e.errors.length});return Promise.reject({values:n.getFieldsValue(d),errorFields:t,outOfDate:n.lastValidatePromise!==b})});y.catch(function(e){return e});var x=d.filter(function(e){return m.has(e.join(p))});return n.triggerOnFieldsChange(x),y}),(0,h.Z)(this,"submit",function(){n.warningUnhooked(),n.validateFields().then(function(e){var t=n.callbacks.onFinish;if(t)try{t(e)}catch(e){console.error(e)}}).catch(function(e){var t=n.callbacks.onFinishFailed;t&&t(e)})}),this.forceRootUpdate=t}),eC=function(e){var t=o.useRef(),n=o.useState({}),r=(0,eb.Z)(n,2)[1];if(!t.current){if(e)t.current=e;else{var a=new eS(function(){r({})});t.current=a.getForm()}}return[t.current]},eZ=o.createContext({triggerFormChange:function(){},triggerFormFinish:function(){},registerForm:function(){},unregisterForm:function(){}}),eO=function(e){var t=e.validateMessages,n=e.onFormChange,r=e.onFormFinish,a=e.children,i=o.useContext(eZ),c=o.useRef({});return o.createElement(eZ.Provider,{value:(0,s.Z)((0,s.Z)({},i),{},{validateMessages:(0,s.Z)((0,s.Z)({},i.validateMessages),t),triggerFormChange:function(e,t){n&&n(e,{changedFields:t,forms:c.current}),i.triggerFormChange(e,t)},triggerFormFinish:function(e,t){r&&r(e,{values:t,forms:c.current}),i.triggerFormFinish(e,t)},registerForm:function(e,t){e&&(c.current=(0,s.Z)((0,s.Z)({},c.current),{},(0,h.Z)({},e,t))),i.registerForm(e,t)},unregisterForm:function(e){var t=(0,s.Z)({},c.current);delete t[e],c.current=t,i.unregisterForm(e)}})},a)},ek=["name","initialValues","fields","form","preserve","children","component","validateMessages","validateTrigger","onValuesChange","onFieldsChange","onFinish","onFinishFailed"];function eM(e){try{return JSON.stringify(e)}catch(e){return Math.random()}}var eR=function(){},ej=function(){for(var e=arguments.length,t=Array(e),n=0;n1?t-1:0),o=1;oen;(0,s.useImperativeHandle)(t,function(){return{focus:q,blur:function(){var e;null===(e=V.current)||void 0===e||e.blur()},setSelectionRange:function(e,t,n){var r;null===(r=V.current)||void 0===r||r.setSelectionRange(e,t,n)},select:function(){var e;null===(e=V.current)||void 0===e||e.select()},input:V.current}}),(0,s.useEffect)(function(){D(function(e){return(!e||!Z)&&e})},[Z]);var ea=function(e,t,n){var r,o,a=t;if(!W.current&&et.exceedFormatter&&et.max&&et.strategy(t)>et.max)a=et.exceedFormatter(t,{max:et.max}),t!==a&&ee([(null===(r=V.current)||void 0===r?void 0:r.selectionStart)||0,(null===(o=V.current)||void 0===o?void 0:o.selectionEnd)||0]);else if("compositionEnd"===n.source)return;K(a),V.current&&(0,u.rJ)(V.current,e,c,a)};(0,s.useEffect)(function(){if(J){var e;null===(e=V.current)||void 0===e||e.setSelectionRange.apply(e,(0,f.Z)(J))}},[J]);var ei=eo&&"".concat(C,"-out-of-range");return s.createElement(d,(0,o.Z)({},L,{prefixCls:C,className:l()(k,ei),handleReset:function(e){K(""),q(),V.current&&(0,u.rJ)(V.current,e,c)},value:$,focused:B,triggerFocus:q,suffix:function(){var e=Number(en)>0;if(R||et.show){var t=et.showFormatter?et.showFormatter({value:$,count:er,maxLength:en}):"".concat(er).concat(e?" / ".concat(en):"");return s.createElement(s.Fragment,null,et.show&&s.createElement("span",{className:l()("".concat(C,"-show-count-suffix"),(0,a.Z)({},"".concat(C,"-show-count-has-suffix"),!!R),null==T?void 0:T.count),style:(0,r.Z)({},null==F?void 0:F.count)},t),R)}return null}(),disabled:Z,classes:P,classNames:T,styles:F}),(n=(0,h.Z)(e,["prefixCls","onPressEnter","addonBefore","addonAfter","prefix","suffix","allowClear","defaultValue","showCount","count","classes","htmlSize","styles","classNames"]),s.createElement("input",(0,o.Z)({autoComplete:i},n,{onChange:function(e){ea(e,e.target.value,{source:"change"})},onFocus:function(e){D(!0),null==y||y(e)},onBlur:function(e){D(!1),null==x||x(e)},onKeyDown:function(e){w&&"Enter"===e.key&&w(e),null==E||E(e)},className:l()(C,(0,a.Z)({},"".concat(C,"-disabled"),Z),null==T?void 0:T.input),style:null==F?void 0:F.input,ref:V,size:O,type:void 0===N?"text":N,onCompositionStart:function(e){W.current=!0,null==A||A(e)},onCompositionEnd:function(e){W.current=!1,ea(e,e.currentTarget.value,{source:"compositionEnd"}),null==z||z(e)}}))))})},55041:function(e,t,n){"use strict";function r(e){return!!(e.addonBefore||e.addonAfter)}function o(e){return!!(e.prefix||e.suffix||e.allowClear)}function a(e,t,n,r){if(n){var o=t;if("click"===t.type){var a=e.cloneNode(!0);o=Object.create(t,{target:{value:a},currentTarget:{value:a}}),a.value="",n(o);return}if("file"!==e.type&&void 0!==r){var i=e.cloneNode(!0);o=Object.create(t,{target:{value:i},currentTarget:{value:i}}),i.value=r,n(o);return}n(o)}}function i(e,t){if(e){e.focus(t);var n=(t||{}).cursor;if(n){var r=e.value.length;switch(n){case"start":e.setSelectionRange(0,0);break;case"end":e.setSelectionRange(r,r);break;default:e.setSelectionRange(0,r)}}}}n.d(t,{He:function(){return r},X3:function(){return o},nH:function(){return i},rJ:function(){return a}})},47970:function(e,t,n){"use strict";n.d(t,{V4:function(){return ep},zt:function(){return x},ZP:function(){return em}});var r,o,a,i,c,l=n(11993),s=n(31686),u=n(26365),d=n(41154),f=n(36760),p=n.n(f),m=n(2868),g=n(28791),h=n(2265),v=n(6989),b=["children"],y=h.createContext({});function x(e){var t=e.children,n=(0,v.Z)(e,b);return h.createElement(y.Provider,{value:n},t)}var w=n(76405),E=n(25049),S=n(15354),C=n(15900),Z=function(e){(0,S.Z)(n,e);var t=(0,C.Z)(n);function n(){return(0,w.Z)(this,n),t.apply(this,arguments)}return(0,E.Z)(n,[{key:"render",value:function(){return this.props.children}}]),n}(h.Component),O=n(69819),k="none",M="appear",R="enter",j="leave",I="none",N="prepare",P="start",T="active",F="prepared",A=n(94981);function z(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit".concat(e)]="webkit".concat(t),n["Moz".concat(e)]="moz".concat(t),n["ms".concat(e)]="MS".concat(t),n["O".concat(e)]="o".concat(t.toLowerCase()),n}var L=(r=(0,A.Z)(),o="undefined"!=typeof window?window:{},a={animationend:z("Animation","AnimationEnd"),transitionend:z("Transition","TransitionEnd")},!r||("AnimationEvent"in o||delete a.animationend.animation,"TransitionEvent"in o||delete a.transitionend.transition),a),_={};(0,A.Z)()&&(_=document.createElement("div").style);var H={};function B(e){if(H[e])return H[e];var t=L[e];if(t)for(var n=Object.keys(t),r=n.length,o=0;o1&&void 0!==arguments[1]?arguments[1]:2;t();var a=(0,$.Z)(function(){o<=1?r({isCanceled:function(){return a!==e.current}}):n(r,o-1)});e.current=a},t]},Q=[N,P,T,"end"],J=[N,F];function ee(e){return e===T||"end"===e}var et=function(e,t,n){var r=(0,O.Z)(I),o=(0,u.Z)(r,2),a=o[0],i=o[1],c=Y(),l=(0,u.Z)(c,2),s=l[0],d=l[1],f=t?J:Q;return K(function(){if(a!==I&&"end"!==a){var e=f.indexOf(a),t=f[e+1],r=n(a);!1===r?i(t,!0):t&&s(function(e){function n(){e.isCanceled()||i(t,!0)}!0===r?n():Promise.resolve(r).then(n)})}},[e,a]),h.useEffect(function(){return function(){d()}},[]),[function(){i(N,!0)},a]},en=(i=V,"object"===(0,d.Z)(V)&&(i=V.transitionSupport),(c=h.forwardRef(function(e,t){var n=e.visible,r=void 0===n||n,o=e.removeOnLeave,a=void 0===o||o,c=e.forceRender,d=e.children,f=e.motionName,v=e.leavedClassName,b=e.eventProps,x=h.useContext(y).motion,w=!!(e.motionName&&i&&!1!==x),E=(0,h.useRef)(),S=(0,h.useRef)(),C=function(e,t,n,r){var o=r.motionEnter,a=void 0===o||o,i=r.motionAppear,c=void 0===i||i,d=r.motionLeave,f=void 0===d||d,p=r.motionDeadline,m=r.motionLeaveImmediately,g=r.onAppearPrepare,v=r.onEnterPrepare,b=r.onLeavePrepare,y=r.onAppearStart,x=r.onEnterStart,w=r.onLeaveStart,E=r.onAppearActive,S=r.onEnterActive,C=r.onLeaveActive,Z=r.onAppearEnd,I=r.onEnterEnd,A=r.onLeaveEnd,z=r.onVisibleChanged,L=(0,O.Z)(),_=(0,u.Z)(L,2),H=_[0],B=_[1],D=(0,O.Z)(k),W=(0,u.Z)(D,2),V=W[0],q=W[1],G=(0,O.Z)(null),X=(0,u.Z)(G,2),$=X[0],Y=X[1],Q=(0,h.useRef)(!1),J=(0,h.useRef)(null),en=(0,h.useRef)(!1);function er(){q(k,!0),Y(null,!0)}function eo(e){var t,r=n();if(!e||e.deadline||e.target===r){var o=en.current;V===M&&o?t=null==Z?void 0:Z(r,e):V===R&&o?t=null==I?void 0:I(r,e):V===j&&o&&(t=null==A?void 0:A(r,e)),V!==k&&o&&!1!==t&&er()}}var ea=U(eo),ei=(0,u.Z)(ea,1)[0],ec=function(e){var t,n,r;switch(e){case M:return t={},(0,l.Z)(t,N,g),(0,l.Z)(t,P,y),(0,l.Z)(t,T,E),t;case R:return n={},(0,l.Z)(n,N,v),(0,l.Z)(n,P,x),(0,l.Z)(n,T,S),n;case j:return r={},(0,l.Z)(r,N,b),(0,l.Z)(r,P,w),(0,l.Z)(r,T,C),r;default:return{}}},el=h.useMemo(function(){return ec(V)},[V]),es=et(V,!e,function(e){if(e===N){var t,r=el[N];return!!r&&r(n())}return ef in el&&Y((null===(t=el[ef])||void 0===t?void 0:t.call(el,n(),null))||null),ef===T&&(ei(n()),p>0&&(clearTimeout(J.current),J.current=setTimeout(function(){eo({deadline:!0})},p))),ef===F&&er(),!0}),eu=(0,u.Z)(es,2),ed=eu[0],ef=eu[1],ep=ee(ef);en.current=ep,K(function(){B(t);var n,r=Q.current;Q.current=!0,!r&&t&&c&&(n=M),r&&t&&a&&(n=R),(r&&!t&&f||!r&&m&&!t&&f)&&(n=j);var o=ec(n);n&&(e||o[N])?(q(n),ed()):q(k)},[t]),(0,h.useEffect)(function(){(V!==M||c)&&(V!==R||a)&&(V!==j||f)||q(k)},[c,a,f]),(0,h.useEffect)(function(){return function(){Q.current=!1,clearTimeout(J.current)}},[]);var em=h.useRef(!1);(0,h.useEffect)(function(){H&&(em.current=!0),void 0!==H&&V===k&&((em.current||H)&&(null==z||z(H)),em.current=!0)},[H,V]);var eg=$;return el[N]&&ef===P&&(eg=(0,s.Z)({transition:"none"},eg)),[V,ef,eg,null!=H?H:t]}(w,r,function(){try{return E.current instanceof HTMLElement?E.current:(0,m.Z)(S.current)}catch(e){return null}},e),I=(0,u.Z)(C,4),A=I[0],z=I[1],L=I[2],_=I[3],H=h.useRef(_);_&&(H.current=!0);var B=h.useCallback(function(e){E.current=e,(0,g.mH)(t,e)},[t]),D=(0,s.Z)((0,s.Z)({},b),{},{visible:r});if(d){if(A===k)W=_?d((0,s.Z)({},D),B):!a&&H.current&&v?d((0,s.Z)((0,s.Z)({},D),{},{className:v}),B):!c&&(a||v)?null:d((0,s.Z)((0,s.Z)({},D),{},{style:{display:"none"}}),B);else{z===N?q="prepare":ee(z)?q="active":z===P&&(q="start");var W,V,q,G=X(f,"".concat(A,"-").concat(q));W=d((0,s.Z)((0,s.Z)({},D),{},{className:p()(X(f,A),(V={},(0,l.Z)(V,G,G&&q),(0,l.Z)(V,f,"string"==typeof f),V)),style:L}),B)}}else W=null;return h.isValidElement(W)&&(0,g.Yr)(W)&&!W.ref&&(W=h.cloneElement(W,{ref:B})),h.createElement(Z,{ref:S},W)})).displayName="CSSMotion",c),er=n(1119),eo=n(63496),ea="keep",ei="remove",ec="removed";function el(e){var t;return t=e&&"object"===(0,d.Z)(e)&&"key"in e?e:{key:e},(0,s.Z)((0,s.Z)({},t),{},{key:String(t.key)})}function es(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];return e.map(el)}var eu=["component","children","onVisibleChanged","onAllRemoved"],ed=["status"],ef=["eventProps","visible","children","motionName","motionAppear","motionEnter","motionLeave","motionLeaveImmediately","motionDeadline","removeOnLeave","leavedClassName","onAppearPrepare","onAppearStart","onAppearActive","onAppearEnd","onEnterStart","onEnterActive","onEnterEnd","onLeaveStart","onLeaveActive","onLeaveEnd"],ep=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:en,n=function(e){(0,S.Z)(r,e);var n=(0,C.Z)(r);function r(){var e;(0,w.Z)(this,r);for(var t=arguments.length,o=Array(t),a=0;a0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=[],r=0,o=t.length,a=es(e),i=es(t);a.forEach(function(e){for(var t=!1,a=r;a1}).forEach(function(e){(n=n.filter(function(t){var n=t.key,r=t.status;return n!==e||r!==ei})).forEach(function(t){t.key===e&&(t.status=ea)})}),n})(r,es(n)).filter(function(e){var t=r.find(function(t){var n=t.key;return e.key===n});return!t||t.status!==ec||e.status!==ei})}}}]),r}(h.Component);return(0,l.Z)(n,"defaultProps",{component:"div"}),n}(V),em=en},49283:function(e,t,n){"use strict";n.d(t,{qX:function(){return g},JB:function(){return v},lm:function(){return O}});var r=n(83145),o=n(26365),a=n(6989),i=n(2265),c=n(31686),l=n(54887),s=n(1119),u=n(11993),d=n(36760),f=n.n(d),p=n(47970),m=n(95814),g=i.forwardRef(function(e,t){var n=e.prefixCls,r=e.style,a=e.className,c=e.duration,l=void 0===c?4.5:c,d=e.eventKey,p=e.content,g=e.closable,h=e.closeIcon,v=e.props,b=e.onClick,y=e.onNoticeClose,x=e.times,w=e.hovering,E=i.useState(!1),S=(0,o.Z)(E,2),C=S[0],Z=S[1],O=w||C,k=function(){y(d)};i.useEffect(function(){if(!O&&l>0){var e=setTimeout(function(){k()},1e3*l);return function(){clearTimeout(e)}}},[l,O,x]);var M="".concat(n,"-notice");return i.createElement("div",(0,s.Z)({},v,{ref:t,className:f()(M,a,(0,u.Z)({},"".concat(M,"-closable"),g)),style:r,onMouseEnter:function(e){var t;Z(!0),null==v||null===(t=v.onMouseEnter)||void 0===t||t.call(v,e)},onMouseLeave:function(e){var t;Z(!1),null==v||null===(t=v.onMouseLeave)||void 0===t||t.call(v,e)},onClick:b}),i.createElement("div",{className:"".concat(M,"-content")},p),g&&i.createElement("a",{tabIndex:0,className:"".concat(M,"-close"),onKeyDown:function(e){("Enter"===e.key||"Enter"===e.code||e.keyCode===m.Z.ENTER)&&k()},onClick:function(e){e.preventDefault(),e.stopPropagation(),k()}},void 0===h?"x":h))}),h=i.createContext({}),v=function(e){var t=e.children,n=e.classNames;return i.createElement(h.Provider,{value:{classNames:n}},t)},b=n(41154),y=function(e){var t,n,r,o={offset:8,threshold:3,gap:16};return e&&"object"===(0,b.Z)(e)&&(o.offset=null!==(t=e.offset)&&void 0!==t?t:8,o.threshold=null!==(n=e.threshold)&&void 0!==n?n:3,o.gap=null!==(r=e.gap)&&void 0!==r?r:16),[!!e,o]},x=["className","style","classNames","styles"],w=function(e){var t,n=e.configList,l=e.placement,d=e.prefixCls,m=e.className,v=e.style,b=e.motion,w=e.onAllNoticeRemoved,E=e.onNoticeClose,S=e.stack,C=(0,i.useContext)(h).classNames,Z=(0,i.useRef)({}),O=(0,i.useState)(null),k=(0,o.Z)(O,2),M=k[0],R=k[1],j=(0,i.useState)([]),I=(0,o.Z)(j,2),N=I[0],P=I[1],T=n.map(function(e){return{config:e,key:String(e.key)}}),F=y(S),A=(0,o.Z)(F,2),z=A[0],L=A[1],_=L.offset,H=L.threshold,B=L.gap,D=z&&(N.length>0||T.length<=H),W="function"==typeof b?b(l):b;return(0,i.useEffect)(function(){z&&N.length>1&&P(function(e){return e.filter(function(e){return T.some(function(t){return e===t.key})})})},[N,T,z]),(0,i.useEffect)(function(){var e,t;z&&Z.current[null===(e=T[T.length-1])||void 0===e?void 0:e.key]&&R(Z.current[null===(t=T[T.length-1])||void 0===t?void 0:t.key])},[T,z]),i.createElement(p.V4,(0,s.Z)({key:l,className:f()(d,"".concat(d,"-").concat(l),null==C?void 0:C.list,m,(t={},(0,u.Z)(t,"".concat(d,"-stack"),!!z),(0,u.Z)(t,"".concat(d,"-stack-expanded"),D),t)),style:v,keys:T,motionAppear:!0},W,{onAllRemoved:function(){w(l)}}),function(e,t){var n=e.config,o=e.className,u=e.style,p=e.index,m=n.key,h=n.times,v=String(m),b=n.className,y=n.style,w=n.classNames,S=n.styles,O=(0,a.Z)(n,x),k=T.findIndex(function(e){return e.key===v}),R={};if(z){var j=T.length-1-(k>-1?k:p-1),I="top"===l||"bottom"===l?"-50%":"0";if(j>0){R.height=D?null===(F=Z.current[v])||void 0===F?void 0:F.offsetHeight:null==M?void 0:M.offsetHeight;for(var F,A,L,H,W=0,V=0;V-1?Z.current[v]=e:delete Z.current[v]},prefixCls:d,classNames:w,styles:S,className:f()(b,null==C?void 0:C.notice),style:y,times:h,key:m,eventKey:m,onNoticeClose:E,hovering:z&&N.length>0})))})},E=i.forwardRef(function(e,t){var n=e.prefixCls,a=void 0===n?"rc-notification":n,s=e.container,u=e.motion,d=e.maxCount,f=e.className,p=e.style,m=e.onAllRemoved,g=e.stack,h=e.renderNotifications,v=i.useState([]),b=(0,o.Z)(v,2),y=b[0],x=b[1],E=function(e){var t,n=y.find(function(t){return t.key===e});null==n||null===(t=n.onClose)||void 0===t||t.call(n),x(function(t){return t.filter(function(t){return t.key!==e})})};i.useImperativeHandle(t,function(){return{open:function(e){x(function(t){var n,o=(0,r.Z)(t),a=o.findIndex(function(t){return t.key===e.key}),i=(0,c.Z)({},e);return a>=0?(i.times=((null===(n=t[a])||void 0===n?void 0:n.times)||0)+1,o[a]=i):(i.times=0,o.push(i)),d>0&&o.length>d&&(o=o.slice(-d)),o})},close:function(e){E(e)},destroy:function(){x([])}}});var S=i.useState({}),C=(0,o.Z)(S,2),Z=C[0],O=C[1];i.useEffect(function(){var e={};y.forEach(function(t){var n=t.placement,r=void 0===n?"topRight":n;r&&(e[r]=e[r]||[],e[r].push(t))}),Object.keys(Z).forEach(function(t){e[t]=e[t]||[]}),O(e)},[y]);var k=function(e){O(function(t){var n=(0,c.Z)({},t);return(n[e]||[]).length||delete n[e],n})},M=i.useRef(!1);if(i.useEffect(function(){Object.keys(Z).length>0?M.current=!0:M.current&&(null==m||m(),M.current=!1)},[Z]),!s)return null;var R=Object.keys(Z);return(0,l.createPortal)(i.createElement(i.Fragment,null,R.map(function(e){var t=Z[e],n=i.createElement(w,{key:e,configList:t,placement:e,prefixCls:a,className:null==f?void 0:f(e),style:null==p?void 0:p(e),motion:u,onNoticeClose:E,onAllNoticeRemoved:k,stack:g});return h?h(n,{prefixCls:a,key:e}):n})),s)}),S=["getContainer","motion","prefixCls","maxCount","className","style","onAllRemoved","stack","renderNotifications"],C=function(){return document.body},Z=0;function O(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.getContainer,n=void 0===t?C:t,c=e.motion,l=e.prefixCls,s=e.maxCount,u=e.className,d=e.style,f=e.onAllRemoved,p=e.stack,m=e.renderNotifications,g=(0,a.Z)(e,S),h=i.useState(),v=(0,o.Z)(h,2),b=v[0],y=v[1],x=i.useRef(),w=i.createElement(E,{container:b,ref:x,prefixCls:l,motion:c,maxCount:s,className:u,style:d,onAllRemoved:f,stack:p,renderNotifications:m}),O=i.useState([]),k=(0,o.Z)(O,2),M=k[0],R=k[1],j=i.useMemo(function(){return{open:function(e){var t=function(){for(var e={},t=arguments.length,n=Array(t),r=0;rP,eR=(0,c.useMemo)(function(){var e=x;return eO?e=null===q&&B?x:x.slice(0,Math.min(x.length,X/R)):"number"==typeof P&&(e=x.slice(0,P)),e},[x,R,q,P,eO]),ej=(0,c.useMemo)(function(){return eO?x.slice(eb+1):x.slice(eR.length)},[x,eR,eO,eb]),eI=(0,c.useCallback)(function(e,t){var n;return"function"==typeof S?S(e):null!==(n=S&&(null==e?void 0:e[S]))&&void 0!==n?n:t},[S]),eN=(0,c.useCallback)(w||function(e){return e},[w]);function eP(e,t,n){(eh!==e||void 0!==t&&t!==ef)&&(ev(e),n||(eE(eX){eP(r-1,e-o-el+eo);break}}A&&eF(0)+el>X&&ep(null)}},[X,$,eo,el,eI,eR]);var eA=ew&&!!ej.length,ez={};null!==ef&&eO&&(ez={position:"absolute",left:ef,top:0});var eL={prefixCls:eS,responsive:eO,component:L,invalidate:ek},e_=E?function(e,t){var n=eI(e,t);return c.createElement(y.Provider,{key:n,value:(0,o.Z)((0,o.Z)({},eL),{},{order:t,item:e,itemKey:n,registerSize:eT,display:t<=eb})},E(e,t))}:function(e,t){var n=eI(e,t);return c.createElement(m,(0,r.Z)({},eL,{order:t,key:n,item:e,renderItem:eN,itemKey:n,registerSize:eT,display:t<=eb}))},eH={order:eA?eb:Number.MAX_SAFE_INTEGER,className:"".concat(eS,"-rest"),registerSize:function(e,t){ea(t),et(eo)},display:eA};if(F)F&&(l=c.createElement(y.Provider,{value:(0,o.Z)((0,o.Z)({},eL),eH)},F(ej)));else{var eB=T||k;l=c.createElement(m,(0,r.Z)({},eL,eH),"function"==typeof eB?eB(ej):eB)}var eD=c.createElement(void 0===z?"div":z,(0,r.Z)({className:s()(!ek&&p,N),style:I,ref:t},H),eR.map(e_),eM?l:null,A&&c.createElement(m,(0,r.Z)({},eL,{responsive:eZ,responsiveDisabled:!eO,order:eb,className:"".concat(eS,"-suffix"),registerSize:function(e,t){es(t)},display:!0,style:ez}),A));return eZ&&(eD=c.createElement(u.Z,{onResize:function(e,t){G(t.clientWidth)},disabled:!eO},eD)),eD});M.displayName="Overflow",M.Item=S,M.RESPONSIVE=Z,M.INVALIDATE=O;var R=M},96257:function(e,t){"use strict";t.Z={items_per_page:"/ page",jump_to:"Go to",jump_to_confirm:"confirm",page:"Page",prev_page:"Previous Page",next_page:"Next Page",prev_5:"Previous 5 Pages",next_5:"Next 5 Pages",prev_3:"Previous 3 Pages",next_3:"Next 3 Pages",page_size:"Page Size"}},31474:function(e,t,n){"use strict";n.d(t,{Z:function(){return H}});var r=n(1119),o=n(2265),a=n(45287);n(32559);var i=n(31686),c=n(41154),l=n(2868),s=n(28791),u=o.createContext(null),d=function(){if("undefined"!=typeof Map)return Map;function e(e,t){var n=-1;return e.some(function(e,r){return e[0]===t&&(n=r,!0)}),n}return function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(t){var n=e(this.__entries__,t),r=this.__entries__[n];return r&&r[1]},t.prototype.set=function(t,n){var r=e(this.__entries__,t);~r?this.__entries__[r][1]=n:this.__entries__.push([t,n])},t.prototype.delete=function(t){var n=this.__entries__,r=e(n,t);~r&&n.splice(r,1)},t.prototype.has=function(t){return!!~e(this.__entries__,t)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(e,t){void 0===t&&(t=null);for(var n=0,r=this.__entries__;n0},e.prototype.connect_=function(){f&&!this.connected_&&(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),h?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){f&&this.connected_&&(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(e){var t=e.propertyName,n=void 0===t?"":t;g.some(function(e){return!!~n.indexOf(e)})&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e}(),b=function(e,t){for(var n=0,r=Object.keys(t);n0},e}(),M="undefined"!=typeof WeakMap?new WeakMap:new d,R=function e(t){if(!(this instanceof e))throw TypeError("Cannot call a class as a function.");if(!arguments.length)throw TypeError("1 argument required, but only 0 present.");var n=new k(t,v.getInstance(),this);M.set(this,n)};["observe","unobserve","disconnect"].forEach(function(e){R.prototype[e]=function(){var t;return(t=M.get(this))[e].apply(t,arguments)}});var j=void 0!==p.ResizeObserver?p.ResizeObserver:R,I=new Map,N=new j(function(e){e.forEach(function(e){var t,n=e.target;null===(t=I.get(n))||void 0===t||t.forEach(function(e){return e(n)})})}),P=n(76405),T=n(25049),F=n(15354),A=n(15900),z=function(e){(0,F.Z)(n,e);var t=(0,A.Z)(n);function n(){return(0,P.Z)(this,n),t.apply(this,arguments)}return(0,T.Z)(n,[{key:"render",value:function(){return this.props.children}}]),n}(o.Component),L=o.forwardRef(function(e,t){var n=e.children,r=e.disabled,a=o.useRef(null),d=o.useRef(null),f=o.useContext(u),p="function"==typeof n,m=p?n(a):n,g=o.useRef({width:-1,height:-1,offsetWidth:-1,offsetHeight:-1}),h=!p&&o.isValidElement(m)&&(0,s.Yr)(m),v=h?m.ref:null,b=(0,s.x1)(v,a),y=function(){var e;return(0,l.Z)(a.current)||(a.current&&"object"===(0,c.Z)(a.current)?(0,l.Z)(null===(e=a.current)||void 0===e?void 0:e.nativeElement):null)||(0,l.Z)(d.current)};o.useImperativeHandle(t,function(){return y()});var x=o.useRef(e);x.current=e;var w=o.useCallback(function(e){var t=x.current,n=t.onResize,r=t.data,o=e.getBoundingClientRect(),a=o.width,c=o.height,l=e.offsetWidth,s=e.offsetHeight,u=Math.floor(a),d=Math.floor(c);if(g.current.width!==u||g.current.height!==d||g.current.offsetWidth!==l||g.current.offsetHeight!==s){var p={width:u,height:d,offsetWidth:l,offsetHeight:s};g.current=p;var m=(0,i.Z)((0,i.Z)({},p),{},{offsetWidth:l===Math.round(a)?a:l,offsetHeight:s===Math.round(c)?c:s});null==f||f(m,e,r),n&&Promise.resolve().then(function(){n(m,e)})}},[]);return o.useEffect(function(){var e=y();return e&&!r&&(I.has(e)||(I.set(e,new Set),N.observe(e)),I.get(e).add(w)),function(){I.has(e)&&(I.get(e).delete(w),I.get(e).size||(N.unobserve(e),I.delete(e)))}},[a.current,r]),o.createElement(z,{ref:d},h?o.cloneElement(m,{ref:b}):m)}),_=o.forwardRef(function(e,t){var n=e.children;return("function"==typeof n?[n]:(0,a.Z)(n)).map(function(n,a){var i=(null==n?void 0:n.key)||"".concat("rc-observer-key","-").concat(a);return o.createElement(L,(0,r.Z)({},e,{key:i,ref:0===a?t:void 0}),n)})});_.Collection=function(e){var t=e.children,n=e.onBatchResize,r=o.useRef(0),a=o.useRef([]),i=o.useContext(u),c=o.useCallback(function(e,t,o){r.current+=1;var c=r.current;a.current.push({size:e,element:t,data:o}),Promise.resolve().then(function(){c===r.current&&(null==n||n(a.current),a.current=[])}),null==i||i(e,t,o)},[n,i]);return o.createElement(u.Provider,{value:c},t)};var H=_},5769:function(e,t,n){"use strict";n.d(t,{G:function(){return i},Z:function(){return h}});var r=n(36760),o=n.n(r),a=n(2265);function i(e){var t=e.children,n=e.prefixCls,r=e.id,i=e.overlayInnerStyle,c=e.className,l=e.style;return a.createElement("div",{className:o()("".concat(n,"-content"),c),style:l},a.createElement("div",{className:"".concat(n,"-inner"),id:r,role:"tooltip",style:i},"function"==typeof t?t():t))}var c=n(1119),l=n(31686),s=n(6989),u=n(97821),d={shiftX:64,adjustY:1},f={adjustX:1,shiftY:!0},p=[0,0],m={left:{points:["cr","cl"],overflow:f,offset:[-4,0],targetOffset:p},right:{points:["cl","cr"],overflow:f,offset:[4,0],targetOffset:p},top:{points:["bc","tc"],overflow:d,offset:[0,-4],targetOffset:p},bottom:{points:["tc","bc"],overflow:d,offset:[0,4],targetOffset:p},topLeft:{points:["bl","tl"],overflow:d,offset:[0,-4],targetOffset:p},leftTop:{points:["tr","tl"],overflow:f,offset:[-4,0],targetOffset:p},topRight:{points:["br","tr"],overflow:d,offset:[0,-4],targetOffset:p},rightTop:{points:["tl","tr"],overflow:f,offset:[4,0],targetOffset:p},bottomRight:{points:["tr","br"],overflow:d,offset:[0,4],targetOffset:p},rightBottom:{points:["bl","br"],overflow:f,offset:[4,0],targetOffset:p},bottomLeft:{points:["tl","bl"],overflow:d,offset:[0,4],targetOffset:p},leftBottom:{points:["br","bl"],overflow:f,offset:[-4,0],targetOffset:p}},g=["overlayClassName","trigger","mouseEnterDelay","mouseLeaveDelay","overlayStyle","prefixCls","children","onVisibleChange","afterVisibleChange","transitionName","animation","motion","placement","align","destroyTooltipOnHide","defaultVisible","getTooltipContainer","overlayInnerStyle","arrowContent","overlay","id","showArrow"],h=(0,a.forwardRef)(function(e,t){var n=e.overlayClassName,r=e.trigger,o=e.mouseEnterDelay,d=e.mouseLeaveDelay,f=e.overlayStyle,p=e.prefixCls,h=void 0===p?"rc-tooltip":p,v=e.children,b=e.onVisibleChange,y=e.afterVisibleChange,x=e.transitionName,w=e.animation,E=e.motion,S=e.placement,C=e.align,Z=e.destroyTooltipOnHide,O=e.defaultVisible,k=e.getTooltipContainer,M=e.overlayInnerStyle,R=(e.arrowContent,e.overlay),j=e.id,I=e.showArrow,N=(0,s.Z)(e,g),P=(0,a.useRef)(null);(0,a.useImperativeHandle)(t,function(){return P.current});var T=(0,l.Z)({},N);return"visible"in e&&(T.popupVisible=e.visible),a.createElement(u.Z,(0,c.Z)({popupClassName:n,prefixCls:h,popup:function(){return a.createElement(i,{key:"content",prefixCls:h,id:j,overlayInnerStyle:M},R)},action:void 0===r?["hover"]:r,builtinPlacements:m,popupPlacement:void 0===S?"right":S,ref:P,popupAlign:void 0===C?{}:C,getPopupContainer:k,onPopupVisibleChange:b,afterPopupVisibleChange:y,popupTransitionName:x,popupAnimation:w,popupMotion:E,defaultPopupVisible:O,autoDestroy:void 0!==Z&&Z,mouseLeaveDelay:void 0===d?.1:d,popupStyle:f,mouseEnterDelay:void 0===o?0:o,arrow:void 0===I||I},T),v)})},45287:function(e,t,n){"use strict";n.d(t,{Z:function(){return function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=[];return r.Children.forEach(t,function(t){(null!=t||n.keepEmpty)&&(Array.isArray(t)?a=a.concat(e(t)):(0,o.isFragment)(t)&&t.props?a=a.concat(e(t.props.children,n)):a.push(t))}),a}}});var r=n(2265),o=n(93754)},94981:function(e,t,n){"use strict";function r(){return!!("undefined"!=typeof window&&window.document&&window.document.createElement)}n.d(t,{Z:function(){return r}})},2161:function(e,t,n){"use strict";function r(e,t){if(!e)return!1;if(e.contains)return e.contains(t);for(var n=t;n;){if(n===e)return!0;n=n.parentNode}return!1}n.d(t,{Z:function(){return r}})},21717:function(e,t,n){"use strict";n.d(t,{hq:function(){return m},jL:function(){return p}});var r=n(94981),o=n(2161),a="data-rc-order",i="data-rc-priority",c=new Map;function l(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.mark;return t?t.startsWith("data-")?t:"data-".concat(t):"rc-util-key"}function s(e){return e.attachTo?e.attachTo:document.querySelector("head")||document.body}function u(e){return Array.from((c.get(e)||e).children).filter(function(e){return"STYLE"===e.tagName})}function d(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!(0,r.Z)())return null;var n=t.csp,o=t.prepend,c=t.priority,l=void 0===c?0:c,d="queue"===o?"prependQueue":o?"prepend":"append",f="prependQueue"===d,p=document.createElement("style");p.setAttribute(a,d),f&&l&&p.setAttribute(i,"".concat(l)),null!=n&&n.nonce&&(p.nonce=null==n?void 0:n.nonce),p.innerHTML=e;var m=s(t),g=m.firstChild;if(o){if(f){var h=u(m).filter(function(e){return!!["prepend","prependQueue"].includes(e.getAttribute(a))&&l>=Number(e.getAttribute(i)||0)});if(h.length)return m.insertBefore(p,h[h.length-1].nextSibling),p}m.insertBefore(p,g)}else m.appendChild(p);return p}function f(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return u(s(t)).find(function(n){return n.getAttribute(l(t))===e})}function p(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=f(e,t);n&&s(t).removeChild(n)}function m(e,t){var n,r,a,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};!function(e,t){var n=c.get(e);if(!n||!(0,o.Z)(document,n)){var r=d("",t),a=r.parentNode;c.set(e,a),e.removeChild(r)}}(s(i),i);var u=f(t,i);if(u)return null!==(n=i.csp)&&void 0!==n&&n.nonce&&u.nonce!==(null===(r=i.csp)||void 0===r?void 0:r.nonce)&&(u.nonce=null===(a=i.csp)||void 0===a?void 0:a.nonce),u.innerHTML!==e&&(u.innerHTML=e),u;var p=d(e,i);return p.setAttribute(l(i),t),p}},2868:function(e,t,n){"use strict";n.d(t,{S:function(){return a},Z:function(){return i}});var r=n(2265),o=n(54887);function a(e){return e instanceof HTMLElement||e instanceof SVGElement}function i(e){return a(e)?e:e instanceof r.Component?o.findDOMNode(e):null}},2857:function(e,t){"use strict";t.Z=function(e){if(!e)return!1;if(e instanceof Element){if(e.offsetParent)return!0;if(e.getBBox){var t=e.getBBox(),n=t.width,r=t.height;if(n||r)return!0}if(e.getBoundingClientRect){var o=e.getBoundingClientRect(),a=o.width,i=o.height;if(a||i)return!0}}return!1}},13211:function(e,t,n){"use strict";function r(e){var t;return null==e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}function o(e){return r(e) instanceof ShadowRoot?r(e):null}n.d(t,{A:function(){return o}})},95814:function(e,t){"use strict";var n={MAC_ENTER:3,BACKSPACE:8,TAB:9,NUM_CENTER:12,ENTER:13,SHIFT:16,CTRL:17,ALT:18,PAUSE:19,CAPS_LOCK:20,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,PRINT_SCREEN:44,INSERT:45,DELETE:46,ZERO:48,ONE:49,TWO:50,THREE:51,FOUR:52,FIVE:53,SIX:54,SEVEN:55,EIGHT:56,NINE:57,QUESTION_MARK:63,A:65,B:66,C:67,D:68,E:69,F:70,G:71,H:72,I:73,J:74,K:75,L:76,M:77,N:78,O:79,P:80,Q:81,R:82,S:83,T:84,U:85,V:86,W:87,X:88,Y:89,Z:90,META:91,WIN_KEY_RIGHT:92,CONTEXT_MENU:93,NUM_ZERO:96,NUM_ONE:97,NUM_TWO:98,NUM_THREE:99,NUM_FOUR:100,NUM_FIVE:101,NUM_SIX:102,NUM_SEVEN:103,NUM_EIGHT:104,NUM_NINE:105,NUM_MULTIPLY:106,NUM_PLUS:107,NUM_MINUS:109,NUM_PERIOD:110,NUM_DIVISION:111,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,NUMLOCK:144,SEMICOLON:186,DASH:189,EQUALS:187,COMMA:188,PERIOD:190,SLASH:191,APOSTROPHE:192,SINGLE_QUOTE:222,OPEN_SQUARE_BRACKET:219,BACKSLASH:220,CLOSE_SQUARE_BRACKET:221,WIN_KEY:224,MAC_FF_META:224,WIN_IME:229,isTextModifyingKeyEvent:function(e){var t=e.keyCode;if(e.altKey&&!e.ctrlKey||e.metaKey||t>=n.F1&&t<=n.F12)return!1;switch(t){case n.ALT:case n.CAPS_LOCK:case n.CONTEXT_MENU:case n.CTRL:case n.DOWN:case n.END:case n.ESC:case n.HOME:case n.INSERT:case n.LEFT:case n.MAC_FF_META:case n.META:case n.NUMLOCK:case n.NUM_CENTER:case n.PAGE_DOWN:case n.PAGE_UP:case n.PAUSE:case n.PRINT_SCREEN:case n.RIGHT:case n.SHIFT:case n.UP:case n.WIN_KEY:case n.WIN_KEY_RIGHT:return!1;default:return!0}},isCharacterKey:function(e){if(e>=n.ZERO&&e<=n.NINE||e>=n.NUM_ZERO&&e<=n.NUM_MULTIPLY||e>=n.A&&e<=n.Z||-1!==window.navigator.userAgent.indexOf("WebKit")&&0===e)return!0;switch(e){case n.SPACE:case n.QUESTION_MARK:case n.NUM_PLUS:case n.NUM_MINUS:case n.NUM_PERIOD:case n.NUM_DIVISION:case n.SEMICOLON:case n.DASH:case n.EQUALS:case n.COMMA:case n.PERIOD:case n.SLASH:case n.APOSTROPHE:case n.SINGLE_QUOTE:case n.OPEN_SQUARE_BRACKET:case n.BACKSLASH:case n.CLOSE_SQUARE_BRACKET:return!0;default:return!1}}};t.Z=n},18404:function(e,t,n){"use strict";n.d(t,{s:function(){return h},v:function(){return b}});var r,o,a=n(73129),i=n(54580),c=n(41154),l=n(31686),s=n(54887),u=(0,l.Z)({},r||(r=n.t(s,2))),d=u.version,f=u.render,p=u.unmountComponentAtNode;try{Number((d||"").split(".")[0])>=18&&(o=u.createRoot)}catch(e){}function m(e){var t=u.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;t&&"object"===(0,c.Z)(t)&&(t.usingClientEntryPoint=e)}var g="__rc_react_root__";function h(e,t){if(o){var n;m(!0),n=t[g]||o(t),m(!1),n.render(e),t[g]=n;return}f(e,t)}function v(){return(v=(0,i.Z)((0,a.Z)().mark(function e(t){return(0,a.Z)().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.abrupt("return",Promise.resolve().then(function(){var e;null===(e=t[g])||void 0===e||e.unmount(),delete t[g]}));case 1:case"end":return e.stop()}},e)}))).apply(this,arguments)}function b(e){return y.apply(this,arguments)}function y(){return(y=(0,i.Z)((0,a.Z)().mark(function e(t){return(0,a.Z)().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(!(void 0!==o)){e.next=2;break}return e.abrupt("return",function(e){return v.apply(this,arguments)}(t));case 2:p(t);case 3:case"end":return e.stop()}},e)}))).apply(this,arguments)}},3208:function(e,t,n){"use strict";var r;function o(e){if("undefined"==typeof document)return 0;if(e||void 0===r){var t=document.createElement("div");t.style.width="100%",t.style.height="200px";var n=document.createElement("div"),o=n.style;o.position="absolute",o.top="0",o.left="0",o.pointerEvents="none",o.visibility="hidden",o.width="200px",o.height="150px",o.overflow="hidden",n.appendChild(t),document.body.appendChild(n);var a=t.offsetWidth;n.style.overflow="scroll";var i=t.offsetWidth;a===i&&(i=n.clientWidth),document.body.removeChild(n),r=a-i}return r}function a(e){var t=e.match(/^(.*)px$/),n=Number(null==t?void 0:t[1]);return Number.isNaN(n)?o():n}function i(e){if("undefined"==typeof document||!e||!(e instanceof Element))return{width:0,height:0};var t=getComputedStyle(e,"::-webkit-scrollbar"),n=t.width,r=t.height;return{width:a(n),height:a(r)}}n.d(t,{Z:function(){return o},o:function(){return i}})},58525:function(e,t,n){"use strict";n.d(t,{Z:function(){return o}});var r=n(2265);function o(e){var t=r.useRef();return t.current=e,r.useCallback(function(){for(var e,n=arguments.length,r=Array(n),o=0;o2&&void 0!==arguments[2]&&arguments[2],a=new Set;return function e(t,i){var c=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,l=a.has(t);if((0,o.ZP)(!l,"Warning: There may be circular references"),l)return!1;if(t===i)return!0;if(n&&c>1)return!1;a.add(t);var s=c+1;if(Array.isArray(t)){if(!Array.isArray(i)||t.length!==i.length)return!1;for(var u=0;u