repo_id
stringlengths
15
132
file_path
stringlengths
34
176
content
stringlengths
2
3.52M
__index_level_0__
int64
0
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/unittests/test_mlflow_dependencies.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import pytest import promptflow import promptflow._sdk._mlflow as module @pytest.mark.sdk_test @pytest.mark.unittest class TestMLFlowDependencies: def test_mlflow_dependencies(self): assert module.DAG_FILE_NAME == "flow.dag.yaml" assert module.Flow == promptflow._sdk.entities._flow.Flow assert module.FlowInvoker == promptflow._sdk._serving.flow_invoker.FlowInvoker assert module.remove_additional_includes is not None assert module._merge_local_code_and_additional_includes is not None
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/unittests/test_cli_activity_name.py
import pytest from promptflow._cli._pf.entry import get_parser_args from promptflow._cli._utils import _get_cli_activity_name def get_cli_activity_name(cmd): prog, args = get_parser_args(list(cmd)[1:]) return _get_cli_activity_name(cli=prog, args=args) @pytest.mark.unittest class TestCliTimeConsume: def test_pf_run_create(self, activity_name="pf.run.create") -> None: assert get_cli_activity_name( cmd=( "pf", "run", "create", "--flow", "print_input_flow", "--data", "print_input_flow.jsonl", )) == activity_name def test_pf_run_update(self, activity_name="pf.run.update") -> None: assert get_cli_activity_name( cmd=( "pf", "run", "update", "--name", "test_name", "--set", "description=test pf run update" )) == activity_name def test_pf_flow_test(self, activity_name="pf.flow.test"): assert get_cli_activity_name( cmd=( "pf", "flow", "test", "--flow", "print_input_flow", "--inputs", "text=https://www.youtube.com/watch?v=o5ZQyXaAv1g", )) == activity_name def test_pf_flow_build(self, activity_name="pf.flow.build"): assert get_cli_activity_name( cmd=( "pf", "flow", "build", "--source", "print_input_flow/flow.dag.yaml", "--output", "./", "--format", "docker", )) == activity_name def test_pf_connection_create(self, activity_name="pf.connection.create"): assert get_cli_activity_name( cmd=( "pf", "connection", "create", "--file", "azure_openai_connection.yaml", "--name", "test_name", )) == activity_name def test_pf_connection_list(self, activity_name="pf.connection.list"): assert get_cli_activity_name(cmd=("pf", "connection", "list")) == activity_name
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/unittests/test_config.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from pathlib import Path import pytest from promptflow._sdk._configuration import Configuration, InvalidConfigValue from promptflow._sdk._constants import FLOW_DIRECTORY_MACRO_IN_CONFIG from promptflow._sdk._utils import ClientUserAgentUtil CONFIG_DATA_ROOT = Path(__file__).parent.parent.parent / "test_configs" / "configs" @pytest.fixture def config(): return Configuration.get_instance() @pytest.mark.unittest class TestConfig: def test_set_config(self, config): config.set_config("a.b.c.test_key", "test_value") assert config.get_config("a.b.c.test_key") == "test_value" # global config may contain other keys assert config.config["a"] == {"b": {"c": {"test_key": "test_value"}}} def test_get_config(self, config): config.set_config("test_key", "test_value") assert config.get_config("test_key") == "test_value" def test_get_or_set_installation_id(self, config): user_id = config.get_or_set_installation_id() assert user_id is not None def test_config_instance(self, config): new_config = Configuration.get_instance() assert new_config is config def test_set_invalid_run_output_path(self, config: Configuration) -> None: expected_error_message = ( "Cannot specify flow directory as run output path; " "if you want to specify run output path under flow directory, " "please use its child folder, e.g. '${flow_directory}/.runs'." ) # directly set with pytest.raises(InvalidConfigValue) as e: config.set_config(key=Configuration.RUN_OUTPUT_PATH, value=FLOW_DIRECTORY_MACRO_IN_CONFIG) assert expected_error_message in str(e) # override with pytest.raises(InvalidConfigValue) as e: Configuration(overrides={Configuration.RUN_OUTPUT_PATH: FLOW_DIRECTORY_MACRO_IN_CONFIG}) assert expected_error_message in str(e) def test_ua_set_load(self, config: Configuration) -> None: config.set_config(key=Configuration.USER_AGENT, value="test/1.0.0") user_agent = config.get_user_agent() assert user_agent == "PFCustomer_test/1.0.0" # load empty ua won't break config.set_config(key=Configuration.USER_AGENT, value="") user_agent = config.get_user_agent() assert user_agent == "" # empty ua won't add to context ClientUserAgentUtil.update_user_agent_from_config() user_agent = ClientUserAgentUtil.get_user_agent() # in test environment, user agent may contain promptflow-local-serving/0.0.1 test-user-agent assert "test/1.0.0" not in user_agent
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/recording_utilities/record_storage.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import hashlib import json import os import shelve from pathlib import Path from typing import Dict from filelock import FileLock from promptflow.exceptions import PromptflowException from .constants import ENVIRON_TEST_MODE, RecordMode class RecordItemMissingException(PromptflowException): """Exception raised when record item missing.""" pass class RecordFileMissingException(PromptflowException): """Exception raised when record file missing or invalid.""" pass class RecordStorage(object): """ RecordStorage is used to store the record of node run. File often stored in .promptflow/node_cache.shelve Currently only text input/output could be recorded. Example of cached items: { "/record/file/resolved": { "hash_value": { # hash_value is sha1 of dict, accelerate the search "input": { "key1": "value1", # Converted to string, type info dropped }, "output": "output_convert_to_string", "output_type": "output_type" # Currently support only simple strings. } } } """ _standard_record_folder = ".promptflow" _standard_record_name = "node_cache.shelve" _instance = None def __init__(self, record_file: str = None): """ RecordStorage is used to store the record of node run. """ self._record_file: Path = None self.cached_items: Dict[str, Dict[str, Dict[str, object]]] = {} self.record_file = record_file @property def record_file(self) -> Path: return self._record_file @record_file.setter def record_file(self, record_file_input) -> None: """ Will load record_file if exist. """ if record_file_input == self._record_file: return if isinstance(record_file_input, str): self._record_file = Path(record_file_input).resolve() elif isinstance(record_file_input, Path): self._record_file = record_file_input.resolve() else: return if not self._record_file.parts[-1].endswith(RecordStorage._standard_record_name): record_folder = self._record_file / RecordStorage._standard_record_folder self._record_file = record_folder / RecordStorage._standard_record_name else: record_folder = self._record_file.parent self._record_file_str = str(self._record_file.resolve()) # cache folder we could create if not exist. if not record_folder.exists(): record_folder.mkdir(parents=True, exist_ok=True) # if file exist, load file if self.exists_record_file(record_folder, self._record_file.parts[-1]): self._load_file() else: self.cached_items = { self._record_file_str: {}, } def exists_record_file(self, record_folder, file_name) -> bool: files = os.listdir(record_folder) for file in files: if file.startswith(file_name): return True return False def _write_file(self, hashkey) -> None: file_content = self.cached_items.get(self._record_file_str, None) if file_content is not None: file_content_line = file_content.get(hashkey, None) if file_content_line is not None: lock = FileLock(self.record_file.parent / "record_file.lock") with lock: saved_dict = shelve.open(self._record_file_str, "c", writeback=False) saved_dict[hashkey] = file_content_line saved_dict.close() else: raise RecordItemMissingException(f"Record item not found in cache with hashkey {hashkey}.") else: raise RecordFileMissingException( f"This exception should not happen here, but record file is not found {self._record_file_str}." ) def _load_file(self) -> None: local_content = self.cached_items.get(self._record_file_str, None) if not local_content: if RecordStorage.is_recording_mode(): lock = FileLock(self.record_file.parent / "record_file.lock") with lock: if not self.exists_record_file(self.record_file.parent, self.record_file.parts[-1]): return self.cached_items[self._record_file_str] = {} saved_dict = shelve.open(self._record_file_str, "r", writeback=False) for key, value in saved_dict.items(): self.cached_items[self._record_file_str][key] = value saved_dict.close() else: if not self.exists_record_file(self.record_file.parent, self.record_file.parts[-1]): return self.cached_items[self._record_file_str] = {} saved_dict = shelve.open(self._record_file_str, "r", writeback=False) for key, value in saved_dict.items(): self.cached_items[self._record_file_str][key] = value saved_dict.close() def delete_lock_file(self): lock_file = self.record_file.parent / "record_file.lock" if lock_file.exists(): os.remove(lock_file) def get_record(self, input_dict: Dict) -> object: """ Get record from local storage. :param input_dict: input dict of critical AOAI inputs :type input_dict: Dict :raises RecordFileMissingException: Record file not exist :raises RecordItemMissingException: Record item not exist in record file :return: original output of node run :rtype: object """ input_dict = self._recursive_create_hashable_args(input_dict) hash_value: str = hashlib.sha1(str(sorted(input_dict.items())).encode("utf-8")).hexdigest() current_saved_records: Dict[str, str] = self.cached_items.get(self._record_file_str, None) if current_saved_records is None: raise RecordFileMissingException(f"Record file not found {self.record_file}.") saved_output = current_saved_records.get(hash_value, None) if saved_output is None: raise RecordItemMissingException( f"Record item not found in file {self.record_file}.\n" f"values: {json.dumps(input_dict)}\n" ) # not all items are reserved in the output dict. output = saved_output["output"] output_type = saved_output["output_type"] if "generator" in output_type: return self._create_output_generator(output, output_type) else: return output def _recursive_create_hashable_args(self, item): if isinstance(item, tuple): return [self._recursive_create_hashable_args(i) for i in item] if isinstance(item, list): return [self._recursive_create_hashable_args(i) for i in item] if isinstance(item, dict): return {k: self._recursive_create_hashable_args(v) for k, v in item.items()} elif "module: promptflow.connections" in str(item) or "object at" in str(item): return [] else: return item def _parse_output_generator(self, output): """ Special handling for generator type. Since pickle will not work for generator. Returns the real list for reocrding, and create a generator for original output. Parse output has a simplified hypothesis: output is simple dict, list or generator, because a full schema of output is too heavy to handle. Example: {"answer": <generator>, "a": "b"}, <generator> """ output_type = "" output_value = None output_generator = None if isinstance(output, dict): output_value = {} output_generator = {} for item in output.items(): k, v = item if type(v).__name__ == "generator": vlist = list(v) def vgenerator(): for vitem in vlist: yield vitem output_value[k] = vlist output_generator[k] = vgenerator() output_type = "dict[generator]" else: output_value[k] = v elif type(output).__name__ == "generator": output_value = list(output) def generator(): for item in output_value: yield item output_generator = generator() output_type = "generator" else: output_value = output output_generator = None output_type = type(output).__name__ return output_value, output_generator, output_type def _create_output_generator(self, output, output_type): """ Special handling for generator type. Returns a generator for original output. Create output has a simplified hypothesis: All list with output type generator is treated as generator. """ output_generator = None if output_type == "dict[generator]": output_generator = {} for k, v in output.items(): if type(v).__name__ == "list": def vgenerator(): for item in v: yield item output_generator[k] = vgenerator() else: output_generator[k] = v elif output_type == "generator": def generator(): for item in output: yield item output_generator = generator() return output_generator def set_record(self, input_dict: Dict, output): """ Set record to local storage, always override the old record. :param input_dict: input dict of critical AOAI inputs :type input_dict: OrderedDict :param output: original output of node run :type output: object """ # filter args, object at will not hash input_dict = self._recursive_create_hashable_args(input_dict) hash_value: str = hashlib.sha1(str(sorted(input_dict.items())).encode("utf-8")).hexdigest() current_saved_records: Dict[str, str] = self.cached_items.get(self._record_file_str, None) output_value, output_generator, output_type = self._parse_output_generator(output) if current_saved_records is None: current_saved_records = {} current_saved_records[hash_value] = { "input": input_dict, "output": output_value, "output_type": output_type, } else: saved_output = current_saved_records.get(hash_value, None) if saved_output is not None: if saved_output["output"] == output_value and saved_output["output_type"] == output_type: if "generator" in output_type: return output_generator else: return output_value else: current_saved_records[hash_value] = { "input": input_dict, "output": output_value, "output_type": output_type, } else: current_saved_records[hash_value] = { "input": input_dict, "output": output_value, "output_type": output_type, } self.cached_items[self._record_file_str] = current_saved_records self._write_file(hash_value) if "generator" in output_type: return output_generator else: return output_value @classmethod def get_test_mode_from_environ(cls) -> str: return os.getenv(ENVIRON_TEST_MODE, RecordMode.LIVE) @classmethod def is_recording_mode(cls) -> bool: return RecordStorage.get_test_mode_from_environ() == RecordMode.RECORD @classmethod def is_replaying_mode(cls) -> bool: return RecordStorage.get_test_mode_from_environ() == RecordMode.REPLAY @classmethod def is_live_mode(cls) -> bool: return RecordStorage.get_test_mode_from_environ() == RecordMode.LIVE @classmethod def get_instance(cls, record_file=None) -> "RecordStorage": """ Use this to get instance to avoid multiple copies of same record storage. :param record_file: initiate at first entrance, defaults to None in the first call will raise exception. :type record_file: str or Path, optional :return: instance of RecordStorage :rtype: RecordStorage """ # if not in recording mode, return None if not (RecordStorage.is_recording_mode() or RecordStorage.is_replaying_mode()): return None # Create instance if not exist if cls._instance is None: if record_file is None: raise RecordFileMissingException("record_file is value None") cls._instance = RecordStorage(record_file) if record_file is not None: cls._instance.record_file = record_file return cls._instance
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/recording_utilities/constants.py
ENVIRON_TEST_MODE = "PROMPT_FLOW_TEST_MODE" class RecordMode: LIVE = "live" RECORD = "record" REPLAY = "replay"
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/recording_utilities/mock_tool.py
import functools import inspect from promptflow._core.tool import STREAMING_OPTION_PARAMETER_ATTR, ToolType from promptflow._core.tracer import TraceType, _create_trace_from_function_call from .record_storage import RecordFileMissingException, RecordItemMissingException, RecordStorage # recording array is a global variable to store the function names that need to be recorded recording_array = ["fetch_text_content_from_url", "my_python_tool"] def recording_array_extend(items): global recording_array recording_array.extend(items) def recording_array_reset(): global recording_array recording_array = ["fetch_text_content_from_url", "my_python_tool"] def _prepare_input_dict(func, args, kwargs): """Prepare input dict for record storage""" if func.__name__ == "partial": func_wo_partial = func.func else: func_wo_partial = func input_dict = {} for key in kwargs: input_dict[key] = kwargs[key] if type(func).__name__ == "partial": input_dict["_args"] = func.args for key in func.keywords: input_dict[key] = func.keywords[key] else: input_dict["_args"] = [] input_dict["_func"] = func_wo_partial.__qualname__ return input_dict def _replace_tool_rule(func): """Replace tool with the following rules.""" global recording_array if func.__name__ == "partial": func_wo_partial = func.func else: func_wo_partial = func if func_wo_partial.__qualname__.startswith("AzureOpenAI"): return True elif func_wo_partial.__qualname__.startswith("OpenAI"): return True elif func_wo_partial.__module__ == "promptflow.tools.aoai": return True elif func_wo_partial.__module__ == "promptflow.tools.openai_gpt4v": return True elif func_wo_partial.__module__ == "promptflow.tools.openai": return True elif func_wo_partial.__qualname__ in recording_array: return True else: return False def call_func(func, args, kwargs): input_dict = _prepare_input_dict(func, args, kwargs) if RecordStorage.is_replaying_mode(): return RecordStorage.get_instance().get_record(input_dict) # Record mode will record item to record file elif RecordStorage.is_recording_mode(): try: # prevent recording the same item twice obj = RecordStorage.get_instance().get_record(input_dict) except (RecordItemMissingException, RecordFileMissingException): # recording the item obj = RecordStorage.get_instance().set_record(input_dict, func(*args, **kwargs)) return obj async def call_func_async(func, args, kwargs): input_dict = _prepare_input_dict(func, args, kwargs) if RecordStorage.is_replaying_mode(): return RecordStorage.get_instance().get_record(input_dict) # Record mode will record item to record file elif RecordStorage.is_recording_mode(): try: # prevent recording the same item twice obj = RecordStorage.get_instance().get_record(input_dict) except (RecordItemMissingException, RecordFileMissingException): # recording the item obj = RecordStorage.get_instance().set_record(input_dict, await func(*args, **kwargs)) return obj def mock_tool(original_tool): """ Basically this is the original tool decorator. The key modification is, at every func(*args, **argv) call. There is a surrounding record/replay logic: if replay: return replay: elif record: if recorded: return recorded call func(*args, **argv) and record the result Actually it needn't to be such a long function, but tool decorator should not trigger a long stack trace. """ def tool( func=None, *args_mock, name: str = None, description: str = None, type: str = None, input_settings=None, streaming_option_parameter=None, **kwargs_mock, ): def tool_decorator(func): from promptflow.exceptions import UserErrorException def create_trace(func, args, kwargs): return _create_trace_from_function_call(func, args=args, kwargs=kwargs, trace_type=TraceType.TOOL) if inspect.iscoroutinefunction(func): @functools.wraps(func) async def decorated_tool(*args, **kwargs): from promptflow._core.tracer import Tracer if Tracer.active_instance() is None: return await call_func_async(func, args, kwargs) try: Tracer.push(create_trace(func, args, kwargs)) output = await call_func_async(func, args, kwargs) return Tracer.pop(output) except Exception as e: Tracer.pop(None, e) raise new_f = decorated_tool else: @functools.wraps(func) def decorated_tool(*args, **kwargs): from promptflow._core.tracer import Tracer if Tracer.active_instance() is None: return call_func(func, args, kwargs) try: Tracer.push(create_trace(func, args, kwargs)) output = call_func(func, args, kwargs) return Tracer.pop(output) except Exception as e: Tracer.pop(None, e) raise new_f = decorated_tool if type is not None and type not in [k.value for k in ToolType]: raise UserErrorException(f"Tool type {type} is not supported yet.") new_f.__original_function = func new_f.__tool = None # This will be set when generating the tool definition. new_f.__name = name new_f.__description = description new_f.__type = type new_f.__input_settings = input_settings new_f.__extra_info = kwargs_mock if streaming_option_parameter and isinstance(streaming_option_parameter, str): setattr(new_f, STREAMING_OPTION_PARAMETER_ATTR, streaming_option_parameter) return new_f # tool replacements. if func is not None: if not _replace_tool_rule(func): return original_tool( func, *args_mock, name=name, description=description, type=type, input_settings=input_settings, **kwargs_mock, ) return tool_decorator(func) return original_tool( # no recording for @tool(name="func_name") func, *args_mock, name=name, description=description, type=type, input_settings=input_settings, **kwargs_mock, ) return tool
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_test/recording_utilities/__init__.py
from .constants import ENVIRON_TEST_MODE, RecordMode from .mock_tool import mock_tool, recording_array_extend, recording_array_reset from .record_storage import RecordFileMissingException, RecordItemMissingException, RecordStorage __all__ = [ "RecordStorage", "RecordMode", "ENVIRON_TEST_MODE", "RecordFileMissingException", "RecordItemMissingException", "mock_tool", "recording_array_extend", "recording_array_reset", ]
0
promptflow_repo/promptflow/src/promptflow/tests
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/conftest.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import logging import os import uuid from concurrent.futures import ThreadPoolExecutor from pathlib import Path from typing import Callable, Optional from unittest.mock import patch import jwt import pytest from azure.core.exceptions import ResourceNotFoundError from mock import mock from pytest_mock import MockerFixture from promptflow._sdk._constants import FlowType, RunStatus from promptflow._sdk._utils import ClientUserAgentUtil from promptflow._sdk.entities import Run from promptflow.azure import PFClient from promptflow.azure._entities._flow import Flow from ._azure_utils import get_cred from .recording_utilities import ( PFAzureIntegrationTestRecording, SanitizedValues, VariableRecorder, get_created_flow_name_from_flow_path, get_pf_client_for_replay, is_live, is_record, is_replay, ) FLOWS_DIR = "./tests/test_configs/flows" EAGER_FLOWS_DIR = "./tests/test_configs/eager_flows" DATAS_DIR = "./tests/test_configs/datas" AZUREML_RESOURCE_PROVIDER = "Microsoft.MachineLearningServices" RESOURCE_ID_FORMAT = "/subscriptions/{}/resourceGroups/{}/providers/{}/workspaces/{}" def package_scope_in_live_mode() -> str: """Determine the scope of some expected sharing fixtures. We have many tests against flows and runs, and it's very time consuming to create a new flow/run for each test. So we expect to leverage pytest fixture concept to share flows/runs across tests. However, we also have replay tests, which require function scope fixture as it will locate the recording YAML based on the test function info. Use this function to determine the scope of the fixtures dynamically. For those fixtures that will request dynamic scope fixture(s), they also need to be dynamic scope. """ # package-scope should be enough for Azure tests return "package" if is_live() else "function" @pytest.fixture(scope=package_scope_in_live_mode()) def user_object_id() -> str: if is_replay(): return SanitizedValues.USER_OBJECT_ID credential = get_cred() access_token = credential.get_token("https://management.azure.com/.default") decoded_token = jwt.decode(access_token.token, options={"verify_signature": False}) return decoded_token["oid"] @pytest.fixture(scope=package_scope_in_live_mode()) def tenant_id() -> str: if is_replay(): return SanitizedValues.TENANT_ID credential = get_cred() access_token = credential.get_token("https://management.azure.com/.default") decoded_token = jwt.decode(access_token.token, options={"verify_signature": False}) return decoded_token["tid"] @pytest.fixture(scope=package_scope_in_live_mode()) def ml_client( subscription_id: str, resource_group_name: str, workspace_name: str, ): """return a machine learning client using default e2e testing workspace""" from azure.ai.ml import MLClient return MLClient( credential=get_cred(), subscription_id=subscription_id, resource_group_name=resource_group_name, workspace_name=workspace_name, cloud="AzureCloud", ) @pytest.fixture(scope=package_scope_in_live_mode()) def remote_client(subscription_id: str, resource_group_name: str, workspace_name: str): from promptflow.azure import PFClient if is_replay(): client = get_pf_client_for_replay() else: client = PFClient( credential=get_cred(), subscription_id=subscription_id, resource_group_name=resource_group_name, workspace_name=workspace_name, ) assert "promptflow-sdk" in ClientUserAgentUtil.get_user_agent() assert "promptflow/" not in ClientUserAgentUtil.get_user_agent() yield client @pytest.fixture def remote_workspace_resource_id(subscription_id: str, resource_group_name: str, workspace_name: str) -> str: return "azureml:" + RESOURCE_ID_FORMAT.format( subscription_id, resource_group_name, AZUREML_RESOURCE_PROVIDER, workspace_name ) @pytest.fixture(scope=package_scope_in_live_mode()) def pf(remote_client): # do not add annotation here, because PFClient will trigger promptflow.azure imports and break the isolation # between azure and non-azure tests yield remote_client @pytest.fixture def remote_web_classification_data(remote_client): from azure.ai.ml.entities import Data data_name, data_version = "webClassification1", "1" try: return remote_client.ml_client.data.get(name=data_name, version=data_version) except ResourceNotFoundError: return remote_client.ml_client.data.create_or_update( Data(name=data_name, version=data_version, path=f"{DATAS_DIR}/webClassification1.jsonl", type="uri_file") ) @pytest.fixture(scope="session") def runtime(runtime_name: str) -> str: return runtime_name PROMPTFLOW_ROOT = Path(__file__) / "../../.." MODEL_ROOT = Path(PROMPTFLOW_ROOT / "tests/test_configs/flows") @pytest.fixture def flow_serving_client_remote_connection(mocker: MockerFixture, remote_workspace_resource_id): from promptflow._sdk._serving.app import create_app as create_serving_app model_path = (Path(MODEL_ROOT) / "basic-with-connection").resolve().absolute().as_posix() mocker.patch.dict(os.environ, {"PROMPTFLOW_PROJECT_PATH": model_path}) mocker.patch.dict(os.environ, {"USER_AGENT": "test-user-agent"}) app = create_serving_app( config={"connection.provider": remote_workspace_resource_id}, environment_variables={"API_TYPE": "${azure_open_ai_connection.api_type}"}, ) app.config.update( { "TESTING": True, } ) return app.test_client() @pytest.fixture def flow_serving_client_with_prt_config_env( mocker: MockerFixture, subscription_id, resource_group_name, workspace_name ): # noqa: E501 connections = { "PRT_CONFIG_OVERRIDE": f"deployment.subscription_id={subscription_id}," f"deployment.resource_group={resource_group_name}," f"deployment.workspace_name={workspace_name}," "app.port=8088", } return create_serving_client_with_connections("basic-with-connection", mocker, connections) @pytest.fixture def flow_serving_client_with_connection_provider_env(mocker: MockerFixture, remote_workspace_resource_id): connections = {"PROMPTFLOW_CONNECTION_PROVIDER": remote_workspace_resource_id} return create_serving_client_with_connections("basic-with-connection", mocker, connections) @pytest.fixture def flow_serving_client_with_aml_resource_id_env(mocker: MockerFixture, remote_workspace_resource_id): aml_resource_id = "{}/onlineEndpoints/{}/deployments/{}".format(remote_workspace_resource_id, "myendpoint", "blue") connections = {"AML_DEPLOYMENT_RESOURCE_ID": aml_resource_id} return create_serving_client_with_connections("basic-with-connection", mocker, connections) @pytest.fixture def serving_client_with_connection_name_override(mocker: MockerFixture, remote_workspace_resource_id): connections = { "aoai_connection": "azure_open_ai_connection", "PROMPTFLOW_CONNECTION_PROVIDER": remote_workspace_resource_id, } return create_serving_client_with_connections("llm_connection_override", mocker, connections) @pytest.fixture def serving_client_with_connection_data_override(mocker: MockerFixture, remote_workspace_resource_id): model_name = "llm_connection_override" model_path = (Path(MODEL_ROOT) / model_name).resolve().absolute() # load arm connection template connection_arm_template = model_path.joinpath("connection_arm_template.json").read_text() connections = { "aoai_connection": connection_arm_template, "PROMPTFLOW_CONNECTION_PROVIDER": remote_workspace_resource_id, } return create_serving_client_with_connections(model_name, mocker, connections) def create_serving_client_with_connections(model_name, mocker: MockerFixture, connections: dict = {}): from promptflow._sdk._serving.app import create_app as create_serving_app model_path = (Path(MODEL_ROOT) / model_name).resolve().absolute().as_posix() mocker.patch.dict(os.environ, {"PROMPTFLOW_PROJECT_PATH": model_path}) mocker.patch.dict( os.environ, { **connections, }, ) # Set credential to None for azureml extension type # As we mock app in github workflow, which do not have managed identity credential func = "promptflow._sdk._serving.extension.azureml_extension._get_managed_identity_credential_with_retry" with mock.patch(func) as mock_cred_func: mock_cred_func.return_value = None app = create_serving_app( environment_variables={"API_TYPE": "${azure_open_ai_connection.api_type}"}, extension_type="azureml", ) app.config.update( { "TESTING": True, } ) return app.test_client() @pytest.fixture(scope=package_scope_in_live_mode()) def variable_recorder() -> VariableRecorder: yield VariableRecorder() @pytest.fixture(scope=package_scope_in_live_mode()) def randstr(variable_recorder: VariableRecorder) -> Callable[[str], str]: """Return a "random" UUID.""" def generate_random_string(variable_name: str) -> str: random_string = str(uuid.uuid4()) if is_live(): return random_string elif is_replay(): return variable_name else: return variable_recorder.get_or_record_variable(variable_name, random_string) return generate_random_string @pytest.fixture(scope=package_scope_in_live_mode()) def vcr_recording( request: pytest.FixtureRequest, user_object_id: str, tenant_id: str, variable_recorder: VariableRecorder ) -> Optional[PFAzureIntegrationTestRecording]: """Fixture to record or replay network traffic. If the test mode is "live", nothing will happen. If the test mode is "record" or "replay", this fixture will locate a YAML (recording) file based on the test file, class and function name, write to (record) or read from (replay) the file. """ if is_live(): yield None else: recording = PFAzureIntegrationTestRecording.from_test_case( test_class=request.cls, test_func_name=request.node.name, user_object_id=user_object_id, tenant_id=tenant_id, variable_recorder=variable_recorder, ) recording.enter_vcr() request.addfinalizer(recording.exit_vcr) yield recording # we expect this fixture only work when running live test without recording # when recording, we don't want to record any application insights secrets # when replaying, we also don't need this @pytest.fixture(autouse=not is_live()) def mock_appinsights_log_handler(mocker: MockerFixture) -> None: dummy_logger = logging.getLogger("dummy") mocker.patch("promptflow._sdk._telemetry.telemetry.get_telemetry_logger", return_value=dummy_logger) return @pytest.fixture def single_worker_thread_pool() -> None: """Mock to use one thread for thread pool executor. VCR.py cannot record network traffic in other threads, and we have multi-thread operations during resolving the flow. Mock it using one thread to make VCR.py work. """ def single_worker_thread_pool_executor(*args, **kwargs): return ThreadPoolExecutor(max_workers=1) if is_live(): yield else: with patch( "promptflow.azure.operations._run_operations.ThreadPoolExecutor", new=single_worker_thread_pool_executor, ): yield @pytest.fixture def mock_set_headers_with_user_aml_token(mocker: MockerFixture) -> None: """Mock set aml-user-token operation. There will be requests fetching cloud metadata during retrieving AML token, which will break during replay. As the logic comes from azure-ai-ml, changes in Prompt Flow can hardly affect it, mock it here. """ if not is_live(): mocker.patch( "promptflow.azure._restclient.flow_service_caller.FlowServiceCaller._set_headers_with_user_aml_token" ) yield @pytest.fixture def mock_get_azure_pf_client(mocker: MockerFixture, remote_client) -> None: """Mock PF Azure client to avoid network traffic during replay test.""" if not is_live(): mocker.patch( "promptflow._cli._pf_azure._run._get_azure_pf_client", return_value=remote_client, ) mocker.patch( "promptflow._cli._pf_azure._flow._get_azure_pf_client", return_value=remote_client, ) yield @pytest.fixture(scope=package_scope_in_live_mode()) def mock_get_user_identity_info(user_object_id: str, tenant_id: str) -> None: """Mock get user object id and tenant id, currently used in flow list operation.""" if not is_live(): with patch( "promptflow.azure._restclient.flow_service_caller.FlowServiceCaller._get_user_identity_info", return_value=(user_object_id, tenant_id), ): yield else: yield @pytest.fixture(scope=package_scope_in_live_mode()) def created_flow(pf: PFClient, randstr: Callable[[str], str], variable_recorder: VariableRecorder) -> Flow: """Create a flow for test.""" flow_display_name = randstr("flow_display_name") flow_source = FLOWS_DIR + "/simple_hello_world/" description = "test flow description" tags = {"owner": "sdk-test"} result = pf.flows.create_or_update( flow=flow_source, display_name=flow_display_name, type=FlowType.STANDARD, description=description, tags=tags ) remote_flow_dag_path = result.path # make sure the flow is created successfully assert pf.flows._storage_client._check_file_share_file_exist(remote_flow_dag_path) is True assert result.display_name == flow_display_name assert result.type == FlowType.STANDARD assert result.tags == tags assert result.path.endswith("flow.dag.yaml") # flow in Azure will have different file share name with timestamp # and this is a client-side behavior, so we need to sanitize this in recording # so extract this during record test if is_record(): flow_name_const = "flow_name" flow_name = get_created_flow_name_from_flow_path(result.path) variable_recorder.get_or_record_variable(flow_name_const, flow_name) yield result @pytest.fixture(scope=package_scope_in_live_mode()) def created_batch_run_without_llm(pf: PFClient, randstr: Callable[[str], str], runtime: str) -> Run: """Create a batch run that does not require LLM.""" name = randstr("batch_run_name") run = pf.run( # copy test_configs/flows/simple_hello_world to a separate folder # as pf.run will generate .promptflow/flow.tools.json # it will affect Azure file share upload logic and replay test flow=f"{FLOWS_DIR}/hello-world", data=f"{DATAS_DIR}/webClassification3.jsonl", column_mapping={"name": "${data.url}"}, name=name, display_name="sdk-cli-test-fixture-batch-run-without-llm", ) run = pf.runs.stream(run=name) assert run.status == RunStatus.COMPLETED yield run @pytest.fixture(scope=package_scope_in_live_mode()) def simple_eager_run(pf: PFClient, randstr: Callable[[str], str]) -> Run: """Create a simple eager run.""" run = pf.run( flow=f"{EAGER_FLOWS_DIR}/simple_with_req", data=f"{DATAS_DIR}/simple_eager_flow_data.jsonl", name=randstr("name"), ) pf.runs.stream(run) run = pf.runs.get(run) assert run.status == RunStatus.COMPLETED yield run @pytest.fixture(scope=package_scope_in_live_mode()) def created_eval_run_without_llm( pf: PFClient, randstr: Callable[[str], str], runtime: str, created_batch_run_without_llm: Run ) -> Run: """Create a evaluation run against batch run without LLM dependency.""" name = randstr("eval_run_name") run = pf.run( flow=f"{FLOWS_DIR}/eval-classification-accuracy", data=f"{DATAS_DIR}/webClassification3.jsonl", run=created_batch_run_without_llm, column_mapping={"groundtruth": "${data.answer}", "prediction": "${run.outputs.result}"}, runtime=runtime, name=name, display_name="sdk-cli-test-fixture-eval-run-without-llm", ) run = pf.runs.stream(run=name) assert run.status == RunStatus.COMPLETED yield run @pytest.fixture(scope=package_scope_in_live_mode()) def created_failed_run(pf: PFClient, randstr: Callable[[str], str], runtime: str) -> Run: """Create a failed run.""" name = randstr("failed_run_name") run = pf.run( flow=f"{FLOWS_DIR}/partial_fail", data=f"{DATAS_DIR}/webClassification3.jsonl", runtime=runtime, name=name, display_name="sdk-cli-test-fixture-failed-run", ) # set raise_on_error to False to promise returning something run = pf.runs.stream(run=name, raise_on_error=False) assert run.status == RunStatus.FAILED yield run @pytest.fixture(autouse=not is_live()) def mock_vcrpy_for_httpx() -> None: # there is a known issue in vcrpy handling httpx response: https://github.com/kevin1024/vcrpy/pull/591 # the related code change has not been merged, so we need such a fixture for patch def _transform_headers(httpx_response): out = {} for key, var in httpx_response.headers.raw: decoded_key = key.decode("utf-8") decoded_var = var.decode("utf-8") if decoded_key.lower() == "content-encoding" and decoded_var in ("gzip", "deflate"): continue out.setdefault(decoded_key, []) out[decoded_key].append(decoded_var) return out with patch("vcr.stubs.httpx_stubs._transform_headers", new=_transform_headers): yield @pytest.fixture(autouse=not is_live()) def mock_to_thread() -> None: # https://docs.python.org/3/library/asyncio-task.html#asyncio.to_thread # to_thread actually uses a separate thread, which will break mocks # so we need to mock it to avoid using a separate thread # this is only for AsyncRunDownloader.to_thread async def to_thread(func, /, *args, **kwargs): func(*args, **kwargs) with patch( "promptflow.azure.operations._async_run_downloader.to_thread", new=to_thread, ): yield @pytest.fixture def mock_isinstance_for_mock_datastore() -> None: """Mock built-in function isinstance. We have an isinstance check during run download for datastore type for better error message; while our mock datastore in replay mode is not a valid type, so mock it with strict condition. """ if not is_replay(): yield else: from azure.ai.ml.entities._datastore.azure_storage import AzureBlobDatastore from .recording_utilities.utils import MockDatastore original_isinstance = isinstance def mock_isinstance(*args): if original_isinstance(args[0], MockDatastore) and args[1] == AzureBlobDatastore: return True return original_isinstance(*args) with patch("builtins.isinstance", new=mock_isinstance): yield @pytest.fixture(autouse=True) def mock_check_latest_version() -> None: """Mock check latest version. As CI uses docker, it will always trigger this check behavior, and we don't have recording for this; and this will hit many unknown issue with vcrpy. """ with patch("promptflow._utils.version_hint_utils.check_latest_version", new=lambda: None): yield
0
promptflow_repo/promptflow/src/promptflow/tests
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/_azure_utils.py
import signal from azure.identity import AzureCliCredential, DefaultAzureCredential def get_cred(): """get credential for azure storage""" # resolve requests try: credential = AzureCliCredential() token = credential.get_token("https://management.azure.com/.default") except Exception: credential = DefaultAzureCredential() # ensure we can get token token = credential.get_token("https://management.azure.com/.default") assert token is not None return credential PYTEST_TIMEOUT_METHOD = "signal" if hasattr(signal, "SIGALRM") else "thread" # use signal when os support SIGALRM DEFAULT_TEST_TIMEOUT = 10 * 60 # 10mins
0
promptflow_repo/promptflow/src/promptflow/tests
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # ---------------------------------------------------------
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_run_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy import json import shutil from logging import Logger from pathlib import Path from tempfile import TemporaryDirectory from time import sleep from typing import Callable from unittest.mock import MagicMock, patch import pandas as pd import pydash import pytest from promptflow._sdk._constants import DownloadedRun, RunStatus from promptflow._sdk._errors import InvalidRunError, InvalidRunStatusError, RunNotFoundError from promptflow._sdk._load_functions import load_run from promptflow._sdk.entities import Run from promptflow._utils.flow_utils import get_flow_lineage_id from promptflow._utils.yaml_utils import load_yaml from promptflow.azure import PFClient from promptflow.azure._constants._flow import ENVIRONMENT, PYTHON_REQUIREMENTS_TXT from promptflow.azure._entities._flow import Flow from promptflow.exceptions import UserErrorException from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD from ..recording_utilities import is_live PROMOTFLOW_ROOT = Path(__file__) / "../../../.." TEST_ROOT = Path(__file__).parent.parent.parent MODEL_ROOT = TEST_ROOT / "test_configs/e2e_samples" CONNECTION_FILE = (PROMOTFLOW_ROOT / "connections.json").resolve().absolute().as_posix() FLOWS_DIR = "./tests/test_configs/flows" EAGER_FLOWS_DIR = "./tests/test_configs/eager_flows" RUNS_DIR = "./tests/test_configs/runs" DATAS_DIR = "./tests/test_configs/datas" @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.e2etest @pytest.mark.usefixtures( "mock_set_headers_with_user_aml_token", "single_worker_thread_pool", "vcr_recording", ) class TestFlowRun: def test_run_bulk(self, pf, runtime: str, randstr: Callable[[str], str]): name = randstr("name") run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"{DATAS_DIR}/webClassification1.jsonl", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=name, ) assert isinstance(run, Run) assert run.name == name def test_run_bulk_from_yaml(self, pf, runtime: str, randstr: Callable[[str], str]): run_id = randstr("run_id") run = load_run( source=f"{RUNS_DIR}/sample_bulk_run_cloud.yaml", params_override=[{"name": run_id, "runtime": runtime}], ) run = pf.runs.create_or_update(run=run) assert isinstance(run, Run) def test_basic_evaluation(self, pf, runtime: str, randstr: Callable[[str], str]): data_path = f"{DATAS_DIR}/webClassification3.jsonl" run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=data_path, column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("batch_run_name"), ) assert isinstance(run, Run) run = pf.runs.stream(run=run.name) assert run.status == RunStatus.COMPLETED eval_run = pf.run( flow=f"{FLOWS_DIR}/eval-classification-accuracy", data=data_path, run=run, column_mapping={"groundtruth": "${data.answer}", "prediction": "${run.outputs.category}"}, runtime=runtime, name=randstr("eval_run_name"), ) assert isinstance(eval_run, Run) eval_run = pf.runs.stream(run=eval_run.name) assert eval_run.status == RunStatus.COMPLETED def test_basic_evaluation_without_data(self, pf, runtime: str, randstr: Callable[[str], str]): run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"{DATAS_DIR}/webClassification3.jsonl", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("batch_run_name"), ) assert isinstance(run, Run) run = pf.runs.stream(run=run.name) assert run.status == RunStatus.COMPLETED eval_run = pf.run( flow=f"{FLOWS_DIR}/eval-classification-accuracy", run=run, column_mapping={ # evaluation reference run.inputs "groundtruth": "${run.inputs.url}", "prediction": "${run.outputs.category}", }, runtime=runtime, name=randstr("eval_run_name"), ) assert isinstance(eval_run, Run) eval_run = pf.runs.stream(run=eval_run.name) assert eval_run.status == RunStatus.COMPLETED def test_run_bulk_with_remote_flow( self, pf: PFClient, runtime: str, randstr: Callable[[str], str], created_flow: Flow ): """Test run bulk with remote workspace flow.""" name = randstr("name") run = pf.run( flow=f"azureml:{created_flow.name}", data=f"{DATAS_DIR}/simple_hello_world.jsonl", column_mapping={"name": "${data.name}"}, runtime=runtime, name=name, ) assert isinstance(run, Run) assert run.name == name def test_run_bulk_with_registry_flow( self, pf: PFClient, runtime: str, randstr: Callable[[str], str], registry_name: str ): """Test run bulk with remote registry flow.""" name = randstr("name") run = pf.run( flow=f"azureml://registries/{registry_name}/models/simple_hello_world/versions/202311241", data=f"{DATAS_DIR}/simple_hello_world.jsonl", column_mapping={"name": "${data.name}"}, runtime=runtime, name=name, ) assert isinstance(run, Run) assert run.name == name # test invalid registry flow with pytest.raises(UserErrorException, match="Invalid remote flow pattern, got"): pf.run( flow="azureml://registries/no-flow", data=f"{DATAS_DIR}/simple_hello_world.jsonl", column_mapping={"name": "${data.name}"}, runtime=runtime, name=name, ) def test_run_with_connection_overwrite(self, pf, runtime: str, randstr: Callable[[str], str]): run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"{DATAS_DIR}/webClassification1.jsonl", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", connections={"classify_with_llm": {"connection": "azure_open_ai", "model": "gpt-3.5-turbo"}}, runtime=runtime, name=randstr("name"), ) assert isinstance(run, Run) def test_run_with_env_overwrite(self, pf, runtime: str, randstr: Callable[[str], str]): run = load_run( source=f"{RUNS_DIR}/run_with_env.yaml", params_override=[{"runtime": runtime}], ) run.name = randstr("name") run = pf.runs.create_or_update(run=run) assert isinstance(run, Run) def test_run_display_name_with_macro(self, pf, runtime: str, randstr: Callable[[str], str]): run = load_run( source=f"{RUNS_DIR}/run_with_env.yaml", params_override=[{"runtime": runtime}], ) run.name = randstr("name") run.display_name = "my_display_name_${variant_id}_${timestamp}" run = pf.runs.create_or_update(run=run) assert run.display_name.startswith("my_display_name_variant_0_") assert "${timestamp}" not in run.display_name assert isinstance(run, Run) def test_default_run_display_name(self, pf, runtime: str, randstr: Callable[[str], str]): run = load_run( source=f"{RUNS_DIR}/run_with_env.yaml", params_override=[{"runtime": runtime}], ) run.name = randstr("name") run = pf.runs.create_or_update(run=run) assert run.display_name == run.name assert isinstance(run, Run) def test_run_with_remote_data( self, pf, runtime: str, remote_web_classification_data, randstr: Callable[[str], str] ): # run with arm id run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"azureml:{remote_web_classification_data.id}", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("name1"), ) assert isinstance(run, Run) # run with name version run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"azureml:{remote_web_classification_data.name}:{remote_web_classification_data.version}", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("name2"), ) assert isinstance(run, Run) # TODO: confirm whether this test is a end-to-end test def test_run_bulk_not_exist(self, pf, runtime: str, randstr: Callable[[str], str]): test_data = f"{DATAS_DIR}/webClassification1.jsonl" with pytest.raises(UserErrorException) as e: pf.run( flow=f"{FLOWS_DIR}/web_classification", # data with file:/// prefix is not supported, should raise not exist error data=f"file:///{Path(test_data).resolve().absolute()}", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("name"), ) assert "does not exist" in str(e.value) def test_list_runs(self, pf): runs = pf.runs.list(max_results=10) for run in runs: print(json.dumps(run._to_dict(), indent=4)) assert len(runs) == 10 def test_show_run(self, pf: PFClient, created_eval_run_without_llm: Run): run = pf.runs.get(run=created_eval_run_without_llm.name) run_dict = run._to_dict() print(json.dumps(run_dict, indent=4)) # it's hard to assert with precise value, so just assert existence, type and length expected_keys = [ "name", "created_on", "status", "display_name", "description", "tags", "properties", "creation_context", "start_time", "end_time", "duration", "portal_url", "data", "output", "run", ] for expected_key in expected_keys: assert expected_key in run_dict if expected_key == "description": assert run_dict[expected_key] is None elif expected_key in {"tags", "properties", "creation_context"}: assert isinstance(run_dict[expected_key], dict) else: assert isinstance(run_dict[expected_key], str) assert len(run_dict[expected_key]) > 0 def test_show_run_details(self, pf: PFClient, created_batch_run_without_llm: Run): # get first 2 results details = pf.get_details(run=created_batch_run_without_llm.name, max_results=2) assert details.shape[0] == 2 # get first 10 results while it only has 3 details = pf.get_details(run=created_batch_run_without_llm.name, max_results=10) assert details.shape[0] == 3 # get all results details = pf.get_details(run=created_batch_run_without_llm.name, all_results=True) assert details.shape[0] == 3 # get all results even if max_results is set to 2 details = pf.get_details( run=created_batch_run_without_llm.name, max_results=2, all_results=True, ) assert details.shape[0] == 3 def test_show_metrics(self, pf: PFClient, created_eval_run_without_llm: Run): metrics = pf.runs.get_metrics(run=created_eval_run_without_llm.name) print(json.dumps(metrics, indent=4)) # as we use unmatched data, we can assert the accuracy is 0 assert metrics == {"accuracy": 0.0} def test_stream_invalid_run_logs(self, pf, randstr: Callable[[str], str]): # test get invalid run name non_exist_run = randstr("non_exist_run") with pytest.raises(RunNotFoundError, match=f"Run {non_exist_run!r} not found"): pf.runs.stream(run=non_exist_run) def test_stream_run_logs(self, pf: PFClient, created_batch_run_without_llm: Run): run = pf.runs.stream(run=created_batch_run_without_llm.name) assert run.status == RunStatus.COMPLETED def test_stream_failed_run_logs(self, pf: PFClient, created_failed_run: Run, capfd: pytest.CaptureFixture): # (default) raise_on_error=True with pytest.raises(InvalidRunStatusError): pf.stream(run=created_failed_run.name) # raise_on_error=False pf.stream(run=created_failed_run.name, raise_on_error=False) out, _ = capfd.readouterr() assert "The input for batch run is incorrect. Couldn't find these mapping relations: ${data.key}" in out def test_failed_run_to_dict_exclude(self, pf: PFClient, created_failed_run: Run): failed_run = pf.runs.get(run=created_failed_run.name) # Azure run object reference a dict, use deepcopy to avoid unexpected modification default = copy.deepcopy(failed_run._to_dict()) exclude = failed_run._to_dict(exclude_additional_info=True, exclude_debug_info=True) assert "additionalInfo" in default["error"]["error"] and "additionalInfo" not in exclude["error"]["error"] assert "debugInfo" in default["error"]["error"] and "debugInfo" not in exclude["error"]["error"] @pytest.mark.skipif( condition=not is_live(), reason="cannot differ the two requests to run history in replay mode.", ) def test_archive_and_restore_run(self, pf: PFClient, created_batch_run_without_llm: Run): from promptflow._sdk._constants import RunHistoryKeys run_meta_data = RunHistoryKeys.RunMetaData hidden = RunHistoryKeys.HIDDEN run_id = created_batch_run_without_llm.name # test archive pf.runs.archive(run=run_id) run_data = pf.runs._get_run_from_run_history(run_id, original_form=True)[run_meta_data] assert run_data[hidden] is True # test restore pf.runs.restore(run=run_id) run_data = pf.runs._get_run_from_run_history(run_id, original_form=True)[run_meta_data] assert run_data[hidden] is False def test_update_run(self, pf: PFClient, created_batch_run_without_llm: Run, randstr: Callable[[str], str]): run_id = created_batch_run_without_llm.name test_mark = randstr("test_mark") new_display_name = f"test_display_name_{test_mark}" new_description = f"test_description_{test_mark}" new_tags = {"test_tag": test_mark} run = pf.runs.update( run=run_id, display_name=new_display_name, description=new_description, tags=new_tags, ) # sleep to wait for update to take effect sleep(3) assert run.display_name == new_display_name assert run.description == new_description assert run.tags["test_tag"] == test_mark # test wrong type of parameters won't raise error, just log warnings and got ignored run = pf.runs.update( run=run_id, tags={"test_tag": {"a": 1}}, ) # sleep to wait for update to take effect sleep(3) assert run.display_name == new_display_name assert run.description == new_description assert run.tags["test_tag"] == test_mark def test_cancel_run(self, pf, runtime: str, randstr: Callable[[str], str]): # create a run run_name = randstr("name") pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"{DATAS_DIR}/webClassification1.jsonl", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=run_name, ) pf.runs.cancel(run=run_name) sleep(3) run = pf.runs.get(run=run_name) # the run status might still be cancel requested, but it should be canceled eventually assert run.status in [RunStatus.CANCELED, RunStatus.CANCEL_REQUESTED] @pytest.mark.skipif( condition=not is_live(), reason="request uri contains temp folder name, need some time to sanitize." ) def test_run_with_additional_includes(self, pf, runtime: str, randstr: Callable[[str], str]): run = pf.run( flow=f"{FLOWS_DIR}/web_classification_with_additional_include", data=f"{DATAS_DIR}/webClassification1.jsonl", inputs_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("name"), ) run = pf.runs.stream(run=run.name) assert run.status == RunStatus.COMPLETED # Test additional includes don't exist with pytest.raises(ValueError) as e: pf.run( flow=f"{FLOWS_DIR}/web_classification_with_invalid_additional_include", data=f"{DATAS_DIR}/webClassification1.jsonl", inputs_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("name_invalid"), ) assert "Unable to find additional include ../invalid/file/path" in str(e.value) @pytest.mark.skip(reason="Cannot find tools of the flow with symbolic.") def test_run_with_symbolic(self, remote_client, pf, runtime, prepare_symbolic_flow): run = pf.run( flow=f"{FLOWS_DIR}/web_classification_with_symbolic", data=f"{DATAS_DIR}/webClassification1.jsonl", inputs_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, ) remote_client.runs.stream(run=run.name) def test_run_bulk_without_retry(self, remote_client): from azure.core.exceptions import ServiceResponseError from azure.core.pipeline.transport._requests_basic import RequestsTransport from azure.core.rest._requests_basic import RestRequestsTransportResponse from requests import Response from promptflow.azure._restclient.flow.models import SubmitBulkRunRequest from promptflow.azure._restclient.flow_service_caller import FlowRequestException, FlowServiceCaller from promptflow.azure.operations import RunOperations mock_run = MagicMock() mock_run._runtime = "fake_runtime" mock_run._to_rest_object.return_value = SubmitBulkRunRequest() mock_run._use_remote_flow = False with patch.object(RunOperations, "_resolve_data_to_asset_id"), patch.object(RunOperations, "_resolve_flow"): with patch.object(RequestsTransport, "send") as mock_request, patch.object( FlowServiceCaller, "_set_headers_with_user_aml_token" ): mock_request.side_effect = ServiceResponseError( "Connection aborted.", error=ConnectionResetError(10054, "An existing connection was forcibly closed", None, 10054, None), ) with pytest.raises(ServiceResponseError): remote_client.runs.create_or_update(run=mock_run) # won't retry connection error since POST without response code is not retryable according to # retry policy assert mock_request.call_count == 1 with patch.object(RunOperations, "_resolve_data_to_asset_id"), patch.object(RunOperations, "_resolve_flow"): with patch.object(RequestsTransport, "send") as mock_request, patch.object( FlowServiceCaller, "_set_headers_with_user_aml_token" ): fake_response = Response() # won't retry 500 fake_response.status_code = 500 fake_response._content = b'{"error": "error"}' fake_response._content_consumed = True mock_request.return_value = RestRequestsTransportResponse( request=None, internal_response=fake_response, ) with pytest.raises(FlowRequestException): remote_client.runs.create_or_update(run=mock_run) assert mock_request.call_count == 1 with patch.object(RunOperations, "_resolve_data_to_asset_id"), patch.object(RunOperations, "_resolve_flow"): with patch.object(RequestsTransport, "send") as mock_request, patch.object( FlowServiceCaller, "_set_headers_with_user_aml_token" ): fake_response = Response() # will retry 503 fake_response.status_code = 503 fake_response._content = b'{"error": "error"}' fake_response._content_consumed = True mock_request.return_value = RestRequestsTransportResponse( request=None, internal_response=fake_response, ) with pytest.raises(FlowRequestException): remote_client.runs.create_or_update(run=mock_run) assert mock_request.call_count == 4 def test_pf_run_with_env_var(self, pf, randstr: Callable[[str], str]): from promptflow.azure.operations import RunOperations def create_or_update(run, **kwargs): # make run.flow a datastore path uri, so that it can be parsed by AzureMLDatastorePathUri run.flow = "azureml://datastores/workspaceblobstore/paths/LocalUpload/not/important/path" return run with patch.object(RunOperations, "create_or_update") as mock_create_or_update: mock_create_or_update.side_effect = create_or_update env_var = {"API_BASE": "${azure_open_ai_connection.api_base}"} run = pf.run( flow=f"{FLOWS_DIR}/print_env_var", data=f"{DATAS_DIR}/env_var_names.jsonl", environment_variables=env_var, name=randstr("name"), ) assert run._to_rest_object().environment_variables == env_var def test_automatic_runtime(self, pf, randstr: Callable[[str], str]): from promptflow.azure._restclient.flow_service_caller import FlowServiceCaller from promptflow.azure.operations import RunOperations def submit(*args, **kwargs): body = kwargs.get("body", None) assert body.runtime_name == "automatic" assert body.vm_size is None assert body.max_idle_time_seconds is None return body with patch.object(FlowServiceCaller, "submit_bulk_run") as mock_submit, patch.object(RunOperations, "get"): mock_submit.side_effect = submit # no runtime provided, will use automatic runtime pf.run( flow=f"{FLOWS_DIR}/print_env_var", data=f"{DATAS_DIR}/env_var_names.jsonl", name=randstr("name1"), ) with patch.object(FlowServiceCaller, "submit_bulk_run") as mock_submit, patch.object(RunOperations, "get"): mock_submit.side_effect = submit # automatic is a reserved runtime name, will use automatic runtime if specified. pf.run( flow=f"{FLOWS_DIR}/print_env_var", data=f"{DATAS_DIR}/env_var_names.jsonl", runtime="automatic", name=randstr("name2"), ) def test_automatic_runtime_with_resources(self, pf, randstr: Callable[[str], str]): from promptflow.azure._restclient.flow.models import SessionSetupModeEnum source = f"{RUNS_DIR}/sample_bulk_run_with_resources.yaml" run_id = randstr("run_id") run = load_run( source=source, params_override=[{"name": run_id}], ) rest_run = run._to_rest_object() assert rest_run.vm_size == "Standard_D2" assert rest_run.max_idle_time_seconds == 3600 assert rest_run.session_setup_mode == SessionSetupModeEnum.SYSTEM_WAIT run = pf.runs.create_or_update(run=run) assert isinstance(run, Run) def test_run_data_not_provided(self, pf, randstr: Callable[[str], str]): with pytest.raises(UserErrorException) as e: pf.run( flow=f"{FLOWS_DIR}/web_classification", name=randstr("name"), ) assert "at least one of data or run must be provided" in str(e) def test_run_without_dump(self, pf, runtime: str, randstr: Callable[[str], str]) -> None: from promptflow._sdk._errors import RunNotFoundError from promptflow._sdk._orm.run_info import RunInfo run = pf.run( flow=f"{FLOWS_DIR}/web_classification", data=f"{DATAS_DIR}/webClassification1.jsonl", column_mapping={"url": "${data.url}"}, variant="${summarize_text_content.variant_0}", runtime=runtime, name=randstr("name"), ) # cloud run should not dump to database with pytest.raises(RunNotFoundError): RunInfo.get(run.name) def test_input_mapping_with_dict(self, pf, runtime: str, randstr: Callable[[str], str]): data_path = f"{DATAS_DIR}/webClassification3.jsonl" run = pf.run( flow=f"{FLOWS_DIR}/flow_with_dict_input", data=data_path, column_mapping=dict(key={"a": 1}, extra="${data.url}"), runtime=runtime, name=randstr("name"), ) assert '"{\\"a\\": 1}"' in run.properties["azureml.promptflow.inputs_mapping"] run = pf.runs.stream(run=run) assert run.status == "Completed" def test_get_invalid_run_cases(self, pf, randstr: Callable[[str], str]): # test get invalid run type with pytest.raises(InvalidRunError, match="expected 'str' or 'Run' object"): pf.runs.get(run=object()) # test get invalid run name non_exist_run = randstr("non_exist_run") with pytest.raises(RunNotFoundError, match=f"Run {non_exist_run!r} not found"): pf.runs.get(run=non_exist_run) # TODO: need to confirm whether this is an end-to-end test def test_exp_id(self): with TemporaryDirectory() as tmp_dir: shutil.copytree(f"{FLOWS_DIR}/flow_with_dict_input", f"{tmp_dir}/flow dir with space") run = Run( flow=Path(f"{tmp_dir}/flow dir with space"), data=f"{DATAS_DIR}/webClassification3.jsonl", ) rest_run = run._to_rest_object() assert rest_run.run_experiment_name == "flow_dir_with_space" shutil.copytree(f"{FLOWS_DIR}/flow_with_dict_input", f"{tmp_dir}/flow-dir-with-dash") run = Run( flow=Path(f"{tmp_dir}/flow-dir-with-dash"), data=f"{DATAS_DIR}/webClassification3.jsonl", ) rest_run = run._to_rest_object() assert rest_run.run_experiment_name == "flow_dir_with_dash" def test_tools_json_ignored(self, pf, randstr: Callable[[str], str]): from azure.ai.ml._artifacts._blob_storage_helper import BlobStorageClient from promptflow.azure._restclient.flow_service_caller import FlowServiceCaller from promptflow.azure.operations import RunOperations files_to_upload = [] def fake_upload_file(storage_client, source: str, dest, *args, **kwargs): files_to_upload.append(source) storage_client.uploaded_file_count += 1 with patch("azure.ai.ml._utils._asset_utils.upload_file") as mock_upload_file, patch.object( FlowServiceCaller, "submit_bulk_run" ), patch.object(BlobStorageClient, "_set_confirmation_metadata"), patch.object(RunOperations, "get"): mock_upload_file.side_effect = fake_upload_file data_path = f"{DATAS_DIR}/webClassification3.jsonl" pf.run( flow=f"{FLOWS_DIR}/flow_with_dict_input", data=data_path, column_mapping={"key": {"value": "1"}, "url": "${data.url}"}, runtime="fake_runtime", name=randstr("name"), ) # make sure .promptflow/flow.tools.json not uploaded for f in files_to_upload: if ".promptflow/flow.tools.json" in f: raise Exception(f"flow.tools.json should not be uploaded, got {f}") def test_flow_id_in_submission(self, pf, runtime: str, randstr: Callable[[str], str]): from promptflow.azure._restclient.flow_service_caller import FlowServiceCaller from promptflow.azure.operations import RunOperations flow_path = f"{FLOWS_DIR}/print_env_var" flow_lineage_id = get_flow_lineage_id(flow_path) flow_session_id = pf._runs._get_session_id(flow_path) def submit(*args, **kwargs): body = kwargs.get("body", None) assert flow_session_id == body.session_id assert flow_lineage_id == body.flow_lineage_id return body # flow session id is same with or without session creation with patch.object(FlowServiceCaller, "submit_bulk_run") as mock_submit, patch.object( RunOperations, "get" ), patch.object(FlowServiceCaller, "create_flow_session"): mock_submit.side_effect = submit pf.run( flow=flow_path, data=f"{DATAS_DIR}/env_var_names.jsonl", runtime=runtime, name=randstr("name1"), ) with patch.object(FlowServiceCaller, "submit_bulk_run") as mock_submit, patch.object( RunOperations, "get" ), patch.object(FlowServiceCaller, "create_flow_session"): mock_submit.side_effect = submit # no runtime provided, will use automatic runtime pf.run( flow=flow_path, data=f"{DATAS_DIR}/env_var_names.jsonl", name=randstr("name2"), ) def test_run_submission_exception(self, pf): from azure.core.exceptions import HttpResponseError from promptflow.azure._restclient.flow.operations import BulkRunsOperations from promptflow.azure._restclient.flow_service_caller import FlowRequestException, FlowServiceCaller def fake_submit(*args, **kwargs): headers = kwargs.get("headers", None) request_id_in_headers = headers["x-ms-client-request-id"] # request id in headers should be same with request id in service caller assert request_id_in_headers == pf.runs._service_caller._request_id raise HttpResponseError("customized error message.") with patch.object(BulkRunsOperations, "submit_bulk_run") as mock_request, patch.object( FlowServiceCaller, "_set_headers_with_user_aml_token" ): mock_request.side_effect = fake_submit with pytest.raises(FlowRequestException) as e: original_request_id = pf.runs._service_caller._request_id pf.runs._service_caller.submit_bulk_run( subscription_id="fake_subscription_id", resource_group_name="fake_resource_group", workspace_name="fake_workspace_name", ) # request id has been updated assert original_request_id != pf.runs._service_caller._request_id # original error message should be included in FlowRequestException assert "customized error message" in str(e.value) # request id should be included in FlowRequestException assert f"request id: {pf.runs._service_caller._request_id}" in str(e.value) def test_get_detail_against_partial_fail_run(self, pf, runtime: str, randstr: Callable[[str], str]) -> None: run = pf.run( flow=f"{FLOWS_DIR}/partial_fail", data=f"{FLOWS_DIR}/partial_fail/data.jsonl", runtime=runtime, name=randstr("name"), ) pf.runs.stream(run=run.name) detail = pf.get_details(run=run.name) assert len(detail) == 3 # TODO: seems another unit test... def test_vnext_workspace_base_url(self): from promptflow.azure._restclient.service_caller_factory import _FlowServiceCallerFactory mock_workspace = MagicMock() mock_workspace.discovery_url = "https://promptflow.azure-api.net/discovery/workspaces/fake_workspace_id" service_caller = _FlowServiceCallerFactory.get_instance( workspace=mock_workspace, credential=MagicMock(), operation_scope=MagicMock() ) assert service_caller.caller._client._base_url == "https://promptflow.azure-api.net/" @pytest.mark.usefixtures("mock_isinstance_for_mock_datastore") def test_download_run(self, pf: PFClient, created_batch_run_without_llm: Run): expected_files = [ DownloadedRun.RUN_METADATA_FILE_NAME, DownloadedRun.LOGS_FILE_NAME, DownloadedRun.METRICS_FILE_NAME, f"{DownloadedRun.SNAPSHOT_FOLDER}/flow.dag.yaml", ] with TemporaryDirectory() as tmp_dir: pf.runs.download(run=created_batch_run_without_llm.name, output=tmp_dir) for file in expected_files: assert Path(tmp_dir, created_batch_run_without_llm.name, file).exists() def test_request_id_when_making_http_requests(self, pf, runtime: str, randstr: Callable[[str], str]): from azure.core.exceptions import HttpResponseError from promptflow.azure._restclient.flow.operations import BulkRunsOperations from promptflow.azure._restclient.flow_service_caller import FlowRequestException request_ids = set() def fake_submit(*args, **kwargs): headers = kwargs.get("headers", None) request_id_in_headers = headers["x-ms-client-request-id"] # request id in headers should be same with request id in service caller assert request_id_in_headers == pf.runs._service_caller._request_id # request id in request is same request id in collected logs assert request_id_in_headers in request_ids raise HttpResponseError("customized error message.") def check_inner_call(*args, **kwargs): if "extra" in kwargs: request_id = pydash.get(kwargs, "extra.custom_dimensions.request_id") request_ids.add(request_id) with patch.object(BulkRunsOperations, "submit_bulk_run") as mock_request, patch.object( Logger, "info" ) as mock_logger: mock_logger.side_effect = check_inner_call mock_request.side_effect = fake_submit with pytest.raises(FlowRequestException) as e: pf.run( flow=f"{FLOWS_DIR}/print_env_var", data=f"{DATAS_DIR}/env_var_names.jsonl", runtime=runtime, name=randstr("name1"), ) # request id in service caller is same request id in collected logs assert pf.runs._service_caller._request_id in request_ids # only 1 request id generated in logs assert len(request_ids) == 1 # request id should be included in FlowRequestException assert f"request id: {pf.runs._service_caller._request_id}" in str(e.value) old_request_id = request_ids.pop() with pytest.raises(FlowRequestException) as e: pf.run( flow=f"{FLOWS_DIR}/print_env_var", data=f"{DATAS_DIR}/env_var_names.jsonl", runtime=runtime, name=randstr("name1"), ) # request id in service caller is same request id in collected logs assert pf.runs._service_caller._request_id in request_ids # request id is not same with before assert old_request_id not in request_ids # only 1 request id generated in logs assert len(request_ids) == 1 # request id should be included in FlowRequestException assert f"request id: {pf.runs._service_caller._request_id}" in str(e.value) def test_get_details_against_partial_completed_run( self, pf: PFClient, runtime: str, randstr: Callable[[str], str] ) -> None: flow_mod2 = f"{FLOWS_DIR}/mod-n/two" flow_mod3 = f"{FLOWS_DIR}/mod-n/three" data_path = f"{DATAS_DIR}/numbers.jsonl" # batch run against data run1 = pf.run( flow=flow_mod2, data=data_path, column_mapping={"number": "${data.value}"}, runtime=runtime, name=randstr("run1"), ) pf.runs.stream(run1) details1 = pf.get_details(run1) assert len(details1) == 20 assert len(details1[details1["outputs.output"].notnull()]) == 10 # assert to ensure inputs and outputs are aligned for _, row in details1.iterrows(): if pd.notnull(row["outputs.output"]): assert int(row["inputs.number"]) == int(row["outputs.output"]) # batch run against previous run run2 = pf.run( flow=flow_mod3, run=run1, column_mapping={"number": "${run.outputs.output}"}, runtime=runtime, name=randstr("run2"), ) pf.runs.stream(run2) details2 = pf.get_details(run2) assert len(details2) == 10 assert len(details2[details2["outputs.output"].notnull()]) == 4 # assert to ensure inputs and outputs are aligned for _, row in details2.iterrows(): if pd.notnull(row["outputs.output"]): assert int(row["inputs.number"]) == int(row["outputs.output"]) @pytest.mark.usefixtures("mock_isinstance_for_mock_datastore") def test_auto_resolve_requirements(self, pf: PFClient, randstr: Callable[[str], str]): # will add requirements.txt to flow.dag.yaml if exists when submitting run. with TemporaryDirectory() as temp: temp = Path(temp) shutil.copytree(f"{FLOWS_DIR}/flow_with_requirements_txt", temp / "flow_with_requirements_txt") run = pf.run( flow=temp / "flow_with_requirements_txt", data=f"{DATAS_DIR}/env_var_names.jsonl", name=randstr("name"), ) pf.runs.stream(run) pf.runs.download(run=run.name, output=temp) flow_dag = load_yaml(Path(temp, run.name, "snapshot/flow.dag.yaml")) assert "requirements.txt" in flow_dag[ENVIRONMENT][PYTHON_REQUIREMENTS_TXT] local_flow_dag = load_yaml(f"{FLOWS_DIR}/flow_with_requirements_txt/flow.dag.yaml") assert "environment" not in local_flow_dag @pytest.mark.usefixtures("mock_isinstance_for_mock_datastore") def test_requirements_in_additional_includes(self, pf: PFClient, randstr: Callable[[str], str]): run = pf.run( flow=f"{FLOWS_DIR}/flow_with_additional_include_req", data=f"{DATAS_DIR}/env_var_names.jsonl", name=randstr("name"), ) run = pf.runs.stream(run) assert run._error is None with TemporaryDirectory() as temp: pf.runs.download(run=run.name, output=temp) assert Path(temp, run.name, "snapshot/requirements").exists() @pytest.mark.skipif( condition=is_live(), reason="removed requirement.txt to avoid compliance check.", ) def test_eager_flow_crud(self, pf: PFClient, randstr: Callable[[str], str], simple_eager_run: Run): run = simple_eager_run run = pf.runs.get(run) assert run.status == RunStatus.COMPLETED details = pf.runs.get_details(run) assert details.shape[0] == 1 metrics = pf.runs.get_metrics(run) assert metrics == {} # TODO(2917923): cannot differ the two requests to run history in replay mode." # run_meta_data = RunHistoryKeys.RunMetaData # hidden = RunHistoryKeys.HIDDEN # run_id = run.name # # test archive # pf.runs.archive(run=run_id) # run_data = pf.runs._get_run_from_run_history(run_id, original_form=True)[run_meta_data] # assert run_data[hidden] is True # # # test restore # pf.runs.restore(run=run_id) # run_data = pf.runs._get_run_from_run_history(run_id, original_form=True)[run_meta_data] # assert run_data[hidden] is False @pytest.mark.skipif( condition=is_live(), reason="removed requirement.txt to avoid compliance check.", ) def test_eager_flow_cancel(self, pf: PFClient, randstr: Callable[[str], str]): """Test cancel eager flow.""" # create a run run_name = randstr("name") pf.run( flow=f"{EAGER_FLOWS_DIR}/long_running", data=f"{DATAS_DIR}/simple_eager_flow_data.jsonl", name=run_name, ) pf.runs.cancel(run=run_name) sleep(3) run = pf.runs.get(run=run_name) # the run status might still be cancel requested, but it should be canceled eventually assert run.status in [RunStatus.CANCELED, RunStatus.CANCEL_REQUESTED] @pytest.mark.skipif( condition=is_live(), reason="removed requirement.txt to avoid compliance check.", ) @pytest.mark.usefixtures("mock_isinstance_for_mock_datastore") def test_eager_flow_download(self, pf: PFClient, simple_eager_run: Run): run = simple_eager_run expected_files = [ DownloadedRun.RUN_METADATA_FILE_NAME, DownloadedRun.LOGS_FILE_NAME, DownloadedRun.METRICS_FILE_NAME, f"{DownloadedRun.SNAPSHOT_FOLDER}/flow.dag.yaml", ] # test download with TemporaryDirectory() as tmp_dir: pf.runs.download(run=run.name, output=tmp_dir) for file in expected_files: assert Path(tmp_dir, run.name, file).exists()
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/classificationAccuracy.csv
groundtruth,prediction App,App App,App App,App App,App App,App App,App App,App
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_azure_cli_perf.py
import os import sys import timeit from typing import Callable from unittest import mock import pytest from promptflow._cli._user_agent import USER_AGENT as CLI_USER_AGENT # noqa: E402 from promptflow._sdk._telemetry import log_activity from promptflow._sdk._utils import ClientUserAgentUtil from sdk_cli_azure_test.recording_utilities import is_replay FLOWS_DIR = "./tests/test_configs/flows" DATAS_DIR = "./tests/test_configs/datas" def mock_log_activity(*args, **kwargs): custom_message = "github run: https://github.com/microsoft/promptflow/actions/runs/{0}".format( os.environ.get("GITHUB_RUN_ID") ) if len(args) == 4: if args[3] is not None: args[3]["custom_message"] = custom_message else: args = list(args) args[3] = {"custom_message": custom_message} elif "custom_dimensions" in kwargs and kwargs["custom_dimensions"] is not None: kwargs["custom_dimensions"]["custom_message"] = custom_message else: kwargs["custom_dimensions"] = {"custom_message": custom_message} return log_activity(*args, **kwargs) def run_cli_command(cmd, time_limit=3600): from promptflow._cli._pf_azure.entry import main sys.argv = list(cmd) st = timeit.default_timer() with mock.patch.object(ClientUserAgentUtil, "get_user_agent") as get_user_agent_fun, mock.patch( "promptflow._sdk._telemetry.activity.log_activity", side_effect=mock_log_activity ), mock.patch("promptflow._cli._pf_azure.entry.log_activity", side_effect=mock_log_activity): # Client side will modify user agent only through ClientUserAgentUtil to avoid impact executor/runtime. get_user_agent_fun.return_value = f"{CLI_USER_AGENT} perf_monitor/1.0" user_agent = ClientUserAgentUtil.get_user_agent() assert user_agent == f"{CLI_USER_AGENT} perf_monitor/1.0" main() ed = timeit.default_timer() print(f"{cmd}, \nTotal time: {ed - st}s") if is_replay(): assert ed - st < time_limit, f"The time limit is {time_limit}s, but it took {ed - st}s." @pytest.fixture def operation_scope_args(subscription_id: str, resource_group_name: str, workspace_name: str): return [ "--subscription", subscription_id, "--resource-group", resource_group_name, "--workspace-name", workspace_name, ] @pytest.mark.perf_monitor_test @pytest.mark.usefixtures( "mock_get_azure_pf_client", "mock_set_headers_with_user_aml_token", "single_worker_thread_pool", "vcr_recording", ) class TestAzureCliPerf: def test_pfazure_run_create(self, operation_scope_args, randstr: Callable[[str], str], time_limit=15): name = randstr("name") run_cli_command( cmd=( "pfazure", "run", "create", "--flow", f"{FLOWS_DIR}/print_input_flow", "--data", f"{DATAS_DIR}/print_input_flow.jsonl", "--name", name, *operation_scope_args, ), time_limit=time_limit, ) def test_pfazure_run_update(self, operation_scope_args, time_limit=15): run_cli_command( cmd=( "pfazure", "run", "update", "--name", "test_run", "--set", "display_name=test_run", "description='test_description'", "tags.key1=value1", *operation_scope_args, ), time_limit=time_limit, ) def test_run_restore(self, operation_scope_args, time_limit=15): run_cli_command( cmd=( "pfazure", "run", "restore", "--name", "test_run", *operation_scope_args, ), time_limit=time_limit, )
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_flow_in_azure_ml.py
import re from pathlib import Path import pydash import pytest from promptflow._utils.yaml_utils import dump_yaml, load_yaml_string from promptflow.connections import AzureOpenAIConnection from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD from ..recording_utilities import is_live PROMOTFLOW_ROOT = Path(__file__) / "../../../.." TEST_ROOT = Path(__file__).parent.parent.parent MODEL_ROOT = TEST_ROOT / "test_configs/e2e_samples" CONNECTION_FILE = (PROMOTFLOW_ROOT / "connections.json").resolve().absolute().as_posix() def assert_dict_equals_with_skip_fields(item1, item2, skip_fields): for fot_key in skip_fields: pydash.set_(item1, fot_key, None) pydash.set_(item2, fot_key, None) assert item1 == item2 def normalize_arm_id(origin_value: str): if origin_value: m = re.match( r"(.*)/subscriptions/[a-z0-9\-]+/resourceGroups/[a-z0-9\-]+/providers/" r"Microsoft.MachineLearningServices/workspaces/[a-z0-9\-]+/([a-z]+)/[^/]+/versions/([a-z0-9\-]+)", origin_value, ) if m: prefix, asset_type, _ = m.groups() return ( f"{prefix}/subscriptions/xxx/resourceGroups/xxx/providers/" f"Microsoft.MachineLearningServices/workspaces/xxx/{asset_type}/xxx/versions/xxx" ) return None def update_saved_spec(component, saved_spec_path: str): yaml_text = component._to_yaml() saved_spec_path = Path(saved_spec_path) yaml_content = load_yaml_string(yaml_text) if yaml_content.get("creation_context"): for key in yaml_content.get("creation_context"): yaml_content["creation_context"][key] = "xxx" for key in ["task.code", "task.environment", "id"]: target_value = normalize_arm_id(pydash.get(yaml_content, key)) if target_value: pydash.set_(yaml_content, key, target_value) yaml_text = dump_yaml(yaml_content) if saved_spec_path.is_file(): current_spec_text = saved_spec_path.read_text() if current_spec_text == yaml_text: return saved_spec_path.parent.mkdir(parents=True, exist_ok=True) saved_spec_path.write_text(yaml_text) @pytest.mark.skipif( condition=not is_live(), reason="flow in pipeline tests require secrets config file, only run in live mode.", ) @pytest.mark.usefixtures("use_secrets_config_file") @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.e2etest class TestFlowInAzureML: @pytest.mark.parametrize( "load_params, expected_spec_attrs", [ pytest.param( { "name": "web_classification_4", "version": "1.0.0", "description": "Create flows that use large language models to " "classify URLs into multiple categories.", "environment_variables": { "verbose": "true", }, }, { "name": "web_classification_4", "version": "1.0.0", "description": "Create flows that use large language models to " "classify URLs into multiple categories.", "type": "parallel", }, id="parallel", ), ], ) def test_flow_as_component( self, azure_open_ai_connection: AzureOpenAIConnection, temp_output_dir, ml_client, load_params: dict, expected_spec_attrs: dict, request, ) -> None: # keep the simplest test here, more tests are in azure-ai-ml from azure.ai.ml import load_component flows_dir = "./tests/test_configs/flows" flow_func: Component = load_component( f"{flows_dir}/web_classification/flow.dag.yaml", params_override=[load_params] ) # TODO: snapshot of flow component changed every time? created_component = ml_client.components.create_or_update(flow_func, is_anonymous=True) update_saved_spec( created_component, f"./tests/test_configs/flows/saved_component_spec/{request.node.callspec.id}.yaml" ) component_dict = created_component._to_dict() slimmed_created_component_attrs = {key: pydash.get(component_dict, key) for key in expected_spec_attrs.keys()} assert slimmed_created_component_attrs == expected_spec_attrs
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_flow_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json from pathlib import Path import pytest from promptflow.azure._entities._flow import Flow from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD from ..recording_utilities import is_live tests_root_dir = Path(__file__).parent.parent.parent flow_test_dir = tests_root_dir / "test_configs/flows" data_dir = tests_root_dir / "test_configs/datas" @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.e2etest @pytest.mark.usefixtures( "mock_set_headers_with_user_aml_token", "single_worker_thread_pool", "vcr_recording", ) class TestFlow: def test_create_flow(self, created_flow: Flow): # most of the assertions are in the fixture itself assert isinstance(created_flow, Flow) def test_get_flow(self, pf, created_flow: Flow): result = pf.flows.get(name=created_flow.name) # assert created flow is the same as the one retrieved attributes = vars(result) for attr in attributes: assert getattr(result, attr) == getattr(created_flow, attr), f"Assertion failed for attribute: {attr!r}" @pytest.mark.skipif( condition=not is_live(), reason="Complicated test combining `pf flow test` and global config", ) def test_flow_test_with_config(self, remote_workspace_resource_id): from promptflow import PFClient client = PFClient(config={"connection.provider": remote_workspace_resource_id}) output = client.test(flow=flow_test_dir / "web_classification") assert output.keys() == {"category", "evidence"} @pytest.mark.usefixtures("mock_get_user_identity_info") def test_list_flows(self, pf): flows = pf.flows.list(max_results=3) for flow in flows: print(json.dumps(flow._to_dict(), indent=4)) assert len(flows) == 3
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_flow_serve.py
import json import pytest from ..recording_utilities import is_live testdata = """The event sourcing pattern involves using an append-only store to record the full series of actions on that data. The Azure Cosmos DB change feed is a great choice as a central data store in event sourcing architectures in which all data ingestion is modeled as writes (no updates or deletes). In this case, each write to Azure Cosmos DB is an \"event,\" so there's a full record of past events in the change feed. Typical uses of the events published by the central event store are to maintain materialized views or to integrate with external systems. Because there's no time limit for retention in the change feed latest version mode, you can replay all past events by reading from the beginning of your Azure Cosmos DB container's change feed. You can even have multiple change feed consumers subscribe to the same container's change feed.""" @pytest.mark.skipif(condition=not is_live(), reason="serving tests, only run in live mode.") @pytest.mark.usefixtures("flow_serving_client_remote_connection") @pytest.mark.e2etest def test_local_serving_api_with_remote_connection(flow_serving_client_remote_connection): response = flow_serving_client_remote_connection.get("/health") assert b'{"status":"Healthy","version":"0.0.1"}' in response.data response = flow_serving_client_remote_connection.post("/score", data=json.dumps({"text": "hi"})) assert ( response.status_code == 200 ), f"Response code indicates error {response.status_code} - {response.data.decode()}" assert "output_prompt" in json.loads(response.data.decode()) @pytest.mark.skipif(condition=not is_live(), reason="serving tests, only run in live mode.") @pytest.mark.usefixtures("flow_serving_client_with_prt_config_env") @pytest.mark.e2etest def test_azureml_serving_api_with_prt_config_env(flow_serving_client_with_prt_config_env): response = flow_serving_client_with_prt_config_env.get("/health") assert b'{"status":"Healthy","version":"0.0.1"}' in response.data response = flow_serving_client_with_prt_config_env.post("/score", data=json.dumps({"text": "hi"})) assert ( response.status_code == 200 ), f"Response code indicates error {response.status_code} - {response.data.decode()}" assert "output_prompt" in json.loads(response.data.decode()) response = flow_serving_client_with_prt_config_env.get("/") assert b"Welcome to promptflow app" in response.data @pytest.mark.skipif(condition=not is_live(), reason="serving tests, only run in live mode.") @pytest.mark.usefixtures("flow_serving_client_with_connection_provider_env") @pytest.mark.e2etest def test_azureml_serving_api_with_conn_provider_env(flow_serving_client_with_connection_provider_env): response = flow_serving_client_with_connection_provider_env.get("/health") assert b'{"status":"Healthy","version":"0.0.1"}' in response.data response = flow_serving_client_with_connection_provider_env.post("/score", data=json.dumps({"text": "hi"})) assert ( response.status_code == 200 ), f"Response code indicates error {response.status_code} - {response.data.decode()}" assert "output_prompt" in json.loads(response.data.decode()) response = flow_serving_client_with_connection_provider_env.get("/") assert b"Welcome to promptflow app" in response.data @pytest.mark.skipif(condition=not is_live(), reason="serving tests, only run in live mode.") @pytest.mark.usefixtures("flow_serving_client_with_connection_provider_env") @pytest.mark.e2etest def test_azureml_serving_api_with_aml_resource_id_env(flow_serving_client_with_aml_resource_id_env): response = flow_serving_client_with_aml_resource_id_env.get("/health") assert b'{"status":"Healthy","version":"0.0.1"}' in response.data response = flow_serving_client_with_aml_resource_id_env.post("/score", data=json.dumps({"text": "hi"})) assert ( response.status_code == 200 ), f"Response code indicates error {response.status_code} - {response.data.decode()}" assert "output_prompt" in json.loads(response.data.decode()) @pytest.mark.skipif(condition=not is_live(), reason="serving tests, only run in live mode.") @pytest.mark.usefixtures("serving_client_with_connection_name_override") @pytest.mark.e2etest def test_azureml_serving_api_with_connection_name_override(serving_client_with_connection_name_override): response = serving_client_with_connection_name_override.get("/health") assert b'{"status":"Healthy","version":"0.0.1"}' in response.data response = serving_client_with_connection_name_override.post("/score", data=json.dumps({"text": testdata})) assert ( response.status_code == 200 ), f"Response code indicates error {response.status_code} - {response.data.decode()}" assert "api_base" not in json.loads(response.data.decode()).values() @pytest.mark.usefixtures("serving_client_with_connection_data_override") @pytest.mark.e2etest def test_azureml_serving_api_with_connection_data_override(serving_client_with_connection_data_override): response = serving_client_with_connection_data_override.get("/health") assert b'{"status":"Healthy","version":"0.0.1"}' in response.data response = serving_client_with_connection_data_override.post("/score", data=json.dumps({"text": "hi"})) assert ( response.status_code == 200 ), f"Response code indicates error {response.status_code} - {response.data.decode()}" assert "api_base" in json.loads(response.data.decode()).values()
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_connection_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import pydash import pytest from promptflow._sdk.entities._connection import _Connection from promptflow.connections import AzureOpenAIConnection, CustomConnection from promptflow.contracts.types import Secret from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD @pytest.fixture def connection_ops(pf): return pf._connections @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.e2etest @pytest.mark.usefixtures("vcr_recording") class TestConnectionOperations: @pytest.mark.skip(reason="Skip to avoid flooded connections in workspace.") def test_connection_get_create_delete(self, connection_ops): from promptflow.azure._restclient.flow_service_caller import FlowRequestException connection = _Connection( name="test_connection_1", type="AzureOpenAI", configs=AzureOpenAIConnection( api_key=Secret("test_key"), api_base="test_base", api_type="azure", api_version="2023-07-01-preview", ), ) try: result = connection_ops.get(name=connection.name) except FlowRequestException: result = connection_ops.create_or_update(connection) config_dict = pydash.omit(result._to_dict(), "configs.api_key") assert config_dict == { "name": "test_connection_1", "connection_type": "AzureOpenAI", "connection_scope": "User", "configs": {"api_base": "test_base", "api_type": "azure", "api_version": "2023-07-01-preview"}, } # soft delete connection_ops.delete(name=connection.name) @pytest.mark.skip(reason="Skip to avoid flooded connections in workspace.") def test_custom_connection_create(self, connection_ops): from promptflow.azure._restclient.flow_service_caller import FlowRequestException connection = _Connection( name="test_connection_2", type="Custom", custom_configs=CustomConnection(a="1", b=Secret("2")) ) try: result = connection_ops.get(name=connection.name) except FlowRequestException: result = connection_ops.create_or_update(connection) config_dict = pydash.omit(result._to_dict(), "custom_configs") assert config_dict == {"connection_scope": "User", "connection_type": "Custom", "name": "test_connection_2"} # soft delete connection_ops.delete(name=connection.name) def test_list_connection_spec(self, connection_ops): result = {v.connection_type: v._to_dict() for v in connection_ops.list_connection_specs()} # Assert custom keys type assert "Custom" in result assert result["Custom"] == { "module": "promptflow.connections", "connection_type": "Custom", "flow_value_type": "CustomConnection", "config_specs": [], } # assert strong type assert "AzureOpenAI" in result aoai_config_specs = result["AzureOpenAI"]["config_specs"] for config_dict in aoai_config_specs: if config_dict["name"] == "api_version": del config_dict["default_value"] expected_config_specs = [ {"name": "api_key", "display_name": "API key", "config_value_type": "Secret", "is_optional": False}, {"name": "api_base", "display_name": "API base", "config_value_type": "String", "is_optional": False}, { "name": "api_type", "display_name": "API type", "config_value_type": "String", "default_value": "azure", "is_optional": False, }, { "name": "api_version", "display_name": "API version", "config_value_type": "String", "is_optional": False, }, ] for spec in expected_config_specs: assert spec in result["AzureOpenAI"]["config_specs"] def test_get_connection(self, connection_ops): # Note: No secrets will be returned by MT api result = connection_ops.get(name="azure_open_ai_connection") assert ( result._to_dict().items() > { "api_type": "azure", "module": "promptflow.connections", "name": "azure_open_ai_connection", }.items() ) result = connection_ops.get(name="custom_connection") assert ( result._to_dict().items() > { "name": "custom_connection", "module": "promptflow.connections", "configs": {}, "secrets": {}, }.items() )
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_cli_with_azure.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import contextlib import os import sys import uuid from typing import Callable import pytest from mock.mock import patch from promptflow._constants import PF_USER_AGENT from promptflow._core.operation_context import OperationContext from promptflow._sdk._utils import ClientUserAgentUtil from promptflow._sdk.entities import Run from promptflow._utils.utils import environment_variable_overwrite, parse_ua_to_dict from promptflow.azure import PFClient from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD from ..recording_utilities import is_live FLOWS_DIR = "./tests/test_configs/flows" DATAS_DIR = "./tests/test_configs/datas" RUNS_DIR = "./tests/test_configs/runs" # TODO: move this to a shared utility module def run_pf_command(*args, pf, runtime=None, cwd=None): from promptflow._cli._pf_azure.entry import main origin_argv, origin_cwd = sys.argv, os.path.abspath(os.curdir) try: sys.argv = ( ["pfazure"] + list(args) + [ "--subscription", pf._ml_client.subscription_id, "--resource-group", pf._ml_client.resource_group_name, "--workspace-name", pf._ml_client.workspace_name, ] ) if runtime: sys.argv += ["--runtime", runtime] if cwd: os.chdir(cwd) main() finally: sys.argv = origin_argv os.chdir(origin_cwd) @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.e2etest @pytest.mark.usefixtures( "mock_get_azure_pf_client", "mock_set_headers_with_user_aml_token", "single_worker_thread_pool", "vcr_recording", ) class TestCliWithAzure: def test_basic_flow_run_bulk_without_env(self, pf, runtime: str, randstr: Callable[[str], str]) -> None: name = randstr("name") run_pf_command( "run", "create", "--flow", f"{FLOWS_DIR}/web_classification", "--data", f"{DATAS_DIR}/webClassification3.jsonl", "--name", name, pf=pf, runtime=runtime, ) run = pf.runs.get(run=name) assert isinstance(run, Run) @pytest.mark.skip("Custom tool pkg and promptprompt pkg with CustomStrongTypeConnection not installed on runtime.") def test_basic_flow_with_package_tool_with_custom_strong_type_connection(self, pf, runtime) -> None: name = str(uuid.uuid4()) run_pf_command( "run", "create", "--flow", f"{FLOWS_DIR}/flow_with_package_tool_with_custom_strong_type_connection", "--data", f"{FLOWS_DIR}/flow_with_package_tool_with_custom_strong_type_connection/data.jsonl", "--name", name, pf=pf, runtime=runtime, ) run = pf.runs.get(run=name) assert isinstance(run, Run) def test_run_with_remote_data( self, pf, runtime: str, remote_web_classification_data, randstr: Callable[[str], str] ) -> None: # run with arm id name = randstr("name1") run_pf_command( "run", "create", "--flow", "web_classification", "--data", f"azureml:{remote_web_classification_data.id}", "--name", name, pf=pf, runtime=runtime, cwd=f"{FLOWS_DIR}", ) run = pf.runs.get(run=name) assert isinstance(run, Run) # run with name version name = randstr("name2") run_pf_command( "run", "create", "--flow", "web_classification", "--data", f"azureml:{remote_web_classification_data.name}:{remote_web_classification_data.version}", "--name", name, pf=pf, runtime=runtime, cwd=f"{FLOWS_DIR}", ) run = pf.runs.get(run=name) assert isinstance(run, Run) def test_run_file_with_set(self, pf, runtime: str, randstr: Callable[[str], str]) -> None: name = randstr("name") run_pf_command( "run", "create", "--file", f"{RUNS_DIR}/run_with_env.yaml", "--set", f"runtime={runtime}", "--name", name, pf=pf, ) run = pf.runs.get(run=name) assert isinstance(run, Run) assert run.properties["azureml.promptflow.runtime_name"] == runtime @pytest.mark.skipif(condition=not is_live(), reason="This test requires an actual PFClient") def test_azure_cli_ua(self, pf: PFClient): # clear user agent before test context = OperationContext().get_instance() context.user_agent = "" with environment_variable_overwrite(PF_USER_AGENT, ""): with pytest.raises(SystemExit): run_pf_command( "run", "show", "--name", "not_exist", pf=pf, ) user_agent = ClientUserAgentUtil.get_user_agent() ua_dict = parse_ua_to_dict(user_agent) assert ua_dict.keys() == {"promptflow-sdk", "promptflow-cli"} def test_cli_telemetry(self, pf, runtime: str, randstr: Callable[[str], str]) -> None: name = randstr("name") @contextlib.contextmanager def check_workspace_info(*args, **kwargs): if "custom_dimensions" in kwargs: assert kwargs["custom_dimensions"]["workspace_name"] == pf._ml_client.workspace_name assert kwargs["custom_dimensions"]["resource_group_name"] == pf._ml_client.resource_group_name assert kwargs["custom_dimensions"]["subscription_id"] == pf._ml_client.subscription_id yield None with patch("promptflow._sdk._telemetry.activity.log_activity") as mock_log_activity: mock_log_activity.side_effect = check_workspace_info run_pf_command( "run", "create", "--file", f"{RUNS_DIR}/run_with_env.yaml", "--set", f"runtime={runtime}", "--name", name, pf=pf, )
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_telemetry.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import contextlib import os import shutil import sys import tempfile import uuid from logging import Logger from pathlib import Path from typing import Callable from unittest.mock import MagicMock, patch import pydash import pytest from promptflow import load_run from promptflow._constants import PF_USER_AGENT from promptflow._core.operation_context import OperationContext from promptflow._sdk._configuration import Configuration from promptflow._sdk._errors import RunNotFoundError from promptflow._sdk._telemetry import ( ActivityType, PromptFlowSDKLogHandler, get_appinsights_log_handler, get_telemetry_logger, is_telemetry_enabled, log_activity, ) from promptflow._sdk._utils import ClientUserAgentUtil, call_from_extension from promptflow._utils.utils import environment_variable_overwrite, parse_ua_to_dict from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD @contextlib.contextmanager def cli_consent_config_overwrite(val): config = Configuration.get_instance() original_consent = config.get_telemetry_consent() config.set_telemetry_consent(val) try: yield finally: if original_consent: config.set_telemetry_consent(original_consent) else: config.set_telemetry_consent(True) @contextlib.contextmanager def extension_consent_config_overwrite(val): config = Configuration.get_instance() original_consent = config.get_config(key=Configuration.EXTENSION_COLLECT_TELEMETRY) config.set_config(key=Configuration.EXTENSION_COLLECT_TELEMETRY, value=val) try: yield finally: if original_consent: config.set_config(key=Configuration.EXTENSION_COLLECT_TELEMETRY, value=original_consent) else: config.set_config(key=Configuration.EXTENSION_COLLECT_TELEMETRY, value=True) RUNS_DIR = "./tests/test_configs/runs" FLOWS_DIR = "./tests/test_configs/flows" @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.usefixtures("mock_set_headers_with_user_aml_token", "single_worker_thread_pool", "vcr_recording") @pytest.mark.e2etest class TestTelemetry: def test_logging_handler(self): # override environment variable with cli_consent_config_overwrite(True): handler = get_appinsights_log_handler() assert isinstance(handler, PromptFlowSDKLogHandler) assert handler._is_telemetry_enabled is True with cli_consent_config_overwrite(False): handler = get_appinsights_log_handler() assert isinstance(handler, PromptFlowSDKLogHandler) assert handler._is_telemetry_enabled is False def test_call_from_extension(self): from promptflow._core.operation_context import OperationContext assert call_from_extension() is False with environment_variable_overwrite(PF_USER_AGENT, "prompt-flow-extension/1.0.0"): assert call_from_extension() is True # remove extension ua in context context = OperationContext().get_instance() context.user_agent = context.user_agent.replace("prompt-flow-extension/1.0.0", "") def test_custom_event(self, pf): from promptflow._sdk._telemetry.logging_handler import PromptFlowSDKLogHandler def log_event(*args, **kwargs): record = args[0] assert record.custom_dimensions is not None logger = get_telemetry_logger() handler = logger.handlers[0] assert isinstance(handler, PromptFlowSDKLogHandler) envelope = handler.log_record_to_envelope(record) custom_dimensions = pydash.get(envelope, "data.baseData.properties") assert isinstance(custom_dimensions, dict) # Note: need privacy review if we add new fields. if "start" in record.message: assert custom_dimensions.keys() == { "request_id", "activity_name", "activity_type", "subscription_id", "resource_group_name", "workspace_name", "level", "python_version", "user_agent", "installation_id", "first_call", "from_ci", } elif "complete" in record.message: assert custom_dimensions.keys() == { "request_id", "activity_name", "activity_type", "subscription_id", "resource_group_name", "workspace_name", "completion_status", "duration_ms", "level", "python_version", "user_agent", "installation_id", "first_call", "from_ci", } else: raise ValueError("Invalid message: {}".format(record.message)) assert record.message.startswith("pfazure.runs.get") with patch.object(PromptFlowSDKLogHandler, "emit") as mock_logger: mock_logger.side_effect = log_event # mock_error_logger.side_effect = log_event try: pf.runs.get("not_exist") except RunNotFoundError: pass def test_default_logging_behavior(self): assert is_telemetry_enabled() is True # default enable telemetry logger = get_telemetry_logger() handler = logger.handlers[0] assert isinstance(handler, PromptFlowSDKLogHandler) assert handler._is_telemetry_enabled is True def test_close_logging_handler(self): with cli_consent_config_overwrite(False): logger = get_telemetry_logger() handler = logger.handlers[0] assert isinstance(handler, PromptFlowSDKLogHandler) assert handler._is_telemetry_enabled is False with extension_consent_config_overwrite(False): with environment_variable_overwrite(PF_USER_AGENT, "prompt-flow-extension/1.0.0"): logger = get_telemetry_logger() handler = logger.handlers[0] assert isinstance(handler, PromptFlowSDKLogHandler) assert handler._is_telemetry_enabled is False # default enable telemetry logger = get_telemetry_logger() handler = logger.handlers[0] assert isinstance(handler, PromptFlowSDKLogHandler) assert handler._is_telemetry_enabled is True def test_cached_logging_handler(self): # should get same logger & handler instance if called multiple times logger = get_telemetry_logger() handler = next((h for h in logger.handlers if isinstance(h, PromptFlowSDKLogHandler)), None) another_logger = get_telemetry_logger() another_handler = next((h for h in another_logger.handlers if isinstance(h, PromptFlowSDKLogHandler)), None) assert logger is another_logger assert handler is another_handler def test_sdk_telemetry_ua(self, pf): from promptflow import PFClient from promptflow.azure import PFClient as PFAzureClient # log activity will pick correct ua def assert_ua(*args, **kwargs): ua = pydash.get(kwargs, "extra.custom_dimensions.user_agent", None) ua_dict = parse_ua_to_dict(ua) assert ua_dict.keys() == {"promptflow-sdk"} logger = MagicMock() logger.info = MagicMock() logger.info.side_effect = assert_ua # clear user agent before test context = OperationContext().get_instance() context.user_agent = "" # get telemetry logger from SDK should not have extension ua # start a clean local SDK client with environment_variable_overwrite(PF_USER_AGENT, ""): PFClient() user_agent = ClientUserAgentUtil.get_user_agent() ua_dict = parse_ua_to_dict(user_agent) assert ua_dict.keys() == {"promptflow-sdk"} # Call log_activity with log_activity(logger, "test_activity", activity_type=ActivityType.PUBLICAPI): # Perform some activity pass # start a clean Azure SDK client with environment_variable_overwrite(PF_USER_AGENT, ""): PFAzureClient( ml_client=pf._ml_client, subscription_id=pf._ml_client.subscription_id, resource_group_name=pf._ml_client.resource_group_name, workspace_name=pf._ml_client.workspace_name, ) user_agent = ClientUserAgentUtil.get_user_agent() ua_dict = parse_ua_to_dict(user_agent) assert ua_dict.keys() == {"promptflow-sdk"} # Call log_activity with log_activity(logger, "test_activity", activity_type=ActivityType.PUBLICAPI): # Perform some activity pass PFAzureClient( ml_client=pf._ml_client, subscription_id=pf._ml_client.subscription_id, resource_group_name=pf._ml_client.resource_group_name, workspace_name=pf._ml_client.workspace_name, user_agent="a/1.0.0", ) user_agent = ClientUserAgentUtil.get_user_agent() ua_dict = parse_ua_to_dict(user_agent) assert ua_dict.keys() == {"promptflow-sdk", "a"} context = OperationContext().get_instance() context.user_agent = "" def test_inner_function_call(self, pf, runtime: str, randstr: Callable[[str], str]): request_ids = set() first_sdk_calls = [] def check_inner_call(*args, **kwargs): if "extra" in kwargs: request_id = pydash.get(kwargs, "extra.custom_dimensions.request_id") first_sdk_call = pydash.get(kwargs, "extra.custom_dimensions.first_call") request_ids.add(request_id) first_sdk_calls.append(first_sdk_call) with patch.object(Logger, "info") as mock_logger: mock_logger.side_effect = check_inner_call run = load_run( source=f"{RUNS_DIR}/run_with_env.yaml", params_override=[{"runtime": runtime}], ) run.name = randstr("name") pf.runs.create_or_update(run=run) # only 1 request id assert len(request_ids) == 1 # only 1 and last call is public call assert first_sdk_calls[0] is True assert first_sdk_calls[-1] is True assert set(first_sdk_calls[1:-1]) == {False} def test_different_request_id(self): from promptflow import PFClient pf = PFClient() request_ids = set() first_sdk_calls = [] def check_inner_call(*args, **kwargs): if "extra" in kwargs: request_id = pydash.get(kwargs, "extra.custom_dimensions.request_id") first_sdk_call = pydash.get(kwargs, "extra.custom_dimensions.first_call") request_ids.add(request_id) first_sdk_calls.append(first_sdk_call) with patch.object(Logger, "info") as mock_logger: mock_logger.side_effect = check_inner_call run = load_run( source=f"{RUNS_DIR}/run_with_env.yaml", ) # create 2 times will get 2 request ids run.name = str(uuid.uuid4()) pf.runs.create_or_update(run=run) run.name = str(uuid.uuid4()) pf.runs.create_or_update(run=run) # only 1 request id assert len(request_ids) == 2 # 1 and last call is public call assert first_sdk_calls[0] is True assert first_sdk_calls[-1] is True def test_scrub_fields(self): from promptflow import PFClient pf = PFClient() from promptflow._sdk._telemetry.logging_handler import PromptFlowSDKLogHandler def log_event(*args, **kwargs): record = args[0] assert record.custom_dimensions is not None logger = get_telemetry_logger() handler = logger.handlers[0] assert isinstance(handler, PromptFlowSDKLogHandler) envelope = handler.log_record_to_envelope(record) # device name removed assert "ai.cloud.roleInstance" not in envelope.tags assert "ai.device.id" not in envelope.tags # role name should be scrubbed or kept in whitelist assert envelope.tags["ai.cloud.role"] in [os.path.basename(sys.argv[0]), "***"] with patch.object(PromptFlowSDKLogHandler, "emit") as mock_logger: mock_logger.side_effect = log_event # mock_error_logger.side_effect = log_event try: pf.runs.get("not_exist") except RunNotFoundError: pass def test_different_event_for_node_run(self): from promptflow import PFClient pf = PFClient() from promptflow._sdk._telemetry.logging_handler import PromptFlowSDKLogHandler def assert_node_run(*args, **kwargs): record = args[0] assert record.msg.startswith("pf.flows.node_test") assert record.custom_dimensions["activity_name"] == "pf.flows.node_test" def assert_flow_test(*args, **kwargs): record = args[0] assert record.msg.startswith("pf.flows.test") assert record.custom_dimensions["activity_name"] == "pf.flows.test" with tempfile.TemporaryDirectory() as temp_dir: shutil.copytree((Path(FLOWS_DIR) / "print_env_var").resolve().as_posix(), temp_dir, dirs_exist_ok=True) with patch.object(PromptFlowSDKLogHandler, "emit") as mock_logger: mock_logger.side_effect = assert_node_run pf.flows.test(temp_dir, node="print_env", inputs={"key": "API_BASE"}) with patch.object(PromptFlowSDKLogHandler, "emit") as mock_logger: mock_logger.side_effect = assert_flow_test pf.flows.test(temp_dir, inputs={"key": "API_BASE"})
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_arm_connection_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import pytest from .._azure_utils import DEFAULT_TEST_TIMEOUT, PYTEST_TIMEOUT_METHOD @pytest.fixture def connection_ops(pf): return pf._arm_connections @pytest.mark.timeout(timeout=DEFAULT_TEST_TIMEOUT, method=PYTEST_TIMEOUT_METHOD) @pytest.mark.e2etest @pytest.mark.usefixtures("vcr_recording") class TestArmConnectionOperations: def test_get_connection(self, connection_ops): # Note: Secrets will be returned by arm api result = connection_ops.get(name="azure_open_ai_connection") assert ( result._to_dict().items() > { "api_type": "azure", "module": "promptflow.connections", "name": "azure_open_ai_connection", }.items() ) result = connection_ops.get(name="custom_connection") assert ( result._to_dict().items() > { "name": "custom_connection", "module": "promptflow.connections", "configs": {}, }.items() )
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/e2etests/test_cli.py
import os import os.path import sys from pathlib import Path import pytest from promptflow._cli._pf.entry import main from ..recording_utilities import is_live FLOWS_DIR = "./tests/test_configs/flows" RUNS_DIR = "./tests/test_configs/runs" CONNECTIONS_DIR = "./tests/test_configs/connections" DATAS_DIR = "./tests/test_configs/datas" # TODO: move this to a shared utility module def run_pf_command(*args, cwd=None): """Run a pf command with the given arguments and working directory. There have been some unknown issues in using subprocess on CI, so we use this function instead, which will also provide better debugging experience. """ origin_argv, origin_cwd = sys.argv, os.path.abspath(os.curdir) try: sys.argv = ["pf"] + list(args) if cwd: os.chdir(cwd) main() finally: sys.argv = origin_argv os.chdir(origin_cwd) @pytest.mark.skipif(condition=not is_live(), reason="CLI tests, only run in live mode.") @pytest.mark.cli_test @pytest.mark.e2etest class TestCli: # PF cli test is here because when designate connection provider to remote, we need azure dependencies. def test_pf_flow_test(self, remote_workspace_resource_id): # Test with connection provider run_pf_command( "flow", "test", "--flow", f"{FLOWS_DIR}/web_classification", "--config", f"connection.provider={remote_workspace_resource_id}", ) output_path = Path(FLOWS_DIR) / "web_classification" / ".promptflow" / "flow.output.json" assert output_path.exists() def test_flow_chat(self, monkeypatch, capsys, remote_workspace_resource_id): chat_list = ["hi", "what is chat gpt?"] def mock_input(*args, **kwargs): if chat_list: return chat_list.pop() else: raise KeyboardInterrupt() monkeypatch.setattr("builtins.input", mock_input) run_pf_command( "flow", "test", "--flow", f"{FLOWS_DIR}/chat_flow", "--interactive", "--verbose", "--config", f"connection.provider={remote_workspace_resource_id}", ) output_path = Path(FLOWS_DIR) / "chat_flow" / ".promptflow" / "chat.output.json" assert output_path.exists() detail_path = Path(FLOWS_DIR) / "chat_flow" / ".promptflow" / "chat.detail.json" assert detail_path.exists() outerr = capsys.readouterr() # Check node output assert "chat_node:" in outerr.out assert "show_answer:" in outerr.out assert "[show_answer]: print:" in outerr.out
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_flow_entity.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import shutil import tempfile import uuid from pathlib import Path import pytest from mock.mock import Mock from promptflow._sdk._load_functions import load_run from promptflow._sdk._vendor import get_upload_files_from_folder from promptflow._utils.flow_utils import load_flow_dag from promptflow.azure._constants._flow import ENVIRONMENT, PYTHON_REQUIREMENTS_TXT from promptflow.azure._entities._flow import Flow tests_root_dir = Path(__file__).parent.parent.parent FLOWS_DIR = (tests_root_dir / "test_configs/flows").resolve() RUNS_DIR = (tests_root_dir / "test_configs/runs").resolve() def load_flow(source): from promptflow.azure._load_functions import load_flow return load_flow(source=source) @pytest.mark.unittest class TestFlow: @pytest.mark.skip(reason="TODO: add back when we bring back meta.yaml") def test_load_flow(self): local_file = tests_root_dir / "test_configs/flows/meta_files/flow.meta.yaml" flow = load_flow(source=local_file) assert flow._to_dict() == { "name": "web_classificiation_flow_3", "description": "Create flows that use large language models to classify URLs into multiple categories.", "display_name": "Web Classification", "type": "default", "path": "./flow.dag.yaml", } rest_dict = flow._to_rest_object().as_dict() assert rest_dict == { "description": "Create flows that use large language models to classify URLs into multiple categories.", "flow_name": "Web Classification", "flow_run_settings": {}, "flow_type": "default", "is_archived": True, "flow_definition_file_path": "./flow.dag.yaml", } @pytest.mark.skip(reason="TODO: add back when we bring back meta.yaml") def test_load_flow_from_remote_storage(self): from promptflow.azure.operations._flow_operations import FlowOperations local_file = tests_root_dir / "test_configs/flows/meta_files/remote_fs.meta.yaml" flow = load_flow(source=local_file) assert flow._to_dict() == { "name": "classification_accuracy_eval", "path": "azureml://datastores/workspaceworkingdirectory/paths/Users/wanhan/my_flow_snapshot/flow.dag.yaml", "type": "evaluation", } FlowOperations._try_resolve_code_for_flow(flow, Mock()) rest_dict = flow._to_rest_object().as_dict() assert rest_dict == { "flow_definition_file_path": "Users/wanhan/my_flow_snapshot/flow.dag.yaml", "flow_run_settings": {}, "flow_type": "evaluation", "is_archived": True, } def test_ignore_files_in_flow(self): local_file = tests_root_dir / "test_configs/flows/web_classification" with tempfile.TemporaryDirectory() as temp: flow_path = Path(temp) / "flow" shutil.copytree(local_file, flow_path) assert (Path(temp) / "flow/.promptflow/flow.tools.json").exists() (Path(flow_path) / ".runs").mkdir(parents=True) (Path(flow_path) / ".runs" / "mock.file").touch() flow = load_flow(source=flow_path) with flow._build_code() as code: assert code is not None upload_paths = get_upload_files_from_folder( path=code.path, ignore_file=code._ignore_file, ) flow_files = list(sorted([item[1] for item in upload_paths])) # assert that .runs/mock.file are ignored assert ".runs/mock.file" not in flow_files # Web classification may be executed and include flow.detail.json, flow.logs, flow.outputs.json assert all( file in flow_files for file in [ ".promptflow/flow.tools.json", "classify_with_llm.jinja2", "convert_to_dict.py", "fetch_text_content_from_url.py", "fetch_text_content_from_url_input.jsonl", "flow.dag.yaml", "prepare_examples.py", "samples.json", "summarize_text_content.jinja2", "summarize_text_content__variant_1.jinja2", "webClassification20.csv", ] ) def test_load_yaml_run_with_resources(self): source = f"{RUNS_DIR}/sample_bulk_run_with_resources.yaml" run = load_run(source=source, params_override=[{"name": str(uuid.uuid4())}]) assert run._resources["instance_type"] == "Standard_D2" assert run._resources["idle_time_before_shutdown_minutes"] == 60 def test_flow_with_additional_includes(self): flow_folder = FLOWS_DIR / "web_classification_with_additional_include" flow = load_flow(source=flow_folder) with flow._build_code() as code: assert code is not None _, temp_flow = load_flow_dag(code.path) assert "additional_includes" not in temp_flow upload_paths = get_upload_files_from_folder( path=code.path, ignore_file=code._ignore_file, ) flow_files = list(sorted([item[1] for item in upload_paths])) target_additional_includes = [ "convert_to_dict.py", "fetch_text_content_from_url.py", "summarize_text_content.jinja2", "external_files/convert_to_dict.py", "external_files/fetch_text_content_from_url.py", "external_files/summarize_text_content.jinja2", ] # assert all additional includes are included for file in target_additional_includes: assert file in flow_files def test_flow_with_ignore_file(self): flow_folder = FLOWS_DIR / "flow_with_ignore_file" flow = load_flow(source=flow_folder) with flow._build_code() as code: assert code is not None upload_paths = get_upload_files_from_folder( path=code.path, ignore_file=code._ignore_file, ) flow_files = list(sorted([item[1] for item in upload_paths])) assert len(flow_files) > 0 target_ignored_files = ["ignored_folder/1.txt", "random.ignored"] # assert all ignored files are ignored for file in target_ignored_files: assert file not in flow_files def test_resolve_requirements(self): flow_dag = {} # Test when requirements.txt does not exist assert not Flow._resolve_requirements(flow_path=FLOWS_DIR / "flow_with_ignore_file", flow_dag=flow_dag) # Test when requirements.txt exists but already added to flow_dag flow_dag[ENVIRONMENT] = {PYTHON_REQUIREMENTS_TXT: "another_requirements.txt"} assert not Flow._resolve_requirements(flow_path=FLOWS_DIR / "flow_with_requirements_txt", flow_dag=flow_dag) # Test when requirements.txt exists and not added to flow_dag flow_dag = {} assert Flow._resolve_requirements(flow_path=FLOWS_DIR / "flow_with_requirements_txt", flow_dag=flow_dag) def test_resolve_requirements_for_flow(self): with tempfile.TemporaryDirectory() as temp: temp = Path(temp) # flow without environment section flow_folder = FLOWS_DIR / "flow_with_requirements_txt" shutil.copytree(flow_folder, temp / "flow_with_requirements_txt") flow_folder = temp / "flow_with_requirements_txt" flow = load_flow(source=flow_folder) with flow._build_code(): _, flow_dag = load_flow_dag(flow_path=flow_folder) assert flow_dag[ENVIRONMENT] == {"python_requirements_txt": "requirements.txt"} _, flow_dag = load_flow_dag(flow_path=flow_folder) assert ENVIRONMENT not in flow_dag # flow with environment section flow_folder = FLOWS_DIR / "flow_with_requirements_txt_and_env" shutil.copytree(flow_folder, temp / "flow_with_requirements_txt_and_env") flow_folder = temp / "flow_with_requirements_txt_and_env" flow = load_flow(source=flow_folder) with flow._build_code(): _, flow_dag = load_flow_dag(flow_path=flow_folder) assert flow_dag[ENVIRONMENT] == { "image": "python:3.8-slim", "python_requirements_txt": "requirements.txt", } _, flow_dag = load_flow_dag(flow_path=flow_folder) assert flow_dag[ENVIRONMENT] == {"image": "python:3.8-slim"}
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_run_operations.py
import tempfile import pytest from pytest_mock import MockerFixture from promptflow.azure import PFClient from promptflow.exceptions import UserErrorException @pytest.mark.unittest class TestRunOperations: def test_download_run_with_invalid_workspace_datastore(self, pf: PFClient, mocker: MockerFixture): # test download with invalid workspace datastore mocker.patch.object(pf.runs, "_validate_for_run_download") mocker.patch.object(pf.runs, "_workspace_default_datastore", "test") with tempfile.TemporaryDirectory() as tmp_dir: with pytest.raises(UserErrorException, match="workspace default datastore is not supported"): pf.runs.download(run="fake_run_name", output=tmp_dir)
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_pf_client_azure.py
import pytest from promptflow._sdk._errors import RunOperationParameterError @pytest.mark.unittest class TestPFClientAzure: def test_wrong_client_parameters(self): from promptflow.azure import PFClient # test wrong client parameters with pytest.raises(RunOperationParameterError, match="You have passed in the wrong parameter name"): PFClient( subscription_id="fake_subscription_id", resource_group="fake_resource_group", workspace_name="fake_workspace_name", )
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_flow_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from pathlib import Path from unittest.mock import patch import pytest from promptflow._sdk._errors import FlowOperationError from promptflow.exceptions import UserErrorException tests_root_dir = Path(__file__).parent.parent.parent flow_test_dir = tests_root_dir / "test_configs/flows" data_dir = tests_root_dir / "test_configs/datas" @pytest.mark.unittest class TestFlowOperations: def test_create_flow_with_invalid_parameters(self, pf): with pytest.raises(UserErrorException, match=r"Flow source must be a directory with"): pf.flows.create_or_update(flow="fake_source") flow_source = flow_test_dir / "web_classification/" with pytest.raises(UserErrorException, match="Not a valid string"): pf.flows.create_or_update(flow=flow_source, display_name=False) with pytest.raises(UserErrorException, match="Must be one of: standard, evaluation, chat"): pf.flows.create_or_update(flow=flow_source, type="unknown") with pytest.raises(UserErrorException, match="Not a valid string"): pf.flows.create_or_update(flow=flow_source, description=False) with pytest.raises(UserErrorException, match="Not a valid string"): pf.flows.create_or_update(flow=flow_source, tags={"key": False}) @pytest.mark.usefixtures("enable_logger_propagate") def test_create_flow_with_warnings(self, pf, caplog): flow_source = flow_test_dir / "web_classification/" pf.flows._validate_flow_creation_parameters(source=flow_source, random="random") assert "random: Unknown field" in caplog.text def test_list_flows_invalid_cases(self, pf): with pytest.raises(FlowOperationError, match="'max_results' must be a positive integer"): pf.flows.list(max_results=0) with pytest.raises(FlowOperationError, match="'flow_type' must be one of"): pf.flows.list(flow_type="unknown") with pytest.raises(FlowOperationError, match="Invalid list view type"): pf.flows.list(list_view_type="invalid") def test_get_user_identity_info(self): # we have a fixture "mock_get_user_identity_info" to mock this function during record and replay # as we don't want to deal with token in these modes; meanwhile, considering coverage, add this # unit test to try to cover this code path. import jwt from promptflow.azure._restclient.flow_service_caller import FlowServiceCaller mock_oid, mock_tid = "mock_oid", "mock_tid" def mock_init(*args, **kwargs) -> str: self = args[0] self._credential = None def mock_get_arm_token(*args, **kwargs) -> str: return jwt.encode( payload={ "oid": mock_oid, "tid": mock_tid, }, key="", ) with patch( "promptflow.azure._restclient.flow_service_caller.get_arm_token", new=mock_get_arm_token, ): with patch.object(FlowServiceCaller, "__init__", new=mock_init): service_caller = FlowServiceCaller(workspace=None, credential=None, operation_scope=None) user_object_id, user_tenant_id = service_caller._get_user_identity_info() assert user_object_id == mock_oid assert user_tenant_id == mock_tid
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_arm_connection_build.py
import copy import pytest def build_from_data_and_assert(data, expected): from azure.ai.ml._restclient.v2023_06_01_preview.models import WorkspaceConnectionPropertiesV2BasicResource from promptflow.azure.operations._arm_connection_operations import ArmConnectionOperations data = copy.deepcopy(data) obj = WorkspaceConnectionPropertiesV2BasicResource.deserialize(data) assert ArmConnectionOperations.build_connection_dict_from_rest_object("mock", obj) == expected @pytest.mark.unittest def test_build_azure_openai_connection_from_rest_object(): # Test on ApiKey type with AzureOpenAI category data = { "id": "mock_id", "name": "azure_open_ai_connection", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "ApiKey", "credentials": {"key": "***"}, "category": "AzureOpenAI", "target": "<api-base>", "metadata": { "azureml.flow.connection_type": "AzureOpenAI", "azureml.flow.module": "promptflow.connections", "apiType": "azure", "ApiVersion": "2023-07-01-preview", "ResourceId": "mock_id", }, }, } expected = { "type": "AzureOpenAIConnection", "module": "promptflow.connections", "value": { "api_base": "<api-base>", "api_key": "***", "api_type": "azure", "api_version": "2023-07-01-preview", "resource_id": "mock_id", }, } build_from_data_and_assert(data, expected) @pytest.mark.unittest def test_build_default_azure_openai_connection_missing_metadata(): # Test on ApiKey type with AzureOpenAI category data = { "id": "mock_id", "name": "azure_open_ai_connection", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "ApiKey", "credentials": {"key": "***"}, "category": "AzureOpenAI", "target": "<api-base>", "metadata": { # Missing ApiType and ApiVersion # "ApiType": "azure", # "ApiVersion": "2023-07-01-preview", }, }, } expected = { "type": "AzureOpenAIConnection", "module": "promptflow.connections", "value": { "api_base": "<api-base>", "api_key": "***", # Assert below keys are filtered out # "api_type": None, # "api_version": None, }, } build_from_data_and_assert(data, expected) @pytest.mark.unittest def test_build_custom_keys_connection_from_rest_object(): # Test on CustomKeys type with CustomConnection category data = { "id": "mock_id", "name": "custom_connection", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "CustomKeys", "credentials": {"keys": {"my_key1": "***", "my_key2": "***"}}, "category": "CustomKeys", "target": "<api-base>", "metadata": { "azureml.flow.connection_type": "Custom", "azureml.flow.module": "promptflow.connections", "general_key": "general_value", }, }, } expected = { "type": "CustomConnection", "module": "promptflow.connections", "value": {"my_key1": "***", "my_key2": "***", "general_key": "general_value"}, "secret_keys": ["my_key1", "my_key2"], } build_from_data_and_assert(data, expected) @pytest.mark.unittest def test_build_cognitive_search_connection_from_rest_object(): # Test on ApiKey type with CognitiveSearch category data = { "tags": None, "location": None, "id": "mock_id", "name": "test", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "ApiKey", "credentials": {"key": "***"}, "category": "CognitiveSearch", "expiryTime": None, "target": "mock_target", "metadata": { "azureml.flow.connection_type": "CognitiveSearch", "azureml.flow.module": "promptflow.connections", "ApiVersion": "2023-07-01-Preview", }, }, } expected = { "type": "CognitiveSearchConnection", "module": "promptflow.connections", "value": {"api_key": "***", "api_base": "mock_target", "api_version": "2023-07-01-Preview"}, } build_from_data_and_assert(data, expected) @pytest.mark.unittest def test_build_cognitive_service_category_connection_from_rest_object(): # Test on Api type with CognitiveService category data = { "id": "mock_id", "name": "ACS_Connection", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "ApiKey", "credentials": {"key": "***"}, "category": "CognitiveService", "target": "mock_target", "metadata": { "azureml.flow.connection_type": "AzureContentSafety", "azureml.flow.module": "promptflow.connections", "Kind": "Content Safety", "ApiVersion": "2023-04-30-preview", }, }, } expected = { "type": "AzureContentSafetyConnection", "module": "promptflow.connections", "value": {"api_key": "***", "endpoint": "mock_target", "api_version": "2023-04-30-preview"}, } build_from_data_and_assert(data, expected) # Test category + kind as connection type del data["properties"]["metadata"]["azureml.flow.connection_type"] build_from_data_and_assert(data, expected) @pytest.mark.unittest def test_build_connection_missing_metadata(): data = { "id": "mock_id", "name": "ACS_Connection", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "ApiKey", "credentials": {"key": "***"}, "category": "CognitiveService", "target": "mock_target", "metadata": { "ApiVersion": "2023-04-30-preview", }, }, } with pytest.raises(Exception) as e: build_from_data_and_assert(data, {}) assert "is not recognized in PromptFlow" in str(e.value) @pytest.mark.unittest def test_build_connection_unknown_category(): data = { "id": "mock_id", "name": "ACS_Connection", "type": "Microsoft.MachineLearningServices/workspaces/connections", "properties": { "authType": "ApiKey", "credentials": {"key": "***"}, "category": "Unknown", "target": "mock_target", "metadata": { "azureml.flow.connection_type": "AzureContentSafety", "azureml.flow.module": "promptflow.connections", "Kind": "Content Safety", "ApiVersion": "2023-04-30-preview", }, }, } with pytest.raises(Exception) as e: build_from_data_and_assert(data, {}) assert "Unknown connection mock category Unknown" in str(e.value)
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_pf_client.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import mock import pytest from promptflow import PFClient from promptflow._sdk.operations._connection_operations import ConnectionOperations from promptflow._sdk.operations._local_azure_connection_operations import LocalAzureConnectionOperations from promptflow.exceptions import UserErrorException from ..recording_utilities import is_live AZUREML_RESOURCE_PROVIDER = "Microsoft.MachineLearningServices" RESOURCE_ID_FORMAT = "/subscriptions/{}/resourceGroups/{}/providers/{}/workspaces/{}" @pytest.mark.sdk_test @pytest.mark.e2etest class TestPFClient: # Test pf client when connection provider is azureml. # This tests suites need azure dependencies. @pytest.mark.skipif(condition=not is_live(), reason="This test requires an actual PFClient") def test_connection_provider(self, subscription_id: str, resource_group_name: str, workspace_name: str): target = "promptflow._sdk._pf_client.Configuration" with mock.patch(target) as mocked: mocked.return_value.get_connection_provider.return_value = "abc" with pytest.raises(UserErrorException) as e: client = PFClient() assert client.connections assert "Unsupported connection provider" in str(e.value) with mock.patch(target) as mocked: mocked.return_value.get_connection_provider.return_value = "azureml:xx" with pytest.raises(ValueError) as e: client = PFClient() assert client.connections assert "Malformed connection provider string" in str(e.value) with mock.patch(target) as mocked: mocked.return_value.get_connection_provider.return_value = "local" client = PFClient() assert isinstance(client.connections, ConnectionOperations) with mock.patch(target) as mocked: mocked.return_value.get_connection_provider.return_value = "azureml:" + RESOURCE_ID_FORMAT.format( subscription_id, resource_group_name, AZUREML_RESOURCE_PROVIDER, workspace_name ) client = PFClient() assert isinstance(client.connections, LocalAzureConnectionOperations) client = PFClient( config={ "connection.provider": "azureml:" + RESOURCE_ID_FORMAT.format( subscription_id, resource_group_name, AZUREML_RESOURCE_PROVIDER, workspace_name ) } ) assert isinstance(client.connections, LocalAzureConnectionOperations) def test_local_azure_connection_extract_workspace(self): res = LocalAzureConnectionOperations._extract_workspace( "azureml://subscriptions/123/resourceGroups/456/providers/Microsoft.MachineLearningServices/workspaces/789" ) assert res == ("123", "456", "789") res = LocalAzureConnectionOperations._extract_workspace( "azureml://subscriptions/123/resourcegroups/456/workspaces/789" ) assert res == ("123", "456", "789") with pytest.raises(ValueError) as e: LocalAzureConnectionOperations._extract_workspace("azureml:xx") assert "Malformed connection provider string" in str(e.value) with pytest.raises(ValueError) as e: LocalAzureConnectionOperations._extract_workspace( "azureml://subscriptions/123/resourceGroups/456/providers/Microsoft.MachineLearningServices/workspaces/" ) assert "Malformed connection provider string" in str(e.value)
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_run_entity.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import shutil from pathlib import Path from tempfile import TemporaryDirectory from unittest.mock import Mock import pytest from promptflow._sdk.entities import Run from promptflow._utils.flow_utils import get_flow_lineage_id from promptflow.exceptions import UserErrorException PROMOTFLOW_ROOT = Path(__file__) / "../../../.." TEST_ROOT = Path(__file__).parent.parent.parent MODEL_ROOT = TEST_ROOT / "test_configs/e2e_samples" CONNECTION_FILE = (PROMOTFLOW_ROOT / "connections.json").resolve().absolute().as_posix() FLOWS_DIR = "./tests/test_configs/flows" RUNS_DIR = "./tests/test_configs/runs" DATAS_DIR = "./tests/test_configs/datas" @pytest.mark.unittest class TestRun: def test_input_mapping_types(self, pf): data_path = f"{DATAS_DIR}/webClassification3.jsonl" flow_path = Path(f"{FLOWS_DIR}/flow_with_dict_input") # run with dict inputs run = Run( flow=flow_path, data=data_path, column_mapping=dict(key={"a": 1}), ) rest_run = run._to_rest_object() assert rest_run.inputs_mapping == {"key": '{"a": 1}'} # run with list inputs run = Run( flow=flow_path, data=data_path, column_mapping=dict(key=["a", "b"]), ) rest_run = run._to_rest_object() assert rest_run.inputs_mapping == {"key": '["a", "b"]'} # unsupported inputs run = Run( flow=flow_path, data=data_path, column_mapping=dict(key=Mock()), ) with pytest.raises(UserErrorException): run._to_rest_object() run = Run(flow=flow_path, data=data_path, column_mapping="str") with pytest.raises(UserErrorException): run._to_rest_object() def test_flow_id(self): # same flow id for same flow in same GIT repo flow_path = Path(f"{FLOWS_DIR}/flow_with_dict_input") # run with dict inputs session_id1 = get_flow_lineage_id(flow_path) session_id2 = get_flow_lineage_id(flow_path) assert session_id1 == session_id2 # same flow id for same flow in same device with TemporaryDirectory() as tmp_dir: shutil.copytree(f"{FLOWS_DIR}/flow_with_dict_input", f"{tmp_dir}/flow_with_dict_input") session_id3 = get_flow_lineage_id(f"{tmp_dir}/flow_with_dict_input") session_id4 = get_flow_lineage_id(f"{tmp_dir}/flow_with_dict_input") assert session_id3 == session_id4 assert session_id3 != session_id1
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_azure_cli_activity_name.py
import pytest from promptflow._cli._pf_azure.entry import get_parser_args from promptflow._cli._utils import _get_cli_activity_name def get_cli_activity_name(cmd): prog, args = get_parser_args(list(cmd)[1:]) return _get_cli_activity_name(cli=prog, args=args) @pytest.mark.unittest class TestAzureCliTimeConsume: def test_pfazure_run_create(self, activity_name="pfazure.run.create"): assert ( get_cli_activity_name( cmd=("pfazure", "run", "create", "--flow", "print_input_flow", "--data", "print_input_flow.jsonl") ) == activity_name ) def test_pfazure_run_update(self, activity_name="pfazure.run.update"): assert ( get_cli_activity_name( cmd=( "pfazure", "run", "update", "--name", "test_run", "--set", "display_name=test_run", "description='test_description'", "tags.key1=value1", ) ) == activity_name ) def test_run_restore(self, activity_name="pfazure.run.restore"): assert get_cli_activity_name(cmd=("pfazure", "run", "restore", "--name", "test_run")) == activity_name
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_utils.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from unittest.mock import MagicMock import pytest from promptflow.exceptions import UserErrorException @pytest.mark.unittest class TestUtils: def test_url_parse(self): from promptflow.azure._utils._url_utils import BulkRunId, BulkRunURL flow_id = ( "azureml://experiment/3e123da1-f9a5-4c91-9234-8d9ffbb39ff5/flow/" "0ab9d2dd-3bac-4b68-bb28-12af959b1165/bulktest/715efeaf-b0b4-4778-b94a-2538152b8766/" "run/f88faee6-e510-45b7-9e63-08671b30b3a2" ) flow_id = BulkRunId(flow_id) assert flow_id.experiment_id == "3e123da1-f9a5-4c91-9234-8d9ffbb39ff5" assert flow_id.flow_id == "0ab9d2dd-3bac-4b68-bb28-12af959b1165" assert flow_id.bulk_test_id == "715efeaf-b0b4-4778-b94a-2538152b8766" flow_run_url = ( "https://ml.azure.com/prompts/flow/3e123da1-f9a5-4c91-9234-8d9ffbb39ff5/" "0ab9d2dd-3bac-4b68-bb28-12af959b1165/bulktest/715efeaf-b0b4-4778-b94a-2538152b8766/" "details?wsid=/subscriptions/96aede12-2f73-41cb-b983-6d11a904839b/resourcegroups/promptflow/" "providers/Microsoft.MachineLearningServices/workspaces/promptflow-eastus" ) flow_url = BulkRunURL(flow_run_url) assert flow_url.experiment_id == "3e123da1-f9a5-4c91-9234-8d9ffbb39ff5" assert flow_url.flow_id == "0ab9d2dd-3bac-4b68-bb28-12af959b1165" assert flow_url.bulk_test_id == "715efeaf-b0b4-4778-b94a-2538152b8766" def test_forbidden_new_caller(self): from promptflow.azure._restclient.flow_service_caller import FlowServiceCaller with pytest.raises(UserErrorException) as e: FlowServiceCaller(MagicMock(), MagicMock(), MagicMock()) assert "_FlowServiceCallerFactory" in str(e.value)
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_cli.py
import contextlib import os import sys from pathlib import Path from typing import List from unittest.mock import MagicMock, patch import pandas as pd import pytest from pytest_mock import MockFixture from promptflow._sdk._constants import VIS_PORTAL_URL_TMPL tests_root_dir = Path(__file__).parent.parent.parent flow_test_dir = tests_root_dir / "test_configs/flows" data_dir = tests_root_dir / "test_configs/datas" def run_pf_command(*args, cwd=None): from promptflow._cli._pf_azure.entry import main origin_argv, origin_cwd = sys.argv, os.path.abspath(os.curdir) try: sys.argv = ["pfazure"] + list(args) if cwd: os.chdir(cwd) main() finally: sys.argv = origin_argv os.chdir(origin_cwd) @pytest.fixture def operation_scope_args(subscription_id: str, resource_group_name: str, workspace_name: str): return [ "--subscription", subscription_id, "--resource-group", resource_group_name, "--workspace-name", workspace_name, ] @pytest.mark.usefixtures("mock_get_azure_pf_client") @pytest.mark.unittest class TestAzureCli: def test_pf_azure_version(self, capfd): run_pf_command("--version") out, err = capfd.readouterr() assert "0.0.1\n" in out def test_run_show(self, mocker: MockFixture, operation_scope_args): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "get") # show_run will print the run object, so we need to mock the return value mocked.return_value._to_dict.return_value = {"name": "test_run"} run_pf_command( "run", "show", "--name", "test_run", *operation_scope_args, ) mocked.assert_called_once() def test_run_show_details(self, mocker: MockFixture, operation_scope_args): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "get_details") # show_run_details will print details, so we need to mock the return value mocked.return_value = pd.DataFrame([{"input": "input_value", "output": "output_value"}]) run_pf_command( "run", "show-details", "--name", "test_run", "--max-results", "10", "--all-results", *operation_scope_args, ) mocked.assert_called_once() def test_run_show_metrics(self, mocker: MockFixture, operation_scope_args): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "get_metrics") # show_metrics will print the metrics, so we need to mock the return value mocked.return_value = {"accuracy": 0.9} run_pf_command( "run", "show-metrics", "--name", "test_run", *operation_scope_args, ) mocked.assert_called_once() def test_run_list_runs( self, mocker: MockFixture, operation_scope_args, subscription_id: str, resource_group_name: str, workspace_name: str, ): from promptflow.azure.operations._run_operations import RunOperations mocked_run = MagicMock() mocked_run._to_dict.return_value = {"name": "test_run"} mocked = mocker.patch.object(RunOperations, "list") # list_runs will print the run list, so we need to mock the return value mocked.return_value = [mocked_run] run_pf_command( "run", "list", "--max-results", "10", "--include-archived", *operation_scope_args, ) run_pf_command( "run", "list", "--max-results", "10", "--include-archived", "--output", "table", *operation_scope_args, ) mocker.patch.dict( os.environ, { "AZUREML_ARM_WORKSPACE_NAME": workspace_name, "AZUREML_ARM_SUBSCRIPTION": subscription_id, "AZUREML_ARM_RESOURCEGROUP": resource_group_name, }, ) run_pf_command( "run", "list", "--max-results", "10", "--include-archived", ) assert mocked.call_count == 3 def test_run_visualize( self, operation_scope_args: List[str], capfd: pytest.CaptureFixture, subscription_id: str, resource_group_name: str, workspace_name: str, ) -> None: # cloud version visualize is actually a string concatenation names = "name1,name2,name3" run_pf_command( "run", "visualize", "--names", names, *operation_scope_args, ) captured = capfd.readouterr() expected_portal_url = VIS_PORTAL_URL_TMPL.format( subscription_id=subscription_id, resource_group_name=resource_group_name, workspace_name=workspace_name, names=names, ) assert expected_portal_url in captured.out def test_run_archive( self, mocker: MockFixture, operation_scope_args, ): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "archive") mocked.return_value._to_dict.return_value = {"name": "test_run"} run_pf_command( "run", "archive", "--name", "test_run", *operation_scope_args, ) mocked.assert_called_once() def test_run_restore( self, mocker: MockFixture, operation_scope_args, ): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "restore") mocked.return_value._to_dict.return_value = {"name": "test_run"} run_pf_command( "run", "restore", "--name", "test_run", *operation_scope_args, ) mocked.assert_called_once() def test_run_update( self, mocker: MockFixture, operation_scope_args, ): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "update") mocked.return_value._to_dict.return_value = {"name": "test_run"} run_pf_command( "run", "update", "--name", "test_run", "--set", "display_name=test_run", "description='test_description'", "tags.key1=value1", *operation_scope_args, ) mocked.assert_called_once() def test_flow_create( self, mocker: MockFixture, operation_scope_args, ): from promptflow.azure.operations._flow_operations import FlowOperations mocked = mocker.patch.object(FlowOperations, "create_or_update") mocked.return_value._to_dict.return_value = {"name": "test_run"} flow_dir = Path(flow_test_dir, "web_classification").resolve().as_posix() run_pf_command( "flow", "create", "--flow", flow_dir, "--set", "display_name=test_flow", "type=standard", "description='test_description'", "tags.key1=value1", *operation_scope_args, ) mocked.assert_called_with( flow=flow_dir, display_name="test_flow", type="standard", description="test_description", tags={"key1": "value1"}, ) def test_flow_create_with_unknown_field(self, mocker: MockFixture, operation_scope_args): from promptflow.azure.operations._flow_operations import FlowOperations mocked = mocker.patch.object(FlowOperations, "create_or_update") mocked.return_value._to_dict.return_value = {"name": "test_run"} flow_dir = Path(flow_test_dir, "web_classification").resolve().as_posix() run_pf_command( "flow", "create", "--flow", flow_dir, "--set", "random_key=random_value", *operation_scope_args, ) mocked.assert_called_with(flow=flow_dir, random_key="random_value") def test_flow_list( self, mocker: MockFixture, operation_scope_args, ): from promptflow.azure.operations._flow_operations import FlowOperations mocked_flow = MagicMock() mocked_flow._to_dict.return_value = {"name": "test_flow"} mocked = mocker.patch.object(FlowOperations, "list") mocked.return_value = [mocked_flow] run_pf_command( "flow", "list", "--max-results", "10", "--include-archived", "--type", "standard", "--include-others", "--output", "table", *operation_scope_args, ) mocked.assert_called_once() def test_run_telemetry( self, mocker: MockFixture, operation_scope_args, subscription_id: str, resource_group_name: str, workspace_name: str, ): from promptflow.azure.operations._run_operations import RunOperations mocked_run = MagicMock() mocked_run._to_dict.return_value = {"name": "test_run"} mocked = mocker.patch.object(RunOperations, "list") # list_runs will print the run list, so we need to mock the return value mocked.return_value = [mocked_run] mocker.patch.dict( os.environ, { "AZUREML_ARM_WORKSPACE_NAME": workspace_name, "AZUREML_ARM_SUBSCRIPTION": subscription_id, "AZUREML_ARM_RESOURCEGROUP": resource_group_name, }, ) @contextlib.contextmanager def check_workspace_info(*args, **kwargs): if "custom_dimensions" in kwargs: assert kwargs["custom_dimensions"]["workspace_name"] == workspace_name assert kwargs["custom_dimensions"]["resource_group_name"] == resource_group_name assert kwargs["custom_dimensions"]["subscription_id"] == subscription_id yield None with patch("promptflow._sdk._telemetry.activity.log_activity") as mock_log_activity: mock_log_activity.side_effect = check_workspace_info run_pf_command( "run", "list", "--max-results", "10", "--include-archived", *operation_scope_args, ) def test_run_download(self, mocker: MockFixture, operation_scope_args): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "download") mocked.return_value = "fake_output_run_dir" run_pf_command( "run", "download", "--name", "test_run", "--output", "fake_output_dir", "--overwrite", *operation_scope_args, ) mocked.assert_called_once() def test_run_cancel(self, mocker: MockFixture, operation_scope_args): from promptflow.azure.operations._run_operations import RunOperations mocked = mocker.patch.object(RunOperations, "cancel") run_pf_command( "run", "cancel", "--name", "test_run", *operation_scope_args, ) mocked.assert_called_once()
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/unittests/test_config.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from pathlib import Path import pytest from promptflow._sdk._configuration import ConfigFileNotFound, Configuration, InvalidConfigFile from promptflow._utils.context_utils import _change_working_dir AZUREML_RESOURCE_PROVIDER = "Microsoft.MachineLearningServices" RESOURCE_ID_FORMAT = "/subscriptions/{}/resourceGroups/{}/providers/{}/workspaces/{}" CONFIG_DATA_ROOT = Path(__file__).parent.parent.parent / "test_configs" / "configs" @pytest.fixture def config(): return Configuration.get_instance() @pytest.mark.unittest class TestConfig: def test_get_workspace_from_config(self): # New instance instead of get_instance() to avoid side effect conf = Configuration(overrides={"connection.provider": "azureml"}) # Test config within flow folder target_folder = CONFIG_DATA_ROOT / "mock_flow1" with _change_working_dir(target_folder): config1 = conf.get_connection_provider() assert config1 == "azureml:" + RESOURCE_ID_FORMAT.format("sub1", "rg1", AZUREML_RESOURCE_PROVIDER, "ws1") # Test config using flow parent folder target_folder = CONFIG_DATA_ROOT / "mock_flow2" with _change_working_dir(target_folder): config2 = conf.get_connection_provider() assert config2 == "azureml:" + RESOURCE_ID_FORMAT.format( "sub_default", "rg_default", AZUREML_RESOURCE_PROVIDER, "ws_default" ) # Test config not found with pytest.raises(ConfigFileNotFound): Configuration._get_workspace_from_config(path=CONFIG_DATA_ROOT.parent) # Test empty config target_folder = CONFIG_DATA_ROOT / "mock_flow_empty_config" with pytest.raises(InvalidConfigFile): with _change_working_dir(target_folder): conf.get_connection_provider()
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/recording_utilities/constants.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- ENVIRON_TEST_MODE = "PROMPT_FLOW_TEST_MODE" class TestMode: LIVE = "live" RECORD = "record" REPLAY = "replay" FILTER_HEADERS = [ "aml-user-token", "authorization", "date", "etag", "request-context", "x-aml-cluster", "x-ms-access-tier", "x-ms-access-tier-inferred", "x-ms-client-request-id", "x-ms-client-session-id", "x-ms-client-user-type", "x-ms-correlation-request-id", "x-ms-file-permission-key", "x-ms-lease-state", "x-ms-lease-status", "x-ms-server-encrypted", "x-ms-ratelimit-remaining-subscription-reads", "x-ms-ratelimit-remaining-subscription-writes", "x-ms-response-type", "x-ms-request-id", "x-ms-routing-request-id", "x-msedge-ref", ] class SanitizedValues: UUID = "00000000-0000-0000-0000-000000000000" SUBSCRIPTION_ID = "00000000-0000-0000-0000-000000000000" RESOURCE_GROUP_NAME = "00000" WORKSPACE_NAME = "00000" WORKSPACE_ID = "00000000-0000-0000-0000-000000000000" TENANT_ID = "00000000-0000-0000-0000-000000000000" USER_OBJECT_ID = "00000000-0000-0000-0000-000000000000" # workspace DISCOVERY_URL = "https://eastus.api.azureml.ms/discovery" # datastore FAKE_KEY = "this is fake key" FAKE_ACCOUNT_NAME = "fake_account_name" FAKE_CONTAINER_NAME = "fake-container-name" FAKE_FILE_SHARE_NAME = "fake-file-share-name" # aoai connection FAKE_API_BASE = "https://fake.openai.azure.com" # storage UPLOAD_HASH = "000000000000000000000000000000000000" BLOB_STORAGE_REQUEST_HOST = "fake_account_name.blob.core.windows.net" FILE_SHARE_REQUEST_HOST = "fake_account_name.file.core.windows.net" # PFS RUNTIME_NAME = "fake-runtime-name" SESSION_ID = "000000000000000000000000000000000000000000000000" FLOW_LINEAGE_ID = "0000000000000000000000000000000000000000000000000000000000000000" REGION = "fake-region" FLOW_ID = "00000000-0000-0000-0000-000000000000" # trick: "unknown_user" is the value when client fails to get username # use this value so that we don't do extra logic when replay USERNAME = "unknown_user" # MISC EMAIL_USERNAME = "username" class AzureMLResourceTypes: CONNECTION = "Microsoft.MachineLearningServices/workspaces/connections" DATASTORE = "Microsoft.MachineLearningServices/workspaces/datastores" WORKSPACE = "Microsoft.MachineLearningServices/workspaces" TEST_CLASSES_FOR_RUN_INTEGRATION_TEST_RECORDING = [ "TestCliWithAzure", "TestFlowRun", "TestFlow", "TestTelemetry", "TestAzureCliPerf", ]
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/recording_utilities/utils.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json import os import re from dataclasses import dataclass from typing import Dict import jwt from azure.core.credentials import AccessToken from vcr.request import Request from .constants import ENVIRON_TEST_MODE, SanitizedValues, TestMode def get_test_mode_from_environ() -> str: return os.getenv(ENVIRON_TEST_MODE, TestMode.LIVE) def is_live() -> bool: return get_test_mode_from_environ() == TestMode.LIVE def is_record() -> bool: return get_test_mode_from_environ() == TestMode.RECORD def is_replay() -> bool: return get_test_mode_from_environ() == TestMode.REPLAY class FakeTokenCredential: """Refer from Azure SDK for Python repository. https://github.com/Azure/azure-sdk-for-python/blob/main/tools/azure-sdk-tools/devtools_testutils/fake_credentials.py """ def __init__(self): token = jwt.encode( payload={ "aud": "https://management.azure.com", }, key="", ) self.token = AccessToken(token, 0) self.get_token_count = 0 def get_token(self, *args, **kwargs) -> AccessToken: self.get_token_count += 1 return self.token @dataclass class MockDatastore: """Mock Datastore class for `DatastoreOperations.get_default().name`.""" name: str account_name: str container_name: str endpoint: str def mock_datastore_get_default(*args, **kwargs) -> MockDatastore: return MockDatastore( name="workspaceblobstore", account_name=SanitizedValues.FAKE_ACCOUNT_NAME, container_name=SanitizedValues.FAKE_CONTAINER_NAME, endpoint="core.windows.net", ) def mock_workspace_get(*args, **kwargs): from azure.ai.ml.entities import Workspace return Workspace( name=SanitizedValues.WORKSPACE_NAME, resource_group=SanitizedValues.RESOURCE_GROUP_NAME, discovery_url=SanitizedValues.DISCOVERY_URL, workspace_id=SanitizedValues.WORKSPACE_ID, ) def get_pf_client_for_replay(): from azure.ai.ml import MLClient from promptflow.azure import PFClient ml_client = MLClient( credential=FakeTokenCredential(), subscription_id=SanitizedValues.SUBSCRIPTION_ID, resource_group_name=SanitizedValues.RESOURCE_GROUP_NAME, workspace_name=SanitizedValues.WORKSPACE_NAME, ) ml_client.datastores.get_default = mock_datastore_get_default ml_client.workspaces.get = mock_workspace_get return PFClient(ml_client=ml_client) def sanitize_azure_workspace_triad(value: str) -> str: sanitized_sub = re.sub( "/(subscriptions)/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}", r"/\1/{}".format("00000000-0000-0000-0000-000000000000"), value, flags=re.IGNORECASE, ) # for regex pattern for resource group name and workspace name, refer from: # https://learn.microsoft.com/en-us/rest/api/resources/resource-groups/create-or-update?tabs=HTTP sanitized_rg = re.sub( r"/(resourceGroups)/[-\w\._\(\)]+", r"/\1/{}".format("00000"), sanitized_sub, flags=re.IGNORECASE, ) sanitized_ws = re.sub( r"/(workspaces)/[-\w\._\(\)]+[/?]", r"/\1/{}/".format("00000"), sanitized_rg, flags=re.IGNORECASE, ) # workspace name can be the last part of the string # e.g. xxx/Microsoft.MachineLearningServices/workspaces/<workspace-name> # apply a special handle here to sanitize if sanitized_ws.startswith("https://"): split1, split2 = sanitized_ws.split("/")[-2:] if split1 == "workspaces": sanitized_ws = sanitized_ws.replace(split2, SanitizedValues.WORKSPACE_NAME) return sanitized_ws def sanitize_experiment_id(value: str) -> str: value = re.sub( r"(experimentId)=[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}", r"\1={}".format(SanitizedValues.WORKSPACE_ID), value, flags=re.IGNORECASE, ) return value def sanitize_upload_hash(value: str) -> str: value = re.sub( r"(az-ml-artifacts)/([0-9a-f]{32})", r"\1/{}".format(SanitizedValues.UPLOAD_HASH), value, flags=re.IGNORECASE, ) value = re.sub( r"(LocalUpload)/([0-9a-f]{32})", r"\1/{}".format(SanitizedValues.UPLOAD_HASH), value, flags=re.IGNORECASE, ) return value def sanitize_username(value: str) -> str: value = re.sub( r"/(Users%2F)([^%?]+)(%2F|\?)", r"/\1{}\3".format(SanitizedValues.USERNAME), value, flags=re.IGNORECASE, ) value = re.sub( r"(Users/)([^/]+)(/)", r"\1{}\3".format(SanitizedValues.USERNAME), value, flags=re.IGNORECASE, ) return value def sanitize_flow_asset_id(value: str) -> str: # input: azureml://locations/<region>/workspaces/<workspace-id>/flows/<flow-id> # sanitize those with angle brackets sanitized_region = re.sub( r"/(locations)/[^/]+", r"/\1/{}".format(SanitizedValues.REGION), value, flags=re.IGNORECASE, ) sanitized_workspace_id = re.sub( r"/(workspaces)/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}", r"/\1/{}".format(SanitizedValues.WORKSPACE_ID), sanitized_region, flags=re.IGNORECASE, ) sanitized_flow_id = re.sub( r"/(flows)/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}", r"/\1/{}/".format(SanitizedValues.FLOW_ID), sanitized_workspace_id, flags=re.IGNORECASE, ) return sanitized_flow_id def sanitize_pfs_request_body(body: str) -> str: # sanitize workspace triad for longhand syntax asset, e.g. "batchDataInput.dataUri" body = sanitize_azure_workspace_triad(body) body_dict = json.loads(body) # /BulkRuns/submit if "runtimeName" in body_dict: body_dict["runtimeName"] = SanitizedValues.RUNTIME_NAME if "sessionId" in body_dict: body_dict["sessionId"] = SanitizedValues.SESSION_ID if "flowLineageId" in body: body_dict["flowLineageId"] = SanitizedValues.FLOW_LINEAGE_ID if "flowDefinitionResourceId" in body_dict: body_dict["flowDefinitionResourceId"] = sanitize_flow_asset_id(body_dict["flowDefinitionResourceId"]) # PFS will help handle this field, so client does not need to pass this value if "runExperimentName" in body: body_dict["runExperimentName"] = "" return json.dumps(body_dict) def sanitize_pfs_response_body(body: str) -> str: body_dict = json.loads(body) # BulkRuns/{flowRunId} if "studioPortalEndpoint" in body: body_dict["studioPortalEndpoint"] = sanitize_azure_workspace_triad(body_dict["studioPortalEndpoint"]) return json.dumps(body_dict) def sanitize_email(value: str) -> str: return re.sub(r"([\w\.-]+)@(microsoft.com)", r"{}@\2".format(SanitizedValues.EMAIL_USERNAME), value) def sanitize_file_share_flow_path(value: str) -> str: flow_folder_name = "simple_hello_world" if flow_folder_name not in value: return value start_index = value.index(flow_folder_name) flow_name_length = 38 # len("simple_hello_world-01-01-2024-00-00-00") flow_name = value[start_index : start_index + flow_name_length] return value.replace(flow_name, "flow_name") def _sanitize_session_id_creating_automatic_runtime(value: str) -> str: value = re.sub( "/(FlowSessions)/[0-9a-f]{48}", r"/\1/{}".format(SanitizedValues.SESSION_ID), value, flags=re.IGNORECASE, ) return value def _sanitize_operation_id_polling_automatic_runtime(value: str) -> str: value = re.sub( "/(operations)/[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}", r"/\1/{}".format(SanitizedValues.UUID), value, flags=re.IGNORECASE, ) return value def sanitize_automatic_runtime_request_path(value: str) -> str: return _sanitize_operation_id_polling_automatic_runtime(_sanitize_session_id_creating_automatic_runtime(value)) def _is_json_payload(headers: Dict, key: str) -> bool: if not headers: return False content_type = headers.get(key) if not content_type: return False # content-type can be an array, e.g. ["application/json; charset=utf-8"] content_type = content_type[0] if isinstance(content_type, list) else content_type content_type = content_type.split(";")[0].lower() return "application/json" in content_type def is_json_payload_request(request: Request) -> bool: headers = request.headers return _is_json_payload(headers, key="Content-Type") def is_json_payload_response(response: Dict) -> bool: headers = response.get("headers") # PFAzureIntegrationTestRecording will lower keys in response headers return _is_json_payload(headers, key="content-type") def is_httpx_response(response: Dict) -> bool: # different from other stubs in vcrpy, httpx response uses "content" instead of "body" # this leads to different handle logic to response # so we need a utility to check if a response is from httpx return "content" in response def get_created_flow_name_from_flow_path(flow_path: str) -> str: # pytest fixture "created_flow" will create flow on file share with timestamp as suffix # we need to extract the flow name from the path # flow name is expected to start with "simple_hello_world" and follow with "/flow.dag.yaml" return flow_path[flow_path.index("simple_hello_world") : flow_path.index("/flow.dag.yaml")]
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/recording_utilities/bases.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy import inspect import json from pathlib import Path from typing import Dict, List import vcr from vcr import matchers from vcr.request import Request from .constants import FILTER_HEADERS, TEST_CLASSES_FOR_RUN_INTEGRATION_TEST_RECORDING, SanitizedValues from .processors import ( AzureMLExperimentIDProcessor, AzureOpenAIConnectionProcessor, AzureResourceProcessor, AzureWorkspaceTriadProcessor, DropProcessor, EmailProcessor, IndexServiceProcessor, PFSProcessor, RecordingProcessor, StorageProcessor, UserInfoProcessor, ) from .utils import ( is_httpx_response, is_json_payload_request, is_live, is_record, is_replay, sanitize_automatic_runtime_request_path, sanitize_azure_workspace_triad, sanitize_file_share_flow_path, sanitize_pfs_request_body, sanitize_upload_hash, ) from .variable_recorder import VariableRecorder class PFAzureIntegrationTestRecording: def __init__( self, test_class, test_func_name: str, user_object_id: str, tenant_id: str, variable_recorder: VariableRecorder, ): self.test_class = test_class self.test_func_name = test_func_name self.user_object_id = user_object_id self.tenant_id = tenant_id self.recording_file = self._get_recording_file() self.recording_processors = self._get_recording_processors() self.vcr = self._init_vcr() self._cm = None # context manager from VCR self.cassette = None self.variable_recorder = variable_recorder @staticmethod def from_test_case(test_class, test_func_name: str, **kwargs) -> "PFAzureIntegrationTestRecording": test_class_name = test_class.__name__ if test_class_name in TEST_CLASSES_FOR_RUN_INTEGRATION_TEST_RECORDING: return PFAzureRunIntegrationTestRecording( test_class=test_class, test_func_name=test_func_name, user_object_id=kwargs["user_object_id"], tenant_id=kwargs["tenant_id"], variable_recorder=kwargs["variable_recorder"], ) else: return PFAzureIntegrationTestRecording( test_class=test_class, test_func_name=test_func_name, user_object_id=kwargs["user_object_id"], tenant_id=kwargs["tenant_id"], variable_recorder=kwargs["variable_recorder"], ) def _get_recording_file(self) -> Path: # recording files are expected to be located at "tests/test_configs/recordings" # test file path should locate at "tests/sdk_cli_azure_test/e2etests" test_file_path = Path(inspect.getfile(self.test_class)).resolve() recording_dir = (test_file_path.parent.parent.parent / "test_configs" / "recordings").resolve() recording_dir.mkdir(exist_ok=True) test_file_name = test_file_path.stem test_class_name = self.test_class.__name__ if "[" in self.test_func_name: # for tests that use pytest.mark.parametrize, there will be "[]" in test function name # recording filename pattern: # {test_file_name}_{test_class_name}_{test_func_name}/{parameter_id}.yaml test_func_name, parameter_id = self.test_func_name.split("[") parameter_id = parameter_id.rstrip("]") test_func_dir = (recording_dir / f"{test_file_name}_{test_class_name}_{test_func_name}").resolve() test_func_dir.mkdir(exist_ok=True) recording_file = (test_func_dir / f"{parameter_id}.yaml").resolve() else: # for most remaining tests # recording filename pattern: {test_file_name}_{test_class_name}_{test_func_name}.yaml recording_filename = f"{test_file_name}_{test_class_name}_{self.test_func_name}.yaml" recording_file = (recording_dir / recording_filename).resolve() if is_record() and recording_file.is_file(): recording_file.unlink() return recording_file def _init_vcr(self) -> vcr.VCR: _vcr = vcr.VCR( cassette_library_dir=self.recording_file.parent.as_posix(), before_record_request=self._process_request_recording, before_record_response=self._process_response_recording, decode_compressed_response=True, record_mode="none" if is_replay() else "all", filter_headers=FILTER_HEADERS, ) _vcr.match_on += ("body",) return _vcr def enter_vcr(self): self._cm = self.vcr.use_cassette(self.recording_file.as_posix()) self.cassette = self._cm.__enter__() def exit_vcr(self): if is_record(): self._postprocess_recording() self._cm.__exit__() def _process_request_recording(self, request: Request) -> Request: if is_live(): return request if is_record(): for processor in self.recording_processors: request = processor.process_request(request) return request def _process_response_recording(self, response: Dict) -> Dict: if is_live(): return response # httpx and non-httpx responses have different structure # non-httpx has .body.string, while httpx has .content # in our sanitizers (processors) logic, we only handle .body.string # so make httpx align non-httpx for less code change is_httpx = is_httpx_response(response) if is_httpx: body_string = response.pop("content") response["body"] = {"string": body_string} else: response["body"]["string"] = response["body"]["string"].decode("utf-8") if is_record(): # lower and filter some headers headers = {} for k in response["headers"]: if k.lower() not in FILTER_HEADERS: headers[k.lower()] = response["headers"][k] response["headers"] = headers for processor in self.recording_processors: response = processor.process_response(response) if is_httpx: response["content"] = response["body"]["string"] if not is_replay(): response.pop("body") if isinstance(response["content"], bytes): response["content"] = response["content"].decode("utf-8") else: # vcrpy does not handle well with httpx, so we need some transformations # otherwise, replay tests will break during init VCR response instance response["status"] = {"code": response["status_code"], "message": ""} if isinstance(response["body"]["string"], str): response["body"]["string"] = response["body"]["string"].encode("utf-8") else: response["body"]["string"] = response["body"]["string"].encode("utf-8") return response def _get_recording_processors(self) -> List[RecordingProcessor]: return [ AzureMLExperimentIDProcessor(), AzureOpenAIConnectionProcessor(), AzureResourceProcessor(), AzureWorkspaceTriadProcessor(), DropProcessor(), EmailProcessor(), IndexServiceProcessor(), PFSProcessor(), StorageProcessor(), UserInfoProcessor(user_object_id=self.user_object_id, tenant_id=self.tenant_id), ] def _postprocess_recording(self) -> None: self._apply_replacement_for_recordings() return def _apply_replacement_for_recordings(self) -> None: for i in range(len(self.cassette.data)): req, resp = self.cassette.data[i] req = self.variable_recorder.sanitize_request(req) resp = self.variable_recorder.sanitize_response(resp) self.cassette.data[i] = (req, resp) return class PFAzureRunIntegrationTestRecording(PFAzureIntegrationTestRecording): """Test class for run operations in Prompt Flow Azure. Different from other operations, run operations have: - duplicate network requests for stream run - blob storage requests contain upload hash - Submit and get run data API requests are indistinguishable without run name in body Use a separate class with more pre/post recording processing method or request matchers to handle above cases. """ def _init_vcr(self) -> vcr.VCR: _vcr = super(PFAzureRunIntegrationTestRecording, self)._init_vcr() _vcr.register_matcher("path", self._custom_request_path_matcher) _vcr.register_matcher("body", self._custom_request_body_matcher) return _vcr def enter_vcr(self): self._cm = self.vcr.use_cassette( self.recording_file.as_posix(), allow_playback_repeats=True, filter_query_parameters=["api-version"], ) self.cassette = self._cm.__enter__() def _postprocess_recording(self) -> None: self._drop_duplicate_recordings() super(PFAzureRunIntegrationTestRecording, self)._postprocess_recording() def _drop_duplicate_recordings(self) -> None: # stream run operation contains two requests: # 1. get status; 2. get logs # before the run is terminated, there will be many duplicate requests # getting status/logs, which leads to infinite loop during replay # therefore apply such post process to drop those duplicate recordings dropped_recordings = [] run_data_requests = dict() log_content_requests = dict() for req, resp in self.cassette.data: # run hisotry's rundata API if str(req.path).endswith("/rundata"): body = req.body.decode("utf-8") body_dict = json.loads(body) name = body_dict["runId"] run_data_requests[name] = (req, resp) continue if str(req.path).endswith("/logContent"): log_content_requests[req.uri] = (req, resp) continue dropped_recordings.append((req, resp)) # append rundata recording(s) for req, resp in run_data_requests.values(): dropped_recordings.append((req, resp)) for req, resp in log_content_requests.values(): dropped_recordings.append((req, resp)) self.cassette.data = dropped_recordings return def _custom_request_path_matcher(self, r1: Request, r2: Request) -> bool: # NOTE: orders of below conditions matter, please modify with caution # in run download scenario, observed below wired path: https://<xxx>/https://<yyy>/<remaining> # as we don't have append/replace logic, it might result from Azure blob client, # which is hard to patch; therefore, hack this in matcher (here) # https:// should appear in path, so it's safe to use this as a condition if "https://" in r1.path: _path = str(r1.path) endpoint = ".blob.core.windows.net/" duplicate_path = _path[_path.index(endpoint) + len(endpoint) :] path_for_compare = _path[: _path.index("https://")] + duplicate_path[duplicate_path.index("/") + 1 :] return path_for_compare == r2.path # for blob storage request, sanitize the upload hash in path if r1.host == r2.host and r1.host == SanitizedValues.BLOB_STORAGE_REQUEST_HOST: return sanitize_upload_hash(r1.path) == r2.path # for file share request, mainly target pytest fixture "created_flow" if r1.host == r2.host and r1.host == SanitizedValues.FILE_SHARE_REQUEST_HOST: return sanitize_file_share_flow_path(r1.path) == r2.path # for automatic runtime, sanitize flow session id in path if r1.host == r2.host and ("FlowSessions" in r1.path and "FlowSessions" in r2.path): path1 = sanitize_automatic_runtime_request_path(r1.path) path2 = sanitize_automatic_runtime_request_path(r2.path) return sanitize_azure_workspace_triad(path1) == path2 return r1.path == r2.path def _custom_request_body_matcher(self, r1: Request, r2: Request) -> bool: if is_json_payload_request(r1) and r1.body is not None: # note that `sanitize_upload_hash` is not idempotent # so we should not modify r1 directly # otherwise it will be sanitized multiple times with many zeros _r1 = copy.deepcopy(r1) body1 = _r1.body.decode("utf-8") body1 = sanitize_pfs_request_body(body1) body1 = sanitize_upload_hash(body1) _r1.body = body1.encode("utf-8") try: return matchers.body(_r1, r2) except AssertionError: # if not match, extra sanitize flow file share path (if exists) # for potential pytest fixture "created_flow" scenario body_dict = json.loads(body1) if "flowDefinitionFilePath" in body_dict: body_dict["flowDefinitionFilePath"] = "Users/unknown_user/promptflow/flow_name/flow.dag.yaml" body1 = json.dumps(body_dict) _r1.body = body1.encode("utf-8") return matchers.body(_r1, r2) else: return False else: return matchers.body(r1, r2)
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/recording_utilities/processors.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import base64 import json from typing import Dict from vcr.request import Request from .constants import AzureMLResourceTypes, SanitizedValues from .utils import ( is_json_payload_request, is_json_payload_response, sanitize_azure_workspace_triad, sanitize_email, sanitize_experiment_id, sanitize_pfs_request_body, sanitize_pfs_response_body, sanitize_upload_hash, sanitize_username, ) class RecordingProcessor: def process_request(self, request: Request) -> Request: return request def process_response(self, response: Dict) -> Dict: return response class AzureWorkspaceTriadProcessor(RecordingProcessor): """Sanitize subscription id, resource group name and workspace name.""" def process_request(self, request: Request) -> Request: request.uri = sanitize_azure_workspace_triad(request.uri) return request def process_response(self, response: Dict) -> Dict: response["body"]["string"] = sanitize_azure_workspace_triad(response["body"]["string"]) return response class AzureMLExperimentIDProcessor(RecordingProcessor): """Sanitize Azure ML experiment id, currently we use workspace id as the value.""" def process_request(self, request: Request) -> Request: request.uri = sanitize_experiment_id(request.uri) return request def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): if "experimentId" in response["body"]["string"]: body = json.loads(response["body"]["string"]) if "experimentId" in body: body["experimentId"] = SanitizedValues.WORKSPACE_ID response["body"]["string"] = json.dumps(body) return response class AzureResourceProcessor(RecordingProcessor): """Sanitize sensitive data in Azure resource GET response.""" def __init__(self): # datastore related self.storage_account_names = set() self.storage_container_names = set() self.file_share_names = set() def _sanitize_request_url_for_storage(self, uri: str) -> str: # this instance will store storage account names and container names # so we can apply the sanitization here with simple string replace rather than regex for account_name in self.storage_account_names: uri = uri.replace(account_name, SanitizedValues.FAKE_ACCOUNT_NAME) for container_name in self.storage_container_names: uri = uri.replace(container_name, SanitizedValues.FAKE_CONTAINER_NAME) for file_share_name in self.file_share_names: uri = uri.replace(file_share_name, SanitizedValues.FAKE_FILE_SHARE_NAME) return uri def process_request(self, request: Request) -> Request: request.uri = self._sanitize_request_url_for_storage(request.uri) return request def _sanitize_response_body(self, body: Dict) -> Dict: resource_type = body.get("type") if resource_type == AzureMLResourceTypes.WORKSPACE: body = self._sanitize_response_for_workspace(body) elif resource_type == AzureMLResourceTypes.CONNECTION: body = self._sanitize_response_for_arm_connection(body) elif resource_type == AzureMLResourceTypes.DATASTORE: body = self._sanitize_response_for_datastore(body) return body def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): body = json.loads(response["body"]["string"]) if isinstance(body, dict): # response can be a list sometimes (e.g. get workspace datastores) # need to sanitize each with a for loop if "value" in body: resources = body["value"] for i in range(len(resources)): resources[i] = self._sanitize_response_body(resources[i]) body["value"] = resources else: body = self._sanitize_response_body(body) response["body"]["string"] = json.dumps(body) return response def _sanitize_response_for_workspace(self, body: Dict) -> Dict: filter_keys = ["identity", "properties", "systemData"] for k in filter_keys: if k in body: body.pop(k) # need during the constructor of FlowServiceCaller (for vNet case) body["properties"] = {"discoveryUrl": SanitizedValues.DISCOVERY_URL} name = body["name"] body["name"] = SanitizedValues.WORKSPACE_NAME body["id"] = body["id"].replace(name, SanitizedValues.WORKSPACE_NAME) return body def _sanitize_response_for_arm_connection(self, body: Dict) -> Dict: if body["properties"]["authType"] == "CustomKeys": # custom connection, sanitize "properties.credentials.keys" body["properties"]["credentials"]["keys"] = {} else: # others, sanitize "properties.credentials.key" body["properties"]["credentials"]["key"] = "_" body["properties"]["target"] = "_" return body def _sanitize_response_for_datastore(self, body: Dict) -> Dict: body["properties"]["subscriptionId"] = SanitizedValues.SUBSCRIPTION_ID body["properties"]["resourceGroup"] = SanitizedValues.RESOURCE_GROUP_NAME self.storage_account_names.add(body["properties"]["accountName"]) body["properties"]["accountName"] = SanitizedValues.FAKE_ACCOUNT_NAME # blob storage if "containerName" in body["properties"]: self.storage_container_names.add(body["properties"]["containerName"]) body["properties"]["containerName"] = SanitizedValues.FAKE_CONTAINER_NAME # file share elif "fileShareName" in body["properties"]: self.file_share_names.add(body["properties"]["fileShareName"]) body["properties"]["fileShareName"] = SanitizedValues.FAKE_FILE_SHARE_NAME return body class AzureOpenAIConnectionProcessor(RecordingProcessor): """Sanitize api_base in AOAI connection GET response.""" def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): body = json.loads(response["body"]["string"]) if isinstance(body, dict) and body.get("connectionType") == "AzureOpenAI": body["configs"]["api_base"] = SanitizedValues.FAKE_API_BASE response["body"]["string"] = json.dumps(body) return response class StorageProcessor(RecordingProcessor): """Sanitize sensitive data during storage operations when submit run.""" def process_request(self, request: Request) -> Request: request.uri = sanitize_upload_hash(request.uri) request.uri = sanitize_username(request.uri) if is_json_payload_request(request) and request.body is not None: body = request.body.decode("utf-8") body = sanitize_upload_hash(body) body = sanitize_username(body) request.body = body.encode("utf-8") return request def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): response["body"]["string"] = sanitize_username(response["body"]["string"]) body = json.loads(response["body"]["string"]) if isinstance(body, dict): self._sanitize_list_secrets_response(body) response["body"]["string"] = json.dumps(body) return response def _sanitize_list_secrets_response(self, body: Dict) -> Dict: if "key" in body: b64_key = base64.b64encode(SanitizedValues.FAKE_KEY.encode("ascii")) body["key"] = str(b64_key, "ascii") return body class DropProcessor(RecordingProcessor): """Ignore some requests that won't be used during playback.""" def process_request(self, request: Request) -> Request: if "/metadata/identity/oauth2/token" in request.path: return None return request class PFSProcessor(RecordingProcessor): """Sanitize request/response for PFS operations.""" def process_request(self, request: Request) -> Request: if is_json_payload_request(request) and request.body is not None: body = request.body.decode("utf-8") body = sanitize_pfs_request_body(body) request.body = body.encode("utf-8") return request def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): response["body"]["string"] = sanitize_pfs_response_body(response["body"]["string"]) return response class UserInfoProcessor(RecordingProcessor): """Sanitize user object id and tenant id in responses.""" def __init__(self, user_object_id: str, tenant_id: str): self.user_object_id = user_object_id self.tenant_id = tenant_id def process_request(self, request: Request) -> Request: if is_json_payload_request(request) and request.body is not None: body = request.body.decode("utf-8") body = str(body).replace(self.user_object_id, SanitizedValues.USER_OBJECT_ID) body = body.replace(self.tenant_id, SanitizedValues.TENANT_ID) request.body = body.encode("utf-8") return request def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): response["body"]["string"] = str(response["body"]["string"]).replace( self.user_object_id, SanitizedValues.USER_OBJECT_ID ) response["body"]["string"] = str(response["body"]["string"]).replace( self.tenant_id, SanitizedValues.TENANT_ID ) return response class IndexServiceProcessor(RecordingProcessor): """Sanitize index service responses.""" def process_response(self, response: Dict) -> Dict: if is_json_payload_response(response): if "continuationToken" in response["body"]["string"]: body = json.loads(response["body"]["string"]) body.pop("continuationToken", None) response["body"]["string"] = json.dumps(body) return response class EmailProcessor(RecordingProcessor): """Sanitize email address in responses.""" def process_response(self, response: Dict) -> Dict: response["body"]["string"] = sanitize_email(response["body"]["string"]) return response
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/recording_utilities/variable_recorder.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from typing import Dict from vcr.request import Request from .utils import is_httpx_response, is_json_payload_request class VariableRecorder: def __init__(self): self.variables = dict() def get_or_record_variable(self, variable: str, default: str) -> str: return self.variables.setdefault(variable, default) def sanitize_request(self, request: Request) -> Request: request.uri = self._sanitize(request.uri) if is_json_payload_request(request) and request.body is not None: body = request.body.decode("utf-8") body = self._sanitize(body) request.body = body.encode("utf-8") return request def sanitize_response(self, response: Dict) -> Dict: # httpx response: .content, string; no action needed # non-httpx response: .body.string, bytes, need decode/encode if is_httpx_response(response): response["content"] = self._sanitize(response["content"]) else: response["body"]["string"] = response["body"]["string"].decode("utf-8") response["body"]["string"] = self._sanitize(response["body"]["string"]) response["body"]["string"] = response["body"]["string"].encode("utf-8") return response def _sanitize(self, value: str) -> str: for k, v in self.variables.items(): value = value.replace(v, k) return value
0
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test
promptflow_repo/promptflow/src/promptflow/tests/sdk_cli_azure_test/recording_utilities/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from .bases import PFAzureIntegrationTestRecording from .constants import SanitizedValues from .utils import get_created_flow_name_from_flow_path, get_pf_client_for_replay, is_live, is_record, is_replay from .variable_recorder import VariableRecorder __all__ = [ "PFAzureIntegrationTestRecording", "SanitizedValues", "VariableRecorder", "get_created_flow_name_from_flow_path", "get_pf_client_for_replay", "is_live", "is_record", "is_replay", ]
0
promptflow_repo/promptflow/src/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/exceptions.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import inspect import string import traceback from enum import Enum from functools import cached_property class ErrorCategory(str, Enum): USER_ERROR = "UserError" SYSTEM_ERROR = "SystemError" UNKNOWN = "Unknown" class ErrorTarget(str, Enum): """The target of the error, indicates which part of the system the error occurs.""" EXECUTOR = "Executor" BATCH = "Batch" FLOW_EXECUTOR = "FlowExecutor" NODE_EXECUTOR = "NodeExecutor" TOOL = "Tool" AZURE_RUN_STORAGE = "AzureRunStorage" RUNTIME = "Runtime" UNKNOWN = "Unknown" RUN_TRACKER = "RunTracker" RUN_STORAGE = "RunStorage" CONTROL_PLANE_SDK = "ControlPlaneSDK" SERVING_APP = "ServingApp" FLOW_INVOKER = "FlowInvoker" FUNCTION_PATH = "FunctionPath" class PromptflowException(Exception): """Base exception for all errors. :param message: A message describing the error. This is the error message the user will see. :type message: str :param target: The name of the element that caused the exception to be thrown. :type target: ~promptflow.exceptions.ErrorTarget :param error: The original exception if any. :type error: Exception """ def __init__( self, message="", message_format="", target: ErrorTarget = ErrorTarget.UNKNOWN, module=None, **kwargs, ): self._inner_exception = kwargs.get("error") self._target = target self._module = module self._message_format = message_format self._kwargs = kwargs if message: self._message = str(message) elif self.message_format: self._message = self.message_format.format(**self.message_parameters) else: self._message = self.__class__.__name__ super().__init__(self._message) @property def message(self): """The error message.""" return self._message @property def message_format(self): """The error message format.""" return self._message_format @cached_property def message_parameters(self): """The error message parameters.""" if not self._kwargs: return {} required_arguments = self.get_arguments_from_message_format(self.message_format) parameters = {} for argument in required_arguments: if argument not in self._kwargs: parameters[argument] = f"<{argument}>" else: parameters[argument] = self._kwargs[argument] return parameters @cached_property def serializable_message_parameters(self): """The serializable error message parameters.""" return {k: str(v) for k, v in self.message_parameters.items()} @property def target(self): """The error target. :return: The error target. :rtype: ~promptflow.exceptions.ErrorTarget """ return self._target @target.setter def target(self, value): """Set the error target.""" self._target = value @property def module(self): """The module of the error that occurs. It is similar to `target` but is more specific. It is meant to store the Python module name of the code that raises the exception. """ return self._module @module.setter def module(self, value): """Set the module of the error that occurs.""" self._module = value @property def reference_code(self): """The reference code of the error.""" # In Python 3.11, the __str__ method of the Enum type returns the name of the enumeration member. # However, in earlier Python versions, the __str__ method returns the value of the enumeration member. # Therefore, when dealing with this situation, we need to make some additional adjustments. target = self.target.value if isinstance(self.target, ErrorTarget) else self.target if self.module: return f"{target}/{self.module}" else: return target @property def inner_exception(self): """Get the inner exception. The inner exception can be set via either style: 1) Set via the error parameter in the constructor. raise PromptflowException("message", error=inner_exception) 2) Set via raise from statement. raise PromptflowException("message") from inner_exception """ return self._inner_exception or self.__cause__ @property def additional_info(self): """Return a dict of the additional info of the exception. By default, this information could usually be empty. However, we can still define additional info for some specific exception. i.e. For ToolExcutionError, we may add the tool's line number, stacktrace to the additional info. """ return None @property def error_codes(self): """Returns a list of the error codes for this exception. The error codes is defined the same as the class inheritance. i.e. For ToolExcutionError which inherits from UserErrorException, The result would be ["UserErrorException", "ToolExecutionError"]. """ if getattr(self, "_error_codes", None): return self._error_codes from promptflow._utils.exception_utils import infer_error_code_from_class def reversed_error_codes(): for clz in self.__class__.__mro__: if clz is PromptflowException: break yield infer_error_code_from_class(clz) self._error_codes = list(reversed_error_codes()) self._error_codes.reverse() return self._error_codes def get_arguments_from_message_format(self, message_format): """Get the arguments from the message format.""" def iter_field_name(): if not message_format: return for _, field_name, _, _ in string.Formatter().parse(message_format): if field_name is not None: yield field_name return set(iter_field_name()) def __str__(self): """Return the error message. Some child classes may override this method to return a more detailed error message.""" return self.message class UserErrorException(PromptflowException): """Exception raised when invalid or unsupported inputs are provided.""" pass class SystemErrorException(PromptflowException): """Exception raised when service error is triggered.""" pass class ValidationException(UserErrorException): """Exception raised when validation fails.""" pass class _ErrorInfo: @classmethod def get_error_info(cls, e: Exception): if not isinstance(e, Exception): return None, None, None, None, None e = cls.select_exception(e) if cls._is_system_error(e): return ( ErrorCategory.SYSTEM_ERROR, cls._error_type(e), cls._error_target(e), cls._error_message(e), cls._error_detail(e), ) if cls._is_user_error(e): return ( ErrorCategory.USER_ERROR, cls._error_type(e), cls._error_target(e), cls._error_message(e), cls._error_detail(e), ) return ErrorCategory.UNKNOWN, cls._error_type(e), ErrorTarget.UNKNOWN, "", cls._error_detail(e) @classmethod def select_exception(cls, e: Exception): """Select the exception in e and e.__cause__, and prioritize the Exception defined in the promptflow.""" if isinstance(e, PromptflowException): return e # raise Exception("message") from PromptflowException("message") if e.__cause__ and isinstance(e.__cause__, PromptflowException): return e.__cause__ return e @classmethod def _is_system_error(cls, e: Exception): if isinstance(e, SystemErrorException): return True return False @classmethod def _is_user_error(cls, e: Exception): if isinstance(e, UserErrorException): return True return False @classmethod def _error_type(cls, e: Exception): """Return exception type. Note: For PromptflowException(error=ValueError(message="xxx")) or UserErrorException(error=ValueError(message="xxx")) or SystemErrorException(error=ValueError(message="xxx")), the desired return type is ValueError, not PromptflowException, UserErrorException and SystemErrorException. """ error_type = type(e).__name__ if type(e) in (PromptflowException, UserErrorException, SystemErrorException): if e.inner_exception: error_type = type(e.inner_exception).__name__ return error_type @classmethod def _error_target(cls, e: Exception): return getattr(e, "target", ErrorTarget.UNKNOWN) @classmethod def _error_message(cls, e: Exception): return getattr(e, "message_format", "") @classmethod def _error_detail(cls, e: Exception): exception_codes = cls._get_exception_codes(e) exception_code = None for item in exception_codes[::-1]: if "promptflow" in item["module"]: # Only record information within the promptflow package exception_code = item break if not exception_code: return "" return ( f"module={exception_code['module']}, " f"code={exception_code['exception_code']}, " f"lineno={exception_code['lineno']}." ) @classmethod def _get_exception_codes(cls, e: Exception) -> list: """ Obtain information on each line of the traceback, including the module name, exception code and lineno where the error occurred. :param e: Exception object :return: A list, each item contains information for each row of the traceback, which format is like this: { 'module': 'promptflow.executor.errors', 'exception_code': 'return self.inner_exception.additional_info', 'lineno': 223 } """ exception_codes = [] traceback_info = traceback.extract_tb(e.__traceback__) for item in traceback_info: lineno = item.lineno filename = item.filename line_code = item.line module = inspect.getmodule(None, _filename=filename) exception_code = {"module": "", "exception_code": line_code, "lineno": lineno} if module is not None: exception_code["module"] = module.__name__ exception_codes.append(exception_code) return exception_codes
0
promptflow_repo/promptflow/src/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_constants.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- CONNECTION_NAME_PROPERTY = "__connection_name" CONNECTION_SECRET_KEYS = "__secret_keys" PROMPTFLOW_CONNECTIONS = "PROMPTFLOW_CONNECTIONS" PROMPTFLOW_SECRETS_FILE = "PROMPTFLOW_SECRETS_FILE" PF_NO_INTERACTIVE_LOGIN = "PF_NO_INTERACTIVE_LOGIN" PF_LOGGING_LEVEL = "PF_LOGGING_LEVEL" OPENAI_API_KEY = "openai-api-key" BING_API_KEY = "bing-api-key" AOAI_API_KEY = "aoai-api-key" SERPAPI_API_KEY = "serpapi-api-key" CONTENT_SAFETY_API_KEY = "content-safety-api-key" ERROR_RESPONSE_COMPONENT_NAME = "promptflow" EXTENSION_UA = "prompt-flow-extension" LANGUAGE_KEY = "language" DEFAULT_ENCODING = "utf-8" # Constants related to execution LINE_NUMBER_KEY = "line_number" # Using the same key with portal. LINE_TIMEOUT_SEC = 600 class FlowLanguage: """The enum of tool source type.""" Python = "python" CSharp = "csharp" class AvailableIDE: VS = "vs" VS_CODE = "vsc" USER_AGENT = "USER_AGENT" PF_USER_AGENT = "PF_USER_AGENT" CLI_PACKAGE_NAME = 'promptflow' CURRENT_VERSION = 'current_version' LATEST_VERSION = 'latest_version' LAST_HINT_TIME = 'last_hint_time' LAST_CHECK_TIME = 'last_check_time' PF_VERSION_CHECK = "pf_version_check.json" HINT_INTERVAL_DAY = 7 GET_PYPI_INTERVAL_DAY = 7 _ENV_PF_INSTALLER = 'PF_INSTALLER'
0
promptflow_repo/promptflow/src/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_version.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- VERSION = "0.0.1"
0
promptflow_repo/promptflow/src/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore from promptflow._core.metric_logger import log_metric # flake8: noqa from promptflow._core.tool import ToolProvider, tool from promptflow._core.tracer import trace # control plane sdk functions from promptflow._sdk._load_functions import load_flow, load_run from ._sdk._pf_client import PFClient from ._version import VERSION # backward compatibility log_flow_metric = log_metric __version__ = VERSION __all__ = ["PFClient", "load_flow", "load_run", "log_metric", "ToolProvider", "tool", "trace"]
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_errors.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from promptflow._sdk._constants import BULK_RUN_ERRORS from promptflow.exceptions import ErrorTarget, SystemErrorException, UserErrorException class SDKError(UserErrorException): """SDK base class, target default is CONTROL_PLANE_SDK.""" def __init__( self, message="", message_format="", target: ErrorTarget = ErrorTarget.CONTROL_PLANE_SDK, module=None, **kwargs, ): super().__init__(message=message, message_format=message_format, target=target, module=module, **kwargs) class SDKInternalError(SystemErrorException): """SDK internal error.""" def __init__( self, message="", message_format="", target: ErrorTarget = ErrorTarget.CONTROL_PLANE_SDK, module=None, **kwargs, ): super().__init__(message=message, message_format=message_format, target=target, module=module, **kwargs) class RunExistsError(SDKError): """Exception raised when run already exists.""" pass class RunNotFoundError(SDKError): """Exception raised if run cannot be found.""" pass class InvalidRunStatusError(SDKError): """Exception raised if run status is invalid.""" pass class UnsecureConnectionError(SDKError): """Exception raised if connection is not secure.""" pass class DecryptConnectionError(SDKError): """Exception raised if connection decryption failed.""" pass class StoreConnectionEncryptionKeyError(SDKError): """Exception raised if no keyring backend.""" pass class InvalidFlowError(SDKError): """Exception raised if flow definition is not legal.""" pass class ConnectionNotFoundError(SDKError): """Exception raised if connection is not found.""" pass class InvalidRunError(SDKError): """Exception raised if run name is not legal.""" pass class GenerateFlowToolsJsonError(SDKError): """Exception raised if flow tools json generation failed.""" pass class BulkRunException(SDKError): """Exception raised when bulk run failed.""" def __init__(self, *, message="", failed_lines, total_lines, errors, module: str = None, **kwargs): self.failed_lines = failed_lines self.total_lines = total_lines self._additional_info = { BULK_RUN_ERRORS: errors, } message = f"First error message is: {message}" # bulk run error is line error only when failed_lines > 0 if isinstance(failed_lines, int) and isinstance(total_lines, int) and failed_lines > 0: message = f"Failed to run {failed_lines}/{total_lines} lines. " + message super().__init__(message=message, target=ErrorTarget.RUNTIME, module=module, **kwargs) @property def additional_info(self): """Set the tool exception details as additional info.""" return self._additional_info class RunOperationParameterError(SDKError): """Exception raised when list run failed.""" pass class RunOperationError(SDKError): """Exception raised when run operation failed.""" pass class FlowOperationError(SDKError): """Exception raised when flow operation failed.""" pass class ExperimentExistsError(SDKError): """Exception raised when experiment already exists.""" pass class ExperimentNotFoundError(SDKError): """Exception raised if experiment cannot be found.""" pass class ExperimentValidationError(SDKError): """Exception raised if experiment validation failed.""" pass class ExperimentValueError(SDKError): """Exception raised if experiment validation failed.""" pass class ExperimentHasCycle(SDKError): """Exception raised if experiment validation failed.""" pass class DownloadInternalError(SDKInternalError): """Exception raised if download internal error.""" pass class ExperimentCommandRunError(SDKError): """Exception raised if experiment validation failed.""" pass
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_mlflow.py
# flake8: noqa """Put some imports here for mlflow promptflow flavor usage. DO NOT change the module names in "all" list. If the interface has changed in source code, wrap it here and keep original function/module names the same as before, otherwise mldesigner will be broken by this change. """ from promptflow._sdk._constants import DAG_FILE_NAME from promptflow._sdk._serving.flow_invoker import FlowInvoker from promptflow._sdk._submitter import remove_additional_includes from promptflow._sdk._utils import _merge_local_code_and_additional_includes from promptflow._sdk.entities._flow import Flow __all__ = [ "Flow", "FlowInvoker", "remove_additional_includes", "_merge_local_code_and_additional_includes", "DAG_FILE_NAME", ]
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_utils.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import collections import hashlib import json import multiprocessing import os import platform import re import shutil import stat import sys import tempfile import zipfile from contextlib import contextmanager from enum import Enum from functools import partial from os import PathLike from pathlib import Path from typing import Any, Dict, List, Optional, Set, Tuple, Union from urllib.parse import urlparse import keyring import pydash from cryptography.fernet import Fernet from filelock import FileLock from jinja2 import Template from keyring.errors import NoKeyringError from marshmallow import ValidationError import promptflow from promptflow._constants import EXTENSION_UA, PF_NO_INTERACTIVE_LOGIN, PF_USER_AGENT, USER_AGENT from promptflow._core.tool_meta_generator import generate_tool_meta_dict_by_file from promptflow._core.tools_manager import gen_dynamic_list, retrieve_tool_func_result from promptflow._sdk._constants import ( DAG_FILE_NAME, DEFAULT_ENCODING, FLOW_TOOLS_JSON, FLOW_TOOLS_JSON_GEN_TIMEOUT, HOME_PROMPT_FLOW_DIR, KEYRING_ENCRYPTION_KEY_NAME, KEYRING_ENCRYPTION_LOCK_PATH, KEYRING_SYSTEM, NODE, NODE_VARIANTS, NODES, PROMPT_FLOW_DIR_NAME, REFRESH_CONNECTIONS_DIR_LOCK_PATH, REGISTRY_URI_PREFIX, REMOTE_URI_PREFIX, USE_VARIANTS, VARIANTS, CommonYamlFields, ConnectionProvider, ) from promptflow._sdk._errors import ( DecryptConnectionError, GenerateFlowToolsJsonError, StoreConnectionEncryptionKeyError, UnsecureConnectionError, ) from promptflow._sdk._vendor import IgnoreFile, get_ignore_file, get_upload_files_from_folder from promptflow._utils.context_utils import _change_working_dir, inject_sys_path from promptflow._utils.dataclass_serializer import serialize from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow._utils.yaml_utils import dump_yaml, load_yaml, load_yaml_string from promptflow.contracts.tool import ToolType from promptflow.exceptions import ErrorTarget, UserErrorException logger = get_cli_sdk_logger() def snake_to_camel(name): return re.sub(r"(?:^|_)([a-z])", lambda x: x.group(1).upper(), name) def find_type_in_override(params_override: Optional[list] = None) -> Optional[str]: params_override = params_override or [] for override in params_override: if CommonYamlFields.TYPE in override: return override[CommonYamlFields.TYPE] return None # region Encryption CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING = None ENCRYPTION_KEY_IN_KEY_RING = None @contextmanager def use_customized_encryption_key(encryption_key: str): global CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING = encryption_key yield CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING = None def set_encryption_key(encryption_key: Union[str, bytes]): if isinstance(encryption_key, bytes): encryption_key = encryption_key.decode("utf-8") keyring.set_password("promptflow", "encryption_key", encryption_key) _encryption_key_lock = FileLock(KEYRING_ENCRYPTION_LOCK_PATH) def get_encryption_key(generate_if_not_found: bool = False) -> str: global CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING global ENCRYPTION_KEY_IN_KEY_RING if CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING is not None: return CUSTOMIZED_ENCRYPTION_KEY_IN_KEY_RING if ENCRYPTION_KEY_IN_KEY_RING is not None: return ENCRYPTION_KEY_IN_KEY_RING def _get_from_keyring(): try: # Cache encryption key as mac will pop window to ask for permission when calling get_password return keyring.get_password(KEYRING_SYSTEM, KEYRING_ENCRYPTION_KEY_NAME) except NoKeyringError as e: raise StoreConnectionEncryptionKeyError( "System keyring backend service not found in your operating system. " "See https://pypi.org/project/keyring/ to install requirement for different operating system, " "or 'pip install keyrings.alt' to use the third-party backend. Reach more detail about this error at " "https://microsoft.github.io/promptflow/how-to-guides/faq.html#connection-creation-failed-with-storeconnectionencryptionkeyerror" # noqa: E501 ) from e ENCRYPTION_KEY_IN_KEY_RING = _get_from_keyring() if ENCRYPTION_KEY_IN_KEY_RING is not None or not generate_if_not_found: return ENCRYPTION_KEY_IN_KEY_RING _encryption_key_lock.acquire() # Note: we access the keyring twice, as global var can't share across processes. ENCRYPTION_KEY_IN_KEY_RING = _get_from_keyring() if ENCRYPTION_KEY_IN_KEY_RING is not None: return ENCRYPTION_KEY_IN_KEY_RING try: ENCRYPTION_KEY_IN_KEY_RING = Fernet.generate_key().decode("utf-8") keyring.set_password(KEYRING_SYSTEM, KEYRING_ENCRYPTION_KEY_NAME, ENCRYPTION_KEY_IN_KEY_RING) finally: _encryption_key_lock.release() return ENCRYPTION_KEY_IN_KEY_RING def encrypt_secret_value(secret_value): encryption_key = get_encryption_key(generate_if_not_found=True) fernet_client = Fernet(encryption_key) token = fernet_client.encrypt(secret_value.encode("utf-8")) return token.decode("utf-8") def decrypt_secret_value(connection_name, encrypted_secret_value): encryption_key = get_encryption_key() if encryption_key is None: raise Exception("Encryption key not found in keyring.") fernet_client = Fernet(encryption_key) try: return fernet_client.decrypt(encrypted_secret_value.encode("utf-8")).decode("utf-8") except Exception as e: if len(encrypted_secret_value) < 57: # This is to workaround old custom secrets that are not encrypted with Fernet. # Fernet token: https://github.com/fernet/spec/blob/master/Spec.md # Format: Version ‖ Timestamp ‖ IV ‖ Ciphertext ‖ HMAC # Version: 8 bits, Timestamp: 64 bits, IV: 128 bits, HMAC: 256 bits, # Ciphertext variable length, multiple of 128 bits # So the minimum length of a Fernet token is 57 bytes raise UnsecureConnectionError( f"Please delete and re-create connection {connection_name} " f"due to a security issue in the old sdk version." ) raise DecryptConnectionError( f"Decrypt connection {connection_name} secret failed: {str(e)}. " f"If you have ever changed your encryption key manually, " f"please revert it back to the original one, or delete all connections and re-create them." ) # endregion def decorate_validation_error(schema: Any, pretty_error: str, additional_message: str = "") -> str: return f"Validation for {schema.__name__} failed:\n\n {pretty_error} \n\n {additional_message}" def load_from_dict(schema: Any, data: Dict, context: Dict, additional_message: str = "", **kwargs): try: return schema(context=context).load(data, **kwargs) except ValidationError as e: pretty_error = json.dumps(e.normalized_messages(), indent=2) raise ValidationError(decorate_validation_error(schema, pretty_error, additional_message)) def strip_quotation(value): """ To avoid escaping chars in command args, args will be surrounded in quotas. Need to remove the pair of quotation first. """ if value.startswith('"') and value.endswith('"'): return value[1:-1] elif value.startswith("'") and value.endswith("'"): return value[1:-1] else: return value def parse_variant(variant: str) -> Tuple[str, str]: variant_regex = r"\${([^.]+).([^}]+)}" match = re.match(variant_regex, strip_quotation(variant)) if match: return match.group(1), match.group(2) else: error = ValueError( f"Invalid variant format: {variant}, variant should be in format of ${{TUNING_NODE.VARIANT}}" ) raise UserErrorException( target=ErrorTarget.CONTROL_PLANE_SDK, message=str(error), error=error, ) def _match_reference(env_val: str): env_val = env_val.strip() m = re.match(r"^\$\{([^.]+)\.([^.]+)}$", env_val) if not m: return None, None name, key = m.groups() return name, key # !!! Attention!!!: Please make sure you have contact with PRS team before changing the interface. def get_used_connection_names_from_environment_variables(): """The function will get all potential related connection names from current environment variables. for example, if part of env var is { "ENV_VAR_1": "${my_connection.key}", "ENV_VAR_2": "${my_connection.key2}", "ENV_VAR_3": "${my_connection2.key}", } The function will return {"my_connection", "my_connection2"}. """ return get_used_connection_names_from_dict(os.environ) def get_used_connection_names_from_dict(connection_dict: dict): connection_names = set() for key, val in connection_dict.items(): connection_name, _ = _match_reference(val) if connection_name: connection_names.add(connection_name) return connection_names # !!! Attention!!!: Please make sure you have contact with PRS team before changing the interface. def update_environment_variables_with_connections(built_connections): """The function will result env var value ${my_connection.key} to the real connection keys.""" return update_dict_value_with_connections(built_connections, os.environ) def _match_env_reference(val: str): try: val = val.strip() m = re.match(r"^\$\{env:(.+)}$", val) if not m: return None name = m.groups()[0] return name except Exception: # for exceptions when val is not a string, return return None def override_connection_config_with_environment_variable(connections: Dict[str, dict]): """ The function will use relevant environment variable to override connection configurations. For instance, if there is a custom connection named 'custom_connection' with a configuration key called 'chat_deployment_name,' the function will attempt to retrieve 'chat_deployment_name' from the environment variable 'CUSTOM_CONNECTION_CHAT_DEPLOYMENT_NAME' by default. If the environment variable is not set, it will use the original value as a fallback. """ for connection_name, connection in connections.items(): values = connection.get("value", {}) for key, val in values.items(): connection_name = connection_name.replace(" ", "_") env_name = f"{connection_name}_{key}".upper() if env_name not in os.environ: continue values[key] = os.environ[env_name] logger.info(f"Connection {connection_name}'s {key} is overridden with environment variable {env_name}") return connections def resolve_connections_environment_variable_reference(connections: Dict[str, dict]): """The function will resolve connection secrets env var reference like api_key: ${env:KEY}""" for connection in connections.values(): values = connection.get("value", {}) for key, val in values.items(): if not _match_env_reference(val): continue env_name = _match_env_reference(val) if env_name not in os.environ: raise UserErrorException(f"Environment variable {env_name} is not found.") values[key] = os.environ[env_name] return connections def update_dict_value_with_connections(built_connections, connection_dict: dict): for key, val in connection_dict.items(): connection_name, connection_key = _match_reference(val) if connection_name is None: continue if connection_name not in built_connections: continue if connection_key not in built_connections[connection_name]["value"]: continue connection_dict[key] = built_connections[connection_name]["value"][connection_key] def in_jupyter_notebook() -> bool: """ Checks if user is using a Jupyter Notebook. This is necessary because logging is not allowed in non-Jupyter contexts. Adapted from https://stackoverflow.com/a/22424821 """ try: # cspell:ignore ipython from IPython import get_ipython if "IPKernelApp" not in get_ipython().config: return False except ImportError: return False except AttributeError: return False return True def render_jinja_template(template_path, *, trim_blocks=True, keep_trailing_newline=True, **kwargs): with open(template_path, "r", encoding=DEFAULT_ENCODING) as f: template = Template(f.read(), trim_blocks=trim_blocks, keep_trailing_newline=keep_trailing_newline) return template.render(**kwargs) def print_yellow_warning(message): from colorama import Fore, init init(autoreset=True) print(Fore.YELLOW + message) def print_red_error(message): from colorama import Fore, init init(autoreset=True) print(Fore.RED + message) def safe_parse_object_list(obj_list, parser, message_generator): results = [] for obj in obj_list: try: results.append(parser(obj)) except Exception as e: extended_message = f"{message_generator(obj)} Error: {type(e).__name__}, {str(e)}" print_yellow_warning(extended_message) return results def _normalize_identifier_name(name): normalized_name = name.lower() normalized_name = re.sub(r"[\W_]", " ", normalized_name) # No non-word characters normalized_name = re.sub(" +", " ", normalized_name).strip() # No double spaces, leading or trailing spaces if re.match(r"\d", normalized_name): normalized_name = "n" + normalized_name # No leading digits return normalized_name def _sanitize_python_variable_name(name: str): return _normalize_identifier_name(name).replace(" ", "_") def _get_additional_includes(yaml_path): flow_dag = load_yaml(yaml_path) return flow_dag.get("additional_includes", []) def _is_folder_to_compress(path: Path) -> bool: """Check if the additional include needs to compress corresponding folder as a zip. For example, given additional include /mnt/c/hello.zip 1) if a file named /mnt/c/hello.zip already exists, return False (simply copy) 2) if a folder named /mnt/c/hello exists, return True (compress as a zip and copy) :param path: Given path in additional include. :type path: Path :return: If the path need to be compressed as a zip file. :rtype: bool """ if path.suffix != ".zip": return False # if zip file exists, simply copy as other additional includes if path.exists(): return False # remove .zip suffix and check whether the folder exists stem_path = path.parent / path.stem return stem_path.is_dir() def _resolve_folder_to_compress(base_path: Path, include: str, dst_path: Path) -> None: """resolve the zip additional include, need to compress corresponding folder.""" zip_additional_include = (base_path / include).resolve() folder_to_zip = zip_additional_include.parent / zip_additional_include.stem zip_file = dst_path / zip_additional_include.name with zipfile.ZipFile(zip_file, "w") as zf: zf.write(folder_to_zip, os.path.relpath(folder_to_zip, folder_to_zip.parent)) # write root in zip for root, _, files in os.walk(folder_to_zip, followlinks=True): for file in files: file_path = os.path.join(folder_to_zip, file) zf.write(file_path, os.path.relpath(file_path, folder_to_zip.parent)) @contextmanager def _merge_local_code_and_additional_includes(code_path: Path): # TODO: unify variable names: flow_dir_path, flow_dag_path, flow_path def additional_includes_copy(src, relative_path, target_dir): if src.is_file(): dst = Path(target_dir) / relative_path dst.parent.mkdir(parents=True, exist_ok=True) if dst.exists(): logger.warning( "Found duplicate file in additional includes, " f"additional include file {src} will overwrite {relative_path}" ) shutil.copy2(src, dst) else: for name in src.glob("*"): additional_includes_copy(name, Path(relative_path) / name.name, target_dir) if code_path.is_dir(): yaml_path = (Path(code_path) / DAG_FILE_NAME).resolve() code_path = code_path.resolve() else: yaml_path = code_path.resolve() code_path = code_path.parent.resolve() with tempfile.TemporaryDirectory() as temp_dir: shutil.copytree(code_path.resolve().as_posix(), temp_dir, dirs_exist_ok=True) for item in _get_additional_includes(yaml_path): src_path = Path(item) if not src_path.is_absolute(): src_path = (code_path / item).resolve() if _is_folder_to_compress(src_path): _resolve_folder_to_compress(code_path, item, Path(temp_dir)) # early continue as the folder is compressed as a zip file continue if not src_path.exists(): error = ValueError(f"Unable to find additional include {item}") raise UserErrorException( target=ErrorTarget.CONTROL_PLANE_SDK, message=str(error), error=error, ) additional_includes_copy(src_path, relative_path=src_path.name, target_dir=temp_dir) yield temp_dir def incremental_print(log: str, printed: int, fileout) -> int: count = 0 for line in log.splitlines(): if count >= printed: fileout.write(line + "\n") printed += 1 count += 1 return printed def get_promptflow_sdk_version() -> str: try: return promptflow.__version__ except AttributeError: # if promptflow is installed from source, it does not have __version__ attribute return "0.0.1" def print_pf_version(): print("promptflow\t\t\t {}".format(get_promptflow_sdk_version())) print() print("Executable '{}'".format(os.path.abspath(sys.executable))) print("Python ({}) {}".format(platform.system(), sys.version)) class PromptflowIgnoreFile(IgnoreFile): # TODO add more files to this list. IGNORE_FILE = [".runs", "__pycache__"] def __init__(self, prompt_flow_path: Union[Path, str]): super(PromptflowIgnoreFile, self).__init__(prompt_flow_path) self._path = Path(prompt_flow_path) self._ignore_tools_json = False @property def base_path(self) -> Path: return self._path def _get_ignore_list(self): """Get ignore list from ignore file contents.""" if not self.exists(): return [] base_ignore = get_ignore_file(self.base_path) result = self.IGNORE_FILE + base_ignore._get_ignore_list() if self._ignore_tools_json: result.append(f"{PROMPT_FLOW_DIR_NAME}/{FLOW_TOOLS_JSON}") return result def _generate_meta_from_files( tools: List[Tuple[str, str]], flow_directory: Path, tools_dict: dict, exception_dict: dict ) -> None: with _change_working_dir(flow_directory), inject_sys_path(flow_directory): for source, tool_type in tools: try: tools_dict[source] = generate_tool_meta_dict_by_file(source, ToolType(tool_type)) except Exception as e: exception_dict[source] = str(e) def _generate_tool_meta( flow_directory: Path, tools: List[Tuple[str, str]], raise_error: bool, timeout: int, *, include_errors_in_output: bool = False, load_in_subprocess: bool = True, ) -> Dict[str, dict]: """Generate tool meta from files. :param flow_directory: flow directory :param tools: tool list :param raise_error: whether raise error when generate meta failed :param timeout: timeout for generate meta :param include_errors_in_output: whether include errors in output :param load_in_subprocess: whether load tool meta with subprocess to prevent system path disturb. Default is True. If set to False, will load tool meta in sync mode and timeout need to be handled outside current process. :return: tool meta dict """ if load_in_subprocess: # use multiprocess generate to avoid system path disturb manager = multiprocessing.Manager() tools_dict = manager.dict() exception_dict = manager.dict() p = multiprocessing.Process( target=_generate_meta_from_files, args=(tools, flow_directory, tools_dict, exception_dict) ) p.start() p.join(timeout=timeout) if p.is_alive(): logger.warning(f"Generate meta timeout after {timeout} seconds, terminate the process.") p.terminate() p.join() else: tools_dict, exception_dict = {}, {} # There is no built-in method to forcefully stop a running thread/coroutine in Python # because abruptly stopping a thread can cause issues like resource leaks, # deadlocks, or inconsistent states. # Caller needs to handle the timeout outside current process. logger.warning( "Generate meta in current process and timeout won't take effect. " "Please handle timeout manually outside current process." ) _generate_meta_from_files(tools, flow_directory, tools_dict, exception_dict) res = {source: tool for source, tool in tools_dict.items()} for source in res: # remove name in tool meta res[source].pop("name") # convert string Enum to string if isinstance(res[source]["type"], Enum): res[source]["type"] = res[source]["type"].value # not all tools have inputs, so check first if "inputs" in res[source]: for tool_input in res[source]["inputs"]: tool_input_type = res[source]["inputs"][tool_input]["type"] for i in range(len(tool_input_type)): if isinstance(tool_input_type[i], Enum): tool_input_type[i] = tool_input_type[i].value # collect errors and print warnings errors = { source: exception for source, exception in exception_dict.items() } # for not processed tools, regard as timeout error for source, _ in tools: if source not in res and source not in errors: errors[source] = f"Generate meta timeout for source {source!r}." for source in errors: if include_errors_in_output: res[source] = errors[source] else: logger.warning(f"Generate meta for source {source!r} failed: {errors[source]}.") if raise_error and len(errors) > 0: error_message = "Generate meta failed, detail error(s):\n" + json.dumps(errors, indent=4) raise GenerateFlowToolsJsonError(error_message) return res def _retrieve_tool_func_result(func_call_scenario: str, function_config: Dict): """Retrieve tool func result according to func_call_scenario. :param func_call_scenario: function call scenario :param function_config: function config in tool meta. Should contain'func_path' and 'func_kwargs'. :return: func call result according to func_call_scenario. """ func_path = function_config.get("func_path", "") func_kwargs = function_config.get("func_kwargs", {}) # May call azure control plane api in the custom function to list Azure resources. # which may need Azure workspace triple. # TODO: move this method to a common place. from promptflow._cli._utils import get_workspace_triad_from_local workspace_triad = get_workspace_triad_from_local() if workspace_triad.subscription_id and workspace_triad.resource_group_name and workspace_triad.workspace_name: result = retrieve_tool_func_result(func_call_scenario, func_path, func_kwargs, workspace_triad._asdict()) # if no workspace triple available, just skip. else: result = retrieve_tool_func_result(func_call_scenario, func_path, func_kwargs) result_with_log = {"result": result, "logs": {}} return result_with_log def _gen_dynamic_list(function_config: Dict) -> List: """Generate dynamic list for a tool input. :param function_config: function config in tool meta. Should contain'func_path' and 'func_kwargs'. :return: a list of tool input dynamic enums. """ func_path = function_config.get("func_path", "") func_kwargs = function_config.get("func_kwargs", {}) # May call azure control plane api in the custom function to list Azure resources. # which may need Azure workspace triple. # TODO: move this method to a common place. from promptflow._cli._utils import get_workspace_triad_from_local workspace_triad = get_workspace_triad_from_local() if workspace_triad.subscription_id and workspace_triad.resource_group_name and workspace_triad.workspace_name: return gen_dynamic_list(func_path, func_kwargs, workspace_triad._asdict()) # if no workspace triple available, just skip. else: return gen_dynamic_list(func_path, func_kwargs) def _generate_package_tools(keys: Optional[List[str]] = None) -> dict: from promptflow._core.tools_manager import collect_package_tools return collect_package_tools(keys=keys) def _update_involved_tools_and_packages( _node, _node_path, *, tools: List, used_packages: Set, source_path_mapping: Dict[str, List[str]], ): source, tool_type = pydash.get(_node, "source.path", None), _node.get("type", None) used_packages.add(pydash.get(_node, "source.tool", None)) if source is None or tool_type is None: return # for custom LLM tool, its source points to the used prompt template so handle it as prompt tool if tool_type == ToolType.CUSTOM_LLM: tool_type = ToolType.PROMPT if pydash.get(_node, "source.type") not in ["code", "package_with_prompt"]: return pair = (source, tool_type.lower()) if pair not in tools: tools.append(pair) source_path_mapping[source].append(f"{_node_path}.source.path") def _get_involved_code_and_package( data: dict, ) -> Tuple[List[Tuple[str, str]], Set[str], Dict[str, List[str]]]: tools = [] # List[Tuple[source_file, tool_type]] used_packages = set() source_path_mapping = collections.defaultdict(list) for node_i, node in enumerate(data[NODES]): _update_involved_tools_and_packages( node, f"{NODES}.{node_i}", tools=tools, used_packages=used_packages, source_path_mapping=source_path_mapping, ) # understand DAG to parse variants # TODO: should we allow source to appear both in node and node variants? if node.get(USE_VARIANTS) is True: node_variants = data[NODE_VARIANTS][node["name"]] for variant_id in node_variants[VARIANTS]: node_with_variant = node_variants[VARIANTS][variant_id][NODE] _update_involved_tools_and_packages( node_with_variant, f"{NODE_VARIANTS}.{node['name']}.{VARIANTS}.{variant_id}.{NODE}", tools=tools, used_packages=used_packages, source_path_mapping=source_path_mapping, ) if None in used_packages: used_packages.remove(None) return tools, used_packages, source_path_mapping def generate_flow_tools_json( flow_directory: Union[str, Path], dump: bool = True, raise_error: bool = True, timeout: int = FLOW_TOOLS_JSON_GEN_TIMEOUT, *, include_errors_in_output: bool = False, target_source: str = None, used_packages_only: bool = False, source_path_mapping: Dict[str, List[str]] = None, ) -> dict: """Generate flow.tools.json for a flow directory. :param flow_directory: path to flow directory. :param dump: whether to dump to .promptflow/flow.tools.json, default value is True. :param raise_error: whether to raise the error, default value is True. :param timeout: timeout for generation, default value is 60 seconds. :param include_errors_in_output: whether to include error messages in output, default value is False. :param target_source: the source name to filter result, default value is None. Note that we will update system path in coroutine if target_source is provided given it's expected to be from a specific cli call. :param used_packages_only: whether to only include used packages, default value is False. :param source_path_mapping: if specified, record yaml paths for each source. """ flow_directory = Path(flow_directory).resolve() # parse flow DAG data = load_yaml(flow_directory / DAG_FILE_NAME) tools, used_packages, _source_path_mapping = _get_involved_code_and_package(data) # update passed in source_path_mapping if specified if source_path_mapping is not None: source_path_mapping.update(_source_path_mapping) # filter tools by target_source if specified if target_source is not None: tools = list(filter(lambda x: x[0] == target_source, tools)) # generate content # TODO: remove type in tools (input) and code (output) flow_tools = { "code": _generate_tool_meta( flow_directory, tools, raise_error=raise_error, timeout=timeout, include_errors_in_output=include_errors_in_output, # we don't need to protect system path according to the target usage when target_source is specified load_in_subprocess=target_source is None, ), # specified source may only appear in code tools "package": {} if target_source is not None else _generate_package_tools(keys=list(used_packages) if used_packages_only else None), } if dump: # dump as flow.tools.json promptflow_folder = flow_directory / PROMPT_FLOW_DIR_NAME promptflow_folder.mkdir(exist_ok=True) with open(promptflow_folder / FLOW_TOOLS_JSON, mode="w", encoding=DEFAULT_ENCODING) as f: json.dump(flow_tools, f, indent=4) return flow_tools class ClientUserAgentUtil: """SDK/CLI side user agent utilities.""" @classmethod def _get_context(cls): from promptflow._core.operation_context import OperationContext return OperationContext.get_instance() @classmethod def get_user_agent(cls): from promptflow._core.operation_context import OperationContext context = cls._get_context() # directly get from context since client side won't need promptflow/xxx. return context.get(OperationContext.USER_AGENT_KEY, "").strip() @classmethod def append_user_agent(cls, user_agent: Optional[str]): if not user_agent: return context = cls._get_context() context.append_user_agent(user_agent) @classmethod def update_user_agent_from_env_var(cls): # this is for backward compatibility: we should use PF_USER_AGENT in newer versions. for env_name in [USER_AGENT, PF_USER_AGENT]: if env_name in os.environ: cls.append_user_agent(os.environ[env_name]) @classmethod def update_user_agent_from_config(cls): """Update user agent from config. 1p customer will set it. We'll add PFCustomer_ as prefix.""" from promptflow._sdk._configuration import Configuration config = Configuration.get_instance() user_agent = config.get_user_agent() if user_agent: cls.append_user_agent(user_agent) def setup_user_agent_to_operation_context(user_agent): """Setup user agent to OperationContext. For calls from extension, ua will be like: prompt-flow-extension/ promptflow-cli/ promptflow-sdk/ For calls from CLI, ua will be like: promptflow-cli/ promptflow-sdk/ For calls from SDK, ua will be like: promptflow-sdk/ For 1p customer call which set user agent in config, ua will be like: PFCustomer_XXX/ """ # add user added UA after SDK/CLI ClientUserAgentUtil.append_user_agent(user_agent) ClientUserAgentUtil.update_user_agent_from_env_var() ClientUserAgentUtil.update_user_agent_from_config() return ClientUserAgentUtil.get_user_agent() def call_from_extension() -> bool: """Return true if current request is from extension.""" ClientUserAgentUtil.update_user_agent_from_env_var() user_agent = ClientUserAgentUtil.get_user_agent() return EXTENSION_UA in user_agent def generate_random_string(length: int = 6) -> str: import random import string return "".join(random.choice(string.ascii_lowercase) for _ in range(length)) def copy_tree_respect_template_and_ignore_file(source: Path, target: Path, render_context: dict = None): def is_template(path: str): return path.endswith(".jinja2") for source_path, target_path in get_upload_files_from_folder( path=source, ignore_file=PromptflowIgnoreFile(prompt_flow_path=source), ): (target / target_path).parent.mkdir(parents=True, exist_ok=True) if render_context is None or not is_template(source_path): shutil.copy(source_path, target / target_path) else: (target / target_path[: -len(".jinja2")]).write_bytes( # always use unix line ending render_jinja_template(source_path, **render_context) .encode("utf-8") .replace(b"\r\n", b"\n"), ) def get_local_connections_from_executable( executable, client, connections_to_ignore: List[str] = None, connections_to_add: List[str] = None ): """Get local connections from executable. executable: The executable flow object. client: Local client to get connections. connections_to_ignore: The connection names to ignore when getting connections. connections_to_add: The connection names to add when getting connections. """ connection_names = executable.get_connection_names() if connections_to_add: connection_names.update(connections_to_add) connections_to_ignore = connections_to_ignore or [] result = {} for n in connection_names: if n not in connections_to_ignore: conn = client.connections.get(name=n, with_secrets=True) result[n] = conn._to_execution_connection_dict() return result def _generate_connections_dir(): # Get Python executable path python_path = sys.executable # Hash the Python executable path hash_object = hashlib.sha1(python_path.encode()) hex_dig = hash_object.hexdigest() # Generate the connections system path using the hash connections_dir = (HOME_PROMPT_FLOW_DIR / "envs" / hex_dig / "connections").resolve() return connections_dir _refresh_connection_dir_lock = FileLock(REFRESH_CONNECTIONS_DIR_LOCK_PATH) # This function is used by extension to generate the connection files every time collect tools. def refresh_connections_dir(connection_spec_files, connection_template_yamls): connections_dir = _generate_connections_dir() # Use lock to prevent concurrent access with _refresh_connection_dir_lock: if os.path.isdir(connections_dir): shutil.rmtree(connections_dir) os.makedirs(connections_dir) if connection_spec_files and connection_template_yamls: for connection_name, content in connection_spec_files.items(): file_name = connection_name + ".spec.json" with open(connections_dir / file_name, "w", encoding=DEFAULT_ENCODING) as f: json.dump(content, f, indent=2) # use YAML to dump template file in order to keep the comments for connection_name, content in connection_template_yamls.items(): yaml_data = load_yaml_string(content) file_name = connection_name + ".template.yaml" with open(connections_dir / file_name, "w", encoding=DEFAULT_ENCODING) as f: dump_yaml(yaml_data, f) def dump_flow_result(flow_folder, prefix, flow_result=None, node_result=None, custom_path=None): """Dump flow result for extension. :param flow_folder: The flow folder. :param prefix: The file prefix. :param flow_result: The flow result returned by exec_line. :param node_result: The node result when test node returned by load_and_exec_node. :param custom_path: The custom path to dump flow result. """ if flow_result: flow_serialize_result = { "flow_runs": [serialize(flow_result.run_info)], "node_runs": [serialize(run) for run in flow_result.node_run_infos.values()], } else: flow_serialize_result = { "flow_runs": [], "node_runs": [serialize(node_result)], } dump_folder = Path(flow_folder) / PROMPT_FLOW_DIR_NAME if custom_path is None else Path(custom_path) dump_folder.mkdir(parents=True, exist_ok=True) with open(dump_folder / f"{prefix}.detail.json", "w", encoding=DEFAULT_ENCODING) as f: json.dump(flow_serialize_result, f, indent=2, ensure_ascii=False) if node_result: metrics = flow_serialize_result["node_runs"][0]["metrics"] output = flow_serialize_result["node_runs"][0]["output"] else: metrics = flow_serialize_result["flow_runs"][0]["metrics"] output = flow_serialize_result["flow_runs"][0]["output"] if metrics: with open(dump_folder / f"{prefix}.metrics.json", "w", encoding=DEFAULT_ENCODING) as f: json.dump(metrics, f, indent=2, ensure_ascii=False) if output: with open(dump_folder / f"{prefix}.output.json", "w", encoding=DEFAULT_ENCODING) as f: json.dump(output, f, indent=2, ensure_ascii=False) def read_write_by_user(): return stat.S_IRUSR | stat.S_IWUSR def remove_empty_element_from_dict(obj: dict) -> dict: """Remove empty element from dict, e.g. {"a": 1, "b": {}} -> {"a": 1}""" new_dict = {} for key, value in obj.items(): if isinstance(value, dict): value = remove_empty_element_from_dict(value) if value is not None: new_dict[key] = value return new_dict def is_github_codespaces(): # Ref: # https://docs.github.com/en/codespaces/developing-in-a-codespace/default-environment-variables-for-your-codespace return os.environ.get("CODESPACES", None) == "true" def interactive_credential_disabled(): return os.environ.get(PF_NO_INTERACTIVE_LOGIN, "false").lower() == "true" def is_from_cli(): from promptflow._cli._user_agent import USER_AGENT as CLI_UA return CLI_UA in ClientUserAgentUtil.get_user_agent() def is_url(value: Union[PathLike, str]) -> bool: try: result = urlparse(str(value)) return all([result.scheme, result.netloc]) except ValueError: return False def is_remote_uri(obj) -> bool: # return True if it's supported remote uri if isinstance(obj, str): if obj.startswith(REMOTE_URI_PREFIX): # azureml: started, azureml:name:version, azureml://xxx return True elif is_url(obj): return True return False def parse_remote_flow_pattern(flow: object) -> str: # Check if the input matches the correct pattern flow_name = None error_message = ( f"Invalid remote flow pattern, got {flow!r} while expecting " f"a remote workspace flow like '{REMOTE_URI_PREFIX}<flow-name>', or a remote registry flow like " f"'{REMOTE_URI_PREFIX}//registries/<registry-name>/models/<flow-name>/versions/<version>'" ) if not isinstance(flow, str) or not flow.startswith(REMOTE_URI_PREFIX): raise UserErrorException(error_message) # check for registry flow pattern if flow.startswith(REGISTRY_URI_PREFIX): pattern = r"azureml://registries/.*?/models/(?P<name>.*?)/versions/(?P<version>.*?)$" match = re.match(pattern, flow) if not match or len(match.groups()) != 2: raise UserErrorException(error_message) flow_name, _ = match.groups() # check for workspace flow pattern elif flow.startswith(REMOTE_URI_PREFIX): pattern = r"azureml:(?P<name>.*?)$" match = re.match(pattern, flow) if not match or len(match.groups()) != 1: raise UserErrorException(error_message) flow_name = match.groups()[0] return flow_name def get_connection_operation(connection_provider: str, credential=None, user_agent: str = None): """ Get connection operation based on connection provider. This function will be called by PFClient, so please do not refer to PFClient in this function. :param connection_provider: Connection provider, e.g. local, azureml, azureml://subscriptions..., etc. :type connection_provider: str :param credential: Credential when remote provider, default to chained credential DefaultAzureCredential. :type credential: object :param user_agent: User Agent :type user_agent: str """ if connection_provider == ConnectionProvider.LOCAL.value: from promptflow._sdk.operations._connection_operations import ConnectionOperations logger.debug("PFClient using local connection operations.") connection_operation = ConnectionOperations() elif connection_provider.startswith(ConnectionProvider.AZUREML.value): from promptflow._sdk.operations._local_azure_connection_operations import LocalAzureConnectionOperations logger.debug(f"PFClient using local azure connection operations with credential {credential}.") if user_agent is None: connection_operation = LocalAzureConnectionOperations(connection_provider, credential=credential) else: connection_operation = LocalAzureConnectionOperations(connection_provider, user_agent=user_agent) else: error = ValueError(f"Unsupported connection provider: {connection_provider}") raise UserErrorException( target=ErrorTarget.CONTROL_PLANE_SDK, message=str(error), error=error, ) return connection_operation # extract open read/write as partial to centralize the encoding read_open = partial(open, mode="r", encoding=DEFAULT_ENCODING) write_open = partial(open, mode="w", encoding=DEFAULT_ENCODING) # extract some file operations inside this file def json_load(file) -> str: with read_open(file) as f: return json.load(f) def json_dump(obj, file) -> None: with write_open(file) as f: json.dump(obj, f, ensure_ascii=False) def pd_read_json(file) -> "DataFrame": import pandas as pd with read_open(file) as f: return pd.read_json(f, orient="records", lines=True)
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_visualize_functions.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import shutil import tempfile import webbrowser from dataclasses import asdict from pathlib import Path from typing import Optional from promptflow._sdk._constants import VIS_HTML_TMPL, VIS_JS_BUNDLE_FILENAME from promptflow._sdk._utils import render_jinja_template from promptflow.contracts._run_management import VisualizationRender def generate_html_string(data: dict) -> str: visualization_render = VisualizationRender(data=data) return render_jinja_template(VIS_HTML_TMPL, **asdict(visualization_render)) def try_to_open_html(html_path: str) -> None: print(f"The HTML file is generated at {str(Path(html_path).resolve().absolute())!r}.") print("Trying to view the result in a web browser...") web_browser_opened = False web_browser_opened = webbrowser.open(f"file://{html_path}") if not web_browser_opened: print( f"Failed to visualize from the web browser, the HTML file locates at {html_path!r}.\n" "You can manually open it with your web browser, or try SDK to visualize it." ) else: print("Successfully visualized from the web browser.") def dump_js_bundle(html_path: str) -> None: js_bundle_src_path = Path(__file__).parent / "data" / VIS_JS_BUNDLE_FILENAME js_bundle_dst_path = Path(html_path).parent / VIS_JS_BUNDLE_FILENAME shutil.copy(js_bundle_src_path, js_bundle_dst_path) def dump_html(html_string: str, html_path: Optional[str] = None, open_html: bool = True) -> None: if html_path is not None: with open(html_path, "w") as f: f.write(html_string) else: with tempfile.NamedTemporaryFile(prefix="pf-visualize-detail-", suffix=".html", delete=False) as f: f.write(html_string.encode("utf-8")) html_path = f.name dump_js_bundle(html_path) if open_html: try_to_open_html(html_path)
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_configuration.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import logging import os.path import uuid from itertools import product from os import PathLike from pathlib import Path from typing import Optional, Union import pydash from promptflow._sdk._constants import ( DEFAULT_ENCODING, FLOW_DIRECTORY_MACRO_IN_CONFIG, HOME_PROMPT_FLOW_DIR, SERVICE_CONFIG_FILE, ConnectionProvider, ) from promptflow._sdk._utils import call_from_extension, read_write_by_user from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow._utils.yaml_utils import dump_yaml, load_yaml from promptflow.exceptions import ErrorTarget, ValidationException logger = get_cli_sdk_logger() class ConfigFileNotFound(ValidationException): pass class InvalidConfigFile(ValidationException): pass class InvalidConfigValue(ValidationException): pass class Configuration(object): CONFIG_PATH = Path(HOME_PROMPT_FLOW_DIR) / SERVICE_CONFIG_FILE COLLECT_TELEMETRY = "telemetry.enabled" EXTENSION_COLLECT_TELEMETRY = "extension.telemetry_enabled" INSTALLATION_ID = "cli.installation_id" CONNECTION_PROVIDER = "connection.provider" RUN_OUTPUT_PATH = "run.output_path" USER_AGENT = "user_agent" ENABLE_INTERNAL_FEATURES = "enable_internal_features" _instance = None def __init__(self, overrides=None): if not os.path.exists(self.CONFIG_PATH.parent): os.makedirs(self.CONFIG_PATH.parent, exist_ok=True) if not os.path.exists(self.CONFIG_PATH): self.CONFIG_PATH.touch(mode=read_write_by_user(), exist_ok=True) with open(self.CONFIG_PATH, "w", encoding=DEFAULT_ENCODING) as f: dump_yaml({}, f) self._config = load_yaml(self.CONFIG_PATH) if not self._config: self._config = {} # Allow config override by kwargs overrides = overrides or {} for key, value in overrides.items(): self._validate(key, value) pydash.set_(self._config, key, value) @property def config(self): return self._config @classmethod def get_instance(cls): """Use this to get instance to avoid multiple copies of same global config.""" if cls._instance is None: cls._instance = Configuration() return cls._instance def set_config(self, key, value): """Store config in file to avoid concurrent write.""" self._validate(key, value) pydash.set_(self._config, key, value) with open(self.CONFIG_PATH, "w", encoding=DEFAULT_ENCODING) as f: dump_yaml(self._config, f) def get_config(self, key): try: return pydash.get(self._config, key, None) except Exception: # pylint: disable=broad-except return None def get_all(self): return self._config @classmethod def _get_workspace_from_config( cls, *, path: Union[PathLike, str] = None, ) -> str: """Return a workspace arm id from an existing Azure Machine Learning Workspace. Reads workspace configuration from a file. Throws an exception if the config file can't be found. :param path: The path to the config file or starting directory to search. The parameter defaults to starting the search in the current directory. :type path: str :return: The workspace arm id for an existing Azure ML Workspace. :rtype: ~str """ from azure.ai.ml import MLClient from azure.ai.ml._file_utils.file_utils import traverse_up_path_and_find_file from azure.ai.ml.constants._common import AZUREML_RESOURCE_PROVIDER, RESOURCE_ID_FORMAT path = Path(".") if path is None else Path(path) if path.is_file(): found_path = path else: # Based on priority # Look in config dirs like .azureml or plain directory # with None directories_to_look = [".azureml", None] files_to_look = ["config.json"] found_path = None for curr_dir, curr_file in product(directories_to_look, files_to_look): logging.debug( "No config file directly found, starting search from %s " "directory, for %s file name to be present in " "%s subdirectory", path, curr_file, curr_dir, ) found_path = traverse_up_path_and_find_file( path=path, file_name=curr_file, directory_name=curr_dir, num_levels=20, ) if found_path: break if not found_path: msg = ( "We could not find config.json in: {} or in its parent directories. " "Please provide the full path to the config file or ensure that " "config.json exists in the parent directories." ) raise ConfigFileNotFound( message=msg.format(path), no_personal_data_message=msg.format("[path]"), target=ErrorTarget.CONTROL_PLANE_SDK, ) subscription_id, resource_group, workspace_name = MLClient._get_workspace_info(found_path) if not (subscription_id and resource_group and workspace_name): raise InvalidConfigFile( "The subscription_id, resource_group and workspace_name can not be empty. Got: " f"subscription_id: {subscription_id}, resource_group: {resource_group}, " f"workspace_name: {workspace_name} from file {found_path}." ) return RESOURCE_ID_FORMAT.format(subscription_id, resource_group, AZUREML_RESOURCE_PROVIDER, workspace_name) def get_connection_provider(self, path=None) -> Optional[str]: """Get the current connection provider. Default to local if not configured.""" provider = self.get_config(key=self.CONNECTION_PROVIDER) return self.resolve_connection_provider(provider, path=path) @classmethod def resolve_connection_provider(cls, provider, path=None) -> Optional[str]: if provider is None: return ConnectionProvider.LOCAL if provider == ConnectionProvider.AZUREML.value: # Note: The below function has azure-ai-ml dependency. return "azureml:" + cls._get_workspace_from_config(path=path) # If provider not None and not Azure, return it directly. # It can be the full path of a workspace. return provider def get_telemetry_consent(self) -> Optional[bool]: """Get the current telemetry consent value. Return None if not configured.""" if call_from_extension(): return self.get_config(key=self.EXTENSION_COLLECT_TELEMETRY) return self.get_config(key=self.COLLECT_TELEMETRY) def set_telemetry_consent(self, value): """Set the telemetry consent value and store in local.""" self.set_config(key=self.COLLECT_TELEMETRY, value=value) def get_or_set_installation_id(self): """Get user id if exists, otherwise set installation id and return it.""" user_id = self.get_config(key=self.INSTALLATION_ID) if user_id: return user_id else: user_id = str(uuid.uuid4()) self.set_config(key=self.INSTALLATION_ID, value=user_id) return user_id def get_run_output_path(self) -> Optional[str]: """Get the run output path in local.""" return self.get_config(key=self.RUN_OUTPUT_PATH) def _to_dict(self): return self._config @staticmethod def _validate(key: str, value: str) -> None: if key == Configuration.RUN_OUTPUT_PATH: if value.rstrip("/").endswith(FLOW_DIRECTORY_MACRO_IN_CONFIG): raise InvalidConfigValue( "Cannot specify flow directory as run output path; " "if you want to specify run output path under flow directory, " "please use its child folder, e.g. '${flow_directory}/.runs'." ) return def get_user_agent(self) -> Optional[str]: """Get customer set user agent. If set, will add prefix `PFCustomer_`""" user_agent = self.get_config(key=self.USER_AGENT) if user_agent: return f"PFCustomer_{user_agent}" return user_agent def is_internal_features_enabled(self) -> Optional[bool]: """Get enable_preview_features""" result = self.get_config(key=self.ENABLE_INTERNAL_FEATURES) if isinstance(result, str): return result.lower() == "true" return result is True
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_pf_client.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import os from os import PathLike from pathlib import Path from typing import Any, Dict, List, Union from .._utils.logger_utils import get_cli_sdk_logger from ._configuration import Configuration from ._constants import MAX_SHOW_DETAILS_RESULTS from ._load_functions import load_flow from ._user_agent import USER_AGENT from ._utils import ClientUserAgentUtil, get_connection_operation, setup_user_agent_to_operation_context from .entities import Run from .entities._eager_flow import EagerFlow from .operations import RunOperations from .operations._connection_operations import ConnectionOperations from .operations._experiment_operations import ExperimentOperations from .operations._flow_operations import FlowOperations from .operations._tool_operations import ToolOperations logger = get_cli_sdk_logger() def _create_run(run: Run, **kwargs): client = PFClient() return client.runs.create_or_update(run=run, **kwargs) class PFClient: """A client class to interact with prompt flow entities.""" def __init__(self, **kwargs): logger.debug("PFClient init with kwargs: %s", kwargs) self._runs = RunOperations() self._connection_provider = kwargs.pop("connection_provider", None) self._config = kwargs.get("config", None) or {} # The credential is used as an option to override # DefaultAzureCredential when using workspace connection provider self._credential = kwargs.get("credential", None) # Lazy init to avoid azure credential requires too early self._connections = None self._flows = FlowOperations(client=self) self._tools = ToolOperations() # add user agent from kwargs if any if isinstance(kwargs.get("user_agent"), str): ClientUserAgentUtil.append_user_agent(kwargs["user_agent"]) self._experiments = ExperimentOperations(self) setup_user_agent_to_operation_context(USER_AGENT) def run( self, flow: Union[str, PathLike], *, data: Union[str, PathLike] = None, run: Union[str, Run] = None, column_mapping: dict = None, variant: str = None, connections: dict = None, environment_variables: dict = None, name: str = None, display_name: str = None, tags: Dict[str, str] = None, **kwargs, ) -> Run: """Run flow against provided data or run. .. note:: At least one of the ``data`` or ``run`` parameters must be provided. .. admonition:: Column_mapping Column mapping is a mapping from flow input name to specified values. If specified, the flow will be executed with provided value for specified inputs. The value can be: - from data: - ``data.col1`` - from run: - ``run.inputs.col1``: if need reference run's inputs - ``run.output.col1``: if need reference run's outputs - Example: - ``{"ground_truth": "${data.answer}", "prediction": "${run.outputs.answer}"}`` :param flow: Path to the flow directory to run evaluation. :type flow: Union[str, PathLike] :param data: Pointer to the test data (of variant bulk runs) for eval runs. :type data: Union[str, PathLike] :param run: Flow run ID or flow run. This parameter helps keep lineage between the current run and variant runs. Batch outputs can be referenced as ``${run.outputs.col_name}`` in inputs_mapping. :type run: Union[str, ~promptflow.entities.Run] :param column_mapping: Define a data flow logic to map input data. :type column_mapping: Dict[str, str] :param variant: Node & variant name in the format of ``${node_name.variant_name}``. The default variant will be used if not specified. :type variant: str :param connections: Overwrite node level connections with provided values. Example: ``{"node1": {"connection": "new_connection", "deployment_name": "gpt-35-turbo"}}`` :type connections: Dict[str, Dict[str, str]] :param environment_variables: Environment variables to set by specifying a property path and value. Example: ``{"key1": "${my_connection.api_key}", "key2"="value2"}`` The value reference to connection keys will be resolved to the actual value, and all environment variables specified will be set into os.environ. :type environment_variables: Dict[str, str] :param name: Name of the run. :type name: str :param display_name: Display name of the run. :type display_name: str :param tags: Tags of the run. :type tags: Dict[str, str] :return: Flow run info. :rtype: ~promptflow.entities.Run """ if not os.path.exists(flow): raise FileNotFoundError(f"flow path {flow} does not exist") if data and not os.path.exists(data): raise FileNotFoundError(f"data path {data} does not exist") if not run and not data: raise ValueError("at least one of data or run must be provided") # TODO(2901096): Support pf run with python file, maybe create a temp flow.dag.yaml in this case # load flow object for validation and early failure flow_obj = load_flow(source=flow) # validate param conflicts if isinstance(flow_obj, EagerFlow): if variant or connections: logger.warning("variant and connections are not supported for eager flow, will be ignored") variant, connections = None, None run = Run( name=name, display_name=display_name, tags=tags, data=data, column_mapping=column_mapping, run=run, variant=variant, flow=Path(flow), connections=connections, environment_variables=environment_variables, config=Configuration(overrides=self._config), ) return self.runs.create_or_update(run=run, **kwargs) def stream(self, run: Union[str, Run], raise_on_error: bool = True) -> Run: """Stream run logs to the console. :param run: Run object or name of the run. :type run: Union[str, ~promptflow.sdk.entities.Run] :param raise_on_error: Raises an exception if a run fails or canceled. :type raise_on_error: bool :return: flow run info. :rtype: ~promptflow.sdk.entities.Run """ return self.runs.stream(run, raise_on_error) def get_details( self, run: Union[str, Run], max_results: int = MAX_SHOW_DETAILS_RESULTS, all_results: bool = False ) -> "DataFrame": """Get the details from the run including inputs and outputs. .. note:: If `all_results` is set to True, `max_results` will be overwritten to sys.maxsize. :param run: The run name or run object :type run: Union[str, ~promptflow.sdk.entities.Run] :param max_results: The max number of runs to return, defaults to 100 :type max_results: int :param all_results: Whether to return all results, defaults to False :type all_results: bool :raises RunOperationParameterError: If `max_results` is not a positive integer. :return: The details data frame. :rtype: pandas.DataFrame """ return self.runs.get_details(name=run, max_results=max_results, all_results=all_results) def get_metrics(self, run: Union[str, Run]) -> Dict[str, Any]: """Get run metrics. :param run: Run object or name of the run. :type run: Union[str, ~promptflow.sdk.entities.Run] :return: Run metrics. :rtype: Dict[str, Any] """ return self.runs.get_metrics(run) def visualize(self, runs: Union[List[str], List[Run]]) -> None: """Visualize run(s). :param run: Run object or name of the run. :type run: Union[str, ~promptflow.sdk.entities.Run] """ self.runs.visualize(runs) @property def runs(self) -> RunOperations: """Run operations that can manage runs.""" return self._runs @property def tools(self) -> ToolOperations: """Tool operations that can manage tools.""" return self._tools def _ensure_connection_provider(self) -> str: if not self._connection_provider: # Get a copy with config override instead of the config instance self._connection_provider = Configuration(overrides=self._config).get_connection_provider() logger.debug("PFClient connection provider: %s", self._connection_provider) return self._connection_provider @property def connections(self) -> ConnectionOperations: """Connection operations that can manage connections.""" if not self._connections: self._ensure_connection_provider() self._connections = get_connection_operation(self._connection_provider, self._credential) return self._connections @property def flows(self) -> FlowOperations: """Operations on the flow that can manage flows.""" return self._flows def test( self, flow: Union[str, PathLike], *, inputs: dict = None, variant: str = None, node: str = None, environment_variables: dict = None, ) -> dict: """Test flow or node. :param flow: path to flow directory to test :type flow: Union[str, PathLike] :param inputs: Input data for the flow test :type inputs: dict :param variant: Node & variant name in format of ${node_name.variant_name}, will use default variant if not specified. :type variant: str :param node: If specified it will only test this node, else it will test the flow. :type node: str :param environment_variables: Environment variables to set by specifying a property path and value. Example: {"key1": "${my_connection.api_key}", "key2"="value2"} The value reference to connection keys will be resolved to the actual value, and all environment variables specified will be set into os.environ. :type environment_variables: dict :return: The result of flow or node :rtype: dict """ return self.flows.test( flow=flow, inputs=inputs, variant=variant, environment_variables=environment_variables, node=node )
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_run_functions.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from os import PathLike from typing import IO, AnyStr, Union from promptflow._sdk._load_functions import load_run from promptflow._sdk._pf_client import PFClient from promptflow._sdk.entities._run import Run def _create_run(run: Run, **kwargs): client = PFClient() return client.runs.create_or_update(run=run, **kwargs) def create_yaml_run(source: Union[str, PathLike, IO[AnyStr]], params_override: list = None, **kwargs): """Create a run from a yaml file. Should only call from CLI.""" run = load_run(source, params_override=params_override, **kwargs) return _create_run(run=run, **kwargs)
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_load_functions.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from os import PathLike from pathlib import Path from typing import IO, AnyStr, Optional, Union from dotenv import dotenv_values from .._utils.logger_utils import get_cli_sdk_logger from .._utils.yaml_utils import load_yaml from .entities import Run from .entities._connection import CustomConnection, _Connection from .entities._flow import Flow logger = get_cli_sdk_logger() def load_common( cls, source: Union[str, PathLike, IO[AnyStr]], relative_origin: str = None, params_override: Optional[list] = None, **kwargs, ): """Private function to load a yaml file to an entity object. :param cls: The entity class type. :type cls: type[Resource] :param source: A source of yaml. :type source: Union[str, PathLike, IO[AnyStr]] :param relative_origin: The origin of to be used when deducing the relative locations of files referenced in the parsed yaml. Must be provided, and is assumed to be assigned by other internal functions that call this. :type relative_origin: str :param params_override: _description_, defaults to None :type params_override: list, optional """ if relative_origin is None: if isinstance(source, (str, PathLike)): relative_origin = source else: try: relative_origin = source.name except AttributeError: # input is a stream or something relative_origin = "./" params_override = params_override or [] yaml_dict = load_yaml(source) logger.debug(f"Resolve cls and type with {yaml_dict}, params_override {params_override}.") # pylint: disable=protected-access cls, type_str = cls._resolve_cls_and_type(data=yaml_dict, params_override=params_override) try: return cls._load( data=yaml_dict, yaml_path=relative_origin, params_override=params_override, **kwargs, ) except Exception as e: raise Exception(f"Load entity error: {e}") from e def load_flow( source: Union[str, PathLike, IO[AnyStr]], *, entry: str = None, **kwargs, ) -> Flow: """Load flow from YAML file. :param source: The local yaml source of a flow. Must be a path to a local file. If the source is a path, it will be open and read. An exception is raised if the file does not exist. :type source: Union[PathLike, str] :param entry: The entry function, only works when source is a code file. :type entry: str :return: A Flow object :rtype: Flow """ return Flow.load(source, entry=entry, **kwargs) def load_run( source: Union[str, PathLike, IO[AnyStr]], params_override: Optional[list] = None, **kwargs, ) -> Run: """Load run from YAML file. :param source: The local yaml source of a run. Must be a path to a local file. If the source is a path, it will be open and read. An exception is raised if the file does not exist. :type source: Union[PathLike, str] :param params_override: Fields to overwrite on top of the yaml file. Format is [{"field1": "value1"}, {"field2": "value2"}] :type params_override: List[Dict] :return: A Run object :rtype: Run """ data = load_yaml(source=source) return Run._load(data=data, yaml_path=source, params_override=params_override, **kwargs) def load_connection( source: Union[str, PathLike, IO[AnyStr]], **kwargs, ): if Path(source).name.endswith(".env"): return _load_env_to_connection(source, **kwargs) return load_common(_Connection, source, **kwargs) def _load_env_to_connection( source, params_override: Optional[list] = None, **kwargs, ): source = Path(source) name = next((_dct["name"] for _dct in params_override if "name" in _dct), None) if not name: raise Exception("Please specify --name when creating connection from .env.") if not source.exists(): raise FileNotFoundError(f"File {source.absolute().as_posix()!r} not found.") try: data = dict(dotenv_values(source)) if not data: # Handle some special case dotenv returns empty with no exception raised. raise ValueError( f"Load nothing from dotenv file {source.absolute().as_posix()!r}, " "please make sure the file is not empty and readable." ) return CustomConnection(name=name, secrets=data) except Exception as e: raise Exception(f"Load entity error: {e}") from e
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_user_agent.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from promptflow._version import VERSION USER_AGENT = "{}/{}".format("promptflow-sdk", VERSION)
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_constants.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import os from enum import Enum from pathlib import Path LOGGER_NAME = "promptflow" PROMPT_FLOW_HOME_DIR_ENV_VAR = "PF_HOME_DIRECTORY" PROMPT_FLOW_DIR_NAME = ".promptflow" def _prepare_home_dir() -> Path: """Prepare prompt flow home directory. User can configure it by setting environment variable: `PF_HOME_DIRECTORY`; if not configured, or configured value is not valid, use default value: "~/.promptflow/". """ from promptflow._utils.logger_utils import get_cli_sdk_logger logger = get_cli_sdk_logger() if PROMPT_FLOW_HOME_DIR_ENV_VAR in os.environ: logger.debug( f"environment variable {PROMPT_FLOW_HOME_DIR_ENV_VAR!r} is set, honor it preparing home directory." ) try: pf_home_dir = Path(os.getenv(PROMPT_FLOW_HOME_DIR_ENV_VAR)).resolve() pf_home_dir.mkdir(parents=True, exist_ok=True) return pf_home_dir except Exception as e: # pylint: disable=broad-except _warning_message = ( "Invalid configuration for prompt flow home directory: " f"{os.getenv(PROMPT_FLOW_HOME_DIR_ENV_VAR)!r}: {str(e)!r}.\n" 'Fall back to use default value: "~/.promptflow/".' ) logger.warning(_warning_message) try: logger.debug("preparing home directory with default value.") pf_home_dir = (Path.home() / PROMPT_FLOW_DIR_NAME).resolve() pf_home_dir.mkdir(parents=True, exist_ok=True) return pf_home_dir except Exception as e: # pylint: disable=broad-except _error_message = ( f"Cannot create prompt flow home directory: {str(e)!r}.\n" "Please check if you have proper permission to operate the directory " f"{HOME_PROMPT_FLOW_DIR.as_posix()!r}; or configure it via " f"environment variable {PROMPT_FLOW_HOME_DIR_ENV_VAR!r}.\n" ) logger.error(_error_message) raise Exception(_error_message) HOME_PROMPT_FLOW_DIR = _prepare_home_dir() DAG_FILE_NAME = "flow.dag.yaml" NODE_VARIANTS = "node_variants" VARIANTS = "variants" NODES = "nodes" NODE = "node" INPUTS = "inputs" USE_VARIANTS = "use_variants" DEFAULT_VAR_ID = "default_variant_id" FLOW_TOOLS_JSON = "flow.tools.json" FLOW_TOOLS_JSON_GEN_TIMEOUT = 60 PROMPT_FLOW_RUNS_DIR_NAME = ".runs" PROMPT_FLOW_EXP_DIR_NAME = ".exps" SERVICE_CONFIG_FILE = "pf.yaml" PF_SERVICE_PORT_FILE = "pfs.port" PF_SERVICE_LOG_FILE = "pfs.log" LOCAL_MGMT_DB_PATH = (HOME_PROMPT_FLOW_DIR / "pf.sqlite").resolve() LOCAL_MGMT_DB_SESSION_ACQUIRE_LOCK_PATH = (HOME_PROMPT_FLOW_DIR / "pf.sqlite.lock").resolve() SCHEMA_INFO_TABLENAME = "schema_info" RUN_INFO_TABLENAME = "run_info" RUN_INFO_CREATED_ON_INDEX_NAME = "idx_run_info_created_on" CONNECTION_TABLE_NAME = "connection" EXPERIMENT_TABLE_NAME = "experiment" EXPERIMENT_CREATED_ON_INDEX_NAME = "idx_experiment_created_on" BASE_PATH_CONTEXT_KEY = "base_path" SCHEMA_KEYS_CONTEXT_CONFIG_KEY = "schema_configs_keys" SCHEMA_KEYS_CONTEXT_SECRET_KEY = "schema_secrets_keys" PARAMS_OVERRIDE_KEY = "params_override" FILE_PREFIX = "file:" KEYRING_SYSTEM = "promptflow" KEYRING_ENCRYPTION_KEY_NAME = "encryption_key" KEYRING_ENCRYPTION_LOCK_PATH = (HOME_PROMPT_FLOW_DIR / "encryption_key.lock").resolve() REFRESH_CONNECTIONS_DIR_LOCK_PATH = (HOME_PROMPT_FLOW_DIR / "refresh_connections_dir.lock").resolve() # Note: Use this only for show. Reading input should regard all '*' string as scrubbed, no matter the length. SCRUBBED_VALUE = "******" SCRUBBED_VALUE_NO_CHANGE = "<no-change>" SCRUBBED_VALUE_USER_INPUT = "<user-input>" CHAT_HISTORY = "chat_history" WORKSPACE_LINKED_DATASTORE_NAME = "workspaceblobstore" LINE_NUMBER = "line_number" AZUREML_PF_RUN_PROPERTIES_LINEAGE = "azureml.promptflow.input_run_id" AZURE_WORKSPACE_REGEX_FORMAT = ( "^azureml:[/]{1,2}subscriptions/([^/]+)/resource(groups|Groups)/([^/]+)" "(/providers/Microsoft.MachineLearningServices)?/workspaces/([^/]+)$" ) DEFAULT_ENCODING = "utf-8" LOCAL_STORAGE_BATCH_SIZE = 1 LOCAL_SERVICE_PORT = 5000 BULK_RUN_ERRORS = "BulkRunErrors" RUN_MACRO = "${run}" VARIANT_ID_MACRO = "${variant_id}" TIMESTAMP_MACRO = "${timestamp}" DEFAULT_VARIANT = "variant_0" # run visualize constants VIS_HTML_TMPL = Path(__file__).parent / "data" / "visualize.j2" VIS_JS_BUNDLE_FILENAME = "bulkTestDetails.min.js" VIS_PORTAL_URL_TMPL = ( "https://ml.azure.com/prompts/flow/bulkrun/runs/outputs" "?wsid=/subscriptions/{subscription_id}/resourceGroups/{resource_group_name}" "/providers/Microsoft.MachineLearningServices/workspaces/{workspace_name}&runId={names}" ) REMOTE_URI_PREFIX = "azureml:" REGISTRY_URI_PREFIX = "azureml://registries/" FLOW_RESOURCE_ID_PREFIX = "azureml://locations/" FLOW_DIRECTORY_MACRO_IN_CONFIG = "${flow_directory}" # Tool meta info UIONLY_HIDDEN = "uionly_hidden" SKIP_FUNC_PARAMS = ["subscription_id", "resource_group_name", "workspace_name"] ICON_DARK = "icon_dark" ICON_LIGHT = "icon_light" ICON = "icon" TOOL_SCHEMA = Path(__file__).parent / "data" / "tool.schema.json" class CustomStrongTypeConnectionConfigs: PREFIX = "promptflow.connection." TYPE = "custom_type" MODULE = "module" PACKAGE = "package" PACKAGE_VERSION = "package_version" PROMPTFLOW_TYPE_KEY = PREFIX + TYPE PROMPTFLOW_MODULE_KEY = PREFIX + MODULE PROMPTFLOW_PACKAGE_KEY = PREFIX + PACKAGE PROMPTFLOW_PACKAGE_VERSION_KEY = PREFIX + PACKAGE_VERSION @staticmethod def is_custom_key(key): return key not in [ CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY, CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY, CustomStrongTypeConnectionConfigs.PROMPTFLOW_PACKAGE_KEY, CustomStrongTypeConnectionConfigs.PROMPTFLOW_PACKAGE_VERSION_KEY, ] class RunTypes: BATCH = "batch" EVALUATION = "evaluation" PAIRWISE_EVALUATE = "pairwise_evaluate" COMMAND = "command" class AzureRunTypes: """Run types for run entity from index service.""" BATCH = "azureml.promptflow.FlowRun" EVALUATION = "azureml.promptflow.EvaluationRun" PAIRWISE_EVALUATE = "azureml.promptflow.PairwiseEvaluationRun" class RestRunTypes: """Run types for run entity from MT service.""" BATCH = "FlowRun" EVALUATION = "EvaluationRun" PAIRWISE_EVALUATE = "PairwiseEvaluationRun" # run document statuses class RunStatus(object): # Ordered by transition order QUEUED = "Queued" NOT_STARTED = "NotStarted" PREPARING = "Preparing" PROVISIONING = "Provisioning" STARTING = "Starting" RUNNING = "Running" CANCEL_REQUESTED = "CancelRequested" CANCELED = "Canceled" FINALIZING = "Finalizing" COMPLETED = "Completed" FAILED = "Failed" UNAPPROVED = "Unapproved" NOTRESPONDING = "NotResponding" PAUSING = "Pausing" PAUSED = "Paused" @classmethod def list(cls): """Return the list of supported run statuses.""" return [ cls.QUEUED, cls.PREPARING, cls.PROVISIONING, cls.STARTING, cls.RUNNING, cls.CANCEL_REQUESTED, cls.CANCELED, cls.FINALIZING, cls.COMPLETED, cls.FAILED, cls.NOT_STARTED, cls.UNAPPROVED, cls.NOTRESPONDING, cls.PAUSING, cls.PAUSED, ] @classmethod def get_running_statuses(cls): """Return the list of running statuses.""" return [ cls.NOT_STARTED, cls.QUEUED, cls.PREPARING, cls.PROVISIONING, cls.STARTING, cls.RUNNING, cls.UNAPPROVED, cls.NOTRESPONDING, cls.PAUSING, cls.PAUSED, ] @classmethod def get_post_processing_statuses(cls): """Return the list of running statuses.""" return [cls.CANCEL_REQUESTED, cls.FINALIZING] class FlowRunProperties: FLOW_PATH = "flow_path" OUTPUT_PATH = "output_path" NODE_VARIANT = "node_variant" RUN = "run" SYSTEM_METRICS = "system_metrics" # Experiment command node fields only COMMAND = "command" OUTPUTS = "outputs" class CommonYamlFields: """Common yaml fields. Common yaml fields are used to define the common fields in yaml files. It can be one of the following values: type, name, $schema. """ TYPE = "type" """Type.""" NAME = "name" """Name.""" SCHEMA = "$schema" """Schema.""" MAX_LIST_CLI_RESULTS = 50 # general list MAX_RUN_LIST_RESULTS = 50 # run list MAX_SHOW_DETAILS_RESULTS = 100 # show details class CLIListOutputFormat: JSON = "json" TABLE = "table" class LocalStorageFilenames: SNAPSHOT_FOLDER = "snapshot" DAG = DAG_FILE_NAME FLOW_TOOLS_JSON = FLOW_TOOLS_JSON INPUTS = "inputs.jsonl" OUTPUTS = "outputs.jsonl" DETAIL = "detail.json" METRICS = "metrics.json" LOG = "logs.txt" EXCEPTION = "error.json" META = "meta.json" class ListViewType(str, Enum): ACTIVE_ONLY = "ActiveOnly" ARCHIVED_ONLY = "ArchivedOnly" ALL = "All" def get_list_view_type(archived_only: bool, include_archived: bool) -> ListViewType: if archived_only and include_archived: raise Exception("Cannot provide both archived-only and include-archived.") if include_archived: return ListViewType.ALL elif archived_only: return ListViewType.ARCHIVED_ONLY else: return ListViewType.ACTIVE_ONLY class RunInfoSources(str, Enum): """Run sources.""" LOCAL = "local" INDEX_SERVICE = "index_service" RUN_HISTORY = "run_history" MT_SERVICE = "mt_service" EXISTING_RUN = "existing_run" class ConfigValueType(str, Enum): STRING = "String" SECRET = "Secret" class ConnectionType(str, Enum): _NOT_SET = "NotSet" AZURE_OPEN_AI = "AzureOpenAI" OPEN_AI = "OpenAI" QDRANT = "Qdrant" COGNITIVE_SEARCH = "CognitiveSearch" SERP = "Serp" AZURE_CONTENT_SAFETY = "AzureContentSafety" FORM_RECOGNIZER = "FormRecognizer" WEAVIATE = "Weaviate" CUSTOM = "Custom" ALL_CONNECTION_TYPES = set( map(lambda x: f"{x.value}Connection", filter(lambda x: x != ConnectionType._NOT_SET, ConnectionType)) ) class ConnectionFields(str, Enum): CONNECTION = "connection" DEPLOYMENT_NAME = "deployment_name" MODEL = "model" SUPPORTED_CONNECTION_FIELDS = { ConnectionFields.CONNECTION.value, ConnectionFields.DEPLOYMENT_NAME.value, ConnectionFields.MODEL.value, } class RunDataKeys: PORTAL_URL = "portal_url" DATA = "data" RUN = "run" OUTPUT = "output" class RunHistoryKeys: RunMetaData = "runMetadata" HIDDEN = "hidden" class ConnectionProvider(str, Enum): LOCAL = "local" AZUREML = "azureml" class FlowType: STANDARD = "standard" EVALUATION = "evaluation" CHAT = "chat" @staticmethod def get_all_values(): values = [value for key, value in vars(FlowType).items() if isinstance(value, str) and key.isupper()] return values CLIENT_FLOW_TYPE_2_SERVICE_FLOW_TYPE = { FlowType.STANDARD: "default", FlowType.EVALUATION: "evaluation", FlowType.CHAT: "chat", } SERVICE_FLOW_TYPE_2_CLIENT_FLOW_TYPE = {value: key for key, value in CLIENT_FLOW_TYPE_2_SERVICE_FLOW_TYPE.items()} class AzureFlowSource: LOCAL = "local" PF_SERVICE = "pf_service" INDEX = "index" class DownloadedRun: SNAPSHOT_FOLDER = LocalStorageFilenames.SNAPSHOT_FOLDER METRICS_FILE_NAME = LocalStorageFilenames.METRICS LOGS_FILE_NAME = LocalStorageFilenames.LOG RUN_METADATA_FILE_NAME = "run_metadata.json" class ExperimentNodeType(object): FLOW = "flow" COMMAND = "command" class ExperimentStatus(object): NOT_STARTED = "NotStarted" IN_PROGRESS = "InProgress" TERMINATED = "Terminated"
0
promptflow_repo/promptflow/src/promptflow/promptflow
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_run_inputs.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from os import PathLike from typing import Union # TODO(2528165): remove this file when we deprecate Flow.run_bulk class BaseInputs(object): def __init__(self, data: Union[str, PathLike], inputs_mapping: dict = None, **kwargs): self.data = data self.inputs_mapping = inputs_mapping class BulkInputs(BaseInputs): """Bulk run inputs. data: pointer to test data for standard runs inputs_mapping: define a data flow logic to map input data, support: from data: data.col1: Example: {"question": "${data.question}", "context": "${data.context}"} """ # TODO: support inputs_mapping for bulk run pass class EvalInputs(BaseInputs): """Evaluation flow run inputs. data: pointer to test data (of variant bulk runs) for eval runs variant: variant run id or variant run keep lineage between current run and variant runs variant outputs can be referenced as ${batch_run.outputs.col_name} in inputs_mapping baseline: baseline run id or baseline run baseline bulk run for eval runs for pairwise comparison inputs_mapping: define a data flow logic to map input data, support: from data: data.col1: from variant: [0].col1, [1].col2: if need different col from variant run data variant.output.col1: if all upstream runs has col1 Example: {"ground_truth": "${data.answer}", "prediction": "${batch_run.outputs.answer}"} """ def __init__( self, data: Union[str, PathLike], variant: Union[str, "BulkRun"] = None, # noqa: F821 baseline: Union[str, "BulkRun"] = None, # noqa: F821 inputs_mapping: dict = None, **kwargs ): super().__init__(data=data, inputs_mapping=inputs_mapping, **kwargs) self.variant = variant self.baseline = baseline
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_experiment.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy import datetime import json import shutil import uuid from os import PathLike from pathlib import Path from typing import Any, Dict, List, Optional, Union from marshmallow import Schema from promptflow._sdk._constants import ( BASE_PATH_CONTEXT_KEY, PARAMS_OVERRIDE_KEY, PROMPT_FLOW_DIR_NAME, PROMPT_FLOW_EXP_DIR_NAME, ExperimentNodeType, ExperimentStatus, ) from promptflow._sdk._errors import ExperimentValidationError, ExperimentValueError from promptflow._sdk._orm.experiment import Experiment as ORMExperiment from promptflow._sdk._submitter import remove_additional_includes from promptflow._sdk._utils import _merge_local_code_and_additional_includes, _sanitize_python_variable_name from promptflow._sdk.entities import Run from promptflow._sdk.entities._validation import MutableValidationResult, SchemaValidatableMixin from promptflow._sdk.entities._yaml_translatable import YAMLTranslatableMixin from promptflow._sdk.schemas._experiment import ( CommandNodeSchema, ExperimentDataSchema, ExperimentInputSchema, ExperimentSchema, ExperimentTemplateSchema, FlowNodeSchema, ) from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow.contracts.tool import ValueType logger = get_cli_sdk_logger() class ExperimentData(YAMLTranslatableMixin): def __init__(self, name, path, **kwargs): self.name = name self.path = path @classmethod def _get_schema_cls(cls): return ExperimentDataSchema class ExperimentInput(YAMLTranslatableMixin): def __init__(self, name, default, type, **kwargs): self.name = name self.type, self.default = self._resolve_type_and_default(type, default) @classmethod def _get_schema_cls(cls): return ExperimentInputSchema def _resolve_type_and_default(self, typ, default): supported_types = [ ValueType.INT, ValueType.STRING, ValueType.DOUBLE, ValueType.LIST, ValueType.OBJECT, ValueType.BOOL, ] value_type: ValueType = next((i for i in supported_types if typ.lower() == i.value.lower()), None) if value_type is None: raise ExperimentValueError(f"Unknown experiment input type {typ!r}, supported are {supported_types}.") return value_type.value, value_type.parse(default) if default is not None else None @classmethod def _load_from_dict(cls, data: Dict, context: Dict, additional_message: str = None, **kwargs): # Override this to avoid 'type' got pop out schema_cls = cls._get_schema_cls() try: loaded_data = schema_cls(context=context).load(data, **kwargs) except Exception as e: raise Exception(f"Load experiment input failed with {str(e)}. f{(additional_message or '')}.") return cls(base_path=context[BASE_PATH_CONTEXT_KEY], **loaded_data) class FlowNode(YAMLTranslatableMixin): def __init__( self, path: Union[Path, str], name: str, # input fields are optional since it's not stored in DB data: Optional[str] = None, variant: Optional[str] = None, run: Optional[Union["Run", str]] = None, inputs: Optional[dict] = None, display_name: Optional[str] = None, description: Optional[str] = None, tags: Optional[List[Dict[str, str]]] = None, environment_variables: Optional[Dict[str, str]] = None, connections: Optional[Dict[str, Dict]] = None, properties: Optional[Dict[str, Any]] = None, **kwargs, ): self.type = ExperimentNodeType.FLOW self.data = data self.inputs = inputs self.display_name = display_name self.description = description self.tags = tags self.variant = variant self.run = run self.environment_variables = environment_variables or {} self.connections = connections or {} self._properties = properties or {} # init here to make sure those fields initialized in all branches. self.path = path # default run name: flow directory name + timestamp self.name = name self._runtime = kwargs.get("runtime", None) self._resources = kwargs.get("resources", None) @classmethod def _get_schema_cls(cls): return FlowNodeSchema def _save_snapshot(self, target): """Save flow source to experiment snapshot.""" # Resolve additional includes in flow from promptflow import load_flow Path(target).mkdir(parents=True, exist_ok=True) flow = load_flow(source=self.path) saved_flow_path = Path(target) / self.name with _merge_local_code_and_additional_includes(code_path=flow.code) as resolved_flow_dir: remove_additional_includes(Path(resolved_flow_dir)) shutil.copytree(src=resolved_flow_dir, dst=saved_flow_path) logger.debug(f"Flow source saved to {saved_flow_path}.") self.path = saved_flow_path.resolve().absolute().as_posix() class CommandNode(YAMLTranslatableMixin): def __init__( self, command, name, inputs=None, outputs=None, runtime=None, environment_variables=None, code=None, display_name=None, **kwargs, ): self.type = ExperimentNodeType.COMMAND self.name = name self.display_name = display_name self.code = code self.command = command self.inputs = inputs or {} self.outputs = outputs or {} self.runtime = runtime self.environment_variables = environment_variables or {} @classmethod def _get_schema_cls(cls): return CommandNodeSchema def _save_snapshot(self, target): """Save command source to experiment snapshot.""" Path(target).mkdir(parents=True, exist_ok=True) saved_path = Path(target) / self.name if not self.code: # Create an empty folder saved_path.mkdir(parents=True, exist_ok=True) self.code = saved_path.resolve().absolute().as_posix() return code = Path(self.code) if not code.exists(): raise ExperimentValueError(f"Command node code {code} does not exist.") if code.is_dir(): shutil.copytree(src=self.code, dst=saved_path) else: saved_path.mkdir(parents=True, exist_ok=True) shutil.copy(src=self.code, dst=saved_path) logger.debug(f"Command node source saved to {saved_path}.") self.code = saved_path.resolve().absolute().as_posix() class ExperimentTemplate(YAMLTranslatableMixin, SchemaValidatableMixin): def __init__(self, nodes, name=None, description=None, data=None, inputs=None, **kwargs): self._base_path = kwargs.get(BASE_PATH_CONTEXT_KEY, Path(".")) self.name = name or self._generate_name() self.description = description self.nodes = nodes self.data = data or [] self.inputs = inputs or [] self._source_path = None @classmethod # pylint: disable=unused-argument def _resolve_cls_and_type(cls, **kwargs): return cls, "experiment_template" @classmethod def _get_schema_cls(cls): return ExperimentTemplateSchema @classmethod def _load( cls, data: Optional[Dict] = None, yaml_path: Optional[Union[PathLike, str]] = None, params_override: Optional[list] = None, **kwargs, ): data = data or {} params_override = params_override or [] context = { BASE_PATH_CONTEXT_KEY: Path(yaml_path).parent if yaml_path else Path("./"), PARAMS_OVERRIDE_KEY: params_override, } logger.debug(f"Loading class object with data {data}, params_override {params_override}, context {context}.") exp = cls._load_from_dict( data=data, context=context, additional_message="Failed to load experiment", **kwargs, ) if yaml_path: exp._source_path = yaml_path return exp def _generate_name(self) -> str: """Generate a template name.""" try: folder_name = Path(self._base_path).resolve().absolute().name return _sanitize_python_variable_name(folder_name) except Exception as e: logger.debug(f"Failed to generate template name, error: {e}, use uuid.") return str(uuid.uuid4()) @classmethod def _load_from_dict(cls, data: Dict, context: Dict, additional_message: str = None, **kwargs): schema_cls = cls._get_schema_cls() try: loaded_data = schema_cls(context=context).load(data, **kwargs) except Exception as e: raise Exception(f"Load experiment template failed with {str(e)}. f{(additional_message or '')}.") return cls(base_path=context[BASE_PATH_CONTEXT_KEY], **loaded_data) @classmethod def _create_schema_for_validation(cls, context) -> Schema: return cls._get_schema_cls()(context=context) def _default_context(self) -> dict: return {BASE_PATH_CONTEXT_KEY: self._base_path} @classmethod def _create_validation_error(cls, message: str, no_personal_data_message: str) -> Exception: return ExperimentValidationError( message=message, no_personal_data_message=no_personal_data_message, ) def _customized_validate(self) -> MutableValidationResult: """Validate the resource with customized logic. Override this method to add customized validation logic. :return: The customized validation result :rtype: MutableValidationResult """ pass class Experiment(ExperimentTemplate): def __init__( self, nodes, name=None, data=None, inputs=None, status=ExperimentStatus.NOT_STARTED, node_runs=None, properties=None, **kwargs, ): self.name = name or self._generate_name() self.status = status self.node_runs = node_runs or {} self.properties = properties or {} self.created_on = kwargs.get("created_on", datetime.datetime.now().isoformat()) self.last_start_time = kwargs.get("last_start_time", None) self.last_end_time = kwargs.get("last_end_time", None) self.is_archived = kwargs.get("is_archived", False) self._output_dir = Path.home() / PROMPT_FLOW_DIR_NAME / PROMPT_FLOW_EXP_DIR_NAME / self.name super().__init__(nodes, name=self.name, data=data, inputs=inputs, **kwargs) @classmethod def _get_schema_cls(cls): return ExperimentSchema @classmethod # pylint: disable=unused-argument def _resolve_cls_and_type(cls, **kwargs): return cls, "experiment" def _generate_name(self) -> str: """Generate a experiment name.""" try: folder_name = Path(self._base_path).resolve().absolute().name timestamp = datetime.datetime.now().strftime("%Y%m%d_%H%M%S_%f") exp_name = f"{folder_name}_{timestamp}" return _sanitize_python_variable_name(exp_name) except Exception as e: logger.debug(f"Failed to generate experiment name, error: {e}, use uuid.") return str(uuid.uuid4()) def _save_snapshot_and_update_node( self, ): """Save node source to experiment snapshot, update node path.""" snapshot_dir = self._output_dir / "snapshots" for node in self.nodes: node._save_snapshot(snapshot_dir) def _append_node_run(self, node_name, run: Run): """Append node run to experiment.""" if node_name not in self.node_runs or not isinstance(self.node_runs[node_name], list): self.node_runs[node_name] = [] # TODO: Review this self.node_runs[node_name].append({"name": run.name, "status": run.status}) def _to_orm_object(self): """Convert to ORM object.""" result = ORMExperiment( name=self.name, description=self.description, status=self.status, created_on=self.created_on, archived=self.is_archived, last_start_time=self.last_start_time, last_end_time=self.last_end_time, properties=json.dumps(self.properties), data=json.dumps([item._to_dict() for item in self.data]), inputs=json.dumps([input._to_dict() for input in self.inputs]), nodes=json.dumps([node._to_dict() for node in self.nodes]), node_runs=json.dumps(self.node_runs), ) logger.debug(f"Experiment to ORM object: {result.__dict__}") return result @classmethod def _from_orm_object(cls, obj: ORMExperiment) -> "Experiment": """Create a experiment object from ORM object.""" nodes = [] context = {BASE_PATH_CONTEXT_KEY: "./"} for node_dict in json.loads(obj.nodes): if node_dict["type"] == ExperimentNodeType.FLOW: nodes.append( FlowNode._load_from_dict(node_dict, context=context, additional_message="Failed to load node.") ) elif node_dict["type"] == ExperimentNodeType.COMMAND: nodes.append( CommandNode._load_from_dict(node_dict, context=context, additional_message="Failed to load node.") ) else: raise Exception(f"Unknown node type {node_dict['type']}") data = [ ExperimentData._load_from_dict(item, context=context, additional_message="Failed to load experiment data") for item in json.loads(obj.data) ] inputs = [ ExperimentInput._load_from_dict( item, context=context, additional_message="Failed to load experiment inputs" ) for item in json.loads(obj.inputs) ] return cls( name=obj.name, description=obj.description, status=obj.status, created_on=obj.created_on, last_start_time=obj.last_start_time, last_end_time=obj.last_end_time, is_archived=obj.archived, properties=json.loads(obj.properties), data=data, inputs=inputs, nodes=nodes, node_runs=json.loads(obj.node_runs), ) @classmethod def from_template(cls, template: ExperimentTemplate, name=None): """Create a experiment object from template.""" timestamp = datetime.datetime.now().strftime("%Y%m%d_%H%M%S_%f") exp_name = name or f"{template.name}_{timestamp}" experiment = cls( name=exp_name, description=template.description, data=copy.deepcopy(template.data), inputs=copy.deepcopy(template.inputs), nodes=copy.deepcopy(template.nodes), base_path=template._base_path, ) logger.debug("Start saving snapshot and update node.") experiment._save_snapshot_and_update_node() return experiment
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_run.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import datetime import functools import json import uuid from os import PathLike from pathlib import Path from typing import Any, Dict, List, Optional, Union from dateutil import parser as date_parser from promptflow._sdk._configuration import Configuration from promptflow._sdk._constants import ( BASE_PATH_CONTEXT_KEY, DEFAULT_ENCODING, DEFAULT_VARIANT, FLOW_DIRECTORY_MACRO_IN_CONFIG, FLOW_RESOURCE_ID_PREFIX, PARAMS_OVERRIDE_KEY, PROMPT_FLOW_DIR_NAME, REGISTRY_URI_PREFIX, REMOTE_URI_PREFIX, RUN_MACRO, TIMESTAMP_MACRO, VARIANT_ID_MACRO, AzureRunTypes, DownloadedRun, FlowRunProperties, RestRunTypes, RunDataKeys, RunInfoSources, RunStatus, RunTypes, ) from promptflow._sdk._errors import InvalidRunError, InvalidRunStatusError from promptflow._sdk._orm import RunInfo as ORMRun from promptflow._sdk._utils import ( _sanitize_python_variable_name, is_remote_uri, parse_remote_flow_pattern, parse_variant, ) from promptflow._sdk.entities._yaml_translatable import YAMLTranslatableMixin from promptflow._sdk.schemas._run import RunSchema from promptflow._utils.flow_utils import get_flow_lineage_id from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow.exceptions import UserErrorException AZURE_RUN_TYPE_2_RUN_TYPE = { AzureRunTypes.BATCH: RunTypes.BATCH, AzureRunTypes.EVALUATION: RunTypes.EVALUATION, AzureRunTypes.PAIRWISE_EVALUATE: RunTypes.PAIRWISE_EVALUATE, } REST_RUN_TYPE_2_RUN_TYPE = { RestRunTypes.BATCH: RunTypes.BATCH, RestRunTypes.EVALUATION: RunTypes.EVALUATION, RestRunTypes.PAIRWISE_EVALUATE: RunTypes.PAIRWISE_EVALUATE, } logger = get_cli_sdk_logger() class Run(YAMLTranslatableMixin): """Flow run entity. :param flow: Path of the flow directory. :type flow: Path :param name: Name of the run. :type name: str :param data: Input data for the run. Local path or remote uri(starts with azureml: or public URL) are supported. Note: remote uri is only supported for cloud run. # noqa: E501 :type data: Optional[str] :param variant: Variant of the run. :type variant: Optional[str] :param run: Parent run or run ID. :type run: Optional[Union[Run, str]] :param column_mapping: Column mapping for the run. Optional since it's not stored in the database. :type column_mapping: Optional[dict] :param display_name: Display name of the run. :type display_name: Optional[str] :param description: Description of the run. :type description: Optional[str] :param tags: Tags of the run. :type tags: Optional[List[Dict[str, str]]] :param created_on: Date and time the run was created. :type created_on: Optional[datetime.datetime] :param start_time: Date and time the run started. :type start_time: Optional[datetime.datetime] :param end_time: Date and time the run ended. :type end_time: Optional[datetime.datetime] :param status: Status of the run. :type status: Optional[str] :param environment_variables: Environment variables for the run. :type environment_variables: Optional[Dict[str, str]] :param connections: Connections for the run. :type connections: Optional[Dict[str, Dict]] :param properties: Properties of the run. :type properties: Optional[Dict[str, Any]] :param kwargs: Additional keyword arguments. :type kwargs: Optional[dict] """ def __init__( self, flow: Optional[Union[Path, str]] = None, name: Optional[str] = None, # input fields are optional since it's not stored in DB data: Optional[str] = None, variant: Optional[str] = None, run: Optional[Union["Run", str]] = None, column_mapping: Optional[dict] = None, display_name: Optional[str] = None, description: Optional[str] = None, tags: Optional[List[Dict[str, str]]] = None, *, created_on: Optional[datetime.datetime] = None, start_time: Optional[datetime.datetime] = None, end_time: Optional[datetime.datetime] = None, status: Optional[str] = None, environment_variables: Optional[Dict[str, str]] = None, connections: Optional[Dict[str, Dict]] = None, properties: Optional[Dict[str, Any]] = None, source: Optional[Union[Path, str]] = None, **kwargs, ): # TODO: remove when RUN CRUD don't depend on this self.type = kwargs.get("type", RunTypes.BATCH) self.data = data self.column_mapping = column_mapping self.display_name = display_name self.description = description self.tags = tags self.variant = variant self.run = run self._created_on = created_on or datetime.datetime.now() self._status = status or RunStatus.NOT_STARTED self.environment_variables = environment_variables or {} self.connections = connections or {} self._properties = properties or {} self.source = source self._is_archived = kwargs.get("is_archived", False) self._run_source = kwargs.get("run_source", RunInfoSources.LOCAL) self._start_time = start_time self._end_time = end_time self._duration = kwargs.get("duration", None) self._portal_url = kwargs.get(RunDataKeys.PORTAL_URL, None) self._creation_context = kwargs.get("creation_context", None) # init here to make sure those fields initialized in all branches. self.flow = flow self._use_remote_flow = is_remote_uri(flow) self._experiment_name = None self._lineage_id = None if self._use_remote_flow: self._flow_name = parse_remote_flow_pattern(flow) self._lineage_id = self._flow_name # default run name: flow directory name + timestamp self.name = name or self._generate_run_name() experiment_name = kwargs.get("experiment_name", None) if self._run_source == RunInfoSources.LOCAL and not self._use_remote_flow: self.flow = Path(flow).resolve().absolute() flow_dir = self._get_flow_dir() # sanitize flow_dir to avoid invalid experiment name self._experiment_name = _sanitize_python_variable_name(flow_dir.name) self._lineage_id = get_flow_lineage_id(flow_dir=flow_dir) self._output_path = Path( kwargs.get("output_path", self._generate_output_path(config=kwargs.get("config", None))) ) self._flow_name = flow_dir.name elif self._run_source == RunInfoSources.INDEX_SERVICE: self._metrics = kwargs.get("metrics", {}) self._experiment_name = experiment_name elif self._run_source == RunInfoSources.RUN_HISTORY: self._error = kwargs.get("error", None) self._output = kwargs.get("output", None) elif self._run_source == RunInfoSources.EXISTING_RUN: # when the run is created from an existing run folder, the output path is also the source path self._output_path = Path(source) self._runtime = kwargs.get("runtime", None) self._resources = kwargs.get("resources", None) self._outputs = kwargs.get("outputs", None) self._command = kwargs.get("command", None) @property def created_on(self) -> str: return self._created_on.isoformat() @property def status(self) -> str: return self._status @property def properties(self) -> Dict[str, str]: result = {} if self._run_source == RunInfoSources.LOCAL: # show posix path to avoid windows path escaping result = { FlowRunProperties.FLOW_PATH: Path(self.flow).as_posix() if not self._use_remote_flow else self.flow, FlowRunProperties.OUTPUT_PATH: self._output_path.as_posix(), } if self.run: run_name = self.run.name if isinstance(self.run, Run) else self.run result[FlowRunProperties.RUN] = run_name if self.variant: result[FlowRunProperties.NODE_VARIANT] = self.variant if self._command: result[FlowRunProperties.COMMAND] = self._command if self._outputs: result[FlowRunProperties.OUTPUTS] = self._outputs elif self._run_source == RunInfoSources.EXISTING_RUN: result = { FlowRunProperties.OUTPUT_PATH: Path(self.source).resolve().as_posix(), } return { **result, **self._properties, } @classmethod def _from_orm_object(cls, obj: ORMRun) -> "Run": properties_json = json.loads(str(obj.properties)) flow = properties_json.get(FlowRunProperties.FLOW_PATH, None) # there can be two sources for orm run object: # 1. LOCAL: Created when run is created from local flow # 2. EXISTING_RUN: Created when run is created from existing run folder source = None if getattr(obj, "run_source", None) == RunInfoSources.EXISTING_RUN: source = properties_json[FlowRunProperties.OUTPUT_PATH] return Run( name=str(obj.name), flow=Path(flow) if flow else None, source=Path(source) if source else None, output_path=properties_json[FlowRunProperties.OUTPUT_PATH], run=properties_json.get(FlowRunProperties.RUN, None), variant=properties_json.get(FlowRunProperties.NODE_VARIANT, None), display_name=obj.display_name, description=str(obj.description) if obj.description else None, tags=json.loads(str(obj.tags)) if obj.tags else None, # keyword arguments created_on=datetime.datetime.fromisoformat(str(obj.created_on)), start_time=datetime.datetime.fromisoformat(str(obj.start_time)) if obj.start_time else None, end_time=datetime.datetime.fromisoformat(str(obj.end_time)) if obj.end_time else None, status=str(obj.status), data=Path(obj.data).resolve().absolute().as_posix() if obj.data else None, properties={FlowRunProperties.SYSTEM_METRICS: properties_json.get(FlowRunProperties.SYSTEM_METRICS, {})}, # compatible with old runs, their run_source is empty, treat them as local run_source=obj.run_source or RunInfoSources.LOCAL, # experiment command node only fields command=properties_json.get(FlowRunProperties.COMMAND, None), outputs=properties_json.get(FlowRunProperties.OUTPUTS, None), ) @classmethod def _from_index_service_entity(cls, run_entity: dict) -> "Run": """Convert run entity from index service to run object.""" # TODO(2887134): support cloud eager Run CRUD start_time = run_entity["properties"].get("startTime", None) end_time = run_entity["properties"].get("endTime", None) duration = run_entity["properties"].get("duration", None) return Run( name=run_entity["properties"]["runId"], flow=Path(f"azureml://flows/{run_entity['properties']['experimentName']}"), type=AZURE_RUN_TYPE_2_RUN_TYPE[run_entity["properties"]["runType"]], created_on=date_parser.parse(run_entity["properties"]["creationContext"]["createdTime"]), status=run_entity["annotations"]["status"], display_name=run_entity["annotations"]["displayName"], description=run_entity["annotations"]["description"], tags=run_entity["annotations"]["tags"], properties=run_entity["properties"]["userProperties"], is_archived=run_entity["annotations"]["archived"], run_source=RunInfoSources.INDEX_SERVICE, metrics=run_entity["annotations"]["metrics"], start_time=date_parser.parse(start_time) if start_time else None, end_time=date_parser.parse(end_time) if end_time else None, duration=duration, creation_context=run_entity["properties"]["creationContext"], experiment_name=run_entity["properties"]["experimentName"], ) @classmethod def _from_run_history_entity(cls, run_entity: dict) -> "Run": """Convert run entity from run history service to run object.""" # TODO(2887134): support cloud eager Run CRUD flow_name = run_entity["properties"].get("azureml.promptflow.flow_name", None) start_time = run_entity.get("startTimeUtc", None) end_time = run_entity.get("endTimeUtc", None) duration = run_entity.get("duration", None) return Run( name=run_entity["runId"], flow=Path(f"azureml://flows/{flow_name}"), type=AZURE_RUN_TYPE_2_RUN_TYPE[run_entity["runType"]], created_on=date_parser.parse(run_entity["createdUtc"]), start_time=date_parser.parse(start_time) if start_time else None, end_time=date_parser.parse(end_time) if end_time else None, duration=duration, status=run_entity["status"], display_name=run_entity["displayName"], description=run_entity["description"], tags=run_entity["tags"], properties=run_entity["properties"], is_archived=run_entity.get("archived", False), # TODO: Get archived status, depends on run history team error=run_entity.get("error", None), run_source=RunInfoSources.RUN_HISTORY, portal_url=run_entity[RunDataKeys.PORTAL_URL], creation_context=run_entity["createdBy"], data=run_entity[RunDataKeys.DATA], run=run_entity[RunDataKeys.RUN], output=run_entity[RunDataKeys.OUTPUT], ) @classmethod def _from_mt_service_entity(cls, run_entity) -> "Run": """Convert run object from MT service to run object.""" flow_run_id = run_entity.flow_run_resource_id.split("/")[-1] return cls( name=flow_run_id, flow=Path(f"azureml://flows/{run_entity.flow_name}"), display_name=run_entity.flow_run_display_name, description="", tags=[], created_on=date_parser.parse(run_entity.created_on), status="", run_source=RunInfoSources.MT_SERVICE, ) def _to_orm_object(self) -> ORMRun: """Convert current run entity to ORM object.""" display_name = self._format_display_name() return ORMRun( name=self.name, created_on=self.created_on, status=self.status, start_time=self._start_time.isoformat() if self._start_time else None, end_time=self._end_time.isoformat() if self._end_time else None, display_name=display_name, description=self.description, tags=json.dumps(self.tags) if self.tags else None, properties=json.dumps(self.properties), data=Path(self.data).resolve().absolute().as_posix() if self.data else None, run_source=self._run_source, ) def _dump(self) -> None: """Dump current run entity to local DB.""" self._to_orm_object().dump() def _to_dict( self, *, exclude_additional_info: bool = False, exclude_debug_info: bool = False, exclude_properties: bool = False, ): from promptflow._sdk.operations._local_storage_operations import LocalStorageOperations properties = self.properties result = { "name": self.name, "created_on": self.created_on, "status": self.status, "display_name": self.display_name, "description": self.description, "tags": self.tags, "properties": properties, } if self._run_source == RunInfoSources.LOCAL: result["flow_name"] = self._flow_name local_storage = LocalStorageOperations(run=self) result[RunDataKeys.DATA] = ( local_storage._data_path.resolve().absolute().as_posix() if local_storage._data_path is not None else None ) result[RunDataKeys.OUTPUT] = local_storage.outputs_folder.as_posix() if self.run: run_name = self.run.name if isinstance(self.run, Run) else self.run result[RunDataKeys.RUN] = properties.pop(FlowRunProperties.RUN, run_name) # add exception part if any exception_dict = local_storage.load_exception() if exception_dict: if exclude_additional_info: exception_dict.pop("additionalInfo", None) if exclude_debug_info: exception_dict.pop("debugInfo", None) result["error"] = exception_dict elif self._run_source == RunInfoSources.INDEX_SERVICE: result["creation_context"] = self._creation_context result["flow_name"] = self._experiment_name result["is_archived"] = self._is_archived result["start_time"] = self._start_time.isoformat() if self._start_time else None result["end_time"] = self._end_time.isoformat() if self._end_time else None result["duration"] = self._duration elif self._run_source == RunInfoSources.RUN_HISTORY: result["creation_context"] = self._creation_context result["start_time"] = self._start_time.isoformat() if self._start_time else None result["end_time"] = self._end_time.isoformat() if self._end_time else None result["duration"] = self._duration result[RunDataKeys.PORTAL_URL] = self._portal_url result[RunDataKeys.DATA] = self.data result[RunDataKeys.OUTPUT] = self._output if self.run: result[RunDataKeys.RUN] = self.run if self._error: result["error"] = self._error if exclude_additional_info: result["error"]["error"].pop("additionalInfo", None) if exclude_debug_info: result["error"]["error"].pop("debugInfo", None) # hide properties when needed (e.g. list remote runs) if exclude_properties is True: result.pop("properties", None) return result @classmethod def _load( cls, data: Optional[Dict] = None, yaml_path: Optional[Union[PathLike, str]] = None, params_override: Optional[list] = None, **kwargs, ): from marshmallow import INCLUDE data = data or {} params_override = params_override or [] context = { BASE_PATH_CONTEXT_KEY: Path(yaml_path).parent if yaml_path else Path("./"), PARAMS_OVERRIDE_KEY: params_override, } run = cls._load_from_dict( data=data, context=context, additional_message="Failed to load flow run", unknown=INCLUDE, **kwargs, ) if yaml_path: run._source_path = yaml_path return run def _generate_run_name(self) -> str: """Generate a run name with flow_name_variant_timestamp format.""" try: flow_name = self._get_flow_dir().name if not self._use_remote_flow else self._flow_name variant = self.variant timestamp = datetime.datetime.now().strftime("%Y%m%d_%H%M%S_%f") variant = parse_variant(variant)[1] if variant else DEFAULT_VARIANT run_name_prefix = f"{flow_name}_{variant}" # TODO(2562996): limit run name to avoid it become too long run_name = f"{run_name_prefix}_{timestamp}" return _sanitize_python_variable_name(run_name) except Exception: return str(uuid.uuid4()) def _get_default_display_name(self) -> str: display_name = self.display_name or self.name return display_name def _format_display_name(self) -> str: """ Format display name. Replace macros in display name with actual values. The following macros are supported: ${variant_id}, ${run}, ${timestamp} For example, if the display name is "run-${variant_id}-${timestamp}" it will be formatted to "run-variant_1-20210901123456" """ display_name = self._get_default_display_name() time_stamp = datetime.datetime.now().strftime("%Y%m%d%H%M") if self.run: display_name = display_name.replace(RUN_MACRO, self._validate_and_return_run_name(self.run)) display_name = display_name.replace(TIMESTAMP_MACRO, time_stamp) variant = self.variant variant = parse_variant(variant)[1] if variant else DEFAULT_VARIANT display_name = display_name.replace(VARIANT_ID_MACRO, variant) return display_name def _get_flow_dir(self) -> Path: if not self._use_remote_flow: flow = Path(self.flow) if flow.is_dir(): return flow return flow.parent raise UserErrorException("Cannot get flow directory for remote flow.") @classmethod def _get_schema_cls(self): return RunSchema def _to_rest_object(self): from azure.ai.ml._utils._storage_utils import AzureMLDatastorePathUri from promptflow.azure._restclient.flow.models import ( BatchDataInput, RunDisplayNameGenerationType, SessionSetupModeEnum, SubmitBulkRunRequest, ) if self.run is not None: if isinstance(self.run, Run): variant = self.run.name elif isinstance(self.run, str): variant = self.run else: raise UserErrorException(f"Invalid run type: {type(self.run)}") else: variant = None if not variant and not self.data: raise UserErrorException("Either run or data should be provided") # parse inputs mapping inputs_mapping = {} if self.column_mapping and not isinstance(self.column_mapping, dict): raise UserErrorException(f"column_mapping should be a dictionary, got {type(self.column_mapping)} instead.") if self.column_mapping: for k, v in self.column_mapping.items(): if isinstance(v, (int, float, str, bool)): inputs_mapping[k] = v else: try: val = json.dumps(v) except Exception as e: raise UserErrorException( f"Invalid input mapping value: {v}, " f"only primitive or json serializable value is supported, got {type(v)}", error=e, ) inputs_mapping[k] = val # parse resources if self._resources is not None: if not isinstance(self._resources, dict): raise TypeError(f"resources should be a dict, got {type(self._resources)} for {self._resources}") vm_size = self._resources.get("instance_type", None) max_idle_time_minutes = self._resources.get("idle_time_before_shutdown_minutes", None) # change to seconds max_idle_time_seconds = max_idle_time_minutes * 60 if max_idle_time_minutes else None else: vm_size = None max_idle_time_seconds = None # use functools.partial to avoid too many arguments that have the same values common_submit_bulk_run_request = functools.partial( SubmitBulkRunRequest, run_id=self.name, # will use user provided display name since PFS will have special logic to update it. run_display_name=self._get_default_display_name(), description=self.description, tags=self.tags, node_variant=self.variant, variant_run_id=variant, batch_data_input=BatchDataInput( data_uri=self.data, ), inputs_mapping=inputs_mapping, run_experiment_name=self._experiment_name, environment_variables=self.environment_variables, connections=self.connections, flow_lineage_id=self._lineage_id, run_display_name_generation_type=RunDisplayNameGenerationType.USER_PROVIDED_MACRO, vm_size=vm_size, max_idle_time_seconds=max_idle_time_seconds, session_setup_mode=SessionSetupModeEnum.SYSTEM_WAIT, ) if str(self.flow).startswith(REMOTE_URI_PREFIX): if not self._use_remote_flow: # in normal case, we will upload local flow to datastore and resolve the self.flow to be remote uri # upload via _check_and_upload_path # submit with params FlowDefinitionDataStoreName and FlowDefinitionBlobPath path_uri = AzureMLDatastorePathUri(str(self.flow)) return common_submit_bulk_run_request( flow_definition_data_store_name=path_uri.datastore, flow_definition_blob_path=path_uri.path, ) else: # if the flow is a remote flow in the beginning, we will submit with params FlowDefinitionResourceID # submit with params flow_definition_resource_id which will be resolved in pfazure run create operation # the flow resource id looks like: "azureml://locations/<region>/workspaces/<ws-name>/flows/<flow-name>" if not isinstance(self.flow, str) or ( not self.flow.startswith(FLOW_RESOURCE_ID_PREFIX) and not self.flow.startswith(REGISTRY_URI_PREFIX) ): raise UserErrorException( f"Invalid flow value when transforming to rest object: {self.flow!r}. " f"Expecting a flow definition resource id starts with '{FLOW_RESOURCE_ID_PREFIX}' " f"or a flow registry uri starts with '{REGISTRY_URI_PREFIX}'" ) return common_submit_bulk_run_request( flow_definition_resource_id=self.flow, ) else: # upload via CodeOperations.create_or_update # submit with param FlowDefinitionDataUri return common_submit_bulk_run_request( flow_definition_data_uri=str(self.flow), ) def _check_run_status_is_completed(self) -> None: if self.status != RunStatus.COMPLETED: error_message = f"Run {self.name!r} is not completed, the status is {self.status!r}." if self.status != RunStatus.FAILED: error_message += " Please wait for its completion, or select other completed run(s)." raise InvalidRunStatusError(error_message) @staticmethod def _validate_and_return_run_name(run: Union[str, "Run"]) -> str: """Check if run name is valid.""" if isinstance(run, Run): return run.name elif isinstance(run, str): return run raise InvalidRunError(f"Invalid run {run!r}, expected 'str' or 'Run' object but got {type(run)!r}.") def _validate_for_run_create_operation(self): """Validate run object for create operation.""" # check flow value if Path(self.flow).is_dir(): # local flow pass elif isinstance(self.flow, str) and self.flow.startswith(REMOTE_URI_PREFIX): # remote flow pass else: raise UserErrorException( f"Invalid flow value: {self.flow!r}. Expecting a local flow folder path or a remote flow pattern " f"like '{REMOTE_URI_PREFIX}<flow-name>'" ) if is_remote_uri(self.data): # Pass through ARM id or remote url, the error will happen in runtime if format is not correct currently. pass else: if self.data and not Path(self.data).exists(): raise UserErrorException(f"data path {self.data} does not exist") if not self.run and not self.data: raise UserErrorException("at least one of data or run must be provided") def _generate_output_path(self, config: Optional[Configuration]) -> Path: config = config or Configuration.get_instance() path = config.get_run_output_path() if path is None: path = Path.home() / PROMPT_FLOW_DIR_NAME / ".runs" else: try: flow_posix_path = self.flow.resolve().as_posix() path = Path(path.replace(FLOW_DIRECTORY_MACRO_IN_CONFIG, self.flow.resolve().as_posix())).resolve() # in case user manually modifies ~/.promptflow/pf.yaml # fall back to default run output path if path.as_posix() == flow_posix_path: raise Exception(f"{FLOW_DIRECTORY_MACRO_IN_CONFIG!r} is not a valid value.") path.mkdir(parents=True, exist_ok=True) except Exception: # pylint: disable=broad-except path = Path.home() / PROMPT_FLOW_DIR_NAME / ".runs" warning_message = ( "Got unexpected error when parsing specified output path: " f"{config.get_run_output_path()!r}; " f"will use default output path: {path!r} instead." ) logger.warning(warning_message) return (path / str(self.name)).resolve() @classmethod def _load_from_source(cls, source: Union[str, Path], params_override: Optional[Dict] = None, **kwargs) -> "Run": """Load run from run record source folder.""" source = Path(source) params_override = params_override or {} run_metadata_file = source / DownloadedRun.RUN_METADATA_FILE_NAME if not run_metadata_file.exists(): raise UserErrorException( f"Invalid run source: {source!r}. Expecting a valid run source folder with {run_metadata_file!r}. " f"Please make sure the run source is downloaded by 'pfazure run download' command." ) # extract run info from source folder with open(source / DownloadedRun.RUN_METADATA_FILE_NAME, encoding=DEFAULT_ENCODING) as f: run_info = json.load(f) return cls( name=run_info["name"], source=source, run_source=RunInfoSources.EXISTING_RUN, status=run_info["status"], # currently only support completed run display_name=params_override.get("display_name", run_info.get("display_name", source.name)), description=params_override.get("description", run_info.get("description", "")), tags=params_override.get("tags", run_info.get("tags", {})), created_on=datetime.datetime.fromisoformat(run_info["created_on"]), start_time=datetime.datetime.fromisoformat(run_info["start_time"]), end_time=datetime.datetime.fromisoformat(run_info["end_time"]), **kwargs, )
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_eager_flow.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from os import PathLike from pathlib import Path from typing import Union from promptflow._constants import LANGUAGE_KEY, FlowLanguage from promptflow._sdk._constants import BASE_PATH_CONTEXT_KEY from promptflow._sdk.entities._flow import FlowBase from promptflow.exceptions import UserErrorException class EagerFlow(FlowBase): """This class is used to represent an eager flow.""" def __init__( self, path: Union[str, PathLike], entry: str, data: dict, **kwargs, ): self.path = Path(path) self.code = self.path.parent self.entry = entry self._data = data super().__init__(**kwargs) @property def language(self) -> str: return self._data.get(LANGUAGE_KEY, FlowLanguage.Python) @classmethod def _create_schema_for_validation(cls, context): # import here to avoid circular import from ..schemas._flow import EagerFlowSchema return EagerFlowSchema(context=context) @classmethod def _load(cls, path: Path, entry: str = None, data: dict = None, **kwargs): data = data or {} # schema validation on unknown fields if path.suffix in [".yaml", ".yml"]: data = cls._create_schema_for_validation(context={BASE_PATH_CONTEXT_KEY: path.parent}).load(data) path = data["path"] if entry: raise UserErrorException("Specifying entry function is not allowed when YAML file is provided.") else: entry = data["entry"] if entry is None: raise UserErrorException(f"Entry function is not specified for flow {path}") return cls(path=path, entry=entry, data=data, **kwargs)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_yaml_translatable.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import abc from typing import Dict, Optional from promptflow._sdk._constants import BASE_PATH_CONTEXT_KEY, CommonYamlFields from promptflow._sdk._utils import load_from_dict from promptflow._utils.yaml_utils import dump_yaml class YAMLTranslatableMixin(abc.ABC): @classmethod # pylint: disable=unused-argument def _resolve_cls_and_type(cls, data, params_override: Optional[list]): """Resolve the class to use for deserializing the data. Return current class if no override is provided. :param data: Data to deserialize. :type data: dict :param params_override: Parameters to override, defaults to None :type params_override: typing.Optional[list] :return: Class to use for deserializing the data & its "type". Type will be None if no override is provided. :rtype: tuple[class, typing.Optional[str]] """ @classmethod def _get_schema_cls(self): pass def _to_dict(self) -> Dict: schema_cls = self._get_schema_cls() return schema_cls(context={BASE_PATH_CONTEXT_KEY: "./"}).dump(self) def _to_yaml(self) -> str: return dump_yaml(self._to_dict()) def __str__(self): try: return self._to_yaml() except BaseException: # pylint: disable=broad-except return super(YAMLTranslatableMixin, self).__str__() @classmethod def _load_from_dict(cls, data: Dict, context: Dict, additional_message: str, **kwargs): schema_cls = cls._get_schema_cls() loaded_data = load_from_dict(schema_cls, data, context, additional_message, **kwargs) # pop the type field since it already exists in class init loaded_data.pop(CommonYamlFields.TYPE, None) return cls(base_path=context[BASE_PATH_CONTEXT_KEY], **loaded_data)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_connection.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import abc import importlib import json import types from os import PathLike from pathlib import Path from typing import Dict, List, Union from promptflow._core.token_provider import AzureTokenProvider, TokenProviderABC from promptflow._sdk._constants import ( BASE_PATH_CONTEXT_KEY, PARAMS_OVERRIDE_KEY, SCHEMA_KEYS_CONTEXT_CONFIG_KEY, SCHEMA_KEYS_CONTEXT_SECRET_KEY, SCRUBBED_VALUE, SCRUBBED_VALUE_NO_CHANGE, SCRUBBED_VALUE_USER_INPUT, ConfigValueType, ConnectionType, CustomStrongTypeConnectionConfigs, ) from promptflow._sdk._errors import UnsecureConnectionError, SDKError from promptflow._sdk._orm.connection import Connection as ORMConnection from promptflow._sdk._utils import ( decrypt_secret_value, encrypt_secret_value, find_type_in_override, in_jupyter_notebook, print_yellow_warning, snake_to_camel, ) from promptflow._sdk.entities._yaml_translatable import YAMLTranslatableMixin from promptflow._sdk.schemas._connection import ( AzureContentSafetyConnectionSchema, AzureOpenAIConnectionSchema, CognitiveSearchConnectionSchema, CustomConnectionSchema, CustomStrongTypeConnectionSchema, FormRecognizerConnectionSchema, OpenAIConnectionSchema, QdrantConnectionSchema, SerpConnectionSchema, WeaviateConnectionSchema, ) from promptflow._utils.logger_utils import LoggerFactory from promptflow.contracts.types import Secret from promptflow.exceptions import ValidationException, UserErrorException logger = LoggerFactory.get_logger(name=__name__) PROMPTFLOW_CONNECTIONS = "promptflow.connections" class _Connection(YAMLTranslatableMixin): """A connection entity that stores the connection information. :param name: Connection name :type name: str :param type: Possible values include: "OpenAI", "AzureOpenAI", "Custom". :type type: str :param module: The module of connection class, used for execution. :type module: str :param configs: The configs kv pairs. :type configs: Dict[str, str] :param secrets: The secrets kv pairs. :type secrets: Dict[str, str] """ TYPE = ConnectionType._NOT_SET def __init__( self, name: str = "default_connection", module: str = "promptflow.connections", configs: Dict[str, str] = None, secrets: Dict[str, str] = None, **kwargs, ): self.name = name self.type = self.TYPE self.class_name = f"{self.TYPE.value}Connection" # The type in executor connection dict self.configs = configs or {} self.module = module # Note the connection secrets value behaviors: # -------------------------------------------------------------------------------- # | secret value | CLI create | CLI update | SDK create_or_update | # -------------------------------------------------------------------------------- # | empty or all "*" | prompt input | use existing values | use existing values | # | <no-change> | prompt input | use existing values | use existing values | # | <user-input> | prompt input | prompt input | raise error | # -------------------------------------------------------------------------------- self.secrets = secrets or {} self._secrets = {**self.secrets} # Un-scrubbed secrets self.expiry_time = kwargs.get("expiry_time", None) self.created_date = kwargs.get("created_date", None) self.last_modified_date = kwargs.get("last_modified_date", None) # Conditional assignment to prevent entity bloat when unused. print_as_yaml = kwargs.pop("print_as_yaml", in_jupyter_notebook()) if print_as_yaml: self.print_as_yaml = True @classmethod def _casting_type(cls, typ): type_dict = { "azure_open_ai": ConnectionType.AZURE_OPEN_AI.value, "open_ai": ConnectionType.OPEN_AI.value, } if typ in type_dict: return type_dict.get(typ) return snake_to_camel(typ) def keys(self) -> List: """Return keys of the connection properties.""" return list(self.configs.keys()) + list(self.secrets.keys()) def __getitem__(self, item): # Note: This is added to allow usage **connection(). if item in self.secrets: return self.secrets[item] if item in self.configs: return self.configs[item] # raise UserErrorException(error=KeyError(f"Key {item!r} not found in connection {self.name!r}.")) # Cant't raise UserErrorException due to the code exit(1) of promptflow._cli._utils.py line 368. raise KeyError(f"Key {item!r} not found in connection {self.name!r}.") @classmethod def _is_scrubbed_value(cls, value): """For scrubbed value, cli will get original for update, and prompt user to input for create.""" if value is None or not value: return True if all([v == "*" for v in value]): return True return value == SCRUBBED_VALUE_NO_CHANGE @classmethod def _is_user_input_value(cls, value): """The value will prompt user to input in cli for both create and update.""" return value == SCRUBBED_VALUE_USER_INPUT def _validate_and_encrypt_secrets(self): encrypt_secrets = {} invalid_secrets = [] for k, v in self.secrets.items(): # In sdk experience, if v is not scrubbed, use it. # If v is scrubbed, try to use the value in _secrets. # If v is <user-input>, raise error. if self._is_scrubbed_value(v): # Try to get the value not scrubbed. v = self._secrets.get(k) if self._is_scrubbed_value(v) or self._is_user_input_value(v): # Can't find the original value or is <user-input>, raise error. invalid_secrets.append(k) continue encrypt_secrets[k] = encrypt_secret_value(v) if invalid_secrets: raise ValidationException( f"Connection {self.name!r} secrets {invalid_secrets} value invalid, please fill them." ) return encrypt_secrets @classmethod def _load_from_dict(cls, data: Dict, context: Dict, additional_message: str = None, **kwargs): schema_cls = cls._get_schema_cls() try: loaded_data = schema_cls(context=context).load(data, **kwargs) except Exception as e: raise SDKError(f"Load connection failed with {str(e)}. f{(additional_message or '')}.") return cls(base_path=context[BASE_PATH_CONTEXT_KEY], **loaded_data) def _to_dict(self) -> Dict: schema_cls = self._get_schema_cls() return schema_cls(context={BASE_PATH_CONTEXT_KEY: "./"}).dump(self) @classmethod # pylint: disable=unused-argument def _resolve_cls_and_type(cls, data, params_override=None): type_in_override = find_type_in_override(params_override) type_str = type_in_override or data.get("type") if type_str is None: raise ValidationException("type is required for connection.") type_str = cls._casting_type(type_str) type_cls = _supported_types.get(type_str) if type_cls is None: raise ValidationException( f"connection_type {type_str!r} is not supported. Supported types are: {list(_supported_types.keys())}" ) return type_cls, type_str @abc.abstractmethod def _to_orm_object(self) -> ORMConnection: pass @classmethod def _from_mt_rest_object(cls, mt_rest_obj) -> "_Connection": type_cls, _ = cls._resolve_cls_and_type(data={"type": mt_rest_obj.connection_type}) obj = type_cls._from_mt_rest_object(mt_rest_obj) return obj @classmethod def _from_orm_object_with_secrets(cls, orm_object: ORMConnection): # !!! Attention !!!: Do not use this function to user facing api, use _from_orm_object to remove secrets. type_cls, _ = cls._resolve_cls_and_type(data={"type": orm_object.connectionType}) obj = type_cls._from_orm_object_with_secrets(orm_object) return obj @classmethod def _from_orm_object(cls, orm_object: ORMConnection): """This function will create a connection object then scrub secrets.""" type_cls, _ = cls._resolve_cls_and_type(data={"type": orm_object.connectionType}) obj = type_cls._from_orm_object_with_secrets(orm_object) # Note: we may can't get secret keys for custom connection from MT obj.secrets = {k: SCRUBBED_VALUE for k in obj.secrets} return obj @classmethod def _load( cls, data: Dict = None, yaml_path: Union[PathLike, str] = None, params_override: list = None, **kwargs, ) -> "_Connection": """Load a job object from a yaml file. :param cls: Indicates that this is a class method. :type cls: class :param data: Data Dictionary, defaults to None :type data: Dict, optional :param yaml_path: YAML Path, defaults to None :type yaml_path: Union[PathLike, str], optional :param params_override: Fields to overwrite on top of the yaml file. Format is [{"field1": "value1"}, {"field2": "value2"}], defaults to None :type params_override: List[Dict], optional :param kwargs: A dictionary of additional configuration parameters. :type kwargs: dict :raises Exception: An exception :return: Loaded job object. :rtype: Job """ data = data or {} params_override = params_override or [] context = { BASE_PATH_CONTEXT_KEY: Path(yaml_path).parent if yaml_path else Path("../../azure/_entities/"), PARAMS_OVERRIDE_KEY: params_override, } connection_type, type_str = cls._resolve_cls_and_type(data, params_override) connection = connection_type._load_from_dict( data=data, context=context, additional_message=f"If you are trying to configure a job that is not of type {type_str}, please specify " f"the correct connection type in the 'type' property.", **kwargs, ) return connection def _to_execution_connection_dict(self) -> dict: value = {**self.configs, **self.secrets} secret_keys = list(self.secrets.keys()) return { "type": self.class_name, # Required class name for connection in executor "module": self.module, "value": {k: v for k, v in value.items() if v is not None}, # Filter None value out "secret_keys": secret_keys, } @classmethod def _from_execution_connection_dict(cls, name, data) -> "_Connection": type_cls, _ = cls._resolve_cls_and_type(data={"type": data.get("type")[: -len("Connection")]}) value_dict = data.get("value", {}) if type_cls == CustomConnection: secrets = {k: v for k, v in value_dict.items() if k in data.get("secret_keys", [])} configs = {k: v for k, v in value_dict.items() if k not in secrets} return CustomConnection(name=name, configs=configs, secrets=secrets) return type_cls(name=name, **value_dict) def _get_scrubbed_secrets(self): """Return the scrubbed secrets of connection.""" return {key: val for key, val in self.secrets.items() if self._is_scrubbed_value(val)} class _StrongTypeConnection(_Connection): def _to_orm_object(self): # Both keys & secrets will be stored in configs for strong type connection. secrets = self._validate_and_encrypt_secrets() return ORMConnection( connectionName=self.name, connectionType=self.type.value, configs=json.dumps({**self.configs, **secrets}), customConfigs="{}", expiryTime=self.expiry_time, createdDate=self.created_date, lastModifiedDate=self.last_modified_date, ) @classmethod def _from_orm_object_with_secrets(cls, orm_object: ORMConnection): # !!! Attention !!!: Do not use this function to user facing api, use _from_orm_object to remove secrets. # Both keys & secrets will be stored in configs for strong type connection. type_cls, _ = cls._resolve_cls_and_type(data={"type": orm_object.connectionType}) obj = type_cls( name=orm_object.connectionName, expiry_time=orm_object.expiryTime, created_date=orm_object.createdDate, last_modified_date=orm_object.lastModifiedDate, **json.loads(orm_object.configs), ) obj.secrets = {k: decrypt_secret_value(obj.name, v) for k, v in obj.secrets.items()} obj._secrets = {**obj.secrets} return obj @classmethod def _from_mt_rest_object(cls, mt_rest_obj): type_cls, _ = cls._resolve_cls_and_type(data={"type": mt_rest_obj.connection_type}) configs = mt_rest_obj.configs or {} # For not ARM strong type connection, e.g. OpenAI, api_key will not be returned, but is required argument. # For ARM strong type connection, api_key will be None and missing when conn._to_dict(), so set a scrubbed one. configs.update({"api_key": SCRUBBED_VALUE}) obj = type_cls( name=mt_rest_obj.connection_name, expiry_time=mt_rest_obj.expiry_time, created_date=mt_rest_obj.created_date, last_modified_date=mt_rest_obj.last_modified_date, **configs, ) return obj @property def api_key(self): """Return the api key.""" return self.secrets.get("api_key", SCRUBBED_VALUE) @api_key.setter def api_key(self, value): """Set the api key.""" self.secrets["api_key"] = value class AzureOpenAIConnection(_StrongTypeConnection): """Azure Open AI connection. :param api_key: The api key. :type api_key: str :param api_base: The api base. :type api_base: str :param api_type: The api type, default "azure". :type api_type: str :param api_version: The api version, default "2023-07-01-preview". :type api_version: str :param token_provider: The token provider. :type token_provider: promptflow._core.token_provider.TokenProviderABC :param name: Connection name. :type name: str """ TYPE = ConnectionType.AZURE_OPEN_AI def __init__( self, api_key: str, api_base: str, api_type: str = "azure", api_version: str = "2023-07-01-preview", token_provider: TokenProviderABC = None, **kwargs, ): configs = {"api_base": api_base, "api_type": api_type, "api_version": api_version} secrets = {"api_key": api_key} self._token_provider = token_provider super().__init__(configs=configs, secrets=secrets, **kwargs) @classmethod def _get_schema_cls(cls): return AzureOpenAIConnectionSchema @property def api_base(self): """Return the connection api base.""" return self.configs.get("api_base") @api_base.setter def api_base(self, value): """Set the connection api base.""" self.configs["api_base"] = value @property def api_type(self): """Return the connection api type.""" return self.configs.get("api_type") @api_type.setter def api_type(self, value): """Set the connection api type.""" self.configs["api_type"] = value @property def api_version(self): """Return the connection api version.""" return self.configs.get("api_version") @api_version.setter def api_version(self, value): """Set the connection api version.""" self.configs["api_version"] = value def get_token(self): """Return the connection token.""" if not self._token_provider: self._token_provider = AzureTokenProvider() return self._token_provider.get_token() class OpenAIConnection(_StrongTypeConnection): """Open AI connection. :param api_key: The api key. :type api_key: str :param organization: Optional. The unique identifier for your organization which can be used in API requests. :type organization: str :param base_url: Optional. Specify when use customized api base, leave None to use open ai default api base. :type base_url: str :param name: Connection name. :type name: str """ TYPE = ConnectionType.OPEN_AI def __init__(self, api_key: str, organization: str = None, base_url=None, **kwargs): if base_url == "": # Keep empty as None to avoid disturbing openai pick the default api base. base_url = None configs = {"organization": organization, "base_url": base_url} secrets = {"api_key": api_key} super().__init__(configs=configs, secrets=secrets, **kwargs) @classmethod def _get_schema_cls(cls): return OpenAIConnectionSchema @property def organization(self): """Return the connection organization.""" return self.configs.get("organization") @organization.setter def organization(self, value): """Set the connection organization.""" self.configs["organization"] = value @property def base_url(self): """Return the connection api base.""" return self.configs.get("base_url") @base_url.setter def base_url(self, value): """Set the connection api base.""" self.configs["base_url"] = value class SerpConnection(_StrongTypeConnection): """Serp connection. :param api_key: The api key. :type api_key: str :param name: Connection name. :type name: str """ TYPE = ConnectionType.SERP def __init__(self, api_key: str, **kwargs): secrets = {"api_key": api_key} super().__init__(secrets=secrets, **kwargs) @classmethod def _get_schema_cls(cls): return SerpConnectionSchema class _EmbeddingStoreConnection(_StrongTypeConnection): TYPE = ConnectionType._NOT_SET def __init__(self, api_key: str, api_base: str, **kwargs): configs = {"api_base": api_base} secrets = {"api_key": api_key} super().__init__(module="promptflow_vectordb.connections", configs=configs, secrets=secrets, **kwargs) @property def api_base(self): return self.configs.get("api_base") @api_base.setter def api_base(self, value): self.configs["api_base"] = value class QdrantConnection(_EmbeddingStoreConnection): """Qdrant connection. :param api_key: The api key. :type api_key: str :param api_base: The api base. :type api_base: str :param name: Connection name. :type name: str """ TYPE = ConnectionType.QDRANT @classmethod def _get_schema_cls(cls): return QdrantConnectionSchema class WeaviateConnection(_EmbeddingStoreConnection): """Weaviate connection. :param api_key: The api key. :type api_key: str :param api_base: The api base. :type api_base: str :param name: Connection name. :type name: str """ TYPE = ConnectionType.WEAVIATE @classmethod def _get_schema_cls(cls): return WeaviateConnectionSchema class CognitiveSearchConnection(_StrongTypeConnection): """Cognitive Search connection. :param api_key: The api key. :type api_key: str :param api_base: The api base. :type api_base: str :param api_version: The api version, default "2023-07-01-Preview". :type api_version: str :param name: Connection name. :type name: str """ TYPE = ConnectionType.COGNITIVE_SEARCH def __init__(self, api_key: str, api_base: str, api_version: str = "2023-07-01-Preview", **kwargs): configs = {"api_base": api_base, "api_version": api_version} secrets = {"api_key": api_key} super().__init__(configs=configs, secrets=secrets, **kwargs) @classmethod def _get_schema_cls(cls): return CognitiveSearchConnectionSchema @property def api_base(self): """Return the connection api base.""" return self.configs.get("api_base") @api_base.setter def api_base(self, value): """Set the connection api base.""" self.configs["api_base"] = value @property def api_version(self): """Return the connection api version.""" return self.configs.get("api_version") @api_version.setter def api_version(self, value): """Set the connection api version.""" self.configs["api_version"] = value class AzureContentSafetyConnection(_StrongTypeConnection): """Azure Content Safety connection. :param api_key: The api key. :type api_key: str :param endpoint: The api endpoint. :type endpoint: str :param api_version: The api version, default "2023-04-30-preview". :type api_version: str :param api_type: The api type, default "Content Safety". :type api_type: str :param name: Connection name. :type name: str """ TYPE = ConnectionType.AZURE_CONTENT_SAFETY def __init__( self, api_key: str, endpoint: str, api_version: str = "2023-10-01", api_type: str = "Content Safety", **kwargs, ): configs = {"endpoint": endpoint, "api_version": api_version, "api_type": api_type} secrets = {"api_key": api_key} super().__init__(configs=configs, secrets=secrets, **kwargs) @classmethod def _get_schema_cls(cls): return AzureContentSafetyConnectionSchema @property def endpoint(self): """Return the connection endpoint.""" return self.configs.get("endpoint") @endpoint.setter def endpoint(self, value): """Set the connection endpoint.""" self.configs["endpoint"] = value @property def api_version(self): """Return the connection api version.""" return self.configs.get("api_version") @api_version.setter def api_version(self, value): """Set the connection api version.""" self.configs["api_version"] = value @property def api_type(self): """Return the connection api type.""" return self.configs.get("api_type") @api_type.setter def api_type(self, value): """Set the connection api type.""" self.configs["api_type"] = value class FormRecognizerConnection(AzureContentSafetyConnection): """Form Recognizer connection. :param api_key: The api key. :type api_key: str :param endpoint: The api endpoint. :type endpoint: str :param api_version: The api version, default "2023-07-31". :type api_version: str :param api_type: The api type, default "Form Recognizer". :type api_type: str :param name: Connection name. :type name: str """ # Note: FormRecognizer and ContentSafety are using CognitiveService type in ARM, so keys are the same. TYPE = ConnectionType.FORM_RECOGNIZER def __init__( self, api_key: str, endpoint: str, api_version: str = "2023-07-31", api_type: str = "Form Recognizer", **kwargs ): super().__init__(api_key=api_key, endpoint=endpoint, api_version=api_version, api_type=api_type, **kwargs) @classmethod def _get_schema_cls(cls): return FormRecognizerConnectionSchema class CustomStrongTypeConnection(_Connection): """Custom strong type connection. .. note:: This connection type should not be used directly. Below is an example of how to use CustomStrongTypeConnection: .. code-block:: python class MyCustomConnection(CustomStrongTypeConnection): api_key: Secret api_base: str :param configs: The configs kv pairs. :type configs: Dict[str, str] :param secrets: The secrets kv pairs. :type secrets: Dict[str, str] :param name: Connection name :type name: str """ def __init__( self, secrets: Dict[str, str], configs: Dict[str, str] = None, **kwargs, ): # There are two cases to init a Custom strong type connection: # 1. The connection is created through SDK PFClient, custom_type and custom_module are not in the kwargs. # 2. The connection is loaded from template file, custom_type and custom_module are in the kwargs. custom_type = kwargs.get(CustomStrongTypeConnectionConfigs.TYPE, None) custom_module = kwargs.get(CustomStrongTypeConnectionConfigs.MODULE, None) if custom_type: configs.update({CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY: custom_type}) if custom_module: configs.update({CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY: custom_module}) self.kwargs = kwargs super().__init__(configs=configs, secrets=secrets, **kwargs) self.module = kwargs.get("module", self.__class__.__module__) self.custom_type = custom_type or self.__class__.__name__ self.package = kwargs.get(CustomStrongTypeConnectionConfigs.PACKAGE, None) self.package_version = kwargs.get(CustomStrongTypeConnectionConfigs.PACKAGE_VERSION, None) def __getattribute__(self, item): # Note: The reason to overwrite __getattribute__ instead of __getattr__ is as follows: # Custom strong type connection is written this way: # class MyCustomConnection(CustomStrongTypeConnection): # api_key: Secret # api_base: str = "This is a default value" # api_base has a default value, my_custom_connection_instance.api_base would not trigger __getattr__. # The default value will be returned directly instead of the real value in configs. annotations = getattr(super().__getattribute__("__class__"), "__annotations__", {}) if item in annotations: if annotations[item] == Secret: return self.secrets[item] else: return self.configs[item] return super().__getattribute__(item) def __setattr__(self, key, value): annotations = getattr(super().__getattribute__("__class__"), "__annotations__", {}) if key in annotations: if annotations[key] == Secret: self.secrets[key] = value else: self.configs[key] = value return super().__setattr__(key, value) def _to_orm_object(self) -> ORMConnection: custom_connection = self._convert_to_custom() return custom_connection._to_orm_object() def _convert_to_custom(self): # update configs self.configs.update({CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY: self.custom_type}) self.configs.update({CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY: self.module}) if self.package and self.package_version: self.configs.update({CustomStrongTypeConnectionConfigs.PROMPTFLOW_PACKAGE_KEY: self.package}) self.configs.update( {CustomStrongTypeConnectionConfigs.PROMPTFLOW_PACKAGE_VERSION_KEY: self.package_version} ) custom_connection = CustomConnection(configs=self.configs, secrets=self.secrets, **self.kwargs) return custom_connection @classmethod def _get_custom_keys(cls, data: Dict): # The data could be either from yaml or from DB. # If from yaml, 'custom_type' and 'module' are outside the configs of data. # If from DB, 'custom_type' and 'module' are within the configs of data. if not data.get(CustomStrongTypeConnectionConfigs.TYPE) or not data.get( CustomStrongTypeConnectionConfigs.MODULE ): if ( not data["configs"][CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY] or not data["configs"][CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY] ): error = ValueError("custom_type and module are required for custom strong type connections.") raise UserErrorException(message=str(error), error=error) else: m = data["configs"][CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY] custom_cls = data["configs"][CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY] else: m = data[CustomStrongTypeConnectionConfigs.MODULE] custom_cls = data[CustomStrongTypeConnectionConfigs.TYPE] try: module = importlib.import_module(m) cls = getattr(module, custom_cls) except ImportError: error = ValueError( f"Can't find module {m} in current environment. Please check the module is correctly configured." ) raise UserErrorException(message=str(error), error=error) except AttributeError: error = ValueError( f"Can't find class {custom_cls} in module {m}. " f"Please check the custom_type is correctly configured." ) raise UserErrorException(message=str(error), error=error) schema_configs = {} schema_secrets = {} for k, v in cls.__annotations__.items(): if v == Secret: schema_secrets[k] = v else: schema_configs[k] = v return schema_configs, schema_secrets @classmethod def _get_schema_cls(cls): return CustomStrongTypeConnectionSchema @classmethod def _load_from_dict(cls, data: Dict, context: Dict, additional_message: str = None, **kwargs): schema_config_keys, schema_secret_keys = cls._get_custom_keys(data) context[SCHEMA_KEYS_CONTEXT_CONFIG_KEY] = schema_config_keys context[SCHEMA_KEYS_CONTEXT_SECRET_KEY] = schema_secret_keys return (super()._load_from_dict(data, context, additional_message, **kwargs))._convert_to_custom() class CustomConnection(_Connection): """Custom connection. :param configs: The configs kv pairs. :type configs: Dict[str, str] :param secrets: The secrets kv pairs. :type secrets: Dict[str, str] :param name: Connection name :type name: str """ TYPE = ConnectionType.CUSTOM def __init__( self, secrets: Dict[str, str], configs: Dict[str, str] = None, **kwargs, ): super().__init__(secrets=secrets, configs=configs, **kwargs) @classmethod def _get_schema_cls(cls): return CustomConnectionSchema @classmethod def _load_from_dict(cls, data: Dict, context: Dict, additional_message: str = None, **kwargs): # If context has params_override, it means the data would be updated by overridden values. # Provide CustomStrongTypeConnectionSchema if 'custom_type' in params_override, else CustomConnectionSchema. # For example: # If a user updates an existing connection by re-upserting a connection file, # the 'data' from DB is CustomConnection, # but 'params_override' would actually contain custom strong type connection data. is_custom_strong_type = data.get(CustomStrongTypeConnectionConfigs.TYPE) or any( CustomStrongTypeConnectionConfigs.TYPE in d for d in context.get(PARAMS_OVERRIDE_KEY, []) ) if is_custom_strong_type: return CustomStrongTypeConnection._load_from_dict(data, context, additional_message, **kwargs) return super()._load_from_dict(data, context, additional_message, **kwargs) def __getattr__(self, item): # Note: This is added for compatibility with promptflow.connections custom connection usage. if item == "secrets": # Usually obj.secrets will not reach here # This is added to handle copy.deepcopy loop issue return super().__getattribute__("secrets") if item == "configs": # Usually obj.configs will not reach here # This is added to handle copy.deepcopy loop issue return super().__getattribute__("configs") if item in self.secrets: logger.warning("Please use connection.secrets[key] to access secrets.") return self.secrets[item] if item in self.configs: logger.warning("Please use connection.configs[key] to access configs.") return self.configs[item] return super().__getattribute__(item) def is_secret(self, item): """Check if item is a secret.""" # Note: This is added for compatibility with promptflow.connections custom connection usage. return item in self.secrets def _to_orm_object(self): # Both keys & secrets will be set in custom configs with value type specified for custom connection. if not self.secrets: error = ValueError( "Secrets is required for custom connection, " "please use CustomConnection(configs={key1: val1}, secrets={key2: val2}) " "to initialize custom connection." ) raise UserErrorException(message=str(error), error=error) custom_configs = { k: {"configValueType": ConfigValueType.STRING.value, "value": v} for k, v in self.configs.items() } encrypted_secrets = self._validate_and_encrypt_secrets() custom_configs.update( {k: {"configValueType": ConfigValueType.SECRET.value, "value": v} for k, v in encrypted_secrets.items()} ) return ORMConnection( connectionName=self.name, connectionType=self.type.value, configs="{}", customConfigs=json.dumps(custom_configs), expiryTime=self.expiry_time, createdDate=self.created_date, lastModifiedDate=self.last_modified_date, ) @classmethod def _from_orm_object_with_secrets(cls, orm_object: ORMConnection): # !!! Attention !!!: Do not use this function to user facing api, use _from_orm_object to remove secrets. # Both keys & secrets will be set in custom configs with value type specified for custom connection. configs = { k: v["value"] for k, v in json.loads(orm_object.customConfigs).items() if v["configValueType"] == ConfigValueType.STRING.value } secrets = {} unsecure_connection = False custom_type = None for k, v in json.loads(orm_object.customConfigs).items(): if k == CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY: custom_type = v["value"] continue if not v["configValueType"] == ConfigValueType.SECRET.value: continue try: secrets[k] = decrypt_secret_value(orm_object.connectionName, v["value"]) except UnsecureConnectionError: # This is to workaround old custom secrets that are not encrypted with Fernet. unsecure_connection = True secrets[k] = v["value"] if unsecure_connection: print_yellow_warning( f"Warning: Please delete and re-create connection {orm_object.connectionName} " "due to a security issue in the old sdk version." ) return cls( name=orm_object.connectionName, configs=configs, secrets=secrets, custom_type=custom_type, expiry_time=orm_object.expiryTime, created_date=orm_object.createdDate, last_modified_date=orm_object.lastModifiedDate, ) @classmethod def _from_mt_rest_object(cls, mt_rest_obj): type_cls, _ = cls._resolve_cls_and_type(data={"type": mt_rest_obj.connection_type}) if not mt_rest_obj.custom_configs: mt_rest_obj.custom_configs = {} configs = { k: v.value for k, v in mt_rest_obj.custom_configs.items() if v.config_value_type == ConfigValueType.STRING.value } secrets = { k: v.value for k, v in mt_rest_obj.custom_configs.items() if v.config_value_type == ConfigValueType.SECRET.value } return cls( name=mt_rest_obj.connection_name, configs=configs, secrets=secrets, expiry_time=mt_rest_obj.expiry_time, created_date=mt_rest_obj.created_date, last_modified_date=mt_rest_obj.last_modified_date, ) def _is_custom_strong_type(self): return ( CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY in self.configs and self.configs[CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY] ) def _convert_to_custom_strong_type(self, module=None, to_class=None) -> CustomStrongTypeConnection: # There are two scenarios to convert a custom connection to custom strong type connection: # 1. The connection is created from a custom strong type connection template file. # Custom type and module name are present in the configs. # 2. The connection is created through SDK PFClient or a custom connection template file. # Custom type and module name are not present in the configs. Module and class must be passed for conversion. if to_class == self.__class__.__name__: # No need to convert. return self import importlib if ( CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY in self.configs and CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY in self.configs ): module_name = self.configs.get(CustomStrongTypeConnectionConfigs.PROMPTFLOW_MODULE_KEY) module = importlib.import_module(module_name) custom_conn_name = self.configs.get(CustomStrongTypeConnectionConfigs.PROMPTFLOW_TYPE_KEY) elif isinstance(module, str) and isinstance(to_class, str): module_name = module module = importlib.import_module(module_name) custom_conn_name = to_class elif isinstance(module, types.ModuleType) and isinstance(to_class, str): custom_conn_name = to_class else: error = ValueError( f"Failed to convert to custom strong type connection because of " f"invalid module or class: {module}, {to_class}" ) raise UserErrorException(message=str(error), error=error) custom_defined_connection_class = getattr(module, custom_conn_name) connection_instance = custom_defined_connection_class(configs=self.configs, secrets=self.secrets) return connection_instance _supported_types = { v.TYPE.value: v for v in globals().values() if isinstance(v, type) and issubclass(v, _Connection) and not v.__name__.startswith("_") }
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_flow.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import abc import json from os import PathLike from pathlib import Path from typing import Dict, Optional, Tuple, Union from marshmallow import Schema from promptflow._constants import LANGUAGE_KEY, FlowLanguage from promptflow._sdk._constants import ( BASE_PATH_CONTEXT_KEY, DAG_FILE_NAME, DEFAULT_ENCODING, FLOW_TOOLS_JSON, PROMPT_FLOW_DIR_NAME, ) from promptflow._sdk.entities._connection import _Connection from promptflow._sdk.entities._validation import SchemaValidatableMixin from promptflow._utils.flow_utils import resolve_flow_path from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow._utils.yaml_utils import load_yaml, load_yaml_string from promptflow.exceptions import ErrorTarget, UserErrorException logger = get_cli_sdk_logger() class FlowContext: """Flow context entity. the settings on this context will be applied to the flow when executing. :param connections: Connections for the flow. :type connections: Optional[Dict[str, Dict]] :param variant: Variant of the flow. :type variant: Optional[str] :param variant: Overrides of the flow. :type variant: Optional[Dict[str, Dict]] :param streaming: Whether the flow's output need to be return in streaming mode. :type streaming: Optional[bool] """ def __init__( self, *, connections=None, variant=None, overrides=None, streaming=None, ): self.connections, self._connection_objs = connections or {}, {} self.variant = variant self.overrides = overrides or {} self.streaming = streaming # TODO: introduce connection provider support def _resolve_connections(self): # resolve connections and create placeholder for connection objects for _, v in self.connections.items(): if isinstance(v, dict): for k, conn in v.items(): if isinstance(conn, _Connection): name = self._get_connection_obj_name(conn) v[k] = name self._connection_objs[name] = conn @classmethod def _get_connection_obj_name(cls, connection: _Connection): # create a unique connection name for connection obj # will generate same name if connection has same content connection_dict = connection._to_dict() connection_name = f"connection_{hash(json.dumps(connection_dict, sort_keys=True))}" return connection_name def _to_dict(self): return { "connections": self.connections, "variant": self.variant, "overrides": self.overrides, "streaming": self.streaming, } def __eq__(self, other): if isinstance(other, FlowContext): return self._to_dict() == other._to_dict() return False def __hash__(self): self._resolve_connections() return hash(json.dumps(self._to_dict(), sort_keys=True)) class FlowBase(abc.ABC): def __init__(self, **kwargs): self._context = FlowContext() self._content_hash = kwargs.pop("content_hash", None) super().__init__(**kwargs) @property def context(self) -> FlowContext: return self._context @context.setter def context(self, val): if not isinstance(val, FlowContext): raise UserErrorException("context must be a FlowContext object, got {type(val)} instead.") self._context = val @property @abc.abstractmethod def language(self) -> str: """Language of the flow.""" @classmethod # pylint: disable=unused-argument def _resolve_cls_and_type(cls, data, params_override): """Resolve the class to use for deserializing the data. Return current class if no override is provided. :param data: Data to deserialize. :type data: dict :param params_override: Parameters to override, defaults to None :type params_override: typing.Optional[list] :return: Class to use for deserializing the data & its "type". Type will be None if no override is provided. :rtype: tuple[class, typing.Optional[str]] """ return cls, "flow" class Flow(FlowBase): """This class is used to represent a flow.""" def __init__( self, code: Union[str, PathLike], dag: dict, **kwargs, ): self._code = Path(code) path = kwargs.pop("path", None) self._path = Path(path) if path else None self.variant = kwargs.pop("variant", None) or {} self.dag = dag super().__init__(**kwargs) @property def code(self) -> Path: return self._code @code.setter def code(self, value: Union[str, PathLike, Path]): self._code = value @property def path(self) -> Path: flow_file = self._path or self.code / DAG_FILE_NAME if not flow_file.is_file(): raise UserErrorException( "The directory does not contain a valid flow.", target=ErrorTarget.CONTROL_PLANE_SDK, ) return flow_file @property def language(self) -> str: return self.dag.get(LANGUAGE_KEY, FlowLanguage.Python) @classmethod def _is_eager_flow(cls, data: dict): """Check if the flow is an eager flow. Use field 'entry' to determine.""" # If entry specified, it's an eager flow. return data.get("entry") @classmethod def load( cls, source: Union[str, PathLike], entry: str = None, **kwargs, ): from promptflow._sdk.entities._eager_flow import EagerFlow source_path = Path(source) if not source_path.exists(): raise UserErrorException(f"Source {source_path.absolute().as_posix()} does not exist") flow_path = resolve_flow_path(source_path) if not flow_path.exists(): raise UserErrorException(f"Flow file {flow_path.absolute().as_posix()} does not exist") if flow_path.suffix in [".yaml", ".yml"]: # read flow file to get hash with open(flow_path, "r", encoding=DEFAULT_ENCODING) as f: flow_content = f.read() data = load_yaml_string(flow_content) kwargs["content_hash"] = hash(flow_content) is_eager_flow = cls._is_eager_flow(data) if is_eager_flow: return EagerFlow._load(path=flow_path, entry=entry, data=data, **kwargs) else: # TODO: schema validation and warning on unknown fields return ProtectedFlow._load(path=flow_path, dag=data, **kwargs) # if non-YAML file is provided, treat is as eager flow return EagerFlow._load(path=flow_path, entry=entry, **kwargs) def _init_executable(self, tuning_node=None, variant=None): from promptflow._sdk._submitter import variant_overwrite_context # TODO: check if there is potential bug here # this is a little wired: # 1. the executable is created from a temp folder when there is additional includes # 2. after the executable is returned, the temp folder is deleted with variant_overwrite_context(self.code, tuning_node, variant) as flow: from promptflow.contracts.flow import Flow as ExecutableFlow return ExecutableFlow.from_yaml(flow_file=flow.path, working_dir=flow.code) def __eq__(self, other): if isinstance(other, Flow): return self._content_hash == other._content_hash and self.context == other.context return False def __hash__(self): return hash(self.context) ^ self._content_hash class ProtectedFlow(Flow, SchemaValidatableMixin): """This class is used to hide internal interfaces from user. User interface should be carefully designed to avoid breaking changes, while developers may need to change internal interfaces to improve the code quality. On the other hand, making all internal interfaces private will make it strange to use them everywhere inside this package. Ideally, developers should always initialize ProtectedFlow object instead of Flow object. """ def __init__( self, code: str, params_override: Optional[Dict] = None, **kwargs, ): super().__init__(code=code, **kwargs) self._flow_dir, self._dag_file_name = self._get_flow_definition(self.code) self._executable = None self._params_override = params_override @classmethod def _load(cls, path: Path, dag: dict, **kwargs): return cls(code=path.parent.absolute().as_posix(), dag=dag, **kwargs) @property def flow_dag_path(self) -> Path: return self._flow_dir / self._dag_file_name @property def name(self) -> str: return self._flow_dir.name @property def display_name(self) -> str: return self.dag.get("display_name", self.name) @property def tools_meta_path(self) -> Path: target_path = self._flow_dir / PROMPT_FLOW_DIR_NAME / FLOW_TOOLS_JSON target_path.parent.mkdir(parents=True, exist_ok=True) return target_path @classmethod def _get_flow_definition(cls, flow, base_path=None) -> Tuple[Path, str]: if base_path: flow_path = Path(base_path) / flow else: flow_path = Path(flow) if flow_path.is_dir() and (flow_path / DAG_FILE_NAME).is_file(): return flow_path, DAG_FILE_NAME elif flow_path.is_file(): return flow_path.parent, flow_path.name raise ValueError(f"Can't find flow with path {flow_path.as_posix()}.") # region SchemaValidatableMixin @classmethod def _create_schema_for_validation(cls, context) -> Schema: # import here to avoid circular import from ..schemas._flow import FlowSchema return FlowSchema(context=context) def _default_context(self) -> dict: return {BASE_PATH_CONTEXT_KEY: self._flow_dir} def _create_validation_error(self, message, no_personal_data_message=None): return UserErrorException( message=message, target=ErrorTarget.CONTROL_PLANE_SDK, no_personal_data_message=no_personal_data_message, ) def _dump_for_validation(self) -> Dict: # Flow is read-only in control plane, so we always dump the flow from file data = load_yaml(self.flow_dag_path) if isinstance(self._params_override, dict): data.update(self._params_override) return data # endregion # region MLFlow model requirements @property def inputs(self): # This is used for build mlflow model signature. if not self._executable: self._executable = self._init_executable() return {k: v.type.value for k, v in self._executable.inputs.items()} @property def outputs(self): # This is used for build mlflow model signature. if not self._executable: self._executable = self._init_executable() return {k: v.type.value for k, v in self._executable.outputs.items()} # endregion def __call__(self, *args, **kwargs): """Calling flow as a function, the inputs should be provided with key word arguments. Returns the output of the flow. The function call throws UserErrorException: if the flow is not valid or the inputs are not valid. SystemErrorException: if the flow execution failed due to unexpected executor error. :param args: positional arguments are not supported. :param kwargs: flow inputs with key word arguments. :return: """ if args: raise UserErrorException("Flow can only be called with keyword arguments.") result = self.invoke(inputs=kwargs) return result.output def invoke(self, inputs: dict) -> "LineResult": """Invoke a flow and get a LineResult object.""" from promptflow._sdk._submitter.test_submitter import TestSubmitterViaProxy from promptflow._sdk.operations._flow_context_resolver import FlowContextResolver if self.dag.get(LANGUAGE_KEY, FlowLanguage.Python) == FlowLanguage.CSharp: with TestSubmitterViaProxy(flow=self, flow_context=self.context).init() as submitter: result = submitter.exec_with_inputs( inputs=inputs, ) return result else: invoker = FlowContextResolver.resolve(flow=self) result = invoker._invoke( data=inputs, ) return result
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- # isort: skip_file # skip to avoid circular import __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore from ._connection import ( AzureContentSafetyConnection, AzureOpenAIConnection, CognitiveSearchConnection, CustomConnection, OpenAIConnection, SerpConnection, QdrantConnection, WeaviateConnection, FormRecognizerConnection, CustomStrongTypeConnection, ) from ._run import Run from ._validation import ValidationResult from ._flow import FlowContext __all__ = [ # region: Connection "AzureContentSafetyConnection", "AzureOpenAIConnection", "OpenAIConnection", "CustomConnection", "CustomStrongTypeConnection", "CognitiveSearchConnection", "SerpConnection", "QdrantConnection", "WeaviateConnection", "FormRecognizerConnection", # endregion # region Run "Run", "ValidationResult", # endregion # region Flow "FlowContext", # endregion ]
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_validation/core.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- # pylint: disable=protected-access import copy import json import os.path import typing from pathlib import Path from typing import Dict, List, Optional import pydash import strictyaml from marshmallow import ValidationError from promptflow._utils.logger_utils import get_cli_sdk_logger logger = get_cli_sdk_logger() class _ValidationStatus: """Validation status class. Validation status is used to indicate the status of an validation result. It can be one of the following values: Succeeded, Failed. """ SUCCEEDED = "Succeeded" """Succeeded.""" FAILED = "Failed" """Failed.""" class Diagnostic(object): """Represents a diagnostic of an asset validation error with the location info.""" def __init__(self, yaml_path: str, message: str, error_code: str, **kwargs) -> None: """Init Diagnostic. :keyword yaml_path: A dash path from root to the target element of the diagnostic. :paramtype yaml_path: str :keyword message: Error message of diagnostic. :paramtype message: str :keyword error_code: Error code of diagnostic. :paramtype error_code: str """ self.yaml_path = yaml_path self.message = message self.error_code = error_code self.local_path, self.value = None, None self._key = kwargs.pop("key", "yaml_path") # Set extra info to attribute for k, v in kwargs.items(): if not k.startswith("_"): setattr(self, k, v) def __repr__(self) -> str: """The asset friendly name and error message. :return: The formatted diagnostic :rtype: str """ return "{}: {}".format(getattr(self, self._key), self.message) @classmethod def create_instance( cls, yaml_path: str, message: Optional[str] = None, error_code: Optional[str] = None, **kwargs, ): """Create a diagnostic instance. :param yaml_path: A dash path from root to the target element of the diagnostic. :type yaml_path: str :param message: Error message of diagnostic. :type message: str :param error_code: Error code of diagnostic. :type error_code: str :return: The created instance :rtype: Diagnostic """ return cls( yaml_path=yaml_path, message=message, error_code=error_code, **kwargs, ) class ValidationResult(object): """Represents the result of validation. This class is used to organize and parse diagnostics from both client & server side before expose them. The result is immutable. """ def __init__(self) -> None: self._target_obj = None self._errors = [] self._warnings = [] self._kwargs = {} def _set_extra_info(self, key, value): self._kwargs[key] = value def _get_extra_info(self, key, default=None): return self._kwargs.get(key, default) @property def error_messages(self) -> Dict: """ Return all messages of errors in the validation result. :return: A dictionary of error messages. The key is the yaml path of the error, and the value is the error message. :rtype: dict """ messages = {} for diagnostic in self._errors: message_key = getattr(diagnostic, diagnostic._key) if message_key not in messages: messages[message_key] = diagnostic.message else: messages[message_key] += "; " + diagnostic.message return messages @property def passed(self) -> bool: """Returns boolean indicating whether any errors were found. :return: True if the validation passed, False otherwise. :rtype: bool """ return not self._errors def _to_dict(self) -> typing.Dict[str, typing.Any]: result = { "result": _ValidationStatus.SUCCEEDED if self.passed else _ValidationStatus.FAILED, } result.update(self._kwargs) for diagnostic_type, diagnostics in [ ("errors", self._errors), ("warnings", self._warnings), ]: messages = [] for diagnostic in diagnostics: message = { "message": diagnostic.message, "path": diagnostic.yaml_path, "value": pydash.get(self._target_obj, diagnostic.yaml_path, diagnostic.value), } if diagnostic.local_path: message["location"] = str(diagnostic.local_path) for attr in dir(diagnostic): if attr not in message and not attr.startswith("_") and not callable(getattr(diagnostic, attr)): message[attr] = getattr(diagnostic, attr) message = {k: v for k, v in message.items() if v is not None} messages.append(message) if messages: result[diagnostic_type] = messages return result def __repr__(self) -> str: """Get the string representation of the validation result. :return: The string representation :rtype: str """ return json.dumps(self._to_dict(), indent=2) class MutableValidationResult(ValidationResult): """Used by the client side to construct a validation result. The result is mutable and should not be exposed to the user. """ def __init__(self, target_obj: Optional[typing.Dict[str, typing.Any]] = None): super().__init__() self._target_obj = target_obj def merge_with( self, target: ValidationResult, field_name: Optional[str] = None, condition_skip: Optional[typing.Callable] = None, overwrite: bool = False, ): """Merge errors & warnings in another validation results into current one. Will update current validation result. If field_name is not None, then yaml_path in the other validation result will be updated accordingly. * => field_name, a.b => field_name.a.b e.g.. If None, then no update. :param target: Validation result to merge. :type target: ValidationResult :param field_name: The base field name for the target to merge. :type field_name: str :param condition_skip: A function to determine whether to skip the merge of a diagnostic in the target. :type condition_skip: typing.Callable :param overwrite: Whether to overwrite the current validation result. If False, all diagnostics will be kept; if True, current diagnostics with the same yaml_path will be dropped. :type overwrite: bool :return: The current validation result. :rtype: MutableValidationResult """ for source_diagnostics, target_diagnostics in [ (target._errors, self._errors), (target._warnings, self._warnings), ]: if overwrite: keys_to_remove = set(map(lambda x: x.yaml_path, source_diagnostics)) target_diagnostics[:] = [ diagnostic for diagnostic in target_diagnostics if diagnostic.yaml_path not in keys_to_remove ] for diagnostic in source_diagnostics: if condition_skip and condition_skip(diagnostic): continue new_diagnostic = copy.deepcopy(diagnostic) if field_name: if new_diagnostic.yaml_path == "*": new_diagnostic.yaml_path = field_name else: new_diagnostic.yaml_path = field_name + "." + new_diagnostic.yaml_path target_diagnostics.append(new_diagnostic) return self def try_raise( self, raise_error: bool = True, *, error_func: typing.Callable[[str, str], Exception] = None, ) -> "MutableValidationResult": """Try to raise an error from the validation result. If the validation is passed or raise_error is False, this method will return the validation result. :param raise_error: Whether to raise the error. :type raise_error: bool :keyword error_func: A function to create the error. If None, a marshmallow.ValidationError will be created. The first parameter of the function is the string representation of the validation result, and the second parameter is the error message without personal data. :type error_func: typing.Callable[[str, str], Exception] :return: The current validation result. :rtype: MutableValidationResult """ # pylint: disable=logging-not-lazy if raise_error is False: return self if self._warnings: logger.warning("Schema validation warnings: %s" % str(self._warnings)) if not self.passed: if error_func is None: def error_func(msg, _): return ValidationError(message=msg) raise error_func( self.__repr__(), f"Schema validation failed: {self.error_messages}", ) return self def append_error( self, yaml_path: str = "*", message: Optional[str] = None, error_code: Optional[str] = None, **kwargs, ): """Append an error to the validation result. :param yaml_path: The yaml path of the error. :type yaml_path: str :param message: The message of the error. :type message: str :param error_code: The error code of the error. :type error_code: str :return: The current validation result. :rtype: MutableValidationResult """ self._errors.append( Diagnostic.create_instance( yaml_path=yaml_path, message=message, error_code=error_code, **kwargs, ) ) return self def resolve_location_for_diagnostics(self, source_path: str, resolve_value: bool = False): """Resolve location/value for diagnostics based on the source path where the validatable object is loaded. Location includes local path of the exact file (can be different from the source path) & line number of the invalid field. Value of a diagnostic is resolved from the validatable object in transfering to a dict by default; however, when the validatable object is not available for the validation result, validation result is created from marshmallow.ValidationError.messages e.g., it can be resolved from the source path. :param source_path: The path of the source file. :type source_path: str :param resolve_value: Whether to resolve the value of the invalid field from source file. :type resolve_value: bool """ resolver = _YamlLocationResolver(source_path) for diagnostic in self._errors + self._warnings: diagnostic.local_path, value = resolver.resolve(diagnostic.yaml_path) if value is not None and resolve_value: diagnostic.value = value def append_warning( self, yaml_path: str = "*", message: Optional[str] = None, error_code: Optional[str] = None, **kwargs, ): """Append a warning to the validation result. :param yaml_path: The yaml path of the warning. :type yaml_path: str :param message: The message of the warning. :type message: str :param error_code: The error code of the warning. :type error_code: str :return: The current validation result. :rtype: MutableValidationResult """ self._warnings.append( Diagnostic.create_instance( yaml_path=yaml_path, message=message, error_code=error_code, **kwargs, ) ) return self class ValidationResultBuilder: """A helper class to create a validation result.""" UNKNOWN_MESSAGE = "Unknown field." def __init__(self): pass @classmethod def success(cls) -> MutableValidationResult: """Create a validation result with success status. :return: A validation result :rtype: MutableValidationResult """ return MutableValidationResult() @classmethod def from_single_message( cls, singular_error_message: Optional[str] = None, yaml_path: str = "*", data: Optional[dict] = None ): """Create a validation result with only 1 diagnostic. :param singular_error_message: diagnostic.message. :type singular_error_message: Optional[str] :param yaml_path: diagnostic.yaml_path. :type yaml_path: str :param data: serializedvalidation target. :type data: Optional[Dict] :return: The validation result :rtype: MutableValidationResult """ obj = MutableValidationResult(target_obj=data) if singular_error_message: obj.append_error(message=singular_error_message, yaml_path=yaml_path) return obj @classmethod def from_validation_error( cls, error: ValidationError, *, source_path: Optional[str] = None, error_on_unknown_field=False ) -> MutableValidationResult: """Create a validation result from a ValidationError, which will be raised in marshmallow.Schema.load. Please use this function only for exception in loading file. :param error: ValidationError raised by marshmallow.Schema.load. :type error: ValidationError :keyword error_on_unknown_field: whether to raise error if there are unknown field diagnostics. :paramtype error_on_unknown_field: bool :return: The validation result :rtype: MutableValidationResult """ obj = cls.from_validation_messages( error.messages, data=error.data, error_on_unknown_field=error_on_unknown_field ) if source_path: obj.resolve_location_for_diagnostics(source_path, resolve_value=True) return obj @classmethod def from_validation_messages( cls, errors: typing.Dict, data: typing.Dict, *, error_on_unknown_field: bool = False ) -> MutableValidationResult: """Create a validation result from error messages, which will be returned by marshmallow.Schema.validate. :param errors: error message returned by marshmallow.Schema.validate. :type errors: dict :param data: serialized data to validate :type data: dict :keyword error_on_unknown_field: whether to raise error if there are unknown field diagnostics. :paramtype error_on_unknown_field: bool :return: The validation result :rtype: MutableValidationResult """ instance = MutableValidationResult(target_obj=data) errors = copy.deepcopy(errors) cls._from_validation_messages_recursively(errors, [], instance, error_on_unknown_field=error_on_unknown_field) return instance @classmethod def _from_validation_messages_recursively( cls, errors: typing.Union[typing.Dict, typing.List, str], path_stack: typing.List[str], instance: MutableValidationResult, error_on_unknown_field: bool, ): cur_path = ".".join(path_stack) if path_stack else "*" # single error message if isinstance(errors, dict) and "_schema" in errors: instance.append_error( message=";".join(errors["_schema"]), yaml_path=cur_path, ) # errors on attributes elif isinstance(errors, dict): for field, msgs in errors.items(): # fields.Dict if field in ["key", "value"]: cls._from_validation_messages_recursively(msgs, path_stack, instance, error_on_unknown_field) else: # Todo: Add hack logic here to deal with error message in nested TypeSensitiveUnionField in # DataTransfer: will be a nested dict with None field as dictionary key. # open a item to track: https://msdata.visualstudio.com/Vienna/_workitems/edit/2244262/ if field is None: cls._from_validation_messages_recursively(msgs, path_stack, instance, error_on_unknown_field) else: path_stack.append(field) cls._from_validation_messages_recursively(msgs, path_stack, instance, error_on_unknown_field) path_stack.pop() # detailed error message elif isinstance(errors, list) and all(isinstance(msg, str) for msg in errors): if cls.UNKNOWN_MESSAGE in errors and not error_on_unknown_field: # Unknown field is not a real error, so we should remove it and append a warning. errors.remove(cls.UNKNOWN_MESSAGE) instance.append_warning(message=cls.UNKNOWN_MESSAGE, yaml_path=cur_path) if errors: instance.append_error(message=";".join(errors), yaml_path=cur_path) # union field elif isinstance(errors, list): def msg2str(msg): if isinstance(msg, str): return msg if isinstance(msg, dict) and len(msg) == 1 and "_schema" in msg and len(msg["_schema"]) == 1: return msg["_schema"][0] return str(msg) instance.append_error(message="; ".join([msg2str(x) for x in errors]), yaml_path=cur_path) # unknown error else: instance.append_error(message=str(errors), yaml_path=cur_path) class _YamlLocationResolver: def __init__(self, source_path): self._source_path = source_path def resolve(self, yaml_path, source_path=None): """Resolve the location & value of a yaml path starting from source_path. :param yaml_path: yaml path. :type yaml_path: str :param source_path: source path. :type source_path: str :return: the location & value of the yaml path based on source_path. :rtype: Tuple[str, str] """ source_path = source_path or self._source_path if source_path is None or not os.path.isfile(source_path): return None, None if yaml_path is None or yaml_path == "*": return source_path, None attrs = yaml_path.split(".") attrs.reverse() return self._resolve_recursively(attrs, Path(source_path)) def _resolve_recursively(self, attrs: List[str], source_path: Path): with open(source_path, encoding="utf-8") as f: try: loaded_yaml = strictyaml.load(f.read()) except Exception as e: # pylint: disable=broad-except msg = "Can't load source file %s as a strict yaml:\n%s" % (source_path, str(e)) logger.debug(msg) return None, None while attrs: attr = attrs[-1] if loaded_yaml.is_mapping() and attr in loaded_yaml: loaded_yaml = loaded_yaml.get(attr) attrs.pop() elif loaded_yaml.is_sequence() and attr.isdigit() and 0 <= int(attr) < len(loaded_yaml): loaded_yaml = loaded_yaml[int(attr)] attrs.pop() else: try: # if current object is a path of a valid yaml file, try to resolve location in new source file next_path = Path(loaded_yaml.value) if not next_path.is_absolute(): next_path = source_path.parent / next_path if next_path.is_file(): return self._resolve_recursively(attrs, source_path=next_path) except OSError: pass except TypeError: pass # if not, return current section break return ( f"{source_path.resolve().absolute()}#line {loaded_yaml.start_line}", None if attrs else loaded_yaml.value, )
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_validation/schema.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- # pylint: disable=protected-access import json import typing from marshmallow import Schema, ValidationError from promptflow._utils.logger_utils import LoggerFactory from .core import MutableValidationResult, ValidationResultBuilder module_logger = LoggerFactory.get_logger(__name__) class SchemaValidatableMixin: """The mixin class for schema validation.""" @classmethod def _create_empty_validation_result(cls) -> MutableValidationResult: """Simply create an empty validation result To reduce _ValidationResultBuilder importing, which is a private class. :return: An empty validation result :rtype: MutableValidationResult """ return ValidationResultBuilder.success() @classmethod def _load_with_schema(cls, data, *, context, raise_original_exception=False, **kwargs): schema = cls._create_schema_for_validation(context=context) try: return schema.load(data, **kwargs) except ValidationError as e: if raise_original_exception: raise e msg = "Trying to load data with schema failed. Data:\n%s\nError: %s" % ( json.dumps(data, indent=4) if isinstance(data, dict) else data, json.dumps(e.messages, indent=4), ) raise cls._create_validation_error( message=msg, no_personal_data_message=str(e), ) from e @classmethod # pylint: disable-next=docstring-missing-param def _create_schema_for_validation(cls, context) -> Schema: """Create a schema of the resource with specific context. Should be overridden by subclass. :return: The schema of the resource. :rtype: Schema. """ raise NotImplementedError() def _default_context(self) -> dict: """Get the default context for schema validation. Should be overridden by subclass. :return: The default context for schema validation :rtype: dict """ raise NotImplementedError() @property def _schema_for_validation(self) -> Schema: """Return the schema of this Resource with default context. Do not override this method. Override _create_schema_for_validation instead. :return: The schema of the resource. :rtype: Schema. """ return self._create_schema_for_validation(context=self._default_context()) def _dump_for_validation(self) -> typing.Dict: """Convert the resource to a dictionary. :return: Converted dictionary :rtype: typing.Dict """ return self._schema_for_validation.dump(self) @classmethod def _create_validation_error(cls, message: str, no_personal_data_message: str) -> Exception: """The function to create the validation exception to raise in _try_raise and _validate when raise_error is True. Should be overridden by subclass. :param message: The error message containing detailed information :type message: str :param no_personal_data_message: The error message without personal data :type no_personal_data_message: str :return: The validation exception to raise :rtype: Exception """ raise NotImplementedError() @classmethod def _try_raise( cls, validation_result: MutableValidationResult, *, raise_error: bool = True ) -> MutableValidationResult: return validation_result.try_raise(raise_error=raise_error, error_func=cls._create_validation_error) def _validate(self, raise_error=False) -> MutableValidationResult: """Validate the resource. If raise_error is True, raise ValidationError if validation fails and log warnings if applicable; Else, return the validation result. :param raise_error: Whether to raise ValidationError if validation fails. :type raise_error: bool :return: The validation result :rtype: MutableValidationResult """ result = self.__schema_validate() result.merge_with(self._customized_validate()) return self._try_raise(result, raise_error=raise_error) def _customized_validate(self) -> MutableValidationResult: """Validate the resource with customized logic. Override this method to add customized validation logic. :return: The customized validation result :rtype: MutableValidationResult """ return self._create_empty_validation_result() @classmethod def _get_skip_fields_in_schema_validation( cls, ) -> typing.List[str]: """Get the fields that should be skipped in schema validation. Override this method to add customized validation logic. :return: The fields to skip in schema validation :rtype: typing.List[str] """ return [] def __schema_validate(self) -> MutableValidationResult: """Validate the resource with the schema. :return: The validation result :rtype: MutableValidationResult """ data = self._dump_for_validation() messages = self._schema_for_validation.validate(data) for skip_field in self._get_skip_fields_in_schema_validation(): if skip_field in messages: del messages[skip_field] return ValidationResultBuilder.from_validation_messages(messages, data=data)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/entities/_validation/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from .core import MutableValidationResult, ValidationResult, ValidationResultBuilder from .schema import SchemaValidatableMixin __all__ = [ "SchemaValidatableMixin", "MutableValidationResult", "ValidationResult", "ValidationResultBuilder", ]
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/_experiment.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from marshmallow import fields, post_load, pre_load from promptflow._sdk._constants import ExperimentNodeType from promptflow._sdk.schemas._base import PatchedSchemaMeta, YamlFileSchema from promptflow._sdk.schemas._fields import ( LocalPathField, NestedField, PrimitiveValueField, StringTransformedEnum, UnionField, ) from promptflow._sdk.schemas._run import RunSchema class CommandNodeSchema(YamlFileSchema): # TODO: Not finalized now. Need to revisit. name = fields.Str(required=True) display_name = fields.Str() type = StringTransformedEnum(allowed_values=ExperimentNodeType.COMMAND, required=True) code = LocalPathField(default=".") command = fields.Str(required=True) inputs = fields.Dict(keys=fields.Str) outputs = fields.Dict(keys=fields.Str, values=LocalPathField(allow_none=True)) environment_variables = fields.Dict(keys=fields.Str, values=fields.Str) # runtime field, only available for cloud run runtime = fields.Str() # TODO: Revisit the required fields class FlowNodeSchema(RunSchema): class Meta: exclude = ["flow", "column_mapping", "data", "run"] name = fields.Str(required=True) type = StringTransformedEnum(allowed_values=ExperimentNodeType.FLOW, required=True) inputs = fields.Dict(keys=fields.Str) path = UnionField([LocalPathField(required=True), fields.Str(required=True)]) @pre_load def warning_unknown_fields(self, data, **kwargs): # Override to avoid warning here return data class ExperimentDataSchema(metaclass=PatchedSchemaMeta): name = fields.Str(required=True) path = LocalPathField(required=True) class ExperimentInputSchema(metaclass=PatchedSchemaMeta): name = fields.Str(required=True) type = fields.Str(required=True) default = PrimitiveValueField() class ExperimentTemplateSchema(YamlFileSchema): name = fields.Str() description = fields.Str() data = fields.List(NestedField(ExperimentDataSchema)) # Optional inputs = fields.List(NestedField(ExperimentInputSchema)) # Optional nodes = fields.List( UnionField( [ NestedField(CommandNodeSchema), NestedField(FlowNodeSchema), ] ), required=True, ) @post_load def resolve_nodes(self, data, **kwargs): from promptflow._sdk.entities._experiment import CommandNode, FlowNode nodes = data.get("nodes", []) resolved_nodes = [] for node in nodes: if not isinstance(node, dict): continue node_type = node.get("type", None) if node_type == ExperimentNodeType.FLOW: resolved_nodes.append(FlowNode._load_from_dict(data=node, context=self.context, additional_message="")) elif node_type == ExperimentNodeType.COMMAND: resolved_nodes.append( CommandNode._load_from_dict(data=node, context=self.context, additional_message="") ) else: raise ValueError(f"Unknown node type {node_type} for node {node}.") data["nodes"] = resolved_nodes return data @post_load def resolve_data_and_inputs(self, data, **kwargs): from promptflow._sdk.entities._experiment import ExperimentData, ExperimentInput def resolve_resource(key, cls): items = data.get(key, []) resolved_result = [] for item in items: if not isinstance(item, dict): continue resolved_result.append( cls._load_from_dict( data=item, context=self.context, additional_message=f"Failed to load {cls.__name__}", ) ) return resolved_result data["data"] = resolve_resource("data", ExperimentData) data["inputs"] = resolve_resource("inputs", ExperimentInput) return data class ExperimentSchema(ExperimentTemplateSchema): node_runs = fields.Dict(keys=fields.Str(), values=fields.Str()) # TODO: Revisit this status = fields.Str(dump_only=True) properties = fields.Dict(keys=fields.Str(), values=fields.Str(allow_none=True)) created_on = fields.Str(dump_only=True) last_start_time = fields.Str(dump_only=True) last_end_time = fields.Str(dump_only=True)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/_run.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import os.path from dotenv import dotenv_values from marshmallow import fields, post_load, pre_load from promptflow._sdk._utils import is_remote_uri from promptflow._sdk.schemas._base import PatchedSchemaMeta, YamlFileSchema from promptflow._sdk.schemas._fields import LocalPathField, NestedField, UnionField from promptflow._utils.logger_utils import get_cli_sdk_logger logger = get_cli_sdk_logger() def _resolve_dot_env_file(data, **kwargs): """Resolve .env file to environment variables.""" env_var = data.get("environment_variables", None) try: if env_var and os.path.exists(env_var): env_dict = dotenv_values(env_var) data["environment_variables"] = env_dict except TypeError: pass return data class ResourcesSchema(metaclass=PatchedSchemaMeta): """Schema for resources.""" instance_type = fields.Str() idle_time_before_shutdown_minutes = fields.Int() class RemotePathStr(fields.Str): default_error_messages = { "invalid_path": "Invalid remote path. " "Currently only azureml://xxx or public URL(e.g. https://xxx) are supported.", } def _validate(self, value): # inherited validations like required, allow_none, etc. super(RemotePathStr, self)._validate(value) if value is None: return if not is_remote_uri(value): raise self.make_error( "invalid_path", ) class RemoteFlowStr(fields.Str): default_error_messages = { "invalid_path": "Invalid remote flow path. Currently only azureml:<flow-name> is supported", } def _validate(self, value): # inherited validations like required, allow_none, etc. super(RemoteFlowStr, self)._validate(value) if value is None: return if not isinstance(value, str) or not value.startswith("azureml:"): raise self.make_error( "invalid_path", ) class RunSchema(YamlFileSchema): """Base schema for all run schemas.""" # TODO(2898455): support directly write path/flow + entry in run.yaml # region: common fields name = fields.Str() display_name = fields.Str(required=False) tags = fields.Dict(keys=fields.Str(), values=fields.Str(allow_none=True)) status = fields.Str(dump_only=True) description = fields.Str(attribute="description") properties = fields.Dict(keys=fields.Str(), values=fields.Str(allow_none=True)) # endregion: common fields flow = UnionField([LocalPathField(required=True), RemoteFlowStr(required=True)]) # inputs field data = UnionField([LocalPathField(), RemotePathStr()]) column_mapping = fields.Dict(keys=fields.Str) # runtime field, only available for cloud run runtime = fields.Str() resources = NestedField(ResourcesSchema) run = fields.Str() # region: context variant = fields.Str() environment_variables = UnionField( [ fields.Dict(keys=fields.Str(), values=fields.Str()), # support load environment variables from .env file LocalPathField(), ] ) connections = fields.Dict(keys=fields.Str(), values=fields.Dict(keys=fields.Str())) # endregion: context # region: command node command = fields.Str(dump_only=True) outputs = fields.Dict(key=fields.Str(), dump_only=True) # endregion: command node @post_load def resolve_dot_env_file(self, data, **kwargs): return _resolve_dot_env_file(data, **kwargs) @pre_load def warning_unknown_fields(self, data, **kwargs): # log warnings for unknown schema fields unknown_fields = set(data) - set(self.fields) if unknown_fields: logger.warning("Run schema validation warnings. Unknown fields found: %s", unknown_fields) return data
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/_base.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- # pylint: disable=unused-argument,no-self-use import copy from pathlib import Path from typing import Optional from marshmallow import RAISE, fields, post_load, pre_load from marshmallow.decorators import post_dump from marshmallow.schema import Schema, SchemaMeta from pydash import objects from promptflow._sdk._constants import BASE_PATH_CONTEXT_KEY, FILE_PREFIX, PARAMS_OVERRIDE_KEY from promptflow._utils.logger_utils import LoggerFactory from promptflow._utils.yaml_utils import load_yaml module_logger = LoggerFactory.get_logger(__name__) class PatchedMeta: ordered = True unknown = RAISE class PatchedBaseSchema(Schema): class Meta: unknown = RAISE ordered = True @post_dump def remove_none(self, data, **kwargs): """Prevents from dumping attributes that are None, thus making the dump more compact.""" return dict((key, value) for key, value in data.items() if value is not None) class PatchedSchemaMeta(SchemaMeta): """Currently there is an open issue in marshmallow, that the "unknown" property is not inherited. We use a metaclass to inject a Meta class into all our Schema classes. """ def __new__(cls, name, bases, dct): meta = dct.get("Meta") if meta is None: dct["Meta"] = PatchedMeta else: if not hasattr(meta, "unknown"): dct["Meta"].unknown = RAISE if not hasattr(meta, "ordered"): dct["Meta"].ordered = True if PatchedBaseSchema not in bases: bases = bases + (PatchedBaseSchema,) return super().__new__(cls, name, bases, dct) class PathAwareSchema(PatchedBaseSchema, metaclass=PatchedSchemaMeta): schema_ignored = fields.Str(data_key="$schema", dump_only=True) def __init__(self, *args, **kwargs): # this will make context of all PathAwareSchema child class point to one object self.context = kwargs.get("context", None) if self.context is None or self.context.get(BASE_PATH_CONTEXT_KEY, None) is None: raise Exception("Base path for reading files is required when building PathAwareSchema") # set old base path, note it's an Path object and point to the same object with # self.context.get(BASE_PATH_CONTEXT_KEY) self.old_base_path = self.context.get(BASE_PATH_CONTEXT_KEY) super().__init__(*args, **kwargs) @pre_load def add_param_overrides(self, data, **kwargs): # Removing params override from context so that overriding is done once on the yaml # child schema should not override the params. params_override = self.context.pop(PARAMS_OVERRIDE_KEY, None) if params_override is not None: for override in params_override: for param, val in override.items(): # Check that none of the intermediary levels are string references (azureml/file) param_tokens = param.split(".") test_layer = data for layer in param_tokens: if test_layer is None: continue if isinstance(test_layer, str): raise Exception( f"Cannot use '--set' on properties defined by reference strings: --set {param}" ) test_layer = test_layer.get(layer, None) objects.set_(data, param, val) return data @pre_load def trim_dump_only(self, data, **kwargs): """Marshmallow raises if dump_only fields are present in the schema. This is not desirable for our use case, where read-only properties can be present in the yaml, and should simply be ignored, while we should raise in. the case an unknown field is present - to prevent typos. """ if isinstance(data, str) or data is None: return data for key, value in self.fields.items(): # pylint: disable=no-member if value.dump_only: schema_key = value.data_key or key if data.get(schema_key, None) is not None: data.pop(schema_key) return data class YamlFileSchema(PathAwareSchema): """Base class that allows derived classes to be built from paths to separate yaml files in place of inline yaml definitions. This will be transparent to any parent schema containing a nested schema of the derived class, it will not need a union type for the schema, a YamlFile string will be resolved by the pre_load method into a dictionary. On loading the child yaml, update the base path to use for loading sub-child files. """ def __init__(self, *args, **kwargs): self._previous_base_path = None super().__init__(*args, **kwargs) @classmethod def _resolve_path(cls, data, base_path) -> Optional[Path]: if isinstance(data, str) and data.startswith(FILE_PREFIX): # Use directly if absolute path path = Path(data[len(FILE_PREFIX) :]) if not path.is_absolute(): path = Path(base_path) / path path.resolve() return path return None @pre_load def load_from_file(self, data, **kwargs): path = self._resolve_path(data, Path(self.context[BASE_PATH_CONTEXT_KEY])) if path is not None: self._previous_base_path = Path(self.context[BASE_PATH_CONTEXT_KEY]) # Push update # deepcopy self.context[BASE_PATH_CONTEXT_KEY] to update old base path self.old_base_path = copy.deepcopy(self.context[BASE_PATH_CONTEXT_KEY]) self.context[BASE_PATH_CONTEXT_KEY] = path.parent data = load_yaml(path) return data return data # Schemas are read depth-first, so push/pop to update current path @post_load def reset_base_path_post_load(self, data, **kwargs): if self._previous_base_path is not None: # pop state self.context[BASE_PATH_CONTEXT_KEY] = self._previous_base_path return data class CreateBySchema(metaclass=PatchedSchemaMeta): user_object_id = fields.Str(dump_only=True, attribute="userObjectId") user_tenant_id = fields.Str(dump_only=True, attribute="userTenantId") user_name = fields.Str(dump_only=True, attribute="userName")
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/_fields.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy import typing from pathlib import Path from marshmallow import fields from marshmallow.exceptions import FieldInstanceResolutionError, ValidationError from marshmallow.fields import _T, Field, Nested from marshmallow.utils import RAISE, resolve_field_instance from promptflow._sdk._constants import BASE_PATH_CONTEXT_KEY from promptflow._sdk.schemas._base import PathAwareSchema from promptflow._utils.logger_utils import LoggerFactory # pylint: disable=unused-argument,no-self-use,protected-access module_logger = LoggerFactory.get_logger(__name__) class StringTransformedEnum(Field): def __init__(self, **kwargs): # pop marshmallow unknown args to avoid warnings self.allowed_values = kwargs.pop("allowed_values", None) self.casing_transform = kwargs.pop("casing_transform", lambda x: x.lower()) self.pass_original = kwargs.pop("pass_original", False) super().__init__(**kwargs) if isinstance(self.allowed_values, str): self.allowed_values = [self.allowed_values] self.allowed_values = [self.casing_transform(x) for x in self.allowed_values] def _jsonschema_type_mapping(self): schema = {"type": "string", "enum": self.allowed_values} if self.name is not None: schema["title"] = self.name if self.dump_only: schema["readonly"] = True return schema def _serialize(self, value, attr, obj, **kwargs): if not value: return if isinstance(value, str) and self.casing_transform(value) in self.allowed_values: return value if self.pass_original else self.casing_transform(value) raise ValidationError(f"Value {value!r} passed is not in set {self.allowed_values}") def _deserialize(self, value, attr, data, **kwargs): if isinstance(value, str) and self.casing_transform(value) in self.allowed_values: return value if self.pass_original else self.casing_transform(value) raise ValidationError(f"Value {value!r} passed is not in set {self.allowed_values}") class LocalPathField(fields.Str): """A field that validates that the input is a local path. Can only be used as fields of PathAwareSchema. """ default_error_messages = { "invalid_path": "The filename, directory name, or volume label syntax is incorrect.", "path_not_exist": "Can't find {allow_type} in resolved absolute path: {path}.", } def __init__(self, allow_dir=True, allow_file=True, **kwargs): self._allow_dir = allow_dir self._allow_file = allow_file self._pattern = kwargs.get("pattern", None) super().__init__(**kwargs) def _resolve_path(self, value) -> Path: """Resolve path to absolute path based on base_path in context. Will resolve the path if it's already an absolute path. """ try: result = Path(value) base_path = Path(self.context[BASE_PATH_CONTEXT_KEY]) if not result.is_absolute(): result = base_path / result # for non-path string like "azureml:/xxx", OSError can be raised in either # resolve() or is_dir() or is_file() result = result.resolve() if (self._allow_dir and result.is_dir()) or (self._allow_file and result.is_file()): return result except OSError: raise self.make_error("invalid_path") raise self.make_error("path_not_exist", path=result.as_posix(), allow_type=self.allowed_path_type) @property def allowed_path_type(self) -> str: if self._allow_dir and self._allow_file: return "directory or file" if self._allow_dir: return "directory" return "file" def _validate(self, value): # inherited validations like required, allow_none, etc. super(LocalPathField, self)._validate(value) if value is None: return self._resolve_path(value) def _serialize(self, value, attr, obj, **kwargs) -> typing.Optional[str]: # do not block serializing None even if required or not allow_none. if value is None: return None # always dump path as absolute path in string as base_path will be dropped after serialization return super(LocalPathField, self)._serialize(self._resolve_path(value).as_posix(), attr, obj, **kwargs) def _deserialize(self, value, attr, data, **kwargs): # resolve to absolute path if value is None: return None return super()._deserialize(self._resolve_path(value).as_posix(), attr, data, **kwargs) # Note: Currently contains a bug where the order in which fields are inputted can potentially cause a bug # Example, the first line below works, but the second one fails upon calling load_from_dict # with the error " AttributeError: 'list' object has no attribute 'get'" # inputs = UnionField([fields.List(NestedField(DataSchema)), NestedField(DataSchema)]) # inputs = UnionField([NestedField(DataSchema), fields.List(NestedField(DataSchema))]) class UnionField(fields.Field): def __init__(self, union_fields: typing.List[fields.Field], is_strict=False, **kwargs): super().__init__(**kwargs) try: # add the validation and make sure union_fields must be subclasses or instances of # marshmallow.base.FieldABC self._union_fields = [resolve_field_instance(cls_or_instance) for cls_or_instance in union_fields] # TODO: make serialization/de-serialization work in the same way as json schema when is_strict is True self.is_strict = is_strict # S\When True, combine fields with oneOf instead of anyOf at schema generation except FieldInstanceResolutionError as error: raise ValueError( 'Elements of "union_fields" must be subclasses or ' "instances of marshmallow.base.FieldABC." ) from error @property def union_fields(self): return iter(self._union_fields) def insert_union_field(self, field): self._union_fields.insert(0, field) # This sets the parent for the schema and also handles nesting. def _bind_to_schema(self, field_name, schema): super()._bind_to_schema(field_name, schema) self._union_fields = self._create_bind_fields(self._union_fields, field_name) def _create_bind_fields(self, _fields, field_name): new_union_fields = [] for field in _fields: field = copy.deepcopy(field) field._bind_to_schema(field_name, self) new_union_fields.append(field) return new_union_fields def _serialize(self, value, attr, obj, **kwargs): if value is None: return None errors = [] for field in self._union_fields: try: return field._serialize(value, attr, obj, **kwargs) except ValidationError as e: errors.extend(e.messages) except (TypeError, ValueError, AttributeError) as e: errors.extend([str(e)]) raise ValidationError(message=errors, field_name=attr) def _deserialize(self, value, attr, data, **kwargs): errors = [] for schema in self._union_fields: try: return schema.deserialize(value, attr, data, **kwargs) except ValidationError as e: errors.append(e.normalized_messages()) except (FileNotFoundError, TypeError) as e: errors.append([str(e)]) finally: # Revert base path to original path when job schema fail to deserialize job. For example, when load # parallel job with component file reference starting with FILE prefix, maybe first CommandSchema will # load component yaml according to AnonymousCommandComponentSchema, and YamlFileSchema will update base # path. When CommandSchema fail to load, then Parallelschema will load component yaml according to # AnonymousParallelComponentSchema, but base path now is incorrect, and will raise path not found error # when load component yaml file. if ( hasattr(schema, "name") and schema.name == "jobs" and hasattr(schema, "schema") and isinstance(schema.schema, PathAwareSchema) ): # use old base path to recover original base path schema.schema.context[BASE_PATH_CONTEXT_KEY] = schema.schema.old_base_path # recover base path of parent schema schema.context[BASE_PATH_CONTEXT_KEY] = schema.schema.context[BASE_PATH_CONTEXT_KEY] raise ValidationError(errors, field_name=attr) class NestedField(Nested): """anticipates the default coming in next marshmallow version, unknown=True.""" def __init__(self, *args, **kwargs): if kwargs.get("unknown") is None: kwargs["unknown"] = RAISE super().__init__(*args, **kwargs) class DumpableIntegerField(fields.Integer): """An int field that cannot serialize other type of values to int if self.strict.""" def _serialize(self, value, attr, obj, **kwargs) -> typing.Optional[typing.Union[str, _T]]: if self.strict and not isinstance(value, int): # this implementation can serialize bool to bool raise self.make_error("invalid", input=value) return super()._serialize(value, attr, obj, **kwargs) class DumpableFloatField(fields.Float): """A float field that cannot serialize other type of values to float if self.strict.""" def __init__( self, *, strict: bool = False, allow_nan: bool = False, as_string: bool = False, **kwargs, ): self.strict = strict super().__init__(allow_nan=allow_nan, as_string=as_string, **kwargs) def _validated(self, value): if self.strict and not isinstance(value, float): raise self.make_error("invalid", input=value) return super()._validated(value) def _serialize(self, value, attr, obj, **kwargs) -> typing.Optional[typing.Union[str, _T]]: return super()._serialize(self._validated(value), attr, obj, **kwargs) def PrimitiveValueField(**kwargs): """Function to return a union field for primitive value. :return: The primitive value field :rtype: Field """ return UnionField( [ # Note: order matters here - to make sure value parsed correctly. # By default, when strict is false, marshmallow downcasts float to int. # Setting it to true will throw a validation error when loading a float to int. # https://github.com/marshmallow-code/marshmallow/pull/755 # Use DumpableIntegerField to make sure there will be validation error when # loading/dumping a float to int. # note that this field can serialize bool instance but cannot deserialize bool instance. DumpableIntegerField(strict=True), # Use DumpableFloatField with strict of True to avoid '1'(str) serialized to 1.0(float) DumpableFloatField(strict=True), # put string schema after Int and Float to make sure they won't dump to string fields.Str(), # fields.Bool comes last since it'll parse anything non-falsy to True fields.Bool(), ], **kwargs, )
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/_connection.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy from marshmallow import ValidationError, fields, pre_dump, validates from promptflow._sdk._constants import ( SCHEMA_KEYS_CONTEXT_CONFIG_KEY, SCHEMA_KEYS_CONTEXT_SECRET_KEY, ConnectionType, CustomStrongTypeConnectionConfigs, ) from promptflow._sdk.schemas._base import YamlFileSchema from promptflow._sdk.schemas._fields import StringTransformedEnum from promptflow._utils.utils import camel_to_snake def _casting_type(typ): type_dict = { ConnectionType.AZURE_OPEN_AI: "azure_open_ai", ConnectionType.OPEN_AI: "open_ai", } if typ in type_dict: return type_dict.get(typ) return camel_to_snake(typ) class ConnectionSchema(YamlFileSchema): name = fields.Str(attribute="name") module = fields.Str(dump_default="promptflow.connections") created_date = fields.Str(dump_only=True) last_modified_date = fields.Str(dump_only=True) expiry_time = fields.Str(dump_only=True) @pre_dump def _pre_dump(self, data, **kwargs): from promptflow._sdk.entities._connection import _Connection if not isinstance(data, _Connection): return data # Update the type replica of the connection object to match schema copied = copy.deepcopy(data) copied.type = camel_to_snake(copied.type) return copied class AzureOpenAIConnectionSchema(ConnectionSchema): type = StringTransformedEnum(allowed_values="azure_open_ai", required=True) api_key = fields.Str(required=True) api_base = fields.Str(required=True) api_type = fields.Str(dump_default="azure") api_version = fields.Str(dump_default="2023-07-01-preview") class OpenAIConnectionSchema(ConnectionSchema): type = StringTransformedEnum(allowed_values="open_ai", required=True) api_key = fields.Str(required=True) organization = fields.Str() base_url = fields.Str() class EmbeddingStoreConnectionSchema(ConnectionSchema): module = fields.Str(dump_default="promptflow_vectordb.connections") api_key = fields.Str(required=True) api_base = fields.Str(required=True) class QdrantConnectionSchema(EmbeddingStoreConnectionSchema): type = StringTransformedEnum(allowed_values=camel_to_snake(ConnectionType.QDRANT), required=True) class WeaviateConnectionSchema(EmbeddingStoreConnectionSchema): type = StringTransformedEnum(allowed_values=camel_to_snake(ConnectionType.WEAVIATE), required=True) class CognitiveSearchConnectionSchema(ConnectionSchema): type = StringTransformedEnum( allowed_values=camel_to_snake(ConnectionType.COGNITIVE_SEARCH), required=True, ) api_key = fields.Str(required=True) api_base = fields.Str(required=True) api_version = fields.Str(dump_default="2023-07-01-Preview") class SerpConnectionSchema(ConnectionSchema): type = StringTransformedEnum(allowed_values=camel_to_snake(ConnectionType.SERP), required=True) api_key = fields.Str(required=True) class AzureContentSafetyConnectionSchema(ConnectionSchema): type = StringTransformedEnum( allowed_values=camel_to_snake(ConnectionType.AZURE_CONTENT_SAFETY), required=True, ) api_key = fields.Str(required=True) endpoint = fields.Str(required=True) api_version = fields.Str(dump_default="2023-10-01") api_type = fields.Str(dump_default="Content Safety") class FormRecognizerConnectionSchema(ConnectionSchema): type = StringTransformedEnum( allowed_values=camel_to_snake(ConnectionType.FORM_RECOGNIZER), required=True, ) api_key = fields.Str(required=True) endpoint = fields.Str(required=True) api_version = fields.Str(dump_default="2023-07-31") api_type = fields.Str(dump_default="Form Recognizer") class CustomConnectionSchema(ConnectionSchema): type = StringTransformedEnum(allowed_values=camel_to_snake(ConnectionType.CUSTOM), required=True) configs = fields.Dict(keys=fields.Str(), values=fields.Str()) # Secrets is a must-have field for CustomConnection secrets = fields.Dict(keys=fields.Str(), values=fields.Str(), required=True) class CustomStrongTypeConnectionSchema(CustomConnectionSchema): name = fields.Str(attribute="name") module = fields.Str(required=True) custom_type = fields.Str(required=True) package = fields.Str(required=True) package_version = fields.Str(required=True) # TODO: validate configs and secrets @validates("configs") def validate_configs(self, value): schema_config_keys = self.context.get(SCHEMA_KEYS_CONTEXT_CONFIG_KEY, None) if schema_config_keys: for key in value: if CustomStrongTypeConnectionConfigs.is_custom_key(key) and key not in schema_config_keys: raise ValidationError(f"Invalid config key {key}, please check the schema.") @validates("secrets") def validate_secrets(self, value): schema_secret_keys = self.context.get(SCHEMA_KEYS_CONTEXT_SECRET_KEY, None) if schema_secret_keys: for key in value: if key not in schema_secret_keys: raise ValidationError(f"Invalid secret key {key}, please check the schema.")
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/_flow.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from marshmallow import fields, validate from promptflow._sdk._constants import FlowType from promptflow._sdk.schemas._base import PatchedSchemaMeta, YamlFileSchema from promptflow._sdk.schemas._fields import LocalPathField, NestedField class FlowInputSchema(metaclass=PatchedSchemaMeta): """Schema for flow input.""" type = fields.Str(required=True) description = fields.Str() # Note: default attribute default can be various types, so we use Raw type here, # but when transforming to json schema, there is no equivalent type, it will become string type # may need to delete the default type in the generated json schema to avoid false alarm default = fields.Raw() is_chat_input = fields.Bool() is_chat_history = fields.Bool() class FlowOutputSchema(metaclass=PatchedSchemaMeta): """Schema for flow output.""" type = fields.Str(required=True) reference = fields.Str() description = fields.Str() is_chat_output = fields.Bool() class BaseFlowSchema(YamlFileSchema): """Base schema for flow.""" additional_includes = fields.List(fields.Str()) environment = fields.Dict() # metadata type = fields.Str(validate=validate.OneOf(FlowType.get_all_values())) language = fields.Str() description = fields.Str() display_name = fields.Str() tags = fields.Dict(keys=fields.Str(), values=fields.Str()) class FlowSchema(BaseFlowSchema): """Schema for flow dag.""" inputs = fields.Dict(keys=fields.Str(), values=NestedField(FlowInputSchema)) outputs = fields.Dict(keys=fields.Str(), values=NestedField(FlowOutputSchema)) nodes = fields.List(fields.Dict()) node_variants = fields.Dict(keys=fields.Str(), values=fields.Dict()) class EagerFlowSchema(BaseFlowSchema): """Schema for eager flow.""" # path to flow entry file. path = LocalPathField(required=True) # entry function entry = fields.Str(required=True)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/schemas/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/_errors.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from promptflow.exceptions import ErrorTarget, UserErrorException class BadRequest(UserErrorException): pass class JsonPayloadRequiredForMultipleInputFields(BadRequest): pass class MissingRequiredFlowInput(BadRequest): pass class FlowConnectionError(UserErrorException): pass class UnsupportedConnectionProvider(FlowConnectionError): def __init__(self, provider): super().__init__( message_format="Unsupported connection provider {provider}, " "supported are 'local' and typing.Callable.", provider=provider, target=ErrorTarget.FLOW_INVOKER, ) class MissingConnectionProvider(FlowConnectionError): pass class InvalidConnectionData(FlowConnectionError): def __init__(self, connection_name): super().__init__( message_format="Invalid connection data detected while overriding connection {connection_name}.", connection_name=connection_name, target=ErrorTarget.FLOW_INVOKER) class UnexpectedConnectionProviderReturn(FlowConnectionError): pass class MultipleStreamOutputFieldsNotSupported(UserErrorException): def __init__(self): super().__init__( "Multiple stream output fields not supported.", target=ErrorTarget.SERVING_APP, ) class NotAcceptable(UserErrorException): def __init__(self, media_type, supported_media_types): super().__init__( message_format="Media type {media_type} in Accept header is not acceptable. " "Supported media type(s) - {supported_media_types}", media_type=media_type, supported_media_types=supported_media_types, target=ErrorTarget.SERVING_APP, )
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/app.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json import logging import mimetypes import os from pathlib import Path from typing import Dict from flask import Flask, g, jsonify, request from promptflow._sdk._load_functions import load_flow from promptflow._sdk._serving.extension.extension_factory import ExtensionFactory from promptflow._sdk._serving.flow_invoker import FlowInvoker from promptflow._sdk._serving.response_creator import ResponseCreator from promptflow._sdk._serving.utils import ( enable_monitoring, get_output_fields_to_remove, get_sample_json, handle_error_to_response, load_request_data, streaming_response_required, ) from promptflow._sdk._utils import setup_user_agent_to_operation_context from promptflow._utils.exception_utils import ErrorResponse from promptflow._utils.logger_utils import LoggerFactory from promptflow._version import VERSION from promptflow.contracts.run_info import Status from promptflow.exceptions import SystemErrorException from promptflow.storage._run_storage import DummyRunStorage from .swagger import generate_swagger logger = LoggerFactory.get_logger("pfserving-app", target_stdout=True) DEFAULT_STATIC_PATH = Path(__file__).parent / "static" USER_AGENT = f"promptflow-local-serving/{VERSION}" class PromptflowServingApp(Flask): def init(self, **kwargs): with self.app_context(): # default to local, can be override when creating the app self.extension = ExtensionFactory.create_extension(logger, **kwargs) self.flow_invoker: FlowInvoker = None # parse promptflow project path self.project_path = self.extension.get_flow_project_path() logger.info(f"Project path: {self.project_path}") self.flow_entity = load_flow(self.project_path) self.flow = self.flow_entity._init_executable() # enable environment_variables environment_variables = kwargs.get("environment_variables", {}) os.environ.update(environment_variables) default_environment_variables = self.flow.get_environment_variables_with_overrides() self.set_default_environment_variables(default_environment_variables) self.flow_name = self.extension.get_flow_name() self.flow.name = self.flow_name conn_data_override, conn_name_override = self.extension.get_override_connections(self.flow) self.connections_override = conn_data_override self.connections_name_override = conn_name_override self.flow_monitor = self.extension.get_flow_monitor() self.connection_provider = self.extension.get_connection_provider() self.credential = self.extension.get_credential() self.sample = get_sample_json(self.project_path, logger) self.init_swagger() # try to initialize the flow invoker try: self.init_invoker_if_not_exist() except Exception as e: if self.extension.raise_ex_on_invoker_initialization_failure(e): raise e # ensure response has the correct content type mimetypes.add_type("application/javascript", ".js") mimetypes.add_type("text/css", ".css") setup_user_agent_to_operation_context(self.extension.get_user_agent()) add_default_routes(self) # register blueprints blue_prints = self.extension.get_blueprints() for blue_print in blue_prints: self.register_blueprint(blue_print) def init_invoker_if_not_exist(self): if self.flow_invoker: return logger.info("Promptflow executor starts initializing...") self.flow_invoker = FlowInvoker( self.project_path, connection_provider=self.connection_provider, streaming=streaming_response_required, raise_ex=False, connections=self.connections_override, connections_name_overrides=self.connections_name_override, # for serving, we don't need to persist intermediate result, this is to avoid memory leak. storage=DummyRunStorage(), credential=self.credential, ) self.flow = self.flow_invoker.flow # Set the flow name as folder name self.flow.name = self.flow_name self.response_fields_to_remove = get_output_fields_to_remove(self.flow, logger) logger.info("Promptflow executor initializing succeed!") def init_swagger(self): self.response_fields_to_remove = get_output_fields_to_remove(self.flow, logger) self.swagger = generate_swagger(self.flow, self.sample, self.response_fields_to_remove) def set_default_environment_variables(self, default_environment_variables: Dict[str, str] = None): if default_environment_variables is None: return for key, value in default_environment_variables.items(): if key not in os.environ: os.environ[key] = value def add_default_routes(app: PromptflowServingApp): @app.errorhandler(Exception) def handle_error(e): err_resp, resp_code = handle_error_to_response(e, logger) app.flow_monitor.handle_error(e, resp_code) return err_resp, resp_code @app.route("/score", methods=["POST"]) @enable_monitoring def score(): """process a flow request in the runtime.""" raw_data = request.get_data() logger.debug(f"PromptFlow executor received data: {raw_data}") app.init_invoker_if_not_exist() if app.flow.inputs.keys().__len__() == 0: data = {} logger.info("Flow has no input, request data will be ignored.") else: logger.info("Start loading request data...") data = load_request_data(app.flow, raw_data, logger) # set context data g.data = data g.flow_id = app.flow.id or app.flow.name run_id = g.get("req_id", None) # TODO: refine this once we can directly set the input/output log level to DEBUG in flow_invoker. disable_data_logging = logger.level >= logging.INFO flow_result = app.flow_invoker.invoke(data, run_id=run_id, disable_input_output_logging=disable_data_logging) g.flow_result = flow_result # check flow result, if failed, return error response if flow_result.run_info.status != Status.Completed: if flow_result.run_info.error: err = ErrorResponse(flow_result.run_info.error) g.err_code = err.innermost_error_code return jsonify(err.to_simplified_dict()), err.response_code else: # in case of run failed but can't find any error, return 500 exception = SystemErrorException("Flow execution failed without error message.") return jsonify(ErrorResponse.from_exception(exception).to_simplified_dict()), 500 intermediate_output = flow_result.output or {} # remove evaluation only fields result_output = {k: v for k, v in intermediate_output.items() if k not in app.response_fields_to_remove} response_creator = ResponseCreator( flow_run_result=result_output, accept_mimetypes=request.accept_mimetypes, ) app.flow_monitor.setup_streaming_monitor_if_needed(response_creator, data, intermediate_output) return response_creator.create_response() @app.route("/swagger.json", methods=["GET"]) def swagger(): """Get the swagger object.""" return jsonify(app.swagger) @app.route("/health", methods=["GET"]) def health(): """Check if the runtime is alive.""" return {"status": "Healthy", "version": VERSION} @app.route("/version", methods=["GET"]) def version(): """Check the runtime's version.""" build_info = os.environ.get("BUILD_INFO", "") try: build_info_dict = json.loads(build_info) version = build_info_dict["build_number"] except Exception: version = VERSION return {"status": "Healthy", "build_info": build_info, "version": version} def create_app(**kwargs): app = PromptflowServingApp(__name__) if __name__ != "__main__": app.logger.handlers = logger.handlers app.logger.setLevel(logger.level) app.init(**kwargs) return app if __name__ == "__main__": create_app().run()
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/utils.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json import os import time import base64 import zlib from flask import jsonify, request from promptflow._sdk._serving._errors import ( JsonPayloadRequiredForMultipleInputFields, MissingRequiredFlowInput, NotAcceptable, ) from promptflow._utils.exception_utils import ErrorResponse, ExceptionPresenter from promptflow.contracts.flow import Flow as FlowContract from promptflow.exceptions import ErrorTarget def load_request_data(flow, raw_data, logger): try: data = json.loads(raw_data) except Exception: input = None if flow.inputs.keys().__len__() > 1: # this should only work if there's only 1 input field, otherwise it will fail # TODO: add a check to make sure there's only 1 input field message = ( "Promptflow executor received non json data, but there's more than 1 input fields, " "please use json request data instead." ) raise JsonPayloadRequiredForMultipleInputFields(message, target=ErrorTarget.SERVING_APP) if isinstance(raw_data, bytes) or isinstance(raw_data, bytearray): input = str(raw_data, "UTF-8") elif isinstance(raw_data, str): input = raw_data default_key = list(flow.inputs.keys())[0] logger.debug(f"Promptflow executor received non json data: {input}, default key: {default_key}") data = {default_key: input} return data def validate_request_data(flow, data): """Validate required request data is provided.""" # TODO: Note that we don't have default flow input presently, all of the default is None. required_inputs = [k for k, v in flow.inputs.items() if v.default is None] missing_inputs = [k for k in required_inputs if k not in data] if missing_inputs: raise MissingRequiredFlowInput( f"Required input fields {missing_inputs} are missing in request data {data!r}", target=ErrorTarget.SERVING_APP, ) def streaming_response_required(): """Check if streaming response is required.""" return "text/event-stream" in request.accept_mimetypes.values() def get_sample_json(project_path, logger): # load swagger sample if exists sample_file = os.path.join(project_path, "samples.json") if not os.path.exists(sample_file): return None logger.info("Promptflow sample file detected.") with open(sample_file, "r", encoding="UTF-8") as f: sample = json.load(f) return sample # get evaluation only fields def get_output_fields_to_remove(flow: FlowContract, logger) -> list: """get output fields to remove.""" included_outputs = os.getenv("PROMPTFLOW_RESPONSE_INCLUDED_FIELDS", None) if included_outputs: logger.info(f"Response included fields: {included_outputs}") res = json.loads(included_outputs) return [k for k, v in flow.outputs.items() if k not in res] return [k for k, v in flow.outputs.items() if v.evaluation_only] def handle_error_to_response(e, logger): presenter = ExceptionPresenter.create(e) logger.error(f"Promptflow serving app error: {presenter.to_dict()}") logger.error(f"Promptflow serving error traceback: {presenter.formatted_traceback}") resp = ErrorResponse(presenter.to_dict()) response_code = resp.response_code # The http response code for NotAcceptable is 406. # Currently the error framework does not allow response code overriding, # we add a check here to override the response code. # TODO: Consider how to embed this logic into the error framework. if isinstance(e, NotAcceptable): response_code = 406 return jsonify(resp.to_simplified_dict()), response_code def get_pf_serving_env(env_key: str): if len(env_key) == 0: return None value = os.getenv(env_key, None) if value is None and env_key.startswith("PROMPTFLOW_"): value = os.getenv(env_key.replace("PROMPTFLOW_", "PF_"), None) return value def get_cost_up_to_now(start_time: float): return (time.time() - start_time) * 1000 def enable_monitoring(func): func._enable_monitoring = True return func def normalize_connection_name(connection_name: str): return connection_name.replace(" ", "_") def decode_dict(data: str) -> dict: # str -> bytes data = data.encode() zipped_conns = base64.b64decode(data) # gzip decode conns_data = zlib.decompress(zipped_conns, 16 + zlib.MAX_WBITS) return json.loads(conns_data.decode()) def encode_dict(data: dict) -> str: # json encode data = json.dumps(data) # gzip compress gzip_compress = zlib.compressobj(9, zlib.DEFLATED, zlib.MAX_WBITS | 16) zipped_data = gzip_compress.compress(data.encode()) + gzip_compress.flush() # base64 encode b64_data = base64.b64encode(zipped_data) # bytes -> str return b64_data.decode()
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/swagger.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import logging from promptflow.contracts.flow import Flow, FlowInputDefinition, FlowOutputDefinition from promptflow.contracts.tool import ValueType type_mapping = { ValueType.INT: "integer", ValueType.DOUBLE: "number", ValueType.BOOL: "boolean", ValueType.STRING: "string", ValueType.LIST: "array", ValueType.OBJECT: "object", ValueType.IMAGE: "object", # Dump as object as portal test page can't handle image now } def generate_input_field_schema(input: FlowInputDefinition) -> dict: field_schema = {"type": type_mapping[input.type]} if input.description: field_schema["description"] = input.description if input.default: field_schema["default"] = input.default if input.type == ValueType.OBJECT: field_schema["additionalProperties"] = {} if input.type == ValueType.LIST: field_schema["items"] = {"type": "object", "additionalProperties": {}} return field_schema def generate_output_field_schema(output: FlowOutputDefinition) -> dict: field_schema = {"type": type_mapping[output.type]} if output.description: field_schema["description"] = output.description if output.type == ValueType.OBJECT: field_schema["additionalProperties"] = {} if output.type == ValueType.LIST: field_schema["items"] = {"type": "object", "additionalProperties": {}} return field_schema def generate_swagger(flow: Flow, samples, outputs_to_remove: list) -> dict: """convert a flow to swagger object.""" swagger = {"openapi": "3.0.0"} swagger["info"] = { "title": f"Promptflow[{flow.name}] API", "version": "1.0.0", "x-flow-name": str(flow.name), } swagger["components"] = { "securitySchemes": { "bearerAuth": { "type": "http", "scheme": "bearer", } } } swagger["security"] = [{"bearerAuth": []}] input_schema = {"type": "object"} request_body_required = False if len(flow.inputs) > 0: input_schema["properties"] = {} input_schema["required"] = [] request_body_required = True for name, input in flow.inputs.items(): if input.is_chat_input: swagger["info"]["x-chat-input"] = name swagger["info"]["x-flow-type"] = "chat" if input.is_chat_history: swagger["info"]["x-chat-history"] = name input_schema["properties"][name] = generate_input_field_schema(input) input_schema["required"].append(name) output_schema = {"type": "object"} if len(flow.outputs) > 0: output_schema["properties"] = {} for name, output in flow.outputs.items(): # skip evaluation only outputs in swagger # TODO remove this if sdk removed this evaluation_only field if output.evaluation_only: continue if output.is_chat_output: swagger["info"]["x-chat-output"] = name if outputs_to_remove and name in outputs_to_remove: continue output_schema["properties"][name] = generate_output_field_schema(output) example = {} if samples: if isinstance(samples, list): example = samples[0] else: logging.warning("samples should be a list of dict, but got %s, skipped.", type(samples)) swagger["paths"] = { "/score": { "post": { "summary": f"run promptflow: {flow.name} with an given input", "requestBody": { "description": "promptflow input data", "required": request_body_required, "content": { "application/json": { "schema": input_schema, "example": example, # need to check this based on the sample data } }, }, "responses": { "200": { "description": "successful operation", "content": { "application/json": { "schema": output_schema, } }, }, "400": { "description": "Invalid input", }, "default": { "description": "unexpected error", }, }, } } } return swagger
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/flow_invoker.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from pathlib import Path from typing import Callable, Union from promptflow import PFClient from promptflow._constants import LINE_NUMBER_KEY from promptflow._sdk._load_functions import load_flow from promptflow._sdk._serving._errors import UnexpectedConnectionProviderReturn, UnsupportedConnectionProvider from promptflow._sdk._serving.flow_result import FlowResult from promptflow._sdk._serving.utils import validate_request_data from promptflow._sdk._utils import ( dump_flow_result, get_local_connections_from_executable, override_connection_config_with_environment_variable, resolve_connections_environment_variable_reference, update_environment_variables_with_connections, ) from promptflow._sdk.entities._connection import _Connection from promptflow._sdk.entities._flow import Flow from promptflow._sdk.operations._flow_operations import FlowOperations from promptflow._utils.logger_utils import LoggerFactory from promptflow._utils.multimedia_utils import convert_multimedia_data_to_base64, persist_multimedia_data from promptflow.contracts.flow import Flow as ExecutableFlow from promptflow.executor import FlowExecutor from promptflow.storage._run_storage import DefaultRunStorage class FlowInvoker: """ The invoker of a flow. :param flow: The path of the flow, or the flow loaded by load_flow(). :type flow: [str, ~promptflow._sdk.entities._flow.Flow] :param connection_provider: The connection provider, defaults to None :type connection_provider: [str, Callable], optional :param streaming: The function or bool to determine enable streaming or not, defaults to lambda: False :type streaming: Union[Callable[[], bool], bool], optional :param connections: Pre-resolved connections used when executing, defaults to None :type connections: dict, optional :param connections_name_overrides: The connection name overrides, defaults to None Example: ``{"aoai_connection": "azure_open_ai_connection"}`` The node with reference to connection 'aoai_connection' will be resolved to the actual connection 'azure_open_ai_connection'. # noqa: E501 :type connections_name_overrides: dict, optional :param raise_ex: Whether to raise exception when executing flow, defaults to True :type raise_ex: bool, optional """ def __init__( self, flow: [str, Flow], connection_provider: [str, Callable] = None, streaming: Union[Callable[[], bool], bool] = False, connections: dict = None, connections_name_overrides: dict = None, raise_ex: bool = True, **kwargs, ): self.logger = kwargs.get("logger", LoggerFactory.get_logger("flowinvoker")) self.flow_entity = flow if isinstance(flow, Flow) else load_flow(source=flow) self._executable_flow = ExecutableFlow._from_dict( flow_dag=self.flow_entity.dag, working_dir=self.flow_entity.code ) self.connections = connections or {} self.connections_name_overrides = connections_name_overrides or {} self.raise_ex = raise_ex self.storage = kwargs.get("storage", None) self.streaming = streaming if isinstance(streaming, Callable) else lambda: streaming # Pass dump_to path to dump flow result for extension. self._dump_to = kwargs.get("dump_to", None) # The credential is used as an option to override # DefaultAzureCredential when using workspace connection provider self._credential = kwargs.get("credential", None) self._init_connections(connection_provider) self._init_executor() self.flow = self.executor._flow self._dump_file_prefix = "chat" if self._is_chat_flow else "flow" def _init_connections(self, connection_provider): self._is_chat_flow, _, _ = FlowOperations._is_chat_flow(self._executable_flow) connection_provider = "local" if connection_provider is None else connection_provider if isinstance(connection_provider, str): self.logger.info(f"Getting connections from pf client with provider {connection_provider}...") connections_to_ignore = list(self.connections.keys()) connections_to_ignore.extend(self.connections_name_overrides.keys()) # Note: The connection here could be local or workspace, depends on the connection.provider in pf.yaml. connections = get_local_connections_from_executable( executable=self._executable_flow, client=PFClient(config={"connection.provider": connection_provider}, credential=self._credential), connections_to_ignore=connections_to_ignore, # fetch connections with name override connections_to_add=list(self.connections_name_overrides.values()), ) # use original name for connection with name override override_name_to_original_name_mapping = {v: k for k, v in self.connections_name_overrides.items()} for name, conn in connections.items(): if name in override_name_to_original_name_mapping: self.connections[override_name_to_original_name_mapping[name]] = conn else: self.connections[name] = conn elif isinstance(connection_provider, Callable): self.logger.info("Getting connections from custom connection provider...") connection_list = connection_provider() if not isinstance(connection_list, list): raise UnexpectedConnectionProviderReturn( f"Connection provider {connection_provider} should return a list of connections." ) if any(not isinstance(item, _Connection) for item in connection_list): raise UnexpectedConnectionProviderReturn( f"All items returned by {connection_provider} should be connection type, got {connection_list}." ) # TODO(2824058): support connection provider when executing function connections = {item.name: item.to_execution_connection_dict() for item in connection_list} self.connections.update(connections) else: raise UnsupportedConnectionProvider(connection_provider) override_connection_config_with_environment_variable(self.connections) resolve_connections_environment_variable_reference(self.connections) update_environment_variables_with_connections(self.connections) self.logger.info(f"Promptflow get connections successfully. keys: {self.connections.keys()}") def _init_executor(self): self.logger.info("Promptflow executor starts initializing...") storage = None if self._dump_to: storage = DefaultRunStorage(base_dir=self._dump_to, sub_dir=Path(".promptflow/intermediate")) else: storage = self.storage self.executor = FlowExecutor._create_from_flow( flow=self._executable_flow, working_dir=self.flow_entity.code, connections=self.connections, raise_ex=self.raise_ex, storage=storage, ) self.executor.enable_streaming_for_llm_flow(self.streaming) self.logger.info("Promptflow executor initiated successfully.") def _invoke(self, data: dict, run_id=None, disable_input_output_logging=False): """ Process a flow request in the runtime. :param data: The request data dict with flow input as keys, for example: {"question": "What is ChatGPT?"}. :type data: dict :param run_id: The run id of the flow request, defaults to None :type run_id: str, optional :return: The result of executor. :rtype: ~promptflow.executor._result.LineResult """ log_data = "<REDACTED>" if disable_input_output_logging else data self.logger.info(f"Validating flow input with data {log_data!r}") validate_request_data(self.flow, data) self.logger.info(f"Execute flow with data {log_data!r}") # Pass index 0 as extension require for dumped result. # TODO: Remove this index after extension remove this requirement. result = self.executor.exec_line(data, index=0, run_id=run_id, allow_generator_output=self.streaming()) if LINE_NUMBER_KEY in result.output: # Remove line number from output del result.output[LINE_NUMBER_KEY] return result def invoke(self, data: dict, run_id=None, disable_input_output_logging=False): """ Process a flow request in the runtime and return the output of the executor. :param data: The request data dict with flow input as keys, for example: {"question": "What is ChatGPT?"}. :type data: dict :return: The flow output dict, for example: {"answer": "ChatGPT is a chatbot."}. :rtype: dict """ result = self._invoke(data, run_id=run_id, disable_input_output_logging=disable_input_output_logging) # Get base64 for multi modal object resolved_outputs = self._convert_multimedia_data_to_base64(result) self._dump_invoke_result(result) log_outputs = "<REDACTED>" if disable_input_output_logging else result.output self.logger.info(f"Flow run result: {log_outputs}") if not self.raise_ex: # If raise_ex is False, we will return the trace flow & node run info. return FlowResult( output=resolved_outputs or {}, run_info=result.run_info, node_run_infos=result.node_run_infos, ) return resolved_outputs def _convert_multimedia_data_to_base64(self, invoke_result): resolved_outputs = { k: convert_multimedia_data_to_base64(v, with_type=True, dict_type=True) for k, v in invoke_result.output.items() } return resolved_outputs def _dump_invoke_result(self, invoke_result): if self._dump_to: invoke_result.output = persist_multimedia_data( invoke_result.output, base_dir=self._dump_to, sub_dir=Path(".promptflow/output") ) dump_flow_result(flow_folder=self._dump_to, flow_result=invoke_result, prefix=self._dump_file_prefix)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/flow_result.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from dataclasses import dataclass from typing import Mapping, Any from promptflow.contracts.run_info import FlowRunInfo from promptflow.contracts.run_info import RunInfo as NodeRunInfo @dataclass class FlowResult: """The result of a flow call.""" output: Mapping[str, Any] # trace info of the flow run. run_info: FlowRunInfo node_run_infos: Mapping[str, NodeRunInfo]
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/response_creator.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json import time from types import GeneratorType from flask import Response, jsonify from werkzeug.datastructures import MIMEAccept from promptflow._sdk._serving._errors import MultipleStreamOutputFieldsNotSupported, NotAcceptable class ResponseCreator: """Generates http response from flow run result.""" def __init__( self, flow_run_result, accept_mimetypes, stream_start_callback_func=None, stream_end_callback_func=None, stream_event_callback_func=None ): # Fields that are with GeneratorType are streaming outputs. stream_fields = [k for k, v in flow_run_result.items() if isinstance(v, GeneratorType)] if len(stream_fields) > 1: raise MultipleStreamOutputFieldsNotSupported() self.stream_field_name = stream_fields[0] if stream_fields else None self.stream_iterator = flow_run_result.pop(self.stream_field_name, None) self.non_stream_fields = flow_run_result # According to RFC2616, if "Accept" header is not specified, # then it is assumed that the client accepts all media types. # Set */* as the default value here. # https://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html if not accept_mimetypes: accept_mimetypes = MIMEAccept([("*/*", 1)]) self.accept_mimetypes = accept_mimetypes self._on_stream_start = stream_start_callback_func self._on_stream_end = stream_end_callback_func self._on_stream_event = stream_event_callback_func @property def has_stream_field(self): return self.stream_field_name is not None @property def text_stream_specified_explicitly(self): """Returns True only when text/event-stream is specified explicitly. For other cases like */* or text/*, it will return False. """ return "text/event-stream" in self.accept_mimetypes.values() @property def accept_json(self): """Returns True if the Accept header includes application/json. It also returns True when specified with */* or application/*. """ return self.accept_mimetypes.accept_json def create_text_stream_response(self): def format_event(data): return f"data: {json.dumps(data)}\n\n" def generate(): start_time = time.time() if self._on_stream_start: self._on_stream_start() # If there are non streaming fields, yield them firstly. if self.non_stream_fields: yield format_event(self.non_stream_fields) # If there is stream field, read and yield data until the end. if self.stream_iterator is not None: for chunk in self.stream_iterator: if self._on_stream_event: self._on_stream_event(chunk) yield format_event({self.stream_field_name: chunk}) if self._on_stream_end: duration = (time.time() - start_time) * 1000 self._on_stream_end(duration) return Response(generate(), mimetype="text/event-stream") def create_json_response(self): # If there is stream field, iterate over it and get the merged result. if self.stream_iterator is not None: merged_text = "".join(self.stream_iterator) self.non_stream_fields[self.stream_field_name] = merged_text return jsonify(self.non_stream_fields) def create_response(self): if self.has_stream_field: if self.text_stream_specified_explicitly: return self.create_text_stream_response() elif self.accept_json: return self.create_json_response() else: raise NotAcceptable( media_type=self.accept_mimetypes, supported_media_types="text/event-stream, application/json" ) else: if self.accept_json: return self.create_json_response() else: raise NotAcceptable(media_type=self.accept_mimetypes, supported_media_types="application/json")
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/blueprint/static_web_blueprint.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import flask from jinja2 import Template from pathlib import Path from flask import Blueprint, request, url_for, current_app as app def construct_staticweb_blueprint(static_folder): """Construct static web blueprint.""" staticweb_blueprint = Blueprint('staticweb_blueprint', __name__, static_folder=static_folder) @staticweb_blueprint.route("/", methods=["GET", "POST"]) def home(): """Show the home page.""" index_path = Path(static_folder) / "index.html" if static_folder else None if index_path and index_path.exists(): template = Template(open(index_path, "r", encoding="UTF-8").read()) return flask.render_template(template, url_for=url_for) else: return "<h1>Welcome to promptflow app.</h1>" @staticweb_blueprint.route("/<path:path>", methods=["GET", "POST", "PUT", "DELETE", "PATCH"]) def notfound(path): rules = {rule.rule: rule.methods for rule in app.url_map.iter_rules()} if path not in rules or request.method not in rules[path]: unsupported_message = ( f"The requested api {path!r} with {request.method} is not supported by current app, " f"if you entered the URL manually please check your spelling and try again." ) return unsupported_message, 404 return staticweb_blueprint
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/blueprint/monitor_blueprint.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from flask import Blueprint, current_app as app, request from promptflow._sdk._serving.monitor.flow_monitor import FlowMonitor def is_monitoring_enabled() -> bool: enabled = False if request.endpoint in app.view_functions: view_func = app.view_functions[request.endpoint] enabled = hasattr(view_func, "_enable_monitoring") return enabled def construct_monitor_blueprint(flow_monitor: FlowMonitor): """Construct monitor blueprint.""" monitor_blueprint = Blueprint("monitor_blueprint", __name__) @monitor_blueprint.before_app_request def start_monitoring(): if not is_monitoring_enabled(): return flow_monitor.start_monitoring() @monitor_blueprint.after_app_request def finish_monitoring(response): if not is_monitoring_enabled(): return response flow_monitor.finish_monitoring(response.status_code) return response return monitor_blueprint
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/blueprint/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/static/index.html
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Local Server Test App</title> <style> html, body { height: 100%; width: 100%; box-sizing: border-box; padding: 0; margin: 0; } #root { height: 100%; width: 100%; display: flex; } </style> <script type="module" crossorigin src="/static/index.js"></script> </head> <body> <div id="root"></div> <script> const time = new Date().toISOString(); const now = performance.now(); console.log("[perf " + time + " " + now + "]" + " load script start"); </script> </body> </html>
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/static/index.js
var eG=Object.defineProperty;var tG=(e,t,n)=>t in e?eG(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var nG=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var gf=(e,t,n)=>(tG(e,typeof t!="symbol"?t+"":t,n),n);var pxe=nG((Axe,rv)=>{function rG(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in e)){const i=Object.getOwnPropertyDescriptor(r,o);i&&Object.defineProperty(e,o,i.get?i:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const a of i.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function n(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=n(o);fetch(o.href,i)}})();var Mf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function xr(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var XN={exports:{}},H0={};/* object-assign (c) Sindre Sorhus @license MIT */var q8=Object.getOwnPropertySymbols,oG=Object.prototype.hasOwnProperty,iG=Object.prototype.propertyIsEnumerable;function aG(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function sG(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;var r=Object.getOwnPropertyNames(t).map(function(i){return t[i]});if(r.join("")!=="0123456789")return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(i){o[i]=i}),Object.keys(Object.assign({},o)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}var ZN=sG()?Object.assign:function(e,t){for(var n,r=aG(e),o,i=1;i<arguments.length;i++){n=Object(arguments[i]);for(var a in n)oG.call(n,a)&&(r[a]=n[a]);if(q8){o=q8(n);for(var s=0;s<o.length;s++)iG.call(n,o[s])&&(r[o[s]]=n[o[s]])}}return r},JN={exports:{}},Ut={};/** @license React v17.0.2 * react.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var g4=ZN,Yd=60103,eF=60106;Ut.Fragment=60107;Ut.StrictMode=60108;Ut.Profiler=60114;var tF=60109,nF=60110,rF=60112;Ut.Suspense=60113;var oF=60115,iF=60116;if(typeof Symbol=="function"&&Symbol.for){var ua=Symbol.for;Yd=ua("react.element"),eF=ua("react.portal"),Ut.Fragment=ua("react.fragment"),Ut.StrictMode=ua("react.strict_mode"),Ut.Profiler=ua("react.profiler"),tF=ua("react.provider"),nF=ua("react.context"),rF=ua("react.forward_ref"),Ut.Suspense=ua("react.suspense"),oF=ua("react.memo"),iF=ua("react.lazy")}var $8=typeof Symbol=="function"&&Symbol.iterator;function lG(e){return e===null||typeof e!="object"?null:(e=$8&&e[$8]||e["@@iterator"],typeof e=="function"?e:null)}function U0(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var aF={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},sF={};function Qd(e,t,n){this.props=e,this.context=t,this.refs=sF,this.updater=n||aF}Qd.prototype.isReactComponent={};Qd.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error(U0(85));this.updater.enqueueSetState(this,e,t,"setState")};Qd.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function lF(){}lF.prototype=Qd.prototype;function v4(e,t,n){this.props=e,this.context=t,this.refs=sF,this.updater=n||aF}var b4=v4.prototype=new lF;b4.constructor=v4;g4(b4,Qd.prototype);b4.isPureReactComponent=!0;var y4={current:null},uF=Object.prototype.hasOwnProperty,cF={key:!0,ref:!0,__self:!0,__source:!0};function fF(e,t,n){var r,o={},i=null,a=null;if(t!=null)for(r in t.ref!==void 0&&(a=t.ref),t.key!==void 0&&(i=""+t.key),t)uF.call(t,r)&&!cF.hasOwnProperty(r)&&(o[r]=t[r]);var s=arguments.length-2;if(s===1)o.children=n;else if(1<s){for(var l=Array(s),u=0;u<s;u++)l[u]=arguments[u+2];o.children=l}if(e&&e.defaultProps)for(r in s=e.defaultProps,s)o[r]===void 0&&(o[r]=s[r]);return{$$typeof:Yd,type:e,key:i,ref:a,props:o,_owner:y4.current}}function uG(e,t){return{$$typeof:Yd,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function E4(e){return typeof e=="object"&&e!==null&&e.$$typeof===Yd}function cG(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var W8=/\/+/g;function X5(e,t){return typeof e=="object"&&e!==null&&e.key!=null?cG(""+e.key):t.toString(36)}function vg(e,t,n,r,o){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var a=!1;if(e===null)a=!0;else switch(i){case"string":case"number":a=!0;break;case"object":switch(e.$$typeof){case Yd:case eF:a=!0}}if(a)return a=e,o=o(a),e=r===""?"."+X5(a,0):r,Array.isArray(o)?(n="",e!=null&&(n=e.replace(W8,"$&/")+"/"),vg(o,t,n,"",function(u){return u})):o!=null&&(E4(o)&&(o=uG(o,n+(!o.key||a&&a.key===o.key?"":(""+o.key).replace(W8,"$&/")+"/")+e)),t.push(o)),1;if(a=0,r=r===""?".":r+":",Array.isArray(e))for(var s=0;s<e.length;s++){i=e[s];var l=r+X5(i,s);a+=vg(i,t,n,l,o)}else if(l=lG(e),typeof l=="function")for(e=l.call(e),s=0;!(i=e.next()).done;)i=i.value,l=r+X5(i,s++),a+=vg(i,t,n,l,o);else if(i==="object")throw t=""+e,Error(U0(31,t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t));return a}function gm(e,t,n){if(e==null)return e;var r=[],o=0;return vg(e,r,"","",function(i){return t.call(n,i,o++)}),r}function fG(e){if(e._status===-1){var t=e._result;t=t(),e._status=0,e._result=t,t.then(function(n){e._status===0&&(n=n.default,e._status=1,e._result=n)},function(n){e._status===0&&(e._status=2,e._result=n)})}if(e._status===1)return e._result;throw e._result}var dF={current:null};function hl(){var e=dF.current;if(e===null)throw Error(U0(321));return e}var dG={ReactCurrentDispatcher:dF,ReactCurrentBatchConfig:{transition:0},ReactCurrentOwner:y4,IsSomeRendererActing:{current:!1},assign:g4};Ut.Children={map:gm,forEach:function(e,t,n){gm(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return gm(e,function(){t++}),t},toArray:function(e){return gm(e,function(t){return t})||[]},only:function(e){if(!E4(e))throw Error(U0(143));return e}};Ut.Component=Qd;Ut.PureComponent=v4;Ut.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=dG;Ut.cloneElement=function(e,t,n){if(e==null)throw Error(U0(267,e));var r=g4({},e.props),o=e.key,i=e.ref,a=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,a=y4.current),t.key!==void 0&&(o=""+t.key),e.type&&e.type.defaultProps)var s=e.type.defaultProps;for(l in t)uF.call(t,l)&&!cF.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&s!==void 0?s[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){s=Array(l);for(var u=0;u<l;u++)s[u]=arguments[u+2];r.children=s}return{$$typeof:Yd,type:e.type,key:o,ref:i,props:r,_owner:a}};Ut.createContext=function(e,t){return t===void 0&&(t=null),e={$$typeof:nF,_calculateChangedBits:t,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider={$$typeof:tF,_context:e},e.Consumer=e};Ut.createElement=fF;Ut.createFactory=function(e){var t=fF.bind(null,e);return t.type=e,t};Ut.createRef=function(){return{current:null}};Ut.forwardRef=function(e){return{$$typeof:rF,render:e}};Ut.isValidElement=E4;Ut.lazy=function(e){return{$$typeof:iF,_payload:{_status:-1,_result:e},_init:fG}};Ut.memo=function(e,t){return{$$typeof:oF,type:e,compare:t===void 0?null:t}};Ut.useCallback=function(e,t){return hl().useCallback(e,t)};Ut.useContext=function(e,t){return hl().useContext(e,t)};Ut.useDebugValue=function(){};Ut.useEffect=function(e,t){return hl().useEffect(e,t)};Ut.useImperativeHandle=function(e,t,n){return hl().useImperativeHandle(e,t,n)};Ut.useLayoutEffect=function(e,t){return hl().useLayoutEffect(e,t)};Ut.useMemo=function(e,t){return hl().useMemo(e,t)};Ut.useReducer=function(e,t,n){return hl().useReducer(e,t,n)};Ut.useRef=function(e){return hl().useRef(e)};Ut.useState=function(e){return hl().useState(e)};Ut.version="17.0.2";JN.exports=Ut;var T=JN.exports;const Bt=xr(T),n0=rG({__proto__:null,default:Bt},[T]);/** @license React v17.0.2 * react-jsx-runtime.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var hG=T,hF=60103;H0.Fragment=60107;if(typeof Symbol=="function"&&Symbol.for){var G8=Symbol.for;hF=G8("react.element"),H0.Fragment=G8("react.fragment")}var pG=hG.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,mG=Object.prototype.hasOwnProperty,gG={key:!0,ref:!0,__self:!0,__source:!0};function pF(e,t,n){var r,o={},i=null,a=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(a=t.ref);for(r in t)mG.call(t,r)&&!gG.hasOwnProperty(r)&&(o[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)o[r]===void 0&&(o[r]=t[r]);return{$$typeof:hF,type:e,key:i,ref:a,props:o,_owner:pG.current}}H0.jsx=pF;H0.jsxs=pF;XN.exports=H0;var Q=XN.exports;/*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */var mE=function(e,t){return mE=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o])},mE(e,t)};function yi(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");mE(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var oe=function(){return oe=Object.assign||function(t){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},oe.apply(this,arguments)};function pl(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]]);return n}function vG(e,t,n,r){var o=arguments.length,i=o<3?t:r===null?r=Object.getOwnPropertyDescriptor(t,n):r,a;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(e,t,n,r);else for(var s=e.length-1;s>=0;s--)(a=e[s])&&(i=(o<3?a(i):o>3?a(t,n,i):a(t,n))||i);return o>3&&i&&Object.defineProperty(t,n,i),i}function Yi(e,t,n){if(n||arguments.length===2)for(var r=0,o=t.length,i;r<o;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||t)}var K8={},bg=void 0;try{bg=window}catch{}function yb(e,t){if(typeof bg<"u"){var n=bg.__packages__=bg.__packages__||{};if(!n[e]||!K8[e]){K8[e]=t;var r=n[e]=n[e]||[];r.push(t)}}}yb("@fluentui/set-version","6.0.0");var j1={none:0,insertNode:1,appendChild:2},V8="__stylesheet__",bG=typeof navigator<"u"&&/rv:11.0/.test(navigator.userAgent),Lf={};try{Lf=window||{}}catch{}var vf,Qi=function(){function e(t,n){var r,o,i,a,s,l;this._rules=[],this._preservedRules=[],this._counter=0,this._keyToClassName={},this._onInsertRuleCallbacks=[],this._onResetCallbacks=[],this._classNameToArgs={},this._config=oe({injectionMode:typeof document>"u"?j1.none:j1.insertNode,defaultPrefix:"css",namespace:void 0,cspSettings:void 0},t),this._classNameToArgs=(r=n==null?void 0:n.classNameToArgs)!==null&&r!==void 0?r:this._classNameToArgs,this._counter=(o=n==null?void 0:n.counter)!==null&&o!==void 0?o:this._counter,this._keyToClassName=(a=(i=this._config.classNameCache)!==null&&i!==void 0?i:n==null?void 0:n.keyToClassName)!==null&&a!==void 0?a:this._keyToClassName,this._preservedRules=(s=n==null?void 0:n.preservedRules)!==null&&s!==void 0?s:this._preservedRules,this._rules=(l=n==null?void 0:n.rules)!==null&&l!==void 0?l:this._rules}return e.getInstance=function(){if(vf=Lf[V8],!vf||vf._lastStyleElement&&vf._lastStyleElement.ownerDocument!==document){var t=(Lf==null?void 0:Lf.FabricConfig)||{},n=new e(t.mergeStyles,t.serializedStylesheet);vf=n,Lf[V8]=n}return vf},e.prototype.serialize=function(){return JSON.stringify({classNameToArgs:this._classNameToArgs,counter:this._counter,keyToClassName:this._keyToClassName,preservedRules:this._preservedRules,rules:this._rules})},e.prototype.setConfig=function(t){this._config=oe(oe({},this._config),t)},e.prototype.onReset=function(t){var n=this;return this._onResetCallbacks.push(t),function(){n._onResetCallbacks=n._onResetCallbacks.filter(function(r){return r!==t})}},e.prototype.onInsertRule=function(t){var n=this;return this._onInsertRuleCallbacks.push(t),function(){n._onInsertRuleCallbacks=n._onInsertRuleCallbacks.filter(function(r){return r!==t})}},e.prototype.getClassName=function(t){var n=this._config.namespace,r=t||this._config.defaultPrefix;return(n?n+"-":"")+r+"-"+this._counter++},e.prototype.cacheClassName=function(t,n,r,o){this._keyToClassName[n]=t,this._classNameToArgs[t]={args:r,rules:o}},e.prototype.classNameFromKey=function(t){return this._keyToClassName[t]},e.prototype.getClassNameCache=function(){return this._keyToClassName},e.prototype.argsFromClassName=function(t){var n=this._classNameToArgs[t];return n&&n.args},e.prototype.insertedRulesFromClassName=function(t){var n=this._classNameToArgs[t];return n&&n.rules},e.prototype.insertRule=function(t,n){var r=this._config.injectionMode,o=r!==j1.none?this._getStyleElement():void 0;if(n&&this._preservedRules.push(t),o)switch(r){case j1.insertNode:var i=o.sheet;try{i.insertRule(t,i.cssRules.length)}catch{}break;case j1.appendChild:o.appendChild(document.createTextNode(t));break}else this._rules.push(t);this._config.onInsertRule&&this._config.onInsertRule(t),this._onInsertRuleCallbacks.forEach(function(a){return a()})},e.prototype.getRules=function(t){return(t?this._preservedRules.join(""):"")+this._rules.join("")},e.prototype.reset=function(){this._rules=[],this._counter=0,this._classNameToArgs={},this._keyToClassName={},this._onResetCallbacks.forEach(function(t){return t()})},e.prototype.resetKeys=function(){this._keyToClassName={}},e.prototype._getStyleElement=function(){var t=this;return!this._styleElement&&typeof document<"u"&&(this._styleElement=this._createStyleElement(),bG||window.requestAnimationFrame(function(){t._styleElement=void 0})),this._styleElement},e.prototype._createStyleElement=function(){var t=document.head,n=document.createElement("style"),r=null;n.setAttribute("data-merge-styles","true");var o=this._config.cspSettings;if(o&&o.nonce&&n.setAttribute("nonce",o.nonce),this._lastStyleElement)r=this._lastStyleElement.nextElementSibling;else{var i=this._findPlaceholderStyleTag();i?r=i.nextElementSibling:r=t.childNodes[0]}return t.insertBefore(n,t.contains(r)?r:null),this._lastStyleElement=n,n},e.prototype._findPlaceholderStyleTag=function(){var t=document.head;return t?t.querySelector("style[data-merge-styles]"):null},e}();function mF(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=[],r=[],o=Qi.getInstance();function i(a){for(var s=0,l=a;s<l.length;s++){var u=l[s];if(u)if(typeof u=="string")if(u.indexOf(" ")>=0)i(u.split(" "));else{var d=o.argsFromClassName(u);d?i(d):n.indexOf(u)===-1&&n.push(u)}else Array.isArray(u)?i(u):typeof u=="object"&&r.push(u)}}return i(e),{classes:n,objects:r}}function gF(e){cd!==e&&(cd=e)}function vF(){return cd===void 0&&(cd=typeof document<"u"&&!!document.documentElement&&document.documentElement.getAttribute("dir")==="rtl"),cd}var cd;cd=vF();function Eb(){return{rtl:vF()}}var Y8={};function yG(e,t){var n=e[t];n.charAt(0)!=="-"&&(e[t]=Y8[n]=Y8[n]||n.replace(/([A-Z])/g,"-$1").toLowerCase())}var vm;function EG(){var e;if(!vm){var t=typeof document<"u"?document:void 0,n=typeof navigator<"u"?navigator:void 0,r=(e=n==null?void 0:n.userAgent)===null||e===void 0?void 0:e.toLowerCase();t?vm={isWebkit:!!(t&&"WebkitAppearance"in t.documentElement.style),isMoz:!!(r&&r.indexOf("firefox")>-1),isOpera:!!(r&&r.indexOf("opera")>-1),isMs:!!(n&&(/rv:11.0/i.test(n.userAgent)||/Edge\/\d./i.test(navigator.userAgent)))}:vm={isWebkit:!0,isMoz:!0,isOpera:!0,isMs:!0}}return vm}var Q8={"user-select":1};function _G(e,t){var n=EG(),r=e[t];if(Q8[r]){var o=e[t+1];Q8[r]&&(n.isWebkit&&e.push("-webkit-"+r,o),n.isMoz&&e.push("-moz-"+r,o),n.isMs&&e.push("-ms-"+r,o),n.isOpera&&e.push("-o-"+r,o))}}var TG=["column-count","font-weight","flex","flex-grow","flex-shrink","fill-opacity","opacity","order","z-index","zoom"];function wG(e,t){var n=e[t],r=e[t+1];if(typeof r=="number"){var o=TG.indexOf(n)>-1,i=n.indexOf("--")>-1,a=o||i?"":"px";e[t+1]=""+r+a}}var bm,Wl="left",Gl="right",kG="@noflip",X8=(bm={},bm[Wl]=Gl,bm[Gl]=Wl,bm),Z8={"w-resize":"e-resize","sw-resize":"se-resize","nw-resize":"ne-resize"};function SG(e,t,n){if(e.rtl){var r=t[n];if(!r)return;var o=t[n+1];if(typeof o=="string"&&o.indexOf(kG)>=0)t[n+1]=o.replace(/\s*(?:\/\*\s*)?\@noflip\b(?:\s*\*\/)?\s*?/g,"");else if(r.indexOf(Wl)>=0)t[n]=r.replace(Wl,Gl);else if(r.indexOf(Gl)>=0)t[n]=r.replace(Gl,Wl);else if(String(o).indexOf(Wl)>=0)t[n+1]=o.replace(Wl,Gl);else if(String(o).indexOf(Gl)>=0)t[n+1]=o.replace(Gl,Wl);else if(X8[r])t[n]=X8[r];else if(Z8[o])t[n+1]=Z8[o];else switch(r){case"margin":case"padding":t[n+1]=CG(o);break;case"box-shadow":t[n+1]=xG(o,0);break}}}function xG(e,t){var n=e.split(" "),r=parseInt(n[t],10);return n[0]=n[0].replace(String(r),String(r*-1)),n.join(" ")}function CG(e){if(typeof e=="string"){var t=e.split(" ");if(t.length===4)return t[0]+" "+t[3]+" "+t[2]+" "+t[1]}return e}function AG(e){for(var t=[],n=0,r=0,o=0;o<e.length;o++)switch(e[o]){case"(":r++;break;case")":r&&r--;break;case" ":case" ":r||(o>n&&t.push(e.substring(n,o)),n=o+1);break}return n<e.length&&t.push(e.substring(n)),t}var NG="displayName";function FG(e){var t=e&&e["&"];return t?t.displayName:void 0}var bF=/\:global\((.+?)\)/g;function IG(e){if(!bF.test(e))return e;for(var t=[],n=/\:global\((.+?)\)/g,r=null;r=n.exec(e);)r[1].indexOf(",")>-1&&t.push([r.index,r.index+r[0].length,r[1].split(",").map(function(o){return":global("+o.trim()+")"}).join(", ")]);return t.reverse().reduce(function(o,i){var a=i[0],s=i[1],l=i[2],u=o.slice(0,a),d=o.slice(s);return u+l+d},e)}function J8(e,t){return e.indexOf(":global(")>=0?e.replace(bF,"$1"):e.indexOf(":")===0?t+e:e.indexOf("&")<0?t+" "+e:e}function ex(e,t,n,r){t===void 0&&(t={__order:[]}),n.indexOf("@")===0?(n=n+"{"+e,fd([r],t,n)):n.indexOf(",")>-1?IG(n).split(",").map(function(o){return o.trim()}).forEach(function(o){return fd([r],t,J8(o,e))}):fd([r],t,J8(n,e))}function fd(e,t,n){t===void 0&&(t={__order:[]}),n===void 0&&(n="&");var r=Qi.getInstance(),o=t[n];o||(o={},t[n]=o,t.__order.push(n));for(var i=0,a=e;i<a.length;i++){var s=a[i];if(typeof s=="string"){var l=r.argsFromClassName(s);l&&fd(l,t,n)}else if(Array.isArray(s))fd(s,t,n);else for(var u in s)if(s.hasOwnProperty(u)){var d=s[u];if(u==="selectors"){var h=s.selectors;for(var p in h)h.hasOwnProperty(p)&&ex(n,t,p,h[p])}else typeof d=="object"?d!==null&&ex(n,t,u,d):d!==void 0&&(u==="margin"||u==="padding"?BG(o,u,d):o[u]=d)}}return t}function BG(e,t,n){var r=typeof n=="string"?AG(n):[n];r.length===0&&r.push(n),r[r.length-1]==="!important"&&(r=r.slice(0,-1).map(function(o){return o+" !important"})),e[t+"Top"]=r[0],e[t+"Right"]=r[1]||r[0],e[t+"Bottom"]=r[2]||r[0],e[t+"Left"]=r[3]||r[1]||r[0]}function RG(e,t){for(var n=[e.rtl?"rtl":"ltr"],r=!1,o=0,i=t.__order;o<i.length;o++){var a=i[o];n.push(a);var s=t[a];for(var l in s)s.hasOwnProperty(l)&&s[l]!==void 0&&(r=!0,n.push(l,s[l]))}return r?n.join(""):void 0}function yF(e,t){return t<=0?"":t===1?e:e+yF(e,t-1)}function _4(e,t){if(!t)return"";var n=[];for(var r in t)t.hasOwnProperty(r)&&r!==NG&&t[r]!==void 0&&n.push(r,t[r]);for(var o=0;o<n.length;o+=2)yG(n,o),wG(n,o),SG(e,n,o),_G(n,o);for(var o=1;o<n.length;o+=4)n.splice(o,1,":",n[o],";");return n.join("")}function EF(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=fd(t),o=RG(e,r);if(o){var i=Qi.getInstance(),a={className:i.classNameFromKey(o),key:o,args:t};if(!a.className){a.className=i.getClassName(FG(r));for(var s=[],l=0,u=r.__order;l<u.length;l++){var d=u[l];s.push(d,_4(e,r[d]))}a.rulesToInsert=s}return a}}function _F(e,t){t===void 0&&(t=1);var n=Qi.getInstance(),r=e.className,o=e.key,i=e.args,a=e.rulesToInsert;if(a){for(var s=0;s<a.length;s+=2){var l=a[s+1];if(l){var u=a[s];u=u.replace(/&/g,yF("."+e.className,t));var d=u+"{"+l+"}"+(u.indexOf("@")===0?"}":"");n.insertRule(d)}}n.cacheClassName(r,o,i,a)}}function OG(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=EF.apply(void 0,Yi([e],t));return r?(_F(r,e.specificityMultiplier),r.className):""}function Fo(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return TF(e,Eb())}function TF(e,t){var n=e instanceof Array?e:[e],r=mF(n),o=r.classes,i=r.objects;return i.length&&o.push(OG(t||{},i)),o.join(" ")}function jc(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];if(e&&e.length===1&&e[0]&&!e[0].subComponentStyles)return e[0];for(var n={},r={},o=0,i=e;o<i.length;o++){var a=i[o];if(a){for(var s in a)if(a.hasOwnProperty(s)){if(s==="subComponentStyles"&&a.subComponentStyles!==void 0){var l=a.subComponentStyles;for(var u in l)l.hasOwnProperty(u)&&(r.hasOwnProperty(u)?r[u].push(l[u]):r[u]=[l[u]]);continue}var d=n[s],h=a[s];d===void 0?n[s]=h:n[s]=Yi(Yi([],Array.isArray(d)?d:[d]),Array.isArray(h)?h:[h])}}}if(Object.keys(r).length>0){n.subComponentStyles={};var p=n.subComponentStyles,m=function(v){if(r.hasOwnProperty(v)){var _=r[v];p[v]=function(b){return jc.apply(void 0,_.map(function(E){return typeof E=="function"?E(b):E}))}}};for(var u in r)m(u)}return n}function q0(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return wF(e,Eb())}function wF(e,t){var n={subComponentStyles:{}},r=e[0];if(!r&&e.length<=1)return{subComponentStyles:{}};var o=jc.apply(void 0,e),i=[];for(var a in o)if(o.hasOwnProperty(a)){if(a==="subComponentStyles"){n.subComponentStyles=o.subComponentStyles||{};continue}var s=o[a],l=mF(s),u=l.classes,d=l.objects;if(d!=null&&d.length){var h=EF(t||{},{displayName:a},d);h&&(i.push(h),n[a]=u.concat([h.className]).join(" "))}else n[a]=u.join(" ")}for(var p=0,m=i;p<m.length;p++){var h=m[p];h&&_F(h,t==null?void 0:t.specificityMultiplier)}return n}function kF(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=[],o=0,i=t;o<i.length;o++){var a=i[o];a&&r.push(typeof a=="function"?a(e):a)}return r.length===1?r[0]:r.length?jc.apply(void 0,r):{}}function SF(e){var t=Qi.getInstance(),n=_4(Eb(),e),r=t.classNameFromKey(n);if(!r){var o=t.getClassName();t.insertRule("@font-face{"+n+"}",!0),t.cacheClassName(o,n,[],["font-face",n])}}function Ji(e){var t=Qi.getInstance(),n=[];for(var r in e)e.hasOwnProperty(r)&&n.push(r,"{",_4(Eb(),e[r]),"}");var o=n.join(""),i=t.classNameFromKey(o);if(i)return i;var a=t.getClassName();return t.insertRule("@keyframes "+a+"{"+o+"}",!0),t.cacheClassName(a,o,[],["keyframes",o]),a}function DG(e){var t={},n=function(o){if(e.hasOwnProperty(o)){var i;Object.defineProperty(t,o,{get:function(){return i===void 0&&(i=Fo(e[o]).toString()),i},enumerable:!0,configurable:!0})}};for(var r in e)n(r);return t}var gE=void 0;try{gE=window}catch{}function ur(e){if(!(typeof gE>"u")){var t=e;return t&&t.ownerDocument&&t.ownerDocument.defaultView?t.ownerDocument.defaultView:gE}}var _b=function(){function e(t,n){this._timeoutIds=null,this._immediateIds=null,this._intervalIds=null,this._animationFrameIds=null,this._isDisposed=!1,this._parent=t||null,this._onErrorHandler=n,this._noop=function(){}}return e.prototype.dispose=function(){var t;if(this._isDisposed=!0,this._parent=null,this._timeoutIds){for(t in this._timeoutIds)this._timeoutIds.hasOwnProperty(t)&&this.clearTimeout(parseInt(t,10));this._timeoutIds=null}if(this._immediateIds){for(t in this._immediateIds)this._immediateIds.hasOwnProperty(t)&&this.clearImmediate(parseInt(t,10));this._immediateIds=null}if(this._intervalIds){for(t in this._intervalIds)this._intervalIds.hasOwnProperty(t)&&this.clearInterval(parseInt(t,10));this._intervalIds=null}if(this._animationFrameIds){for(t in this._animationFrameIds)this._animationFrameIds.hasOwnProperty(t)&&this.cancelAnimationFrame(parseInt(t,10));this._animationFrameIds=null}},e.prototype.setTimeout=function(t,n){var r=this,o=0;return this._isDisposed||(this._timeoutIds||(this._timeoutIds={}),o=setTimeout(function(){try{r._timeoutIds&&delete r._timeoutIds[o],t.apply(r._parent)}catch(i){r._logError(i)}},n),this._timeoutIds[o]=!0),o},e.prototype.clearTimeout=function(t){this._timeoutIds&&this._timeoutIds[t]&&(clearTimeout(t),delete this._timeoutIds[t])},e.prototype.setImmediate=function(t,n){var r=this,o=0,i=ur(n);if(!this._isDisposed){this._immediateIds||(this._immediateIds={});var a=function(){try{r._immediateIds&&delete r._immediateIds[o],t.apply(r._parent)}catch(s){r._logError(s)}};o=i.setTimeout(a,0),this._immediateIds[o]=!0}return o},e.prototype.clearImmediate=function(t,n){var r=ur(n);this._immediateIds&&this._immediateIds[t]&&(r.clearTimeout(t),delete this._immediateIds[t])},e.prototype.setInterval=function(t,n){var r=this,o=0;return this._isDisposed||(this._intervalIds||(this._intervalIds={}),o=setInterval(function(){try{t.apply(r._parent)}catch(i){r._logError(i)}},n),this._intervalIds[o]=!0),o},e.prototype.clearInterval=function(t){this._intervalIds&&this._intervalIds[t]&&(clearInterval(t),delete this._intervalIds[t])},e.prototype.throttle=function(t,n,r){var o=this;if(this._isDisposed)return this._noop;var i=n||0,a=!0,s=!0,l=0,u,d,h=null;r&&typeof r.leading=="boolean"&&(a=r.leading),r&&typeof r.trailing=="boolean"&&(s=r.trailing);var p=function(v){var _=Date.now(),b=_-l,E=a?i-b:i;return b>=i&&(!v||a)?(l=_,h&&(o.clearTimeout(h),h=null),u=t.apply(o._parent,d)):h===null&&s&&(h=o.setTimeout(p,E)),u},m=function(){for(var v=[],_=0;_<arguments.length;_++)v[_]=arguments[_];return d=v,p(!0)};return m},e.prototype.debounce=function(t,n,r){var o=this;if(this._isDisposed){var i=function(){};return i.cancel=function(){},i.flush=function(){return null},i.pending=function(){return!1},i}var a=n||0,s=!1,l=!0,u=null,d=0,h=Date.now(),p,m,v=null;r&&typeof r.leading=="boolean"&&(s=r.leading),r&&typeof r.trailing=="boolean"&&(l=r.trailing),r&&typeof r.maxWait=="number"&&!isNaN(r.maxWait)&&(u=r.maxWait);var _=function(C){v&&(o.clearTimeout(v),v=null),h=C},b=function(C){_(C),p=t.apply(o._parent,m)},E=function(C){var A=Date.now(),P=!1;C&&(s&&A-d>=a&&(P=!0),d=A);var I=A-d,j=a-I,H=A-h,K=!1;return u!==null&&(H>=u&&v?K=!0:j=Math.min(j,u-H)),I>=a||K||P?b(A):(v===null||!C)&&l&&(v=o.setTimeout(E,j)),p},w=function(){return!!v},k=function(){w()&&_(Date.now())},y=function(){return w()&&b(Date.now()),p},F=function(){for(var C=[],A=0;A<arguments.length;A++)C[A]=arguments[A];return m=C,E(!0)};return F.cancel=k,F.flush=y,F.pending=w,F},e.prototype.requestAnimationFrame=function(t,n){var r=this,o=0,i=ur(n);if(!this._isDisposed){this._animationFrameIds||(this._animationFrameIds={});var a=function(){try{r._animationFrameIds&&delete r._animationFrameIds[o],t.apply(r._parent)}catch(s){r._logError(s)}};o=i.requestAnimationFrame?i.requestAnimationFrame(a):i.setTimeout(a,0),this._animationFrameIds[o]=!0}return o},e.prototype.cancelAnimationFrame=function(t,n){var r=ur(n);this._animationFrameIds&&this._animationFrameIds[t]&&(r.cancelAnimationFrame?r.cancelAnimationFrame(t):r.clearTimeout(t),delete this._animationFrameIds[t])},e.prototype._logError=function(t){this._onErrorHandler&&this._onErrorHandler(t)},e}();function T4(e,t){for(var n in e)if(e.hasOwnProperty(n)&&(!t.hasOwnProperty(n)||t[n]!==e[n]))return!1;for(var n in t)if(t.hasOwnProperty(n)&&!e.hasOwnProperty(n))return!1;return!0}function pc(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return PG.apply(this,[null,e].concat(t))}function PG(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];t=t||{};for(var o=0,i=n;o<i.length;o++){var a=i[o];if(a)for(var s in a)a.hasOwnProperty(s)&&(!e||e(s))&&(t[s]=a[s])}return t}var Ws=function(){function e(t){this._id=e._uniqueId++,this._parent=t,this._eventRecords=[]}return e.raise=function(t,n,r,o){var i;if(e._isElement(t)){if(typeof document<"u"&&document.createEvent){var a=document.createEvent("HTMLEvents");a.initEvent(n,o||!1,!0),pc(a,r),i=t.dispatchEvent(a)}else if(typeof document<"u"&&document.createEventObject){var s=document.createEventObject(r);t.fireEvent("on"+n,s)}}else for(;t&&i!==!1;){var l=t.__events__,u=l?l[n]:null;if(u){for(var d in u)if(u.hasOwnProperty(d))for(var h=u[d],p=0;i!==!1&&p<h.length;p++){var m=h[p];m.objectCallback&&(i=m.objectCallback.call(m.parent,r))}}t=o?t.parent:null}return i},e.isObserved=function(t,n){var r=t&&t.__events__;return!!r&&!!r[n]},e.isDeclared=function(t,n){var r=t&&t.__declaredEvents;return!!r&&!!r[n]},e.stopPropagation=function(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0},e._isElement=function(t){return!!t&&(!!t.addEventListener||typeof HTMLElement<"u"&&t instanceof HTMLElement)},e.prototype.dispose=function(){this._isDisposed||(this._isDisposed=!0,this.off(),this._parent=null)},e.prototype.onAll=function(t,n,r){for(var o in n)n.hasOwnProperty(o)&&this.on(t,o,n[o],r)},e.prototype.on=function(t,n,r,o){var i=this;if(n.indexOf(",")>-1)for(var a=n.split(/[ ,]+/),s=0;s<a.length;s++)this.on(t,a[s],r,o);else{var l=this._parent,u={target:t,eventName:n,parent:l,callback:r,options:o},a=t.__events__=t.__events__||{};if(a[n]=a[n]||{count:0},a[n][this._id]=a[n][this._id]||[],a[n][this._id].push(u),a[n].count++,e._isElement(t)){var d=function(){for(var m=[],v=0;v<arguments.length;v++)m[v]=arguments[v];if(!i._isDisposed){var _;try{if(_=r.apply(l,m),_===!1&&m[0]){var b=m[0];b.preventDefault&&b.preventDefault(),b.stopPropagation&&b.stopPropagation(),b.cancelBubble=!0}}catch{}return _}};u.elementCallback=d,t.addEventListener?t.addEventListener(n,d,o):t.attachEvent&&t.attachEvent("on"+n,d)}else{var h=function(){for(var m=[],v=0;v<arguments.length;v++)m[v]=arguments[v];if(!i._isDisposed)return r.apply(l,m)};u.objectCallback=h}this._eventRecords.push(u)}},e.prototype.off=function(t,n,r,o){for(var i=0;i<this._eventRecords.length;i++){var a=this._eventRecords[i];if((!t||t===a.target)&&(!n||n===a.eventName)&&(!r||r===a.callback)&&(typeof o!="boolean"||o===a.options)){var s=a.target.__events__,l=s[a.eventName],u=l?l[this._id]:null;u&&(u.length===1||!r?(l.count-=u.length,delete s[a.eventName][this._id]):(l.count--,u.splice(u.indexOf(a),1)),l.count||delete s[a.eventName]),a.elementCallback&&(a.target.removeEventListener?a.target.removeEventListener(a.eventName,a.elementCallback,a.options):a.target.detachEvent&&a.target.detachEvent("on"+a.eventName,a.elementCallback)),this._eventRecords.splice(i--,1)}}},e.prototype.raise=function(t,n,r){return e.raise(this._parent,t,n,r)},e.prototype.declare=function(t){var n=this._parent.__declaredEvents=this._parent.__declaredEvents||{};if(typeof t=="string")n[t]=!0;else for(var r=0;r<t.length;r++)n[t[r]]=!0},e._uniqueId=0,e}();function ss(e){if(!(typeof document>"u")){var t=e;return t&&t.ownerDocument?t.ownerDocument:document}}var Z5;Fo({overflow:"hidden !important"});function MG(){if(Z5===void 0){var e=document.createElement("div");e.style.setProperty("width","100px"),e.style.setProperty("height","100px"),e.style.setProperty("overflow","scroll"),e.style.setProperty("position","absolute"),e.style.setProperty("top","-9999px"),document.body.appendChild(e),Z5=e.offsetWidth-e.clientWidth,document.body.removeChild(e)}return Z5}var LG=void 0;function xF(e){console&&console.warn&&console.warn(e)}function CF(e,t,n,r,o){if(o===!0&&!1)for(var i,a;i<a.length;i++)var s}(function(e){yi(t,e);function t(n,r){var o=e.call(this,n,r)||this;return jG(o,t.prototype,["componentDidMount","shouldComponentUpdate","getSnapshotBeforeUpdate","render","componentDidUpdate","componentWillUnmount"]),o}return t.prototype.componentDidUpdate=function(n,r){this._updateComponentRef(n,this.props)},t.prototype.componentDidMount=function(){this._setComponentRef(this.props.componentRef,this)},t.prototype.componentWillUnmount=function(){if(this._setComponentRef(this.props.componentRef,null),this.__disposables){for(var n=0,r=this._disposables.length;n<r;n++){var o=this.__disposables[n];o.dispose&&o.dispose()}this.__disposables=null}},Object.defineProperty(t.prototype,"className",{get:function(){if(!this.__className){var n=/function (.{1,})\(/,r=n.exec(this.constructor.toString());this.__className=r&&r.length>1?r[1]:""}return this.__className},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"_disposables",{get:function(){return this.__disposables||(this.__disposables=[]),this.__disposables},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"_async",{get:function(){return this.__async||(this.__async=new _b(this),this._disposables.push(this.__async)),this.__async},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"_events",{get:function(){return this.__events||(this.__events=new Ws(this),this._disposables.push(this.__events)),this.__events},enumerable:!1,configurable:!0}),t.prototype._resolveRef=function(n){var r=this;return this.__resolves||(this.__resolves={}),this.__resolves[n]||(this.__resolves[n]=function(o){return r[n]=o}),this.__resolves[n]},t.prototype._updateComponentRef=function(n,r){r===void 0&&(r={}),n&&r&&n.componentRef!==r.componentRef&&(this._setComponentRef(n.componentRef,null),this._setComponentRef(r.componentRef,this))},t.prototype._warnDeprecations=function(n){this.className,this.props},t.prototype._warnMutuallyExclusive=function(n){this.className,this.props},t.prototype._warnConditionallyRequiredProps=function(n,r,o){CF(this.className,this.props,n,r,o)},t.prototype._setComponentRef=function(n,r){!this._skipComponentRefResolution&&n&&(typeof n=="function"&&n(r),typeof n=="object"&&(n.current=r))},t})(T.Component);function jG(e,t,n){for(var r=0,o=n.length;r<o;r++)zG(e,t,n[r])}function zG(e,t,n){var r=e[n],o=t[n];(r||o)&&(e[n]=function(){for(var i=[],a=0;a<arguments.length;a++)i[a]=arguments[a];var s;return o&&(s=o.apply(this,i)),r!==o&&(s=r.apply(this,i)),s})}function AF(){return null}var J5="__globalSettings__",w4="__callbacks__",HG=0,NF=function(){function e(){}return e.getValue=function(t,n){var r=vE();return r[t]===void 0&&(r[t]=typeof n=="function"?n():n),r[t]},e.setValue=function(t,n){var r=vE(),o=r[w4],i=r[t];if(n!==i){r[t]=n;var a={oldValue:i,value:n,key:t};for(var s in o)o.hasOwnProperty(s)&&o[s](a)}return n},e.addChangeListener=function(t){var n=t.__id__,r=tx();n||(n=t.__id__=String(HG++)),r[n]=t},e.removeChangeListener=function(t){var n=tx();delete n[t.__id__]},e}();function vE(){var e,t=ur(),n=t||{};return n[J5]||(n[J5]=(e={},e[w4]={},e)),n[J5]}function tx(){var e=vE();return e[w4]}var qt={backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,pauseBreak:19,capslock:20,escape:27,space:32,pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40,insert:45,del:46,zero:48,one:49,two:50,three:51,four:52,five:53,six:54,seven:55,eight:56,nine:57,colon:58,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,leftWindow:91,rightWindow:92,select:93,zero_numpad:96,one_numpad:97,two_numpad:98,three_numpad:99,four_numpad:100,five_numpad:101,six_numpad:102,seven_numpad:103,eight_numpad:104,nine_numpad:105,multiply:106,add:107,subtract:109,decimalPoint:110,divide: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,scrollLock:145,semicolon:186,equalSign:187,comma:188,dash:189,period:190,forwardSlash:191,graveAccent:192,openBracket:219,backSlash:220,closeBracket:221,singleQuote:222},ts=function(){function e(t,n,r,o){t===void 0&&(t=0),n===void 0&&(n=0),r===void 0&&(r=0),o===void 0&&(o=0),this.top=r,this.bottom=o,this.left=t,this.right=n}return Object.defineProperty(e.prototype,"width",{get:function(){return this.right-this.left},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"height",{get:function(){return this.bottom-this.top},enumerable:!1,configurable:!0}),e.prototype.equals=function(t){return parseFloat(this.top.toFixed(4))===parseFloat(t.top.toFixed(4))&&parseFloat(this.bottom.toFixed(4))===parseFloat(t.bottom.toFixed(4))&&parseFloat(this.left.toFixed(4))===parseFloat(t.left.toFixed(4))&&parseFloat(this.right.toFixed(4))===parseFloat(t.right.toFixed(4))},e}();function UG(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.length<2?t[0]:function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];t.forEach(function(i){return i&&i.apply(e,r)})}}function $0(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=e.filter(function(r){return r}).join(" ").trim();return n===""?void 0:n}function qG(e,t,n){var r=e.slice();return r.splice(t,0,n),r}function $G(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function FF(e){var t=null;try{var n=ur();t=n?n.sessionStorage.getItem(e):null}catch{}return t}function WG(e,t){var n;try{(n=ur())===null||n===void 0||n.sessionStorage.setItem(e,t)}catch{}}var IF="isRTL",Hs;function ls(e){if(e===void 0&&(e={}),e.rtl!==void 0)return e.rtl;if(Hs===void 0){var t=FF(IF);t!==null&&(Hs=t==="1",GG(Hs));var n=ss();Hs===void 0&&n&&(Hs=(n.body&&n.body.getAttribute("dir")||n.documentElement.getAttribute("dir"))==="rtl",gF(Hs))}return!!Hs}function GG(e,t){t===void 0&&(t=!1);var n=ss();n&&n.documentElement.setAttribute("dir",e?"rtl":"ltr"),t&&WG(IF,e?"1":"0"),Hs=e,gF(Hs)}function KG(e){return e&&!!e._virtual}function VG(e){var t;return e&&KG(e)&&(t=e._virtual.parent),t}function BF(e,t){return t===void 0&&(t=!0),e&&(t&&VG(e)||e.parentNode&&e.parentNode)}function bE(e,t,n){n===void 0&&(n=!0);var r=!1;if(e&&t)if(n)if(e===t)r=!0;else for(r=!1;t;){var o=BF(t);if(o===e){r=!0;break}t=o}else e.contains&&(r=e.contains(t));return r}function k4(e,t){return!e||e===document.body?null:t(e)?e:k4(BF(e),t)}function YG(e,t){var n=k4(e,function(r){return r.hasAttribute(t)});return n&&n.getAttribute(t)}var yE="data-portal-element";function QG(e){e.setAttribute(yE,"true")}function XG(e,t){var n=k4(e,function(r){return t===r||r.hasAttribute(yE)});return n!==null&&n.hasAttribute(yE)}function ZG(e,t){var n=e,r=t;n._virtual||(n._virtual={children:[]});var o=n._virtual.parent;if(o&&o!==t){var i=o._virtual.children.indexOf(n);i>-1&&o._virtual.children.splice(i,1)}n._virtual.parent=r||void 0,r&&(r._virtual||(r._virtual={children:[]}),r._virtual.children.push(n))}var JG="data-is-focusable",eK="data-is-visible",tK="data-focuszone-id",nK="data-is-sub-focuszone";function rK(e,t,n){return xh(e,t,!0,!1,!1,n)}function oK(e,t,n){return jf(e,t,!0,!1,!0,n)}function iK(e){var t=xh(e,e,!0,!1,!1,!0);return t?(lK(t),!0):!1}function jf(e,t,n,r,o,i,a,s){if(!t||!a&&t===e)return null;var l=RF(t);if(o&&l&&(i||!(OF(t)||DF(t)))){var u=jf(e,t.lastElementChild,!0,!0,!0,i,a,s);if(u){if(s&&EE(u,!0)||!s)return u;var d=jf(e,u.previousElementSibling,!0,!0,!0,i,a,s);if(d)return d;for(var h=u.parentElement;h&&h!==t;){var p=jf(e,h.previousElementSibling,!0,!0,!0,i,a,s);if(p)return p;h=h.parentElement}}}if(n&&l&&EE(t,s))return t;var m=jf(e,t.previousElementSibling,!0,!0,!0,i,a,s);return m||(r?null:jf(e,t.parentElement,!0,!1,!1,i,a,s))}function xh(e,t,n,r,o,i,a,s){if(!t||t===e&&o&&!a)return null;var l=RF(t);if(n&&l&&EE(t,s))return t;if(!o&&l&&(i||!(OF(t)||DF(t)))){var u=xh(e,t.firstElementChild,!0,!0,!1,i,a,s);if(u)return u}if(t===e)return null;var d=xh(e,t.nextElementSibling,!0,!0,!1,i,a,s);return d||(r?null:xh(e,t.parentElement,!1,!1,!0,i,a,s))}function RF(e){if(!e||!e.getAttribute)return!1;var t=e.getAttribute(eK);return t!=null?t==="true":e.offsetHeight!==0||e.offsetParent!==null||e.isVisible===!0}function EE(e,t){if(!e||e.disabled)return!1;var n=0,r=null;e&&e.getAttribute&&(r=e.getAttribute("tabIndex"),r&&(n=parseInt(r,10)));var o=e.getAttribute?e.getAttribute(JG):null,i=r!==null&&n>=0,a=!!e&&o!=="false"&&(e.tagName==="A"||e.tagName==="BUTTON"||e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.tagName==="SELECT"||o==="true"||i);return t?n!==-1&&a:a}function OF(e){return!!(e&&e.getAttribute&&e.getAttribute(tK))}function DF(e){return!!(e&&e.getAttribute&&e.getAttribute(nK)==="true")}function aK(e){var t=ss(e),n=t&&t.activeElement;return!!(n&&bE(e,n))}function sK(e,t){return YG(e,t)!=="true"}var bf=void 0;function lK(e){if(e){if(bf){bf=e;return}bf=e;var t=ur(e);t&&t.requestAnimationFrame(function(){bf&&bf.focus(),bf=void 0})}}function zf(e,t,n,r){return e.addEventListener(t,n,r),function(){return e.removeEventListener(t,n,r)}}var uK=50,cK=5,yg=0,e2=Qi.getInstance();e2&&e2.onReset&&e2.onReset(function(){return yg++});var ym="__retval__";function ml(e){e===void 0&&(e={});var t=new Map,n=0,r=0,o=yg,i=function(a,s){var l;if(s===void 0&&(s={}),e.useStaticStyles&&typeof a=="function"&&a.__noStyleOverride__)return a(s);r++;var u=t,d=s.theme,h=d&&d.rtl!==void 0?d.rtl:ls(),p=e.disableCaching;if(o!==yg&&(o=yg,t=new Map,n=0),e.disableCaching||(u=nx(t,a),u=nx(u,s)),(p||!u[ym])&&(a===void 0?u[ym]={}:u[ym]=wF([typeof a=="function"?a(s):a],{rtl:!!h,specificityMultiplier:e.useStaticStyles?cK:void 0}),p||n++),n>(e.cacheSize||uK)){var m=ur();!((l=m==null?void 0:m.FabricConfig)===null||l===void 0)&&l.enableClassNameCacheFullWarning&&(console.warn("Styles are being recalculated too frequently. Cache miss rate is "+n+"/"+r+"."),console.trace()),t.clear(),n=0,e.disableCaching=!0}return u[ym]};return i}function t2(e,t){return t=fK(t),e.has(t)||e.set(t,new Map),e.get(t)}function nx(e,t){if(typeof t=="function"){var n=t.__cachedInputs__;if(n)for(var r=0,o=t.__cachedInputs__;r<o.length;r++){var i=o[r];e=t2(e,i)}else e=t2(e,t)}else if(typeof t=="object")for(var a in t)t.hasOwnProperty(a)&&(e=t2(e,t[a]));return e}function fK(e){switch(e){case void 0:return"__undefined__";case null:return"__null__";default:return e}}var rx=!1,Eg=0,dK={empty:!0},n2={},r0=typeof WeakMap>"u"?null:WeakMap;function hK(){Eg++}function Cr(e,t,n){if(t===void 0&&(t=100),n===void 0&&(n=!1),!r0)return e;if(!rx){var r=Qi.getInstance();r&&r.onReset&&Qi.getInstance().onReset(hK),rx=!0}var o,i=0,a=Eg;return function(){for(var l=[],u=0;u<arguments.length;u++)l[u]=arguments[u];var d=o;(o===void 0||a!==Eg||t>0&&i>t)&&(o=ox(),i=0,a=Eg),d=o;for(var h=0;h<l.length;h++){var p=pK(l[h]);d.map.has(p)||d.map.set(p,ox()),d=d.map.get(p)}return d.hasOwnProperty("value")||(d.value=e.apply(void 0,l),i++),n&&(d.value===null||d.value===void 0)&&(d.value=e.apply(void 0,l)),d.value}}function Od(e){if(!r0)return e;var t=new r0;function n(r){if(!r||typeof r!="function"&&typeof r!="object")return e(r);if(t.has(r))return t.get(r);var o=e(r);return t.set(r,o),o}return n}function pK(e){if(e){if(typeof e=="object"||typeof e=="function")return e;n2[e]||(n2[e]={val:e})}else return dK;return n2[e]}function ox(){return{map:r0?new r0:null}}function mK(e){var t=e,n=Od(function(r){if(e===r)throw new Error("Attempted to compose a component with itself.");var o=r,i=Od(function(s){var l=function(u){return T.createElement(o,oe({},u,{defaultRender:s}))};return l}),a=function(s){var l=s.defaultRender;return T.createElement(t,oe({},s,{defaultRender:l?i(l):o}))};return a});return n}var gK=Od(mK);function PF(e,t){return gK(e)(t)}function Ys(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=[],r=0,o=e;r<o.length;r++){var i=o[r];if(i)if(typeof i=="string")n.push(i);else if(i.hasOwnProperty("toString")&&typeof i.toString=="function")n.push(i.toString());else for(var a in i)i[a]&&n.push(a)}return n.join(" ")}var vK="customizations",bK={settings:{},scopedSettings:{},inCustomizerContext:!1},Ol=NF.getValue(vK,{settings:{},scopedSettings:{},inCustomizerContext:!1}),Em=[],$i=function(){function e(){}return e.reset=function(){Ol.settings={},Ol.scopedSettings={}},e.applySettings=function(t){Ol.settings=oe(oe({},Ol.settings),t),e._raiseChange()},e.applyScopedSettings=function(t,n){Ol.scopedSettings[t]=oe(oe({},Ol.scopedSettings[t]),n),e._raiseChange()},e.getSettings=function(t,n,r){r===void 0&&(r=bK);for(var o={},i=n&&r.scopedSettings[n]||{},a=n&&Ol.scopedSettings[n]||{},s=0,l=t;s<l.length;s++){var u=l[s];o[u]=i[u]||r.settings[u]||a[u]||Ol.settings[u]}return o},e.applyBatchedUpdates=function(t,n){e._suppressUpdates=!0;try{t()}catch{}e._suppressUpdates=!1,n||e._raiseChange()},e.observe=function(t){Em.push(t)},e.unobserve=function(t){Em=Em.filter(function(n){return n!==t})},e._raiseChange=function(){e._suppressUpdates||Em.forEach(function(t){return t()})},e}(),o0=T.createContext({customizations:{inCustomizerContext:!1,settings:{},scopedSettings:{}}});function yK(e,t){e===void 0&&(e={});var n=MF(t)?t:_K(t);return n(e)}function EK(e,t){e===void 0&&(e={});var n=MF(t)?t:TK(t);return n(e)}function MF(e){return typeof e=="function"}function _K(e){return function(t){return e?oe(oe({},t),e):t}}function TK(e){return e===void 0&&(e={}),function(t){var n=oe({},t);for(var r in e)e.hasOwnProperty(r)&&(n[r]=oe(oe({},t[r]),e[r]));return n}}function wK(e,t){var n=(t||{}).customizations,r=n===void 0?{settings:{},scopedSettings:{}}:n;return{customizations:{settings:yK(r.settings,e.settings),scopedSettings:EK(r.scopedSettings,e.scopedSettings),inCustomizerContext:!0}}}var kK=function(e){yi(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n._onCustomizationChange=function(){return n.forceUpdate()},n}return t.prototype.componentDidMount=function(){$i.observe(this._onCustomizationChange)},t.prototype.componentWillUnmount=function(){$i.unobserve(this._onCustomizationChange)},t.prototype.render=function(){var n=this,r=this.props.contextTransform;return T.createElement(o0.Consumer,null,function(o){var i=wK(n.props,o);return r&&(i=r(i)),T.createElement(o0.Provider,{value:i},n.props.children)})},t}(T.Component);function SK(e,t){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function xK(e,t,n){return function(o){var i,a=(i=function(s){yi(l,s);function l(u){var d=s.call(this,u)||this;return d._styleCache={},d._onSettingChanged=d._onSettingChanged.bind(d),d}return l.prototype.componentDidMount=function(){$i.observe(this._onSettingChanged)},l.prototype.componentWillUnmount=function(){$i.unobserve(this._onSettingChanged)},l.prototype.render=function(){var u=this;return T.createElement(o0.Consumer,null,function(d){var h=$i.getSettings(t,e,d.customizations),p=u.props;if(h.styles&&typeof h.styles=="function"&&(h.styles=h.styles(oe(oe({},h),p))),n&&h.styles){if(u._styleCache.default!==h.styles||u._styleCache.component!==p.styles){var m=jc(h.styles,p.styles);u._styleCache.default=h.styles,u._styleCache.component=p.styles,u._styleCache.merged=m}return T.createElement(o,oe({},h,p,{styles:u._styleCache.merged}))}return T.createElement(o,oe({},h,p))})},l.prototype._onSettingChanged=function(){this.forceUpdate()},l}(T.Component),i.displayName="Customized"+e,i);return SK(o,a)}}function CK(e,t){var n=AK(),r=T.useContext(o0).customizations,o=r.inCustomizerContext;return T.useEffect(function(){return o||$i.observe(n),function(){o||$i.unobserve(n)}},[o]),$i.getSettings(e,t,r)}function AK(){var e=T.useState(0),t=e[1];return function(){return t(function(n){return++n})}}function NK(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=UG(e,e[n],t[n]))}var ov="__currentId__",FK="id__",iv=ur()||{};iv[ov]===void 0&&(iv[ov]=0);var ix=!1;function cu(e){if(!ix){var t=Qi.getInstance();t&&t.onReset&&t.onReset(IK),ix=!0}var n=iv[ov]++;return(e===void 0?FK:e)+n}function IK(e){e===void 0&&(e=0),iv[ov]=e}var Xn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n={},r=0,o=e;r<o.length;r++)for(var i=o[r],a=Array.isArray(i)?i:Object.keys(i),s=0,l=a;s<l.length;s++){var u=l[s];n[u]=1}return n},BK=Xn(["onCopy","onCut","onPaste","onCompositionEnd","onCompositionStart","onCompositionUpdate","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onInput","onSubmit","onLoad","onError","onKeyDown","onKeyDownCapture","onKeyPress","onKeyUp","onAbort","onCanPlay","onCanPlayThrough","onDurationChange","onEmptied","onEncrypted","onEnded","onLoadedData","onLoadedMetadata","onLoadStart","onPause","onPlay","onPlaying","onProgress","onRateChange","onSeeked","onSeeking","onStalled","onSuspend","onTimeUpdate","onVolumeChange","onWaiting","onClick","onClickCapture","onContextMenu","onDoubleClick","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onMouseUpCapture","onSelect","onTouchCancel","onTouchEnd","onTouchMove","onTouchStart","onScroll","onWheel","onPointerCancel","onPointerDown","onPointerEnter","onPointerLeave","onPointerMove","onPointerOut","onPointerOver","onPointerUp","onGotPointerCapture","onLostPointerCapture"]),RK=Xn(["accessKey","children","className","contentEditable","dir","draggable","hidden","htmlFor","id","lang","ref","role","style","tabIndex","title","translate","spellCheck","name"]),fr=Xn(RK,BK);Xn(fr,["form"]);var OK=Xn(fr,["height","loop","muted","preload","src","width"]);Xn(OK,["poster"]);Xn(fr,["start"]);Xn(fr,["value"]);var LF=Xn(fr,["download","href","hrefLang","media","rel","target","type"]),Oc=Xn(fr,["autoFocus","disabled","form","formAction","formEncType","formMethod","formNoValidate","formTarget","type","value"]);Xn(Oc,["accept","alt","autoCapitalize","autoComplete","checked","dirname","form","height","inputMode","list","max","maxLength","min","minLength","multiple","pattern","placeholder","readOnly","required","src","step","size","type","value","width"]);Xn(Oc,["autoCapitalize","cols","dirname","form","maxLength","minLength","placeholder","readOnly","required","rows","wrap"]);Xn(Oc,["form","multiple","required"]);Xn(fr,["selected","value"]);Xn(fr,["cellPadding","cellSpacing"]);Xn(fr,["rowSpan","scope"]);Xn(fr,["colSpan","headers","rowSpan","scope"]);Xn(fr,["span"]);Xn(fr,["span"]);Xn(fr,["acceptCharset","action","encType","encType","method","noValidate","target"]);Xn(fr,["allow","allowFullScreen","allowPaymentRequest","allowTransparency","csp","height","importance","referrerPolicy","sandbox","src","srcDoc","width"]);var DK=Xn(fr,["alt","crossOrigin","height","src","srcSet","useMap","width"]),W0=fr;function Zr(e,t,n){for(var r=Array.isArray(t),o={},i=Object.keys(e),a=0,s=i;a<s.length;a++){var l=s[a],u=!r&&t[l]||r&&t.indexOf(l)>=0||l.indexOf("data-")===0||l.indexOf("aria-")===0;u&&(!n||(n==null?void 0:n.indexOf(l))===-1)&&(o[l]=e[l])}return o}function Tb(e){NK(e,{componentDidMount:PK,componentDidUpdate:MK,componentWillUnmount:LK})}function PK(){av(this.props.componentRef,this)}function MK(e){e.componentRef!==this.props.componentRef&&(av(e.componentRef,null),av(this.props.componentRef,this))}function LK(){av(this.props.componentRef,null)}function av(e,t){e&&(typeof e=="object"?e.current=t:typeof e=="function"&&e(t))}var ca,jK=(ca={},ca[qt.up]=1,ca[qt.down]=1,ca[qt.left]=1,ca[qt.right]=1,ca[qt.home]=1,ca[qt.end]=1,ca[qt.tab]=1,ca[qt.pageUp]=1,ca[qt.pageDown]=1,ca);function zK(e){return!!jK[e]}var Go="ms-Fabric--isFocusVisible",ax="ms-Fabric--isFocusHidden";function dd(e,t){var n=t?ur(t):ur();if(n){var r=n.document.body.classList;r.add(e?Go:ax),r.remove(e?ax:Go)}}var sx=new WeakMap;function lx(e,t){var n,r=sx.get(e);return r?n=r+t:n=1,sx.set(e,n),n}function jF(e){T.useEffect(function(){var t,n=ur(e==null?void 0:e.current);if(!(!n||((t=n.FabricConfig)===null||t===void 0?void 0:t.disableFocusRects)===!0)){var r=lx(n,1);return r<=1&&(n.addEventListener("mousedown",ux,!0),n.addEventListener("pointerdown",cx,!0),n.addEventListener("keydown",fx,!0)),function(){var o;!n||((o=n.FabricConfig)===null||o===void 0?void 0:o.disableFocusRects)===!0||(r=lx(n,-1),r===0&&(n.removeEventListener("mousedown",ux,!0),n.removeEventListener("pointerdown",cx,!0),n.removeEventListener("keydown",fx,!0)))}}},[e])}var HK=function(e){return jF(e.rootRef),null};function ux(e){dd(!1,e.target)}function cx(e){e.pointerType!=="mouse"&&dd(!1,e.target)}function fx(e){zK(e.which)&&dd(!0,e.target)}function UK(e){var t=null;try{var n=ur();t=n?n.localStorage.getItem(e):null}catch{}return t}var tc,dx="language";function qK(e){if(e===void 0&&(e="sessionStorage"),tc===void 0){var t=ss(),n=e==="localStorage"?UK(dx):e==="sessionStorage"?FF(dx):void 0;n&&(tc=n),tc===void 0&&t&&(tc=t.documentElement.getAttribute("lang")),tc===void 0&&(tc="en")}return tc}function hx(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=0,o=t;r<o.length;r++){var i=o[r];zF(e||{},i)}return e}function zF(e,t,n){n===void 0&&(n=[]),n.push(t);for(var r in t)if(t.hasOwnProperty(r)&&r!=="__proto__"&&r!=="constructor"&&r!=="prototype"){var o=t[r];if(typeof o=="object"&&o!==null&&!Array.isArray(o)){var i=n.indexOf(o)>-1;e[r]=i?o:zF(e[r]||{},o,n)}else e[r]=o}return n.pop(),e}var px=function(){return!window||!window.navigator||!window.navigator.userAgent?!1:/iPad|iPhone|iPod/i.test(window.navigator.userAgent)},$K=["TEMPLATE","STYLE","SCRIPT"];function WK(e){var t=ss(e);if(!t)return function(){};for(var n=[];e!==t.body&&e.parentElement;){for(var r=0,o=e.parentElement.children;r<o.length;r++){var i=o[r],a=i.getAttribute("aria-hidden");i!==e&&(a==null?void 0:a.toLowerCase())!=="true"&&$K.indexOf(i.tagName)===-1&&n.push([i,a])}e=e.parentElement}return n.forEach(function(s){var l=s[0];l.setAttribute("aria-hidden","true")}),function(){GK(n),n=[]}}function GK(e){e.forEach(function(t){var n=t[0],r=t[1];r?n.setAttribute("aria-hidden",r):n.removeAttribute("aria-hidden")})}var r2;function mx(e){var t;if(typeof r2>"u"||e){var n=ur(),r=(t=n==null?void 0:n.navigator)===null||t===void 0?void 0:t.userAgent;r2=!!r&&r.indexOf("Macintosh")!==-1}return!!r2}function KK(e){var t=Od(function(n){var r=Od(function(o){return function(i){return n(i,o)}});return function(o,i){return e(o,i?r(i):n)}});return t}var VK=Od(KK);function HF(e,t){return VK(e)(t)}var YK=["theme","styles"];function gl(e,t,n,r,o){r=r||{scope:"",fields:void 0};var i=r.scope,a=r.fields,s=a===void 0?YK:a,l=T.forwardRef(function(d,h){var p=T.useRef(),m=CK(s,i),v=m.styles;m.dir;var _=pl(m,["styles","dir"]),b=n?n(d):void 0,E=p.current&&p.current.__cachedInputs__||[],w=d.styles;if(!p.current||v!==E[1]||w!==E[2]){var k=function(y){return kF(y,t,v,w)};k.__cachedInputs__=[t,v,w],k.__noStyleOverride__=!v&&!w,p.current=k}return T.createElement(e,oe({ref:h},_,b,d,{styles:p.current}))});l.displayName="Styled"+(e.displayName||e.name);var u=o?T.memo(l):l;return l.displayName&&(u.displayName=l.displayName),u}function S4(e,t){for(var n=oe({},t),r=0,o=Object.keys(e);r<o.length;r++){var i=o[r];n[i]===void 0&&(n[i]=e[i])}return n}var QK=function(e){return function(t){for(var n=0,r=e.refs;n<r.length;n++){var o=r[n];typeof o=="function"?o(t):o&&(o.current=t)}}},XK=function(e){var t={refs:[]};return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return(!t.resolver||!$G(t.refs,n))&&(t.resolver=QK(t)),t.refs=n,t.resolver}},i0=T.useLayoutEffect,ZK="icons",mi=NF.getValue(ZK,{__options:{disableWarnings:!1,warnOnMissingIcons:!0},__remapped:{}}),o2=Qi.getInstance();o2&&o2.onReset&&o2.onReset(function(){for(var e in mi)mi.hasOwnProperty(e)&&mi[e].subset&&(mi[e].subset.className=void 0)});var sv=function(e){return e.toLowerCase()};function Ar(e,t){var n=oe(oe({},e),{isRegistered:!1,className:void 0}),r=e.icons;t=t?oe(oe({},mi.__options),t):mi.__options;for(var o in r)if(r.hasOwnProperty(o)){var i=r[o],a=sv(o);mi[a]?eV(o):mi[a]={code:i,subset:n}}}function nc(e,t){mi.__remapped[sv(e)]=sv(t)}function JK(e){var t=void 0,n=mi.__options;if(e=e?sv(e):"",e=mi.__remapped[e]||e,e)if(t=mi[e],t){var r=t.subset;r&&r.fontFace&&(r.isRegistered||(SF(r.fontFace),r.isRegistered=!0),r.className||(r.className=Fo(r.style,{fontFamily:r.fontFace.fontFamily,fontWeight:r.fontFace.fontWeight||"normal",fontStyle:r.fontFace.fontStyle||"normal"})))}else!n.disableWarnings&&n.warnOnMissingIcons&&xF('The icon "'+e+'" was used but not registered. See https://github.com/microsoft/fluentui/wiki/Using-icons for more information.');return t}var z1=[],i2=void 0;function eV(e){var t=mi.__options,n=2e3,r=10;t.disableWarnings||(z1.push(e),i2===void 0&&(i2=setTimeout(function(){xF(`Some icons were re-registered. Applications should only call registerIcons for any given icon once. Redefining what an icon is may have unintended consequences. Duplicates include: `+z1.slice(0,r).join(", ")+(z1.length>r?" (+ "+(z1.length-r)+" more)":"")),i2=void 0,z1=[]},n)))}function tV(e,t,n,r,o){o===void 0&&(o=!1);var i=oe({primaryButtonBorder:"transparent",errorText:r?"#F1707B":"#a4262c",messageText:r?"#F3F2F1":"#323130",messageLink:r?"#6CB8F6":"#005A9E",messageLinkHovered:r?"#82C7FF":"#004578",infoIcon:r?"#C8C6C4":"#605e5c",errorIcon:r?"#F1707B":"#A80000",blockingIcon:r?"#442726":"#FDE7E9",warningIcon:r?"#C8C6C4":"#797775",severeWarningIcon:r?"#FCE100":"#D83B01",successIcon:r?"#92C353":"#107C10",infoBackground:r?"#323130":"#f3f2f1",errorBackground:r?"#442726":"#FDE7E9",blockingBackground:r?"#442726":"#FDE7E9",warningBackground:r?"#433519":"#FFF4CE",severeWarningBackground:r?"#4F2A0F":"#FED9CC",successBackground:r?"#393D1B":"#DFF6DD",warningHighlight:r?"#fff100":"#ffb900",successText:r?"#92c353":"#107C10"},n),a=UF(e,t,i,r);return nV(a,o)}function UF(e,t,n,r,o){var i={},a=e||{},s=a.white,l=a.black,u=a.themePrimary,d=a.themeDark,h=a.themeDarker,p=a.themeDarkAlt,m=a.themeLighter,v=a.neutralLight,_=a.neutralLighter,b=a.neutralDark,E=a.neutralQuaternary,w=a.neutralQuaternaryAlt,k=a.neutralPrimary,y=a.neutralSecondary,F=a.neutralSecondaryAlt,C=a.neutralTertiary,A=a.neutralTertiaryAlt,P=a.neutralLighterAlt,I=a.accent;return s&&(i.bodyBackground=s,i.bodyFrameBackground=s,i.accentButtonText=s,i.buttonBackground=s,i.primaryButtonText=s,i.primaryButtonTextHovered=s,i.primaryButtonTextPressed=s,i.inputBackground=s,i.inputForegroundChecked=s,i.listBackground=s,i.menuBackground=s,i.cardStandoutBackground=s),l&&(i.bodyTextChecked=l,i.buttonTextCheckedHovered=l),u&&(i.link=u,i.primaryButtonBackground=u,i.inputBackgroundChecked=u,i.inputIcon=u,i.inputFocusBorderAlt=u,i.menuIcon=u,i.menuHeader=u,i.accentButtonBackground=u),d&&(i.primaryButtonBackgroundPressed=d,i.inputBackgroundCheckedHovered=d,i.inputIconHovered=d),h&&(i.linkHovered=h),p&&(i.primaryButtonBackgroundHovered=p),m&&(i.inputPlaceholderBackgroundChecked=m),v&&(i.bodyBackgroundChecked=v,i.bodyFrameDivider=v,i.bodyDivider=v,i.variantBorder=v,i.buttonBackgroundCheckedHovered=v,i.buttonBackgroundPressed=v,i.listItemBackgroundChecked=v,i.listHeaderBackgroundPressed=v,i.menuItemBackgroundPressed=v,i.menuItemBackgroundChecked=v),_&&(i.bodyBackgroundHovered=_,i.buttonBackgroundHovered=_,i.buttonBackgroundDisabled=_,i.buttonBorderDisabled=_,i.primaryButtonBackgroundDisabled=_,i.disabledBackground=_,i.listItemBackgroundHovered=_,i.listHeaderBackgroundHovered=_,i.menuItemBackgroundHovered=_),E&&(i.primaryButtonTextDisabled=E,i.disabledSubtext=E),w&&(i.listItemBackgroundCheckedHovered=w),C&&(i.disabledBodyText=C,i.variantBorderHovered=(n==null?void 0:n.variantBorderHovered)||C,i.buttonTextDisabled=C,i.inputIconDisabled=C,i.disabledText=C),k&&(i.bodyText=k,i.actionLink=k,i.buttonText=k,i.inputBorderHovered=k,i.inputText=k,i.listText=k,i.menuItemText=k),P&&(i.bodyStandoutBackground=P,i.defaultStateBackground=P),b&&(i.actionLinkHovered=b,i.buttonTextHovered=b,i.buttonTextChecked=b,i.buttonTextPressed=b,i.inputTextHovered=b,i.menuItemTextHovered=b),y&&(i.bodySubtext=y,i.focusBorder=y,i.inputBorder=y,i.smallInputBorder=y,i.inputPlaceholderText=y),F&&(i.buttonBorder=F),A&&(i.disabledBodySubtext=A,i.disabledBorder=A,i.buttonBackgroundChecked=A,i.menuDivider=A),I&&(i.accentButtonBackground=I),t!=null&&t.elevation4&&(i.cardShadow=t.elevation4),!r&&(t!=null&&t.elevation8)?i.cardShadowHovered=t.elevation8:i.variantBorderHovered&&(i.cardShadowHovered="0 0 1px "+i.variantBorderHovered),i=oe(oe({},i),n),i}function nV(e,t){var n="";return t===!0&&(n=" /* @deprecated */"),e.listTextColor=e.listText+n,e.menuItemBackgroundChecked+=n,e.warningHighlight+=n,e.warningText=e.messageText+n,e.successText+=n,e}function rV(e,t){var n,r,o;t===void 0&&(t={});var i=hx({},e,t,{semanticColors:UF(t.palette,t.effects,t.semanticColors,t.isInverted===void 0?e.isInverted:t.isInverted)});if(!((n=t.palette)===null||n===void 0)&&n.themePrimary&&!(!((r=t.palette)===null||r===void 0)&&r.accent)&&(i.palette.accent=t.palette.themePrimary),t.defaultFontStyle)for(var a=0,s=Object.keys(i.fonts);a<s.length;a++){var l=s[a];i.fonts[l]=hx(i.fonts[l],t.defaultFontStyle,(o=t==null?void 0:t.fonts)===null||o===void 0?void 0:o[l])}return i}var gx={themeDarker:"#004578",themeDark:"#005a9e",themeDarkAlt:"#106ebe",themePrimary:"#0078d4",themeSecondary:"#2b88d8",themeTertiary:"#71afe5",themeLight:"#c7e0f4",themeLighter:"#deecf9",themeLighterAlt:"#eff6fc",black:"#000000",blackTranslucent40:"rgba(0,0,0,.4)",neutralDark:"#201f1e",neutralPrimary:"#323130",neutralPrimaryAlt:"#3b3a39",neutralSecondary:"#605e5c",neutralSecondaryAlt:"#8a8886",neutralTertiary:"#a19f9d",neutralTertiaryAlt:"#c8c6c4",neutralQuaternary:"#d2d0ce",neutralQuaternaryAlt:"#e1dfdd",neutralLight:"#edebe9",neutralLighter:"#f3f2f1",neutralLighterAlt:"#faf9f8",accent:"#0078d4",white:"#ffffff",whiteTranslucent40:"rgba(255,255,255,.4)",yellowDark:"#d29200",yellow:"#ffb900",yellowLight:"#fff100",orange:"#d83b01",orangeLight:"#ea4300",orangeLighter:"#ff8c00",redDark:"#a4262c",red:"#e81123",magentaDark:"#5c005c",magenta:"#b4009e",magentaLight:"#e3008c",purpleDark:"#32145a",purple:"#5c2d91",purpleLight:"#b4a0ff",blueDark:"#002050",blueMid:"#00188f",blue:"#0078d4",blueLight:"#00bcf2",tealDark:"#004b50",teal:"#008272",tealLight:"#00b294",greenDark:"#004b1c",green:"#107c10",greenLight:"#bad80a"},Xf;(function(e){e.depth0="0 0 0 0 transparent",e.depth4="0 1.6px 3.6px 0 rgba(0, 0, 0, 0.132), 0 0.3px 0.9px 0 rgba(0, 0, 0, 0.108)",e.depth8="0 3.2px 7.2px 0 rgba(0, 0, 0, 0.132), 0 0.6px 1.8px 0 rgba(0, 0, 0, 0.108)",e.depth16="0 6.4px 14.4px 0 rgba(0, 0, 0, 0.132), 0 1.2px 3.6px 0 rgba(0, 0, 0, 0.108)",e.depth64="0 25.6px 57.6px 0 rgba(0, 0, 0, 0.22), 0 4.8px 14.4px 0 rgba(0, 0, 0, 0.18)"})(Xf||(Xf={}));var vx={elevation4:Xf.depth4,elevation8:Xf.depth8,elevation16:Xf.depth16,elevation64:Xf.depth64,roundedCorner2:"2px",roundedCorner4:"4px",roundedCorner6:"6px"},oV={s2:"4px",s1:"8px",m:"16px",l1:"20px",l2:"32px"},vn="cubic-bezier(.1,.9,.2,1)",Ri="cubic-bezier(.1,.25,.75,.9)",_m="0.167s",bx="0.267s",sn="0.367s",yx="0.467s",Br=Ji({from:{opacity:0},to:{opacity:1}}),Rr=Ji({from:{opacity:1},to:{opacity:0,visibility:"hidden"}}),iV=Fu(-10),aV=Fu(-20),sV=Fu(-40),lV=Fu(-400),uV=Fu(10),cV=Fu(20),fV=Fu(40),dV=Fu(400),hV=wb(10),pV=wb(20),mV=wb(-10),gV=wb(-20),vV=Iu(10),bV=Iu(20),yV=Iu(40),EV=Iu(400),_V=Iu(-10),TV=Iu(-20),wV=Iu(-40),kV=Iu(-400),SV=kb(-10),xV=kb(-20),CV=kb(10),AV=kb(20),NV=Ji({from:{transform:"scale3d(.98,.98,1)"},to:{transform:"scale3d(1,1,1)"}}),FV=Ji({from:{transform:"scale3d(1,1,1)"},to:{transform:"scale3d(.98,.98,1)"}}),IV=Ji({from:{transform:"scale3d(1.03,1.03,1)"},to:{transform:"scale3d(1,1,1)"}}),BV=Ji({from:{transform:"scale3d(1,1,1)"},to:{transform:"scale3d(1.03,1.03,1)"}}),RV=Ji({from:{transform:"rotateZ(0deg)"},to:{transform:"rotateZ(90deg)"}}),OV=Ji({from:{transform:"rotateZ(0deg)"},to:{transform:"rotateZ(-90deg)"}}),DV={slideRightIn10:Ct(Br+","+iV,sn,vn),slideRightIn20:Ct(Br+","+aV,sn,vn),slideRightIn40:Ct(Br+","+sV,sn,vn),slideRightIn400:Ct(Br+","+lV,sn,vn),slideLeftIn10:Ct(Br+","+uV,sn,vn),slideLeftIn20:Ct(Br+","+cV,sn,vn),slideLeftIn40:Ct(Br+","+fV,sn,vn),slideLeftIn400:Ct(Br+","+dV,sn,vn),slideUpIn10:Ct(Br+","+hV,sn,vn),slideUpIn20:Ct(Br+","+pV,sn,vn),slideDownIn10:Ct(Br+","+mV,sn,vn),slideDownIn20:Ct(Br+","+gV,sn,vn),slideRightOut10:Ct(Rr+","+vV,sn,vn),slideRightOut20:Ct(Rr+","+bV,sn,vn),slideRightOut40:Ct(Rr+","+yV,sn,vn),slideRightOut400:Ct(Rr+","+EV,sn,vn),slideLeftOut10:Ct(Rr+","+_V,sn,vn),slideLeftOut20:Ct(Rr+","+TV,sn,vn),slideLeftOut40:Ct(Rr+","+wV,sn,vn),slideLeftOut400:Ct(Rr+","+kV,sn,vn),slideUpOut10:Ct(Rr+","+SV,sn,vn),slideUpOut20:Ct(Rr+","+xV,sn,vn),slideDownOut10:Ct(Rr+","+CV,sn,vn),slideDownOut20:Ct(Rr+","+AV,sn,vn),scaleUpIn100:Ct(Br+","+NV,sn,vn),scaleDownIn100:Ct(Br+","+IV,sn,vn),scaleUpOut103:Ct(Rr+","+BV,_m,Ri),scaleDownOut98:Ct(Rr+","+FV,_m,Ri),fadeIn100:Ct(Br,_m,Ri),fadeIn200:Ct(Br,bx,Ri),fadeIn400:Ct(Br,sn,Ri),fadeIn500:Ct(Br,yx,Ri),fadeOut100:Ct(Rr,_m,Ri),fadeOut200:Ct(Rr,bx,Ri),fadeOut400:Ct(Rr,sn,Ri),fadeOut500:Ct(Rr,yx,Ri),rotate90deg:Ct(RV,"0.1s",Ri),rotateN90deg:Ct(OV,"0.1s",Ri)};function Ct(e,t,n){return{animationName:e,animationDuration:t,animationTimingFunction:n,animationFillMode:"both"}}function Fu(e){return Ji({from:{transform:"translate3d("+e+"px,0,0)",pointerEvents:"none"},to:{transform:"translate3d(0,0,0)",pointerEvents:"auto"}})}function wb(e){return Ji({from:{transform:"translate3d(0,"+e+"px,0)",pointerEvents:"none"},to:{transform:"translate3d(0,0,0)",pointerEvents:"auto"}})}function Iu(e){return Ji({from:{transform:"translate3d(0,0,0)"},to:{transform:"translate3d("+e+"px,0,0)"}})}function kb(e){return Ji({from:{transform:"translate3d(0,0,0)"},to:{transform:"translate3d(0,"+e+"px,0)"}})}var zn;(function(e){e.Arabic="Segoe UI Web (Arabic)",e.Cyrillic="Segoe UI Web (Cyrillic)",e.EastEuropean="Segoe UI Web (East European)",e.Greek="Segoe UI Web (Greek)",e.Hebrew="Segoe UI Web (Hebrew)",e.Thai="Leelawadee UI Web",e.Vietnamese="Segoe UI Web (Vietnamese)",e.WestEuropean="Segoe UI Web (West European)",e.Selawik="Selawik Web",e.Armenian="Segoe UI Web (Armenian)",e.Georgian="Segoe UI Web (Georgian)"})(zn||(zn={}));var rn;(function(e){e.Arabic="'"+zn.Arabic+"'",e.ChineseSimplified="'Microsoft Yahei UI', Verdana, Simsun",e.ChineseTraditional="'Microsoft Jhenghei UI', Pmingliu",e.Cyrillic="'"+zn.Cyrillic+"'",e.EastEuropean="'"+zn.EastEuropean+"'",e.Greek="'"+zn.Greek+"'",e.Hebrew="'"+zn.Hebrew+"'",e.Hindi="'Nirmala UI'",e.Japanese="'Yu Gothic UI', 'Meiryo UI', Meiryo, 'MS Pgothic', Osaka",e.Korean="'Malgun Gothic', Gulim",e.Selawik="'"+zn.Selawik+"'",e.Thai="'Leelawadee UI Web', 'Kmer UI'",e.Vietnamese="'"+zn.Vietnamese+"'",e.WestEuropean="'"+zn.WestEuropean+"'",e.Armenian="'"+zn.Armenian+"'",e.Georgian="'"+zn.Georgian+"'"})(rn||(rn={}));var So;(function(e){e.size10="10px",e.size12="12px",e.size14="14px",e.size16="16px",e.size18="18px",e.size20="20px",e.size24="24px",e.size28="28px",e.size32="32px",e.size42="42px",e.size68="68px",e.mini="10px",e.xSmall="10px",e.small="12px",e.smallPlus="12px",e.medium="14px",e.mediumPlus="16px",e.icon="16px",e.large="18px",e.xLarge="20px",e.xLargePlus="24px",e.xxLarge="28px",e.xxLargePlus="32px",e.superLarge="42px",e.mega="68px"})(So||(So={}));var Rn;(function(e){e.light=100,e.semilight=300,e.regular=400,e.semibold=600,e.bold=700})(Rn||(Rn={}));var Kl;(function(e){e.xSmall="10px",e.small="12px",e.medium="16px",e.large="20px"})(Kl||(Kl={}));var PV="'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', 'Helvetica Neue', sans-serif",MV="'Segoe UI', '"+zn.WestEuropean+"'",a2={ar:rn.Arabic,bg:rn.Cyrillic,cs:rn.EastEuropean,el:rn.Greek,et:rn.EastEuropean,he:rn.Hebrew,hi:rn.Hindi,hr:rn.EastEuropean,hu:rn.EastEuropean,ja:rn.Japanese,kk:rn.EastEuropean,ko:rn.Korean,lt:rn.EastEuropean,lv:rn.EastEuropean,pl:rn.EastEuropean,ru:rn.Cyrillic,sk:rn.EastEuropean,"sr-latn":rn.EastEuropean,th:rn.Thai,tr:rn.EastEuropean,uk:rn.Cyrillic,vi:rn.Vietnamese,"zh-hans":rn.ChineseSimplified,"zh-hant":rn.ChineseTraditional,hy:rn.Armenian,ka:rn.Georgian};function LV(e){return e+", "+PV}function jV(e){for(var t in a2)if(a2.hasOwnProperty(t)&&e&&t.indexOf(e)===0)return a2[t];return MV}function fi(e,t,n){return{fontFamily:n,MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontSize:e,fontWeight:t}}function zV(e){var t=jV(e),n=LV(t),r={tiny:fi(So.mini,Rn.regular,n),xSmall:fi(So.xSmall,Rn.regular,n),small:fi(So.small,Rn.regular,n),smallPlus:fi(So.smallPlus,Rn.regular,n),medium:fi(So.medium,Rn.regular,n),mediumPlus:fi(So.mediumPlus,Rn.regular,n),large:fi(So.large,Rn.regular,n),xLarge:fi(So.xLarge,Rn.semibold,n),xLargePlus:fi(So.xLargePlus,Rn.semibold,n),xxLarge:fi(So.xxLarge,Rn.semibold,n),xxLargePlus:fi(So.xxLargePlus,Rn.semibold,n),superLarge:fi(So.superLarge,Rn.semibold,n),mega:fi(So.mega,Rn.semibold,n)};return r}var HV="https://static2.sharepointonline.com/files/fabric/assets",UV=zV(qK());function mc(e,t,n,r){e="'"+e+"'";var o=r!==void 0?"local('"+r+"'),":"";SF({fontFamily:e,src:o+("url('"+t+".woff2') format('woff2'),")+("url('"+t+".woff') format('woff')"),fontWeight:n,fontStyle:"normal",fontDisplay:"swap"})}function fa(e,t,n,r,o){r===void 0&&(r="segoeui");var i=e+"/"+n+"/"+r;mc(t,i+"-light",Rn.light,o&&o+" Light"),mc(t,i+"-semilight",Rn.semilight,o&&o+" SemiLight"),mc(t,i+"-regular",Rn.regular,o),mc(t,i+"-semibold",Rn.semibold,o&&o+" SemiBold"),mc(t,i+"-bold",Rn.bold,o&&o+" Bold")}function qV(e){if(e){var t=e+"/fonts";fa(t,zn.Thai,"leelawadeeui-thai","leelawadeeui"),fa(t,zn.Arabic,"segoeui-arabic"),fa(t,zn.Cyrillic,"segoeui-cyrillic"),fa(t,zn.EastEuropean,"segoeui-easteuropean"),fa(t,zn.Greek,"segoeui-greek"),fa(t,zn.Hebrew,"segoeui-hebrew"),fa(t,zn.Vietnamese,"segoeui-vietnamese"),fa(t,zn.WestEuropean,"segoeui-westeuropean","segoeui","Segoe UI"),fa(t,rn.Selawik,"selawik","selawik"),fa(t,zn.Armenian,"segoeui-armenian"),fa(t,zn.Georgian,"segoeui-georgian"),mc("Leelawadee UI Web",t+"/leelawadeeui-thai/leelawadeeui-semilight",Rn.light),mc("Leelawadee UI Web",t+"/leelawadeeui-thai/leelawadeeui-bold",Rn.semibold)}}function $V(){var e,t,n=(e=ur())===null||e===void 0?void 0:e.FabricConfig;return(t=n==null?void 0:n.fontBaseUrl)!==null&&t!==void 0?t:HV}qV($V());function Sb(e,t){e===void 0&&(e={}),t===void 0&&(t=!1);var n=!!e.isInverted,r={palette:gx,effects:vx,fonts:UV,spacing:oV,isInverted:n,disableGlobalClassNames:!1,semanticColors:tV(gx,vx,void 0,n,t),rtl:void 0};return rV(r,e)}var Ao="@media screen and (-ms-high-contrast: active), (forced-colors: active)",WV=640,qF=WV-1;function $F(e,t){var n=typeof e=="number"?" and (min-width: "+e+"px)":"",r=typeof t=="number"?" and (max-width: "+t+"px)":"";return"@media only screen"+n+r}function WF(){return{forcedColorAdjust:"none",MsHighContrastAdjust:"none"}}var Dd;(function(e){e.Nav=1,e.ScrollablePane=1,e.FocusStyle=1,e.Coachmark=1e3,e.Layer=1e6,e.KeytipLayer=1000001})(Dd||(Dd={}));function Pd(e,t,n,r,o,i,a){return typeof t=="number"||!t?Ex(e,{inset:t,position:n,highContrastStyle:r,borderColor:o,outlineColor:i,isFocusedOnly:a}):Ex(e,t)}function Ex(e,t){var n,r;t===void 0&&(t={});var o=t.inset,i=o===void 0?0:o,a=t.width,s=a===void 0?1:a,l=t.position,u=l===void 0?"relative":l,d=t.highContrastStyle,h=t.borderColor,p=h===void 0?e.palette.white:h,m=t.outlineColor,v=m===void 0?e.palette.neutralSecondary:m,_=t.isFocusedOnly,b=_===void 0?!0:_;return{outline:"transparent",position:u,selectors:(n={"::-moz-focus-inner":{border:"0"}},n["."+Go+" &"+(b?":focus":"")+":after"]={content:'""',position:"absolute",left:i+1,top:i+1,bottom:i+1,right:i+1,border:s+"px solid "+p,outline:s+"px solid "+v,zIndex:Dd.FocusStyle,selectors:(r={},r[Ao]=d,r)},n)}}function GV(){return{selectors:{"&::-moz-focus-inner":{border:0},"&":{outline:"transparent"}}}}var GF={position:"absolute",width:1,height:1,margin:-1,padding:0,border:0,overflow:"hidden",whiteSpace:"nowrap"},KV=Cr(function(e,t){var n=Qi.getInstance();return t?Object.keys(e).reduce(function(r,o){return r[o]=n.getClassName(e[o]),r},{}):e});function hs(e,t,n){return KV(e,n!==void 0?n:t.disableGlobalClassNames)}var lv=globalThis&&globalThis.__assign||function(){return lv=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++){t=arguments[n];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},lv.apply(this,arguments)},Ch=typeof window>"u"?global:window,_x=Ch&&Ch.CSPSettings&&Ch.CSPSettings.nonce,gi=VV();function VV(){var e=Ch.__themeState__||{theme:void 0,lastStyleElement:void 0,registeredStyles:[]};return e.runState||(e=lv({},e,{perf:{count:0,duration:0},runState:{flushTimer:0,mode:0,buffer:[]}})),e.registeredThemableStyles||(e=lv({},e,{registeredThemableStyles:[]})),Ch.__themeState__=e,e}function YV(e,t){gi.loadStyles?gi.loadStyles(VF(e).styleString,e):ZV(e)}function KF(e){gi.theme=e,XV()}function QV(e){e===void 0&&(e=3),(e===3||e===2)&&(Tx(gi.registeredStyles),gi.registeredStyles=[]),(e===3||e===1)&&(Tx(gi.registeredThemableStyles),gi.registeredThemableStyles=[])}function Tx(e){e.forEach(function(t){var n=t&&t.styleElement;n&&n.parentElement&&n.parentElement.removeChild(n)})}function XV(){if(gi.theme){for(var e=[],t=0,n=gi.registeredThemableStyles;t<n.length;t++){var r=n[t];e.push(r.themableStyle)}e.length>0&&(QV(1),YV([].concat.apply([],e)))}}function VF(e){var t=gi.theme,n=!1,r=(e||[]).map(function(o){var i=o.theme;if(i){n=!0;var a=t?t[i]:void 0,s=o.defaultValue||"inherit";return t&&!a&&console&&!(i in t)&&typeof DEBUG<"u"&&DEBUG&&console.warn('Theming value not provided for "'+i+'". Falling back to "'+s+'".'),a||s}else return o.rawString});return{styleString:r.join(""),themable:n}}function ZV(e){if(!(typeof document>"u")){var t=document.getElementsByTagName("head")[0],n=document.createElement("style"),r=VF(e),o=r.styleString,i=r.themable;n.setAttribute("data-load-themed-styles","true"),_x&&n.setAttribute("nonce",_x),n.appendChild(document.createTextNode(o)),gi.perf.count++,t.appendChild(n);var a=document.createEvent("HTMLEvents");a.initEvent("styleinsert",!0,!1),a.args={newStyle:n},document.dispatchEvent(a);var s={styleElement:n,themableStyle:e};i?gi.registeredThemableStyles.push(s):gi.registeredStyles.push(s)}}var La=Sb({}),JV=[],_E="theme";function YF(){var e,t,n,r=ur();!((t=r==null?void 0:r.FabricConfig)===null||t===void 0)&&t.legacyTheme?eY(r.FabricConfig.legacyTheme):$i.getSettings([_E]).theme||(!((n=r==null?void 0:r.FabricConfig)===null||n===void 0)&&n.theme&&(La=Sb(r.FabricConfig.theme)),$i.applySettings((e={},e[_E]=La,e)))}YF();function eY(e,t){var n;return t===void 0&&(t=!1),La=Sb(e,t),KF(oe(oe(oe(oe({},La.palette),La.semanticColors),La.effects),tY(La))),$i.applySettings((n={},n[_E]=La,n)),JV.forEach(function(r){try{r(La)}catch{}}),La}function tY(e){for(var t={},n=0,r=Object.keys(e.fonts);n<r.length;n++)for(var o=r[n],i=e.fonts[o],a=0,s=Object.keys(i);a<s.length;a++){var l=s[a],u=o+l.charAt(0).toUpperCase()+l.slice(1),d=i[l];l==="fontSize"&&typeof d=="number"&&(d=d+"px"),t[u]=d}return t}var bc=DG(DV);yb("@fluentui/style-utilities","8.6.0");YF();var hr={topLeftEdge:0,topCenter:1,topRightEdge:2,topAutoEdge:3,bottomLeftEdge:4,bottomCenter:5,bottomRightEdge:6,bottomAutoEdge:7,leftTopEdge:8,leftCenter:9,leftBottomEdge:10,rightTopEdge:11,rightCenter:12,rightBottomEdge:13},Je;(function(e){e[e.top=1]="top",e[e.bottom=-1]="bottom",e[e.left=2]="left",e[e.right=-2]="right"})(Je||(Je={}));var wx;(function(e){e[e.top=0]="top",e[e.bottom=1]="bottom",e[e.start=2]="start",e[e.end=3]="end"})(wx||(wx={}));var oo;function Ho(e,t,n){return{targetEdge:e,alignmentEdge:t,isAuto:n}}var kx=(oo={},oo[hr.topLeftEdge]=Ho(Je.top,Je.left),oo[hr.topCenter]=Ho(Je.top),oo[hr.topRightEdge]=Ho(Je.top,Je.right),oo[hr.topAutoEdge]=Ho(Je.top,void 0,!0),oo[hr.bottomLeftEdge]=Ho(Je.bottom,Je.left),oo[hr.bottomCenter]=Ho(Je.bottom),oo[hr.bottomRightEdge]=Ho(Je.bottom,Je.right),oo[hr.bottomAutoEdge]=Ho(Je.bottom,void 0,!0),oo[hr.leftTopEdge]=Ho(Je.left,Je.top),oo[hr.leftCenter]=Ho(Je.left),oo[hr.leftBottomEdge]=Ho(Je.left,Je.bottom),oo[hr.rightTopEdge]=Ho(Je.right,Je.top),oo[hr.rightCenter]=Ho(Je.right),oo[hr.rightBottomEdge]=Ho(Je.right,Je.bottom),oo);function x4(e,t){return!(e.top<t.top||e.bottom>t.bottom||e.left<t.left||e.right>t.right)}function uv(e,t){var n=[];return e.top<t.top&&n.push(Je.top),e.bottom>t.bottom&&n.push(Je.bottom),e.left<t.left&&n.push(Je.left),e.right>t.right&&n.push(Je.right),n}function po(e,t){return e[Je[t]]}function Sx(e,t,n){return e[Je[t]]=n,e}function a0(e,t){var n=Xd(t);return(po(e,n.positiveEdge)+po(e,n.negativeEdge))/2}function xb(e,t){return e>0?t:t*-1}function TE(e,t){return xb(e,po(t,e))}function Qs(e,t,n){var r=po(e,n)-po(t,n);return xb(n,r)}function Md(e,t,n,r){r===void 0&&(r=!0);var o=po(e,t)-n,i=Sx(e,t,n);return r&&(i=Sx(e,t*-1,po(e,t*-1)-o)),i}function s0(e,t,n,r){return r===void 0&&(r=0),Md(e,n,po(t,n)+xb(n,r))}function nY(e,t,n,r){r===void 0&&(r=0);var o=n*-1,i=xb(o,r);return Md(e,n*-1,po(t,n)+i)}function cv(e,t,n){var r=TE(n,e);return r>TE(n,t)}function rY(e,t){for(var n=uv(e,t),r=0,o=0,i=n;o<i.length;o++){var a=i[o];r+=Math.pow(Qs(e,t,a),2)}return r}function oY(e,t,n,r,o){o===void 0&&(o=0);var i=[Je.left,Je.right,Je.bottom,Je.top];ls()&&(i[0]*=-1,i[1]*=-1);for(var a=e,s=r.targetEdge,l=r.alignmentEdge,u,d=s,h=l,p=0;p<4;p++){if(cv(a,n,s))return{elementRectangle:a,targetEdge:s,alignmentEdge:l};var m=rY(a,n);(!u||m<u)&&(u=m,d=s,h=l),i.splice(i.indexOf(s),1),i.length>0&&(i.indexOf(s*-1)>-1?s=s*-1:(l=s,s=i.slice(-1)[0]),a=fv(e,t,{targetEdge:s,alignmentEdge:l},o))}return a=fv(e,t,{targetEdge:d,alignmentEdge:h},o),{elementRectangle:a,targetEdge:d,alignmentEdge:h}}function iY(e,t,n,r){var o=e.alignmentEdge,i=e.targetEdge,a=e.elementRectangle,s=o*-1,l=fv(a,t,{targetEdge:i,alignmentEdge:s},n,r);return{elementRectangle:l,targetEdge:i,alignmentEdge:s}}function aY(e,t,n,r,o,i,a){o===void 0&&(o=0);var s=r.alignmentEdge,l=r.alignTargetEdge,u={elementRectangle:e,targetEdge:r.targetEdge,alignmentEdge:s};!i&&!a&&(u=oY(e,t,n,r,o));var d=uv(u.elementRectangle,n),h=i?-u.targetEdge:void 0;if(d.length>0)if(l)if(u.alignmentEdge&&d.indexOf(u.alignmentEdge*-1)>-1){var p=iY(u,t,o,a);if(x4(p.elementRectangle,n))return p;u=s2(uv(p.elementRectangle,n),u,n,h)}else u=s2(d,u,n,h);else u=s2(d,u,n,h);return u}function s2(e,t,n,r){for(var o=0,i=e;o<i.length;o++){var a=i[o],s=void 0;if(r&&r===a*-1)s=Md(t.elementRectangle,a,po(n,a),!1),t.forcedInBounds=!0;else{s=s0(t.elementRectangle,n,a);var l=cv(s,n,a*-1);l||(s=Md(s,a*-1,po(n,a*-1),!1),t.forcedInBounds=!0)}t.elementRectangle=s}return t}function QF(e,t,n){var r=Xd(t).positiveEdge,o=a0(e,t),i=o-po(e,r);return Md(e,r,n-i)}function fv(e,t,n,r,o){r===void 0&&(r=0);var i=new ts(e.left,e.right,e.top,e.bottom),a=n.alignmentEdge,s=n.targetEdge,l=o?s:s*-1;if(i=o?s0(i,t,s,r):nY(i,t,s,r),a)i=s0(i,t,a);else{var u=a0(t,s);i=QF(i,l,u)}return i}function Xd(e){return e===Je.top||e===Je.bottom?{positiveEdge:Je.left,negativeEdge:Je.right}:{positiveEdge:Je.top,negativeEdge:Je.bottom}}function XF(e,t,n){return n&&Math.abs(Qs(e,n,t))>Math.abs(Qs(e,n,t*-1))?t*-1:t}function sY(e,t,n){return n!==void 0&&po(e,t)===po(n,t)}function lY(e,t,n,r,o,i,a,s){var l={},u=C4(t),d=i?n:n*-1,h=o||Xd(n).positiveEdge;return(!a||sY(e,TY(h),r))&&(h=XF(e,h,r)),l[Je[d]]=Qs(e,u,d),l[Je[h]]=Qs(e,u,h),s&&(l[Je[d*-1]]=Qs(e,u,d*-1),l[Je[h*-1]]=Qs(e,u,h*-1)),l}function uY(e){return Math.sqrt(e*e*2)}function cY(e,t,n){if(e===void 0&&(e=hr.bottomAutoEdge),n)return{alignmentEdge:n.alignmentEdge,isAuto:n.isAuto,targetEdge:n.targetEdge};var r=oe({},kx[e]);return ls()?(r.alignmentEdge&&r.alignmentEdge%2===0&&(r.alignmentEdge=r.alignmentEdge*-1),t!==void 0?kx[t]:r):r}function fY(e,t,n,r,o){return e.isAuto&&(e.alignmentEdge=ZF(e.targetEdge,t,n)),e.alignTargetEdge=o,e}function ZF(e,t,n){var r=a0(t,e),o=a0(n,e),i=Xd(e),a=i.positiveEdge,s=i.negativeEdge;return r<=o?a:s}function dY(e,t,n,r,o,i,a){var s=fv(e,t,r,o,a);return x4(s,n)?{elementRectangle:s,targetEdge:r.targetEdge,alignmentEdge:r.alignmentEdge}:aY(s,t,n,r,o,i,a)}function hY(e,t,n){var r=e.targetEdge*-1,o=new ts(0,e.elementRectangle.width,0,e.elementRectangle.height),i={},a=XF(e.elementRectangle,e.alignmentEdge?e.alignmentEdge:Xd(r).positiveEdge,n),s=Qs(e.elementRectangle,e.targetRectangle,r),l=s>Math.abs(po(t,r));return i[Je[r]]=po(t,r),i[Je[a]]=Qs(t,o,a),{elementPosition:oe({},i),closestEdge:ZF(e.targetEdge,t,o),targetEdge:r,hideBeak:!l}}function pY(e,t){var n=t.targetRectangle,r=Xd(t.targetEdge),o=r.positiveEdge,i=r.negativeEdge,a=a0(n,t.targetEdge),s=new ts(e/2,t.elementRectangle.width-e/2,e/2,t.elementRectangle.height-e/2),l=new ts(0,e,0,e);return l=Md(l,t.targetEdge*-1,-e/2),l=QF(l,t.targetEdge*-1,a-TE(o,t.elementRectangle)),cv(l,s,o)?cv(l,s,i)||(l=s0(l,s,i)):l=s0(l,s,o),l}function C4(e){var t=e.getBoundingClientRect();return new ts(t.left,t.right,t.top,t.bottom)}function mY(e){return new ts(e.left,e.right,e.top,e.bottom)}function gY(e,t){var n;if(t){if(t.preventDefault){var r=t;n=new ts(r.clientX,r.clientX,r.clientY,r.clientY)}else if(t.getBoundingClientRect)n=C4(t);else{var o=t,i=o.left||o.x,a=o.top||o.y,s=o.right||i,l=o.bottom||a;n=new ts(i,s,a,l)}if(!x4(n,e))for(var u=uv(n,e),d=0,h=u;d<h.length;d++){var p=h[d];n[Je[p]]=e[Je[p]]}}else n=new ts(0,0,0,0);return n}function vY(e,t,n,r){var o=e.gapSpace?e.gapSpace:0,i=gY(n,e.target),a=fY(cY(e.directionalHint,e.directionalHintForRTL,r),i,n,e.coverTarget,e.alignTargetEdge),s=dY(C4(t),i,n,a,o,e.directionalHintFixed,e.coverTarget);return oe(oe({},s),{targetRectangle:i})}function bY(e,t,n,r,o){var i=lY(e.elementRectangle,t,e.targetEdge,n,e.alignmentEdge,r,o,e.forcedInBounds);return{elementPosition:i,targetEdge:e.targetEdge,alignmentEdge:e.alignmentEdge}}function JF(e,t,n,r,o){var i=e.isBeakVisible&&e.beakWidth||0,a=uY(i)/2+(e.gapSpace?e.gapSpace:0),s=e;s.gapSpace=a;var l=e.bounds?mY(e.bounds):new ts(0,window.innerWidth-MG(),0,window.innerHeight),u=vY(s,n,l,r),d=pY(i,u),h=hY(u,d,l);return oe(oe({},bY(u,t,l,e.coverTarget,o)),{beakPosition:h})}function yY(e,t,n,r){return JF(e,t,n,r,!0)}function EY(e,t,n,r){return JF(e,t,n,r)}function _Y(e,t,n,r){return yY(e,t,n,r)}function TY(e){return e*-1}function wY(e,t){var n=void 0;if(t.getWindowSegments&&(n=t.getWindowSegments()),n===void 0||n.length<=1)return{top:0,left:0,right:t.innerWidth,bottom:t.innerHeight,width:t.innerWidth,height:t.innerHeight};var r=0,o=0;if(e!==null&&e.getBoundingClientRect){var i=e.getBoundingClientRect();r=(i.left+i.right)/2,o=(i.top+i.bottom)/2}else e!==null&&(r=e.left||e.x,o=e.top||e.y);for(var a={top:0,left:0,right:0,bottom:0,width:0,height:0},s=0,l=n;s<l.length;s++){var u=l[s];r&&u.left<=r&&u.right>=r&&o&&u.top<=o&&u.bottom>=o&&(a={top:u.top,left:u.left,right:u.right,bottom:u.bottom,width:u.width,height:u.height})}return a}function kY(e,t){return wY(e,t)}function A4(e){var t=T.useRef();return t.current===void 0&&(t.current={value:typeof e=="function"?e():e}),t.current.value}function Zd(){var e=A4(function(){return new _b});return T.useEffect(function(){return function(){return e.dispose()}},[e]),e}function eI(e,t){var n=T.useRef(t);return n.current||(n.current=cu(e)),n.current}function G0(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=T.useCallback(function(r){n.current=r;for(var o=0,i=e;o<i.length;o++){var a=i[o];typeof a=="function"?a(r):a&&(a.current=r)}},Yi([],e));return n}function l0(e,t,n,r){var o=T.useRef(n);o.current=n,T.useEffect(function(){var i=e&&"current"in e?e.current:e;if(i){var a=zf(i,t,function(s){return o.current(s)},r);return a}},[e,t,r])}function tI(e){var t=T.useRef();return T.useEffect(function(){t.current=e}),t.current}var nI=T.createContext({window:typeof window=="object"?window:void 0}),N4=function(){return T.useContext(nI).window},SY=function(){var e;return(e=T.useContext(nI).window)===null||e===void 0?void 0:e.document};function rI(e,t){var n=T.useRef(),r=T.useRef(null),o=N4();if(!e||e!==n.current||typeof e=="string"){var i=t==null?void 0:t.current;if(e)if(typeof e=="string"){var a=ss(i);r.current=a?a.querySelector(e):null}else"stopPropagation"in e||"getBoundingClientRect"in e?r.current=e:"current"in e?r.current=e.current:r.current=e;n.current=e}return[r,o]}function xY(e,t){var n=Zd(),r=T.useState(!1),o=r[0],i=r[1];return T.useEffect(function(){return n.requestAnimationFrame(function(){var a;if(!(e.style&&e.style.overflowY)){var s=!1;if(t&&t.current&&(!((a=t.current)===null||a===void 0)&&a.firstElementChild)){var l=t.current.clientHeight,u=t.current.firstElementChild.clientHeight;l>0&&u>l&&(s=u-l>1)}o!==s&&i(s)}}),function(){return n.dispose()}}),o}function CY(e){var t=e.originalElement,n=e.containsFocus;t&&n&&t!==ur()&&setTimeout(function(){var r;(r=t.focus)===null||r===void 0||r.call(t)},0)}function AY(e,t){var n=e.onRestoreFocus,r=n===void 0?CY:n,o=T.useRef(),i=T.useRef(!1);T.useEffect(function(){return o.current=ss().activeElement,aK(t.current)&&(i.current=!0),function(){var a;r==null||r({originalElement:o.current,containsFocus:i.current,documentContainsFocus:((a=ss())===null||a===void 0?void 0:a.hasFocus())||!1}),o.current=void 0}},[]),l0(t,"focus",T.useCallback(function(){i.current=!0},[]),!0),l0(t,"blur",T.useCallback(function(a){t.current&&a.relatedTarget&&!t.current.contains(a.relatedTarget)&&(i.current=!1)},[]),!0)}function NY(e,t){var n=String(e["aria-modal"]).toLowerCase()==="true"&&e.enableAriaHiddenSiblings;T.useEffect(function(){if(n&&t.current){var r=WK(t.current);return r}},[t,n])}var oI=T.forwardRef(function(e,t){var n=S4({shouldRestoreFocus:!0,enableAriaHiddenSiblings:!0},e),r=T.useRef(),o=G0(r,t);NY(n,r),AY(n,r);var i=n.role,a=n.className,s=n.ariaLabel,l=n.ariaLabelledBy,u=n.ariaDescribedBy,d=n.style,h=n.children,p=n.onDismiss,m=xY(n,r),v=T.useCallback(function(b){switch(b.which){case qt.escape:p&&(p(b),b.preventDefault(),b.stopPropagation());break}},[p]),_=N4();return l0(_,"keydown",v),T.createElement("div",oe({ref:o},Zr(n,W0),{className:a,role:i,"aria-label":s,"aria-labelledby":l,"aria-describedby":u,onKeyDown:v,style:oe({overflowY:m?"scroll":void 0,outline:"none"},d)}),h)});oI.displayName="Popup";var yf,FY="CalloutContentBase",IY=(yf={},yf[Je.top]=bc.slideUpIn10,yf[Je.bottom]=bc.slideDownIn10,yf[Je.left]=bc.slideLeftIn10,yf[Je.right]=bc.slideRightIn10,yf),xx={top:0,left:0},BY={opacity:0,filter:"opacity(0)",pointerEvents:"none"},RY=["role","aria-roledescription"],iI={preventDismissOnLostFocus:!1,preventDismissOnScroll:!1,preventDismissOnResize:!1,isBeakVisible:!0,beakWidth:16,gapSpace:0,minPagePadding:8,directionalHint:hr.bottomAutoEdge},OY=ml({disableCaching:!0});function DY(e,t,n){var r=e.bounds,o=e.minPagePadding,i=o===void 0?iI.minPagePadding:o,a=e.target,s=T.useState(!1),l=s[0],u=s[1],d=T.useRef(),h=T.useCallback(function(){if(!d.current||l){var m=typeof r=="function"?n?r(a,n):void 0:r;!m&&n&&(m=kY(t.current,n),m={top:m.top+i,left:m.left+i,right:m.right-i,bottom:m.bottom-i,width:m.width-i*2,height:m.height-i*2}),d.current=m,l&&u(!1)}return d.current},[r,i,a,t,n,l]),p=Zd();return l0(n,"resize",p.debounce(function(){u(!0)},500,{leading:!0})),h}function PY(e,t,n){var r,o=e.calloutMaxHeight,i=e.finalHeight,a=e.directionalHint,s=e.directionalHintFixed,l=e.hidden,u=T.useState(),d=u[0],h=u[1],p=(r=n==null?void 0:n.elementPosition)!==null&&r!==void 0?r:{},m=p.top,v=p.bottom;return T.useEffect(function(){var _,b=(_=t())!==null&&_!==void 0?_:{},E=b.top,w=b.bottom;!o&&!l?typeof m=="number"&&w?h(w-m):typeof v=="number"&&typeof E=="number"&&w&&h(w-E-v):h(o||void 0)},[v,o,i,a,s,t,l,n,m]),d}function MY(e,t,n,r,o){var i=T.useState(),a=i[0],s=i[1],l=T.useRef(0),u=T.useRef(),d=Zd(),h=e.hidden,p=e.target,m=e.finalHeight,v=e.calloutMaxHeight,_=e.onPositioned,b=e.directionalHint;return T.useEffect(function(){if(h)s(void 0),l.current=0;else{var E=d.requestAnimationFrame(function(){var w,k;if(t.current&&n){var y=oe(oe({},e),{target:r.current,bounds:o()}),F=n.cloneNode(!0);F.style.maxHeight=v?""+v:"",F.style.visibility="hidden",(w=n.parentElement)===null||w===void 0||w.appendChild(F);var C=u.current===p?a:void 0,A=m?_Y(y,t.current,F,C):EY(y,t.current,F,C);(k=n.parentElement)===null||k===void 0||k.removeChild(F),!a&&A||a&&A&&!HY(a,A)&&l.current<5?(l.current++,s(A)):l.current>0&&(l.current=0,_==null||_(a))}},n);return u.current=p,function(){d.cancelAnimationFrame(E),u.current=void 0}}},[h,b,d,n,v,t,r,m,o,_,a,e,p]),a}function LY(e,t,n){var r=e.hidden,o=e.setInitialFocus,i=Zd(),a=!!t;T.useEffect(function(){if(!r&&o&&a&&n){var s=i.requestAnimationFrame(function(){return iK(n)},n);return function(){return i.cancelAnimationFrame(s)}}},[r,a,i,n,o])}function jY(e,t,n,r,o){var i=e.hidden,a=e.onDismiss,s=e.preventDismissOnScroll,l=e.preventDismissOnResize,u=e.preventDismissOnLostFocus,d=e.dismissOnTargetClick,h=e.shouldDismissOnWindowFocus,p=e.preventDismissOnEvent,m=T.useRef(!1),v=Zd(),_=A4([function(){m.current=!0},function(){m.current=!1}]),b=!!t;return T.useEffect(function(){var E=function(A){b&&!s&&y(A)},w=function(A){!l&&!(p&&p(A))&&(a==null||a(A))},k=function(A){u||y(A)},y=function(A){var P=A.composedPath?A.composedPath():[],I=P.length>0?P[0]:A.target,j=n.current&&!bE(n.current,I);if(j&&m.current){m.current=!1;return}if(!r.current&&j||A.target!==o&&j&&(!r.current||"stopPropagation"in r.current||d||I!==r.current&&!bE(r.current,I))){if(p&&p(A))return;a==null||a(A)}},F=function(A){h&&(p&&!p(A)||!p&&!u)&&!(o!=null&&o.document.hasFocus())&&A.relatedTarget===null&&(a==null||a(A))},C=new Promise(function(A){v.setTimeout(function(){if(!i&&o){var P=[zf(o,"scroll",E,!0),zf(o,"resize",w,!0),zf(o.document.documentElement,"focus",k,!0),zf(o.document.documentElement,"click",k,!0),zf(o,"blur",F,!0)];A(function(){P.forEach(function(I){return I()})})}},0)});return function(){C.then(function(A){return A()})}},[i,v,n,r,o,a,h,d,u,l,s,b,p]),_}var aI=T.memo(T.forwardRef(function(e,t){var n=S4(iI,e),r=n.styles,o=n.style,i=n.ariaLabel,a=n.ariaDescribedBy,s=n.ariaLabelledBy,l=n.className,u=n.isBeakVisible,d=n.children,h=n.beakWidth,p=n.calloutWidth,m=n.calloutMaxWidth,v=n.calloutMinWidth,_=n.doNotLayer,b=n.finalHeight,E=n.hideOverflow,w=E===void 0?!!b:E,k=n.backgroundColor,y=n.calloutMaxHeight,F=n.onScroll,C=n.shouldRestoreFocus,A=C===void 0?!0:C,P=n.target,I=n.hidden,j=n.onLayerMounted,H=T.useRef(null),K=T.useState(null),U=K[0],pe=K[1],se=T.useCallback(function(tr){pe(tr)},[]),J=G0(H,t),$=rI(n.target,{current:U}),_e=$[0],ve=$[1],fe=DY(n,_e,ve),R=MY(n,H,U,_e,fe),L=PY(n,fe,R),Ae=jY(n,R,H,_e,ve),Ue=Ae[0],Ve=Ae[1],Le=(R==null?void 0:R.elementPosition.top)&&(R==null?void 0:R.elementPosition.bottom),st=oe(oe({},R==null?void 0:R.elementPosition),{maxHeight:L});if(Le&&(st.bottom=void 0),LY(n,R,U),T.useEffect(function(){I||j==null||j()},[I]),!ve)return null;var We=w,rt=u&&!!P,Zt=OY(r,{theme:n.theme,className:l,overflowYHidden:We,calloutWidth:p,positions:R,beakWidth:h,backgroundColor:k,calloutMaxWidth:m,calloutMinWidth:v,doNotLayer:_}),qn=oe(oe({maxHeight:y||"100%"},o),We&&{overflowY:"hidden"}),er=n.hidden?{visibility:"hidden"}:void 0;return T.createElement("div",{ref:J,className:Zt.container,style:er},T.createElement("div",oe({},Zr(n,W0,RY),{className:Ys(Zt.root,R&&R.targetEdge&&IY[R.targetEdge]),style:R?oe({},st):BY,tabIndex:-1,ref:se}),rt&&T.createElement("div",{className:Zt.beak,style:zY(R)}),rt&&T.createElement("div",{className:Zt.beakCurtain}),T.createElement(oI,{role:n.role,"aria-roledescription":n["aria-roledescription"],ariaDescribedBy:a,ariaLabel:i,ariaLabelledBy:s,className:Zt.calloutMain,onDismiss:n.onDismiss,onMouseDown:Ue,onMouseUp:Ve,onRestoreFocus:n.onRestoreFocus,onScroll:F,shouldRestoreFocus:A,style:qn},d)))}),function(e,t){return!t.shouldUpdateWhenHidden&&e.hidden&&t.hidden?!0:T4(e,t)});function zY(e){var t,n,r=oe(oe({},(t=e==null?void 0:e.beakPosition)===null||t===void 0?void 0:t.elementPosition),{display:!((n=e==null?void 0:e.beakPosition)===null||n===void 0)&&n.hideBeak?"none":void 0});return!r.top&&!r.bottom&&!r.left&&!r.right&&(r.left=xx.left,r.top=xx.top),r}function HY(e,t){return Cx(e.elementPosition,t.elementPosition)&&Cx(e.beakPosition.elementPosition,t.beakPosition.elementPosition)}function Cx(e,t){for(var n in t)if(t.hasOwnProperty(n)){var r=e[n],o=t[n];if(r!==void 0&&o!==void 0){if(r.toFixed(2)!==o.toFixed(2))return!1}else return!1}return!0}aI.displayName=FY;function UY(e){return{height:e,width:e}}var qY={container:"ms-Callout-container",root:"ms-Callout",beak:"ms-Callout-beak",beakCurtain:"ms-Callout-beakCurtain",calloutMain:"ms-Callout-main"},$Y=function(e){var t,n=e.theme,r=e.className,o=e.overflowYHidden,i=e.calloutWidth,a=e.beakWidth,s=e.backgroundColor,l=e.calloutMaxWidth,u=e.calloutMinWidth,d=e.doNotLayer,h=hs(qY,n),p=n.semanticColors,m=n.effects;return{container:[h.container,{position:"relative"}],root:[h.root,n.fonts.medium,{position:"absolute",display:"flex",zIndex:d?Dd.Layer:void 0,boxSizing:"border-box",borderRadius:m.roundedCorner2,boxShadow:m.elevation16,selectors:(t={},t[Ao]={borderWidth:1,borderStyle:"solid",borderColor:"WindowText"},t)},GV(),r,!!i&&{width:i},!!l&&{maxWidth:l},!!u&&{minWidth:u}],beak:[h.beak,{position:"absolute",backgroundColor:p.menuBackground,boxShadow:"inherit",border:"inherit",boxSizing:"border-box",transform:"rotate(45deg)"},UY(a),s&&{backgroundColor:s}],beakCurtain:[h.beakCurtain,{position:"absolute",top:0,right:0,bottom:0,left:0,backgroundColor:p.menuBackground,borderRadius:m.roundedCorner2}],calloutMain:[h.calloutMain,{backgroundColor:p.menuBackground,overflowX:"hidden",overflowY:"auto",position:"relative",width:"100%",borderRadius:m.roundedCorner2},o&&{overflowY:"hidden"},s&&{backgroundColor:s}]}},WY=gl(aI,$Y,void 0,{scope:"CalloutContent"}),sI={exports:{}},ea={},lI={exports:{}},uI={};/** @license React v0.20.2 * scheduler.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */(function(e){var t,n,r,o;if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var a=Date,s=a.now();e.unstable_now=function(){return a.now()-s}}if(typeof window>"u"||typeof MessageChannel!="function"){var l=null,u=null,d=function(){if(l!==null)try{var R=e.unstable_now();l(!0,R),l=null}catch(L){throw setTimeout(d,0),L}};t=function(R){l!==null?setTimeout(t,0,R):(l=R,setTimeout(d,0))},n=function(R,L){u=setTimeout(R,L)},r=function(){clearTimeout(u)},e.unstable_shouldYield=function(){return!1},o=e.unstable_forceFrameRate=function(){}}else{var h=window.setTimeout,p=window.clearTimeout;if(typeof console<"u"){var m=window.cancelAnimationFrame;typeof window.requestAnimationFrame!="function"&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),typeof m!="function"&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var v=!1,_=null,b=-1,E=5,w=0;e.unstable_shouldYield=function(){return e.unstable_now()>=w},o=function(){},e.unstable_forceFrameRate=function(R){0>R||125<R?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):E=0<R?Math.floor(1e3/R):5};var k=new MessageChannel,y=k.port2;k.port1.onmessage=function(){if(_!==null){var R=e.unstable_now();w=R+E;try{_(!0,R)?y.postMessage(null):(v=!1,_=null)}catch(L){throw y.postMessage(null),L}}else v=!1},t=function(R){_=R,v||(v=!0,y.postMessage(null))},n=function(R,L){b=h(function(){R(e.unstable_now())},L)},r=function(){p(b),b=-1}}function F(R,L){var Ae=R.length;R.push(L);e:for(;;){var Ue=Ae-1>>>1,Ve=R[Ue];if(Ve!==void 0&&0<P(Ve,L))R[Ue]=L,R[Ae]=Ve,Ae=Ue;else break e}}function C(R){return R=R[0],R===void 0?null:R}function A(R){var L=R[0];if(L!==void 0){var Ae=R.pop();if(Ae!==L){R[0]=Ae;e:for(var Ue=0,Ve=R.length;Ue<Ve;){var Le=2*(Ue+1)-1,st=R[Le],We=Le+1,rt=R[We];if(st!==void 0&&0>P(st,Ae))rt!==void 0&&0>P(rt,st)?(R[Ue]=rt,R[We]=Ae,Ue=We):(R[Ue]=st,R[Le]=Ae,Ue=Le);else if(rt!==void 0&&0>P(rt,Ae))R[Ue]=rt,R[We]=Ae,Ue=We;else break e}}return L}return null}function P(R,L){var Ae=R.sortIndex-L.sortIndex;return Ae!==0?Ae:R.id-L.id}var I=[],j=[],H=1,K=null,U=3,pe=!1,se=!1,J=!1;function $(R){for(var L=C(j);L!==null;){if(L.callback===null)A(j);else if(L.startTime<=R)A(j),L.sortIndex=L.expirationTime,F(I,L);else break;L=C(j)}}function _e(R){if(J=!1,$(R),!se)if(C(I)!==null)se=!0,t(ve);else{var L=C(j);L!==null&&n(_e,L.startTime-R)}}function ve(R,L){se=!1,J&&(J=!1,r()),pe=!0;var Ae=U;try{for($(L),K=C(I);K!==null&&(!(K.expirationTime>L)||R&&!e.unstable_shouldYield());){var Ue=K.callback;if(typeof Ue=="function"){K.callback=null,U=K.priorityLevel;var Ve=Ue(K.expirationTime<=L);L=e.unstable_now(),typeof Ve=="function"?K.callback=Ve:K===C(I)&&A(I),$(L)}else A(I);K=C(I)}if(K!==null)var Le=!0;else{var st=C(j);st!==null&&n(_e,st.startTime-L),Le=!1}return Le}finally{K=null,U=Ae,pe=!1}}var fe=o;e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(R){R.callback=null},e.unstable_continueExecution=function(){se||pe||(se=!0,t(ve))},e.unstable_getCurrentPriorityLevel=function(){return U},e.unstable_getFirstCallbackNode=function(){return C(I)},e.unstable_next=function(R){switch(U){case 1:case 2:case 3:var L=3;break;default:L=U}var Ae=U;U=L;try{return R()}finally{U=Ae}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=fe,e.unstable_runWithPriority=function(R,L){switch(R){case 1:case 2:case 3:case 4:case 5:break;default:R=3}var Ae=U;U=R;try{return L()}finally{U=Ae}},e.unstable_scheduleCallback=function(R,L,Ae){var Ue=e.unstable_now();switch(typeof Ae=="object"&&Ae!==null?(Ae=Ae.delay,Ae=typeof Ae=="number"&&0<Ae?Ue+Ae:Ue):Ae=Ue,R){case 1:var Ve=-1;break;case 2:Ve=250;break;case 5:Ve=1073741823;break;case 4:Ve=1e4;break;default:Ve=5e3}return Ve=Ae+Ve,R={id:H++,callback:L,priorityLevel:R,startTime:Ae,expirationTime:Ve,sortIndex:-1},Ae>Ue?(R.sortIndex=Ae,F(j,R),C(I)===null&&R===C(j)&&(J?r():J=!0,n(_e,Ae-Ue))):(R.sortIndex=Ve,F(I,R),se||pe||(se=!0,t(ve))),R},e.unstable_wrapCallback=function(R){var L=U;return function(){var Ae=U;U=L;try{return R.apply(this,arguments)}finally{U=Ae}}}})(uI);lI.exports=uI;var wE=lI.exports;/** @license React v17.0.2 * react-dom.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Cb=T,Pn=ZN,Lr=wE;function Ie(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}if(!Cb)throw Error(Ie(227));var cI=new Set,u0={};function zc(e,t){Ld(e,t),Ld(e+"Capture",t)}function Ld(e,t){for(u0[e]=t,e=0;e<t.length;e++)cI.add(t[e])}var al=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),GY=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,Ax=Object.prototype.hasOwnProperty,Nx={},Fx={};function KY(e){return Ax.call(Fx,e)?!0:Ax.call(Nx,e)?!1:GY.test(e)?Fx[e]=!0:(Nx[e]=!0,!1)}function VY(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function YY(e,t,n,r){if(t===null||typeof t>"u"||VY(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Ro(e,t,n,r,o,i,a){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=o,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=a}var Jr={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Jr[e]=new Ro(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Jr[t]=new Ro(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Jr[e]=new Ro(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Jr[e]=new Ro(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Jr[e]=new Ro(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Jr[e]=new Ro(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Jr[e]=new Ro(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Jr[e]=new Ro(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Jr[e]=new Ro(e,5,!1,e.toLowerCase(),null,!1,!1)});var F4=/[\-:]([a-z])/g;function I4(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(F4,I4);Jr[t]=new Ro(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(F4,I4);Jr[t]=new Ro(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(F4,I4);Jr[t]=new Ro(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Jr[e]=new Ro(e,1,!1,e.toLowerCase(),null,!1,!1)});Jr.xlinkHref=new Ro("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Jr[e]=new Ro(e,1,!1,e.toLowerCase(),null,!0,!0)});function B4(e,t,n,r){var o=Jr.hasOwnProperty(t)?Jr[t]:null,i=o!==null?o.type===0:r?!1:!(!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N");i||(YY(t,n,o,r)&&(n=null),r||o===null?KY(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):o.mustUseProperty?e[o.propertyName]=n===null?o.type===3?!1:"":n:(t=o.attributeName,r=o.attributeNamespace,n===null?e.removeAttribute(t):(o=o.type,n=o===3||o===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var Hc=Cb.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,bh=60103,yc=60106,tu=60107,R4=60108,Ah=60114,O4=60109,D4=60110,Ab=60112,Nh=60113,dv=60120,Nb=60115,P4=60116,M4=60121,L4=60128,fI=60129,j4=60130,kE=60131;if(typeof Symbol=="function"&&Symbol.for){var Or=Symbol.for;bh=Or("react.element"),yc=Or("react.portal"),tu=Or("react.fragment"),R4=Or("react.strict_mode"),Ah=Or("react.profiler"),O4=Or("react.provider"),D4=Or("react.context"),Ab=Or("react.forward_ref"),Nh=Or("react.suspense"),dv=Or("react.suspense_list"),Nb=Or("react.memo"),P4=Or("react.lazy"),M4=Or("react.block"),Or("react.scope"),L4=Or("react.opaque.id"),fI=Or("react.debug_trace_mode"),j4=Or("react.offscreen"),kE=Or("react.legacy_hidden")}var Ix=typeof Symbol=="function"&&Symbol.iterator;function H1(e){return e===null||typeof e!="object"?null:(e=Ix&&e[Ix]||e["@@iterator"],typeof e=="function"?e:null)}var l2;function yh(e){if(l2===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);l2=t&&t[1]||""}return` `+l2+e}var u2=!1;function Tm(e,t){if(!e||u2)return"";u2=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(l){var r=l}Reflect.construct(e,[],t)}else{try{t.call()}catch(l){r=l}e.call(t.prototype)}else{try{throw Error()}catch(l){r=l}e()}}catch(l){if(l&&r&&typeof l.stack=="string"){for(var o=l.stack.split(` `),i=r.stack.split(` `),a=o.length-1,s=i.length-1;1<=a&&0<=s&&o[a]!==i[s];)s--;for(;1<=a&&0<=s;a--,s--)if(o[a]!==i[s]){if(a!==1||s!==1)do if(a--,s--,0>s||o[a]!==i[s])return` `+o[a].replace(" at new "," at ");while(1<=a&&0<=s);break}}}finally{u2=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?yh(e):""}function QY(e){switch(e.tag){case 5:return yh(e.type);case 16:return yh("Lazy");case 13:return yh("Suspense");case 19:return yh("SuspenseList");case 0:case 2:case 15:return e=Tm(e.type,!1),e;case 11:return e=Tm(e.type.render,!1),e;case 22:return e=Tm(e.type._render,!1),e;case 1:return e=Tm(e.type,!0),e;default:return""}}function hd(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case tu:return"Fragment";case yc:return"Portal";case Ah:return"Profiler";case R4:return"StrictMode";case Nh:return"Suspense";case dv:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case D4:return(e.displayName||"Context")+".Consumer";case O4:return(e._context.displayName||"Context")+".Provider";case Ab:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case Nb:return hd(e.type);case M4:return hd(e._render);case P4:t=e._payload,e=e._init;try{return hd(e(t))}catch{}}return null}function wu(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function dI(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function XY(e){var t=dI(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var o=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(a){r=""+a,i.call(this,a)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(a){r=""+a},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function wm(e){e._valueTracker||(e._valueTracker=XY(e))}function hI(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=dI(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function hv(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function SE(e,t){var n=t.checked;return Pn({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Bx(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=wu(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function pI(e,t){t=t.checked,t!=null&&B4(e,"checked",t,!1)}function xE(e,t){pI(e,t);var n=wu(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?CE(e,t.type,n):t.hasOwnProperty("defaultValue")&&CE(e,t.type,wu(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Rx(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function CE(e,t,n){(t!=="number"||hv(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}function ZY(e){var t="";return Cb.Children.forEach(e,function(n){n!=null&&(t+=n)}),t}function AE(e,t){return e=Pn({children:void 0},t),(t=ZY(t.children))&&(e.children=t),e}function pd(e,t,n,r){if(e=e.options,t){t={};for(var o=0;o<n.length;o++)t["$"+n[o]]=!0;for(n=0;n<e.length;n++)o=t.hasOwnProperty("$"+e[n].value),e[n].selected!==o&&(e[n].selected=o),o&&r&&(e[n].defaultSelected=!0)}else{for(n=""+wu(n),t=null,o=0;o<e.length;o++){if(e[o].value===n){e[o].selected=!0,r&&(e[o].defaultSelected=!0);return}t!==null||e[o].disabled||(t=e[o])}t!==null&&(t.selected=!0)}}function NE(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(Ie(91));return Pn({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Ox(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(Ie(92));if(Array.isArray(n)){if(!(1>=n.length))throw Error(Ie(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:wu(n)}}function mI(e,t){var n=wu(t.value),r=wu(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function Dx(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}var FE={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function gI(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function IE(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?gI(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var km,vI=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,o){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,o)})}:e}(function(e,t){if(e.namespaceURI!==FE.svg||"innerHTML"in e)e.innerHTML=t;else{for(km=km||document.createElement("div"),km.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=km.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function c0(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Fh={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},JY=["Webkit","ms","Moz","O"];Object.keys(Fh).forEach(function(e){JY.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Fh[t]=Fh[e]})});function bI(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Fh.hasOwnProperty(e)&&Fh[e]?(""+t).trim():t+"px"}function yI(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,o=bI(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,o):e[n]=o}}var eQ=Pn({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function BE(e,t){if(t){if(eQ[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(Ie(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(Ie(60));if(!(typeof t.dangerouslySetInnerHTML=="object"&&"__html"in t.dangerouslySetInnerHTML))throw Error(Ie(61))}if(t.style!=null&&typeof t.style!="object")throw Error(Ie(62))}}function RE(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function z4(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var OE=null,md=null,gd=null;function Px(e){if(e=V0(e)){if(typeof OE!="function")throw Error(Ie(280));var t=e.stateNode;t&&(t=Db(t),OE(e.stateNode,e.type,t))}}function EI(e){md?gd?gd.push(e):gd=[e]:md=e}function _I(){if(md){var e=md,t=gd;if(gd=md=null,Px(e),t)for(e=0;e<t.length;e++)Px(t[e])}}function H4(e,t){return e(t)}function TI(e,t,n,r,o){return e(t,n,r,o)}function U4(){}var wI=H4,Ec=!1,c2=!1;function q4(){(md!==null||gd!==null)&&(U4(),_I())}function tQ(e,t,n){if(c2)return e(t,n);c2=!0;try{return wI(e,t,n)}finally{c2=!1,q4()}}function f0(e,t){var n=e.stateNode;if(n===null)return null;var r=Db(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(Ie(231,t,typeof n));return n}var DE=!1;if(al)try{var U1={};Object.defineProperty(U1,"passive",{get:function(){DE=!0}}),window.addEventListener("test",U1,U1),window.removeEventListener("test",U1,U1)}catch{DE=!1}function nQ(e,t,n,r,o,i,a,s,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(d){this.onError(d)}}var Ih=!1,pv=null,mv=!1,PE=null,rQ={onError:function(e){Ih=!0,pv=e}};function oQ(e,t,n,r,o,i,a,s,l){Ih=!1,pv=null,nQ.apply(rQ,arguments)}function iQ(e,t,n,r,o,i,a,s,l){if(oQ.apply(this,arguments),Ih){if(Ih){var u=pv;Ih=!1,pv=null}else throw Error(Ie(198));mv||(mv=!0,PE=u)}}function Uc(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&1026&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function kI(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function Mx(e){if(Uc(e)!==e)throw Error(Ie(188))}function aQ(e){var t=e.alternate;if(!t){if(t=Uc(e),t===null)throw Error(Ie(188));return t!==e?null:e}for(var n=e,r=t;;){var o=n.return;if(o===null)break;var i=o.alternate;if(i===null){if(r=o.return,r!==null){n=r;continue}break}if(o.child===i.child){for(i=o.child;i;){if(i===n)return Mx(o),e;if(i===r)return Mx(o),t;i=i.sibling}throw Error(Ie(188))}if(n.return!==r.return)n=o,r=i;else{for(var a=!1,s=o.child;s;){if(s===n){a=!0,n=o,r=i;break}if(s===r){a=!0,r=o,n=i;break}s=s.sibling}if(!a){for(s=i.child;s;){if(s===n){a=!0,n=i,r=o;break}if(s===r){a=!0,r=i,n=o;break}s=s.sibling}if(!a)throw Error(Ie(189))}}if(n.alternate!==r)throw Error(Ie(190))}if(n.tag!==3)throw Error(Ie(188));return n.stateNode.current===n?e:t}function SI(e){if(e=aQ(e),!e)return null;for(var t=e;;){if(t.tag===5||t.tag===6)return t;if(t.child)t.child.return=t,t=t.child;else{if(t===e)break;for(;!t.sibling;){if(!t.return||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}}return null}function Lx(e,t){for(var n=e.alternate;t!==null;){if(t===e||t===n)return!0;t=t.return}return!1}var xI,$4,CI,AI,ME=!1,Qa=[],fu=null,du=null,hu=null,d0=new Map,h0=new Map,q1=[],jx="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function LE(e,t,n,r,o){return{blockedOn:e,domEventName:t,eventSystemFlags:n|16,nativeEvent:o,targetContainers:[r]}}function zx(e,t){switch(e){case"focusin":case"focusout":fu=null;break;case"dragenter":case"dragleave":du=null;break;case"mouseover":case"mouseout":hu=null;break;case"pointerover":case"pointerout":d0.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":h0.delete(t.pointerId)}}function $1(e,t,n,r,o,i){return e===null||e.nativeEvent!==i?(e=LE(t,n,r,o,i),t!==null&&(t=V0(t),t!==null&&$4(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,o!==null&&t.indexOf(o)===-1&&t.push(o),e)}function sQ(e,t,n,r,o){switch(t){case"focusin":return fu=$1(fu,e,t,n,r,o),!0;case"dragenter":return du=$1(du,e,t,n,r,o),!0;case"mouseover":return hu=$1(hu,e,t,n,r,o),!0;case"pointerover":var i=o.pointerId;return d0.set(i,$1(d0.get(i)||null,e,t,n,r,o)),!0;case"gotpointercapture":return i=o.pointerId,h0.set(i,$1(h0.get(i)||null,e,t,n,r,o)),!0}return!1}function lQ(e){var t=_c(e.target);if(t!==null){var n=Uc(t);if(n!==null){if(t=n.tag,t===13){if(t=kI(n),t!==null){e.blockedOn=t,AI(e.lanePriority,function(){Lr.unstable_runWithPriority(e.priority,function(){CI(n)})});return}}else if(t===3&&n.stateNode.hydrate){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function _g(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=V4(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n!==null)return t=V0(n),t!==null&&$4(t),e.blockedOn=n,!1;t.shift()}return!0}function Hx(e,t,n){_g(e)&&n.delete(t)}function uQ(){for(ME=!1;0<Qa.length;){var e=Qa[0];if(e.blockedOn!==null){e=V0(e.blockedOn),e!==null&&xI(e);break}for(var t=e.targetContainers;0<t.length;){var n=V4(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n!==null){e.blockedOn=n;break}t.shift()}e.blockedOn===null&&Qa.shift()}fu!==null&&_g(fu)&&(fu=null),du!==null&&_g(du)&&(du=null),hu!==null&&_g(hu)&&(hu=null),d0.forEach(Hx),h0.forEach(Hx)}function W1(e,t){e.blockedOn===t&&(e.blockedOn=null,ME||(ME=!0,Lr.unstable_scheduleCallback(Lr.unstable_NormalPriority,uQ)))}function NI(e){function t(o){return W1(o,e)}if(0<Qa.length){W1(Qa[0],e);for(var n=1;n<Qa.length;n++){var r=Qa[n];r.blockedOn===e&&(r.blockedOn=null)}}for(fu!==null&&W1(fu,e),du!==null&&W1(du,e),hu!==null&&W1(hu,e),d0.forEach(t),h0.forEach(t),n=0;n<q1.length;n++)r=q1[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<q1.length&&(n=q1[0],n.blockedOn===null);)lQ(n),n.blockedOn===null&&q1.shift()}function Sm(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Zf={animationend:Sm("Animation","AnimationEnd"),animationiteration:Sm("Animation","AnimationIteration"),animationstart:Sm("Animation","AnimationStart"),transitionend:Sm("Transition","TransitionEnd")},f2={},FI={};al&&(FI=document.createElement("div").style,"AnimationEvent"in window||(delete Zf.animationend.animation,delete Zf.animationiteration.animation,delete Zf.animationstart.animation),"TransitionEvent"in window||delete Zf.transitionend.transition);function Fb(e){if(f2[e])return f2[e];if(!Zf[e])return e;var t=Zf[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in FI)return f2[e]=t[n];return e}var II=Fb("animationend"),BI=Fb("animationiteration"),RI=Fb("animationstart"),OI=Fb("transitionend"),DI=new Map,W4=new Map,cQ=["abort","abort",II,"animationEnd",BI,"animationIteration",RI,"animationStart","canplay","canPlay","canplaythrough","canPlayThrough","durationchange","durationChange","emptied","emptied","encrypted","encrypted","ended","ended","error","error","gotpointercapture","gotPointerCapture","load","load","loadeddata","loadedData","loadedmetadata","loadedMetadata","loadstart","loadStart","lostpointercapture","lostPointerCapture","playing","playing","progress","progress","seeking","seeking","stalled","stalled","suspend","suspend","timeupdate","timeUpdate",OI,"transitionEnd","waiting","waiting"];function G4(e,t){for(var n=0;n<e.length;n+=2){var r=e[n],o=e[n+1];o="on"+(o[0].toUpperCase()+o.slice(1)),W4.set(r,t),DI.set(r,o),zc(o,[r])}}var fQ=Lr.unstable_now;fQ();var yn=8;function Hf(e){if(1&e)return yn=15,1;if(2&e)return yn=14,2;if(4&e)return yn=13,4;var t=24&e;return t!==0?(yn=12,t):e&32?(yn=11,32):(t=192&e,t!==0?(yn=10,t):e&256?(yn=9,256):(t=3584&e,t!==0?(yn=8,t):e&4096?(yn=7,4096):(t=4186112&e,t!==0?(yn=6,t):(t=62914560&e,t!==0?(yn=5,t):e&67108864?(yn=4,67108864):e&134217728?(yn=3,134217728):(t=805306368&e,t!==0?(yn=2,t):1073741824&e?(yn=1,1073741824):(yn=8,e))))))}function dQ(e){switch(e){case 99:return 15;case 98:return 10;case 97:case 96:return 8;case 95:return 2;default:return 0}}function hQ(e){switch(e){case 15:case 14:return 99;case 13:case 12:case 11:case 10:return 98;case 9:case 8:case 7:case 6:case 4:case 5:return 97;case 3:case 2:case 1:return 95;case 0:return 90;default:throw Error(Ie(358,e))}}function p0(e,t){var n=e.pendingLanes;if(n===0)return yn=0;var r=0,o=0,i=e.expiredLanes,a=e.suspendedLanes,s=e.pingedLanes;if(i!==0)r=i,o=yn=15;else if(i=n&134217727,i!==0){var l=i&~a;l!==0?(r=Hf(l),o=yn):(s&=i,s!==0&&(r=Hf(s),o=yn))}else i=n&~a,i!==0?(r=Hf(i),o=yn):s!==0&&(r=Hf(s),o=yn);if(r===0)return 0;if(r=31-ku(r),r=n&((0>r?0:1<<r)<<1)-1,t!==0&&t!==r&&!(t&a)){if(Hf(t),o<=yn)return t;yn=o}if(t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-ku(t),o=1<<n,r|=e[n],t&=~o;return r}function PI(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function gv(e,t){switch(e){case 15:return 1;case 14:return 2;case 12:return e=Uf(24&~t),e===0?gv(10,t):e;case 10:return e=Uf(192&~t),e===0?gv(8,t):e;case 8:return e=Uf(3584&~t),e===0&&(e=Uf(4186112&~t),e===0&&(e=512)),e;case 2:return t=Uf(805306368&~t),t===0&&(t=268435456),t}throw Error(Ie(358,e))}function Uf(e){return e&-e}function d2(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ib(e,t,n){e.pendingLanes|=t;var r=t-1;e.suspendedLanes&=r,e.pingedLanes&=r,e=e.eventTimes,t=31-ku(t),e[t]=n}var ku=Math.clz32?Math.clz32:gQ,pQ=Math.log,mQ=Math.LN2;function gQ(e){return e===0?32:31-(pQ(e)/mQ|0)|0}var vQ=Lr.unstable_UserBlockingPriority,bQ=Lr.unstable_runWithPriority,Tg=!0;function yQ(e,t,n,r){Ec||U4();var o=K4,i=Ec;Ec=!0;try{TI(o,e,t,n,r)}finally{(Ec=i)||q4()}}function EQ(e,t,n,r){bQ(vQ,K4.bind(null,e,t,n,r))}function K4(e,t,n,r){if(Tg){var o;if((o=(t&4)===0)&&0<Qa.length&&-1<jx.indexOf(e))e=LE(null,e,t,n,r),Qa.push(e);else{var i=V4(e,t,n,r);if(i===null)o&&zx(e,r);else{if(o){if(-1<jx.indexOf(e)){e=LE(i,e,t,n,r),Qa.push(e);return}if(sQ(i,e,t,n,r))return;zx(e,r)}YI(e,t,r,null,n)}}}}function V4(e,t,n,r){var o=z4(r);if(o=_c(o),o!==null){var i=Uc(o);if(i===null)o=null;else{var a=i.tag;if(a===13){if(o=kI(i),o!==null)return o;o=null}else if(a===3){if(i.stateNode.hydrate)return i.tag===3?i.stateNode.containerInfo:null;o=null}else i!==o&&(o=null)}}return YI(e,t,r,o,n),null}var ru=null,Y4=null,wg=null;function MI(){if(wg)return wg;var e,t=Y4,n=t.length,r,o="value"in ru?ru.value:ru.textContent,i=o.length;for(e=0;e<n&&t[e]===o[e];e++);var a=n-e;for(r=1;r<=a&&t[n-r]===o[i-r];r++);return wg=o.slice(e,1<r?1-r:void 0)}function kg(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function xm(){return!0}function Ux(){return!1}function Ei(e){function t(n,r,o,i,a){this._reactName=n,this._targetInst=o,this.type=r,this.nativeEvent=i,this.target=a,this.currentTarget=null;for(var s in e)e.hasOwnProperty(s)&&(n=e[s],this[s]=n?n(i):i[s]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?xm:Ux,this.isPropagationStopped=Ux,this}return Pn(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=xm)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=xm)},persist:function(){},isPersistent:xm}),t}var Jd={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Q4=Ei(Jd),K0=Pn({},Jd,{view:0,detail:0}),_Q=Ei(K0),h2,p2,G1,Bb=Pn({},K0,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:X4,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==G1&&(G1&&e.type==="mousemove"?(h2=e.screenX-G1.screenX,p2=e.screenY-G1.screenY):p2=h2=0,G1=e),h2)},movementY:function(e){return"movementY"in e?e.movementY:p2}}),qx=Ei(Bb),TQ=Pn({},Bb,{dataTransfer:0}),wQ=Ei(TQ),kQ=Pn({},K0,{relatedTarget:0}),m2=Ei(kQ),SQ=Pn({},Jd,{animationName:0,elapsedTime:0,pseudoElement:0}),xQ=Ei(SQ),CQ=Pn({},Jd,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),AQ=Ei(CQ),NQ=Pn({},Jd,{data:0}),$x=Ei(NQ),FQ={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},IQ={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},BQ={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function RQ(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=BQ[e])?!!t[e]:!1}function X4(){return RQ}var OQ=Pn({},K0,{key:function(e){if(e.key){var t=FQ[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=kg(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?IQ[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:X4,charCode:function(e){return e.type==="keypress"?kg(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?kg(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),DQ=Ei(OQ),PQ=Pn({},Bb,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Wx=Ei(PQ),MQ=Pn({},K0,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:X4}),LQ=Ei(MQ),jQ=Pn({},Jd,{propertyName:0,elapsedTime:0,pseudoElement:0}),zQ=Ei(jQ),HQ=Pn({},Bb,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),UQ=Ei(HQ),qQ=[9,13,27,32],Z4=al&&"CompositionEvent"in window,Bh=null;al&&"documentMode"in document&&(Bh=document.documentMode);var $Q=al&&"TextEvent"in window&&!Bh,LI=al&&(!Z4||Bh&&8<Bh&&11>=Bh),Gx=String.fromCharCode(32),Kx=!1;function jI(e,t){switch(e){case"keyup":return qQ.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function zI(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Jf=!1;function WQ(e,t){switch(e){case"compositionend":return zI(t);case"keypress":return t.which!==32?null:(Kx=!0,Gx);case"textInput":return e=t.data,e===Gx&&Kx?null:e;default:return null}}function GQ(e,t){if(Jf)return e==="compositionend"||!Z4&&jI(e,t)?(e=MI(),wg=Y4=ru=null,Jf=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return LI&&t.locale!=="ko"?null:t.data;default:return null}}var KQ={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Vx(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!KQ[e.type]:t==="textarea"}function HI(e,t,n,r){EI(r),t=vv(t,"onChange"),0<t.length&&(n=new Q4("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Rh=null,m0=null;function VQ(e){GI(e,0)}function Rb(e){var t=td(e);if(hI(t))return e}function YQ(e,t){if(e==="change")return t}var UI=!1;if(al){var g2;if(al){var v2="oninput"in document;if(!v2){var Yx=document.createElement("div");Yx.setAttribute("oninput","return;"),v2=typeof Yx.oninput=="function"}g2=v2}else g2=!1;UI=g2&&(!document.documentMode||9<document.documentMode)}function Qx(){Rh&&(Rh.detachEvent("onpropertychange",qI),m0=Rh=null)}function qI(e){if(e.propertyName==="value"&&Rb(m0)){var t=[];if(HI(t,m0,e,z4(e)),e=VQ,Ec)e(t);else{Ec=!0;try{H4(e,t)}finally{Ec=!1,q4()}}}}function QQ(e,t,n){e==="focusin"?(Qx(),Rh=t,m0=n,Rh.attachEvent("onpropertychange",qI)):e==="focusout"&&Qx()}function XQ(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Rb(m0)}function ZQ(e,t){if(e==="click")return Rb(t)}function JQ(e,t){if(e==="input"||e==="change")return Rb(t)}function eX(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Hi=typeof Object.is=="function"?Object.is:eX,tX=Object.prototype.hasOwnProperty;function g0(e,t){if(Hi(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++)if(!tX.call(t,n[r])||!Hi(e[n[r]],t[n[r]]))return!1;return!0}function Xx(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Zx(e,t){var n=Xx(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Xx(n)}}function $I(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?$I(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Jx(){for(var e=window,t=hv();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=hv(e.document)}return t}function jE(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var nX=al&&"documentMode"in document&&11>=document.documentMode,ed=null,zE=null,Oh=null,HE=!1;function e3(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;HE||ed==null||ed!==hv(r)||(r=ed,"selectionStart"in r&&jE(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Oh&&g0(Oh,r)||(Oh=r,r=vv(zE,"onSelect"),0<r.length&&(t=new Q4("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=ed)))}G4("cancel cancel click click close close contextmenu contextMenu copy copy cut cut auxclick auxClick dblclick doubleClick dragend dragEnd dragstart dragStart drop drop focusin focus focusout blur input input invalid invalid keydown keyDown keypress keyPress keyup keyUp mousedown mouseDown mouseup mouseUp paste paste pause pause play play pointercancel pointerCancel pointerdown pointerDown pointerup pointerUp ratechange rateChange reset reset seeked seeked submit submit touchcancel touchCancel touchend touchEnd touchstart touchStart volumechange volumeChange".split(" "),0);G4("drag drag dragenter dragEnter dragexit dragExit dragleave dragLeave dragover dragOver mousemove mouseMove mouseout mouseOut mouseover mouseOver pointermove pointerMove pointerout pointerOut pointerover pointerOver scroll scroll toggle toggle touchmove touchMove wheel wheel".split(" "),1);G4(cQ,2);for(var t3="change selectionchange textInput compositionstart compositionend compositionupdate".split(" "),b2=0;b2<t3.length;b2++)W4.set(t3[b2],0);Ld("onMouseEnter",["mouseout","mouseover"]);Ld("onMouseLeave",["mouseout","mouseover"]);Ld("onPointerEnter",["pointerout","pointerover"]);Ld("onPointerLeave",["pointerout","pointerover"]);zc("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));zc("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));zc("onBeforeInput",["compositionend","keypress","textInput","paste"]);zc("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));zc("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));zc("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Eh="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),WI=new Set("cancel close invalid load scroll toggle".split(" ").concat(Eh));function n3(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,iQ(r,t,void 0,e),e.currentTarget=null}function GI(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],o=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var a=r.length-1;0<=a;a--){var s=r[a],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==i&&o.isPropagationStopped())break e;n3(o,s,u),i=l}else for(a=0;a<r.length;a++){if(s=r[a],l=s.instance,u=s.currentTarget,s=s.listener,l!==i&&o.isPropagationStopped())break e;n3(o,s,u),i=l}}}if(mv)throw e=PE,mv=!1,PE=null,e}function xn(e,t){var n=XI(t),r=e+"__bubble";n.has(r)||(VI(t,e,2,!1),n.add(r))}var r3="_reactListening"+Math.random().toString(36).slice(2);function KI(e){e[r3]||(e[r3]=!0,cI.forEach(function(t){WI.has(t)||o3(t,!1,e,null),o3(t,!0,e,null)}))}function o3(e,t,n,r){var o=4<arguments.length&&arguments[4]!==void 0?arguments[4]:0,i=n;if(e==="selectionchange"&&n.nodeType!==9&&(i=n.ownerDocument),r!==null&&!t&&WI.has(e)){if(e!=="scroll")return;o|=2,i=r}var a=XI(i),s=e+"__"+(t?"capture":"bubble");a.has(s)||(t&&(o|=4),VI(i,e,o,t),a.add(s))}function VI(e,t,n,r){var o=W4.get(t);switch(o===void 0?2:o){case 0:o=yQ;break;case 1:o=EQ;break;default:o=K4}n=o.bind(null,t,n,e),o=void 0,!DE||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(o=!0),r?o!==void 0?e.addEventListener(t,n,{capture:!0,passive:o}):e.addEventListener(t,n,!0):o!==void 0?e.addEventListener(t,n,{passive:o}):e.addEventListener(t,n,!1)}function YI(e,t,n,r,o){var i=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var a=r.tag;if(a===3||a===4){var s=r.stateNode.containerInfo;if(s===o||s.nodeType===8&&s.parentNode===o)break;if(a===4)for(a=r.return;a!==null;){var l=a.tag;if((l===3||l===4)&&(l=a.stateNode.containerInfo,l===o||l.nodeType===8&&l.parentNode===o))return;a=a.return}for(;s!==null;){if(a=_c(s),a===null)return;if(l=a.tag,l===5||l===6){r=i=a;continue e}s=s.parentNode}}r=r.return}tQ(function(){var u=i,d=z4(n),h=[];e:{var p=DI.get(e);if(p!==void 0){var m=Q4,v=e;switch(e){case"keypress":if(kg(n)===0)break e;case"keydown":case"keyup":m=DQ;break;case"focusin":v="focus",m=m2;break;case"focusout":v="blur",m=m2;break;case"beforeblur":case"afterblur":m=m2;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":m=qx;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":m=wQ;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":m=LQ;break;case II:case BI:case RI:m=xQ;break;case OI:m=zQ;break;case"scroll":m=_Q;break;case"wheel":m=UQ;break;case"copy":case"cut":case"paste":m=AQ;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":m=Wx}var _=(t&4)!==0,b=!_&&e==="scroll",E=_?p!==null?p+"Capture":null:p;_=[];for(var w=u,k;w!==null;){k=w;var y=k.stateNode;if(k.tag===5&&y!==null&&(k=y,E!==null&&(y=f0(w,E),y!=null&&_.push(v0(w,y,k)))),b)break;w=w.return}0<_.length&&(p=new m(p,v,null,n,d),h.push({event:p,listeners:_}))}}if(!(t&7)){e:{if(p=e==="mouseover"||e==="pointerover",m=e==="mouseout"||e==="pointerout",p&&!(t&16)&&(v=n.relatedTarget||n.fromElement)&&(_c(v)||v[e1]))break e;if((m||p)&&(p=d.window===d?d:(p=d.ownerDocument)?p.defaultView||p.parentWindow:window,m?(v=n.relatedTarget||n.toElement,m=u,v=v?_c(v):null,v!==null&&(b=Uc(v),v!==b||v.tag!==5&&v.tag!==6)&&(v=null)):(m=null,v=u),m!==v)){if(_=qx,y="onMouseLeave",E="onMouseEnter",w="mouse",(e==="pointerout"||e==="pointerover")&&(_=Wx,y="onPointerLeave",E="onPointerEnter",w="pointer"),b=m==null?p:td(m),k=v==null?p:td(v),p=new _(y,w+"leave",m,n,d),p.target=b,p.relatedTarget=k,y=null,_c(d)===u&&(_=new _(E,w+"enter",v,n,d),_.target=k,_.relatedTarget=b,y=_),b=y,m&&v)t:{for(_=m,E=v,w=0,k=_;k;k=Ef(k))w++;for(k=0,y=E;y;y=Ef(y))k++;for(;0<w-k;)_=Ef(_),w--;for(;0<k-w;)E=Ef(E),k--;for(;w--;){if(_===E||E!==null&&_===E.alternate)break t;_=Ef(_),E=Ef(E)}_=null}else _=null;m!==null&&i3(h,p,m,_,!1),v!==null&&b!==null&&i3(h,b,v,_,!0)}}e:{if(p=u?td(u):window,m=p.nodeName&&p.nodeName.toLowerCase(),m==="select"||m==="input"&&p.type==="file")var F=YQ;else if(Vx(p))if(UI)F=JQ;else{F=XQ;var C=QQ}else(m=p.nodeName)&&m.toLowerCase()==="input"&&(p.type==="checkbox"||p.type==="radio")&&(F=ZQ);if(F&&(F=F(e,u))){HI(h,F,n,d);break e}C&&C(e,p,u),e==="focusout"&&(C=p._wrapperState)&&C.controlled&&p.type==="number"&&CE(p,"number",p.value)}switch(C=u?td(u):window,e){case"focusin":(Vx(C)||C.contentEditable==="true")&&(ed=C,zE=u,Oh=null);break;case"focusout":Oh=zE=ed=null;break;case"mousedown":HE=!0;break;case"contextmenu":case"mouseup":case"dragend":HE=!1,e3(h,n,d);break;case"selectionchange":if(nX)break;case"keydown":case"keyup":e3(h,n,d)}var A;if(Z4)e:{switch(e){case"compositionstart":var P="onCompositionStart";break e;case"compositionend":P="onCompositionEnd";break e;case"compositionupdate":P="onCompositionUpdate";break e}P=void 0}else Jf?jI(e,n)&&(P="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(P="onCompositionStart");P&&(LI&&n.locale!=="ko"&&(Jf||P!=="onCompositionStart"?P==="onCompositionEnd"&&Jf&&(A=MI()):(ru=d,Y4="value"in ru?ru.value:ru.textContent,Jf=!0)),C=vv(u,P),0<C.length&&(P=new $x(P,e,null,n,d),h.push({event:P,listeners:C}),A?P.data=A:(A=zI(n),A!==null&&(P.data=A)))),(A=$Q?WQ(e,n):GQ(e,n))&&(u=vv(u,"onBeforeInput"),0<u.length&&(d=new $x("onBeforeInput","beforeinput",null,n,d),h.push({event:d,listeners:u}),d.data=A))}GI(h,t)})}function v0(e,t,n){return{instance:e,listener:t,currentTarget:n}}function vv(e,t){for(var n=t+"Capture",r=[];e!==null;){var o=e,i=o.stateNode;o.tag===5&&i!==null&&(o=i,i=f0(e,n),i!=null&&r.unshift(v0(e,i,o)),i=f0(e,t),i!=null&&r.push(v0(e,i,o))),e=e.return}return r}function Ef(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function i3(e,t,n,r,o){for(var i=t._reactName,a=[];n!==null&&n!==r;){var s=n,l=s.alternate,u=s.stateNode;if(l!==null&&l===r)break;s.tag===5&&u!==null&&(s=u,o?(l=f0(n,i),l!=null&&a.unshift(v0(n,l,s))):o||(l=f0(n,i),l!=null&&a.push(v0(n,l,s)))),n=n.return}a.length!==0&&e.push({event:t,listeners:a})}function bv(){}var y2=null,E2=null;function QI(e,t){switch(e){case"button":case"input":case"select":case"textarea":return!!t.autoFocus}return!1}function UE(e,t){return e==="textarea"||e==="option"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var a3=typeof setTimeout=="function"?setTimeout:void 0,rX=typeof clearTimeout=="function"?clearTimeout:void 0;function J4(e){e.nodeType===1?e.textContent="":e.nodeType===9&&(e=e.body,e!=null&&(e.textContent=""))}function vd(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break}return e}function s3(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var _2=0;function oX(e){return{$$typeof:L4,toString:e,valueOf:e}}var Ob=Math.random().toString(36).slice(2),ou="__reactFiber$"+Ob,yv="__reactProps$"+Ob,e1="__reactContainer$"+Ob,l3="__reactEvents$"+Ob;function _c(e){var t=e[ou];if(t)return t;for(var n=e.parentNode;n;){if(t=n[e1]||n[ou]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=s3(e);e!==null;){if(n=e[ou])return n;e=s3(e)}return t}e=n,n=e.parentNode}return null}function V0(e){return e=e[ou]||e[e1],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function td(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(Ie(33))}function Db(e){return e[yv]||null}function XI(e){var t=e[l3];return t===void 0&&(t=e[l3]=new Set),t}var qE=[],nd=-1;function Bu(e){return{current:e}}function An(e){0>nd||(e.current=qE[nd],qE[nd]=null,nd--)}function Qn(e,t){nd++,qE[nd]=e.current,e.current=t}var Su={},mo=Bu(Su),Jo=Bu(!1),Dc=Su;function jd(e,t){var n=e.type.contextTypes;if(!n)return Su;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in n)o[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function ei(e){return e=e.childContextTypes,e!=null}function Ev(){An(Jo),An(mo)}function u3(e,t,n){if(mo.current!==Su)throw Error(Ie(168));Qn(mo,t),Qn(Jo,n)}function ZI(e,t,n){var r=e.stateNode;if(e=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var o in r)if(!(o in e))throw Error(Ie(108,hd(t)||"Unknown",o));return Pn({},n,r)}function Sg(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Su,Dc=mo.current,Qn(mo,e),Qn(Jo,Jo.current),!0}function c3(e,t,n){var r=e.stateNode;if(!r)throw Error(Ie(169));n?(e=ZI(e,t,Dc),r.__reactInternalMemoizedMergedChildContext=e,An(Jo),An(mo),Qn(mo,e)):An(Jo),Qn(Jo,n)}var eT=null,Ac=null,iX=Lr.unstable_runWithPriority,tT=Lr.unstable_scheduleCallback,$E=Lr.unstable_cancelCallback,aX=Lr.unstable_shouldYield,f3=Lr.unstable_requestPaint,WE=Lr.unstable_now,sX=Lr.unstable_getCurrentPriorityLevel,Pb=Lr.unstable_ImmediatePriority,JI=Lr.unstable_UserBlockingPriority,eB=Lr.unstable_NormalPriority,tB=Lr.unstable_LowPriority,nB=Lr.unstable_IdlePriority,T2={},lX=f3!==void 0?f3:function(){},Gs=null,xg=null,w2=!1,d3=WE(),co=1e4>d3?WE:function(){return WE()-d3};function zd(){switch(sX()){case Pb:return 99;case JI:return 98;case eB:return 97;case tB:return 96;case nB:return 95;default:throw Error(Ie(332))}}function rB(e){switch(e){case 99:return Pb;case 98:return JI;case 97:return eB;case 96:return tB;case 95:return nB;default:throw Error(Ie(332))}}function Pc(e,t){return e=rB(e),iX(e,t)}function b0(e,t,n){return e=rB(e),tT(e,t,n)}function ps(){if(xg!==null){var e=xg;xg=null,$E(e)}oB()}function oB(){if(!w2&&Gs!==null){w2=!0;var e=0;try{var t=Gs;Pc(99,function(){for(;e<t.length;e++){var n=t[e];do n=n(!0);while(n!==null)}}),Gs=null}catch(n){throw Gs!==null&&(Gs=Gs.slice(e+1)),tT(Pb,ps),n}finally{w2=!1}}}var uX=Hc.ReactCurrentBatchConfig;function ga(e,t){if(e&&e.defaultProps){t=Pn({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}var _v=Bu(null),Tv=null,rd=null,wv=null;function nT(){wv=rd=Tv=null}function rT(e){var t=_v.current;An(_v),e.type._context._currentValue=t}function iB(e,t){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)===t){if(n===null||(n.childLanes&t)===t)break;n.childLanes|=t}else e.childLanes|=t,n!==null&&(n.childLanes|=t);e=e.return}}function bd(e,t){Tv=e,wv=rd=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ea=!0),e.firstContext=null)}function Xi(e,t){if(wv!==e&&t!==!1&&t!==0)if((typeof t!="number"||t===1073741823)&&(wv=e,t=1073741823),t={context:e,observedBits:t,next:null},rd===null){if(Tv===null)throw Error(Ie(308));rd=t,Tv.dependencies={lanes:0,firstContext:t,responders:null}}else rd=rd.next=t;return e._currentValue}var Vl=!1;function oT(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null},effects:null}}function aB(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function pu(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function mu(e,t){if(e=e.updateQueue,e!==null){e=e.shared;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}}function h3(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var o=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?o=i=a:i=i.next=a,n=n.next}while(n!==null);i===null?o=i=t:i=i.next=t}else o=i=t;n={baseState:r.baseState,firstBaseUpdate:o,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function y0(e,t,n,r){var o=e.updateQueue;Vl=!1;var i=o.firstBaseUpdate,a=o.lastBaseUpdate,s=o.shared.pending;if(s!==null){o.shared.pending=null;var l=s,u=l.next;l.next=null,a===null?i=u:a.next=u,a=l;var d=e.alternate;if(d!==null){d=d.updateQueue;var h=d.lastBaseUpdate;h!==a&&(h===null?d.firstBaseUpdate=u:h.next=u,d.lastBaseUpdate=l)}}if(i!==null){h=o.baseState,a=0,d=u=l=null;do{s=i.lane;var p=i.eventTime;if((r&s)===s){d!==null&&(d=d.next={eventTime:p,lane:0,tag:i.tag,payload:i.payload,callback:i.callback,next:null});e:{var m=e,v=i;switch(s=t,p=n,v.tag){case 1:if(m=v.payload,typeof m=="function"){h=m.call(p,h,s);break e}h=m;break e;case 3:m.flags=m.flags&-4097|64;case 0:if(m=v.payload,s=typeof m=="function"?m.call(p,h,s):m,s==null)break e;h=Pn({},h,s);break e;case 2:Vl=!0}}i.callback!==null&&(e.flags|=32,s=o.effects,s===null?o.effects=[i]:s.push(i))}else p={eventTime:p,lane:s,tag:i.tag,payload:i.payload,callback:i.callback,next:null},d===null?(u=d=p,l=h):d=d.next=p,a|=s;if(i=i.next,i===null){if(s=o.shared.pending,s===null)break;i=s.next,s.next=null,o.lastBaseUpdate=s,o.shared.pending=null}}while(1);d===null&&(l=h),o.baseState=l,o.firstBaseUpdate=u,o.lastBaseUpdate=d,Q0|=a,e.lanes=a,e.memoizedState=h}}function p3(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],o=r.callback;if(o!==null){if(r.callback=null,r=n,typeof o!="function")throw Error(Ie(191,o));o.call(r)}}}var sB=new Cb.Component().refs;function kv(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:Pn({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Mb={isMounted:function(e){return(e=e._reactInternals)?Uc(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=vi(),o=gu(e),i=pu(r,o);i.payload=t,n!=null&&(i.callback=n),mu(e,i),vu(e,o,r)},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=vi(),o=gu(e),i=pu(r,o);i.tag=1,i.payload=t,n!=null&&(i.callback=n),mu(e,i),vu(e,o,r)},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=vi(),r=gu(e),o=pu(n,r);o.tag=2,t!=null&&(o.callback=t),mu(e,o),vu(e,r,n)}};function m3(e,t,n,r,o,i,a){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,i,a):t.prototype&&t.prototype.isPureReactComponent?!g0(n,r)||!g0(o,i):!0}function lB(e,t,n){var r=!1,o=Su,i=t.contextType;return typeof i=="object"&&i!==null?i=Xi(i):(o=ei(t)?Dc:mo.current,r=t.contextTypes,i=(r=r!=null)?jd(e,o):Su),t=new t(n,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Mb,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=o,e.__reactInternalMemoizedMaskedChildContext=i),t}function g3(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Mb.enqueueReplaceState(t,t.state,null)}function GE(e,t,n,r){var o=e.stateNode;o.props=n,o.state=e.memoizedState,o.refs=sB,oT(e);var i=t.contextType;typeof i=="object"&&i!==null?o.context=Xi(i):(i=ei(t)?Dc:mo.current,o.context=jd(e,i)),y0(e,n,o,r),o.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(kv(e,t,i,n),o.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof o.getSnapshotBeforeUpdate=="function"||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(t=o.state,typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount(),t!==o.state&&Mb.enqueueReplaceState(o,o.state,null),y0(e,n,o,r),o.state=e.memoizedState),typeof o.componentDidMount=="function"&&(e.flags|=4)}var Cm=Array.isArray;function K1(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(Ie(309));var r=n.stateNode}if(!r)throw Error(Ie(147,e));var o=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===o?t.ref:(t=function(i){var a=r.refs;a===sB&&(a=r.refs={}),i===null?delete a[o]:a[o]=i},t._stringRef=o,t)}if(typeof e!="string")throw Error(Ie(284));if(!n._owner)throw Error(Ie(290,e))}return e}function Am(e,t){if(e.type!=="textarea")throw Error(Ie(31,Object.prototype.toString.call(t)==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":t))}function uB(e){function t(b,E){if(e){var w=b.lastEffect;w!==null?(w.nextEffect=E,b.lastEffect=E):b.firstEffect=b.lastEffect=E,E.nextEffect=null,E.flags=8}}function n(b,E){if(!e)return null;for(;E!==null;)t(b,E),E=E.sibling;return null}function r(b,E){for(b=new Map;E!==null;)E.key!==null?b.set(E.key,E):b.set(E.index,E),E=E.sibling;return b}function o(b,E){return b=Cu(b,E),b.index=0,b.sibling=null,b}function i(b,E,w){return b.index=w,e?(w=b.alternate,w!==null?(w=w.index,w<E?(b.flags=2,E):w):(b.flags=2,E)):E}function a(b){return e&&b.alternate===null&&(b.flags=2),b}function s(b,E,w,k){return E===null||E.tag!==6?(E=A2(w,b.mode,k),E.return=b,E):(E=o(E,w),E.return=b,E)}function l(b,E,w,k){return E!==null&&E.elementType===w.type?(k=o(E,w.props),k.ref=K1(b,E,w),k.return=b,k):(k=Fg(w.type,w.key,w.props,null,b.mode,k),k.ref=K1(b,E,w),k.return=b,k)}function u(b,E,w,k){return E===null||E.tag!==4||E.stateNode.containerInfo!==w.containerInfo||E.stateNode.implementation!==w.implementation?(E=N2(w,b.mode,k),E.return=b,E):(E=o(E,w.children||[]),E.return=b,E)}function d(b,E,w,k,y){return E===null||E.tag!==7?(E=Td(w,b.mode,k,y),E.return=b,E):(E=o(E,w),E.return=b,E)}function h(b,E,w){if(typeof E=="string"||typeof E=="number")return E=A2(""+E,b.mode,w),E.return=b,E;if(typeof E=="object"&&E!==null){switch(E.$$typeof){case bh:return w=Fg(E.type,E.key,E.props,null,b.mode,w),w.ref=K1(b,null,E),w.return=b,w;case yc:return E=N2(E,b.mode,w),E.return=b,E}if(Cm(E)||H1(E))return E=Td(E,b.mode,w,null),E.return=b,E;Am(b,E)}return null}function p(b,E,w,k){var y=E!==null?E.key:null;if(typeof w=="string"||typeof w=="number")return y!==null?null:s(b,E,""+w,k);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case bh:return w.key===y?w.type===tu?d(b,E,w.props.children,k,y):l(b,E,w,k):null;case yc:return w.key===y?u(b,E,w,k):null}if(Cm(w)||H1(w))return y!==null?null:d(b,E,w,k,null);Am(b,w)}return null}function m(b,E,w,k,y){if(typeof k=="string"||typeof k=="number")return b=b.get(w)||null,s(E,b,""+k,y);if(typeof k=="object"&&k!==null){switch(k.$$typeof){case bh:return b=b.get(k.key===null?w:k.key)||null,k.type===tu?d(E,b,k.props.children,y,k.key):l(E,b,k,y);case yc:return b=b.get(k.key===null?w:k.key)||null,u(E,b,k,y)}if(Cm(k)||H1(k))return b=b.get(w)||null,d(E,b,k,y,null);Am(E,k)}return null}function v(b,E,w,k){for(var y=null,F=null,C=E,A=E=0,P=null;C!==null&&A<w.length;A++){C.index>A?(P=C,C=null):P=C.sibling;var I=p(b,C,w[A],k);if(I===null){C===null&&(C=P);break}e&&C&&I.alternate===null&&t(b,C),E=i(I,E,A),F===null?y=I:F.sibling=I,F=I,C=P}if(A===w.length)return n(b,C),y;if(C===null){for(;A<w.length;A++)C=h(b,w[A],k),C!==null&&(E=i(C,E,A),F===null?y=C:F.sibling=C,F=C);return y}for(C=r(b,C);A<w.length;A++)P=m(C,b,A,w[A],k),P!==null&&(e&&P.alternate!==null&&C.delete(P.key===null?A:P.key),E=i(P,E,A),F===null?y=P:F.sibling=P,F=P);return e&&C.forEach(function(j){return t(b,j)}),y}function _(b,E,w,k){var y=H1(w);if(typeof y!="function")throw Error(Ie(150));if(w=y.call(w),w==null)throw Error(Ie(151));for(var F=y=null,C=E,A=E=0,P=null,I=w.next();C!==null&&!I.done;A++,I=w.next()){C.index>A?(P=C,C=null):P=C.sibling;var j=p(b,C,I.value,k);if(j===null){C===null&&(C=P);break}e&&C&&j.alternate===null&&t(b,C),E=i(j,E,A),F===null?y=j:F.sibling=j,F=j,C=P}if(I.done)return n(b,C),y;if(C===null){for(;!I.done;A++,I=w.next())I=h(b,I.value,k),I!==null&&(E=i(I,E,A),F===null?y=I:F.sibling=I,F=I);return y}for(C=r(b,C);!I.done;A++,I=w.next())I=m(C,b,A,I.value,k),I!==null&&(e&&I.alternate!==null&&C.delete(I.key===null?A:I.key),E=i(I,E,A),F===null?y=I:F.sibling=I,F=I);return e&&C.forEach(function(H){return t(b,H)}),y}return function(b,E,w,k){var y=typeof w=="object"&&w!==null&&w.type===tu&&w.key===null;y&&(w=w.props.children);var F=typeof w=="object"&&w!==null;if(F)switch(w.$$typeof){case bh:e:{for(F=w.key,y=E;y!==null;){if(y.key===F){switch(y.tag){case 7:if(w.type===tu){n(b,y.sibling),E=o(y,w.props.children),E.return=b,b=E;break e}break;default:if(y.elementType===w.type){n(b,y.sibling),E=o(y,w.props),E.ref=K1(b,y,w),E.return=b,b=E;break e}}n(b,y);break}else t(b,y);y=y.sibling}w.type===tu?(E=Td(w.props.children,b.mode,k,w.key),E.return=b,b=E):(k=Fg(w.type,w.key,w.props,null,b.mode,k),k.ref=K1(b,E,w),k.return=b,b=k)}return a(b);case yc:e:{for(y=w.key;E!==null;){if(E.key===y)if(E.tag===4&&E.stateNode.containerInfo===w.containerInfo&&E.stateNode.implementation===w.implementation){n(b,E.sibling),E=o(E,w.children||[]),E.return=b,b=E;break e}else{n(b,E);break}else t(b,E);E=E.sibling}E=N2(w,b.mode,k),E.return=b,b=E}return a(b)}if(typeof w=="string"||typeof w=="number")return w=""+w,E!==null&&E.tag===6?(n(b,E.sibling),E=o(E,w),E.return=b,b=E):(n(b,E),E=A2(w,b.mode,k),E.return=b,b=E),a(b);if(Cm(w))return v(b,E,w,k);if(H1(w))return _(b,E,w,k);if(F&&Am(b,w),typeof w>"u"&&!y)switch(b.tag){case 1:case 22:case 0:case 11:case 15:throw Error(Ie(152,hd(b.type)||"Component"))}return n(b,E)}}var Sv=uB(!0),cB=uB(!1),Y0={},ns=Bu(Y0),E0=Bu(Y0),_0=Bu(Y0);function Tc(e){if(e===Y0)throw Error(Ie(174));return e}function KE(e,t){switch(Qn(_0,t),Qn(E0,e),Qn(ns,Y0),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:IE(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=IE(t,e)}An(ns),Qn(ns,t)}function Hd(){An(ns),An(E0),An(_0)}function v3(e){Tc(_0.current);var t=Tc(ns.current),n=IE(t,e.type);t!==n&&(Qn(E0,e),Qn(ns,n))}function iT(e){E0.current===e&&(An(ns),An(E0))}var Yn=Bu(0);function xv(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&64)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Xs=null,iu=null,rs=!1;function fB(e,t){var n=Ui(5,null,null,0);n.elementType="DELETED",n.type="DELETED",n.stateNode=t,n.return=e,n.flags=8,e.lastEffect!==null?(e.lastEffect.nextEffect=n,e.lastEffect=n):e.firstEffect=e.lastEffect=n}function b3(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,!0):!1;case 13:return!1;default:return!1}}function VE(e){if(rs){var t=iu;if(t){var n=t;if(!b3(e,t)){if(t=vd(n.nextSibling),!t||!b3(e,t)){e.flags=e.flags&-1025|2,rs=!1,Xs=e;return}fB(Xs,n)}Xs=e,iu=vd(t.firstChild)}else e.flags=e.flags&-1025|2,rs=!1,Xs=e}}function y3(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Xs=e}function Nm(e){if(e!==Xs)return!1;if(!rs)return y3(e),rs=!0,!1;var t=e.type;if(e.tag!==5||t!=="head"&&t!=="body"&&!UE(t,e.memoizedProps))for(t=iu;t;)fB(e,t),t=vd(t.nextSibling);if(y3(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(Ie(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){iu=vd(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}iu=null}}else iu=Xs?vd(e.stateNode.nextSibling):null;return!0}function k2(){iu=Xs=null,rs=!1}var yd=[];function aT(){for(var e=0;e<yd.length;e++)yd[e]._workInProgressVersionPrimary=null;yd.length=0}var Dh=Hc.ReactCurrentDispatcher,Wi=Hc.ReactCurrentBatchConfig,T0=0,cr=null,so=null,Yr=null,Cv=!1,Ph=!1;function Uo(){throw Error(Ie(321))}function sT(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Hi(e[n],t[n]))return!1;return!0}function lT(e,t,n,r,o,i){if(T0=i,cr=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Dh.current=e===null||e.memoizedState===null?fX:dX,e=n(r,o),Ph){i=0;do{if(Ph=!1,!(25>i))throw Error(Ie(301));i+=1,Yr=so=null,t.updateQueue=null,Dh.current=hX,e=n(r,o)}while(Ph)}if(Dh.current=Iv,t=so!==null&&so.next!==null,T0=0,Yr=so=cr=null,Cv=!1,t)throw Error(Ie(300));return e}function wc(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Yr===null?cr.memoizedState=Yr=e:Yr=Yr.next=e,Yr}function qc(){if(so===null){var e=cr.alternate;e=e!==null?e.memoizedState:null}else e=so.next;var t=Yr===null?cr.memoizedState:Yr.next;if(t!==null)Yr=t,so=e;else{if(e===null)throw Error(Ie(310));so=e,e={memoizedState:so.memoizedState,baseState:so.baseState,baseQueue:so.baseQueue,queue:so.queue,next:null},Yr===null?cr.memoizedState=Yr=e:Yr=Yr.next=e}return Yr}function Xa(e,t){return typeof t=="function"?t(e):t}function V1(e){var t=qc(),n=t.queue;if(n===null)throw Error(Ie(311));n.lastRenderedReducer=e;var r=so,o=r.baseQueue,i=n.pending;if(i!==null){if(o!==null){var a=o.next;o.next=i.next,i.next=a}r.baseQueue=o=i,n.pending=null}if(o!==null){o=o.next,r=r.baseState;var s=a=i=null,l=o;do{var u=l.lane;if((T0&u)===u)s!==null&&(s=s.next={lane:0,action:l.action,eagerReducer:l.eagerReducer,eagerState:l.eagerState,next:null}),r=l.eagerReducer===e?l.eagerState:e(r,l.action);else{var d={lane:u,action:l.action,eagerReducer:l.eagerReducer,eagerState:l.eagerState,next:null};s===null?(a=s=d,i=r):s=s.next=d,cr.lanes|=u,Q0|=u}l=l.next}while(l!==null&&l!==o);s===null?i=r:s.next=a,Hi(r,t.memoizedState)||(Ea=!0),t.memoizedState=r,t.baseState=i,t.baseQueue=s,n.lastRenderedState=r}return[t.memoizedState,n.dispatch]}function Y1(e){var t=qc(),n=t.queue;if(n===null)throw Error(Ie(311));n.lastRenderedReducer=e;var r=n.dispatch,o=n.pending,i=t.memoizedState;if(o!==null){n.pending=null;var a=o=o.next;do i=e(i,a.action),a=a.next;while(a!==o);Hi(i,t.memoizedState)||(Ea=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function E3(e,t,n){var r=t._getVersion;r=r(t._source);var o=t._workInProgressVersionPrimary;if(o!==null?e=o===r:(e=e.mutableReadLanes,(e=(T0&e)===e)&&(t._workInProgressVersionPrimary=r,yd.push(t))),e)return n(t._source);throw yd.push(t),Error(Ie(350))}function dB(e,t,n,r){var o=Bo;if(o===null)throw Error(Ie(349));var i=t._getVersion,a=i(t._source),s=Dh.current,l=s.useState(function(){return E3(o,t,n)}),u=l[1],d=l[0];l=Yr;var h=e.memoizedState,p=h.refs,m=p.getSnapshot,v=h.source;h=h.subscribe;var _=cr;return e.memoizedState={refs:p,source:t,subscribe:r},s.useEffect(function(){p.getSnapshot=n,p.setSnapshot=u;var b=i(t._source);if(!Hi(a,b)){b=n(t._source),Hi(d,b)||(u(b),b=gu(_),o.mutableReadLanes|=b&o.pendingLanes),b=o.mutableReadLanes,o.entangledLanes|=b;for(var E=o.entanglements,w=b;0<w;){var k=31-ku(w),y=1<<k;E[k]|=b,w&=~y}}},[n,t,r]),s.useEffect(function(){return r(t._source,function(){var b=p.getSnapshot,E=p.setSnapshot;try{E(b(t._source));var w=gu(_);o.mutableReadLanes|=w&o.pendingLanes}catch(k){E(function(){throw k})}})},[t,r]),Hi(m,n)&&Hi(v,t)&&Hi(h,r)||(e={pending:null,dispatch:null,lastRenderedReducer:Xa,lastRenderedState:d},e.dispatch=u=fT.bind(null,cr,e),l.queue=e,l.baseQueue=null,d=E3(o,t,n),l.memoizedState=l.baseState=d),d}function hB(e,t,n){var r=qc();return dB(r,e,t,n)}function Q1(e){var t=wc();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e=t.queue={pending:null,dispatch:null,lastRenderedReducer:Xa,lastRenderedState:e},e=e.dispatch=fT.bind(null,cr,e),[t.memoizedState,e]}function Av(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=cr.updateQueue,t===null?(t={lastEffect:null},cr.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function _3(e){var t=wc();return e={current:e},t.memoizedState=e}function Nv(){return qc().memoizedState}function YE(e,t,n,r){var o=wc();cr.flags|=e,o.memoizedState=Av(1|t,n,void 0,r===void 0?null:r)}function uT(e,t,n,r){var o=qc();r=r===void 0?null:r;var i=void 0;if(so!==null){var a=so.memoizedState;if(i=a.destroy,r!==null&&sT(r,a.deps)){Av(t,n,i,r);return}}cr.flags|=e,o.memoizedState=Av(1|t,n,i,r)}function T3(e,t){return YE(516,4,e,t)}function Fv(e,t){return uT(516,4,e,t)}function pB(e,t){return uT(4,2,e,t)}function mB(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function gB(e,t,n){return n=n!=null?n.concat([e]):null,uT(4,2,mB.bind(null,t,e),n)}function cT(){}function vB(e,t){var n=qc();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&sT(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function bB(e,t){var n=qc();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&sT(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function cX(e,t){var n=zd();Pc(98>n?98:n,function(){e(!0)}),Pc(97<n?97:n,function(){var r=Wi.transition;Wi.transition=1;try{e(!1),t()}finally{Wi.transition=r}})}function fT(e,t,n){var r=vi(),o=gu(e),i={lane:o,action:n,eagerReducer:null,eagerState:null,next:null},a=t.pending;if(a===null?i.next=i:(i.next=a.next,a.next=i),t.pending=i,a=e.alternate,e===cr||a!==null&&a===cr)Ph=Cv=!0;else{if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var s=t.lastRenderedState,l=a(s,n);if(i.eagerReducer=a,i.eagerState=l,Hi(l,s))return}catch{}finally{}vu(e,o,r)}}var Iv={readContext:Xi,useCallback:Uo,useContext:Uo,useEffect:Uo,useImperativeHandle:Uo,useLayoutEffect:Uo,useMemo:Uo,useReducer:Uo,useRef:Uo,useState:Uo,useDebugValue:Uo,useDeferredValue:Uo,useTransition:Uo,useMutableSource:Uo,useOpaqueIdentifier:Uo,unstable_isNewReconciler:!1},fX={readContext:Xi,useCallback:function(e,t){return wc().memoizedState=[e,t===void 0?null:t],e},useContext:Xi,useEffect:T3,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,YE(4,2,mB.bind(null,t,e),n)},useLayoutEffect:function(e,t){return YE(4,2,e,t)},useMemo:function(e,t){var n=wc();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=wc();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e=r.queue={pending:null,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},e=e.dispatch=fT.bind(null,cr,e),[r.memoizedState,e]},useRef:_3,useState:Q1,useDebugValue:cT,useDeferredValue:function(e){var t=Q1(e),n=t[0],r=t[1];return T3(function(){var o=Wi.transition;Wi.transition=1;try{r(e)}finally{Wi.transition=o}},[e]),n},useTransition:function(){var e=Q1(!1),t=e[0];return e=cX.bind(null,e[1]),_3(e),[e,t]},useMutableSource:function(e,t,n){var r=wc();return r.memoizedState={refs:{getSnapshot:t,setSnapshot:null},source:e,subscribe:n},dB(r,e,t,n)},useOpaqueIdentifier:function(){if(rs){var e=!1,t=oX(function(){throw e||(e=!0,n("r:"+(_2++).toString(36))),Error(Ie(355))}),n=Q1(t)[1];return!(cr.mode&2)&&(cr.flags|=516,Av(5,function(){n("r:"+(_2++).toString(36))},void 0,null)),t}return t="r:"+(_2++).toString(36),Q1(t),t},unstable_isNewReconciler:!1},dX={readContext:Xi,useCallback:vB,useContext:Xi,useEffect:Fv,useImperativeHandle:gB,useLayoutEffect:pB,useMemo:bB,useReducer:V1,useRef:Nv,useState:function(){return V1(Xa)},useDebugValue:cT,useDeferredValue:function(e){var t=V1(Xa),n=t[0],r=t[1];return Fv(function(){var o=Wi.transition;Wi.transition=1;try{r(e)}finally{Wi.transition=o}},[e]),n},useTransition:function(){var e=V1(Xa)[0];return[Nv().current,e]},useMutableSource:hB,useOpaqueIdentifier:function(){return V1(Xa)[0]},unstable_isNewReconciler:!1},hX={readContext:Xi,useCallback:vB,useContext:Xi,useEffect:Fv,useImperativeHandle:gB,useLayoutEffect:pB,useMemo:bB,useReducer:Y1,useRef:Nv,useState:function(){return Y1(Xa)},useDebugValue:cT,useDeferredValue:function(e){var t=Y1(Xa),n=t[0],r=t[1];return Fv(function(){var o=Wi.transition;Wi.transition=1;try{r(e)}finally{Wi.transition=o}},[e]),n},useTransition:function(){var e=Y1(Xa)[0];return[Nv().current,e]},useMutableSource:hB,useOpaqueIdentifier:function(){return Y1(Xa)[0]},unstable_isNewReconciler:!1},pX=Hc.ReactCurrentOwner,Ea=!1;function Yo(e,t,n,r){t.child=e===null?cB(t,null,n,r):Sv(t,e.child,n,r)}function w3(e,t,n,r,o){n=n.render;var i=t.ref;return bd(t,o),r=lT(e,t,n,r,i,o),e!==null&&!Ea?(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~o,Zs(e,t,o)):(t.flags|=1,Yo(e,t,r,o),t.child)}function k3(e,t,n,r,o,i){if(e===null){var a=n.type;return typeof a=="function"&&!vT(a)&&a.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=a,yB(e,t,a,r,o,i)):(e=Fg(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}return a=e.child,!(o&i)&&(o=a.memoizedProps,n=n.compare,n=n!==null?n:g0,n(o,r)&&e.ref===t.ref)?Zs(e,t,i):(t.flags|=1,e=Cu(a,r),e.ref=t.ref,e.return=t,t.child=e)}function yB(e,t,n,r,o,i){if(e!==null&&g0(e.memoizedProps,r)&&e.ref===t.ref)if(Ea=!1,(i&o)!==0)e.flags&16384&&(Ea=!0);else return t.lanes=e.lanes,Zs(e,t,i);return QE(e,t,n,r,i)}function S2(e,t,n){var r=t.pendingProps,o=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden"||r.mode==="unstable-defer-without-hiding")if(!(t.mode&4))t.memoizedState={baseLanes:0},Im(t,n);else if(n&1073741824)t.memoizedState={baseLanes:0},Im(t,i!==null?i.baseLanes:n);else return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e},Im(t,e),null;else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,Im(t,r);return Yo(e,t,o,n),t.child}function EB(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=128)}function QE(e,t,n,r,o){var i=ei(n)?Dc:mo.current;return i=jd(t,i),bd(t,o),n=lT(e,t,n,r,i,o),e!==null&&!Ea?(t.updateQueue=e.updateQueue,t.flags&=-517,e.lanes&=~o,Zs(e,t,o)):(t.flags|=1,Yo(e,t,n,o),t.child)}function S3(e,t,n,r,o){if(ei(n)){var i=!0;Sg(t)}else i=!1;if(bd(t,o),t.stateNode===null)e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),lB(t,n,r),GE(t,n,r,o),r=!0;else if(e===null){var a=t.stateNode,s=t.memoizedProps;a.props=s;var l=a.context,u=n.contextType;typeof u=="object"&&u!==null?u=Xi(u):(u=ei(n)?Dc:mo.current,u=jd(t,u));var d=n.getDerivedStateFromProps,h=typeof d=="function"||typeof a.getSnapshotBeforeUpdate=="function";h||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(s!==r||l!==u)&&g3(t,a,r,u),Vl=!1;var p=t.memoizedState;a.state=p,y0(t,r,a,o),l=t.memoizedState,s!==r||p!==l||Jo.current||Vl?(typeof d=="function"&&(kv(t,n,d,r),l=t.memoizedState),(s=Vl||m3(t,n,s,r,p,l,u))?(h||typeof a.UNSAFE_componentWillMount!="function"&&typeof a.componentWillMount!="function"||(typeof a.componentWillMount=="function"&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount=="function"&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount=="function"&&(t.flags|=4)):(typeof a.componentDidMount=="function"&&(t.flags|=4),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=u,r=s):(typeof a.componentDidMount=="function"&&(t.flags|=4),r=!1)}else{a=t.stateNode,aB(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:ga(t.type,s),a.props=u,h=t.pendingProps,p=a.context,l=n.contextType,typeof l=="object"&&l!==null?l=Xi(l):(l=ei(n)?Dc:mo.current,l=jd(t,l));var m=n.getDerivedStateFromProps;(d=typeof m=="function"||typeof a.getSnapshotBeforeUpdate=="function")||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(s!==h||p!==l)&&g3(t,a,r,l),Vl=!1,p=t.memoizedState,a.state=p,y0(t,r,a,o);var v=t.memoizedState;s!==h||p!==v||Jo.current||Vl?(typeof m=="function"&&(kv(t,n,m,r),v=t.memoizedState),(u=Vl||m3(t,n,u,r,p,v,l))?(d||typeof a.UNSAFE_componentWillUpdate!="function"&&typeof a.componentWillUpdate!="function"||(typeof a.componentWillUpdate=="function"&&a.componentWillUpdate(r,v,l),typeof a.UNSAFE_componentWillUpdate=="function"&&a.UNSAFE_componentWillUpdate(r,v,l)),typeof a.componentDidUpdate=="function"&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate=="function"&&(t.flags|=256)):(typeof a.componentDidUpdate!="function"||s===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&p===e.memoizedState||(t.flags|=256),t.memoizedProps=r,t.memoizedState=v),a.props=r,a.state=v,a.context=l,r=u):(typeof a.componentDidUpdate!="function"||s===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&p===e.memoizedState||(t.flags|=256),r=!1)}return XE(e,t,n,r,i,o)}function XE(e,t,n,r,o,i){EB(e,t);var a=(t.flags&64)!==0;if(!r&&!a)return o&&c3(t,n,!1),Zs(e,t,i);r=t.stateNode,pX.current=t;var s=a&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&a?(t.child=Sv(t,e.child,null,i),t.child=Sv(t,null,s,i)):Yo(e,t,s,i),t.memoizedState=r.state,o&&c3(t,n,!0),t.child}function x3(e){var t=e.stateNode;t.pendingContext?u3(e,t.pendingContext,t.pendingContext!==t.context):t.context&&u3(e,t.context,!1),KE(e,t.containerInfo)}var Fm={dehydrated:null,retryLane:0};function C3(e,t,n){var r=t.pendingProps,o=Yn.current,i=!1,a;return(a=(t.flags&64)!==0)||(a=e!==null&&e.memoizedState===null?!1:(o&2)!==0),a?(i=!0,t.flags&=-65):e!==null&&e.memoizedState===null||r.fallback===void 0||r.unstable_avoidThisFallback===!0||(o|=1),Qn(Yn,o&1),e===null?(r.fallback!==void 0&&VE(t),e=r.children,o=r.fallback,i?(e=A3(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Fm,e):typeof r.unstable_expectedLoadTime=="number"?(e=A3(t,e,o,n),t.child.memoizedState={baseLanes:n},t.memoizedState=Fm,t.lanes=33554432,e):(n=bT({mode:"visible",children:e},t.mode,n,null),n.return=t,t.child=n)):e.memoizedState!==null?i?(r=F3(e,t,r.children,r.fallback,n),i=t.child,o=e.child.memoizedState,i.memoizedState=o===null?{baseLanes:n}:{baseLanes:o.baseLanes|n},i.childLanes=e.childLanes&~n,t.memoizedState=Fm,r):(n=N3(e,t,r.children,n),t.memoizedState=null,n):i?(r=F3(e,t,r.children,r.fallback,n),i=t.child,o=e.child.memoizedState,i.memoizedState=o===null?{baseLanes:n}:{baseLanes:o.baseLanes|n},i.childLanes=e.childLanes&~n,t.memoizedState=Fm,r):(n=N3(e,t,r.children,n),t.memoizedState=null,n)}function A3(e,t,n,r){var o=e.mode,i=e.child;return t={mode:"hidden",children:t},!(o&2)&&i!==null?(i.childLanes=0,i.pendingProps=t):i=bT(t,o,0,null),n=Td(n,o,r,null),i.return=e,n.return=e,i.sibling=n,e.child=i,n}function N3(e,t,n,r){var o=e.child;return e=o.sibling,n=Cu(o,{mode:"visible",children:n}),!(t.mode&2)&&(n.lanes=r),n.return=t,n.sibling=null,e!==null&&(e.nextEffect=null,e.flags=8,t.firstEffect=t.lastEffect=e),t.child=n}function F3(e,t,n,r,o){var i=t.mode,a=e.child;e=a.sibling;var s={mode:"hidden",children:n};return!(i&2)&&t.child!==a?(n=t.child,n.childLanes=0,n.pendingProps=s,a=n.lastEffect,a!==null?(t.firstEffect=n.firstEffect,t.lastEffect=a,a.nextEffect=null):t.firstEffect=t.lastEffect=null):n=Cu(a,s),e!==null?r=Cu(e,r):(r=Td(r,i,o,null),r.flags|=2),r.return=t,n.return=t,n.sibling=r,t.child=n,r}function I3(e,t){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),iB(e.return,t)}function x2(e,t,n,r,o,i){var a=e.memoizedState;a===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:o,lastEffect:i}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=r,a.tail=n,a.tailMode=o,a.lastEffect=i)}function B3(e,t,n){var r=t.pendingProps,o=r.revealOrder,i=r.tail;if(Yo(e,t,r.children,n),r=Yn.current,r&2)r=r&1|2,t.flags|=64;else{if(e!==null&&e.flags&64)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&I3(e,n);else if(e.tag===19)I3(e,n);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(Qn(Yn,r),!(t.mode&2))t.memoizedState=null;else switch(o){case"forwards":for(n=t.child,o=null;n!==null;)e=n.alternate,e!==null&&xv(e)===null&&(o=n),n=n.sibling;n=o,n===null?(o=t.child,t.child=null):(o=n.sibling,n.sibling=null),x2(t,!1,o,n,i,t.lastEffect);break;case"backwards":for(n=null,o=t.child,t.child=null;o!==null;){if(e=o.alternate,e!==null&&xv(e)===null){t.child=o;break}e=o.sibling,o.sibling=n,n=o,o=e}x2(t,!0,n,null,i,t.lastEffect);break;case"together":x2(t,!1,null,null,void 0,t.lastEffect);break;default:t.memoizedState=null}return t.child}function Zs(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Q0|=t.lanes,n&t.childLanes){if(e!==null&&t.child!==e.child)throw Error(Ie(153));if(t.child!==null){for(e=t.child,n=Cu(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Cu(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}return null}var _B,ZE,TB,wB;_B=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};ZE=function(){};TB=function(e,t,n,r){var o=e.memoizedProps;if(o!==r){e=t.stateNode,Tc(ns.current);var i=null;switch(n){case"input":o=SE(e,o),r=SE(e,r),i=[];break;case"option":o=AE(e,o),r=AE(e,r),i=[];break;case"select":o=Pn({},o,{value:void 0}),r=Pn({},r,{value:void 0}),i=[];break;case"textarea":o=NE(e,o),r=NE(e,r),i=[];break;default:typeof o.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=bv)}BE(n,r);var a;n=null;for(u in o)if(!r.hasOwnProperty(u)&&o.hasOwnProperty(u)&&o[u]!=null)if(u==="style"){var s=o[u];for(a in s)s.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(u0.hasOwnProperty(u)?i||(i=[]):(i=i||[]).push(u,null));for(u in r){var l=r[u];if(s=o!=null?o[u]:void 0,r.hasOwnProperty(u)&&l!==s&&(l!=null||s!=null))if(u==="style")if(s){for(a in s)!s.hasOwnProperty(a)||l&&l.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in l)l.hasOwnProperty(a)&&s[a]!==l[a]&&(n||(n={}),n[a]=l[a])}else n||(i||(i=[]),i.push(u,n)),n=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,s=s?s.__html:void 0,l!=null&&s!==l&&(i=i||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(i=i||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(u0.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&xn("scroll",e),i||s===l||(i=[])):typeof l=="object"&&l!==null&&l.$$typeof===L4?l.toString():(i=i||[]).push(u,l))}n&&(i=i||[]).push("style",n);var u=i;(t.updateQueue=u)&&(t.flags|=4)}};wB=function(e,t,n,r){n!==r&&(t.flags|=4)};function X1(e,t){if(!rs)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function mX(e,t,n){var r=t.pendingProps;switch(t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return ei(t.type)&&Ev(),null;case 3:return Hd(),An(Jo),An(mo),aT(),r=t.stateNode,r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Nm(t)?t.flags|=4:r.hydrate||(t.flags|=256)),ZE(t),null;case 5:iT(t);var o=Tc(_0.current);if(n=t.type,e!==null&&t.stateNode!=null)TB(e,t,n,r,o),e.ref!==t.ref&&(t.flags|=128);else{if(!r){if(t.stateNode===null)throw Error(Ie(166));return null}if(e=Tc(ns.current),Nm(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[ou]=t,r[yv]=i,n){case"dialog":xn("cancel",r),xn("close",r);break;case"iframe":case"object":case"embed":xn("load",r);break;case"video":case"audio":for(e=0;e<Eh.length;e++)xn(Eh[e],r);break;case"source":xn("error",r);break;case"img":case"image":case"link":xn("error",r),xn("load",r);break;case"details":xn("toggle",r);break;case"input":Bx(r,i),xn("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!i.multiple},xn("invalid",r);break;case"textarea":Ox(r,i),xn("invalid",r)}BE(n,i),e=null;for(var a in i)i.hasOwnProperty(a)&&(o=i[a],a==="children"?typeof o=="string"?r.textContent!==o&&(e=["children",o]):typeof o=="number"&&r.textContent!==""+o&&(e=["children",""+o]):u0.hasOwnProperty(a)&&o!=null&&a==="onScroll"&&xn("scroll",r));switch(n){case"input":wm(r),Rx(r,i,!0);break;case"textarea":wm(r),Dx(r);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(r.onclick=bv)}r=e,t.updateQueue=r,r!==null&&(t.flags|=4)}else{switch(a=o.nodeType===9?o:o.ownerDocument,e===FE.html&&(e=gI(n)),e===FE.html?n==="script"?(e=a.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=a.createElement(n,{is:r.is}):(e=a.createElement(n),n==="select"&&(a=e,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):e=a.createElementNS(e,n),e[ou]=t,e[yv]=r,_B(e,t,!1,!1),t.stateNode=e,a=RE(n,r),n){case"dialog":xn("cancel",e),xn("close",e),o=r;break;case"iframe":case"object":case"embed":xn("load",e),o=r;break;case"video":case"audio":for(o=0;o<Eh.length;o++)xn(Eh[o],e);o=r;break;case"source":xn("error",e),o=r;break;case"img":case"image":case"link":xn("error",e),xn("load",e),o=r;break;case"details":xn("toggle",e),o=r;break;case"input":Bx(e,r),o=SE(e,r),xn("invalid",e);break;case"option":o=AE(e,r);break;case"select":e._wrapperState={wasMultiple:!!r.multiple},o=Pn({},r,{value:void 0}),xn("invalid",e);break;case"textarea":Ox(e,r),o=NE(e,r),xn("invalid",e);break;default:o=r}BE(n,o);var s=o;for(i in s)if(s.hasOwnProperty(i)){var l=s[i];i==="style"?yI(e,l):i==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&vI(e,l)):i==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&c0(e,l):typeof l=="number"&&c0(e,""+l):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(u0.hasOwnProperty(i)?l!=null&&i==="onScroll"&&xn("scroll",e):l!=null&&B4(e,i,l,a))}switch(n){case"input":wm(e),Rx(e,r,!1);break;case"textarea":wm(e),Dx(e);break;case"option":r.value!=null&&e.setAttribute("value",""+wu(r.value));break;case"select":e.multiple=!!r.multiple,i=r.value,i!=null?pd(e,!!r.multiple,i,!1):r.defaultValue!=null&&pd(e,!!r.multiple,r.defaultValue,!0);break;default:typeof o.onClick=="function"&&(e.onclick=bv)}QI(n,r)&&(t.flags|=4)}t.ref!==null&&(t.flags|=128)}return null;case 6:if(e&&t.stateNode!=null)wB(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(Ie(166));n=Tc(_0.current),Tc(ns.current),Nm(t)?(r=t.stateNode,n=t.memoizedProps,r[ou]=t,r.nodeValue!==n&&(t.flags|=4)):(r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[ou]=t,t.stateNode=r)}return null;case 13:return An(Yn),r=t.memoizedState,t.flags&64?(t.lanes=n,t):(r=r!==null,n=!1,e===null?t.memoizedProps.fallback!==void 0&&Nm(t):n=e.memoizedState!==null,r&&!n&&t.mode&2&&(e===null&&t.memoizedProps.unstable_avoidThisFallback!==!0||Yn.current&1?Qr===0&&(Qr=3):((Qr===0||Qr===3)&&(Qr=4),Bo===null||!(Q0&134217727)&&!(n1&134217727)||Ed(Bo,fo))),(r||n)&&(t.flags|=4),null);case 4:return Hd(),ZE(t),e===null&&KI(t.stateNode.containerInfo),null;case 10:return rT(t),null;case 17:return ei(t.type)&&Ev(),null;case 19:if(An(Yn),r=t.memoizedState,r===null)return null;if(i=(t.flags&64)!==0,a=r.rendering,a===null)if(i)X1(r,!1);else{if(Qr!==0||e!==null&&e.flags&64)for(e=t.child;e!==null;){if(a=xv(e),a!==null){for(t.flags|=64,X1(r,!1),i=a.updateQueue,i!==null&&(t.updateQueue=i,t.flags|=4),r.lastEffect===null&&(t.firstEffect=null),t.lastEffect=r.lastEffect,r=n,n=t.child;n!==null;)i=n,e=r,i.flags&=2,i.nextEffect=null,i.firstEffect=null,i.lastEffect=null,a=i.alternate,a===null?(i.childLanes=0,i.lanes=e,i.child=null,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null,i.stateNode=null):(i.childLanes=a.childLanes,i.lanes=a.lanes,i.child=a.child,i.memoizedProps=a.memoizedProps,i.memoizedState=a.memoizedState,i.updateQueue=a.updateQueue,i.type=a.type,e=a.dependencies,i.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Qn(Yn,Yn.current&1|2),t.child}e=e.sibling}r.tail!==null&&co()>o_&&(t.flags|=64,i=!0,X1(r,!1),t.lanes=33554432)}else{if(!i)if(e=xv(a),e!==null){if(t.flags|=64,i=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),X1(r,!0),r.tail===null&&r.tailMode==="hidden"&&!a.alternate&&!rs)return t=t.lastEffect=r.lastEffect,t!==null&&(t.nextEffect=null),null}else 2*co()-r.renderingStartTime>o_&&n!==1073741824&&(t.flags|=64,i=!0,X1(r,!1),t.lanes=33554432);r.isBackwards?(a.sibling=t.child,t.child=a):(n=r.last,n!==null?n.sibling=a:t.child=a,r.last=a)}return r.tail!==null?(n=r.tail,r.rendering=n,r.tail=n.sibling,r.lastEffect=t.lastEffect,r.renderingStartTime=co(),n.sibling=null,t=Yn.current,Qn(Yn,i?t&1|2:t&1),n):null;case 23:case 24:return gT(),e!==null&&e.memoizedState!==null!=(t.memoizedState!==null)&&r.mode!=="unstable-defer-without-hiding"&&(t.flags|=4),null}throw Error(Ie(156,t.tag))}function gX(e){switch(e.tag){case 1:ei(e.type)&&Ev();var t=e.flags;return t&4096?(e.flags=t&-4097|64,e):null;case 3:if(Hd(),An(Jo),An(mo),aT(),t=e.flags,t&64)throw Error(Ie(285));return e.flags=t&-4097|64,e;case 5:return iT(e),null;case 13:return An(Yn),t=e.flags,t&4096?(e.flags=t&-4097|64,e):null;case 19:return An(Yn),null;case 4:return Hd(),null;case 10:return rT(e),null;case 23:case 24:return gT(),null;default:return null}}function dT(e,t){try{var n="",r=t;do n+=QY(r),r=r.return;while(r);var o=n}catch(i){o=` Error generating stack: `+i.message+` `+i.stack}return{value:e,source:t,stack:o}}function JE(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var vX=typeof WeakMap=="function"?WeakMap:Map;function kB(e,t,n){n=pu(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Rv||(Rv=!0,i_=r),JE(e,t)},n}function SB(e,t,n){n=pu(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var o=t.value;n.payload=function(){return JE(e,t),r(o)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){typeof r!="function"&&(Za===null?Za=new Set([this]):Za.add(this),JE(e,t));var a=t.stack;this.componentDidCatch(t.value,{componentStack:a!==null?a:""})}),n}var bX=typeof WeakSet=="function"?WeakSet:Set;function R3(e){var t=e.ref;if(t!==null)if(typeof t=="function")try{t(null)}catch(n){bu(e,n)}else t.current=null}function yX(e,t){switch(t.tag){case 0:case 11:case 15:case 22:return;case 1:if(t.flags&256&&e!==null){var n=e.memoizedProps,r=e.memoizedState;e=t.stateNode,t=e.getSnapshotBeforeUpdate(t.elementType===t.type?n:ga(t.type,n),r),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:t.flags&256&&J4(t.stateNode.containerInfo);return;case 5:case 6:case 4:case 17:return}throw Error(Ie(163))}function EX(e,t,n){switch(n.tag){case 0:case 11:case 15:case 22:if(t=n.updateQueue,t=t!==null?t.lastEffect:null,t!==null){e=t=t.next;do{if((e.tag&3)===3){var r=e.create;e.destroy=r()}e=e.next}while(e!==t)}if(t=n.updateQueue,t=t!==null?t.lastEffect:null,t!==null){e=t=t.next;do{var o=e;r=o.next,o=o.tag,o&4&&o&1&&(OB(n,e),AX(n,e)),e=r}while(e!==t)}return;case 1:e=n.stateNode,n.flags&4&&(t===null?e.componentDidMount():(r=n.elementType===n.type?t.memoizedProps:ga(n.type,t.memoizedProps),e.componentDidUpdate(r,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),t=n.updateQueue,t!==null&&p3(n,t,e);return;case 3:if(t=n.updateQueue,t!==null){if(e=null,n.child!==null)switch(n.child.tag){case 5:e=n.child.stateNode;break;case 1:e=n.child.stateNode}p3(n,t,e)}return;case 5:e=n.stateNode,t===null&&n.flags&4&&QI(n.type,n.memoizedProps)&&e.focus();return;case 6:return;case 4:return;case 12:return;case 13:n.memoizedState===null&&(n=n.alternate,n!==null&&(n=n.memoizedState,n!==null&&(n=n.dehydrated,n!==null&&NI(n))));return;case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(Ie(163))}function O3(e,t){for(var n=e;;){if(n.tag===5){var r=n.stateNode;if(t)r=r.style,typeof r.setProperty=="function"?r.setProperty("display","none","important"):r.display="none";else{r=n.stateNode;var o=n.memoizedProps.style;o=o!=null&&o.hasOwnProperty("display")?o.display:null,r.style.display=bI("display",o)}}else if(n.tag===6)n.stateNode.nodeValue=t?"":n.memoizedProps;else if((n.tag!==23&&n.tag!==24||n.memoizedState===null||n===e)&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===e)break;for(;n.sibling===null;){if(n.return===null||n.return===e)return;n=n.return}n.sibling.return=n.return,n=n.sibling}}function D3(e,t){if(Ac&&typeof Ac.onCommitFiberUnmount=="function")try{Ac.onCommitFiberUnmount(eT,t)}catch{}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(e=t.updateQueue,e!==null&&(e=e.lastEffect,e!==null)){var n=e=e.next;do{var r=n,o=r.destroy;if(r=r.tag,o!==void 0)if(r&4)OB(t,n);else{r=t;try{o()}catch(i){bu(r,i)}}n=n.next}while(n!==e)}break;case 1:if(R3(t),e=t.stateNode,typeof e.componentWillUnmount=="function")try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(i){bu(t,i)}break;case 5:R3(t);break;case 4:xB(e,t)}}function P3(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function M3(e){return e.tag===5||e.tag===3||e.tag===4}function L3(e){e:{for(var t=e.return;t!==null;){if(M3(t))break e;t=t.return}throw Error(Ie(160))}var n=t;switch(t=n.stateNode,n.tag){case 5:var r=!1;break;case 3:t=t.containerInfo,r=!0;break;case 4:t=t.containerInfo,r=!0;break;default:throw Error(Ie(161))}n.flags&16&&(c0(t,""),n.flags&=-17);e:t:for(n=e;;){for(;n.sibling===null;){if(n.return===null||M3(n.return)){n=null;break e}n=n.return}for(n.sibling.return=n.return,n=n.sibling;n.tag!==5&&n.tag!==6&&n.tag!==18;){if(n.flags&2||n.child===null||n.tag===4)continue t;n.child.return=n,n=n.child}if(!(n.flags&2)){n=n.stateNode;break e}}r?e_(e,n,t):t_(e,n,t)}function e_(e,t,n){var r=e.tag,o=r===5||r===6;if(o)e=o?e.stateNode:e.stateNode.instance,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=bv));else if(r!==4&&(e=e.child,e!==null))for(e_(e,t,n),e=e.sibling;e!==null;)e_(e,t,n),e=e.sibling}function t_(e,t,n){var r=e.tag,o=r===5||r===6;if(o)e=o?e.stateNode:e.stateNode.instance,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(t_(e,t,n),e=e.sibling;e!==null;)t_(e,t,n),e=e.sibling}function xB(e,t){for(var n=t,r=!1,o,i;;){if(!r){r=n.return;e:for(;;){if(r===null)throw Error(Ie(160));switch(o=r.stateNode,r.tag){case 5:i=!1;break e;case 3:o=o.containerInfo,i=!0;break e;case 4:o=o.containerInfo,i=!0;break e}r=r.return}r=!0}if(n.tag===5||n.tag===6){e:for(var a=e,s=n,l=s;;)if(D3(a,l),l.child!==null&&l.tag!==4)l.child.return=l,l=l.child;else{if(l===s)break e;for(;l.sibling===null;){if(l.return===null||l.return===s)break e;l=l.return}l.sibling.return=l.return,l=l.sibling}i?(a=o,s=n.stateNode,a.nodeType===8?a.parentNode.removeChild(s):a.removeChild(s)):o.removeChild(n.stateNode)}else if(n.tag===4){if(n.child!==null){o=n.stateNode.containerInfo,i=!0,n.child.return=n,n=n.child;continue}}else if(D3(e,n),n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return,n.tag===4&&(r=!1)}n.sibling.return=n.return,n=n.sibling}}function C2(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var r=n=n.next;do(r.tag&3)===3&&(e=r.destroy,r.destroy=void 0,e!==void 0&&e()),r=r.next;while(r!==n)}return;case 1:return;case 5:if(n=t.stateNode,n!=null){r=t.memoizedProps;var o=e!==null?e.memoizedProps:r;e=t.type;var i=t.updateQueue;if(t.updateQueue=null,i!==null){for(n[yv]=r,e==="input"&&r.type==="radio"&&r.name!=null&&pI(n,r),RE(e,o),t=RE(e,r),o=0;o<i.length;o+=2){var a=i[o],s=i[o+1];a==="style"?yI(n,s):a==="dangerouslySetInnerHTML"?vI(n,s):a==="children"?c0(n,s):B4(n,a,s,t)}switch(e){case"input":xE(n,r);break;case"textarea":mI(n,r);break;case"select":e=n._wrapperState.wasMultiple,n._wrapperState.wasMultiple=!!r.multiple,i=r.value,i!=null?pd(n,!!r.multiple,i,!1):e!==!!r.multiple&&(r.defaultValue!=null?pd(n,!!r.multiple,r.defaultValue,!0):pd(n,!!r.multiple,r.multiple?[]:"",!1))}}}return;case 6:if(t.stateNode===null)throw Error(Ie(162));t.stateNode.nodeValue=t.memoizedProps;return;case 3:n=t.stateNode,n.hydrate&&(n.hydrate=!1,NI(n.containerInfo));return;case 12:return;case 13:t.memoizedState!==null&&(mT=co(),O3(t.child,!0)),j3(t);return;case 19:j3(t);return;case 17:return;case 23:case 24:O3(t,t.memoizedState!==null);return}throw Error(Ie(163))}function j3(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new bX),t.forEach(function(r){var o=IX.bind(null,e,r);n.has(r)||(n.add(r),r.then(o,o))})}}function _X(e,t){return e!==null&&(e=e.memoizedState,e===null||e.dehydrated!==null)?(t=t.memoizedState,t!==null&&t.dehydrated===null):!1}var TX=Math.ceil,Bv=Hc.ReactCurrentDispatcher,hT=Hc.ReactCurrentOwner,ut=0,Bo=null,kr=null,fo=0,Mc=0,n_=Bu(0),Qr=0,Lb=null,t1=0,Q0=0,n1=0,pT=0,r_=null,mT=0,o_=1/0;function r1(){o_=co()+500}var je=null,Rv=!1,i_=null,Za=null,xu=!1,Mh=null,_h=90,a_=[],s_=[],nl=null,Lh=0,l_=null,Cg=-1,Vs=0,Ag=0,jh=null,Ng=!1;function vi(){return ut&48?co():Cg!==-1?Cg:Cg=co()}function gu(e){if(e=e.mode,!(e&2))return 1;if(!(e&4))return zd()===99?1:2;if(Vs===0&&(Vs=t1),uX.transition!==0){Ag!==0&&(Ag=r_!==null?r_.pendingLanes:0),e=Vs;var t=4186112&~Ag;return t&=-t,t===0&&(e=4186112&~e,t=e&-e,t===0&&(t=8192)),t}return e=zd(),ut&4&&e===98?e=gv(12,Vs):(e=dQ(e),e=gv(e,Vs)),e}function vu(e,t,n){if(50<Lh)throw Lh=0,l_=null,Error(Ie(185));if(e=jb(e,t),e===null)return null;Ib(e,t,n),e===Bo&&(n1|=t,Qr===4&&Ed(e,fo));var r=zd();t===1?ut&8&&!(ut&48)?u_(e):(Zi(e,n),ut===0&&(r1(),ps())):(!(ut&4)||r!==98&&r!==99||(nl===null?nl=new Set([e]):nl.add(e)),Zi(e,n)),r_=e}function jb(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}function Zi(e,t){for(var n=e.callbackNode,r=e.suspendedLanes,o=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes;0<a;){var s=31-ku(a),l=1<<s,u=i[s];if(u===-1){if(!(l&r)||l&o){u=t,Hf(l);var d=yn;i[s]=10<=d?u+250:6<=d?u+5e3:-1}}else u<=t&&(e.expiredLanes|=l);a&=~l}if(r=p0(e,e===Bo?fo:0),t=yn,r===0)n!==null&&(n!==T2&&$E(n),e.callbackNode=null,e.callbackPriority=0);else{if(n!==null){if(e.callbackPriority===t)return;n!==T2&&$E(n)}t===15?(n=u_.bind(null,e),Gs===null?(Gs=[n],xg=tT(Pb,oB)):Gs.push(n),n=T2):t===14?n=b0(99,u_.bind(null,e)):(n=hQ(t),n=b0(n,CB.bind(null,e))),e.callbackPriority=t,e.callbackNode=n}}function CB(e){if(Cg=-1,Ag=Vs=0,ut&48)throw Error(Ie(327));var t=e.callbackNode;if(Ru()&&e.callbackNode!==t)return null;var n=p0(e,e===Bo?fo:0);if(n===0)return null;var r=n,o=ut;ut|=16;var i=IB();(Bo!==e||fo!==r)&&(r1(),_d(e,r));do try{SX();break}catch(s){FB(e,s)}while(1);if(nT(),Bv.current=i,ut=o,kr!==null?r=0:(Bo=null,fo=0,r=Qr),t1&n1)_d(e,0);else if(r!==0){if(r===2&&(ut|=64,e.hydrate&&(e.hydrate=!1,J4(e.containerInfo)),n=PI(e),n!==0&&(r=Th(e,n))),r===1)throw t=Lb,_d(e,0),Ed(e,n),Zi(e,co()),t;switch(e.finishedWork=e.current.alternate,e.finishedLanes=n,r){case 0:case 1:throw Error(Ie(345));case 2:fc(e);break;case 3:if(Ed(e,n),(n&62914560)===n&&(r=mT+500-co(),10<r)){if(p0(e,0)!==0)break;if(o=e.suspendedLanes,(o&n)!==n){vi(),e.pingedLanes|=e.suspendedLanes&o;break}e.timeoutHandle=a3(fc.bind(null,e),r);break}fc(e);break;case 4:if(Ed(e,n),(n&4186112)===n)break;for(r=e.eventTimes,o=-1;0<n;){var a=31-ku(n);i=1<<a,a=r[a],a>o&&(o=a),n&=~i}if(n=o,n=co()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*TX(n/1960))-n,10<n){e.timeoutHandle=a3(fc.bind(null,e),n);break}fc(e);break;case 5:fc(e);break;default:throw Error(Ie(329))}}return Zi(e,co()),e.callbackNode===t?CB.bind(null,e):null}function Ed(e,t){for(t&=~pT,t&=~n1,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-ku(t),r=1<<n;e[n]=-1,t&=~r}}function u_(e){if(ut&48)throw Error(Ie(327));if(Ru(),e===Bo&&e.expiredLanes&fo){var t=fo,n=Th(e,t);t1&n1&&(t=p0(e,t),n=Th(e,t))}else t=p0(e,0),n=Th(e,t);if(e.tag!==0&&n===2&&(ut|=64,e.hydrate&&(e.hydrate=!1,J4(e.containerInfo)),t=PI(e),t!==0&&(n=Th(e,t))),n===1)throw n=Lb,_d(e,0),Ed(e,t),Zi(e,co()),n;return e.finishedWork=e.current.alternate,e.finishedLanes=t,fc(e),Zi(e,co()),null}function wX(){if(nl!==null){var e=nl;nl=null,e.forEach(function(t){t.expiredLanes|=24&t.pendingLanes,Zi(t,co())})}ps()}function AB(e,t){var n=ut;ut|=1;try{return e(t)}finally{ut=n,ut===0&&(r1(),ps())}}function NB(e,t){var n=ut;ut&=-2,ut|=8;try{return e(t)}finally{ut=n,ut===0&&(r1(),ps())}}function Im(e,t){Qn(n_,Mc),Mc|=t,t1|=t}function gT(){Mc=n_.current,An(n_)}function _d(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,rX(n)),kr!==null)for(n=kr.return;n!==null;){var r=n;switch(r.tag){case 1:r=r.type.childContextTypes,r!=null&&Ev();break;case 3:Hd(),An(Jo),An(mo),aT();break;case 5:iT(r);break;case 4:Hd();break;case 13:An(Yn);break;case 19:An(Yn);break;case 10:rT(r);break;case 23:case 24:gT()}n=n.return}Bo=e,kr=Cu(e.current,null),fo=Mc=t1=t,Qr=0,Lb=null,pT=n1=Q0=0}function FB(e,t){do{var n=kr;try{if(nT(),Dh.current=Iv,Cv){for(var r=cr.memoizedState;r!==null;){var o=r.queue;o!==null&&(o.pending=null),r=r.next}Cv=!1}if(T0=0,Yr=so=cr=null,Ph=!1,hT.current=null,n===null||n.return===null){Qr=1,Lb=t,kr=null;break}e:{var i=e,a=n.return,s=n,l=t;if(t=fo,s.flags|=2048,s.firstEffect=s.lastEffect=null,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l;if(!(s.mode&2)){var d=s.alternate;d?(s.updateQueue=d.updateQueue,s.memoizedState=d.memoizedState,s.lanes=d.lanes):(s.updateQueue=null,s.memoizedState=null)}var h=(Yn.current&1)!==0,p=a;do{var m;if(m=p.tag===13){var v=p.memoizedState;if(v!==null)m=v.dehydrated!==null;else{var _=p.memoizedProps;m=_.fallback===void 0?!1:_.unstable_avoidThisFallback!==!0?!0:!h}}if(m){var b=p.updateQueue;if(b===null){var E=new Set;E.add(u),p.updateQueue=E}else b.add(u);if(!(p.mode&2)){if(p.flags|=64,s.flags|=16384,s.flags&=-2981,s.tag===1)if(s.alternate===null)s.tag=17;else{var w=pu(-1,1);w.tag=2,mu(s,w)}s.lanes|=1;break e}l=void 0,s=t;var k=i.pingCache;if(k===null?(k=i.pingCache=new vX,l=new Set,k.set(u,l)):(l=k.get(u),l===void 0&&(l=new Set,k.set(u,l))),!l.has(s)){l.add(s);var y=FX.bind(null,i,u,s);u.then(y,y)}p.flags|=4096,p.lanes=t;break e}p=p.return}while(p!==null);l=Error((hd(s.type)||"A React component")+` suspended while rendering, but no fallback UI was specified. Add a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.`)}Qr!==5&&(Qr=2),l=dT(l,s),p=a;do{switch(p.tag){case 3:i=l,p.flags|=4096,t&=-t,p.lanes|=t;var F=kB(p,i,t);h3(p,F);break e;case 1:i=l;var C=p.type,A=p.stateNode;if(!(p.flags&64)&&(typeof C.getDerivedStateFromError=="function"||A!==null&&typeof A.componentDidCatch=="function"&&(Za===null||!Za.has(A)))){p.flags|=4096,t&=-t,p.lanes|=t;var P=SB(p,i,t);h3(p,P);break e}}p=p.return}while(p!==null)}RB(n)}catch(I){t=I,kr===n&&n!==null&&(kr=n=n.return);continue}break}while(1)}function IB(){var e=Bv.current;return Bv.current=Iv,e===null?Iv:e}function Th(e,t){var n=ut;ut|=16;var r=IB();Bo===e&&fo===t||_d(e,t);do try{kX();break}catch(o){FB(e,o)}while(1);if(nT(),ut=n,Bv.current=r,kr!==null)throw Error(Ie(261));return Bo=null,fo=0,Qr}function kX(){for(;kr!==null;)BB(kr)}function SX(){for(;kr!==null&&!aX();)BB(kr)}function BB(e){var t=DB(e.alternate,e,Mc);e.memoizedProps=e.pendingProps,t===null?RB(e):kr=t,hT.current=null}function RB(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&2048){if(n=gX(t),n!==null){n.flags&=2047,kr=n;return}e!==null&&(e.firstEffect=e.lastEffect=null,e.flags|=2048)}else{if(n=mX(n,t,Mc),n!==null){kr=n;return}if(n=t,n.tag!==24&&n.tag!==23||n.memoizedState===null||Mc&1073741824||!(n.mode&4)){for(var r=0,o=n.child;o!==null;)r|=o.lanes|o.childLanes,o=o.sibling;n.childLanes=r}e!==null&&!(e.flags&2048)&&(e.firstEffect===null&&(e.firstEffect=t.firstEffect),t.lastEffect!==null&&(e.lastEffect!==null&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1<t.flags&&(e.lastEffect!==null?e.lastEffect.nextEffect=t:e.firstEffect=t,e.lastEffect=t))}if(t=t.sibling,t!==null){kr=t;return}kr=t=e}while(t!==null);Qr===0&&(Qr=5)}function fc(e){var t=zd();return Pc(99,xX.bind(null,e,t)),null}function xX(e,t){do Ru();while(Mh!==null);if(ut&48)throw Error(Ie(327));var n=e.finishedWork;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(Ie(177));e.callbackNode=null;var r=n.lanes|n.childLanes,o=r,i=e.pendingLanes&~o;e.pendingLanes=o,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=o,e.mutableReadLanes&=o,e.entangledLanes&=o,o=e.entanglements;for(var a=e.eventTimes,s=e.expirationTimes;0<i;){var l=31-ku(i),u=1<<l;o[l]=0,a[l]=-1,s[l]=-1,i&=~u}if(nl!==null&&!(r&24)&&nl.has(e)&&nl.delete(e),e===Bo&&(kr=Bo=null,fo=0),1<n.flags?n.lastEffect!==null?(n.lastEffect.nextEffect=n,r=n.firstEffect):r=n:r=n.firstEffect,r!==null){if(o=ut,ut|=32,hT.current=null,y2=Tg,a=Jx(),jE(a)){if("selectionStart"in a)s={start:a.selectionStart,end:a.selectionEnd};else e:if(s=(s=a.ownerDocument)&&s.defaultView||window,(u=s.getSelection&&s.getSelection())&&u.rangeCount!==0){s=u.anchorNode,i=u.anchorOffset,l=u.focusNode,u=u.focusOffset;try{s.nodeType,l.nodeType}catch{s=null;break e}var d=0,h=-1,p=-1,m=0,v=0,_=a,b=null;t:for(;;){for(var E;_!==s||i!==0&&_.nodeType!==3||(h=d+i),_!==l||u!==0&&_.nodeType!==3||(p=d+u),_.nodeType===3&&(d+=_.nodeValue.length),(E=_.firstChild)!==null;)b=_,_=E;for(;;){if(_===a)break t;if(b===s&&++m===i&&(h=d),b===l&&++v===u&&(p=d),(E=_.nextSibling)!==null)break;_=b,b=_.parentNode}_=E}s=h===-1||p===-1?null:{start:h,end:p}}else s=null;s=s||{start:0,end:0}}else s=null;E2={focusedElem:a,selectionRange:s},Tg=!1,jh=null,Ng=!1,je=r;do try{CX()}catch(I){if(je===null)throw Error(Ie(330));bu(je,I),je=je.nextEffect}while(je!==null);jh=null,je=r;do try{for(a=e;je!==null;){var w=je.flags;if(w&16&&c0(je.stateNode,""),w&128){var k=je.alternate;if(k!==null){var y=k.ref;y!==null&&(typeof y=="function"?y(null):y.current=null)}}switch(w&1038){case 2:L3(je),je.flags&=-3;break;case 6:L3(je),je.flags&=-3,C2(je.alternate,je);break;case 1024:je.flags&=-1025;break;case 1028:je.flags&=-1025,C2(je.alternate,je);break;case 4:C2(je.alternate,je);break;case 8:s=je,xB(a,s);var F=s.alternate;P3(s),F!==null&&P3(F)}je=je.nextEffect}}catch(I){if(je===null)throw Error(Ie(330));bu(je,I),je=je.nextEffect}while(je!==null);if(y=E2,k=Jx(),w=y.focusedElem,a=y.selectionRange,k!==w&&w&&w.ownerDocument&&$I(w.ownerDocument.documentElement,w)){for(a!==null&&jE(w)&&(k=a.start,y=a.end,y===void 0&&(y=k),"selectionStart"in w?(w.selectionStart=k,w.selectionEnd=Math.min(y,w.value.length)):(y=(k=w.ownerDocument||document)&&k.defaultView||window,y.getSelection&&(y=y.getSelection(),s=w.textContent.length,F=Math.min(a.start,s),a=a.end===void 0?F:Math.min(a.end,s),!y.extend&&F>a&&(s=a,a=F,F=s),s=Zx(w,F),i=Zx(w,a),s&&i&&(y.rangeCount!==1||y.anchorNode!==s.node||y.anchorOffset!==s.offset||y.focusNode!==i.node||y.focusOffset!==i.offset)&&(k=k.createRange(),k.setStart(s.node,s.offset),y.removeAllRanges(),F>a?(y.addRange(k),y.extend(i.node,i.offset)):(k.setEnd(i.node,i.offset),y.addRange(k)))))),k=[],y=w;y=y.parentNode;)y.nodeType===1&&k.push({element:y,left:y.scrollLeft,top:y.scrollTop});for(typeof w.focus=="function"&&w.focus(),w=0;w<k.length;w++)y=k[w],y.element.scrollLeft=y.left,y.element.scrollTop=y.top}Tg=!!y2,E2=y2=null,e.current=n,je=r;do try{for(w=e;je!==null;){var C=je.flags;if(C&36&&EX(w,je.alternate,je),C&128){k=void 0;var A=je.ref;if(A!==null){var P=je.stateNode;switch(je.tag){case 5:k=P;break;default:k=P}typeof A=="function"?A(k):A.current=k}}je=je.nextEffect}}catch(I){if(je===null)throw Error(Ie(330));bu(je,I),je=je.nextEffect}while(je!==null);je=null,lX(),ut=o}else e.current=n;if(xu)xu=!1,Mh=e,_h=t;else for(je=r;je!==null;)t=je.nextEffect,je.nextEffect=null,je.flags&8&&(C=je,C.sibling=null,C.stateNode=null),je=t;if(r=e.pendingLanes,r===0&&(Za=null),r===1?e===l_?Lh++:(Lh=0,l_=e):Lh=0,n=n.stateNode,Ac&&typeof Ac.onCommitFiberRoot=="function")try{Ac.onCommitFiberRoot(eT,n,void 0,(n.current.flags&64)===64)}catch{}if(Zi(e,co()),Rv)throw Rv=!1,e=i_,i_=null,e;return ut&8||ps(),null}function CX(){for(;je!==null;){var e=je.alternate;Ng||jh===null||(je.flags&8?Lx(je,jh)&&(Ng=!0):je.tag===13&&_X(e,je)&&Lx(je,jh)&&(Ng=!0));var t=je.flags;t&256&&yX(e,je),!(t&512)||xu||(xu=!0,b0(97,function(){return Ru(),null})),je=je.nextEffect}}function Ru(){if(_h!==90){var e=97<_h?97:_h;return _h=90,Pc(e,NX)}return!1}function AX(e,t){a_.push(t,e),xu||(xu=!0,b0(97,function(){return Ru(),null}))}function OB(e,t){s_.push(t,e),xu||(xu=!0,b0(97,function(){return Ru(),null}))}function NX(){if(Mh===null)return!1;var e=Mh;if(Mh=null,ut&48)throw Error(Ie(331));var t=ut;ut|=32;var n=s_;s_=[];for(var r=0;r<n.length;r+=2){var o=n[r],i=n[r+1],a=o.destroy;if(o.destroy=void 0,typeof a=="function")try{a()}catch(l){if(i===null)throw Error(Ie(330));bu(i,l)}}for(n=a_,a_=[],r=0;r<n.length;r+=2){o=n[r],i=n[r+1];try{var s=o.create;o.destroy=s()}catch(l){if(i===null)throw Error(Ie(330));bu(i,l)}}for(s=e.current.firstEffect;s!==null;)e=s.nextEffect,s.nextEffect=null,s.flags&8&&(s.sibling=null,s.stateNode=null),s=e;return ut=t,ps(),!0}function z3(e,t,n){t=dT(n,t),t=kB(e,t,1),mu(e,t),t=vi(),e=jb(e,1),e!==null&&(Ib(e,1,t),Zi(e,t))}function bu(e,t){if(e.tag===3)z3(e,e,t);else for(var n=e.return;n!==null;){if(n.tag===3){z3(n,e,t);break}else if(n.tag===1){var r=n.stateNode;if(typeof n.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Za===null||!Za.has(r))){e=dT(t,e);var o=SB(n,e,1);if(mu(n,o),o=vi(),n=jb(n,1),n!==null)Ib(n,1,o),Zi(n,o);else if(typeof r.componentDidCatch=="function"&&(Za===null||!Za.has(r)))try{r.componentDidCatch(t,e)}catch{}break}}n=n.return}}function FX(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=vi(),e.pingedLanes|=e.suspendedLanes&n,Bo===e&&(fo&n)===n&&(Qr===4||Qr===3&&(fo&62914560)===fo&&500>co()-mT?_d(e,0):pT|=n),Zi(e,t)}function IX(e,t){var n=e.stateNode;n!==null&&n.delete(t),t=0,t===0&&(t=e.mode,t&2?t&4?(Vs===0&&(Vs=t1),t=Uf(62914560&~Vs),t===0&&(t=4194304)):t=zd()===99?1:2:t=1),n=vi(),e=jb(e,t),e!==null&&(Ib(e,t,n),Zi(e,n))}var DB;DB=function(e,t,n){var r=t.lanes;if(e!==null)if(e.memoizedProps!==t.pendingProps||Jo.current)Ea=!0;else if(n&r)Ea=!!(e.flags&16384);else{switch(Ea=!1,t.tag){case 3:x3(t),k2();break;case 5:v3(t);break;case 1:ei(t.type)&&Sg(t);break;case 4:KE(t,t.stateNode.containerInfo);break;case 10:r=t.memoizedProps.value;var o=t.type._context;Qn(_v,o._currentValue),o._currentValue=r;break;case 13:if(t.memoizedState!==null)return n&t.child.childLanes?C3(e,t,n):(Qn(Yn,Yn.current&1),t=Zs(e,t,n),t!==null?t.sibling:null);Qn(Yn,Yn.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&64){if(r)return B3(e,t,n);t.flags|=64}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),Qn(Yn,Yn.current),r)break;return null;case 23:case 24:return t.lanes=0,S2(e,t,n)}return Zs(e,t,n)}else Ea=!1;switch(t.lanes=0,t.tag){case 2:if(r=t.type,e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,o=jd(t,mo.current),bd(t,n),o=lT(null,t,r,e,o,n),t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,ei(r)){var i=!0;Sg(t)}else i=!1;t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,oT(t);var a=r.getDerivedStateFromProps;typeof a=="function"&&kv(t,r,a,e),o.updater=Mb,t.stateNode=o,o._reactInternals=t,GE(t,r,e,n),t=XE(null,t,r,!0,i,n)}else t.tag=0,Yo(null,t,o,n),t=t.child;return t;case 16:o=t.elementType;e:{switch(e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=o._init,o=i(o._payload),t.type=o,i=t.tag=RX(o),e=ga(o,e),i){case 0:t=QE(null,t,o,e,n);break e;case 1:t=S3(null,t,o,e,n);break e;case 11:t=w3(null,t,o,e,n);break e;case 14:t=k3(null,t,o,ga(o.type,e),r,n);break e}throw Error(Ie(306,o,""))}return t;case 0:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ga(r,o),QE(e,t,r,o,n);case 1:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ga(r,o),S3(e,t,r,o,n);case 3:if(x3(t),r=t.updateQueue,e===null||r===null)throw Error(Ie(282));if(r=t.pendingProps,o=t.memoizedState,o=o!==null?o.element:null,aB(e,t),y0(t,r,null,n),r=t.memoizedState.element,r===o)k2(),t=Zs(e,t,n);else{if(o=t.stateNode,(i=o.hydrate)&&(iu=vd(t.stateNode.containerInfo.firstChild),Xs=t,i=rs=!0),i){if(e=o.mutableSourceEagerHydrationData,e!=null)for(o=0;o<e.length;o+=2)i=e[o],i._workInProgressVersionPrimary=e[o+1],yd.push(i);for(n=cB(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|1024,n=n.sibling}else Yo(e,t,r,n),k2();t=t.child}return t;case 5:return v3(t),e===null&&VE(t),r=t.type,o=t.pendingProps,i=e!==null?e.memoizedProps:null,a=o.children,UE(r,o)?a=null:i!==null&&UE(r,i)&&(t.flags|=16),EB(e,t),Yo(e,t,a,n),t.child;case 6:return e===null&&VE(t),null;case 13:return C3(e,t,n);case 4:return KE(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Sv(t,null,r,n):Yo(e,t,r,n),t.child;case 11:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ga(r,o),w3(e,t,r,o,n);case 7:return Yo(e,t,t.pendingProps,n),t.child;case 8:return Yo(e,t,t.pendingProps.children,n),t.child;case 12:return Yo(e,t,t.pendingProps.children,n),t.child;case 10:e:{r=t.type._context,o=t.pendingProps,a=t.memoizedProps,i=o.value;var s=t.type._context;if(Qn(_v,s._currentValue),s._currentValue=i,a!==null)if(s=a.value,i=Hi(s,i)?0:(typeof r._calculateChangedBits=="function"?r._calculateChangedBits(s,i):1073741823)|0,i===0){if(a.children===o.children&&!Jo.current){t=Zs(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var l=s.dependencies;if(l!==null){a=s.child;for(var u=l.firstContext;u!==null;){if(u.context===r&&u.observedBits&i){s.tag===1&&(u=pu(-1,n&-n),u.tag=2,mu(s,u)),s.lanes|=n,u=s.alternate,u!==null&&(u.lanes|=n),iB(s.return,n),l.lanes|=n;break}u=u.next}}else a=s.tag===10&&s.type===t.type?null:s.child;if(a!==null)a.return=s;else for(a=s;a!==null;){if(a===t){a=null;break}if(s=a.sibling,s!==null){s.return=a.return,a=s;break}a=a.return}s=a}Yo(e,t,o.children,n),t=t.child}return t;case 9:return o=t.type,i=t.pendingProps,r=i.children,bd(t,n),o=Xi(o,i.unstable_observedBits),r=r(o),t.flags|=1,Yo(e,t,r,n),t.child;case 14:return o=t.type,i=ga(o,t.pendingProps),i=ga(o.type,i),k3(e,t,o,i,r,n);case 15:return yB(e,t,t.type,t.pendingProps,r,n);case 17:return r=t.type,o=t.pendingProps,o=t.elementType===r?o:ga(r,o),e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),t.tag=1,ei(r)?(e=!0,Sg(t)):e=!1,bd(t,n),lB(t,r,o),GE(t,r,o,n),XE(null,t,r,!0,e,n);case 19:return B3(e,t,n);case 23:return S2(e,t,n);case 24:return S2(e,t,n)}throw Error(Ie(156,t.tag))};function BX(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.flags=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childLanes=this.lanes=0,this.alternate=null}function Ui(e,t,n,r){return new BX(e,t,n,r)}function vT(e){return e=e.prototype,!(!e||!e.isReactComponent)}function RX(e){if(typeof e=="function")return vT(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Ab)return 11;if(e===Nb)return 14}return 2}function Cu(e,t){var n=e.alternate;return n===null?(n=Ui(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.nextEffect=null,n.firstEffect=null,n.lastEffect=null),n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function Fg(e,t,n,r,o,i){var a=2;if(r=e,typeof e=="function")vT(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case tu:return Td(n.children,o,i,t);case fI:a=8,o|=16;break;case R4:a=8,o|=1;break;case Ah:return e=Ui(12,n,t,o|8),e.elementType=Ah,e.type=Ah,e.lanes=i,e;case Nh:return e=Ui(13,n,t,o),e.type=Nh,e.elementType=Nh,e.lanes=i,e;case dv:return e=Ui(19,n,t,o),e.elementType=dv,e.lanes=i,e;case j4:return bT(n,o,i,t);case kE:return e=Ui(24,n,t,o),e.elementType=kE,e.lanes=i,e;default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case O4:a=10;break e;case D4:a=9;break e;case Ab:a=11;break e;case Nb:a=14;break e;case P4:a=16,r=null;break e;case M4:a=22;break e}throw Error(Ie(130,e==null?e:typeof e,""))}return t=Ui(a,n,t,o),t.elementType=e,t.type=r,t.lanes=i,t}function Td(e,t,n,r){return e=Ui(7,e,r,t),e.lanes=n,e}function bT(e,t,n,r){return e=Ui(23,e,r,t),e.elementType=j4,e.lanes=n,e}function A2(e,t,n){return e=Ui(6,e,null,t),e.lanes=n,e}function N2(e,t,n){return t=Ui(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function OX(e,t,n){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.pendingContext=this.context=null,this.hydrate=n,this.callbackNode=null,this.callbackPriority=0,this.eventTimes=d2(0),this.expirationTimes=d2(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=d2(0),this.mutableSourceEagerHydrationData=null}function DX(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:yc,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function Ov(e,t,n,r){var o=t.current,i=vi(),a=gu(o);e:if(n){n=n._reactInternals;t:{if(Uc(n)!==n||n.tag!==1)throw Error(Ie(170));var s=n;do{switch(s.tag){case 3:s=s.stateNode.context;break t;case 1:if(ei(s.type)){s=s.stateNode.__reactInternalMemoizedMergedChildContext;break t}}s=s.return}while(s!==null);throw Error(Ie(171))}if(n.tag===1){var l=n.type;if(ei(l)){n=ZI(n,l,s);break e}}n=s}else n=Su;return t.context===null?t.context=n:t.pendingContext=n,t=pu(i,a),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),mu(o,t),vu(o,a,i),a}function F2(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function H3(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function yT(e,t){H3(e,t),(e=e.alternate)&&H3(e,t)}function PX(){return null}function ET(e,t,n){var r=n!=null&&n.hydrationOptions!=null&&n.hydrationOptions.mutableSources||null;if(n=new OX(e,t,n!=null&&n.hydrate===!0),t=Ui(3,null,null,t===2?7:t===1?3:0),n.current=t,t.stateNode=n,oT(t),e[e1]=n.current,KI(e.nodeType===8?e.parentNode:e),r)for(e=0;e<r.length;e++){t=r[e];var o=t._getVersion;o=o(t._source),n.mutableSourceEagerHydrationData==null?n.mutableSourceEagerHydrationData=[t,o]:n.mutableSourceEagerHydrationData.push(t,o)}this._internalRoot=n}ET.prototype.render=function(e){Ov(e,this._internalRoot,null,null)};ET.prototype.unmount=function(){var e=this._internalRoot,t=e.containerInfo;Ov(null,e,null,function(){t[e1]=null})};function X0(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function MX(e,t){if(t||(t=e?e.nodeType===9?e.documentElement:e.firstChild:null,t=!(!t||t.nodeType!==1||!t.hasAttribute("data-reactroot"))),!t)for(var n;n=e.lastChild;)e.removeChild(n);return new ET(e,0,t?{hydrate:!0}:void 0)}function zb(e,t,n,r,o){var i=n._reactRootContainer;if(i){var a=i._internalRoot;if(typeof o=="function"){var s=o;o=function(){var u=F2(a);s.call(u)}}Ov(t,a,e,o)}else{if(i=n._reactRootContainer=MX(n,r),a=i._internalRoot,typeof o=="function"){var l=o;o=function(){var u=F2(a);l.call(u)}}NB(function(){Ov(t,a,e,o)})}return F2(a)}xI=function(e){if(e.tag===13){var t=vi();vu(e,4,t),yT(e,4)}};$4=function(e){if(e.tag===13){var t=vi();vu(e,67108864,t),yT(e,67108864)}};CI=function(e){if(e.tag===13){var t=vi(),n=gu(e);vu(e,n,t),yT(e,n)}};AI=function(e,t){return t()};OE=function(e,t,n){switch(t){case"input":if(xE(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var o=Db(r);if(!o)throw Error(Ie(90));hI(r),xE(r,o)}}}break;case"textarea":mI(e,n);break;case"select":t=n.value,t!=null&&pd(e,!!n.multiple,t,!1)}};H4=AB;TI=function(e,t,n,r,o){var i=ut;ut|=4;try{return Pc(98,e.bind(null,t,n,r,o))}finally{ut=i,ut===0&&(r1(),ps())}};U4=function(){!(ut&49)&&(wX(),Ru())};wI=function(e,t){var n=ut;ut|=2;try{return e(t)}finally{ut=n,ut===0&&(r1(),ps())}};function PB(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!X0(t))throw Error(Ie(200));return DX(e,t,null,n)}var LX={Events:[V0,td,Db,EI,_I,Ru,{current:!1}]},Z1={findFiberByHostInstance:_c,bundleType:0,version:"17.0.2",rendererPackageName:"react-dom"},jX={bundleType:Z1.bundleType,version:Z1.version,rendererPackageName:Z1.rendererPackageName,rendererConfig:Z1.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Hc.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=SI(e),e===null?null:e.stateNode},findFiberByHostInstance:Z1.findFiberByHostInstance||PX,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Bm=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Bm.isDisabled&&Bm.supportsFiber)try{eT=Bm.inject(jX),Ac=Bm}catch{}}ea.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=LX;ea.createPortal=PB;ea.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(Ie(188)):Error(Ie(268,Object.keys(e)));return e=SI(t),e=e===null?null:e.stateNode,e};ea.flushSync=function(e,t){var n=ut;if(n&48)return e(t);ut|=1;try{if(e)return Pc(99,e.bind(null,t))}finally{ut=n,ps()}};ea.hydrate=function(e,t,n){if(!X0(t))throw Error(Ie(200));return zb(null,e,t,!0,n)};ea.render=function(e,t,n){if(!X0(t))throw Error(Ie(200));return zb(null,e,t,!1,n)};ea.unmountComponentAtNode=function(e){if(!X0(e))throw Error(Ie(40));return e._reactRootContainer?(NB(function(){zb(null,null,e,!1,function(){e._reactRootContainer=null,e[e1]=null})}),!0):!1};ea.unstable_batchedUpdates=AB;ea.unstable_createPortal=function(e,t){return PB(e,t,2<arguments.length&&arguments[2]!==void 0?arguments[2]:null)};ea.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!X0(n))throw Error(Ie(200));if(e==null||e._reactInternals===void 0)throw Error(Ie(38));return zb(e,t,n,!1,r)};ea.version="17.0.2";function MB(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(MB)}catch(e){console.error(e)}}MB(),sI.exports=ea;var _T=sI.exports;const LB=xr(_T);var zX=ml(),HX=Cr(function(e,t){return Sb(oe(oe({},e),{rtl:t}))}),UX=function(e){var t=e.theme,n=e.dir,r=ls(t)?"rtl":"ltr",o=ls()?"rtl":"ltr",i=n||r;return{rootDir:i!==r||i!==o?i:n,needsTheme:i!==r}},jB=T.forwardRef(function(e,t){var n=e.className,r=e.theme,o=e.applyTheme,i=e.applyThemeToBody,a=e.styles,s=zX(a,{theme:r,applyTheme:o,className:n}),l=T.useRef(null);return $X(i,s,l),jF(l),T.createElement(T.Fragment,null,qX(e,s,l,t))});jB.displayName="FabricBase";function qX(e,t,n,r){var o=t.root,i=e.as,a=i===void 0?"div":i,s=e.dir,l=e.theme,u=Zr(e,W0,["dir"]),d=UX(e),h=d.rootDir,p=d.needsTheme,m=T.createElement(a,oe({dir:h},u,{className:o,ref:G0(n,r)}));return p&&(m=T.createElement(kK,{settings:{theme:HX(l,s==="rtl")}},m)),m}function $X(e,t,n){var r=t.bodyThemed;return T.useEffect(function(){if(e){var o=ss(n.current);if(o)return o.body.classList.add(r),function(){o.body.classList.remove(r)}}},[r,e,n]),n}var I2={fontFamily:"inherit"},WX={root:"ms-Fabric",bodyThemed:"ms-Fabric-bodyThemed"},GX=function(e){var t=e.theme,n=e.className,r=e.applyTheme,o=hs(WX,t);return{root:[o.root,t.fonts.medium,{color:t.palette.neutralPrimary,selectors:{"& button":I2,"& input":I2,"& textarea":I2}},r&&{color:t.semanticColors.bodyText,backgroundColor:t.semanticColors.bodyBackground},n],bodyThemed:[{backgroundColor:t.semanticColors.bodyBackground}]}},KX=gl(jB,GX,void 0,{scope:"Fabric"}),nu={},VX;function YX(e,t){nu[e]||(nu[e]=[]),nu[e].push(t)}function QX(e,t){if(nu[e]){var n=nu[e].indexOf(t);n>=0&&(nu[e].splice(n,1),nu[e].length===0&&delete nu[e])}}function XX(){return VX}var ZX=ml(),zB=T.forwardRef(function(e,t){var n=T.useRef(null),r=G0(n,t),o=T.useRef(),i=T.useState(!1),a=i[0],s=i[1],l=SY(),u=e.eventBubblingEnabled,d=e.styles,h=e.theme,p=e.className,m=e.children,v=e.hostId,_=e.onLayerDidMount,b=_===void 0?function(){}:_,E=e.onLayerMounted,w=E===void 0?function(){}:E,k=e.onLayerWillUnmount,y=e.insertFirst,F=ZX(d,{theme:h,className:p,isNotHost:!v}),C=function(){if(l){if(v)return l.getElementById(v);var I=XX();return I?l.querySelector(I):l.body}},A=function(){k==null||k();var I=o.current;o.current=void 0,I&&I.parentNode&&I.parentNode.removeChild(I)},P=function(){var I=C();if(!(!l||!I)){A();var j=l.createElement("div");j.className=F.root,QG(j),ZG(j,n.current),y?I.insertBefore(j,I.firstChild):I.appendChild(j),o.current=j,s(!0)}};return i0(function(){return P(),v&&YX(v,P),function(){A(),v&&QX(v,P)}},[v]),T.useEffect(function(){o.current&&a&&(w==null||w(),b==null||b(),s(!1))},[a,w,b]),T.createElement("span",{className:"ms-layer",ref:r},o.current&&_T.createPortal(T.createElement(KX,oe({},!u&&eZ(),{className:F.content}),m),o.current))});zB.displayName="LayerBase";var Rm,JX=function(e){e.eventPhase===Event.BUBBLING_PHASE&&e.type!=="mouseenter"&&e.type!=="mouseleave"&&e.type!=="touchstart"&&e.type!=="touchend"&&e.stopPropagation()};function eZ(){return Rm||(Rm={},["onClick","onContextMenu","onDoubleClick","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onMouseDown","onMouseEnter","onMouseLeave","onMouseMove","onMouseOver","onMouseOut","onMouseUp","onTouchMove","onTouchStart","onTouchCancel","onTouchEnd","onKeyDown","onKeyPress","onKeyUp","onFocus","onBlur","onChange","onInput","onInvalid","onSubmit"].forEach(function(e){return Rm[e]=JX})),Rm}var tZ={root:"ms-Layer",rootNoHost:"ms-Layer--fixed",content:"ms-Layer-content"},nZ=function(e){var t=e.className,n=e.isNotHost,r=e.theme,o=hs(tZ,r);return{root:[o.root,r.fonts.medium,n&&[o.rootNoHost,{position:"fixed",zIndex:Dd.Layer,top:0,left:0,bottom:0,right:0,visibility:"hidden"}],t],content:[o.content,{visibility:"visible"}]}},rZ=gl(zB,nZ,void 0,{scope:"Layer",fields:["hostId","theme","styles"]}),HB=T.forwardRef(function(e,t){var n=e.layerProps,r=e.doNotLayer,o=pl(e,["layerProps","doNotLayer"]),i=T.createElement(WY,oe({},o,{doNotLayer:r,ref:t}));return r?i:T.createElement(rZ,oe({},n),i)});HB.displayName="Callout";var Dv;(function(e){e[e.default=0]="default",e[e.image=1]="image",e[e.Default=1e5]="Default",e[e.Image=100001]="Image"})(Dv||(Dv={}));var Xo;(function(e){e[e.center=0]="center",e[e.contain=1]="contain",e[e.cover=2]="cover",e[e.none=3]="none",e[e.centerCover=4]="centerCover",e[e.centerContain=5]="centerContain"})(Xo||(Xo={}));var w0;(function(e){e[e.landscape=0]="landscape",e[e.portrait=1]="portrait"})(w0||(w0={}));var No;(function(e){e[e.notLoaded=0]="notLoaded",e[e.loaded=1]="loaded",e[e.error=2]="error",e[e.errorLoaded=3]="errorLoaded"})(No||(No={}));var oZ=ml(),iZ=/\.svg$/i,aZ="fabricImage";function sZ(e,t){var n=e.onLoadingStateChange,r=e.onLoad,o=e.onError,i=e.src,a=T.useState(No.notLoaded),s=a[0],l=a[1];i0(function(){l(No.notLoaded)},[i]),T.useEffect(function(){if(s===No.notLoaded){var h=t.current?i&&t.current.naturalWidth>0&&t.current.naturalHeight>0||t.current.complete&&iZ.test(i):!1;h&&l(No.loaded)}}),T.useEffect(function(){n==null||n(s)},[s]);var u=T.useCallback(function(h){r==null||r(h),i&&l(No.loaded)},[i,r]),d=T.useCallback(function(h){o==null||o(h),l(No.error)},[o]);return[s,u,d]}var UB=T.forwardRef(function(e,t){var n=T.useRef(),r=T.useRef(),o=sZ(e,r),i=o[0],a=o[1],s=o[2],l=Zr(e,DK,["width","height"]),u=e.src,d=e.alt,h=e.width,p=e.height,m=e.shouldFadeIn,v=m===void 0?!0:m,_=e.shouldStartVisible,b=e.className,E=e.imageFit,w=e.role,k=e.maximizeFrame,y=e.styles,F=e.theme,C=e.loading,A=lZ(e,i,r,n),P=oZ(y,{theme:F,className:b,width:h,height:p,maximizeFrame:k,shouldFadeIn:v,shouldStartVisible:_,isLoaded:i===No.loaded||i===No.notLoaded&&e.shouldStartVisible,isLandscape:A===w0.landscape,isCenter:E===Xo.center,isCenterContain:E===Xo.centerContain,isCenterCover:E===Xo.centerCover,isContain:E===Xo.contain,isCover:E===Xo.cover,isNone:E===Xo.none,isError:i===No.error,isNotImageFit:E===void 0});return T.createElement("div",{className:P.root,style:{width:h,height:p},ref:n},T.createElement("img",oe({},l,{onLoad:a,onError:s,key:aZ+e.src||"",className:P.image,ref:G0(r,t),src:u,alt:d,role:w,loading:C})))});UB.displayName="ImageBase";function lZ(e,t,n,r){var o=T.useRef(t),i=T.useRef();return(i===void 0||o.current===No.notLoaded&&t===No.loaded)&&(i.current=uZ(e,t,n,r)),o.current=t,i.current}function uZ(e,t,n,r){var o=e.imageFit,i=e.width,a=e.height;if(e.coverStyle!==void 0)return e.coverStyle;if(t===No.loaded&&(o===Xo.cover||o===Xo.contain||o===Xo.centerContain||o===Xo.centerCover)&&n.current&&r.current){var s=void 0;typeof i=="number"&&typeof a=="number"&&o!==Xo.centerContain&&o!==Xo.centerCover?s=i/a:s=r.current.clientWidth/r.current.clientHeight;var l=n.current.naturalWidth/n.current.naturalHeight;if(l>s)return w0.landscape}return w0.portrait}var cZ={root:"ms-Image",rootMaximizeFrame:"ms-Image--maximizeFrame",image:"ms-Image-image",imageCenter:"ms-Image-image--center",imageContain:"ms-Image-image--contain",imageCover:"ms-Image-image--cover",imageCenterContain:"ms-Image-image--centerContain",imageCenterCover:"ms-Image-image--centerCover",imageNone:"ms-Image-image--none",imageLandscape:"ms-Image-image--landscape",imagePortrait:"ms-Image-image--portrait"},fZ=function(e){var t=e.className,n=e.width,r=e.height,o=e.maximizeFrame,i=e.isLoaded,a=e.shouldFadeIn,s=e.shouldStartVisible,l=e.isLandscape,u=e.isCenter,d=e.isContain,h=e.isCover,p=e.isCenterContain,m=e.isCenterCover,v=e.isNone,_=e.isError,b=e.isNotImageFit,E=e.theme,w=hs(cZ,E),k={position:"absolute",left:"50% /* @noflip */",top:"50%",transform:"translate(-50%,-50%)"},y=ur(),F=y!==void 0&&y.navigator.msMaxTouchPoints===void 0,C=d&&l||h&&!l?{width:"100%",height:"auto"}:{width:"auto",height:"100%"};return{root:[w.root,E.fonts.medium,{overflow:"hidden"},o&&[w.rootMaximizeFrame,{height:"100%",width:"100%"}],i&&a&&!s&&bc.fadeIn400,(u||d||h||p||m)&&{position:"relative"},t],image:[w.image,{display:"block",opacity:0},i&&["is-loaded",{opacity:1}],u&&[w.imageCenter,k],d&&[w.imageContain,F&&{width:"100%",height:"100%",objectFit:"contain"},!F&&C,!F&&k],h&&[w.imageCover,F&&{width:"100%",height:"100%",objectFit:"cover"},!F&&C,!F&&k],p&&[w.imageCenterContain,l&&{maxWidth:"100%"},!l&&{maxHeight:"100%"},k],m&&[w.imageCenterCover,l&&{maxHeight:"100%"},!l&&{maxWidth:"100%"},k],v&&[w.imageNone,{width:"auto",height:"auto"}],b&&[!!n&&!r&&{height:"auto",width:"100%"},!n&&!!r&&{height:"100%",width:"auto"},!!n&&!!r&&{height:"100%",width:"100%"}],l&&w.imageLandscape,!l&&w.imagePortrait,!i&&"is-notLoaded",a&&"is-fadeIn",_&&"is-error"]}},TT=gl(UB,fZ,void 0,{scope:"Image"},!0);TT.displayName="Image";var Nc=q0({root:{display:"inline-block"},placeholder:["ms-Icon-placeHolder",{width:"1em"}],image:["ms-Icon-imageContainer",{overflow:"hidden"}]}),qB="ms-Icon",dZ=function(e){var t=e.className,n=e.iconClassName,r=e.isPlaceholder,o=e.isImage,i=e.styles;return{root:[r&&Nc.placeholder,Nc.root,o&&Nc.image,n,t,i&&i.root,i&&i.imageContainer]}},$B=Cr(function(e){var t=JK(e)||{subset:{},code:void 0},n=t.code,r=t.subset;return n?{children:n,iconClassName:r.className,fontFamily:r.fontFace&&r.fontFace.fontFamily,mergeImageProps:r.mergeImageProps}:null},void 0,!0),c_=function(e){var t=e.iconName,n=e.className,r=e.style,o=r===void 0?{}:r,i=$B(t)||{},a=i.iconClassName,s=i.children,l=i.fontFamily,u=i.mergeImageProps,d=Zr(e,fr),h=e["aria-label"]||e.title,p=e["aria-label"]||e["aria-labelledby"]||e.title?{role:u?void 0:"img"}:{"aria-hidden":!0},m=s;return u&&typeof s=="object"&&typeof s.props=="object"&&h&&(m=T.cloneElement(s,{alt:h})),T.createElement("i",oe({"data-icon-name":t},p,d,u?{title:void 0,"aria-label":void 0}:{},{className:Ys(qB,Nc.root,a,!t&&Nc.placeholder,n),style:oe({fontFamily:l},o)}),m)};Cr(function(e,t,n){return c_({iconName:e,className:t,"aria-label":n})});var hZ=ml({cacheSize:100}),pZ=function(e){yi(t,e);function t(n){var r=e.call(this,n)||this;return r._onImageLoadingStateChange=function(o){r.props.imageProps&&r.props.imageProps.onLoadingStateChange&&r.props.imageProps.onLoadingStateChange(o),o===No.error&&r.setState({imageLoadError:!0})},r.state={imageLoadError:!1},r}return t.prototype.render=function(){var n=this.props,r=n.children,o=n.className,i=n.styles,a=n.iconName,s=n.imageErrorAs,l=n.theme,u=typeof a=="string"&&a.length===0,d=!!this.props.imageProps||this.props.iconType===Dv.image||this.props.iconType===Dv.Image,h=$B(a)||{},p=h.iconClassName,m=h.children,v=h.mergeImageProps,_=hZ(i,{theme:l,className:o,iconClassName:p,isImage:d,isPlaceholder:u}),b=d?"span":"i",E=Zr(this.props,fr,["aria-label"]),w=this.state.imageLoadError,k=oe(oe({},this.props.imageProps),{onLoadingStateChange:this._onImageLoadingStateChange}),y=w&&s||TT,F=this.props["aria-label"]||this.props.ariaLabel,C=k.alt||F||this.props.title,A=!!(C||this.props["aria-labelledby"]||k["aria-label"]||k["aria-labelledby"]),P=A?{role:d||v?void 0:"img","aria-label":d||v?void 0:C}:{"aria-hidden":!0},I=m;return v&&m&&typeof m=="object"&&C&&(I=T.cloneElement(m,{alt:C})),T.createElement(b,oe({"data-icon-name":a},P,E,v?{title:void 0,"aria-label":void 0}:{},{className:_.root}),d?T.createElement(y,oe({},k)):r||I)},t}(T.Component),sl=gl(pZ,dZ,void 0,{scope:"Icon"},!0);sl.displayName="Icon";var mZ=function(e){var t=e.className,n=e.imageProps,r=Zr(e,fr,["aria-label","aria-labelledby","title","aria-describedby"]),o=n.alt||e["aria-label"],i=o||e["aria-labelledby"]||e.title||n["aria-label"]||n["aria-labelledby"]||n.title,a={"aria-labelledby":e["aria-labelledby"],"aria-describedby":e["aria-describedby"],title:e.title},s=i?{}:{"aria-hidden":!0};return T.createElement("div",oe({},s,r,{className:Ys(qB,Nc.root,Nc.image,t)}),T.createElement(TT,oe({},a,n,{alt:i?o:""})))},f_={none:0,all:1,inputOnly:2},ao;(function(e){e[e.vertical=0]="vertical",e[e.horizontal=1]="horizontal",e[e.bidirectional=2]="bidirectional",e[e.domOrder=3]="domOrder"})(ao||(ao={}));var d_=void 0;try{d_=window}catch{}function vl(e){if(!(typeof d_>"u")){var t=e;return t&&t.ownerDocument&&t.ownerDocument.defaultView?t.ownerDocument.defaultView:d_}}function Z0(e){if(!(typeof document>"u")){var t=e;return t&&t.ownerDocument?t.ownerDocument:document}}var J1={none:0,insertNode:1,appendChild:2},U3="__stylesheet__",gZ=typeof navigator<"u"&&/rv:11.0/.test(navigator.userAgent),qf={};try{qf=window||{}}catch{}var _f,o1=function(){function e(t,n){var r,o,i,a,s,l;this._rules=[],this._preservedRules=[],this._counter=0,this._keyToClassName={},this._onInsertRuleCallbacks=[],this._onResetCallbacks=[],this._classNameToArgs={},this._config=oe({injectionMode:typeof document>"u"?J1.none:J1.insertNode,defaultPrefix:"css",namespace:void 0,cspSettings:void 0},t),this._classNameToArgs=(r=n==null?void 0:n.classNameToArgs)!==null&&r!==void 0?r:this._classNameToArgs,this._counter=(o=n==null?void 0:n.counter)!==null&&o!==void 0?o:this._counter,this._keyToClassName=(a=(i=this._config.classNameCache)!==null&&i!==void 0?i:n==null?void 0:n.keyToClassName)!==null&&a!==void 0?a:this._keyToClassName,this._preservedRules=(s=n==null?void 0:n.preservedRules)!==null&&s!==void 0?s:this._preservedRules,this._rules=(l=n==null?void 0:n.rules)!==null&&l!==void 0?l:this._rules}return e.getInstance=function(){if(_f=qf[U3],!_f||_f._lastStyleElement&&_f._lastStyleElement.ownerDocument!==document){var t=(qf==null?void 0:qf.FabricConfig)||{},n=new e(t.mergeStyles,t.serializedStylesheet);_f=n,qf[U3]=n}return _f},e.prototype.serialize=function(){return JSON.stringify({classNameToArgs:this._classNameToArgs,counter:this._counter,keyToClassName:this._keyToClassName,preservedRules:this._preservedRules,rules:this._rules})},e.prototype.setConfig=function(t){this._config=oe(oe({},this._config),t)},e.prototype.onReset=function(t){var n=this;return this._onResetCallbacks.push(t),function(){n._onResetCallbacks=n._onResetCallbacks.filter(function(r){return r!==t})}},e.prototype.onInsertRule=function(t){var n=this;return this._onInsertRuleCallbacks.push(t),function(){n._onInsertRuleCallbacks=n._onInsertRuleCallbacks.filter(function(r){return r!==t})}},e.prototype.getClassName=function(t){var n=this._config.namespace,r=t||this._config.defaultPrefix;return(n?n+"-":"")+r+"-"+this._counter++},e.prototype.cacheClassName=function(t,n,r,o){this._keyToClassName[n]=t,this._classNameToArgs[t]={args:r,rules:o}},e.prototype.classNameFromKey=function(t){return this._keyToClassName[t]},e.prototype.getClassNameCache=function(){return this._keyToClassName},e.prototype.argsFromClassName=function(t){var n=this._classNameToArgs[t];return n&&n.args},e.prototype.insertedRulesFromClassName=function(t){var n=this._classNameToArgs[t];return n&&n.rules},e.prototype.insertRule=function(t,n){var r=this._config.injectionMode,o=r!==J1.none?this._getStyleElement():void 0;if(n&&this._preservedRules.push(t),o)switch(r){case J1.insertNode:var i=o.sheet;try{i.insertRule(t,i.cssRules.length)}catch{}break;case J1.appendChild:o.appendChild(document.createTextNode(t));break}else this._rules.push(t);this._config.onInsertRule&&this._config.onInsertRule(t),this._onInsertRuleCallbacks.forEach(function(a){return a()})},e.prototype.getRules=function(t){return(t?this._preservedRules.join(""):"")+this._rules.join("")},e.prototype.reset=function(){this._rules=[],this._counter=0,this._classNameToArgs={},this._keyToClassName={},this._onResetCallbacks.forEach(function(t){return t()})},e.prototype.resetKeys=function(){this._keyToClassName={}},e.prototype._getStyleElement=function(){var t=this;return!this._styleElement&&typeof document<"u"&&(this._styleElement=this._createStyleElement(),gZ||window.requestAnimationFrame(function(){t._styleElement=void 0})),this._styleElement},e.prototype._createStyleElement=function(){var t=document.head,n=document.createElement("style"),r=null;n.setAttribute("data-merge-styles","true");var o=this._config.cspSettings;if(o&&o.nonce&&n.setAttribute("nonce",o.nonce),this._lastStyleElement)r=this._lastStyleElement.nextElementSibling;else{var i=this._findPlaceholderStyleTag();i?r=i.nextElementSibling:r=t.childNodes[0]}return t.insertBefore(n,t.contains(r)?r:null),this._lastStyleElement=n,n},e.prototype._findPlaceholderStyleTag=function(){var t=document.head;return t?t.querySelector("style[data-merge-styles]"):null},e}();function vZ(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=[],r=[],o=o1.getInstance();function i(a){for(var s=0,l=a;s<l.length;s++){var u=l[s];if(u)if(typeof u=="string")if(u.indexOf(" ")>=0)i(u.split(" "));else{var d=o.argsFromClassName(u);d?i(d):n.indexOf(u)===-1&&n.push(u)}else Array.isArray(u)?i(u):typeof u=="object"&&r.push(u)}}return i(e),{classes:n,objects:r}}function WB(e){wd!==e&&(wd=e)}function GB(){return wd===void 0&&(wd=typeof document<"u"&&!!document.documentElement&&document.documentElement.getAttribute("dir")==="rtl"),wd}var wd;wd=GB();function KB(){return{rtl:GB()}}var q3={};function bZ(e,t){var n=e[t];n.charAt(0)!=="-"&&(e[t]=q3[n]=q3[n]||n.replace(/([A-Z])/g,"-$1").toLowerCase())}var Om;function yZ(){var e;if(!Om){var t=typeof document<"u"?document:void 0,n=typeof navigator<"u"?navigator:void 0,r=(e=n==null?void 0:n.userAgent)===null||e===void 0?void 0:e.toLowerCase();t?Om={isWebkit:!!(t&&"WebkitAppearance"in t.documentElement.style),isMoz:!!(r&&r.indexOf("firefox")>-1),isOpera:!!(r&&r.indexOf("opera")>-1),isMs:!!(n&&(/rv:11.0/i.test(n.userAgent)||/Edge\/\d./i.test(navigator.userAgent)))}:Om={isWebkit:!0,isMoz:!0,isOpera:!0,isMs:!0}}return Om}var $3={"user-select":1};function EZ(e,t){var n=yZ(),r=e[t];if($3[r]){var o=e[t+1];$3[r]&&(n.isWebkit&&e.push("-webkit-"+r,o),n.isMoz&&e.push("-moz-"+r,o),n.isMs&&e.push("-ms-"+r,o),n.isOpera&&e.push("-o-"+r,o))}}var _Z=["column-count","font-weight","flex","flex-grow","flex-shrink","fill-opacity","opacity","order","z-index","zoom"];function TZ(e,t){var n=e[t],r=e[t+1];if(typeof r=="number"){var o=_Z.indexOf(n)>-1,i=n.indexOf("--")>-1,a=o||i?"":"px";e[t+1]=""+r+a}}var Dm,Yl="left",Ql="right",wZ="@noflip",W3=(Dm={},Dm[Yl]=Ql,Dm[Ql]=Yl,Dm),G3={"w-resize":"e-resize","sw-resize":"se-resize","nw-resize":"ne-resize"};function kZ(e,t,n){if(e.rtl){var r=t[n];if(!r)return;var o=t[n+1];if(typeof o=="string"&&o.indexOf(wZ)>=0)t[n+1]=o.replace(/\s*(?:\/\*\s*)?\@noflip\b(?:\s*\*\/)?\s*?/g,"");else if(r.indexOf(Yl)>=0)t[n]=r.replace(Yl,Ql);else if(r.indexOf(Ql)>=0)t[n]=r.replace(Ql,Yl);else if(String(o).indexOf(Yl)>=0)t[n+1]=o.replace(Yl,Ql);else if(String(o).indexOf(Ql)>=0)t[n+1]=o.replace(Ql,Yl);else if(W3[r])t[n]=W3[r];else if(G3[o])t[n+1]=G3[o];else switch(r){case"margin":case"padding":t[n+1]=xZ(o);break;case"box-shadow":t[n+1]=SZ(o,0);break}}}function SZ(e,t){var n=e.split(" "),r=parseInt(n[t],10);return n[0]=n[0].replace(String(r),String(r*-1)),n.join(" ")}function xZ(e){if(typeof e=="string"){var t=e.split(" ");if(t.length===4)return t[0]+" "+t[3]+" "+t[2]+" "+t[1]}return e}function CZ(e){for(var t=[],n=0,r=0,o=0;o<e.length;o++)switch(e[o]){case"(":r++;break;case")":r&&r--;break;case" ":case" ":r||(o>n&&t.push(e.substring(n,o)),n=o+1);break}return n<e.length&&t.push(e.substring(n)),t}var AZ="displayName";function NZ(e){var t=e&&e["&"];return t?t.displayName:void 0}var VB=/\:global\((.+?)\)/g;function FZ(e){if(!VB.test(e))return e;for(var t=[],n=/\:global\((.+?)\)/g,r=null;r=n.exec(e);)r[1].indexOf(",")>-1&&t.push([r.index,r.index+r[0].length,r[1].split(",").map(function(o){return":global("+o.trim()+")"}).join(", ")]);return t.reverse().reduce(function(o,i){var a=i[0],s=i[1],l=i[2],u=o.slice(0,a),d=o.slice(s);return u+l+d},e)}function K3(e,t){return e.indexOf(":global(")>=0?e.replace(VB,"$1"):e.indexOf(":")===0?t+e:e.indexOf("&")<0?t+" "+e:e}function V3(e,t,n,r){t===void 0&&(t={__order:[]}),n.indexOf("@")===0?(n=n+"{"+e,kd([r],t,n)):n.indexOf(",")>-1?FZ(n).split(",").map(function(o){return o.trim()}).forEach(function(o){return kd([r],t,K3(o,e))}):kd([r],t,K3(n,e))}function kd(e,t,n){t===void 0&&(t={__order:[]}),n===void 0&&(n="&");var r=o1.getInstance(),o=t[n];o||(o={},t[n]=o,t.__order.push(n));for(var i=0,a=e;i<a.length;i++){var s=a[i];if(typeof s=="string"){var l=r.argsFromClassName(s);l&&kd(l,t,n)}else if(Array.isArray(s))kd(s,t,n);else for(var u in s)if(s.hasOwnProperty(u)){var d=s[u];if(u==="selectors"){var h=s.selectors;for(var p in h)h.hasOwnProperty(p)&&V3(n,t,p,h[p])}else typeof d=="object"?d!==null&&V3(n,t,u,d):d!==void 0&&(u==="margin"||u==="padding"?IZ(o,u,d):o[u]=d)}}return t}function IZ(e,t,n){var r=typeof n=="string"?CZ(n):[n];r.length===0&&r.push(n),r[r.length-1]==="!important"&&(r=r.slice(0,-1).map(function(o){return o+" !important"})),e[t+"Top"]=r[0],e[t+"Right"]=r[1]||r[0],e[t+"Bottom"]=r[2]||r[0],e[t+"Left"]=r[3]||r[1]||r[0]}function BZ(e,t){for(var n=[e.rtl?"rtl":"ltr"],r=!1,o=0,i=t.__order;o<i.length;o++){var a=i[o];n.push(a);var s=t[a];for(var l in s)s.hasOwnProperty(l)&&s[l]!==void 0&&(r=!0,n.push(l,s[l]))}return r?n.join(""):void 0}function YB(e,t){return t<=0?"":t===1?e:e+YB(e,t-1)}function QB(e,t){if(!t)return"";var n=[];for(var r in t)t.hasOwnProperty(r)&&r!==AZ&&t[r]!==void 0&&n.push(r,t[r]);for(var o=0;o<n.length;o+=2)bZ(n,o),TZ(n,o),kZ(e,n,o),EZ(n,o);for(var o=1;o<n.length;o+=4)n.splice(o,1,":",n[o],";");return n.join("")}function RZ(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=kd(t),o=BZ(e,r);if(o){var i=o1.getInstance(),a={className:i.classNameFromKey(o),key:o,args:t};if(!a.className){a.className=i.getClassName(NZ(r));for(var s=[],l=0,u=r.__order;l<u.length;l++){var d=u[l];s.push(d,QB(e,r[d]))}a.rulesToInsert=s}return a}}function OZ(e,t){t===void 0&&(t=1);var n=o1.getInstance(),r=e.className,o=e.key,i=e.args,a=e.rulesToInsert;if(a){for(var s=0;s<a.length;s+=2){var l=a[s+1];if(l){var u=a[s];u=u.replace(/&/g,YB("."+e.className,t));var d=u+"{"+l+"}"+(u.indexOf("@")===0?"}":"");n.insertRule(d)}}n.cacheClassName(r,o,i,a)}}function DZ(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=RZ.apply(void 0,Yi([e],t));return r?(OZ(r,e.specificityMultiplier),r.className):""}function XB(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return PZ(e,KB())}function PZ(e,t){var n=e instanceof Array?e:[e],r=vZ(n),o=r.classes,i=r.objects;return i.length&&o.push(DZ(t||{},i)),o.join(" ")}function MZ(e){var t=o1.getInstance(),n=QB(KB(),e),r=t.classNameFromKey(n);if(!r){var o=t.getClassName();t.insertRule("@font-face{"+n+"}",!0),t.cacheClassName(o,n,[],["font-face",n])}}XB({overflow:"hidden !important"});var Y3="data-is-scrollable";function LZ(e){for(var t=e,n=Z0(e);t&&t!==n.body;){if(t.getAttribute(Y3)==="true")return t;t=t.parentElement}for(t=e;t&&t!==n.body;){if(t.getAttribute(Y3)!=="false"){var r=getComputedStyle(t),o=r?r.getPropertyValue("overflow-y"):"";if(o&&(o==="scroll"||o==="auto"))return t}t=t.parentElement}return(!t||t===n.body)&&(t=vl(e)),t}var B2="__globalSettings__",wT="__callbacks__",jZ=0,zZ=function(){function e(){}return e.getValue=function(t,n){var r=h_();return r[t]===void 0&&(r[t]=typeof n=="function"?n():n),r[t]},e.setValue=function(t,n){var r=h_(),o=r[wT],i=r[t];if(n!==i){r[t]=n;var a={oldValue:i,value:n,key:t};for(var s in o)o.hasOwnProperty(s)&&o[s](a)}return n},e.addChangeListener=function(t){var n=t.__id__,r=Q3();n||(n=t.__id__=String(jZ++)),r[n]=t},e.removeChangeListener=function(t){var n=Q3();delete n[t.__id__]},e}();function h_(){var e,t=vl(),n=t||{};return n[B2]||(n[B2]=(e={},e[wT]={},e)),n[B2]}function Q3(){var e=h_();return e[wT]}var Oi={backspace:8,tab:9,enter:13,shift:16,ctrl:17,alt:18,pauseBreak:19,capslock:20,escape:27,space:32,pageUp:33,pageDown:34,end:35,home:36,left:37,up:38,right:39,down:40,insert:45,del:46,zero:48,one:49,two:50,three:51,four:52,five:53,six:54,seven:55,eight:56,nine:57,colon:58,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,leftWindow:91,rightWindow:92,select:93,zero_numpad:96,one_numpad:97,two_numpad:98,three_numpad:99,four_numpad:100,five_numpad:101,six_numpad:102,seven_numpad:103,eight_numpad:104,nine_numpad:105,multiply:106,add:107,subtract:109,decimalPoint:110,divide: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,scrollLock:145,semicolon:186,equalSign:187,comma:188,dash:189,period:190,forwardSlash:191,graveAccent:192,openBracket:219,backSlash:220,closeBracket:221,singleQuote:222};function HZ(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.length<2?t[0]:function(){for(var r=[],o=0;o<arguments.length;o++)r[o]=arguments[o];t.forEach(function(i){return i&&i.apply(e,r)})}}function UZ(e,t){if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}function ZB(e){var t=null;try{var n=vl();t=n?n.sessionStorage.getItem(e):null}catch{}return t}function qZ(e,t){var n;try{(n=vl())===null||n===void 0||n.sessionStorage.setItem(e,t)}catch{}}var JB="isRTL",Us;function eh(e){if(e===void 0&&(e={}),e.rtl!==void 0)return e.rtl;if(Us===void 0){var t=ZB(JB);t!==null&&(Us=t==="1",$Z(Us));var n=Z0();Us===void 0&&n&&(Us=(n.body&&n.body.getAttribute("dir")||n.documentElement.getAttribute("dir"))==="rtl",WB(Us))}return!!Us}function $Z(e,t){t===void 0&&(t=!1);var n=Z0();n&&n.documentElement.setAttribute("dir",e?"rtl":"ltr"),t&&qZ(JB,e?"1":"0"),Us=e,WB(Us)}function WZ(e){return e&&!!e._virtual}function GZ(e){var t;return e&&WZ(e)&&(t=e._virtual.parent),t}function Ua(e,t){return t===void 0&&(t=!0),e&&(t&&GZ(e)||e.parentNode&&e.parentNode)}function R2(e,t,n){n===void 0&&(n=!0);var r=!1;if(e&&t)if(n)if(e===t)r=!0;else for(r=!1;t;){var o=Ua(t);if(o===e){r=!0;break}t=o}else e.contains&&(r=e.contains(t));return r}function kT(e,t){return!e||e===document.body?null:t(e)?e:kT(Ua(e),t)}function KZ(e,t){var n=kT(e,function(r){return r.hasAttribute(t)});return n&&n.getAttribute(t)}var X3="data-portal-element";function VZ(e,t){var n=kT(e,function(r){return t===r||r.hasAttribute(X3)});return n!==null&&n.hasAttribute(X3)}var YZ="data-is-focusable",QZ="data-is-visible",XZ="data-focuszone-id",ZZ="data-is-sub-focuszone";function Li(e,t,n,r,o,i,a,s){if(!t||!a&&t===e)return null;var l=ST(t);if(o&&l&&(i||!(qs(t)||xT(t)))){var u=Li(e,t.lastElementChild,!0,!0,!0,i,a,s);if(u){if(s&&$a(u,!0)||!s)return u;var d=Li(e,u.previousElementSibling,!0,!0,!0,i,a,s);if(d)return d;for(var h=u.parentElement;h&&h!==t;){var p=Li(e,h.previousElementSibling,!0,!0,!0,i,a,s);if(p)return p;h=h.parentElement}}}if(n&&l&&$a(t,s))return t;var m=Li(e,t.previousElementSibling,!0,!0,!0,i,a,s);return m||(r?null:Li(e,t.parentElement,!0,!1,!1,i,a,s))}function va(e,t,n,r,o,i,a,s){if(!t||t===e&&o&&!a)return null;var l=ST(t);if(n&&l&&$a(t,s))return t;if(!o&&l&&(i||!(qs(t)||xT(t)))){var u=va(e,t.firstElementChild,!0,!0,!1,i,a,s);if(u)return u}if(t===e)return null;var d=va(e,t.nextElementSibling,!0,!0,!1,i,a,s);return d||(r?null:va(e,t.parentElement,!1,!1,!0,i,a,s))}function ST(e){if(!e||!e.getAttribute)return!1;var t=e.getAttribute(QZ);return t!=null?t==="true":e.offsetHeight!==0||e.offsetParent!==null||e.isVisible===!0}function $a(e,t){if(!e||e.disabled)return!1;var n=0,r=null;e&&e.getAttribute&&(r=e.getAttribute("tabIndex"),r&&(n=parseInt(r,10)));var o=e.getAttribute?e.getAttribute(YZ):null,i=r!==null&&n>=0,a=!!e&&o!=="false"&&(e.tagName==="A"||e.tagName==="BUTTON"||e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.tagName==="SELECT"||o==="true"||i);return t?n!==-1&&a:a}function qs(e){return!!(e&&e.getAttribute&&e.getAttribute(XZ))}function xT(e){return!!(e&&e.getAttribute&&e.getAttribute(ZZ)==="true")}function JZ(e,t){return KZ(e,t)!=="true"}function eJ(e,t){for(var n=e,r=0,o=t;r<o.length;r++){var i=o[r],a=n.children[Math.min(i,n.children.length-1)];if(!a)break;n=a}return n=$a(n)&&ST(n)?n:va(e,n,!0)||Li(e,n),n}function tJ(e,t){for(var n=[];t&&e&&t!==e;){var r=Ua(t,!0);if(r===null)return[];n.unshift(Array.prototype.indexOf.call(r.children,t)),t=r}return n}function nJ(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n=[],r=0,o=e;r<o.length;r++){var i=o[r];if(i)if(typeof i=="string")n.push(i);else if(i.hasOwnProperty("toString")&&typeof i.toString=="function")n.push(i.toString());else for(var a in i)i[a]&&n.push(a)}return n.join(" ")}var rJ="customizations",oJ={settings:{},scopedSettings:{},inCustomizerContext:!1},Dl=zZ.getValue(rJ,{settings:{},scopedSettings:{},inCustomizerContext:!1}),Pm=[],p_=function(){function e(){}return e.reset=function(){Dl.settings={},Dl.scopedSettings={}},e.applySettings=function(t){Dl.settings=oe(oe({},Dl.settings),t),e._raiseChange()},e.applyScopedSettings=function(t,n){Dl.scopedSettings[t]=oe(oe({},Dl.scopedSettings[t]),n),e._raiseChange()},e.getSettings=function(t,n,r){r===void 0&&(r=oJ);for(var o={},i=n&&r.scopedSettings[n]||{},a=n&&Dl.scopedSettings[n]||{},s=0,l=t;s<l.length;s++){var u=l[s];o[u]=i[u]||r.settings[u]||a[u]||Dl.settings[u]}return o},e.applyBatchedUpdates=function(t,n){e._suppressUpdates=!0;try{t()}catch{}e._suppressUpdates=!1,n||e._raiseChange()},e.observe=function(t){Pm.push(t)},e.unobserve=function(t){Pm=Pm.filter(function(n){return n!==t})},e._raiseChange=function(){e._suppressUpdates||Pm.forEach(function(t){return t()})},e}();function iJ(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=HZ(e,e[n],t[n]))}var Pv="__currentId__",aJ="id__",Mv=vl()||{};Mv[Pv]===void 0&&(Mv[Pv]=0);var Z3=!1;function sJ(e){if(!Z3){var t=o1.getInstance();t&&t.onReset&&t.onReset(lJ),Z3=!0}var n=Mv[Pv]++;return(e===void 0?aJ:e)+n}function lJ(e){e===void 0&&(e=0),Mv[Pv]=e}var Zn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var n={},r=0,o=e;r<o.length;r++)for(var i=o[r],a=Array.isArray(i)?i:Object.keys(i),s=0,l=a;s<l.length;s++){var u=l[s];n[u]=1}return n},uJ=Zn(["onCopy","onCut","onPaste","onCompositionEnd","onCompositionStart","onCompositionUpdate","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onInput","onSubmit","onLoad","onError","onKeyDown","onKeyDownCapture","onKeyPress","onKeyUp","onAbort","onCanPlay","onCanPlayThrough","onDurationChange","onEmptied","onEncrypted","onEnded","onLoadedData","onLoadedMetadata","onLoadStart","onPause","onPlay","onPlaying","onProgress","onRateChange","onSeeked","onSeeking","onStalled","onSuspend","onTimeUpdate","onVolumeChange","onWaiting","onClick","onClickCapture","onContextMenu","onDoubleClick","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onMouseUpCapture","onSelect","onTouchCancel","onTouchEnd","onTouchMove","onTouchStart","onScroll","onWheel","onPointerCancel","onPointerDown","onPointerEnter","onPointerLeave","onPointerMove","onPointerOut","onPointerOver","onPointerUp","onGotPointerCapture","onLostPointerCapture"]),cJ=Zn(["accessKey","children","className","contentEditable","dir","draggable","hidden","htmlFor","id","lang","ref","role","style","tabIndex","title","translate","spellCheck","name"]),go=Zn(cJ,uJ);Zn(go,["form"]);var fJ=Zn(go,["height","loop","muted","preload","src","width"]);Zn(fJ,["poster"]);Zn(go,["start"]);Zn(go,["value"]);Zn(go,["download","href","hrefLang","media","rel","target","type"]);var CT=Zn(go,["autoFocus","disabled","form","formAction","formEncType","formMethod","formNoValidate","formTarget","type","value"]);Zn(CT,["accept","alt","autoCapitalize","autoComplete","checked","dirname","form","height","inputMode","list","max","maxLength","min","minLength","multiple","pattern","placeholder","readOnly","required","src","step","size","type","value","width"]);Zn(CT,["autoCapitalize","cols","dirname","form","maxLength","minLength","placeholder","readOnly","required","rows","wrap"]);Zn(CT,["form","multiple","required"]);Zn(go,["selected","value"]);Zn(go,["cellPadding","cellSpacing"]);Zn(go,["rowSpan","scope"]);Zn(go,["colSpan","headers","rowSpan","scope"]);Zn(go,["span"]);Zn(go,["span"]);Zn(go,["acceptCharset","action","encType","encType","method","noValidate","target"]);Zn(go,["allow","allowFullScreen","allowPaymentRequest","allowTransparency","csp","height","importance","referrerPolicy","sandbox","src","srcDoc","width"]);Zn(go,["alt","crossOrigin","height","src","srcSet","useMap","width"]);function dJ(e,t,n){for(var r=Array.isArray(t),o={},i=Object.keys(e),a=0,s=i;a<s.length;a++){var l=s[a],u=!r&&t[l]||r&&t.indexOf(l)>=0||l.indexOf("data-")===0||l.indexOf("aria-")===0;u&&(!n||(n==null?void 0:n.indexOf(l))===-1)&&(o[l]=e[l])}return o}function hJ(e){iJ(e,{componentDidMount:pJ,componentDidUpdate:mJ,componentWillUnmount:gJ})}function pJ(){Lv(this.props.componentRef,this)}function mJ(e){e.componentRef!==this.props.componentRef&&(Lv(e.componentRef,null),Lv(this.props.componentRef,this))}function gJ(){Lv(this.props.componentRef,null)}function Lv(e,t){e&&(typeof e=="object"?e.current=t:typeof e=="function"&&e(t))}function vJ(e){var t=null;try{var n=vl();t=n?n.localStorage.getItem(e):null}catch{}return t}var rc,J3="language";function bJ(e){if(e===void 0&&(e="sessionStorage"),rc===void 0){var t=Z0(),n=e==="localStorage"?vJ(J3):e==="sessionStorage"?ZB(J3):void 0;n&&(rc=n),rc===void 0&&t&&(rc=t.documentElement.getAttribute("lang")),rc===void 0&&(rc="en")}return rc}function eC(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];for(var r=0,o=t;r<o.length;r++){var i=o[r];eR(e||{},i)}return e}function eR(e,t,n){n===void 0&&(n=[]),n.push(t);for(var r in t)if(t.hasOwnProperty(r)&&r!=="__proto__"&&r!=="constructor"&&r!=="prototype"){var o=t[r];if(typeof o=="object"&&o!==null&&!Array.isArray(o)){var i=n.indexOf(o)>-1;e[r]=i?o:eR(e[r]||{},o,n)}else e[r]=o}return n.pop(),e}var yJ=function(e){return function(t){for(var n=0,r=e.refs;n<r.length;n++){var o=r[n];typeof o=="function"?o(t):o&&(o.current=t)}}},EJ=function(e){var t={refs:[]};return function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];return(!t.resolver||!UZ(t.refs,n))&&(t.resolver=yJ(t)),t.refs=n,t.resolver}};function _J(e,t,n,r,o){o===void 0&&(o=!1);var i=oe({primaryButtonBorder:"transparent",errorText:r?"#F1707B":"#a4262c",messageText:r?"#F3F2F1":"#323130",messageLink:r?"#6CB8F6":"#005A9E",messageLinkHovered:r?"#82C7FF":"#004578",infoIcon:r?"#C8C6C4":"#605e5c",errorIcon:r?"#F1707B":"#A80000",blockingIcon:r?"#442726":"#FDE7E9",warningIcon:r?"#C8C6C4":"#797775",severeWarningIcon:r?"#FCE100":"#D83B01",successIcon:r?"#92C353":"#107C10",infoBackground:r?"#323130":"#f3f2f1",errorBackground:r?"#442726":"#FDE7E9",blockingBackground:r?"#442726":"#FDE7E9",warningBackground:r?"#433519":"#FFF4CE",severeWarningBackground:r?"#4F2A0F":"#FED9CC",successBackground:r?"#393D1B":"#DFF6DD",warningHighlight:r?"#fff100":"#ffb900",successText:r?"#92c353":"#107C10"},n),a=tR(e,t,i,r);return TJ(a,o)}function tR(e,t,n,r,o){var i={},a=e||{},s=a.white,l=a.black,u=a.themePrimary,d=a.themeDark,h=a.themeDarker,p=a.themeDarkAlt,m=a.themeLighter,v=a.neutralLight,_=a.neutralLighter,b=a.neutralDark,E=a.neutralQuaternary,w=a.neutralQuaternaryAlt,k=a.neutralPrimary,y=a.neutralSecondary,F=a.neutralSecondaryAlt,C=a.neutralTertiary,A=a.neutralTertiaryAlt,P=a.neutralLighterAlt,I=a.accent;return s&&(i.bodyBackground=s,i.bodyFrameBackground=s,i.accentButtonText=s,i.buttonBackground=s,i.primaryButtonText=s,i.primaryButtonTextHovered=s,i.primaryButtonTextPressed=s,i.inputBackground=s,i.inputForegroundChecked=s,i.listBackground=s,i.menuBackground=s,i.cardStandoutBackground=s),l&&(i.bodyTextChecked=l,i.buttonTextCheckedHovered=l),u&&(i.link=u,i.primaryButtonBackground=u,i.inputBackgroundChecked=u,i.inputIcon=u,i.inputFocusBorderAlt=u,i.menuIcon=u,i.menuHeader=u,i.accentButtonBackground=u),d&&(i.primaryButtonBackgroundPressed=d,i.inputBackgroundCheckedHovered=d,i.inputIconHovered=d),h&&(i.linkHovered=h),p&&(i.primaryButtonBackgroundHovered=p),m&&(i.inputPlaceholderBackgroundChecked=m),v&&(i.bodyBackgroundChecked=v,i.bodyFrameDivider=v,i.bodyDivider=v,i.variantBorder=v,i.buttonBackgroundCheckedHovered=v,i.buttonBackgroundPressed=v,i.listItemBackgroundChecked=v,i.listHeaderBackgroundPressed=v,i.menuItemBackgroundPressed=v,i.menuItemBackgroundChecked=v),_&&(i.bodyBackgroundHovered=_,i.buttonBackgroundHovered=_,i.buttonBackgroundDisabled=_,i.buttonBorderDisabled=_,i.primaryButtonBackgroundDisabled=_,i.disabledBackground=_,i.listItemBackgroundHovered=_,i.listHeaderBackgroundHovered=_,i.menuItemBackgroundHovered=_),E&&(i.primaryButtonTextDisabled=E,i.disabledSubtext=E),w&&(i.listItemBackgroundCheckedHovered=w),C&&(i.disabledBodyText=C,i.variantBorderHovered=(n==null?void 0:n.variantBorderHovered)||C,i.buttonTextDisabled=C,i.inputIconDisabled=C,i.disabledText=C),k&&(i.bodyText=k,i.actionLink=k,i.buttonText=k,i.inputBorderHovered=k,i.inputText=k,i.listText=k,i.menuItemText=k),P&&(i.bodyStandoutBackground=P,i.defaultStateBackground=P),b&&(i.actionLinkHovered=b,i.buttonTextHovered=b,i.buttonTextChecked=b,i.buttonTextPressed=b,i.inputTextHovered=b,i.menuItemTextHovered=b),y&&(i.bodySubtext=y,i.focusBorder=y,i.inputBorder=y,i.smallInputBorder=y,i.inputPlaceholderText=y),F&&(i.buttonBorder=F),A&&(i.disabledBodySubtext=A,i.disabledBorder=A,i.buttonBackgroundChecked=A,i.menuDivider=A),I&&(i.accentButtonBackground=I),t!=null&&t.elevation4&&(i.cardShadow=t.elevation4),!r&&(t!=null&&t.elevation8)?i.cardShadowHovered=t.elevation8:i.variantBorderHovered&&(i.cardShadowHovered="0 0 1px "+i.variantBorderHovered),i=oe(oe({},i),n),i}function TJ(e,t){var n="";return t===!0&&(n=" /* @deprecated */"),e.listTextColor=e.listText+n,e.menuItemBackgroundChecked+=n,e.warningHighlight+=n,e.warningText=e.messageText+n,e.successText+=n,e}function wJ(e,t){var n,r,o;t===void 0&&(t={});var i=eC({},e,t,{semanticColors:tR(t.palette,t.effects,t.semanticColors,t.isInverted===void 0?e.isInverted:t.isInverted)});if(!((n=t.palette)===null||n===void 0)&&n.themePrimary&&!(!((r=t.palette)===null||r===void 0)&&r.accent)&&(i.palette.accent=t.palette.themePrimary),t.defaultFontStyle)for(var a=0,s=Object.keys(i.fonts);a<s.length;a++){var l=s[a];i.fonts[l]=eC(i.fonts[l],t.defaultFontStyle,(o=t==null?void 0:t.fonts)===null||o===void 0?void 0:o[l])}return i}var tC={themeDarker:"#004578",themeDark:"#005a9e",themeDarkAlt:"#106ebe",themePrimary:"#0078d4",themeSecondary:"#2b88d8",themeTertiary:"#71afe5",themeLight:"#c7e0f4",themeLighter:"#deecf9",themeLighterAlt:"#eff6fc",black:"#000000",blackTranslucent40:"rgba(0,0,0,.4)",neutralDark:"#201f1e",neutralPrimary:"#323130",neutralPrimaryAlt:"#3b3a39",neutralSecondary:"#605e5c",neutralSecondaryAlt:"#8a8886",neutralTertiary:"#a19f9d",neutralTertiaryAlt:"#c8c6c4",neutralQuaternary:"#d2d0ce",neutralQuaternaryAlt:"#e1dfdd",neutralLight:"#edebe9",neutralLighter:"#f3f2f1",neutralLighterAlt:"#faf9f8",accent:"#0078d4",white:"#ffffff",whiteTranslucent40:"rgba(255,255,255,.4)",yellowDark:"#d29200",yellow:"#ffb900",yellowLight:"#fff100",orange:"#d83b01",orangeLight:"#ea4300",orangeLighter:"#ff8c00",redDark:"#a4262c",red:"#e81123",magentaDark:"#5c005c",magenta:"#b4009e",magentaLight:"#e3008c",purpleDark:"#32145a",purple:"#5c2d91",purpleLight:"#b4a0ff",blueDark:"#002050",blueMid:"#00188f",blue:"#0078d4",blueLight:"#00bcf2",tealDark:"#004b50",teal:"#008272",tealLight:"#00b294",greenDark:"#004b1c",green:"#107c10",greenLight:"#bad80a"},od;(function(e){e.depth0="0 0 0 0 transparent",e.depth4="0 1.6px 3.6px 0 rgba(0, 0, 0, 0.132), 0 0.3px 0.9px 0 rgba(0, 0, 0, 0.108)",e.depth8="0 3.2px 7.2px 0 rgba(0, 0, 0, 0.132), 0 0.6px 1.8px 0 rgba(0, 0, 0, 0.108)",e.depth16="0 6.4px 14.4px 0 rgba(0, 0, 0, 0.132), 0 1.2px 3.6px 0 rgba(0, 0, 0, 0.108)",e.depth64="0 25.6px 57.6px 0 rgba(0, 0, 0, 0.22), 0 4.8px 14.4px 0 rgba(0, 0, 0, 0.18)"})(od||(od={}));var nC={elevation4:od.depth4,elevation8:od.depth8,elevation16:od.depth16,elevation64:od.depth64,roundedCorner2:"2px",roundedCorner4:"4px",roundedCorner6:"6px"},kJ={s2:"4px",s1:"8px",m:"16px",l1:"20px",l2:"32px"},Hn;(function(e){e.Arabic="Segoe UI Web (Arabic)",e.Cyrillic="Segoe UI Web (Cyrillic)",e.EastEuropean="Segoe UI Web (East European)",e.Greek="Segoe UI Web (Greek)",e.Hebrew="Segoe UI Web (Hebrew)",e.Thai="Leelawadee UI Web",e.Vietnamese="Segoe UI Web (Vietnamese)",e.WestEuropean="Segoe UI Web (West European)",e.Selawik="Selawik Web",e.Armenian="Segoe UI Web (Armenian)",e.Georgian="Segoe UI Web (Georgian)"})(Hn||(Hn={}));var on;(function(e){e.Arabic="'"+Hn.Arabic+"'",e.ChineseSimplified="'Microsoft Yahei UI', Verdana, Simsun",e.ChineseTraditional="'Microsoft Jhenghei UI', Pmingliu",e.Cyrillic="'"+Hn.Cyrillic+"'",e.EastEuropean="'"+Hn.EastEuropean+"'",e.Greek="'"+Hn.Greek+"'",e.Hebrew="'"+Hn.Hebrew+"'",e.Hindi="'Nirmala UI'",e.Japanese="'Yu Gothic UI', 'Meiryo UI', Meiryo, 'MS Pgothic', Osaka",e.Korean="'Malgun Gothic', Gulim",e.Selawik="'"+Hn.Selawik+"'",e.Thai="'Leelawadee UI Web', 'Kmer UI'",e.Vietnamese="'"+Hn.Vietnamese+"'",e.WestEuropean="'"+Hn.WestEuropean+"'",e.Armenian="'"+Hn.Armenian+"'",e.Georgian="'"+Hn.Georgian+"'"})(on||(on={}));var xo;(function(e){e.size10="10px",e.size12="12px",e.size14="14px",e.size16="16px",e.size18="18px",e.size20="20px",e.size24="24px",e.size28="28px",e.size32="32px",e.size42="42px",e.size68="68px",e.mini="10px",e.xSmall="10px",e.small="12px",e.smallPlus="12px",e.medium="14px",e.mediumPlus="16px",e.icon="16px",e.large="18px",e.xLarge="20px",e.xLargePlus="24px",e.xxLarge="28px",e.xxLargePlus="32px",e.superLarge="42px",e.mega="68px"})(xo||(xo={}));var Gn;(function(e){e.light=100,e.semilight=300,e.regular=400,e.semibold=600,e.bold=700})(Gn||(Gn={}));var rC;(function(e){e.xSmall="10px",e.small="12px",e.medium="16px",e.large="20px"})(rC||(rC={}));var SJ="'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', 'Helvetica Neue', sans-serif",xJ="'Segoe UI', '"+Hn.WestEuropean+"'",O2={ar:on.Arabic,bg:on.Cyrillic,cs:on.EastEuropean,el:on.Greek,et:on.EastEuropean,he:on.Hebrew,hi:on.Hindi,hr:on.EastEuropean,hu:on.EastEuropean,ja:on.Japanese,kk:on.EastEuropean,ko:on.Korean,lt:on.EastEuropean,lv:on.EastEuropean,pl:on.EastEuropean,ru:on.Cyrillic,sk:on.EastEuropean,"sr-latn":on.EastEuropean,th:on.Thai,tr:on.EastEuropean,uk:on.Cyrillic,vi:on.Vietnamese,"zh-hans":on.ChineseSimplified,"zh-hant":on.ChineseTraditional,hy:on.Armenian,ka:on.Georgian};function CJ(e){return e+", "+SJ}function AJ(e){for(var t in O2)if(O2.hasOwnProperty(t)&&e&&t.indexOf(e)===0)return O2[t];return xJ}function di(e,t,n){return{fontFamily:n,MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontSize:e,fontWeight:t}}function NJ(e){var t=AJ(e),n=CJ(t),r={tiny:di(xo.mini,Gn.regular,n),xSmall:di(xo.xSmall,Gn.regular,n),small:di(xo.small,Gn.regular,n),smallPlus:di(xo.smallPlus,Gn.regular,n),medium:di(xo.medium,Gn.regular,n),mediumPlus:di(xo.mediumPlus,Gn.regular,n),large:di(xo.large,Gn.regular,n),xLarge:di(xo.xLarge,Gn.semibold,n),xLargePlus:di(xo.xLargePlus,Gn.semibold,n),xxLarge:di(xo.xxLarge,Gn.semibold,n),xxLargePlus:di(xo.xxLargePlus,Gn.semibold,n),superLarge:di(xo.superLarge,Gn.semibold,n),mega:di(xo.mega,Gn.semibold,n)};return r}var FJ="https://static2.sharepointonline.com/files/fabric/assets",IJ=NJ(bJ());function gc(e,t,n,r){e="'"+e+"'";var o=r!==void 0?"local('"+r+"'),":"";MZ({fontFamily:e,src:o+("url('"+t+".woff2') format('woff2'),")+("url('"+t+".woff') format('woff')"),fontWeight:n,fontStyle:"normal",fontDisplay:"swap"})}function da(e,t,n,r,o){r===void 0&&(r="segoeui");var i=e+"/"+n+"/"+r;gc(t,i+"-light",Gn.light,o&&o+" Light"),gc(t,i+"-semilight",Gn.semilight,o&&o+" SemiLight"),gc(t,i+"-regular",Gn.regular,o),gc(t,i+"-semibold",Gn.semibold,o&&o+" SemiBold"),gc(t,i+"-bold",Gn.bold,o&&o+" Bold")}function BJ(e){if(e){var t=e+"/fonts";da(t,Hn.Thai,"leelawadeeui-thai","leelawadeeui"),da(t,Hn.Arabic,"segoeui-arabic"),da(t,Hn.Cyrillic,"segoeui-cyrillic"),da(t,Hn.EastEuropean,"segoeui-easteuropean"),da(t,Hn.Greek,"segoeui-greek"),da(t,Hn.Hebrew,"segoeui-hebrew"),da(t,Hn.Vietnamese,"segoeui-vietnamese"),da(t,Hn.WestEuropean,"segoeui-westeuropean","segoeui","Segoe UI"),da(t,on.Selawik,"selawik","selawik"),da(t,Hn.Armenian,"segoeui-armenian"),da(t,Hn.Georgian,"segoeui-georgian"),gc("Leelawadee UI Web",t+"/leelawadeeui-thai/leelawadeeui-semilight",Gn.light),gc("Leelawadee UI Web",t+"/leelawadeeui-thai/leelawadeeui-bold",Gn.semibold)}}function RJ(){var e,t,n=(e=vl())===null||e===void 0?void 0:e.FabricConfig;return(t=n==null?void 0:n.fontBaseUrl)!==null&&t!==void 0?t:FJ}BJ(RJ());function Hb(e,t){e===void 0&&(e={}),t===void 0&&(t=!1);var n=!!e.isInverted,r={palette:tC,effects:nC,fonts:IJ,spacing:kJ,isInverted:n,disableGlobalClassNames:!1,semanticColors:_J(tC,nC,void 0,n,t),rtl:void 0};return wJ(r,e)}var Pi=Hb({}),OJ=[],m_="theme";function nR(){var e,t,n,r=vl();!((t=r==null?void 0:r.FabricConfig)===null||t===void 0)&&t.legacyTheme?PJ(r.FabricConfig.legacyTheme):p_.getSettings([m_]).theme||(!((n=r==null?void 0:r.FabricConfig)===null||n===void 0)&&n.theme&&(Pi=Hb(r.FabricConfig.theme)),p_.applySettings((e={},e[m_]=Pi,e)))}nR();function DJ(e){return e===void 0&&(e=!1),e===!0&&(Pi=Hb({},e)),Pi}function PJ(e,t){var n;return t===void 0&&(t=!1),Pi=Hb(e,t),KF(oe(oe(oe(oe({},Pi.palette),Pi.semanticColors),Pi.effects),MJ(Pi))),p_.applySettings((n={},n[m_]=Pi,n)),OJ.forEach(function(r){try{r(Pi)}catch{}}),Pi}function MJ(e){for(var t={},n=0,r=Object.keys(e.fonts);n<r.length;n++)for(var o=r[n],i=e.fonts[o],a=0,s=Object.keys(i);a<s.length;a++){var l=s[a],u=o+l.charAt(0).toUpperCase()+l.slice(1),d=i[l];l==="fontSize"&&typeof d=="number"&&(d=d+"px"),t[u]=d}return t}yb("@fluentui/style-utilities","8.6.0");nR();var Mm="data-is-focusable",LJ="data-disable-click-on-enter",D2="data-focuszone-id",Pa="tabindex",P2="data-no-vertical-wrap",M2="data-no-horizontal-wrap",L2=999999999,th=-999999999,j2,jJ="ms-FocusZone";function zJ(e,t){var n;typeof MouseEvent=="function"?n=new MouseEvent("click",{ctrlKey:t==null?void 0:t.ctrlKey,metaKey:t==null?void 0:t.metaKey,shiftKey:t==null?void 0:t.shiftKey,altKey:t==null?void 0:t.altKey,bubbles:t==null?void 0:t.bubbles,cancelable:t==null?void 0:t.cancelable}):(n=document.createEvent("MouseEvents"),n.initMouseEvent("click",t?t.bubbles:!1,t?t.cancelable:!1,window,0,0,0,0,0,t?t.ctrlKey:!1,t?t.altKey:!1,t?t.shiftKey:!1,t?t.metaKey:!1,0,null)),e.dispatchEvent(n)}function HJ(){return j2||(j2=XB({selectors:{":focus":{outline:"none"}}},jJ)),j2}var nh={},Tf=new Set,UJ=["text","number","password","email","tel","url","search"],oc=!1,rR=function(e){yi(t,e);function t(n){var r,o,i,a,s=e.call(this,n)||this;s._root=T.createRef(),s._mergedRef=EJ(),s._onFocus=function(u){if(!s._portalContainsElement(u.target)){var d=s.props,h=d.onActiveElementChanged,p=d.doNotAllowFocusEventToPropagate,m=d.stopFocusPropagation,v=d.onFocusNotification,_=d.onFocus,b=d.shouldFocusInnerElementWhenReceivedFocus,E=d.defaultTabbableElement,w=s._isImmediateDescendantOfZone(u.target),k;if(w)k=u.target;else for(var y=u.target;y&&y!==s._root.current;){if($a(y)&&s._isImmediateDescendantOfZone(y)){k=y;break}y=Ua(y,oc)}if(b&&u.target===s._root.current){var F=E&&typeof E=="function"&&s._root.current&&E(s._root.current);F&&$a(F)?(k=F,F.focus()):(s.focus(!0),s._activeElement&&(k=null))}var C=!s._activeElement;k&&k!==s._activeElement&&((w||C)&&s._setFocusAlignment(k,!0,!0),s._activeElement=k,C&&s._updateTabIndexes()),h&&h(s._activeElement,u),(m||p)&&u.stopPropagation(),_?_(u):v&&v()}},s._onBlur=function(){s._setParkedFocus(!1)},s._onMouseDown=function(u){if(!s._portalContainsElement(u.target)){var d=s.props.disabled;if(!d){for(var h=u.target,p=[];h&&h!==s._root.current;)p.push(h),h=Ua(h,oc);for(;p.length&&(h=p.pop(),h&&$a(h)&&s._setActiveElement(h,!0),!qs(h)););}}},s._onKeyDown=function(u,d){if(!s._portalContainsElement(u.target)){var h=s.props,p=h.direction,m=h.disabled,v=h.isInnerZoneKeystroke,_=h.pagingSupportDisabled,b=h.shouldEnterInnerZone;if(!m&&(s.props.onKeyDown&&s.props.onKeyDown(u),!u.isDefaultPrevented()&&!(s._getDocument().activeElement===s._root.current&&s._isInnerZone))){if((b&&b(u)||v&&v(u))&&s._isImmediateDescendantOfZone(u.target)){var E=s._getFirstInnerZone();if(E){if(!E.focus(!0))return}else if(xT(u.target)){if(!s.focusElement(va(u.target,u.target.firstChild,!0)))return}else return}else{if(u.altKey)return;switch(u.which){case Oi.space:if(s._shouldRaiseClicksOnSpace&&s._tryInvokeClickForFocusable(u.target,u))break;return;case Oi.left:if(p!==ao.vertical&&(s._preventDefaultWhenHandled(u),s._moveFocusLeft(d)))break;return;case Oi.right:if(p!==ao.vertical&&(s._preventDefaultWhenHandled(u),s._moveFocusRight(d)))break;return;case Oi.up:if(p!==ao.horizontal&&(s._preventDefaultWhenHandled(u),s._moveFocusUp()))break;return;case Oi.down:if(p!==ao.horizontal&&(s._preventDefaultWhenHandled(u),s._moveFocusDown()))break;return;case Oi.pageDown:if(!_&&s._moveFocusPaging(!0))break;return;case Oi.pageUp:if(!_&&s._moveFocusPaging(!1))break;return;case Oi.tab:if(s.props.allowTabKey||s.props.handleTabKey===f_.all||s.props.handleTabKey===f_.inputOnly&&s._isElementInput(u.target)){var w=!1;if(s._processingTabKey=!0,p===ao.vertical||!s._shouldWrapFocus(s._activeElement,M2))w=u.shiftKey?s._moveFocusUp():s._moveFocusDown();else{var k=eh(d)?!u.shiftKey:u.shiftKey;w=k?s._moveFocusLeft(d):s._moveFocusRight(d)}if(s._processingTabKey=!1,w)break;s.props.shouldResetActiveElementWhenTabFromZone&&(s._activeElement=null)}return;case Oi.home:if(s._isContentEditableElement(u.target)||s._isElementInput(u.target)&&!s._shouldInputLoseFocus(u.target,!1))return!1;var y=s._root.current&&s._root.current.firstChild;if(s._root.current&&y&&s.focusElement(va(s._root.current,y,!0)))break;return;case Oi.end:if(s._isContentEditableElement(u.target)||s._isElementInput(u.target)&&!s._shouldInputLoseFocus(u.target,!0))return!1;var F=s._root.current&&s._root.current.lastChild;if(s._root.current&&s.focusElement(Li(s._root.current,F,!0,!0,!0)))break;return;case Oi.enter:if(s._shouldRaiseClicksOnEnter&&s._tryInvokeClickForFocusable(u.target,u))break;return;default:return}}u.preventDefault(),u.stopPropagation()}}},s._getHorizontalDistanceFromCenter=function(u,d,h){var p=s._focusAlignment.left||s._focusAlignment.x||0,m=Math.floor(h.top),v=Math.floor(d.bottom),_=Math.floor(h.bottom),b=Math.floor(d.top),E=u&&m>v,w=!u&&_<b;return E||w?p>=h.left&&p<=h.left+h.width?0:Math.abs(h.left+h.width/2-p):s._shouldWrapFocus(s._activeElement,P2)?L2:th},hJ(s),s._id=sJ("FocusZone"),s._focusAlignment={left:0,top:0},s._processingTabKey=!1;var l=(o=(r=n.shouldRaiseClicks)!==null&&r!==void 0?r:t.defaultProps.shouldRaiseClicks)!==null&&o!==void 0?o:!0;return s._shouldRaiseClicksOnEnter=(i=n.shouldRaiseClicksOnEnter)!==null&&i!==void 0?i:l,s._shouldRaiseClicksOnSpace=(a=n.shouldRaiseClicksOnSpace)!==null&&a!==void 0?a:l,s}return t.getOuterZones=function(){return Tf.size},t._onKeyDownCapture=function(n){n.which===Oi.tab&&Tf.forEach(function(r){return r._updateTabIndexes()})},t.prototype.componentDidMount=function(){var n=this._root.current;if(nh[this._id]=this,n){this._windowElement=vl(n);for(var r=Ua(n,oc);r&&r!==this._getDocument().body&&r.nodeType===1;){if(qs(r)){this._isInnerZone=!0;break}r=Ua(r,oc)}this._isInnerZone||(Tf.add(this),this._windowElement&&Tf.size===1&&this._windowElement.addEventListener("keydown",t._onKeyDownCapture,!0)),this._root.current&&this._root.current.addEventListener("blur",this._onBlur,!0),this._updateTabIndexes(),this.props.defaultTabbableElement&&typeof this.props.defaultTabbableElement=="string"?this._activeElement=this._getDocument().querySelector(this.props.defaultTabbableElement):this.props.defaultActiveElement&&(this._activeElement=this._getDocument().querySelector(this.props.defaultActiveElement)),this.props.shouldFocusOnMount&&this.focus()}},t.prototype.componentDidUpdate=function(){var n=this._root.current,r=this._getDocument();if(!this.props.preventFocusRestoration&&r&&this._lastIndexPath&&(r.activeElement===r.body||r.activeElement===null||r.activeElement===n)){var o=eJ(n,this._lastIndexPath);o?(this._setActiveElement(o,!0),o.focus(),this._setParkedFocus(!1)):this._setParkedFocus(!0)}},t.prototype.componentWillUnmount=function(){delete nh[this._id],this._isInnerZone||(Tf.delete(this),this._windowElement&&Tf.size===0&&this._windowElement.removeEventListener("keydown",t._onKeyDownCapture,!0)),this._root.current&&this._root.current.removeEventListener("blur",this._onBlur,!0),this._activeElement=null,this._defaultFocusElement=null},t.prototype.render=function(){var n=this,r=this.props,o=r.as,i=r.elementType,a=r.rootProps,s=r.ariaDescribedBy,l=r.ariaLabelledBy,u=r.className,d=dJ(this.props,go),h=o||i||"div";this._evaluateFocusBeforeRender();var p=DJ();return T.createElement(h,oe({"aria-labelledby":l,"aria-describedby":s},d,a,{className:nJ(HJ(),u),ref:this._mergedRef(this.props.elementRef,this._root),"data-focuszone-id":this._id,onKeyDown:function(m){return n._onKeyDown(m,p)},onFocus:this._onFocus,onMouseDownCapture:this._onMouseDown}),this.props.children)},t.prototype.focus=function(n){if(n===void 0&&(n=!1),this._root.current)if(!n&&this._root.current.getAttribute(Mm)==="true"&&this._isInnerZone){var r=this._getOwnerZone(this._root.current);if(r!==this._root.current){var o=nh[r.getAttribute(D2)];return!!o&&o.focusElement(this._root.current)}return!1}else{if(!n&&this._activeElement&&R2(this._root.current,this._activeElement)&&$a(this._activeElement))return this._activeElement.focus(),!0;var i=this._root.current.firstChild;return this.focusElement(va(this._root.current,i,!0))}return!1},t.prototype.focusLast=function(){if(this._root.current){var n=this._root.current&&this._root.current.lastChild;return this.focusElement(Li(this._root.current,n,!0,!0,!0))}return!1},t.prototype.focusElement=function(n,r){var o=this.props,i=o.onBeforeFocus,a=o.shouldReceiveFocus;return a&&!a(n)||i&&!i(n)?!1:n?(this._setActiveElement(n,r),this._activeElement&&this._activeElement.focus(),!0):!1},t.prototype.setFocusAlignment=function(n){this._focusAlignment=n},t.prototype._evaluateFocusBeforeRender=function(){var n=this._root.current,r=this._getDocument();if(r){var o=r.activeElement;if(o!==n){var i=R2(n,o,!1);this._lastIndexPath=i?tJ(n,o):void 0}}},t.prototype._setParkedFocus=function(n){var r=this._root.current;r&&this._isParked!==n&&(this._isParked=n,n?(this.props.allowFocusRoot||(this._parkedTabIndex=r.getAttribute("tabindex"),r.setAttribute("tabindex","-1")),r.focus()):this.props.allowFocusRoot||(this._parkedTabIndex?(r.setAttribute("tabindex",this._parkedTabIndex),this._parkedTabIndex=void 0):r.removeAttribute("tabindex")))},t.prototype._setActiveElement=function(n,r){var o=this._activeElement;this._activeElement=n,o&&(qs(o)&&this._updateTabIndexes(o),o.tabIndex=-1),this._activeElement&&((!this._focusAlignment||r)&&this._setFocusAlignment(n,!0,!0),this._activeElement.tabIndex=0)},t.prototype._preventDefaultWhenHandled=function(n){this.props.preventDefaultWhenHandled&&n.preventDefault()},t.prototype._tryInvokeClickForFocusable=function(n,r){var o=n;if(o===this._root.current)return!1;do{if(o.tagName==="BUTTON"||o.tagName==="A"||o.tagName==="INPUT"||o.tagName==="TEXTAREA")return!1;if(this._isImmediateDescendantOfZone(o)&&o.getAttribute(Mm)==="true"&&o.getAttribute(LJ)!=="true")return zJ(o,r),!0;o=Ua(o,oc)}while(o!==this._root.current);return!1},t.prototype._getFirstInnerZone=function(n){if(n=n||this._activeElement||this._root.current,!n)return null;if(qs(n))return nh[n.getAttribute(D2)];for(var r=n.firstElementChild;r;){if(qs(r))return nh[r.getAttribute(D2)];var o=this._getFirstInnerZone(r);if(o)return o;r=r.nextElementSibling}return null},t.prototype._moveFocus=function(n,r,o,i){i===void 0&&(i=!0);var a=this._activeElement,s=-1,l=void 0,u=!1,d=this.props.direction===ao.bidirectional;if(!a||!this._root.current||this._isElementInput(a)&&!this._shouldInputLoseFocus(a,n))return!1;var h=d?a.getBoundingClientRect():null;do if(a=n?va(this._root.current,a):Li(this._root.current,a),d){if(a){var p=a.getBoundingClientRect(),m=r(h,p);if(m===-1&&s===-1){l=a;break}if(m>-1&&(s===-1||m<s)&&(s=m,l=a),s>=0&&m<0)break}}else{l=a;break}while(a);if(l&&l!==this._activeElement)u=!0,this.focusElement(l);else if(this.props.isCircularNavigation&&i)return n?this.focusElement(va(this._root.current,this._root.current.firstElementChild,!0)):this.focusElement(Li(this._root.current,this._root.current.lastElementChild,!0,!0,!0));return u},t.prototype._moveFocusDown=function(){var n=this,r=-1,o=this._focusAlignment.left||this._focusAlignment.x||0;return this._moveFocus(!0,function(i,a){var s=-1,l=Math.floor(a.top),u=Math.floor(i.bottom);return l<u?n._shouldWrapFocus(n._activeElement,P2)?L2:th:((r===-1&&l>=u||l===r)&&(r=l,o>=a.left&&o<=a.left+a.width?s=0:s=Math.abs(a.left+a.width/2-o)),s)})?(this._setFocusAlignment(this._activeElement,!1,!0),!0):!1},t.prototype._moveFocusUp=function(){var n=this,r=-1,o=this._focusAlignment.left||this._focusAlignment.x||0;return this._moveFocus(!1,function(i,a){var s=-1,l=Math.floor(a.bottom),u=Math.floor(a.top),d=Math.floor(i.top);return l>d?n._shouldWrapFocus(n._activeElement,P2)?L2:th:((r===-1&&l<=d||u===r)&&(r=u,o>=a.left&&o<=a.left+a.width?s=0:s=Math.abs(a.left+a.width/2-o)),s)})?(this._setFocusAlignment(this._activeElement,!1,!0),!0):!1},t.prototype._moveFocusLeft=function(n){var r=this,o=this._shouldWrapFocus(this._activeElement,M2);return this._moveFocus(eh(n),function(i,a){var s=-1,l;return eh(n)?l=parseFloat(a.top.toFixed(3))<parseFloat(i.bottom.toFixed(3)):l=parseFloat(a.bottom.toFixed(3))>parseFloat(i.top.toFixed(3)),l&&a.right<=i.right&&r.props.direction!==ao.vertical?s=i.right-a.right:o||(s=th),s},void 0,o)?(this._setFocusAlignment(this._activeElement,!0,!1),!0):!1},t.prototype._moveFocusRight=function(n){var r=this,o=this._shouldWrapFocus(this._activeElement,M2);return this._moveFocus(!eh(n),function(i,a){var s=-1,l;return eh(n)?l=parseFloat(a.bottom.toFixed(3))>parseFloat(i.top.toFixed(3)):l=parseFloat(a.top.toFixed(3))<parseFloat(i.bottom.toFixed(3)),l&&a.left>=i.left&&r.props.direction!==ao.vertical?s=a.left-i.left:o||(s=th),s},void 0,o)?(this._setFocusAlignment(this._activeElement,!0,!1),!0):!1},t.prototype._moveFocusPaging=function(n,r){r===void 0&&(r=!0);var o=this._activeElement;if(!o||!this._root.current||this._isElementInput(o)&&!this._shouldInputLoseFocus(o,n))return!1;var i=LZ(o);if(!i)return!1;var a=-1,s=void 0,l=-1,u=-1,d=i.clientHeight,h=o.getBoundingClientRect();do if(o=n?va(this._root.current,o):Li(this._root.current,o),o){var p=o.getBoundingClientRect(),m=Math.floor(p.top),v=Math.floor(h.bottom),_=Math.floor(p.bottom),b=Math.floor(h.top),E=this._getHorizontalDistanceFromCenter(n,h,p),w=n&&m>v+d,k=!n&&_<b-d;if(w||k)break;E>-1&&(n&&m>l?(l=m,a=E,s=o):!n&&_<u?(u=_,a=E,s=o):(a===-1||E<=a)&&(a=E,s=o))}while(o);var y=!1;if(s&&s!==this._activeElement)y=!0,this.focusElement(s),this._setFocusAlignment(s,!1,!0);else if(this.props.isCircularNavigation&&r)return n?this.focusElement(va(this._root.current,this._root.current.firstElementChild,!0)):this.focusElement(Li(this._root.current,this._root.current.lastElementChild,!0,!0,!0));return y},t.prototype._setFocusAlignment=function(n,r,o){if(this.props.direction===ao.bidirectional&&(!this._focusAlignment||r||o)){var i=n.getBoundingClientRect(),a=i.left+i.width/2,s=i.top+i.height/2;this._focusAlignment||(this._focusAlignment={left:a,top:s}),r&&(this._focusAlignment.left=a),o&&(this._focusAlignment.top=s)}},t.prototype._isImmediateDescendantOfZone=function(n){return this._getOwnerZone(n)===this._root.current},t.prototype._getOwnerZone=function(n){for(var r=Ua(n,oc);r&&r!==this._root.current&&r!==this._getDocument().body;){if(qs(r))return r;r=Ua(r,oc)}return r},t.prototype._updateTabIndexes=function(n){!this._activeElement&&this.props.defaultTabbableElement&&typeof this.props.defaultTabbableElement=="function"&&(this._activeElement=this.props.defaultTabbableElement(this._root.current)),!n&&this._root.current&&(this._defaultFocusElement=null,n=this._root.current,this._activeElement&&!R2(n,this._activeElement)&&(this._activeElement=null)),this._activeElement&&!$a(this._activeElement)&&(this._activeElement=null);for(var r=n&&n.children,o=0;r&&o<r.length;o++){var i=r[o];qs(i)?i.getAttribute(Mm)==="true"&&(!this._isInnerZone&&(!this._activeElement&&!this._defaultFocusElement||this._activeElement===i)?(this._defaultFocusElement=i,i.getAttribute(Pa)!=="0"&&i.setAttribute(Pa,"0")):i.getAttribute(Pa)!=="-1"&&i.setAttribute(Pa,"-1")):(i.getAttribute&&i.getAttribute(Mm)==="false"&&i.setAttribute(Pa,"-1"),$a(i)?this.props.disabled?i.setAttribute(Pa,"-1"):!this._isInnerZone&&(!this._activeElement&&!this._defaultFocusElement||this._activeElement===i)?(this._defaultFocusElement=i,i.getAttribute(Pa)!=="0"&&i.setAttribute(Pa,"0")):i.getAttribute(Pa)!=="-1"&&i.setAttribute(Pa,"-1"):i.tagName==="svg"&&i.getAttribute("focusable")!=="false"&&i.setAttribute("focusable","false")),this._updateTabIndexes(i)}},t.prototype._isContentEditableElement=function(n){return n&&n.getAttribute("contenteditable")==="true"},t.prototype._isElementInput=function(n){return!!(n&&n.tagName&&(n.tagName.toLowerCase()==="input"||n.tagName.toLowerCase()==="textarea"))},t.prototype._shouldInputLoseFocus=function(n,r){if(!this._processingTabKey&&n&&n.type&&UJ.indexOf(n.type.toLowerCase())>-1){var o=n.selectionStart,i=n.selectionEnd,a=o!==i,s=n.value,l=n.readOnly;if(a||o>0&&!r&&!l||o!==s.length&&r&&!l||this.props.handleTabKey&&!(this.props.shouldInputLoseFocusOnArrowKey&&this.props.shouldInputLoseFocusOnArrowKey(n)))return!1}return!0},t.prototype._shouldWrapFocus=function(n,r){return this.props.checkForNoWrap?JZ(n,r):!0},t.prototype._portalContainsElement=function(n){return n&&!!this._root.current&&VZ(n,this._root.current)},t.prototype._getDocument=function(){return Z0(this._root.current)},t.defaultProps={isCircularNavigation:!1,direction:ao.bidirectional,shouldRaiseClicks:!0},t}(T.Component),Ko;(function(e){e[e.Normal=0]="Normal",e[e.Divider=1]="Divider",e[e.Header=2]="Header",e[e.Section=3]="Section"})(Ko||(Ko={}));function k0(e){return e.canCheck?!!(e.isChecked||e.checked):typeof e.isChecked=="boolean"?e.isChecked:typeof e.checked=="boolean"?e.checked:null}function ll(e){return!!(e.subMenuProps||e.items)}function Ja(e){return!!(e.isDisabled||e.disabled)}function oR(e){var t=k0(e),n=t!==null;return n?"menuitemcheckbox":"menuitem"}var oC=function(e){var t=e.item,n=e.classNames,r=t.iconProps;return T.createElement(sl,oe({},r,{className:n.icon}))},qJ=function(e){var t=e.item,n=e.hasIcons;return n?t.onRenderIcon?t.onRenderIcon(e,oC):oC(e):null},$J=function(e){var t=e.onCheckmarkClick,n=e.item,r=e.classNames,o=k0(n);if(t){var i=function(a){return t(n,a)};return T.createElement(sl,{iconName:n.canCheck!==!1&&o?"CheckMark":"",className:r.checkmarkIcon,onClick:i})}return null},WJ=function(e){var t=e.item,n=e.classNames;return t.text||t.name?T.createElement("span",{className:n.label},t.text||t.name):null},GJ=function(e){var t=e.item,n=e.classNames;return t.secondaryText?T.createElement("span",{className:n.secondaryText},t.secondaryText):null},KJ=function(e){var t=e.item,n=e.classNames,r=e.theme;return ll(t)?T.createElement(sl,oe({iconName:ls(r)?"ChevronLeft":"ChevronRight"},t.submenuIconProps,{className:n.subMenuIcon})):null},VJ=function(e){yi(t,e);function t(n){var r=e.call(this,n)||this;return r.openSubMenu=function(){var o=r.props,i=o.item,a=o.openSubMenu,s=o.getSubmenuTarget;if(s){var l=s();ll(i)&&a&&l&&a(i,l)}},r.dismissSubMenu=function(){var o=r.props,i=o.item,a=o.dismissSubMenu;ll(i)&&a&&a()},r.dismissMenu=function(o){var i=r.props.dismissMenu;i&&i(void 0,o)},Tb(r),r}return t.prototype.render=function(){var n=this.props,r=n.item,o=n.classNames,i=r.onRenderContent||this._renderLayout;return T.createElement("div",{className:r.split?o.linkContentMenu:o.linkContent},i(this.props,{renderCheckMarkIcon:$J,renderItemIcon:qJ,renderItemName:WJ,renderSecondaryText:GJ,renderSubMenuIcon:KJ}))},t.prototype._renderLayout=function(n,r){return T.createElement(T.Fragment,null,r.renderCheckMarkIcon(n),r.renderItemIcon(n),r.renderItemName(n),r.renderSecondaryText(n),r.renderSubMenuIcon(n))},t}(T.Component),YJ=Cr(function(e){return q0({wrapper:{display:"inline-flex",height:"100%",alignItems:"center"},divider:{width:1,height:"100%",backgroundColor:e.palette.neutralTertiaryAlt}})}),Xl=36,iC=$F(0,qF),rh=Cr(function(){var e;return{selectors:(e={},e[Ao]=oe({backgroundColor:"Highlight",borderColor:"Highlight",color:"HighlightText"},WF()),e)}}),QJ=Cr(function(e){var t,n,r,o,i,a,s,l=e.semanticColors,u=e.fonts,d=e.palette,h=l.menuItemBackgroundHovered,p=l.menuItemTextHovered,m=l.menuItemBackgroundPressed,v=l.bodyDivider,_={item:[u.medium,{color:l.bodyText,position:"relative",boxSizing:"border-box"}],divider:{display:"block",height:"1px",backgroundColor:v,position:"relative"},root:[Pd(e),u.medium,{color:l.bodyText,backgroundColor:"transparent",border:"none",width:"100%",height:Xl,lineHeight:Xl,display:"block",cursor:"pointer",padding:"0px 8px 0 4px",textAlign:"left"}],rootDisabled:{color:l.disabledBodyText,cursor:"default",pointerEvents:"none",selectors:(t={},t[Ao]=oe({color:"GrayText",opacity:1},WF()),t)},rootHovered:oe({backgroundColor:h,color:p,selectors:{".ms-ContextualMenu-icon":{color:d.themeDarkAlt},".ms-ContextualMenu-submenuIcon":{color:d.neutralPrimary}}},rh()),rootFocused:oe({backgroundColor:d.white},rh()),rootChecked:oe({selectors:{".ms-ContextualMenu-checkmarkIcon":{color:d.neutralPrimary}}},rh()),rootPressed:oe({backgroundColor:m,selectors:{".ms-ContextualMenu-icon":{color:d.themeDark},".ms-ContextualMenu-submenuIcon":{color:d.neutralPrimary}}},rh()),rootExpanded:oe({backgroundColor:m,color:l.bodyTextChecked},rh()),linkContent:{whiteSpace:"nowrap",height:"inherit",display:"flex",alignItems:"center",maxWidth:"100%"},anchorLink:{padding:"0px 8px 0 4px",textRendering:"auto",color:"inherit",letterSpacing:"normal",wordSpacing:"normal",textTransform:"none",textIndent:"0px",textShadow:"none",textDecoration:"none",boxSizing:"border-box"},label:{margin:"0 4px",verticalAlign:"middle",display:"inline-block",flexGrow:"1",textOverflow:"ellipsis",overflow:"hidden",whiteSpace:"nowrap"},secondaryText:{color:e.palette.neutralSecondary,paddingLeft:"20px",textAlign:"right"},icon:{display:"inline-block",minHeight:"1px",maxHeight:Xl,fontSize:Kl.medium,width:Kl.medium,margin:"0 4px",verticalAlign:"middle",flexShrink:"0",selectors:(n={},n[iC]={fontSize:Kl.large,width:Kl.large},n)},iconColor:{color:l.menuIcon,selectors:(r={},r[Ao]={color:"inherit"},r["$root:hover &"]={selectors:(o={},o[Ao]={color:"HighlightText"},o)},r["$root:focus &"]={selectors:(i={},i[Ao]={color:"HighlightText"},i)},r)},iconDisabled:{color:l.disabledBodyText},checkmarkIcon:{color:l.bodySubtext,selectors:(a={},a[Ao]={color:"HighlightText"},a)},subMenuIcon:{height:Xl,lineHeight:Xl,color:d.neutralSecondary,textAlign:"center",display:"inline-block",verticalAlign:"middle",flexShrink:"0",fontSize:Kl.small,selectors:(s={":hover":{color:d.neutralPrimary},":active":{color:d.neutralPrimary}},s[iC]={fontSize:Kl.medium},s[Ao]={color:"HighlightText"},s)},splitButtonFlexContainer:[Pd(e),{display:"flex",height:Xl,flexWrap:"nowrap",justifyContent:"center",alignItems:"flex-start"}]};return jc(_)}),aC="28px",XJ=$F(0,qF),ZJ=Cr(function(e){var t;return q0(YJ(e),{wrapper:{position:"absolute",right:28,selectors:(t={},t[XJ]={right:32},t)},divider:{height:16,width:1}})}),JJ={item:"ms-ContextualMenu-item",divider:"ms-ContextualMenu-divider",root:"ms-ContextualMenu-link",isChecked:"is-checked",isExpanded:"is-expanded",isDisabled:"is-disabled",linkContent:"ms-ContextualMenu-linkContent",linkContentMenu:"ms-ContextualMenu-linkContent",icon:"ms-ContextualMenu-icon",iconColor:"ms-ContextualMenu-iconColor",checkmarkIcon:"ms-ContextualMenu-checkmarkIcon",subMenuIcon:"ms-ContextualMenu-submenuIcon",label:"ms-ContextualMenu-itemText",secondaryText:"ms-ContextualMenu-secondaryText",splitMenu:"ms-ContextualMenu-splitMenu",screenReaderText:"ms-ContextualMenu-screenReaderText"},eee=Cr(function(e,t,n,r,o,i,a,s,l,u,d,h){var p,m,v,_,b=QJ(e),E=hs(JJ,e);return q0({item:[E.item,b.item,a],divider:[E.divider,b.divider,s],root:[E.root,b.root,r&&[E.isChecked,b.rootChecked],o&&b.anchorLink,n&&[E.isExpanded,b.rootExpanded],t&&[E.isDisabled,b.rootDisabled],!t&&!n&&[{selectors:(p={":hover":b.rootHovered,":active":b.rootPressed},p["."+Go+" &:focus, ."+Go+" &:focus:hover"]=b.rootFocused,p["."+Go+" &:hover"]={background:"inherit;"},p)}],h],splitPrimary:[b.root,{width:"calc(100% - "+aC+")"},r&&["is-checked",b.rootChecked],(t||d)&&["is-disabled",b.rootDisabled],!(t||d)&&!r&&[{selectors:(m={":hover":b.rootHovered},m[":hover ~ ."+E.splitMenu]=b.rootHovered,m[":active"]=b.rootPressed,m["."+Go+" &:focus, ."+Go+" &:focus:hover"]=b.rootFocused,m["."+Go+" &:hover"]={background:"inherit;"},m)}]],splitMenu:[E.splitMenu,b.root,{flexBasis:"0",padding:"0 8px",minWidth:aC},n&&["is-expanded",b.rootExpanded],t&&["is-disabled",b.rootDisabled],!t&&!n&&[{selectors:(v={":hover":b.rootHovered,":active":b.rootPressed},v["."+Go+" &:focus, ."+Go+" &:focus:hover"]=b.rootFocused,v["."+Go+" &:hover"]={background:"inherit;"},v)}]],anchorLink:b.anchorLink,linkContent:[E.linkContent,b.linkContent],linkContentMenu:[E.linkContentMenu,b.linkContent,{justifyContent:"center"}],icon:[E.icon,i&&b.iconColor,b.icon,l,t&&[E.isDisabled,b.iconDisabled]],iconColor:b.iconColor,checkmarkIcon:[E.checkmarkIcon,i&&b.checkmarkIcon,b.icon,l],subMenuIcon:[E.subMenuIcon,b.subMenuIcon,u,n&&{color:e.palette.neutralPrimary},t&&[b.iconDisabled]],label:[E.label,b.label],secondaryText:[E.secondaryText,b.secondaryText],splitContainer:[b.splitButtonFlexContainer,!t&&!r&&[{selectors:(_={},_["."+Go+" &:focus, ."+Go+" &:focus:hover"]=b.rootFocused,_)}]],screenReaderText:[E.screenReaderText,b.screenReaderText,GF,{visibility:"hidden"}]})}),iR=function(e){var t=e.theme,n=e.disabled,r=e.expanded,o=e.checked,i=e.isAnchorLink,a=e.knownIcon,s=e.itemClassName,l=e.dividerClassName,u=e.iconClassName,d=e.subMenuClassName,h=e.primaryDisabled,p=e.className;return eee(t,n,r,o,i,a,s,l,u,d,h,p)},S0=gl(VJ,iR,void 0,{scope:"ContextualMenuItem"}),AT=function(e){yi(t,e);function t(n){var r=e.call(this,n)||this;return r._onItemMouseEnter=function(o){var i=r.props,a=i.item,s=i.onItemMouseEnter;s&&s(a,o,o.currentTarget)},r._onItemClick=function(o){var i=r.props,a=i.item,s=i.onItemClickBase;s&&s(a,o,o.currentTarget)},r._onItemMouseLeave=function(o){var i=r.props,a=i.item,s=i.onItemMouseLeave;s&&s(a,o)},r._onItemKeyDown=function(o){var i=r.props,a=i.item,s=i.onItemKeyDown;s&&s(a,o)},r._onItemMouseMove=function(o){var i=r.props,a=i.item,s=i.onItemMouseMove;s&&s(a,o,o.currentTarget)},r._getSubmenuTarget=function(){},Tb(r),r}return t.prototype.shouldComponentUpdate=function(n){return!T4(n,this.props)},t}(T.Component),tee="ktp",sC="-",nee="data-ktp-target",ree="data-ktp-execute-target",oee="ktp-layer-id",ja;(function(e){e.KEYTIP_ADDED="keytipAdded",e.KEYTIP_REMOVED="keytipRemoved",e.KEYTIP_UPDATED="keytipUpdated",e.PERSISTED_KEYTIP_ADDED="persistedKeytipAdded",e.PERSISTED_KEYTIP_REMOVED="persistedKeytipRemoved",e.PERSISTED_KEYTIP_EXECUTE="persistedKeytipExecute",e.ENTER_KEYTIP_MODE="enterKeytipMode",e.EXIT_KEYTIP_MODE="exitKeytipMode"})(ja||(ja={}));var iee=function(){function e(){this.keytips={},this.persistedKeytips={},this.sequenceMapping={},this.inKeytipMode=!1,this.shouldEnterKeytipMode=!0,this.delayUpdatingKeytipChange=!1}return e.getInstance=function(){return this._instance},e.prototype.init=function(t){this.delayUpdatingKeytipChange=t},e.prototype.register=function(t,n){n===void 0&&(n=!1);var r=t;n||(r=this.addParentOverflow(t),this.sequenceMapping[r.keySequences.toString()]=r);var o=this._getUniqueKtp(r);if(n?this.persistedKeytips[o.uniqueID]=o:this.keytips[o.uniqueID]=o,this.inKeytipMode||!this.delayUpdatingKeytipChange){var i=n?ja.PERSISTED_KEYTIP_ADDED:ja.KEYTIP_ADDED;Ws.raise(this,i,{keytip:r,uniqueID:o.uniqueID})}return o.uniqueID},e.prototype.update=function(t,n){var r=this.addParentOverflow(t),o=this._getUniqueKtp(r,n),i=this.keytips[n];i&&(o.keytip.visible=i.keytip.visible,this.keytips[n]=o,delete this.sequenceMapping[i.keytip.keySequences.toString()],this.sequenceMapping[o.keytip.keySequences.toString()]=o.keytip,(this.inKeytipMode||!this.delayUpdatingKeytipChange)&&Ws.raise(this,ja.KEYTIP_UPDATED,{keytip:o.keytip,uniqueID:o.uniqueID}))},e.prototype.unregister=function(t,n,r){r===void 0&&(r=!1),r?delete this.persistedKeytips[n]:delete this.keytips[n],!r&&delete this.sequenceMapping[t.keySequences.toString()];var o=r?ja.PERSISTED_KEYTIP_REMOVED:ja.KEYTIP_REMOVED;(this.inKeytipMode||!this.delayUpdatingKeytipChange)&&Ws.raise(this,o,{keytip:t,uniqueID:n})},e.prototype.enterKeytipMode=function(){Ws.raise(this,ja.ENTER_KEYTIP_MODE)},e.prototype.exitKeytipMode=function(){Ws.raise(this,ja.EXIT_KEYTIP_MODE)},e.prototype.getKeytips=function(){var t=this;return Object.keys(this.keytips).map(function(n){return t.keytips[n].keytip})},e.prototype.addParentOverflow=function(t){var n=Yi([],t.keySequences);if(n.pop(),n.length!==0){var r=this.sequenceMapping[n.toString()];if(r&&r.overflowSetSequence)return oe(oe({},t),{overflowSetSequence:r.overflowSetSequence})}return t},e.prototype.menuExecute=function(t,n){Ws.raise(this,ja.PERSISTED_KEYTIP_EXECUTE,{overflowButtonSequences:t,keytipSequences:n})},e.prototype._getUniqueKtp=function(t,n){return n===void 0&&(n=cu()),{keytip:oe({},t),uniqueID:n}},e._instance=new e,e}();function aR(e){return e.reduce(function(t,n){return t+sC+n.split("").join(sC)},tee)}function aee(e,t){var n=t.length,r=Yi([],t).pop(),o=Yi([],e);return qG(o,n-1,r)}function see(e){var t=" "+oee;return e.length?t+" "+aR(e):t}function lee(e){var t=T.useRef(),n=e.keytipProps?oe({disabled:e.disabled},e.keytipProps):void 0,r=A4(iee.getInstance()),o=tI(e);i0(function(){t.current&&n&&((o==null?void 0:o.keytipProps)!==e.keytipProps||(o==null?void 0:o.disabled)!==e.disabled)&&r.update(n,t.current)}),i0(function(){return n&&(t.current=r.register(n)),function(){n&&r.unregister(n,t.current)}},[]);var i={ariaDescribedBy:void 0,keytipId:void 0};return n&&(i=uee(r,n,e.ariaDescribedBy)),i}function uee(e,t,n){var r=e.addParentOverflow(t),o=$0(n,see(r.keySequences)),i=Yi([],r.keySequences);r.overflowSetSequence&&(i=aee(i,r.overflowSetSequence));var a=aR(i);return{ariaDescribedBy:o,keytipId:a}}var x0=function(e){var t,n=e.children,r=pl(e,["children"]),o=lee(r),i=o.keytipId,a=o.ariaDescribedBy;return n((t={},t[nee]=i,t[ree]=i,t["aria-describedby"]=a,t))},cee=function(e){yi(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n._anchor=T.createRef(),n._getMemoizedMenuButtonKeytipProps=Cr(function(r){return oe(oe({},r),{hasMenu:!0})}),n._getSubmenuTarget=function(){return n._anchor.current?n._anchor.current:void 0},n._onItemClick=function(r){var o=n.props,i=o.item,a=o.onItemClick;a&&a(i,r)},n._renderAriaDescription=function(r,o){return r?T.createElement("span",{id:n._ariaDescriptionId,className:o},r):null},n}return t.prototype.render=function(){var n=this,r=this.props,o=r.item,i=r.classNames,a=r.index,s=r.focusableElementIndex,l=r.totalItemCount,u=r.hasCheckmarks,d=r.hasIcons,h=r.contextualMenuItemAs,p=h===void 0?S0:h,m=r.expandedMenuItemKey,v=r.onItemClick,_=r.openSubMenu,b=r.dismissSubMenu,E=r.dismissMenu,w=o.rel;o.target&&o.target.toLowerCase()==="_blank"&&(w=w||"nofollow noopener noreferrer");var k=ll(o),y=Zr(o,LF),F=Ja(o),C=o.itemProps,A=o.ariaDescription,P=o.keytipProps;P&&k&&(P=this._getMemoizedMenuButtonKeytipProps(P)),A&&(this._ariaDescriptionId=cu());var I=$0(o.ariaDescribedBy,A?this._ariaDescriptionId:void 0,y["aria-describedby"]),j={"aria-describedby":I};return T.createElement("div",null,T.createElement(x0,{keytipProps:o.keytipProps,ariaDescribedBy:I,disabled:F},function(H){return T.createElement("a",oe({},j,y,H,{ref:n._anchor,href:o.href,target:o.target,rel:w,className:i.root,role:"menuitem","aria-haspopup":k||void 0,"aria-expanded":k?o.key===m:void 0,"aria-posinset":s+1,"aria-setsize":l,"aria-disabled":Ja(o),style:o.style,onClick:n._onItemClick,onMouseEnter:n._onItemMouseEnter,onMouseLeave:n._onItemMouseLeave,onMouseMove:n._onItemMouseMove,onKeyDown:k?n._onItemKeyDown:void 0}),T.createElement(p,oe({componentRef:o.componentRef,item:o,classNames:i,index:a,onCheckmarkClick:u&&v?v:void 0,hasIcons:d,openSubMenu:_,dismissSubMenu:b,dismissMenu:E,getSubmenuTarget:n._getSubmenuTarget},C)),n._renderAriaDescription(A,i.screenReaderText))}))},t}(AT),fee=function(e){yi(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n._btn=T.createRef(),n._getMemoizedMenuButtonKeytipProps=Cr(function(r){return oe(oe({},r),{hasMenu:!0})}),n._renderAriaDescription=function(r,o){return r?T.createElement("span",{id:n._ariaDescriptionId,className:o},r):null},n._getSubmenuTarget=function(){return n._btn.current?n._btn.current:void 0},n}return t.prototype.render=function(){var n=this,r=this.props,o=r.item,i=r.classNames,a=r.index,s=r.focusableElementIndex,l=r.totalItemCount,u=r.hasCheckmarks,d=r.hasIcons,h=r.contextualMenuItemAs,p=h===void 0?S0:h,m=r.expandedMenuItemKey,v=r.onItemMouseDown,_=r.onItemClick,b=r.openSubMenu,E=r.dismissSubMenu,w=r.dismissMenu,k=k0(o),y=k!==null,F=oR(o),C=ll(o),A=o.itemProps,P=o.ariaLabel,I=o.ariaDescription,j=Zr(o,Oc);delete j.disabled;var H=o.role||F;I&&(this._ariaDescriptionId=cu());var K=$0(o.ariaDescribedBy,I?this._ariaDescriptionId:void 0,j["aria-describedby"]),U={className:i.root,onClick:this._onItemClick,onKeyDown:C?this._onItemKeyDown:void 0,onMouseEnter:this._onItemMouseEnter,onMouseLeave:this._onItemMouseLeave,onMouseDown:function(se){return v?v(o,se):void 0},onMouseMove:this._onItemMouseMove,href:o.href,title:o.title,"aria-label":P,"aria-describedby":K,"aria-haspopup":C||void 0,"aria-expanded":C?o.key===m:void 0,"aria-posinset":s+1,"aria-setsize":l,"aria-disabled":Ja(o),"aria-checked":(H==="menuitemcheckbox"||H==="menuitemradio")&&y?!!k:void 0,"aria-selected":H==="menuitem"&&y?!!k:void 0,role:H,style:o.style},pe=o.keytipProps;return pe&&C&&(pe=this._getMemoizedMenuButtonKeytipProps(pe)),T.createElement(x0,{keytipProps:pe,ariaDescribedBy:K,disabled:Ja(o)},function(se){return T.createElement("button",oe({ref:n._btn},j,U,se),T.createElement(p,oe({componentRef:o.componentRef,item:o,classNames:i,index:a,onCheckmarkClick:u&&_?_:void 0,hasIcons:d,openSubMenu:b,dismissSubMenu:E,dismissMenu:w,getSubmenuTarget:n._getSubmenuTarget},A)),n._renderAriaDescription(I,i.screenReaderText))})},t}(AT),dee=function(e){var t=e.theme,n=e.getClassNames,r=e.className;if(!t)throw new Error("Theme is undefined or null.");if(n){var o=n(t);return{wrapper:[o.wrapper],divider:[o.divider]}}return{wrapper:[{display:"inline-flex",height:"100%",alignItems:"center"},r],divider:[{width:1,height:"100%",backgroundColor:t.palette.neutralTertiaryAlt}]}},hee=ml(),sR=T.forwardRef(function(e,t){var n=e.styles,r=e.theme,o=e.getClassNames,i=e.className,a=hee(n,{theme:r,getClassNames:o,className:i});return T.createElement("span",{className:a.wrapper,ref:t},T.createElement("span",{className:a.divider}))});sR.displayName="VerticalDividerBase";var pee=gl(sR,dee,void 0,{scope:"VerticalDivider"}),mee=500,gee=function(e){yi(t,e);function t(n){var r=e.call(this,n)||this;return r._getMemoizedMenuButtonKeytipProps=Cr(function(o){return oe(oe({},o),{hasMenu:!0})}),r._onItemKeyDown=function(o){var i=r.props,a=i.item,s=i.onItemKeyDown;o.which===qt.enter?(r._executeItemClick(o),o.preventDefault(),o.stopPropagation()):s&&s(a,o)},r._getSubmenuTarget=function(){return r._splitButton},r._renderAriaDescription=function(o,i){return o?T.createElement("span",{id:r._ariaDescriptionId,className:i},o):null},r._onItemMouseEnterPrimary=function(o){var i=r.props,a=i.item,s=i.onItemMouseEnter;s&&s(oe(oe({},a),{subMenuProps:void 0,items:void 0}),o,r._splitButton)},r._onItemMouseEnterIcon=function(o){var i=r.props,a=i.item,s=i.onItemMouseEnter;s&&s(a,o,r._splitButton)},r._onItemMouseMovePrimary=function(o){var i=r.props,a=i.item,s=i.onItemMouseMove;s&&s(oe(oe({},a),{subMenuProps:void 0,items:void 0}),o,r._splitButton)},r._onItemMouseMoveIcon=function(o){var i=r.props,a=i.item,s=i.onItemMouseMove;s&&s(a,o,r._splitButton)},r._onIconItemClick=function(o){var i=r.props,a=i.item,s=i.onItemClickBase;s&&s(a,o,r._splitButton?r._splitButton:o.currentTarget)},r._executeItemClick=function(o){var i=r.props,a=i.item,s=i.executeItemClick,l=i.onItemClick;if(!(a.disabled||a.isDisabled)){if(r._processingTouch&&l)return l(a,o);s&&s(a,o)}},r._onTouchStart=function(o){r._splitButton&&!("onpointerdown"in r._splitButton)&&r._handleTouchAndPointerEvent(o)},r._onPointerDown=function(o){o.pointerType==="touch"&&(r._handleTouchAndPointerEvent(o),o.preventDefault(),o.stopImmediatePropagation())},r._async=new _b(r),r._events=new Ws(r),r}return t.prototype.componentDidMount=function(){this._splitButton&&"onpointerdown"in this._splitButton&&this._events.on(this._splitButton,"pointerdown",this._onPointerDown,!0)},t.prototype.componentWillUnmount=function(){this._async.dispose(),this._events.dispose()},t.prototype.render=function(){var n=this,r=this.props,o=r.item,i=r.classNames,a=r.index,s=r.focusableElementIndex,l=r.totalItemCount,u=r.hasCheckmarks,d=r.hasIcons,h=r.onItemMouseLeave,p=r.expandedMenuItemKey,m=ll(o),v=o.keytipProps;v&&(v=this._getMemoizedMenuButtonKeytipProps(v));var _=o.ariaDescription;return _&&(this._ariaDescriptionId=cu()),T.createElement(x0,{keytipProps:v,disabled:Ja(o)},function(b){return T.createElement("div",{"data-ktp-target":b["data-ktp-target"],ref:function(E){return n._splitButton=E},role:oR(o),"aria-label":o.ariaLabel,className:i.splitContainer,"aria-disabled":Ja(o),"aria-expanded":m?o.key===p:void 0,"aria-haspopup":!0,"aria-describedby":$0(o.ariaDescribedBy,_?n._ariaDescriptionId:void 0,b["aria-describedby"]),"aria-checked":o.isChecked||o.checked,"aria-posinset":s+1,"aria-setsize":l,onMouseEnter:n._onItemMouseEnterPrimary,onMouseLeave:h?h.bind(n,oe(oe({},o),{subMenuProps:null,items:null})):void 0,onMouseMove:n._onItemMouseMovePrimary,onKeyDown:n._onItemKeyDown,onClick:n._executeItemClick,onTouchStart:n._onTouchStart,tabIndex:0,"data-is-focusable":!0,"aria-roledescription":o["aria-roledescription"]},n._renderSplitPrimaryButton(o,i,a,u,d),n._renderSplitDivider(o),n._renderSplitIconButton(o,i,a,b),n._renderAriaDescription(_,i.screenReaderText))})},t.prototype._renderSplitPrimaryButton=function(n,r,o,i,a){var s=this.props,l=s.contextualMenuItemAs,u=l===void 0?S0:l,d=s.onItemClick,h={key:n.key,disabled:Ja(n)||n.primaryDisabled,name:n.name,text:n.text||n.name,secondaryText:n.secondaryText,className:r.splitPrimary,canCheck:n.canCheck,isChecked:n.isChecked,checked:n.checked,iconProps:n.iconProps,onRenderIcon:n.onRenderIcon,data:n.data,"data-is-focusable":!1},p=n.itemProps;return T.createElement("button",oe({},Zr(h,Oc)),T.createElement(u,oe({"data-is-focusable":!1,item:h,classNames:r,index:o,onCheckmarkClick:i&&d?d:void 0,hasIcons:a},p)))},t.prototype._renderSplitDivider=function(n){var r=n.getSplitButtonVerticalDividerClassNames||ZJ;return T.createElement(pee,{getClassNames:r})},t.prototype._renderSplitIconButton=function(n,r,o,i){var a=this.props,s=a.contextualMenuItemAs,l=s===void 0?S0:s,u=a.onItemMouseLeave,d=a.onItemMouseDown,h=a.openSubMenu,p=a.dismissSubMenu,m=a.dismissMenu,v={onClick:this._onIconItemClick,disabled:Ja(n),className:r.splitMenu,subMenuProps:n.subMenuProps,submenuIconProps:n.submenuIconProps,split:!0,key:n.key},_=oe(oe({},Zr(v,Oc)),{onMouseEnter:this._onItemMouseEnterIcon,onMouseLeave:u?u.bind(this,n):void 0,onMouseDown:function(E){return d?d(n,E):void 0},onMouseMove:this._onItemMouseMoveIcon,"data-is-focusable":!1,"data-ktp-execute-target":i["data-ktp-execute-target"],"aria-hidden":!0}),b=n.itemProps;return T.createElement("button",oe({},_),T.createElement(l,oe({componentRef:n.componentRef,item:v,classNames:r,index:o,hasIcons:!1,openSubMenu:h,dismissSubMenu:p,dismissMenu:m,getSubmenuTarget:this._getSubmenuTarget},b)))},t.prototype._handleTouchAndPointerEvent=function(n){var r=this,o=this.props.onTap;o&&o(n),this._lastTouchTimeoutId&&(this._async.clearTimeout(this._lastTouchTimeoutId),this._lastTouchTimeoutId=void 0),this._processingTouch=!0,this._lastTouchTimeoutId=this._async.setTimeout(function(){r._processingTouch=!1,r._lastTouchTimeoutId=void 0},mee)},t}(AT),C0;(function(e){e[e.small=0]="small",e[e.medium=1]="medium",e[e.large=2]="large",e[e.xLarge=3]="xLarge",e[e.xxLarge=4]="xxLarge",e[e.xxxLarge=5]="xxxLarge",e[e.unknown=999]="unknown"})(C0||(C0={}));var vee=[479,639,1023,1365,1919,99999999],lR;function uR(){var e;return(e=lR)!==null&&e!==void 0?e:C0.large}function bee(e){var t=C0.small;if(e){try{for(;e.innerWidth>vee[t];)t++}catch{t=uR()}lR=t}else throw new Error("Content was rendered in a server environment without providing a default responsive mode. Call setResponsiveMode to define what the responsive mode is.");return t}var yee=function(e,t){var n=T.useState(uR()),r=n[0],o=n[1],i=T.useCallback(function(){var s=bee(ur(e.current));r!==s&&o(s)},[e,r]),a=N4();return l0(a,"resize",i),T.useEffect(function(){t===void 0&&i()},[t]),t??r},Eee=T.createContext({}),_ee=ml(),Tee=ml(),wee={items:[],shouldFocusOnMount:!0,gapSpace:0,directionalHint:hr.bottomAutoEdge,beakWidth:16};function cR(e,t){var n=t==null?void 0:t.target,r=e.subMenuProps?e.subMenuProps.items:e.items;if(r){for(var o=[],i=0,a=r;i<a.length;i++){var s=a[i];if(s.preferMenuTargetAsEventTarget){var l=s.onClick,u=pl(s,["onClick"]);o.push(oe(oe({},u),{onClick:mR(l,n)}))}else o.push(s)}return o}}function kee(e){return e.some(function(t){return!!(t.canCheck||t.sectionProps&&t.sectionProps.items.some(function(n){return n.canCheck===!0}))})}var fR=250,dR="ContextualMenu",See=Cr(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return function(n){return kF.apply(void 0,Yi([n,iR],e))}});function xee(e,t){var n=e.hidden,r=n===void 0?!1:n,o=e.onMenuDismissed,i=e.onMenuOpened,a=tI(r),s=T.useRef(i),l=T.useRef(o),u=T.useRef(e);s.current=i,l.current=o,u.current=e,T.useEffect(function(){var d,h;r&&a===!1?(d=l.current)===null||d===void 0||d.call(l,u.current):!r&&a!==!1&&((h=s.current)===null||h===void 0||h.call(s,u.current))},[r,a]),T.useEffect(function(){return function(){var d;return(d=l.current)===null||d===void 0?void 0:d.call(l,u.current)}},[])}function Cee(e,t){var n=e.hidden,r=e.items,o=e.theme,i=e.className,a=e.id,s=e.target,l=T.useState(),u=l[0],d=l[1],h=T.useState(),p=h[0],m=h[1],v=eI(dR,a),_=T.useCallback(function(){d(void 0),m(void 0)},[]),b=T.useCallback(function(k,y){var F=k.key;u!==F&&(y.focus(),d(F),m(y))},[u]);T.useEffect(function(){n&&_()},[n,_]);var E=Bee(t,_),w=function(){var k=pR(u,r),y=null;if(k&&(y={items:cR(k,{target:s}),target:p,onDismiss:E,isSubMenu:!0,id:v,shouldFocusOnMount:!0,directionalHint:ls(o)?hr.leftTopEdge:hr.rightTopEdge,className:i,gapSpace:0,isBeakVisible:!1},k.subMenuProps&&pc(y,k.subMenuProps),k.preferMenuTargetAsEventTarget)){var F=k.onItemClick;y.onItemClick=mR(F,s)}return y};return[u,b,w,E]}function Aee(e){var t=e.delayUpdateFocusOnHover,n=e.hidden,r=T.useRef(!t),o=T.useRef(!1);T.useEffect(function(){r.current=!t,o.current=n?!1:!t&&o.current},[t,n]);var i=T.useCallback(function(){t&&(r.current=!1)},[t]);return[r,o,i]}function Nee(e,t){var n=e.hidden,r=e.onRestoreFocus,o=T.useRef(),i=T.useCallback(function(a){var s,l;r?r(a):a!=null&&a.documentContainsFocus&&((l=(s=o.current)===null||s===void 0?void 0:s.focus)===null||l===void 0||l.call(s))},[r]);return i0(function(){var a;n?o.current&&(i({originalElement:o.current,containsFocus:!0,documentContainsFocus:((a=ss())===null||a===void 0?void 0:a.hasFocus())||!1}),o.current=void 0):o.current=t==null?void 0:t.document.activeElement},[n,t==null?void 0:t.document.activeElement,i]),[i]}function Fee(e,t,n,r){var o=e.theme,i=e.isSubMenu,a=e.focusZoneProps,s=a===void 0?{}:a,l=s.checkForNoWrap,u=s.direction,d=u===void 0?ao.vertical:u,h=T.useRef(),p=function(y,F,C){var A=!1;return F(y)&&(t(y,C),y.preventDefault(),y.stopPropagation(),A=!0),A},m=function(y){var F=ls(o)?qt.right:qt.left;return y.which!==F||!i?!1:!!(d===ao.vertical||l&&!sK(y.target,"data-no-horizontal-wrap"))},v=function(y){return y.which===qt.escape||m(y)||y.which===qt.up&&(y.altKey||y.metaKey)},_=function(y){h.current=lC(y);var F=y.which===qt.escape&&(mx()||px());return p(y,v,F)},b=function(y){var F=h.current&&lC(y);return h.current=!1,!!F&&!(px()||mx())},E=function(y){return p(y,b,!0)},w=function(y){var F=_(y);if(!(F||!n.current)){var C=!!(y.altKey||y.metaKey),A=y.which===qt.up,P=y.which===qt.down;if(!C&&(A||P)){var I=A?oK(n.current,n.current.lastChild,!0):rK(n.current,n.current.firstChild,!0);I&&(I.focus(),y.preventDefault(),y.stopPropagation())}}},k=function(y,F){var C=ls(o)?qt.left:qt.right;!y.disabled&&(F.which===C||F.which===qt.enter||F.which===qt.down&&(F.altKey||F.metaKey))&&(r(y,F.currentTarget,!1),F.preventDefault())};return[_,E,w,k]}function Iee(e){var t=T.useRef(!0),n=T.useRef(),r=function(){!t.current&&n.current!==void 0?(e.clearTimeout(n.current),n.current=void 0):t.current=!1,n.current=e.setTimeout(function(){t.current=!0},fR)};return[r,t]}function Bee(e,t){var n=T.useRef(!1);T.useEffect(function(){return n.current=!0,function(){n.current=!1}},[]);var r=function(o,i){i?e(o,i):n.current&&t()};return r}function Ree(e,t){var n=e.subMenuHoverDelay,r=n===void 0?fR:n,o=T.useRef(void 0),i=function(){o.current!==void 0&&(t.clearTimeout(o.current),o.current=void 0)},a=function(s){o.current=t.setTimeout(function(){s(),i()},r)};return[i,a,o]}function Oee(e,t,n,r,o,i,a,s,l,u,d,h,p){var m=e.target,v=function(A,P,I){o.current&&(i.current=!0),!b()&&w(A,P,I)},_=function(A,P,I){var j=P.currentTarget;if(o.current)i.current=!0;else return;!t.current||n.current!==void 0||j===(r==null?void 0:r.document.activeElement)||w(A,P,I)},b=function(){return!t.current||!i.current},E=function(A,P){var I;if(!b()&&(u(),a===void 0))if(s.current.setActive)try{s.current.setActive()}catch{}else(I=s.current)===null||I===void 0||I.focus()},w=function(A,P,I){var j=I||P.currentTarget;A.key!==a&&(u(),a===void 0&&j.focus(),ll(A)?(P.stopPropagation(),l(function(){j.focus(),d(A,j,!0)})):l(function(){h(P),j.focus()}))},k=function(A,P){y(A,P,P.currentTarget)},y=function(A,P,I){var j=cR(A,{target:m});u(),!ll(A)&&(!j||!j.length)?C(A,P):A.key!==a&&d(A,I,P.nativeEvent.detail!==0||P.nativeEvent.pointerType==="mouse"),P.stopPropagation(),P.preventDefault()},F=function(A,P){C(A,P),P.stopPropagation()},C=function(A,P){if(!(A.disabled||A.isDisabled)){A.preferMenuTargetAsEventTarget&&gR(P,m);var I=!1;A.onClick?I=!!A.onClick(P,A):e.onItemClick&&(I=!!e.onItemClick(P,A)),(I||!P.defaultPrevented)&&p(P,!0)}};return[v,_,E,k,F,C,y]}var hR=T.memo(T.forwardRef(function(e,t){var n,r=S4(wee,e);r.ref;var o=pl(r,["ref"]),i=T.useRef(null),a=Zd(),s=eI(dR,o.id),l=function(B,z){var ee;return(ee=o.onDismiss)===null||ee===void 0?void 0:ee.call(o,B,z)},u=rI(o.target,i),d=u[0],h=u[1],p=Nee(o,h)[0],m=Cee(o,l),v=m[0],_=m[1],b=m[2],E=m[3],w=Aee(o),k=w[0],y=w[1],F=w[2],C=Iee(a),A=C[0],P=C[1],I=Ree(o,a),j=I[0],H=I[1],K=I[2],U=yee(i,o.responsiveMode);xee(o);var pe=Fee(o,l,i,_),se=pe[0],J=pe[1],$=pe[2],_e=pe[3],ve=Oee(o,P,K,h,k,y,v,i,H,j,_,E,l),fe=ve[0],R=ve[1],L=ve[2],Ae=ve[3],Ue=ve[4],Ve=ve[5],Le=ve[6],st=function(B,z,ee){var ue=0,ce=B.items,te=B.totalItemCount,he=B.hasCheckmarks,Be=B.hasIcons;return T.createElement("ul",{className:z.list,onKeyDown:se,onKeyUp:J,role:"presentation"},ce.map(function(He,tt){var vt=rt(He,tt,ue,te,he,Be,z);if(He.itemType!==Ko.Divider&&He.itemType!==Ko.Header){var at=He.customOnRenderListLength?He.customOnRenderListLength:1;ue+=at}return vt}))},We=function(B,z){var ee=o.focusZoneAs,ue=ee===void 0?rR:ee;return T.createElement(ue,oe({},z),B)},rt=function(B,z,ee,ue,ce,te,he){var Be,He=[],tt=B.iconProps||{iconName:"None"},vt=B.getItemClassNames,at=B.itemProps,Mt=at?at.styles:void 0,en=B.itemType===Ko.Divider?B.className:void 0,Xe=B.submenuIconProps?B.submenuIconProps.className:"",Vt;if(vt)Vt=vt(o.theme,Ja(B),v===B.key,!!k0(B),!!B.href,tt.iconName!=="None",B.className,en,tt.className,Xe,B.primaryDisabled);else{var Hr={theme:o.theme,disabled:Ja(B),expanded:v===B.key,checked:!!k0(B),isAnchorLink:!!B.href,knownIcon:tt.iconName!=="None",itemClassName:B.className,dividerClassName:en,iconClassName:tt.className,subMenuClassName:Xe,primaryDisabled:B.primaryDisabled};Vt=Tee(See((Be=he.subComponentStyles)===null||Be===void 0?void 0:Be.menuItem,Mt),Hr)}switch((B.text==="-"||B.name==="-")&&(B.itemType=Ko.Divider),B.itemType){case Ko.Divider:He.push(tr(z,Vt));break;case Ko.Header:He.push(tr(z,Vt));var ri=br(B,Vt,he,z,ce,te);He.push(er(ri,B.key||z,Vt,B.title));break;case Ko.Section:He.push(qn(B,Vt,he,z,ce,te));break;default:var _s=function(){return In(B,Vt,z,ee,ue,ce,te)},oi=o.onRenderContextualMenuItem?o.onRenderContextualMenuItem(B,_s):_s();He.push(er(oi,B.key||z,Vt,B.title));break}return T.createElement(T.Fragment,{key:B.key},He)},Zt=function(B,z){var ee=B.index,ue=B.focusableElementIndex,ce=B.totalItemCount,te=B.hasCheckmarks,he=B.hasIcons;return rt(B,ee,ue,ce,te,he,z)},qn=function(B,z,ee,ue,ce,te){var he=B.sectionProps;if(he){var Be,He;if(he.title){var tt=void 0,vt="";if(typeof he.title=="string"){var at=s+he.title.replace(/\s/g,"");tt={key:"section-"+he.title+"-title",itemType:Ko.Header,text:he.title,id:at},vt=at}else{var Mt=he.title.id||s+he.title.key.replace(/\s/g,"");tt=oe(oe({},he.title),{id:Mt}),vt=Mt}tt&&(He={role:"group","aria-labelledby":vt},Be=br(tt,z,ee,ue,ce,te))}if(he.items&&he.items.length>0)return T.createElement("li",{role:"presentation",key:he.key||B.key||"section-"+ue},T.createElement("div",oe({},He),T.createElement("ul",{className:ee.list,role:"presentation"},he.topDivider&&tr(ue,z,!0,!0),Be&&er(Be,B.key||ue,z,B.title),he.items.map(function(en,Xe){return rt(en,Xe,Xe,he.items.length,ce,te,ee)}),he.bottomDivider&&tr(ue,z,!1,!0))))}},er=function(B,z,ee,ue){return T.createElement("li",{role:"presentation",title:ue,key:z,className:ee.item},B)},tr=function(B,z,ee,ue){return ue||B>0?T.createElement("li",{role:"separator",key:"separator-"+B+(ee===void 0?"":ee?"-top":"-bottom"),className:z.divider,"aria-hidden":"true"}):null},In=function(B,z,ee,ue,ce,te,he){if(B.onRender)return B.onRender(oe({"aria-posinset":ue+1,"aria-setsize":ce},B),l);var Be=o.contextualMenuItemAs,He={item:B,classNames:z,index:ee,focusableElementIndex:ue,totalItemCount:ce,hasCheckmarks:te,hasIcons:he,contextualMenuItemAs:Be,onItemMouseEnter:fe,onItemMouseLeave:L,onItemMouseMove:R,onItemMouseDown:Dee,executeItemClick:Ve,onItemKeyDown:_e,expandedMenuItemKey:v,openSubMenu:_,dismissSubMenu:E,dismissMenu:l};return B.href?T.createElement(cee,oe({},He,{onItemClick:Ue})):B.split&&ll(B)?T.createElement(gee,oe({},He,{onItemClick:Ae,onItemClickBase:Le,onTap:j})):T.createElement(fee,oe({},He,{onItemClick:Ae,onItemClickBase:Le}))},br=function(B,z,ee,ue,ce,te){var he=o.contextualMenuItemAs,Be=he===void 0?S0:he,He=B.itemProps,tt=B.id,vt=He&&Zr(He,W0);return T.createElement("div",oe({id:tt,className:ee.header},vt,{style:B.style}),T.createElement(Be,oe({item:B,classNames:z,index:ue,onCheckmarkClick:ce?Ae:void 0,hasIcons:te},He)))},Nr=o.isBeakVisible,an=o.items,yo=o.labelElementId,Eo=o.id,jr=o.className,pn=o.beakWidth,Mn=o.directionalHint,mn=o.directionalHintForRTL,Po=o.alignTargetEdge,me=o.gapSpace,le=o.coverTarget,ie=o.ariaLabel,G=o.doNotLayer,ae=o.target,Te=o.bounds,Oe=o.useTargetWidth,$e=o.useTargetAsMinWidth,_t=o.directionalHintFixed,Qe=o.shouldFocusOnMount,lt=o.shouldFocusOnContainer,Kt=o.title,Pt=o.styles,gt=o.theme,Ln=o.calloutProps,Tn=o.onRenderSubMenu,zr=Tn===void 0?uC:Tn,wn=o.onRenderMenuList,kt=wn===void 0?function(B,z){return st(B,rr)}:wn,nr=o.focusZoneProps,dr=o.getMenuClassNames,rr=dr?dr(gt,jr):_ee(Pt,{theme:gt,className:jr}),to=Fr(an);function Fr(B){for(var z=0,ee=B;z<ee.length;z++){var ue=ee[z];if(ue.iconProps||ue.itemType===Ko.Section&&ue.sectionProps&&Fr(ue.sectionProps.items))return!0}return!1}var _o=oe(oe({direction:ao.vertical,handleTabKey:f_.all,isCircularNavigation:!0},nr),{className:Ys(rr.root,(n=o.focusZoneProps)===null||n===void 0?void 0:n.className)}),Ia=kee(an),wi=v&&o.hidden!==!0?b():null;Nr=Nr===void 0?U<=C0.medium:Nr;var ju,ki=d.current;if((Oe||$e)&&ki&&ki.offsetWidth){var _1=ki.getBoundingClientRect(),Xc=_1.width-2;Oe?ju={width:Xc}:$e&&(ju={minWidth:Xc})}if(an&&an.length>0){for(var Zc=0,zu=0,Es=an;zu<Es.length;zu++){var q=Es[zu];if(q.itemType!==Ko.Divider&&q.itemType!==Ko.Header){var W=q.customOnRenderListLength?q.customOnRenderListLength:1;Zc+=W}}var O=rr.subComponentStyles?rr.subComponentStyles.callout:void 0;return T.createElement(Eee.Consumer,null,function(B){return T.createElement(HB,oe({styles:O,onRestoreFocus:p},Ln,{target:ae||B.target,isBeakVisible:Nr,beakWidth:pn,directionalHint:Mn,directionalHintForRTL:mn,gapSpace:me,coverTarget:le,doNotLayer:G,className:Ys("ms-ContextualMenu-Callout",Ln&&Ln.className),setInitialFocus:Qe,onDismiss:o.onDismiss||B.onDismiss,onScroll:A,bounds:Te,directionalHintFixed:_t,alignTargetEdge:Po,hidden:o.hidden||B.hidden,ref:t}),T.createElement("div",{style:ju,ref:i,id:Eo,className:rr.container,tabIndex:lt?0:-1,onKeyDown:$,onKeyUp:J,onFocusCapture:F,"aria-label":ie,"aria-labelledby":yo,role:"menu"},Kt&&T.createElement("div",{className:rr.title}," ",Kt," "),an&&an.length?We(kt({ariaLabel:ie,items:an,totalItemCount:Zc,hasCheckmarks:Ia,hasIcons:to,defaultMenuItemRenderer:function(z){return Zt(z,rr)},labelElementId:yo},function(z,ee){return st(z,rr)}),_o):null,wi&&zr(wi,uC)))})}else return null}),function(e,t){return!t.shouldUpdateWhenHidden&&e.hidden&&t.hidden?!0:T4(e,t)});hR.displayName="ContextualMenuBase";function lC(e){return e.which===qt.alt||e.key==="Meta"}function Dee(e,t){var n;(n=e.onMouseDown)===null||n===void 0||n.call(e,e,t)}function uC(e,t){throw Error("ContextualMenuBase: onRenderSubMenu callback is null or undefined. Please ensure to set `onRenderSubMenu` property either manually or with `styled` helper.")}function pR(e,t){for(var n=0,r=t;n<r.length;n++){var o=r[n];if(o.itemType===Ko.Section&&o.sectionProps){var i=pR(e,o.sectionProps.items);if(i)return i}else if(o.key&&o.key===e)return o}}function mR(e,t){return e&&function(n,r){return gR(n,t),e(n,r)}}function gR(e,t){e&&t&&(e.persist(),t instanceof Event?e.target=t.target:t instanceof Element&&(e.target=t))}var Pee={root:"ms-ContextualMenu",container:"ms-ContextualMenu-container",list:"ms-ContextualMenu-list",header:"ms-ContextualMenu-header",title:"ms-ContextualMenu-title",isopen:"is-open"},Mee=function(e){var t=e.className,n=e.theme,r=hs(Pee,n),o=n.fonts,i=n.semanticColors,a=n.effects;return{root:[n.fonts.medium,r.root,r.isopen,{backgroundColor:i.menuBackground,minWidth:"180px"},t],container:[r.container,{selectors:{":focus":{outline:0}}}],list:[r.list,r.isopen,{listStyleType:"none",margin:"0",padding:"0"}],header:[r.header,o.small,{fontWeight:Rn.semibold,color:i.menuHeader,background:"none",backgroundColor:"transparent",border:"none",height:Xl,lineHeight:Xl,cursor:"default",padding:"0px 6px",userSelect:"none",textAlign:"left"}],title:[r.title,{fontSize:o.mediumPlus.fontSize,paddingRight:"14px",paddingLeft:"14px",paddingBottom:"5px",paddingTop:"5px",backgroundColor:i.menuItemBackgroundPressed}],subComponentStyles:{callout:{root:{boxShadow:a.elevation8}},menuItem:{}}}};function cC(e){return T.createElement(vR,oe({},e))}var vR=gl(hR,Mee,function(e){return{onRenderSubMenu:e.onRenderSubMenu?HF(e.onRenderSubMenu,cC):cC}},{scope:"ContextualMenu"}),g_=vR;g_.displayName="ContextualMenu";var fC={msButton:"ms-Button",msButtonHasMenu:"ms-Button--hasMenu",msButtonIcon:"ms-Button-icon",msButtonMenuIcon:"ms-Button-menuIcon",msButtonLabel:"ms-Button-label",msButtonDescription:"ms-Button-description",msButtonScreenReaderText:"ms-Button-screenReaderText",msButtonFlexContainer:"ms-Button-flexContainer",msButtonTextContainer:"ms-Button-textContainer"},Lee=Cr(function(e,t,n,r,o,i,a,s,l,u,d){var h,p,m=hs(fC,e||{}),v=u&&!d;return q0({root:[m.msButton,t.root,r,l&&["is-checked",t.rootChecked],v&&["is-expanded",t.rootExpanded,{selectors:(h={},h[":hover ."+m.msButtonIcon]=t.iconExpandedHovered,h[":hover ."+m.msButtonMenuIcon]=t.menuIconExpandedHovered||t.rootExpandedHovered,h[":hover"]=t.rootExpandedHovered,h)}],s&&[fC.msButtonHasMenu,t.rootHasMenu],a&&["is-disabled",t.rootDisabled],!a&&!v&&!l&&{selectors:(p={":hover":t.rootHovered},p[":hover ."+m.msButtonLabel]=t.labelHovered,p[":hover ."+m.msButtonIcon]=t.iconHovered,p[":hover ."+m.msButtonDescription]=t.descriptionHovered,p[":hover ."+m.msButtonMenuIcon]=t.menuIconHovered,p[":focus"]=t.rootFocused,p[":active"]=t.rootPressed,p[":active ."+m.msButtonIcon]=t.iconPressed,p[":active ."+m.msButtonDescription]=t.descriptionPressed,p[":active ."+m.msButtonMenuIcon]=t.menuIconPressed,p)},a&&l&&[t.rootCheckedDisabled],!a&&l&&{selectors:{":hover":t.rootCheckedHovered,":active":t.rootCheckedPressed}},n],flexContainer:[m.msButtonFlexContainer,t.flexContainer],textContainer:[m.msButtonTextContainer,t.textContainer],icon:[m.msButtonIcon,o,t.icon,v&&t.iconExpanded,l&&t.iconChecked,a&&t.iconDisabled],label:[m.msButtonLabel,t.label,l&&t.labelChecked,a&&t.labelDisabled],menuIcon:[m.msButtonMenuIcon,i,t.menuIcon,l&&t.menuIconChecked,a&&!d&&t.menuIconDisabled,!a&&!v&&!l&&{selectors:{":hover":t.menuIconHovered,":active":t.menuIconPressed}},v&&["is-expanded",t.menuIconExpanded]],description:[m.msButtonDescription,t.description,l&&t.descriptionChecked,a&&t.descriptionDisabled],screenReaderText:[m.msButtonScreenReaderText,t.screenReaderText]})}),jee=Cr(function(e,t,n,r,o){return{root:Fo(e.splitButtonMenuButton,n&&[e.splitButtonMenuButtonExpanded],t&&[e.splitButtonMenuButtonDisabled],r&&!t&&[e.splitButtonMenuButtonChecked],o&&!t&&[{selectors:{":focus":e.splitButtonMenuFocused}}]),splitButtonContainer:Fo(e.splitButtonContainer,!t&&r&&[e.splitButtonContainerChecked,{selectors:{":hover":e.splitButtonContainerCheckedHovered}}],!t&&!r&&[{selectors:{":hover":e.splitButtonContainerHovered,":focus":e.splitButtonContainerFocused}}],t&&e.splitButtonContainerDisabled),icon:Fo(e.splitButtonMenuIcon,t&&e.splitButtonMenuIconDisabled,!t&&o&&e.splitButtonMenuIcon),flexContainer:Fo(e.splitButtonFlexContainer),divider:Fo(e.splitButtonDivider,(o||t)&&e.splitButtonDividerDisabled)}}),zee=500,Hee="BaseButton",Uee=function(e){yi(t,e);function t(n){var r=e.call(this,n)||this;return r._buttonElement=T.createRef(),r._splitButtonContainer=T.createRef(),r._mergedRef=XK(),r._renderedVisibleMenu=!1,r._getMemoizedMenuButtonKeytipProps=Cr(function(o){return oe(oe({},o),{hasMenu:!0})}),r._onRenderIcon=function(o,i){var a=r.props.iconProps;if(a&&(a.iconName!==void 0||a.imageProps)){var s=a.className,l=a.imageProps,u=pl(a,["className","imageProps"]);if(a.styles)return T.createElement(sl,oe({className:Ys(r._classNames.icon,s),imageProps:l},u));if(a.iconName)return T.createElement(c_,oe({className:Ys(r._classNames.icon,s)},u));if(l)return T.createElement(mZ,oe({className:Ys(r._classNames.icon,s),imageProps:l},u))}return null},r._onRenderTextContents=function(){var o=r.props,i=o.text,a=o.children,s=o.secondaryText,l=s===void 0?r.props.description:s,u=o.onRenderText,d=u===void 0?r._onRenderText:u,h=o.onRenderDescription,p=h===void 0?r._onRenderDescription:h;return i||typeof a=="string"||l?T.createElement("span",{className:r._classNames.textContainer},d(r.props,r._onRenderText),p(r.props,r._onRenderDescription)):[d(r.props,r._onRenderText),p(r.props,r._onRenderDescription)]},r._onRenderText=function(){var o=r.props.text,i=r.props.children;return o===void 0&&typeof i=="string"&&(o=i),r._hasText()?T.createElement("span",{key:r._labelId,className:r._classNames.label,id:r._labelId},o):null},r._onRenderChildren=function(){var o=r.props.children;return typeof o=="string"?null:o},r._onRenderDescription=function(o){var i=o.secondaryText,a=i===void 0?r.props.description:i;return a?T.createElement("span",{key:r._descriptionId,className:r._classNames.description,id:r._descriptionId},a):null},r._onRenderAriaDescription=function(){var o=r.props.ariaDescription;return o?T.createElement("span",{className:r._classNames.screenReaderText,id:r._ariaDescriptionId},o):null},r._onRenderMenuIcon=function(o){var i=r.props.menuIconProps;return T.createElement(c_,oe({iconName:"ChevronDown"},i,{className:r._classNames.menuIcon}))},r._onRenderMenu=function(o){var i=r.props.menuAs?PF(r.props.menuAs,g_):g_;return T.createElement(i,oe({},o))},r._onDismissMenu=function(o){var i=r.props.menuProps;i&&i.onDismiss&&i.onDismiss(o),(!o||!o.defaultPrevented)&&r._dismissMenu()},r._dismissMenu=function(){r._menuShouldFocusOnMount=void 0,r._menuShouldFocusOnContainer=void 0,r.setState({menuHidden:!0})},r._openMenu=function(o,i){i===void 0&&(i=!0),r.props.menuProps&&(r._menuShouldFocusOnContainer=o,r._menuShouldFocusOnMount=i,r._renderedVisibleMenu=!0,r.setState({menuHidden:!1}))},r._onToggleMenu=function(o){var i=!0;r.props.menuProps&&r.props.menuProps.shouldFocusOnMount===!1&&(i=!1),r.state.menuHidden?r._openMenu(o,i):r._dismissMenu()},r._onSplitContainerFocusCapture=function(o){var i=r._splitButtonContainer.current;!i||o.target&&XG(o.target,i)||i.focus()},r._onSplitButtonPrimaryClick=function(o){r.state.menuHidden||r._dismissMenu(),!r._processingTouch&&r.props.onClick?r.props.onClick(o):r._processingTouch&&r._onMenuClick(o)},r._onKeyDown=function(o){r.props.disabled&&(o.which===qt.enter||o.which===qt.space)?(o.preventDefault(),o.stopPropagation()):r.props.disabled||(r.props.menuProps?r._onMenuKeyDown(o):r.props.onKeyDown!==void 0&&r.props.onKeyDown(o))},r._onKeyUp=function(o){!r.props.disabled&&r.props.onKeyUp!==void 0&&r.props.onKeyUp(o)},r._onKeyPress=function(o){!r.props.disabled&&r.props.onKeyPress!==void 0&&r.props.onKeyPress(o)},r._onMouseUp=function(o){!r.props.disabled&&r.props.onMouseUp!==void 0&&r.props.onMouseUp(o)},r._onMouseDown=function(o){!r.props.disabled&&r.props.onMouseDown!==void 0&&r.props.onMouseDown(o)},r._onClick=function(o){r.props.disabled||(r.props.menuProps?r._onMenuClick(o):r.props.onClick!==void 0&&r.props.onClick(o))},r._onSplitButtonContainerKeyDown=function(o){o.which===qt.enter||o.which===qt.space?r._buttonElement.current&&(r._buttonElement.current.click(),o.preventDefault(),o.stopPropagation()):r._onMenuKeyDown(o)},r._onMenuKeyDown=function(o){if(!r.props.disabled){r.props.onKeyDown&&r.props.onKeyDown(o);var i=o.which===qt.up,a=o.which===qt.down;if(!o.defaultPrevented&&r._isValidMenuOpenKey(o)){var s=r.props.onMenuClick;s&&s(o,r.props),r._onToggleMenu(!1),o.preventDefault(),o.stopPropagation()}if((o.which===qt.enter||o.which===qt.space)&&dd(!0,o.target),!(o.altKey||o.metaKey)&&(i||a)&&!r.state.menuHidden&&r.props.menuProps){var l=r._menuShouldFocusOnMount!==void 0?r._menuShouldFocusOnMount:r.props.menuProps.shouldFocusOnMount;l||(o.preventDefault(),o.stopPropagation(),r._menuShouldFocusOnMount=!0,r.forceUpdate())}}},r._onTouchStart=function(){r._isSplitButton&&r._splitButtonContainer.current&&!("onpointerdown"in r._splitButtonContainer.current)&&r._handleTouchAndPointerEvent()},r._onMenuClick=function(o){var i=r.props,a=i.onMenuClick,s=i.menuProps;a&&a(o,r.props),o.defaultPrevented||(r._onToggleMenu((s==null?void 0:s.shouldFocusOnContainer)||!1),o.preventDefault(),o.stopPropagation())},Tb(r),r._async=new _b(r),r._events=new Ws(r),CF(Hee,n,["menuProps","onClick"],"split",r.props.split),r._labelId=cu(),r._descriptionId=cu(),r._ariaDescriptionId=cu(),r.state={menuHidden:!0},r}return Object.defineProperty(t.prototype,"_isSplitButton",{get:function(){return!!this.props.menuProps&&!!this.props.onClick&&this.props.split===!0},enumerable:!1,configurable:!0}),t.prototype.render=function(){var n,r=this.props,o=r.ariaDescription,i=r.ariaLabel,a=r.ariaHidden,s=r.className,l=r.disabled,u=r.allowDisabledFocus,d=r.primaryDisabled,h=r.secondaryText,p=h===void 0?this.props.description:h,m=r.href,v=r.iconProps,_=r.menuIconProps,b=r.styles,E=r.checked,w=r.variantClassName,k=r.theme,y=r.toggle,F=r.getClassNames,C=r.role,A=this.state.menuHidden,P=l||d;this._classNames=F?F(k,s,w,v&&v.className,_&&_.className,P,E,!A,!!this.props.menuProps,this.props.split,!!u):Lee(k,b,s,w,v&&v.className,_&&_.className,P,!!this.props.menuProps,E,!A,this.props.split);var I=this,j=I._ariaDescriptionId,H=I._labelId,K=I._descriptionId,U=!P&&!!m,pe=U?"a":"button",se=Zr(pc(U?{}:{type:"button"},this.props.rootProps,this.props),U?LF:Oc,["disabled"]),J=i||se["aria-label"],$=void 0;o?$=j:p&&this.props.onRenderDescription!==AF?$=K:se["aria-describedby"]&&($=se["aria-describedby"]);var _e=void 0;se["aria-labelledby"]?_e=se["aria-labelledby"]:$&&!J&&(_e=this._hasText()?H:void 0);var ve=!(this.props["data-is-focusable"]===!1||l&&!u||this._isSplitButton),fe=C==="menuitemcheckbox"||C==="checkbox",R=fe||y===!0?!!E:void 0,L=pc(se,(n={className:this._classNames.root,ref:this._mergedRef(this.props.elementRef,this._buttonElement),disabled:P&&!u,onKeyDown:this._onKeyDown,onKeyPress:this._onKeyPress,onKeyUp:this._onKeyUp,onMouseDown:this._onMouseDown,onMouseUp:this._onMouseUp,onClick:this._onClick,"aria-label":J,"aria-labelledby":_e,"aria-describedby":$,"aria-disabled":P,"data-is-focusable":ve},n[fe?"aria-checked":"aria-pressed"]=R,n));if(a&&(L["aria-hidden"]=!0),this._isSplitButton)return this._onRenderSplitButtonContent(pe,L);if(this.props.menuProps){var Ae=this.props.menuProps.id,Ue=Ae===void 0?this._labelId+"-menu":Ae;pc(L,{"aria-expanded":!A,"aria-controls":A?null:Ue,"aria-haspopup":!0})}return this._onRenderContent(pe,L)},t.prototype.componentDidMount=function(){this._isSplitButton&&this._splitButtonContainer.current&&("onpointerdown"in this._splitButtonContainer.current&&this._events.on(this._splitButtonContainer.current,"pointerdown",this._onPointerDown,!0),"onpointerup"in this._splitButtonContainer.current&&this.props.onPointerUp&&this._events.on(this._splitButtonContainer.current,"pointerup",this.props.onPointerUp,!0))},t.prototype.componentDidUpdate=function(n,r){this.props.onAfterMenuDismiss&&!r.menuHidden&&this.state.menuHidden&&this.props.onAfterMenuDismiss()},t.prototype.componentWillUnmount=function(){this._async.dispose(),this._events.dispose()},t.prototype.focus=function(){this._isSplitButton&&this._splitButtonContainer.current?(dd(!0),this._splitButtonContainer.current.focus()):this._buttonElement.current&&(dd(!0),this._buttonElement.current.focus())},t.prototype.dismissMenu=function(){this._dismissMenu()},t.prototype.openMenu=function(n,r){this._openMenu(n,r)},t.prototype._onRenderContent=function(n,r){var o=this,i=this.props,a=n,s=i.menuIconProps,l=i.menuProps,u=i.onRenderIcon,d=u===void 0?this._onRenderIcon:u,h=i.onRenderAriaDescription,p=h===void 0?this._onRenderAriaDescription:h,m=i.onRenderChildren,v=m===void 0?this._onRenderChildren:m,_=i.onRenderMenu,b=_===void 0?this._onRenderMenu:_,E=i.onRenderMenuIcon,w=E===void 0?this._onRenderMenuIcon:E,k=i.disabled,y=i.keytipProps;y&&l&&(y=this._getMemoizedMenuButtonKeytipProps(y));var F=function(A){return T.createElement(a,oe({},r,A),T.createElement("span",{className:o._classNames.flexContainer,"data-automationid":"splitbuttonprimary"},d(i,o._onRenderIcon),o._onRenderTextContents(),p(i,o._onRenderAriaDescription),v(i,o._onRenderChildren),!o._isSplitButton&&(l||s||o.props.onRenderMenuIcon)&&w(o.props,o._onRenderMenuIcon),l&&!l.doNotLayer&&o._shouldRenderMenu()&&b(o._getMenuProps(l),o._onRenderMenu)))},C=y?T.createElement(x0,{keytipProps:this._isSplitButton?void 0:y,ariaDescribedBy:r["aria-describedby"],disabled:k},function(A){return F(A)}):F();return l&&l.doNotLayer?T.createElement(T.Fragment,null,C,this._shouldRenderMenu()&&b(this._getMenuProps(l),this._onRenderMenu)):T.createElement(T.Fragment,null,C,T.createElement(HK,null))},t.prototype._shouldRenderMenu=function(){var n=this.state.menuHidden,r=this.props,o=r.persistMenu,i=r.renderPersistedMenuHiddenOnMount;if(n){if(o&&(this._renderedVisibleMenu||i))return!0}else return!0;return!1},t.prototype._hasText=function(){return this.props.text!==null&&(this.props.text!==void 0||typeof this.props.children=="string")},t.prototype._getMenuProps=function(n){var r=this.props.persistMenu,o=this.state.menuHidden;return!n.ariaLabel&&!n.labelElementId&&this._hasText()&&(n=oe(oe({},n),{labelElementId:this._labelId})),oe(oe({id:this._labelId+"-menu",directionalHint:hr.bottomLeftEdge},n),{shouldFocusOnContainer:this._menuShouldFocusOnContainer,shouldFocusOnMount:this._menuShouldFocusOnMount,hidden:r?o:void 0,className:Ys("ms-BaseButton-menuhost",n.className),target:this._isSplitButton?this._splitButtonContainer.current:this._buttonElement.current,onDismiss:this._onDismissMenu})},t.prototype._onRenderSplitButtonContent=function(n,r){var o=this,i=this.props,a=i.styles,s=a===void 0?{}:a,l=i.disabled,u=i.allowDisabledFocus,d=i.checked,h=i.getSplitButtonClassNames,p=i.primaryDisabled,m=i.menuProps,v=i.toggle,_=i.role,b=i.primaryActionButtonProps,E=this.props.keytipProps,w=this.state.menuHidden,k=h?h(!!l,!w,!!d,!!u):s&&jee(s,!!l,!w,!!d,!!p);pc(r,{onClick:void 0,onPointerDown:void 0,onPointerUp:void 0,tabIndex:-1,"data-is-focusable":!1}),E&&m&&(E=this._getMemoizedMenuButtonKeytipProps(E));var y=Zr(r,[],["disabled"]);b&&pc(r,b);var F=function(C){return T.createElement("div",oe({},y,{"data-ktp-target":C?C["data-ktp-target"]:void 0,role:_||"button","aria-disabled":l,"aria-haspopup":!0,"aria-expanded":!w,"aria-pressed":v?!!d:void 0,"aria-describedby":$0(r["aria-describedby"],C?C["aria-describedby"]:void 0),className:k&&k.splitButtonContainer,onKeyDown:o._onSplitButtonContainerKeyDown,onTouchStart:o._onTouchStart,ref:o._splitButtonContainer,"data-is-focusable":!0,onClick:!l&&!p?o._onSplitButtonPrimaryClick:void 0,tabIndex:!l&&!p||u?0:void 0,"aria-roledescription":r["aria-roledescription"],onFocusCapture:o._onSplitContainerFocusCapture}),T.createElement("span",{style:{display:"flex"}},o._onRenderContent(n,r),o._onRenderSplitButtonMenuButton(k,C),o._onRenderSplitButtonDivider(k)))};return E?T.createElement(x0,{keytipProps:E,disabled:l},function(C){return F(C)}):F()},t.prototype._onRenderSplitButtonDivider=function(n){if(n&&n.divider){var r=function(o){o.stopPropagation()};return T.createElement("span",{className:n.divider,"aria-hidden":!0,onClick:r})}return null},t.prototype._onRenderSplitButtonMenuButton=function(n,r){var o=this.props,i=o.allowDisabledFocus,a=o.checked,s=o.disabled,l=o.splitButtonMenuProps,u=o.splitButtonAriaLabel,d=o.primaryDisabled,h=this.state.menuHidden,p=this.props.menuIconProps;p===void 0&&(p={iconName:"ChevronDown"});var m=oe(oe({},l),{styles:n,checked:a,disabled:s,allowDisabledFocus:i,onClick:this._onMenuClick,menuProps:void 0,iconProps:oe(oe({},p),{className:this._classNames.menuIcon}),ariaLabel:u,"aria-haspopup":!0,"aria-expanded":!h,"data-is-focusable":!1});return T.createElement(t,oe({},m,{"data-ktp-execute-target":r&&r["data-ktp-execute-target"],onMouseDown:this._onMouseDown,tabIndex:d&&!i?0:-1}))},t.prototype._onPointerDown=function(n){var r=this.props.onPointerDown;r&&r(n),n.pointerType==="touch"&&(this._handleTouchAndPointerEvent(),n.preventDefault(),n.stopImmediatePropagation())},t.prototype._handleTouchAndPointerEvent=function(){var n=this;this._lastTouchTimeoutId!==void 0&&(this._async.clearTimeout(this._lastTouchTimeoutId),this._lastTouchTimeoutId=void 0),this._processingTouch=!0,this._lastTouchTimeoutId=this._async.setTimeout(function(){n._processingTouch=!1,n._lastTouchTimeoutId=void 0,n.focus()},zee)},t.prototype._isValidMenuOpenKey=function(n){return this.props.menuTriggerKeyCode?n.which===this.props.menuTriggerKeyCode:this.props.menuProps?n.which===qt.down&&(n.altKey||n.metaKey):!1},t.defaultProps={baseClassName:"ms-Button",styles:{},split:!1},t}(T.Component),dC={outline:0},hC=function(e){return{fontSize:e,margin:"0 4px",height:"16px",lineHeight:"16px",textAlign:"center",flexShrink:0}},qee=Cr(function(e){var t,n,r=e.semanticColors,o=e.effects,i=e.fonts,a=r.buttonBorder,s=r.disabledBackground,l=r.disabledText,u={left:-2,top:-2,bottom:-2,right:-2,outlineColor:"ButtonText"};return{root:[Pd(e,{inset:1,highContrastStyle:u,borderColor:"transparent"}),e.fonts.medium,{boxSizing:"border-box",border:"1px solid "+a,userSelect:"none",display:"inline-block",textDecoration:"none",textAlign:"center",cursor:"pointer",padding:"0 16px",borderRadius:o.roundedCorner2,selectors:{":active > *":{position:"relative",left:0,top:0}}}],rootDisabled:[Pd(e,{inset:1,highContrastStyle:u,borderColor:"transparent"}),{backgroundColor:s,borderColor:s,color:l,cursor:"default",selectors:{":hover":dC,":focus":dC}}],iconDisabled:{color:l,selectors:(t={},t[Ao]={color:"GrayText"},t)},menuIconDisabled:{color:l,selectors:(n={},n[Ao]={color:"GrayText"},n)},flexContainer:{display:"flex",height:"100%",flexWrap:"nowrap",justifyContent:"center",alignItems:"center"},description:{display:"block"},textContainer:{flexGrow:1,display:"block"},icon:hC(i.mediumPlus.fontSize),menuIcon:hC(i.small.fontSize),label:{margin:"0 4px",lineHeight:"100%",display:"block"},screenReaderText:GF}}),$ee="40px",Wee="0 4px",Gee=Cr(function(e,t){var n,r,o,i=qee(e),a={root:{padding:Wee,height:$ee,color:e.palette.neutralPrimary,backgroundColor:"transparent",border:"1px solid transparent",selectors:(n={},n[Ao]={borderColor:"Window"},n)},rootHovered:{color:e.palette.themePrimary,selectors:(r={},r[Ao]={color:"Highlight"},r)},iconHovered:{color:e.palette.themePrimary},rootPressed:{color:e.palette.black},rootExpanded:{color:e.palette.themePrimary},iconPressed:{color:e.palette.themeDarker},rootDisabled:{color:e.palette.neutralTertiary,backgroundColor:"transparent",borderColor:"transparent",selectors:(o={},o[Ao]={color:"GrayText"},o)},rootChecked:{color:e.palette.black},iconChecked:{color:e.palette.themeDarker},flexContainer:{justifyContent:"flex-start"},icon:{color:e.palette.themeDarkAlt},iconDisabled:{color:"inherit"},menuIcon:{color:e.palette.neutralSecondary},textContainer:{flexGrow:0}};return jc(i,a,t)}),pC=function(e){yi(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.render=function(){var n=this.props,r=n.styles,o=n.theme;return T.createElement(Uee,oe({},this.props,{variantClassName:"ms-Button--action ms-Button--command",styles:Gee(o,r),onRenderDescription:AF}))},t=vG([xK("ActionButton",["theme","styles"],!0)],t),t}(T.Component);function Kee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons"',src:"url('"+e+"fabric-icons-a13498cf.woff') format('woff')"},icons:{GlobalNavButton:"",ChevronDown:"",ChevronUp:"",Edit:"",Add:"",Cancel:"",More:"",Settings:"",Mail:"",Filter:"",Search:"",Share:"",BlockedSite:"",FavoriteStar:"",FavoriteStarFill:"",CheckMark:"",Delete:"",ChevronLeft:"",ChevronRight:"",Calendar:"",Megaphone:"",Undo:"",Flag:"",Page:"",Pinned:"",View:"",Clear:"",Download:"",Upload:"",Folder:"",Sort:"",AlignRight:"",AlignLeft:"",Tag:"",AddFriend:"",Info:"",SortLines:"",List:"",CircleRing:"",Heart:"",HeartFill:"",Tiles:"",Embed:"",Glimmer:"",Ascending:"",Descending:"",SortUp:"",SortDown:"",SyncToPC:"",LargeGrid:"",SkypeCheck:"",SkypeClock:"",SkypeMinus:"",ClearFilter:"",Flow:"",StatusCircleCheckmark:"",MoreVertical:""}};Ar(n,t)}function Vee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-0"',src:"url('"+e+"fabric-icons-0-467ee27f.woff') format('woff')"},icons:{PageLink:"",CommentSolid:"",ChangeEntitlements:"",Installation:"",WebAppBuilderModule:"",WebAppBuilderFragment:"",WebAppBuilderSlot:"",BullseyeTargetEdit:"",WebAppBuilderFragmentCreate:"",PageData:"",PageHeaderEdit:"",ProductList:"",UnpublishContent:"",DependencyAdd:"",DependencyRemove:"",EntitlementPolicy:"",EntitlementRedemption:"",SchoolDataSyncLogo:"",PinSolid12:"",PinSolidOff12:"",AddLink:"",SharepointAppIcon16:"",DataflowsLink:"",TimePicker:"",UserWarning:"",ComplianceAudit:"",InternetSharing:"",Brightness:"",MapPin:"",Airplane:"",Tablet:"",QuickNote:"",Video:"",People:"",Phone:"",Pin:"",Shop:"",Stop:"",Link:"",AllApps:"",Zoom:"",ZoomOut:"",Microphone:"",Camera:"",Attach:"",Send:"",FavoriteList:"",PageSolid:"",Forward:"",Back:"",Refresh:"",Lock:"",ReportHacked:"",EMI:"",MiniLink:"",Blocked:"",ReadingMode:"",Favicon:"",Remove:"",Checkbox:"",CheckboxComposite:"",CheckboxFill:"",CheckboxIndeterminate:"",CheckboxCompositeReversed:"",BackToWindow:"",FullScreen:"",Print:"",Up:"",Down:"",OEM:"",Save:"",ReturnKey:"",Cloud:"",Flashlight:"",CommandPrompt:"",Sad:"",RealEstate:"",SIPMove:"",EraseTool:"",GripperTool:"",Dialpad:"",PageLeft:"",PageRight:"",MultiSelect:"",KeyboardClassic:"",Play:"",Pause:"",InkingTool:"",Emoji2:"",GripperBarHorizontal:"",System:"",Personalize:"",SearchAndApps:"",Globe:"",EaseOfAccess:"",ContactInfo:"",Unpin:"",Contact:"",Memo:"",IncomingCall:""}};Ar(n,t)}function Yee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-1"',src:"url('"+e+"fabric-icons-1-4d521695.woff') format('woff')"},icons:{Paste:"",WindowsLogo:"",Error:"",GripperBarVertical:"",Unlock:"",Slideshow:"",Trim:"",AutoEnhanceOn:"",AutoEnhanceOff:"",Color:"",SaveAs:"",Light:"",Filters:"",AspectRatio:"",Contrast:"",Redo:"",Crop:"",PhotoCollection:"",Album:"",Rotate:"",PanoIndicator:"",Translate:"",RedEye:"",ViewOriginal:"",ThumbnailView:"",Package:"",Telemarketer:"",Warning:"",Financial:"",Education:"",ShoppingCart:"",Train:"",Move:"",TouchPointer:"",Merge:"",TurnRight:"",Ferry:"",Highlight:"",PowerButton:"",Tab:"",Admin:"",TVMonitor:"",Speakers:"",Game:"",HorizontalTabKey:"",UnstackSelected:"",StackIndicator:"",Nav2DMapView:"",StreetsideSplitMinimize:"",Car:"",Bus:"",EatDrink:"",SeeDo:"",LocationCircle:"",Home:"",SwitcherStartEnd:"",ParkingLocation:"",IncidentTriangle:"",Touch:"",MapDirections:"",CaretHollow:"",CaretSolid:"",History:"",Location:"",MapLayers:"",SearchNearby:"",Work:"",Recent:"",Hotel:"",Bank:"",LocationDot:"",Dictionary:"",ChromeBack:"",FolderOpen:"",PinnedFill:"",RevToggleKey:"",USB:"",Previous:"",Next:"",Sync:"",Help:"",Emoji:"",MailForward:"",ClosePane:"",OpenPane:"",PreviewLink:"",ZoomIn:"",Bookmarks:"",Document:"",ProtectedDocument:"",OpenInNewWindow:"",MailFill:"",ViewAll:"",Switch:"",Rename:"",Go:"",Remote:"",SelectAll:"",Orientation:"",Import:""}};Ar(n,t)}function Qee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-2"',src:"url('"+e+"fabric-icons-2-63c99abf.woff') format('woff')"},icons:{Picture:"",ChromeClose:"",ShowResults:"",Message:"",CalendarDay:"",CalendarWeek:"",MailReplyAll:"",Read:"",Cut:"",PaymentCard:"",Copy:"",Important:"",MailReply:"",GotoToday:"",Font:"",FontColor:"",FolderFill:"",Permissions:"",DisableUpdates:"",Unfavorite:"",Italic:"",Underline:"",Bold:"",MoveToFolder:"",Dislike:"",Like:"",AlignCenter:"",OpenFile:"",ClearSelection:"",FontDecrease:"",FontIncrease:"",FontSize:"",CellPhone:"",RepeatOne:"",RepeatAll:"",Calculator:"",Library:"",PostUpdate:"",NewFolder:"",CalendarReply:"",UnsyncFolder:"",SyncFolder:"",BlockContact:"",Accept:"",BulletedList:"",Preview:"",News:"",Chat:"",Group:"",World:"",Comment:"",DockLeft:"",DockRight:"",Repair:"",Accounts:"",Street:"",RadioBullet:"",Stopwatch:"",Clock:"",WorldClock:"",AlarmClock:"",Photo:"",ActionCenter:"",Hospital:"",Timer:"",FullCircleMask:"",LocationFill:"",ChromeMinimize:"",ChromeRestore:"",Annotation:"",Fingerprint:"",Handwriting:"",ChromeFullScreen:"",Completed:"",Label:"",FlickDown:"",FlickUp:"",FlickLeft:"",FlickRight:"",MiniExpand:"",MiniContract:"",Streaming:"",MusicInCollection:"",OneDriveLogo:"",CompassNW:"",Code:"",LightningBolt:"",CalculatorMultiply:"",CalculatorAddition:"",CalculatorSubtract:"",CalculatorPercentage:"",CalculatorEqualTo:"",PrintfaxPrinterFile:"",StorageOptical:"",Communications:"",Headset:"",Health:"",Webcam2:"",FrontCamera:"",ChevronUpSmall:""}};Ar(n,t)}function Xee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-3"',src:"url('"+e+"fabric-icons-3-089e217a.woff') format('woff')"},icons:{ChevronDownSmall:"",ChevronLeftSmall:"",ChevronRightSmall:"",ChevronUpMed:"",ChevronDownMed:"",ChevronLeftMed:"",ChevronRightMed:"",Devices2:"",PC1:"",PresenceChickletVideo:"",Reply:"",HalfAlpha:"",ConstructionCone:"",DoubleChevronLeftMed:"",Volume0:"",Volume1:"",Volume2:"",Volume3:"",Chart:"",Robot:"",Manufacturing:"",LockSolid:"",FitPage:"",FitWidth:"",BidiLtr:"",BidiRtl:"",RightDoubleQuote:"",Sunny:"",CloudWeather:"",Cloudy:"",PartlyCloudyDay:"",PartlyCloudyNight:"",ClearNight:"",RainShowersDay:"",Rain:"",Thunderstorms:"",RainSnow:"",Snow:"",BlowingSnow:"",Frigid:"",Fog:"",Squalls:"",Duststorm:"",Unknown:"",Precipitation:"",Ribbon:"",AreaChart:"",Assign:"",FlowChart:"",CheckList:"",Diagnostic:"",Generate:"",LineChart:"",Equalizer:"",BarChartHorizontal:"",BarChartVertical:"",Freezing:"",FunnelChart:"",Processing:"",Quantity:"",ReportDocument:"",StackColumnChart:"",SnowShowerDay:"",HailDay:"",WorkFlow:"",HourGlass:"",StoreLogoMed20:"",TimeSheet:"",TriangleSolid:"",UpgradeAnalysis:"",VideoSolid:"",RainShowersNight:"",SnowShowerNight:"",Teamwork:"",HailNight:"",PeopleAdd:"",Glasses:"",DateTime2:"",Shield:"",Header1:"",PageAdd:"",NumberedList:"",PowerBILogo:"",Info2:"",MusicInCollectionFill:"",Asterisk:"",ErrorBadge:"",CircleFill:"",Record2:"",AllAppsMirrored:"",BookmarksMirrored:"",BulletedListMirrored:"",CaretHollowMirrored:"",CaretSolidMirrored:"",ChromeBackMirrored:"",ClearSelectionMirrored:"",ClosePaneMirrored:"",DockLeftMirrored:"",DoubleChevronLeftMedMirrored:"",GoMirrored:""}};Ar(n,t)}function Zee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-4"',src:"url('"+e+"fabric-icons-4-a656cc0a.woff') format('woff')"},icons:{HelpMirrored:"",ImportMirrored:"",ImportAllMirrored:"",ListMirrored:"",MailForwardMirrored:"",MailReplyMirrored:"",MailReplyAllMirrored:"",MiniContractMirrored:"",MiniExpandMirrored:"",OpenPaneMirrored:"",ParkingLocationMirrored:"",SendMirrored:"",ShowResultsMirrored:"",ThumbnailViewMirrored:"",Media:"",Devices3:"",Focus:"",VideoLightOff:"",Lightbulb:"",StatusTriangle:"",VolumeDisabled:"",Puzzle:"",EmojiNeutral:"",EmojiDisappointed:"",HomeSolid:"",Ringer:"",PDF:"",HeartBroken:"",StoreLogo16:"",MultiSelectMirrored:"",Broom:"",AddToShoppingList:"",Cocktails:"",Wines:"",Articles:"",Cycling:"",DietPlanNotebook:"",Pill:"",ExerciseTracker:"",HandsFree:"",Medical:"",Running:"",Weights:"",Trackers:"",AddNotes:"",AllCurrency:"",BarChart4:"",CirclePlus:"",Coffee:"",Cotton:"",Market:"",Money:"",PieDouble:"",PieSingle:"",RemoveFilter:"",Savings:"",Sell:"",StockDown:"",StockUp:"",Lamp:"",Source:"",MSNVideos:"",Cricket:"",Golf:"",Baseball:"",Soccer:"",MoreSports:"",AutoRacing:"",CollegeHoops:"",CollegeFootball:"",ProFootball:"",ProHockey:"",Rugby:"",SubstitutionsIn:"",Tennis:"",Arrivals:"",Design:"",Website:"",Drop:"",HistoricalWeather:"",SkiResorts:"",Snowflake:"",BusSolid:"",FerrySolid:"",AirplaneSolid:"",TrainSolid:"",Ticket:"",WifiWarning4:"",Devices4:"",AzureLogo:"",BingLogo:"",MSNLogo:"",OutlookLogoInverse:"",OfficeLogo:"",SkypeLogo:"",Door:"",EditMirrored:"",GiftCard:"",DoubleBookmark:"",StatusErrorFull:""}};Ar(n,t)}function Jee(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-5"',src:"url('"+e+"fabric-icons-5-f95ba260.woff') format('woff')"},icons:{Certificate:"",FastForward:"",Rewind:"",Photo2:"",OpenSource:"",Movers:"",CloudDownload:"",Family:"",WindDirection:"",Bug:"",SiteScan:"",BrowserScreenShot:"",F12DevTools:"",CSS:"",JS:"",DeliveryTruck:"",ReminderPerson:"",ReminderGroup:"",ReminderTime:"",TabletMode:"",Umbrella:"",NetworkTower:"",CityNext:"",CityNext2:"",Section:"",OneNoteLogoInverse:"",ToggleFilled:"",ToggleBorder:"",SliderThumb:"",ToggleThumb:"",Documentation:"",Badge:"",Giftbox:"",VisualStudioLogo:"",HomeGroup:"",ExcelLogoInverse:"",WordLogoInverse:"",PowerPointLogoInverse:"",Cafe:"",SpeedHigh:"",Commitments:"",ThisPC:"",MusicNote:"",MicOff:"",PlaybackRate1x:"",EdgeLogo:"",CompletedSolid:"",AlbumRemove:"",MessageFill:"",TabletSelected:"",MobileSelected:"",LaptopSelected:"",TVMonitorSelected:"",DeveloperTools:"",Shapes:"",InsertTextBox:"",LowerBrightness:"",WebComponents:"",OfflineStorage:"",DOM:"",CloudUpload:"",ScrollUpDown:"",DateTime:"",Event:"",Cake:"",Org:"",PartyLeader:"",DRM:"",CloudAdd:"",AppIconDefault:"",Photo2Add:"",Photo2Remove:"",Calories:"",POI:"",AddTo:"",RadioBtnOff:"",RadioBtnOn:"",ExploreContent:"",Product:"",ProgressLoopInner:"",ProgressLoopOuter:"",Blocked2:"",FangBody:"",Toolbox:"",PageHeader:"",ChatInviteFriend:"",Brush:"",Shirt:"",Crown:"",Diamond:"",ScaleUp:"",QRCode:"",Feedback:"",SharepointLogoInverse:"",YammerLogo:"",Hide:"",Uneditable:"",ReturnToSession:"",OpenFolderHorizontal:"",CalendarMirrored:""}};Ar(n,t)}function ete(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-6"',src:"url('"+e+"fabric-icons-6-ef6fd590.woff') format('woff')"},icons:{SwayLogoInverse:"",OutOfOffice:"",Trophy:"",ReopenPages:"",EmojiTabSymbols:"",AADLogo:"",AccessLogo:"",AdminALogoInverse32:"",AdminCLogoInverse32:"",AdminDLogoInverse32:"",AdminELogoInverse32:"",AdminLLogoInverse32:"",AdminMLogoInverse32:"",AdminOLogoInverse32:"",AdminPLogoInverse32:"",AdminSLogoInverse32:"",AdminYLogoInverse32:"",DelveLogoInverse:"",ExchangeLogoInverse:"",LyncLogo:"",OfficeVideoLogoInverse:"",SocialListeningLogo:"",VisioLogoInverse:"",Balloons:"",Cat:"",MailAlert:"",MailCheck:"",MailLowImportance:"",MailPause:"",MailRepeat:"",SecurityGroup:"",Table:"",VoicemailForward:"",VoicemailReply:"",Waffle:"",RemoveEvent:"",EventInfo:"",ForwardEvent:"",WipePhone:"",AddOnlineMeeting:"",JoinOnlineMeeting:"",RemoveLink:"",PeopleBlock:"",PeopleRepeat:"",PeopleAlert:"",PeoplePause:"",TransferCall:"",AddPhone:"",UnknownCall:"",NoteReply:"",NoteForward:"",NotePinned:"",RemoveOccurrence:"",Timeline:"",EditNote:"",CircleHalfFull:"",Room:"",Unsubscribe:"",Subscribe:"",HardDrive:"",RecurringTask:"",TaskManager:"",TaskManagerMirrored:"",Combine:"",Split:"",DoubleChevronUp:"",DoubleChevronLeft:"",DoubleChevronRight:"",TextBox:"",TextField:"",NumberField:"",Dropdown:"",PenWorkspace:"",BookingsLogo:"",ClassNotebookLogoInverse:"",DelveAnalyticsLogo:"",DocsLogoInverse:"",Dynamics365Logo:"",DynamicSMBLogo:"",OfficeAssistantLogo:"",OfficeStoreLogo:"",OneNoteEduLogoInverse:"",PlannerLogo:"",PowerApps:"",Suitcase:"",ProjectLogoInverse:"",CaretLeft8:"",CaretRight8:"",CaretUp8:"",CaretDown8:"",CaretLeftSolid8:"",CaretRightSolid8:"",CaretUpSolid8:"",CaretDownSolid8:"",ClearFormatting:"",Superscript:"",Subscript:"",Strikethrough:"",Export:"",ExportMirrored:""}};Ar(n,t)}function tte(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-7"',src:"url('"+e+"fabric-icons-7-2b97bb99.woff') format('woff')"},icons:{SingleBookmark:"",SingleBookmarkSolid:"",DoubleChevronDown:"",FollowUser:"",ReplyAll:"",WorkforceManagement:"",RecruitmentManagement:"",Questionnaire:"",ManagerSelfService:"",ProductionFloorManagement:"",ProductRelease:"",ProductVariant:"",ReplyMirrored:"",ReplyAllMirrored:"",Medal:"",AddGroup:"",QuestionnaireMirrored:"",CloudImportExport:"",TemporaryUser:"",CaretSolid16:"",GroupedDescending:"",GroupedAscending:"",AwayStatus:"",MyMoviesTV:"",GenericScan:"",AustralianRules:"",WifiEthernet:"",TrackersMirrored:"",DateTimeMirrored:"",StopSolid:"",DoubleChevronUp12:"",DoubleChevronDown12:"",DoubleChevronLeft12:"",DoubleChevronRight12:"",CalendarAgenda:"",ConnectVirtualMachine:"",AddEvent:"",AssetLibrary:"",DataConnectionLibrary:"",DocLibrary:"",FormLibrary:"",FormLibraryMirrored:"",ReportLibrary:"",ReportLibraryMirrored:"",ContactCard:"",CustomList:"",CustomListMirrored:"",IssueTracking:"",IssueTrackingMirrored:"",PictureLibrary:"",OfficeAddinsLogo:"",OfflineOneDriveParachute:"",OfflineOneDriveParachuteDisabled:"",TriangleSolidUp12:"",TriangleSolidDown12:"",TriangleSolidLeft12:"",TriangleSolidRight12:"",TriangleUp12:"",TriangleDown12:"",TriangleLeft12:"",TriangleRight12:"",ArrowUpRight8:"",ArrowDownRight8:"",DocumentSet:"",GoToDashboard:"",DelveAnalytics:"",ArrowUpRightMirrored8:"",ArrowDownRightMirrored8:"",CompanyDirectory:"",OpenEnrollment:"",CompanyDirectoryMirrored:"",OneDriveAdd:"",ProfileSearch:"",Header2:"",Header3:"",Header4:"",RingerSolid:"",Eyedropper:"",MarketDown:"",CalendarWorkWeek:"",SidePanel:"",GlobeFavorite:"",CaretTopLeftSolid8:"",CaretTopRightSolid8:"",ViewAll2:"",DocumentReply:"",PlayerSettings:"",ReceiptForward:"",ReceiptReply:"",ReceiptCheck:"",Fax:"",RecurringEvent:"",ReplyAlt:"",ReplyAllAlt:"",EditStyle:"",EditMail:"",Lifesaver:"",LifesaverLock:"",InboxCheck:"",FolderSearch:""}};Ar(n,t)}function nte(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-8"',src:"url('"+e+"fabric-icons-8-6fdf1528.woff') format('woff')"},icons:{CollapseMenu:"",ExpandMenu:"",Boards:"",SunAdd:"",SunQuestionMark:"",LandscapeOrientation:"",DocumentSearch:"",PublicCalendar:"",PublicContactCard:"",PublicEmail:"",PublicFolder:"",WordDocument:"",PowerPointDocument:"",ExcelDocument:"",GroupedList:"",ClassroomLogo:"",Sections:"",EditPhoto:"",Starburst:"",ShareiOS:"",AirTickets:"",PencilReply:"",Tiles2:"",SkypeCircleCheck:"",SkypeCircleClock:"",SkypeCircleMinus:"",SkypeMessage:"",ClosedCaption:"",ATPLogo:"",OfficeFormsLogoInverse:"",RecycleBin:"",EmptyRecycleBin:"",Hide2:"",Breadcrumb:"",BirthdayCake:"",TimeEntry:"",CRMProcesses:"",PageEdit:"",PageArrowRight:"",PageRemove:"",Database:"",DataManagementSettings:"",CRMServices:"",EditContact:"",ConnectContacts:"",AppIconDefaultAdd:"",AppIconDefaultList:"",ActivateOrders:"",DeactivateOrders:"",ProductCatalog:"",ScatterChart:"",AccountActivity:"",DocumentManagement:"",CRMReport:"",KnowledgeArticle:"",Relationship:"",HomeVerify:"",ZipFolder:"",SurveyQuestions:"",TextDocument:"",TextDocumentShared:"",PageCheckedOut:"",PageShared:"",SaveAndClose:"",Script:"",Archive:"",ActivityFeed:"",Compare:"",EventDate:"",ArrowUpRight:"",CaretRight:"",SetAction:"",ChatBot:"",CaretSolidLeft:"",CaretSolidDown:"",CaretSolidRight:"",CaretSolidUp:"",PowerAppsLogo:"",PowerApps2Logo:"",SearchIssue:"",SearchIssueMirrored:"",FabricAssetLibrary:"",FabricDataConnectionLibrary:"",FabricDocLibrary:"",FabricFormLibrary:"",FabricFormLibraryMirrored:"",FabricReportLibrary:"",FabricReportLibraryMirrored:"",FabricPublicFolder:"",FabricFolderSearch:"",FabricMovetoFolder:"",FabricUnsyncFolder:"",FabricSyncFolder:"",FabricOpenFolderHorizontal:"",FabricFolder:"",FabricFolderFill:"",FabricNewFolder:"",FabricPictureLibrary:"",PhotoVideoMedia:"",AddFavorite:""}};Ar(n,t)}function rte(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-9"',src:"url('"+e+"fabric-icons-9-c6162b42.woff') format('woff')"},icons:{AddFavoriteFill:"",BufferTimeBefore:"",BufferTimeAfter:"",BufferTimeBoth:"",PublishContent:"",ClipboardList:"",ClipboardListMirrored:"",CannedChat:"",SkypeForBusinessLogo:"",TabCenter:"",PageCheckedin:"",PageList:"",ReadOutLoud:"",CaretBottomLeftSolid8:"",CaretBottomRightSolid8:"",FolderHorizontal:"",MicrosoftStaffhubLogo:"",GiftboxOpen:"",StatusCircleOuter:"",StatusCircleInner:"",StatusCircleRing:"",StatusTriangleOuter:"",StatusTriangleInner:"",StatusTriangleExclamation:"",StatusCircleExclamation:"",StatusCircleErrorX:"",StatusCircleInfo:"",StatusCircleBlock:"",StatusCircleBlock2:"",StatusCircleQuestionMark:"",StatusCircleSync:"",Toll:"",ExploreContentSingle:"",CollapseContent:"",CollapseContentSingle:"",InfoSolid:"",GroupList:"",ProgressRingDots:"",CaloriesAdd:"",BranchFork:"",MuteChat:"",AddHome:"",AddWork:"",MobileReport:"",ScaleVolume:"",HardDriveGroup:"",FastMode:"",ToggleLeft:"",ToggleRight:"",TriangleShape:"",RectangleShape:"",CubeShape:"",Trophy2:"",BucketColor:"",BucketColorFill:"",Taskboard:"",SingleColumn:"",DoubleColumn:"",TripleColumn:"",ColumnLeftTwoThirds:"",ColumnRightTwoThirds:"",AccessLogoFill:"",AnalyticsLogo:"",AnalyticsQuery:"",NewAnalyticsQuery:"",AnalyticsReport:"",WordLogo:"",WordLogoFill:"",ExcelLogo:"",ExcelLogoFill:"",OneNoteLogo:"",OneNoteLogoFill:"",OutlookLogo:"",OutlookLogoFill:"",PowerPointLogo:"",PowerPointLogoFill:"",PublisherLogo:"",PublisherLogoFill:"",ScheduleEventAction:"",FlameSolid:"",ServerProcesses:"",Server:"",SaveAll:"",LinkedInLogo:"",Decimals:"",SidePanelMirrored:"",ProtectRestrict:"",Blog:"",UnknownMirrored:"",PublicContactCardMirrored:"",GridViewSmall:"",GridViewMedium:"",GridViewLarge:"",Step:"",StepInsert:"",StepShared:"",StepSharedAdd:"",StepSharedInsert:"",ViewDashboard:"",ViewList:""}};Ar(n,t)}function ote(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-10"',src:"url('"+e+"fabric-icons-10-c4ded8e4.woff') format('woff')"},icons:{ViewListGroup:"",ViewListTree:"",TriggerAuto:"",TriggerUser:"",PivotChart:"",StackedBarChart:"",StackedLineChart:"",BuildQueue:"",BuildQueueNew:"",UserFollowed:"",ContactLink:"",Stack:"",Bullseye:"",VennDiagram:"",FiveTileGrid:"",FocalPoint:"",Insert:"",RingerRemove:"",TeamsLogoInverse:"",TeamsLogo:"",TeamsLogoFill:"",SkypeForBusinessLogoFill:"",SharepointLogo:"",SharepointLogoFill:"",DelveLogo:"",DelveLogoFill:"",OfficeVideoLogo:"",OfficeVideoLogoFill:"",ExchangeLogo:"",ExchangeLogoFill:"",Signin:"",DocumentApproval:"",CloneToDesktop:"",InstallToDrive:"",Blur:"",Build:"",ProcessMetaTask:"",BranchFork2:"",BranchLocked:"",BranchCommit:"",BranchCompare:"",BranchMerge:"",BranchPullRequest:"",BranchSearch:"",BranchShelveset:"",RawSource:"",MergeDuplicate:"",RowsGroup:"",RowsChild:"",Deploy:"",Redeploy:"",ServerEnviroment:"",VisioDiagram:"",HighlightMappedShapes:"",TextCallout:"",IconSetsFlag:"",VisioLogo:"",VisioLogoFill:"",VisioDocument:"",TimelineProgress:"",TimelineDelivery:"",Backlog:"",TeamFavorite:"",TaskGroup:"",TaskGroupMirrored:"",ScopeTemplate:"",AssessmentGroupTemplate:"",NewTeamProject:"",CommentAdd:"",CommentNext:"",CommentPrevious:"",ShopServer:"",LocaleLanguage:"",QueryList:"",UserSync:"",UserPause:"",StreamingOff:"",ArrowTallUpLeft:"",ArrowTallUpRight:"",ArrowTallDownLeft:"",ArrowTallDownRight:"",FieldEmpty:"",FieldFilled:"",FieldChanged:"",FieldNotChanged:"",RingerOff:"",PlayResume:"",BulletedList2:"",BulletedList2Mirrored:"",ImageCrosshair:"",GitGraph:"",Repo:"",RepoSolid:"",FolderQuery:"",FolderList:"",FolderListMirrored:"",LocationOutline:"",POISolid:"",CalculatorNotEqualTo:"",BoxSubtractSolid:""}};Ar(n,t)}function ite(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-11"',src:"url('"+e+"fabric-icons-11-2a8393d6.woff') format('woff')"},icons:{BoxAdditionSolid:"",BoxMultiplySolid:"",BoxPlaySolid:"",BoxCheckmarkSolid:"",CirclePauseSolid:"",CirclePause:"",MSNVideosSolid:"",CircleStopSolid:"",CircleStop:"",NavigateBack:"",NavigateBackMirrored:"",NavigateForward:"",NavigateForwardMirrored:"",UnknownSolid:"",UnknownMirroredSolid:"",CircleAddition:"",CircleAdditionSolid:"",FilePDB:"",FileTemplate:"",FileSQL:"",FileJAVA:"",FileASPX:"",FileCSS:"",FileSass:"",FileLess:"",FileHTML:"",JavaScriptLanguage:"",CSharpLanguage:"",CSharp:"",VisualBasicLanguage:"",VB:"",CPlusPlusLanguage:"",CPlusPlus:"",FSharpLanguage:"",FSharp:"",TypeScriptLanguage:"",PythonLanguage:"",PY:"",CoffeeScript:"",MarkDownLanguage:"",FullWidth:"",FullWidthEdit:"",Plug:"",PlugSolid:"",PlugConnected:"",PlugDisconnected:"",UnlockSolid:"",Variable:"",Parameter:"",CommentUrgent:"",Storyboard:"",DiffInline:"",DiffSideBySide:"",ImageDiff:"",ImagePixel:"",FileBug:"",FileCode:"",FileComment:"",BusinessHoursSign:"",FileImage:"",FileSymlink:"",AutoFillTemplate:"",WorkItem:"",WorkItemBug:"",LogRemove:"",ColumnOptions:"",Packages:"",BuildIssue:"",AssessmentGroup:"",VariableGroup:"",FullHistory:"",Wheelchair:"",SingleColumnEdit:"",DoubleColumnEdit:"",TripleColumnEdit:"",ColumnLeftTwoThirdsEdit:"",ColumnRightTwoThirdsEdit:"",StreamLogo:"",PassiveAuthentication:"",AlertSolid:"",MegaphoneSolid:"",TaskSolid:"",ConfigurationSolid:"",BugSolid:"",CrownSolid:"",Trophy2Solid:"",QuickNoteSolid:"",ConstructionConeSolid:"",PageListSolid:"",PageListMirroredSolid:"",StarburstSolid:"",ReadingModeSolid:"",SadSolid:"",HealthSolid:"",ShieldSolid:"",GiftBoxSolid:"",ShoppingCartSolid:"",MailSolid:"",ChatSolid:"",RibbonSolid:""}};Ar(n,t)}function ate(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-12"',src:"url('"+e+"fabric-icons-12-7e945a1e.woff') format('woff')"},icons:{FinancialSolid:"",FinancialMirroredSolid:"",HeadsetSolid:"",PermissionsSolid:"",ParkingSolid:"",ParkingMirroredSolid:"",DiamondSolid:"",AsteriskSolid:"",OfflineStorageSolid:"",BankSolid:"",DecisionSolid:"",Parachute:"",ParachuteSolid:"",FiltersSolid:"",ColorSolid:"",ReviewSolid:"",ReviewRequestSolid:"",ReviewRequestMirroredSolid:"",ReviewResponseSolid:"",FeedbackRequestSolid:"",FeedbackRequestMirroredSolid:"",FeedbackResponseSolid:"",WorkItemBar:"",WorkItemBarSolid:"",Separator:"",NavigateExternalInline:"",PlanView:"",TimelineMatrixView:"",EngineeringGroup:"",ProjectCollection:"",CaretBottomRightCenter8:"",CaretBottomLeftCenter8:"",CaretTopRightCenter8:"",CaretTopLeftCenter8:"",DonutChart:"",ChevronUnfold10:"",ChevronFold10:"",DoubleChevronDown8:"",DoubleChevronUp8:"",DoubleChevronLeft8:"",DoubleChevronRight8:"",ChevronDownEnd6:"",ChevronUpEnd6:"",ChevronLeftEnd6:"",ChevronRightEnd6:"",ContextMenu:"",AzureAPIManagement:"",AzureServiceEndpoint:"",VSTSLogo:"",VSTSAltLogo1:"",VSTSAltLogo2:"",FileTypeSolution:"",WordLogoInverse16:"",WordLogo16:"",WordLogoFill16:"",PowerPointLogoInverse16:"",PowerPointLogo16:"",PowerPointLogoFill16:"",ExcelLogoInverse16:"",ExcelLogo16:"",ExcelLogoFill16:"",OneNoteLogoInverse16:"",OneNoteLogo16:"",OneNoteLogoFill16:"",OutlookLogoInverse16:"",OutlookLogo16:"",OutlookLogoFill16:"",PublisherLogoInverse16:"",PublisherLogo16:"",PublisherLogoFill16:"",VisioLogoInverse16:"",VisioLogo16:"",VisioLogoFill16:"",TestBeaker:"",TestBeakerSolid:"",TestExploreSolid:"",TestAutoSolid:"",TestUserSolid:"",TestImpactSolid:"",TestPlan:"",TestStep:"",TestParameter:"",TestSuite:"",TestCase:"",Sprint:"",SignOut:"",TriggerApproval:"",Rocket:"",AzureKeyVault:"",Onboarding:"",Transition:"",LikeSolid:"",DislikeSolid:"",CRMCustomerInsightsApp:"",EditCreate:"",PlayReverseResume:"",PlayReverse:"",SearchData:"",UnSetColor:"",DeclineCall:""}};Ar(n,t)}function ste(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-13"',src:"url('"+e+"fabric-icons-13-c3989a02.woff') format('woff')"},icons:{RectangularClipping:"",TeamsLogo16:"",TeamsLogoFill16:"",Spacer:"",SkypeLogo16:"",SkypeForBusinessLogo16:"",SkypeForBusinessLogoFill16:"",FilterSolid:"",MailUndelivered:"",MailTentative:"",MailTentativeMirrored:"",MailReminder:"",ReceiptUndelivered:"",ReceiptTentative:"",ReceiptTentativeMirrored:"",Inbox:"",IRMReply:"",IRMReplyMirrored:"",IRMForward:"",IRMForwardMirrored:"",VoicemailIRM:"",EventAccepted:"",EventTentative:"",EventTentativeMirrored:"",EventDeclined:"",IDBadge:"",BackgroundColor:"",OfficeFormsLogoInverse16:"",OfficeFormsLogo:"",OfficeFormsLogoFill:"",OfficeFormsLogo16:"",OfficeFormsLogoFill16:"",OfficeFormsLogoInverse24:"",OfficeFormsLogo24:"",OfficeFormsLogoFill24:"",PageLock:"",NotExecuted:"",NotImpactedSolid:"",FieldReadOnly:"",FieldRequired:"",BacklogBoard:"",ExternalBuild:"",ExternalTFVC:"",ExternalXAML:"",IssueSolid:"",DefectSolid:"",LadybugSolid:"",NugetLogo:"",TFVCLogo:"",ProjectLogo32:"",ProjectLogoFill32:"",ProjectLogo16:"",ProjectLogoFill16:"",SwayLogo32:"",SwayLogoFill32:"",SwayLogo16:"",SwayLogoFill16:"",ClassNotebookLogo32:"",ClassNotebookLogoFill32:"",ClassNotebookLogo16:"",ClassNotebookLogoFill16:"",ClassNotebookLogoInverse32:"",ClassNotebookLogoInverse16:"",StaffNotebookLogo32:"",StaffNotebookLogoFill32:"",StaffNotebookLogo16:"",StaffNotebookLogoFill16:"",StaffNotebookLogoInverted32:"",StaffNotebookLogoInverted16:"",KaizalaLogo:"",TaskLogo:"",ProtectionCenterLogo32:"",GallatinLogo:"",Globe2:"",Guitar:"",Breakfast:"",Brunch:"",BeerMug:"",Vacation:"",Teeth:"",Taxi:"",Chopsticks:"",SyncOccurence:"",UnsyncOccurence:"",GIF:"",PrimaryCalendar:"",SearchCalendar:"",VideoOff:"",MicrosoftFlowLogo:"",BusinessCenterLogo:"",ToDoLogoBottom:"",ToDoLogoTop:"",EditSolid12:"",EditSolidMirrored12:"",UneditableSolid12:"",UneditableSolidMirrored12:"",UneditableMirrored:"",AdminALogo32:"",AdminALogoFill32:"",ToDoLogoInverse:""}};Ar(n,t)}function lte(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-14"',src:"url('"+e+"fabric-icons-14-5cf58db8.woff') format('woff')"},icons:{Snooze:"",WaffleOffice365:"",ImageSearch:"",NewsSearch:"",VideoSearch:"",R:"",FontColorA:"",FontColorSwatch:"",LightWeight:"",NormalWeight:"",SemiboldWeight:"",GroupObject:"",UngroupObject:"",AlignHorizontalLeft:"",AlignHorizontalCenter:"",AlignHorizontalRight:"",AlignVerticalTop:"",AlignVerticalCenter:"",AlignVerticalBottom:"",HorizontalDistributeCenter:"",VerticalDistributeCenter:"",Ellipse:"",Line:"",Octagon:"",Hexagon:"",Pentagon:"",RightTriangle:"",HalfCircle:"",QuarterCircle:"",ThreeQuarterCircle:"","6PointStar":"","12PointStar":"",ArrangeBringToFront:"",ArrangeSendToBack:"",ArrangeSendBackward:"",ArrangeBringForward:"",BorderDash:"",BorderDot:"",LineStyle:"",LineThickness:"",WindowEdit:"",HintText:"",MediaAdd:"",AnchorLock:"",AutoHeight:"",ChartSeries:"",ChartXAngle:"",ChartYAngle:"",Combobox:"",LineSpacing:"",Padding:"",PaddingTop:"",PaddingBottom:"",PaddingLeft:"",PaddingRight:"",NavigationFlipper:"",AlignJustify:"",TextOverflow:"",VisualsFolder:"",VisualsStore:"",PictureCenter:"",PictureFill:"",PicturePosition:"",PictureStretch:"",PictureTile:"",Slider:"",SliderHandleSize:"",DefaultRatio:"",NumberSequence:"",GUID:"",ReportAdd:"",DashboardAdd:"",MapPinSolid:"",WebPublish:"",PieSingleSolid:"",BlockedSolid:"",DrillDown:"",DrillDownSolid:"",DrillExpand:"",DrillShow:"",SpecialEvent:"",OneDriveFolder16:"",FunctionalManagerDashboard:"",BIDashboard:"",CodeEdit:"",RenewalCurrent:"",RenewalFuture:"",SplitObject:"",BulkUpload:"",DownloadDocument:"",GreetingCard:"",Flower:"",WaitlistConfirm:"",WaitlistConfirmMirrored:"",LaptopSecure:"",DragObject:"",EntryView:"",EntryDecline:"",ContactCardSettings:"",ContactCardSettingsMirrored:""}};Ar(n,t)}function ute(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-15"',src:"url('"+e+"fabric-icons-15-3807251b.woff') format('woff')"},icons:{CalendarSettings:"",CalendarSettingsMirrored:"",HardDriveLock:"",HardDriveUnlock:"",AccountManagement:"",ReportWarning:"",TransitionPop:"",TransitionPush:"",TransitionEffect:"",LookupEntities:"",ExploreData:"",AddBookmark:"",SearchBookmark:"",DrillThrough:"",MasterDatabase:"",CertifiedDatabase:"",MaximumValue:"",MinimumValue:"",VisualStudioIDELogo32:"",PasteAsText:"",PasteAsCode:"",BrowserTab:"",BrowserTabScreenshot:"",DesktopScreenshot:"",FileYML:"",ClipboardSolid:"",FabricUserFolder:"",FabricNetworkFolder:"",BullseyeTarget:"",AnalyticsView:"",Video360Generic:"",Untag:"",Leave:"",Trending12:"",Blocked12:"",Warning12:"",CheckedOutByOther12:"",CheckedOutByYou12:"",CircleShapeSolid:"",SquareShapeSolid:"",TriangleShapeSolid:"",DropShapeSolid:"",RectangleShapeSolid:"",ZoomToFit:"",InsertColumnsLeft:"",InsertColumnsRight:"",InsertRowsAbove:"",InsertRowsBelow:"",DeleteColumns:"",DeleteRows:"",DeleteRowsMirrored:"",DeleteTable:"",AccountBrowser:"",VersionControlPush:"",StackedColumnChart2:"",TripleColumnWide:"",QuadColumn:"",WhiteBoardApp16:"",WhiteBoardApp32:"",PinnedSolid:"",InsertSignatureLine:"",ArrangeByFrom:"",Phishing:"",CreateMailRule:"",PublishCourse:"",DictionaryRemove:"",UserRemove:"",UserEvent:"",Encryption:"",PasswordField:"",OpenInNewTab:"",Hide3:"",VerifiedBrandSolid:"",MarkAsProtected:"",AuthenticatorApp:"",WebTemplate:"",DefenderTVM:"",MedalSolid:"",D365TalentLearn:"",D365TalentInsight:"",D365TalentHRCore:"",BacklogList:"",ButtonControl:"",TableGroup:"",MountainClimbing:"",TagUnknown:"",TagUnknownMirror:"",TagUnknown12:"",TagUnknown12Mirror:"",Link12:"",Presentation:"",Presentation12:"",Lock12:"",BuildDefinition:"",ReleaseDefinition:"",SaveTemplate:"",UserGauge:"",BlockedSiteSolid12:"",TagSolid:"",OfficeChat:""}};Ar(n,t)}function cte(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-16"',src:"url('"+e+"fabric-icons-16-9cf93f3b.woff') format('woff')"},icons:{OfficeChatSolid:"",MailSchedule:"",WarningSolid:"",Blocked2Solid:"",SkypeCircleArrow:"",SkypeArrow:"",SyncStatus:"",SyncStatusSolid:"",ProjectDocument:"",ToDoLogoOutline:"",VisioOnlineLogoFill32:"",VisioOnlineLogo32:"",VisioOnlineLogoCloud32:"",VisioDiagramSync:"",Event12:"",EventDateMissed12:"",UserOptional:"",ResponsesMenu:"",DoubleDownArrow:"",DistributeDown:"",BookmarkReport:"",FilterSettings:"",GripperDotsVertical:"",MailAttached:"",AddIn:"",LinkedDatabase:"",TableLink:"",PromotedDatabase:"",BarChartVerticalFilter:"",BarChartVerticalFilterSolid:"",MicOff2:"",MicrosoftTranslatorLogo:"",ShowTimeAs:"",FileRequest:"",WorkItemAlert:"",PowerBILogo16:"",PowerBILogoBackplate16:"",BulletedListText:"",BulletedListBullet:"",BulletedListTextMirrored:"",BulletedListBulletMirrored:"",NumberedListText:"",NumberedListNumber:"",NumberedListTextMirrored:"",NumberedListNumberMirrored:"",RemoveLinkChain:"",RemoveLinkX:"",FabricTextHighlight:"",ClearFormattingA:"",ClearFormattingEraser:"",Photo2Fill:"",IncreaseIndentText:"",IncreaseIndentArrow:"",DecreaseIndentText:"",DecreaseIndentArrow:"",IncreaseIndentTextMirrored:"",IncreaseIndentArrowMirrored:"",DecreaseIndentTextMirrored:"",DecreaseIndentArrowMirrored:"",CheckListText:"",CheckListCheck:"",CheckListTextMirrored:"",CheckListCheckMirrored:"",NumberSymbol:"",Coupon:"",VerifiedBrand:"",ReleaseGate:"",ReleaseGateCheck:"",ReleaseGateError:"",M365InvoicingLogo:"",RemoveFromShoppingList:"",ShieldAlert:"",FabricTextHighlightComposite:"",Dataflows:"",GenericScanFilled:"",DiagnosticDataBarTooltip:"",SaveToMobile:"",Orientation2:"",ScreenCast:"",ShowGrid:"",SnapToGrid:"",ContactList:"",NewMail:"",EyeShadow:"",FabricFolderConfirm:"",InformationBarriers:"",CommentActive:"",ColumnVerticalSectionEdit:"",WavingHand:"",ShakeDevice:"",SmartGlassRemote:"",Rotate90Clockwise:"",Rotate90CounterClockwise:"",CampaignTemplate:"",ChartTemplate:"",PageListFilter:"",SecondaryNav:"",ColumnVerticalSection:"",SkypeCircleSlash:"",SkypeSlash:""}};Ar(n,t)}function fte(e,t){e===void 0&&(e="");var n={style:{MozOsxFontSmoothing:"grayscale",WebkitFontSmoothing:"antialiased",fontStyle:"normal",fontWeight:"normal",speak:"none"},fontFace:{fontFamily:'"FabricMDL2Icons-17"',src:"url('"+e+"fabric-icons-17-0c4ed701.woff') format('woff')"},icons:{CustomizeToolbar:"",DuplicateRow:"",RemoveFromTrash:"",MailOptions:"",Childof:"",Footer:"",Header:"",BarChartVerticalFill:"",StackedColumnChart2Fill:"",PlainText:"",AccessibiltyChecker:"",DatabaseSync:"",ReservationOrders:"",TabOneColumn:"",TabTwoColumn:"",TabThreeColumn:"",BulletedTreeList:"",MicrosoftTranslatorLogoGreen:"",MicrosoftTranslatorLogoBlue:"",InternalInvestigation:"",AddReaction:"",ContactHeart:"",VisuallyImpaired:"",EventToDoLogo:"",Variable2:"",ModelingView:"",DisconnectVirtualMachine:"",ReportLock:"",Uneditable2:"",Uneditable2Mirrored:"",BarChartVerticalEdit:"",GlobalNavButtonActive:"",PollResults:"",Rerun:"",QandA:"",QandAMirror:"",BookAnswers:"",AlertSettings:"",TrimStart:"",TrimEnd:"",TableComputed:"",DecreaseIndentLegacy:"",IncreaseIndentLegacy:"",SizeLegacy:""}};Ar(n,t)}var dte=function(){nc("trash","delete"),nc("onedrive","onedrivelogo"),nc("alertsolid12","eventdatemissed12"),nc("sixpointstar","6pointstar"),nc("twelvepointstar","12pointstar"),nc("toggleon","toggleleft"),nc("toggleoff","toggleright")};yb("@fluentui/font-icons-mdl2","8.2.0");var hte="https://spoppe-b.azureedge.net/files/fabric-cdn-prod_20210407.001/assets/icons/";function pte(e,t){e===void 0&&(e=hte),[Kee,Vee,Yee,Qee,Xee,Zee,Jee,ete,tte,nte,rte,ote,ite,ate,ste,lte,ute,cte,fte].forEach(function(n){return n(e,t)}),dte()}var mte={root:"ms-Nav",linkText:"ms-Nav-linkText",compositeLink:"ms-Nav-compositeLink",link:"ms-Nav-link",chevronButton:"ms-Nav-chevronButton",chevronIcon:"ms-Nav-chevron",navItem:"ms-Nav-navItem",navItems:"ms-Nav-navItems",group:"ms-Nav-group",groupContent:"ms-Nav-groupContent"},gte={textContainer:{overflow:"hidden"},label:{whiteSpace:"nowrap",textOverflow:"ellipsis",overflow:"hidden"}},vte=function(e){var t,n=e.className,r=e.theme,o=e.isOnTop,i=e.isExpanded,a=e.isGroup,s=e.isLink,l=e.isSelected,u=e.isDisabled,d=e.isButtonEntry,h=e.navHeight,p=h===void 0?44:h,m=e.position,v=e.leftPadding,_=v===void 0?20:v,b=e.leftPaddingExpanded,E=b===void 0?28:b,w=e.rightPadding,k=w===void 0?20:w,y=r.palette,F=r.semanticColors,C=r.fonts,A=hs(mte,r);return{root:[A.root,n,C.medium,{overflowY:"auto",userSelect:"none",WebkitOverflowScrolling:"touch"},o&&[{position:"absolute"},bc.slideRightIn40]],linkText:[A.linkText,{margin:"0 4px",overflow:"hidden",verticalAlign:"middle",textAlign:"left",textOverflow:"ellipsis"}],compositeLink:[A.compositeLink,{display:"block",position:"relative",color:F.bodyText},i&&"is-expanded",l&&"is-selected",u&&"is-disabled",u&&{color:F.disabledText}],link:[A.link,Pd(r),{display:"block",position:"relative",height:p,width:"100%",lineHeight:p+"px",textDecoration:"none",cursor:"pointer",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden",paddingLeft:_,paddingRight:k,color:F.bodyText,selectors:(t={},t[Ao]={border:0,selectors:{":focus":{border:"1px solid WindowText"}}},t)},!u&&{selectors:{".ms-Nav-compositeLink:hover &":{backgroundColor:F.bodyBackgroundHovered}}},l&&{color:F.bodyTextChecked,fontWeight:Rn.semibold,backgroundColor:F.bodyBackgroundChecked,selectors:{"&:after":{borderLeft:"2px solid "+y.themePrimary,content:'""',position:"absolute",top:0,right:0,bottom:0,left:0,pointerEvents:"none"}}},u&&{color:F.disabledText},d&&{color:y.themePrimary}],chevronButton:[A.chevronButton,Pd(r),C.small,{display:"block",textAlign:"left",lineHeight:p+"px",margin:"5px 0",padding:"0px, "+k+"px, 0px, "+E+"px",border:"none",textOverflow:"ellipsis",whiteSpace:"nowrap",overflow:"hidden",cursor:"pointer",color:F.bodyText,backgroundColor:"transparent",selectors:{"&:visited":{color:F.bodyText}}},a&&{fontSize:C.large.fontSize,width:"100%",height:p,borderBottom:"1px solid "+F.bodyDivider},s&&{display:"block",width:E-2,height:p-2,position:"absolute",top:"1px",left:m+"px",zIndex:Dd.Nav,padding:0,margin:0},l&&{color:y.themePrimary,backgroundColor:y.neutralLighterAlt,selectors:{"&:after":{borderLeft:"2px solid "+y.themePrimary,content:'""',position:"absolute",top:0,right:0,bottom:0,left:0,pointerEvents:"none"}}}],chevronIcon:[A.chevronIcon,{position:"absolute",left:"8px",height:p,display:"inline-flex",alignItems:"center",lineHeight:p+"px",fontSize:C.small.fontSize,transition:"transform .1s linear"},i&&{transform:"rotate(-180deg)"},s&&{top:0}],navItem:[A.navItem,{padding:0}],navItems:[A.navItems,{listStyleType:"none",padding:0,margin:0}],group:[A.group,i&&"is-expanded"],groupContent:[A.groupContent,{display:"none",marginBottom:"40px"},bc.slideDownIn20,i&&{display:"block"}]}},mC=14,bte=3,wf;function yte(e){return!!e&&!/^[a-z0-9+-.]+:\/\//i.test(e)}var Pl=ml(),Ete=function(e){yi(t,e);function t(n){var r=e.call(this,n)||this;return r._focusZone=T.createRef(),r._onRenderLink=function(o){var i=r.props,a=i.styles,s=i.groups,l=i.theme,u=Pl(a,{theme:l,groups:s});return T.createElement("div",{className:u.linkText},o.name)},r._renderGroup=function(o,i){var a=r.props,s=a.styles,l=a.groups,u=a.theme,d=a.onRenderGroupHeader,h=d===void 0?r._renderGroupHeader:d,p=r._isGroupExpanded(o),m=Pl(s,{theme:u,isGroup:!0,isExpanded:p,groups:l}),v=function(b,E){r._onGroupHeaderClicked(o,b)},_=oe(oe({},o),{isExpanded:p,onHeaderClick:v});return T.createElement("div",{key:i,className:m.group},_.name?h(_,r._renderGroupHeader):null,T.createElement("div",{className:m.groupContent},r._renderLinks(_.links,0)))},r._renderGroupHeader=function(o){var i=r.props,a=i.styles,s=i.groups,l=i.theme,u=i.expandButtonAriaLabel,d=o.isExpanded,h=Pl(a,{theme:l,isGroup:!0,isExpanded:d,groups:s}),p=(d?o.collapseAriaLabel:o.expandAriaLabel)||u,m=o.onHeaderClick,v=m?function(_){m(_,d)}:void 0;return T.createElement("button",{className:h.chevronButton,onClick:v,"aria-label":p,"aria-expanded":d},T.createElement(sl,{className:h.chevronIcon,iconName:"ChevronDown"}),o.name)},Tb(r),r.state={isGroupCollapsed:{},isLinkExpandStateChanged:!1,selectedKey:n.initialSelectedKey||n.selectedKey},r}return t.prototype.render=function(){var n=this.props,r=n.styles,o=n.groups,i=n.className,a=n.isOnTop,s=n.theme;if(!o)return null;var l=o.map(this._renderGroup),u=Pl(r,{theme:s,className:i,isOnTop:a,groups:o});return T.createElement(rR,{direction:ao.vertical,componentRef:this._focusZone},T.createElement("nav",{role:"navigation",className:u.root,"aria-label":this.props.ariaLabel},l))},Object.defineProperty(t.prototype,"selectedKey",{get:function(){return this.state.selectedKey},enumerable:!1,configurable:!0}),t.prototype.focus=function(n){return n===void 0&&(n=!1),this._focusZone&&this._focusZone.current?this._focusZone.current.focus(n):!1},t.prototype._renderNavLink=function(n,r,o){var i=this.props,a=i.styles,s=i.groups,l=i.theme,u=n.icon||n.iconProps,d=this._isLinkSelected(n),h=n.ariaCurrent,p=h===void 0?"page":h,m=Pl(a,{theme:l,isSelected:d,isDisabled:n.disabled,isButtonEntry:n.onClick&&!n.forceAnchor,leftPadding:mC*o+bte+(u?0:24),groups:s}),v=n.url&&n.target&&!yte(n.url)?"noopener noreferrer":void 0,_=this.props.linkAs?PF(this.props.linkAs,pC):pC,b=this.props.onRenderLink?HF(this.props.onRenderLink,this._onRenderLink):this._onRenderLink;return T.createElement(_,{className:m.link,styles:gte,href:n.url||(n.forceAnchor?"#":void 0),iconProps:n.iconProps||{iconName:n.icon},onClick:n.onClick?this._onNavButtonLinkClicked.bind(this,n):this._onNavAnchorLinkClicked.bind(this,n),title:n.title!==void 0?n.title:n.name,target:n.target,rel:v,disabled:n.disabled,"aria-current":d?p:void 0,"aria-label":n.ariaLabel?n.ariaLabel:void 0,link:n},b(n))},t.prototype._renderCompositeLink=function(n,r,o){var i=oe({},Zr(n,W0,["onClick"])),a=this.props,s=a.expandButtonAriaLabel,l=a.styles,u=a.groups,d=a.theme,h=Pl(l,{theme:d,isExpanded:!!n.isExpanded,isSelected:this._isLinkSelected(n),isLink:!0,isDisabled:n.disabled,position:mC*o+1,groups:u}),p="";return n.links&&n.links.length>0&&(n.collapseAriaLabel||n.expandAriaLabel?p=n.isExpanded?n.collapseAriaLabel:n.expandAriaLabel:p=s?n.name+" "+s:n.name),T.createElement("div",oe({},i,{key:n.key||r,className:h.compositeLink}),n.links&&n.links.length>0?T.createElement("button",{className:h.chevronButton,onClick:this._onLinkExpandClicked.bind(this,n),"aria-label":p,"aria-expanded":n.isExpanded?"true":"false"},T.createElement(sl,{className:h.chevronIcon,iconName:"ChevronDown"})):null,this._renderNavLink(n,r,o))},t.prototype._renderLink=function(n,r,o){var i=this.props,a=i.styles,s=i.groups,l=i.theme,u=Pl(a,{theme:l,groups:s});return T.createElement("li",{key:n.key||r,role:"listitem",className:u.navItem},this._renderCompositeLink(n,r,o),n.isExpanded?this._renderLinks(n.links,++o):null)},t.prototype._renderLinks=function(n,r){var o=this;if(!n||!n.length)return null;var i=n.map(function(h,p){return o._renderLink(h,p,r)}),a=this.props,s=a.styles,l=a.groups,u=a.theme,d=Pl(s,{theme:u,groups:l});return T.createElement("ul",{role:"list",className:d.navItems},i)},t.prototype._onGroupHeaderClicked=function(n,r){n.onHeaderClick&&n.onHeaderClick(r,this._isGroupExpanded(n)),n.isExpanded===void 0&&this._toggleCollapsed(n),r&&(r.preventDefault(),r.stopPropagation())},t.prototype._onLinkExpandClicked=function(n,r){var o=this.props.onLinkExpandClick;o&&o(r,n),r.defaultPrevented||(n.isExpanded=!n.isExpanded,this.setState({isLinkExpandStateChanged:!0})),r.preventDefault(),r.stopPropagation()},t.prototype._preventBounce=function(n,r){!n.url&&n.forceAnchor&&r.preventDefault()},t.prototype._onNavAnchorLinkClicked=function(n,r){this._preventBounce(n,r),this.props.onLinkClick&&this.props.onLinkClick(r,n),!n.url&&n.links&&n.links.length>0&&this._onLinkExpandClicked(n,r),this.setState({selectedKey:n.key})},t.prototype._onNavButtonLinkClicked=function(n,r){this._preventBounce(n,r),n.onClick&&n.onClick(r,n),!n.url&&n.links&&n.links.length>0&&this._onLinkExpandClicked(n,r),this.setState({selectedKey:n.key})},t.prototype._isLinkSelected=function(n){if(this.props.selectedKey!==void 0)return n.key===this.props.selectedKey;if(this.state.selectedKey!==void 0)return n.key===this.state.selectedKey;if(typeof ur()>"u"||!n.url)return!1;wf=wf||document.createElement("a"),wf.href=n.url||"";var r=wf.href;return location.href===r||location.protocol+"//"+location.host+location.pathname===r?!0:location.hash?location.hash===n.url?!0:(wf.href=location.hash.substring(1),wf.href===r):!1},t.prototype._isGroupExpanded=function(n){return n.isExpanded!==void 0?n.isExpanded:n.name&&this.state.isGroupCollapsed.hasOwnProperty(n.name)?!this.state.isGroupCollapsed[n.name]:n.collapseByDefault!==void 0?!n.collapseByDefault:!0},t.prototype._toggleCollapsed=function(n){var r;if(n.name){var o=oe(oe({},this.state.isGroupCollapsed),(r={},r[n.name]=this._isGroupExpanded(n),r));this.setState({isGroupCollapsed:o})}},t.defaultProps={groups:null},t}(T.Component),_te=gl(Ete,vte,void 0,{scope:"Nav"}),NT=oe;function Ig(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var o=e;return o.isSlot?(n=T.Children.toArray(n),n.length===0?o(t):o(oe(oe({},t),{children:n}))):T.createElement.apply(n0,Yi([e,t],n))}function bR(e,t){t===void 0&&(t={});var n=t.defaultProp,r=n===void 0?"children":n,o=function(i,a,s,l,u){if(T.isValidElement(a))return a;var d=wte(r,a),h=kte(l,u,i,d);if(s){if(s.component){var p=s.component;return T.createElement(p,oe({},h))}if(s.render)return s.render(h,e)}return T.createElement(e,oe({},h))};return o}var Tte=Cr(function(e){return bR(e)});function yR(e,t){var n={},r=e,o=function(a){if(t.hasOwnProperty(a)){var s=function(l){for(var u=[],d=1;d<arguments.length;d++)u[d-1]=arguments[d];if(u.length>0)throw new Error("Any module using getSlots must use withSlots. Please see withSlots javadoc for more info.");return Ste(t[a],l,r[a],r.slots&&r.slots[a],r._defaultStyles&&r._defaultStyles[a],r.theme)};s.isSlot=!0,n[a]=s}};for(var i in t)o(i);return n}function wte(e,t){var n,r;return typeof t=="string"||typeof t=="number"||typeof t=="boolean"?r=(n={},n[e]=t,n):r=t,r}function kte(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];for(var o={},i=[],a=0,s=n;a<s.length;a++){var l=s[a];i.push(l&&l.className),NT(o,l)}return o.className=TF([e,i],{rtl:ls(t)}),o}function Ste(e,t,n,r,o,i){return e.create!==void 0?e.create(t,n,r,o):Tte(e)(t,n,r,o,i)}function ER(e,t){t===void 0&&(t={});var n=t.factoryOptions,r=n===void 0?{}:n,o=r.defaultProp,i=function(a){var s=Cte(t.displayName,T.useContext(o0),t.fields),l=t.state;l&&(a=oe(oe({},a),l(a)));var u=a.theme||s.theme,d=_R(a,u,t.tokens,s.tokens,a.tokens),h=xte(a,u,d,t.styles,s.styles,a.styles),p=oe(oe({},a),{styles:h,tokens:d,_defaultStyles:h,theme:u});return e(p)};return i.displayName=t.displayName||e.name,o&&(i.create=bR(i,{defaultProp:o})),NT(i,t.statics),i}function xte(e,t,n){for(var r=[],o=3;o<arguments.length;o++)r[o-3]=arguments[o];return jc.apply(void 0,r.map(function(i){return typeof i=="function"?i(e,t,n):i}))}function _R(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];for(var o={},i=0,a=n;i<a.length;i++){var s=a[i];s&&(s=typeof s=="function"?s(e,t):s,Array.isArray(s)&&(s=_R.apply(void 0,Yi([e,t],s))),NT(o,s))}return o}function Cte(e,t,n){var r=["theme","styles","tokens"];return $i.getSettings(n||r,e,t.customizations)}var Ate={root:"ms-StackItem"},Nte={start:"flex-start",end:"flex-end"},Fte=function(e,t,n){var r=e.grow,o=e.shrink,i=e.disableShrink,a=e.align,s=e.verticalFill,l=e.order,u=e.className,d=hs(Ate,t);return{root:[t.fonts.medium,d.root,{margin:n.margin,padding:n.padding,height:s?"100%":"auto",width:"auto"},r&&{flexGrow:r===!0?1:r},(i||!r&&!o)&&{flexShrink:0},o&&!i&&{flexShrink:1},a&&{alignSelf:Nte[a]||a},l&&{order:l},u]}},Ite=function(e){var t=e.children,n=Zr(e,fr);if(t==null)return null;var r=yR(e,{root:"div"});return Ig(r.root,oe({},n),t)},TR=ER(Ite,{displayName:"StackItem",styles:Fte}),Sd=function(e,t){return t.spacing.hasOwnProperty(e)?t.spacing[e]:e},z2=function(e){var t=parseFloat(e),n=isNaN(t)?0:t,r=isNaN(t)?"":t.toString(),o=e.substring(r.toString().length);return{value:n,unit:o||"px"}},Bte=function(e,t){if(e===void 0||e==="")return{rowGap:{value:0,unit:"px"},columnGap:{value:0,unit:"px"}};if(typeof e=="number")return{rowGap:{value:e,unit:"px"},columnGap:{value:e,unit:"px"}};var n=e.split(" ");if(n.length>2)return{rowGap:{value:0,unit:"px"},columnGap:{value:0,unit:"px"}};if(n.length===2)return{rowGap:z2(Sd(n[0],t)),columnGap:z2(Sd(n[1],t))};var r=z2(Sd(e,t));return{rowGap:r,columnGap:r}},gC=function(e,t){if(e===void 0||typeof e=="number"||e==="")return e;var n=e.split(" ");return n.length<2?Sd(e,t):n.reduce(function(r,o){return Sd(r,t)+" "+Sd(o,t)})},kf={start:"flex-start",end:"flex-end"},Rte={root:"ms-Stack",inner:"ms-Stack-inner"},Ote=function(e,t,n){var r,o,i,a,s,l,u,d=e.verticalFill,h=e.horizontal,p=e.reversed,m=e.grow,v=e.wrap,_=e.horizontalAlign,b=e.verticalAlign,E=e.disableShrink,w=e.className,k=hs(Rte,t),y=n&&n.childrenGap?n.childrenGap:e.gap,F=n&&n.maxHeight?n.maxHeight:e.maxHeight,C=n&&n.maxWidth?n.maxWidth:e.maxWidth,A=n&&n.padding?n.padding:e.padding,P=Bte(y,t),I=P.rowGap,j=P.columnGap,H=""+-.5*j.value+j.unit,K=""+-.5*I.value+I.unit,U={textOverflow:"ellipsis"},pe={"> *:not(.ms-StackItem)":{flexShrink:E?0:1}};return v?{root:[k.root,{flexWrap:"wrap",maxWidth:C,maxHeight:F,width:"auto",overflow:"visible",height:"100%"},_&&(r={},r[h?"justifyContent":"alignItems"]=kf[_]||_,r),b&&(o={},o[h?"alignItems":"justifyContent"]=kf[b]||b,o),w,{display:"flex"},h&&{height:d?"100%":"auto"}],inner:[k.inner,{display:"flex",flexWrap:"wrap",marginLeft:H,marginRight:H,marginTop:K,marginBottom:K,overflow:"visible",boxSizing:"border-box",padding:gC(A,t),width:j.value===0?"100%":"calc(100% + "+j.value+j.unit+")",maxWidth:"100vw",selectors:oe({"> *":oe({margin:""+.5*I.value+I.unit+" "+.5*j.value+j.unit},U)},pe)},_&&(i={},i[h?"justifyContent":"alignItems"]=kf[_]||_,i),b&&(a={},a[h?"alignItems":"justifyContent"]=kf[b]||b,a),h&&{flexDirection:p?"row-reverse":"row",height:I.value===0?"100%":"calc(100% + "+I.value+I.unit+")",selectors:{"> *":{maxWidth:j.value===0?"100%":"calc(100% - "+j.value+j.unit+")"}}},!h&&{flexDirection:p?"column-reverse":"column",height:"calc(100% + "+I.value+I.unit+")",selectors:{"> *":{maxHeight:I.value===0?"100%":"calc(100% - "+I.value+I.unit+")"}}}]}:{root:[k.root,{display:"flex",flexDirection:h?p?"row-reverse":"row":p?"column-reverse":"column",flexWrap:"nowrap",width:"auto",height:d?"100%":"auto",maxWidth:C,maxHeight:F,padding:gC(A,t),boxSizing:"border-box",selectors:oe((s={"> *":U},s[p?"> *:not(:last-child)":"> *:not(:first-child)"]=[h&&{marginLeft:""+j.value+j.unit},!h&&{marginTop:""+I.value+I.unit}],s),pe)},m&&{flexGrow:m===!0?1:m},_&&(l={},l[h?"justifyContent":"alignItems"]=kf[_]||_,l),b&&(u={},u[h?"alignItems":"justifyContent"]=kf[b]||b,u),w]}},Dte=function(e){var t=e.as,n=t===void 0?"div":t,r=e.disableShrink,o=e.wrap,i=pl(e,["as","disableShrink","wrap"]),a=T.Children.toArray(e.children);a.length===1&&T.isValidElement(a[0])&&a[0].type===T.Fragment&&(a=a[0].props.children),a=T.Children.map(a,function(u,d){if(!u)return null;if(Pte(u)){var h={shrink:!r};return T.cloneElement(u,oe(oe({},h),u.props))}return u});var s=Zr(i,fr),l=yR(e,{root:n,inner:"div"});return o?Ig(l.root,oe({},s),Ig(l.inner,null,a)):Ig(l.root,oe({},s),a)};function Pte(e){return!!e&&typeof e=="object"&&!!e.type&&e.type.displayName===TR.displayName}var Mte={Item:TR},wR=ER(Dte,{displayName:"Stack",styles:Ote,statics:Mte});const Lte=["Top","Right","Bottom","Left"];function J0(e,t,...n){const[r,o=r,i=r,a=o]=n,s=[r,o,i,a],l={};for(let u=0;u<s.length;u+=1)if(s[u]||s[u]===0){const d=e+Lte[u]+t;l[d]=s[u]}return l}function kR(...e){return J0("border","Width",...e)}function SR(...e){return J0("border","Style",...e)}function xR(...e){return J0("border","Color",...e)}function jte(...e){return Object.assign(Object.assign(Object.assign({},kR(e[0])),e[1]&&SR(e[1])),e[2]&&xR(e[2]))}function zte(...e){return Object.assign(Object.assign({borderLeftWidth:e[0]},e[1]&&{borderLeftStyle:e[1]}),e[2]&&{borderLeftColor:e[2]})}function Hte(...e){return Object.assign(Object.assign({borderBottomWidth:e[0]},e[1]&&{borderBottomStyle:e[1]}),e[2]&&{borderBottomColor:e[2]})}function Ute(...e){return Object.assign(Object.assign({borderRightWidth:e[0]},e[1]&&{borderRightStyle:e[1]}),e[2]&&{borderRightColor:e[2]})}function qte(...e){return Object.assign(Object.assign({borderTopWidth:e[0]},e[1]&&{borderTopStyle:e[1]}),e[2]&&{borderTopColor:e[2]})}function $te(e,t=e,n=e,r=t){return{borderBottomRightRadius:n,borderBottomLeftRadius:r,borderTopRightRadius:t,borderTopLeftRadius:e}}const Wte=e=>typeof e=="string"&&/(\d+(\w+|%))/.test(e),Lm=e=>typeof e=="number"&&!Number.isNaN(e),Gte=e=>e==="initial",vC=e=>e==="auto",Kte=e=>e==="none",Vte=["content","fit-content","max-content","min-content"],H2=e=>Vte.some(t=>e===t)||Wte(e);function Yte(...e){const t=e.length===1,n=e.length===2,r=e.length===3;if(t){const[o]=e;if(Gte(o))return{flexGrow:0,flexShrink:1,flexBasis:"auto"};if(vC(o))return{flexGrow:1,flexShrink:1,flexBasis:"auto"};if(Kte(o))return{flexGrow:0,flexShrink:0,flexBasis:"auto"};if(Lm(o))return{flexGrow:o,flexShrink:1,flexBasis:0};if(H2(o))return{flexGrow:1,flexShrink:1,flexBasis:o}}if(n){const[o,i]=e;if(Lm(i))return{flexGrow:o,flexShrink:i,flexBasis:0};if(H2(i))return{flexGrow:o,flexShrink:1,flexBasis:i}}if(r){const[o,i,a]=e;if(Lm(o)&&Lm(i)&&(vC(a)||H2(a)))return{flexGrow:o,flexShrink:i,flexBasis:a}}return{}}function Qte(e,t=e){return{columnGap:e,rowGap:t}}const Xte=/var\(.*\)/gi;function Zte(e){return e===void 0||typeof e=="number"||typeof e=="string"&&!Xte.test(e)}const Jte=/^[a-zA-Z0-9\-_\\#;]+$/,ene=/^-moz-initial$|^auto$|^initial$|^inherit$|^revert$|^unset$|^span \d+$|\d.*/;function U2(e){return e!==void 0&&typeof e=="string"&&Jte.test(e)&&!ene.test(e)}function tne(...e){if(e.some(i=>!Zte(i)))return{};const t=e[0]!==void 0?e[0]:"auto",n=e[1]!==void 0?e[1]:U2(t)?t:"auto",r=e[2]!==void 0?e[2]:U2(t)?t:"auto",o=e[3]!==void 0?e[3]:U2(n)?n:"auto";return{gridRowStart:t,gridColumnStart:n,gridRowEnd:r,gridColumnEnd:o}}function nne(...e){return J0("margin","",...e)}function rne(...e){return J0("padding","",...e)}function one(e,t=e){return{overflowX:e,overflowY:t}}function ine(...e){const[t,n=t,r=t,o=n]=e;return{top:t,right:n,bottom:r,left:o}}function ane(e,t,n){return Object.assign(Object.assign({outlineWidth:e},t&&{outlineStyle:t}),n&&{outlineColor:n})}function sne(...e){return une(e)?{transitionDelay:e[0],transitionDuration:e[0],transitionProperty:e[0],transitionTimingFunction:e[0]}:cne(e).reduce((n,[r,o="0s",i="0s",a="ease"],s)=>(s===0?(n.transitionProperty=r,n.transitionDuration=o,n.transitionDelay=i,n.transitionTimingFunction=a):(n.transitionProperty+=`, ${r}`,n.transitionDuration+=`, ${o}`,n.transitionDelay+=`, ${i}`,n.transitionTimingFunction+=`, ${a}`),n),{})}const lne=["-moz-initial","inherit","initial","revert","unset"];function une(e){return e.length===1&&lne.includes(e[0])}function cne(e){return e.length===1&&Array.isArray(e[0])?e[0]:[e]}const q2=typeof window>"u"?global:window,$2="@griffel/";function fne(e,t){return q2[Symbol.for($2+e)]||(q2[Symbol.for($2+e)]=t),q2[Symbol.for($2+e)]}const v_=fne("DEFINITION_LOOKUP_TABLE",{}),Bg="data-make-styles-bucket",b_="f",y_=7,FT="___",dne=FT.length+y_,hne=0,pne=1,mne={all:1,animation:1,background:1,backgroundPosition:1,border:1,borderBlock:1,borderBlockEnd:1,borderBlockStart:1,borderBottom:1,borderColor:1,borderImage:1,borderInline:1,borderInlineEnd:1,borderInlineStart:1,borderLeft:1,borderRadius:1,borderRight:1,borderStyle:1,borderTop:1,borderWidth:1,columns:1,columnRule:1,flex:1,flexFlow:1,font:1,gap:1,grid:1,gridArea:1,gridColumn:1,gridRow:1,gridTemplate:1,lineClamp:1,listStyle:1,margin:1,mask:1,maskBorder:1,motion:1,offset:1,outline:1,overflow:1,overscrollBehavior:1,padding:1,placeItems:1,placeSelf:1,textDecoration:1,textEmphasis:1,transition:1};function Ud(e){for(var t=0,n,r=0,o=e.length;o>=4;++r,o-=4)n=e.charCodeAt(r)&255|(e.charCodeAt(++r)&255)<<8|(e.charCodeAt(++r)&255)<<16|(e.charCodeAt(++r)&255)<<24,n=(n&65535)*1540483477+((n>>>16)*59797<<16),n^=n>>>24,t=(n&65535)*1540483477+((n>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(r+2)&255)<<16;case 2:t^=(e.charCodeAt(r+1)&255)<<8;case 1:t^=e.charCodeAt(r)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}function gne(e){const t=e.length;if(t===y_)return e;for(let n=t;n<y_;n++)e+="0";return e}function CR(e,t,n=[]){return FT+gne(Ud(e+t))}function AR(e,t){let n="";for(const r in e){const o=e[r];if(o){const i=Array.isArray(o);t==="rtl"?n+=(i?o[1]:o)+" ":n+=(i?o[0]:o)+" "}}return n.slice(0,-1)}function jv(e,t){const n={};for(const r in e){const o=AR(e[r],t);if(o===""){n[r]="";continue}const i=CR(o,t),a=i+" "+o;v_[i]=[e[r],t],n[r]=a}return n}const bC={};function et(){let e=null,t="",n="";const r=new Array(arguments.length);for(let u=0;u<arguments.length;u++){const d=arguments[u];if(typeof d=="string"&&d!==""){const h=d.indexOf(FT);if(h===-1)t+=d+" ";else{const p=d.substr(h,dne);h>0&&(t+=d.slice(0,h)),n+=p,r[u]=p}}}if(n==="")return t.slice(0,-1);const o=bC[n];if(o!==void 0)return t+o;const i=[];for(let u=0;u<arguments.length;u++){const d=r[u];if(d){const h=v_[d];h&&(i.push(h[hne]),e=h[pne])}}const a=Object.assign.apply(Object,[{}].concat(i));let s=AR(a,e);const l=CR(s,e,r);return s=l+" "+s,bC[n]=s,v_[l]=[a,e],t+s}function vne(e){return Array.isArray(e)?e:[e]}function bne(e,t,n){const r=[];if(n[Bg]=t,e)for(const i in n)e.setAttribute(i,n[i]);function o(i){return e!=null&&e.sheet?e.sheet.insertRule(i,e.sheet.cssRules.length):r.push(i)}return{elementAttributes:n,insertRule:o,element:e,bucketName:t,cssRules(){return e!=null&&e.sheet?Array.from(e.sheet.cssRules).map(i=>i.cssText):r}}}const yne=["r","d","l","v","w","f","i","h","a","k","t","m"],yC=yne.reduce((e,t,n)=>(e[t]=n,e),{});function Ene(e,t,n,r={}){const o=e==="m",i=o?e+r.m:e;if(!n.stylesheets[i]){const a=t&&t.createElement("style"),s=bne(a,e,Object.assign(Object.assign({},n.styleElementAttributes),o&&{media:r.m}));if(n.stylesheets[i]=s,t&&a){const l=_ne(t,e,n,r);t.head.insertBefore(a,l)}}return n.stylesheets[i]}function _ne(e,t,n,r){const o=yC[t];let i=s=>o-yC[s.getAttribute(Bg)],a=e.head.querySelectorAll(`[${Bg}]`);if(t==="m"&&r){const s=e.head.querySelectorAll(`[${Bg}="${t}"]`);s.length&&(a=s,i=l=>n.compareMediaQueries(r.m,l.media))}for(const s of a)if(i(s)<0)return s;return null}let Tne=0;const wne=(e,t)=>e<t?-1:e>t?1:0;function kne(e=typeof document>"u"?void 0:document,t={}){const{unstable_filterCSSRule:n,styleElementAttributes:r,compareMediaQueries:o=wne}=t,i={insertionCache:{},stylesheets:{},styleElementAttributes:Object.freeze(r),compareMediaQueries:o,id:`d${Tne++}`,insertCSSRules(a){for(const s in a){const l=a[s];for(let u=0,d=l.length;u<d;u++){const[h,p]=vne(l[u]),m=Ene(s,e,i,p);if(!i.insertionCache[h]){i.insertionCache[h]=s;try{n?n(h)&&m.insertRule(h):m.insertRule(h)}catch{}}}}}};return i}function NR(e){return e.reduce(function(t,n){var r=n[0],o=n[1];return t[r]=o,t[o]=r,t},{})}function Sne(e){return typeof e=="boolean"}function xne(e){return typeof e=="function"}function wh(e){return typeof e=="number"}function Cne(e){return e===null||typeof e>"u"}function Ane(e){return e&&typeof e=="object"}function Nne(e){return typeof e=="string"}function Rg(e,t){return e.indexOf(t)!==-1}function Fne(e){return parseFloat(e)===0?e:e[0]==="-"?e.slice(1):"-"+e}function jm(e,t,n,r){return t+Fne(n)+r}function Ine(e){var t=e.indexOf(".");if(t===-1)e=100-parseFloat(e)+"%";else{var n=e.length-t-2;e=100-parseFloat(e),e=e.toFixed(n)+"%"}return e}function FR(e){return e.replace(/ +/g," ").split(" ").map(function(t){return t.trim()}).filter(Boolean).reduce(function(t,n){var r=t.list,o=t.state,i=(n.match(/\(/g)||[]).length,a=(n.match(/\)/g)||[]).length;return o.parensDepth>0?r[r.length-1]=r[r.length-1]+" "+n:r.push(n),o.parensDepth+=i-a,{list:r,state:o}},{list:[],state:{parensDepth:0}}).list}function EC(e){var t=FR(e);if(t.length<=3||t.length>4)return e;var n=t[0],r=t[1],o=t[2],i=t[3];return[n,i,o,r].join(" ")}function Bne(e){return!Sne(e)&&!Cne(e)}function Rne(e){for(var t=[],n=0,r=0,o=!1;r<e.length;)!o&&e[r]===","?(t.push(e.substring(n,r).trim()),r++,n=r):e[r]==="("?(o=!0,r++):(e[r]===")"&&(o=!1),r++);return n!=r&&t.push(e.substring(n,r+1)),t}var Se={padding:function(t){var n=t.value;return wh(n)?n:EC(n)},textShadow:function(t){var n=t.value,r=Rne(n).map(function(o){return o.replace(/(^|\s)(-*)([.|\d]+)/,function(i,a,s,l){if(l==="0")return i;var u=s===""?"-":"";return""+a+u+l})});return r.join(",")},borderColor:function(t){var n=t.value;return EC(n)},borderRadius:function(t){var n=t.value;if(wh(n))return n;if(Rg(n,"/")){var r=n.split("/"),o=r[0],i=r[1],a=Se.borderRadius({value:o.trim()}),s=Se.borderRadius({value:i.trim()});return a+" / "+s}var l=FR(n);switch(l.length){case 2:return l.reverse().join(" ");case 4:{var u=l[0],d=l[1],h=l[2],p=l[3];return[d,u,p,h].join(" ")}default:return n}},background:function(t){var n=t.value,r=t.valuesToConvert,o=t.isRtl,i=t.bgImgDirectionRegex,a=t.bgPosDirectionRegex;if(wh(n))return n;var s=n.replace(/(url\(.*?\))|(rgba?\(.*?\))|(hsl\(.*?\))|(#[a-fA-F0-9]+)|((^| )(\D)+( |$))/g,"").trim();return n=n.replace(s,Se.backgroundPosition({value:s,valuesToConvert:r,isRtl:o,bgPosDirectionRegex:a})),Se.backgroundImage({value:n,valuesToConvert:r,bgImgDirectionRegex:i})},backgroundImage:function(t){var n=t.value,r=t.valuesToConvert,o=t.bgImgDirectionRegex;return!Rg(n,"url(")&&!Rg(n,"linear-gradient(")?n:n.replace(o,function(i,a,s){return i.replace(s,r[s])})},backgroundPosition:function(t){var n=t.value,r=t.valuesToConvert,o=t.isRtl,i=t.bgPosDirectionRegex;return n.replace(o?/^((-|\d|\.)+%)/:null,function(a,s){return Ine(s)}).replace(i,function(a){return r[a]})},backgroundPositionX:function(t){var n=t.value,r=t.valuesToConvert,o=t.isRtl,i=t.bgPosDirectionRegex;return wh(n)?n:Se.backgroundPosition({value:n,valuesToConvert:r,isRtl:o,bgPosDirectionRegex:i})},transition:function(t){var n=t.value,r=t.propertiesToConvert;return n.split(/,\s*/g).map(function(o){var i=o.split(" ");return i[0]=r[i[0]]||i[0],i.join(" ")}).join(", ")},transitionProperty:function(t){var n=t.value,r=t.propertiesToConvert;return n.split(/,\s*/g).map(function(o){return r[o]||o}).join(", ")},transform:function(t){var n=t.value,r="[^\\u0020-\\u007e]",o="(?:(?:(?:\\[0-9a-f]{1,6})(?:\\r\\n|\\s)?)|\\\\[^\\r\\n\\f0-9a-f])",i="((?:-?"+("(?:[0-9]*\\.[0-9]+|[0-9]+)(?:\\s*(?:em|ex|px|cm|mm|in|pt|pc|deg|rad|grad|ms|s|hz|khz|%)|"+("-?"+("(?:[_a-z]|"+r+"|"+o+")")+("(?:[_a-z0-9-]|"+r+"|"+o+")")+"*")+")?")+")|(?:inherit|auto))",a=new RegExp("(translateX\\s*\\(\\s*)"+i+"(\\s*\\))","gi"),s=new RegExp("(translate\\s*\\(\\s*)"+i+"((?:\\s*,\\s*"+i+"){0,1}\\s*\\))","gi"),l=new RegExp("(translate3d\\s*\\(\\s*)"+i+"((?:\\s*,\\s*"+i+"){0,2}\\s*\\))","gi"),u=new RegExp("(rotate[ZY]?\\s*\\(\\s*)"+i+"(\\s*\\))","gi");return n.replace(a,jm).replace(s,jm).replace(l,jm).replace(u,jm)}};Se.objectPosition=Se.backgroundPosition;Se.margin=Se.padding;Se.borderWidth=Se.padding;Se.boxShadow=Se.textShadow;Se.webkitBoxShadow=Se.boxShadow;Se.mozBoxShadow=Se.boxShadow;Se.WebkitBoxShadow=Se.boxShadow;Se.MozBoxShadow=Se.boxShadow;Se.borderStyle=Se.borderColor;Se.webkitTransform=Se.transform;Se.mozTransform=Se.transform;Se.WebkitTransform=Se.transform;Se.MozTransform=Se.transform;Se.transformOrigin=Se.backgroundPosition;Se.webkitTransformOrigin=Se.transformOrigin;Se.mozTransformOrigin=Se.transformOrigin;Se.WebkitTransformOrigin=Se.transformOrigin;Se.MozTransformOrigin=Se.transformOrigin;Se.webkitTransition=Se.transition;Se.mozTransition=Se.transition;Se.WebkitTransition=Se.transition;Se.MozTransition=Se.transition;Se.webkitTransitionProperty=Se.transitionProperty;Se.mozTransitionProperty=Se.transitionProperty;Se.WebkitTransitionProperty=Se.transitionProperty;Se.MozTransitionProperty=Se.transitionProperty;Se["text-shadow"]=Se.textShadow;Se["border-color"]=Se.borderColor;Se["border-radius"]=Se.borderRadius;Se["background-image"]=Se.backgroundImage;Se["background-position"]=Se.backgroundPosition;Se["background-position-x"]=Se.backgroundPositionX;Se["object-position"]=Se.objectPosition;Se["border-width"]=Se.padding;Se["box-shadow"]=Se.textShadow;Se["-webkit-box-shadow"]=Se.textShadow;Se["-moz-box-shadow"]=Se.textShadow;Se["border-style"]=Se.borderColor;Se["-webkit-transform"]=Se.transform;Se["-moz-transform"]=Se.transform;Se["transform-origin"]=Se.transformOrigin;Se["-webkit-transform-origin"]=Se.transformOrigin;Se["-moz-transform-origin"]=Se.transformOrigin;Se["-webkit-transition"]=Se.transition;Se["-moz-transition"]=Se.transition;Se["transition-property"]=Se.transitionProperty;Se["-webkit-transition-property"]=Se.transitionProperty;Se["-moz-transition-property"]=Se.transitionProperty;var IR=NR([["paddingLeft","paddingRight"],["marginLeft","marginRight"],["left","right"],["borderLeft","borderRight"],["borderLeftColor","borderRightColor"],["borderLeftStyle","borderRightStyle"],["borderLeftWidth","borderRightWidth"],["borderTopLeftRadius","borderTopRightRadius"],["borderBottomLeftRadius","borderBottomRightRadius"],["padding-left","padding-right"],["margin-left","margin-right"],["border-left","border-right"],["border-left-color","border-right-color"],["border-left-style","border-right-style"],["border-left-width","border-right-width"],["border-top-left-radius","border-top-right-radius"],["border-bottom-left-radius","border-bottom-right-radius"]]),One=["content"],_C=NR([["ltr","rtl"],["left","right"],["w-resize","e-resize"],["sw-resize","se-resize"],["nw-resize","ne-resize"]]),Dne=new RegExp("(^|\\W|_)((ltr)|(rtl)|(left)|(right))(\\W|_|$)","g"),Pne=new RegExp("(left)|(right)");function BR(e){return Object.keys(e).reduce(function(t,n){var r=e[n];if(Nne(r)&&(r=r.trim()),Rg(One,n))return t[n]=r,t;var o=E_(n,r),i=o.key,a=o.value;return t[i]=a,t},Array.isArray(e)?[]:{})}function E_(e,t){var n=/\/\*\s?@noflip\s?\*\//.test(t),r=n?e:Mne(e),o=n?t:Lne(r,t);return{key:r,value:o}}function Mne(e){return IR[e]||e}function Lne(e,t){if(!Bne(t))return t;if(Ane(t))return BR(t);var n=wh(t),r=xne(t),o=n||r?t:t.replace(/ !important.*?$/,""),i=!n&&o.length!==t.length,a=Se[e],s;return a?s=a({value:o,valuesToConvert:_C,propertiesToConvert:IR,isRtl:!0,bgImgDirectionRegex:Dne,bgPosDirectionRegex:Pne}):s=_C[o]||o,i?s+" !important":s}var bn="-ms-",zh="-moz-",Qt="-webkit-",RR="comm",Ub="rule",IT="decl",jne="@import",OR="@keyframes",zne=Math.abs,qb=String.fromCharCode,Hne=Object.assign;function Une(e,t){return(((t<<2^Co(e,0))<<2^Co(e,1))<<2^Co(e,2))<<2^Co(e,3)}function DR(e){return e.trim()}function Hl(e,t){return(e=t.exec(e))?e[0]:e}function xt(e,t,n){return e.replace(t,n)}function Og(e,t){return e.indexOf(t)}function Co(e,t){return e.charCodeAt(t)|0}function qd(e,t,n){return e.slice(t,n)}function Ks(e){return e.length}function BT(e){return e.length}function kc(e,t){return t.push(e),e}function qne(e,t){return e.map(t).join("")}var $b=1,$d=1,PR=0,bi=0,Un=0,i1="";function Wb(e,t,n,r,o,i,a){return{value:e,root:t,parent:n,type:r,props:o,children:i,line:$b,column:$d,length:a,return:""}}function oh(e,t){return Hne(Wb("",null,null,"",null,null,0),e,{length:-e.length},t)}function $ne(){return Un}function Wne(){return Un=bi>0?Co(i1,--bi):0,$d--,Un===10&&($d=1,$b--),Un}function Gi(){return Un=bi<PR?Co(i1,bi++):0,$d++,Un===10&&($d=1,$b++),Un}function Fc(){return Co(i1,bi)}function Dg(){return bi}function Gb(e,t){return qd(i1,e,t)}function zv(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function MR(e){return $b=$d=1,PR=Ks(i1=e),bi=0,[]}function LR(e){return i1="",e}function Pg(e){return DR(Gb(bi-1,__(e===91?e+2:e===40?e+1:e)))}function Gne(e){return LR(Vne(MR(e)))}function Kne(e){for(;(Un=Fc())&&Un<33;)Gi();return zv(e)>2||zv(Un)>3?"":" "}function Vne(e){for(;Gi();)switch(zv(Un)){case 0:kc(jR(bi-1),e);break;case 2:kc(Pg(Un),e);break;default:kc(qb(Un),e)}return e}function Yne(e,t){for(;--t&&Gi()&&!(Un<48||Un>102||Un>57&&Un<65||Un>70&&Un<97););return Gb(e,Dg()+(t<6&&Fc()==32&&Gi()==32))}function __(e){for(;Gi();)switch(Un){case e:return bi;case 34:case 39:e!==34&&e!==39&&__(Un);break;case 40:e===41&&__(e);break;case 92:Gi();break}return bi}function Qne(e,t){for(;Gi()&&e+Un!==47+10;)if(e+Un===42+42&&Fc()===47)break;return"/*"+Gb(t,bi-1)+"*"+qb(e===47?e:Gi())}function jR(e){for(;!zv(Fc());)Gi();return Gb(e,bi)}function zR(e){return LR(Mg("",null,null,null,[""],e=MR(e),0,[0],e))}function Mg(e,t,n,r,o,i,a,s,l){for(var u=0,d=0,h=a,p=0,m=0,v=0,_=1,b=1,E=1,w=0,k="",y=o,F=i,C=r,A=k;b;)switch(v=w,w=Gi()){case 40:if(v!=108&&A.charCodeAt(h-1)==58){Og(A+=xt(Pg(w),"&","&\f"),"&\f")!=-1&&(E=-1);break}case 34:case 39:case 91:A+=Pg(w);break;case 9:case 10:case 13:case 32:A+=Kne(v);break;case 92:A+=Yne(Dg()-1,7);continue;case 47:switch(Fc()){case 42:case 47:kc(Xne(Qne(Gi(),Dg()),t,n),l);break;default:A+="/"}break;case 123*_:s[u++]=Ks(A)*E;case 125*_:case 59:case 0:switch(w){case 0:case 125:b=0;case 59+d:m>0&&Ks(A)-h&&kc(m>32?wC(A+";",r,n,h-1):wC(xt(A," ","")+";",r,n,h-2),l);break;case 59:A+=";";default:if(kc(C=TC(A,t,n,u,d,o,s,k,y=[],F=[],h),i),w===123)if(d===0)Mg(A,t,C,C,y,i,h,s,F);else switch(p){case 100:case 109:case 115:Mg(e,C,C,r&&kc(TC(e,C,C,0,0,o,s,k,o,y=[],h),F),o,F,h,s,r?y:F);break;default:Mg(A,C,C,C,[""],F,0,s,F)}}u=d=m=0,_=E=1,k=A="",h=a;break;case 58:h=1+Ks(A),m=v;default:if(_<1){if(w==123)--_;else if(w==125&&_++==0&&Wne()==125)continue}switch(A+=qb(w),w*_){case 38:E=d>0?1:(A+="\f",-1);break;case 44:s[u++]=(Ks(A)-1)*E,E=1;break;case 64:Fc()===45&&(A+=Pg(Gi())),p=Fc(),d=h=Ks(k=A+=jR(Dg())),w++;break;case 45:v===45&&Ks(A)==2&&(_=0)}}return i}function TC(e,t,n,r,o,i,a,s,l,u,d){for(var h=o-1,p=o===0?i:[""],m=BT(p),v=0,_=0,b=0;v<r;++v)for(var E=0,w=qd(e,h+1,h=zne(_=a[v])),k=e;E<m;++E)(k=DR(_>0?p[E]+" "+w:xt(w,/&\f/g,p[E])))&&(l[b++]=k);return Wb(e,t,n,o===0?Ub:s,l,u,d)}function Xne(e,t,n){return Wb(e,t,n,RR,qb($ne()),qd(e,2,-2),0)}function wC(e,t,n,r){return Wb(e,t,n,IT,qd(e,0,r),qd(e,r+1,-1),r)}function HR(e,t,n){switch(Une(e,t)){case 5103:return Qt+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return Qt+e+e;case 4789:return zh+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return Qt+e+zh+e+bn+e+e;case 6828:case 4268:return Qt+e+bn+e+e;case 6165:return Qt+e+bn+"flex-"+e+e;case 5187:return Qt+e+xt(e,/(\w+).+(:[^]+)/,Qt+"box-$1$2"+bn+"flex-$1$2")+e;case 5443:return Qt+e+bn+"flex-item-"+xt(e,/flex-|-self/g,"")+(Hl(e,/flex-|baseline/)?"":bn+"grid-row-"+xt(e,/flex-|-self/g,""))+e;case 4675:return Qt+e+bn+"flex-line-pack"+xt(e,/align-content|flex-|-self/g,"")+e;case 5548:return Qt+e+bn+xt(e,"shrink","negative")+e;case 5292:return Qt+e+bn+xt(e,"basis","preferred-size")+e;case 6060:return Qt+"box-"+xt(e,"-grow","")+Qt+e+bn+xt(e,"grow","positive")+e;case 4554:return Qt+xt(e,/([^-])(transform)/g,"$1"+Qt+"$2")+e;case 6187:return xt(xt(xt(e,/(zoom-|grab)/,Qt+"$1"),/(image-set)/,Qt+"$1"),e,"")+e;case 5495:case 3959:return xt(e,/(image-set\([^]*)/,Qt+"$1$`$1");case 4968:return xt(xt(e,/(.+:)(flex-)?(.*)/,Qt+"box-pack:$3"+bn+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Qt+e+e;case 4200:if(!Hl(e,/flex-|baseline/))return bn+"grid-column-align"+qd(e,t)+e;break;case 2592:case 3360:return bn+xt(e,"template-","")+e;case 4384:case 3616:return n&&n.some(function(r,o){return t=o,Hl(r.props,/grid-\w+-end/)})?~Og(e+(n=n[t].value),"span")?e:bn+xt(e,"-start","")+e+bn+"grid-row-span:"+(~Og(n,"span")?Hl(n,/\d+/):+Hl(n,/\d+/)-+Hl(e,/\d+/))+";":bn+xt(e,"-start","")+e;case 4896:case 4128:return n&&n.some(function(r){return Hl(r.props,/grid-\w+-start/)})?e:bn+xt(xt(e,"-end","-span"),"span ","")+e;case 4095:case 3583:case 4068:case 2532:return xt(e,/(.+)-inline(.+)/,Qt+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Ks(e)-1-t>6)switch(Co(e,t+1)){case 109:if(Co(e,t+4)!==45)break;case 102:return xt(e,/(.+:)(.+)-([^]+)/,"$1"+Qt+"$2-$3$1"+zh+(Co(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~Og(e,"stretch")?HR(xt(e,"stretch","fill-available"),t,n)+e:e}break;case 5152:case 5920:return xt(e,/(.+?):(\d+)(\s*\/\s*(span)?\s*(\d+))?(.*)/,function(r,o,i,a,s,l,u){return bn+o+":"+i+u+(a?bn+o+"-span:"+(s?l:+l-+i)+u:"")+e});case 4949:if(Co(e,t+6)===121)return xt(e,":",":"+Qt)+e;break;case 6444:switch(Co(e,Co(e,14)===45?18:11)){case 120:return xt(e,/(.+:)([^;\s!]+)(;|(\s+)?!.+)?/,"$1"+Qt+(Co(e,14)===45?"inline-":"")+"box$3$1"+Qt+"$2$3$1"+bn+"$2box$3")+e;case 100:return xt(e,":",":"+bn)+e}break;case 5936:switch(Co(e,t+11)){case 114:return Qt+e+bn+xt(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return Qt+e+bn+xt(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return Qt+e+bn+xt(e,/[svh]\w+-[tblr]{2}/,"lr")+e}case 2903:return Qt+e+bn+e+e;case 5719:case 2647:case 2135:case 3927:case 2391:return xt(e,"scroll-","scroll-snap-")+e}return e}function Ic(e,t){for(var n="",r=BT(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function UR(e,t,n,r){switch(e.type){case jne:case IT:return e.return=e.return||e.value;case RR:return"";case OR:return e.return=e.value+"{"+Ic(e.children,r)+"}";case Ub:e.value=e.props.join(",")}return Ks(n=Ic(e.children,r))?e.return=e.value+"{"+n+"}":""}function qR(e){var t=BT(e);return function(n,r,o,i){for(var a="",s=0;s<t;s++)a+=e[s](n,r,o,i)||"";return a}}function $R(e){return function(t){t.root||(t=t.return)&&e(t)}}function WR(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case IT:e.return=HR(e.value,e.length,n);return;case OR:return Ic([oh(e,{value:xt(e.value,"@","@"+Qt)})],r);case Ub:if(e.length)return qne(e.props,function(o){switch(Hl(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Ic([oh(e,{props:[xt(o,/:(read-\w+)/,":"+zh+"$1")]})],r);case"::placeholder":return Ic([oh(e,{props:[xt(o,/:(plac\w+)/,":"+Qt+"input-$1")]}),oh(e,{props:[xt(o,/:(plac\w+)/,":"+zh+"$1")]}),oh(e,{props:[xt(o,/:(plac\w+)/,bn+"input-$1")]})],r)}return""})}}const Zne=e=>{switch(e.type){case Ub:if(typeof e.props=="string")return;e.props=e.props.map(t=>t.indexOf(":global(")===-1?t:Gne(t).reduce((n,r,o,i)=>{if(r==="")return n;if(r===":"&&i[o+1]==="global"){const a=i[o+2].slice(1,-1)+" ";return n.unshift(a),i[o+1]="",i[o+2]="",n}return n.push(r),n},[]).join(""))}},Jne=/[A-Z]/g,ere=/^ms-/,W2={};function tre(e){return"-"+e.toLowerCase()}function kh(e){if(Object.prototype.hasOwnProperty.call(W2,e))return W2[e];if(e.substr(0,2)==="--")return e;const t=e.replace(Jne,tre);return W2[e]=ere.test(t)?"-"+t:t}function GR(e){return e.charAt(0)==="&"?e.slice(1):e}const nre=/,( *[^ &])/g;function rre(e){return"&"+GR(e.replace(nre,",&$1"))}function ore(e){const t=[];return Ic(zR(e),qR([Zne,WR,UR,$R(n=>t.push(n))])),t}function kC(e,t,n){let r=t;return n.length>0&&(r=n.reduceRight((o,i)=>`${rre(i)} { ${o} }`,t)),`${e}{${r}}`}function SC(e){const{className:t,media:n,layer:r,selectors:o,support:i,property:a,rtlClassName:s,rtlProperty:l,rtlValue:u,value:d}=e,h=`.${t}`,p=Array.isArray(d)?`${d.map(v=>`${kh(a)}: ${v}`).join(";")};`:`${kh(a)}: ${d};`;let m=kC(h,p,o);if(l&&s){const v=`.${s}`,_=Array.isArray(u)?`${u.map(b=>`${kh(l)}: ${b}`).join(";")};`:`${kh(l)}: ${u};`;m+=kC(v,_,o)}return n&&(m=`@media ${n} { ${m} }`),r&&(m=`@layer ${r} { ${m} }`),i&&(m=`@supports ${i} { ${m} }`),ore(m)}function ire(e){let t="";for(const n in e){const r=e[n];typeof r!="string"&&typeof r!="number"||(t+=kh(n)+":"+r+";")}return t}function xC(e){let t="";for(const n in e)t+=`${n}{${ire(e[n])}}`;return t}function CC(e,t){const n=`@keyframes ${e} {${t}}`,r=[];return Ic(zR(n),qR([WR,UR,$R(o=>r.push(o))])),r}function AC(e,t){return e.length===0?t:`${e} and ${t}`}function are(e){return e.substr(0,6)==="@media"}function sre(e){return e.substr(0,6)==="@layer"}const lre=/^(:|\[|>|&)/;function ure(e){return lre.test(e)}function cre(e){return e.substr(0,9)==="@supports"}function fre(e){return e!=null&&typeof e=="object"&&Array.isArray(e)===!1}const NC={"us-w":"w","us-v":"i",nk:"l",si:"v",cu:"f",ve:"h",ti:"a"};function FC(e,t,n,r){if(n)return"m";if(t||r)return"t";if(e.length>0){const o=e[0].trim();if(o.charCodeAt(0)===58)return NC[o.slice(4,8)]||NC[o.slice(3,5)]||"d"}return"d"}function zm({media:e,layer:t,property:n,selectors:r,support:o,value:i}){const a=Ud(r.join("")+e+t+o+n+i.trim());return b_+a}function IC(e,t,n,r){const o=e.join("")+t+n+r,i=Ud(o),a=i.charCodeAt(0);return a>=48&&a<=57?String.fromCharCode(a+17)+i.substr(1):i}function BC(e,t,n,r){e[t]=r?[n,r]:n}function RC(e,t){return t?[e,t]:e}function G2(e,t,n,r,o){var i;let a;t==="m"&&o&&(a={m:o}),(i=e[t])!==null&&i!==void 0||(e[t]=[]),n&&e[t].push(RC(n,a)),r&&e[t].push(RC(r,a))}function $f(e,t=[],n="",r="",o="",i={},a={},s){for(const l in e){if(mne.hasOwnProperty(l))continue;const u=e[l];if(u!=null){if(typeof u=="string"||typeof u=="number"){const d=IC(t,n,o,l),h=zm({media:n,layer:r,value:u.toString(),support:o,selectors:t,property:l}),p=s&&{key:l,value:s}||E_(l,u),m=p.key!==l||p.value!==u,v=m?zm({value:p.value.toString(),property:p.key,selectors:t,media:n,layer:r,support:o}):void 0,_=m?{rtlClassName:v,rtlProperty:p.key,rtlValue:p.value}:void 0,b=FC(t,r,n,o),[E,w]=SC(Object.assign({className:h,media:n,layer:r,selectors:t,property:l,support:o,value:u},_));BC(i,d,h,v),G2(a,b,E,w,n)}else if(l==="animationName"){const d=Array.isArray(u)?u:[u],h=[],p=[];for(const m of d){const v=xC(m),_=xC(BR(m)),b=b_+Ud(v);let E;const w=CC(b,v);let k=[];v===_?E=b:(E=b_+Ud(_),k=CC(E,_));for(let y=0;y<w.length;y++)G2(a,"k",w[y],k[y],n);h.push(b),p.push(E)}$f({animationName:h.join(", ")},t,n,r,o,i,a,p.join(", "))}else if(Array.isArray(u)){if(u.length===0)continue;const d=IC(t,n,o,l),h=zm({media:n,layer:r,value:u.map(y=>(y??"").toString()).join(";"),support:o,selectors:t,property:l}),p=u.map(y=>E_(l,y));if(!!p.some(y=>y.key!==p[0].key))continue;const v=p[0].key!==l||p.some((y,F)=>y.value!==u[F]),_=v?zm({value:p.map(y=>{var F;return((F=y==null?void 0:y.value)!==null&&F!==void 0?F:"").toString()}).join(";"),property:p[0].key,selectors:t,layer:r,media:n,support:o}):void 0,b=v?{rtlClassName:_,rtlProperty:p[0].key,rtlValue:p.map(y=>y.value)}:void 0,E=FC(t,r,n,o),[w,k]=SC(Object.assign({className:h,media:n,layer:r,selectors:t,property:l,support:o,value:u},b));BC(i,d,h,_),G2(a,E,w,k,n)}else if(fre(u)){if(ure(l))$f(u,t.concat(GR(l)),n,r,o,i,a);else if(are(l)){const d=AC(n,l.slice(6).trim());$f(u,t,d,r,o,i,a)}else if(sre(l)){const d=(r?`${r}.`:"")+l.slice(6).trim();$f(u,t,n,d,o,i,a)}else if(cre(l)){const d=AC(o,l.slice(9).trim());$f(u,t,n,r,d,i,a)}}}}return[i,a]}function dre(e){const t={},n={};for(const r in e){const o=e[r],[i,a]=$f(o);t[r]=i,Object.keys(a).forEach(s=>{n[s]=(n[s]||[]).concat(a[s])})}return[t,n]}function hre(e){const t={};let n=null,r=null,o=null,i=null;function a(s){const{dir:l,renderer:u}=s;n===null&&([n,r]=dre(e));const d=l==="ltr",h=d?u.id:u.id+"r";return d?o===null&&(o=jv(n,l)):i===null&&(i=jv(n,l)),t[h]===void 0&&(u.insertCSSRules(r),t[h]=!0),d?o:i}return a}function KR(e,t){const n={};let r=null,o=null;function i(a){const{dir:s,renderer:l}=a,u=s==="ltr",d=u?l.id:l.id+"r";return u?r===null&&(r=jv(e,s)):o===null&&(o=jv(e,s)),n[d]===void 0&&(l.insertCSSRules(t),n[d]=!0),u?r:o}return i}function pre(e,t,n){const r={};function o(i){const{dir:a,renderer:s}=i,l=a==="ltr",u=l?s.id:s.id+"r";return r[u]===void 0&&(s.insertCSSRules({r:n}),r[u]=!0),l?e:t||e}return o}const mt={border:jte,borderLeft:zte,borderBottom:Hte,borderRight:Ute,borderTop:qte,borderColor:xR,borderStyle:SR,borderRadius:$te,borderWidth:kR,flex:Yte,gap:Qte,gridArea:tne,margin:nne,padding:rne,overflow:one,inset:ine,outline:ane,transition:sne},mre=T.createContext(kne());function ep(){return T.useContext(mre)}const VR=T.createContext("ltr"),gre=({children:e,dir:t})=>T.createElement(VR.Provider,{value:t},e);function RT(){return T.useContext(VR)}function OT(e){const t=hre(e);return function(){const r=RT(),o=ep();return t({dir:r,renderer:o})}}function pt(e,t){const n=KR(e,t);return function(){const o=RT(),i=ep();return n({dir:o,renderer:i})}}function $c(e,t,n){const r=pre(e,t,n);return function(){const i=RT(),a=ep();return r({dir:i,renderer:a})}}const YR=T.createContext(void 0),vre=YR.Provider,QR=T.createContext(void 0),bre="",yre=QR.Provider;function XR(){var e;return(e=T.useContext(QR))!==null&&e!==void 0?e:bre}const ZR=T.createContext(void 0),Ere={},_re=ZR.Provider;function Tre(){var e;return(e=T.useContext(ZR))!==null&&e!==void 0?e:Ere}const JR=T.createContext(void 0),wre={targetDocument:typeof document=="object"?document:void 0,dir:"ltr"},kre=JR.Provider;function Oo(){var e;return(e=T.useContext(JR))!==null&&e!==void 0?e:wre}const eO=T.createContext(void 0),Sre=eO.Provider;function tO(){var e;return(e=T.useContext(eO))!==null&&e!==void 0?e:{}}function xre(e,t){const n={};for(const r in e)t.indexOf(r)===-1&&e.hasOwnProperty(r)&&(n[r]=e[r]);return n}function Jn(e){const t={},n={},r=Object.keys(e.components);for(const o of r){const[i,a]=Cre(e,o);t[o]=i,n[o]=a}return{slots:t,slotProps:n}}function Cre(e,t){var n,r,o;if(e[t]===void 0)return[null,void 0];const{children:i,as:a,...s}=e[t],l=((n=e.components)===null||n===void 0?void 0:n[t])===void 0||typeof e.components[t]=="string"?a||((r=e.components)===null||r===void 0?void 0:r[t])||"div":e.components[t];if(typeof i=="function"){const h=i;return[T.Fragment,{children:h(l,s)}]}const d=typeof l=="string"&&((o=e[t])===null||o===void 0?void 0:o.as)?xre(e[t],["as"]):e[t];return[l,d]}const $t=(e,t)=>{const{required:n=!1,defaultProps:r}=t||{};if(e===null||e===void 0&&!n)return;let o={};return typeof e=="string"||typeof e=="number"||Array.isArray(e)||T.isValidElement(e)?o.children=e:typeof e=="object"&&(o=e),r?{...r,...o}:o};function Are(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)&&!T.isValidElement(e)}function Nre(e){return typeof e=="function"}const Wc=e=>{const t=Fre(e.state),n=typeof e.defaultState>"u"?e.initialState:e.defaultState,[r,o]=T.useState(n),i=t?e.state:r,a=T.useRef(i);T.useEffect(()=>{a.current=i},[i]);const s=T.useCallback(l=>{Nre(l)?a.current=l(a.current):a.current=l,o(a.current)},[]);return[i,s]},Fre=e=>{const[t]=T.useState(()=>e!==void 0);return t};function DT(){return typeof window<"u"&&!!(window.document&&window.document.createElement)}const nO={current:0},Ire=T.createContext(void 0);function rO(){var e;return(e=T.useContext(Ire))!==null&&e!==void 0?e:nO}function Bre(){const e=rO()!==nO,[t,n]=T.useState(e);return DT()&&e&&T.useLayoutEffect(()=>{n(!1)},[]),t}const us=DT()?T.useLayoutEffect:T.useEffect,Et=e=>{const t=T.useRef(()=>{throw new Error("Cannot call an event handler while rendering")});return us(()=>{t.current=e},[e]),T.useCallback((...n)=>{const r=t.current;return r(...n)},[t])},oO=T.createContext(void 0);oO.Provider;function Rre(){return T.useContext(oO)||""}function lo(e="fui-",t){const n=rO(),r=Rre(),o=n0["useId"];return o?t||`${r}${e}${o()}`:T.useMemo(()=>t||`${r}${e}${++n.current}`,[r,e,t,n])}function cs(...e){const t=T.useCallback(n=>{t.current=n;for(const r of e)typeof r=="function"?r(n):r&&(r.current=n)},[...e]);return t}const iO=e=>{const{refs:t,callback:n,element:r,disabled:o,contains:i}=e,a=T.useRef(void 0);Dre(!o,r,n);const s=Et(l=>{const u=i||((h,p)=>!!(h!=null&&h.contains(p)));t.every(h=>!u(h.current||null,l.target))&&!o&&n(l)});T.useEffect(()=>{let l=Ore(window);const u=d=>{if(d===l){l=void 0;return}s(d)};return o||(r==null||r.addEventListener("click",u,!0),r==null||r.addEventListener("touchstart",u,!0),r==null||r.addEventListener("contextmenu",u,!0)),a.current=window.setTimeout(()=>{l=void 0},1),()=>{r==null||r.removeEventListener("click",u,!0),r==null||r.removeEventListener("touchstart",u,!0),r==null||r.removeEventListener("contextmenu",u,!0),clearTimeout(a.current),l=void 0}},[s,r,o])},Ore=e=>{var t,n,r;if(e)return typeof e.window=="object"&&e.window===e?e.event:(r=(n=(t=e.ownerDocument)===null||t===void 0?void 0:t.defaultView)===null||n===void 0?void 0:n.event)!==null&&r!==void 0?r:void 0},K2="fuiframefocus",Dre=(e,t,n,r=1e3)=>{const o=T.useRef(),i=Et(a=>{n&&n(a)});T.useEffect(()=>(e&&(t==null||t.addEventListener(K2,i,!0)),()=>{t==null||t.removeEventListener(K2,i,!0)}),[t,e,i]),T.useEffect(()=>{var a;return e&&(o.current=(a=t==null?void 0:t.defaultView)===null||a===void 0?void 0:a.setInterval(()=>{const s=t==null?void 0:t.activeElement;if((s==null?void 0:s.tagName)==="IFRAME"||(s==null?void 0:s.tagName)==="WEBVIEW"){const l=new CustomEvent(K2,{bubbles:!0});s.dispatchEvent(l)}},r)),()=>{var s;(s=t==null?void 0:t.defaultView)===null||s===void 0||s.clearTimeout(o.current)}},[t,e,r])},aO=e=>{const{refs:t,callback:n,element:r,disabled:o,contains:i}=e,a=Et(s=>{const l=i||((d,h)=>!!(d!=null&&d.contains(h)));t.every(d=>!l(d.current||null,s.target))&&!o&&n(s)});T.useEffect(()=>(o||(r==null||r.addEventListener("wheel",a),r==null||r.addEventListener("touchmove",a)),()=>{r==null||r.removeEventListener("wheel",a),r==null||r.removeEventListener("touchmove",a)}),[a,r,o])};function Pre(){const[e]=T.useState(()=>({id:void 0,set:(t,n)=>{e.clear(),e.id=setTimeout(t,n)},clear:()=>{e.id!==void 0&&(clearTimeout(e.id),e.id=void 0)}}));return T.useEffect(()=>e.clear,[e]),[e.set,e.clear]}const _n=(...e)=>{const t={};for(const n of e){const r=Array.isArray(n)?n:Object.keys(n);for(const o of r)t[o]=1}return t},Mre=_n(["onAuxClick","onCopy","onCut","onPaste","onCompositionEnd","onCompositionStart","onCompositionUpdate","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onInput","onSubmit","onLoad","onError","onKeyDown","onKeyDownCapture","onKeyPress","onKeyUp","onAbort","onCanPlay","onCanPlayThrough","onDurationChange","onEmptied","onEncrypted","onEnded","onLoadedData","onLoadedMetadata","onLoadStart","onPause","onPlay","onPlaying","onProgress","onRateChange","onSeeked","onSeeking","onStalled","onSuspend","onTimeUpdate","onVolumeChange","onWaiting","onClick","onClickCapture","onContextMenu","onDoubleClick","onDrag","onDragEnd","onDragEnter","onDragExit","onDragLeave","onDragOver","onDragStart","onDrop","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseOut","onMouseOver","onMouseUp","onMouseUpCapture","onSelect","onTouchCancel","onTouchEnd","onTouchMove","onTouchStart","onScroll","onWheel","onPointerCancel","onPointerDown","onPointerEnter","onPointerLeave","onPointerMove","onPointerOut","onPointerOver","onPointerUp","onGotPointerCapture","onLostPointerCapture"]),Lre=_n(["accessKey","children","className","contentEditable","dir","draggable","hidden","htmlFor","id","lang","ref","role","style","tabIndex","title","translate","spellCheck","name"]),jre=_n(["itemID","itemProp","itemRef","itemScope","itemType"]),gr=_n(Lre,Mre,jre),zre=_n(gr,["form"]),sO=_n(gr,["height","loop","muted","preload","src","width"]),Hre=_n(sO,["poster"]),Ure=_n(gr,["start"]),qre=_n(gr,["value"]),$re=_n(gr,["download","href","hrefLang","media","rel","target","type"]),Wre=_n(gr,["dateTime"]),Kb=_n(gr,["autoFocus","disabled","form","formAction","formEncType","formMethod","formNoValidate","formTarget","type","value"]),Gre=_n(Kb,["accept","alt","autoCapitalize","autoComplete","checked","dirname","form","height","inputMode","list","max","maxLength","min","multiple","pattern","placeholder","readOnly","required","src","step","size","type","value","width"]),Kre=_n(Kb,["autoCapitalize","cols","dirname","form","maxLength","placeholder","readOnly","required","rows","wrap"]),Vre=_n(Kb,["form","multiple","required"]),Yre=_n(gr,["selected","value"]),Qre=_n(gr,["cellPadding","cellSpacing"]),Xre=gr,Zre=_n(gr,["colSpan","rowSpan","scope"]),Jre=_n(gr,["colSpan","headers","rowSpan","scope"]),eoe=_n(gr,["span"]),toe=_n(gr,["span"]),noe=_n(gr,["disabled","form"]),roe=_n(gr,["acceptCharset","action","encType","encType","method","noValidate","target"]),ooe=_n(gr,["allow","allowFullScreen","allowPaymentRequest","allowTransparency","csp","height","importance","referrerPolicy","sandbox","src","srcDoc","width"]),ioe=_n(gr,["alt","crossOrigin","height","src","srcSet","useMap","width"]),aoe=_n(gr,["open","onCancel","onClose"]);function soe(e,t,n){const r=Array.isArray(t),o={},i=Object.keys(e);for(const a of i)(!r&&t[a]||r&&t.indexOf(a)>=0||a.indexOf("data-")===0||a.indexOf("aria-")===0)&&(!n||(n==null?void 0:n.indexOf(a))===-1)&&(o[a]=e[a]);return o}const loe={label:zre,audio:sO,video:Hre,ol:Ure,li:qre,a:$re,button:Kb,input:Gre,textarea:Kre,select:Vre,option:Yre,table:Qre,tr:Xre,th:Zre,td:Jre,colGroup:eoe,col:toe,fieldset:noe,form:roe,iframe:ooe,img:ioe,time:Wre,dialog:aoe};function vr(e,t,n){const r=e&&loe[e]||gr;return r.as=1,soe(t,r,n)}const lO=({primarySlotTagName:e,props:t,excludedPropNames:n})=>({root:{style:t.style,className:t.className},primary:vr(e,t,[...n||[],"style","className"])});function Vn(e,t){return(...n)=>{e==null||e(...n),t==null||t(...n)}}function uO(e){return!!e.type.isFluentTriggerComponent}function Vb(e,t){return typeof e=="function"?e(t):e?cO(e,t):e||null}function cO(e,t){if(!T.isValidElement(e)||e.type===T.Fragment)throw new Error("A trigger element must be a single element for this component. Please ensure that you're not using React Fragments.");if(uO(e)){const n=cO(e.props.children,t);return T.cloneElement(e,void 0,n)}else return T.cloneElement(e,t)}function tp(e){return T.isValidElement(e)?uO(e)?tp(e.props.children):e:null}const uoe=(e,t)=>{const{slots:n,slotProps:r}=Jn(e);return T.createElement(kre,{value:t.provider},T.createElement(vre,{value:t.theme},T.createElement(yre,{value:t.themeClassName},T.createElement(_re,{value:t.tooltip},T.createElement(gre,{dir:t.textDirection},T.createElement(Sre,{value:t.overrides_unstable},T.createElement(n.root,{...r.root},e.root.children)))))))};/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const coe=typeof WeakRef<"u";class fO{constructor(t){coe&&typeof t=="object"?this._weakRef=new WeakRef(t):this._instance=t}deref(){var t,n,r;let o;return this._weakRef?(o=(t=this._weakRef)===null||t===void 0?void 0:t.deref(),o||delete this._weakRef):(o=this._instance,!((r=(n=o)===null||n===void 0?void 0:n.isDisposed)===null||r===void 0)&&r.call(n)&&delete this._instance),o}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const wa="keyborg:focusin";function foe(e){const t=e.HTMLElement,n=t.prototype.focus;let r=!1;return t.prototype.focus=function(){r=!0},e.document.createElement("button").focus(),t.prototype.focus=n,r}let V2=!1;function np(e){const t=e.focus;t.__keyborgNativeFocus?t.__keyborgNativeFocus.call(e):e.focus()}function doe(e){const t=e;V2||(V2=foe(t));const n=t.HTMLElement.prototype.focus;if(n.__keyborgNativeFocus)return;t.HTMLElement.prototype.focus=o;const r=t.__keyborgData={focusInHandler:i=>{var a;const s=i.target;if(!s)return;const l=document.createEvent("HTMLEvents");l.initEvent(wa,!0,!0);const u={relatedTarget:i.relatedTarget||void 0};(V2||r.lastFocusedProgrammatically)&&(u.isFocusedProgrammatically=s===((a=r.lastFocusedProgrammatically)===null||a===void 0?void 0:a.deref()),r.lastFocusedProgrammatically=void 0),l.details=u,s.dispatchEvent(l)}};t.document.addEventListener("focusin",t.__keyborgData.focusInHandler,!0);function o(){const i=t.__keyborgData;return i&&(i.lastFocusedProgrammatically=new fO(this)),n.apply(this,arguments)}o.__keyborgNativeFocus=n}function hoe(e){const t=e,n=t.HTMLElement.prototype,r=n.focus.__keyborgNativeFocus,o=t.__keyborgData;o&&(t.document.removeEventListener("focusin",o.focusInHandler,!0),delete t.__keyborgData),r&&(n.focus=r)}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const poe=9,moe=27,goe=500;let dO=0;class voe{constructor(){this.__keyborgCoreRefs={},this._isNavigatingWithKeyboard=!1}add(t){const n=t.id;n in this.__keyborgCoreRefs||(this.__keyborgCoreRefs[n]=new fO(t))}remove(t){delete this.__keyborgCoreRefs[t],Object.keys(this.__keyborgCoreRefs).length===0&&(this._isNavigatingWithKeyboard=!1)}setVal(t){if(this._isNavigatingWithKeyboard!==t){this._isNavigatingWithKeyboard=t;for(const n of Object.keys(this.__keyborgCoreRefs)){const o=this.__keyborgCoreRefs[n].deref();o?o.update(t):this.remove(n)}}}getVal(){return this._isNavigatingWithKeyboard}}const za=new voe;class boe{constructor(t){this._isMouseUsed=!1,this._onFocusIn=r=>{if(this._isMouseUsed){this._isMouseUsed=!1;return}if(za.getVal())return;const o=r.details;o.relatedTarget&&(o.isFocusedProgrammatically||o.isFocusedProgrammatically===void 0||za.setVal(!0))},this._onMouseDown=r=>{r.buttons===0||r.clientX===0&&r.clientY===0&&r.screenX===0&&r.screenY===0||(this._isMouseUsed=!0,za.setVal(!1))},this._onKeyDown=r=>{const o=za.getVal();!o&&r.keyCode===poe?za.setVal(!0):o&&r.keyCode===moe&&this._scheduleDismiss()},this.id="c"+ ++dO,this._win=t;const n=t.document;n.addEventListener(wa,this._onFocusIn,!0),n.addEventListener("mousedown",this._onMouseDown,!0),t.addEventListener("keydown",this._onKeyDown,!0),doe(t),za.add(this)}dispose(){const t=this._win;if(t){this._dismissTimer&&(t.clearTimeout(this._dismissTimer),this._dismissTimer=void 0),hoe(t);const n=t.document;n.removeEventListener(wa,this._onFocusIn,!0),n.removeEventListener("mousedown",this._onMouseDown,!0),t.removeEventListener("keydown",this._onKeyDown,!0),delete this._win,za.remove(this.id)}}isDisposed(){return!!this._win}update(t){var n,r;const o=(r=(n=this._win)===null||n===void 0?void 0:n.__keyborg)===null||r===void 0?void 0:r.refs;if(o)for(const i of Object.keys(o))rp.update(o[i],t)}_scheduleDismiss(){const t=this._win;if(t){this._dismissTimer&&(t.clearTimeout(this._dismissTimer),this._dismissTimer=void 0);const n=t.document.activeElement;this._dismissTimer=t.setTimeout(()=>{this._dismissTimer=void 0;const r=t.document.activeElement;n&&r&&n===r&&za.setVal(!1)},goe)}}}class rp{constructor(t){this._cb=[],this._id="k"+ ++dO,this._win=t;const n=t.__keyborg;n?(this._core=n.core,n.refs[this._id]=this):(this._core=new boe(t),t.__keyborg={core:this._core,refs:{[this._id]:this}})}static create(t){return new rp(t)}static dispose(t){t.dispose()}static update(t,n){t._cb.forEach(r=>r(n))}dispose(){var t;const n=(t=this._win)===null||t===void 0?void 0:t.__keyborg;n!=null&&n.refs[this._id]&&(delete n.refs[this._id],Object.keys(n.refs).length===0&&(n.core.dispose(),delete this._win.__keyborg)),this._cb=[],delete this._core,delete this._win}isNavigatingWithKeyboard(){return za.getVal()}subscribe(t){this._cb.push(t)}unsubscribe(t){const n=this._cb.indexOf(t);n>=0&&this._cb.splice(n,1)}setVal(t){za.setVal(t)}}function Yb(e){return rp.create(e)}function Qb(e){rp.dispose(e)}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const xd="data-tabster",hO="data-tabster-dummy",pO="tabster:deloser",mO="tabster:modalizer",T_="tabster:mover",yoe={Any:0,Accessible:1,Focusable:2},Wf={History:0,DeloserDefault:1,RootDefault:2,DeloserFirst:3,RootFirst:4},Ul={Invisible:0,PartiallyVisible:1,Visible:2},Gf={Both:0,Vertical:1,Horizontal:2,Grid:3},Eoe={Unlimited:0,Limited:1,LimitedTrapFocus:2};var Hm=Object.freeze({__proto__:null,TabsterAttributeName:xd,TabsterDummyInputAttributeName:hO,DeloserEventName:pO,ModalizerEventName:mO,MoverEventName:T_,ObservedElementAccesibilities:yoe,RestoreFocusOrders:Wf,Visibilities:Ul,MoverDirections:Gf,GroupperTabbabilities:Eoe});/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */function Au(e,t){var n;return(n=e.storageEntry(t))===null||n===void 0?void 0:n.tabster}function _oe(e,t,n){var r,o;const i=n||e._noop?void 0:t.getAttribute(xd);let a=e.storageEntry(t),s;if(i)if(i!==((r=a==null?void 0:a.attr)===null||r===void 0?void 0:r.string))try{const h=JSON.parse(i);if(typeof h!="object")throw new Error(`Value is not a JSON object, got '${i}'.`);s={string:i,object:h}}catch{}else return;else if(!a)return;a||(a=e.storageEntry(t,!0)),a.tabster||(a.tabster={});const l=a.tabster||{},u=((o=a.attr)===null||o===void 0?void 0:o.object)||{},d=(s==null?void 0:s.object)||{};for(const h of Object.keys(u))if(!d[h]){if(h==="root"){const p=l[h];p&&e.root.onRoot(p,!0)}else if(h==="modalizer"){const p=l.modalizer;e.modalizer&&p&&e.modalizer.updateModalizer(p,!0)}switch(h){case"deloser":case"root":case"groupper":case"modalizer":case"mover":const p=l[h];p&&(p.dispose(),delete l[h]);break;case"observed":delete l[h],e.observedElement&&e.observedElement.onObservedElementUpdate(t);break;case"focusable":case"outline":case"uncontrolled":delete l[h];break}}for(const h of Object.keys(d))switch(h){case"deloser":l.deloser?l.deloser.setProps(d.deloser):e.deloser&&(l.deloser=e.deloser.createDeloser(t,d.deloser));break;case"root":l.root?l.root.setProps(d.root):l.root=e.root.createRoot(t,d.root),e.root.onRoot(l.root);break;case"modalizer":l.modalizer?l.modalizer.setProps(d.modalizer):e.modalizer&&(l.modalizer=e.modalizer.createModalizer(t,d.modalizer));break;case"focusable":l.focusable=d.focusable;break;case"groupper":l.groupper?l.groupper.setProps(d.groupper):e.groupper&&(l.groupper=e.groupper.createGroupper(t,d.groupper));break;case"mover":l.mover?l.mover.setProps(d.mover):e.mover&&(l.mover=e.mover.createMover(t,d.mover));break;case"observed":e.observedElement&&(l.observed=d.observed,e.observedElement.onObservedElementUpdate(t));break;case"uncontrolled":l.uncontrolled=d.uncontrolled;break;case"outline":e.outline&&(l.outline=d.outline);break;default:console.error(`Unknown key '${h}' in data-tabster attribute value.`)}s?a.attr=s:(Object.keys(l).length===0&&(delete a.tabster,delete a.attr),e.storageEntry(t,!1))}function Toe(e,t,n,r){const o=e.storageEntry(t,!0);if(!o.aug){if(r===void 0)return;o.aug={}}if(r===void 0){if(n in o.aug){const i=o.aug[n];delete o.aug[n],i===null?t.removeAttribute(n):t.setAttribute(n,i)}}else n in o.aug||(o.aug[n]=t.getAttribute(n)),r===null?t.removeAttribute(n):t.setAttribute(n,r);r===void 0&&Object.keys(o.aug).length===0&&(delete o.aug,e.storageEntry(t,!1))}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */function woe(e){const t=e();return t.EventTarget?new t.EventTarget:t.document.createElement("div")}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */let w_;const OC=typeof DOMRect<"u"?DOMRect:class{constructor(e,t,n,r){this.left=e||0,this.top=t||0,this.right=(e||0)+(n||0),this.bottom=(t||0)+(r||0)}};let koe=0;try{document.createTreeWalker(document,NodeFilter.SHOW_ELEMENT),w_=!1}catch{w_=!0}function bl(e){const t=e();let n=t.__tabsterInstanceContext;return n||(n={elementByUId:{},basics:{Promise:t.Promise||void 0,WeakRef:t.WeakRef||void 0},containerBoundingRectCache:{},lastContainerBoundingRectCacheId:0,fakeWeakRefs:[],fakeWeakRefsStarted:!1},t.__tabsterInstanceContext=n),n}function Soe(e){const t=e.__tabsterInstanceContext;t&&(t.elementByUId={},delete t.WeakRef,t.containerBoundingRectCache={},t.containerBoundingRectCacheTimer&&e.clearTimeout(t.containerBoundingRectCacheTimer),t.fakeWeakRefsTimer&&e.clearTimeout(t.fakeWeakRefsTimer),t.fakeWeakRefs=[],delete e.__tabsterInstanceContext)}function xoe(e){const t=e.__tabsterInstanceContext;return new((t==null?void 0:t.basics.WeakMap)||WeakMap)}class gO{constructor(t){this._target=t}deref(){return this._target}static cleanup(t,n){return t._target?n||!Zb(t._target.ownerDocument,t._target)?(delete t._target,!0):!1:!0}}class os{constructor(t,n,r){const o=bl(t);let i;o.WeakRef?i=new o.WeakRef(n):(i=new gO(n),o.fakeWeakRefs.push(i)),this._ref=i,this._data=r}get(){const t=this._ref;let n;return t&&(n=t.deref(),n||delete this._ref),n}getData(){return this._data}}function vO(e,t){const n=bl(e);n.fakeWeakRefs=n.fakeWeakRefs.filter(r=>!gO.cleanup(r,t))}function bO(e){const t=bl(e);t.fakeWeakRefsStarted||(t.fakeWeakRefsStarted=!0,t.WeakRef=Foe(t)),t.fakeWeakRefsTimer||(t.fakeWeakRefsTimer=e().setTimeout(()=>{t.fakeWeakRefsTimer=void 0,vO(e),bO(e)},2*60*1e3))}function Coe(e){const t=bl(e);t.fakeWeakRefsStarted=!1,t.fakeWeakRefsTimer&&(e().clearTimeout(t.fakeWeakRefsTimer),t.fakeWeakRefsTimer=void 0,t.fakeWeakRefs=[])}function Xb(e,t,n){if(t.nodeType!==Node.ELEMENT_NODE)return;const r=w_?n:{acceptNode:n};return e.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,r,!1)}function yO(e,t){let n=t.__tabsterCacheId;const r=bl(e),o=n?r.containerBoundingRectCache[n]:void 0;if(o)return o.rect;const i=t.ownerDocument&&t.ownerDocument.documentElement;if(!i)return new OC;let a=0,s=0,l=i.clientWidth,u=i.clientHeight;if(t!==i){const h=t.getBoundingClientRect();a=Math.max(a,h.left),s=Math.max(s,h.top),l=Math.min(l,h.right),u=Math.min(u,h.bottom)}const d=new OC(a<l?a:-1,s<u?s:-1,a<l?l-a:0,s<u?u-s:0);return n||(n="r-"+ ++r.lastContainerBoundingRectCacheId,t.__tabsterCacheId=n),r.containerBoundingRectCache[n]={rect:d,element:t},r.containerBoundingRectCacheTimer||(r.containerBoundingRectCacheTimer=window.setTimeout(()=>{r.containerBoundingRectCacheTimer=void 0;for(const h of Object.keys(r.containerBoundingRectCache))delete r.containerBoundingRectCache[h].element.__tabsterCacheId;r.containerBoundingRectCache={}},50)),d}function DC(e,t){const n=EO(t);if(n){const r=yO(e,n),o=t.getBoundingClientRect();return o.top>=r.top&&o.bottom<=r.bottom}return!1}function PC(e,t,n){const r=EO(t);if(r){const o=yO(e,r),i=t.getBoundingClientRect();n?r.scrollTop+=i.top-o.top:r.scrollTop+=i.bottom-o.bottom}}function EO(e){const t=e.ownerDocument;if(t){for(let n=e.parentElement;n;n=n.parentElement)if(n.scrollWidth>n.clientWidth||n.scrollHeight>n.clientHeight)return n;return t.documentElement}return null}function Aoe(e){e.__shouldIgnoreFocus=!0}function _O(e){return!!e.__shouldIgnoreFocus}function Noe(e){const t=new Uint32Array(4);if(e.crypto&&e.crypto.getRandomValues)e.crypto.getRandomValues(t);else if(e.msCrypto&&e.msCrypto.getRandomValues)e.msCrypto.getRandomValues(t);else for(let r=0;r<t.length;r++)t[r]=4294967295*Math.random();const n=[];for(let r=0;r<t.length;r++)n.push(t[r].toString(36));return n.push("|"),n.push((++koe).toString(36)),n.push("|"),n.push(Date.now().toString(36)),n.join("")}function Hh(e,t){const n=bl(e);let r=t.__tabsterElementUID;return r||(r=t.__tabsterElementUID=Noe(e())),!n.elementByUId[r]&&Zb(t.ownerDocument,t)&&(n.elementByUId[r]=new os(e,t)),r}function MC(e,t){const n=bl(e);for(const r of Object.keys(n.elementByUId)){const o=n.elementByUId[r],i=o&&o.get();i&&t&&!t.contains(i)||delete n.elementByUId[r]}}function Zb(e,t){var n;return!!(!((n=e==null?void 0:e.body)===null||n===void 0)&&n.contains(t))}function TO(e,t){const n=e.matches||e.matchesSelector||e.msMatchesSelector||e.webkitMatchesSelector;return n&&n.call(e,t)}function wO(e){const t=bl(e);if(t.basics.Promise)return t.basics.Promise;throw new Error("No Promise defined.")}function Foe(e){return e.basics.WeakRef}let Ioe=0;class Jb{constructor(t,n,r){const o=t.getWindow;this._tabster=t,this._element=new os(o,n),this._props={...r},this.id="i"+ ++Ioe}getElement(){return this._element.get()}getProps(){return this._props}setProps(t){this._props={...t}}}class k_{constructor(t,n,r,o){var i;this._focusIn=u=>{const d=this.input;if(this.onFocusIn&&d){const h=es.getLastPhantomFrom()||u.relatedTarget;this.onFocusIn(this,this._isBackward(!0,d,h),h)}},this._focusOut=u=>{this.shouldMoveOut=!1;const d=this.input;if(this.onFocusOut&&d){const h=u.relatedTarget;this.onFocusOut(this,this._isBackward(!1,d,h),h)}};const a=t(),s=a.document.createElement("i");s.tabIndex=0,s.setAttribute("role","none"),s.setAttribute(hO,""),s.setAttribute("aria-hidden","true");const l=s.style;l.position="fixed",l.width=l.height="1px",l.opacity="0.001",l.zIndex="-1",l.setProperty("content-visibility","hidden"),Aoe(s),this.input=s,this.isFirst=r.isFirst,this.isOutside=n,this._isPhantom=(i=r.isPhantom)!==null&&i!==void 0?i:!1,s.addEventListener("focusin",this._focusIn),s.addEventListener("focusout",this._focusOut),s.__tabsterDummyContainer=o,this._isPhantom&&(this._disposeTimer=a.setTimeout(()=>{delete this._disposeTimer,this.dispose()},0),this._clearDisposeTimeout=()=>{this._disposeTimer&&(a.clearTimeout(this._disposeTimer),delete this._disposeTimer),delete this._clearDisposeTimeout})}dispose(){var t;this._clearDisposeTimeout&&this._clearDisposeTimeout();const n=this.input;n&&(delete this.onFocusIn,delete this.onFocusOut,delete this.input,n.removeEventListener("focusin",this._focusIn),n.removeEventListener("focusout",this._focusOut),delete n.__tabsterDummyContainer,(t=n.parentElement)===null||t===void 0||t.removeChild(n))}setTopLeft(t,n){var r;const o=(r=this.input)===null||r===void 0?void 0:r.style;o&&(o.top=`${t}px`,o.left=`${n}px`)}_isBackward(t,n,r){return t&&!r?!this.isFirst:!!(r&&n.compareDocumentPosition(r)&Node.DOCUMENT_POSITION_FOLLOWING)}}const PT={Root:1,Modalizer:2,Mover:3,Groupper:4};class es{constructor(t,n,r,o){this._element=n,this._instance=new Boe(t,n,this,r,o),this.moveOutWithDefaultAction=i=>{var a;(a=this._instance)===null||a===void 0||a.moveOutWithDefaultAction(i)}}_setHandlers(t,n){this._onFocusIn=t,this._onFocusOut=n}getHandler(t){return t?this._onFocusIn:this._onFocusOut}setTabbable(t){var n;(n=this._instance)===null||n===void 0||n.setTabbable(this,t)}dispose(){this._instance&&(this._instance.dispose(this),delete this._instance),delete this._onFocusIn,delete this._onFocusOut}static getLastPhantomFrom(){const t=es._lastPhantomFrom;return delete es._lastPhantomFrom,t}static moveWithPhantomDummy(t,n,r,o){const a=new k_(t.getWindow,!0,{isPhantom:!0,isFirst:!0}).input;if(a){const s=n.parentElement;if(s){let l=r&&!o||!r&&o?n.nextElementSibling:n;if(l)if(o){const u=l.previousElementSibling;u&&u.__tabsterDummyContainer&&(l=u)}else l.__tabsterDummyContainer&&(l=l.nextElementSibling);s.insertBefore(a,l),es._lastPhantomFrom=n,t.getWindow().setTimeout(()=>{delete es._lastPhantomFrom},0),np(a)}}}}class Boe{constructor(t,n,r,o,i){var a;this._wrappers=[],this._isOutside=!1,this._transformElements=[],this._onFocusIn=(d,h,p)=>{this._onFocus(!0,d,h,p)},this._onFocusOut=(d,h,p)=>{this._onFocus(!1,d,h,p)},this.moveOutWithDefaultAction=d=>{const h=this._firstDummy,p=this._lastDummy;h!=null&&h.input&&(p!=null&&p.input)&&(d?(h.shouldMoveOut=!0,h.input.tabIndex=0,h.input.focus()):(p.shouldMoveOut=!0,p.input.tabIndex=0,p.input.focus()))},this.setTabbable=(d,h)=>{var p,m;for(const _ of this._wrappers)if(_.manager===d){_.tabbable=h;break}const v=this._getCurrent();if(v){const _=v.tabbable?0:-1;let b=(p=this._firstDummy)===null||p===void 0?void 0:p.input;b&&(b.tabIndex=_),b=(m=this._lastDummy)===null||m===void 0?void 0:m.input,b&&(b.tabIndex=_)}},this._addTransformOffsets=()=>{const d=this._getWindow();this._scrollTimer&&d.clearTimeout(this._scrollTimer),this._scrollTimer=d.setTimeout(()=>{delete this._scrollTimer,this._reallyAddTransformOffsets()},100)};const s=n.get();if(!s)throw new Error("No element");this._getWindow=t.getWindow;const l=s.__tabsterDummy;if((l||this)._wrappers.push({manager:r,priority:o,tabbable:!0}),l)return l;s.__tabsterDummy=this,this._firstDummy=new k_(this._getWindow,this._isOutside,{isFirst:!0},n),this._lastDummy=new k_(this._getWindow,this._isOutside,{isFirst:!1},n),this._firstDummy.onFocusIn=this._onFocusIn,this._firstDummy.onFocusOut=this._onFocusOut,this._lastDummy.onFocusIn=this._onFocusIn,this._lastDummy.onFocusOut=this._onFocusOut,this._element=n,this._addDummyInputs();const u=(a=n.get())===null||a===void 0?void 0:a.tagName;this._isOutside=(i||u==="UL"||u==="OL"||u==="TABLE")&&!(u==="LI"||u==="TD"||u==="TH"),(typeof process>"u"||{}.NODE_ENV!=="test")&&this._observeMutations()}dispose(t,n){var r,o,i;if((this._wrappers=this._wrappers.filter(s=>s.manager!==t&&!n)).length===0){delete((r=this._element)===null||r===void 0?void 0:r.get()).__tabsterDummy,this._unobserve&&(this._unobserve(),delete this._unobserve);for(const l of this._transformElements)l.removeEventListener("scroll",this._addTransformOffsets);this._transformElements=[];const s=this._getWindow();this._scrollTimer&&(s.clearTimeout(this._scrollTimer),delete this._scrollTimer),this._addTimer&&(s.clearTimeout(this._addTimer),delete this._addTimer),(o=this._firstDummy)===null||o===void 0||o.dispose(),(i=this._lastDummy)===null||i===void 0||i.dispose()}}_onFocus(t,n,r,o){var i;const a=this._getCurrent();a&&((i=a.manager.getHandler(t))===null||i===void 0||i(n,r,o))}_getCurrent(){return this._wrappers.sort((t,n)=>t.tabbable!==n.tabbable?t.tabbable?-1:1:t.priority-n.priority),this._wrappers[0]}_addDummyInputs(){this._addTimer||(this._addTimer=this._getWindow().setTimeout(()=>{var t,n,r;delete this._addTimer;const o=(t=this._element)===null||t===void 0?void 0:t.get(),i=(n=this._firstDummy)===null||n===void 0?void 0:n.input,a=(r=this._lastDummy)===null||r===void 0?void 0:r.input;if(!(!o||!i||!a)){if(this._isOutside){const s=o.parentElement;if(s){const l=o.nextElementSibling;l!==a&&s.insertBefore(a,l),o.previousElementSibling!==i&&s.insertBefore(i,o)}}else{o.lastElementChild!==a&&o.appendChild(a);const s=o.firstElementChild;s&&s!==i&&o.insertBefore(i,s)}this._addTransformOffsets()}},0))}_observeMutations(){var t;if(this._unobserve)return;const n=new MutationObserver(()=>{this._unobserve&&this._addDummyInputs()}),r=(t=this._element)===null||t===void 0?void 0:t.get(),o=this._isOutside?r==null?void 0:r.parentElement:r;o&&(n.observe(o,{childList:!0}),this._unobserve=()=>{n.disconnect()})}_reallyAddTransformOffsets(){var t,n,r,o;const i=((t=this._firstDummy)===null||t===void 0?void 0:t.input)||((n=this._lastDummy)===null||n===void 0?void 0:n.input),a=this._transformElements,s=[],l=new WeakMap,u=new WeakMap;let d=0,h=0;for(const m of a)l.set(m,m);const p=this._getWindow();for(let m=i;m;m=m.parentElement){const v=p.getComputedStyle(m).transform;if(v&&v!=="none"){let _=l.get(m);_||(_=m,_.addEventListener("scroll",this._addTransformOffsets)),s.push(_),u.set(_,_),d+=_.scrollTop,h+=_.scrollLeft}}for(const m of a)u.get(m)||m.removeEventListener("scroll",this._addTransformOffsets);this._transformElements=s,(r=this._firstDummy)===null||r===void 0||r.setTopLeft(d,h),(o=this._lastDummy)===null||o===void 0||o.setTopLeft(d,h)}}function kO(e){let t=null;for(let n=e.lastElementChild;n;n=n.lastElementChild)t=n;return t||void 0}function LC(e,t){let n=e,r=null;for(;n&&!r;)r=t?n.previousElementSibling:n.nextElementSibling,n=n.parentElement;return r||void 0}function Wd(e,t,n){const r=document.createEvent("HTMLEvents");return r.initEvent(t,!0,!0),r.details=n,e.dispatchEvent(r),!r.defaultPrevented}class jC extends es{constructor(t,n,r){super(t,n,PT.Root),this._onDummyInputFocus=o=>{var i;if(o.shouldMoveOut)this._setFocused(!1,!0);else{this._tabster.keyboardNavigation.setNavigatingWithKeyboard(!0);const a=this._element.get();if(a&&(this._setFocused(!0,!0),o.isFirst?this._tabster.focusedElement.focusFirst({container:a}):this._tabster.focusedElement.focusLast({container:a})))return;(i=o.input)===null||i===void 0||i.blur()}},this._setHandlers(this._onDummyInputFocus),this._tabster=t,this._setFocused=r}}class zC extends Jb{constructor(t,n,r,o){super(t,n,o),this._isFocused=!1,this._setFocused=(a,s)=>{if(this._setFocusedTimer&&(this._tabster.getWindow().clearTimeout(this._setFocusedTimer),delete this._setFocusedTimer),this._isFocused===a)return;const l=this._element.get();l&&(a?(this._isFocused=!0,Wd(this._tabster.root.eventTarget,"focus",{element:l,fromAdjacent:s})):this._setFocusedTimer=this._tabster.getWindow().setTimeout(()=>{delete this._setFocusedTimer,this._isFocused=!1,Wd(this._tabster.root.eventTarget,"blur",{element:l,fromAdjacent:s})},0))},this._onFocus=a=>{var s;const l=this._tabster.getWindow();if(this._setTabbableTimer&&(l.clearTimeout(this._setTabbableTimer),delete this._setTabbableTimer),a){const u=Io.getTabsterContext(this._tabster,a);if(u&&this._setFocused(u.root.getElement()===this._element.get()),!u||u.uncontrolled||this._tabster.rootDummyInputs){(s=this._dummyManager)===null||s===void 0||s.setTabbable(!1);return}}else this._setFocused(!1);this._setTabbableTimer=l.setTimeout(()=>{var u;delete this._setTabbableTimer,(u=this._dummyManager)===null||u===void 0||u.setTabbable(!0)},0)},this._onDispose=r;const i=t.getWindow;this.uid=Hh(i,n),(t.controlTab||t.rootDummyInputs)&&(this._dummyManager=new jC(t,this._element,this._setFocused)),t.focusedElement.subscribe(this._onFocus),this._add()}dispose(){var t;this._onDispose(this);const n=this._tabster.getWindow();this._setFocusedTimer&&(n.clearTimeout(this._setFocusedTimer),delete this._setFocusedTimer),this._setTabbableTimer&&(n.clearTimeout(this._setTabbableTimer),delete this._setTabbableTimer),(t=this._dummyManager)===null||t===void 0||t.dispose(),this._remove()}moveOutWithDefaultAction(t){const n=this._dummyManager;if(n)n.moveOutWithDefaultAction(t);else{const r=this.getElement();r&&jC.moveWithPhantomDummy(this._tabster,r,!0,t)}}_add(){}_remove(){}}class Io{constructor(t,n){this._roots={},this.rootById={},this._init=()=>{this._initTimer=void 0},this._onRootDispose=r=>{delete this._roots[r.id]},this._tabster=t,this._win=t.getWindow,this._initTimer=this._win().setTimeout(this._init,0),this._autoRoot=n,this.eventTarget=woe(this._win)}dispose(){const t=this._win();this._autoRootInstance&&(this._autoRootInstance.dispose(),delete this._autoRootInstance,delete this._autoRoot),this._initTimer&&(t.clearTimeout(this._initTimer),this._initTimer=void 0),Object.keys(this._roots).forEach(n=>{this._roots[n]&&(this._roots[n].dispose(),delete this._roots[n])}),this.rootById={}}createRoot(t,n){const r=new zC(this._tabster,t,this._onRootDispose,n);return this._roots[r.id]=r,r}static getRootByUId(t,n){const r=t().__tabsterInstance;return r&&r.root.rootById[n]}static getTabsterContext(t,n,r){r===void 0&&(r={});var o,i,a;if(!n.ownerDocument)return;const s=r.checkRtl;let l,u,d,h,p=!1,m,v,_,b=n;const E={};for(;b&&(!l||s);){const w=Au(t,b);if(s&&v===void 0){const F=b.dir;F&&(v=F.toLowerCase()==="rtl")}if(!w){b=b.parentElement;continue}w.uncontrolled&&(_=b),!h&&(!((o=w.focusable)===null||o===void 0)&&o.excludeFromMover)&&!d&&(p=!0);const k=w.groupper,y=w.mover;!d&&k&&(d=k),!h&&y&&(h=y,m=!!d),!u&&w.modalizer&&(u=w.modalizer),w.root&&(l=w.root),!((i=w.focusable)===null||i===void 0)&&i.ignoreKeydown&&Object.assign(E,w.focusable.ignoreKeydown),b=b.parentElement}if(!l){const w=t.root,k=w._autoRoot;if(k&&!w._autoRootInstance){const y=(a=n.ownerDocument)===null||a===void 0?void 0:a.body;y&&(w._autoRootInstance=new zC(w._tabster,y,w._onRootDispose,k))}l=w._autoRootInstance}return d&&!h&&(m=!0),l?{root:l,modalizer:u,groupper:d,mover:h,isGroupperFirst:m,isRtl:s?!!v:void 0,uncontrolled:_,isExcludedFromMover:p,ignoreKeydown:E}:void 0}onRoot(t,n){n?delete this.rootById[t.uid]:this.rootById[t.uid]=t}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const A0=10;class Roe{}class Ooe extends Roe{constructor(t,n){super(),this.uid=n.uid,this._tabster=t,this._deloser=n}belongsTo(t){return t===this._deloser}unshift(t){this._deloser.unshift(t)}async focusAvailable(){const t=this._deloser.findAvailable();return t?this._tabster.focusedElement.focus(t):!1}async resetFocus(){const t=this._tabster.getWindow;return wO(t).resolve(this._deloser.resetFocus())}}class Doe{constructor(t,n){this._history=[],this._tabster=t,this.rootUId=n}getLength(){return this._history.length}removeDeloser(t){this._history=this._history.filter(n=>!n.belongsTo(t))}hasDeloser(t){return this._history.some(n=>n.belongsTo(t))}}class Poe extends Doe{unshiftToDeloser(t,n){let r;for(let o=0;o<this._history.length;o++)if(this._history[o].belongsTo(t)){r=this._history[o],this._history.splice(o,1);break}r||(r=new Ooe(this._tabster,t)),r.unshift(n),this._history.unshift(r),this._history.splice(A0,this._history.length-A0)}async focusAvailable(t){let n=!!t;for(const r of this._history)if(t&&r.belongsTo(t)&&(n=!1),!n&&await r.focusAvailable())return!0;return!1}async resetFocus(t){let n=!!t;const r={};for(const o of this._history)t&&o.belongsTo(t)&&(n=!1),!n&&!r[o.uid]&&(r[o.uid]=o);for(const o of Object.keys(r))if(await r[o].resetFocus())return!0;return!1}}class Moe{constructor(t){this._history=[],this._tabster=t}dispose(){this._history=[]}process(t){var n;const r=Io.getTabsterContext(this._tabster,t),o=r&&r.root.uid,i=SO.getDeloser(this._tabster,t);if(!o||!i)return;const a=this.make(o,()=>new Poe(this._tabster,o));return(!r||!r.modalizer||!((n=r.modalizer)===null||n===void 0)&&n.isActive())&&a.unshiftToDeloser(i,t),i}make(t,n){let r;for(let o=0;o<this._history.length;o++){const i=this._history[o];if(i.rootUId===t){r=i,this._history.splice(o,1);break}}return r||(r=n()),this._history.unshift(r),this._history.splice(A0,this._history.length-A0),r}removeDeloser(t){this._history.forEach(n=>{n.removeDeloser(t)}),this._history=this._history.filter(n=>n.getLength()>0)}async focusAvailable(t){let n=!!t;for(const r of this._history)if(t&&r.hasDeloser(t)&&(n=!1),!n&&await r.focusAvailable(t))return!0;return!1}async resetFocus(t){let n=!!t;for(const r of this._history)if(t&&r.hasDeloser(t)&&(n=!1),!n&&await r.resetFocus(t))return!0;return!1}}function HC(e,t,n){const r=[],o=/(:|\.|\[|\]|,|=|@)/g,i="\\$1";e.id&&r.push("#"+e.id.replace(o,i)),t!==!1&&e.className&&e.className.split(" ").forEach(l=>{l=l.trim(),l&&r.push("."+l.replace(o,i))});let a=0,s;if(n!==!1&&r.length===0){for(s=e;s;)a++,s=s.previousElementSibling;r.unshift(":nth-child("+a+")")}return r.unshift(e.tagName.toLowerCase()),r.join("")}function Loe(e){if(!Zb(e.ownerDocument,e))return;const t=[HC(e)];let n=e.parentElement;for(;n;){const r=n.tagName==="BODY";if(t.unshift(HC(n,!1,!r)),r)break;n=n.parentElement}return t.join(" ")}class UC extends Jb{constructor(t,n,r,o){super(t,n,o),this._isActive=!1,this._history=[[]],this._snapshotIndex=0,this.isActive=()=>this._isActive,this.setSnapshot=i=>{this._snapshotIndex=i,this._history.length>i+1&&this._history.splice(i+1,this._history.length-i-1),this._history[i]||(this._history[i]=[])},this.focusFirst=()=>{const i=this._element.get();return!!i&&this._tabster.focusedElement.focusFirst({container:i})},this.focusDefault=()=>{const i=this._element.get();return!!i&&this._tabster.focusedElement.focusDefault(i)},this.resetFocus=()=>{const i=this._element.get();return!!i&&this._tabster.focusedElement.resetFocus(i)},this.clearHistory=i=>{const a=this._element.get();if(!a){this._history[this._snapshotIndex]=[];return}this._history[this._snapshotIndex]=this._history[this._snapshotIndex].filter(s=>{const l=s.get();return l&&i?a.contains(l):!1})},this.uid=Hh(t.getWindow,n),this._onDispose=r}dispose(){this._remove(),this._onDispose(this),this._isActive=!1,this._snapshotIndex=0,this._props={},this._history=[]}setActive(t){this._isActive=t}getActions(){return{focusDefault:this.focusDefault,focusFirst:this.focusFirst,resetFocus:this.resetFocus,clearHistory:this.clearHistory,setSnapshot:this.setSnapshot,isActive:this.isActive}}unshift(t){let n=this._history[this._snapshotIndex];for(n=this._history[this._snapshotIndex]=n.filter(r=>{const o=r.get();return o&&o!==t}),n.unshift(new os(this._tabster.getWindow,t,Loe(t)));n.length>A0;)n.pop()}findAvailable(){const t=this._element.get();if(!t||!this._tabster.focusable.isVisible(t))return null;let n=this._props.restoreFocusOrder,r=null;const o=Io.getTabsterContext(this._tabster,t);if(!o)return null;const i=o.root,a=i.getElement();if(!a)return null;if(n===void 0&&(n=i.getProps().restoreFocusOrder),n===Wf.RootDefault&&(r=this._tabster.focusable.findDefault({container:a})),!r&&n===Wf.RootFirst&&(r=this._findFirst(a)),r)return r;const s=this._findInHistory(),l=this._tabster.focusable.findDefault({container:t}),u=this._findFirst(t);return s&&n===Wf.History?s:l&&n===Wf.DeloserDefault?l:u&&n===Wf.DeloserFirst?u:l||s||u||null}customFocusLostHandler(t){return Wd(t,pO,this.getActions())}_findInHistory(){const t=this._history[this._snapshotIndex].slice(0);this.clearHistory(!0);for(let n=0;n<t.length;n++){const r=t[n],o=r.get(),i=this._element.get();if(o&&i&&i.contains(o)){if(this._tabster.focusable.isFocusable(o))return o}else if(!this._props.noSelectorCheck){const a=r.getData();if(a&&i){let s;try{s=i.ownerDocument.querySelectorAll(a)}catch{continue}for(let l=0;l<s.length;l++){const u=s[l];if(u&&this._tabster.focusable.isFocusable(u))return u}}}}return null}_findFirst(t){if(this._tabster.keyboardNavigation.isNavigatingWithKeyboard()){const n=this._tabster.focusable.findFirst({container:t});if(n)return n}return null}_remove(){}}class SO{constructor(t,n){this._inDeloser=!1,this._isRestoringFocus=!1,this._isPaused=!1,this._init=()=>{this._initTimer=void 0,this._tabster.focusedElement.subscribe(this._onFocus)},this._onFocus=o=>{if(this._restoreFocusTimer&&(this._win().clearTimeout(this._restoreFocusTimer),this._restoreFocusTimer=void 0),!o){this._scheduleRestoreFocus();return}const i=this._history.process(o);i?this._activate(i):this._deactivate()},this._onDeloserDispose=o=>{this._history.removeDeloser(o),o.isActive()&&this._scheduleRestoreFocus()},this._tabster=t,this._win=t.getWindow,this._history=new Moe(t),this._initTimer=this._win().setTimeout(this._init,0);const r=n==null?void 0:n.autoDeloser;r&&(this._autoDeloser=r)}dispose(){const t=this._win();this._initTimer&&(t.clearTimeout(this._initTimer),this._initTimer=void 0),this._restoreFocusTimer&&(t.clearTimeout(this._restoreFocusTimer),this._restoreFocusTimer=void 0),this._autoDeloserInstance&&(this._autoDeloserInstance.dispose(),delete this._autoDeloserInstance,delete this._autoDeloser),this._tabster.focusedElement.unsubscribe(this._onFocus),this._history.dispose(),delete this._curDeloser}createDeloser(t,n){var r;const o=new UC(this._tabster,t,this._onDeloserDispose,n);return t.contains((r=this._tabster.focusedElement.getFocusedElement())!==null&&r!==void 0?r:null)&&this._activate(o),o}getActions(t){for(let n=t;n;n=n.parentElement){const r=Au(this._tabster,n);if(r&&r.deloser)return r.deloser.getActions()}}pause(){this._isPaused=!0,this._restoreFocusTimer&&(this._win().clearTimeout(this._restoreFocusTimer),this._restoreFocusTimer=void 0)}resume(t){this._isPaused=!1,t&&this._scheduleRestoreFocus()}_activate(t){const n=this._curDeloser;n!==t&&(this._inDeloser=!0,n==null||n.setActive(!1),t.setActive(!0),this._curDeloser=t)}_deactivate(){var t;this._inDeloser=!1,(t=this._curDeloser)===null||t===void 0||t.setActive(!1),this._curDeloser=void 0}_scheduleRestoreFocus(t){if(this._isPaused||this._isRestoringFocus)return;const n=async()=>{this._restoreFocusTimer=void 0;const r=this._tabster.focusedElement.getLastFocusedElement();if(!t&&(this._isRestoringFocus||!this._inDeloser||r!=null&&r.offsetParent))return;const o=this._curDeloser;if(o){if(r&&o.customFocusLostHandler(r))return;const i=o.findAvailable();if(i&&this._tabster.focusedElement.focus(i))return}this._deactivate(),this._isRestoringFocus=!0,await this._history.focusAvailable(null)||await this._history.resetFocus(null),this._isRestoringFocus=!1};t?n():this._restoreFocusTimer=this._win().setTimeout(n,100)}static getDeloser(t,n){var r;for(let i=n;i;i=i.parentElement){const a=Au(t,i);if(a&&a.deloser)return a.deloser}const o=t.deloser&&t.deloser;if(o){if(o._autoDeloserInstance)return o._autoDeloserInstance;const i=o._autoDeloser;if(!o._autoDeloserInstance&&i){const a=(r=n.ownerDocument)===null||r===void 0?void 0:r.body;a&&(o._autoDeloserInstance=new UC(t,a,t.deloser._onDeloserDispose,i))}return o._autoDeloserInstance}}static getHistory(t){return t._history}static forceRestoreFocus(t){t._scheduleRestoreFocus(!0)}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */let xO=class{constructor(){this._callbacks=[]}dispose(){this._callbacks=[],delete this._val}subscribe(t){this._callbacks.indexOf(t)<0&&this._callbacks.push(t)}unsubscribe(t){const n=this._callbacks.indexOf(t);n>=0&&this._callbacks.splice(n,1)}setVal(t,n){this._val!==t&&(this._val=t,this._callCallbacks(t,n))}getVal(){return this._val}trigger(t,n){this._callCallbacks(t,n)}_callCallbacks(t,n){this._callbacks.forEach(r=>r(t,n))}};/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const joe=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])","*[tabindex]","*[contenteditable]"].join(", ");class zoe{constructor(t,n){this._tabster=t,this._win=n}dispose(){}_getBody(){const t=this._tabster.focusedElement.getLastFocusedElement();return t&&t.ownerDocument?t.ownerDocument.body:this._win().document.body}getProps(t){const n=Au(this._tabster,t);return n&&n.focusable||{}}isFocusable(t,n,r,o){return TO(t,joe)&&(n||t.tabIndex!==-1)?(r||this.isVisible(t))&&(o||this.isAccessible(t)):!1}isVisible(t){if(!t.ownerDocument||t.offsetParent===null&&t.ownerDocument.body!==t)return!1;const n=t.ownerDocument.defaultView;if(!n)return!1;const r=t.ownerDocument.body.getBoundingClientRect();return!(r.width===0&&r.height===0||n.getComputedStyle(t).visibility==="hidden")}isAccessible(t){var n;for(let r=t;r;r=r.parentElement){const o=Au(this._tabster,r);if(this._isHidden(r)||!((n=o==null?void 0:o.focusable)===null||n===void 0?void 0:n.ignoreAriaDisabled)&&this._isDisabled(r))return!1}return!0}_isDisabled(t){return t.hasAttribute("disabled")}_isHidden(t){const n=t.getAttribute("aria-hidden");return!!(n&&n.toLowerCase()==="true")}findFirst(t){return this.findElement({container:this._getBody(),...t})}findLast(t){return this.findElement({container:this._getBody(),isBackward:!0,...t})}findNext(t){return this.findElement({container:this._getBody(),...t})}findPrev(t){return this.findElement({container:this._getBody(),isBackward:!0,...t})}findDefault(t){return this.findElement({...t,acceptCondition:n=>this._tabster.focusable.isFocusable(n,t.includeProgrammaticallyFocusable)&&!!this.getProps(n).isDefault})||null}findAll(t){return this._findElements(!0,t)||[]}findElement(t){const n=this._findElements(!1,t);return n&&n[0]}_findElements(t,n){const{container:r,currentElement:o=null,includeProgrammaticallyFocusable:i,ignoreUncontrolled:a,ignoreAccessibiliy:s,isBackward:l,onUncontrolled:u,onElement:d}=n,h=[];let{acceptCondition:p}=n;if(!r)return null;p||(p=E=>this._tabster.focusable.isFocusable(E,i,s,s));const m={container:r,from:o||r,isBackward:l,acceptCondition:p,includeProgrammaticallyFocusable:i,ignoreUncontrolled:a,ignoreAccessibiliy:s,cachedGrouppers:{}},v=Xb(r.ownerDocument,r,E=>this._acceptElement(E,m));if(!v)return null;const _=E=>{const w=m.foundElement;return w&&h.push(w),t?w&&(m.found=!1,delete m.foundElement,delete m.fromCtx,m.from=w,d&&!d(w))?!1:!!(w||E):!!(E&&!w)};if(o)v.currentNode=o;else if(l){const E=kO(r);if(!E)return null;if(this._acceptElement(E,m)===NodeFilter.FILTER_ACCEPT&&!_(!0))return h;v.currentNode=E}let b;do b=(l?v.previousNode():v.nextNode())||void 0;while(_());if(!t){const E=m.nextUncontrolled;if(E)return u&&u(E),b?void 0:null}return h.length?h:null}_acceptElement(t,n){if(n.found)return NodeFilter.FILTER_ACCEPT;const r=n.container;if(t===r)return NodeFilter.FILTER_SKIP;if(!r.contains(t)||t.__tabsterDummyContainer)return NodeFilter.FILTER_REJECT;let o=n.lastToIgnore;if(o){if(o.contains(t))return NodeFilter.FILTER_REJECT;o=n.lastToIgnore=void 0}const i=n.currentCtx=Io.getTabsterContext(this._tabster,t);if(!i)return NodeFilter.FILTER_SKIP;if(n.ignoreUncontrolled){if(_O(t))return NodeFilter.FILTER_SKIP}else if(i.uncontrolled&&!n.nextUncontrolled&&this._tabster.focusable.isFocusable(t,void 0,!0,!0)&&!i.groupper&&!i.mover)return n.nextUncontrolled=i.uncontrolled,NodeFilter.FILTER_REJECT;if(t.tagName==="IFRAME"||t.tagName==="WEBVIEW")return n.found=!0,n.lastToIgnore=n.foundElement=t,NodeFilter.FILTER_ACCEPT;if(!n.ignoreAccessibiliy&&!this.isAccessible(t))return NodeFilter.FILTER_REJECT;let a,s=n.fromCtx;s||(s=n.fromCtx=Io.getTabsterContext(this._tabster,n.from));const l=s==null?void 0:s.mover;let u=i.groupper,d=i.mover;if(u||d||l){const h=u==null?void 0:u.getElement(),p=l==null?void 0:l.getElement();let m=d==null?void 0:d.getElement();m&&p&&r.contains(p)&&(!h||!d||p.contains(h))&&(d=l,m=p),h&&(h===r||!r.contains(h))&&(u=void 0),m&&!r.contains(m)&&(d=void 0),u&&d&&(m&&h&&!h.contains(m)?d=void 0:u=void 0),u&&(a=u.acceptElement(t,n)),d&&(a=d.acceptElement(t,n))}return a===void 0&&(a=n.acceptCondition(t)?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP),a===NodeFilter.FILTER_ACCEPT&&!n.found&&(n.found=!0,n.foundElement=t),a}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const Ht={Tab:9,Enter:13,Esc:27,Space:32,PageUp:33,PageDown:34,End:35,Home:36,Left:37,Up:38,Right:39,Down:40};/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */class ar extends xO{constructor(t,n){super(),this._init=()=>{this._initTimer=void 0;const r=this._win();r.document.addEventListener(wa,this._onFocusIn,!0),r.document.addEventListener("focusout",this._onFocusOut,!0),r.addEventListener("keydown",this._onKeyDown,!0)},this._onFocusIn=r=>{this._setFocusedElement(r.target,r.details.relatedTarget,r.details.isFocusedProgrammatically)},this._onFocusOut=r=>{this._setFocusedElement(void 0,r.relatedTarget)},this._validateFocusedElement=r=>{},this._onKeyDown=r=>{var o,i,a,s;if(r.keyCode!==Ht.Tab||r.ctrlKey)return;const l=this.getVal();if(!l||!l.ownerDocument||l.contentEditable==="true")return;const u=this._tabster,d=u.controlTab,h=Io.getTabsterContext(u,l);if(!h||!d&&!h.groupper&&!h.mover||h.ignoreKeydown[r.key])return;const p=r.shiftKey,m=ar.findNextTabbable(u,h,void 0,l,p);if((!m||!d&&!m.element)&&!d){const _=m==null?void 0:m.lastMoverOrGroupper;if(_){(o=_.dummyManager)===null||o===void 0||o.moveOutWithDefaultAction(p);return}}let v;if(m){let _=m.uncontrolled;if(_){const b=h.isGroupperFirst;let E=!1;if(b!==void 0){const w=(i=h.groupper)===null||i===void 0?void 0:i.getElement(),k=(a=h.mover)===null||a===void 0?void 0:a.getElement();let y;b&&w&&_.contains(w)?y=w:!b&&k&&_.contains(k)&&(y=k),y&&(_=y,E=!0)}_&&h.uncontrolled!==_&&es.moveWithPhantomDummy(this._tabster,_,E,p);return}if(v=m.element,h.modalizer){const b=v&&Io.getTabsterContext(u,v);if((!b||h.root.uid!==b.root.uid||!(!((s=b.modalizer)===null||s===void 0)&&s.isActive()))&&h.modalizer.onBeforeFocusOut()){r.preventDefault();return}if(!v&&h.modalizer.isActive()&&h.modalizer.getProps().isTrapped){const E=p?"findLast":"findFirst";v=u.focusable[E]({container:h.modalizer.getElement()})}}}v?v.tagName!=="IFRAME"&&(r.preventDefault(),r.stopImmediatePropagation(),np(v)):h.root.moveOutWithDefaultAction(p)},this._tabster=t,this._win=n,this._initTimer=n().setTimeout(this._init,0)}dispose(){super.dispose();const t=this._win();this._initTimer&&(t.clearTimeout(this._initTimer),this._initTimer=void 0),t.document.removeEventListener(wa,this._onFocusIn,!0),t.document.removeEventListener("focusout",this._onFocusOut,!0),t.removeEventListener("keydown",this._onKeyDown,!0),delete ar._lastResetElement,delete this._nextVal,delete this._lastVal}static forgetMemorized(t,n){var r,o;let i=ar._lastResetElement,a=i&&i.get();a&&n.contains(a)&&delete ar._lastResetElement,a=(o=(r=t._nextVal)===null||r===void 0?void 0:r.element)===null||o===void 0?void 0:o.get(),a&&n.contains(a)&&delete t._nextVal,i=t._lastVal,a=i&&i.get(),a&&n.contains(a)&&delete t._lastVal}getFocusedElement(){return this.getVal()}getLastFocusedElement(){var t;let n=(t=this._lastVal)===null||t===void 0?void 0:t.get();return(!n||n&&!Zb(n.ownerDocument,n))&&(this._lastVal=n=void 0),n}focus(t,n,r){return this._tabster.focusable.isFocusable(t,n,!1,r)?(t.focus(),!0):!1}focusDefault(t){const n=this._tabster.focusable.findDefault({container:t});return n?(this._tabster.focusedElement.focus(n),!0):!1}_focusFirstOrLast(t,n){const r=this._tabster.focusable,o=n.container;let i,a;if(o){const s=Io.getTabsterContext(this._tabster,o);if(s){let l=ar.findNextTabbable(this._tabster,s,o,void 0,!t);if(l)for(a=l.element,i=l.uncontrolled;!a&&i;)r.isFocusable(i,!1,!0,!0)?a=i:a=r[t?"findFirst":"findLast"]({container:i,ignoreUncontrolled:!0,ignoreAccessibiliy:!0}),a||(l=ar.findNextTabbable(this._tabster,s,i,void 0,!t),l&&(a=l.element,i=l.uncontrolled))}}return a&&!(o!=null&&o.contains(a))&&(a=void 0),a?(this.focus(a,!1,!0),!0):!1}focusFirst(t){return this._focusFirstOrLast(!0,t)}focusLast(t){return this._focusFirstOrLast(!1,t)}resetFocus(t){if(!this._tabster.focusable.isVisible(t))return!1;if(this._tabster.focusable.isFocusable(t,!0,!0,!0))this.focus(t);else{const n=t.getAttribute("tabindex"),r=t.getAttribute("aria-hidden");t.tabIndex=-1,t.setAttribute("aria-hidden","true"),ar._lastResetElement=new os(this._win,t),this.focus(t,!0,!0),this._setOrRemoveAttribute(t,"tabindex",n),this._setOrRemoveAttribute(t,"aria-hidden",r)}return!0}_setOrRemoveAttribute(t,n,r){r===null?t.removeAttribute(n):t.setAttribute(n,r)}_setFocusedElement(t,n,r){var o;if(this._tabster._noop)return;const i={relatedTarget:n};if(t){const s=(o=ar._lastResetElement)===null||o===void 0?void 0:o.get();if(ar._lastResetElement=void 0,s===t||_O(t))return;i.isFocusedProgrammatically=r}const a=this._nextVal={element:t?new os(this._win,t):void 0,details:i};t&&t!==this._val&&this._validateFocusedElement(t),this._nextVal===a&&this.setVal(t,i),this._nextVal=void 0}setVal(t,n){super.setVal(t,n),t&&(this._lastVal=new os(this._win,t))}static findNextTabbable(t,n,r,o,i){var a;const s=r||n.root.getElement();if(!s)return null;let l=null;const u=ar._isTabbingTimer,d=t.getWindow();u&&d.clearTimeout(u),ar.isTabbing=!0,ar._isTabbingTimer=d.setTimeout(()=>{delete ar._isTabbingTimer,ar.isTabbing=!1},0);const h=m=>{l=m.findNextTabbable(o,i)};if(n.groupper&&n.mover){let m=n.isGroupperFirst;if(m&&o){const v=Io.getTabsterContext(t,o);(v==null?void 0:v.groupper)!==n.groupper&&(m=!1)}h(m?n.groupper:n.mover)}else if(n.groupper)h(n.groupper);else if(n.mover)h(n.mover);else{let m;const v=b=>{m=b},_=i?t.focusable.findPrev({container:s,currentElement:o,onUncontrolled:v}):t.focusable.findNext({container:s,currentElement:o,onUncontrolled:v});l={element:m?void 0:_,uncontrolled:m}}const p=(a=l==null?void 0:l.lastMoverOrGroupper)===null||a===void 0?void 0:a.getElement();if(p){l=null;const m=LC(p,i);if(m){const v=Io.getTabsterContext(t,m,{checkRtl:!0});if(v){let _=LC(m,!i);_&&(i||(_=kO(_)),l=ar.findNextTabbable(t,v,s,_,i))}}}return l}}ar.isTabbing=!1;/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */class Hoe extends xO{constructor(t){super(),this._onChange=n=>{this.setVal(n,void 0)},this._keyborg=Yb(t()),this._keyborg.subscribe(this._onChange)}dispose(){super.dispose(),this._keyborg&&(this._keyborg.unsubscribe(this._onChange),Qb(this._keyborg),delete this._keyborg)}setNavigatingWithKeyboard(t){var n;(n=this._keyborg)===null||n===void 0||n.setVal(t)}isNavigatingWithKeyboard(){var t;return!!(!((t=this._keyborg)===null||t===void 0)&&t.isNavigatingWithKeyboard())}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */let Uoe=0;class qoe extends Jb{constructor(t,n,r,o,i,a){super(t,n,a),this._isFocused=!1,this._onKeyDown=l=>{const u=l.keyCode,d=l.shiftKey;if(u!==Ht.Tab)return;const h=this._tabster.focusedElement.getFocusedElement(),p=this.getElement();let m=d?"findPrev":"findNext",v;h&&(p!=null&&p.contains(h))&&(v=this._tabster.focusable[m]({container:this.getElement(),currentElement:h})),!v&&this._props.isTrapped&&(m=d?"findLast":"findFirst",v=this._tabster.focusable[m]({container:this.getElement()})),v?(l.preventDefault(),l.stopImmediatePropagation(),np(v)):this._props.isOthersAccessible||this._moveOutWithDefault(d)},this.internalId="ml"+ ++Uoe,this.userId=a.id,this._onDispose=r,this._moveOutWithDefault=o,this._onActiveChange=i,t.controlTab||n.addEventListener("keydown",this._onKeyDown);const s=n.parentElement;s?this._modalizerParent=new os(t.getWindow,s):this._modalizerParent=null,this._setAccessibilityProps()}setProps(t){t.id&&(this.userId=t.id),this._props={...t},this._setAccessibilityProps()}dispose(){this._onDispose(this),this._remove()}setActive(t){var n,r,o;if(t===this._isActive)return;this._isActive=t,this._onActiveChange(t);let i=((n=this._element.get())===null||n===void 0?void 0:n.ownerDocument)||((o=(r=this._modalizerParent)===null||r===void 0?void 0:r.get())===null||o===void 0?void 0:o.ownerDocument);i||(i=this._tabster.getWindow().document);const a=i.body,s=Xb(i,a,l=>{var u;if(this._props.isOthersAccessible)return NodeFilter.FILTER_REJECT;const d=this._element.get(),h=(u=this._modalizerParent)===null||u===void 0?void 0:u.get(),p=d===l,m=!!l.contains(d||null),v=!!l.contains(h||null);if(p)return NodeFilter.FILTER_REJECT;if(m||v)return NodeFilter.FILTER_SKIP;Toe(this._tabster,l,"aria-hidden",t?"true":void 0);const _=d===(d==null?void 0:d.ownerDocument.body)?!1:d==null?void 0:d.ownerDocument.body.contains(d);return!(h===(h==null?void 0:h.ownerDocument.body)?!1:h==null?void 0:h.ownerDocument.body.contains(h))&&!_?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_REJECT});if(s)for(;s.nextNode(););}isActive(){return!!this._isActive}contains(t){var n;return!!(!((n=this.getElement())===null||n===void 0)&&n.contains(t))}onBeforeFocusOut(){const t=this.getElement();return t?!Wd(t,mO,{eventName:"beforefocusout"}):!1}_remove(){}_setAccessibilityProps(){}}class $oe extends es{constructor(t,n,r){super(n,r,PT.Modalizer),this._onFocusDummyInput=o=>{const i=this._modalizerAPI.activeModalizer;if(!i||o.shouldMoveOut)return;const a=o.isFirst?"findFirst":"findLast",s=this._tabster.focusable[a]({container:i.getElement()});s&&this._tabster.focusedElement.focus(s)},this._modalizerAPI=t,this._tabster=n,this.setTabbable(!1),this._setHandlers(this._onFocusDummyInput)}}class Woe{constructor(t){if(this._init=()=>{this._initTimer=void 0,this._tabster.focusedElement.subscribe(this._onFocus)},this._onModalizerDispose=n=>{n.setActive(!1),this.activeModalizer===n&&(this.activeModalizer=void 0),delete this._modalizers[n.userId]},this._onFocus=(n,r)=>{var o,i,a;const s=n&&Io.getTabsterContext(this._tabster,n);if(!s||!n)return;this._focusOutTimer&&(this._win().clearTimeout(this._focusOutTimer),this._focusOutTimer=void 0);const l=s==null?void 0:s.modalizer;if(l!==this.activeModalizer){if(r.isFocusedProgrammatically&&!(!((o=this.activeModalizer)===null||o===void 0)&&o.contains(n)))(i=this.activeModalizer)===null||i===void 0||i.setActive(!1),this.activeModalizer=void 0,l&&(this.activeModalizer=l,this.activeModalizer.setActive(!0));else if(!(!((a=this.activeModalizer)===null||a===void 0)&&a.getProps().isOthersAccessible)){const u=this._win();u.clearTimeout(this._restoreModalizerFocusTimer),this._restoreModalizerFocusTimer=u.setTimeout(()=>this._restoreModalizerFocus(n),100)}}},this._tabster=t,this._win=t.getWindow,this._initTimer=this._win().setTimeout(this._init,0),this._modalizers={},!t.controlTab){const n=this._win().document.body;this._dummyManager=new $oe(this,t,new os(this._win,n))}}dispose(){var t;const n=this._win();(t=this._dummyManager)===null||t===void 0||t.dispose(),this._initTimer&&(n.clearTimeout(this._initTimer),this._initTimer=void 0),n.clearTimeout(this._restoreModalizerFocusTimer),n.clearTimeout(this._focusOutTimer),Object.keys(this._modalizers).forEach(r=>{this._modalizers[r]&&(this._modalizers[r].dispose(),delete this._modalizers[r])}),this._tabster.focusedElement.unsubscribe(this._onFocus),delete this.activeModalizer}createModalizer(t,n){var r,o,i,a,s;const l=new qoe(this._tabster,t,this._onModalizerDispose,(o=(r=this._dummyManager)===null||r===void 0?void 0:r.moveOutWithDefaultAction)!==null&&o!==void 0?o:()=>null,(a=(i=this._dummyManager)===null||i===void 0?void 0:i.setTabbable)!==null&&a!==void 0?a:()=>null,n);if(this._modalizers[n.id]=l,t.contains((s=this._tabster.focusedElement.getFocusedElement())!==null&&s!==void 0?s:null)){const u=this.activeModalizer;u&&u.setActive(!1),this.activeModalizer=l,this.activeModalizer.setActive(!0)}return l}focus(t,n,r){const o=Io.getTabsterContext(this._tabster,t);if(o&&o.modalizer){this.activeModalizer=o.modalizer,this.activeModalizer.setActive(!0);const i=this.activeModalizer.getProps(),a=this.activeModalizer.getElement();if(a){if(n===void 0&&(n=i.isNoFocusFirst),!n&&this._tabster.keyboardNavigation.isNavigatingWithKeyboard()&&this._tabster.focusedElement.focusFirst({container:a})||(r===void 0&&(r=i.isNoFocusDefault),!r&&this._tabster.focusedElement.focusDefault(a)))return!0;this._tabster.focusedElement.resetFocus(a)}}return!1}updateModalizer(t,n){n&&(t.isActive()&&t.setActive(!1),delete this._modalizers[t.userId],this.activeModalizer===t&&(this.activeModalizer=void 0))}_restoreModalizerFocus(t){if(!(t!=null&&t.ownerDocument)||!this.activeModalizer)return;let n=this._tabster.focusable.findFirst({container:this.activeModalizer.getElement()});if(n){if(t.compareDocumentPosition(n)&document.DOCUMENT_POSITION_PRECEDING&&(n=this._tabster.focusable.findLast({container:t.ownerDocument.body}),!n))throw new Error("Something went wrong.");this._tabster.focusedElement.focus(n)}else t.blur()}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */const Goe=["input","textarea","*[contenteditable]"].join(", ");class Koe extends es{constructor(t,n,r){super(n,t,PT.Mover),this._onFocusDummyInput=o=>{var i,a;const s=this._element.get(),l=o.input;if(s&&!o.shouldMoveOut&&l){const u=Io.getTabsterContext(this._tabster,s);let d;u&&(d=(i=ar.findNextTabbable(this._tabster,u,void 0,l,!o.isFirst))===null||i===void 0?void 0:i.element);const h=(a=this._getMemorized())===null||a===void 0?void 0:a.get();h&&(d=h),d&&np(d)}},this._tabster=n,this._getMemorized=r,this._setHandlers(this._onFocusDummyInput)}}const Y2=1,qC=2,$C=3;class Voe extends Jb{constructor(t,n,r,o){super(t,n,o),this._visible={},this._onIntersection=a=>{for(const s of a){const l=s.target,u=Hh(this._win,l);let d,h=this._fullyVisible;if(s.intersectionRatio>=.25&&(d=s.intersectionRatio>=.75?Ul.Visible:Ul.PartiallyVisible,d===Ul.Visible&&(h=u)),this._visible[u]!==d){d===void 0?(delete this._visible[u],h===u&&delete this._fullyVisible):(this._visible[u]=d,this._fullyVisible=h);const p=this.getState(l);p&&Wd(l,T_,p)}}},this._win=t.getWindow,(this._props.trackState||this._props.visibilityAware)&&(this._intersectionObserver=new IntersectionObserver(this._onIntersection,{threshold:[0,.25,.5,.75,1]}),this._observeState()),this._onDispose=r;const i=()=>o.memorizeCurrent?this._current:void 0;t.controlTab||(this.dummyManager=new Koe(this._element,t,i))}dispose(){var t;this._onDispose(this),this._intersectionObserver&&(this._intersectionObserver.disconnect(),delete this._intersectionObserver),delete this._current,delete this._fullyVisible,delete this._allElements,delete this._updateQueue,this._unobserve&&(this._unobserve(),delete this._unobserve);const n=this._win();this._setCurrentTimer&&(n.clearTimeout(this._setCurrentTimer),delete this._setCurrentTimer),this._updateTimer&&(n.clearTimeout(this._updateTimer),delete this._updateTimer),(t=this.dummyManager)===null||t===void 0||t.dispose()}setCurrent(t){t?this._current=new os(this._win,t):this._current=void 0,(this._props.trackState||this._props.visibilityAware)&&!this._setCurrentTimer&&(this._setCurrentTimer=this._win().setTimeout(()=>{var n;delete this._setCurrentTimer;const r=[];this._current!==this._prevCurrent&&(r.push(this._current),r.push(this._prevCurrent),this._prevCurrent=this._current);for(const o of r){const i=o==null?void 0:o.get();if(i&&((n=this._allElements)===null||n===void 0?void 0:n.get(i))===this){const a=this._props;if(i&&(a.visibilityAware!==void 0||a.trackState)){const s=this.getState(i);s&&Wd(i,T_,s)}}}}))}getCurrent(){var t;return((t=this._current)===null||t===void 0?void 0:t.get())||null}findNextTabbable(t,n){var r;const o=this.getElement(),i=o&&((r=t==null?void 0:t.__tabsterDummyContainer)===null||r===void 0?void 0:r.get())===o;if(!o)return null;const s=this._tabster.focusable;let l=null,u;const d=h=>{u=h};return(this._props.tabbable||i||t&&!o.contains(t))&&(l=n?s.findPrev({currentElement:t,container:o,onUncontrolled:d}):s.findNext({currentElement:t,container:o,onUncontrolled:d})),{element:l,uncontrolled:u,lastMoverOrGroupper:l||u?void 0:this}}acceptElement(t,n){var r,o,i;if(!ar.isTabbing)return!((r=n.currentCtx)===null||r===void 0)&&r.isExcludedFromMover?NodeFilter.FILTER_REJECT:void 0;const{memorizeCurrent:a,visibilityAware:s}=this._props,l=this.getElement();if(l&&(a||s)&&(!l.contains(n.from)||((o=n.from.__tabsterDummyContainer)===null||o===void 0?void 0:o.get())===l)){if(a){const u=(i=this._current)===null||i===void 0?void 0:i.get();if(u&&n.acceptCondition(u))return n.found=!0,n.foundElement=u,n.lastToIgnore=l,NodeFilter.FILTER_ACCEPT}if(s){const u=this._tabster.focusable.findElement({container:l,ignoreUncontrolled:!0,isBackward:n.isBackward,acceptCondition:d=>{var h;const p=Hh(this._win,d),m=this._visible[p];return l!==d&&!!(!((h=this._allElements)===null||h===void 0)&&h.get(d))&&n.acceptCondition(d)&&(m===Ul.Visible||m===Ul.PartiallyVisible&&(s===Ul.PartiallyVisible||!this._fullyVisible))}});if(u)return n.found=!0,n.foundElement=u,n.lastToIgnore=l,NodeFilter.FILTER_ACCEPT}}}_observeState(){const t=this.getElement();if(this._unobserve||!t||typeof MutationObserver>"u")return;const n=this._win(),r=this._allElements=new WeakMap,o=this._tabster.focusable;let i=this._updateQueue=[];const a=new MutationObserver(m=>{for(const v of m){const _=v.target,b=v.removedNodes,E=v.addedNodes;if(v.type==="attributes")v.attributeName==="tabindex"&&i.push({element:_,type:qC});else{for(let w=0;w<b.length;w++)i.push({element:b[w],type:$C});for(let w=0;w<E.length;w++)i.push({element:E[w],type:Y2})}}h()}),s=(m,v)=>{var _,b;const E=r.get(m);E&&v&&((_=this._intersectionObserver)===null||_===void 0||_.unobserve(m),r.delete(m)),!E&&!v&&(r.set(m,this),(b=this._intersectionObserver)===null||b===void 0||b.observe(m))},l=m=>{const v=o.isFocusable(m);r.get(m)?v||s(m,!0):v&&s(m)},u=m=>{const{mover:v}=p(m);if(v&&v!==this)if(v.getElement()===m&&o.isFocusable(m))s(m);else return;const _=Xb(n.document,m,b=>{const{mover:E,groupper:w}=p(b);if(E&&E!==this)return NodeFilter.FILTER_REJECT;const k=w==null?void 0:w.getFirst(!0);return w&&w.getElement()!==b&&k&&k!==b?NodeFilter.FILTER_REJECT:(o.isFocusable(b)&&s(b),NodeFilter.FILTER_SKIP)});if(_)for(_.currentNode=m;_.nextNode(););},d=m=>{r.get(m)&&s(m,!0);for(let _=m.firstElementChild;_;_=_.nextElementSibling)d(_)},h=()=>{!this._updateTimer&&i.length&&(this._updateTimer=n.setTimeout(()=>{delete this._updateTimer;for(const{element:m,type:v}of i)switch(v){case qC:l(m);break;case Y2:u(m);break;case $C:d(m);break}i=this._updateQueue=[]},0))},p=m=>{const v={};for(let _=m;_;_=_.parentElement){const b=Au(this._tabster,_);if(b&&(b.groupper&&!v.groupper&&(v.groupper=b.groupper),b.mover)){v.mover=b.mover;break}}return v};i.push({element:t,type:Y2}),h(),a.observe(t,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["tabindex"]}),this._unobserve=()=>{a.disconnect()}}getState(t){const n=Hh(this._win,t);if(n in this._visible){const r=this._visible[n]||Ul.Invisible;return{isCurrent:this._current?this._current.get()===t:void 0,visibility:r}}}}function Yoe(e,t,n,r,o,i,a,s){const l=n<o?o-n:a<e?e-a:0,u=r<i?i-r:s<t?t-s:0;return l===0?u:u===0?l:Math.sqrt(l*l+u*u)}class Qoe{constructor(t,n){this._init=()=>{this._initTimer=void 0,this._win().addEventListener("keydown",this._onKeyDown,!0)},this._onMoverDispose=r=>{delete this._movers[r.id]},this._onFocus=r=>{var o;for(let i=r;i;i=i.parentElement){const a=(o=Au(this._tabster,i))===null||o===void 0?void 0:o.mover;if(a){a.setCurrent(r);break}}},this._onKeyDown=async r=>{var o;this._ignoredInputTimer&&(this._win().clearTimeout(this._ignoredInputTimer),delete this._ignoredInputTimer),(o=this._ignoredInputResolve)===null||o===void 0||o.call(this,!1);let i=r.keyCode;switch(i){case Ht.Down:case Ht.Right:case Ht.Up:case Ht.Left:case Ht.PageDown:case Ht.PageUp:case Ht.Home:case Ht.End:break;default:return}const a=this._tabster,s=a.focusedElement.getFocusedElement();if(!s||await this._isIgnoredInput(s,i))return;const l=Io.getTabsterContext(a,s,{checkRtl:!0});if(!l||!l.mover||l.isExcludedFromMover||l.isGroupperFirst&&l.groupper&&l.groupper.isActive(!0))return;const u=l.mover,d=u.getElement();if(!d)return;const h=a.focusable,p=u.getProps(),m=p.direction||Gf.Both,v=m===Gf.Both,_=v||m===Gf.Vertical,b=v||m===Gf.Horizontal,E=m===Gf.Grid,w=p.cyclic;let k,y,F=0,C=0;if(E&&(y=s.getBoundingClientRect(),F=Math.ceil(y.left),C=Math.floor(y.right)),!(p.disableHomeEndKeys&&(i===Ht.Home||i===Ht.End))){if(l.isRtl&&(i===Ht.Right?i=Ht.Left:i===Ht.Left&&(i=Ht.Right)),i===Ht.Down&&_||i===Ht.Right&&(b||E))if(k=h.findNext({currentElement:s,container:d}),k&&E){const A=Math.ceil(k.getBoundingClientRect().left);C>A&&(k=void 0)}else!k&&w&&(k=h.findFirst({container:d}));else if(i===Ht.Up&&_||i===Ht.Left&&(b||E))k=h.findPrev({currentElement:s,container:d}),k&&E?Math.floor(k.getBoundingClientRect().right)>F&&(k=void 0):!k&&w&&(k=h.findLast({container:d}));else if(i===Ht.Home)k=h.findFirst({container:d});else if(i===Ht.End)k=h.findLast({container:d});else if(i===Ht.PageUp){let A=h.findPrev({currentElement:s,container:d}),P=null;for(;A;)P=A,A=DC(this._win,A)?h.findPrev({currentElement:A,container:d}):null;k=P,k&&PC(this._win,k,!1)}else if(i===Ht.PageDown){let A=h.findNext({currentElement:s,container:d}),P=null;for(;A;)P=A,A=DC(this._win,A)?h.findNext({currentElement:A,container:d}):null;k=P,k&&PC(this._win,k,!0)}else if(E){const A=i===Ht.Up,P=F,I=Math.ceil(y.top),j=C,H=Math.floor(y.bottom);let K,U,pe=0;h.findAll({container:d,currentElement:s,isBackward:A,onElement:se=>{const J=se.getBoundingClientRect(),$=Math.ceil(J.left),_e=Math.ceil(J.top),ve=Math.floor(J.right),fe=Math.floor(J.bottom);if(A&&I<fe||!A&&H>_e)return!0;const R=Math.ceil(Math.min(j,ve))-Math.floor(Math.max(P,$)),L=Math.ceil(Math.min(j-P,ve-$));if(R>0&&L>=R){const Ae=R/L;Ae>pe&&(K=se,pe=Ae)}else if(pe===0){const Ae=Yoe(P,I,j,H,$,_e,ve,fe);(U===void 0||Ae<U)&&(U=Ae,K=se)}else if(pe>0)return!1;return!0}}),k=K}k&&(r.preventDefault(),r.stopImmediatePropagation(),np(k))}},this._tabster=t,this._win=n,this._initTimer=n().setTimeout(this._init,0),this._movers={},t.focusedElement.subscribe(this._onFocus)}dispose(){var t;const n=this._win();this._tabster.focusedElement.unsubscribe(this._onFocus),this._initTimer&&(n.clearTimeout(this._initTimer),delete this._initTimer),(t=this._ignoredInputResolve)===null||t===void 0||t.call(this,!1),this._ignoredInputTimer&&(n.clearTimeout(this._ignoredInputTimer),delete this._ignoredInputTimer),n.removeEventListener("keydown",this._onKeyDown,!0),Object.keys(this._movers).forEach(r=>{this._movers[r]&&(this._movers[r].dispose(),delete this._movers[r])})}createMover(t,n){const r=new Voe(this._tabster,t,this._onMoverDispose,n);return this._movers[r.id]=r,r}async _isIgnoredInput(t,n){var r;if(t.getAttribute("aria-expanded")==="true")return!0;if(TO(t,Goe)){let o=0,i=0,a=0,s;if(t.tagName==="INPUT"||t.tagName==="TEXTAREA"){const l=t.type;if(a=(t.value||"").length,l==="email"||l==="number"){if(a){const d=(r=t.ownerDocument.defaultView)===null||r===void 0?void 0:r.getSelection();if(d){const h=d.toString().length,p=n===Ht.Left||n===Ht.Up;if(d.modify("extend",p?"backward":"forward","character"),h!==d.toString().length)return d.modify("extend",p?"forward":"backward","character"),!0;a=0}}}else{const d=t.selectionStart;if(d===null)return l==="hidden";o=d||0,i=t.selectionEnd||0}}else t.contentEditable==="true"&&(s=new(wO(this._win))(l=>{this._ignoredInputResolve=v=>{delete this._ignoredInputResolve,l(v)};const u=this._win();this._ignoredInputTimer&&u.clearTimeout(this._ignoredInputTimer);const{anchorNode:d,focusNode:h,anchorOffset:p,focusOffset:m}=u.getSelection()||{};this._ignoredInputTimer=u.setTimeout(()=>{var v,_,b;delete this._ignoredInputTimer;const{anchorNode:E,focusNode:w,anchorOffset:k,focusOffset:y}=u.getSelection()||{};if(E!==d||w!==h||k!==p||y!==m){(v=this._ignoredInputResolve)===null||v===void 0||v.call(this,!1);return}if(o=k||0,i=y||0,a=((_=t.textContent)===null||_===void 0?void 0:_.length)||0,E&&w&&t.contains(E)&&t.contains(w)&&E!==t){let F=!1;const C=A=>{if(A===E)F=!0;else if(A===w)return!0;const P=A.textContent;if(P&&!A.firstChild){const j=P.length;F?w!==E&&(i+=j):(o+=j,i+=j)}let I=!1;for(let j=A.firstChild;j&&!I;j=j.nextSibling)I=C(j);return I};C(t)}(b=this._ignoredInputResolve)===null||b===void 0||b.call(this,!0)},0)}));if(s&&!await s||o!==i||o>0&&(n===Ht.Left||n===Ht.Up||n===Ht.Home)||o<a&&(n===Ht.Right||n===Ht.Down||n===Ht.End))return!0}return!1}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */function Xoe(e,t,n,r){if(typeof MutationObserver>"u")return()=>{};const o=t.getWindow;let i;const a=d=>{for(const h of d){const p=h.target,m=h.removedNodes,v=h.addedNodes;if(h.type==="attributes")h.attributeName===xd&&n(t,p);else{for(let _=0;_<m.length;_++)s(m[_],!0);for(let _=0;_<v.length;_++)s(v[_])}}};function s(d,h){i||(i=bl(o).elementByUId),l(d,h);const p=Xb(e,d,m=>l(m,h));if(p)for(;p.nextNode(););}function l(d,h){var p;if(!d.getAttribute)return NodeFilter.FILTER_SKIP;const m=d.__tabsterElementUID;return m&&i&&(h?delete i[m]:(p=i[m])!==null&&p!==void 0||(i[m]=new os(o,d))),(Au(t,d)||d.hasAttribute(xd))&&n(t,d,h),NodeFilter.FILTER_SKIP}const u=new MutationObserver(a);return r&&s(o().document.body),u.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:[xd]}),()=>{u.disconnect()}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */class Zoe{constructor(){}}/*! * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */class Joe{constructor(t){this.keyboardNavigation=t.keyboardNavigation,this.focusedElement=t.focusedElement,this.focusable=t.focusable,this.root=t.root,this.uncontrolled=t.uncontrolled,this.core=t}}class eie{constructor(t,n){var r;this._forgetMemorizedElements=[],this._wrappers=new Set,this._version="3.0.8",this._noop=!1,this.getWindow=()=>{if(!this._win)throw new Error("Using disposed Tabster.");return this._win},this._storage=xoe(t),this._win=t;const o=this.getWindow;this.keyboardNavigation=new Hoe(o),this.focusedElement=new ar(this,o),this.focusable=new zoe(this,o),this.root=new Io(this,n==null?void 0:n.autoRoot),this.uncontrolled=new Zoe,this.controlTab=(r=n==null?void 0:n.controlTab)!==null&&r!==void 0?r:!0,this.rootDummyInputs=!!(n!=null&&n.rootDummyInputs),this.internal={stopObserver:()=>{this._unobserve&&(this._unobserve(),delete this._unobserve)},resumeObserver:i=>{if(!this._unobserve){const a=o().document;this._unobserve=Xoe(a,this,_oe,i)}}},this.internal.resumeObserver(!1),bO(o)}createTabster(t){const n=new Joe(this);return t||this._wrappers.add(n),n}disposeTabster(t,n){n?this._wrappers.clear():this._wrappers.delete(t),this._wrappers.size===0&&this.dispose()}dispose(){var t,n,r,o,i,a,s;this.internal.stopObserver();const l=this._win;this._forgetMemorizedElements=[],l&&this._forgetMemorizedTimer&&(l.clearTimeout(this._forgetMemorizedTimer),delete this._forgetMemorizedTimer),(t=this.outline)===null||t===void 0||t.dispose(),(n=this.crossOrigin)===null||n===void 0||n.dispose(),(r=this.deloser)===null||r===void 0||r.dispose(),(o=this.groupper)===null||o===void 0||o.dispose(),(i=this.mover)===null||i===void 0||i.dispose(),(a=this.modalizer)===null||a===void 0||a.dispose(),(s=this.observedElement)===null||s===void 0||s.dispose(),this.keyboardNavigation.dispose(),this.focusable.dispose(),this.focusedElement.dispose(),this.root.dispose(),Coe(this.getWindow),MC(this.getWindow),this._storage=new WeakMap,this._wrappers.clear(),l&&(Soe(l),delete l.__tabsterInstance,delete this._win)}storageEntry(t,n){const r=this._storage;let o=r.get(t);return o?n===!1&&Object.keys(o).length===0&&r.delete(t):n===!0&&(o={},r.set(t,o)),o}forceCleanup(){this._win&&(this._forgetMemorizedElements.push(this._win.document.body),!this._forgetMemorizedTimer&&(this._forgetMemorizedTimer=this._win.setTimeout(()=>{delete this._forgetMemorizedTimer;for(let t=this._forgetMemorizedElements.shift();t;t=this._forgetMemorizedElements.shift())MC(this.getWindow,t),ar.forgetMemorized(this.focusedElement,t)},0),vO(this.getWindow,!0)))}}function tie(e,t){let n=sie(e);return n||(n=new eie(e,t),e.__tabsterInstance=n),n.createTabster()}function nie(e){const t=e.core;return t.mover||(t.mover=new Qoe(t,t.getWindow)),t.mover}function rie(e,t){const n=e.core;return n.deloser||(n.deloser=new SO(n,t)),n.deloser}function oie(e){const t=e.core;return t.modalizer||(t.modalizer=new Woe(t)),t.modalizer}function iie(e,t){e.core.disposeTabster(e,t)}function aie(e,t){const n=JSON.stringify(e);return t===!0?n:{[xd]:n}}function sie(e){return e.__tabsterInstance}const ey=()=>{const{targetDocument:e}=Oo(),t=(e==null?void 0:e.defaultView)||void 0,n=T.useMemo(()=>t?tie(t,{autoRoot:{},controlTab:!1}):null,[t]);return us(()=>()=>{n&&iie(n)},[n]),n},S_=e=>(ey(),aie(e)),lie=(e={})=>{const{circular:t,axis:n,memorizeCurrent:r,tabbable:o,ignoreDefaultKeydown:i}=e,a=ey();return a&&nie(a),S_({mover:{cyclic:!!t,direction:uie(n??"vertical"),memorizeCurrent:r,tabbable:o},...i&&{focusable:{ignoreKeydown:i}}})};function uie(e){switch(e){case"horizontal":return Hm.MoverDirections.Horizontal;case"grid":return Hm.MoverDirections.Grid;case"both":return Hm.MoverDirections.Both;case"vertical":default:return Hm.MoverDirections.Vertical}}const op=()=>{const e=ey(),t=T.useCallback((a,s)=>(e==null?void 0:e.focusable.findAll({container:a,acceptCondition:s}))||[],[e]),n=T.useCallback(a=>e==null?void 0:e.focusable.findFirst({container:a}),[e]),r=T.useCallback(a=>e==null?void 0:e.focusable.findLast({container:a}),[e]),o=T.useCallback((a,s={})=>e==null?void 0:e.focusable.findNext({currentElement:a,...s}),[e]),i=T.useCallback((a,s={})=>e==null?void 0:e.focusable.findPrev({currentElement:a,...s}),[e]);return{findAllFocusable:t,findFirstFocusable:n,findLastFocusable:r,findNextFocusable:o,findPrevFocusable:i}},CO="data-fui-focus-visible",AO="data-fui-focus-within";function cie(e,t){if(NO(e))return()=>{};const n={current:void 0},r=Yb(t);r.subscribe(a=>{!a&&n.current&&(Q2(n.current),n.current=void 0)});const o=a=>{n.current&&(Q2(n.current),n.current=void 0),r.isNavigatingWithKeyboard()&&WC(a.target)&&a.target&&(n.current=a.target,fie(n.current))},i=a=>{(!a.relatedTarget||WC(a.relatedTarget)&&!e.contains(a.relatedTarget))&&n.current&&(Q2(n.current),n.current=void 0)};return e.addEventListener(wa,o),e.addEventListener("focusout",i),e.focusVisible=!0,()=>{e.removeEventListener(wa,o),e.removeEventListener("focusout",i),delete e.focusVisible,Qb(r)}}function fie(e){e.setAttribute(CO,"")}function Q2(e){e.removeAttribute(CO)}function WC(e){return e?!!(e&&typeof e=="object"&&"classList"in e&&"contains"in e):!1}function NO(e){return e?e.focusVisible?!0:NO(e==null?void 0:e.parentElement):!1}function FO(){const{targetDocument:e}=Oo(),t=T.useRef(null);return T.useEffect(()=>{if(e!=null&&e.defaultView&&t.current)return cie(t.current,e.defaultView)},[t,e]),t}function die(e,t){const n=Yb(t);n.subscribe(i=>{i||GC(e)});const r=i=>{n.isNavigatingWithKeyboard()&&KC(i.target)&&hie(e)},o=i=>{(!i.relatedTarget||KC(i.relatedTarget)&&!e.contains(i.relatedTarget))&&GC(e)};return e.addEventListener(wa,r),e.addEventListener("focusout",o),()=>{e.removeEventListener(wa,r),e.removeEventListener("focusout",o),Qb(n)}}function hie(e){e.setAttribute(AO,"")}function GC(e){e.removeAttribute(AO)}function KC(e){return e?!!(e&&typeof e=="object"&&"classList"in e&&"contains"in e):!1}function pie(){const{targetDocument:e}=Oo(),t=T.useRef(null);return T.useEffect(()=>{if(e!=null&&e.defaultView&&t.current)return die(t.current,e.defaultView)},[t,e]),t}const ty=(e={})=>{const{trapFocus:t,alwaysFocusable:n,legacyTrapFocus:r}=e,o=ey();o&&(oie(o),rie(o));const i=lo("modal-",e.id),a=S_({deloser:{},modalizer:{id:i,isOthersAccessible:!t,isAlwaysAccessible:n,isTrapped:r}}),s=S_({deloser:{}});return{modalAttributes:a,triggerAttributes:s}},we={0:"#000000",2:"#050505",4:"#0a0a0a",6:"#0f0f0f",8:"#141414",10:"#1a1a1a",12:"#1f1f1f",14:"#242424",16:"#292929",18:"#2e2e2e",20:"#333333",22:"#383838",24:"#3d3d3d",26:"#424242",28:"#474747",30:"#4d4d4d",32:"#525252",34:"#575757",36:"#5c5c5c",38:"#616161",40:"#666666",42:"#6b6b6b",44:"#707070",46:"#757575",48:"#7a7a7a",50:"#808080",52:"#858585",54:"#8a8a8a",56:"#8f8f8f",58:"#949494",60:"#999999",62:"#9e9e9e",64:"#a3a3a3",66:"#a8a8a8",68:"#adadad",70:"#b3b3b3",72:"#b8b8b8",74:"#bdbdbd",76:"#c2c2c2",78:"#c7c7c7",80:"#cccccc",82:"#d1d1d1",84:"#d6d6d6",86:"#dbdbdb",88:"#e0e0e0",90:"#e6e6e6",92:"#ebebeb",94:"#f0f0f0",96:"#f5f5f5",98:"#fafafa",100:"#ffffff"},ya={5:"rgba(255, 255, 255, 0.05)",10:"rgba(255, 255, 255, 0.1)",20:"rgba(255, 255, 255, 0.2)",30:"rgba(255, 255, 255, 0.3)",40:"rgba(255, 255, 255, 0.4)",50:"rgba(255, 255, 255, 0.5)",60:"rgba(255, 255, 255, 0.6)",70:"rgba(255, 255, 255, 0.7)",80:"rgba(255, 255, 255, 0.8)",90:"rgba(255, 255, 255, 0.9)"},ba={5:"rgba(0, 0, 0, 0.05)",10:"rgba(0, 0, 0, 0.1)",20:"rgba(0, 0, 0, 0.2)",30:"rgba(0, 0, 0, 0.3)",40:"rgba(0, 0, 0, 0.4)",50:"rgba(0, 0, 0, 0.5)",60:"rgba(0, 0, 0, 0.6)",70:"rgba(0, 0, 0, 0.7)",80:"rgba(0, 0, 0, 0.8)",90:"rgba(0, 0, 0, 0.9)"},VC={5:"rgba(36, 36, 36, 0.05)",10:"rgba(36, 36, 36, 0.1)",20:"rgba(36, 36, 36, 0.2)",30:"rgba(36, 36, 36, 0.3)",40:"rgba(36, 36, 36, 0.4)",50:"rgba(36, 36, 36, 0.5)",60:"rgba(36, 36, 36, 0.6)",70:"rgba(36, 36, 36, 0.7)",80:"rgba(36, 36, 36, 0.8)",90:"rgba(36, 36, 36, 0.9)"},ht="#ffffff",x_="#000000",mie={shade50:"#130204",shade40:"#230308",shade30:"#420610",shade20:"#590815",shade10:"#690a19",primary:"#750b1c",tint10:"#861b2c",tint20:"#962f3f",tint30:"#ac4f5e",tint40:"#d69ca5",tint50:"#e9c7cd",tint60:"#f9f0f2"},gie={shade50:"#200205",shade40:"#3b0509",shade30:"#6e0811",shade20:"#960b18",shade10:"#b10e1c",primary:"#c50f1f",tint10:"#cc2635",tint20:"#d33f4c",tint30:"#dc626d",tint40:"#eeacb2",tint50:"#f6d1d5",tint60:"#fdf3f4"},vie={shade50:"#210809",shade40:"#3f1011",shade30:"#751d1f",shade20:"#9f282b",shade10:"#bc2f32",primary:"#d13438",tint10:"#d7494c",tint20:"#dc5e62",tint30:"#e37d80",tint40:"#f1bbbc",tint50:"#f8dadb",tint60:"#fdf6f6"},bie={shade50:"#230900",shade40:"#411200",shade30:"#7a2101",shade20:"#a62d01",shade10:"#c43501",primary:"#da3b01",tint10:"#de501c",tint20:"#e36537",tint30:"#e9835e",tint40:"#f4bfab",tint50:"#f9dcd1",tint60:"#fdf6f3"},yie={shade50:"#200d03",shade40:"#3d1805",shade30:"#712d09",shade20:"#9a3d0c",shade10:"#b6480e",primary:"#ca5010",tint10:"#d06228",tint20:"#d77440",tint30:"#df8e64",tint40:"#efc4ad",tint50:"#f7dfd2",tint60:"#fdf7f4"},Eie={shade50:"#291600",shade40:"#4d2a00",shade30:"#8f4e00",shade20:"#c26a00",shade10:"#e67e00",primary:"#ff8c00",tint10:"#ff9a1f",tint20:"#ffa83d",tint30:"#ffba66",tint40:"#ffddb3",tint50:"#ffedd6",tint60:"#fffaf5"},_ie={shade50:"#251a00",shade40:"#463100",shade30:"#835b00",shade20:"#b27c00",shade10:"#d39300",primary:"#eaa300",tint10:"#edad1c",tint20:"#efb839",tint30:"#f2c661",tint40:"#f9e2ae",tint50:"#fcefd3",tint60:"#fefbf4"},Tie={primary:"#fde300",shade10:"#e4cc00",shade20:"#c0ad00",shade30:"#817400",shade40:"#4c4400",shade50:"#282400",tint10:"#fde61e",tint20:"#fdea3d",tint30:"#feee66",tint40:"#fef7b2",tint50:"#fffad6",tint60:"#fffef5"},wie={shade50:"#1f1900",shade40:"#3a2f00",shade30:"#6c5700",shade20:"#937700",shade10:"#ae8c00",primary:"#c19c00",tint10:"#c8a718",tint20:"#d0b232",tint30:"#dac157",tint40:"#ecdfa5",tint50:"#f5eece",tint60:"#fdfbf2"},kie={shade50:"#181202",shade40:"#2e2103",shade30:"#553e06",shade20:"#745408",shade10:"#89640a",primary:"#986f0b",tint10:"#a47d1e",tint20:"#b18c34",tint30:"#c1a256",tint40:"#e0cea2",tint50:"#efe4cb",tint60:"#fbf8f2"},Sie={shade50:"#170e07",shade40:"#2b1a0e",shade30:"#50301a",shade20:"#6c4123",shade10:"#804d29",primary:"#8e562e",tint10:"#9c663f",tint20:"#a97652",tint30:"#bb8f6f",tint40:"#ddc3b0",tint50:"#edded3",tint60:"#faf7f4"},xie={shade50:"#0c1501",shade40:"#162702",shade30:"#294903",shade20:"#376304",shade10:"#427505",primary:"#498205",tint10:"#599116",tint20:"#6ba02b",tint30:"#85b44c",tint40:"#bdd99b",tint50:"#dbebc7",tint60:"#f6faf0"},Cie={shade50:"#002111",shade40:"#003d20",shade30:"#00723b",shade20:"#009b51",shade10:"#00b85f",primary:"#00cc6a",tint10:"#19d279",tint20:"#34d889",tint30:"#5ae0a0",tint40:"#a8f0cd",tint50:"#cff7e4",tint60:"#f3fdf8"},Aie={shade50:"#031a02",shade40:"#063004",shade30:"#0b5a08",shade20:"#0e7a0b",shade10:"#11910d",primary:"#13a10e",tint10:"#27ac22",tint20:"#3db838",tint30:"#5ec75a",tint40:"#a7e3a5",tint50:"#cef0cd",tint60:"#f2fbf2"},Nie={shade50:"#031403",shade40:"#052505",shade30:"#094509",shade20:"#0c5e0c",shade10:"#0e700e",primary:"#107c10",tint10:"#218c21",tint20:"#359b35",tint30:"#54b054",tint40:"#9fd89f",tint50:"#c9eac9",tint60:"#f1faf1"},Fie={shade50:"#021102",shade40:"#032003",shade30:"#063b06",shade20:"#085108",shade10:"#0a5f0a",primary:"#0b6a0b",tint10:"#1a7c1a",tint20:"#2d8e2d",tint30:"#4da64d",tint40:"#9ad29a",tint50:"#c6e7c6",tint60:"#f0f9f0"},Iie={shade50:"#001d1f",shade40:"#00373a",shade30:"#00666d",shade20:"#008b94",shade10:"#00a5af",primary:"#00b7c3",tint10:"#18bfca",tint20:"#32c8d1",tint30:"#58d3db",tint40:"#a6e9ed",tint50:"#cef3f5",tint60:"#f2fcfd"},Bie={shade50:"#001516",shade40:"#012728",shade30:"#02494c",shade20:"#026467",shade10:"#037679",primary:"#038387",tint10:"#159195",tint20:"#2aa0a4",tint30:"#4cb4b7",tint40:"#9bd9db",tint50:"#c7ebec",tint60:"#f0fafa"},Rie={shade50:"#000f12",shade40:"#001b22",shade30:"#00333f",shade20:"#004555",shade10:"#005265",primary:"#005b70",tint10:"#0f6c81",tint20:"#237d92",tint30:"#4496a9",tint40:"#94c8d4",tint50:"#c3e1e8",tint60:"#eff7f9"},Oie={shade50:"#001322",shade40:"#002440",shade30:"#004377",shade20:"#005ba1",shade10:"#006cbf",primary:"#0078d4",tint10:"#1a86d9",tint20:"#3595de",tint30:"#5caae5",tint40:"#a9d3f2",tint50:"#d0e7f8",tint60:"#f3f9fd"},Die={shade50:"#000c16",shade40:"#00172a",shade30:"#002c4e",shade20:"#003b6a",shade10:"#00467e",primary:"#004e8c",tint10:"#125e9a",tint20:"#286fa8",tint30:"#4a89ba",tint40:"#9abfdc",tint50:"#c7dced",tint60:"#f0f6fa"},Pie={shade50:"#0d1126",shade40:"#182047",shade30:"#2c3c85",shade20:"#3c51b4",shade10:"#4760d5",primary:"#4f6bed",tint10:"#637cef",tint20:"#778df1",tint30:"#93a4f4",tint40:"#c8d1fa",tint50:"#e1e6fc",tint60:"#f7f9fe"},Mie={shade50:"#00061d",shade40:"#000c36",shade30:"#001665",shade20:"#001e89",shade10:"#0023a2",primary:"#0027b4",tint10:"#173bbd",tint20:"#3050c6",tint30:"#546fd2",tint40:"#a3b2e8",tint50:"#ccd5f3",tint60:"#f2f4fc"},Lie={shade50:"#120f25",shade40:"#221d46",shade30:"#3f3682",shade20:"#5649b0",shade10:"#6656d1",primary:"#7160e8",tint10:"#8172eb",tint20:"#9184ee",tint30:"#a79cf1",tint40:"#d2ccf8",tint50:"#e7e4fb",tint60:"#f9f8fe"},jie={shade50:"#0f0717",shade40:"#1c0e2b",shade30:"#341a51",shade20:"#46236e",shade10:"#532982",primary:"#5c2e91",tint10:"#6b3f9e",tint20:"#7c52ab",tint30:"#9470bd",tint40:"#c6b1de",tint50:"#e0d3ed",tint60:"#f7f4fb"},zie={shade50:"#160418",shade40:"#29072e",shade30:"#4c0d55",shade20:"#671174",shade10:"#7a1589",primary:"#881798",tint10:"#952aa4",tint20:"#a33fb1",tint30:"#b55fc1",tint40:"#d9a7e0",tint50:"#eaceef",tint60:"#faf2fb"},Hie={shade50:"#1f091d",shade40:"#3a1136",shade30:"#6d2064",shade20:"#932b88",shade10:"#af33a1",primary:"#c239b3",tint10:"#c94cbc",tint20:"#d161c4",tint30:"#da7ed0",tint40:"#edbbe7",tint50:"#f5daf2",tint60:"#fdf5fc"},Uie={shade50:"#1c0b1f",shade40:"#35153a",shade30:"#63276d",shade20:"#863593",shade10:"#9f3faf",primary:"#b146c2",tint10:"#ba58c9",tint20:"#c36bd1",tint30:"#cf87da",tint40:"#e6bfed",tint50:"#f2dcf5",tint60:"#fcf6fd"},qie={shade50:"#24091b",shade40:"#441232",shade30:"#80215d",shade20:"#ad2d7e",shade10:"#cd3595",primary:"#e43ba6",tint10:"#e750b0",tint20:"#ea66ba",tint30:"#ef85c8",tint40:"#f7c0e3",tint50:"#fbddf0",tint60:"#fef6fb"},$ie={shade50:"#1f0013",shade40:"#390024",shade30:"#6b0043",shade20:"#91005a",shade10:"#ac006b",primary:"#bf0077",tint10:"#c71885",tint20:"#ce3293",tint30:"#d957a8",tint40:"#eca5d1",tint50:"#f5cee6",tint60:"#fcf2f9"},Wie={shade50:"#13000c",shade40:"#240017",shade30:"#43002b",shade20:"#5a003b",shade10:"#6b0045",primary:"#77004d",tint10:"#87105d",tint20:"#98246f",tint30:"#ad4589",tint40:"#d696c0",tint50:"#e9c4dc",tint60:"#faf0f6"},Gie={shade50:"#141313",shade40:"#252323",shade30:"#444241",shade20:"#5d5958",shade10:"#6e6968",primary:"#7a7574",tint10:"#8a8584",tint20:"#9a9594",tint30:"#afabaa",tint40:"#d7d4d4",tint50:"#eae8e8",tint60:"#faf9f9"},Kie={shade50:"#0f0e0e",shade40:"#1c1b1a",shade30:"#343231",shade20:"#474443",shade10:"#54514f",primary:"#5d5a58",tint10:"#706d6b",tint20:"#84817e",tint30:"#9e9b99",tint40:"#cecccb",tint50:"#e5e4e3",tint60:"#f8f8f8"},Vie={shade50:"#111314",shade40:"#1f2426",shade30:"#3b4447",shade20:"#505c60",shade10:"#5f6d71",primary:"#69797e",tint10:"#79898d",tint20:"#89989d",tint30:"#a0adb2",tint40:"#cdd6d8",tint50:"#e4e9ea",tint60:"#f8f9fa"},Yie={shade50:"#090a0b",shade40:"#111315",shade30:"#202427",shade20:"#2b3135",shade10:"#333a3f",primary:"#394146",tint10:"#4d565c",tint20:"#626c72",tint30:"#808a90",tint40:"#bcc3c7",tint50:"#dbdfe1",tint60:"#f6f7f8"},Xt={red:vie,green:Nie,darkOrange:bie,yellow:Tie,berry:Hie,lightGreen:Aie,marigold:_ie},yu={darkRed:mie,cranberry:gie,pumpkin:yie,peach:Eie,gold:wie,brass:kie,brown:Sie,forest:xie,seafoam:Cie,darkGreen:Fie,lightTeal:Iie,teal:Bie,steel:Rie,blue:Oie,royalBlue:Die,cornflower:Pie,navy:Mie,lavender:Lie,purple:jie,grape:zie,lilac:Uie,pink:qie,magenta:$ie,plum:Wie,beige:Gie,mink:Kie,platinum:Vie,anchor:Yie},IO=["red","green","darkOrange","yellow","berry","lightGreen","marigold"],BO=["darkRed","cranberry","pumpkin","peach","gold","brass","brown","forest","seafoam","darkGreen","lightTeal","teal","steel","blue","royalBlue","cornflower","navy","lavender","purple","grape","lilac","pink","magenta","plum","beige","mink","platinum","anchor"],ip=IO.reduce((e,t)=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),r={[`colorPalette${n}Background1`]:Xt[t].tint60,[`colorPalette${n}Background2`]:Xt[t].tint40,[`colorPalette${n}Background3`]:Xt[t].primary,[`colorPalette${n}Foreground1`]:Xt[t].shade10,[`colorPalette${n}Foreground2`]:Xt[t].shade30,[`colorPalette${n}Foreground3`]:Xt[t].primary,[`colorPalette${n}BorderActive`]:Xt[t].primary,[`colorPalette${n}Border1`]:Xt[t].tint40,[`colorPalette${n}Border2`]:Xt[t].primary};return Object.assign(e,r)},{});ip.colorPaletteYellowForeground1=Xt.yellow.shade30;ip.colorPaletteRedForegroundInverted=Xt.red.tint20;ip.colorPaletteGreenForegroundInverted=Xt.green.tint20;ip.colorPaletteYellowForegroundInverted=Xt.yellow.tint40;const Qie=BO.reduce((e,t)=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),r={[`colorPalette${n}Background2`]:yu[t].tint40,[`colorPalette${n}Foreground2`]:yu[t].shade30,[`colorPalette${n}BorderActive`]:yu[t].primary};return Object.assign(e,r)},{}),Xie={...ip,...Qie},Zie=e=>({colorNeutralForeground1:we[14],colorNeutralForeground1Hover:we[14],colorNeutralForeground1Pressed:we[14],colorNeutralForeground1Selected:we[14],colorNeutralForeground2:we[26],colorNeutralForeground2Hover:we[14],colorNeutralForeground2Pressed:we[14],colorNeutralForeground2Selected:we[14],colorNeutralForeground2BrandHover:e[80],colorNeutralForeground2BrandPressed:e[70],colorNeutralForeground2BrandSelected:e[80],colorNeutralForeground3:we[38],colorNeutralForeground3Hover:we[26],colorNeutralForeground3Pressed:we[26],colorNeutralForeground3Selected:we[26],colorNeutralForeground3BrandHover:e[80],colorNeutralForeground3BrandPressed:e[70],colorNeutralForeground3BrandSelected:e[80],colorNeutralForeground4:we[44],colorNeutralForegroundDisabled:we[74],colorNeutralForegroundInvertedDisabled:ya[40],colorBrandForegroundLink:e[70],colorBrandForegroundLinkHover:e[60],colorBrandForegroundLinkPressed:e[40],colorBrandForegroundLinkSelected:e[70],colorNeutralForeground2Link:we[26],colorNeutralForeground2LinkHover:we[14],colorNeutralForeground2LinkPressed:we[14],colorNeutralForeground2LinkSelected:we[14],colorCompoundBrandForeground1:e[80],colorCompoundBrandForeground1Hover:e[70],colorCompoundBrandForeground1Pressed:e[60],colorBrandForeground1:e[80],colorBrandForeground2:e[70],colorNeutralForeground1Static:we[14],colorNeutralForegroundStaticInverted:ht,colorNeutralForegroundInverted:ht,colorNeutralForegroundInvertedHover:ht,colorNeutralForegroundInvertedPressed:ht,colorNeutralForegroundInvertedSelected:ht,colorNeutralForegroundInverted2:ht,colorNeutralForegroundOnBrand:ht,colorNeutralForegroundInvertedLink:ht,colorNeutralForegroundInvertedLinkHover:ht,colorNeutralForegroundInvertedLinkPressed:ht,colorNeutralForegroundInvertedLinkSelected:ht,colorBrandForegroundInverted:e[100],colorBrandForegroundInvertedHover:e[110],colorBrandForegroundInvertedPressed:e[100],colorBrandForegroundOnLight:e[80],colorBrandForegroundOnLightHover:e[70],colorBrandForegroundOnLightPressed:e[50],colorBrandForegroundOnLightSelected:e[60],colorNeutralBackground1:ht,colorNeutralBackground1Hover:we[96],colorNeutralBackground1Pressed:we[88],colorNeutralBackground1Selected:we[92],colorNeutralBackground2:we[98],colorNeutralBackground2Hover:we[94],colorNeutralBackground2Pressed:we[86],colorNeutralBackground2Selected:we[90],colorNeutralBackground3:we[96],colorNeutralBackground3Hover:we[92],colorNeutralBackground3Pressed:we[84],colorNeutralBackground3Selected:we[88],colorNeutralBackground4:we[94],colorNeutralBackground4Hover:we[98],colorNeutralBackground4Pressed:we[96],colorNeutralBackground4Selected:ht,colorNeutralBackground5:we[92],colorNeutralBackground5Hover:we[96],colorNeutralBackground5Pressed:we[94],colorNeutralBackground5Selected:we[98],colorNeutralBackground6:we[90],colorNeutralBackgroundInverted:we[16],colorNeutralBackgroundStatic:we[20],colorSubtleBackground:"transparent",colorSubtleBackgroundHover:we[96],colorSubtleBackgroundPressed:we[88],colorSubtleBackgroundSelected:we[92],colorSubtleBackgroundLightAlphaHover:ya[70],colorSubtleBackgroundLightAlphaPressed:ya[50],colorSubtleBackgroundLightAlphaSelected:"transparent",colorSubtleBackgroundInverted:"transparent",colorSubtleBackgroundInvertedHover:ba[10],colorSubtleBackgroundInvertedPressed:ba[30],colorSubtleBackgroundInvertedSelected:ba[20],colorTransparentBackground:"transparent",colorTransparentBackgroundHover:"transparent",colorTransparentBackgroundPressed:"transparent",colorTransparentBackgroundSelected:"transparent",colorNeutralBackgroundDisabled:we[94],colorNeutralBackgroundInvertedDisabled:ya[10],colorNeutralStencil1:we[90],colorNeutralStencil2:we[98],colorNeutralStencil1Alpha:ba[10],colorNeutralStencil2Alpha:ba[5],colorBackgroundOverlay:ba[40],colorScrollbarOverlay:ba[50],colorBrandBackground:e[80],colorBrandBackgroundHover:e[70],colorBrandBackgroundPressed:e[40],colorBrandBackgroundSelected:e[60],colorCompoundBrandBackground:e[80],colorCompoundBrandBackgroundHover:e[70],colorCompoundBrandBackgroundPressed:e[60],colorBrandBackgroundStatic:e[80],colorBrandBackground2:e[160],colorBrandBackgroundInverted:ht,colorBrandBackgroundInvertedHover:e[160],colorBrandBackgroundInvertedPressed:e[140],colorBrandBackgroundInvertedSelected:e[150],colorNeutralStrokeAccessible:we[38],colorNeutralStrokeAccessibleHover:we[34],colorNeutralStrokeAccessiblePressed:we[30],colorNeutralStrokeAccessibleSelected:e[80],colorNeutralStroke1:we[82],colorNeutralStroke1Hover:we[78],colorNeutralStroke1Pressed:we[70],colorNeutralStroke1Selected:we[74],colorNeutralStroke2:we[88],colorNeutralStroke3:we[94],colorNeutralStrokeOnBrand:ht,colorNeutralStrokeOnBrand2:ht,colorNeutralStrokeOnBrand2Hover:ht,colorNeutralStrokeOnBrand2Pressed:ht,colorNeutralStrokeOnBrand2Selected:ht,colorBrandStroke1:e[80],colorBrandStroke2:e[140],colorCompoundBrandStroke:e[80],colorCompoundBrandStrokeHover:e[70],colorCompoundBrandStrokePressed:e[60],colorNeutralStrokeDisabled:we[88],colorNeutralStrokeInvertedDisabled:ya[40],colorTransparentStroke:"transparent",colorTransparentStrokeInteractive:"transparent",colorTransparentStrokeDisabled:"transparent",colorStrokeFocus1:ht,colorStrokeFocus2:x_,colorNeutralShadowAmbient:"rgba(0,0,0,0.12)",colorNeutralShadowKey:"rgba(0,0,0,0.14)",colorNeutralShadowAmbientLighter:"rgba(0,0,0,0.06)",colorNeutralShadowKeyLighter:"rgba(0,0,0,0.07)",colorNeutralShadowAmbientDarker:"rgba(0,0,0,0.20)",colorNeutralShadowKeyDarker:"rgba(0,0,0,0.24)",colorBrandShadowAmbient:"rgba(0,0,0,0.30)",colorBrandShadowKey:"rgba(0,0,0,0.25)"}),RO={borderRadiusNone:"0",borderRadiusSmall:"2px",borderRadiusMedium:"4px",borderRadiusLarge:"6px",borderRadiusXLarge:"8px",borderRadiusCircular:"10000px"},OO={curveAccelerateMax:"cubic-bezier(1,0,1,1)",curveAccelerateMid:"cubic-bezier(0.7,0,1,0.5)",curveAccelerateMin:"cubic-bezier(0.8,0,1,1)",curveDecelerateMax:"cubic-bezier(0,0,0,1)",curveDecelerateMid:"cubic-bezier(0.1,0.9,0.2,1)",curveDecelerateMin:"cubic-bezier(0.33,0,0.1,1)",curveEasyEaseMax:"cubic-bezier(0.8,0,0.1,1)",curveEasyEase:"cubic-bezier(0.33,0,0.67,1)",curveLinear:"cubic-bezier(0,0,1,1)"},DO={durationUltraFast:"50ms",durationFaster:"100ms",durationFast:"150ms",durationNormal:"200ms",durationSlow:"300ms",durationSlower:"400ms",durationUltraSlow:"500ms"},PO={fontSizeBase100:"10px",fontSizeBase200:"12px",fontSizeBase300:"14px",fontSizeBase400:"16px",fontSizeBase500:"20px",fontSizeBase600:"24px",fontSizeHero700:"28px",fontSizeHero800:"32px",fontSizeHero900:"40px",fontSizeHero1000:"68px"},MO={lineHeightBase100:"14px",lineHeightBase200:"16px",lineHeightBase300:"20px",lineHeightBase400:"22px",lineHeightBase500:"28px",lineHeightBase600:"32px",lineHeightHero700:"36px",lineHeightHero800:"40px",lineHeightHero900:"52px",lineHeightHero1000:"92px"},LO={fontWeightRegular:400,fontWeightMedium:500,fontWeightSemibold:600,fontWeightBold:700},jO={fontFamilyBase:"'Segoe UI', 'Segoe UI Web (West European)', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif",fontFamilyMonospace:"Consolas, 'Courier New', Courier, monospace",fontFamilyNumeric:"Bahnschrift, 'Segoe UI', 'Segoe UI Web (West European)', -apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue', sans-serif"},Kn={none:"0",xxs:"2px",xs:"4px",sNudge:"6px",s:"8px",mNudge:"10px",m:"12px",l:"16px",xl:"20px",xxl:"24px",xxxl:"32px"},zO={spacingHorizontalNone:Kn.none,spacingHorizontalXXS:Kn.xxs,spacingHorizontalXS:Kn.xs,spacingHorizontalSNudge:Kn.sNudge,spacingHorizontalS:Kn.s,spacingHorizontalMNudge:Kn.mNudge,spacingHorizontalM:Kn.m,spacingHorizontalL:Kn.l,spacingHorizontalXL:Kn.xl,spacingHorizontalXXL:Kn.xxl,spacingHorizontalXXXL:Kn.xxxl},HO={spacingVerticalNone:Kn.none,spacingVerticalXXS:Kn.xxs,spacingVerticalXS:Kn.xs,spacingVerticalSNudge:Kn.sNudge,spacingVerticalS:Kn.s,spacingVerticalMNudge:Kn.mNudge,spacingVerticalM:Kn.m,spacingVerticalL:Kn.l,spacingVerticalXL:Kn.xl,spacingVerticalXXL:Kn.xxl,spacingVerticalXXXL:Kn.xxxl},UO={strokeWidthThin:"1px",strokeWidthThick:"2px",strokeWidthThicker:"3px",strokeWidthThickest:"4px"},nn={colorNeutralForeground1:"var(--colorNeutralForeground1)",colorNeutralForeground1Hover:"var(--colorNeutralForeground1Hover)",colorNeutralForeground1Pressed:"var(--colorNeutralForeground1Pressed)",colorNeutralForeground1Selected:"var(--colorNeutralForeground1Selected)",colorNeutralForeground2:"var(--colorNeutralForeground2)",colorNeutralForeground2Hover:"var(--colorNeutralForeground2Hover)",colorNeutralForeground2Pressed:"var(--colorNeutralForeground2Pressed)",colorNeutralForeground2Selected:"var(--colorNeutralForeground2Selected)",colorNeutralForeground2BrandHover:"var(--colorNeutralForeground2BrandHover)",colorNeutralForeground2BrandPressed:"var(--colorNeutralForeground2BrandPressed)",colorNeutralForeground2BrandSelected:"var(--colorNeutralForeground2BrandSelected)",colorNeutralForeground3:"var(--colorNeutralForeground3)",colorNeutralForeground3Hover:"var(--colorNeutralForeground3Hover)",colorNeutralForeground3Pressed:"var(--colorNeutralForeground3Pressed)",colorNeutralForeground3Selected:"var(--colorNeutralForeground3Selected)",colorNeutralForeground3BrandHover:"var(--colorNeutralForeground3BrandHover)",colorNeutralForeground3BrandPressed:"var(--colorNeutralForeground3BrandPressed)",colorNeutralForeground3BrandSelected:"var(--colorNeutralForeground3BrandSelected)",colorNeutralForeground4:"var(--colorNeutralForeground4)",colorNeutralForegroundDisabled:"var(--colorNeutralForegroundDisabled)",colorBrandForegroundLink:"var(--colorBrandForegroundLink)",colorBrandForegroundLinkHover:"var(--colorBrandForegroundLinkHover)",colorBrandForegroundLinkPressed:"var(--colorBrandForegroundLinkPressed)",colorBrandForegroundLinkSelected:"var(--colorBrandForegroundLinkSelected)",colorNeutralForeground2Link:"var(--colorNeutralForeground2Link)",colorNeutralForeground2LinkHover:"var(--colorNeutralForeground2LinkHover)",colorNeutralForeground2LinkPressed:"var(--colorNeutralForeground2LinkPressed)",colorNeutralForeground2LinkSelected:"var(--colorNeutralForeground2LinkSelected)",colorCompoundBrandForeground1:"var(--colorCompoundBrandForeground1)",colorCompoundBrandForeground1Hover:"var(--colorCompoundBrandForeground1Hover)",colorCompoundBrandForeground1Pressed:"var(--colorCompoundBrandForeground1Pressed)",colorNeutralForegroundOnBrand:"var(--colorNeutralForegroundOnBrand)",colorNeutralForegroundInverted:"var(--colorNeutralForegroundInverted)",colorNeutralForegroundInvertedHover:"var(--colorNeutralForegroundInvertedHover)",colorNeutralForegroundInvertedPressed:"var(--colorNeutralForegroundInvertedPressed)",colorNeutralForegroundInvertedSelected:"var(--colorNeutralForegroundInvertedSelected)",colorNeutralForegroundInverted2:"var(--colorNeutralForegroundInverted2)",colorNeutralForegroundStaticInverted:"var(--colorNeutralForegroundStaticInverted)",colorNeutralForegroundInvertedLink:"var(--colorNeutralForegroundInvertedLink)",colorNeutralForegroundInvertedLinkHover:"var(--colorNeutralForegroundInvertedLinkHover)",colorNeutralForegroundInvertedLinkPressed:"var(--colorNeutralForegroundInvertedLinkPressed)",colorNeutralForegroundInvertedLinkSelected:"var(--colorNeutralForegroundInvertedLinkSelected)",colorNeutralForegroundInvertedDisabled:"var(--colorNeutralForegroundInvertedDisabled)",colorBrandForeground1:"var(--colorBrandForeground1)",colorBrandForeground2:"var(--colorBrandForeground2)",colorNeutralForeground1Static:"var(--colorNeutralForeground1Static)",colorBrandForegroundInverted:"var(--colorBrandForegroundInverted)",colorBrandForegroundInvertedHover:"var(--colorBrandForegroundInvertedHover)",colorBrandForegroundInvertedPressed:"var(--colorBrandForegroundInvertedPressed)",colorBrandForegroundOnLight:"var(--colorBrandForegroundOnLight)",colorBrandForegroundOnLightHover:"var(--colorBrandForegroundOnLightHover)",colorBrandForegroundOnLightPressed:"var(--colorBrandForegroundOnLightPressed)",colorBrandForegroundOnLightSelected:"var(--colorBrandForegroundOnLightSelected)",colorNeutralBackground1:"var(--colorNeutralBackground1)",colorNeutralBackground1Hover:"var(--colorNeutralBackground1Hover)",colorNeutralBackground1Pressed:"var(--colorNeutralBackground1Pressed)",colorNeutralBackground1Selected:"var(--colorNeutralBackground1Selected)",colorNeutralBackground2:"var(--colorNeutralBackground2)",colorNeutralBackground2Hover:"var(--colorNeutralBackground2Hover)",colorNeutralBackground2Pressed:"var(--colorNeutralBackground2Pressed)",colorNeutralBackground2Selected:"var(--colorNeutralBackground2Selected)",colorNeutralBackground3:"var(--colorNeutralBackground3)",colorNeutralBackground3Hover:"var(--colorNeutralBackground3Hover)",colorNeutralBackground3Pressed:"var(--colorNeutralBackground3Pressed)",colorNeutralBackground3Selected:"var(--colorNeutralBackground3Selected)",colorNeutralBackground4:"var(--colorNeutralBackground4)",colorNeutralBackground4Hover:"var(--colorNeutralBackground4Hover)",colorNeutralBackground4Pressed:"var(--colorNeutralBackground4Pressed)",colorNeutralBackground4Selected:"var(--colorNeutralBackground4Selected)",colorNeutralBackground5:"var(--colorNeutralBackground5)",colorNeutralBackground5Hover:"var(--colorNeutralBackground5Hover)",colorNeutralBackground5Pressed:"var(--colorNeutralBackground5Pressed)",colorNeutralBackground5Selected:"var(--colorNeutralBackground5Selected)",colorNeutralBackground6:"var(--colorNeutralBackground6)",colorNeutralBackgroundStatic:"var(--colorNeutralBackgroundStatic)",colorNeutralBackgroundInverted:"var(--colorNeutralBackgroundInverted)",colorSubtleBackground:"var(--colorSubtleBackground)",colorSubtleBackgroundHover:"var(--colorSubtleBackgroundHover)",colorSubtleBackgroundPressed:"var(--colorSubtleBackgroundPressed)",colorSubtleBackgroundSelected:"var(--colorSubtleBackgroundSelected)",colorSubtleBackgroundLightAlphaHover:"var(--colorSubtleBackgroundLightAlphaHover)",colorSubtleBackgroundLightAlphaPressed:"var(--colorSubtleBackgroundLightAlphaPressed)",colorSubtleBackgroundLightAlphaSelected:"var(--colorSubtleBackgroundLightAlphaSelected)",colorSubtleBackgroundInverted:"var(--colorSubtleBackgroundInverted)",colorSubtleBackgroundInvertedHover:"var(--colorSubtleBackgroundInvertedHover)",colorSubtleBackgroundInvertedPressed:"var(--colorSubtleBackgroundInvertedPressed)",colorSubtleBackgroundInvertedSelected:"var(--colorSubtleBackgroundInvertedSelected)",colorTransparentBackground:"var(--colorTransparentBackground)",colorTransparentBackgroundHover:"var(--colorTransparentBackgroundHover)",colorTransparentBackgroundPressed:"var(--colorTransparentBackgroundPressed)",colorTransparentBackgroundSelected:"var(--colorTransparentBackgroundSelected)",colorNeutralBackgroundDisabled:"var(--colorNeutralBackgroundDisabled)",colorNeutralBackgroundInvertedDisabled:"var(--colorNeutralBackgroundInvertedDisabled)",colorNeutralStencil1:"var(--colorNeutralStencil1)",colorNeutralStencil2:"var(--colorNeutralStencil2)",colorNeutralStencil1Alpha:"var(--colorNeutralStencil1Alpha)",colorNeutralStencil2Alpha:"var(--colorNeutralStencil2Alpha)",colorBackgroundOverlay:"var(--colorBackgroundOverlay)",colorScrollbarOverlay:"var(--colorScrollbarOverlay)",colorBrandBackground:"var(--colorBrandBackground)",colorBrandBackgroundHover:"var(--colorBrandBackgroundHover)",colorBrandBackgroundPressed:"var(--colorBrandBackgroundPressed)",colorBrandBackgroundSelected:"var(--colorBrandBackgroundSelected)",colorCompoundBrandBackground:"var(--colorCompoundBrandBackground)",colorCompoundBrandBackgroundHover:"var(--colorCompoundBrandBackgroundHover)",colorCompoundBrandBackgroundPressed:"var(--colorCompoundBrandBackgroundPressed)",colorBrandBackgroundStatic:"var(--colorBrandBackgroundStatic)",colorBrandBackground2:"var(--colorBrandBackground2)",colorBrandBackgroundInverted:"var(--colorBrandBackgroundInverted)",colorBrandBackgroundInvertedHover:"var(--colorBrandBackgroundInvertedHover)",colorBrandBackgroundInvertedPressed:"var(--colorBrandBackgroundInvertedPressed)",colorBrandBackgroundInvertedSelected:"var(--colorBrandBackgroundInvertedSelected)",colorNeutralStrokeAccessible:"var(--colorNeutralStrokeAccessible)",colorNeutralStrokeAccessibleHover:"var(--colorNeutralStrokeAccessibleHover)",colorNeutralStrokeAccessiblePressed:"var(--colorNeutralStrokeAccessiblePressed)",colorNeutralStrokeAccessibleSelected:"var(--colorNeutralStrokeAccessibleSelected)",colorNeutralStroke1:"var(--colorNeutralStroke1)",colorNeutralStroke1Hover:"var(--colorNeutralStroke1Hover)",colorNeutralStroke1Pressed:"var(--colorNeutralStroke1Pressed)",colorNeutralStroke1Selected:"var(--colorNeutralStroke1Selected)",colorNeutralStroke2:"var(--colorNeutralStroke2)",colorNeutralStroke3:"var(--colorNeutralStroke3)",colorNeutralStrokeOnBrand:"var(--colorNeutralStrokeOnBrand)",colorNeutralStrokeOnBrand2:"var(--colorNeutralStrokeOnBrand2)",colorNeutralStrokeOnBrand2Hover:"var(--colorNeutralStrokeOnBrand2Hover)",colorNeutralStrokeOnBrand2Pressed:"var(--colorNeutralStrokeOnBrand2Pressed)",colorNeutralStrokeOnBrand2Selected:"var(--colorNeutralStrokeOnBrand2Selected)",colorBrandStroke1:"var(--colorBrandStroke1)",colorBrandStroke2:"var(--colorBrandStroke2)",colorCompoundBrandStroke:"var(--colorCompoundBrandStroke)",colorCompoundBrandStrokeHover:"var(--colorCompoundBrandStrokeHover)",colorCompoundBrandStrokePressed:"var(--colorCompoundBrandStrokePressed)",colorNeutralStrokeDisabled:"var(--colorNeutralStrokeDisabled)",colorNeutralStrokeInvertedDisabled:"var(--colorNeutralStrokeInvertedDisabled)",colorTransparentStroke:"var(--colorTransparentStroke)",colorTransparentStrokeInteractive:"var(--colorTransparentStrokeInteractive)",colorTransparentStrokeDisabled:"var(--colorTransparentStrokeDisabled)",colorStrokeFocus1:"var(--colorStrokeFocus1)",colorStrokeFocus2:"var(--colorStrokeFocus2)",colorNeutralShadowAmbient:"var(--colorNeutralShadowAmbient)",colorNeutralShadowKey:"var(--colorNeutralShadowKey)",colorNeutralShadowAmbientLighter:"var(--colorNeutralShadowAmbientLighter)",colorNeutralShadowKeyLighter:"var(--colorNeutralShadowKeyLighter)",colorNeutralShadowAmbientDarker:"var(--colorNeutralShadowAmbientDarker)",colorNeutralShadowKeyDarker:"var(--colorNeutralShadowKeyDarker)",colorBrandShadowAmbient:"var(--colorBrandShadowAmbient)",colorBrandShadowKey:"var(--colorBrandShadowKey)",colorPaletteRedBackground1:"var(--colorPaletteRedBackground1)",colorPaletteRedBackground2:"var(--colorPaletteRedBackground2)",colorPaletteRedBackground3:"var(--colorPaletteRedBackground3)",colorPaletteRedBorderActive:"var(--colorPaletteRedBorderActive)",colorPaletteRedBorder1:"var(--colorPaletteRedBorder1)",colorPaletteRedBorder2:"var(--colorPaletteRedBorder2)",colorPaletteRedForeground1:"var(--colorPaletteRedForeground1)",colorPaletteRedForeground2:"var(--colorPaletteRedForeground2)",colorPaletteRedForeground3:"var(--colorPaletteRedForeground3)",colorPaletteRedForegroundInverted:"var(--colorPaletteRedForegroundInverted)",colorPaletteGreenBackground1:"var(--colorPaletteGreenBackground1)",colorPaletteGreenBackground2:"var(--colorPaletteGreenBackground2)",colorPaletteGreenBackground3:"var(--colorPaletteGreenBackground3)",colorPaletteGreenBorderActive:"var(--colorPaletteGreenBorderActive)",colorPaletteGreenBorder1:"var(--colorPaletteGreenBorder1)",colorPaletteGreenBorder2:"var(--colorPaletteGreenBorder2)",colorPaletteGreenForeground1:"var(--colorPaletteGreenForeground1)",colorPaletteGreenForeground2:"var(--colorPaletteGreenForeground2)",colorPaletteGreenForeground3:"var(--colorPaletteGreenForeground3)",colorPaletteGreenForegroundInverted:"var(--colorPaletteGreenForegroundInverted)",colorPaletteDarkOrangeBackground1:"var(--colorPaletteDarkOrangeBackground1)",colorPaletteDarkOrangeBackground2:"var(--colorPaletteDarkOrangeBackground2)",colorPaletteDarkOrangeBackground3:"var(--colorPaletteDarkOrangeBackground3)",colorPaletteDarkOrangeBorderActive:"var(--colorPaletteDarkOrangeBorderActive)",colorPaletteDarkOrangeBorder1:"var(--colorPaletteDarkOrangeBorder1)",colorPaletteDarkOrangeBorder2:"var(--colorPaletteDarkOrangeBorder2)",colorPaletteDarkOrangeForeground1:"var(--colorPaletteDarkOrangeForeground1)",colorPaletteDarkOrangeForeground2:"var(--colorPaletteDarkOrangeForeground2)",colorPaletteDarkOrangeForeground3:"var(--colorPaletteDarkOrangeForeground3)",colorPaletteYellowBackground1:"var(--colorPaletteYellowBackground1)",colorPaletteYellowBackground2:"var(--colorPaletteYellowBackground2)",colorPaletteYellowBackground3:"var(--colorPaletteYellowBackground3)",colorPaletteYellowBorderActive:"var(--colorPaletteYellowBorderActive)",colorPaletteYellowBorder1:"var(--colorPaletteYellowBorder1)",colorPaletteYellowBorder2:"var(--colorPaletteYellowBorder2)",colorPaletteYellowForeground1:"var(--colorPaletteYellowForeground1)",colorPaletteYellowForeground2:"var(--colorPaletteYellowForeground2)",colorPaletteYellowForeground3:"var(--colorPaletteYellowForeground3)",colorPaletteYellowForegroundInverted:"var(--colorPaletteYellowForegroundInverted)",colorPaletteBerryBackground1:"var(--colorPaletteBerryBackground1)",colorPaletteBerryBackground2:"var(--colorPaletteBerryBackground2)",colorPaletteBerryBackground3:"var(--colorPaletteBerryBackground3)",colorPaletteBerryBorderActive:"var(--colorPaletteBerryBorderActive)",colorPaletteBerryBorder1:"var(--colorPaletteBerryBorder1)",colorPaletteBerryBorder2:"var(--colorPaletteBerryBorder2)",colorPaletteBerryForeground1:"var(--colorPaletteBerryForeground1)",colorPaletteBerryForeground2:"var(--colorPaletteBerryForeground2)",colorPaletteBerryForeground3:"var(--colorPaletteBerryForeground3)",colorPaletteMarigoldBackground1:"var(--colorPaletteMarigoldBackground1)",colorPaletteMarigoldBackground2:"var(--colorPaletteMarigoldBackground2)",colorPaletteMarigoldBackground3:"var(--colorPaletteMarigoldBackground3)",colorPaletteMarigoldBorderActive:"var(--colorPaletteMarigoldBorderActive)",colorPaletteMarigoldBorder1:"var(--colorPaletteMarigoldBorder1)",colorPaletteMarigoldBorder2:"var(--colorPaletteMarigoldBorder2)",colorPaletteMarigoldForeground1:"var(--colorPaletteMarigoldForeground1)",colorPaletteMarigoldForeground2:"var(--colorPaletteMarigoldForeground2)",colorPaletteMarigoldForeground3:"var(--colorPaletteMarigoldForeground3)",colorPaletteLightGreenBackground1:"var(--colorPaletteLightGreenBackground1)",colorPaletteLightGreenBackground2:"var(--colorPaletteLightGreenBackground2)",colorPaletteLightGreenBackground3:"var(--colorPaletteLightGreenBackground3)",colorPaletteLightGreenBorderActive:"var(--colorPaletteLightGreenBorderActive)",colorPaletteLightGreenBorder1:"var(--colorPaletteLightGreenBorder1)",colorPaletteLightGreenBorder2:"var(--colorPaletteLightGreenBorder2)",colorPaletteLightGreenForeground1:"var(--colorPaletteLightGreenForeground1)",colorPaletteLightGreenForeground2:"var(--colorPaletteLightGreenForeground2)",colorPaletteLightGreenForeground3:"var(--colorPaletteLightGreenForeground3)",colorPaletteAnchorBackground2:"var(--colorPaletteAnchorBackground2)",colorPaletteAnchorBorderActive:"var(--colorPaletteAnchorBorderActive)",colorPaletteAnchorForeground2:"var(--colorPaletteAnchorForeground2)",colorPaletteBeigeBackground2:"var(--colorPaletteBeigeBackground2)",colorPaletteBeigeBorderActive:"var(--colorPaletteBeigeBorderActive)",colorPaletteBeigeForeground2:"var(--colorPaletteBeigeForeground2)",colorPaletteBlueBackground2:"var(--colorPaletteBlueBackground2)",colorPaletteBlueBorderActive:"var(--colorPaletteBlueBorderActive)",colorPaletteBlueForeground2:"var(--colorPaletteBlueForeground2)",colorPaletteBrassBackground2:"var(--colorPaletteBrassBackground2)",colorPaletteBrassBorderActive:"var(--colorPaletteBrassBorderActive)",colorPaletteBrassForeground2:"var(--colorPaletteBrassForeground2)",colorPaletteBrownBackground2:"var(--colorPaletteBrownBackground2)",colorPaletteBrownBorderActive:"var(--colorPaletteBrownBorderActive)",colorPaletteBrownForeground2:"var(--colorPaletteBrownForeground2)",colorPaletteCornflowerBackground2:"var(--colorPaletteCornflowerBackground2)",colorPaletteCornflowerBorderActive:"var(--colorPaletteCornflowerBorderActive)",colorPaletteCornflowerForeground2:"var(--colorPaletteCornflowerForeground2)",colorPaletteCranberryBackground2:"var(--colorPaletteCranberryBackground2)",colorPaletteCranberryBorderActive:"var(--colorPaletteCranberryBorderActive)",colorPaletteCranberryForeground2:"var(--colorPaletteCranberryForeground2)",colorPaletteDarkGreenBackground2:"var(--colorPaletteDarkGreenBackground2)",colorPaletteDarkGreenBorderActive:"var(--colorPaletteDarkGreenBorderActive)",colorPaletteDarkGreenForeground2:"var(--colorPaletteDarkGreenForeground2)",colorPaletteDarkRedBackground2:"var(--colorPaletteDarkRedBackground2)",colorPaletteDarkRedBorderActive:"var(--colorPaletteDarkRedBorderActive)",colorPaletteDarkRedForeground2:"var(--colorPaletteDarkRedForeground2)",colorPaletteForestBackground2:"var(--colorPaletteForestBackground2)",colorPaletteForestBorderActive:"var(--colorPaletteForestBorderActive)",colorPaletteForestForeground2:"var(--colorPaletteForestForeground2)",colorPaletteGoldBackground2:"var(--colorPaletteGoldBackground2)",colorPaletteGoldBorderActive:"var(--colorPaletteGoldBorderActive)",colorPaletteGoldForeground2:"var(--colorPaletteGoldForeground2)",colorPaletteGrapeBackground2:"var(--colorPaletteGrapeBackground2)",colorPaletteGrapeBorderActive:"var(--colorPaletteGrapeBorderActive)",colorPaletteGrapeForeground2:"var(--colorPaletteGrapeForeground2)",colorPaletteLavenderBackground2:"var(--colorPaletteLavenderBackground2)",colorPaletteLavenderBorderActive:"var(--colorPaletteLavenderBorderActive)",colorPaletteLavenderForeground2:"var(--colorPaletteLavenderForeground2)",colorPaletteLightTealBackground2:"var(--colorPaletteLightTealBackground2)",colorPaletteLightTealBorderActive:"var(--colorPaletteLightTealBorderActive)",colorPaletteLightTealForeground2:"var(--colorPaletteLightTealForeground2)",colorPaletteLilacBackground2:"var(--colorPaletteLilacBackground2)",colorPaletteLilacBorderActive:"var(--colorPaletteLilacBorderActive)",colorPaletteLilacForeground2:"var(--colorPaletteLilacForeground2)",colorPaletteMagentaBackground2:"var(--colorPaletteMagentaBackground2)",colorPaletteMagentaBorderActive:"var(--colorPaletteMagentaBorderActive)",colorPaletteMagentaForeground2:"var(--colorPaletteMagentaForeground2)",colorPaletteMinkBackground2:"var(--colorPaletteMinkBackground2)",colorPaletteMinkBorderActive:"var(--colorPaletteMinkBorderActive)",colorPaletteMinkForeground2:"var(--colorPaletteMinkForeground2)",colorPaletteNavyBackground2:"var(--colorPaletteNavyBackground2)",colorPaletteNavyBorderActive:"var(--colorPaletteNavyBorderActive)",colorPaletteNavyForeground2:"var(--colorPaletteNavyForeground2)",colorPalettePeachBackground2:"var(--colorPalettePeachBackground2)",colorPalettePeachBorderActive:"var(--colorPalettePeachBorderActive)",colorPalettePeachForeground2:"var(--colorPalettePeachForeground2)",colorPalettePinkBackground2:"var(--colorPalettePinkBackground2)",colorPalettePinkBorderActive:"var(--colorPalettePinkBorderActive)",colorPalettePinkForeground2:"var(--colorPalettePinkForeground2)",colorPalettePlatinumBackground2:"var(--colorPalettePlatinumBackground2)",colorPalettePlatinumBorderActive:"var(--colorPalettePlatinumBorderActive)",colorPalettePlatinumForeground2:"var(--colorPalettePlatinumForeground2)",colorPalettePlumBackground2:"var(--colorPalettePlumBackground2)",colorPalettePlumBorderActive:"var(--colorPalettePlumBorderActive)",colorPalettePlumForeground2:"var(--colorPalettePlumForeground2)",colorPalettePumpkinBackground2:"var(--colorPalettePumpkinBackground2)",colorPalettePumpkinBorderActive:"var(--colorPalettePumpkinBorderActive)",colorPalettePumpkinForeground2:"var(--colorPalettePumpkinForeground2)",colorPalettePurpleBackground2:"var(--colorPalettePurpleBackground2)",colorPalettePurpleBorderActive:"var(--colorPalettePurpleBorderActive)",colorPalettePurpleForeground2:"var(--colorPalettePurpleForeground2)",colorPaletteRoyalBlueBackground2:"var(--colorPaletteRoyalBlueBackground2)",colorPaletteRoyalBlueBorderActive:"var(--colorPaletteRoyalBlueBorderActive)",colorPaletteRoyalBlueForeground2:"var(--colorPaletteRoyalBlueForeground2)",colorPaletteSeafoamBackground2:"var(--colorPaletteSeafoamBackground2)",colorPaletteSeafoamBorderActive:"var(--colorPaletteSeafoamBorderActive)",colorPaletteSeafoamForeground2:"var(--colorPaletteSeafoamForeground2)",colorPaletteSteelBackground2:"var(--colorPaletteSteelBackground2)",colorPaletteSteelBorderActive:"var(--colorPaletteSteelBorderActive)",colorPaletteSteelForeground2:"var(--colorPaletteSteelForeground2)",colorPaletteTealBackground2:"var(--colorPaletteTealBackground2)",colorPaletteTealBorderActive:"var(--colorPaletteTealBorderActive)",colorPaletteTealForeground2:"var(--colorPaletteTealForeground2)",borderRadiusNone:"var(--borderRadiusNone)",borderRadiusSmall:"var(--borderRadiusSmall)",borderRadiusMedium:"var(--borderRadiusMedium)",borderRadiusLarge:"var(--borderRadiusLarge)",borderRadiusXLarge:"var(--borderRadiusXLarge)",borderRadiusCircular:"var(--borderRadiusCircular)",fontFamilyBase:"var(--fontFamilyBase)",fontFamilyMonospace:"var(--fontFamilyMonospace)",fontFamilyNumeric:"var(--fontFamilyNumeric)",fontSizeBase100:"var(--fontSizeBase100)",fontSizeBase200:"var(--fontSizeBase200)",fontSizeBase300:"var(--fontSizeBase300)",fontSizeBase400:"var(--fontSizeBase400)",fontSizeBase500:"var(--fontSizeBase500)",fontSizeBase600:"var(--fontSizeBase600)",fontSizeHero700:"var(--fontSizeHero700)",fontSizeHero800:"var(--fontSizeHero800)",fontSizeHero900:"var(--fontSizeHero900)",fontSizeHero1000:"var(--fontSizeHero1000)",fontWeightRegular:"var(--fontWeightRegular)",fontWeightMedium:"var(--fontWeightMedium)",fontWeightSemibold:"var(--fontWeightSemibold)",fontWeightBold:"var(--fontWeightBold)",lineHeightBase100:"var(--lineHeightBase100)",lineHeightBase200:"var(--lineHeightBase200)",lineHeightBase300:"var(--lineHeightBase300)",lineHeightBase400:"var(--lineHeightBase400)",lineHeightBase500:"var(--lineHeightBase500)",lineHeightBase600:"var(--lineHeightBase600)",lineHeightHero700:"var(--lineHeightHero700)",lineHeightHero800:"var(--lineHeightHero800)",lineHeightHero900:"var(--lineHeightHero900)",lineHeightHero1000:"var(--lineHeightHero1000)",shadow2:"var(--shadow2)",shadow4:"var(--shadow4)",shadow8:"var(--shadow8)",shadow16:"var(--shadow16)",shadow28:"var(--shadow28)",shadow64:"var(--shadow64)",shadow2Brand:"var(--shadow2Brand)",shadow4Brand:"var(--shadow4Brand)",shadow8Brand:"var(--shadow8Brand)",shadow16Brand:"var(--shadow16Brand)",shadow28Brand:"var(--shadow28Brand)",shadow64Brand:"var(--shadow64Brand)",strokeWidthThin:"var(--strokeWidthThin)",strokeWidthThick:"var(--strokeWidthThick)",strokeWidthThicker:"var(--strokeWidthThicker)",strokeWidthThickest:"var(--strokeWidthThickest)",spacingHorizontalNone:"var(--spacingHorizontalNone)",spacingHorizontalXXS:"var(--spacingHorizontalXXS)",spacingHorizontalXS:"var(--spacingHorizontalXS)",spacingHorizontalSNudge:"var(--spacingHorizontalSNudge)",spacingHorizontalS:"var(--spacingHorizontalS)",spacingHorizontalMNudge:"var(--spacingHorizontalMNudge)",spacingHorizontalM:"var(--spacingHorizontalM)",spacingHorizontalL:"var(--spacingHorizontalL)",spacingHorizontalXL:"var(--spacingHorizontalXL)",spacingHorizontalXXL:"var(--spacingHorizontalXXL)",spacingHorizontalXXXL:"var(--spacingHorizontalXXXL)",spacingVerticalNone:"var(--spacingVerticalNone)",spacingVerticalXXS:"var(--spacingVerticalXXS)",spacingVerticalXS:"var(--spacingVerticalXS)",spacingVerticalSNudge:"var(--spacingVerticalSNudge)",spacingVerticalS:"var(--spacingVerticalS)",spacingVerticalMNudge:"var(--spacingVerticalMNudge)",spacingVerticalM:"var(--spacingVerticalM)",spacingVerticalL:"var(--spacingVerticalL)",spacingVerticalXL:"var(--spacingVerticalXL)",spacingVerticalXXL:"var(--spacingVerticalXXL)",spacingVerticalXXXL:"var(--spacingVerticalXXXL)",durationUltraFast:"var(--durationUltraFast)",durationFaster:"var(--durationFaster)",durationFast:"var(--durationFast)",durationNormal:"var(--durationNormal)",durationSlow:"var(--durationSlow)",durationSlower:"var(--durationSlower)",durationUltraSlow:"var(--durationUltraSlow)",curveAccelerateMax:"var(--curveAccelerateMax)",curveAccelerateMid:"var(--curveAccelerateMid)",curveAccelerateMin:"var(--curveAccelerateMin)",curveDecelerateMax:"var(--curveDecelerateMax)",curveDecelerateMid:"var(--curveDecelerateMid)",curveDecelerateMin:"var(--curveDecelerateMin)",curveEasyEaseMax:"var(--curveEasyEaseMax)",curveEasyEase:"var(--curveEasyEase)",curveLinear:"var(--curveLinear)"};function Hv(e,t,n=""){return{[`shadow2${n}`]:`0 0 2px ${e}, 0 1px 2px ${t}`,[`shadow4${n}`]:`0 0 2px ${e}, 0 2px 4px ${t}`,[`shadow8${n}`]:`0 0 2px ${e}, 0 4px 8px ${t}`,[`shadow16${n}`]:`0 0 2px ${e}, 0 8px 16px ${t}`,[`shadow28${n}`]:`0 0 8px ${e}, 0 14px 28px ${t}`,[`shadow64${n}`]:`0 0 8px ${e}, 0 32px 64px ${t}`}}const Jie=e=>{const t=Zie(e);return{...RO,...PO,...MO,...jO,...LO,...UO,...zO,...HO,...DO,...OO,...t,...Xie,...Hv(t.colorNeutralShadowAmbient,t.colorNeutralShadowKey),...Hv(t.colorBrandShadowAmbient,t.colorBrandShadowKey,"Brand")}},qO={10:"#2b2b40",20:"#2f2f4a",30:"#333357",40:"#383966",50:"#3d3e78",60:"#444791",70:"#4f52b2",80:"#5b5fc7",90:"#7579eb",100:"#7f85f5",110:"#9299f7",120:"#aab1fa",130:"#b6bcfa",140:"#c5cbfa",150:"#dce0fa",160:"#e8ebfa"},eae=Jie(qO),ms=IO.reduce((e,t)=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),r={[`colorPalette${n}Background1`]:Xt[t].shade40,[`colorPalette${n}Background2`]:Xt[t].shade30,[`colorPalette${n}Background3`]:Xt[t].primary,[`colorPalette${n}Foreground1`]:Xt[t].tint30,[`colorPalette${n}Foreground2`]:Xt[t].tint40,[`colorPalette${n}Foreground3`]:Xt[t].tint20,[`colorPalette${n}BorderActive`]:Xt[t].tint30,[`colorPalette${n}Border1`]:Xt[t].primary,[`colorPalette${n}Border2`]:Xt[t].tint20};return Object.assign(e,r)},{});ms.colorPaletteRedForeground3=Xt.red.tint30;ms.colorPaletteRedBorder2=Xt.red.tint30;ms.colorPaletteGreenForeground3=Xt.green.tint40;ms.colorPaletteGreenBorder2=Xt.green.tint40;ms.colorPaletteDarkOrangeForeground3=Xt.darkOrange.tint30;ms.colorPaletteDarkOrangeBorder2=Xt.darkOrange.tint30;ms.colorPaletteRedForegroundInverted=Xt.red.primary;ms.colorPaletteGreenForegroundInverted=Xt.green.primary;ms.colorPaletteYellowForegroundInverted=Xt.yellow.shade30;const MT=BO.reduce((e,t)=>{const n=t.slice(0,1).toUpperCase()+t.slice(1),r={[`colorPalette${n}Background2`]:yu[t].shade30,[`colorPalette${n}Foreground2`]:yu[t].tint40,[`colorPalette${n}BorderActive`]:yu[t].tint30};return Object.assign(e,r)},{});MT.colorPaletteDarkRedBackground2=yu.darkRed.shade20;MT.colorPalettePlumBackground2=yu.plum.shade20;const tae={...ms,...MT},nae=e=>({colorNeutralForeground1:ht,colorNeutralForeground1Hover:ht,colorNeutralForeground1Pressed:ht,colorNeutralForeground1Selected:ht,colorNeutralForeground2:we[84],colorNeutralForeground2Hover:ht,colorNeutralForeground2Pressed:ht,colorNeutralForeground2Selected:ht,colorNeutralForeground2BrandHover:e[100],colorNeutralForeground2BrandPressed:e[90],colorNeutralForeground2BrandSelected:e[100],colorNeutralForeground3:we[68],colorNeutralForeground3Hover:we[84],colorNeutralForeground3Pressed:we[84],colorNeutralForeground3Selected:we[84],colorNeutralForeground3BrandHover:e[100],colorNeutralForeground3BrandPressed:e[90],colorNeutralForeground3BrandSelected:e[100],colorNeutralForeground4:we[60],colorNeutralForegroundDisabled:we[36],colorNeutralForegroundInvertedDisabled:ya[40],colorBrandForegroundLink:e[100],colorBrandForegroundLinkHover:e[110],colorBrandForegroundLinkPressed:e[90],colorBrandForegroundLinkSelected:e[100],colorNeutralForeground2Link:we[84],colorNeutralForeground2LinkHover:ht,colorNeutralForeground2LinkPressed:ht,colorNeutralForeground2LinkSelected:ht,colorCompoundBrandForeground1:e[100],colorCompoundBrandForeground1Hover:e[110],colorCompoundBrandForeground1Pressed:e[90],colorBrandForeground1:e[100],colorBrandForeground2:e[120],colorNeutralForeground1Static:we[14],colorNeutralForegroundStaticInverted:ht,colorNeutralForegroundInverted:we[14],colorNeutralForegroundInvertedHover:we[14],colorNeutralForegroundInvertedPressed:we[14],colorNeutralForegroundInvertedSelected:we[14],colorNeutralForegroundInverted2:we[14],colorNeutralForegroundOnBrand:ht,colorNeutralForegroundInvertedLink:ht,colorNeutralForegroundInvertedLinkHover:ht,colorNeutralForegroundInvertedLinkPressed:ht,colorNeutralForegroundInvertedLinkSelected:ht,colorBrandForegroundInverted:e[80],colorBrandForegroundInvertedHover:e[70],colorBrandForegroundInvertedPressed:e[60],colorBrandForegroundOnLight:e[80],colorBrandForegroundOnLightHover:e[70],colorBrandForegroundOnLightPressed:e[50],colorBrandForegroundOnLightSelected:e[60],colorNeutralBackground1:we[16],colorNeutralBackground1Hover:we[24],colorNeutralBackground1Pressed:we[12],colorNeutralBackground1Selected:we[22],colorNeutralBackground2:we[14],colorNeutralBackground2Hover:we[22],colorNeutralBackground2Pressed:we[10],colorNeutralBackground2Selected:we[20],colorNeutralBackground3:we[12],colorNeutralBackground3Hover:we[20],colorNeutralBackground3Pressed:we[8],colorNeutralBackground3Selected:we[18],colorNeutralBackground4:we[8],colorNeutralBackground4Hover:we[16],colorNeutralBackground4Pressed:we[4],colorNeutralBackground4Selected:we[14],colorNeutralBackground5:we[4],colorNeutralBackground5Hover:we[12],colorNeutralBackground5Pressed:x_,colorNeutralBackground5Selected:we[10],colorNeutralBackground6:we[20],colorNeutralBackgroundInverted:ht,colorNeutralBackgroundStatic:we[24],colorSubtleBackground:"transparent",colorSubtleBackgroundHover:we[22],colorSubtleBackgroundPressed:we[18],colorSubtleBackgroundSelected:we[20],colorSubtleBackgroundLightAlphaHover:VC[80],colorSubtleBackgroundLightAlphaPressed:VC[50],colorSubtleBackgroundLightAlphaSelected:"transparent",colorSubtleBackgroundInverted:"transparent",colorSubtleBackgroundInvertedHover:ba[10],colorSubtleBackgroundInvertedPressed:ba[30],colorSubtleBackgroundInvertedSelected:ba[20],colorTransparentBackground:"transparent",colorTransparentBackgroundHover:"transparent",colorTransparentBackgroundPressed:"transparent",colorTransparentBackgroundSelected:"transparent",colorNeutralBackgroundDisabled:we[8],colorNeutralBackgroundInvertedDisabled:ya[10],colorNeutralStencil1:we[34],colorNeutralStencil2:we[20],colorNeutralStencil1Alpha:ya[10],colorNeutralStencil2Alpha:ya[5],colorBackgroundOverlay:ba[50],colorScrollbarOverlay:ya[60],colorBrandBackground:e[70],colorBrandBackgroundHover:e[80],colorBrandBackgroundPressed:e[40],colorBrandBackgroundSelected:e[60],colorCompoundBrandBackground:e[100],colorCompoundBrandBackgroundHover:e[110],colorCompoundBrandBackgroundPressed:e[90],colorBrandBackgroundStatic:e[80],colorBrandBackground2:e[40],colorBrandBackgroundInverted:ht,colorBrandBackgroundInvertedHover:e[160],colorBrandBackgroundInvertedPressed:e[140],colorBrandBackgroundInvertedSelected:e[150],colorNeutralStrokeAccessible:we[68],colorNeutralStrokeAccessibleHover:we[74],colorNeutralStrokeAccessiblePressed:we[70],colorNeutralStrokeAccessibleSelected:e[100],colorNeutralStroke1:we[40],colorNeutralStroke1Hover:we[46],colorNeutralStroke1Pressed:we[42],colorNeutralStroke1Selected:we[44],colorNeutralStroke2:we[32],colorNeutralStroke3:we[24],colorNeutralStrokeOnBrand:we[16],colorNeutralStrokeOnBrand2:ht,colorNeutralStrokeOnBrand2Hover:ht,colorNeutralStrokeOnBrand2Pressed:ht,colorNeutralStrokeOnBrand2Selected:ht,colorBrandStroke1:e[100],colorBrandStroke2:e[50],colorCompoundBrandStroke:e[90],colorCompoundBrandStrokeHover:e[100],colorCompoundBrandStrokePressed:e[80],colorNeutralStrokeDisabled:we[26],colorNeutralStrokeInvertedDisabled:ya[40],colorTransparentStroke:"transparent",colorTransparentStrokeInteractive:"transparent",colorTransparentStrokeDisabled:"transparent",colorStrokeFocus1:x_,colorStrokeFocus2:ht,colorNeutralShadowAmbient:"rgba(0,0,0,0.24)",colorNeutralShadowKey:"rgba(0,0,0,0.28)",colorNeutralShadowAmbientLighter:"rgba(0,0,0,0.12)",colorNeutralShadowKeyLighter:"rgba(0,0,0,0.14)",colorNeutralShadowAmbientDarker:"rgba(0,0,0,0.40)",colorNeutralShadowKeyDarker:"rgba(0,0,0,0.48)",colorBrandShadowAmbient:"rgba(0,0,0,0.30)",colorBrandShadowKey:"rgba(0,0,0,0.25)"}),rae=e=>{const t=nae(e);return{...RO,...PO,...MO,...jO,...LO,...UO,...zO,...HO,...DO,...OO,...t,...tae,...Hv(t.colorNeutralShadowAmbient,t.colorNeutralShadowKey),...Hv(t.colorBrandShadowAmbient,t.colorBrandShadowKey,"Brand")}},oae=rae(qO),LT={root:"fui-FluentProvider"},iae=KR({root:{sj55zd:"f19n0e5",De3pzq:"fxugw4r",fsow6f:["f1o700av","fes3tcz"],Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"}},{d:[".f19n0e5{color:var(--colorNeutralForeground1);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f1o700av{text-align:left;}",".fes3tcz{text-align:right;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}"]}),aae=e=>{const t=ep(),n=iae({dir:e.dir,renderer:t});return e.root.className=et(LT.root,e.themeClassName,n.root,e.root.className),e},sae=n0["useInsertionEffect"]?n0["useInsertionEffect"]:us,lae=(e,t)=>{if(!e)return;const n=e.createElement("style");return Object.keys(t).forEach(r=>{n.setAttribute(r,t[r])}),e.head.appendChild(n),n},uae=(e,t)=>{const n=e.sheet;n&&(n.cssRules.length>0&&n.deleteRule(0),n.insertRule(t,0))},cae=e=>{const{targetDocument:t,theme:n}=e,r=ep(),o=T.useRef(),i=lo(LT.root),a=r.styleElementAttributes,s=T.useMemo(()=>n?Object.keys(n).reduce((u,d)=>(u+=`--${d}: ${n[d]}; `,u),""):"",[n]),l=`.${i.replace(/:/g,"\\:")} { ${s} }`;return sae(()=>{if(o.current=lae(t,{...a,id:i}),o.current)return uae(o.current,l),()=>{var u;(u=o.current)===null||u===void 0||u.remove()}},[i,t,l,a]),i},fae=(e,t)=>{const n=Oo(),r=dae(),o=tO(),{applyStylesToPortals:i=!0,dir:a=n.dir,targetDocument:s=n.targetDocument,theme:l,overrides_unstable:u={}}=e,d=YC(r,l),h=YC(o,u);return T.useEffect(()=>{},[]),{applyStylesToPortals:i,dir:a,targetDocument:s,theme:d,overrides_unstable:h,themeClassName:cae({theme:d,targetDocument:s}),components:{root:"div"},root:vr("div",{...e,dir:a,ref:cs(t,FO())})}};function YC(e,t){return e&&t?{...e,...t}:e||t}function dae(){return T.useContext(YR)}function hae(e){const{applyStylesToPortals:t,dir:n,root:r,targetDocument:o,theme:i,themeClassName:a,overrides_unstable:s}=e,l=T.useMemo(()=>({dir:n,targetDocument:o}),[n,o]),[u]=T.useState(()=>({}));return{overrides_unstable:s,provider:l,textDirection:n,tooltip:u,theme:i,themeClassName:t?r.className:a}}const ny=T.forwardRef((e,t)=>{const n=fae(e,t);aae(n);const r=hae(n);return uoe(n,r)});ny.displayName="FluentProvider";const pae=e=>n=>{const r=T.useRef(n.value),o=T.useRef(0),i=T.useRef();return i.current||(i.current={value:r,version:o,listeners:[]}),us(()=>{r.current=n.value,o.current+=1,wE.unstable_runWithPriority(wE.unstable_NormalPriority,()=>{i.current.listeners.forEach(a=>{a([o.current,n.value])})})},[n.value]),T.createElement(e,{value:i.current},n.children)},ry=e=>{const t=T.createContext({value:{current:e},version:{current:-1},listeners:[]});return t.Provider=pae(t.Provider),delete t.Consumer,t},oy=(e,t)=>{const n=T.useContext(e),{value:{current:r},version:{current:o},listeners:i}=n,a=t(r),[s,l]=T.useReducer((u,d)=>{if(!d)return[r,a];if(d[0]<=o)return Um(u[1],a)?u:[r,a];try{if(Um(u[0],d[1]))return u;const h=t(d[1]);return Um(u[1],h)?u:[d[1],h]}catch{}return[u[0],u[1]]},[r,a]);return Um(s[1],a)||l(void 0),us(()=>(i.push(l),()=>{const u=i.indexOf(l);i.splice(u,1)}),[i]),s[1]};function mae(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}const Um=typeof Object.is=="function"?Object.is:mae;function jT(e){const t=T.useContext(e);return t.version?t.version.current!==-1:!1}const Uh="Enter",id=" ",gae="Tab",vae="ArrowDown",$O="ArrowLeft",WO="ArrowRight",ap="Escape";function Gd(e,t){const{disabled:n,disabledFocusable:r=!1,["aria-disabled"]:o,onClick:i,onKeyDown:a,onKeyUp:s,...l}=t??{},u=typeof o=="string"?o==="true":o,d=n||r||u,h=Et(v=>{d?(v.preventDefault(),v.stopPropagation()):i==null||i(v)}),p=Et(v=>{if(a==null||a(v),v.isDefaultPrevented())return;const _=v.key;if(d&&(_===Uh||_===id)){v.preventDefault(),v.stopPropagation();return}if(_===id){v.preventDefault();return}else _===Uh&&(v.preventDefault(),v.currentTarget.click())}),m=Et(v=>{if(s==null||s(v),v.isDefaultPrevented())return;const _=v.key;if(d&&(_===Uh||_===id)){v.preventDefault(),v.stopPropagation();return}_===id&&(v.preventDefault(),v.currentTarget.click())});if(e==="button"||e===void 0)return{...l,disabled:n&&!r,"aria-disabled":r?!0:u,onClick:r?void 0:h,onKeyUp:r?void 0:s,onKeyDown:r?void 0:a};{const v={role:"button",tabIndex:n&&!r?void 0:0,...l,onClick:h,onKeyUp:m,onKeyDown:p,"aria-disabled":n||r||u};return e==="a"&&d&&(v.href=void 0),v}}const bae=(e,t)=>{var n;const r=$t(e,t),o=Gd((n=r==null?void 0:r.as)!==null&&n!==void 0?n:"button",r);return r&&o},Lg="data-make-styles-bucket",C_=7,zT="___",yae=zT.length+C_,A_={},Eae=0,_ae=1;function Tae(e){const t=e.length;if(t===C_)return e;for(let n=t;n<C_;n++)e+="0";return e}function GO(e,t,n=[]){return zT+Tae(Ud(e+t))}function KO(e,t){let n="";for(const r in e){const o=e[r];if(o){const i=Array.isArray(o);t==="rtl"?n+=(i?o[1]:o)+" ":n+=(i?o[0]:o)+" "}}return n.slice(0,-1)}function QC(e,t){const n={};for(const r in e){const o=KO(e[r],t),i=GO(o,t),a=i+" "+o;A_[i]=[e[r],t],n[r]=a}return n}const XC={};function N_(){let e=null,t="",n="";const r=new Array(arguments.length);for(let u=0;u<arguments.length;u++){const d=arguments[u];if(typeof d=="string"){const h=d.indexOf(zT);if(h===-1)t+=d+" ";else{const p=d.substr(h,yae);h>0&&(t+=d.slice(0,h)),n+=p,r[u]=p}}}if(n==="")return t.slice(0,-1);const o=XC[n];if(o!==void 0)return t+o;const i=[];for(let u=0;u<arguments.length;u++){const d=r[u];if(d){const h=A_[d];h&&(i.push(h[Eae]),e=h[_ae])}}const a=Object.assign.apply(Object,[{}].concat(i));let s=KO(a,e);const l=GO(s,e,r);return s=l+" "+s,XC[n]=s,A_[l]=[a,e],t+s}function wae(e){return Array.isArray(e)?e:[e]}function kae(e,t,n){const r=[];if(n[Lg]=t,e)for(const i in n)e.setAttribute(i,n[i]);function o(i){return e!=null&&e.sheet?e.sheet.insertRule(i,e.sheet.cssRules.length):r.push(i)}return{elementAttributes:n,insertRule:o,element:e,bucketName:t,cssRules(){return e!=null&&e.sheet?Array.from(e.sheet.cssRules).map(i=>i.cssText):r}}}const Sae=["d","l","v","w","f","i","h","a","k","t","m"],ZC=Sae.reduce((e,t,n)=>(e[t]=n,e),{});function xae(e,t,n,r={},o){let i=e;if(e==="m"&&o&&(i=e+o.m),!n.stylesheets[i]){const a=t&&t.createElement("style");e==="m"&&o&&(r.media=o.m);const s=kae(a,e,r);if(n.stylesheets[i]=s,t&&a){const l=Cae(t,e,n,o);t.head.insertBefore(a,l)}}return n.stylesheets[i]}function Cae(e,t,n,r){const o=ZC[t];let i=s=>o-ZC[s.getAttribute(Lg)],a=e.head.querySelectorAll(`[${Lg}]`);if(t==="m"&&r){const s=e.head.querySelectorAll(`[${Lg}="${t}"]`);s.length&&(a=s,i=l=>n.compareMediaQueries(r.m,l.media))}for(const s of a)if(i(s)<0)return s;return null}let Aae=0;const Nae=(e,t)=>e<t?-1:e>t?1:0;function Fae(e=typeof document>"u"?void 0:document,t={}){const{unstable_filterCSSRule:n,compareMediaQueries:r=Nae}=t,o={insertionCache:{},stylesheets:{},compareMediaQueries:r,id:`d${Aae++}`,insertCSSRules(i){for(const a in i){const s=i[a];for(let l=0,u=s.length;l<u;l++){const[d,h]=wae(s[l]),p=xae(a,e,o,t.styleElementAttributes,h);if(!o.insertionCache[d]){o.insertionCache[d]=a;try{n?n(d)&&p.insertRule(d):p.insertRule(d)}catch{}}}}}};return o}function Iae(e,t){const n={};let r=null,o=null;function i(a){const{dir:s,renderer:l}=a,u=s==="ltr",d=u?l.id:l.id+"r";return u?r===null&&(r=QC(e,s)):o===null&&(o=QC(e,s)),n[d]===void 0&&(l.insertCSSRules(t),n[d]=!0),u?r:o}return i}const Bae=T.createContext(Fae());function Rae(){return T.useContext(Bae)}const Oae=T.createContext("ltr");function Dae(){return T.useContext(Oae)}function VO(e,t){const n=Iae(e,t);return function(){const o=Dae(),i=Rae();return n({dir:o,renderer:i})}}const Pae=VO({root:{mc9l5x:"f1w7gpdv",Bg96gwp:"fez10in",ycbfsm:"fg4l7m0"}},{d:[".f1w7gpdv{display:inline;}",".fez10in{line-height:0;}"],t:["@media (forced-colors: active){.fg4l7m0{forced-color-adjust:auto;}}"]}),Mae=e=>{const{title:t,primaryFill:n="currentColor"}=e,r=pl(e,["title","primaryFill"]),o=Object.assign(Object.assign({},r),{title:void 0,fill:n}),i=Pae();return o.className=N_(i.root,o.className),t&&(o["aria-label"]=t),!o["aria-label"]&&!o["aria-labelledby"]?o["aria-hidden"]=!0:o.role="img",o},Lae=(e,t)=>{const n=r=>{const o=Mae(r);return T.createElement(e,Object.assign({},o))};return n.displayName=t,n},Ge=Lae,jae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:"1em",height:"1em",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M12.27 15.8a.75.75 0 0 1-1.06-.03l-5-5.25a.75.75 0 0 1 0-1.04l5-5.25a.75.75 0 1 1 1.08 1.04L7.8 10l4.5 4.73c.29.3.28.78-.02 1.06Z",fill:t}))},zae=Ge(jae,"ChevronLeftFilled"),Hae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:"1em",height:"1em",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M12.35 15.85a.5.5 0 0 1-.7 0L6.16 10.4a.55.55 0 0 1 0-.78l5.49-5.46a.5.5 0 1 1 .7.7L7.2 10l5.16 5.15c.2.2.2.5 0 .7Z",fill:t}))},Uae=Ge(Hae,"ChevronLeftRegular"),qae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:"1em",height:"1em",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M7.73 4.2a.75.75 0 0 1 1.06.03l5 5.25c.28.3.28.75 0 1.04l-5 5.25a.75.75 0 1 1-1.08-1.04L12.2 10l-4.5-4.73a.75.75 0 0 1 .02-1.06Z",fill:t}))},$ae=Ge(qae,"ChevronRightFilled"),Wae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:"1em",height:"1em",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M7.65 4.15c.2-.2.5-.2.7 0l5.49 5.46c.21.22.21.57 0 .78l-5.49 5.46a.5.5 0 0 1-.7-.7L12.8 10 7.65 4.85a.5.5 0 0 1 0-.7Z",fill:t}))},Gae=Ge(Wae,"ChevronRightRegular"),Kae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:"1em",height:"1em",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M10 2a8 8 0 1 0 0 16 8 8 0 0 0 0-16Z",fill:t}))},Vae=Ge(Kae,"CircleFilled"),Yae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:"1em",height:"1em",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M10 2a4 4 0 1 0 0 8 4 4 0 0 0 0-8ZM7 6a3 3 0 1 1 6 0 3 3 0 0 1-6 0Zm-2 5a2 2 0 0 0-2 2c0 1.7.83 2.97 2.13 3.8A9.14 9.14 0 0 0 10 18c1.85 0 3.58-.39 4.87-1.2A4.35 4.35 0 0 0 17 13a2 2 0 0 0-2-2H5Zm-1 2a1 1 0 0 1 1-1h10a1 1 0 0 1 1 1c0 1.3-.62 2.28-1.67 2.95A8.16 8.16 0 0 1 10 17a8.16 8.16 0 0 1-4.33-1.05A3.36 3.36 0 0 1 4 13Z",fill:t}))},Qae=Ge(Yae,"PersonRegular"),Xae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M11.88 3H12a1 1 0 0 1 1 .88V11h7a1 1 0 0 1 1 .88V12a1 1 0 0 1-.88 1H13v7a1 1 0 0 1-.88 1H12a1 1 0 0 1-1-.88V13H4a1 1 0 0 1-1-.88V12a1 1 0 0 1 .88-1H11V4a1 1 0 0 1 .88-1H12h-.12Z",fill:t}))},Zae=Ge(Xae,"Add24Filled"),Jae=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M11.75 3c.38 0 .7.28.74.65l.01.1V11h7.25a.75.75 0 0 1 .1 1.5H12.5v7.25a.75.75 0 0 1-1.49.1V12.5H3.74a.75.75 0 0 1-.1-1.5H11V3.75c0-.41.34-.75.75-.75Z",fill:t}))},ese=Ge(Jae,"Add24Regular"),tse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M14.85 1.15c.2.2.2.5 0 .7L10.9 5.81a4.78 4.78 0 0 0-.71-.7l3.96-3.96c.2-.2.5-.2.7 0ZM4.65 6.19l-.39.36 5.2 5.2.4-.4a3.67 3.67 0 1 0-5.2-5.16ZM1.3 8.04l2.1-.95 5.52 5.52-.95 2.1a.5.5 0 0 1-.81.14l-6-6a.5.5 0 0 1 .14-.8Z",fill:t}))},YO=Ge(tse,"Broom16Filled"),nse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M1 6a5 5 0 1 1 10 0A5 5 0 0 1 1 6Zm7.35-.9a.5.5 0 1 0-.7-.7L5.5 6.54 4.35 5.4a.5.5 0 1 0-.7.7l1.5 1.5c.2.2.5.2.7 0l2.5-2.5Z",fill:t}))},rse=Ge(nse,"CheckmarkCircle12Filled"),ose=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5.5 4.63V17.25c0 1.8 1.46 3.25 3.25 3.25h8.62c-.31.88-1.15 1.5-2.13 1.5H8.75A4.75 4.75 0 0 1 4 17.25V6.75c0-.98.63-1.81 1.5-2.12ZM17.75 2C18.99 2 20 3 20 4.25v13c0 1.24-1 2.25-2.25 2.25h-9c-1.24 0-2.25-1-2.25-2.25v-13C6.5 3.01 7.5 2 8.75 2h9Zm0 1.5h-9a.75.75 0 0 0-.75.75v13c0 .41.34.75.75.75h9c.41 0 .75-.34.75-.75v-13a.75.75 0 0 0-.75-.75Z",fill:t}))},QO=Ge(ose,"Copy24Regular"),ise=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M10 5h4a2 2 0 1 0-4 0ZM8.5 5a3.5 3.5 0 1 1 7 0h5.75a.75.75 0 0 1 0 1.5h-1.32l-1.17 12.11A3.75 3.75 0 0 1 15.03 22H8.97a3.75 3.75 0 0 1-3.73-3.39L4.07 6.5H2.75a.75.75 0 0 1 0-1.5H8.5Zm2 4.75a.75.75 0 0 0-1.5 0v7.5a.75.75 0 0 0 1.5 0v-7.5ZM14.25 9c.41 0 .75.34.75.75v7.5a.75.75 0 0 1-1.5 0v-7.5c0-.41.34-.75.75-.75Zm-7.52 9.47a2.25 2.25 0 0 0 2.24 2.03h6.06c1.15 0 2.12-.88 2.24-2.03L18.42 6.5H5.58l1.15 11.97Z",fill:t}))},ase=Ge(ise,"Delete24Regular"),sse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"m2.59 2.72.06-.07a.5.5 0 0 1 .63-.06l.07.06L8 7.29l4.65-4.64a.5.5 0 0 1 .7.7L8.71 8l4.64 4.65c.18.17.2.44.06.63l-.06.07a.5.5 0 0 1-.63.06l-.07-.06L8 8.71l-4.65 4.64a.5.5 0 0 1-.7-.7L7.29 8 2.65 3.35a.5.5 0 0 1-.06-.63l.06-.07-.06.07Z",fill:t}))},lse=Ge(sse,"Dismiss16Regular"),use=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"m4.21 4.39.08-.1a1 1 0 0 1 1.32-.08l.1.08L12 10.6l6.3-6.3a1 1 0 1 1 1.4 1.42L13.42 12l6.3 6.3a1 1 0 0 1 .08 1.31l-.08.1a1 1 0 0 1-1.32.08l-.1-.08L12 13.4l-6.3 6.3a1 1 0 0 1-1.4-1.42L10.58 12l-6.3-6.3a1 1 0 0 1-.08-1.31l.08-.1-.08.1Z",fill:t}))},cse=Ge(use,"Dismiss24Filled"),fse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"m4.4 4.55.07-.08a.75.75 0 0 1 .98-.07l.08.07L12 10.94l6.47-6.47a.75.75 0 1 1 1.06 1.06L13.06 12l6.47 6.47c.27.27.3.68.07.98l-.07.08a.75.75 0 0 1-.98.07l-.08-.07L12 13.06l-6.47 6.47a.75.75 0 0 1-1.06-1.06L10.94 12 4.47 5.53a.75.75 0 0 1-.07-.98l.07-.08-.07.08Z",fill:t}))},dse=Ge(fse,"Dismiss24Regular"),hse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M15.9 3.05a3.58 3.58 0 1 1 5.05 5.06l-.89.89L15 3.94l.9-.9ZM13.93 5l-10 10c-.4.4-.7.92-.82 1.48l-1.1 4.6a.75.75 0 0 0 .9.9l4.6-1.1A3.1 3.1 0 0 0 9 20.06l10-10L13.94 5Z",fill:t}))},pse=Ge(hse,"Edit24Filled"),mse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 11A5 5 0 1 0 6 1a5 5 0 0 0 0 10Zm-.75-2.75a.75.75 0 1 1 1.5 0 .75.75 0 0 1-1.5 0Zm.26-4.84a.5.5 0 0 1 .98 0l.01.09v2.59a.5.5 0 0 1-1 0V3.41Z",fill:t}))},gse=Ge(mse,"ErrorCircle12Filled"),vse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M3.75 3a.75.75 0 0 0-.75.75V5.5a.5.5 0 0 1-1 0V3.75C2 2.78 2.78 2 3.75 2H5.5a.5.5 0 0 1 0 1H3.75ZM10 2.5c0-.28.22-.5.5-.5h1.75c.97 0 1.75.78 1.75 1.75V5.5a.5.5 0 0 1-1 0V3.75a.75.75 0 0 0-.75-.75H10.5a.5.5 0 0 1-.5-.5ZM2.5 10c.28 0 .5.22.5.5v1.75c0 .41.34.75.75.75H5.5a.5.5 0 0 1 0 1H3.75C2.78 14 2 13.22 2 12.25V10.5c0-.28.22-.5.5-.5Zm11 0c.28 0 .5.22.5.5v1.75c0 .97-.78 1.75-1.75 1.75H10.5a.5.5 0 0 1 0-1h1.75c.41 0 .75-.34.75-.75V10.5c0-.28.22-.5.5-.5Z",fill:t}))},bse=Ge(vse,"FullScreenMaximize16Regular"),yse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M11 4a1 1 0 0 0 1 1h1.5a.5.5 0 0 1 0 1H12a2 2 0 0 1-2-2V2.5a.5.5 0 0 1 1 0V4Zm0 8a1 1 0 0 1 1-1h1.5a.5.5 0 0 0 0-1H12a2 2 0 0 0-2 2v1.5a.5.5 0 0 0 1 0V12Zm-7-1a1 1 0 0 1 1 1v1.5a.5.5 0 0 0 1 0V12a2 2 0 0 0-2-2H2.5a.5.5 0 0 0 0 1H4Zm1-7a1 1 0 0 1-1 1H2.5a.5.5 0 0 0 0 1H4a2 2 0 0 0 2-2V2.5a.5.5 0 0 0-1 0V4Z",fill:t}))},Ese=Ge(yse,"FullScreenMinimize16Regular"),_se=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8 7c.28 0 .5.22.5.5v3a.5.5 0 0 1-1 0v-3c0-.28.22-.5.5-.5Zm0-.75a.75.75 0 1 0 0-1.5.75.75 0 0 0 0 1.5ZM2 8a6 6 0 1 1 12 0A6 6 0 0 1 2 8Zm6-5a5 5 0 1 0 0 10A5 5 0 0 0 8 3Z",fill:t}))},Tse=Ge(_se,"Info16Regular"),wse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M12 8a2 2 0 1 1 0-4 2 2 0 0 1 0 4Zm0 6a2 2 0 1 1 0-4 2 2 0 0 1 0 4Zm-2 4a2 2 0 1 0 4 0 2 2 0 0 0-4 0Z",fill:t}))},XO=Ge(wse,"MoreVertical24Filled"),kse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5 10A5 5 0 1 0 5 0a5 5 0 0 0 0 10Zm2.1-5.9L4.85 6.35a.5.5 0 0 1-.7 0l-1-1a.5.5 0 0 1 .7-.7l.65.64 1.9-1.9a.5.5 0 0 1 .7.71Z",fill:t}))},JC=Ge(kse,"PresenceAvailable10Filled"),Sse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5 0a5 5 0 1 0 0 10A5 5 0 0 0 5 0ZM1 5a4 4 0 1 1 8 0 4 4 0 0 1-8 0Zm6.1-1.6c.2.2.2.5 0 .7L4.85 6.35a.5.5 0 0 1-.7 0l-1-1a.5.5 0 1 1 .7-.7l.65.64 1.9-1.9c.2-.19.5-.19.7 0Z",fill:t}))},e6=Ge(Sse,"PresenceAvailable10Regular"),xse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 12A6 6 0 1 0 6 0a6 6 0 0 0 0 12Zm2.53-6.72L5.78 8.03c-.3.3-.77.3-1.06 0l-1-1a.75.75 0 0 1 1.06-1.06l.47.47 2.22-2.22a.75.75 0 0 1 1.06 1.06Z",fill:t}))},Cse=Ge(xse,"PresenceAvailable12Filled"),Ase=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 0a6 6 0 1 0 0 12A6 6 0 0 0 6 0ZM1.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0Zm7.03-1.78c.3.3.3.77 0 1.06L5.78 8.03c-.3.3-.77.3-1.06 0l-1-1a.75.75 0 0 1 1.06-1.06l.47.47 2.22-2.22c.3-.3.77-.3 1.06 0Z",fill:t}))},Nse=Ge(Ase,"PresenceAvailable12Regular"),Fse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16Zm3.7-9.3-4 4a1 1 0 0 1-1.41 0l-2-2a1 1 0 1 1 1.42-1.4L7 8.58l3.3-3.3a1 1 0 0 1 1.4 1.42Z",fill:t}))},X2=Ge(Fse,"PresenceAvailable16Filled"),Ise=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M11.7 6.7a1 1 0 0 0-1.4-1.4L7 8.58l-1.3-1.3a1 1 0 0 0-1.4 1.42l2 2a1 1 0 0 0 1.4 0l4-4ZM0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6a6 6 0 1 0 0 12A6 6 0 0 0 8 2Z",fill:t}))},Z2=Ge(Ise,"PresenceAvailable16Regular"),Bse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5 10A5 5 0 1 0 5 0a5 5 0 0 0 0 10Zm0-7v1.8l1.35 1.35a.5.5 0 1 1-.7.7l-1.5-1.5A.5.5 0 0 1 4 5V3a.5.5 0 0 1 1 0Z",fill:t}))},t6=Ge(Bse,"PresenceAway10Filled"),Rse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 12A6 6 0 1 0 6 0a6 6 0 0 0 0 12Zm.5-8.75v2.4l1.49 1.28A.75.75 0 1 1 7 8.07l-1.75-1.5A.75.75 0 0 1 5 6V3.25a.75.75 0 0 1 1.5 0Z",fill:t}))},Ose=Ge(Rse,"PresenceAway12Filled"),Dse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16Zm.5-11.5v3.02l2.12 1.7a1 1 0 1 1-1.24 1.56l-2.5-2A1 1 0 0 1 6.5 8V4.5a1 1 0 0 1 2 0Z",fill:t}))},J2=Ge(Dse,"PresenceAway16Filled"),Pse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M10 5A5 5 0 1 0 0 5a5 5 0 0 0 10 0ZM9 5a4 4 0 0 1-6.45 3.16l5.61-5.61C8.69 3.22 9 4.08 9 5ZM7.45 1.84 1.84 7.45a4 4 0 0 1 5.61-5.61Z",fill:t}))},n6=Ge(Pse,"PresenceBlocked10Regular"),Mse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M12 6A6 6 0 1 1 0 6a6 6 0 0 1 12 0Zm-1.5 0c0-.97-.3-1.87-.83-2.6L3.39 9.66A4.5 4.5 0 0 0 10.5 6ZM8.6 2.33a4.5 4.5 0 0 0-6.28 6.28l6.29-6.28Z",fill:t}))},Lse=Ge(Mse,"PresenceBlocked12Regular"),jse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0Zm-2 0c0-1.3-.41-2.5-1.1-3.48L4.51 12.9A6 6 0 0 0 14 8Zm-2.52-4.9a6 6 0 0 0-8.37 8.37l8.37-8.36Z",fill:t}))},e9=Ge(jse,"PresenceBlocked16Regular"),zse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M10 5A5 5 0 1 1 0 5a5 5 0 0 1 10 0Z",fill:t}))},r6=Ge(zse,"PresenceBusy10Filled"),Hse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M12 6A6 6 0 1 1 0 6a6 6 0 0 1 12 0Z",fill:t}))},Use=Ge(Hse,"PresenceBusy12Filled"),qse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M16 8A8 8 0 1 1 0 8a8 8 0 0 1 16 0Z",fill:t}))},t9=Ge(qse,"PresenceBusy16Filled"),$se=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5 10A5 5 0 1 0 5 0a5 5 0 0 0 0 10ZM3.5 4.5h3a.5.5 0 0 1 0 1h-3a.5.5 0 0 1 0-1Z",fill:t}))},o6=Ge($se,"PresenceDnd10Filled"),Wse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5 0a5 5 0 1 0 0 10A5 5 0 0 0 5 0ZM1 5a4 4 0 1 1 8 0 4 4 0 0 1-8 0Zm2 0c0-.28.22-.5.5-.5h3a.5.5 0 0 1 0 1h-3A.5.5 0 0 1 3 5Z",fill:t}))},i6=Ge(Wse,"PresenceDnd10Regular"),Gse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 12A6 6 0 1 0 6 0a6 6 0 0 0 0 12ZM3.75 5.25h4.5a.75.75 0 0 1 0 1.5h-4.5a.75.75 0 0 1 0-1.5Z",fill:t}))},Kse=Ge(Gse,"PresenceDnd12Filled"),Vse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 0a6 6 0 1 0 0 12A6 6 0 0 0 6 0ZM1.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0ZM3 6c0-.41.34-.75.75-.75h4.5a.75.75 0 0 1 0 1.5h-4.5A.75.75 0 0 1 3 6Z",fill:t}))},Yse=Ge(Vse,"PresenceDnd12Regular"),Qse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8 16A8 8 0 1 0 8 0a8 8 0 0 0 0 16ZM5.25 7h5.5a1 1 0 1 1 0 2h-5.5a1 1 0 1 1 0-2Z",fill:t}))},n9=Ge(Qse,"PresenceDnd16Filled"),Xse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5.25 7a1 1 0 0 0 0 2h5.5a1 1 0 1 0 0-2h-5.5ZM0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6a6 6 0 1 0 0 12A6 6 0 0 0 8 2Z",fill:t}))},r9=Ge(Xse,"PresenceDnd16Regular"),Zse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6.85 3.15c.2.2.2.5 0 .7L5.71 5l1.14 1.15a.5.5 0 1 1-.7.7L5 5.71 3.85 6.85a.5.5 0 1 1-.7-.7L4.29 5 3.15 3.85a.5.5 0 1 1 .7-.7L5 4.29l1.15-1.14c.2-.2.5-.2.7 0ZM0 5a5 5 0 1 1 10 0A5 5 0 0 1 0 5Zm5-4a4 4 0 1 0 0 8 4 4 0 0 0 0-8Z",fill:t}))},a6=Ge(Zse,"PresenceOffline10Regular"),Jse=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8.03 3.97c.3.3.3.77 0 1.06L7.06 6l.97.97a.75.75 0 0 1-1.06 1.06L6 7.06l-.97.97a.75.75 0 0 1-1.06-1.06L4.94 6l-.97-.97a.75.75 0 0 1 1.06-1.06l.97.97.97-.97c.3-.3.77-.3 1.06 0ZM0 6a6 6 0 1 1 12 0A6 6 0 0 1 0 6Zm6-4.5a4.5 4.5 0 1 0 0 9 4.5 4.5 0 0 0 0-9Z",fill:t}))},ele=Ge(Jse,"PresenceOffline12Regular"),tle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M10.7 5.3a1 1 0 0 1 0 1.4L9.42 8l1.3 1.3a1 1 0 0 1-1.42 1.4L8 9.42l-1.3 1.3a1 1 0 0 1-1.4-1.42L6.58 8l-1.3-1.3a1 1 0 0 1 1.42-1.4L8 6.58l1.3-1.3a1 1 0 0 1 1.4 0ZM0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Zm8-6a6 6 0 1 0 0 12A6 6 0 0 0 8 2Z",fill:t}))},o9=Ge(tle,"PresenceOffline16Regular"),nle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5.35 3.85a.5.5 0 1 0-.7-.7l-1.5 1.5a.5.5 0 0 0 0 .7l1.5 1.5a.5.5 0 1 0 .7-.7L4.7 5.5h1.8a.5.5 0 1 0 0-1H4.7l.65-.65ZM5 0a5 5 0 1 0 0 10A5 5 0 0 0 5 0ZM1 5a4 4 0 1 1 8 0 4 4 0 0 1-8 0Z",fill:t}))},s6=Ge(nle,"PresenceOof10Regular"),rle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6.28 4.53a.75.75 0 0 0-1.06-1.06l-2 2c-.3.3-.3.77 0 1.06l2 2a.75.75 0 0 0 1.06-1.06l-.72-.72h2.69a.75.75 0 1 0 0-1.5h-2.7l.73-.72ZM6 0a6 6 0 1 0 0 12A6 6 0 0 0 6 0ZM1.5 6a4.5 4.5 0 1 1 9 0 4.5 4.5 0 0 1-9 0Z",fill:t}))},ole=Ge(rle,"PresenceOof12Regular"),ile=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8.2 6.2a1 1 0 1 0-1.4-1.4L4.3 7.3a1 1 0 0 0 0 1.4l2.5 2.5a1 1 0 0 0 1.4-1.4L7.42 9H11a1 1 0 1 0 0-2H7.41l.8-.8ZM8 0a8 8 0 1 0 0 16A8 8 0 0 0 8 0ZM2 8a6 6 0 1 1 12 0A6 6 0 0 1 2 8Z",fill:t}))},i9=Ge(ile,"PresenceOof16Regular"),ale=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:10,height:10,viewBox:"0 0 10 10",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5 1a4 4 0 1 0 0 8 4 4 0 0 0 0-8ZM0 5a5 5 0 1 1 10 0A5 5 0 0 1 0 5Z",fill:t}))},l6=Ge(ale,"PresenceUnknown10Regular"),sle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M6 1.5a4.5 4.5 0 1 0 0 9 4.5 4.5 0 0 0 0-9ZM0 6a6 6 0 1 1 12 0A6 6 0 0 1 0 6Z",fill:t}))},lle=Ge(sle,"PresenceUnknown12Regular"),ule=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M8 2a6 6 0 1 0 0 12A6 6 0 0 0 8 2ZM0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8Z",fill:t}))},a9=Ge(ule,"PresenceUnknown16Regular"),cle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:16,height:16,viewBox:"0 0 16 16",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M1.72 1.05a.5.5 0 0 0-.71.55l1.4 4.85c.06.18.21.32.4.35l5.69.95c.27.06.27.44 0 .5l-5.69.95a.5.5 0 0 0-.4.35l-1.4 4.85a.5.5 0 0 0 .71.55l13-6.5a.5.5 0 0 0 0-.9l-13-6.5Z",fill:t}))},fle=Ge(cle,"Send16Filled"),dle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5.7 12 2.3 3.27a.75.75 0 0 1 .94-.98l.1.04 18 9c.51.26.54.97.1 1.28l-.1.06-18 9a.75.75 0 0 1-1.07-.85l.03-.1L5.7 12 2.3 3.27 5.7 12ZM4.4 4.54l2.61 6.7 6.63.01c.38 0 .7.28.74.65v.1c0 .38-.27.7-.64.74l-.1.01H7l-2.6 6.7L19.31 12 4.4 4.54Z",fill:t}))},hle=Ge(dle,"Send24Regular"),ple=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:24,height:24,viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M12.01 2.25c.74 0 1.47.1 2.18.25.32.07.55.33.59.65l.17 1.53a1.38 1.38 0 0 0 1.92 1.11l1.4-.61c.3-.13.64-.06.85.17a9.8 9.8 0 0 1 2.2 3.8c.1.3 0 .63-.26.82l-1.24.92a1.38 1.38 0 0 0 0 2.22l1.24.92c.26.19.36.52.27.82a9.8 9.8 0 0 1-2.2 3.8.75.75 0 0 1-.85.17l-1.4-.62a1.38 1.38 0 0 0-1.93 1.12l-.17 1.52a.75.75 0 0 1-.58.65 9.52 9.52 0 0 1-4.4 0 .75.75 0 0 1-.57-.65l-.17-1.52a1.38 1.38 0 0 0-1.93-1.11l-1.4.62a.75.75 0 0 1-.85-.18 9.8 9.8 0 0 1-2.2-3.8c-.1-.3 0-.63.27-.82l1.24-.92a1.38 1.38 0 0 0 0-2.22l-1.24-.92a.75.75 0 0 1-.28-.82 9.8 9.8 0 0 1 2.2-3.8c.23-.23.57-.3.86-.17l1.4.62c.4.17.86.15 1.25-.08.38-.22.63-.6.68-1.04l.17-1.53a.75.75 0 0 1 .58-.65c.72-.16 1.45-.24 2.2-.25Zm0 1.5c-.45 0-.9.04-1.35.12l-.11.97a2.89 2.89 0 0 1-4.02 2.33l-.9-.4A8.3 8.3 0 0 0 4.28 9.1l.8.59a2.88 2.88 0 0 1 0 4.64l-.8.59a8.3 8.3 0 0 0 1.35 2.32l.9-.4a2.88 2.88 0 0 1 4.02 2.32l.1.99c.9.15 1.8.15 2.7 0l.1-.99a2.88 2.88 0 0 1 4.02-2.32l.9.4a8.3 8.3 0 0 0 1.36-2.32l-.8-.59a2.88 2.88 0 0 1 0-4.64l.8-.59a8.3 8.3 0 0 0-1.35-2.32l-.9.4a2.88 2.88 0 0 1-4.02-2.32l-.11-.98c-.45-.08-.9-.11-1.34-.12ZM12 8.25a3.75 3.75 0 1 1 0 7.5 3.75 3.75 0 0 1 0-7.5Zm0 1.5a2.25 2.25 0 1 0 0 4.5 2.25 2.25 0 0 0 0-4.5Z",fill:t}))},mle=Ge(ple,"Settings24Regular"),gle=e=>{const{fill:t="currentColor",className:n}=e;return T.createElement("svg",Object.assign({},e,{width:12,height:12,viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",className:n}),T.createElement("path",{d:"M5.21 1.46a.9.9 0 0 1 1.58 0l4.09 7.17a.92.92 0 0 1-.79 1.37H1.91a.92.92 0 0 1-.79-1.37l4.1-7.17ZM5.5 4.5v1a.5.5 0 0 0 1 0v-1a.5.5 0 0 0-1 0ZM6 6.75a.75.75 0 1 0 0 1.5.75.75 0 0 0 0-1.5Z",fill:t}))},vle=Ge(gle,"Warning12Filled"),ble="fui-Icon-filled",yle="fui-Icon-regular",Ele=VO({root:{mc9l5x:"fjseox"},visible:{mc9l5x:"f1w7gpdv"}},{d:[".fjseox{display:none;}",".f1w7gpdv{display:inline;}"]}),_le=(e,t)=>{const n=r=>{const{className:o,primaryFill:i="currentColor",filled:a}=r,s=pl(r,["className","primaryFill","filled"]),l=Ele();return T.createElement(T.Fragment,null,T.createElement(e,Object.assign({},s,{className:N_(l.root,a&&l.visible,ble,o),fill:i})),T.createElement(t,Object.assign({},s,{className:N_(l.root,!a&&l.visible,yle,o),fill:i})))};return n.displayName="CompoundIcon",n},ZO=_le,Tle=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},t.initials&&T.createElement(t.initials,{...n.initials}),t.icon&&T.createElement(t.icon,{...n.icon}),t.image&&T.createElement(t.image,{...n.image}),t.badge&&T.createElement(t.badge,{...n.badge}),e.activeAriaLabelElement)},wle=/[\(\[\{][^\)\]\}]*[\)\]\}]/g,kle=/[\0-\u001F\!-/:-@\[-`\{-\u00BF\u0250-\u036F\uD800-\uFFFF]/g,Sle=/^\d+[\d\s]*(:?ext|x|)\s*\d+$/i,xle=/\s+/g,Cle=/[\u0600-\u06FF\u0750-\u077F\u08A0-\u08FF\u1100-\u11FF\u3130-\u318F\uA960-\uA97F\uAC00-\uD7AF\uD7B0-\uD7FF\u3040-\u309F\u30A0-\u30FF\u3400-\u4DBF\u4E00-\u9FFF\uF900-\uFAFF]|[\uD840-\uD869][\uDC00-\uDED6]/;function Ale(e,t,n){let r="";const o=e.split(" ");return o.length!==0&&(r+=o[0].charAt(0).toUpperCase()),n||(o.length===2?r+=o[1].charAt(0).toUpperCase():o.length===3&&(r+=o[2].charAt(0).toUpperCase())),t&&r.length>1?r.charAt(1)+r.charAt(0):r}function Nle(e){return e=e.replace(wle,""),e=e.replace(kle,""),e=e.replace(xle," "),e=e.trim(),e}function Fle(e,t,n){return!e||(e=Nle(e),Cle.test(e)||!(n!=null&&n.allowPhoneInitials)&&Sle.test(e))?"":Ale(e,t,n==null?void 0:n.firstInitialOnly)}const Ile=(e,t)=>{const{shape:n="circular",size:r="medium",iconPosition:o="before",appearance:i="filled",color:a="brand"}=e;return{shape:n,size:r,iconPosition:o,appearance:i,color:a,components:{root:"div",icon:"span"},root:vr("div",{ref:t,...e}),icon:$t(e.icon)}},Ble=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},e.iconPosition==="before"&&t.icon&&T.createElement(t.icon,{...n.icon}),e.root.children,e.iconPosition==="after"&&t.icon&&T.createElement(t.icon,{...n.icon}))},Rle={tiny:t6,"extra-small":t6,small:Ose,medium:J2,large:J2,"extra-large":J2},Ole={tiny:e6,"extra-small":e6,small:Nse,medium:Z2,large:Z2,"extra-large":Z2},Dle={tiny:JC,"extra-small":JC,small:Cse,medium:X2,large:X2,"extra-large":X2},Ple={tiny:n6,"extra-small":n6,small:Lse,medium:e9,large:e9,"extra-large":e9},Mle={tiny:r6,"extra-small":r6,small:Use,medium:t9,large:t9,"extra-large":t9},Lle={tiny:o6,"extra-small":o6,small:Kse,medium:n9,large:n9,"extra-large":n9},jle={tiny:i6,"extra-small":i6,small:Yse,medium:r9,large:r9,"extra-large":r9},zle={tiny:s6,"extra-small":s6,small:ole,medium:i9,large:i9,"extra-large":i9},u6={tiny:a6,"extra-small":a6,small:ele,medium:o9,large:o9,"extra-large":o9},c6={tiny:l6,"extra-small":l6,small:lle,medium:a9,large:a9,"extra-large":a9},Hle=(e,t,n)=>{switch(e){case"available":return t?Ole[n]:Dle[n];case"away":return t?u6[n]:Rle[n];case"blocked":return Ple[n];case"busy":return t?c6[n]:Mle[n];case"do-not-disturb":return t?jle[n]:Lle[n];case"offline":return u6[n];case"out-of-office":return zle[n];case"unknown":return c6[n]}},f6={busy:"busy","out-of-office":"out of office",away:"away",available:"available",offline:"offline","do-not-disturb":"do not disturb",unknown:"unknown",blocked:"blocked"},Ule=(e,t)=>{const{size:n="medium",status:r="available",outOfOffice:o=!1}=e,i=f6[r],a=e.outOfOffice&&e.status!=="out-of-office"?` ${f6["out-of-office"]}`:"",s=Hle(r,o,n);return{...Ile({"aria-label":i+a,role:"img",...e,size:n,icon:$t(e.icon,{defaultProps:{children:s?T.createElement(s,null):null},required:!0})},t),status:r,outOfOffice:o}},d6={root:"fui-PresenceBadge",icon:"fui-PresenceBadge__icon"},qle=e=>e==="busy"||e==="do-not-disturb"||e==="unknown"||e==="blocked",$le=pt({root:{z8tnut:"f1g0x7ka",z189sj:["fhxju0i","f1cnd47f"],Byoj8tv:"f1qch9an",uwmqm3:["f1cnd47f","fhxju0i"],mc9l5x:"ftuwxu6",B7ck84d:"f1ewtqcl",Bt984gj:"f122n59",Brf1p80:"f4d9j23",Bhmb4qv:"fb8jth9",Bbmb7ep:["f8fbkgy","f1nfllo7"],Beyfa6y:["f1nfllo7","f8fbkgy"],B7oj6ja:["f1djnp8u","f1s8kh49"],Btl43ni:["f1s8kh49","f1djnp8u"],De3pzq:"fxugw4r"},statusBusy:{sj55zd:"fvi85wt"},statusAway:{sj55zd:"f14k8a89"},statusAvailable:{sj55zd:"fqa5hgp"},statusOffline:{sj55zd:"f11d4kpn"},statusOutOfOffice:{sj55zd:"fdce8r3"},outOfOffice:{sj55zd:"fr0bkrk"},outOfOfficeAvailable:{sj55zd:"fqa5hgp"},outOfOfficeBusy:{sj55zd:"fvi85wt"},outOfOfficeAway:{sj55zd:"f14k8a89"},tiny:{Bubjx69:"f9ikmtg",a9b677:"f16dn6v3",B5pe6w7:"fab5kbq",p4uzdd:"f1ms1d91"},large:{Bubjx69:"f9ikmtg",a9b677:"f64fuq3",B5pe6w7:"f1vfi1yj",p4uzdd:"f15s34gz"},extraLarge:{Bubjx69:"f9ikmtg",a9b677:"f1w9dchk",B5pe6w7:"f14efy9b",p4uzdd:"fhipgdu"}},{d:[".f1g0x7ka{padding-top:0;}",".fhxju0i{padding-right:0;}",".f1cnd47f{padding-left:0;}",".f1qch9an{padding-bottom:0;}",".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}",".f1ewtqcl{box-sizing:border-box;}",".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}",".fb8jth9 span{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f8fbkgy{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1nfllo7{border-bottom-left-radius:var(--borderRadiusCircular);}",".f1djnp8u{border-top-right-radius:var(--borderRadiusCircular);}",".f1s8kh49{border-top-left-radius:var(--borderRadiusCircular);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".fvi85wt{color:var(--colorPaletteRedBackground3);}",".f14k8a89{color:var(--colorPaletteMarigoldBackground3);}",".fqa5hgp{color:var(--colorPaletteLightGreenForeground3);}",".f11d4kpn{color:var(--colorNeutralForeground3);}",".fdce8r3{color:var(--colorPaletteBerryForeground3);}",".fr0bkrk{color:var(--colorNeutralBackground1);}",".f9ikmtg{aspect-ratio:1;}",".f16dn6v3{width:6px;}",".fab5kbq svg{width:6px!important;}",".f1ms1d91 svg{height:6px!important;}",".f64fuq3{width:20px;}",".f1vfi1yj svg{width:20px!important;}",".f15s34gz svg{height:20px!important;}",".f1w9dchk{width:28px;}",".f14efy9b svg{width:28px!important;}",".fhipgdu svg{height:28px!important;}"]}),Wle=e=>{const t=$le(),n=qle(e.status);return e.root.className=et(d6.root,t.root,n&&t.statusBusy,e.status==="away"&&t.statusAway,e.status==="available"&&t.statusAvailable,e.status==="offline"&&t.statusOffline,e.status==="out-of-office"&&t.statusOutOfOffice,e.outOfOffice&&t.outOfOffice,e.outOfOffice&&e.status==="available"&&t.outOfOfficeAvailable,e.outOfOffice&&n&&t.outOfOfficeBusy,e.outOfOffice&&e.status==="away"&&t.outOfOfficeAway,e.outOfOffice&&e.status==="offline"&&t.statusOffline,e.outOfOffice&&e.status==="out-of-office"&&t.statusOutOfOffice,e.size==="tiny"&&t.tiny,e.size==="large"&&t.large,e.size==="extra-large"&&t.extraLarge,e.root.className),e.icon&&(e.icon.className=et(d6.icon,e.icon.className)),e},JO=T.forwardRef((e,t)=>{const n=Ule(e,t);return Wle(n),Ble(n)});JO.displayName="PresenceBadge";const eD=T.createContext(void 0),Gle={};eD.Provider;const Kle=()=>{var e;return(e=T.useContext(eD))!==null&&e!==void 0?e:Gle},Vle={active:"active",inactive:"inactive"},Yle=(e,t)=>{var n;const{dir:r}=Oo(),{size:o}=Kle(),{name:i,size:a=o??32,shape:s="circular",active:l="unset",activeAppearance:u="ring",idForColor:d}=e;let{color:h="neutral"}=e;h==="colorful"&&(h=h6[Xle((n=d??i)!==null&&n!==void 0?n:"")%h6.length]);const p=lo("avatar-"),m=vr("span",{role:"img",id:p,...e,ref:t},["name"]),[v,_]=T.useState(void 0),b=$t(e.image,{defaultProps:{alt:"",role:"presentation","aria-hidden":!0,hidden:v}});b&&(b.onError=Vn(b.onError,()=>_(!0)),b.onLoad=Vn(b.onLoad,()=>_(void 0)));let E=$t(e.initials,{required:!0,defaultProps:{children:Fle(i,r==="rtl",{firstInitialOnly:a<=16}),id:p+"__initials"}});E!=null&&E.children||(E=void 0);let w;!E&&(!b||v)&&(w=$t(e.icon,{required:!0,defaultProps:{children:T.createElement(Qae,null),"aria-hidden":!0}}));const k=$t(e.badge,{defaultProps:{size:Qle(a),id:p+"__badge"}});let y;if(!m["aria-label"]&&!m["aria-labelledby"]&&(i?(m["aria-label"]=i,k&&(m["aria-labelledby"]=m.id+" "+k.id)):E&&(m["aria-labelledby"]=E.id+(k?" "+k.id:"")),l==="active"||l==="inactive")){const F=Vle[l];if(m["aria-labelledby"]){const C=p+"__active";m["aria-labelledby"]+=" "+C,y=T.createElement("span",{hidden:!0,id:C},F)}else m["aria-label"]&&(m["aria-label"]+=" "+F)}return{size:a,shape:s,active:l,activeAppearance:u,activeAriaLabelElement:y,color:h,components:{root:"span",initials:"span",icon:"span",image:"img",badge:JO},root:m,initials:E,icon:w,image:b,badge:k}},Qle=e=>e>=96?"extra-large":e>=64?"large":e>=56?"medium":e>=40?"small":e>=28?"extra-small":"tiny",h6=["dark-red","cranberry","red","pumpkin","peach","marigold","gold","brass","brown","forest","seafoam","dark-green","light-teal","teal","steel","blue","royal-blue","cornflower","navy","lavender","purple","grape","lilac","pink","magenta","plum","beige","mink","platinum","anchor"],Xle=e=>{let t=0;for(let n=e.length-1;n>=0;n--){const r=e.charCodeAt(n),o=n%8;t^=(r<<o)+(r>>8-o)}return t},ih={root:"fui-Avatar",image:"fui-Avatar__image",initials:"fui-Avatar__initials",icon:"fui-Avatar__icon",badge:"fui-Avatar__badge"},Zle=pt({root:{mc9l5x:"f14t3ns0",Bnnss6s:"fi64zpg",qhf8xq:"f10pi13n",ha4doy:"fmrv4ls",Bbmb7ep:["f8fbkgy","f1nfllo7"],Beyfa6y:["f1nfllo7","f8fbkgy"],B7oj6ja:["f1djnp8u","f1s8kh49"],Btl43ni:["f1s8kh49","f1djnp8u"],Bahqtrf:"fk6fouc",Bhrd7zp:"fl43uef"},textCaption2Strong:{Be2twd7:"f13mqy1h",Bhrd7zp:"fl43uef"},textCaption1Strong:{Be2twd7:"fy9rknc"},textBody1Strong:{Be2twd7:"fkhj508"},textSubtitle2:{Be2twd7:"fod5ikn"},textSubtitle1:{Be2twd7:"f1pp30po"},textTitle:{Be2twd7:"f1x0m3f5"},squareSmall:{Bbmb7ep:["f1g3puop","fi2rrw2"],Beyfa6y:["fi2rrw2","f1g3puop"],B7oj6ja:["f1rstyi9","f1s4nn1u"],Btl43ni:["f1s4nn1u","f1rstyi9"]},squareMedium:{Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"]},squareLarge:{Bbmb7ep:["f1ldthgs","frrelxk"],Beyfa6y:["frrelxk","f1ldthgs"],B7oj6ja:["fobrfso","ffisxpw"],Btl43ni:["ffisxpw","fobrfso"]},squareXLarge:{Bbmb7ep:["fnivh3a","fc7yr5o"],Beyfa6y:["fc7yr5o","fnivh3a"],B7oj6ja:["f1el4m67","f8yange"],Btl43ni:["f8yange","f1el4m67"]},activeOrInactive:{Bz10aip:"ftfx35i",Bmy1vo4:"fv0atk9",B3o57yi:"f1iry5bo",Cwk7ip:"f1gyuh7d",Hwfdqs:"f1onx1g3",Ftih45:"f1wl9k8s",Brfgrao:"f1j7ml58",Bciustq:"ffi060y",Fbdkly:["f1fzr1x6","f1f351id"],lawp4y:"fchca7p",mdwyqc:["f1f351id","f1fzr1x6"],Budzafs:["f1kd9phw","fyf2ch2"],r59vdv:["fyf2ch2","f1kd9phw"],n07z76:["f1gnrg9b","f1xx2lx6"],ck0cow:["f1xx2lx6","f1gnrg9b"],B8bqphf:"f1e9wvyh",h7gv66:"f1vyz52m",Bvy8d8o:"f1rjhkxy",B1pumaf:"f1ak47q9",B17wnbm:"f1apa6og"},ring:{Bdkvgpv:"f163fonl",m598lv:["f1yq6w5o","f1jpmc5p"],qa3bma:"f11yjt3y",Bbv0w2i:["f1jpmc5p","f1yq6w5o"]},ringThick:{qehafq:"f1rbtjc9",Bicfajf:["f1wm0e7m","f1o0l8kp"],susq4k:"f1tz5420",Biibvgv:["f1o0l8kp","f1wm0e7m"],B0qfbqy:"f1q30tuz",B4f6apu:["f9c0djs","fcwzx2y"],y0oebl:"f1hdqo1a",uvfttm:["fcwzx2y","f9c0djs"]},ringThicker:{qehafq:"fk7ejgl",Bicfajf:["f12sbt0w","f1tnh028"],susq4k:"fcrsff4",Biibvgv:["f1tnh028","f12sbt0w"],B0qfbqy:"f1jrge4j",B4f6apu:["fc2vpa6","f133djwz"],y0oebl:"f9hcsm3",uvfttm:["f133djwz","fc2vpa6"]},ringThickest:{qehafq:"fl3e39p",Bicfajf:["f14m8wrz","fckzhtt"],susq4k:"fnxq6pw",Biibvgv:["fckzhtt","f14m8wrz"],B0qfbqy:"fr6r3yi",B4f6apu:["ftxoq8w","f4gs2h8"],y0oebl:"f9gga8r",uvfttm:["f4gs2h8","ftxoq8w"]},shadow4:{h8m2vh:"f196qwgu"},shadow8:{h8m2vh:"fut48mo"},shadow16:{h8m2vh:"fh2kfig"},shadow28:{h8m2vh:"f4c2u2p"},inactive:{abs64n:"fp25eh",Bz10aip:"f1clczzi",Bmy1vo4:"fv0atk9",B3o57yi:"f1iry5bo",Cwk7ip:"fxm264b",Hwfdqs:"f1onx1g3",Bwz0kr7:"f1o7dfsw",qehafq:"fe3o830",Bicfajf:["fzynn9s","f1z0ukd1"],susq4k:"f1kyqvp9",Biibvgv:["f1z0ukd1","fzynn9s"],vz82u:"f1dhznln",B8bqphf:"f1e9wvyh",h7gv66:"f1vyz52m",Bvy8d8o:"f1yb2g89",B1pumaf:"f1ak47q9",B17wnbm:"f1apa6og"},badge:{qhf8xq:"f1euv43f",B5kzvoi:"f1yab3r1",j35jbq:["f1e31b4d","f1vgc2s3"],E5pizo:"ffo9j2l"},badgeLarge:{E5pizo:"f1nayfl2"},image:{qhf8xq:"f1euv43f",Bhzewxz:"f15twtuk",oyh7mz:["f1vgc2s3","f1e31b4d"],a9b677:"fly5x3f",Bqenvij:"f1l02sjl",Bbmb7ep:["f1d9uwra","fzibvwi"],Beyfa6y:["fzibvwi","f1d9uwra"],B7oj6ja:["fuoumxm","f1vtqnvc"],Btl43ni:["f1vtqnvc","fuoumxm"],st4lth:"f1ps3kmd",ha4doy:"f12kltsn"},iconInitials:{qhf8xq:"f1euv43f",B7ck84d:"f1ewtqcl",Bhzewxz:"f15twtuk",oyh7mz:["f1vgc2s3","f1e31b4d"],a9b677:"fly5x3f",Bqenvij:"f1l02sjl",Bg96gwp:"fp6vxd",B4j52fo:"f192inf7",Bekrc4i:["f5tn483","f1ojsxk5"],Bn0qgzm:"f1vxd6vx",ibv6hh:["f1ojsxk5","f5tn483"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],mc9l5x:"f22iagw",Bt984gj:"f122n59",Brf1p80:"f4d9j23",ha4doy:"fa4t5tb",fsow6f:"f17mccla",famaaq:"f1xqy1su",Bbmb7ep:["f1d9uwra","fzibvwi"],Beyfa6y:["fzibvwi","f1d9uwra"],B7oj6ja:["fuoumxm","f1vtqnvc"],Btl43ni:["f1vtqnvc","fuoumxm"]},icon12:{Be2twd7:"f1ugzwwg"},icon16:{Be2twd7:"f4ybsrx"},icon20:{Be2twd7:"fe5j1ua"},icon24:{Be2twd7:"f1rt2boy"},icon28:{Be2twd7:"f24l1pt"},icon32:{Be2twd7:"ffl51b"},icon48:{Be2twd7:"f18m8u13"}},{d:[".f14t3ns0{display:inline-block;}",".fi64zpg{-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;}",".f10pi13n{position:relative;}",".fmrv4ls{vertical-align:middle;}",".f8fbkgy{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1nfllo7{border-bottom-left-radius:var(--borderRadiusCircular);}",".f1djnp8u{border-top-right-radius:var(--borderRadiusCircular);}",".f1s8kh49{border-top-left-radius:var(--borderRadiusCircular);}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fl43uef{font-weight:var(--fontWeightSemibold);}",".f13mqy1h{font-size:var(--fontSizeBase100);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".fkhj508{font-size:var(--fontSizeBase300);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".f1pp30po{font-size:var(--fontSizeBase500);}",".f1x0m3f5{font-size:var(--fontSizeBase600);}",".f1g3puop{border-bottom-right-radius:var(--borderRadiusSmall);}",".fi2rrw2{border-bottom-left-radius:var(--borderRadiusSmall);}",".f1rstyi9{border-top-right-radius:var(--borderRadiusSmall);}",".f1s4nn1u{border-top-left-radius:var(--borderRadiusSmall);}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f1ldthgs{border-bottom-right-radius:var(--borderRadiusLarge);}",".frrelxk{border-bottom-left-radius:var(--borderRadiusLarge);}",".fobrfso{border-top-right-radius:var(--borderRadiusLarge);}",".ffisxpw{border-top-left-radius:var(--borderRadiusLarge);}",".fnivh3a{border-bottom-right-radius:var(--borderRadiusXLarge);}",".fc7yr5o{border-bottom-left-radius:var(--borderRadiusXLarge);}",".f1el4m67{border-top-right-radius:var(--borderRadiusXLarge);}",".f8yange{border-top-left-radius:var(--borderRadiusXLarge);}",".ftfx35i{-webkit-transform:perspective(1px);-moz-transform:perspective(1px);-ms-transform:perspective(1px);transform:perspective(1px);}",".fv0atk9{transition-property:transform,opacity;}",".f1iry5bo{transition-duration:var(--durationUltraSlow),var(--durationFaster);}",".f1gyuh7d{transition-delay:var(--curveEasyEaseMax),var(--curveLinear);}",'.f1wl9k8s::before{content:"";}',".f1j7ml58::before{position:absolute;}",".ffi060y::before{top:0;}",".f1fzr1x6::before{left:0;}",".f1f351id::before{right:0;}",".fchca7p::before{bottom:0;}",".f1kd9phw::before{border-bottom-right-radius:inherit;}",".fyf2ch2::before{border-bottom-left-radius:inherit;}",".f1gnrg9b::before{border-top-right-radius:inherit;}",".f1xx2lx6::before{border-top-left-radius:inherit;}",".f1e9wvyh::before{transition-property:margin,opacity;}",".f1vyz52m::before{transition-duration:var(--durationUltraSlow),var(--durationSlower);}",".f1rjhkxy::before{transition-delay:var(--curveEasyEaseMax),var(--curveLinear);}",".f163fonl::before{border-top-style:solid;}",".f1yq6w5o::before{border-right-style:solid;}",".f1jpmc5p::before{border-left-style:solid;}",".f11yjt3y::before{border-bottom-style:solid;}",".f1rbtjc9::before{margin-top:calc(-2 * var(--strokeWidthThick));}",".f1wm0e7m::before{margin-right:calc(-2 * var(--strokeWidthThick));}",".f1o0l8kp::before{margin-left:calc(-2 * var(--strokeWidthThick));}",".f1tz5420::before{margin-bottom:calc(-2 * var(--strokeWidthThick));}",".f1q30tuz::before{border-top-width:var(--strokeWidthThick);}",".f9c0djs::before{border-right-width:var(--strokeWidthThick);}",".fcwzx2y::before{border-left-width:var(--strokeWidthThick);}",".f1hdqo1a::before{border-bottom-width:var(--strokeWidthThick);}",".fk7ejgl::before{margin-top:calc(-2 * var(--strokeWidthThicker));}",".f12sbt0w::before{margin-right:calc(-2 * var(--strokeWidthThicker));}",".f1tnh028::before{margin-left:calc(-2 * var(--strokeWidthThicker));}",".fcrsff4::before{margin-bottom:calc(-2 * var(--strokeWidthThicker));}",".f1jrge4j::before{border-top-width:var(--strokeWidthThicker);}",".fc2vpa6::before{border-right-width:var(--strokeWidthThicker);}",".f133djwz::before{border-left-width:var(--strokeWidthThicker);}",".f9hcsm3::before{border-bottom-width:var(--strokeWidthThicker);}",".fl3e39p::before{margin-top:calc(-2 * var(--strokeWidthThickest));}",".f14m8wrz::before{margin-right:calc(-2 * var(--strokeWidthThickest));}",".fckzhtt::before{margin-left:calc(-2 * var(--strokeWidthThickest));}",".fnxq6pw::before{margin-bottom:calc(-2 * var(--strokeWidthThickest));}",".fr6r3yi::before{border-top-width:var(--strokeWidthThickest);}",".ftxoq8w::before{border-right-width:var(--strokeWidthThickest);}",".f4gs2h8::before{border-left-width:var(--strokeWidthThickest);}",".f9gga8r::before{border-bottom-width:var(--strokeWidthThickest);}",".f196qwgu::before{box-shadow:var(--shadow4);}",".fut48mo::before{box-shadow:var(--shadow8);}",".fh2kfig::before{box-shadow:var(--shadow16);}",".f4c2u2p::before{box-shadow:var(--shadow28);}",".fp25eh{opacity:0.8;}",".f1clczzi{-webkit-transform:scale(0.875);-moz-transform:scale(0.875);-ms-transform:scale(0.875);transform:scale(0.875);}",".fxm264b{transition-delay:var(--curveDecelerateMin),var(--curveLinear);}",".fe3o830::before{margin-top:0;}",".fzynn9s::before{margin-right:0;}",".f1z0ukd1::before{margin-left:0;}",".f1kyqvp9::before{margin-bottom:0;}",".f1dhznln::before{opacity:0;}",".f1yb2g89::before{transition-delay:var(--curveDecelerateMin),var(--curveLinear);}",".f1euv43f{position:absolute;}",".f1yab3r1{bottom:0;}",".f1e31b4d{right:0;}",".f1vgc2s3{left:0;}",".ffo9j2l{box-shadow:0 0 0 var(--strokeWidthThin) var(--colorNeutralBackground1);}",".f1nayfl2{box-shadow:0 0 0 var(--strokeWidthThick) var(--colorNeutralBackground1);}",".f15twtuk{top:0;}",".fly5x3f{width:100%;}",".f1l02sjl{height:100%;}",".f1d9uwra{border-bottom-right-radius:inherit;}",".fzibvwi{border-bottom-left-radius:inherit;}",".fuoumxm{border-top-right-radius:inherit;}",".f1vtqnvc{border-top-left-radius:inherit;}",".f1ps3kmd{object-fit:cover;}",".f12kltsn{vertical-align:top;}",".f1ewtqcl{box-sizing:border-box;}",".fp6vxd{line-height:1;}",".f192inf7{border-top-width:var(--strokeWidthThin);}",".f5tn483{border-right-width:var(--strokeWidthThin);}",".f1ojsxk5{border-left-width:var(--strokeWidthThin);}",".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}",".fa4t5tb{vertical-align:center;}",".f17mccla{text-align:center;}",".f1xqy1su{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;}",".f1ugzwwg{font-size:12px;}",".f4ybsrx{font-size:16px;}",".fe5j1ua{font-size:20px;}",".f1rt2boy{font-size:24px;}",".f24l1pt{font-size:28px;}",".ffl51b{font-size:32px;}",".f18m8u13{font-size:48px;}"],m:[["@media screen and (prefers-reduced-motion: reduce){.f1onx1g3{transition-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1ak47q9::before{transition-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1apa6og::before{transition-delay:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1onx1g3{transition-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1o7dfsw{transition-delay:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1ak47q9::before{transition-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1apa6og::before{transition-delay:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}]]}),Jle=pt({16:{a9b677:"fjw5fx7",Bqenvij:"fd461yt"},20:{a9b677:"f64fuq3",Bqenvij:"fjamq6b"},24:{a9b677:"fq4mcun",Bqenvij:"frvgh55"},28:{a9b677:"f1w9dchk",Bqenvij:"fxldao9"},32:{a9b677:"f1szoe96",Bqenvij:"f1d2rq10"},36:{a9b677:"fpdz1er",Bqenvij:"f8ljn23"},40:{a9b677:"feqmc2u",Bqenvij:"fbhnoac"},48:{a9b677:"f124akge",Bqenvij:"ff2sm71"},56:{a9b677:"f1u66zr1",Bqenvij:"fzki0ko"},64:{a9b677:"fa9ln6p",Bqenvij:"f16k9i2m"},72:{a9b677:"fhcae8x",Bqenvij:"f1shusfg"},96:{a9b677:"f1kyr2gn",Bqenvij:"fypu0ge"},120:{a9b677:"fwfqyga",Bqenvij:"fjr5b71"},128:{a9b677:"f1iksgmy",Bqenvij:"fele2au"}},{d:[".fjw5fx7{width:16px;}",".fd461yt{height:16px;}",".f64fuq3{width:20px;}",".fjamq6b{height:20px;}",".fq4mcun{width:24px;}",".frvgh55{height:24px;}",".f1w9dchk{width:28px;}",".fxldao9{height:28px;}",".f1szoe96{width:32px;}",".f1d2rq10{height:32px;}",".fpdz1er{width:36px;}",".f8ljn23{height:36px;}",".feqmc2u{width:40px;}",".fbhnoac{height:40px;}",".f124akge{width:48px;}",".ff2sm71{height:48px;}",".f1u66zr1{width:56px;}",".fzki0ko{height:56px;}",".fa9ln6p{width:64px;}",".f16k9i2m{height:64px;}",".fhcae8x{width:72px;}",".f1shusfg{height:72px;}",".f1kyr2gn{width:96px;}",".fypu0ge{height:96px;}",".fwfqyga{width:120px;}",".fjr5b71{height:120px;}",".f1iksgmy{width:128px;}",".fele2au{height:128px;}"]}),eue=pt({neutral:{sj55zd:"f11d4kpn",De3pzq:"f18f03hv",Bic5iru:"f1uuiafn"},brand:{sj55zd:"fonrgv7",De3pzq:"f1blnnmj",Bic5iru:"f1uuiafn"},"dark-red":{sj55zd:"fqjd1y1",De3pzq:"f1vq2oo4",Bic5iru:"f1t2x9on"},cranberry:{sj55zd:"fg9gses",De3pzq:"f1lwxszt",Bic5iru:"f1pvshc9"},red:{sj55zd:"f23f7i0",De3pzq:"f1q9qhfq",Bic5iru:"f1ectbk9"},pumpkin:{sj55zd:"fjnan08",De3pzq:"fz91bi3",Bic5iru:"fvzpl0b"},peach:{sj55zd:"fknu15p",De3pzq:"f1b9nr51",Bic5iru:"fwj2kd7"},marigold:{sj55zd:"f9603vw",De3pzq:"f3z4w6d",Bic5iru:"fr120vy"},gold:{sj55zd:"fmq0uwp",De3pzq:"fg50kya",Bic5iru:"f8xmmar"},brass:{sj55zd:"f28g5vo",De3pzq:"f4w2gd0",Bic5iru:"f1hbety2"},brown:{sj55zd:"ftl572b",De3pzq:"f14wu1f4",Bic5iru:"f1vg3s4g"},forest:{sj55zd:"f1gymlvd",De3pzq:"f19ut4y6",Bic5iru:"f1m3olm5"},seafoam:{sj55zd:"fnnb6wn",De3pzq:"f1n057jc",Bic5iru:"f17xiqtr"},"dark-green":{sj55zd:"ff58qw8",De3pzq:"f11t05wk",Bic5iru:"fx32vyh"},"light-teal":{sj55zd:"f1up9qbj",De3pzq:"f42feg1",Bic5iru:"f1mkihwv"},teal:{sj55zd:"f135dsb4",De3pzq:"f6hvv1p",Bic5iru:"fecnooh"},steel:{sj55zd:"f151dlcp",De3pzq:"f1lnp8zf",Bic5iru:"f15hfgzm"},blue:{sj55zd:"f1rjv50u",De3pzq:"f1ggcpy6",Bic5iru:"fqproka"},"royal-blue":{sj55zd:"f1emykk5",De3pzq:"f12rj61f",Bic5iru:"f17v2w59"},cornflower:{sj55zd:"fqsigj7",De3pzq:"f8k7hur",Bic5iru:"fp0q1mo"},navy:{sj55zd:"f1nj97xi",De3pzq:"f19gw0ux",Bic5iru:"f1nlym55"},lavender:{sj55zd:"fwctg0i",De3pzq:"ff379vm",Bic5iru:"f62vk8h"},purple:{sj55zd:"fjrsgpu",De3pzq:"f1mzf1e1",Bic5iru:"f15zl69q"},grape:{sj55zd:"f1fiiydq",De3pzq:"f1o4k8oy",Bic5iru:"f53w4j7"},lilac:{sj55zd:"f1res9jt",De3pzq:"f1x6mz1o",Bic5iru:"fu2771t"},pink:{sj55zd:"fv3fbbi",De3pzq:"fydlv6t",Bic5iru:"fzflscs"},magenta:{sj55zd:"f1f1fwnz",De3pzq:"f4xb6j5",Bic5iru:"fb6rmqc"},plum:{sj55zd:"f8ptl6j",De3pzq:"fqo8e26",Bic5iru:"f1a4gm5b"},beige:{sj55zd:"f1ntv3ld",De3pzq:"f101elhj",Bic5iru:"f1qpf9z1"},mink:{sj55zd:"f1fscmp",De3pzq:"f13g8o5c",Bic5iru:"f1l7or83"},platinum:{sj55zd:"f1dr00v2",De3pzq:"fkh7blw",Bic5iru:"fzrj0iu"},anchor:{sj55zd:"f1f3ti53",De3pzq:"fu4yj0j",Bic5iru:"f8oz6wf"}},{d:[".f11d4kpn{color:var(--colorNeutralForeground3);}",".f18f03hv{background-color:var(--colorNeutralBackground6);}",".f1uuiafn::before{color:var(--colorBrandStroke1);}",".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}",".f1blnnmj{background-color:var(--colorBrandBackgroundStatic);}",".fqjd1y1{color:var(--colorPaletteDarkRedForeground2);}",".f1vq2oo4{background-color:var(--colorPaletteDarkRedBackground2);}",".f1t2x9on::before{color:var(--colorPaletteDarkRedBorderActive);}",".fg9gses{color:var(--colorPaletteCranberryForeground2);}",".f1lwxszt{background-color:var(--colorPaletteCranberryBackground2);}",".f1pvshc9::before{color:var(--colorPaletteCranberryBorderActive);}",".f23f7i0{color:var(--colorPaletteRedForeground2);}",".f1q9qhfq{background-color:var(--colorPaletteRedBackground2);}",".f1ectbk9::before{color:var(--colorPaletteRedBorderActive);}",".fjnan08{color:var(--colorPalettePumpkinForeground2);}",".fz91bi3{background-color:var(--colorPalettePumpkinBackground2);}",".fvzpl0b::before{color:var(--colorPalettePumpkinBorderActive);}",".fknu15p{color:var(--colorPalettePeachForeground2);}",".f1b9nr51{background-color:var(--colorPalettePeachBackground2);}",".fwj2kd7::before{color:var(--colorPalettePeachBorderActive);}",".f9603vw{color:var(--colorPaletteMarigoldForeground2);}",".f3z4w6d{background-color:var(--colorPaletteMarigoldBackground2);}",".fr120vy::before{color:var(--colorPaletteMarigoldBorderActive);}",".fmq0uwp{color:var(--colorPaletteGoldForeground2);}",".fg50kya{background-color:var(--colorPaletteGoldBackground2);}",".f8xmmar::before{color:var(--colorPaletteGoldBorderActive);}",".f28g5vo{color:var(--colorPaletteBrassForeground2);}",".f4w2gd0{background-color:var(--colorPaletteBrassBackground2);}",".f1hbety2::before{color:var(--colorPaletteBrassBorderActive);}",".ftl572b{color:var(--colorPaletteBrownForeground2);}",".f14wu1f4{background-color:var(--colorPaletteBrownBackground2);}",".f1vg3s4g::before{color:var(--colorPaletteBrownBorderActive);}",".f1gymlvd{color:var(--colorPaletteForestForeground2);}",".f19ut4y6{background-color:var(--colorPaletteForestBackground2);}",".f1m3olm5::before{color:var(--colorPaletteForestBorderActive);}",".fnnb6wn{color:var(--colorPaletteSeafoamForeground2);}",".f1n057jc{background-color:var(--colorPaletteSeafoamBackground2);}",".f17xiqtr::before{color:var(--colorPaletteSeafoamBorderActive);}",".ff58qw8{color:var(--colorPaletteDarkGreenForeground2);}",".f11t05wk{background-color:var(--colorPaletteDarkGreenBackground2);}",".fx32vyh::before{color:var(--colorPaletteDarkGreenBorderActive);}",".f1up9qbj{color:var(--colorPaletteLightTealForeground2);}",".f42feg1{background-color:var(--colorPaletteLightTealBackground2);}",".f1mkihwv::before{color:var(--colorPaletteLightTealBorderActive);}",".f135dsb4{color:var(--colorPaletteTealForeground2);}",".f6hvv1p{background-color:var(--colorPaletteTealBackground2);}",".fecnooh::before{color:var(--colorPaletteTealBorderActive);}",".f151dlcp{color:var(--colorPaletteSteelForeground2);}",".f1lnp8zf{background-color:var(--colorPaletteSteelBackground2);}",".f15hfgzm::before{color:var(--colorPaletteSteelBorderActive);}",".f1rjv50u{color:var(--colorPaletteBlueForeground2);}",".f1ggcpy6{background-color:var(--colorPaletteBlueBackground2);}",".fqproka::before{color:var(--colorPaletteBlueBorderActive);}",".f1emykk5{color:var(--colorPaletteRoyalBlueForeground2);}",".f12rj61f{background-color:var(--colorPaletteRoyalBlueBackground2);}",".f17v2w59::before{color:var(--colorPaletteRoyalBlueBorderActive);}",".fqsigj7{color:var(--colorPaletteCornflowerForeground2);}",".f8k7hur{background-color:var(--colorPaletteCornflowerBackground2);}",".fp0q1mo::before{color:var(--colorPaletteCornflowerBorderActive);}",".f1nj97xi{color:var(--colorPaletteNavyForeground2);}",".f19gw0ux{background-color:var(--colorPaletteNavyBackground2);}",".f1nlym55::before{color:var(--colorPaletteNavyBorderActive);}",".fwctg0i{color:var(--colorPaletteLavenderForeground2);}",".ff379vm{background-color:var(--colorPaletteLavenderBackground2);}",".f62vk8h::before{color:var(--colorPaletteLavenderBorderActive);}",".fjrsgpu{color:var(--colorPalettePurpleForeground2);}",".f1mzf1e1{background-color:var(--colorPalettePurpleBackground2);}",".f15zl69q::before{color:var(--colorPalettePurpleBorderActive);}",".f1fiiydq{color:var(--colorPaletteGrapeForeground2);}",".f1o4k8oy{background-color:var(--colorPaletteGrapeBackground2);}",".f53w4j7::before{color:var(--colorPaletteGrapeBorderActive);}",".f1res9jt{color:var(--colorPaletteLilacForeground2);}",".f1x6mz1o{background-color:var(--colorPaletteLilacBackground2);}",".fu2771t::before{color:var(--colorPaletteLilacBorderActive);}",".fv3fbbi{color:var(--colorPalettePinkForeground2);}",".fydlv6t{background-color:var(--colorPalettePinkBackground2);}",".fzflscs::before{color:var(--colorPalettePinkBorderActive);}",".f1f1fwnz{color:var(--colorPaletteMagentaForeground2);}",".f4xb6j5{background-color:var(--colorPaletteMagentaBackground2);}",".fb6rmqc::before{color:var(--colorPaletteMagentaBorderActive);}",".f8ptl6j{color:var(--colorPalettePlumForeground2);}",".fqo8e26{background-color:var(--colorPalettePlumBackground2);}",".f1a4gm5b::before{color:var(--colorPalettePlumBorderActive);}",".f1ntv3ld{color:var(--colorPaletteBeigeForeground2);}",".f101elhj{background-color:var(--colorPaletteBeigeBackground2);}",".f1qpf9z1::before{color:var(--colorPaletteBeigeBorderActive);}",".f1fscmp{color:var(--colorPaletteMinkForeground2);}",".f13g8o5c{background-color:var(--colorPaletteMinkBackground2);}",".f1l7or83::before{color:var(--colorPaletteMinkBorderActive);}",".f1dr00v2{color:var(--colorPalettePlatinumForeground2);}",".fkh7blw{background-color:var(--colorPalettePlatinumBackground2);}",".fzrj0iu::before{color:var(--colorPalettePlatinumBorderActive);}",".f1f3ti53{color:var(--colorPaletteAnchorForeground2);}",".fu4yj0j{background-color:var(--colorPaletteAnchorBackground2);}",".f8oz6wf::before{color:var(--colorPaletteAnchorBorderActive);}"]}),tue=e=>{const{size:t,shape:n,active:r,activeAppearance:o,color:i}=e,a=Zle(),s=Jle(),l=eue(),u=[a.root,s[t],l[i]];if(t<=24?u.push(a.textCaption2Strong):t<=28?u.push(a.textCaption1Strong):t<=40?u.push(a.textBody1Strong):t<=56?u.push(a.textSubtitle2):t<=96?u.push(a.textSubtitle1):u.push(a.textTitle),n==="square"&&(t<=24?u.push(a.squareSmall):t<=48?u.push(a.squareMedium):t<=72?u.push(a.squareLarge):u.push(a.squareXLarge)),(r==="active"||r==="inactive")&&(u.push(a.activeOrInactive),(o==="ring"||o==="ring-shadow")&&(u.push(a.ring),t<=48?u.push(a.ringThick):t<=64?u.push(a.ringThicker):u.push(a.ringThickest)),(o==="shadow"||o==="ring-shadow")&&(t<=28?u.push(a.shadow4):t<=48?u.push(a.shadow8):t<=64?u.push(a.shadow16):u.push(a.shadow28)),r==="inactive"&&u.push(a.inactive)),e.root.className=et(ih.root,...u,e.root.className),e.badge&&(e.badge.className=et(ih.badge,a.badge,t>=64&&a.badgeLarge,e.badge.className)),e.image&&(e.image.className=et(ih.image,a.image,e.image.className)),e.initials&&(e.initials.className=et(ih.initials,a.iconInitials,e.initials.className)),e.icon){let d;t<=16?d=a.icon12:t<=24?d=a.icon16:t<=40?d=a.icon20:t<=48?d=a.icon24:t<=56?d=a.icon28:t<=72?d=a.icon32:d=a.icon48,e.icon.className=et(ih.icon,a.iconInitials,d,e.icon.className)}return e},tD=T.forwardRef((e,t)=>{const n=Yle(e,t);return tue(n),Tle(n)});tD.displayName="Avatar";function nue(e){const t=e.clientX,n=e.clientY,r=t+1,o=n+1;function i(){return{left:t,top:n,right:r,bottom:o,x:t,y:n,height:1,width:1}}return{getBoundingClientRect:i}}function a1(e){return e.split("-")[1]}function HT(e){return e==="y"?"height":"width"}function rl(e){return e.split("-")[0]}function s1(e){return["top","bottom"].includes(rl(e))?"x":"y"}function p6(e,t,n){let{reference:r,floating:o}=e;const i=r.x+r.width/2-o.width/2,a=r.y+r.height/2-o.height/2,s=s1(t),l=HT(s),u=r[l]/2-o[l]/2,d=s==="x";let h;switch(rl(t)){case"top":h={x:i,y:r.y-o.height};break;case"bottom":h={x:i,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:a};break;case"left":h={x:r.x-o.width,y:a};break;default:h={x:r.x,y:r.y}}switch(a1(t)){case"start":h[s]-=u*(n&&d?-1:1);break;case"end":h[s]+=u*(n&&d?-1:1)}return h}const rue=async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:i=[],platform:a}=n,s=i.filter(Boolean),l=await(a.isRTL==null?void 0:a.isRTL(t));let u=await a.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:h}=p6(u,r,l),p=r,m={},v=0;for(let _=0;_<s.length;_++){const{name:b,fn:E}=s[_],{x:w,y:k,data:y,reset:F}=await E({x:d,y:h,initialPlacement:r,placement:p,strategy:o,middlewareData:m,rects:u,platform:a,elements:{reference:e,floating:t}});d=w??d,h=k??h,m={...m,[b]:{...m[b],...y}},F&&v<=50&&(v++,typeof F=="object"&&(F.placement&&(p=F.placement),F.rects&&(u=F.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:o}):F.rects),{x:d,y:h}=p6(u,p,l)),_=-1)}return{x:d,y:h,placement:p,strategy:o,middlewareData:m}};function nD(e){return typeof e!="number"?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(e):{top:e,right:e,bottom:e,left:e}}function Uv(e){return{...e,top:e.y,left:e.x,right:e.x+e.width,bottom:e.y+e.height}}async function Kd(e,t){var n;t===void 0&&(t={});const{x:r,y:o,platform:i,rects:a,elements:s,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:d="viewport",elementContext:h="floating",altBoundary:p=!1,padding:m=0}=t,v=nD(m),_=s[p?h==="floating"?"reference":"floating":h],b=Uv(await i.getClippingRect({element:(n=await(i.isElement==null?void 0:i.isElement(_)))==null||n?_:_.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(s.floating)),boundary:u,rootBoundary:d,strategy:l})),E=h==="floating"?{...a.floating,x:r,y:o}:a.reference,w=await(i.getOffsetParent==null?void 0:i.getOffsetParent(s.floating)),k=await(i.isElement==null?void 0:i.isElement(w))&&await(i.getScale==null?void 0:i.getScale(w))||{x:1,y:1},y=Uv(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({rect:E,offsetParent:w,strategy:l}):E);return{top:(b.top-y.top+v.top)/k.y,bottom:(y.bottom-b.bottom+v.bottom)/k.y,left:(b.left-y.left+v.left)/k.x,right:(y.right-b.right+v.right)/k.x}}const oue=Math.min,dc=Math.max;function F_(e,t,n){return dc(e,oue(t,n))}const iue=e=>({name:"arrow",options:e,async fn(t){const{element:n,padding:r=0}=e||{},{x:o,y:i,placement:a,rects:s,platform:l}=t;if(n==null)return{};const u=nD(r),d={x:o,y:i},h=s1(a),p=HT(h),m=await l.getDimensions(n),v=h==="y"?"top":"left",_=h==="y"?"bottom":"right",b=s.reference[p]+s.reference[h]-d[h]-s.floating[p],E=d[h]-s.reference[h],w=await(l.getOffsetParent==null?void 0:l.getOffsetParent(n));let k=w?h==="y"?w.clientHeight||0:w.clientWidth||0:0;k===0&&(k=s.floating[p]);const y=b/2-E/2,F=u[v],C=k-m[p]-u[_],A=k/2-m[p]/2+y,P=F_(F,A,C),I=a1(a)!=null&&A!=P&&s.reference[p]/2-(A<F?u[v]:u[_])-m[p]/2<0;return{[h]:d[h]-(I?A<F?F-A:C-A:0),data:{[h]:P,centerOffset:A-P}}}}),rD=["top","right","bottom","left"];rD.reduce((e,t)=>e.concat(t,t+"-start",t+"-end"),[]);const aue={left:"right",right:"left",bottom:"top",top:"bottom"};function qv(e){return e.replace(/left|right|bottom|top/g,t=>aue[t])}function sue(e,t,n){n===void 0&&(n=!1);const r=a1(e),o=s1(e),i=HT(o);let a=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(a=qv(a)),{main:a,cross:qv(a)}}const lue={start:"end",end:"start"};function s9(e){return e.replace(/start|end/g,t=>lue[t])}const uue=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n;const{placement:r,middlewareData:o,rects:i,initialPlacement:a,platform:s,elements:l}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:m="none",flipAlignment:v=!0,..._}=e,b=rl(r),E=rl(a)===a,w=await(s.isRTL==null?void 0:s.isRTL(l.floating)),k=h||(E||!v?[qv(a)]:function(j){const H=qv(j);return[s9(j),H,s9(H)]}(a));h||m==="none"||k.push(...function(j,H,K,U){const pe=a1(j);let se=function(J,$,_e){const ve=["left","right"],fe=["right","left"],R=["top","bottom"],L=["bottom","top"];switch(J){case"top":case"bottom":return _e?$?fe:ve:$?ve:fe;case"left":case"right":return $?R:L;default:return[]}}(rl(j),K==="start",U);return pe&&(se=se.map(J=>J+"-"+pe),H&&(se=se.concat(se.map(s9)))),se}(a,v,m,w));const y=[a,...k],F=await Kd(t,_),C=[];let A=((n=o.flip)==null?void 0:n.overflows)||[];if(u&&C.push(F[b]),d){const{main:j,cross:H}=sue(r,i,w);C.push(F[j],F[H])}if(A=[...A,{placement:r,overflows:C}],!C.every(j=>j<=0)){var P;const j=(((P=o.flip)==null?void 0:P.index)||0)+1,H=y[j];if(H)return{data:{index:j,overflows:A},reset:{placement:H}};let K="bottom";switch(p){case"bestFit":{var I;const U=(I=A.map(pe=>[pe,pe.overflows.filter(se=>se>0).reduce((se,J)=>se+J,0)]).sort((pe,se)=>pe[1]-se[1])[0])==null?void 0:I[0].placement;U&&(K=U);break}case"initialPlacement":K=a}if(r!==K)return{reset:{placement:K}}}return{}}}};function m6(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function g6(e){return rD.some(t=>e[t]>=0)}const v6=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{strategy:n="referenceHidden",...r}=e,{rects:o}=t;switch(n){case"referenceHidden":{const i=m6(await Kd(t,{...r,elementContext:"reference"}),o.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:g6(i)}}}case"escaped":{const i=m6(await Kd(t,{...r,altBoundary:!0}),o.floating);return{data:{escapedOffsets:i,escaped:g6(i)}}}default:return{}}}}},cue=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:n,y:r}=t,o=await async function(i,a){const{placement:s,platform:l,elements:u}=i,d=await(l.isRTL==null?void 0:l.isRTL(u.floating)),h=rl(s),p=a1(s),m=s1(s)==="x",v=["left","top"].includes(h)?-1:1,_=d&&m?-1:1,b=typeof a=="function"?a(i):a;let{mainAxis:E,crossAxis:w,alignmentAxis:k}=typeof b=="number"?{mainAxis:b,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...b};return p&&typeof k=="number"&&(w=p==="end"?-1*k:k),m?{x:w*_,y:E*v}:{x:E*v,y:w*_}}(t,e);return{x:n+o.x,y:r+o.y,data:o}}}};function oD(e){return e==="x"?"y":"x"}const fue=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:i=!0,crossAxis:a=!1,limiter:s={fn:b=>{let{x:E,y:w}=b;return{x:E,y:w}}},...l}=e,u={x:n,y:r},d=await Kd(t,l),h=s1(rl(o)),p=oD(h);let m=u[h],v=u[p];if(i){const b=h==="y"?"bottom":"right";m=F_(m+d[h==="y"?"top":"left"],m,m-d[b])}if(a){const b=p==="y"?"bottom":"right";v=F_(v+d[p==="y"?"top":"left"],v,v-d[b])}const _=s.fn({...t,[h]:m,[p]:v});return{..._,data:{x:_.x-n,y:_.y-r}}}}},due=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:o,rects:i,middlewareData:a}=t,{offset:s=0,mainAxis:l=!0,crossAxis:u=!0}=e,d={x:n,y:r},h=s1(o),p=oD(h);let m=d[h],v=d[p];const _=typeof s=="function"?s(t):s,b=typeof _=="number"?{mainAxis:_,crossAxis:0}:{mainAxis:0,crossAxis:0,..._};if(l){const k=h==="y"?"height":"width",y=i.reference[h]-i.floating[k]+b.mainAxis,F=i.reference[h]+i.reference[k]-b.mainAxis;m<y?m=y:m>F&&(m=F)}if(u){var E,w;const k=h==="y"?"width":"height",y=["top","left"].includes(rl(o)),F=i.reference[p]-i.floating[k]+(y&&((E=a.offset)==null?void 0:E[p])||0)+(y?0:b.crossAxis),C=i.reference[p]+i.reference[k]+(y?0:((w=a.offset)==null?void 0:w[p])||0)-(y?b.crossAxis:0);v<F?v=F:v>C&&(v=C)}return{[h]:m,[p]:v}}}},hue=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:n,rects:r,platform:o,elements:i}=t,{apply:a=()=>{},...s}=e,l=await Kd(t,s),u=rl(n),d=a1(n);let h,p;u==="top"||u==="bottom"?(h=u,p=d===(await(o.isRTL==null?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(p=u,h=d==="end"?"top":"bottom");const m=dc(l.left,0),v=dc(l.right,0),_=dc(l.top,0),b=dc(l.bottom,0),E={availableHeight:r.floating.height-(["left","right"].includes(n)?2*(_!==0||b!==0?_+b:dc(l.top,l.bottom)):l[h]),availableWidth:r.floating.width-(["top","bottom"].includes(n)?2*(m!==0||v!==0?m+v:dc(l.left,l.right)):l[p])};await a({...t,...E});const w=await o.getDimensions(i.floating);return r.floating.width!==w.width||r.floating.height!==w.height?{reset:{rects:!0}}:{}}}};function qi(e){var t;return((t=e.ownerDocument)==null?void 0:t.defaultView)||window}function is(e){return qi(e).getComputedStyle(e)}function Nu(e){return aD(e)?(e.nodeName||"").toLowerCase():""}let qm;function iD(){if(qm)return qm;const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?(qm=e.brands.map(t=>t.brand+"/"+t.version).join(" "),qm):navigator.userAgent}function ul(e){return e instanceof qi(e).HTMLElement}function Eu(e){return e instanceof qi(e).Element}function aD(e){return e instanceof qi(e).Node}function b6(e){return typeof ShadowRoot>"u"?!1:e instanceof qi(e).ShadowRoot||e instanceof ShadowRoot}function iy(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=is(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function pue(e){return["table","td","th"].includes(Nu(e))}function I_(e){const t=/firefox/i.test(iD()),n=is(e),r=n.backdropFilter||n.WebkitBackdropFilter;return n.transform!=="none"||n.perspective!=="none"||!!r&&r!=="none"||t&&n.willChange==="filter"||t&&!!n.filter&&n.filter!=="none"||["transform","perspective"].some(o=>n.willChange.includes(o))||["paint","layout","strict","content"].some(o=>{const i=n.contain;return i!=null&&i.includes(o)})}function sD(){return!/^((?!chrome|android).)*safari/i.test(iD())}function UT(e){return["html","body","#document"].includes(Nu(e))}const y6=Math.min,qh=Math.max,$v=Math.round;function lD(e){const t=is(e);let n=parseFloat(t.width),r=parseFloat(t.height);const o=e.offsetWidth,i=e.offsetHeight,a=$v(n)!==o||$v(r)!==i;return a&&(n=o,r=i),{width:n,height:r,fallback:a}}function uD(e){return Eu(e)?e:e.contextElement}const cD={x:1,y:1};function Cd(e){const t=uD(e);if(!ul(t))return cD;const n=t.getBoundingClientRect(),{width:r,height:o,fallback:i}=lD(t);let a=(i?$v(n.width):n.width)/r,s=(i?$v(n.height):n.height)/o;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}function N0(e,t,n,r){var o,i;t===void 0&&(t=!1),n===void 0&&(n=!1);const a=e.getBoundingClientRect(),s=uD(e);let l=cD;t&&(r?Eu(r)&&(l=Cd(r)):l=Cd(e));const u=s?qi(s):window,d=!sD()&&n;let h=(a.left+(d&&((o=u.visualViewport)==null?void 0:o.offsetLeft)||0))/l.x,p=(a.top+(d&&((i=u.visualViewport)==null?void 0:i.offsetTop)||0))/l.y,m=a.width/l.x,v=a.height/l.y;if(s){const _=qi(s),b=r&&Eu(r)?qi(r):r;let E=_.frameElement;for(;E&&r&&b!==_;){const w=Cd(E),k=E.getBoundingClientRect(),y=getComputedStyle(E);k.x+=(E.clientLeft+parseFloat(y.paddingLeft))*w.x,k.y+=(E.clientTop+parseFloat(y.paddingTop))*w.y,h*=w.x,p*=w.y,m*=w.x,v*=w.y,h+=k.x,p+=k.y,E=qi(E).frameElement}}return{width:m,height:v,top:p,right:h+m,bottom:p+v,left:h,x:h,y:p}}function _u(e){return((aD(e)?e.ownerDocument:e.document)||window.document).documentElement}function ay(e){return Eu(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function fD(e){return N0(_u(e)).left+ay(e).scrollLeft}function mue(e,t,n){const r=ul(t),o=_u(t),i=N0(e,!0,n==="fixed",t);let a={scrollLeft:0,scrollTop:0};const s={x:0,y:0};if(r||!r&&n!=="fixed")if((Nu(t)!=="body"||iy(o))&&(a=ay(t)),ul(t)){const l=N0(t,!0);s.x=l.x+t.clientLeft,s.y=l.y+t.clientTop}else o&&(s.x=fD(o));return{x:i.left+a.scrollLeft-s.x,y:i.top+a.scrollTop-s.y,width:i.width,height:i.height}}function F0(e){if(Nu(e)==="html")return e;const t=e.assignedSlot||e.parentNode||(b6(e)?e.host:null)||_u(e);return b6(t)?t.host:t}function E6(e){return ul(e)&&is(e).position!=="fixed"?e.offsetParent:null}function _6(e){const t=qi(e);let n=E6(e);for(;n&&pue(n)&&is(n).position==="static";)n=E6(n);return n&&(Nu(n)==="html"||Nu(n)==="body"&&is(n).position==="static"&&!I_(n))?t:n||function(r){let o=F0(r);for(;ul(o)&&!UT(o);){if(I_(o))return o;o=F0(o)}return null}(e)||t}function dD(e){const t=F0(e);return UT(t)?e.ownerDocument.body:ul(t)&&iy(t)?t:dD(t)}function hD(e,t){var n;t===void 0&&(t=[]);const r=dD(e),o=r===((n=e.ownerDocument)==null?void 0:n.body),i=qi(r);return o?t.concat(i,i.visualViewport||[],iy(r)?r:[]):t.concat(r,hD(r))}function T6(e,t,n){return t==="viewport"?Uv(function(r,o){const i=qi(r),a=_u(r),s=i.visualViewport;let l=a.clientWidth,u=a.clientHeight,d=0,h=0;if(s){l=s.width,u=s.height;const p=sD();(p||!p&&o==="fixed")&&(d=s.offsetLeft,h=s.offsetTop)}return{width:l,height:u,x:d,y:h}}(e,n)):Eu(t)?function(r,o){const i=N0(r,!0,o==="fixed"),a=i.top+r.clientTop,s=i.left+r.clientLeft,l=ul(r)?Cd(r):{x:1,y:1},u=r.clientWidth*l.x,d=r.clientHeight*l.y,h=s*l.x,p=a*l.y;return{top:p,left:h,right:h+u,bottom:p+d,x:h,y:p,width:u,height:d}}(t,n):Uv(function(r){var o;const i=_u(r),a=ay(r),s=(o=r.ownerDocument)==null?void 0:o.body,l=qh(i.scrollWidth,i.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),u=qh(i.scrollHeight,i.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0);let d=-a.scrollLeft+fD(r);const h=-a.scrollTop;return is(s||i).direction==="rtl"&&(d+=qh(i.clientWidth,s?s.clientWidth:0)-l),{width:l,height:u,x:d,y:h}}(_u(e)))}const gue={getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const i=n==="clippingAncestors"?function(u,d){const h=d.get(u);if(h)return h;let p=hD(u).filter(b=>Eu(b)&&Nu(b)!=="body"),m=null;const v=is(u).position==="fixed";let _=v?F0(u):u;for(;Eu(_)&&!UT(_);){const b=is(_),E=I_(_);(v?E||m:E||b.position!=="static"||!m||!["absolute","fixed"].includes(m.position))?m=b:p=p.filter(w=>w!==_),_=F0(_)}return d.set(u,p),p}(t,this._c):[].concat(n),a=[...i,r],s=a[0],l=a.reduce((u,d)=>{const h=T6(t,d,o);return u.top=qh(h.top,u.top),u.right=y6(h.right,u.right),u.bottom=y6(h.bottom,u.bottom),u.left=qh(h.left,u.left),u},T6(t,s,o));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{rect:t,offsetParent:n,strategy:r}=e;const o=ul(n),i=_u(n);if(n===i)return t;let a={scrollLeft:0,scrollTop:0},s={x:1,y:1};const l={x:0,y:0};if((o||!o&&r!=="fixed")&&((Nu(n)!=="body"||iy(i))&&(a=ay(n)),ul(n))){const u=N0(n);s=Cd(n),l.x=u.x+n.clientLeft,l.y=u.y+n.clientTop}return{width:t.width*s.x,height:t.height*s.y,x:t.x*s.x-a.scrollLeft*s.x+l.x,y:t.y*s.y-a.scrollTop*s.y+l.y}},isElement:Eu,getDimensions:function(e){return lD(e)},getOffsetParent:_6,getDocumentElement:_u,getScale:Cd,async getElementRects(e){let{reference:t,floating:n,strategy:r}=e;const o=this.getOffsetParent||_6,i=this.getDimensions;return{reference:mue(t,await o(n),r),floating:{x:0,y:0,...await i(n)}}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>is(e).direction==="rtl"},vue=(e,t,n)=>{const r=new Map,o={platform:gue,...n},i={...o.platform,_c:r};return rue(e,t,{...o,platform:i})};function pD(e){const t=e.split("-");return{side:t[0],alignment:t[1]}}const bue=e=>e.nodeName==="HTML"?e:e.parentNode||e.host,yue=e=>{var t;return e.nodeType!==1?{}:((t=e.ownerDocument)===null||t===void 0?void 0:t.defaultView).getComputedStyle(e,null)},I0=e=>{const t=e&&bue(e);if(!t)return document.body;switch(t.nodeName){case"HTML":case"BODY":return t.ownerDocument.body;case"#document":return t.body}const{overflow:n,overflowX:r,overflowY:o}=yue(t);return/(auto|scroll|overlay)/.test(n+o+r)?t:I0(t)},Eue=e=>{var t;const n=I0(e);return n?n!==((t=n.ownerDocument)===null||t===void 0?void 0:t.body):!1};function qT(e,t){if(t==="window")return e==null?void 0:e.ownerDocument.documentElement;if(t==="clippingParents")return"clippingAncestors";if(t==="scrollParent"){let n=I0(e);return n.nodeName==="BODY"&&(n=e==null?void 0:e.ownerDocument.documentElement),n}return t}function mD(e,t){return typeof e=="number"||typeof e=="object"&&e!==null?l9(e,t):typeof e=="function"?n=>{const r=e(n);return l9(r,t)}:{mainAxis:t}}const l9=(e,t)=>{var n;return typeof e=="number"?{mainAxis:e+t}:{...e,mainAxis:((n=e.mainAxis)!==null&&n!==void 0?n:0)+t}},_ue=e=>({above:"top",below:"bottom",before:e?"right":"left",after:e?"left":"right"}),Tue=()=>({start:"start",end:"end",top:"start",bottom:"end",center:void 0}),wue=(e,t)=>{const n=e==="above"||e==="below",r=t==="top"||t==="bottom";return n&&r||!n&&!r},kue=(e,t,n)=>{const r=wue(t,e)?"center":e,o=t&&_ue(n)[t],i=r&&Tue()[r];return o&&i?`${o}-${i}`:o},Sue=()=>({top:"above",bottom:"below",right:"after",left:"before"}),xue=e=>e==="above"||e==="below"?{start:"start",end:"end"}:{start:"top",end:"bottom"},Cue=e=>{const{side:t,alignment:n}=pD(e),r=Sue()[t],o=n&&xue(r)[n];return{position:r,alignment:o}},Aue={above:{position:"above",align:"center"},"above-start":{position:"above",align:"start"},"above-end":{position:"above",align:"end"},below:{position:"below",align:"center"},"below-start":{position:"below",align:"start"},"below-end":{position:"below",align:"end"},before:{position:"before",align:"center"},"before-top":{position:"before",align:"top"},"before-bottom":{position:"before",align:"bottom"},after:{position:"after",align:"center"},"after-top":{position:"after",align:"top"},"after-bottom":{position:"after",align:"bottom"}};function $T(e){return e==null?{}:typeof e=="string"?Aue[e]:e}function u9(e,t,n){const r=T.useRef(!0),[o]=T.useState(()=>({value:e,callback:t,facade:{get current(){return o.value},set current(i){const a=o.value;if(a!==i){if(o.value=i,n&&r.current)return;o.callback(i,a)}}}}));return us(()=>{r.current=!1},[]),o.callback=t,o.facade}function Nue(e){let t;return()=>(t||(t=new Promise(n=>{Promise.resolve().then(()=>{t=void 0,n(e())})})),t)}function Fue(e){const{arrow:t,middlewareData:n}=e;if(!n.arrow||!t)return;const{x:r,y:o}=n.arrow;Object.assign(t.style,{left:`${r}px`,top:`${o}px`})}const w6="data-popper-is-intersecting",k6="data-popper-escaped",S6="data-popper-reference-hidden",Iue="data-popper-placement";function Bue(e){var t,n;const{container:r,placement:o,middlewareData:i,strategy:a,lowPPI:s,coordinates:l}=e;if(!r)return;r.setAttribute(Iue,o),r.removeAttribute(w6),i.intersectionObserver.intersecting&&r.setAttribute(w6,""),r.removeAttribute(k6),!((t=i.hide)===null||t===void 0)&&t.escaped&&r.setAttribute(k6,""),r.removeAttribute(S6),!((n=i.hide)===null||n===void 0)&&n.referenceHidden&&r.setAttribute(S6,"");const u=Math.round(l.x),d=Math.round(l.y);Object.assign(r.style,{transform:s?`translate(${u}px, ${d}px)`:`translate3d(${u}px, ${d}px, 0)`,position:a})}function Rue(){return{name:"coverTarget",fn:e=>{const{placement:t,rects:n,x:r,y:o}=e,i=pD(t).side,a={x:r,y:o};switch(i){case"bottom":a.y-=n.reference.height;break;case"top":a.y+=n.reference.height;break;case"left":a.x+=n.reference.width;break;case"right":a.x-=n.reference.width;break}return a}}}function Oue(e){const{hasScrollableElement:t,flipBoundary:n,container:r}=e;return uue({...t&&{boundary:"clippingAncestors"},...n&&{altBoundary:!0,boundary:qT(r,n)},fallbackStrategy:"bestFit"})}function Due(){return{name:"intersectionObserver",fn:async e=>{const t=e.rects.floating,n=await Kd(e,{altBoundary:!0}),r=n.top<t.height&&n.top>0,o=n.bottom<t.height&&n.bottom>0;return{data:{intersecting:r||o}}}}}function Pue(e,t){const{container:n,overflowBoundary:r}=t;return hue({...r&&{altBoundary:!0,boundary:qT(n,r)},apply({availableHeight:o,availableWidth:i,elements:a,rects:s}){const l=e==="always"||e==="width-always"||s.floating.width>i&&(e===!0||e==="width");(e==="always"||e==="height-always"||s.floating.height>o&&(e===!0||e==="height"))&&Object.assign(a.floating.style,{maxHeight:`${o}px`,boxSizing:"border-box"}),l&&Object.assign(a.floating.style,{maxWidth:`${i}px`,boxSizing:"border-box"})}})}function Mue(e){return!e||typeof e=="number"||typeof e=="object"?e:({rects:{floating:t,reference:n},placement:r})=>{const{position:o,alignment:i}=Cue(r);return e({positionedRect:t,targetRect:n,position:o,alignment:i})}}function Lue(e){const t=Mue(e);return cue(t)}function jue(e){const{hasScrollableElement:t,disableTether:n,overflowBoundary:r,container:o}=e;return fue({...t&&{boundary:"clippingAncestors"},...n&&{crossAxis:n==="all",limiter:due({crossAxis:n!=="all",mainAxis:!1})},...r&&{altBoundary:!0,boundary:qT(o,r)}})}function zue(e){const{container:t,target:n,arrow:r,strategy:o,middleware:i,placement:a}=e;if(!n||!t)return{updatePosition:()=>{},dispose:()=>{}};let s=!0;const l=new Set,u=t.ownerDocument.defaultView;Object.assign(t.style,{position:"fixed",left:0,top:0,margin:0});let d=()=>{s&&(l.add(I0(t)),n instanceof HTMLElement&&l.add(I0(n)),l.forEach(m=>{m.addEventListener("scroll",h)}),s=!1),Object.assign(t.style,{position:o}),vue(n,t,{placement:a,middleware:i,strategy:o}).then(({x:m,y:v,middlewareData:_,placement:b})=>{Fue({arrow:r,middlewareData:_}),Bue({container:t,middlewareData:_,placement:b,coordinates:{x:m,y:v},lowPPI:((u==null?void 0:u.devicePixelRatio)||1)<=1,strategy:o})}).catch(m=>{})};const h=Nue(()=>d()),p=()=>{d=()=>null,u&&(u.removeEventListener("scroll",h),u.removeEventListener("resize",h)),l.forEach(m=>{m.removeEventListener("scroll",h)})};return u&&(u.addEventListener("scroll",h),u.addEventListener("resize",h)),h(),{updatePosition:h,dispose:p}}function WT(e){const t=T.useRef(null),n=T.useRef(null),r=T.useRef(null),o=T.useRef(null),i=T.useRef(null),{enabled:a=!0}=e,s=Hue(e),l=T.useCallback(()=>{var m;t.current&&t.current.dispose(),t.current=null;const v=(m=r.current)!==null&&m!==void 0?m:n.current;a&&DT()&&v&&o.current&&(t.current=zue({container:o.current,target:v,arrow:i.current,...s(o.current,i.current)}))},[a,s]),u=Et(m=>{r.current=m,l()});T.useImperativeHandle(e.positioningRef,()=>({updatePosition:()=>{var m;return(m=t.current)===null||m===void 0?void 0:m.updatePosition()},setTarget:m=>{e.target,u(m)}}),[e.target,u]),us(()=>{var m;u((m=e.target)!==null&&m!==void 0?m:null)},[e.target,u]),us(()=>{l()},[l]);const d=u9(null,m=>{n.current!==m&&(n.current=m,l())}),h=u9(null,m=>{o.current!==m&&(o.current=m,l())}),p=u9(null,m=>{i.current!==m&&(i.current=m,l())});return{targetRef:d,containerRef:h,arrowRef:p}}function Hue(e){const{align:t,arrowPadding:n,autoSize:r,coverTarget:o,flipBoundary:i,offset:a,overflowBoundary:s,pinned:l,position:u,unstable_disableTether:d,positionFixed:h}=e,{dir:p}=Oo(),m=p==="rtl",v=h?"fixed":"absolute";return T.useCallback((_,b)=>{const E=Eue(_),w=kue(t,u,m),k=[a&&Lue(a),o&&Rue(),!l&&Oue({container:_,flipBoundary:i,hasScrollableElement:E}),jue({container:_,hasScrollableElement:E,overflowBoundary:s,disableTether:d}),r&&Pue(r,{container:_,overflowBoundary:s}),Due(),b&&iue({element:b,padding:n}),v6({strategy:"referenceHidden"}),v6({strategy:"escaped"})].filter(Boolean);return{placement:w,middleware:k,strategy:v}},[t,n,r,o,d,i,m,a,s,l,u,v])}const gD=e=>{const[t,n]=T.useState(e);return[t,o=>{if(o==null){n(void 0);return}let i;o instanceof MouseEvent?i=o:i=o.nativeEvent,i instanceof MouseEvent;const a=nue(i);n(a)}]};var vD=()=>T.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner.current,Uue=()=>!1,x6=new WeakSet;function que(e,t){const n=vD();T.useEffect(()=>{if(!x6.has(n)){x6.add(n),e();return}return e()},t)}var C6=new WeakSet;function $ue(e,t){return T.useMemo(()=>{const n=vD();return C6.has(n)?e():(C6.add(n),null)},t)}function Wue(e,t){var n;const r=Uue()&&!1,o=r?$ue:T.useMemo,i=r?que:T.useEffect,[a,s]=(n=o(()=>e(),t))!=null?n:[null,()=>null];return i(()=>s,t),a}const Gue=n0["useInsertionEffect"],Kue=pt({root:{qhf8xq:"f10pi13n",Bj3rh1h:"f494woh"}},{d:[".f10pi13n{position:relative;}",".f494woh{z-index:1000000;}"]}),Vue=Number(T.version.split(".")[0]),Yue=e=>{const{targetDocument:t,dir:n}=Oo(),r=FO(),o=Kue(),i=XR(),a=et(i,o.root),s=Wue(()=>{if(t===void 0||e.disabled)return[null,()=>null];const l=t.createElement("div");return t.body.appendChild(l),[l,()=>l.remove()]},[t]);return Vue>=18?Gue(()=>{if(!s)return;const l=a.split(" ").filter(Boolean);return s.classList.add(...l),s.setAttribute("dir",n),r.current=s,()=>{s.classList.remove(...l),s.removeAttribute("dir")}},[a,n,s,r]):T.useMemo(()=>{s&&(s.className=a,s.setAttribute("dir",n),r.current=s)},[a,n,s,r]),s};function Que(e){return e&&!!e._virtual}function Xue(e){return Que(e)&&e._virtual.parent||null}function Zue(e,t={}){if(!e)return null;if(!t.skipVirtual){const n=Xue(e);if(n)return n}return(e==null?void 0:e.parentNode)||null}function B0(e,t){if(!e||!t)return!1;if(e===t)return!0;{const n=new WeakSet;for(;t;){const r=Zue(t,{skipVirtual:n.has(t)});if(n.add(t),r===e)return!0;t=r}}return!1}function A6(e,t){if(!e)return;const n=e;n._virtual||(n._virtual={}),n._virtual.parent=t}const Jue=e=>{const{children:t,mountNode:n}=e,r=T.useRef(null),o=Yue({disabled:!!n}),i={children:t,mountNode:n??o,virtualParentRootRef:r};return T.useEffect(()=>(i.virtualParentRootRef.current&&i.mountNode&&A6(i.mountNode,i.virtualParentRootRef.current),()=>{i.mountNode&&A6(i.mountNode,void 0)}),[i.virtualParentRootRef,i.mountNode]),i},ece=e=>T.createElement("span",{hidden:!0,ref:e.virtualParentRootRef},e.mountNode&&_T.createPortal(e.children,e.mountNode)),sp=e=>{const t=Jue(e);return ece(t)};sp.displayName="Portal";const GT=ry(void 0),tce={open:!1,setOpen:()=>null,toggleOpen:()=>null,triggerRef:{current:null},contentRef:{current:null},arrowRef:{current:null},openOnContext:!1,openOnHover:!1,size:"medium",trapFocus:!1,inline:!1};GT.Provider;const Gr=e=>oy(GT,(t=tce)=>e(t)),nce=(e,t)=>{const n=Gr(w=>w.contentRef),r=Gr(w=>w.openOnHover),o=Gr(w=>w.setOpen),i=Gr(w=>w.mountNode),a=Gr(w=>w.arrowRef),s=Gr(w=>w.size),l=Gr(w=>w.withArrow),u=Gr(w=>w.appearance),d=Gr(w=>w.trapFocus),h=Gr(w=>w.legacyTrapFocus),p=Gr(w=>w.inline),{modalAttributes:m}=ty({trapFocus:d,legacyTrapFocus:h}),v={inline:p,appearance:u,withArrow:l,size:s,arrowRef:a,mountNode:i,components:{root:"div"},root:vr("div",{ref:cs(t,n),role:d?"dialog":"group","aria-modal":d?!0:void 0,...m,...e})},{onMouseEnter:_,onMouseLeave:b,onKeyDown:E}=v.root;return v.root.onMouseEnter=w=>{r&&o(w,!0),_==null||_(w)},v.root.onMouseLeave=w=>{r&&o(w,!1),b==null||b(w)},v.root.onKeyDown=w=>{var k;w.key==="Escape"&&(!((k=n.current)===null||k===void 0)&&k.contains(w.target))&&o(w,!1),E==null||E(w)},v},rce=e=>{const{slots:t,slotProps:n}=Jn(e),r=T.createElement(t.root,{...n.root},e.withArrow&&T.createElement("div",{ref:e.arrowRef,className:e.arrowClassName}),n.root.children);return e.inline?r:T.createElement(sp,{mountNode:e.mountNode},r)},oce={root:"fui-PopoverSurface"},ice={small:6,medium:8,large:8},ace=pt({root:{sj55zd:"f19n0e5",De3pzq:"fxugw4r",E5pizo:"f1hg901r",Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"},inverted:{De3pzq:"fg3r6xk",sj55zd:"fonrgv7"},brand:{De3pzq:"ffp7eso",sj55zd:"f1phragk"},smallPadding:{z8tnut:"f1kcqot9",z189sj:["f11qrl6u","fjlbh76"],Byoj8tv:"fpe6lb7",uwmqm3:["fjlbh76","f11qrl6u"]},mediumPadding:{z8tnut:"fqag9an",z189sj:["f1gbmcue","f1rh9g5y"],Byoj8tv:"fp67ikv",uwmqm3:["f1rh9g5y","f1gbmcue"]},largePadding:{z8tnut:"fc7z3ec",z189sj:["fat0sn4","fekwl8i"],Byoj8tv:"fe2my4m",uwmqm3:["fekwl8i","fat0sn4"]},smallArrow:{a9b677:"f1ekdpwm",Bqenvij:"f83vc9z"},mediumLargeArrow:{a9b677:"f1kmc0fn",Bqenvij:"fb6lvc5"},arrow:{qhf8xq:"f1euv43f",De3pzq:"f1u2r49w",Bcdw1i0:"fd7fpy0",Bj3rh1h:"f1bsuimh",Ftih45:"f1wl9k8s",B1puzpu:"f1wkw4r9",Brfgrao:"f1j7ml58",Bcvre1j:"fyl8oag",Ccq8qp:"frdoeuz",Baz25je:"fb81m9q",cmx5o7:"f1ljr5q2",B4f6apu:"fyfemzf",m598lv:"focyt6c",Bk5zm6e:"fnhxbxj",y0oebl:"fdw6hkg",qa3bma:"f11yjt3y",Bqjgrrk:"f1172wan",Budzafs:["f9e5op9","f112wvtl"],Hv9wc6:["ftj5xct","fyavhwi"],hl6cv3:"f1773hnp",Bh2vraf:"f1n8855c",yayu3t:"f1v7783n",wedwtw:"fsw6im5",rhl9o9:"fh2hsk5",Bu8t5uz:"f159pzir",B6q6orb:"f11yvu4",Bwwlvwl:"fm1ycve"}},{d:[".f19n0e5{color:var(--colorNeutralForeground1);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f1hg901r{box-shadow:var(--shadow16);}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".fg3r6xk{background-color:var(--colorNeutralBackgroundStatic);}",".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}",".ffp7eso{background-color:var(--colorBrandBackground);}",".f1phragk{color:var(--colorNeutralForegroundOnBrand);}",".f1kcqot9{padding-top:12px;}",".f11qrl6u{padding-right:12px;}",".fjlbh76{padding-left:12px;}",".fpe6lb7{padding-bottom:12px;}",".fqag9an{padding-top:16px;}",".f1gbmcue{padding-right:16px;}",".f1rh9g5y{padding-left:16px;}",".fp67ikv{padding-bottom:16px;}",".fc7z3ec{padding-top:20px;}",".fat0sn4{padding-right:20px;}",".fekwl8i{padding-left:20px;}",".fe2my4m{padding-bottom:20px;}",".f1ekdpwm{width:8.484px;}",".f83vc9z{height:8.484px;}",".f1kmc0fn{width:11.312px;}",".fb6lvc5{height:11.312px;}",".f1euv43f{position:absolute;}",".f1u2r49w{background-color:inherit;}",".fd7fpy0{visibility:hidden;}",".f1bsuimh{z-index:-1;}",'.f1wl9k8s::before{content:"";}',".f1wkw4r9::before{visibility:visible;}",".f1j7ml58::before{position:absolute;}",".fyl8oag::before{box-sizing:border-box;}",".frdoeuz::before{width:inherit;}",".fb81m9q::before{height:inherit;}",".f1ljr5q2::before{background-color:inherit;}",".fyfemzf::before{border-right-width:1px;}",".focyt6c::before{border-right-style:solid;}",".fnhxbxj::before{border-right-color:var(--colorTransparentStroke);}",".fdw6hkg::before{border-bottom-width:1px;}",".f11yjt3y::before{border-bottom-style:solid;}",".f1172wan::before{border-bottom-color:var(--colorTransparentStroke);}",".f9e5op9::before{border-bottom-right-radius:var(--borderRadiusSmall);}",".f112wvtl::before{border-bottom-left-radius:var(--borderRadiusSmall);}",".ftj5xct::before{-webkit-transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);-moz-transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);-ms-transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);}",".fyavhwi::before{-webkit-transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);-moz-transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);-ms-transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);}",'[data-popper-placement^="top"] .f1773hnp{bottom:-1px;}','[data-popper-placement^="top"] .f1n8855c{--angle:0;}','[data-popper-placement^="right"] .f1v7783n{left:-1px;}','[data-popper-placement^="right"] .fsw6im5{--angle:90deg;}','[data-popper-placement^="bottom"] .fh2hsk5{top:-1px;}','[data-popper-placement^="bottom"] .f159pzir{--angle:180deg;}','[data-popper-placement^="left"] .f11yvu4{right:-1px;}','[data-popper-placement^="left"] .fm1ycve{--angle:270deg;}']}),sce=e=>{const t=ace();return e.root.className=et(oce.root,t.root,e.size==="small"&&t.smallPadding,e.size==="medium"&&t.mediumPadding,e.size==="large"&&t.largePadding,e.appearance==="inverted"&&t.inverted,e.appearance==="brand"&&t.brand,e.root.className),e.arrowClassName=et(t.arrow,e.size==="small"?t.smallArrow:t.mediumLargeArrow),e},B_=T.forwardRef((e,t)=>{const n=nce(e,t);return sce(n),rce(n)});B_.displayName="PopoverSurface";const lce=4,uce=e=>{var t;const[n,r]=gD(),o={size:"medium",contextTarget:n,setContextTarget:r,...e},i=T.Children.toArray(e.children);let a,s;i.length===2?(a=i[0],s=i[1]):i.length===1&&(s=i[0]);const[l,u]=cce(o),d=T.useRef(0),h=Et((E,w)=>{var k;clearTimeout(d.current),!(E instanceof Event)&&E.persist&&E.persist(),E.type==="mouseleave"?d.current=setTimeout(()=>{u(E,w)},(k=e.mouseLeaveDelay)!==null&&k!==void 0?k:500):u(E,w)});T.useEffect(()=>()=>{clearTimeout(d.current)},[]);const p=T.useCallback(E=>{h(E,!l)},[h,l]),m=fce(o),{targetDocument:v}=Oo();iO({contains:B0,element:v,callback:E=>h(E,!1),refs:[m.triggerRef,m.contentRef],disabled:!l});const _=o.openOnContext||o.closeOnScroll;aO({contains:B0,element:v,callback:E=>h(E,!1),refs:[m.triggerRef,m.contentRef],disabled:!l||!_});const{findFirstFocusable:b}=op();return T.useEffect(()=>{var E;if(!e.unstable_disableAutoFocus&&l&&m.contentRef.current){const w=(E=m.contentRef.current.getAttribute("tabIndex"))!==null&&E!==void 0?E:void 0,k=isNaN(w)?b(m.contentRef.current):m.contentRef.current;k==null||k.focus()}},[b,l,m.contentRef,e.unstable_disableAutoFocus]),{...o,...m,popoverTrigger:a,popoverSurface:s,open:l,setOpen:h,toggleOpen:p,setContextTarget:r,contextTarget:n,inline:(t=e.inline)!==null&&t!==void 0?t:!1}};function cce(e){const t=Et((a,s)=>{var l;return(l=e.onOpenChange)===null||l===void 0?void 0:l.call(e,a,s)}),[n,r]=Wc({state:e.open,defaultState:e.defaultOpen,initialState:!1});e.open=n!==void 0?n:e.open;const o=e.setContextTarget,i=T.useCallback((a,s)=>{s&&a.type==="contextmenu"&&o(a),s||o(void 0),r(s),t==null||t(a,{open:s})},[r,t,o]);return[n,i]}function fce(e){const t={position:"above",align:"center",arrowPadding:2*lce,target:e.openOnContext?e.contextTarget:void 0,...$T(e.positioning)};t.coverTarget&&(e.withArrow=!1),e.withArrow&&(t.offset=mD(t.offset,ice[e.size]));const{targetRef:n,containerRef:r,arrowRef:o}=WT(t);return{triggerRef:n,contentRef:r,arrowRef:o}}const dce=e=>{const{appearance:t,arrowRef:n,contentRef:r,inline:o,mountNode:i,open:a,openOnContext:s,openOnHover:l,setOpen:u,size:d,toggleOpen:h,trapFocus:p,triggerRef:m,withArrow:v,legacyTrapFocus:_}=e;return T.createElement(GT.Provider,{value:{appearance:t,arrowRef:n,contentRef:r,inline:o,mountNode:i,open:a,openOnContext:s,openOnHover:l,setOpen:u,toggleOpen:h,triggerRef:m,size:d,trapFocus:p,legacyTrapFocus:_,withArrow:v}},e.popoverTrigger,e.open&&e.popoverSurface)},R_=e=>{const t=uce(e);return dce(t)};R_.displayName="Popover";const hce=e=>{const{children:t,disableButtonEnhancement:n=!1}=e,r=tp(t),o=Gr(k=>k.open),i=Gr(k=>k.setOpen),a=Gr(k=>k.toggleOpen),s=Gr(k=>k.triggerRef),l=Gr(k=>k.openOnHover),u=Gr(k=>k.openOnContext),{triggerAttributes:d}=ty(),h=k=>{u&&(k.preventDefault(),i(k,!0))},p=k=>{u||a(k)},m=k=>{k.key===ap&&o&&(i(k,!1),k.stopPropagation())},v=k=>{l&&i(k,!0)},_=k=>{l&&i(k,!1)},b={...d,"aria-expanded":`${o}`,...r==null?void 0:r.props,onMouseEnter:Et(Vn(r==null?void 0:r.props.onMouseEnter,v)),onMouseLeave:Et(Vn(r==null?void 0:r.props.onMouseLeave,_)),onContextMenu:Et(Vn(r==null?void 0:r.props.onContextMenu,h)),ref:cs(s,r==null?void 0:r.ref)},E={...b,onClick:Et(Vn(r==null?void 0:r.props.onClick,p)),onKeyDown:Et(Vn(r==null?void 0:r.props.onKeyDown,m))},w=Gd((r==null?void 0:r.type)==="button"||(r==null?void 0:r.type)==="a"?r.type:"div",E);return{children:Vb(e.children,Gd((r==null?void 0:r.type)==="button"||(r==null?void 0:r.type)==="a"?r.type:"div",u?b:n?E:w))}},pce=e=>e.children,Wv=e=>{const t=hce(e);return pce(t)};Wv.displayName="PopoverTrigger";Wv.isFluentTriggerComponent=!0;const mce=6,gce=4,vce=e=>{var t,n,r,o;const i=Tre(),a=Bre(),{targetDocument:s}=Oo(),[l,u]=Pre(),{appearance:d="normal",children:h,content:p,withArrow:m=!1,positioning:v="above",onVisibleChange:_,relationship:b,showDelay:E=250,hideDelay:w=250,mountNode:k}=e,[y,F]=Wc({state:e.visible,initialState:!1}),C=T.useCallback((_e,ve)=>{u(),F(fe=>(_e!==fe&&(_==null||_(ve,{visible:_e})),_e))},[u,F,_]),A={withArrow:m,positioning:v,showDelay:E,hideDelay:w,relationship:b,visible:y,shouldRenderTooltip:y,appearance:d,mountNode:k,components:{content:"div"},content:$t(p,{defaultProps:{role:"tooltip"},required:!0})};A.content.id=lo("tooltip-",A.content.id);const P={enabled:A.visible,arrowPadding:2*gce,position:"above",align:"center",offset:4,...$T(A.positioning)};A.withArrow&&(P.offset=mD(P.offset,mce));const{targetRef:I,containerRef:j,arrowRef:H}=WT(P);A.content.ref=cs(A.content.ref,j),A.arrowRef=H,us(()=>{var _e;if(y){const ve={hide:()=>C(!1)};(_e=i.visibleTooltip)===null||_e===void 0||_e.hide(),i.visibleTooltip=ve;const fe=R=>{R.key===ap&&(ve.hide(),R.stopPropagation())};return s==null||s.addEventListener("keydown",fe,{capture:!0}),()=>{i.visibleTooltip===ve&&(i.visibleTooltip=void 0),s==null||s.removeEventListener("keydown",fe,{capture:!0})}}},[i,s,y,C]);const K=T.useRef(!1),U=T.useCallback(_e=>{if(_e.type==="focus"&&K.current){K.current=!1;return}const ve=i.visibleTooltip?0:A.showDelay;l(()=>{C(!0,_e)},ve),_e.persist()},[l,C,A.showDelay,i]),pe=T.useCallback(_e=>{let ve=A.hideDelay;_e.type==="blur"&&(ve=0,K.current=(s==null?void 0:s.activeElement)===_e.target),l(()=>{C(!1,_e)},ve),_e.persist()},[l,C,A.hideDelay,s]);A.content.onPointerEnter=Vn(A.content.onPointerEnter,u),A.content.onPointerLeave=Vn(A.content.onPointerLeave,pe),A.content.onFocus=Vn(A.content.onFocus,u),A.content.onBlur=Vn(A.content.onBlur,pe);const se=tp(h),J={};b==="label"?typeof A.content.children=="string"?J["aria-label"]=A.content.children:(J["aria-labelledby"]=A.content.id,A.shouldRenderTooltip=!0):b==="description"&&(J["aria-describedby"]=A.content.id,A.shouldRenderTooltip=!0),a&&(A.shouldRenderTooltip=!1);const $=cs(se==null?void 0:se.ref,I);return A.children=Vb(h,{...J,...se==null?void 0:se.props,ref:P.target===void 0?$:se==null?void 0:se.ref,onPointerEnter:Et(Vn((t=se==null?void 0:se.props)===null||t===void 0?void 0:t.onPointerEnter,U)),onPointerLeave:Et(Vn((n=se==null?void 0:se.props)===null||n===void 0?void 0:n.onPointerLeave,pe)),onFocus:Et(Vn((r=se==null?void 0:se.props)===null||r===void 0?void 0:r.onFocus,U)),onBlur:Et(Vn((o=se==null?void 0:se.props)===null||o===void 0?void 0:o.onBlur,pe))}),A},bce=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(T.Fragment,null,e.children,e.shouldRenderTooltip&&T.createElement(sp,{mountNode:e.mountNode},T.createElement(t.content,{...n.content},e.withArrow&&T.createElement("div",{ref:e.arrowRef,className:e.arrowClassName}),e.content.children)))},yce={content:"fui-Tooltip__content"},Ece=pt({root:{mc9l5x:"fjseox",B7ck84d:"f1ewtqcl",B2u0y6b:"f132xexn",Bceei9c:"f158kwzp",Bahqtrf:"fk6fouc",Be2twd7:"fy9rknc",Bg96gwp:"fwrc4pm",Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],z8tnut:"f10ra9hq",z189sj:["fd9xhir","f1jlaasf"],Byoj8tv:"f1d7kygh",uwmqm3:["f1jlaasf","fd9xhir"],De3pzq:"fxugw4r",sj55zd:"f19n0e5",Bhu2qc9:"fxeb0a7"},visible:{mc9l5x:"ftgm304"},inverted:{De3pzq:"fg3r6xk",sj55zd:"fonrgv7"},arrow:{qhf8xq:"f1euv43f",De3pzq:"f1u2r49w",Bcdw1i0:"fd7fpy0",Bj3rh1h:"f1bsuimh",a9b677:"f1ekdpwm",Bqenvij:"f83vc9z",Ftih45:"f1wl9k8s",B1puzpu:"f1wkw4r9",Brfgrao:"f1j7ml58",Bcvre1j:"fyl8oag",Ccq8qp:"frdoeuz",Baz25je:"fb81m9q",cmx5o7:"f1ljr5q2",B4f6apu:"fyfemzf",m598lv:"focyt6c",Bk5zm6e:"fnhxbxj",y0oebl:"fdw6hkg",qa3bma:"f11yjt3y",Bqjgrrk:"f1172wan",Budzafs:["f9e5op9","f112wvtl"],Hv9wc6:["ftj5xct","fyavhwi"],hl6cv3:"f1773hnp",Bh2vraf:"f1n8855c",yayu3t:"f1v7783n",wedwtw:"fsw6im5",rhl9o9:"fh2hsk5",Bu8t5uz:"f159pzir",B6q6orb:"f11yvu4",Bwwlvwl:"fm1ycve"}},{d:[".fjseox{display:none;}",".f1ewtqcl{box-sizing:border-box;}",".f132xexn{max-width:240px;}",".f158kwzp{cursor:default;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".f10ra9hq{padding-top:4px;}",".fd9xhir{padding-right:11px;}",".f1jlaasf{padding-left:11px;}",".f1d7kygh{padding-bottom:6px;}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f19n0e5{color:var(--colorNeutralForeground1);}",".fxeb0a7{-webkit-filter:drop-shadow(0 0 2px var(--colorNeutralShadowAmbient)) drop-shadow(0 4px 8px var(--colorNeutralShadowKey));filter:drop-shadow(0 0 2px var(--colorNeutralShadowAmbient)) drop-shadow(0 4px 8px var(--colorNeutralShadowKey));}",".ftgm304{display:block;}",".fg3r6xk{background-color:var(--colorNeutralBackgroundStatic);}",".fonrgv7{color:var(--colorNeutralForegroundStaticInverted);}",".f1euv43f{position:absolute;}",".f1u2r49w{background-color:inherit;}",".fd7fpy0{visibility:hidden;}",".f1bsuimh{z-index:-1;}",".f1ekdpwm{width:8.484px;}",".f83vc9z{height:8.484px;}",'.f1wl9k8s::before{content:"";}',".f1wkw4r9::before{visibility:visible;}",".f1j7ml58::before{position:absolute;}",".fyl8oag::before{box-sizing:border-box;}",".frdoeuz::before{width:inherit;}",".fb81m9q::before{height:inherit;}",".f1ljr5q2::before{background-color:inherit;}",".fyfemzf::before{border-right-width:1px;}",".focyt6c::before{border-right-style:solid;}",".fnhxbxj::before{border-right-color:var(--colorTransparentStroke);}",".fdw6hkg::before{border-bottom-width:1px;}",".f11yjt3y::before{border-bottom-style:solid;}",".f1172wan::before{border-bottom-color:var(--colorTransparentStroke);}",".f9e5op9::before{border-bottom-right-radius:var(--borderRadiusSmall);}",".f112wvtl::before{border-bottom-left-radius:var(--borderRadiusSmall);}",".ftj5xct::before{-webkit-transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);-moz-transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);-ms-transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);transform:rotate(var(--angle)) translate(0, 50%) rotate(45deg);}",".fyavhwi::before{-webkit-transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);-moz-transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);-ms-transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);transform:rotate(var(--angle)) translate(0, 50%) rotate(-45deg);}",'[data-popper-placement^="top"] .f1773hnp{bottom:-1px;}','[data-popper-placement^="top"] .f1n8855c{--angle:0;}','[data-popper-placement^="right"] .f1v7783n{left:-1px;}','[data-popper-placement^="right"] .fsw6im5{--angle:90deg;}','[data-popper-placement^="bottom"] .fh2hsk5{top:-1px;}','[data-popper-placement^="bottom"] .f159pzir{--angle:180deg;}','[data-popper-placement^="left"] .f11yvu4{right:-1px;}','[data-popper-placement^="left"] .fm1ycve{--angle:270deg;}']}),_ce=e=>{const t=Ece();return e.content.className=et(yce.content,t.root,e.appearance==="inverted"&&t.inverted,e.visible&&t.visible,e.content.className),e.arrowClassName=t.arrow,e},cl=e=>{const t=vce(e);return _ce(t),bce(t)};cl.displayName="Tooltip";cl.isFluentTriggerComponent=!0;const Tce=e=>{const{slots:t,slotProps:n}=Jn(e),{iconOnly:r,iconPosition:o}=e;return T.createElement(t.root,{...n.root},o!=="after"&&t.icon&&T.createElement(t.icon,{...n.icon}),!r&&e.root.children,o==="after"&&t.icon&&T.createElement(t.icon,{...n.icon}))},bD=T.createContext(void 0),wce={};bD.Provider;const kce=()=>{var e;return(e=T.useContext(bD))!==null&&e!==void 0?e:wce},Sce=(e,t)=>{const{size:n}=kce(),{appearance:r="secondary",as:o="button",disabled:i=!1,disabledFocusable:a=!1,icon:s,iconPosition:l="before",shape:u="rounded",size:d=n??"medium"}=e,h=$t(s);return{appearance:r,disabled:i,disabledFocusable:a,iconPosition:l,shape:u,size:d,iconOnly:!!(h!=null&&h.children&&!e.children),components:{root:"button",icon:"span"},root:vr(o,bae(e,{required:!0,defaultProps:{ref:t,type:"button"}})),icon:h}},N6={root:"fui-Button",icon:"fui-Button__icon"},xce=$c("rsawnvh","r1eny37h",[".rsawnvh{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;box-sizing:border-box;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;text-decoration-line:none;vertical-align:middle;margin:0;overflow:hidden;background-color:var(--colorNeutralBackground1);color:var(--colorNeutralForeground1);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);font-family:var(--fontFamilyBase);outline-style:none;padding:5px var(--spacingHorizontalM);min-width:96px;border-radius:var(--borderRadiusMedium);font-size:var(--fontSizeBase300);font-weight:var(--fontWeightSemibold);line-height:var(--lineHeightBase300);transition-duration:var(--durationFaster);transition-property:background,border,color;transition-timing-function:var(--curveEasyEase);}",".rsawnvh:hover{background-color:var(--colorNeutralBackground1Hover);border-color:var(--colorNeutralStroke1Hover);color:var(--colorNeutralForeground1Hover);cursor:pointer;}",".rsawnvh:hover .fui-Icon-filled{display:inline;}",".rsawnvh:hover .fui-Icon-regular{display:none;}",".rsawnvh:hover:active{background-color:var(--colorNeutralBackground1Pressed);border-color:var(--colorNeutralStroke1Pressed);color:var(--colorNeutralForeground1Pressed);outline-style:none;}",".rsawnvh:hover:active .fui-Icon-filled{display:inline;}",".rsawnvh:hover:active .fui-Icon-regular{display:none;}","@media screen and (prefers-reduced-motion: reduce){.rsawnvh{transition-duration:0.01ms;}}","@media (forced-colors: active){.rsawnvh:focus{border-color:ButtonText;}.rsawnvh:hover{background-color:HighlightText;border-color:Highlight;color:Highlight;forced-color-adjust:none;}.rsawnvh:hover:active{background-color:HighlightText;border-color:Highlight;color:Highlight;forced-color-adjust:none;}}",".rsawnvh:focus{outline-style:none;}",".rsawnvh:focus-visible{outline-style:none;}",".rsawnvh[data-fui-focus-visible]{border-color:var(--colorTransparentStroke);border-radius:var(--borderRadiusMedium);outline:var(--strokeWidthThick) solid var(--colorTransparentStroke);box-shadow:var(--shadow4),0 0 0 2px var(--colorStrokeFocus2);z-index:1;}",".r1eny37h{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;box-sizing:border-box;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;text-decoration-line:none;vertical-align:middle;margin:0;overflow:hidden;background-color:var(--colorNeutralBackground1);color:var(--colorNeutralForeground1);border:var(--strokeWidthThin) solid var(--colorNeutralStroke1);font-family:var(--fontFamilyBase);outline-style:none;padding:5px var(--spacingHorizontalM);min-width:96px;border-radius:var(--borderRadiusMedium);font-size:var(--fontSizeBase300);font-weight:var(--fontWeightSemibold);line-height:var(--lineHeightBase300);transition-duration:var(--durationFaster);transition-property:background,border,color;transition-timing-function:var(--curveEasyEase);}",".r1eny37h:hover{background-color:var(--colorNeutralBackground1Hover);border-color:var(--colorNeutralStroke1Hover);color:var(--colorNeutralForeground1Hover);cursor:pointer;}",".r1eny37h:hover .fui-Icon-filled{display:inline;}",".r1eny37h:hover .fui-Icon-regular{display:none;}",".r1eny37h:hover:active{background-color:var(--colorNeutralBackground1Pressed);border-color:var(--colorNeutralStroke1Pressed);color:var(--colorNeutralForeground1Pressed);outline-style:none;}",".r1eny37h:hover:active .fui-Icon-filled{display:inline;}",".r1eny37h:hover:active .fui-Icon-regular{display:none;}","@media screen and (prefers-reduced-motion: reduce){.r1eny37h{transition-duration:0.01ms;}}","@media (forced-colors: active){.r1eny37h:focus{border-color:ButtonText;}.r1eny37h:hover{background-color:HighlightText;border-color:Highlight;color:Highlight;forced-color-adjust:none;}.r1eny37h:hover:active{background-color:HighlightText;border-color:Highlight;color:Highlight;forced-color-adjust:none;}}",".r1eny37h:focus{outline-style:none;}",".r1eny37h:focus-visible{outline-style:none;}",".r1eny37h[data-fui-focus-visible]{border-color:var(--colorTransparentStroke);border-radius:var(--borderRadiusMedium);outline:var(--strokeWidthThick) solid var(--colorTransparentStroke);box-shadow:var(--shadow4),0 0 0 2px var(--colorStrokeFocus2);z-index:1;}"]),Cce=$c("rywnvv2",null,[".rywnvv2{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;font-size:20px;height:20px;width:20px;--fui-Button__icon--spacing:var(--spacingHorizontalSNudge);}"]),Ace=pt({outline:{De3pzq:"f1c21dwh",Jwef8y:"fjxutwb",iro3zm:"fwiml72"},primary:{De3pzq:"ffp7eso",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],sj55zd:"f1phragk",Jwef8y:"f15wkkf3",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],Bi91k9c:"f1rq72xc",iro3zm:"fnp9lpt",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"],B2d53fq:"f1d6v5y2"},secondary:{},subtle:{De3pzq:"fhovq9v",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],sj55zd:"fkfq4zb",Jwef8y:"f1t94bn6",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],Bi91k9c:"fnwyq0v",Bbdnnc7:"fy5bs14",iro3zm:"fsv2rcd",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"],B2d53fq:"f1omzyqd",x3br3k:"fj8yq94"},transparent:{De3pzq:"f1c21dwh",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],sj55zd:"fkfq4zb",Jwef8y:"fjxutwb",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],Bi91k9c:"f139oj5f",iro3zm:"fwiml72",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"],B2d53fq:"f1fg1p5m"},circular:{Bbmb7ep:["f8fbkgy","f1nfllo7"],Beyfa6y:["f1nfllo7","f8fbkgy"],B7oj6ja:["f1djnp8u","f1s8kh49"],Btl43ni:["f1s8kh49","f1djnp8u"]},rounded:{},square:{Bbmb7ep:["fzi6hpg","fyowgf4"],Beyfa6y:["fyowgf4","fzi6hpg"],B7oj6ja:["f3fg2lr","f13av6d4"],Btl43ni:["f13av6d4","f3fg2lr"]},small:{Bf4jedk:"fh7ncta",z8tnut:"f1khb0e9",z189sj:["f1vdfbxk","f1f5gg8d"],Byoj8tv:"f1jnq6q7",uwmqm3:["f1f5gg8d","f1vdfbxk"],Bbmb7ep:["fclariu","fyjfh2l"],Beyfa6y:["fyjfh2l","fclariu"],B7oj6ja:["f11xeu6h","f1knf8zw"],Btl43ni:["f1knf8zw","f11xeu6h"],Be2twd7:"fy9rknc",Bhrd7zp:"figsok6",Bg96gwp:"fwrc4pm"},smallWithIcon:{Byoj8tv:"f1brlhvm",z8tnut:"f1sl3k7w"},medium:{},large:{Bf4jedk:"f14es27b",z8tnut:"fp9bwmr",z189sj:["fjodcmx","fhx4nu"],Byoj8tv:"f150uoa4",uwmqm3:["fhx4nu","fjodcmx"],Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],Be2twd7:"fod5ikn",Bhrd7zp:"fl43uef",Bg96gwp:"faaz57k"},largeWithIcon:{Byoj8tv:"fy7v416",z8tnut:"f1a1bwwz"}},{d:[".f1c21dwh{background-color:var(--colorTransparentBackground);}",".ffp7eso{background-color:var(--colorBrandBackground);}",".f1p3nwhy{border-top-color:transparent;}",".f11589ue{border-right-color:transparent;}",".f1pdflbu{border-left-color:transparent;}",".f1q5o8ev{border-bottom-color:transparent;}",".f1phragk{color:var(--colorNeutralForegroundOnBrand);}",".fhovq9v{background-color:var(--colorSubtleBackground);}",".fkfq4zb{color:var(--colorNeutralForeground2);}",".f8fbkgy{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1nfllo7{border-bottom-left-radius:var(--borderRadiusCircular);}",".f1djnp8u{border-top-right-radius:var(--borderRadiusCircular);}",".f1s8kh49{border-top-left-radius:var(--borderRadiusCircular);}",".fzi6hpg{border-bottom-right-radius:var(--borderRadiusNone);}",".fyowgf4{border-bottom-left-radius:var(--borderRadiusNone);}",".f3fg2lr{border-top-right-radius:var(--borderRadiusNone);}",".f13av6d4{border-top-left-radius:var(--borderRadiusNone);}",".fh7ncta{min-width:64px;}",".f1khb0e9{padding-top:3px;}",".f1vdfbxk{padding-right:var(--spacingHorizontalS);}",".f1f5gg8d{padding-left:var(--spacingHorizontalS);}",".f1jnq6q7{padding-bottom:3px;}",".fclariu{border-bottom-right-radius:3px;}",".fyjfh2l{border-bottom-left-radius:3px;}",".f11xeu6h{border-top-right-radius:3px;}",".f1knf8zw{border-top-left-radius:3px;}",".fy9rknc{font-size:var(--fontSizeBase200);}",".figsok6{font-weight:var(--fontWeightRegular);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".f1brlhvm{padding-bottom:1px;}",".f1sl3k7w{padding-top:1px;}",".f14es27b{min-width:96px;}",".fp9bwmr{padding-top:8px;}",".fjodcmx{padding-right:var(--spacingHorizontalL);}",".fhx4nu{padding-left:var(--spacingHorizontalL);}",".f150uoa4{padding-bottom:8px;}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".fl43uef{font-weight:var(--fontWeightSemibold);}",".faaz57k{line-height:var(--lineHeightBase400);}",".fy7v416{padding-bottom:7px;}",".f1a1bwwz{padding-top:7px;}"],h:[".fjxutwb:hover{background-color:var(--colorTransparentBackgroundHover);}",".fwiml72:hover:active{background-color:var(--colorTransparentBackgroundPressed);}",".f15wkkf3:hover{background-color:var(--colorBrandBackgroundHover);}",".f1s2uweq:hover{border-top-color:transparent;}",".fr80ssc:hover{border-right-color:transparent;}",".fecsdlb:hover{border-left-color:transparent;}",".f1ukrpxl:hover{border-bottom-color:transparent;}",".f1rq72xc:hover{color:var(--colorNeutralForegroundOnBrand);}",".fnp9lpt:hover:active{background-color:var(--colorBrandBackgroundPressed);}",".f1h0usnq:hover:active{border-top-color:transparent;}",".fs4ktlq:hover:active{border-right-color:transparent;}",".fx2bmrt:hover:active{border-left-color:transparent;}",".f16h9ulv:hover:active{border-bottom-color:transparent;}",".f1d6v5y2:hover:active{color:var(--colorNeutralForegroundOnBrand);}",".f1t94bn6:hover{background-color:var(--colorSubtleBackgroundHover);}",".fnwyq0v:hover{color:var(--colorNeutralForeground2Hover);}",".fy5bs14:hover .fui-Button__icon{color:var(--colorNeutralForeground2BrandHover);}",".fsv2rcd:hover:active{background-color:var(--colorSubtleBackgroundPressed);}",".f1omzyqd:hover:active{color:var(--colorNeutralForeground2Pressed);}",".fj8yq94:hover:active .fui-Button__icon{color:var(--colorNeutralForeground2BrandPressed);}",".f139oj5f:hover{color:var(--colorNeutralForeground2BrandHover);}",".f1fg1p5m:hover:active{color:var(--colorNeutralForeground2BrandPressed);}"]}),Nce=pt({base:{De3pzq:"f1bg9a2p",g2u3we:"f1jj8ep1",h3c5rm:["f15xbau","fy0fskl"],B9xav0g:"f4ikngz",zhjwy3:["fy0fskl","f15xbau"],sj55zd:"f1s2aq7o",Bceei9c:"fdrzuqr",Jwef8y:"f1falr9n",Bgoe8wy:"f12mpcsy",Bwzppfd:["f1gwvigk","f18rmfxp"],oetu4i:"f1jnshp0",gg5e9n:["f18rmfxp","f1gwvigk"],Bi91k9c:"fvgxktp",eoavqd:"fphbwmw",Bk3fhr4:"f19vpps7",Bmfj8id:"fv5swzo",iro3zm:"f1t6o4dc",b661bw:"f10ztigi",Bk6r4ia:["f1ft5sdu","f1gzf82w"],B9zn80p:"f12zbtn2",Bpld233:["f1gzf82w","f1ft5sdu"],B2d53fq:"fcvwxyo",c3iz72:"f8w4c43",em6i61:"f1ol4fw6",vm6p8p:"f1q1lw4e"},highContrast:{Bjwas2f:"fg455y9",Bn1d65q:["f1rvyvqg","f14g86mu"],Bxeuatn:"f1cwzwz",n51gp8:["f14g86mu","f1rvyvqg"],Bbusuzp:"f1dcs8yz",G867l3:"fjwq6ea",gdbnj:["f1lr3nhc","f1mbxvi6"],mxns5l:"fn5gmvv",o3nasb:["f1mbxvi6","f1lr3nhc"],pgvf35:"f53ppgq",Bh7lczh:["f1663y11","f80fkiy"],dpv3f4:"f18v5270",Bpnjhaq:["f80fkiy","f1663y11"],ze5xyy:"f1kc2mi9",Bf756sw:"fihuait",Bow2dr7:["fnxhupq","fyd6l6x"],Bvhedfk:"fx507ft",Gye4lf:["fyd6l6x","fnxhupq"],pc6evw:"fb3rf2x"},outline:{De3pzq:"f1c21dwh",Jwef8y:"f9ql6rf",iro3zm:"f3h1zc4"},primary:{g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"]},secondary:{},subtle:{De3pzq:"f1c21dwh",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],Jwef8y:"f9ql6rf",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],iro3zm:"f3h1zc4",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"]},transparent:{De3pzq:"f1c21dwh",g2u3we:"f1p3nwhy",h3c5rm:["f11589ue","f1pdflbu"],B9xav0g:"f1q5o8ev",zhjwy3:["f1pdflbu","f11589ue"],Jwef8y:"f9ql6rf",Bgoe8wy:"f1s2uweq",Bwzppfd:["fr80ssc","fecsdlb"],oetu4i:"f1ukrpxl",gg5e9n:["fecsdlb","fr80ssc"],iro3zm:"f3h1zc4",b661bw:"f1h0usnq",Bk6r4ia:["fs4ktlq","fx2bmrt"],B9zn80p:"f16h9ulv",Bpld233:["fx2bmrt","fs4ktlq"]}},{d:[".f1bg9a2p{background-color:var(--colorNeutralBackgroundDisabled);}",".f1jj8ep1{border-top-color:var(--colorNeutralStrokeDisabled);}",".f15xbau{border-right-color:var(--colorNeutralStrokeDisabled);}",".fy0fskl{border-left-color:var(--colorNeutralStrokeDisabled);}",".f4ikngz{border-bottom-color:var(--colorNeutralStrokeDisabled);}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".fdrzuqr{cursor:not-allowed;}",".f1c21dwh{background-color:var(--colorTransparentBackground);}",".f1p3nwhy{border-top-color:transparent;}",".f11589ue{border-right-color:transparent;}",".f1pdflbu{border-left-color:transparent;}",".f1q5o8ev{border-bottom-color:transparent;}"],h:[".f1falr9n:hover{background-color:var(--colorNeutralBackgroundDisabled);}",".f12mpcsy:hover{border-top-color:var(--colorNeutralStrokeDisabled);}",".f1gwvigk:hover{border-right-color:var(--colorNeutralStrokeDisabled);}",".f18rmfxp:hover{border-left-color:var(--colorNeutralStrokeDisabled);}",".f1jnshp0:hover{border-bottom-color:var(--colorNeutralStrokeDisabled);}",".fvgxktp:hover{color:var(--colorNeutralForegroundDisabled);}",".fphbwmw:hover{cursor:not-allowed;}",".f19vpps7:hover .fui-Icon-filled{display:none;}",".fv5swzo:hover .fui-Icon-regular{display:inline;}",".f1t6o4dc:hover:active{background-color:var(--colorNeutralBackgroundDisabled);}",".f10ztigi:hover:active{border-top-color:var(--colorNeutralStrokeDisabled);}",".f1ft5sdu:hover:active{border-right-color:var(--colorNeutralStrokeDisabled);}",".f1gzf82w:hover:active{border-left-color:var(--colorNeutralStrokeDisabled);}",".f12zbtn2:hover:active{border-bottom-color:var(--colorNeutralStrokeDisabled);}",".fcvwxyo:hover:active{color:var(--colorNeutralForegroundDisabled);}",".f8w4c43:hover:active{cursor:not-allowed;}",".f1ol4fw6:hover:active .fui-Icon-filled{display:none;}",".f1q1lw4e:hover:active .fui-Icon-regular{display:inline;}",".f9ql6rf:hover{background-color:var(--colorTransparentBackground);}",".f3h1zc4:hover:active{background-color:var(--colorTransparentBackground);}",".f1s2uweq:hover{border-top-color:transparent;}",".fr80ssc:hover{border-right-color:transparent;}",".fecsdlb:hover{border-left-color:transparent;}",".f1ukrpxl:hover{border-bottom-color:transparent;}",".f1h0usnq:hover:active{border-top-color:transparent;}",".fs4ktlq:hover:active{border-right-color:transparent;}",".fx2bmrt:hover:active{border-left-color:transparent;}",".f16h9ulv:hover:active{border-bottom-color:transparent;}"],m:[["@media (forced-colors: active){.fg455y9{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1rvyvqg{border-right-color:GrayText;}.f14g86mu{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1cwzwz{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f14g86mu{border-left-color:GrayText;}.f1rvyvqg{border-right-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1dcs8yz{color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fjwq6ea:focus{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1lr3nhc:focus{border-right-color:GrayText;}.f1mbxvi6:focus{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fn5gmvv:focus{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1mbxvi6:focus{border-left-color:GrayText;}.f1lr3nhc:focus{border-right-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f53ppgq:hover{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1663y11:hover{border-right-color:GrayText;}.f80fkiy:hover{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f18v5270:hover{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f80fkiy:hover{border-left-color:GrayText;}.f1663y11:hover{border-right-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1kc2mi9:hover{color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fihuait:hover:active{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fnxhupq:hover:active{border-right-color:GrayText;}.fyd6l6x:hover:active{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fx507ft:hover:active{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fyd6l6x:hover:active{border-left-color:GrayText;}.fnxhupq:hover:active{border-right-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.fb3rf2x:hover:active{color:GrayText;}}",{m:"(forced-colors: active)"}]]}),Fce=pt({circular:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",kdpuga:["fanj13w","f1gou5sz"],Bw81rd7:["f1gou5sz","fanj13w"],B6xbmo0:["fulf6x3","foeb2x"],dm238s:["foeb2x","fulf6x3"]},rounded:{},square:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",kdpuga:["f1ndz5i7","f1co4qro"],Bw81rd7:["f1co4qro","f1ndz5i7"],B6xbmo0:["f146y5a9","f1k2ftg"],dm238s:["f1k2ftg","f146y5a9"]},primary:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",B8q5s1w:"f15my96h",Bci5o5g:["f8yq1e5","f59w28j"],n8qw10:"f1mze7uc",Bdrgwmp:["f59w28j","f8yq1e5"],j6ew2k:"ftbnf46"},small:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",kdpuga:["fg3gtdo","fwii5mg"],Bw81rd7:["fwii5mg","fg3gtdo"],B6xbmo0:["f1palphq","f12nxie7"],dm238s:["f12nxie7","f1palphq"]},medium:{},large:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",kdpuga:["ft3lys4","f1la4x2g"],Bw81rd7:["f1la4x2g","ft3lys4"],B6xbmo0:["f156y0zm","fakimq4"],dm238s:["fakimq4","f156y0zm"]}},{f:[".ftqa4ok:focus{outline-style:none;}"],i:[".f2hkw1w:focus-visible{outline-style:none;}"],d:[".fanj13w[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1gou5sz[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusCircular);}",".fulf6x3[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusCircular);}",".foeb2x[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusCircular);}",".f1ndz5i7[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusNone);}",".f1co4qro[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusNone);}",".f146y5a9[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusNone);}",".f1k2ftg[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusNone);}",".f15my96h[data-fui-focus-visible]{border-top-color:var(--colorNeutralForegroundOnBrand);}",".f8yq1e5[data-fui-focus-visible]{border-right-color:var(--colorNeutralForegroundOnBrand);}",".f59w28j[data-fui-focus-visible]{border-left-color:var(--colorNeutralForegroundOnBrand);}",".f1mze7uc[data-fui-focus-visible]{border-bottom-color:var(--colorNeutralForegroundOnBrand);}",".ftbnf46[data-fui-focus-visible]{box-shadow:var(--shadow2),0 0 0 2px var(--colorStrokeFocus2);}",".fg3gtdo[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusSmall);}",".fwii5mg[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusSmall);}",".f1palphq[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusSmall);}",".f12nxie7[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusSmall);}",".ft3lys4[data-fui-focus-visible]{border-bottom-right-radius:var(--borderRadiusLarge);}",".f1la4x2g[data-fui-focus-visible]{border-bottom-left-radius:var(--borderRadiusLarge);}",".f156y0zm[data-fui-focus-visible]{border-top-right-radius:var(--borderRadiusLarge);}",".fakimq4[data-fui-focus-visible]{border-top-left-radius:var(--borderRadiusLarge);}"]}),Ice=pt({small:{z8tnut:"f1sl3k7w",z189sj:["f136y8j8","f10xn8zz"],Byoj8tv:"f1brlhvm",uwmqm3:["f10xn8zz","f136y8j8"],Bf4jedk:"f17fgpbq",B2u0y6b:"f1jt17bm"},medium:{z8tnut:"f1sbtcvk",z189sj:["fwiuce9","f15vdbe4"],Byoj8tv:"fdghr9",uwmqm3:["f15vdbe4","fwiuce9"],Bf4jedk:"fwbmr0d",B2u0y6b:"f44c6la"},large:{z8tnut:"f1a1bwwz",z189sj:["f18k1jr3","f1rtp3s9"],Byoj8tv:"fy7v416",uwmqm3:["f1rtp3s9","f18k1jr3"],Bf4jedk:"f12clzc2",B2u0y6b:"fjy1crr"}},{d:[".f1sl3k7w{padding-top:1px;}",".f136y8j8{padding-right:1px;}",".f10xn8zz{padding-left:1px;}",".f1brlhvm{padding-bottom:1px;}",".f17fgpbq{min-width:24px;}",".f1jt17bm{max-width:24px;}",".f1sbtcvk{padding-top:5px;}",".fwiuce9{padding-right:5px;}",".f15vdbe4{padding-left:5px;}",".fdghr9{padding-bottom:5px;}",".fwbmr0d{min-width:32px;}",".f44c6la{max-width:32px;}",".f1a1bwwz{padding-top:7px;}",".f18k1jr3{padding-right:7px;}",".f1rtp3s9{padding-left:7px;}",".fy7v416{padding-bottom:7px;}",".f12clzc2{min-width:40px;}",".fjy1crr{max-width:40px;}"]}),Bce=pt({small:{Be2twd7:"fe5j1ua",Bqenvij:"fjamq6b",a9b677:"f64fuq3",Bqrlyyl:"fbaiahx"},medium:{},large:{Be2twd7:"f1rt2boy",Bqenvij:"frvgh55",a9b677:"fq4mcun",Bqrlyyl:"f1exjqw5"},before:{t21cq0:["f1nizpg2","f1a695kz"]},after:{Frg6f3:["f1a695kz","f1nizpg2"]}},{d:[".fe5j1ua{font-size:20px;}",".fjamq6b{height:20px;}",".f64fuq3{width:20px;}",".fbaiahx{--fui-Button__icon--spacing:var(--spacingHorizontalXS);}",".f1rt2boy{font-size:24px;}",".frvgh55{height:24px;}",".fq4mcun{width:24px;}",".f1exjqw5{--fui-Button__icon--spacing:var(--spacingHorizontalSNudge);}",".f1nizpg2{margin-right:var(--fui-Button__icon--spacing);}",".f1a695kz{margin-left:var(--fui-Button__icon--spacing);}"]}),Rce=e=>{const t=xce(),n=Cce(),r=Ace(),o=Nce(),i=Fce(),a=Ice(),s=Bce(),{appearance:l,disabled:u,disabledFocusable:d,icon:h,iconOnly:p,iconPosition:m,shape:v,size:_}=e;return e.root.className=et(N6.root,t,l&&r[l],r[_],h&&_==="small"&&r.smallWithIcon,h&&_==="large"&&r.largeWithIcon,r[v],(u||d)&&o.base,(u||d)&&o.highContrast,l&&(u||d)&&o[l],l==="primary"&&i.primary,i[_],i[v],p&&a[_],e.root.className),e.icon&&(e.icon.className=et(N6.icon,n,e.root.children!==void 0&&e.root.children!==null&&s[m],s[_],e.icon.className)),e},En=T.forwardRef((e,t)=>{const n=Sce(e,t);return Rce(n),Tce(n)});En.displayName="Button";const Oce=(e,t)=>{const{disabled:n=!1,required:r=!1,weight:o="regular",size:i="medium"}=e;return{disabled:n,required:$t(r===!0?"*":r||void 0,{defaultProps:{"aria-hidden":"true"}}),weight:o,size:i,components:{root:"label",required:"span"},root:vr("label",{ref:t,...e})}},Dce=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},e.root.children,t.required&&T.createElement(t.required,{...n.required}))},F6={root:"fui-Label",required:"fui-Label__required"},Pce=pt({root:{Bahqtrf:"fk6fouc",sj55zd:"f19n0e5"},disabled:{sj55zd:"f1s2aq7o"},required:{sj55zd:"f1whyuy6",uwmqm3:["fycuoez","f8wuabp"]},requiredDisabled:{sj55zd:"f1s2aq7o"},small:{Be2twd7:"fy9rknc",Bg96gwp:"fwrc4pm"},medium:{Be2twd7:"fkhj508",Bg96gwp:"f1i3iumi"},large:{Be2twd7:"fod5ikn",Bg96gwp:"faaz57k",Bhrd7zp:"fl43uef"},semibold:{Bhrd7zp:"fl43uef"}},{d:[".fk6fouc{font-family:var(--fontFamilyBase);}",".f19n0e5{color:var(--colorNeutralForeground1);}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".f1whyuy6{color:var(--colorPaletteRedForeground3);}",".fycuoez{padding-left:4px;}",".f8wuabp{padding-right:4px;}",".fy9rknc{font-size:var(--fontSizeBase200);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".fkhj508{font-size:var(--fontSizeBase300);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".faaz57k{line-height:var(--lineHeightBase400);}",".fl43uef{font-weight:var(--fontWeightSemibold);}"]}),Mce=e=>{const t=Pce();return e.root.className=et(F6.root,t.root,e.disabled&&t.disabled,t[e.size],e.weight==="semibold"&&t.semibold,e.root.className),e.required&&(e.required.className=et(F6.required,t.required,e.disabled&&t.requiredDisabled,e.required.className)),e},Zo=T.forwardRef((e,t)=>{const n=Oce(e,t);return Mce(n),Dce(n)});Zo.displayName="Label";const Lce=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},t.label&&T.createElement(t.label,{...n.label}),n.root.children,t.validationMessage&&T.createElement(t.validationMessage,{...n.validationMessage},t.validationMessageIcon&&T.createElement(t.validationMessageIcon,{...n.validationMessageIcon}),n.validationMessage.children),t.hint&&T.createElement(t.hint,{...n.hint}))},jce={error:T.createElement(gse,null),warning:T.createElement(vle,null),success:T.createElement(rse,null),none:void 0},zce=(e,t)=>{var n,r,o,i;const{children:a,orientation:s="vertical",required:l,validationState:u=e.validationMessage?"error":"none",size:d}=e,h=lo("field-"),p=vr("div",{...e,ref:t},["children"]),m=$t(e.label,{defaultProps:{id:h+"__label",required:l,size:d}}),v=$t(e.validationMessage,{defaultProps:{id:h+"__validationMessage",role:u==="error"?"alert":void 0}}),_=$t(e.hint,{defaultProps:{id:h+"__hint"}}),b=jce[u],E=$t(e.validationMessageIcon,{required:!!b,defaultProps:{children:b}}),w=T.isValidElement(a)?{...a.props}:{};return m&&((n=w["aria-labelledby"])!==null&&n!==void 0||(w["aria-labelledby"]=m.id),m.htmlFor||((r=w.id)!==null&&r!==void 0||(w.id=h+"__control"),m.htmlFor=w.id)),(v||_)&&(w["aria-describedby"]=[v==null?void 0:v.id,_==null?void 0:_.id,w["aria-describedby"]].filter(Boolean).join(" ")),u==="error"&&((o=w["aria-invalid"])!==null&&o!==void 0||(w["aria-invalid"]=!0)),l&&((i=w["aria-required"])!==null&&i!==void 0||(w["aria-required"]=!0)),T.isValidElement(a)?p.children=T.cloneElement(a,w):typeof a=="function"&&(p.children=a(w)),{orientation:s,validationState:u,components:{root:"div",label:Zo,validationMessage:"div",validationMessageIcon:"span",hint:"div"},root:p,label:m,validationMessageIcon:E,validationMessage:v,hint:_}},ah={root:"fui-Field",label:"fui-Field__label",validationMessage:"fui-Field__validationMessage",validationMessageIcon:"fui-Field__validationMessageIcon",hint:"fui-Field__hint"},Hce=pt({base:{mc9l5x:"f13qh94s"},horizontal:{Budl1dq:"f2wwaib",wkccdc:"f1645dqt"},horizontalNoLabel:{uwmqm3:["f15jqgz8","fggqkej"],Budl1dq:"f1c2z91y"}},{d:[".f13qh94s{display:grid;}",".f2wwaib{grid-template-columns:33% 1fr;}",".f1645dqt{grid-template-rows:auto auto auto 1fr;}",".f15jqgz8{padding-left:33%;}",".fggqkej{padding-right:33%;}",".f1c2z91y{grid-template-columns:1fr;}"]}),Uce=pt({base:{z8tnut:"fclwglc",Byoj8tv:"fywfov9"},large:{z8tnut:"f1sl3k7w",Byoj8tv:"f1brlhvm"},vertical:{jrapky:"fyacil5"},verticalLarge:{jrapky:"f8l5zjj"},horizontal:{t21cq0:["fkujibs","f199hnxi"],Ijaq50:"f16hsg94",nk6f5a:"f1nzqi2z"}},{d:[".fclwglc{padding-top:var(--spacingVerticalXXS);}",".fywfov9{padding-bottom:var(--spacingVerticalXXS);}",".f1sl3k7w{padding-top:1px;}",".f1brlhvm{padding-bottom:1px;}",".fyacil5{margin-bottom:var(--spacingVerticalXXS);}",".f8l5zjj{margin-bottom:var(--spacingVerticalXS);}",".fkujibs{margin-right:var(--spacingHorizontalM);}",".f199hnxi{margin-left:var(--spacingHorizontalM);}",".f16hsg94{grid-row-start:1;}",".f1nzqi2z{grid-row-end:-1;}"]}),qce=$c("r5c4z9l",null,[".r5c4z9l{margin-top:var(--spacingVerticalXXS);color:var(--colorNeutralForeground3);font-family:var(--fontFamilyBase);font-size:var(--fontSizeBase200);font-weight:var(--fontWeightRegular);line-height:var(--lineHeightBase200);}"]),$ce=pt({error:{sj55zd:"f1hcrxcs"},withIcon:{uwmqm3:["frawy03","fg4c52"]}},{d:[".f1hcrxcs{color:var(--colorPaletteRedForeground1);}",".frawy03{padding-left:calc(12px + var(--spacingHorizontalXS));}",".fg4c52{padding-right:calc(12px + var(--spacingHorizontalXS));}"]}),Wce=$c("ra7h1uk","r1rh6bd7",[".ra7h1uk{display:inline-block;font-size:12px;margin-left:calc(-12px - var(--spacingHorizontalXS));margin-right:var(--spacingHorizontalXS);line-height:0;vertical-align:-1px;}",".r1rh6bd7{display:inline-block;font-size:12px;margin-right:calc(-12px - var(--spacingHorizontalXS));margin-left:var(--spacingHorizontalXS);line-height:0;vertical-align:-1px;}"]),Gce=pt({error:{sj55zd:"f1hcrxcs"},warning:{sj55zd:"f1k5f75o"},success:{sj55zd:"ffmvakt"}},{d:[".f1hcrxcs{color:var(--colorPaletteRedForeground1);}",".f1k5f75o{color:var(--colorPaletteDarkOrangeForeground1);}",".ffmvakt{color:var(--colorPaletteGreenForeground1);}"]}),Kce=e=>{const{validationState:t}=e,n=e.orientation==="horizontal",r=Hce();e.root.className=et(ah.root,r.base,n&&r.horizontal,n&&!e.label&&r.horizontalNoLabel,e.root.className);const o=Uce();e.label&&(e.label.className=et(ah.label,o.base,n&&o.horizontal,!n&&o.vertical,e.label.size==="large"&&o.large,!n&&e.label.size==="large"&&o.verticalLarge,e.label.className));const i=Wce(),a=Gce();e.validationMessageIcon&&(e.validationMessageIcon.className=et(ah.validationMessageIcon,i,t!=="none"&&a[t],e.validationMessageIcon.className));const s=qce(),l=$ce();e.validationMessage&&(e.validationMessage.className=et(ah.validationMessage,s,t==="error"&&l.error,!!e.validationMessageIcon&&l.withIcon,e.validationMessage.className)),e.hint&&(e.hint.className=et(ah.hint,s,e.hint.className))},yD=T.forwardRef((e,t)=>{const n=zce(e,t);return Kce(n),Lce(n)});yD.displayName="Field";const Vce=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},n.root.children!==void 0&&T.createElement(t.wrapper,{...n.wrapper},n.root.children))},Yce=(e,t)=>{const{alignContent:n="center",appearance:r="default",inset:o=!1,vertical:i=!1,wrapper:a}=e,s=lo("divider-");return{alignContent:n,appearance:r,inset:o,vertical:i,components:{root:"div",wrapper:"div"},root:vr("div",{role:"separator","aria-orientation":i?"vertical":"horizontal","aria-labelledby":e.children?s:void 0,...e,ref:t}),wrapper:$t(a,{required:!0,defaultProps:{id:s,children:e.children}})}},I6={root:"fui-Divider",wrapper:"fui-Divider__wrapper"},Qce=pt({base:{Bt984gj:"f122n59",B7ck84d:"f1ewtqcl",mc9l5x:"f22iagw",Beiy3e4:"f1063pyq",Bh6795r:"fqerorx",qhf8xq:"f10pi13n",Bahqtrf:"fk6fouc",Be2twd7:"fy9rknc",Bhrd7zp:"figsok6",Bg96gwp:"fwrc4pm",fsow6f:"f17mccla",Bcvre1j:"fyl8oag",Br0sdwz:"f16vkdww",Bn78ew0:"fhsnbul",li1rpt:"f1gw3sf2",ap17g6:"f1ly5f7u",B771hl4:"f1s3tz6t"},childless:{susq4k:"f1kyqvp9",Bicfajf:["fzynn9s","f1z0ukd1"],jwcpgy:["fekrn8e","ftdg338"],B4rk6o:"fesgyo"},start:{Bsft5z2:"f13zj6fq"},center:{Ftih45:"f1wl9k8s",Bsft5z2:"f13zj6fq"},end:{Ftih45:"f1wl9k8s"},brand:{sj55zd:"f16muhyy",Bq4z7u6:"fcbuu2a",Bk5zm6e:["f1wdw2dr","f1ttio3w"],Bqjgrrk:"f1582fpk",Bm6vgfq:["f1ttio3w","f1wdw2dr"],B0n5ga8:"f1ahrvm8",s924m2:["f1cd3wbc","f17hbk9y"],B1q35kw:"fvrapl0",Gp14am:["f17hbk9y","f1cd3wbc"]},default:{sj55zd:"fkfq4zb",Bq4z7u6:"f1vccso1",Bk5zm6e:["f1geml7w","fjml6kk"],Bqjgrrk:"f1r7kh1m",Bm6vgfq:["fjml6kk","f1geml7w"],B0n5ga8:"f16j7guv",s924m2:["fx01ahm","fj1a37q"],B1q35kw:"fl8d8yv",Gp14am:["fj1a37q","fx01ahm"]},subtle:{sj55zd:"fkfq4zb",Bq4z7u6:"f5g06un",Bk5zm6e:["f13sxdku","f1n015lb"],Bqjgrrk:"f1x6bl8t",Bm6vgfq:["f1n015lb","f13sxdku"],B0n5ga8:"fvod1wy",s924m2:["fwslg65","flk0e17"],B1q35kw:"f103fvts",Gp14am:["flk0e17","fwslg65"]},strong:{sj55zd:"fkfq4zb",Bq4z7u6:"f10tv6oz",Bk5zm6e:["f16xp3sf","f1seuxxq"],Bqjgrrk:"fwrmqbx",Bm6vgfq:["f1seuxxq","f16xp3sf"],B0n5ga8:"ft83z1f",s924m2:["f1g4150c","f192dr6e"],B1q35kw:"f1qnawh6",Gp14am:["f192dr6e","f1g4150c"]}},{d:[".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".f1ewtqcl{box-sizing:border-box;}",".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f1063pyq{-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}",".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}",".f10pi13n{position:relative;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".figsok6{font-weight:var(--fontWeightRegular);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".f17mccla{text-align:center;}",".fyl8oag::before{box-sizing:border-box;}",".f16vkdww::before{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".fhsnbul::before{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}",".f1gw3sf2::after{box-sizing:border-box;}",".f1ly5f7u::after{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f1s3tz6t::after{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}",".f1kyqvp9::before{margin-bottom:0;}",".fzynn9s::before{margin-right:0;}",".f1z0ukd1::before{margin-left:0;}",".fekrn8e::after{margin-left:0;}",".ftdg338::after{margin-right:0;}",".fesgyo::after{margin-top:0;}",'.f13zj6fq::after{content:"";}','.f1wl9k8s::before{content:"";}',".f16muhyy{color:var(--colorBrandForeground1);}",".fcbuu2a::before{border-top-color:var(--colorBrandStroke1);}",".f1wdw2dr::before{border-right-color:var(--colorBrandStroke1);}",".f1ttio3w::before{border-left-color:var(--colorBrandStroke1);}",".f1582fpk::before{border-bottom-color:var(--colorBrandStroke1);}",".f1ahrvm8::after{border-top-color:var(--colorBrandStroke1);}",".f1cd3wbc::after{border-right-color:var(--colorBrandStroke1);}",".f17hbk9y::after{border-left-color:var(--colorBrandStroke1);}",".fvrapl0::after{border-bottom-color:var(--colorBrandStroke1);}",".fkfq4zb{color:var(--colorNeutralForeground2);}",".f1vccso1::before{border-top-color:var(--colorNeutralStroke2);}",".f1geml7w::before{border-right-color:var(--colorNeutralStroke2);}",".fjml6kk::before{border-left-color:var(--colorNeutralStroke2);}",".f1r7kh1m::before{border-bottom-color:var(--colorNeutralStroke2);}",".f16j7guv::after{border-top-color:var(--colorNeutralStroke2);}",".fx01ahm::after{border-right-color:var(--colorNeutralStroke2);}",".fj1a37q::after{border-left-color:var(--colorNeutralStroke2);}",".fl8d8yv::after{border-bottom-color:var(--colorNeutralStroke2);}",".f5g06un::before{border-top-color:var(--colorNeutralStroke3);}",".f13sxdku::before{border-right-color:var(--colorNeutralStroke3);}",".f1n015lb::before{border-left-color:var(--colorNeutralStroke3);}",".f1x6bl8t::before{border-bottom-color:var(--colorNeutralStroke3);}",".fvod1wy::after{border-top-color:var(--colorNeutralStroke3);}",".fwslg65::after{border-right-color:var(--colorNeutralStroke3);}",".flk0e17::after{border-left-color:var(--colorNeutralStroke3);}",".f103fvts::after{border-bottom-color:var(--colorNeutralStroke3);}",".f10tv6oz::before{border-top-color:var(--colorNeutralStroke1);}",".f16xp3sf::before{border-right-color:var(--colorNeutralStroke1);}",".f1seuxxq::before{border-left-color:var(--colorNeutralStroke1);}",".fwrmqbx::before{border-bottom-color:var(--colorNeutralStroke1);}",".ft83z1f::after{border-top-color:var(--colorNeutralStroke1);}",".f1g4150c::after{border-right-color:var(--colorNeutralStroke1);}",".f192dr6e::after{border-left-color:var(--colorNeutralStroke1);}",".f1qnawh6::after{border-bottom-color:var(--colorNeutralStroke1);}"]}),Xce=pt({base:{a9b677:"fly5x3f",Bdkvgpv:"f163fonl",B0qfbqy:"f51yk4v",pbipgd:"f13rof3u",Bm2nyyq:"f8rth92",xrcqlc:"f6czdpx",i5u598:"f1iyka9k"},inset:{uwmqm3:["fjlbh76","f11qrl6u"],z189sj:["f11qrl6u","fjlbh76"]},start:{Ftih45:"f1wl9k8s",Bicfajf:["f1ojjlep","fk1kexq"],Bxwl2t9:"f1he2m4d",jwcpgy:["f12w1bnb","f1558wlj"]},center:{Bicfajf:["f1ojjlep","fk1kexq"],jwcpgy:["f12w1bnb","f1558wlj"]},end:{Bicfajf:["f1ojjlep","fk1kexq"],Bsft5z2:"f13zj6fq",jwcpgy:["f12w1bnb","f1558wlj"],Iy66sp:"f1ayce8x"}},{d:[".fly5x3f{width:100%;}",".f163fonl::before{border-top-style:solid;}",".f51yk4v::before{border-top-width:var(--strokeWidthThin);}",".f13rof3u::before{min-width:8px;}",".f8rth92::after{border-top-style:solid;}",".f6czdpx::after{border-top-width:var(--strokeWidthThin);}",".f1iyka9k::after{min-width:8px;}",".fjlbh76{padding-left:12px;}",".f11qrl6u{padding-right:12px;}",'.f1wl9k8s::before{content:"";}',".f1ojjlep::before{margin-right:12px;}",".fk1kexq::before{margin-left:12px;}",".f1he2m4d::before{max-width:8px;}",".f12w1bnb::after{margin-left:12px;}",".f1558wlj::after{margin-right:12px;}",'.f13zj6fq::after{content:"";}',".f1ayce8x::after{max-width:8px;}"]}),Zce=pt({base:{Beiy3e4:"f1vx9l62",sshi5w:"f16gbxbe",m598lv:["f1yq6w5o","f1jpmc5p"],B4f6apu:["f9sc749","f1x8pvcy"],zkzzav:"fhkwbjy",Barhvk9:["flthirb","ftkbnf5"],Ihftqj:["f13hvwk3","f1en4csx"],Bde111x:"f19onpk6"},inset:{B6of3ja:"f1xdg43u",jrapky:"f1jlhsmd"},withChildren:{sshi5w:"f1tjaq3g"},start:{Ftih45:"f1wl9k8s",susq4k:"fg2pwug",Bbdr6tz:"fkjtzyi",B4rk6o:"f8vk40g"},center:{susq4k:"fg2pwug",B4rk6o:"f8vk40g"},end:{susq4k:"fg2pwug",Bsft5z2:"f13zj6fq",B4rk6o:"f8vk40g",gn64ia:"fqg5mu5"}},{d:[".f1vx9l62{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}",".f16gbxbe{min-height:20px;}",".f1yq6w5o::before{border-right-style:solid;}",".f1jpmc5p::before{border-left-style:solid;}",".f9sc749::before{border-right-width:var(--strokeWidthThin);}",".f1x8pvcy::before{border-left-width:var(--strokeWidthThin);}",".fhkwbjy::before{min-height:8px;}",".flthirb::after{border-right-style:solid;}",".ftkbnf5::after{border-left-style:solid;}",".f13hvwk3::after{border-right-width:var(--strokeWidthThin);}",".f1en4csx::after{border-left-width:var(--strokeWidthThin);}",".f19onpk6::after{min-height:8px;}",".f1xdg43u{margin-top:12px;}",".f1jlhsmd{margin-bottom:12px;}",".f1tjaq3g{min-height:84px;}",'.f1wl9k8s::before{content:"";}',".fg2pwug::before{margin-bottom:12px;}",".fkjtzyi::before{max-height:8px;}",".f8vk40g::after{margin-top:12px;}",'.f13zj6fq::after{content:"";}',".fqg5mu5::after{max-height:8px;}"]}),Jce=e=>{const t=Qce(),n=Xce(),r=Zce(),{alignContent:o,appearance:i,inset:a,vertical:s}=e;return e.root.className=et(I6.root,t.base,t[o],i&&t[i],!s&&n.base,!s&&a&&n.inset,!s&&n[o],s&&r.base,s&&a&&r.inset,s&&r[o],s&&e.root.children!==void 0&&r.withChildren,e.root.children===void 0&&t.childless,e.root.className),e.wrapper&&(e.wrapper.className=et(I6.wrapper,e.wrapper.className)),e},O_=T.forwardRef((e,t)=>{const n=Yce(e,t);return Jce(n),Vce(n)});O_.displayName="Divider";const efe=(e,t)=>{var n;const r=tO(),{size:o="medium",appearance:i=(n=r.inputDefaultAppearance)!==null&&n!==void 0?n:"outline",onChange:a}=e,[s,l]=Wc({state:e.value,defaultState:e.defaultValue,initialState:""}),u=lO({props:e,primarySlotTagName:"input",excludedPropNames:["size","onChange","value","defaultValue"]}),d={size:o,appearance:i,components:{root:"span",input:"input",contentBefore:"span",contentAfter:"span"},input:$t(e.input,{required:!0,defaultProps:{type:"text",ref:t,...u.primary}}),contentAfter:$t(e.contentAfter),contentBefore:$t(e.contentBefore),root:$t(e.root,{required:!0,defaultProps:u.root})};return d.input.value=s,d.input.onChange=Et(h=>{const p=h.target.value;a==null||a(h,{value:p}),l(p)}),d},tfe=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},t.contentBefore&&T.createElement(t.contentBefore,{...n.contentBefore}),T.createElement(t.input,{...n.input}),t.contentAfter&&T.createElement(t.contentAfter,{...n.contentAfter}))},$m={root:"fui-Input",input:"fui-Input__input",contentBefore:"fui-Input__contentBefore",contentAfter:"fui-Input__contentAfter"},nfe=pt({base:{mc9l5x:"ftuwxu6",Bt984gj:"f122n59",Eh141a:"flvyvdh",i8kkvl:"f14mj54c",Belr9w4:"fiut8dr",Bahqtrf:"fk6fouc",Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],qhf8xq:"f10pi13n",B7ck84d:"f1ewtqcl"},interactive:{li1rpt:"f1gw3sf2",Bsft5z2:"f13zj6fq",E3zdtr:"f1mdlcz9",Eqx8gd:["f1a7op3","f1cjjd47"],By385i5:"f1gboi2j",B1piin3:["f1cjjd47","f1a7op3"],Dlnsje:"f145g4dw",d9w3h3:["f1kp91vd","f1ibwz09"],B3778ie:["f1ibwz09","f1kp91vd"],Bcgy8vk:"f1cb6c3",Bw17bha:"f1lh990p",B1q35kw:"f1jc6hxc",Gjdm7m:"f13evtba",b1kco5:"f1yk9hq",Ba2ppi3:"fhwpy7i",F2fol1:"f14ee0xe",lck23g:"f1xhbsuh",df92cz:"fv8e3ye",I188md:"ftb5wc6",umuwi5:"fjw5xc1",Blcqepd:"f1xdyd5c",nplu4u:"fatpbeo",Bioka5o:"fb7uyps",H713fs:"f1cmft4k",B9ooomg:"f1x58t8o",Bercvud:"f1ibeo51",Bbr2w1p:"f14a1fxs",Bduesf4:"f3e99gv",Bpq79vn:"fhljsf7"},small:{sshi5w:"f1pha7fy",z8tnut:"f1g0x7ka",z189sj:["fdw0yi8","fk8j09s"],Byoj8tv:"f1qch9an",uwmqm3:["fk8j09s","fdw0yi8"],Bahqtrf:"fk6fouc",Be2twd7:"fy9rknc",Bhrd7zp:"figsok6",Bg96gwp:"fwrc4pm"},medium:{sshi5w:"f1nxs5xn",z8tnut:"f1g0x7ka",z189sj:["f11gcy0p","f1ng84yb"],Byoj8tv:"f1qch9an",uwmqm3:["f1ng84yb","f11gcy0p"],Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"},large:{sshi5w:"f1w5jphr",z8tnut:"f1g0x7ka",z189sj:["fw5db7e","f1uw59to"],Byoj8tv:"f1qch9an",uwmqm3:["f1uw59to","fw5db7e"],Bahqtrf:"fk6fouc",Be2twd7:"fod5ikn",Bhrd7zp:"figsok6",Bg96gwp:"faaz57k",i8kkvl:"f1rjii52",Belr9w4:"f1r7g2jn"},outline:{De3pzq:"fxugw4r",B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fj3muxo",h3c5rm:["f1akhkt","f1lxtadh"],B9xav0g:"f1c1zstj",zhjwy3:["f1lxtadh","f1akhkt"]},outlineInteractive:{Bgoe8wy:"fvcxoqz",Bwzppfd:["f1ub3y4t","f1m52nbi"],oetu4i:"f1l4zc64",gg5e9n:["f1m52nbi","f1ub3y4t"],Drbcw7:"f8vnjqi",udz0bu:["fz1etlk","f1hc16gm"],Be8ivqh:"f1klwx88",ofdepl:["f1hc16gm","fz1etlk"]},underline:{De3pzq:"f1c21dwh",Bbmb7ep:["f1krrbdw","f1deotkl"],Beyfa6y:["f1deotkl","f1krrbdw"],B7oj6ja:["f10ostut","f1ozlkrg"],Btl43ni:["f1ozlkrg","f10ostut"],Bn0qgzm:"f1f09k3d",oivjwe:"fg706s2",B9xav0g:"f1c1zstj"},underlineInteractive:{oetu4i:"f1l4zc64",Be8ivqh:"f1klwx88",B3778ie:["f1nf3wye","feulmo5"],d9w3h3:["feulmo5","f1nf3wye"],Bl18szs:["f18vqdqu","f53nyzz"],B4j8arr:["f53nyzz","f18vqdqu"]},filled:{B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"]},filledInteractive:{q7v0qe:"ftmjh5b",kmh5ft:["f17blpuu","fsrcdbj"],nagaa4:"f1tpwn32",B1yhkcb:["fsrcdbj","f17blpuu"]},invalid:{tvckwq:"fs4k3qj",gk2u95:["fcee079","fmyw78r"],hhx65j:"f1fgmyf4",Bxowmz0:["fmyw78r","fcee079"]},"filled-darker":{De3pzq:"f16xq7d1"},"filled-lighter":{De3pzq:"fxugw4r"},"filled-darker-shadow":{De3pzq:"f16xq7d1",E5pizo:"fyed02w"},"filled-lighter-shadow":{De3pzq:"fxugw4r",E5pizo:"fyed02w"},disabled:{Bceei9c:"fdrzuqr",De3pzq:"f1c21dwh",g2u3we:"f1jj8ep1",h3c5rm:["f15xbau","fy0fskl"],B9xav0g:"f4ikngz",zhjwy3:["fy0fskl","f15xbau"],Bjwas2f:"fg455y9",Bn1d65q:["f1rvyvqg","f14g86mu"],Bxeuatn:"f1cwzwz",n51gp8:["f14g86mu","f1rvyvqg"]}},{d:[".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}",".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".flvyvdh{-webkit-box-flex-wrap:nowrap;-webkit-flex-wrap:nowrap;-ms-flex-wrap:nowrap;flex-wrap:nowrap;}",".f14mj54c{-webkit-column-gap:var(--spacingHorizontalXXS);column-gap:var(--spacingHorizontalXXS);}",".fiut8dr{row-gap:var(--spacingHorizontalXXS);}",".fk6fouc{font-family:var(--fontFamilyBase);}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f10pi13n{position:relative;}",".f1ewtqcl{box-sizing:border-box;}",".f1gw3sf2::after{box-sizing:border-box;}",'.f13zj6fq::after{content:"";}',".f1mdlcz9::after{position:absolute;}",".f1a7op3::after{left:-1px;}",".f1cjjd47::after{right:-1px;}",".f1gboi2j::after{bottom:-1px;}",".f145g4dw::after{height:max(2px, var(--borderRadiusMedium));}",".f1kp91vd::after{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1ibwz09::after{border-bottom-right-radius:var(--borderRadiusMedium);}",".f1cb6c3::after{border-bottom-width:2px;}",".f1lh990p::after{border-bottom-style:solid;}",".f1jc6hxc::after{border-bottom-color:var(--colorCompoundBrandStroke);}",".f13evtba::after{-webkit-clip-path:inset(calc(100% - 2px) 0 0 0);clip-path:inset(calc(100% - 2px) 0 0 0);}",".f1yk9hq::after{-webkit-transform:scaleX(0);-moz-transform:scaleX(0);-ms-transform:scaleX(0);transform:scaleX(0);}",".fhwpy7i::after{transition-property:transform;}",".f14ee0xe::after{transition-duration:var(--durationUltraFast);}",".f1xhbsuh::after{transition-delay:var(--curveAccelerateMid);}",".f1pha7fy{min-height:24px;}",".f1g0x7ka{padding-top:0;}",".fdw0yi8{padding-right:var(--spacingHorizontalSNudge);}",".fk8j09s{padding-left:var(--spacingHorizontalSNudge);}",".f1qch9an{padding-bottom:0;}",".fy9rknc{font-size:var(--fontSizeBase200);}",".figsok6{font-weight:var(--fontWeightRegular);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".f1nxs5xn{min-height:32px;}",".f11gcy0p{padding-right:var(--spacingHorizontalMNudge);}",".f1ng84yb{padding-left:var(--spacingHorizontalMNudge);}",".fkhj508{font-size:var(--fontSizeBase300);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".f1w5jphr{min-height:40px;}",".fw5db7e{padding-right:var(--spacingHorizontalM);}",".f1uw59to{padding-left:var(--spacingHorizontalM);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".faaz57k{line-height:var(--lineHeightBase400);}",".f1rjii52{-webkit-column-gap:var(--spacingHorizontalSNudge);column-gap:var(--spacingHorizontalSNudge);}",".f1r7g2jn{row-gap:var(--spacingHorizontalSNudge);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fj3muxo{border-top-color:var(--colorNeutralStroke1);}",".f1akhkt{border-right-color:var(--colorNeutralStroke1);}",".f1lxtadh{border-left-color:var(--colorNeutralStroke1);}",".f1c1zstj{border-bottom-color:var(--colorNeutralStrokeAccessible);}",".f1c21dwh{background-color:var(--colorTransparentBackground);}",".f1krrbdw{border-bottom-right-radius:0;}",".f1deotkl{border-bottom-left-radius:0;}",".f10ostut{border-top-right-radius:0;}",".f1ozlkrg{border-top-left-radius:0;}",".f1nf3wye::after{border-bottom-right-radius:0;}",".feulmo5::after{border-bottom-left-radius:0;}",".f18vqdqu::after{border-top-right-radius:0;}",".f53nyzz::after{border-top-left-radius:0;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".fs4k3qj:not(:focus-within),.fs4k3qj:hover:not(:focus-within){border-top-color:var(--colorPaletteRedBorder2);}",".fcee079:not(:focus-within),.fcee079:hover:not(:focus-within){border-right-color:var(--colorPaletteRedBorder2);}",".fmyw78r:not(:focus-within),.fmyw78r:hover:not(:focus-within){border-left-color:var(--colorPaletteRedBorder2);}",".f1fgmyf4:not(:focus-within),.f1fgmyf4:hover:not(:focus-within){border-bottom-color:var(--colorPaletteRedBorder2);}",".f16xq7d1{background-color:var(--colorNeutralBackground3);}",".fyed02w{box-shadow:var(--shadow2);}",".fdrzuqr{cursor:not-allowed;}",".f1jj8ep1{border-top-color:var(--colorNeutralStrokeDisabled);}",".f15xbau{border-right-color:var(--colorNeutralStrokeDisabled);}",".fy0fskl{border-left-color:var(--colorNeutralStrokeDisabled);}",".f4ikngz{border-bottom-color:var(--colorNeutralStrokeDisabled);}"],m:[["@media screen and (prefers-reduced-motion: reduce){.fv8e3ye::after{transition-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.ftb5wc6::after{transition-delay:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1cmft4k:focus-within::after{transition-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1x58t8o:focus-within::after{transition-delay:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media (forced-colors: active){.fg455y9{border-top-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1rvyvqg{border-right-color:GrayText;}.f14g86mu{border-left-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f1cwzwz{border-bottom-color:GrayText;}}",{m:"(forced-colors: active)"}],["@media (forced-colors: active){.f14g86mu{border-left-color:GrayText;}.f1rvyvqg{border-right-color:GrayText;}}",{m:"(forced-colors: active)"}]],w:[".fjw5xc1:focus-within::after{-webkit-transform:scaleX(1);-moz-transform:scaleX(1);-ms-transform:scaleX(1);transform:scaleX(1);}",".f1xdyd5c:focus-within::after{transition-property:transform;}",".fatpbeo:focus-within::after{transition-duration:var(--durationNormal);}",".fb7uyps:focus-within::after{transition-delay:var(--curveDecelerateMid);}",".f1ibeo51:focus-within:active::after{border-bottom-color:var(--colorCompoundBrandStrokePressed);}",".f14a1fxs:focus-within{outline-width:2px;}",".f3e99gv:focus-within{outline-style:solid;}",".fhljsf7:focus-within{outline-color:transparent;}"],h:[".fvcxoqz:hover{border-top-color:var(--colorNeutralStroke1Hover);}",".f1ub3y4t:hover{border-right-color:var(--colorNeutralStroke1Hover);}",".f1m52nbi:hover{border-left-color:var(--colorNeutralStroke1Hover);}",".f1l4zc64:hover{border-bottom-color:var(--colorNeutralStrokeAccessibleHover);}",".ftmjh5b:hover,.ftmjh5b:focus-within{border-top-color:var(--colorTransparentStrokeInteractive);}",".f17blpuu:hover,.f17blpuu:focus-within{border-right-color:var(--colorTransparentStrokeInteractive);}",".fsrcdbj:hover,.fsrcdbj:focus-within{border-left-color:var(--colorTransparentStrokeInteractive);}",".f1tpwn32:hover,.f1tpwn32:focus-within{border-bottom-color:var(--colorTransparentStrokeInteractive);}"],a:[".f8vnjqi:active,.f8vnjqi:focus-within{border-top-color:var(--colorNeutralStroke1Pressed);}",".fz1etlk:active,.fz1etlk:focus-within{border-right-color:var(--colorNeutralStroke1Pressed);}",".f1hc16gm:active,.f1hc16gm:focus-within{border-left-color:var(--colorNeutralStroke1Pressed);}",".f1klwx88:active,.f1klwx88:focus-within{border-bottom-color:var(--colorNeutralStrokeAccessiblePressed);}"]}),rfe=pt({base:{B7ck84d:"f1ewtqcl",Bh6795r:"fqerorx",Bf4jedk:"fy77jfu",icvyot:"f1ern45e",vrafjx:["f1n71otn","f1deefiw"],oivjwe:"f1h8hb77",wvpqe5:["f1deefiw","f1n71otn"],z8tnut:"f1g0x7ka",z189sj:["ffczdla","fgiv446"],Byoj8tv:"f1qch9an",uwmqm3:["fgiv446","ffczdla"],sj55zd:"f19n0e5",De3pzq:"f3rmtva",yvdlaj:"fwyc1cq",B3o7kgh:"f13ta7ih",oeaueh:"f1s6fcnf"},small:{Bahqtrf:"fk6fouc",Be2twd7:"fy9rknc",Bhrd7zp:"figsok6",Bg96gwp:"fwrc4pm"},medium:{Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"},large:{Bahqtrf:"fk6fouc",Be2twd7:"fod5ikn",Bhrd7zp:"figsok6",Bg96gwp:"faaz57k",z8tnut:"f1g0x7ka",z189sj:["fdw0yi8","fk8j09s"],Byoj8tv:"f1qch9an",uwmqm3:["fk8j09s","fdw0yi8"]},disabled:{sj55zd:"f1s2aq7o",De3pzq:"f1c21dwh",Bceei9c:"fdrzuqr",yvdlaj:"fahhnxm"}},{d:[".f1ewtqcl{box-sizing:border-box;}",".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}",".fy77jfu{min-width:0;}",".f1ern45e{border-top-style:none;}",".f1n71otn{border-right-style:none;}",".f1deefiw{border-left-style:none;}",".f1h8hb77{border-bottom-style:none;}",".f1g0x7ka{padding-top:0;}",".ffczdla{padding-right:var(--spacingHorizontalXXS);}",".fgiv446{padding-left:var(--spacingHorizontalXXS);}",".f1qch9an{padding-bottom:0;}",".f19n0e5{color:var(--colorNeutralForeground1);}",".f3rmtva{background-color:transparent;}",".fwyc1cq::-webkit-input-placeholder{color:var(--colorNeutralForeground4);}",".fwyc1cq::-moz-placeholder{color:var(--colorNeutralForeground4);}",".f13ta7ih::-webkit-input-placeholder{opacity:1;}",".f13ta7ih::-moz-placeholder{opacity:1;}",".f1s6fcnf{outline-style:none;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fy9rknc{font-size:var(--fontSizeBase200);}",".figsok6{font-weight:var(--fontWeightRegular);}",".fwrc4pm{line-height:var(--lineHeightBase200);}",".fkhj508{font-size:var(--fontSizeBase300);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".faaz57k{line-height:var(--lineHeightBase400);}",".fdw0yi8{padding-right:var(--spacingHorizontalSNudge);}",".fk8j09s{padding-left:var(--spacingHorizontalSNudge);}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".f1c21dwh{background-color:var(--colorTransparentBackground);}",".fdrzuqr{cursor:not-allowed;}",".fahhnxm::-webkit-input-placeholder{color:var(--colorNeutralForegroundDisabled);}",".fahhnxm::-moz-placeholder{color:var(--colorNeutralForegroundDisabled);}"]}),ofe=pt({base:{B7ck84d:"f1ewtqcl",sj55zd:"f11d4kpn",mc9l5x:"f22iagw"},disabled:{sj55zd:"f1s2aq7o"},small:{kwki1k:"f3u2cy0"},medium:{kwki1k:"f1oqplr0"},large:{kwki1k:"fa420co"}},{d:[".f1ewtqcl{box-sizing:border-box;}",".f11d4kpn{color:var(--colorNeutralForeground3);}",".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".f3u2cy0>svg{font-size:16px;}",".f1oqplr0>svg{font-size:20px;}",".fa420co>svg{font-size:24px;}"]}),ife=e=>{const{size:t,appearance:n}=e,r=e.input.disabled,o=`${e.input["aria-invalid"]}`=="true",i=n.startsWith("filled"),a=nfe(),s=rfe(),l=ofe();e.root.className=et($m.root,a.base,a[t],a[n],!r&&a.interactive,!r&&n==="outline"&&a.outlineInteractive,!r&&n==="underline"&&a.underlineInteractive,!r&&i&&a.filledInteractive,i&&a.filled,!r&&o&&a.invalid,r&&a.disabled,e.root.className),e.input.className=et($m.input,s.base,s[t],r&&s.disabled,e.input.className);const u=[l.base,r&&l.disabled,l[t]];return e.contentBefore&&(e.contentBefore.className=et($m.contentBefore,...u,e.contentBefore.className)),e.contentAfter&&(e.contentAfter.className=et($m.contentAfter,...u,e.contentAfter.className)),e},Ad=T.forwardRef((e,t)=>{const n=efe(e,t);return ife(n),tfe(n)});Ad.displayName="Input";const afe=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root})},sfe=(e,t)=>{const{bordered:n=!1,fit:r="default",block:o=!1,shape:i="square",shadow:a=!1}=e;return{bordered:n,fit:r,block:o,shape:i,shadow:a,components:{root:"img"},root:vr("img",{ref:t,...e})}},lfe={root:"fui-Image"},ufe=pt({base:{g2u3we:"fj3muxo",h3c5rm:["f1akhkt","f1lxtadh"],B9xav0g:"f1aperda",zhjwy3:["f1lxtadh","f1akhkt"],Bbmb7ep:["fzi6hpg","fyowgf4"],Beyfa6y:["fyowgf4","fzi6hpg"],B7oj6ja:["f3fg2lr","f13av6d4"],Btl43ni:["f13av6d4","f3fg2lr"],B7ck84d:"f1ewtqcl",mc9l5x:"f14t3ns0"},bordered:{icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],B4j52fo:"f192inf7",Bekrc4i:["f5tn483","f1ojsxk5"],Bn0qgzm:"f1vxd6vx",ibv6hh:["f1ojsxk5","f5tn483"]},circular:{Bbmb7ep:["f8fbkgy","f1nfllo7"],Beyfa6y:["f1nfllo7","f8fbkgy"],B7oj6ja:["f1djnp8u","f1s8kh49"],Btl43ni:["f1s8kh49","f1djnp8u"]},rounded:{Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"]},square:{},shadow:{E5pizo:"f1whvlc6"},center:{st4lth:"f1plgu50",Ermj5k:"f14xojzb",Bqenvij:"f1l02sjl",a9b677:"fly5x3f"},contain:{st4lth:"f1kle4es",Ermj5k:"f14xojzb",Bqenvij:"f1l02sjl",a9b677:"fly5x3f"},default:{},cover:{st4lth:"f1ps3kmd",Ermj5k:"f14xojzb",Bqenvij:"f1l02sjl",a9b677:"fly5x3f"},none:{st4lth:"f1plgu50",Ermj5k:["f13uwng7","fjmyj0p"],Bqenvij:"f1l02sjl",a9b677:"fly5x3f"},block:{a9b677:"fly5x3f"}},{d:[".fj3muxo{border-top-color:var(--colorNeutralStroke1);}",".f1akhkt{border-right-color:var(--colorNeutralStroke1);}",".f1lxtadh{border-left-color:var(--colorNeutralStroke1);}",".f1aperda{border-bottom-color:var(--colorNeutralStroke1);}",".fzi6hpg{border-bottom-right-radius:var(--borderRadiusNone);}",".fyowgf4{border-bottom-left-radius:var(--borderRadiusNone);}",".f3fg2lr{border-top-right-radius:var(--borderRadiusNone);}",".f13av6d4{border-top-left-radius:var(--borderRadiusNone);}",".f1ewtqcl{box-sizing:border-box;}",".f14t3ns0{display:inline-block;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".f192inf7{border-top-width:var(--strokeWidthThin);}",".f5tn483{border-right-width:var(--strokeWidthThin);}",".f1ojsxk5{border-left-width:var(--strokeWidthThin);}",".f1vxd6vx{border-bottom-width:var(--strokeWidthThin);}",".f8fbkgy{border-bottom-right-radius:var(--borderRadiusCircular);}",".f1nfllo7{border-bottom-left-radius:var(--borderRadiusCircular);}",".f1djnp8u{border-top-right-radius:var(--borderRadiusCircular);}",".f1s8kh49{border-top-left-radius:var(--borderRadiusCircular);}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f1whvlc6{box-shadow:var(--shadow4);}",".f1plgu50{object-fit:none;}",".f14xojzb{object-position:center;}",".f1l02sjl{height:100%;}",".fly5x3f{width:100%;}",".f1kle4es{object-fit:contain;}",".f1ps3kmd{object-fit:cover;}",".f13uwng7{object-position:left top;}",".fjmyj0p{object-position:right top;}"]}),cfe=e=>{const t=ufe();e.root.className=et(lfe.root,t.base,e.block&&t.block,e.bordered&&t.bordered,e.shadow&&t.shadow,t[e.fit],t[e.shape],e.root.className)},Gv=T.forwardRef((e,t)=>{const n=sfe(e,t);return cfe(n),afe(n)});Gv.displayName="Image";const ffe=e=>{const{disabled:t,disabledFocusable:n}=e,{onClick:r,onKeyDown:o,role:i,tabIndex:a,type:s}=e.root;return e.root.as==="a"?(e.root.href=t?void 0:e.root.href,e.root.tabIndex=a??(t&&!n?void 0:0),(t||n)&&(e.root.role=i||"link")):e.root.type=s||"button",e.root.onClick=l=>{t||n?l.preventDefault():r==null||r(l)},e.root.onKeyDown=l=>{(t||n)&&(l.key===Uh||l.key===id)?(l.preventDefault(),l.stopPropagation()):o==null||o(l)},e.disabled=t||n,e.root["aria-disabled"]=t||n||void 0,e.root.as==="button"&&(e.root.disabled=t&&!n),e},dfe=(e,t)=>{const{appearance:n="default",disabled:r=!1,disabledFocusable:o=!1,inline:i=!1}=e,a=e.as||(e.href?"a":"button"),l={appearance:n,disabled:r,disabledFocusable:o,inline:i,components:{root:"a"},root:vr(a,{ref:t,type:a==="button"?"button":void 0,...e,as:a})};return ffe(l),l},hfe={root:"fui-Link"},pfe=pt({focusIndicator:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",Bttzg6e:"fhgqx19",B3uz8dt:"f1olyrje",B6ihwck:"f1p93eir"},root:{De3pzq:"f3rmtva",B7ck84d:"f1ewtqcl",sj55zd:"fyind8e",Bceei9c:"f1k6fduh",mc9l5x:"f1w7gpdv",Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",B6of3ja:"f1hu3pq6",t21cq0:["f11qmguv","f1tyq0we"],jrapky:"f19f4twv",Frg6f3:["f1tyq0we","f11qmguv"],z8tnut:"f1g0x7ka",z189sj:["fhxju0i","f1cnd47f"],Byoj8tv:"f1qch9an",uwmqm3:["f1cnd47f","fhxju0i"],B68tc82:"fqv5qza",Bmxbyg5:"f1vmzxwi",fsow6f:["f1o700av","fes3tcz"],w71qe1:"f1iuv45f",Bkioxbp:"f1cmlufx",ygn44y:"f9n3di6",famaaq:"f1ids18y",Bde5pd6:"f1tx3yz7",Bi91k9c:"f1deo86v",i089h6:"f1eh06m1",lj723h:"f1iescvh"},button:{icvyot:"f1ern45e",vrafjx:["f1n71otn","f1deefiw"],oivjwe:"f1h8hb77",wvpqe5:["f1deefiw","f1n71otn"]},href:{Be2twd7:"fjoy568"},subtle:{sj55zd:"fkfq4zb",Bde5pd6:"f1tx3yz7",Bi91k9c:"fnwyq0v",i089h6:"f1eh06m1",lj723h:"flvvhsy"},inline:{w71qe1:"f13mvf36"},disabled:{w71qe1:"f1iuv45f",sj55zd:"f1s2aq7o",Bceei9c:"fdrzuqr",Bde5pd6:"fbnuktb",Bi91k9c:"fvgxktp",i089h6:"fljg2da",lj723h:"f19wldhg"}},{f:[".ftqa4ok:focus{outline-style:none;}"],i:[".f2hkw1w:focus-visible{outline-style:none;}"],d:[".fhgqx19[data-fui-focus-visible]{text-decoration-color:var(--colorStrokeFocus2);}",".f1olyrje[data-fui-focus-visible]{text-decoration-line:underline;}",".f1p93eir[data-fui-focus-visible]{text-decoration-style:double;}",".f3rmtva{background-color:transparent;}",".f1ewtqcl{box-sizing:border-box;}",".fyind8e{color:var(--colorBrandForegroundLink);}",".f1k6fduh{cursor:pointer;}",".f1w7gpdv{display:inline;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1hu3pq6{margin-top:0;}",".f11qmguv{margin-right:0;}",".f1tyq0we{margin-left:0;}",".f19f4twv{margin-bottom:0;}",".f1g0x7ka{padding-top:0;}",".fhxju0i{padding-right:0;}",".f1cnd47f{padding-left:0;}",".f1qch9an{padding-bottom:0;}",".fqv5qza{overflow-x:inherit;}",".f1vmzxwi{overflow-y:inherit;}",".f1o700av{text-align:left;}",".fes3tcz{text-align:right;}",".f1iuv45f{text-decoration-line:none;}",".f1cmlufx{text-decoration-thickness:var(--strokeWidthThin);}",".f9n3di6{text-overflow:inherit;}",".f1ids18y{-webkit-user-select:text;-moz-user-select:text;-ms-user-select:text;user-select:text;}",".f1ern45e{border-top-style:none;}",".f1n71otn{border-right-style:none;}",".f1deefiw{border-left-style:none;}",".f1h8hb77{border-bottom-style:none;}",".fjoy568{font-size:inherit;}",".fkfq4zb{color:var(--colorNeutralForeground2);}",".f13mvf36{text-decoration-line:underline;}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}",".fdrzuqr{cursor:not-allowed;}"],h:[".f1tx3yz7:hover{text-decoration-line:underline;}",".f1deo86v:hover{color:var(--colorBrandForegroundLinkHover);}",".fnwyq0v:hover{color:var(--colorNeutralForeground2Hover);}",".fbnuktb:hover{text-decoration-line:none;}",".fvgxktp:hover{color:var(--colorNeutralForegroundDisabled);}"],a:[".f1eh06m1:active{text-decoration-line:underline;}",".f1iescvh:active{color:var(--colorBrandForegroundLinkPressed);}",".flvvhsy:active{color:var(--colorNeutralForeground2Pressed);}",".fljg2da:active{text-decoration-line:none;}",".f19wldhg:active{color:var(--colorNeutralForegroundDisabled);}"]}),mfe=e=>{const t=pfe(),{appearance:n,disabled:r,inline:o,root:i}=e;return e.root.className=et(hfe.root,t.root,t.focusIndicator,i.as==="a"&&i.href&&t.href,i.as==="button"&&t.button,n==="subtle"&&t.subtle,o&&t.inline,r&&t.disabled,e.root.className),e},gfe=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root})},ED=T.forwardRef((e,t)=>{const n=dfe(e,t);return mfe(n),gfe(n)});ED.displayName="Link";const KT=ry(void 0),vfe={open:!1,setOpen:()=>!1,checkedValues:{},onCheckedValueChange:()=>null,isSubmenu:!1,triggerRef:{current:null},menuPopoverRef:{current:null},triggerId:"",openOnContext:!1,openOnHover:!1,hasIcons:!1,hasCheckmarks:!1,inline:!1,persistOnItemClick:!1},bfe=KT.Provider,lr=e=>oy(KT,(t=vfe)=>e(t)),_D=T.createContext(void 0),yfe=!1,Efe=_D.Provider,_fe=()=>{var e;return(e=T.useContext(_D))!==null&&e!==void 0?e:yfe},VT=ry(void 0),Tfe={checkedValues:{},setFocusByFirstCharacter:()=>null,toggleCheckbox:()=>null,selectRadio:()=>null,hasIcons:!1,hasCheckmarks:!1},wfe=VT.Provider,D_=e=>oy(VT,(t=Tfe)=>e(t)),R0="fuimenuenter",kfe=e=>{const{refs:t,callback:n,element:r,disabled:o}=e,i=Et(a=>{var s;const l=t[0],u=a.target;!B0((s=l.current)!==null&&s!==void 0?s:null,u)&&!o&&n(a)});T.useEffect(()=>{if(r!=null)return o||r.addEventListener(R0,i),()=>{r.removeEventListener(R0,i)}},[i,r,o])},Sfe=(e,t)=>{e.dispatchEvent(new CustomEvent(R0,{bubbles:!0,detail:{nativeEvent:t}}))};function YT(){const e=lr(n=>n.isSubmenu),t=jT(VT);return e||t}const xfe=e=>{const t=YT(),{hoverDelay:n=500,inline:r=!1,hasCheckmarks:o=!1,hasIcons:i=!1,closeOnScroll:a=!1,openOnContext:s=!1,persistOnItemClick:l=!1,openOnHover:u=t,defaultCheckedValues:d}=e,h=lo("menu"),[p,m]=gD(),v={position:t?"after":"below",align:t?"top":"start",target:e.openOnContext?p:void 0,...$T(e.positioning)},_=T.Children.toArray(e.children);let b,E;_.length===2?(b=_[0],E=_[1]):_.length===1&&(E=_[0]);const{targetRef:w,containerRef:k}=WT(v),[y,F]=Afe({hoverDelay:n,isSubmenu:t,setContextTarget:m,closeOnScroll:a,menuPopoverRef:k,triggerRef:w,open:e.open,defaultOpen:e.defaultOpen,onOpenChange:e.onOpenChange,openOnContext:s}),[C,A]=Cfe({checkedValues:e.checkedValues,defaultCheckedValues:d,onCheckedValueChange:e.onCheckedValueChange});return{inline:r,hoverDelay:n,triggerId:h,isSubmenu:t,openOnHover:u,contextTarget:p,setContextTarget:m,hasCheckmarks:o,hasIcons:i,closeOnScroll:a,menuTrigger:b,menuPopover:E,triggerRef:w,menuPopoverRef:k,components:{},openOnContext:s,open:y,setOpen:F,checkedValues:C,onCheckedValueChange:A,persistOnItemClick:l}},Cfe=e=>{const[t,n]=Wc({state:e.checkedValues,defaultState:e.defaultCheckedValues,initialState:{}}),r=Et((o,{name:i,checkedItems:a})=>{var s;(s=e.onCheckedValueChange)===null||s===void 0||s.call(e,o,{name:i,checkedItems:a}),n(l=>({...l,[i]:a}))});return[t,r]},Afe=e=>{const{targetDocument:t}=Oo(),n=lr(v=>v.setOpen),r=Et((v,_)=>{var b;return(b=e.onOpenChange)===null||b===void 0?void 0:b.call(e,v,_)}),o=T.useRef(!1),i=T.useRef(0),a=T.useRef(!1),[s,l]=Wc({state:e.open,defaultState:e.defaultOpen,initialState:!1}),u=Et((v,_)=>{const b=v instanceof CustomEvent&&v.type===R0?v.detail.nativeEvent:v;r==null||r(b,{..._}),_.open&&v.type==="contextmenu"&&e.setContextTarget(v),_.open||(e.setContextTarget(void 0),o.current=!0),_.bubble&&n(v,{..._}),l(_.open)}),d=Et((v,_)=>{var b;clearTimeout(i.current),!(v instanceof Event)&&v.persist&&v.persist(),v.type==="mouseleave"||v.type==="mouseenter"||v.type==="mousemove"||v.type===R0?(!((b=e.triggerRef.current)===null||b===void 0)&&b.contains(v.target)&&(a.current=v.type==="mouseenter"||v.type==="mousemove"),i.current=setTimeout(()=>u(v,_),e.hoverDelay)):u(v,_)});iO({contains:B0,disabled:!s,element:t,refs:[e.menuPopoverRef,!e.openOnContext&&e.triggerRef].filter(Boolean),callback:v=>d(v,{open:!1,type:"clickOutside",event:v})});const h=e.openOnContext||e.closeOnScroll;aO({contains:B0,element:t,callback:v=>d(v,{open:!1,type:"scrollOutside",event:v}),refs:[e.menuPopoverRef,!e.openOnContext&&e.triggerRef].filter(Boolean),disabled:!s||!h}),kfe({element:t,callback:v=>{a.current||d(v,{open:!1,type:"menuMouseEnter",event:v})},disabled:!s,refs:[e.menuPopoverRef]}),T.useEffect(()=>()=>{clearTimeout(i.current)},[]);const{findFirstFocusable:p}=op(),m=T.useCallback(()=>{const v=p(e.menuPopoverRef.current);v==null||v.focus()},[p,e.menuPopoverRef]);return T.useEffect(()=>{var v;s?m():o.current&&((v=e.triggerRef.current)===null||v===void 0||v.focus()),o.current=!1},[e.triggerRef,e.isSubmenu,s,m]),[s,d]};function Nfe(e){const{checkedValues:t,hasCheckmarks:n,hasIcons:r,inline:o,isSubmenu:i,menuPopoverRef:a,onCheckedValueChange:s,open:l,openOnContext:u,openOnHover:d,persistOnItemClick:h,setOpen:p,triggerId:m,triggerRef:v}=e;return{menu:{checkedValues:t,hasCheckmarks:n,hasIcons:r,inline:o,isSubmenu:i,menuPopoverRef:a,onCheckedValueChange:s,open:l,openOnContext:u,openOnHover:d,persistOnItemClick:h,setOpen:p,triggerId:m,triggerRef:v}}}const Ffe=(e,t)=>T.createElement(bfe,{value:t.menu},e.menuTrigger,e.open&&e.menuPopover),QT=e=>{const t=xfe(e),n=Nfe(t);return Ffe(t,n)};QT.displayName="Menu";const Ife=(e,t)=>{const n=D_(o=>o.setFocusByFirstCharacter),{onKeyDown:r}=e.root;return e.root.onKeyDown=o=>{var i;r==null||r(o),!(((i=o.key)===null||i===void 0?void 0:i.length)>1)&&t.current&&(n==null||n(o,t.current))},e},Bfe=ZO($ae,Gae),Rfe=ZO(zae,Uae),Ofe=(e,t)=>{const n=_fe(),r=lr(_=>_.persistOnItemClick),{as:o="div",disabled:i=!1,hasSubmenu:a=n,persistOnClick:s=r}=e,l=D_(_=>_.hasIcons),u=D_(_=>_.hasCheckmarks),d=lr(_=>_.setOpen),{dir:h}=Oo(),p=T.useRef(null),m=T.useRef(!1),v={hasSubmenu:a,disabled:i,persistOnClick:s,components:{root:"div",icon:"span",checkmark:"span",submenuIndicator:"span",content:"span",secondaryContent:"span"},root:vr(o,Gd(o,{role:"menuitem",...e,disabled:!1,disabledFocusable:i,ref:cs(t,p),onKeyDown:Et(_=>{var b;(b=e.onKeyDown)===null||b===void 0||b.call(e,_),!_.isDefaultPrevented()&&(_.key===id||_.key===Uh)&&(m.current=!0)}),onMouseEnter:Et(_=>{var b,E;(b=p.current)===null||b===void 0||b.focus(),(E=e.onMouseEnter)===null||E===void 0||E.call(e,_)}),onClick:Et(_=>{var b;!a&&!s&&(d(_,{open:!1,keyboard:m.current,bubble:!0,type:"menuItemClick",event:_}),m.current=!1),(b=e.onClick)===null||b===void 0||b.call(e,_)})})),icon:$t(e.icon,{required:l}),checkmark:$t(e.checkmark,{required:u}),submenuIndicator:$t(e.submenuIndicator,{required:a,defaultProps:{children:h==="ltr"?T.createElement(Bfe,null):T.createElement(Rfe,null)}}),content:$t(e.content,{required:!!e.children,defaultProps:{children:e.children}}),secondaryContent:$t(e.secondaryContent)};return Ife(v,p),v},Dfe=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root},t.checkmark&&T.createElement(t.checkmark,{...n.checkmark}),t.icon&&T.createElement(t.icon,{...n.icon}),t.content&&T.createElement(t.content,{...n.content}),t.secondaryContent&&T.createElement(t.secondaryContent,{...n.secondaryContent}),t.submenuIndicator&&T.createElement(t.submenuIndicator,{...n.submenuIndicator}))},Pfe=pt({root:{a9b677:"fjw5fx7",Bqenvij:"fd461yt",Bcdw1i0:"fd7fpy0"},rootChecked:{Bcdw1i0:"f1022m68"}},{d:[".fjw5fx7{width:16px;}",".fd461yt{height:16px;}",".fd7fpy0{visibility:hidden;}",".f1022m68{visibility:visible;}"]}),Mfe=e=>{const t=Pfe();e.checkmark&&(e.checkmark.className=et(t.root,e.checked&&t.rootChecked,e.checkmark.className))},Sf={root:"fui-MenuItem",icon:"fui-MenuItem__icon",checkmark:"fui-MenuItem__checkmark",submenuIndicator:"fui-MenuItem__submenuIndicator",content:"fui-MenuItem__content",secondaryContent:"fui-MenuItem__secondaryContent"},Lfe=pt({focusIndicator:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",B8q5s1w:"f8hki3x",Bci5o5g:["f1d2448m","ffh67wi"],n8qw10:"f1bjia2o",Bdrgwmp:["ffh67wi","f1d2448m"],Bm4h7ae:"f15bsgw9",B7ys5i9:"f14e48fq",Busjfv9:"f18yb2kv",Bhk32uz:"fd6o370",Bf4ptjt:"fh1cnn4",kclons:["fy7oxxb","f184ne2d"],Bhdgwq3:"fpukqih",Blkhhs4:["f184ne2d","fy7oxxb"],Bqtpl0w:"frrh606",clg4pj:["f1v5zibi","fo2hd23"],hgwjuy:"ful5kiu",Bonggc9:["fo2hd23","f1v5zibi"],B1tsrr9:["f1jqcqds","ftffrms"],Dah5zi:["ftffrms","f1jqcqds"],Bkh64rk:["f2e7qr6","fsr1zz6"],qqdqy8:["fsr1zz6","f2e7qr6"],B6dhp37:"f1dvezut",i03rao:["fd0oaoj","f1cwg4i8"],Boxcth7:"fjvm52t",Bsom6fd:["f1cwg4i8","fd0oaoj"],J0r882:"fdiulkx",Bjwuhne:"f1yalx80",Ghsupd:["fq22d5a","f1jw7pan"],Bule8hv:["f1jw7pan","fq22d5a"]},root:{Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],qhf8xq:"f10pi13n",sj55zd:"fkfq4zb",De3pzq:"fxugw4r",z189sj:["f81rol6","frdkuqy"],uwmqm3:["frdkuqy","f81rol6"],Bqenvij:"f1d2rq10",mc9l5x:"f22iagw",Bt984gj:"f122n59",Be2twd7:"fkhj508",Bceei9c:"f1k6fduh",i8kkvl:"f1q8lukm",Belr9w4:"f1ma2n7n",Jwef8y:"f1knas48",Bi91k9c:"fnwyq0v",Bk3fhr4:"ft1hn21",Bmfj8id:"fuxngvv",Bg7n49j:"fp258yr",famaaq:"f1xqy1su"},content:{uwmqm3:["f161knb0","f12huiiw"],z189sj:["f12huiiw","f161knb0"],De3pzq:"f3rmtva",Bh6795r:"fqerorx"},secondaryContent:{uwmqm3:["f161knb0","f12huiiw"],z189sj:["f12huiiw","f161knb0"],sj55zd:"f11d4kpn",Bi91k9c:"f1jp5ecu",t0hwav:"fc1cou1"},icon:{a9b677:"f64fuq3",Bqenvij:"fjamq6b",Be2twd7:"fe5j1ua",Bg96gwp:"fez10in",Bt984gj:"f122n59",mc9l5x:"ftuwxu6",Brf1p80:"f4d9j23"},submenuIndicator:{a9b677:"f64fuq3",Bqenvij:"fjamq6b",Be2twd7:"fe5j1ua",Bg96gwp:"fez10in",Bt984gj:"f122n59",mc9l5x:"ftuwxu6",Brf1p80:"f4d9j23"},disabled:{sj55zd:"f1s2aq7o",Bi91k9c:"fvgxktp",t0hwav:"ft33916"}},{f:[".ftqa4ok:focus{outline-style:none;}",".fc1cou1:focus{color:var(--colorNeutralForeground3Hover);}",".ft33916:focus{color:var(--colorNeutralForegroundDisabled);}"],i:[".f2hkw1w:focus-visible{outline-style:none;}"],d:[".f8hki3x[data-fui-focus-visible]{border-top-color:transparent;}",".f1d2448m[data-fui-focus-visible]{border-right-color:transparent;}",".ffh67wi[data-fui-focus-visible]{border-left-color:transparent;}",".f1bjia2o[data-fui-focus-visible]{border-bottom-color:transparent;}",'.f15bsgw9[data-fui-focus-visible]::after{content:"";}',".f14e48fq[data-fui-focus-visible]::after{position:absolute;}",".f18yb2kv[data-fui-focus-visible]::after{pointer-events:none;}",".fd6o370[data-fui-focus-visible]::after{z-index:1;}",".fh1cnn4[data-fui-focus-visible]::after{border-top-style:solid;}",".fy7oxxb[data-fui-focus-visible]::after{border-right-style:solid;}",".f184ne2d[data-fui-focus-visible]::after{border-left-style:solid;}",".fpukqih[data-fui-focus-visible]::after{border-bottom-style:solid;}",".frrh606[data-fui-focus-visible]::after{border-top-width:2px;}",".f1v5zibi[data-fui-focus-visible]::after{border-right-width:2px;}",".fo2hd23[data-fui-focus-visible]::after{border-left-width:2px;}",".ful5kiu[data-fui-focus-visible]::after{border-bottom-width:2px;}",".f1jqcqds[data-fui-focus-visible]::after{border-bottom-right-radius:var(--borderRadiusMedium);}",".ftffrms[data-fui-focus-visible]::after{border-bottom-left-radius:var(--borderRadiusMedium);}",".f2e7qr6[data-fui-focus-visible]::after{border-top-right-radius:var(--borderRadiusMedium);}",".fsr1zz6[data-fui-focus-visible]::after{border-top-left-radius:var(--borderRadiusMedium);}",".f1dvezut[data-fui-focus-visible]::after{border-top-color:var(--colorStrokeFocus2);}",".fd0oaoj[data-fui-focus-visible]::after{border-right-color:var(--colorStrokeFocus2);}",".f1cwg4i8[data-fui-focus-visible]::after{border-left-color:var(--colorStrokeFocus2);}",".fjvm52t[data-fui-focus-visible]::after{border-bottom-color:var(--colorStrokeFocus2);}",".fdiulkx[data-fui-focus-visible]::after{top:-2px;}",".f1yalx80[data-fui-focus-visible]::after{bottom:-2px;}",".fq22d5a[data-fui-focus-visible]::after{left:-2px;}",".f1jw7pan[data-fui-focus-visible]::after{right:-2px;}",".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".f10pi13n{position:relative;}",".fkfq4zb{color:var(--colorNeutralForeground2);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f81rol6{padding-right:10px;}",".frdkuqy{padding-left:10px;}",".f1d2rq10{height:32px;}",".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".fkhj508{font-size:var(--fontSizeBase300);}",".f1k6fduh{cursor:pointer;}",".f1q8lukm{-webkit-column-gap:4px;column-gap:4px;}",".f1ma2n7n{row-gap:4px;}",".f1xqy1su{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;}",".f161knb0{padding-left:2px;}",".f12huiiw{padding-right:2px;}",".f3rmtva{background-color:transparent;}",".fqerorx{-webkit-box-flex:1;-webkit-flex-grow:1;-ms-flex-positive:1;flex-grow:1;}",".f11d4kpn{color:var(--colorNeutralForeground3);}",".f64fuq3{width:20px;}",".fjamq6b{height:20px;}",".fe5j1ua{font-size:20px;}",".fez10in{line-height:0;}",".ftuwxu6{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;}",".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}",".f1s2aq7o{color:var(--colorNeutralForegroundDisabled);}"],h:[".f1knas48:hover{background-color:var(--colorNeutralBackground1Hover);}",".fnwyq0v:hover{color:var(--colorNeutralForeground2Hover);}",".ft1hn21:hover .fui-Icon-filled{display:inline;}",".fuxngvv:hover .fui-Icon-regular{display:none;}",".fp258yr:hover .fui-MenuItem__icon{color:var(--colorNeutralForeground2BrandSelected);}",".f1jp5ecu:hover{color:var(--colorNeutralForeground3Hover);}",".fvgxktp:hover{color:var(--colorNeutralForegroundDisabled);}"]}),jfe=e=>{const t=Lfe();e.root.className=et(Sf.root,t.root,t.focusIndicator,e.disabled&&t.disabled,e.root.className),e.content&&(e.content.className=et(Sf.content,t.content,e.content.className)),e.checkmark&&(e.checkmark.className=et(Sf.checkmark,e.checkmark.className)),e.secondaryContent&&(e.secondaryContent.className=et(Sf.secondaryContent,!e.disabled&&t.secondaryContent,e.secondaryContent.className)),e.icon&&(e.icon.className=et(Sf.icon,t.icon,e.icon.className)),e.submenuIndicator&&(e.submenuIndicator.className=et(Sf.submenuIndicator,t.submenuIndicator,e.submenuIndicator.className)),Mfe(e)},$h=T.forwardRef((e,t)=>{const n=Ofe(e,t);return jfe(n),Dfe(n)});$h.displayName="MenuItem";const zfe=(e,t)=>{var n,r;const o=lie({circular:!0,ignoreDefaultKeydown:{Tab:!0}}),{findAllFocusable:i}=op(),a=Hfe(),s=jT(KT);Ufe(e,a,s)&&console.warn("You are using both MenuList and Menu props, we recommend you to use Menu props when available");const l=T.useRef(null),u=T.useCallback((_,b)=>{const E=["menuitem","menuitemcheckbox","menuitemradio"];if(!l.current)return;const w=i(l.current,P=>P.hasAttribute("role")&&E.indexOf(P.getAttribute("role"))!==-1);let k=w.indexOf(b)+1;k===w.length&&(k=0);const y=w.map(P=>{var I;return(I=P.textContent)===null||I===void 0?void 0:I.charAt(0).toLowerCase()}),F=_.key.toLowerCase(),C=(P,I)=>{for(let j=P;j<y.length;j++)if(F===y[j])return j;return-1};let A=C(k);A===-1&&(A=C(0)),A>-1&&w[A].focus()},[i]),[d,h]=Wc({state:(n=e.checkedValues)!==null&&n!==void 0?n:s?a.checkedValues:void 0,defaultState:e.defaultCheckedValues,initialState:{}}),p=(r=e.onCheckedValueChange)!==null&&r!==void 0?r:s?a.onCheckedValueChange:void 0,m=Et((_,b,E,w)=>{const y=[...(d==null?void 0:d[b])||[]];w?y.splice(y.indexOf(E),1):y.push(E),p==null||p(_,{name:b,checkedItems:y}),h(F=>({...F,[b]:y}))}),v=Et((_,b,E)=>{const w=[E];h(k=>({...k,[b]:w})),p==null||p(_,{name:b,checkedItems:w})});return{components:{root:"div"},root:vr("div",{ref:cs(t,l),role:"menu","aria-labelledby":a.triggerId,...o,...e}),hasIcons:a.hasIcons||!1,hasCheckmarks:a.hasCheckmarks||!1,checkedValues:d,setFocusByFirstCharacter:u,selectRadio:v,toggleCheckbox:m}},Hfe=()=>{const e=lr(i=>i.checkedValues),t=lr(i=>i.onCheckedValueChange),n=lr(i=>i.triggerId),r=lr(i=>i.hasIcons),o=lr(i=>i.hasCheckmarks);return{checkedValues:e,onCheckedValueChange:t,triggerId:n,hasIcons:r,hasCheckmarks:o}},Ufe=(e,t,n)=>{let r=!1;for(const o in t)e[o]&&(r=!0);return n&&r},qfe=(e,t)=>{const{slots:n,slotProps:r}=Jn(e);return T.createElement(wfe,{value:t.menuList},T.createElement(n.root,{...r.root}))};function $fe(e){const{checkedValues:t,hasCheckmarks:n,hasIcons:r,selectRadio:o,setFocusByFirstCharacter:i,toggleCheckbox:a}=e;return{menuList:{checkedValues:t,hasCheckmarks:n,hasIcons:r,selectRadio:o,setFocusByFirstCharacter:i,toggleCheckbox:a}}}const Wfe={root:"fui-MenuList"},Gfe=pt({root:{mc9l5x:"f22iagw",Beiy3e4:"f1vx9l62",i8kkvl:"f16mnhsx",Belr9w4:"fbi42co"}},{d:[".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f1vx9l62{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}",".f16mnhsx{-webkit-column-gap:2px;column-gap:2px;}",".fbi42co{row-gap:2px;}"]}),Kfe=e=>{const t=Gfe();return e.root.className=et(Wfe.root,t.root,e.root.className),e},XT=T.forwardRef((e,t)=>{const n=zfe(e,t),r=$fe(n);return Kfe(n),qfe(n,r)});XT.displayName="MenuList";const Vfe=(e,t)=>{var n;const r=lr(E=>E.menuPopoverRef),o=lr(E=>E.setOpen),i=lr(E=>E.open),a=lr(E=>E.openOnHover),s=YT(),l=T.useRef(!0),u=T.useRef(0),{dir:d}=Oo(),h=d==="ltr"?$O:WO,p=T.useCallback(E=>{E&&E.addEventListener("mouseover",w=>{l.current&&(l.current=!1,Sfe(r.current,w),u.current=setTimeout(()=>l.current=!0,250))})},[r,u]);T.useEffect(()=>{},[]);const m=(n=lr(E=>E.inline))!==null&&n!==void 0?n:!1,v=vr("div",{role:"presentation",...e,ref:cs(t,r,p)}),{onMouseEnter:_,onKeyDown:b}=v;return v.onMouseEnter=Et(E=>{a&&o(E,{open:!0,keyboard:!1,type:"menuPopoverMouseEnter",event:E}),_==null||_(E)}),v.onKeyDown=Et(E=>{var w;const k=E.key;(k===ap||s&&k===h)&&i&&!((w=r.current)===null||w===void 0)&&w.contains(E.target)&&(o(E,{open:!1,keyboard:!0,type:"menuPopoverKeyDown",event:E}),E.stopPropagation()),k===gae&&o(E,{open:!1,keyboard:!0,type:"menuPopoverKeyDown",event:E}),b==null||b(E)}),{inline:m,components:{root:"div"},root:v}},Yfe={root:"fui-MenuPopover"},Qfe=pt({root:{Bbmb7ep:["f1aa9q02","f16jpd5f"],Beyfa6y:["f16jpd5f","f1aa9q02"],B7oj6ja:["f1jar5jt","fyu767a"],Btl43ni:["fyu767a","f1jar5jt"],De3pzq:"fxugw4r",sj55zd:"f19n0e5",Bf4jedk:"fkqu4gx",B2u0y6b:"f1kaai3v",a9b677:"f1ahpp82",E5pizo:"f1hg901r",z8tnut:"f10ra9hq",z189sj:["f8wuabp","fycuoez"],Byoj8tv:"f1y2xyjm",uwmqm3:["fycuoez","f8wuabp"],B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"}},{d:[".f1aa9q02{border-bottom-right-radius:var(--borderRadiusMedium);}",".f16jpd5f{border-bottom-left-radius:var(--borderRadiusMedium);}",".f1jar5jt{border-top-right-radius:var(--borderRadiusMedium);}",".fyu767a{border-top-left-radius:var(--borderRadiusMedium);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f19n0e5{color:var(--colorNeutralForeground1);}",".fkqu4gx{min-width:128px;}",".f1kaai3v{max-width:300px;}",".f1ahpp82{width:-webkit-max-content;width:-moz-max-content;width:max-content;}",".f1hg901r{box-shadow:var(--shadow16);}",".f10ra9hq{padding-top:4px;}",".f8wuabp{padding-right:4px;}",".fycuoez{padding-left:4px;}",".f1y2xyjm{padding-bottom:4px;}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}"]}),Xfe=e=>{const t=Qfe();return e.root.className=et(Yfe.root,t.root,e.root.className),e},Zfe=e=>{const{slots:t,slotProps:n}=Jn(e);return e.inline?T.createElement(t.root,{...n.root}):T.createElement(sp,null,T.createElement(t.root,{...n.root}))},ZT=T.forwardRef((e,t)=>{const n=Vfe(e,t);return Xfe(n),Zfe(n)});ZT.displayName="MenuPopover";const Jfe=e=>{const{children:t,disableButtonEnhancement:n=!1}=e,r=lr(H=>H.triggerRef),o=lr(H=>H.menuPopoverRef),i=lr(H=>H.setOpen),a=lr(H=>H.open),s=lr(H=>H.triggerId),l=lr(H=>H.openOnHover),u=lr(H=>H.openOnContext),d=YT(),{findFirstFocusable:h}=op(),p=T.useCallback(()=>{const H=h(o.current);H==null||H.focus()},[h,o]),m=T.useRef(!1),v=T.useRef(!1),{dir:_}=Oo(),b=_==="ltr"?WO:$O,E=tp(t),w=H=>{xf(H)||u&&(H.preventDefault(),i(H,{open:!0,keyboard:!1,type:"menuTriggerContextMenu",event:H}))},k=H=>{xf(H)||u||(i(H,{open:!a,keyboard:m.current,type:"menuTriggerClick",event:H}),m.current=!1)},y=H=>{if(xf(H))return;const K=H.key;!u&&(d&&K===b||!d&&K===vae)&&i(H,{open:!0,keyboard:!0,type:"menuTriggerKeyDown",event:H}),K===ap&&!d&&i(H,{open:!1,keyboard:!0,type:"menuTriggerKeyDown",event:H}),a&&K===b&&d&&p()},F=H=>{xf(H)||l&&v.current&&i(H,{open:!0,keyboard:!1,type:"menuTriggerMouseEnter",event:H})},C=H=>{xf(H)||l&&!v.current&&(i(H,{open:!0,keyboard:!1,type:"menuTriggerMouseMove",event:H}),v.current=!0)},A=H=>{xf(H)||l&&i(H,{open:!1,keyboard:!1,type:"menuTriggerMouseLeave",event:H})},P={id:s,...E==null?void 0:E.props,ref:cs(r,E==null?void 0:E.ref),onMouseEnter:Et(Vn(E==null?void 0:E.props.onMouseEnter,F)),onMouseLeave:Et(Vn(E==null?void 0:E.props.onMouseLeave,A)),onContextMenu:Et(Vn(E==null?void 0:E.props.onContextMenu,w)),onMouseMove:Et(Vn(E==null?void 0:E.props.onMouseMove,C))},I={"aria-haspopup":"menu","aria-expanded":!a&&!d?void 0:a,...P,onClick:Et(Vn(E==null?void 0:E.props.onClick,k)),onKeyDown:Et(Vn(E==null?void 0:E.props.onKeyDown,y))},j=Gd((E==null?void 0:E.type)==="button"||(E==null?void 0:E.type)==="a"?E.type:"div",I);return{isSubmenu:d,children:Vb(t,u?P:n?I:j)}},xf=e=>{const t=n=>n.hasAttribute("disabled")||n.hasAttribute("aria-disabled")&&n.getAttribute("aria-disabled")==="true";return e.target instanceof HTMLElement&&t(e.target)?!0:e.currentTarget instanceof HTMLElement&&t(e.currentTarget)},ede=e=>T.createElement(Efe,{value:e.isSubmenu},e.children),sy=e=>{const t=Jfe(e);return ede(t)};sy.displayName="MenuTrigger";sy.isFluentTriggerComponent=!0;const tde=()=>T.createElement("svg",{className:"fui-Spinner__Progressbar"},T.createElement("circle",{className:"fui-Spinner__Track"}),T.createElement("circle",{className:"fui-Spinner__Tail"})),nde=(e,t)=>{const{appearance:n="primary",labelPosition:r="after",size:o="medium"}=e,i=lo("spinner"),{role:a="progressbar",tabIndex:s,...l}=e,u=vr("div",{ref:t,role:a,...l},["size"]),d=$t(e.label,{defaultProps:{id:i},required:!1}),h=$t(e.spinner,{required:!0,defaultProps:{children:T.createElement(tde,null),tabIndex:s}});return d&&u&&!u["aria-labelledby"]&&(u["aria-labelledby"]=d.id),{appearance:n,labelPosition:r,size:o,components:{root:"div",spinner:"span",label:Zo},root:u,spinner:h,label:d}},rde=e=>{const{slots:t,slotProps:n}=Jn(e),{labelPosition:r}=e;return T.createElement(t.root,{...n.root},t.label&&(r==="above"||r==="before")&&T.createElement(t.label,{...n.label}),t.spinner&&T.createElement(t.spinner,{...n.spinner}),t.label&&(r==="below"||r==="after")&&T.createElement(t.label,{...n.label}))},c9={root:"fui-Spinner",spinner:"fui-Spinner__spinner",label:"fui-Spinner__label"},ode=pt({root:{mc9l5x:"f22iagw",Bt984gj:"f122n59",Brf1p80:"f4d9j23",Bg96gwp:"fez10in",i8kkvl:"f4px1ci",Belr9w4:"fn67r4l"},horizontal:{Beiy3e4:"f1063pyq"},vertical:{Beiy3e4:"f1vx9l62"}},{d:[".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f122n59{-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}",".f4d9j23{-webkit-box-pack:center;-ms-flex-pack:center;-webkit-justify-content:center;justify-content:center;}",".fez10in{line-height:0;}",".f4px1ci{-webkit-column-gap:8px;column-gap:8px;}",".fn67r4l{row-gap:8px;}",".f1063pyq{-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;}",".f1vx9l62{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),ide=pt({spinnerSVG:{B3aqqti:"f1or16p5",Brovlpu:"f1grzc83",Bxa1mx5:"f19shzzi",Bwaue66:["f5tbecn","f15qb8s7"],fyp1ls:"fn4mtlg",ag6ruv:"f1y80fxs",osj692:"f1r2crtq",aq5vjd:"f1wsi8sr",tlu9e1:"f1bkm2qd",J3u96z:"f1urqz7h",d32isg:"f1da2vov",Bsvqbuc:"f11rfva0",b3s3i5:"f1exc66"},tiny:{Bah9ito:"f1j4wmu2",ut6tcf:"f1vppzuq",B7p06xz:"fv1u54w",B807ibg:"fngtx1d"},"extra-small":{Bah9ito:"fmpqlna",ut6tcf:"f15z5jzu",B7p06xz:"fv1u54w",B807ibg:"fadawes"},small:{Bah9ito:"fo52gbo",ut6tcf:"f1b41i3v",B7p06xz:"fv1u54w",B807ibg:"f1xqyyrl"},medium:{Bah9ito:"f1aiqagr",ut6tcf:"f1wtx80b",B7p06xz:"f1flujpd",B807ibg:"f1u06hy7"},large:{Bah9ito:"f1trdq7b",ut6tcf:"f9e0mc5",B7p06xz:"f1flujpd",B807ibg:"f13pmvhl"},"extra-large":{Bah9ito:"f89rf2a",ut6tcf:"f1w2xg3q",B7p06xz:"f1flujpd",B807ibg:"fmn74v6"},huge:{Bah9ito:"f1rx7k5y",ut6tcf:"f1vtyt49",B7p06xz:"f1owbg48",B807ibg:"f1fr1izd"}},{f:[".f1or16p5:focus{outline-width:3px;}",".f1grzc83:focus{outline-style:solid;}",".f19shzzi:focus{outline-color:transparent;}"],k:["@-webkit-keyframes fb7n1on{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);transform:rotate(0deg);}100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-ms-transform:rotate(360deg);transform:rotate(360deg);}}","@-webkit-keyframes f1gx3jof{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);transform:rotate(0deg);}100%{-webkit-transform:rotate(-360deg);-moz-transform:rotate(-360deg);-ms-transform:rotate(-360deg);transform:rotate(-360deg);}}","@keyframes fb7n1on{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);transform:rotate(0deg);}100%{-webkit-transform:rotate(360deg);-moz-transform:rotate(360deg);-ms-transform:rotate(360deg);transform:rotate(360deg);}}","@keyframes f1gx3jof{0%{-webkit-transform:rotate(0deg);-moz-transform:rotate(0deg);-ms-transform:rotate(0deg);transform:rotate(0deg);}100%{-webkit-transform:rotate(-360deg);-moz-transform:rotate(-360deg);-ms-transform:rotate(-360deg);transform:rotate(-360deg);}}"],d:[".f5tbecn>svg{-webkit-animation-name:fb7n1on;animation-name:fb7n1on;}",".f15qb8s7>svg{-webkit-animation-name:f1gx3jof;animation-name:f1gx3jof;}",".fn4mtlg>svg{-webkit-animation-duration:3s;animation-duration:3s;}",".f1y80fxs>svg{-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;}",".f1r2crtq>svg{-webkit-animation-timing-function:linear;animation-timing-function:linear;}",".f1wsi8sr>svg{background-color:transparent;}",".f1da2vov>svg>circle{cx:50%;}",".f11rfva0>svg>circle{cy:50%;}",".f1exc66>svg>circle{fill:none;}",".f1j4wmu2>svg{height:20px;}",".f1vppzuq>svg{width:20px;}",".fv1u54w>svg>circle{stroke-width:var(--strokeWidthThick);}",".fngtx1d>svg>circle{r:9px;}",".fmpqlna>svg{height:24px;}",".f15z5jzu>svg{width:24px;}",".fadawes>svg>circle{r:11px;}",".fo52gbo>svg{height:28px;}",".f1b41i3v>svg{width:28px;}",".f1xqyyrl>svg>circle{r:13px;}",".f1aiqagr>svg{height:32px;}",".f1wtx80b>svg{width:32px;}",".f1flujpd>svg>circle{stroke-width:var(--strokeWidthThicker);}",".f1u06hy7>svg>circle{r:14.5px;}",".f1trdq7b>svg{height:36px;}",".f9e0mc5>svg{width:36px;}",".f13pmvhl>svg>circle{r:16.5px;}",".f89rf2a>svg{height:40px;}",".f1w2xg3q>svg{width:40px;}",".fmn74v6>svg>circle{r:18.5px;}",".f1rx7k5y>svg{height:44px;}",".f1vtyt49>svg{width:44px;}",".f1owbg48>svg>circle{stroke-width:var(--strokeWidthThickest);}",".f1fr1izd>svg>circle{r:20px;}"],m:[["@media screen and (prefers-reduced-motion: reduce){.f1bkm2qd>svg{-webkit-animation-duration:0.01ms;animation-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.f1urqz7h>svg{-webkit-animation-iteration-count:1;animation-iteration-count:1;}}",{m:"screen and (prefers-reduced-motion: reduce)"}]]}),ade=pt({inverted:{gwg7kz:"f1jvpmnu",Bvrehnu:"fq8a5sv",Bidp6o:"f1b4lwqj",cq3kgi:"f1najlst",Btwiser:"fjxod4",B8001xd:"fu3xdw0",Bdordwa:["f1ttdh6v","fmyjox0"],Bo2mdfu:"f1eseayc",E10nrc:"folzdkc",Bwl7w15:"fhlfkde",Bksq7rz:"f1esql28"},primary:{gwg7kz:"f11ditju",B8k2rxp:"f1m9nikz",Bvrehnu:"fq8a5sv",Bidp6o:"f1b4lwqj",cq3kgi:"f1najlst",Btwiser:"fjxod4",B8001xd:"fu3xdw0",Bdordwa:["f1ttdh6v","fmyjox0"],Bo2mdfu:"f1eseayc",E10nrc:"folzdkc",Bwl7w15:"fhlfkde",Bksq7rz:"f61h2gu",y14cdu:"flglbw1"}},{d:[".f1jvpmnu>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}",".fq8a5sv>svg>circle.fui-Spinner__Tail{-webkit-animation-name:f1v1ql0f;animation-name:f1v1ql0f;}",".f1b4lwqj>svg>circle.fui-Spinner__Tail{-webkit-animation-duration:1.5s;animation-duration:1.5s;}",".f1najlst>svg>circle.fui-Spinner__Tail{-webkit-animation-iteration-count:infinite;animation-iteration-count:infinite;}",".fjxod4>svg>circle.fui-Spinner__Tail{-webkit-animation-timing-function:var(--curveEasyEase);animation-timing-function:var(--curveEasyEase);}",".fu3xdw0>svg>circle.fui-Spinner__Tail{stroke-linecap:round;}",".f1ttdh6v>svg>circle.fui-Spinner__Tail{-webkit-transform:rotate(-90deg);-moz-transform:rotate(-90deg);-ms-transform:rotate(-90deg);transform:rotate(-90deg);}",".fmyjox0>svg>circle.fui-Spinner__Tail{-webkit-transform:rotate(90deg);-moz-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg);}",".f1eseayc>svg>circle.fui-Spinner__Tail{transform-origin:50% 50%;}",".f1esql28>svg>circle.fui-Spinner__Track{stroke:rgba(255, 255, 255, 0.2);}",".f11ditju>svg>circle.fui-Spinner__Tail{stroke:var(--colorBrandStroke1);}",".f61h2gu>svg>circle.fui-Spinner__Track{stroke:var(--colorBrandStroke2);}"],k:["@-webkit-keyframes f1v1ql0f{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}","@keyframes f1v1ql0f{0%{stroke-dasharray:1,150;stroke-dashoffset:0;}50%{stroke-dasharray:90,150;stroke-dashoffset:-35;}100%{stroke-dasharray:90,150;stroke-dashoffset:-124;}}"],m:[["@media screen and (prefers-reduced-motion: reduce){.folzdkc>svg>circle.fui-Spinner__Tail{-webkit-animation-duration:0.01ms;animation-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.fhlfkde>svg>circle.fui-Spinner__Tail{-webkit-animation-iteration-count:1;animation-iteration-count:1;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (forced-colors: active){.f1m9nikz>svg>circle.fui-Spinner__Tail{stroke:var(--colorNeutralStrokeOnBrand2);}}",{m:"screen and (forced-colors: active)"}],["@media screen and (prefers-reduced-motion: reduce){.folzdkc>svg>circle.fui-Spinner__Tail{-webkit-animation-duration:0.01ms;animation-duration:0.01ms;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (prefers-reduced-motion: reduce){.fhlfkde>svg>circle.fui-Spinner__Tail{-webkit-animation-iteration-count:1;animation-iteration-count:1;}}",{m:"screen and (prefers-reduced-motion: reduce)"}],["@media screen and (forced-colors: active){.flglbw1>svg>circle.fui-Spinner__Track{stroke:var(--colorNeutralBackgroundInverted);}}",{m:"screen and (forced-colors: active)"}]]}),sde=pt({inverted:{sj55zd:"f15aqcq"},primary:{},tiny:{Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"},"extra-small":{Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"},small:{Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"},medium:{Bahqtrf:"fk6fouc",Be2twd7:"fod5ikn",Bhrd7zp:"fl43uef",Bg96gwp:"faaz57k"},large:{Bahqtrf:"fk6fouc",Be2twd7:"fod5ikn",Bhrd7zp:"fl43uef",Bg96gwp:"faaz57k"},"extra-large":{Bahqtrf:"fk6fouc",Be2twd7:"fod5ikn",Bhrd7zp:"fl43uef",Bg96gwp:"faaz57k"},huge:{Bahqtrf:"fk6fouc",Be2twd7:"f1pp30po",Bhrd7zp:"fl43uef",Bg96gwp:"f106mvju"}},{d:[".f15aqcq{color:rgba(255, 255, 255, 1);}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}",".fod5ikn{font-size:var(--fontSizeBase400);}",".fl43uef{font-weight:var(--fontWeightSemibold);}",".faaz57k{line-height:var(--lineHeightBase400);}",".f1pp30po{font-size:var(--fontSizeBase500);}",".f106mvju{line-height:var(--lineHeightBase500);}"]}),lde=e=>{const{labelPosition:t,size:n,appearance:r="primary"}=e,o=ode(),i=ide(),a=sde(),s=ade();return e.root.className=et(c9.root,o.root,(t==="above"||t==="below")&&o.vertical,(t==="before"||t==="after")&&o.horizontal,e.root.className),e.spinner&&(e.spinner.className=et(c9.spinner,i.spinnerSVG,i[n],s[r],e.spinner.className)),e.label&&(e.label.className=et(c9.label,a[n],a[r],e.label.className)),e},TD=T.forwardRef((e,t)=>{const n=nde(e,t);return lde(n),rde(n)});TD.displayName="Spinner";const ude=(e,t)=>{const{checked:n,defaultChecked:r,disabled:o,labelPosition:i="after",onChange:a,required:s}=e,l=lO({props:e,primarySlotTagName:"input",excludedPropNames:["checked","defaultChecked","onChange"]}),u=lo("switch-",l.primary.id),d=$t(e.root,{defaultProps:{ref:pie(),...l.root},required:!0}),h=$t(e.indicator,{defaultProps:{"aria-hidden":!0,children:T.createElement(Vae,null)},required:!0}),p=$t(e.input,{defaultProps:{checked:n,defaultChecked:r,id:u,ref:t,role:"switch",type:"checkbox",...l.primary},required:!0});p.onChange=Vn(p.onChange,v=>a==null?void 0:a(v,{checked:v.currentTarget.checked}));const m=$t(e.label,{defaultProps:{disabled:o,htmlFor:u,required:s,size:"medium"}});return{labelPosition:i,components:{root:"div",indicator:"div",input:"input",label:Zo},root:d,indicator:h,input:p,label:m}},cde=e=>{const{slots:t,slotProps:n}=Jn(e),{labelPosition:r}=e;return T.createElement(t.root,{...n.root},T.createElement(t.input,{...n.input}),r!=="after"&&t.label&&T.createElement(t.label,{...n.label}),T.createElement(t.indicator,{...n.indicator}),r==="after"&&t.label&&T.createElement(t.label,{...n.label}))},Wm={root:"fui-Switch",indicator:"fui-Switch__indicator",input:"fui-Switch__input",label:"fui-Switch__label"},fde=$c("r1u7w45w","rlzel8d",[".r1u7w45w{-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;box-sizing:border-box;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;position:relative;}",".r1u7w45w:focus{outline-style:none;}",".r1u7w45w:focus-visible{outline-style:none;}",".r1u7w45w[data-fui-focus-within]:focus-within{border-top-color:transparent;border-right-color:transparent;border-bottom-color:transparent;border-left-color:transparent;}",'.r1u7w45w[data-fui-focus-within]:focus-within::after{content:"";position:absolute;pointer-events:none;z-index:1;border-top-style:solid;border-right-style:solid;border-bottom-style:solid;border-left-style:solid;border-top-width:2px;border-right-width:2px;border-bottom-width:2px;border-left-width:2px;border-bottom-right-radius:var(--borderRadiusMedium);border-bottom-left-radius:var(--borderRadiusMedium);border-top-right-radius:var(--borderRadiusMedium);border-top-left-radius:var(--borderRadiusMedium);border-top-color:var(--colorStrokeFocus2);border-right-color:var(--colorStrokeFocus2);border-bottom-color:var(--colorStrokeFocus2);border-left-color:var(--colorStrokeFocus2);top:-2px;bottom:-2px;left:-2px;right:-2px;}',".rlzel8d{-webkit-align-items:flex-start;-webkit-box-align:flex-start;-ms-flex-align:flex-start;align-items:flex-start;box-sizing:border-box;display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;position:relative;}",".rlzel8d:focus{outline-style:none;}",".rlzel8d:focus-visible{outline-style:none;}",".rlzel8d[data-fui-focus-within]:focus-within{border-top-color:transparent;border-left-color:transparent;border-bottom-color:transparent;border-right-color:transparent;}",'.rlzel8d[data-fui-focus-within]:focus-within::after{content:"";position:absolute;pointer-events:none;z-index:1;border-top-style:solid;border-left-style:solid;border-bottom-style:solid;border-right-style:solid;border-top-width:2px;border-left-width:2px;border-bottom-width:2px;border-right-width:2px;border-bottom-left-radius:var(--borderRadiusMedium);border-bottom-right-radius:var(--borderRadiusMedium);border-top-left-radius:var(--borderRadiusMedium);border-top-right-radius:var(--borderRadiusMedium);border-top-color:var(--colorStrokeFocus2);border-left-color:var(--colorStrokeFocus2);border-bottom-color:var(--colorStrokeFocus2);border-right-color:var(--colorStrokeFocus2);top:-2px;bottom:-2px;right:-2px;left:-2px;}']),dde=pt({vertical:{Beiy3e4:"f1vx9l62"}},{d:[".f1vx9l62{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}"]}),hde=$c("r13wlxb8",null,[".r13wlxb8{border-radius:var(--borderRadiusCircular);border:1px solid;line-height:0;box-sizing:border-box;fill:currentColor;-webkit-flex-shrink:0;-ms-flex-negative:0;flex-shrink:0;font-size:18px;height:20px;margin:var(--spacingVerticalS) var(--spacingHorizontalS);pointer-events:none;transition-duration:var(--durationNormal);transition-timing-function:var(--curveEasyEase);transition-property:background,border,color;width:40px;}","@media screen and (prefers-reduced-motion: reduce){.r13wlxb8{transition-duration:0.01ms;}}",".r13wlxb8>*{transition-duration:var(--durationNormal);transition-timing-function:var(--curveEasyEase);transition-property:transform;}","@media screen and (prefers-reduced-motion: reduce){.r13wlxb8>*{transition-duration:0.01ms;}}"]),pde=pt({labelAbove:{B6of3ja:"f1hu3pq6"}},{d:[".f1hu3pq6{margin-top:0;}"]}),mde=$c("r92li9d","rxjpw57",[".r92li9d{box-sizing:border-box;cursor:pointer;height:100%;margin:0;opacity:0;position:absolute;width:calc(40px + 2 * var(--spacingHorizontalS));}",".r92li9d:checked~.fui-Switch__indicator>*{-webkit-transform:translateX(20px);-moz-transform:translateX(20px);-ms-transform:translateX(20px);transform:translateX(20px);}",".r92li9d:disabled{cursor:default;}",".r92li9d:disabled~.fui-Switch__indicator{color:var(--colorNeutralForegroundDisabled);}",".r92li9d:disabled~.fui-Switch__label{cursor:default;color:var(--colorNeutralForegroundDisabled);}",".r92li9d:enabled:not(:checked)~.fui-Switch__indicator{color:var(--colorNeutralStrokeAccessible);border-color:var(--colorNeutralStrokeAccessible);}",".r92li9d:enabled:not(:checked)~.fui-Switch__label{color:var(--colorNeutralForeground1);}",".r92li9d:enabled:not(:checked):hover~.fui-Switch__indicator{color:var(--colorNeutralStrokeAccessibleHover);border-color:var(--colorNeutralStrokeAccessibleHover);}",".r92li9d:enabled:not(:checked):hover:active~.fui-Switch__indicator{color:var(--colorNeutralStrokeAccessiblePressed);border-color:var(--colorNeutralStrokeAccessiblePressed);}",".r92li9d:enabled:checked~.fui-Switch__indicator{background-color:var(--colorCompoundBrandBackground);color:var(--colorNeutralForegroundInverted);border-color:var(--colorTransparentStroke);}",".r92li9d:enabled:checked:hover~.fui-Switch__indicator{background-color:var(--colorCompoundBrandBackgroundHover);border-color:var(--colorTransparentStrokeInteractive);}",".r92li9d:enabled:checked:hover:active~.fui-Switch__indicator{background-color:var(--colorCompoundBrandBackgroundPressed);border-color:var(--colorTransparentStrokeInteractive);}",".r92li9d:disabled:not(:checked)~.fui-Switch__indicator{border-color:var(--colorNeutralStrokeDisabled);}",".r92li9d:disabled:checked~.fui-Switch__indicator{background-color:var(--colorNeutralBackgroundDisabled);border-color:var(--colorTransparentStrokeDisabled);}","@media (forced-colors: active){.r92li9d:disabled~.fui-Switch__indicator{color:GrayText;border-color:GrayText;}.r92li9d:disabled~.fui-Switch__label{color:GrayText;}}",".rxjpw57{box-sizing:border-box;cursor:pointer;height:100%;margin:0;opacity:0;position:absolute;width:calc(40px + 2 * var(--spacingHorizontalS));}",".rxjpw57:checked~.fui-Switch__indicator>*{-webkit-transform:translateX(-20px);-moz-transform:translateX(-20px);-ms-transform:translateX(-20px);transform:translateX(-20px);}",".rxjpw57:disabled{cursor:default;}",".rxjpw57:disabled~.fui-Switch__indicator{color:var(--colorNeutralForegroundDisabled);}",".rxjpw57:disabled~.fui-Switch__label{cursor:default;color:var(--colorNeutralForegroundDisabled);}",".rxjpw57:enabled:not(:checked)~.fui-Switch__indicator{color:var(--colorNeutralStrokeAccessible);border-color:var(--colorNeutralStrokeAccessible);}",".rxjpw57:enabled:not(:checked)~.fui-Switch__label{color:var(--colorNeutralForeground1);}",".rxjpw57:enabled:not(:checked):hover~.fui-Switch__indicator{color:var(--colorNeutralStrokeAccessibleHover);border-color:var(--colorNeutralStrokeAccessibleHover);}",".rxjpw57:enabled:not(:checked):hover:active~.fui-Switch__indicator{color:var(--colorNeutralStrokeAccessiblePressed);border-color:var(--colorNeutralStrokeAccessiblePressed);}",".rxjpw57:enabled:checked~.fui-Switch__indicator{background-color:var(--colorCompoundBrandBackground);color:var(--colorNeutralForegroundInverted);border-color:var(--colorTransparentStroke);}",".rxjpw57:enabled:checked:hover~.fui-Switch__indicator{background-color:var(--colorCompoundBrandBackgroundHover);border-color:var(--colorTransparentStrokeInteractive);}",".rxjpw57:enabled:checked:hover:active~.fui-Switch__indicator{background-color:var(--colorCompoundBrandBackgroundPressed);border-color:var(--colorTransparentStrokeInteractive);}",".rxjpw57:disabled:not(:checked)~.fui-Switch__indicator{border-color:var(--colorNeutralStrokeDisabled);}",".rxjpw57:disabled:checked~.fui-Switch__indicator{background-color:var(--colorNeutralBackgroundDisabled);border-color:var(--colorTransparentStrokeDisabled);}","@media (forced-colors: active){.rxjpw57:disabled~.fui-Switch__indicator{color:GrayText;border-color:GrayText;}.rxjpw57:disabled~.fui-Switch__label{color:GrayText;}}"]),gde=pt({before:{j35jbq:["f1e31b4d","f1vgc2s3"],Bhzewxz:"f15twtuk"},after:{oyh7mz:["f1vgc2s3","f1e31b4d"],Bhzewxz:"f15twtuk"},above:{B5kzvoi:"f1yab3r1",Bqenvij:"f1aar7gd",a9b677:"fly5x3f"}},{d:[".f1e31b4d{right:0;}",".f1vgc2s3{left:0;}",".f15twtuk{top:0;}",".f1yab3r1{bottom:0;}",".f1aar7gd{height:calc(20px + var(--spacingVerticalS));}",".fly5x3f{width:100%;}"]}),vde=pt({base:{Bceei9c:"f1k6fduh",jrapky:"f49ad5g",B6of3ja:"f1xlvstr",z8tnut:"f1kwiid1",z189sj:["f1vdfbxk","f1f5gg8d"],Byoj8tv:"f5b47ha",uwmqm3:["f1f5gg8d","f1vdfbxk"]},above:{z8tnut:"f1ywm7hm",Byoj8tv:"f14wxoun",a9b677:"fly5x3f"},after:{uwmqm3:["fruq291","f7x41pl"]},before:{z189sj:["f7x41pl","fruq291"]}},{d:[".f1k6fduh{cursor:pointer;}",".f49ad5g{margin-bottom:calc((20px - var(--lineHeightBase300)) / 2);}",".f1xlvstr{margin-top:calc((20px - var(--lineHeightBase300)) / 2);}",".f1kwiid1{padding-top:var(--spacingVerticalS);}",".f1vdfbxk{padding-right:var(--spacingHorizontalS);}",".f1f5gg8d{padding-left:var(--spacingHorizontalS);}",".f5b47ha{padding-bottom:var(--spacingVerticalS);}",".f1ywm7hm{padding-top:var(--spacingVerticalXS);}",".f14wxoun{padding-bottom:var(--spacingVerticalXS);}",".fly5x3f{width:100%;}",".fruq291{padding-left:var(--spacingHorizontalXS);}",".f7x41pl{padding-right:var(--spacingHorizontalXS);}"]}),bde=e=>{const t=fde(),n=dde(),r=hde(),o=pde(),i=mde(),a=gde(),s=vde(),{label:l,labelPosition:u}=e;return e.root.className=et(Wm.root,t,u==="above"&&n.vertical,e.root.className),e.indicator.className=et(Wm.indicator,r,l&&u==="above"&&o.labelAbove,e.indicator.className),e.input.className=et(Wm.input,i,l&&a[u],e.input.className),e.label&&(e.label.className=et(Wm.label,s.base,s[u],e.label.className)),e},jg=T.forwardRef((e,t)=>{const n=ude(e,t);return bde(n),cde(n)});jg.displayName="Switch";function yde(e,t){return e.key===ap&&t!=="alert"&&!e.isDefaultPrevented()}const Zl="__fluentDisableScrollElement";function Ede(){const{targetDocument:e}=Oo();return T.useCallback(()=>{if(e)return _de(e.body)},[e])}function _de(e){var t,n;const{clientWidth:r}=e.ownerDocument.documentElement,o=(n=(t=e.ownerDocument.defaultView)===null||t===void 0?void 0:t.innerWidth)!==null&&n!==void 0?n:0;return Tde(e),e[Zl].count===0&&(e.style.overflow="hidden",e.style.paddingRight=`${o-r}px`),e[Zl].count++,()=>{e[Zl].count--,e[Zl].count===0&&(e.style.overflow=e[Zl].previousOverflowStyle,e.style.paddingRight=e[Zl].previousPaddingRightStyle)}}function Tde(e){var t,n;(t=(n=e)[Zl])!==null&&t!==void 0||(n[Zl]={count:0,previousOverflowStyle:e.style.overflow,previousPaddingRightStyle:e.style.paddingRight})}function wde(e,t){const{findFirstFocusable:n}=op(),{targetDocument:r}=Oo(),o=T.useRef(null),i=T.useRef();return T.useEffect(()=>{var a,s;if(!e)return(a=i.current)===null||a===void 0?void 0:a.focus();i.current=r==null?void 0:r.activeElement;const l=o.current&&n(o.current);l?l.focus():(s=o.current)===null||s===void 0||s.focus()},[n,e,t,r]),o}const kde={open:!1,modalType:"modal",isNestedDialog:!1,dialogRef:{current:null},requestOpenChange(){}},JT=ry(void 0),Sde=JT.Provider,Ga=e=>oy(JT,(t=kde)=>e(t)),xde=!1,wD=T.createContext(void 0),kD=wD.Provider,Cde=()=>{var e;return(e=T.useContext(wD))!==null&&e!==void 0?e:xde},Ade=e=>{const{children:t,modalType:n="modal",onOpenChange:r}=e,[o,i]=Nde(t),[a,s]=Wc({state:e.open,defaultState:e.defaultOpen,initialState:!1}),l=Et(p=>{r==null||r(p.event,p),p.event.isDefaultPrevented()||s(p.open)}),u=wde(a,n),d=Ede(),h=!!(a&&n!=="non-modal");return us(()=>{if(h)return d()},[d,h]),{components:{backdrop:"div"},open:a,modalType:n,content:a?i:null,trigger:o,requestOpenChange:l,dialogTitleId:lo("dialog-title-"),isNestedDialog:jT(JT),dialogRef:u}};function Nde(e){const t=T.Children.toArray(e);switch(t.length){case 2:return t;case 1:return[void 0,t[0]];default:return[void 0,void 0]}}const Fde=(e,t)=>{const{content:n,trigger:r}=e;return T.createElement(Sde,{value:t.dialog},T.createElement(kD,{value:t.dialogSurface},r,n))};function Ide(e){const{modalType:t,open:n,dialogRef:r,dialogTitleId:o,isNestedDialog:i,requestOpenChange:a}=e;return{dialog:{open:n,modalType:t,dialogRef:r,dialogTitleId:o,isNestedDialog:i,requestOpenChange:a},dialogSurface:!1}}const Kv=T.memo(e=>{const t=Ade(e),n=Ide(t);return Fde(t,n)});Kv.displayName="Dialog";const Bde=e=>{const t=Cde(),{children:n,disableButtonEnhancement:r=!1,action:o=t?"close":"open"}=e,i=tp(n),a=Ga(p=>p.requestOpenChange),s=Ga(p=>p.open),{triggerAttributes:l}=ty(),u=Et(p=>{var m,v;(v=i==null?void 0:(m=i.props).onClick)===null||v===void 0||v.call(m,p),p.isDefaultPrevented()||a({event:p,type:"triggerClick",open:o==="open"})}),d={...i==null?void 0:i.props,"aria-expanded":s,ref:i==null?void 0:i.ref,onClick:u,...l},h=Gd((i==null?void 0:i.type)==="button"||(i==null?void 0:i.type)==="a"?i.type:"div",{...d,type:"button"});return{children:Vb(n,r?d:h)}},Rde=e=>e.children,O0=e=>{const t=Bde(e);return Rde(t)};O0.displayName="DialogTrigger";O0.isFluentTriggerComponent=!0;const Ode=(e,t)=>{const{position:n="end"}=e;return{components:{root:"div"},root:vr("div",{ref:t,...e}),position:n}},Dde=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root})},Pde={root:"fui-DialogActions"},Mde=pt({root:{Bqenvij:"f3052tw",B7ck84d:"f1ewtqcl",mc9l5x:"f22iagw",i8kkvl:"f4px1ci",Belr9w4:"fn67r4l",Bmdcpmo:"f6glcwc",th9wkt:"f1e3st1r"},gridPositionEnd:{Bdqf98w:"f1a7i8kp",Ijaq50:"f11u0jfc",Br312pm:"f1d6tb1o",nk6f5a:"f23awfp",Bw0ie65:"fiappcv"},gridPositionStart:{Bdqf98w:"fsxvdwy",Ijaq50:"f1vnb230",Br312pm:"f14781pt",nk6f5a:"f13d374e",Bw0ie65:"f1fjo411"}},{d:[".f3052tw{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;}",".f1ewtqcl{box-sizing:border-box;}",".f22iagw{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;}",".f4px1ci{-webkit-column-gap:8px;column-gap:8px;}",".fn67r4l{row-gap:8px;}",".f1a7i8kp{justify-self:end;}",".f11u0jfc{grid-row-start:actions-end;}",".f1d6tb1o{grid-column-start:actions-end;}",".f23awfp{grid-row-end:actions-end;}",".fiappcv{grid-column-end:actions-end;}",".fsxvdwy{justify-self:start;}",".f1vnb230{grid-row-start:actions-start;}",".f14781pt{grid-column-start:actions-start;}",".f13d374e{grid-row-end:actions-start;}",".f1fjo411{grid-column-end:actions-start;}"],m:[["@media screen and (max-width: 480px){.f6glcwc{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}}",{m:"screen and (max-width: 480px)"}],["@media screen and (max-width: 480px){.f1e3st1r{justify-self:stretch;}}",{m:"screen and (max-width: 480px)"}]]}),Lde=e=>{const t=Mde();return e.root.className=et(Pde.root,t.root,e.position==="start"&&t.gridPositionStart,e.position==="end"&&t.gridPositionEnd,e.root.className),e},P_=T.forwardRef((e,t)=>{const n=Ode(e,t);return Lde(n),Dde(n)});P_.displayName="DialogActions";const jde=(e,t)=>{var n;return{components:{root:"div"},root:vr((n=e.as)!==null&&n!==void 0?n:"div",{ref:t,...e})}},zde=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root})},Hde={root:"fui-DialogBody"},Ude=pt({root:{mc9l5x:"f13qh94s",fshzfu:"f120kxnn",a9b677:"fly5x3f",Bqenvij:"f3052tw",B2u0y6b:"fvgz9i8",Bxyxcbc:"flnwrvu",B7ck84d:"f1ewtqcl",wkccdc:"f874eam",Budl1dq:"fjj47a5",zoa1oz:"fe34spp",B68tc82:"f1ln0qer",Bmxbyg5:"fa2wlxz",i8kkvl:"f4px1ci",Belr9w4:"fn67r4l",B5xtmjs:"ff54dml",Bqu9lor:"f52bj20",B06wobe:"f1dangjo"}},{d:[".f13qh94s{display:grid;}",".f120kxnn::backdrop{background-color:rgba(0, 0, 0, 0.4);}",".fly5x3f{width:100%;}",".f3052tw{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;}",".fvgz9i8{max-width:600px;}",".flnwrvu{max-height:calc(100vh - 2 * 24px);}",".f1ewtqcl{box-sizing:border-box;}",".f874eam{grid-template-rows:auto 1fr auto;}",".fjj47a5{grid-template-columns:1fr 1fr auto;}",'.fe34spp{grid-template-areas:"title title close-button" "body body body" "actions-start actions-end actions-end";}',".f1ln0qer{overflow-x:unset;}",".fa2wlxz{overflow-y:unset;}",".f4px1ci{-webkit-column-gap:8px;column-gap:8px;}",".fn67r4l{row-gap:8px;}"],m:[["@media screen and (max-width: 480px){.ff54dml{max-width:100vw;}}",{m:"screen and (max-width: 480px)"}],["@media screen and (max-width: 480px){.f52bj20{grid-template-rows:auto 1fr auto auto;}}",{m:"screen and (max-width: 480px)"}],['@media screen and (max-width: 480px){.f1dangjo{grid-template-areas:"title title close-button" "body body body" "actions-start actions-start actions-start" "actions-end actions-end actions-end";}}',{m:"screen and (max-width: 480px)"}]]}),qde=e=>{const t=Ude();return e.root.className=et(Hde.root,t.root,e.root.className),e},Vv=T.forwardRef((e,t)=>{const n=jde(e,t);return qde(n),zde(n)});Vv.displayName="DialogBody";const B6={root:"fui-DialogTitle",action:"fui-DialogTitle__action"},$de=pt({root:{Bahqtrf:"fk6fouc",Be2twd7:"f1pp30po",Bhrd7zp:"fl43uef",Bg96gwp:"f106mvju",Ijaq50:"faq1aip",Br312pm:"f1m489tg",nk6f5a:"fv2srd9",Bw0ie65:"f1tz6hh8"},rootWithoutCloseButton:{Ijaq50:"faq1aip",Br312pm:"f1m489tg",nk6f5a:"f11nczdl",Bw0ie65:"f98d4vj"},action:{Ijaq50:"f1hysmiz",Br312pm:"f1379kmu",nk6f5a:"f11nczdl",Bw0ie65:"f98d4vj"}},{d:[".fk6fouc{font-family:var(--fontFamilyBase);}",".f1pp30po{font-size:var(--fontSizeBase500);}",".fl43uef{font-weight:var(--fontWeightSemibold);}",".f106mvju{line-height:var(--lineHeightBase500);}",".faq1aip{grid-row-start:title;}",".f1m489tg{grid-column-start:title;}",".fv2srd9{grid-row-end:title;}",".f1tz6hh8{grid-column-end:title;}",".f11nczdl{grid-row-end:close-button;}",".f98d4vj{grid-column-end:close-button;}",".f1hysmiz{grid-row-start:close-button;}",".f1379kmu{grid-column-start:close-button;}"]}),Wde=pt({button:{qhf8xq:"f10pi13n",B7ck84d:"f1e4lqlz",De3pzq:"f1u2r49w",sj55zd:"f1ym3bx4",Bahqtrf:"f1mo0ibp",Be2twd7:"fjoy568",Bceei9c:"f1k6fduh",Bg96gwp:"fez10in",B68tc82:"f1mtd64y",Bmxbyg5:"f1y7q3j9",z8tnut:"f1g0x7ka",z189sj:["fhxju0i","f1cnd47f"],Byoj8tv:"f1qch9an",uwmqm3:["f1cnd47f","fhxju0i"],icvyot:"f1ern45e",vrafjx:["f1n71otn","f1deefiw"],oivjwe:"f1h8hb77",wvpqe5:["f1deefiw","f1n71otn"],Bv0vk6g:"f37px4s",fsow6f:"fgusgyc",Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",B8q5s1w:"f8hki3x",Bci5o5g:["f1d2448m","ffh67wi"],n8qw10:"f1bjia2o",Bdrgwmp:["ffh67wi","f1d2448m"],Bm4h7ae:"f15bsgw9",B7ys5i9:"f14e48fq",Busjfv9:"f18yb2kv",Bhk32uz:"fd6o370",Bf4ptjt:"fh1cnn4",kclons:["fy7oxxb","f184ne2d"],Bhdgwq3:"fpukqih",Blkhhs4:["f184ne2d","fy7oxxb"],Bqtpl0w:"frrh606",clg4pj:["f1v5zibi","fo2hd23"],hgwjuy:"ful5kiu",Bonggc9:["fo2hd23","f1v5zibi"],B1tsrr9:["f1jqcqds","ftffrms"],Dah5zi:["ftffrms","f1jqcqds"],Bkh64rk:["f2e7qr6","fsr1zz6"],qqdqy8:["fsr1zz6","f2e7qr6"],B6dhp37:"f1dvezut",i03rao:["fd0oaoj","f1cwg4i8"],Boxcth7:"fjvm52t",Bsom6fd:["f1cwg4i8","fd0oaoj"],J0r882:"fdiulkx",Bjwuhne:"f1yalx80",Ghsupd:["fq22d5a","f1jw7pan"],Bule8hv:["f1jw7pan","fq22d5a"]}},{d:[".f10pi13n{position:relative;}",".f1e4lqlz{box-sizing:content-box;}",".f1u2r49w{background-color:inherit;}",".f1ym3bx4{color:inherit;}",".f1mo0ibp{font-family:inherit;}",".fjoy568{font-size:inherit;}",".f1k6fduh{cursor:pointer;}",".fez10in{line-height:0;}",".f1mtd64y{overflow-x:visible;}",".f1y7q3j9{overflow-y:visible;}",".f1g0x7ka{padding-top:0;}",".fhxju0i{padding-right:0;}",".f1cnd47f{padding-left:0;}",".f1qch9an{padding-bottom:0;}",".f1ern45e{border-top-style:none;}",".f1n71otn{border-right-style:none;}",".f1deefiw{border-left-style:none;}",".f1h8hb77{border-bottom-style:none;}",".f37px4s{-webkit-appearance:button;}",".fgusgyc{text-align:unset;}",".f8hki3x[data-fui-focus-visible]{border-top-color:transparent;}",".f1d2448m[data-fui-focus-visible]{border-right-color:transparent;}",".ffh67wi[data-fui-focus-visible]{border-left-color:transparent;}",".f1bjia2o[data-fui-focus-visible]{border-bottom-color:transparent;}",'.f15bsgw9[data-fui-focus-visible]::after{content:"";}',".f14e48fq[data-fui-focus-visible]::after{position:absolute;}",".f18yb2kv[data-fui-focus-visible]::after{pointer-events:none;}",".fd6o370[data-fui-focus-visible]::after{z-index:1;}",".fh1cnn4[data-fui-focus-visible]::after{border-top-style:solid;}",".fy7oxxb[data-fui-focus-visible]::after{border-right-style:solid;}",".f184ne2d[data-fui-focus-visible]::after{border-left-style:solid;}",".fpukqih[data-fui-focus-visible]::after{border-bottom-style:solid;}",".frrh606[data-fui-focus-visible]::after{border-top-width:2px;}",".f1v5zibi[data-fui-focus-visible]::after{border-right-width:2px;}",".fo2hd23[data-fui-focus-visible]::after{border-left-width:2px;}",".ful5kiu[data-fui-focus-visible]::after{border-bottom-width:2px;}",".f1jqcqds[data-fui-focus-visible]::after{border-bottom-right-radius:var(--borderRadiusMedium);}",".ftffrms[data-fui-focus-visible]::after{border-bottom-left-radius:var(--borderRadiusMedium);}",".f2e7qr6[data-fui-focus-visible]::after{border-top-right-radius:var(--borderRadiusMedium);}",".fsr1zz6[data-fui-focus-visible]::after{border-top-left-radius:var(--borderRadiusMedium);}",".f1dvezut[data-fui-focus-visible]::after{border-top-color:var(--colorStrokeFocus2);}",".fd0oaoj[data-fui-focus-visible]::after{border-right-color:var(--colorStrokeFocus2);}",".f1cwg4i8[data-fui-focus-visible]::after{border-left-color:var(--colorStrokeFocus2);}",".fjvm52t[data-fui-focus-visible]::after{border-bottom-color:var(--colorStrokeFocus2);}",".fdiulkx[data-fui-focus-visible]::after{top:-2px;}",".f1yalx80[data-fui-focus-visible]::after{bottom:-2px;}",".fq22d5a[data-fui-focus-visible]::after{left:-2px;}",".f1jw7pan[data-fui-focus-visible]::after{right:-2px;}"],f:[".ftqa4ok:focus{outline-style:none;}"],i:[".f2hkw1w:focus-visible{outline-style:none;}"]}),Gde=e=>{const t=$de();return e.root.className=et(B6.root,t.root,!e.action&&t.rootWithoutCloseButton,e.root.className),e.action&&(e.action.className=et(B6.action,t.action,e.action.className)),e},Kde=(e,t)=>{const{as:n,action:r}=e,o=Ga(a=>a.modalType),i=Wde();return{components:{root:"div",action:"div"},root:vr(n??"div",{ref:t,id:Ga(a=>a.dialogTitleId),...e}),action:$t(r,{required:o==="non-modal",defaultProps:{children:T.createElement(O0,{disableButtonEnhancement:!0,action:"close"},T.createElement("button",{className:i.button,"aria-label":"close"},T.createElement(dse,null)))}})}},Vde=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(T.Fragment,null,T.createElement(t.root,{...n.root},n.root.children),t.action&&T.createElement(t.action,{...n.action}))},Yv=T.forwardRef((e,t)=>{const n=Kde(e,t);return Gde(n),Vde(n)});Yv.displayName="DialogTitle";const Yde=(e,t)=>{const{backdrop:n,as:r}=e,o=Ga(p=>p.modalType),i=Ga(p=>p.dialogRef),a=Ga(p=>p.open),s=Ga(p=>p.requestOpenChange),l=Ga(p=>p.dialogTitleId),u=Et(p=>{var m,v;Are(e.backdrop)&&((v=(m=e.backdrop).onClick)===null||v===void 0||v.call(m,p)),o==="modal"&&!p.isDefaultPrevented()&&s({event:p,open:!1,type:"backdropClick"})}),d=Et(p=>{var m;(m=e.onKeyDown)===null||m===void 0||m.call(e,p),yde(p,o)&&(s({event:p,open:!1,type:"escapeKeyDown"}),p.stopPropagation())}),{modalAttributes:h}=ty({trapFocus:o!=="non-modal"});return{components:{backdrop:"div",root:"div"},backdrop:$t(n,{required:a&&o!=="non-modal",defaultProps:{"aria-hidden":"true",onClick:u}}),root:vr(r??"div",{tabIndex:-1,"aria-modal":o!=="non-modal",role:o==="alert"?"alertdialog":"dialog","aria-labelledby":e["aria-label"]?void 0:l,...e,...h,onKeyDown:d,ref:cs(t,i)})}},Qde=(e,t)=>{const{slots:n,slotProps:r}=Jn(e);return T.createElement(sp,null,n.backdrop&&T.createElement(n.backdrop,{...r.backdrop}),T.createElement(kD,{value:t.dialogSurface},T.createElement(n.root,{...r.root})))},R6={root:"fui-DialogSurface",backdrop:"fui-DialogSurface__backdrop"},Xde=pt({focusOutline:{Brovlpu:"ftqa4ok",B486eqv:"f2hkw1w",B8q5s1w:"f8hki3x",Bci5o5g:["f1d2448m","ffh67wi"],n8qw10:"f1bjia2o",Bdrgwmp:["ffh67wi","f1d2448m"],Bm4h7ae:"f15bsgw9",B7ys5i9:"f14e48fq",Busjfv9:"f18yb2kv",Bhk32uz:"fd6o370",Bf4ptjt:"fh1cnn4",kclons:["fy7oxxb","f184ne2d"],Bhdgwq3:"fpukqih",Blkhhs4:["f184ne2d","fy7oxxb"],Bqtpl0w:"frrh606",clg4pj:["f1v5zibi","fo2hd23"],hgwjuy:"ful5kiu",Bonggc9:["fo2hd23","f1v5zibi"],B1tsrr9:["f1jqcqds","ftffrms"],Dah5zi:["ftffrms","f1jqcqds"],Bkh64rk:["f2e7qr6","fsr1zz6"],qqdqy8:["fsr1zz6","f2e7qr6"],B6dhp37:"f1dvezut",i03rao:["fd0oaoj","f1cwg4i8"],Boxcth7:"fjvm52t",Bsom6fd:["f1cwg4i8","fd0oaoj"],J0r882:"fdiulkx",Bjwuhne:"f1yalx80",Ghsupd:["fq22d5a","f1jw7pan"],Bule8hv:["f1jw7pan","fq22d5a"]},root:{mc9l5x:"ftgm304",famaaq:"f1c515w",Bcdw1i0:"f1bitti",Bhzewxz:"f15twtuk",j35jbq:["f1e31b4d","f1vgc2s3"],B5kzvoi:"f1yab3r1",oyh7mz:["f1vgc2s3","f1e31b4d"],z8tnut:"fuq56rw",z189sj:["f15kemlc","fdgang7"],Byoj8tv:"fl2zwns",uwmqm3:["fdgang7","f15kemlc"],B6of3ja:"fgr6219",t21cq0:["f1ujusj6","fcgxt0o"],jrapky:"f10jk5vf",Frg6f3:["fcgxt0o","f1ujusj6"],icvyot:"fzkkow9",vrafjx:["fcdblym","fjik90z"],oivjwe:"fg706s2",wvpqe5:["fjik90z","fcdblym"],B68tc82:"f1ln0qer",Bmxbyg5:"fa2wlxz",fshzfu:"f120kxnn",qhf8xq:"f19dog8a",a9b677:"fly5x3f",Bqenvij:"f3052tw",B2u0y6b:"fvgz9i8",Bxyxcbc:"f6a9g1z",B7ck84d:"f1ewtqcl",E5pizo:"f10nrhrw",De3pzq:"fxugw4r",sj55zd:"f19n0e5",B4j52fo:"f5ogflp",Bekrc4i:["f1hqa2wf","finvdd3"],Bn0qgzm:"f1f09k3d",ibv6hh:["finvdd3","f1hqa2wf"],g2u3we:"fghlq4f",h3c5rm:["f1gn591s","fjscplz"],B9xav0g:"fb073pr",zhjwy3:["fjscplz","f1gn591s"],Bbmb7ep:["fnivh3a","fc7yr5o"],Beyfa6y:["fc7yr5o","fnivh3a"],B7oj6ja:["f1el4m67","f8yange"],Btl43ni:["f8yange","f1el4m67"],B5xtmjs:"ff54dml"},backdrop:{qhf8xq:"f19dog8a",De3pzq:"fju19wo",Bhzewxz:"f113wtx2",j35jbq:["f10k790i","f1xynx9j"],B5kzvoi:"f5gq2j6",oyh7mz:["f1xynx9j","f10k790i"]},nestedDialogBackdrop:{De3pzq:"f3rmtva"},nestedNativeDialogBackdrop:{fshzfu:"foe20jx"}},{f:[".ftqa4ok:focus{outline-style:none;}"],i:[".f2hkw1w:focus-visible{outline-style:none;}"],d:[".f8hki3x[data-fui-focus-visible]{border-top-color:transparent;}",".f1d2448m[data-fui-focus-visible]{border-right-color:transparent;}",".ffh67wi[data-fui-focus-visible]{border-left-color:transparent;}",".f1bjia2o[data-fui-focus-visible]{border-bottom-color:transparent;}",'.f15bsgw9[data-fui-focus-visible]::after{content:"";}',".f14e48fq[data-fui-focus-visible]::after{position:absolute;}",".f18yb2kv[data-fui-focus-visible]::after{pointer-events:none;}",".fd6o370[data-fui-focus-visible]::after{z-index:1;}",".fh1cnn4[data-fui-focus-visible]::after{border-top-style:solid;}",".fy7oxxb[data-fui-focus-visible]::after{border-right-style:solid;}",".f184ne2d[data-fui-focus-visible]::after{border-left-style:solid;}",".fpukqih[data-fui-focus-visible]::after{border-bottom-style:solid;}",".frrh606[data-fui-focus-visible]::after{border-top-width:2px;}",".f1v5zibi[data-fui-focus-visible]::after{border-right-width:2px;}",".fo2hd23[data-fui-focus-visible]::after{border-left-width:2px;}",".ful5kiu[data-fui-focus-visible]::after{border-bottom-width:2px;}",".f1jqcqds[data-fui-focus-visible]::after{border-bottom-right-radius:var(--borderRadiusMedium);}",".ftffrms[data-fui-focus-visible]::after{border-bottom-left-radius:var(--borderRadiusMedium);}",".f2e7qr6[data-fui-focus-visible]::after{border-top-right-radius:var(--borderRadiusMedium);}",".fsr1zz6[data-fui-focus-visible]::after{border-top-left-radius:var(--borderRadiusMedium);}",".f1dvezut[data-fui-focus-visible]::after{border-top-color:var(--colorStrokeFocus2);}",".fd0oaoj[data-fui-focus-visible]::after{border-right-color:var(--colorStrokeFocus2);}",".f1cwg4i8[data-fui-focus-visible]::after{border-left-color:var(--colorStrokeFocus2);}",".fjvm52t[data-fui-focus-visible]::after{border-bottom-color:var(--colorStrokeFocus2);}",".fdiulkx[data-fui-focus-visible]::after{top:-2px;}",".f1yalx80[data-fui-focus-visible]::after{bottom:-2px;}",".fq22d5a[data-fui-focus-visible]::after{left:-2px;}",".f1jw7pan[data-fui-focus-visible]::after{right:-2px;}",".ftgm304{display:block;}",".f1c515w{-webkit-user-select:unset;-moz-user-select:unset;-ms-user-select:unset;user-select:unset;}",".f1bitti{visibility:unset;}",".f15twtuk{top:0;}",".f1e31b4d{right:0;}",".f1vgc2s3{left:0;}",".f1yab3r1{bottom:0;}",".fuq56rw{padding-top:24px;}",".f15kemlc{padding-right:24px;}",".fdgang7{padding-left:24px;}",".fl2zwns{padding-bottom:24px;}",".fgr6219{margin-top:auto;}",".f1ujusj6{margin-right:auto;}",".fcgxt0o{margin-left:auto;}",".f10jk5vf{margin-bottom:auto;}",".fzkkow9{border-top-style:solid;}",".fcdblym{border-right-style:solid;}",".fjik90z{border-left-style:solid;}",".fg706s2{border-bottom-style:solid;}",".f1ln0qer{overflow-x:unset;}",".fa2wlxz{overflow-y:unset;}",".f120kxnn::backdrop{background-color:rgba(0, 0, 0, 0.4);}",".f19dog8a{position:fixed;}",".fly5x3f{width:100%;}",".f3052tw{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content;}",".fvgz9i8{max-width:600px;}",".f6a9g1z{max-height:100vh;}",".f1ewtqcl{box-sizing:border-box;}",".f10nrhrw{box-shadow:var(--shadow64);}",".fxugw4r{background-color:var(--colorNeutralBackground1);}",".f19n0e5{color:var(--colorNeutralForeground1);}",".f5ogflp{border-top-width:1px;}",".f1hqa2wf{border-right-width:1px;}",".finvdd3{border-left-width:1px;}",".f1f09k3d{border-bottom-width:1px;}",".fghlq4f{border-top-color:var(--colorTransparentStroke);}",".f1gn591s{border-right-color:var(--colorTransparentStroke);}",".fjscplz{border-left-color:var(--colorTransparentStroke);}",".fb073pr{border-bottom-color:var(--colorTransparentStroke);}",".fnivh3a{border-bottom-right-radius:var(--borderRadiusXLarge);}",".fc7yr5o{border-bottom-left-radius:var(--borderRadiusXLarge);}",".f1el4m67{border-top-right-radius:var(--borderRadiusXLarge);}",".f8yange{border-top-left-radius:var(--borderRadiusXLarge);}",".fju19wo{background-color:rgba(0, 0, 0, 0.4);}",".f113wtx2{top:0px;}",".f10k790i{right:0px;}",".f1xynx9j{left:0px;}",".f5gq2j6{bottom:0px;}",".f3rmtva{background-color:transparent;}",".foe20jx::backdrop{background-color:transparent;}"],m:[["@media screen and (max-width: 480px){.ff54dml{max-width:100vw;}}",{m:"screen and (max-width: 480px)"}]]}),Zde=e=>{const t=Xde(),n=Ga(r=>r.isNestedDialog);return e.root.className=et(R6.root,t.root,t.focusOutline,n&&t.nestedNativeDialogBackdrop,e.root.className),e.backdrop&&(e.backdrop.className=et(R6.backdrop,t.backdrop,n&&t.nestedDialogBackdrop,e.backdrop.className)),e};function Jde(e){return{dialogSurface:!0}}const Qv=T.forwardRef((e,t)=>{const n=Yde(e,t),r=Jde();return Zde(n),Qde(n,r)});Qv.displayName="DialogSurface";const e1e=(e,t)=>{var n;return{components:{root:"div"},root:vr((n=e.as)!==null&&n!==void 0?n:"div",{ref:t,...e})}},t1e=e=>{const{slots:t,slotProps:n}=Jn(e);return T.createElement(t.root,{...n.root})},n1e={root:"fui-DialogContent"},r1e=pt({root:{a9b677:"fly5x3f",Bqenvij:"f1l02sjl",Bmxbyg5:"f5zp4f",sshi5w:"f1nxs5xn",B7ck84d:"f1ewtqcl",Ijaq50:"f6owso0",Br312pm:"fupswjn",nk6f5a:"foucsne",Bw0ie65:"f1ka72gx",Bahqtrf:"fk6fouc",Be2twd7:"fkhj508",Bhrd7zp:"figsok6",Bg96gwp:"f1i3iumi"}},{d:[".fly5x3f{width:100%;}",".f1l02sjl{height:100%;}",".f5zp4f{overflow-y:auto;}",".f1nxs5xn{min-height:32px;}",".f1ewtqcl{box-sizing:border-box;}",".f6owso0{grid-row-start:body;}",".fupswjn{grid-column-start:body;}",".foucsne{grid-row-end:body;}",".f1ka72gx{grid-column-end:body;}",".fk6fouc{font-family:var(--fontFamilyBase);}",".fkhj508{font-size:var(--fontSizeBase300);}",".figsok6{font-weight:var(--fontWeightRegular);}",".f1i3iumi{line-height:var(--lineHeightBase300);}"]}),o1e=e=>{const t=r1e();return e.root.className=et(n1e.root,t.root,e.root.className),e},Xv=T.forwardRef((e,t)=>{const n=e1e(e,t);return o1e(n),t1e(n)});Xv.displayName="DialogContent";function l1(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var u1=function(){function e(){this.listeners=[]}var t=e.prototype;return t.subscribe=function(r){var o=this,i=r||function(){};return this.listeners.push(i),this.onSubscribe(),function(){o.listeners=o.listeners.filter(function(a){return a!==i}),o.onUnsubscribe()}},t.hasListeners=function(){return this.listeners.length>0},t.onSubscribe=function(){},t.onUnsubscribe=function(){},e}();function At(){return At=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},At.apply(this,arguments)}var Zv=typeof window>"u";function Kr(){}function i1e(e,t){return typeof e=="function"?e(t):e}function M_(e){return typeof e=="number"&&e>=0&&e!==1/0}function Jv(e){return Array.isArray(e)?e:[e]}function SD(e,t){return Math.max(e+(t||0)-Date.now(),0)}function zg(e,t,n){return lp(e)?typeof t=="function"?At({},n,{queryKey:e,queryFn:t}):At({},t,{queryKey:e}):e}function a1e(e,t,n){return lp(e)?typeof t=="function"?At({},n,{mutationKey:e,mutationFn:t}):At({},t,{mutationKey:e}):typeof e=="function"?At({},t,{mutationFn:e}):At({},e)}function Jl(e,t,n){return lp(e)?[At({},t,{queryKey:e}),n]:[e||{},t]}function s1e(e,t){if(e===!0&&t===!0||e==null&&t==null)return"all";if(e===!1&&t===!1)return"none";var n=e??!t;return n?"active":"inactive"}function O6(e,t){var n=e.active,r=e.exact,o=e.fetching,i=e.inactive,a=e.predicate,s=e.queryKey,l=e.stale;if(lp(s)){if(r){if(t.queryHash!==ew(s,t.options))return!1}else if(!eb(t.queryKey,s))return!1}var u=s1e(n,i);if(u==="none")return!1;if(u!=="all"){var d=t.isActive();if(u==="active"&&!d||u==="inactive"&&d)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||typeof o=="boolean"&&t.isFetching()!==o||a&&!a(t))}function D6(e,t){var n=e.exact,r=e.fetching,o=e.predicate,i=e.mutationKey;if(lp(i)){if(!t.options.mutationKey)return!1;if(n){if(Sc(t.options.mutationKey)!==Sc(i))return!1}else if(!eb(t.options.mutationKey,i))return!1}return!(typeof r=="boolean"&&t.state.status==="loading"!==r||o&&!o(t))}function ew(e,t){var n=(t==null?void 0:t.queryKeyHashFn)||Sc;return n(e)}function Sc(e){var t=Jv(e);return l1e(t)}function l1e(e){return JSON.stringify(e,function(t,n){return L_(n)?Object.keys(n).sort().reduce(function(r,o){return r[o]=n[o],r},{}):n})}function eb(e,t){return xD(Jv(e),Jv(t))}function xD(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(function(n){return!xD(e[n],t[n])}):!1}function tb(e,t){if(e===t)return e;var n=Array.isArray(e)&&Array.isArray(t);if(n||L_(e)&&L_(t)){for(var r=n?e.length:Object.keys(e).length,o=n?t:Object.keys(t),i=o.length,a=n?[]:{},s=0,l=0;l<i;l++){var u=n?l:o[l];a[u]=tb(e[u],t[u]),a[u]===e[u]&&s++}return r===i&&s===r?e:a}return t}function u1e(e,t){if(e&&!t||t&&!e)return!1;for(var n in e)if(e[n]!==t[n])return!1;return!0}function L_(e){if(!P6(e))return!1;var t=e.constructor;if(typeof t>"u")return!0;var n=t.prototype;return!(!P6(n)||!n.hasOwnProperty("isPrototypeOf"))}function P6(e){return Object.prototype.toString.call(e)==="[object Object]"}function lp(e){return typeof e=="string"||Array.isArray(e)}function c1e(e){return new Promise(function(t){setTimeout(t,e)})}function M6(e){Promise.resolve().then(e).catch(function(t){return setTimeout(function(){throw t})})}function CD(){if(typeof AbortController=="function")return new AbortController}var f1e=function(e){l1(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(o){var i;if(!Zv&&((i=window)!=null&&i.addEventListener)){var a=function(){return o()};return window.addEventListener("visibilitychange",a,!1),window.addEventListener("focus",a,!1),function(){window.removeEventListener("visibilitychange",a),window.removeEventListener("focus",a)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var o;(o=this.cleanup)==null||o.call(this),this.cleanup=void 0}},n.setEventListener=function(o){var i,a=this;this.setup=o,(i=this.cleanup)==null||i.call(this),this.cleanup=o(function(s){typeof s=="boolean"?a.setFocused(s):a.onFocus()})},n.setFocused=function(o){this.focused=o,o&&this.onFocus()},n.onFocus=function(){this.listeners.forEach(function(o){o()})},n.isFocused=function(){return typeof this.focused=="boolean"?this.focused:typeof document>"u"?!0:[void 0,"visible","prerender"].includes(document.visibilityState)},t}(u1),Wh=new f1e,d1e=function(e){l1(t,e);function t(){var r;return r=e.call(this)||this,r.setup=function(o){var i;if(!Zv&&((i=window)!=null&&i.addEventListener)){var a=function(){return o()};return window.addEventListener("online",a,!1),window.addEventListener("offline",a,!1),function(){window.removeEventListener("online",a),window.removeEventListener("offline",a)}}},r}var n=t.prototype;return n.onSubscribe=function(){this.cleanup||this.setEventListener(this.setup)},n.onUnsubscribe=function(){if(!this.hasListeners()){var o;(o=this.cleanup)==null||o.call(this),this.cleanup=void 0}},n.setEventListener=function(o){var i,a=this;this.setup=o,(i=this.cleanup)==null||i.call(this),this.cleanup=o(function(s){typeof s=="boolean"?a.setOnline(s):a.onOnline()})},n.setOnline=function(o){this.online=o,o&&this.onOnline()},n.onOnline=function(){this.listeners.forEach(function(o){o()})},n.isOnline=function(){return typeof this.online=="boolean"?this.online:typeof navigator>"u"||typeof navigator.onLine>"u"?!0:navigator.onLine},t}(u1),Hg=new d1e;function h1e(e){return Math.min(1e3*Math.pow(2,e),3e4)}function nb(e){return typeof(e==null?void 0:e.cancel)=="function"}var AD=function(t){this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent};function Ug(e){return e instanceof AD}var ND=function(t){var n=this,r=!1,o,i,a,s;this.abort=t.abort,this.cancel=function(p){return o==null?void 0:o(p)},this.cancelRetry=function(){r=!0},this.continueRetry=function(){r=!1},this.continue=function(){return i==null?void 0:i()},this.failureCount=0,this.isPaused=!1,this.isResolved=!1,this.isTransportCancelable=!1,this.promise=new Promise(function(p,m){a=p,s=m});var l=function(m){n.isResolved||(n.isResolved=!0,t.onSuccess==null||t.onSuccess(m),i==null||i(),a(m))},u=function(m){n.isResolved||(n.isResolved=!0,t.onError==null||t.onError(m),i==null||i(),s(m))},d=function(){return new Promise(function(m){i=m,n.isPaused=!0,t.onPause==null||t.onPause()}).then(function(){i=void 0,n.isPaused=!1,t.onContinue==null||t.onContinue()})},h=function p(){if(!n.isResolved){var m;try{m=t.fn()}catch(v){m=Promise.reject(v)}o=function(_){if(!n.isResolved&&(u(new AD(_)),n.abort==null||n.abort(),nb(m)))try{m.cancel()}catch{}},n.isTransportCancelable=nb(m),Promise.resolve(m).then(l).catch(function(v){var _,b;if(!n.isResolved){var E=(_=t.retry)!=null?_:3,w=(b=t.retryDelay)!=null?b:h1e,k=typeof w=="function"?w(n.failureCount,v):w,y=E===!0||typeof E=="number"&&n.failureCount<E||typeof E=="function"&&E(n.failureCount,v);if(r||!y){u(v);return}n.failureCount++,t.onFail==null||t.onFail(n.failureCount,v),c1e(k).then(function(){if(!Wh.isFocused()||!Hg.isOnline())return d()}).then(function(){r?u(v):p()})}})}};h()},p1e=function(){function e(){this.queue=[],this.transactions=0,this.notifyFn=function(n){n()},this.batchNotifyFn=function(n){n()}}var t=e.prototype;return t.batch=function(r){var o;this.transactions++;try{o=r()}finally{this.transactions--,this.transactions||this.flush()}return o},t.schedule=function(r){var o=this;this.transactions?this.queue.push(r):M6(function(){o.notifyFn(r)})},t.batchCalls=function(r){var o=this;return function(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];o.schedule(function(){r.apply(void 0,a)})}},t.flush=function(){var r=this,o=this.queue;this.queue=[],o.length&&M6(function(){r.batchNotifyFn(function(){o.forEach(function(i){r.notifyFn(i)})})})},t.setNotifyFunction=function(r){this.notifyFn=r},t.setBatchNotifyFunction=function(r){this.batchNotifyFn=r},e}(),Dn=new p1e,FD=console;function rb(){return FD}function m1e(e){FD=e}var g1e=function(){function e(n){this.abortSignalConsumed=!1,this.hadObservers=!1,this.defaultOptions=n.defaultOptions,this.setOptions(n.options),this.observers=[],this.cache=n.cache,this.queryKey=n.queryKey,this.queryHash=n.queryHash,this.initialState=n.state||this.getDefaultState(this.options),this.state=this.initialState,this.meta=n.meta,this.scheduleGc()}var t=e.prototype;return t.setOptions=function(r){var o;this.options=At({},this.defaultOptions,r),this.meta=r==null?void 0:r.meta,this.cacheTime=Math.max(this.cacheTime||0,(o=this.options.cacheTime)!=null?o:5*60*1e3)},t.setDefaultOptions=function(r){this.defaultOptions=r},t.scheduleGc=function(){var r=this;this.clearGcTimeout(),M_(this.cacheTime)&&(this.gcTimeout=setTimeout(function(){r.optionalRemove()},this.cacheTime))},t.clearGcTimeout=function(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)},t.optionalRemove=function(){this.observers.length||(this.state.isFetching?this.hadObservers&&this.scheduleGc():this.cache.remove(this))},t.setData=function(r,o){var i,a,s=this.state.data,l=i1e(r,s);return(i=(a=this.options).isDataEqual)!=null&&i.call(a,s,l)?l=s:this.options.structuralSharing!==!1&&(l=tb(s,l)),this.dispatch({data:l,type:"success",dataUpdatedAt:o==null?void 0:o.updatedAt}),l},t.setState=function(r,o){this.dispatch({type:"setState",state:r,setStateOptions:o})},t.cancel=function(r){var o,i=this.promise;return(o=this.retryer)==null||o.cancel(r),i?i.then(Kr).catch(Kr):Promise.resolve()},t.destroy=function(){this.clearGcTimeout(),this.cancel({silent:!0})},t.reset=function(){this.destroy(),this.setState(this.initialState)},t.isActive=function(){return this.observers.some(function(r){return r.options.enabled!==!1})},t.isFetching=function(){return this.state.isFetching},t.isStale=function(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(function(r){return r.getCurrentResult().isStale})},t.isStaleByTime=function(r){return r===void 0&&(r=0),this.state.isInvalidated||!this.state.dataUpdatedAt||!SD(this.state.dataUpdatedAt,r)},t.onFocus=function(){var r,o=this.observers.find(function(i){return i.shouldFetchOnWindowFocus()});o&&o.refetch(),(r=this.retryer)==null||r.continue()},t.onOnline=function(){var r,o=this.observers.find(function(i){return i.shouldFetchOnReconnect()});o&&o.refetch(),(r=this.retryer)==null||r.continue()},t.addObserver=function(r){this.observers.indexOf(r)===-1&&(this.observers.push(r),this.hadObservers=!0,this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:r}))},t.removeObserver=function(r){this.observers.indexOf(r)!==-1&&(this.observers=this.observers.filter(function(o){return o!==r}),this.observers.length||(this.retryer&&(this.retryer.isTransportCancelable||this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.cacheTime?this.scheduleGc():this.cache.remove(this)),this.cache.notify({type:"observerRemoved",query:this,observer:r}))},t.getObserversCount=function(){return this.observers.length},t.invalidate=function(){this.state.isInvalidated||this.dispatch({type:"invalidate"})},t.fetch=function(r,o){var i=this,a,s,l;if(this.state.isFetching){if(this.state.dataUpdatedAt&&(o!=null&&o.cancelRefetch))this.cancel({silent:!0});else if(this.promise){var u;return(u=this.retryer)==null||u.continueRetry(),this.promise}}if(r&&this.setOptions(r),!this.options.queryFn){var d=this.observers.find(function(w){return w.options.queryFn});d&&this.setOptions(d.options)}var h=Jv(this.queryKey),p=CD(),m={queryKey:h,pageParam:void 0,meta:this.meta};Object.defineProperty(m,"signal",{enumerable:!0,get:function(){if(p)return i.abortSignalConsumed=!0,p.signal}});var v=function(){return i.options.queryFn?(i.abortSignalConsumed=!1,i.options.queryFn(m)):Promise.reject("Missing queryFn")},_={fetchOptions:o,options:this.options,queryKey:h,state:this.state,fetchFn:v,meta:this.meta};if((a=this.options.behavior)!=null&&a.onFetch){var b;(b=this.options.behavior)==null||b.onFetch(_)}if(this.revertState=this.state,!this.state.isFetching||this.state.fetchMeta!==((s=_.fetchOptions)==null?void 0:s.meta)){var E;this.dispatch({type:"fetch",meta:(E=_.fetchOptions)==null?void 0:E.meta})}return this.retryer=new ND({fn:_.fetchFn,abort:p==null||(l=p.abort)==null?void 0:l.bind(p),onSuccess:function(k){i.setData(k),i.cache.config.onSuccess==null||i.cache.config.onSuccess(k,i),i.cacheTime===0&&i.optionalRemove()},onError:function(k){Ug(k)&&k.silent||i.dispatch({type:"error",error:k}),Ug(k)||(i.cache.config.onError==null||i.cache.config.onError(k,i),rb().error(k)),i.cacheTime===0&&i.optionalRemove()},onFail:function(){i.dispatch({type:"failed"})},onPause:function(){i.dispatch({type:"pause"})},onContinue:function(){i.dispatch({type:"continue"})},retry:_.options.retry,retryDelay:_.options.retryDelay}),this.promise=this.retryer.promise,this.promise},t.dispatch=function(r){var o=this;this.state=this.reducer(this.state,r),Dn.batch(function(){o.observers.forEach(function(i){i.onQueryUpdate(r)}),o.cache.notify({query:o,type:"queryUpdated",action:r})})},t.getDefaultState=function(r){var o=typeof r.initialData=="function"?r.initialData():r.initialData,i=typeof r.initialData<"u",a=i?typeof r.initialDataUpdatedAt=="function"?r.initialDataUpdatedAt():r.initialDataUpdatedAt:0,s=typeof o<"u";return{data:o,dataUpdateCount:0,dataUpdatedAt:s?a??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchMeta:null,isFetching:!1,isInvalidated:!1,isPaused:!1,status:s?"success":"idle"}},t.reducer=function(r,o){var i,a;switch(o.type){case"failed":return At({},r,{fetchFailureCount:r.fetchFailureCount+1});case"pause":return At({},r,{isPaused:!0});case"continue":return At({},r,{isPaused:!1});case"fetch":return At({},r,{fetchFailureCount:0,fetchMeta:(i=o.meta)!=null?i:null,isFetching:!0,isPaused:!1},!r.dataUpdatedAt&&{error:null,status:"loading"});case"success":return At({},r,{data:o.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:(a=o.dataUpdatedAt)!=null?a:Date.now(),error:null,fetchFailureCount:0,isFetching:!1,isInvalidated:!1,isPaused:!1,status:"success"});case"error":var s=o.error;return Ug(s)&&s.revert&&this.revertState?At({},this.revertState):At({},r,{error:s,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,isFetching:!1,isPaused:!1,status:"error"});case"invalidate":return At({},r,{isInvalidated:!0});case"setState":return At({},r,o.state);default:return r}},e}(),ID=function(e){l1(t,e);function t(r){var o;return o=e.call(this)||this,o.config=r||{},o.queries=[],o.queriesMap={},o}var n=t.prototype;return n.build=function(o,i,a){var s,l=i.queryKey,u=(s=i.queryHash)!=null?s:ew(l,i),d=this.get(u);return d||(d=new g1e({cache:this,queryKey:l,queryHash:u,options:o.defaultQueryOptions(i),state:a,defaultOptions:o.getQueryDefaults(l),meta:i.meta}),this.add(d)),d},n.add=function(o){this.queriesMap[o.queryHash]||(this.queriesMap[o.queryHash]=o,this.queries.push(o),this.notify({type:"queryAdded",query:o}))},n.remove=function(o){var i=this.queriesMap[o.queryHash];i&&(o.destroy(),this.queries=this.queries.filter(function(a){return a!==o}),i===o&&delete this.queriesMap[o.queryHash],this.notify({type:"queryRemoved",query:o}))},n.clear=function(){var o=this;Dn.batch(function(){o.queries.forEach(function(i){o.remove(i)})})},n.get=function(o){return this.queriesMap[o]},n.getAll=function(){return this.queries},n.find=function(o,i){var a=Jl(o,i),s=a[0];return typeof s.exact>"u"&&(s.exact=!0),this.queries.find(function(l){return O6(s,l)})},n.findAll=function(o,i){var a=Jl(o,i),s=a[0];return Object.keys(s).length>0?this.queries.filter(function(l){return O6(s,l)}):this.queries},n.notify=function(o){var i=this;Dn.batch(function(){i.listeners.forEach(function(a){a(o)})})},n.onFocus=function(){var o=this;Dn.batch(function(){o.queries.forEach(function(i){i.onFocus()})})},n.onOnline=function(){var o=this;Dn.batch(function(){o.queries.forEach(function(i){i.onOnline()})})},t}(u1),v1e=function(){function e(n){this.options=At({},n.defaultOptions,n.options),this.mutationId=n.mutationId,this.mutationCache=n.mutationCache,this.observers=[],this.state=n.state||BD(),this.meta=n.meta}var t=e.prototype;return t.setState=function(r){this.dispatch({type:"setState",state:r})},t.addObserver=function(r){this.observers.indexOf(r)===-1&&this.observers.push(r)},t.removeObserver=function(r){this.observers=this.observers.filter(function(o){return o!==r})},t.cancel=function(){return this.retryer?(this.retryer.cancel(),this.retryer.promise.then(Kr).catch(Kr)):Promise.resolve()},t.continue=function(){return this.retryer?(this.retryer.continue(),this.retryer.promise):this.execute()},t.execute=function(){var r=this,o,i=this.state.status==="loading",a=Promise.resolve();return i||(this.dispatch({type:"loading",variables:this.options.variables}),a=a.then(function(){r.mutationCache.config.onMutate==null||r.mutationCache.config.onMutate(r.state.variables,r)}).then(function(){return r.options.onMutate==null?void 0:r.options.onMutate(r.state.variables)}).then(function(s){s!==r.state.context&&r.dispatch({type:"loading",context:s,variables:r.state.variables})})),a.then(function(){return r.executeMutation()}).then(function(s){o=s,r.mutationCache.config.onSuccess==null||r.mutationCache.config.onSuccess(o,r.state.variables,r.state.context,r)}).then(function(){return r.options.onSuccess==null?void 0:r.options.onSuccess(o,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(o,null,r.state.variables,r.state.context)}).then(function(){return r.dispatch({type:"success",data:o}),o}).catch(function(s){return r.mutationCache.config.onError==null||r.mutationCache.config.onError(s,r.state.variables,r.state.context,r),rb().error(s),Promise.resolve().then(function(){return r.options.onError==null?void 0:r.options.onError(s,r.state.variables,r.state.context)}).then(function(){return r.options.onSettled==null?void 0:r.options.onSettled(void 0,s,r.state.variables,r.state.context)}).then(function(){throw r.dispatch({type:"error",error:s}),s})})},t.executeMutation=function(){var r=this,o;return this.retryer=new ND({fn:function(){return r.options.mutationFn?r.options.mutationFn(r.state.variables):Promise.reject("No mutationFn found")},onFail:function(){r.dispatch({type:"failed"})},onPause:function(){r.dispatch({type:"pause"})},onContinue:function(){r.dispatch({type:"continue"})},retry:(o=this.options.retry)!=null?o:0,retryDelay:this.options.retryDelay}),this.retryer.promise},t.dispatch=function(r){var o=this;this.state=b1e(this.state,r),Dn.batch(function(){o.observers.forEach(function(i){i.onMutationUpdate(r)}),o.mutationCache.notify(o)})},e}();function BD(){return{context:void 0,data:void 0,error:null,failureCount:0,isPaused:!1,status:"idle",variables:void 0}}function b1e(e,t){switch(t.type){case"failed":return At({},e,{failureCount:e.failureCount+1});case"pause":return At({},e,{isPaused:!0});case"continue":return At({},e,{isPaused:!1});case"loading":return At({},e,{context:t.context,data:void 0,error:null,isPaused:!1,status:"loading",variables:t.variables});case"success":return At({},e,{data:t.data,error:null,status:"success",isPaused:!1});case"error":return At({},e,{data:void 0,error:t.error,failureCount:e.failureCount+1,isPaused:!1,status:"error"});case"setState":return At({},e,t.state);default:return e}}var y1e=function(e){l1(t,e);function t(r){var o;return o=e.call(this)||this,o.config=r||{},o.mutations=[],o.mutationId=0,o}var n=t.prototype;return n.build=function(o,i,a){var s=new v1e({mutationCache:this,mutationId:++this.mutationId,options:o.defaultMutationOptions(i),state:a,defaultOptions:i.mutationKey?o.getMutationDefaults(i.mutationKey):void 0,meta:i.meta});return this.add(s),s},n.add=function(o){this.mutations.push(o),this.notify(o)},n.remove=function(o){this.mutations=this.mutations.filter(function(i){return i!==o}),o.cancel(),this.notify(o)},n.clear=function(){var o=this;Dn.batch(function(){o.mutations.forEach(function(i){o.remove(i)})})},n.getAll=function(){return this.mutations},n.find=function(o){return typeof o.exact>"u"&&(o.exact=!0),this.mutations.find(function(i){return D6(o,i)})},n.findAll=function(o){return this.mutations.filter(function(i){return D6(o,i)})},n.notify=function(o){var i=this;Dn.batch(function(){i.listeners.forEach(function(a){a(o)})})},n.onFocus=function(){this.resumePausedMutations()},n.onOnline=function(){this.resumePausedMutations()},n.resumePausedMutations=function(){var o=this.mutations.filter(function(i){return i.state.isPaused});return Dn.batch(function(){return o.reduce(function(i,a){return i.then(function(){return a.continue().catch(Kr)})},Promise.resolve())})},t}(u1);function E1e(){return{onFetch:function(t){t.fetchFn=function(){var n,r,o,i,a,s,l=(n=t.fetchOptions)==null||(r=n.meta)==null?void 0:r.refetchPage,u=(o=t.fetchOptions)==null||(i=o.meta)==null?void 0:i.fetchMore,d=u==null?void 0:u.pageParam,h=(u==null?void 0:u.direction)==="forward",p=(u==null?void 0:u.direction)==="backward",m=((a=t.state.data)==null?void 0:a.pages)||[],v=((s=t.state.data)==null?void 0:s.pageParams)||[],_=CD(),b=_==null?void 0:_.signal,E=v,w=!1,k=t.options.queryFn||function(){return Promise.reject("Missing queryFn")},y=function(pe,se,J,$){return E=$?[se].concat(E):[].concat(E,[se]),$?[J].concat(pe):[].concat(pe,[J])},F=function(pe,se,J,$){if(w)return Promise.reject("Cancelled");if(typeof J>"u"&&!se&&pe.length)return Promise.resolve(pe);var _e={queryKey:t.queryKey,signal:b,pageParam:J,meta:t.meta},ve=k(_e),fe=Promise.resolve(ve).then(function(L){return y(pe,J,L,$)});if(nb(ve)){var R=fe;R.cancel=ve.cancel}return fe},C;if(!m.length)C=F([]);else if(h){var A=typeof d<"u",P=A?d:L6(t.options,m);C=F(m,A,P)}else if(p){var I=typeof d<"u",j=I?d:_1e(t.options,m);C=F(m,I,j,!0)}else(function(){E=[];var U=typeof t.options.getNextPageParam>"u",pe=l&&m[0]?l(m[0],0,m):!0;C=pe?F([],U,v[0]):Promise.resolve(y([],v[0],m[0]));for(var se=function(_e){C=C.then(function(ve){var fe=l&&m[_e]?l(m[_e],_e,m):!0;if(fe){var R=U?v[_e]:L6(t.options,ve);return F(ve,U,R)}return Promise.resolve(y(ve,v[_e],m[_e]))})},J=1;J<m.length;J++)se(J)})();var H=C.then(function(U){return{pages:U,pageParams:E}}),K=H;return K.cancel=function(){w=!0,_==null||_.abort(),nb(C)&&C.cancel()},H}}}}function L6(e,t){return e.getNextPageParam==null?void 0:e.getNextPageParam(t[t.length-1],t)}function _1e(e,t){return e.getPreviousPageParam==null?void 0:e.getPreviousPageParam(t[0],t)}var T1e=function(){function e(n){n===void 0&&(n={}),this.queryCache=n.queryCache||new ID,this.mutationCache=n.mutationCache||new y1e,this.defaultOptions=n.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[]}var t=e.prototype;return t.mount=function(){var r=this;this.unsubscribeFocus=Wh.subscribe(function(){Wh.isFocused()&&Hg.isOnline()&&(r.mutationCache.onFocus(),r.queryCache.onFocus())}),this.unsubscribeOnline=Hg.subscribe(function(){Wh.isFocused()&&Hg.isOnline()&&(r.mutationCache.onOnline(),r.queryCache.onOnline())})},t.unmount=function(){var r,o;(r=this.unsubscribeFocus)==null||r.call(this),(o=this.unsubscribeOnline)==null||o.call(this)},t.isFetching=function(r,o){var i=Jl(r,o),a=i[0];return a.fetching=!0,this.queryCache.findAll(a).length},t.isMutating=function(r){return this.mutationCache.findAll(At({},r,{fetching:!0})).length},t.getQueryData=function(r,o){var i;return(i=this.queryCache.find(r,o))==null?void 0:i.state.data},t.getQueriesData=function(r){return this.getQueryCache().findAll(r).map(function(o){var i=o.queryKey,a=o.state,s=a.data;return[i,s]})},t.setQueryData=function(r,o,i){var a=zg(r),s=this.defaultQueryOptions(a);return this.queryCache.build(this,s).setData(o,i)},t.setQueriesData=function(r,o,i){var a=this;return Dn.batch(function(){return a.getQueryCache().findAll(r).map(function(s){var l=s.queryKey;return[l,a.setQueryData(l,o,i)]})})},t.getQueryState=function(r,o){var i;return(i=this.queryCache.find(r,o))==null?void 0:i.state},t.removeQueries=function(r,o){var i=Jl(r,o),a=i[0],s=this.queryCache;Dn.batch(function(){s.findAll(a).forEach(function(l){s.remove(l)})})},t.resetQueries=function(r,o,i){var a=this,s=Jl(r,o,i),l=s[0],u=s[1],d=this.queryCache,h=At({},l,{active:!0});return Dn.batch(function(){return d.findAll(l).forEach(function(p){p.reset()}),a.refetchQueries(h,u)})},t.cancelQueries=function(r,o,i){var a=this,s=Jl(r,o,i),l=s[0],u=s[1],d=u===void 0?{}:u;typeof d.revert>"u"&&(d.revert=!0);var h=Dn.batch(function(){return a.queryCache.findAll(l).map(function(p){return p.cancel(d)})});return Promise.all(h).then(Kr).catch(Kr)},t.invalidateQueries=function(r,o,i){var a,s,l,u=this,d=Jl(r,o,i),h=d[0],p=d[1],m=At({},h,{active:(a=(s=h.refetchActive)!=null?s:h.active)!=null?a:!0,inactive:(l=h.refetchInactive)!=null?l:!1});return Dn.batch(function(){return u.queryCache.findAll(h).forEach(function(v){v.invalidate()}),u.refetchQueries(m,p)})},t.refetchQueries=function(r,o,i){var a=this,s=Jl(r,o,i),l=s[0],u=s[1],d=Dn.batch(function(){return a.queryCache.findAll(l).map(function(p){return p.fetch(void 0,At({},u,{meta:{refetchPage:l==null?void 0:l.refetchPage}}))})}),h=Promise.all(d).then(Kr);return u!=null&&u.throwOnError||(h=h.catch(Kr)),h},t.fetchQuery=function(r,o,i){var a=zg(r,o,i),s=this.defaultQueryOptions(a);typeof s.retry>"u"&&(s.retry=!1);var l=this.queryCache.build(this,s);return l.isStaleByTime(s.staleTime)?l.fetch(s):Promise.resolve(l.state.data)},t.prefetchQuery=function(r,o,i){return this.fetchQuery(r,o,i).then(Kr).catch(Kr)},t.fetchInfiniteQuery=function(r,o,i){var a=zg(r,o,i);return a.behavior=E1e(),this.fetchQuery(a)},t.prefetchInfiniteQuery=function(r,o,i){return this.fetchInfiniteQuery(r,o,i).then(Kr).catch(Kr)},t.cancelMutations=function(){var r=this,o=Dn.batch(function(){return r.mutationCache.getAll().map(function(i){return i.cancel()})});return Promise.all(o).then(Kr).catch(Kr)},t.resumePausedMutations=function(){return this.getMutationCache().resumePausedMutations()},t.executeMutation=function(r){return this.mutationCache.build(this,r).execute()},t.getQueryCache=function(){return this.queryCache},t.getMutationCache=function(){return this.mutationCache},t.getDefaultOptions=function(){return this.defaultOptions},t.setDefaultOptions=function(r){this.defaultOptions=r},t.setQueryDefaults=function(r,o){var i=this.queryDefaults.find(function(a){return Sc(r)===Sc(a.queryKey)});i?i.defaultOptions=o:this.queryDefaults.push({queryKey:r,defaultOptions:o})},t.getQueryDefaults=function(r){var o;return r?(o=this.queryDefaults.find(function(i){return eb(r,i.queryKey)}))==null?void 0:o.defaultOptions:void 0},t.setMutationDefaults=function(r,o){var i=this.mutationDefaults.find(function(a){return Sc(r)===Sc(a.mutationKey)});i?i.defaultOptions=o:this.mutationDefaults.push({mutationKey:r,defaultOptions:o})},t.getMutationDefaults=function(r){var o;return r?(o=this.mutationDefaults.find(function(i){return eb(r,i.mutationKey)}))==null?void 0:o.defaultOptions:void 0},t.defaultQueryOptions=function(r){if(r!=null&&r._defaulted)return r;var o=At({},this.defaultOptions.queries,this.getQueryDefaults(r==null?void 0:r.queryKey),r,{_defaulted:!0});return!o.queryHash&&o.queryKey&&(o.queryHash=ew(o.queryKey,o)),o},t.defaultQueryObserverOptions=function(r){return this.defaultQueryOptions(r)},t.defaultMutationOptions=function(r){return r!=null&&r._defaulted?r:At({},this.defaultOptions.mutations,this.getMutationDefaults(r==null?void 0:r.mutationKey),r,{_defaulted:!0})},t.clear=function(){this.queryCache.clear(),this.mutationCache.clear()},e}(),w1e=function(e){l1(t,e);function t(r,o){var i;return i=e.call(this)||this,i.client=r,i.options=o,i.trackedProps=[],i.selectError=null,i.bindMethods(),i.setOptions(o),i}var n=t.prototype;return n.bindMethods=function(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)},n.onSubscribe=function(){this.listeners.length===1&&(this.currentQuery.addObserver(this),j6(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())},n.onUnsubscribe=function(){this.listeners.length||this.destroy()},n.shouldFetchOnReconnect=function(){return j_(this.currentQuery,this.options,this.options.refetchOnReconnect)},n.shouldFetchOnWindowFocus=function(){return j_(this.currentQuery,this.options,this.options.refetchOnWindowFocus)},n.destroy=function(){this.listeners=[],this.clearTimers(),this.currentQuery.removeObserver(this)},n.setOptions=function(o,i){var a=this.options,s=this.currentQuery;if(this.options=this.client.defaultQueryObserverOptions(o),typeof this.options.enabled<"u"&&typeof this.options.enabled!="boolean")throw new Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=a.queryKey),this.updateQuery();var l=this.hasListeners();l&&z6(this.currentQuery,s,this.options,a)&&this.executeFetch(),this.updateResult(i),l&&(this.currentQuery!==s||this.options.enabled!==a.enabled||this.options.staleTime!==a.staleTime)&&this.updateStaleTimeout();var u=this.computeRefetchInterval();l&&(this.currentQuery!==s||this.options.enabled!==a.enabled||u!==this.currentRefetchInterval)&&this.updateRefetchInterval(u)},n.getOptimisticResult=function(o){var i=this.client.defaultQueryObserverOptions(o),a=this.client.getQueryCache().build(this.client,i);return this.createResult(a,i)},n.getCurrentResult=function(){return this.currentResult},n.trackResult=function(o,i){var a=this,s={},l=function(d){a.trackedProps.includes(d)||a.trackedProps.push(d)};return Object.keys(o).forEach(function(u){Object.defineProperty(s,u,{configurable:!1,enumerable:!0,get:function(){return l(u),o[u]}})}),(i.useErrorBoundary||i.suspense)&&l("error"),s},n.getNextResult=function(o){var i=this;return new Promise(function(a,s){var l=i.subscribe(function(u){u.isFetching||(l(),u.isError&&(o!=null&&o.throwOnError)?s(u.error):a(u))})})},n.getCurrentQuery=function(){return this.currentQuery},n.remove=function(){this.client.getQueryCache().remove(this.currentQuery)},n.refetch=function(o){return this.fetch(At({},o,{meta:{refetchPage:o==null?void 0:o.refetchPage}}))},n.fetchOptimistic=function(o){var i=this,a=this.client.defaultQueryObserverOptions(o),s=this.client.getQueryCache().build(this.client,a);return s.fetch().then(function(){return i.createResult(s,a)})},n.fetch=function(o){var i=this;return this.executeFetch(o).then(function(){return i.updateResult(),i.currentResult})},n.executeFetch=function(o){this.updateQuery();var i=this.currentQuery.fetch(this.options,o);return o!=null&&o.throwOnError||(i=i.catch(Kr)),i},n.updateStaleTimeout=function(){var o=this;if(this.clearStaleTimeout(),!(Zv||this.currentResult.isStale||!M_(this.options.staleTime))){var i=SD(this.currentResult.dataUpdatedAt,this.options.staleTime),a=i+1;this.staleTimeoutId=setTimeout(function(){o.currentResult.isStale||o.updateResult()},a)}},n.computeRefetchInterval=function(){var o;return typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.currentResult.data,this.currentQuery):(o=this.options.refetchInterval)!=null?o:!1},n.updateRefetchInterval=function(o){var i=this;this.clearRefetchInterval(),this.currentRefetchInterval=o,!(Zv||this.options.enabled===!1||!M_(this.currentRefetchInterval)||this.currentRefetchInterval===0)&&(this.refetchIntervalId=setInterval(function(){(i.options.refetchIntervalInBackground||Wh.isFocused())&&i.executeFetch()},this.currentRefetchInterval))},n.updateTimers=function(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())},n.clearTimers=function(){this.clearStaleTimeout(),this.clearRefetchInterval()},n.clearStaleTimeout=function(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)},n.clearRefetchInterval=function(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)},n.createResult=function(o,i){var a=this.currentQuery,s=this.options,l=this.currentResult,u=this.currentResultState,d=this.currentResultOptions,h=o!==a,p=h?o.state:this.currentQueryInitialState,m=h?this.currentResult:this.previousQueryResult,v=o.state,_=v.dataUpdatedAt,b=v.error,E=v.errorUpdatedAt,w=v.isFetching,k=v.status,y=!1,F=!1,C;if(i.optimisticResults){var A=this.hasListeners(),P=!A&&j6(o,i),I=A&&z6(o,a,i,s);(P||I)&&(w=!0,_||(k="loading"))}if(i.keepPreviousData&&!v.dataUpdateCount&&(m!=null&&m.isSuccess)&&k!=="error")C=m.data,_=m.dataUpdatedAt,k=m.status,y=!0;else if(i.select&&typeof v.data<"u")if(l&&v.data===(u==null?void 0:u.data)&&i.select===this.selectFn)C=this.selectResult;else try{this.selectFn=i.select,C=i.select(v.data),i.structuralSharing!==!1&&(C=tb(l==null?void 0:l.data,C)),this.selectResult=C,this.selectError=null}catch(K){rb().error(K),this.selectError=K}else C=v.data;if(typeof i.placeholderData<"u"&&typeof C>"u"&&(k==="loading"||k==="idle")){var j;if(l!=null&&l.isPlaceholderData&&i.placeholderData===(d==null?void 0:d.placeholderData))j=l.data;else if(j=typeof i.placeholderData=="function"?i.placeholderData():i.placeholderData,i.select&&typeof j<"u")try{j=i.select(j),i.structuralSharing!==!1&&(j=tb(l==null?void 0:l.data,j)),this.selectError=null}catch(K){rb().error(K),this.selectError=K}typeof j<"u"&&(k="success",C=j,F=!0)}this.selectError&&(b=this.selectError,C=this.selectResult,E=Date.now(),k="error");var H={status:k,isLoading:k==="loading",isSuccess:k==="success",isError:k==="error",isIdle:k==="idle",data:C,dataUpdatedAt:_,error:b,errorUpdatedAt:E,failureCount:v.fetchFailureCount,errorUpdateCount:v.errorUpdateCount,isFetched:v.dataUpdateCount>0||v.errorUpdateCount>0,isFetchedAfterMount:v.dataUpdateCount>p.dataUpdateCount||v.errorUpdateCount>p.errorUpdateCount,isFetching:w,isRefetching:w&&k!=="loading",isLoadingError:k==="error"&&v.dataUpdatedAt===0,isPlaceholderData:F,isPreviousData:y,isRefetchError:k==="error"&&v.dataUpdatedAt!==0,isStale:tw(o,i),refetch:this.refetch,remove:this.remove};return H},n.shouldNotifyListeners=function(o,i){if(!i)return!0;var a=this.options,s=a.notifyOnChangeProps,l=a.notifyOnChangePropsExclusions;if(!s&&!l||s==="tracked"&&!this.trackedProps.length)return!0;var u=s==="tracked"?this.trackedProps:s;return Object.keys(o).some(function(d){var h=d,p=o[h]!==i[h],m=u==null?void 0:u.some(function(_){return _===d}),v=l==null?void 0:l.some(function(_){return _===d});return p&&!v&&(!u||m)})},n.updateResult=function(o){var i=this.currentResult;if(this.currentResult=this.createResult(this.currentQuery,this.options),this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,!u1e(this.currentResult,i)){var a={cache:!0};(o==null?void 0:o.listeners)!==!1&&this.shouldNotifyListeners(this.currentResult,i)&&(a.listeners=!0),this.notify(At({},a,o))}},n.updateQuery=function(){var o=this.client.getQueryCache().build(this.client,this.options);if(o!==this.currentQuery){var i=this.currentQuery;this.currentQuery=o,this.currentQueryInitialState=o.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(i==null||i.removeObserver(this),o.addObserver(this))}},n.onQueryUpdate=function(o){var i={};o.type==="success"?i.onSuccess=!0:o.type==="error"&&!Ug(o.error)&&(i.onError=!0),this.updateResult(i),this.hasListeners()&&this.updateTimers()},n.notify=function(o){var i=this;Dn.batch(function(){o.onSuccess?(i.options.onSuccess==null||i.options.onSuccess(i.currentResult.data),i.options.onSettled==null||i.options.onSettled(i.currentResult.data,null)):o.onError&&(i.options.onError==null||i.options.onError(i.currentResult.error),i.options.onSettled==null||i.options.onSettled(void 0,i.currentResult.error)),o.listeners&&i.listeners.forEach(function(a){a(i.currentResult)}),o.cache&&i.client.getQueryCache().notify({query:i.currentQuery,type:"observerResultsUpdated"})})},t}(u1);function k1e(e,t){return t.enabled!==!1&&!e.state.dataUpdatedAt&&!(e.state.status==="error"&&t.retryOnMount===!1)}function j6(e,t){return k1e(e,t)||e.state.dataUpdatedAt>0&&j_(e,t,t.refetchOnMount)}function j_(e,t,n){if(t.enabled!==!1){var r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&tw(e,t)}return!1}function z6(e,t,n,r){return n.enabled!==!1&&(e!==t||r.enabled===!1)&&(!n.suspense||e.state.status!=="error")&&tw(e,n)}function tw(e,t){return e.isStaleByTime(t.staleTime)}var S1e=function(e){l1(t,e);function t(r,o){var i;return i=e.call(this)||this,i.client=r,i.setOptions(o),i.bindMethods(),i.updateResult(),i}var n=t.prototype;return n.bindMethods=function(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)},n.setOptions=function(o){this.options=this.client.defaultMutationOptions(o)},n.onUnsubscribe=function(){if(!this.listeners.length){var o;(o=this.currentMutation)==null||o.removeObserver(this)}},n.onMutationUpdate=function(o){this.updateResult();var i={listeners:!0};o.type==="success"?i.onSuccess=!0:o.type==="error"&&(i.onError=!0),this.notify(i)},n.getCurrentResult=function(){return this.currentResult},n.reset=function(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})},n.mutate=function(o,i){return this.mutateOptions=i,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,At({},this.options,{variables:typeof o<"u"?o:this.options.variables})),this.currentMutation.addObserver(this),this.currentMutation.execute()},n.updateResult=function(){var o=this.currentMutation?this.currentMutation.state:BD(),i=At({},o,{isLoading:o.status==="loading",isSuccess:o.status==="success",isError:o.status==="error",isIdle:o.status==="idle",mutate:this.mutate,reset:this.reset});this.currentResult=i},n.notify=function(o){var i=this;Dn.batch(function(){i.mutateOptions&&(o.onSuccess?(i.mutateOptions.onSuccess==null||i.mutateOptions.onSuccess(i.currentResult.data,i.currentResult.variables,i.currentResult.context),i.mutateOptions.onSettled==null||i.mutateOptions.onSettled(i.currentResult.data,null,i.currentResult.variables,i.currentResult.context)):o.onError&&(i.mutateOptions.onError==null||i.mutateOptions.onError(i.currentResult.error,i.currentResult.variables,i.currentResult.context),i.mutateOptions.onSettled==null||i.mutateOptions.onSettled(void 0,i.currentResult.error,i.currentResult.variables,i.currentResult.context))),o.listeners&&i.listeners.forEach(function(a){a(i.currentResult)})})},t}(u1),x1e=LB.unstable_batchedUpdates;Dn.setBatchNotifyFunction(x1e);var C1e=console;m1e(C1e);var H6=Bt.createContext(void 0),RD=Bt.createContext(!1);function OD(e){return e&&typeof window<"u"?(window.ReactQueryClientContext||(window.ReactQueryClientContext=H6),window.ReactQueryClientContext):H6}var DD=function(){var t=Bt.useContext(OD(Bt.useContext(RD)));if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},A1e=function(t){var n=t.client,r=t.contextSharing,o=r===void 0?!1:r,i=t.children;Bt.useEffect(function(){return n.mount(),function(){n.unmount()}},[n]);var a=OD(o);return Bt.createElement(RD.Provider,{value:o},Bt.createElement(a.Provider,{value:n},i))};function N1e(){var e=!1;return{clearReset:function(){e=!1},reset:function(){e=!0},isReset:function(){return e}}}var F1e=Bt.createContext(N1e()),I1e=function(){return Bt.useContext(F1e)};function PD(e,t,n){return typeof t=="function"?t.apply(void 0,n):typeof t=="boolean"?t:!!e}function B1e(e,t,n){var r=Bt.useRef(!1),o=Bt.useState(0),i=o[1],a=a1e(e,t,n),s=DD(),l=Bt.useRef();l.current?l.current.setOptions(a):l.current=new S1e(s,a);var u=l.current.getCurrentResult();Bt.useEffect(function(){r.current=!0;var h=l.current.subscribe(Dn.batchCalls(function(){r.current&&i(function(p){return p+1})}));return function(){r.current=!1,h()}},[]);var d=Bt.useCallback(function(h,p){l.current.mutate(h,p).catch(Kr)},[]);if(u.error&&PD(void 0,l.current.options.useErrorBoundary,[u.error]))throw u.error;return At({},u,{mutate:d,mutateAsync:u.mutate})}function R1e(e,t){var n=Bt.useRef(!1),r=Bt.useState(0),o=r[1],i=DD(),a=I1e(),s=i.defaultQueryObserverOptions(e);s.optimisticResults=!0,s.onError&&(s.onError=Dn.batchCalls(s.onError)),s.onSuccess&&(s.onSuccess=Dn.batchCalls(s.onSuccess)),s.onSettled&&(s.onSettled=Dn.batchCalls(s.onSettled)),s.suspense&&(typeof s.staleTime!="number"&&(s.staleTime=1e3),s.cacheTime===0&&(s.cacheTime=1)),(s.suspense||s.useErrorBoundary)&&(a.isReset()||(s.retryOnMount=!1));var l=Bt.useState(function(){return new t(i,s)}),u=l[0],d=u.getOptimisticResult(s);if(Bt.useEffect(function(){n.current=!0,a.clearReset();var h=u.subscribe(Dn.batchCalls(function(){n.current&&o(function(p){return p+1})}));return u.updateResult(),function(){n.current=!1,h()}},[a,u]),Bt.useEffect(function(){u.setOptions(s,{listeners:!1})},[s,u]),s.suspense&&d.isLoading)throw u.fetchOptimistic(s).then(function(h){var p=h.data;s.onSuccess==null||s.onSuccess(p),s.onSettled==null||s.onSettled(p,null)}).catch(function(h){a.clearReset(),s.onError==null||s.onError(h),s.onSettled==null||s.onSettled(void 0,h)});if(d.isError&&!a.isReset()&&!d.isFetching&&PD(s.suspense,s.useErrorBoundary,[d.error,u.getCurrentQuery()]))throw d.error;return s.notifyOnChangeProps==="tracked"&&(d=u.trackResult(d,s)),d}function O1e(e,t,n){var r=zg(e,t,n);return R1e(r,w1e)}const D1e=new ID,P1e=new T1e({queryCache:D1e,defaultOptions:{queries:{enabled:!0,retry:0,staleTime:0,cacheTime:15*60*1e3,refetchOnWindowFocus:!1,refetchOnMount:!0,suspense:!0}}});function U6(e){const t=T.useRef(e);return T.useLayoutEffect(()=>{t.current=e}),T.useCallback((...n)=>{const r=t.current;return r(...n)},[])}var wr=(e=>(e.System="system",e.ErrorHandler="error",e.Chatbot="chatbot",e.User="user",e))(wr||{}),MD=(e=>(e.Text="text",e.Typing="typing",e.SessionSplit="session-split",e))(MD||{});const Ou=OT({chatBox:{...mt.borderRadius("8px"),display:"flex",flexDirection:"column",alignItems:"stretch",backgroundColor:nn.colorNeutralBackground1,width:"100%",height:"100%",boxShadow:"0px 6.4px 14.4px rgba(0, 0, 0, 0.132), 0px 1.2px 3.6px rgba(0, 0, 0, 0.108)","::-webkit-scrollbar":{width:"4px",backgroundColor:nn.colorNeutralBackground1Hover},"::-webkit-scrollbar-thumb":{backgroundColor:nn.colorScrollbarOverlay,...mt.border("1px","solid",nn.colorNeutralBackground1),...mt.borderRadius("9999px")},"::-webkit-scrollbar-thumb:hover":{backgroundColor:nn.colorNeutralForeground1Static},"::-webkit-scrollbar-track":{...mt.borderRadius("9999px"),backgroundColor:"transparent"}},chatBoxHeader:{...mt.flex(0,0,"auto")},chatBoxMain:{...mt.flex(1,1,"auto"),...mt.padding("0","16px"),...mt.overflow("hidden","auto")},chatBoxFooter:{...mt.flex(0,0,"auto"),...mt.padding("16px")},toolbar:{...mt.padding("0px","16px"),...mt.borderBottom("1px","solid",nn.colorNeutralBackground5),boxSizing:"border-box",display:"flex",justifyContent:"space-between",alignItems:"center",height:"48px"},toolbarTitle:{display:"flex",alignItems:"center",columnGap:"2px"},toolbarActions:{display:"flex",alignItems:"center",columnGap:"6px"},toolbarActionButton:{color:nn.colorNeutralForeground2},inputBoxPastMessagesIncluded:{width:"56px"},messages:{},message:{...mt.margin("16px","0"),display:"flex",alignItems:"flex-end",[`&[data-from="${wr.User}"]`]:{flexDirection:"row-reverse"},"& pre > code":{display:"block"}},messageInContextTitle:{display:"flex",alignItems:"center",columnGap:"4px",fontSize:"12px"},messageInContextIndicatorWrapper:{...mt.borderRadius("50%"),height:"6px",width:"6px"},messageInContextIndicator:{backgroundColor:nn.colorPaletteGreenBackground3},messageOutOfContextIndicator:{backgroundColor:nn.colorPaletteYellowBackground3},messageContent:{...mt.padding("16px","16px"),...mt.borderRadius("4px"),boxSizing:"border-box",width:"calc(100% - 80px)",wordBreak:"break-word",lineHeight:"22px","> p":{...mt.margin(0)},[`&[data-from="${wr.Chatbot}"]`]:{backgroundColor:nn.colorNeutralBackground4,color:nn.colorNeutralForeground1},[`&[data-from="${wr.User}"]`]:{backgroundColor:nn.colorBrandBackgroundStatic,color:nn.colorNeutralForegroundOnBrand},[`&[data-from="${wr.ErrorHandler}"]`]:{backgroundColor:nn.colorPaletteRedBackground2,color:nn.colorNeutralForeground1},[`&[data-from="${wr.System}"]`]:{display:"flex",justifyContent:"center",width:"100%",color:nn.colorNeutralForeground4},[`&[data-from="${wr.User}"] a`]:{backgroundColor:nn.colorBrandBackground,color:nn.colorNeutralForegroundOnBrand}},errorMessageDetail:{marginTop:"8px !important",paddingTop:"8px",wordBreak:"break-word",whiteSpace:"break-spaces",...mt.borderTop("1px","solid",nn.colorPaletteDarkRedBorderActive)},messageStatus:{...mt.margin("10px","0","0","0"),...mt.borderTop("1px","solid",nn.colorPaletteAnchorBackground2),fontSize:"12px",fontStyle:"italic"},inputBoxLayout:{display:"flex",alignItems:"center",columnGap:"8px"},inputBoxClearBtn:{height:"32px",width:"32px"},inputBox:{...mt.padding("8px","0px","8px","8px"),...mt.border("1px","solid",nn.colorNeutralBackground5),...mt.borderRadius("4px"),boxSizing:"border-box",display:"block",width:"100%",userSelect:"none",position:"relative",['&[data-disabled="true"]']:{backgroundColor:nn.colorNeutralBackgroundDisabled}},inputBoxTextarea:{...mt.padding("0px","28px","0px","0px"),...mt.overflow("hidden","auto"),...mt.borderWidth(0),...mt.outline(0,"solid","transparent"),backgroundColor:"transparent",boxSizing:"border-box",resize:"none",appearance:"none",overflowWrap:"break-word",lineHeight:"24px",height:"24px",maxHeight:"72px",width:"100%",color:nn.colorNeutralForeground1,userSelect:"text"},inputBoxSendBtnWrapper:{position:"absolute",right:"0px",bottom:"0px",["&& button[disabled]"]:{color:nn.colorNeutralForegroundDisabled}},inputBoxSendBtn:{color:nn.colorNeutralForeground2},inputCountExceeded:{color:nn.colorPaletteRedForeground1},infoIcon:{...mt.margin("0px","0px","0px","4px"),cursor:"default",userSelect:"none",fontSize:"16px"},dismissIconButton:{...mt.margin("0px","0px","0px","4px"),cursor:"pointer",userSelect:"none",fontSize:"16px"},bottomTip:{...mt.border("1px","solid",nn.colorNeutralBackground5),...mt.padding("10px","6px"),...mt.borderRadius("4px"),...mt.margin("0px","0px","2px","0px"),display:"flex",alignItems:"flex-start",boxSizing:"border-box",width:"100%",backgroundColor:nn.colorNeutralBackground3,"> :first-child":{...mt.flex(0,0,"auto"),...mt.padding("0px","8px","0px","0px")},"> div":{...mt.flex(1,1,"auto")},"> :last-child":{...mt.flex(0,0,"auto"),...mt.padding("0px","0px","0px","8px")}}}),M1e=({isBottomTipVisible:e,LocStrings:t,onBottomTipVisibleChange:n})=>{const r=Ou(),o=T.useCallback(()=>{n(!1)},[]);return e?Q.jsxs("div",{className:r.bottomTip,children:[Q.jsx(sl,{className:r.infoIcon,iconName:"InfoSolid"}),Q.jsx("div",{children:t.Tooltip_Bottom}),Q.jsx(sl,{className:r.dismissIconButton,iconName:"Cancel",onClick:o})]}):Q.jsx(Q.Fragment,{})},L1e=e=>{const[t,n]=T.useState(e.initialTypingMessage??""),r=Ou(),o=T.useRef(null),i=U6(()=>{n(""),e.onSendMessage(t)}),a=U6(u=>{u.key==="Enter"&&!u.shiftKey&&!u.ctrlKey&&(u.preventDefault(),i())});T.useEffect(()=>{let u;return e.isChatbotTyping||(u!==void 0&&clearTimeout(u),u=setTimeout(()=>{var d;return(d=o.current)==null?void 0:d.focus()},100)),()=>{u!==void 0&&clearTimeout(u)}},[e.isChatbotTyping]),T.useEffect(()=>{const u=o.current;if(u){const d=()=>{const h=u.scrollHeight;h>0&&(u.style.height=`${h}px`)};return u.addEventListener("input",d),()=>{u.removeEventListener("input",d)}}},[]);const s=/\S/.test(t),l=e.isChatbotTyping||!s;return Q.jsxs(Q.Fragment,{children:[Q.jsx(M1e,{isBottomTipVisible:e.isBottomTipVisible,LocStrings:e.LocStrings,onBottomTipVisibleChange:e.onBottomTipVisibleChange}),Q.jsxs("div",{className:r.inputBoxLayout,children:[Q.jsx(cl,{relationship:"description",content:e.LocStrings.ClearButtonTooltip,children:Q.jsx(En,{as:"button",appearance:"primary",shape:"circular",size:"medium",className:r.inputBoxClearBtn,icon:Q.jsx(YO,{}),disabled:e.isChatbotTyping,onClick:e.onClear})}),Q.jsxs("div",{className:r.inputBox,"data-disabled":e.isChatbotTyping,children:[Q.jsx("textarea",{ref:o,role:"textbox",className:r.inputBoxTextarea,disabled:e.isChatbotTyping||e.inputDisabled,placeholder:e.LocStrings.InputPlaceholder,value:t,onChange:u=>{const d=u.target.value??"";n(d)},onKeyDown:a}),Q.jsx("div",{className:r.inputBoxSendBtnWrapper,children:Q.jsx(En,{as:"button",appearance:"transparent",size:"medium",className:r.inputBoxSendBtn,icon:Q.jsx(fle,{}),disabled:l,onClick:i})})]})]})]})},j1e=(e=!1)=>{const[t,n]=Bt.useState(e),r=Bt.useCallback(()=>{n(o=>!o)},[]);return[t,r]},z1e=({message:e})=>{const t=Ou();return Q.jsx("p",{className:t.errorMessageDetail,children:e.error})},H1e=({message:e,LocStrings:t,CustomMessageContentRenderer:n=q1e})=>{var s;const r=Ou(),[o,i]=j1e(),a=(s=e==null?void 0:e.duration)==null?void 0:s.toFixed(2).replace(/\.?0*$/,"");return Q.jsx("div",{className:r.message,"data-from":e.from,children:Q.jsxs("div",{className:r.messageContent,"data-from":e.from,children:[Q.jsx(n,{message:e}),e.error&&Q.jsx("p",{children:Q.jsx(ED,{onClick:i,children:o?"Hide detail":"Show detail"})}),o&&Q.jsx(z1e,{message:e}),typeof e.duration=="number"&&typeof e.tokens=="number"&&Q.jsxs("div",{className:r.messageStatus,children:[`${t.MessageStatus_Tokens_Desc}: `,Q.jsx("b",{children:e.tokens}),` ${t.MessageStatus_Tokens_Unit}, ${t.MessageStatus_TimeSpent_Desc}: `,Q.jsx("b",{children:a}),` ${t.MessageStatus_TimeSpent_Unit}`]})]})})},U1e=T.memo(H1e),q1e=e=>Q.jsx("p",{children:e.message.content}),$1e=({className:e})=>{const t=W1e();return Q.jsx(wR,{horizontal:!0,verticalAlign:"center",className:e,children:Q.jsxs("div",{className:t.typing,children:[Q.jsx("div",{className:t.typingDot}),Q.jsx("div",{className:t.typingDot}),Q.jsx("div",{className:t.typingDot})]})})},W1e=OT({typing:{...mt.transition("opacity","0.1s"),display:"flex",alignItems:"center",height:"22.5px"},typingDot:{...mt.borderRadius("50%"),...mt.margin("0","0","0","6px"),display:"inline-block",width:"6px",height:"6px",backgroundColor:nn.colorNeutralStroke1,animationDuration:"1.5s",animationTimingFunction:"linear",animationIterationCount:"infinite",animationName:{"0%":{transform:"scale(1)"},"16.67%":{transform:"scale(0)"},"33.33%":{transform:"scale(0)"},"50%":{transform:"scale(0)"},"66.67%":{transform:"scale(1)"},"83.33%":{transform:"scale(1)"},"100%":{transform:"scale(1)"}},"&:nth-child(1)":{...mt.margin("0")},"&:nth-child(2)":{animationDelay:"0.18s"},"&:nth-child(3)":{animationDelay:"0.36s"}}}),G1e=({isChatbotTyping:e,typingClassName:t,messages:n,LocStrings:r,CustomMessageContentRenderer:o})=>{const i=Ou();return Q.jsxs("div",{className:i.messages,children:[n.map(a=>Q.jsx(U1e,{message:a,LocStrings:r,CustomMessageContentRenderer:o},a.id)),e&&Q.jsx($1e,{className:t})]})},K1e=({title:e="Chat",isFullScreen:t,containerStyles:n,LocStrings:r,customToolbarActions:o,onToggleFullScreen:i,onClose:a})=>{const s=Ou();return Q.jsxs("div",{className:s.toolbar,style:n,children:[Q.jsxs("div",{className:s.toolbarTitle,children:[Q.jsx(Zo,{weight:"semibold",children:e}),Q.jsx(cl,{content:r.Tooltip_Title,relationship:"description",children:Q.jsx(En,{as:"button",appearance:"transparent",icon:Q.jsx(Tse,{})})})]}),Q.jsxs("div",{style:{display:"flex",alignItems:"center"},children:[o,Q.jsx(En,{as:"button",appearance:"transparent",icon:t?Q.jsx(Ese,{}):Q.jsx(bse,{}),className:s.toolbarActionButton,onClick:i}),a&&Q.jsx(En,{as:"button",appearance:"transparent",icon:Q.jsx(lse,{}),className:s.toolbarActionButton,onClick:a})]})]})},V1e=e=>{const{containerStyles:t,toolbarContainerStyles:n,chatTitle:r,customInputBox:o,initialTypingMessage:i,isBottomTipVisible:a,isFullScreen:s,isChatbotTyping:l,typingClassName:u,LocStrings:d,inputDisabled:h,messages:p,CustomMessageContentRenderer:m,onBottomTipVisibleChange:v,onClear:_,onSendMessage:b,onToggleFullScreen:E,onClose:w}=e,k=Ou(),y=T.useRef(null);return T.useEffect(()=>{y.current&&(y.current.scrollTop=y.current.scrollHeight)},[p]),Q.jsxs("div",{className:k.chatBox,style:t,children:[Q.jsx("div",{className:k.chatBoxHeader,children:Q.jsx(K1e,{containerStyles:n,title:r,isFullScreen:s,isChatbotTyping:l,LocStrings:d,customToolbarActions:e.customToolbarActions,onToggleFullScreen:E,onClose:w})}),Q.jsx("div",{ref:y,className:k.chatBoxMain,children:Q.jsx(G1e,{isChatbotTyping:l,typingClassName:u,messages:p,LocStrings:d,CustomMessageContentRenderer:m})}),Q.jsx("div",{className:k.chatBoxFooter,children:o||Q.jsx(L1e,{initialTypingMessage:i,isBottomTipVisible:a,isChatbotTyping:l,inputDisabled:h,LocStrings:d,onSendMessage:b,onBottomTipVisibleChange:v,onClear:_})})]})};var ob={exports:{}};/** * @license * Lodash <https://lodash.com/> * Copyright OpenJS Foundation and other contributors <https://openjsf.org/> * Released under MIT license <https://lodash.com/license> * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors */ob.exports;(function(e,t){(function(){var n,r="4.17.21",o=200,i="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",s="Invalid `variable` option passed into `_.template`",l="__lodash_hash_undefined__",u=500,d="__lodash_placeholder__",h=1,p=2,m=4,v=1,_=2,b=1,E=2,w=4,k=8,y=16,F=32,C=64,A=128,P=256,I=512,j=30,H="...",K=800,U=16,pe=1,se=2,J=3,$=1/0,_e=9007199254740991,ve=17976931348623157e292,fe=0/0,R=4294967295,L=R-1,Ae=R>>>1,Ue=[["ary",A],["bind",b],["bindKey",E],["curry",k],["curryRight",y],["flip",I],["partial",F],["partialRight",C],["rearg",P]],Ve="[object Arguments]",Le="[object Array]",st="[object AsyncFunction]",We="[object Boolean]",rt="[object Date]",Zt="[object DOMException]",qn="[object Error]",er="[object Function]",tr="[object GeneratorFunction]",In="[object Map]",br="[object Number]",Nr="[object Null]",an="[object Object]",yo="[object Promise]",Eo="[object Proxy]",jr="[object RegExp]",pn="[object Set]",Mn="[object String]",mn="[object Symbol]",Po="[object Undefined]",me="[object WeakMap]",le="[object WeakSet]",ie="[object ArrayBuffer]",G="[object DataView]",ae="[object Float32Array]",Te="[object Float64Array]",Oe="[object Int8Array]",$e="[object Int16Array]",_t="[object Int32Array]",Qe="[object Uint8Array]",lt="[object Uint8ClampedArray]",Kt="[object Uint16Array]",Pt="[object Uint32Array]",gt=/\b__p \+= '';/g,Ln=/\b(__p \+=) '' \+/g,Tn=/(__e\(.*?\)|\b__t\)) \+\n'';/g,zr=/&(?:amp|lt|gt|quot|#39);/g,wn=/[&<>"']/g,kt=RegExp(zr.source),nr=RegExp(wn.source),dr=/<%-([\s\S]+?)%>/g,rr=/<%([\s\S]+?)%>/g,to=/<%=([\s\S]+?)%>/g,Fr=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,_o=/^\w*$/,Ia=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,wi=/[\\^$.*+?()[\]{}|]/g,ju=RegExp(wi.source),ki=/^\s+/,_1=/\s/,Xc=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Zc=/\{\n\/\* \[wrapped with (.+)\] \*/,zu=/,? & /,Es=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,q=/[()=,{}\[\]\/\s]/,W=/\\(\\)?/g,O=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,B=/\w*$/,z=/^[-+]0x[0-9a-f]+$/i,ee=/^0b[01]+$/i,ue=/^\[object .+?Constructor\]$/,ce=/^0o[0-7]+$/i,te=/^(?:0|[1-9]\d*)$/,he=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Be=/($^)/,He=/['\n\r\u2028\u2029\\]/g,tt="\\ud800-\\udfff",vt="\\u0300-\\u036f",at="\\ufe20-\\ufe2f",Mt="\\u20d0-\\u20ff",en=vt+at+Mt,Xe="\\u2700-\\u27bf",Vt="a-z\\xdf-\\xf6\\xf8-\\xff",Hr="\\xac\\xb1\\xd7\\xf7",ri="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",_s="\\u2000-\\u206f",oi=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Hu="A-Z\\xc0-\\xd6\\xd8-\\xde",Ts="\\ufe0e\\ufe0f",yr=Hr+ri+_s+oi,Ba="['’]",Uu="["+tt+"]",ws="["+yr+"]",qu="["+en+"]",$u="\\d+",T1="["+Xe+"]",Jc="["+Vt+"]",ef="[^"+tt+yr+$u+Xe+Vt+Hu+"]",Wu="\\ud83c[\\udffb-\\udfff]",kl="(?:"+qu+"|"+Wu+")",w1="[^"+tt+"]",qy="(?:\\ud83c[\\udde6-\\uddff]){2}",$y="[\\ud800-\\udbff][\\udc00-\\udfff]",tf="["+Hu+"]",Nk="\\u200d",Fk="(?:"+Jc+"|"+ef+")",rj="(?:"+tf+"|"+ef+")",Ik="(?:"+Ba+"(?:d|ll|m|re|s|t|ve))?",Bk="(?:"+Ba+"(?:D|LL|M|RE|S|T|VE))?",Rk=kl+"?",Ok="["+Ts+"]?",oj="(?:"+Nk+"(?:"+[w1,qy,$y].join("|")+")"+Ok+Rk+")*",ij="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",aj="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",Dk=Ok+Rk+oj,sj="(?:"+[T1,qy,$y].join("|")+")"+Dk,lj="(?:"+[w1+qu+"?",qu,qy,$y,Uu].join("|")+")",uj=RegExp(Ba,"g"),cj=RegExp(qu,"g"),Wy=RegExp(Wu+"(?="+Wu+")|"+lj+Dk,"g"),fj=RegExp([tf+"?"+Jc+"+"+Ik+"(?="+[ws,tf,"$"].join("|")+")",rj+"+"+Bk+"(?="+[ws,tf+Fk,"$"].join("|")+")",tf+"?"+Fk+"+"+Ik,tf+"+"+Bk,aj,ij,$u,sj].join("|"),"g"),dj=RegExp("["+Nk+tt+en+Ts+"]"),hj=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,pj=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],mj=-1,kn={};kn[ae]=kn[Te]=kn[Oe]=kn[$e]=kn[_t]=kn[Qe]=kn[lt]=kn[Kt]=kn[Pt]=!0,kn[Ve]=kn[Le]=kn[ie]=kn[We]=kn[G]=kn[rt]=kn[qn]=kn[er]=kn[In]=kn[br]=kn[an]=kn[jr]=kn[pn]=kn[Mn]=kn[me]=!1;var gn={};gn[Ve]=gn[Le]=gn[ie]=gn[G]=gn[We]=gn[rt]=gn[ae]=gn[Te]=gn[Oe]=gn[$e]=gn[_t]=gn[In]=gn[br]=gn[an]=gn[jr]=gn[pn]=gn[Mn]=gn[mn]=gn[Qe]=gn[lt]=gn[Kt]=gn[Pt]=!0,gn[qn]=gn[er]=gn[me]=!1;var gj={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",Ç:"C",ç:"c",Ð:"D",ð:"d",È:"E",É:"E",Ê:"E",Ë:"E",è:"e",é:"e",ê:"e",ë:"e",Ì:"I",Í:"I",Î:"I",Ï:"I",ì:"i",í:"i",î:"i",ï:"i",Ñ:"N",ñ:"n",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ù:"U",Ú:"U",Û:"U",Ü:"U",ù:"u",ú:"u",û:"u",ü:"u",Ý:"Y",ý:"y",ÿ:"y",Æ:"Ae",æ:"ae",Þ:"Th",þ:"th",ß:"ss",Ā:"A",Ă:"A",Ą:"A",ā:"a",ă:"a",ą:"a",Ć:"C",Ĉ:"C",Ċ:"C",Č:"C",ć:"c",ĉ:"c",ċ:"c",č:"c",Ď:"D",Đ:"D",ď:"d",đ:"d",Ē:"E",Ĕ:"E",Ė:"E",Ę:"E",Ě:"E",ē:"e",ĕ:"e",ė:"e",ę:"e",ě:"e",Ĝ:"G",Ğ:"G",Ġ:"G",Ģ:"G",ĝ:"g",ğ:"g",ġ:"g",ģ:"g",Ĥ:"H",Ħ:"H",ĥ:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Į:"I",İ:"I",ĩ:"i",ī:"i",ĭ:"i",į:"i",ı:"i",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",ĸ:"k",Ĺ:"L",Ļ:"L",Ľ:"L",Ŀ:"L",Ł:"L",ĺ:"l",ļ:"l",ľ:"l",ŀ:"l",ł:"l",Ń:"N",Ņ:"N",Ň:"N",Ŋ:"N",ń:"n",ņ:"n",ň:"n",ŋ:"n",Ō:"O",Ŏ:"O",Ő:"O",ō:"o",ŏ:"o",ő:"o",Ŕ:"R",Ŗ:"R",Ř:"R",ŕ:"r",ŗ:"r",ř:"r",Ś:"S",Ŝ:"S",Ş:"S",Š:"S",ś:"s",ŝ:"s",ş:"s",š:"s",Ţ:"T",Ť:"T",Ŧ:"T",ţ:"t",ť:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Ů:"U",Ű:"U",Ų:"U",ũ:"u",ū:"u",ŭ:"u",ů:"u",ű:"u",ų:"u",Ŵ:"W",ŵ:"w",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Ź:"Z",Ż:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Œ:"Oe",œ:"oe",ʼn:"'n",ſ:"s"},vj={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"},bj={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"},yj={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Ej=parseFloat,_j=parseInt,Pk=typeof Mf=="object"&&Mf&&Mf.Object===Object&&Mf,Tj=typeof self=="object"&&self&&self.Object===Object&&self,Ur=Pk||Tj||Function("return this")(),Gy=t&&!t.nodeType&&t,Gu=Gy&&!0&&e&&!e.nodeType&&e,Mk=Gu&&Gu.exports===Gy,Ky=Mk&&Pk.process,Si=function(){try{var ne=Gu&&Gu.require&&Gu.require("util").types;return ne||Ky&&Ky.binding&&Ky.binding("util")}catch{}}(),Lk=Si&&Si.isArrayBuffer,jk=Si&&Si.isDate,zk=Si&&Si.isMap,Hk=Si&&Si.isRegExp,Uk=Si&&Si.isSet,qk=Si&&Si.isTypedArray;function ii(ne,ge,de){switch(de.length){case 0:return ne.call(ge);case 1:return ne.call(ge,de[0]);case 2:return ne.call(ge,de[0],de[1]);case 3:return ne.call(ge,de[0],de[1],de[2])}return ne.apply(ge,de)}function wj(ne,ge,de,Pe){for(var ft=-1,Yt=ne==null?0:ne.length;++ft<Yt;){var Er=ne[ft];ge(Pe,Er,de(Er),ne)}return Pe}function xi(ne,ge){for(var de=-1,Pe=ne==null?0:ne.length;++de<Pe&&ge(ne[de],de,ne)!==!1;);return ne}function kj(ne,ge){for(var de=ne==null?0:ne.length;de--&&ge(ne[de],de,ne)!==!1;);return ne}function $k(ne,ge){for(var de=-1,Pe=ne==null?0:ne.length;++de<Pe;)if(!ge(ne[de],de,ne))return!1;return!0}function Sl(ne,ge){for(var de=-1,Pe=ne==null?0:ne.length,ft=0,Yt=[];++de<Pe;){var Er=ne[de];ge(Er,de,ne)&&(Yt[ft++]=Er)}return Yt}function Ip(ne,ge){var de=ne==null?0:ne.length;return!!de&&nf(ne,ge,0)>-1}function Vy(ne,ge,de){for(var Pe=-1,ft=ne==null?0:ne.length;++Pe<ft;)if(de(ge,ne[Pe]))return!0;return!1}function Bn(ne,ge){for(var de=-1,Pe=ne==null?0:ne.length,ft=Array(Pe);++de<Pe;)ft[de]=ge(ne[de],de,ne);return ft}function xl(ne,ge){for(var de=-1,Pe=ge.length,ft=ne.length;++de<Pe;)ne[ft+de]=ge[de];return ne}function Yy(ne,ge,de,Pe){var ft=-1,Yt=ne==null?0:ne.length;for(Pe&&Yt&&(de=ne[++ft]);++ft<Yt;)de=ge(de,ne[ft],ft,ne);return de}function Sj(ne,ge,de,Pe){var ft=ne==null?0:ne.length;for(Pe&&ft&&(de=ne[--ft]);ft--;)de=ge(de,ne[ft],ft,ne);return de}function Qy(ne,ge){for(var de=-1,Pe=ne==null?0:ne.length;++de<Pe;)if(ge(ne[de],de,ne))return!0;return!1}var xj=Xy("length");function Cj(ne){return ne.split("")}function Aj(ne){return ne.match(Es)||[]}function Wk(ne,ge,de){var Pe;return de(ne,function(ft,Yt,Er){if(ge(ft,Yt,Er))return Pe=Yt,!1}),Pe}function Bp(ne,ge,de,Pe){for(var ft=ne.length,Yt=de+(Pe?1:-1);Pe?Yt--:++Yt<ft;)if(ge(ne[Yt],Yt,ne))return Yt;return-1}function nf(ne,ge,de){return ge===ge?zj(ne,ge,de):Bp(ne,Gk,de)}function Nj(ne,ge,de,Pe){for(var ft=de-1,Yt=ne.length;++ft<Yt;)if(Pe(ne[ft],ge))return ft;return-1}function Gk(ne){return ne!==ne}function Kk(ne,ge){var de=ne==null?0:ne.length;return de?Jy(ne,ge)/de:fe}function Xy(ne){return function(ge){return ge==null?n:ge[ne]}}function Zy(ne){return function(ge){return ne==null?n:ne[ge]}}function Vk(ne,ge,de,Pe,ft){return ft(ne,function(Yt,Er,fn){de=Pe?(Pe=!1,Yt):ge(de,Yt,Er,fn)}),de}function Fj(ne,ge){var de=ne.length;for(ne.sort(ge);de--;)ne[de]=ne[de].value;return ne}function Jy(ne,ge){for(var de,Pe=-1,ft=ne.length;++Pe<ft;){var Yt=ge(ne[Pe]);Yt!==n&&(de=de===n?Yt:de+Yt)}return de}function e5(ne,ge){for(var de=-1,Pe=Array(ne);++de<ne;)Pe[de]=ge(de);return Pe}function Ij(ne,ge){return Bn(ge,function(de){return[de,ne[de]]})}function Yk(ne){return ne&&ne.slice(0,Jk(ne)+1).replace(ki,"")}function ai(ne){return function(ge){return ne(ge)}}function t5(ne,ge){return Bn(ge,function(de){return ne[de]})}function k1(ne,ge){return ne.has(ge)}function Qk(ne,ge){for(var de=-1,Pe=ne.length;++de<Pe&&nf(ge,ne[de],0)>-1;);return de}function Xk(ne,ge){for(var de=ne.length;de--&&nf(ge,ne[de],0)>-1;);return de}function Bj(ne,ge){for(var de=ne.length,Pe=0;de--;)ne[de]===ge&&++Pe;return Pe}var Rj=Zy(gj),Oj=Zy(vj);function Dj(ne){return"\\"+yj[ne]}function Pj(ne,ge){return ne==null?n:ne[ge]}function rf(ne){return dj.test(ne)}function Mj(ne){return hj.test(ne)}function Lj(ne){for(var ge,de=[];!(ge=ne.next()).done;)de.push(ge.value);return de}function n5(ne){var ge=-1,de=Array(ne.size);return ne.forEach(function(Pe,ft){de[++ge]=[ft,Pe]}),de}function Zk(ne,ge){return function(de){return ne(ge(de))}}function Cl(ne,ge){for(var de=-1,Pe=ne.length,ft=0,Yt=[];++de<Pe;){var Er=ne[de];(Er===ge||Er===d)&&(ne[de]=d,Yt[ft++]=de)}return Yt}function Rp(ne){var ge=-1,de=Array(ne.size);return ne.forEach(function(Pe){de[++ge]=Pe}),de}function jj(ne){var ge=-1,de=Array(ne.size);return ne.forEach(function(Pe){de[++ge]=[Pe,Pe]}),de}function zj(ne,ge,de){for(var Pe=de-1,ft=ne.length;++Pe<ft;)if(ne[Pe]===ge)return Pe;return-1}function Hj(ne,ge,de){for(var Pe=de+1;Pe--;)if(ne[Pe]===ge)return Pe;return Pe}function of(ne){return rf(ne)?qj(ne):xj(ne)}function ia(ne){return rf(ne)?$j(ne):Cj(ne)}function Jk(ne){for(var ge=ne.length;ge--&&_1.test(ne.charAt(ge)););return ge}var Uj=Zy(bj);function qj(ne){for(var ge=Wy.lastIndex=0;Wy.test(ne);)++ge;return ge}function $j(ne){return ne.match(Wy)||[]}function Wj(ne){return ne.match(fj)||[]}var Gj=function ne(ge){ge=ge==null?Ur:af.defaults(Ur.Object(),ge,af.pick(Ur,pj));var de=ge.Array,Pe=ge.Date,ft=ge.Error,Yt=ge.Function,Er=ge.Math,fn=ge.Object,r5=ge.RegExp,Kj=ge.String,Ci=ge.TypeError,Op=de.prototype,Vj=Yt.prototype,sf=fn.prototype,Dp=ge["__core-js_shared__"],Pp=Vj.toString,tn=sf.hasOwnProperty,Yj=0,eS=function(){var c=/[^.]+$/.exec(Dp&&Dp.keys&&Dp.keys.IE_PROTO||"");return c?"Symbol(src)_1."+c:""}(),Mp=sf.toString,Qj=Pp.call(fn),Xj=Ur._,Zj=r5("^"+Pp.call(tn).replace(wi,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Lp=Mk?ge.Buffer:n,Al=ge.Symbol,jp=ge.Uint8Array,tS=Lp?Lp.allocUnsafe:n,zp=Zk(fn.getPrototypeOf,fn),nS=fn.create,rS=sf.propertyIsEnumerable,Hp=Op.splice,oS=Al?Al.isConcatSpreadable:n,S1=Al?Al.iterator:n,Ku=Al?Al.toStringTag:n,Up=function(){try{var c=Zu(fn,"defineProperty");return c({},"",{}),c}catch{}}(),Jj=ge.clearTimeout!==Ur.clearTimeout&&ge.clearTimeout,ez=Pe&&Pe.now!==Ur.Date.now&&Pe.now,tz=ge.setTimeout!==Ur.setTimeout&&ge.setTimeout,qp=Er.ceil,$p=Er.floor,o5=fn.getOwnPropertySymbols,nz=Lp?Lp.isBuffer:n,iS=ge.isFinite,rz=Op.join,oz=Zk(fn.keys,fn),_r=Er.max,no=Er.min,iz=Pe.now,az=ge.parseInt,aS=Er.random,sz=Op.reverse,i5=Zu(ge,"DataView"),x1=Zu(ge,"Map"),a5=Zu(ge,"Promise"),lf=Zu(ge,"Set"),C1=Zu(ge,"WeakMap"),A1=Zu(fn,"create"),Wp=C1&&new C1,uf={},lz=Ju(i5),uz=Ju(x1),cz=Ju(a5),fz=Ju(lf),dz=Ju(C1),Gp=Al?Al.prototype:n,N1=Gp?Gp.valueOf:n,sS=Gp?Gp.toString:n;function D(c){if($n(c)&&!dt(c)&&!(c instanceof Rt)){if(c instanceof Ai)return c;if(tn.call(c,"__wrapped__"))return l8(c)}return new Ai(c)}var cf=function(){function c(){}return function(f){if(!jn(f))return{};if(nS)return nS(f);c.prototype=f;var g=new c;return c.prototype=n,g}}();function Kp(){}function Ai(c,f){this.__wrapped__=c,this.__actions__=[],this.__chain__=!!f,this.__index__=0,this.__values__=n}D.templateSettings={escape:dr,evaluate:rr,interpolate:to,variable:"",imports:{_:D}},D.prototype=Kp.prototype,D.prototype.constructor=D,Ai.prototype=cf(Kp.prototype),Ai.prototype.constructor=Ai;function Rt(c){this.__wrapped__=c,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=R,this.__views__=[]}function hz(){var c=new Rt(this.__wrapped__);return c.__actions__=Mo(this.__actions__),c.__dir__=this.__dir__,c.__filtered__=this.__filtered__,c.__iteratees__=Mo(this.__iteratees__),c.__takeCount__=this.__takeCount__,c.__views__=Mo(this.__views__),c}function pz(){if(this.__filtered__){var c=new Rt(this);c.__dir__=-1,c.__filtered__=!0}else c=this.clone(),c.__dir__*=-1;return c}function mz(){var c=this.__wrapped__.value(),f=this.__dir__,g=dt(c),S=f<0,N=g?c.length:0,M=CH(0,N,this.__views__),V=M.start,Z=M.end,re=Z-V,be=S?Z:V-1,Ee=this.__iteratees__,ke=Ee.length,Re=0,qe=no(re,this.__takeCount__);if(!g||!S&&N==re&&qe==re)return IS(c,this.__actions__);var ot=[];e:for(;re--&&Re<qe;){be+=f;for(var Tt=-1,it=c[be];++Tt<ke;){var Ft=Ee[Tt],Lt=Ft.iteratee,ui=Ft.type,ko=Lt(it);if(ui==se)it=ko;else if(!ko){if(ui==pe)continue e;break e}}ot[Re++]=it}return ot}Rt.prototype=cf(Kp.prototype),Rt.prototype.constructor=Rt;function Vu(c){var f=-1,g=c==null?0:c.length;for(this.clear();++f<g;){var S=c[f];this.set(S[0],S[1])}}function gz(){this.__data__=A1?A1(null):{},this.size=0}function vz(c){var f=this.has(c)&&delete this.__data__[c];return this.size-=f?1:0,f}function bz(c){var f=this.__data__;if(A1){var g=f[c];return g===l?n:g}return tn.call(f,c)?f[c]:n}function yz(c){var f=this.__data__;return A1?f[c]!==n:tn.call(f,c)}function Ez(c,f){var g=this.__data__;return this.size+=this.has(c)?0:1,g[c]=A1&&f===n?l:f,this}Vu.prototype.clear=gz,Vu.prototype.delete=vz,Vu.prototype.get=bz,Vu.prototype.has=yz,Vu.prototype.set=Ez;function ks(c){var f=-1,g=c==null?0:c.length;for(this.clear();++f<g;){var S=c[f];this.set(S[0],S[1])}}function _z(){this.__data__=[],this.size=0}function Tz(c){var f=this.__data__,g=Vp(f,c);if(g<0)return!1;var S=f.length-1;return g==S?f.pop():Hp.call(f,g,1),--this.size,!0}function wz(c){var f=this.__data__,g=Vp(f,c);return g<0?n:f[g][1]}function kz(c){return Vp(this.__data__,c)>-1}function Sz(c,f){var g=this.__data__,S=Vp(g,c);return S<0?(++this.size,g.push([c,f])):g[S][1]=f,this}ks.prototype.clear=_z,ks.prototype.delete=Tz,ks.prototype.get=wz,ks.prototype.has=kz,ks.prototype.set=Sz;function Ss(c){var f=-1,g=c==null?0:c.length;for(this.clear();++f<g;){var S=c[f];this.set(S[0],S[1])}}function xz(){this.size=0,this.__data__={hash:new Vu,map:new(x1||ks),string:new Vu}}function Cz(c){var f=am(this,c).delete(c);return this.size-=f?1:0,f}function Az(c){return am(this,c).get(c)}function Nz(c){return am(this,c).has(c)}function Fz(c,f){var g=am(this,c),S=g.size;return g.set(c,f),this.size+=g.size==S?0:1,this}Ss.prototype.clear=xz,Ss.prototype.delete=Cz,Ss.prototype.get=Az,Ss.prototype.has=Nz,Ss.prototype.set=Fz;function Yu(c){var f=-1,g=c==null?0:c.length;for(this.__data__=new Ss;++f<g;)this.add(c[f])}function Iz(c){return this.__data__.set(c,l),this}function Bz(c){return this.__data__.has(c)}Yu.prototype.add=Yu.prototype.push=Iz,Yu.prototype.has=Bz;function aa(c){var f=this.__data__=new ks(c);this.size=f.size}function Rz(){this.__data__=new ks,this.size=0}function Oz(c){var f=this.__data__,g=f.delete(c);return this.size=f.size,g}function Dz(c){return this.__data__.get(c)}function Pz(c){return this.__data__.has(c)}function Mz(c,f){var g=this.__data__;if(g instanceof ks){var S=g.__data__;if(!x1||S.length<o-1)return S.push([c,f]),this.size=++g.size,this;g=this.__data__=new Ss(S)}return g.set(c,f),this.size=g.size,this}aa.prototype.clear=Rz,aa.prototype.delete=Oz,aa.prototype.get=Dz,aa.prototype.has=Pz,aa.prototype.set=Mz;function lS(c,f){var g=dt(c),S=!g&&ec(c),N=!g&&!S&&Rl(c),M=!g&&!S&&!N&&pf(c),V=g||S||N||M,Z=V?e5(c.length,Kj):[],re=Z.length;for(var be in c)(f||tn.call(c,be))&&!(V&&(be=="length"||N&&(be=="offset"||be=="parent")||M&&(be=="buffer"||be=="byteLength"||be=="byteOffset")||Ns(be,re)))&&Z.push(be);return Z}function uS(c){var f=c.length;return f?c[v5(0,f-1)]:n}function Lz(c,f){return sm(Mo(c),Qu(f,0,c.length))}function jz(c){return sm(Mo(c))}function s5(c,f,g){(g!==n&&!sa(c[f],g)||g===n&&!(f in c))&&xs(c,f,g)}function F1(c,f,g){var S=c[f];(!(tn.call(c,f)&&sa(S,g))||g===n&&!(f in c))&&xs(c,f,g)}function Vp(c,f){for(var g=c.length;g--;)if(sa(c[g][0],f))return g;return-1}function zz(c,f,g,S){return Nl(c,function(N,M,V){f(S,N,g(N),V)}),S}function cS(c,f){return c&&Oa(f,Ir(f),c)}function Hz(c,f){return c&&Oa(f,jo(f),c)}function xs(c,f,g){f=="__proto__"&&Up?Up(c,f,{configurable:!0,enumerable:!0,value:g,writable:!0}):c[f]=g}function l5(c,f){for(var g=-1,S=f.length,N=de(S),M=c==null;++g<S;)N[g]=M?n:U5(c,f[g]);return N}function Qu(c,f,g){return c===c&&(g!==n&&(c=c<=g?c:g),f!==n&&(c=c>=f?c:f)),c}function Ni(c,f,g,S,N,M){var V,Z=f&h,re=f&p,be=f&m;if(g&&(V=N?g(c,S,N,M):g(c)),V!==n)return V;if(!jn(c))return c;var Ee=dt(c);if(Ee){if(V=NH(c),!Z)return Mo(c,V)}else{var ke=ro(c),Re=ke==er||ke==tr;if(Rl(c))return OS(c,Z);if(ke==an||ke==Ve||Re&&!N){if(V=re||Re?{}:JS(c),!Z)return re?bH(c,Hz(V,c)):vH(c,cS(V,c))}else{if(!gn[ke])return N?c:{};V=FH(c,ke,Z)}}M||(M=new aa);var qe=M.get(c);if(qe)return qe;M.set(c,V),A8(c)?c.forEach(function(it){V.add(Ni(it,f,g,it,c,M))}):x8(c)&&c.forEach(function(it,Ft){V.set(Ft,Ni(it,f,g,Ft,c,M))});var ot=be?re?A5:C5:re?jo:Ir,Tt=Ee?n:ot(c);return xi(Tt||c,function(it,Ft){Tt&&(Ft=it,it=c[Ft]),F1(V,Ft,Ni(it,f,g,Ft,c,M))}),V}function Uz(c){var f=Ir(c);return function(g){return fS(g,c,f)}}function fS(c,f,g){var S=g.length;if(c==null)return!S;for(c=fn(c);S--;){var N=g[S],M=f[N],V=c[N];if(V===n&&!(N in c)||!M(V))return!1}return!0}function dS(c,f,g){if(typeof c!="function")throw new Ci(a);return M1(function(){c.apply(n,g)},f)}function I1(c,f,g,S){var N=-1,M=Ip,V=!0,Z=c.length,re=[],be=f.length;if(!Z)return re;g&&(f=Bn(f,ai(g))),S?(M=Vy,V=!1):f.length>=o&&(M=k1,V=!1,f=new Yu(f));e:for(;++N<Z;){var Ee=c[N],ke=g==null?Ee:g(Ee);if(Ee=S||Ee!==0?Ee:0,V&&ke===ke){for(var Re=be;Re--;)if(f[Re]===ke)continue e;re.push(Ee)}else M(f,ke,S)||re.push(Ee)}return re}var Nl=jS(Ra),hS=jS(c5,!0);function qz(c,f){var g=!0;return Nl(c,function(S,N,M){return g=!!f(S,N,M),g}),g}function Yp(c,f,g){for(var S=-1,N=c.length;++S<N;){var M=c[S],V=f(M);if(V!=null&&(Z===n?V===V&&!li(V):g(V,Z)))var Z=V,re=M}return re}function $z(c,f,g,S){var N=c.length;for(g=bt(g),g<0&&(g=-g>N?0:N+g),S=S===n||S>N?N:bt(S),S<0&&(S+=N),S=g>S?0:F8(S);g<S;)c[g++]=f;return c}function pS(c,f){var g=[];return Nl(c,function(S,N,M){f(S,N,M)&&g.push(S)}),g}function qr(c,f,g,S,N){var M=-1,V=c.length;for(g||(g=BH),N||(N=[]);++M<V;){var Z=c[M];f>0&&g(Z)?f>1?qr(Z,f-1,g,S,N):xl(N,Z):S||(N[N.length]=Z)}return N}var u5=zS(),mS=zS(!0);function Ra(c,f){return c&&u5(c,f,Ir)}function c5(c,f){return c&&mS(c,f,Ir)}function Qp(c,f){return Sl(f,function(g){return Fs(c[g])})}function Xu(c,f){f=Il(f,c);for(var g=0,S=f.length;c!=null&&g<S;)c=c[Da(f[g++])];return g&&g==S?c:n}function gS(c,f,g){var S=f(c);return dt(c)?S:xl(S,g(c))}function To(c){return c==null?c===n?Po:Nr:Ku&&Ku in fn(c)?xH(c):jH(c)}function f5(c,f){return c>f}function Wz(c,f){return c!=null&&tn.call(c,f)}function Gz(c,f){return c!=null&&f in fn(c)}function Kz(c,f,g){return c>=no(f,g)&&c<_r(f,g)}function d5(c,f,g){for(var S=g?Vy:Ip,N=c[0].length,M=c.length,V=M,Z=de(M),re=1/0,be=[];V--;){var Ee=c[V];V&&f&&(Ee=Bn(Ee,ai(f))),re=no(Ee.length,re),Z[V]=!g&&(f||N>=120&&Ee.length>=120)?new Yu(V&&Ee):n}Ee=c[0];var ke=-1,Re=Z[0];e:for(;++ke<N&&be.length<re;){var qe=Ee[ke],ot=f?f(qe):qe;if(qe=g||qe!==0?qe:0,!(Re?k1(Re,ot):S(be,ot,g))){for(V=M;--V;){var Tt=Z[V];if(!(Tt?k1(Tt,ot):S(c[V],ot,g)))continue e}Re&&Re.push(ot),be.push(qe)}}return be}function Vz(c,f,g,S){return Ra(c,function(N,M,V){f(S,g(N),M,V)}),S}function B1(c,f,g){f=Il(f,c),c=r8(c,f);var S=c==null?c:c[Da(Ii(f))];return S==null?n:ii(S,c,g)}function vS(c){return $n(c)&&To(c)==Ve}function Yz(c){return $n(c)&&To(c)==ie}function Qz(c){return $n(c)&&To(c)==rt}function R1(c,f,g,S,N){return c===f?!0:c==null||f==null||!$n(c)&&!$n(f)?c!==c&&f!==f:Xz(c,f,g,S,R1,N)}function Xz(c,f,g,S,N,M){var V=dt(c),Z=dt(f),re=V?Le:ro(c),be=Z?Le:ro(f);re=re==Ve?an:re,be=be==Ve?an:be;var Ee=re==an,ke=be==an,Re=re==be;if(Re&&Rl(c)){if(!Rl(f))return!1;V=!0,Ee=!1}if(Re&&!Ee)return M||(M=new aa),V||pf(c)?QS(c,f,g,S,N,M):kH(c,f,re,g,S,N,M);if(!(g&v)){var qe=Ee&&tn.call(c,"__wrapped__"),ot=ke&&tn.call(f,"__wrapped__");if(qe||ot){var Tt=qe?c.value():c,it=ot?f.value():f;return M||(M=new aa),N(Tt,it,g,S,M)}}return Re?(M||(M=new aa),SH(c,f,g,S,N,M)):!1}function Zz(c){return $n(c)&&ro(c)==In}function h5(c,f,g,S){var N=g.length,M=N,V=!S;if(c==null)return!M;for(c=fn(c);N--;){var Z=g[N];if(V&&Z[2]?Z[1]!==c[Z[0]]:!(Z[0]in c))return!1}for(;++N<M;){Z=g[N];var re=Z[0],be=c[re],Ee=Z[1];if(V&&Z[2]){if(be===n&&!(re in c))return!1}else{var ke=new aa;if(S)var Re=S(be,Ee,re,c,f,ke);if(!(Re===n?R1(Ee,be,v|_,S,ke):Re))return!1}}return!0}function bS(c){if(!jn(c)||OH(c))return!1;var f=Fs(c)?Zj:ue;return f.test(Ju(c))}function Jz(c){return $n(c)&&To(c)==jr}function eH(c){return $n(c)&&ro(c)==pn}function tH(c){return $n(c)&&hm(c.length)&&!!kn[To(c)]}function yS(c){return typeof c=="function"?c:c==null?zo:typeof c=="object"?dt(c)?TS(c[0],c[1]):_S(c):H8(c)}function p5(c){if(!P1(c))return oz(c);var f=[];for(var g in fn(c))tn.call(c,g)&&g!="constructor"&&f.push(g);return f}function nH(c){if(!jn(c))return LH(c);var f=P1(c),g=[];for(var S in c)S=="constructor"&&(f||!tn.call(c,S))||g.push(S);return g}function m5(c,f){return c<f}function ES(c,f){var g=-1,S=Lo(c)?de(c.length):[];return Nl(c,function(N,M,V){S[++g]=f(N,M,V)}),S}function _S(c){var f=F5(c);return f.length==1&&f[0][2]?t8(f[0][0],f[0][1]):function(g){return g===c||h5(g,c,f)}}function TS(c,f){return B5(c)&&e8(f)?t8(Da(c),f):function(g){var S=U5(g,c);return S===n&&S===f?q5(g,c):R1(f,S,v|_)}}function Xp(c,f,g,S,N){c!==f&&u5(f,function(M,V){if(N||(N=new aa),jn(M))rH(c,f,V,g,Xp,S,N);else{var Z=S?S(O5(c,V),M,V+"",c,f,N):n;Z===n&&(Z=M),s5(c,V,Z)}},jo)}function rH(c,f,g,S,N,M,V){var Z=O5(c,g),re=O5(f,g),be=V.get(re);if(be){s5(c,g,be);return}var Ee=M?M(Z,re,g+"",c,f,V):n,ke=Ee===n;if(ke){var Re=dt(re),qe=!Re&&Rl(re),ot=!Re&&!qe&&pf(re);Ee=re,Re||qe||ot?dt(Z)?Ee=Z:or(Z)?Ee=Mo(Z):qe?(ke=!1,Ee=OS(re,!0)):ot?(ke=!1,Ee=DS(re,!0)):Ee=[]:L1(re)||ec(re)?(Ee=Z,ec(Z)?Ee=I8(Z):(!jn(Z)||Fs(Z))&&(Ee=JS(re))):ke=!1}ke&&(V.set(re,Ee),N(Ee,re,S,M,V),V.delete(re)),s5(c,g,Ee)}function wS(c,f){var g=c.length;if(g)return f+=f<0?g:0,Ns(f,g)?c[f]:n}function kS(c,f,g){f.length?f=Bn(f,function(M){return dt(M)?function(V){return Xu(V,M.length===1?M[0]:M)}:M}):f=[zo];var S=-1;f=Bn(f,ai(nt()));var N=ES(c,function(M,V,Z){var re=Bn(f,function(be){return be(M)});return{criteria:re,index:++S,value:M}});return Fj(N,function(M,V){return gH(M,V,g)})}function oH(c,f){return SS(c,f,function(g,S){return q5(c,S)})}function SS(c,f,g){for(var S=-1,N=f.length,M={};++S<N;){var V=f[S],Z=Xu(c,V);g(Z,V)&&O1(M,Il(V,c),Z)}return M}function iH(c){return function(f){return Xu(f,c)}}function g5(c,f,g,S){var N=S?Nj:nf,M=-1,V=f.length,Z=c;for(c===f&&(f=Mo(f)),g&&(Z=Bn(c,ai(g)));++M<V;)for(var re=0,be=f[M],Ee=g?g(be):be;(re=N(Z,Ee,re,S))>-1;)Z!==c&&Hp.call(Z,re,1),Hp.call(c,re,1);return c}function xS(c,f){for(var g=c?f.length:0,S=g-1;g--;){var N=f[g];if(g==S||N!==M){var M=N;Ns(N)?Hp.call(c,N,1):E5(c,N)}}return c}function v5(c,f){return c+$p(aS()*(f-c+1))}function aH(c,f,g,S){for(var N=-1,M=_r(qp((f-c)/(g||1)),0),V=de(M);M--;)V[S?M:++N]=c,c+=g;return V}function b5(c,f){var g="";if(!c||f<1||f>_e)return g;do f%2&&(g+=c),f=$p(f/2),f&&(c+=c);while(f);return g}function St(c,f){return D5(n8(c,f,zo),c+"")}function sH(c){return uS(mf(c))}function lH(c,f){var g=mf(c);return sm(g,Qu(f,0,g.length))}function O1(c,f,g,S){if(!jn(c))return c;f=Il(f,c);for(var N=-1,M=f.length,V=M-1,Z=c;Z!=null&&++N<M;){var re=Da(f[N]),be=g;if(re==="__proto__"||re==="constructor"||re==="prototype")return c;if(N!=V){var Ee=Z[re];be=S?S(Ee,re,Z):n,be===n&&(be=jn(Ee)?Ee:Ns(f[N+1])?[]:{})}F1(Z,re,be),Z=Z[re]}return c}var CS=Wp?function(c,f){return Wp.set(c,f),c}:zo,uH=Up?function(c,f){return Up(c,"toString",{configurable:!0,enumerable:!1,value:W5(f),writable:!0})}:zo;function cH(c){return sm(mf(c))}function Fi(c,f,g){var S=-1,N=c.length;f<0&&(f=-f>N?0:N+f),g=g>N?N:g,g<0&&(g+=N),N=f>g?0:g-f>>>0,f>>>=0;for(var M=de(N);++S<N;)M[S]=c[S+f];return M}function fH(c,f){var g;return Nl(c,function(S,N,M){return g=f(S,N,M),!g}),!!g}function Zp(c,f,g){var S=0,N=c==null?S:c.length;if(typeof f=="number"&&f===f&&N<=Ae){for(;S<N;){var M=S+N>>>1,V=c[M];V!==null&&!li(V)&&(g?V<=f:V<f)?S=M+1:N=M}return N}return y5(c,f,zo,g)}function y5(c,f,g,S){var N=0,M=c==null?0:c.length;if(M===0)return 0;f=g(f);for(var V=f!==f,Z=f===null,re=li(f),be=f===n;N<M;){var Ee=$p((N+M)/2),ke=g(c[Ee]),Re=ke!==n,qe=ke===null,ot=ke===ke,Tt=li(ke);if(V)var it=S||ot;else be?it=ot&&(S||Re):Z?it=ot&&Re&&(S||!qe):re?it=ot&&Re&&!qe&&(S||!Tt):qe||Tt?it=!1:it=S?ke<=f:ke<f;it?N=Ee+1:M=Ee}return no(M,L)}function AS(c,f){for(var g=-1,S=c.length,N=0,M=[];++g<S;){var V=c[g],Z=f?f(V):V;if(!g||!sa(Z,re)){var re=Z;M[N++]=V===0?0:V}}return M}function NS(c){return typeof c=="number"?c:li(c)?fe:+c}function si(c){if(typeof c=="string")return c;if(dt(c))return Bn(c,si)+"";if(li(c))return sS?sS.call(c):"";var f=c+"";return f=="0"&&1/c==-$?"-0":f}function Fl(c,f,g){var S=-1,N=Ip,M=c.length,V=!0,Z=[],re=Z;if(g)V=!1,N=Vy;else if(M>=o){var be=f?null:TH(c);if(be)return Rp(be);V=!1,N=k1,re=new Yu}else re=f?[]:Z;e:for(;++S<M;){var Ee=c[S],ke=f?f(Ee):Ee;if(Ee=g||Ee!==0?Ee:0,V&&ke===ke){for(var Re=re.length;Re--;)if(re[Re]===ke)continue e;f&&re.push(ke),Z.push(Ee)}else N(re,ke,g)||(re!==Z&&re.push(ke),Z.push(Ee))}return Z}function E5(c,f){return f=Il(f,c),c=r8(c,f),c==null||delete c[Da(Ii(f))]}function FS(c,f,g,S){return O1(c,f,g(Xu(c,f)),S)}function Jp(c,f,g,S){for(var N=c.length,M=S?N:-1;(S?M--:++M<N)&&f(c[M],M,c););return g?Fi(c,S?0:M,S?M+1:N):Fi(c,S?M+1:0,S?N:M)}function IS(c,f){var g=c;return g instanceof Rt&&(g=g.value()),Yy(f,function(S,N){return N.func.apply(N.thisArg,xl([S],N.args))},g)}function _5(c,f,g){var S=c.length;if(S<2)return S?Fl(c[0]):[];for(var N=-1,M=de(S);++N<S;)for(var V=c[N],Z=-1;++Z<S;)Z!=N&&(M[N]=I1(M[N]||V,c[Z],f,g));return Fl(qr(M,1),f,g)}function BS(c,f,g){for(var S=-1,N=c.length,M=f.length,V={};++S<N;){var Z=S<M?f[S]:n;g(V,c[S],Z)}return V}function T5(c){return or(c)?c:[]}function w5(c){return typeof c=="function"?c:zo}function Il(c,f){return dt(c)?c:B5(c,f)?[c]:s8(Jt(c))}var dH=St;function Bl(c,f,g){var S=c.length;return g=g===n?S:g,!f&&g>=S?c:Fi(c,f,g)}var RS=Jj||function(c){return Ur.clearTimeout(c)};function OS(c,f){if(f)return c.slice();var g=c.length,S=tS?tS(g):new c.constructor(g);return c.copy(S),S}function k5(c){var f=new c.constructor(c.byteLength);return new jp(f).set(new jp(c)),f}function hH(c,f){var g=f?k5(c.buffer):c.buffer;return new c.constructor(g,c.byteOffset,c.byteLength)}function pH(c){var f=new c.constructor(c.source,B.exec(c));return f.lastIndex=c.lastIndex,f}function mH(c){return N1?fn(N1.call(c)):{}}function DS(c,f){var g=f?k5(c.buffer):c.buffer;return new c.constructor(g,c.byteOffset,c.length)}function PS(c,f){if(c!==f){var g=c!==n,S=c===null,N=c===c,M=li(c),V=f!==n,Z=f===null,re=f===f,be=li(f);if(!Z&&!be&&!M&&c>f||M&&V&&re&&!Z&&!be||S&&V&&re||!g&&re||!N)return 1;if(!S&&!M&&!be&&c<f||be&&g&&N&&!S&&!M||Z&&g&&N||!V&&N||!re)return-1}return 0}function gH(c,f,g){for(var S=-1,N=c.criteria,M=f.criteria,V=N.length,Z=g.length;++S<V;){var re=PS(N[S],M[S]);if(re){if(S>=Z)return re;var be=g[S];return re*(be=="desc"?-1:1)}}return c.index-f.index}function MS(c,f,g,S){for(var N=-1,M=c.length,V=g.length,Z=-1,re=f.length,be=_r(M-V,0),Ee=de(re+be),ke=!S;++Z<re;)Ee[Z]=f[Z];for(;++N<V;)(ke||N<M)&&(Ee[g[N]]=c[N]);for(;be--;)Ee[Z++]=c[N++];return Ee}function LS(c,f,g,S){for(var N=-1,M=c.length,V=-1,Z=g.length,re=-1,be=f.length,Ee=_r(M-Z,0),ke=de(Ee+be),Re=!S;++N<Ee;)ke[N]=c[N];for(var qe=N;++re<be;)ke[qe+re]=f[re];for(;++V<Z;)(Re||N<M)&&(ke[qe+g[V]]=c[N++]);return ke}function Mo(c,f){var g=-1,S=c.length;for(f||(f=de(S));++g<S;)f[g]=c[g];return f}function Oa(c,f,g,S){var N=!g;g||(g={});for(var M=-1,V=f.length;++M<V;){var Z=f[M],re=S?S(g[Z],c[Z],Z,g,c):n;re===n&&(re=c[Z]),N?xs(g,Z,re):F1(g,Z,re)}return g}function vH(c,f){return Oa(c,I5(c),f)}function bH(c,f){return Oa(c,XS(c),f)}function em(c,f){return function(g,S){var N=dt(g)?wj:zz,M=f?f():{};return N(g,c,nt(S,2),M)}}function ff(c){return St(function(f,g){var S=-1,N=g.length,M=N>1?g[N-1]:n,V=N>2?g[2]:n;for(M=c.length>3&&typeof M=="function"?(N--,M):n,V&&wo(g[0],g[1],V)&&(M=N<3?n:M,N=1),f=fn(f);++S<N;){var Z=g[S];Z&&c(f,Z,S,M)}return f})}function jS(c,f){return function(g,S){if(g==null)return g;if(!Lo(g))return c(g,S);for(var N=g.length,M=f?N:-1,V=fn(g);(f?M--:++M<N)&&S(V[M],M,V)!==!1;);return g}}function zS(c){return function(f,g,S){for(var N=-1,M=fn(f),V=S(f),Z=V.length;Z--;){var re=V[c?Z:++N];if(g(M[re],re,M)===!1)break}return f}}function yH(c,f,g){var S=f&b,N=D1(c);function M(){var V=this&&this!==Ur&&this instanceof M?N:c;return V.apply(S?g:this,arguments)}return M}function HS(c){return function(f){f=Jt(f);var g=rf(f)?ia(f):n,S=g?g[0]:f.charAt(0),N=g?Bl(g,1).join(""):f.slice(1);return S[c]()+N}}function df(c){return function(f){return Yy(j8(L8(f).replace(uj,"")),c,"")}}function D1(c){return function(){var f=arguments;switch(f.length){case 0:return new c;case 1:return new c(f[0]);case 2:return new c(f[0],f[1]);case 3:return new c(f[0],f[1],f[2]);case 4:return new c(f[0],f[1],f[2],f[3]);case 5:return new c(f[0],f[1],f[2],f[3],f[4]);case 6:return new c(f[0],f[1],f[2],f[3],f[4],f[5]);case 7:return new c(f[0],f[1],f[2],f[3],f[4],f[5],f[6])}var g=cf(c.prototype),S=c.apply(g,f);return jn(S)?S:g}}function EH(c,f,g){var S=D1(c);function N(){for(var M=arguments.length,V=de(M),Z=M,re=hf(N);Z--;)V[Z]=arguments[Z];var be=M<3&&V[0]!==re&&V[M-1]!==re?[]:Cl(V,re);if(M-=be.length,M<g)return GS(c,f,tm,N.placeholder,n,V,be,n,n,g-M);var Ee=this&&this!==Ur&&this instanceof N?S:c;return ii(Ee,this,V)}return N}function US(c){return function(f,g,S){var N=fn(f);if(!Lo(f)){var M=nt(g,3);f=Ir(f),g=function(Z){return M(N[Z],Z,N)}}var V=c(f,g,S);return V>-1?N[M?f[V]:V]:n}}function qS(c){return As(function(f){var g=f.length,S=g,N=Ai.prototype.thru;for(c&&f.reverse();S--;){var M=f[S];if(typeof M!="function")throw new Ci(a);if(N&&!V&&im(M)=="wrapper")var V=new Ai([],!0)}for(S=V?S:g;++S<g;){M=f[S];var Z=im(M),re=Z=="wrapper"?N5(M):n;re&&R5(re[0])&&re[1]==(A|k|F|P)&&!re[4].length&&re[9]==1?V=V[im(re[0])].apply(V,re[3]):V=M.length==1&&R5(M)?V[Z]():V.thru(M)}return function(){var be=arguments,Ee=be[0];if(V&&be.length==1&&dt(Ee))return V.plant(Ee).value();for(var ke=0,Re=g?f[ke].apply(this,be):Ee;++ke<g;)Re=f[ke].call(this,Re);return Re}})}function tm(c,f,g,S,N,M,V,Z,re,be){var Ee=f&A,ke=f&b,Re=f&E,qe=f&(k|y),ot=f&I,Tt=Re?n:D1(c);function it(){for(var Ft=arguments.length,Lt=de(Ft),ui=Ft;ui--;)Lt[ui]=arguments[ui];if(qe)var ko=hf(it),ci=Bj(Lt,ko);if(S&&(Lt=MS(Lt,S,N,qe)),M&&(Lt=LS(Lt,M,V,qe)),Ft-=ci,qe&&Ft<be){var ir=Cl(Lt,ko);return GS(c,f,tm,it.placeholder,g,Lt,ir,Z,re,be-Ft)}var la=ke?g:this,Bs=Re?la[c]:c;return Ft=Lt.length,Z?Lt=zH(Lt,Z):ot&&Ft>1&&Lt.reverse(),Ee&&re<Ft&&(Lt.length=re),this&&this!==Ur&&this instanceof it&&(Bs=Tt||D1(Bs)),Bs.apply(la,Lt)}return it}function $S(c,f){return function(g,S){return Vz(g,c,f(S),{})}}function nm(c,f){return function(g,S){var N;if(g===n&&S===n)return f;if(g!==n&&(N=g),S!==n){if(N===n)return S;typeof g=="string"||typeof S=="string"?(g=si(g),S=si(S)):(g=NS(g),S=NS(S)),N=c(g,S)}return N}}function S5(c){return As(function(f){return f=Bn(f,ai(nt())),St(function(g){var S=this;return c(f,function(N){return ii(N,S,g)})})})}function rm(c,f){f=f===n?" ":si(f);var g=f.length;if(g<2)return g?b5(f,c):f;var S=b5(f,qp(c/of(f)));return rf(f)?Bl(ia(S),0,c).join(""):S.slice(0,c)}function _H(c,f,g,S){var N=f&b,M=D1(c);function V(){for(var Z=-1,re=arguments.length,be=-1,Ee=S.length,ke=de(Ee+re),Re=this&&this!==Ur&&this instanceof V?M:c;++be<Ee;)ke[be]=S[be];for(;re--;)ke[be++]=arguments[++Z];return ii(Re,N?g:this,ke)}return V}function WS(c){return function(f,g,S){return S&&typeof S!="number"&&wo(f,g,S)&&(g=S=n),f=Is(f),g===n?(g=f,f=0):g=Is(g),S=S===n?f<g?1:-1:Is(S),aH(f,g,S,c)}}function om(c){return function(f,g){return typeof f=="string"&&typeof g=="string"||(f=Bi(f),g=Bi(g)),c(f,g)}}function GS(c,f,g,S,N,M,V,Z,re,be){var Ee=f&k,ke=Ee?V:n,Re=Ee?n:V,qe=Ee?M:n,ot=Ee?n:M;f|=Ee?F:C,f&=~(Ee?C:F),f&w||(f&=~(b|E));var Tt=[c,f,N,qe,ke,ot,Re,Z,re,be],it=g.apply(n,Tt);return R5(c)&&o8(it,Tt),it.placeholder=S,i8(it,c,f)}function x5(c){var f=Er[c];return function(g,S){if(g=Bi(g),S=S==null?0:no(bt(S),292),S&&iS(g)){var N=(Jt(g)+"e").split("e"),M=f(N[0]+"e"+(+N[1]+S));return N=(Jt(M)+"e").split("e"),+(N[0]+"e"+(+N[1]-S))}return f(g)}}var TH=lf&&1/Rp(new lf([,-0]))[1]==$?function(c){return new lf(c)}:V5;function KS(c){return function(f){var g=ro(f);return g==In?n5(f):g==pn?jj(f):Ij(f,c(f))}}function Cs(c,f,g,S,N,M,V,Z){var re=f&E;if(!re&&typeof c!="function")throw new Ci(a);var be=S?S.length:0;if(be||(f&=~(F|C),S=N=n),V=V===n?V:_r(bt(V),0),Z=Z===n?Z:bt(Z),be-=N?N.length:0,f&C){var Ee=S,ke=N;S=N=n}var Re=re?n:N5(c),qe=[c,f,g,S,N,Ee,ke,M,V,Z];if(Re&&MH(qe,Re),c=qe[0],f=qe[1],g=qe[2],S=qe[3],N=qe[4],Z=qe[9]=qe[9]===n?re?0:c.length:_r(qe[9]-be,0),!Z&&f&(k|y)&&(f&=~(k|y)),!f||f==b)var ot=yH(c,f,g);else f==k||f==y?ot=EH(c,f,Z):(f==F||f==(b|F))&&!N.length?ot=_H(c,f,g,S):ot=tm.apply(n,qe);var Tt=Re?CS:o8;return i8(Tt(ot,qe),c,f)}function VS(c,f,g,S){return c===n||sa(c,sf[g])&&!tn.call(S,g)?f:c}function YS(c,f,g,S,N,M){return jn(c)&&jn(f)&&(M.set(f,c),Xp(c,f,n,YS,M),M.delete(f)),c}function wH(c){return L1(c)?n:c}function QS(c,f,g,S,N,M){var V=g&v,Z=c.length,re=f.length;if(Z!=re&&!(V&&re>Z))return!1;var be=M.get(c),Ee=M.get(f);if(be&&Ee)return be==f&&Ee==c;var ke=-1,Re=!0,qe=g&_?new Yu:n;for(M.set(c,f),M.set(f,c);++ke<Z;){var ot=c[ke],Tt=f[ke];if(S)var it=V?S(Tt,ot,ke,f,c,M):S(ot,Tt,ke,c,f,M);if(it!==n){if(it)continue;Re=!1;break}if(qe){if(!Qy(f,function(Ft,Lt){if(!k1(qe,Lt)&&(ot===Ft||N(ot,Ft,g,S,M)))return qe.push(Lt)})){Re=!1;break}}else if(!(ot===Tt||N(ot,Tt,g,S,M))){Re=!1;break}}return M.delete(c),M.delete(f),Re}function kH(c,f,g,S,N,M,V){switch(g){case G:if(c.byteLength!=f.byteLength||c.byteOffset!=f.byteOffset)return!1;c=c.buffer,f=f.buffer;case ie:return!(c.byteLength!=f.byteLength||!M(new jp(c),new jp(f)));case We:case rt:case br:return sa(+c,+f);case qn:return c.name==f.name&&c.message==f.message;case jr:case Mn:return c==f+"";case In:var Z=n5;case pn:var re=S&v;if(Z||(Z=Rp),c.size!=f.size&&!re)return!1;var be=V.get(c);if(be)return be==f;S|=_,V.set(c,f);var Ee=QS(Z(c),Z(f),S,N,M,V);return V.delete(c),Ee;case mn:if(N1)return N1.call(c)==N1.call(f)}return!1}function SH(c,f,g,S,N,M){var V=g&v,Z=C5(c),re=Z.length,be=C5(f),Ee=be.length;if(re!=Ee&&!V)return!1;for(var ke=re;ke--;){var Re=Z[ke];if(!(V?Re in f:tn.call(f,Re)))return!1}var qe=M.get(c),ot=M.get(f);if(qe&&ot)return qe==f&&ot==c;var Tt=!0;M.set(c,f),M.set(f,c);for(var it=V;++ke<re;){Re=Z[ke];var Ft=c[Re],Lt=f[Re];if(S)var ui=V?S(Lt,Ft,Re,f,c,M):S(Ft,Lt,Re,c,f,M);if(!(ui===n?Ft===Lt||N(Ft,Lt,g,S,M):ui)){Tt=!1;break}it||(it=Re=="constructor")}if(Tt&&!it){var ko=c.constructor,ci=f.constructor;ko!=ci&&"constructor"in c&&"constructor"in f&&!(typeof ko=="function"&&ko instanceof ko&&typeof ci=="function"&&ci instanceof ci)&&(Tt=!1)}return M.delete(c),M.delete(f),Tt}function As(c){return D5(n8(c,n,f8),c+"")}function C5(c){return gS(c,Ir,I5)}function A5(c){return gS(c,jo,XS)}var N5=Wp?function(c){return Wp.get(c)}:V5;function im(c){for(var f=c.name+"",g=uf[f],S=tn.call(uf,f)?g.length:0;S--;){var N=g[S],M=N.func;if(M==null||M==c)return N.name}return f}function hf(c){var f=tn.call(D,"placeholder")?D:c;return f.placeholder}function nt(){var c=D.iteratee||G5;return c=c===G5?yS:c,arguments.length?c(arguments[0],arguments[1]):c}function am(c,f){var g=c.__data__;return RH(f)?g[typeof f=="string"?"string":"hash"]:g.map}function F5(c){for(var f=Ir(c),g=f.length;g--;){var S=f[g],N=c[S];f[g]=[S,N,e8(N)]}return f}function Zu(c,f){var g=Pj(c,f);return bS(g)?g:n}function xH(c){var f=tn.call(c,Ku),g=c[Ku];try{c[Ku]=n;var S=!0}catch{}var N=Mp.call(c);return S&&(f?c[Ku]=g:delete c[Ku]),N}var I5=o5?function(c){return c==null?[]:(c=fn(c),Sl(o5(c),function(f){return rS.call(c,f)}))}:Y5,XS=o5?function(c){for(var f=[];c;)xl(f,I5(c)),c=zp(c);return f}:Y5,ro=To;(i5&&ro(new i5(new ArrayBuffer(1)))!=G||x1&&ro(new x1)!=In||a5&&ro(a5.resolve())!=yo||lf&&ro(new lf)!=pn||C1&&ro(new C1)!=me)&&(ro=function(c){var f=To(c),g=f==an?c.constructor:n,S=g?Ju(g):"";if(S)switch(S){case lz:return G;case uz:return In;case cz:return yo;case fz:return pn;case dz:return me}return f});function CH(c,f,g){for(var S=-1,N=g.length;++S<N;){var M=g[S],V=M.size;switch(M.type){case"drop":c+=V;break;case"dropRight":f-=V;break;case"take":f=no(f,c+V);break;case"takeRight":c=_r(c,f-V);break}}return{start:c,end:f}}function AH(c){var f=c.match(Zc);return f?f[1].split(zu):[]}function ZS(c,f,g){f=Il(f,c);for(var S=-1,N=f.length,M=!1;++S<N;){var V=Da(f[S]);if(!(M=c!=null&&g(c,V)))break;c=c[V]}return M||++S!=N?M:(N=c==null?0:c.length,!!N&&hm(N)&&Ns(V,N)&&(dt(c)||ec(c)))}function NH(c){var f=c.length,g=new c.constructor(f);return f&&typeof c[0]=="string"&&tn.call(c,"index")&&(g.index=c.index,g.input=c.input),g}function JS(c){return typeof c.constructor=="function"&&!P1(c)?cf(zp(c)):{}}function FH(c,f,g){var S=c.constructor;switch(f){case ie:return k5(c);case We:case rt:return new S(+c);case G:return hH(c,g);case ae:case Te:case Oe:case $e:case _t:case Qe:case lt:case Kt:case Pt:return DS(c,g);case In:return new S;case br:case Mn:return new S(c);case jr:return pH(c);case pn:return new S;case mn:return mH(c)}}function IH(c,f){var g=f.length;if(!g)return c;var S=g-1;return f[S]=(g>1?"& ":"")+f[S],f=f.join(g>2?", ":" "),c.replace(Xc,`{ /* [wrapped with `+f+`] */ `)}function BH(c){return dt(c)||ec(c)||!!(oS&&c&&c[oS])}function Ns(c,f){var g=typeof c;return f=f??_e,!!f&&(g=="number"||g!="symbol"&&te.test(c))&&c>-1&&c%1==0&&c<f}function wo(c,f,g){if(!jn(g))return!1;var S=typeof f;return(S=="number"?Lo(g)&&Ns(f,g.length):S=="string"&&f in g)?sa(g[f],c):!1}function B5(c,f){if(dt(c))return!1;var g=typeof c;return g=="number"||g=="symbol"||g=="boolean"||c==null||li(c)?!0:_o.test(c)||!Fr.test(c)||f!=null&&c in fn(f)}function RH(c){var f=typeof c;return f=="string"||f=="number"||f=="symbol"||f=="boolean"?c!=="__proto__":c===null}function R5(c){var f=im(c),g=D[f];if(typeof g!="function"||!(f in Rt.prototype))return!1;if(c===g)return!0;var S=N5(g);return!!S&&c===S[0]}function OH(c){return!!eS&&eS in c}var DH=Dp?Fs:Q5;function P1(c){var f=c&&c.constructor,g=typeof f=="function"&&f.prototype||sf;return c===g}function e8(c){return c===c&&!jn(c)}function t8(c,f){return function(g){return g==null?!1:g[c]===f&&(f!==n||c in fn(g))}}function PH(c){var f=fm(c,function(S){return g.size===u&&g.clear(),S}),g=f.cache;return f}function MH(c,f){var g=c[1],S=f[1],N=g|S,M=N<(b|E|A),V=S==A&&g==k||S==A&&g==P&&c[7].length<=f[8]||S==(A|P)&&f[7].length<=f[8]&&g==k;if(!(M||V))return c;S&b&&(c[2]=f[2],N|=g&b?0:w);var Z=f[3];if(Z){var re=c[3];c[3]=re?MS(re,Z,f[4]):Z,c[4]=re?Cl(c[3],d):f[4]}return Z=f[5],Z&&(re=c[5],c[5]=re?LS(re,Z,f[6]):Z,c[6]=re?Cl(c[5],d):f[6]),Z=f[7],Z&&(c[7]=Z),S&A&&(c[8]=c[8]==null?f[8]:no(c[8],f[8])),c[9]==null&&(c[9]=f[9]),c[0]=f[0],c[1]=N,c}function LH(c){var f=[];if(c!=null)for(var g in fn(c))f.push(g);return f}function jH(c){return Mp.call(c)}function n8(c,f,g){return f=_r(f===n?c.length-1:f,0),function(){for(var S=arguments,N=-1,M=_r(S.length-f,0),V=de(M);++N<M;)V[N]=S[f+N];N=-1;for(var Z=de(f+1);++N<f;)Z[N]=S[N];return Z[f]=g(V),ii(c,this,Z)}}function r8(c,f){return f.length<2?c:Xu(c,Fi(f,0,-1))}function zH(c,f){for(var g=c.length,S=no(f.length,g),N=Mo(c);S--;){var M=f[S];c[S]=Ns(M,g)?N[M]:n}return c}function O5(c,f){if(!(f==="constructor"&&typeof c[f]=="function")&&f!="__proto__")return c[f]}var o8=a8(CS),M1=tz||function(c,f){return Ur.setTimeout(c,f)},D5=a8(uH);function i8(c,f,g){var S=f+"";return D5(c,IH(S,HH(AH(S),g)))}function a8(c){var f=0,g=0;return function(){var S=iz(),N=U-(S-g);if(g=S,N>0){if(++f>=K)return arguments[0]}else f=0;return c.apply(n,arguments)}}function sm(c,f){var g=-1,S=c.length,N=S-1;for(f=f===n?S:f;++g<f;){var M=v5(g,N),V=c[M];c[M]=c[g],c[g]=V}return c.length=f,c}var s8=PH(function(c){var f=[];return c.charCodeAt(0)===46&&f.push(""),c.replace(Ia,function(g,S,N,M){f.push(N?M.replace(W,"$1"):S||g)}),f});function Da(c){if(typeof c=="string"||li(c))return c;var f=c+"";return f=="0"&&1/c==-$?"-0":f}function Ju(c){if(c!=null){try{return Pp.call(c)}catch{}try{return c+""}catch{}}return""}function HH(c,f){return xi(Ue,function(g){var S="_."+g[0];f&g[1]&&!Ip(c,S)&&c.push(S)}),c.sort()}function l8(c){if(c instanceof Rt)return c.clone();var f=new Ai(c.__wrapped__,c.__chain__);return f.__actions__=Mo(c.__actions__),f.__index__=c.__index__,f.__values__=c.__values__,f}function UH(c,f,g){(g?wo(c,f,g):f===n)?f=1:f=_r(bt(f),0);var S=c==null?0:c.length;if(!S||f<1)return[];for(var N=0,M=0,V=de(qp(S/f));N<S;)V[M++]=Fi(c,N,N+=f);return V}function qH(c){for(var f=-1,g=c==null?0:c.length,S=0,N=[];++f<g;){var M=c[f];M&&(N[S++]=M)}return N}function $H(){var c=arguments.length;if(!c)return[];for(var f=de(c-1),g=arguments[0],S=c;S--;)f[S-1]=arguments[S];return xl(dt(g)?Mo(g):[g],qr(f,1))}var WH=St(function(c,f){return or(c)?I1(c,qr(f,1,or,!0)):[]}),GH=St(function(c,f){var g=Ii(f);return or(g)&&(g=n),or(c)?I1(c,qr(f,1,or,!0),nt(g,2)):[]}),KH=St(function(c,f){var g=Ii(f);return or(g)&&(g=n),or(c)?I1(c,qr(f,1,or,!0),n,g):[]});function VH(c,f,g){var S=c==null?0:c.length;return S?(f=g||f===n?1:bt(f),Fi(c,f<0?0:f,S)):[]}function YH(c,f,g){var S=c==null?0:c.length;return S?(f=g||f===n?1:bt(f),f=S-f,Fi(c,0,f<0?0:f)):[]}function QH(c,f){return c&&c.length?Jp(c,nt(f,3),!0,!0):[]}function XH(c,f){return c&&c.length?Jp(c,nt(f,3),!0):[]}function ZH(c,f,g,S){var N=c==null?0:c.length;return N?(g&&typeof g!="number"&&wo(c,f,g)&&(g=0,S=N),$z(c,f,g,S)):[]}function u8(c,f,g){var S=c==null?0:c.length;if(!S)return-1;var N=g==null?0:bt(g);return N<0&&(N=_r(S+N,0)),Bp(c,nt(f,3),N)}function c8(c,f,g){var S=c==null?0:c.length;if(!S)return-1;var N=S-1;return g!==n&&(N=bt(g),N=g<0?_r(S+N,0):no(N,S-1)),Bp(c,nt(f,3),N,!0)}function f8(c){var f=c==null?0:c.length;return f?qr(c,1):[]}function JH(c){var f=c==null?0:c.length;return f?qr(c,$):[]}function eU(c,f){var g=c==null?0:c.length;return g?(f=f===n?1:bt(f),qr(c,f)):[]}function tU(c){for(var f=-1,g=c==null?0:c.length,S={};++f<g;){var N=c[f];S[N[0]]=N[1]}return S}function d8(c){return c&&c.length?c[0]:n}function nU(c,f,g){var S=c==null?0:c.length;if(!S)return-1;var N=g==null?0:bt(g);return N<0&&(N=_r(S+N,0)),nf(c,f,N)}function rU(c){var f=c==null?0:c.length;return f?Fi(c,0,-1):[]}var oU=St(function(c){var f=Bn(c,T5);return f.length&&f[0]===c[0]?d5(f):[]}),iU=St(function(c){var f=Ii(c),g=Bn(c,T5);return f===Ii(g)?f=n:g.pop(),g.length&&g[0]===c[0]?d5(g,nt(f,2)):[]}),aU=St(function(c){var f=Ii(c),g=Bn(c,T5);return f=typeof f=="function"?f:n,f&&g.pop(),g.length&&g[0]===c[0]?d5(g,n,f):[]});function sU(c,f){return c==null?"":rz.call(c,f)}function Ii(c){var f=c==null?0:c.length;return f?c[f-1]:n}function lU(c,f,g){var S=c==null?0:c.length;if(!S)return-1;var N=S;return g!==n&&(N=bt(g),N=N<0?_r(S+N,0):no(N,S-1)),f===f?Hj(c,f,N):Bp(c,Gk,N,!0)}function uU(c,f){return c&&c.length?wS(c,bt(f)):n}var cU=St(h8);function h8(c,f){return c&&c.length&&f&&f.length?g5(c,f):c}function fU(c,f,g){return c&&c.length&&f&&f.length?g5(c,f,nt(g,2)):c}function dU(c,f,g){return c&&c.length&&f&&f.length?g5(c,f,n,g):c}var hU=As(function(c,f){var g=c==null?0:c.length,S=l5(c,f);return xS(c,Bn(f,function(N){return Ns(N,g)?+N:N}).sort(PS)),S});function pU(c,f){var g=[];if(!(c&&c.length))return g;var S=-1,N=[],M=c.length;for(f=nt(f,3);++S<M;){var V=c[S];f(V,S,c)&&(g.push(V),N.push(S))}return xS(c,N),g}function P5(c){return c==null?c:sz.call(c)}function mU(c,f,g){var S=c==null?0:c.length;return S?(g&&typeof g!="number"&&wo(c,f,g)?(f=0,g=S):(f=f==null?0:bt(f),g=g===n?S:bt(g)),Fi(c,f,g)):[]}function gU(c,f){return Zp(c,f)}function vU(c,f,g){return y5(c,f,nt(g,2))}function bU(c,f){var g=c==null?0:c.length;if(g){var S=Zp(c,f);if(S<g&&sa(c[S],f))return S}return-1}function yU(c,f){return Zp(c,f,!0)}function EU(c,f,g){return y5(c,f,nt(g,2),!0)}function _U(c,f){var g=c==null?0:c.length;if(g){var S=Zp(c,f,!0)-1;if(sa(c[S],f))return S}return-1}function TU(c){return c&&c.length?AS(c):[]}function wU(c,f){return c&&c.length?AS(c,nt(f,2)):[]}function kU(c){var f=c==null?0:c.length;return f?Fi(c,1,f):[]}function SU(c,f,g){return c&&c.length?(f=g||f===n?1:bt(f),Fi(c,0,f<0?0:f)):[]}function xU(c,f,g){var S=c==null?0:c.length;return S?(f=g||f===n?1:bt(f),f=S-f,Fi(c,f<0?0:f,S)):[]}function CU(c,f){return c&&c.length?Jp(c,nt(f,3),!1,!0):[]}function AU(c,f){return c&&c.length?Jp(c,nt(f,3)):[]}var NU=St(function(c){return Fl(qr(c,1,or,!0))}),FU=St(function(c){var f=Ii(c);return or(f)&&(f=n),Fl(qr(c,1,or,!0),nt(f,2))}),IU=St(function(c){var f=Ii(c);return f=typeof f=="function"?f:n,Fl(qr(c,1,or,!0),n,f)});function BU(c){return c&&c.length?Fl(c):[]}function RU(c,f){return c&&c.length?Fl(c,nt(f,2)):[]}function OU(c,f){return f=typeof f=="function"?f:n,c&&c.length?Fl(c,n,f):[]}function M5(c){if(!(c&&c.length))return[];var f=0;return c=Sl(c,function(g){if(or(g))return f=_r(g.length,f),!0}),e5(f,function(g){return Bn(c,Xy(g))})}function p8(c,f){if(!(c&&c.length))return[];var g=M5(c);return f==null?g:Bn(g,function(S){return ii(f,n,S)})}var DU=St(function(c,f){return or(c)?I1(c,f):[]}),PU=St(function(c){return _5(Sl(c,or))}),MU=St(function(c){var f=Ii(c);return or(f)&&(f=n),_5(Sl(c,or),nt(f,2))}),LU=St(function(c){var f=Ii(c);return f=typeof f=="function"?f:n,_5(Sl(c,or),n,f)}),jU=St(M5);function zU(c,f){return BS(c||[],f||[],F1)}function HU(c,f){return BS(c||[],f||[],O1)}var UU=St(function(c){var f=c.length,g=f>1?c[f-1]:n;return g=typeof g=="function"?(c.pop(),g):n,p8(c,g)});function m8(c){var f=D(c);return f.__chain__=!0,f}function qU(c,f){return f(c),c}function lm(c,f){return f(c)}var $U=As(function(c){var f=c.length,g=f?c[0]:0,S=this.__wrapped__,N=function(M){return l5(M,c)};return f>1||this.__actions__.length||!(S instanceof Rt)||!Ns(g)?this.thru(N):(S=S.slice(g,+g+(f?1:0)),S.__actions__.push({func:lm,args:[N],thisArg:n}),new Ai(S,this.__chain__).thru(function(M){return f&&!M.length&&M.push(n),M}))});function WU(){return m8(this)}function GU(){return new Ai(this.value(),this.__chain__)}function KU(){this.__values__===n&&(this.__values__=N8(this.value()));var c=this.__index__>=this.__values__.length,f=c?n:this.__values__[this.__index__++];return{done:c,value:f}}function VU(){return this}function YU(c){for(var f,g=this;g instanceof Kp;){var S=l8(g);S.__index__=0,S.__values__=n,f?N.__wrapped__=S:f=S;var N=S;g=g.__wrapped__}return N.__wrapped__=c,f}function QU(){var c=this.__wrapped__;if(c instanceof Rt){var f=c;return this.__actions__.length&&(f=new Rt(this)),f=f.reverse(),f.__actions__.push({func:lm,args:[P5],thisArg:n}),new Ai(f,this.__chain__)}return this.thru(P5)}function XU(){return IS(this.__wrapped__,this.__actions__)}var ZU=em(function(c,f,g){tn.call(c,g)?++c[g]:xs(c,g,1)});function JU(c,f,g){var S=dt(c)?$k:qz;return g&&wo(c,f,g)&&(f=n),S(c,nt(f,3))}function eq(c,f){var g=dt(c)?Sl:pS;return g(c,nt(f,3))}var tq=US(u8),nq=US(c8);function rq(c,f){return qr(um(c,f),1)}function oq(c,f){return qr(um(c,f),$)}function iq(c,f,g){return g=g===n?1:bt(g),qr(um(c,f),g)}function g8(c,f){var g=dt(c)?xi:Nl;return g(c,nt(f,3))}function v8(c,f){var g=dt(c)?kj:hS;return g(c,nt(f,3))}var aq=em(function(c,f,g){tn.call(c,g)?c[g].push(f):xs(c,g,[f])});function sq(c,f,g,S){c=Lo(c)?c:mf(c),g=g&&!S?bt(g):0;var N=c.length;return g<0&&(g=_r(N+g,0)),pm(c)?g<=N&&c.indexOf(f,g)>-1:!!N&&nf(c,f,g)>-1}var lq=St(function(c,f,g){var S=-1,N=typeof f=="function",M=Lo(c)?de(c.length):[];return Nl(c,function(V){M[++S]=N?ii(f,V,g):B1(V,f,g)}),M}),uq=em(function(c,f,g){xs(c,g,f)});function um(c,f){var g=dt(c)?Bn:ES;return g(c,nt(f,3))}function cq(c,f,g,S){return c==null?[]:(dt(f)||(f=f==null?[]:[f]),g=S?n:g,dt(g)||(g=g==null?[]:[g]),kS(c,f,g))}var fq=em(function(c,f,g){c[g?0:1].push(f)},function(){return[[],[]]});function dq(c,f,g){var S=dt(c)?Yy:Vk,N=arguments.length<3;return S(c,nt(f,4),g,N,Nl)}function hq(c,f,g){var S=dt(c)?Sj:Vk,N=arguments.length<3;return S(c,nt(f,4),g,N,hS)}function pq(c,f){var g=dt(c)?Sl:pS;return g(c,dm(nt(f,3)))}function mq(c){var f=dt(c)?uS:sH;return f(c)}function gq(c,f,g){(g?wo(c,f,g):f===n)?f=1:f=bt(f);var S=dt(c)?Lz:lH;return S(c,f)}function vq(c){var f=dt(c)?jz:cH;return f(c)}function bq(c){if(c==null)return 0;if(Lo(c))return pm(c)?of(c):c.length;var f=ro(c);return f==In||f==pn?c.size:p5(c).length}function yq(c,f,g){var S=dt(c)?Qy:fH;return g&&wo(c,f,g)&&(f=n),S(c,nt(f,3))}var Eq=St(function(c,f){if(c==null)return[];var g=f.length;return g>1&&wo(c,f[0],f[1])?f=[]:g>2&&wo(f[0],f[1],f[2])&&(f=[f[0]]),kS(c,qr(f,1),[])}),cm=ez||function(){return Ur.Date.now()};function _q(c,f){if(typeof f!="function")throw new Ci(a);return c=bt(c),function(){if(--c<1)return f.apply(this,arguments)}}function b8(c,f,g){return f=g?n:f,f=c&&f==null?c.length:f,Cs(c,A,n,n,n,n,f)}function y8(c,f){var g;if(typeof f!="function")throw new Ci(a);return c=bt(c),function(){return--c>0&&(g=f.apply(this,arguments)),c<=1&&(f=n),g}}var L5=St(function(c,f,g){var S=b;if(g.length){var N=Cl(g,hf(L5));S|=F}return Cs(c,S,f,g,N)}),E8=St(function(c,f,g){var S=b|E;if(g.length){var N=Cl(g,hf(E8));S|=F}return Cs(f,S,c,g,N)});function _8(c,f,g){f=g?n:f;var S=Cs(c,k,n,n,n,n,n,f);return S.placeholder=_8.placeholder,S}function T8(c,f,g){f=g?n:f;var S=Cs(c,y,n,n,n,n,n,f);return S.placeholder=T8.placeholder,S}function w8(c,f,g){var S,N,M,V,Z,re,be=0,Ee=!1,ke=!1,Re=!0;if(typeof c!="function")throw new Ci(a);f=Bi(f)||0,jn(g)&&(Ee=!!g.leading,ke="maxWait"in g,M=ke?_r(Bi(g.maxWait)||0,f):M,Re="trailing"in g?!!g.trailing:Re);function qe(ir){var la=S,Bs=N;return S=N=n,be=ir,V=c.apply(Bs,la),V}function ot(ir){return be=ir,Z=M1(Ft,f),Ee?qe(ir):V}function Tt(ir){var la=ir-re,Bs=ir-be,U8=f-la;return ke?no(U8,M-Bs):U8}function it(ir){var la=ir-re,Bs=ir-be;return re===n||la>=f||la<0||ke&&Bs>=M}function Ft(){var ir=cm();if(it(ir))return Lt(ir);Z=M1(Ft,Tt(ir))}function Lt(ir){return Z=n,Re&&S?qe(ir):(S=N=n,V)}function ui(){Z!==n&&RS(Z),be=0,S=re=N=Z=n}function ko(){return Z===n?V:Lt(cm())}function ci(){var ir=cm(),la=it(ir);if(S=arguments,N=this,re=ir,la){if(Z===n)return ot(re);if(ke)return RS(Z),Z=M1(Ft,f),qe(re)}return Z===n&&(Z=M1(Ft,f)),V}return ci.cancel=ui,ci.flush=ko,ci}var Tq=St(function(c,f){return dS(c,1,f)}),wq=St(function(c,f,g){return dS(c,Bi(f)||0,g)});function kq(c){return Cs(c,I)}function fm(c,f){if(typeof c!="function"||f!=null&&typeof f!="function")throw new Ci(a);var g=function(){var S=arguments,N=f?f.apply(this,S):S[0],M=g.cache;if(M.has(N))return M.get(N);var V=c.apply(this,S);return g.cache=M.set(N,V)||M,V};return g.cache=new(fm.Cache||Ss),g}fm.Cache=Ss;function dm(c){if(typeof c!="function")throw new Ci(a);return function(){var f=arguments;switch(f.length){case 0:return!c.call(this);case 1:return!c.call(this,f[0]);case 2:return!c.call(this,f[0],f[1]);case 3:return!c.call(this,f[0],f[1],f[2])}return!c.apply(this,f)}}function Sq(c){return y8(2,c)}var xq=dH(function(c,f){f=f.length==1&&dt(f[0])?Bn(f[0],ai(nt())):Bn(qr(f,1),ai(nt()));var g=f.length;return St(function(S){for(var N=-1,M=no(S.length,g);++N<M;)S[N]=f[N].call(this,S[N]);return ii(c,this,S)})}),j5=St(function(c,f){var g=Cl(f,hf(j5));return Cs(c,F,n,f,g)}),k8=St(function(c,f){var g=Cl(f,hf(k8));return Cs(c,C,n,f,g)}),Cq=As(function(c,f){return Cs(c,P,n,n,n,f)});function Aq(c,f){if(typeof c!="function")throw new Ci(a);return f=f===n?f:bt(f),St(c,f)}function Nq(c,f){if(typeof c!="function")throw new Ci(a);return f=f==null?0:_r(bt(f),0),St(function(g){var S=g[f],N=Bl(g,0,f);return S&&xl(N,S),ii(c,this,N)})}function Fq(c,f,g){var S=!0,N=!0;if(typeof c!="function")throw new Ci(a);return jn(g)&&(S="leading"in g?!!g.leading:S,N="trailing"in g?!!g.trailing:N),w8(c,f,{leading:S,maxWait:f,trailing:N})}function Iq(c){return b8(c,1)}function Bq(c,f){return j5(w5(f),c)}function Rq(){if(!arguments.length)return[];var c=arguments[0];return dt(c)?c:[c]}function Oq(c){return Ni(c,m)}function Dq(c,f){return f=typeof f=="function"?f:n,Ni(c,m,f)}function Pq(c){return Ni(c,h|m)}function Mq(c,f){return f=typeof f=="function"?f:n,Ni(c,h|m,f)}function Lq(c,f){return f==null||fS(c,f,Ir(f))}function sa(c,f){return c===f||c!==c&&f!==f}var jq=om(f5),zq=om(function(c,f){return c>=f}),ec=vS(function(){return arguments}())?vS:function(c){return $n(c)&&tn.call(c,"callee")&&!rS.call(c,"callee")},dt=de.isArray,Hq=Lk?ai(Lk):Yz;function Lo(c){return c!=null&&hm(c.length)&&!Fs(c)}function or(c){return $n(c)&&Lo(c)}function Uq(c){return c===!0||c===!1||$n(c)&&To(c)==We}var Rl=nz||Q5,qq=jk?ai(jk):Qz;function $q(c){return $n(c)&&c.nodeType===1&&!L1(c)}function Wq(c){if(c==null)return!0;if(Lo(c)&&(dt(c)||typeof c=="string"||typeof c.splice=="function"||Rl(c)||pf(c)||ec(c)))return!c.length;var f=ro(c);if(f==In||f==pn)return!c.size;if(P1(c))return!p5(c).length;for(var g in c)if(tn.call(c,g))return!1;return!0}function Gq(c,f){return R1(c,f)}function Kq(c,f,g){g=typeof g=="function"?g:n;var S=g?g(c,f):n;return S===n?R1(c,f,n,g):!!S}function z5(c){if(!$n(c))return!1;var f=To(c);return f==qn||f==Zt||typeof c.message=="string"&&typeof c.name=="string"&&!L1(c)}function Vq(c){return typeof c=="number"&&iS(c)}function Fs(c){if(!jn(c))return!1;var f=To(c);return f==er||f==tr||f==st||f==Eo}function S8(c){return typeof c=="number"&&c==bt(c)}function hm(c){return typeof c=="number"&&c>-1&&c%1==0&&c<=_e}function jn(c){var f=typeof c;return c!=null&&(f=="object"||f=="function")}function $n(c){return c!=null&&typeof c=="object"}var x8=zk?ai(zk):Zz;function Yq(c,f){return c===f||h5(c,f,F5(f))}function Qq(c,f,g){return g=typeof g=="function"?g:n,h5(c,f,F5(f),g)}function Xq(c){return C8(c)&&c!=+c}function Zq(c){if(DH(c))throw new ft(i);return bS(c)}function Jq(c){return c===null}function e$(c){return c==null}function C8(c){return typeof c=="number"||$n(c)&&To(c)==br}function L1(c){if(!$n(c)||To(c)!=an)return!1;var f=zp(c);if(f===null)return!0;var g=tn.call(f,"constructor")&&f.constructor;return typeof g=="function"&&g instanceof g&&Pp.call(g)==Qj}var H5=Hk?ai(Hk):Jz;function t$(c){return S8(c)&&c>=-_e&&c<=_e}var A8=Uk?ai(Uk):eH;function pm(c){return typeof c=="string"||!dt(c)&&$n(c)&&To(c)==Mn}function li(c){return typeof c=="symbol"||$n(c)&&To(c)==mn}var pf=qk?ai(qk):tH;function n$(c){return c===n}function r$(c){return $n(c)&&ro(c)==me}function o$(c){return $n(c)&&To(c)==le}var i$=om(m5),a$=om(function(c,f){return c<=f});function N8(c){if(!c)return[];if(Lo(c))return pm(c)?ia(c):Mo(c);if(S1&&c[S1])return Lj(c[S1]());var f=ro(c),g=f==In?n5:f==pn?Rp:mf;return g(c)}function Is(c){if(!c)return c===0?c:0;if(c=Bi(c),c===$||c===-$){var f=c<0?-1:1;return f*ve}return c===c?c:0}function bt(c){var f=Is(c),g=f%1;return f===f?g?f-g:f:0}function F8(c){return c?Qu(bt(c),0,R):0}function Bi(c){if(typeof c=="number")return c;if(li(c))return fe;if(jn(c)){var f=typeof c.valueOf=="function"?c.valueOf():c;c=jn(f)?f+"":f}if(typeof c!="string")return c===0?c:+c;c=Yk(c);var g=ee.test(c);return g||ce.test(c)?_j(c.slice(2),g?2:8):z.test(c)?fe:+c}function I8(c){return Oa(c,jo(c))}function s$(c){return c?Qu(bt(c),-_e,_e):c===0?c:0}function Jt(c){return c==null?"":si(c)}var l$=ff(function(c,f){if(P1(f)||Lo(f)){Oa(f,Ir(f),c);return}for(var g in f)tn.call(f,g)&&F1(c,g,f[g])}),B8=ff(function(c,f){Oa(f,jo(f),c)}),mm=ff(function(c,f,g,S){Oa(f,jo(f),c,S)}),u$=ff(function(c,f,g,S){Oa(f,Ir(f),c,S)}),c$=As(l5);function f$(c,f){var g=cf(c);return f==null?g:cS(g,f)}var d$=St(function(c,f){c=fn(c);var g=-1,S=f.length,N=S>2?f[2]:n;for(N&&wo(f[0],f[1],N)&&(S=1);++g<S;)for(var M=f[g],V=jo(M),Z=-1,re=V.length;++Z<re;){var be=V[Z],Ee=c[be];(Ee===n||sa(Ee,sf[be])&&!tn.call(c,be))&&(c[be]=M[be])}return c}),h$=St(function(c){return c.push(n,YS),ii(R8,n,c)});function p$(c,f){return Wk(c,nt(f,3),Ra)}function m$(c,f){return Wk(c,nt(f,3),c5)}function g$(c,f){return c==null?c:u5(c,nt(f,3),jo)}function v$(c,f){return c==null?c:mS(c,nt(f,3),jo)}function b$(c,f){return c&&Ra(c,nt(f,3))}function y$(c,f){return c&&c5(c,nt(f,3))}function E$(c){return c==null?[]:Qp(c,Ir(c))}function _$(c){return c==null?[]:Qp(c,jo(c))}function U5(c,f,g){var S=c==null?n:Xu(c,f);return S===n?g:S}function T$(c,f){return c!=null&&ZS(c,f,Wz)}function q5(c,f){return c!=null&&ZS(c,f,Gz)}var w$=$S(function(c,f,g){f!=null&&typeof f.toString!="function"&&(f=Mp.call(f)),c[f]=g},W5(zo)),k$=$S(function(c,f,g){f!=null&&typeof f.toString!="function"&&(f=Mp.call(f)),tn.call(c,f)?c[f].push(g):c[f]=[g]},nt),S$=St(B1);function Ir(c){return Lo(c)?lS(c):p5(c)}function jo(c){return Lo(c)?lS(c,!0):nH(c)}function x$(c,f){var g={};return f=nt(f,3),Ra(c,function(S,N,M){xs(g,f(S,N,M),S)}),g}function C$(c,f){var g={};return f=nt(f,3),Ra(c,function(S,N,M){xs(g,N,f(S,N,M))}),g}var A$=ff(function(c,f,g){Xp(c,f,g)}),R8=ff(function(c,f,g,S){Xp(c,f,g,S)}),N$=As(function(c,f){var g={};if(c==null)return g;var S=!1;f=Bn(f,function(M){return M=Il(M,c),S||(S=M.length>1),M}),Oa(c,A5(c),g),S&&(g=Ni(g,h|p|m,wH));for(var N=f.length;N--;)E5(g,f[N]);return g});function F$(c,f){return O8(c,dm(nt(f)))}var I$=As(function(c,f){return c==null?{}:oH(c,f)});function O8(c,f){if(c==null)return{};var g=Bn(A5(c),function(S){return[S]});return f=nt(f),SS(c,g,function(S,N){return f(S,N[0])})}function B$(c,f,g){f=Il(f,c);var S=-1,N=f.length;for(N||(N=1,c=n);++S<N;){var M=c==null?n:c[Da(f[S])];M===n&&(S=N,M=g),c=Fs(M)?M.call(c):M}return c}function R$(c,f,g){return c==null?c:O1(c,f,g)}function O$(c,f,g,S){return S=typeof S=="function"?S:n,c==null?c:O1(c,f,g,S)}var D8=KS(Ir),P8=KS(jo);function D$(c,f,g){var S=dt(c),N=S||Rl(c)||pf(c);if(f=nt(f,4),g==null){var M=c&&c.constructor;N?g=S?new M:[]:jn(c)?g=Fs(M)?cf(zp(c)):{}:g={}}return(N?xi:Ra)(c,function(V,Z,re){return f(g,V,Z,re)}),g}function P$(c,f){return c==null?!0:E5(c,f)}function M$(c,f,g){return c==null?c:FS(c,f,w5(g))}function L$(c,f,g,S){return S=typeof S=="function"?S:n,c==null?c:FS(c,f,w5(g),S)}function mf(c){return c==null?[]:t5(c,Ir(c))}function j$(c){return c==null?[]:t5(c,jo(c))}function z$(c,f,g){return g===n&&(g=f,f=n),g!==n&&(g=Bi(g),g=g===g?g:0),f!==n&&(f=Bi(f),f=f===f?f:0),Qu(Bi(c),f,g)}function H$(c,f,g){return f=Is(f),g===n?(g=f,f=0):g=Is(g),c=Bi(c),Kz(c,f,g)}function U$(c,f,g){if(g&&typeof g!="boolean"&&wo(c,f,g)&&(f=g=n),g===n&&(typeof f=="boolean"?(g=f,f=n):typeof c=="boolean"&&(g=c,c=n)),c===n&&f===n?(c=0,f=1):(c=Is(c),f===n?(f=c,c=0):f=Is(f)),c>f){var S=c;c=f,f=S}if(g||c%1||f%1){var N=aS();return no(c+N*(f-c+Ej("1e-"+((N+"").length-1))),f)}return v5(c,f)}var q$=df(function(c,f,g){return f=f.toLowerCase(),c+(g?M8(f):f)});function M8(c){return $5(Jt(c).toLowerCase())}function L8(c){return c=Jt(c),c&&c.replace(he,Rj).replace(cj,"")}function $$(c,f,g){c=Jt(c),f=si(f);var S=c.length;g=g===n?S:Qu(bt(g),0,S);var N=g;return g-=f.length,g>=0&&c.slice(g,N)==f}function W$(c){return c=Jt(c),c&&nr.test(c)?c.replace(wn,Oj):c}function G$(c){return c=Jt(c),c&&ju.test(c)?c.replace(wi,"\\$&"):c}var K$=df(function(c,f,g){return c+(g?"-":"")+f.toLowerCase()}),V$=df(function(c,f,g){return c+(g?" ":"")+f.toLowerCase()}),Y$=HS("toLowerCase");function Q$(c,f,g){c=Jt(c),f=bt(f);var S=f?of(c):0;if(!f||S>=f)return c;var N=(f-S)/2;return rm($p(N),g)+c+rm(qp(N),g)}function X$(c,f,g){c=Jt(c),f=bt(f);var S=f?of(c):0;return f&&S<f?c+rm(f-S,g):c}function Z$(c,f,g){c=Jt(c),f=bt(f);var S=f?of(c):0;return f&&S<f?rm(f-S,g)+c:c}function J$(c,f,g){return g||f==null?f=0:f&&(f=+f),az(Jt(c).replace(ki,""),f||0)}function eW(c,f,g){return(g?wo(c,f,g):f===n)?f=1:f=bt(f),b5(Jt(c),f)}function tW(){var c=arguments,f=Jt(c[0]);return c.length<3?f:f.replace(c[1],c[2])}var nW=df(function(c,f,g){return c+(g?"_":"")+f.toLowerCase()});function rW(c,f,g){return g&&typeof g!="number"&&wo(c,f,g)&&(f=g=n),g=g===n?R:g>>>0,g?(c=Jt(c),c&&(typeof f=="string"||f!=null&&!H5(f))&&(f=si(f),!f&&rf(c))?Bl(ia(c),0,g):c.split(f,g)):[]}var oW=df(function(c,f,g){return c+(g?" ":"")+$5(f)});function iW(c,f,g){return c=Jt(c),g=g==null?0:Qu(bt(g),0,c.length),f=si(f),c.slice(g,g+f.length)==f}function aW(c,f,g){var S=D.templateSettings;g&&wo(c,f,g)&&(f=n),c=Jt(c),f=mm({},f,S,VS);var N=mm({},f.imports,S.imports,VS),M=Ir(N),V=t5(N,M),Z,re,be=0,Ee=f.interpolate||Be,ke="__p += '",Re=r5((f.escape||Be).source+"|"+Ee.source+"|"+(Ee===to?O:Be).source+"|"+(f.evaluate||Be).source+"|$","g"),qe="//# sourceURL="+(tn.call(f,"sourceURL")?(f.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++mj+"]")+` `;c.replace(Re,function(it,Ft,Lt,ui,ko,ci){return Lt||(Lt=ui),ke+=c.slice(be,ci).replace(He,Dj),Ft&&(Z=!0,ke+=`' + __e(`+Ft+`) + '`),ko&&(re=!0,ke+=`'; `+ko+`; __p += '`),Lt&&(ke+=`' + ((__t = (`+Lt+`)) == null ? '' : __t) + '`),be=ci+it.length,it}),ke+=`'; `;var ot=tn.call(f,"variable")&&f.variable;if(!ot)ke=`with (obj) { `+ke+` } `;else if(q.test(ot))throw new ft(s);ke=(re?ke.replace(gt,""):ke).replace(Ln,"$1").replace(Tn,"$1;"),ke="function("+(ot||"obj")+`) { `+(ot?"":`obj || (obj = {}); `)+"var __t, __p = ''"+(Z?", __e = _.escape":"")+(re?`, __j = Array.prototype.join; function print() { __p += __j.call(arguments, '') } `:`; `)+ke+`return __p }`;var Tt=z8(function(){return Yt(M,qe+"return "+ke).apply(n,V)});if(Tt.source=ke,z5(Tt))throw Tt;return Tt}function sW(c){return Jt(c).toLowerCase()}function lW(c){return Jt(c).toUpperCase()}function uW(c,f,g){if(c=Jt(c),c&&(g||f===n))return Yk(c);if(!c||!(f=si(f)))return c;var S=ia(c),N=ia(f),M=Qk(S,N),V=Xk(S,N)+1;return Bl(S,M,V).join("")}function cW(c,f,g){if(c=Jt(c),c&&(g||f===n))return c.slice(0,Jk(c)+1);if(!c||!(f=si(f)))return c;var S=ia(c),N=Xk(S,ia(f))+1;return Bl(S,0,N).join("")}function fW(c,f,g){if(c=Jt(c),c&&(g||f===n))return c.replace(ki,"");if(!c||!(f=si(f)))return c;var S=ia(c),N=Qk(S,ia(f));return Bl(S,N).join("")}function dW(c,f){var g=j,S=H;if(jn(f)){var N="separator"in f?f.separator:N;g="length"in f?bt(f.length):g,S="omission"in f?si(f.omission):S}c=Jt(c);var M=c.length;if(rf(c)){var V=ia(c);M=V.length}if(g>=M)return c;var Z=g-of(S);if(Z<1)return S;var re=V?Bl(V,0,Z).join(""):c.slice(0,Z);if(N===n)return re+S;if(V&&(Z+=re.length-Z),H5(N)){if(c.slice(Z).search(N)){var be,Ee=re;for(N.global||(N=r5(N.source,Jt(B.exec(N))+"g")),N.lastIndex=0;be=N.exec(Ee);)var ke=be.index;re=re.slice(0,ke===n?Z:ke)}}else if(c.indexOf(si(N),Z)!=Z){var Re=re.lastIndexOf(N);Re>-1&&(re=re.slice(0,Re))}return re+S}function hW(c){return c=Jt(c),c&&kt.test(c)?c.replace(zr,Uj):c}var pW=df(function(c,f,g){return c+(g?" ":"")+f.toUpperCase()}),$5=HS("toUpperCase");function j8(c,f,g){return c=Jt(c),f=g?n:f,f===n?Mj(c)?Wj(c):Aj(c):c.match(f)||[]}var z8=St(function(c,f){try{return ii(c,n,f)}catch(g){return z5(g)?g:new ft(g)}}),mW=As(function(c,f){return xi(f,function(g){g=Da(g),xs(c,g,L5(c[g],c))}),c});function gW(c){var f=c==null?0:c.length,g=nt();return c=f?Bn(c,function(S){if(typeof S[1]!="function")throw new Ci(a);return[g(S[0]),S[1]]}):[],St(function(S){for(var N=-1;++N<f;){var M=c[N];if(ii(M[0],this,S))return ii(M[1],this,S)}})}function vW(c){return Uz(Ni(c,h))}function W5(c){return function(){return c}}function bW(c,f){return c==null||c!==c?f:c}var yW=qS(),EW=qS(!0);function zo(c){return c}function G5(c){return yS(typeof c=="function"?c:Ni(c,h))}function _W(c){return _S(Ni(c,h))}function TW(c,f){return TS(c,Ni(f,h))}var wW=St(function(c,f){return function(g){return B1(g,c,f)}}),kW=St(function(c,f){return function(g){return B1(c,g,f)}});function K5(c,f,g){var S=Ir(f),N=Qp(f,S);g==null&&!(jn(f)&&(N.length||!S.length))&&(g=f,f=c,c=this,N=Qp(f,Ir(f)));var M=!(jn(g)&&"chain"in g)||!!g.chain,V=Fs(c);return xi(N,function(Z){var re=f[Z];c[Z]=re,V&&(c.prototype[Z]=function(){var be=this.__chain__;if(M||be){var Ee=c(this.__wrapped__),ke=Ee.__actions__=Mo(this.__actions__);return ke.push({func:re,args:arguments,thisArg:c}),Ee.__chain__=be,Ee}return re.apply(c,xl([this.value()],arguments))})}),c}function SW(){return Ur._===this&&(Ur._=Xj),this}function V5(){}function xW(c){return c=bt(c),St(function(f){return wS(f,c)})}var CW=S5(Bn),AW=S5($k),NW=S5(Qy);function H8(c){return B5(c)?Xy(Da(c)):iH(c)}function FW(c){return function(f){return c==null?n:Xu(c,f)}}var IW=WS(),BW=WS(!0);function Y5(){return[]}function Q5(){return!1}function RW(){return{}}function OW(){return""}function DW(){return!0}function PW(c,f){if(c=bt(c),c<1||c>_e)return[];var g=R,S=no(c,R);f=nt(f),c-=R;for(var N=e5(S,f);++g<c;)f(g);return N}function MW(c){return dt(c)?Bn(c,Da):li(c)?[c]:Mo(s8(Jt(c)))}function LW(c){var f=++Yj;return Jt(c)+f}var jW=nm(function(c,f){return c+f},0),zW=x5("ceil"),HW=nm(function(c,f){return c/f},1),UW=x5("floor");function qW(c){return c&&c.length?Yp(c,zo,f5):n}function $W(c,f){return c&&c.length?Yp(c,nt(f,2),f5):n}function WW(c){return Kk(c,zo)}function GW(c,f){return Kk(c,nt(f,2))}function KW(c){return c&&c.length?Yp(c,zo,m5):n}function VW(c,f){return c&&c.length?Yp(c,nt(f,2),m5):n}var YW=nm(function(c,f){return c*f},1),QW=x5("round"),XW=nm(function(c,f){return c-f},0);function ZW(c){return c&&c.length?Jy(c,zo):0}function JW(c,f){return c&&c.length?Jy(c,nt(f,2)):0}return D.after=_q,D.ary=b8,D.assign=l$,D.assignIn=B8,D.assignInWith=mm,D.assignWith=u$,D.at=c$,D.before=y8,D.bind=L5,D.bindAll=mW,D.bindKey=E8,D.castArray=Rq,D.chain=m8,D.chunk=UH,D.compact=qH,D.concat=$H,D.cond=gW,D.conforms=vW,D.constant=W5,D.countBy=ZU,D.create=f$,D.curry=_8,D.curryRight=T8,D.debounce=w8,D.defaults=d$,D.defaultsDeep=h$,D.defer=Tq,D.delay=wq,D.difference=WH,D.differenceBy=GH,D.differenceWith=KH,D.drop=VH,D.dropRight=YH,D.dropRightWhile=QH,D.dropWhile=XH,D.fill=ZH,D.filter=eq,D.flatMap=rq,D.flatMapDeep=oq,D.flatMapDepth=iq,D.flatten=f8,D.flattenDeep=JH,D.flattenDepth=eU,D.flip=kq,D.flow=yW,D.flowRight=EW,D.fromPairs=tU,D.functions=E$,D.functionsIn=_$,D.groupBy=aq,D.initial=rU,D.intersection=oU,D.intersectionBy=iU,D.intersectionWith=aU,D.invert=w$,D.invertBy=k$,D.invokeMap=lq,D.iteratee=G5,D.keyBy=uq,D.keys=Ir,D.keysIn=jo,D.map=um,D.mapKeys=x$,D.mapValues=C$,D.matches=_W,D.matchesProperty=TW,D.memoize=fm,D.merge=A$,D.mergeWith=R8,D.method=wW,D.methodOf=kW,D.mixin=K5,D.negate=dm,D.nthArg=xW,D.omit=N$,D.omitBy=F$,D.once=Sq,D.orderBy=cq,D.over=CW,D.overArgs=xq,D.overEvery=AW,D.overSome=NW,D.partial=j5,D.partialRight=k8,D.partition=fq,D.pick=I$,D.pickBy=O8,D.property=H8,D.propertyOf=FW,D.pull=cU,D.pullAll=h8,D.pullAllBy=fU,D.pullAllWith=dU,D.pullAt=hU,D.range=IW,D.rangeRight=BW,D.rearg=Cq,D.reject=pq,D.remove=pU,D.rest=Aq,D.reverse=P5,D.sampleSize=gq,D.set=R$,D.setWith=O$,D.shuffle=vq,D.slice=mU,D.sortBy=Eq,D.sortedUniq=TU,D.sortedUniqBy=wU,D.split=rW,D.spread=Nq,D.tail=kU,D.take=SU,D.takeRight=xU,D.takeRightWhile=CU,D.takeWhile=AU,D.tap=qU,D.throttle=Fq,D.thru=lm,D.toArray=N8,D.toPairs=D8,D.toPairsIn=P8,D.toPath=MW,D.toPlainObject=I8,D.transform=D$,D.unary=Iq,D.union=NU,D.unionBy=FU,D.unionWith=IU,D.uniq=BU,D.uniqBy=RU,D.uniqWith=OU,D.unset=P$,D.unzip=M5,D.unzipWith=p8,D.update=M$,D.updateWith=L$,D.values=mf,D.valuesIn=j$,D.without=DU,D.words=j8,D.wrap=Bq,D.xor=PU,D.xorBy=MU,D.xorWith=LU,D.zip=jU,D.zipObject=zU,D.zipObjectDeep=HU,D.zipWith=UU,D.entries=D8,D.entriesIn=P8,D.extend=B8,D.extendWith=mm,K5(D,D),D.add=jW,D.attempt=z8,D.camelCase=q$,D.capitalize=M8,D.ceil=zW,D.clamp=z$,D.clone=Oq,D.cloneDeep=Pq,D.cloneDeepWith=Mq,D.cloneWith=Dq,D.conformsTo=Lq,D.deburr=L8,D.defaultTo=bW,D.divide=HW,D.endsWith=$$,D.eq=sa,D.escape=W$,D.escapeRegExp=G$,D.every=JU,D.find=tq,D.findIndex=u8,D.findKey=p$,D.findLast=nq,D.findLastIndex=c8,D.findLastKey=m$,D.floor=UW,D.forEach=g8,D.forEachRight=v8,D.forIn=g$,D.forInRight=v$,D.forOwn=b$,D.forOwnRight=y$,D.get=U5,D.gt=jq,D.gte=zq,D.has=T$,D.hasIn=q5,D.head=d8,D.identity=zo,D.includes=sq,D.indexOf=nU,D.inRange=H$,D.invoke=S$,D.isArguments=ec,D.isArray=dt,D.isArrayBuffer=Hq,D.isArrayLike=Lo,D.isArrayLikeObject=or,D.isBoolean=Uq,D.isBuffer=Rl,D.isDate=qq,D.isElement=$q,D.isEmpty=Wq,D.isEqual=Gq,D.isEqualWith=Kq,D.isError=z5,D.isFinite=Vq,D.isFunction=Fs,D.isInteger=S8,D.isLength=hm,D.isMap=x8,D.isMatch=Yq,D.isMatchWith=Qq,D.isNaN=Xq,D.isNative=Zq,D.isNil=e$,D.isNull=Jq,D.isNumber=C8,D.isObject=jn,D.isObjectLike=$n,D.isPlainObject=L1,D.isRegExp=H5,D.isSafeInteger=t$,D.isSet=A8,D.isString=pm,D.isSymbol=li,D.isTypedArray=pf,D.isUndefined=n$,D.isWeakMap=r$,D.isWeakSet=o$,D.join=sU,D.kebabCase=K$,D.last=Ii,D.lastIndexOf=lU,D.lowerCase=V$,D.lowerFirst=Y$,D.lt=i$,D.lte=a$,D.max=qW,D.maxBy=$W,D.mean=WW,D.meanBy=GW,D.min=KW,D.minBy=VW,D.stubArray=Y5,D.stubFalse=Q5,D.stubObject=RW,D.stubString=OW,D.stubTrue=DW,D.multiply=YW,D.nth=uU,D.noConflict=SW,D.noop=V5,D.now=cm,D.pad=Q$,D.padEnd=X$,D.padStart=Z$,D.parseInt=J$,D.random=U$,D.reduce=dq,D.reduceRight=hq,D.repeat=eW,D.replace=tW,D.result=B$,D.round=QW,D.runInContext=ne,D.sample=mq,D.size=bq,D.snakeCase=nW,D.some=yq,D.sortedIndex=gU,D.sortedIndexBy=vU,D.sortedIndexOf=bU,D.sortedLastIndex=yU,D.sortedLastIndexBy=EU,D.sortedLastIndexOf=_U,D.startCase=oW,D.startsWith=iW,D.subtract=XW,D.sum=ZW,D.sumBy=JW,D.template=aW,D.times=PW,D.toFinite=Is,D.toInteger=bt,D.toLength=F8,D.toLower=sW,D.toNumber=Bi,D.toSafeInteger=s$,D.toString=Jt,D.toUpper=lW,D.trim=uW,D.trimEnd=cW,D.trimStart=fW,D.truncate=dW,D.unescape=hW,D.uniqueId=LW,D.upperCase=pW,D.upperFirst=$5,D.each=g8,D.eachRight=v8,D.first=d8,K5(D,function(){var c={};return Ra(D,function(f,g){tn.call(D.prototype,g)||(c[g]=f)}),c}(),{chain:!1}),D.VERSION=r,xi(["bind","bindKey","curry","curryRight","partial","partialRight"],function(c){D[c].placeholder=D}),xi(["drop","take"],function(c,f){Rt.prototype[c]=function(g){g=g===n?1:_r(bt(g),0);var S=this.__filtered__&&!f?new Rt(this):this.clone();return S.__filtered__?S.__takeCount__=no(g,S.__takeCount__):S.__views__.push({size:no(g,R),type:c+(S.__dir__<0?"Right":"")}),S},Rt.prototype[c+"Right"]=function(g){return this.reverse()[c](g).reverse()}}),xi(["filter","map","takeWhile"],function(c,f){var g=f+1,S=g==pe||g==J;Rt.prototype[c]=function(N){var M=this.clone();return M.__iteratees__.push({iteratee:nt(N,3),type:g}),M.__filtered__=M.__filtered__||S,M}}),xi(["head","last"],function(c,f){var g="take"+(f?"Right":"");Rt.prototype[c]=function(){return this[g](1).value()[0]}}),xi(["initial","tail"],function(c,f){var g="drop"+(f?"":"Right");Rt.prototype[c]=function(){return this.__filtered__?new Rt(this):this[g](1)}}),Rt.prototype.compact=function(){return this.filter(zo)},Rt.prototype.find=function(c){return this.filter(c).head()},Rt.prototype.findLast=function(c){return this.reverse().find(c)},Rt.prototype.invokeMap=St(function(c,f){return typeof c=="function"?new Rt(this):this.map(function(g){return B1(g,c,f)})}),Rt.prototype.reject=function(c){return this.filter(dm(nt(c)))},Rt.prototype.slice=function(c,f){c=bt(c);var g=this;return g.__filtered__&&(c>0||f<0)?new Rt(g):(c<0?g=g.takeRight(-c):c&&(g=g.drop(c)),f!==n&&(f=bt(f),g=f<0?g.dropRight(-f):g.take(f-c)),g)},Rt.prototype.takeRightWhile=function(c){return this.reverse().takeWhile(c).reverse()},Rt.prototype.toArray=function(){return this.take(R)},Ra(Rt.prototype,function(c,f){var g=/^(?:filter|find|map|reject)|While$/.test(f),S=/^(?:head|last)$/.test(f),N=D[S?"take"+(f=="last"?"Right":""):f],M=S||/^find/.test(f);N&&(D.prototype[f]=function(){var V=this.__wrapped__,Z=S?[1]:arguments,re=V instanceof Rt,be=Z[0],Ee=re||dt(V),ke=function(Ft){var Lt=N.apply(D,xl([Ft],Z));return S&&Re?Lt[0]:Lt};Ee&&g&&typeof be=="function"&&be.length!=1&&(re=Ee=!1);var Re=this.__chain__,qe=!!this.__actions__.length,ot=M&&!Re,Tt=re&&!qe;if(!M&&Ee){V=Tt?V:new Rt(this);var it=c.apply(V,Z);return it.__actions__.push({func:lm,args:[ke],thisArg:n}),new Ai(it,Re)}return ot&&Tt?c.apply(this,Z):(it=this.thru(ke),ot?S?it.value()[0]:it.value():it)})}),xi(["pop","push","shift","sort","splice","unshift"],function(c){var f=Op[c],g=/^(?:push|sort|unshift)$/.test(c)?"tap":"thru",S=/^(?:pop|shift)$/.test(c);D.prototype[c]=function(){var N=arguments;if(S&&!this.__chain__){var M=this.value();return f.apply(dt(M)?M:[],N)}return this[g](function(V){return f.apply(dt(V)?V:[],N)})}}),Ra(Rt.prototype,function(c,f){var g=D[f];if(g){var S=g.name+"";tn.call(uf,S)||(uf[S]=[]),uf[S].push({name:f,func:g})}}),uf[tm(n,E).name]=[{name:"wrapper",func:n}],Rt.prototype.clone=hz,Rt.prototype.reverse=pz,Rt.prototype.value=mz,D.prototype.at=$U,D.prototype.chain=WU,D.prototype.commit=GU,D.prototype.next=KU,D.prototype.plant=YU,D.prototype.reverse=QU,D.prototype.toJSON=D.prototype.valueOf=D.prototype.value=XU,D.prototype.first=D.prototype.head,S1&&(D.prototype[S1]=VU),D},af=Gj();Gu?((Gu.exports=af)._=af,Gy._=af):Ur._=af}).call(Mf)})(ob,ob.exports);var Qo=ob.exports;const ib=xr(Qo);var Js=(e=>(e.Debug="debug",e.Normal="normal",e))(Js||{});const Lc="chat_history",z_="userPreference",Y1e={appInfo:{},setAppInfo:Qo.noop,appConfig:{},setAppConfig:Qo.noop,currentMessageNavIdRef:{current:""},navList:[],setNavList:Qo.noop,chatStoreName:"",isDark:!1,setIsDark:Qo.noop,isDisableChatHistory:!1,setIsDisableChatHistory:Qo.noop,messages:new Map,setMessages:Qo.noop,isChatHistoryExist:!1,setIsChatHistoryExist:Qo.noop,chatHistory:new Map,setChatHistory:Qo.noop,viewMode:Js.Normal,setViewMode:Qo.noop,editMessageHandlerRef:{current:void 0},chatDBRef:{current:void 0},chatStoreRef:{current:void 0}},eo=T.createContext(Y1e);var LD={exports:{}},jD={};/** * @license React * use-sync-external-store-shim.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Vd=T;function Q1e(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var X1e=typeof Object.is=="function"?Object.is:Q1e,Z1e=Vd.useState,J1e=Vd.useEffect,ehe=Vd.useLayoutEffect,the=Vd.useDebugValue;function nhe(e,t){var n=t(),r=Z1e({inst:{value:n,getSnapshot:t}}),o=r[0].inst,i=r[1];return ehe(function(){o.value=n,o.getSnapshot=t,f9(o)&&i({inst:o})},[e,n,t]),J1e(function(){return f9(o)&&i({inst:o}),e(function(){f9(o)&&i({inst:o})})},[e]),the(n),n}function f9(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!X1e(e,n)}catch{return!0}}function rhe(e,t){return t()}var ohe=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?rhe:nhe;jD.useSyncExternalStore=Vd.useSyncExternalStore!==void 0?Vd.useSyncExternalStore:ohe;LD.exports=jD;var ihe=LD.exports;function ahe(e){return document.addEventListener("fullscreenchange",e),()=>{document.removeEventListener("fullscreenchange",e)}}const zD=()=>ihe.useSyncExternalStore(ahe,()=>!!document.fullscreenElement),she=()=>{const e=zD();return T.useCallback(()=>{try{e?document.exitFullscreen():document.documentElement.requestFullscreen()}catch(n){console.error(n)}},[e])};var H_={exports:{}},q6=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof window.msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto);if(q6){var $6=new Uint8Array(16);H_.exports=function(){return q6($6),$6}}else{var W6=new Array(16);H_.exports=function(){for(var t=0,n;t<16;t++)t&3||(n=Math.random()*4294967296),W6[t]=n>>>((t&3)<<3)&255;return W6}}var HD=H_.exports,UD=[];for(var Gm=0;Gm<256;++Gm)UD[Gm]=(Gm+256).toString(16).substr(1);function lhe(e,t){var n=t||0,r=UD;return[r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],"-",r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]],r[e[n++]]].join("")}var qD=lhe,uhe=HD,che=qD,G6,d9,h9=0,p9=0;function fhe(e,t,n){var r=t&&n||0,o=t||[];e=e||{};var i=e.node||G6,a=e.clockseq!==void 0?e.clockseq:d9;if(i==null||a==null){var s=uhe();i==null&&(i=G6=[s[0]|1,s[1],s[2],s[3],s[4],s[5]]),a==null&&(a=d9=(s[6]<<8|s[7])&16383)}var l=e.msecs!==void 0?e.msecs:new Date().getTime(),u=e.nsecs!==void 0?e.nsecs:p9+1,d=l-h9+(u-p9)/1e4;if(d<0&&e.clockseq===void 0&&(a=a+1&16383),(d<0||l>h9)&&e.nsecs===void 0&&(u=0),u>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");h9=l,p9=u,d9=a,l+=122192928e5;var h=((l&268435455)*1e4+u)%4294967296;o[r++]=h>>>24&255,o[r++]=h>>>16&255,o[r++]=h>>>8&255,o[r++]=h&255;var p=l/4294967296*1e4&268435455;o[r++]=p>>>8&255,o[r++]=p&255,o[r++]=p>>>24&15|16,o[r++]=p>>>16&255,o[r++]=a>>>8|128,o[r++]=a&255;for(var m=0;m<6;++m)o[r+m]=i[m];return t||che(o)}var dhe=fhe,hhe=HD,phe=qD;function mhe(e,t,n){var r=t&&n||0;typeof e=="string"&&(t=e==="binary"?new Array(16):null,e=null),e=e||{};var o=e.random||(e.rng||hhe)();if(o[6]=o[6]&15|64,o[8]=o[8]&63|128,t)for(var i=0;i<16;++i)t[r+i]=o[i];return t||phe(o)}var ghe=mhe,vhe=dhe,$D=ghe,nw=$D;nw.v1=vhe;nw.v4=$D;var up=nw;async function qa(e){return new Promise((t,n)=>{e.oncomplete=e.onsuccess=()=>{t(e.result)},e.onabort=e.onerror=()=>{n(e.error)}})}class bhe{constructor(t){gf(this,"store");this.store=t}getIndex(t){return this.store.index(t)}async get(t){return qa(this.store.get(t))}async getWithField(t){const n=this.store.openCursor();return new Promise((r,o)=>{n.onsuccess=()=>{const i=n.result;i?Object.entries(t).every(([s,l])=>i.value[s]===l)?r(i.value):i.continue():r(void 0)},n.onerror=()=>{o(n.error)}})}async getWithIndex(t,n){const r=this.getIndex(t);return qa(r.get(n))}async getAll(t,n){return qa(this.store.getAll(t,n))}async getAllWithIndex(t,n,r){const o=this.getIndex(t);return qa(o.getAll(n,r))}async getList(t){try{return Promise.all(t.map(n=>qa(this.store.get(n))))}catch(n){console.error(n)}}async getMatchedRecords(t,n){const r=await this.getList(t),o=n||(s=>!!s),i=[],a={};return r==null||r.forEach((s,l)=>{o(s)?a[t[l]]=s:i.push(t[l])}),{matchedRecords:a,unMatchedKeys:i}}async put(t,n){try{const r=Array.isArray(t)?t:[t];return Promise.all(r.map(o=>qa(this.store.put(o,n))))}catch(r){console.error(r)}}async putWithIndex(t,n,r){const i=this.getIndex(n).openCursor(r);return new Promise((a,s)=>{i.onsuccess=()=>{const l=i.result;l?(l.update({...l.value,...t}),a()):(this.store.put(t),a())},i.onerror=()=>{s(i.error)}})}async putWithField(t,n){const r=this.store.openCursor();return new Promise((o,i)=>{r.onsuccess=()=>{const a=r.result;a?Object.entries(n).every(([l,u])=>a.value[l]===u)?(a.update({...a.value,...t}),o()):a.continue():(this.store.put(t),o())},r.onerror=()=>{i(r.error)}})}async delete(t){try{return qa(this.store.delete(t))}catch(n){console.error(n)}}async deleteWithField(t){const n=this.store.openCursor();return new Promise((r,o)=>{n.onsuccess=()=>{const i=n.result;i?(Object.entries(t).every(([s,l])=>i.value[s]===l)&&i.delete(),i.continue()):r()},n.onerror=()=>{o(n.error)}})}async updateWithField(t,n){const r=this.store.openCursor();return new Promise((o,i)=>{r.onsuccess=()=>{const a=r.result;a?(Object.entries(t).every(([l,u])=>a.value[l]===u)&&a.update({...a.value,...n}),a.continue()):o()},r.onerror=()=>{i(r.error)}})}async deleteWithIndex(t,n){const r=this.getIndex(t).openCursor(n);return new Promise((o,i)=>{r.onsuccess=()=>{const a=r.result;a?(a.delete(),a.continue()):o()},r.onerror=()=>{i(r.error)}})}async deleteList(t){try{await Promise.all(t.map(n=>this.delete(n)))}catch(n){console.error(n)}}async clear(){this.store.clear()}}class yhe extends bhe{constructor(n,r){super(n);gf(this,"appInfo",{});this.appInfo=r??{}}setAppInfo(n){this.appInfo.name=n.name??this.appInfo.name,this.appInfo.version=n.version??this.appInfo.version}async getAppRecords(){const n="chat_app_index";return this.getAllWithIndex(n,IDBKeyRange.only([this.appInfo.name,this.appInfo.version]))}}const Ehe="flow-chat-test-db",c1="flow-chat-test-config-db",_he="chat_nav_index",The={name:_he,keyPath:"navId",options:{unique:!1}};class WD{constructor(t=Ehe){gf(this,"dbName");gf(this,"_db");gf(this,"isDBReady",!1);this.dbName=t}static async allDataBase(){return await window.indexedDB.databases()}static async clearAllDataBase(t){var r;const n=await this.allDataBase();for(const o of n)(r=o.name)!=null&&r.startsWith("promptflow-db-")&&(o.name===t.dbName?t.clear():window.indexedDB.deleteDatabase(o.name))}get db(){if(!this._db)throw new Error("db is not ready");return this._db}get allStoreNames(){return Array.from(this.db.objectStoreNames)}getStore(t){if(!this.allStoreNames.includes(t))return;const n=this.db.transaction(t,"readwrite");return n.oncomplete=()=>{console.log("transaction complete")},new yhe(n.objectStore(t))}clear(t){const n=t?[t]:this.allStoreNames;try{n.forEach(r=>{const o=this.getStore(r);o==null||o.clear()})}catch(r){console.error(r)}}async deleteStore(t){this.allStoreNames.includes(t)&&this.db.deleteObjectStore(t)}close(){this._db&&(this.db.close(),this._db=void 0,this.isDBReady=!1)}async deleteDB(){this.close(),await qa(indexedDB.deleteDatabase(this.dbName)),this.isDBReady=!1}async createDB(t){const n=indexedDB.open(this.dbName);n.onupgradeneeded=r=>{switch(console.log("happen onupgradeneeded"),this._db=n.result,r.oldVersion){case 0:this.db.createObjectStore(c1,{keyPath:"id"}).createIndex("type","type",{unique:!1});break}t.forEach(o=>{if(!this.allStoreNames.includes(o.name)){const i=this.db.createObjectStore(o.name,this.getStoreParams(o));if(Array.isArray(o.indexes))for(const a of o.indexes)i.createIndex(a.name,a.keyPath,a.options)}})},await qa(n),console.log("happen onsuccess"),this._db=n.result,this.isDBReady=!0}getStoreParams(t){const n={};return t?(typeof t.keyPath=="string"&&(n.keyPath=t.keyPath),n):(n.autoIncrement=!0,n)}async createStore(t){const n=indexedDB.open(this.dbName);n.onupgradeneeded=()=>{if(this.db.close(),this._db=n.result,!this.allStoreNames.includes(t.name)){const r=this.db.createObjectStore(t.name,this.getStoreParams(t));if(Array.isArray(t.indexes))for(const o of t.indexes)r.createIndex(o.name,o.keyPath,o.options)}},await qa(n),this._db=n.result,this.isDBReady=!0}}const cp=(e,t)=>e&&t?`${e}-${t}`:"",U_=(e,t,n)=>{const r=typeof e=="string"?e:JSON.stringify(e,void 0,2);return{id:up.v4(),from:t,type:MD.Text,content:r,timestamp:new Date().toISOString(),duration:n}},K6=e=>U_(e,wr.User),V6=(e,t)=>{if(typeof e=="string")return U_(e,wr.Chatbot,t);const n=JSON.stringify(e,void 0,2);return U_(n,wr.Chatbot,t)},Y6=e=>{const t=e.content;try{return JSON.parse(t)}catch{return{}}},whe=e=>{const t=e.content;try{return JSON.parse(t)}catch{return{}}},ab=(e,t,n)=>({id:up.v4(),name:t??"",appInfo:e,storeName:cp(e.name,e.version),isSelected:n??!1,createAt:Date.now(),chatUserName:"User",type:"chatTab",chatUserAvatar:"",chatBotName:"Chatbot",chatBotAvatar:""}),khe=e=>{const{chatDBRef:t,setMessages:n,setChatHistory:r,setNavList:o,setAppConfig:i}=T.useContext(eo),[a,s]=T.useState(!0);return T.useLayoutEffect(()=>{if(e.name&&e.version){const l=cp(e.name,e.version),u=new WD(`promptflow-db-${l}`),d=[{name:l,keyPath:"id",indexes:[The]}];u.createDB(d).then(()=>{t.current=u;const h=u.getStore(l);h==null||h.getAll().then(m=>{const v=new Map;m.forEach(E=>{const w=E.navId;w&&v.set(w,[...v.get(w)??[],E])}),n(v);const _=v.keys(),b=new Map;for(const E of _){const w=ib.findLastIndex(v.get(E),y=>y.from===wr.User),k=ib.findLastIndex(v.get(E),y=>y.from===wr.Chatbot);if(w!==-1){const y=v.get(E)[w],F=Y6(y)[Lc];if(F&&k>w){const C=v.get(E)[k],A=Y6(y);F.push({id:up.v4(),inputs:{...A,[Lc]:void 0},outputs:{...whe(C)},duration:C.duration,navId:E})}b.set(E,F??[])}}r(b)});const p=u.getStore(c1);p==null||p.getAllWithIndex("type","chatTab").then(m=>{console.log("load nav list",m),o(()=>m!=null&&m.length?m.sort((v,_)=>_.createAt-v.createAt).map((v,_)=>({...v,isSelected:_===0})):[ab(e,"",!0)])},()=>{o(()=>[ab(e,"",!0)])}),p==null||p.getWithIndex("type",z_).then(m=>{i(m??{type:z_,appDisplayName:`${e.name}(${e.version})`})})}).finally(()=>{s(!1)})}return()=>{var l;e.name&&e.version&&((l=t.current)==null||l.close())}},[e.name,e.version]),[a]},She=()=>{const{appInfo:e}=T.useContext(eo);return T.useMemo(()=>cp(e.name,e.version),[e.name,e.version])},xhe=()=>{const{setMessages:e,chatDBRef:t,navList:n,currentMessageNavIdRef:r}=T.useContext(eo),o=She(),{id:i}=n.find(u=>u.isSelected)??{},a=T.useCallback(u=>{var p,m;const d=r.current;if(!d)return;const h={...u,navId:d};(m=(p=t.current)==null?void 0:p.getStore(o))==null||m.put({...h,id:Date.now()}),e(v=>{const _=new Map(v);return _.set(d,[..._.get(d)??[],h]),_})},[o]),s=T.useCallback(u=>{i&&e(d=>{var m;const h=new Map(d),p=((m=h.get(i))==null?void 0:m.findIndex(v=>v.id===u))??-1;return p===-1?d:h.set(i,[...h.get(i)??[]].splice(p,1))})},[i]),l=T.useCallback((u,d)=>{i&&e(h=>{var v;const p=new Map(h),m=((v=p.get(i))==null?void 0:v.findIndex(_=>_.id===u))??-1;return m===-1?h:p.set(i,[...(p.get(i)??[]).slice(0,m),d])})},[i]);return{setAddMessage:a,setRemoveMessage:s,setResetAtIdAndRemoveAfterId:l}},GD=(e,t)=>{const{messages:n,navList:r}=T.useContext(eo),{id:o}=r.find(a=>a.isSelected)??{},i=t??o;return T.useMemo(()=>{if(!i)return[];const a=n.get(i)??[];return e?a.filter(s=>s.from===e):a},[e,n,i])},Che=(e,t,n)=>{const r=GD(t,n);return r.length>0&&r[r.length-1].id===e},yl=()=>{const{navList:e,setNavList:t}=T.useContext(eo);return[e,t]},Ahe=e=>{const{appInfo:t}=T.useContext(eo);return ab(t,e)},KD=()=>{const e=Ahe(),[,t]=yl();return()=>{const n={...e,isSelected:!0,createAt:Date.now()};t(r=>{const o=r.map(i=>({...i,isSelected:!1}));return[n,...o]})}},VD=()=>{const[,e]=yl();return T.useCallback(t=>{typeof t=="string"?e(n=>n.filter(r=>!!r.name).map(r=>({...r,isSelected:r.id===t}))):t>=0&&e(n=>n.filter(r=>!!r.name).map((r,o)=>({...r,isSelected:o===t})))},[])},Du=()=>{const[e]=yl();return e.find(t=>t.isSelected)},Nhe=()=>{const[e]=yl();return e.findIndex(t=>t.name==="")===-1},Fhe=()=>{const{chatDBRef:e}=T.useContext(eo),[,t]=yl(),n=Du();return T.useCallback(r=>{var o,i;(n==null?void 0:n.name)===""&&((i=(o=e.current)==null?void 0:o.getStore(c1))==null||i.put({...n,name:r}),t(a=>a.map(s=>({...s,name:s.name?s.name:r}))))},[n,e])},Ihe=()=>{const{chatDBRef:e}=T.useContext(eo),[,t]=yl();return T.useCallback(n=>{var r,o;(o=(r=e.current)==null?void 0:r.getStore(c1))==null||o.updateWithField({id:n.id},n),t(i=>i.map(a=>a.id===n.id?{...a,...n}:a))},[])},Bhe=()=>{const{id:e=""}=Du()||{},t=Ihe();return T.useCallback(n=>{t({...n,id:e})},[e,t])},Rhe=e=>{const{chatDBRef:t,appInfo:n}=T.useContext(eo),[,r]=yl();return T.useCallback(()=>{var o,i,a,s;r(l=>l.length===1?[ab(n,"",!0)]:l.filter(u=>u.id!==e)),(i=(o=t.current)==null?void 0:o.getStore(c1))==null||i.deleteWithField({id:e}),(s=(a=t.current)==null?void 0:a.getStore(cp(n.name,n.version)))==null||s.deleteWithField({navId:e})},[n.name,n.version,t,e])},Ohe=()=>{const{id:e=""}=Du()||{},t=Rhe(e);return T.useCallback(()=>{t()},[t])},Dhe=()=>{const{setChatHistory:e,currentMessageNavIdRef:t}=T.useContext(eo);return{setAddChatHistory:T.useCallback((r,o,i)=>{const a=t.current;if(!a)return;const s={id:up.v4(),inputs:{...r},outputs:{...o},duration:i,navId:a};e(l=>{const u=new Map(l),d=ib.set(ib.cloneDeep(s),`inputs.${Lc}`,void 0);return u.set(a,[...u.get(a)??[],d]),u})},[])}},Phe=()=>{const{chatHistory:e}=T.useContext(eo),{id:t}=Du()??{};return T.useMemo(()=>t?e.get(t)??[]:[],[e,t])},Mhe=()=>{const{messages:e,viewMode:t}=T.useContext(eo),{id:n}=Du()??{},r=T.useMemo(()=>n?e.get(n)??[]:[],[e,n]);return T.useMemo(()=>t===Js.Debug?r:r.map(i=>{if(i.from!==wr.User||typeof i.content!="string")return i;const a=i.content;try{const s=JSON.parse(a),l=Object.keys(s).filter(u=>u!==Lc);return l.length===1?{...i,content:String(s[l[0]])}:i}catch{return i}}),[r,t])};var rw={exports:{}},YD=function(t,n){return function(){for(var o=new Array(arguments.length),i=0;i<o.length;i++)o[i]=arguments[i];return t.apply(n,o)}},Lhe=YD,Gc=Object.prototype.toString;function ow(e){return Gc.call(e)==="[object Array]"}function q_(e){return typeof e>"u"}function jhe(e){return e!==null&&!q_(e)&&e.constructor!==null&&!q_(e.constructor)&&typeof e.constructor.isBuffer=="function"&&e.constructor.isBuffer(e)}function zhe(e){return Gc.call(e)==="[object ArrayBuffer]"}function Hhe(e){return typeof FormData<"u"&&e instanceof FormData}function Uhe(e){var t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&e.buffer instanceof ArrayBuffer,t}function qhe(e){return typeof e=="string"}function $he(e){return typeof e=="number"}function QD(e){return e!==null&&typeof e=="object"}function qg(e){if(Gc.call(e)!=="[object Object]")return!1;var t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function Whe(e){return Gc.call(e)==="[object Date]"}function Ghe(e){return Gc.call(e)==="[object File]"}function Khe(e){return Gc.call(e)==="[object Blob]"}function XD(e){return Gc.call(e)==="[object Function]"}function Vhe(e){return QD(e)&&XD(e.pipe)}function Yhe(e){return typeof URLSearchParams<"u"&&e instanceof URLSearchParams}function Qhe(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Xhe(){return typeof navigator<"u"&&(navigator.product==="ReactNative"||navigator.product==="NativeScript"||navigator.product==="NS")?!1:typeof window<"u"&&typeof document<"u"}function iw(e,t){if(!(e===null||typeof e>"u"))if(typeof e!="object"&&(e=[e]),ow(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.call(null,e[o],o,e)}function $_(){var e={};function t(o,i){qg(e[i])&&qg(o)?e[i]=$_(e[i],o):qg(o)?e[i]=$_({},o):ow(o)?e[i]=o.slice():e[i]=o}for(var n=0,r=arguments.length;n<r;n++)iw(arguments[n],t);return e}function Zhe(e,t,n){return iw(t,function(o,i){n&&typeof o=="function"?e[i]=Lhe(o,n):e[i]=o}),e}function Jhe(e){return e.charCodeAt(0)===65279&&(e=e.slice(1)),e}var _i={isArray:ow,isArrayBuffer:zhe,isBuffer:jhe,isFormData:Hhe,isArrayBufferView:Uhe,isString:qhe,isNumber:$he,isObject:QD,isPlainObject:qg,isUndefined:q_,isDate:Whe,isFile:Ghe,isBlob:Khe,isFunction:XD,isStream:Vhe,isURLSearchParams:Yhe,isStandardBrowserEnv:Xhe,forEach:iw,merge:$_,extend:Zhe,trim:Qhe,stripBOM:Jhe},Cf=_i;function Q6(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var ZD=function(t,n,r){if(!n)return t;var o;if(r)o=r(n);else if(Cf.isURLSearchParams(n))o=n.toString();else{var i=[];Cf.forEach(n,function(l,u){l===null||typeof l>"u"||(Cf.isArray(l)?u=u+"[]":l=[l],Cf.forEach(l,function(h){Cf.isDate(h)?h=h.toISOString():Cf.isObject(h)&&(h=JSON.stringify(h)),i.push(Q6(u)+"="+Q6(h))}))}),o=i.join("&")}if(o){var a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+o}return t},e0e=_i;function ly(){this.handlers=[]}ly.prototype.use=function(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1};ly.prototype.eject=function(t){this.handlers[t]&&(this.handlers[t]=null)};ly.prototype.forEach=function(t){e0e.forEach(this.handlers,function(r){r!==null&&t(r)})};var t0e=ly,n0e=_i,r0e=function(t,n){n0e.forEach(t,function(o,i){i!==n&&i.toUpperCase()===n.toUpperCase()&&(t[n]=o,delete t[i])})},JD=function(t,n,r,o,i){return t.config=n,r&&(t.code=r),t.request=o,t.response=i,t.isAxiosError=!0,t.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},t},m9,X6;function eP(){if(X6)return m9;X6=1;var e=JD;return m9=function(n,r,o,i,a){var s=new Error(n);return e(s,r,o,i,a)},m9}var g9,Z6;function o0e(){if(Z6)return g9;Z6=1;var e=eP();return g9=function(n,r,o){var i=o.config.validateStatus;!o.status||!i||i(o.status)?n(o):r(e("Request failed with status code "+o.status,o.config,null,o.request,o))},g9}var v9,J6;function i0e(){if(J6)return v9;J6=1;var e=_i;return v9=e.isStandardBrowserEnv()?function(){return{write:function(r,o,i,a,s,l){var u=[];u.push(r+"="+encodeURIComponent(o)),e.isNumber(i)&&u.push("expires="+new Date(i).toGMTString()),e.isString(a)&&u.push("path="+a),e.isString(s)&&u.push("domain="+s),l===!0&&u.push("secure"),document.cookie=u.join("; ")},read:function(r){var o=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return o?decodeURIComponent(o[3]):null},remove:function(r){this.write(r,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}(),v9}var b9,e7;function a0e(){return e7||(e7=1,b9=function(t){return/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(t)}),b9}var y9,t7;function s0e(){return t7||(t7=1,y9=function(t,n){return n?t.replace(/\/+$/,"")+"/"+n.replace(/^\/+/,""):t}),y9}var E9,n7;function l0e(){if(n7)return E9;n7=1;var e=a0e(),t=s0e();return E9=function(r,o){return r&&!e(o)?t(r,o):o},E9}var _9,r7;function u0e(){if(r7)return _9;r7=1;var e=_i,t=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"];return _9=function(r){var o={},i,a,s;return r&&e.forEach(r.split(` `),function(u){if(s=u.indexOf(":"),i=e.trim(u.substr(0,s)).toLowerCase(),a=e.trim(u.substr(s+1)),i){if(o[i]&&t.indexOf(i)>=0)return;i==="set-cookie"?o[i]=(o[i]?o[i]:[]).concat([a]):o[i]=o[i]?o[i]+", "+a:a}}),o},_9}var T9,o7;function c0e(){if(o7)return T9;o7=1;var e=_i;return T9=e.isStandardBrowserEnv()?function(){var n=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a"),o;function i(a){var s=a;return n&&(r.setAttribute("href",s),s=r.href),r.setAttribute("href",s),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return o=i(window.location.href),function(s){var l=e.isString(s)?i(s):s;return l.protocol===o.protocol&&l.host===o.host}}():function(){return function(){return!0}}(),T9}var w9,i7;function a7(){if(i7)return w9;i7=1;var e=_i,t=o0e(),n=i0e(),r=ZD,o=l0e(),i=u0e(),a=c0e(),s=eP();return w9=function(u){return new Promise(function(h,p){var m=u.data,v=u.headers,_=u.responseType;e.isFormData(m)&&delete v["Content-Type"];var b=new XMLHttpRequest;if(u.auth){var E=u.auth.username||"",w=u.auth.password?unescape(encodeURIComponent(u.auth.password)):"";v.Authorization="Basic "+btoa(E+":"+w)}var k=o(u.baseURL,u.url);b.open(u.method.toUpperCase(),r(k,u.params,u.paramsSerializer),!0),b.timeout=u.timeout;function y(){if(b){var C="getAllResponseHeaders"in b?i(b.getAllResponseHeaders()):null,A=!_||_==="text"||_==="json"?b.responseText:b.response,P={data:A,status:b.status,statusText:b.statusText,headers:C,config:u,request:b};t(h,p,P),b=null}}if("onloadend"in b?b.onloadend=y:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout(y)},b.onabort=function(){b&&(p(s("Request aborted",u,"ECONNABORTED",b)),b=null)},b.onerror=function(){p(s("Network Error",u,null,b)),b=null},b.ontimeout=function(){var A="timeout of "+u.timeout+"ms exceeded";u.timeoutErrorMessage&&(A=u.timeoutErrorMessage),p(s(A,u,u.transitional&&u.transitional.clarifyTimeoutError?"ETIMEDOUT":"ECONNABORTED",b)),b=null},e.isStandardBrowserEnv()){var F=(u.withCredentials||a(k))&&u.xsrfCookieName?n.read(u.xsrfCookieName):void 0;F&&(v[u.xsrfHeaderName]=F)}"setRequestHeader"in b&&e.forEach(v,function(A,P){typeof m>"u"&&P.toLowerCase()==="content-type"?delete v[P]:b.setRequestHeader(P,A)}),e.isUndefined(u.withCredentials)||(b.withCredentials=!!u.withCredentials),_&&_!=="json"&&(b.responseType=u.responseType),typeof u.onDownloadProgress=="function"&&b.addEventListener("progress",u.onDownloadProgress),typeof u.onUploadProgress=="function"&&b.upload&&b.upload.addEventListener("progress",u.onUploadProgress),u.cancelToken&&u.cancelToken.promise.then(function(A){b&&(b.abort(),p(A),b=null)}),m||(m=null),b.send(m)})},w9}var Vr=_i,s7=r0e,f0e=JD,d0e={"Content-Type":"application/x-www-form-urlencoded"};function l7(e,t){!Vr.isUndefined(e)&&Vr.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}function h0e(){var e;return(typeof XMLHttpRequest<"u"||typeof process<"u"&&Object.prototype.toString.call(process)==="[object process]")&&(e=a7()),e}function p0e(e,t,n){if(Vr.isString(e))try{return(t||JSON.parse)(e),Vr.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}var uy={transitional:{silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},adapter:h0e(),transformRequest:[function(t,n){return s7(n,"Accept"),s7(n,"Content-Type"),Vr.isFormData(t)||Vr.isArrayBuffer(t)||Vr.isBuffer(t)||Vr.isStream(t)||Vr.isFile(t)||Vr.isBlob(t)?t:Vr.isArrayBufferView(t)?t.buffer:Vr.isURLSearchParams(t)?(l7(n,"application/x-www-form-urlencoded;charset=utf-8"),t.toString()):Vr.isObject(t)||n&&n["Content-Type"]==="application/json"?(l7(n,"application/json"),p0e(t)):t}],transformResponse:[function(t){var n=this.transitional,r=n&&n.silentJSONParsing,o=n&&n.forcedJSONParsing,i=!r&&this.responseType==="json";if(i||o&&Vr.isString(t)&&t.length)try{return JSON.parse(t)}catch(a){if(i)throw a.name==="SyntaxError"?f0e(a,this,"E_JSON_PARSE"):a}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(t){return t>=200&&t<300}};uy.headers={common:{Accept:"application/json, text/plain, */*"}};Vr.forEach(["delete","get","head"],function(t){uy.headers[t]={}});Vr.forEach(["post","put","patch"],function(t){uy.headers[t]=Vr.merge(d0e)});var aw=uy,m0e=_i,g0e=aw,v0e=function(t,n,r){var o=this||g0e;return m0e.forEach(r,function(a){t=a.call(o,t,n)}),t},k9,u7;function tP(){return u7||(u7=1,k9=function(t){return!!(t&&t.__CANCEL__)}),k9}var c7=_i,S9=v0e,b0e=tP(),y0e=aw;function x9(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var E0e=function(t){x9(t),t.headers=t.headers||{},t.data=S9.call(t,t.data,t.headers,t.transformRequest),t.headers=c7.merge(t.headers.common||{},t.headers[t.method]||{},t.headers),c7.forEach(["delete","get","head","post","put","patch","common"],function(o){delete t.headers[o]});var n=t.adapter||y0e.adapter;return n(t).then(function(o){return x9(t),o.data=S9.call(t,o.data,o.headers,t.transformResponse),o},function(o){return b0e(o)||(x9(t),o&&o.response&&(o.response.data=S9.call(t,o.response.data,o.response.headers,t.transformResponse))),Promise.reject(o)})},io=_i,nP=function(t,n){n=n||{};var r={},o=["url","method","data"],i=["headers","auth","proxy","params"],a=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],s=["validateStatus"];function l(p,m){return io.isPlainObject(p)&&io.isPlainObject(m)?io.merge(p,m):io.isPlainObject(m)?io.merge({},m):io.isArray(m)?m.slice():m}function u(p){io.isUndefined(n[p])?io.isUndefined(t[p])||(r[p]=l(void 0,t[p])):r[p]=l(t[p],n[p])}io.forEach(o,function(m){io.isUndefined(n[m])||(r[m]=l(void 0,n[m]))}),io.forEach(i,u),io.forEach(a,function(m){io.isUndefined(n[m])?io.isUndefined(t[m])||(r[m]=l(void 0,t[m])):r[m]=l(void 0,n[m])}),io.forEach(s,function(m){m in n?r[m]=l(t[m],n[m]):m in t&&(r[m]=l(void 0,t[m]))});var d=o.concat(i).concat(a).concat(s),h=Object.keys(t).concat(Object.keys(n)).filter(function(m){return d.indexOf(m)===-1});return io.forEach(h,u),r};const _0e="axios",T0e="0.21.4",w0e="Promise based HTTP client for the browser and node.js",k0e="index.js",S0e={test:"grunt test",start:"node ./sandbox/server.js",build:"NODE_ENV=production grunt build",preversion:"npm test",version:"npm run build && grunt version && git add -A dist && git add CHANGELOG.md bower.json package.json",postversion:"git push && git push --tags",examples:"node ./examples/server.js",coveralls:"cat coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",fix:"eslint --fix lib/**/*.js"},x0e={type:"git",url:"https://github.com/axios/axios.git"},C0e=["xhr","http","ajax","promise","node"],A0e="Matt Zabriskie",N0e="MIT",F0e={url:"https://github.com/axios/axios/issues"},I0e="https://axios-http.com",B0e={coveralls:"^3.0.0","es6-promise":"^4.2.4",grunt:"^1.3.0","grunt-banner":"^0.6.0","grunt-cli":"^1.2.0","grunt-contrib-clean":"^1.1.0","grunt-contrib-watch":"^1.0.0","grunt-eslint":"^23.0.0","grunt-karma":"^4.0.0","grunt-mocha-test":"^0.13.3","grunt-ts":"^6.0.0-beta.19","grunt-webpack":"^4.0.2","istanbul-instrumenter-loader":"^1.0.0","jasmine-core":"^2.4.1",karma:"^6.3.2","karma-chrome-launcher":"^3.1.0","karma-firefox-launcher":"^2.1.0","karma-jasmine":"^1.1.1","karma-jasmine-ajax":"^0.1.13","karma-safari-launcher":"^1.0.0","karma-sauce-launcher":"^4.3.6","karma-sinon":"^1.0.5","karma-sourcemap-loader":"^0.3.8","karma-webpack":"^4.0.2","load-grunt-tasks":"^3.5.2",minimist:"^1.2.0",mocha:"^8.2.1",sinon:"^4.5.0","terser-webpack-plugin":"^4.2.3",typescript:"^4.0.5","url-search-params":"^0.10.0",webpack:"^4.44.2","webpack-dev-server":"^3.11.0"},R0e={"./lib/adapters/http.js":"./lib/adapters/xhr.js"},O0e="dist/axios.min.js",D0e="dist/axios.min.js",P0e="./index.d.ts",M0e={"follow-redirects":"^1.14.0"},L0e=[{path:"./dist/axios.min.js",threshold:"5kB"}],j0e={name:_0e,version:T0e,description:w0e,main:k0e,scripts:S0e,repository:x0e,keywords:C0e,author:A0e,license:N0e,bugs:F0e,homepage:I0e,devDependencies:B0e,browser:R0e,jsdelivr:O0e,unpkg:D0e,typings:P0e,dependencies:M0e,bundlesize:L0e};var rP=j0e,sw={};["object","boolean","number","function","string","symbol"].forEach(function(e,t){sw[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});var f7={},z0e=rP.version.split(".");function oP(e,t){for(var n=t?t.split("."):z0e,r=e.split("."),o=0;o<3;o++){if(n[o]>r[o])return!0;if(n[o]<r[o])return!1}return!1}sw.transitional=function(t,n,r){var o=n&&oP(n);function i(a,s){return"[Axios v"+rP.version+"] Transitional option '"+a+"'"+s+(r?". "+r:"")}return function(a,s,l){if(t===!1)throw new Error(i(s," has been removed in "+n));return o&&!f7[s]&&(f7[s]=!0,console.warn(i(s," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,s,l):!0}};function H0e(e,t,n){if(typeof e!="object")throw new TypeError("options must be an object");for(var r=Object.keys(e),o=r.length;o-- >0;){var i=r[o],a=t[i];if(a){var s=e[i],l=s===void 0||a(s,i,e);if(l!==!0)throw new TypeError("option "+i+" must be "+l);continue}if(n!==!0)throw Error("Unknown option "+i)}}var U0e={isOlderVersion:oP,assertOptions:H0e,validators:sw},iP=_i,q0e=ZD,d7=t0e,h7=E0e,cy=nP,aP=U0e,Af=aP.validators;function fp(e){this.defaults=e,this.interceptors={request:new d7,response:new d7}}fp.prototype.request=function(t){typeof t=="string"?(t=arguments[1]||{},t.url=arguments[0]):t=t||{},t=cy(this.defaults,t),t.method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var n=t.transitional;n!==void 0&&aP.assertOptions(n,{silentJSONParsing:Af.transitional(Af.boolean,"1.0.0"),forcedJSONParsing:Af.transitional(Af.boolean,"1.0.0"),clarifyTimeoutError:Af.transitional(Af.boolean,"1.0.0")},!1);var r=[],o=!0;this.interceptors.request.forEach(function(p){typeof p.runWhen=="function"&&p.runWhen(t)===!1||(o=o&&p.synchronous,r.unshift(p.fulfilled,p.rejected))});var i=[];this.interceptors.response.forEach(function(p){i.push(p.fulfilled,p.rejected)});var a;if(!o){var s=[h7,void 0];for(Array.prototype.unshift.apply(s,r),s=s.concat(i),a=Promise.resolve(t);s.length;)a=a.then(s.shift(),s.shift());return a}for(var l=t;r.length;){var u=r.shift(),d=r.shift();try{l=u(l)}catch(h){d(h);break}}try{a=h7(l)}catch(h){return Promise.reject(h)}for(;i.length;)a=a.then(i.shift(),i.shift());return a};fp.prototype.getUri=function(t){return t=cy(this.defaults,t),q0e(t.url,t.params,t.paramsSerializer).replace(/^\?/,"")};iP.forEach(["delete","get","head","options"],function(t){fp.prototype[t]=function(n,r){return this.request(cy(r||{},{method:t,url:n,data:(r||{}).data}))}});iP.forEach(["post","put","patch"],function(t){fp.prototype[t]=function(n,r,o){return this.request(cy(o||{},{method:t,url:n,data:r}))}});var $0e=fp,C9,p7;function sP(){if(p7)return C9;p7=1;function e(t){this.message=t}return e.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},e.prototype.__CANCEL__=!0,C9=e,C9}var A9,m7;function W0e(){if(m7)return A9;m7=1;var e=sP();function t(n){if(typeof n!="function")throw new TypeError("executor must be a function.");var r;this.promise=new Promise(function(a){r=a});var o=this;n(function(a){o.reason||(o.reason=new e(a),r(o.reason))})}return t.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},t.source=function(){var r,o=new t(function(a){r=a});return{token:o,cancel:r}},A9=t,A9}var N9,g7;function G0e(){return g7||(g7=1,N9=function(t){return function(r){return t.apply(null,r)}}),N9}var F9,v7;function K0e(){return v7||(v7=1,F9=function(t){return typeof t=="object"&&t.isAxiosError===!0}),F9}var b7=_i,V0e=YD,$g=$0e,Y0e=nP,Q0e=aw;function lP(e){var t=new $g(e),n=V0e($g.prototype.request,t);return b7.extend(n,$g.prototype,t),b7.extend(n,t),n}var ka=lP(Q0e);ka.Axios=$g;ka.create=function(t){return lP(Y0e(ka.defaults,t))};ka.Cancel=sP();ka.CancelToken=W0e();ka.isCancel=tP();ka.all=function(t){return Promise.all(t)};ka.spread=G0e();ka.isAxiosError=K0e();rw.exports=ka;rw.exports.default=ka;var X0e=rw.exports,Z0e=X0e;const J0e=xr(Z0e),epe=e=>{const{method:t,url:n,data:r,params:o}=e;return e.metaData||(e.metaData={}),e.metaData.startTime=performance.now(),console.log(`[axios] ${t==null?void 0:t.toUpperCase()} ${n}`),r&&console.log(`[axios] data: ${JSON.stringify(r)}`),o&&console.log(`[axios] params: ${JSON.stringify(o)}`),e},tpe=e=>{const{config:t}=e,{method:n,url:r}=t,o=t.metaData.startTime,i=(performance.now()-o)/1e3;return t.metaData.duration=i,console.log(`[axios] ${n==null?void 0:n.toUpperCase()} ${r} ${i}s`),e},npe=[epe],rpe=[tpe],ope="",ipe={headers:{"x-ms-client-user-type":"Promptflow vscode local server"},baseURL:ope,timeout:6e4*6},ape=e=>{const t=J0e.create(e);return npe.forEach(n=>{t.interceptors.request.use(n)}),rpe.forEach(n=>{t.interceptors.response.use(n)}),t},spe=ape(ipe),uP=e=>{const{cacheKey:t,...n}=e;if(t)return t;const r=n.params?JSON.stringify(n.params):"",o=n.headers?JSON.stringify(n.headers):"";return t||`${e.method}-${e.url}-${r}-${o}`},cP=async e=>await spe.request(e);function lpe(e){return O1e({queryKey:uP(e),queryFn:async()=>cP(e),notifyOnChangeProps:"tracked"})}function upe(e,t){return B1e({mutationKey:uP(e),mutationFn:async n=>(e.data=n,cP(e)),onSuccess:async(n,r)=>{var o;(o=t==null?void 0:t.onSuccess)==null||o.call(t,n,r)},onError:async(n,r)=>{var o;(o=t==null?void 0:t.onError)==null||o.call(t,n,r)},onSettled:async(n,r,o)=>{var i;(i=t==null?void 0:t.onSettled)==null||i.call(t,n,r,o)}})}const lw={HeaderTitle:"Chat",InputPlaceholder:"Input anything to test...",Tooltip_Bottom:"Only default variants will be used for chat, if you want to test variants please try batch run. For chatbot and test app bot, it will only show the chat output.",Tooltip_Title:"chat",Tooltip_TotalTokens:"Total tokens",MessageStatus_TimeSpent_Desc:"time spent",MessageStatus_TimeSpent_Unit:"sec",MessageStatus_Tokens_Desc:"Total tokens for generating this",MessageStatus_Tokens_Unit:"tokens",ClearButtonTooltip:"Click to clear all chat histories",Settings:{tooltip:"Settings",useDarkTheme:"Dark theme",useLightTheme:"Light theme"},ViewMode:{Debug:"Debug"},ClearHistoryTooltip:"Clear chat history"},y7=e=>{try{return JSON.parse(e)}catch(t){console.error(t)}return e},cpe=(e,t)=>{switch(t){case"integer":return parseInt(e,10);case"number":return parseFloat(e);case"boolean":return e==="true";case"string":return e;case"array":return y7(e)||[];case"object":return y7(e)||{};default:return e}},fpe=(e,t,n,r)=>{const o={};return Object.keys(e).forEach(i=>{o[i]=cpe(e[i].value??"",e[i].type)}),n&&(o[Lc]=r?[]:t),o};var dpe=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,n=[],r=0;r<e.rangeCount;r++)n.push(e.getRangeAt(r));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null;break}return e.removeAllRanges(),function(){e.type==="Caret"&&e.removeAllRanges(),e.rangeCount||n.forEach(function(o){e.addRange(o)}),t&&t.focus()}},hpe=dpe,E7={"text/plain":"Text","text/html":"Url",default:"Text"},ppe="Copy to clipboard: #{key}, Enter";function mpe(e){var t=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return e.replace(/#{\s*key\s*}/g,t)}function gpe(e,t){var n,r,o,i,a,s,l=!1;t||(t={}),n=t.debug||!1;try{o=hpe(),i=document.createRange(),a=document.getSelection(),s=document.createElement("span"),s.textContent=e,s.ariaHidden="true",s.style.all="unset",s.style.position="fixed",s.style.top=0,s.style.clip="rect(0, 0, 0, 0)",s.style.whiteSpace="pre",s.style.webkitUserSelect="text",s.style.MozUserSelect="text",s.style.msUserSelect="text",s.style.userSelect="text",s.addEventListener("copy",function(d){if(d.stopPropagation(),t.format)if(d.preventDefault(),typeof d.clipboardData>"u"){n&&console.warn("unable to use e.clipboardData"),n&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var h=E7[t.format]||E7.default;window.clipboardData.setData(h,e)}else d.clipboardData.clearData(),d.clipboardData.setData(t.format,e);t.onCopy&&(d.preventDefault(),t.onCopy(d.clipboardData))}),document.body.appendChild(s),i.selectNodeContents(s),a.addRange(i);var u=document.execCommand("copy");if(!u)throw new Error("copy command was unsuccessful");l=!0}catch(d){n&&console.error("unable to copy using execCommand: ",d),n&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(t.format||"text",e),t.onCopy&&t.onCopy(window.clipboardData),l=!0}catch(h){n&&console.error("unable to copy using clipboardData: ",h),n&&console.error("falling back to prompt"),r=mpe("message"in t?t.message:ppe),window.prompt(r,e)}}finally{a&&(typeof a.removeRange=="function"?a.removeRange(i):a.removeAllRanges()),s&&document.body.removeChild(s),o()}return l}var vpe=gpe;const fP=xr(vpe);//! moment.js //! version : 2.29.4 //! authors : Tim Wood, Iskren Chernev, Moment.js contributors //! license : MIT //! momentjs.com var dP;function De(){return dP.apply(null,arguments)}function bpe(e){dP=e}function Sa(e){return e instanceof Array||Object.prototype.toString.call(e)==="[object Array]"}function Bc(e){return e!=null&&Object.prototype.toString.call(e)==="[object Object]"}function Wt(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function uw(e){if(Object.getOwnPropertyNames)return Object.getOwnPropertyNames(e).length===0;var t;for(t in e)if(Wt(e,t))return!1;return!0}function Vo(e){return e===void 0}function fl(e){return typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]"}function dp(e){return e instanceof Date||Object.prototype.toString.call(e)==="[object Date]"}function hP(e,t){var n=[],r,o=e.length;for(r=0;r<o;++r)n.push(t(e[r],r));return n}function au(e,t){for(var n in t)Wt(t,n)&&(e[n]=t[n]);return Wt(t,"toString")&&(e.toString=t.toString),Wt(t,"valueOf")&&(e.valueOf=t.valueOf),e}function gs(e,t,n,r){return MP(e,t,n,r,!0).utc()}function ype(){return{empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}}function yt(e){return e._pf==null&&(e._pf=ype()),e._pf}var W_;Array.prototype.some?W_=Array.prototype.some:W_=function(e){var t=Object(this),n=t.length>>>0,r;for(r=0;r<n;r++)if(r in t&&e.call(this,t[r],r,t))return!0;return!1};function cw(e){if(e._isValid==null){var t=yt(e),n=W_.call(t.parsedDateParts,function(o){return o!=null}),r=!isNaN(e._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidEra&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n);if(e._strict&&(r=r&&t.charsLeftOver===0&&t.unusedTokens.length===0&&t.bigHour===void 0),Object.isFrozen==null||!Object.isFrozen(e))e._isValid=r;else return r}return e._isValid}function fy(e){var t=gs(NaN);return e!=null?au(yt(t),e):yt(t).userInvalidated=!0,t}var _7=De.momentProperties=[],I9=!1;function fw(e,t){var n,r,o,i=_7.length;if(Vo(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),Vo(t._i)||(e._i=t._i),Vo(t._f)||(e._f=t._f),Vo(t._l)||(e._l=t._l),Vo(t._strict)||(e._strict=t._strict),Vo(t._tzm)||(e._tzm=t._tzm),Vo(t._isUTC)||(e._isUTC=t._isUTC),Vo(t._offset)||(e._offset=t._offset),Vo(t._pf)||(e._pf=yt(t)),Vo(t._locale)||(e._locale=t._locale),i>0)for(n=0;n<i;n++)r=_7[n],o=t[r],Vo(o)||(e[r]=o);return e}function hp(e){fw(this,e),this._d=new Date(e._d!=null?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),I9===!1&&(I9=!0,De.updateOffset(this),I9=!1)}function xa(e){return e instanceof hp||e!=null&&e._isAMomentObject!=null}function pP(e){De.suppressDeprecationWarnings===!1&&typeof console<"u"&&console.warn&&console.warn("Deprecation warning: "+e)}function ta(e,t){var n=!0;return au(function(){if(De.deprecationHandler!=null&&De.deprecationHandler(null,e),n){var r=[],o,i,a,s=arguments.length;for(i=0;i<s;i++){if(o="",typeof arguments[i]=="object"){o+=` [`+i+"] ";for(a in arguments[0])Wt(arguments[0],a)&&(o+=a+": "+arguments[0][a]+", ");o=o.slice(0,-2)}else o=arguments[i];r.push(o)}pP(e+` Arguments: `+Array.prototype.slice.call(r).join("")+` `+new Error().stack),n=!1}return t.apply(this,arguments)},t)}var T7={};function mP(e,t){De.deprecationHandler!=null&&De.deprecationHandler(e,t),T7[e]||(pP(t),T7[e]=!0)}De.suppressDeprecationWarnings=!1;De.deprecationHandler=null;function vs(e){return typeof Function<"u"&&e instanceof Function||Object.prototype.toString.call(e)==="[object Function]"}function Epe(e){var t,n;for(n in e)Wt(e,n)&&(t=e[n],vs(t)?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)}function G_(e,t){var n=au({},e),r;for(r in t)Wt(t,r)&&(Bc(e[r])&&Bc(t[r])?(n[r]={},au(n[r],e[r]),au(n[r],t[r])):t[r]!=null?n[r]=t[r]:delete n[r]);for(r in e)Wt(e,r)&&!Wt(t,r)&&Bc(e[r])&&(n[r]=au({},n[r]));return n}function dw(e){e!=null&&this.set(e)}var K_;Object.keys?K_=Object.keys:K_=function(e){var t,n=[];for(t in e)Wt(e,t)&&n.push(t);return n};var _pe={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"};function Tpe(e,t,n){var r=this._calendar[e]||this._calendar.sameElse;return vs(r)?r.call(t,n):r}function fs(e,t,n){var r=""+Math.abs(e),o=t-r.length,i=e>=0;return(i?n?"+":"":"-")+Math.pow(10,Math.max(0,o)).toString().substr(1)+r}var hw=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,Km=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,B9={},Nd={};function Ke(e,t,n,r){var o=r;typeof r=="string"&&(o=function(){return this[r]()}),e&&(Nd[e]=o),t&&(Nd[t[0]]=function(){return fs(o.apply(this,arguments),t[1],t[2])}),n&&(Nd[n]=function(){return this.localeData().ordinal(o.apply(this,arguments),e)})}function wpe(e){return e.match(/\[[\s\S]/)?e.replace(/^\[|\]$/g,""):e.replace(/\\/g,"")}function kpe(e){var t=e.match(hw),n,r;for(n=0,r=t.length;n<r;n++)Nd[t[n]]?t[n]=Nd[t[n]]:t[n]=wpe(t[n]);return function(o){var i="",a;for(a=0;a<r;a++)i+=vs(t[a])?t[a].call(o,e):t[a];return i}}function Wg(e,t){return e.isValid()?(t=gP(t,e.localeData()),B9[t]=B9[t]||kpe(t),B9[t](e)):e.localeData().invalidDate()}function gP(e,t){var n=5;function r(o){return t.longDateFormat(o)||o}for(Km.lastIndex=0;n>=0&&Km.test(e);)e=e.replace(Km,r),Km.lastIndex=0,n-=1;return e}var Spe={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};function xpe(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(hw).map(function(r){return r==="MMMM"||r==="MM"||r==="DD"||r==="dddd"?r.slice(1):r}).join(""),this._longDateFormat[e])}var Cpe="Invalid date";function Ape(){return this._invalidDate}var Npe="%d",Fpe=/\d{1,2}/;function Ipe(e){return this._ordinal.replace("%d",e)}var Bpe={future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"};function Rpe(e,t,n,r){var o=this._relativeTime[n];return vs(o)?o(e,t,n,r):o.replace(/%d/i,e)}function Ope(e,t){var n=this._relativeTime[e>0?"future":"past"];return vs(n)?n(t):n.replace(/%s/i,t)}var Gh={};function vo(e,t){var n=e.toLowerCase();Gh[n]=Gh[n+"s"]=Gh[t]=e}function na(e){return typeof e=="string"?Gh[e]||Gh[e.toLowerCase()]:void 0}function pw(e){var t={},n,r;for(r in e)Wt(e,r)&&(n=na(r),n&&(t[n]=e[r]));return t}var vP={};function bo(e,t){vP[e]=t}function Dpe(e){var t=[],n;for(n in e)Wt(e,n)&&t.push({unit:n,priority:vP[n]});return t.sort(function(r,o){return r.priority-o.priority}),t}function dy(e){return e%4===0&&e%100!==0||e%400===0}function ji(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function Nt(e){var t=+e,n=0;return t!==0&&isFinite(t)&&(n=ji(t)),n}function f1(e,t){return function(n){return n!=null?(bP(this,e,n),De.updateOffset(this,t),this):sb(this,e)}}function sb(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function bP(e,t,n){e.isValid()&&!isNaN(n)&&(t==="FullYear"&&dy(e.year())&&e.month()===1&&e.date()===29?(n=Nt(n),e._d["set"+(e._isUTC?"UTC":"")+t](n,e.month(),by(n,e.month()))):e._d["set"+(e._isUTC?"UTC":"")+t](n))}function Ppe(e){return e=na(e),vs(this[e])?this[e]():this}function Mpe(e,t){if(typeof e=="object"){e=pw(e);var n=Dpe(e),r,o=n.length;for(r=0;r<o;r++)this[n[r].unit](e[n[r].unit])}else if(e=na(e),vs(this[e]))return this[e](t);return this}var yP=/\d/,Ti=/\d\d/,EP=/\d{3}/,mw=/\d{4}/,hy=/[+-]?\d{6}/,Fn=/\d\d?/,_P=/\d\d\d\d?/,TP=/\d\d\d\d\d\d?/,py=/\d{1,3}/,gw=/\d{1,4}/,my=/[+-]?\d{1,6}/,d1=/\d+/,gy=/[+-]?\d+/,Lpe=/Z|[+-]\d\d:?\d\d/gi,vy=/Z|[+-]\d\d(?::?\d\d)?/gi,jpe=/[+-]?\d+(\.\d{1,3})?/,pp=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,lb;lb={};function Me(e,t,n){lb[e]=vs(t)?t:function(r,o){return r&&n?n:t}}function zpe(e,t){return Wt(lb,e)?lb[e](t._strict,t._locale):new RegExp(Hpe(e))}function Hpe(e){return pi(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(t,n,r,o,i){return n||r||o||i}))}function pi(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var V_={};function cn(e,t){var n,r=t,o;for(typeof e=="string"&&(e=[e]),fl(t)&&(r=function(i,a){a[t]=Nt(i)}),o=e.length,n=0;n<o;n++)V_[e[n]]=r}function mp(e,t){cn(e,function(n,r,o,i){o._w=o._w||{},t(n,o._w,o,i)})}function Upe(e,t,n){t!=null&&Wt(V_,e)&&V_[e](t,n._a,n,e)}var ho=0,el=1,Ka=2,Sr=3,_a=4,tl=5,xc=6,qpe=7,$pe=8;function Wpe(e,t){return(e%t+t)%t}var sr;Array.prototype.indexOf?sr=Array.prototype.indexOf:sr=function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1};function by(e,t){if(isNaN(e)||isNaN(t))return NaN;var n=Wpe(t,12);return e+=(t-n)/12,n===1?dy(e)?29:28:31-n%7%2}Ke("M",["MM",2],"Mo",function(){return this.month()+1});Ke("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)});Ke("MMMM",0,0,function(e){return this.localeData().months(this,e)});vo("month","M");bo("month",8);Me("M",Fn);Me("MM",Fn,Ti);Me("MMM",function(e,t){return t.monthsShortRegex(e)});Me("MMMM",function(e,t){return t.monthsRegex(e)});cn(["M","MM"],function(e,t){t[el]=Nt(e)-1});cn(["MMM","MMMM"],function(e,t,n,r){var o=n._locale.monthsParse(e,r,n._strict);o!=null?t[el]=o:yt(n).invalidMonth=e});var Gpe="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),wP="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),kP=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,Kpe=pp,Vpe=pp;function Ype(e,t){return e?Sa(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||kP).test(t)?"format":"standalone"][e.month()]:Sa(this._months)?this._months:this._months.standalone}function Qpe(e,t){return e?Sa(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[kP.test(t)?"format":"standalone"][e.month()]:Sa(this._monthsShort)?this._monthsShort:this._monthsShort.standalone}function Xpe(e,t,n){var r,o,i,a=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],r=0;r<12;++r)i=gs([2e3,r]),this._shortMonthsParse[r]=this.monthsShort(i,"").toLocaleLowerCase(),this._longMonthsParse[r]=this.months(i,"").toLocaleLowerCase();return n?t==="MMM"?(o=sr.call(this._shortMonthsParse,a),o!==-1?o:null):(o=sr.call(this._longMonthsParse,a),o!==-1?o:null):t==="MMM"?(o=sr.call(this._shortMonthsParse,a),o!==-1?o:(o=sr.call(this._longMonthsParse,a),o!==-1?o:null)):(o=sr.call(this._longMonthsParse,a),o!==-1?o:(o=sr.call(this._shortMonthsParse,a),o!==-1?o:null))}function Zpe(e,t,n){var r,o,i;if(this._monthsParseExact)return Xpe.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),r=0;r<12;r++){if(o=gs([2e3,r]),n&&!this._longMonthsParse[r]&&(this._longMonthsParse[r]=new RegExp("^"+this.months(o,"").replace(".","")+"$","i"),this._shortMonthsParse[r]=new RegExp("^"+this.monthsShort(o,"").replace(".","")+"$","i")),!n&&!this._monthsParse[r]&&(i="^"+this.months(o,"")+"|^"+this.monthsShort(o,""),this._monthsParse[r]=new RegExp(i.replace(".",""),"i")),n&&t==="MMMM"&&this._longMonthsParse[r].test(e))return r;if(n&&t==="MMM"&&this._shortMonthsParse[r].test(e))return r;if(!n&&this._monthsParse[r].test(e))return r}}function SP(e,t){var n;if(!e.isValid())return e;if(typeof t=="string"){if(/^\d+$/.test(t))t=Nt(t);else if(t=e.localeData().monthsParse(t),!fl(t))return e}return n=Math.min(e.date(),by(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function xP(e){return e!=null?(SP(this,e),De.updateOffset(this,!0),this):sb(this,"Month")}function Jpe(){return by(this.year(),this.month())}function eme(e){return this._monthsParseExact?(Wt(this,"_monthsRegex")||CP.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(Wt(this,"_monthsShortRegex")||(this._monthsShortRegex=Kpe),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)}function tme(e){return this._monthsParseExact?(Wt(this,"_monthsRegex")||CP.call(this),e?this._monthsStrictRegex:this._monthsRegex):(Wt(this,"_monthsRegex")||(this._monthsRegex=Vpe),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)}function CP(){function e(a,s){return s.length-a.length}var t=[],n=[],r=[],o,i;for(o=0;o<12;o++)i=gs([2e3,o]),t.push(this.monthsShort(i,"")),n.push(this.months(i,"")),r.push(this.months(i,"")),r.push(this.monthsShort(i,""));for(t.sort(e),n.sort(e),r.sort(e),o=0;o<12;o++)t[o]=pi(t[o]),n[o]=pi(n[o]);for(o=0;o<24;o++)r[o]=pi(r[o]);this._monthsRegex=new RegExp("^("+r.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+t.join("|")+")","i")}Ke("Y",0,0,function(){var e=this.year();return e<=9999?fs(e,4):"+"+e});Ke(0,["YY",2],0,function(){return this.year()%100});Ke(0,["YYYY",4],0,"year");Ke(0,["YYYYY",5],0,"year");Ke(0,["YYYYYY",6,!0],0,"year");vo("year","y");bo("year",1);Me("Y",gy);Me("YY",Fn,Ti);Me("YYYY",gw,mw);Me("YYYYY",my,hy);Me("YYYYYY",my,hy);cn(["YYYYY","YYYYYY"],ho);cn("YYYY",function(e,t){t[ho]=e.length===2?De.parseTwoDigitYear(e):Nt(e)});cn("YY",function(e,t){t[ho]=De.parseTwoDigitYear(e)});cn("Y",function(e,t){t[ho]=parseInt(e,10)});function Kh(e){return dy(e)?366:365}De.parseTwoDigitYear=function(e){return Nt(e)+(Nt(e)>68?1900:2e3)};var AP=f1("FullYear",!0);function nme(){return dy(this.year())}function rme(e,t,n,r,o,i,a){var s;return e<100&&e>=0?(s=new Date(e+400,t,n,r,o,i,a),isFinite(s.getFullYear())&&s.setFullYear(e)):s=new Date(e,t,n,r,o,i,a),s}function D0(e){var t,n;return e<100&&e>=0?(n=Array.prototype.slice.call(arguments),n[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function ub(e,t,n){var r=7+t-n,o=(7+D0(e,0,r).getUTCDay()-t)%7;return-o+r-1}function NP(e,t,n,r,o){var i=(7+n-r)%7,a=ub(e,r,o),s=1+7*(t-1)+i+a,l,u;return s<=0?(l=e-1,u=Kh(l)+s):s>Kh(e)?(l=e+1,u=s-Kh(e)):(l=e,u=s),{year:l,dayOfYear:u}}function P0(e,t,n){var r=ub(e.year(),t,n),o=Math.floor((e.dayOfYear()-r-1)/7)+1,i,a;return o<1?(a=e.year()-1,i=o+ol(a,t,n)):o>ol(e.year(),t,n)?(i=o-ol(e.year(),t,n),a=e.year()+1):(a=e.year(),i=o),{week:i,year:a}}function ol(e,t,n){var r=ub(e,t,n),o=ub(e+1,t,n);return(Kh(e)-r+o)/7}Ke("w",["ww",2],"wo","week");Ke("W",["WW",2],"Wo","isoWeek");vo("week","w");vo("isoWeek","W");bo("week",5);bo("isoWeek",5);Me("w",Fn);Me("ww",Fn,Ti);Me("W",Fn);Me("WW",Fn,Ti);mp(["w","ww","W","WW"],function(e,t,n,r){t[r.substr(0,1)]=Nt(e)});function ome(e){return P0(e,this._week.dow,this._week.doy).week}var ime={dow:0,doy:6};function ame(){return this._week.dow}function sme(){return this._week.doy}function lme(e){var t=this.localeData().week(this);return e==null?t:this.add((e-t)*7,"d")}function ume(e){var t=P0(this,1,4).week;return e==null?t:this.add((e-t)*7,"d")}Ke("d",0,"do","day");Ke("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)});Ke("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)});Ke("dddd",0,0,function(e){return this.localeData().weekdays(this,e)});Ke("e",0,0,"weekday");Ke("E",0,0,"isoWeekday");vo("day","d");vo("weekday","e");vo("isoWeekday","E");bo("day",11);bo("weekday",11);bo("isoWeekday",11);Me("d",Fn);Me("e",Fn);Me("E",Fn);Me("dd",function(e,t){return t.weekdaysMinRegex(e)});Me("ddd",function(e,t){return t.weekdaysShortRegex(e)});Me("dddd",function(e,t){return t.weekdaysRegex(e)});mp(["dd","ddd","dddd"],function(e,t,n,r){var o=n._locale.weekdaysParse(e,r,n._strict);o!=null?t.d=o:yt(n).invalidWeekday=e});mp(["d","e","E"],function(e,t,n,r){t[r]=Nt(e)});function cme(e,t){return typeof e!="string"?e:isNaN(e)?(e=t.weekdaysParse(e),typeof e=="number"?e:null):parseInt(e,10)}function fme(e,t){return typeof e=="string"?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}function vw(e,t){return e.slice(t,7).concat(e.slice(0,t))}var dme="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),FP="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),hme="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),pme=pp,mme=pp,gme=pp;function vme(e,t){var n=Sa(this._weekdays)?this._weekdays:this._weekdays[e&&e!==!0&&this._weekdays.isFormat.test(t)?"format":"standalone"];return e===!0?vw(n,this._week.dow):e?n[e.day()]:n}function bme(e){return e===!0?vw(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort}function yme(e){return e===!0?vw(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin}function Eme(e,t,n){var r,o,i,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],r=0;r<7;++r)i=gs([2e3,1]).day(r),this._minWeekdaysParse[r]=this.weekdaysMin(i,"").toLocaleLowerCase(),this._shortWeekdaysParse[r]=this.weekdaysShort(i,"").toLocaleLowerCase(),this._weekdaysParse[r]=this.weekdays(i,"").toLocaleLowerCase();return n?t==="dddd"?(o=sr.call(this._weekdaysParse,a),o!==-1?o:null):t==="ddd"?(o=sr.call(this._shortWeekdaysParse,a),o!==-1?o:null):(o=sr.call(this._minWeekdaysParse,a),o!==-1?o:null):t==="dddd"?(o=sr.call(this._weekdaysParse,a),o!==-1||(o=sr.call(this._shortWeekdaysParse,a),o!==-1)?o:(o=sr.call(this._minWeekdaysParse,a),o!==-1?o:null)):t==="ddd"?(o=sr.call(this._shortWeekdaysParse,a),o!==-1||(o=sr.call(this._weekdaysParse,a),o!==-1)?o:(o=sr.call(this._minWeekdaysParse,a),o!==-1?o:null)):(o=sr.call(this._minWeekdaysParse,a),o!==-1||(o=sr.call(this._weekdaysParse,a),o!==-1)?o:(o=sr.call(this._shortWeekdaysParse,a),o!==-1?o:null))}function _me(e,t,n){var r,o,i;if(this._weekdaysParseExact)return Eme.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),r=0;r<7;r++){if(o=gs([2e3,1]).day(r),n&&!this._fullWeekdaysParse[r]&&(this._fullWeekdaysParse[r]=new RegExp("^"+this.weekdays(o,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[r]=new RegExp("^"+this.weekdaysShort(o,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[r]=new RegExp("^"+this.weekdaysMin(o,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[r]||(i="^"+this.weekdays(o,"")+"|^"+this.weekdaysShort(o,"")+"|^"+this.weekdaysMin(o,""),this._weekdaysParse[r]=new RegExp(i.replace(".",""),"i")),n&&t==="dddd"&&this._fullWeekdaysParse[r].test(e))return r;if(n&&t==="ddd"&&this._shortWeekdaysParse[r].test(e))return r;if(n&&t==="dd"&&this._minWeekdaysParse[r].test(e))return r;if(!n&&this._weekdaysParse[r].test(e))return r}}function Tme(e){if(!this.isValid())return e!=null?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return e!=null?(e=cme(e,this.localeData()),this.add(e-t,"d")):t}function wme(e){if(!this.isValid())return e!=null?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return e==null?t:this.add(e-t,"d")}function kme(e){if(!this.isValid())return e!=null?this:NaN;if(e!=null){var t=fme(e,this.localeData());return this.day(this.day()%7?t:t-7)}else return this.day()||7}function Sme(e){return this._weekdaysParseExact?(Wt(this,"_weekdaysRegex")||bw.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(Wt(this,"_weekdaysRegex")||(this._weekdaysRegex=pme),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)}function xme(e){return this._weekdaysParseExact?(Wt(this,"_weekdaysRegex")||bw.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(Wt(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=mme),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)}function Cme(e){return this._weekdaysParseExact?(Wt(this,"_weekdaysRegex")||bw.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(Wt(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=gme),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)}function bw(){function e(d,h){return h.length-d.length}var t=[],n=[],r=[],o=[],i,a,s,l,u;for(i=0;i<7;i++)a=gs([2e3,1]).day(i),s=pi(this.weekdaysMin(a,"")),l=pi(this.weekdaysShort(a,"")),u=pi(this.weekdays(a,"")),t.push(s),n.push(l),r.push(u),o.push(s),o.push(l),o.push(u);t.sort(e),n.sort(e),r.sort(e),o.sort(e),this._weekdaysRegex=new RegExp("^("+o.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+r.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+n.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+t.join("|")+")","i")}function yw(){return this.hours()%12||12}function Ame(){return this.hours()||24}Ke("H",["HH",2],0,"hour");Ke("h",["hh",2],0,yw);Ke("k",["kk",2],0,Ame);Ke("hmm",0,0,function(){return""+yw.apply(this)+fs(this.minutes(),2)});Ke("hmmss",0,0,function(){return""+yw.apply(this)+fs(this.minutes(),2)+fs(this.seconds(),2)});Ke("Hmm",0,0,function(){return""+this.hours()+fs(this.minutes(),2)});Ke("Hmmss",0,0,function(){return""+this.hours()+fs(this.minutes(),2)+fs(this.seconds(),2)});function IP(e,t){Ke(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}IP("a",!0);IP("A",!1);vo("hour","h");bo("hour",13);function BP(e,t){return t._meridiemParse}Me("a",BP);Me("A",BP);Me("H",Fn);Me("h",Fn);Me("k",Fn);Me("HH",Fn,Ti);Me("hh",Fn,Ti);Me("kk",Fn,Ti);Me("hmm",_P);Me("hmmss",TP);Me("Hmm",_P);Me("Hmmss",TP);cn(["H","HH"],Sr);cn(["k","kk"],function(e,t,n){var r=Nt(e);t[Sr]=r===24?0:r});cn(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e});cn(["h","hh"],function(e,t,n){t[Sr]=Nt(e),yt(n).bigHour=!0});cn("hmm",function(e,t,n){var r=e.length-2;t[Sr]=Nt(e.substr(0,r)),t[_a]=Nt(e.substr(r)),yt(n).bigHour=!0});cn("hmmss",function(e,t,n){var r=e.length-4,o=e.length-2;t[Sr]=Nt(e.substr(0,r)),t[_a]=Nt(e.substr(r,2)),t[tl]=Nt(e.substr(o)),yt(n).bigHour=!0});cn("Hmm",function(e,t,n){var r=e.length-2;t[Sr]=Nt(e.substr(0,r)),t[_a]=Nt(e.substr(r))});cn("Hmmss",function(e,t,n){var r=e.length-4,o=e.length-2;t[Sr]=Nt(e.substr(0,r)),t[_a]=Nt(e.substr(r,2)),t[tl]=Nt(e.substr(o))});function Nme(e){return(e+"").toLowerCase().charAt(0)==="p"}var Fme=/[ap]\.?m?\.?/i,Ime=f1("Hours",!0);function Bme(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"}var RP={calendar:_pe,longDateFormat:Spe,invalidDate:Cpe,ordinal:Npe,dayOfMonthOrdinalParse:Fpe,relativeTime:Bpe,months:Gpe,monthsShort:wP,week:ime,weekdays:dme,weekdaysMin:hme,weekdaysShort:FP,meridiemParse:Fme},On={},sh={},M0;function Rme(e,t){var n,r=Math.min(e.length,t.length);for(n=0;n<r;n+=1)if(e[n]!==t[n])return n;return r}function w7(e){return e&&e.toLowerCase().replace("_","-")}function Ome(e){for(var t=0,n,r,o,i;t<e.length;){for(i=w7(e[t]).split("-"),n=i.length,r=w7(e[t+1]),r=r?r.split("-"):null;n>0;){if(o=yy(i.slice(0,n).join("-")),o)return o;if(r&&r.length>=n&&Rme(i,r)>=n-1)break;n--}t++}return M0}function Dme(e){return e.match("^[^/\\\\]*$")!=null}function yy(e){var t=null,n;if(On[e]===void 0&&typeof rv<"u"&&rv&&rv.exports&&Dme(e))try{t=M0._abbr,n=require,n("./locale/"+e),Tu(t)}catch{On[e]=null}return On[e]}function Tu(e,t){var n;return e&&(Vo(t)?n=El(e):n=Ew(e,t),n?M0=n:typeof console<"u"&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),M0._abbr}function Ew(e,t){if(t!==null){var n,r=RP;if(t.abbr=e,On[e]!=null)mP("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),r=On[e]._config;else if(t.parentLocale!=null)if(On[t.parentLocale]!=null)r=On[t.parentLocale]._config;else if(n=yy(t.parentLocale),n!=null)r=n._config;else return sh[t.parentLocale]||(sh[t.parentLocale]=[]),sh[t.parentLocale].push({name:e,config:t}),null;return On[e]=new dw(G_(r,t)),sh[e]&&sh[e].forEach(function(o){Ew(o.name,o.config)}),Tu(e),On[e]}else return delete On[e],null}function Pme(e,t){if(t!=null){var n,r,o=RP;On[e]!=null&&On[e].parentLocale!=null?On[e].set(G_(On[e]._config,t)):(r=yy(e),r!=null&&(o=r._config),t=G_(o,t),r==null&&(t.abbr=e),n=new dw(t),n.parentLocale=On[e],On[e]=n),Tu(e)}else On[e]!=null&&(On[e].parentLocale!=null?(On[e]=On[e].parentLocale,e===Tu()&&Tu(e)):On[e]!=null&&delete On[e]);return On[e]}function El(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return M0;if(!Sa(e)){if(t=yy(e),t)return t;e=[e]}return Ome(e)}function Mme(){return K_(On)}function _w(e){var t,n=e._a;return n&&yt(e).overflow===-2&&(t=n[el]<0||n[el]>11?el:n[Ka]<1||n[Ka]>by(n[ho],n[el])?Ka:n[Sr]<0||n[Sr]>24||n[Sr]===24&&(n[_a]!==0||n[tl]!==0||n[xc]!==0)?Sr:n[_a]<0||n[_a]>59?_a:n[tl]<0||n[tl]>59?tl:n[xc]<0||n[xc]>999?xc:-1,yt(e)._overflowDayOfYear&&(t<ho||t>Ka)&&(t=Ka),yt(e)._overflowWeeks&&t===-1&&(t=qpe),yt(e)._overflowWeekday&&t===-1&&(t=$pe),yt(e).overflow=t),e}var Lme=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,jme=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,zme=/Z|[+-]\d\d(?::?\d\d)?/,Vm=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],R9=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Hme=/^\/?Date\((-?\d+)/i,Ume=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,qme={UT:0,GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function OP(e){var t,n,r=e._i,o=Lme.exec(r)||jme.exec(r),i,a,s,l,u=Vm.length,d=R9.length;if(o){for(yt(e).iso=!0,t=0,n=u;t<n;t++)if(Vm[t][1].exec(o[1])){a=Vm[t][0],i=Vm[t][2]!==!1;break}if(a==null){e._isValid=!1;return}if(o[3]){for(t=0,n=d;t<n;t++)if(R9[t][1].exec(o[3])){s=(o[2]||" ")+R9[t][0];break}if(s==null){e._isValid=!1;return}}if(!i&&s!=null){e._isValid=!1;return}if(o[4])if(zme.exec(o[4]))l="Z";else{e._isValid=!1;return}e._f=a+(s||"")+(l||""),ww(e)}else e._isValid=!1}function $me(e,t,n,r,o,i){var a=[Wme(e),wP.indexOf(t),parseInt(n,10),parseInt(r,10),parseInt(o,10)];return i&&a.push(parseInt(i,10)),a}function Wme(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function Gme(e){return e.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function Kme(e,t,n){if(e){var r=FP.indexOf(e),o=new Date(t[0],t[1],t[2]).getDay();if(r!==o)return yt(n).weekdayMismatch=!0,n._isValid=!1,!1}return!0}function Vme(e,t,n){if(e)return qme[e];if(t)return 0;var r=parseInt(n,10),o=r%100,i=(r-o)/100;return i*60+o}function DP(e){var t=Ume.exec(Gme(e._i)),n;if(t){if(n=$me(t[4],t[3],t[2],t[5],t[6],t[7]),!Kme(t[1],n,e))return;e._a=n,e._tzm=Vme(t[8],t[9],t[10]),e._d=D0.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),yt(e).rfc2822=!0}else e._isValid=!1}function Yme(e){var t=Hme.exec(e._i);if(t!==null){e._d=new Date(+t[1]);return}if(OP(e),e._isValid===!1)delete e._isValid;else return;if(DP(e),e._isValid===!1)delete e._isValid;else return;e._strict?e._isValid=!1:De.createFromInputFallback(e)}De.createFromInputFallback=ta("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))});function Kf(e,t,n){return e??t??n}function Qme(e){var t=new Date(De.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}function Tw(e){var t,n,r=[],o,i,a;if(!e._d){for(o=Qme(e),e._w&&e._a[Ka]==null&&e._a[el]==null&&Xme(e),e._dayOfYear!=null&&(a=Kf(e._a[ho],o[ho]),(e._dayOfYear>Kh(a)||e._dayOfYear===0)&&(yt(e)._overflowDayOfYear=!0),n=D0(a,0,e._dayOfYear),e._a[el]=n.getUTCMonth(),e._a[Ka]=n.getUTCDate()),t=0;t<3&&e._a[t]==null;++t)e._a[t]=r[t]=o[t];for(;t<7;t++)e._a[t]=r[t]=e._a[t]==null?t===2?1:0:e._a[t];e._a[Sr]===24&&e._a[_a]===0&&e._a[tl]===0&&e._a[xc]===0&&(e._nextDay=!0,e._a[Sr]=0),e._d=(e._useUTC?D0:rme).apply(null,r),i=e._useUTC?e._d.getUTCDay():e._d.getDay(),e._tzm!=null&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[Sr]=24),e._w&&typeof e._w.d<"u"&&e._w.d!==i&&(yt(e).weekdayMismatch=!0)}}function Xme(e){var t,n,r,o,i,a,s,l,u;t=e._w,t.GG!=null||t.W!=null||t.E!=null?(i=1,a=4,n=Kf(t.GG,e._a[ho],P0(Nn(),1,4).year),r=Kf(t.W,1),o=Kf(t.E,1),(o<1||o>7)&&(l=!0)):(i=e._locale._week.dow,a=e._locale._week.doy,u=P0(Nn(),i,a),n=Kf(t.gg,e._a[ho],u.year),r=Kf(t.w,u.week),t.d!=null?(o=t.d,(o<0||o>6)&&(l=!0)):t.e!=null?(o=t.e+i,(t.e<0||t.e>6)&&(l=!0)):o=i),r<1||r>ol(n,i,a)?yt(e)._overflowWeeks=!0:l!=null?yt(e)._overflowWeekday=!0:(s=NP(n,r,o,i,a),e._a[ho]=s.year,e._dayOfYear=s.dayOfYear)}De.ISO_8601=function(){};De.RFC_2822=function(){};function ww(e){if(e._f===De.ISO_8601){OP(e);return}if(e._f===De.RFC_2822){DP(e);return}e._a=[],yt(e).empty=!0;var t=""+e._i,n,r,o,i,a,s=t.length,l=0,u,d;for(o=gP(e._f,e._locale).match(hw)||[],d=o.length,n=0;n<d;n++)i=o[n],r=(t.match(zpe(i,e))||[])[0],r&&(a=t.substr(0,t.indexOf(r)),a.length>0&&yt(e).unusedInput.push(a),t=t.slice(t.indexOf(r)+r.length),l+=r.length),Nd[i]?(r?yt(e).empty=!1:yt(e).unusedTokens.push(i),Upe(i,r,e)):e._strict&&!r&&yt(e).unusedTokens.push(i);yt(e).charsLeftOver=s-l,t.length>0&&yt(e).unusedInput.push(t),e._a[Sr]<=12&&yt(e).bigHour===!0&&e._a[Sr]>0&&(yt(e).bigHour=void 0),yt(e).parsedDateParts=e._a.slice(0),yt(e).meridiem=e._meridiem,e._a[Sr]=Zme(e._locale,e._a[Sr],e._meridiem),u=yt(e).era,u!==null&&(e._a[ho]=e._locale.erasConvertYear(u,e._a[ho])),Tw(e),_w(e)}function Zme(e,t,n){var r;return n==null?t:e.meridiemHour!=null?e.meridiemHour(t,n):(e.isPM!=null&&(r=e.isPM(n),r&&t<12&&(t+=12),!r&&t===12&&(t=0)),t)}function Jme(e){var t,n,r,o,i,a,s=!1,l=e._f.length;if(l===0){yt(e).invalidFormat=!0,e._d=new Date(NaN);return}for(o=0;o<l;o++)i=0,a=!1,t=fw({},e),e._useUTC!=null&&(t._useUTC=e._useUTC),t._f=e._f[o],ww(t),cw(t)&&(a=!0),i+=yt(t).charsLeftOver,i+=yt(t).unusedTokens.length*10,yt(t).score=i,s?i<r&&(r=i,n=t):(r==null||i<r||a)&&(r=i,n=t,a&&(s=!0));au(e,n||t)}function ege(e){if(!e._d){var t=pw(e._i),n=t.day===void 0?t.date:t.day;e._a=hP([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],function(r){return r&&parseInt(r,10)}),Tw(e)}}function tge(e){var t=new hp(_w(PP(e)));return t._nextDay&&(t.add(1,"d"),t._nextDay=void 0),t}function PP(e){var t=e._i,n=e._f;return e._locale=e._locale||El(e._l),t===null||n===void 0&&t===""?fy({nullInput:!0}):(typeof t=="string"&&(e._i=t=e._locale.preparse(t)),xa(t)?new hp(_w(t)):(dp(t)?e._d=t:Sa(n)?Jme(e):n?ww(e):nge(e),cw(e)||(e._d=null),e))}function nge(e){var t=e._i;Vo(t)?e._d=new Date(De.now()):dp(t)?e._d=new Date(t.valueOf()):typeof t=="string"?Yme(e):Sa(t)?(e._a=hP(t.slice(0),function(n){return parseInt(n,10)}),Tw(e)):Bc(t)?ege(e):fl(t)?e._d=new Date(t):De.createFromInputFallback(e)}function MP(e,t,n,r,o){var i={};return(t===!0||t===!1)&&(r=t,t=void 0),(n===!0||n===!1)&&(r=n,n=void 0),(Bc(e)&&uw(e)||Sa(e)&&e.length===0)&&(e=void 0),i._isAMomentObject=!0,i._useUTC=i._isUTC=o,i._l=n,i._i=e,i._f=t,i._strict=r,tge(i)}function Nn(e,t,n,r){return MP(e,t,n,r,!1)}var rge=ta("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Nn.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:fy()}),oge=ta("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",function(){var e=Nn.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:fy()});function LP(e,t){var n,r;if(t.length===1&&Sa(t[0])&&(t=t[0]),!t.length)return Nn();for(n=t[0],r=1;r<t.length;++r)(!t[r].isValid()||t[r][e](n))&&(n=t[r]);return n}function ige(){var e=[].slice.call(arguments,0);return LP("isBefore",e)}function age(){var e=[].slice.call(arguments,0);return LP("isAfter",e)}var sge=function(){return Date.now?Date.now():+new Date},lh=["year","quarter","month","week","day","hour","minute","second","millisecond"];function lge(e){var t,n=!1,r,o=lh.length;for(t in e)if(Wt(e,t)&&!(sr.call(lh,t)!==-1&&(e[t]==null||!isNaN(e[t]))))return!1;for(r=0;r<o;++r)if(e[lh[r]]){if(n)return!1;parseFloat(e[lh[r]])!==Nt(e[lh[r]])&&(n=!0)}return!0}function uge(){return this._isValid}function cge(){return Ca(NaN)}function Ey(e){var t=pw(e),n=t.year||0,r=t.quarter||0,o=t.month||0,i=t.week||t.isoWeek||0,a=t.day||0,s=t.hour||0,l=t.minute||0,u=t.second||0,d=t.millisecond||0;this._isValid=lge(t),this._milliseconds=+d+u*1e3+l*6e4+s*1e3*60*60,this._days=+a+i*7,this._months=+o+r*3+n*12,this._data={},this._locale=El(),this._bubble()}function Gg(e){return e instanceof Ey}function Y_(e){return e<0?Math.round(-1*e)*-1:Math.round(e)}function fge(e,t,n){var r=Math.min(e.length,t.length),o=Math.abs(e.length-t.length),i=0,a;for(a=0;a<r;a++)(n&&e[a]!==t[a]||!n&&Nt(e[a])!==Nt(t[a]))&&i++;return i+o}function jP(e,t){Ke(e,0,0,function(){var n=this.utcOffset(),r="+";return n<0&&(n=-n,r="-"),r+fs(~~(n/60),2)+t+fs(~~n%60,2)})}jP("Z",":");jP("ZZ","");Me("Z",vy);Me("ZZ",vy);cn(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=kw(vy,e)});var dge=/([\+\-]|\d\d)/gi;function kw(e,t){var n=(t||"").match(e),r,o,i;return n===null?null:(r=n[n.length-1]||[],o=(r+"").match(dge)||["-",0,0],i=+(o[1]*60)+Nt(o[2]),i===0?0:o[0]==="+"?i:-i)}function Sw(e,t){var n,r;return t._isUTC?(n=t.clone(),r=(xa(e)||dp(e)?e.valueOf():Nn(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+r),De.updateOffset(n,!1),n):Nn(e).local()}function Q_(e){return-Math.round(e._d.getTimezoneOffset())}De.updateOffset=function(){};function hge(e,t,n){var r=this._offset||0,o;if(!this.isValid())return e!=null?this:NaN;if(e!=null){if(typeof e=="string"){if(e=kw(vy,e),e===null)return this}else Math.abs(e)<16&&!n&&(e=e*60);return!this._isUTC&&t&&(o=Q_(this)),this._offset=e,this._isUTC=!0,o!=null&&this.add(o,"m"),r!==e&&(!t||this._changeInProgress?UP(this,Ca(e-r,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,De.updateOffset(this,!0),this._changeInProgress=null)),this}else return this._isUTC?r:Q_(this)}function pge(e,t){return e!=null?(typeof e!="string"&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}function mge(e){return this.utcOffset(0,e)}function gge(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Q_(this),"m")),this}function vge(){if(this._tzm!=null)this.utcOffset(this._tzm,!1,!0);else if(typeof this._i=="string"){var e=kw(Lpe,this._i);e!=null?this.utcOffset(e):this.utcOffset(0,!0)}return this}function bge(e){return this.isValid()?(e=e?Nn(e).utcOffset():0,(this.utcOffset()-e)%60===0):!1}function yge(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()}function Ege(){if(!Vo(this._isDSTShifted))return this._isDSTShifted;var e={},t;return fw(e,this),e=PP(e),e._a?(t=e._isUTC?gs(e._a):Nn(e._a),this._isDSTShifted=this.isValid()&&fge(e._a,t.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}function _ge(){return this.isValid()?!this._isUTC:!1}function Tge(){return this.isValid()?this._isUTC:!1}function zP(){return this.isValid()?this._isUTC&&this._offset===0:!1}var wge=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,kge=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Ca(e,t){var n=e,r=null,o,i,a;return Gg(e)?n={ms:e._milliseconds,d:e._days,M:e._months}:fl(e)||!isNaN(+e)?(n={},t?n[t]=+e:n.milliseconds=+e):(r=wge.exec(e))?(o=r[1]==="-"?-1:1,n={y:0,d:Nt(r[Ka])*o,h:Nt(r[Sr])*o,m:Nt(r[_a])*o,s:Nt(r[tl])*o,ms:Nt(Y_(r[xc]*1e3))*o}):(r=kge.exec(e))?(o=r[1]==="-"?-1:1,n={y:ic(r[2],o),M:ic(r[3],o),w:ic(r[4],o),d:ic(r[5],o),h:ic(r[6],o),m:ic(r[7],o),s:ic(r[8],o)}):n==null?n={}:typeof n=="object"&&("from"in n||"to"in n)&&(a=Sge(Nn(n.from),Nn(n.to)),n={},n.ms=a.milliseconds,n.M=a.months),i=new Ey(n),Gg(e)&&Wt(e,"_locale")&&(i._locale=e._locale),Gg(e)&&Wt(e,"_isValid")&&(i._isValid=e._isValid),i}Ca.fn=Ey.prototype;Ca.invalid=cge;function ic(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function k7(e,t){var n={};return n.months=t.month()-e.month()+(t.year()-e.year())*12,e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Sge(e,t){var n;return e.isValid()&&t.isValid()?(t=Sw(t,e),e.isBefore(t)?n=k7(e,t):(n=k7(t,e),n.milliseconds=-n.milliseconds,n.months=-n.months),n):{milliseconds:0,months:0}}function HP(e,t){return function(n,r){var o,i;return r!==null&&!isNaN(+r)&&(mP(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),i=n,n=r,r=i),o=Ca(n,r),UP(this,o,e),this}}function UP(e,t,n,r){var o=t._milliseconds,i=Y_(t._days),a=Y_(t._months);e.isValid()&&(r=r??!0,a&&SP(e,sb(e,"Month")+a*n),i&&bP(e,"Date",sb(e,"Date")+i*n),o&&e._d.setTime(e._d.valueOf()+o*n),r&&De.updateOffset(e,i||a))}var xge=HP(1,"add"),Cge=HP(-1,"subtract");function qP(e){return typeof e=="string"||e instanceof String}function Age(e){return xa(e)||dp(e)||qP(e)||fl(e)||Fge(e)||Nge(e)||e===null||e===void 0}function Nge(e){var t=Bc(e)&&!uw(e),n=!1,r=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],o,i,a=r.length;for(o=0;o<a;o+=1)i=r[o],n=n||Wt(e,i);return t&&n}function Fge(e){var t=Sa(e),n=!1;return t&&(n=e.filter(function(r){return!fl(r)&&qP(e)}).length===0),t&&n}function Ige(e){var t=Bc(e)&&!uw(e),n=!1,r=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"],o,i;for(o=0;o<r.length;o+=1)i=r[o],n=n||Wt(e,i);return t&&n}function Bge(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"}function Rge(e,t){arguments.length===1&&(arguments[0]?Age(arguments[0])?(e=arguments[0],t=void 0):Ige(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var n=e||Nn(),r=Sw(n,this).startOf("day"),o=De.calendarFormat(this,r)||"sameElse",i=t&&(vs(t[o])?t[o].call(this,n):t[o]);return this.format(i||this.localeData().calendar(o,this,Nn(n)))}function Oge(){return new hp(this)}function Dge(e,t){var n=xa(e)?e:Nn(e);return this.isValid()&&n.isValid()?(t=na(t)||"millisecond",t==="millisecond"?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf()):!1}function Pge(e,t){var n=xa(e)?e:Nn(e);return this.isValid()&&n.isValid()?(t=na(t)||"millisecond",t==="millisecond"?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf()):!1}function Mge(e,t,n,r){var o=xa(e)?e:Nn(e),i=xa(t)?t:Nn(t);return this.isValid()&&o.isValid()&&i.isValid()?(r=r||"()",(r[0]==="("?this.isAfter(o,n):!this.isBefore(o,n))&&(r[1]===")"?this.isBefore(i,n):!this.isAfter(i,n))):!1}function Lge(e,t){var n=xa(e)?e:Nn(e),r;return this.isValid()&&n.isValid()?(t=na(t)||"millisecond",t==="millisecond"?this.valueOf()===n.valueOf():(r=n.valueOf(),this.clone().startOf(t).valueOf()<=r&&r<=this.clone().endOf(t).valueOf())):!1}function jge(e,t){return this.isSame(e,t)||this.isAfter(e,t)}function zge(e,t){return this.isSame(e,t)||this.isBefore(e,t)}function Hge(e,t,n){var r,o,i;if(!this.isValid())return NaN;if(r=Sw(e,this),!r.isValid())return NaN;switch(o=(r.utcOffset()-this.utcOffset())*6e4,t=na(t),t){case"year":i=Kg(this,r)/12;break;case"month":i=Kg(this,r);break;case"quarter":i=Kg(this,r)/3;break;case"second":i=(this-r)/1e3;break;case"minute":i=(this-r)/6e4;break;case"hour":i=(this-r)/36e5;break;case"day":i=(this-r-o)/864e5;break;case"week":i=(this-r-o)/6048e5;break;default:i=this-r}return n?i:ji(i)}function Kg(e,t){if(e.date()<t.date())return-Kg(t,e);var n=(t.year()-e.year())*12+(t.month()-e.month()),r=e.clone().add(n,"months"),o,i;return t-r<0?(o=e.clone().add(n-1,"months"),i=(t-r)/(r-o)):(o=e.clone().add(n+1,"months"),i=(t-r)/(o-r)),-(n+i)||0}De.defaultFormat="YYYY-MM-DDTHH:mm:ssZ";De.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";function Uge(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")}function qge(e){if(!this.isValid())return null;var t=e!==!0,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?Wg(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):vs(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+this.utcOffset()*60*1e3).toISOString().replace("Z",Wg(n,"Z")):Wg(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")}function $ge(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e="moment",t="",n,r,o,i;return this.isLocal()||(e=this.utcOffset()===0?"moment.utc":"moment.parseZone",t="Z"),n="["+e+'("]',r=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",o="-MM-DD[T]HH:mm:ss.SSS",i=t+'[")]',this.format(n+r+o+i)}function Wge(e){e||(e=this.isUtc()?De.defaultFormatUtc:De.defaultFormat);var t=Wg(this,e);return this.localeData().postformat(t)}function Gge(e,t){return this.isValid()&&(xa(e)&&e.isValid()||Nn(e).isValid())?Ca({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function Kge(e){return this.from(Nn(),e)}function Vge(e,t){return this.isValid()&&(xa(e)&&e.isValid()||Nn(e).isValid())?Ca({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()}function Yge(e){return this.to(Nn(),e)}function $P(e){var t;return e===void 0?this._locale._abbr:(t=El(e),t!=null&&(this._locale=t),this)}var WP=ta("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return e===void 0?this.localeData():this.locale(e)});function GP(){return this._locale}var cb=1e3,Fd=60*cb,fb=60*Fd,KP=(365*400+97)*24*fb;function Id(e,t){return(e%t+t)%t}function VP(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-KP:new Date(e,t,n).valueOf()}function YP(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-KP:Date.UTC(e,t,n)}function Qge(e){var t,n;if(e=na(e),e===void 0||e==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?YP:VP,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=Id(t+(this._isUTC?0:this.utcOffset()*Fd),fb);break;case"minute":t=this._d.valueOf(),t-=Id(t,Fd);break;case"second":t=this._d.valueOf(),t-=Id(t,cb);break}return this._d.setTime(t),De.updateOffset(this,!0),this}function Xge(e){var t,n;if(e=na(e),e===void 0||e==="millisecond"||!this.isValid())return this;switch(n=this._isUTC?YP:VP,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=fb-Id(t+(this._isUTC?0:this.utcOffset()*Fd),fb)-1;break;case"minute":t=this._d.valueOf(),t+=Fd-Id(t,Fd)-1;break;case"second":t=this._d.valueOf(),t+=cb-Id(t,cb)-1;break}return this._d.setTime(t),De.updateOffset(this,!0),this}function Zge(){return this._d.valueOf()-(this._offset||0)*6e4}function Jge(){return Math.floor(this.valueOf()/1e3)}function eve(){return new Date(this.valueOf())}function tve(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]}function nve(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}}function rve(){return this.isValid()?this.toISOString():null}function ove(){return cw(this)}function ive(){return au({},yt(this))}function ave(){return yt(this).overflow}function sve(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}}Ke("N",0,0,"eraAbbr");Ke("NN",0,0,"eraAbbr");Ke("NNN",0,0,"eraAbbr");Ke("NNNN",0,0,"eraName");Ke("NNNNN",0,0,"eraNarrow");Ke("y",["y",1],"yo","eraYear");Ke("y",["yy",2],0,"eraYear");Ke("y",["yyy",3],0,"eraYear");Ke("y",["yyyy",4],0,"eraYear");Me("N",xw);Me("NN",xw);Me("NNN",xw);Me("NNNN",bve);Me("NNNNN",yve);cn(["N","NN","NNN","NNNN","NNNNN"],function(e,t,n,r){var o=n._locale.erasParse(e,r,n._strict);o?yt(n).era=o:yt(n).invalidEra=e});Me("y",d1);Me("yy",d1);Me("yyy",d1);Me("yyyy",d1);Me("yo",Eve);cn(["y","yy","yyy","yyyy"],ho);cn(["yo"],function(e,t,n,r){var o;n._locale._eraYearOrdinalRegex&&(o=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[ho]=n._locale.eraYearOrdinalParse(e,o):t[ho]=parseInt(e,10)});function lve(e,t){var n,r,o,i=this._eras||El("en")._eras;for(n=0,r=i.length;n<r;++n){switch(typeof i[n].since){case"string":o=De(i[n].since).startOf("day"),i[n].since=o.valueOf();break}switch(typeof i[n].until){case"undefined":i[n].until=1/0;break;case"string":o=De(i[n].until).startOf("day").valueOf(),i[n].until=o.valueOf();break}}return i}function uve(e,t,n){var r,o,i=this.eras(),a,s,l;for(e=e.toUpperCase(),r=0,o=i.length;r<o;++r)if(a=i[r].name.toUpperCase(),s=i[r].abbr.toUpperCase(),l=i[r].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(s===e)return i[r];break;case"NNNN":if(a===e)return i[r];break;case"NNNNN":if(l===e)return i[r];break}else if([a,s,l].indexOf(e)>=0)return i[r]}function cve(e,t){var n=e.since<=e.until?1:-1;return t===void 0?De(e.since).year():De(e.since).year()+(t-e.offset)*n}function fve(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until||r[e].until<=n&&n<=r[e].since)return r[e].name;return""}function dve(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until||r[e].until<=n&&n<=r[e].since)return r[e].narrow;return""}function hve(){var e,t,n,r=this.localeData().eras();for(e=0,t=r.length;e<t;++e)if(n=this.clone().startOf("day").valueOf(),r[e].since<=n&&n<=r[e].until||r[e].until<=n&&n<=r[e].since)return r[e].abbr;return""}function pve(){var e,t,n,r,o=this.localeData().eras();for(e=0,t=o.length;e<t;++e)if(n=o[e].since<=o[e].until?1:-1,r=this.clone().startOf("day").valueOf(),o[e].since<=r&&r<=o[e].until||o[e].until<=r&&r<=o[e].since)return(this.year()-De(o[e].since).year())*n+o[e].offset;return this.year()}function mve(e){return Wt(this,"_erasNameRegex")||Cw.call(this),e?this._erasNameRegex:this._erasRegex}function gve(e){return Wt(this,"_erasAbbrRegex")||Cw.call(this),e?this._erasAbbrRegex:this._erasRegex}function vve(e){return Wt(this,"_erasNarrowRegex")||Cw.call(this),e?this._erasNarrowRegex:this._erasRegex}function xw(e,t){return t.erasAbbrRegex(e)}function bve(e,t){return t.erasNameRegex(e)}function yve(e,t){return t.erasNarrowRegex(e)}function Eve(e,t){return t._eraYearOrdinalRegex||d1}function Cw(){var e=[],t=[],n=[],r=[],o,i,a=this.eras();for(o=0,i=a.length;o<i;++o)t.push(pi(a[o].name)),e.push(pi(a[o].abbr)),n.push(pi(a[o].narrow)),r.push(pi(a[o].name)),r.push(pi(a[o].abbr)),r.push(pi(a[o].narrow));this._erasRegex=new RegExp("^("+r.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+t.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+e.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+n.join("|")+")","i")}Ke(0,["gg",2],0,function(){return this.weekYear()%100});Ke(0,["GG",2],0,function(){return this.isoWeekYear()%100});function _y(e,t){Ke(0,[e,e.length],0,t)}_y("gggg","weekYear");_y("ggggg","weekYear");_y("GGGG","isoWeekYear");_y("GGGGG","isoWeekYear");vo("weekYear","gg");vo("isoWeekYear","GG");bo("weekYear",1);bo("isoWeekYear",1);Me("G",gy);Me("g",gy);Me("GG",Fn,Ti);Me("gg",Fn,Ti);Me("GGGG",gw,mw);Me("gggg",gw,mw);Me("GGGGG",my,hy);Me("ggggg",my,hy);mp(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,r){t[r.substr(0,2)]=Nt(e)});mp(["gg","GG"],function(e,t,n,r){t[r]=De.parseTwoDigitYear(e)});function _ve(e){return QP.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)}function Tve(e){return QP.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)}function wve(){return ol(this.year(),1,4)}function kve(){return ol(this.isoWeekYear(),1,4)}function Sve(){var e=this.localeData()._week;return ol(this.year(),e.dow,e.doy)}function xve(){var e=this.localeData()._week;return ol(this.weekYear(),e.dow,e.doy)}function QP(e,t,n,r,o){var i;return e==null?P0(this,r,o).year:(i=ol(e,r,o),t>i&&(t=i),Cve.call(this,e,t,n,r,o))}function Cve(e,t,n,r,o){var i=NP(e,t,n,r,o),a=D0(i.year,0,i.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}Ke("Q",0,"Qo","quarter");vo("quarter","Q");bo("quarter",7);Me("Q",yP);cn("Q",function(e,t){t[el]=(Nt(e)-1)*3});function Ave(e){return e==null?Math.ceil((this.month()+1)/3):this.month((e-1)*3+this.month()%3)}Ke("D",["DD",2],"Do","date");vo("date","D");bo("date",9);Me("D",Fn);Me("DD",Fn,Ti);Me("Do",function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient});cn(["D","DD"],Ka);cn("Do",function(e,t){t[Ka]=Nt(e.match(Fn)[0])});var XP=f1("Date",!0);Ke("DDD",["DDDD",3],"DDDo","dayOfYear");vo("dayOfYear","DDD");bo("dayOfYear",4);Me("DDD",py);Me("DDDD",EP);cn(["DDD","DDDD"],function(e,t,n){n._dayOfYear=Nt(e)});function Nve(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return e==null?t:this.add(e-t,"d")}Ke("m",["mm",2],0,"minute");vo("minute","m");bo("minute",14);Me("m",Fn);Me("mm",Fn,Ti);cn(["m","mm"],_a);var Fve=f1("Minutes",!1);Ke("s",["ss",2],0,"second");vo("second","s");bo("second",15);Me("s",Fn);Me("ss",Fn,Ti);cn(["s","ss"],tl);var Ive=f1("Seconds",!1);Ke("S",0,0,function(){return~~(this.millisecond()/100)});Ke(0,["SS",2],0,function(){return~~(this.millisecond()/10)});Ke(0,["SSS",3],0,"millisecond");Ke(0,["SSSS",4],0,function(){return this.millisecond()*10});Ke(0,["SSSSS",5],0,function(){return this.millisecond()*100});Ke(0,["SSSSSS",6],0,function(){return this.millisecond()*1e3});Ke(0,["SSSSSSS",7],0,function(){return this.millisecond()*1e4});Ke(0,["SSSSSSSS",8],0,function(){return this.millisecond()*1e5});Ke(0,["SSSSSSSSS",9],0,function(){return this.millisecond()*1e6});vo("millisecond","ms");bo("millisecond",16);Me("S",py,yP);Me("SS",py,Ti);Me("SSS",py,EP);var su,ZP;for(su="SSSS";su.length<=9;su+="S")Me(su,d1);function Bve(e,t){t[xc]=Nt(("0."+e)*1e3)}for(su="S";su.length<=9;su+="S")cn(su,Bve);ZP=f1("Milliseconds",!1);Ke("z",0,0,"zoneAbbr");Ke("zz",0,0,"zoneName");function Rve(){return this._isUTC?"UTC":""}function Ove(){return this._isUTC?"Coordinated Universal Time":""}var xe=hp.prototype;xe.add=xge;xe.calendar=Rge;xe.clone=Oge;xe.diff=Hge;xe.endOf=Xge;xe.format=Wge;xe.from=Gge;xe.fromNow=Kge;xe.to=Vge;xe.toNow=Yge;xe.get=Ppe;xe.invalidAt=ave;xe.isAfter=Dge;xe.isBefore=Pge;xe.isBetween=Mge;xe.isSame=Lge;xe.isSameOrAfter=jge;xe.isSameOrBefore=zge;xe.isValid=ove;xe.lang=WP;xe.locale=$P;xe.localeData=GP;xe.max=oge;xe.min=rge;xe.parsingFlags=ive;xe.set=Mpe;xe.startOf=Qge;xe.subtract=Cge;xe.toArray=tve;xe.toObject=nve;xe.toDate=eve;xe.toISOString=qge;xe.inspect=$ge;typeof Symbol<"u"&&Symbol.for!=null&&(xe[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"});xe.toJSON=rve;xe.toString=Uge;xe.unix=Jge;xe.valueOf=Zge;xe.creationData=sve;xe.eraName=fve;xe.eraNarrow=dve;xe.eraAbbr=hve;xe.eraYear=pve;xe.year=AP;xe.isLeapYear=nme;xe.weekYear=_ve;xe.isoWeekYear=Tve;xe.quarter=xe.quarters=Ave;xe.month=xP;xe.daysInMonth=Jpe;xe.week=xe.weeks=lme;xe.isoWeek=xe.isoWeeks=ume;xe.weeksInYear=Sve;xe.weeksInWeekYear=xve;xe.isoWeeksInYear=wve;xe.isoWeeksInISOWeekYear=kve;xe.date=XP;xe.day=xe.days=Tme;xe.weekday=wme;xe.isoWeekday=kme;xe.dayOfYear=Nve;xe.hour=xe.hours=Ime;xe.minute=xe.minutes=Fve;xe.second=xe.seconds=Ive;xe.millisecond=xe.milliseconds=ZP;xe.utcOffset=hge;xe.utc=mge;xe.local=gge;xe.parseZone=vge;xe.hasAlignedHourOffset=bge;xe.isDST=yge;xe.isLocal=_ge;xe.isUtcOffset=Tge;xe.isUtc=zP;xe.isUTC=zP;xe.zoneAbbr=Rve;xe.zoneName=Ove;xe.dates=ta("dates accessor is deprecated. Use date instead.",XP);xe.months=ta("months accessor is deprecated. Use month instead",xP);xe.years=ta("years accessor is deprecated. Use year instead",AP);xe.zone=ta("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",pge);xe.isDSTShifted=ta("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",Ege);function Dve(e){return Nn(e*1e3)}function Pve(){return Nn.apply(null,arguments).parseZone()}function JP(e){return e}var Gt=dw.prototype;Gt.calendar=Tpe;Gt.longDateFormat=xpe;Gt.invalidDate=Ape;Gt.ordinal=Ipe;Gt.preparse=JP;Gt.postformat=JP;Gt.relativeTime=Rpe;Gt.pastFuture=Ope;Gt.set=Epe;Gt.eras=lve;Gt.erasParse=uve;Gt.erasConvertYear=cve;Gt.erasAbbrRegex=gve;Gt.erasNameRegex=mve;Gt.erasNarrowRegex=vve;Gt.months=Ype;Gt.monthsShort=Qpe;Gt.monthsParse=Zpe;Gt.monthsRegex=tme;Gt.monthsShortRegex=eme;Gt.week=ome;Gt.firstDayOfYear=sme;Gt.firstDayOfWeek=ame;Gt.weekdays=vme;Gt.weekdaysMin=yme;Gt.weekdaysShort=bme;Gt.weekdaysParse=_me;Gt.weekdaysRegex=Sme;Gt.weekdaysShortRegex=xme;Gt.weekdaysMinRegex=Cme;Gt.isPM=Nme;Gt.meridiem=Bme;function db(e,t,n,r){var o=El(),i=gs().set(r,t);return o[n](i,e)}function eM(e,t,n){if(fl(e)&&(t=e,e=void 0),e=e||"",t!=null)return db(e,t,n,"month");var r,o=[];for(r=0;r<12;r++)o[r]=db(e,r,n,"month");return o}function Aw(e,t,n,r){typeof e=="boolean"?(fl(t)&&(n=t,t=void 0),t=t||""):(t=e,n=t,e=!1,fl(t)&&(n=t,t=void 0),t=t||"");var o=El(),i=e?o._week.dow:0,a,s=[];if(n!=null)return db(t,(n+i)%7,r,"day");for(a=0;a<7;a++)s[a]=db(t,(a+i)%7,r,"day");return s}function Mve(e,t){return eM(e,t,"months")}function Lve(e,t){return eM(e,t,"monthsShort")}function jve(e,t,n){return Aw(e,t,n,"weekdays")}function zve(e,t,n){return Aw(e,t,n,"weekdaysShort")}function Hve(e,t,n){return Aw(e,t,n,"weekdaysMin")}Tu("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10,n=Nt(e%100/10)===1?"th":t===1?"st":t===2?"nd":t===3?"rd":"th";return e+n}});De.lang=ta("moment.lang is deprecated. Use moment.locale instead.",Tu);De.langData=ta("moment.langData is deprecated. Use moment.localeData instead.",El);var Rs=Math.abs;function Uve(){var e=this._data;return this._milliseconds=Rs(this._milliseconds),this._days=Rs(this._days),this._months=Rs(this._months),e.milliseconds=Rs(e.milliseconds),e.seconds=Rs(e.seconds),e.minutes=Rs(e.minutes),e.hours=Rs(e.hours),e.months=Rs(e.months),e.years=Rs(e.years),this}function tM(e,t,n,r){var o=Ca(t,n);return e._milliseconds+=r*o._milliseconds,e._days+=r*o._days,e._months+=r*o._months,e._bubble()}function qve(e,t){return tM(this,e,t,1)}function $ve(e,t){return tM(this,e,t,-1)}function S7(e){return e<0?Math.floor(e):Math.ceil(e)}function Wve(){var e=this._milliseconds,t=this._days,n=this._months,r=this._data,o,i,a,s,l;return e>=0&&t>=0&&n>=0||e<=0&&t<=0&&n<=0||(e+=S7(X_(n)+t)*864e5,t=0,n=0),r.milliseconds=e%1e3,o=ji(e/1e3),r.seconds=o%60,i=ji(o/60),r.minutes=i%60,a=ji(i/60),r.hours=a%24,t+=ji(a/24),l=ji(nM(t)),n+=l,t-=S7(X_(l)),s=ji(n/12),n%=12,r.days=t,r.months=n,r.years=s,this}function nM(e){return e*4800/146097}function X_(e){return e*146097/4800}function Gve(e){if(!this.isValid())return NaN;var t,n,r=this._milliseconds;if(e=na(e),e==="month"||e==="quarter"||e==="year")switch(t=this._days+r/864e5,n=this._months+nM(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(X_(this._months)),e){case"week":return t/7+r/6048e5;case"day":return t+r/864e5;case"hour":return t*24+r/36e5;case"minute":return t*1440+r/6e4;case"second":return t*86400+r/1e3;case"millisecond":return Math.floor(t*864e5)+r;default:throw new Error("Unknown unit "+e)}}function Kve(){return this.isValid()?this._milliseconds+this._days*864e5+this._months%12*2592e6+Nt(this._months/12)*31536e6:NaN}function _l(e){return function(){return this.as(e)}}var Vve=_l("ms"),Yve=_l("s"),Qve=_l("m"),Xve=_l("h"),Zve=_l("d"),Jve=_l("w"),ebe=_l("M"),tbe=_l("Q"),nbe=_l("y");function rbe(){return Ca(this)}function obe(e){return e=na(e),this.isValid()?this[e+"s"]():NaN}function Kc(e){return function(){return this.isValid()?this._data[e]:NaN}}var ibe=Kc("milliseconds"),abe=Kc("seconds"),sbe=Kc("minutes"),lbe=Kc("hours"),ube=Kc("days"),cbe=Kc("months"),fbe=Kc("years");function dbe(){return ji(this.days()/7)}var $s=Math.round,ad={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function hbe(e,t,n,r,o){return o.relativeTime(t||1,!!n,e,r)}function pbe(e,t,n,r){var o=Ca(e).abs(),i=$s(o.as("s")),a=$s(o.as("m")),s=$s(o.as("h")),l=$s(o.as("d")),u=$s(o.as("M")),d=$s(o.as("w")),h=$s(o.as("y")),p=i<=n.ss&&["s",i]||i<n.s&&["ss",i]||a<=1&&["m"]||a<n.m&&["mm",a]||s<=1&&["h"]||s<n.h&&["hh",s]||l<=1&&["d"]||l<n.d&&["dd",l];return n.w!=null&&(p=p||d<=1&&["w"]||d<n.w&&["ww",d]),p=p||u<=1&&["M"]||u<n.M&&["MM",u]||h<=1&&["y"]||["yy",h],p[2]=t,p[3]=+e>0,p[4]=r,hbe.apply(null,p)}function mbe(e){return e===void 0?$s:typeof e=="function"?($s=e,!0):!1}function gbe(e,t){return ad[e]===void 0?!1:t===void 0?ad[e]:(ad[e]=t,e==="s"&&(ad.ss=t-1),!0)}function vbe(e,t){if(!this.isValid())return this.localeData().invalidDate();var n=!1,r=ad,o,i;return typeof e=="object"&&(t=e,e=!1),typeof e=="boolean"&&(n=e),typeof t=="object"&&(r=Object.assign({},ad,t),t.s!=null&&t.ss==null&&(r.ss=t.s-1)),o=this.localeData(),i=pbe(this,!n,r,o),n&&(i=o.pastFuture(+this,i)),o.postformat(i)}var O9=Math.abs;function Nf(e){return(e>0)-(e<0)||+e}function Ty(){if(!this.isValid())return this.localeData().invalidDate();var e=O9(this._milliseconds)/1e3,t=O9(this._days),n=O9(this._months),r,o,i,a,s=this.asSeconds(),l,u,d,h;return s?(r=ji(e/60),o=ji(r/60),e%=60,r%=60,i=ji(n/12),n%=12,a=e?e.toFixed(3).replace(/\.?0+$/,""):"",l=s<0?"-":"",u=Nf(this._months)!==Nf(s)?"-":"",d=Nf(this._days)!==Nf(s)?"-":"",h=Nf(this._milliseconds)!==Nf(s)?"-":"",l+"P"+(i?u+i+"Y":"")+(n?u+n+"M":"")+(t?d+t+"D":"")+(o||r||e?"T":"")+(o?h+o+"H":"")+(r?h+r+"M":"")+(e?h+a+"S":"")):"P0D"}var jt=Ey.prototype;jt.isValid=uge;jt.abs=Uve;jt.add=qve;jt.subtract=$ve;jt.as=Gve;jt.asMilliseconds=Vve;jt.asSeconds=Yve;jt.asMinutes=Qve;jt.asHours=Xve;jt.asDays=Zve;jt.asWeeks=Jve;jt.asMonths=ebe;jt.asQuarters=tbe;jt.asYears=nbe;jt.valueOf=Kve;jt._bubble=Wve;jt.clone=rbe;jt.get=obe;jt.milliseconds=ibe;jt.seconds=abe;jt.minutes=sbe;jt.hours=lbe;jt.days=ube;jt.weeks=dbe;jt.months=cbe;jt.years=fbe;jt.humanize=vbe;jt.toISOString=Ty;jt.toString=Ty;jt.toJSON=Ty;jt.locale=$P;jt.localeData=GP;jt.toIsoString=ta("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Ty);jt.lang=WP;Ke("X",0,0,"unix");Ke("x",0,0,"valueOf");Me("x",gy);Me("X",jpe);cn("X",function(e,t,n){n._d=new Date(parseFloat(e)*1e3)});cn("x",function(e,t,n){n._d=new Date(Nt(e))});//! moment.js De.version="2.29.4";bpe(Nn);De.fn=xe;De.min=ige;De.max=age;De.now=sge;De.utc=gs;De.unix=Dve;De.months=Mve;De.isDate=dp;De.locale=Tu;De.invalid=fy;De.duration=Ca;De.isMoment=xa;De.weekdays=jve;De.parseZone=Pve;De.localeData=El;De.isDuration=Gg;De.monthsShort=Lve;De.weekdaysMin=Hve;De.defineLocale=Ew;De.updateLocale=Pme;De.locales=Mme;De.weekdaysShort=zve;De.normalizeUnits=na;De.relativeTimeRounding=mbe;De.relativeTimeThreshold=gbe;De.calendarFormat=Bge;De.prototype=xe;De.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"};const bbe=()=>T.useContext(eo),ybe=e=>{try{return JSON.parse(e)}catch(t){console.error(t)}return{}};var Ebe=T.createContext(void 0),_be=Ebe.Provider;const rM="data-fui-focus-visible";function Tbe(e,t){if(oM(e))return()=>{};const n={current:void 0},r=Yb(t);r.subscribe(a=>{!a&&n.current&&(D9(n.current),n.current=void 0)});const o=a=>{n.current&&(D9(n.current),n.current=void 0),r.isNavigatingWithKeyboard()&&x7(a.target)&&a.target&&(n.current=a.target,wbe(n.current))},i=a=>{(!a.relatedTarget||x7(a.relatedTarget)&&!e.contains(a.relatedTarget))&&n.current&&(D9(n.current),n.current=void 0)};return e.addEventListener(wa,o),e.addEventListener("focusout",i),e.focusVisible=!0,()=>{e.removeEventListener(wa,o),e.removeEventListener("focusout",i),delete e.focusVisible,Qb(r)}}function wbe(e){e.setAttribute(rM,"")}function D9(e){e.removeAttribute(rM)}function x7(e){return e?!!(e&&typeof e=="object"&&"classList"in e&&"contains"in e):!1}function oM(e){return e?e.focusVisible?!0:oM(e==null?void 0:e.parentElement):!1}var kbe=new RegExp("("+LT.root+"\\d+)"),iM=function(e){var t=e.children,n=XR(),r=T.useMemo(function(){var i;return(i=n.match(kbe))===null||i===void 0?void 0:i[1]},[n]),o=T.useCallback(function(i){var a=function(){};return r&&(i.classList.add(r),i.ownerDocument.defaultView&&(a=Tbe(i,i.ownerDocument.defaultView))),function(){r&&i.classList.remove(r),a()}},[r]);return T.createElement(_be,{value:o},t)};const C7=["http","https","mailto","tel"];function Sbe(e){const t=(e||"").trim(),n=t.charAt(0);if(n==="#"||n==="/")return t;const r=t.indexOf(":");if(r===-1)return t;let o=-1;for(;++o<C7.length;){const i=C7[o];if(r===i.length&&t.slice(0,i.length).toLowerCase()===i)return t}return o=t.indexOf("?"),o!==-1&&r>o||(o=t.indexOf("#"),o!==-1&&r>o)?t:"javascript:void(0)"}/*! * Determine if an object is a Buffer * * @author Feross Aboukhadijeh <https://feross.org> * @license MIT */var xbe=function(t){return t!=null&&t.constructor!=null&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)};const Cbe=xr(xbe);var Ff={}.hasOwnProperty;function Abe(e){return!e||typeof e!="object"?"":Ff.call(e,"position")||Ff.call(e,"type")?A7(e.position):Ff.call(e,"start")||Ff.call(e,"end")?A7(e):Ff.call(e,"line")||Ff.call(e,"column")?Z_(e):""}function Z_(e){return N7(e&&e.line)+":"+N7(e&&e.column)}function A7(e){return Z_(e&&e.start)+"-"+Z_(e&&e.end)}function N7(e){return e&&typeof e=="number"?e:1}class ra extends Error{constructor(t,n,r){var o=[null,null],i={start:{line:null,column:null},end:{line:null,column:null}},a;super(),typeof n=="string"&&(r=n,n=null),typeof r=="string"&&(a=r.indexOf(":"),a===-1?o[1]=r:(o[0]=r.slice(0,a),o[1]=r.slice(a+1))),n&&("type"in n||"position"in n?n.position&&(i=n.position):"start"in n||"end"in n?i=n:("line"in n||"column"in n)&&(i.start=n)),this.name=Abe(n)||"1:1",this.message=typeof t=="object"?t.message:t,this.stack=typeof t=="object"?t.stack:"",this.reason=this.message,this.line=i.start.line,this.column=i.start.column,this.source=o[0],this.ruleId=o[1],this.position=i,this.file,this.fatal,this.url,this.note}}ra.prototype.file="";ra.prototype.name="";ra.prototype.reason="";ra.prototype.message="";ra.prototype.stack="";ra.prototype.fatal=null;ra.prototype.column=null;ra.prototype.line=null;ra.prototype.source=null;ra.prototype.ruleId=null;ra.prototype.position=null;const Ha={basename:Nbe,dirname:Fbe,extname:Ibe,join:Bbe,sep:"/"};function Nbe(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');gp(e);let n=0,r=-1,o=e.length,i;if(t===void 0||t.length===0||t.length>e.length){for(;o--;)if(e.charCodeAt(o)===47){if(i){n=o+1;break}}else r<0&&(i=!0,r=o+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let a=-1,s=t.length-1;for(;o--;)if(e.charCodeAt(o)===47){if(i){n=o+1;break}}else a<0&&(i=!0,a=o+1),s>-1&&(e.charCodeAt(o)===t.charCodeAt(s--)?s<0&&(r=o):(s=-1,r=a));return n===r?r=a:r<0&&(r=e.length),e.slice(n,r)}function Fbe(e){if(gp(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.charCodeAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.charCodeAt(0)===47?"/":".":t===1&&e.charCodeAt(0)===47?"//":e.slice(0,t)}function Ibe(e){gp(e);let t=e.length,n=-1,r=0,o=-1,i=0,a;for(;t--;){const s=e.charCodeAt(t);if(s===47){if(a){r=t+1;break}continue}n<0&&(a=!0,n=t+1),s===46?o<0?o=t:i!==1&&(i=1):o>-1&&(i=-1)}return o<0||n<0||i===0||i===1&&o===n-1&&o===r+1?"":e.slice(o,n)}function Bbe(...e){let t=-1,n;for(;++t<e.length;)gp(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":Rbe(n)}function Rbe(e){gp(e);const t=e.charCodeAt(0)===47;let n=Obe(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.charCodeAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function Obe(e,t){let n="",r=0,o=-1,i=0,a=-1,s,l;for(;++a<=e.length;){if(a<e.length)s=e.charCodeAt(a);else{if(s===47)break;s=47}if(s===47){if(!(o===a-1||i===1))if(o!==a-1&&i===2){if(n.length<2||r!==2||n.charCodeAt(n.length-1)!==46||n.charCodeAt(n.length-2)!==46){if(n.length>2){if(l=n.lastIndexOf("/"),l!==n.length-1){l<0?(n="",r=0):(n=n.slice(0,l),r=n.length-1-n.lastIndexOf("/")),o=a,i=0;continue}}else if(n.length>0){n="",r=0,o=a,i=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(o+1,a):n=e.slice(o+1,a),r=a-o-1;o=a,i=0}else s===46&&i>-1?i++:i=-1}return n}function gp(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Dbe={cwd:Pbe};function Pbe(){return"/"}function J_(e){return e!==null&&typeof e=="object"&&e.href&&e.origin}function Mbe(e){if(typeof e=="string")e=new URL(e);else if(!J_(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return Lbe(e)}function Lbe(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.charCodeAt(n)===37&&t.charCodeAt(n+1)===50){const r=t.charCodeAt(n+2);if(r===70||r===102){const o=new TypeError("File URL path must not include encoded / characters");throw o.code="ERR_INVALID_FILE_URL_PATH",o}}return decodeURIComponent(t)}const P9=["history","path","basename","stem","extname","dirname"];class aM{constructor(t){let n;t?typeof t=="string"||Cbe(t)?n={value:t}:J_(t)?n={path:t}:n=t:n={},this.data={},this.messages=[],this.history=[],this.cwd=Dbe.cwd(),this.value,this.stored,this.result,this.map;let r=-1;for(;++r<P9.length;){const i=P9[r];i in n&&n[i]!==void 0&&(this[i]=i==="history"?[...n[i]]:n[i])}let o;for(o in n)P9.includes(o)||(this[o]=n[o])}get path(){return this.history[this.history.length-1]}set path(t){J_(t)&&(t=Mbe(t)),L9(t,"path"),this.path!==t&&this.history.push(t)}get dirname(){return typeof this.path=="string"?Ha.dirname(this.path):void 0}set dirname(t){F7(this.basename,"dirname"),this.path=Ha.join(t||"",this.basename)}get basename(){return typeof this.path=="string"?Ha.basename(this.path):void 0}set basename(t){L9(t,"basename"),M9(t,"basename"),this.path=Ha.join(this.dirname||"",t)}get extname(){return typeof this.path=="string"?Ha.extname(this.path):void 0}set extname(t){if(M9(t,"extname"),F7(this.dirname,"extname"),t){if(t.charCodeAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Ha.join(this.dirname,this.stem+(t||""))}get stem(){return typeof this.path=="string"?Ha.basename(this.path,this.extname):void 0}set stem(t){L9(t,"stem"),M9(t,"stem"),this.path=Ha.join(this.dirname||"",t+(this.extname||""))}toString(t){return(this.value||"").toString(t)}message(t,n,r){const o=new ra(t,n,r);return this.path&&(o.name=this.path+":"+o.name,o.file=this.path),o.fatal=!1,this.messages.push(o),o}info(t,n,r){const o=this.message(t,n,r);return o.fatal=null,o}fail(t,n,r){const o=this.message(t,n,r);throw o.fatal=!0,o}}function M9(e,t){if(e&&e.includes(Ha.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Ha.sep+"`")}function L9(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function F7(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function I7(e){if(e)throw e}/*! * Determine if an object is a Buffer * * @author Feross Aboukhadijeh <https://feross.org> * @license MIT */var jbe=function(t){return t!=null&&t.constructor!=null&&typeof t.constructor.isBuffer=="function"&&t.constructor.isBuffer(t)};const zbe=xr(jbe);var Vg=Object.prototype.hasOwnProperty,sM=Object.prototype.toString,B7=Object.defineProperty,R7=Object.getOwnPropertyDescriptor,O7=function(t){return typeof Array.isArray=="function"?Array.isArray(t):sM.call(t)==="[object Array]"},D7=function(t){if(!t||sM.call(t)!=="[object Object]")return!1;var n=Vg.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&Vg.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var o;for(o in t);return typeof o>"u"||Vg.call(t,o)},P7=function(t,n){B7&&n.name==="__proto__"?B7(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},M7=function(t,n){if(n==="__proto__")if(Vg.call(t,n)){if(R7)return R7(t,n).value}else return;return t[n]},Hbe=function e(){var t,n,r,o,i,a,s=arguments[0],l=1,u=arguments.length,d=!1;for(typeof s=="boolean"&&(d=s,s=arguments[1]||{},l=2),(s==null||typeof s!="object"&&typeof s!="function")&&(s={});l<u;++l)if(t=arguments[l],t!=null)for(n in t)r=M7(s,n),o=M7(t,n),s!==o&&(d&&o&&(D7(o)||(i=O7(o)))?(i?(i=!1,a=r&&O7(r)?r:[]):a=r&&D7(r)?r:{},P7(s,{name:n,newValue:e(d,a,o)})):typeof o<"u"&&P7(s,{name:n,newValue:o}));return s};const L7=xr(Hbe);function e4(e){if(Object.prototype.toString.call(e)!=="[object Object]")return!1;const t=Object.getPrototypeOf(e);return t===null||t===Object.prototype}function Ube(){const e=[],t={run:n,use:r};return t;function n(...o){let i=-1;const a=o.pop();if(typeof a!="function")throw new TypeError("Expected function as last argument, not "+a);s(null,...o);function s(l,...u){const d=e[++i];let h=-1;if(l){a(l);return}for(;++h<o.length;)(u[h]===null||u[h]===void 0)&&(u[h]=o[h]);o=u,d?qbe(d,s)(...u):a(null,...u)}}function r(o){if(typeof o!="function")throw new TypeError("Expected `middelware` to be a function, not "+o);return e.push(o),t}}function qbe(e,t){let n;return r;function r(...a){const s=e.length>a.length;let l;s&&a.push(o);try{l=e(...a)}catch(u){const d=u;if(s&&n)throw d;return o(d)}s||(l instanceof Promise?l.then(i,o):l instanceof Error?o(l):i(l))}function o(a,...s){n||(n=!0,t(a,...s))}function i(a){o(null,a)}}const $be=uM().freeze(),lM={}.hasOwnProperty;function uM(){const e=Ube(),t=[];let n={},r,o=-1;return i.data=a,i.Parser=void 0,i.Compiler=void 0,i.freeze=s,i.attachers=t,i.use=l,i.parse=u,i.stringify=d,i.run=h,i.runSync=p,i.process=m,i.processSync=v,i;function i(){const _=uM();let b=-1;for(;++b<t.length;)_.use(...t[b]);return _.data(L7(!0,{},n)),_}function a(_,b){return typeof _=="string"?arguments.length===2?(H9("data",r),n[_]=b,i):lM.call(n,_)&&n[_]||null:_?(H9("data",r),n=_,i):n}function s(){if(r)return i;for(;++o<t.length;){const[_,...b]=t[o];if(b[0]===!1)continue;b[0]===!0&&(b[1]=void 0);const E=_.call(i,...b);typeof E=="function"&&e.use(E)}return r=!0,o=Number.POSITIVE_INFINITY,i}function l(_,...b){let E;if(H9("use",r),_!=null)if(typeof _=="function")F(_,...b);else if(typeof _=="object")Array.isArray(_)?y(_):k(_);else throw new TypeError("Expected usable value, not `"+_+"`");return E&&(n.settings=Object.assign(n.settings||{},E)),i;function w(C){if(typeof C=="function")F(C);else if(typeof C=="object")if(Array.isArray(C)){const[A,...P]=C;F(A,...P)}else k(C);else throw new TypeError("Expected usable value, not `"+C+"`")}function k(C){y(C.plugins),C.settings&&(E=Object.assign(E||{},C.settings))}function y(C){let A=-1;if(C!=null)if(Array.isArray(C))for(;++A<C.length;){const P=C[A];w(P)}else throw new TypeError("Expected a list of plugins, not `"+C+"`")}function F(C,A){let P=-1,I;for(;++P<t.length;)if(t[P][0]===C){I=t[P];break}I?(e4(I[1])&&e4(A)&&(A=L7(!0,I[1],A)),I[1]=A):t.push([...arguments])}}function u(_){i.freeze();const b=uh(_),E=i.Parser;return j9("parse",E),j7(E,"parse")?new E(String(b),b).parse():E(String(b),b)}function d(_,b){i.freeze();const E=uh(b),w=i.Compiler;return z9("stringify",w),z7(_),j7(w,"compile")?new w(_,E).compile():w(_,E)}function h(_,b,E){if(z7(_),i.freeze(),!E&&typeof b=="function"&&(E=b,b=void 0),!E)return new Promise(w);w(null,E);function w(k,y){e.run(_,uh(b),F);function F(C,A,P){A=A||_,C?y(C):k?k(A):E(null,A,P)}}}function p(_,b){let E,w;return i.run(_,b,k),H7("runSync","run",w),E;function k(y,F){I7(y),E=F,w=!0}}function m(_,b){if(i.freeze(),j9("process",i.Parser),z9("process",i.Compiler),!b)return new Promise(E);E(null,b);function E(w,k){const y=uh(_);i.run(i.parse(y),y,(C,A,P)=>{if(C||!A||!P)F(C);else{const I=i.stringify(A,P);I==null||(Kbe(I)?P.value=I:P.result=I),F(C,P)}});function F(C,A){C||!A?k(C):w?w(A):b(null,A)}}}function v(_){let b;i.freeze(),j9("processSync",i.Parser),z9("processSync",i.Compiler);const E=uh(_);return i.process(E,w),H7("processSync","process",b),E;function w(k){b=!0,I7(k)}}}function j7(e,t){return typeof e=="function"&&e.prototype&&(Wbe(e.prototype)||t in e.prototype)}function Wbe(e){let t;for(t in e)if(lM.call(e,t))return!0;return!1}function j9(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Parser`")}function z9(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `Compiler`")}function H9(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function z7(e){if(!e4(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function H7(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function uh(e){return Gbe(e)?e:new aM(e)}function Gbe(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Kbe(e){return typeof e=="string"||zbe(e)}function Vbe(e,t){var{includeImageAlt:n=!0}=t||{};return cM(e,n)}function cM(e,t){return e&&typeof e=="object"&&(e.value||(t?e.alt:"")||"children"in e&&U7(e.children,t)||Array.isArray(e)&&U7(e,t))||""}function U7(e,t){for(var n=[],r=-1;++r<e.length;)n[r]=cM(e[r],t);return n.join("")}function ds(e,t,n,r){const o=e.length;let i=0,a;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<1e4)a=Array.from(r),a.unshift(t,n),[].splice.apply(e,a);else for(n&&[].splice.apply(e,[t,n]);i<r.length;)a=r.slice(i,i+1e4),a.unshift(t,0),[].splice.apply(e,a),i+=1e4,t+=1e4}function zi(e,t){return e.length>0?(ds(e,e.length,0,t),e):t}const q7={}.hasOwnProperty;function Ybe(e){const t={};let n=-1;for(;++n<e.length;)Qbe(t,e[n]);return t}function Qbe(e,t){let n;for(n in t){const o=(q7.call(e,n)?e[n]:void 0)||(e[n]={}),i=t[n];let a;for(a in i){q7.call(o,a)||(o[a]=[]);const s=i[a];Xbe(o[a],Array.isArray(s)?s:s?[s]:[])}}}function Xbe(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);ds(e,0,0,r)}const Zbe=/[!-/:-@[-`{-~\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,Va=Pu(/[A-Za-z]/),t4=Pu(/\d/),Jbe=Pu(/[\dA-Fa-f]/),Ta=Pu(/[\dA-Za-z]/),eye=Pu(/[!-/:-@[-`{-~]/),$7=Pu(/[#-'*+\--9=?A-Z^-~]/);function n4(e){return e!==null&&(e<32||e===127)}function Ki(e){return e!==null&&(e<0||e===32)}function ct(e){return e!==null&&e<-2}function mr(e){return e===-2||e===-1||e===32}const tye=Pu(/\s/),nye=Pu(Zbe);function Pu(e){return t;function t(n){return n!==null&&e.test(String.fromCharCode(n))}}function dn(e,t,n,r){const o=r?r-1:Number.POSITIVE_INFINITY;let i=0;return a;function a(l){return mr(l)?(e.enter(n),s(l)):t(l)}function s(l){return mr(l)&&i++<o?(e.consume(l),s):(e.exit(n),t(l))}}const rye={tokenize:oye};function oye(e){const t=e.attempt(this.parser.constructs.contentInitial,r,o);let n;return t;function r(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),dn(e,t,"linePrefix")}function o(s){return e.enter("paragraph"),i(s)}function i(s){const l=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=l),n=l,a(s)}function a(s){if(s===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(s);return}return ct(s)?(e.consume(s),e.exit("chunkText"),i):(e.consume(s),a)}}const iye={tokenize:aye},W7={tokenize:sye};function aye(e){const t=this,n=[];let r=0,o,i,a;return s;function s(k){if(r<n.length){const y=n[r];return t.containerState=y[1],e.attempt(y[0].continuation,l,u)(k)}return u(k)}function l(k){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,o&&w();const y=t.events.length;let F=y,C;for(;F--;)if(t.events[F][0]==="exit"&&t.events[F][1].type==="chunkFlow"){C=t.events[F][1].end;break}E(r);let A=y;for(;A<t.events.length;)t.events[A][1].end=Object.assign({},C),A++;return ds(t.events,F+1,0,t.events.slice(y)),t.events.length=A,u(k)}return s(k)}function u(k){if(r===n.length){if(!o)return p(k);if(o.currentConstruct&&o.currentConstruct.concrete)return v(k);t.interrupt=!!(o.currentConstruct&&!o._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(W7,d,h)(k)}function d(k){return o&&w(),E(r),p(k)}function h(k){return t.parser.lazy[t.now().line]=r!==n.length,a=t.now().offset,v(k)}function p(k){return t.containerState={},e.attempt(W7,m,v)(k)}function m(k){return r++,n.push([t.currentConstruct,t.containerState]),p(k)}function v(k){if(k===null){o&&w(),E(0),e.consume(k);return}return o=o||t.parser.flow(t.now()),e.enter("chunkFlow",{contentType:"flow",previous:i,_tokenizer:o}),_(k)}function _(k){if(k===null){b(e.exit("chunkFlow"),!0),E(0),e.consume(k);return}return ct(k)?(e.consume(k),b(e.exit("chunkFlow")),r=0,t.interrupt=void 0,s):(e.consume(k),_)}function b(k,y){const F=t.sliceStream(k);if(y&&F.push(null),k.previous=i,i&&(i.next=k),i=k,o.defineSkip(k.start),o.write(F),t.parser.lazy[k.start.line]){let C=o.events.length;for(;C--;)if(o.events[C][1].start.offset<a&&(!o.events[C][1].end||o.events[C][1].end.offset>a))return;const A=t.events.length;let P=A,I,j;for(;P--;)if(t.events[P][0]==="exit"&&t.events[P][1].type==="chunkFlow"){if(I){j=t.events[P][1].end;break}I=!0}for(E(r),C=A;C<t.events.length;)t.events[C][1].end=Object.assign({},j),C++;ds(t.events,P+1,0,t.events.slice(A)),t.events.length=C}}function E(k){let y=n.length;for(;y-- >k;){const F=n[y];t.containerState=F[1],F[0].exit.call(t,e)}n.length=k}function w(){o.write([null]),i=void 0,o=void 0,t.containerState._closeFlow=void 0}}function sye(e,t,n){return dn(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function G7(e){if(e===null||Ki(e)||tye(e))return 1;if(nye(e))return 2}function Nw(e,t,n){const r=[];let o=-1;for(;++o<e.length;){const i=e[o].resolveAll;i&&!r.includes(i)&&(t=i(t,n),r.push(i))}return t}const r4={name:"attention",tokenize:uye,resolveAll:lye};function lye(e,t){let n=-1,r,o,i,a,s,l,u,d;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;l=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const h=Object.assign({},e[r][1].end),p=Object.assign({},e[n][1].start);K7(h,-l),K7(p,l),a={type:l>1?"strongSequence":"emphasisSequence",start:h,end:Object.assign({},e[r][1].end)},s={type:l>1?"strongSequence":"emphasisSequence",start:Object.assign({},e[n][1].start),end:p},i={type:l>1?"strongText":"emphasisText",start:Object.assign({},e[r][1].end),end:Object.assign({},e[n][1].start)},o={type:l>1?"strong":"emphasis",start:Object.assign({},a.start),end:Object.assign({},s.end)},e[r][1].end=Object.assign({},a.start),e[n][1].start=Object.assign({},s.end),u=[],e[r][1].end.offset-e[r][1].start.offset&&(u=zi(u,[["enter",e[r][1],t],["exit",e[r][1],t]])),u=zi(u,[["enter",o,t],["enter",a,t],["exit",a,t],["enter",i,t]]),u=zi(u,Nw(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),u=zi(u,[["exit",i,t],["enter",s,t],["exit",s,t],["exit",o,t]]),e[n][1].end.offset-e[n][1].start.offset?(d=2,u=zi(u,[["enter",e[n][1],t],["exit",e[n][1],t]])):d=0,ds(e,r-1,n-r+3,u),n=r+u.length-d-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function uye(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,o=G7(r);let i;return a;function a(l){return e.enter("attentionSequence"),i=l,s(l)}function s(l){if(l===i)return e.consume(l),s;const u=e.exit("attentionSequence"),d=G7(l),h=!d||d===2&&o||n.includes(l),p=!o||o===2&&d||n.includes(r);return u._open=!!(i===42?h:h&&(o||!p)),u._close=!!(i===42?p:p&&(d||!h)),t(l)}}function K7(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const cye={name:"autolink",tokenize:fye};function fye(e,t,n){let r=1;return o;function o(v){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(v),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),i}function i(v){return Va(v)?(e.consume(v),a):$7(v)?u(v):n(v)}function a(v){return v===43||v===45||v===46||Ta(v)?s(v):u(v)}function s(v){return v===58?(e.consume(v),l):(v===43||v===45||v===46||Ta(v))&&r++<32?(e.consume(v),s):u(v)}function l(v){return v===62?(e.exit("autolinkProtocol"),m(v)):v===null||v===32||v===60||n4(v)?n(v):(e.consume(v),l)}function u(v){return v===64?(e.consume(v),r=0,d):$7(v)?(e.consume(v),u):n(v)}function d(v){return Ta(v)?h(v):n(v)}function h(v){return v===46?(e.consume(v),r=0,d):v===62?(e.exit("autolinkProtocol").type="autolinkEmail",m(v)):p(v)}function p(v){return(v===45||Ta(v))&&r++<63?(e.consume(v),v===45?p:h):n(v)}function m(v){return e.enter("autolinkMarker"),e.consume(v),e.exit("autolinkMarker"),e.exit("autolink"),t}}const wy={tokenize:dye,partial:!0};function dye(e,t,n){return dn(e,r,"linePrefix");function r(o){return o===null||ct(o)?t(o):n(o)}}const fM={name:"blockQuote",tokenize:hye,continuation:{tokenize:pye},exit:mye};function hye(e,t,n){const r=this;return o;function o(a){if(a===62){const s=r.containerState;return s.open||(e.enter("blockQuote",{_container:!0}),s.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(a),e.exit("blockQuoteMarker"),i}return n(a)}function i(a){return mr(a)?(e.enter("blockQuotePrefixWhitespace"),e.consume(a),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(a))}}function pye(e,t,n){return dn(e,e.attempt(fM,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function mye(e){e.exit("blockQuote")}const dM={name:"characterEscape",tokenize:gye};function gye(e,t,n){return r;function r(i){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(i),e.exit("escapeMarker"),o}function o(i){return eye(i)?(e.enter("characterEscapeValue"),e.consume(i),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(i)}}const V7=document.createElement("i");function L0(e){const t="&"+e+";";V7.innerHTML=t;const n=V7.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}const hM={name:"characterReference",tokenize:vye};function vye(e,t,n){const r=this;let o=0,i,a;return s;function s(h){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(h),e.exit("characterReferenceMarker"),l}function l(h){return h===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(h),e.exit("characterReferenceMarkerNumeric"),u):(e.enter("characterReferenceValue"),i=31,a=Ta,d(h))}function u(h){return h===88||h===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(h),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),i=6,a=Jbe,d):(e.enter("characterReferenceValue"),i=7,a=t4,d(h))}function d(h){let p;return h===59&&o?(p=e.exit("characterReferenceValue"),a===Ta&&!L0(r.sliceSerialize(p))?n(h):(e.enter("characterReferenceMarker"),e.consume(h),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)):a(h)&&o++<i?(e.consume(h),d):n(h)}}const Y7={name:"codeFenced",tokenize:bye,concrete:!0};function bye(e,t,n){const r=this,o={tokenize:F,partial:!0},i={tokenize:y,partial:!0},a=this.events[this.events.length-1],s=a&&a[1].type==="linePrefix"?a[2].sliceSerialize(a[1],!0).length:0;let l=0,u;return d;function d(C){return e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),u=C,h(C)}function h(C){return C===u?(e.consume(C),l++,h):(e.exit("codeFencedFenceSequence"),l<3?n(C):dn(e,p,"whitespace")(C))}function p(C){return C===null||ct(C)?b(C):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),m(C))}function m(C){return C===null||Ki(C)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),dn(e,v,"whitespace")(C)):C===96&&C===u?n(C):(e.consume(C),m)}function v(C){return C===null||ct(C)?b(C):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),_(C))}function _(C){return C===null||ct(C)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),b(C)):C===96&&C===u?n(C):(e.consume(C),_)}function b(C){return e.exit("codeFencedFence"),r.interrupt?t(C):E(C)}function E(C){return C===null?k(C):ct(C)?e.attempt(i,e.attempt(o,k,s?dn(e,E,"linePrefix",s+1):E),k)(C):(e.enter("codeFlowValue"),w(C))}function w(C){return C===null||ct(C)?(e.exit("codeFlowValue"),E(C)):(e.consume(C),w)}function k(C){return e.exit("codeFenced"),t(C)}function y(C,A,P){const I=this;return j;function j(K){return C.enter("lineEnding"),C.consume(K),C.exit("lineEnding"),H}function H(K){return I.parser.lazy[I.now().line]?P(K):A(K)}}function F(C,A,P){let I=0;return dn(C,j,"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4);function j(U){return C.enter("codeFencedFence"),C.enter("codeFencedFenceSequence"),H(U)}function H(U){return U===u?(C.consume(U),I++,H):I<l?P(U):(C.exit("codeFencedFenceSequence"),dn(C,K,"whitespace")(U))}function K(U){return U===null||ct(U)?(C.exit("codeFencedFence"),A(U)):P(U)}}}const U9={name:"codeIndented",tokenize:Eye},yye={tokenize:_ye,partial:!0};function Eye(e,t,n){const r=this;return o;function o(u){return e.enter("codeIndented"),dn(e,i,"linePrefix",4+1)(u)}function i(u){const d=r.events[r.events.length-1];return d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?a(u):n(u)}function a(u){return u===null?l(u):ct(u)?e.attempt(yye,a,l)(u):(e.enter("codeFlowValue"),s(u))}function s(u){return u===null||ct(u)?(e.exit("codeFlowValue"),a(u)):(e.consume(u),s)}function l(u){return e.exit("codeIndented"),t(u)}}function _ye(e,t,n){const r=this;return o;function o(a){return r.parser.lazy[r.now().line]?n(a):ct(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),o):dn(e,i,"linePrefix",4+1)(a)}function i(a){const s=r.events[r.events.length-1];return s&&s[1].type==="linePrefix"&&s[2].sliceSerialize(s[1],!0).length>=4?t(a):ct(a)?o(a):n(a)}}const Tye={name:"codeText",tokenize:Sye,resolve:wye,previous:kye};function wye(e){let t=e.length-4,n=3,r,o;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)o===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(o=r):(r===t||e[r][1].type==="lineEnding")&&(e[o][1].type="codeTextData",r!==o+2&&(e[o][1].end=e[r-1][1].end,e.splice(o+2,r-o-2),t-=r-o-2,r=o+2),o=void 0);return e}function kye(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function Sye(e,t,n){let r=0,o,i;return a;function a(h){return e.enter("codeText"),e.enter("codeTextSequence"),s(h)}function s(h){return h===96?(e.consume(h),r++,s):(e.exit("codeTextSequence"),l(h))}function l(h){return h===null?n(h):h===96?(i=e.enter("codeTextSequence"),o=0,d(h)):h===32?(e.enter("space"),e.consume(h),e.exit("space"),l):ct(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),l):(e.enter("codeTextData"),u(h))}function u(h){return h===null||h===32||h===96||ct(h)?(e.exit("codeTextData"),l(h)):(e.consume(h),u)}function d(h){return h===96?(e.consume(h),o++,d):o===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(h)):(i.type="codeTextData",u(h))}}function pM(e){const t={};let n=-1,r,o,i,a,s,l,u;for(;++n<e.length;){for(;n in t;)n=t[n];if(r=e[n],n&&r[1].type==="chunkFlow"&&e[n-1][1].type==="listItemPrefix"&&(l=r[1]._tokenizer.events,i=0,i<l.length&&l[i][1].type==="lineEndingBlank"&&(i+=2),i<l.length&&l[i][1].type==="content"))for(;++i<l.length&&l[i][1].type!=="content";)l[i][1].type==="chunkText"&&(l[i][1]._isInFirstContentOfListItem=!0,i++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,xye(e,n)),n=t[n],u=!0);else if(r[1]._container){for(i=n,o=void 0;i--&&(a=e[i],a[1].type==="lineEnding"||a[1].type==="lineEndingBlank");)a[0]==="enter"&&(o&&(e[o][1].type="lineEndingBlank"),a[1].type="lineEnding",o=i);o&&(r[1].end=Object.assign({},e[o][1].start),s=e.slice(o,n),s.unshift(r),ds(e,o,n-o+1,s))}}return!u}function xye(e,t){const n=e[t][1],r=e[t][2];let o=t-1;const i=[],a=n._tokenizer||r.parser[n.contentType](n.start),s=a.events,l=[],u={};let d,h,p=-1,m=n,v=0,_=0;const b=[_];for(;m;){for(;e[++o][1]!==m;);i.push(o),m._tokenizer||(d=r.sliceStream(m),m.next||d.push(null),h&&a.defineSkip(m.start),m._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=!0),a.write(d),m._isInFirstContentOfListItem&&(a._gfmTasklistFirstContentOfListItem=void 0)),h=m,m=m.next}for(m=n;++p<s.length;)s[p][0]==="exit"&&s[p-1][0]==="enter"&&s[p][1].type===s[p-1][1].type&&s[p][1].start.line!==s[p][1].end.line&&(_=p+1,b.push(_),m._tokenizer=void 0,m.previous=void 0,m=m.next);for(a.events=[],m?(m._tokenizer=void 0,m.previous=void 0):b.pop(),p=b.length;p--;){const E=s.slice(b[p],b[p+1]),w=i.pop();l.unshift([w,w+E.length-1]),ds(e,w,2,E)}for(p=-1;++p<l.length;)u[v+l[p][0]]=v+l[p][1],v+=l[p][1]-l[p][0]-1;return u}const Cye={tokenize:Fye,resolve:Nye},Aye={tokenize:Iye,partial:!0};function Nye(e){return pM(e),e}function Fye(e,t){let n;return r;function r(s){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),o(s)}function o(s){return s===null?i(s):ct(s)?e.check(Aye,a,i)(s):(e.consume(s),o)}function i(s){return e.exit("chunkContent"),e.exit("content"),t(s)}function a(s){return e.consume(s),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,o}}function Iye(e,t,n){const r=this;return o;function o(a){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),dn(e,i,"linePrefix")}function i(a){if(a===null||ct(a))return n(a);const s=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&s&&s[1].type==="linePrefix"&&s[2].sliceSerialize(s[1],!0).length>=4?t(a):e.interrupt(r.parser.constructs.flow,n,t)(a)}}function mM(e,t,n,r,o,i,a,s,l){const u=l||Number.POSITIVE_INFINITY;let d=0;return h;function h(E){return E===60?(e.enter(r),e.enter(o),e.enter(i),e.consume(E),e.exit(i),p):E===null||E===41||n4(E)?n(E):(e.enter(r),e.enter(a),e.enter(s),e.enter("chunkString",{contentType:"string"}),_(E))}function p(E){return E===62?(e.enter(i),e.consume(E),e.exit(i),e.exit(o),e.exit(r),t):(e.enter(s),e.enter("chunkString",{contentType:"string"}),m(E))}function m(E){return E===62?(e.exit("chunkString"),e.exit(s),p(E)):E===null||E===60||ct(E)?n(E):(e.consume(E),E===92?v:m)}function v(E){return E===60||E===62||E===92?(e.consume(E),m):m(E)}function _(E){return E===40?++d>u?n(E):(e.consume(E),_):E===41?d--?(e.consume(E),_):(e.exit("chunkString"),e.exit(s),e.exit(a),e.exit(r),t(E)):E===null||Ki(E)?d?n(E):(e.exit("chunkString"),e.exit(s),e.exit(a),e.exit(r),t(E)):n4(E)?n(E):(e.consume(E),E===92?b:_)}function b(E){return E===40||E===41||E===92?(e.consume(E),_):_(E)}}function gM(e,t,n,r,o,i){const a=this;let s=0,l;return u;function u(m){return e.enter(r),e.enter(o),e.consume(m),e.exit(o),e.enter(i),d}function d(m){return m===null||m===91||m===93&&!l||m===94&&!s&&"_hiddenFootnoteSupport"in a.parser.constructs||s>999?n(m):m===93?(e.exit(i),e.enter(o),e.consume(m),e.exit(o),e.exit(r),t):ct(m)?(e.enter("lineEnding"),e.consume(m),e.exit("lineEnding"),d):(e.enter("chunkString",{contentType:"string"}),h(m))}function h(m){return m===null||m===91||m===93||ct(m)||s++>999?(e.exit("chunkString"),d(m)):(e.consume(m),l=l||!mr(m),m===92?p:h)}function p(m){return m===91||m===92||m===93?(e.consume(m),s++,h):h(m)}}function vM(e,t,n,r,o,i){let a;return s;function s(p){return e.enter(r),e.enter(o),e.consume(p),e.exit(o),a=p===40?41:p,l}function l(p){return p===a?(e.enter(o),e.consume(p),e.exit(o),e.exit(r),t):(e.enter(i),u(p))}function u(p){return p===a?(e.exit(i),l(a)):p===null?n(p):ct(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),dn(e,u,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===a||p===null||ct(p)?(e.exit("chunkString"),u(p)):(e.consume(p),p===92?h:d)}function h(p){return p===a||p===92?(e.consume(p),d):d(p)}}function Vh(e,t){let n;return r;function r(o){return ct(o)?(e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),n=!0,r):mr(o)?dn(e,r,n?"linePrefix":"lineSuffix")(o):t(o)}}function Bd(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const Bye={name:"definition",tokenize:Oye},Rye={tokenize:Dye,partial:!0};function Oye(e,t,n){const r=this;let o;return i;function i(l){return e.enter("definition"),gM.call(r,e,a,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(l)}function a(l){return o=Bd(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),l===58?(e.enter("definitionMarker"),e.consume(l),e.exit("definitionMarker"),Vh(e,mM(e,e.attempt(Rye,dn(e,s,"whitespace"),dn(e,s,"whitespace")),n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString"))):n(l)}function s(l){return l===null||ct(l)?(e.exit("definition"),r.parser.defined.includes(o)||r.parser.defined.push(o),t(l)):n(l)}}function Dye(e,t,n){return r;function r(a){return Ki(a)?Vh(e,o)(a):n(a)}function o(a){return a===34||a===39||a===40?vM(e,dn(e,i,"whitespace"),n,"definitionTitle","definitionTitleMarker","definitionTitleString")(a):n(a)}function i(a){return a===null||ct(a)?t(a):n(a)}}const Pye={name:"hardBreakEscape",tokenize:Mye};function Mye(e,t,n){return r;function r(i){return e.enter("hardBreakEscape"),e.enter("escapeMarker"),e.consume(i),o}function o(i){return ct(i)?(e.exit("escapeMarker"),e.exit("hardBreakEscape"),t(i)):n(i)}}const Lye={name:"headingAtx",tokenize:zye,resolve:jye};function jye(e,t){let n=e.length-2,r=3,o,i;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(o={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},i={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},ds(e,r,n-r+1,[["enter",o,t],["enter",i,t],["exit",i,t],["exit",o,t]])),e}function zye(e,t,n){const r=this;let o=0;return i;function i(d){return e.enter("atxHeading"),e.enter("atxHeadingSequence"),a(d)}function a(d){return d===35&&o++<6?(e.consume(d),a):d===null||Ki(d)?(e.exit("atxHeadingSequence"),r.interrupt?t(d):s(d)):n(d)}function s(d){return d===35?(e.enter("atxHeadingSequence"),l(d)):d===null||ct(d)?(e.exit("atxHeading"),t(d)):mr(d)?dn(e,s,"whitespace")(d):(e.enter("atxHeadingText"),u(d))}function l(d){return d===35?(e.consume(d),l):(e.exit("atxHeadingSequence"),s(d))}function u(d){return d===null||d===35||Ki(d)?(e.exit("atxHeadingText"),s(d)):(e.consume(d),u)}}const Hye=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","section","source","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],Q7=["pre","script","style","textarea"],Uye={name:"htmlFlow",tokenize:Wye,resolveTo:$ye,concrete:!0},qye={tokenize:Gye,partial:!0};function $ye(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function Wye(e,t,n){const r=this;let o,i,a,s,l;return u;function u(L){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(L),d}function d(L){return L===33?(e.consume(L),h):L===47?(e.consume(L),v):L===63?(e.consume(L),o=3,r.interrupt?t:ve):Va(L)?(e.consume(L),a=String.fromCharCode(L),i=!0,_):n(L)}function h(L){return L===45?(e.consume(L),o=2,p):L===91?(e.consume(L),o=5,a="CDATA[",s=0,m):Va(L)?(e.consume(L),o=4,r.interrupt?t:ve):n(L)}function p(L){return L===45?(e.consume(L),r.interrupt?t:ve):n(L)}function m(L){return L===a.charCodeAt(s++)?(e.consume(L),s===a.length?r.interrupt?t:H:m):n(L)}function v(L){return Va(L)?(e.consume(L),a=String.fromCharCode(L),_):n(L)}function _(L){return L===null||L===47||L===62||Ki(L)?L!==47&&i&&Q7.includes(a.toLowerCase())?(o=1,r.interrupt?t(L):H(L)):Hye.includes(a.toLowerCase())?(o=6,L===47?(e.consume(L),b):r.interrupt?t(L):H(L)):(o=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(L):i?w(L):E(L)):L===45||Ta(L)?(e.consume(L),a+=String.fromCharCode(L),_):n(L)}function b(L){return L===62?(e.consume(L),r.interrupt?t:H):n(L)}function E(L){return mr(L)?(e.consume(L),E):I(L)}function w(L){return L===47?(e.consume(L),I):L===58||L===95||Va(L)?(e.consume(L),k):mr(L)?(e.consume(L),w):I(L)}function k(L){return L===45||L===46||L===58||L===95||Ta(L)?(e.consume(L),k):y(L)}function y(L){return L===61?(e.consume(L),F):mr(L)?(e.consume(L),y):w(L)}function F(L){return L===null||L===60||L===61||L===62||L===96?n(L):L===34||L===39?(e.consume(L),l=L,C):mr(L)?(e.consume(L),F):(l=null,A(L))}function C(L){return L===null||ct(L)?n(L):L===l?(e.consume(L),P):(e.consume(L),C)}function A(L){return L===null||L===34||L===39||L===60||L===61||L===62||L===96||Ki(L)?y(L):(e.consume(L),A)}function P(L){return L===47||L===62||mr(L)?w(L):n(L)}function I(L){return L===62?(e.consume(L),j):n(L)}function j(L){return mr(L)?(e.consume(L),j):L===null||ct(L)?H(L):n(L)}function H(L){return L===45&&o===2?(e.consume(L),se):L===60&&o===1?(e.consume(L),J):L===62&&o===4?(e.consume(L),fe):L===63&&o===3?(e.consume(L),ve):L===93&&o===5?(e.consume(L),_e):ct(L)&&(o===6||o===7)?e.check(qye,fe,K)(L):L===null||ct(L)?K(L):(e.consume(L),H)}function K(L){return e.exit("htmlFlowData"),U(L)}function U(L){return L===null?R(L):ct(L)?e.attempt({tokenize:pe,partial:!0},U,R)(L):(e.enter("htmlFlowData"),H(L))}function pe(L,Ae,Ue){return Ve;function Ve(st){return L.enter("lineEnding"),L.consume(st),L.exit("lineEnding"),Le}function Le(st){return r.parser.lazy[r.now().line]?Ue(st):Ae(st)}}function se(L){return L===45?(e.consume(L),ve):H(L)}function J(L){return L===47?(e.consume(L),a="",$):H(L)}function $(L){return L===62&&Q7.includes(a.toLowerCase())?(e.consume(L),fe):Va(L)&&a.length<8?(e.consume(L),a+=String.fromCharCode(L),$):H(L)}function _e(L){return L===93?(e.consume(L),ve):H(L)}function ve(L){return L===62?(e.consume(L),fe):L===45&&o===2?(e.consume(L),ve):H(L)}function fe(L){return L===null||ct(L)?(e.exit("htmlFlowData"),R(L)):(e.consume(L),fe)}function R(L){return e.exit("htmlFlow"),t(L)}}function Gye(e,t,n){return r;function r(o){return e.exit("htmlFlowData"),e.enter("lineEndingBlank"),e.consume(o),e.exit("lineEndingBlank"),e.attempt(wy,t,n)}}const Kye={name:"htmlText",tokenize:Vye};function Vye(e,t,n){const r=this;let o,i,a,s;return l;function l(R){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(R),u}function u(R){return R===33?(e.consume(R),d):R===47?(e.consume(R),A):R===63?(e.consume(R),F):Va(R)?(e.consume(R),j):n(R)}function d(R){return R===45?(e.consume(R),h):R===91?(e.consume(R),i="CDATA[",a=0,b):Va(R)?(e.consume(R),y):n(R)}function h(R){return R===45?(e.consume(R),p):n(R)}function p(R){return R===null||R===62?n(R):R===45?(e.consume(R),m):v(R)}function m(R){return R===null||R===62?n(R):v(R)}function v(R){return R===null?n(R):R===45?(e.consume(R),_):ct(R)?(s=v,_e(R)):(e.consume(R),v)}function _(R){return R===45?(e.consume(R),fe):v(R)}function b(R){return R===i.charCodeAt(a++)?(e.consume(R),a===i.length?E:b):n(R)}function E(R){return R===null?n(R):R===93?(e.consume(R),w):ct(R)?(s=E,_e(R)):(e.consume(R),E)}function w(R){return R===93?(e.consume(R),k):E(R)}function k(R){return R===62?fe(R):R===93?(e.consume(R),k):E(R)}function y(R){return R===null||R===62?fe(R):ct(R)?(s=y,_e(R)):(e.consume(R),y)}function F(R){return R===null?n(R):R===63?(e.consume(R),C):ct(R)?(s=F,_e(R)):(e.consume(R),F)}function C(R){return R===62?fe(R):F(R)}function A(R){return Va(R)?(e.consume(R),P):n(R)}function P(R){return R===45||Ta(R)?(e.consume(R),P):I(R)}function I(R){return ct(R)?(s=I,_e(R)):mr(R)?(e.consume(R),I):fe(R)}function j(R){return R===45||Ta(R)?(e.consume(R),j):R===47||R===62||Ki(R)?H(R):n(R)}function H(R){return R===47?(e.consume(R),fe):R===58||R===95||Va(R)?(e.consume(R),K):ct(R)?(s=H,_e(R)):mr(R)?(e.consume(R),H):fe(R)}function K(R){return R===45||R===46||R===58||R===95||Ta(R)?(e.consume(R),K):U(R)}function U(R){return R===61?(e.consume(R),pe):ct(R)?(s=U,_e(R)):mr(R)?(e.consume(R),U):H(R)}function pe(R){return R===null||R===60||R===61||R===62||R===96?n(R):R===34||R===39?(e.consume(R),o=R,se):ct(R)?(s=pe,_e(R)):mr(R)?(e.consume(R),pe):(e.consume(R),o=void 0,$)}function se(R){return R===o?(e.consume(R),J):R===null?n(R):ct(R)?(s=se,_e(R)):(e.consume(R),se)}function J(R){return R===62||R===47||Ki(R)?H(R):n(R)}function $(R){return R===null||R===34||R===39||R===60||R===61||R===96?n(R):R===62||Ki(R)?H(R):(e.consume(R),$)}function _e(R){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(R),e.exit("lineEnding"),dn(e,ve,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function ve(R){return e.enter("htmlTextData"),s(R)}function fe(R){return R===62?(e.consume(R),e.exit("htmlTextData"),e.exit("htmlText"),t):n(R)}}const Fw={name:"labelEnd",tokenize:e5e,resolveTo:Jye,resolveAll:Zye},Yye={tokenize:t5e},Qye={tokenize:n5e},Xye={tokenize:r5e};function Zye(e){let t=-1,n;for(;++t<e.length;)n=e[t][1],(n.type==="labelImage"||n.type==="labelLink"||n.type==="labelEnd")&&(e.splice(t+1,n.type==="labelImage"?4:2),n.type="data",t++);return e}function Jye(e,t){let n=e.length,r=0,o,i,a,s;for(;n--;)if(o=e[n][1],i){if(o.type==="link"||o.type==="labelLink"&&o._inactive)break;e[n][0]==="enter"&&o.type==="labelLink"&&(o._inactive=!0)}else if(a){if(e[n][0]==="enter"&&(o.type==="labelImage"||o.type==="labelLink")&&!o._balanced&&(i=n,o.type!=="labelLink")){r=2;break}}else o.type==="labelEnd"&&(a=n);const l={type:e[i][1].type==="labelLink"?"link":"image",start:Object.assign({},e[i][1].start),end:Object.assign({},e[e.length-1][1].end)},u={type:"label",start:Object.assign({},e[i][1].start),end:Object.assign({},e[a][1].end)},d={type:"labelText",start:Object.assign({},e[i+r+2][1].end),end:Object.assign({},e[a-2][1].start)};return s=[["enter",l,t],["enter",u,t]],s=zi(s,e.slice(i+1,i+r+3)),s=zi(s,[["enter",d,t]]),s=zi(s,Nw(t.parser.constructs.insideSpan.null,e.slice(i+r+4,a-3),t)),s=zi(s,[["exit",d,t],e[a-2],e[a-1],["exit",u,t]]),s=zi(s,e.slice(a+1)),s=zi(s,[["exit",l,t]]),ds(e,i,e.length,s),e}function e5e(e,t,n){const r=this;let o=r.events.length,i,a;for(;o--;)if((r.events[o][1].type==="labelImage"||r.events[o][1].type==="labelLink")&&!r.events[o][1]._balanced){i=r.events[o][1];break}return s;function s(d){return i?i._inactive?u(d):(a=r.parser.defined.includes(Bd(r.sliceSerialize({start:i.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(d),e.exit("labelMarker"),e.exit("labelEnd"),l):n(d)}function l(d){return d===40?e.attempt(Yye,t,a?t:u)(d):d===91?e.attempt(Qye,t,a?e.attempt(Xye,t,u):u)(d):a?t(d):u(d)}function u(d){return i._balanced=!0,n(d)}}function t5e(e,t,n){return r;function r(l){return e.enter("resource"),e.enter("resourceMarker"),e.consume(l),e.exit("resourceMarker"),Vh(e,o)}function o(l){return l===41?s(l):mM(e,i,n,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(l)}function i(l){return Ki(l)?Vh(e,a)(l):s(l)}function a(l){return l===34||l===39||l===40?vM(e,Vh(e,s),n,"resourceTitle","resourceTitleMarker","resourceTitleString")(l):s(l)}function s(l){return l===41?(e.enter("resourceMarker"),e.consume(l),e.exit("resourceMarker"),e.exit("resource"),t):n(l)}}function n5e(e,t,n){const r=this;return o;function o(a){return gM.call(r,e,i,n,"reference","referenceMarker","referenceString")(a)}function i(a){return r.parser.defined.includes(Bd(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(a):n(a)}}function r5e(e,t,n){return r;function r(i){return e.enter("reference"),e.enter("referenceMarker"),e.consume(i),e.exit("referenceMarker"),o}function o(i){return i===93?(e.enter("referenceMarker"),e.consume(i),e.exit("referenceMarker"),e.exit("reference"),t):n(i)}}const o5e={name:"labelStartImage",tokenize:i5e,resolveAll:Fw.resolveAll};function i5e(e,t,n){const r=this;return o;function o(s){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(s),e.exit("labelImageMarker"),i}function i(s){return s===91?(e.enter("labelMarker"),e.consume(s),e.exit("labelMarker"),e.exit("labelImage"),a):n(s)}function a(s){return s===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(s):t(s)}}const a5e={name:"labelStartLink",tokenize:s5e,resolveAll:Fw.resolveAll};function s5e(e,t,n){const r=this;return o;function o(a){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(a),e.exit("labelMarker"),e.exit("labelLink"),i}function i(a){return a===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(a):t(a)}}const q9={name:"lineEnding",tokenize:l5e};function l5e(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),dn(e,t,"linePrefix")}}const Yg={name:"thematicBreak",tokenize:u5e};function u5e(e,t,n){let r=0,o;return i;function i(l){return e.enter("thematicBreak"),o=l,a(l)}function a(l){return l===o?(e.enter("thematicBreakSequence"),s(l)):mr(l)?dn(e,a,"whitespace")(l):r<3||l!==null&&!ct(l)?n(l):(e.exit("thematicBreak"),t(l))}function s(l){return l===o?(e.consume(l),r++,s):(e.exit("thematicBreakSequence"),a(l))}}const qo={name:"list",tokenize:d5e,continuation:{tokenize:h5e},exit:m5e},c5e={tokenize:g5e,partial:!0},f5e={tokenize:p5e,partial:!0};function d5e(e,t,n){const r=this,o=r.events[r.events.length-1];let i=o&&o[1].type==="linePrefix"?o[2].sliceSerialize(o[1],!0).length:0,a=0;return s;function s(m){const v=r.containerState.type||(m===42||m===43||m===45?"listUnordered":"listOrdered");if(v==="listUnordered"?!r.containerState.marker||m===r.containerState.marker:t4(m)){if(r.containerState.type||(r.containerState.type=v,e.enter(v,{_container:!0})),v==="listUnordered")return e.enter("listItemPrefix"),m===42||m===45?e.check(Yg,n,u)(m):u(m);if(!r.interrupt||m===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),l(m)}return n(m)}function l(m){return t4(m)&&++a<10?(e.consume(m),l):(!r.interrupt||a<2)&&(r.containerState.marker?m===r.containerState.marker:m===41||m===46)?(e.exit("listItemValue"),u(m)):n(m)}function u(m){return e.enter("listItemMarker"),e.consume(m),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||m,e.check(wy,r.interrupt?n:d,e.attempt(c5e,p,h))}function d(m){return r.containerState.initialBlankLine=!0,i++,p(m)}function h(m){return mr(m)?(e.enter("listItemPrefixWhitespace"),e.consume(m),e.exit("listItemPrefixWhitespace"),p):n(m)}function p(m){return r.containerState.size=i+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(m)}}function h5e(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(wy,o,i);function o(s){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,dn(e,t,"listItemIndent",r.containerState.size+1)(s)}function i(s){return r.containerState.furtherBlankLines||!mr(s)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,a(s)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(f5e,t,a)(s))}function a(s){return r.containerState._closeFlow=!0,r.interrupt=void 0,dn(e,e.attempt(qo,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s)}}function p5e(e,t,n){const r=this;return dn(e,o,"listItemIndent",r.containerState.size+1);function o(i){const a=r.events[r.events.length-1];return a&&a[1].type==="listItemIndent"&&a[2].sliceSerialize(a[1],!0).length===r.containerState.size?t(i):n(i)}}function m5e(e){e.exit(this.containerState.type)}function g5e(e,t,n){const r=this;return dn(e,o,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function o(i){const a=r.events[r.events.length-1];return!mr(i)&&a&&a[1].type==="listItemPrefixWhitespace"?t(i):n(i)}}const X7={name:"setextUnderline",tokenize:b5e,resolveTo:v5e};function v5e(e,t){let n=e.length,r,o,i;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(o=n)}else e[n][1].type==="content"&&e.splice(n,1),!i&&e[n][1].type==="definition"&&(i=n);const a={type:"setextHeading",start:Object.assign({},e[o][1].start),end:Object.assign({},e[e.length-1][1].end)};return e[o][1].type="setextHeadingText",i?(e.splice(o,0,["enter",a,t]),e.splice(i+1,0,["exit",e[r][1],t]),e[r][1].end=Object.assign({},e[i][1].end)):e[r][1]=a,e.push(["exit",a,t]),e}function b5e(e,t,n){const r=this;let o=r.events.length,i,a;for(;o--;)if(r.events[o][1].type!=="lineEnding"&&r.events[o][1].type!=="linePrefix"&&r.events[o][1].type!=="content"){a=r.events[o][1].type==="paragraph";break}return s;function s(d){return!r.parser.lazy[r.now().line]&&(r.interrupt||a)?(e.enter("setextHeadingLine"),e.enter("setextHeadingLineSequence"),i=d,l(d)):n(d)}function l(d){return d===i?(e.consume(d),l):(e.exit("setextHeadingLineSequence"),dn(e,u,"lineSuffix")(d))}function u(d){return d===null||ct(d)?(e.exit("setextHeadingLine"),t(d)):n(d)}}const y5e={tokenize:E5e};function E5e(e){const t=this,n=e.attempt(wy,r,e.attempt(this.parser.constructs.flowInitial,o,dn(e,e.attempt(this.parser.constructs.flow,o,e.attempt(Cye,o)),"linePrefix")));return n;function r(i){if(i===null){e.consume(i);return}return e.enter("lineEndingBlank"),e.consume(i),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function o(i){if(i===null){e.consume(i);return}return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const _5e={resolveAll:yM()},T5e=bM("string"),w5e=bM("text");function bM(e){return{tokenize:t,resolveAll:yM(e==="text"?k5e:void 0)};function t(n){const r=this,o=this.parser.constructs[e],i=n.attempt(o,a,s);return a;function a(d){return u(d)?i(d):s(d)}function s(d){if(d===null){n.consume(d);return}return n.enter("data"),n.consume(d),l}function l(d){return u(d)?(n.exit("data"),i(d)):(n.consume(d),l)}function u(d){if(d===null)return!0;const h=o[d];let p=-1;if(h)for(;++p<h.length;){const m=h[p];if(!m.previous||m.previous.call(r,r.previous))return!0}return!1}}}function yM(e){return t;function t(n,r){let o=-1,i;for(;++o<=n.length;)i===void 0?n[o]&&n[o][1].type==="data"&&(i=o,o++):(!n[o]||n[o][1].type!=="data")&&(o!==i+2&&(n[i][1].end=n[o-1][1].end,n.splice(i+2,o-i-2),o=i+2),i=void 0);return e?e(n,r):n}}function k5e(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],o=t.sliceStream(r);let i=o.length,a=-1,s=0,l;for(;i--;){const u=o[i];if(typeof u=="string"){for(a=u.length;u.charCodeAt(a-1)===32;)s++,a--;if(a)break;a=-1}else if(u===-2)l=!0,s++;else if(u!==-1){i++;break}}if(s){const u={type:n===e.length||l||s<2?"lineSuffix":"hardBreakTrailing",start:{line:r.end.line,column:r.end.column-s,offset:r.end.offset-s,_index:r.start._index+i,_bufferIndex:i?a:r.start._bufferIndex+a},end:Object.assign({},r.end)};r.end=Object.assign({},u.start),r.start.offset===r.end.offset?Object.assign(r,u):(e.splice(n,0,["enter",u,t],["exit",u,t]),n+=2)}n++}return e}function S5e(e,t,n){let r=Object.assign(n?Object.assign({},n):{line:1,column:1,offset:0},{_index:0,_bufferIndex:-1});const o={},i=[];let a=[],s=[];const l={consume:w,enter:k,exit:y,attempt:A(F),check:A(C),interrupt:A(C,{interrupt:!0})},u={previous:null,code:null,containerState:{},events:[],parser:e,sliceStream:m,sliceSerialize:p,now:v,defineSkip:_,write:h};let d=t.tokenize.call(u,l);return t.resolveAll&&i.push(t),u;function h(H){return a=zi(a,H),b(),a[a.length-1]!==null?[]:(P(t,0),u.events=Nw(i,u.events,u),u.events)}function p(H,K){return C5e(m(H),K)}function m(H){return x5e(a,H)}function v(){return Object.assign({},r)}function _(H){o[H.line]=H.column,j()}function b(){let H;for(;r._index<a.length;){const K=a[r._index];if(typeof K=="string")for(H=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===H&&r._bufferIndex<K.length;)E(K.charCodeAt(r._bufferIndex));else E(K)}}function E(H){d=d(H)}function w(H){ct(H)?(r.line++,r.column=1,r.offset+=H===-3?2:1,j()):H!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===a[r._index].length&&(r._bufferIndex=-1,r._index++)),u.previous=H}function k(H,K){const U=K||{};return U.type=H,U.start=v(),u.events.push(["enter",U,u]),s.push(U),U}function y(H){const K=s.pop();return K.end=v(),u.events.push(["exit",K,u]),K}function F(H,K){P(H,K.from)}function C(H,K){K.restore()}function A(H,K){return U;function U(pe,se,J){let $,_e,ve,fe;return Array.isArray(pe)?L(pe):"tokenize"in pe?L([pe]):R(pe);function R(Le){return st;function st(We){const rt=We!==null&&Le[We],Zt=We!==null&&Le.null,qn=[...Array.isArray(rt)?rt:rt?[rt]:[],...Array.isArray(Zt)?Zt:Zt?[Zt]:[]];return L(qn)(We)}}function L(Le){return $=Le,_e=0,Le.length===0?J:Ae(Le[_e])}function Ae(Le){return st;function st(We){return fe=I(),ve=Le,Le.partial||(u.currentConstruct=Le),Le.name&&u.parser.constructs.disable.null.includes(Le.name)?Ve():Le.tokenize.call(K?Object.assign(Object.create(u),K):u,l,Ue,Ve)(We)}}function Ue(Le){return H(ve,fe),se}function Ve(Le){return fe.restore(),++_e<$.length?Ae($[_e]):J}}}function P(H,K){H.resolveAll&&!i.includes(H)&&i.push(H),H.resolve&&ds(u.events,K,u.events.length-K,H.resolve(u.events.slice(K),u)),H.resolveTo&&(u.events=H.resolveTo(u.events,u))}function I(){const H=v(),K=u.previous,U=u.currentConstruct,pe=u.events.length,se=Array.from(s);return{restore:J,from:pe};function J(){r=H,u.previous=K,u.currentConstruct=U,u.events.length=pe,s=se,j()}}function j(){r.line in o&&r.column<2&&(r.column=o[r.line],r.offset+=o[r.line]-1)}}function x5e(e,t){const n=t.start._index,r=t.start._bufferIndex,o=t.end._index,i=t.end._bufferIndex;let a;return n===o?a=[e[n].slice(r,i)]:(a=e.slice(n,o),r>-1&&(a[0]=a[0].slice(r)),i>0&&a.push(e[o].slice(0,i))),a}function C5e(e,t){let n=-1;const r=[];let o;for(;++n<e.length;){const i=e[n];let a;if(typeof i=="string")a=i;else switch(i){case-5:{a="\r";break}case-4:{a=` `;break}case-3:{a=`\r `;break}case-2:{a=t?" ":" ";break}case-1:{if(!t&&o)continue;a=" ";break}default:a=String.fromCharCode(i)}o=i===-2,r.push(a)}return r.join("")}const A5e={[42]:qo,[43]:qo,[45]:qo,[48]:qo,[49]:qo,[50]:qo,[51]:qo,[52]:qo,[53]:qo,[54]:qo,[55]:qo,[56]:qo,[57]:qo,[62]:fM},N5e={[91]:Bye},F5e={[-2]:U9,[-1]:U9,[32]:U9},I5e={[35]:Lye,[42]:Yg,[45]:[X7,Yg],[60]:Uye,[61]:X7,[95]:Yg,[96]:Y7,[126]:Y7},B5e={[38]:hM,[92]:dM},R5e={[-5]:q9,[-4]:q9,[-3]:q9,[33]:o5e,[38]:hM,[42]:r4,[60]:[cye,Kye],[91]:a5e,[92]:[Pye,dM],[93]:Fw,[95]:r4,[96]:Tye},O5e={null:[r4,_5e]},D5e={null:[42,95]},P5e={null:[]},M5e=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:D5e,contentInitial:N5e,disable:P5e,document:A5e,flow:I5e,flowInitial:F5e,insideSpan:O5e,string:B5e,text:R5e},Symbol.toStringTag,{value:"Module"}));function L5e(e={}){const t=Ybe([M5e].concat(e.extensions||[])),n={defined:[],lazy:{},constructs:t,content:r(rye),document:r(iye),flow:r(y5e),string:r(T5e),text:r(w5e)};return n;function r(o){return i;function i(a){return S5e(n,o,a)}}}const Z7=/[\0\t\n\r]/g;function j5e(){let e=1,t="",n=!0,r;return o;function o(i,a,s){const l=[];let u,d,h,p,m;for(i=t+i.toString(a),h=0,t="",n&&(i.charCodeAt(0)===65279&&h++,n=void 0);h<i.length;){if(Z7.lastIndex=h,u=Z7.exec(i),p=u&&u.index!==void 0?u.index:i.length,m=i.charCodeAt(p),!u){t=i.slice(h);break}if(m===10&&h===p&&r)l.push(-3),r=void 0;else switch(r&&(l.push(-5),r=void 0),h<p&&(l.push(i.slice(h,p)),e+=p-h),m){case 0:{l.push(65533),e++;break}case 9:{for(d=Math.ceil(e/4)*4,l.push(-2);e++<d;)l.push(-1);break}case 10:{l.push(-4),e=1;break}default:r=!0,e=1}h=p+1}return s&&(r&&l.push(-5),t&&l.push(t),l.push(null)),l}}function z5e(e){for(;!pM(e););return e}function EM(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCharCode(n)}const H5e=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function U5e(e){return e.replace(H5e,q5e)}function q5e(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const o=n.charCodeAt(1),i=o===120||o===88;return EM(n.slice(i?2:1),i?16:10)}return L0(n)||e}var If={}.hasOwnProperty;function Qg(e){return!e||typeof e!="object"?"":If.call(e,"position")||If.call(e,"type")?J7(e.position):If.call(e,"start")||If.call(e,"end")?J7(e):If.call(e,"line")||If.call(e,"column")?o4(e):""}function o4(e){return eA(e&&e.line)+":"+eA(e&&e.column)}function J7(e){return o4(e&&e.start)+"-"+o4(e&&e.end)}function eA(e){return e&&typeof e=="number"?e:1}const i4={}.hasOwnProperty,$5e=function(e,t,n){return typeof t!="string"&&(n=t,t=void 0),W5e(n)(z5e(L5e(n).document().write(j5e()(e,t,!0))))};function W5e(e={}){const t=_M({transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:l(pn),autolinkProtocol:K,autolinkEmail:K,atxHeading:l(an),blockQuote:l(er),characterEscape:K,characterReference:K,codeFenced:l(tr),codeFencedFenceInfo:u,codeFencedFenceMeta:u,codeIndented:l(tr,u),codeText:l(In,u),codeTextData:K,data:K,codeFlowValue:K,definition:l(br),definitionDestinationString:u,definitionLabelString:u,definitionTitleString:u,emphasis:l(Nr),hardBreakEscape:l(yo),hardBreakTrailing:l(yo),htmlFlow:l(Eo,u),htmlFlowData:K,htmlText:l(Eo,u),htmlTextData:K,image:l(jr),label:u,link:l(pn),listItem:l(mn),listItemValue:_,listOrdered:l(Mn,v),listUnordered:l(Mn),paragraph:l(Po),reference:Le,referenceString:u,resourceDestinationString:u,resourceTitleString:u,setextHeading:l(an),strong:l(me),thematicBreak:l(ie)},exit:{atxHeading:h(),atxHeadingSequence:P,autolink:h(),autolinkEmail:qn,autolinkProtocol:Zt,blockQuote:h(),characterEscapeValue:U,characterReferenceMarkerHexadecimal:We,characterReferenceMarkerNumeric:We,characterReferenceValue:rt,codeFenced:h(k),codeFencedFence:w,codeFencedFenceInfo:b,codeFencedFenceMeta:E,codeFlowValue:U,codeIndented:h(y),codeText:h(_e),codeTextData:U,data:U,definition:h(),definitionDestinationString:A,definitionLabelString:F,definitionTitleString:C,emphasis:h(),hardBreakEscape:h(se),hardBreakTrailing:h(se),htmlFlow:h(J),htmlFlowData:U,htmlText:h($),htmlTextData:U,image:h(fe),label:L,labelText:R,lineEnding:pe,link:h(ve),listItem:h(),listOrdered:h(),listUnordered:h(),paragraph:h(),referenceString:st,resourceDestinationString:Ae,resourceTitleString:Ue,resource:Ve,setextHeading:h(H),setextHeadingLineSequence:j,setextHeadingText:I,strong:h(),thematicBreak:h()}},e.mdastExtensions||[]),n={};return r;function r(G){let ae={type:"root",children:[]};const Te=[ae],Oe=[],$e=[],_t={stack:Te,tokenStack:Oe,config:t,enter:d,exit:p,buffer:u,resume:m,setData:i,getData:a};let Qe=-1;for(;++Qe<G.length;)if(G[Qe][1].type==="listOrdered"||G[Qe][1].type==="listUnordered")if(G[Qe][0]==="enter")$e.push(Qe);else{const lt=$e.pop();Qe=o(G,lt,Qe)}for(Qe=-1;++Qe<G.length;){const lt=t[G[Qe][0]];i4.call(lt,G[Qe][1].type)&&lt[G[Qe][1].type].call(Object.assign({sliceSerialize:G[Qe][2].sliceSerialize},_t),G[Qe][1])}if(Oe.length>0){const lt=Oe[Oe.length-1];(lt[1]||tA).call(_t,void 0,lt[0])}for(ae.position={start:s(G.length>0?G[0][1].start:{line:1,column:1,offset:0}),end:s(G.length>0?G[G.length-2][1].end:{line:1,column:1,offset:0})},Qe=-1;++Qe<t.transforms.length;)ae=t.transforms[Qe](ae)||ae;return ae}function o(G,ae,Te){let Oe=ae-1,$e=-1,_t=!1,Qe,lt,Kt,Pt;for(;++Oe<=Te;){const gt=G[Oe];if(gt[1].type==="listUnordered"||gt[1].type==="listOrdered"||gt[1].type==="blockQuote"?(gt[0]==="enter"?$e++:$e--,Pt=void 0):gt[1].type==="lineEndingBlank"?gt[0]==="enter"&&(Qe&&!Pt&&!$e&&!Kt&&(Kt=Oe),Pt=void 0):gt[1].type==="linePrefix"||gt[1].type==="listItemValue"||gt[1].type==="listItemMarker"||gt[1].type==="listItemPrefix"||gt[1].type==="listItemPrefixWhitespace"||(Pt=void 0),!$e&&gt[0]==="enter"&&gt[1].type==="listItemPrefix"||$e===-1&&gt[0]==="exit"&&(gt[1].type==="listUnordered"||gt[1].type==="listOrdered")){if(Qe){let Ln=Oe;for(lt=void 0;Ln--;){const Tn=G[Ln];if(Tn[1].type==="lineEnding"||Tn[1].type==="lineEndingBlank"){if(Tn[0]==="exit")continue;lt&&(G[lt][1].type="lineEndingBlank",_t=!0),Tn[1].type="lineEnding",lt=Ln}else if(!(Tn[1].type==="linePrefix"||Tn[1].type==="blockQuotePrefix"||Tn[1].type==="blockQuotePrefixWhitespace"||Tn[1].type==="blockQuoteMarker"||Tn[1].type==="listItemIndent"))break}Kt&&(!lt||Kt<lt)&&(Qe._spread=!0),Qe.end=Object.assign({},lt?G[lt][1].start:gt[1].end),G.splice(lt||Oe,0,["exit",Qe,gt[2]]),Oe++,Te++}gt[1].type==="listItemPrefix"&&(Qe={type:"listItem",_spread:!1,start:Object.assign({},gt[1].start)},G.splice(Oe,0,["enter",Qe,gt[2]]),Oe++,Te++,Kt=void 0,Pt=!0)}}return G[ae][1]._spread=_t,Te}function i(G,ae){n[G]=ae}function a(G){return n[G]}function s(G){return{line:G.line,column:G.column,offset:G.offset}}function l(G,ae){return Te;function Te(Oe){d.call(this,G(Oe),Oe),ae&&ae.call(this,Oe)}}function u(){this.stack.push({type:"fragment",children:[]})}function d(G,ae,Te){return this.stack[this.stack.length-1].children.push(G),this.stack.push(G),this.tokenStack.push([ae,Te]),G.position={start:s(ae.start)},G}function h(G){return ae;function ae(Te){G&&G.call(this,Te),p.call(this,Te)}}function p(G,ae){const Te=this.stack.pop(),Oe=this.tokenStack.pop();if(Oe)Oe[0].type!==G.type&&(ae?ae.call(this,G,Oe[0]):(Oe[1]||tA).call(this,G,Oe[0]));else throw new Error("Cannot close `"+G.type+"` ("+Qg({start:G.start,end:G.end})+"): it’s not open");return Te.position.end=s(G.end),Te}function m(){return Vbe(this.stack.pop())}function v(){i("expectingFirstListItemValue",!0)}function _(G){if(a("expectingFirstListItemValue")){const ae=this.stack[this.stack.length-2];ae.start=Number.parseInt(this.sliceSerialize(G),10),i("expectingFirstListItemValue")}}function b(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.lang=G}function E(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.meta=G}function w(){a("flowCodeInside")||(this.buffer(),i("flowCodeInside",!0))}function k(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.value=G.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),i("flowCodeInside")}function y(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.value=G.replace(/(\r?\n|\r)$/g,"")}function F(G){const ae=this.resume(),Te=this.stack[this.stack.length-1];Te.label=ae,Te.identifier=Bd(this.sliceSerialize(G)).toLowerCase()}function C(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.title=G}function A(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.url=G}function P(G){const ae=this.stack[this.stack.length-1];if(!ae.depth){const Te=this.sliceSerialize(G).length;ae.depth=Te}}function I(){i("setextHeadingSlurpLineEnding",!0)}function j(G){const ae=this.stack[this.stack.length-1];ae.depth=this.sliceSerialize(G).charCodeAt(0)===61?1:2}function H(){i("setextHeadingSlurpLineEnding")}function K(G){const ae=this.stack[this.stack.length-1];let Te=ae.children[ae.children.length-1];(!Te||Te.type!=="text")&&(Te=le(),Te.position={start:s(G.start)},ae.children.push(Te)),this.stack.push(Te)}function U(G){const ae=this.stack.pop();ae.value+=this.sliceSerialize(G),ae.position.end=s(G.end)}function pe(G){const ae=this.stack[this.stack.length-1];if(a("atHardBreak")){const Te=ae.children[ae.children.length-1];Te.position.end=s(G.end),i("atHardBreak");return}!a("setextHeadingSlurpLineEnding")&&t.canContainEols.includes(ae.type)&&(K.call(this,G),U.call(this,G))}function se(){i("atHardBreak",!0)}function J(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.value=G}function $(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.value=G}function _e(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.value=G}function ve(){const G=this.stack[this.stack.length-1];a("inReference")?(G.type+="Reference",G.referenceType=a("referenceType")||"shortcut",delete G.url,delete G.title):(delete G.identifier,delete G.label),i("referenceType")}function fe(){const G=this.stack[this.stack.length-1];a("inReference")?(G.type+="Reference",G.referenceType=a("referenceType")||"shortcut",delete G.url,delete G.title):(delete G.identifier,delete G.label),i("referenceType")}function R(G){const ae=this.stack[this.stack.length-2],Te=this.sliceSerialize(G);ae.label=U5e(Te),ae.identifier=Bd(Te).toLowerCase()}function L(){const G=this.stack[this.stack.length-1],ae=this.resume(),Te=this.stack[this.stack.length-1];i("inReference",!0),Te.type==="link"?Te.children=G.children:Te.alt=ae}function Ae(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.url=G}function Ue(){const G=this.resume(),ae=this.stack[this.stack.length-1];ae.title=G}function Ve(){i("inReference")}function Le(){i("referenceType","collapsed")}function st(G){const ae=this.resume(),Te=this.stack[this.stack.length-1];Te.label=ae,Te.identifier=Bd(this.sliceSerialize(G)).toLowerCase(),i("referenceType","full")}function We(G){i("characterReferenceType",G.type)}function rt(G){const ae=this.sliceSerialize(G),Te=a("characterReferenceType");let Oe;Te?(Oe=EM(ae,Te==="characterReferenceMarkerNumeric"?10:16),i("characterReferenceType")):Oe=L0(ae);const $e=this.stack.pop();$e.value+=Oe,$e.position.end=s(G.end)}function Zt(G){U.call(this,G);const ae=this.stack[this.stack.length-1];ae.url=this.sliceSerialize(G)}function qn(G){U.call(this,G);const ae=this.stack[this.stack.length-1];ae.url="mailto:"+this.sliceSerialize(G)}function er(){return{type:"blockquote",children:[]}}function tr(){return{type:"code",lang:null,meta:null,value:""}}function In(){return{type:"inlineCode",value:""}}function br(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Nr(){return{type:"emphasis",children:[]}}function an(){return{type:"heading",depth:void 0,children:[]}}function yo(){return{type:"break"}}function Eo(){return{type:"html",value:""}}function jr(){return{type:"image",title:null,url:"",alt:null}}function pn(){return{type:"link",title:null,url:"",children:[]}}function Mn(G){return{type:"list",ordered:G.type==="listOrdered",start:null,spread:G._spread,children:[]}}function mn(G){return{type:"listItem",spread:G._spread,checked:null,children:[]}}function Po(){return{type:"paragraph",children:[]}}function me(){return{type:"strong",children:[]}}function le(){return{type:"text",value:""}}function ie(){return{type:"thematicBreak"}}}function _M(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?_M(e,r):G5e(e,r)}return e}function G5e(e,t){let n;for(n in t)if(i4.call(t,n)){const r=n==="canContainEols"||n==="transforms",i=(i4.call(e,n)?e[n]:void 0)||(e[n]=r?[]:{}),a=t[n];a&&(r?e[n]=[...i,...a]:Object.assign(i,a))}}function tA(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+Qg({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+Qg({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+Qg({start:t.start,end:t.end})+") is still open")}function K5e(e){Object.assign(this,{Parser:n=>{const r=this.data("settings");return $5e(n,Object.assign({},r,e,{extensions:this.data("micromarkExtensions")||[],mdastExtensions:this.data("fromMarkdownExtensions")||[]}))}})}var Mr=function(e,t,n){var r={type:String(e)};return n==null&&(typeof t=="string"||Array.isArray(t))?n=t:Object.assign(r,t),Array.isArray(n)?r.children=n:n!=null&&(r.value=String(n)),r};const Xg={}.hasOwnProperty;function V5e(e,t){const n=t.data||{};return"value"in t&&!(Xg.call(n,"hName")||Xg.call(n,"hProperties")||Xg.call(n,"hChildren"))?e.augment(t,Mr("text",t.value)):e(t,"div",Do(e,t))}function TM(e,t,n){const r=t&&t.type;let o;if(!r)throw new Error("Expected node, got `"+t+"`");return Xg.call(e.handlers,r)?o=e.handlers[r]:e.passThrough&&e.passThrough.includes(r)?o=Y5e:o=e.unknownHandler,(typeof o=="function"?o:V5e)(e,t,n)}function Y5e(e,t){return"children"in t?{...t,children:Do(e,t)}:t}function Do(e,t){const n=[];if("children"in t){const r=t.children;let o=-1;for(;++o<r.length;){const i=TM(e,r[o],t);if(i){if(o&&r[o-1].type==="break"&&(!Array.isArray(i)&&i.type==="text"&&(i.value=i.value.replace(/^\s+/,"")),!Array.isArray(i)&&i.type==="element")){const a=i.children[0];a&&a.type==="text"&&(a.value=a.value.replace(/^\s+/,""))}Array.isArray(i)?n.push(...i):n.push(i)}}}return n}const h1=function(e){if(e==null)return J5e;if(typeof e=="string")return Z5e(e);if(typeof e=="object")return Array.isArray(e)?Q5e(e):X5e(e);if(typeof e=="function")return ky(e);throw new Error("Expected function, string, or object as test")};function Q5e(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=h1(e[n]);return ky(r);function r(...o){let i=-1;for(;++i<t.length;)if(t[i].call(this,...o))return!0;return!1}}function X5e(e){return ky(t);function t(n){let r;for(r in e)if(n[r]!==e[r])return!1;return!0}}function Z5e(e){return ky(t);function t(n){return n&&n.type===e}}function ky(e){return t;function t(...n){return!!e.call(this,...n)}}function J5e(){return!0}const e2e=!0,t2e="skip",nA=!1,n2e=function(e,t,n,r){typeof t=="function"&&typeof n!="function"&&(r=n,n=t,t=null);const o=h1(t),i=r?-1:1;a(e,null,[])();function a(s,l,u){const d=typeof s=="object"&&s!==null?s:{};let h;return typeof d.type=="string"&&(h=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0,Object.defineProperty(p,"name",{value:"node ("+(d.type+(h?"<"+h+">":""))+")"})),p;function p(){let m=[],v,_,b;if((!t||o(s,l,u[u.length-1]||null))&&(m=r2e(n(s,u)),m[0]===nA))return m;if(s.children&&m[0]!==t2e)for(_=(r?s.children.length:-1)+i,b=u.concat(s);_>-1&&_<s.children.length;){if(v=a(s.children[_],_,b)(),v[0]===nA)return v;_=typeof v[1]=="number"?v[1]:_+i}return m}}};function r2e(e){return Array.isArray(e)?e:typeof e=="number"?[e2e,e]:[e]}const Iw=function(e,t,n,r){typeof t=="function"&&typeof n!="function"&&(r=n,n=t,t=null),n2e(e,t,o,r);function o(i,a){const s=a[a.length-1];return n(i,s?s.children.indexOf(i):null,s)}};var Sy=wM("start"),Bw=wM("end");function wM(e){return t;function t(n){var r=n&&n.position&&n.position[e]||{};return{line:r.line||null,column:r.column||null,offset:r.offset>-1?r.offset:null}}}function o2e(e){return!e||!e.position||!e.position.start||!e.position.start.line||!e.position.start.column||!e.position.end||!e.position.end.line||!e.position.end.column}const i2e=!0,a2e="skip",rA=!1,s2e=function(e,t,n,r){typeof t=="function"&&typeof n!="function"&&(r=n,n=t,t=null);var o=h1(t),i=r?-1:1;a(e,null,[])();function a(s,l,u){var d=typeof s=="object"&&s!==null?s:{},h;return typeof d.type=="string"&&(h=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0,Object.defineProperty(p,"name",{value:"node ("+(d.type+(h?"<"+h+">":""))+")"})),p;function p(){var m=[],v,_,b;if((!t||o(s,l,u[u.length-1]||null))&&(m=l2e(n(s,u)),m[0]===rA))return m;if(s.children&&m[0]!==a2e)for(_=(r?s.children.length:-1)+i,b=u.concat(s);_>-1&&_<s.children.length;){if(v=a(s.children[_],_,b)(),v[0]===rA)return v;_=typeof v[1]=="number"?v[1]:_+i}return m}}};function l2e(e){return Array.isArray(e)?e:typeof e=="number"?[i2e,e]:[e]}const u2e=function(e,t,n,r){typeof t=="function"&&typeof n!="function"&&(r=n,n=t,t=null),s2e(e,t,o,r);function o(i,a){var s=a[a.length-1];return n(i,s?s.children.indexOf(i):null,s)}},oA={}.hasOwnProperty;function c2e(e){const t=Object.create(null);if(!e||!e.type)throw new Error("mdast-util-definitions expected node");return u2e(e,"definition",n),r;function n(o){const i=iA(o.identifier);i&&!oA.call(t,i)&&(t[i]=o)}function r(o){const i=iA(o);return i&&oA.call(t,i)?t[i]:null}}function iA(e){return String(e||"").toUpperCase()}function kM(e,t){return e(t,"hr")}function lu(e,t){const n=[];let r=-1;for(t&&n.push(Mr("text",` `));++r<e.length;)r&&n.push(Mr("text",` `)),n.push(e[r]);return t&&e.length>0&&n.push(Mr("text",` `)),n}function SM(e,t){const n={},r=t.ordered?"ol":"ul",o=Do(e,t);let i=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++i<o.length;){const a=o[i];if(a.type==="element"&&a.tagName==="li"&&a.properties&&Array.isArray(a.properties.className)&&a.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}return e(t,r,n,lu(o,!0))}function f2e(e){const t=e.footnoteById,n=e.footnoteOrder;let r=-1;const o=[];for(;++r<n.length;){const i=t[n[r].toUpperCase()];if(!i)continue;const a=String(r+1),s=[...i.children],l={type:"link",url:"#fnref"+a,data:{hProperties:{className:["footnote-back"],role:"doc-backlink"}},children:[{type:"text",value:"↩"}]},u=s[s.length-1];u&&u.type==="paragraph"?u.children.push(l):s.push(l),o.push({type:"listItem",data:{hProperties:{id:"fn"+a,role:"doc-endnote"}},children:s,position:i.position})}return o.length===0?null:e(null,"section",{className:["footnotes"],role:"doc-endnotes"},lu([kM(e),SM(e,{type:"list",ordered:!0,children:o})],!0))}function d2e(e,t){return e(t,"blockquote",lu(Do(e,t),!0))}function h2e(e,t){return[e(t,"br"),Mr("text",` `)]}function p2e(e,t){const n=t.value?t.value+` `:"",r=t.lang&&t.lang.match(/^[^ \t]+(?=[ \t]|$)/),o={};r&&(o.className=["language-"+r]);const i=e(t,"code",o,[Mr("text",n)]);return t.meta&&(i.data={meta:t.meta}),e(t.position,"pre",[i])}function m2e(e,t){return e(t,"del",Do(e,t))}function g2e(e,t){return e(t,"em",Do(e,t))}function xM(e,t){const n=e.footnoteOrder,r=String(t.identifier),o=n.indexOf(r),i=String(o===-1?n.push(r):o+1);return e(t,"a",{href:"#fn"+i,className:["footnote-ref"],id:"fnref"+i,role:"doc-noteref"},[e(t.position,"sup",[Mr("text",i)])])}function v2e(e,t){const n=e.footnoteById,r=e.footnoteOrder;let o=1;for(;o in n;)o++;const i=String(o);return r.push(i),n[i]={type:"footnoteDefinition",identifier:i,children:[{type:"paragraph",children:t.children}],position:t.position},xM(e,{type:"footnoteReference",identifier:i,position:t.position})}function b2e(e,t){return e(t,"h"+t.depth,Do(e,t))}function y2e(e,t){return e.dangerous?e.augment(t,Mr("raw",t.value)):null}var aA={};function E2e(e){var t,n,r=aA[e];if(r)return r;for(r=aA[e]=[],t=0;t<128;t++)n=String.fromCharCode(t),/^[0-9a-z]$/i.test(n)?r.push(n):r.push("%"+("0"+t.toString(16).toUpperCase()).slice(-2));for(t=0;t<e.length;t++)r[e.charCodeAt(t)]=e[t];return r}function xy(e,t,n){var r,o,i,a,s,l="";for(typeof t!="string"&&(n=t,t=xy.defaultChars),typeof n>"u"&&(n=!0),s=E2e(t),r=0,o=e.length;r<o;r++){if(i=e.charCodeAt(r),n&&i===37&&r+2<o&&/^[0-9a-f]{2}$/i.test(e.slice(r+1,r+3))){l+=e.slice(r,r+3),r+=2;continue}if(i<128){l+=s[i];continue}if(i>=55296&&i<=57343){if(i>=55296&&i<=56319&&r+1<o&&(a=e.charCodeAt(r+1),a>=56320&&a<=57343)){l+=encodeURIComponent(e[r]+e[r+1]),r++;continue}l+="%EF%BF%BD";continue}l+=encodeURIComponent(e[r])}return l}xy.defaultChars=";/?:@&=+$,-_.!~*'()#";xy.componentChars="-_.!~*'()";var _2e=xy;const Cy=xr(_2e);function CM(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return Mr("text","!["+t.alt+r);const o=Do(e,t),i=o[0];i&&i.type==="text"?i.value="["+i.value:o.unshift(Mr("text","["));const a=o[o.length-1];return a&&a.type==="text"?a.value+=r:o.push(Mr("text",r)),o}function T2e(e,t){const n=e.definition(t.identifier);if(!n)return CM(e,t);const r={src:Cy(n.url||""),alt:t.alt};return n.title!==null&&n.title!==void 0&&(r.title=n.title),e(t,"img",r)}function w2e(e,t){const n={src:Cy(t.url),alt:t.alt};return t.title!==null&&t.title!==void 0&&(n.title=t.title),e(t,"img",n)}function k2e(e,t){return e(t,"code",[Mr("text",t.value.replace(/\r?\n|\r/g," "))])}function S2e(e,t){const n=e.definition(t.identifier);if(!n)return CM(e,t);const r={href:Cy(n.url||"")};return n.title!==null&&n.title!==void 0&&(r.title=n.title),e(t,"a",r,Do(e,t))}function x2e(e,t){const n={href:Cy(t.url)};return t.title!==null&&t.title!==void 0&&(n.title=t.title),e(t,"a",n,Do(e,t))}function C2e(e,t,n){const r=Do(e,t),o=n?A2e(n):AM(t),i={},a=[];if(typeof t.checked=="boolean"){let u;r[0]&&r[0].type==="element"&&r[0].tagName==="p"?u=r[0]:(u=e(null,"p",[]),r.unshift(u)),u.children.length>0&&u.children.unshift(Mr("text"," ")),u.children.unshift(e(null,"input",{type:"checkbox",checked:t.checked,disabled:!0})),i.className=["task-list-item"]}let s=-1;for(;++s<r.length;){const u=r[s];(o||s!==0||u.type!=="element"||u.tagName!=="p")&&a.push(Mr("text",` `)),u.type==="element"&&u.tagName==="p"&&!o?a.push(...u.children):a.push(u)}const l=r[r.length-1];return l&&(o||!("tagName"in l)||l.tagName!=="p")&&a.push(Mr("text",` `)),e(t,"li",i,a)}function A2e(e){let t=e.spread;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=AM(n[r]);return!!t}function AM(e){const t=e.spread;return t??e.children.length>1}function N2e(e,t){return e(t,"p",Do(e,t))}function F2e(e,t){return e.augment(t,Mr("root",lu(Do(e,t))))}function I2e(e,t){return e(t,"strong",Do(e,t))}function B2e(e,t){const n=t.children;let r=-1;const o=t.align||[],i=[];for(;++r<n.length;){const a=n[r].children,s=r===0?"th":"td";let l=t.align?o.length:a.length;const u=[];for(;l--;){const d=a[l];u[l]=e(d,s,{align:o[l]},d?Do(e,d):[])}i[r]=e(n[r],"tr",lu(u,!0))}return e(t,"table",lu([e(i[0].position,"thead",lu([i[0]],!0))].concat(i[1]?e({start:Sy(i[1]),end:Bw(i[i.length-1])},"tbody",lu(i.slice(1),!0)):[]),!0))}function R2e(e,t){return e.augment(t,Mr("text",String(t.value).replace(/[ \t]*(\r?\n|\r)[ \t]*/g,"$1")))}const O2e={blockquote:d2e,break:h2e,code:p2e,delete:m2e,emphasis:g2e,footnoteReference:xM,footnote:v2e,heading:b2e,html:y2e,imageReference:T2e,image:w2e,inlineCode:k2e,linkReference:S2e,link:x2e,listItem:C2e,list:SM,paragraph:N2e,root:F2e,strong:I2e,table:B2e,text:R2e,thematicBreak:kM,toml:Ym,yaml:Ym,definition:Ym,footnoteDefinition:Ym};function Ym(){return null}const D2e={}.hasOwnProperty;function P2e(e,t){const n=t||{},r=n.allowDangerousHtml||!1,o={};return a.dangerous=r,a.definition=c2e(e),a.footnoteById=o,a.footnoteOrder=[],a.augment=i,a.handlers={...O2e,...n.handlers},a.unknownHandler=n.unknownHandler,a.passThrough=n.passThrough,Iw(e,"footnoteDefinition",s=>{const l=String(s.identifier).toUpperCase();D2e.call(o,l)||(o[l]=s)}),a;function i(s,l){if(s&&"data"in s&&s.data){const u=s.data;u.hName&&(l.type!=="element"&&(l={type:"element",tagName:"",properties:{},children:[]}),l.tagName=u.hName),l.type==="element"&&u.hProperties&&(l.properties={...l.properties,...u.hProperties}),"children"in l&&l.children&&u.hChildren&&(l.children=u.hChildren)}if(s){const u="type"in s?s:{position:s};o2e(u)||(l.position={start:Sy(u),end:Bw(u)})}return l}function a(s,l,u,d){return Array.isArray(u)&&(d=u,u={}),i(s,{type:"element",tagName:l,properties:u||{},children:d||[]})}}function NM(e,t){const n=P2e(e,t),r=TM(n,e,null),o=f2e(n);return o&&r.children.push(Mr("text",` `),o),Array.isArray(r)?{type:"root",children:r}:r}const M2e=function(e,t){return e&&"run"in e?j2e(e,t):z2e(e)},L2e=M2e;function j2e(e,t){return(n,r,o)=>{e.run(NM(n,t),r,i=>{o(i)})}}function z2e(e){return t=>NM(t,e)}var FM={exports:{}},H2e="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",U2e=H2e,q2e=U2e;function IM(){}function BM(){}BM.resetWarningCache=IM;var $2e=function(){function e(r,o,i,a,s,l){if(l!==q2e){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var n={array:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:BM,resetWarningCache:IM};return n.PropTypes=n,n};FM.exports=$2e();var W2e=FM.exports;const Ot=xr(W2e);class vp{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}vp.prototype.property={};vp.prototype.normal={};vp.prototype.space=null;function RM(e,t){for(var n={},r={},o=-1;++o<e.length;)Object.assign(n,e[o].property),Object.assign(r,e[o].normal);return new vp(n,r,t)}function j0(e){return e.toLowerCase()}class ti{constructor(t,n){this.property=t,this.attribute=n}}ti.prototype.space=null;ti.prototype.attribute=null;ti.prototype.property=null;ti.prototype.boolean=!1;ti.prototype.booleanish=!1;ti.prototype.overloadedBoolean=!1;ti.prototype.number=!1;ti.prototype.commaSeparated=!1;ti.prototype.spaceSeparated=!1;ti.prototype.commaOrSpaceSeparated=!1;ti.prototype.mustUseProperty=!1;ti.prototype.defined=!1;var G2e=0,wt=Vc(),pr=Vc(),OM=Vc(),Ce=Vc(),Cn=Vc(),uu=Vc(),hi=Vc();function Vc(){return 2**++G2e}const a4=Object.freeze(Object.defineProperty({__proto__:null,boolean:wt,booleanish:pr,commaOrSpaceSeparated:hi,commaSeparated:uu,number:Ce,overloadedBoolean:OM,spaceSeparated:Cn},Symbol.toStringTag,{value:"Module"}));var Qm=Object.keys(a4);class Rw extends ti{constructor(t,n,r,o){var i=-1;for(super(t,n),sA(this,"space",o);++i<Qm.length;)sA(this,Qm[i],(r&a4[Qm[i]])===a4[Qm[i]])}}Rw.prototype.defined=!0;function sA(e,t,n){n&&(e[t]=n)}var K2e={}.hasOwnProperty;function p1(e){var t={},n={},r,o;for(r in e.properties)K2e.call(e.properties,r)&&(o=new Rw(r,e.transform(e.attributes,r),e.properties[r],e.space),e.mustUseProperty&&e.mustUseProperty.includes(r)&&(o.mustUseProperty=!0),t[r]=o,n[j0(r)]=r,n[j0(o.attribute)]=r);return new vp(t,n,e.space)}var DM=p1({space:"xlink",transform:V2e,properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}});function V2e(e,t){return"xlink:"+t.slice(5).toLowerCase()}var PM=p1({space:"xml",transform:Y2e,properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function Y2e(e,t){return"xml:"+t.slice(3).toLowerCase()}function MM(e,t){return t in e?e[t]:t}function LM(e,t){return MM(e,t.toLowerCase())}var jM=p1({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:LM,properties:{xmlns:null,xmlnsXLink:null}}),zM=p1({transform:Q2e,properties:{ariaActiveDescendant:null,ariaAtomic:pr,ariaAutoComplete:null,ariaBusy:pr,ariaChecked:pr,ariaColCount:Ce,ariaColIndex:Ce,ariaColSpan:Ce,ariaControls:Cn,ariaCurrent:null,ariaDescribedBy:Cn,ariaDetails:null,ariaDisabled:pr,ariaDropEffect:Cn,ariaErrorMessage:null,ariaExpanded:pr,ariaFlowTo:Cn,ariaGrabbed:pr,ariaHasPopup:null,ariaHidden:pr,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:Cn,ariaLevel:Ce,ariaLive:null,ariaModal:pr,ariaMultiLine:pr,ariaMultiSelectable:pr,ariaOrientation:null,ariaOwns:Cn,ariaPlaceholder:null,ariaPosInSet:Ce,ariaPressed:pr,ariaReadOnly:pr,ariaRelevant:null,ariaRequired:pr,ariaRoleDescription:Cn,ariaRowCount:Ce,ariaRowIndex:Ce,ariaRowSpan:Ce,ariaSelected:pr,ariaSetSize:Ce,ariaSort:null,ariaValueMax:Ce,ariaValueMin:Ce,ariaValueNow:Ce,ariaValueText:null,role:null}});function Q2e(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}var X2e=p1({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:LM,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:uu,acceptCharset:Cn,accessKey:Cn,action:null,allow:null,allowFullScreen:wt,allowPaymentRequest:wt,allowUserMedia:wt,alt:null,as:null,async:wt,autoCapitalize:null,autoComplete:Cn,autoFocus:wt,autoPlay:wt,capture:wt,charSet:null,checked:wt,cite:null,className:Cn,cols:Ce,colSpan:null,content:null,contentEditable:pr,controls:wt,controlsList:Cn,coords:Ce|uu,crossOrigin:null,data:null,dateTime:null,decoding:null,default:wt,defer:wt,dir:null,dirName:null,disabled:wt,download:OM,draggable:pr,encType:null,enterKeyHint:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:wt,formTarget:null,headers:Cn,height:Ce,hidden:wt,high:Ce,href:null,hrefLang:null,htmlFor:Cn,httpEquiv:Cn,id:null,imageSizes:null,imageSrcSet:uu,inputMode:null,integrity:null,is:null,isMap:wt,itemId:null,itemProp:Cn,itemRef:Cn,itemScope:wt,itemType:Cn,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:wt,low:Ce,manifest:null,max:null,maxLength:Ce,media:null,method:null,min:null,minLength:Ce,multiple:wt,muted:wt,name:null,nonce:null,noModule:wt,noValidate:wt,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforePrint:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextMenu:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:wt,optimum:Ce,pattern:null,ping:Cn,placeholder:null,playsInline:wt,poster:null,preload:null,readOnly:wt,referrerPolicy:null,rel:Cn,required:wt,reversed:wt,rows:Ce,rowSpan:Ce,sandbox:Cn,scope:null,scoped:wt,seamless:wt,selected:wt,shape:null,size:Ce,sizes:null,slot:null,span:Ce,spellCheck:pr,src:null,srcDoc:null,srcLang:null,srcSet:uu,start:Ce,step:null,style:null,tabIndex:Ce,target:null,title:null,translate:null,type:null,typeMustMatch:wt,useMap:null,value:pr,width:Ce,wrap:null,align:null,aLink:null,archive:Cn,axis:null,background:null,bgColor:null,border:Ce,borderColor:null,bottomMargin:Ce,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:wt,declare:wt,event:null,face:null,frame:null,frameBorder:null,hSpace:Ce,leftMargin:Ce,link:null,longDesc:null,lowSrc:null,marginHeight:Ce,marginWidth:Ce,noResize:wt,noHref:wt,noShade:wt,noWrap:wt,object:null,profile:null,prompt:null,rev:null,rightMargin:Ce,rules:null,scheme:null,scrolling:pr,standby:null,summary:null,text:null,topMargin:Ce,valueType:null,version:null,vAlign:null,vLink:null,vSpace:Ce,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:wt,disableRemotePlayback:wt,prefix:null,property:null,results:Ce,security:null,unselectable:null}}),Z2e=p1({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:MM,properties:{about:hi,accentHeight:Ce,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:Ce,amplitude:Ce,arabicForm:null,ascent:Ce,attributeName:null,attributeType:null,azimuth:Ce,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:Ce,by:null,calcMode:null,capHeight:Ce,className:Cn,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:Ce,diffuseConstant:Ce,direction:null,display:null,dur:null,divisor:Ce,dominantBaseline:null,download:wt,dx:null,dy:null,edgeMode:null,editable:null,elevation:Ce,enableBackground:null,end:null,event:null,exponent:Ce,externalResourcesRequired:null,fill:null,fillOpacity:Ce,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:uu,g2:uu,glyphName:uu,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:Ce,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:Ce,horizOriginX:Ce,horizOriginY:Ce,id:null,ideographic:Ce,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:Ce,k:Ce,k1:Ce,k2:Ce,k3:Ce,k4:Ce,kernelMatrix:hi,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:Ce,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:Ce,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:Ce,overlineThickness:Ce,paintOrder:null,panose1:null,path:null,pathLength:Ce,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:Cn,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:Ce,pointsAtY:Ce,pointsAtZ:Ce,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:hi,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:hi,rev:hi,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:hi,requiredFeatures:hi,requiredFonts:hi,requiredFormats:hi,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:Ce,specularExponent:Ce,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:Ce,strikethroughThickness:Ce,string:null,stroke:null,strokeDashArray:hi,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:Ce,strokeOpacity:Ce,strokeWidth:null,style:null,surfaceScale:Ce,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:hi,tabIndex:Ce,tableValues:null,target:null,targetX:Ce,targetY:Ce,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:hi,to:null,transform:null,u1:null,u2:null,underlinePosition:Ce,underlineThickness:Ce,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:Ce,values:null,vAlphabetic:Ce,vMathematical:Ce,vectorEffect:null,vHanging:Ce,vIdeographic:Ce,version:null,vertAdvY:Ce,vertOriginX:Ce,vertOriginY:Ce,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:Ce,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),J2e=/^data[-\w.:]+$/i,HM=/-[a-z]/g,e9e=/[A-Z]/g;function bp(e,t){var n=j0(t),r=t,o=ti;return n in e.normal?e.property[e.normal[n]]:(n.length>4&&n.slice(0,4)==="data"&&J2e.test(t)&&(t.charAt(4)==="-"?r=t9e(t):t=n9e(t),o=Rw),new o(r,t))}function t9e(e){var t=e.slice(5).replace(HM,o9e);return"data"+t.charAt(0).toUpperCase()+t.slice(1)}function n9e(e){var t=e.slice(4);return HM.test(t)?e:(t=t.replace(e9e,r9e),t.charAt(0)!=="-"&&(t="-"+t),"data"+t)}function r9e(e){return"-"+e.toLowerCase()}function o9e(e){return e.charAt(1).toUpperCase()}var s4={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},m1=RM([PM,DM,jM,zM,X2e],"html"),Mu=RM([PM,DM,jM,zM,Z2e],"svg");function i9e(e){if(e.allowedElements&&e.disallowedElements)throw new TypeError("Only one of `allowedElements` and `disallowedElements` should be defined");if(e.allowedElements||e.disallowedElements||e.allowElement)return t=>{Iw(t,"element",(n,r,o)=>{const i=o;let a;if(e.allowedElements?a=!e.allowedElements.includes(n.tagName):e.disallowedElements&&(a=e.disallowedElements.includes(n.tagName)),!a&&e.allowElement&&typeof r=="number"&&(a=!e.allowElement(n,r,i)),a&&typeof r=="number")return e.unwrapDisallowed&&n.children?i.children.splice(r,1,...n.children):i.children.splice(r,1),r})}}var UM={exports:{}},hn={};/** @license React v17.0.2 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var Ay=60103,Ny=60106,yp=60107,Ep=60108,_p=60114,Tp=60109,wp=60110,kp=60112,Sp=60113,Ow=60120,xp=60115,Cp=60116,qM=60121,$M=60122,WM=60117,GM=60129,KM=60131;if(typeof Symbol=="function"&&Symbol.for){var $r=Symbol.for;Ay=$r("react.element"),Ny=$r("react.portal"),yp=$r("react.fragment"),Ep=$r("react.strict_mode"),_p=$r("react.profiler"),Tp=$r("react.provider"),wp=$r("react.context"),kp=$r("react.forward_ref"),Sp=$r("react.suspense"),Ow=$r("react.suspense_list"),xp=$r("react.memo"),Cp=$r("react.lazy"),qM=$r("react.block"),$M=$r("react.server.block"),WM=$r("react.fundamental"),GM=$r("react.debug_trace_mode"),KM=$r("react.legacy_hidden")}function Aa(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case Ay:switch(e=e.type,e){case yp:case _p:case Ep:case Sp:case Ow:return e;default:switch(e=e&&e.$$typeof,e){case wp:case kp:case Cp:case xp:case Tp:return e;default:return t}}case Ny:return t}}}var a9e=Tp,s9e=Ay,l9e=kp,u9e=yp,c9e=Cp,f9e=xp,d9e=Ny,h9e=_p,p9e=Ep,m9e=Sp;hn.ContextConsumer=wp;hn.ContextProvider=a9e;hn.Element=s9e;hn.ForwardRef=l9e;hn.Fragment=u9e;hn.Lazy=c9e;hn.Memo=f9e;hn.Portal=d9e;hn.Profiler=h9e;hn.StrictMode=p9e;hn.Suspense=m9e;hn.isAsyncMode=function(){return!1};hn.isConcurrentMode=function(){return!1};hn.isContextConsumer=function(e){return Aa(e)===wp};hn.isContextProvider=function(e){return Aa(e)===Tp};hn.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===Ay};hn.isForwardRef=function(e){return Aa(e)===kp};hn.isFragment=function(e){return Aa(e)===yp};hn.isLazy=function(e){return Aa(e)===Cp};hn.isMemo=function(e){return Aa(e)===xp};hn.isPortal=function(e){return Aa(e)===Ny};hn.isProfiler=function(e){return Aa(e)===_p};hn.isStrictMode=function(e){return Aa(e)===Ep};hn.isSuspense=function(e){return Aa(e)===Sp};hn.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===yp||e===_p||e===GM||e===Ep||e===Sp||e===Ow||e===KM||typeof e=="object"&&e!==null&&(e.$$typeof===Cp||e.$$typeof===xp||e.$$typeof===Tp||e.$$typeof===wp||e.$$typeof===kp||e.$$typeof===WM||e.$$typeof===qM||e[0]===$M)};hn.typeOf=Aa;UM.exports=hn;var g9e=UM.exports;const v9e=xr(g9e);function b9e(e){var t=e&&typeof e=="object"&&e.type==="text"?e.value||"":e;return typeof t=="string"&&t.replace(/[ \t\n\f\r]/g,"")===""}function lA(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function VM(e){return e.join(" ").trim()}function uA(e){for(var t=[],n=String(e||""),r=n.indexOf(","),o=0,i,a;!i;)r===-1&&(r=n.length,i=!0),a=n.slice(o,r).trim(),(a||!i)&&t.push(a),o=r+1,r=n.indexOf(",",o);return t}function YM(e,t){var n=t||{};return e[e.length-1]===""&&(e=e.concat("")),e.join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}var cA=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,y9e=/\n/g,E9e=/^\s*/,_9e=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,T9e=/^:\s*/,w9e=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,k9e=/^[;\s]*/,S9e=/^\s+|\s+$/g,x9e=` `,fA="/",dA="*",vc="",C9e="comment",A9e="declaration",N9e=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function o(v){var _=v.match(y9e);_&&(n+=_.length);var b=v.lastIndexOf(x9e);r=~b?v.length-b:r+v.length}function i(){var v={line:n,column:r};return function(_){return _.position=new a(v),u(),_}}function a(v){this.start=v,this.end={line:n,column:r},this.source=t.source}a.prototype.content=e;function s(v){var _=new Error(t.source+":"+n+":"+r+": "+v);if(_.reason=v,_.filename=t.source,_.line=n,_.column=r,_.source=e,!t.silent)throw _}function l(v){var _=v.exec(e);if(_){var b=_[0];return o(b),e=e.slice(b.length),_}}function u(){l(E9e)}function d(v){var _;for(v=v||[];_=h();)_!==!1&&v.push(_);return v}function h(){var v=i();if(!(fA!=e.charAt(0)||dA!=e.charAt(1))){for(var _=2;vc!=e.charAt(_)&&(dA!=e.charAt(_)||fA!=e.charAt(_+1));)++_;if(_+=2,vc===e.charAt(_-1))return s("End of comment missing");var b=e.slice(2,_-2);return r+=2,o(b),e=e.slice(_),r+=2,v({type:C9e,comment:b})}}function p(){var v=i(),_=l(_9e);if(_){if(h(),!l(T9e))return s("property missing ':'");var b=l(w9e),E=v({type:A9e,property:hA(_[0].replace(cA,vc)),value:b?hA(b[0].replace(cA,vc)):vc});return l(k9e),E}}function m(){var v=[];d(v);for(var _;_=p();)_!==!1&&(v.push(_),d(v));return v}return u(),m()};function hA(e){return e?e.replace(S9e,vc):vc}var F9e=N9e;function I9e(e,t){var n=null;if(!e||typeof e!="string")return n;for(var r,o=F9e(e),i=typeof t=="function",a,s,l=0,u=o.length;l<u;l++)r=o[l],a=r.property,s=r.value,i?t(a,s,r):s&&(n||(n={}),n[a]=s);return n}var B9e=I9e;const QM=xr(B9e),l4={}.hasOwnProperty,R9e=new Set(["table","thead","tbody","tfoot","tr"]);function XM(e,t){const n=[];let r=-1,o;for(;++r<t.children.length;)o=t.children[r],o.type==="element"?n.push(O9e(e,o,r,t)):o.type==="text"?(t.type!=="element"||!R9e.has(t.tagName)||!b9e(o))&&n.push(o.value):o.type==="raw"&&!e.options.skipHtml&&n.push(o.value);return n}function O9e(e,t,n,r){const o=e.options,i=e.schema,a=t.tagName,s={};let l=i,u;if(i.space==="html"&&a==="svg"&&(l=Mu,e.schema=l),t.properties)for(u in t.properties)l4.call(t.properties,u)&&P9e(s,u,t.properties[u],e);(a==="ol"||a==="ul")&&e.listDepth++;const d=XM(e,t);(a==="ol"||a==="ul")&&e.listDepth--,e.schema=i;const h=t.position||{start:{line:null,column:null,offset:null},end:{line:null,column:null,offset:null}},p=o.components&&l4.call(o.components,a)?o.components[a]:a,m=typeof p=="string"||p===Bt.Fragment;if(!v9e.isValidElementType(p))throw new TypeError(`Component for name \`${a}\` not defined or is not renderable`);if(s.key=[a,h.start.line,h.start.column,n].join("-"),a==="a"&&o.linkTarget&&(s.target=typeof o.linkTarget=="function"?o.linkTarget(String(s.href||""),t.children,typeof s.title=="string"?s.title:null):o.linkTarget),a==="a"&&o.transformLinkUri&&(s.href=o.transformLinkUri(String(s.href||""),t.children,typeof s.title=="string"?s.title:null)),!m&&a==="code"&&r.type==="element"&&r.tagName!=="pre"&&(s.inline=!0),!m&&(a==="h1"||a==="h2"||a==="h3"||a==="h4"||a==="h5"||a==="h6")&&(s.level=Number.parseInt(a.charAt(1),10)),a==="img"&&o.transformImageUri&&(s.src=o.transformImageUri(String(s.src||""),String(s.alt||""),typeof s.title=="string"?s.title:null)),!m&&a==="li"&&r.type==="element"){const v=D9e(t);s.checked=v&&v.properties?!!v.properties.checked:null,s.index=$9(r,t),s.ordered=r.tagName==="ol"}return!m&&(a==="ol"||a==="ul")&&(s.ordered=a==="ol",s.depth=e.listDepth),(a==="td"||a==="th")&&(s.align&&(s.style||(s.style={}),s.style.textAlign=s.align,delete s.align),m||(s.isHeader=a==="th")),!m&&a==="tr"&&r.type==="element"&&(s.isHeader=r.tagName==="thead"),o.sourcePos&&(s["data-sourcepos"]=j9e(h)),!m&&o.rawSourcePos&&(s.sourcePosition=t.position),!m&&o.includeElementIndex&&(s.index=$9(r,t),s.siblingCount=$9(r)),m||(s.node=t),d.length>0?Bt.createElement(p,s,d):Bt.createElement(p,s)}function D9e(e){let t=-1;for(;++t<e.children.length;){const n=e.children[t];if(n.type==="element"&&n.tagName==="input")return n}return null}function $9(e,t){let n=-1,r=0;for(;++n<e.children.length&&e.children[n]!==t;)e.children[n].type==="element"&&r++;return r}function P9e(e,t,n,r){const o=bp(r.schema,t);let i=n;i==null||i!==i||(Array.isArray(i)&&(i=o.commaSeparated?YM(i):VM(i)),o.property==="style"&&typeof i=="string"&&(i=M9e(i)),o.space&&o.property?e[l4.call(s4,o.property)?s4[o.property]:o.property]=i:o.attribute&&(e[o.attribute]=i))}function M9e(e){const t={};try{QM(e,n)}catch{}return t;function n(r,o){const i=r.slice(0,4)==="-ms-"?`ms-${r.slice(4)}`:r;t[i.replace(/-([a-z])/g,L9e)]=o}}function L9e(e,t){return t.toUpperCase()}function j9e(e){return[e.start.line,":",e.start.column,"-",e.end.line,":",e.end.column].map(t=>String(t)).join("")}const pA={}.hasOwnProperty,z9e="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",Xm={renderers:{to:"components",id:"change-renderers-to-components"},astPlugins:{id:"remove-buggy-html-in-markdown-parser"},allowDangerousHtml:{id:"remove-buggy-html-in-markdown-parser"},escapeHtml:{id:"remove-buggy-html-in-markdown-parser"},source:{to:"children",id:"change-source-to-children"},allowNode:{to:"allowElement",id:"replace-allownode-allowedtypes-and-disallowedtypes"},allowedTypes:{to:"allowedElements",id:"replace-allownode-allowedtypes-and-disallowedtypes"},disallowedTypes:{to:"disallowedElements",id:"replace-allownode-allowedtypes-and-disallowedtypes"},includeNodeIndex:{to:"includeElementIndex",id:"change-includenodeindex-to-includeelementindex"}};function Dw(e){for(const i in Xm)if(pA.call(Xm,i)&&pA.call(e,i)){const a=Xm[i];console.warn(`[react-markdown] Warning: please ${a.to?`use \`${a.to}\` instead of`:"remove"} \`${i}\` (see <${z9e}#${a.id}> for more info)`),delete Xm[i]}const t=$be().use(K5e).use(e.remarkPlugins||e.plugins||[]).use(L2e,{allowDangerousHtml:!0}).use(e.rehypePlugins||[]).use(i9e,e),n=new aM;typeof e.children=="string"?n.value=e.children:e.children!==void 0&&e.children!==null&&console.warn(`[react-markdown] Warning: please pass a string as \`children\` (not: \`${e.children}\`)`);const r=t.runSync(t.parse(n),n);if(r.type!=="root")throw new TypeError("Expected a `root` node");let o=Bt.createElement(Bt.Fragment,{},XM({options:e,schema:m1,listDepth:0},r));return e.className&&(o=Bt.createElement("div",{className:e.className},o)),o}Dw.defaultProps={transformLinkUri:Sbe};Dw.propTypes={children:Ot.string,className:Ot.string,allowElement:Ot.func,allowedElements:Ot.arrayOf(Ot.string),disallowedElements:Ot.arrayOf(Ot.string),unwrapDisallowed:Ot.bool,remarkPlugins:Ot.arrayOf(Ot.oneOfType([Ot.object,Ot.func,Ot.arrayOf(Ot.oneOfType([Ot.object,Ot.func]))])),rehypePlugins:Ot.arrayOf(Ot.oneOfType([Ot.object,Ot.func,Ot.arrayOf(Ot.oneOfType([Ot.object,Ot.func]))])),sourcePos:Ot.bool,rawSourcePos:Ot.bool,skipHtml:Ot.bool,includeElementIndex:Ot.bool,transformLinkUri:Ot.oneOfType([Ot.func,Ot.bool]),linkTarget:Ot.oneOfType([Ot.func,Ot.string]),transformImageUri:Ot.func,components:Ot.object};function H9e(e,t){if(e==null)return{};var n={},r=Object.keys(e),o,i;for(i=0;i<r.length;i++)o=r[i],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}var U9e=H9e,q9e=U9e;function $9e(e,t){if(e==null)return{};var n=q9e(e,t),r,o;if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(o=0;o<i.length;o++)r=i[o],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}var W9e=$9e;const G9e=xr(W9e);function K9e(e){if(Array.isArray(e)){for(var t=0,n=new Array(e.length);t<e.length;t++)n[t]=e[t];return n}}var V9e=K9e;function Y9e(e){if(Symbol.iterator in Object(e)||Object.prototype.toString.call(e)==="[object Arguments]")return Array.from(e)}var Q9e=Y9e;function X9e(){throw new TypeError("Invalid attempt to spread non-iterable instance")}var Z9e=X9e,J9e=V9e,eEe=Q9e,tEe=Z9e;function nEe(e){return J9e(e)||eEe(e)||tEe()}var rEe=nEe;const oEe=xr(rEe);function iEe(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var aEe=iEe;const ZM=xr(aEe);function u4(){return JM=u4=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},u4.apply(this,arguments)}var JM=u4;const sEe=xr(JM);function mA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function sd(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?mA(Object(n),!0).forEach(function(r){ZM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):mA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}function lEe(e){var t=e.length;if(t===0||t===1)return e;if(t===2)return[e[0],e[1],"".concat(e[0],".").concat(e[1]),"".concat(e[1],".").concat(e[0])];if(t===3)return[e[0],e[1],e[2],"".concat(e[0],".").concat(e[1]),"".concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[0]),"".concat(e[1],".").concat(e[2]),"".concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[1],".").concat(e[0])];if(t>=4)return[e[0],e[1],e[2],e[3],"".concat(e[0],".").concat(e[1]),"".concat(e[0],".").concat(e[2]),"".concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[0]),"".concat(e[1],".").concat(e[2]),"".concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[1]),"".concat(e[2],".").concat(e[3]),"".concat(e[3],".").concat(e[0]),"".concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[0]),"".concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[0],".").concat(e[1],".").concat(e[2],".").concat(e[3]),"".concat(e[0],".").concat(e[1],".").concat(e[3],".").concat(e[2]),"".concat(e[0],".").concat(e[2],".").concat(e[1],".").concat(e[3]),"".concat(e[0],".").concat(e[2],".").concat(e[3],".").concat(e[1]),"".concat(e[0],".").concat(e[3],".").concat(e[1],".").concat(e[2]),"".concat(e[0],".").concat(e[3],".").concat(e[2],".").concat(e[1]),"".concat(e[1],".").concat(e[0],".").concat(e[2],".").concat(e[3]),"".concat(e[1],".").concat(e[0],".").concat(e[3],".").concat(e[2]),"".concat(e[1],".").concat(e[2],".").concat(e[0],".").concat(e[3]),"".concat(e[1],".").concat(e[2],".").concat(e[3],".").concat(e[0]),"".concat(e[1],".").concat(e[3],".").concat(e[0],".").concat(e[2]),"".concat(e[1],".").concat(e[3],".").concat(e[2],".").concat(e[0]),"".concat(e[2],".").concat(e[0],".").concat(e[1],".").concat(e[3]),"".concat(e[2],".").concat(e[0],".").concat(e[3],".").concat(e[1]),"".concat(e[2],".").concat(e[1],".").concat(e[0],".").concat(e[3]),"".concat(e[2],".").concat(e[1],".").concat(e[3],".").concat(e[0]),"".concat(e[2],".").concat(e[3],".").concat(e[0],".").concat(e[1]),"".concat(e[2],".").concat(e[3],".").concat(e[1],".").concat(e[0]),"".concat(e[3],".").concat(e[0],".").concat(e[1],".").concat(e[2]),"".concat(e[3],".").concat(e[0],".").concat(e[2],".").concat(e[1]),"".concat(e[3],".").concat(e[1],".").concat(e[0],".").concat(e[2]),"".concat(e[3],".").concat(e[1],".").concat(e[2],".").concat(e[0]),"".concat(e[3],".").concat(e[2],".").concat(e[0],".").concat(e[1]),"".concat(e[3],".").concat(e[2],".").concat(e[1],".").concat(e[0])]}var W9={};function uEe(e){if(e.length===0||e.length===1)return e;var t=e.join(".");return W9[t]||(W9[t]=lEe(e)),W9[t]}function cEe(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0,r=e.filter(function(i){return i!=="token"}),o=uEe(r);return o.reduce(function(i,a){return sd(sd({},i),n[a])},t)}function gA(e){return e.join(" ")}function fEe(e,t){var n=0;return function(r){return n+=1,r.map(function(o,i){return eL({node:o,stylesheet:e,useInlineStyles:t,key:"code-segment-".concat(n,"-").concat(i)})})}}function eL(e){var t=e.node,n=e.stylesheet,r=e.style,o=r===void 0?{}:r,i=e.useInlineStyles,a=e.key,s=t.properties,l=t.type,u=t.tagName,d=t.value;if(l==="text")return d;if(u){var h=fEe(n,i),p;if(!i)p=sd(sd({},s),{},{className:gA(s.className)});else{var m=Object.keys(n).reduce(function(E,w){return w.split(".").forEach(function(k){E.includes(k)||E.push(k)}),E},[]),v=s.className&&s.className.includes("token")?["token"]:[],_=s.className&&v.concat(s.className.filter(function(E){return!m.includes(E)}));p=sd(sd({},s),{},{className:gA(_)||void 0,style:cEe(s.className,Object.assign({},s.style,o),n)})}var b=h(t.children);return Bt.createElement(u,sEe({key:a},p),b)}}const dEe=function(e,t){var n=e.listLanguages();return n.indexOf(t)!==-1};var hEe=["language","children","style","customStyle","codeTagProps","useInlineStyles","showLineNumbers","showInlineLineNumbers","startingLineNumber","lineNumberContainerStyle","lineNumberStyle","wrapLines","wrapLongLines","lineProps","renderer","PreTag","CodeTag","code","astGenerator"];function vA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,r)}return n}function Wa(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?vA(Object(n),!0).forEach(function(r){ZM(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):vA(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var pEe=/\n/g;function mEe(e){return e.match(pEe)}function gEe(e){var t=e.lines,n=e.startingLineNumber,r=e.style;return t.map(function(o,i){var a=i+n;return Bt.createElement("span",{key:"line-".concat(i),className:"react-syntax-highlighter-line-number",style:typeof r=="function"?r(a):r},"".concat(a,` `))})}function vEe(e){var t=e.codeString,n=e.codeStyle,r=e.containerStyle,o=r===void 0?{float:"left",paddingRight:"10px"}:r,i=e.numberStyle,a=i===void 0?{}:i,s=e.startingLineNumber;return Bt.createElement("code",{style:Object.assign({},n,o)},gEe({lines:t.replace(/\n$/,"").split(` `),style:a,startingLineNumber:s}))}function bEe(e){return"".concat(e.toString().length,".25em")}function tL(e,t){return{type:"element",tagName:"span",properties:{key:"line-number--".concat(e),className:["comment","linenumber","react-syntax-highlighter-line-number"],style:t},children:[{type:"text",value:e}]}}function nL(e,t,n){var r={display:"inline-block",minWidth:bEe(n),paddingRight:"1em",textAlign:"right",userSelect:"none"},o=typeof e=="function"?e(t):e,i=Wa(Wa({},r),o);return i}function Zg(e){var t=e.children,n=e.lineNumber,r=e.lineNumberStyle,o=e.largestLineNumber,i=e.showInlineLineNumbers,a=e.lineProps,s=a===void 0?{}:a,l=e.className,u=l===void 0?[]:l,d=e.showLineNumbers,h=e.wrapLongLines,p=typeof s=="function"?s(n):s;if(p.className=u,n&&i){var m=nL(r,n,o);t.unshift(tL(n,m))}return h&d&&(p.style=Wa(Wa({},p.style),{},{display:"flex"})),{type:"element",tagName:"span",properties:p,children:t}}function c4(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];if(e.type==="root")return c4(e.children,t,n);for(var r=0;r<e.length;r++){var o=e[r];if(o.type==="text")n.push(Zg({children:[o],className:oEe(new Set(t))}));else if(o.children){var i=t.concat(o.properties.className);c4(o.children,i).forEach(function(a){return n.push(a)})}}return n}function yEe(e,t,n,r,o,i,a,s,l){var u,d=c4(e.value),h=[],p=-1,m=0;function v(F,C){var A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];return Zg({children:F,lineNumber:C,lineNumberStyle:s,largestLineNumber:a,showInlineLineNumbers:o,lineProps:n,className:A,showLineNumbers:r,wrapLongLines:l})}function _(F,C){if(r&&C&&o){var A=nL(s,C,a);F.unshift(tL(C,A))}return F}function b(F,C){var A=arguments.length>2&&arguments[2]!==void 0?arguments[2]:[];return t||A.length>0?v(F,C,A):_(F,C)}for(var E=function(){var C=d[m],A=C.children[0].value,P=mEe(A);if(P){var I=A.split(` `);I.forEach(function(j,H){var K=r&&h.length+i,U={type:"text",value:"".concat(j,` `)};if(H===0){var pe=d.slice(p+1,m).concat(Zg({children:[U],className:C.properties.className})),se=b(pe,K);h.push(se)}else if(H===I.length-1){var J=d[m+1]&&d[m+1].children&&d[m+1].children[0],$={type:"text",value:"".concat(j)};if(J){var _e=Zg({children:[$],className:C.properties.className});d.splice(m+1,0,_e)}else{var ve=[$],fe=b(ve,K,C.properties.className);h.push(fe)}}else{var R=[U],L=b(R,K,C.properties.className);h.push(L)}}),p=m}m++};m<d.length;)E();if(p!==d.length-1){var w=d.slice(p+1,d.length);if(w&&w.length){var k=r&&h.length+i,y=b(w,k);h.push(y)}}return t?h:(u=[]).concat.apply(u,h)}function EEe(e){var t=e.rows,n=e.stylesheet,r=e.useInlineStyles;return t.map(function(o,i){return eL({node:o,stylesheet:n,useInlineStyles:r,key:"code-segement".concat(i)})})}function rL(e){return e&&typeof e.highlightAuto<"u"}function _Ee(e){var t=e.astGenerator,n=e.language,r=e.code,o=e.defaultCodeValue;if(rL(t)){var i=dEe(t,n);return n==="text"?{value:o,language:"text"}:i?t.highlight(n,r):t.highlightAuto(r)}try{return n&&n!=="text"?{value:t.highlight(r,n)}:{value:o}}catch{return{value:o}}}function TEe(e,t){return function(r){var o=r.language,i=r.children,a=r.style,s=a===void 0?t:a,l=r.customStyle,u=l===void 0?{}:l,d=r.codeTagProps,h=d===void 0?{className:o?"language-".concat(o):void 0,style:Wa(Wa({},s['code[class*="language-"]']),s['code[class*="language-'.concat(o,'"]')])}:d,p=r.useInlineStyles,m=p===void 0?!0:p,v=r.showLineNumbers,_=v===void 0?!1:v,b=r.showInlineLineNumbers,E=b===void 0?!0:b,w=r.startingLineNumber,k=w===void 0?1:w,y=r.lineNumberContainerStyle,F=r.lineNumberStyle,C=F===void 0?{}:F,A=r.wrapLines,P=r.wrapLongLines,I=P===void 0?!1:P,j=r.lineProps,H=j===void 0?{}:j,K=r.renderer,U=r.PreTag,pe=U===void 0?"pre":U,se=r.CodeTag,J=se===void 0?"code":se,$=r.code,_e=$===void 0?(Array.isArray(i)?i[0]:i)||"":$,ve=r.astGenerator,fe=G9e(r,hEe);ve=ve||e;var R=_?Bt.createElement(vEe,{containerStyle:y,codeStyle:h.style||{},numberStyle:C,startingLineNumber:k,codeString:_e}):null,L=s.hljs||s['pre[class*="language-"]']||{backgroundColor:"#fff"},Ae=rL(ve)?"hljs":"prismjs",Ue=m?Object.assign({},fe,{style:Object.assign({},L,u)}):Object.assign({},fe,{className:fe.className?"".concat(Ae," ").concat(fe.className):Ae,style:Object.assign({},u)});if(I?h.style=Wa(Wa({},h.style),{},{whiteSpace:"pre-wrap"}):h.style=Wa(Wa({},h.style),{},{whiteSpace:"pre"}),!ve)return Bt.createElement(pe,Ue,R,Bt.createElement(J,h,_e));(A===void 0&&K||I)&&(A=!0),K=K||EEe;var Ve=[{type:"text",value:_e}],Le=_Ee({astGenerator:ve,language:o,code:_e,defaultCodeValue:Ve});Le.language===null&&(Le.value=Ve);var st=Le.value.length;st===1&&Le.value[0].type==="text"&&(st=Le.value[0].value.split(` `).length);var We=st+k,rt=yEe(Le,A,H,_,E,k,We,C,I);return Bt.createElement(pe,Ue,Bt.createElement(J,h,!E&&R,K({rows:rt,stylesheet:s,useInlineStyles:m})))}}const wEe=["abap","abnf","actionscript","ada","agda","al","antlr4","apacheconf","apex","apl","applescript","aql","arduino","arff","armasm","arturo","asciidoc","asm6502","asmatmel","aspnet","autohotkey","autoit","avisynth","avro-idl","awk","bash","basic","batch","bbcode","bbj","bicep","birb","bison","bnf","bqn","brainfuck","brightscript","bro","bsl","c","cfscript","chaiscript","cil","cilkc","cilkcpp","clike","clojure","cmake","cobol","coffeescript","concurnas","cooklang","coq","cpp","crystal","csharp","cshtml","csp","css-extras","css","csv","cue","cypher","d","dart","dataweave","dax","dhall","diff","django","dns-zone-file","docker","dot","ebnf","editorconfig","eiffel","ejs","elixir","elm","erb","erlang","etlua","excel-formula","factor","false","firestore-security-rules","flow","fortran","fsharp","ftl","gap","gcode","gdscript","gedcom","gettext","gherkin","git","glsl","gml","gn","go-module","go","gradle","graphql","groovy","haml","handlebars","haskell","haxe","hcl","hlsl","hoon","hpkp","hsts","http","ichigojam","icon","icu-message-format","idris","iecst","ignore","inform7","ini","io","j","java","javadoc","javadoclike","javascript","javastacktrace","jexl","jolie","jq","js-extras","js-templates","jsdoc","json","json5","jsonp","jsstacktrace","jsx","julia","keepalived","keyman","kotlin","kumir","kusto","latex","latte","less","lilypond","linker-script","liquid","lisp","livescript","llvm","log","lolcode","lua","magma","makefile","markdown","markup-templating","markup","mata","matlab","maxscript","mel","mermaid","metafont","mizar","mongodb","monkey","moonscript","n1ql","n4js","nand2tetris-hdl","naniscript","nasm","neon","nevod","nginx","nim","nix","nsis","objectivec","ocaml","odin","opencl","openqasm","oz","parigp","parser","pascal","pascaligo","pcaxis","peoplecode","perl","php-extras","php","phpdoc","plant-uml","plsql","powerquery","powershell","processing","prolog","promql","properties","protobuf","psl","pug","puppet","pure","purebasic","purescript","python","q","qml","qore","qsharp","r","racket","reason","regex","rego","renpy","rescript","rest","rip","roboconf","robotframework","ruby","rust","sas","sass","scala","scheme","scss","shell-session","smali","smalltalk","smarty","sml","solidity","solution-file","soy","sparql","splunk-spl","sqf","sql","squirrel","stan","stata","stylus","supercollider","swift","systemd","t4-cs","t4-templating","t4-vb","tap","tcl","textile","toml","tremor","tsx","tt2","turtle","twig","typescript","typoscript","unrealscript","uorazor","uri","v","vala","vbnet","velocity","verilog","vhdl","vim","visual-basic","warpscript","wasm","web-idl","wgsl","wiki","wolfram","wren","xeora","xml-doc","xojo","xquery","yaml","yang","zig"];var bA=/[#.]/g;const kEe=function(e,t="div"){for(var n=e||"",r={},o=0,i,a,s;o<n.length;)bA.lastIndex=o,s=bA.exec(n),i=n.slice(o,s?s.index:n.length),i&&(a?a==="#"?r.id=i:Array.isArray(r.className)?r.className.push(i):r.className=[i]:t=i,o+=i.length),s&&(a=s[0],o++);return{type:"element",tagName:t,properties:r,children:[]}},SEe=new Set(["menu","submit","reset","button"]),f4={}.hasOwnProperty;function oL(e,t,n){const r=n&&NEe(n);return function(i,a,...s){let l=-1,u;if(i==null)u={type:"root",children:[]},s.unshift(a);else if(u=kEe(i,t),u.tagName=u.tagName.toLowerCase(),r&&f4.call(r,u.tagName)&&(u.tagName=r[u.tagName]),xEe(a,u.tagName)){let d;for(d in a)f4.call(a,d)&&CEe(e,u.properties,d,a[d])}else s.unshift(a);for(;++l<s.length;)d4(u.children,s[l]);return u.type==="element"&&u.tagName==="template"&&(u.content={type:"root",children:u.children},u.children=[]),u}}function xEe(e,t){return e==null||typeof e!="object"||Array.isArray(e)?!1:t==="input"||!e.type||typeof e.type!="string"?!0:"children"in e&&Array.isArray(e.children)?!1:t==="button"?SEe.has(e.type.toLowerCase()):!("value"in e)}function CEe(e,t,n,r){const o=bp(e,n);let i=-1,a;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;a=r}else typeof r=="boolean"?a=r:typeof r=="string"?o.spaceSeparated?a=lA(r):o.commaSeparated?a=uA(r):o.commaOrSpaceSeparated?a=lA(uA(r).join(" ")):a=yA(o,o.property,r):Array.isArray(r)?a=r.concat():a=o.property==="style"?AEe(r):String(r);if(Array.isArray(a)){const s=[];for(;++i<a.length;)s[i]=yA(o,o.property,a[i]);a=s}o.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[o.property]=a}}function d4(e,t){let n=-1;if(t!=null)if(typeof t=="string"||typeof t=="number")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(;++n<t.length;)d4(e,t[n]);else if(typeof t=="object"&&"type"in t)t.type==="root"?d4(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function yA(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||j0(n)===j0(t)))return!0}return n}function AEe(e){const t=[];let n;for(n in e)f4.call(e,n)&&t.push([n,e[n]].join(": "));return t.join("; ")}function NEe(e){const t={};let n=-1;for(;++n<e.length;)t[e[n].toLowerCase()]=e[n];return t}const iL=oL(m1,"div"),FEe=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],IEe=oL(Mu,"g",FEe),BEe=["AElig","AMP","Aacute","Acirc","Agrave","Aring","Atilde","Auml","COPY","Ccedil","ETH","Eacute","Ecirc","Egrave","Euml","GT","Iacute","Icirc","Igrave","Iuml","LT","Ntilde","Oacute","Ocirc","Ograve","Oslash","Otilde","Ouml","QUOT","REG","THORN","Uacute","Ucirc","Ugrave","Uuml","Yacute","aacute","acirc","acute","aelig","agrave","amp","aring","atilde","auml","brvbar","ccedil","cedil","cent","copy","curren","deg","divide","eacute","ecirc","egrave","eth","euml","frac12","frac14","frac34","gt","iacute","icirc","iexcl","igrave","iquest","iuml","laquo","lt","macr","micro","middot","nbsp","not","ntilde","oacute","ocirc","ograve","ordf","ordm","oslash","otilde","ouml","para","plusmn","pound","quot","raquo","reg","sect","shy","sup1","sup2","sup3","szlig","thorn","times","uacute","ucirc","ugrave","uml","uuml","yacute","yen","yuml"],EA={0:"�",128:"€",130:"‚",131:"ƒ",132:"„",133:"…",134:"†",135:"‡",136:"ˆ",137:"‰",138:"Š",139:"‹",140:"Œ",142:"Ž",145:"‘",146:"’",147:"“",148:"”",149:"•",150:"–",151:"—",152:"˜",153:"™",154:"š",155:"›",156:"œ",158:"ž",159:"Ÿ"};function aL(e){const t=typeof e=="string"?e.charCodeAt(0):e;return t>=48&&t<=57}function REe(e){const t=typeof e=="string"?e.charCodeAt(0):e;return t>=97&&t<=102||t>=65&&t<=70||t>=48&&t<=57}function OEe(e){const t=typeof e=="string"?e.charCodeAt(0):e;return t>=97&&t<=122||t>=65&&t<=90}function _A(e){return OEe(e)||aL(e)}const Bf=String.fromCharCode,DEe=["","Named character references must be terminated by a semicolon","Numeric character references must be terminated by a semicolon","Named character references cannot be empty","Numeric character references cannot be empty","Named character references must be known","Numeric character references cannot be disallowed","Numeric character references cannot be outside the permissible Unicode range"];function PEe(e,t={}){const n=typeof t.additional=="string"?t.additional.charCodeAt(0):t.additional,r=[];let o=0,i=-1,a="",s,l;t.position&&("start"in t.position||"indent"in t.position?(l=t.position.indent,s=t.position.start):s=t.position);let u=(s?s.line:0)||1,d=(s?s.column:0)||1,h=m(),p;for(o--;++o<=e.length;)if(p===10&&(d=(l?l[i]:0)||1),p=e.charCodeAt(o),p===38){const b=e.charCodeAt(o+1);if(b===9||b===10||b===12||b===32||b===38||b===60||Number.isNaN(b)||n&&b===n){a+=Bf(p),d++;continue}const E=o+1;let w=E,k=E,y;if(b===35){k=++w;const K=e.charCodeAt(k);K===88||K===120?(y="hexadecimal",k=++w):y="decimal"}else y="named";let F="",C="",A="";const P=y==="named"?_A:y==="decimal"?aL:REe;for(k--;++k<=e.length;){const K=e.charCodeAt(k);if(!P(K))break;A+=Bf(K),y==="named"&&BEe.includes(A)&&(F=A,C=L0(A))}let I=e.charCodeAt(k)===59;if(I){k++;const K=y==="named"?L0(A):!1;K&&(F=A,C=K)}let j=1+k-E,H="";if(!(!I&&t.nonTerminated===!1))if(!A)y!=="named"&&v(4,j);else if(y==="named"){if(I&&!C)v(5,1);else if(F!==A&&(k=w+F.length,j=1+k-w,I=!1),!I){const K=F?1:3;if(t.attribute){const U=e.charCodeAt(k);U===61?(v(K,j),C=""):_A(U)?C="":v(K,j)}else v(K,j)}H=C}else{I||v(2,j);let K=Number.parseInt(A,y==="hexadecimal"?16:10);if(MEe(K))v(7,j),H=Bf(65533);else if(K in EA)v(6,j),H=EA[K];else{let U="";LEe(K)&&v(6,j),K>65535&&(K-=65536,U+=Bf(K>>>10|55296),K=56320|K&1023),H=U+Bf(K)}}if(H){_(),h=m(),o=k-1,d+=k-E+1,r.push(H);const K=m();K.offset++,t.reference&&t.reference.call(t.referenceContext,H,{start:h,end:K},e.slice(E-1,k)),h=K}else A=e.slice(E-1,k),a+=A,d+=A.length,o=k-1}else p===10&&(u++,i++,d=0),Number.isNaN(p)?_():(a+=Bf(p),d++);return r.join("");function m(){return{line:u,column:d,offset:o+((s?s.offset:0)||0)}}function v(b,E){let w;t.warning&&(w=m(),w.column+=E,w.offset+=E,t.warning.call(t.warningContext,DEe[b],w,b))}function _(){a&&(r.push(a),t.text&&t.text.call(t.textContext,a,{start:h,end:m()}),a="")}}function MEe(e){return e>=55296&&e<=57343||e>1114111}function LEe(e){return e>=1&&e<=8||e===11||e>=13&&e<=31||e>=127&&e<=159||e>=64976&&e<=65007||(e&65535)===65535||(e&65535)===65534}var jEe=0,Zm={},Dr={util:{type:function(e){return Object.prototype.toString.call(e).slice(8,-1)},objId:function(e){return e.__id||Object.defineProperty(e,"__id",{value:++jEe}),e.__id},clone:function e(t,n){n=n||{};var r,o;switch(Dr.util.type(t)){case"Object":if(o=Dr.util.objId(t),n[o])return n[o];r={},n[o]=r;for(var i in t)t.hasOwnProperty(i)&&(r[i]=e(t[i],n));return r;case"Array":return o=Dr.util.objId(t),n[o]?n[o]:(r=[],n[o]=r,t.forEach(function(a,s){r[s]=e(a,n)}),r);default:return t}}},languages:{plain:Zm,plaintext:Zm,text:Zm,txt:Zm,extend:function(e,t){var n=Dr.util.clone(Dr.languages[e]);for(var r in t)n[r]=t[r];return n},insertBefore:function(e,t,n,r){r=r||Dr.languages;var o=r[e],i={};for(var a in o)if(o.hasOwnProperty(a)){if(a==t)for(var s in n)n.hasOwnProperty(s)&&(i[s]=n[s]);n.hasOwnProperty(a)||(i[a]=o[a])}var l=r[e];return r[e]=i,Dr.languages.DFS(Dr.languages,function(u,d){d===l&&u!=e&&(this[u]=i)}),i},DFS:function e(t,n,r,o){o=o||{};var i=Dr.util.objId;for(var a in t)if(t.hasOwnProperty(a)){n.call(t,a,t[a],r||a);var s=t[a],l=Dr.util.type(s);l==="Object"&&!o[i(s)]?(o[i(s)]=!0,e(s,n,null,o)):l==="Array"&&!o[i(s)]&&(o[i(s)]=!0,e(s,n,a,o))}}},plugins:{},highlight:function(e,t,n){var r={code:e,grammar:t,language:n};if(Dr.hooks.run("before-tokenize",r),!r.grammar)throw new Error('The language "'+r.language+'" has no grammar.');return r.tokens=Dr.tokenize(r.code,r.grammar),Dr.hooks.run("after-tokenize",r),Yh.stringify(Dr.util.encode(r.tokens),r.language)},tokenize:function(e,t){var n=t.rest;if(n){for(var r in n)t[r]=n[r];delete t.rest}var o=new zEe;return Jg(o,o.head,e),sL(e,o,t,o.head,0),UEe(o)},hooks:{all:{},add:function(e,t){var n=Dr.hooks.all;n[e]=n[e]||[],n[e].push(t)},run:function(e,t){var n=Dr.hooks.all[e];if(!(!n||!n.length))for(var r=0,o;o=n[r++];)o(t)}},Token:Yh};function Yh(e,t,n,r){this.type=e,this.content=t,this.alias=n,this.length=(r||"").length|0}function TA(e,t,n,r){e.lastIndex=t;var o=e.exec(n);if(o&&r&&o[1]){var i=o[1].length;o.index+=i,o[0]=o[0].slice(i)}return o}function sL(e,t,n,r,o,i){for(var a in n)if(!(!n.hasOwnProperty(a)||!n[a])){var s=n[a];s=Array.isArray(s)?s:[s];for(var l=0;l<s.length;++l){if(i&&i.cause==a+","+l)return;var u=s[l],d=u.inside,h=!!u.lookbehind,p=!!u.greedy,m=u.alias;if(p&&!u.pattern.global){var v=u.pattern.toString().match(/[imsuy]*$/)[0];u.pattern=RegExp(u.pattern.source,v+"g")}for(var _=u.pattern||u,b=r.next,E=o;b!==t.tail&&!(i&&E>=i.reach);E+=b.value.length,b=b.next){var w=b.value;if(t.length>e.length)return;if(!(w instanceof Yh)){var k=1,y;if(p){if(y=TA(_,E,e,h),!y||y.index>=e.length)break;var P=y.index,F=y.index+y[0].length,C=E;for(C+=b.value.length;P>=C;)b=b.next,C+=b.value.length;if(C-=b.value.length,E=C,b.value instanceof Yh)continue;for(var A=b;A!==t.tail&&(C<F||typeof A.value=="string");A=A.next)k++,C+=A.value.length;k--,w=e.slice(E,C),y.index-=E}else if(y=TA(_,0,w,h),!y)continue;var P=y.index,I=y[0],j=w.slice(0,P),H=w.slice(P+I.length),K=E+w.length;i&&K>i.reach&&(i.reach=K);var U=b.prev;j&&(U=Jg(t,U,j),E+=j.length),HEe(t,U,k);var pe=new Yh(a,d?Dr.tokenize(I,d):I,m,I);if(b=Jg(t,U,pe),H&&Jg(t,b,H),k>1){var se={cause:a+","+l,reach:K};sL(e,t,n,b.prev,E,se),i&&se.reach>i.reach&&(i.reach=se.reach)}}}}}}function zEe(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function Jg(e,t,n){var r=t.next,o={value:n,prev:t,next:r};return t.next=o,r.prev=o,e.length++,o}function HEe(e,t,n){for(var r=t.next,o=0;o<n&&r!==e.tail;o++)r=r.next;t.next=r,r.prev=t,e.length-=o}function UEe(e){for(var t=[],n=e.head.next;n!==e.tail;)t.push(n.value),n=n.next;return t}const lL=Dr,g1={}.hasOwnProperty;function uL(){}uL.prototype=lL;const Ze=new uL;Ze.highlight=qEe;Ze.register=$Ee;Ze.alias=WEe;Ze.registered=GEe;Ze.listLanguages=KEe;Ze.util.encode=VEe;Ze.Token.stringify=h4;function qEe(e,t){if(typeof e!="string")throw new TypeError("Expected `string` for `value`, got `"+e+"`");let n,r;if(t&&typeof t=="object")n=t;else{if(r=t,typeof r!="string")throw new TypeError("Expected `string` for `name`, got `"+r+"`");if(g1.call(Ze.languages,r))n=Ze.languages[r];else throw new Error("Unknown language: `"+r+"` is not registered")}return{type:"root",children:lL.highlight.call(Ze,e,n,r)}}function $Ee(e){if(typeof e!="function"||!e.displayName)throw new Error("Expected `function` for `syntax`, got `"+e+"`");g1.call(Ze.languages,e.displayName)||e(Ze)}function WEe(e,t){const n=Ze.languages;let r={};typeof e=="string"?t&&(r[e]=t):r=e;let o;for(o in r)if(g1.call(r,o)){const i=r[o],a=typeof i=="string"?[i]:i;let s=-1;for(;++s<a.length;)n[a[s]]=n[o]}}function GEe(e){if(typeof e!="string")throw new TypeError("Expected `string` for `aliasOrLanguage`, got `"+e+"`");return g1.call(Ze.languages,e)}function KEe(){const e=Ze.languages,t=[];let n;for(n in e)g1.call(e,n)&&typeof e[n]=="object"&&t.push(n);return t}function h4(e,t){if(typeof e=="string")return{type:"text",value:e};if(Array.isArray(e)){const r=[];let o=-1;for(;++o<e.length;)e[o]!==""&&e[o]!==null&&e[o]!==void 0&&r.push(h4(e[o],t));return r}const n={type:e.type,content:h4(e.content,t),tag:"span",classes:["token",e.type],attributes:{},language:t};return e.alias&&n.classes.push(...typeof e.alias=="string"?[e.alias]:e.alias),Ze.hooks.run("wrap",n),iL(n.tag+"."+n.classes.join("."),YEe(n.attributes),n.content)}function VEe(e){return e}function YEe(e){let t;for(t in e)g1.call(e,t)&&(e[t]=PEe(e[t]));return e}const QEe={'code[class*="language-"]':{color:"black",background:"none",textShadow:"0 1px white",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{color:"black",background:"#f5f2f0",textShadow:"0 1px white",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:".5em 0",overflow:"auto"},'pre[class*="language-"]::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"] ::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"]::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"] ::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"]::selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"] ::selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"]::selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"] ::selection':{textShadow:"none",background:"#b3d4fc"},':not(pre) > code[class*="language-"]':{background:"#f5f2f0",padding:".1em",borderRadius:".3em",whiteSpace:"normal"},comment:{color:"slategray"},prolog:{color:"slategray"},doctype:{color:"slategray"},cdata:{color:"slategray"},punctuation:{color:"#999"},namespace:{Opacity:".7"},property:{color:"#905"},tag:{color:"#905"},boolean:{color:"#905"},number:{color:"#905"},constant:{color:"#905"},symbol:{color:"#905"},deleted:{color:"#905"},selector:{color:"#690"},"attr-name":{color:"#690"},string:{color:"#690"},char:{color:"#690"},builtin:{color:"#690"},inserted:{color:"#690"},operator:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},entity:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)",cursor:"help"},url:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".language-css .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".style .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},atrule:{color:"#07a"},"attr-value":{color:"#07a"},keyword:{color:"#07a"},function:{color:"#DD4A68"},"class-name":{color:"#DD4A68"},regex:{color:"#e90"},important:{color:"#e90",fontWeight:"bold"},variable:{color:"#e90"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"}};bs.displayName="clike";bs.aliases=[];function bs(e){e.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/}}Ap.displayName="c";Ap.aliases=[];function Ap(e){e.register(bs),e.languages.c=e.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),e.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),e.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},e.languages.c.string],char:e.languages.c.char,comment:e.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:e.languages.c}}}}),e.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete e.languages.c.boolean}Fy.displayName="cpp";Fy.aliases=[];function Fy(e){e.register(Ap),function(t){var n=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,r=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return n.source});t.languages.cpp=t.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return n.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:n,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),t.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return r})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),t.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:t.languages.cpp}}}}),t.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),t.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:t.languages.extend("cpp",{})}}),t.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},t.languages.cpp["base-clause"])}(e)}Pw.displayName="arduino";Pw.aliases=["ino"];function Pw(e){e.register(Fy),e.languages.arduino=e.languages.extend("cpp",{keyword:/\b(?:String|array|bool|boolean|break|byte|case|catch|continue|default|do|double|else|finally|for|function|goto|if|in|instanceof|int|integer|long|loop|new|null|return|setup|string|switch|throw|try|void|while|word)\b/,constant:/\b(?:ANALOG_MESSAGE|DEFAULT|DIGITAL_MESSAGE|EXTERNAL|FIRMATA_STRING|HIGH|INPUT|INPUT_PULLUP|INTERNAL|INTERNAL1V1|INTERNAL2V56|LED_BUILTIN|LOW|OUTPUT|REPORT_ANALOG|REPORT_DIGITAL|SET_PIN_MODE|SYSEX_START|SYSTEM_RESET)\b/,builtin:/\b(?:Audio|BSSID|Bridge|Client|Console|EEPROM|Esplora|EsploraTFT|Ethernet|EthernetClient|EthernetServer|EthernetUDP|File|FileIO|FileSystem|Firmata|GPRS|GSM|GSMBand|GSMClient|GSMModem|GSMPIN|GSMScanner|GSMServer|GSMVoiceCall|GSM_SMS|HttpClient|IPAddress|IRread|Keyboard|KeyboardController|LiquidCrystal|LiquidCrystal_I2C|Mailbox|Mouse|MouseController|PImage|Process|RSSI|RobotControl|RobotMotor|SD|SPI|SSID|Scheduler|Serial|Server|Servo|SoftwareSerial|Stepper|Stream|TFT|Task|USBHost|WiFi|WiFiClient|WiFiServer|WiFiUDP|Wire|YunClient|YunServer|abs|addParameter|analogRead|analogReadResolution|analogReference|analogWrite|analogWriteResolution|answerCall|attach|attachGPRS|attachInterrupt|attached|autoscroll|available|background|beep|begin|beginPacket|beginSD|beginSMS|beginSpeaker|beginTFT|beginTransmission|beginWrite|bit|bitClear|bitRead|bitSet|bitWrite|blink|blinkVersion|buffer|changePIN|checkPIN|checkPUK|checkReg|circle|cityNameRead|cityNameWrite|clear|clearScreen|click|close|compassRead|config|connect|connected|constrain|cos|countryNameRead|countryNameWrite|createChar|cursor|debugPrint|delay|delayMicroseconds|detach|detachInterrupt|digitalRead|digitalWrite|disconnect|display|displayLogos|drawBMP|drawCompass|encryptionType|end|endPacket|endSMS|endTransmission|endWrite|exists|exitValue|fill|find|findUntil|flush|gatewayIP|get|getAsynchronously|getBand|getButton|getCurrentCarrier|getIMEI|getKey|getModifiers|getOemKey|getPINUsed|getResult|getSignalStrength|getSocket|getVoiceCallStatus|getXChange|getYChange|hangCall|height|highByte|home|image|interrupts|isActionDone|isDirectory|isListening|isPIN|isPressed|isValid|keyPressed|keyReleased|keyboardRead|knobRead|leftToRight|line|lineFollowConfig|listen|listenOnLocalhost|loadImage|localIP|lowByte|macAddress|maintain|map|max|messageAvailable|micros|millis|min|mkdir|motorsStop|motorsWrite|mouseDragged|mouseMoved|mousePressed|mouseReleased|move|noAutoscroll|noBlink|noBuffer|noCursor|noDisplay|noFill|noInterrupts|noListenOnLocalhost|noStroke|noTone|onReceive|onRequest|open|openNextFile|overflow|parseCommand|parseFloat|parseInt|parsePacket|pauseMode|peek|pinMode|playFile|playMelody|point|pointTo|position|pow|prepare|press|print|printFirmwareVersion|printVersion|println|process|processInput|pulseIn|put|random|randomSeed|read|readAccelerometer|readBlue|readButton|readBytes|readBytesUntil|readGreen|readJoystickButton|readJoystickSwitch|readJoystickX|readJoystickY|readLightSensor|readMessage|readMicrophone|readNetworks|readRed|readSlider|readString|readStringUntil|readTemperature|ready|rect|release|releaseAll|remoteIP|remoteNumber|remotePort|remove|requestFrom|retrieveCallingNumber|rewindDirectory|rightToLeft|rmdir|robotNameRead|robotNameWrite|run|runAsynchronously|runShellCommand|runShellCommandAsynchronously|running|scanNetworks|scrollDisplayLeft|scrollDisplayRight|seek|sendAnalog|sendDigitalPortPair|sendDigitalPorts|sendString|sendSysex|serialEvent|setBand|setBitOrder|setClockDivider|setCursor|setDNS|setDataMode|setFirmwareVersion|setMode|setPINUsed|setSpeed|setTextSize|setTimeout|shiftIn|shiftOut|shutdown|sin|size|sqrt|startLoop|step|stop|stroke|subnetMask|switchPIN|tan|tempoWrite|text|tone|transfer|tuneWrite|turn|updateIR|userNameRead|userNameWrite|voiceCall|waitContinue|width|write|writeBlue|writeGreen|writeJSON|writeMessage|writeMicroseconds|writeRGB|writeRed|yield)\b/}),e.languages.ino=e.languages.arduino}Mw.displayName="bash";Mw.aliases=["sh","shell"];function Mw(e){(function(t){var n="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",r={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},o={bash:r,environment:{pattern:RegExp("\\$"+n),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+n),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};t.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+n),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:o},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:r}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:o},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:o.entity}}],environment:{pattern:RegExp("\\$?"+n),alias:"constant"},variable:o.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},r.inside=t.languages.bash;for(var i=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],a=o.variable[1].inside,s=0;s<i.length;s++)a[i[s]]=t.languages.bash[i[s]];t.languages.sh=t.languages.bash,t.languages.shell=t.languages.bash})(e)}Lw.displayName="csharp";Lw.aliases=["cs","dotnet"];function Lw(e){e.register(bs),function(t){function n(fe,R){return fe.replace(/<<(\d+)>>/g,function(L,Ae){return"(?:"+R[+Ae]+")"})}function r(fe,R,L){return RegExp(n(fe,R),L||"")}function o(fe,R){for(var L=0;L<R;L++)fe=fe.replace(/<<self>>/g,function(){return"(?:"+fe+")"});return fe.replace(/<<self>>/g,"[^\\s\\S]")}var i={type:"bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void",typeDeclaration:"class enum interface record struct",contextual:"add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)",other:"abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield"};function a(fe){return"\\b(?:"+fe.trim().replace(/ /g,"|")+")\\b"}var s=a(i.typeDeclaration),l=RegExp(a(i.type+" "+i.typeDeclaration+" "+i.contextual+" "+i.other)),u=a(i.typeDeclaration+" "+i.contextual+" "+i.other),d=a(i.type+" "+i.typeDeclaration+" "+i.other),h=o(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source,2),p=o(/\((?:[^()]|<<self>>)*\)/.source,2),m=/@?\b[A-Za-z_]\w*\b/.source,v=n(/<<0>>(?:\s*<<1>>)?/.source,[m,h]),_=n(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source,[u,v]),b=/\[\s*(?:,\s*)*\]/.source,E=n(/<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,[_,b]),w=n(/[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,[h,p,b]),k=n(/\(<<0>>+(?:,<<0>>+)+\)/.source,[w]),y=n(/(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,[k,_,b]),F={keyword:l,punctuation:/[<>()?,.:[\]]/},C=/'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source,A=/"(?:\\.|[^\\"\r\n])*"/.source,P=/@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;t.languages.csharp=t.languages.extend("clike",{string:[{pattern:r(/(^|[^$\\])<<0>>/.source,[P]),lookbehind:!0,greedy:!0},{pattern:r(/(^|[^@$\\])<<0>>/.source,[A]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:r(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source,[_]),lookbehind:!0,inside:F},{pattern:r(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source,[m,y]),lookbehind:!0,inside:F},{pattern:r(/(\busing\s+)<<0>>(?=\s*=)/.source,[m]),lookbehind:!0},{pattern:r(/(\b<<0>>\s+)<<1>>/.source,[s,v]),lookbehind:!0,inside:F},{pattern:r(/(\bcatch\s*\(\s*)<<0>>/.source,[_]),lookbehind:!0,inside:F},{pattern:r(/(\bwhere\s+)<<0>>/.source,[m]),lookbehind:!0},{pattern:r(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source,[E]),lookbehind:!0,inside:F},{pattern:r(/\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/.source,[y,d,m]),inside:F}],keyword:l,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),t.languages.insertBefore("csharp","number",{range:{pattern:/\.\./,alias:"operator"}}),t.languages.insertBefore("csharp","punctuation",{"named-parameter":{pattern:r(/([(,]\s*)<<0>>(?=\s*:)/.source,[m]),lookbehind:!0,alias:"punctuation"}}),t.languages.insertBefore("csharp","class-name",{namespace:{pattern:r(/(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,[m]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:r(/(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/.source,[p]),lookbehind:!0,alias:"class-name",inside:F},"return-type":{pattern:r(/<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,[y,_]),inside:F,alias:"class-name"},"constructor-invocation":{pattern:r(/(\bnew\s+)<<0>>(?=\s*[[({])/.source,[y]),lookbehind:!0,inside:F,alias:"class-name"},"generic-method":{pattern:r(/<<0>>\s*<<1>>(?=\s*\()/.source,[m,h]),inside:{function:r(/^<<0>>/.source,[m]),generic:{pattern:RegExp(h),alias:"class-name",inside:F}}},"type-list":{pattern:r(/\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/.source,[s,v,m,y,l.source,p,/\bnew\s*\(\s*\)/.source]),lookbehind:!0,inside:{"record-arguments":{pattern:r(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source,[v,p]),lookbehind:!0,greedy:!0,inside:t.languages.csharp},keyword:l,"class-name":{pattern:RegExp(y),greedy:!0,inside:F},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:"keyword"}}}});var I=A+"|"+C,j=n(/\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,[I]),H=o(n(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[j]),2),K=/\b(?:assembly|event|field|method|module|param|property|return|type)\b/.source,U=n(/<<0>>(?:\s*\(<<1>>*\))?/.source,[_,H]);t.languages.insertBefore("csharp","class-name",{attribute:{pattern:r(/((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/.source,[K,U]),lookbehind:!0,greedy:!0,inside:{target:{pattern:r(/^<<0>>(?=\s*:)/.source,[K]),alias:"keyword"},"attribute-arguments":{pattern:r(/\(<<0>>*\)/.source,[H]),inside:t.languages.csharp},"class-name":{pattern:RegExp(_),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var pe=/:[^}\r\n]+/.source,se=o(n(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[j]),2),J=n(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[se,pe]),$=o(n(/[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/.source,[I]),2),_e=n(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[$,pe]);function ve(fe,R){return{interpolation:{pattern:r(/((?:^|[^{])(?:\{\{)*)<<0>>/.source,[fe]),lookbehind:!0,inside:{"format-string":{pattern:r(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source,[R,pe]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-csharp",inside:t.languages.csharp}}},string:/[\s\S]+/}}t.languages.insertBefore("csharp","string",{"interpolation-string":[{pattern:r(/(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,[J]),lookbehind:!0,greedy:!0,inside:ve(J,se)},{pattern:r(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source,[_e]),lookbehind:!0,greedy:!0,inside:ve(_e,$)}],char:{pattern:RegExp(C),greedy:!0}}),t.languages.dotnet=t.languages.cs=t.languages.csharp}(e)}Np.displayName="markup";Np.aliases=["atom","html","mathml","rss","ssml","svg","xml"];function Np(e){e.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},e.languages.markup.tag.inside["attr-value"].inside.entity=e.languages.markup.entity,e.languages.markup.doctype.inside["internal-subset"].inside=e.languages.markup,e.hooks.add("wrap",function(t){t.type==="entity"&&(t.attributes.title=t.content.value.replace(/&amp;/,"&"))}),Object.defineProperty(e.languages.markup.tag,"addInlined",{value:function(n,r){var o={};o["language-"+r]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:e.languages[r]},o.cdata=/^<!\[CDATA\[|\]\]>$/i;var i={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:o}};i["language-"+r]={pattern:/[\s\S]+/,inside:e.languages[r]};var a={};a[n]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return n}),"i"),lookbehind:!0,greedy:!0,inside:i},e.languages.insertBefore("markup","cdata",a)}}),Object.defineProperty(e.languages.markup.tag,"addAttribute",{value:function(t,n){e.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+t+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[n,"language-"+n],inside:e.languages[n]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),e.languages.html=e.languages.markup,e.languages.mathml=e.languages.markup,e.languages.svg=e.languages.markup,e.languages.xml=e.languages.extend("markup",{}),e.languages.ssml=e.languages.xml,e.languages.atom=e.languages.xml,e.languages.rss=e.languages.xml}v1.displayName="css";v1.aliases=[];function v1(e){(function(t){var n=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;t.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+n.source+")*?"+/(?:;|(?=\s*\{))/.source),inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+n.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+n.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+n.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:n,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},t.languages.css.atrule.inside.rest=t.languages.css;var r=t.languages.markup;r&&(r.tag.addInlined("style","css"),r.tag.addAttribute("style","css"))})(e)}jw.displayName="diff";jw.aliases=[];function jw(e){(function(t){t.languages.diff={coord:[/^(?:\*{3}|-{3}|\+{3}).*$/m,/^@@.*@@$/m,/^\d.*$/m]};var n={"deleted-sign":"-","deleted-arrow":"<","inserted-sign":"+","inserted-arrow":">",unchanged:" ",diff:"!"};Object.keys(n).forEach(function(r){var o=n[r],i=[];/^\w+$/.test(r)||i.push(/\w+/.exec(r)[0]),r==="diff"&&i.push("bold"),t.languages.diff[r]={pattern:RegExp("^(?:["+o+`].*(?:\r ?| |(?![\\s\\S])))+`,"m"),alias:i,inside:{line:{pattern:/(.)(?=[\s\S]).*(?:\r\n?|\n)?/,lookbehind:!0},prefix:{pattern:/[\s\S]/,alias:/\w+/.exec(r)[0]}}}}),Object.defineProperty(t.languages.diff,"PREFIXES",{value:n})})(e)}zw.displayName="go";zw.aliases=[];function zw(e){e.register(bs),e.languages.go=e.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),e.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete e.languages.go["class-name"]}Hw.displayName="ini";Hw.aliases=[];function Hw(e){e.languages.ini={comment:{pattern:/(^[ \f\t\v]*)[#;][^\n\r]*/m,lookbehind:!0},section:{pattern:/(^[ \f\t\v]*)\[[^\n\r\]]*\]?/m,lookbehind:!0,inside:{"section-name":{pattern:/(^\[[ \f\t\v]*)[^ \f\t\v\]]+(?:[ \f\t\v]+[^ \f\t\v\]]+)*/,lookbehind:!0,alias:"selector"},punctuation:/\[|\]/}},key:{pattern:/(^[ \f\t\v]*)[^ \f\n\r\t\v=]+(?:[ \f\t\v]+[^ \f\n\r\t\v=]+)*(?=[ \f\t\v]*=)/m,lookbehind:!0,alias:"attr-name"},value:{pattern:/(=[ \f\t\v]*)[^ \f\n\r\t\v]+(?:[ \f\t\v]+[^ \f\n\r\t\v]+)*/,lookbehind:!0,alias:"attr-value",inside:{"inner-value":{pattern:/^("|').+(?=\1$)/,lookbehind:!0}}},punctuation:/=/}}Uw.displayName="java";Uw.aliases=[];function Uw(e){e.register(bs),function(t){var n=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,r=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,o={pattern:RegExp(/(^|[^\w.])/.source+r+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};t.languages.java=t.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[o,{pattern:RegExp(/(^|[^\w.])/.source+r+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:o.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+r+/[A-Z]\w*\b/.source),lookbehind:!0,inside:o.inside}],keyword:n,function:[t.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),t.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),t.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":o,keyword:n,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+r+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:o.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+r+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:o.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return n.source})),lookbehind:!0,inside:{punctuation:/\./}}})}(e)}qw.displayName="regex";qw.aliases=[];function qw(e){(function(t){var n={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:"escape"},r=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,o={pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},i={pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},a="(?:[^\\\\-]|"+r.source+")",s=RegExp(a+"-"+a),l={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:"variable"};t.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:"operator"},"char-class-punctuation":{pattern:/^\[|\]$/,alias:"punctuation"},range:{pattern:s,inside:{escape:r,"range-punctuation":{pattern:/-/,alias:"operator"}}},"special-escape":n,"char-set":i,escape:r}},"special-escape":n,"char-set":o,backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:"keyword"},{pattern:/\\k<[^<>']+>/,alias:"keyword",inside:{"group-name":l}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:"function"},escape:r,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/,alias:"punctuation",inside:{"group-name":l}},{pattern:/\)/,alias:"punctuation"}],quantifier:{pattern:/(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/,alias:"number"},alternation:{pattern:/\|/,alias:"keyword"}}})(e)}Iy.displayName="javascript";Iy.aliases=["js"];function Iy(e){e.register(bs),e.languages.javascript=e.languages.extend("clike",{"class-name":[e.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),e.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,e.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:e.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:e.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:e.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:e.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:e.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),e.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:e.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),e.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),e.languages.markup&&(e.languages.markup.tag.addInlined("script","javascript"),e.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),e.languages.js=e.languages.javascript}$w.displayName="json";$w.aliases=["webmanifest"];function $w(e){e.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},e.languages.webmanifest=e.languages.json}Ww.displayName="kotlin";Ww.aliases=["kt","kts"];function Ww(e){e.register(bs),function(t){t.languages.kotlin=t.languages.extend("clike",{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete t.languages.kotlin["class-name"];var n={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:t.languages.kotlin}};t.languages.insertBefore("kotlin","string",{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:"multiline",inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:n},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:"singleline",inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:n},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete t.languages.kotlin.string,t.languages.insertBefore("kotlin","keyword",{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:"builtin"}}),t.languages.insertBefore("kotlin","function",{label:{pattern:/\b\w+@|@\w+\b/,alias:"symbol"}}),t.languages.kt=t.languages.kotlin,t.languages.kts=t.languages.kotlin}(e)}Gw.displayName="less";Gw.aliases=[];function Gw(e){e.register(v1),e.languages.less=e.languages.extend("css",{comment:[/\/\*[\s\S]*?\*\//,{pattern:/(^|[^\\])\/\/.*/,lookbehind:!0}],atrule:{pattern:/@[\w-](?:\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{punctuation:/[:()]/}},selector:{pattern:/(?:@\{[\w-]+\}|[^{};\s@])(?:@\{[\w-]+\}|\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};@\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{variable:/@+[\w-]+/}},property:/(?:@\{[\w-]+\}|[\w-])+(?:\+_?)?(?=\s*:)/,operator:/[+\-*\/]/}),e.languages.insertBefore("less","property",{variable:[{pattern:/@[\w-]+\s*:/,inside:{punctuation:/:/}},/@@?[\w-]+/],"mixin-usage":{pattern:/([{;]\s*)[.#](?!\d)[\w-].*?(?=[(;])/,lookbehind:!0,alias:"function"}})}Kw.displayName="lua";Kw.aliases=[];function Kw(e){e.languages.lua={comment:/^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,greedy:!0},number:/\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,keyword:/\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,function:/(?!\d)\w+(?=\s*(?:[({]))/,operator:[/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,{pattern:/(^|[^.])\.\.(?!\.)/,lookbehind:!0}],punctuation:/[\[\](){},;]|\.+|:+/}}Vw.displayName="makefile";Vw.aliases=[];function Vw(e){e.languages.makefile={comment:{pattern:/(^|[^\\])#(?:\\(?:\r\n|[\s\S])|[^\\\r\n])*/,lookbehind:!0},string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"builtin-target":{pattern:/\.[A-Z][^:#=\s]+(?=\s*:(?!=))/,alias:"builtin"},target:{pattern:/^(?:[^:=\s]|[ \t]+(?![\s:]))+(?=\s*:(?!=))/m,alias:"symbol",inside:{variable:/\$+(?:(?!\$)[^(){}:#=\s]+|(?=[({]))/}},variable:/\$+(?:(?!\$)[^(){}:#=\s]+|\([@*%<^+?][DF]\)|(?=[({]))/,keyword:/-include\b|\b(?:define|else|endef|endif|export|ifn?def|ifn?eq|include|override|private|sinclude|undefine|unexport|vpath)\b/,function:{pattern:/(\()(?:abspath|addsuffix|and|basename|call|dir|error|eval|file|filter(?:-out)?|findstring|firstword|flavor|foreach|guile|if|info|join|lastword|load|notdir|or|origin|patsubst|realpath|shell|sort|strip|subst|suffix|value|warning|wildcard|word(?:list|s)?)(?=[ \t])/,lookbehind:!0},operator:/(?:::|[?:+!])?=|[|@]/,punctuation:/[:;(){}]/}}Yw.displayName="yaml";Yw.aliases=["yml"];function Yw(e){(function(t){var n=/[*&][^\s[\]{},]+/,r=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,o="(?:"+r.source+"(?:[ ]+"+n.source+")?|"+n.source+"(?:[ ]+"+r.source+")?)",i=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),a=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function s(l,u){u=(u||"").replace(/m/g,"")+"m";var d=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return o}).replace(/<<value>>/g,function(){return l});return RegExp(d,u)}t.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return o})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return o}).replace(/<<key>>/g,function(){return"(?:"+i+"|"+a+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:s(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:s(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:s(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:s(a),lookbehind:!0,greedy:!0},number:{pattern:s(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:r,important:n,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},t.languages.yml=t.languages.yaml})(e)}Qw.displayName="markdown";Qw.aliases=["md"];function Qw(e){e.register(Np),function(t){var n=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function r(s){return s=s.replace(/<inner>/g,function(){return n}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+s+")")}var o=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,i=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return o}),a=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;t.languages.markdown=t.languages.extend("markup",{}),t.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:t.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+i+a+"(?:"+i+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+i+a+")(?:"+i+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(o),inside:t.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+i+")"+a+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+i+"$"),inside:{"table-header":{pattern:RegExp(o),alias:"important",inside:t.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:r(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:r(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:r(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:r(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(s){["url","bold","italic","strike","code-snippet"].forEach(function(l){s!==l&&(t.languages.markdown[s].inside.content.inside[l]=t.languages.markdown[l])})}),t.hooks.add("after-tokenize",function(s){if(s.language!=="markdown"&&s.language!=="md")return;function l(u){if(!(!u||typeof u=="string"))for(var d=0,h=u.length;d<h;d++){var p=u[d];if(p.type!=="code"){l(p.content);continue}var m=p.content[1],v=p.content[3];if(m&&v&&m.type==="code-language"&&v.type==="code-block"&&typeof m.content=="string"){var _=m.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp");_=(/[a-z][\w-]*/i.exec(_)||[""])[0].toLowerCase();var b="language-"+_;v.alias?typeof v.alias=="string"?v.alias=[v.alias,b]:v.alias.push(b):v.alias=[b]}}}l(s.tokens)}),t.hooks.add("wrap",function(s){if(s.type==="code-block"){for(var l="",u=0,d=s.classes.length;u<d;u++){var h=s.classes[u],p=/language-(.+)/.exec(h);if(p){l=p[1];break}}var m=t.languages[l];if(m)s.content=t.highlight(s.content.value,m,l);else if(l&&l!=="none"&&t.plugins.autoloader){var v="md-"+new Date().valueOf()+"-"+Math.floor(Math.random()*1e16);s.attributes.id=v,t.plugins.autoloader.loadLanguages(l,function(){var _=document.getElementById(v);_&&(_.innerHTML=t.highlight(_.textContent,t.languages[l],l))})}}}),RegExp(t.languages.markup.tag.pattern.source,"gi"),t.languages.md=t.languages.markdown}(e)}Xw.displayName="objectivec";Xw.aliases=["objc"];function Xw(e){e.register(Ap),e.languages.objectivec=e.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete e.languages.objectivec["class-name"],e.languages.objc=e.languages.objectivec}Zw.displayName="perl";Zw.aliases=[];function Zw(e){(function(t){var n=/(?:\((?:[^()\\]|\\[\s\S])*\)|\{(?:[^{}\\]|\\[\s\S])*\}|\[(?:[^[\]\\]|\\[\s\S])*\]|<(?:[^<>\\]|\\[\s\S])*>)/.source;t.languages.perl={comment:[{pattern:/(^\s*)=\w[\s\S]*?=cut.*/m,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\$])#.*/,lookbehind:!0,greedy:!0}],string:[{pattern:RegExp(/\b(?:q|qq|qw|qx)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,n].join("|")+")"),greedy:!0},{pattern:/("|`)(?:(?!\1)[^\\]|\\[\s\S])*\1/,greedy:!0},{pattern:/'(?:[^'\\\r\n]|\\.)*'/,greedy:!0}],regex:[{pattern:RegExp(/\b(?:m|qr)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,n].join("|")+")"+/[msixpodualngc]*/.source),greedy:!0},{pattern:RegExp(/(^|[^-])\b(?:s|tr|y)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\2)[^\\]|\\[\s\S])*\2(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,/([a-zA-Z0-9])(?:(?!\3)[^\\]|\\[\s\S])*\3(?:(?!\3)[^\\]|\\[\s\S])*\3/.source,n+/\s*/.source+n].join("|")+")"+/[msixpodualngcer]*/.source),lookbehind:!0,greedy:!0},{pattern:/\/(?:[^\/\\\r\n]|\\.)*\/[msixpodualngc]*(?=\s*(?:$|[\r\n,.;})&|\-+*~<>!?^]|(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|x|xor)\b))/,greedy:!0}],variable:[/[&*$@%]\{\^[A-Z]+\}/,/[&*$@%]\^[A-Z_]/,/[&*$@%]#?(?=\{)/,/[&*$@%]#?(?:(?:::)*'?(?!\d)[\w$]+(?![\w$]))+(?:::)*/,/[&*$@%]\d+/,/(?!%=)[$@%][!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~]/],filehandle:{pattern:/<(?![<=])\S*?>|\b_\b/,alias:"symbol"},"v-string":{pattern:/v\d+(?:\.\d+)*|\d+(?:\.\d+){2,}/,alias:"string"},function:{pattern:/(\bsub[ \t]+)\w+/,lookbehind:!0},keyword:/\b(?:any|break|continue|default|delete|die|do|else|elsif|eval|for|foreach|given|goto|if|last|local|my|next|our|package|print|redo|require|return|say|state|sub|switch|undef|unless|until|use|when|while)\b/,number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)\b/,operator:/-[rwxoRWXOezsfdlpSbctugkTBMAC]\b|\+[+=]?|-[-=>]?|\*\*?=?|\/\/?=?|=[=~>]?|~[~=]?|\|\|?=?|&&?=?|<(?:=>?|<=?)?|>>?=?|![~=]?|[%^]=?|\.(?:=|\.\.?)?|[\\?]|\bx(?:=|\b)|\b(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|xor)\b/,punctuation:/[{}[\];(),:]/}})(e)}By.displayName="markup-templating";By.aliases=[];function By(e){e.register(Np),function(t){function n(r,o){return"___"+r.toUpperCase()+o+"___"}Object.defineProperties(t.languages["markup-templating"]={},{buildPlaceholders:{value:function(r,o,i,a){if(r.language===o){var s=r.tokenStack=[];r.code=r.code.replace(i,function(l){if(typeof a=="function"&&!a(l))return l;for(var u=s.length,d;r.code.indexOf(d=n(o,u))!==-1;)++u;return s[u]=l,d}),r.grammar=t.languages.markup}}},tokenizePlaceholders:{value:function(r,o){if(r.language!==o||!r.tokenStack)return;r.grammar=t.languages[o];var i=0,a=Object.keys(r.tokenStack);function s(l){for(var u=0;u<l.length&&!(i>=a.length);u++){var d=l[u];if(typeof d=="string"||d.content&&typeof d.content=="string"){var h=a[i],p=r.tokenStack[h],m=typeof d=="string"?d:d.content,v=n(o,h),_=m.indexOf(v);if(_>-1){++i;var b=m.substring(0,_),E=new t.Token(o,t.tokenize(p,r.grammar),"language-"+o,p),w=m.substring(_+v.length),k=[];b&&k.push.apply(k,s([b])),k.push(E),w&&k.push.apply(k,s([w])),typeof d=="string"?l.splice.apply(l,[u,1].concat(k)):d.content=k}}else d.content&&s(d.content)}return l}s(r.tokens)}}})}(e)}Jw.displayName="php";Jw.aliases=[];function Jw(e){e.register(By),function(t){var n=/\/\*[\s\S]*?\*\/|\/\/.*|#(?!\[).*/,r=[{pattern:/\b(?:false|true)\b/i,alias:"boolean"},{pattern:/(::\s*)\b[a-z_]\w*\b(?!\s*\()/i,greedy:!0,lookbehind:!0},{pattern:/(\b(?:case|const)\s+)\b[a-z_]\w*(?=\s*[;=])/i,greedy:!0,lookbehind:!0},/\b(?:null)\b/i,/\b[A-Z_][A-Z0-9_]*\b(?!\s*\()/],o=/\b0b[01]+(?:_[01]+)*\b|\b0o[0-7]+(?:_[0-7]+)*\b|\b0x[\da-f]+(?:_[\da-f]+)*\b|(?:\b\d+(?:_\d+)*\.?(?:\d+(?:_\d+)*)?|\B\.\d+)(?:e[+-]?\d+)?/i,i=/<?=>|\?\?=?|\.{3}|\??->|[!=]=?=?|::|\*\*=?|--|\+\+|&&|\|\||<<|>>|[?~]|[/^|%*&<>.+-]=?/,a=/[{}\[\](),:;]/;t.languages.php={delimiter:{pattern:/\?>$|^<\?(?:php(?=\s)|=)?/i,alias:"important"},comment:n,variable:/\$+(?:\w+\b|(?=\{))/,package:{pattern:/(namespace\s+|use\s+(?:function\s+)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,lookbehind:!0,inside:{punctuation:/\\/}},"class-name-definition":{pattern:/(\b(?:class|enum|interface|trait)\s+)\b[a-z_]\w*(?!\\)\b/i,lookbehind:!0,alias:"class-name"},"function-definition":{pattern:/(\bfunction\s+)[a-z_]\w*(?=\s*\()/i,lookbehind:!0,alias:"function"},keyword:[{pattern:/(\(\s*)\b(?:array|bool|boolean|float|int|integer|object|string)\b(?=\s*\))/i,alias:"type-casting",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string)\b(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|never|object|self|static|string|void)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/\b(?:array(?!\s*\()|bool|float|int|iterable|mixed|object|string|void)\b/i,alias:"type-declaration",greedy:!0},{pattern:/(\|\s*)(?:false|null)\b|\b(?:false|null)(?=\s*\|)/i,alias:"type-declaration",greedy:!0,lookbehind:!0},{pattern:/\b(?:parent|self|static)(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(\byield\s+)from\b/i,lookbehind:!0},/\bclass\b/i,{pattern:/((?:^|[^\s>:]|(?:^|[^-])>|(?:^|[^:]):)\s*)\b(?:abstract|and|array|as|break|callable|case|catch|clone|const|continue|declare|default|die|do|echo|else|elseif|empty|enddeclare|endfor|endforeach|endif|endswitch|endwhile|enum|eval|exit|extends|final|finally|fn|for|foreach|function|global|goto|if|implements|include|include_once|instanceof|insteadof|interface|isset|list|match|namespace|never|new|or|parent|print|private|protected|public|readonly|require|require_once|return|self|static|switch|throw|trait|try|unset|use|var|while|xor|yield|__halt_compiler)\b/i,lookbehind:!0}],"argument-name":{pattern:/([(,]\s*)\b[a-z_]\w*(?=\s*:(?!:))/i,lookbehind:!0},"class-name":[{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self|\s+static))\s+|\bcatch\s*\()\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/(\|\s*)\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/\b[a-z_]\w*(?!\\)\b(?=\s*\|)/i,greedy:!0},{pattern:/(\|\s*)(?:\\?\b[a-z_]\w*)+\b/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(?:\\?\b[a-z_]\w*)+\b(?=\s*\|)/i,alias:"class-name-fully-qualified",greedy:!0,inside:{punctuation:/\\/}},{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self\b|\s+static\b))\s+|\bcatch\s*\()(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*\$)/i,alias:"type-declaration",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-declaration"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*::)/i,alias:["class-name-fully-qualified","static-context"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/([(,?]\s*)[a-z_]\w*(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-hint"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b[a-z_]\w*(?!\\)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:["class-name-fully-qualified","return-type"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:r,function:{pattern:/(^|[^\\\w])\\?[a-z_](?:[\w\\]*\w)?(?=\s*\()/i,lookbehind:!0,inside:{punctuation:/\\/}},property:{pattern:/(->\s*)\w+/,lookbehind:!0},number:o,operator:i,punctuation:a};var s={pattern:/\{\$(?:\{(?:\{[^{}]+\}|[^{}]+)\}|[^{}])+\}|(^|[^\\{])\$+(?:\w+(?:\[[^\r\n\[\]]+\]|->\w+)?)/,lookbehind:!0,inside:t.languages.php},l=[{pattern:/<<<'([^']+)'[\r\n](?:.*[\r\n])*?\1;/,alias:"nowdoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<'[^']+'|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<'?|[';]$/}}}},{pattern:/<<<(?:"([^"]+)"[\r\n](?:.*[\r\n])*?\1;|([a-z_]\w*)[\r\n](?:.*[\r\n])*?\2;)/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<(?:"[^"]+"|[a-z_]\w*)|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<"?|[";]$/}},interpolation:s}},{pattern:/`(?:\\[\s\S]|[^\\`])*`/,alias:"backtick-quoted-string",greedy:!0},{pattern:/'(?:\\[\s\S]|[^\\'])*'/,alias:"single-quoted-string",greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,alias:"double-quoted-string",greedy:!0,inside:{interpolation:s}}];t.languages.insertBefore("php","variable",{string:l,attribute:{pattern:/#\[(?:[^"'\/#]|\/(?![*/])|\/\/.*$|#(?!\[).*$|\/\*(?:[^*]|\*(?!\/))*\*\/|"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*')+\](?=\s*[a-z$#])/im,greedy:!0,inside:{"attribute-content":{pattern:/^(#\[)[\s\S]+(?=\]$)/,lookbehind:!0,inside:{comment:n,string:l,"attribute-class-name":[{pattern:/([^:]|^)\b[a-z_]\w*(?!\\)\b/i,alias:"class-name",greedy:!0,lookbehind:!0},{pattern:/([^:]|^)(?:\\?\b[a-z_]\w*)+/i,alias:["class-name","class-name-fully-qualified"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:r,number:o,operator:i,punctuation:a}},delimiter:{pattern:/^#\[|\]$/,alias:"punctuation"}}}}),t.hooks.add("before-tokenize",function(u){if(/<\?/.test(u.code)){var d=/<\?(?:[^"'/#]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|(?:\/\/|#(?!\[))(?:[^?\n\r]|\?(?!>))*(?=$|\?>|[\r\n])|#\[|\/\*(?:[^*]|\*(?!\/))*(?:\*\/|$))*?(?:\?>|$)/g;t.languages["markup-templating"].buildPlaceholders(u,"php",d)}}),t.hooks.add("after-tokenize",function(u){t.languages["markup-templating"].tokenizePlaceholders(u,"php")})}(e)}ek.displayName="python";ek.aliases=["py"];function ek(e){e.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},e.languages.python["string-interpolation"].inside.interpolation.inside.rest=e.languages.python,e.languages.py=e.languages.python}tk.displayName="r";tk.aliases=[];function tk(e){e.languages.r={comment:/#.*/,string:{pattern:/(['"])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},"percent-operator":{pattern:/%[^%\s]*%/,alias:"operator"},boolean:/\b(?:FALSE|TRUE)\b/,ellipsis:/\.\.(?:\.|\d+)/,number:[/\b(?:Inf|NaN)\b/,/(?:\b0x[\dA-Fa-f]+(?:\.\d*)?|\b\d+(?:\.\d*)?|\B\.\d+)(?:[EePp][+-]?\d+)?[iL]?/],keyword:/\b(?:NA|NA_character_|NA_complex_|NA_integer_|NA_real_|NULL|break|else|for|function|if|in|next|repeat|while)\b/,operator:/->?>?|<(?:=|<?-)?|[>=!]=?|::?|&&?|\|\|?|[+*\/^$@~]/,punctuation:/[(){}\[\],;]/}}nk.displayName="ruby";nk.aliases=["rb"];function nk(e){e.register(bs),function(t){t.languages.ruby=t.languages.extend("clike",{comment:{pattern:/#.*|^=begin\s[\s\S]*?^=end/m,greedy:!0},"class-name":{pattern:/(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,operator:/\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,punctuation:/[(){}[\].,;]/}),t.languages.insertBefore("ruby","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}});var n={pattern:/((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,lookbehind:!0,inside:{content:{pattern:/^(#\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:t.languages.ruby},delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"}}};delete t.languages.ruby.function;var r="(?:"+[/([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,/\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,/\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,/<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source].join("|")+")",o=/(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/.source;t.languages.insertBefore("ruby","keyword",{"regex-literal":[{pattern:RegExp(/%r/.source+r+/[egimnosux]{0,6}/.source),greedy:!0,inside:{interpolation:n,regex:/[\s\S]+/}},{pattern:/(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,lookbehind:!0,greedy:!0,inside:{interpolation:n,regex:/[\s\S]+/}}],variable:/[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,symbol:[{pattern:RegExp(/(^|[^:]):/.source+o),lookbehind:!0,greedy:!0},{pattern:RegExp(/([\r\n{(,][ \t]*)/.source+o+/(?=:(?!:))/.source),lookbehind:!0,greedy:!0}],"method-definition":{pattern:/(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,lookbehind:!0,inside:{function:/\b\w+$/,keyword:/^self\b/,"class-name":/^\w+/,punctuation:/\./}}}),t.languages.insertBefore("ruby","string",{"string-literal":[{pattern:RegExp(/%[qQiIwWs]?/.source+r),greedy:!0,inside:{interpolation:n,string:/[\s\S]+/}},{pattern:/("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,greedy:!0,inside:{interpolation:n,string:/[\s\S]+/}},{pattern:/<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?/}},interpolation:n,string:/[\s\S]+/}},{pattern:/<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?'|'$/}},string:/[\s\S]+/}}],"command-literal":[{pattern:RegExp(/%x/.source+r),greedy:!0,inside:{interpolation:n,command:{pattern:/[\s\S]+/,alias:"string"}}},{pattern:/`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,greedy:!0,inside:{interpolation:n,command:{pattern:/[\s\S]+/,alias:"string"}}}]}),delete t.languages.ruby.string,t.languages.insertBefore("ruby","number",{builtin:/\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,constant:/\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/}),t.languages.rb=t.languages.ruby}(e)}rk.displayName="rust";rk.aliases=[];function rk(e){(function(t){for(var n=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,r=0;r<2;r++)n=n.replace(/<self>/g,function(){return n});n=n.replace(/<self>/g,function(){return/[^\s\S]/.source}),t.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+n),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},t.languages.rust["closure-params"].inside.rest=t.languages.rust,t.languages.rust.attribute.inside.string=t.languages.rust.string})(e)}ok.displayName="sass";ok.aliases=[];function ok(e){e.register(v1),function(t){t.languages.sass=t.languages.extend("css",{comment:{pattern:/^([ \t]*)\/[\/*].*(?:(?:\r?\n|\r)\1[ \t].+)*/m,lookbehind:!0,greedy:!0}}),t.languages.insertBefore("sass","atrule",{"atrule-line":{pattern:/^(?:[ \t]*)[@+=].+/m,greedy:!0,inside:{atrule:/(?:@[\w-]+|[+=])/}}}),delete t.languages.sass.atrule;var n=/\$[-\w]+|#\{\$[-\w]+\}/,r=[/[+*\/%]|[=!]=|<=?|>=?|\b(?:and|not|or)\b/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}];t.languages.insertBefore("sass","property",{"variable-line":{pattern:/^[ \t]*\$.+/m,greedy:!0,inside:{punctuation:/:/,variable:n,operator:r}},"property-line":{pattern:/^[ \t]*(?:[^:\s]+ *:.*|:[^:\s].*)/m,greedy:!0,inside:{property:[/[^:\s]+(?=\s*:)/,{pattern:/(:)[^:\s]+/,lookbehind:!0}],punctuation:/:/,variable:n,operator:r,important:t.languages.sass.important}}}),delete t.languages.sass.property,delete t.languages.sass.important,t.languages.insertBefore("sass","punctuation",{selector:{pattern:/^([ \t]*)\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*(?:,(?:\r?\n|\r)\1[ \t]+\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*)*/m,lookbehind:!0,greedy:!0}})}(e)}ik.displayName="scss";ik.aliases=[];function ik(e){e.register(v1),e.languages.scss=e.languages.extend("css",{comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0},atrule:{pattern:/@[\w-](?:\([^()]+\)|[^()\s]|\s+(?!\s))*?(?=\s+[{;])/,inside:{rule:/@[\w-]+/}},url:/(?:[-a-z]+-)?url(?=\()/i,selector:{pattern:/(?=\S)[^@;{}()]?(?:[^@;{}()\s]|\s+(?!\s)|#\{\$[-\w]+\})+(?=\s*\{(?:\}|\s|[^}][^:{}]*[:{][^}]))/,inside:{parent:{pattern:/&/,alias:"important"},placeholder:/%[-\w]+/,variable:/\$[-\w]+|#\{\$[-\w]+\}/}},property:{pattern:/(?:[-\w]|\$[-\w]|#\{\$[-\w]+\})+(?=\s*:)/,inside:{variable:/\$[-\w]+|#\{\$[-\w]+\}/}}}),e.languages.insertBefore("scss","atrule",{keyword:[/@(?:content|debug|each|else(?: if)?|extend|for|forward|function|if|import|include|mixin|return|use|warn|while)\b/i,{pattern:/( )(?:from|through)(?= )/,lookbehind:!0}]}),e.languages.insertBefore("scss","important",{variable:/\$[-\w]+|#\{\$[-\w]+\}/}),e.languages.insertBefore("scss","function",{"module-modifier":{pattern:/\b(?:as|hide|show|with)\b/i,alias:"keyword"},placeholder:{pattern:/%[-\w]+/,alias:"selector"},statement:{pattern:/\B!(?:default|optional)\b/i,alias:"keyword"},boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"},operator:{pattern:/(\s)(?:[-+*\/%]|[=!]=|<=?|>=?|and|not|or)(?=\s)/,lookbehind:!0}}),e.languages.scss.atrule.inside.rest=e.languages.scss}ak.displayName="sql";ak.aliases=[];function ak(e){e.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/}}sk.displayName="swift";sk.aliases=[];function sk(e){e.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+(/(?:elseif|if)\b/.source+"(?:[ ]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+")+"|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},e.languages.swift["string-literal"].forEach(function(t){t.inside.interpolation.inside=e.languages.swift})}lk.displayName="typescript";lk.aliases=["ts"];function lk(e){e.register(Iy),function(t){t.languages.typescript=t.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),t.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete t.languages.typescript.parameter,delete t.languages.typescript["literal-property"];var n=t.languages.extend("typescript",{});delete n["class-name"],t.languages.typescript["class-name"].inside=n,t.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:n}}}}),t.languages.ts=t.languages.typescript}(e)}Ry.displayName="basic";Ry.aliases=[];function Ry(e){e.languages.basic={comment:{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},string:{pattern:/"(?:""|[!#$%&'()*,\/:;<=>?^\w +\-.])*"/,greedy:!0},number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,keyword:/\b(?:AS|BEEP|BLOAD|BSAVE|CALL(?: ABSOLUTE)?|CASE|CHAIN|CHDIR|CLEAR|CLOSE|CLS|COM|COMMON|CONST|DATA|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DIM|DO|DOUBLE|ELSE|ELSEIF|END|ENVIRON|ERASE|ERROR|EXIT|FIELD|FILES|FOR|FUNCTION|GET|GOSUB|GOTO|IF|INPUT|INTEGER|IOCTL|KEY|KILL|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|MKDIR|NAME|NEXT|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPTION BASE|OUT|POKE|PUT|READ|REDIM|REM|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SELECT CASE|SHARED|SHELL|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|SUB|SWAP|SYSTEM|THEN|TIMER|TO|TROFF|TRON|TYPE|UNLOCK|UNTIL|USING|VIEW PRINT|WAIT|WEND|WHILE|WRITE)(?:\$|\b)/i,function:/\b(?:ABS|ACCESS|ACOS|ANGLE|AREA|ARITHMETIC|ARRAY|ASIN|ASK|AT|ATN|BASE|BEGIN|BREAK|CAUSE|CEIL|CHR|CLIP|COLLATE|COLOR|CON|COS|COSH|COT|CSC|DATE|DATUM|DEBUG|DECIMAL|DEF|DEG|DEGREES|DELETE|DET|DEVICE|DISPLAY|DOT|ELAPSED|EPS|ERASABLE|EXLINE|EXP|EXTERNAL|EXTYPE|FILETYPE|FIXED|FP|GO|GRAPH|HANDLER|IDN|IMAGE|IN|INT|INTERNAL|IP|IS|KEYED|LBOUND|LCASE|LEFT|LEN|LENGTH|LET|LINE|LINES|LOG|LOG10|LOG2|LTRIM|MARGIN|MAT|MAX|MAXNUM|MID|MIN|MISSING|MOD|NATIVE|NUL|NUMERIC|OF|OPTION|ORD|ORGANIZATION|OUTIN|OUTPUT|PI|POINT|POINTER|POINTS|POS|PRINT|PROGRAM|PROMPT|RAD|RADIANS|RANDOMIZE|RECORD|RECSIZE|RECTYPE|RELATIVE|REMAINDER|REPEAT|REST|RETRY|REWRITE|RIGHT|RND|ROUND|RTRIM|SAME|SEC|SELECT|SEQUENTIAL|SET|SETTER|SGN|SIN|SINH|SIZE|SKIP|SQR|STANDARD|STATUS|STR|STREAM|STYLE|TAB|TAN|TANH|TEMPLATE|TEXT|THERE|TIME|TIMEOUT|TRACE|TRANSFORM|TRUNCATE|UBOUND|UCASE|USE|VAL|VARIABLE|VIEWPORT|WHEN|WINDOW|WITH|ZER|ZONEWIDTH)(?:\$|\b)/i,operator:/<[=>]?|>=?|[+\-*\/^=&]|\b(?:AND|EQV|IMP|NOT|OR|XOR)\b/i,punctuation:/[,;:()]/}}uk.displayName="vbnet";uk.aliases=[];function uk(e){e.register(Ry),e.languages.vbnet=e.languages.extend("basic",{comment:[{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},{pattern:/(^|[^\\:])'.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(^|[^"])"(?:""|[^"])*"(?!")/,lookbehind:!0,greedy:!0},keyword:/(?:\b(?:ADDHANDLER|ADDRESSOF|ALIAS|AND|ANDALSO|AS|BEEP|BLOAD|BOOLEAN|BSAVE|BYREF|BYTE|BYVAL|CALL(?: ABSOLUTE)?|CASE|CATCH|CBOOL|CBYTE|CCHAR|CDATE|CDBL|CDEC|CHAIN|CHAR|CHDIR|CINT|CLASS|CLEAR|CLNG|CLOSE|CLS|COBJ|COM|COMMON|CONST|CONTINUE|CSBYTE|CSHORT|CSNG|CSTR|CTYPE|CUINT|CULNG|CUSHORT|DATA|DATE|DECIMAL|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DEFAULT|DELEGATE|DIM|DIRECTCAST|DO|DOUBLE|ELSE|ELSEIF|END|ENUM|ENVIRON|ERASE|ERROR|EVENT|EXIT|FALSE|FIELD|FILES|FINALLY|FOR(?: EACH)?|FRIEND|FUNCTION|GET|GETTYPE|GETXMLNAMESPACE|GLOBAL|GOSUB|GOTO|HANDLES|IF|IMPLEMENTS|IMPORTS|IN|INHERITS|INPUT|INTEGER|INTERFACE|IOCTL|IS|ISNOT|KEY|KILL|LET|LIB|LIKE|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|ME|MKDIR|MOD|MODULE|MUSTINHERIT|MUSTOVERRIDE|MYBASE|MYCLASS|NAME|NAMESPACE|NARROWING|NEW|NEXT|NOT|NOTHING|NOTINHERITABLE|NOTOVERRIDABLE|OBJECT|OF|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPERATOR|OPTION(?: BASE)?|OPTIONAL|OR|ORELSE|OUT|OVERLOADS|OVERRIDABLE|OVERRIDES|PARAMARRAY|PARTIAL|POKE|PRIVATE|PROPERTY|PROTECTED|PUBLIC|PUT|RAISEEVENT|READ|READONLY|REDIM|REM|REMOVEHANDLER|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SBYTE|SELECT(?: CASE)?|SET|SHADOWS|SHARED|SHELL|SHORT|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|STRUCTURE|SUB|SWAP|SYNCLOCK|SYSTEM|THEN|THROW|TIMER|TO|TROFF|TRON|TRUE|TRY|TRYCAST|TYPE|TYPEOF|UINTEGER|ULONG|UNLOCK|UNTIL|USHORT|USING|VIEW PRINT|WAIT|WEND|WHEN|WHILE|WIDENING|WITH|WITHEVENTS|WRITE|WRITEONLY|XOR)|\B(?:#CONST|#ELSE|#ELSEIF|#END|#IF))(?:\$|\b)/i,punctuation:/[,;:(){}]/})}Ze.register(bs);Ze.register(Ap);Ze.register(Fy);Ze.register(Pw);Ze.register(Mw);Ze.register(Lw);Ze.register(Np);Ze.register(v1);Ze.register(jw);Ze.register(zw);Ze.register(Hw);Ze.register(Uw);Ze.register(qw);Ze.register(Iy);Ze.register($w);Ze.register(Ww);Ze.register(Gw);Ze.register(Kw);Ze.register(Vw);Ze.register(Yw);Ze.register(Qw);Ze.register(Xw);Ze.register(Zw);Ze.register(By);Ze.register(Jw);Ze.register(ek);Ze.register(tk);Ze.register(nk);Ze.register(rk);Ze.register(ok);Ze.register(ik);Ze.register(ak);Ze.register(sk);Ze.register(lk);Ze.register(Ry);Ze.register(uk);var cL=TEe(Ze,QEe);cL.supportedLanguages=wEe;const XEe=cL;var fL={exports:{}};(function(e,t){(function(n,r){e.exports=r(T)})(Mf,function(n){return function(r){var o={};function i(a){if(o[a])return o[a].exports;var s=o[a]={i:a,l:!1,exports:{}};return r[a].call(s.exports,s,s.exports,i),s.l=!0,s.exports}return i.m=r,i.c=o,i.d=function(a,s,l){i.o(a,s)||Object.defineProperty(a,s,{enumerable:!0,get:l})},i.r=function(a){typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(a,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(a,"__esModule",{value:!0})},i.t=function(a,s){if(1&s&&(a=i(a)),8&s||4&s&&typeof a=="object"&&a&&a.__esModule)return a;var l=Object.create(null);if(i.r(l),Object.defineProperty(l,"default",{enumerable:!0,value:a}),2&s&&typeof a!="string")for(var u in a)i.d(l,u,function(d){return a[d]}.bind(null,u));return l},i.n=function(a){var s=a&&a.__esModule?function(){return a.default}:function(){return a};return i.d(s,"a",s),s},i.o=function(a,s){return Object.prototype.hasOwnProperty.call(a,s)},i.p="",i(i.s=48)}([function(r,o){r.exports=n},function(r,o){var i=r.exports={version:"2.6.12"};typeof __e=="number"&&(__e=i)},function(r,o,i){var a=i(26)("wks"),s=i(17),l=i(3).Symbol,u=typeof l=="function";(r.exports=function(d){return a[d]||(a[d]=u&&l[d]||(u?l:s)("Symbol."+d))}).store=a},function(r,o){var i=r.exports=typeof window<"u"&&window.Math==Math?window:typeof self<"u"&&self.Math==Math?self:Function("return this")();typeof __g=="number"&&(__g=i)},function(r,o,i){r.exports=!i(8)(function(){return Object.defineProperty({},"a",{get:function(){return 7}}).a!=7})},function(r,o){var i={}.hasOwnProperty;r.exports=function(a,s){return i.call(a,s)}},function(r,o,i){var a=i(7),s=i(16);r.exports=i(4)?function(l,u,d){return a.f(l,u,s(1,d))}:function(l,u,d){return l[u]=d,l}},function(r,o,i){var a=i(10),s=i(35),l=i(23),u=Object.defineProperty;o.f=i(4)?Object.defineProperty:function(d,h,p){if(a(d),h=l(h,!0),a(p),s)try{return u(d,h,p)}catch{}if("get"in p||"set"in p)throw TypeError("Accessors not supported!");return"value"in p&&(d[h]=p.value),d}},function(r,o){r.exports=function(i){try{return!!i()}catch{return!0}}},function(r,o,i){var a=i(40),s=i(22);r.exports=function(l){return a(s(l))}},function(r,o,i){var a=i(11);r.exports=function(s){if(!a(s))throw TypeError(s+" is not an object!");return s}},function(r,o){r.exports=function(i){return typeof i=="object"?i!==null:typeof i=="function"}},function(r,o){r.exports={}},function(r,o,i){var a=i(39),s=i(27);r.exports=Object.keys||function(l){return a(l,s)}},function(r,o){r.exports=!0},function(r,o,i){var a=i(3),s=i(1),l=i(53),u=i(6),d=i(5),h=function(p,m,v){var _,b,E,w=p&h.F,k=p&h.G,y=p&h.S,F=p&h.P,C=p&h.B,A=p&h.W,P=k?s:s[m]||(s[m]={}),I=P.prototype,j=k?a:y?a[m]:(a[m]||{}).prototype;for(_ in k&&(v=m),v)(b=!w&&j&&j[_]!==void 0)&&d(P,_)||(E=b?j[_]:v[_],P[_]=k&&typeof j[_]!="function"?v[_]:C&&b?l(E,a):A&&j[_]==E?function(H){var K=function(U,pe,se){if(this instanceof H){switch(arguments.length){case 0:return new H;case 1:return new H(U);case 2:return new H(U,pe)}return new H(U,pe,se)}return H.apply(this,arguments)};return K.prototype=H.prototype,K}(E):F&&typeof E=="function"?l(Function.call,E):E,F&&((P.virtual||(P.virtual={}))[_]=E,p&h.R&&I&&!I[_]&&u(I,_,E)))};h.F=1,h.G=2,h.S=4,h.P=8,h.B=16,h.W=32,h.U=64,h.R=128,r.exports=h},function(r,o){r.exports=function(i,a){return{enumerable:!(1&i),configurable:!(2&i),writable:!(4&i),value:a}}},function(r,o){var i=0,a=Math.random();r.exports=function(s){return"Symbol(".concat(s===void 0?"":s,")_",(++i+a).toString(36))}},function(r,o,i){var a=i(22);r.exports=function(s){return Object(a(s))}},function(r,o){o.f={}.propertyIsEnumerable},function(r,o,i){var a=i(52)(!0);i(34)(String,"String",function(s){this._t=String(s),this._i=0},function(){var s,l=this._t,u=this._i;return u>=l.length?{value:void 0,done:!0}:(s=a(l,u),this._i+=s.length,{value:s,done:!1})})},function(r,o){var i=Math.ceil,a=Math.floor;r.exports=function(s){return isNaN(s=+s)?0:(s>0?a:i)(s)}},function(r,o){r.exports=function(i){if(i==null)throw TypeError("Can't call method on "+i);return i}},function(r,o,i){var a=i(11);r.exports=function(s,l){if(!a(s))return s;var u,d;if(l&&typeof(u=s.toString)=="function"&&!a(d=u.call(s))||typeof(u=s.valueOf)=="function"&&!a(d=u.call(s))||!l&&typeof(u=s.toString)=="function"&&!a(d=u.call(s)))return d;throw TypeError("Can't convert object to primitive value")}},function(r,o){var i={}.toString;r.exports=function(a){return i.call(a).slice(8,-1)}},function(r,o,i){var a=i(26)("keys"),s=i(17);r.exports=function(l){return a[l]||(a[l]=s(l))}},function(r,o,i){var a=i(1),s=i(3),l=s["__core-js_shared__"]||(s["__core-js_shared__"]={});(r.exports=function(u,d){return l[u]||(l[u]=d!==void 0?d:{})})("versions",[]).push({version:a.version,mode:i(14)?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},function(r,o){r.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(r,o,i){var a=i(7).f,s=i(5),l=i(2)("toStringTag");r.exports=function(u,d,h){u&&!s(u=h?u:u.prototype,l)&&a(u,l,{configurable:!0,value:d})}},function(r,o,i){i(62);for(var a=i(3),s=i(6),l=i(12),u=i(2)("toStringTag"),d="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),h=0;h<d.length;h++){var p=d[h],m=a[p],v=m&&m.prototype;v&&!v[u]&&s(v,u,p),l[p]=l.Array}},function(r,o,i){o.f=i(2)},function(r,o,i){var a=i(3),s=i(1),l=i(14),u=i(30),d=i(7).f;r.exports=function(h){var p=s.Symbol||(s.Symbol=l?{}:a.Symbol||{});h.charAt(0)=="_"||h in p||d(p,h,{value:u.f(h)})}},function(r,o){o.f=Object.getOwnPropertySymbols},function(r,o){r.exports=function(i,a,s){return Math.min(Math.max(i,a),s)}},function(r,o,i){var a=i(14),s=i(15),l=i(37),u=i(6),d=i(12),h=i(55),p=i(28),m=i(61),v=i(2)("iterator"),_=!([].keys&&"next"in[].keys()),b=function(){return this};r.exports=function(E,w,k,y,F,C,A){h(k,w,y);var P,I,j,H=function(fe){if(!_&&fe in se)return se[fe];switch(fe){case"keys":case"values":return function(){return new k(this,fe)}}return function(){return new k(this,fe)}},K=w+" Iterator",U=F=="values",pe=!1,se=E.prototype,J=se[v]||se["@@iterator"]||F&&se[F],$=J||H(F),_e=F?U?H("entries"):$:void 0,ve=w=="Array"&&se.entries||J;if(ve&&(j=m(ve.call(new E)))!==Object.prototype&&j.next&&(p(j,K,!0),a||typeof j[v]=="function"||u(j,v,b)),U&&J&&J.name!=="values"&&(pe=!0,$=function(){return J.call(this)}),a&&!A||!_&&!pe&&se[v]||u(se,v,$),d[w]=$,d[K]=b,F)if(P={values:U?$:H("values"),keys:C?$:H("keys"),entries:_e},A)for(I in P)I in se||l(se,I,P[I]);else s(s.P+s.F*(_||pe),w,P);return P}},function(r,o,i){r.exports=!i(4)&&!i(8)(function(){return Object.defineProperty(i(36)("div"),"a",{get:function(){return 7}}).a!=7})},function(r,o,i){var a=i(11),s=i(3).document,l=a(s)&&a(s.createElement);r.exports=function(u){return l?s.createElement(u):{}}},function(r,o,i){r.exports=i(6)},function(r,o,i){var a=i(10),s=i(56),l=i(27),u=i(25)("IE_PROTO"),d=function(){},h=function(){var p,m=i(36)("iframe"),v=l.length;for(m.style.display="none",i(60).appendChild(m),m.src="javascript:",(p=m.contentWindow.document).open(),p.write("<script>document.F=Object<\/script>"),p.close(),h=p.F;v--;)delete h.prototype[l[v]];return h()};r.exports=Object.create||function(p,m){var v;return p!==null?(d.prototype=a(p),v=new d,d.prototype=null,v[u]=p):v=h(),m===void 0?v:s(v,m)}},function(r,o,i){var a=i(5),s=i(9),l=i(57)(!1),u=i(25)("IE_PROTO");r.exports=function(d,h){var p,m=s(d),v=0,_=[];for(p in m)p!=u&&a(m,p)&&_.push(p);for(;h.length>v;)a(m,p=h[v++])&&(~l(_,p)||_.push(p));return _}},function(r,o,i){var a=i(24);r.exports=Object("z").propertyIsEnumerable(0)?Object:function(s){return a(s)=="String"?s.split(""):Object(s)}},function(r,o,i){var a=i(39),s=i(27).concat("length","prototype");o.f=Object.getOwnPropertyNames||function(l){return a(l,s)}},function(r,o,i){var a=i(24),s=i(2)("toStringTag"),l=a(function(){return arguments}())=="Arguments";r.exports=function(u){var d,h,p;return u===void 0?"Undefined":u===null?"Null":typeof(h=function(m,v){try{return m[v]}catch{}}(d=Object(u),s))=="string"?h:l?a(d):(p=a(d))=="Object"&&typeof d.callee=="function"?"Arguments":p}},function(r,o){var i;i=function(){return this}();try{i=i||new Function("return this")()}catch{typeof window=="object"&&(i=window)}r.exports=i},function(r,o){var i=/-?\d+(\.\d+)?%?/g;r.exports=function(a){return a.match(i)}},function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.getBase16Theme=o.createStyling=o.invertTheme=void 0;var a=b(i(49)),s=b(i(76)),l=b(i(81)),u=b(i(89)),d=b(i(93)),h=function(I){if(I&&I.__esModule)return I;var j={};if(I!=null)for(var H in I)Object.prototype.hasOwnProperty.call(I,H)&&(j[H]=I[H]);return j.default=I,j}(i(94)),p=b(i(132)),m=b(i(133)),v=b(i(138)),_=i(139);function b(I){return I&&I.__esModule?I:{default:I}}var E=h.default,w=(0,u.default)(E),k=(0,v.default)(m.default,_.rgb2yuv,function(I){var j,H=(0,l.default)(I,3),K=H[0],U=H[1],pe=H[2];return[(j=K,j<.25?1:j<.5?.9-j:1.1-j),U,pe]},_.yuv2rgb,p.default),y=function(I){return function(j){return{className:[j.className,I.className].filter(Boolean).join(" "),style:(0,s.default)({},j.style||{},I.style||{})}}},F=function(I,j){var H=(0,u.default)(j);for(var K in I)H.indexOf(K)===-1&&H.push(K);return H.reduce(function(U,pe){return U[pe]=function(se,J){if(se===void 0)return J;if(J===void 0)return se;var $=se===void 0?"undefined":(0,a.default)(se),_e=J===void 0?"undefined":(0,a.default)(J);switch($){case"string":switch(_e){case"string":return[J,se].filter(Boolean).join(" ");case"object":return y({className:se,style:J});case"function":return function(ve){for(var fe=arguments.length,R=Array(fe>1?fe-1:0),L=1;L<fe;L++)R[L-1]=arguments[L];return y({className:se})(J.apply(void 0,[ve].concat(R)))}}case"object":switch(_e){case"string":return y({className:J,style:se});case"object":return(0,s.default)({},J,se);case"function":return function(ve){for(var fe=arguments.length,R=Array(fe>1?fe-1:0),L=1;L<fe;L++)R[L-1]=arguments[L];return y({style:se})(J.apply(void 0,[ve].concat(R)))}}case"function":switch(_e){case"string":return function(ve){for(var fe=arguments.length,R=Array(fe>1?fe-1:0),L=1;L<fe;L++)R[L-1]=arguments[L];return se.apply(void 0,[y(ve)({className:J})].concat(R))};case"object":return function(ve){for(var fe=arguments.length,R=Array(fe>1?fe-1:0),L=1;L<fe;L++)R[L-1]=arguments[L];return se.apply(void 0,[y(ve)({style:J})].concat(R))};case"function":return function(ve){for(var fe=arguments.length,R=Array(fe>1?fe-1:0),L=1;L<fe;L++)R[L-1]=arguments[L];return se.apply(void 0,[J.apply(void 0,[ve].concat(R))].concat(R))}}}}(I[pe],j[pe]),U},{})},C=function(I,j){for(var H=arguments.length,K=Array(H>2?H-2:0),U=2;U<H;U++)K[U-2]=arguments[U];if(j===null)return I;Array.isArray(j)||(j=[j]);var pe=j.map(function(J){return I[J]}).filter(Boolean),se=pe.reduce(function(J,$){return typeof $=="string"?J.className=[J.className,$].filter(Boolean).join(" "):($===void 0?"undefined":(0,a.default)($))==="object"?J.style=(0,s.default)({},J.style,$):typeof $=="function"&&(J=(0,s.default)({},J,$.apply(void 0,[J].concat(K)))),J},{className:"",style:{}});return se.className||delete se.className,(0,u.default)(se.style).length===0&&delete se.style,se},A=o.invertTheme=function(I){return(0,u.default)(I).reduce(function(j,H){return j[H]=/^base/.test(H)?k(I[H]):H==="scheme"?I[H]+":inverted":I[H],j},{})},P=(o.createStyling=(0,d.default)(function(I){for(var j=arguments.length,H=Array(j>3?j-3:0),K=3;K<j;K++)H[K-3]=arguments[K];var U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},pe=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},se=U.defaultBase16,J=se===void 0?E:se,$=U.base16Themes,_e=$===void 0?null:$,ve=P(pe,_e);ve&&(pe=(0,s.default)({},ve,pe));var fe=w.reduce(function(Ue,Ve){return Ue[Ve]=pe[Ve]||J[Ve],Ue},{}),R=(0,u.default)(pe).reduce(function(Ue,Ve){return w.indexOf(Ve)===-1&&(Ue[Ve]=pe[Ve]),Ue},{}),L=I(fe),Ae=F(R,L);return(0,d.default)(C,2).apply(void 0,[Ae].concat(H))},3),o.getBase16Theme=function(I,j){if(I&&I.extend&&(I=I.extend),typeof I=="string"){var H=I.split(":"),K=(0,l.default)(H,2),U=K[0],pe=K[1];I=(j||{})[U]||h[U],pe==="inverted"&&(I=A(I))}return I&&I.hasOwnProperty("base00")?I:void 0})},function(r,o,i){var a,s=typeof Reflect=="object"?Reflect:null,l=s&&typeof s.apply=="function"?s.apply:function(y,F,C){return Function.prototype.apply.call(y,F,C)};a=s&&typeof s.ownKeys=="function"?s.ownKeys:Object.getOwnPropertySymbols?function(y){return Object.getOwnPropertyNames(y).concat(Object.getOwnPropertySymbols(y))}:function(y){return Object.getOwnPropertyNames(y)};var u=Number.isNaN||function(y){return y!=y};function d(){d.init.call(this)}r.exports=d,r.exports.once=function(y,F){return new Promise(function(C,A){function P(){I!==void 0&&y.removeListener("error",I),C([].slice.call(arguments))}var I;F!=="error"&&(I=function(j){y.removeListener(F,P),A(j)},y.once("error",I)),y.once(F,P)})},d.EventEmitter=d,d.prototype._events=void 0,d.prototype._eventsCount=0,d.prototype._maxListeners=void 0;var h=10;function p(y){if(typeof y!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof y)}function m(y){return y._maxListeners===void 0?d.defaultMaxListeners:y._maxListeners}function v(y,F,C,A){var P,I,j,H;if(p(C),(I=y._events)===void 0?(I=y._events=Object.create(null),y._eventsCount=0):(I.newListener!==void 0&&(y.emit("newListener",F,C.listener?C.listener:C),I=y._events),j=I[F]),j===void 0)j=I[F]=C,++y._eventsCount;else if(typeof j=="function"?j=I[F]=A?[C,j]:[j,C]:A?j.unshift(C):j.push(C),(P=m(y))>0&&j.length>P&&!j.warned){j.warned=!0;var K=new Error("Possible EventEmitter memory leak detected. "+j.length+" "+String(F)+" listeners added. Use emitter.setMaxListeners() to increase limit");K.name="MaxListenersExceededWarning",K.emitter=y,K.type=F,K.count=j.length,H=K,console&&console.warn&&console.warn(H)}return y}function _(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function b(y,F,C){var A={fired:!1,wrapFn:void 0,target:y,type:F,listener:C},P=_.bind(A);return P.listener=C,A.wrapFn=P,P}function E(y,F,C){var A=y._events;if(A===void 0)return[];var P=A[F];return P===void 0?[]:typeof P=="function"?C?[P.listener||P]:[P]:C?function(I){for(var j=new Array(I.length),H=0;H<j.length;++H)j[H]=I[H].listener||I[H];return j}(P):k(P,P.length)}function w(y){var F=this._events;if(F!==void 0){var C=F[y];if(typeof C=="function")return 1;if(C!==void 0)return C.length}return 0}function k(y,F){for(var C=new Array(F),A=0;A<F;++A)C[A]=y[A];return C}Object.defineProperty(d,"defaultMaxListeners",{enumerable:!0,get:function(){return h},set:function(y){if(typeof y!="number"||y<0||u(y))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+y+".");h=y}}),d.init=function(){this._events!==void 0&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},d.prototype.setMaxListeners=function(y){if(typeof y!="number"||y<0||u(y))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+y+".");return this._maxListeners=y,this},d.prototype.getMaxListeners=function(){return m(this)},d.prototype.emit=function(y){for(var F=[],C=1;C<arguments.length;C++)F.push(arguments[C]);var A=y==="error",P=this._events;if(P!==void 0)A=A&&P.error===void 0;else if(!A)return!1;if(A){var I;if(F.length>0&&(I=F[0]),I instanceof Error)throw I;var j=new Error("Unhandled error."+(I?" ("+I.message+")":""));throw j.context=I,j}var H=P[y];if(H===void 0)return!1;if(typeof H=="function")l(H,this,F);else{var K=H.length,U=k(H,K);for(C=0;C<K;++C)l(U[C],this,F)}return!0},d.prototype.addListener=function(y,F){return v(this,y,F,!1)},d.prototype.on=d.prototype.addListener,d.prototype.prependListener=function(y,F){return v(this,y,F,!0)},d.prototype.once=function(y,F){return p(F),this.on(y,b(this,y,F)),this},d.prototype.prependOnceListener=function(y,F){return p(F),this.prependListener(y,b(this,y,F)),this},d.prototype.removeListener=function(y,F){var C,A,P,I,j;if(p(F),(A=this._events)===void 0)return this;if((C=A[y])===void 0)return this;if(C===F||C.listener===F)--this._eventsCount==0?this._events=Object.create(null):(delete A[y],A.removeListener&&this.emit("removeListener",y,C.listener||F));else if(typeof C!="function"){for(P=-1,I=C.length-1;I>=0;I--)if(C[I]===F||C[I].listener===F){j=C[I].listener,P=I;break}if(P<0)return this;P===0?C.shift():function(H,K){for(;K+1<H.length;K++)H[K]=H[K+1];H.pop()}(C,P),C.length===1&&(A[y]=C[0]),A.removeListener!==void 0&&this.emit("removeListener",y,j||F)}return this},d.prototype.off=d.prototype.removeListener,d.prototype.removeAllListeners=function(y){var F,C,A;if((C=this._events)===void 0)return this;if(C.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):C[y]!==void 0&&(--this._eventsCount==0?this._events=Object.create(null):delete C[y]),this;if(arguments.length===0){var P,I=Object.keys(C);for(A=0;A<I.length;++A)(P=I[A])!=="removeListener"&&this.removeAllListeners(P);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(typeof(F=C[y])=="function")this.removeListener(y,F);else if(F!==void 0)for(A=F.length-1;A>=0;A--)this.removeListener(y,F[A]);return this},d.prototype.listeners=function(y){return E(this,y,!0)},d.prototype.rawListeners=function(y){return E(this,y,!1)},d.listenerCount=function(y,F){return typeof y.listenerCount=="function"?y.listenerCount(F):w.call(y,F)},d.prototype.listenerCount=w,d.prototype.eventNames=function(){return this._eventsCount>0?a(this._events):[]}},function(r,o,i){r.exports.Dispatcher=i(140)},function(r,o,i){r.exports=i(142)},function(r,o,i){o.__esModule=!0;var a=u(i(50)),s=u(i(65)),l=typeof s.default=="function"&&typeof a.default=="symbol"?function(d){return typeof d}:function(d){return d&&typeof s.default=="function"&&d.constructor===s.default&&d!==s.default.prototype?"symbol":typeof d};function u(d){return d&&d.__esModule?d:{default:d}}o.default=typeof s.default=="function"&&l(a.default)==="symbol"?function(d){return d===void 0?"undefined":l(d)}:function(d){return d&&typeof s.default=="function"&&d.constructor===s.default&&d!==s.default.prototype?"symbol":d===void 0?"undefined":l(d)}},function(r,o,i){r.exports={default:i(51),__esModule:!0}},function(r,o,i){i(20),i(29),r.exports=i(30).f("iterator")},function(r,o,i){var a=i(21),s=i(22);r.exports=function(l){return function(u,d){var h,p,m=String(s(u)),v=a(d),_=m.length;return v<0||v>=_?l?"":void 0:(h=m.charCodeAt(v))<55296||h>56319||v+1===_||(p=m.charCodeAt(v+1))<56320||p>57343?l?m.charAt(v):h:l?m.slice(v,v+2):p-56320+(h-55296<<10)+65536}}},function(r,o,i){var a=i(54);r.exports=function(s,l,u){if(a(s),l===void 0)return s;switch(u){case 1:return function(d){return s.call(l,d)};case 2:return function(d,h){return s.call(l,d,h)};case 3:return function(d,h,p){return s.call(l,d,h,p)}}return function(){return s.apply(l,arguments)}}},function(r,o){r.exports=function(i){if(typeof i!="function")throw TypeError(i+" is not a function!");return i}},function(r,o,i){var a=i(38),s=i(16),l=i(28),u={};i(6)(u,i(2)("iterator"),function(){return this}),r.exports=function(d,h,p){d.prototype=a(u,{next:s(1,p)}),l(d,h+" Iterator")}},function(r,o,i){var a=i(7),s=i(10),l=i(13);r.exports=i(4)?Object.defineProperties:function(u,d){s(u);for(var h,p=l(d),m=p.length,v=0;m>v;)a.f(u,h=p[v++],d[h]);return u}},function(r,o,i){var a=i(9),s=i(58),l=i(59);r.exports=function(u){return function(d,h,p){var m,v=a(d),_=s(v.length),b=l(p,_);if(u&&h!=h){for(;_>b;)if((m=v[b++])!=m)return!0}else for(;_>b;b++)if((u||b in v)&&v[b]===h)return u||b||0;return!u&&-1}}},function(r,o,i){var a=i(21),s=Math.min;r.exports=function(l){return l>0?s(a(l),9007199254740991):0}},function(r,o,i){var a=i(21),s=Math.max,l=Math.min;r.exports=function(u,d){return(u=a(u))<0?s(u+d,0):l(u,d)}},function(r,o,i){var a=i(3).document;r.exports=a&&a.documentElement},function(r,o,i){var a=i(5),s=i(18),l=i(25)("IE_PROTO"),u=Object.prototype;r.exports=Object.getPrototypeOf||function(d){return d=s(d),a(d,l)?d[l]:typeof d.constructor=="function"&&d instanceof d.constructor?d.constructor.prototype:d instanceof Object?u:null}},function(r,o,i){var a=i(63),s=i(64),l=i(12),u=i(9);r.exports=i(34)(Array,"Array",function(d,h){this._t=u(d),this._i=0,this._k=h},function(){var d=this._t,h=this._k,p=this._i++;return!d||p>=d.length?(this._t=void 0,s(1)):s(0,h=="keys"?p:h=="values"?d[p]:[p,d[p]])},"values"),l.Arguments=l.Array,a("keys"),a("values"),a("entries")},function(r,o){r.exports=function(){}},function(r,o){r.exports=function(i,a){return{value:a,done:!!i}}},function(r,o,i){r.exports={default:i(66),__esModule:!0}},function(r,o,i){i(67),i(73),i(74),i(75),r.exports=i(1).Symbol},function(r,o,i){var a=i(3),s=i(5),l=i(4),u=i(15),d=i(37),h=i(68).KEY,p=i(8),m=i(26),v=i(28),_=i(17),b=i(2),E=i(30),w=i(31),k=i(69),y=i(70),F=i(10),C=i(11),A=i(18),P=i(9),I=i(23),j=i(16),H=i(38),K=i(71),U=i(72),pe=i(32),se=i(7),J=i(13),$=U.f,_e=se.f,ve=K.f,fe=a.Symbol,R=a.JSON,L=R&&R.stringify,Ae=b("_hidden"),Ue=b("toPrimitive"),Ve={}.propertyIsEnumerable,Le=m("symbol-registry"),st=m("symbols"),We=m("op-symbols"),rt=Object.prototype,Zt=typeof fe=="function"&&!!pe.f,qn=a.QObject,er=!qn||!qn.prototype||!qn.prototype.findChild,tr=l&&p(function(){return H(_e({},"a",{get:function(){return _e(this,"a",{value:7}).a}})).a!=7})?function(ie,G,ae){var Te=$(rt,G);Te&&delete rt[G],_e(ie,G,ae),Te&&ie!==rt&&_e(rt,G,Te)}:_e,In=function(ie){var G=st[ie]=H(fe.prototype);return G._k=ie,G},br=Zt&&typeof fe.iterator=="symbol"?function(ie){return typeof ie=="symbol"}:function(ie){return ie instanceof fe},Nr=function(ie,G,ae){return ie===rt&&Nr(We,G,ae),F(ie),G=I(G,!0),F(ae),s(st,G)?(ae.enumerable?(s(ie,Ae)&&ie[Ae][G]&&(ie[Ae][G]=!1),ae=H(ae,{enumerable:j(0,!1)})):(s(ie,Ae)||_e(ie,Ae,j(1,{})),ie[Ae][G]=!0),tr(ie,G,ae)):_e(ie,G,ae)},an=function(ie,G){F(ie);for(var ae,Te=k(G=P(G)),Oe=0,$e=Te.length;$e>Oe;)Nr(ie,ae=Te[Oe++],G[ae]);return ie},yo=function(ie){var G=Ve.call(this,ie=I(ie,!0));return!(this===rt&&s(st,ie)&&!s(We,ie))&&(!(G||!s(this,ie)||!s(st,ie)||s(this,Ae)&&this[Ae][ie])||G)},Eo=function(ie,G){if(ie=P(ie),G=I(G,!0),ie!==rt||!s(st,G)||s(We,G)){var ae=$(ie,G);return!ae||!s(st,G)||s(ie,Ae)&&ie[Ae][G]||(ae.enumerable=!0),ae}},jr=function(ie){for(var G,ae=ve(P(ie)),Te=[],Oe=0;ae.length>Oe;)s(st,G=ae[Oe++])||G==Ae||G==h||Te.push(G);return Te},pn=function(ie){for(var G,ae=ie===rt,Te=ve(ae?We:P(ie)),Oe=[],$e=0;Te.length>$e;)!s(st,G=Te[$e++])||ae&&!s(rt,G)||Oe.push(st[G]);return Oe};Zt||(d((fe=function(){if(this instanceof fe)throw TypeError("Symbol is not a constructor!");var ie=_(arguments.length>0?arguments[0]:void 0),G=function(ae){this===rt&&G.call(We,ae),s(this,Ae)&&s(this[Ae],ie)&&(this[Ae][ie]=!1),tr(this,ie,j(1,ae))};return l&&er&&tr(rt,ie,{configurable:!0,set:G}),In(ie)}).prototype,"toString",function(){return this._k}),U.f=Eo,se.f=Nr,i(41).f=K.f=jr,i(19).f=yo,pe.f=pn,l&&!i(14)&&d(rt,"propertyIsEnumerable",yo,!0),E.f=function(ie){return In(b(ie))}),u(u.G+u.W+u.F*!Zt,{Symbol:fe});for(var Mn="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),mn=0;Mn.length>mn;)b(Mn[mn++]);for(var Po=J(b.store),me=0;Po.length>me;)w(Po[me++]);u(u.S+u.F*!Zt,"Symbol",{for:function(ie){return s(Le,ie+="")?Le[ie]:Le[ie]=fe(ie)},keyFor:function(ie){if(!br(ie))throw TypeError(ie+" is not a symbol!");for(var G in Le)if(Le[G]===ie)return G},useSetter:function(){er=!0},useSimple:function(){er=!1}}),u(u.S+u.F*!Zt,"Object",{create:function(ie,G){return G===void 0?H(ie):an(H(ie),G)},defineProperty:Nr,defineProperties:an,getOwnPropertyDescriptor:Eo,getOwnPropertyNames:jr,getOwnPropertySymbols:pn});var le=p(function(){pe.f(1)});u(u.S+u.F*le,"Object",{getOwnPropertySymbols:function(ie){return pe.f(A(ie))}}),R&&u(u.S+u.F*(!Zt||p(function(){var ie=fe();return L([ie])!="[null]"||L({a:ie})!="{}"||L(Object(ie))!="{}"})),"JSON",{stringify:function(ie){for(var G,ae,Te=[ie],Oe=1;arguments.length>Oe;)Te.push(arguments[Oe++]);if(ae=G=Te[1],(C(G)||ie!==void 0)&&!br(ie))return y(G)||(G=function($e,_t){if(typeof ae=="function"&&(_t=ae.call(this,$e,_t)),!br(_t))return _t}),Te[1]=G,L.apply(R,Te)}}),fe.prototype[Ue]||i(6)(fe.prototype,Ue,fe.prototype.valueOf),v(fe,"Symbol"),v(Math,"Math",!0),v(a.JSON,"JSON",!0)},function(r,o,i){var a=i(17)("meta"),s=i(11),l=i(5),u=i(7).f,d=0,h=Object.isExtensible||function(){return!0},p=!i(8)(function(){return h(Object.preventExtensions({}))}),m=function(_){u(_,a,{value:{i:"O"+ ++d,w:{}}})},v=r.exports={KEY:a,NEED:!1,fastKey:function(_,b){if(!s(_))return typeof _=="symbol"?_:(typeof _=="string"?"S":"P")+_;if(!l(_,a)){if(!h(_))return"F";if(!b)return"E";m(_)}return _[a].i},getWeak:function(_,b){if(!l(_,a)){if(!h(_))return!0;if(!b)return!1;m(_)}return _[a].w},onFreeze:function(_){return p&&v.NEED&&h(_)&&!l(_,a)&&m(_),_}}},function(r,o,i){var a=i(13),s=i(32),l=i(19);r.exports=function(u){var d=a(u),h=s.f;if(h)for(var p,m=h(u),v=l.f,_=0;m.length>_;)v.call(u,p=m[_++])&&d.push(p);return d}},function(r,o,i){var a=i(24);r.exports=Array.isArray||function(s){return a(s)=="Array"}},function(r,o,i){var a=i(9),s=i(41).f,l={}.toString,u=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];r.exports.f=function(d){return u&&l.call(d)=="[object Window]"?function(h){try{return s(h)}catch{return u.slice()}}(d):s(a(d))}},function(r,o,i){var a=i(19),s=i(16),l=i(9),u=i(23),d=i(5),h=i(35),p=Object.getOwnPropertyDescriptor;o.f=i(4)?p:function(m,v){if(m=l(m),v=u(v,!0),h)try{return p(m,v)}catch{}if(d(m,v))return s(!a.f.call(m,v),m[v])}},function(r,o){},function(r,o,i){i(31)("asyncIterator")},function(r,o,i){i(31)("observable")},function(r,o,i){o.__esModule=!0;var a,s=i(77),l=(a=s)&&a.__esModule?a:{default:a};o.default=l.default||function(u){for(var d=1;d<arguments.length;d++){var h=arguments[d];for(var p in h)Object.prototype.hasOwnProperty.call(h,p)&&(u[p]=h[p])}return u}},function(r,o,i){r.exports={default:i(78),__esModule:!0}},function(r,o,i){i(79),r.exports=i(1).Object.assign},function(r,o,i){var a=i(15);a(a.S+a.F,"Object",{assign:i(80)})},function(r,o,i){var a=i(4),s=i(13),l=i(32),u=i(19),d=i(18),h=i(40),p=Object.assign;r.exports=!p||i(8)(function(){var m={},v={},_=Symbol(),b="abcdefghijklmnopqrst";return m[_]=7,b.split("").forEach(function(E){v[E]=E}),p({},m)[_]!=7||Object.keys(p({},v)).join("")!=b})?function(m,v){for(var _=d(m),b=arguments.length,E=1,w=l.f,k=u.f;b>E;)for(var y,F=h(arguments[E++]),C=w?s(F).concat(w(F)):s(F),A=C.length,P=0;A>P;)y=C[P++],a&&!k.call(F,y)||(_[y]=F[y]);return _}:p},function(r,o,i){o.__esModule=!0;var a=l(i(82)),s=l(i(85));function l(u){return u&&u.__esModule?u:{default:u}}o.default=function(u,d){if(Array.isArray(u))return u;if((0,a.default)(Object(u)))return function(h,p){var m=[],v=!0,_=!1,b=void 0;try{for(var E,w=(0,s.default)(h);!(v=(E=w.next()).done)&&(m.push(E.value),!p||m.length!==p);v=!0);}catch(k){_=!0,b=k}finally{try{!v&&w.return&&w.return()}finally{if(_)throw b}}return m}(u,d);throw new TypeError("Invalid attempt to destructure non-iterable instance")}},function(r,o,i){r.exports={default:i(83),__esModule:!0}},function(r,o,i){i(29),i(20),r.exports=i(84)},function(r,o,i){var a=i(42),s=i(2)("iterator"),l=i(12);r.exports=i(1).isIterable=function(u){var d=Object(u);return d[s]!==void 0||"@@iterator"in d||l.hasOwnProperty(a(d))}},function(r,o,i){r.exports={default:i(86),__esModule:!0}},function(r,o,i){i(29),i(20),r.exports=i(87)},function(r,o,i){var a=i(10),s=i(88);r.exports=i(1).getIterator=function(l){var u=s(l);if(typeof u!="function")throw TypeError(l+" is not iterable!");return a(u.call(l))}},function(r,o,i){var a=i(42),s=i(2)("iterator"),l=i(12);r.exports=i(1).getIteratorMethod=function(u){if(u!=null)return u[s]||u["@@iterator"]||l[a(u)]}},function(r,o,i){r.exports={default:i(90),__esModule:!0}},function(r,o,i){i(91),r.exports=i(1).Object.keys},function(r,o,i){var a=i(18),s=i(13);i(92)("keys",function(){return function(l){return s(a(l))}})},function(r,o,i){var a=i(15),s=i(1),l=i(8);r.exports=function(u,d){var h=(s.Object||{})[u]||Object[u],p={};p[u]=d(h),a(a.S+a.F*l(function(){h(1)}),"Object",p)}},function(r,o,i){(function(a){var s=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],l=/^\s+|\s+$/g,u=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,d=/\{\n\/\* \[wrapped with (.+)\] \*/,h=/,? & /,p=/^[-+]0x[0-9a-f]+$/i,m=/^0b[01]+$/i,v=/^\[object .+?Constructor\]$/,_=/^0o[0-7]+$/i,b=/^(?:0|[1-9]\d*)$/,E=parseInt,w=typeof a=="object"&&a&&a.Object===Object&&a,k=typeof self=="object"&&self&&self.Object===Object&&self,y=w||k||Function("return this")();function F(me,le,ie){switch(ie.length){case 0:return me.call(le);case 1:return me.call(le,ie[0]);case 2:return me.call(le,ie[0],ie[1]);case 3:return me.call(le,ie[0],ie[1],ie[2])}return me.apply(le,ie)}function C(me,le){return!!(me&&me.length)&&function(ie,G,ae){if(G!=G)return function($e,_t,Qe,lt){for(var Kt=$e.length,Pt=Qe+(lt?1:-1);lt?Pt--:++Pt<Kt;)if(_t($e[Pt],Pt,$e))return Pt;return-1}(ie,A,ae);for(var Te=ae-1,Oe=ie.length;++Te<Oe;)if(ie[Te]===G)return Te;return-1}(me,le,0)>-1}function A(me){return me!=me}function P(me,le){for(var ie=me.length,G=0;ie--;)me[ie]===le&&G++;return G}function I(me,le){for(var ie=-1,G=me.length,ae=0,Te=[];++ie<G;){var Oe=me[ie];Oe!==le&&Oe!=="__lodash_placeholder__"||(me[ie]="__lodash_placeholder__",Te[ae++]=ie)}return Te}var j,H,K,U=Function.prototype,pe=Object.prototype,se=y["__core-js_shared__"],J=(j=/[^.]+$/.exec(se&&se.keys&&se.keys.IE_PROTO||""))?"Symbol(src)_1."+j:"",$=U.toString,_e=pe.hasOwnProperty,ve=pe.toString,fe=RegExp("^"+$.call(_e).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),R=Object.create,L=Math.max,Ae=Math.min,Ue=(H=In(Object,"defineProperty"),(K=In.name)&&K.length>2?H:void 0);function Ve(me){return Mn(me)?R(me):{}}function Le(me){return!(!Mn(me)||function(le){return!!J&&J in le}(me))&&(function(le){var ie=Mn(le)?ve.call(le):"";return ie=="[object Function]"||ie=="[object GeneratorFunction]"}(me)||function(le){var ie=!1;if(le!=null&&typeof le.toString!="function")try{ie=!!(le+"")}catch{}return ie}(me)?fe:v).test(function(le){if(le!=null){try{return $.call(le)}catch{}try{return le+""}catch{}}return""}(me))}function st(me,le,ie,G){for(var ae=-1,Te=me.length,Oe=ie.length,$e=-1,_t=le.length,Qe=L(Te-Oe,0),lt=Array(_t+Qe),Kt=!G;++$e<_t;)lt[$e]=le[$e];for(;++ae<Oe;)(Kt||ae<Te)&&(lt[ie[ae]]=me[ae]);for(;Qe--;)lt[$e++]=me[ae++];return lt}function We(me,le,ie,G){for(var ae=-1,Te=me.length,Oe=-1,$e=ie.length,_t=-1,Qe=le.length,lt=L(Te-$e,0),Kt=Array(lt+Qe),Pt=!G;++ae<lt;)Kt[ae]=me[ae];for(var gt=ae;++_t<Qe;)Kt[gt+_t]=le[_t];for(;++Oe<$e;)(Pt||ae<Te)&&(Kt[gt+ie[Oe]]=me[ae++]);return Kt}function rt(me){return function(){var le=arguments;switch(le.length){case 0:return new me;case 1:return new me(le[0]);case 2:return new me(le[0],le[1]);case 3:return new me(le[0],le[1],le[2]);case 4:return new me(le[0],le[1],le[2],le[3]);case 5:return new me(le[0],le[1],le[2],le[3],le[4]);case 6:return new me(le[0],le[1],le[2],le[3],le[4],le[5]);case 7:return new me(le[0],le[1],le[2],le[3],le[4],le[5],le[6])}var ie=Ve(me.prototype),G=me.apply(ie,le);return Mn(G)?G:ie}}function Zt(me,le,ie,G,ae,Te,Oe,$e,_t,Qe){var lt=128&le,Kt=1&le,Pt=2&le,gt=24&le,Ln=512&le,Tn=Pt?void 0:rt(me);return function zr(){for(var wn=arguments.length,kt=Array(wn),nr=wn;nr--;)kt[nr]=arguments[nr];if(gt)var dr=tr(zr),rr=P(kt,dr);if(G&&(kt=st(kt,G,ae,gt)),Te&&(kt=We(kt,Te,Oe,gt)),wn-=rr,gt&&wn<Qe){var to=I(kt,dr);return qn(me,le,Zt,zr.placeholder,ie,kt,to,$e,_t,Qe-wn)}var Fr=Kt?ie:this,_o=Pt?Fr[me]:me;return wn=kt.length,$e?kt=yo(kt,$e):Ln&&wn>1&&kt.reverse(),lt&&_t<wn&&(kt.length=_t),this&&this!==y&&this instanceof zr&&(_o=Tn||rt(_o)),_o.apply(Fr,kt)}}function qn(me,le,ie,G,ae,Te,Oe,$e,_t,Qe){var lt=8&le;le|=lt?32:64,4&(le&=~(lt?64:32))||(le&=-4);var Kt=ie(me,le,ae,lt?Te:void 0,lt?Oe:void 0,lt?void 0:Te,lt?void 0:Oe,$e,_t,Qe);return Kt.placeholder=G,Eo(Kt,me,le)}function er(me,le,ie,G,ae,Te,Oe,$e){var _t=2&le;if(!_t&&typeof me!="function")throw new TypeError("Expected a function");var Qe=G?G.length:0;if(Qe||(le&=-97,G=ae=void 0),Oe=Oe===void 0?Oe:L(Po(Oe),0),$e=$e===void 0?$e:Po($e),Qe-=ae?ae.length:0,64&le){var lt=G,Kt=ae;G=ae=void 0}var Pt=[me,le,ie,G,ae,lt,Kt,Te,Oe,$e];if(me=Pt[0],le=Pt[1],ie=Pt[2],G=Pt[3],ae=Pt[4],!($e=Pt[9]=Pt[9]==null?_t?0:me.length:L(Pt[9]-Qe,0))&&24&le&&(le&=-25),le&&le!=1)gt=le==8||le==16?function(Ln,Tn,zr){var wn=rt(Ln);return function kt(){for(var nr=arguments.length,dr=Array(nr),rr=nr,to=tr(kt);rr--;)dr[rr]=arguments[rr];var Fr=nr<3&&dr[0]!==to&&dr[nr-1]!==to?[]:I(dr,to);if((nr-=Fr.length)<zr)return qn(Ln,Tn,Zt,kt.placeholder,void 0,dr,Fr,void 0,void 0,zr-nr);var _o=this&&this!==y&&this instanceof kt?wn:Ln;return F(_o,this,dr)}}(me,le,$e):le!=32&&le!=33||ae.length?Zt.apply(void 0,Pt):function(Ln,Tn,zr,wn){var kt=1&Tn,nr=rt(Ln);return function dr(){for(var rr=-1,to=arguments.length,Fr=-1,_o=wn.length,Ia=Array(_o+to),wi=this&&this!==y&&this instanceof dr?nr:Ln;++Fr<_o;)Ia[Fr]=wn[Fr];for(;to--;)Ia[Fr++]=arguments[++rr];return F(wi,kt?zr:this,Ia)}}(me,le,ie,G);else var gt=function(Ln,Tn,zr){var wn=1&Tn,kt=rt(Ln);return function nr(){var dr=this&&this!==y&&this instanceof nr?kt:Ln;return dr.apply(wn?zr:this,arguments)}}(me,le,ie);return Eo(gt,me,le)}function tr(me){return me.placeholder}function In(me,le){var ie=function(G,ae){return G==null?void 0:G[ae]}(me,le);return Le(ie)?ie:void 0}function br(me){var le=me.match(d);return le?le[1].split(h):[]}function Nr(me,le){var ie=le.length,G=ie-1;return le[G]=(ie>1?"& ":"")+le[G],le=le.join(ie>2?", ":" "),me.replace(u,`{ /* [wrapped with `+le+`] */ `)}function an(me,le){return!!(le=le??9007199254740991)&&(typeof me=="number"||b.test(me))&&me>-1&&me%1==0&&me<le}function yo(me,le){for(var ie=me.length,G=Ae(le.length,ie),ae=function(Oe,$e){var _t=-1,Qe=Oe.length;for($e||($e=Array(Qe));++_t<Qe;)$e[_t]=Oe[_t];return $e}(me);G--;){var Te=le[G];me[G]=an(Te,ie)?ae[Te]:void 0}return me}var Eo=Ue?function(me,le,ie){var G,ae=le+"";return Ue(me,"toString",{configurable:!0,enumerable:!1,value:(G=Nr(ae,jr(br(ae),ie)),function(){return G})})}:function(me){return me};function jr(me,le){return function(ie,G){for(var ae=-1,Te=ie?ie.length:0;++ae<Te&&G(ie[ae],ae,ie)!==!1;);}(s,function(ie){var G="_."+ie[0];le&ie[1]&&!C(me,G)&&me.push(G)}),me.sort()}function pn(me,le,ie){var G=er(me,8,void 0,void 0,void 0,void 0,void 0,le=ie?void 0:le);return G.placeholder=pn.placeholder,G}function Mn(me){var le=typeof me;return!!me&&(le=="object"||le=="function")}function mn(me){return me?(me=function(le){if(typeof le=="number")return le;if(function(ae){return typeof ae=="symbol"||function(Te){return!!Te&&typeof Te=="object"}(ae)&&ve.call(ae)=="[object Symbol]"}(le))return NaN;if(Mn(le)){var ie=typeof le.valueOf=="function"?le.valueOf():le;le=Mn(ie)?ie+"":ie}if(typeof le!="string")return le===0?le:+le;le=le.replace(l,"");var G=m.test(le);return G||_.test(le)?E(le.slice(2),G?2:8):p.test(le)?NaN:+le}(me))===1/0||me===-1/0?17976931348623157e292*(me<0?-1:1):me==me?me:0:me===0?me:0}function Po(me){var le=mn(me),ie=le%1;return le==le?ie?le-ie:le:0}pn.placeholder={},r.exports=pn}).call(this,i(43))},function(r,o,i){function a(We){return We&&We.__esModule?We.default:We}o.__esModule=!0;var s=i(95);o.threezerotwofour=a(s);var l=i(96);o.apathy=a(l);var u=i(97);o.ashes=a(u);var d=i(98);o.atelierDune=a(d);var h=i(99);o.atelierForest=a(h);var p=i(100);o.atelierHeath=a(p);var m=i(101);o.atelierLakeside=a(m);var v=i(102);o.atelierSeaside=a(v);var _=i(103);o.bespin=a(_);var b=i(104);o.brewer=a(b);var E=i(105);o.bright=a(E);var w=i(106);o.chalk=a(w);var k=i(107);o.codeschool=a(k);var y=i(108);o.colors=a(y);var F=i(109);o.default=a(F);var C=i(110);o.eighties=a(C);var A=i(111);o.embers=a(A);var P=i(112);o.flat=a(P);var I=i(113);o.google=a(I);var j=i(114);o.grayscale=a(j);var H=i(115);o.greenscreen=a(H);var K=i(116);o.harmonic=a(K);var U=i(117);o.hopscotch=a(U);var pe=i(118);o.isotope=a(pe);var se=i(119);o.marrakesh=a(se);var J=i(120);o.mocha=a(J);var $=i(121);o.monokai=a($);var _e=i(122);o.ocean=a(_e);var ve=i(123);o.paraiso=a(ve);var fe=i(124);o.pop=a(fe);var R=i(125);o.railscasts=a(R);var L=i(126);o.shapeshifter=a(L);var Ae=i(127);o.solarized=a(Ae);var Ue=i(128);o.summerfruit=a(Ue);var Ve=i(129);o.tomorrow=a(Ve);var Le=i(130);o.tube=a(Le);var st=i(131);o.twilight=a(st)},function(r,o,i){o.__esModule=!0,o.default={scheme:"threezerotwofour",author:"jan t. sott (http://github.com/idleberg)",base00:"#090300",base01:"#3a3432",base02:"#4a4543",base03:"#5c5855",base04:"#807d7c",base05:"#a5a2a2",base06:"#d6d5d4",base07:"#f7f7f7",base08:"#db2d20",base09:"#e8bbd0",base0A:"#fded02",base0B:"#01a252",base0C:"#b5e4f4",base0D:"#01a0e4",base0E:"#a16a94",base0F:"#cdab53"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"apathy",author:"jannik siebert (https://github.com/janniks)",base00:"#031A16",base01:"#0B342D",base02:"#184E45",base03:"#2B685E",base04:"#5F9C92",base05:"#81B5AC",base06:"#A7CEC8",base07:"#D2E7E4",base08:"#3E9688",base09:"#3E7996",base0A:"#3E4C96",base0B:"#883E96",base0C:"#963E4C",base0D:"#96883E",base0E:"#4C963E",base0F:"#3E965B"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"ashes",author:"jannik siebert (https://github.com/janniks)",base00:"#1C2023",base01:"#393F45",base02:"#565E65",base03:"#747C84",base04:"#ADB3BA",base05:"#C7CCD1",base06:"#DFE2E5",base07:"#F3F4F5",base08:"#C7AE95",base09:"#C7C795",base0A:"#AEC795",base0B:"#95C7AE",base0C:"#95AEC7",base0D:"#AE95C7",base0E:"#C795AE",base0F:"#C79595"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"atelier dune",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/dune)",base00:"#20201d",base01:"#292824",base02:"#6e6b5e",base03:"#7d7a68",base04:"#999580",base05:"#a6a28c",base06:"#e8e4cf",base07:"#fefbec",base08:"#d73737",base09:"#b65611",base0A:"#cfb017",base0B:"#60ac39",base0C:"#1fad83",base0D:"#6684e1",base0E:"#b854d4",base0F:"#d43552"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"atelier forest",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/forest)",base00:"#1b1918",base01:"#2c2421",base02:"#68615e",base03:"#766e6b",base04:"#9c9491",base05:"#a8a19f",base06:"#e6e2e0",base07:"#f1efee",base08:"#f22c40",base09:"#df5320",base0A:"#d5911a",base0B:"#5ab738",base0C:"#00ad9c",base0D:"#407ee7",base0E:"#6666ea",base0F:"#c33ff3"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"atelier heath",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/heath)",base00:"#1b181b",base01:"#292329",base02:"#695d69",base03:"#776977",base04:"#9e8f9e",base05:"#ab9bab",base06:"#d8cad8",base07:"#f7f3f7",base08:"#ca402b",base09:"#a65926",base0A:"#bb8a35",base0B:"#379a37",base0C:"#159393",base0D:"#516aec",base0E:"#7b59c0",base0F:"#cc33cc"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"atelier lakeside",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/lakeside/)",base00:"#161b1d",base01:"#1f292e",base02:"#516d7b",base03:"#5a7b8c",base04:"#7195a8",base05:"#7ea2b4",base06:"#c1e4f6",base07:"#ebf8ff",base08:"#d22d72",base09:"#935c25",base0A:"#8a8a0f",base0B:"#568c3b",base0C:"#2d8f6f",base0D:"#257fad",base0E:"#5d5db1",base0F:"#b72dd2"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"atelier seaside",author:"bram de haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/seaside/)",base00:"#131513",base01:"#242924",base02:"#5e6e5e",base03:"#687d68",base04:"#809980",base05:"#8ca68c",base06:"#cfe8cf",base07:"#f0fff0",base08:"#e6193c",base09:"#87711d",base0A:"#c3c322",base0B:"#29a329",base0C:"#1999b3",base0D:"#3d62f5",base0E:"#ad2bee",base0F:"#e619c3"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"bespin",author:"jan t. sott",base00:"#28211c",base01:"#36312e",base02:"#5e5d5c",base03:"#666666",base04:"#797977",base05:"#8a8986",base06:"#9d9b97",base07:"#baae9e",base08:"#cf6a4c",base09:"#cf7d34",base0A:"#f9ee98",base0B:"#54be0d",base0C:"#afc4db",base0D:"#5ea6ea",base0E:"#9b859d",base0F:"#937121"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"brewer",author:"timothée poisot (http://github.com/tpoisot)",base00:"#0c0d0e",base01:"#2e2f30",base02:"#515253",base03:"#737475",base04:"#959697",base05:"#b7b8b9",base06:"#dadbdc",base07:"#fcfdfe",base08:"#e31a1c",base09:"#e6550d",base0A:"#dca060",base0B:"#31a354",base0C:"#80b1d3",base0D:"#3182bd",base0E:"#756bb1",base0F:"#b15928"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"bright",author:"chris kempson (http://chriskempson.com)",base00:"#000000",base01:"#303030",base02:"#505050",base03:"#b0b0b0",base04:"#d0d0d0",base05:"#e0e0e0",base06:"#f5f5f5",base07:"#ffffff",base08:"#fb0120",base09:"#fc6d24",base0A:"#fda331",base0B:"#a1c659",base0C:"#76c7b7",base0D:"#6fb3d2",base0E:"#d381c3",base0F:"#be643c"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"chalk",author:"chris kempson (http://chriskempson.com)",base00:"#151515",base01:"#202020",base02:"#303030",base03:"#505050",base04:"#b0b0b0",base05:"#d0d0d0",base06:"#e0e0e0",base07:"#f5f5f5",base08:"#fb9fb1",base09:"#eda987",base0A:"#ddb26f",base0B:"#acc267",base0C:"#12cfc0",base0D:"#6fc2ef",base0E:"#e1a3ee",base0F:"#deaf8f"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"codeschool",author:"brettof86",base00:"#232c31",base01:"#1c3657",base02:"#2a343a",base03:"#3f4944",base04:"#84898c",base05:"#9ea7a6",base06:"#a7cfa3",base07:"#b5d8f6",base08:"#2a5491",base09:"#43820d",base0A:"#a03b1e",base0B:"#237986",base0C:"#b02f30",base0D:"#484d79",base0E:"#c59820",base0F:"#c98344"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"colors",author:"mrmrs (http://clrs.cc)",base00:"#111111",base01:"#333333",base02:"#555555",base03:"#777777",base04:"#999999",base05:"#bbbbbb",base06:"#dddddd",base07:"#ffffff",base08:"#ff4136",base09:"#ff851b",base0A:"#ffdc00",base0B:"#2ecc40",base0C:"#7fdbff",base0D:"#0074d9",base0E:"#b10dc9",base0F:"#85144b"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"default",author:"chris kempson (http://chriskempson.com)",base00:"#181818",base01:"#282828",base02:"#383838",base03:"#585858",base04:"#b8b8b8",base05:"#d8d8d8",base06:"#e8e8e8",base07:"#f8f8f8",base08:"#ab4642",base09:"#dc9656",base0A:"#f7ca88",base0B:"#a1b56c",base0C:"#86c1b9",base0D:"#7cafc2",base0E:"#ba8baf",base0F:"#a16946"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"eighties",author:"chris kempson (http://chriskempson.com)",base00:"#2d2d2d",base01:"#393939",base02:"#515151",base03:"#747369",base04:"#a09f93",base05:"#d3d0c8",base06:"#e8e6df",base07:"#f2f0ec",base08:"#f2777a",base09:"#f99157",base0A:"#ffcc66",base0B:"#99cc99",base0C:"#66cccc",base0D:"#6699cc",base0E:"#cc99cc",base0F:"#d27b53"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"embers",author:"jannik siebert (https://github.com/janniks)",base00:"#16130F",base01:"#2C2620",base02:"#433B32",base03:"#5A5047",base04:"#8A8075",base05:"#A39A90",base06:"#BEB6AE",base07:"#DBD6D1",base08:"#826D57",base09:"#828257",base0A:"#6D8257",base0B:"#57826D",base0C:"#576D82",base0D:"#6D5782",base0E:"#82576D",base0F:"#825757"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"flat",author:"chris kempson (http://chriskempson.com)",base00:"#2C3E50",base01:"#34495E",base02:"#7F8C8D",base03:"#95A5A6",base04:"#BDC3C7",base05:"#e0e0e0",base06:"#f5f5f5",base07:"#ECF0F1",base08:"#E74C3C",base09:"#E67E22",base0A:"#F1C40F",base0B:"#2ECC71",base0C:"#1ABC9C",base0D:"#3498DB",base0E:"#9B59B6",base0F:"#be643c"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"google",author:"seth wright (http://sethawright.com)",base00:"#1d1f21",base01:"#282a2e",base02:"#373b41",base03:"#969896",base04:"#b4b7b4",base05:"#c5c8c6",base06:"#e0e0e0",base07:"#ffffff",base08:"#CC342B",base09:"#F96A38",base0A:"#FBA922",base0B:"#198844",base0C:"#3971ED",base0D:"#3971ED",base0E:"#A36AC7",base0F:"#3971ED"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"grayscale",author:"alexandre gavioli (https://github.com/alexx2/)",base00:"#101010",base01:"#252525",base02:"#464646",base03:"#525252",base04:"#ababab",base05:"#b9b9b9",base06:"#e3e3e3",base07:"#f7f7f7",base08:"#7c7c7c",base09:"#999999",base0A:"#a0a0a0",base0B:"#8e8e8e",base0C:"#868686",base0D:"#686868",base0E:"#747474",base0F:"#5e5e5e"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"green screen",author:"chris kempson (http://chriskempson.com)",base00:"#001100",base01:"#003300",base02:"#005500",base03:"#007700",base04:"#009900",base05:"#00bb00",base06:"#00dd00",base07:"#00ff00",base08:"#007700",base09:"#009900",base0A:"#007700",base0B:"#00bb00",base0C:"#005500",base0D:"#009900",base0E:"#00bb00",base0F:"#005500"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"harmonic16",author:"jannik siebert (https://github.com/janniks)",base00:"#0b1c2c",base01:"#223b54",base02:"#405c79",base03:"#627e99",base04:"#aabcce",base05:"#cbd6e2",base06:"#e5ebf1",base07:"#f7f9fb",base08:"#bf8b56",base09:"#bfbf56",base0A:"#8bbf56",base0B:"#56bf8b",base0C:"#568bbf",base0D:"#8b56bf",base0E:"#bf568b",base0F:"#bf5656"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"hopscotch",author:"jan t. sott",base00:"#322931",base01:"#433b42",base02:"#5c545b",base03:"#797379",base04:"#989498",base05:"#b9b5b8",base06:"#d5d3d5",base07:"#ffffff",base08:"#dd464c",base09:"#fd8b19",base0A:"#fdcc59",base0B:"#8fc13e",base0C:"#149b93",base0D:"#1290bf",base0E:"#c85e7c",base0F:"#b33508"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"isotope",author:"jan t. sott",base00:"#000000",base01:"#404040",base02:"#606060",base03:"#808080",base04:"#c0c0c0",base05:"#d0d0d0",base06:"#e0e0e0",base07:"#ffffff",base08:"#ff0000",base09:"#ff9900",base0A:"#ff0099",base0B:"#33ff00",base0C:"#00ffff",base0D:"#0066ff",base0E:"#cc00ff",base0F:"#3300ff"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"marrakesh",author:"alexandre gavioli (http://github.com/alexx2/)",base00:"#201602",base01:"#302e00",base02:"#5f5b17",base03:"#6c6823",base04:"#86813b",base05:"#948e48",base06:"#ccc37a",base07:"#faf0a5",base08:"#c35359",base09:"#b36144",base0A:"#a88339",base0B:"#18974e",base0C:"#75a738",base0D:"#477ca1",base0E:"#8868b3",base0F:"#b3588e"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"mocha",author:"chris kempson (http://chriskempson.com)",base00:"#3B3228",base01:"#534636",base02:"#645240",base03:"#7e705a",base04:"#b8afad",base05:"#d0c8c6",base06:"#e9e1dd",base07:"#f5eeeb",base08:"#cb6077",base09:"#d28b71",base0A:"#f4bc87",base0B:"#beb55b",base0C:"#7bbda4",base0D:"#8ab3b5",base0E:"#a89bb9",base0F:"#bb9584"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"monokai",author:"wimer hazenberg (http://www.monokai.nl)",base00:"#272822",base01:"#383830",base02:"#49483e",base03:"#75715e",base04:"#a59f85",base05:"#f8f8f2",base06:"#f5f4f1",base07:"#f9f8f5",base08:"#f92672",base09:"#fd971f",base0A:"#f4bf75",base0B:"#a6e22e",base0C:"#a1efe4",base0D:"#66d9ef",base0E:"#ae81ff",base0F:"#cc6633"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"ocean",author:"chris kempson (http://chriskempson.com)",base00:"#2b303b",base01:"#343d46",base02:"#4f5b66",base03:"#65737e",base04:"#a7adba",base05:"#c0c5ce",base06:"#dfe1e8",base07:"#eff1f5",base08:"#bf616a",base09:"#d08770",base0A:"#ebcb8b",base0B:"#a3be8c",base0C:"#96b5b4",base0D:"#8fa1b3",base0E:"#b48ead",base0F:"#ab7967"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"paraiso",author:"jan t. sott",base00:"#2f1e2e",base01:"#41323f",base02:"#4f424c",base03:"#776e71",base04:"#8d8687",base05:"#a39e9b",base06:"#b9b6b0",base07:"#e7e9db",base08:"#ef6155",base09:"#f99b15",base0A:"#fec418",base0B:"#48b685",base0C:"#5bc4bf",base0D:"#06b6ef",base0E:"#815ba4",base0F:"#e96ba8"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"pop",author:"chris kempson (http://chriskempson.com)",base00:"#000000",base01:"#202020",base02:"#303030",base03:"#505050",base04:"#b0b0b0",base05:"#d0d0d0",base06:"#e0e0e0",base07:"#ffffff",base08:"#eb008a",base09:"#f29333",base0A:"#f8ca12",base0B:"#37b349",base0C:"#00aabb",base0D:"#0e5a94",base0E:"#b31e8d",base0F:"#7a2d00"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"railscasts",author:"ryan bates (http://railscasts.com)",base00:"#2b2b2b",base01:"#272935",base02:"#3a4055",base03:"#5a647e",base04:"#d4cfc9",base05:"#e6e1dc",base06:"#f4f1ed",base07:"#f9f7f3",base08:"#da4939",base09:"#cc7833",base0A:"#ffc66d",base0B:"#a5c261",base0C:"#519f50",base0D:"#6d9cbe",base0E:"#b6b3eb",base0F:"#bc9458"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"shapeshifter",author:"tyler benziger (http://tybenz.com)",base00:"#000000",base01:"#040404",base02:"#102015",base03:"#343434",base04:"#555555",base05:"#ababab",base06:"#e0e0e0",base07:"#f9f9f9",base08:"#e92f2f",base09:"#e09448",base0A:"#dddd13",base0B:"#0ed839",base0C:"#23edda",base0D:"#3b48e3",base0E:"#f996e2",base0F:"#69542d"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"solarized",author:"ethan schoonover (http://ethanschoonover.com/solarized)",base00:"#002b36",base01:"#073642",base02:"#586e75",base03:"#657b83",base04:"#839496",base05:"#93a1a1",base06:"#eee8d5",base07:"#fdf6e3",base08:"#dc322f",base09:"#cb4b16",base0A:"#b58900",base0B:"#859900",base0C:"#2aa198",base0D:"#268bd2",base0E:"#6c71c4",base0F:"#d33682"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"summerfruit",author:"christopher corley (http://cscorley.github.io/)",base00:"#151515",base01:"#202020",base02:"#303030",base03:"#505050",base04:"#B0B0B0",base05:"#D0D0D0",base06:"#E0E0E0",base07:"#FFFFFF",base08:"#FF0086",base09:"#FD8900",base0A:"#ABA800",base0B:"#00C918",base0C:"#1faaaa",base0D:"#3777E6",base0E:"#AD00A1",base0F:"#cc6633"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"tomorrow",author:"chris kempson (http://chriskempson.com)",base00:"#1d1f21",base01:"#282a2e",base02:"#373b41",base03:"#969896",base04:"#b4b7b4",base05:"#c5c8c6",base06:"#e0e0e0",base07:"#ffffff",base08:"#cc6666",base09:"#de935f",base0A:"#f0c674",base0B:"#b5bd68",base0C:"#8abeb7",base0D:"#81a2be",base0E:"#b294bb",base0F:"#a3685a"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"london tube",author:"jan t. sott",base00:"#231f20",base01:"#1c3f95",base02:"#5a5758",base03:"#737171",base04:"#959ca1",base05:"#d9d8d8",base06:"#e7e7e8",base07:"#ffffff",base08:"#ee2e24",base09:"#f386a1",base0A:"#ffd204",base0B:"#00853e",base0C:"#85cebc",base0D:"#009ddc",base0E:"#98005d",base0F:"#b06110"},r.exports=o.default},function(r,o,i){o.__esModule=!0,o.default={scheme:"twilight",author:"david hart (http://hart-dev.com)",base00:"#1e1e1e",base01:"#323537",base02:"#464b50",base03:"#5f5a60",base04:"#838184",base05:"#a7a7a7",base06:"#c3c3c3",base07:"#ffffff",base08:"#cf6a4c",base09:"#cda869",base0A:"#f9ee98",base0B:"#8f9d6a",base0C:"#afc4db",base0D:"#7587a6",base0E:"#9b859d",base0F:"#9b703f"},r.exports=o.default},function(r,o,i){var a=i(33);function s(l){var u=Math.round(a(l,0,255)).toString(16);return u.length==1?"0"+u:u}r.exports=function(l){var u=l.length===4?s(255*l[3]):"";return"#"+s(l[0])+s(l[1])+s(l[2])+u}},function(r,o,i){var a=i(134),s=i(135),l=i(136),u=i(137),d={"#":s,hsl:function(p){var m=a(p),v=u(m);return m.length===4&&v.push(m[3]),v},rgb:l};function h(p){for(var m in d)if(p.indexOf(m)===0)return d[m](p)}h.rgb=l,h.hsl=a,h.hex=s,r.exports=h},function(r,o,i){var a=i(44),s=i(33);function l(u,d){switch(u=parseFloat(u),d){case 0:return s(u,0,360);case 1:case 2:return s(u,0,100);case 3:return s(u,0,1)}}r.exports=function(u){return a(u).map(l)}},function(r,o){r.exports=function(i){i.length!==4&&i.length!==5||(i=function(l){for(var u="#",d=1;d<l.length;d++){var h=l.charAt(d);u+=h+h}return u}(i));var a=[parseInt(i.substring(1,3),16),parseInt(i.substring(3,5),16),parseInt(i.substring(5,7),16)];if(i.length===9){var s=parseFloat((parseInt(i.substring(7,9),16)/255).toFixed(2));a.push(s)}return a}},function(r,o,i){var a=i(44),s=i(33);function l(u,d){return d<3?u.indexOf("%")!=-1?Math.round(255*s(parseInt(u,10),0,100)/100):s(parseInt(u,10),0,255):s(parseFloat(u),0,1)}r.exports=function(u){return a(u).map(l)}},function(r,o){r.exports=function(i){var a,s,l,u,d,h=i[0]/360,p=i[1]/100,m=i[2]/100;if(p==0)return[d=255*m,d,d];a=2*m-(s=m<.5?m*(1+p):m+p-m*p),u=[0,0,0];for(var v=0;v<3;v++)(l=h+1/3*-(v-1))<0&&l++,l>1&&l--,d=6*l<1?a+6*(s-a)*l:2*l<1?s:3*l<2?a+(s-a)*(2/3-l)*6:a,u[v]=255*d;return u}},function(r,o,i){(function(a){var s=typeof a=="object"&&a&&a.Object===Object&&a,l=typeof self=="object"&&self&&self.Object===Object&&self,u=s||l||Function("return this")();function d(I,j,H){switch(H.length){case 0:return I.call(j);case 1:return I.call(j,H[0]);case 2:return I.call(j,H[0],H[1]);case 3:return I.call(j,H[0],H[1],H[2])}return I.apply(j,H)}function h(I,j){for(var H=-1,K=j.length,U=I.length;++H<K;)I[U+H]=j[H];return I}var p=Object.prototype,m=p.hasOwnProperty,v=p.toString,_=u.Symbol,b=p.propertyIsEnumerable,E=_?_.isConcatSpreadable:void 0,w=Math.max;function k(I){return y(I)||function(j){return function(H){return function(K){return!!K&&typeof K=="object"}(H)&&function(K){return K!=null&&function(U){return typeof U=="number"&&U>-1&&U%1==0&&U<=9007199254740991}(K.length)&&!function(U){var pe=function(se){var J=typeof se;return!!se&&(J=="object"||J=="function")}(U)?v.call(U):"";return pe=="[object Function]"||pe=="[object GeneratorFunction]"}(K)}(H)}(j)&&m.call(j,"callee")&&(!b.call(j,"callee")||v.call(j)=="[object Arguments]")}(I)||!!(E&&I&&I[E])}var y=Array.isArray,F,C,A,P=(C=function(I){var j=(I=function K(U,pe,se,J,$){var _e=-1,ve=U.length;for(se||(se=k),$||($=[]);++_e<ve;){var fe=U[_e];pe>0&&se(fe)?pe>1?K(fe,pe-1,se,J,$):h($,fe):J||($[$.length]=fe)}return $}(I,1)).length,H=j;for(F;H--;)if(typeof I[H]!="function")throw new TypeError("Expected a function");return function(){for(var K=0,U=j?I[K].apply(this,arguments):arguments[0];++K<j;)U=I[K].call(this,U);return U}},A=w(A===void 0?C.length-1:A,0),function(){for(var I=arguments,j=-1,H=w(I.length-A,0),K=Array(H);++j<H;)K[j]=I[A+j];j=-1;for(var U=Array(A+1);++j<A;)U[j]=I[j];return U[A]=K,d(C,this,U)});r.exports=P}).call(this,i(43))},function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.yuv2rgb=function(a){var s,l,u,d=a[0],h=a[1],p=a[2];return s=1*d+0*h+1.13983*p,l=1*d+-.39465*h+-.5806*p,u=1*d+2.02311*h+0*p,s=Math.min(Math.max(0,s),1),l=Math.min(Math.max(0,l),1),u=Math.min(Math.max(0,u),1),[255*s,255*l,255*u]},o.rgb2yuv=function(a){var s=a[0]/255,l=a[1]/255,u=a[2]/255;return[.299*s+.587*l+.114*u,-.14713*s+-.28886*l+.436*u,.615*s+-.51499*l+-.10001*u]}},function(r,o,i){function a(u,d,h){return d in u?Object.defineProperty(u,d,{value:h,enumerable:!0,configurable:!0,writable:!0}):u[d]=h,u}var s=i(141),l=function(){function u(){a(this,"_callbacks",void 0),a(this,"_isDispatching",void 0),a(this,"_isHandled",void 0),a(this,"_isPending",void 0),a(this,"_lastID",void 0),a(this,"_pendingPayload",void 0),this._callbacks={},this._isDispatching=!1,this._isHandled={},this._isPending={},this._lastID=1}var d=u.prototype;return d.register=function(h){var p="ID_"+this._lastID++;return this._callbacks[p]=h,p},d.unregister=function(h){this._callbacks[h]||s(!1),delete this._callbacks[h]},d.waitFor=function(h){this._isDispatching||s(!1);for(var p=0;p<h.length;p++){var m=h[p];this._isPending[m]?this._isHandled[m]||s(!1):(this._callbacks[m]||s(!1),this._invokeCallback(m))}},d.dispatch=function(h){this._isDispatching&&s(!1),this._startDispatching(h);try{for(var p in this._callbacks)this._isPending[p]||this._invokeCallback(p)}finally{this._stopDispatching()}},d.isDispatching=function(){return this._isDispatching},d._invokeCallback=function(h){this._isPending[h]=!0,this._callbacks[h](this._pendingPayload),this._isHandled[h]=!0},d._startDispatching=function(h){for(var p in this._callbacks)this._isPending[p]=!1,this._isHandled[p]=!1;this._pendingPayload=h,this._isDispatching=!0},d._stopDispatching=function(){delete this._pendingPayload,this._isDispatching=!1},u}();r.exports=l},function(r,o,i){r.exports=function(a,s){for(var l=arguments.length,u=new Array(l>2?l-2:0),d=2;d<l;d++)u[d-2]=arguments[d];if(!a){var h;if(s===void 0)h=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var p=0;(h=new Error(s.replace(/%s/g,function(){return String(u[p++])}))).name="Invariant Violation"}throw h.framesToPop=1,h}}},function(r,o,i){function a(q,W,O){return W in q?Object.defineProperty(q,W,{value:O,enumerable:!0,configurable:!0,writable:!0}):q[W]=O,q}function s(q,W){var O=Object.keys(q);if(Object.getOwnPropertySymbols){var B=Object.getOwnPropertySymbols(q);W&&(B=B.filter(function(z){return Object.getOwnPropertyDescriptor(q,z).enumerable})),O.push.apply(O,B)}return O}function l(q){for(var W=1;W<arguments.length;W++){var O=arguments[W]!=null?arguments[W]:{};W%2?s(Object(O),!0).forEach(function(B){a(q,B,O[B])}):Object.getOwnPropertyDescriptors?Object.defineProperties(q,Object.getOwnPropertyDescriptors(O)):s(Object(O)).forEach(function(B){Object.defineProperty(q,B,Object.getOwnPropertyDescriptor(O,B))})}return q}function u(q,W){if(!(q instanceof W))throw new TypeError("Cannot call a class as a function")}function d(q,W){for(var O=0;O<W.length;O++){var B=W[O];B.enumerable=B.enumerable||!1,B.configurable=!0,"value"in B&&(B.writable=!0),Object.defineProperty(q,B.key,B)}}function h(q,W,O){return W&&d(q.prototype,W),O&&d(q,O),q}function p(q,W){return(p=Object.setPrototypeOf||function(O,B){return O.__proto__=B,O})(q,W)}function m(q,W){if(typeof W!="function"&&W!==null)throw new TypeError("Super expression must either be null or a function");q.prototype=Object.create(W&&W.prototype,{constructor:{value:q,writable:!0,configurable:!0}}),W&&p(q,W)}function v(q){return(v=Object.setPrototypeOf?Object.getPrototypeOf:function(W){return W.__proto__||Object.getPrototypeOf(W)})(q)}function _(q){return(_=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(W){return typeof W}:function(W){return W&&typeof Symbol=="function"&&W.constructor===Symbol&&W!==Symbol.prototype?"symbol":typeof W})(q)}function b(q){if(q===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return q}function E(q,W){return!W||_(W)!=="object"&&typeof W!="function"?b(q):W}function w(q){var W=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],function(){})),!0}catch{return!1}}();return function(){var O,B=v(q);if(W){var z=v(this).constructor;O=Reflect.construct(B,arguments,z)}else O=B.apply(this,arguments);return E(this,O)}}i.r(o);var k=i(0),y=i.n(k);function F(){var q=this.constructor.getDerivedStateFromProps(this.props,this.state);q!=null&&this.setState(q)}function C(q){this.setState(function(W){var O=this.constructor.getDerivedStateFromProps(q,W);return O??null}.bind(this))}function A(q,W){try{var O=this.props,B=this.state;this.props=q,this.state=W,this.__reactInternalSnapshotFlag=!0,this.__reactInternalSnapshot=this.getSnapshotBeforeUpdate(O,B)}finally{this.props=O,this.state=B}}function P(q){var W=q.prototype;if(!W||!W.isReactComponent)throw new Error("Can only polyfill class components");if(typeof q.getDerivedStateFromProps!="function"&&typeof W.getSnapshotBeforeUpdate!="function")return q;var O=null,B=null,z=null;if(typeof W.componentWillMount=="function"?O="componentWillMount":typeof W.UNSAFE_componentWillMount=="function"&&(O="UNSAFE_componentWillMount"),typeof W.componentWillReceiveProps=="function"?B="componentWillReceiveProps":typeof W.UNSAFE_componentWillReceiveProps=="function"&&(B="UNSAFE_componentWillReceiveProps"),typeof W.componentWillUpdate=="function"?z="componentWillUpdate":typeof W.UNSAFE_componentWillUpdate=="function"&&(z="UNSAFE_componentWillUpdate"),O!==null||B!==null||z!==null){var ee=q.displayName||q.name,ue=typeof q.getDerivedStateFromProps=="function"?"getDerivedStateFromProps()":"getSnapshotBeforeUpdate()";throw Error(`Unsafe legacy lifecycles will not be called for components using new component APIs. `+ee+" uses "+ue+" but also contains the following legacy lifecycles:"+(O!==null?` `+O:"")+(B!==null?` `+B:"")+(z!==null?` `+z:"")+` The above lifecycles should be removed. Learn more about this warning here: https://fb.me/react-async-component-lifecycle-hooks`)}if(typeof q.getDerivedStateFromProps=="function"&&(W.componentWillMount=F,W.componentWillReceiveProps=C),typeof W.getSnapshotBeforeUpdate=="function"){if(typeof W.componentDidUpdate!="function")throw new Error("Cannot polyfill getSnapshotBeforeUpdate() for components that do not define componentDidUpdate() on the prototype");W.componentWillUpdate=A;var ce=W.componentDidUpdate;W.componentDidUpdate=function(te,he,Be){var He=this.__reactInternalSnapshotFlag?this.__reactInternalSnapshot:Be;ce.call(this,te,he,He)}}return q}function I(q,W){if(q==null)return{};var O,B,z=function(ue,ce){if(ue==null)return{};var te,he,Be={},He=Object.keys(ue);for(he=0;he<He.length;he++)te=He[he],ce.indexOf(te)>=0||(Be[te]=ue[te]);return Be}(q,W);if(Object.getOwnPropertySymbols){var ee=Object.getOwnPropertySymbols(q);for(B=0;B<ee.length;B++)O=ee[B],W.indexOf(O)>=0||Object.prototype.propertyIsEnumerable.call(q,O)&&(z[O]=q[O])}return z}function j(q){var W=function(O){return{}.toString.call(O).match(/\s([a-zA-Z]+)/)[1].toLowerCase()}(q);return W==="number"&&(W=isNaN(q)?"nan":(0|q)!=q?"float":"integer"),W}F.__suppressDeprecationWarning=!0,C.__suppressDeprecationWarning=!0,A.__suppressDeprecationWarning=!0;var H={scheme:"rjv-default",author:"mac gainor",base00:"rgba(0, 0, 0, 0)",base01:"rgb(245, 245, 245)",base02:"rgb(235, 235, 235)",base03:"#93a1a1",base04:"rgba(0, 0, 0, 0.3)",base05:"#586e75",base06:"#073642",base07:"#002b36",base08:"#d33682",base09:"#cb4b16",base0A:"#dc322f",base0B:"#859900",base0C:"#6c71c4",base0D:"#586e75",base0E:"#2aa198",base0F:"#268bd2"},K={scheme:"rjv-grey",author:"mac gainor",base00:"rgba(1, 1, 1, 0)",base01:"rgba(1, 1, 1, 0.1)",base02:"rgba(0, 0, 0, 0.2)",base03:"rgba(1, 1, 1, 0.3)",base04:"rgba(0, 0, 0, 0.4)",base05:"rgba(1, 1, 1, 0.5)",base06:"rgba(1, 1, 1, 0.6)",base07:"rgba(1, 1, 1, 0.7)",base08:"rgba(1, 1, 1, 0.8)",base09:"rgba(1, 1, 1, 0.8)",base0A:"rgba(1, 1, 1, 0.8)",base0B:"rgba(1, 1, 1, 0.8)",base0C:"rgba(1, 1, 1, 0.8)",base0D:"rgba(1, 1, 1, 0.8)",base0E:"rgba(1, 1, 1, 0.8)",base0F:"rgba(1, 1, 1, 0.8)"},U={white:"#fff",black:"#000",transparent:"rgba(1, 1, 1, 0)",globalFontFamily:"monospace",globalCursor:"default",indentBlockWidth:"5px",braceFontWeight:"bold",braceCursor:"pointer",ellipsisFontSize:"18px",ellipsisLineHeight:"10px",ellipsisCursor:"pointer",keyMargin:"0px 5px",keyLetterSpacing:"0.5px",keyFontStyle:"none",keyBorderRadius:"3px",keyColonWeight:"bold",keyVerticalAlign:"top",keyOpacity:"0.85",keyOpacityHover:"1",keyValPaddingTop:"3px",keyValPaddingBottom:"3px",keyValPaddingRight:"5px",keyValBorderLeft:"1px solid",keyValBorderHover:"2px solid",keyValPaddingHover:"3px 5px 3px 4px",pushedContentMarginLeft:"6px",variableValuePaddingRight:"6px",nullFontSize:"11px",nullFontWeight:"bold",nullPadding:"1px 2px",nullBorderRadius:"3px",nanFontSize:"11px",nanFontWeight:"bold",nanPadding:"1px 2px",nanBorderRadius:"3px",undefinedFontSize:"11px",undefinedFontWeight:"bold",undefinedPadding:"1px 2px",undefinedBorderRadius:"3px",dataTypeFontSize:"11px",dataTypeMarginRight:"4px",datatypeOpacity:"0.8",objectSizeBorderRadius:"3px",objectSizeFontStyle:"italic",objectSizeMargin:"0px 6px 0px 0px",clipboardCursor:"pointer",clipboardCheckMarginLeft:"-12px",metaDataPadding:"0px 0px 0px 10px",arrayGroupMetaPadding:"0px 0px 0px 4px",iconContainerWidth:"17px",tooltipPadding:"4px",editInputMinWidth:"130px",editInputBorderRadius:"2px",editInputPadding:"5px",editInputMarginRight:"4px",editInputFontFamily:"monospace",iconCursor:"pointer",iconFontSize:"15px",iconPaddingRight:"1px",dateValueMarginLeft:"2px",iconMarginRight:"3px",detectedRowPaddingTop:"3px",addKeyCoverBackground:"rgba(255, 255, 255, 0.3)",addKeyCoverPosition:"absolute",addKeyCoverPositionPx:"0px",addKeyModalWidth:"200px",addKeyModalMargin:"auto",addKeyModalPadding:"10px",addKeyModalRadius:"3px"},pe=i(45),se=function(q){var W=function(O){return{backgroundColor:O.base00,ellipsisColor:O.base09,braceColor:O.base07,expandedIcon:O.base0D,collapsedIcon:O.base0E,keyColor:O.base07,arrayKeyColor:O.base0C,objectSize:O.base04,copyToClipboard:O.base0F,copyToClipboardCheck:O.base0D,objectBorder:O.base02,dataTypes:{boolean:O.base0E,date:O.base0D,float:O.base0B,function:O.base0D,integer:O.base0F,string:O.base09,nan:O.base08,null:O.base0A,undefined:O.base05,regexp:O.base0A,background:O.base02},editVariable:{editIcon:O.base0E,cancelIcon:O.base09,removeIcon:O.base09,addIcon:O.base0E,checkIcon:O.base0E,background:O.base01,color:O.base0A,border:O.base07},addKeyModal:{background:O.base05,border:O.base04,color:O.base0A,labelColor:O.base01},validationFailure:{background:O.base09,iconColor:O.base01,fontColor:O.base01}}}(q);return{"app-container":{fontFamily:U.globalFontFamily,cursor:U.globalCursor,backgroundColor:W.backgroundColor,position:"relative"},ellipsis:{display:"inline-block",color:W.ellipsisColor,fontSize:U.ellipsisFontSize,lineHeight:U.ellipsisLineHeight,cursor:U.ellipsisCursor},"brace-row":{display:"inline-block",cursor:"pointer"},brace:{display:"inline-block",cursor:U.braceCursor,fontWeight:U.braceFontWeight,color:W.braceColor},"expanded-icon":{color:W.expandedIcon},"collapsed-icon":{color:W.collapsedIcon},colon:{display:"inline-block",margin:U.keyMargin,color:W.keyColor,verticalAlign:"top"},objectKeyVal:function(O,B){return{style:l({paddingTop:U.keyValPaddingTop,paddingRight:U.keyValPaddingRight,paddingBottom:U.keyValPaddingBottom,borderLeft:U.keyValBorderLeft+" "+W.objectBorder,":hover":{paddingLeft:B.paddingLeft-1+"px",borderLeft:U.keyValBorderHover+" "+W.objectBorder}},B)}},"object-key-val-no-border":{padding:U.keyValPadding},"pushed-content":{marginLeft:U.pushedContentMarginLeft},variableValue:function(O,B){return{style:l({display:"inline-block",paddingRight:U.variableValuePaddingRight,position:"relative"},B)}},"object-name":{display:"inline-block",color:W.keyColor,letterSpacing:U.keyLetterSpacing,fontStyle:U.keyFontStyle,verticalAlign:U.keyVerticalAlign,opacity:U.keyOpacity,":hover":{opacity:U.keyOpacityHover}},"array-key":{display:"inline-block",color:W.arrayKeyColor,letterSpacing:U.keyLetterSpacing,fontStyle:U.keyFontStyle,verticalAlign:U.keyVerticalAlign,opacity:U.keyOpacity,":hover":{opacity:U.keyOpacityHover}},"object-size":{color:W.objectSize,borderRadius:U.objectSizeBorderRadius,fontStyle:U.objectSizeFontStyle,margin:U.objectSizeMargin,cursor:"default"},"data-type-label":{fontSize:U.dataTypeFontSize,marginRight:U.dataTypeMarginRight,opacity:U.datatypeOpacity},boolean:{display:"inline-block",color:W.dataTypes.boolean},date:{display:"inline-block",color:W.dataTypes.date},"date-value":{marginLeft:U.dateValueMarginLeft},float:{display:"inline-block",color:W.dataTypes.float},function:{display:"inline-block",color:W.dataTypes.function,cursor:"pointer",whiteSpace:"pre-line"},"function-value":{fontStyle:"italic"},integer:{display:"inline-block",color:W.dataTypes.integer},string:{display:"inline-block",color:W.dataTypes.string},nan:{display:"inline-block",color:W.dataTypes.nan,fontSize:U.nanFontSize,fontWeight:U.nanFontWeight,backgroundColor:W.dataTypes.background,padding:U.nanPadding,borderRadius:U.nanBorderRadius},null:{display:"inline-block",color:W.dataTypes.null,fontSize:U.nullFontSize,fontWeight:U.nullFontWeight,backgroundColor:W.dataTypes.background,padding:U.nullPadding,borderRadius:U.nullBorderRadius},undefined:{display:"inline-block",color:W.dataTypes.undefined,fontSize:U.undefinedFontSize,padding:U.undefinedPadding,borderRadius:U.undefinedBorderRadius,backgroundColor:W.dataTypes.background},regexp:{display:"inline-block",color:W.dataTypes.regexp},"copy-to-clipboard":{cursor:U.clipboardCursor},"copy-icon":{color:W.copyToClipboard,fontSize:U.iconFontSize,marginRight:U.iconMarginRight,verticalAlign:"top"},"copy-icon-copied":{color:W.copyToClipboardCheck,marginLeft:U.clipboardCheckMarginLeft},"array-group-meta-data":{display:"inline-block",padding:U.arrayGroupMetaPadding},"object-meta-data":{display:"inline-block",padding:U.metaDataPadding},"icon-container":{display:"inline-block",width:U.iconContainerWidth},tooltip:{padding:U.tooltipPadding},removeVarIcon:{verticalAlign:"top",display:"inline-block",color:W.editVariable.removeIcon,cursor:U.iconCursor,fontSize:U.iconFontSize,marginRight:U.iconMarginRight},addVarIcon:{verticalAlign:"top",display:"inline-block",color:W.editVariable.addIcon,cursor:U.iconCursor,fontSize:U.iconFontSize,marginRight:U.iconMarginRight},editVarIcon:{verticalAlign:"top",display:"inline-block",color:W.editVariable.editIcon,cursor:U.iconCursor,fontSize:U.iconFontSize,marginRight:U.iconMarginRight},"edit-icon-container":{display:"inline-block",verticalAlign:"top"},"check-icon":{display:"inline-block",cursor:U.iconCursor,color:W.editVariable.checkIcon,fontSize:U.iconFontSize,paddingRight:U.iconPaddingRight},"cancel-icon":{display:"inline-block",cursor:U.iconCursor,color:W.editVariable.cancelIcon,fontSize:U.iconFontSize,paddingRight:U.iconPaddingRight},"edit-input":{display:"inline-block",minWidth:U.editInputMinWidth,borderRadius:U.editInputBorderRadius,backgroundColor:W.editVariable.background,color:W.editVariable.color,padding:U.editInputPadding,marginRight:U.editInputMarginRight,fontFamily:U.editInputFontFamily},"detected-row":{paddingTop:U.detectedRowPaddingTop},"key-modal-request":{position:U.addKeyCoverPosition,top:U.addKeyCoverPositionPx,left:U.addKeyCoverPositionPx,right:U.addKeyCoverPositionPx,bottom:U.addKeyCoverPositionPx,backgroundColor:U.addKeyCoverBackground},"key-modal":{width:U.addKeyModalWidth,backgroundColor:W.addKeyModal.background,marginLeft:U.addKeyModalMargin,marginRight:U.addKeyModalMargin,padding:U.addKeyModalPadding,borderRadius:U.addKeyModalRadius,marginTop:"15px",position:"relative"},"key-modal-label":{color:W.addKeyModal.labelColor,marginLeft:"2px",marginBottom:"5px",fontSize:"11px"},"key-modal-input-container":{overflow:"hidden"},"key-modal-input":{width:"100%",padding:"3px 6px",fontFamily:"monospace",color:W.addKeyModal.color,border:"none",boxSizing:"border-box",borderRadius:"2px"},"key-modal-cancel":{backgroundColor:W.editVariable.removeIcon,position:"absolute",top:"0px",right:"0px",borderRadius:"0px 3px 0px 3px",cursor:"pointer"},"key-modal-cancel-icon":{color:W.addKeyModal.labelColor,fontSize:U.iconFontSize,transform:"rotate(45deg)"},"key-modal-submit":{color:W.editVariable.addIcon,fontSize:U.iconFontSize,position:"absolute",right:"2px",top:"3px",cursor:"pointer"},"function-ellipsis":{display:"inline-block",color:W.ellipsisColor,fontSize:U.ellipsisFontSize,lineHeight:U.ellipsisLineHeight,cursor:U.ellipsisCursor},"validation-failure":{float:"right",padding:"3px 6px",borderRadius:"2px",cursor:"pointer",color:W.validationFailure.fontColor,backgroundColor:W.validationFailure.background},"validation-failure-label":{marginRight:"6px"},"validation-failure-clear":{position:"relative",verticalAlign:"top",cursor:"pointer",color:W.validationFailure.iconColor,fontSize:U.iconFontSize,transform:"rotate(45deg)"}}};function J(q,W,O){return q||console.error("theme has not been set"),function(B){var z=H;return B!==!1&&B!=="none"||(z=K),Object(pe.createStyling)(se,{defaultBase16:z})(B)}(q)(W,O)}var $=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=(B.rjvId,B.type_name),ee=B.displayDataTypes,ue=B.theme;return ee?y.a.createElement("span",Object.assign({className:"data-type-label"},J(ue,"data-type-label")),z):null}}]),O}(y.a.PureComponent),_e=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props;return y.a.createElement("div",J(B.theme,"boolean"),y.a.createElement($,Object.assign({type_name:"bool"},B)),B.value?"true":"false")}}]),O}(y.a.PureComponent),ve=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props;return y.a.createElement("div",J(B.theme,"date"),y.a.createElement($,Object.assign({type_name:"date"},B)),y.a.createElement("span",Object.assign({className:"date-value"},J(B.theme,"date-value")),B.value.toLocaleTimeString("en-us",{weekday:"short",year:"numeric",month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"})))}}]),O}(y.a.PureComponent),fe=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props;return y.a.createElement("div",J(B.theme,"float"),y.a.createElement($,Object.assign({type_name:"float"},B)),this.props.value)}}]),O}(y.a.PureComponent);function R(q,W){(W==null||W>q.length)&&(W=q.length);for(var O=0,B=new Array(W);O<W;O++)B[O]=q[O];return B}function L(q,W){if(q){if(typeof q=="string")return R(q,W);var O=Object.prototype.toString.call(q).slice(8,-1);return O==="Object"&&q.constructor&&(O=q.constructor.name),O==="Map"||O==="Set"?Array.from(q):O==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(O)?R(q,W):void 0}}function Ae(q,W){var O;if(typeof Symbol>"u"||q[Symbol.iterator]==null){if(Array.isArray(q)||(O=L(q))||W&&q&&typeof q.length=="number"){O&&(q=O);var B=0,z=function(){};return{s:z,n:function(){return B>=q.length?{done:!0}:{done:!1,value:q[B++]}},e:function(te){throw te},f:z}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var ee,ue=!0,ce=!1;return{s:function(){O=q[Symbol.iterator]()},n:function(){var te=O.next();return ue=te.done,te},e:function(te){ce=!0,ee=te},f:function(){try{ue||O.return==null||O.return()}finally{if(ce)throw ee}}}}function Ue(q){return function(W){if(Array.isArray(W))return R(W)}(q)||function(W){if(typeof Symbol<"u"&&Symbol.iterator in Object(W))return Array.from(W)}(q)||L(q)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}var Ve=i(46),Le=new(i(47)).Dispatcher,st=new(function(q){m(O,q);var W=w(O);function O(){var B;u(this,O);for(var z=arguments.length,ee=new Array(z),ue=0;ue<z;ue++)ee[ue]=arguments[ue];return(B=W.call.apply(W,[this].concat(ee))).objects={},B.set=function(ce,te,he,Be){B.objects[ce]===void 0&&(B.objects[ce]={}),B.objects[ce][te]===void 0&&(B.objects[ce][te]={}),B.objects[ce][te][he]=Be},B.get=function(ce,te,he,Be){return B.objects[ce]===void 0||B.objects[ce][te]===void 0||B.objects[ce][te][he]==null?Be:B.objects[ce][te][he]},B.handleAction=function(ce){var te=ce.rjvId,he=ce.data;switch(ce.name){case"RESET":B.emit("reset-"+te);break;case"VARIABLE_UPDATED":ce.data.updated_src=B.updateSrc(te,he),B.set(te,"action","variable-update",l(l({},he),{},{type:"variable-edited"})),B.emit("variable-update-"+te);break;case"VARIABLE_REMOVED":ce.data.updated_src=B.updateSrc(te,he),B.set(te,"action","variable-update",l(l({},he),{},{type:"variable-removed"})),B.emit("variable-update-"+te);break;case"VARIABLE_ADDED":ce.data.updated_src=B.updateSrc(te,he),B.set(te,"action","variable-update",l(l({},he),{},{type:"variable-added"})),B.emit("variable-update-"+te);break;case"ADD_VARIABLE_KEY_REQUEST":B.set(te,"action","new-key-request",he),B.emit("add-key-request-"+te)}},B.updateSrc=function(ce,te){var he=te.name,Be=te.namespace,He=te.new_value,tt=(te.existing_value,te.variable_removed);Be.shift();var vt,at=B.get(ce,"global","src"),Mt=B.deepCopy(at,Ue(Be)),en=Mt,Xe=Ae(Be);try{for(Xe.s();!(vt=Xe.n()).done;)en=en[vt.value]}catch(Vt){Xe.e(Vt)}finally{Xe.f()}return tt?j(en)=="array"?en.splice(he,1):delete en[he]:he!==null?en[he]=He:Mt=He,B.set(ce,"global","src",Mt),Mt},B.deepCopy=function(ce,te){var he,Be=j(ce),He=te.shift();return Be=="array"?he=Ue(ce):Be=="object"&&(he=l({},ce)),He!==void 0&&(he[He]=B.deepCopy(ce[He],te)),he},B}return O}(Ve.EventEmitter));Le.register(st.handleAction.bind(st));var We=st,rt=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).toggleCollapsed=function(){z.setState({collapsed:!z.state.collapsed},function(){We.set(z.props.rjvId,z.props.namespace,"collapsed",z.state.collapsed)})},z.getFunctionDisplay=function(ee){var ue=b(z).props;return ee?y.a.createElement("span",null,z.props.value.toString().slice(9,-1).replace(/\{[\s\S]+/,""),y.a.createElement("span",{className:"function-collapsed",style:{fontWeight:"bold"}},y.a.createElement("span",null,"{"),y.a.createElement("span",J(ue.theme,"ellipsis"),"..."),y.a.createElement("span",null,"}"))):z.props.value.toString().slice(9,-1)},z.state={collapsed:We.get(B.rjvId,B.namespace,"collapsed",!0)},z}return h(O,[{key:"render",value:function(){var B=this.props,z=this.state.collapsed;return y.a.createElement("div",J(B.theme,"function"),y.a.createElement($,Object.assign({type_name:"function"},B)),y.a.createElement("span",Object.assign({},J(B.theme,"function-value"),{className:"rjv-function-container",onClick:this.toggleCollapsed}),this.getFunctionDisplay(z)))}}]),O}(y.a.PureComponent),Zt=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){return y.a.createElement("div",J(this.props.theme,"nan"),"NaN")}}]),O}(y.a.PureComponent),qn=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){return y.a.createElement("div",J(this.props.theme,"null"),"NULL")}}]),O}(y.a.PureComponent),er=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props;return y.a.createElement("div",J(B.theme,"integer"),y.a.createElement($,Object.assign({type_name:"int"},B)),this.props.value)}}]),O}(y.a.PureComponent),tr=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props;return y.a.createElement("div",J(B.theme,"regexp"),y.a.createElement($,Object.assign({type_name:"regexp"},B)),this.props.value.toString())}}]),O}(y.a.PureComponent),In=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).toggleCollapsed=function(){z.setState({collapsed:!z.state.collapsed},function(){We.set(z.props.rjvId,z.props.namespace,"collapsed",z.state.collapsed)})},z.state={collapsed:We.get(B.rjvId,B.namespace,"collapsed",!0)},z}return h(O,[{key:"render",value:function(){this.state.collapsed;var B=this.props,z=B.collapseStringsAfterLength,ee=B.theme,ue=B.value,ce={style:{cursor:"default"}};return j(z)==="integer"&&ue.length>z&&(ce.style.cursor="pointer",this.state.collapsed&&(ue=y.a.createElement("span",null,ue.substring(0,z),y.a.createElement("span",J(ee,"ellipsis")," ...")))),y.a.createElement("div",J(ee,"string"),y.a.createElement($,Object.assign({type_name:"string"},B)),y.a.createElement("span",Object.assign({className:"string-value"},ce,{onClick:this.toggleCollapsed}),'"',ue,'"'))}}]),O}(y.a.PureComponent),br=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){return y.a.createElement("div",J(this.props.theme,"undefined"),"undefined")}}]),O}(y.a.PureComponent);function Nr(){return(Nr=Object.assign||function(q){for(var W=1;W<arguments.length;W++){var O=arguments[W];for(var B in O)Object.prototype.hasOwnProperty.call(O,B)&&(q[B]=O[B])}return q}).apply(this,arguments)}var an=k.useLayoutEffect,yo=function(q){var W=Object(k.useRef)(q);return an(function(){W.current=q}),W},Eo=function(q,W){typeof q!="function"?q.current=W:q(W)},jr=function(q,W){var O=Object(k.useRef)();return Object(k.useCallback)(function(B){q.current=B,O.current&&Eo(O.current,null),O.current=W,W&&Eo(W,B)},[W])},pn={"min-height":"0","max-height":"none",height:"0",visibility:"hidden",overflow:"hidden",position:"absolute","z-index":"-1000",top:"0",right:"0"},Mn=function(q){Object.keys(pn).forEach(function(W){q.style.setProperty(W,pn[W],"important")})},mn=null,Po=function(){},me=["borderBottomWidth","borderLeftWidth","borderRightWidth","borderTopWidth","boxSizing","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","paddingBottom","paddingLeft","paddingRight","paddingTop","tabSize","textIndent","textRendering","textTransform","width"],le=!!document.documentElement.currentStyle,ie=function(q,W){var O=q.cacheMeasurements,B=q.maxRows,z=q.minRows,ee=q.onChange,ue=ee===void 0?Po:ee,ce=q.onHeightChange,te=ce===void 0?Po:ce,he=function(Xe,Vt){if(Xe==null)return{};var Hr,ri,_s={},oi=Object.keys(Xe);for(ri=0;ri<oi.length;ri++)Hr=oi[ri],Vt.indexOf(Hr)>=0||(_s[Hr]=Xe[Hr]);return _s}(q,["cacheMeasurements","maxRows","minRows","onChange","onHeightChange"]),Be,He=he.value!==void 0,tt=Object(k.useRef)(null),vt=jr(tt,W),at=Object(k.useRef)(0),Mt=Object(k.useRef)(),en=function(){var Xe=tt.current,Vt=O&&Mt.current?Mt.current:function(oi){var Hu=window.getComputedStyle(oi);if(Hu===null)return null;var Ts,yr=(Ts=Hu,me.reduce(function(Uu,ws){return Uu[ws]=Ts[ws],Uu},{})),Ba=yr.boxSizing;return Ba===""?null:(le&&Ba==="border-box"&&(yr.width=parseFloat(yr.width)+parseFloat(yr.borderRightWidth)+parseFloat(yr.borderLeftWidth)+parseFloat(yr.paddingRight)+parseFloat(yr.paddingLeft)+"px"),{sizingStyle:yr,paddingSize:parseFloat(yr.paddingBottom)+parseFloat(yr.paddingTop),borderSize:parseFloat(yr.borderBottomWidth)+parseFloat(yr.borderTopWidth)})}(Xe);if(Vt){Mt.current=Vt;var Hr=function(oi,Hu,Ts,yr){Ts===void 0&&(Ts=1),yr===void 0&&(yr=1/0),mn||((mn=document.createElement("textarea")).setAttribute("tab-index","-1"),mn.setAttribute("aria-hidden","true"),Mn(mn)),mn.parentNode===null&&document.body.appendChild(mn);var Ba=oi.paddingSize,Uu=oi.borderSize,ws=oi.sizingStyle,qu=ws.boxSizing;Object.keys(ws).forEach(function(Wu){var kl=Wu;mn.style[kl]=ws[kl]}),Mn(mn),mn.value=Hu;var $u=function(Wu,kl){var w1=Wu.scrollHeight;return kl.sizingStyle.boxSizing==="border-box"?w1+kl.borderSize:w1-kl.paddingSize}(mn,oi);mn.value="x";var T1=mn.scrollHeight-Ba,Jc=T1*Ts;qu==="border-box"&&(Jc=Jc+Ba+Uu),$u=Math.max(Jc,$u);var ef=T1*yr;return qu==="border-box"&&(ef=ef+Ba+Uu),[$u=Math.min(ef,$u),T1]}(Vt,Xe.value||Xe.placeholder||"x",z,B),ri=Hr[0],_s=Hr[1];at.current!==ri&&(at.current=ri,Xe.style.setProperty("height",ri+"px","important"),te(ri,{rowHeight:_s}))}};return Object(k.useLayoutEffect)(en),Be=yo(en),Object(k.useLayoutEffect)(function(){var Xe=function(Vt){Be.current(Vt)};return window.addEventListener("resize",Xe),function(){window.removeEventListener("resize",Xe)}},[]),Object(k.createElement)("textarea",Nr({},he,{onChange:function(Xe){He||en(),ue(Xe)},ref:vt}))},G=Object(k.forwardRef)(ie);function ae(q){q=q.trim();try{if((q=JSON.stringify(JSON.parse(q)))[0]==="[")return Te("array",JSON.parse(q));if(q[0]==="{")return Te("object",JSON.parse(q));if(q.match(/\-?\d+\.\d+/)&&q.match(/\-?\d+\.\d+/)[0]===q)return Te("float",parseFloat(q));if(q.match(/\-?\d+e-\d+/)&&q.match(/\-?\d+e-\d+/)[0]===q)return Te("float",Number(q));if(q.match(/\-?\d+/)&&q.match(/\-?\d+/)[0]===q)return Te("integer",parseInt(q));if(q.match(/\-?\d+e\+\d+/)&&q.match(/\-?\d+e\+\d+/)[0]===q)return Te("integer",Number(q))}catch{}switch(q=q.toLowerCase()){case"undefined":return Te("undefined",void 0);case"nan":return Te("nan",NaN);case"null":return Te("null",null);case"true":return Te("boolean",!0);case"false":return Te("boolean",!1);default:if(q=Date.parse(q))return Te("date",new Date(q))}return Te(!1,null)}function Te(q,W){return{type:q,value:W}}var Oe=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 24 24",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("path",{d:"M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M7,13H17V11H7"})))}}]),O}(y.a.PureComponent),$e=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 24 24",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("path",{d:"M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M13,7H11V11H7V13H11V17H13V13H17V11H13V7Z"})))}}]),O}(y.a.PureComponent),_t=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]),ue=kt(z).style;return y.a.createElement("span",ee,y.a.createElement("svg",{fill:ue.color,width:ue.height,height:ue.width,style:ue,viewBox:"0 0 1792 1792"},y.a.createElement("path",{d:"M1344 800v64q0 14-9 23t-23 9h-832q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h832q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z"})))}}]),O}(y.a.PureComponent),Qe=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]),ue=kt(z).style;return y.a.createElement("span",ee,y.a.createElement("svg",{fill:ue.color,width:ue.height,height:ue.width,style:ue,viewBox:"0 0 1792 1792"},y.a.createElement("path",{d:"M1344 800v64q0 14-9 23t-23 9h-352v352q0 14-9 23t-23 9h-64q-14 0-23-9t-9-23v-352h-352q-14 0-23-9t-9-23v-64q0-14 9-23t23-9h352v-352q0-14 9-23t23-9h64q14 0 23 9t9 23v352h352q14 0 23 9t9 23zm128 448v-832q0-66-47-113t-113-47h-832q-66 0-113 47t-47 113v832q0 66 47 113t113 47h832q66 0 113-47t47-113zm128-832v832q0 119-84.5 203.5t-203.5 84.5h-832q-119 0-203.5-84.5t-84.5-203.5v-832q0-119 84.5-203.5t203.5-84.5h832q119 0 203.5 84.5t84.5 203.5z"})))}}]),O}(y.a.PureComponent),lt=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",{style:l(l({},kt(z).style),{},{paddingLeft:"2px",verticalAlign:"top"}),viewBox:"0 0 15 15",fill:"currentColor"},y.a.createElement("path",{d:"M0 14l6-6-6-6z"})))}}]),O}(y.a.PureComponent),Kt=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",{style:l(l({},kt(z).style),{},{paddingLeft:"2px",verticalAlign:"top"}),viewBox:"0 0 15 15",fill:"currentColor"},y.a.createElement("path",{d:"M0 5l6 6 6-6z"})))}}]),O}(y.a.PureComponent),Pt=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 40 40",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("g",null,y.a.createElement("path",{d:"m30 35h-25v-22.5h25v7.5h2.5v-12.5c0-1.4-1.1-2.5-2.5-2.5h-7.5c0-2.8-2.2-5-5-5s-5 2.2-5 5h-7.5c-1.4 0-2.5 1.1-2.5 2.5v27.5c0 1.4 1.1 2.5 2.5 2.5h25c1.4 0 2.5-1.1 2.5-2.5v-5h-2.5v5z m-20-27.5h2.5s2.5-1.1 2.5-2.5 1.1-2.5 2.5-2.5 2.5 1.1 2.5 2.5 1.3 2.5 2.5 2.5h2.5s2.5 1.1 2.5 2.5h-20c0-1.5 1.1-2.5 2.5-2.5z m-2.5 20h5v-2.5h-5v2.5z m17.5-5v-5l-10 7.5 10 7.5v-5h12.5v-5h-12.5z m-17.5 10h7.5v-2.5h-7.5v2.5z m12.5-17.5h-12.5v2.5h12.5v-2.5z m-7.5 5h-5v2.5h5v-2.5z"}))))}}]),O}(y.a.PureComponent),gt=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 40 40",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("g",null,y.a.createElement("path",{d:"m28.6 25q0-0.5-0.4-1l-4-4 4-4q0.4-0.5 0.4-1 0-0.6-0.4-1.1l-2-2q-0.4-0.4-1-0.4-0.6 0-1 0.4l-4.1 4.1-4-4.1q-0.4-0.4-1-0.4-0.6 0-1 0.4l-2 2q-0.5 0.5-0.5 1.1 0 0.5 0.5 1l4 4-4 4q-0.5 0.5-0.5 1 0 0.7 0.5 1.1l2 2q0.4 0.4 1 0.4 0.6 0 1-0.4l4-4.1 4.1 4.1q0.4 0.4 1 0.4 0.6 0 1-0.4l2-2q0.4-0.4 0.4-1z m8.7-5q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z"}))))}}]),O}(y.a.PureComponent),Ln=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 40 40",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("g",null,y.a.createElement("path",{d:"m30.1 21.4v-2.8q0-0.6-0.4-1t-1-0.5h-5.7v-5.7q0-0.6-0.4-1t-1-0.4h-2.9q-0.6 0-1 0.4t-0.4 1v5.7h-5.7q-0.6 0-1 0.5t-0.5 1v2.8q0 0.6 0.5 1t1 0.5h5.7v5.7q0 0.5 0.4 1t1 0.4h2.9q0.6 0 1-0.4t0.4-1v-5.7h5.7q0.6 0 1-0.5t0.4-1z m7.2-1.4q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z"}))))}}]),O}(y.a.PureComponent),Tn=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 40 40",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("g",null,y.a.createElement("path",{d:"m31.6 21.6h-10v10h-3.2v-10h-10v-3.2h10v-10h3.2v10h10v3.2z"}))))}}]),O}(y.a.PureComponent),zr=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 40 40",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("g",null,y.a.createElement("path",{d:"m19.8 26.4l2.6-2.6-3.4-3.4-2.6 2.6v1.3h2.2v2.1h1.2z m9.8-16q-0.3-0.4-0.7 0l-7.8 7.8q-0.4 0.4 0 0.7t0.7 0l7.8-7.8q0.4-0.4 0-0.7z m1.8 13.2v4.3q0 2.6-1.9 4.5t-4.5 1.9h-18.6q-2.6 0-4.5-1.9t-1.9-4.5v-18.6q0-2.7 1.9-4.6t4.5-1.8h18.6q1.4 0 2.6 0.5 0.3 0.2 0.4 0.5 0.1 0.4-0.2 0.7l-1.1 1.1q-0.3 0.3-0.7 0.1-0.5-0.1-1-0.1h-18.6q-1.4 0-2.5 1.1t-1 2.5v18.6q0 1.4 1 2.5t2.5 1h18.6q1.5 0 2.5-1t1.1-2.5v-2.9q0-0.2 0.2-0.4l1.4-1.5q0.3-0.3 0.8-0.1t0.4 0.6z m-2.1-16.5l6.4 6.5-15 15h-6.4v-6.5z m9.9 3l-2.1 2-6.4-6.4 2.1-2q0.6-0.7 1.5-0.7t1.5 0.7l3.4 3.4q0.6 0.6 0.6 1.5t-0.6 1.5z"}))))}}]),O}(y.a.PureComponent),wn=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.style,ee=I(B,["style"]);return y.a.createElement("span",ee,y.a.createElement("svg",Object.assign({},kt(z),{viewBox:"0 0 40 40",fill:"currentColor",preserveAspectRatio:"xMidYMid meet"}),y.a.createElement("g",null,y.a.createElement("path",{d:"m31.7 16.4q0-0.6-0.4-1l-2.1-2.1q-0.4-0.4-1-0.4t-1 0.4l-9.1 9.1-5-5q-0.5-0.4-1-0.4t-1 0.4l-2.1 2q-0.4 0.4-0.4 1 0 0.6 0.4 1l8.1 8.1q0.4 0.4 1 0.4 0.6 0 1-0.4l12.2-12.1q0.4-0.4 0.4-1z m5.6 3.6q0 4.7-2.3 8.6t-6.3 6.2-8.6 2.3-8.6-2.3-6.2-6.2-2.3-8.6 2.3-8.6 6.2-6.2 8.6-2.3 8.6 2.3 6.3 6.2 2.3 8.6z"}))))}}]),O}(y.a.PureComponent);function kt(q){return q||(q={}),{style:l(l({verticalAlign:"middle"},q),{},{color:q.color?q.color:"#000000",height:"1em",width:"1em"})}}var nr=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).copiedTimer=null,z.handleCopy=function(){var ee=document.createElement("textarea"),ue=z.props,ce=ue.clickCallback,te=ue.src,he=ue.namespace;ee.innerHTML=JSON.stringify(z.clipboardValue(te),null," "),document.body.appendChild(ee),ee.select(),document.execCommand("copy"),document.body.removeChild(ee),z.copiedTimer=setTimeout(function(){z.setState({copied:!1})},5500),z.setState({copied:!0},function(){typeof ce=="function"&&ce({src:te,namespace:he,name:he[he.length-1]})})},z.getClippyIcon=function(){var ee=z.props.theme;return z.state.copied?y.a.createElement("span",null,y.a.createElement(Pt,Object.assign({className:"copy-icon"},J(ee,"copy-icon"))),y.a.createElement("span",J(ee,"copy-icon-copied"),"✔")):y.a.createElement(Pt,Object.assign({className:"copy-icon"},J(ee,"copy-icon")))},z.clipboardValue=function(ee){switch(j(ee)){case"function":case"regexp":return ee.toString();default:return ee}},z.state={copied:!1},z}return h(O,[{key:"componentWillUnmount",value:function(){this.copiedTimer&&(clearTimeout(this.copiedTimer),this.copiedTimer=null)}},{key:"render",value:function(){var B=this.props,z=(B.src,B.theme),ee=B.hidden,ue=B.rowHovered,ce=J(z,"copy-to-clipboard").style,te="inline";return ee&&(te="none"),y.a.createElement("span",{className:"copy-to-clipboard-container",title:"Copy to clipboard",style:{verticalAlign:"top",display:ue?"inline-block":"none"}},y.a.createElement("span",{style:l(l({},ce),{},{display:te}),onClick:this.handleCopy},this.getClippyIcon()))}}]),O}(y.a.PureComponent),dr=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).getEditIcon=function(){var ee=z.props,ue=ee.variable,ce=ee.theme;return y.a.createElement("div",{className:"click-to-edit",style:{verticalAlign:"top",display:z.state.hovered?"inline-block":"none"}},y.a.createElement(zr,Object.assign({className:"click-to-edit-icon"},J(ce,"editVarIcon"),{onClick:function(){z.prepopInput(ue)}})))},z.prepopInput=function(ee){if(z.props.onEdit!==!1){var ue=function(te){var he;switch(j(te)){case"undefined":he="undefined";break;case"nan":he="NaN";break;case"string":he=te;break;case"date":case"function":case"regexp":he=te.toString();break;default:try{he=JSON.stringify(te,null," ")}catch{he=""}}return he}(ee.value),ce=ae(ue);z.setState({editMode:!0,editValue:ue,parsedInput:{type:ce.type,value:ce.value}})}},z.getRemoveIcon=function(){var ee=z.props,ue=ee.variable,ce=ee.namespace,te=ee.theme,he=ee.rjvId;return y.a.createElement("div",{className:"click-to-remove",style:{verticalAlign:"top",display:z.state.hovered?"inline-block":"none"}},y.a.createElement(gt,Object.assign({className:"click-to-remove-icon"},J(te,"removeVarIcon"),{onClick:function(){Le.dispatch({name:"VARIABLE_REMOVED",rjvId:he,data:{name:ue.name,namespace:ce,existing_value:ue.value,variable_removed:!0}})}})))},z.getValue=function(ee,ue){var ce=!ue&&ee.type,te=b(z).props;switch(ce){case!1:return z.getEditInput();case"string":return y.a.createElement(In,Object.assign({value:ee.value},te));case"integer":return y.a.createElement(er,Object.assign({value:ee.value},te));case"float":return y.a.createElement(fe,Object.assign({value:ee.value},te));case"boolean":return y.a.createElement(_e,Object.assign({value:ee.value},te));case"function":return y.a.createElement(rt,Object.assign({value:ee.value},te));case"null":return y.a.createElement(qn,te);case"nan":return y.a.createElement(Zt,te);case"undefined":return y.a.createElement(br,te);case"date":return y.a.createElement(ve,Object.assign({value:ee.value},te));case"regexp":return y.a.createElement(tr,Object.assign({value:ee.value},te));default:return y.a.createElement("div",{className:"object-value"},JSON.stringify(ee.value))}},z.getEditInput=function(){var ee=z.props.theme,ue=z.state.editValue;return y.a.createElement("div",null,y.a.createElement(G,Object.assign({type:"text",inputRef:function(ce){return ce&&ce.focus()},value:ue,className:"variable-editor",onChange:function(ce){var te=ce.target.value,he=ae(te);z.setState({editValue:te,parsedInput:{type:he.type,value:he.value}})},onKeyDown:function(ce){switch(ce.key){case"Escape":z.setState({editMode:!1,editValue:""});break;case"Enter":(ce.ctrlKey||ce.metaKey)&&z.submitEdit(!0)}ce.stopPropagation()},placeholder:"update this value",minRows:2},J(ee,"edit-input"))),y.a.createElement("div",J(ee,"edit-icon-container"),y.a.createElement(gt,Object.assign({className:"edit-cancel"},J(ee,"cancel-icon"),{onClick:function(){z.setState({editMode:!1,editValue:""})}})),y.a.createElement(wn,Object.assign({className:"edit-check string-value"},J(ee,"check-icon"),{onClick:function(){z.submitEdit()}})),y.a.createElement("div",null,z.showDetected())))},z.submitEdit=function(ee){var ue=z.props,ce=ue.variable,te=ue.namespace,he=ue.rjvId,Be=z.state,He=Be.editValue,tt=Be.parsedInput,vt=He;ee&&tt.type&&(vt=tt.value),z.setState({editMode:!1}),Le.dispatch({name:"VARIABLE_UPDATED",rjvId:he,data:{name:ce.name,namespace:te,existing_value:ce.value,new_value:vt,variable_removed:!1}})},z.showDetected=function(){var ee=z.props,ue=ee.theme,ce=(ee.variable,ee.namespace,ee.rjvId,z.state.parsedInput),te=(ce.type,ce.value,z.getDetectedInput());if(te)return y.a.createElement("div",null,y.a.createElement("div",J(ue,"detected-row"),te,y.a.createElement(wn,{className:"edit-check detected",style:l({verticalAlign:"top",paddingLeft:"3px"},J(ue,"check-icon").style),onClick:function(){z.submitEdit(!0)}})))},z.getDetectedInput=function(){var ee=z.state.parsedInput,ue=ee.type,ce=ee.value,te=b(z).props,he=te.theme;if(ue!==!1)switch(ue.toLowerCase()){case"object":return y.a.createElement("span",null,y.a.createElement("span",{style:l(l({},J(he,"brace").style),{},{cursor:"default"})},"{"),y.a.createElement("span",{style:l(l({},J(he,"ellipsis").style),{},{cursor:"default"})},"..."),y.a.createElement("span",{style:l(l({},J(he,"brace").style),{},{cursor:"default"})},"}"));case"array":return y.a.createElement("span",null,y.a.createElement("span",{style:l(l({},J(he,"brace").style),{},{cursor:"default"})},"["),y.a.createElement("span",{style:l(l({},J(he,"ellipsis").style),{},{cursor:"default"})},"..."),y.a.createElement("span",{style:l(l({},J(he,"brace").style),{},{cursor:"default"})},"]"));case"string":return y.a.createElement(In,Object.assign({value:ce},te));case"integer":return y.a.createElement(er,Object.assign({value:ce},te));case"float":return y.a.createElement(fe,Object.assign({value:ce},te));case"boolean":return y.a.createElement(_e,Object.assign({value:ce},te));case"function":return y.a.createElement(rt,Object.assign({value:ce},te));case"null":return y.a.createElement(qn,te);case"nan":return y.a.createElement(Zt,te);case"undefined":return y.a.createElement(br,te);case"date":return y.a.createElement(ve,Object.assign({value:new Date(ce)},te))}},z.state={editMode:!1,editValue:"",hovered:!1,renameKey:!1,parsedInput:{type:!1,value:null}},z}return h(O,[{key:"render",value:function(){var B=this,z=this.props,ee=z.variable,ue=z.singleIndent,ce=z.type,te=z.theme,he=z.namespace,Be=z.indentWidth,He=z.enableClipboard,tt=z.onEdit,vt=z.onDelete,at=z.onSelect,Mt=z.displayArrayKey,en=z.quotesOnKeys,Xe=this.state.editMode;return y.a.createElement("div",Object.assign({},J(te,"objectKeyVal",{paddingLeft:Be*ue}),{onMouseEnter:function(){return B.setState(l(l({},B.state),{},{hovered:!0}))},onMouseLeave:function(){return B.setState(l(l({},B.state),{},{hovered:!1}))},className:"variable-row",key:ee.name}),ce=="array"?Mt?y.a.createElement("span",Object.assign({},J(te,"array-key"),{key:ee.name+"_"+he}),ee.name,y.a.createElement("div",J(te,"colon"),":")):null:y.a.createElement("span",null,y.a.createElement("span",Object.assign({},J(te,"object-name"),{className:"object-key",key:ee.name+"_"+he}),!!en&&y.a.createElement("span",{style:{verticalAlign:"top"}},'"'),y.a.createElement("span",{style:{display:"inline-block"}},ee.name),!!en&&y.a.createElement("span",{style:{verticalAlign:"top"}},'"')),y.a.createElement("span",J(te,"colon"),":")),y.a.createElement("div",Object.assign({className:"variable-value",onClick:at===!1&&tt===!1?null:function(Vt){var Hr=Ue(he);(Vt.ctrlKey||Vt.metaKey)&&tt!==!1?B.prepopInput(ee):at!==!1&&(Hr.shift(),at(l(l({},ee),{},{namespace:Hr})))}},J(te,"variableValue",{cursor:at===!1?"default":"pointer"})),this.getValue(ee,Xe)),He?y.a.createElement(nr,{rowHovered:this.state.hovered,hidden:Xe,src:ee.value,clickCallback:He,theme:te,namespace:[].concat(Ue(he),[ee.name])}):null,tt!==!1&&Xe==0?this.getEditIcon():null,vt!==!1&&Xe==0?this.getRemoveIcon():null)}}]),O}(y.a.PureComponent),rr=function(q){m(O,q);var W=w(O);function O(){var B;u(this,O);for(var z=arguments.length,ee=new Array(z),ue=0;ue<z;ue++)ee[ue]=arguments[ue];return(B=W.call.apply(W,[this].concat(ee))).getObjectSize=function(){var ce=B.props,te=ce.size,he=ce.theme;if(ce.displayObjectSize)return y.a.createElement("span",Object.assign({className:"object-size"},J(he,"object-size")),te," item",te===1?"":"s")},B.getAddAttribute=function(ce){var te=B.props,he=te.theme,Be=te.namespace,He=te.name,tt=te.src,vt=te.rjvId,at=te.depth;return y.a.createElement("span",{className:"click-to-add",style:{verticalAlign:"top",display:ce?"inline-block":"none"}},y.a.createElement(Ln,Object.assign({className:"click-to-add-icon"},J(he,"addVarIcon"),{onClick:function(){var Mt={name:at>0?He:null,namespace:Be.splice(0,Be.length-1),existing_value:tt,variable_removed:!1,key_name:null};j(tt)==="object"?Le.dispatch({name:"ADD_VARIABLE_KEY_REQUEST",rjvId:vt,data:Mt}):Le.dispatch({name:"VARIABLE_ADDED",rjvId:vt,data:l(l({},Mt),{},{new_value:[].concat(Ue(tt),[null])})})}})))},B.getRemoveObject=function(ce){var te=B.props,he=te.theme,Be=(te.hover,te.namespace),He=te.name,tt=te.src,vt=te.rjvId;if(Be.length!==1)return y.a.createElement("span",{className:"click-to-remove",style:{display:ce?"inline-block":"none"}},y.a.createElement(gt,Object.assign({className:"click-to-remove-icon"},J(he,"removeVarIcon"),{onClick:function(){Le.dispatch({name:"VARIABLE_REMOVED",rjvId:vt,data:{name:He,namespace:Be.splice(0,Be.length-1),existing_value:tt,variable_removed:!0}})}})))},B.render=function(){var ce=B.props,te=ce.theme,he=ce.onDelete,Be=ce.onAdd,He=ce.enableClipboard,tt=ce.src,vt=ce.namespace,at=ce.rowHovered;return y.a.createElement("div",Object.assign({},J(te,"object-meta-data"),{className:"object-meta-data",onClick:function(Mt){Mt.stopPropagation()}}),B.getObjectSize(),He?y.a.createElement(nr,{rowHovered:at,clickCallback:He,src:tt,theme:te,namespace:vt}):null,Be!==!1?B.getAddAttribute(at):null,he!==!1?B.getRemoveObject(at):null)},B}return O}(y.a.PureComponent);function to(q){var W=q.parent_type,O=q.namespace,B=q.quotesOnKeys,z=q.theme,ee=q.jsvRoot,ue=q.name,ce=q.displayArrayKey,te=q.name?q.name:"";return!ee||ue!==!1&&ue!==null?W=="array"?ce?y.a.createElement("span",Object.assign({},J(z,"array-key"),{key:O}),y.a.createElement("span",{className:"array-key"},te),y.a.createElement("span",J(z,"colon"),":")):y.a.createElement("span",null):y.a.createElement("span",Object.assign({},J(z,"object-name"),{key:O}),y.a.createElement("span",{className:"object-key"},B&&y.a.createElement("span",{style:{verticalAlign:"top"}},'"'),y.a.createElement("span",null,te),B&&y.a.createElement("span",{style:{verticalAlign:"top"}},'"')),y.a.createElement("span",J(z,"colon"),":")):y.a.createElement("span",null)}function Fr(q){var W=q.theme;switch(q.iconStyle){case"triangle":return y.a.createElement(Kt,Object.assign({},J(W,"expanded-icon"),{className:"expanded-icon"}));case"square":return y.a.createElement(_t,Object.assign({},J(W,"expanded-icon"),{className:"expanded-icon"}));default:return y.a.createElement(Oe,Object.assign({},J(W,"expanded-icon"),{className:"expanded-icon"}))}}function _o(q){var W=q.theme;switch(q.iconStyle){case"triangle":return y.a.createElement(lt,Object.assign({},J(W,"collapsed-icon"),{className:"collapsed-icon"}));case"square":return y.a.createElement(Qe,Object.assign({},J(W,"collapsed-icon"),{className:"collapsed-icon"}));default:return y.a.createElement($e,Object.assign({},J(W,"collapsed-icon"),{className:"collapsed-icon"}))}}var Ia=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).toggleCollapsed=function(ee){var ue=[];for(var ce in z.state.expanded)ue.push(z.state.expanded[ce]);ue[ee]=!ue[ee],z.setState({expanded:ue})},z.state={expanded:[]},z}return h(O,[{key:"getExpandedIcon",value:function(B){var z=this.props,ee=z.theme,ue=z.iconStyle;return this.state.expanded[B]?y.a.createElement(Fr,{theme:ee,iconStyle:ue}):y.a.createElement(_o,{theme:ee,iconStyle:ue})}},{key:"render",value:function(){var B=this,z=this.props,ee=z.src,ue=z.groupArraysAfterLength,ce=(z.depth,z.name),te=z.theme,he=z.jsvRoot,Be=z.namespace,He=(z.parent_type,I(z,["src","groupArraysAfterLength","depth","name","theme","jsvRoot","namespace","parent_type"])),tt=0,vt=5*this.props.indentWidth;he||(tt=5*this.props.indentWidth);var at=ue,Mt=Math.ceil(ee.length/at);return y.a.createElement("div",Object.assign({className:"object-key-val"},J(te,he?"jsv-root":"objectKeyVal",{paddingLeft:tt})),y.a.createElement(to,this.props),y.a.createElement("span",null,y.a.createElement(rr,Object.assign({size:ee.length},this.props))),Ue(Array(Mt)).map(function(en,Xe){return y.a.createElement("div",Object.assign({key:Xe,className:"object-key-val array-group"},J(te,"objectKeyVal",{marginLeft:6,paddingLeft:vt})),y.a.createElement("span",J(te,"brace-row"),y.a.createElement("div",Object.assign({className:"icon-container"},J(te,"icon-container"),{onClick:function(Vt){B.toggleCollapsed(Xe)}}),B.getExpandedIcon(Xe)),B.state.expanded[Xe]?y.a.createElement(ki,Object.assign({key:ce+Xe,depth:0,name:!1,collapsed:!1,groupArraysAfterLength:at,index_offset:Xe*at,src:ee.slice(Xe*at,Xe*at+at),namespace:Be,type:"array",parent_type:"array_group",theme:te},He)):y.a.createElement("span",Object.assign({},J(te,"brace"),{onClick:function(Vt){B.toggleCollapsed(Xe)},className:"array-group-brace"}),"[",y.a.createElement("div",Object.assign({},J(te,"array-group-meta-data"),{className:"array-group-meta-data"}),y.a.createElement("span",Object.assign({className:"object-size"},J(te,"object-size")),Xe*at," - ",Xe*at+at>ee.length?ee.length:Xe*at+at)),"]")))}))}}]),O}(y.a.PureComponent),wi=function(q){m(O,q);var W=w(O);function O(B){var z;u(this,O),(z=W.call(this,B)).toggleCollapsed=function(){z.setState({expanded:!z.state.expanded},function(){We.set(z.props.rjvId,z.props.namespace,"expanded",z.state.expanded)})},z.getObjectContent=function(ue,ce,te){return y.a.createElement("div",{className:"pushed-content object-container"},y.a.createElement("div",Object.assign({className:"object-content"},J(z.props.theme,"pushed-content")),z.renderObjectContents(ce,te)))},z.getEllipsis=function(){return z.state.size===0?null:y.a.createElement("div",Object.assign({},J(z.props.theme,"ellipsis"),{className:"node-ellipsis",onClick:z.toggleCollapsed}),"...")},z.getObjectMetaData=function(ue){var ce=z.props,te=(ce.rjvId,ce.theme,z.state),he=te.size,Be=te.hovered;return y.a.createElement(rr,Object.assign({rowHovered:Be,size:he},z.props))},z.renderObjectContents=function(ue,ce){var te,he=z.props,Be=he.depth,He=he.parent_type,tt=he.index_offset,vt=he.groupArraysAfterLength,at=he.namespace,Mt=z.state.object_type,en=[],Xe=Object.keys(ue||{});return z.props.sortKeys&&Mt!=="array"&&(Xe=Xe.sort()),Xe.forEach(function(Vt){if(te=new ju(Vt,ue[Vt]),He==="array_group"&&tt&&(te.name=parseInt(te.name)+tt),ue.hasOwnProperty(Vt))if(te.type==="object")en.push(y.a.createElement(ki,Object.assign({key:te.name,depth:Be+1,name:te.name,src:te.value,namespace:at.concat(te.name),parent_type:Mt},ce)));else if(te.type==="array"){var Hr=ki;vt&&te.value.length>vt&&(Hr=Ia),en.push(y.a.createElement(Hr,Object.assign({key:te.name,depth:Be+1,name:te.name,src:te.value,namespace:at.concat(te.name),type:"array",parent_type:Mt},ce)))}else en.push(y.a.createElement(dr,Object.assign({key:te.name+"_"+at,variable:te,singleIndent:5,namespace:at,type:z.props.type},ce)))}),en};var ee=O.getState(B);return z.state=l(l({},ee),{},{prevProps:{}}),z}return h(O,[{key:"getBraceStart",value:function(B,z){var ee=this,ue=this.props,ce=ue.src,te=ue.theme,he=ue.iconStyle;if(ue.parent_type==="array_group")return y.a.createElement("span",null,y.a.createElement("span",J(te,"brace"),B==="array"?"[":"{"),z?this.getObjectMetaData(ce):null);var Be=z?Fr:_o;return y.a.createElement("span",null,y.a.createElement("span",Object.assign({onClick:function(He){ee.toggleCollapsed()}},J(te,"brace-row")),y.a.createElement("div",Object.assign({className:"icon-container"},J(te,"icon-container")),y.a.createElement(Be,{theme:te,iconStyle:he})),y.a.createElement(to,this.props),y.a.createElement("span",J(te,"brace"),B==="array"?"[":"{")),z?this.getObjectMetaData(ce):null)}},{key:"render",value:function(){var B=this,z=this.props,ee=z.depth,ue=z.src,ce=(z.namespace,z.name,z.type,z.parent_type),te=z.theme,he=z.jsvRoot,Be=z.iconStyle,He=I(z,["depth","src","namespace","name","type","parent_type","theme","jsvRoot","iconStyle"]),tt=this.state,vt=tt.object_type,at=tt.expanded,Mt={};return he||ce==="array_group"?ce==="array_group"&&(Mt.borderLeft=0,Mt.display="inline"):Mt.paddingLeft=5*this.props.indentWidth,y.a.createElement("div",Object.assign({className:"object-key-val",onMouseEnter:function(){return B.setState(l(l({},B.state),{},{hovered:!0}))},onMouseLeave:function(){return B.setState(l(l({},B.state),{},{hovered:!1}))}},J(te,he?"jsv-root":"objectKeyVal",Mt)),this.getBraceStart(vt,at),at?this.getObjectContent(ee,ue,l({theme:te,iconStyle:Be},He)):this.getEllipsis(),y.a.createElement("span",{className:"brace-row"},y.a.createElement("span",{style:l(l({},J(te,"brace").style),{},{paddingLeft:at?"3px":"0px"})},vt==="array"?"]":"}"),at?null:this.getObjectMetaData(ue)))}}],[{key:"getDerivedStateFromProps",value:function(B,z){var ee=z.prevProps;return B.src!==ee.src||B.collapsed!==ee.collapsed||B.name!==ee.name||B.namespace!==ee.namespace||B.rjvId!==ee.rjvId?l(l({},O.getState(B)),{},{prevProps:B}):null}}]),O}(y.a.PureComponent);wi.getState=function(q){var W=Object.keys(q.src).length,O=(q.collapsed===!1||q.collapsed!==!0&&q.collapsed>q.depth)&&(!q.shouldCollapse||q.shouldCollapse({name:q.name,src:q.src,type:j(q.src),namespace:q.namespace})===!1)&&W!==0;return{expanded:We.get(q.rjvId,q.namespace,"expanded",O),object_type:q.type==="array"?"array":"object",parent_type:q.type==="array"?"array":"object",size:W,hovered:!1}};var ju=function q(W,O){u(this,q),this.name=W,this.value=O,this.type=j(O)};P(wi);var ki=wi,_1=function(q){m(O,q);var W=w(O);function O(){var B;u(this,O);for(var z=arguments.length,ee=new Array(z),ue=0;ue<z;ue++)ee[ue]=arguments[ue];return(B=W.call.apply(W,[this].concat(ee))).render=function(){var ce=b(B).props,te=[ce.name],he=ki;return Array.isArray(ce.src)&&ce.groupArraysAfterLength&&ce.src.length>ce.groupArraysAfterLength&&(he=Ia),y.a.createElement("div",{className:"pretty-json-container object-container"},y.a.createElement("div",{className:"object-content"},y.a.createElement(he,Object.assign({namespace:te,depth:0,jsvRoot:!0},ce))))},B}return O}(y.a.PureComponent),Xc=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).closeModal=function(){Le.dispatch({rjvId:z.props.rjvId,name:"RESET"})},z.submit=function(){z.props.submit(z.state.input)},z.state={input:B.input?B.input:""},z}return h(O,[{key:"render",value:function(){var B=this,z=this.props,ee=z.theme,ue=z.rjvId,ce=z.isValid,te=this.state.input,he=ce(te);return y.a.createElement("div",Object.assign({className:"key-modal-request"},J(ee,"key-modal-request"),{onClick:this.closeModal}),y.a.createElement("div",Object.assign({},J(ee,"key-modal"),{onClick:function(Be){Be.stopPropagation()}}),y.a.createElement("div",J(ee,"key-modal-label"),"Key Name:"),y.a.createElement("div",{style:{position:"relative"}},y.a.createElement("input",Object.assign({},J(ee,"key-modal-input"),{className:"key-modal-input",ref:function(Be){return Be&&Be.focus()},spellCheck:!1,value:te,placeholder:"...",onChange:function(Be){B.setState({input:Be.target.value})},onKeyPress:function(Be){he&&Be.key==="Enter"?B.submit():Be.key==="Escape"&&B.closeModal()}})),he?y.a.createElement(wn,Object.assign({},J(ee,"key-modal-submit"),{className:"key-modal-submit",onClick:function(Be){return B.submit()}})):null),y.a.createElement("span",J(ee,"key-modal-cancel"),y.a.createElement(Tn,Object.assign({},J(ee,"key-modal-cancel-icon"),{className:"key-modal-cancel",onClick:function(){Le.dispatch({rjvId:ue,name:"RESET"})}})))))}}]),O}(y.a.PureComponent),Zc=function(q){m(O,q);var W=w(O);function O(){var B;u(this,O);for(var z=arguments.length,ee=new Array(z),ue=0;ue<z;ue++)ee[ue]=arguments[ue];return(B=W.call.apply(W,[this].concat(ee))).isValid=function(ce){var te=B.props.rjvId,he=We.get(te,"action","new-key-request");return ce!=""&&Object.keys(he.existing_value).indexOf(ce)===-1},B.submit=function(ce){var te=B.props.rjvId,he=We.get(te,"action","new-key-request");he.new_value=l({},he.existing_value),he.new_value[ce]=B.props.defaultValue,Le.dispatch({name:"VARIABLE_ADDED",rjvId:te,data:he})},B}return h(O,[{key:"render",value:function(){var B=this.props,z=B.active,ee=B.theme,ue=B.rjvId;return z?y.a.createElement(Xc,{rjvId:ue,theme:ee,isValid:this.isValid,submit:this.submit}):null}}]),O}(y.a.PureComponent),zu=function(q){m(O,q);var W=w(O);function O(){return u(this,O),W.apply(this,arguments)}return h(O,[{key:"render",value:function(){var B=this.props,z=B.message,ee=B.active,ue=B.theme,ce=B.rjvId;return ee?y.a.createElement("div",Object.assign({className:"validation-failure"},J(ue,"validation-failure"),{onClick:function(){Le.dispatch({rjvId:ce,name:"RESET"})}}),y.a.createElement("span",J(ue,"validation-failure-label"),z),y.a.createElement(Tn,J(ue,"validation-failure-clear"))):null}}]),O}(y.a.PureComponent),Es=function(q){m(O,q);var W=w(O);function O(B){var z;return u(this,O),(z=W.call(this,B)).rjvId=Date.now().toString(),z.getListeners=function(){return{reset:z.resetState,"variable-update":z.updateSrc,"add-key-request":z.addKeyRequest}},z.updateSrc=function(){var ee,ue=We.get(z.rjvId,"action","variable-update"),ce=ue.name,te=ue.namespace,he=ue.new_value,Be=ue.existing_value,He=(ue.variable_removed,ue.updated_src),tt=ue.type,vt=z.props,at=vt.onEdit,Mt=vt.onDelete,en=vt.onAdd,Xe={existing_src:z.state.src,new_value:he,updated_src:He,name:ce,namespace:te,existing_value:Be};switch(tt){case"variable-added":ee=en(Xe);break;case"variable-edited":ee=at(Xe);break;case"variable-removed":ee=Mt(Xe)}ee!==!1?(We.set(z.rjvId,"global","src",He),z.setState({src:He})):z.setState({validationFailure:!0})},z.addKeyRequest=function(){z.setState({addKeyRequest:!0})},z.resetState=function(){z.setState({validationFailure:!1,addKeyRequest:!1})},z.state={addKeyRequest:!1,editKeyRequest:!1,validationFailure:!1,src:O.defaultProps.src,name:O.defaultProps.name,theme:O.defaultProps.theme,validationMessage:O.defaultProps.validationMessage,prevSrc:O.defaultProps.src,prevName:O.defaultProps.name,prevTheme:O.defaultProps.theme},z}return h(O,[{key:"componentDidMount",value:function(){We.set(this.rjvId,"global","src",this.state.src);var B=this.getListeners();for(var z in B)We.on(z+"-"+this.rjvId,B[z]);this.setState({addKeyRequest:!1,editKeyRequest:!1})}},{key:"componentDidUpdate",value:function(B,z){z.addKeyRequest!==!1&&this.setState({addKeyRequest:!1}),z.editKeyRequest!==!1&&this.setState({editKeyRequest:!1}),B.src!==this.state.src&&We.set(this.rjvId,"global","src",this.state.src)}},{key:"componentWillUnmount",value:function(){var B=this.getListeners();for(var z in B)We.removeListener(z+"-"+this.rjvId,B[z])}},{key:"render",value:function(){var B=this.state,z=B.validationFailure,ee=B.validationMessage,ue=B.addKeyRequest,ce=B.theme,te=B.src,he=B.name,Be=this.props,He=Be.style,tt=Be.defaultValue;return y.a.createElement("div",{className:"react-json-view",style:l(l({},J(ce,"app-container").style),He)},y.a.createElement(zu,{message:ee,active:z,theme:ce,rjvId:this.rjvId}),y.a.createElement(_1,Object.assign({},this.props,{src:te,name:he,theme:ce,type:j(te),rjvId:this.rjvId})),y.a.createElement(Zc,{active:ue,theme:ce,rjvId:this.rjvId,defaultValue:tt}))}}],[{key:"getDerivedStateFromProps",value:function(B,z){if(B.src!==z.prevSrc||B.name!==z.prevName||B.theme!==z.prevTheme){var ee={src:B.src,name:B.name,theme:B.theme,validationMessage:B.validationMessage,prevSrc:B.src,prevName:B.name,prevTheme:B.theme};return O.validateState(ee)}return null}}]),O}(y.a.PureComponent);Es.defaultProps={src:{},name:"root",theme:"rjv-default",collapsed:!1,collapseStringsAfterLength:!1,shouldCollapse:!1,sortKeys:!1,quotesOnKeys:!0,groupArraysAfterLength:100,indentWidth:4,enableClipboard:!0,displayObjectSize:!0,displayDataTypes:!0,onEdit:!1,onDelete:!1,onAdd:!1,onSelect:!1,iconStyle:"triangle",style:{},validationMessage:"Validation Error",defaultValue:null,displayArrayKey:!0},Es.validateState=function(q){var W={};return j(q.theme)!=="object"||function(O){var B=["base00","base01","base02","base03","base04","base05","base06","base07","base08","base09","base0A","base0B","base0C","base0D","base0E","base0F"];if(j(O)==="object"){for(var z=0;z<B.length;z++)if(!(B[z]in O))return!1;return!0}return!1}(q.theme)||(console.error("react-json-view error:","theme prop must be a theme name or valid base-16 theme object.",'defaulting to "rjv-default" theme'),W.theme="rjv-default"),j(q.src)!=="object"&&j(q.src)!=="array"&&(console.error("react-json-view error:","src property must be a valid json object"),W.name="ERROR",W.src={message:"src property must be a valid json object"}),l(l({},q),W)},P(Es),o.default=Es}])})})(fL);var ZEe=fL.exports;const JEe=xr(ZEe),e_e={'code[class*="language-"]':{color:"#f8f8f2",background:"none",textShadow:"0 1px rgba(0, 0, 0, 0.3)",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{color:"#f8f8f2",background:"#272822",textShadow:"0 1px rgba(0, 0, 0, 0.3)",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:".5em 0",overflow:"auto",borderRadius:"0.3em"},':not(pre) > code[class*="language-"]':{background:"#272822",padding:".1em",borderRadius:".3em",whiteSpace:"normal"},comment:{color:"#8292a2"},prolog:{color:"#8292a2"},doctype:{color:"#8292a2"},cdata:{color:"#8292a2"},punctuation:{color:"#f8f8f2"},namespace:{Opacity:".7"},property:{color:"#f92672"},tag:{color:"#f92672"},constant:{color:"#f92672"},symbol:{color:"#f92672"},deleted:{color:"#f92672"},boolean:{color:"#ae81ff"},number:{color:"#ae81ff"},selector:{color:"#a6e22e"},"attr-name":{color:"#a6e22e"},string:{color:"#a6e22e"},char:{color:"#a6e22e"},builtin:{color:"#a6e22e"},inserted:{color:"#a6e22e"},operator:{color:"#f8f8f2"},entity:{color:"#f8f8f2",cursor:"help"},url:{color:"#f8f8f2"},".language-css .token.string":{color:"#f8f8f2"},".style .token.string":{color:"#f8f8f2"},variable:{color:"#f8f8f2"},atrule:{color:"#e6db74"},"attr-value":{color:"#e6db74"},function:{color:"#e6db74"},"class-name":{color:"#e6db74"},keyword:{color:"#66d9ef"},regex:{color:"#fd971f"},important:{color:"#fd971f",fontWeight:"bold"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"}};var Na={};const t_e=[65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111];Na.REPLACEMENT_CHARACTER="�";Na.CODE_POINTS={EOF:-1,NULL:0,TABULATION:9,CARRIAGE_RETURN:13,LINE_FEED:10,FORM_FEED:12,SPACE:32,EXCLAMATION_MARK:33,QUOTATION_MARK:34,NUMBER_SIGN:35,AMPERSAND:38,APOSTROPHE:39,HYPHEN_MINUS:45,SOLIDUS:47,DIGIT_0:48,DIGIT_9:57,SEMICOLON:59,LESS_THAN_SIGN:60,EQUALS_SIGN:61,GREATER_THAN_SIGN:62,QUESTION_MARK:63,LATIN_CAPITAL_A:65,LATIN_CAPITAL_F:70,LATIN_CAPITAL_X:88,LATIN_CAPITAL_Z:90,RIGHT_SQUARE_BRACKET:93,GRAVE_ACCENT:96,LATIN_SMALL_A:97,LATIN_SMALL_F:102,LATIN_SMALL_X:120,LATIN_SMALL_Z:122,REPLACEMENT_CHARACTER:65533};Na.CODE_POINT_SEQUENCES={DASH_DASH_STRING:[45,45],DOCTYPE_STRING:[68,79,67,84,89,80,69],CDATA_START_STRING:[91,67,68,65,84,65,91],SCRIPT_STRING:[115,99,114,105,112,116],PUBLIC_STRING:[80,85,66,76,73,67],SYSTEM_STRING:[83,89,83,84,69,77]};Na.isSurrogate=function(e){return e>=55296&&e<=57343};Na.isSurrogatePair=function(e){return e>=56320&&e<=57343};Na.getSurrogatePairCodePoint=function(e,t){return(e-55296)*1024+9216+t};Na.isControlCodePoint=function(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159};Na.isUndefinedCodePoint=function(e){return e>=64976&&e<=65007||t_e.indexOf(e)>-1};var ck={controlCharacterInInputStream:"control-character-in-input-stream",noncharacterInInputStream:"noncharacter-in-input-stream",surrogateInInputStream:"surrogate-in-input-stream",nonVoidHtmlElementStartTagWithTrailingSolidus:"non-void-html-element-start-tag-with-trailing-solidus",endTagWithAttributes:"end-tag-with-attributes",endTagWithTrailingSolidus:"end-tag-with-trailing-solidus",unexpectedSolidusInTag:"unexpected-solidus-in-tag",unexpectedNullCharacter:"unexpected-null-character",unexpectedQuestionMarkInsteadOfTagName:"unexpected-question-mark-instead-of-tag-name",invalidFirstCharacterOfTagName:"invalid-first-character-of-tag-name",unexpectedEqualsSignBeforeAttributeName:"unexpected-equals-sign-before-attribute-name",missingEndTagName:"missing-end-tag-name",unexpectedCharacterInAttributeName:"unexpected-character-in-attribute-name",unknownNamedCharacterReference:"unknown-named-character-reference",missingSemicolonAfterCharacterReference:"missing-semicolon-after-character-reference",unexpectedCharacterAfterDoctypeSystemIdentifier:"unexpected-character-after-doctype-system-identifier",unexpectedCharacterInUnquotedAttributeValue:"unexpected-character-in-unquoted-attribute-value",eofBeforeTagName:"eof-before-tag-name",eofInTag:"eof-in-tag",missingAttributeValue:"missing-attribute-value",missingWhitespaceBetweenAttributes:"missing-whitespace-between-attributes",missingWhitespaceAfterDoctypePublicKeyword:"missing-whitespace-after-doctype-public-keyword",missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers:"missing-whitespace-between-doctype-public-and-system-identifiers",missingWhitespaceAfterDoctypeSystemKeyword:"missing-whitespace-after-doctype-system-keyword",missingQuoteBeforeDoctypePublicIdentifier:"missing-quote-before-doctype-public-identifier",missingQuoteBeforeDoctypeSystemIdentifier:"missing-quote-before-doctype-system-identifier",missingDoctypePublicIdentifier:"missing-doctype-public-identifier",missingDoctypeSystemIdentifier:"missing-doctype-system-identifier",abruptDoctypePublicIdentifier:"abrupt-doctype-public-identifier",abruptDoctypeSystemIdentifier:"abrupt-doctype-system-identifier",cdataInHtmlContent:"cdata-in-html-content",incorrectlyOpenedComment:"incorrectly-opened-comment",eofInScriptHtmlCommentLikeText:"eof-in-script-html-comment-like-text",eofInDoctype:"eof-in-doctype",nestedComment:"nested-comment",abruptClosingOfEmptyComment:"abrupt-closing-of-empty-comment",eofInComment:"eof-in-comment",incorrectlyClosedComment:"incorrectly-closed-comment",eofInCdata:"eof-in-cdata",absenceOfDigitsInNumericCharacterReference:"absence-of-digits-in-numeric-character-reference",nullCharacterReference:"null-character-reference",surrogateCharacterReference:"surrogate-character-reference",characterReferenceOutsideUnicodeRange:"character-reference-outside-unicode-range",controlCharacterReference:"control-character-reference",noncharacterCharacterReference:"noncharacter-character-reference",missingWhitespaceBeforeDoctypeName:"missing-whitespace-before-doctype-name",missingDoctypeName:"missing-doctype-name",invalidCharacterSequenceAfterDoctypeName:"invalid-character-sequence-after-doctype-name",duplicateAttribute:"duplicate-attribute",nonConformingDoctype:"non-conforming-doctype",missingDoctype:"missing-doctype",misplacedDoctype:"misplaced-doctype",endTagWithoutMatchingOpenElement:"end-tag-without-matching-open-element",closingOfElementWithOpenChildElements:"closing-of-element-with-open-child-elements",disallowedContentInNoscriptInHead:"disallowed-content-in-noscript-in-head",openElementsLeftAfterEof:"open-elements-left-after-eof",abandonedHeadElementChild:"abandoned-head-element-child",misplacedStartTagForHeadElement:"misplaced-start-tag-for-head-element",nestedNoscriptInHead:"nested-noscript-in-head",eofInElementThatCanContainOnlyText:"eof-in-element-that-can-contain-only-text"};const Vf=Na,G9=ck,ac=Vf.CODE_POINTS,n_e=1<<16;let r_e=class{constructor(){this.html=null,this.pos=-1,this.lastGapPos=-1,this.lastCharPos=-1,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=n_e}_err(){}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.lastCharPos){const n=this.html.charCodeAt(this.pos+1);if(Vf.isSurrogatePair(n))return this.pos++,this._addGap(),Vf.getSurrogatePairCodePoint(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,ac.EOF;return this._err(G9.surrogateInInputStream),t}dropParsedChunk(){this.pos>this.bufferWaterline&&(this.lastCharPos-=this.pos,this.html=this.html.substring(this.pos),this.pos=0,this.lastGapPos=-1,this.gapStack=[])}write(t,n){this.html?this.html+=t:this.html=t,this.lastCharPos=this.html.length-1,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1,this.html.length),this.lastCharPos=this.html.length-1,this.endOfChunkHit=!1}advance(){if(this.pos++,this.pos>this.lastCharPos)return this.endOfChunkHit=!this.lastChunkWritten,ac.EOF;let t=this.html.charCodeAt(this.pos);return this.skipNextNewLine&&t===ac.LINE_FEED?(this.skipNextNewLine=!1,this._addGap(),this.advance()):t===ac.CARRIAGE_RETURN?(this.skipNextNewLine=!0,ac.LINE_FEED):(this.skipNextNewLine=!1,Vf.isSurrogate(t)&&(t=this._processSurrogate(t)),t>31&&t<127||t===ac.LINE_FEED||t===ac.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){Vf.isControlCodePoint(t)?this._err(G9.controlCharacterInInputStream):Vf.isUndefinedCodePoint(t)&&this._err(G9.noncharacterInInputStream)}retreat(){this.pos===this.lastGapPos&&(this.lastGapPos=this.gapStack.pop(),this.pos--),this.pos--}};var o_e=r_e,i_e=new Uint16Array([4,52,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,106,303,412,810,1432,1701,1796,1987,2114,2360,2420,2484,3170,3251,4140,4393,4575,4610,5106,5512,5728,6117,6274,6315,6345,6427,6516,7002,7910,8733,9323,9870,10170,10631,10893,11318,11386,11467,12773,13092,14474,14922,15448,15542,16419,17666,18166,18611,19004,19095,19298,19397,4,16,69,77,97,98,99,102,103,108,109,110,111,112,114,115,116,117,140,150,158,169,176,194,199,210,216,222,226,242,256,266,283,294,108,105,103,5,198,1,59,148,1,198,80,5,38,1,59,156,1,38,99,117,116,101,5,193,1,59,167,1,193,114,101,118,101,59,1,258,4,2,105,121,182,191,114,99,5,194,1,59,189,1,194,59,1,1040,114,59,3,55349,56580,114,97,118,101,5,192,1,59,208,1,192,112,104,97,59,1,913,97,99,114,59,1,256,100,59,1,10835,4,2,103,112,232,237,111,110,59,1,260,102,59,3,55349,56632,112,108,121,70,117,110,99,116,105,111,110,59,1,8289,105,110,103,5,197,1,59,264,1,197,4,2,99,115,272,277,114,59,3,55349,56476,105,103,110,59,1,8788,105,108,100,101,5,195,1,59,292,1,195,109,108,5,196,1,59,301,1,196,4,8,97,99,101,102,111,114,115,117,321,350,354,383,388,394,400,405,4,2,99,114,327,336,107,115,108,97,115,104,59,1,8726,4,2,118,119,342,345,59,1,10983,101,100,59,1,8966,121,59,1,1041,4,3,99,114,116,362,369,379,97,117,115,101,59,1,8757,110,111,117,108,108,105,115,59,1,8492,97,59,1,914,114,59,3,55349,56581,112,102,59,3,55349,56633,101,118,101,59,1,728,99,114,59,1,8492,109,112,101,113,59,1,8782,4,14,72,79,97,99,100,101,102,104,105,108,111,114,115,117,442,447,456,504,542,547,569,573,577,616,678,784,790,796,99,121,59,1,1063,80,89,5,169,1,59,454,1,169,4,3,99,112,121,464,470,497,117,116,101,59,1,262,4,2,59,105,476,478,1,8914,116,97,108,68,105,102,102,101,114,101,110,116,105,97,108,68,59,1,8517,108,101,121,115,59,1,8493,4,4,97,101,105,111,514,520,530,535,114,111,110,59,1,268,100,105,108,5,199,1,59,528,1,199,114,99,59,1,264,110,105,110,116,59,1,8752,111,116,59,1,266,4,2,100,110,553,560,105,108,108,97,59,1,184,116,101,114,68,111,116,59,1,183,114,59,1,8493,105,59,1,935,114,99,108,101,4,4,68,77,80,84,591,596,603,609,111,116,59,1,8857,105,110,117,115,59,1,8854,108,117,115,59,1,8853,105,109,101,115,59,1,8855,111,4,2,99,115,623,646,107,119,105,115,101,67,111,110,116,111,117,114,73,110,116,101,103,114,97,108,59,1,8754,101,67,117,114,108,121,4,2,68,81,658,671,111,117,98,108,101,81,117,111,116,101,59,1,8221,117,111,116,101,59,1,8217,4,4,108,110,112,117,688,701,736,753,111,110,4,2,59,101,696,698,1,8759,59,1,10868,4,3,103,105,116,709,717,722,114,117,101,110,116,59,1,8801,110,116,59,1,8751,111,117,114,73,110,116,101,103,114,97,108,59,1,8750,4,2,102,114,742,745,59,1,8450,111,100,117,99,116,59,1,8720,110,116,101,114,67,108,111,99,107,119,105,115,101,67,111,110,116,111,117,114,73,110,116,101,103,114,97,108,59,1,8755,111,115,115,59,1,10799,99,114,59,3,55349,56478,112,4,2,59,67,803,805,1,8915,97,112,59,1,8781,4,11,68,74,83,90,97,99,101,102,105,111,115,834,850,855,860,865,888,903,916,921,1011,1415,4,2,59,111,840,842,1,8517,116,114,97,104,100,59,1,10513,99,121,59,1,1026,99,121,59,1,1029,99,121,59,1,1039,4,3,103,114,115,873,879,883,103,101,114,59,1,8225,114,59,1,8609,104,118,59,1,10980,4,2,97,121,894,900,114,111,110,59,1,270,59,1,1044,108,4,2,59,116,910,912,1,8711,97,59,1,916,114,59,3,55349,56583,4,2,97,102,927,998,4,2,99,109,933,992,114,105,116,105,99,97,108,4,4,65,68,71,84,950,957,978,985,99,117,116,101,59,1,180,111,4,2,116,117,964,967,59,1,729,98,108,101,65,99,117,116,101,59,1,733,114,97,118,101,59,1,96,105,108,100,101,59,1,732,111,110,100,59,1,8900,102,101,114,101,110,116,105,97,108,68,59,1,8518,4,4,112,116,117,119,1021,1026,1048,1249,102,59,3,55349,56635,4,3,59,68,69,1034,1036,1041,1,168,111,116,59,1,8412,113,117,97,108,59,1,8784,98,108,101,4,6,67,68,76,82,85,86,1065,1082,1101,1189,1211,1236,111,110,116,111,117,114,73,110,116,101,103,114,97,108,59,1,8751,111,4,2,116,119,1089,1092,59,1,168,110,65,114,114,111,119,59,1,8659,4,2,101,111,1107,1141,102,116,4,3,65,82,84,1117,1124,1136,114,114,111,119,59,1,8656,105,103,104,116,65,114,114,111,119,59,1,8660,101,101,59,1,10980,110,103,4,2,76,82,1149,1177,101,102,116,4,2,65,82,1158,1165,114,114,111,119,59,1,10232,105,103,104,116,65,114,114,111,119,59,1,10234,105,103,104,116,65,114,114,111,119,59,1,10233,105,103,104,116,4,2,65,84,1199,1206,114,114,111,119,59,1,8658,101,101,59,1,8872,112,4,2,65,68,1218,1225,114,114,111,119,59,1,8657,111,119,110,65,114,114,111,119,59,1,8661,101,114,116,105,99,97,108,66,97,114,59,1,8741,110,4,6,65,66,76,82,84,97,1264,1292,1299,1352,1391,1408,114,114,111,119,4,3,59,66,85,1276,1278,1283,1,8595,97,114,59,1,10515,112,65,114,114,111,119,59,1,8693,114,101,118,101,59,1,785,101,102,116,4,3,82,84,86,1310,1323,1334,105,103,104,116,86,101,99,116,111,114,59,1,10576,101,101,86,101,99,116,111,114,59,1,10590,101,99,116,111,114,4,2,59,66,1345,1347,1,8637,97,114,59,1,10582,105,103,104,116,4,2,84,86,1362,1373,101,101,86,101,99,116,111,114,59,1,10591,101,99,116,111,114,4,2,59,66,1384,1386,1,8641,97,114,59,1,10583,101,101,4,2,59,65,1399,1401,1,8868,114,114,111,119,59,1,8615,114,114,111,119,59,1,8659,4,2,99,116,1421,1426,114,59,3,55349,56479,114,111,107,59,1,272,4,16,78,84,97,99,100,102,103,108,109,111,112,113,115,116,117,120,1466,1470,1478,1489,1515,1520,1525,1536,1544,1593,1609,1617,1650,1664,1668,1677,71,59,1,330,72,5,208,1,59,1476,1,208,99,117,116,101,5,201,1,59,1487,1,201,4,3,97,105,121,1497,1503,1512,114,111,110,59,1,282,114,99,5,202,1,59,1510,1,202,59,1,1069,111,116,59,1,278,114,59,3,55349,56584,114,97,118,101,5,200,1,59,1534,1,200,101,109,101,110,116,59,1,8712,4,2,97,112,1550,1555,99,114,59,1,274,116,121,4,2,83,86,1563,1576,109,97,108,108,83,113,117,97,114,101,59,1,9723,101,114,121,83,109,97,108,108,83,113,117,97,114,101,59,1,9643,4,2,103,112,1599,1604,111,110,59,1,280,102,59,3,55349,56636,115,105,108,111,110,59,1,917,117,4,2,97,105,1624,1640,108,4,2,59,84,1631,1633,1,10869,105,108,100,101,59,1,8770,108,105,98,114,105,117,109,59,1,8652,4,2,99,105,1656,1660,114,59,1,8496,109,59,1,10867,97,59,1,919,109,108,5,203,1,59,1675,1,203,4,2,105,112,1683,1689,115,116,115,59,1,8707,111,110,101,110,116,105,97,108,69,59,1,8519,4,5,99,102,105,111,115,1713,1717,1722,1762,1791,121,59,1,1060,114,59,3,55349,56585,108,108,101,100,4,2,83,86,1732,1745,109,97,108,108,83,113,117,97,114,101,59,1,9724,101,114,121,83,109,97,108,108,83,113,117,97,114,101,59,1,9642,4,3,112,114,117,1770,1775,1781,102,59,3,55349,56637,65,108,108,59,1,8704,114,105,101,114,116,114,102,59,1,8497,99,114,59,1,8497,4,12,74,84,97,98,99,100,102,103,111,114,115,116,1822,1827,1834,1848,1855,1877,1882,1887,1890,1896,1978,1984,99,121,59,1,1027,5,62,1,59,1832,1,62,109,109,97,4,2,59,100,1843,1845,1,915,59,1,988,114,101,118,101,59,1,286,4,3,101,105,121,1863,1869,1874,100,105,108,59,1,290,114,99,59,1,284,59,1,1043,111,116,59,1,288,114,59,3,55349,56586,59,1,8921,112,102,59,3,55349,56638,101,97,116,101,114,4,6,69,70,71,76,83,84,1915,1933,1944,1953,1959,1971,113,117,97,108,4,2,59,76,1925,1927,1,8805,101,115,115,59,1,8923,117,108,108,69,113,117,97,108,59,1,8807,114,101,97,116,101,114,59,1,10914,101,115,115,59,1,8823,108,97,110,116,69,113,117,97,108,59,1,10878,105,108,100,101,59,1,8819,99,114,59,3,55349,56482,59,1,8811,4,8,65,97,99,102,105,111,115,117,2005,2012,2026,2032,2036,2049,2073,2089,82,68,99,121,59,1,1066,4,2,99,116,2018,2023,101,107,59,1,711,59,1,94,105,114,99,59,1,292,114,59,1,8460,108,98,101,114,116,83,112,97,99,101,59,1,8459,4,2,112,114,2055,2059,102,59,1,8461,105,122,111,110,116,97,108,76,105,110,101,59,1,9472,4,2,99,116,2079,2083,114,59,1,8459,114,111,107,59,1,294,109,112,4,2,68,69,2097,2107,111,119,110,72,117,109,112,59,1,8782,113,117,97,108,59,1,8783,4,14,69,74,79,97,99,100,102,103,109,110,111,115,116,117,2144,2149,2155,2160,2171,2189,2194,2198,2209,2245,2307,2329,2334,2341,99,121,59,1,1045,108,105,103,59,1,306,99,121,59,1,1025,99,117,116,101,5,205,1,59,2169,1,205,4,2,105,121,2177,2186,114,99,5,206,1,59,2184,1,206,59,1,1048,111,116,59,1,304,114,59,1,8465,114,97,118,101,5,204,1,59,2207,1,204,4,3,59,97,112,2217,2219,2238,1,8465,4,2,99,103,2225,2229,114,59,1,298,105,110,97,114,121,73,59,1,8520,108,105,101,115,59,1,8658,4,2,116,118,2251,2281,4,2,59,101,2257,2259,1,8748,4,2,103,114,2265,2271,114,97,108,59,1,8747,115,101,99,116,105,111,110,59,1,8898,105,115,105,98,108,101,4,2,67,84,2293,2300,111,109,109,97,59,1,8291,105,109,101,115,59,1,8290,4,3,103,112,116,2315,2320,2325,111,110,59,1,302,102,59,3,55349,56640,97,59,1,921,99,114,59,1,8464,105,108,100,101,59,1,296,4,2,107,109,2347,2352,99,121,59,1,1030,108,5,207,1,59,2358,1,207,4,5,99,102,111,115,117,2372,2386,2391,2397,2414,4,2,105,121,2378,2383,114,99,59,1,308,59,1,1049,114,59,3,55349,56589,112,102,59,3,55349,56641,4,2,99,101,2403,2408,114,59,3,55349,56485,114,99,121,59,1,1032,107,99,121,59,1,1028,4,7,72,74,97,99,102,111,115,2436,2441,2446,2452,2467,2472,2478,99,121,59,1,1061,99,121,59,1,1036,112,112,97,59,1,922,4,2,101,121,2458,2464,100,105,108,59,1,310,59,1,1050,114,59,3,55349,56590,112,102,59,3,55349,56642,99,114,59,3,55349,56486,4,11,74,84,97,99,101,102,108,109,111,115,116,2508,2513,2520,2562,2585,2981,2986,3004,3011,3146,3167,99,121,59,1,1033,5,60,1,59,2518,1,60,4,5,99,109,110,112,114,2532,2538,2544,2548,2558,117,116,101,59,1,313,98,100,97,59,1,923,103,59,1,10218,108,97,99,101,116,114,102,59,1,8466,114,59,1,8606,4,3,97,101,121,2570,2576,2582,114,111,110,59,1,317,100,105,108,59,1,315,59,1,1051,4,2,102,115,2591,2907,116,4,10,65,67,68,70,82,84,85,86,97,114,2614,2663,2672,2728,2735,2760,2820,2870,2888,2895,4,2,110,114,2620,2633,103,108,101,66,114,97,99,107,101,116,59,1,10216,114,111,119,4,3,59,66,82,2644,2646,2651,1,8592,97,114,59,1,8676,105,103,104,116,65,114,114,111,119,59,1,8646,101,105,108,105,110,103,59,1,8968,111,4,2,117,119,2679,2692,98,108,101,66,114,97,99,107,101,116,59,1,10214,110,4,2,84,86,2699,2710,101,101,86,101,99,116,111,114,59,1,10593,101,99,116,111,114,4,2,59,66,2721,2723,1,8643,97,114,59,1,10585,108,111,111,114,59,1,8970,105,103,104,116,4,2,65,86,2745,2752,114,114,111,119,59,1,8596,101,99,116,111,114,59,1,10574,4,2,101,114,2766,2792,101,4,3,59,65,86,2775,2777,2784,1,8867,114,114,111,119,59,1,8612,101,99,116,111,114,59,1,10586,105,97,110,103,108,101,4,3,59,66,69,2806,2808,2813,1,8882,97,114,59,1,10703,113,117,97,108,59,1,8884,112,4,3,68,84,86,2829,2841,2852,111,119,110,86,101,99,116,111,114,59,1,10577,101,101,86,101,99,116,111,114,59,1,10592,101,99,116,111,114,4,2,59,66,2863,2865,1,8639,97,114,59,1,10584,101,99,116,111,114,4,2,59,66,2881,2883,1,8636,97,114,59,1,10578,114,114,111,119,59,1,8656,105,103,104,116,97,114,114,111,119,59,1,8660,115,4,6,69,70,71,76,83,84,2922,2936,2947,2956,2962,2974,113,117,97,108,71,114,101,97,116,101,114,59,1,8922,117,108,108,69,113,117,97,108,59,1,8806,114,101,97,116,101,114,59,1,8822,101,115,115,59,1,10913,108,97,110,116,69,113,117,97,108,59,1,10877,105,108,100,101,59,1,8818,114,59,3,55349,56591,4,2,59,101,2992,2994,1,8920,102,116,97,114,114,111,119,59,1,8666,105,100,111,116,59,1,319,4,3,110,112,119,3019,3110,3115,103,4,4,76,82,108,114,3030,3058,3070,3098,101,102,116,4,2,65,82,3039,3046,114,114,111,119,59,1,10229,105,103,104,116,65,114,114,111,119,59,1,10231,105,103,104,116,65,114,114,111,119,59,1,10230,101,102,116,4,2,97,114,3079,3086,114,114,111,119,59,1,10232,105,103,104,116,97,114,114,111,119,59,1,10234,105,103,104,116,97,114,114,111,119,59,1,10233,102,59,3,55349,56643,101,114,4,2,76,82,3123,3134,101,102,116,65,114,114,111,119,59,1,8601,105,103,104,116,65,114,114,111,119,59,1,8600,4,3,99,104,116,3154,3158,3161,114,59,1,8466,59,1,8624,114,111,107,59,1,321,59,1,8810,4,8,97,99,101,102,105,111,115,117,3188,3192,3196,3222,3227,3237,3243,3248,112,59,1,10501,121,59,1,1052,4,2,100,108,3202,3213,105,117,109,83,112,97,99,101,59,1,8287,108,105,110,116,114,102,59,1,8499,114,59,3,55349,56592,110,117,115,80,108,117,115,59,1,8723,112,102,59,3,55349,56644,99,114,59,1,8499,59,1,924,4,9,74,97,99,101,102,111,115,116,117,3271,3276,3283,3306,3422,3427,4120,4126,4137,99,121,59,1,1034,99,117,116,101,59,1,323,4,3,97,101,121,3291,3297,3303,114,111,110,59,1,327,100,105,108,59,1,325,59,1,1053,4,3,103,115,119,3314,3380,3415,97,116,105,118,101,4,3,77,84,86,3327,3340,3365,101,100,105,117,109,83,112,97,99,101,59,1,8203,104,105,4,2,99,110,3348,3357,107,83,112,97,99,101,59,1,8203,83,112,97,99,101,59,1,8203,101,114,121,84,104,105,110,83,112,97,99,101,59,1,8203,116,101,100,4,2,71,76,3389,3405,114,101,97,116,101,114,71,114,101,97,116,101,114,59,1,8811,101,115,115,76,101,115,115,59,1,8810,76,105,110,101,59,1,10,114,59,3,55349,56593,4,4,66,110,112,116,3437,3444,3460,3464,114,101,97,107,59,1,8288,66,114,101,97,107,105,110,103,83,112,97,99,101,59,1,160,102,59,1,8469,4,13,59,67,68,69,71,72,76,78,80,82,83,84,86,3492,3494,3517,3536,3578,3657,3685,3784,3823,3860,3915,4066,4107,1,10988,4,2,111,117,3500,3510,110,103,114,117,101,110,116,59,1,8802,112,67,97,112,59,1,8813,111,117,98,108,101,86,101,114,116,105,99,97,108,66,97,114,59,1,8742,4,3,108,113,120,3544,3552,3571,101,109,101,110,116,59,1,8713,117,97,108,4,2,59,84,3561,3563,1,8800,105,108,100,101,59,3,8770,824,105,115,116,115,59,1,8708,114,101,97,116,101,114,4,7,59,69,70,71,76,83,84,3600,3602,3609,3621,3631,3637,3650,1,8815,113,117,97,108,59,1,8817,117,108,108,69,113,117,97,108,59,3,8807,824,114,101,97,116,101,114,59,3,8811,824,101,115,115,59,1,8825,108,97,110,116,69,113,117,97,108,59,3,10878,824,105,108,100,101,59,1,8821,117,109,112,4,2,68,69,3666,3677,111,119,110,72,117,109,112,59,3,8782,824,113,117,97,108,59,3,8783,824,101,4,2,102,115,3692,3724,116,84,114,105,97,110,103,108,101,4,3,59,66,69,3709,3711,3717,1,8938,97,114,59,3,10703,824,113,117,97,108,59,1,8940,115,4,6,59,69,71,76,83,84,3739,3741,3748,3757,3764,3777,1,8814,113,117,97,108,59,1,8816,114,101,97,116,101,114,59,1,8824,101,115,115,59,3,8810,824,108,97,110,116,69,113,117,97,108,59,3,10877,824,105,108,100,101,59,1,8820,101,115,116,101,100,4,2,71,76,3795,3812,114,101,97,116,101,114,71,114,101,97,116,101,114,59,3,10914,824,101,115,115,76,101,115,115,59,3,10913,824,114,101,99,101,100,101,115,4,3,59,69,83,3838,3840,3848,1,8832,113,117,97,108,59,3,10927,824,108,97,110,116,69,113,117,97,108,59,1,8928,4,2,101,105,3866,3881,118,101,114,115,101,69,108,101,109,101,110,116,59,1,8716,103,104,116,84,114,105,97,110,103,108,101,4,3,59,66,69,3900,3902,3908,1,8939,97,114,59,3,10704,824,113,117,97,108,59,1,8941,4,2,113,117,3921,3973,117,97,114,101,83,117,4,2,98,112,3933,3952,115,101,116,4,2,59,69,3942,3945,3,8847,824,113,117,97,108,59,1,8930,101,114,115,101,116,4,2,59,69,3963,3966,3,8848,824,113,117,97,108,59,1,8931,4,3,98,99,112,3981,4e3,4045,115,101,116,4,2,59,69,3990,3993,3,8834,8402,113,117,97,108,59,1,8840,99,101,101,100,115,4,4,59,69,83,84,4015,4017,4025,4037,1,8833,113,117,97,108,59,3,10928,824,108,97,110,116,69,113,117,97,108,59,1,8929,105,108,100,101,59,3,8831,824,101,114,115,101,116,4,2,59,69,4056,4059,3,8835,8402,113,117,97,108,59,1,8841,105,108,100,101,4,4,59,69,70,84,4080,4082,4089,4100,1,8769,113,117,97,108,59,1,8772,117,108,108,69,113,117,97,108,59,1,8775,105,108,100,101,59,1,8777,101,114,116,105,99,97,108,66,97,114,59,1,8740,99,114,59,3,55349,56489,105,108,100,101,5,209,1,59,4135,1,209,59,1,925,4,14,69,97,99,100,102,103,109,111,112,114,115,116,117,118,4170,4176,4187,4205,4212,4217,4228,4253,4259,4292,4295,4316,4337,4346,108,105,103,59,1,338,99,117,116,101,5,211,1,59,4185,1,211,4,2,105,121,4193,4202,114,99,5,212,1,59,4200,1,212,59,1,1054,98,108,97,99,59,1,336,114,59,3,55349,56594,114,97,118,101,5,210,1,59,4226,1,210,4,3,97,101,105,4236,4241,4246,99,114,59,1,332,103,97,59,1,937,99,114,111,110,59,1,927,112,102,59,3,55349,56646,101,110,67,117,114,108,121,4,2,68,81,4272,4285,111,117,98,108,101,81,117,111,116,101,59,1,8220,117,111,116,101,59,1,8216,59,1,10836,4,2,99,108,4301,4306,114,59,3,55349,56490,97,115,104,5,216,1,59,4314,1,216,105,4,2,108,109,4323,4332,100,101,5,213,1,59,4330,1,213,101,115,59,1,10807,109,108,5,214,1,59,4344,1,214,101,114,4,2,66,80,4354,4380,4,2,97,114,4360,4364,114,59,1,8254,97,99,4,2,101,107,4372,4375,59,1,9182,101,116,59,1,9140,97,114,101,110,116,104,101,115,105,115,59,1,9180,4,9,97,99,102,104,105,108,111,114,115,4413,4422,4426,4431,4435,4438,4448,4471,4561,114,116,105,97,108,68,59,1,8706,121,59,1,1055,114,59,3,55349,56595,105,59,1,934,59,1,928,117,115,77,105,110,117,115,59,1,177,4,2,105,112,4454,4467,110,99,97,114,101,112,108,97,110,101,59,1,8460,102,59,1,8473,4,4,59,101,105,111,4481,4483,4526,4531,1,10939,99,101,100,101,115,4,4,59,69,83,84,4498,4500,4507,4519,1,8826,113,117,97,108,59,1,10927,108,97,110,116,69,113,117,97,108,59,1,8828,105,108,100,101,59,1,8830,109,101,59,1,8243,4,2,100,112,4537,4543,117,99,116,59,1,8719,111,114,116,105,111,110,4,2,59,97,4555,4557,1,8759,108,59,1,8733,4,2,99,105,4567,4572,114,59,3,55349,56491,59,1,936,4,4,85,102,111,115,4585,4594,4599,4604,79,84,5,34,1,59,4592,1,34,114,59,3,55349,56596,112,102,59,1,8474,99,114,59,3,55349,56492,4,12,66,69,97,99,101,102,104,105,111,114,115,117,4636,4642,4650,4681,4704,4763,4767,4771,5047,5069,5081,5094,97,114,114,59,1,10512,71,5,174,1,59,4648,1,174,4,3,99,110,114,4658,4664,4668,117,116,101,59,1,340,103,59,1,10219,114,4,2,59,116,4675,4677,1,8608,108,59,1,10518,4,3,97,101,121,4689,4695,4701,114,111,110,59,1,344,100,105,108,59,1,342,59,1,1056,4,2,59,118,4710,4712,1,8476,101,114,115,101,4,2,69,85,4722,4748,4,2,108,113,4728,4736,101,109,101,110,116,59,1,8715,117,105,108,105,98,114,105,117,109,59,1,8651,112,69,113,117,105,108,105,98,114,105,117,109,59,1,10607,114,59,1,8476,111,59,1,929,103,104,116,4,8,65,67,68,70,84,85,86,97,4792,4840,4849,4905,4912,4972,5022,5040,4,2,110,114,4798,4811,103,108,101,66,114,97,99,107,101,116,59,1,10217,114,111,119,4,3,59,66,76,4822,4824,4829,1,8594,97,114,59,1,8677,101,102,116,65,114,114,111,119,59,1,8644,101,105,108,105,110,103,59,1,8969,111,4,2,117,119,4856,4869,98,108,101,66,114,97,99,107,101,116,59,1,10215,110,4,2,84,86,4876,4887,101,101,86,101,99,116,111,114,59,1,10589,101,99,116,111,114,4,2,59,66,4898,4900,1,8642,97,114,59,1,10581,108,111,111,114,59,1,8971,4,2,101,114,4918,4944,101,4,3,59,65,86,4927,4929,4936,1,8866,114,114,111,119,59,1,8614,101,99,116,111,114,59,1,10587,105,97,110,103,108,101,4,3,59,66,69,4958,4960,4965,1,8883,97,114,59,1,10704,113,117,97,108,59,1,8885,112,4,3,68,84,86,4981,4993,5004,111,119,110,86,101,99,116,111,114,59,1,10575,101,101,86,101,99,116,111,114,59,1,10588,101,99,116,111,114,4,2,59,66,5015,5017,1,8638,97,114,59,1,10580,101,99,116,111,114,4,2,59,66,5033,5035,1,8640,97,114,59,1,10579,114,114,111,119,59,1,8658,4,2,112,117,5053,5057,102,59,1,8477,110,100,73,109,112,108,105,101,115,59,1,10608,105,103,104,116,97,114,114,111,119,59,1,8667,4,2,99,104,5087,5091,114,59,1,8475,59,1,8625,108,101,68,101,108,97,121,101,100,59,1,10740,4,13,72,79,97,99,102,104,105,109,111,113,115,116,117,5134,5150,5157,5164,5198,5203,5259,5265,5277,5283,5374,5380,5385,4,2,67,99,5140,5146,72,99,121,59,1,1065,121,59,1,1064,70,84,99,121,59,1,1068,99,117,116,101,59,1,346,4,5,59,97,101,105,121,5176,5178,5184,5190,5195,1,10940,114,111,110,59,1,352,100,105,108,59,1,350,114,99,59,1,348,59,1,1057,114,59,3,55349,56598,111,114,116,4,4,68,76,82,85,5216,5227,5238,5250,111,119,110,65,114,114,111,119,59,1,8595,101,102,116,65,114,114,111,119,59,1,8592,105,103,104,116,65,114,114,111,119,59,1,8594,112,65,114,114,111,119,59,1,8593,103,109,97,59,1,931,97,108,108,67,105,114,99,108,101,59,1,8728,112,102,59,3,55349,56650,4,2,114,117,5289,5293,116,59,1,8730,97,114,101,4,4,59,73,83,85,5306,5308,5322,5367,1,9633,110,116,101,114,115,101,99,116,105,111,110,59,1,8851,117,4,2,98,112,5329,5347,115,101,116,4,2,59,69,5338,5340,1,8847,113,117,97,108,59,1,8849,101,114,115,101,116,4,2,59,69,5358,5360,1,8848,113,117,97,108,59,1,8850,110,105,111,110,59,1,8852,99,114,59,3,55349,56494,97,114,59,1,8902,4,4,98,99,109,112,5395,5420,5475,5478,4,2,59,115,5401,5403,1,8912,101,116,4,2,59,69,5411,5413,1,8912,113,117,97,108,59,1,8838,4,2,99,104,5426,5468,101,101,100,115,4,4,59,69,83,84,5440,5442,5449,5461,1,8827,113,117,97,108,59,1,10928,108,97,110,116,69,113,117,97,108,59,1,8829,105,108,100,101,59,1,8831,84,104,97,116,59,1,8715,59,1,8721,4,3,59,101,115,5486,5488,5507,1,8913,114,115,101,116,4,2,59,69,5498,5500,1,8835,113,117,97,108,59,1,8839,101,116,59,1,8913,4,11,72,82,83,97,99,102,104,105,111,114,115,5536,5546,5552,5567,5579,5602,5607,5655,5695,5701,5711,79,82,78,5,222,1,59,5544,1,222,65,68,69,59,1,8482,4,2,72,99,5558,5563,99,121,59,1,1035,121,59,1,1062,4,2,98,117,5573,5576,59,1,9,59,1,932,4,3,97,101,121,5587,5593,5599,114,111,110,59,1,356,100,105,108,59,1,354,59,1,1058,114,59,3,55349,56599,4,2,101,105,5613,5631,4,2,114,116,5619,5627,101,102,111,114,101,59,1,8756,97,59,1,920,4,2,99,110,5637,5647,107,83,112,97,99,101,59,3,8287,8202,83,112,97,99,101,59,1,8201,108,100,101,4,4,59,69,70,84,5668,5670,5677,5688,1,8764,113,117,97,108,59,1,8771,117,108,108,69,113,117,97,108,59,1,8773,105,108,100,101,59,1,8776,112,102,59,3,55349,56651,105,112,108,101,68,111,116,59,1,8411,4,2,99,116,5717,5722,114,59,3,55349,56495,114,111,107,59,1,358,4,14,97,98,99,100,102,103,109,110,111,112,114,115,116,117,5758,5789,5805,5823,5830,5835,5846,5852,5921,5937,6089,6095,6101,6108,4,2,99,114,5764,5774,117,116,101,5,218,1,59,5772,1,218,114,4,2,59,111,5781,5783,1,8607,99,105,114,59,1,10569,114,4,2,99,101,5796,5800,121,59,1,1038,118,101,59,1,364,4,2,105,121,5811,5820,114,99,5,219,1,59,5818,1,219,59,1,1059,98,108,97,99,59,1,368,114,59,3,55349,56600,114,97,118,101,5,217,1,59,5844,1,217,97,99,114,59,1,362,4,2,100,105,5858,5905,101,114,4,2,66,80,5866,5892,4,2,97,114,5872,5876,114,59,1,95,97,99,4,2,101,107,5884,5887,59,1,9183,101,116,59,1,9141,97,114,101,110,116,104,101,115,105,115,59,1,9181,111,110,4,2,59,80,5913,5915,1,8899,108,117,115,59,1,8846,4,2,103,112,5927,5932,111,110,59,1,370,102,59,3,55349,56652,4,8,65,68,69,84,97,100,112,115,5955,5985,5996,6009,6026,6033,6044,6075,114,114,111,119,4,3,59,66,68,5967,5969,5974,1,8593,97,114,59,1,10514,111,119,110,65,114,114,111,119,59,1,8645,111,119,110,65,114,114,111,119,59,1,8597,113,117,105,108,105,98,114,105,117,109,59,1,10606,101,101,4,2,59,65,6017,6019,1,8869,114,114,111,119,59,1,8613,114,114,111,119,59,1,8657,111,119,110,97,114,114,111,119,59,1,8661,101,114,4,2,76,82,6052,6063,101,102,116,65,114,114,111,119,59,1,8598,105,103,104,116,65,114,114,111,119,59,1,8599,105,4,2,59,108,6082,6084,1,978,111,110,59,1,933,105,110,103,59,1,366,99,114,59,3,55349,56496,105,108,100,101,59,1,360,109,108,5,220,1,59,6115,1,220,4,9,68,98,99,100,101,102,111,115,118,6137,6143,6148,6152,6166,6250,6255,6261,6267,97,115,104,59,1,8875,97,114,59,1,10987,121,59,1,1042,97,115,104,4,2,59,108,6161,6163,1,8873,59,1,10982,4,2,101,114,6172,6175,59,1,8897,4,3,98,116,121,6183,6188,6238,97,114,59,1,8214,4,2,59,105,6194,6196,1,8214,99,97,108,4,4,66,76,83,84,6209,6214,6220,6231,97,114,59,1,8739,105,110,101,59,1,124,101,112,97,114,97,116,111,114,59,1,10072,105,108,100,101,59,1,8768,84,104,105,110,83,112,97,99,101,59,1,8202,114,59,3,55349,56601,112,102,59,3,55349,56653,99,114,59,3,55349,56497,100,97,115,104,59,1,8874,4,5,99,101,102,111,115,6286,6292,6298,6303,6309,105,114,99,59,1,372,100,103,101,59,1,8896,114,59,3,55349,56602,112,102,59,3,55349,56654,99,114,59,3,55349,56498,4,4,102,105,111,115,6325,6330,6333,6339,114,59,3,55349,56603,59,1,926,112,102,59,3,55349,56655,99,114,59,3,55349,56499,4,9,65,73,85,97,99,102,111,115,117,6365,6370,6375,6380,6391,6405,6410,6416,6422,99,121,59,1,1071,99,121,59,1,1031,99,121,59,1,1070,99,117,116,101,5,221,1,59,6389,1,221,4,2,105,121,6397,6402,114,99,59,1,374,59,1,1067,114,59,3,55349,56604,112,102,59,3,55349,56656,99,114,59,3,55349,56500,109,108,59,1,376,4,8,72,97,99,100,101,102,111,115,6445,6450,6457,6472,6477,6501,6505,6510,99,121,59,1,1046,99,117,116,101,59,1,377,4,2,97,121,6463,6469,114,111,110,59,1,381,59,1,1047,111,116,59,1,379,4,2,114,116,6483,6497,111,87,105,100,116,104,83,112,97,99,101,59,1,8203,97,59,1,918,114,59,1,8488,112,102,59,1,8484,99,114,59,3,55349,56501,4,16,97,98,99,101,102,103,108,109,110,111,112,114,115,116,117,119,6550,6561,6568,6612,6622,6634,6645,6672,6699,6854,6870,6923,6933,6963,6974,6983,99,117,116,101,5,225,1,59,6559,1,225,114,101,118,101,59,1,259,4,6,59,69,100,105,117,121,6582,6584,6588,6591,6600,6609,1,8766,59,3,8766,819,59,1,8767,114,99,5,226,1,59,6598,1,226,116,101,5,180,1,59,6607,1,180,59,1,1072,108,105,103,5,230,1,59,6620,1,230,4,2,59,114,6628,6630,1,8289,59,3,55349,56606,114,97,118,101,5,224,1,59,6643,1,224,4,2,101,112,6651,6667,4,2,102,112,6657,6663,115,121,109,59,1,8501,104,59,1,8501,104,97,59,1,945,4,2,97,112,6678,6692,4,2,99,108,6684,6688,114,59,1,257,103,59,1,10815,5,38,1,59,6697,1,38,4,2,100,103,6705,6737,4,5,59,97,100,115,118,6717,6719,6724,6727,6734,1,8743,110,100,59,1,10837,59,1,10844,108,111,112,101,59,1,10840,59,1,10842,4,7,59,101,108,109,114,115,122,6753,6755,6758,6762,6814,6835,6848,1,8736,59,1,10660,101,59,1,8736,115,100,4,2,59,97,6770,6772,1,8737,4,8,97,98,99,100,101,102,103,104,6790,6793,6796,6799,6802,6805,6808,6811,59,1,10664,59,1,10665,59,1,10666,59,1,10667,59,1,10668,59,1,10669,59,1,10670,59,1,10671,116,4,2,59,118,6821,6823,1,8735,98,4,2,59,100,6830,6832,1,8894,59,1,10653,4,2,112,116,6841,6845,104,59,1,8738,59,1,197,97,114,114,59,1,9084,4,2,103,112,6860,6865,111,110,59,1,261,102,59,3,55349,56658,4,7,59,69,97,101,105,111,112,6886,6888,6891,6897,6900,6904,6908,1,8776,59,1,10864,99,105,114,59,1,10863,59,1,8778,100,59,1,8779,115,59,1,39,114,111,120,4,2,59,101,6917,6919,1,8776,113,59,1,8778,105,110,103,5,229,1,59,6931,1,229,4,3,99,116,121,6941,6946,6949,114,59,3,55349,56502,59,1,42,109,112,4,2,59,101,6957,6959,1,8776,113,59,1,8781,105,108,100,101,5,227,1,59,6972,1,227,109,108,5,228,1,59,6981,1,228,4,2,99,105,6989,6997,111,110,105,110,116,59,1,8755,110,116,59,1,10769,4,16,78,97,98,99,100,101,102,105,107,108,110,111,112,114,115,117,7036,7041,7119,7135,7149,7155,7219,7224,7347,7354,7463,7489,7786,7793,7814,7866,111,116,59,1,10989,4,2,99,114,7047,7094,107,4,4,99,101,112,115,7058,7064,7073,7080,111,110,103,59,1,8780,112,115,105,108,111,110,59,1,1014,114,105,109,101,59,1,8245,105,109,4,2,59,101,7088,7090,1,8765,113,59,1,8909,4,2,118,119,7100,7105,101,101,59,1,8893,101,100,4,2,59,103,7113,7115,1,8965,101,59,1,8965,114,107,4,2,59,116,7127,7129,1,9141,98,114,107,59,1,9142,4,2,111,121,7141,7146,110,103,59,1,8780,59,1,1073,113,117,111,59,1,8222,4,5,99,109,112,114,116,7167,7181,7188,7193,7199,97,117,115,4,2,59,101,7176,7178,1,8757,59,1,8757,112,116,121,118,59,1,10672,115,105,59,1,1014,110,111,117,59,1,8492,4,3,97,104,119,7207,7210,7213,59,1,946,59,1,8502,101,101,110,59,1,8812,114,59,3,55349,56607,103,4,7,99,111,115,116,117,118,119,7241,7262,7288,7305,7328,7335,7340,4,3,97,105,117,7249,7253,7258,112,59,1,8898,114,99,59,1,9711,112,59,1,8899,4,3,100,112,116,7270,7275,7281,111,116,59,1,10752,108,117,115,59,1,10753,105,109,101,115,59,1,10754,4,2,113,116,7294,7300,99,117,112,59,1,10758,97,114,59,1,9733,114,105,97,110,103,108,101,4,2,100,117,7318,7324,111,119,110,59,1,9661,112,59,1,9651,112,108,117,115,59,1,10756,101,101,59,1,8897,101,100,103,101,59,1,8896,97,114,111,119,59,1,10509,4,3,97,107,111,7362,7436,7458,4,2,99,110,7368,7432,107,4,3,108,115,116,7377,7386,7394,111,122,101,110,103,101,59,1,10731,113,117,97,114,101,59,1,9642,114,105,97,110,103,108,101,4,4,59,100,108,114,7411,7413,7419,7425,1,9652,111,119,110,59,1,9662,101,102,116,59,1,9666,105,103,104,116,59,1,9656,107,59,1,9251,4,2,49,51,7442,7454,4,2,50,52,7448,7451,59,1,9618,59,1,9617,52,59,1,9619,99,107,59,1,9608,4,2,101,111,7469,7485,4,2,59,113,7475,7478,3,61,8421,117,105,118,59,3,8801,8421,116,59,1,8976,4,4,112,116,119,120,7499,7504,7517,7523,102,59,3,55349,56659,4,2,59,116,7510,7512,1,8869,111,109,59,1,8869,116,105,101,59,1,8904,4,12,68,72,85,86,98,100,104,109,112,116,117,118,7549,7571,7597,7619,7655,7660,7682,7708,7715,7721,7728,7750,4,4,76,82,108,114,7559,7562,7565,7568,59,1,9559,59,1,9556,59,1,9558,59,1,9555,4,5,59,68,85,100,117,7583,7585,7588,7591,7594,1,9552,59,1,9574,59,1,9577,59,1,9572,59,1,9575,4,4,76,82,108,114,7607,7610,7613,7616,59,1,9565,59,1,9562,59,1,9564,59,1,9561,4,7,59,72,76,82,104,108,114,7635,7637,7640,7643,7646,7649,7652,1,9553,59,1,9580,59,1,9571,59,1,9568,59,1,9579,59,1,9570,59,1,9567,111,120,59,1,10697,4,4,76,82,108,114,7670,7673,7676,7679,59,1,9557,59,1,9554,59,1,9488,59,1,9484,4,5,59,68,85,100,117,7694,7696,7699,7702,7705,1,9472,59,1,9573,59,1,9576,59,1,9516,59,1,9524,105,110,117,115,59,1,8863,108,117,115,59,1,8862,105,109,101,115,59,1,8864,4,4,76,82,108,114,7738,7741,7744,7747,59,1,9563,59,1,9560,59,1,9496,59,1,9492,4,7,59,72,76,82,104,108,114,7766,7768,7771,7774,7777,7780,7783,1,9474,59,1,9578,59,1,9569,59,1,9566,59,1,9532,59,1,9508,59,1,9500,114,105,109,101,59,1,8245,4,2,101,118,7799,7804,118,101,59,1,728,98,97,114,5,166,1,59,7812,1,166,4,4,99,101,105,111,7824,7829,7834,7846,114,59,3,55349,56503,109,105,59,1,8271,109,4,2,59,101,7841,7843,1,8765,59,1,8909,108,4,3,59,98,104,7855,7857,7860,1,92,59,1,10693,115,117,98,59,1,10184,4,2,108,109,7872,7885,108,4,2,59,101,7879,7881,1,8226,116,59,1,8226,112,4,3,59,69,101,7894,7896,7899,1,8782,59,1,10926,4,2,59,113,7905,7907,1,8783,59,1,8783,4,15,97,99,100,101,102,104,105,108,111,114,115,116,117,119,121,7942,8021,8075,8080,8121,8126,8157,8279,8295,8430,8446,8485,8491,8707,8726,4,3,99,112,114,7950,7956,8007,117,116,101,59,1,263,4,6,59,97,98,99,100,115,7970,7972,7977,7984,7998,8003,1,8745,110,100,59,1,10820,114,99,117,112,59,1,10825,4,2,97,117,7990,7994,112,59,1,10827,112,59,1,10823,111,116,59,1,10816,59,3,8745,65024,4,2,101,111,8013,8017,116,59,1,8257,110,59,1,711,4,4,97,101,105,117,8031,8046,8056,8061,4,2,112,114,8037,8041,115,59,1,10829,111,110,59,1,269,100,105,108,5,231,1,59,8054,1,231,114,99,59,1,265,112,115,4,2,59,115,8069,8071,1,10828,109,59,1,10832,111,116,59,1,267,4,3,100,109,110,8088,8097,8104,105,108,5,184,1,59,8095,1,184,112,116,121,118,59,1,10674,116,5,162,2,59,101,8112,8114,1,162,114,100,111,116,59,1,183,114,59,3,55349,56608,4,3,99,101,105,8134,8138,8154,121,59,1,1095,99,107,4,2,59,109,8146,8148,1,10003,97,114,107,59,1,10003,59,1,967,114,4,7,59,69,99,101,102,109,115,8174,8176,8179,8258,8261,8268,8273,1,9675,59,1,10691,4,3,59,101,108,8187,8189,8193,1,710,113,59,1,8791,101,4,2,97,100,8200,8223,114,114,111,119,4,2,108,114,8210,8216,101,102,116,59,1,8634,105,103,104,116,59,1,8635,4,5,82,83,97,99,100,8235,8238,8241,8246,8252,59,1,174,59,1,9416,115,116,59,1,8859,105,114,99,59,1,8858,97,115,104,59,1,8861,59,1,8791,110,105,110,116,59,1,10768,105,100,59,1,10991,99,105,114,59,1,10690,117,98,115,4,2,59,117,8288,8290,1,9827,105,116,59,1,9827,4,4,108,109,110,112,8305,8326,8376,8400,111,110,4,2,59,101,8313,8315,1,58,4,2,59,113,8321,8323,1,8788,59,1,8788,4,2,109,112,8332,8344,97,4,2,59,116,8339,8341,1,44,59,1,64,4,3,59,102,108,8352,8354,8358,1,8705,110,59,1,8728,101,4,2,109,120,8365,8371,101,110,116,59,1,8705,101,115,59,1,8450,4,2,103,105,8382,8395,4,2,59,100,8388,8390,1,8773,111,116,59,1,10861,110,116,59,1,8750,4,3,102,114,121,8408,8412,8417,59,3,55349,56660,111,100,59,1,8720,5,169,2,59,115,8424,8426,1,169,114,59,1,8471,4,2,97,111,8436,8441,114,114,59,1,8629,115,115,59,1,10007,4,2,99,117,8452,8457,114,59,3,55349,56504,4,2,98,112,8463,8474,4,2,59,101,8469,8471,1,10959,59,1,10961,4,2,59,101,8480,8482,1,10960,59,1,10962,100,111,116,59,1,8943,4,7,100,101,108,112,114,118,119,8507,8522,8536,8550,8600,8697,8702,97,114,114,4,2,108,114,8516,8519,59,1,10552,59,1,10549,4,2,112,115,8528,8532,114,59,1,8926,99,59,1,8927,97,114,114,4,2,59,112,8545,8547,1,8630,59,1,10557,4,6,59,98,99,100,111,115,8564,8566,8573,8587,8592,8596,1,8746,114,99,97,112,59,1,10824,4,2,97,117,8579,8583,112,59,1,10822,112,59,1,10826,111,116,59,1,8845,114,59,1,10821,59,3,8746,65024,4,4,97,108,114,118,8610,8623,8663,8672,114,114,4,2,59,109,8618,8620,1,8631,59,1,10556,121,4,3,101,118,119,8632,8651,8656,113,4,2,112,115,8639,8645,114,101,99,59,1,8926,117,99,99,59,1,8927,101,101,59,1,8910,101,100,103,101,59,1,8911,101,110,5,164,1,59,8670,1,164,101,97,114,114,111,119,4,2,108,114,8684,8690,101,102,116,59,1,8630,105,103,104,116,59,1,8631,101,101,59,1,8910,101,100,59,1,8911,4,2,99,105,8713,8721,111,110,105,110,116,59,1,8754,110,116,59,1,8753,108,99,116,121,59,1,9005,4,19,65,72,97,98,99,100,101,102,104,105,106,108,111,114,115,116,117,119,122,8773,8778,8783,8821,8839,8854,8887,8914,8930,8944,9036,9041,9058,9197,9227,9258,9281,9297,9305,114,114,59,1,8659,97,114,59,1,10597,4,4,103,108,114,115,8793,8799,8805,8809,103,101,114,59,1,8224,101,116,104,59,1,8504,114,59,1,8595,104,4,2,59,118,8816,8818,1,8208,59,1,8867,4,2,107,108,8827,8834,97,114,111,119,59,1,10511,97,99,59,1,733,4,2,97,121,8845,8851,114,111,110,59,1,271,59,1,1076,4,3,59,97,111,8862,8864,8880,1,8518,4,2,103,114,8870,8876,103,101,114,59,1,8225,114,59,1,8650,116,115,101,113,59,1,10871,4,3,103,108,109,8895,8902,8907,5,176,1,59,8900,1,176,116,97,59,1,948,112,116,121,118,59,1,10673,4,2,105,114,8920,8926,115,104,116,59,1,10623,59,3,55349,56609,97,114,4,2,108,114,8938,8941,59,1,8643,59,1,8642,4,5,97,101,103,115,118,8956,8986,8989,8996,9001,109,4,3,59,111,115,8965,8967,8983,1,8900,110,100,4,2,59,115,8975,8977,1,8900,117,105,116,59,1,9830,59,1,9830,59,1,168,97,109,109,97,59,1,989,105,110,59,1,8946,4,3,59,105,111,9009,9011,9031,1,247,100,101,5,247,2,59,111,9020,9022,1,247,110,116,105,109,101,115,59,1,8903,110,120,59,1,8903,99,121,59,1,1106,99,4,2,111,114,9048,9053,114,110,59,1,8990,111,112,59,1,8973,4,5,108,112,116,117,119,9070,9076,9081,9130,9144,108,97,114,59,1,36,102,59,3,55349,56661,4,5,59,101,109,112,115,9093,9095,9109,9116,9122,1,729,113,4,2,59,100,9102,9104,1,8784,111,116,59,1,8785,105,110,117,115,59,1,8760,108,117,115,59,1,8724,113,117,97,114,101,59,1,8865,98,108,101,98,97,114,119,101,100,103,101,59,1,8966,110,4,3,97,100,104,9153,9160,9172,114,114,111,119,59,1,8595,111,119,110,97,114,114,111,119,115,59,1,8650,97,114,112,111,111,110,4,2,108,114,9184,9190,101,102,116,59,1,8643,105,103,104,116,59,1,8642,4,2,98,99,9203,9211,107,97,114,111,119,59,1,10512,4,2,111,114,9217,9222,114,110,59,1,8991,111,112,59,1,8972,4,3,99,111,116,9235,9248,9252,4,2,114,121,9241,9245,59,3,55349,56505,59,1,1109,108,59,1,10742,114,111,107,59,1,273,4,2,100,114,9264,9269,111,116,59,1,8945,105,4,2,59,102,9276,9278,1,9663,59,1,9662,4,2,97,104,9287,9292,114,114,59,1,8693,97,114,59,1,10607,97,110,103,108,101,59,1,10662,4,2,99,105,9311,9315,121,59,1,1119,103,114,97,114,114,59,1,10239,4,18,68,97,99,100,101,102,103,108,109,110,111,112,113,114,115,116,117,120,9361,9376,9398,9439,9444,9447,9462,9495,9531,9585,9598,9614,9659,9755,9771,9792,9808,9826,4,2,68,111,9367,9372,111,116,59,1,10871,116,59,1,8785,4,2,99,115,9382,9392,117,116,101,5,233,1,59,9390,1,233,116,101,114,59,1,10862,4,4,97,105,111,121,9408,9414,9430,9436,114,111,110,59,1,283,114,4,2,59,99,9421,9423,1,8790,5,234,1,59,9428,1,234,108,111,110,59,1,8789,59,1,1101,111,116,59,1,279,59,1,8519,4,2,68,114,9453,9458,111,116,59,1,8786,59,3,55349,56610,4,3,59,114,115,9470,9472,9482,1,10906,97,118,101,5,232,1,59,9480,1,232,4,2,59,100,9488,9490,1,10902,111,116,59,1,10904,4,4,59,105,108,115,9505,9507,9515,9518,1,10905,110,116,101,114,115,59,1,9191,59,1,8467,4,2,59,100,9524,9526,1,10901,111,116,59,1,10903,4,3,97,112,115,9539,9544,9564,99,114,59,1,275,116,121,4,3,59,115,118,9554,9556,9561,1,8709,101,116,59,1,8709,59,1,8709,112,4,2,49,59,9571,9583,4,2,51,52,9577,9580,59,1,8196,59,1,8197,1,8195,4,2,103,115,9591,9594,59,1,331,112,59,1,8194,4,2,103,112,9604,9609,111,110,59,1,281,102,59,3,55349,56662,4,3,97,108,115,9622,9635,9640,114,4,2,59,115,9629,9631,1,8917,108,59,1,10723,117,115,59,1,10865,105,4,3,59,108,118,9649,9651,9656,1,949,111,110,59,1,949,59,1,1013,4,4,99,115,117,118,9669,9686,9716,9747,4,2,105,111,9675,9680,114,99,59,1,8790,108,111,110,59,1,8789,4,2,105,108,9692,9696,109,59,1,8770,97,110,116,4,2,103,108,9705,9710,116,114,59,1,10902,101,115,115,59,1,10901,4,3,97,101,105,9724,9729,9734,108,115,59,1,61,115,116,59,1,8799,118,4,2,59,68,9741,9743,1,8801,68,59,1,10872,112,97,114,115,108,59,1,10725,4,2,68,97,9761,9766,111,116,59,1,8787,114,114,59,1,10609,4,3,99,100,105,9779,9783,9788,114,59,1,8495,111,116,59,1,8784,109,59,1,8770,4,2,97,104,9798,9801,59,1,951,5,240,1,59,9806,1,240,4,2,109,114,9814,9822,108,5,235,1,59,9820,1,235,111,59,1,8364,4,3,99,105,112,9834,9838,9843,108,59,1,33,115,116,59,1,8707,4,2,101,111,9849,9859,99,116,97,116,105,111,110,59,1,8496,110,101,110,116,105,97,108,101,59,1,8519,4,12,97,99,101,102,105,106,108,110,111,112,114,115,9896,9910,9914,9921,9954,9960,9967,9989,9994,10027,10036,10164,108,108,105,110,103,100,111,116,115,101,113,59,1,8786,121,59,1,1092,109,97,108,101,59,1,9792,4,3,105,108,114,9929,9935,9950,108,105,103,59,1,64259,4,2,105,108,9941,9945,103,59,1,64256,105,103,59,1,64260,59,3,55349,56611,108,105,103,59,1,64257,108,105,103,59,3,102,106,4,3,97,108,116,9975,9979,9984,116,59,1,9837,105,103,59,1,64258,110,115,59,1,9649,111,102,59,1,402,4,2,112,114,1e4,10005,102,59,3,55349,56663,4,2,97,107,10011,10016,108,108,59,1,8704,4,2,59,118,10022,10024,1,8916,59,1,10969,97,114,116,105,110,116,59,1,10765,4,2,97,111,10042,10159,4,2,99,115,10048,10155,4,6,49,50,51,52,53,55,10062,10102,10114,10135,10139,10151,4,6,50,51,52,53,54,56,10076,10083,10086,10093,10096,10099,5,189,1,59,10081,1,189,59,1,8531,5,188,1,59,10091,1,188,59,1,8533,59,1,8537,59,1,8539,4,2,51,53,10108,10111,59,1,8532,59,1,8534,4,3,52,53,56,10122,10129,10132,5,190,1,59,10127,1,190,59,1,8535,59,1,8540,53,59,1,8536,4,2,54,56,10145,10148,59,1,8538,59,1,8541,56,59,1,8542,108,59,1,8260,119,110,59,1,8994,99,114,59,3,55349,56507,4,17,69,97,98,99,100,101,102,103,105,106,108,110,111,114,115,116,118,10206,10217,10247,10254,10268,10273,10358,10363,10374,10380,10385,10406,10458,10464,10470,10497,10610,4,2,59,108,10212,10214,1,8807,59,1,10892,4,3,99,109,112,10225,10231,10244,117,116,101,59,1,501,109,97,4,2,59,100,10239,10241,1,947,59,1,989,59,1,10886,114,101,118,101,59,1,287,4,2,105,121,10260,10265,114,99,59,1,285,59,1,1075,111,116,59,1,289,4,4,59,108,113,115,10283,10285,10288,10308,1,8805,59,1,8923,4,3,59,113,115,10296,10298,10301,1,8805,59,1,8807,108,97,110,116,59,1,10878,4,4,59,99,100,108,10318,10320,10324,10345,1,10878,99,59,1,10921,111,116,4,2,59,111,10332,10334,1,10880,4,2,59,108,10340,10342,1,10882,59,1,10884,4,2,59,101,10351,10354,3,8923,65024,115,59,1,10900,114,59,3,55349,56612,4,2,59,103,10369,10371,1,8811,59,1,8921,109,101,108,59,1,8503,99,121,59,1,1107,4,4,59,69,97,106,10395,10397,10400,10403,1,8823,59,1,10898,59,1,10917,59,1,10916,4,4,69,97,101,115,10416,10419,10434,10453,59,1,8809,112,4,2,59,112,10426,10428,1,10890,114,111,120,59,1,10890,4,2,59,113,10440,10442,1,10888,4,2,59,113,10448,10450,1,10888,59,1,8809,105,109,59,1,8935,112,102,59,3,55349,56664,97,118,101,59,1,96,4,2,99,105,10476,10480,114,59,1,8458,109,4,3,59,101,108,10489,10491,10494,1,8819,59,1,10894,59,1,10896,5,62,6,59,99,100,108,113,114,10512,10514,10527,10532,10538,10545,1,62,4,2,99,105,10520,10523,59,1,10919,114,59,1,10874,111,116,59,1,8919,80,97,114,59,1,10645,117,101,115,116,59,1,10876,4,5,97,100,101,108,115,10557,10574,10579,10599,10605,4,2,112,114,10563,10570,112,114,111,120,59,1,10886,114,59,1,10616,111,116,59,1,8919,113,4,2,108,113,10586,10592,101,115,115,59,1,8923,108,101,115,115,59,1,10892,101,115,115,59,1,8823,105,109,59,1,8819,4,2,101,110,10616,10626,114,116,110,101,113,113,59,3,8809,65024,69,59,3,8809,65024,4,10,65,97,98,99,101,102,107,111,115,121,10653,10658,10713,10718,10724,10760,10765,10786,10850,10875,114,114,59,1,8660,4,4,105,108,109,114,10668,10674,10678,10684,114,115,112,59,1,8202,102,59,1,189,105,108,116,59,1,8459,4,2,100,114,10690,10695,99,121,59,1,1098,4,3,59,99,119,10703,10705,10710,1,8596,105,114,59,1,10568,59,1,8621,97,114,59,1,8463,105,114,99,59,1,293,4,3,97,108,114,10732,10748,10754,114,116,115,4,2,59,117,10741,10743,1,9829,105,116,59,1,9829,108,105,112,59,1,8230,99,111,110,59,1,8889,114,59,3,55349,56613,115,4,2,101,119,10772,10779,97,114,111,119,59,1,10533,97,114,111,119,59,1,10534,4,5,97,109,111,112,114,10798,10803,10809,10839,10844,114,114,59,1,8703,116,104,116,59,1,8763,107,4,2,108,114,10816,10827,101,102,116,97,114,114,111,119,59,1,8617,105,103,104,116,97,114,114,111,119,59,1,8618,102,59,3,55349,56665,98,97,114,59,1,8213,4,3,99,108,116,10858,10863,10869,114,59,3,55349,56509,97,115,104,59,1,8463,114,111,107,59,1,295,4,2,98,112,10881,10887,117,108,108,59,1,8259,104,101,110,59,1,8208,4,15,97,99,101,102,103,105,106,109,110,111,112,113,115,116,117,10925,10936,10958,10977,10990,11001,11039,11045,11101,11192,11220,11226,11237,11285,11299,99,117,116,101,5,237,1,59,10934,1,237,4,3,59,105,121,10944,10946,10955,1,8291,114,99,5,238,1,59,10953,1,238,59,1,1080,4,2,99,120,10964,10968,121,59,1,1077,99,108,5,161,1,59,10975,1,161,4,2,102,114,10983,10986,59,1,8660,59,3,55349,56614,114,97,118,101,5,236,1,59,10999,1,236,4,4,59,105,110,111,11011,11013,11028,11034,1,8520,4,2,105,110,11019,11024,110,116,59,1,10764,116,59,1,8749,102,105,110,59,1,10716,116,97,59,1,8489,108,105,103,59,1,307,4,3,97,111,112,11053,11092,11096,4,3,99,103,116,11061,11065,11088,114,59,1,299,4,3,101,108,112,11073,11076,11082,59,1,8465,105,110,101,59,1,8464,97,114,116,59,1,8465,104,59,1,305,102,59,1,8887,101,100,59,1,437,4,5,59,99,102,111,116,11113,11115,11121,11136,11142,1,8712,97,114,101,59,1,8453,105,110,4,2,59,116,11129,11131,1,8734,105,101,59,1,10717,100,111,116,59,1,305,4,5,59,99,101,108,112,11154,11156,11161,11179,11186,1,8747,97,108,59,1,8890,4,2,103,114,11167,11173,101,114,115,59,1,8484,99,97,108,59,1,8890,97,114,104,107,59,1,10775,114,111,100,59,1,10812,4,4,99,103,112,116,11202,11206,11211,11216,121,59,1,1105,111,110,59,1,303,102,59,3,55349,56666,97,59,1,953,114,111,100,59,1,10812,117,101,115,116,5,191,1,59,11235,1,191,4,2,99,105,11243,11248,114,59,3,55349,56510,110,4,5,59,69,100,115,118,11261,11263,11266,11271,11282,1,8712,59,1,8953,111,116,59,1,8949,4,2,59,118,11277,11279,1,8948,59,1,8947,59,1,8712,4,2,59,105,11291,11293,1,8290,108,100,101,59,1,297,4,2,107,109,11305,11310,99,121,59,1,1110,108,5,239,1,59,11316,1,239,4,6,99,102,109,111,115,117,11332,11346,11351,11357,11363,11380,4,2,105,121,11338,11343,114,99,59,1,309,59,1,1081,114,59,3,55349,56615,97,116,104,59,1,567,112,102,59,3,55349,56667,4,2,99,101,11369,11374,114,59,3,55349,56511,114,99,121,59,1,1112,107,99,121,59,1,1108,4,8,97,99,102,103,104,106,111,115,11404,11418,11433,11438,11445,11450,11455,11461,112,112,97,4,2,59,118,11413,11415,1,954,59,1,1008,4,2,101,121,11424,11430,100,105,108,59,1,311,59,1,1082,114,59,3,55349,56616,114,101,101,110,59,1,312,99,121,59,1,1093,99,121,59,1,1116,112,102,59,3,55349,56668,99,114,59,3,55349,56512,4,23,65,66,69,72,97,98,99,100,101,102,103,104,106,108,109,110,111,112,114,115,116,117,118,11515,11538,11544,11555,11560,11721,11780,11818,11868,12136,12160,12171,12203,12208,12246,12275,12327,12509,12523,12569,12641,12732,12752,4,3,97,114,116,11523,11528,11532,114,114,59,1,8666,114,59,1,8656,97,105,108,59,1,10523,97,114,114,59,1,10510,4,2,59,103,11550,11552,1,8806,59,1,10891,97,114,59,1,10594,4,9,99,101,103,109,110,112,113,114,116,11580,11586,11594,11600,11606,11624,11627,11636,11694,117,116,101,59,1,314,109,112,116,121,118,59,1,10676,114,97,110,59,1,8466,98,100,97,59,1,955,103,4,3,59,100,108,11615,11617,11620,1,10216,59,1,10641,101,59,1,10216,59,1,10885,117,111,5,171,1,59,11634,1,171,114,4,8,59,98,102,104,108,112,115,116,11655,11657,11669,11673,11677,11681,11685,11690,1,8592,4,2,59,102,11663,11665,1,8676,115,59,1,10527,115,59,1,10525,107,59,1,8617,112,59,1,8619,108,59,1,10553,105,109,59,1,10611,108,59,1,8610,4,3,59,97,101,11702,11704,11709,1,10923,105,108,59,1,10521,4,2,59,115,11715,11717,1,10925,59,3,10925,65024,4,3,97,98,114,11729,11734,11739,114,114,59,1,10508,114,107,59,1,10098,4,2,97,107,11745,11758,99,4,2,101,107,11752,11755,59,1,123,59,1,91,4,2,101,115,11764,11767,59,1,10635,108,4,2,100,117,11774,11777,59,1,10639,59,1,10637,4,4,97,101,117,121,11790,11796,11811,11815,114,111,110,59,1,318,4,2,100,105,11802,11807,105,108,59,1,316,108,59,1,8968,98,59,1,123,59,1,1083,4,4,99,113,114,115,11828,11832,11845,11864,97,59,1,10550,117,111,4,2,59,114,11840,11842,1,8220,59,1,8222,4,2,100,117,11851,11857,104,97,114,59,1,10599,115,104,97,114,59,1,10571,104,59,1,8626,4,5,59,102,103,113,115,11880,11882,12008,12011,12031,1,8804,116,4,5,97,104,108,114,116,11895,11913,11935,11947,11996,114,114,111,119,4,2,59,116,11905,11907,1,8592,97,105,108,59,1,8610,97,114,112,111,111,110,4,2,100,117,11925,11931,111,119,110,59,1,8637,112,59,1,8636,101,102,116,97,114,114,111,119,115,59,1,8647,105,103,104,116,4,3,97,104,115,11959,11974,11984,114,114,111,119,4,2,59,115,11969,11971,1,8596,59,1,8646,97,114,112,111,111,110,115,59,1,8651,113,117,105,103,97,114,114,111,119,59,1,8621,104,114,101,101,116,105,109,101,115,59,1,8907,59,1,8922,4,3,59,113,115,12019,12021,12024,1,8804,59,1,8806,108,97,110,116,59,1,10877,4,5,59,99,100,103,115,12043,12045,12049,12070,12083,1,10877,99,59,1,10920,111,116,4,2,59,111,12057,12059,1,10879,4,2,59,114,12065,12067,1,10881,59,1,10883,4,2,59,101,12076,12079,3,8922,65024,115,59,1,10899,4,5,97,100,101,103,115,12095,12103,12108,12126,12131,112,112,114,111,120,59,1,10885,111,116,59,1,8918,113,4,2,103,113,12115,12120,116,114,59,1,8922,103,116,114,59,1,10891,116,114,59,1,8822,105,109,59,1,8818,4,3,105,108,114,12144,12150,12156,115,104,116,59,1,10620,111,111,114,59,1,8970,59,3,55349,56617,4,2,59,69,12166,12168,1,8822,59,1,10897,4,2,97,98,12177,12198,114,4,2,100,117,12184,12187,59,1,8637,4,2,59,108,12193,12195,1,8636,59,1,10602,108,107,59,1,9604,99,121,59,1,1113,4,5,59,97,99,104,116,12220,12222,12227,12235,12241,1,8810,114,114,59,1,8647,111,114,110,101,114,59,1,8990,97,114,100,59,1,10603,114,105,59,1,9722,4,2,105,111,12252,12258,100,111,116,59,1,320,117,115,116,4,2,59,97,12267,12269,1,9136,99,104,101,59,1,9136,4,4,69,97,101,115,12285,12288,12303,12322,59,1,8808,112,4,2,59,112,12295,12297,1,10889,114,111,120,59,1,10889,4,2,59,113,12309,12311,1,10887,4,2,59,113,12317,12319,1,10887,59,1,8808,105,109,59,1,8934,4,8,97,98,110,111,112,116,119,122,12345,12359,12364,12421,12446,12467,12474,12490,4,2,110,114,12351,12355,103,59,1,10220,114,59,1,8701,114,107,59,1,10214,103,4,3,108,109,114,12373,12401,12409,101,102,116,4,2,97,114,12382,12389,114,114,111,119,59,1,10229,105,103,104,116,97,114,114,111,119,59,1,10231,97,112,115,116,111,59,1,10236,105,103,104,116,97,114,114,111,119,59,1,10230,112,97,114,114,111,119,4,2,108,114,12433,12439,101,102,116,59,1,8619,105,103,104,116,59,1,8620,4,3,97,102,108,12454,12458,12462,114,59,1,10629,59,3,55349,56669,117,115,59,1,10797,105,109,101,115,59,1,10804,4,2,97,98,12480,12485,115,116,59,1,8727,97,114,59,1,95,4,3,59,101,102,12498,12500,12506,1,9674,110,103,101,59,1,9674,59,1,10731,97,114,4,2,59,108,12517,12519,1,40,116,59,1,10643,4,5,97,99,104,109,116,12535,12540,12548,12561,12564,114,114,59,1,8646,111,114,110,101,114,59,1,8991,97,114,4,2,59,100,12556,12558,1,8651,59,1,10605,59,1,8206,114,105,59,1,8895,4,6,97,99,104,105,113,116,12583,12589,12594,12597,12614,12635,113,117,111,59,1,8249,114,59,3,55349,56513,59,1,8624,109,4,3,59,101,103,12606,12608,12611,1,8818,59,1,10893,59,1,10895,4,2,98,117,12620,12623,59,1,91,111,4,2,59,114,12630,12632,1,8216,59,1,8218,114,111,107,59,1,322,5,60,8,59,99,100,104,105,108,113,114,12660,12662,12675,12680,12686,12692,12698,12705,1,60,4,2,99,105,12668,12671,59,1,10918,114,59,1,10873,111,116,59,1,8918,114,101,101,59,1,8907,109,101,115,59,1,8905,97,114,114,59,1,10614,117,101,115,116,59,1,10875,4,2,80,105,12711,12716,97,114,59,1,10646,4,3,59,101,102,12724,12726,12729,1,9667,59,1,8884,59,1,9666,114,4,2,100,117,12739,12746,115,104,97,114,59,1,10570,104,97,114,59,1,10598,4,2,101,110,12758,12768,114,116,110,101,113,113,59,3,8808,65024,69,59,3,8808,65024,4,14,68,97,99,100,101,102,104,105,108,110,111,112,115,117,12803,12809,12893,12908,12914,12928,12933,12937,13011,13025,13032,13049,13052,13069,68,111,116,59,1,8762,4,4,99,108,112,114,12819,12827,12849,12887,114,5,175,1,59,12825,1,175,4,2,101,116,12833,12836,59,1,9794,4,2,59,101,12842,12844,1,10016,115,101,59,1,10016,4,2,59,115,12855,12857,1,8614,116,111,4,4,59,100,108,117,12869,12871,12877,12883,1,8614,111,119,110,59,1,8615,101,102,116,59,1,8612,112,59,1,8613,107,101,114,59,1,9646,4,2,111,121,12899,12905,109,109,97,59,1,10793,59,1,1084,97,115,104,59,1,8212,97,115,117,114,101,100,97,110,103,108,101,59,1,8737,114,59,3,55349,56618,111,59,1,8487,4,3,99,100,110,12945,12954,12985,114,111,5,181,1,59,12952,1,181,4,4,59,97,99,100,12964,12966,12971,12976,1,8739,115,116,59,1,42,105,114,59,1,10992,111,116,5,183,1,59,12983,1,183,117,115,4,3,59,98,100,12995,12997,13e3,1,8722,59,1,8863,4,2,59,117,13006,13008,1,8760,59,1,10794,4,2,99,100,13017,13021,112,59,1,10971,114,59,1,8230,112,108,117,115,59,1,8723,4,2,100,112,13038,13044,101,108,115,59,1,8871,102,59,3,55349,56670,59,1,8723,4,2,99,116,13058,13063,114,59,3,55349,56514,112,111,115,59,1,8766,4,3,59,108,109,13077,13079,13087,1,956,116,105,109,97,112,59,1,8888,97,112,59,1,8888,4,24,71,76,82,86,97,98,99,100,101,102,103,104,105,106,108,109,111,112,114,115,116,117,118,119,13142,13165,13217,13229,13247,13330,13359,13414,13420,13508,13513,13579,13602,13626,13631,13762,13767,13855,13936,13995,14214,14285,14312,14432,4,2,103,116,13148,13152,59,3,8921,824,4,2,59,118,13158,13161,3,8811,8402,59,3,8811,824,4,3,101,108,116,13173,13200,13204,102,116,4,2,97,114,13181,13188,114,114,111,119,59,1,8653,105,103,104,116,97,114,114,111,119,59,1,8654,59,3,8920,824,4,2,59,118,13210,13213,3,8810,8402,59,3,8810,824,105,103,104,116,97,114,114,111,119,59,1,8655,4,2,68,100,13235,13241,97,115,104,59,1,8879,97,115,104,59,1,8878,4,5,98,99,110,112,116,13259,13264,13270,13275,13308,108,97,59,1,8711,117,116,101,59,1,324,103,59,3,8736,8402,4,5,59,69,105,111,112,13287,13289,13293,13298,13302,1,8777,59,3,10864,824,100,59,3,8779,824,115,59,1,329,114,111,120,59,1,8777,117,114,4,2,59,97,13316,13318,1,9838,108,4,2,59,115,13325,13327,1,9838,59,1,8469,4,2,115,117,13336,13344,112,5,160,1,59,13342,1,160,109,112,4,2,59,101,13352,13355,3,8782,824,59,3,8783,824,4,5,97,101,111,117,121,13371,13385,13391,13407,13411,4,2,112,114,13377,13380,59,1,10819,111,110,59,1,328,100,105,108,59,1,326,110,103,4,2,59,100,13399,13401,1,8775,111,116,59,3,10861,824,112,59,1,10818,59,1,1085,97,115,104,59,1,8211,4,7,59,65,97,100,113,115,120,13436,13438,13443,13466,13472,13478,13494,1,8800,114,114,59,1,8663,114,4,2,104,114,13450,13454,107,59,1,10532,4,2,59,111,13460,13462,1,8599,119,59,1,8599,111,116,59,3,8784,824,117,105,118,59,1,8802,4,2,101,105,13484,13489,97,114,59,1,10536,109,59,3,8770,824,105,115,116,4,2,59,115,13503,13505,1,8708,59,1,8708,114,59,3,55349,56619,4,4,69,101,115,116,13523,13527,13563,13568,59,3,8807,824,4,3,59,113,115,13535,13537,13559,1,8817,4,3,59,113,115,13545,13547,13551,1,8817,59,3,8807,824,108,97,110,116,59,3,10878,824,59,3,10878,824,105,109,59,1,8821,4,2,59,114,13574,13576,1,8815,59,1,8815,4,3,65,97,112,13587,13592,13597,114,114,59,1,8654,114,114,59,1,8622,97,114,59,1,10994,4,3,59,115,118,13610,13612,13623,1,8715,4,2,59,100,13618,13620,1,8956,59,1,8954,59,1,8715,99,121,59,1,1114,4,7,65,69,97,100,101,115,116,13647,13652,13656,13661,13665,13737,13742,114,114,59,1,8653,59,3,8806,824,114,114,59,1,8602,114,59,1,8229,4,4,59,102,113,115,13675,13677,13703,13725,1,8816,116,4,2,97,114,13684,13691,114,114,111,119,59,1,8602,105,103,104,116,97,114,114,111,119,59,1,8622,4,3,59,113,115,13711,13713,13717,1,8816,59,3,8806,824,108,97,110,116,59,3,10877,824,4,2,59,115,13731,13734,3,10877,824,59,1,8814,105,109,59,1,8820,4,2,59,114,13748,13750,1,8814,105,4,2,59,101,13757,13759,1,8938,59,1,8940,105,100,59,1,8740,4,2,112,116,13773,13778,102,59,3,55349,56671,5,172,3,59,105,110,13787,13789,13829,1,172,110,4,4,59,69,100,118,13800,13802,13806,13812,1,8713,59,3,8953,824,111,116,59,3,8949,824,4,3,97,98,99,13820,13823,13826,59,1,8713,59,1,8951,59,1,8950,105,4,2,59,118,13836,13838,1,8716,4,3,97,98,99,13846,13849,13852,59,1,8716,59,1,8958,59,1,8957,4,3,97,111,114,13863,13892,13899,114,4,4,59,97,115,116,13874,13876,13883,13888,1,8742,108,108,101,108,59,1,8742,108,59,3,11005,8421,59,3,8706,824,108,105,110,116,59,1,10772,4,3,59,99,101,13907,13909,13914,1,8832,117,101,59,1,8928,4,2,59,99,13920,13923,3,10927,824,4,2,59,101,13929,13931,1,8832,113,59,3,10927,824,4,4,65,97,105,116,13946,13951,13971,13982,114,114,59,1,8655,114,114,4,3,59,99,119,13961,13963,13967,1,8603,59,3,10547,824,59,3,8605,824,103,104,116,97,114,114,111,119,59,1,8603,114,105,4,2,59,101,13990,13992,1,8939,59,1,8941,4,7,99,104,105,109,112,113,117,14011,14036,14060,14080,14085,14090,14106,4,4,59,99,101,114,14021,14023,14028,14032,1,8833,117,101,59,1,8929,59,3,10928,824,59,3,55349,56515,111,114,116,4,2,109,112,14045,14050,105,100,59,1,8740,97,114,97,108,108,101,108,59,1,8742,109,4,2,59,101,14067,14069,1,8769,4,2,59,113,14075,14077,1,8772,59,1,8772,105,100,59,1,8740,97,114,59,1,8742,115,117,4,2,98,112,14098,14102,101,59,1,8930,101,59,1,8931,4,3,98,99,112,14114,14157,14171,4,4,59,69,101,115,14124,14126,14130,14133,1,8836,59,3,10949,824,59,1,8840,101,116,4,2,59,101,14141,14144,3,8834,8402,113,4,2,59,113,14151,14153,1,8840,59,3,10949,824,99,4,2,59,101,14164,14166,1,8833,113,59,3,10928,824,4,4,59,69,101,115,14181,14183,14187,14190,1,8837,59,3,10950,824,59,1,8841,101,116,4,2,59,101,14198,14201,3,8835,8402,113,4,2,59,113,14208,14210,1,8841,59,3,10950,824,4,4,103,105,108,114,14224,14228,14238,14242,108,59,1,8825,108,100,101,5,241,1,59,14236,1,241,103,59,1,8824,105,97,110,103,108,101,4,2,108,114,14254,14269,101,102,116,4,2,59,101,14263,14265,1,8938,113,59,1,8940,105,103,104,116,4,2,59,101,14279,14281,1,8939,113,59,1,8941,4,2,59,109,14291,14293,1,957,4,3,59,101,115,14301,14303,14308,1,35,114,111,59,1,8470,112,59,1,8199,4,9,68,72,97,100,103,105,108,114,115,14332,14338,14344,14349,14355,14369,14376,14408,14426,97,115,104,59,1,8877,97,114,114,59,1,10500,112,59,3,8781,8402,97,115,104,59,1,8876,4,2,101,116,14361,14365,59,3,8805,8402,59,3,62,8402,110,102,105,110,59,1,10718,4,3,65,101,116,14384,14389,14393,114,114,59,1,10498,59,3,8804,8402,4,2,59,114,14399,14402,3,60,8402,105,101,59,3,8884,8402,4,2,65,116,14414,14419,114,114,59,1,10499,114,105,101,59,3,8885,8402,105,109,59,3,8764,8402,4,3,65,97,110,14440,14445,14468,114,114,59,1,8662,114,4,2,104,114,14452,14456,107,59,1,10531,4,2,59,111,14462,14464,1,8598,119,59,1,8598,101,97,114,59,1,10535,4,18,83,97,99,100,101,102,103,104,105,108,109,111,112,114,115,116,117,118,14512,14515,14535,14560,14597,14603,14618,14643,14657,14662,14701,14741,14747,14769,14851,14877,14907,14916,59,1,9416,4,2,99,115,14521,14531,117,116,101,5,243,1,59,14529,1,243,116,59,1,8859,4,2,105,121,14541,14557,114,4,2,59,99,14548,14550,1,8858,5,244,1,59,14555,1,244,59,1,1086,4,5,97,98,105,111,115,14572,14577,14583,14587,14591,115,104,59,1,8861,108,97,99,59,1,337,118,59,1,10808,116,59,1,8857,111,108,100,59,1,10684,108,105,103,59,1,339,4,2,99,114,14609,14614,105,114,59,1,10687,59,3,55349,56620,4,3,111,114,116,14626,14630,14640,110,59,1,731,97,118,101,5,242,1,59,14638,1,242,59,1,10689,4,2,98,109,14649,14654,97,114,59,1,10677,59,1,937,110,116,59,1,8750,4,4,97,99,105,116,14672,14677,14693,14698,114,114,59,1,8634,4,2,105,114,14683,14687,114,59,1,10686,111,115,115,59,1,10683,110,101,59,1,8254,59,1,10688,4,3,97,101,105,14709,14714,14719,99,114,59,1,333,103,97,59,1,969,4,3,99,100,110,14727,14733,14736,114,111,110,59,1,959,59,1,10678,117,115,59,1,8854,112,102,59,3,55349,56672,4,3,97,101,108,14755,14759,14764,114,59,1,10679,114,112,59,1,10681,117,115,59,1,8853,4,7,59,97,100,105,111,115,118,14785,14787,14792,14831,14837,14841,14848,1,8744,114,114,59,1,8635,4,4,59,101,102,109,14802,14804,14817,14824,1,10845,114,4,2,59,111,14811,14813,1,8500,102,59,1,8500,5,170,1,59,14822,1,170,5,186,1,59,14829,1,186,103,111,102,59,1,8886,114,59,1,10838,108,111,112,101,59,1,10839,59,1,10843,4,3,99,108,111,14859,14863,14873,114,59,1,8500,97,115,104,5,248,1,59,14871,1,248,108,59,1,8856,105,4,2,108,109,14884,14893,100,101,5,245,1,59,14891,1,245,101,115,4,2,59,97,14901,14903,1,8855,115,59,1,10806,109,108,5,246,1,59,14914,1,246,98,97,114,59,1,9021,4,12,97,99,101,102,104,105,108,109,111,114,115,117,14948,14992,14996,15033,15038,15068,15090,15189,15192,15222,15427,15441,114,4,4,59,97,115,116,14959,14961,14976,14989,1,8741,5,182,2,59,108,14968,14970,1,182,108,101,108,59,1,8741,4,2,105,108,14982,14986,109,59,1,10995,59,1,11005,59,1,8706,121,59,1,1087,114,4,5,99,105,109,112,116,15009,15014,15019,15024,15027,110,116,59,1,37,111,100,59,1,46,105,108,59,1,8240,59,1,8869,101,110,107,59,1,8241,114,59,3,55349,56621,4,3,105,109,111,15046,15057,15063,4,2,59,118,15052,15054,1,966,59,1,981,109,97,116,59,1,8499,110,101,59,1,9742,4,3,59,116,118,15076,15078,15087,1,960,99,104,102,111,114,107,59,1,8916,59,1,982,4,2,97,117,15096,15119,110,4,2,99,107,15103,15115,107,4,2,59,104,15110,15112,1,8463,59,1,8462,118,59,1,8463,115,4,9,59,97,98,99,100,101,109,115,116,15140,15142,15148,15151,15156,15168,15171,15179,15184,1,43,99,105,114,59,1,10787,59,1,8862,105,114,59,1,10786,4,2,111,117,15162,15165,59,1,8724,59,1,10789,59,1,10866,110,5,177,1,59,15177,1,177,105,109,59,1,10790,119,111,59,1,10791,59,1,177,4,3,105,112,117,15200,15208,15213,110,116,105,110,116,59,1,10773,102,59,3,55349,56673,110,100,5,163,1,59,15220,1,163,4,10,59,69,97,99,101,105,110,111,115,117,15244,15246,15249,15253,15258,15334,15347,15367,15416,15421,1,8826,59,1,10931,112,59,1,10935,117,101,59,1,8828,4,2,59,99,15264,15266,1,10927,4,6,59,97,99,101,110,115,15280,15282,15290,15299,15303,15329,1,8826,112,112,114,111,120,59,1,10935,117,114,108,121,101,113,59,1,8828,113,59,1,10927,4,3,97,101,115,15311,15319,15324,112,112,114,111,120,59,1,10937,113,113,59,1,10933,105,109,59,1,8936,105,109,59,1,8830,109,101,4,2,59,115,15342,15344,1,8242,59,1,8473,4,3,69,97,115,15355,15358,15362,59,1,10933,112,59,1,10937,105,109,59,1,8936,4,3,100,102,112,15375,15378,15404,59,1,8719,4,3,97,108,115,15386,15392,15398,108,97,114,59,1,9006,105,110,101,59,1,8978,117,114,102,59,1,8979,4,2,59,116,15410,15412,1,8733,111,59,1,8733,105,109,59,1,8830,114,101,108,59,1,8880,4,2,99,105,15433,15438,114,59,3,55349,56517,59,1,968,110,99,115,112,59,1,8200,4,6,102,105,111,112,115,117,15462,15467,15472,15478,15485,15491,114,59,3,55349,56622,110,116,59,1,10764,112,102,59,3,55349,56674,114,105,109,101,59,1,8279,99,114,59,3,55349,56518,4,3,97,101,111,15499,15520,15534,116,4,2,101,105,15506,15515,114,110,105,111,110,115,59,1,8461,110,116,59,1,10774,115,116,4,2,59,101,15528,15530,1,63,113,59,1,8799,116,5,34,1,59,15540,1,34,4,21,65,66,72,97,98,99,100,101,102,104,105,108,109,110,111,112,114,115,116,117,120,15586,15609,15615,15620,15796,15855,15893,15931,15977,16001,16039,16183,16204,16222,16228,16285,16312,16318,16363,16408,16416,4,3,97,114,116,15594,15599,15603,114,114,59,1,8667,114,59,1,8658,97,105,108,59,1,10524,97,114,114,59,1,10511,97,114,59,1,10596,4,7,99,100,101,110,113,114,116,15636,15651,15656,15664,15687,15696,15770,4,2,101,117,15642,15646,59,3,8765,817,116,101,59,1,341,105,99,59,1,8730,109,112,116,121,118,59,1,10675,103,4,4,59,100,101,108,15675,15677,15680,15683,1,10217,59,1,10642,59,1,10661,101,59,1,10217,117,111,5,187,1,59,15694,1,187,114,4,11,59,97,98,99,102,104,108,112,115,116,119,15721,15723,15727,15739,15742,15746,15750,15754,15758,15763,15767,1,8594,112,59,1,10613,4,2,59,102,15733,15735,1,8677,115,59,1,10528,59,1,10547,115,59,1,10526,107,59,1,8618,112,59,1,8620,108,59,1,10565,105,109,59,1,10612,108,59,1,8611,59,1,8605,4,2,97,105,15776,15781,105,108,59,1,10522,111,4,2,59,110,15788,15790,1,8758,97,108,115,59,1,8474,4,3,97,98,114,15804,15809,15814,114,114,59,1,10509,114,107,59,1,10099,4,2,97,107,15820,15833,99,4,2,101,107,15827,15830,59,1,125,59,1,93,4,2,101,115,15839,15842,59,1,10636,108,4,2,100,117,15849,15852,59,1,10638,59,1,10640,4,4,97,101,117,121,15865,15871,15886,15890,114,111,110,59,1,345,4,2,100,105,15877,15882,105,108,59,1,343,108,59,1,8969,98,59,1,125,59,1,1088,4,4,99,108,113,115,15903,15907,15914,15927,97,59,1,10551,100,104,97,114,59,1,10601,117,111,4,2,59,114,15922,15924,1,8221,59,1,8221,104,59,1,8627,4,3,97,99,103,15939,15966,15970,108,4,4,59,105,112,115,15950,15952,15957,15963,1,8476,110,101,59,1,8475,97,114,116,59,1,8476,59,1,8477,116,59,1,9645,5,174,1,59,15975,1,174,4,3,105,108,114,15985,15991,15997,115,104,116,59,1,10621,111,111,114,59,1,8971,59,3,55349,56623,4,2,97,111,16007,16028,114,4,2,100,117,16014,16017,59,1,8641,4,2,59,108,16023,16025,1,8640,59,1,10604,4,2,59,118,16034,16036,1,961,59,1,1009,4,3,103,110,115,16047,16167,16171,104,116,4,6,97,104,108,114,115,116,16063,16081,16103,16130,16143,16155,114,114,111,119,4,2,59,116,16073,16075,1,8594,97,105,108,59,1,8611,97,114,112,111,111,110,4,2,100,117,16093,16099,111,119,110,59,1,8641,112,59,1,8640,101,102,116,4,2,97,104,16112,16120,114,114,111,119,115,59,1,8644,97,114,112,111,111,110,115,59,1,8652,105,103,104,116,97,114,114,111,119,115,59,1,8649,113,117,105,103,97,114,114,111,119,59,1,8605,104,114,101,101,116,105,109,101,115,59,1,8908,103,59,1,730,105,110,103,100,111,116,115,101,113,59,1,8787,4,3,97,104,109,16191,16196,16201,114,114,59,1,8644,97,114,59,1,8652,59,1,8207,111,117,115,116,4,2,59,97,16214,16216,1,9137,99,104,101,59,1,9137,109,105,100,59,1,10990,4,4,97,98,112,116,16238,16252,16257,16278,4,2,110,114,16244,16248,103,59,1,10221,114,59,1,8702,114,107,59,1,10215,4,3,97,102,108,16265,16269,16273,114,59,1,10630,59,3,55349,56675,117,115,59,1,10798,105,109,101,115,59,1,10805,4,2,97,112,16291,16304,114,4,2,59,103,16298,16300,1,41,116,59,1,10644,111,108,105,110,116,59,1,10770,97,114,114,59,1,8649,4,4,97,99,104,113,16328,16334,16339,16342,113,117,111,59,1,8250,114,59,3,55349,56519,59,1,8625,4,2,98,117,16348,16351,59,1,93,111,4,2,59,114,16358,16360,1,8217,59,1,8217,4,3,104,105,114,16371,16377,16383,114,101,101,59,1,8908,109,101,115,59,1,8906,105,4,4,59,101,102,108,16394,16396,16399,16402,1,9657,59,1,8885,59,1,9656,116,114,105,59,1,10702,108,117,104,97,114,59,1,10600,59,1,8478,4,19,97,98,99,100,101,102,104,105,108,109,111,112,113,114,115,116,117,119,122,16459,16466,16472,16572,16590,16672,16687,16746,16844,16850,16924,16963,16988,17115,17121,17154,17206,17614,17656,99,117,116,101,59,1,347,113,117,111,59,1,8218,4,10,59,69,97,99,101,105,110,112,115,121,16494,16496,16499,16513,16518,16531,16536,16556,16564,16569,1,8827,59,1,10932,4,2,112,114,16505,16508,59,1,10936,111,110,59,1,353,117,101,59,1,8829,4,2,59,100,16524,16526,1,10928,105,108,59,1,351,114,99,59,1,349,4,3,69,97,115,16544,16547,16551,59,1,10934,112,59,1,10938,105,109,59,1,8937,111,108,105,110,116,59,1,10771,105,109,59,1,8831,59,1,1089,111,116,4,3,59,98,101,16582,16584,16587,1,8901,59,1,8865,59,1,10854,4,7,65,97,99,109,115,116,120,16606,16611,16634,16642,16646,16652,16668,114,114,59,1,8664,114,4,2,104,114,16618,16622,107,59,1,10533,4,2,59,111,16628,16630,1,8600,119,59,1,8600,116,5,167,1,59,16640,1,167,105,59,1,59,119,97,114,59,1,10537,109,4,2,105,110,16659,16665,110,117,115,59,1,8726,59,1,8726,116,59,1,10038,114,4,2,59,111,16679,16682,3,55349,56624,119,110,59,1,8994,4,4,97,99,111,121,16697,16702,16716,16739,114,112,59,1,9839,4,2,104,121,16708,16713,99,121,59,1,1097,59,1,1096,114,116,4,2,109,112,16724,16729,105,100,59,1,8739,97,114,97,108,108,101,108,59,1,8741,5,173,1,59,16744,1,173,4,2,103,109,16752,16770,109,97,4,3,59,102,118,16762,16764,16767,1,963,59,1,962,59,1,962,4,8,59,100,101,103,108,110,112,114,16788,16790,16795,16806,16817,16828,16832,16838,1,8764,111,116,59,1,10858,4,2,59,113,16801,16803,1,8771,59,1,8771,4,2,59,69,16812,16814,1,10910,59,1,10912,4,2,59,69,16823,16825,1,10909,59,1,10911,101,59,1,8774,108,117,115,59,1,10788,97,114,114,59,1,10610,97,114,114,59,1,8592,4,4,97,101,105,116,16860,16883,16891,16904,4,2,108,115,16866,16878,108,115,101,116,109,105,110,117,115,59,1,8726,104,112,59,1,10803,112,97,114,115,108,59,1,10724,4,2,100,108,16897,16900,59,1,8739,101,59,1,8995,4,2,59,101,16910,16912,1,10922,4,2,59,115,16918,16920,1,10924,59,3,10924,65024,4,3,102,108,112,16932,16938,16958,116,99,121,59,1,1100,4,2,59,98,16944,16946,1,47,4,2,59,97,16952,16954,1,10692,114,59,1,9023,102,59,3,55349,56676,97,4,2,100,114,16970,16985,101,115,4,2,59,117,16978,16980,1,9824,105,116,59,1,9824,59,1,8741,4,3,99,115,117,16996,17028,17089,4,2,97,117,17002,17015,112,4,2,59,115,17009,17011,1,8851,59,3,8851,65024,112,4,2,59,115,17022,17024,1,8852,59,3,8852,65024,117,4,2,98,112,17035,17062,4,3,59,101,115,17043,17045,17048,1,8847,59,1,8849,101,116,4,2,59,101,17056,17058,1,8847,113,59,1,8849,4,3,59,101,115,17070,17072,17075,1,8848,59,1,8850,101,116,4,2,59,101,17083,17085,1,8848,113,59,1,8850,4,3,59,97,102,17097,17099,17112,1,9633,114,4,2,101,102,17106,17109,59,1,9633,59,1,9642,59,1,9642,97,114,114,59,1,8594,4,4,99,101,109,116,17131,17136,17142,17148,114,59,3,55349,56520,116,109,110,59,1,8726,105,108,101,59,1,8995,97,114,102,59,1,8902,4,2,97,114,17160,17172,114,4,2,59,102,17167,17169,1,9734,59,1,9733,4,2,97,110,17178,17202,105,103,104,116,4,2,101,112,17188,17197,112,115,105,108,111,110,59,1,1013,104,105,59,1,981,115,59,1,175,4,5,98,99,109,110,112,17218,17351,17420,17423,17427,4,9,59,69,100,101,109,110,112,114,115,17238,17240,17243,17248,17261,17267,17279,17285,17291,1,8834,59,1,10949,111,116,59,1,10941,4,2,59,100,17254,17256,1,8838,111,116,59,1,10947,117,108,116,59,1,10945,4,2,69,101,17273,17276,59,1,10955,59,1,8842,108,117,115,59,1,10943,97,114,114,59,1,10617,4,3,101,105,117,17299,17335,17339,116,4,3,59,101,110,17308,17310,17322,1,8834,113,4,2,59,113,17317,17319,1,8838,59,1,10949,101,113,4,2,59,113,17330,17332,1,8842,59,1,10955,109,59,1,10951,4,2,98,112,17345,17348,59,1,10965,59,1,10963,99,4,6,59,97,99,101,110,115,17366,17368,17376,17385,17389,17415,1,8827,112,112,114,111,120,59,1,10936,117,114,108,121,101,113,59,1,8829,113,59,1,10928,4,3,97,101,115,17397,17405,17410,112,112,114,111,120,59,1,10938,113,113,59,1,10934,105,109,59,1,8937,105,109,59,1,8831,59,1,8721,103,59,1,9834,4,13,49,50,51,59,69,100,101,104,108,109,110,112,115,17455,17462,17469,17476,17478,17481,17496,17509,17524,17530,17536,17548,17554,5,185,1,59,17460,1,185,5,178,1,59,17467,1,178,5,179,1,59,17474,1,179,1,8835,59,1,10950,4,2,111,115,17487,17491,116,59,1,10942,117,98,59,1,10968,4,2,59,100,17502,17504,1,8839,111,116,59,1,10948,115,4,2,111,117,17516,17520,108,59,1,10185,98,59,1,10967,97,114,114,59,1,10619,117,108,116,59,1,10946,4,2,69,101,17542,17545,59,1,10956,59,1,8843,108,117,115,59,1,10944,4,3,101,105,117,17562,17598,17602,116,4,3,59,101,110,17571,17573,17585,1,8835,113,4,2,59,113,17580,17582,1,8839,59,1,10950,101,113,4,2,59,113,17593,17595,1,8843,59,1,10956,109,59,1,10952,4,2,98,112,17608,17611,59,1,10964,59,1,10966,4,3,65,97,110,17622,17627,17650,114,114,59,1,8665,114,4,2,104,114,17634,17638,107,59,1,10534,4,2,59,111,17644,17646,1,8601,119,59,1,8601,119,97,114,59,1,10538,108,105,103,5,223,1,59,17664,1,223,4,13,97,98,99,100,101,102,104,105,111,112,114,115,119,17694,17709,17714,17737,17742,17749,17754,17860,17905,17957,17964,18090,18122,4,2,114,117,17700,17706,103,101,116,59,1,8982,59,1,964,114,107,59,1,9140,4,3,97,101,121,17722,17728,17734,114,111,110,59,1,357,100,105,108,59,1,355,59,1,1090,111,116,59,1,8411,108,114,101,99,59,1,8981,114,59,3,55349,56625,4,4,101,105,107,111,17764,17805,17836,17851,4,2,114,116,17770,17786,101,4,2,52,102,17777,17780,59,1,8756,111,114,101,59,1,8756,97,4,3,59,115,118,17795,17797,17802,1,952,121,109,59,1,977,59,1,977,4,2,99,110,17811,17831,107,4,2,97,115,17818,17826,112,112,114,111,120,59,1,8776,105,109,59,1,8764,115,112,59,1,8201,4,2,97,115,17842,17846,112,59,1,8776,105,109,59,1,8764,114,110,5,254,1,59,17858,1,254,4,3,108,109,110,17868,17873,17901,100,101,59,1,732,101,115,5,215,3,59,98,100,17884,17886,17898,1,215,4,2,59,97,17892,17894,1,8864,114,59,1,10801,59,1,10800,116,59,1,8749,4,3,101,112,115,17913,17917,17953,97,59,1,10536,4,4,59,98,99,102,17927,17929,17934,17939,1,8868,111,116,59,1,9014,105,114,59,1,10993,4,2,59,111,17945,17948,3,55349,56677,114,107,59,1,10970,97,59,1,10537,114,105,109,101,59,1,8244,4,3,97,105,112,17972,17977,18082,100,101,59,1,8482,4,7,97,100,101,109,112,115,116,17993,18051,18056,18059,18066,18072,18076,110,103,108,101,4,5,59,100,108,113,114,18009,18011,18017,18032,18035,1,9653,111,119,110,59,1,9663,101,102,116,4,2,59,101,18026,18028,1,9667,113,59,1,8884,59,1,8796,105,103,104,116,4,2,59,101,18045,18047,1,9657,113,59,1,8885,111,116,59,1,9708,59,1,8796,105,110,117,115,59,1,10810,108,117,115,59,1,10809,98,59,1,10701,105,109,101,59,1,10811,101,122,105,117,109,59,1,9186,4,3,99,104,116,18098,18111,18116,4,2,114,121,18104,18108,59,3,55349,56521,59,1,1094,99,121,59,1,1115,114,111,107,59,1,359,4,2,105,111,18128,18133,120,116,59,1,8812,104,101,97,100,4,2,108,114,18143,18154,101,102,116,97,114,114,111,119,59,1,8606,105,103,104,116,97,114,114,111,119,59,1,8608,4,18,65,72,97,98,99,100,102,103,104,108,109,111,112,114,115,116,117,119,18204,18209,18214,18234,18250,18268,18292,18308,18319,18343,18379,18397,18413,18504,18547,18553,18584,18603,114,114,59,1,8657,97,114,59,1,10595,4,2,99,114,18220,18230,117,116,101,5,250,1,59,18228,1,250,114,59,1,8593,114,4,2,99,101,18241,18245,121,59,1,1118,118,101,59,1,365,4,2,105,121,18256,18265,114,99,5,251,1,59,18263,1,251,59,1,1091,4,3,97,98,104,18276,18281,18287,114,114,59,1,8645,108,97,99,59,1,369,97,114,59,1,10606,4,2,105,114,18298,18304,115,104,116,59,1,10622,59,3,55349,56626,114,97,118,101,5,249,1,59,18317,1,249,4,2,97,98,18325,18338,114,4,2,108,114,18332,18335,59,1,8639,59,1,8638,108,107,59,1,9600,4,2,99,116,18349,18374,4,2,111,114,18355,18369,114,110,4,2,59,101,18363,18365,1,8988,114,59,1,8988,111,112,59,1,8975,114,105,59,1,9720,4,2,97,108,18385,18390,99,114,59,1,363,5,168,1,59,18395,1,168,4,2,103,112,18403,18408,111,110,59,1,371,102,59,3,55349,56678,4,6,97,100,104,108,115,117,18427,18434,18445,18470,18475,18494,114,114,111,119,59,1,8593,111,119,110,97,114,114,111,119,59,1,8597,97,114,112,111,111,110,4,2,108,114,18457,18463,101,102,116,59,1,8639,105,103,104,116,59,1,8638,117,115,59,1,8846,105,4,3,59,104,108,18484,18486,18489,1,965,59,1,978,111,110,59,1,965,112,97,114,114,111,119,115,59,1,8648,4,3,99,105,116,18512,18537,18542,4,2,111,114,18518,18532,114,110,4,2,59,101,18526,18528,1,8989,114,59,1,8989,111,112,59,1,8974,110,103,59,1,367,114,105,59,1,9721,99,114,59,3,55349,56522,4,3,100,105,114,18561,18566,18572,111,116,59,1,8944,108,100,101,59,1,361,105,4,2,59,102,18579,18581,1,9653,59,1,9652,4,2,97,109,18590,18595,114,114,59,1,8648,108,5,252,1,59,18601,1,252,97,110,103,108,101,59,1,10663,4,15,65,66,68,97,99,100,101,102,108,110,111,112,114,115,122,18643,18648,18661,18667,18847,18851,18857,18904,18909,18915,18931,18937,18943,18949,18996,114,114,59,1,8661,97,114,4,2,59,118,18656,18658,1,10984,59,1,10985,97,115,104,59,1,8872,4,2,110,114,18673,18679,103,114,116,59,1,10652,4,7,101,107,110,112,114,115,116,18695,18704,18711,18720,18742,18754,18810,112,115,105,108,111,110,59,1,1013,97,112,112,97,59,1,1008,111,116,104,105,110,103,59,1,8709,4,3,104,105,114,18728,18732,18735,105,59,1,981,59,1,982,111,112,116,111,59,1,8733,4,2,59,104,18748,18750,1,8597,111,59,1,1009,4,2,105,117,18760,18766,103,109,97,59,1,962,4,2,98,112,18772,18791,115,101,116,110,101,113,4,2,59,113,18784,18787,3,8842,65024,59,3,10955,65024,115,101,116,110,101,113,4,2,59,113,18803,18806,3,8843,65024,59,3,10956,65024,4,2,104,114,18816,18822,101,116,97,59,1,977,105,97,110,103,108,101,4,2,108,114,18834,18840,101,102,116,59,1,8882,105,103,104,116,59,1,8883,121,59,1,1074,97,115,104,59,1,8866,4,3,101,108,114,18865,18884,18890,4,3,59,98,101,18873,18875,18880,1,8744,97,114,59,1,8891,113,59,1,8794,108,105,112,59,1,8942,4,2,98,116,18896,18901,97,114,59,1,124,59,1,124,114,59,3,55349,56627,116,114,105,59,1,8882,115,117,4,2,98,112,18923,18927,59,3,8834,8402,59,3,8835,8402,112,102,59,3,55349,56679,114,111,112,59,1,8733,116,114,105,59,1,8883,4,2,99,117,18955,18960,114,59,3,55349,56523,4,2,98,112,18966,18981,110,4,2,69,101,18973,18977,59,3,10955,65024,59,3,8842,65024,110,4,2,69,101,18988,18992,59,3,10956,65024,59,3,8843,65024,105,103,122,97,103,59,1,10650,4,7,99,101,102,111,112,114,115,19020,19026,19061,19066,19072,19075,19089,105,114,99,59,1,373,4,2,100,105,19032,19055,4,2,98,103,19038,19043,97,114,59,1,10847,101,4,2,59,113,19050,19052,1,8743,59,1,8793,101,114,112,59,1,8472,114,59,3,55349,56628,112,102,59,3,55349,56680,59,1,8472,4,2,59,101,19081,19083,1,8768,97,116,104,59,1,8768,99,114,59,3,55349,56524,4,14,99,100,102,104,105,108,109,110,111,114,115,117,118,119,19125,19146,19152,19157,19173,19176,19192,19197,19202,19236,19252,19269,19286,19291,4,3,97,105,117,19133,19137,19142,112,59,1,8898,114,99,59,1,9711,112,59,1,8899,116,114,105,59,1,9661,114,59,3,55349,56629,4,2,65,97,19163,19168,114,114,59,1,10234,114,114,59,1,10231,59,1,958,4,2,65,97,19182,19187,114,114,59,1,10232,114,114,59,1,10229,97,112,59,1,10236,105,115,59,1,8955,4,3,100,112,116,19210,19215,19230,111,116,59,1,10752,4,2,102,108,19221,19225,59,3,55349,56681,117,115,59,1,10753,105,109,101,59,1,10754,4,2,65,97,19242,19247,114,114,59,1,10233,114,114,59,1,10230,4,2,99,113,19258,19263,114,59,3,55349,56525,99,117,112,59,1,10758,4,2,112,116,19275,19281,108,117,115,59,1,10756,114,105,59,1,9651,101,101,59,1,8897,101,100,103,101,59,1,8896,4,8,97,99,101,102,105,111,115,117,19316,19335,19349,19357,19362,19367,19373,19379,99,4,2,117,121,19323,19332,116,101,5,253,1,59,19330,1,253,59,1,1103,4,2,105,121,19341,19346,114,99,59,1,375,59,1,1099,110,5,165,1,59,19355,1,165,114,59,3,55349,56630,99,121,59,1,1111,112,102,59,3,55349,56682,99,114,59,3,55349,56526,4,2,99,109,19385,19389,121,59,1,1102,108,5,255,1,59,19395,1,255,4,10,97,99,100,101,102,104,105,111,115,119,19419,19426,19441,19446,19462,19467,19472,19480,19486,19492,99,117,116,101,59,1,378,4,2,97,121,19432,19438,114,111,110,59,1,382,59,1,1079,111,116,59,1,380,4,2,101,116,19452,19458,116,114,102,59,1,8488,97,59,1,950,114,59,3,55349,56631,99,121,59,1,1078,103,114,97,114,114,59,1,8669,112,102,59,3,55349,56683,99,114,59,3,55349,56527,4,2,106,110,19498,19501,59,1,8205,106,59,1,8204]);const a_e=o_e,ln=Na,Cc=i_e,ye=ck,Y=ln.CODE_POINTS,sc=ln.CODE_POINT_SEQUENCES,s_e={128:8364,130:8218,131:402,132:8222,133:8230,134:8224,135:8225,136:710,137:8240,138:352,139:8249,140:338,142:381,145:8216,146:8217,147:8220,148:8221,149:8226,150:8211,151:8212,152:732,153:8482,154:353,155:8250,156:339,158:382,159:376},dL=1<<0,hL=1<<1,pL=1<<2,l_e=dL|hL|pL,It="DATA_STATE",Yf="RCDATA_STATE",Sh="RAWTEXT_STATE",zs="SCRIPT_DATA_STATE",mL="PLAINTEXT_STATE",wA="TAG_OPEN_STATE",kA="END_TAG_OPEN_STATE",K9="TAG_NAME_STATE",SA="RCDATA_LESS_THAN_SIGN_STATE",xA="RCDATA_END_TAG_OPEN_STATE",CA="RCDATA_END_TAG_NAME_STATE",AA="RAWTEXT_LESS_THAN_SIGN_STATE",NA="RAWTEXT_END_TAG_OPEN_STATE",FA="RAWTEXT_END_TAG_NAME_STATE",IA="SCRIPT_DATA_LESS_THAN_SIGN_STATE",BA="SCRIPT_DATA_END_TAG_OPEN_STATE",RA="SCRIPT_DATA_END_TAG_NAME_STATE",OA="SCRIPT_DATA_ESCAPE_START_STATE",DA="SCRIPT_DATA_ESCAPE_START_DASH_STATE",ha="SCRIPT_DATA_ESCAPED_STATE",PA="SCRIPT_DATA_ESCAPED_DASH_STATE",V9="SCRIPT_DATA_ESCAPED_DASH_DASH_STATE",Jm="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN_STATE",MA="SCRIPT_DATA_ESCAPED_END_TAG_OPEN_STATE",LA="SCRIPT_DATA_ESCAPED_END_TAG_NAME_STATE",jA="SCRIPT_DATA_DOUBLE_ESCAPE_START_STATE",Os="SCRIPT_DATA_DOUBLE_ESCAPED_STATE",zA="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_STATE",HA="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH_STATE",eg="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN_STATE",UA="SCRIPT_DATA_DOUBLE_ESCAPE_END_STATE",Ma="BEFORE_ATTRIBUTE_NAME_STATE",tg="ATTRIBUTE_NAME_STATE",Y9="AFTER_ATTRIBUTE_NAME_STATE",Q9="BEFORE_ATTRIBUTE_VALUE_STATE",ng="ATTRIBUTE_VALUE_DOUBLE_QUOTED_STATE",rg="ATTRIBUTE_VALUE_SINGLE_QUOTED_STATE",og="ATTRIBUTE_VALUE_UNQUOTED_STATE",X9="AFTER_ATTRIBUTE_VALUE_QUOTED_STATE",Ml="SELF_CLOSING_START_TAG_STATE",ch="BOGUS_COMMENT_STATE",qA="MARKUP_DECLARATION_OPEN_STATE",$A="COMMENT_START_STATE",WA="COMMENT_START_DASH_STATE",Ll="COMMENT_STATE",GA="COMMENT_LESS_THAN_SIGN_STATE",KA="COMMENT_LESS_THAN_SIGN_BANG_STATE",VA="COMMENT_LESS_THAN_SIGN_BANG_DASH_STATE",YA="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH_STATE",ig="COMMENT_END_DASH_STATE",ag="COMMENT_END_STATE",QA="COMMENT_END_BANG_STATE",XA="DOCTYPE_STATE",sg="BEFORE_DOCTYPE_NAME_STATE",lg="DOCTYPE_NAME_STATE",ZA="AFTER_DOCTYPE_NAME_STATE",JA="AFTER_DOCTYPE_PUBLIC_KEYWORD_STATE",eN="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER_STATE",Z9="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED_STATE",J9="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED_STATE",eE="AFTER_DOCTYPE_PUBLIC_IDENTIFIER_STATE",tN="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS_STATE",nN="AFTER_DOCTYPE_SYSTEM_KEYWORD_STATE",rN="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER_STATE",fh="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED_STATE",dh="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED_STATE",tE="AFTER_DOCTYPE_SYSTEM_IDENTIFIER_STATE",Ds="BOGUS_DOCTYPE_STATE",ug="CDATA_SECTION_STATE",oN="CDATA_SECTION_BRACKET_STATE",iN="CDATA_SECTION_END_STATE",Rf="CHARACTER_REFERENCE_STATE",aN="NAMED_CHARACTER_REFERENCE_STATE",sN="AMBIGUOS_AMPERSAND_STATE",lN="NUMERIC_CHARACTER_REFERENCE_STATE",uN="HEXADEMICAL_CHARACTER_REFERENCE_START_STATE",cN="DECIMAL_CHARACTER_REFERENCE_START_STATE",fN="HEXADEMICAL_CHARACTER_REFERENCE_STATE",dN="DECIMAL_CHARACTER_REFERENCE_STATE",hh="NUMERIC_CHARACTER_REFERENCE_END_STATE";function Sn(e){return e===Y.SPACE||e===Y.LINE_FEED||e===Y.TABULATION||e===Y.FORM_FEED}function Qh(e){return e>=Y.DIGIT_0&&e<=Y.DIGIT_9}function pa(e){return e>=Y.LATIN_CAPITAL_A&&e<=Y.LATIN_CAPITAL_Z}function hc(e){return e>=Y.LATIN_SMALL_A&&e<=Y.LATIN_SMALL_Z}function ql(e){return hc(e)||pa(e)}function nE(e){return ql(e)||Qh(e)}function gL(e){return e>=Y.LATIN_CAPITAL_A&&e<=Y.LATIN_CAPITAL_F}function vL(e){return e>=Y.LATIN_SMALL_A&&e<=Y.LATIN_SMALL_F}function u_e(e){return Qh(e)||gL(e)||vL(e)}function ev(e){return e+32}function Wn(e){return e<=65535?String.fromCharCode(e):(e-=65536,String.fromCharCode(e>>>10&1023|55296)+String.fromCharCode(56320|e&1023))}function jl(e){return String.fromCharCode(ev(e))}function hN(e,t){const n=Cc[++e];let r=++e,o=r+n-1;for(;r<=o;){const i=r+o>>>1,a=Cc[i];if(a<t)r=i+1;else if(a>t)o=i-1;else return Cc[i+n]}return-1}let oa=class $o{constructor(){this.preprocessor=new a_e,this.tokenQueue=[],this.allowCDATA=!1,this.state=It,this.returnState="",this.charRefCode=-1,this.tempBuff=[],this.lastStartTagName="",this.consumedAfterSnapshot=-1,this.active=!1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr=null}_err(){}_errOnNextCodePoint(t){this._consume(),this._err(t),this._unconsume()}getNextToken(){for(;!this.tokenQueue.length&&this.active;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this[this.state](t)}return this.tokenQueue.shift()}write(t,n){this.active=!0,this.preprocessor.write(t,n)}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t)}_ensureHibernation(){if(this.preprocessor.endOfChunkHit){for(;this.consumedAfterSnapshot>0;this.consumedAfterSnapshot--)this.preprocessor.retreat();return this.active=!1,this.tokenQueue.push({type:$o.HIBERNATION_TOKEN}),!0}return!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_unconsume(){this.consumedAfterSnapshot--,this.preprocessor.retreat()}_reconsumeInState(t){this.state=t,this._unconsume()}_consumeSequenceIfMatch(t,n,r){let o=0,i=!0;const a=t.length;let s=0,l=n,u;for(;s<a;s++){if(s>0&&(l=this._consume(),o++),l===Y.EOF){i=!1;break}if(u=t[s],l!==u&&(r||l!==ev(u))){i=!1;break}}if(!i)for(;o--;)this._unconsume();return i}_isTempBufferEqualToScriptString(){if(this.tempBuff.length!==sc.SCRIPT_STRING.length)return!1;for(let t=0;t<this.tempBuff.length;t++)if(this.tempBuff[t]!==sc.SCRIPT_STRING[t])return!1;return!0}_createStartTagToken(){this.currentToken={type:$o.START_TAG_TOKEN,tagName:"",selfClosing:!1,ackSelfClosing:!1,attrs:[]}}_createEndTagToken(){this.currentToken={type:$o.END_TAG_TOKEN,tagName:"",selfClosing:!1,attrs:[]}}_createCommentToken(){this.currentToken={type:$o.COMMENT_TOKEN,data:""}}_createDoctypeToken(t){this.currentToken={type:$o.DOCTYPE_TOKEN,name:t,forceQuirks:!1,publicId:null,systemId:null}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n}}_createEOFToken(){this.currentToken={type:$o.EOF_TOKEN}}_createAttr(t){this.currentAttr={name:t,value:""}}_leaveAttrName(t){$o.getTokenAttr(this.currentToken,this.currentAttr.name)===null?this.currentToken.attrs.push(this.currentAttr):this._err(ye.duplicateAttribute),this.state=t}_leaveAttrValue(t){this.state=t}_emitCurrentToken(){this._emitCurrentCharacterToken();const t=this.currentToken;this.currentToken=null,t.type===$o.START_TAG_TOKEN?this.lastStartTagName=t.tagName:t.type===$o.END_TAG_TOKEN&&(t.attrs.length>0&&this._err(ye.endTagWithAttributes),t.selfClosing&&this._err(ye.endTagWithTrailingSolidus)),this.tokenQueue.push(t)}_emitCurrentCharacterToken(){this.currentCharacterToken&&(this.tokenQueue.push(this.currentCharacterToken),this.currentCharacterToken=null)}_emitEOFToken(){this._createEOFToken(),this._emitCurrentToken()}_appendCharToCurrentCharacterToken(t,n){this.currentCharacterToken&&this.currentCharacterToken.type!==t&&this._emitCurrentCharacterToken(),this.currentCharacterToken?this.currentCharacterToken.chars+=n:this._createCharacterToken(t,n)}_emitCodePoint(t){let n=$o.CHARACTER_TOKEN;Sn(t)?n=$o.WHITESPACE_CHARACTER_TOKEN:t===Y.NULL&&(n=$o.NULL_CHARACTER_TOKEN),this._appendCharToCurrentCharacterToken(n,Wn(t))}_emitSeveralCodePoints(t){for(let n=0;n<t.length;n++)this._emitCodePoint(t[n])}_emitChars(t){this._appendCharToCurrentCharacterToken($o.CHARACTER_TOKEN,t)}_matchNamedCharacterReference(t){let n=null,r=1,o=hN(0,t);for(this.tempBuff.push(t);o>-1;){const i=Cc[o],a=i<l_e;a&&i&dL&&(n=i&hL?[Cc[++o],Cc[++o]]:[Cc[++o]],r=0);const l=this._consume();if(this.tempBuff.push(l),r++,l===Y.EOF)break;a?o=i&pL?hN(o,l):-1:o=l===i?++o:-1}for(;r--;)this.tempBuff.pop(),this._unconsume();return n}_isCharacterReferenceInAttribute(){return this.returnState===ng||this.returnState===rg||this.returnState===og}_isCharacterReferenceAttributeQuirk(t){if(!t&&this._isCharacterReferenceInAttribute()){const n=this._consume();return this._unconsume(),n===Y.EQUALS_SIGN||nE(n)}return!1}_flushCodePointsConsumedAsCharacterReference(){if(this._isCharacterReferenceInAttribute())for(let t=0;t<this.tempBuff.length;t++)this.currentAttr.value+=Wn(this.tempBuff[t]);else this._emitSeveralCodePoints(this.tempBuff);this.tempBuff=[]}[It](t){this.preprocessor.dropParsedChunk(),t===Y.LESS_THAN_SIGN?this.state=wA:t===Y.AMPERSAND?(this.returnState=It,this.state=Rf):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitCodePoint(t)):t===Y.EOF?this._emitEOFToken():this._emitCodePoint(t)}[Yf](t){this.preprocessor.dropParsedChunk(),t===Y.AMPERSAND?(this.returnState=Yf,this.state=Rf):t===Y.LESS_THAN_SIGN?this.state=SA:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?this._emitEOFToken():this._emitCodePoint(t)}[Sh](t){this.preprocessor.dropParsedChunk(),t===Y.LESS_THAN_SIGN?this.state=AA:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?this._emitEOFToken():this._emitCodePoint(t)}[zs](t){this.preprocessor.dropParsedChunk(),t===Y.LESS_THAN_SIGN?this.state=IA:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?this._emitEOFToken():this._emitCodePoint(t)}[mL](t){this.preprocessor.dropParsedChunk(),t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?this._emitEOFToken():this._emitCodePoint(t)}[wA](t){t===Y.EXCLAMATION_MARK?this.state=qA:t===Y.SOLIDUS?this.state=kA:ql(t)?(this._createStartTagToken(),this._reconsumeInState(K9)):t===Y.QUESTION_MARK?(this._err(ye.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(),this._reconsumeInState(ch)):t===Y.EOF?(this._err(ye.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken()):(this._err(ye.invalidFirstCharacterOfTagName),this._emitChars("<"),this._reconsumeInState(It))}[kA](t){ql(t)?(this._createEndTagToken(),this._reconsumeInState(K9)):t===Y.GREATER_THAN_SIGN?(this._err(ye.missingEndTagName),this.state=It):t===Y.EOF?(this._err(ye.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken()):(this._err(ye.invalidFirstCharacterOfTagName),this._createCommentToken(),this._reconsumeInState(ch))}[K9](t){Sn(t)?this.state=Ma:t===Y.SOLIDUS?this.state=Ml:t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):pa(t)?this.currentToken.tagName+=jl(t):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.tagName+=ln.REPLACEMENT_CHARACTER):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):this.currentToken.tagName+=Wn(t)}[SA](t){t===Y.SOLIDUS?(this.tempBuff=[],this.state=xA):(this._emitChars("<"),this._reconsumeInState(Yf))}[xA](t){ql(t)?(this._createEndTagToken(),this._reconsumeInState(CA)):(this._emitChars("</"),this._reconsumeInState(Yf))}[CA](t){if(pa(t))this.currentToken.tagName+=jl(t),this.tempBuff.push(t);else if(hc(t))this.currentToken.tagName+=Wn(t),this.tempBuff.push(t);else{if(this.lastStartTagName===this.currentToken.tagName){if(Sn(t)){this.state=Ma;return}if(t===Y.SOLIDUS){this.state=Ml;return}if(t===Y.GREATER_THAN_SIGN){this.state=It,this._emitCurrentToken();return}}this._emitChars("</"),this._emitSeveralCodePoints(this.tempBuff),this._reconsumeInState(Yf)}}[AA](t){t===Y.SOLIDUS?(this.tempBuff=[],this.state=NA):(this._emitChars("<"),this._reconsumeInState(Sh))}[NA](t){ql(t)?(this._createEndTagToken(),this._reconsumeInState(FA)):(this._emitChars("</"),this._reconsumeInState(Sh))}[FA](t){if(pa(t))this.currentToken.tagName+=jl(t),this.tempBuff.push(t);else if(hc(t))this.currentToken.tagName+=Wn(t),this.tempBuff.push(t);else{if(this.lastStartTagName===this.currentToken.tagName){if(Sn(t)){this.state=Ma;return}if(t===Y.SOLIDUS){this.state=Ml;return}if(t===Y.GREATER_THAN_SIGN){this._emitCurrentToken(),this.state=It;return}}this._emitChars("</"),this._emitSeveralCodePoints(this.tempBuff),this._reconsumeInState(Sh)}}[IA](t){t===Y.SOLIDUS?(this.tempBuff=[],this.state=BA):t===Y.EXCLAMATION_MARK?(this.state=OA,this._emitChars("<!")):(this._emitChars("<"),this._reconsumeInState(zs))}[BA](t){ql(t)?(this._createEndTagToken(),this._reconsumeInState(RA)):(this._emitChars("</"),this._reconsumeInState(zs))}[RA](t){if(pa(t))this.currentToken.tagName+=jl(t),this.tempBuff.push(t);else if(hc(t))this.currentToken.tagName+=Wn(t),this.tempBuff.push(t);else{if(this.lastStartTagName===this.currentToken.tagName){if(Sn(t)){this.state=Ma;return}else if(t===Y.SOLIDUS){this.state=Ml;return}else if(t===Y.GREATER_THAN_SIGN){this._emitCurrentToken(),this.state=It;return}}this._emitChars("</"),this._emitSeveralCodePoints(this.tempBuff),this._reconsumeInState(zs)}}[OA](t){t===Y.HYPHEN_MINUS?(this.state=DA,this._emitChars("-")):this._reconsumeInState(zs)}[DA](t){t===Y.HYPHEN_MINUS?(this.state=V9,this._emitChars("-")):this._reconsumeInState(zs)}[ha](t){t===Y.HYPHEN_MINUS?(this.state=PA,this._emitChars("-")):t===Y.LESS_THAN_SIGN?this.state=Jm:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?(this._err(ye.eofInScriptHtmlCommentLikeText),this._emitEOFToken()):this._emitCodePoint(t)}[PA](t){t===Y.HYPHEN_MINUS?(this.state=V9,this._emitChars("-")):t===Y.LESS_THAN_SIGN?this.state=Jm:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.state=ha,this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?(this._err(ye.eofInScriptHtmlCommentLikeText),this._emitEOFToken()):(this.state=ha,this._emitCodePoint(t))}[V9](t){t===Y.HYPHEN_MINUS?this._emitChars("-"):t===Y.LESS_THAN_SIGN?this.state=Jm:t===Y.GREATER_THAN_SIGN?(this.state=zs,this._emitChars(">")):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.state=ha,this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?(this._err(ye.eofInScriptHtmlCommentLikeText),this._emitEOFToken()):(this.state=ha,this._emitCodePoint(t))}[Jm](t){t===Y.SOLIDUS?(this.tempBuff=[],this.state=MA):ql(t)?(this.tempBuff=[],this._emitChars("<"),this._reconsumeInState(jA)):(this._emitChars("<"),this._reconsumeInState(ha))}[MA](t){ql(t)?(this._createEndTagToken(),this._reconsumeInState(LA)):(this._emitChars("</"),this._reconsumeInState(ha))}[LA](t){if(pa(t))this.currentToken.tagName+=jl(t),this.tempBuff.push(t);else if(hc(t))this.currentToken.tagName+=Wn(t),this.tempBuff.push(t);else{if(this.lastStartTagName===this.currentToken.tagName){if(Sn(t)){this.state=Ma;return}if(t===Y.SOLIDUS){this.state=Ml;return}if(t===Y.GREATER_THAN_SIGN){this._emitCurrentToken(),this.state=It;return}}this._emitChars("</"),this._emitSeveralCodePoints(this.tempBuff),this._reconsumeInState(ha)}}[jA](t){Sn(t)||t===Y.SOLIDUS||t===Y.GREATER_THAN_SIGN?(this.state=this._isTempBufferEqualToScriptString()?Os:ha,this._emitCodePoint(t)):pa(t)?(this.tempBuff.push(ev(t)),this._emitCodePoint(t)):hc(t)?(this.tempBuff.push(t),this._emitCodePoint(t)):this._reconsumeInState(ha)}[Os](t){t===Y.HYPHEN_MINUS?(this.state=zA,this._emitChars("-")):t===Y.LESS_THAN_SIGN?(this.state=eg,this._emitChars("<")):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?(this._err(ye.eofInScriptHtmlCommentLikeText),this._emitEOFToken()):this._emitCodePoint(t)}[zA](t){t===Y.HYPHEN_MINUS?(this.state=HA,this._emitChars("-")):t===Y.LESS_THAN_SIGN?(this.state=eg,this._emitChars("<")):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.state=Os,this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?(this._err(ye.eofInScriptHtmlCommentLikeText),this._emitEOFToken()):(this.state=Os,this._emitCodePoint(t))}[HA](t){t===Y.HYPHEN_MINUS?this._emitChars("-"):t===Y.LESS_THAN_SIGN?(this.state=eg,this._emitChars("<")):t===Y.GREATER_THAN_SIGN?(this.state=zs,this._emitChars(">")):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.state=Os,this._emitChars(ln.REPLACEMENT_CHARACTER)):t===Y.EOF?(this._err(ye.eofInScriptHtmlCommentLikeText),this._emitEOFToken()):(this.state=Os,this._emitCodePoint(t))}[eg](t){t===Y.SOLIDUS?(this.tempBuff=[],this.state=UA,this._emitChars("/")):this._reconsumeInState(Os)}[UA](t){Sn(t)||t===Y.SOLIDUS||t===Y.GREATER_THAN_SIGN?(this.state=this._isTempBufferEqualToScriptString()?ha:Os,this._emitCodePoint(t)):pa(t)?(this.tempBuff.push(ev(t)),this._emitCodePoint(t)):hc(t)?(this.tempBuff.push(t),this._emitCodePoint(t)):this._reconsumeInState(Os)}[Ma](t){Sn(t)||(t===Y.SOLIDUS||t===Y.GREATER_THAN_SIGN||t===Y.EOF?this._reconsumeInState(Y9):t===Y.EQUALS_SIGN?(this._err(ye.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=tg):(this._createAttr(""),this._reconsumeInState(tg)))}[tg](t){Sn(t)||t===Y.SOLIDUS||t===Y.GREATER_THAN_SIGN||t===Y.EOF?(this._leaveAttrName(Y9),this._unconsume()):t===Y.EQUALS_SIGN?this._leaveAttrName(Q9):pa(t)?this.currentAttr.name+=jl(t):t===Y.QUOTATION_MARK||t===Y.APOSTROPHE||t===Y.LESS_THAN_SIGN?(this._err(ye.unexpectedCharacterInAttributeName),this.currentAttr.name+=Wn(t)):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentAttr.name+=ln.REPLACEMENT_CHARACTER):this.currentAttr.name+=Wn(t)}[Y9](t){Sn(t)||(t===Y.SOLIDUS?this.state=Ml:t===Y.EQUALS_SIGN?this.state=Q9:t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):(this._createAttr(""),this._reconsumeInState(tg)))}[Q9](t){Sn(t)||(t===Y.QUOTATION_MARK?this.state=ng:t===Y.APOSTROPHE?this.state=rg:t===Y.GREATER_THAN_SIGN?(this._err(ye.missingAttributeValue),this.state=It,this._emitCurrentToken()):this._reconsumeInState(og))}[ng](t){t===Y.QUOTATION_MARK?this.state=X9:t===Y.AMPERSAND?(this.returnState=ng,this.state=Rf):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentAttr.value+=ln.REPLACEMENT_CHARACTER):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):this.currentAttr.value+=Wn(t)}[rg](t){t===Y.APOSTROPHE?this.state=X9:t===Y.AMPERSAND?(this.returnState=rg,this.state=Rf):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentAttr.value+=ln.REPLACEMENT_CHARACTER):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):this.currentAttr.value+=Wn(t)}[og](t){Sn(t)?this._leaveAttrValue(Ma):t===Y.AMPERSAND?(this.returnState=og,this.state=Rf):t===Y.GREATER_THAN_SIGN?(this._leaveAttrValue(It),this._emitCurrentToken()):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentAttr.value+=ln.REPLACEMENT_CHARACTER):t===Y.QUOTATION_MARK||t===Y.APOSTROPHE||t===Y.LESS_THAN_SIGN||t===Y.EQUALS_SIGN||t===Y.GRAVE_ACCENT?(this._err(ye.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=Wn(t)):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):this.currentAttr.value+=Wn(t)}[X9](t){Sn(t)?this._leaveAttrValue(Ma):t===Y.SOLIDUS?this._leaveAttrValue(Ml):t===Y.GREATER_THAN_SIGN?(this._leaveAttrValue(It),this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):(this._err(ye.missingWhitespaceBetweenAttributes),this._reconsumeInState(Ma))}[Ml](t){t===Y.GREATER_THAN_SIGN?(this.currentToken.selfClosing=!0,this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInTag),this._emitEOFToken()):(this._err(ye.unexpectedSolidusInTag),this._reconsumeInState(Ma))}[ch](t){t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._emitCurrentToken(),this._emitEOFToken()):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.data+=ln.REPLACEMENT_CHARACTER):this.currentToken.data+=Wn(t)}[qA](t){this._consumeSequenceIfMatch(sc.DASH_DASH_STRING,t,!0)?(this._createCommentToken(),this.state=$A):this._consumeSequenceIfMatch(sc.DOCTYPE_STRING,t,!1)?this.state=XA:this._consumeSequenceIfMatch(sc.CDATA_START_STRING,t,!0)?this.allowCDATA?this.state=ug:(this._err(ye.cdataInHtmlContent),this._createCommentToken(),this.currentToken.data="[CDATA[",this.state=ch):this._ensureHibernation()||(this._err(ye.incorrectlyOpenedComment),this._createCommentToken(),this._reconsumeInState(ch))}[$A](t){t===Y.HYPHEN_MINUS?this.state=WA:t===Y.GREATER_THAN_SIGN?(this._err(ye.abruptClosingOfEmptyComment),this.state=It,this._emitCurrentToken()):this._reconsumeInState(Ll)}[WA](t){t===Y.HYPHEN_MINUS?this.state=ag:t===Y.GREATER_THAN_SIGN?(this._err(ye.abruptClosingOfEmptyComment),this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInComment),this._emitCurrentToken(),this._emitEOFToken()):(this.currentToken.data+="-",this._reconsumeInState(Ll))}[Ll](t){t===Y.HYPHEN_MINUS?this.state=ig:t===Y.LESS_THAN_SIGN?(this.currentToken.data+="<",this.state=GA):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.data+=ln.REPLACEMENT_CHARACTER):t===Y.EOF?(this._err(ye.eofInComment),this._emitCurrentToken(),this._emitEOFToken()):this.currentToken.data+=Wn(t)}[GA](t){t===Y.EXCLAMATION_MARK?(this.currentToken.data+="!",this.state=KA):t===Y.LESS_THAN_SIGN?this.currentToken.data+="!":this._reconsumeInState(Ll)}[KA](t){t===Y.HYPHEN_MINUS?this.state=VA:this._reconsumeInState(Ll)}[VA](t){t===Y.HYPHEN_MINUS?this.state=YA:this._reconsumeInState(ig)}[YA](t){t!==Y.GREATER_THAN_SIGN&&t!==Y.EOF&&this._err(ye.nestedComment),this._reconsumeInState(ag)}[ig](t){t===Y.HYPHEN_MINUS?this.state=ag:t===Y.EOF?(this._err(ye.eofInComment),this._emitCurrentToken(),this._emitEOFToken()):(this.currentToken.data+="-",this._reconsumeInState(Ll))}[ag](t){t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):t===Y.EXCLAMATION_MARK?this.state=QA:t===Y.HYPHEN_MINUS?this.currentToken.data+="-":t===Y.EOF?(this._err(ye.eofInComment),this._emitCurrentToken(),this._emitEOFToken()):(this.currentToken.data+="--",this._reconsumeInState(Ll))}[QA](t){t===Y.HYPHEN_MINUS?(this.currentToken.data+="--!",this.state=ig):t===Y.GREATER_THAN_SIGN?(this._err(ye.incorrectlyClosedComment),this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInComment),this._emitCurrentToken(),this._emitEOFToken()):(this.currentToken.data+="--!",this._reconsumeInState(Ll))}[XA](t){Sn(t)?this.state=sg:t===Y.GREATER_THAN_SIGN?this._reconsumeInState(sg):t===Y.EOF?(this._err(ye.eofInDoctype),this._createDoctypeToken(null),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingWhitespaceBeforeDoctypeName),this._reconsumeInState(sg))}[sg](t){Sn(t)||(pa(t)?(this._createDoctypeToken(jl(t)),this.state=lg):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this._createDoctypeToken(ln.REPLACEMENT_CHARACTER),this.state=lg):t===Y.GREATER_THAN_SIGN?(this._err(ye.missingDoctypeName),this._createDoctypeToken(null),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this.state=It):t===Y.EOF?(this._err(ye.eofInDoctype),this._createDoctypeToken(null),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._createDoctypeToken(Wn(t)),this.state=lg))}[lg](t){Sn(t)?this.state=ZA:t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):pa(t)?this.currentToken.name+=jl(t):t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.name+=ln.REPLACEMENT_CHARACTER):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):this.currentToken.name+=Wn(t)}[ZA](t){Sn(t)||(t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):this._consumeSequenceIfMatch(sc.PUBLIC_STRING,t,!1)?this.state=JA:this._consumeSequenceIfMatch(sc.SYSTEM_STRING,t,!1)?this.state=nN:this._ensureHibernation()||(this._err(ye.invalidCharacterSequenceAfterDoctypeName),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds)))}[JA](t){Sn(t)?this.state=eN:t===Y.QUOTATION_MARK?(this._err(ye.missingWhitespaceAfterDoctypePublicKeyword),this.currentToken.publicId="",this.state=Z9):t===Y.APOSTROPHE?(this._err(ye.missingWhitespaceAfterDoctypePublicKeyword),this.currentToken.publicId="",this.state=J9):t===Y.GREATER_THAN_SIGN?(this._err(ye.missingDoctypePublicIdentifier),this.currentToken.forceQuirks=!0,this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingQuoteBeforeDoctypePublicIdentifier),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds))}[eN](t){Sn(t)||(t===Y.QUOTATION_MARK?(this.currentToken.publicId="",this.state=Z9):t===Y.APOSTROPHE?(this.currentToken.publicId="",this.state=J9):t===Y.GREATER_THAN_SIGN?(this._err(ye.missingDoctypePublicIdentifier),this.currentToken.forceQuirks=!0,this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingQuoteBeforeDoctypePublicIdentifier),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds)))}[Z9](t){t===Y.QUOTATION_MARK?this.state=eE:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.publicId+=ln.REPLACEMENT_CHARACTER):t===Y.GREATER_THAN_SIGN?(this._err(ye.abruptDoctypePublicIdentifier),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this.state=It):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):this.currentToken.publicId+=Wn(t)}[J9](t){t===Y.APOSTROPHE?this.state=eE:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.publicId+=ln.REPLACEMENT_CHARACTER):t===Y.GREATER_THAN_SIGN?(this._err(ye.abruptDoctypePublicIdentifier),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this.state=It):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):this.currentToken.publicId+=Wn(t)}[eE](t){Sn(t)?this.state=tN:t===Y.GREATER_THAN_SIGN?(this.state=It,this._emitCurrentToken()):t===Y.QUOTATION_MARK?(this._err(ye.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),this.currentToken.systemId="",this.state=fh):t===Y.APOSTROPHE?(this._err(ye.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),this.currentToken.systemId="",this.state=dh):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingQuoteBeforeDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds))}[tN](t){Sn(t)||(t===Y.GREATER_THAN_SIGN?(this._emitCurrentToken(),this.state=It):t===Y.QUOTATION_MARK?(this.currentToken.systemId="",this.state=fh):t===Y.APOSTROPHE?(this.currentToken.systemId="",this.state=dh):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingQuoteBeforeDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds)))}[nN](t){Sn(t)?this.state=rN:t===Y.QUOTATION_MARK?(this._err(ye.missingWhitespaceAfterDoctypeSystemKeyword),this.currentToken.systemId="",this.state=fh):t===Y.APOSTROPHE?(this._err(ye.missingWhitespaceAfterDoctypeSystemKeyword),this.currentToken.systemId="",this.state=dh):t===Y.GREATER_THAN_SIGN?(this._err(ye.missingDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingQuoteBeforeDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds))}[rN](t){Sn(t)||(t===Y.QUOTATION_MARK?(this.currentToken.systemId="",this.state=fh):t===Y.APOSTROPHE?(this.currentToken.systemId="",this.state=dh):t===Y.GREATER_THAN_SIGN?(this._err(ye.missingDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this.state=It,this._emitCurrentToken()):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.missingQuoteBeforeDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this._reconsumeInState(Ds)))}[fh](t){t===Y.QUOTATION_MARK?this.state=tE:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.systemId+=ln.REPLACEMENT_CHARACTER):t===Y.GREATER_THAN_SIGN?(this._err(ye.abruptDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this.state=It):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):this.currentToken.systemId+=Wn(t)}[dh](t){t===Y.APOSTROPHE?this.state=tE:t===Y.NULL?(this._err(ye.unexpectedNullCharacter),this.currentToken.systemId+=ln.REPLACEMENT_CHARACTER):t===Y.GREATER_THAN_SIGN?(this._err(ye.abruptDoctypeSystemIdentifier),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this.state=It):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):this.currentToken.systemId+=Wn(t)}[tE](t){Sn(t)||(t===Y.GREATER_THAN_SIGN?(this._emitCurrentToken(),this.state=It):t===Y.EOF?(this._err(ye.eofInDoctype),this.currentToken.forceQuirks=!0,this._emitCurrentToken(),this._emitEOFToken()):(this._err(ye.unexpectedCharacterAfterDoctypeSystemIdentifier),this._reconsumeInState(Ds)))}[Ds](t){t===Y.GREATER_THAN_SIGN?(this._emitCurrentToken(),this.state=It):t===Y.NULL?this._err(ye.unexpectedNullCharacter):t===Y.EOF&&(this._emitCurrentToken(),this._emitEOFToken())}[ug](t){t===Y.RIGHT_SQUARE_BRACKET?this.state=oN:t===Y.EOF?(this._err(ye.eofInCdata),this._emitEOFToken()):this._emitCodePoint(t)}[oN](t){t===Y.RIGHT_SQUARE_BRACKET?this.state=iN:(this._emitChars("]"),this._reconsumeInState(ug))}[iN](t){t===Y.GREATER_THAN_SIGN?this.state=It:t===Y.RIGHT_SQUARE_BRACKET?this._emitChars("]"):(this._emitChars("]]"),this._reconsumeInState(ug))}[Rf](t){this.tempBuff=[Y.AMPERSAND],t===Y.NUMBER_SIGN?(this.tempBuff.push(t),this.state=lN):nE(t)?this._reconsumeInState(aN):(this._flushCodePointsConsumedAsCharacterReference(),this._reconsumeInState(this.returnState))}[aN](t){const n=this._matchNamedCharacterReference(t);if(this._ensureHibernation())this.tempBuff=[Y.AMPERSAND];else if(n){const r=this.tempBuff[this.tempBuff.length-1]===Y.SEMICOLON;this._isCharacterReferenceAttributeQuirk(r)||(r||this._errOnNextCodePoint(ye.missingSemicolonAfterCharacterReference),this.tempBuff=n),this._flushCodePointsConsumedAsCharacterReference(),this.state=this.returnState}else this._flushCodePointsConsumedAsCharacterReference(),this.state=sN}[sN](t){nE(t)?this._isCharacterReferenceInAttribute()?this.currentAttr.value+=Wn(t):this._emitCodePoint(t):(t===Y.SEMICOLON&&this._err(ye.unknownNamedCharacterReference),this._reconsumeInState(this.returnState))}[lN](t){this.charRefCode=0,t===Y.LATIN_SMALL_X||t===Y.LATIN_CAPITAL_X?(this.tempBuff.push(t),this.state=uN):this._reconsumeInState(cN)}[uN](t){u_e(t)?this._reconsumeInState(fN):(this._err(ye.absenceOfDigitsInNumericCharacterReference),this._flushCodePointsConsumedAsCharacterReference(),this._reconsumeInState(this.returnState))}[cN](t){Qh(t)?this._reconsumeInState(dN):(this._err(ye.absenceOfDigitsInNumericCharacterReference),this._flushCodePointsConsumedAsCharacterReference(),this._reconsumeInState(this.returnState))}[fN](t){gL(t)?this.charRefCode=this.charRefCode*16+t-55:vL(t)?this.charRefCode=this.charRefCode*16+t-87:Qh(t)?this.charRefCode=this.charRefCode*16+t-48:t===Y.SEMICOLON?this.state=hh:(this._err(ye.missingSemicolonAfterCharacterReference),this._reconsumeInState(hh))}[dN](t){Qh(t)?this.charRefCode=this.charRefCode*10+t-48:t===Y.SEMICOLON?this.state=hh:(this._err(ye.missingSemicolonAfterCharacterReference),this._reconsumeInState(hh))}[hh](){if(this.charRefCode===Y.NULL)this._err(ye.nullCharacterReference),this.charRefCode=Y.REPLACEMENT_CHARACTER;else if(this.charRefCode>1114111)this._err(ye.characterReferenceOutsideUnicodeRange),this.charRefCode=Y.REPLACEMENT_CHARACTER;else if(ln.isSurrogate(this.charRefCode))this._err(ye.surrogateCharacterReference),this.charRefCode=Y.REPLACEMENT_CHARACTER;else if(ln.isUndefinedCodePoint(this.charRefCode))this._err(ye.noncharacterCharacterReference);else if(ln.isControlCodePoint(this.charRefCode)||this.charRefCode===Y.CARRIAGE_RETURN){this._err(ye.controlCharacterReference);const t=s_e[this.charRefCode];t&&(this.charRefCode=t)}this.tempBuff=[this.charRefCode],this._flushCodePointsConsumedAsCharacterReference(),this._reconsumeInState(this.returnState)}};oa.CHARACTER_TOKEN="CHARACTER_TOKEN";oa.NULL_CHARACTER_TOKEN="NULL_CHARACTER_TOKEN";oa.WHITESPACE_CHARACTER_TOKEN="WHITESPACE_CHARACTER_TOKEN";oa.START_TAG_TOKEN="START_TAG_TOKEN";oa.END_TAG_TOKEN="END_TAG_TOKEN";oa.COMMENT_TOKEN="COMMENT_TOKEN";oa.DOCTYPE_TOKEN="DOCTYPE_TOKEN";oa.EOF_TOKEN="EOF_TOKEN";oa.HIBERNATION_TOKEN="HIBERNATION_TOKEN";oa.MODE={DATA:It,RCDATA:Yf,RAWTEXT:Sh,SCRIPT_DATA:zs,PLAINTEXT:mL};oa.getTokenAttr=function(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null};var Oy=oa,Fa={};const rE=Fa.NAMESPACES={HTML:"http://www.w3.org/1999/xhtml",MATHML:"http://www.w3.org/1998/Math/MathML",SVG:"http://www.w3.org/2000/svg",XLINK:"http://www.w3.org/1999/xlink",XML:"http://www.w3.org/XML/1998/namespace",XMLNS:"http://www.w3.org/2000/xmlns/"};Fa.ATTRS={TYPE:"type",ACTION:"action",ENCODING:"encoding",PROMPT:"prompt",NAME:"name",COLOR:"color",FACE:"face",SIZE:"size"};Fa.DOCUMENT_MODE={NO_QUIRKS:"no-quirks",QUIRKS:"quirks",LIMITED_QUIRKS:"limited-quirks"};const Ne=Fa.TAG_NAMES={A:"a",ADDRESS:"address",ANNOTATION_XML:"annotation-xml",APPLET:"applet",AREA:"area",ARTICLE:"article",ASIDE:"aside",B:"b",BASE:"base",BASEFONT:"basefont",BGSOUND:"bgsound",BIG:"big",BLOCKQUOTE:"blockquote",BODY:"body",BR:"br",BUTTON:"button",CAPTION:"caption",CENTER:"center",CODE:"code",COL:"col",COLGROUP:"colgroup",DD:"dd",DESC:"desc",DETAILS:"details",DIALOG:"dialog",DIR:"dir",DIV:"div",DL:"dl",DT:"dt",EM:"em",EMBED:"embed",FIELDSET:"fieldset",FIGCAPTION:"figcaption",FIGURE:"figure",FONT:"font",FOOTER:"footer",FOREIGN_OBJECT:"foreignObject",FORM:"form",FRAME:"frame",FRAMESET:"frameset",H1:"h1",H2:"h2",H3:"h3",H4:"h4",H5:"h5",H6:"h6",HEAD:"head",HEADER:"header",HGROUP:"hgroup",HR:"hr",HTML:"html",I:"i",IMG:"img",IMAGE:"image",INPUT:"input",IFRAME:"iframe",KEYGEN:"keygen",LABEL:"label",LI:"li",LINK:"link",LISTING:"listing",MAIN:"main",MALIGNMARK:"malignmark",MARQUEE:"marquee",MATH:"math",MENU:"menu",META:"meta",MGLYPH:"mglyph",MI:"mi",MO:"mo",MN:"mn",MS:"ms",MTEXT:"mtext",NAV:"nav",NOBR:"nobr",NOFRAMES:"noframes",NOEMBED:"noembed",NOSCRIPT:"noscript",OBJECT:"object",OL:"ol",OPTGROUP:"optgroup",OPTION:"option",P:"p",PARAM:"param",PLAINTEXT:"plaintext",PRE:"pre",RB:"rb",RP:"rp",RT:"rt",RTC:"rtc",RUBY:"ruby",S:"s",SCRIPT:"script",SECTION:"section",SELECT:"select",SOURCE:"source",SMALL:"small",SPAN:"span",STRIKE:"strike",STRONG:"strong",STYLE:"style",SUB:"sub",SUMMARY:"summary",SUP:"sup",TABLE:"table",TBODY:"tbody",TEMPLATE:"template",TEXTAREA:"textarea",TFOOT:"tfoot",TD:"td",TH:"th",THEAD:"thead",TITLE:"title",TR:"tr",TRACK:"track",TT:"tt",U:"u",UL:"ul",SVG:"svg",VAR:"var",WBR:"wbr",XMP:"xmp"};Fa.SPECIAL_ELEMENTS={[rE.HTML]:{[Ne.ADDRESS]:!0,[Ne.APPLET]:!0,[Ne.AREA]:!0,[Ne.ARTICLE]:!0,[Ne.ASIDE]:!0,[Ne.BASE]:!0,[Ne.BASEFONT]:!0,[Ne.BGSOUND]:!0,[Ne.BLOCKQUOTE]:!0,[Ne.BODY]:!0,[Ne.BR]:!0,[Ne.BUTTON]:!0,[Ne.CAPTION]:!0,[Ne.CENTER]:!0,[Ne.COL]:!0,[Ne.COLGROUP]:!0,[Ne.DD]:!0,[Ne.DETAILS]:!0,[Ne.DIR]:!0,[Ne.DIV]:!0,[Ne.DL]:!0,[Ne.DT]:!0,[Ne.EMBED]:!0,[Ne.FIELDSET]:!0,[Ne.FIGCAPTION]:!0,[Ne.FIGURE]:!0,[Ne.FOOTER]:!0,[Ne.FORM]:!0,[Ne.FRAME]:!0,[Ne.FRAMESET]:!0,[Ne.H1]:!0,[Ne.H2]:!0,[Ne.H3]:!0,[Ne.H4]:!0,[Ne.H5]:!0,[Ne.H6]:!0,[Ne.HEAD]:!0,[Ne.HEADER]:!0,[Ne.HGROUP]:!0,[Ne.HR]:!0,[Ne.HTML]:!0,[Ne.IFRAME]:!0,[Ne.IMG]:!0,[Ne.INPUT]:!0,[Ne.LI]:!0,[Ne.LINK]:!0,[Ne.LISTING]:!0,[Ne.MAIN]:!0,[Ne.MARQUEE]:!0,[Ne.MENU]:!0,[Ne.META]:!0,[Ne.NAV]:!0,[Ne.NOEMBED]:!0,[Ne.NOFRAMES]:!0,[Ne.NOSCRIPT]:!0,[Ne.OBJECT]:!0,[Ne.OL]:!0,[Ne.P]:!0,[Ne.PARAM]:!0,[Ne.PLAINTEXT]:!0,[Ne.PRE]:!0,[Ne.SCRIPT]:!0,[Ne.SECTION]:!0,[Ne.SELECT]:!0,[Ne.SOURCE]:!0,[Ne.STYLE]:!0,[Ne.SUMMARY]:!0,[Ne.TABLE]:!0,[Ne.TBODY]:!0,[Ne.TD]:!0,[Ne.TEMPLATE]:!0,[Ne.TEXTAREA]:!0,[Ne.TFOOT]:!0,[Ne.TH]:!0,[Ne.THEAD]:!0,[Ne.TITLE]:!0,[Ne.TR]:!0,[Ne.TRACK]:!0,[Ne.UL]:!0,[Ne.WBR]:!0,[Ne.XMP]:!0},[rE.MATHML]:{[Ne.MI]:!0,[Ne.MO]:!0,[Ne.MN]:!0,[Ne.MS]:!0,[Ne.MTEXT]:!0,[Ne.ANNOTATION_XML]:!0},[rE.SVG]:{[Ne.TITLE]:!0,[Ne.FOREIGN_OBJECT]:!0,[Ne.DESC]:!0}};const bL=Fa,Fe=bL.TAG_NAMES,un=bL.NAMESPACES;function pN(e){switch(e.length){case 1:return e===Fe.P;case 2:return e===Fe.RB||e===Fe.RP||e===Fe.RT||e===Fe.DD||e===Fe.DT||e===Fe.LI;case 3:return e===Fe.RTC;case 6:return e===Fe.OPTION;case 8:return e===Fe.OPTGROUP}return!1}function c_e(e){switch(e.length){case 1:return e===Fe.P;case 2:return e===Fe.RB||e===Fe.RP||e===Fe.RT||e===Fe.DD||e===Fe.DT||e===Fe.LI||e===Fe.TD||e===Fe.TH||e===Fe.TR;case 3:return e===Fe.RTC;case 5:return e===Fe.TBODY||e===Fe.TFOOT||e===Fe.THEAD;case 6:return e===Fe.OPTION;case 7:return e===Fe.CAPTION;case 8:return e===Fe.OPTGROUP||e===Fe.COLGROUP}return!1}function cg(e,t){switch(e.length){case 2:if(e===Fe.TD||e===Fe.TH)return t===un.HTML;if(e===Fe.MI||e===Fe.MO||e===Fe.MN||e===Fe.MS)return t===un.MATHML;break;case 4:if(e===Fe.HTML)return t===un.HTML;if(e===Fe.DESC)return t===un.SVG;break;case 5:if(e===Fe.TABLE)return t===un.HTML;if(e===Fe.MTEXT)return t===un.MATHML;if(e===Fe.TITLE)return t===un.SVG;break;case 6:return(e===Fe.APPLET||e===Fe.OBJECT)&&t===un.HTML;case 7:return(e===Fe.CAPTION||e===Fe.MARQUEE)&&t===un.HTML;case 8:return e===Fe.TEMPLATE&&t===un.HTML;case 13:return e===Fe.FOREIGN_OBJECT&&t===un.SVG;case 14:return e===Fe.ANNOTATION_XML&&t===un.MATHML}return!1}let f_e=class{constructor(t,n){this.stackTop=-1,this.items=[],this.current=t,this.currentTagName=null,this.currentTmplContent=null,this.tmplCount=0,this.treeAdapter=n}_indexOf(t){let n=-1;for(let r=this.stackTop;r>=0;r--)if(this.items[r]===t){n=r;break}return n}_isInTemplate(){return this.currentTagName===Fe.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===un.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagName=this.current&&this.treeAdapter.getTagName(this.current),this.currentTmplContent=this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):null}push(t){this.items[++this.stackTop]=t,this._updateCurrentElement(),this._isInTemplate()&&this.tmplCount++}pop(){this.stackTop--,this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this._updateCurrentElement()}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&this._updateCurrentElement()}insertAfter(t,n){const r=this._indexOf(t)+1;this.items.splice(r,0,n),r===++this.stackTop&&this._updateCurrentElement()}popUntilTagNamePopped(t){for(;this.stackTop>-1;){const n=this.currentTagName,r=this.treeAdapter.getNamespaceURI(this.current);if(this.pop(),n===t&&r===un.HTML)break}}popUntilElementPopped(t){for(;this.stackTop>-1;){const n=this.current;if(this.pop(),n===t)break}}popUntilNumberedHeaderPopped(){for(;this.stackTop>-1;){const t=this.currentTagName,n=this.treeAdapter.getNamespaceURI(this.current);if(this.pop(),t===Fe.H1||t===Fe.H2||t===Fe.H3||t===Fe.H4||t===Fe.H5||t===Fe.H6&&n===un.HTML)break}}popUntilTableCellPopped(){for(;this.stackTop>-1;){const t=this.currentTagName,n=this.treeAdapter.getNamespaceURI(this.current);if(this.pop(),t===Fe.TD||t===Fe.TH&&n===un.HTML)break}}popAllUpToHtmlElement(){this.stackTop=0,this._updateCurrentElement()}clearBackToTableContext(){for(;this.currentTagName!==Fe.TABLE&&this.currentTagName!==Fe.TEMPLATE&&this.currentTagName!==Fe.HTML||this.treeAdapter.getNamespaceURI(this.current)!==un.HTML;)this.pop()}clearBackToTableBodyContext(){for(;this.currentTagName!==Fe.TBODY&&this.currentTagName!==Fe.TFOOT&&this.currentTagName!==Fe.THEAD&&this.currentTagName!==Fe.TEMPLATE&&this.currentTagName!==Fe.HTML||this.treeAdapter.getNamespaceURI(this.current)!==un.HTML;)this.pop()}clearBackToTableRowContext(){for(;this.currentTagName!==Fe.TR&&this.currentTagName!==Fe.TEMPLATE&&this.currentTagName!==Fe.HTML||this.treeAdapter.getNamespaceURI(this.current)!==un.HTML;)this.pop()}remove(t){for(let n=this.stackTop;n>=0;n--)if(this.items[n]===t){this.items.splice(n,1),this.stackTop--,this._updateCurrentElement();break}}tryPeekProperlyNestedBodyElement(){const t=this.items[1];return t&&this.treeAdapter.getTagName(t)===Fe.BODY?t:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){let n=this._indexOf(t);return--n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.currentTagName===Fe.HTML}hasInScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.treeAdapter.getTagName(this.items[n]),o=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&o===un.HTML)return!0;if(cg(r,o))return!1}return!0}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.treeAdapter.getTagName(this.items[t]),r=this.treeAdapter.getNamespaceURI(this.items[t]);if((n===Fe.H1||n===Fe.H2||n===Fe.H3||n===Fe.H4||n===Fe.H5||n===Fe.H6)&&r===un.HTML)return!0;if(cg(n,r))return!1}return!0}hasInListItemScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.treeAdapter.getTagName(this.items[n]),o=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&o===un.HTML)return!0;if((r===Fe.UL||r===Fe.OL)&&o===un.HTML||cg(r,o))return!1}return!0}hasInButtonScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.treeAdapter.getTagName(this.items[n]),o=this.treeAdapter.getNamespaceURI(this.items[n]);if(r===t&&o===un.HTML)return!0;if(r===Fe.BUTTON&&o===un.HTML||cg(r,o))return!1}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.treeAdapter.getTagName(this.items[n]);if(this.treeAdapter.getNamespaceURI(this.items[n])===un.HTML){if(r===t)return!0;if(r===Fe.TABLE||r===Fe.TEMPLATE||r===Fe.HTML)return!1}}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--){const n=this.treeAdapter.getTagName(this.items[t]);if(this.treeAdapter.getNamespaceURI(this.items[t])===un.HTML){if(n===Fe.TBODY||n===Fe.THEAD||n===Fe.TFOOT)return!0;if(n===Fe.TABLE||n===Fe.HTML)return!1}}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--){const r=this.treeAdapter.getTagName(this.items[n]);if(this.treeAdapter.getNamespaceURI(this.items[n])===un.HTML){if(r===t)return!0;if(r!==Fe.OPTION&&r!==Fe.OPTGROUP)return!1}}return!0}generateImpliedEndTags(){for(;pN(this.currentTagName);)this.pop()}generateImpliedEndTagsThoroughly(){for(;c_e(this.currentTagName);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;pN(this.currentTagName)&&this.currentTagName!==t;)this.pop()}};var d_e=f_e;const fg=3;let fk=class $l{constructor(t){this.length=0,this.entries=[],this.treeAdapter=t,this.bookmark=null}_getNoahArkConditionCandidates(t){const n=[];if(this.length>=fg){const r=this.treeAdapter.getAttrList(t).length,o=this.treeAdapter.getTagName(t),i=this.treeAdapter.getNamespaceURI(t);for(let a=this.length-1;a>=0;a--){const s=this.entries[a];if(s.type===$l.MARKER_ENTRY)break;const l=s.element,u=this.treeAdapter.getAttrList(l);this.treeAdapter.getTagName(l)===o&&this.treeAdapter.getNamespaceURI(l)===i&&u.length===r&&n.push({idx:a,attrs:u})}}return n.length<fg?[]:n}_ensureNoahArkCondition(t){const n=this._getNoahArkConditionCandidates(t);let r=n.length;if(r){const o=this.treeAdapter.getAttrList(t),i=o.length,a=Object.create(null);for(let s=0;s<i;s++){const l=o[s];a[l.name]=l.value}for(let s=0;s<i;s++)for(let l=0;l<r;l++){const u=n[l].attrs[s];if(a[u.name]!==u.value&&(n.splice(l,1),r--),n.length<fg)return}for(let s=r-1;s>=fg-1;s--)this.entries.splice(n[s].idx,1),this.length--}}insertMarker(){this.entries.push({type:$l.MARKER_ENTRY}),this.length++}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.push({type:$l.ELEMENT_ENTRY,element:t,token:n}),this.length++}insertElementAfterBookmark(t,n){let r=this.length-1;for(;r>=0&&this.entries[r]!==this.bookmark;r--);this.entries.splice(r+1,0,{type:$l.ELEMENT_ENTRY,element:t,token:n}),this.length++}removeEntry(t){for(let n=this.length-1;n>=0;n--)if(this.entries[n]===t){this.entries.splice(n,1),this.length--;break}}clearToLastMarker(){for(;this.length;){const t=this.entries.pop();if(this.length--,t.type===$l.MARKER_ENTRY)break}}getElementEntryInScopeWithTagName(t){for(let n=this.length-1;n>=0;n--){const r=this.entries[n];if(r.type===$l.MARKER_ENTRY)return null;if(this.treeAdapter.getTagName(r.element)===t)return r}return null}getElementEntry(t){for(let n=this.length-1;n>=0;n--){const r=this.entries[n];if(r.type===$l.ELEMENT_ENTRY&&r.element===t)return r}return null}};fk.MARKER_ENTRY="MARKER_ENTRY";fk.ELEMENT_ENTRY="ELEMENT_ENTRY";var h_e=fk;let yL=class{constructor(t){const n={},r=this._getOverriddenMethods(this,n);for(const o of Object.keys(r))typeof r[o]=="function"&&(n[o]=t[o],t[o]=r[o])}_getOverriddenMethods(){throw new Error("Not implemented")}};yL.install=function(e,t,n){e.__mixins||(e.__mixins=[]);for(let o=0;o<e.__mixins.length;o++)if(e.__mixins[o].constructor===t)return e.__mixins[o];const r=new t(e,n);return e.__mixins.push(r),r};var Tl=yL;const p_e=Tl;let m_e=class extends p_e{constructor(t){super(t),this.preprocessor=t,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.offset=0,this.col=0,this.line=1}_getOverriddenMethods(t,n){return{advance(){const r=this.pos+1,o=this.html[r];return t.isEol&&(t.isEol=!1,t.line++,t.lineStartPos=r),(o===` `||o==="\r"&&this.html[r+1]!==` `)&&(t.isEol=!0),t.col=r-t.lineStartPos+1,t.offset=t.droppedBufferSize+r,n.advance.call(this)},retreat(){n.retreat.call(this),t.isEol=!1,t.col=this.pos-t.lineStartPos+1},dropParsedChunk(){const r=this.pos;n.dropParsedChunk.call(this);const o=r-this.pos;t.lineStartPos-=o,t.droppedBufferSize+=o,t.offset=t.droppedBufferSize+this.pos}}}};var EL=m_e;const mN=Tl,oE=Oy,g_e=EL;let v_e=class extends mN{constructor(t){super(t),this.tokenizer=t,this.posTracker=mN.install(t.preprocessor,g_e),this.currentAttrLocation=null,this.ctLoc=null}_getCurrentLocation(){return{startLine:this.posTracker.line,startCol:this.posTracker.col,startOffset:this.posTracker.offset,endLine:-1,endCol:-1,endOffset:-1}}_attachCurrentAttrLocationInfo(){this.currentAttrLocation.endLine=this.posTracker.line,this.currentAttrLocation.endCol=this.posTracker.col,this.currentAttrLocation.endOffset=this.posTracker.offset;const t=this.tokenizer.currentToken,n=this.tokenizer.currentAttr;t.location.attrs||(t.location.attrs=Object.create(null)),t.location.attrs[n.name]=this.currentAttrLocation}_getOverriddenMethods(t,n){const r={_createStartTagToken(){n._createStartTagToken.call(this),this.currentToken.location=t.ctLoc},_createEndTagToken(){n._createEndTagToken.call(this),this.currentToken.location=t.ctLoc},_createCommentToken(){n._createCommentToken.call(this),this.currentToken.location=t.ctLoc},_createDoctypeToken(o){n._createDoctypeToken.call(this,o),this.currentToken.location=t.ctLoc},_createCharacterToken(o,i){n._createCharacterToken.call(this,o,i),this.currentCharacterToken.location=t.ctLoc},_createEOFToken(){n._createEOFToken.call(this),this.currentToken.location=t._getCurrentLocation()},_createAttr(o){n._createAttr.call(this,o),t.currentAttrLocation=t._getCurrentLocation()},_leaveAttrName(o){n._leaveAttrName.call(this,o),t._attachCurrentAttrLocationInfo()},_leaveAttrValue(o){n._leaveAttrValue.call(this,o),t._attachCurrentAttrLocationInfo()},_emitCurrentToken(){const o=this.currentToken.location;this.currentCharacterToken&&(this.currentCharacterToken.location.endLine=o.startLine,this.currentCharacterToken.location.endCol=o.startCol,this.currentCharacterToken.location.endOffset=o.startOffset),this.currentToken.type===oE.EOF_TOKEN?(o.endLine=o.startLine,o.endCol=o.startCol,o.endOffset=o.startOffset):(o.endLine=t.posTracker.line,o.endCol=t.posTracker.col+1,o.endOffset=t.posTracker.offset+1),n._emitCurrentToken.call(this)},_emitCurrentCharacterToken(){const o=this.currentCharacterToken&&this.currentCharacterToken.location;o&&o.endOffset===-1&&(o.endLine=t.posTracker.line,o.endCol=t.posTracker.col,o.endOffset=t.posTracker.offset),n._emitCurrentCharacterToken.call(this)}};return Object.keys(oE.MODE).forEach(o=>{const i=oE.MODE[o];r[i]=function(a){t.ctLoc=t._getCurrentLocation(),n[i].call(this,a)}}),r}};var _L=v_e;const b_e=Tl;let y_e=class extends b_e{constructor(t,n){super(t),this.onItemPop=n.onItemPop}_getOverriddenMethods(t,n){return{pop(){t.onItemPop(this.current),n.pop.call(this)},popAllUpToHtmlElement(){for(let r=this.stackTop;r>0;r--)t.onItemPop(this.items[r]);n.popAllUpToHtmlElement.call(this)},remove(r){t.onItemPop(this.current),n.remove.call(this,r)}}}};var E_e=y_e;const iE=Tl,gN=Oy,T_e=_L,w_e=E_e,k_e=Fa,aE=k_e.TAG_NAMES;let S_e=class extends iE{constructor(t){super(t),this.parser=t,this.treeAdapter=this.parser.treeAdapter,this.posTracker=null,this.lastStartTagToken=null,this.lastFosterParentingLocation=null,this.currentToken=null}_setStartLocation(t){let n=null;this.lastStartTagToken&&(n=Object.assign({},this.lastStartTagToken.location),n.startTag=this.lastStartTagToken.location),this.treeAdapter.setNodeSourceCodeLocation(t,n)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const o=n.location,i=this.treeAdapter.getTagName(t),a=n.type===gN.END_TAG_TOKEN&&i===n.tagName,s={};a?(s.endTag=Object.assign({},o),s.endLine=o.endLine,s.endCol=o.endCol,s.endOffset=o.endOffset):(s.endLine=o.startLine,s.endCol=o.startCol,s.endOffset=o.startOffset),this.treeAdapter.updateNodeSourceCodeLocation(t,s)}}_getOverriddenMethods(t,n){return{_bootstrap(r,o){n._bootstrap.call(this,r,o),t.lastStartTagToken=null,t.lastFosterParentingLocation=null,t.currentToken=null;const i=iE.install(this.tokenizer,T_e);t.posTracker=i.posTracker,iE.install(this.openElements,w_e,{onItemPop:function(a){t._setEndLocation(a,t.currentToken)}})},_runParsingLoop(r){n._runParsingLoop.call(this,r);for(let o=this.openElements.stackTop;o>=0;o--)t._setEndLocation(this.openElements.items[o],t.currentToken)},_processTokenInForeignContent(r){t.currentToken=r,n._processTokenInForeignContent.call(this,r)},_processToken(r){if(t.currentToken=r,n._processToken.call(this,r),r.type===gN.END_TAG_TOKEN&&(r.tagName===aE.HTML||r.tagName===aE.BODY&&this.openElements.hasInScope(aE.BODY)))for(let i=this.openElements.stackTop;i>=0;i--){const a=this.openElements.items[i];if(this.treeAdapter.getTagName(a)===r.tagName){t._setEndLocation(a,r);break}}},_setDocumentType(r){n._setDocumentType.call(this,r);const o=this.treeAdapter.getChildNodes(this.document),i=o.length;for(let a=0;a<i;a++){const s=o[a];if(this.treeAdapter.isDocumentTypeNode(s)){this.treeAdapter.setNodeSourceCodeLocation(s,r.location);break}}},_attachElementToTree(r){t._setStartLocation(r),t.lastStartTagToken=null,n._attachElementToTree.call(this,r)},_appendElement(r,o){t.lastStartTagToken=r,n._appendElement.call(this,r,o)},_insertElement(r,o){t.lastStartTagToken=r,n._insertElement.call(this,r,o)},_insertTemplate(r){t.lastStartTagToken=r,n._insertTemplate.call(this,r);const o=this.treeAdapter.getTemplateContent(this.openElements.current);this.treeAdapter.setNodeSourceCodeLocation(o,null)},_insertFakeRootElement(){n._insertFakeRootElement.call(this),this.treeAdapter.setNodeSourceCodeLocation(this.openElements.current,null)},_appendCommentNode(r,o){n._appendCommentNode.call(this,r,o);const i=this.treeAdapter.getChildNodes(o),a=i[i.length-1];this.treeAdapter.setNodeSourceCodeLocation(a,r.location)},_findFosterParentingLocation(){return t.lastFosterParentingLocation=n._findFosterParentingLocation.call(this),t.lastFosterParentingLocation},_insertCharacters(r){n._insertCharacters.call(this,r);const o=this._shouldFosterParentOnInsertion(),i=o&&t.lastFosterParentingLocation.parent||this.openElements.currentTmplContent||this.openElements.current,a=this.treeAdapter.getChildNodes(i),s=o&&t.lastFosterParentingLocation.beforeElement?a.indexOf(t.lastFosterParentingLocation.beforeElement)-1:a.length-1,l=a[s];if(this.treeAdapter.getNodeSourceCodeLocation(l)){const{endLine:d,endCol:h,endOffset:p}=r.location;this.treeAdapter.updateNodeSourceCodeLocation(l,{endLine:d,endCol:h,endOffset:p})}else this.treeAdapter.setNodeSourceCodeLocation(l,r.location)}}}};var x_e=S_e;const C_e=Tl;let A_e=class extends C_e{constructor(t,n){super(t),this.posTracker=null,this.onParseError=n.onParseError}_setErrorLocation(t){t.startLine=t.endLine=this.posTracker.line,t.startCol=t.endCol=this.posTracker.col,t.startOffset=t.endOffset=this.posTracker.offset}_reportError(t){const n={code:t,startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1};this._setErrorLocation(n),this.onParseError(n)}_getOverriddenMethods(t){return{_err(n){t._reportError(n)}}}};var dk=A_e;const N_e=dk,F_e=EL,I_e=Tl;let B_e=class extends N_e{constructor(t,n){super(t,n),this.posTracker=I_e.install(t,F_e),this.lastErrOffset=-1}_reportError(t){this.lastErrOffset!==this.posTracker.offset&&(this.lastErrOffset=this.posTracker.offset,super._reportError(t))}};var R_e=B_e;const O_e=dk,D_e=R_e,P_e=Tl;let M_e=class extends O_e{constructor(t,n){super(t,n);const r=P_e.install(t.preprocessor,D_e,n);this.posTracker=r.posTracker}};var L_e=M_e;const j_e=dk,z_e=L_e,H_e=_L,vN=Tl;let U_e=class extends j_e{constructor(t,n){super(t,n),this.opts=n,this.ctLoc=null,this.locBeforeToken=!1}_setErrorLocation(t){this.ctLoc&&(t.startLine=this.ctLoc.startLine,t.startCol=this.ctLoc.startCol,t.startOffset=this.ctLoc.startOffset,t.endLine=this.locBeforeToken?this.ctLoc.startLine:this.ctLoc.endLine,t.endCol=this.locBeforeToken?this.ctLoc.startCol:this.ctLoc.endCol,t.endOffset=this.locBeforeToken?this.ctLoc.startOffset:this.ctLoc.endOffset)}_getOverriddenMethods(t,n){return{_bootstrap(r,o){n._bootstrap.call(this,r,o),vN.install(this.tokenizer,z_e,t.opts),vN.install(this.tokenizer,H_e)},_processInputToken(r){t.ctLoc=r.location,n._processInputToken.call(this,r)},_err(r,o){t.locBeforeToken=o&&o.beforeToken,t._reportError(r)}}}};var q_e=U_e,zt={};const{DOCUMENT_MODE:$_e}=Fa;zt.createDocument=function(){return{nodeName:"#document",mode:$_e.NO_QUIRKS,childNodes:[]}};zt.createDocumentFragment=function(){return{nodeName:"#document-fragment",childNodes:[]}};zt.createElement=function(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}};zt.createCommentNode=function(e){return{nodeName:"#comment",data:e,parentNode:null}};const TL=function(e){return{nodeName:"#text",value:e,parentNode:null}},wL=zt.appendChild=function(e,t){e.childNodes.push(t),t.parentNode=e},W_e=zt.insertBefore=function(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e};zt.setTemplateContent=function(e,t){e.content=t};zt.getTemplateContent=function(e){return e.content};zt.setDocumentType=function(e,t,n,r){let o=null;for(let i=0;i<e.childNodes.length;i++)if(e.childNodes[i].nodeName==="#documentType"){o=e.childNodes[i];break}o?(o.name=t,o.publicId=n,o.systemId=r):wL(e,{nodeName:"#documentType",name:t,publicId:n,systemId:r})};zt.setDocumentMode=function(e,t){e.mode=t};zt.getDocumentMode=function(e){return e.mode};zt.detachNode=function(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}};zt.insertText=function(e,t){if(e.childNodes.length){const n=e.childNodes[e.childNodes.length-1];if(n.nodeName==="#text"){n.value+=t;return}}wL(e,TL(t))};zt.insertTextBefore=function(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&r.nodeName==="#text"?r.value+=t:W_e(e,TL(t),n)};zt.adoptAttributes=function(e,t){const n=[];for(let r=0;r<e.attrs.length;r++)n.push(e.attrs[r].name);for(let r=0;r<t.length;r++)n.indexOf(t[r].name)===-1&&e.attrs.push(t[r])};zt.getFirstChild=function(e){return e.childNodes[0]};zt.getChildNodes=function(e){return e.childNodes};zt.getParentNode=function(e){return e.parentNode};zt.getAttrList=function(e){return e.attrs};zt.getTagName=function(e){return e.tagName};zt.getNamespaceURI=function(e){return e.namespaceURI};zt.getTextNodeContent=function(e){return e.value};zt.getCommentNodeContent=function(e){return e.data};zt.getDocumentTypeNodeName=function(e){return e.name};zt.getDocumentTypeNodePublicId=function(e){return e.publicId};zt.getDocumentTypeNodeSystemId=function(e){return e.systemId};zt.isTextNode=function(e){return e.nodeName==="#text"};zt.isCommentNode=function(e){return e.nodeName==="#comment"};zt.isDocumentTypeNode=function(e){return e.nodeName==="#documentType"};zt.isElementNode=function(e){return!!e.tagName};zt.setNodeSourceCodeLocation=function(e,t){e.sourceCodeLocation=t};zt.getNodeSourceCodeLocation=function(e){return e.sourceCodeLocation};zt.updateNodeSourceCodeLocation=function(e,t){e.sourceCodeLocation=Object.assign(e.sourceCodeLocation,t)};var G_e=function(t,n){return n=n||Object.create(null),[t,n].reduce((r,o)=>(Object.keys(o).forEach(i=>{r[i]=o[i]}),r),Object.create(null))},Dy={};const{DOCUMENT_MODE:Of}=Fa,kL="html",K_e="about:legacy-compat",V_e="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",SL=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],Y_e=SL.concat(["-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"]),Q_e=["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"],xL=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],X_e=xL.concat(["-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"]);function bN(e){const t=e.indexOf('"')!==-1?"'":'"';return t+e+t}function yN(e,t){for(let n=0;n<t.length;n++)if(e.indexOf(t[n])===0)return!0;return!1}Dy.isConforming=function(e){return e.name===kL&&e.publicId===null&&(e.systemId===null||e.systemId===K_e)};Dy.getDocumentMode=function(e){if(e.name!==kL)return Of.QUIRKS;const t=e.systemId;if(t&&t.toLowerCase()===V_e)return Of.QUIRKS;let n=e.publicId;if(n!==null){if(n=n.toLowerCase(),Q_e.indexOf(n)>-1)return Of.QUIRKS;let r=t===null?Y_e:SL;if(yN(n,r))return Of.QUIRKS;if(r=t===null?xL:X_e,yN(n,r))return Of.LIMITED_QUIRKS}return Of.NO_QUIRKS};Dy.serializeContent=function(e,t,n){let r="!DOCTYPE ";return e&&(r+=e),t?r+=" PUBLIC "+bN(t):n&&(r+=" SYSTEM"),n!==null&&(r+=" "+bN(n)),r};var Lu={};const sE=Oy,hk=Fa,Ye=hk.TAG_NAMES,Wr=hk.NAMESPACES,tv=hk.ATTRS,EN={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},Z_e="definitionurl",J_e="definitionURL",e4e={attributename:"attributeName",attributetype:"attributeType",basefrequency:"baseFrequency",baseprofile:"baseProfile",calcmode:"calcMode",clippathunits:"clipPathUnits",diffuseconstant:"diffuseConstant",edgemode:"edgeMode",filterunits:"filterUnits",glyphref:"glyphRef",gradienttransform:"gradientTransform",gradientunits:"gradientUnits",kernelmatrix:"kernelMatrix",kernelunitlength:"kernelUnitLength",keypoints:"keyPoints",keysplines:"keySplines",keytimes:"keyTimes",lengthadjust:"lengthAdjust",limitingconeangle:"limitingConeAngle",markerheight:"markerHeight",markerunits:"markerUnits",markerwidth:"markerWidth",maskcontentunits:"maskContentUnits",maskunits:"maskUnits",numoctaves:"numOctaves",pathlength:"pathLength",patterncontentunits:"patternContentUnits",patterntransform:"patternTransform",patternunits:"patternUnits",pointsatx:"pointsAtX",pointsaty:"pointsAtY",pointsatz:"pointsAtZ",preservealpha:"preserveAlpha",preserveaspectratio:"preserveAspectRatio",primitiveunits:"primitiveUnits",refx:"refX",refy:"refY",repeatcount:"repeatCount",repeatdur:"repeatDur",requiredextensions:"requiredExtensions",requiredfeatures:"requiredFeatures",specularconstant:"specularConstant",specularexponent:"specularExponent",spreadmethod:"spreadMethod",startoffset:"startOffset",stddeviation:"stdDeviation",stitchtiles:"stitchTiles",surfacescale:"surfaceScale",systemlanguage:"systemLanguage",tablevalues:"tableValues",targetx:"targetX",targety:"targetY",textlength:"textLength",viewbox:"viewBox",viewtarget:"viewTarget",xchannelselector:"xChannelSelector",ychannelselector:"yChannelSelector",zoomandpan:"zoomAndPan"},t4e={"xlink:actuate":{prefix:"xlink",name:"actuate",namespace:Wr.XLINK},"xlink:arcrole":{prefix:"xlink",name:"arcrole",namespace:Wr.XLINK},"xlink:href":{prefix:"xlink",name:"href",namespace:Wr.XLINK},"xlink:role":{prefix:"xlink",name:"role",namespace:Wr.XLINK},"xlink:show":{prefix:"xlink",name:"show",namespace:Wr.XLINK},"xlink:title":{prefix:"xlink",name:"title",namespace:Wr.XLINK},"xlink:type":{prefix:"xlink",name:"type",namespace:Wr.XLINK},"xml:base":{prefix:"xml",name:"base",namespace:Wr.XML},"xml:lang":{prefix:"xml",name:"lang",namespace:Wr.XML},"xml:space":{prefix:"xml",name:"space",namespace:Wr.XML},xmlns:{prefix:"",name:"xmlns",namespace:Wr.XMLNS},"xmlns:xlink":{prefix:"xmlns",name:"xlink",namespace:Wr.XMLNS}},n4e=Lu.SVG_TAG_NAMES_ADJUSTMENT_MAP={altglyph:"altGlyph",altglyphdef:"altGlyphDef",altglyphitem:"altGlyphItem",animatecolor:"animateColor",animatemotion:"animateMotion",animatetransform:"animateTransform",clippath:"clipPath",feblend:"feBlend",fecolormatrix:"feColorMatrix",fecomponenttransfer:"feComponentTransfer",fecomposite:"feComposite",feconvolvematrix:"feConvolveMatrix",fediffuselighting:"feDiffuseLighting",fedisplacementmap:"feDisplacementMap",fedistantlight:"feDistantLight",feflood:"feFlood",fefunca:"feFuncA",fefuncb:"feFuncB",fefuncg:"feFuncG",fefuncr:"feFuncR",fegaussianblur:"feGaussianBlur",feimage:"feImage",femerge:"feMerge",femergenode:"feMergeNode",femorphology:"feMorphology",feoffset:"feOffset",fepointlight:"fePointLight",fespecularlighting:"feSpecularLighting",fespotlight:"feSpotLight",fetile:"feTile",feturbulence:"feTurbulence",foreignobject:"foreignObject",glyphref:"glyphRef",lineargradient:"linearGradient",radialgradient:"radialGradient",textpath:"textPath"},r4e={[Ye.B]:!0,[Ye.BIG]:!0,[Ye.BLOCKQUOTE]:!0,[Ye.BODY]:!0,[Ye.BR]:!0,[Ye.CENTER]:!0,[Ye.CODE]:!0,[Ye.DD]:!0,[Ye.DIV]:!0,[Ye.DL]:!0,[Ye.DT]:!0,[Ye.EM]:!0,[Ye.EMBED]:!0,[Ye.H1]:!0,[Ye.H2]:!0,[Ye.H3]:!0,[Ye.H4]:!0,[Ye.H5]:!0,[Ye.H6]:!0,[Ye.HEAD]:!0,[Ye.HR]:!0,[Ye.I]:!0,[Ye.IMG]:!0,[Ye.LI]:!0,[Ye.LISTING]:!0,[Ye.MENU]:!0,[Ye.META]:!0,[Ye.NOBR]:!0,[Ye.OL]:!0,[Ye.P]:!0,[Ye.PRE]:!0,[Ye.RUBY]:!0,[Ye.S]:!0,[Ye.SMALL]:!0,[Ye.SPAN]:!0,[Ye.STRONG]:!0,[Ye.STRIKE]:!0,[Ye.SUB]:!0,[Ye.SUP]:!0,[Ye.TABLE]:!0,[Ye.TT]:!0,[Ye.U]:!0,[Ye.UL]:!0,[Ye.VAR]:!0};Lu.causesExit=function(e){const t=e.tagName;return t===Ye.FONT&&(sE.getTokenAttr(e,tv.COLOR)!==null||sE.getTokenAttr(e,tv.SIZE)!==null||sE.getTokenAttr(e,tv.FACE)!==null)?!0:r4e[t]};Lu.adjustTokenMathMLAttrs=function(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Z_e){e.attrs[t].name=J_e;break}};Lu.adjustTokenSVGAttrs=function(e){for(let t=0;t<e.attrs.length;t++){const n=e4e[e.attrs[t].name];n&&(e.attrs[t].name=n)}};Lu.adjustTokenXMLAttrs=function(e){for(let t=0;t<e.attrs.length;t++){const n=t4e[e.attrs[t].name];n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}};Lu.adjustTokenSVGTagName=function(e){const t=n4e[e.tagName];t&&(e.tagName=t)};function o4e(e,t){return t===Wr.MATHML&&(e===Ye.MI||e===Ye.MO||e===Ye.MN||e===Ye.MS||e===Ye.MTEXT)}function i4e(e,t,n){if(t===Wr.MATHML&&e===Ye.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===tv.ENCODING){const o=n[r].value.toLowerCase();return o===EN.TEXT_HTML||o===EN.APPLICATION_XML}}return t===Wr.SVG&&(e===Ye.FOREIGN_OBJECT||e===Ye.DESC||e===Ye.TITLE)}Lu.isIntegrationPoint=function(e,t,n,r){return!!((!r||r===Wr.HTML)&&i4e(e,t,n)||(!r||r===Wr.MATHML)&&o4e(e,t))};const X=Oy,a4e=d_e,_N=h_e,s4e=x_e,l4e=q_e,TN=Tl,u4e=zt,c4e=G_e,wN=Dy,Ya=Lu,Xr=ck,f4e=Na,Yc=Fa,x=Yc.TAG_NAMES,ze=Yc.NAMESPACES,CL=Yc.ATTRS,d4e={scriptingEnabled:!0,sourceCodeLocationInfo:!1,onParseError:null,treeAdapter:u4e},AL="hidden",h4e=8,p4e=3,NL="INITIAL_MODE",pk="BEFORE_HTML_MODE",Py="BEFORE_HEAD_MODE",b1="IN_HEAD_MODE",FL="IN_HEAD_NO_SCRIPT_MODE",My="AFTER_HEAD_MODE",as="IN_BODY_MODE",hb="TEXT_MODE",uo="IN_TABLE_MODE",IL="IN_TABLE_TEXT_MODE",Ly="IN_CAPTION_MODE",Fp="IN_COLUMN_GROUP_MODE",Vi="IN_TABLE_BODY_MODE",dl="IN_ROW_MODE",jy="IN_CELL_MODE",mk="IN_SELECT_MODE",gk="IN_SELECT_IN_TABLE_MODE",pb="IN_TEMPLATE_MODE",vk="AFTER_BODY_MODE",zy="IN_FRAMESET_MODE",BL="AFTER_FRAMESET_MODE",RL="AFTER_AFTER_BODY_MODE",OL="AFTER_AFTER_FRAMESET_MODE",m4e={[x.TR]:dl,[x.TBODY]:Vi,[x.THEAD]:Vi,[x.TFOOT]:Vi,[x.CAPTION]:Ly,[x.COLGROUP]:Fp,[x.TABLE]:uo,[x.BODY]:as,[x.FRAMESET]:zy},g4e={[x.CAPTION]:uo,[x.COLGROUP]:uo,[x.TBODY]:uo,[x.TFOOT]:uo,[x.THEAD]:uo,[x.COL]:Fp,[x.TR]:Vi,[x.TD]:dl,[x.TH]:dl},kN={[NL]:{[X.CHARACTER_TOKEN]:mh,[X.NULL_CHARACTER_TOKEN]:mh,[X.WHITESPACE_CHARACTER_TOKEN]:Dt,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:x4e,[X.START_TAG_TOKEN]:mh,[X.END_TAG_TOKEN]:mh,[X.EOF_TOKEN]:mh},[pk]:{[X.CHARACTER_TOKEN]:Xh,[X.NULL_CHARACTER_TOKEN]:Xh,[X.WHITESPACE_CHARACTER_TOKEN]:Dt,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:C4e,[X.END_TAG_TOKEN]:A4e,[X.EOF_TOKEN]:Xh},[Py]:{[X.CHARACTER_TOKEN]:Zh,[X.NULL_CHARACTER_TOKEN]:Zh,[X.WHITESPACE_CHARACTER_TOKEN]:Dt,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:dg,[X.START_TAG_TOKEN]:N4e,[X.END_TAG_TOKEN]:F4e,[X.EOF_TOKEN]:Zh},[b1]:{[X.CHARACTER_TOKEN]:Jh,[X.NULL_CHARACTER_TOKEN]:Jh,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:dg,[X.START_TAG_TOKEN]:Pr,[X.END_TAG_TOKEN]:Qc,[X.EOF_TOKEN]:Jh},[FL]:{[X.CHARACTER_TOKEN]:e0,[X.NULL_CHARACTER_TOKEN]:e0,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:dg,[X.START_TAG_TOKEN]:I4e,[X.END_TAG_TOKEN]:B4e,[X.EOF_TOKEN]:e0},[My]:{[X.CHARACTER_TOKEN]:t0,[X.NULL_CHARACTER_TOKEN]:t0,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:dg,[X.START_TAG_TOKEN]:R4e,[X.END_TAG_TOKEN]:O4e,[X.EOF_TOKEN]:t0},[as]:{[X.CHARACTER_TOKEN]:hg,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:ni,[X.END_TAG_TOKEN]:bk,[X.EOF_TOKEN]:Ms},[hb]:{[X.CHARACTER_TOKEN]:Wo,[X.NULL_CHARACTER_TOKEN]:Wo,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Dt,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:Dt,[X.END_TAG_TOKEN]:fTe,[X.EOF_TOKEN]:dTe},[uo]:{[X.CHARACTER_TOKEN]:Ls,[X.NULL_CHARACTER_TOKEN]:Ls,[X.WHITESPACE_CHARACTER_TOKEN]:Ls,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:yk,[X.END_TAG_TOKEN]:Ek,[X.EOF_TOKEN]:Ms},[IL]:{[X.CHARACTER_TOKEN]:TTe,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:_Te,[X.COMMENT_TOKEN]:gh,[X.DOCTYPE_TOKEN]:gh,[X.START_TAG_TOKEN]:gh,[X.END_TAG_TOKEN]:gh,[X.EOF_TOKEN]:gh},[Ly]:{[X.CHARACTER_TOKEN]:hg,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:wTe,[X.END_TAG_TOKEN]:kTe,[X.EOF_TOKEN]:Ms},[Fp]:{[X.CHARACTER_TOKEN]:mb,[X.NULL_CHARACTER_TOKEN]:mb,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:STe,[X.END_TAG_TOKEN]:xTe,[X.EOF_TOKEN]:Ms},[Vi]:{[X.CHARACTER_TOKEN]:Ls,[X.NULL_CHARACTER_TOKEN]:Ls,[X.WHITESPACE_CHARACTER_TOKEN]:Ls,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:CTe,[X.END_TAG_TOKEN]:ATe,[X.EOF_TOKEN]:Ms},[dl]:{[X.CHARACTER_TOKEN]:Ls,[X.NULL_CHARACTER_TOKEN]:Ls,[X.WHITESPACE_CHARACTER_TOKEN]:Ls,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:NTe,[X.END_TAG_TOKEN]:FTe,[X.EOF_TOKEN]:Ms},[jy]:{[X.CHARACTER_TOKEN]:hg,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:ITe,[X.END_TAG_TOKEN]:BTe,[X.EOF_TOKEN]:Ms},[mk]:{[X.CHARACTER_TOKEN]:Wo,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:DL,[X.END_TAG_TOKEN]:PL,[X.EOF_TOKEN]:Ms},[gk]:{[X.CHARACTER_TOKEN]:Wo,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:RTe,[X.END_TAG_TOKEN]:OTe,[X.EOF_TOKEN]:Ms},[pb]:{[X.CHARACTER_TOKEN]:hg,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:DTe,[X.END_TAG_TOKEN]:PTe,[X.EOF_TOKEN]:ML},[vk]:{[X.CHARACTER_TOKEN]:gb,[X.NULL_CHARACTER_TOKEN]:gb,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:S4e,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:MTe,[X.END_TAG_TOKEN]:LTe,[X.EOF_TOKEN]:ph},[zy]:{[X.CHARACTER_TOKEN]:Dt,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:jTe,[X.END_TAG_TOKEN]:zTe,[X.EOF_TOKEN]:ph},[BL]:{[X.CHARACTER_TOKEN]:Dt,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:Wo,[X.COMMENT_TOKEN]:Tr,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:HTe,[X.END_TAG_TOKEN]:UTe,[X.EOF_TOKEN]:ph},[RL]:{[X.CHARACTER_TOKEN]:nv,[X.NULL_CHARACTER_TOKEN]:nv,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:SN,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:qTe,[X.END_TAG_TOKEN]:nv,[X.EOF_TOKEN]:ph},[OL]:{[X.CHARACTER_TOKEN]:Dt,[X.NULL_CHARACTER_TOKEN]:Dt,[X.WHITESPACE_CHARACTER_TOKEN]:lc,[X.COMMENT_TOKEN]:SN,[X.DOCTYPE_TOKEN]:Dt,[X.START_TAG_TOKEN]:$Te,[X.END_TAG_TOKEN]:Dt,[X.EOF_TOKEN]:ph}};class v4e{constructor(t){this.options=c4e(d4e,t),this.treeAdapter=this.options.treeAdapter,this.pendingScript=null,this.options.sourceCodeLocationInfo&&TN.install(this,s4e),this.options.onParseError&&TN.install(this,l4e,{onParseError:this.options.onParseError})}parse(t){const n=this.treeAdapter.createDocument();return this._bootstrap(n,null),this.tokenizer.write(t,!0),this._runParsingLoop(null),n}parseFragment(t,n){n||(n=this.treeAdapter.createElement(x.TEMPLATE,ze.HTML,[]));const r=this.treeAdapter.createElement("documentmock",ze.HTML,[]);this._bootstrap(r,n),this.treeAdapter.getTagName(n)===x.TEMPLATE&&this._pushTmplInsertionMode(pb),this._initTokenizerForFragmentParsing(),this._insertFakeRootElement(),this._resetInsertionMode(),this._findFormInFragmentContext(),this.tokenizer.write(t,!0),this._runParsingLoop(null);const o=this.treeAdapter.getFirstChild(r),i=this.treeAdapter.createDocumentFragment();return this._adoptNodes(o,i),i}_bootstrap(t,n){this.tokenizer=new X(this.options),this.stopped=!1,this.insertionMode=NL,this.originalInsertionMode="",this.document=t,this.fragmentContext=n,this.headElement=null,this.formElement=null,this.openElements=new a4e(this.document,this.treeAdapter),this.activeFormattingElements=new _N(this.treeAdapter),this.tmplInsertionModeStack=[],this.tmplInsertionModeStackTop=-1,this.currentTmplInsertionMode=null,this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1}_err(){}_runParsingLoop(t){for(;!this.stopped;){this._setupTokenizerCDATAMode();const n=this.tokenizer.getNextToken();if(n.type===X.HIBERNATION_TOKEN)break;if(this.skipNextNewLine&&(this.skipNextNewLine=!1,n.type===X.WHITESPACE_CHARACTER_TOKEN&&n.chars[0]===` `)){if(n.chars.length===1)continue;n.chars=n.chars.substr(1)}if(this._processInputToken(n),t&&this.pendingScript)break}}runParsingLoopForCurrentChunk(t,n){if(this._runParsingLoop(n),n&&this.pendingScript){const r=this.pendingScript;this.pendingScript=null,n(r);return}t&&t()}_setupTokenizerCDATAMode(){const t=this._getAdjustedCurrentElement();this.tokenizer.allowCDATA=t&&t!==this.document&&this.treeAdapter.getNamespaceURI(t)!==ze.HTML&&!this._isIntegrationPoint(t)}_switchToTextParsing(t,n){this._insertElement(t,ze.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=hb}switchToPlaintextParsing(){this.insertionMode=hb,this.originalInsertionMode=as,this.tokenizer.state=X.MODE.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;do{if(this.treeAdapter.getTagName(t)===x.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}while(t)}_initTokenizerForFragmentParsing(){if(this.treeAdapter.getNamespaceURI(this.fragmentContext)===ze.HTML){const t=this.treeAdapter.getTagName(this.fragmentContext);t===x.TITLE||t===x.TEXTAREA?this.tokenizer.state=X.MODE.RCDATA:t===x.STYLE||t===x.XMP||t===x.IFRAME||t===x.NOEMBED||t===x.NOFRAMES||t===x.NOSCRIPT?this.tokenizer.state=X.MODE.RAWTEXT:t===x.SCRIPT?this.tokenizer.state=X.MODE.SCRIPT_DATA:t===x.PLAINTEXT&&(this.tokenizer.state=X.MODE.PLAINTEXT)}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",o=t.systemId||"";this.treeAdapter.setDocumentType(this.document,n,r,o)}_attachElementToTree(t){if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const n=this.openElements.currentTmplContent||this.openElements.current;this.treeAdapter.appendChild(n,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r),this.openElements.push(r)}_insertFakeElement(t){const n=this.treeAdapter.createElement(t,ze.HTML,[]);this._attachElementToTree(n),this.openElements.push(n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,ze.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n),this.openElements.push(n)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(x.HTML,ze.HTML,[]);this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r)}_insertCharacters(t){if(this._shouldFosterParentOnInsertion())this._fosterParentText(t.chars);else{const n=this.openElements.currentTmplContent||this.openElements.current;this.treeAdapter.insertText(n,t.chars)}}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_shouldProcessTokenInForeignContent(t){const n=this._getAdjustedCurrentElement();if(!n||n===this.document)return!1;const r=this.treeAdapter.getNamespaceURI(n);if(r===ze.HTML||this.treeAdapter.getTagName(n)===x.ANNOTATION_XML&&r===ze.MATHML&&t.type===X.START_TAG_TOKEN&&t.tagName===x.SVG)return!1;const o=t.type===X.CHARACTER_TOKEN||t.type===X.NULL_CHARACTER_TOKEN||t.type===X.WHITESPACE_CHARACTER_TOKEN;return(t.type===X.START_TAG_TOKEN&&t.tagName!==x.MGLYPH&&t.tagName!==x.MALIGNMARK||o)&&this._isIntegrationPoint(n,ze.MATHML)||(t.type===X.START_TAG_TOKEN||o)&&this._isIntegrationPoint(n,ze.HTML)?!1:t.type!==X.EOF_TOKEN}_processToken(t){kN[this.insertionMode][t.type](this,t)}_processTokenInBodyMode(t){kN[as][t.type](this,t)}_processTokenInForeignContent(t){t.type===X.CHARACTER_TOKEN?GTe(this,t):t.type===X.NULL_CHARACTER_TOKEN?WTe(this,t):t.type===X.WHITESPACE_CHARACTER_TOKEN?Wo(this,t):t.type===X.COMMENT_TOKEN?Tr(this,t):t.type===X.START_TAG_TOKEN?KTe(this,t):t.type===X.END_TAG_TOKEN&&VTe(this,t)}_processInputToken(t){this._shouldProcessTokenInForeignContent(t)?this._processTokenInForeignContent(t):this._processToken(t),t.type===X.START_TAG_TOKEN&&t.selfClosing&&!t.ackSelfClosing&&this._err(Xr.nonVoidHtmlElementStartTagWithTrailingSolidus)}_isIntegrationPoint(t,n){const r=this.treeAdapter.getTagName(t),o=this.treeAdapter.getNamespaceURI(t),i=this.treeAdapter.getAttrList(t);return Ya.isIntegrationPoint(r,o,i,n)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.length;if(t){let n=t,r=null;do if(n--,r=this.activeFormattingElements.entries[n],r.type===_N.MARKER_ENTRY||this.openElements.contains(r.element)){n++;break}while(n>0);for(let o=n;o<t;o++)r=this.activeFormattingElements.entries[o],this._insertElement(r.token,this.treeAdapter.getNamespaceURI(r.element)),r.element=this.openElements.current}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=dl}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(x.P),this.openElements.popUntilTagNamePopped(x.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop,n=!1;t>=0;t--){let r=this.openElements.items[t];t===0&&(n=!0,this.fragmentContext&&(r=this.fragmentContext));const o=this.treeAdapter.getTagName(r),i=m4e[o];if(i){this.insertionMode=i;break}else if(!n&&(o===x.TD||o===x.TH)){this.insertionMode=jy;break}else if(!n&&o===x.HEAD){this.insertionMode=b1;break}else if(o===x.SELECT){this._resetInsertionModeForSelect(t);break}else if(o===x.TEMPLATE){this.insertionMode=this.currentTmplInsertionMode;break}else if(o===x.HTML){this.insertionMode=this.headElement?My:Py;break}else if(n){this.insertionMode=as;break}}}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.items[n],o=this.treeAdapter.getTagName(r);if(o===x.TEMPLATE)break;if(o===x.TABLE){this.insertionMode=gk;return}}this.insertionMode=mk}_pushTmplInsertionMode(t){this.tmplInsertionModeStack.push(t),this.tmplInsertionModeStackTop++,this.currentTmplInsertionMode=t}_popTmplInsertionMode(){this.tmplInsertionModeStack.pop(),this.tmplInsertionModeStackTop--,this.currentTmplInsertionMode=this.tmplInsertionModeStack[this.tmplInsertionModeStackTop]}_isElementCausesFosterParenting(t){const n=this.treeAdapter.getTagName(t);return n===x.TABLE||n===x.TBODY||n===x.TFOOT||n===x.THEAD||n===x.TR}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this._isElementCausesFosterParenting(this.openElements.current)}_findFosterParentingLocation(){const t={parent:null,beforeElement:null};for(let n=this.openElements.stackTop;n>=0;n--){const r=this.openElements.items[n],o=this.treeAdapter.getTagName(r),i=this.treeAdapter.getNamespaceURI(r);if(o===x.TEMPLATE&&i===ze.HTML){t.parent=this.treeAdapter.getTemplateContent(r);break}else if(o===x.TABLE){t.parent=this.treeAdapter.getParentNode(r),t.parent?t.beforeElement=r:t.parent=this.openElements.items[n-1];break}}return t.parent||(t.parent=this.openElements.items[0]),t}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_fosterParentText(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertTextBefore(n.parent,t,n.beforeElement):this.treeAdapter.insertText(n.parent,t)}_isSpecialElement(t){const n=this.treeAdapter.getTagName(t),r=this.treeAdapter.getNamespaceURI(t);return Yc.SPECIAL_ELEMENTS[r][n]}}var b4e=v4e;function y4e(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagName)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):ma(e,t),n}function E4e(e,t){let n=null;for(let r=e.openElements.stackTop;r>=0;r--){const o=e.openElements.items[r];if(o===t.element)break;e._isSpecialElement(o)&&(n=o)}return n||(e.openElements.popUntilElementPopped(t.element),e.activeFormattingElements.removeEntry(t)),n}function _4e(e,t,n){let r=t,o=e.openElements.getCommonAncestor(t);for(let i=0,a=o;a!==n;i++,a=o){o=e.openElements.getCommonAncestor(a);const s=e.activeFormattingElements.getElementEntry(a),l=s&&i>=p4e;!s||l?(l&&e.activeFormattingElements.removeEntry(s),e.openElements.remove(a)):(a=T4e(e,s),r===t&&(e.activeFormattingElements.bookmark=s),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(a,r),r=a)}return r}function T4e(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function w4e(e,t,n){if(e._isElementCausesFosterParenting(t))e._fosterParentElement(n);else{const r=e.treeAdapter.getTagName(t),o=e.treeAdapter.getNamespaceURI(t);r===x.TEMPLATE&&o===ze.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function k4e(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),o=n.token,i=e.treeAdapter.createElement(o.tagName,r,o.attrs);e._adoptNodes(t,i),e.treeAdapter.appendChild(t,i),e.activeFormattingElements.insertElementAfterBookmark(i,n.token),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,i)}function eu(e,t){let n;for(let r=0;r<h4e&&(n=y4e(e,t),!!n);r++){const o=E4e(e,n);if(!o)break;e.activeFormattingElements.bookmark=n;const i=_4e(e,o,n.element),a=e.openElements.getCommonAncestor(n.element);e.treeAdapter.detachNode(i),w4e(e,a,i),k4e(e,o,n)}}function Dt(){}function dg(e){e._err(Xr.misplacedDoctype)}function Tr(e,t){e._appendCommentNode(t,e.openElements.currentTmplContent||e.openElements.current)}function S4e(e,t){e._appendCommentNode(t,e.openElements.items[0])}function SN(e,t){e._appendCommentNode(t,e.document)}function Wo(e,t){e._insertCharacters(t)}function ph(e){e.stopped=!0}function x4e(e,t){e._setDocumentType(t);const n=t.forceQuirks?Yc.DOCUMENT_MODE.QUIRKS:wN.getDocumentMode(t);wN.isConforming(t)||e._err(Xr.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=pk}function mh(e,t){e._err(Xr.missingDoctype,{beforeToken:!0}),e.treeAdapter.setDocumentMode(e.document,Yc.DOCUMENT_MODE.QUIRKS),e.insertionMode=pk,e._processToken(t)}function C4e(e,t){t.tagName===x.HTML?(e._insertElement(t,ze.HTML),e.insertionMode=Py):Xh(e,t)}function A4e(e,t){const n=t.tagName;(n===x.HTML||n===x.HEAD||n===x.BODY||n===x.BR)&&Xh(e,t)}function Xh(e,t){e._insertFakeRootElement(),e.insertionMode=Py,e._processToken(t)}function N4e(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.HEAD?(e._insertElement(t,ze.HTML),e.headElement=e.openElements.current,e.insertionMode=b1):Zh(e,t)}function F4e(e,t){const n=t.tagName;n===x.HEAD||n===x.BODY||n===x.HTML||n===x.BR?Zh(e,t):e._err(Xr.endTagWithoutMatchingOpenElement)}function Zh(e,t){e._insertFakeElement(x.HEAD),e.headElement=e.openElements.current,e.insertionMode=b1,e._processToken(t)}function Pr(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.BASE||n===x.BASEFONT||n===x.BGSOUND||n===x.LINK||n===x.META?(e._appendElement(t,ze.HTML),t.ackSelfClosing=!0):n===x.TITLE?e._switchToTextParsing(t,X.MODE.RCDATA):n===x.NOSCRIPT?e.options.scriptingEnabled?e._switchToTextParsing(t,X.MODE.RAWTEXT):(e._insertElement(t,ze.HTML),e.insertionMode=FL):n===x.NOFRAMES||n===x.STYLE?e._switchToTextParsing(t,X.MODE.RAWTEXT):n===x.SCRIPT?e._switchToTextParsing(t,X.MODE.SCRIPT_DATA):n===x.TEMPLATE?(e._insertTemplate(t,ze.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=pb,e._pushTmplInsertionMode(pb)):n===x.HEAD?e._err(Xr.misplacedStartTagForHeadElement):Jh(e,t)}function Qc(e,t){const n=t.tagName;n===x.HEAD?(e.openElements.pop(),e.insertionMode=My):n===x.BODY||n===x.BR||n===x.HTML?Jh(e,t):n===x.TEMPLATE&&e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagName!==x.TEMPLATE&&e._err(Xr.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(x.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e._popTmplInsertionMode(),e._resetInsertionMode()):e._err(Xr.endTagWithoutMatchingOpenElement)}function Jh(e,t){e.openElements.pop(),e.insertionMode=My,e._processToken(t)}function I4e(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.BASEFONT||n===x.BGSOUND||n===x.HEAD||n===x.LINK||n===x.META||n===x.NOFRAMES||n===x.STYLE?Pr(e,t):n===x.NOSCRIPT?e._err(Xr.nestedNoscriptInHead):e0(e,t)}function B4e(e,t){const n=t.tagName;n===x.NOSCRIPT?(e.openElements.pop(),e.insertionMode=b1):n===x.BR?e0(e,t):e._err(Xr.endTagWithoutMatchingOpenElement)}function e0(e,t){const n=t.type===X.EOF_TOKEN?Xr.openElementsLeftAfterEof:Xr.disallowedContentInNoscriptInHead;e._err(n),e.openElements.pop(),e.insertionMode=b1,e._processToken(t)}function R4e(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.BODY?(e._insertElement(t,ze.HTML),e.framesetOk=!1,e.insertionMode=as):n===x.FRAMESET?(e._insertElement(t,ze.HTML),e.insertionMode=zy):n===x.BASE||n===x.BASEFONT||n===x.BGSOUND||n===x.LINK||n===x.META||n===x.NOFRAMES||n===x.SCRIPT||n===x.STYLE||n===x.TEMPLATE||n===x.TITLE?(e._err(Xr.abandonedHeadElementChild),e.openElements.push(e.headElement),Pr(e,t),e.openElements.remove(e.headElement)):n===x.HEAD?e._err(Xr.misplacedStartTagForHeadElement):t0(e,t)}function O4e(e,t){const n=t.tagName;n===x.BODY||n===x.HTML||n===x.BR?t0(e,t):n===x.TEMPLATE?Qc(e,t):e._err(Xr.endTagWithoutMatchingOpenElement)}function t0(e,t){e._insertFakeElement(x.BODY),e.insertionMode=as,e._processToken(t)}function lc(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function hg(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function D4e(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function P4e(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function M4e(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,ze.HTML),e.insertionMode=zy)}function Ps(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML)}function L4e(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement();const n=e.openElements.currentTagName;(n===x.H1||n===x.H2||n===x.H3||n===x.H4||n===x.H5||n===x.H6)&&e.openElements.pop(),e._insertElement(t,ze.HTML)}function xN(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function j4e(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML),n||(e.formElement=e.openElements.current))}function z4e(e,t){e.framesetOk=!1;const n=t.tagName;for(let r=e.openElements.stackTop;r>=0;r--){const o=e.openElements.items[r],i=e.treeAdapter.getTagName(o);let a=null;if(n===x.LI&&i===x.LI?a=x.LI:(n===x.DD||n===x.DT)&&(i===x.DD||i===x.DT)&&(a=i),a){e.openElements.generateImpliedEndTagsWithExclusion(a),e.openElements.popUntilTagNamePopped(a);break}if(i!==x.ADDRESS&&i!==x.DIV&&i!==x.P&&e._isSpecialElement(o))break}e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML)}function H4e(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML),e.tokenizer.state=X.MODE.PLAINTEXT}function U4e(e,t){e.openElements.hasInScope(x.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(x.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML),e.framesetOk=!1}function q4e(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(x.A);n&&(eu(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Df(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function $4e(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(x.NOBR)&&(eu(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,ze.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function CN(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function W4e(e,t){e.treeAdapter.getDocumentMode(e.document)!==Yc.DOCUMENT_MODE.QUIRKS&&e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML),e.framesetOk=!1,e.insertionMode=uo}function Qf(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,ze.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function G4e(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,ze.HTML);const n=X.getTokenAttr(t,CL.TYPE);(!n||n.toLowerCase()!==AL)&&(e.framesetOk=!1),t.ackSelfClosing=!0}function AN(e,t){e._appendElement(t,ze.HTML),t.ackSelfClosing=!0}function K4e(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._appendElement(t,ze.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function V4e(e,t){t.tagName=x.IMG,Qf(e,t)}function Y4e(e,t){e._insertElement(t,ze.HTML),e.skipNextNewLine=!0,e.tokenizer.state=X.MODE.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=hb}function Q4e(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,X.MODE.RAWTEXT)}function X4e(e,t){e.framesetOk=!1,e._switchToTextParsing(t,X.MODE.RAWTEXT)}function NN(e,t){e._switchToTextParsing(t,X.MODE.RAWTEXT)}function Z4e(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML),e.framesetOk=!1,e.insertionMode===uo||e.insertionMode===Ly||e.insertionMode===Vi||e.insertionMode===dl||e.insertionMode===jy?e.insertionMode=gk:e.insertionMode=mk}function FN(e,t){e.openElements.currentTagName===x.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML)}function IN(e,t){e.openElements.hasInScope(x.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,ze.HTML)}function J4e(e,t){e.openElements.hasInScope(x.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(x.RTC),e._insertElement(t,ze.HTML)}function eTe(e,t){e.openElements.hasInButtonScope(x.P)&&e._closePElement(),e._insertElement(t,ze.HTML)}function tTe(e,t){e._reconstructActiveFormattingElements(),Ya.adjustTokenMathMLAttrs(t),Ya.adjustTokenXMLAttrs(t),t.selfClosing?e._appendElement(t,ze.MATHML):e._insertElement(t,ze.MATHML),t.ackSelfClosing=!0}function nTe(e,t){e._reconstructActiveFormattingElements(),Ya.adjustTokenSVGAttrs(t),Ya.adjustTokenXMLAttrs(t),t.selfClosing?e._appendElement(t,ze.SVG):e._insertElement(t,ze.SVG),t.ackSelfClosing=!0}function Di(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,ze.HTML)}function ni(e,t){const n=t.tagName;switch(n.length){case 1:n===x.I||n===x.S||n===x.B||n===x.U?Df(e,t):n===x.P?Ps(e,t):n===x.A?q4e(e,t):Di(e,t);break;case 2:n===x.DL||n===x.OL||n===x.UL?Ps(e,t):n===x.H1||n===x.H2||n===x.H3||n===x.H4||n===x.H5||n===x.H6?L4e(e,t):n===x.LI||n===x.DD||n===x.DT?z4e(e,t):n===x.EM||n===x.TT?Df(e,t):n===x.BR?Qf(e,t):n===x.HR?K4e(e,t):n===x.RB?IN(e,t):n===x.RT||n===x.RP?J4e(e,t):n!==x.TH&&n!==x.TD&&n!==x.TR&&Di(e,t);break;case 3:n===x.DIV||n===x.DIR||n===x.NAV?Ps(e,t):n===x.PRE?xN(e,t):n===x.BIG?Df(e,t):n===x.IMG||n===x.WBR?Qf(e,t):n===x.XMP?Q4e(e,t):n===x.SVG?nTe(e,t):n===x.RTC?IN(e,t):n!==x.COL&&Di(e,t);break;case 4:n===x.HTML?D4e(e,t):n===x.BASE||n===x.LINK||n===x.META?Pr(e,t):n===x.BODY?P4e(e,t):n===x.MAIN||n===x.MENU?Ps(e,t):n===x.FORM?j4e(e,t):n===x.CODE||n===x.FONT?Df(e,t):n===x.NOBR?$4e(e,t):n===x.AREA?Qf(e,t):n===x.MATH?tTe(e,t):n===x.MENU?eTe(e,t):n!==x.HEAD&&Di(e,t);break;case 5:n===x.STYLE||n===x.TITLE?Pr(e,t):n===x.ASIDE?Ps(e,t):n===x.SMALL?Df(e,t):n===x.TABLE?W4e(e,t):n===x.EMBED?Qf(e,t):n===x.INPUT?G4e(e,t):n===x.PARAM||n===x.TRACK?AN(e,t):n===x.IMAGE?V4e(e,t):n!==x.FRAME&&n!==x.TBODY&&n!==x.TFOOT&&n!==x.THEAD&&Di(e,t);break;case 6:n===x.SCRIPT?Pr(e,t):n===x.CENTER||n===x.FIGURE||n===x.FOOTER||n===x.HEADER||n===x.HGROUP||n===x.DIALOG?Ps(e,t):n===x.BUTTON?U4e(e,t):n===x.STRIKE||n===x.STRONG?Df(e,t):n===x.APPLET||n===x.OBJECT?CN(e,t):n===x.KEYGEN?Qf(e,t):n===x.SOURCE?AN(e,t):n===x.IFRAME?X4e(e,t):n===x.SELECT?Z4e(e,t):n===x.OPTION?FN(e,t):Di(e,t);break;case 7:n===x.BGSOUND?Pr(e,t):n===x.DETAILS||n===x.ADDRESS||n===x.ARTICLE||n===x.SECTION||n===x.SUMMARY?Ps(e,t):n===x.LISTING?xN(e,t):n===x.MARQUEE?CN(e,t):n===x.NOEMBED?NN(e,t):n!==x.CAPTION&&Di(e,t);break;case 8:n===x.BASEFONT?Pr(e,t):n===x.FRAMESET?M4e(e,t):n===x.FIELDSET?Ps(e,t):n===x.TEXTAREA?Y4e(e,t):n===x.TEMPLATE?Pr(e,t):n===x.NOSCRIPT?e.options.scriptingEnabled?NN(e,t):Di(e,t):n===x.OPTGROUP?FN(e,t):n!==x.COLGROUP&&Di(e,t);break;case 9:n===x.PLAINTEXT?H4e(e,t):Di(e,t);break;case 10:n===x.BLOCKQUOTE||n===x.FIGCAPTION?Ps(e,t):Di(e,t);break;default:Di(e,t)}}function rTe(e){e.openElements.hasInScope(x.BODY)&&(e.insertionMode=vk)}function oTe(e,t){e.openElements.hasInScope(x.BODY)&&(e.insertionMode=vk,e._processToken(t))}function zl(e,t){const n=t.tagName;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function iTe(e){const t=e.openElements.tmplCount>0,n=e.formElement;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(x.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(x.FORM):e.openElements.remove(n))}function aTe(e){e.openElements.hasInButtonScope(x.P)||e._insertFakeElement(x.P),e._closePElement()}function sTe(e){e.openElements.hasInListItemScope(x.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(x.LI),e.openElements.popUntilTagNamePopped(x.LI))}function lTe(e,t){const n=t.tagName;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function uTe(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function BN(e,t){const n=t.tagName;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function cTe(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(x.BR),e.openElements.pop(),e.framesetOk=!1}function ma(e,t){const n=t.tagName;for(let r=e.openElements.stackTop;r>0;r--){const o=e.openElements.items[r];if(e.treeAdapter.getTagName(o)===n){e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilElementPopped(o);break}if(e._isSpecialElement(o))break}}function bk(e,t){const n=t.tagName;switch(n.length){case 1:n===x.A||n===x.B||n===x.I||n===x.S||n===x.U?eu(e,t):n===x.P?aTe(e):ma(e,t);break;case 2:n===x.DL||n===x.UL||n===x.OL?zl(e,t):n===x.LI?sTe(e):n===x.DD||n===x.DT?lTe(e,t):n===x.H1||n===x.H2||n===x.H3||n===x.H4||n===x.H5||n===x.H6?uTe(e):n===x.BR?cTe(e):n===x.EM||n===x.TT?eu(e,t):ma(e,t);break;case 3:n===x.BIG?eu(e,t):n===x.DIR||n===x.DIV||n===x.NAV||n===x.PRE?zl(e,t):ma(e,t);break;case 4:n===x.BODY?rTe(e):n===x.HTML?oTe(e,t):n===x.FORM?iTe(e):n===x.CODE||n===x.FONT||n===x.NOBR?eu(e,t):n===x.MAIN||n===x.MENU?zl(e,t):ma(e,t);break;case 5:n===x.ASIDE?zl(e,t):n===x.SMALL?eu(e,t):ma(e,t);break;case 6:n===x.CENTER||n===x.FIGURE||n===x.FOOTER||n===x.HEADER||n===x.HGROUP||n===x.DIALOG?zl(e,t):n===x.APPLET||n===x.OBJECT?BN(e,t):n===x.STRIKE||n===x.STRONG?eu(e,t):ma(e,t);break;case 7:n===x.ADDRESS||n===x.ARTICLE||n===x.DETAILS||n===x.SECTION||n===x.SUMMARY||n===x.LISTING?zl(e,t):n===x.MARQUEE?BN(e,t):ma(e,t);break;case 8:n===x.FIELDSET?zl(e,t):n===x.TEMPLATE?Qc(e,t):ma(e,t);break;case 10:n===x.BLOCKQUOTE||n===x.FIGCAPTION?zl(e,t):ma(e,t);break;default:ma(e,t)}}function Ms(e,t){e.tmplInsertionModeStackTop>-1?ML(e,t):e.stopped=!0}function fTe(e,t){t.tagName===x.SCRIPT&&(e.pendingScript=e.openElements.current),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function dTe(e,t){e._err(Xr.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e._processToken(t)}function Ls(e,t){const n=e.openElements.currentTagName;n===x.TABLE||n===x.TBODY||n===x.TFOOT||n===x.THEAD||n===x.TR?(e.pendingCharacterTokens=[],e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=IL,e._processToken(t)):Mi(e,t)}function hTe(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,ze.HTML),e.insertionMode=Ly}function pTe(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,ze.HTML),e.insertionMode=Fp}function mTe(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(x.COLGROUP),e.insertionMode=Fp,e._processToken(t)}function gTe(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,ze.HTML),e.insertionMode=Vi}function vTe(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(x.TBODY),e.insertionMode=Vi,e._processToken(t)}function bTe(e,t){e.openElements.hasInTableScope(x.TABLE)&&(e.openElements.popUntilTagNamePopped(x.TABLE),e._resetInsertionMode(),e._processToken(t))}function yTe(e,t){const n=X.getTokenAttr(t,CL.TYPE);n&&n.toLowerCase()===AL?e._appendElement(t,ze.HTML):Mi(e,t),t.ackSelfClosing=!0}function ETe(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,ze.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function yk(e,t){const n=t.tagName;switch(n.length){case 2:n===x.TD||n===x.TH||n===x.TR?vTe(e,t):Mi(e,t);break;case 3:n===x.COL?mTe(e,t):Mi(e,t);break;case 4:n===x.FORM?ETe(e,t):Mi(e,t);break;case 5:n===x.TABLE?bTe(e,t):n===x.STYLE?Pr(e,t):n===x.TBODY||n===x.TFOOT||n===x.THEAD?gTe(e,t):n===x.INPUT?yTe(e,t):Mi(e,t);break;case 6:n===x.SCRIPT?Pr(e,t):Mi(e,t);break;case 7:n===x.CAPTION?hTe(e,t):Mi(e,t);break;case 8:n===x.COLGROUP?pTe(e,t):n===x.TEMPLATE?Pr(e,t):Mi(e,t);break;default:Mi(e,t)}}function Ek(e,t){const n=t.tagName;n===x.TABLE?e.openElements.hasInTableScope(x.TABLE)&&(e.openElements.popUntilTagNamePopped(x.TABLE),e._resetInsertionMode()):n===x.TEMPLATE?Qc(e,t):n!==x.BODY&&n!==x.CAPTION&&n!==x.COL&&n!==x.COLGROUP&&n!==x.HTML&&n!==x.TBODY&&n!==x.TD&&n!==x.TFOOT&&n!==x.TH&&n!==x.THEAD&&n!==x.TR&&Mi(e,t)}function Mi(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,e._processTokenInBodyMode(t),e.fosterParentingEnabled=n}function _Te(e,t){e.pendingCharacterTokens.push(t)}function TTe(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function gh(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Mi(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}function wTe(e,t){const n=t.tagName;n===x.CAPTION||n===x.COL||n===x.COLGROUP||n===x.TBODY||n===x.TD||n===x.TFOOT||n===x.TH||n===x.THEAD||n===x.TR?e.openElements.hasInTableScope(x.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(x.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=uo,e._processToken(t)):ni(e,t)}function kTe(e,t){const n=t.tagName;n===x.CAPTION||n===x.TABLE?e.openElements.hasInTableScope(x.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(x.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=uo,n===x.TABLE&&e._processToken(t)):n!==x.BODY&&n!==x.COL&&n!==x.COLGROUP&&n!==x.HTML&&n!==x.TBODY&&n!==x.TD&&n!==x.TFOOT&&n!==x.TH&&n!==x.THEAD&&n!==x.TR&&bk(e,t)}function STe(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.COL?(e._appendElement(t,ze.HTML),t.ackSelfClosing=!0):n===x.TEMPLATE?Pr(e,t):mb(e,t)}function xTe(e,t){const n=t.tagName;n===x.COLGROUP?e.openElements.currentTagName===x.COLGROUP&&(e.openElements.pop(),e.insertionMode=uo):n===x.TEMPLATE?Qc(e,t):n!==x.COL&&mb(e,t)}function mb(e,t){e.openElements.currentTagName===x.COLGROUP&&(e.openElements.pop(),e.insertionMode=uo,e._processToken(t))}function CTe(e,t){const n=t.tagName;n===x.TR?(e.openElements.clearBackToTableBodyContext(),e._insertElement(t,ze.HTML),e.insertionMode=dl):n===x.TH||n===x.TD?(e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(x.TR),e.insertionMode=dl,e._processToken(t)):n===x.CAPTION||n===x.COL||n===x.COLGROUP||n===x.TBODY||n===x.TFOOT||n===x.THEAD?e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=uo,e._processToken(t)):yk(e,t)}function ATe(e,t){const n=t.tagName;n===x.TBODY||n===x.TFOOT||n===x.THEAD?e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=uo):n===x.TABLE?e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=uo,e._processToken(t)):(n!==x.BODY&&n!==x.CAPTION&&n!==x.COL&&n!==x.COLGROUP||n!==x.HTML&&n!==x.TD&&n!==x.TH&&n!==x.TR)&&Ek(e,t)}function NTe(e,t){const n=t.tagName;n===x.TH||n===x.TD?(e.openElements.clearBackToTableRowContext(),e._insertElement(t,ze.HTML),e.insertionMode=jy,e.activeFormattingElements.insertMarker()):n===x.CAPTION||n===x.COL||n===x.COLGROUP||n===x.TBODY||n===x.TFOOT||n===x.THEAD||n===x.TR?e.openElements.hasInTableScope(x.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Vi,e._processToken(t)):yk(e,t)}function FTe(e,t){const n=t.tagName;n===x.TR?e.openElements.hasInTableScope(x.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Vi):n===x.TABLE?e.openElements.hasInTableScope(x.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Vi,e._processToken(t)):n===x.TBODY||n===x.TFOOT||n===x.THEAD?(e.openElements.hasInTableScope(n)||e.openElements.hasInTableScope(x.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=Vi,e._processToken(t)):(n!==x.BODY&&n!==x.CAPTION&&n!==x.COL&&n!==x.COLGROUP||n!==x.HTML&&n!==x.TD&&n!==x.TH)&&Ek(e,t)}function ITe(e,t){const n=t.tagName;n===x.CAPTION||n===x.COL||n===x.COLGROUP||n===x.TBODY||n===x.TD||n===x.TFOOT||n===x.TH||n===x.THEAD||n===x.TR?(e.openElements.hasInTableScope(x.TD)||e.openElements.hasInTableScope(x.TH))&&(e._closeTableCell(),e._processToken(t)):ni(e,t)}function BTe(e,t){const n=t.tagName;n===x.TD||n===x.TH?e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=dl):n===x.TABLE||n===x.TBODY||n===x.TFOOT||n===x.THEAD||n===x.TR?e.openElements.hasInTableScope(n)&&(e._closeTableCell(),e._processToken(t)):n!==x.BODY&&n!==x.CAPTION&&n!==x.COL&&n!==x.COLGROUP&&n!==x.HTML&&bk(e,t)}function DL(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.OPTION?(e.openElements.currentTagName===x.OPTION&&e.openElements.pop(),e._insertElement(t,ze.HTML)):n===x.OPTGROUP?(e.openElements.currentTagName===x.OPTION&&e.openElements.pop(),e.openElements.currentTagName===x.OPTGROUP&&e.openElements.pop(),e._insertElement(t,ze.HTML)):n===x.INPUT||n===x.KEYGEN||n===x.TEXTAREA||n===x.SELECT?e.openElements.hasInSelectScope(x.SELECT)&&(e.openElements.popUntilTagNamePopped(x.SELECT),e._resetInsertionMode(),n!==x.SELECT&&e._processToken(t)):(n===x.SCRIPT||n===x.TEMPLATE)&&Pr(e,t)}function PL(e,t){const n=t.tagName;if(n===x.OPTGROUP){const r=e.openElements.items[e.openElements.stackTop-1],o=r&&e.treeAdapter.getTagName(r);e.openElements.currentTagName===x.OPTION&&o===x.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagName===x.OPTGROUP&&e.openElements.pop()}else n===x.OPTION?e.openElements.currentTagName===x.OPTION&&e.openElements.pop():n===x.SELECT&&e.openElements.hasInSelectScope(x.SELECT)?(e.openElements.popUntilTagNamePopped(x.SELECT),e._resetInsertionMode()):n===x.TEMPLATE&&Qc(e,t)}function RTe(e,t){const n=t.tagName;n===x.CAPTION||n===x.TABLE||n===x.TBODY||n===x.TFOOT||n===x.THEAD||n===x.TR||n===x.TD||n===x.TH?(e.openElements.popUntilTagNamePopped(x.SELECT),e._resetInsertionMode(),e._processToken(t)):DL(e,t)}function OTe(e,t){const n=t.tagName;n===x.CAPTION||n===x.TABLE||n===x.TBODY||n===x.TFOOT||n===x.THEAD||n===x.TR||n===x.TD||n===x.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(x.SELECT),e._resetInsertionMode(),e._processToken(t)):PL(e,t)}function DTe(e,t){const n=t.tagName;if(n===x.BASE||n===x.BASEFONT||n===x.BGSOUND||n===x.LINK||n===x.META||n===x.NOFRAMES||n===x.SCRIPT||n===x.STYLE||n===x.TEMPLATE||n===x.TITLE)Pr(e,t);else{const r=g4e[n]||as;e._popTmplInsertionMode(),e._pushTmplInsertionMode(r),e.insertionMode=r,e._processToken(t)}}function PTe(e,t){t.tagName===x.TEMPLATE&&Qc(e,t)}function ML(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(x.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e._popTmplInsertionMode(),e._resetInsertionMode(),e._processToken(t)):e.stopped=!0}function MTe(e,t){t.tagName===x.HTML?ni(e,t):gb(e,t)}function LTe(e,t){t.tagName===x.HTML?e.fragmentContext||(e.insertionMode=RL):gb(e,t)}function gb(e,t){e.insertionMode=as,e._processToken(t)}function jTe(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.FRAMESET?e._insertElement(t,ze.HTML):n===x.FRAME?(e._appendElement(t,ze.HTML),t.ackSelfClosing=!0):n===x.NOFRAMES&&Pr(e,t)}function zTe(e,t){t.tagName===x.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagName!==x.FRAMESET&&(e.insertionMode=BL))}function HTe(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.NOFRAMES&&Pr(e,t)}function UTe(e,t){t.tagName===x.HTML&&(e.insertionMode=OL)}function qTe(e,t){t.tagName===x.HTML?ni(e,t):nv(e,t)}function nv(e,t){e.insertionMode=as,e._processToken(t)}function $Te(e,t){const n=t.tagName;n===x.HTML?ni(e,t):n===x.NOFRAMES&&Pr(e,t)}function WTe(e,t){t.chars=f4e.REPLACEMENT_CHARACTER,e._insertCharacters(t)}function GTe(e,t){e._insertCharacters(t),e.framesetOk=!1}function KTe(e,t){if(Ya.causesExit(t)&&!e.fragmentContext){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==ze.HTML&&!e._isIntegrationPoint(e.openElements.current);)e.openElements.pop();e._processToken(t)}else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===ze.MATHML?Ya.adjustTokenMathMLAttrs(t):r===ze.SVG&&(Ya.adjustTokenSVGTagName(t),Ya.adjustTokenSVGAttrs(t)),Ya.adjustTokenXMLAttrs(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function VTe(e,t){for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===ze.HTML){e._processToken(t);break}if(e.treeAdapter.getTagName(r).toLowerCase()===t.tagName){e.openElements.popUntilElementPopped(r);break}}}const YTe=xr(b4e);function QTe(e){for(var t=String(e),n=[],r=/\r?\n|\r/g;r.test(t);)n.push(r.lastIndex);return n.push(t.length+1),{toPoint:o,toOffset:i};function o(a){var s=-1;if(a>-1&&a<n[n.length-1]){for(;++s<n.length;)if(n[s]>a)return{line:s+1,column:a-(n[s-1]||0)+1,offset:a}}return{line:void 0,column:void 0,offset:void 0}}function i(a){var s=a&&a.line,l=a&&a.column,u;return typeof s=="number"&&typeof l=="number"&&!Number.isNaN(s)&&!Number.isNaN(l)&&s-1 in n&&(u=(n[s-2]||0)+l-1||0),u>-1&&u<n[n.length-1]?u:-1}}var Rc={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};const LL={}.hasOwnProperty,RN={"#document":ON,"#document-fragment":ON,"#text":ewe,"#comment":twe,"#documentType":JTe};function XTe(e,t={}){let n,r;return owe(t)?(r=t,n={}):(r=t.file,n=t),_k({schema:n.space==="svg"?Mu:m1,file:r,verbose:n.verbose,location:!1},e)}function _k(e,t){const n=e.schema,r=LL.call(RN,t.nodeName)?RN[t.nodeName]:nwe;let o;"tagName"in t&&(e.schema=t.namespaceURI===Rc.svg?Mu:m1),"childNodes"in t&&(o=ZTe(e,t.childNodes));const i=r(e,t,o);if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const a=rwe(e,i,t.sourceCodeLocation);a&&(e.location=!0,i.position=a)}return e.schema=n,i}function ZTe(e,t){let n=-1;const r=[];for(;++n<t.length;)r[n]=_k(e,t[n]);return r}function ON(e,t,n){const r={type:"root",children:n,data:{quirksMode:t.mode==="quirks"||t.mode==="limited-quirks"}};if(e.file&&e.location){const o=String(e.file),i=QTe(o);r.position={start:i.toPoint(0),end:i.toPoint(o.length)}}return r}function JTe(){return{type:"doctype"}}function ewe(e,t){return{type:"text",value:t.value}}function twe(e,t){return{type:"comment",value:t.data}}function nwe(e,t,n){const r=e.schema.space==="svg"?IEe:iL;let o=-1;const i={};for(;++o<t.attrs.length;){const s=t.attrs[o];i[(s.prefix?s.prefix+":":"")+s.name]=s.value}const a=r(t.tagName,i,n);if(a.tagName==="template"&&"content"in t){const s=t.sourceCodeLocation,l=s&&s.startTag&&ld(s.startTag),u=s&&s.endTag&&ld(s.endTag),d=_k(e,t.content);l&&u&&e.file&&(d.position={start:l.end,end:u.start}),a.content=d}return a}function rwe(e,t,n){const r=ld(n);if(t.type==="element"){const o=t.children[t.children.length-1];if(r&&!n.endTag&&o&&o.position&&o.position.end&&(r.end=Object.assign({},o.position.end)),e.verbose){const i={};let a;for(a in n.attrs)LL.call(n.attrs,a)&&(i[bp(e.schema,a).property]=ld(n.attrs[a]));t.data={position:{opening:ld(n.startTag),closing:n.endTag?ld(n.endTag):null,properties:i}}}}return r}function ld(e){const t=DN({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=DN({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:null}function DN(e){return e.line&&e.column?e:null}function owe(e){return"messages"in e}const iwe=Rc,awe=s4,swe={}.hasOwnProperty,lwe=h1("root"),p4=h1("element"),uwe=h1("text");function cwe(e,t,n){if(typeof e!="function")throw new TypeError("h is not a function");const r=dwe(e),o=mwe(e),i=pwe(e);let a,s;if(typeof n=="string"||typeof n=="boolean"?(a=n,n={}):(n||(n={}),a=n.prefix),lwe(t))s=t.children.length===1&&p4(t.children[0])?t.children[0]:{type:"element",tagName:"div",properties:{},children:t.children};else if(p4(t))s=t;else throw new Error("Expected root or element, not `"+(t&&t.type||t)+"`");return jL(e,s,{schema:n.space==="svg"?Mu:m1,prefix:a==null?r||o||i?"h-":null:typeof a=="string"?a:a?"h-":null,key:0,react:r,vue:o,vdom:i,hyperscript:hwe(e)})}function jL(e,t,n){const r=n.schema;let o=r,i=t.tagName;const a={},s=[];let l=-1,u;r.space==="html"&&i.toLowerCase()==="svg"&&(o=Mu,n.schema=o);for(u in t.properties)t.properties&&swe.call(t.properties,u)&&fwe(a,u,t.properties[u],n,i);if(n.vdom&&(o.space==="html"?i=i.toUpperCase():o.space&&(a.namespace=iwe[o.space])),n.prefix&&(n.key++,a.key=n.prefix+n.key),t.children)for(;++l<t.children.length;){const d=t.children[l];p4(d)?s.push(jL(e,d,n)):uwe(d)&&s.push(d.value)}return n.schema=r,s.length>0?e.call(t,i,a,s):e.call(t,i,a)}function fwe(e,t,n,r,o){const i=bp(r.schema,t);let a;n==null||typeof n=="number"&&Number.isNaN(n)||n===!1&&(r.vue||r.vdom||r.hyperscript)||!n&&i.boolean&&(r.vue||r.vdom||r.hyperscript)||(Array.isArray(n)&&(n=i.commaSeparated?YM(n):VM(n)),i.boolean&&r.hyperscript&&(n=""),i.property==="style"&&typeof n=="string"&&(r.react||r.vue||r.vdom)&&(n=gwe(n,o)),r.vue?i.property!=="style"&&(a="attrs"):i.mustUseProperty||(r.vdom?i.property!=="style"&&(a="attributes"):r.hyperscript&&(a="attrs")),a?e[a]=Object.assign(e[a]||{},{[i.attribute]:n}):i.space&&r.react?e[awe[i.property]||i.property]=n:e[i.attribute]=n)}function dwe(e){const t=e("div",{});return!!(t&&("_owner"in t||"_store"in t)&&(t.key===void 0||t.key===null))}function hwe(e){return"context"in e&&"cleanup"in e}function pwe(e){return e("div",{}).type==="VirtualNode"}function mwe(e){const t=e("div",{});return!!(t&&t.context&&t.context._isVue)}function gwe(e,t){const n={};try{QM(e,(r,o)=>{r.slice(0,4)==="-ms-"&&(r="ms-"+r.slice(4)),n[r.replace(/-([a-z])/g,(i,a)=>a.toUpperCase())]=o})}catch(r){throw r.message=t+"[style]"+r.message.slice(9),r}return n}var PN={}.hasOwnProperty;function zL(e,t){var n=t||{};function r(o){var i=r.invalid,a=r.handlers;if(o&&PN.call(o,e)&&(i=PN.call(a,o[e])?a[o[e]]:r.unknown),i)return i.apply(this,arguments)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}var vwe={}.hasOwnProperty,HL=zL("type",{handlers:{root:ywe,element:kwe,text:Twe,comment:wwe,doctype:_we}});function bwe(e,t){return HL(e,t==="svg"?Mu:m1)}function ywe(e,t){var n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Tk(e.children,n,t),y1(e,n)}function Ewe(e,t){var n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Tk(e.children,n,t),y1(e,n)}function _we(e){return y1(e,{nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:void 0})}function Twe(e){return y1(e,{nodeName:"#text",value:e.value,parentNode:void 0})}function wwe(e){return y1(e,{nodeName:"#comment",data:e.value,parentNode:void 0})}function kwe(e,t){var n=t.space;return cwe(r,Object.assign({},e,{children:[]}),{space:n});function r(o,i){var a=[],s,l,u,d,h;for(u in i)!vwe.call(i,u)||i[u]===!1||(s=bp(t,u),!(s.boolean&&!i[u])&&(l={name:u,value:i[u]===!0?"":String(i[u])},s.space&&s.space!=="html"&&s.space!=="svg"&&(d=u.indexOf(":"),d<0?l.prefix="":(l.name=u.slice(d+1),l.prefix=u.slice(0,d)),l.namespace=Rc[s.space]),a.push(l)));return t.space==="html"&&e.tagName==="svg"&&(t=Mu),h=y1(e,{nodeName:o,tagName:o,attrs:a,namespaceURI:Rc[t.space],childNodes:[],parentNode:void 0}),h.childNodes=Tk(e.children,h,t),o==="template"&&(h.content=Ewe(e.content,t)),h}}function Tk(e,t,n){var r=-1,o=[],i;if(e)for(;++r<e.length;)i=HL(e[r],n),i.parentNode=t,o.push(i);return o}function y1(e,t){var n=e.position;return n&&n.start&&n.end&&(t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset}),t}var Swe=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","isindex","keygen","link","menuitem","meta","nextid","param","source","track","wbr"];const xwe="IN_TEMPLATE_MODE",Cwe="DATA_STATE",Awe="CHARACTER_TOKEN",Nwe="START_TAG_TOKEN",Fwe="END_TAG_TOKEN",Iwe="COMMENT_TOKEN",Bwe="DOCTYPE_TOKEN",Rwe={sourceCodeLocationInfo:!0,scriptingEnabled:!1},UL=function(e,t,n){let r=-1;const o=new YTe(Rwe),i=zL("type",{handlers:{root:_,element:b,text:E,comment:k,doctype:w,raw:y},unknown:Mwe});let a,s,l,u,d;if(jwe(t)&&(n=t,t=void 0),n&&n.passThrough)for(;++r<n.passThrough.length;)i.handlers[n.passThrough[r]]=F;const h=XTe(Lwe(e)?m():p(),t);if(a&&Iw(h,"comment",(A,P,I)=>{const j=A;if(j.value.stitch&&I!==null&&P!==null)return I.children[P]=j.value.stitch,P}),e.type!=="root"&&h.type==="root"&&h.children.length===1)return h.children[0];return h;function p(){const A={nodeName:"template",tagName:"template",attrs:[],namespaceURI:Rc.html,childNodes:[]},P={nodeName:"documentmock",tagName:"documentmock",attrs:[],namespaceURI:Rc.html,childNodes:[]},I={nodeName:"#document-fragment",childNodes:[]};if(o._bootstrap(P,A),o._pushTmplInsertionMode(xwe),o._initTokenizerForFragmentParsing(),o._insertFakeRootElement(),o._resetInsertionMode(),o._findFormInFragmentContext(),s=o.tokenizer,!s)throw new Error("Expected `tokenizer`");return l=s.preprocessor,d=s.__mixins[0],u=d.posTracker,i(e),o._adoptNodes(P.childNodes[0],I),I}function m(){const A=o.treeAdapter.createDocument();if(o._bootstrap(A,void 0),s=o.tokenizer,!s)throw new Error("Expected `tokenizer`");return l=s.preprocessor,d=s.__mixins[0],u=d.posTracker,i(e),A}function v(A){let P=-1;if(A)for(;++P<A.length;)i(A[P])}function _(A){v(A.children)}function b(A){C(),o._processToken(Owe(A),Rc.html),v(A.children),Swe.includes(A.tagName)||(C(),o._processToken(Pwe(A)))}function E(A){C(),o._processToken({type:Awe,chars:A.value,location:ud(A)})}function w(A){C(),o._processToken({type:Bwe,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:ud(A)})}function k(A){C(),o._processToken({type:Iwe,data:A.value,location:ud(A)})}function y(A){const P=Sy(A),I=P.line||1,j=P.column||1,H=P.offset||0;if(!l)throw new Error("Expected `preprocessor`");if(!s)throw new Error("Expected `tokenizer`");if(!u)throw new Error("Expected `posTracker`");if(!d)throw new Error("Expected `locationTracker`");l.html=void 0,l.pos=-1,l.lastGapPos=-1,l.lastCharPos=-1,l.gapStack=[],l.skipNextNewLine=!1,l.lastChunkWritten=!1,l.endOfChunkHit=!1,u.isEol=!1,u.lineStartPos=-j+1,u.droppedBufferSize=H,u.offset=0,u.col=1,u.line=I,d.currentAttrLocation=void 0,d.ctLoc=ud(A),s.write(A.value),o._runParsingLoop(void 0);const K=s.currentCharacterToken;K&&(K.location.endLine=u.line,K.location.endCol=u.col+1,K.location.endOffset=u.offset+1,o._processToken(K))}function F(A){a=!0;let P;"children"in A?P={...A,children:UL({type:"root",children:A.children},t,n).children}:P={...A},k({type:"comment",value:{stitch:P}})}function C(){if(!s)throw new Error("Expected `tokenizer`");s.tokenQueue=[],s.state=Cwe,s.returnState="",s.charRefCode=-1,s.tempBuff=[],s.lastStartTagName="",s.consumedAfterSnapshot=-1,s.active=!1,s.currentCharacterToken=void 0,s.currentToken=void 0,s.currentAttr=void 0}};function Owe(e){const t=Object.assign(ud(e));return t.startTag=Object.assign({},t),{type:Nwe,tagName:e.tagName,selfClosing:!1,attrs:Dwe(e),location:t}}function Dwe(e){return bwe({tagName:e.tagName,type:"element",properties:e.properties,children:[]}).attrs}function Pwe(e){const t=Object.assign(ud(e));return t.startTag=Object.assign({},t),{type:Fwe,tagName:e.tagName,attrs:[],location:t}}function Mwe(e){throw new Error("Cannot compile `"+e.type+"` node")}function Lwe(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName==="html"))}function ud(e){const t=Sy(e),n=Bw(e);return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function jwe(e){return!!(e&&!("message"in e&&"messages"in e))}function zwe(e={}){return(t,n)=>UL(t,n,e)}var Hwe={}.hasOwnProperty,Uwe=qwe;function qwe(e){return e==null?[]:"length"in e?e:[e]}var qL=$we,pg=1e4;function $we(e,t,n,r){var o=e.length,i=0,a,s;if(t<0?t=-t>o?0:o+t:t=t>o?o:t,n=n>0?n:0,r.length<pg)return s=Array.from(r),s.unshift(t,n),[].splice.apply(e,s);for(a=[].splice.apply(e,[t,n]);i<r.length;)s=r.slice(i,i+pg),s.unshift(t,0),[].splice.apply(e,s),i+=pg,t+=pg;return a}var Wwe=Vwe,MN=Hwe,Gwe=Uwe,Kwe=qL;function Vwe(e){for(var t={},n=-1;++n<e.length;)Ywe(t,e[n]);return t}function Ywe(e,t){var n,r,o,i;for(n in t){r=MN.call(e,n)?e[n]:e[n]={},o=t[n];for(i in o)r[i]=Qwe(Gwe(o[i]),MN.call(r,i)?r[i]:[])}}function Qwe(e,t){for(var n=-1,r=[];++n<e.length;)(e[n].add==="after"?t:r).push(e[n]);return Kwe(t,0,0,r),t}var $L={},Xwe=String.fromCharCode,Hy=Jwe,Zwe=Xwe;function Jwe(e){return t;function t(n){return e.test(Zwe(n))}}var eke=Hy,tke=eke(/[\dA-Za-z]/),nke=Hy,rke=nke(/[A-Za-z]/),wk=tke,oke=rke,WL={tokenize:cke},GL={tokenize:fke},Rd={tokenize:pke},ike={tokenize:hke},ake={tokenize:dke},KL={tokenize:lke,previous:E1},VL={tokenize:uke,previous:E1},wl={tokenize:ske,previous:E1},ys={};$L.text=ys;var uc=48;for(;uc<123;)ys[uc]=wl,uc++,uc===58?uc=65:uc===91&&(uc=97);ys[43]=wl;ys[45]=wl;ys[46]=wl;ys[95]=wl;ys[72]=[wl,VL];ys[104]=[wl,VL];ys[87]=[wl,KL];ys[119]=[wl,KL];function ske(e,t,n){var r=this,o;return i;function i(p){return!jN(p)||!E1(r.previous)?n(p):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),a(p))}function a(p){return jN(p)?(e.consume(p),a):p===64?(e.consume(p),s):n(p)}function s(p){return p===46?e.check(Rd,h,l)(p):p===45||p===95?e.check(Rd,n,u)(p):wk(p)?(e.consume(p),s):h(p)}function l(p){return e.consume(p),o=!0,s}function u(p){return e.consume(p),d}function d(p){return p===46?e.check(Rd,n,l)(p):s(p)}function h(p){return o?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(p)):n(p)}}function lke(e,t,n){var r=this;return o;function o(u){return u!==87&&u-32!==87||!E1(r.previous)?n(u):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.consume(u),i)}function i(u){return u===87||u-32===87?(e.consume(u),a):n(u)}function a(u){return u===87||u-32===87?(e.consume(u),s):n(u)}function s(u){return u===46?(e.consume(u),e.attempt(WL,e.attempt(GL,l),n)):n(u)}function l(u){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(u)}}function uke(e,t,n){var r=this;return o;function o(m){return m!==72&&m-32!==72||!E1(r.previous)?n(m):(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),e.consume(m),i)}function i(m){return m===84||m-32===84?(e.consume(m),a):n(m)}function a(m){return m===84||m-32===84?(e.consume(m),s):n(m)}function s(m){return m===80||m-32===80?(e.consume(m),l):n(m)}function l(m){return m===83||m-32===83?(e.consume(m),u):u(m)}function u(m){return m===58?(e.consume(m),d):n(m)}function d(m){return m===47?(e.consume(m),h):n(m)}function h(m){return m===47?(e.consume(m),e.attempt(WL,e.attempt(GL,p),n)):n(m)}function p(m){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(m)}}function cke(e,t,n){var r,o,i;return a;function a(d){return e.enter("literalAutolinkDomain"),s(d)}function s(d){return d===45||d===95||wk(d)?(d===95&&(r=!0),e.consume(d),s):d===46?e.check(Rd,u,l)(d):u(d)}function l(d){return e.consume(d),i=!0,o=r,r=void 0,s}function u(d){return i&&!o&&!r?(e.exit("literalAutolinkDomain"),t(d)):n(d)}}function fke(e,t){var n=0;return r;function r(u){return z0(u)?t(u):LN(u)?e.check(Rd,t,o)(u):o(u)}function o(u){return e.enter("literalAutolinkWwwPath"),i(u)}function i(u){return u===38?e.check(ake,l,a)(u):(u===40&&n++,u===41?e.check(ike,s,a)(u):z0(u)?l(u):LN(u)?e.check(Rd,l,a)(u):(e.consume(u),i))}function a(u){return e.consume(u),i}function s(u){return n--,n<0?l(u):a(u)}function l(u){return e.exit("literalAutolinkWwwPath"),t(u)}}function dke(e,t,n){return r;function r(a){return e.enter("literalAutolinkCharacterReferenceNamed"),e.consume(a),o}function o(a){return oke(a)?(e.consume(a),o):a===59?(e.consume(a),i):n(a)}function i(a){return e.exit("literalAutolinkCharacterReferenceNamed"),z0(a)?t(a):n(a)}}function hke(e,t,n){return r;function r(i){return e.enter("literalAutolinkParen"),e.consume(i),o}function o(i){return e.exit("literalAutolinkParen"),z0(i)||i===41?t(i):n(i)}}function pke(e,t,n){return r;function r(i){return e.enter("literalAutolinkPunctuation"),e.consume(i),o}function o(i){return e.exit("literalAutolinkPunctuation"),z0(i)?t(i):n(i)}}function LN(e){return e===33||e===42||e===44||e===46||e===58||e===63||e===95||e===126}function z0(e){return e===null||e<0||e===32||e===60}function jN(e){return e===43||e===45||e===46||e===95||wk(e)}function E1(e){return e===null||e<0||e===32||e===40||e===42||e===95||e===126}var mke=$L,YL=gke;function gke(e){return e<0||e===32}var vke=/[!-\/:-@\[-`\{-~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,bke=vke,yke=Hy,Eke=yke(bke),_ke=Hy,Tke=_ke(/\s/),wke=Cke,kke=YL,Ske=Eke,xke=Tke;function Cke(e){if(e===null||kke(e)||xke(e))return 1;if(Ske(e))return 2}var Ake=Nke;function Nke(e,t,n){for(var r=[],o=-1,i;++o<e.length;)i=e[o].resolveAll,i&&r.indexOf(i)<0&&(t=i(t,n),r.push(i));return t}var Fke=Object.assign,Ike=Rke,Bke=Fke;function Rke(e){return Bke({},e)}var Oke=Pke,zN=wke,lE=qL,Dke=Ake,mg=Ike;function Pke(e){var t=e||{},n=t.singleTilde,r={tokenize:a,resolveAll:o};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:r}};function o(s,l){for(var u=-1,d,h,p,m;++u<s.length;)if(s[u][0]==="enter"&&s[u][1].type==="strikethroughSequenceTemporary"&&s[u][1]._close){for(p=u;p--;)if(s[p][0]==="exit"&&s[p][1].type==="strikethroughSequenceTemporary"&&s[p][1]._open&&s[u][1].end.offset-s[u][1].start.offset===s[p][1].end.offset-s[p][1].start.offset){s[u][1].type="strikethroughSequence",s[p][1].type="strikethroughSequence",d={type:"strikethrough",start:mg(s[p][1].start),end:mg(s[u][1].end)},h={type:"strikethroughText",start:mg(s[p][1].end),end:mg(s[u][1].start)},m=[["enter",d,l],["enter",s[p][1],l],["exit",s[p][1],l],["enter",h,l]],lE(m,m.length,0,Dke(l.parser.constructs.insideSpan.null,s.slice(p+1,u),l)),lE(m,m.length,0,[["exit",h,l],["enter",s[u][1],l],["exit",s[u][1],l],["exit",d,l]]),lE(s,p-1,u-p+3,m),u=p+m.length-2;break}}return i(s)}function i(s){for(var l=-1,u=s.length;++l<u;)s[l][1].type==="strikethroughSequenceTemporary"&&(s[l][1].type="data");return s}function a(s,l,u){var d=this.previous,h=this.events,p=0;return m;function m(_){return _!==126||d===126&&h[h.length-1][1].type!=="characterEscape"?u(_):(s.enter("strikethroughSequenceTemporary"),v(_))}function v(_){var b=zN(d),E,w;return _===126?p>1?u(_):(s.consume(_),p++,v):p<2&&!n?u(_):(E=s.exit("strikethroughSequenceTemporary"),w=zN(_),E._open=!w||w===2&&b,E._close=!b||b===2&&w,l(_))}}}var QL={},Mke=Lke;function Lke(e){return e===-2||e===-1||e===32}var XL=jke,HN=Mke;function jke(e,t,n,r){var o=r?r-1:1/0,i;return a;function a(l){return HN(l)?(e.enter(n),i=0,s(l)):t(l)}function s(l){return HN(l)&&i++<o?(e.consume(l),s):(e.exit(n),t(l))}}QL.flow={null:{tokenize:Uke,resolve:Hke,interruptible:!0}};var uE=XL,zke={tokenize:qke,partial:!0},UN={tokenize:$ke,partial:!0};function Hke(e,t){for(var n=e.length,r=-1,o,i,a,s,l,u,d,h,p,m;++r<n;)o=e[r][1],s&&(o.type==="temporaryTableCellContent"&&(h=h||r,p=r),(o.type==="tableCellDivider"||o.type==="tableRow")&&p&&(u={type:"tableContent",start:e[h][1].start,end:e[p][1].end},d={type:"chunkText",start:u.start,end:u.end,contentType:"text"},e.splice(h,p-h+1,["enter",u,t],["enter",d,t],["exit",d,t],["exit",u,t]),r-=p-h-3,n=e.length,h=void 0,p=void 0)),e[r][0]==="exit"&&(o.type==="tableCellDivider"||o.type==="tableRow")&&m&&m+1<r&&(l={type:a?"tableDelimiter":i?"tableHeader":"tableData",start:e[m][1].start,end:e[r][1].end},e.splice(r+(o.type==="tableCellDivider"?1:0),0,["exit",l,t]),e.splice(m,0,["enter",l,t]),r+=2,n=e.length,m=r+1),o.type==="tableRow"&&(s=e[r][0]==="enter",s&&(m=r+1)),o.type==="tableDelimiterRow"&&(a=e[r][0]==="enter",a&&(m=r+1)),o.type==="tableHead"&&(i=e[r][0]==="enter");return e}function Uke(e,t,n){var r=[],o=0,i,a;return s;function s($){return $===null||$===-5||$===-4||$===-3?n($):(e.enter("table")._align=r,e.enter("tableHead"),e.enter("tableRow"),$===124?l($):(o++,e.enter("temporaryTableCellContent"),h($)))}function l($){return e.enter("tableCellDivider"),e.consume($),e.exit("tableCellDivider"),i=!0,u}function u($){return $===null||$===-5||$===-4||$===-3?m($):$===-2||$===-1||$===32?(e.enter("whitespace"),e.consume($),d):(i&&(i=void 0,o++),$===124?l($):(e.enter("temporaryTableCellContent"),h($)))}function d($){return $===-2||$===-1||$===32?(e.consume($),d):(e.exit("whitespace"),u($))}function h($){return $===null||$<0||$===32||$===124?(e.exit("temporaryTableCellContent"),u($)):(e.consume($),$===92?p:h)}function p($){return $===92||$===124?(e.consume($),h):h($)}function m($){return $===null?n($):(e.exit("tableRow"),e.exit("tableHead"),e.enter("lineEnding"),e.consume($),e.exit("lineEnding"),e.check(zke,n,uE(e,v,"linePrefix",4)))}function v($){return $===null||$<0||$===32?n($):(e.enter("tableDelimiterRow"),_($))}function _($){return $===null||$===-5||$===-4||$===-3?y($):$===-2||$===-1||$===32?(e.enter("whitespace"),e.consume($),b):$===45?(e.enter("tableDelimiterFiller"),e.consume($),a=!0,r.push(null),E):$===58?(e.enter("tableDelimiterAlignment"),e.consume($),e.exit("tableDelimiterAlignment"),r.push("left"),w):$===124?(e.enter("tableCellDivider"),e.consume($),e.exit("tableCellDivider"),_):n($)}function b($){return $===-2||$===-1||$===32?(e.consume($),b):(e.exit("whitespace"),_($))}function E($){return $===45?(e.consume($),E):(e.exit("tableDelimiterFiller"),$===58?(e.enter("tableDelimiterAlignment"),e.consume($),e.exit("tableDelimiterAlignment"),r[r.length-1]=r[r.length-1]==="left"?"center":"right",k):_($))}function w($){return $===45?(e.enter("tableDelimiterFiller"),e.consume($),a=!0,E):n($)}function k($){return $===null||$===-5||$===-4||$===-3?y($):$===-2||$===-1||$===32?(e.enter("whitespace"),e.consume($),b):$===124?(e.enter("tableCellDivider"),e.consume($),e.exit("tableCellDivider"),_):n($)}function y($){return e.exit("tableDelimiterRow"),!a||o!==r.length?n($):$===null?F($):e.check(UN,F,C)($)}function F($){return e.exit("table"),t($)}function C($){return e.enter("lineEnding"),e.consume($),e.exit("lineEnding"),uE(e,A,"linePrefix",4)}function A($){return e.enter("tableBody"),P($)}function P($){return e.enter("tableRow"),$===124?I($):(e.enter("temporaryTableCellContent"),K($))}function I($){return e.enter("tableCellDivider"),e.consume($),e.exit("tableCellDivider"),j}function j($){return $===null||$===-5||$===-4||$===-3?pe($):$===-2||$===-1||$===32?(e.enter("whitespace"),e.consume($),H):$===124?I($):(e.enter("temporaryTableCellContent"),K($))}function H($){return $===-2||$===-1||$===32?(e.consume($),H):(e.exit("whitespace"),j($))}function K($){return $===null||$<0||$===32||$===124?(e.exit("temporaryTableCellContent"),j($)):(e.consume($),$===92?U:K)}function U($){return $===92||$===124?(e.consume($),K):K($)}function pe($){return e.exit("tableRow"),$===null?se($):e.check(UN,se,J)($)}function se($){return e.exit("tableBody"),F($)}function J($){return e.enter("lineEnding"),e.consume($),e.exit("lineEnding"),uE(e,P,"linePrefix",4)}}function qke(e,t,n){return r;function r(a){return a!==45?n(a):(e.enter("setextUnderline"),o(a))}function o(a){return a===45?(e.consume(a),o):i(a)}function i(a){return a===-2||a===-1||a===32?(e.consume(a),i):a===null||a===-5||a===-4||a===-3?t(a):n(a)}}function $ke(e,t,n){var r=0;return o;function o(a){return e.enter("check"),e.consume(a),i}function i(a){return a===-1||a===32?(e.consume(a),r++,r===4?t:i):a===null||a<0?t(a):n(a)}}var Wke=QL,ZL={},Gke=Kke;function Kke(e){for(var t=-1,n=0;++t<e.length;)n+=typeof e[t]=="string"?e[t].length:1;return n}var Vke=Qke,Yke=Gke;function Qke(e,t){var n=e[e.length-1];return!n||n[1].type!==t?0:Yke(n[2].sliceStream(n[1]))}var Xke=YL,Zke=XL,Jke=Vke,eSe={tokenize:tSe};ZL.text={91:eSe};function tSe(e,t,n){var r=this;return o;function o(s){return s!==91||r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(s):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),i)}function i(s){return s===-2||s===32?(e.enter("taskListCheckValueUnchecked"),e.consume(s),e.exit("taskListCheckValueUnchecked"),a):s===88||s===120?(e.enter("taskListCheckValueChecked"),e.consume(s),e.exit("taskListCheckValueChecked"),a):n(s)}function a(s){return s===93?(e.enter("taskListCheckMarker"),e.consume(s),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),e.check({tokenize:nSe},t,n)):n(s)}}function nSe(e,t,n){var r=this;return Zke(e,o,"whitespace");function o(i){return Jke(r.events,"whitespace")&&i!==null&&!Xke(i)?t(i):n(i)}}var rSe=ZL,oSe=Wwe,iSe=mke,aSe=Oke,sSe=Wke,lSe=rSe,uSe=cSe;function cSe(e){return oSe([iSe,aSe(e),sSe,lSe])}var fSe=uSe,kk={};kk.enter={literalAutolink:dSe,literalAutolinkEmail:cE,literalAutolinkHttp:cE,literalAutolinkWww:cE};kk.exit={literalAutolink:gSe,literalAutolinkEmail:mSe,literalAutolinkHttp:hSe,literalAutolinkWww:pSe};function dSe(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function cE(e){this.config.enter.autolinkProtocol.call(this,e)}function hSe(e){this.config.exit.autolinkProtocol.call(this,e)}function pSe(e){this.config.exit.data.call(this,e),this.stack[this.stack.length-1].url="http://"+this.sliceSerialize(e)}function mSe(e){this.config.exit.autolinkEmail.call(this,e)}function gSe(e){this.exit(e)}var Uy={};Uy.canContainEols=["delete"];Uy.enter={strikethrough:vSe};Uy.exit={strikethrough:bSe};function vSe(e){this.enter({type:"delete",children:[]},e)}function bSe(e){this.exit(e)}var Sk={};Sk.enter={table:ySe,tableData:qN,tableHeader:qN,tableRow:_Se};Sk.exit={codeText:TSe,table:ESe,tableData:fE,tableHeader:fE,tableRow:fE};function ySe(e){this.enter({type:"table",align:e._align,children:[]},e),this.setData("inTable",!0)}function ESe(e){this.exit(e),this.setData("inTable")}function _Se(e){this.enter({type:"tableRow",children:[]},e)}function fE(e){this.exit(e)}function qN(e){this.enter({type:"tableCell",children:[]},e)}function TSe(e){var t=this.resume();this.getData("inTable")&&(t=t.replace(/\\([\\|])/g,wSe)),this.stack[this.stack.length-1].value=t,this.exit(e)}function wSe(e,t){return t==="|"?t:e}var JL={};JL.exit={taskListCheckValueChecked:$N,taskListCheckValueUnchecked:$N,paragraph:kSe};function $N(e){this.stack[this.stack.length-2].checked=e.type==="taskListCheckValueChecked"}function kSe(e){var t=this.stack[this.stack.length-2],n=this.stack[this.stack.length-1],r=t.children,o=n.children[0],i=-1,a;if(t&&t.type==="listItem"&&typeof t.checked=="boolean"&&o&&o.type==="text"){for(;++i<r.length;)if(r[i].type==="paragraph"){a=r[i];break}a===n&&(o.value=o.value.slice(1),o.value.length===0?n.children.shift():(o.position.start.column++,o.position.start.offset++,n.position.start=Object.assign({},o.position.start)))}this.exit(e)}var SSe=kk,xSe=Uy,CSe=Sk,ASe=JL,NSe={}.hasOwnProperty,FSe=ISe([SSe,xSe,CSe,ASe]);function ISe(e){for(var t={canContainEols:[]},n=e.length,r=-1;++r<n;)BSe(t,e[r]);return t}function BSe(e,t){var n,r,o;for(n in t)r=NSe.call(e,n)?e[n]:e[n]={},o=t[n],n==="canContainEols"?e[n]=[].concat(r,o):Object.assign(r,o)}var ej={},dE="phrasing",hE=["autolink","link","image"];ej.unsafe=[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:dE,notInConstruct:hE},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:dE,notInConstruct:hE},{character:":",before:"[ps]",after:"\\/",inConstruct:dE,notInConstruct:hE}];var xk={},RSe=OSe;function OSe(e,t,n){for(var r=e.children||[],o=[],i=-1,a=n.before,s,l,u;++i<r.length;)u=r[i],i+1<r.length?(l=t.handle.handlers[r[i+1].type],l&&l.peek&&(l=l.peek),s=l?l(r[i+1],e,t,{before:"",after:""}).charAt(0):""):s=n.after,o.push(t.handle(u,e,t,{before:a,after:s})),a=o[o.length-1].slice(-1);return o.join("")}var DSe=RSe;xk.unsafe=[{character:"~",inConstruct:"phrasing"}];xk.handlers={delete:tj};tj.peek=PSe;function tj(e,t,n){var r=n.enter("emphasis"),o=DSe(e,n,{before:"~",after:"~"});return r(),"~~"+o+"~~"}function PSe(){return"~"}var MSe=LSe;function LSe(e,t,n){for(var r=e.children||[],o=[],i=-1,a=n.before,s,l,u;++i<r.length;)u=r[i],i+1<r.length?(l=t.handle.handlers[r[i+1].type],l&&l.peek&&(l=l.peek),s=l?l(r[i+1],e,t,{before:"",after:""}).charAt(0):""):s=n.after,o.push(t.handle(u,e,t,{before:a,after:s})),a=o[o.length-1].slice(-1);return o.join("")}var jSe=nj;nj.peek=zSe;function nj(e){for(var t=e.value||"",n="`",r="";new RegExp("(^|[^`])"+n+"([^`]|$)").test(t);)n+="`";return/[^ \r\n]/.test(t)&&(/[ \r\n`]/.test(t.charAt(0))||/[ \r\n`]/.test(t.charAt(t.length-1)))&&(r=" "),n+r+t+r+n}function zSe(){return"`"}/*! * repeat-string <https://github.com/jonschlinkert/repeat-string> * * Copyright (c) 2014-2015, Jon Schlinkert. * Licensed under the MIT License. */var js="",pE,Ck=HSe;function HSe(e,t){if(typeof e!="string")throw new TypeError("expected a string");if(t===1)return e;if(t===2)return e+e;var n=e.length*t;if(pE!==e||typeof pE>"u")pE=e,js="";else if(js.length>=n)return js.substr(0,n);for(;n>js.length&&t>1;)t&1&&(js+=e),t>>=1,e+=e;return js+=e,js=js.substr(0,n),js}var Pf=Ck,USe=YSe,qSe=/ +$/,cc=" ",$Se=` `,WSe="-",gg=":",WN="|",GN=0,GSe=67,KSe=76,VSe=82,vb=99,m4=108,bb=114;function YSe(e,t){for(var n=t||{},r=n.padding!==!1,o=n.delimiterStart!==!1,i=n.delimiterEnd!==!1,a=(n.align||[]).concat(),s=n.alignDelimiters!==!1,l=[],u=n.stringLength||XSe,d=-1,h=e.length,p=[],m=[],v=[],_=[],b=[],E=0,w,k,y,F,C,A,P,I,j,H,K;++d<h;){for(w=e[d],k=-1,y=w.length,v=[],_=[],y>E&&(E=y);++k<y;)A=QSe(w[k]),s===!0&&(C=u(A),_[k]=C,F=b[k],(F===void 0||C>F)&&(b[k]=C)),v.push(A);p[d]=v,m[d]=_}if(k=-1,y=E,typeof a=="object"&&"length"in a)for(;++k<y;)l[k]=KN(a[k]);else for(K=KN(a);++k<y;)l[k]=K;for(k=-1,y=E,v=[],_=[];++k<y;)K=l[k],j="",H="",K===m4?j=gg:K===bb?H=gg:K===vb&&(j=gg,H=gg),C=s?Math.max(1,b[k]-j.length-H.length):1,A=j+Pf(WSe,C)+H,s===!0&&(C=j.length+C+H.length,C>b[k]&&(b[k]=C),_[k]=C),v[k]=A;for(p.splice(1,0,v),m.splice(1,0,_),d=-1,h=p.length,P=[];++d<h;){for(v=p[d],_=m[d],k=-1,y=E,I=[];++k<y;)A=v[k]||"",j="",H="",s===!0&&(C=b[k]-(_[k]||0),K=l[k],K===bb?j=Pf(cc,C):K===vb?C%2===0?(j=Pf(cc,C/2),H=j):(j=Pf(cc,C/2+.5),H=Pf(cc,C/2-.5)):H=Pf(cc,C)),o===!0&&k===0&&I.push(WN),r===!0&&!(s===!1&&A==="")&&(o===!0||k!==0)&&I.push(cc),s===!0&&I.push(j),I.push(A),s===!0&&I.push(H),r===!0&&I.push(cc),(i===!0||k!==y-1)&&I.push(WN);I=I.join(""),i===!1&&(I=I.replace(qSe,"")),P.push(I)}return P.join($Se)}function QSe(e){return e==null?"":String(e)}function XSe(e){return e.length}function KN(e){var t=typeof e=="string"?e.charCodeAt(0):GN;return t===KSe||t===m4?m4:t===VSe||t===bb?bb:t===GSe||t===vb?vb:GN}var ZSe=MSe,JSe=jSe,e8e=USe,t8e=n8e;function n8e(e){var t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,o=t.stringLength,i=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:` `,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{table:a,tableRow:s,tableCell:l,inlineCode:p}};function a(m,v,_){return u(d(m,_),m.align)}function s(m,v,_){var b=h(m,_),E=u([b]);return E.slice(0,E.indexOf(` `))}function l(m,v,_){var b=_.enter("tableCell"),E=ZSe(m,_,{before:i,after:i});return b(),E}function u(m,v){return e8e(m,{align:v,alignDelimiters:r,padding:n,stringLength:o})}function d(m,v){for(var _=m.children,b=-1,E=_.length,w=[],k=v.enter("table");++b<E;)w[b]=h(_[b],v);return k(),w}function h(m,v){for(var _=m.children,b=-1,E=_.length,w=[],k=v.enter("tableRow");++b<E;)w[b]=l(_[b],m,v);return k(),w}function p(m,v,_){var b=JSe(m);return _.stack.indexOf("tableCell")!==-1&&(b=b.replace(/\|/,"\\$&")),b}}var Ak={},r8e=o8e;function o8e(e){var t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}var i8e=a8e;function a8e(e){var t=e.options.listItemIndent||"tab";if(t===1||t==="1")return"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}var s8e=u8e,l8e=Ck;function u8e(e,t){for(var n=e.children||[],r=[],o=-1,i;++o<n.length;)i=n[o],r.push(t.handle(i,e,t,{before:` `,after:` `})),o+1<n.length&&r.push(a(i,n[o+1]));return r.join("");function a(s,l){for(var u=-1,d;++u<t.join.length&&(d=t.join[u](s,l,e,t),!(d===!0||d===1));){if(typeof d=="number")return l8e(` `,1+Number(d));if(d===!1)return` <!----> `}return` `}}var c8e=d8e,f8e=/\r?\n|\r/g;function d8e(e,t){for(var n=[],r=0,o=0,i;i=f8e.exec(e);)a(e.slice(r,i.index)),n.push(i[0]),r=i.index+i[0].length,o++;return a(e.slice(r)),n.join("");function a(s){n.push(t(s,o,!s))}}var h8e=b8e,VN=Ck,p8e=r8e,m8e=i8e,g8e=s8e,v8e=c8e;function b8e(e,t,n){var r=p8e(n),o=m8e(n),i,a,s;return t&&t.ordered&&(r=(t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+"."),i=r.length+1,(o==="tab"||o==="mixed"&&(t&&t.spread||e.spread))&&(i=Math.ceil(i/4)*4),s=n.enter("listItem"),a=v8e(g8e(e,n),l),s(),a;function l(u,d,h){return d?(h?"":VN(" ",i))+u:(h?r:r+VN(" ",i-r.length))+u}}var y8e=h8e;Ak.unsafe=[{atBreak:!0,character:"-",after:"[:|-]"}];Ak.handlers={listItem:E8e};function E8e(e,t,n){var r=y8e(e,t,n),o=e.children[0];return typeof e.checked=="boolean"&&o&&o.type==="paragraph"&&(r=r.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,i)),r;function i(a){return a+"["+(e.checked?"x":" ")+"] "}}var _8e=ej,T8e=xk,w8e=t8e,k8e=Ak,S8e=x8e;function x8e(e){for(var t=[_8e,T8e,w8e(e),k8e],n=t.length,r=-1,o,i=[],a={};++r<n;)o=t[r],i=i.concat(o.unsafe||[]),a=Object.assign(a,o.handlers||{});return{unsafe:i,handlers:a}}var C8e=fSe,A8e=FSe,N8e=S8e,YN,F8e=I8e;function I8e(e){var t=this.data();!YN&&(this.Parser&&this.Parser.prototype&&this.Parser.prototype.blockTokenizers||this.Compiler&&this.Compiler.prototype&&this.Compiler.prototype.visitors)&&(YN=!0,console.warn("[remark-gfm] Warning: please upgrade to remark 13 to use this plugin")),n("micromarkExtensions",C8e(e)),n("fromMarkdownExtensions",A8e),n("toMarkdownExtensions",N8e(e));function n(r,o){t[r]?t[r].push(o):t[r]=[o]}}const B8e=xr(F8e),R8e=e=>{try{JSON.parse(e)}catch{return!1}return!0},O8e=Fo({padding:"4px 20px",fontSize:"16px"}),D8e=({className:e,content:t,isDark:n})=>{if(typeof t!="string")return Q.jsx(Q.Fragment,{children:t});const r=R8e(t)?`\`\`\`json ${t} \`\`\``:t;return Q.jsx(ny,{className:e,children:Q.jsx(iM,{children:Q.jsx(Dw,{components:{code:o=>{const{node:i,inline:a,children:s,className:l,...u}=o,d=/language-(\w+)/.exec(l||"");return!a&&d?Q.jsx(XEe,{...u,language:d[1],showLineNumbers:!0,style:n?e_e:void 0,PreTag:"div",children:String(s).replace(/\n$/,"")}):Q.jsx("code",{className:l,...u,children:o.children})}},className:O8e,children:r??"",remarkPlugins:[B8e],rehypePlugins:[zwe]})})})},P8e=({id:e,src:t,isDark:n,style:r,isEnableEdit:o,onEdit:i})=>{const[a,s]=Bt.useState(t),l=n?"monokai":"rjv-default",u=o?d=>{const h=d.updated_src;console.log("newPayload ",h),s(h),i==null||i(e,h)}:void 0;return Q.jsx(ny,{children:Q.jsx(iM,{children:Q.jsx(JEe,{style:r,src:a,theme:l,quotesOnKeys:!1,displayDataTypes:!1,onEdit:u,displayObjectSize:!1})})})},M8e=({message:e})=>{const{isDark:t,viewMode:n,editMessageHandlerRef:r}=bbe(),o=Che(e.id,wr.User),i=(h,p)=>{var m;(m=r.current)==null||m.call(r,h,p)},a=e.from===wr.User&&n===Js.Debug,s=T.useMemo(()=>ybe(e.content),[e.content]),l=Object.keys(s),u=l.length===1?s[l[0]]:e.content,d=e.from===wr.Chatbot?u:e.content;return Q.jsxs("div",{children:[Q.jsx(j8e,{message:e,isUserDebug:a}),a?Q.jsx(P8e,{style:{padding:10},src:s,isEnableEdit:o,onEdit:i,isDark:t,id:`${e.id}`}):Q.jsx(D8e,{isDark:t,content:d},e.id),Q.jsx(z8e,{message:e})]})},L8e=({message:e})=>{const t=Du();return Q.jsxs("div",{style:{paddingBottom:"10px"},children:[Q.jsxs("span",{style:{fontWeight:"bold",fontSize:"18px",display:"inline-flex",alignItems:"center"},children:[Q.jsx("span",{children:e.from===wr.User?(t==null?void 0:t.chatUserName)??"User":(t==null?void 0:t.chatBotName)??"Chatbot"}),e.from===wr.User?(t==null?void 0:t.chatUserAvatar)&&Q.jsx("span",{style:{paddingLeft:8},children:Q.jsx(Gv,{src:t==null?void 0:t.chatUserAvatar,shape:"circular",width:32,height:32})}):(t==null?void 0:t.chatBotAvatar)&&Q.jsx("span",{style:{paddingLeft:8},children:Q.jsx(Gv,{src:t==null?void 0:t.chatBotAvatar,shape:"circular",width:32,height:32})})]}),Q.jsx("span",{style:{fontSize:14,paddingLeft:12},children:De(e.timestamp).fromNow()})]})},j8e=({message:e,isUserDebug:t})=>{const n=()=>{fP(e.content)};return Q.jsxs("div",{style:{width:"100%",display:"flex",flexDirection:"row",alignItems:"center",justifyContent:"space-between"},children:[Q.jsx(L8e,{message:e}),t?Q.jsx(Q.Fragment,{}):Q.jsxs(QT,{children:[Q.jsx(sy,{children:Q.jsx(cl,{content:"More action",relationship:"label",children:Q.jsx(En,{shape:"circular",size:"small",icon:Q.jsx(XO,{})})})}),Q.jsx(ZT,{children:Q.jsx(XT,{children:Q.jsx($h,{icon:Q.jsx(QO,{}),onClick:n,children:"Copy"})})})]})]})},z8e=({message:e})=>e.duration?Q.jsxs("div",{style:{paddingTop:5},children:["Duration: ",e.duration.toFixed(4),"s"]}):Q.jsx(Q.Fragment,{}),H8e=e=>{switch(typeof e){case"undefined":return!1;case"string":return e.length>0;default:return!0}},U8e=Fo({display:"flex",alignItems:"center",justifyContent:"flex-end",paddingLeft:8,paddingRight:8,i:{fontSize:"1.5em"}}),q8e=Fo({display:"flex !important",alignItems:"center",marginBottom:10,">label":{minWidth:100,textAlign:"right"},">.fui-Input":{flex:1}}),$8e=({scoreInputs:e,isChatbotTyping:t,onScore:n,onClear:r})=>{const o=GD(wr.User),i=T.useRef(o.length-1),[a,s]=T.useState(e);T.useEffect(()=>{i.current=o.length-1},[o]);const l=b=>{const E=i.current+(b==="ArrowUp"?-1:1);if(E<0){i.current=E+o.length;return}if(E>=o.length){i.current=E-o.length;return}i.current=E},[u,d]=T.useState(!1),h=T.useRef(null),p=Ou();T.useEffect(()=>{Object.keys(e).length&&s(Qo.cloneDeep(e))},[e]),T.useEffect(()=>{const b=Object.keys(a).every(E=>H8e(a[E].value));d(b)},[a]);const m=T.useCallback(()=>{n(a),Object.keys(e).length&&s(Qo.cloneDeep(Object.fromEntries(Object.keys(e).map(b=>[b,{...e[b],value:void 0}]))))},[a,n,e]),v=T.useCallback(b=>{b.key==="Enter"&&u&&m()},[u,m]);T.useEffect(()=>{var b;!t&&h.current&&((b=h.current.querySelector("input"))==null||b.focus())},[t]);const _=Object.keys(a).map(b=>{const{type:E,sample:w,value:k}=a[b],y=(C,A)=>{const P=A.value;s(I=>({...I,[b]:{...I[b],value:P}})),i.current=o.length-1},F=C=>{(C.key==="ArrowUp"||C.key==="ArrowDown")&&(s(A=>{const P=JSON.parse(o[i.current].content);return{...A,[b]:{...A[b],value:P[b]}}}),console.log("ArrowUp"),l(C.key))};return Q.jsx(yD,{label:b,required:!0,orientation:"horizontal",className:q8e,size:"large",children:Q.jsx(Ad,{type:E,size:"large",onKeyDown:v,disabled:t,onChange:y,onKeyUp:F,placeholder:w,value:k??""})},b)});return Q.jsxs("div",{className:p.inputBox,"data-disabled":t,style:{display:"flex"},children:[Q.jsx("div",{style:{flex:1,marginBottom:-10},ref:h,children:_}),Q.jsxs("div",{className:U8e,children:[Q.jsx(cl,{relationship:"description",content:"Send message",children:Q.jsx(En,{as:"button",appearance:"primary",shape:"circular",style:{marginLeft:"10px",width:"40px",height:"36px",maxWidth:40,maxHeight:40},size:"medium",icon:Q.jsx(hle,{}),disabled:t||!u,onClick:m})}),r?Q.jsx(cl,{relationship:"description",content:lw.ClearHistoryTooltip,children:Q.jsx(En,{style:{marginLeft:"10px",width:"40px",height:"36px",maxWidth:40,maxHeight:40},as:"button",shape:"circular",size:"medium",icon:Q.jsx(YO,{}),disabled:t,onClick:r})}):void 0]})]})},W8e=(e,t)=>{const n=URL.createObjectURL(e),r=document.createElement("a");r.href=n,r.download=t,document.body.appendChild(r),r.click(),document.body.removeChild(r),URL.revokeObjectURL(n)},G8e=Fo({display:"flex",flexDirection:"column",marginBottom:15,"> label":{marginBottom:10,fontSize:16}}),K8e=()=>{const{isDark:e,setIsDark:t,messages:n,viewMode:r,setViewMode:o,chatDBRef:i,isDisableChatHistory:a,appConfig:s,setAppConfig:l,setIsDisableChatHistory:u}=T.useContext(eo),[d,h]=T.useState(),[p,m]=T.useState(!1),v=T.useCallback(()=>m(!1),[]),[_,b]=T.useState(!1),[E,w]=T.useState(!1),k=()=>{t(!e)},y=T.useCallback((U,pe)=>{h(pe.value)},[]),F=T.useCallback(()=>{var U;(U=i.current)==null||U.clear(),b(!1),setTimeout(()=>{window.location.reload()},200)},[]),C=()=>{WD.clearAllDataBase(i.current),w(!1),setTimeout(()=>{window.location.reload()},200)},A=T.useCallback(()=>{var pe,se;const U={id:s.id||up.v4(),type:z_,appDisplayName:d};l(J=>J!=null&&J.id?{...J,appDisplayName:d}:U),(se=(pe=i.current)==null?void 0:pe.getStore(c1))==null||se.put(U)},[d,s]),P=lo("appDisplayName"),I=T.useCallback(()=>{const U={};for(const[se,J]of n)U[se]=J;const pe=new Blob([JSON.stringify(U,void 0,2)],{type:"application/json"});W8e(pe,"chat-history.json")},[n]),j=T.useCallback(()=>{o(U=>U===Js.Normal?Js.Debug:Js.Normal)},[]),H=()=>{u(U=>!U)},K=T.useCallback(()=>{m(!0)},[]);return Q.jsxs(Q.Fragment,{children:[Q.jsx(cl,{content:"Settings",relationship:"label",children:Q.jsx(En,{icon:Q.jsx(mle,{}),onClick:K})}),Q.jsx(Kv,{modalType:"modal",open:p,children:Q.jsx(Qv,{style:{width:500,height:"100vh",marginRight:0},children:Q.jsxs(Vv,{children:[Q.jsx(Yv,{children:Q.jsxs("div",{style:{display:"flex",alignItems:"center",justifyContent:"space-between"},children:[Q.jsx("span",{children:"Settings"}),Q.jsx(En,{appearance:"subtle",icon:Q.jsx(cse,{}),onClick:v})]})}),Q.jsxs(Xv,{children:[Q.jsx("div",{children:Q.jsx(jg,{labelPosition:"after",label:lw.Settings.useDarkTheme,onChange:k,checked:e})}),Q.jsx("div",{children:Q.jsx(jg,{label:"Debug",checked:r===Js.Debug,onChange:j})}),Q.jsx("div",{children:Q.jsx(jg,{label:"Enable chat history",checked:!a,onChange:H})}),Q.jsx(O_,{style:{margin:"10px 0"}}),Q.jsxs("div",{className:G8e,children:[Q.jsx(Zo,{htmlFor:P,children:"Edit app name"}),Q.jsxs("div",{style:{display:"flex",width:"100%"},children:[Q.jsx(Ad,{id:P,value:d??(s==null?void 0:s.appDisplayName),style:{width:"100%"},size:"large",onChange:y}),Q.jsx(En,{style:{marginLeft:10},onClick:A,children:"Save"})]})]}),Q.jsx(En,{onClick:I,size:"large",appearance:"secondary",children:"Download history"}),Q.jsx(O_,{style:{margin:"10px 0"}}),Q.jsx(Zo,{children:"Clear Chat history"}),Q.jsxs("div",{style:{marginTop:10},children:[Q.jsxs(R_,{open:_,children:[Q.jsx(Wv,{disableButtonEnhancement:!0,children:Q.jsx(En,{size:"large",appearance:"subtle",onClick:()=>b(!0),children:"Clear current chat app"})}),Q.jsx(B_,{children:Q.jsxs("div",{style:{padding:10},children:[Q.jsx(Zo,{children:"Are you sure you want to clear the current chat app data?"}),Q.jsxs("div",{style:{display:"flex",justifyContent:"center",marginTop:10},children:[Q.jsx(En,{style:{marginRight:10},onClick:F,size:"large",appearance:"primary",children:"Yes"}),Q.jsx(En,{onClick:()=>b(!1),size:"large",appearance:"subtle",children:"No"})]})]})})]}),Q.jsxs(R_,{open:E,children:[Q.jsx(Wv,{disableButtonEnhancement:!0,children:Q.jsx(En,{style:{marginLeft:10},size:"large",appearance:"subtle",onClick:()=>w(!0),children:"Clear all chat app"})}),Q.jsx(B_,{children:Q.jsxs("div",{style:{padding:10},children:[Q.jsx(Zo,{children:"Are you sure you want to clear all chat app data?"}),Q.jsxs("div",{style:{display:"flex",justifyContent:"center",marginTop:10},children:[Q.jsx(En,{style:{marginRight:10},onClick:C,size:"large",appearance:"primary",children:"Yes"}),Q.jsx(En,{onClick:()=>w(!1),size:"large",appearance:"subtle",children:"No"})]})]})})]})]})]})]})})})]})},V8e=Fo({backgroundColor:"var(--colorNeutralBackground4)",padding:"10px 20px",borderRadius:16}),Y8e=({scoreInputs:e,isChatHistoryExist:t})=>{const[n,r]=T.useState(!1),[o,i]=T.useState(!0),{isDisableChatHistory:a,setIsChatHistoryExist:s,appConfig:l={},editMessageHandlerRef:u,currentMessageNavIdRef:d}=T.useContext(eo),h=Mhe(),p=Phe(),{id:m}=Du()??{},{setAddChatHistory:v}=Dhe(),_=zD(),b=she(),{setAddMessage:E,setResetAtIdAndRemoveAfterId:w}=xhe(),k=Fhe(),[y]=yl();T.useEffect(()=>{s(t)},[t]);const F=(P,I,j)=>{E(V6(P,j)),v(I,P,j),d.current=""},C=upe({url:"/score",method:"POST"},{onSettled:(P,I,j)=>{var H;if(r(!1),I){E(V6(I.message)),d.current="";return}F((P==null?void 0:P.data)??{},j||{},(H=P==null?void 0:P.config.metaData)==null?void 0:H.duration)}});u.current=async(P,I)=>{w(P,K6(I)),r(!0),C.mutate(I)};const A=async P=>{const I=fpe(P,p,t,a);d.current=m??"";const j=K6(I);if(E(j),y.length&&y[0].name===""){const H=Object.values(P)[0].value??"";k(H)}r(!0),C.mutate(I)};return Q.jsx(V1e,{containerStyles:{backgroundColor:"var(--colorNeutralBackground3)"},toolbarContainerStyles:{backgroundColor:"var(--colorNeutralBackground1)"},chatTitle:l.appDisplayName,isBottomTipVisible:o,isFullScreen:_,isChatbotTyping:n&&d.current===m,typingClassName:V8e,messages:h,onBottomTipVisibleChange:i,onClear:Qo.noop,LocStrings:lw,onToggleFullScreen:b,onClose:void 0,customToolbarActions:Q.jsx(K8e,{}),CustomMessageContentRenderer:M8e,customInputBox:Q.jsx($8e,{scoreInputs:e,isChatbotTyping:n,onScore:A}),onSendMessage:Qo.noop})},Q8e=async e=>new Promise((t,n)=>{const r=new FileReader;r.readAsDataURL(e),r.onload=function(){t(r.result)},r.onerror=function(o){n(o)}}),QN=({name:e="file-input",onFileChange:t,value:n})=>{const[r,o]=T.useState(n??""),i=T.useRef(null),a=T.useCallback(()=>{var l;(l=i.current)==null||l.click()},[]),s=T.useCallback(async l=>{var d;const u=(d=l.target.files)==null?void 0:d[0];if(u){const h=await Q8e(u);o(h),t==null||t(h)}},[t]);return Q.jsxs("div",{children:[Q.jsx("input",{type:"file",name:e,ref:i,onChange:s,style:{display:"none"}}),Q.jsx(tD,{icon:Q.jsx(ese,{}),shape:"square",onClick:a}),r?Q.jsx("div",{style:{paddingTop:15},children:Q.jsx(Gv,{bordered:!0,shape:"circular",src:r,alt:"image",style:{width:160,height:160}})}):void 0]})},X8e=()=>{const{name:e}=Du()??{};return T.useCallback(()=>{fP(e??"")},[e])},Z8e=Fo({".ms-Nav-groupContent":{"> .ms-Nav-navItems":{"> .ms-Nav-navItem":{button:{color:"var(--colorNeutralForeground1)"}}}}}),vh=Fo({display:"flex",flexDirection:"column",marginBottom:15,"> label":{marginBottom:5,fontSize:16}}),J8e={id:"newChat",name:"New chat",url:""},exe={display:"flex",width:"100%",whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis",fontSize:18,fontWeight:"bold"},txe=({link:e})=>{const t=KD(),n=Nhe(),r=()=>{t()};return Q.jsx(En,{onClick:r,icon:Q.jsx(Zae,{}),shape:"rounded",disabled:!n,style:{width:"90%",marginLeft:"5%",marginTop:10,height:50},children:(e==null?void 0:e.name)??""})},nxe=e=>{var l,u,d,h,p,m;const{onDelete:t}=e,n=VD(),r=v=>{v&&n(v.id)},o=T.useCallback(v=>{v.stopPropagation()},[]),i=X8e(),a=T.useCallback(()=>{var v,_;console.log("on edit",e.link),(_=e.onEditing)==null||_.call(e,((v=e.link)==null?void 0:v.id)??"")},[e.onEditing,(l=e.link)==null?void 0:l.id]),s=T.useMemo(()=>Q.jsxs(QT,{children:[Q.jsx(sy,{children:Q.jsx(En,{shape:"circular",style:{},size:"small",onClick:o,icon:Q.jsx(XO,{})})}),Q.jsx(ZT,{children:Q.jsxs(XT,{children:[Q.jsx($h,{icon:Q.jsx(QO,{}),onClick:i,children:"Copy"}),Q.jsx($h,{icon:Q.jsx(pse,{}),onClick:a,children:"Update"}),Q.jsx($h,{icon:Q.jsx(ase,{}),onClick:t,children:"Delete"})]})})]}),[o,i]);return((u=e.link)==null?void 0:u.id)==="newChat"?Q.jsx(txe,{link:e.link}):Q.jsx(cl,{content:((d=e.link)==null?void 0:d.name)??"",relationship:"label",positioning:"after",children:Q.jsx(En,{onClick:()=>r(e.link),shape:"square",as:"a",style:{width:"94%",marginLeft:"3%",border:0,height:50,marginTop:10,backgroundColor:(h=e.link)!=null&&h.isSelected?"var(--colorNeutralBackground3)":""},icon:Q.jsx("span",{style:{visibility:(p=e.link)!=null&&p.isSelected?"visible":"hidden"},children:s}),iconPosition:"after",children:Q.jsx("span",{style:exe,children:(m=e.link)==null?void 0:m.name})})})},rxe=()=>{const[e]=yl(),[t,n]=T.useState(!1),[r,o]=T.useState(!1),[i,a]=T.useState(""),[s,l]=T.useState(""),[u,d]=T.useState(""),[h,p]=T.useState(""),[m,v]=T.useState(""),_=KD(),b=VD(),E=T.useCallback(ve=>{n(!0);const fe=e.find(R=>R.id===ve);a((fe==null?void 0:fe.name)??""),l((fe==null?void 0:fe.chatUserName)??""),d((fe==null?void 0:fe.chatUserAvatar)??""),p((fe==null?void 0:fe.chatBotName)??""),v((fe==null?void 0:fe.chatBotAvatar)??"")},[e]),w=Bhe(),k=T.useCallback((ve,fe)=>{ve.stopPropagation(),a(fe.value??"")},[]),y=T.useCallback((ve,fe)=>{ve.stopPropagation(),l(fe.value??"")},[]),F=T.useCallback(ve=>{d(ve)},[]),C=T.useCallback((ve,fe)=>{ve.stopPropagation(),p(fe.value??"")},[]),A=T.useCallback(ve=>{v(ve)},[]),P=()=>{w({name:i,chatUserName:s,chatUserAvatar:u,chatBotName:h,chatBotAvatar:m}),n(!1)},I=lo("navName"),j=lo("chatUserName"),H=lo("chatBotName"),K=lo("chatUserAvatar"),U=lo("chatBotAvatar");T.useEffect(()=>{console.log("realod the nav container")},[]);const pe=T.useMemo(()=>[J8e].concat(e.map(ve=>({id:ve.id,name:ve.name,url:"",isSelected:ve.isSelected}))),[e]),se=T.useMemo(()=>pe.filter(ve=>!!ve.name),[pe]),J=T.useCallback(()=>{o(!0)},[]),$=Ohe(),_e=T.useCallback(()=>{$(),o(!1),e.length===1?requestAnimationFrame(()=>{_()}):b(0)},[e,$,_]);return Q.jsxs(Q.Fragment,{children:[Q.jsx(_te,{className:Z8e,styles:{root:{width:320},compositeLink:{backgroundColor:"var(--colorNeutralBackground1)"}},linkAs:ve=>Q.jsx(nxe,{...ve,onEditing:E,onDelete:J}),groups:[{links:se}]}),Q.jsx(Kv,{open:t,children:Q.jsx(Qv,{children:Q.jsxs(Vv,{children:[Q.jsx(Yv,{children:"Edit this chat"}),Q.jsxs(Xv,{style:{margin:"5px 0 10px 0"},children:[Q.jsxs("div",{className:vh,children:[Q.jsx(Zo,{htmlFor:I,children:"Name"}),Q.jsx(Ad,{id:I,value:i,style:{width:"100%"},size:"large",onChange:k})]}),Q.jsxs("div",{className:vh,children:[Q.jsx(Zo,{htmlFor:j,children:"Chat user name"}),Q.jsx(Ad,{id:j,value:s,style:{width:"100%"},size:"large",onChange:y})]}),Q.jsxs("div",{className:vh,children:[Q.jsx(Zo,{htmlFor:K,children:"Chat user avatar"}),Q.jsx(QN,{name:"chatUserAvatar",onFileChange:F,value:u})]}),Q.jsxs("div",{className:vh,children:[Q.jsx(Zo,{htmlFor:H,children:"Chat bot name"}),Q.jsx(Ad,{id:H,value:h,style:{width:"100%"},size:"large",onChange:C})]}),Q.jsxs("div",{className:vh,children:[Q.jsx(Zo,{htmlFor:U,children:"Chat bot avatar"}),Q.jsx(QN,{name:"chatBotAvatar",onFileChange:A,value:m})]})]}),Q.jsxs(P_,{children:[Q.jsx(O0,{disableButtonEnhancement:!0,children:Q.jsx(En,{size:"large",appearance:"secondary",onClick:()=>n(!1),children:"Close"})}),Q.jsx(En,{size:"large",appearance:"primary",onClick:P,children:"Update"})]})]})})}),Q.jsx(Kv,{modalType:"alert",open:r,onOpenChange:(ve,fe)=>{o(fe.open)},children:Q.jsx(Qv,{children:Q.jsxs(Vv,{children:[Q.jsx(Yv,{children:"Delete the chat"}),Q.jsx(Xv,{children:"This chat will no longer appear here. Also all the messages in this chat will be deleted."}),Q.jsxs(P_,{children:[Q.jsx(O0,{disableButtonEnhancement:!0,children:Q.jsx(En,{appearance:"secondary",children:"Close"})}),Q.jsx(En,{appearance:"primary",onClick:_e,children:"Delete"})]})]})})})]})},oxe=e=>{var i,a,s,l,u;const t={},n=(l=(s=(a=(i=e.paths["/score"])==null?void 0:i.post)==null?void 0:a.requestBody)==null?void 0:s.content)==null?void 0:l["application/json"],r=(u=n==null?void 0:n.schema)==null?void 0:u.properties;if(!r||Object.keys(r).length===0)return{inputs:t,isChatHistoryExist:!1};const o=Object.keys(r).includes(Lc);return Object.keys(r).filter(d=>d!==Lc).forEach(d=>{var h,p;t[d]={type:r[d].type,sample:(h=n==null?void 0:n.example)==null?void 0:h[d],value:((p=n==null?void 0:n.example)==null?void 0:p[d])??""}}),{inputs:t,isChatHistoryExist:o}},ixe=()=>{const{isLoading:e,data:t}=lpe({url:"/swagger.json",method:"GET"}),{inputs:n,isChatHistoryExist:r}=T.useMemo(()=>t!=null&&t.data?oxe(t.data):{inputs:{},isChatHistoryExist:!1},[t]),o=T.useMemo(()=>{var a;const i=((a=t==null?void 0:t.data)==null?void 0:a.info)??{};return{name:i["x-flow-name"]??"Prompt flow",version:i.version??""}},[t]);return{isLoading:e,inputs:n,appInfo:o,isChatHistoryExist:r}},axe=()=>{const{setAppInfo:e}=T.useContext(eo),{inputs:t,appInfo:n,isChatHistoryExist:r}=ixe();return khe(n),T.useEffect(()=>{e(n)},[n]),Q.jsxs(wR,{horizontal:!0,style:{height:"100vh"},children:[Q.jsx(rxe,{}),Q.jsx("div",{style:{flex:1,width:"100%",overflow:"hidden"},children:Q.jsx(Y8e,{scoreInputs:t,appInfo:n,isChatHistoryExist:r})})]})},sxe=OT({container:{width:"100%",height:"100%",display:"flex",alignItems:"center",justifyContent:"center"}}),lxe=()=>{const e=sxe();return Q.jsx("div",{className:e.container,children:Q.jsx(TD,{label:"Loading..."})})};class il{static get(t){const n=localStorage.getItem(t);return n===null?null:JSON.parse(n)}static set(t,n){localStorage.setItem(t,JSON.stringify(n))}}const uxe=()=>{const[e,t]=T.useState(new Map),[n,r]=T.useState(!1),[o,i]=T.useState({}),[a,s]=T.useState({}),l=T.useRef(""),[u,d]=T.useState(new Map),[h,p]=fxe(),[m,v]=cxe(),[_,b]=dxe(),[E,w]=T.useState([]),k=T.useRef(),y=T.useRef(),F=T.useRef(),C=T.useMemo(()=>cp(o.name,o.version),[o.name,o.version]);return T.useMemo(()=>({appInfo:o,setAppInfo:i,chatStoreName:C,currentMessageNavIdRef:l,isDark:_,setIsDark:b,isDisableChatHistory:h,setIsDisableChatHistory:p,messages:e,setMessages:t,isChatHistoryExist:n,setIsChatHistoryExist:r,chatHistory:u,setChatHistory:d,viewMode:m,setViewMode:v,editMessageHandlerRef:k,chatDBRef:y,chatStoreRef:F,navList:E,setNavList:w,appConfig:a,setAppConfig:s}),[_,b,C,h,p,m,v,e,u,o,E,a])},cxe=()=>{const[e,t]=T.useState(()=>il.get("viewMode")??Js.Normal),n=T.useCallback(r=>{typeof r=="function"?t(o=>{const i=r(o);return il.set("viewMode",i),i}):(t(r),il.set("viewMode",r))},[]);return[e,n]},fxe=()=>{const[e,t]=T.useState(()=>il.get("isDisableChatHistory")??!1),n=T.useCallback(r=>{typeof r=="function"?t(o=>{const i=r(o);return il.set("isDisableChatHistory",i),i}):(il.set("isDisableChatHistory",r),t(r))},[]);return[e,n]},dxe=()=>{const[e,t]=T.useState(()=>il.get("isDark")??!1),n=T.useCallback(r=>{typeof r=="function"?t(o=>{const i=r(o);return il.set("isDark",i),i}):(t(r),il.set("isDark",r))},[]);return[e,n]},hxe=()=>{const e=uxe(),t=T.useMemo(()=>e.isDark?oae:eae,[e.isDark]);return Q.jsx(A1e,{client:P1e,children:Q.jsx(eo.Provider,{value:e,children:Q.jsx(ny,{theme:t,style:{width:"100%"},children:Q.jsx(T.Suspense,{fallback:Q.jsx(lxe,{}),children:Q.jsx(axe,{})})})})})};pte();LB.render(Q.jsx(hxe,{}),document.getElementById("root"))});export default pxe();
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/extension/azureml_extension.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json import os import re from promptflow._sdk._serving._errors import InvalidConnectionData, MissingConnectionProvider from promptflow._sdk._serving.extension.default_extension import AppExtension from promptflow._sdk._serving.monitor.data_collector import FlowDataCollector from promptflow._sdk._serving.monitor.flow_monitor import FlowMonitor from promptflow._sdk._serving.monitor.metrics import MetricsRecorder from promptflow._sdk._serving.utils import decode_dict, get_pf_serving_env, normalize_connection_name from promptflow._utils.retry_utils import retry from promptflow._version import VERSION from promptflow.contracts.flow import Flow USER_AGENT = f"promptflow-cloud-serving/{VERSION}" AML_DEPLOYMENT_RESOURCE_ID_REGEX = "/subscriptions/(.*)/resourceGroups/(.*)/providers/Microsoft.MachineLearningServices/workspaces/(.*)/onlineEndpoints/(.*)/deployments/(.*)" # noqa: E501 AML_CONNECTION_PROVIDER_TEMPLATE = "azureml:/subscriptions/{}/resourceGroups/{}/providers/Microsoft.MachineLearningServices/workspaces/{}" # noqa: E501 class AzureMLExtension(AppExtension): """AzureMLExtension is used to create extension for azureml serving.""" def __init__(self, logger, **kwargs): super().__init__(logger=logger, **kwargs) self.logger = logger # parse promptflow project path project_path: str = get_pf_serving_env("PROMPTFLOW_PROJECT_PATH") if not project_path: model_dir = os.getenv("AZUREML_MODEL_DIR", ".") model_rootdir = os.listdir(model_dir)[0] self.model_name = model_rootdir project_path = os.path.join(model_dir, model_rootdir) self.model_root_path = project_path # mlflow support in base extension self.project_path = self._get_mlflow_project_path(project_path) # initialize connections or connection provider # TODO: to be deprecated, remove in next major version self.connections = self._get_env_connections_if_exist() self.endpoint_name: str = None self.deployment_name: str = None self.connection_provider = None self.credential = _get_managed_identity_credential_with_retry() if len(self.connections) == 0: self._initialize_connection_provider() # initialize metrics common dimensions if exist self.common_dimensions = {} if self.endpoint_name: self.common_dimensions["endpoint"] = self.endpoint_name if self.deployment_name: self.common_dimensions["deployment"] = self.deployment_name env_dimensions = self._get_common_dimensions_from_env() self.common_dimensions.update(env_dimensions) # initialize flow monitor data_collector = FlowDataCollector(self.logger) metrics_recorder = self._get_metrics_recorder() self.flow_monitor = FlowMonitor( self.logger, self.get_flow_name(), data_collector, metrics_recorder=metrics_recorder ) def get_flow_project_path(self) -> str: return self.project_path def get_flow_name(self) -> str: return os.path.basename(self.model_root_path) def get_connection_provider(self) -> str: return self.connection_provider def get_blueprints(self): return self._get_default_blueprints() def get_flow_monitor(self) -> FlowMonitor: return self.flow_monitor def get_override_connections(self, flow: Flow) -> (dict, dict): connection_names = flow.get_connection_names() connections = {} connections_name_overrides = {} for connection_name in connection_names: # replace " " with "_" in connection name normalized_name = normalize_connection_name(connection_name) if normalized_name in os.environ: override_conn = os.environ[normalized_name] data_override = False # try load connection as a json try: # data override conn_data = json.loads(override_conn) data_override = True except ValueError: # name override self.logger.debug(f"Connection value is not json, enable name override for {connection_name}.") connections_name_overrides[connection_name] = override_conn if data_override: try: # try best to convert to connection, this is only for azureml deployment. from promptflow.azure.operations._arm_connection_operations import ArmConnectionOperations conn = ArmConnectionOperations._convert_to_connection_dict(connection_name, conn_data) connections[connection_name] = conn except Exception as e: self.logger.warn(f"Failed to convert connection data to connection: {e}") raise InvalidConnectionData(connection_name) if len(connections_name_overrides) > 0: self.logger.info(f"Connection name overrides: {connections_name_overrides}") if len(connections) > 0: self.logger.info(f"Connections data overrides: {connections.keys()}") self.connections.update(connections) return self.connections, connections_name_overrides def raise_ex_on_invoker_initialization_failure(self, ex: Exception): from promptflow.azure.operations._arm_connection_operations import UserAuthenticationError # allow lazy authentication for UserAuthenticationError return not isinstance(ex, UserAuthenticationError) def get_user_agent(self) -> str: return USER_AGENT def get_metrics_common_dimensions(self): return self.common_dimensions def get_credential(self): return self.credential def _get_env_connections_if_exist(self): # For local test app connections will be set. connections = {} env_connections = get_pf_serving_env("PROMPTFLOW_ENCODED_CONNECTIONS") if env_connections: connections = decode_dict(env_connections) return connections def _get_metrics_recorder(self): # currently only support exporting it to azure monitor(application insights) # TODO: add support for dynamic loading thus user can customize their own exporter. custom_dimensions = self.get_metrics_common_dimensions() try: from azure.monitor.opentelemetry.exporter import AzureMonitorMetricExporter from opentelemetry.sdk.metrics.export import PeriodicExportingMetricReader # check whether azure monitor instrumentation key is set instrumentation_key = os.getenv("AML_APP_INSIGHTS_KEY") or os.getenv("APPINSIGHTS_INSTRUMENTATIONKEY") if instrumentation_key: self.logger.info("Initialize metrics recorder with azure monitor metrics exporter...") exporter = AzureMonitorMetricExporter(connection_string=f"InstrumentationKey={instrumentation_key}") reader = PeriodicExportingMetricReader(exporter=exporter, export_interval_millis=60000) return MetricsRecorder(self.logger, reader=reader, common_dimensions=custom_dimensions) else: self.logger.info("Azure monitor metrics exporter is not enabled, metrics will not be collected.") except ImportError: self.logger.warning("No metrics exporter module found, metrics will not be collected.") return None def _initialize_connection_provider(self): # parse connection provider self.connection_provider = get_pf_serving_env("PROMPTFLOW_CONNECTION_PROVIDER") if not self.connection_provider: pf_override = os.getenv("PRT_CONFIG_OVERRIDE", None) if pf_override: env_conf = pf_override.split(",") env_conf_list = [setting.split("=") for setting in env_conf] settings = {setting[0]: setting[1] for setting in env_conf_list} self.subscription_id = settings.get("deployment.subscription_id", None) self.resource_group = settings.get("deployment.resource_group", None) self.workspace_name = settings.get("deployment.workspace_name", None) self.endpoint_name = settings.get("deployment.endpoint_name", None) self.deployment_name = settings.get("deployment.deployment_name", None) else: deploy_resource_id = os.getenv("AML_DEPLOYMENT_RESOURCE_ID", None) if deploy_resource_id: match_result = re.match(AML_DEPLOYMENT_RESOURCE_ID_REGEX, deploy_resource_id) if len(match_result.groups()) == 5: self.subscription_id = match_result.group(1) self.resource_group = match_result.group(2) self.workspace_name = match_result.group(3) self.endpoint_name = match_result.group(4) self.deployment_name = match_result.group(5) else: # raise exception if not found any valid connection provider setting raise MissingConnectionProvider( message="Missing connection provider, please check whether 'PROMPTFLOW_CONNECTION_PROVIDER' " "is in your environment variable list." ) # noqa: E501 self.connection_provider = AML_CONNECTION_PROVIDER_TEMPLATE.format( self.subscription_id, self.resource_group, self.workspace_name ) # noqa: E501 def _get_managed_identity_credential_with_retry(**kwargs): from azure.identity import ManagedIdentityCredential class ManagedIdentityCredentialWithRetry(ManagedIdentityCredential): @retry(Exception) def get_token(self, *scopes, **kwargs): return super().get_token(*scopes, **kwargs) return ManagedIdentityCredentialWithRetry(**kwargs)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/extension/extension_factory.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from enum import Enum from promptflow._sdk._serving.extension.default_extension import AppExtension class ExtensionType(Enum): """Extension type used to identify which extension to load in serving app.""" Default = "local" AzureML = "azureml" class ExtensionFactory: """ExtensionFactory is used to create extension based on extension type.""" @staticmethod def create_extension(logger, **kwargs) -> AppExtension: """Create extension based on extension type.""" extension_type_str = kwargs.get("extension_type", ExtensionType.Default.value) if not extension_type_str: extension_type_str = ExtensionType.Default.value extension_type = ExtensionType(extension_type_str.lower()) if extension_type == ExtensionType.AzureML: from promptflow._sdk._serving.extension.azureml_extension import AzureMLExtension return AzureMLExtension(logger=logger, **kwargs) else: from promptflow._sdk._serving.extension.default_extension import DefaultAppExtension return DefaultAppExtension(logger=logger, **kwargs)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/extension/default_extension.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import json import os from abc import ABC, abstractmethod from pathlib import Path from promptflow._constants import DEFAULT_ENCODING from promptflow._sdk._configuration import Configuration from promptflow._sdk._serving.blueprint.monitor_blueprint import construct_monitor_blueprint from promptflow._sdk._serving.blueprint.static_web_blueprint import construct_staticweb_blueprint from promptflow._sdk._serving.monitor.flow_monitor import FlowMonitor from promptflow._utils.yaml_utils import load_yaml from promptflow._version import VERSION from promptflow.contracts.flow import Flow USER_AGENT = f"promptflow-local-serving/{VERSION}" DEFAULT_STATIC_PATH = Path(__file__).parent.parent / "static" class AppExtension(ABC): def __init__(self, logger, **kwargs): self.logger = logger @abstractmethod def get_flow_project_path(self) -> str: """Get flow project path.""" pass @abstractmethod def get_flow_name(self) -> str: """Get flow name.""" pass @abstractmethod def get_connection_provider(self) -> str: """Get connection provider.""" pass @abstractmethod def get_blueprints(self): """Get blueprints for current extension.""" pass def get_override_connections(self, flow: Flow) -> (dict, dict): """ Get override connections for current extension. :param flow: The flow to execute. :type flow: ~promptflow._sdk.entities._flow.Flow :return: The override connections, first dict is for connection data override, second dict is for connection name override. # noqa: E501 :rtype: (dict, dict) """ return {}, {} def raise_ex_on_invoker_initialization_failure(self, ex: Exception): """ whether to raise exception when initializing flow invoker failed. :param ex: The exception when initializing flow invoker. :type ex: Exception :return: Whether to raise exception when initializing flow invoker failed. """ return True def get_user_agent(self) -> str: """Get user agent used for current extension.""" return USER_AGENT def get_credential(self): """Get credential for current extension.""" return None def get_metrics_common_dimensions(self): """Get common dimensions for metrics if exist.""" return self._get_common_dimensions_from_env() def get_flow_monitor(self) -> FlowMonitor: """Get flow monitor for current extension.""" # default no data collector, no app insights metric exporter return FlowMonitor(self.logger, self.get_flow_name(), None, metrics_recorder=None) def _get_mlflow_project_path(self, project_path: str): # check whether it's mlflow model mlflow_metadata_file = os.path.join(project_path, "MLmodel") if os.path.exists(mlflow_metadata_file): with open(mlflow_metadata_file, "r", encoding=DEFAULT_ENCODING) as fin: mlflow_metadata = load_yaml(fin) flow_entry = mlflow_metadata.get("flavors", {}).get("promptflow", {}).get("entry") if mlflow_metadata: dag_path = os.path.join(project_path, flow_entry) return str(Path(dag_path).parent.absolute()) return project_path def _get_common_dimensions_from_env(self): common_dimensions_str = os.getenv("PF_SERVING_METRICS_COMMON_DIMENSIONS", None) if common_dimensions_str: try: common_dimensions = json.loads(common_dimensions_str) return common_dimensions except Exception as ex: self.logger.warn(f"Failed to parse common dimensions with value={common_dimensions_str}: {ex}") return {} def _get_default_blueprints(self, static_folder=None): static_web_blueprint = construct_staticweb_blueprint(static_folder) monitor_print = construct_monitor_blueprint(self.get_flow_monitor()) return [static_web_blueprint, monitor_print] class DefaultAppExtension(AppExtension): """default app extension for local serve.""" def __init__(self, logger, **kwargs): self.logger = logger static_folder = kwargs.get("static_folder", None) self.static_folder = static_folder if static_folder else DEFAULT_STATIC_PATH logger.info(f"Static_folder: {self.static_folder}") app_config = kwargs.get("config", None) or {} pf_config = Configuration(overrides=app_config) logger.info(f"Promptflow config: {pf_config}") self.connection_provider = pf_config.get_connection_provider() def get_flow_project_path(self) -> str: return os.getenv("PROMPTFLOW_PROJECT_PATH", ".") def get_flow_name(self) -> str: project_path = self.get_flow_project_path() return Path(project_path).stem def get_connection_provider(self) -> str: return self.connection_provider def get_blueprints(self): return self._get_default_blueprints(self.static_folder)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/extension/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/monitor/flow_monitor.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import time from promptflow._sdk._serving.monitor.data_collector import FlowDataCollector from promptflow._sdk._serving.monitor.streaming_monitor import StreamingMonitor from promptflow._sdk._serving.monitor.metrics import MetricsRecorder, ResponseType from promptflow._sdk._serving.utils import streaming_response_required, get_cost_up_to_now from promptflow._sdk._serving.flow_result import FlowResult from promptflow._utils.exception_utils import ErrorResponse from flask import request, g class FlowMonitor: """FlowMonitor is used to collect metrics & data for promptflow serving.""" def __init__(self, logger, default_flow_name, data_collector: FlowDataCollector, metrics_recorder: MetricsRecorder): self.data_collector = data_collector self.metrics_recorder = metrics_recorder self.logger = logger self.flow_name = default_flow_name def setup_streaming_monitor_if_needed(self, response_creator, data, output): g.streaming = response_creator.has_stream_field and response_creator.text_stream_specified_explicitly # set streaming callback functions if the response is streaming if g.streaming: streaming_monitor = StreamingMonitor( self.logger, flow_id=g.get("flow_id", self.flow_name), start_time=g.start_time, inputs=data, outputs=output, req_id=g.get("req_id", None), streaming_field_name=response_creator.stream_field_name, metric_recorder=self.metrics_recorder, data_collector=self.data_collector, ) response_creator._on_stream_start = streaming_monitor.on_stream_start response_creator._on_stream_end = streaming_monitor.on_stream_end response_creator._on_stream_event = streaming_monitor.on_stream_event self.logger.info(f"Finish stream callback setup for flow with streaming={g.streaming}.") else: self.logger.info("Flow does not enable streaming response.") def handle_error(self, ex: Exception, resp_code: int): if self.metrics_recorder: flow_id = g.get("flow_id", self.flow_name) err_code = ErrorResponse.from_exception(ex).innermost_error_code streaming = g.get("streaming", False) self.metrics_recorder.record_flow_request(flow_id, resp_code, err_code, streaming) def start_monitoring(self): g.start_time = time.time() g.streaming = streaming_response_required() g.req_id = request.headers.get("x-request-id", None) self.logger.info(f"Start monitoring new request, request_id: {g.req_id}") def finish_monitoring(self, resp_status_code): data = g.get("data", None) flow_result: FlowResult = g.get("flow_result", None) req_id = g.get("req_id", None) flow_id = g.get("flow_id", self.flow_name) # collect non-streaming flow request/response data if self.data_collector and data and flow_result and flow_result.output and not g.streaming: self.data_collector.collect_flow_data(data, flow_result.output, req_id) if self.metrics_recorder: if flow_result: self.metrics_recorder.record_tracing_metrics(flow_result.run_info, flow_result.node_run_infos) err_code = g.get("err_code", "None") self.metrics_recorder.record_flow_request(flow_id, resp_status_code, err_code, g.streaming) # streaming metrics will be recorded in the streaming callback func if not g.streaming: latency = get_cost_up_to_now(g.start_time) self.metrics_recorder.record_flow_latency( flow_id, resp_status_code, g.streaming, ResponseType.Default.value, latency ) self.logger.info(f"Finish monitoring request, request_id: {req_id}.")
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/monitor/streaming_monitor.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from promptflow._sdk._serving.utils import get_cost_up_to_now from promptflow._sdk._serving.monitor.metrics import ResponseType class StreamingMonitor: """StreamingMonitor is used to collect metrics & data for streaming response.""" def __init__(self, logger, flow_id: str, start_time: float, inputs: dict, outputs: dict, req_id: str, streaming_field_name: str, metric_recorder, data_collector, ) -> None: self.logger = logger self.flow_id = flow_id self.start_time = start_time self.inputs = inputs self.outputs = outputs self.streaming_field_name = streaming_field_name self.req_id = req_id self.metric_recorder = metric_recorder self.data_collector = data_collector self.response_message = [] def on_stream_start(self): """stream start call back function, record flow latency when first byte received.""" self.logger.info("start streaming response...") if self.metric_recorder: duration = get_cost_up_to_now(self.start_time) self.metric_recorder.record_flow_latency(self.flow_id, 200, True, ResponseType.FirstByte.value, duration) def on_stream_end(self, streaming_resp_duration: float): """stream end call back function, record flow latency and streaming response data when last byte received.""" if self.metric_recorder: duration = get_cost_up_to_now(self.start_time) self.metric_recorder.record_flow_latency(self.flow_id, 200, True, ResponseType.LastByte.value, duration) self.metric_recorder.record_flow_streaming_response_duration(self.flow_id, streaming_resp_duration) if self.data_collector: response_content = "".join(self.response_message) if self.streaming_field_name in self.outputs: self.outputs[self.streaming_field_name] = response_content self.data_collector.collect_flow_data(self.inputs, self.outputs, self.req_id) self.logger.info("finish streaming response.") def on_stream_event(self, message: str): """stream event call back function, record streaming response data chunk.""" self.response_message.append(message)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/monitor/metrics.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from enum import Enum from typing import Dict, Sequence, Set, List, Any from promptflow._utils.exception_utils import ErrorResponse from promptflow.contracts.run_info import FlowRunInfo, RunInfo, Status # define metrics dimension keys FLOW_KEY = "flow" RUN_STATUS_KEY = "run_status" NODE_KEY = "node" LLM_ENGINE_KEY = "llm_engine" TOKEN_TYPE_KEY = "token_type" RESPONSE_CODE_KEY = "response_code" EXCEPTION_TYPE_KEY = "exception" STREAMING_KEY = "streaming" API_CALL_KEY = "api_call" RESPONSE_TYPE_KEY = "response_type" # firstbyte, lastbyte, default HISTOGRAM_BOUNDARIES: Sequence[float] = ( 1.0, 5.0, 10.0, 25.0, 50.0, 75.0, 100.0, 250.0, 500.0, 750.0, 1000.0, 2500.0, 5000.0, 7500.0, 10000.0, 25000.0, 50000.0, 75000.0, 100000.0, 300000.0, ) class ResponseType(Enum): # latency from receiving the request to sending the first byte of response, only applicable to streaming flow FirstByte = "firstbyte" # latency from receiving the request to sending the last byte of response, only applicable to streaming flow LastByte = "lastbyte" # latency from receiving the request to sending the whole response, only applicable to non-streaming flow Default = "default" class LLMTokenType(Enum): PromptTokens = "prompt_tokens" CompletionTokens = "completion_tokens" try: from opentelemetry import metrics from opentelemetry.metrics import set_meter_provider from opentelemetry.sdk.metrics import MeterProvider from opentelemetry.sdk.metrics.view import ExplicitBucketHistogramAggregation, SumAggregation, View # define meter meter = metrics.get_meter_provider().get_meter("Promptflow Standard Metrics") # define metrics token_consumption = meter.create_counter("Token_Consumption") flow_latency = meter.create_histogram("Flow_Latency") node_latency = meter.create_histogram("Node_Latency") flow_request = meter.create_counter("Flow_Request") remote_api_call_latency = meter.create_histogram("RPC_Latency") remote_api_call_request = meter.create_counter("RPC_Request") node_request = meter.create_counter("Node_Request") # metrics for streaming streaming_response_duration = meter.create_histogram("Flow_Streaming_Response_Duration") # define metrics views # token view token_view = View( instrument_name="Token_Consumption", description="", attribute_keys={FLOW_KEY, NODE_KEY, LLM_ENGINE_KEY, TOKEN_TYPE_KEY}, aggregation=SumAggregation(), ) # latency view flow_latency_view = View( instrument_name="Flow_Latency", description="", attribute_keys={FLOW_KEY, RESPONSE_CODE_KEY, STREAMING_KEY, RESPONSE_TYPE_KEY}, aggregation=ExplicitBucketHistogramAggregation(boundaries=HISTOGRAM_BOUNDARIES), ) node_latency_view = View( instrument_name="Node_Latency", description="", attribute_keys={FLOW_KEY, NODE_KEY, RUN_STATUS_KEY}, aggregation=ExplicitBucketHistogramAggregation(boundaries=HISTOGRAM_BOUNDARIES), ) flow_streaming_response_duration_view = View( instrument_name="Flow_Streaming_Response_Duration", description="during between sending the first byte and last byte of the response, only for streaming flow", attribute_keys={FLOW_KEY}, aggregation=ExplicitBucketHistogramAggregation(boundaries=HISTOGRAM_BOUNDARIES), ) # request view request_view = View( instrument_name="Flow_Request", description="", attribute_keys={FLOW_KEY, RESPONSE_CODE_KEY, STREAMING_KEY, EXCEPTION_TYPE_KEY}, aggregation=SumAggregation(), ) node_request_view = View( instrument_name="Node_Request", description="", attribute_keys={FLOW_KEY, NODE_KEY, RUN_STATUS_KEY, EXCEPTION_TYPE_KEY}, aggregation=SumAggregation(), ) # Remote API call view remote_api_call_latency_view = View( instrument_name="RPC_Latency", description="", attribute_keys={FLOW_KEY, NODE_KEY, API_CALL_KEY}, aggregation=ExplicitBucketHistogramAggregation(boundaries=HISTOGRAM_BOUNDARIES), ) remote_api_call_request_view = View( instrument_name="RPC_Request", description="", attribute_keys={FLOW_KEY, NODE_KEY, API_CALL_KEY, EXCEPTION_TYPE_KEY}, aggregation=SumAggregation(), ) metrics_enabled = True except ImportError: metrics_enabled = False class MetricsRecorder(object): """OpenTelemetry Metrics Recorder""" def __init__(self, logger, reader=None, common_dimensions: Dict[str, str] = None) -> None: """initialize metrics recorder :param logger: logger :type logger: Logger :param reader: metric reader :type reader: opentelemetry.sdk.metrics.export.MetricReader :param common_dimensions: common dimensions for all metrics :type common_dimensions: Dict[str, str] """ self.logger = logger if not metrics_enabled: logger.warning("OpenTelemetry metric is not enabled, metrics will not be recorded." + "If you want to collect metrics, please enable 'azureml-serving' extra requirement " + "for promptflow: 'pip install promptflow[azureml-serving]'") return self.common_dimensions = common_dimensions or {} self.reader = reader dimension_keys = {key for key in common_dimensions} self._config_common_monitor(dimension_keys, reader) logger.info("OpenTelemetry metric is enabled, metrics will be recorded.") def record_flow_request(self, flow_id: str, response_code: int, exception: str, streaming: bool): if not metrics_enabled: return try: flow_request.add( 1, { FLOW_KEY: flow_id, RESPONSE_CODE_KEY: str(response_code), EXCEPTION_TYPE_KEY: exception, STREAMING_KEY: str(streaming), **self.common_dimensions, }, ) except Exception as e: self.logger.warning("failed to record flow request metrics: %s", e) def record_flow_latency( self, flow_id: str, response_code: int, streaming: bool, response_type: str, duration: float ): if not metrics_enabled: return try: flow_latency.record( duration, { FLOW_KEY: flow_id, RESPONSE_CODE_KEY: str(response_code), STREAMING_KEY: str(streaming), RESPONSE_TYPE_KEY: response_type, **self.common_dimensions, }, ) except Exception as e: self.logger.warning("failed to record flow latency metrics: %s", e) def record_flow_streaming_response_duration(self, flow_id: str, duration: float): if not metrics_enabled: return try: streaming_response_duration.record(duration, {FLOW_KEY: flow_id, **self.common_dimensions}) except Exception as e: self.logger.warning("failed to record streaming duration metrics: %s", e) def record_tracing_metrics(self, flow_run: FlowRunInfo, node_runs: Dict[str, RunInfo]): if not metrics_enabled: return try: for _, run in node_runs.items(): flow_id = flow_run.flow_id if flow_run is not None else "default" if len(run.system_metrics) > 0: duration = run.system_metrics.get("duration", None) if duration is not None: duration = duration * 1000 node_latency.record( duration, { FLOW_KEY: flow_id, NODE_KEY: run.node, RUN_STATUS_KEY: run.status.value, **self.common_dimensions, }, ) # openai token metrics inputs = run.inputs or {} engine = inputs.get("deployment_name") or "" for token_type in [LLMTokenType.PromptTokens.value, LLMTokenType.CompletionTokens.value]: count = run.system_metrics.get(token_type, None) if count: token_consumption.add( count, { FLOW_KEY: flow_id, NODE_KEY: run.node, LLM_ENGINE_KEY: engine, TOKEN_TYPE_KEY: token_type, **self.common_dimensions, }, ) # record node request metric err = None if run.status != Status.Completed: err = "unknown" if isinstance(run.error, dict): err = self._get_exact_error(run.error) elif isinstance(run.error, str): err = run.error node_request.add( 1, { FLOW_KEY: flow_id, NODE_KEY: run.node, RUN_STATUS_KEY: run.status.value, EXCEPTION_TYPE_KEY: err, **self.common_dimensions, }, ) if run.api_calls and len(run.api_calls) > 0: for api_call in run.api_calls: # since first layer api_call is the node call itself, we ignore them here api_calls: List[Dict[str, Any]] = api_call.get("children", None) if api_calls is None: continue self._record_api_call_metrics(flow_id, run.node, api_calls) except Exception as e: self.logger.warning(f"failed to record metrics: {e}, flow_run: {flow_run}, node_runs: {node_runs}") def _record_api_call_metrics(self, flow_id, node, api_calls: List[Dict[str, Any]], prefix: str = None): if api_calls and len(api_calls) > 0: for api_call in api_calls: cur_name = api_call.get("name") api_name = f"{prefix}_{cur_name}" if prefix else cur_name # api-call latency metrics # sample data: {"start_time":1688462182.744916, "end_time":1688462184.280989} start_time = api_call.get("start_time", None) end_time = api_call.get("end_time", None) if start_time and end_time: api_call_latency_ms = (end_time - start_time) * 1000 remote_api_call_latency.record( api_call_latency_ms, { FLOW_KEY: flow_id, NODE_KEY: node, API_CALL_KEY: api_name, **self.common_dimensions, }, ) # remote api call request metrics err = api_call.get("error") or {} if isinstance(err, dict): exception_type = self._get_exact_error(err) else: exception_type = err remote_api_call_request.add( 1, { FLOW_KEY: flow_id, NODE_KEY: node, API_CALL_KEY: api_name, EXCEPTION_TYPE_KEY: exception_type, **self.common_dimensions, }, ) child_api_calls = api_call.get("children", None) if child_api_calls: self._record_api_call_metrics(flow_id, node, child_api_calls, api_name) def _get_exact_error(self, err: Dict): error_response = ErrorResponse.from_error_dict(err) return error_response.innermost_error_code # configure monitor, by default only expose prometheus metrics def _config_common_monitor(self, common_keys: Set[str] = {}, reader=None): metrics_views = [ token_view, flow_latency_view, node_latency_view, request_view, remote_api_call_latency_view, remote_api_call_request_view, ] for view in metrics_views: view._attribute_keys.update(common_keys) readers = [] if reader: readers.append(reader) meter_provider = MeterProvider( metric_readers=readers, views=metrics_views, ) set_meter_provider(meter_provider)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/monitor/data_collector.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- class FlowDataCollector: """FlowDataCollector is used to collect flow data via MDC for monitoring.""" def __init__(self, logger): self.logger = logger self._init_success = self._init_data_collector() logger.info(f"Mdc init status: {self._init_success}") def _init_data_collector(self) -> bool: """init data collector.""" self.logger.info("Init mdc...") try: from azureml.ai.monitoring import Collector self.inputs_collector = Collector(name="model_inputs") self.outputs_collector = Collector(name="model_outputs") return True except ImportError as e: self.logger.warn(f"Load mdc related module failed: {e}") return False except Exception as e: self.logger.warn(f"Init mdc failed: {e}") return False def collect_flow_data(self, input: dict, output: dict, req_id: str = None, client_req_id: str = None): """collect flow data via MDC for monitoring.""" if not self._init_success: return try: import pandas as pd from azureml.ai.monitoring.context import BasicCorrelationContext # build context ctx = BasicCorrelationContext(id=req_id) # collect inputs coll_input = {k: [v] for k, v in input.items()} input_df = pd.DataFrame(coll_input) self.inputs_collector.collect(input_df, ctx) # collect outputs coll_output = {k: [v] for k, v in output.items()} output_df = pd.DataFrame(coll_output) # collect outputs data, pass in correlation_context so inputs and outputs data can be correlated later self.outputs_collector.collect(output_df, ctx) except ImportError as e: self.logger.warn(f"Load mdc related module failed: {e}") except Exception as e: self.logger.warn(f"Collect flow data failed: {e}")
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/_serving/monitor/__init__.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- __path__ = __import__("pkgutil").extend_path(__path__, __name__) # type: ignore
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_flow_context_resolver.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from functools import lru_cache from os import PathLike from pathlib import Path from typing import Dict from promptflow._sdk._constants import NODES from promptflow._sdk._utils import parse_variant from promptflow._sdk.entities import FlowContext from promptflow._sdk.entities._flow import Flow from promptflow._utils.flow_utils import load_flow_dag from promptflow.contracts.flow import Node from promptflow.exceptions import UserErrorException # Resolve flow context to invoker # Resolve flow according to flow context # Resolve connection, variant, overwrite, store in-memory # create invoker based on resolved flow # cache invoker if flow context not changed (define hash function for flow context). class FlowContextResolver: """Flow context resolver.""" def __init__(self, flow_path: PathLike): from promptflow import PFClient self.flow_path, self.flow_dag = load_flow_dag(flow_path=Path(flow_path)) self.working_dir = Path(self.flow_path).parent.resolve() self.node_name_2_node: Dict[str, Node] = {node["name"]: node for node in self.flow_dag[NODES]} self.client = PFClient() @classmethod @lru_cache def resolve(cls, flow: Flow) -> "FlowInvoker": """Resolve flow to flow invoker.""" resolver = cls(flow_path=flow.path) resolver._resolve(flow_context=flow.context) return resolver._create_invoker(flow=flow, flow_context=flow.context) def _resolve(self, flow_context: FlowContext): """Resolve flow context.""" # TODO(2813319): support node overrides # TODO: define priority of the contexts flow_context._resolve_connections() self._resolve_variant(flow_context=flow_context)._resolve_connections( flow_context=flow_context, )._resolve_overrides(flow_context=flow_context) def _resolve_variant(self, flow_context: FlowContext) -> "FlowContextResolver": """Resolve variant of the flow and store in-memory.""" # TODO: put all varint string parser here if not flow_context.variant: return self else: tuning_node, variant = parse_variant(flow_context.variant) from promptflow._sdk._submitter import overwrite_variant overwrite_variant( flow_dag=self.flow_dag, tuning_node=tuning_node, variant=variant, ) return self def _resolve_connections(self, flow_context: FlowContext) -> "FlowContextResolver": """Resolve connections of the flow and store in-memory.""" from promptflow._sdk._submitter import overwrite_connections overwrite_connections( flow_dag=self.flow_dag, connections=flow_context.connections, working_dir=self.working_dir, ) return self def _resolve_overrides(self, flow_context: FlowContext) -> "FlowContextResolver": """Resolve overrides of the flow and store in-memory.""" from promptflow._sdk._submitter import overwrite_flow overwrite_flow( flow_dag=self.flow_dag, params_overrides=flow_context.overrides, ) return self def _resolve_connection_objs(self, flow_context: FlowContext): # validate connection objs connections = {} for key, connection_obj in flow_context._connection_objs.items(): scrubbed_secrets = connection_obj._get_scrubbed_secrets() if scrubbed_secrets: raise UserErrorException( f"Connection {connection_obj} contains scrubbed secrets with key {scrubbed_secrets.keys()}, " "please make sure connection has decrypted secrets to use in flow execution. " ) connections[key] = connection_obj._to_execution_connection_dict() return connections def _create_invoker(self, flow: Flow, flow_context: FlowContext) -> "FlowInvoker": from promptflow._sdk._serving.flow_invoker import FlowInvoker connections = self._resolve_connection_objs(flow_context=flow_context) # use updated flow dag to create new flow object for invoker resolved_flow = Flow(code=self.working_dir, dag=self.flow_dag) invoker = FlowInvoker( flow=resolved_flow, connections=connections, streaming=flow_context.streaming, ) return invoker
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_flow_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import contextlib import glob import json import os import shutil import subprocess import sys from importlib.metadata import version from os import PathLike from pathlib import Path from typing import Dict, Iterable, List, Tuple, Union from promptflow._constants import LANGUAGE_KEY, FlowLanguage from promptflow._sdk._constants import ( CHAT_HISTORY, DEFAULT_ENCODING, FLOW_TOOLS_JSON_GEN_TIMEOUT, LOCAL_MGMT_DB_PATH, PROMPT_FLOW_DIR_NAME, ) from promptflow._sdk._load_functions import load_flow from promptflow._sdk._submitter import TestSubmitter from promptflow._sdk._submitter.utils import SubmitterHelper from promptflow._sdk._telemetry import ActivityType, TelemetryMixin, monitor_operation from promptflow._sdk._utils import ( _get_additional_includes, _merge_local_code_and_additional_includes, copy_tree_respect_template_and_ignore_file, dump_flow_result, generate_flow_tools_json, generate_random_string, logger, parse_variant, ) from promptflow._sdk.entities._eager_flow import EagerFlow from promptflow._sdk.entities._flow import ProtectedFlow from promptflow._sdk.entities._validation import ValidationResult from promptflow._utils.context_utils import _change_working_dir from promptflow._utils.yaml_utils import dump_yaml, load_yaml from promptflow.exceptions import UserErrorException class FlowOperations(TelemetryMixin): """FlowOperations.""" def __init__(self, client): self._client = client super().__init__() @monitor_operation(activity_name="pf.flows.test", activity_type=ActivityType.PUBLICAPI) def test( self, flow: Union[str, PathLike], *, inputs: dict = None, variant: str = None, node: str = None, environment_variables: dict = None, entry: str = None, **kwargs, ) -> dict: """Test flow or node. :param flow: path to flow directory to test :type flow: Union[str, PathLike] :param inputs: Input data for the flow test :type inputs: dict :param variant: Node & variant name in format of ${node_name.variant_name}, will use default variant if not specified. :type variant: str :param node: If specified it will only test this node, else it will test the flow. :type node: str :param environment_variables: Environment variables to set by specifying a property path and value. Example: {"key1": "${my_connection.api_key}", "key2"="value2"} The value reference to connection keys will be resolved to the actual value, and all environment variables specified will be set into os.environ. :type environment_variables: dict :param entry: Entry function. Required when flow is script. :type entry: str :return: The result of flow or node :rtype: dict """ result = self._test( flow=flow, inputs=inputs, variant=variant, node=node, environment_variables=environment_variables, entry=entry, **kwargs, ) dump_test_result = kwargs.get("dump_test_result", False) if dump_test_result: # Dump flow/node test info flow = load_flow(flow) if node: dump_flow_result(flow_folder=flow.code, node_result=result, prefix=f"flow-{node}.node") else: if variant: tuning_node, node_variant = parse_variant(variant) prefix = f"flow-{tuning_node}-{node_variant}" else: prefix = "flow" dump_flow_result(flow_folder=flow.code, flow_result=result, prefix=prefix) additional_output_path = kwargs.get("detail", None) if additional_output_path: if not dump_test_result: flow = load_flow(flow) if node: # detail and output dump_flow_result( flow_folder=flow.code, node_result=result, prefix=f"flow-{node}.node", custom_path=additional_output_path, ) # log log_src_path = Path(flow.code) / PROMPT_FLOW_DIR_NAME / f"{node}.node.log" log_dst_path = Path(additional_output_path) / f"{node}.node.log" shutil.copy(log_src_path, log_dst_path) else: if variant: tuning_node, node_variant = parse_variant(variant) prefix = f"flow-{tuning_node}-{node_variant}" else: prefix = "flow" # detail and output dump_flow_result( flow_folder=flow.code, flow_result=result, prefix=prefix, custom_path=additional_output_path, ) # log log_src_path = Path(flow.code) / PROMPT_FLOW_DIR_NAME / "flow.log" log_dst_path = Path(additional_output_path) / "flow.log" shutil.copy(log_src_path, log_dst_path) TestSubmitter._raise_error_when_test_failed(result, show_trace=node is not None) return result.output def _test( self, flow: Union[str, PathLike], *, inputs: dict = None, variant: str = None, node: str = None, environment_variables: dict = None, stream_log: bool = True, stream_output: bool = True, allow_generator_output: bool = True, entry: str = None, **kwargs, ): """Test flow or node. :param flow: path to flow directory to test :param inputs: Input data for the flow test :param variant: Node & variant name in format of ${node_name.variant_name}, will use default variant if not specified. :param node: If specified it will only test this node, else it will test the flow. :param environment_variables: Environment variables to set by specifying a property path and value. Example: {"key1": "${my_connection.api_key}", "key2"="value2"} The value reference to connection keys will be resolved to the actual value, and all environment variables specified will be set into os.environ. :param stream_log: Whether streaming the log. :param stream_output: Whether streaming the outputs. :param allow_generator_output: Whether return streaming output when flow has streaming output. :param entry: The entry function, only works when source is a code file. :return: Executor result """ from promptflow._sdk._load_functions import load_flow inputs = inputs or {} flow = load_flow(flow, entry=entry) if isinstance(flow, EagerFlow): if variant or node: logger.warning("variant and node are not supported for eager flow, will be ignored") variant, node = None, None else: if entry: logger.warning("entry is only supported for eager flow, will be ignored") flow.context.variant = variant from promptflow._constants import FlowLanguage from promptflow._sdk._submitter.test_submitter import TestSubmitterViaProxy if flow.language == FlowLanguage.CSharp: with TestSubmitterViaProxy(flow=flow, flow_context=flow.context, client=self._client).init() as submitter: is_chat_flow, chat_history_input_name, _ = self._is_chat_flow(submitter.dataplane_flow) flow_inputs, dependency_nodes_outputs = submitter.resolve_data( node_name=node, inputs=inputs, chat_history_name=chat_history_input_name ) if node: return submitter.node_test( node_name=node, flow_inputs=flow_inputs, dependency_nodes_outputs=dependency_nodes_outputs, environment_variables=environment_variables, stream=True, ) else: return submitter.flow_test( inputs=flow_inputs, environment_variables=environment_variables, stream_log=stream_log, stream_output=stream_output, allow_generator_output=allow_generator_output and is_chat_flow, ) with TestSubmitter(flow=flow, flow_context=flow.context, client=self._client).init() as submitter: if isinstance(flow, EagerFlow): # TODO(2897153): support chat eager flow is_chat_flow, chat_history_input_name = False, None flow_inputs, dependency_nodes_outputs = inputs, None else: is_chat_flow, chat_history_input_name, _ = self._is_chat_flow(submitter.dataplane_flow) flow_inputs, dependency_nodes_outputs = submitter.resolve_data( node_name=node, inputs=inputs, chat_history_name=chat_history_input_name ) if node: return submitter.node_test( node_name=node, flow_inputs=flow_inputs, dependency_nodes_outputs=dependency_nodes_outputs, environment_variables=environment_variables, stream=True, ) else: return submitter.flow_test( inputs=flow_inputs, environment_variables=environment_variables, stream_log=stream_log, stream_output=stream_output, allow_generator_output=allow_generator_output and is_chat_flow, ) @staticmethod def _is_chat_flow(flow): """ Check if the flow is chat flow. Check if chat_history in the flow input and only one chat input and one chat output to determine if it is a chat flow. """ chat_inputs = [item for item in flow.inputs.values() if item.is_chat_input] chat_outputs = [item for item in flow.outputs.values() if item.is_chat_output] chat_history_input_name = next( iter([input_name for input_name, value in flow.inputs.items() if value.is_chat_history]), None ) if ( not chat_history_input_name and CHAT_HISTORY in flow.inputs and flow.inputs[CHAT_HISTORY].is_chat_history is not False ): chat_history_input_name = CHAT_HISTORY is_chat_flow, error_msg = True, "" if len(chat_inputs) != 1: is_chat_flow = False error_msg = "chat flow does not support multiple chat inputs" elif len(chat_outputs) != 1: is_chat_flow = False error_msg = "chat flow does not support multiple chat outputs" elif not chat_history_input_name: is_chat_flow = False error_msg = "chat_history is required in the inputs of chat flow" return is_chat_flow, chat_history_input_name, error_msg @monitor_operation(activity_name="pf.flows._chat", activity_type=ActivityType.INTERNALCALL) def _chat( self, flow, *, inputs: dict = None, variant: str = None, environment_variables: dict = None, **kwargs, ) -> List: """Interact with Chat Flow. Only chat flow supported. :param flow: path to flow directory to chat :param inputs: Input data for the flow to chat :param environment_variables: Environment variables to set by specifying a property path and value. Example: {"key1": "${my_connection.api_key}", "key2"="value2"} The value reference to connection keys will be resolved to the actual value, and all environment variables specified will be set into os.environ. """ from promptflow._sdk._load_functions import load_flow flow = load_flow(flow) flow.context.variant = variant with TestSubmitter(flow=flow, flow_context=flow.context, client=self._client).init() as submitter: is_chat_flow, chat_history_input_name, error_msg = self._is_chat_flow(submitter.dataplane_flow) if not is_chat_flow: raise UserErrorException(f"Only support chat flow in interactive mode, {error_msg}.") info_msg = f"Welcome to chat flow, {submitter.dataplane_flow.name}." print("=" * len(info_msg)) print(info_msg) print("Press Enter to send your message.") print("You can quit with ctrl+C.") print("=" * len(info_msg)) submitter._chat_flow( inputs=inputs, chat_history_name=chat_history_input_name, environment_variables=environment_variables, show_step_output=kwargs.get("show_step_output", False), ) @monitor_operation(activity_name="pf.flows._chat_with_ui", activity_type=ActivityType.INTERNALCALL) def _chat_with_ui(self, script): try: import bs4 # noqa: F401 import streamlit_quill # noqa: F401 from streamlit.web import cli as st_cli except ImportError as ex: raise UserErrorException( f"Please try 'pip install promptflow[executable]' to install dependency, {ex.msg}." ) sys.argv = [ "streamlit", "run", script, "--global.developmentMode=false", "--client.toolbarMode=viewer", "--browser.gatherUsageStats=false", ] st_cli.main() def _build_environment_config(self, flow_dag_path: Path): flow_info = load_yaml(flow_dag_path) # standard env object: # environment: # image: xxx # conda_file: xxx # python_requirements_txt: xxx # setup_sh: xxx # TODO: deserialize dag with structured class here to avoid using so many magic strings env_obj = flow_info.get("environment", {}) env_obj["sdk_version"] = version("promptflow") # version 0.0.1 is the dev version of promptflow if env_obj["sdk_version"] == "0.0.1": del env_obj["sdk_version"] if not env_obj.get("python_requirements_txt", None) and (flow_dag_path.parent / "requirements.txt").is_file(): env_obj["python_requirements_txt"] = "requirements.txt" env_obj["conda_env_name"] = "promptflow-serve" if "conda_file" in env_obj: conda_file = flow_dag_path.parent / env_obj["conda_file"] if conda_file.is_file(): conda_obj = yaml.safe_load(conda_file.read_text()) if "name" in conda_obj: env_obj["conda_env_name"] = conda_obj["name"] return env_obj @classmethod def _refine_connection_name(cls, connection_name: str): return connection_name.replace(" ", "_") def _dump_connection(self, connection, output_path: Path): # connection yaml should be a dict instead of ordered dict connection_dict = connection._to_dict() connection_yaml = { "$schema": f"https://azuremlschemas.azureedge.net/promptflow/" f"latest/{connection.__class__.__name__}.schema.json", **connection_dict, } if connection.type == "Custom": secret_dict = connection_yaml["secrets"] else: secret_dict = connection_yaml connection_var_name = self._refine_connection_name(connection.name) env_var_names = [f"{connection_var_name}_{secret_key}".upper() for secret_key in connection.secrets] for secret_key, secret_env in zip(connection.secrets, env_var_names): secret_dict[secret_key] = "${env:" + secret_env + "}" for key in ["created_date", "last_modified_date"]: if key in connection_yaml: del connection_yaml[key] key_order = ["$schema", "type", "name", "configs", "secrets", "module"] sorted_connection_dict = { key: connection_yaml[key] for key in sorted( connection_yaml.keys(), key=lambda x: (0, key_order.index(x)) if x in key_order else (1, x), ) } with open(output_path, "w", encoding="utf-8") as f: f.write(dump_yaml(sorted_connection_dict)) return env_var_names def _migrate_connections(self, connection_names: List[str], output_dir: Path): from promptflow._sdk._pf_client import PFClient output_dir.mkdir(parents=True, exist_ok=True) local_client = PFClient() connection_paths, env_var_names = [], {} for connection_name in connection_names: connection = local_client.connections.get(name=connection_name, with_secrets=True) connection_var_name = self._refine_connection_name(connection_name) connection_paths.append(output_dir / f"{connection_var_name}.yaml") for env_var_name in self._dump_connection( connection, connection_paths[-1], ): if env_var_name in env_var_names: raise RuntimeError( f"environment variable name conflict: connection {connection_name} and " f"{env_var_names[env_var_name]} on {env_var_name}" ) env_var_names[env_var_name] = connection_name return connection_paths, list(env_var_names.keys()) def _export_flow_connections( self, built_flow_dag_path: Path, *, output_dir: Path, ): """Export flow connections to yaml files. :param built_flow_dag_path: path to built flow dag yaml file. Given this is a built flow, we can assume that the flow involves no additional includes, symlink, or variant. :param output_dir: output directory to export connections """ flow: ProtectedFlow = load_flow(built_flow_dag_path) with _change_working_dir(flow.code): if flow.language == FlowLanguage.CSharp: from promptflow.batch import CSharpExecutorProxy return self._migrate_connections( connection_names=SubmitterHelper.get_used_connection_names( tools_meta=CSharpExecutorProxy.get_tool_metadata( flow_file=flow.flow_dag_path, working_dir=flow.code, ), flow_dag=flow.dag, ), output_dir=output_dir, ) else: # TODO: avoid using executable here from promptflow.contracts.flow import Flow as ExecutableFlow executable = ExecutableFlow.from_yaml(flow_file=flow.path, working_dir=flow.code) return self._migrate_connections( connection_names=executable.get_connection_names(), output_dir=output_dir, ) def _build_flow( self, flow_dag_path: Path, *, output: Union[str, PathLike], tuning_node: str = None, node_variant: str = None, update_flow_tools_json: bool = True, ): # TODO: confirm if we need to import this from promptflow._sdk._submitter import variant_overwrite_context flow_copy_target = Path(output) flow_copy_target.mkdir(parents=True, exist_ok=True) # resolve additional includes and copy flow directory first to guarantee there is a final flow directory # TODO: shall we pop "node_variants" unless keep-variants is specified? with variant_overwrite_context( flow_dag_path, tuning_node=tuning_node, variant=node_variant, drop_node_variants=True, ) as temp_flow: # TODO: avoid copy for twice copy_tree_respect_template_and_ignore_file(temp_flow.code, flow_copy_target) if update_flow_tools_json: generate_flow_tools_json(flow_copy_target) return flow_copy_target / flow_dag_path.name def _export_to_docker( self, flow_dag_path: Path, output_dir: Path, *, env_var_names: List[str], connection_paths: List[Path], flow_name: str, is_csharp_flow: bool = False, ): (output_dir / "settings.json").write_text( data=json.dumps({env_var_name: "" for env_var_name in env_var_names}, indent=2), encoding="utf-8", ) environment_config = self._build_environment_config(flow_dag_path) # TODO: make below strings constants if is_csharp_flow: source = Path(__file__).parent.parent / "data" / "docker_csharp" else: source = Path(__file__).parent.parent / "data" / "docker" copy_tree_respect_template_and_ignore_file( source=source, target=output_dir, render_context={ "env": environment_config, "flow_name": f"{flow_name}-{generate_random_string(6)}", "local_db_rel_path": LOCAL_MGMT_DB_PATH.relative_to(Path.home()).as_posix(), "connection_yaml_paths": list(map(lambda x: x.relative_to(output_dir).as_posix(), connection_paths)), }, ) def _build_as_executable( self, flow_dag_path: Path, output_dir: Path, *, flow_name: str, env_var_names: List[str], ): try: import bs4 # noqa: F401 import PyInstaller # noqa: F401 import streamlit import streamlit_quill # noqa: F401 except ImportError as ex: raise UserErrorException( f"Please try 'pip install promptflow[executable]' to install dependency, {ex.msg}." ) from promptflow.contracts.flow import Flow as ExecutableFlow (output_dir / "settings.json").write_text( data=json.dumps({env_var_name: "" for env_var_name in env_var_names}, indent=2), encoding="utf-8", ) environment_config = self._build_environment_config(flow_dag_path) hidden_imports = [] if ( environment_config.get("python_requirements_txt", None) and (flow_dag_path.parent / "requirements.txt").is_file() ): with open(flow_dag_path.parent / "requirements.txt", "r", encoding="utf-8") as file: file_content = file.read() hidden_imports = file_content.splitlines() runtime_interpreter_path = (Path(streamlit.__file__).parent / "runtime").as_posix() executable = ExecutableFlow.from_yaml(flow_file=Path(flow_dag_path.name), working_dir=flow_dag_path.parent) flow_inputs = { flow_input: (value.default, value.type.value) for flow_input, value in executable.inputs.items() if not value.is_chat_history } flow_inputs_params = ["=".join([flow_input, flow_input]) for flow_input, _ in flow_inputs.items()] flow_inputs_params = ",".join(flow_inputs_params) is_chat_flow, chat_history_input_name, _ = self._is_chat_flow(executable) label = "Chat" if is_chat_flow else "Run" copy_tree_respect_template_and_ignore_file( source=Path(__file__).parent.parent / "data" / "executable", target=output_dir, render_context={ "hidden_imports": hidden_imports, "flow_name": flow_name, "runtime_interpreter_path": runtime_interpreter_path, "flow_inputs": flow_inputs, "flow_inputs_params": flow_inputs_params, "flow_path": None, "is_chat_flow": is_chat_flow, "chat_history_input_name": chat_history_input_name, "label": label, }, ) self._run_pyinstaller(output_dir) def _run_pyinstaller(self, output_dir): with _change_working_dir(output_dir, mkdir=False): subprocess.run(["pyinstaller", "app.spec"], check=True) print("PyInstaller command executed successfully.") @monitor_operation(activity_name="pf.flows.build", activity_type=ActivityType.PUBLICAPI) def build( self, flow: Union[str, PathLike], *, output: Union[str, PathLike], format: str = "docker", variant: str = None, **kwargs, ): """ Build flow to other format. :param flow: path to the flow directory or flow dag to export :type flow: Union[str, PathLike] :param format: export format, support "docker" and "executable" only for now :type format: str :param output: output directory :type output: Union[str, PathLike] :param variant: node variant in format of {node_name}.{variant_name}, will use default variant if not specified. :type variant: str :return: no return :rtype: None """ output_dir = Path(output).absolute() output_dir.mkdir(parents=True, exist_ok=True) flow: ProtectedFlow = load_flow(flow) is_csharp_flow = flow.dag.get(LANGUAGE_KEY, "") == FlowLanguage.CSharp if format not in ["docker", "executable"]: raise ValueError(f"Unsupported export format: {format}") if variant: tuning_node, node_variant = parse_variant(variant) else: tuning_node, node_variant = None, None flow_only = kwargs.pop("flow_only", False) if flow_only: output_flow_dir = output_dir else: output_flow_dir = output_dir / "flow" new_flow_dag_path = self._build_flow( flow_dag_path=flow.flow_dag_path, output=output_flow_dir, tuning_node=tuning_node, node_variant=node_variant, update_flow_tools_json=False if is_csharp_flow else True, ) if flow_only: return # use new flow dag path below as origin one may miss additional includes connection_paths, env_var_names = self._export_flow_connections( built_flow_dag_path=new_flow_dag_path, output_dir=output_dir / "connections", ) if format == "docker": self._export_to_docker( flow_dag_path=new_flow_dag_path, output_dir=output_dir, connection_paths=connection_paths, flow_name=flow.name, env_var_names=env_var_names, is_csharp_flow=is_csharp_flow, ) elif format == "executable": self._build_as_executable( flow_dag_path=new_flow_dag_path, output_dir=output_dir, flow_name=flow.name, env_var_names=env_var_names, ) @classmethod @contextlib.contextmanager def _resolve_additional_includes(cls, flow_dag_path: Path) -> Iterable[Path]: # TODO: confirm if we need to import this from promptflow._sdk._submitter import remove_additional_includes # Eager flow may not contain a yaml file, skip resolving additional includes def is_yaml_file(file_path): _, file_extension = os.path.splitext(file_path) return file_extension.lower() in (".yaml", ".yml") if is_yaml_file(flow_dag_path) and _get_additional_includes(flow_dag_path): # Merge the flow folder and additional includes to temp folder. # TODO: support a flow_dag_path with a name different from flow.dag.yaml with _merge_local_code_and_additional_includes(code_path=flow_dag_path.parent) as temp_dir: remove_additional_includes(Path(temp_dir)) yield Path(temp_dir) / flow_dag_path.name else: yield flow_dag_path @monitor_operation(activity_name="pf.flows.validate", activity_type=ActivityType.PUBLICAPI) def validate(self, flow: Union[str, PathLike], *, raise_error: bool = False, **kwargs) -> ValidationResult: """ Validate flow. :param flow: path to the flow directory or flow dag to export :type flow: Union[str, PathLike] :param raise_error: whether raise error when validation failed :type raise_error: bool :return: a validation result object :rtype: ValidationResult """ flow_entity: ProtectedFlow = load_flow(source=flow) # TODO: put off this if we do path existence check in FlowSchema on fields other than additional_includes validation_result = flow_entity._validate() source_path_mapping = {} flow_tools, tools_errors = self._generate_tools_meta( flow=flow_entity.flow_dag_path, source_path_mapping=source_path_mapping, ) flow_entity.tools_meta_path.write_text( data=json.dumps(flow_tools, indent=4), encoding=DEFAULT_ENCODING, ) if tools_errors: for source_name, message in tools_errors.items(): for yaml_path in source_path_mapping.get(source_name, []): validation_result.append_error( yaml_path=yaml_path, message=message, ) # flow in control plane is read-only, so resolve location makes sense even in SDK experience validation_result.resolve_location_for_diagnostics(flow_entity.flow_dag_path.as_posix()) flow_entity._try_raise( validation_result, raise_error=raise_error, ) return validation_result @monitor_operation(activity_name="pf.flows._generate_tools_meta", activity_type=ActivityType.INTERNALCALL) def _generate_tools_meta( self, flow: Union[str, PathLike], *, source_name: str = None, source_path_mapping: Dict[str, List[str]] = None, timeout: int = FLOW_TOOLS_JSON_GEN_TIMEOUT, ) -> Tuple[dict, dict]: """Generate flow tools meta for a specific flow or a specific node in the flow. This is a private interface for vscode extension, so do not change the interface unless necessary. Usage: from promptflow import PFClient PFClient().flows._generate_tools_meta(flow="flow.dag.yaml", source_name="convert_to_dict.py") :param flow: path to the flow directory or flow dag to export :type flow: Union[str, PathLike] :param source_name: source name to generate tools meta. If not specified, generate tools meta for all sources. :type source_name: str :param source_path_mapping: If passed in None, do nothing; if passed in a dict, will record all reference yaml paths for each source in the dict passed in. :type source_path_mapping: Dict[str, List[str]] :param timeout: timeout for generating tools meta :type timeout: int :return: dict of tools meta and dict of tools errors :rtype: Tuple[dict, dict] """ flow: ProtectedFlow = load_flow(source=flow) if not isinstance(flow, ProtectedFlow): # No tools meta for eager flow return {}, {} with self._resolve_additional_includes(flow.flow_dag_path) as new_flow_dag_path: flow_tools = generate_flow_tools_json( flow_directory=new_flow_dag_path.parent, dump=False, raise_error=False, include_errors_in_output=True, target_source=source_name, used_packages_only=True, source_path_mapping=source_path_mapping, timeout=timeout, ) flow_tools_meta = flow_tools.pop("code", {}) tools_errors = {} nodes_with_error = [node_name for node_name, message in flow_tools_meta.items() if isinstance(message, str)] for node_name in nodes_with_error: tools_errors[node_name] = flow_tools_meta.pop(node_name) additional_includes = _get_additional_includes(flow.flow_dag_path) if additional_includes: additional_files = {} for include in additional_includes: include_path = Path(include) if Path(include).is_absolute() else flow.code / include if include_path.is_file(): file_name = Path(include).name additional_files[Path(file_name)] = os.path.relpath(include_path, flow.code) else: if not Path(include).is_absolute(): include = flow.code / include files = glob.glob(os.path.join(include, "**"), recursive=True) additional_files.update( { Path(os.path.relpath(path, include.parent)): os.path.relpath(path, flow.code) for path in files } ) for tool in flow_tools_meta.values(): source = tool.get("source", None) if source and Path(source) in additional_files: tool["source"] = additional_files[Path(source)] flow_tools["code"] = flow_tools_meta return flow_tools, tools_errors
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_local_azure_connection_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import re from typing import List from promptflow._sdk._constants import AZURE_WORKSPACE_REGEX_FORMAT, MAX_LIST_CLI_RESULTS from promptflow._sdk._telemetry import ActivityType, WorkspaceTelemetryMixin, monitor_operation from promptflow._sdk._utils import interactive_credential_disabled, is_from_cli, is_github_codespaces, print_red_error from promptflow._sdk.entities._connection import _Connection from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow.azure._utils.gerneral import get_arm_token logger = get_cli_sdk_logger() class LocalAzureConnectionOperations(WorkspaceTelemetryMixin): def __init__(self, connection_provider, **kwargs): self._subscription_id, self._resource_group, self._workspace_name = self._extract_workspace(connection_provider) self._credential = kwargs.pop("credential", None) or self._get_credential() super().__init__( subscription_id=self._subscription_id, resource_group_name=self._resource_group, workspace_name=self._workspace_name, **kwargs, ) # Lazy init client as ml_client initialization require workspace read permission self._pfazure_client = None self._user_agent = kwargs.pop("user_agent", None) @property def _client(self): if self._pfazure_client is None: from promptflow.azure._pf_client import PFClient as PFAzureClient self._pfazure_client = PFAzureClient( # TODO: disable interactive credential when starting as a service credential=self._credential, subscription_id=self._subscription_id, resource_group_name=self._resource_group, workspace_name=self._workspace_name, user_agent=self._user_agent, ) return self._pfazure_client @classmethod def _get_credential(cls): from azure.ai.ml._azure_environments import AzureEnvironments, EndpointURLS, _get_cloud, _get_default_cloud_name from azure.identity import DefaultAzureCredential, DeviceCodeCredential if is_from_cli(): try: # Try getting token for cli without interactive login cloud_name = _get_default_cloud_name() if cloud_name != AzureEnvironments.ENV_DEFAULT: cloud = _get_cloud(cloud=cloud_name) authority = cloud.get(EndpointURLS.ACTIVE_DIRECTORY_ENDPOINT) credential = DefaultAzureCredential(authority=authority, exclude_shared_token_cache_credential=True) else: credential = DefaultAzureCredential() get_arm_token(credential=credential) except Exception: print_red_error( "Please run 'az login' or 'az login --use-device-code' to set up account. " "See https://docs.microsoft.com/cli/azure/authenticate-azure-cli for more details." ) exit(1) if interactive_credential_disabled(): return DefaultAzureCredential(exclude_interactive_browser_credential=True) if is_github_codespaces(): # For code spaces, append device code credential as the fallback option. credential = DefaultAzureCredential() credential.credentials = (*credential.credentials, DeviceCodeCredential()) return credential return DefaultAzureCredential(exclude_interactive_browser_credential=False) @classmethod def _extract_workspace(cls, connection_provider): match = re.match(AZURE_WORKSPACE_REGEX_FORMAT, connection_provider) if not match or len(match.groups()) != 5: raise ValueError( "Malformed connection provider string, expected azureml:/subscriptions/<subscription_id>/" "resourceGroups/<resource_group>/providers/Microsoft.MachineLearningServices/" f"workspaces/<workspace_name>, got {connection_provider}" ) subscription_id = match.group(1) resource_group = match.group(3) workspace_name = match.group(5) return subscription_id, resource_group, workspace_name @monitor_operation(activity_name="pf.connections.azure.list", activity_type=ActivityType.PUBLICAPI) def list( self, max_results: int = MAX_LIST_CLI_RESULTS, all_results: bool = False, ) -> List[_Connection]: """List connections. :return: List of run objects. :rtype: List[~promptflow.sdk.entities._connection._Connection] """ if max_results != MAX_LIST_CLI_RESULTS or all_results: logger.warning( "max_results and all_results are not supported for workspace connection and will be ignored." ) return self._client._connections.list() @monitor_operation(activity_name="pf.connections.azure.get", activity_type=ActivityType.PUBLICAPI) def get(self, name: str, **kwargs) -> _Connection: """Get a connection entity. :param name: Name of the connection. :type name: str :return: connection object retrieved from the database. :rtype: ~promptflow.sdk.entities._connection._Connection """ with_secrets = kwargs.get("with_secrets", False) if with_secrets: # Do not use pfazure_client here as it requires workspace read permission # Get secrets from arm only requires workspace listsecrets permission from promptflow.azure.operations._arm_connection_operations import ArmConnectionOperations return ArmConnectionOperations._direct_get( name, self._subscription_id, self._resource_group, self._workspace_name, self._credential ) return self._client._connections.get(name) @monitor_operation(activity_name="pf.connections.azure.delete", activity_type=ActivityType.PUBLICAPI) def delete(self, name: str) -> None: """Delete a connection entity. :param name: Name of the connection. :type name: str """ raise NotImplementedError( "Delete workspace connection is not supported in promptflow, " "please manage it in workspace portal, az ml cli or AzureML SDK." ) @monitor_operation(activity_name="pf.connections.azure.create_or_update", activity_type=ActivityType.PUBLICAPI) def create_or_update(self, connection: _Connection, **kwargs): """Create or update a connection. :param connection: Run object to create or update. :type connection: ~promptflow.sdk.entities._connection._Connection """ raise NotImplementedError( "Create or update workspace connection is not supported in promptflow, " "please manage it in workspace portal, az ml cli or AzureML SDK." )
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_connection_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- from datetime import datetime from typing import List from promptflow._sdk._constants import MAX_LIST_CLI_RESULTS from promptflow._sdk._orm import Connection as ORMConnection from promptflow._sdk._telemetry import ActivityType, TelemetryMixin, monitor_operation from promptflow._sdk._utils import safe_parse_object_list from promptflow._sdk.entities._connection import _Connection class ConnectionOperations(TelemetryMixin): """ConnectionOperations.""" def __init__(self, **kwargs): super().__init__(**kwargs) @monitor_operation(activity_name="pf.connections.list", activity_type=ActivityType.PUBLICAPI) def list( self, max_results: int = MAX_LIST_CLI_RESULTS, all_results: bool = False, ) -> List[_Connection]: """List connections. :param max_results: Max number of results to return. :type max_results: int :param all_results: Return all results. :type all_results: bool :return: List of run objects. :rtype: List[~promptflow.sdk.entities._connection._Connection] """ orm_connections = ORMConnection.list(max_results=max_results, all_results=all_results) return safe_parse_object_list( obj_list=orm_connections, parser=_Connection._from_orm_object, message_generator=lambda x: f"Failed to load connection {x.connectionName}, skipped.", ) @monitor_operation(activity_name="pf.connections.get", activity_type=ActivityType.PUBLICAPI) def get(self, name: str, **kwargs) -> _Connection: """Get a connection entity. :param name: Name of the connection. :type name: str :return: connection object retrieved from the database. :rtype: ~promptflow.sdk.entities._connection._Connection """ return self._get(name, **kwargs) def _get(self, name: str, **kwargs) -> _Connection: with_secrets = kwargs.get("with_secrets", False) raise_error = kwargs.get("raise_error", True) orm_connection = ORMConnection.get(name, raise_error) if orm_connection is None: return None if with_secrets: return _Connection._from_orm_object_with_secrets(orm_connection) return _Connection._from_orm_object(orm_connection) @monitor_operation(activity_name="pf.connections.delete", activity_type=ActivityType.PUBLICAPI) def delete(self, name: str) -> None: """Delete a connection entity. :param name: Name of the connection. :type name: str """ ORMConnection.delete(name) @monitor_operation(activity_name="pf.connections.create_or_update", activity_type=ActivityType.PUBLICAPI) def create_or_update(self, connection: _Connection, **kwargs): """Create or update a connection. :param connection: Run object to create or update. :type connection: ~promptflow.sdk.entities._connection._Connection """ orm_object = connection._to_orm_object() now = datetime.now().isoformat() if orm_object.createdDate is None: orm_object.createdDate = now orm_object.lastModifiedDate = now ORMConnection.create_or_update(orm_object) return self.get(connection.name)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_run_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy import os.path import sys import time from dataclasses import asdict from typing import Any, Dict, List, Optional, Union from promptflow._constants import LANGUAGE_KEY, AvailableIDE, FlowLanguage from promptflow._sdk._constants import ( MAX_RUN_LIST_RESULTS, MAX_SHOW_DETAILS_RESULTS, FlowRunProperties, ListViewType, RunInfoSources, RunStatus, ) from promptflow._sdk._errors import InvalidRunStatusError, RunExistsError, RunNotFoundError, RunOperationParameterError from promptflow._sdk._orm import RunInfo as ORMRun from promptflow._sdk._telemetry import ActivityType, TelemetryMixin, monitor_operation from promptflow._sdk._utils import incremental_print, print_red_error, safe_parse_object_list from promptflow._sdk._visualize_functions import dump_html, generate_html_string from promptflow._sdk.entities import Run from promptflow._sdk.operations._local_storage_operations import LocalStorageOperations from promptflow._utils.logger_utils import get_cli_sdk_logger from promptflow._utils.yaml_utils import load_yaml_string from promptflow.contracts._run_management import RunDetail, RunMetadata, RunVisualization, VisualizationConfig from promptflow.exceptions import UserErrorException RUNNING_STATUSES = RunStatus.get_running_statuses() logger = get_cli_sdk_logger() class RunOperations(TelemetryMixin): """RunOperations.""" def __init__(self, **kwargs): super().__init__(**kwargs) @monitor_operation(activity_name="pf.runs.list", activity_type=ActivityType.PUBLICAPI) def list( self, max_results: Optional[int] = MAX_RUN_LIST_RESULTS, *, list_view_type: ListViewType = ListViewType.ACTIVE_ONLY, ) -> List[Run]: """List runs. :param max_results: Max number of results to return. Default: MAX_RUN_LIST_RESULTS. :type max_results: Optional[int] :param list_view_type: View type for including/excluding (for example) archived runs. Default: ACTIVE_ONLY. :type include_archived: Optional[ListViewType] :return: List of run objects. :rtype: List[~promptflow.entities.Run] """ orm_runs = ORMRun.list(max_results=max_results, list_view_type=list_view_type) return safe_parse_object_list( obj_list=orm_runs, parser=Run._from_orm_object, message_generator=lambda x: f"Error parsing run {x.name!r}, skipped.", ) @monitor_operation(activity_name="pf.runs.get", activity_type=ActivityType.PUBLICAPI) def get(self, name: str) -> Run: """Get a run entity. :param name: Name of the run. :type name: str :return: run object retrieved from the database. :rtype: ~promptflow.entities.Run """ return self._get(name) def _get(self, name: str) -> Run: name = Run._validate_and_return_run_name(name) try: return Run._from_orm_object(ORMRun.get(name)) except RunNotFoundError as e: raise e @monitor_operation(activity_name="pf.runs.create_or_update", activity_type=ActivityType.PUBLICAPI) def create_or_update(self, run: Run, **kwargs) -> Run: """Create or update a run. :param run: Run object to create or update. :type run: ~promptflow.entities.Run :return: Run object created or updated. :rtype: ~promptflow.entities.Run """ # create run from an existing run folder if run._run_source == RunInfoSources.EXISTING_RUN: return self._create_run_from_existing_run_folder(run=run, **kwargs) # TODO: change to async stream = kwargs.pop("stream", False) try: from promptflow._sdk._submitter import RunSubmitter created_run = RunSubmitter(run_operations=self).submit(run=run, **kwargs) if stream: self.stream(created_run) return created_run except RunExistsError: raise RunExistsError(f"Run {run.name!r} already exists.") def _create_run_from_existing_run_folder(self, run: Run, **kwargs) -> Run: """Create run from existing run folder.""" try: self.get(run.name) except RunNotFoundError: pass else: raise RunExistsError(f"Run {run.name!r} already exists.") try: run._dump() return run except Exception as e: raise UserErrorException( f"Failed to create run {run.name!r} from existing run folder {run.source!r}: {str(e)}" ) from e def _print_run_summary(self, run: Run) -> None: print("======= Run Summary =======\n") duration = str(run._end_time - run._created_on) print( f'Run name: "{run.name}"\n' f'Run status: "{run.status}"\n' f'Start time: "{run._created_on}"\n' f'Duration: "{duration}"\n' f'Output path: "{run._output_path}"\n' ) @monitor_operation(activity_name="pf.runs.stream", activity_type=ActivityType.PUBLICAPI) def stream(self, name: Union[str, Run], raise_on_error: bool = True) -> Run: """Stream run logs to the console. :param name: Name of the run, or run object. :type name: Union[str, ~promptflow.sdk.entities.Run] :param raise_on_error: Raises an exception if a run fails or canceled. :type raise_on_error: bool :return: Run object. :rtype: ~promptflow.entities.Run """ name = Run._validate_and_return_run_name(name) run = self.get(name=name) local_storage = LocalStorageOperations(run=run) file_handler = sys.stdout try: printed = 0 run = self.get(run.name) while run.status in RUNNING_STATUSES or run.status == RunStatus.FINALIZING: file_handler.flush() available_logs = local_storage.logger.get_logs() printed = incremental_print(available_logs, printed, file_handler) time.sleep(10) run = self.get(run.name) # ensure all logs are printed file_handler.flush() available_logs = local_storage.logger.get_logs() incremental_print(available_logs, printed, file_handler) self._print_run_summary(run) except KeyboardInterrupt: error_message = "The output streaming for the run was interrupted, but the run is still executing." print(error_message) if run.status == RunStatus.FAILED or run.status == RunStatus.CANCELED: if run.status == RunStatus.FAILED: error_message = local_storage.load_exception().get("message", "Run fails with unknown error.") else: error_message = "Run is canceled." if raise_on_error: raise InvalidRunStatusError(error_message) else: print_red_error(error_message) return run @monitor_operation(activity_name="pf.runs.archive", activity_type=ActivityType.PUBLICAPI) def archive(self, name: Union[str, Run]) -> Run: """Archive a run. :param name: Name of the run. :type name: str :return: archived run object. :rtype: ~promptflow._sdk.entities._run.Run """ name = Run._validate_and_return_run_name(name) ORMRun.get(name).archive() return self.get(name) @monitor_operation(activity_name="pf.runs.restore", activity_type=ActivityType.PUBLICAPI) def restore(self, name: Union[str, Run]) -> Run: """Restore a run. :param name: Name of the run. :type name: str :return: restored run object. :rtype: ~promptflow._sdk.entities._run.Run """ name = Run._validate_and_return_run_name(name) ORMRun.get(name).restore() return self.get(name) @monitor_operation(activity_name="pf.runs.update", activity_type=ActivityType.PUBLICAPI) def update( self, name: Union[str, Run], display_name: Optional[str] = None, description: Optional[str] = None, tags: Optional[Dict[str, str]] = None, **kwargs, ) -> Run: """Update run status. :param name: run name :param display_name: display name to update :param description: description to update :param tags: tags to update :param kwargs: other fields to update, fields not supported will be directly dropped. :return: updated run object :rtype: ~promptflow._sdk.entities._run.Run """ name = Run._validate_and_return_run_name(name) # the kwargs is to support update run status scenario but keep it private ORMRun.get(name).update(display_name=display_name, description=description, tags=tags, **kwargs) return self.get(name) @monitor_operation(activity_name="pf.runs.delete", activity_type=ActivityType.PUBLICAPI) def delete( self, name: str, ) -> None: """Delete run permanently. Caution: This operation will delete the run permanently from your local disk. Both run entity and output data will be deleted. :param name: run name to delete :return: None """ valid_run = self.get(name) LocalStorageOperations(valid_run).delete() ORMRun.delete(name) @monitor_operation(activity_name="pf.runs.get_details", activity_type=ActivityType.PUBLICAPI) def get_details( self, name: Union[str, Run], max_results: int = MAX_SHOW_DETAILS_RESULTS, all_results: bool = False ) -> "DataFrame": """Get the details from the run. .. note:: If `all_results` is set to True, `max_results` will be overwritten to sys.maxsize. :param name: The run name or run object :type name: Union[str, ~promptflow.sdk.entities.Run] :param max_results: The max number of runs to return, defaults to 100 :type max_results: int :param all_results: Whether to return all results, defaults to False :type all_results: bool :raises RunOperationParameterError: If `max_results` is not a positive integer. :return: The details data frame. :rtype: pandas.DataFrame """ from pandas import DataFrame # if all_results is True, set max_results to sys.maxsize if all_results: max_results = sys.maxsize if not isinstance(max_results, int) or max_results < 1: raise RunOperationParameterError(f"'max_results' must be a positive integer, got {max_results!r}") name = Run._validate_and_return_run_name(name) run = self.get(name=name) local_storage = LocalStorageOperations(run=run) inputs, outputs = local_storage.load_inputs_and_outputs() inputs = inputs.to_dict("list") outputs = outputs.to_dict("list") data = {} columns = [] for k in inputs: new_k = f"inputs.{k}" data[new_k] = copy.deepcopy(inputs[k]) columns.append(new_k) for k in outputs: new_k = f"outputs.{k}" data[new_k] = copy.deepcopy(outputs[k]) columns.append(new_k) df = DataFrame(data).head(max_results).reindex(columns=columns) return df @monitor_operation(activity_name="pf.runs.get_metrics", activity_type=ActivityType.PUBLICAPI) def get_metrics(self, name: Union[str, Run]) -> Dict[str, Any]: """Get run metrics. :param name: name of the run. :type name: str :return: Run metrics. :rtype: Dict[str, Any] """ name = Run._validate_and_return_run_name(name) run = self.get(name=name) run._check_run_status_is_completed() local_storage = LocalStorageOperations(run=run) return local_storage.load_metrics() def _visualize(self, runs: List[Run], html_path: Optional[str] = None) -> None: details: List[RunDetail] = [] metadatas: List[RunMetadata] = [] configs: List[VisualizationConfig] = [] for run in runs: # check run status first # if run status is not compeleted, there might be unexpected error during parse data # so we directly raise error if there is any incomplete run run._check_run_status_is_completed() local_storage = LocalStorageOperations(run) # nan, inf and -inf are not JSON serializable, which will lead to JavaScript parse error # so specify `parse_const_as_str` as True to parse them as string detail = local_storage.load_detail(parse_const_as_str=True) # ad-hoc step: make logs field empty to avoid too big HTML file # we don't provide logs view in visualization page for now # when we enable, we will save those big data (e.g. logs) in separate file(s) # JS load can be faster than static HTML for i in range(len(detail["node_runs"])): detail["node_runs"][i]["logs"] = {"stdout": "", "stderr": ""} metadata = RunMetadata( name=run.name, display_name=run.display_name, create_time=run.created_on, flow_path=run.properties.get(FlowRunProperties.FLOW_PATH, None), output_path=run.properties[FlowRunProperties.OUTPUT_PATH], tags=run.tags, lineage=run.run, metrics=self.get_metrics(name=run.name), dag=local_storage.load_dag_as_string(), flow_tools_json=local_storage.load_flow_tools_json(), mode="eager" if local_storage.eager_mode else "", ) details.append(copy.deepcopy(detail)) metadatas.append(asdict(metadata)) # TODO: add language to run metadata flow_dag = load_yaml_string(metadata.dag) or {} configs.append( VisualizationConfig( [AvailableIDE.VS_CODE] if flow_dag.get(LANGUAGE_KEY, FlowLanguage.Python) == FlowLanguage.Python else [AvailableIDE.VS] ) ) data_for_visualize = RunVisualization( detail=details, metadata=metadatas, config=configs, ) html_string = generate_html_string(asdict(data_for_visualize)) # if html_path is specified, not open it in webbrowser(as it comes from VSC) dump_html(html_string, html_path=html_path, open_html=html_path is None) @monitor_operation(activity_name="pf.runs.visualize", activity_type=ActivityType.PUBLICAPI) def visualize(self, runs: Union[str, Run, List[str], List[Run]], **kwargs) -> None: """Visualize run(s). :param runs: List of run objects, or names of the runs. :type runs: Union[str, ~promptflow.sdk.entities.Run, List[str], List[~promptflow.sdk.entities.Run]] """ if not isinstance(runs, list): runs = [runs] validated_runs = [] for run in runs: run_name = Run._validate_and_return_run_name(run) validated_runs.append(self.get(name=run_name)) html_path = kwargs.pop("html_path", None) try: self._visualize(validated_runs, html_path=html_path) except InvalidRunStatusError as e: error_message = f"Cannot visualize non-completed run. {str(e)}" logger.error(error_message) def _get_outputs(self, run: Union[str, Run]) -> List[Dict[str, Any]]: """Get the outputs of the run, load from local storage.""" local_storage = self._get_local_storage(run) return local_storage.load_outputs() def _get_inputs(self, run: Union[str, Run]) -> List[Dict[str, Any]]: """Get the outputs of the run, load from local storage.""" local_storage = self._get_local_storage(run) return local_storage.load_inputs() def _get_outputs_path(self, run: Union[str, Run]) -> str: """Get the outputs file path of the run.""" local_storage = self._get_local_storage(run) return local_storage._outputs_path if local_storage.load_outputs() else None def _get_data_path(self, run: Union[str, Run]) -> str: """Get the outputs file path of the run.""" local_storage = self._get_local_storage(run) # TODO: what if the data is deleted? if local_storage._data_path and not os.path.exists(local_storage._data_path): raise UserErrorException( f"Data path {local_storage._data_path} for run {run.name} does not exist. " "Please make sure it exists and not deleted." ) return local_storage._data_path def _get_local_storage(self, run: Union[str, Run]) -> LocalStorageOperations: """Get the local storage of the run.""" if isinstance(run, str): run = self.get(name=run) return LocalStorageOperations(run)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_local_storage_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import copy import datetime import json import logging import shutil from dataclasses import asdict, dataclass from functools import partial from pathlib import Path from typing import Any, Dict, List, NewType, Optional, Tuple, Union from filelock import FileLock from promptflow import load_flow from promptflow._sdk._constants import ( HOME_PROMPT_FLOW_DIR, LINE_NUMBER, LOCAL_STORAGE_BATCH_SIZE, PROMPT_FLOW_DIR_NAME, LocalStorageFilenames, RunInfoSources, ) from promptflow._sdk._errors import BulkRunException, InvalidRunError from promptflow._sdk._utils import ( PromptflowIgnoreFile, generate_flow_tools_json, json_dump, json_load, pd_read_json, read_open, write_open, ) from promptflow._sdk.entities import Run from promptflow._sdk.entities._eager_flow import EagerFlow from promptflow._sdk.entities._flow import Flow from promptflow._utils.dataclass_serializer import serialize from promptflow._utils.exception_utils import PromptflowExceptionPresenter from promptflow._utils.logger_utils import LogContext, get_cli_sdk_logger from promptflow._utils.multimedia_utils import get_file_reference_encoder from promptflow._utils.yaml_utils import load_yaml from promptflow.batch._result import BatchResult from promptflow.contracts.multimedia import Image from promptflow.contracts.run_info import FlowRunInfo from promptflow.contracts.run_info import RunInfo as NodeRunInfo from promptflow.contracts.run_info import Status from promptflow.contracts.run_mode import RunMode from promptflow.exceptions import UserErrorException from promptflow.storage import AbstractRunStorage logger = get_cli_sdk_logger() RunInputs = NewType("RunInputs", Dict[str, List[Any]]) RunOutputs = NewType("RunOutputs", Dict[str, List[Any]]) RunMetrics = NewType("RunMetrics", Dict[str, Any]) @dataclass class LoggerOperations(LogContext): stream: bool = False @property def log_path(self) -> str: return str(self.file_path) def get_logs(self) -> str: with read_open(self.file_path) as f: return f.read() def _get_execute_loggers_list(cls) -> List[logging.Logger]: result = super()._get_execute_loggers_list() result.append(logger) return result def get_initializer(self): return partial( LoggerOperations, file_path=self.file_path, run_mode=self.run_mode, credential_list=self.credential_list, stream=self.stream, ) def __enter__(self): log_path = Path(self.log_path) log_path.parent.mkdir(parents=True, exist_ok=True) if self.run_mode == RunMode.Batch: log_path.touch(exist_ok=True) else: if log_path.exists(): # for non batch run, clean up previous log content try: with write_open(log_path) as file: file.truncate(0) except Exception as e: logger.warning(f"Failed to clean up the previous log content because {e}") else: log_path.touch() for _logger in self._get_execute_loggers_list(): for handler in _logger.handlers: if self.stream is False and isinstance(handler, logging.StreamHandler): handler.setLevel(logging.CRITICAL) super().__enter__() def __exit__(self, *args): super().__exit__(*args) for _logger in self._get_execute_loggers_list(): for handler in _logger.handlers: if self.stream is False and isinstance(handler, logging.StreamHandler): handler.setLevel(logging.CRITICAL) @dataclass class NodeRunRecord: NodeName: str line_number: int run_info: str start_time: datetime end_time: datetime status: str @staticmethod def from_run_info(node_run_info: NodeRunInfo) -> "NodeRunRecord": return NodeRunRecord( NodeName=node_run_info.node, line_number=node_run_info.index, run_info=serialize(node_run_info), start_time=node_run_info.start_time.isoformat(), end_time=node_run_info.end_time.isoformat(), status=node_run_info.status.value, ) def dump(self, path: Path, run_name: str) -> None: # for nodes in first line run and all reduce nodes, the target filename is 000000000.jsonl # so we need to handle concurrent write with file lock filename_need_lock = "0".zfill(LocalStorageOperations.LINE_NUMBER_WIDTH) + ".jsonl" if path.name == filename_need_lock: file_lock_path = (HOME_PROMPT_FLOW_DIR / f"{run_name}.{self.NodeName}.lock").resolve() lock = FileLock(file_lock_path) lock.acquire() try: json_dump(asdict(self), path) finally: lock.release() else: # for normal nodes in other line runs, directly write json_dump(asdict(self), path) @dataclass class LineRunRecord: line_number: int run_info: str start_time: datetime.datetime end_time: datetime.datetime name: str description: str status: str tags: str @staticmethod def from_flow_run_info(flow_run_info: FlowRunInfo) -> "LineRunRecord": return LineRunRecord( line_number=flow_run_info.index, run_info=serialize(flow_run_info), start_time=flow_run_info.start_time.isoformat(), end_time=flow_run_info.end_time.isoformat(), name=flow_run_info.name, description=flow_run_info.description, status=flow_run_info.status.value, tags=flow_run_info.tags, ) def dump(self, path: Path) -> None: json_dump(asdict(self), path) class LocalStorageOperations(AbstractRunStorage): """LocalStorageOperations.""" LINE_NUMBER_WIDTH = 9 def __init__(self, run: Run, stream=False, run_mode=RunMode.Test): self._run = run self.path = self._prepare_folder(self._run._output_path) self.logger = LoggerOperations( file_path=self.path / LocalStorageFilenames.LOG, stream=stream, run_mode=run_mode ) # snapshot self._snapshot_folder_path = self._prepare_folder(self.path / LocalStorageFilenames.SNAPSHOT_FOLDER) self._dag_path = self._snapshot_folder_path / LocalStorageFilenames.DAG self._flow_tools_json_path = ( self._snapshot_folder_path / PROMPT_FLOW_DIR_NAME / LocalStorageFilenames.FLOW_TOOLS_JSON ) self._inputs_path = self.path / LocalStorageFilenames.INPUTS # keep this for other usages # below inputs and outputs are dumped by SDK self._sdk_inputs_path = self._inputs_path self._sdk_output_path = self.path / LocalStorageFilenames.OUTPUTS # metrics self._metrics_path = self.path / LocalStorageFilenames.METRICS # legacy files: detail.json and outputs.jsonl(not the one in flow_outputs folder) self._detail_path = self.path / LocalStorageFilenames.DETAIL self._legacy_outputs_path = self.path / LocalStorageFilenames.OUTPUTS # for line run records, store per line # for normal node run records, store per node per line; # for reduce node run records, store centralized in 000000000.jsonl per node self.outputs_folder = self._prepare_folder(self.path / "flow_outputs") self._outputs_path = self.outputs_folder / "output.jsonl" # dumped by executor self._node_infos_folder = self._prepare_folder(self.path / "node_artifacts") self._run_infos_folder = self._prepare_folder(self.path / "flow_artifacts") self._data_path = Path(run.data) if run.data is not None else None self._meta_path = self.path / LocalStorageFilenames.META self._exception_path = self.path / LocalStorageFilenames.EXCEPTION self._dump_meta_file() self._eager_mode = self._calculate_eager_mode(run) @property def eager_mode(self) -> bool: return self._eager_mode @classmethod def _calculate_eager_mode(cls, run: Run) -> bool: if run._run_source == RunInfoSources.LOCAL: try: flow_obj = load_flow(source=run.flow) return isinstance(flow_obj, EagerFlow) except Exception as e: # For run with incomplete flow snapshot, ignore load flow error to make sure it can still show. logger.debug(f"Failed to load flow from {run.flow} due to {e}.") return False elif run._run_source in [RunInfoSources.INDEX_SERVICE, RunInfoSources.RUN_HISTORY]: return run._properties.get("azureml.promptflow.run_mode") == "Eager" # TODO(2901279): support eager mode for run created from run folder return False def delete(self) -> None: def on_rmtree_error(func, path, exc_info): raise InvalidRunError(f"Failed to delete run {self.path} due to {exc_info[1]}.") shutil.rmtree(path=self.path, onerror=on_rmtree_error) def _dump_meta_file(self) -> None: json_dump({"batch_size": LOCAL_STORAGE_BATCH_SIZE}, self._meta_path) def dump_snapshot(self, flow: Flow) -> None: """Dump flow directory to snapshot folder, input file will be dumped after the run.""" patterns = [pattern for pattern in PromptflowIgnoreFile.IGNORE_FILE] # ignore current output parent folder to avoid potential recursive copy patterns.append(self._run._output_path.parent.name) shutil.copytree( flow.code.as_posix(), self._snapshot_folder_path, ignore=shutil.ignore_patterns(*patterns), dirs_exist_ok=True, ) # replace DAG file with the overwrite one if not self._eager_mode: self._dag_path.unlink() shutil.copy(flow.path, self._dag_path) def load_dag_as_string(self) -> str: if self._eager_mode: return "" with read_open(self._dag_path) as f: return f.read() def load_flow_tools_json(self) -> dict: if self._eager_mode: # no tools json for eager mode return {} if not self._flow_tools_json_path.is_file(): return generate_flow_tools_json(self._snapshot_folder_path, dump=False) else: return json_load(self._flow_tools_json_path) def load_io_spec(self) -> Tuple[Dict[str, Dict[str, str]], Dict[str, Dict[str, str]]]: """Load input/output spec from DAG.""" # TODO(2898455): support eager mode with read_open(self._dag_path) as f: flow_dag = load_yaml(f) return flow_dag["inputs"], flow_dag["outputs"] def load_inputs(self) -> RunInputs: df = pd_read_json(self._inputs_path) return df.to_dict("list") def load_outputs(self) -> RunOutputs: # for legacy run, simply read the output file and return as list of dict if not self._outputs_path.is_file(): df = pd_read_json(self._legacy_outputs_path) return df.to_dict("list") df = pd_read_json(self._outputs_path) if len(df) > 0: df = df.set_index(LINE_NUMBER) return df.to_dict("list") def dump_inputs_and_outputs(self) -> None: inputs, outputs = self._collect_io_from_debug_info() with write_open(self._sdk_inputs_path) as f: inputs.to_json(f, orient="records", lines=True, force_ascii=False) with write_open(self._sdk_output_path) as f: outputs.to_json(f, orient="records", lines=True, force_ascii=False) def dump_metrics(self, metrics: Optional[RunMetrics]) -> None: metrics = metrics or dict() json_dump(metrics, self._metrics_path) def dump_exception(self, exception: Exception, batch_result: BatchResult) -> None: """Dump exception to local storage. :param exception: Exception raised during bulk run. :param batch_result: Bulk run outputs. If exception not raised, store line run error messages. """ # extract line run errors errors = [] if batch_result: for line_error in batch_result.error_summary.error_list: errors.append(line_error.to_dict()) # collect aggregation node error for node_name, aggr_error in batch_result.error_summary.aggr_error_dict.items(): errors.append({"error": aggr_error, "aggregation_node_name": node_name}) if errors: try: # use first line run error message as exception message if no exception raised error = errors[0] message = error["error"]["message"] except Exception: message = ( "Failed to extract error message from line runs. " f"Please check {self._outputs_path} for more info." ) elif exception and isinstance(exception, UserErrorException): # SystemError will be raised above and users can see it, so we don't need to dump it. message = str(exception) else: return if not isinstance(exception, BulkRunException): # If other errors raised, pass it into PromptflowException exception = BulkRunException( message=message, error=exception, failed_lines=batch_result.failed_lines if batch_result else "unknown", total_lines=batch_result.total_lines if batch_result else "unknown", errors={"errors": errors}, ) json_dump(PromptflowExceptionPresenter.create(exception).to_dict(include_debug_info=True), self._exception_path) def load_exception(self) -> Dict: try: return json_load(self._exception_path) except Exception: return {} def load_detail(self, parse_const_as_str: bool = False) -> Dict[str, list]: if self._detail_path.is_file(): # legacy run with local file detail.json, then directly load from the file return json_load(self._detail_path) else: # nan, inf and -inf are not JSON serializable # according to https://docs.python.org/3/library/json.html#json.loads # `parse_constant` will be called to handle these values # so if parse_const_as_str is True, we will parse these values as str with a lambda function json_loads = json.loads if not parse_const_as_str else partial(json.loads, parse_constant=lambda x: str(x)) # collect from local files and concat in the memory flow_runs, node_runs = [], [] for line_run_record_file in sorted(self._run_infos_folder.iterdir()): # In addition to the output jsonl files, there may be multimedia files in the output folder, # so we should skip them. if line_run_record_file.suffix.lower() != ".jsonl": continue with read_open(line_run_record_file) as f: new_runs = [json_loads(line)["run_info"] for line in list(f)] flow_runs += new_runs for node_folder in sorted(self._node_infos_folder.iterdir()): for node_run_record_file in sorted(node_folder.iterdir()): if node_run_record_file.suffix.lower() != ".jsonl": continue with read_open(node_run_record_file) as f: new_runs = [json_loads(line)["run_info"] for line in list(f)] node_runs += new_runs return {"flow_runs": flow_runs, "node_runs": node_runs} def load_metrics(self) -> Dict[str, Union[int, float, str]]: return json_load(self._metrics_path) def persist_node_run(self, run_info: NodeRunInfo) -> None: """Persist node run record to local storage.""" node_folder = self._prepare_folder(self._node_infos_folder / run_info.node) self._persist_run_multimedia(run_info, node_folder) node_run_record = NodeRunRecord.from_run_info(run_info) # for reduce nodes, the line_number is None, store the info in the 000000000.jsonl # align with AzureMLRunStorageV2, which is a storage contract with PFS line_number = 0 if node_run_record.line_number is None else node_run_record.line_number filename = f"{str(line_number).zfill(self.LINE_NUMBER_WIDTH)}.jsonl" node_run_record.dump(node_folder / filename, run_name=self._run.name) def persist_flow_run(self, run_info: FlowRunInfo) -> None: """Persist line run record to local storage.""" if not Status.is_terminated(run_info.status): logger.info("Line run is not terminated, skip persisting line run record.") return self._persist_run_multimedia(run_info, self._run_infos_folder) line_run_record = LineRunRecord.from_flow_run_info(run_info) # calculate filename according to the batch size # note that if batch_size > 1, need to well handle concurrent write scenario lower_bound = line_run_record.line_number // LOCAL_STORAGE_BATCH_SIZE * LOCAL_STORAGE_BATCH_SIZE upper_bound = lower_bound + LOCAL_STORAGE_BATCH_SIZE - 1 filename = ( f"{str(lower_bound).zfill(self.LINE_NUMBER_WIDTH)}_" f"{str(upper_bound).zfill(self.LINE_NUMBER_WIDTH)}.jsonl" ) line_run_record.dump(self._run_infos_folder / filename) def persist_result(self, result: Optional[BatchResult]) -> None: """Persist metrics from return of executor.""" if result is None: return self.dump_inputs_and_outputs() self.dump_metrics(result.metrics) def _persist_run_multimedia(self, run_info: Union[FlowRunInfo, NodeRunInfo], folder_path: Path): if run_info.inputs: run_info.inputs = self._serialize_multimedia(run_info.inputs, folder_path) if run_info.output: run_info.output = self._serialize_multimedia(run_info.output, folder_path) run_info.result = None if run_info.api_calls: run_info.api_calls = self._serialize_multimedia(run_info.api_calls, folder_path) def _serialize_multimedia(self, value, folder_path: Path, relative_path: Path = None): pfbytes_file_reference_encoder = get_file_reference_encoder(folder_path, relative_path, use_absolute_path=True) serialization_funcs = {Image: partial(Image.serialize, **{"encoder": pfbytes_file_reference_encoder})} return serialize(value, serialization_funcs=serialization_funcs) @staticmethod def _prepare_folder(path: Union[str, Path]) -> Path: path = Path(path) path.mkdir(parents=True, exist_ok=True) return path @staticmethod def _outputs_padding(df: "DataFrame", inputs_line_numbers: List[int]) -> "DataFrame": import pandas as pd if len(df) == len(inputs_line_numbers): return df missing_lines = [] lines_set = set(df[LINE_NUMBER].values) for i in inputs_line_numbers: if i not in lines_set: missing_lines.append({LINE_NUMBER: i}) df_to_append = pd.DataFrame(missing_lines) res = pd.concat([df, df_to_append], ignore_index=True) res = res.sort_values(by=LINE_NUMBER, ascending=True) return res def load_inputs_and_outputs(self) -> Tuple["DataFrame", "DataFrame"]: if not self._sdk_inputs_path.is_file() or not self._sdk_output_path.is_file(): inputs, outputs = self._collect_io_from_debug_info() else: inputs = pd_read_json(self._sdk_inputs_path) outputs = pd_read_json(self._sdk_output_path) # if all line runs are failed, no need to fill if len(outputs) > 0: outputs = self._outputs_padding(outputs, inputs[LINE_NUMBER].tolist()) outputs.fillna(value="(Failed)", inplace=True) # replace nan with explicit prompt outputs = outputs.set_index(LINE_NUMBER) return inputs, outputs def _collect_io_from_debug_info(self) -> Tuple["DataFrame", "DataFrame"]: import pandas as pd inputs, outputs = [], [] for line_run_record_file in sorted(self._run_infos_folder.iterdir()): if line_run_record_file.suffix.lower() != ".jsonl": continue with read_open(line_run_record_file) as f: datas = [json.loads(line) for line in list(f)] for data in datas: line_number: int = data[LINE_NUMBER] line_run_info: dict = data["run_info"] current_inputs = line_run_info.get("inputs") current_outputs = line_run_info.get("output") inputs.append(copy.deepcopy(current_inputs)) if current_outputs is not None: current_outputs[LINE_NUMBER] = line_number outputs.append(copy.deepcopy(current_outputs)) return pd.DataFrame(inputs), pd.DataFrame(outputs)
0
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk
promptflow_repo/promptflow/src/promptflow/promptflow/_sdk/operations/_tool_operations.py
# --------------------------------------------------------- # Copyright (c) Microsoft Corporation. All rights reserved. # --------------------------------------------------------- import importlib.util import inspect import io import json import logging import pkgutil from dataclasses import asdict from os import PathLike from pathlib import Path from types import ModuleType from typing import Union import jsonschema from promptflow._core.tool_meta_generator import ( ToolValidationError, _parse_tool_from_function, asdict_without_none, is_tool, ) from promptflow._core.tools_manager import PACKAGE_TOOLS_ENTRY, collect_package_tools from promptflow._sdk._constants import ICON, ICON_DARK, ICON_LIGHT, LOGGER_NAME, SKIP_FUNC_PARAMS, TOOL_SCHEMA from promptflow._sdk._telemetry import ActivityType, monitor_operation from promptflow._sdk.entities._validation import ValidationResult, ValidationResultBuilder from promptflow._utils.multimedia_utils import convert_multimedia_data_to_base64 from promptflow.contracts.multimedia import Image from promptflow.exceptions import UserErrorException TOTAL_COUNT = "total_count" INVALID_COUNT = "invalid_count" logger = logging.getLogger(LOGGER_NAME) class ToolOperations: """ToolOperations.""" def __init__(self): self._tool_schema_dict = None @property def _tool_schema(self): if not self._tool_schema_dict: with open(TOOL_SCHEMA, "r") as f: self._tool_schema_dict = json.load(f) return self._tool_schema_dict def _merge_validate_result(self, target, source): target.merge_with(source) target._set_extra_info( TOTAL_COUNT, target._get_extra_info(TOTAL_COUNT, 0) + source._get_extra_info(TOTAL_COUNT, 0), ) target._set_extra_info( INVALID_COUNT, target._get_extra_info(INVALID_COUNT, 0) + source._get_extra_info(INVALID_COUNT, 0), ) def _list_tools_in_package(self, package_name: str, raise_error: bool = False): """ List the meta of all tools in the package. Raise user error if raise_error=True and found incorrect tools. :param package_name: Package name :type package_name: str :param raise_error: Whether to raise the error. :type raise_error: bool :return: Dict of tools meta :rtype: Dict[str, Dict] """ package_tools, validate_result = self._list_tool_meta_in_package(package_name=package_name) if not validate_result.passed: if raise_error: def tool_validate_error_func(msg, _): return ToolValidationError(message=msg, validate_result=validate_result) validate_result.try_raise(raise_error=raise_error, error_func=tool_validate_error_func) else: logger.warning(f"Found invalid tool(s):\n {repr(validate_result)}") return package_tools def _list_tool_meta_in_package(self, package_name: str): """ List the meta of all tools in the package. :param package_name: Package name :type package_name: str :return: Dict of tools meta, validation result :rtype: Dict[str, Dict], ValidationResult """ package_tools = {} validate_result = ValidationResultBuilder.success() try: package = __import__(package_name) module_list = pkgutil.walk_packages(package.__path__, prefix=package.__name__ + ".") for module in module_list: module_tools, module_validate_result = self._generate_tool_meta(importlib.import_module(module.name)) package_tools.update(module_tools) self._merge_validate_result(validate_result, module_validate_result) except ImportError as e: raise UserErrorException(f"Cannot find the package {package_name}, {e}.") return package_tools, validate_result def _generate_tool_meta(self, tool_module): """ Generate tools meta in the module. :param tool_module: The module needs to generate tools meta :type tool_module: object :return: Dict of tools meta, validation result :rtype: Dict[str, Dict], ValidationResult """ tool_functions = self._collect_tool_functions_in_module(tool_module) tool_methods = self._collect_tool_class_methods_in_module(tool_module) construct_tools = {} invalid_tool_count = 0 tool_validate_result = ValidationResultBuilder.success() for f in tool_functions: tool, input_settings, extra_info = self._parse_tool_from_func(f) construct_tool, validate_result = self._serialize_tool(tool, input_settings, extra_info, f) if validate_result.passed: tool_name = self._get_tool_name(tool) construct_tools[tool_name] = construct_tool else: invalid_tool_count = invalid_tool_count + 1 tool_validate_result.merge_with(validate_result) for (f, initialize_inputs) in tool_methods: tool, input_settings, extra_info = self._parse_tool_from_func(f, initialize_inputs) construct_tool, validate_result = self._serialize_tool(tool, input_settings, extra_info, f) if validate_result.passed: tool_name = self._get_tool_name(tool) construct_tools[tool_name] = construct_tool else: invalid_tool_count = invalid_tool_count + 1 tool_validate_result.merge_with(validate_result) # The generated dict cannot be dumped as yaml directly since yaml cannot handle string enum. tools = json.loads(json.dumps(construct_tools)) tool_validate_result._set_extra_info(TOTAL_COUNT, len(tool_functions) + len(tool_methods)) tool_validate_result._set_extra_info(INVALID_COUNT, invalid_tool_count) return tools, tool_validate_result @staticmethod def _collect_tool_functions_in_module(tool_module): tools = [] for _, obj in inspect.getmembers(tool_module): if is_tool(obj): # Note that the tool should be in defined in exec but not imported in exec, # so it should also have the same module with the current function. if getattr(obj, "__module__", "") != tool_module.__name__: continue tools.append(obj) return tools @staticmethod def _collect_tool_class_methods_in_module(tool_module): from promptflow._core.tool import ToolProvider tools = [] for _, obj in inspect.getmembers(tool_module): if isinstance(obj, type) and issubclass(obj, ToolProvider) and obj.__module__ == tool_module.__name__: for _, method in inspect.getmembers(obj): if is_tool(method): initialize_inputs = obj.get_initialize_inputs() tools.append((method, initialize_inputs)) return tools def _get_tool_name(self, tool): tool_name = ( f"{tool.module}.{tool.class_name}.{tool.function}" if tool.class_name is not None else f"{tool.module}.{tool.function}" ) return tool_name def _parse_tool_from_func(self, tool_func, initialize_inputs=None): """ Parse tool from tool function :param tool_func: The tool function :type tool_func: callable :param initialize_inputs: Initialize inputs of tool :type initialize_inputs: Dict[str, obj] :return: tool object, tool input settings, extra info about the tool :rtype: Tool, Dict[str, InputSetting], Dict[str, obj] """ tool = _parse_tool_from_function( tool_func, initialize_inputs=initialize_inputs, gen_custom_type_conn=True, skip_prompt_template=True ) extra_info = getattr(tool_func, "__extra_info") input_settings = getattr(tool_func, "__input_settings") return tool, input_settings, extra_info def _validate_tool_function(self, tool, input_settings, extra_info, func_name=None, func_path=None): """ Check whether the icon and input settings of the tool are legitimate. :param tool: The tool object :type tool: Tool :param input_settings: Input settings of the tool :type input_settings: Dict[str, InputSetting] :param extra_info: Extra info about the tool :type extra_info: Dict[str, obj] :param func_name: Function name of the tool :type func_name: str :param func_path: Script path of the tool :type func_path: str :return: Validation result of the tool :rtype: ValidationResult """ validate_result = ValidationResultBuilder.success() if extra_info: if ICON in extra_info: if ICON_LIGHT in extra_info or ICON_DARK in extra_info: validate_result.append_error( yaml_path=None, message=f"Cannot provide both `icon` and `{ICON_LIGHT}` or `{ICON_DARK}`.", function_name=func_name, location=func_path, key="function_name", ) if input_settings: input_settings_validate_result = self._validate_input_settings( tool.inputs, input_settings, func_name, func_path ) validate_result.merge_with(input_settings_validate_result) return validate_result def _validate_tool_schema(self, tool_dict, func_name=None, func_path=None): """ Check whether the generated schema of the tool are legitimate. :param tool_dict: The generated tool dict :type tool_dict: Dict[str, obj] :param func_name: Function name of the tool :type func_name: str :param func_path: Script path of the tool :type func_path: str :return: Validation result of the tool :rtype: ValidationResult """ validate_result = ValidationResultBuilder.success() try: jsonschema.validate(instance=tool_dict, schema=self._tool_schema) except jsonschema.exceptions.ValidationError as e: validate_result.append_error( message=str(e), yaml_path=None, function_name=func_name, location=func_path, key="function_name" ) return validate_result def _validate_input_settings(self, tool_inputs, input_settings, func_name=None, func_path=None): """ Check whether input settings of the tool are legitimate. :param tool_inputs: Tool inputs :type tool_inputs: Dict[str, obj] :param input_settings: Input settings of the tool :type input_settings: Dict[str, InputSetting] :param extra_info: Extra info about the tool :type extra_info: Dict[str, obj] :param func_name: Function name of the tool :type func_name: str :param func_path: Script path of the tool :type func_path: str :return: Validation result of the tool :rtype: ValidationResult """ validate_result = ValidationResultBuilder.success() for input_name, settings in input_settings.items(): if input_name not in tool_inputs: validate_result.append_error( yaml_path=None, message=f"Cannot find {input_name} in tool inputs.", function_name=func_name, location=func_path, key="function_name", ) if settings.enabled_by and settings.enabled_by not in tool_inputs: validate_result.append_error( yaml_path=None, message=f'Cannot find the input "{settings.enabled_by}" for the enabled_by of {input_name}.', function_name=func_name, location=func_path, key="function_name", ) if settings.dynamic_list: dynamic_func_inputs = inspect.signature(settings.dynamic_list._func_obj).parameters has_kwargs = any([param.kind == param.VAR_KEYWORD for param in dynamic_func_inputs.values()]) required_inputs = [ k for k, v in dynamic_func_inputs.items() if v.default is inspect.Parameter.empty and v.kind != v.VAR_KEYWORD and k not in SKIP_FUNC_PARAMS ] if settings.dynamic_list._input_mapping: # Validate input mapping in dynamic_list for func_input, reference_input in settings.dynamic_list._input_mapping.items(): # Check invalid input name of dynamic list function if not has_kwargs and func_input not in dynamic_func_inputs: validate_result.append_error( yaml_path=None, message=f"Cannot find {func_input} in the inputs of " f"dynamic_list func {settings.dynamic_list.func_path}", function_name=func_name, location=func_path, key="function_name", ) # Check invalid input name of tool if reference_input not in tool_inputs: validate_result.append_error( yaml_path=None, message=f"Cannot find {reference_input} in the tool inputs.", function_name=func_name, location=func_path, key="function_name", ) if func_input in required_inputs: required_inputs.remove(func_input) # Check required input of dynamic_list function if len(required_inputs) != 0: validate_result.append_error( yaml_path=None, message=f"Missing required input(s) of dynamic_list function: {required_inputs}", function_name=func_name, location=func_path, key="function_name", ) return validate_result def _serialize_tool(self, tool, input_settings, extra_info, tool_func): """ Serialize tool obj to dict. :param tool_func: Package tool function :type tool_func: callable :param initialize_inputs: Initialize inputs of package tool :type initialize_inputs: Dict[str, obj] :return: package tool name, serialized tool :rtype: str, Dict[str, str] """ tool_func_name = tool_func.__name__ tool_script_path = inspect.getsourcefile(getattr(tool_func, "__original_function", tool_func)) validate_result = self._validate_tool_function( tool, input_settings, extra_info, tool_func_name, tool_script_path ) if validate_result.passed: construct_tool = asdict(tool, dict_factory=lambda x: {k: v for (k, v) in x if v}) if extra_info: if ICON in extra_info: extra_info[ICON] = self._serialize_icon_data(extra_info["icon"]) if ICON_LIGHT in extra_info: icon = extra_info.get("icon", {}) icon["light"] = self._serialize_icon_data(extra_info[ICON_LIGHT]) extra_info[ICON] = icon if ICON_DARK in extra_info: icon = extra_info.get("icon", {}) icon["dark"] = self._serialize_icon_data(extra_info[ICON_DARK]) extra_info[ICON] = icon construct_tool.update(extra_info) # Update tool input settings if input_settings: tool_inputs = construct_tool.get("inputs", {}) generated_by_inputs = {} for input_name, settings in input_settings.items(): tool_inputs[input_name].update(asdict_without_none(settings)) if settings.generated_by: generated_by_inputs.update(settings.generated_by._input_settings) tool_inputs.update(generated_by_inputs) schema_validate_result = self._validate_tool_schema(construct_tool, tool_func_name, tool_script_path) validate_result.merge_with(schema_validate_result) return construct_tool, validate_result else: return {}, validate_result def _serialize_icon_data(self, icon): if not Path(icon).exists(): raise UserErrorException(f"Cannot find the icon path {icon}.") return self._serialize_image_data(icon) @staticmethod def _serialize_image_data(image_path): """Serialize image to base64.""" from PIL import Image as PIL_Image with open(image_path, "rb") as image_file: # Create a BytesIO object from the image file image_data = io.BytesIO(image_file.read()) # Open the image and resize it img = PIL_Image.open(image_data) if img.size != (16, 16): img = img.resize((16, 16), PIL_Image.Resampling.LANCZOS) buffered = io.BytesIO() img.save(buffered, format="PNG") icon_image = Image(buffered.getvalue(), mime_type="image/png") image_url = convert_multimedia_data_to_base64(icon_image, with_type=True) return image_url @staticmethod def _is_package_tool(package) -> bool: import pkg_resources try: distribution = pkg_resources.get_distribution(package.__name__) entry_points = distribution.get_entry_map() return PACKAGE_TOOLS_ENTRY in entry_points except Exception as e: logger.debug(f"Failed to check {package.__name__} is a package tool, raise {e}") return False @monitor_operation(activity_name="pf.tools.list", activity_type=ActivityType.PUBLICAPI) def list( self, flow: Union[str, PathLike] = None, ): """ List all package tools in the environment and code tools in the flow. :param flow: path to the flow directory :type flow: Union[str, PathLike] :return: Dict of package tools and code tools info. :rtype: Dict[str, Dict] """ from promptflow._sdk._pf_client import PFClient local_client = PFClient() package_tools = collect_package_tools() if flow: tools, _ = local_client.flows._generate_tools_meta(flow) else: tools = {"package": {}, "code": {}} tools["package"].update(package_tools) return tools @monitor_operation(activity_name="pf.tools.validate", activity_type=ActivityType.PUBLICAPI) def validate( self, source: Union[str, callable, PathLike], *, raise_error: bool = False, **kwargs ) -> ValidationResult: """ Validate tool. :param source: path to the package tool directory or tool script :type source: Union[str, callable, PathLike] :param raise_error: whether raise error when validation failed :type raise_error: bool :return: a validation result object :rtype: ValidationResult """ def validate_tool_function(tool_func, init_inputs=None): tool, input_settings, extra_info = self._parse_tool_from_func(tool_func, init_inputs) _, validate_result = self._serialize_tool(tool, input_settings, extra_info, source) validate_result._set_extra_info(TOTAL_COUNT, 1) validate_result._set_extra_info(INVALID_COUNT, 0 if validate_result.passed else 1) return validate_result if callable(source): from promptflow._core.tool import ToolProvider if isinstance(source, type) and issubclass(source, ToolProvider): # Validate tool class validate_result = ValidationResultBuilder.success() for _, method in inspect.getmembers(source): if is_tool(method): initialize_inputs = source.get_initialize_inputs() func_validate_result = validate_tool_function(method, initialize_inputs) self._merge_validate_result(validate_result, func_validate_result) else: # Validate tool function validate_result = validate_tool_function(source) elif isinstance(source, (str, PathLike)): # Validate tool script if not Path(source).exists(): raise UserErrorException(f"Cannot find the tool script {source}") # Load the module from the file path module_name = Path(source).stem spec = importlib.util.spec_from_file_location(module_name, source) module = importlib.util.module_from_spec(spec) # Load the module's code spec.loader.exec_module(module) _, validate_result = self._generate_tool_meta(module) elif isinstance(source, ModuleType): # Validate package tool if not self._is_package_tool(source): raise UserErrorException("Invalid package tool.") _, validate_result = self._list_tool_meta_in_package(package_name=source.__name__) else: raise UserErrorException( "Provide invalid source, tool validation source supports script tool, " "package tool and tool script path." ) def tool_validate_error_func(msg, _): return ToolValidationError(message=msg) validate_result.try_raise(raise_error=raise_error, error_func=tool_validate_error_func) return validate_result
0